mirror of
https://github.com/harvester/harvester-ui-extension.git
synced 2026-11-15 13:26:15 +08:00
112 lines
4.2 MiB
Plaintext
112 lines
4.2 MiB
Plaintext
(function(e,t){"object"===typeof exports&&"object"===typeof module?module.exports=t(require("vue"),require("__jsyaml"),require("__jszip")):"function"===typeof define&&define.amd?define([,"__jsyaml","__jszip"],t):"object"===typeof exports?exports["harvester-1.10.0-dev"]=t(require("vue"),require("__jsyaml"),require("__jszip")):e["harvester-1.10.0-dev"]=t(e["Vue"],e["__jsyaml"],e["__jszip"])})("undefined"!==typeof self?self:this,function(e,t,n){return function(){var r={60425:function(e,t,n){"use strict";function r(e){if(null==e)return window;if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function i(e){var t=r(e).Element;return e instanceof t||e instanceof Element}function o(e){var t=r(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function a(e){if("undefined"===typeof ShadowRoot)return!1;var t=r(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}n.d(t,{n4:function(){return lt}});var s=Math.max,l=Math.min,c=Math.round;function u(){var e=navigator.userAgentData;return null!=e&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(e){return e.brand+"/"+e.version}).join(" "):navigator.userAgent}function d(){return!/^((?!chrome|android).)*safari/i.test(u())}function h(e,t,n){void 0===t&&(t=!1),void 0===n&&(n=!1);var a=e.getBoundingClientRect(),s=1,l=1;t&&o(e)&&(s=e.offsetWidth>0&&c(a.width)/e.offsetWidth||1,l=e.offsetHeight>0&&c(a.height)/e.offsetHeight||1);var u=i(e)?r(e):window,h=u.visualViewport,p=!d()&&n,f=(a.left+(p&&h?h.offsetLeft:0))/s,m=(a.top+(p&&h?h.offsetTop:0))/l,g=a.width/s,v=a.height/l;return{width:g,height:v,top:m,right:f+g,bottom:m+v,left:f,x:f,y:m}}function p(e){var t=r(e),n=t.pageXOffset,i=t.pageYOffset;return{scrollLeft:n,scrollTop:i}}function f(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function m(e){return e!==r(e)&&o(e)?f(e):p(e)}function g(e){return e?(e.nodeName||"").toLowerCase():null}function v(e){return((i(e)?e.ownerDocument:e.document)||window.document).documentElement}function b(e){return h(v(e)).left+p(e).scrollLeft}function y(e){return r(e).getComputedStyle(e)}function w(e){var t=y(e),n=t.overflow,r=t.overflowX,i=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+i+r)}function O(e){var t=e.getBoundingClientRect(),n=c(t.width)/e.offsetWidth||1,r=c(t.height)/e.offsetHeight||1;return 1!==n||1!==r}function S(e,t,n){void 0===n&&(n=!1);var r=o(t),i=o(t)&&O(t),a=v(t),s=h(e,i,n),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&(("body"!==g(t)||w(a))&&(l=m(t)),o(t)?(c=h(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):a&&(c.x=b(a))),{x:s.left+l.scrollLeft-c.x,y:s.top+l.scrollTop-c.y,width:s.width,height:s.height}}function E(e){var t=h(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function x(e){return"html"===g(e)?e:e.assignedSlot||e.parentNode||(a(e)?e.host:null)||v(e)}function _(e){return["html","body","#document"].indexOf(g(e))>=0?e.ownerDocument.body:o(e)&&w(e)?e:_(x(e))}function k(e,t){var n;void 0===t&&(t=[]);var i=_(e),o=i===(null==(n=e.ownerDocument)?void 0:n.body),a=r(i),s=o?[a].concat(a.visualViewport||[],w(i)?i:[]):i,l=t.concat(s);return o?l:l.concat(k(x(s)))}function C(e){return["table","td","th"].indexOf(g(e))>=0}function A(e){return o(e)&&"fixed"!==y(e).position?e.offsetParent:null}function T(e){var t=/firefox/i.test(u()),n=/Trident/i.test(u());if(n&&o(e)){var r=y(e);if("fixed"===r.position)return null}var i=x(e);a(i)&&(i=i.host);while(o(i)&&["html","body"].indexOf(g(i))<0){var s=y(i);if("none"!==s.transform||"none"!==s.perspective||"paint"===s.contain||-1!==["transform","perspective"].indexOf(s.willChange)||t&&"filter"===s.willChange||t&&s.filter&&"none"!==s.filter)return i;i=i.parentNode}return null}function R(e){var t=r(e),n=A(e);while(n&&C(n)&&"static"===y(n).position)n=A(n);return n&&("html"===g(n)||"body"===g(n)&&"static"===y(n).position)?t:n||T(e)||t}var N="top",P="bottom",I="right",M="left",D="auto",L=[N,P,I,M],B="start",$="end",V="clippingParents",F="viewport",j="popper",U="reference",G=L.reduce(function(e,t){return e.concat([t+"-"+B,t+"-"+$])},[]),H=[].concat(L,[D]).reduce(function(e,t){return e.concat([t,t+"-"+B,t+"-"+$])},[]),q="beforeRead",Q="read",z="afterRead",K="beforeMain",W="main",X="afterMain",Y="beforeWrite",Z="write",J="afterWrite",ee=[q,Q,z,K,W,X,Y,Z,J];function te(e){var t=new Map,n=new Set,r=[];function i(e){n.add(e.name);var o=[].concat(e.requires||[],e.requiresIfExists||[]);o.forEach(function(e){if(!n.has(e)){var r=t.get(e);r&&i(r)}}),r.push(e)}return e.forEach(function(e){t.set(e.name,e)}),e.forEach(function(e){n.has(e.name)||i(e)}),r}function ne(e){var t=te(e);return ee.reduce(function(e,n){return e.concat(t.filter(function(e){return e.phase===n}))},[])}function re(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function ie(e){var t=e.reduce(function(e,t){var n=e[t.name];return e[t.name]=n?Object.assign({},n,t,{options:Object.assign({},n.options,t.options),data:Object.assign({},n.data,t.data)}):t,e},{});return Object.keys(t).map(function(e){return t[e]})}var oe={placement:"bottom",modifiers:[],strategy:"absolute"};function ae(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return!t.some(function(e){return!(e&&"function"===typeof e.getBoundingClientRect)})}function se(e){void 0===e&&(e={});var t=e,n=t.defaultModifiers,r=void 0===n?[]:n,o=t.defaultOptions,a=void 0===o?oe:o;return function(e,t,n){void 0===n&&(n=a);var o={placement:"bottom",orderedModifiers:[],options:Object.assign({},oe,a),modifiersData:{},elements:{reference:e,popper:t},attributes:{},styles:{}},s=[],l=!1,c={state:o,setOptions:function(n){var s="function"===typeof n?n(o.options):n;d(),o.options=Object.assign({},a,o.options,s),o.scrollParents={reference:i(e)?k(e):e.contextElement?k(e.contextElement):[],popper:k(t)};var l=ne(ie([].concat(r,o.options.modifiers)));return o.orderedModifiers=l.filter(function(e){return e.enabled}),u(),c.update()},forceUpdate:function(){if(!l){var e=o.elements,t=e.reference,n=e.popper;if(ae(t,n)){o.rects={reference:S(t,R(n),"fixed"===o.options.strategy),popper:E(n)},o.reset=!1,o.placement=o.options.placement,o.orderedModifiers.forEach(function(e){return o.modifiersData[e.name]=Object.assign({},e.data)});for(var r=0;r<o.orderedModifiers.length;r++)if(!0!==o.reset){var i=o.orderedModifiers[r],a=i.fn,s=i.options,u=void 0===s?{}:s,d=i.name;"function"===typeof a&&(o=a({state:o,options:u,name:d,instance:c})||o)}else o.reset=!1,r=-1}}},update:re(function(){return new Promise(function(e){c.forceUpdate(),e(o)})}),destroy:function(){d(),l=!0}};if(!ae(e,t))return c;function u(){o.orderedModifiers.forEach(function(e){var t=e.name,n=e.options,r=void 0===n?{}:n,i=e.effect;if("function"===typeof i){var a=i({state:o,name:t,instance:c,options:r}),l=function(){};s.push(a||l)}})}function d(){s.forEach(function(e){return e()}),s=[]}return c.setOptions(n).then(function(e){!l&&n.onFirstUpdate&&n.onFirstUpdate(e)}),c}}var le={passive:!0};function ce(e){var t=e.state,n=e.instance,i=e.options,o=i.scroll,a=void 0===o||o,s=i.resize,l=void 0===s||s,c=r(t.elements.popper),u=[].concat(t.scrollParents.reference,t.scrollParents.popper);return a&&u.forEach(function(e){e.addEventListener("scroll",n.update,le)}),l&&c.addEventListener("resize",n.update,le),function(){a&&u.forEach(function(e){e.removeEventListener("scroll",n.update,le)}),l&&c.removeEventListener("resize",n.update,le)}}var ue={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:ce,data:{}};function de(e){return e.split("-")[0]}function he(e){return e.split("-")[1]}function pe(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function fe(e){var t,n=e.reference,r=e.element,i=e.placement,o=i?de(i):null,a=i?he(i):null,s=n.x+n.width/2-r.width/2,l=n.y+n.height/2-r.height/2;switch(o){case N:t={x:s,y:n.y-r.height};break;case P:t={x:s,y:n.y+n.height};break;case I:t={x:n.x+n.width,y:l};break;case M:t={x:n.x-r.width,y:l};break;default:t={x:n.x,y:n.y}}var c=o?pe(o):null;if(null!=c){var u="y"===c?"height":"width";switch(a){case B:t[c]=t[c]-(n[u]/2-r[u]/2);break;case $:t[c]=t[c]+(n[u]/2-r[u]/2);break;default:}}return t}function me(e){var t=e.state,n=e.name;t.modifiersData[n]=fe({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}var ge={name:"popperOffsets",enabled:!0,phase:"read",fn:me,data:{}},ve={top:"auto",right:"auto",bottom:"auto",left:"auto"};function be(e,t){var n=e.x,r=e.y,i=t.devicePixelRatio||1;return{x:c(n*i)/i||0,y:c(r*i)/i||0}}function ye(e){var t,n=e.popper,i=e.popperRect,o=e.placement,a=e.variation,s=e.offsets,l=e.position,c=e.gpuAcceleration,u=e.adaptive,d=e.roundOffsets,h=e.isFixed,p=s.x,f=void 0===p?0:p,m=s.y,g=void 0===m?0:m,b="function"===typeof d?d({x:f,y:g}):{x:f,y:g};f=b.x,g=b.y;var w=s.hasOwnProperty("x"),O=s.hasOwnProperty("y"),S=M,E=N,x=window;if(u){var _=R(n),k="clientHeight",C="clientWidth";if(_===r(n)&&(_=v(n),"static"!==y(_).position&&"absolute"===l&&(k="scrollHeight",C="scrollWidth")),o===N||(o===M||o===I)&&a===$){E=P;var A=h&&_===x&&x.visualViewport?x.visualViewport.height:_[k];g-=A-i.height,g*=c?1:-1}if(o===M||(o===N||o===P)&&a===$){S=I;var T=h&&_===x&&x.visualViewport?x.visualViewport.width:_[C];f-=T-i.width,f*=c?1:-1}}var D,L=Object.assign({position:l},u&&ve),B=!0===d?be({x:f,y:g},r(n)):{x:f,y:g};return f=B.x,g=B.y,c?Object.assign({},L,(D={},D[E]=O?"0":"",D[S]=w?"0":"",D.transform=(x.devicePixelRatio||1)<=1?"translate("+f+"px, "+g+"px)":"translate3d("+f+"px, "+g+"px, 0)",D)):Object.assign({},L,(t={},t[E]=O?g+"px":"",t[S]=w?f+"px":"",t.transform="",t))}function we(e){var t=e.state,n=e.options,r=n.gpuAcceleration,i=void 0===r||r,o=n.adaptive,a=void 0===o||o,s=n.roundOffsets,l=void 0===s||s,c={placement:de(t.placement),variation:he(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:i,isFixed:"fixed"===t.options.strategy};null!=t.modifiersData.popperOffsets&&(t.styles.popper=Object.assign({},t.styles.popper,ye(Object.assign({},c,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:a,roundOffsets:l})))),null!=t.modifiersData.arrow&&(t.styles.arrow=Object.assign({},t.styles.arrow,ye(Object.assign({},c,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}var Oe={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:we,data:{}};function Se(e){var t=e.state;Object.keys(t.elements).forEach(function(e){var n=t.styles[e]||{},r=t.attributes[e]||{},i=t.elements[e];o(i)&&g(i)&&(Object.assign(i.style,n),Object.keys(r).forEach(function(e){var t=r[e];!1===t?i.removeAttribute(e):i.setAttribute(e,!0===t?"":t)}))})}function Ee(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(e){var r=t.elements[e],i=t.attributes[e]||{},a=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:n[e]),s=a.reduce(function(e,t){return e[t]="",e},{});o(r)&&g(r)&&(Object.assign(r.style,s),Object.keys(i).forEach(function(e){r.removeAttribute(e)}))})}}var xe={name:"applyStyles",enabled:!0,phase:"write",fn:Se,effect:Ee,requires:["computeStyles"]};function _e(e,t,n){var r=de(e),i=[M,N].indexOf(r)>=0?-1:1,o="function"===typeof n?n(Object.assign({},t,{placement:e})):n,a=o[0],s=o[1];return a=a||0,s=(s||0)*i,[M,I].indexOf(r)>=0?{x:s,y:a}:{x:a,y:s}}function ke(e){var t=e.state,n=e.options,r=e.name,i=n.offset,o=void 0===i?[0,0]:i,a=H.reduce(function(e,n){return e[n]=_e(n,t.rects,o),e},{}),s=a[t.placement],l=s.x,c=s.y;null!=t.modifiersData.popperOffsets&&(t.modifiersData.popperOffsets.x+=l,t.modifiersData.popperOffsets.y+=c),t.modifiersData[r]=a}var Ce={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:ke},Ae={left:"right",right:"left",bottom:"top",top:"bottom"};function Te(e){return e.replace(/left|right|bottom|top/g,function(e){return Ae[e]})}var Re={start:"end",end:"start"};function Ne(e){return e.replace(/start|end/g,function(e){return Re[e]})}function Pe(e,t){var n=r(e),i=v(e),o=n.visualViewport,a=i.clientWidth,s=i.clientHeight,l=0,c=0;if(o){a=o.width,s=o.height;var u=d();(u||!u&&"fixed"===t)&&(l=o.offsetLeft,c=o.offsetTop)}return{width:a,height:s,x:l+b(e),y:c}}function Ie(e){var t,n=v(e),r=p(e),i=null==(t=e.ownerDocument)?void 0:t.body,o=s(n.scrollWidth,n.clientWidth,i?i.scrollWidth:0,i?i.clientWidth:0),a=s(n.scrollHeight,n.clientHeight,i?i.scrollHeight:0,i?i.clientHeight:0),l=-r.scrollLeft+b(e),c=-r.scrollTop;return"rtl"===y(i||n).direction&&(l+=s(n.clientWidth,i?i.clientWidth:0)-o),{width:o,height:a,x:l,y:c}}function Me(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&a(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function De(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function Le(e,t){var n=h(e,!1,"fixed"===t);return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function Be(e,t,n){return t===F?De(Pe(e,n)):i(t)?Le(t,n):De(Ie(v(e)))}function $e(e){var t=k(x(e)),n=["absolute","fixed"].indexOf(y(e).position)>=0,r=n&&o(e)?R(e):e;return i(r)?t.filter(function(e){return i(e)&&Me(e,r)&&"body"!==g(e)}):[]}function Ve(e,t,n,r){var i="clippingParents"===t?$e(e):[].concat(t),o=[].concat(i,[n]),a=o[0],c=o.reduce(function(t,n){var i=Be(e,n,r);return t.top=s(i.top,t.top),t.right=l(i.right,t.right),t.bottom=l(i.bottom,t.bottom),t.left=s(i.left,t.left),t},Be(e,a,r));return c.width=c.right-c.left,c.height=c.bottom-c.top,c.x=c.left,c.y=c.top,c}function Fe(){return{top:0,right:0,bottom:0,left:0}}function je(e){return Object.assign({},Fe(),e)}function Ue(e,t){return t.reduce(function(t,n){return t[n]=e,t},{})}function Ge(e,t){void 0===t&&(t={});var n=t,r=n.placement,o=void 0===r?e.placement:r,a=n.strategy,s=void 0===a?e.strategy:a,l=n.boundary,c=void 0===l?V:l,u=n.rootBoundary,d=void 0===u?F:u,p=n.elementContext,f=void 0===p?j:p,m=n.altBoundary,g=void 0!==m&&m,b=n.padding,y=void 0===b?0:b,w=je("number"!==typeof y?y:Ue(y,L)),O=f===j?U:j,S=e.rects.popper,E=e.elements[g?O:f],x=Ve(i(E)?E:E.contextElement||v(e.elements.popper),c,d,s),_=h(e.elements.reference),k=fe({reference:_,element:S,strategy:"absolute",placement:o}),C=De(Object.assign({},S,k)),A=f===j?C:_,T={top:x.top-A.top+w.top,bottom:A.bottom-x.bottom+w.bottom,left:x.left-A.left+w.left,right:A.right-x.right+w.right},R=e.modifiersData.offset;if(f===j&&R){var M=R[o];Object.keys(T).forEach(function(e){var t=[I,P].indexOf(e)>=0?1:-1,n=[N,P].indexOf(e)>=0?"y":"x";T[e]+=M[n]*t})}return T}function He(e,t){void 0===t&&(t={});var n=t,r=n.placement,i=n.boundary,o=n.rootBoundary,a=n.padding,s=n.flipVariations,l=n.allowedAutoPlacements,c=void 0===l?H:l,u=he(r),d=u?s?G:G.filter(function(e){return he(e)===u}):L,h=d.filter(function(e){return c.indexOf(e)>=0});0===h.length&&(h=d);var p=h.reduce(function(t,n){return t[n]=Ge(e,{placement:n,boundary:i,rootBoundary:o,padding:a})[de(n)],t},{});return Object.keys(p).sort(function(e,t){return p[e]-p[t]})}function qe(e){if(de(e)===D)return[];var t=Te(e);return[Ne(e),t,Ne(t)]}function Qe(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var i=n.mainAxis,o=void 0===i||i,a=n.altAxis,s=void 0===a||a,l=n.fallbackPlacements,c=n.padding,u=n.boundary,d=n.rootBoundary,h=n.altBoundary,p=n.flipVariations,f=void 0===p||p,m=n.allowedAutoPlacements,g=t.options.placement,v=de(g),b=v===g,y=l||(b||!f?[Te(g)]:qe(g)),w=[g].concat(y).reduce(function(e,n){return e.concat(de(n)===D?He(t,{placement:n,boundary:u,rootBoundary:d,padding:c,flipVariations:f,allowedAutoPlacements:m}):n)},[]),O=t.rects.reference,S=t.rects.popper,E=new Map,x=!0,_=w[0],k=0;k<w.length;k++){var C=w[k],A=de(C),T=he(C)===B,R=[N,P].indexOf(A)>=0,L=R?"width":"height",$=Ge(t,{placement:C,boundary:u,rootBoundary:d,altBoundary:h,padding:c}),V=R?T?I:M:T?P:N;O[L]>S[L]&&(V=Te(V));var F=Te(V),j=[];if(o&&j.push($[A]<=0),s&&j.push($[V]<=0,$[F]<=0),j.every(function(e){return e})){_=C,x=!1;break}E.set(C,j)}if(x)for(var U=f?3:1,G=function(e){var t=w.find(function(t){var n=E.get(t);if(n)return n.slice(0,e).every(function(e){return e})});if(t)return _=t,"break"},H=U;H>0;H--){var q=G(H);if("break"===q)break}t.placement!==_&&(t.modifiersData[r]._skip=!0,t.placement=_,t.reset=!0)}}var ze={name:"flip",enabled:!0,phase:"main",fn:Qe,requiresIfExists:["offset"],data:{_skip:!1}};function Ke(e){return"x"===e?"y":"x"}function We(e,t,n){return s(e,l(t,n))}function Xe(e,t,n){var r=We(e,t,n);return r>n?n:r}function Ye(e){var t=e.state,n=e.options,r=e.name,i=n.mainAxis,o=void 0===i||i,a=n.altAxis,c=void 0!==a&&a,u=n.boundary,d=n.rootBoundary,h=n.altBoundary,p=n.padding,f=n.tether,m=void 0===f||f,g=n.tetherOffset,v=void 0===g?0:g,b=Ge(t,{boundary:u,rootBoundary:d,padding:p,altBoundary:h}),y=de(t.placement),w=he(t.placement),O=!w,S=pe(y),x=Ke(S),_=t.modifiersData.popperOffsets,k=t.rects.reference,C=t.rects.popper,A="function"===typeof v?v(Object.assign({},t.rects,{placement:t.placement})):v,T="number"===typeof A?{mainAxis:A,altAxis:A}:Object.assign({mainAxis:0,altAxis:0},A),D=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,L={x:0,y:0};if(_){if(o){var $,V="y"===S?N:M,F="y"===S?P:I,j="y"===S?"height":"width",U=_[S],G=U+b[V],H=U-b[F],q=m?-C[j]/2:0,Q=w===B?k[j]:C[j],z=w===B?-C[j]:-k[j],K=t.elements.arrow,W=m&&K?E(K):{width:0,height:0},X=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:Fe(),Y=X[V],Z=X[F],J=We(0,k[j],W[j]),ee=O?k[j]/2-q-J-Y-T.mainAxis:Q-J-Y-T.mainAxis,te=O?-k[j]/2+q+J+Z+T.mainAxis:z+J+Z+T.mainAxis,ne=t.elements.arrow&&R(t.elements.arrow),re=ne?"y"===S?ne.clientTop||0:ne.clientLeft||0:0,ie=null!=($=null==D?void 0:D[S])?$:0,oe=U+ee-ie-re,ae=U+te-ie,se=We(m?l(G,oe):G,U,m?s(H,ae):H);_[S]=se,L[S]=se-U}if(c){var le,ce="x"===S?N:M,ue="x"===S?P:I,fe=_[x],me="y"===x?"height":"width",ge=fe+b[ce],ve=fe-b[ue],be=-1!==[N,M].indexOf(y),ye=null!=(le=null==D?void 0:D[x])?le:0,we=be?ge:fe-k[me]-C[me]-ye+T.altAxis,Oe=be?fe+k[me]+C[me]-ye-T.altAxis:ve,Se=m&&be?Xe(we,fe,Oe):We(m?we:ge,fe,m?Oe:ve);_[x]=Se,L[x]=Se-fe}t.modifiersData[r]=L}}var Ze={name:"preventOverflow",enabled:!0,phase:"main",fn:Ye,requiresIfExists:["offset"]},Je=function(e,t){return e="function"===typeof e?e(Object.assign({},t.rects,{placement:t.placement})):e,je("number"!==typeof e?e:Ue(e,L))};function et(e){var t,n=e.state,r=e.name,i=e.options,o=n.elements.arrow,a=n.modifiersData.popperOffsets,s=de(n.placement),l=pe(s),c=[M,I].indexOf(s)>=0,u=c?"height":"width";if(o&&a){var d=Je(i.padding,n),h=E(o),p="y"===l?N:M,f="y"===l?P:I,m=n.rects.reference[u]+n.rects.reference[l]-a[l]-n.rects.popper[u],g=a[l]-n.rects.reference[l],v=R(o),b=v?"y"===l?v.clientHeight||0:v.clientWidth||0:0,y=m/2-g/2,w=d[p],O=b-h[u]-d[f],S=b/2-h[u]/2+y,x=We(w,S,O),_=l;n.modifiersData[r]=(t={},t[_]=x,t.centerOffset=x-S,t)}}function tt(e){var t=e.state,n=e.options,r=n.element,i=void 0===r?"[data-popper-arrow]":r;null!=i&&("string"!==typeof i||(i=t.elements.popper.querySelector(i),i))&&Me(t.elements.popper,i)&&(t.elements.arrow=i)}var nt={name:"arrow",enabled:!0,phase:"main",fn:et,effect:tt,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function rt(e,t,n){return void 0===n&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function it(e){return[N,I,P,M].some(function(t){return e[t]>=0})}function ot(e){var t=e.state,n=e.name,r=t.rects.reference,i=t.rects.popper,o=t.modifiersData.preventOverflow,a=Ge(t,{elementContext:"reference"}),s=Ge(t,{altBoundary:!0}),l=rt(a,r),c=rt(s,i,o),u=it(l),d=it(c);t.modifiersData[n]={referenceClippingOffsets:l,popperEscapeOffsets:c,isReferenceHidden:u,hasPopperEscaped:d},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":d})}var at={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:ot},st=[ue,ge,Oe,xe,Ce,ze,Ze,nt,at],lt=se({defaultModifiers:st})},19469:function(e,t,n){var r={"./__tests__/opsgenie.spec":91332,"./__tests__/opsgenie.spec.ts":91332,"./__tests__/pagerduty.spec":54293,"./__tests__/pagerduty.spec.ts":54293,"./__tests__/slack.spec":90828,"./__tests__/slack.spec.ts":90828,"./email":51557,"./email.vue":51557,"./opsgenie":22243,"./opsgenie.vue":22243,"./pagerduty":87450,"./pagerduty.vue":87450,"./slack":33427,"./slack.vue":33427,"./webhook":81655,"./webhook.vue":81655};function i(e){var t=o(e);return n(t)}function o(e){if(!n.o(r,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return r[e]}i.keys=function(){return Object.keys(r)},i.resolve=o,e.exports=i,i.id=19469},26093:function(e,t,n){"use strict";var r=n(39907),i=n(4364);function o(e){return o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},o(e)}function a(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,l(r.key),r)}}function s(e,t,n){return t&&a(e.prototype,t),n&&a(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function l(e){var t=c(e,"string");return"symbol"===o(t)?t:String(t)}function c(e,t){if("object"!==o(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!==o(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}function u(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var d,h,p=n(41342),f=p.codes,m=f.ERR_AMBIGUOUS_ARGUMENT,g=f.ERR_INVALID_ARG_TYPE,v=f.ERR_INVALID_ARG_VALUE,b=f.ERR_INVALID_RETURN_VALUE,y=f.ERR_MISSING_ARGS,w=n(49801),O=n(49208),S=O.inspect,E=n(49208).types,x=E.isPromise,_=E.isRegExp,k=n(23225)(),C=n(61937)(),A=n(79818)("RegExp.prototype.test");new Map;function T(){var e=n(5656);d=e.isDeepEqual,h=e.isDeepStrictEqual}var R=!1,N=e.exports=L,P={};function I(e){if(e.message instanceof Error)throw e.message;throw new w(e)}function M(e,t,n,o,a){var s,l=arguments.length;if(0===l)s="Failed";else if(1===l)n=e,e=void 0;else{if(!1===R){R=!0;var c=r.emitWarning?r.emitWarning:i.warn.bind(i);c("assert.fail() with more than one argument is deprecated. Please use assert.strictEqual() instead or only pass a message.","DeprecationWarning","DEP0094")}2===l&&(o="!=")}if(n instanceof Error)throw n;var u={actual:e,expected:t,operator:void 0===o?"fail":o,stackStartFn:a||M};void 0!==n&&(u.message=n);var d=new w(u);throw s&&(d.message=s,d.generatedMessage=!0),d}function D(e,t,n,r){if(!n){var i=!1;if(0===t)i=!0,r="No value argument passed to `assert.ok()`";else if(r instanceof Error)throw r;var o=new w({actual:n,expected:!0,message:r,operator:"==",stackStartFn:e});throw o.generatedMessage=i,o}}function L(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];D.apply(void 0,[L,t.length].concat(t))}function B(e,t,n){if(arguments.length<2)throw new y("actual","expected");void 0===d&&T(),h(e,t)&&I({actual:e,expected:t,message:n,operator:"notDeepStrictEqual",stackStartFn:B})}N.fail=M,N.AssertionError=w,N.ok=L,N.equal=function e(t,n,r){if(arguments.length<2)throw new y("actual","expected");t!=n&&I({actual:t,expected:n,message:r,operator:"==",stackStartFn:e})},N.notEqual=function e(t,n,r){if(arguments.length<2)throw new y("actual","expected");t==n&&I({actual:t,expected:n,message:r,operator:"!=",stackStartFn:e})},N.deepEqual=function e(t,n,r){if(arguments.length<2)throw new y("actual","expected");void 0===d&&T(),d(t,n)||I({actual:t,expected:n,message:r,operator:"deepEqual",stackStartFn:e})},N.notDeepEqual=function e(t,n,r){if(arguments.length<2)throw new y("actual","expected");void 0===d&&T(),d(t,n)&&I({actual:t,expected:n,message:r,operator:"notDeepEqual",stackStartFn:e})},N.deepStrictEqual=function e(t,n,r){if(arguments.length<2)throw new y("actual","expected");void 0===d&&T(),h(t,n)||I({actual:t,expected:n,message:r,operator:"deepStrictEqual",stackStartFn:e})},N.notDeepStrictEqual=B,N.strictEqual=function e(t,n,r){if(arguments.length<2)throw new y("actual","expected");C(t,n)||I({actual:t,expected:n,message:r,operator:"strictEqual",stackStartFn:e})},N.notStrictEqual=function e(t,n,r){if(arguments.length<2)throw new y("actual","expected");C(t,n)&&I({actual:t,expected:n,message:r,operator:"notStrictEqual",stackStartFn:e})};var $=s(function e(t,n,r){var i=this;u(this,e),n.forEach(function(e){e in t&&(void 0!==r&&"string"===typeof r[e]&&_(t[e])&&A(t[e],r[e])?i[e]=r[e]:i[e]=t[e])})});function V(e,t,n,r,i,o){if(!(n in e)||!h(e[n],t[n])){if(!r){var a=new $(e,i),s=new $(t,i,e),l=new w({actual:a,expected:s,operator:"deepStrictEqual",stackStartFn:o});throw l.actual=e,l.expected=t,l.operator=o.name,l}I({actual:e,expected:t,message:r,operator:o.name,stackStartFn:o})}}function F(e,t,n,r){if("function"!==typeof t){if(_(t))return A(t,e);if(2===arguments.length)throw new g("expected",["Function","RegExp"],t);if("object"!==o(e)||null===e){var i=new w({actual:e,expected:t,message:n,operator:"deepStrictEqual",stackStartFn:r});throw i.operator=r.name,i}var a=Object.keys(t);if(t instanceof Error)a.push("name","message");else if(0===a.length)throw new v("error",t,"may not be an empty object");return void 0===d&&T(),a.forEach(function(i){"string"===typeof e[i]&&_(t[i])&&A(t[i],e[i])||V(e,t,i,n,a,r)}),!0}return void 0!==t.prototype&&e instanceof t||!Error.isPrototypeOf(t)&&!0===t.call({},e)}function j(e){if("function"!==typeof e)throw new g("fn","Function",e);try{e()}catch(t){return t}return P}function U(e){return x(e)||null!==e&&"object"===o(e)&&"function"===typeof e.then&&"function"===typeof e.catch}function G(e){return Promise.resolve().then(function(){var t;if("function"===typeof e){if(t=e(),!U(t))throw new b("instance of Promise","promiseFn",t)}else{if(!U(e))throw new g("promiseFn",["Function","Promise"],e);t=e}return Promise.resolve().then(function(){return t}).then(function(){return P}).catch(function(e){return e})})}function H(e,t,n,r){if("string"===typeof n){if(4===arguments.length)throw new g("error",["Object","Error","Function","RegExp"],n);if("object"===o(t)&&null!==t){if(t.message===n)throw new m("error/message",'The error message "'.concat(t.message,'" is identical to the message.'))}else if(t===n)throw new m("error/message",'The error "'.concat(t,'" is identical to the message.'));r=n,n=void 0}else if(null!=n&&"object"!==o(n)&&"function"!==typeof n)throw new g("error",["Object","Error","Function","RegExp"],n);if(t===P){var i="";n&&n.name&&(i+=" (".concat(n.name,")")),i+=r?": ".concat(r):".";var a="rejects"===e.name?"rejection":"exception";I({actual:void 0,expected:n,operator:e.name,message:"Missing expected ".concat(a).concat(i),stackStartFn:e})}if(n&&!F(t,n,r,e))throw t}function q(e,t,n,r){if(t!==P){if("string"===typeof n&&(r=n,n=void 0),!n||F(t,n)){var i=r?": ".concat(r):".",o="doesNotReject"===e.name?"rejection":"exception";I({actual:t,expected:n,operator:e.name,message:"Got unwanted ".concat(o).concat(i,"\n")+'Actual message: "'.concat(t&&t.message,'"'),stackStartFn:e})}throw t}}function Q(e,t,n,r,i){if(!_(t))throw new g("regexp","RegExp",t);var a="match"===i;if("string"!==typeof e||A(t,e)!==a){if(n instanceof Error)throw n;var s=!n;n=n||("string"!==typeof e?'The "string" argument must be of type string. Received type '+"".concat(o(e)," (").concat(S(e),")"):(a?"The input did not match the regular expression ":"The input was expected to not match the regular expression ")+"".concat(S(t),". Input:\n\n").concat(S(e),"\n"));var l=new w({actual:e,expected:t,message:n,operator:i,stackStartFn:r});throw l.generatedMessage=s,l}}function z(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];D.apply(void 0,[z,t.length].concat(t))}N.throws=function e(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];H.apply(void 0,[e,j(t)].concat(r))},N.rejects=function e(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];return G(t).then(function(t){return H.apply(void 0,[e,t].concat(r))})},N.doesNotThrow=function e(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];q.apply(void 0,[e,j(t)].concat(r))},N.doesNotReject=function e(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];return G(t).then(function(t){return q.apply(void 0,[e,t].concat(r))})},N.ifError=function e(t){if(null!==t&&void 0!==t){var n="ifError got unwanted exception: ";"object"===o(t)&&"string"===typeof t.message?0===t.message.length&&t.constructor?n+=t.constructor.name:n+=t.message:n+=S(t);var r=new w({actual:t,expected:null,operator:"ifError",message:n,stackStartFn:e}),i=t.stack;if("string"===typeof i){var a=i.split("\n");a.shift();for(var s=r.stack.split("\n"),l=0;l<a.length;l++){var c=s.indexOf(a[l]);if(-1!==c){s=s.slice(0,c);break}}r.stack="".concat(s.join("\n"),"\n").concat(a.join("\n"))}throw r}},N.match=function e(t,n,r){Q(t,n,r,e,"match")},N.doesNotMatch=function e(t,n,r){Q(t,n,r,e,"doesNotMatch")},N.strict=k(z,N,{equal:N.strictEqual,deepEqual:N.deepStrictEqual,notEqual:N.notStrictEqual,notDeepEqual:N.notDeepStrictEqual}),N.strict.strict=N.strict},49801:function(e,t,n){"use strict";var r=n(39907);function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function o(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?i(Object(n),!0).forEach(function(t){a(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):i(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function a(e,t,n){return t=u(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function s(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function l(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,u(r.key),r)}}function c(e,t,n){return t&&l(e.prototype,t),n&&l(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function u(e){var t=d(e,"string");return"symbol"===S(t)?t:String(t)}function d(e,t){if("object"!==S(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!==S(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}function h(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&w(e,t)}function p(e){var t=b();return function(){var n,r=O(e);if(t){var i=O(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return f(this,n)}}function f(e,t){if(t&&("object"===S(t)||"function"===typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return m(e)}function m(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function g(e){var t="function"===typeof Map?new Map:void 0;return g=function(e){if(null===e||!y(e))return e;if("function"!==typeof e)throw new TypeError("Super expression must either be null or a function");if("undefined"!==typeof t){if(t.has(e))return t.get(e);t.set(e,n)}function n(){return v(e,arguments,O(this).constructor)}return n.prototype=Object.create(e.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),w(n,e)},g(e)}function v(e,t,n){return v=b()?Reflect.construct.bind():function(e,t,n){var r=[null];r.push.apply(r,t);var i=Function.bind.apply(e,r),o=new i;return n&&w(o,n.prototype),o},v.apply(null,arguments)}function b(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}function y(e){return-1!==Function.toString.call(e).indexOf("[native code]")}function w(e,t){return w=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},w(e,t)}function O(e){return O=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},O(e)}function S(e){return S="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},S(e)}var E=n(49208),x=E.inspect,_=n(41342),k=_.codes.ERR_INVALID_ARG_TYPE;function C(e,t,n){return(void 0===n||n>e.length)&&(n=e.length),e.substring(n-t.length,n)===t}function A(e,t){if(t=Math.floor(t),0==e.length||0==t)return"";var n=e.length*t;t=Math.floor(Math.log(t)/Math.log(2));while(t)e+=e,t--;return e+=e.substring(0,n-e.length),e}var T="",R="",N="",P="",I={deepStrictEqual:"Expected values to be strictly deep-equal:",strictEqual:"Expected values to be strictly equal:",strictEqualObject:'Expected "actual" to be reference-equal to "expected":',deepEqual:"Expected values to be loosely deep-equal:",equal:"Expected values to be loosely equal:",notDeepStrictEqual:'Expected "actual" not to be strictly deep-equal to:',notStrictEqual:'Expected "actual" to be strictly unequal to:',notStrictEqualObject:'Expected "actual" not to be reference-equal to "expected":',notDeepEqual:'Expected "actual" not to be loosely deep-equal to:',notEqual:'Expected "actual" to be loosely unequal to:',notIdentical:"Values identical but not reference-equal:"},M=10;function D(e){var t=Object.keys(e),n=Object.create(Object.getPrototypeOf(e));return t.forEach(function(t){n[t]=e[t]}),Object.defineProperty(n,"message",{value:e.message}),n}function L(e){return x(e,{compact:!1,customInspect:!1,depth:1e3,maxArrayLength:1/0,showHidden:!1,breakLength:1/0,showProxy:!1,sorted:!0,getters:!0})}function B(e,t,n){var i="",o="",a=0,s="",l=!1,c=L(e),u=c.split("\n"),d=L(t).split("\n"),h=0,p="";if("strictEqual"===n&&"object"===S(e)&&"object"===S(t)&&null!==e&&null!==t&&(n="strictEqualObject"),1===u.length&&1===d.length&&u[0]!==d[0]){var f=u[0].length+d[0].length;if(f<=M){if(("object"!==S(e)||null===e)&&("object"!==S(t)||null===t)&&(0!==e||0!==t))return"".concat(I[n],"\n\n")+"".concat(u[0]," !== ").concat(d[0],"\n")}else if("strictEqualObject"!==n){var m=r.stderr&&r.stderr.isTTY?r.stderr.columns:80;if(f<m){while(u[0][h]===d[0][h])h++;h>2&&(p="\n ".concat(A(" ",h),"^"),h=0)}}}var g=u[u.length-1],v=d[d.length-1];while(g===v){if(h++<2?s="\n ".concat(g).concat(s):i=g,u.pop(),d.pop(),0===u.length||0===d.length)break;g=u[u.length-1],v=d[d.length-1]}var b=Math.max(u.length,d.length);if(0===b){var y=c.split("\n");if(y.length>30){y[26]="".concat(T,"...").concat(P);while(y.length>27)y.pop()}return"".concat(I.notIdentical,"\n\n").concat(y.join("\n"),"\n")}h>3&&(s="\n".concat(T,"...").concat(P).concat(s),l=!0),""!==i&&(s="\n ".concat(i).concat(s),i="");var w=0,O=I[n]+"\n".concat(R,"+ actual").concat(P," ").concat(N,"- expected").concat(P),E=" ".concat(T,"...").concat(P," Lines skipped");for(h=0;h<b;h++){var x=h-a;if(u.length<h+1)x>1&&h>2&&(x>4?(o+="\n".concat(T,"...").concat(P),l=!0):x>3&&(o+="\n ".concat(d[h-2]),w++),o+="\n ".concat(d[h-1]),w++),a=h,i+="\n".concat(N,"-").concat(P," ").concat(d[h]),w++;else if(d.length<h+1)x>1&&h>2&&(x>4?(o+="\n".concat(T,"...").concat(P),l=!0):x>3&&(o+="\n ".concat(u[h-2]),w++),o+="\n ".concat(u[h-1]),w++),a=h,o+="\n".concat(R,"+").concat(P," ").concat(u[h]),w++;else{var _=d[h],k=u[h],D=k!==_&&(!C(k,",")||k.slice(0,-1)!==_);D&&C(_,",")&&_.slice(0,-1)===k&&(D=!1,k+=","),D?(x>1&&h>2&&(x>4?(o+="\n".concat(T,"...").concat(P),l=!0):x>3&&(o+="\n ".concat(u[h-2]),w++),o+="\n ".concat(u[h-1]),w++),a=h,o+="\n".concat(R,"+").concat(P," ").concat(k),i+="\n".concat(N,"-").concat(P," ").concat(_),w+=2):(o+=i,i="",1!==x&&0!==h||(o+="\n ".concat(k),w++))}if(w>20&&h<b-2)return"".concat(O).concat(E,"\n").concat(o,"\n").concat(T,"...").concat(P).concat(i,"\n")+"".concat(T,"...").concat(P)}return"".concat(O).concat(l?E:"","\n").concat(o).concat(i).concat(s).concat(p)}var $=function(e,t){h(i,e);var n=p(i);function i(e){var t;if(s(this,i),"object"!==S(e)||null===e)throw new k("options","Object",e);var o=e.message,a=e.operator,l=e.stackStartFn,c=e.actual,u=e.expected,d=Error.stackTraceLimit;if(Error.stackTraceLimit=0,null!=o)t=n.call(this,String(o));else if(r.stderr&&r.stderr.isTTY&&(r.stderr&&r.stderr.getColorDepth&&1!==r.stderr.getColorDepth()?(T="[34m",R="[32m",P="[39m",N="[31m"):(T="",R="",P="",N="")),"object"===S(c)&&null!==c&&"object"===S(u)&&null!==u&&"stack"in c&&c instanceof Error&&"stack"in u&&u instanceof Error&&(c=D(c),u=D(u)),"deepStrictEqual"===a||"strictEqual"===a)t=n.call(this,B(c,u,a));else if("notDeepStrictEqual"===a||"notStrictEqual"===a){var h=I[a],p=L(c).split("\n");if("notStrictEqual"===a&&"object"===S(c)&&null!==c&&(h=I.notStrictEqualObject),p.length>30){p[26]="".concat(T,"...").concat(P);while(p.length>27)p.pop()}t=1===p.length?n.call(this,"".concat(h," ").concat(p[0])):n.call(this,"".concat(h,"\n\n").concat(p.join("\n"),"\n"))}else{var g=L(c),v="",b=I[a];"notDeepEqual"===a||"notEqual"===a?(g="".concat(I[a],"\n\n").concat(g),g.length>1024&&(g="".concat(g.slice(0,1021),"..."))):(v="".concat(L(u)),g.length>512&&(g="".concat(g.slice(0,509),"...")),v.length>512&&(v="".concat(v.slice(0,509),"...")),"deepEqual"===a||"equal"===a?g="".concat(b,"\n\n").concat(g,"\n\nshould equal\n\n"):v=" ".concat(a," ").concat(v)),t=n.call(this,"".concat(g).concat(v))}return Error.stackTraceLimit=d,t.generatedMessage=!o,Object.defineProperty(m(t),"name",{value:"AssertionError [ERR_ASSERTION]",enumerable:!1,writable:!0,configurable:!0}),t.code="ERR_ASSERTION",t.actual=c,t.expected=u,t.operator=a,Error.captureStackTrace&&Error.captureStackTrace(m(t),l),t.stack,t.name="AssertionError",f(t)}return c(i,[{key:"toString",value:function(){return"".concat(this.name," [").concat(this.code,"]: ").concat(this.message)}},{key:t,value:function(e,t){return x(this,o(o({},t),{},{customInspect:!1,depth:0}))}}]),i}(g(Error),x.custom);e.exports=$},41342:function(e,t,n){"use strict";function r(e){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}function i(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,a(r.key),r)}}function o(e,t,n){return t&&i(e.prototype,t),n&&i(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function a(e){var t=s(e,"string");return"symbol"===r(t)?t:String(t)}function s(e,t){if("object"!==r(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,t||"default");if("object"!==r(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}function l(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function c(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&u(e,t)}function u(e,t){return u=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},u(e,t)}function d(e){var t=f();return function(){var n,r=m(e);if(t){var i=m(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return h(this,n)}}function h(e,t){if(t&&("object"===r(t)||"function"===typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return p(e)}function p(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function f(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}function m(e){return m=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},m(e)}var g,v,b={};function y(e,t,n){function r(e,n,r){return"string"===typeof t?t:t(e,n,r)}n||(n=Error);var i=function(t){c(i,t);var n=d(i);function i(t,o,a){var s;return l(this,i),s=n.call(this,r(t,o,a)),s.code=e,s}return o(i)}(n);b[e]=i}function w(e,t){if(Array.isArray(e)){var n=e.length;return e=e.map(function(e){return String(e)}),n>2?"one of ".concat(t," ").concat(e.slice(0,n-1).join(", "),", or ")+e[n-1]:2===n?"one of ".concat(t," ").concat(e[0]," or ").concat(e[1]):"of ".concat(t," ").concat(e[0])}return"of ".concat(t," ").concat(String(e))}function O(e,t,n){return e.substr(!n||n<0?0:+n,t.length)===t}function S(e,t,n){return(void 0===n||n>e.length)&&(n=e.length),e.substring(n-t.length,n)===t}function E(e,t,n){return"number"!==typeof n&&(n=0),!(n+t.length>e.length)&&-1!==e.indexOf(t,n)}y("ERR_AMBIGUOUS_ARGUMENT",'The "%s" argument is ambiguous. %s',TypeError),y("ERR_INVALID_ARG_TYPE",function(e,t,i){var o,a;if(void 0===g&&(g=n(26093)),g("string"===typeof e,"'name' must be a string"),"string"===typeof t&&O(t,"not ")?(o="must not be",t=t.replace(/^not /,"")):o="must be",S(e," argument"))a="The ".concat(e," ").concat(o," ").concat(w(t,"type"));else{var s=E(e,".")?"property":"argument";a='The "'.concat(e,'" ').concat(s," ").concat(o," ").concat(w(t,"type"))}return a+=". Received type ".concat(r(i)),a},TypeError),y("ERR_INVALID_ARG_VALUE",function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"is invalid";void 0===v&&(v=n(49208));var i=v.inspect(t);return i.length>128&&(i="".concat(i.slice(0,128),"...")),"The argument '".concat(e,"' ").concat(r,". Received ").concat(i)},TypeError,RangeError),y("ERR_INVALID_RETURN_VALUE",function(e,t,n){var i;return i=n&&n.constructor&&n.constructor.name?"instance of ".concat(n.constructor.name):"type ".concat(r(n)),"Expected ".concat(e,' to be returned from the "').concat(t,'"')+" function but got ".concat(i,".")},TypeError),y("ERR_MISSING_ARGS",function(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];void 0===g&&(g=n(26093)),g(t.length>0,"At least one arg needs to be specified");var i="The ",o=t.length;switch(t=t.map(function(e){return'"'.concat(e,'"')}),o){case 1:i+="".concat(t[0]," argument");break;case 2:i+="".concat(t[0]," and ").concat(t[1]," arguments");break;default:i+=t.slice(0,o-1).join(", "),i+=", and ".concat(t[o-1]," arguments");break}return"".concat(i," must be specified")},TypeError),e.exports.codes=b},5656:function(e,t,n){"use strict";function r(e,t){return l(e)||s(e,t)||o(e,t)||i()}function i(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function o(e,t){if(e){if("string"===typeof e)return a(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?a(e,t):void 0}}function a(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function s(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,i,o,a,s=[],l=!0,c=!1;try{if(o=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=o.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(e){c=!0,i=e}finally{try{if(!l&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw i}}return s}}function l(e){if(Array.isArray(e))return e}function c(e){return c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},c(e)}var u=void 0!==/a/g.flags,d=function(e){var t=[];return e.forEach(function(e){return t.push(e)}),t},h=function(e){var t=[];return e.forEach(function(e,n){return t.push([n,e])}),t},p=Object.is?Object.is:n(55968),f=Object.getOwnPropertySymbols?Object.getOwnPropertySymbols:function(){return[]},m=Number.isNaN?Number.isNaN:n(7838);function g(e){return e.call.bind(e)}var v=g(Object.prototype.hasOwnProperty),b=g(Object.prototype.propertyIsEnumerable),y=g(Object.prototype.toString),w=n(49208).types,O=w.isAnyArrayBuffer,S=w.isArrayBufferView,E=w.isDate,x=w.isMap,_=w.isRegExp,k=w.isSet,C=w.isNativeError,A=w.isBoxedPrimitive,T=w.isNumberObject,R=w.isStringObject,N=w.isBooleanObject,P=w.isBigIntObject,I=w.isSymbolObject,M=w.isFloat32Array,D=w.isFloat64Array;function L(e){if(0===e.length||e.length>10)return!0;for(var t=0;t<e.length;t++){var n=e.charCodeAt(t);if(n<48||n>57)return!0}return 10===e.length&&e>=Math.pow(2,32)}function B(e){return Object.keys(e).filter(L).concat(f(e).filter(Object.prototype.propertyIsEnumerable.bind(e)))}
|
||
/*!
|
||
* The buffer module from node.js, for the browser.
|
||
*
|
||
* @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org>
|
||
* @license MIT
|
||
*/function $(e,t){if(e===t)return 0;for(var n=e.length,r=t.length,i=0,o=Math.min(n,r);i<o;++i)if(e[i]!==t[i]){n=e[i],r=t[i];break}return n<r?-1:r<n?1:0}var V=void 0,F=!0,j=!1,U=0,G=1,H=2,q=3;function Q(e,t){return u?e.source===t.source&&e.flags===t.flags:RegExp.prototype.toString.call(e)===RegExp.prototype.toString.call(t)}function z(e,t){if(e.byteLength!==t.byteLength)return!1;for(var n=0;n<e.byteLength;n++)if(e[n]!==t[n])return!1;return!0}function K(e,t){return e.byteLength===t.byteLength&&0===$(new Uint8Array(e.buffer,e.byteOffset,e.byteLength),new Uint8Array(t.buffer,t.byteOffset,t.byteLength))}function W(e,t){return e.byteLength===t.byteLength&&0===$(new Uint8Array(e),new Uint8Array(t))}function X(e,t){return T(e)?T(t)&&p(Number.prototype.valueOf.call(e),Number.prototype.valueOf.call(t)):R(e)?R(t)&&String.prototype.valueOf.call(e)===String.prototype.valueOf.call(t):N(e)?N(t)&&Boolean.prototype.valueOf.call(e)===Boolean.prototype.valueOf.call(t):P(e)?P(t)&&BigInt.prototype.valueOf.call(e)===BigInt.prototype.valueOf.call(t):I(t)&&Symbol.prototype.valueOf.call(e)===Symbol.prototype.valueOf.call(t)}function Y(e,t,n,r){if(e===t)return 0!==e||(!n||p(e,t));if(n){if("object"!==c(e))return"number"===typeof e&&m(e)&&m(t);if("object"!==c(t)||null===e||null===t)return!1;if(Object.getPrototypeOf(e)!==Object.getPrototypeOf(t))return!1}else{if(null===e||"object"!==c(e))return(null===t||"object"!==c(t))&&e==t;if(null===t||"object"!==c(t))return!1}var i=y(e),o=y(t);if(i!==o)return!1;if(Array.isArray(e)){if(e.length!==t.length)return!1;var a=B(e,V),s=B(t,V);return a.length===s.length&&J(e,t,n,r,G,a)}if("[object Object]"===i&&(!x(e)&&x(t)||!k(e)&&k(t)))return!1;if(E(e)){if(!E(t)||Date.prototype.getTime.call(e)!==Date.prototype.getTime.call(t))return!1}else if(_(e)){if(!_(t)||!Q(e,t))return!1}else if(C(e)||e instanceof Error){if(e.message!==t.message||e.name!==t.name)return!1}else{if(S(e)){if(n||!M(e)&&!D(e)){if(!K(e,t))return!1}else if(!z(e,t))return!1;var l=B(e,V),u=B(t,V);return l.length===u.length&&J(e,t,n,r,U,l)}if(k(e))return!(!k(t)||e.size!==t.size)&&J(e,t,n,r,H);if(x(e))return!(!x(t)||e.size!==t.size)&&J(e,t,n,r,q);if(O(e)){if(!W(e,t))return!1}else if(A(e)&&!X(e,t))return!1}return J(e,t,n,r,U)}function Z(e,t){return t.filter(function(t){return b(e,t)})}function J(e,t,n,r,i,o){if(5===arguments.length){o=Object.keys(e);var a=Object.keys(t);if(o.length!==a.length)return!1}for(var s=0;s<o.length;s++)if(!v(t,o[s]))return!1;if(n&&5===arguments.length){var l=f(e);if(0!==l.length){var c=0;for(s=0;s<l.length;s++){var u=l[s];if(b(e,u)){if(!b(t,u))return!1;o.push(u),c++}else if(b(t,u))return!1}var d=f(t);if(l.length!==d.length&&Z(t,d).length!==c)return!1}else{var h=f(t);if(0!==h.length&&0!==Z(t,h).length)return!1}}if(0===o.length&&(i===U||i===G&&0===e.length||0===e.size))return!0;if(void 0===r)r={val1:new Map,val2:new Map,position:0};else{var p=r.val1.get(e);if(void 0!==p){var m=r.val2.get(t);if(void 0!==m)return p===m}r.position++}r.val1.set(e,r.position),r.val2.set(t,r.position);var g=se(e,t,n,o,r,i);return r.val1.delete(e),r.val2.delete(t),g}function ee(e,t,n,r){for(var i=d(e),o=0;o<i.length;o++){var a=i[o];if(Y(t,a,n,r))return e.delete(a),!0}return!1}function te(e){switch(c(e)){case"undefined":return null;case"object":return;case"symbol":return!1;case"string":e=+e;case"number":if(m(e))return!1}return!0}function ne(e,t,n){var r=te(n);return null!=r?r:t.has(r)&&!e.has(r)}function re(e,t,n,r,i){var o=te(n);if(null!=o)return o;var a=t.get(o);return!(void 0===a&&!t.has(o)||!Y(r,a,!1,i))&&(!e.has(o)&&Y(r,a,!1,i))}function ie(e,t,n,r){for(var i=null,o=d(e),a=0;a<o.length;a++){var s=o[a];if("object"===c(s)&&null!==s)null===i&&(i=new Set),i.add(s);else if(!t.has(s)){if(n)return!1;if(!ne(e,t,s))return!1;null===i&&(i=new Set),i.add(s)}}if(null!==i){for(var l=d(t),u=0;u<l.length;u++){var h=l[u];if("object"===c(h)&&null!==h){if(!ee(i,h,n,r))return!1}else if(!n&&!e.has(h)&&!ee(i,h,n,r))return!1}return 0===i.size}return!0}function oe(e,t,n,r,i,o){for(var a=d(e),s=0;s<a.length;s++){var l=a[s];if(Y(n,l,i,o)&&Y(r,t.get(l),i,o))return e.delete(l),!0}return!1}function ae(e,t,n,i){for(var o=null,a=h(e),s=0;s<a.length;s++){var l=r(a[s],2),u=l[0],d=l[1];if("object"===c(u)&&null!==u)null===o&&(o=new Set),o.add(u);else{var p=t.get(u);if(void 0===p&&!t.has(u)||!Y(d,p,n,i)){if(n)return!1;if(!re(e,t,u,d,i))return!1;null===o&&(o=new Set),o.add(u)}}}if(null!==o){for(var f=h(t),m=0;m<f.length;m++){var g=r(f[m],2),v=g[0],b=g[1];if("object"===c(v)&&null!==v){if(!oe(o,e,v,b,n,i))return!1}else if(!n&&(!e.has(v)||!Y(e.get(v),b,!1,i))&&!oe(o,e,v,b,!1,i))return!1}return 0===o.size}return!0}function se(e,t,n,r,i,o){var a=0;if(o===H){if(!ie(e,t,n,i))return!1}else if(o===q){if(!ae(e,t,n,i))return!1}else if(o===G)for(;a<e.length;a++){if(!v(e,a)){if(v(t,a))return!1;for(var s=Object.keys(e);a<s.length;a++){var l=s[a];if(!v(t,l)||!Y(e[l],t[l],n,i))return!1}return s.length===Object.keys(t).length}if(!v(t,a)||!Y(e[a],t[a],n,i))return!1}for(a=0;a<r.length;a++){var c=r[a];if(!Y(e[c],t[c],n,i))return!1}return!0}function le(e,t){return Y(e,t,j)}function ce(e,t){return Y(e,t,F)}e.exports={isDeepEqual:le,isDeepStrictEqual:ce}},7991:function(e,t){"use strict";t.byteLength=c,t.toByteArray=d,t.fromByteArray=f;for(var n=[],r=[],i="undefined"!==typeof Uint8Array?Uint8Array:Array,o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,s=o.length;a<s;++a)n[a]=o[a],r[o.charCodeAt(a)]=a;function l(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");-1===n&&(n=t);var r=n===t?0:4-n%4;return[n,r]}function c(e){var t=l(e),n=t[0],r=t[1];return 3*(n+r)/4-r}function u(e,t,n){return 3*(t+n)/4-n}function d(e){var t,n,o=l(e),a=o[0],s=o[1],c=new i(u(e,a,s)),d=0,h=s>0?a-4:a;for(n=0;n<h;n+=4)t=r[e.charCodeAt(n)]<<18|r[e.charCodeAt(n+1)]<<12|r[e.charCodeAt(n+2)]<<6|r[e.charCodeAt(n+3)],c[d++]=t>>16&255,c[d++]=t>>8&255,c[d++]=255&t;return 2===s&&(t=r[e.charCodeAt(n)]<<2|r[e.charCodeAt(n+1)]>>4,c[d++]=255&t),1===s&&(t=r[e.charCodeAt(n)]<<10|r[e.charCodeAt(n+1)]<<4|r[e.charCodeAt(n+2)]>>2,c[d++]=t>>8&255,c[d++]=255&t),c}function h(e){return n[e>>18&63]+n[e>>12&63]+n[e>>6&63]+n[63&e]}function p(e,t,n){for(var r,i=[],o=t;o<n;o+=3)r=(e[o]<<16&16711680)+(e[o+1]<<8&65280)+(255&e[o+2]),i.push(h(r));return i.join("")}function f(e){for(var t,r=e.length,i=r%3,o=[],a=16383,s=0,l=r-i;s<l;s+=a)o.push(p(e,s,s+a>l?l:s+a));return 1===i?(t=e[r-1],o.push(n[t>>2]+n[t<<4&63]+"==")):2===i&&(t=(e[r-2]<<8)+e[r-1],o.push(n[t>>10]+n[t>>4&63]+n[t<<2&63]+"=")),o.join("")}r["-".charCodeAt(0)]=62,r["_".charCodeAt(0)]=63},1048:function(e,t,n){"use strict";var r=n(4364);
|
||
/*!
|
||
* The buffer module from node.js, for the browser.
|
||
*
|
||
* @author Feross Aboukhadijeh <https://feross.org>
|
||
* @license MIT
|
||
*/const i=n(7991),o=n(39318),a="function"===typeof Symbol&&"function"===typeof Symbol["for"]?Symbol["for"]("nodejs.util.inspect.custom"):null;t.Buffer=u,t.SlowBuffer=O,t.INSPECT_MAX_BYTES=50;const s=2147483647;function l(){try{const e=new Uint8Array(1),t={foo:function(){return 42}};return Object.setPrototypeOf(t,Uint8Array.prototype),Object.setPrototypeOf(e,t),42===e.foo()}catch(e){return!1}}function c(e){if(e>s)throw new RangeError('The value "'+e+'" is invalid for option "size"');const t=new Uint8Array(e);return Object.setPrototypeOf(t,u.prototype),t}function u(e,t,n){if("number"===typeof e){if("string"===typeof t)throw new TypeError('The "string" argument must be of type string. Received type number');return f(e)}return d(e,t,n)}function d(e,t,n){if("string"===typeof e)return m(e,t);if(ArrayBuffer.isView(e))return v(e);if(null==e)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(se(e,ArrayBuffer)||e&&se(e.buffer,ArrayBuffer))return b(e,t,n);if("undefined"!==typeof SharedArrayBuffer&&(se(e,SharedArrayBuffer)||e&&se(e.buffer,SharedArrayBuffer)))return b(e,t,n);if("number"===typeof e)throw new TypeError('The "value" argument must not be of type number. Received type number');const r=e.valueOf&&e.valueOf();if(null!=r&&r!==e)return u.from(r,t,n);const i=y(e);if(i)return i;if("undefined"!==typeof Symbol&&null!=Symbol.toPrimitive&&"function"===typeof e[Symbol.toPrimitive])return u.from(e[Symbol.toPrimitive]("string"),t,n);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e)}function h(e){if("number"!==typeof e)throw new TypeError('"size" argument must be of type number');if(e<0)throw new RangeError('The value "'+e+'" is invalid for option "size"')}function p(e,t,n){return h(e),e<=0?c(e):void 0!==t?"string"===typeof n?c(e).fill(t,n):c(e).fill(t):c(e)}function f(e){return h(e),c(e<0?0:0|w(e))}function m(e,t){if("string"===typeof t&&""!==t||(t="utf8"),!u.isEncoding(t))throw new TypeError("Unknown encoding: "+t);const n=0|S(e,t);let r=c(n);const i=r.write(e,t);return i!==n&&(r=r.slice(0,i)),r}function g(e){const t=e.length<0?0:0|w(e.length),n=c(t);for(let r=0;r<t;r+=1)n[r]=255&e[r];return n}function v(e){if(se(e,Uint8Array)){const t=new Uint8Array(e);return b(t.buffer,t.byteOffset,t.byteLength)}return g(e)}function b(e,t,n){if(t<0||e.byteLength<t)throw new RangeError('"offset" is outside of buffer bounds');if(e.byteLength<t+(n||0))throw new RangeError('"length" is outside of buffer bounds');let r;return r=void 0===t&&void 0===n?new Uint8Array(e):void 0===n?new Uint8Array(e,t):new Uint8Array(e,t,n),Object.setPrototypeOf(r,u.prototype),r}function y(e){if(u.isBuffer(e)){const t=0|w(e.length),n=c(t);return 0===n.length||e.copy(n,0,0,t),n}return void 0!==e.length?"number"!==typeof e.length||le(e.length)?c(0):g(e):"Buffer"===e.type&&Array.isArray(e.data)?g(e.data):void 0}function w(e){if(e>=s)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s.toString(16)+" bytes");return 0|e}function O(e){return+e!=e&&(e=0),u.alloc(+e)}function S(e,t){if(u.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||se(e,ArrayBuffer))return e.byteLength;if("string"!==typeof e)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);const n=e.length,r=arguments.length>2&&!0===arguments[2];if(!r&&0===n)return 0;let i=!1;for(;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":return ne(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return oe(e).length;default:if(i)return r?-1:ne(e).length;t=(""+t).toLowerCase(),i=!0}}function E(e,t,n){let r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if(n>>>=0,t>>>=0,n<=t)return"";e||(e="utf8");while(1)switch(e){case"hex":return $(this,t,n);case"utf8":case"utf-8":return I(this,t,n);case"ascii":return L(this,t,n);case"latin1":case"binary":return B(this,t,n);case"base64":return P(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return V(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function x(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function _(e,t,n,r,i){if(0===e.length)return-1;if("string"===typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,le(n)&&(n=i?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(i)return-1;n=e.length-1}else if(n<0){if(!i)return-1;n=0}if("string"===typeof t&&(t=u.from(t,r)),u.isBuffer(t))return 0===t.length?-1:k(e,t,n,r,i);if("number"===typeof t)return t&=255,"function"===typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):k(e,[t],n,r,i);throw new TypeError("val must be string, number or Buffer")}function k(e,t,n,r,i){let o,a=1,s=e.length,l=t.length;if(void 0!==r&&(r=String(r).toLowerCase(),"ucs2"===r||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;a=2,s/=2,l/=2,n/=2}function c(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(i){let r=-1;for(o=n;o<s;o++)if(c(e,o)===c(t,-1===r?0:o-r)){if(-1===r&&(r=o),o-r+1===l)return r*a}else-1!==r&&(o-=o-r),r=-1}else for(n+l>s&&(n=s-l),o=n;o>=0;o--){let n=!0;for(let r=0;r<l;r++)if(c(e,o+r)!==c(t,r)){n=!1;break}if(n)return o}return-1}function C(e,t,n,r){n=Number(n)||0;const i=e.length-n;r?(r=Number(r),r>i&&(r=i)):r=i;const o=t.length;let a;for(r>o/2&&(r=o/2),a=0;a<r;++a){const r=parseInt(t.substr(2*a,2),16);if(le(r))return a;e[n+a]=r}return a}function A(e,t,n,r){return ae(ne(t,e.length-n),e,n,r)}function T(e,t,n,r){return ae(re(t),e,n,r)}function R(e,t,n,r){return ae(oe(t),e,n,r)}function N(e,t,n,r){return ae(ie(t,e.length-n),e,n,r)}function P(e,t,n){return 0===t&&n===e.length?i.fromByteArray(e):i.fromByteArray(e.slice(t,n))}function I(e,t,n){n=Math.min(e.length,n);const r=[];let i=t;while(i<n){const t=e[i];let o=null,a=t>239?4:t>223?3:t>191?2:1;if(i+a<=n){let n,r,s,l;switch(a){case 1:t<128&&(o=t);break;case 2:n=e[i+1],128===(192&n)&&(l=(31&t)<<6|63&n,l>127&&(o=l));break;case 3:n=e[i+1],r=e[i+2],128===(192&n)&&128===(192&r)&&(l=(15&t)<<12|(63&n)<<6|63&r,l>2047&&(l<55296||l>57343)&&(o=l));break;case 4:n=e[i+1],r=e[i+2],s=e[i+3],128===(192&n)&&128===(192&r)&&128===(192&s)&&(l=(15&t)<<18|(63&n)<<12|(63&r)<<6|63&s,l>65535&&l<1114112&&(o=l))}}null===o?(o=65533,a=1):o>65535&&(o-=65536,r.push(o>>>10&1023|55296),o=56320|1023&o),r.push(o),i+=a}return D(r)}t.kMaxLength=s,u.TYPED_ARRAY_SUPPORT=l(),u.TYPED_ARRAY_SUPPORT||"undefined"===typeof r||"function"!==typeof r.error||r.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(u.prototype,"parent",{enumerable:!0,get:function(){if(u.isBuffer(this))return this.buffer}}),Object.defineProperty(u.prototype,"offset",{enumerable:!0,get:function(){if(u.isBuffer(this))return this.byteOffset}}),u.poolSize=8192,u.from=function(e,t,n){return d(e,t,n)},Object.setPrototypeOf(u.prototype,Uint8Array.prototype),Object.setPrototypeOf(u,Uint8Array),u.alloc=function(e,t,n){return p(e,t,n)},u.allocUnsafe=function(e){return f(e)},u.allocUnsafeSlow=function(e){return f(e)},u.isBuffer=function(e){return null!=e&&!0===e._isBuffer&&e!==u.prototype},u.compare=function(e,t){if(se(e,Uint8Array)&&(e=u.from(e,e.offset,e.byteLength)),se(t,Uint8Array)&&(t=u.from(t,t.offset,t.byteLength)),!u.isBuffer(e)||!u.isBuffer(t))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(e===t)return 0;let n=e.length,r=t.length;for(let i=0,o=Math.min(n,r);i<o;++i)if(e[i]!==t[i]){n=e[i],r=t[i];break}return n<r?-1:r<n?1:0},u.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},u.concat=function(e,t){if(!Array.isArray(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return u.alloc(0);let n;if(void 0===t)for(t=0,n=0;n<e.length;++n)t+=e[n].length;const r=u.allocUnsafe(t);let i=0;for(n=0;n<e.length;++n){let t=e[n];if(se(t,Uint8Array))i+t.length>r.length?(u.isBuffer(t)||(t=u.from(t)),t.copy(r,i)):Uint8Array.prototype.set.call(r,t,i);else{if(!u.isBuffer(t))throw new TypeError('"list" argument must be an Array of Buffers');t.copy(r,i)}i+=t.length}return r},u.byteLength=S,u.prototype._isBuffer=!0,u.prototype.swap16=function(){const e=this.length;if(e%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let t=0;t<e;t+=2)x(this,t,t+1);return this},u.prototype.swap32=function(){const e=this.length;if(e%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let t=0;t<e;t+=4)x(this,t,t+3),x(this,t+1,t+2);return this},u.prototype.swap64=function(){const e=this.length;if(e%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let t=0;t<e;t+=8)x(this,t,t+7),x(this,t+1,t+6),x(this,t+2,t+5),x(this,t+3,t+4);return this},u.prototype.toString=function(){const e=this.length;return 0===e?"":0===arguments.length?I(this,0,e):E.apply(this,arguments)},u.prototype.toLocaleString=u.prototype.toString,u.prototype.equals=function(e){if(!u.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===u.compare(this,e)},u.prototype.inspect=function(){let e="";const n=t.INSPECT_MAX_BYTES;return e=this.toString("hex",0,n).replace(/(.{2})/g,"$1 ").trim(),this.length>n&&(e+=" ... "),"<Buffer "+e+">"},a&&(u.prototype[a]=u.prototype.inspect),u.prototype.compare=function(e,t,n,r,i){if(se(e,Uint8Array)&&(e=u.from(e,e.offset,e.byteLength)),!u.isBuffer(e))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===i&&(i=this.length),t<0||n>e.length||r<0||i>this.length)throw new RangeError("out of range index");if(r>=i&&t>=n)return 0;if(r>=i)return-1;if(t>=n)return 1;if(t>>>=0,n>>>=0,r>>>=0,i>>>=0,this===e)return 0;let o=i-r,a=n-t;const s=Math.min(o,a),l=this.slice(r,i),c=e.slice(t,n);for(let u=0;u<s;++u)if(l[u]!==c[u]){o=l[u],a=c[u];break}return o<a?-1:a<o?1:0},u.prototype.includes=function(e,t,n){return-1!==this.indexOf(e,t,n)},u.prototype.indexOf=function(e,t,n){return _(this,e,t,n,!0)},u.prototype.lastIndexOf=function(e,t,n){return _(this,e,t,n,!1)},u.prototype.write=function(e,t,n,r){if(void 0===t)r="utf8",n=this.length,t=0;else if(void 0===n&&"string"===typeof t)r=t,n=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t>>>=0,isFinite(n)?(n>>>=0,void 0===r&&(r="utf8")):(r=n,n=void 0)}const i=this.length-t;if((void 0===n||n>i)&&(n=i),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");let o=!1;for(;;)switch(r){case"hex":return C(this,e,t,n);case"utf8":case"utf-8":return A(this,e,t,n);case"ascii":case"latin1":case"binary":return T(this,e,t,n);case"base64":return R(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return N(this,e,t,n);default:if(o)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),o=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};const M=4096;function D(e){const t=e.length;if(t<=M)return String.fromCharCode.apply(String,e);let n="",r=0;while(r<t)n+=String.fromCharCode.apply(String,e.slice(r,r+=M));return n}function L(e,t,n){let r="";n=Math.min(e.length,n);for(let i=t;i<n;++i)r+=String.fromCharCode(127&e[i]);return r}function B(e,t,n){let r="";n=Math.min(e.length,n);for(let i=t;i<n;++i)r+=String.fromCharCode(e[i]);return r}function $(e,t,n){const r=e.length;(!t||t<0)&&(t=0),(!n||n<0||n>r)&&(n=r);let i="";for(let o=t;o<n;++o)i+=ce[e[o]];return i}function V(e,t,n){const r=e.slice(t,n);let i="";for(let o=0;o<r.length-1;o+=2)i+=String.fromCharCode(r[o]+256*r[o+1]);return i}function F(e,t,n){if(e%1!==0||e<0)throw new RangeError("offset is not uint");if(e+t>n)throw new RangeError("Trying to access beyond buffer length")}function j(e,t,n,r,i,o){if(!u.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>i||t<o)throw new RangeError('"value" argument is out of bounds');if(n+r>e.length)throw new RangeError("Index out of range")}function U(e,t,n,r,i){Y(t,r,i,e,n,7);let o=Number(t&BigInt(4294967295));e[n++]=o,o>>=8,e[n++]=o,o>>=8,e[n++]=o,o>>=8,e[n++]=o;let a=Number(t>>BigInt(32)&BigInt(4294967295));return e[n++]=a,a>>=8,e[n++]=a,a>>=8,e[n++]=a,a>>=8,e[n++]=a,n}function G(e,t,n,r,i){Y(t,r,i,e,n,7);let o=Number(t&BigInt(4294967295));e[n+7]=o,o>>=8,e[n+6]=o,o>>=8,e[n+5]=o,o>>=8,e[n+4]=o;let a=Number(t>>BigInt(32)&BigInt(4294967295));return e[n+3]=a,a>>=8,e[n+2]=a,a>>=8,e[n+1]=a,a>>=8,e[n]=a,n+8}function H(e,t,n,r,i,o){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function q(e,t,n,r,i){return t=+t,n>>>=0,i||H(e,t,n,4,34028234663852886e22,-34028234663852886e22),o.write(e,t,n,r,23,4),n+4}function Q(e,t,n,r,i){return t=+t,n>>>=0,i||H(e,t,n,8,17976931348623157e292,-17976931348623157e292),o.write(e,t,n,r,52,8),n+8}u.prototype.slice=function(e,t){const n=this.length;e=~~e,t=void 0===t?n:~~t,e<0?(e+=n,e<0&&(e=0)):e>n&&(e=n),t<0?(t+=n,t<0&&(t=0)):t>n&&(t=n),t<e&&(t=e);const r=this.subarray(e,t);return Object.setPrototypeOf(r,u.prototype),r},u.prototype.readUintLE=u.prototype.readUIntLE=function(e,t,n){e>>>=0,t>>>=0,n||F(e,t,this.length);let r=this[e],i=1,o=0;while(++o<t&&(i*=256))r+=this[e+o]*i;return r},u.prototype.readUintBE=u.prototype.readUIntBE=function(e,t,n){e>>>=0,t>>>=0,n||F(e,t,this.length);let r=this[e+--t],i=1;while(t>0&&(i*=256))r+=this[e+--t]*i;return r},u.prototype.readUint8=u.prototype.readUInt8=function(e,t){return e>>>=0,t||F(e,1,this.length),this[e]},u.prototype.readUint16LE=u.prototype.readUInt16LE=function(e,t){return e>>>=0,t||F(e,2,this.length),this[e]|this[e+1]<<8},u.prototype.readUint16BE=u.prototype.readUInt16BE=function(e,t){return e>>>=0,t||F(e,2,this.length),this[e]<<8|this[e+1]},u.prototype.readUint32LE=u.prototype.readUInt32LE=function(e,t){return e>>>=0,t||F(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},u.prototype.readUint32BE=u.prototype.readUInt32BE=function(e,t){return e>>>=0,t||F(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},u.prototype.readBigUInt64LE=ue(function(e){e>>>=0,Z(e,"offset");const t=this[e],n=this[e+7];void 0!==t&&void 0!==n||J(e,this.length-8);const r=t+256*this[++e]+65536*this[++e]+this[++e]*2**24,i=this[++e]+256*this[++e]+65536*this[++e]+n*2**24;return BigInt(r)+(BigInt(i)<<BigInt(32))}),u.prototype.readBigUInt64BE=ue(function(e){e>>>=0,Z(e,"offset");const t=this[e],n=this[e+7];void 0!==t&&void 0!==n||J(e,this.length-8);const r=t*2**24+65536*this[++e]+256*this[++e]+this[++e],i=this[++e]*2**24+65536*this[++e]+256*this[++e]+n;return(BigInt(r)<<BigInt(32))+BigInt(i)}),u.prototype.readIntLE=function(e,t,n){e>>>=0,t>>>=0,n||F(e,t,this.length);let r=this[e],i=1,o=0;while(++o<t&&(i*=256))r+=this[e+o]*i;return i*=128,r>=i&&(r-=Math.pow(2,8*t)),r},u.prototype.readIntBE=function(e,t,n){e>>>=0,t>>>=0,n||F(e,t,this.length);let r=t,i=1,o=this[e+--r];while(r>0&&(i*=256))o+=this[e+--r]*i;return i*=128,o>=i&&(o-=Math.pow(2,8*t)),o},u.prototype.readInt8=function(e,t){return e>>>=0,t||F(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},u.prototype.readInt16LE=function(e,t){e>>>=0,t||F(e,2,this.length);const n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},u.prototype.readInt16BE=function(e,t){e>>>=0,t||F(e,2,this.length);const n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},u.prototype.readInt32LE=function(e,t){return e>>>=0,t||F(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},u.prototype.readInt32BE=function(e,t){return e>>>=0,t||F(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},u.prototype.readBigInt64LE=ue(function(e){e>>>=0,Z(e,"offset");const t=this[e],n=this[e+7];void 0!==t&&void 0!==n||J(e,this.length-8);const r=this[e+4]+256*this[e+5]+65536*this[e+6]+(n<<24);return(BigInt(r)<<BigInt(32))+BigInt(t+256*this[++e]+65536*this[++e]+this[++e]*2**24)}),u.prototype.readBigInt64BE=ue(function(e){e>>>=0,Z(e,"offset");const t=this[e],n=this[e+7];void 0!==t&&void 0!==n||J(e,this.length-8);const r=(t<<24)+65536*this[++e]+256*this[++e]+this[++e];return(BigInt(r)<<BigInt(32))+BigInt(this[++e]*2**24+65536*this[++e]+256*this[++e]+n)}),u.prototype.readFloatLE=function(e,t){return e>>>=0,t||F(e,4,this.length),o.read(this,e,!0,23,4)},u.prototype.readFloatBE=function(e,t){return e>>>=0,t||F(e,4,this.length),o.read(this,e,!1,23,4)},u.prototype.readDoubleLE=function(e,t){return e>>>=0,t||F(e,8,this.length),o.read(this,e,!0,52,8)},u.prototype.readDoubleBE=function(e,t){return e>>>=0,t||F(e,8,this.length),o.read(this,e,!1,52,8)},u.prototype.writeUintLE=u.prototype.writeUIntLE=function(e,t,n,r){if(e=+e,t>>>=0,n>>>=0,!r){const r=Math.pow(2,8*n)-1;j(this,e,t,n,r,0)}let i=1,o=0;this[t]=255&e;while(++o<n&&(i*=256))this[t+o]=e/i&255;return t+n},u.prototype.writeUintBE=u.prototype.writeUIntBE=function(e,t,n,r){if(e=+e,t>>>=0,n>>>=0,!r){const r=Math.pow(2,8*n)-1;j(this,e,t,n,r,0)}let i=n-1,o=1;this[t+i]=255&e;while(--i>=0&&(o*=256))this[t+i]=e/o&255;return t+n},u.prototype.writeUint8=u.prototype.writeUInt8=function(e,t,n){return e=+e,t>>>=0,n||j(this,e,t,1,255,0),this[t]=255&e,t+1},u.prototype.writeUint16LE=u.prototype.writeUInt16LE=function(e,t,n){return e=+e,t>>>=0,n||j(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},u.prototype.writeUint16BE=u.prototype.writeUInt16BE=function(e,t,n){return e=+e,t>>>=0,n||j(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},u.prototype.writeUint32LE=u.prototype.writeUInt32LE=function(e,t,n){return e=+e,t>>>=0,n||j(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},u.prototype.writeUint32BE=u.prototype.writeUInt32BE=function(e,t,n){return e=+e,t>>>=0,n||j(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},u.prototype.writeBigUInt64LE=ue(function(e,t=0){return U(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))}),u.prototype.writeBigUInt64BE=ue(function(e,t=0){return G(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))}),u.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t>>>=0,!r){const r=Math.pow(2,8*n-1);j(this,e,t,n,r-1,-r)}let i=0,o=1,a=0;this[t]=255&e;while(++i<n&&(o*=256))e<0&&0===a&&0!==this[t+i-1]&&(a=1),this[t+i]=(e/o|0)-a&255;return t+n},u.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t>>>=0,!r){const r=Math.pow(2,8*n-1);j(this,e,t,n,r-1,-r)}let i=n-1,o=1,a=0;this[t+i]=255&e;while(--i>=0&&(o*=256))e<0&&0===a&&0!==this[t+i+1]&&(a=1),this[t+i]=(e/o|0)-a&255;return t+n},u.prototype.writeInt8=function(e,t,n){return e=+e,t>>>=0,n||j(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},u.prototype.writeInt16LE=function(e,t,n){return e=+e,t>>>=0,n||j(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},u.prototype.writeInt16BE=function(e,t,n){return e=+e,t>>>=0,n||j(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},u.prototype.writeInt32LE=function(e,t,n){return e=+e,t>>>=0,n||j(this,e,t,4,2147483647,-2147483648),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},u.prototype.writeInt32BE=function(e,t,n){return e=+e,t>>>=0,n||j(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},u.prototype.writeBigInt64LE=ue(function(e,t=0){return U(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),u.prototype.writeBigInt64BE=ue(function(e,t=0){return G(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),u.prototype.writeFloatLE=function(e,t,n){return q(this,e,t,!0,n)},u.prototype.writeFloatBE=function(e,t,n){return q(this,e,t,!1,n)},u.prototype.writeDoubleLE=function(e,t,n){return Q(this,e,t,!0,n)},u.prototype.writeDoubleBE=function(e,t,n){return Q(this,e,t,!1,n)},u.prototype.copy=function(e,t,n,r){if(!u.isBuffer(e))throw new TypeError("argument should be a Buffer");if(n||(n=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r<n&&(r=n),r===n)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(n<0||n>=this.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t<r-n&&(r=e.length-t+n);const i=r-n;return this===e&&"function"===typeof Uint8Array.prototype.copyWithin?this.copyWithin(t,n,r):Uint8Array.prototype.set.call(e,this.subarray(n,r),t),i},u.prototype.fill=function(e,t,n,r){if("string"===typeof e){if("string"===typeof t?(r=t,t=0,n=this.length):"string"===typeof n&&(r=n,n=this.length),void 0!==r&&"string"!==typeof r)throw new TypeError("encoding must be a string");if("string"===typeof r&&!u.isEncoding(r))throw new TypeError("Unknown encoding: "+r);if(1===e.length){const t=e.charCodeAt(0);("utf8"===r&&t<128||"latin1"===r)&&(e=t)}}else"number"===typeof e?e&=255:"boolean"===typeof e&&(e=Number(e));if(t<0||this.length<t||this.length<n)throw new RangeError("Out of range index");if(n<=t)return this;let i;if(t>>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"===typeof e)for(i=t;i<n;++i)this[i]=e;else{const o=u.isBuffer(e)?e:u.from(e,r),a=o.length;if(0===a)throw new TypeError('The value "'+e+'" is invalid for argument "value"');for(i=0;i<n-t;++i)this[i+t]=o[i%a]}return this};const z={};function K(e,t,n){z[e]=class extends n{constructor(){super(),Object.defineProperty(this,"message",{value:t.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${e}]`,this.stack,delete this.name}get code(){return e}set code(e){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:e,writable:!0})}toString(){return`${this.name} [${e}]: ${this.message}`}}}function W(e){let t="",n=e.length;const r="-"===e[0]?1:0;for(;n>=r+4;n-=3)t=`_${e.slice(n-3,n)}${t}`;return`${e.slice(0,n)}${t}`}function X(e,t,n){Z(t,"offset"),void 0!==e[t]&&void 0!==e[t+n]||J(t,e.length-(n+1))}function Y(e,t,n,r,i,o){if(e>n||e<t){const r="bigint"===typeof t?"n":"";let i;throw i=o>3?0===t||t===BigInt(0)?`>= 0${r} and < 2${r} ** ${8*(o+1)}${r}`:`>= -(2${r} ** ${8*(o+1)-1}${r}) and < 2 ** ${8*(o+1)-1}${r}`:`>= ${t}${r} and <= ${n}${r}`,new z.ERR_OUT_OF_RANGE("value",i,e)}X(r,i,o)}function Z(e,t){if("number"!==typeof e)throw new z.ERR_INVALID_ARG_TYPE(t,"number",e)}function J(e,t,n){if(Math.floor(e)!==e)throw Z(e,n),new z.ERR_OUT_OF_RANGE(n||"offset","an integer",e);if(t<0)throw new z.ERR_BUFFER_OUT_OF_BOUNDS;throw new z.ERR_OUT_OF_RANGE(n||"offset",`>= ${n?1:0} and <= ${t}`,e)}K("ERR_BUFFER_OUT_OF_BOUNDS",function(e){return e?`${e} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"},RangeError),K("ERR_INVALID_ARG_TYPE",function(e,t){return`The "${e}" argument must be of type number. Received type ${typeof t}`},TypeError),K("ERR_OUT_OF_RANGE",function(e,t,n){let r=`The value of "${e}" is out of range.`,i=n;return Number.isInteger(n)&&Math.abs(n)>2**32?i=W(String(n)):"bigint"===typeof n&&(i=String(n),(n>BigInt(2)**BigInt(32)||n<-(BigInt(2)**BigInt(32)))&&(i=W(i)),i+="n"),r+=` It must be ${t}. Received ${i}`,r},RangeError);const ee=/[^+/0-9A-Za-z-_]/g;function te(e){if(e=e.split("=")[0],e=e.trim().replace(ee,""),e.length<2)return"";while(e.length%4!==0)e+="=";return e}function ne(e,t){let n;t=t||1/0;const r=e.length;let i=null;const o=[];for(let a=0;a<r;++a){if(n=e.charCodeAt(a),n>55295&&n<57344){if(!i){if(n>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(a+1===r){(t-=3)>-1&&o.push(239,191,189);continue}i=n;continue}if(n<56320){(t-=3)>-1&&o.push(239,191,189),i=n;continue}n=65536+(i-55296<<10|n-56320)}else i&&(t-=3)>-1&&o.push(239,191,189);if(i=null,n<128){if((t-=1)<0)break;o.push(n)}else if(n<2048){if((t-=2)<0)break;o.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;o.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return o}function re(e){const t=[];for(let n=0;n<e.length;++n)t.push(255&e.charCodeAt(n));return t}function ie(e,t){let n,r,i;const o=[];for(let a=0;a<e.length;++a){if((t-=2)<0)break;n=e.charCodeAt(a),r=n>>8,i=n%256,o.push(i),o.push(r)}return o}function oe(e){return i.toByteArray(te(e))}function ae(e,t,n,r){let i;for(i=0;i<r;++i){if(i+n>=t.length||i>=e.length)break;t[i+n]=e[i]}return i}function se(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}function le(e){return e!==e}const ce=function(){const e="0123456789abcdef",t=new Array(256);for(let n=0;n<16;++n){const r=16*n;for(let i=0;i<16;++i)t[r+i]=e[n]+e[i]}return t}();function ue(e){return"undefined"===typeof BigInt?de:e}function de(){throw new Error("BigInt not supported")}},30049:function(e){e.exports={100:"Continue",101:"Switching Protocols",102:"Processing",200:"OK",201:"Created",202:"Accepted",203:"Non-Authoritative Information",204:"No Content",205:"Reset Content",206:"Partial Content",207:"Multi-Status",208:"Already Reported",226:"IM Used",300:"Multiple Choices",301:"Moved Permanently",302:"Found",303:"See Other",304:"Not Modified",305:"Use Proxy",307:"Temporary Redirect",308:"Permanent Redirect",400:"Bad Request",401:"Unauthorized",402:"Payment Required",403:"Forbidden",404:"Not Found",405:"Method Not Allowed",406:"Not Acceptable",407:"Proxy Authentication Required",408:"Request Timeout",409:"Conflict",410:"Gone",411:"Length Required",412:"Precondition Failed",413:"Payload Too Large",414:"URI Too Long",415:"Unsupported Media Type",416:"Range Not Satisfiable",417:"Expectation Failed",418:"I'm a teapot",421:"Misdirected Request",422:"Unprocessable Entity",423:"Locked",424:"Failed Dependency",425:"Unordered Collection",426:"Upgrade Required",428:"Precondition Required",429:"Too Many Requests",431:"Request Header Fields Too Large",451:"Unavailable For Legal Reasons",500:"Internal Server Error",501:"Not Implemented",502:"Bad Gateway",503:"Service Unavailable",504:"Gateway Timeout",505:"HTTP Version Not Supported",506:"Variant Also Negotiates",507:"Insufficient Storage",508:"Loop Detected",509:"Bandwidth Limit Exceeded",510:"Not Extended",511:"Network Authentication Required"}},89366:function(e,t,n){"use strict";async function r(e){let t;const n={headers:{accept:"application/yaml"}};return e.hasLink("view")&&(t=(await e.followLink("view",n)).data),e.cleanForDownload(t)}n.d(t,{Ep:function(){return l},nx:function(){return s},R7:function(){return d},te:function(){return u}});var i=n(9274),o=n(65359),a=n(4364);async function s(e){try{if(!e.canYaml)return;const t=await r(e);return{resource:e,yaml:t}}catch(t){a.warn(`Could not determine/fetch yaml for '${null===e||void 0===e?void 0:e.type}'`,t)}}function l(e){const t=(0,o.Pj)();if(t.getters["type-map/hasCustomEdit"](e.type)&&t.getters["type-map/hasCustomDetail"](e.type)&&!e.disableResourceDetailDrawerConfigTab)return{resource:e,component:t.getters["type-map/importEdit"](e.type),resourceType:e.type}}const c="isInResourceDetailDrawerKey";function u(){(0,i.provide)(c,!0)}function d(){return(0,i.inject)(c,!1)}},6855:function(e,t,n){"use strict";n.d(t,{G:function(){return o},t:function(){return a}});var r=n(8187),i=n(73883);function o(e,t,n="stateSimpleColor",i="stateDisplay",o){const a={};t.forEach(e=>{const t=e[i]?.toLowerCase(),o=e[n]||"disabled";a[t]=a[t]||{color:o,label:t,count:0},(0,r.Ky)(o,a[t].color)&&(a[t].color=o),a[t].count++});const s=Object.values(a);return s.sort((e,t)=>(0,r.Ky)(e.color,t.color)?-1:e.color!==t.color?1:e.count===t.count?0:e.count>t.count?-1:1),{label:e,color:s.length?s[0].color:void 0,counts:s.length?s:void 0,to:o}}function a(e,t,n){const r=t.map(e=>{const t=e.state||i.jv.MISSING;return{stateDisplay:(0,i.ch)(t),stateSimpleColor:(0,i.Cb)(t,e.error,e.transitioning)}});return o(e,r,"stateSimpleColor","stateDisplay",n)}},95811:function(e,t,n){"use strict";n.d(t,{B:function(){return c},_:function(){return l}});var r=n(12784),i=n.n(r),o=n(92043),a=n(9274);const s=Symbol("formSummary");function l(e){const t=(0,a.ref)({}),n=(0,a.ref)([]),r=(e=[],n,i=new Set)=>{var o,a,s,l;let c=e;const u=(null===n||void 0===n?void 0:n.el)?(null===(o=null===n||void 0===n?void 0:n.el)||void 0===o?void 0:o.summaryID)||"":(null===n||void 0===n?void 0:n.summaryID)||"",h=t.value[u],p=null===h||void 0===h?void 0:h.summary;if(h&&p&&t.value[p.id]&&!i.has(p.id)){i.add(p.id);const t={node:n,children:[],...p,scrollTo:h?()=>d(h):void 0};t.component=h,e.push(t),c=t.children}if(!n)return;const f=n.el?Array.from(null!==(s=null===(a=n.el)||void 0===a?void 0:a.children)&&void 0!==s?s:[]):Array.from(null!==(l=n.children)&&void 0!==l?l:[]);return f.forEach(e=>{r(c,e,i)}),e},o=()=>{(null===e||void 0===e?void 0:e.value)?n.value=r([],e.value)||[]:n.value=[]},l=i()(o);(0,a.onMounted)(()=>{l()});const c=e=>{const t=(n=[],r=null)=>{var i,o,a,s;for(const l of n){if((null===(o=null===(i=null===l||void 0===l?void 0:l.component)||void 0===i?void 0:i.summary)||void 0===o?void 0:o.id)===(null===(a=null===e||void 0===e?void 0:e.summary)||void 0===a?void 0:a.id))return r;if(null===(s=null===l||void 0===l?void 0:l.children)||void 0===s?void 0:s.length){const e=t(l.children,l);if(e)return e}}return null};return t(n.value)},u=(e,t)=>{const r=(n=[])=>{var i,o,a;for(const s of n){if((null===(o=null===(i=null===s||void 0===s?void 0:s.component)||void 0===i?void 0:i.summary)||void 0===o?void 0:o.id)===e)return s.label=t,!0;if((null===(a=null===s||void 0===s?void 0:s.children)||void 0===a?void 0:a.length)&&r(s.children))return!0}return!1};return r(n.value)},d=e=>{var t;const n=c(e);(null===n||void 0===n?void 0:n.component)&&d(n.component),(null===(t=null===e||void 0===e?void 0:e.summary)||void 0===t?void 0:t.scrollTo)&&e.summary.scrollTo()},h=e=>{var n,r;e&&(null===(n=e.summary)||void 0===n?void 0:n.id)&&(t.value[null===(r=e.summary)||void 0===r?void 0:r.id]=e,l())},p=e=>{var n,r;e&&(null===(n=e.summary)||void 0===n?void 0:n.id)&&(delete t.value[null===(r=e.summary)||void 0===r?void 0:r.id],l())};return(0,a.provide)(s,{registerComponent:h,unRegisterComponent:p,refreshComponents:l,updateComponentLabel:u}),{locatedComponents:n}}function c(e){const{registerComponent:t=()=>{},unRegisterComponent:n=()=>{},refreshComponents:r=()=>{},updateComponentLabel:i=()=>!1}=(0,a.inject)(s)||{},{scrollTo:l,label:c,elementRef:u}=e,d=(0,o.vx)(),h={id:d,scrollTo:l};return h.label="string"===typeof c?(0,a.computed)(()=>c):c,(0,a.watch)(h.label,e=>{const t=i(d,e);t||r()}),(0,a.onMounted)(()=>{u.value&&(u.value.summaryID=d),t({summary:h,summaryID:d})}),(0,a.onUnmounted)(()=>{const e={summary:h};n(e)}),{summary:h}}},44544:function(e,t,n){"use strict";n.d(t,{Dg:function(){return u},qz:function(){return c},wi:function(){return l}});var r=n(92043),i=n(45250),o=n(9274);const a="update-count",s="is-inside-resource-tabs",l=()=>{(0,o.provide)(s,!0)},c=()=>{if(!(0,o.inject)(s,!1))return{isCountVisible:(0,o.ref)(!1)};const e=(0,o.ref)({}),t=(0,o.computed)(()=>Object.keys(e.value).length>0),n=(0,o.computed)(()=>(0,i.sum)(Object.values(e.value).map(e=>e||0))),r=(t,n)=>{e.value[t]=n};return(0,o.provide)(a,r),{isCountVisible:t,count:n}},u=()=>{const e=(0,r.vx)(),t=(0,o.inject)(a,()=>{}),n=n=>{t(e,n)},i=()=>n(void 0);return{updateTabCount:n,clearTabCount:i}}},21342:function(e,t,n){"use strict";n.d(t,{Ay:function(){return T}});var r=n(35664),i=n(41476),o=n(10213),a=n(50025),s=n(85042),l=n(15092),c=n(88343),u=n(9274),d=n(12663),h=n(20926),p=n(75689),f=n(4364);class m{constructor(e){const{$store:t,id:n,enabledFor:r,onChange:i,formatResponse:o,saveCountAs:a}=e;this.$store=t,this.id=n,this.backOffId=`${this.id}`,this.enabledFor=r,this.onChange=i,this.classify=(null===o||void 0===o?void 0:o.classify)||!1,this.reactive=(null===o||void 0===o?void 0:o.reactive)||!1,this.saveCountAs=a,this.isEnabled=l.A.isEnabled({rootGetters:t.getters,$extension:this.$store.$extension},r)}async request(e){var t,n,r,i;const{pagination:o,forceWatch:a,revision:s}=e,l=null===(t=this.enabledFor.resource)||void 0===t?void 0:t.id;if(!this.isEnabled)throw new Error(`Wrapper for type '${this.enabledFor.store}/${l}' in context '${null===(n=this.enabledFor.resource)||void 0===n?void 0:n.context}' not supported`);const m=this.backOffId,g=null===(r=d.A.getBackOff(m))||void 0===r?void 0:r.metadata.revision,v=this.cachedRevision,b=new h.J(s),y=new h.J(g),w=new h.J(v),O=new h.J(g||v);if(O.isNewerThan(b)){if(y.isNewerThan(b))return f.info(`Ignoring event listener request to update '${this.id}' with revision '${b.revision}' (newer in-progress revision '${y.revision}'). `),Promise.reject(new Error("Ignoring current request in favour of other in-progress request with newer revision"));if(w.isNewerThan(b))return f.info(`Ignoring event listener request to update '${this.id}' with revision '${b.revision}' (newer cached revision '${w.revision}'). `),this.cachedResult?this.cachedResult:Promise.reject(new Error("Cache has higher revision than target revision... but no cached results?"))}b.isNewerThan(y)&&(f.info(`Dropping event listener request to update '${this.id}' with revision '${O.revision}' (newer target revision '${b.revision}'). `),d.A.reset(m));const S=await d.A.recurse({id:m,metadata:{revision:s},description:`Fetching resources for ${l} (wrapper). Initial request, or triggered by web socket`,continueOnError:async e=>400===(null===e||void 0===e?void 0:e.status)&&(null===e||void 0===e?void 0:e.code)===p.s.UNKNOWN_REVISION,delayedFn:async()=>{var e;const t={watch:!1,pagination:o,transient:!0,saveCountAs:this.saveCountAs,revision:s},n=await this.$store.dispatch(`${this.enabledFor.store}/findPage`,{opt:t,type:l});return this.cachedRevision=null===(e=n.pagination)||void 0===e?void 0:e.result.revision,n}});if(!S)throw new Error(`Wrapper for type '${this.enabledFor.store}/${l}' in context '${null===(i=this.enabledFor.resource)||void 0===i?void 0:i.context}' failed to fetch resources`);const E=!this.steveWatchParams;return this.onChange&&(E||a)&&(this.steveWatchParams={event:c.r.CHANGES,id:this.id,params:{type:l,mode:c.g.RESOURCE_CHANGES,force:a}},this.watch()),this.classify&&(S.data=await this.$store.dispatch(`${this.enabledFor.store}/createMany`,S.data)),this.reactive?this.cachedResult={...S,data:(0,u.reactive)(S.data)}:this.cachedResult=S,this.cachedResult}async watch(){if(!this.steveWatchParams)return void f.error("Calling watch but no watch params created");const e={...this.steveWatchParams,callback:this.onChange};await this.$store.dispatch(`${this.enabledFor.store}/watchEvent`,e)}async unWatch(){if(!this.steveWatchParams)return;const e={...this.steveWatchParams};await this.$store.dispatch(`${this.enabledFor.store}/unwatchEvent`,e)}async onDestroy(){await this.unWatch()}}var g=m,v=n(74302),b=n(4364);function y(e=[],t){return(Array.isArray(e)?e:[]).slice(0,t)}function w(e,t=[],n){const r=new Map(e.map(e=>[e.id,e]));return t.map(e=>r.get(e)).filter(e=>!!e).slice(0,n)}const O=2e3,S=6e4,E=[{asc:!1,field:"status.connected"},{asc:!0,field:"spec.displayName"}];class x{get pinnedPref(){return this.$store.getters["prefs/get"](i.Hu)||[]}get recentPref(){return this.$store.getters["prefs/get"](i._E)||[]}get cachedNonLocal(){return Object.values(this.clusterCache).filter(e=>!e.isLocal)}get clustersPinned(){return w(this.cachedNonLocal,this.pinnedPref,1/0)}get clustersRecent(){const e=y(this.recentPref,i.UK);return w(Object.values(this.clusterCache),e,i.ZX)}async refreshRecent(){}get clustersLocal(){const e=this.clusterCache[r.d_];return e?[e]:[]}syncPinnedFlags(e){const t=new Set(e||[]);Object.values(this.clusterCache).forEach(e=>{e.pinned=t.has(e.id)})}constructor({$store:e}){this.clusterCache=(0,u.reactive)({}),this.clustersOthers=(0,u.reactive)([]),this.counts=(0,u.reactive)({others:0,browsable:0}),this.$store=e}convertToCluster(e,t){const n={id:e.id,label:e.nameDisplay,ready:e.canExplore,providerNavLogo:e.providerMenuLogo,badge:e.badge,iconColor:e.iconColor,isLocal:e.isLocal,pinned:this.pinnedPref.includes(e.id),description:t?.description||e.description,stateDisplay:e.stateDisplay||"",providerDisplay:t?.provisionerDisplay||e.machineProviderDisplay||e.provider||"",kubernetesVersion:e.kubernetesVersionRaw||"",pin:()=>e.pin(),unpin:()=>e.unpin(),clusterRoute:{name:"c-cluster-explorer",params:{cluster:e.id}}},r=this.clusterCache[n.id];return r?(Object.assign(r,n),r):(this.clusterCache[n.id]=n,n)}}class _ extends x{constructor({$store:e}){super({$store:e}),this.recentClusters=(0,u.reactive)([]),this.recentSeq=0,this.othersPage=1,this.othersPages=0,this.othersResetting=0,this.othersSeq=0,this.clusterCount=null,this.countFilters=null,this.countRetries=0,this.countSeq=0,this.clustersContextWrapper=new g({$store:e,id:"top-level-menu-context-clusters",onChange:async()=>{if(this.args)try{await this.updateContext(this.args)}catch{}},enabledFor:{store:o.e.MANAGEMENT,resource:{id:r.Mc.CLUSTER,context:"side-bar"}},formatResponse:{classify:!0}}),this.clustersRecentWrapper=new g({$store:e,id:"top-level-menu-recent-clusters",enabledFor:{store:o.e.MANAGEMENT,resource:{id:r.Mc.CLUSTER,context:"side-bar"}},formatResponse:{classify:!0}}),this.clustersOthersWrapper=new g({$store:e,id:"top-level-menu-unpinned-clusters",enabledFor:{store:o.e.MANAGEMENT,resource:{id:r.Mc.CLUSTER,context:"side-bar"}},formatResponse:{classify:!0}})}async updateContext(e){const t=e.pinnedIds||[],n=Array.from(new Set([r.d_,...t])),i=await this.clustersContextWrapper.request({forceWatch:e.forceWatch,pagination:{filters:this.constructParams({ids:n,includeIds:!0}),page:1,sort:E,projectsOrNamespaces:[]},revision:e.mgmtClusterRevision}),o=new Set(i.data.map(e=>e.id));i.data.forEach(e=>this.convertToCluster(e)),n.forEach(e=>{o.has(e)||delete this.clusterCache[e]})}get clustersRecent(){return this.recentClusters}async refreshRecent(){const e=y(this.recentPref,i.UK),t=++this.recentSeq;if(!e.length)return void(this.recentClusters.length=0);const n=await this.clustersRecentWrapper.request({pagination:{filters:this.constructParams({ids:e,includeIds:!0}),page:1,pageSize:i.UK,sort:E,projectsOrNamespaces:[]}}),r=n.data.map(e=>this.convertToCluster(e));t===this.recentSeq&&(this.recentClusters.length=0,this.recentClusters.push(...w(r,e,i.ZX)))}async update(e){this.args=e,await this.updateContext(e).catch(e=>{b.warn("Unable to update the side nav cluster context (local/pinned)",e)})}async destroy(){this.countSeq+=1,clearTimeout(this.countRetryTimer),this.clustersContextWrapper.onDestroy(),this.clustersOthersWrapper.onDestroy(),this.clustersRecentWrapper.onDestroy()}constructParams({ids:e,searchTerm:t,includeSearchTerm:n,includeIds:r}){const i=(0,s.gF)({getters:this.$store.getters}),o=[...i];return e&&r&&o.push(a.eY.createMultipleFields(e.map(e=>({field:"id",value:e,equals:!0,exact:!0})))),t&&n&&o.push(a.eY.createSingleField({field:"spec.displayName",exact:!1,value:t})),o}async fetchOthers(e){const t=this.args;if(!t)return;const n=this.othersPage;if(e)this.othersPage=1;else{if(this.othersPage>=this.othersPages)return;this.othersPage+=1}const r=++this.othersSeq;let o;try{o=await this.clustersOthersWrapper.request({pagination:{filters:this.constructParams({searchTerm:t.searchTerm,includeSearchTerm:!!t.searchTerm}),page:this.othersPage,pageSize:i.Ks,sort:E,projectsOrNamespaces:[]}})}catch(s){throw r===this.othersSeq&&(this.othersPage=n),s}if(r!==this.othersSeq)return;this.counts.others=o.pagination?.result?.count??o.data.length,this.othersPages=o.pagination?.result?.pages??Math.ceil(this.counts.others/i.Ks);const a=o.data.map(e=>this.convertToCluster(e));e&&(this.clustersOthers.length=0),this.clustersOthers.push(...a)}resetOthers(e){return e&&(this.args=e),this.othersResetting+=1,this.fetchOthers(!0).finally(()=>{this.othersResetting-=1})}loadMoreOthers(){return this.othersResetting>0?Promise.resolve():this.fetchOthers(!1)}async updateCount(e){const t=(0,s.xl)({getters:this.$store.getters});if(e!==this.clusterCount||t!==this.countFilters)return clearTimeout(this.countRetryTimer),this.countRetries=0,this.fetchCounts(e)}async fetchCounts(e){const t=++this.countSeq,n=(0,s.xl)({getters:this.$store.getters}),i=e=>({pagination:{filters:e,page:1,pageSize:1,sort:[],projectsOrNamespaces:[]},transient:!0,saveCountAs:r.Nc.K8S_CLUSTERS});let o,a;try{const e=await this.$store.dispatch("management/findPage",{type:r.Mc.CLUSTER,opt:i((0,s.gF)({getters:this.$store.getters}))});o=e?.pagination?.result?.count}catch(c){a=c}if(t!==this.countSeq)return;if("number"===typeof o)return this.counts.browsable=o,this.clusterCount=e,this.countFilters=n,void(this.countRetries=0);b.warn("Unable to count clusters, retrying",a||"the response carried no total");const l=Math.min(O*2**this.countRetries,S);this.countRetries+=1,this.countRetryTimer=setTimeout(()=>this.fetchCounts(e),l)}}class k extends x{constructor({$store:e}){super({$store:e}),this.othersLimit=i.Ks,this.othersFull=[],this.hasProvCluster=this.$store.getters["management/schemaFor"](r.Z7.RANCHER_CLUSTER),this.hasProvCluster&&e.dispatch("management/findAll",{type:r.Z7.RANCHER_CLUSTER})}async update(e){const t=this.updateClusters(),n=new Set(t.map(e=>e.id));Object.keys(this.clusterCache).forEach(e=>{n.has(e)||e===r.d_&&!t.length||delete this.clusterCache[e]}),this.othersFull=this.clustersFiltered(t,e),this.counts.others=this.othersFull.length,this.counts.browsable=t.length,this.applyOthers()}async destroy(){}applyOthers(){this.clustersOthers.length=0,this.clustersOthers.push(...this.othersFull.slice(0,this.othersLimit))}resetOthers(e){return this.othersLimit=i.Ks,e&&(this.othersFull=this.clustersFiltered(this.updateClusters(),e),this.counts.others=this.othersFull.length),this.applyOthers(),Promise.resolve()}loadMoreOthers(){return this.othersLimit+=i.Ks,this.applyOthers(),Promise.resolve()}updateClusters(){if(!this.hasProvCluster)return[];const e=this.$store.getters["management/all"](r.Mc.CLUSTER),t=(0,s.uY)((0,s.WJ)(e,this.$store),this.$store),n=this.$store.getters["management/all"](r.Z7.RANCHER_CLUSTER),i=n.reduce((e,t)=>(t.mgmt?.id&&(e[t.mgmt.id]=t),e),{});return(t||[]).reduce((e,t)=>i[t.id]?(e.push(this.convertToCluster(t,i[t.id])),e):e,[])}clustersFiltered(e,t){const n=(t.searchTerm||"").toLowerCase(),r=e.filter(e=>!n||e.label?.toLowerCase().includes(n));return(0,v.Ul)(r,["ready:desc","label"])}async updateCount(){}}class C{constructor(){this.initialized=!1}init(e){if(this._helper)return;const t=e.getters["management/paginationEnabled"]({id:r.Mc.CLUSTER,context:"side-bar"});this._helper=t?new _({$store:e}):new k({$store:e}),this.initialized=!0}async reset(){await(this._helper?.destroy()),delete this._helper}get helper(){if(!this._helper)throw new Error("Unable to use the side nav cluster helper (not initialised)");return this._helper}}const A=new C;var T=A},3889:function(e,t,n){"use strict";n.d(t,{UN:function(){return a},cB:function(){return s},eD:function(){return l},wQ:function(){return c}});var r=n(9274);const i="isInResourceEditKey",o="isInResourceCreateKey";function a(){return(0,r.inject)(i,!1)}function s(){return(0,r.inject)(o,!1)}function l(){(0,r.provide)(i,!0)}function c(){(0,r.provide)(o,!0)}},82149:function(e,t,n){"use strict";n.d(t,{mG:function(){return se},$4:function(){return ae},kS:function(){return le},ve:function(){return ce}});var r=n(9274),i=n(4364),o=["input:not([inert]):not([inert] *)","select:not([inert]):not([inert] *)","textarea:not([inert]):not([inert] *)","a[href]:not([inert]):not([inert] *)","button:not([inert]):not([inert] *)","[tabindex]:not(slot):not([inert]):not([inert] *)","audio[controls]:not([inert]):not([inert] *)","video[controls]:not([inert]):not([inert] *)",'[contenteditable]:not([contenteditable="false"]):not([inert]):not([inert] *)',"details>summary:first-of-type:not([inert]):not([inert] *)","details:not([inert]):not([inert] *)"],a=o.join(","),s="undefined"===typeof Element,l=s?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,c=!s&&Element.prototype.getRootNode?function(e){var t;return null===e||void 0===e||null===(t=e.getRootNode)||void 0===t?void 0:t.call(e)}:function(e){return null===e||void 0===e?void 0:e.ownerDocument},u=function(e,t){var n;void 0===t&&(t=!0);var r=null===e||void 0===e||null===(n=e.getAttribute)||void 0===n?void 0:n.call(e,"inert"),i=""===r||"true"===r,o=i||t&&e&&("function"===typeof e.closest?e.closest("[inert]"):u(e.parentNode));return o},d=function(e){var t,n=null===e||void 0===e||null===(t=e.getAttribute)||void 0===t?void 0:t.call(e,"contenteditable");return""===n||"true"===n},h=function(e,t,n){if(u(e))return[];var r=Array.prototype.slice.apply(e.querySelectorAll(a));return t&&l.call(e,a)&&r.unshift(e),r=r.filter(n),r},p=function(e,t,n){var r=[],i=Array.from(e);while(i.length){var o=i.shift();if(!u(o,!1))if("SLOT"===o.tagName){var s=o.assignedElements(),c=s.length?s:o.children,d=p(c,!0,n);n.flatten?r.push.apply(r,d):r.push({scopeParent:o,candidates:d})}else{var h=l.call(o,a);h&&n.filter(o)&&(t||!e.includes(o))&&r.push(o);var f=o.shadowRoot||"function"===typeof n.getShadowRoot&&n.getShadowRoot(o),m=!u(f,!1)&&(!n.shadowRootFilter||n.shadowRootFilter(o));if(f&&m){var g=p(!0===f?o.children:f.children,!0,n);n.flatten?r.push.apply(r,g):r.push({scopeParent:o,candidates:g})}else i.unshift.apply(i,o.children)}}return r},f=function(e){return!isNaN(parseInt(e.getAttribute("tabindex"),10))},m=function(e){if(!e)throw new Error("No node provided");return e.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(e.tagName)||d(e))&&!f(e)?0:e.tabIndex},g=function(e,t){var n=m(e);return n<0&&t&&!f(e)?0:n},v=function(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex},b=function(e){return"INPUT"===e.tagName},y=function(e){return b(e)&&"hidden"===e.type},w=function(e){var t="DETAILS"===e.tagName&&Array.prototype.slice.apply(e.children).some(function(e){return"SUMMARY"===e.tagName});return t},O=function(e,t){for(var n=0;n<e.length;n++)if(e[n].checked&&e[n].form===t)return e[n]},S=function(e){if(!e.name)return!0;var t,n=e.form||c(e),r=function(e){return n.querySelectorAll('input[type="radio"][name="'+e+'"]')};if("undefined"!==typeof window&&"undefined"!==typeof window.CSS&&"function"===typeof window.CSS.escape)t=r(window.CSS.escape(e.name));else try{t=r(e.name)}catch(a){return i.error("Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s",a.message),!1}var o=O(t,e.form);return!o||o===e},E=function(e){return b(e)&&"radio"===e.type},x=function(e){return E(e)&&!S(e)},_=function(e){var t,n=e&&c(e),r=null===(t=n)||void 0===t?void 0:t.host,i=!1;if(n&&n!==e){var o,a,s;i=!!(null!==(o=r)&&void 0!==o&&null!==(a=o.ownerDocument)&&void 0!==a&&a.contains(r)||null!==e&&void 0!==e&&null!==(s=e.ownerDocument)&&void 0!==s&&s.contains(e));while(!i&&r){var l,u,d;n=c(r),r=null===(l=n)||void 0===l?void 0:l.host,i=!(null===(u=r)||void 0===u||null===(d=u.ownerDocument)||void 0===d||!d.contains(r))}}return i},k=function(e){var t=e.getBoundingClientRect(),n=t.width,r=t.height;return 0===n&&0===r},C=function(e,t){var n=t.displayCheck,r=t.getShadowRoot;if("full-native"===n&&"checkVisibility"in e){var i=e.checkVisibility({checkOpacity:!1,opacityProperty:!1,contentVisibilityAuto:!0,visibilityProperty:!0,checkVisibilityCSS:!0});return!i}if("hidden"===getComputedStyle(e).visibility)return!0;var o=l.call(e,"details>summary:first-of-type"),a=o?e.parentElement:e;if(l.call(a,"details:not([open]) *"))return!0;if(n&&"full"!==n&&"full-native"!==n&&"legacy-full"!==n){if("non-zero-area"===n)return k(e)}else{if("function"===typeof r){var s=e;while(e){var u=e.parentElement,d=c(e);if(u&&!u.shadowRoot&&!0===r(u))return k(e);e=e.assignedSlot?e.assignedSlot:u||d===e.ownerDocument?u:d.host}e=s}if(_(e))return!e.getClientRects().length;if("legacy-full"!==n)return!0}return!1},A=function(e){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(e.tagName)){var t=e.parentElement;while(t){if("FIELDSET"===t.tagName&&t.disabled){for(var n=0;n<t.children.length;n++){var r=t.children.item(n);if("LEGEND"===r.tagName)return!!l.call(t,"fieldset[disabled] *")||!r.contains(e)}return!0}t=t.parentElement}}return!1},T=function(e,t){return!(t.disabled||y(t)||C(t,e)||w(t)||A(t))},R=function(e,t){return!(x(t)||m(t)<0||!T(e,t))},N=function(e){var t=parseInt(e.getAttribute("tabindex"),10);return!!(isNaN(t)||t>=0)},P=function(e){var t=[],n=[];return e.forEach(function(e,r){var i=!!e.scopeParent,o=i?e.scopeParent:e,a=g(o,i),s=i?P(e.candidates):o;0===a?i?t.push.apply(t,s):t.push(o):n.push({documentOrder:r,tabIndex:a,item:e,isScope:i,content:s})}),n.sort(v).reduce(function(e,t){return t.isScope?e.push.apply(e,t.content):e.push(t.content),e},[]).concat(t)},I=function(e,t){var n;return t=t||{},n=t.getShadowRoot?p([e],t.includeContainer,{filter:R.bind(null,t),flatten:!1,getShadowRoot:t.getShadowRoot,shadowRootFilter:N}):h(e,t.includeContainer,R.bind(null,t)),P(n)},M=function(e,t){var n;return t=t||{},n=t.getShadowRoot?p([e],t.includeContainer,{filter:T.bind(null,t),flatten:!0,getShadowRoot:t.getShadowRoot}):h(e,t.includeContainer,T.bind(null,t)),n},D=function(e,t){if(t=t||{},!e)throw new Error("No node provided");return!1!==l.call(e,a)&&R(t,e)},L=o.concat("iframe:not([inert]):not([inert] *)").join(","),B=function(e,t){if(t=t||{},!e)throw new Error("No node provided");return!1!==l.call(e,L)&&T(t,e)};
|
||
/*!
|
||
* focus-trap 7.6.5
|
||
* @license MIT, https://github.com/focus-trap/focus-trap/blob/master/LICENSE
|
||
*/
|
||
function $(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function V(e){if(Array.isArray(e))return $(e)}function F(e,t,n){return(t=z(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function j(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}function U(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function G(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function H(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?G(Object(n),!0).forEach(function(t){F(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):G(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function q(e){return V(e)||j(e)||K(e)||U()}function Q(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}function z(e){var t=Q(e,"string");return"symbol"==typeof t?t:t+""}function K(e,t){if(e){if("string"==typeof e)return $(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?$(e,t):void 0}}var W={activateTrap:function(e,t){if(e.length>0){var n=e[e.length-1];n!==t&&n._setPausedState(!0)}var r=e.indexOf(t);-1===r||e.splice(r,1),e.push(t)},deactivateTrap:function(e,t){var n=e.indexOf(t);-1!==n&&e.splice(n,1),e.length>0&&!e[e.length-1]._isManuallyPaused()&&e[e.length-1]._setPausedState(!1)}},X=function(e){return e.tagName&&"input"===e.tagName.toLowerCase()&&"function"===typeof e.select},Y=function(e){return"Escape"===(null===e||void 0===e?void 0:e.key)||"Esc"===(null===e||void 0===e?void 0:e.key)||27===(null===e||void 0===e?void 0:e.keyCode)},Z=function(e){return"Tab"===(null===e||void 0===e?void 0:e.key)||9===(null===e||void 0===e?void 0:e.keyCode)},J=function(e){return Z(e)&&!e.shiftKey},ee=function(e){return Z(e)&&e.shiftKey},te=function(e){return setTimeout(e,0)},ne=function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return"function"===typeof e?e.apply(void 0,n):e},re=function(e){return e.target.shadowRoot&&"function"===typeof e.composedPath?e.composedPath()[0]:e.target},ie=[],oe=function(e,t){var n,r=(null===t||void 0===t?void 0:t.document)||document,i=(null===t||void 0===t?void 0:t.trapStack)||ie,o=H({returnFocusOnDeactivate:!0,escapeDeactivates:!0,delayInitialFocus:!0,isKeyForward:J,isKeyBackward:ee},t),a={containers:[],containerGroups:[],tabbableGroups:[],nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1,manuallyPaused:!1,delayInitialFocusTimer:void 0,recentNavEvent:void 0},s=function(e,t,n){return e&&void 0!==e[t]?e[t]:o[n||t]},l=function(e,t){var n="function"===typeof(null===t||void 0===t?void 0:t.composedPath)?t.composedPath():void 0;return a.containerGroups.findIndex(function(t){var r=t.container,i=t.tabbableNodes;return r.contains(e)||(null===n||void 0===n?void 0:n.includes(r))||i.find(function(t){return t===e})})},c=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.hasFallback,i=void 0!==n&&n,a=t.params,s=void 0===a?[]:a,l=o[e];if("function"===typeof l&&(l=l.apply(void 0,q(s))),!0===l&&(l=void 0),!l){if(void 0===l||!1===l)return l;throw new Error("`".concat(e,"` was specified but was not a node, or did not return a node"))}var c=l;if("string"===typeof l){try{c=r.querySelector(l)}catch(u){throw new Error("`".concat(e,'` appears to be an invalid selector; error="').concat(u.message,'"'))}if(!c&&!i)throw new Error("`".concat(e,"` as selector refers to no known node"))}return c},u=function(){var e=c("initialFocus",{hasFallback:!0});if(!1===e)return!1;if(void 0===e||e&&!B(e,o.tabbableOptions))if(l(r.activeElement)>=0)e=r.activeElement;else{var t=a.tabbableGroups[0],n=t&&t.firstTabbableNode;e=n||c("fallbackFocus")}else null===e&&(e=c("fallbackFocus"));if(!e)throw new Error("Your focus-trap needs to have at least one focusable element");return e},d=function(){if(a.containerGroups=a.containers.map(function(e){var t=I(e,o.tabbableOptions),n=M(e,o.tabbableOptions),r=t.length>0?t[0]:void 0,i=t.length>0?t[t.length-1]:void 0,a=n.find(function(e){return D(e)}),s=n.slice().reverse().find(function(e){return D(e)}),l=!!t.find(function(e){return m(e)>0});return{container:e,tabbableNodes:t,focusableNodes:n,posTabIndexesFound:l,firstTabbableNode:r,lastTabbableNode:i,firstDomTabbableNode:a,lastDomTabbableNode:s,nextTabbableNode:function(e){var r=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=t.indexOf(e);return i<0?r?n.slice(n.indexOf(e)+1).find(function(e){return D(e)}):n.slice(0,n.indexOf(e)).reverse().find(function(e){return D(e)}):t[i+(r?1:-1)]}}}),a.tabbableGroups=a.containerGroups.filter(function(e){return e.tabbableNodes.length>0}),a.tabbableGroups.length<=0&&!c("fallbackFocus"))throw new Error("Your focus-trap must have at least one container with at least one tabbable node in it at all times");if(a.containerGroups.find(function(e){return e.posTabIndexesFound})&&a.containerGroups.length>1)throw new Error("At least one node with a positive tabindex was found in one of your focus-trap's multiple containers. Positive tabindexes are only supported in single-container focus-traps.")},h=function(e){var t=e.activeElement;if(t)return t.shadowRoot&&null!==t.shadowRoot.activeElement?h(t.shadowRoot):t},p=function(e){!1!==e&&e!==h(document)&&(e&&e.focus?(e.focus({preventScroll:!!o.preventScroll}),a.mostRecentlyFocusedNode=e,X(e)&&e.select()):p(u()))},f=function(e){var t=c("setReturnFocus",{params:[e]});return t||!1!==t&&e},g=function(e){var t=e.target,n=e.event,r=e.isBackward,i=void 0!==r&&r;t=t||re(n),d();var s=null;if(a.tabbableGroups.length>0){var u=l(t,n),h=u>=0?a.containerGroups[u]:void 0;if(u<0)s=i?a.tabbableGroups[a.tabbableGroups.length-1].lastTabbableNode:a.tabbableGroups[0].firstTabbableNode;else if(i){var p=a.tabbableGroups.findIndex(function(e){var n=e.firstTabbableNode;return t===n});if(p<0&&(h.container===t||B(t,o.tabbableOptions)&&!D(t,o.tabbableOptions)&&!h.nextTabbableNode(t,!1))&&(p=u),p>=0){var f=0===p?a.tabbableGroups.length-1:p-1,g=a.tabbableGroups[f];s=m(t)>=0?g.lastTabbableNode:g.lastDomTabbableNode}else Z(n)||(s=h.nextTabbableNode(t,!1))}else{var v=a.tabbableGroups.findIndex(function(e){var n=e.lastTabbableNode;return t===n});if(v<0&&(h.container===t||B(t,o.tabbableOptions)&&!D(t,o.tabbableOptions)&&!h.nextTabbableNode(t))&&(v=u),v>=0){var b=v===a.tabbableGroups.length-1?0:v+1,y=a.tabbableGroups[b];s=m(t)>=0?y.firstTabbableNode:y.firstDomTabbableNode}else Z(n)||(s=h.nextTabbableNode(t))}}else s=c("fallbackFocus");return s},v=function(e){var t=re(e);l(t,e)>=0||(ne(o.clickOutsideDeactivates,e)?n.deactivate({returnFocus:o.returnFocusOnDeactivate}):ne(o.allowOutsideClick,e)||e.preventDefault())},b=function(e){var t=re(e),n=l(t,e)>=0;if(n||t instanceof Document)n&&(a.mostRecentlyFocusedNode=t);else{var r;e.stopImmediatePropagation();var i=!0;if(a.mostRecentlyFocusedNode)if(m(a.mostRecentlyFocusedNode)>0){var s=l(a.mostRecentlyFocusedNode),c=a.containerGroups[s].tabbableNodes;if(c.length>0){var d=c.findIndex(function(e){return e===a.mostRecentlyFocusedNode});d>=0&&(o.isKeyForward(a.recentNavEvent)?d+1<c.length&&(r=c[d+1],i=!1):d-1>=0&&(r=c[d-1],i=!1))}}else a.containerGroups.some(function(e){return e.tabbableNodes.some(function(e){return m(e)>0})})||(i=!1);else i=!1;i&&(r=g({target:a.mostRecentlyFocusedNode,isBackward:o.isKeyBackward(a.recentNavEvent)})),p(r||(a.mostRecentlyFocusedNode||u()))}a.recentNavEvent=void 0},y=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];a.recentNavEvent=e;var n=g({event:e,isBackward:t});n&&(Z(e)&&e.preventDefault(),p(n))},w=function(e){(o.isKeyForward(e)||o.isKeyBackward(e))&&y(e,o.isKeyBackward(e))},O=function(e){Y(e)&&!1!==ne(o.escapeDeactivates,e)&&(e.preventDefault(),n.deactivate())},S=function(e){var t=re(e);l(t,e)>=0||ne(o.clickOutsideDeactivates,e)||ne(o.allowOutsideClick,e)||(e.preventDefault(),e.stopImmediatePropagation())},E=function(){if(a.active)return W.activateTrap(i,n),a.delayInitialFocusTimer=o.delayInitialFocus?te(function(){p(u())}):p(u()),r.addEventListener("focusin",b,!0),r.addEventListener("mousedown",v,{capture:!0,passive:!1}),r.addEventListener("touchstart",v,{capture:!0,passive:!1}),r.addEventListener("click",S,{capture:!0,passive:!1}),r.addEventListener("keydown",w,{capture:!0,passive:!1}),r.addEventListener("keydown",O),n},x=function(){if(a.active)return r.removeEventListener("focusin",b,!0),r.removeEventListener("mousedown",v,!0),r.removeEventListener("touchstart",v,!0),r.removeEventListener("click",S,!0),r.removeEventListener("keydown",w,!0),r.removeEventListener("keydown",O),n},_=function(e){var t=e.some(function(e){var t=Array.from(e.removedNodes);return t.some(function(e){return e===a.mostRecentlyFocusedNode})});t&&p(u())},k="undefined"!==typeof window&&"MutationObserver"in window?new MutationObserver(_):void 0,C=function(){k&&(k.disconnect(),a.active&&!a.paused&&a.containers.map(function(e){k.observe(e,{subtree:!0,childList:!0})}))};return n={get active(){return a.active},get paused(){return a.paused},activate:function(e){if(a.active)return this;var t=s(e,"onActivate"),n=s(e,"onPostActivate"),i=s(e,"checkCanFocusTrap");i||d(),a.active=!0,a.paused=!1,a.nodeFocusedBeforeActivation=h(r),null===t||void 0===t||t();var o=function(){i&&d(),E(),C(),null===n||void 0===n||n()};return i?(i(a.containers.concat()).then(o,o),this):(o(),this)},deactivate:function(e){if(!a.active)return this;var t=H({onDeactivate:o.onDeactivate,onPostDeactivate:o.onPostDeactivate,checkCanReturnFocus:o.checkCanReturnFocus},e);clearTimeout(a.delayInitialFocusTimer),a.delayInitialFocusTimer=void 0,x(),a.active=!1,a.paused=!1,C(),W.deactivateTrap(i,n);var r=s(t,"onDeactivate"),l=s(t,"onPostDeactivate"),c=s(t,"checkCanReturnFocus"),u=s(t,"returnFocus","returnFocusOnDeactivate");null===r||void 0===r||r();var d=function(){te(function(){u&&p(f(a.nodeFocusedBeforeActivation)),null===l||void 0===l||l()})};return u&&c?(c(f(a.nodeFocusedBeforeActivation)).then(d,d),this):(d(),this)},pause:function(e){return a.active?(a.manuallyPaused=!0,this._setPausedState(!0,e)):this},unpause:function(e){return a.active?(a.manuallyPaused=!1,i[i.length-1]!==this?this:this._setPausedState(!1,e)):this},updateContainerElements:function(e){var t=[].concat(e).filter(Boolean);return a.containers=t.map(function(e){return"string"===typeof e?r.querySelector(e):e}),a.active&&d(),C(),this}},Object.defineProperties(n,{_isManuallyPaused:{value:function(){return a.manuallyPaused}},_setPausedState:{value:function(e,t){if(a.paused===e)return this;if(a.paused=e,e){var n=s(t,"onPause"),r=s(t,"onPostPause");null===n||void 0===n||n(),x(),C(),null===r||void 0===r||r()}else{var i=s(t,"onUnpause"),o=s(t,"onPostUnpause");null===i||void 0===i||i(),d(),E(),C(),null===o||void 0===o||o()}return this}}}),n.updateContainerElements(e),n};function ae(e=document){const t=e.querySelectorAll('a, button, input, textarea, select, details,[tabindex]:not([tabindex="-1"])'),n=[];return t.forEach(e=>{e.hasAttribute("disabled")||n.push(e)}),n.length?n[0]:document.body}const se={escapeDeactivates:!0,allowOutsideClick:!0};function le(e,t=se){let n,i;(0,r.onMounted)(()=>{i="string"===typeof e?document.querySelector(e):e,n=oe(i,t),(0,r.nextTick)(()=>{n.activate()})}),(0,r.onBeforeUnmount)(()=>{Object.keys(n).length&&n.deactivate()})}function ce(e,t,n=se,i=!1){let o,a;(0,r.watch)(e,e=>{e&&!o?(0,r.nextTick)(()=>{a="string"===typeof t?document.querySelector(t):t,o=oe(a,n);const e=()=>o.activate();(0,r.nextTick)(()=>{setTimeout(e,0)})}):!e&&o&&Object.keys(o).length&&!i&&o.deactivate()},{immediate:!0}),i&&(0,r.onBeforeUnmount)(()=>{o&&Object.keys(o).length&&o.deactivate()})}},91452:function(e,t,n){"use strict";n.d(t,{L:function(){return a},x:function(){return o}});var r=n(9274);const i="isInResourceDetailKey";function o(){return(0,r.inject)(i,!1)}function a(){(0,r.provide)(i,!0)}},40597:function(e,t,n){"use strict";n.d(t,{L:function(){return i}});var r=n(9274);const i=(e,t,n={})=>{const{ignore:i=[]}=n;let o=!0;const a=e=>i.some(t=>{if("string"===typeof t)return Array.from(window.document.querySelectorAll(t)).some(t=>t===e.target||e.composedPath().includes(t));{const n=t;return n&&(e.target===n||e.composedPath().includes(n))}}),s=n=>{const r=e.value;r&&r!==n.target&&!n.composedPath().includes(r)&&(0===n.detail&&(o=!a(n)),o?"function"===typeof t&&t():o=!0)},l=t=>{const n=e.value;o=!a(t)&&!(!n||t.composedPath().includes(n))};(0,r.onMounted)(()=>{window.addEventListener("click",s),window.addEventListener("pointerdown",l)}),(0,r.onBeforeUnmount)(()=>{window.removeEventListener("click",s),window.removeEventListener("pointerdown",l)})}},95457:function(e,t,n){"use strict";n.d(t,{s:function(){return l}});var r=n(92043);n(9274),n(65359),n(4364);function i(e,t,n,i=!1,o=!0){const a=e.getters["i18n/t"](t,n);let s;if(void 0!==a)s=a;else if(n&&Object.keys(n).length){const e=Object.keys(n).map(e=>`${e}: ${n[e]}`).join(", ");s=`%${t}(${e})%`,i=!0}else s=`%${t}%`;return i?s:o?(0,r.ZD)(s):s}var o=n(4364);let a=null;const s=(e,t,n)=>a?i(a,e,t,n):({NODE_ENV:"production",BASE_URL:"/"}.dev&&o.warn("useI18n: store not available"),e),l=e=>{if(a=e,!a)throw new Error("usI18n() must be called from setup()");return{t:s}}},2117:function(e,t,n){"use strict";n.d(t,{K:function(){return o},x:function(){return a}});var r=n(9274),i=n(14220);const o={tooltipKey:{type:String,default:null},placeholder:{type:[String,Number],default:""},placeholderKey:{type:String,default:null},label:{type:String,default:null},labelKey:{type:String,default:null},value:{type:[String,Number,Object,null],default:""},mode:{type:String,default:i.G5},rules:{default:()=>[],type:Array,validator:e=>e.every(e=>["function"].includes(typeof e))},required:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},requireDirty:{default:!0,type:Boolean}},a=(e,t)=>{const n=(0,r.ref)(e.mode===i.nW||!!`${e.value}`),o=(0,r.ref)(!1),a=(0,r.ref)(null),s=(0,r.computed)(()=>{var t;return e.required||(null===(t=e.rules)||void 0===t?void 0:t.some(e=>"required"===(null===e||void 0===e?void 0:e.name)))}),l=(0,r.computed)(()=>!!`${e.value}`),c=(0,r.computed)(()=>e.mode===i.nW),u=(0,r.computed)(()=>e.disabled||c.value),d=(0,r.computed)(()=>{const n=e.rules.find(e=>"required"===(null===e||void 0===e?void 0:e.name)),r=[],i=e.value;if(n&&a.value&&!o.value){const e=n(i);if(e)return t("update:validation",!1),e}for(const t of e.rules){const e=t(i);e&&"required"!==t.name&&r.push(e)}return r.length>0&&(a.value||o.value||!e.requireDirty)?(t("update:validation",!1),r.join(", ")):void t("update:validation",!0)}),h=()=>{n.value=!0,o.value=!0},p=()=>{o.value=!1,e.value||(n.value=!1),a.value=Date.now()};return{raised:n,focused:o,blurred:a,empty:l,isView:c,onFocusLabeled:h,onBlurLabeled:p,isDisabled:u,validationMessage:d,requiredField:s}}},97693:function(e,t,n){"use strict";n.d(t,{v:function(){return a}});var r=n(9274);function i(e,t){e&&("function"===typeof t&&(t=t()),e.style.width="string"!==typeof t?`${t}px`:t)}function o(e){if(e&&e.length)return e.length?parseFloat(getComputedStyle(e[0]).width.replace("px","")):parseFloat(getComputedStyle(e).width.replace("px",""))}const a=(e,t)=>{const n=(0,r.computed)(()=>{if(null===t||void 0===t?void 0:t.value)return!0;const n=e.options||[];return!!(e.searchable||n.length>=10)}),a=(0,r.computed)(()=>{var n;return!(null===t||void 0===t?void 0:t.value)&&(null===(n=e.filterable)||void 0===n||n)}),s=e=>{(0,r.nextTick)(()=>{if(!e.value)return;const t=e.value.querySelector("ul.vs__dropdown-menu"),n=o(e.value)||0,r=o(t)||0;r<n&&i(t,n)})};return{isSearchable:n,isFilterable:a,resizeHandler:s}}},75886:function(e,t,n){"use strict";n.d(t,{K:function(){return l}});var r=n(9274),i=n(2722),o=n.n(i),a=n(83288);let s;const l=e=>(s=e,{featureDropdownMenu:c}),c=(0,r.computed)(()=>{const{fullVersion:e}=(0,a.hQ)(s),t=o().coerce(e)||{version:"0.0.0"};return o().gte(t.version,"2.11.0")})},16824:function(e,t,n){"use strict";n.d(t,{U:function(){return a}});var r=n(9274),i=n(53197),o=n(92043);function a({name:e,rules:t,value:n,validationMessage:a}){const s=(0,r.inject)("vee-show-all-errors",(0,r.ref)(!1)),l=`__field__${(0,o.aR)(12)}`,c=(0,r.computed)(()=>e.value||l),u=n=>{if(!e.value)return!0;for(const e of t.value){const t=e(n);if(t)return t}return!0},{errorMessage:d,handleBlur:h,validate:p,value:f,meta:m}=(0,i.Mt)(c,u,{initialValue:n.value,validateOnValueUpdate:!0,validateOnMount:!0});(0,r.watch)(n,e=>{f.value!==e&&(f.value=e)});const g=(0,r.computed)(()=>e.value&&d.value&&(m.touched||s.value)?d.value:a.value);return{effectiveValidationMessage:g,veeHandleBlur:h,veeValidate:p,showAllErrors:s}}},17259:function(e,t,n){"use strict";n.d(t,{J:function(){return r},u:function(){return i}});const r={OPAQUE:"Opaque",SERVICE_ACCT:"kubernetes.io/service-account-token",DOCKER_JSON:"kubernetes.io/dockerconfigjson",BASIC:"kubernetes.io/basic-auth",SSH:"kubernetes.io/ssh-auth",TLS:"kubernetes.io/tls",BOOTSTRAP:"bootstrap.kubernetes.io/token",ISTIO_TLS:"istio.io/key-and-cert",HELM_RELEASE:"helm.sh/release.v1",FLEET_CLUSTER:"fleet.cattle.io/cluster-registration-values",CLOUD_CREDENTIAL:"provisioning.cattle.io/cloud-credential",RKE_AUTH_CONFIG:"rke.cattle.io/auth-config",FLEET_OCI_STORAGE:"fleet.cattle.io/bundle-oci-storage/v1alpha1"},i={APP_ID:"github_app_id",INSTALLATION_ID:"github_app_installation_id",PRIVATE_KEY:"github_app_private_key"}},9262:function(e,t,n){"use strict";n.d(t,{$8:function(){return s},Df:function(){return a},HG:function(){return o}});var r=n(40207);const i={CLUSTER:"cluster",FLEET:"fleet"},o={VERSION_RANCHER:"server-version",VERSION_CLI:"cli-version",VERSION_MACHINE:"machine-version",VERSION_HELM:"helm-version",CLI_URL:{DARWIN:"cli-url-darwin",WINDOWS:"cli-url-windows",LINUX:"cli-url-linux"},API_HOST:"api-host",CA_CERTS:"cacerts",HIDE_LOCAL_CLUSTER:"hide-local-cluster",AUTH_TOKEN_MAX_TTL_MINUTES:"auth-token-max-ttl-minutes",KUBECONFIG_GENERATE_TOKEN:"kubeconfig-generate-token",KUBECONFIG_DEFAULT_TOKEN_TTL_MINUTES:"kubeconfig-default-token-ttl-minutes",ENGINE_ISO_URL:"engine-iso-url",FIRST_LOGIN:"first-login",INGRESS_IP_DOMAIN:"ingress-ip-domain",SERVER_URL:"server-url",RKE_METADATA_CONFIG:"rke-metadata-config",EULA_AGREED:"eula-agreed",AUTH_USER_INFO_MAX_AGE_SECONDS:"auth-user-info-max-age-seconds",AUTH_USER_SESSION_IDLE_TTL_MINUTES:"auth-user-session-idle-ttl-minutes",AUTH_USER_SESSION_TTL_MINUTES:"auth-user-session-ttl-minutes",AUTH_USER_INFO_RESYNC_CRON:"auth-user-info-resync-cron",AUTH_LOCAL_VALIDATE_DESC:"auth-password-requirements-description",PASSWORD_MIN_LENGTH:"password-min-length",UI_DASHBOARD_INDEX:"ui-dashboard-index",UI_DASHBOARD_HARVESTER_LEGACY_PLUGIN:"ui-dashboard-harvester-legacy-plugin",UI_OFFLINE_PREFERRED:"ui-offline-preferred",SYSTEM_DEFAULT_REGISTRY:"system-default-registry",SYSTEM_DEFAULT_REGISTRY_PULL_SECRETS:"system-default-registry-pull-secrets",UI_ISSUES:"ui-issues",PL:"ui-pl",PL_RANCHER_VALUE:"rancher",SUPPORTED:"has-support",BANNERS:"ui-banners",ISSUES:"ui-issues",BRAND:"ui-brand",LOGO_LIGHT:"ui-logo-light",LOGO_DARK:"ui-logo-dark",BANNER_LIGHT:"ui-banner-light",BANNER_DARK:"ui-banner-dark",LOGIN_BACKGROUND_LIGHT:"ui-login-background-light",LOGIN_BACKGROUND_DARK:"ui-login-background-dark",PRIMARY_COLOR:"ui-primary-color",LINK_COLOR:"ui-link-color",COMMUNITY_LINKS:"ui-community-links",FAVICON:"ui-favicon",UI_PERFORMANCE:"ui-performance",UI_CUSTOM_LINKS:"ui-custom-links",UI_SUPPORTED_K8S_VERSIONS:"ui-k8s-supported-versions-range",THEME:"ui-theme",SYSTEM_NAMESPACES:"system-namespaces",CLUSTER_AGENT_DEFAULT_AFFINITY:"cluster-agent-default-affinity",FLEET_AGENT_DEFAULT_AFFINITY:"fleet-agent-default-affinity",ADD_EXTENSION_REPOS_BANNER_DISPLAY:"display-add-extension-repos-banner",AGENT_TLS_MODE:"agent-tls-mode",USER_RETENTION_CRON:"user-retention-cron",USER_RETENTION_DRY_RUN:"user-retention-dry-run",USER_LAST_LOGIN_DEFAULT:"user-last-login-default",DISABLE_INACTIVE_USER_AFTER:"disable-inactive-user-after",DELETE_INACTIVE_USER_AFTER:"delete-inactive-user-after",K3S_UPGRADER_UNINSTALL_CONCURRENCY:"k3s-based-upgrader-uninstall-concurrency",SYSTEM_AGENT_UPGRADER_INSTALL_CONCURRENCY:"system-agent-upgrader-install-concurrency",IMPORTED_CLUSTER_VERSION_MANAGEMENT:"imported-cluster-version-management",CLUSTER_AGENT_DEFAULT_PRIORITY_CLASS:"cluster-agent-default-priority-class",CLUSTER_AGENT_DEFAULT_POD_DISTRIBUTION_BUDGET:"cluster-agent-default-pod-disruption-budget",FLEET_AGENT_DEFAULT_PRIORITY_CLASS:"fleet-agent-default-priority-class",FLEET_AGENT_DEFAULT_POD_DISTRIBUTION_BUDGET:"fleet-agent-default-pod-disruption-budget",KEV2_OPERATORS:"kev2-operators",DYNAMIC_CONTENT_ENABLED:"ui-content-enabled",DYNAMIC_CONTENT_ENDPOINT:"ui-content-endpoint",IMPORTED_CLUSTER_DAY2_OPS_DEFAULT:"imported-cluster-day2-ops-enabled",DELETE_MACHINE_ON_FAILURE_AFTER:"delete-machine-on-failure-after",SYSTEM_CATALOG:"system-catalog",UI_APPCO_ENABLED:"ui-appco-enabled"},a={[o.CA_CERTS]:{kind:"multiline",readOnly:!0},[o.ENGINE_ISO_URL]:{},[o.PASSWORD_MIN_LENGTH]:{kind:"integer",ruleSet:[{name:"betweenValues",key:"Password",factoryArg:[2,256]},{name:"isInteger",key:"Password"},{name:"isPositive",key:"Password"},{name:"isOctal",key:"Password"}]},[o.INGRESS_IP_DOMAIN]:{},[o.AUTH_USER_INFO_MAX_AGE_SECONDS]:{},[o.AUTH_USER_SESSION_IDLE_TTL_MINUTES]:{},[o.AUTH_USER_SESSION_TTL_MINUTES]:{},[o.AUTH_TOKEN_MAX_TTL_MINUTES]:{},[o.KUBECONFIG_GENERATE_TOKEN]:{kind:"boolean"},[o.KUBECONFIG_DEFAULT_TOKEN_TTL_MINUTES]:{kind:"integer"},[o.AUTH_USER_INFO_RESYNC_CRON]:{},[o.SERVER_URL]:{kind:"url",canReset:!0},[o.RKE_METADATA_CONFIG]:{kind:"json"},[o.SYSTEM_DEFAULT_REGISTRY]:{},[o.SYSTEM_DEFAULT_REGISTRY_PULL_SECRETS]:{},[o.UI_DASHBOARD_INDEX]:{},[o.UI_OFFLINE_PREFERRED]:{kind:"enum",options:["dynamic","true","false"]},[o.UI_APPCO_ENABLED]:{kind:"enum",display:"radio",options:["true","false",""],canReset:!0},[o.BRAND]:{canReset:!0},[o.HIDE_LOCAL_CLUSTER]:{kind:"boolean"},[o.AGENT_TLS_MODE]:{kind:"enum",options:["strict","system-store"],warning:"agent-tls-mode"},[o.SYSTEM_AGENT_UPGRADER_INSTALL_CONCURRENCY]:{kind:"integer",ruleSet:[{name:"minValue",factoryArg:1}]},[o.K3S_UPGRADER_UNINSTALL_CONCURRENCY]:{kind:"integer",ruleSet:[{name:"minValue",factoryArg:1}]},[o.IMPORTED_CLUSTER_VERSION_MANAGEMENT]:{kind:"boolean"},[o.IMPORTED_CLUSTER_DAY2_OPS_DEFAULT]:{kind:"boolean"},[o.CLUSTER_AGENT_DEFAULT_PRIORITY_CLASS]:{kind:"json",agent:i.CLUSTER},[o.CLUSTER_AGENT_DEFAULT_POD_DISTRIBUTION_BUDGET]:{kind:"json",agent:i.CLUSTER},[o.FLEET_AGENT_DEFAULT_PRIORITY_CLASS]:{kind:"json",agent:i.FLEET},[o.FLEET_AGENT_DEFAULT_POD_DISTRIBUTION_BUDGET]:{kind:"json",agent:i.FLEET},[o.DELETE_MACHINE_ON_FAILURE_AFTER]:{kind:"string"}},s=(o.ENGINE_ISO_URL,o.RKE_METADATA_CONFIG,o.K3S_UPGRADER_UNINSTALL_CONCURRENCY,o.IMPORTED_CLUSTER_VERSION_MANAGEMENT,o.CLUSTER_AGENT_DEFAULT_PRIORITY_CLASS,o.CLUSTER_AGENT_DEFAULT_POD_DISTRIBUTION_BUDGET,o.FLEET_AGENT_DEFAULT_PRIORITY_CLASS,o.FLEET_AGENT_DEFAULT_POD_DISTRIBUTION_BUDGET,o.IMPORTED_CLUSTER_DAY2_OPS_DEFAULT,o.DELETE_MACHINE_ON_FAILURE_AFTER,{inactivity:{enabled:!1,threshold:900},incrementalLoading:{enabled:!0,threshold:1500},manualRefresh:{enabled:!1,threshold:1500},disableWebsocketNotification:!0,garbageCollection:r.W,forceNsFilterV2:{enabled:!1},advancedWorker:{enabled:!1},kubeAPI:{warningHeader:{separator:"299 - ",notificationBlockList:["299 - unknown field"]}},serverPagination:{useDefaultStores:!0,stores:void 0,resourceChangesDebounceMs:4e3}})},25659:function(e,t,n){"use strict";n.d(t,{A:function(){return g}});var r,i=n(31915),o=n(35881),a=n(92043),s=n(14220),l=n(37327),c=n(76978),u=n(4364);function d(e,t){const n=(0,l.P)(e);return"home"===t&&"home"===e.name||t===n}function h({name:e,query:t,meta:n},r){return!(r!==s.G5||!t.mode||t.mode!==s.G5||t.as)||(!(r!==s.au||!t.as||t.as!==s.au)||(!(r!==s.fS||t.as||!e.includes("-id")&&"detail"!==n.mode||t.mode&&t?.mode===s.G5)||(!(r!==s.wC||e.includes("-id")||!e.includes("-resource"))||!(r!==s.YQ||!e.endsWith("-create")))))}function p(e,t,n){if(!Object.keys(t).length)return!0;const{params:r}=e,i=["product","resource","namespace","cluster","id","mode","path","hash","queryParam","context"];let o=!0;for(let a=0;a<i.length;a++){const s=i[a];if(t[s]){const i=Array.isArray(t[s])?t[s]:[t[s]];for(let t=0;t<i.length;t++){const a=i[t];if(a&&(o="hash"===s?!!e.hash&&e.hash.includes(a):"product"===s?d(e,a):"mode"===s?h(e,a):"resource"===s?r[s]&&"*"===a||a===r[s]:"context"===s?(0,c.n4)(a,n):"queryParam"===s?(0,c.n4)(a,e.query):"path"===s&&a.urlPath?a.endsWith?e.path.endsWith(a.urlPath):!Object.keys(a).includes("exact")||a.exact?a.urlPath===e.path:e.path.includes(a.urlPath):a===r[s]),o)break}if(!o)break}}return o}(function(e){e["_CONFIG"]="config",e["_CREATE"]="create",e["_DETAIL"]="detail",e["_EDIT"]="edit",e["_LIST"]="list"})(r||(r={}));const f={};function m(e){const t=e.getAllUIConfig?.();if(t){const e={};Object.values(i.c7).forEach(n=>{t[n]||f[n]||(e[n]=!0,f[n]=!0)}),Object.keys(e).length&&u.warn(`[plugin-helpers] These ExtensionPoints aren't available for usage in this Rancher version: ${Object.keys(e).join(", ")}`)}}function g(e,t,n,r,s=e,l){const c=[];if(e.$extension?.getUIConfig){if(m(e.$extension),f[t])return[];const u=e.$extension.getUIConfig(t,n);u.forEach((e,d)=>{if(p(r,e.locationConfig,l||{})){if(t===i.c7.CARD)n===i.O4.CLUSTER_DASHBOARD_CARD&&e.labelKey&&(u[d].label=s.t(e.labelKey));else if(t===i.c7.ACTION&&(n===i.ug.TABLE&&(e.labelKey&&(u[d].label=s.t(e.labelKey)),u[d].bulkable=u[d].multiple||u[d].bulkable,u[d].action||(u[d].action=`custom-table-action-${(0,a.vx)(10).toLowerCase()}`)),n===i.ug.HEADER&&e.shortcut))if("string"===typeof e.shortcut)u[d].shortcutLabel=()=>o.cX?`(⌘-${e.shortcut.toUpperCase()})`:`(Ctrl-${e.shortcut.toUpperCase()})`,u[d].shortcutKey={windows:["ctrl",e.shortcut],mac:["meta",e.shortcut]};else if("object"===typeof e.shortcut&&!Array.isArray(e.shortcut)&&null!==e.shortcut){u[d].shortcutKey=e.shortcut;const t=o.cX?u[d].shortcut.mac:u[d].shortcut.windows?u[d].shortcut.windows:[];let n="";t.forEach((e,r)=>{r<t.length-1?(e="meta"===e?"⌘":o.cX&&"alt"===e?"⌥":(0,a.TF)(e),n+=`${e}`,n+="-"):n+=`${e.toUpperCase()}`}),u[d].shortcutLabel=()=>`(${n})`}c.push(u[d])}})}return c}},89778:function(e,t,n){"use strict";n.d(t,{j:function(){return a}});n(86565),n(14220),n(31915),n(25314),n(9274),n(83297);n(59918),n(47433);function r(e){return void 0!==e.sideMenu&&"children"in e.sideMenu}var i=n(10213);class o{weightFromProductChild(e){var t,n;return(null===(t=e.sideMenu)||void 0===t?void 0:t.weight)||(null===(n=e.sideMenu)||void 0===n?void 0:n.weight)}gatherChildrenOrdering(e){let t=e.reduce((e,t)=>{const n=this.weightFromProductChild(t);return"number"!==typeof n?e:n<e?n:e},1/0);t===1/0&&(t=999);const n=[];return e.forEach((e,i)=>{var o,a;const s={...e};void 0!==(null===(o=s.sideMenu)||void 0===o?void 0:o.weight)&&null!==(null===(a=s.sideMenu)||void 0===a?void 0:a.weight)||(s.sideMenu||(s.sideMenu={}),s.sideMenu.weight=t-(i+1)),r(s)&&(s.sideMenu.children=this.gatherChildrenOrdering(s.sideMenu.children)),n.push(s)}),n.sort((e,t)=>{var n,r,i,o;return(null!==(r=null===(n=t.sideMenu)||void 0===n?void 0:n.weight)&&void 0!==r?r:0)-(null!==(o=null===(i=e.sideMenu)||void 0===i?void 0:i.weight)&&void 0!==o?o:0)})}generateTopLevelExtensionSimpleBaseRoute(e,t={}){const{component:n,omitPath:r}=t,i={name:`${e}`,path:`${e}`,params:{product:e},meta:{product:e}};return n&&(i.component=n),r&&delete i.path,i}generateVirtualTypeRoute(e,t,n={}){return n.extendProduct?this.generateVirtualTypeRouteForExistingProduct(e,t,n):this.generateVirtualTypeRouteForNewProduct(e,t,n)}generateVirtualTypeRouteForExistingProduct(e,t,n={}){const{component:r,omitPath:i}=n,o=t?`c-cluster-${e}-${t}`:`c-cluster-${e}`,a=t?`c/:cluster/${e}/${t}`:`c/:cluster/${e}`,s={name:o,path:a,params:{product:e},meta:{product:e}};return r&&(s.component=r),i&&delete s.path,s}generateVirtualTypeRouteForNewProduct(e,t,n={}){const{component:r,omitPath:o,startRouteWithProduct:a}=n;let s,l;a?(s=t?`${e}-c-cluster-${t}`:`${e}-c-cluster`,l=t?`${e}/c/:cluster/${t}`:`${e}/c/:cluster`):(s=t?`c-cluster-${e}-${t}`:`c-cluster-${e}`,l=t?`c/:cluster/${e}/${t}`:`c/:cluster/${e}`);const c={name:s,path:l,params:{product:e,cluster:i.w},meta:{product:e,cluster:i.w}};return r&&(c.component=r),o&&delete c.path,c}generateConfigureTypeRoute(e,t,n={}){return n.extendProduct?this.generateConfigureTypeRouteForExistingProduct(e,t,n):this.generateConfigureTypeRouteForNewProduct(e,t,n)}generateConfigureTypeRouteForExistingProduct(e,t,n={}){const{component:r,omitPath:i}=n,o={name:"c-cluster-product-resource",path:"c/:cluster/:product/:resource",params:{product:e,resource:null===t||void 0===t?void 0:t.type},meta:{product:e,resource:null===t||void 0===t?void 0:t.type}};return r&&(o.component=r),i&&delete o.path,o}generateConfigureTypeRouteForNewProduct(e,t,n={}){const{component:r,omitPath:o,startRouteWithProduct:a}=n;let s,l;a?(s=`${e}-c-cluster-resource`,l=`${e}/c/:cluster/:resource`):(s=`c-cluster-${e}-resource`,l=`c/:cluster/${e}/:resource`);const c={name:s,path:l,params:{product:e,cluster:i.w,resource:null===t||void 0===t?void 0:t.type},meta:{product:e,cluster:i.w,resource:null===t||void 0===t?void 0:t.type}};return r&&(c.component=r),o&&delete c.path,c}generateResourceRoutes(e,t,n={}){return n.extendProduct?this.generateResourceRoutesForExistingProduct(e,t):this.generateResourceRoutesForNewProduct(e,n)}generateResourceRoutesForExistingProduct(e,t){const r=e=>e.then(e=>e.default||e);return[{name:`c-cluster-${e}-resource`,path:`c/:cluster/${e}/:resource`,component:()=>r(n.e(446).then(n.bind(n,36446))),meta:{product:e,resource:t.type}},{name:`c-cluster-${e}-resource-create`,path:`c/:cluster/${e}/:resource/create`,component:()=>r(n.e(856).then(n.bind(n,13856))),meta:{product:e,resource:t.type}},{name:`c-cluster-${e}-resource-id`,path:`c/:cluster/${e}/:resource/:id`,component:()=>r(n.e(303).then(n.bind(n,66303))),meta:{product:e,resource:t.type,asyncSetup:!0}},{name:`c-cluster-${e}-resource-namespace-id`,path:`c/:cluster/${e}/:resource/:namespace/:id`,component:()=>r(n.e(277).then(n.bind(n,28277))),meta:{product:e,resource:t.type,asyncSetup:!0}}]}generateResourceRoutesForNewProduct(e,t={}){const r=e=>e.then(e=>e.default||e);let o,a;return t.startRouteWithProduct?(o=`${e}-c-cluster`,a=`${e}/c/:cluster`):(o=`c-cluster-${e}`,a=`c/:cluster/${e}`),[{name:`${o}-resource`,path:`${a}/:resource`,component:()=>r(n.e(446).then(n.bind(n,36446))),meta:{product:e,cluster:i.w}},{name:`${o}-resource-create`,path:`${a}/:resource/create`,component:()=>r(n.e(856).then(n.bind(n,13856))),meta:{product:e,cluster:i.w}},{name:`${o}-resource-id`,path:`${a}/:resource/:id`,component:()=>r(n.e(303).then(n.bind(n,66303))),meta:{product:e,cluster:i.w,asyncSetup:!0}},{name:`${o}-resource-namespace-id`,path:`${a}/:resource/:namespace/:id`,component:()=>r(n.e(277).then(n.bind(n,28277))),meta:{product:e,cluster:i.w,asyncSetup:!0}}]}}new o;n(4364);new Map;n(4364);new WeakMap;n(4364);const a={MODELS:"models",MODEL_EXTENSION:"model-extension",SERVER_SIDE_PAGINATION_RESOURCES:"server-side-pagination",I18N_GLOBAL:"l10n-global"}},31915:function(e,t,n){"use strict";var r,i,o,a,s,l,c;n.d(t,{O4:function(){return s},W3:function(){return l},W7:function(){return o},c7:function(){return r},lX:function(){return a},ug:function(){return i},vH:function(){return c}}),function(e){e["ACTION"]="Action",e["TAB"]="Tab",e["PANEL"]="Panel",e["CARD"]="Card",e["TABLE_COL"]="TableColumn",e["TABLE"]="Table"}(r||(r={})),function(e){e["HEADER"]="header-action",e["TABLE"]="table-action"}(i||(i={})),function(e){e["ABOUT_TOP"]="about-top",e["DETAILS_MASTHEAD"]="details-masthead",e["DETAIL_TOP"]="detail-top",e["RESOURCE_LIST"]="resource-list"}(o||(o={})),function(e){e["RESOURCE_DETAIL"]="tab",e["OTHER"]="other-tab-locations",e["RESOURCE_DETAIL_PAGE"]="resource-detail-page",e["RESOURCE_CREATE_PAGE"]="resource-create-page",e["RESOURCE_EDIT_PAGE"]="resource-edit-page",e["RESOURCE_SHOW_CONFIGURATION"]="resource-show-configuration",e["CLUSTER_CREATE_RKE2"]="cluster-create-rke2"}(a||(a={})),function(e){e["CLUSTER_DASHBOARD_CARD"]="cluster-dashboard-card"}(s||(s={})),function(e){e["RESOURCE"]="resource-list"}(l||(l={})),function(e){e["RESOURCE"]="resource-list"}(c||(c={}))},91332:function(e,t,n){"use strict";n.r(t);var r=n(81073),i=n(22243),o=n(42200);describe("component: Opsgenie.vue",()=>{const e={mode:"edit",value:{responders:[]},namespace:"test-namespace"};it("should render correctly with initial props",()=>{const t=(0,r.Ky)(i["default"],{props:e,global:{mocks:{$fetchState:{pending:!1,error:null}}}}),n=t.findAll("h3");expect(n[0].text()).toBe("Target"),expect(n[1].text()).toBe("Responders"),expect(t.findComponent({name:"SimpleSecretSelector"}).exists()).toBe(!0),expect(t.findComponent({name:"LabeledInput"}).exists()).toBe(!0),expect(t.findComponent(o.S).exists()).toBe(!0),expect(t.findComponent({name:"ArrayList"}).exists()).toBe(!0)}),it("should update proxy URL",async()=>{const t=(0,r.Ky)(i["default"],{props:e,global:{mocks:{$fetchState:{pending:!1,error:null}}}}),n=t.findComponent({name:"LabeledInput"});await n.vm.$emit("update:value","http://my-proxy.com"),expect(t.props("value").httpConfig.proxyURL).toBe("http://my-proxy.com")}),it("should toggle send resolved alerts checkbox",async()=>{const t=(0,r.Ky)(i["default"],{props:e,global:{mocks:{$fetchState:{pending:!1,error:null}}}}),n=t.findComponent(o.S);await n.vm.$emit("update:value",!1),expect(t.props("value").sendResolved).toBe(!1)}),it("should handle API key secret updates",async()=>{const t=(0,r.Ky)(i["default"],{props:e,global:{mocks:{$fetchState:{pending:!1,error:null}}}}),n=t.findComponent({name:"SimpleSecretSelector"});await n.vm.$emit("updateSecretName","my-secret-name"),await n.vm.$emit("updateSecretKey","my-secret-key"),expect(t.props("value").apiKey.name).toBe("my-secret-name"),expect(t.props("value").apiKey.key).toBe("my-secret-key")}),it("should add and update a responder",async()=>{const t=(0,r.Ky)(i["default"],{props:e,global:{mocks:{$fetchState:{pending:!1,error:null}}}}),n=t.findComponent({name:"ArrayList"});await n.vm.$emit("update:value",[t.vm.defaultResponder]);const o=t.vm.responders;expect(o).toHaveLength(1),expect(o[0].type).toBe("team"),expect(o[0].target).toBe("id"),o[0].type="user",await t.vm.$nextTick(),expect(t.props("value").responders[0].type).toBe("user"),t.vm.updateResponder({selected:"username",text:"test-user"},o[0]),await t.vm.$nextTick(),expect(o[0].target).toBe("username"),expect(o[0].value).toBe("test-user"),expect(t.props("value").responders[0]).toStrictEqual({type:"user",username:"test-user"})}),it("should remove a responder",async()=>{const t=(0,r.Ky)(i["default"],{props:{...e,value:{responders:[{type:"team",id:"team-id"}]}},global:{mocks:{$fetchState:{pending:!1,error:null}}}});t.vm.responders.splice(0,1),await t.vm.$nextTick(),expect(t.vm.responders).toHaveLength(0),expect(t.props("value").responders).toHaveLength(0)}),it("should render in view mode",()=>{const e=(0,r.Ky)(i["default"],{props:{mode:"view",value:{httpConfig:{proxyURL:"http://view-proxy.com"},sendResolved:!1,responders:[{type:"user",name:"view-user"}]},namespace:"test-namespace"},global:{mocks:{$fetchState:{pending:!1,error:null}}}}),t=e.findComponent({name:"LabeledInput"}),n=e.findComponent(o.S),a=e.findComponent({name:"ArrayList"});expect(t.props("mode")).toBe("view"),expect(n.props("mode")).toBe("view"),expect(a.props("mode")).toBe("view");const s=e.vm.responders[0];expect(s.type).toBe("user"),expect(s.target).toBe("name"),expect(s.value).toBe("view-user"),expect(e.vm.typeLabel(s.type)).toBe("User"),expect(e.vm.targetLabel(s.target)).toBe("Name")})})},54293:function(e,t,n){"use strict";n.r(t);var r=n(81073),i=n(87450),o=n(42200);describe("component: PagerDuty.vue",()=>{const e={mode:"edit",value:{},namespace:"test-namespace"};it("should render correctly with initial props",()=>{const t=(0,r.Ky)(i["default"],{props:e,global:{mocks:{$fetchState:{pending:!1,error:null}}}}),n=t.findAll("h3");expect(n[0].text()).toBe("Target"),expect(t.findComponent({name:"LabeledSelect"}).exists()).toBe(!0),expect(t.findComponent({name:"SimpleSecretSelector"}).exists()).toBe(!0),expect(t.findComponent({name:"LabeledInput"}).exists()).toBe(!0),expect(t.findComponent(o.S).exists()).toBe(!0)}),it('should show routing key selector for "Events API v2"',()=>{const t=(0,r.Ky)(i["default"],{props:e,global:{mocks:{$fetchState:{pending:!1,error:null}}}}),n=t.findComponent({name:"SimpleSecretSelector"});expect(n.props("secretNameLabel")).toContain("monitoring.alertmanagerConfig.pagerDuty.routingKey")}),it('should show service key selector for "Prometheus"',async()=>{const t=(0,r.Ky)(i["default"],{props:{...e,value:{serviceKey:{name:"s",key:"k"}}},global:{mocks:{$fetchState:{pending:!1,error:null}}}}),n=t.findComponent({name:"SimpleSecretSelector"});expect(n.props("secretNameLabel")).toContain("monitoring.alertmanagerConfig.pagerDuty.serviceKey")}),it("should clear other key when integration type changes",async()=>{const t=(0,r.Ky)(i["default"],{props:{...e,value:{routingKey:{name:"r",key:"k"}}},global:{mocks:{$fetchState:{pending:!1,error:null}}}});t.vm.integrationType="Prometheus",await t.vm.$nextTick(),expect(t.props("value").routingKey).toBeNull()}),it("should update routing key secret",async()=>{const t=(0,r.Ky)(i["default"],{props:e,global:{mocks:{$fetchState:{pending:!1,error:null}}}}),n=t.findComponent({name:"SimpleSecretSelector"});await n.vm.$emit("updateSecretName","routing-name"),await n.vm.$emit("updateSecretKey","routing-key"),expect(t.props("value").routingKey.name).toBe("routing-name"),expect(t.props("value").routingKey.key).toBe("routing-key")}),it("should update service key secret",async()=>{const t=(0,r.Ky)(i["default"],{props:{...e,value:{serviceKey:{}}},global:{mocks:{$fetchState:{pending:!1,error:null}}}}),n=t.findComponent({name:"SimpleSecretSelector"});await n.vm.$emit("updateSecretName","service-name"),await n.vm.$emit("updateSecretKey","service-key"),expect(t.props("value").serviceKey.name).toBe("service-name"),expect(t.props("value").serviceKey.key).toBe("service-key")}),it("should update proxy URL",async()=>{const t=(0,r.Ky)(i["default"],{props:e,global:{mocks:{$fetchState:{pending:!1,error:null}}}}),n=t.findComponent({name:"LabeledInput"});await n.vm.$emit("update:value","http://proxy.com"),expect(t.props("value").httpConfig.proxyURL).toBe("http://proxy.com")}),it("should toggle send resolved alerts",async()=>{const t=(0,r.Ky)(i["default"],{props:e,global:{mocks:{$fetchState:{pending:!1,error:null}}}}),n=t.findComponent(o.S);await n.vm.$emit("update:value",!1),expect(t.props("value").sendResolved).toBe(!1)}),it("should render in view mode",()=>{const t=(0,r.Ky)(i["default"],{props:{...e,mode:"view"},global:{mocks:{$fetchState:{pending:!1,error:null}}}});expect(t.findComponent({name:"LabeledSelect"}).attributes("mode")).toBe("view"),expect(t.findComponent({name:"SimpleSecretSelector"}).props("disabled")).toBe(!0),expect(t.findComponent({name:"LabeledInput"}).attributes("mode")).toBe("view"),expect(t.findComponent(o.S).attributes("mode")).toBe("view")}),it("should show banner if no namespace is provided",()=>{const t=(0,r.Ky)(i["default"],{props:{...e,namespace:""},global:{mocks:{$fetchState:{pending:!1,error:null}}}});expect(t.findComponent({name:"Banner"}).exists()).toBe(!0)})})},90828:function(e,t,n){"use strict";n.r(t);var r=n(81073),i=n(33427),o=n(42200),a=n(79380),s=n(14220);describe("component: Slack.vue",()=>{const e={mode:"edit",value:{},namespace:"test-namespace"};it("should render correctly with initial props",()=>{const t=(0,r.Ky)(i["default"],{props:e,global:{mocks:{$fetchState:{pending:!1,error:null}}}}),n=t.findAll("h3");expect(n[0].text()).toBe("Target"),expect(t.findComponent({name:"SimpleSecretSelector"}).exists()).toBe(!0),expect(t.findAllComponents(a.o)).toHaveLength(2),expect(t.findComponent(o.S).exists()).toBe(!0)}),it("should initialize text template in create mode",()=>{const t=(0,r.Ky)(i["default"],{props:{...e,mode:s.YQ},global:{mocks:{$fetchState:{pending:!1,error:null}}}});expect(t.props("value").text).toBe('{{ template "slack.rancher.text" . }}')}),it("should update API URL secret",async()=>{const t=(0,r.Ky)(i["default"],{props:e,global:{mocks:{$fetchState:{pending:!1,error:null}}}}),n=t.findComponent({name:"SimpleSecretSelector"});await n.vm.$emit("updateSecretName","my-secret"),await n.vm.$emit("updateSecretKey","my-key"),expect(t.props("value").apiURL.name).toBe("my-secret"),expect(t.props("value").apiURL.key).toBe("my-key")}),it("should update default channel",async()=>{const t=(0,r.Ky)(i["default"],{props:e,global:{mocks:{$fetchState:{pending:!1,error:null}}}}),n=t.findAllComponents(a.o)[0];await n.vm.$emit("update:value","#my-channel"),expect(t.props("value").channel).toBe("#my-channel")}),it("should update proxy URL",async()=>{const t=(0,r.Ky)(i["default"],{props:e,global:{mocks:{$fetchState:{pending:!1,error:null}}}}),n=t.findAllComponents(a.o)[1];await n.vm.$emit("update:value","http://my-proxy.com"),expect(t.props("value").httpConfig.proxyURL).toBe("http://my-proxy.com")}),it("should toggle send resolved alerts",async()=>{const t=(0,r.Ky)(i["default"],{props:e,global:{mocks:{$fetchState:{pending:!1,error:null}}}}),n=t.findComponent(o.S);await n.vm.$emit("update:value",!0),expect(t.props("value").sendResolved).toBe(!0)}),it("should render in view mode",()=>{const t=(0,r.Ky)(i["default"],{props:{...e,mode:"view"},global:{mocks:{$fetchState:{pending:!1,error:null}}}});expect(t.findComponent({name:"SimpleSecretSelector"}).props("disabled")).toBe(!0);const n=t.findAllComponents(a.o);expect(n[0].props("mode")).toBe("view"),expect(n[1].props("mode")).toBe("view"),expect(t.findComponent(o.S).props("mode")).toBe("view")}),it("should show banner if no namespace is provided",()=>{const t=(0,r.Ky)(i["default"],{props:{...e,namespace:""},global:{mocks:{$fetchState:{pending:!1,error:null}}}});expect(t.findComponent({name:"Banner"}).exists()).toBe(!0)})})},25192:function(e,t,n){"use strict";n.r(t);var r=n(41212),i=n(35664);describe("class Deployment",()=>{describe("replicaSetId",()=>{it.each([{relationships:[],expected:void 0},{relationships:[{rel:"owner",toType:i.oU.REPLICA_SET,toId:"rel-id"}],expected:"rel-id"},{relationships:[{rel:"owner",toType:i.oU.REPLICA_SET,toId:"rel-id-1",message:"ReplicaSet is available. Replicas: 1"}],expected:"rel-id-1"},{relationships:[{rel:"owner",toType:i.oU.REPLICA_SET,toId:"rel-id-1",message:"ReplicaSet is available. Replicas: 0"},{rel:"owner",toType:i.oU.REPLICA_SET,toId:"rel-id-2",message:"ReplicaSet is available. Replicas: 1"}],expected:"rel-id-2"},{relationships:[{rel:"owner",toType:i.oU.REPLICA_SET,toId:"rel-id-1",message:"Message without replicas count"},{rel:"owner",toType:i.oU.REPLICA_SET,toId:"rel-id-2",message:"Another message without replicas count"}],expected:"rel-id-1"},{relationships:[{rel:"owner",toType:i.oU.REPLICA_SET,toId:"rel-id-1",message:"ReplicaSet is available. Replicas: 0"},{rel:"owner",toType:i.oU.REPLICA_SET,toId:"rel-id-2",message:"ReplicaSet is available. Replicas: 0"}],expected:"rel-id-1"},{relationships:[{rel:"owner",toType:i.oU.REPLICA_SET,toId:"rel-id-1",message:"Message without replicas count"},{rel:"owner",toType:i.oU.REPLICA_SET,toId:"rel-id-2",message:"ReplicaSet is available. Replicas: 0"}],expected:"rel-id-1"}])("replicaSetId",({relationships:e,expected:t})=>{const n={id:"any-id",type:i.oU.DEPLOYMENT,metadata:{name:"any-name",namespace:"any-namespace",uid:"any-uid",relationships:e}},o=new r["default"](n);expect(o.replicaSetId).toStrictEqual(t)})})})},83805:function(e,t,n){"use strict";n.r(t);var r=n(77763),i=n(35664),o=n(38823),a=n(2841),s=n(4364);const l=JSON.stringify([{addresses:["172.18.0.3"],port:32767,protocol:"TCP",serviceName:"default:frontend",allNodes:!0},{addresses:["172.18.0.3"],port:32e3,protocol:"TCP",serviceName:"default:frontend",allNodes:!0}]),c=[{name:"state"},{name:"type"},{name:"namespace"},{name:"age"}],u=(e={},{endpoints:t,glance:n=c,rootGetters:o={},getters:s={}}={})=>{const l=new r["default"]({type:i.oU.REPLICA_SET,metadata:{name:"frontend-567d5b464c",namespace:"default",annotations:void 0===t?void 0:{[a.bs]:t}},...e},{getters:{schemaFor:jest.fn(()=>({id:i.oU.REPLICA_SET})),...s},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e,"cluster/typeRegistered":()=>!1,"cluster/schemaFor":()=>{},...o}});return Object.defineProperty(l,"_glance",{get:()=>n}),l},d=(e,t)=>e.glance.find(e=>e.name===t);describe("class ReplicaSet",()=>{describe("glance",()=>{it("should add the ready, pod restarts and endpoints rows before the age",()=>{const e=u({spec:{replicas:3},status:{readyReplicas:3}});expect(e.glance.map(e=>e.name)).toStrictEqual(["state","type","namespace","ready","podRestarts","endpoints","age"])}),it("should add the rows at the end when there is no age row",()=>{const e=u({spec:{replicas:3},status:{readyReplicas:3}},{glance:[{name:"state"}]});expect(e.glance.map(e=>e.name)).toStrictEqual(["state","ready","podRestarts","endpoints"])}),it.each([["all replicas ready",3,3,3,void 0],["some replicas not ready",3,1,1,void 0],["no replica ready",3,void 0,0,void 0],["scaled to zero",0,void 0,0,"none"]])("should show the ready replicas when %s",(e,t,n,r,i)=>{const o=u({spec:{replicas:t},status:{readyReplicas:n}});expect(d(o,"ready")).toStrictEqual({name:"ready",label:"component.resource.detail.glance.ready",formatter:"ReadyIndicator",formatterOpts:{ready:r,total:t,status:i},content:`${r}/${t}`})}),it("should count ready replicas, not replicas that are merely created",()=>{const e=u({spec:{replicas:3},status:{replicas:3,readyReplicas:0}}),t=d(e,"ready");expect(t.content).toStrictEqual("0/3"),expect(t.formatterOpts).toStrictEqual({ready:0,total:3,status:void 0})}),it("should show no replicas to be ready when there are no spec replicas or status",()=>{const e=u(),t=d(e,"ready");expect(t.content).toStrictEqual("0/0"),expect(t.formatterOpts.status).toStrictEqual("none")}),it("should show the pod restarts with a formatter that fetches the pods of this ReplicaSet",()=>{const e=u({spec:{replicas:3}});expect(d(e,"podRestarts")).toStrictEqual({name:"podRestarts",label:"component.resource.detail.glance.podRestarts",formatter:"WorkloadPodRestarts",formatterOpts:{row:e}})}),it("should show the endpoints annotation with a formatter that renders it like the ReplicaSets list Endpoints column",()=>{const e=u({spec:{replicas:3}},{endpoints:l});expect(d(e,"endpoints")).toStrictEqual({name:"endpoints",label:"component.resource.detail.glance.endpoints",formatter:"WorkloadGlanceEndpoints",formatterOpts:{row:e,col:{}},content:l})}),it("should show a dash rather than drop the endpoints row when there are no endpoints",()=>{const e=u({spec:{replicas:3}}),t=d(e,"endpoints");expect(t.formatter).toBeUndefined(),expect(t.content).toStrictEqual("—")}),it("should show a dash when the endpoints annotation is malformed",()=>{const e=jest.spyOn(s,"warn").mockImplementation(()=>{}),t=u({spec:{replicas:3}},{endpoints:"not json"}),n=d(t,"endpoints");expect(n.formatter).toBeUndefined(),expect(n.content).toStrictEqual("—"),e.mockRestore()})}),describe("ready",()=>{it.each([["all replicas ready",{replicas:3},{replicas:3,readyReplicas:3},"3/3"],["no replica ready, although all of them are created",{replicas:3},{replicas:3},"0/3"],["some replicas ready",{replicas:3},{replicas:3,readyReplicas:1},"1/3"],["more replicas ready than desired, while scaling down",{replicas:1},{replicas:3,readyReplicas:3},"3/1"],["scaled to zero",{replicas:0},{replicas:0},"0/0"],["no status yet",{replicas:3},void 0,"0/3"]])("should show the ready replicas out of the desired ones when %s, like kubectl",(e,t,n,r)=>{const i=u({spec:t,status:n});expect(i.ready).toStrictEqual(r)}),it("should show the ready replicas in the Ready row of the masthead",()=>{const e=u({spec:{replicas:3},status:{replicas:3,readyReplicas:0}}),t=e.details.find(e=>"Ready"===e.label);expect(t.content).toStrictEqual("0/3")})}),describe("glanceGatewayEndpoints",()=>{const e=[{link:"http://shop.example.com/shop",linkDisplay:"http://shop.example.com/shop"}],t=(t,n={})=>{const r=u({spec:{replicas:3}},{...n,rootGetters:{"cluster/typeRegistered":e=>t.includes(e)}}),i=jest.fn(()=>e);return Object.defineProperty(r,"gatewayEndpoints",{get:i}),{replicaSet:r,getGatewayEndpoints:i}};it("should be the gateway endpoints once the services, HTTPRoutes and gateways are in the store",()=>{const{replicaSet:n}=t([i.YV,i.Yq.HTTP_ROUTE,i.Yq.GATEWAY]);expect(n.glanceGatewayEndpoints).toStrictEqual(e)}),it.each([["services",[i.Yq.HTTP_ROUTE,i.Yq.GATEWAY]],["HTTPRoutes",[i.YV,i.Yq.GATEWAY]],["gateways",[i.YV,i.Yq.HTTP_ROUTE]],["services, HTTPRoutes or gateways",[]]])("should be empty, without working them out, when the store has no %s yet",(e,n)=>{const{replicaSet:r,getGatewayEndpoints:i}=t(n);expect(r.glanceGatewayEndpoints).toStrictEqual([]),expect(i).toHaveBeenCalledTimes(0)})}),describe("endpoints row with the Gateway API",()=>{const e=[i.YV,i.Yq.HTTP_ROUTE,i.Yq.GATEWAY],t=(e,t={})=>u({spec:{replicas:3}},{...t,rootGetters:{"cluster/schemaFor":t=>e.includes(t)?{id:t}:void 0}});it("should use the formatter that fetches the gateway endpoints when there are no public endpoints",()=>{const n=t(e);expect(d(n,"endpoints")).toStrictEqual({name:"endpoints",label:"component.resource.detail.glance.endpoints",formatter:"WorkloadGlanceEndpoints",formatterOpts:{row:n,col:{}},content:"—"})}),it("should pass on the public endpoints annotation as well",()=>{const n=t(e,{endpoints:l}),r=d(n,"endpoints");expect(r.formatter).toStrictEqual("WorkloadGlanceEndpoints"),expect(r.content).toStrictEqual(l)}),it.each([["services",[i.Yq.HTTP_ROUTE,i.Yq.GATEWAY]],["HTTPRoutes, e.g. on a cluster without the Gateway API",[i.YV,i.Yq.GATEWAY]],["gateways",[i.YV,i.Yq.HTTP_ROUTE]]])("should show a dash without a formatter when the user can not see %s and there are no public endpoints",(e,n)=>{const r=t(n),i=d(r,"endpoints");expect(i.formatter).toBeUndefined(),expect(i.content).toStrictEqual("—")})}),describe("fetchGatewayEndpointResources",()=>{const e=[i.YV,i.Yq.HTTP_ROUTE,i.Yq.GATEWAY],t=e=>u({spec:{replicas:3}},{rootGetters:{"cluster/schemaFor":t=>e.includes(t)?{id:t}:void 0}});it("should fetch the services in the namespace, the HTTPRoutes and the gateways, like the workload detail page",async()=>{const n=t(e);await n.fetchGatewayEndpointResources(),expect(n.$dispatch).toHaveBeenCalledTimes(3),expect(n.$dispatch).toHaveBeenCalledWith("cluster/findAll",{type:i.YV,opt:{namespaced:"default"}},{root:!0}),expect(n.$dispatch).toHaveBeenCalledWith("cluster/findAll",{type:i.Yq.HTTP_ROUTE},{root:!0}),expect(n.$dispatch).toHaveBeenCalledWith("cluster/findAll",{type:i.Yq.GATEWAY},{root:!0})}),it.each([["services",[i.Yq.HTTP_ROUTE,i.Yq.GATEWAY]],["HTTPRoutes, e.g. on a cluster without the Gateway API",[i.YV,i.Yq.GATEWAY]],["gateways",[i.YV,i.Yq.HTTP_ROUTE]]])("should fetch nothing when the user can not see %s, as there can be no gateway endpoints",async(e,n)=>{const r=t(n);await r.fetchGatewayEndpointResources(),expect(r.$dispatch).toHaveBeenCalledTimes(0)}),it("should fail when they can not be fetched, so the card can show that there are none",async()=>{const n=t(e);n.$dispatch.mockRejectedValue(new Error("forbidden")),await expect(n.fetchGatewayEndpointResources()).rejects.toThrow("forbidden")})}),describe("podsInStore",()=>{const e={matchLabels:{app:"frontend","pod-template-hash":"567d5b464c"}},t=e=>({metadata:{name:e,namespace:"default"}}),n=(t,{status:n={replicas:3},registered:r=!0,spec:o={selector:e}}={})=>u({spec:o,status:n},{getters:{typeRegistered:jest.fn(e=>r&&e===i.Sm),matching:jest.fn(()=>t)}});it("should look up the pods matching the selector in the namespace of the ReplicaSet",()=>{const t=n([]);t.podsInStore,expect(t.$getters.matching).toHaveBeenCalledWith(i.Sm,(0,o._R)(e),"default")}),it("should return the pods when the store has all of them, e.g. on the page of the Deployment",()=>{const e=[t("a"),t("b"),t("c")];expect(n(e).podsInStore).toStrictEqual(e)}),it("should return the pods when the store has more than the ReplicaSet counts, e.g. one still terminating",()=>{const e=[t("a"),t("b"),t("c"),t("d")];expect(n(e).podsInStore).toStrictEqual(e)}),it("should return nothing when the store only has some of them, e.g. on the page of one of its pods",()=>{expect(n([t("a")]).podsInStore).toBeUndefined()}),it.each([["no replicas",{replicas:0}],["no replica count",{}]])("should return no pods for a ReplicaSet with %s",(e,t)=>{expect(n([],{status:t}).podsInStore).toStrictEqual([])}),it("should return nothing without asking the store when it has never loaded pods",()=>{const e=n([t("a"),t("b"),t("c")],{registered:!1});expect(e.podsInStore).toBeUndefined(),expect(e.$getters.matching).toHaveBeenCalledTimes(0)}),it("should return nothing when the ReplicaSet has no selector, rather than match every pod",()=>{const e=n([t("a"),t("b"),t("c")],{spec:{}});expect(e.podsInStore).toBeUndefined(),expect(e.$getters.matching).toHaveBeenCalledTimes(0)})}),describe("fetchGlancePods",()=>{const e=e=>{const t=u({spec:{replicas:3}});return t.metadata.resourceVersion="100",t.matchingPods=jest.fn(e),t};it("should fetch the pods of the ReplicaSet",async()=>{const t=[{id:"default/a"}],n=e(()=>Promise.resolve(t));await expect(n.fetchGlancePods()).resolves.toStrictEqual(t),expect(n.matchingPods).toHaveBeenCalledWith()}),it("should not fetch them again when the card opens again and the ReplicaSet has not changed",async()=>{const t=[{id:"default/a"}],n=e(()=>Promise.resolve(t));await n.fetchGlancePods(),await expect(n.fetchGlancePods()).resolves.toStrictEqual(t),expect(n.matchingPods).toHaveBeenCalledTimes(1)}),it("should fetch them again once the ReplicaSet has changed",async()=>{const t=e(()=>Promise.resolve([]));await t.fetchGlancePods(),t.metadata.resourceVersion="101",await t.fetchGlancePods(),expect(t.matchingPods).toHaveBeenCalledTimes(2)}),it("should keep the pods of each ReplicaSet apart",async()=>{const t=e(()=>Promise.resolve([{id:"default/a"}])),n=e(()=>Promise.resolve([{id:"default/b"}]));await t.fetchGlancePods(),await expect(n.fetchGlancePods()).resolves.toStrictEqual([{id:"default/b"}])}),it("should fetch them again after a failure",async()=>{const t=e(()=>Promise.reject(new Error("forbidden")));await expect(t.fetchGlancePods()).rejects.toThrow("forbidden"),await expect(t.fetchGlancePods()).rejects.toThrow("forbidden"),expect(t.matchingPods).toHaveBeenCalledTimes(2)})})})},34700:function(e,t,n){"use strict";n.r(t);var r=n(8488);describe("auditPolicy Model",()=>{let e,t,n;beforeEach(()=>{e=jest.fn(),t=jest.fn();const i={id:"test-policy",spec:{enabled:!1},metadata:{name:"test-policy"}};n=new r["default"](i,{dispatch:e,rootGetters:{"i18n/t":t},getters:{schemaFor:()=>({linkFor:jest.fn()})}})}),describe("enable method",()=>{it('should call enableOrDisable with "enable"',()=>{const e=jest.spyOn(n,"enableOrDisable").mockImplementation();n.enable(),expect(e).toHaveBeenCalledWith("enable")})}),describe("disable method",()=>{it('should call enableOrDisable with "disable"',()=>{const e=jest.spyOn(n,"enableOrDisable").mockImplementation();n.disable(),expect(e).toHaveBeenCalledWith("disable")})}),describe("enableOrDisable method",()=>{let r;beforeEach(()=>{r={spec:{enabled:!1},save:jest.fn()},e.mockImplementation(e=>"rancher/clone"===e?Promise.resolve(r):Promise.resolve())}),it('should enable policy when flag is "enable"',async()=>{r.save.mockResolvedValue({}),await n.enableOrDisable("enable"),expect(r.spec.enabled).toBe(!0),expect(r.save).toHaveBeenCalledWith()}),it('should disable policy when flag is "disable"',async()=>{r.save.mockResolvedValue({}),await n.enableOrDisable("disable"),expect(r.spec.enabled).toBe(!1),expect(r.save).toHaveBeenCalledWith()}),it("should handle save errors and show growl notification",async()=>{const i=new Error("Save failed");r.save.mockRejectedValue(i),t.mockReturnValue("Error when enabling - test-policy"),await n.enableOrDisable("enable"),expect(e).toHaveBeenCalledWith("growl/fromError",{title:"Error when enabling - test-policy",err:i,timeout:5e3},{root:!0})}),it("should call translation with correct parameters",async()=>{const e=new Error("Save failed");r.save.mockRejectedValue(e),await n.enableOrDisable("enable"),expect(t).toHaveBeenCalledWith("auditPolicy.error.enableOrDisable",{flag:"enable",id:"test-policy"})}),it("should dispatch rancher/clone with correct parameters",async()=>{r.save.mockResolvedValue({}),await n.enableOrDisable("enable"),expect(e).toHaveBeenCalledWith("rancher/clone",{resource:n},{root:!0})})})})},8432:function(e,t,n){"use strict";n.r(t);var r=n(43020);describe("class Cronjob",()=>{it("should have no ownerReferences by default",()=>{const e={id:"any-id",type:"batch.job",apiVersion:"batch/v1",kind:"Job",metadata:{name:"any-name",namespace:"any-namespace",uid:"any-uid"},spec:{jobTemplate:{}}},t={name:"any-name",namespace:"any-namespace",uid:"any-uid"},n=new r["default"](e);expect(n.metadata).toStrictEqual(t)}),describe("method runNow",()=>{it("should populate job metadata",async()=>{const e={id:"any-id",type:"batch.job",apiVersion:"batch/v1",kind:"Job",metadata:{name:"any-name",namespace:"any-namespace",uid:"any-uid"},spec:{jobTemplate:{}}},t=Date.now(),n={name:`${e.metadata.name}-${t}`,namespace:e.metadata.namespace,ownerReferences:[{apiVersion:"batch/v1",controller:!0,kind:"Job",name:e.metadata.name,uid:e.metadata.uid}],uid:e.metadata.uid},i=()=>({...e,save:jest.fn(),goToDetail:jest.fn()}),o=new r["default"](e,{dispatch:i});jest.useFakeTimers().setSystemTime(t),jest.spyOn(o,"$dispatch").mockImplementation(i),await o.runNow(),expect(o.metadata).toStrictEqual(n)}),it("should redirect to another page",async()=>{const e={metadata:{name:"any-name"},spec:{jobTemplate:{}}},t=jest.fn(),n=()=>({...e,save:jest.fn(),goToDetail:t}),i=new r["default"](e,{dispatch:n});jest.spyOn(i,"$dispatch").mockImplementation(n),await i.runNow(),expect(t).toHaveBeenCalledWith()})})})},94226:function(e,t,n){"use strict";n.r(t);var r=n(65502),i=n(7325),o=n(2841);const a="1.16.2",s="1.16.1",l="cert-manager",c={repoName:"appCo",home:"https://apps.rancher.io/applications/cert-manager"},u={repoName:"certManagerOfficial",home:"https://cert-manager.io",oldHome:"https://github.com/jetstack/cert-manager"},d={name:l,repoName:c.repoName,versions:[{version:a,home:c.home,repoName:c.repoName,annotations:{}},{version:s,home:c.home,repoName:c.repoName,annotations:{}}]},h={name:l,repoName:c.repoName,versions:[{version:a,home:c.home,repoName:c.repoName,annotations:{}},{version:s,home:c.home,repoName:c.repoName,annotations:{}}]},p={name:l,repoName:u.repoName,versions:[{version:a,home:u.home,repoName:u.repoName,annotations:{}},{version:s,home:u.oldHome,repoName:u.repoName,annotations:{}}]},f={name:l,repoName:u.repoName,versions:[{version:a,home:u.home,repoName:u.repoName,annotations:{}},{version:s,home:u.oldHome,repoName:u.repoName,annotations:{}}]},m={name:l,repoName:u.repoName,versions:[{version:a,home:u.home,repoName:u.repoName,annotations:{}}]},g={metadata:{annotations:{[o.W8.SOURCE_REPO_NAME]:c.repoName},name:l,home:c.home,version:s}},v={metadata:{name:l,home:u.oldHome,version:s}},b={metadata:{annotations:{[o.W8.SOURCE_REPO_NAME]:u.repoName},name:l,home:u.oldHome,version:s}};describe("class CatalogApp",()=>{describe("upgradeAvailable",()=>{const e=[[v,[],i.I0.NO_UPGRADE],[v,[d],i.I0.NO_UPGRADE],[v,[d,h],i.I0.NO_UPGRADE],[v,[d,h,p],i.I0.SINGLE_UPGRADE],[g,[],i.I0.NO_UPGRADE],[g,[d],i.I0.SINGLE_UPGRADE],[g,[d,p],i.I0.SINGLE_UPGRADE],[g,[d,h],i.I0.MULTIPLE_UPGRADES],[b,[],i.I0.NO_UPGRADE],[b,[p],i.I0.SINGLE_UPGRADE],[b,[p,d],i.I0.SINGLE_UPGRADE],[b,[p,f],i.I0.MULTIPLE_UPGRADES],[b,[m],i.I0.SINGLE_UPGRADE]];it.each(e)("should return the correct upgrade status",(e,t,n)=>{const i=new r["default"]({spec:{chart:e}},{rootGetters:{"catalog/chart":()=>t,currentCluster:{workerOSs:["linux"]},"prefs/get":()=>!1}});expect(i.upgradeAvailable).toBe(n)})}),describe("valuesLoaded",()=>{it("should be false if data is missing (e.g. secret)",()=>{const e=new r["default"]({});jest.spyOn(e,"_secret","get").mockReturnValue(null),expect(e.valuesLoaded).toBe(!1)}),it("should be false if part of the data is missing",()=>{const e=new r["default"]({});jest.spyOn(e,"_secret","get").mockReturnValue({data:{}}),expect(e.valuesLoaded).toBe(!1)}),it("should be true if all required data is present",()=>{const e=new r["default"]({});jest.spyOn(e,"_secret","get").mockReturnValue({data:{release:{config:{foo:"bar"},chart:{values:{baz:"qux"}}}}}),expect(e.valuesLoaded).toBe(!0)})})})},42173:function(e,t,n){"use strict";n.r(t);var r=n(75348),i=n(35664),o=n(9262);describe("clusterRepo",()=>{let e;beforeEach(()=>{e=new r["default"]({metadata:{name:"test-repo"},spec:{url:"https://test-url.com"}},{getters:{},dispatch:jest.fn(),rootGetters:{}}),jest.spyOn(e,"_key","get").mockReturnValue("test-key"),jest.spyOn(e,"save").mockImplementation().mockResolvedValue(!0),jest.spyOn(e,"waitForState").mockImplementation().mockResolvedValue(!0),jest.spyOn(e,"$dispatch","get").mockReturnValue(jest.fn()),jest.spyOn(e,"t","get").mockReturnValue(e=>e)}),describe("refresh",()=>{it("updates forceUpdate, saves, waits for active state, and dispatches load by default",async()=>{const t=new Date("2023-01-01T12:00:00.000Z"),r=jest.spyOn(n.g,"Date").mockImplementation(()=>t);await e.refresh(),expect(e.spec.forceUpdate).toBe("2023-01-01T12:00:00Z"),expect(e.save).toHaveBeenCalledWith(),expect(e.waitForState).toHaveBeenCalledWith("active",3e4,1e3),expect(e.$dispatch).toHaveBeenCalledWith("catalog/load",{force:!0,repoKeys:[e._key]},{root:!0}),r.mockRestore()}),it("updates forceUpdate, saves, waits for active state, but DOES NOT dispatch load if dispatchLoad is false",async()=>{await e.refresh(!1),expect(e.save).toHaveBeenCalledWith(),expect(e.waitForState).toHaveBeenCalledWith("active",3e4,1e3),expect(e.$dispatch).not.toHaveBeenCalled()}),it("dispatches error to growl if save or waitForState fails",async()=>{const t=new Error("waitForState timeout");e.waitForState.mockRejectedValue(t),jest.spyOn(e,"t","get").mockReturnValue(jest.fn().mockReturnValue("Error refreshing repository")),jest.spyOn(e,"nameDisplay","get").mockReturnValue("Test Repo"),await e.refresh(),expect(e.$dispatch).toHaveBeenCalledWith("growl/fromError",{title:"Error refreshing repository",err:t},{root:!0})})}),describe("defaultRefreshIntervalHours",()=>{it("returns 24 for OCI repos",()=>{e.spec.url="oci://example.com/chart",e.spec.insecurePlainHttp=!1,expect(e.defaultRefreshIntervalHours).toStrictEqual(24)}),it("returns 1 for git repos",()=>{e.spec={gitRepo:"https://github.com/example/charts"},expect(e.defaultRefreshIntervalHours).toStrictEqual(1)}),it("returns 1 for helm repos",()=>{e.spec={url:"https://charts.example.com"},expect(e.defaultRefreshIntervalHours).toStrictEqual(1)})}),describe("defaultRefreshInterval",()=>{it("returns seconds for OCI repos (24 hours)",()=>{e.spec.url="oci://example.com/chart",e.spec.insecurePlainHttp=!1,expect(e.defaultRefreshInterval).toStrictEqual(86400)}),it("returns seconds for non-OCI repos (1 hour)",()=>{e.spec={gitRepo:"https://github.com/example/charts"},expect(e.defaultRefreshInterval).toStrictEqual(3600)})}),describe("refreshIntervalDisplay",()=>{it.each([-1,-100])('returns "Disabled" when value is %p',t=>{e.spec.refreshInterval=t,expect(e.refreshIntervalDisplay).toStrictEqual("generic.disabled")}),it("returns formatted duration for positive values",()=>{e.spec.refreshInterval=3661,expect(e.refreshIntervalDisplay).toStrictEqual("1h 1m 1s")}),it("returns default formatted duration when not set",()=>{e.spec={url:"https://charts.example.com"},expect(e.refreshIntervalDisplay).toStrictEqual("1h")}),it("returns default formatted duration for OCI when not set",()=>{e.spec={url:"oci://example.com/chart",insecurePlainHttp:!1},expect(e.refreshIntervalDisplay).toStrictEqual("1d")})}),describe("isRancherSource",()=>{const e=(e,t,n)=>{const a=jest.fn((e,t)=>{if(e===i.Mc.SETTING&&t===o.HG.SYSTEM_CATALOG)return void 0===n?void 0:{value:n}});return new r["default"]({metadata:{name:t},spec:e},{getters:{},dispatch:jest.fn(),rootGetters:{"management/byId":a}})};it("returns true for a *.rancher.io url regardless of environment",()=>{expect(e({url:"https://charts.rancher.io"},"rancher-charts","external").isRancherSource).toBe(!0)}),it("returns false for a mirrored url in a connected environment",()=>{expect(e({url:"https://internal-mirror.example.com/charts"},"rancher-charts","external").isRancherSource).toBe(!1)}),it.each(["rancher-charts","rancher-partner-charts"])("returns true for a mirrored %p repo in an airgap environment",t=>{expect(e({url:"https://internal-mirror.example.com/charts"},t,"bundled").isRancherSource).toBe(!0)}),it("returns false for a mirrored repo with a non-rancher name in an airgap environment",()=>{expect(e({url:"https://internal-mirror.example.com/charts"},"my-charts","bundled").isRancherSource).toBe(!1)}),it("returns false when the system-catalog setting is not exactly bundled",()=>{expect(e({url:"https://internal-mirror.example.com/charts"},"rancher-charts","bundle").isRancherSource).toBe(!1)}),it("returns false when the system-catalog setting is missing",()=>{expect(e({url:"https://internal-mirror.example.com/charts"},"rancher-charts",void 0).isRancherSource).toBe(!1)}),describe("isAirgapMirror",()=>{it.each(["rancher-charts","rancher-partner-charts"])("returns true for a mirrored %p repo in an airgap environment",t=>{expect(e({url:"https://internal-mirror.example.com/charts"},t,"bundled").isAirgapMirror).toBe(!0)}),it("returns false for a *.rancher.io url in an airgap environment",()=>{expect(e({url:"https://charts.rancher.io"},"rancher-charts","bundled").isAirgapMirror).toBe(!1)}),it("returns false for a mirrored repo in a connected environment",()=>{expect(e({url:"https://internal-mirror.example.com/charts"},"rancher-charts","external").isAirgapMirror).toBe(!1)}),it("returns false for a non-rancher name in an airgap environment",()=>{expect(e({url:"https://internal-mirror.example.com/charts"},"my-charts","bundled").isAirgapMirror).toBe(!1)})})}),describe("refreshBulk",()=>{it("calls refresh(false) on all items and then dispatches a single catalog/load with all repoKeys",async()=>{const t={_key:"repo-1",refresh:jest.fn().mockResolvedValue(!0)},n={_key:"repo-2",refresh:jest.fn().mockResolvedValue(!0)};await e.refreshBulk([t,n]),expect(t.refresh).toHaveBeenCalledWith(!1),expect(n.refresh).toHaveBeenCalledWith(!1),expect(e.$dispatch).toHaveBeenCalledWith("catalog/load",{force:!0,repoKeys:["repo-1","repo-2"]},{root:!0})})})})},44775:function(e,t,n){"use strict";n.r(t);var r=n(92737),i=n(7325),o=n(2841),a=n(35664),s=n(11524);jest.mock("@shell/utils/chart",()=>({getLatestCompatibleVersion:jest.fn()}));const l=jest.fn(e=>e),c=jest.fn(),u={chartName:"my-app",repoName:"my-repo",repoNameDisplay:"My Repo",versions:[{version:"1.3.0",home:"https://example.com",created:"2024-03-10T12:00:00Z"},{version:"1.2.3",home:"https://example.com"}],categories:[],tags:[],deprecated:!1};function d(e=i.I0.NO_UPGRADE){return{spec:{chart:{metadata:{name:"my-app",version:"1.3.0",home:"https://example.com",annotations:{[o.W8.SOURCE_REPO_NAME]:"my-repo"}}}},metadata:{},upgradeAvailable:e}}describe("class Chart",()=>{let e;beforeEach(()=>{e={rootGetters:{"cluster/all":()=>[],"i18n/t":l,currentCluster:{workerOSs:[]},"prefs/get":()=>!1},dispatch:c},s.Gl.mockImplementation(e=>e.versions[0])}),describe("queryParams",()=>{it("should return query params with the latest compatible version",()=>{const t=new r["default"](u,e),n=t.queryParams();expect(s.Gl).toHaveBeenCalledWith(t,[],!1),expect(n).toHaveProperty("version","1.3.0")}),it("should reflect a different latest version from the mock",()=>{s.Gl.mockImplementation(e=>e.versions[1]);const t=new r["default"](u,e),n=t.queryParams();expect(n).toHaveProperty("version","1.2.3")})}),describe("matchingInstalledApps",()=>{it("matches by name, repo, and home in latest version",()=>{const t=d();e.rootGetters["cluster/all"]=()=>[t];const n=new r["default"](u,e);expect(n.matchingInstalledApps).toHaveLength(1)}),it("does not match if name is different",()=>{const t=d();t.spec.chart.metadata.name="different-app",e.rootGetters["cluster/all"]=()=>[t];const n=new r["default"](u,e);expect(n.matchingInstalledApps).toHaveLength(0)}),it("does not match if repo is different",()=>{const t=d();t.spec.chart.metadata.annotations[o.W8.SOURCE_REPO_NAME]="different-repo",e.rootGetters["cluster/all"]=()=>[t];const n=new r["default"](u,e);expect(n.matchingInstalledApps).toHaveLength(0)}),it("matches by version+home when not latest",()=>{const t=d();t.spec.chart.metadata.version="1.2.3",e.rootGetters["cluster/all"]=()=>[t];const n=new r["default"](u,e);expect(n.matchingInstalledApps).toHaveLength(1)}),it("can use fallback repo from metadata labels",()=>{const t=d();t.spec.chart.metadata.annotations={},t.metadata={labels:{[o.W8.CLUSTER_REPO_NAME]:"my-repo"}},e.rootGetters["cluster/all"]=()=>[t];const n=new r["default"](u,e);expect(n.matchingInstalledApps).toHaveLength(1)})}),describe("isInstalled",()=>{it("is true when one app matches",()=>{const t=d();t.spec.chart.metadata.version="1.2.3",e.rootGetters["cluster/all"]=()=>[t];const n=new r["default"](u,e);expect(n.isInstalled).toBe(!0)}),it("is false when no apps match",()=>{const t=new r["default"](u,e);expect(t.isInstalled).toBe(!1)}),it("is true when multiple apps match",()=>{const t=d();t.spec.chart.metadata.version="1.2.3",e.rootGetters["cluster/all"]=()=>[t,t];const n=new r["default"](u,e);expect(n.isInstalled).toBe(!0)})}),describe("upgradeable",()=>{it("is true when installed and upgradeAvailable is SINGLE_UPGRADE",()=>{const t=d(i.I0.SINGLE_UPGRADE);t.spec.chart.metadata.version="1.2.3",e.rootGetters["cluster/all"]=()=>[t];const n=new r["default"](u,e);expect(n.upgradeable).toBe(!0)}),it("is false if upgradeAvailable is different",()=>{const t=d(i.I0.NO_UPGRADE);t.spec.chart.metadata.version="1.2.3",e.rootGetters["cluster/all"]=()=>[t];const n=new r["default"](u,e);expect(n.upgradeable).toBe(!1)}),it("is false when not installed",()=>{const t=new r["default"](u,e);expect(t.upgradeable).toBe(!1)}),it("is true when at least one of multiple installed apps is upgradeable",()=>{const t=d(i.I0.NO_UPGRADE),n=d(i.I0.SINGLE_UPGRADE);e.rootGetters["cluster/all"]=()=>[t,n];const o=new r["default"](u,e);expect(o.upgradeable).toBe(!0)}),it("is false when none of multiple installed apps are upgradeable",()=>{const t=d(i.I0.NO_UPGRADE),n=d(i.I0.NO_UPGRADE);e.rootGetters["cluster/all"]=()=>[t,n];const o=new r["default"](u,e);expect(o.upgradeable).toBe(!1)})}),describe("installedCount",()=>{it("returns 0 when no apps are installed",()=>{const t=new r["default"](u,e);expect(t.installedCount).toBe(0)}),it("returns 1 when one app is installed",()=>{const t=d();e.rootGetters["cluster/all"]=()=>[t];const n=new r["default"](u,e);expect(n.installedCount).toBe(1)}),it("returns correct count when multiple apps are installed",()=>{const t=d(),n=d(),i=d();e.rootGetters["cluster/all"]=()=>[t,n,i];const o=new r["default"](u,e);expect(o.installedCount).toBe(3)})}),describe("cardContent",()=>{it("includes correct subHeader and footer info",()=>{const t=new r["default"](u,e),n=t.cardContent;expect(s.Gl).toHaveBeenCalledWith(t,[],!1),expect(n.subHeaderItems).toHaveLength(2),expect(n.subHeaderItems[0].label).toBe("1.3.0"),expect(n.subHeaderItems[1].label).toBe("Mar 10, 2024"),expect(n.footerItems).toHaveLength(1),expect(n.footerItems[0].labels).toContain("My Repo"),expect(n.statuses).toHaveLength(0)}),it("includes category and tag items when present",()=>{const t=new r["default"]({...u,categories:["database"],tags:["linux","experimentl"]},e),n=t.cardContent;expect(n.footerItems).toHaveLength(3);const i=n.footerItems.find(e=>"category-alt"===e.icon);expect(i).toBeDefined(),expect(null===i||void 0===i?void 0:i.labels).toContain("database");const o=n.footerItems.find(e=>"tag-alt"===e.icon);expect(o).toBeDefined(),expect(null===o||void 0===o?void 0:o.labels).toStrictEqual(expect.arrayContaining(["linux","experimentl"]))}),it("includes deprecated status when deprecated is true",()=>{const t=new r["default"]({...u,deprecated:!0},e),n=t.cardContent,i=n.statuses.find(e=>{var t;return"generic.deprecated"===(null===(t=e.tooltip)||void 0===t?void 0:t.key)});expect(i).toBeDefined(),expect(null===i||void 0===i?void 0:i.color).toBe("error")}),it("includes installed status when app is installed",()=>{var t;const n=d();e.rootGetters["cluster/all"]=()=>[n];const i=new r["default"](u,e),o=i.cardContent,a=o.statuses.find(e=>{var t,n;return null===(n=null===(t=e.tooltip)||void 0===t?void 0:t.text)||void 0===n?void 0:n.startsWith("generic.installed")});expect(a).toBeDefined(),expect(null===a||void 0===a?void 0:a.color).toBe("success"),expect(null===(t=null===a||void 0===a?void 0:a.tooltip)||void 0===t?void 0:t.text).toContain(n.spec.chart.metadata.version)}),it("does not include version in installed tooltip when multiple instances exist",()=>{var t;const n=d(),i=d();i.spec.chart.metadata.version="1.2.0",e.rootGetters["cluster/all"]=()=>[n,i];const o=new r["default"](u,e),a=o.cardContent,s=a.statuses.find(e=>{var t,n;return null===(n=null===(t=e.tooltip)||void 0===t?void 0:t.text)||void 0===n?void 0:n.startsWith("generic.installedMultiple")});expect(s).toBeDefined(),expect(null===s||void 0===s?void 0:s.color).toBe("success"),expect(null===(t=null===s||void 0===s?void 0:s.tooltip)||void 0===t?void 0:t.text).toBe("generic.installedMultiple")}),it("includes upgradeable status when upgrade is available",()=>{const t=d(i.I0.SINGLE_UPGRADE);e.rootGetters["cluster/all"]=()=>[t];const n=new r["default"](u,e),o=n.cardContent,a=o.statuses.find(e=>{var t;return"generic.upgradeable"===(null===(t=e.tooltip)||void 0===t?void 0:t.key)});expect(a).toBeDefined(),expect(null===a||void 0===a?void 0:a.color).toBe("info")}),it("shows all statuses together when all conditions are met",()=>{const t=d(i.I0.SINGLE_UPGRADE);e.rootGetters["cluster/all"]=()=>[t];const n=new r["default"]({...u,deprecated:!0},e),o=n.cardContent,a=o.statuses.map(e=>{var t,n,r;return(null===(t=e.tooltip)||void 0===t?void 0:t.key)?e.tooltip.key:(null===(r=null===(n=e.tooltip)||void 0===n?void 0:n.text)||void 0===r?void 0:r.startsWith("generic.installed"))?"generic.installed":void 0});expect(a).toStrictEqual(expect.arrayContaining(["generic.deprecated","generic.upgradeable","generic.installed"]))}),it("handles zero time for last updated date",()=>{const e={...u,versions:[{...u.versions[0],created:a.x8}]},t=new r["default"](e,{rootGetters:{"cluster/all":()=>[],"i18n/t":e=>e,currentCluster:{workerOSs:[]},"prefs/get":()=>!1}}),n=t.cardContent;expect(n.subHeaderItems).toHaveLength(1),expect(n.subHeaderItems[0].icon).toBe("icon-version-alt")}),it("handles falsy time for last updated date",()=>{const e={...u,versions:[{...u.versions[0],created:""}]},t=new r["default"](e,{rootGetters:{"cluster/all":()=>[],"i18n/t":e=>e,currentCluster:{workerOSs:[]},"prefs/get":()=>!1}}),n=t.cardContent;expect(n.subHeaderItems).toHaveLength(1),expect(n.subHeaderItems[0].icon).toBe("icon-version-alt")})})})},62275:function(e,t,n){"use strict";n.r(t);var r=n(45231);describe("class CloudCredential",()=>{describe("doneRoute",()=>{it("points at the cloud credential list, not the unrelated (and non-existent) secret list route",()=>{const e=new r["default"]({id:"cattle-global-data:cc-abc123"});expect(e.doneRoute).toBe("c-cluster-manager-cloudCredential")})}),describe("disableResourceDetailDrawer",()=>{it('is true, hiding "Show Configuration" since it has no custom detail component and YAML is intentionally unavailable',()=>{const e=new r["default"]({id:"cattle-global-data:cc-abc123"});expect(e.disableResourceDetailDrawer).toBe(!0)})})})},13573:function(e,t,n){"use strict";n.r(t);var r=n(16787);describe("class NormanCluster",()=>{const e=jest.fn(()=>"abc"),t={rootGetters:{"i18n/t":e},dispatch:jest.fn()};it("should return empty arrays of system labels and system annotations if cluster labels and annotations are undefined",()=>{const e=new r["default"]({},t);expect(e.systemLabels).toStrictEqual([]),expect(e.systemAnnotations).toStrictEqual([])}),it("should list all the cluster's annotation keys that contain coreos.com, cattle.io, k3s.io, kubernetes.io, or k3s.io",()=>{const e=["cattle.io/test","coreos.com","test.cattle.io/something","kubernetes.io/test"],n=new r["default"]({annotations:{"cattle.io/test":"abc","coreos.com":"abc","k3s.io/test":"abc","test.cattle.io/something":"abc","kubernetes.io/test":"abc","other-label":"abc"}},t);expect(e.find(e=>!n.systemAnnotations.includes(e))).toBeUndefined()}),it("should list all the cluster's label keys that contain io.cattle.lifecycle, kubernetes.io, cattle.io, or k3s.io",()=>{const e=["cattle.io/test","test.io.cattle.lifecycle","test.kubernetes.io/test","k3s.io/test"],n=new r["default"]({labels:{"cattle.io/test":"abc","test.io.cattle.lifecycle":"abc","k3s.io/test":"abc","test.kubernetes.io/test":"abc","other-label":"abc"}},t);expect(e.find(e=>!n.systemLabels.includes(e))).toBeUndefined()})})},9258:function(e,t,n){"use strict";n.r(t);var r=n(53622);const i=e=>new r["default"]({},{getters:{},rootGetters:{},dispatch:e}),o={spec:{customBenchmarkConfigMapName:"metadata-cm",customBenchmarkConfigMapNamespace:"compliance"}};describe("class: ClusterScan",()=>{describe("method: _resolveExportMetadata",()=>{it("returns empty metadata and decorations when the benchmark is undefined",async()=>{const e=jest.fn(),t=i(e),n=await t._resolveExportMetadata(void 0);expect(n).toStrictEqual({metadata:{},decorations:{}}),expect(e).not.toHaveBeenCalled()}),it("returns empty when the ConfigMap name is missing",async()=>{const e=jest.fn(),t=i(e),n=await t._resolveExportMetadata({spec:{customBenchmarkConfigMapNamespace:"compliance"}});expect(n).toStrictEqual({metadata:{},decorations:{}}),expect(e).not.toHaveBeenCalled()}),it("returns empty when the ConfigMap namespace is missing",async()=>{const e=jest.fn(),t=i(e),n=await t._resolveExportMetadata({spec:{customBenchmarkConfigMapName:"metadata-cm"}});expect(n).toStrictEqual({metadata:{},decorations:{}}),expect(e).not.toHaveBeenCalled()}),it("fetches the ConfigMap by namespace/name from the configmap type",async()=>{const e=jest.fn().mockResolvedValue({data:{}}),t=i(e);await t._resolveExportMetadata(o),expect(e).toHaveBeenCalledWith("find",{type:"configmap",id:"compliance/metadata-cm"})}),it("returns empty when the ConfigMap has no metadata.yaml data key",async()=>{const e=jest.fn().mockResolvedValue({data:{"other.yaml":"title: x"}}),t=i(e),n=await t._resolveExportMetadata(o);expect(n).toStrictEqual({metadata:{},decorations:{}})}),it("returns empty when the ConfigMap itself is not found",async()=>{const e=jest.fn().mockResolvedValue(void 0),t=i(e),n=await t._resolveExportMetadata(o);expect(n).toStrictEqual({metadata:{},decorations:{}})}),it("splits top-level fields into metadata and the checks map into decorations",async()=>{const e=["title: CIS Kubernetes Benchmark","description: A CIS profile","referenceType: cis","checks:",' "5.1.1":'," ruleId: CIS-5.1.1-rule"," severity: high"," idents:"," - system: https://www.cisecurity.org/controls/"," value: CIS-CSC-3",' "5.1.2":'," ruleId: CIS-5.1.2-rule"].join("\n"),t=jest.fn().mockResolvedValue({data:{"metadata.yaml":e}}),n=i(t),r=await n._resolveExportMetadata(o);expect(r.metadata).toStrictEqual({title:"CIS Kubernetes Benchmark",description:"A CIS profile",referenceType:"cis"}),expect(r.decorations).toStrictEqual({"5.1.1":{ruleId:"CIS-5.1.1-rule",severity:"high",idents:[{system:"https://www.cisecurity.org/controls/",value:"CIS-CSC-3"}]},"5.1.2":{ruleId:"CIS-5.1.2-rule"}})}),it("returns empty decorations when metadata.yaml has no checks map",async()=>{const e=["title: STIG","source: disa"].join("\n"),t=jest.fn().mockResolvedValue({data:{"metadata.yaml":e}}),n=i(t),r=await n._resolveExportMetadata(o);expect(r.metadata).toStrictEqual({title:"STIG",source:"disa"}),expect(r.decorations).toStrictEqual({})}),it("returns empty when the ConfigMap lookup rejects",async()=>{const e=jest.fn().mockRejectedValue(new Error("not found")),t=i(e),n=await t._resolveExportMetadata(o);expect(n).toStrictEqual({metadata:{},decorations:{}})}),it("returns empty when metadata.yaml is malformed YAML",async()=>{const e=jest.fn().mockResolvedValue({data:{"metadata.yaml":'title: "unterminated'}}),t=i(e),n=await t._resolveExportMetadata(o);expect(n).toStrictEqual({metadata:{},decorations:{}})})})})},90466:function(e,t,n){"use strict";n.r(t);var r=n(6856),i=n(35664);const o=r["default"];describe("class Kubeconfig",()=>{const e=jest.fn((e,t)=>'"ext.cattle.io.kubeconfig".deleted'===e?`${null===t||void 0===t?void 0:t.name} (deleted)`:e),t=(t,n={})=>{const r=new o(t);return jest.spyOn(r,"$rootGetters","get").mockReturnValue({"i18n/t":e,"management/all":()=>[],"management/byId":()=>null,...n}),r};beforeEach(()=>{jest.clearAllMocks()}),describe("expiresAt",()=>{it("should return null when ttl is not set",()=>{const e=t({metadata:{creationTimestamp:"2024-01-01T00:00:00Z"},spec:{}});expect(e.expiresAt).toBeNull()}),it("should return null when creationTimestamp is not set",()=>{const e=t({metadata:{},spec:{ttl:3600}});expect(e.expiresAt).toBeNull()}),it("should calculate expiry correctly",()=>{const e=t({metadata:{creationTimestamp:"2024-01-01T00:00:00Z"},spec:{ttl:3600}});expect(e.expiresAt).toBe("2024-01-01T01:00:00.000Z")}),it("should handle large ttl values",()=>{const e=t({metadata:{creationTimestamp:"2024-01-01T00:00:00Z"},spec:{ttl:86400}});expect(e.expiresAt).toBe("2024-01-02T00:00:00.000Z")})}),describe("referencedClusters",()=>{const n={detailLocation:{name:"c-cluster-product-resource-id",params:{cluster:"my-cluster"}}},r={id:"c-m-abc123",nameDisplay:"my-cluster",provCluster:n},o={id:"c-m-def456",nameDisplay:"mgmt-cluster",detailLocation:{name:"c-cluster-product-resource-id",params:{cluster:"mgmt-cluster"}}};it("should return empty array when no clusters are specified",()=>{const e=t({metadata:{},spec:{}});expect(e.referencedClusters).toStrictEqual([])}),it("should map provisioning cluster by mgmt id",()=>{const e=t({metadata:{},spec:{clusters:["c-m-abc123"]}},{"management/byId":(e,t)=>e===i.Mc.CLUSTER&&"c-m-abc123"===t?r:null});expect(e.referencedClusters).toStrictEqual([{label:"my-cluster",location:n.detailLocation}])}),it("should map management cluster when no provisioning cluster found",()=>{const e=t({metadata:{},spec:{clusters:["c-m-def456"]}},{"management/byId":(e,t)=>e===i.Mc.CLUSTER&&"c-m-def456"===t?o:null});expect(e.referencedClusters).toStrictEqual([{label:"mgmt-cluster",location:o.detailLocation}])}),it("should return deleted label when cluster not found",()=>{const n=t({metadata:{},spec:{clusters:["c-m-deleted"]}});expect(n.referencedClusters).toStrictEqual([{label:"c-m-deleted (deleted)",location:null}]),expect(e).toHaveBeenCalledWith('"ext.cattle.io.kubeconfig".deleted',{name:"c-m-deleted"})}),it("should prefer provisioning cluster over management cluster for location",()=>{const e={id:"c-m-abc123",nameDisplay:"my-cluster",detailLocation:{name:"mgmt-location"},provCluster:{detailLocation:{name:"prov-location"}}},n=t({metadata:{},spec:{clusters:["c-m-abc123"]}},{"management/byId":(t,n)=>t===i.Mc.CLUSTER&&"c-m-abc123"===n?e:null});expect(n.referencedClusters).toStrictEqual([{label:"my-cluster",location:{name:"prov-location"}}])})}),describe("sortedReferencedClusters",()=>{it("should sort existing clusters before deleted clusters",()=>{const e={id:"c-m-exists",nameDisplay:"existing-cluster",detailLocation:{name:"location"}},n=t({metadata:{},spec:{clusters:["deleted-1","c-m-exists","deleted-2"]}},{"management/byId":(t,n)=>t===i.Mc.CLUSTER&&"c-m-exists"===n?e:null}),r=n.sortedReferencedClusters;expect(r[0].label).toBe("existing-cluster"),expect(r[0].location).not.toBeNull(),expect(r[1].location).toBeNull(),expect(r[2].location).toBeNull()}),it("should sort existing clusters alphabetically",()=>{const e={"c-m-zebra":{id:"c-m-zebra",nameDisplay:"zebra",detailLocation:{name:"z"}},"c-m-alpha":{id:"c-m-alpha",nameDisplay:"alpha",detailLocation:{name:"a"}},"c-m-beta":{id:"c-m-beta",nameDisplay:"beta",detailLocation:{name:"b"}}},n=t({metadata:{},spec:{clusters:["c-m-zebra","c-m-alpha","c-m-beta"]}},{"management/byId":(t,n)=>t===i.Mc.CLUSTER&&e[n]||null}),r=n.sortedReferencedClusters;expect(r.map(e=>e.label)).toStrictEqual(["alpha","beta","zebra"])}),it("should sort numerically when names contain numbers",()=>{const e={"c-m-2":{id:"c-m-2",nameDisplay:"cluster2",detailLocation:{name:"c2"}},"c-m-10":{id:"c-m-10",nameDisplay:"cluster10",detailLocation:{name:"c10"}},"c-m-1":{id:"c-m-1",nameDisplay:"cluster1",detailLocation:{name:"c1"}}},n=t({metadata:{},spec:{clusters:["c-m-2","c-m-10","c-m-1"]}},{"management/byId":(t,n)=>t===i.Mc.CLUSTER&&e[n]||null}),r=n.sortedReferencedClusters;expect(r.map(e=>e.label)).toStrictEqual(["cluster1","cluster2","cluster10"])})}),describe("referencedClustersSortable",()=>{it("should return comma-separated lowercase labels",()=>{const e={"c-m-1":{id:"c-m-1",nameDisplay:"Alpha",detailLocation:{name:"a"}},"c-m-2":{id:"c-m-2",nameDisplay:"Beta",detailLocation:{name:"b"}}},n=t({metadata:{},spec:{clusters:["c-m-1","c-m-2"]}},{"management/byId":(t,n)=>t===i.Mc.CLUSTER&&e[n]||null});expect(n.referencedClustersSortable).toBe("alpha,beta")}),it("should return empty string when no clusters",()=>{const e=t({metadata:{},spec:{}});expect(e.referencedClustersSortable).toBe("")})}),describe("_availableActions",()=>{it("should filter out goToEdit, goToEditYaml, cloneYaml, and download actions",()=>{const e=t({metadata:{},spec:{}}),n=[{action:"goToClone"},{action:"divider"},{action:"goToEdit"},{action:"goToEditYaml"},{action:"cloneYaml"},{action:"download"},{action:"promptRemove"}];jest.spyOn(Object.getPrototypeOf(Object.getPrototypeOf(e)),"_availableActions","get").mockReturnValue(n);const r=e._availableActions;expect(r).toStrictEqual([{action:"goToClone"},{action:"promptRemove"}])})})})},2054:function(e,t,n){"use strict";n.r(t);var r=n(91970);describe("class FleetApplication",()=>{afterEach(()=>{jest.restoreAllMocks()}),describe("applicationType",()=>{it("should return the kind property",()=>{const e=new r["default"]({kind:"GitRepo"});expect(e.applicationType).toStrictEqual("GitRepo")})}),describe("targetClusters",()=>{function e(e,t,n="fleet-default",i=[]){const o={id:n,clusters:t,clusterGroups:i};return jest.spyOn(r["default"].prototype,"$getters","get").mockReturnValue({byId:()=>o,all:()=>[]}),new r["default"]({metadata:{namespace:n},spec:{targets:e}})}it.each([["metadata.name",[{clusterName:"c-m-abc123"}],[{id:"fleet-default/c-m-abc123",metadata:{name:"c-m-abc123"},nameDisplay:"my-cluster"}],[{id:"fleet-default/c-m-abc123",metadata:{name:"c-m-abc123"},nameDisplay:"my-cluster"}]],["nameDisplay when metadata.name does not match",[{clusterName:"my-display-name"}],[{id:"fleet-default/c-m-abc123",metadata:{name:"c-m-abc123"},nameDisplay:"my-display-name"}],[{id:"fleet-default/c-m-abc123",metadata:{name:"c-m-abc123"},nameDisplay:"my-display-name"}]]])("should find cluster by %s",(t,n,r,i)=>{const o=e(n,r);expect(o.targetClusters).toStrictEqual(i)}),it("should prefer metadata.name match over nameDisplay match",()=>{const t=[{id:"fleet-default/exact-match",metadata:{name:"exact-match"},nameDisplay:"display-a"},{id:"fleet-default/c-m-other",metadata:{name:"c-m-other"},nameDisplay:"exact-match"}],n=e([{clusterName:"exact-match"}],t);expect(n.targetClusters).toStrictEqual([t[0]])}),it("should return empty array when no cluster matches by name or nameDisplay",()=>{const t=[{id:"fleet-default/c-m-abc123",metadata:{name:"c-m-abc123"},nameDisplay:"my-cluster"}],n=e([{clusterName:"non-existent"}],t);expect(n.targetClusters).toStrictEqual([])}),it("should handle multiple targets with mixed name and nameDisplay matches",()=>{const t=[{id:"fleet-default/c-m-abc123",metadata:{name:"c-m-abc123"},nameDisplay:"cluster-alpha"},{id:"fleet-default/c-m-def456",metadata:{name:"c-m-def456"},nameDisplay:"cluster-beta"}],n=[{clusterName:"c-m-abc123"},{clusterName:"cluster-beta"}],r=e(n,t);expect(r.targetClusters).toStrictEqual([t[0],t[1]])}),it("should return empty array when targets is empty",()=>{const t=e([],[]);expect(t.targetClusters).toStrictEqual([])}),it("should return empty array when targets is undefined",()=>{const t=e(void 0,[]);expect(t.targetClusters).toStrictEqual([])}),it("should return empty array when workspace has no clusters",()=>{const t=e([{clusterName:"any-name"}],[]);expect(t.targetClusters).toStrictEqual([])}),it("should handle cluster with undefined nameDisplay gracefully",()=>{const t=[{id:"fleet-default/c-m-abc123",metadata:{name:"c-m-abc123"},nameDisplay:void 0}],n=e([{clusterName:"c-m-abc123"}],t);expect(n.targetClusters).toStrictEqual([t[0]])}),it("should return local cluster targets when workspace is fleet-local",()=>{const t=[{id:"fleet-local/local",metadata:{name:"local"},nameDisplay:"local"}],n=[{id:"fleet-local/default",targetClusters:t}],r=e([],[],"fleet-local",n);expect(r.targetClusters).toStrictEqual(t)}),it("should return empty array when workspace is fleet-local and default group is missing",()=>{const t=e([],[],"fleet-local",[]);expect(t.targetClusters).toStrictEqual([])})}),describe("state",()=>{function e(e){return new r["default"]({kind:"HelmOp",metadata:{namespace:"fleet-local",state:{name:e,error:!0}},spec:{}})}it.each([["waitingfordependency","Waiting for Dependency","text-info"],["waitapplied","Wait Applied","text-info"],["modified","Modified","text-warning"]])("should colour %s from the state, not from the error flag",(t,n,r)=>{const i=e(t);expect(i.stateDisplay).toBe(n),expect(i.stateColor).toBe(r)}),it("should still colour a state the UI classifies as an error as an error",()=>{const t=e("errapplied");expect(t.stateColor).toBe("text-error")}),it("should still describe a state whose error flag was dropped",()=>{const e=new r["default"]({kind:"HelmOp",metadata:{namespace:"fleet-local",state:{name:"waitingfordependency",error:!0,message:"waiting for dependent bundle(s)"}},spec:{}});expect(e.stateDescription).toBe("Waiting for dependent bundle(s)")})})})},6864:function(e,t,n){"use strict";n.r(t);var r=n(5096);describe("class FleetBundle",()=>{afterEach(()=>{jest.restoreAllMocks()}),describe("targetClusters",()=>{function e(e,t,n="fleet-default",i=[],o=[],a=[],s={}){const l={id:n,metadata:{name:n},clusters:t,clusterGroups:i};return jest.spyOn(r["default"].prototype,"$getters","get").mockReturnValue({byId:(e,t)=>t===n?l:a.find(e=>{var n;return(null===(n=e.metadata)||void 0===n?void 0:n.name)===t}),all:e=>"fleet.cattle.io.bundlenamespacemapping"===e?o:"management.cattle.io.fleetworkspace"===e?a:[]}),new r["default"]({metadata:{namespace:n,labels:s},spec:{targets:e}})}it.each([["metadata.name",[{clusterName:"c-m-abc123"}],[{id:"fleet-default/c-m-abc123",metadata:{name:"c-m-abc123"},nameDisplay:"my-cluster"}],[{id:"fleet-default/c-m-abc123",metadata:{name:"c-m-abc123"},nameDisplay:"my-cluster"}]],["nameDisplay when metadata.name does not match",[{clusterName:"my-display-name"}],[{id:"fleet-default/c-m-abc123",metadata:{name:"c-m-abc123"},nameDisplay:"my-display-name"}],[{id:"fleet-default/c-m-abc123",metadata:{name:"c-m-abc123"},nameDisplay:"my-display-name"}]]])("should find cluster by %s",(t,n,r,i)=>{const o=e(n,r);expect(o.targetClusters).toStrictEqual(i)}),it("should prefer metadata.name match over nameDisplay match",()=>{const t=[{id:"fleet-default/exact-match",metadata:{name:"exact-match"},nameDisplay:"display-a"},{id:"fleet-default/c-m-other",metadata:{name:"c-m-other"},nameDisplay:"exact-match"}],n=e([{clusterName:"exact-match"}],t);expect(n.targetClusters).toStrictEqual([t[0]])}),it("should return empty array when no cluster matches by name or nameDisplay",()=>{const t=[{id:"fleet-default/c-m-abc123",metadata:{name:"c-m-abc123"},nameDisplay:"my-cluster"}],n=e([{clusterName:"non-existent"}],t);expect(n.targetClusters).toStrictEqual([])}),it("should handle multiple targets with mixed name and nameDisplay matches",()=>{const t=[{id:"fleet-default/c-m-abc123",metadata:{name:"c-m-abc123"},nameDisplay:"cluster-alpha"},{id:"fleet-default/c-m-def456",metadata:{name:"c-m-def456"},nameDisplay:"cluster-beta"}],n=[{clusterName:"c-m-abc123"},{clusterName:"cluster-beta"}],r=e(n,t);expect(r.targetClusters).toStrictEqual([t[0],t[1]])}),it("should return empty array when workspace has no clusters",()=>{const t=e([{clusterName:"any-name"}],[]);expect(t.targetClusters).toStrictEqual([])}),it("should handle cluster with undefined nameDisplay gracefully",()=>{const t=[{id:"fleet-default/c-m-abc123",metadata:{name:"c-m-abc123"},nameDisplay:void 0}],n=e([{clusterName:"c-m-abc123"}],t);expect(n.targetClusters).toStrictEqual([t[0]])}),it("should not match by nameDisplay when nameDisplay is undefined and target uses a different name",()=>{const t=[{id:"fleet-default/c-m-abc123",metadata:{name:"c-m-abc123"},nameDisplay:void 0}],n=e([{clusterName:"some-other-name"}],t);expect(n.targetClusters).toStrictEqual([])}),it("should include clusters from namespaces mapped via BundleNamespaceMapping",()=>{const t=[{id:"fleet-default/c-m-mapped1",metadata:{name:"c-m-mapped1"},nameDisplay:"mapped-cluster"}],n=[{metadata:{namespace:"fleet-new"},bundleSelector:{matchLabels:{team:"one"}},namespaceSelector:{matchLabels:{"kubernetes.io/metadata.name":"fleet-default"}}}],r={id:"fleet-default",metadata:{name:"fleet-default",labels:{}},clusters:t,clusterGroups:[]},i=e([{clusterSelector:{}}],[],"fleet-new",[],n,[r],{team:"one"});expect(i.targetClusters).toStrictEqual(t)}),it("should not include clusters when bundle does not match BundleNamespaceMapping selector",()=>{const t=[{id:"fleet-default/c-m-mapped1",metadata:{name:"c-m-mapped1"},nameDisplay:"mapped-cluster"}],n=[{metadata:{namespace:"fleet-new"},bundleSelector:{matchLabels:{team:"two"}},namespaceSelector:{matchLabels:{"kubernetes.io/metadata.name":"fleet-default"}}}],r={id:"fleet-default",metadata:{name:"fleet-default",labels:{}},clusters:t,clusterGroups:[]},i=e([{clusterSelector:{}}],[],"fleet-new",[],n,[r],{team:"one"});expect(i.targetClusters).toStrictEqual([])}),it("should return local cluster targets when workspace is fleet-local",()=>{const t=[{id:"fleet-local/local",metadata:{name:"local"},nameDisplay:"local"}],n=[{id:"fleet-local/default",targetClusters:t}],r=e([],[],"fleet-local",n);expect(r.targetClusters).toStrictEqual(t)}),it("should return empty array when workspace is fleet-local and default group is missing",()=>{const t=e([],[],"fleet-local",[]);expect(t.targetClusters).toStrictEqual([])})}),describe("state",()=>{function e(e,t="",n=!1){return new r["default"]({metadata:{namespace:"fleet-local",state:{name:e,error:n,transitioning:!1,message:""}},status:{conditions:t?[{type:"Ready",status:"False",error:!0,transitioning:!0,message:t}]:[]}})}const t="WaitingForDependency(1) [Cluster fleet-local/local: waiting for dependent bundle(s) to reach an accepted state: zz-dep-broken (state: ErrApplied, accepted: Ready)]",n="ErrApplied(1) [Cluster fleet-local/local: unable to build kubernetes objects from release manifest]",i="NotReady(1) [Cluster fleet-local/local]; deployment.apps default/foo error] ReplicaSet has timed out progressing";it.each([["waitingfordependency",t,"Waiting for Dependency","text-info"],["errapplied",n,"Err Applied","text-error"],["notready",i,"Not Ready","text-warning"],["modified","Modified(1) [Cluster fleet-local/local]","Modified","text-warning"],["active","","Active","text-success"]])("should report %s as it is reported by the backend",(t,n,r,i)=>{const o=e(t,n);expect(o.state).toBe(t),expect(o.stateDisplay).toBe(r),expect(o.stateColor).toBe(i)}),it("should not report a bundle held back by a dependency as an error, even though the message names the dependency's ErrApplied state",()=>{const n=e("waitingfordependency",t);expect(n.state).not.toBe("errapplied"),expect(n.stateColor).not.toBe("text-error")}),it("should not report a bundle as an error because the word error appears in its message",()=>{const t=e("notready",i);expect(t.state).toBe("notready"),expect(t.stateColor).not.toBe("text-error")}),describe("given the backend also flags the state as an error",()=>{it.each([["waitingfordependency","text-info"],["waitapplied","text-info"],["pending","text-info"],["modified","text-warning"],["notready","text-warning"]])("should colour %s from the state, not from the flag",(t,n)=>{const r=e(t,"some message",!0),i=e(t,"some message",!1);expect(r.stateColor).toBe(n),expect(r.stateColor).toBe(i.stateColor)}),it("should still colour a state the UI classifies as an error as an error",()=>{const t=e("errapplied","ErrApplied(1) [...]",!0);expect(t.stateColor).toBe("text-error")}),it("should leave a state the UI does not know to the flag",()=>{const t=e("somethingnewfromfleet","some message",!0);expect(t.stateColor).toBe("text-error")})}),describe("stateDescription",()=>{it("should describe a non ready bundle with the Ready condition message",()=>{const n=e("waitingfordependency",t);expect(n.stateDescription).toBe(t)}),it("should not describe a ready bundle",()=>{const t=e("active");expect(t.stateDescription).toBe("")}),it("should not describe a ready bundle whose Ready condition carries a message",()=>{const e=new r["default"]({metadata:{namespace:"fleet-local",state:{name:"active",error:!1,transitioning:!1,message:""}},status:{conditions:[{type:"Ready",status:"True",message:"Deployment ready"}]}});expect(e.stateDescription).toBe("")})})})})},84264:function(e,t,n){"use strict";n.r(t);var r=n(5904);describe("class FleetCluster",()=>{it("should provide bundleInfo if correct data is present",()=>{const e=new r["default"]({metadata:{},spec:{},status:{display:{readyBundles:"0/1"}}});expect(e.bundleInfo.ready).toBe(0),expect(e.bundleInfo.total).toBe(1),expect(Object.getOwnPropertyNames(e.bundleInfo)).not.toContain("noValidData")}),describe("should provide bundleInfo with error",()=>{it.each([[""],["/"],["1/"],["/1"],["1/1/2"],["a/1"],["a/b"],["any-string"],["any-string1/string2"]])('with multiple scenarios of wrongful "readyBundles" data',e=>{const t=new r["default"]({metadata:{},spec:{},status:{display:{readyBundles:e}}});expect(Object.getOwnPropertyNames(t.bundleInfo)).toContain("noValidData")})})})},44282:function(e,t,n){"use strict";n.r(t);var r=n(84402);const i={commit:"foo",conditions:[{error:!0,lastUpdateTime:"2025-02-28T15:39:52Z",message:"Modified(1) [Cluster fleet-local/local]; configmap.v1 lots-a/test-config-one missing",status:"False",transitioning:!0,type:"Ready"},{error:!1,lastUpdateTime:"2025-02-28T15:36:25Z",status:"True",transitioning:!1,type:"GitPolling"},{error:!1,lastUpdateTime:"2025-02-28T15:36:25Z",status:"False",transitioning:!1,type:"Reconciling"},{error:!1,lastUpdateTime:"2025-02-28T15:36:25Z",status:"False",transitioning:!1,type:"Stalled"},{error:!1,lastUpdateTime:"2025-02-28T15:36:25Z",status:"True",transitioning:!1,type:"Accepted"}],desiredReadyClusters:1,display:{readyBundleDeployments:"1/2",state:"Modified"},gitJobStatus:"Current",lastPollingTriggered:"2025-02-28T16:08:39Z",observedGeneration:1,perClusterResourceCounts:{"fleet-local/local":{desiredReady:2,missing:1,modified:0,notReady:0,orphaned:0,ready:2,unknown:0,waitApplied:0}},readyClusters:0,resourceCounts:{desiredReady:2,missing:1,modified:0,notReady:0,orphaned:0,ready:2,unknown:0,waitApplied:0},resources:[{apiVersion:"v1",id:"lots-a/test-config-one",kind:"ConfigMap",name:"test-config-one",namespace:"lots-a",perClusterState:{missing:["fleet-local/local"]},state:"Missing",type:"configmap"},{apiVersion:"v1",id:"lots-a/test-config-two",kind:"ConfigMap",name:"test-config-two",namespace:"lots-a",perClusterState:{ready:["fleet-local/local"]},state:"Ready",type:"configmap"}],summary:{desiredReady:2,modified:1,nonReadyResources:[{bundleState:"Modified",modifiedStatus:[{apiVersion:"v1",kind:"ConfigMap",missing:!0,name:"test-config-one",namespace:"lots-a"}],name:"lots-a-scale-lotsofbundles-one"}],ready:1}};describe("class GitRepo",()=>{describe("resourcesStatuses",()=>{it.each([[]])("fn",()=>{jest.spyOn(r["default"].prototype,"$getters","get").mockReturnValue({byId:jest.fn()}),jest.spyOn(r["default"].prototype,"targetClusters","get").mockReturnValue([{id:"fleet-local/local",metadata:{labels:{}}}]);const e=new r["default"]({metadata:{namespace:"fleet-local"},spec:{},status:i}),t=e.resourcesStatuses,n=t.find(e=>"lots-a/test-config-one"===e.id);expect(n.state).toStrictEqual("missing"),expect(n.detailLocation).toBeUndefined();const o=t.find(e=>"lots-a/test-config-two"===e.id);expect(o.state).toStrictEqual("ready"),expect(o.detailLocation).toBeDefined()})}),describe("applyDefaults",()=>{const e={rootGetters:{workspace:"fleet-default"}};it("puts a new resource in the header workspace, with drift correction off",()=>{const t={metadata:{},spec:{repo:""}};new r["default"](t,e).applyDefaults(),expect(t.metadata.namespace).toBe("fleet-default"),expect(t.spec.correctDrift).toStrictEqual({enabled:!1})}),it("keeps the workspace and drift correction of a cloned resource",()=>{const t={enabled:!0,force:!0},n={metadata:{namespace:"team-a"},spec:{repo:"",correctDrift:t}};new r["default"](n,e).applyDefaults(),expect(n.metadata.namespace).toBe("team-a"),expect(n.spec.correctDrift).toStrictEqual(t)})})})},37069:function(e,t,n){"use strict";n.r(t);var r=n(80591),i=n(39618);const o=jest.fn(()=>!0);jest.mock("@shell/config/version",()=>({isRancherPrime:()=>o()})),describe("class HelmOp",()=>{let e;beforeEach(()=>{o.mockReturnValue(!0)}),describe("source getter",()=>{it("should return correct source for SOURCE_TYPE.REPO (HTTPS)",()=>{e=new r["default"]({spec:{helm:{repo:"https://charts.rancher.io/fleet",chart:"fleet-agent"}}});const t=e.source;expect(t.value).toBe("https://charts.rancher.io/fleet"),expect(t.display).toBe("charts.rancher.io/fleet"),expect(t.icon).toBe("icon icon-application"),expect(t.showLink).toBe(!0)}),it("should return correct source for SOURCE_TYPE.REPO (GitHub HTTPS .git)",()=>{e=new r["default"]({spec:{helm:{repo:"https://github.com/rancher/fleet.git",chart:"fleet"}}});const t=e.source;expect(t.value).toBe("https://github.com/rancher/fleet.git"),expect(t.display).toBe("rancher/fleet"),expect(t.icon).toBe("icon icon-application"),expect(t.showLink).toBe(!0)}),it("should return correct source for SOURCE_TYPE.REPO (GitHub SSH)",()=>{e=new r["default"]({spec:{helm:{repo:"git@github.com:rancher/fleet.git",chart:"fleet"}}});const t=e.source;expect(t.value).toBe("https://github.com/rancher/fleet"),expect(t.display).toBe("rancher/fleet"),expect(t.icon).toBe("icon icon-application"),expect(t.showLink).toBe(!0)}),it("should return correct source for SOURCE_TYPE.OCI",()=>{e=new r["default"]({spec:{helm:{repo:"oci://ghcr.io/rancher/some-chart"}}});const t=e.source;expect(t.value).toBe("oci://ghcr.io"),expect(t.display).toBe("oci://ghcr.io"),expect(t.icon).toBe("icon icon-application"),expect(t.showLink).toBe(!1)}),it("should return correct source for SOURCE_TYPE.TARBALL",()=>{e=new r["default"]({spec:{helm:{chart:"https://github.com/rancher/fleet-helm-charts/releases/download/fleet-0.12.1-beta.2/fleet-0.12.1-beta.2.tgz"}}});const t=e.source;expect(t.value).toBe("https://github.com/rancher/fleet-helm-charts/releases/download/fleet-0.12.1-beta.2/fleet-0.12.1-beta.2.tgz"),expect(t.display).toBe("rancher/fleet-helm-charts/releases/download/fleet-0.12.1-beta.2/fleet-0.12.1-beta.2.tgz"),expect(t.icon).toBe("icon icon-application"),expect(t.showLink).toBe(!0)}),it("should handle missing helm spec gracefully",()=>{e=new r["default"]({spec:{}});const t=e.source;expect(t.value).toBe(""),expect(t.display).toBeNull(),expect(t.icon).toBe("icon icon-application"),expect(t.showLink).toBe(!1)})}),describe("sourceSub getter",()=>{it("should display chart name and desired version when both are present (SOURCE_TYPE.REPO)",()=>{e=new r["default"]({spec:{helm:{repo:"https://charts.rancher.io/fleet",chart:"fleet-agent",version:"0.12.x"}}});const t=e.sourceSub;expect(t.value).toBe("fleet-agent : 0.12.x"),expect(t.display).toBe("fleet-agent : 0.12.x")}),it("should display chart name and desired version when both are present (SOURCE_TYPE.OCI)",()=>{e=new r["default"]({spec:{helm:{repo:"oci://ghcr.io/rancher/some-chart",version:"1.0.0"}}});const t=e.sourceSub;expect(t.value).toBe("rancher/some-chart : 1.0.0"),expect(t.display).toBe("rancher/some-chart : 1.0.0")}),it("should display only installed version when only it is present",()=>{e=new r["default"]({status:{version:"0.12.3"},spec:{helm:{}}});const t=e.sourceSub;expect(t.value).toBe("0.12.3"),expect(t.display).toBe("0.12.3")}),it("should display semantic version when installed version is missing",()=>{e=new r["default"]({spec:{helm:{version:"0.12.x",chart:"test-chart"}}});const t=e.sourceSub;expect(t.value).toBe("0.12.x"),expect(t.display).toBe("0.12.x")}),it('should display "semantic -> installed" when both versions are present (no chart)',()=>{e=new r["default"]({spec:{helm:{version:"0.12.x"}},status:{version:"0.12.5"}});const t=e.sourceSub;expect(t.value).toBe("0.12.x -> 0.12.5"),expect(t.display).toBe("0.12.x -> 0.12.5")}),it('should display chart and "semantic -> installed" when all are present',()=>{e=new r["default"]({spec:{helm:{repo:"https://charts.rancher.io/fleet",chart:"fleet-agent",version:"0.12.x"}},status:{version:"0.12.5"}});const t=e.sourceSub;expect(t.value).toBe("fleet-agent : 0.12.x -> 0.12.5"),expect(t.display).toBe("fleet-agent : 0.12.x -> 0.12.5")}),it("should display chart and only semantic version when all are present but semantic version is equal to installed version (no duplicate info)",()=>{e=new r["default"]({spec:{helm:{repo:"https://charts.rancher.io/fleet",chart:"fleet-agent",version:"0.12.3"}},status:{version:"0.12.3"}});const t=e.sourceSub;expect(t.value).toBe("fleet-agent : 0.12.3"),expect(t.display).toBe("fleet-agent : 0.12.3")}),it("should return empty string when no version or chart information is available",()=>{e=new r["default"]({spec:{helm:{}},status:{}});const t=e.sourceSub;expect(t.value).toBe(""),expect(t.display).toBe("")}),it("should correctly handle missing helm spec",()=>{e=new r["default"]({spec:{},status:{}});const t=e.sourceSub;expect(t.value).toBe(""),expect(t.display).toBe("")})}),describe("isSuseAppCollectionFromUI",()=>{it("should return true when annotation is set",()=>{e=new r["default"]({metadata:{annotations:{"catalog.cattle.io/suse-application-collection":"true"}},spec:{helm:{}}}),expect(e.isSuseAppCollectionFromUI).toBe(!0)}),it("should return false when annotation is missing",()=>{e=new r["default"]({metadata:{annotations:{}},spec:{helm:{}}}),expect(e.isSuseAppCollectionFromUI).toBe(!1)})}),describe("isSuseAppCollection",()=>{it("should return true even when not Rancher Prime if annotation is set",()=>{o.mockReturnValue(!1),e=new r["default"]({metadata:{annotations:{"catalog.cattle.io/suse-application-collection":"true"}},spec:{helm:{}}}),expect(e.isSuseAppCollection).toBe(!0)}),it("should return true when annotation is set and Rancher Prime",()=>{e=new r["default"]({metadata:{annotations:{"catalog.cattle.io/suse-application-collection":"true"}},spec:{helm:{}}}),expect(e.isSuseAppCollection).toBe(!0)}),it("should return true when repo URL starts with SUSE_APP_COLLECTION_REPO_URL",()=>{e=new r["default"]({metadata:{},spec:{helm:{repo:`${i.nx}/my-chart`}}}),expect(e.isSuseAppCollection).toBe(!0)}),it("should return false when no annotation and different repo URL",()=>{e=new r["default"]({metadata:{},spec:{helm:{repo:"oci://other-registry.io/charts"}}}),expect(e.isSuseAppCollection).toBe(!1)})}),describe("applicationType",()=>{it('should return "SUSE AppCo" when isSuseAppCollectionFromUI is true',()=>{e=new r["default"]({metadata:{annotations:{"catalog.cattle.io/suse-application-collection":"true"}},spec:{helm:{}},kind:"HelmOp"}),expect(e.applicationType).toStrictEqual("SUSE AppCo")}),it("should return kind when not SUSE App Collection from UI",()=>{e=new r["default"]({metadata:{},spec:{helm:{}},kind:"HelmOp"}),expect(e.applicationType).toStrictEqual("HelmOp")})}),describe("applyDefaults",()=>{const e={rootGetters:{workspace:"fleet-default"}};it("puts a new resource in the header workspace, with drift correction off",()=>{const t={metadata:{},spec:{helm:{}}};new r["default"](t,e).applyDefaults(),expect(t.metadata.namespace).toBe("fleet-default"),expect(t.spec.correctDrift).toStrictEqual({enabled:!1})}),it("keeps the workspace and drift correction of a cloned resource",()=>{const t={enabled:!0,force:!0},n={metadata:{namespace:"team-a"},spec:{helm:{},correctDrift:t}};new r["default"](n,e).applyDefaults(),expect(n.metadata.namespace).toBe("team-a"),expect(n.spec.correctDrift).toStrictEqual(t)})})})},19454:function(e,t,n){"use strict";n.r(t);var r=n(2036);const i={rootGetters:{workspace:"fleet-default"}},o=(e={})=>new r["default"]({type:"fleet.cattle.io.policy",metadata:{},...e},i);describe("class FleetPolicy",()=>{describe("applyDefaults",()=>{it("should default the namespace to the current workspace",()=>{const e=o();e.applyDefaults(),expect(e.metadata.namespace).toBe("fleet-default")}),it("should keep a namespace that is already set",()=>{const e=o({metadata:{namespace:"fleet-local"}});e.applyDefaults(),expect(e.metadata.namespace).toBe("fleet-local")}),it("should leave the enforcement flags to the user, as Fleet applies them across the whole workspace",()=>{const e=o();e.applyDefaults(),expect(e.requireServiceAccount).toBeUndefined()})}),describe("cleanForSave",()=>{it("should drop sub-objects the user never filled in",()=>{const e=o(),t=e.cleanForSave({requireServiceAccount:!0,gitRepo:{},helmOp:{defaultServiceAccount:"",allowedHelmSecretNames:[]}});expect(t).toStrictEqual({requireServiceAccount:!0})}),it("should drop an empty allowedServiceAccounts list",()=>{const e=o(),t=e.cleanForSave({allowedServiceAccounts:[],requireServiceAccount:!1});expect(t).toStrictEqual({requireServiceAccount:!1})}),it("should keep the fields the user did fill in",()=>{const e=o(),t=e.cleanForSave({allowedServiceAccounts:["tenant-1-deployer"],gitRepo:{defaultServiceAccount:"tenant-1-deployer",defaultClientSecretName:"",allowedClientSecretNames:["tenant-1-git-credentials"]},helmOp:{defaultHelmSecretName:"tenant-1-helm-credentials",allowedHelmSecretNames:[]}});expect(t).toStrictEqual({allowedServiceAccounts:["tenant-1-deployer"],gitRepo:{defaultServiceAccount:"tenant-1-deployer",allowedClientSecretNames:["tenant-1-git-credentials"]},helmOp:{defaultHelmSecretName:"tenant-1-helm-credentials"}})})})})},49636:function(e,t,n){"use strict";n.r(t);var r=n(87784),i=n(99611),o=n(35664);const a=(e,t="gwdemo")=>({metadata:{name:e,namespace:t}}),s=(e,t={},n="gwdemo",r="demo-gateway")=>new i["default"]({metadata:{name:r,namespace:n},spec:e,status:t}),l={namespaces:{from:"All"}},c={name:"http",protocol:"HTTP",port:80,allowedRoutes:l},u={name:"https",protocol:"HTTPS",port:443,allowedRoutes:l},d=(e,t=[],n=!0,i="gwdemo")=>new r["default"]({metadata:{name:"demo-route",namespace:i},spec:e},{rootGetters:{"cluster/schemaFor":e=>n&&e===o.Yq.GATEWAY?{}:void 0,"cluster/all":e=>e===o.Yq.GATEWAY?t:[]}});describe("class HttpRoute",()=>{describe("backendRefTargets",()=>{it.each([["a bare ref, defaulting to a Service in the route namespace",{name:"demo-app"},!0],["an explicit core Service",{name:"demo-app",group:"",kind:"Service"},!0],["an explicit same namespace",{name:"demo-app",namespace:"gwdemo"},!0],["a different service name",{name:"other-app"},!1],["a Service in another namespace",{name:"demo-app",namespace:"elsewhere"},!1],["a non-Service kind",{name:"demo-app",kind:"ServiceImport"},!1],["a non-core group",{name:"demo-app",group:"multicluster.x-k8s.io",kind:"Service"},!1]])("should match %s",(e,t,n)=>{expect(d({}).backendRefTargets(t,a("demo-app"))).toBe(n)}),it("should not match when either side is missing",()=>{expect(d({}).backendRefTargets(void 0,a("demo-app"))).toBe(!1),expect(d({}).backendRefTargets({name:"demo-app"},void 0)).toBe(!1)})}),describe("pathsForRule",()=>{it.each([["no matches at all",{},["/"]],["a match with no path, for example header only",{matches:[{headers:[{name:"x",value:"y"}]}]},["/"]],["a PathPrefix match",{matches:[{path:{type:"PathPrefix",value:"/shop"}}]},["/shop"]],["an Exact match",{matches:[{path:{type:"Exact",value:"/shop/cart"}}]},["/shop/cart"]],["a path with no explicit type, which defaults to PathPrefix",{matches:[{path:{value:"/shop"}}]},["/shop"]],["a path with no value",{matches:[{path:{type:"PathPrefix"}}]},["/"]],["duplicate paths",{matches:[{path:{value:"/shop"}},{path:{value:"/shop"}}]},["/shop"]],["several paths",{matches:[{path:{value:"/shop"}},{path:{value:"/cart"}}]},["/shop","/cart"]],["a literal path alongside a regular expression",{matches:[{path:{value:"/shop"}},{path:{type:"RegularExpression",value:"/v[0-9]+"}}]},["/shop"]],["a header-only match beside a path match, which serves both",{matches:[{headers:[{name:"x",value:"y"}]},{path:{value:"/shop"}}]},["/","/shop"]],["a header-only match beside a regular expression, which serves only /",{matches:[{path:{type:"RegularExpression",value:"/v[0-9]+"}},{headers:[{name:"x",value:"y"}]}]},["/"]]])("should return the paths for %s",(e,t,n)=>{expect(d({}).pathsForRule(t)).toStrictEqual(n)}),it("should return no paths for a rule matched only by regular expression, rather than claiming /",()=>{const e={matches:[{path:{type:"RegularExpression",value:"/api/v[0-9]+/.*"}}]};expect(d({}).pathsForRule(e)).toStrictEqual([])})}),describe("rulesForServices / targetsAnyService",()=>{const e={rules:[{backendRefs:[{name:"other-app",port:80}]},{backendRefs:[{name:"demo-app",port:80}]}]};it("should return only the rules that reference one of the services",()=>{expect(d(e).rulesForServices([a("demo-app")])).toStrictEqual([e.rules[1]]),expect(d(e).targetsAnyService([a("demo-app")])).toBe(!0)}),it("should ignore services the route does not reference",()=>{expect(d(e).rulesForServices([a("unrelated")])).toStrictEqual([]),expect(d(e).targetsAnyService([a("unrelated")])).toBe(!1)}),it("should return nothing when there are no services",()=>{expect(d(e).rulesForServices([])).toStrictEqual([]),expect(d(e).targetsAnyService()).toBe(!1)}),it("should tolerate a rule with no backendRefs and a spec with no rules",()=>{expect(d({rules:[{}]}).rulesForServices([a("demo-app")])).toStrictEqual([]),expect(d({}).rulesForServices([a("demo-app")])).toStrictEqual([])})}),describe("parentGateways",()=>{const e=s({listeners:[c]});it.each([["a bare parentRef, defaulting to a Gateway in the route namespace",{name:"demo-gateway"},1],["an explicit group and kind",{name:"demo-gateway",group:"gateway.networking.k8s.io",kind:"Gateway"},1],["a parentRef to a gateway that does not exist",{name:"missing"},0],["a parentRef in another namespace",{name:"demo-gateway",namespace:"elsewhere"},0],["a non-Gateway kind",{name:"demo-gateway",kind:"Mesh"},0]])("should resolve %s",(t,n,r)=>{expect(d({parentRefs:[n]},[e]).parentGateways).toHaveLength(r)}),it("should return nothing when there are no parentRefs",()=>{expect(d({},[e]).parentGateways).toStrictEqual([])}),it("should not touch the store on a cluster with no Gateway schema",()=>{const t=d({parentRefs:[{name:"demo-gateway"}]},[e],!1);expect(t.parentGateways).toStrictEqual([])})}),describe("hostnamesDisplay / parentRefsDisplay",()=>{it("should join the hostnames",()=>{expect(d({hostnames:["a.example.com","b.example.com"]}).hostnamesDisplay).toBe("a.example.com, b.example.com"),expect(d({}).hostnamesDisplay).toBe("")}),it("should qualify only the parentRefs that point at another namespace",()=>{const e={parentRefs:[{name:"local-gw"},{name:"same-gw",namespace:"gwdemo"},{name:"far-gw",namespace:"other"}]};expect(d(e).parentRefsDisplay).toBe("local-gw, same-gw, other/far-gw"),expect(d({}).parentRefsDisplay).toBe("")}),it("should list only actual Gateways, not a mesh parentRef, under a Gateways heading",()=>{const e={parentRefs:[{name:"demo-gateway"},{name:"mesh-svc",kind:"Service",group:""}]};expect(d(e).parentRefsDisplay).toBe("demo-gateway")})}),describe("endpointsForServices",()=>{const e=[a("demo-app")],t=[{matches:[{path:{type:"PathPrefix",value:"/shop"}}],backendRefs:[{name:"demo-app",port:80}]}],n=[{name:"demo-gateway"}],r=(r,i={})=>d({parentRefs:n,rules:t,hostnames:["demo.example.com"],...i},[r]).endpointsForServices(e);it("should build an http url and omit the default port 80",()=>{expect(r(s({listeners:[c]}))).toStrictEqual([{link:"http://demo.example.com/shop",linkDisplay:"http://demo.example.com/shop"}])}),it("should build an https url and omit the default port 443",()=>{expect(r(s({listeners:[u]}))).toStrictEqual([{link:"https://demo.example.com/shop",linkDisplay:"https://demo.example.com/shop"}])}),it("should include a non default port",()=>{const e=s({listeners:[{name:"http",protocol:"HTTP",port:8080}]});expect(r(e)[0].link).toBe("http://demo.example.com:8080/shop")}),it("should emit a url for every listener a bare parentRef attaches to, in either order",()=>{const e=s({listeners:[c,u]}),t=s({listeners:[u,c]}),n=["http://demo.example.com/shop","https://demo.example.com/shop"];expect(r(e).map(e=>e.link).sort()).toStrictEqual(n),expect(r(t).map(e=>e.link).sort()).toStrictEqual(n)}),it("should fall back to the listener hostname when the route has none",()=>{const e=s({listeners:[{...c,hostname:"listener.example.com"}]});expect(r(e,{hostnames:[]})[0].link).toBe("http://listener.example.com/shop")}),it("should fall back to the gateway address when neither has a hostname",()=>{const e=s({listeners:[c]},{addresses:[{type:"IPAddress",value:"172.19.0.240"}]});expect(r(e,{hostnames:[]})[0].link).toBe("http://172.19.0.240/shop")}),it("should not offer the gateway address for a wildcard only route, which would not match its Host header",()=>{const e=s({listeners:[c]},{addresses:[{type:"IPAddress",value:"172.19.0.240"}]});expect(r(e,{hostnames:["*.example.com"]})).toStrictEqual([])}),it("should resolve a wildcard route against a listener that pins a concrete hostname",()=>{const e=s({listeners:[{...c,hostname:"shop.example.com"}]});expect(r(e,{hostnames:["*.example.com"]})[0].link).toBe("http://shop.example.com/shop")}),it("should keep a route hostname that falls under a wildcard listener",()=>{const e=s({listeners:[{...c,hostname:"*.example.com"}]});expect(r(e)[0].link).toBe("http://demo.example.com/shop")}),it("should emit nothing when the route and listener hostnames do not overlap",()=>{const e=s({listeners:[{...c,hostname:"other.example.com"}]});expect(r(e)).toStrictEqual([])}),it("should emit nothing for a rule matched only by regular expression",()=>{const e=s({listeners:[c]}),t=[{matches:[{path:{type:"RegularExpression",value:"/v[0-9]+"}}],backendRefs:[{name:"demo-app"}]}];expect(r(e,{rules:t})).toStrictEqual([])}),it("should bracket an IPv6 gateway address so the url is valid",()=>{const e=s({listeners:[c]},{addresses:[{type:"IPAddress",value:"2001:db8::1"}]}),t=r(e,{hostnames:[]})[0].link;expect(t).toBe("http://[2001:db8::1]/shop"),expect(()=>new URL(t)).not.toThrow()}),it("should match a wildcard listener as a suffix over any number of labels",()=>{const e=s({listeners:[{...c,hostname:"*.example.com"}]});expect(r(e,{hostnames:["shop.example.com"]})[0].link).toBe("http://shop.example.com/shop"),expect(r(e,{hostnames:["eu.shop.example.com"]})[0].link).toBe("http://eu.shop.example.com/shop"),expect(r(e,{hostnames:["example.com"]})).toStrictEqual([]),expect(r(e,{hostnames:["notexample.com"]})).toStrictEqual([])}),it("should compare hostnames case insensitively",()=>{const e=s({listeners:[{...c,hostname:"demo.example.com"}]});expect(r(e,{hostnames:["Demo.Example.COM"]})[0].link).toBe("http://demo.example.com/shop")}),it("should not attach to a listener that only allows routes from its own namespace",()=>{const n=s({listeners:[{...c,allowedRoutes:{namespaces:{from:"Same"}}}]},{},"infra"),r={parentRefs:[{name:"demo-gateway",namespace:"infra"}],rules:t,hostnames:["demo.example.com"]};expect(d(r,[n]).endpointsForServices(e)).toStrictEqual([])}),it("should return nothing when the listener is not http(s)",()=>{expect(r(s({listeners:[{name:"tcp",protocol:"TCP",port:5432}]}))).toStrictEqual([])}),it("should return nothing when the gateway has no address and nothing has a hostname",()=>{expect(r(s({listeners:[c]}),{hostnames:[]})).toStrictEqual([])}),it("should return nothing when the parent gateway cannot be resolved",()=>{expect(r(s({listeners:[c]},{},"elsewhere"))).toStrictEqual([])}),it("should return nothing when no rule targets the services",()=>{const e=s({listeners:[c]});expect(d({parentRefs:n,rules:t,hostnames:["demo.example.com"]},[e]).endpointsForServices([a("unrelated")])).toStrictEqual([])}),it("should honour a parentRef that pins a listener by sectionName",()=>{const n=s({listeners:[c,u]}),r={parentRefs:[{name:"demo-gateway",sectionName:"https"}],rules:t,hostnames:["demo.example.com"]};expect(d(r,[n]).endpointsForServices(e).map(e=>e.link)).toStrictEqual(["https://demo.example.com/shop"])}),it("should produce one url per hostname and path, without duplicates",()=>{const t=s({listeners:[c]}),n={parentRefs:[{name:"demo-gateway"},{name:"demo-gateway"}],hostnames:["a.example.com","b.example.com"],rules:[{matches:[{path:{value:"/shop"}},{path:{value:"/cart"}}],backendRefs:[{name:"demo-app",port:80}]}]};expect(d(n,[t]).endpointsForServices(e).map(e=>e.link)).toStrictEqual(["http://a.example.com/shop","http://a.example.com/cart","http://b.example.com/shop","http://b.example.com/cart"])})})}),describe("class Gateway",()=>{describe("addresses",()=>{it("should return the values the controller assigned",()=>{const e=s({},{addresses:[{type:"IPAddress",value:"172.19.0.240"},{type:"Hostname",value:"gw.example.com"}]});expect(e.addresses).toStrictEqual(["172.19.0.240","gw.example.com"])}),it.each([["no status",{}],["no addresses",{addresses:[]}],["an address with no value",{addresses:[{type:"IPAddress"}]}]])("should return an empty list for %s",(e,t)=>{expect(s({},t).addresses).toStrictEqual([])})}),describe("listenersFor",()=>{const e=s({listeners:[{name:"tcp",protocol:"TCP",port:5432},c,u]}),t=e=>e.map(e=>e.name);it("should return every http(s) listener when nothing is pinned",()=>{expect(t(e.listenersFor({},"gwdemo"))).toStrictEqual(["http","https"])}),it("should honour sectionName",()=>{expect(t(e.listenersFor({sectionName:"https"},"gwdemo"))).toStrictEqual(["https"])}),it("should honour port",()=>{expect(t(e.listenersFor({port:443},"gwdemo"))).toStrictEqual(["https"])}),it("should honour sectionName and port together",()=>{expect(t(e.listenersFor({sectionName:"https",port:443},"gwdemo"))).toStrictEqual(["https"]),expect(e.listenersFor({sectionName:"https",port:80},"gwdemo")).toStrictEqual([])}),it("should return nothing when nothing matches",()=>{expect(e.listenersFor({sectionName:"nope"},"gwdemo")).toStrictEqual([]),expect(e.listenersFor({sectionName:"tcp"},"gwdemo")).toStrictEqual([]),expect(s({}).listenersFor({},"gwdemo")).toStrictEqual([])})}),describe("allowsRoute",()=>{const e=s({});it("should default to accepting only routes in its own namespace",()=>{expect(e.allowsRoute({},"gwdemo","HTTPRoute")).toBe(!0),expect(e.allowsRoute({},"elsewhere","HTTPRoute")).toBe(!1)}),it("should honour namespaces.from",()=>{expect(e.allowsRoute({allowedRoutes:l},"elsewhere","HTTPRoute")).toBe(!0),expect(e.allowsRoute({allowedRoutes:{namespaces:{from:"Same"}}},"elsewhere","HTTPRoute")).toBe(!1)}),it("should be permissive for a namespace Selector, whose labels this model does not load",()=>{const t={allowedRoutes:{namespaces:{from:"Selector",selector:{matchLabels:{env:"prod"}}}}};expect(e.allowsRoute(t,"elsewhere","HTTPRoute")).toBe(!0)}),it("should honour allowedRoutes.kinds",()=>{const t={allowedRoutes:{...l,kinds:[{kind:"GRPCRoute"}]}},n={allowedRoutes:{...l,kinds:[{kind:"GRPCRoute"},{kind:"HTTPRoute"}]}};expect(e.allowsRoute(t,"gwdemo","HTTPRoute")).toBe(!1),expect(e.allowsRoute(n,"gwdemo","HTTPRoute")).toBe(!0)})}),describe("schemeForListener",()=>{it.each([["HTTP","http"],["HTTPS","https"],["TCP",void 0],["UDP",void 0],[void 0,void 0],["constructor",void 0],["toString",void 0]])("should map the %s listener protocol to %s",(e,t)=>{expect((0,i.schemeForListener)({protocol:e})).toBe(t)}),it("should return undefined for no listener at all",()=>{expect((0,i.schemeForListener)(void 0)).toBeUndefined()})})})},85166:function(e,t,n){"use strict";n.r(t);var r=n(21766);describe("class LogFlow",()=>{it('prop "outputs" should take namespace in consideration when filtering logging v2 "outputs"',()=>{const e=[{apiVersion:"logging.banzaicloud.io/v1beta1",kind:"Output",metadata:{creationTimestamp:"2025-03-17T10:51:55Z",namespace:"default",name:"output1",uid:"927b4a2e-6be0-476f-9bdd-cf30c4a27d8b"},name:"output1",spec:{awsElasticsearch:{endpoint:{}}},status:{active:!1}},{apiVersion:"logging.banzaicloud.io/v1beta1",kind:"Output",metadata:{creationTimestamp:"2025-03-17T10:51:55Z",namespace:"cattle-fleet-system",name:"output2",uid:"927b4a2e-6be0-476f-9bdd-cf30c4a27d8c"},name:"output2",spec:{awsElasticsearch:{endpoint:{}}},status:{active:!1}},{apiVersion:"logging.banzaicloud.io/v1beta1",kind:"Output",metadata:{creationTimestamp:"2025-03-17T10:51:55Z",namespace:"cattle-fleet-system",name:"output3",uid:"927b4a2e-6be0-476f-9bdd-cf30c4a27d8d"},name:"output3",spec:{awsElasticsearch:{endpoint:{}}},status:{active:!1}},{apiVersion:"logging.banzaicloud.io/v1beta1",kind:"Output",metadata:{creationTimestamp:"2025-03-17T10:51:55Z",namespace:"kube-system",name:"output4",uid:"927b4a2e-6be0-476f-9bdd-cf30c4a27d8e"},name:"output4",spec:{awsElasticsearch:{endpoint:{}}},status:{active:!1}}],t={apiVersion:"logging.banzaicloud.io/v1beta1",kind:"Flow",metadata:{name:"flow2",creationTimestamp:"2025-03-17T10:53:02Z",generation:1,namespace:"cattle-fleet-system",resourceVersion:"4070",uid:"fdf7d553-d101-4c37-91b0-784f95dc950a",fields:["flow2",!0,null]},spec:{localOutputRefs:["output2","output3"]}},n=new r["default"](t);jest.spyOn(n,"allOutputs","get").mockReturnValue(e),expect(n.outputs).toStrictEqual([e[1],e[2]])})})},48207:function(e,t,n){"use strict";n.r(t);var r=n(78277),i=n(73883),o=n(52148);jest.mock("@shell/utils/require-asset",()=>({requireAsset:jest.fn(e=>e)}));const a={"i18n/withFallback":e=>e,"i18n/t":e=>e,"features/get":()=>!1,"management/schemaFor":()=>({resourceMethods:["PUT"]}),"management/byId":()=>({spec:{value:!0},status:{lockedValue:null}})},s=e=>new r["default"](e,{rootGetters:a});describe("fx: providerKey",()=>{const e=[["activeDirectoryConfig","activedirectory"],["activeDirectoryProvider","activedirectory"],["githubConfig","github"],["githubProvider","github"],["keyCloakOIDCConfig","keycloakoidc"],["keyCloakOIDCProvider","keycloakoidc"],["googleOauthConfig","googleoauth"],["googleOAuthProvider","googleoauth"],["localConfig","local"],["",""],[void 0,""],[null,""]];it.each(e)("should normalise %p to %p",(e,t)=>{expect((0,r.providerKey)(e)).toBe(t)})}),describe("fx: configTypeName",()=>{const e=[["githubProvider","githubConfig"],["azureADProvider","azureADConfig"],["keyCloakOIDCProvider","keyCloakOIDCConfig"],["activeDirectoryProvider","activeDirectoryConfig"],["githubConfig","githubConfig"],["",""],[void 0,""],[null,""]];it.each(e)("should turn %p into %p",(e,t)=>{expect((0,r.configTypeName)(e)).toBe(t)})}),describe("fx: configTypeForProvider",()=>{const e=[["activeDirectoryProvider","ldap"],["githubProvider","oauth"],["githubAppProvider","oauth"],["googleOAuthProvider","oauth"],["keyCloakProvider","saml"],["keyCloakOIDCProvider","oidc"],["genericSAMLProvider","saml"],["localProvider",""],["notAProvider",void 0],[void 0,void 0]];it.each(e)("should resolve %p to %p",(e,t)=>{expect((0,r.configTypeForProvider)(e)).toBe(t)}),it("should resolve the config naming as well as the provider naming",()=>{expect((0,r.configTypeForProvider)("githubConfig")).toBe("oauth"),expect((0,r.configTypeForProvider)("githubProvider")).toBe("oauth")})}),describe("fx: providerIcon",()=>{it.each([["githubProvider","github"],["activeDirectoryProvider","activedirectory"],["oktaProvider","okta"]])("should derive the asset name from %p",(e,t)=>{expect((0,r.providerIcon)(e)).toBe(`~shell/assets/images/vendor/${t}.svg`)}),it.each([["azureADProvider","entraid"],["genericOIDCProvider","openid"],["keyCloakOIDCProvider","keycloak"],["oidcProvider","openid"]])("should apply the override for %p",(e,t)=>{expect((0,r.providerIcon)(e)).toBe(`~shell/assets/images/vendor/${t}.svg`)}),it("should resolve the config naming and the provider naming to one asset",()=>{expect((0,r.providerIcon)("githubConfig")).toBe((0,r.providerIcon)("githubProvider"))}),it.each(["localProvider","localConfig"])("should give %p the Rancher local mark",e=>{expect((0,r.providerIcon)(e)).toBe("~shell/assets/images/vendor/local.svg")}),it("should fall back to an empty string when the vendor has no logo",()=>{jest.mocked(o.mS).mockImplementationOnce(()=>{throw new Error("Asset not found")}),expect((0,r.providerIcon)("unknownProvider")).toBe("")}),it.each([void 0,null,""])("should not throw for %p",e=>{jest.mocked(o.mS).mockImplementationOnce(()=>{throw new Error("Asset not found")}),expect((0,r.providerIcon)(e)).toBe("")})}),describe("class AuthConfig",()=>{describe("disable",()=>{const e=(e,t,n={})=>{const i=jest.fn(r=>"rancher/find"===r?Promise.resolve(e):"management/findAll"===r?Promise.resolve(n.configs||[]):"rancher/clone"===r?Promise.resolve(t):Promise.resolve()),o=new r["default"]({id:"github",_type:"githubConfig"},{rootGetters:{...a,...n},dispatch:i});return{config:o,dispatch:i}},t=e=>e.mock.calls.find(([e])=>"management/promptModal"===e);it("should be a method the action menu can actually call",()=>{expect(typeof s({id:"github"}).disable).toBe("function")}),it("should confirm before disabling",async()=>{const{config:n,dispatch:r}=e({});await n.promptDisable();const i=t(r);expect(i[1].component).toBe("DisableAuthProviderDialog"),expect(i[1].componentProps.name).toBe(n.nameDisplay)}),it("should let the dialog render its own modal",async()=>{const{config:n,dispatch:r}=e({});await n.promptDisable(),expect(t(r)[1].ownsModal).toBe(!0)}),it("should disable only once the dialog calls back",async()=>{const n={hasAction:()=>!0,doAction:jest.fn()},{config:r,dispatch:i}=e(n);await r.promptDisable();const{disableCb:o}=t(i)[1].componentProps;expect(n.doAction).not.toHaveBeenCalled(),await o(),expect(n.doAction).toHaveBeenCalledWith("disable")}),describe("when it would be the last way in",()=>{const n={"features/get":()=>!0,configs:[{id:"local",enabled:!0},{id:"github",enabled:!0},{id:"okta",enabled:!1}]};it("should offer to turn local login back on instead of disabling",async()=>{const{config:r,dispatch:i}=e({},void 0,n);await r.promptDisable(),expect(t(i)[1].component).toBe("DisableLastAuthProviderDialog")}),it("should not hand the dialog a way to disable the provider",async()=>{const{config:r,dispatch:i}=e({},void 0,n);await r.promptDisable(),expect(t(i)[1].componentProps.disableCb).toBeUndefined()}),it("should name the provider that cannot be disabled",async()=>{const{config:r,dispatch:i}=e({},void 0,n);await r.promptDisable(),expect(t(i)[1].componentProps.name).toBe(r.nameDisplay)}),it("should keep the ordinary dialog while another provider is still enabled",async()=>{const{config:r,dispatch:i}=e({},void 0,{...n,configs:[...n.configs,{id:"okta",enabled:!0}]});await r.promptDisable(),expect(t(i)[1].component).toBe("DisableAuthProviderDialog")}),it("should keep the ordinary dialog while local login is still on",async()=>{const{config:r,dispatch:i}=e({},void 0,{...n,"features/get":()=>!1});await r.promptDisable(),expect(t(i)[1].component).toBe("DisableAuthProviderDialog")})}),it("should run the norman action for the matching config",async()=>{const t={hasAction:()=>!0,doAction:jest.fn()},{config:n,dispatch:r}=e(t);await n.disable(),expect(r).toHaveBeenCalledWith("rancher/find",{type:"authconfig",id:"github",opt:{url:"/v3/authconfig/github",force:!0}},{root:!0}),expect(t.doAction).toHaveBeenCalledWith("disable")}),it("should fall back to saving the flag when there is no action",async()=>{const t={enabled:!0,save:jest.fn()},{config:n}=e({hasAction:()=>!1},t);await n.disable(),expect(t.enabled).toBe(!1),expect(t.save).toHaveBeenCalledWith()}),it("should fall back when the advertised action is not honoured",async()=>{const t={enabled:!0,save:jest.fn()},n={hasAction:()=>!0,doAction:jest.fn().mockRejectedValue({code:"ActionNotAvailable",status:404})},{config:r}=e(n,t);await r.disable(),expect(n.doAction).toHaveBeenCalledWith("disable"),expect(t.enabled).toBe(!1),expect(t.save).toHaveBeenCalledWith()}),it("should report a failure rather than leaving it uncaught",async()=>{const t={hasAction:()=>!0,doAction:jest.fn().mockRejectedValue({code:"PermissionDenied",status:403})},{config:n,dispatch:r}=e(t);await expect(n.disable()).resolves.toBeUndefined(),expect(r).toHaveBeenCalledWith("growl/fromError",{title:"generic.notification.title.error",err:{code:"PermissionDenied",status:403}},{root:!0})}),it("should refresh the config so the list reflects the change",async()=>{const{config:t,dispatch:n}=e({hasAction:()=>!0,doAction:jest.fn()});await t.disable(),expect(n).toHaveBeenCalledWith("find",{type:"management.cattle.io.authconfig",id:"github",opt:{force:!0}})})}),describe("canCustomEdit",()=>{it("should find the form for an instance of the provider",()=>{const e=new r["default"]({id:"github-5",_type:"githubConfig"},{rootGetters:{...a,"type-map/hasCustomEdit":(e,t)=>"github"===t}});expect(e.canCustomEdit).toBe(!0)})}),describe("detailLocation",()=>{it("should point at the auth config page for this config",()=>{const e=new r["default"]({id:"github",_type:"githubConfig"},{rootGetters:{...a,clusterId:"local"}});expect(e.detailLocation).toStrictEqual({name:"c-cluster-auth-config-id",params:{cluster:"local",id:"github"}})})}),it("should opt out of the generic configuration drawer",()=>{expect(s({id:"github"}).disableResourceDetailDrawer).toBe(!0)}),describe("goToEdit",()=>{it("should open the provider page on the provider configuration",()=>{const e=jest.fn();jest.spyOn(i.Ay.prototype,"currentRouter").mockReturnValue({push:e});const t=new r["default"]({id:"github",_type:"githubConfig"},{rootGetters:{...a,clusterId:"local"}});t.goToEdit(),expect(e).toHaveBeenCalledWith({name:"c-cluster-auth-config-id",params:{cluster:"local",id:"github"},query:{mode:"edit",as:void 0,editConfig:"true"}}),jest.restoreAllMocks()})}),describe("_availableActions",()=>{const e=[{action:"showConfiguration",label:"action.showConfiguration",icon:"icon icon-document",enabled:!0},{divider:!0},{action:"goToEdit",label:"action.edit",icon:"icon icon-edit",enabled:!0},{divider:!0},{action:"download",label:"action.download",icon:"icon icon-download",bulkable:!0,bulkAction:"downloadBulk",enabled:!0,weight:0},{action:"promptRemove",altAction:"remove",label:"action.remove",icon:"icon icon-trash",bulkable:!0,bulkAction:"promptRemove",enabled:!0,weight:-10}];beforeEach(()=>{jest.spyOn(i.Ay.prototype,"_availableActions","get").mockReturnValue([...e])}),afterEach(()=>jest.restoreAllMocks()),it("should part the menu into two groups with a single divider",()=>{const e=s({id:"github",enabled:!0})._availableActions;expect(e.filter(e=>e.divider)).toHaveLength(1),expect(e.map(e=>e.action||"divider")).toStrictEqual(["showConfiguration","goToEdit","download","divider","promptDisable","promptRemove"])}),it("should offer disabling only while the provider is enabled",()=>{const e=s({id:"github",enabled:!0})._availableActions,t=s({id:"github",enabled:!1})._availableActions,n=e=>e.find(e=>"promptDisable"===e.action);expect(n(e).enabled).toBe(!0),expect(n(t).enabled).toBe(!1)})})})},58221:function(e,t,n){"use strict";n.r(t);var r=n(65230),i=n(35664),o=n(41476),a=n(48881),s=n(6198);jest.mock("@shell/utils/clipboard",()=>({copyTextToClipboard:jest.fn(()=>Promise.resolve({}))})),jest.mock("@shell/utils/download",()=>({downloadFile:jest.fn(()=>Promise.resolve({}))})),describe("class MgmtCluster",()=>{describe("provisioner",()=>{const e=[[{provider:"rke2",driver:"imported"},"rke2"],[{provider:"k3s",driver:"K3S"},"K3S"],[{provider:"aks",driver:"AKS"},"AKS"],[{},"imported"]];it.each(e)("should return provisioner value properly based on the props data",(e,t)=>{const n=new r["default"]({status:e});expect(n.provisioner).toBe(t)})}),describe("copyKubeConfig",()=>{let e;const t=jest.fn(),n="apiVersion: v1\nkind: Config\nclusters:\n- name: test-cluster";beforeEach(()=>{jest.clearAllMocks(),e=new r["default"]({id:"test-cluster-1",metadata:{name:"test-cluster-1"}}),e.generateKubeConfig=t}),it("should copy single cluster kubeconfig to clipboard",async()=>{t.mockResolvedValue(n),await e.copyKubeConfig(),expect(t).toHaveBeenCalledWith(),expect(a.e).toHaveBeenCalledWith(n)}),it("should not copy to clipboard if config generation returns null",async()=>{t.mockResolvedValue(null),await e.copyKubeConfig(),expect(t).toHaveBeenCalledWith(),expect(a.e).not.toHaveBeenCalled()}),it("should handle errors gracefully",async()=>{t.mockRejectedValue(new Error("Generation failed")),await expect(e.copyKubeConfig()).resolves.not.toThrow(),expect(a.e).not.toHaveBeenCalled()})}),describe("copyKubeConfigBulk",()=>{let e;const t=jest.fn(),n="apiVersion: v1\nkind: Config\nclusters:\n- name: cluster-1\n- name: cluster-2";beforeEach(()=>{jest.clearAllMocks(),e=new r["default"]({id:"cluster-1",metadata:{name:"cluster-1"}}),e.generateKubeConfig=t}),it("should copy multiple cluster kubeconfigs to clipboard",async()=>{const r=[{id:"cluster-1",mgmt:{id:"mgmt-cluster-1"}},{id:"cluster-2",mgmt:{id:"mgmt-cluster-2"}},{id:"cluster-3",mgmt:{id:"mgmt-cluster-3"}}];t.mockResolvedValue(n),await e.copyKubeConfigBulk(r),expect(t).toHaveBeenCalledWith(["mgmt-cluster-1","mgmt-cluster-2","mgmt-cluster-3"]),expect(a.e).toHaveBeenCalledWith(n)}),it("should use item.id when mgmt.id is not available",async()=>{const r=[{id:"cluster-1"},{id:"cluster-2"},{id:"cluster-3",mgmt:{id:"mgmt-cluster-3"}}];t.mockResolvedValue(n),await e.copyKubeConfigBulk(r),expect(t).toHaveBeenCalledWith(["cluster-1","cluster-2","mgmt-cluster-3"]),expect(a.e).toHaveBeenCalledWith(n)}),it("should handle single cluster in bulk action",async()=>{const r=[{id:"cluster-1",mgmt:{id:"mgmt-cluster-1"}}];t.mockResolvedValue(n),await e.copyKubeConfigBulk(r),expect(t).toHaveBeenCalledWith(["mgmt-cluster-1"]),expect(a.e).toHaveBeenCalledWith(n)}),it("should not copy to clipboard if config generation returns null",async()=>{const n=[{id:"cluster-1",mgmt:{id:"mgmt-cluster-1"}},{id:"cluster-2",mgmt:{id:"mgmt-cluster-2"}}];t.mockResolvedValue(null),await e.copyKubeConfigBulk(n),expect(t).toHaveBeenCalledWith(["mgmt-cluster-1","mgmt-cluster-2"]),expect(a.e).not.toHaveBeenCalled()}),it("should not copy to clipboard if config is empty string",async()=>{const n=[{id:"cluster-1",mgmt:{id:"mgmt-cluster-1"}}];t.mockResolvedValue(""),await e.copyKubeConfigBulk(n),expect(t).toHaveBeenCalledWith(["mgmt-cluster-1"]),expect(a.e).not.toHaveBeenCalled()}),it("should handle errors gracefully",async()=>{const n=[{id:"cluster-1",mgmt:{id:"mgmt-cluster-1"}}];t.mockRejectedValue(new Error("Generation failed")),await expect(e.copyKubeConfigBulk(n)).resolves.not.toThrow(),expect(a.e).not.toHaveBeenCalled()}),it("should handle empty items array",async()=>{const r=[];t.mockResolvedValue(n),await e.copyKubeConfigBulk(r),expect(t).toHaveBeenCalledWith([]),expect(a.e).toHaveBeenCalledWith(n)})}),describe("generateKubeConfig",()=>{const e="apiVersion: v1\nkind: Config";let t,n;const o=(e="cluster-1")=>{const t={dispatch:n,rootGetters:{"i18n/t":e=>e}};return new r["default"]({id:e,metadata:{name:e}},t)};beforeEach(()=>{jest.clearAllMocks(),t=jest.fn().mockResolvedValue({status:{value:e}}),n=jest.fn().mockResolvedValue({save:t})}),it("should request a kubeconfig for this cluster without the default `rancher` entry",async()=>{const r=o(),a=await r.generateKubeConfig();expect(n).toHaveBeenCalledWith("management/create",{type:i.I$.KUBECONFIG,spec:{clusters:["cluster-1"],includeDefaultEntry:!1}},{root:!0}),expect(t).toHaveBeenCalledWith(),expect(a).toBe(e)}),it("should pass an explicit list of clusters through, still excluding the default entry",async()=>{const e=o();await e.generateKubeConfig(["cluster-1","cluster-2"]),expect(n).toHaveBeenCalledWith("management/create",{type:i.I$.KUBECONFIG,spec:{clusters:["cluster-1","cluster-2"],includeDefaultEntry:!1}},{root:!0})}),it("should not make a request when there are no clusters",async()=>{const e=o(),t=await e.generateKubeConfig([]);expect(n).not.toHaveBeenCalledWith("management/create",expect.anything(),expect.anything()),expect(t).toBeUndefined()}),it("should growl an error when there are no clusters",async()=>{const e=o();await e.generateKubeConfig([]),expect(n).toHaveBeenCalledWith("growl/error",{title:"cluster.kubeConfig.error.title",message:"cluster.kubeConfig.error.noClusters"},{root:!0})}),it("should return undefined when the response has no value",async()=>{t.mockResolvedValue({});const e=o(),n=await e.generateKubeConfig();expect(n).toBeUndefined()})}),describe("kubeConfigClusterIds",()=>{const e=()=>new r["default"]({id:"cluster-1"});it("should prefer the management cluster id over the row id",()=>{const t=[{id:"prov-1",mgmt:{id:"mgmt-1"}},{id:"prov-2"}];expect(e().kubeConfigClusterIds(t)).toStrictEqual(["mgmt-1","prov-2"])}),it("should de-duplicate ids that resolve to the same management cluster",()=>{const t=[{id:"prov-1",mgmt:{id:"mgmt-1"}},{id:"mgmt-1"},{id:"prov-2",mgmt:{id:"mgmt-2"}}];expect(e().kubeConfigClusterIds(t)).toStrictEqual(["mgmt-1","mgmt-2"])}),it("should drop rows without an id",()=>{const t=[{id:"mgmt-1"},{},{id:""}];expect(e().kubeConfigClusterIds(t)).toStrictEqual(["mgmt-1"])}),it("should handle no items",()=>{expect(e().kubeConfigClusterIds()).toStrictEqual([]),expect(e().kubeConfigClusterIds([])).toStrictEqual([])})}),describe("downloadKubeConfigBulk",()=>{let e;const t=jest.fn(),n="apiVersion: v1\nkind: Config";beforeEach(()=>{jest.clearAllMocks(),e=new r["default"]({id:"cluster-1"}),e.generateKubeConfig=t}),it("should download a kubeconfig for the de-duplicated set of clusters",async()=>{const r=[{id:"prov-1",mgmt:{id:"mgmt-1"}},{id:"mgmt-1"}];t.mockResolvedValue(n),await e.downloadKubeConfigBulk(r),expect(t).toHaveBeenCalledWith(["mgmt-1"]),expect(s.PE).toHaveBeenCalledWith("kubeconfig.yaml",n,"application/yaml")}),it("should not download a file when no config was generated",async()=>{t.mockResolvedValue(void 0),await e.downloadKubeConfigBulk([]),expect(s.PE).not.toHaveBeenCalled()})}),describe("pin / unpin",()=>{const e=e=>{const t=[],n=jest.fn((e,n)=>(t.push({action:e,payload:n}),Promise.resolve("prefs/applyPrefsOptimistic"===e?{}:void 0)));return{cluster:new r["default"]({id:e},{dispatch:n}),calls:t}};it("pin routes through the shared writer (one optimistic commit, then one reconcile)",async()=>{const{cluster:t,calls:n}=e("c-a");await t.pin(),expect(n.map(e=>e.action)).toStrictEqual(["prefs/applyPrefsOptimistic","prefs/reconcilePrefs"])}),it("pin sends a single PINNED_CLUSTERS mutation that adds the cluster at the top, idempotently",async()=>{const{cluster:t,calls:n}=e("c-a");await t.pin();const r=n[0].payload;expect(r).toHaveLength(1),expect(r[0].key).toBe(o.Hu),expect(r[0].apply([])).toStrictEqual(["c-a"]),expect(r[0].apply(["c-b"])).toStrictEqual(["c-a","c-b"]),expect(r[0].apply(["c-a"])).toStrictEqual(["c-a"]),expect(r[0].apply(["c-b","c-a","c-c"])).toStrictEqual(["c-a","c-b","c-c"])}),it("unpin touches PINNED only",async()=>{const{cluster:t,calls:n}=e("c-a");await t.unpin();const r=n[0].payload;expect(n.map(e=>e.action)).toStrictEqual(["prefs/applyPrefsOptimistic","prefs/reconcilePrefs"]),expect(r.map(e=>e.key)).toStrictEqual([o.Hu]),expect(r[0].apply(["c-a","c-b"])).toStrictEqual(["c-b"])}),it("unpin of local touches PINNED only",async()=>{const{cluster:t,calls:n}=e("local");await t.unpin();const r=n[0].payload;expect(r.map(e=>e.key)).toStrictEqual([o.Hu]),expect(r[0].apply(["local","c-b"])).toStrictEqual(["c-b"])}),it("pinBulk pins a whole selection in one write, in the order selected",async()=>{const{cluster:t,calls:n}=e("c-a");await t.pinBulk([{id:"c-a"},{id:"prov-b",mgmt:{id:"c-b"}}]),expect(n.map(e=>e.action)).toStrictEqual(["prefs/applyPrefsOptimistic","prefs/reconcilePrefs"]);const r=n[0].payload;expect(r).toHaveLength(1),expect(r[0].key).toBe(o.Hu),expect(r[0].apply(["c-z"])).toStrictEqual(["c-a","c-b","c-z"]),expect(r[0].apply(["c-b"])).toStrictEqual(["c-a","c-b"])}),it("unpinBulk unpins a whole selection in one write, leaving the rest pinned",async()=>{const{cluster:t,calls:n}=e("c-a");await t.unpinBulk([{id:"c-a"},{id:"prov-b",mgmt:{id:"c-b"}}]);const r=n[0].payload;expect(r).toHaveLength(1),expect(r[0].apply(["c-a","c-z","c-b"])).toStrictEqual(["c-z"])})})})},77316:function(e,t,n){"use strict";n.r(t);var r=n(54820);describe("class CRTB",()=>{describe("clusterDetailLocation",()=>{it("should link to the explorer of the bound cluster when the cluster can be explored",()=>{const e=new r["default"]({clusterName:"c-m-abcde"},{rootGetters:{"management/byId":()=>({canExplore:!0})}});expect(e.clusterDetailLocation).toStrictEqual({name:"c-cluster-explorer",params:{cluster:"c-m-abcde"}})}),it.each([["cannot be explored",{canExplore:!1}],["is not loaded",void 0]])("should not link when the cluster %s",(e,t)=>{const n=new r["default"]({clusterName:"c-m-abcde"},{rootGetters:{"management/byId":()=>t}});expect(n.clusterDetailLocation).toBeNull()})})})},49833:function(e,t,n){"use strict";n.r(t);var r=n(58975),i=n(73883),o=n(83297);jest.mock("@shell/config/version",()=>({isRancherPrime:jest.fn(()=>!1)})),describe("class Feature",()=>{const e={dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e},getters:{schemaFor:()=>({linkFor:jest.fn()})}};beforeEach(()=>{jest.spyOn(i.Ay.prototype,"_availableActions","get").mockReturnValue([])}),afterEach(()=>{jest.restoreAllMocks()}),describe("enabled getter",()=>{it.each([[!0,!0],[!1,!1]])("should return lockedValue (%s) when status.lockedValue is not null",(t,n)=>{const i=new r["default"]({spec:{value:!1},status:{lockedValue:t,default:!1}},e);expect(i.enabled).toBe(n)}),it("should return spec.value when lockedValue is null and spec.value is set",()=>{const t=new r["default"]({spec:{value:!0},status:{lockedValue:null,default:!1}},e);expect(t.enabled).toBe(!0)}),it("should fall back to status.default when lockedValue is null and spec.value is null",()=>{const t=new r["default"]({spec:{value:null},status:{lockedValue:null,default:!0}},e);expect(t.enabled).toBe(!0)}),it("should not throw when status is missing (malformed feature flag)",()=>{const t=new r["default"]({spec:{value:!0}},e);expect(()=>t.enabled).not.toThrow(),expect(t.enabled).toBe(!0)})}),describe("a Prime feature",()=>{const t=(t=null)=>new r["default"]({id:"multiple-auth-providers",spec:{value:t},status:{lockedValue:null,default:!0,prime:!0}},e);afterEach(()=>{jest.mocked(o.f$).mockReturnValue(!1)}),it("should be off on a build that is not Prime, whatever its default",()=>{jest.mocked(o.f$).mockReturnValue(!1),expect(t().enabled).toBe(!1)}),it("should be off on a build that is not Prime even when switched on",()=>{jest.mocked(o.f$).mockReturnValue(!1),expect(t(!0).enabled).toBe(!1)}),it("should follow its value on Prime",()=>{jest.mocked(o.f$).mockReturnValue(!0),expect(t().enabled).toBe(!0)}),it("should not offer to switch it on on a build that is not Prime",()=>{jest.mocked(o.f$).mockReturnValue(!1);const e=t();jest.spyOn(e,"canUpdate","get").mockReturnValue(!0);const n=e._availableActions.find(e=>"toggleFeatureFlag"===e.action);expect(null===n||void 0===n?void 0:n.enabled).toBe(!1)}),it("should offer to switch it on on Prime",()=>{jest.mocked(o.f$).mockReturnValue(!0);const e=t(!1);jest.spyOn(e,"canUpdate","get").mockReturnValue(!0);const n=e._availableActions.find(e=>"toggleFeatureFlag"===e.action);expect(null===n||void 0===n?void 0:n.enabled).toBe(!0)})}),describe("restartRequired getter",()=>{it("should return false when status.dynamic is true",()=>{const t=new r["default"]({spec:{},status:{dynamic:!0,lockedValue:null}},e);expect(t.restartRequired).toBe(!1)}),it("should return true when status.dynamic is false",()=>{const t=new r["default"]({spec:{},status:{dynamic:!1,lockedValue:null}},e);expect(t.restartRequired).toBe(!0)}),it("should return true when status is missing (malformed feature flag)",()=>{const t=new r["default"]({spec:{}},e);expect(()=>t.restartRequired).not.toThrow(),expect(t.restartRequired).toBe(!0)})}),describe("_availableActions getter",()=>{it("should disable the toggle action when lockedValue is not null",()=>{const t=new r["default"]({spec:{value:!1},status:{lockedValue:!0,default:!1,dynamic:!0}},e);jest.spyOn(t,"canUpdate","get").mockReturnValue(!0);const n=t._availableActions;expect(n[0].action).toBe("toggleFeatureFlag"),expect(n[0].enabled).toBe(!1)}),it("should enable the toggle action when lockedValue is null and user canUpdate",()=>{const t=new r["default"]({spec:{value:!1},status:{lockedValue:null,default:!1,dynamic:!0},id:"some-feature"},e);jest.spyOn(t,"canUpdate","get").mockReturnValue(!0);const n=t._availableActions;expect(n[0].action).toBe("toggleFeatureFlag"),expect(n[0].enabled).toBe(!0)}),it("should not throw and should disable the toggle action when status is missing (malformed feature flag)",()=>{const t=new r["default"]({spec:{value:!1},id:"some-feature"},e);jest.spyOn(t,"canUpdate","get").mockReturnValue(!0),expect(()=>t._availableActions).not.toThrow();const n=t._availableActions;expect(n[0].action).toBe("toggleFeatureFlag"),expect(n[0].enabled).toBeFalsy()})})})},25529:function(e,t,n){"use strict";n.r(t);var r=n(77917);describe("class MgmtNode",()=>{const e="foo",t="bar",n=jest.fn(()=>t),i={rootGetters:{"i18n/t":n}},o=()=>{jest.clearAllMocks()};it("should not return addresses if they are not present in the resource status, the internalNodeStatus, or the rkeNode key in status",()=>{const e=new r["default"]({status:{}});expect(e.addresses).toStrictEqual([]),o()}),describe("should return addresses",()=>{const t=[e];it("if they are present directly on the resource status",()=>{const e=new r["default"]({status:{addresses:t}});expect(e.addresses).toStrictEqual(t)}),it('if they are not present directly on the resource status but are on "status.internalNodeStatus"',()=>{const e=new r["default"]({status:{internalNodeStatus:{addresses:t}}});expect(e.addresses).toStrictEqual(t)})}),describe("should return an internalIp",()=>{const t=[{type:"InternalIP",address:e}],n=e;it("if addresses includes an object with an appropriate type and address",()=>{const n=new r["default"]({status:{addresses:t}});expect(n.internalIp).toStrictEqual(e)}),it("if internalNodeStatus.addresses includes an object with an appropriate type and address",()=>{const n=new r["default"]({status:{internalNodeStatus:{addresses:t}}});expect(n.internalIp).toStrictEqual(e)}),it("if addresses and internalNodeStatus.addresses do not provide an internal ip and the status includes an rkeNode key with an appropriate type and address",()=>{const e=new r["default"]({status:{rkeNode:{internalAddress:n}}});expect(e.internalIp).toStrictEqual(n)})}),describe("should return an externalIp",()=>{const t=[{type:"ExternalIP",address:e}],n=e;it("if addresses includes an object with an appropriate type and address",()=>{const n=new r["default"]({status:{addresses:t}});expect(n.externalIp).toStrictEqual(e)}),it("if internalNodeStatus.addresses includes an object with an appropriate type and address",()=>{const n=new r["default"]({status:{internalNodeStatus:{addresses:t}}});expect(n.externalIp).toStrictEqual(e)}),it("if addresses and internalNodeStatus.addresses do not provide an external ip and the status includes an rkeNode key with an appropriate type and address",()=>{const e=new r["default"]({status:{rkeNode:{address:n}}});expect(e.externalIp).toStrictEqual(n)})}),describe("should return an appropriate message",()=>{it("if there is no internalIp to display",()=>{const e=new r["default"]({status:{}},i);expect(e.internalIp).toStrictEqual(t),expect(n).toHaveBeenCalledTimes(1),expect(n).toHaveBeenCalledWith("generic.none"),o()}),it("if there is no externalIp to display",()=>{const e=new r["default"]({status:{}},i);expect(e.externalIp).toStrictEqual(t),expect(n).toHaveBeenCalledTimes(1),expect(n).toHaveBeenCalledWith("generic.none"),o()})}),describe("pool",()=>{it("should return undefined if nodePoolName is not set",()=>{const e=new r["default"]({spec:{}});expect(e.pool).toBeUndefined()}),it("should return the node pool when nodePoolName is set",()=>{const e={id:"fleet-local/np1"},t={rootGetters:{"i18n/t":n,"management/byId":jest.fn(()=>e)}},i=new r["default"]({spec:{nodePoolName:"fleet-local:np1"}},t);expect(i.pool).toStrictEqual(e),expect(t.rootGetters["management/byId"]).toHaveBeenCalledWith("management.cattle.io.nodepool","fleet-local/np1")})}),describe("canScaleDown",()=>{const e="test",t="test/id",i={worker:{worker:!0,etcd:!1,controlPlane:!1},etcd:{worker:!1,etcd:!0,controlPlane:!1},controlPlane:{worker:!1,etcd:!1,controlPlane:!0},etcdAndControlPlane:{worker:!1,etcd:!0,controlPlane:!0},all:{worker:!0,etcd:!0,controlPlane:!0}},o={id:"01",isWorker:!0,isControlPlane:!1,isEtcd:!1},a={id:"02",isWorker:!1,isControlPlane:!1,isEtcd:!0},s={id:"03",isWorker:!1,isControlPlane:!0,isEtcd:!1},l={id:"03",isWorker:!1,isControlPlane:!0,isEtcd:!0},c={id:"04",isWorker:!0,isControlPlane:!0,isEtcd:!0},u={rootGetters:{"rancher/byId":()=>({actions:{scaledown:"scaledown"}}),"i18n/t":n}};it.each([[{spec:i.worker,nodes:[o]},!0],[{spec:i.etcd,nodes:[a,a,s]},!0],[{spec:i.etcdAndControlPlane,nodes:[l,l]},!0],[{spec:i.etcdAndControlPlane,nodes:[l]},!1],[{spec:i.all,nodes:[c]},!1],[{spec:i.all,nodes:[c,c]},!0]])("should return canScaleDown properly",(n,i)=>{const{spec:o,nodes:a}=n,s=new r["default"]({spec:o,id:t},{...u,rootGetters:{...u.rootGetters,"management/byId":()=>({id:e,provCluster:{nodes:a}})}});expect(s.canScaleDown).toStrictEqual(i)})})})},94479:function(e,t,n){"use strict";n.r(t);var r=n(68959);describe("class MgmtNodePool",()=>{describe("canScaleDownPool",()=>{const e="test",t="test/id",n={worker:{worker:!0,etcd:!1,controlPlane:!1},etcd:{worker:!1,etcd:!0,controlPlane:!1},controlPlane:{worker:!1,etcd:!1,controlPlane:!0},etcdAndControlPlane:{worker:!1,etcd:!0,controlPlane:!0},all:{worker:!0,etcd:!0,controlPlane:!0}},i={id:"01",isWorker:!0,isControlPlane:!1,isEtcd:!1},o={id:"02",isWorker:!1,isControlPlane:!1,isEtcd:!0},a={id:"03",isWorker:!1,isControlPlane:!0,isEtcd:!1},s={id:"03",isWorker:!1,isControlPlane:!0,isEtcd:!0},l={id:"04",isWorker:!0,isControlPlane:!0,isEtcd:!0},c={rootGetters:{"rancher/byId":()=>({actions:{scaledown:"scaledown"}})}};it.each([[{spec:n.worker,nodes:[i]},!0],[{spec:n.etcd,nodes:[o,o,a]},!0],[{spec:n.etcdAndControlPlane,nodes:[s,s]},!0],[{spec:n.etcdAndControlPlane,nodes:[s]},!1],[{spec:n.all,nodes:[l]},!1],[{spec:n.all,nodes:[l,l]},!0]])("should return canScaleDownPool properly",(n,i)=>{const{spec:o,nodes:a}=n,s=new r["default"]({spec:o,metadata:{},id:t},{...c,getters:{byId:()=>({id:e,nodes:a})}});expect(s.canScaleDownPool()).toStrictEqual(i)})})})},15460:function(e,t,n){"use strict";n.r(t);var r=n(24220),i=n(35664),o=n(11518),a=n(27278);describe("class Project",()=>{const e=(e,t)=>{const n={getters:{schemaFor:()=>({attributes:{namespaced:!0}})},rootGetters:{currentProduct:e,productId:e.name,clusterId:t},rootState:{$extension:{getPlugins:()=>({})}}};return new r["default"]({id:"local/p-abcde",type:i.Mc.PROJECT,metadata:{name:"p-abcde",namespace:"local"},spec:{clusterName:"local"}},n)};describe("detailLocation",()=>{it.each([["auth","c-m-other"],["settings","c-m-other"],[a.o,"local"]])("should link to the project in its own cluster in the explorer when the current product is %p and the current cluster is %p",(t,n)=>{const r=e({name:t,inStore:"management"},n);expect(r.detailLocation).toStrictEqual({name:"c-cluster-product-resource-namespace-id",params:{cluster:"local",product:a.o,resource:i.Mc.PROJECT,namespace:"local",id:"p-abcde"}})}),it("should keep the harvester route and the current cluster when the current product is harvester",()=>{const t=e({name:o.T3,inStore:o.T3},"c-m-harvester");expect(t.detailLocation).toStrictEqual({name:`${o.T3}-c-cluster-resource-namespace-id`,params:{product:o.T3,cluster:"c-m-harvester",resource:i.Mc.PROJECT,namespace:"local",id:"p-abcde"}})})})})},34375:function(e,t,n){"use strict";n.r(t);var r=n(91673),i=n(35664),o=n(27278);describe("class PRTB",()=>{describe("projectDetailLocation",()=>{it("should use the project detail location when the project is loaded",()=>{const e={name:"project-location"},t=new r["default"]({projectName:"local:p-abcde"},{rootGetters:{"management/byId":()=>({detailLocation:e})}});expect(t.projectDetailLocation).toStrictEqual(e)}),it.each([["local:p-abcde","local","p-abcde"],["c-m-abcde:p-fghij","c-m-abcde","p-fghij"]])("should link to the project in its own cluster in the explorer when %p is not loaded",(e,t,n)=>{const a=new r["default"]({projectName:e},{rootGetters:{"management/byId":()=>{}}});expect(a.projectDetailLocation).toStrictEqual({name:"c-cluster-product-resource-namespace-id",params:{cluster:t,product:o.o,resource:i.Mc.PROJECT,namespace:t,id:n}})})}),describe("clusterDetailLocation",()=>{it("should link to the explorer of the project's cluster when the cluster can be explored",()=>{const e=new r["default"]({projectName:"c-m-abcde:p-fghij"},{rootGetters:{"management/byId":()=>({canExplore:!0})}});expect(e.clusterDetailLocation).toStrictEqual({name:"c-cluster-explorer",params:{cluster:"c-m-abcde"}})}),it.each([["cannot be explored",{canExplore:!1}],["is not loaded",void 0]])("should not link when the cluster %s",(e,t)=>{const n=new r["default"]({projectName:"c-m-abcde:p-fghij"},{rootGetters:{"management/byId":()=>t}});expect(n.clusterDetailLocation).toBeNull()})})})},4166:function(e,t,n){"use strict";n.r(t);var r=n(34858);const i={apiVersion:"monitoring.coreos.com/v1alpha1",kind:"AlertmanagerConfig",metadata:{name:"test",namespace:"default"}},o=e=>new r["default"](e);describe("class AlertmanagerConfig",()=>{describe("applyDefaults",()=>{it("on a fresh resource, seeds the route with defaults and no match/matchRe",()=>{const e=o({...i});e.applyDefaults(),expect(e.spec.receivers).toStrictEqual([]),expect(e.spec.route).toStrictEqual({groupBy:[],groupWait:"30s",groupInterval:"5m",repeatInterval:"4h",matchers:[]})}),it("backfills route defaults on a resource loaded without a route",()=>{const e=o({...i,spec:{receivers:[{name:"existing"}]}});e.applyDefaults(),expect(e.spec.route).toBeDefined(),expect(e.spec.route.receiver).toBeUndefined(),expect(e.spec.route.matchers).toStrictEqual([])}),it("preserves existing matchers on load",()=>{const e=[{name:"severity",value:"warning",matchType:"="}],t=o({...i,spec:{receivers:[{name:"existing"}],route:{receiver:"existing",matchers:e}}});t.applyDefaults(),expect(t.spec.route.matchers).toStrictEqual(e)})}),describe("cleanForSave",()=>{it("drops spec.route when no receiver is set — this is what fixes #17347 on 109+ charts",()=>{const e=o({...i}),t=e.cleanForSave({...i,spec:{receivers:[],route:{groupBy:[],groupWait:"30s",groupInterval:"5m",repeatInterval:"4h",matchers:[]}}},!0);expect(t.spec.route).toBeUndefined(),expect(t.spec.receivers).toStrictEqual([])}),it("keeps spec.route when a receiver is set",()=>{const e=o({...i}),t=e.cleanForSave({...i,spec:{receivers:[{name:"existing"}],route:{receiver:"existing",groupBy:[],matchers:[]}}},!1);expect(t.spec.route).toBeDefined(),expect(t.spec.route.receiver).toBe("existing")})})})},68882:function(e,t,n){"use strict";n.r(t);var r=n(67867),i=n(2841),o=n(71025),a=n(35664),s=n(47034),l=n(27278),c=n(21342);jest.mock("@shell/components/nav/TopLevelMenu.helper",()=>({__esModule:!0,default:{helper:{clustersLocal:[]}}})),describe("class Namespace",()=>{describe("checking if isSystem",()=>{it.each([["whatever1",i.eG,!0],["whatever2","any-annotation",!1],["whatever3","",!1]])("should return true if it has the correct annotation",(e,t,n)=>{const i=new r["default"]({}),o={...i.metadata,name:e};t&&(o.annotations={[t]:"true"}),i.metadata=o,expect(i.isSystem).toBe(n)});const e=[];o.A.forEach(t=>{e.push([t,!0])}),e.push(["c-whatever-system",!1]),e.push(["cattle-whatever",!1]),e.push(["k3k-system",!0]),e.push(["",!1]),it.each(e)("should return true if it belongs to the curated list of namespaces",(e,t)=>{const n=new r["default"]({});n.metadata={...n.metadata,name:e},expect(n.isSystem).toBe(t)}),it.each([["cattle-c-whatever-system",!0],["cattle-whatever",!1],["c-whatever-system",!1]])('should return true if starts with "cattle-" end with "-system',(e,t)=>{const n=new r["default"]({});n.metadata={...n.metadata,name:e},expect(n.isSystem).toBe(t)})}),it.todo("should check if isFleetManaged"),describe("checking if isObscure",()=>{it.each([["c-whatever-system","management.cattle.io/system-namespace",!0],["p-whatever",i.eG,!0],["p-whatever","",!1],["","",!1]])("should return a value if is system AND has the correct prefix",(e,t,n)=>{const i=new r["default"]({}),o={...i.metadata,name:e};t&&(o.annotations={[t]:"true"}),i.metadata=o,expect(i.isObscure).toBe(n)})}),it.each([["foo:bar","bar"],["",null]])("given %p annotation, projectId should be %p",(e,t)=>{const n=new r["default"]({});n.metadata={name:"",annotations:{"field.cattle.io/projectId":e}},expect(n.projectId).toBe(t)}),it.todo("should return the project"),describe("handling groupById",()=>{it("should return the groupById if have project id",()=>{const e=new r["default"]({});jest.spyOn(e,"project","get").mockReturnValue({id:"mock-project-id",type:"project",name:"mock-project"}),expect(e.groupById).toStrictEqual("mock-project-id")}),it("should return the groupById if project id undefined",()=>{const e=jest.fn(()=>"Not in a Project"),t={rootGetters:{"i18n/t":e}},n=new r["default"]({},t);jest.spyOn(n,"project","get").mockReturnValue({}),expect(n.groupById).toStrictEqual("Not in a Project")})}),it.todo("should return the project name with i18n"),it.todo("should return the projectNameSort"),it.todo("should check if istioInstalled"),it.todo("should check if injectionEnabled"),describe("handling Istio labels",()=>{const e=jest.fn();it.each([{metadata:{name:"",labels:{"istio-injection":"whatever"}},save:e},[{metadata:{name:"",labels:{"istio-injection":"whatever"}},save:e}]])("should handle both data as list and single object and save",t=>{const n=new r["default"]({});n.enableAutoInjection(t),expect(e).toHaveBeenCalledWith()}),it("should add auto injection label as enable",()=>{const t={metadata:{name:"",labels:{"istio-injection":"whatever"}},save:e},n=new r["default"]({});n.enableAutoInjection(t),expect(t.metadata.labels["istio-injection"]).toBe("enabled")}),it("should remove label on disable",()=>{const t={metadata:{name:"",labels:{"istio-injection":"whatever"}},save:e},n=new r["default"]({});n.enableAutoInjection(t,!1),expect(t.metadata.labels["istio-injection"]).toBeUndefined()})}),it.todo("should disableAutoInjection"),it.todo("should check if confirmRemove"),describe("move action availability",()=>{const e=Object.getPrototypeOf(r["default"].prototype),t=({canUpdate:t})=>{const n=new r["default"]({});return jest.spyOn(n,"$rootGetters","get").mockReturnValue({isRancher:!0,isSingleProduct:!1,"i18n/t":e=>e}),Object.defineProperty(n,"istioInstalled",{get:()=>!1,configurable:!0}),Object.defineProperty(n,"canUpdate",{get:()=>t,configurable:!0}),jest.spyOn(e,"_availableActions","get").mockReturnValue([]),n};it("should include the move action when user can update the namespace",()=>{const e=t({canUpdate:!0}),n=e.availableActions.find(e=>"move"===e.action);expect(n).toBeDefined(),expect(null===n||void 0===n?void 0:n.enabled).toBe(!0)}),it("should exclude the move action when user cannot update the namespace",()=>{const e=t({canUpdate:!1}),n=e.availableActions.find(e=>"move"===e.action);expect(n).toBeUndefined()})}),describe("handling listLocation",()=>{it.each([["c-cluster-product-projectsnamespaces",!0],["c-cluster-product-resource",!1]])("should return the name %p if is Rancher (%p)",(e,t)=>{const n=new r["default"]({});jest.spyOn(n,"$rootGetters","get").mockReturnValue({isRancher:t,currentProduct:{inStore:""}}),expect(n.listLocation.name).toBe(e)}),it("should route to local cluster explorer when in manager product",()=>{const e=new r["default"]({});jest.spyOn(e,"$rootGetters","get").mockReturnValue({isRancher:!0,productId:s.o,clusterId:"_",currentProduct:{inStore:""}}),expect(e.listLocation.params.cluster).toBe(a.d_),expect(e.listLocation.params.product).toBe(l.o)}),it("should use current cluster and always use explorer product when not in manager",()=>{const e=new r["default"]({});jest.spyOn(e,"$rootGetters","get").mockReturnValue({isRancher:!0,productId:l.o,clusterId:"c-abc",currentProduct:{inStore:""}}),expect(e.listLocation.params.cluster).toBe("c-abc"),expect(e.listLocation.params.product).toBe(l.o)})}),describe("handling _detailLocation",()=>{const e=(e,t)=>{jest.spyOn(e,"$rootGetters","get").mockReturnValue(t),jest.spyOn(e,"$getters","get").mockReturnValue({schemaFor:()=>({attributes:{namespaced:!1}})}),Object.defineProperty(e,"isProdRegistrationV2TopLevelProductResoure",{get:()=>!1})};it("should route to local cluster explorer when in manager product",()=>{const t=new r["default"]({});e(t,{productId:s.o,clusterId:"_"});const n=t._detailLocation;expect(n.params.cluster).toBe(a.d_),expect(n.params.product).toBe(l.o)}),it("should use current cluster and product when not in manager product",()=>{const t=new r["default"]({});e(t,{productId:l.o,clusterId:"c-abc"});const n=t._detailLocation;expect(n.params.cluster).toBe("c-abc"),expect(n.params.product).toBe(l.o)})}),describe("resourceQuota",()=>{it("should return the parsed resourceQuota annotation",()=>{const e=new r["default"]({metadata:{annotations:{[i._n]:'{"limit":{"limitsCpu":"500m"}}'}}});expect(e.resourceQuota).toStrictEqual({limit:{limitsCpu:"500m"}})}),it.each([["there are no annotations",void 0],["the annotation is missing",{}],["the annotation is malformed JSON",{[i._n]:'{"limit":{"limitsCpu":"500m"\''}],["the annotation is JSON null",{[i._n]:"null"}],["the annotation is a JSON array",{[i._n]:"[]"}]])("should return an empty limit when %s",(e,t)=>{const n=new r["default"]({metadata:{annotations:t}});expect(n.resourceQuota).toStrictEqual({limit:{}})})}),describe("hasInvalidResourceQuota",()=>{it.each([[!1,"there are no annotations",void 0],[!1,"the annotation is missing",{}],[!1,"the annotation is valid",{[i._n]:'{"limit":{"limitsCpu":"500m"}}'}],[!0,"the annotation is malformed JSON",{[i._n]:'{"limit":{"limitsCpu":"500m"\''}],[!0,"the annotation is JSON null",{[i._n]:"null"}],[!0,"the annotation is a JSON array",{[i._n]:"[]"}]])("should return %p when %s",(e,t,n)=>{const i=new r["default"]({metadata:{annotations:n}});expect(i.hasInvalidResourceQuota).toBe(e)})}),it.todo("should set the resourceQuota as reactive Vue property"),it.todo("should reset project with cleanForNew"),describe("hideDetailLocation",()=>{it("should not throw when currentProduct is undefined",()=>{const e=new r["default"]({});jest.spyOn(e,"$rootGetters","get").mockReturnValue({currentProduct:void 0}),expect(()=>e.hideDetailLocation).not.toThrow(),expect(e.hideDetailLocation).toBe(!0)})}),describe("glance",()=>{it("should return projectGlance instead of namespace when namespace is in a project",()=>{var e;const t=jest.fn(e=>e),n={rootGetters:{"i18n/t":t}},i=new r["default"]({},n),o={detailLocation:"project-detail",nameDisplay:"My Project"};jest.spyOn(i,"project","get").mockReturnValue(o),Object.defineProperty(i,"_glance",{get:jest.fn(()=>[{name:"namespace"},{name:"other"}])});const a=i.glance;expect(a).toHaveLength(2),expect(a[0].name).toBe("project"),expect(a[0].label).toBe("component.resource.detail.glance.project"),expect(a[0].formatter).toBe("Link"),expect(null===(e=a[0].formatterOpts)||void 0===e?void 0:e.to).toBe("project-detail"),expect(a[0].content).toBe("My Project"),expect(a[1].name).toBe("other")}),it("should remove namespace from glance when namespace is not in a project",()=>{const e=new r["default"]({});jest.spyOn(e,"project","get").mockReturnValue(null),jest.spyOn(e,"$rootGetters","get").mockReturnValue({productId:l.o}),Object.defineProperty(e,"_glance",{get:jest.fn(()=>[{name:"namespace"},{name:"other"}])});const t=e.glance;expect(t).toHaveLength(1),expect(t[0].name).toBe("other")}),it("should remove type Link formatter when in manager product without local cluster access",()=>{const e=new r["default"]({});c.Ay.helper.clustersLocal.length=0,jest.spyOn(e,"project","get").mockReturnValue(null),jest.spyOn(e,"$rootGetters","get").mockReturnValue({productId:s.o}),Object.defineProperty(e,"_glance",{get:jest.fn(()=>[{name:"type",formatter:"Link",formatterOpts:{to:{},row:{}}},{name:"other"}])});const t=e.glance,n=t.find(e=>"type"===e.name);expect(n).toBeDefined(),expect(null===n||void 0===n?void 0:n.formatter).toBeUndefined(),expect(null===n||void 0===n?void 0:n.formatterOpts).toBeUndefined()}),it("should keep type Link formatter when in manager product with local cluster access",()=>{const e=new r["default"]({});c.Ay.helper.clustersLocal.length=0,c.Ay.helper.clustersLocal.push({id:a.d_}),jest.spyOn(e,"project","get").mockReturnValue(null),jest.spyOn(e,"$rootGetters","get").mockReturnValue({productId:s.o}),Object.defineProperty(e,"_glance",{get:jest.fn(()=>[{name:"type",formatter:"Link",formatterOpts:{to:{},row:{}}},{name:"other"}])});const t=e.glance,n=t.find(e=>"type"===e.name);expect(n).toBeDefined(),expect(null===n||void 0===n?void 0:n.formatter).toBe("Link"),expect(null===n||void 0===n?void 0:n.formatterOpts).toBeDefined()}),it("should keep type Link formatter when not in manager product",()=>{const e=new r["default"]({});jest.spyOn(e,"project","get").mockReturnValue(null),jest.spyOn(e,"$rootGetters","get").mockReturnValue({productId:l.o}),Object.defineProperty(e,"_glance",{get:jest.fn(()=>[{name:"type",formatter:"Link",formatterOpts:{to:{},row:{}}},{name:"other"}])});const t=e.glance,n=t.find(e=>"type"===e.name);expect(n).toBeDefined(),expect(null===n||void 0===n?void 0:n.formatter).toBe("Link"),expect(null===n||void 0===n?void 0:n.formatterOpts).toBeDefined()})}),describe("projectGlance",()=>{it("should return undefined if namespace is not in a project",()=>{const e=new r["default"]({});jest.spyOn(e,"project","get").mockReturnValue(null),expect(e.projectGlance).toBeUndefined()}),it("should return project glance information if namespace is in a project",()=>{const e=jest.fn(e=>e),t={rootGetters:{"i18n/t":e}},n=new r["default"]({},t),i={detailLocation:"project-detail",nameDisplay:"My Project"};jest.spyOn(n,"project","get").mockReturnValue(i);const o=n.projectGlance;expect(null===o||void 0===o?void 0:o.name).toBe("project"),expect(null===o||void 0===o?void 0:o.label).toBe("component.resource.detail.glance.project"),expect(null===o||void 0===o?void 0:o.formatter).toBe("Link"),expect(null===o||void 0===o?void 0:o.formatterOpts.to).toBe("project-detail"),expect(null===o||void 0===o?void 0:o.content).toBe("My Project")})})})},4915:function(e,t,n){"use strict";n.r(t);var r=n(44458),i=n(35664),o=n(50025);describe("class Node",()=>{const e=()=>{jest.clearAllMocks()};it.each([["1200",1200],["1k",1e3]])("given %p status pod capacity value from the backend, should parse the value correctly as %p",(t,n)=>{const i=new r["default"]({status:{capacity:{pods:t}}});expect(i.podCapacity).toStrictEqual(n),e()}),describe("popover",()=>{const e="nodeRunningPods/local/node-1",t=[{name:"state"},{name:"type"},{name:"namespace"},{name:"age"}],n=(e={},{metrics:t,hasMetricsSchema:n=!0,canViewPods:o=!0,paginated:a=!1,haveAllPods:s=!1,pods:l=[],savedCounts:c={}}={})=>{const u=jest.fn(),d=jest.fn(),h={[i.$v.NODE]:n?{id:i.$v.NODE}:void 0,[i.Sm]:o?{id:i.Sm}:void 0},p={"i18n/t":e=>e,"cluster/byId":jest.fn(()=>t),"cluster/schemaFor":jest.fn(e=>h[e]),"cluster/paginationEnabled":jest.fn(()=>a),"cluster/haveAll":jest.fn(()=>s),"cluster/urlFor":jest.fn(()=>"https://rancher/k8s/clusters/local/v1/pods"),"cluster/getSavedCount":jest.fn(e=>c[e]),"cluster/all":jest.fn(()=>l),clusterId:"local",currentCluster:{metadata:{labels:{}},provisioner:"k3s"}},f=new r["default"]({id:"node-1",metadata:{name:"node-1",annotations:{}},status:{addresses:[],allocatable:{cpu:"4",memory:"8Gi"},capacity:{cpu:"4",memory:"8Gi",pods:"110"},nodeInfo:{}},...e},{dispatch:u,commit:d,rootGetters:p});return{node:f,dispatch:u,commit:d,rootGetters:p}},a=(e,n=t)=>(Object.defineProperty(e,"_glance",{get:()=>n}),e),s=e=>e.map(e=>e.name),l=(e,t)=>e.find(e=>e.name===t);describe("glance",()=>{it("should add the node rows between the type and age rows, without a namespace row",()=>{const{node:e}=n();expect(s(a(e).glance)).toStrictEqual(["state","type","externalIp","internalIp","version","os","age"])}),it("should add the node rows at the end when there is no age row",()=>{const{node:e}=n();expect(s(a(e,[{name:"state"},{name:"type"}]).glance)).toStrictEqual(["state","type","externalIp","internalIp","version","os"])}),it("should not change the rows of the base glance",()=>{const{node:e}=n(),r=[...t],i=a(e,r).glance;expect(i).not.toBe(r),expect(s(r)).toStrictEqual(["state","type","namespace","age"])}),it.each([["externalIp","ExternalIP","component.resource.detail.glance.externalIp"],["internalIp","InternalIP","component.resource.detail.glance.internalIp"]])("should show the %p row as an IP that can be copied",(e,t,r)=>{const{node:i}=n({status:{addresses:[{type:t,address:"10.0.0.1"}],nodeInfo:{}}});expect(l(a(i).glance,e)).toStrictEqual({name:e,label:r,formatter:"CopyToClipboard",content:"10.0.0.1"})}),it.each(["externalIp","internalIp"])("should show a dash without a copy button when the node has no %p",e=>{const{node:t}=n(),r=l(a(t).glance,e);expect(r.formatter).toBeUndefined(),expect(r.content).toStrictEqual("—")}),it("should show the external IP from the annotation when the node has no external address",()=>{const{node:e}=n({metadata:{name:"node-1",annotations:{"rke.cattle.io/external-ip":"1.2.3.4"}}});expect(l(a(e).glance,"externalIp").content).toStrictEqual("1.2.3.4")}),it.each([["version",{kubeletVersion:"v1.33.1+k3s1"},"v1.33.1+k3s1"],["os",{osImage:"Ubuntu 24.04 LTS"},"Ubuntu 24.04 LTS"],["version",{},"—"],["os",{},"—"]])("should show the %p row from the node info %p as %p",(e,t,r)=>{const{node:i}=n({status:{addresses:[],nodeInfo:t}});expect(l(a(i).glance,e).content).toStrictEqual(r)})}),describe("glanceUsage",()=>{const t=(e,t)=>e.glanceUsage.find(e=>e.name===t).percentage,r=(e,t)=>({spec:{nodeName:e},state:t}),o=(e,t="node-1")=>Array.from({length:e},()=>r(t,"running"));it("should return the CPU, memory and pods usage in that order",()=>{const{node:e}=n();expect(e.glanceUsage.map(e=>[e.name,e.label])).toStrictEqual([["cpu","component.resource.detail.glance.cpu"],["memory","component.resource.detail.glance.memory"],["pods","component.resource.detail.glance.pods"]])}),it.each([["cpu",{usage:{cpu:"1",memory:"0"}},25],["memory",{usage:{cpu:"0",memory:"2Gi"}},25]])("should work out the %p usage from the metrics of the node",(e,r,i)=>{const{node:o}=n({},{metrics:r});expect(t(o,e)).toStrictEqual(i)}),it.each([["cpu",void 0],["memory",void 0],["cpu",{usage:{}}],["memory",{usage:{}}]])("should not have a %p usage when there are no metrics %p",(e,r)=>{const{node:i}=n({},{metrics:r});expect(t(i,e)).toBeUndefined()}),it.each([["cpu",{allocatable:{memory:"8Gi"},capacity:{memory:"8Gi"}}],["memory",{allocatable:{cpu:"4"},capacity:{cpu:"4"}}]])("should not have a %p usage when the node has no capacity",(e,r)=>{const{node:i}=n({status:{addresses:[],nodeInfo:{},...r}},{metrics:{usage:{cpu:"1",memory:"2Gi"}}});expect(t(i,e)).toBeUndefined()}),describe("pods, without server-side pagination, when every pod is in the store",()=>{it("should count the running pods on the node in the store, like the Nodes list",()=>{const e=[...o(11),r("node-1","crashLoopBackOff"),r("node-1","completed"),...o(5,"node-2")],{node:a,rootGetters:s}=n({},{pods:e,haveAllPods:!0});expect(t(a,"pods")).toStrictEqual(10),expect(t(a,"pods")).toStrictEqual(Number.parseFloat(a.podConsumedUsage)),expect(s["cluster/haveAll"]).toHaveBeenCalledWith(i.Sm)}),it.each([["has no pods",[]],["has no running pods",[r("node-1","crashLoopBackOff")]]])("should not have a pods usage when the node %s, like the Nodes list shows n/a",(e,r)=>{const{node:i}=n({},{pods:r,haveAllPods:!0});expect(t(i,"pods")).toBeUndefined()}),it("should not use a saved count of the running pods",()=>{const{node:r,rootGetters:i}=n({},{pods:o(11),haveAllPods:!0,savedCounts:{[e]:55}});expect(t(r,"pods")).toStrictEqual(10),expect(i["cluster/getSavedCount"].mock.calls).toStrictEqual([])})}),describe("pods, without server-side pagination, when only some pods are in the store",()=>{it("should work out the pods usage from the running pods counted by a request",()=>{const{node:r}=n({},{savedCounts:{[e]:11}});expect(t(r,"pods")).toStrictEqual(10)}),it("should not count the pods in the store, which may only be the pods of some namespaces",()=>{const{node:e,rootGetters:r}=n({},{pods:o(11)});expect(t(e,"pods")).toBeUndefined(),expect(r["cluster/all"].mock.calls).toStrictEqual([])}),it.each([["has not been counted yet",{}],["is zero, like the Nodes list shows n/a",{[e]:0}],["was counted in another cluster",{"nodeRunningPods/c-m-abcdef/node-1":11}]])("should not have a pods usage when the count of running pods %s",(e,r)=>{const{node:i}=n({},{savedCounts:r});expect(t(i,"pods")).toBeUndefined()})}),describe("pods, with server-side pagination",()=>{it.each([[11,10],[55,50],[220,200]])("should work out the pods usage from %p running pods counted by the API",(r,o)=>{const{node:a,rootGetters:s}=n({},{paginated:!0,savedCounts:{[e]:r}});expect(t(a,"pods")).toStrictEqual(o),expect(s["cluster/paginationEnabled"]).toHaveBeenCalledWith(i.Sm)}),it("should not count the pods in the store, which are only a page of pods",()=>{const{node:e,rootGetters:r}=n({},{paginated:!0,haveAllPods:!0,pods:o(11)});expect(t(e,"pods")).toBeUndefined(),expect(r["cluster/all"].mock.calls).toStrictEqual([])}),it.each([["has not been counted yet",{}],["is zero, like the Nodes list shows n/a",{[e]:0}],["was counted in another cluster",{"nodeRunningPods/c-m-abcdef/node-1":11}]])("should not have a pods usage when the count of running pods %s",(e,r)=>{const{node:i}=n({},{paginated:!0,savedCounts:r});expect(t(i,"pods")).toBeUndefined()})}),it.each([["zero",!1,{pods:"0"}],["missing",!1,{}],["zero",!0,{pods:"0"}],["missing",!0,{}]])("should not have a pods usage when the pod capacity is %s (server-side pagination: %p)",(r,i,a)=>{const{node:s}=n({status:{addresses:[],nodeInfo:{},capacity:a}},{paginated:i,pods:o(11),savedCounts:{[e]:11}});expect(t(s,"pods")).toBeUndefined()})}),describe("fetchGlanceResources",()=>{const t=(new AbortController).signal,r=["cluster/find",{type:i.$v.NODE,id:"node-1",opt:{force:!0,watch:!1,signal:t}},{root:!0}],a=["cluster/request",{url:"https://rancher/k8s/clusters/local/v1/pods?filter=spec.nodeName=node-1",signal:t},{root:!0}],s=["cluster/findPage",{type:i.Sm,opt:{transient:!0,saveCountAs:e,signal:t,pagination:new o.gR({page:1,pageSize:1,filters:[o.eY.createSingleField({field:"spec.nodeName",value:"node-1"}),o.eY.createSingleField({field:"metadata.state.name",value:"running"})]})}},{root:!0}];it("should fetch the metrics of the node without watching them, and request the pods on the node without storing them",async()=>{const{node:e,dispatch:o,rootGetters:s}=n();await e.fetchGlanceResources(t),expect(o.mock.calls).toStrictEqual([r,a]),expect(s["cluster/urlFor"]).toHaveBeenCalledWith(i.Sm)}),it("should not fetch pods when every pod is already in the store, as they are counted there",async()=>{const{node:e,dispatch:i,commit:o}=n({},{haveAllPods:!0});await e.fetchGlanceResources(t),expect(i.mock.calls).toStrictEqual([r]),expect(o).toHaveBeenCalledTimes(0)}),it("should only count the running pods on the node with server-side pagination, without storing them",async()=>{const{node:e,dispatch:i}=n({},{paginated:!0});await e.fetchGlanceResources(t),expect(i.mock.calls).toStrictEqual([r,s])}),it("should not fetch metrics when the cluster has no metrics API",async()=>{const{node:e,dispatch:r,rootGetters:o}=n({},{hasMetricsSchema:!1});await e.fetchGlanceResources(t),expect(o["cluster/schemaFor"]).toHaveBeenCalledWith(i.$v.NODE),expect(r.mock.calls).toStrictEqual([a])}),it.each([!1,!0])("should not fetch pods when the user can not see them (server-side pagination: %p)",async e=>{const{node:o,dispatch:a,rootGetters:s}=n({},{canViewPods:!1,paginated:e});await o.fetchGlanceResources(t),expect(s["cluster/schemaFor"]).toHaveBeenCalledWith(i.Sm),expect(a.mock.calls).toStrictEqual([r])}),it("should fetch nothing when the user can see neither metrics nor pods",async()=>{const{node:e,dispatch:r}=n({},{hasMetricsSchema:!1,canViewPods:!1});await expect(e.fetchGlanceResources(t)).resolves.toBeUndefined(),expect(r.mock.calls).toStrictEqual([])}),it("should still count the pods, and then reject, when the metrics can not be fetched",async()=>{const{node:e,dispatch:i}=n({},{paginated:!0});i.mockImplementation(e=>"cluster/find"===e?Promise.reject(new Error("forbidden")):Promise.resolve()),await expect(e.fetchGlanceResources(t)).rejects.toThrow("forbidden"),expect(i.mock.calls).toStrictEqual([r,s])}),it("should wait for the pods to be counted before rejecting when the metrics can not be fetched",async()=>{const{node:e,dispatch:r}=n({},{paginated:!0});let i=!1;r.mockImplementation(e=>"cluster/find"===e?Promise.reject(new Error("forbidden")):new Promise(e=>setTimeout(e,0)).then(()=>{i=!0})),await expect(e.fetchGlanceResources(t)).rejects.toThrow("forbidden"),expect(i).toBe(!0)}),describe("counting the running pods without server-side pagination",()=>{const r=(e,t)=>({spec:{nodeName:e},metadata:{state:{name:t}}}),i=t=>["cluster/setSavedCount",{name:e,count:t},{root:!0}],o=(e,t)=>e.mockImplementation(e=>Promise.resolve("cluster/request"===e?t:void 0));it("should save the count of the running pods on the node, like the Nodes list counts them",async()=>{const{node:e,dispatch:a,commit:s}=n({},{hasMetricsSchema:!1});o(a,{data:[...Array.from({length:11},()=>r("node-1","running")),r("node-1","crashLoopBackOff"),r("node-1","completed"),r("node-1","terminating")]}),await e.fetchRunningPods(t),expect(s.mock.calls).toStrictEqual([i(11)])}),it("should not count the pods on another node that the filter matches part of the name of",async()=>{const{node:e,dispatch:a,commit:s}=n({},{hasMetricsSchema:!1});o(a,{data:[r("node-1","running"),r("node-10","running"),r("my-node-1","running")]}),await e.fetchRunningPods(t),expect(s.mock.calls).toStrictEqual([i(1)])}),it.each([["no pods",{data:[]}],["no data",{}],["nothing",void 0]])("should save a count of zero when the request returns %s",async(e,r)=>{const{node:a,dispatch:s,commit:l}=n({},{hasMetricsSchema:!1});o(s,r),await a.fetchRunningPods(t),expect(l.mock.calls).toStrictEqual([i(0)])}),it("should add the filter to the query of a collection url that already has one",async()=>{const{node:e,dispatch:r,rootGetters:i}=n({},{hasMetricsSchema:!1});i["cluster/urlFor"].mockReturnValue("https://rancher/k8s/clusters/local/v1/pods?exclude=metadata.managedFields"),o(r,{data:[]}),await e.fetchRunningPods(t),expect(r).toHaveBeenCalledWith("cluster/request",{url:"https://rancher/k8s/clusters/local/v1/pods?exclude=metadata.managedFields&filter=spec.nodeName=node-1",signal:t},{root:!0})}),it("should encode the node name in the request",async()=>{const{node:e,dispatch:r}=n({id:"node 1&x",metadata:{name:"node 1&x",annotations:{}}},{hasMetricsSchema:!1});o(r,{data:[]}),await e.fetchRunningPods(t),expect(r).toHaveBeenCalledWith("cluster/request",{url:"https://rancher/k8s/clusters/local/v1/pods?filter=spec.nodeName=node%201%26x",signal:t},{root:!0})})}),it.each([!1,!0])("should forget the count of running pods, so the card shows n/a, and reject when the pods can not be counted (server-side pagination: %p)",async r=>{const{node:i,dispatch:o,commit:a}=n({},{hasMetricsSchema:!1,paginated:r});o.mockRejectedValue(new Error("server error")),await expect(i.fetchGlanceResources(t)).rejects.toThrow("server error"),expect(a.mock.calls).toStrictEqual([["cluster/setSavedCount",{name:e,count:void 0},{root:!0}]])}),it.each([!1,!0])("should keep the last count of running pods, and reject, when the request is cancelled (server-side pagination: %p)",async e=>{const{node:t,dispatch:r,commit:i}=n({},{hasMetricsSchema:!1,paginated:e}),o=new AbortController;r.mockImplementation(()=>(o.abort(),Promise.reject(new Error("canceled")))),await expect(t.fetchGlanceResources(o.signal)).rejects.toThrow("canceled"),expect(i).toHaveBeenCalledTimes(0)}),it("should not save a count itself with server-side pagination, as the API saves it",async()=>{const{node:e,commit:r}=n({},{hasMetricsSchema:!1,paginated:!0});await e.fetchGlanceResources(t),expect(r).toHaveBeenCalledTimes(0)})})})})},54566:function(e,t,n){"use strict";n.r(t);var r=n(76006),i=n(35664);const o={type:i.oU.REPLICA_SET,name:"frontend-57b8b59b77",namespace:"default"},a=(e={},{schema:t={id:i.oU.REPLICA_SET}}={})=>new r["default"]({metadata:{name:"frontend-57b8b59b77-abcde",namespace:"default"},...e},{getters:{schemaFor:jest.fn(()=>t)},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e,"type-map/labelFor":jest.fn(()=>"ReplicaSet")}}),s=e=>{Object.defineProperty(e,"_glance",{get:()=>[{name:"state"},{name:"type"},{name:"namespace"},{name:"age"}]})},l=e=>({name:"app",ready:e,restartCount:0,state:{running:{}}});describe("class Pod",()=>{describe("containerReadiness",()=>{it.each([["no containers or statuses",{},{},{ready:0,total:0}],["all containers ready",{containers:[{name:"a"},{name:"b"}]},{containerStatuses:[l(!0),l(!0)]},{ready:2,total:2}],["one container not ready",{containers:[{name:"a"},{name:"b"}]},{containerStatuses:[l(!0),l(!1)]},{ready:1,total:2}],["statuses not reported yet",{containers:[{name:"a"}]},{},{ready:0,total:1}],["a ready container that is not running",{containers:[{name:"a"}]},{containerStatuses:[{name:"a",ready:!0,state:{terminated:{}}}]},{ready:0,total:1}]])("should count %p",(e,t,n,r)=>{const i=a({spec:t,status:n});expect(i.containerReadiness).toStrictEqual(r)}),it("should count a started and ready sidecar init container",()=>{const e=a({spec:{containers:[{name:"app"}],initContainers:[{name:"setup"},{name:"proxy",restartPolicy:"Always"}]},status:{containerStatuses:[l(!0)],initContainerStatuses:[{name:"setup",ready:!0,started:!0,state:{terminated:{exitCode:0}}},{name:"proxy",ready:!0,started:!0,state:{running:{}}}]}});expect(e.containerReadiness).toStrictEqual({ready:2,total:2})}),it("should not count the app containers while a regular init container is running",()=>{const e=a({spec:{containers:[{name:"app"}],initContainers:[{name:"setup"}]},status:{containerStatuses:[l(!0)],initContainerStatuses:[{name:"setup",ready:!1,state:{running:{}}}]}});expect(e.containerReadiness).toStrictEqual({ready:0,total:1})}),it("should count a sidecar that has not started as not ready",()=>{const e=a({spec:{containers:[{name:"app"}],initContainers:[{name:"proxy",restartPolicy:"Always"}]},status:{initContainerStatuses:[{name:"proxy",ready:!1,started:!1,state:{waiting:{}}}]}});expect(e.containerReadiness).toStrictEqual({ready:0,total:2})})}),describe("totalRestartCount",()=>{it("should add up the app container and sidecar restarts once the pod has initialised",()=>{const e=a({spec:{containers:[{name:"app"},{name:"worker"}],initContainers:[{name:"setup"},{name:"proxy",restartPolicy:"Always"}]},status:{containerStatuses:[{name:"app",restartCount:2},{name:"worker",restartCount:3}],initContainerStatuses:[{name:"setup",restartCount:5,state:{terminated:{exitCode:0}}},{name:"proxy",restartCount:1,started:!0,state:{running:{}}}]}});expect(e.totalRestartCount).toStrictEqual(6)}),it("should only add up the init container restarts while the pod is initialising",()=>{const e=a({spec:{containers:[{name:"app"}],initContainers:[{name:"setup"}]},status:{containerStatuses:[{name:"app",restartCount:2}],initContainerStatuses:[{name:"setup",restartCount:4,state:{waiting:{reason:"CrashLoopBackOff"}}}]}});expect(e.totalRestartCount).toStrictEqual(4)}),it("should add up the app container restarts when the pod reports it has initialised",()=>{const e=a({spec:{containers:[{name:"app"}],initContainers:[{name:"setup"}]},status:{conditions:[{type:"Initialized",status:"True"}],containerStatuses:[{name:"app",restartCount:2}],initContainerStatuses:[{name:"setup",restartCount:4,state:{waiting:{}}}]}});expect(e.totalRestartCount).toStrictEqual(2)}),it("should be 0 when no container statuses are reported",()=>{const e=a({status:{}});expect(e.totalRestartCount).toStrictEqual(0)})}),describe("node row in details",()=>{const e="ip-172-31-13-111",t=()=>a({spec:{nodeName:e},status:{podIP:"10.42.0.1"}}),n=e=>e.details.find(e=>"Node"===e.label);it("should keep the LinkName formatter for views of the details that do not use the popover",()=>{const r=n(t());expect([r.formatter,r.formatterOpts,r.content]).toStrictEqual(["LinkName",{type:i.NW,value:e},e])}),it("should show a popover of the node in the masthead",()=>{const{valueOverride:r}=n(t());expect(r.props).toStrictEqual({type:i.NW,value:e})}),it("should use the same popover component every time the details are worked out",()=>{const e=t();expect(n(e).valueOverride.component).toBe(n(e).valueOverride.component)}),it("should not have a node row when the pod has not been scheduled",()=>{const e=t();e.spec={},expect(n(e)).toBeUndefined()})}),describe("workloadTypeLabel",()=>{it("should use the label of the owning workload type",()=>{const e=a();jest.spyOn(e,"workloadRef","get").mockReturnValue(o),expect(e.workloadTypeLabel).toStrictEqual("ReplicaSet"),expect(e.$rootGetters["type-map/labelFor"]).toHaveBeenCalledWith({id:i.oU.REPLICA_SET})}),it("should fall back to a generic label when the workload type has no schema",()=>{const e=a({},{schema:null});jest.spyOn(e,"workloadRef","get").mockReturnValue(o),expect(e.workloadTypeLabel).toStrictEqual("component.resource.detail.glance.workload")})}),describe("details",()=>{it("should label the workload row with the type of the workload",()=>{const e=a({spec:{},status:{podIP:"10.42.0.1"}});jest.spyOn(e,"workloadRef","get").mockReturnValue(o);const t=e.details.find(e=>e.content===o.name);expect(t.label).toStrictEqual("ReplicaSet")});const e={...o,id:`${o.namespace}/${o.name}`},t=[i.NW,...Object.values(i.oU).filter(e=>e!==i.oU.REPLICA_SET)],s=(e,t=[i.oU.REPLICA_SET])=>{const n=new r["default"]({metadata:{name:"frontend-57b8b59b77-abcde",namespace:"default"},spec:{},status:{podIP:"10.42.0.1"}},{getters:{schemaFor:jest.fn(e=>t.includes(e)?{id:e}:null)},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e,"type-map/labelFor":jest.fn(()=>"ReplicaSet"),productId:"explorer",clusterId:"local"}});return jest.spyOn(n,"workloadRef","get").mockReturnValue(e),n},l=e=>e.details.find(t=>t.content===e.workloadRef.name);it("should show a popover for a ReplicaSet owner, without its state",()=>{const{valueOverride:t}=l(s(e));expect(t.props).toStrictEqual({type:i.oU.REPLICA_SET,id:"default/frontend-57b8b59b77",name:"frontend-57b8b59b77",showStatus:!1,detailLocation:{name:"c-cluster-product-resource-namespace-id",params:{product:"explorer",cluster:"local",resource:i.oU.REPLICA_SET,namespace:"default",id:"frontend-57b8b59b77"}}})}),it("should show the ReplicaSet with the ResourcePopover component",async()=>{const{default:t}=await n.e(411).then(n.bind(n,80411)),{valueOverride:r}=l(s(e));expect(await r.component.__asyncLoader()).toBe(t)}),it("should check that the user can see ReplicaSets before showing the popover",()=>{const t=s(e);l(t),expect(t.$getters.schemaFor).toHaveBeenCalledWith(i.oU.REPLICA_SET)}),it("should reuse the same popover component every time the details are built",()=>{const t=s(e),n=l(t),r=l(t);expect(n.valueOverride.component).toBeDefined(),expect(r.valueOverride.component).toBe(n.valueOverride.component)}),it("should keep the plain link on a ReplicaSet row for consumers that ignore the popover",()=>{const t=l(s(e));expect(t.formatter).toStrictEqual("LinkName"),expect(t.formatterOpts).toStrictEqual({value:"frontend-57b8b59b77",type:i.oU.REPLICA_SET,namespace:"default"})}),it.each([i.oU.DEPLOYMENT,i.oU.JOB,i.oU.STATEFUL_SET,i.oU.DAEMON_SET,i.oU.REPLICATION_CONTROLLER])("should show a plain link rather than a popover for a %p owner",e=>{const t=l(s({type:e,name:"owner",namespace:"default",id:"default/owner"},[i.oU.REPLICA_SET,e]));expect(t.valueOverride).toBeUndefined(),expect(t.formatter).toStrictEqual("LinkName")}),it("should show a plain link when the user can see every type but ReplicaSets",()=>{const n=l(s(e,t));expect(n.valueOverride).toBeUndefined(),expect(n.formatter).toStrictEqual("LinkName")})}),describe("glance",()=>{const e={spec:{nodeName:"ip-172-31-13-111",containers:[{name:"app"}]},status:{phase:"Running",podIP:"10.42.112.167",containerStatuses:[{...l(!0),restartCount:4}]}};it("should add the pod rows between the namespace and age rows",()=>{const t=a(e);jest.spyOn(t,"workloadRef","get").mockReturnValue(o),s(t),expect(t.glance.map(e=>e.name)).toStrictEqual(["state","type","namespace","ready","restarts","podIp","workload","node","age"])}),it("should show the ready count with a status coloured by readiness",()=>{const t=a(e);s(t);const n=t.glance.find(e=>"ready"===e.name);expect(n).toStrictEqual({name:"ready",label:"component.resource.detail.glance.ready",formatter:"ReadyIndicator",formatterOpts:{ready:1,total:1,status:void 0},content:"1/1"})}),it.each(["Succeeded","Failed"])("should show a neutral ready status when the pod has %p",t=>{const n=a({...e,status:{...e.status,phase:t}});s(n);const r=n.glance.find(e=>"ready"===e.name);expect(r.formatterOpts.status).toStrictEqual("none")}),it("should show the restarts of all containers",()=>{const t=a(e);s(t);const n=t.glance.find(e=>"restarts"===e.name);expect(n.content).toStrictEqual(4)}),it("should show the pod IP with a copy button",()=>{const t=a(e);s(t);const n=t.glance.find(e=>"podIp"===e.name);expect(n).toStrictEqual({name:"podIp",label:"component.resource.detail.glance.podIp",formatter:"CopyToClipboard",formatterOpts:{plain:!0},content:"10.42.112.167"})}),it("should show a dash and no copy button when the pod has no IP",()=>{const t=a({...e,status:{phase:"Pending"}});s(t);const n=t.glance.find(e=>"podIp"===e.name);expect(n.formatter).toBeUndefined(),expect(n.content).toStrictEqual("—")}),it("should link to the owning workload, labelled with its type",()=>{const t=a(e);jest.spyOn(t,"workloadRef","get").mockReturnValue(o),s(t);const n=t.glance.find(e=>"workload"===e.name);expect(n).toStrictEqual({name:"workload",label:"ReplicaSet",formatter:"LinkName",formatterOpts:{value:o.name,type:o.type,namespace:o.namespace},content:o.name})}),it("should link to the node the pod is scheduled on",()=>{const t=a(e);s(t);const n=t.glance.find(e=>"node"===e.name);expect(n).toStrictEqual({name:"node",label:"component.resource.detail.glance.node",formatter:"LinkName",formatterOpts:{type:i.NW,value:"ip-172-31-13-111"},content:"ip-172-31-13-111"})}),it("should leave out the workload and node rows when the pod has no owner and is not scheduled",()=>{const e=a({spec:{containers:[{name:"app"}]},status:{phase:"Pending"}});jest.spyOn(e,"workloadRef","get").mockReturnValue(void 0),s(e);const t=e.glance.map(e=>e.name);expect(t).toStrictEqual(["state","type","namespace","ready","restarts","podIp","age"])})})})},54837:function(e,t,n){"use strict";n.r(t);var r=n(97219);const i=r["default"];describe("class Principal",()=>{describe("avatarSrc",()=>{it("should use the github profile picture (sized) when one is set",()=>{const e=new i({id:"github_user://123",provider:"github",profilePicture:"https://avatars.example/u/123.png"});expect(e.avatarSrc).toStrictEqual("https://avatars.example/u/123.png?s=80")}),it("should fall back to a generated identicon for a github principal without a picture",()=>{const e=new i({id:"github_user://123",provider:"github"});expect(()=>e.avatarSrc).not.toThrow(),expect(e.avatarSrc).toMatch(/^data:image\/png;base64,/)}),it("should use a generated identicon for non-github providers",()=>{const e=new i({id:"local://u-abc",provider:"local"});expect(e.avatarSrc).toMatch(/^data:image\/png;base64,/)})})})},29759:function(e,t,n){"use strict";n.r(t);var r=n(47685),i=n(65230),o=n(11518),a=n(2841),s=n(9262),l=n(35664),c=n(19463),u=n(27278),d=n(21342);jest.mock("@shell/utils/operation-cr",()=>({createOperationCR:jest.fn()})),jest.mock("@shell/components/nav/TopLevelMenu.helper",()=>({__esModule:!0,default:{helper:{clustersLocal:[]}}})),jest.mock("@shell/utils/provider",()=>({isHostedProvider:jest.fn().mockImplementation((e,t)=>["GKE","EKS","AKS"].includes(t)),isCAPIProvider:jest.fn().mockImplementation((e,t)=>["capa","capv"].includes(t.toLowerCase()))})),jest.mock("@shell/utils/clipboard",()=>({copyTextToClipboard:jest.fn(()=>Promise.resolve({}))})),describe("class ProvCluster",()=>{const e={clusterName:"test",provisioner:"GKE",spec:{},mgmt:new i["default"]({spec:{gkeConfig:{privateClusterConfig:{enablePrivateEndpoint:!0}}}})},t={clusterName:"test",provisioner:"EKS",spec:{},mgmt:new i["default"]({spec:{eksConfig:{privateAccess:!0}}})},n={clusterName:"test",provisioner:"AKS",spec:{},mgmt:new i["default"]({spec:{aksConfig:{privateCluster:!0}}})};describe("isHostedKubernetesProvider + isPrivateHostedProvider",()=>{const i=[[e,!0],[t,!0],[n,!0]],o=()=>{jest.clearAllMocks()};it.each(i)("should return the isHostedKubernetesProvider and isPrivateHostedProvider values properly based on the props data",(e,t)=>{const n=new r["default"]({spec:e.spec});jest.spyOn(e.mgmt,"provCluster","get").mockReturnValue(e),jest.spyOn(n,"mgmt","get").mockReturnValue(e.mgmt),jest.spyOn(e.mgmt,"provisioner","get").mockReturnValue(e.provisioner),expect(n.isRke2).toBe(!1),expect(n.isHostedKubernetesProvider).toBe(t),expect(n.isPrivateHostedProvider).toBe(t),o()})}),describe("isImported",()=>{const e=[{description:"should return false for a local cluster",clusterData:{isLocal:!0},expected:!1},{description:"should return true for an imported k3s cluster",clusterData:{isLocal:!1,mgmt:{status:{provider:"k3s",driver:"k3s"}}},expected:!0},{description:"should return true for an imported k3s cluster in waiting state",clusterData:{isLocal:!1,mgmt:{status:{provider:void 0,driver:"k3s"}}},expected:!0},{description:"should return true for an imported rke2 cluster in waiting state",clusterData:{isLocal:!1,mgmt:{status:{provider:void 0,driver:"rke2"}}},expected:!0},{description:"should return false for a provisioned k3s cluster",clusterData:{isLocal:!1,mgmt:{status:{provider:"k3s",driver:"imported"}}},expected:!1},{description:"should return true for an imported rke2 cluster",clusterData:{isLocal:!1,mgmt:{status:{provider:"rke2",driver:"rke2"}}},expected:!0},{description:"should return false for a provisioned rke2 cluster",clusterData:{isLocal:!1,mgmt:{status:{provider:"rke2",driver:"imported"}}},expected:!1},{description:"should return true for an imported hosted cluster",clusterData:{isLocal:!1,isHostedKubernetesProvider:!0,providerConfig:{imported:!0},mgmt:{status:{provider:"",driver:"EKS"}}},expected:!0},{description:"should return false for a provisioned hosted cluster",clusterData:{isLocal:!1,isHostedKubernetesProvider:!0,providerConfig:{imported:!1},mgmt:{status:{provider:"",driver:"EKS"}}},expected:!1},{description:"should return true for a generic imported cluster",clusterData:{isLocal:!1,provisioner:"imported"},expected:!0},{description:"should return false for a generic provisioned cluster",clusterData:{isLocal:!1,provisioner:"rke2"},expected:!1}],t=()=>{jest.clearAllMocks()};it.each(e)("$description",({clusterData:e,expected:n})=>{const o=new i["default"](e.mgmt||{}),a=new r["default"]({});jest.spyOn(a,"mgmt","get").mockReturnValue(o),jest.spyOn(o,"provCluster","get").mockReturnValue(a),void 0!==e.isLocal&&jest.spyOn(o,"isLocal","get").mockReturnValue(e.isLocal),void 0!==e.isHostedKubernetesProvider&&jest.spyOn(o,"isHostedKubernetesProvider","get").mockReturnValue(e.isHostedKubernetesProvider),void 0!==e.providerConfig&&jest.spyOn(a,"providerConfig","get").mockReturnValue(e.providerConfig),void 0!==e.provisioner&&jest.spyOn(o,"provisioner","get").mockReturnValue(e.provisioner),expect(a.isImported).toBe(n),t()})}),describe("hasError",()=>{const e=[{error:!1,lastUpdateTime:"2022-10-17T23:09:15Z",status:"True",transitioning:!1,type:"Ready"}],t=[{error:!0,lastUpdateTime:"2022-10-17T23:09:15Z",status:"False",message:"some-error-message",transitioning:!1,type:"Pending"}],n=[],o=[{error:!0,lastUpdateTime:"2022-10-17T23:09:15Z",status:"False",message:"some-error-message",transitioning:!1,type:"Pending"},{error:!1,lastUpdateTime:"2023-10-17T23:09:15Z",status:"True",transitioning:!1,type:"Ready"}],a=[{error:!1,lastUpdateTime:"2022-10-17T23:09:15Z",status:"True",transitioning:!1,type:"Ready"},{error:!0,lastUpdateTime:"2023-10-17T23:09:15Z",status:"False",message:"some-error-message",transitioning:!1,type:"Pending"}],s=[{error:!0,lastUpdateTime:"",status:"False",message:"some-error-message",transitioning:!1,type:"Pending"},{error:!1,lastUpdateTime:"2023-10-17T23:09:15Z",status:"True",transitioning:!1,type:"Ready"}],l=[["conditionsWithoutError",e,!1],["conditionsWithoutReady",t,!0],["noConditions",n,!1],["conditionsWithReadyLatest",o,!1],["conditionsWithErrorLatest",a,!0],["conditionsWithProblemInLastUpdateTimeProp",s,!1]],c=()=>{jest.clearAllMocks()};it.each(l)('should return the hasError value properly based on the "status.conditions" props data for testcase %p',(e,t,n)=>{const o={rootGetters:{"management/byId":jest.fn()}},a=new i["default"]({status:{conditions:t}},o),s=new r["default"]({},o);jest.spyOn(s,"mgmt","get").mockReturnValue(a),expect(s.hasError).toBe(n),c()})}),describe("isK3s",()=>{it.each([["a k3s management cluster",{status:{provider:"k3s"}},"v1.35.0+rke2r1",!0],["an rke2 management cluster",{status:{provider:"rke2"}},"v1.35.0+k3s1",!1]])("should use the management cluster when there is one (%s)",(e,t,n,o)=>{const a=new r["default"]({spec:{kubernetesVersion:n,rkeConfig:{}}});jest.spyOn(a,"mgmt","get").mockReturnValue(new i["default"](t)),expect(a.isK3s).toBe(o)}),it.each([["v1.35.0+k3s1",!0],["v1.35.0+rke2r1",!1],[void 0,!1]])("without a management cluster (e.g. when creating), should use kubernetes version %p",(e,t)=>{const n=new r["default"]({spec:{kubernetesVersion:e,rkeConfig:{}}});jest.spyOn(n,"mgmt","get").mockReturnValue(null),expect(n.isK3s).toBe(t)})}),describe("supportsWindows",()=>{const e=[{description:"should return false for k3s",clusterData:{isK3s:!0},expected:!1},{description:"should return false for imported k3s",clusterData:{isImportedK3s:!0},expected:!1},{description:"should return windowsPreferedCluster for rke1",clusterData:{isRke1:!0,mgmt:{spec:{windowsPreferedCluster:!0}}},expected:!0},{description:"should return false for rke1 if windowsPreferedCluster is false/missing",clusterData:{isRke1:!0,mgmt:{spec:{windowsPreferedCluster:!1}}},expected:!1},{description:"should return false if not rke2 (and not rke1 or k3s)",clusterData:{isRke2:!1},expected:!1},{description:"should return false if kubernetesVersion is missing",clusterData:{isRke2:!0,kubernetesVersion:void 0},expected:!1},{description:"should return false if kubernetesVersion is less than v1.21.0",clusterData:{isRke2:!0,kubernetesVersion:"v1.20.9"},expected:!1},{description:"should return false if cni is not calico or flannel",clusterData:{isRke2:!0,kubernetesVersion:"v1.34.0",spec:{rkeConfig:{machineGlobalConfig:{cni:"cilium"}}}},expected:!1},{description:"should return true if cni is calico",clusterData:{isRke2:!0,kubernetesVersion:"v1.34.0",spec:{rkeConfig:{machineGlobalConfig:{cni:"calico"}}}},expected:!0},{description:"should return false if cni is flannel and kubernetesVersion is less than v1.29.2 (e.g. v1.29.1)",clusterData:{isRke2:!0,kubernetesVersion:"v1.29.1",spec:{rkeConfig:{machineGlobalConfig:{cni:"flannel"}}}},expected:!1},{description:"should return true if cni is flannel and kubernetesVersion is exactly v1.29.2",clusterData:{isRke2:!0,kubernetesVersion:"v1.29.2",spec:{rkeConfig:{machineGlobalConfig:{cni:"flannel"}}}},expected:!0},{description:"should return true if cni is flannel and kubernetesVersion is >= v1.29.2 (e.g. v1.35.0)",clusterData:{isRke2:!0,kubernetesVersion:"v1.35.0",spec:{rkeConfig:{machineGlobalConfig:{cni:"flannel"}}}},expected:!0},{description:"should return true if cni is empty/undefined",clusterData:{isRke2:!0,kubernetesVersion:"v1.34.0",spec:{rkeConfig:{machineGlobalConfig:{}}}},expected:!0}];it.each(e)("$description",({clusterData:e,expected:t})=>{const n=new r["default"]({spec:e.spec});jest.spyOn(n,"mgmt","get").mockReturnValue(e.mgmt),jest.spyOn(n,"isK3s","get").mockReturnValue(e.isK3s||!1),jest.spyOn(n,"isImportedK3s","get").mockReturnValue(e.isImportedK3s||!1),jest.spyOn(n,"isRke1","get").mockReturnValue(e.isRke1||!1),jest.spyOn(n,"isRke2","get").mockReturnValue(e.isRke2||!1),jest.spyOn(n,"kubernetesVersion","get").mockReturnValue(e.kubernetesVersion),expect(n.supportsWindows).toBe(t),jest.clearAllMocks()})}),describe("isCapiWithoutExtension",()=>{const e=[{description:"should return undefined when mgmt is undefined",isCapiHybrid:void 0,isCAPIProvider:void 0,expected:void 0},{description:"should return false when not a CAPI cluster",isCapiHybrid:!1,isCAPIProvider:!1,expected:!1},{description:"should return false when CAPI cluster and a registered CAPI provider extension exists",isCapiHybrid:!0,isCAPIProvider:!0,expected:!1},{description:"should return true when CAPI cluster but no registered CAPI provider extension",isCapiHybrid:!0,isCAPIProvider:!1,expected:!0}];it.each(e)("$description",({isCapiHybrid:e,isCAPIProvider:t,expected:n})=>{const o=new r["default"]({});if(void 0===e)jest.spyOn(o,"mgmt","get").mockReturnValue(void 0);else{const n=new i["default"]({});jest.spyOn(n,"isCapiHybrid","get").mockReturnValue(e),jest.spyOn(n,"isCAPIProvider","get").mockReturnValue(t),jest.spyOn(o,"mgmt","get").mockReturnValue(n)}expect(o.isCapiWithoutExtension).toStrictEqual(n),jest.clearAllMocks()})}),describe("day 2 operations",()=>{const e=({byId:e=jest.fn(),all:t=jest.fn(()=>[]),schemaFor:n=jest.fn(()=>({}))}={})=>({getters:{schemaFor:n},rootGetters:{"management/byId":e,"management/all":t}});it("should return true when the day 2 operations feature is enabled",()=>{const t=jest.fn().mockImplementation((e,t)=>{if(e===l.Mc.FEATURE&&t===o.IY)return{enabled:!0}}),n=new r["default"]({},e({byId:t}));expect(n.isDayTwoOpsFeatureEnabled).toBe(!0)}),it("should return true for imported RKE2 day 2 operations when the annotation is enabled",()=>{const t=jest.fn().mockImplementation((e,t)=>{if(e===l.Mc.FEATURE&&t===o.IY)return{enabled:!0}}),n=new r["default"]({},e({byId:t}));jest.spyOn(n,"mgmt","get").mockReturnValue({metadata:{annotations:{[a.P0.ENABLED]:"true"}}}),jest.spyOn(n,"isImportedRke2K3s","get").mockReturnValue(!0),expect(n.isImportedWithDayTwoOps).toBe(!0)}),it("should return true for imported RKE2 day 2 operations when the global setting is enabled",()=>{const t=jest.fn().mockImplementation((e,t)=>e===l.Mc.FEATURE&&t===o.IY?{enabled:!0}:e===l.Mc.SETTING&&t===s.HG.IMPORTED_CLUSTER_DAY2_OPS_DEFAULT?{value:"true"}:void 0),n=new r["default"]({},e({byId:t}));jest.spyOn(n,"mgmt","get").mockReturnValue({metadata:{annotations:{}}}),jest.spyOn(n,"isImportedRke2K3s","get").mockReturnValue(!0),expect(n.isImportedWithDayTwoOps).toBe(!0)}),it("should return false for imported RKE2 day 2 operations when the feature is disabled",()=>{const t=jest.fn().mockImplementation((e,t)=>{if(e===l.Mc.SETTING&&t===s.HG.IMPORTED_CLUSTER_DAY2_OPS_DEFAULT)return{value:"true"}}),n=new r["default"]({},e({byId:t}));jest.spyOn(n,"mgmt","get").mockReturnValue({metadata:{annotations:{[a.P0.ENABLED]:"true"}}}),jest.spyOn(n,"isImportedRke2K3s","get").mockReturnValue(!0),expect(n.isImportedWithDayTwoOps).toBeFalsy()}),it("should return false for imported RKE2 day 2 operations when operation schema is missing",()=>{const t=jest.fn().mockImplementation((e,t)=>e===l.Mc.FEATURE&&t===o.IY?{enabled:!0}:e===l.Mc.SETTING&&t===s.HG.IMPORTED_CLUSTER_DAY2_OPS_DEFAULT?{value:"true"}:void 0),n=jest.fn().mockReturnValue(void 0),i=new r["default"]({},e({byId:t,schemaFor:n}));jest.spyOn(i,"mgmt","get").mockReturnValue({metadata:{annotations:{[a.P0.ENABLED]:"true"}}}),jest.spyOn(i,"isImportedRke2K3s","get").mockReturnValue(!0),expect(i.isImportedWithDayTwoOps).toBeFalsy()}),it("should filter etcd snapshots by management cluster fields for imported day 2 operations clusters",()=>{const t=[{metadata:{namespace:"c-m-1"},spec:{clusterName:"imported-cluster"}},{metadata:{namespace:"c-m-1"},spec:{clusterName:"other-cluster"}},{metadata:{namespace:"c-m-2"},spec:{clusterName:"imported-cluster"}}],n=jest.fn().mockReturnValue(t),i=new r["default"]({},e({all:n}));jest.spyOn(i,"isImportedWithDayTwoOps","get").mockReturnValue(!0),jest.spyOn(i,"mgmt","get").mockReturnValue({id:"c-m-1",metadata:{name:"imported-cluster"}}),expect(i.etcdSnapshots).toStrictEqual([t[0]])}),it("should create an operation CR when taking a snapshot on an imported RKE2 or K3s cluster",()=>{const t=new r["default"]({},e());c.l.mockResolvedValue(void 0),jest.spyOn(t,"isRke1","get").mockReturnValue(!1),jest.spyOn(t,"isImportedWithDayTwoOps","get").mockReturnValue(!0),jest.spyOn(t,"mgmt","get").mockReturnValue({id:"c-m-1",metadata:{name:"imported-cluster"}}),t.takeSnapshot(),expect(c.l).toHaveBeenCalledTimes(1),expect(c.l.mock.calls[0][1]).toBe(l.qR.ETCD_SNAPSHOT),expect(c.l.mock.calls[0][2]).toStrictEqual({clusterRef:{apiVersion:"management.cattle.io/v3",kind:"Cluster",name:"c-m-1"}}),expect(c.l.mock.calls[0][3]).toBe("c-m-1"),expect(c.l.mock.calls[0][4]).toBe("imported-cluster")})}),describe("namespaceLocation",()=>{const e=e=>{d.Ay.helper.clustersLocal.length=0,e&&d.Ay.helper.clustersLocal.push({id:l.d_})};it("should route to the local cluster explorer when local is accessible",()=>{e(!0);const t=new r["default"]({metadata:{namespace:"fleet-default"}});expect(t.namespaceLocation).toStrictEqual({name:"c-cluster-product-resource-id",params:{cluster:l.d_,product:u.o,resource:l.CU,id:"fleet-default"}})}),it("should return null when the user has no access to the local cluster",()=>{e(!1);const t=new r["default"]({metadata:{namespace:"fleet-default"}});expect(t.namespaceLocation).toBeNull()})}),describe("pin / unpin",()=>{const e=jest.fn(),t=t=>{t={links:{},hasAction:()=>!1,...t};const n=new r["default"]({},{getters:{schemaFor:jest.fn(()=>({}))},rootGetters:{"i18n/t":e=>e},dispatch:e});return jest.spyOn(n,"mgmt","get").mockReturnValue(t),n};beforeEach(()=>e.mockClear());const n=e=>(jest.spyOn(Object.getPrototypeOf(Object.getPrototypeOf(e)),"_availableActions","get").mockReturnValue([]),jest.spyOn(e,"customProvisionerHelper","get").mockReturnValue(void 0),e._availableActions),i=(e,t)=>n(e).find(e=>e.action===t);it.each([["pinCluster","pin"],["unpinCluster","unpin"]])("%s delegates to the management cluster",(e,n)=>{const r={[n]:jest.fn()};t(r)[e](),expect(r[n]).toHaveBeenCalledTimes(1)}),it.each([["pinClusterBulk","pinBulk"],["unpinClusterBulk","unpinBulk"]])("%s hands the whole selection to the management cluster, for one write",(e,n)=>{const r={[n]:jest.fn()},i=[{id:"cluster-1"},{id:"cluster-2"}];t(r)[e](i),expect(r[n]).toHaveBeenCalledWith(i)}),it("offers the pin only while the cluster is unpinned, and the unpin only while it is pinned",()=>{const e=t({pinned:!1,isLocal:!1}),n=t({pinned:!0,isLocal:!1});expect(i(e,"pinCluster").enabled).toBe(!0),expect(i(e,"unpinCluster").enabled).toBe(!1),expect(i(n,"pinCluster").enabled).toBe(!1),expect(i(n,"unpinCluster").enabled).toBe(!0)}),it("offers neither for local",()=>{const e=t({pinned:!1,isLocal:!0});expect(i(e,"pinCluster").enabled).toBe(!1),expect(i(e,"unpinCluster").enabled).toBe(!1)}),it.each([["pinCluster","pin"],["unpinCluster","unpin"],["pinClusterBulk","pinBulk"],["unpinClusterBulk","unpinBulk"]])("%s growls when the preference write is rejected",async(n,r)=>{const i={[r]:jest.fn(()=>Promise.resolve({type:"error",status:500}))};await t(i)[n]([]),expect(e).toHaveBeenCalledWith("growl/fromError",expect.objectContaining({title:"nav.pinClusterError"}),{root:!0})}),it("stays quiet when the preference write lands",async()=>{const n={pin:jest.fn(()=>Promise.resolve({}))};await t(n).pinCluster(),expect(e).not.toHaveBeenCalled()}),it("leads the bulk actions, pin before unpin",()=>{const e=n(t({pinned:!1,isLocal:!1})).filter(e=>e.bulkable).sort((e,t)=>(t.weight||0)-(e.weight||0)).map(e=>e.action);expect(e.slice(0,2)).toStrictEqual(["pinCluster","unpinCluster"])}),it("keeps the pin on an RKE1 cluster, which cannot take most other actions",()=>{const e=t({pinned:!1,isLocal:!1});jest.spyOn(e,"isRke1","get").mockReturnValue(!0),expect(i(e,"pinCluster").enabled).toBe(!0)})}),describe("copyKubeConfigBulk",()=>{it("should delegate to mgmt cluster copyKubeConfigBulk method",async()=>{const e=jest.fn().mockResolvedValue(void 0),t=new i["default"]({});t.copyKubeConfigBulk=e;const n=new r["default"]({});jest.spyOn(n,"mgmt","get").mockReturnValue(t);const o=[{id:"cluster-1",mgmt:{id:"mgmt-cluster-1"}},{id:"cluster-2",mgmt:{id:"mgmt-cluster-2"}}];await n.copyKubeConfigBulk(o),expect(e).toHaveBeenCalledWith(o)}),it("should handle when mgmt cluster is undefined",()=>{const e=new r["default"]({});jest.spyOn(e,"mgmt","get").mockReturnValue(void 0);const t=[{id:"cluster-1"}];expect(e.copyKubeConfigBulk(t)).toBeUndefined()}),it("should pass through all items to mgmt cluster",async()=>{const e=jest.fn().mockResolvedValue(void 0),t=new i["default"]({});t.copyKubeConfigBulk=e;const n=new r["default"]({});jest.spyOn(n,"mgmt","get").mockReturnValue(t);const o=[{id:"rke2-cluster",mgmt:{id:"c-m-1"}},{id:"k3s-cluster",mgmt:{id:"c-m-2"}},{id:"eks-cluster",mgmt:{id:"c-m-3"}}];await n.copyKubeConfigBulk(o),expect(e).toHaveBeenCalledWith(o),expect(e).toHaveBeenCalledTimes(1)})})})},22892:function(e,t,n){"use strict";n.r(t);var r=n(38816);describe("class VmwarevsphereMachineTemplate",()=>{describe("providerLocation",()=>{it.each([["/DC1/host/ClusterA/Resources","ClusterA"],["/DC1/host/ClusterA/Resources/PoolX","ClusterA"],["/DC1/host/ClusterA/Resources/","ClusterA"],["/DC1/host/esxi01/Resources","esxi01"],["/DC1/vm/FolderA",null],["/DC1/host/foo/ResourcesPool/bar",null],["/DC1/host//Resources/PoolX",null],["",null],[null,null],[void 0,null]])("returns %p for pool %p",(e,t)=>{const n=new r["default"]({spec:{template:{spec:{pool:e}}}});expect(n.providerLocation).toStrictEqual(t)})})})},81453:function(e,t,n){"use strict";n.r(t);var r=n(2334);describe("class: schema:",()=>{describe("parseType",()=>{it.each([["array",void 0,["array"]],["map",void 0,["map"]],["io.cattle.provisioning.v1.Cluster.status",void 0,["io.cattle.provisioning.v1.Cluster.status"]],["array[string]",void 0,["array","string"]],["array",{subtype:"string"},["array","string"]],["map[string]",void 0,["map","string"]],["map",{subtype:"string"},["map","string"]],["array[io.cattle.provisioning.v1.Cluster.status]",void 0,["array","io.cattle.provisioning.v1.Cluster.status"]],["array",{subtype:"io.cattle.provisioning.v1.Cluster.status"},["array","io.cattle.provisioning.v1.Cluster.status"]],["map[io.cattle.provisioning.v1.Cluster.status]",void 0,["map","io.cattle.provisioning.v1.Cluster.status"]],["map",{subtype:"io.cattle.provisioning.v1.Cluster.status"},["map","io.cattle.provisioning.v1.Cluster.status"]]])("string: %p and field: %p ... should equal %p",(e,t,n)=>{expect((0,r.parseType)(e,t)).toStrictEqual(n)})})})},66131:function(e,t,n){"use strict";n.r(t);var r=n(1133),i=n(35664),o=n(2841),a=n(10213);describe("class Secret (project scoped secret getters)",()=>{const e="c-m-abc123",t="p-xyz789";it("isProjectScoped is true when the PSS labels are present and isRancher is true",()=>{const n=new r["default"]({metadata:{labels:{[o.Qw]:t,[o.Bt]:e}}},{rootGetters:{isRancher:!0}});expect(n.isProjectScoped).toBe(!0),expect(n.projectScopedProjectName).toBe(t),expect(n.projectScopedClusterId).toBe(e)}),it("isProjectScoped is false when isRancher is false",()=>{const n=new r["default"]({metadata:{labels:{[o.Qw]:t,[o.Bt]:e}}},{rootGetters:{isRancher:!1}});expect(n.isProjectScoped).toBe(!1)}),it("isProjectScoped is false when it is itself a copy created by a PSS",()=>{const n=new r["default"]({metadata:{labels:{[o.Qw]:t,[o.Bt]:e},annotations:{[o.c8]:"true"}}},{rootGetters:{isRancher:!0}});expect(n.isProjectScoped).toBe(!1),expect(n.isProjectSecretCopy).toBe(!0),expect(n.projectSecretCopyProjectName).toBe(t),expect(n.projectSecretCopyClusterId).toBe(e)}),it("isProjectScoped is false without the PSS project label",()=>{const e=new r["default"]({metadata:{labels:{}}},{rootGetters:{isRancher:!0}});expect(e.isProjectScoped).toBe(!1)}),it("projectCluster looks up the cluster via the management store when project scoped",()=>{const n={id:e},s=jest.fn().mockReturnValue(n),l=new r["default"]({metadata:{labels:{[o.Qw]:t,[o.Bt]:e}}},{rootGetters:{isRancher:!0,[`${a.e.MANAGEMENT}/byId`]:s}});expect(l.projectCluster).toBe(n),expect(s).toHaveBeenCalledWith(i.Mc.CLUSTER,e)}),it("projectCluster is undefined when the secret is not project scoped",()=>{const e=new r["default"]({metadata:{labels:{}}},{rootGetters:{isRancher:!0}});expect(e.projectCluster).toBeUndefined()}),it("project resolves via the composite clusterId/projectName id first",()=>{const n={id:`${e}/${t}`},s=jest.fn().mockImplementation((r,i)=>i===`${e}/${t}`?n:void 0),l=new r["default"]({metadata:{labels:{[o.Qw]:t,[o.Bt]:e}}},{rootGetters:{isRancher:!0,[`${a.e.MANAGEMENT}/byId`]:s}});expect(l.project).toBe(n),expect(s).toHaveBeenCalledWith(i.Mc.PROJECT,`${e}/${t}`)}),it("project falls back to the plain project name id when the composite id is not found",()=>{const n={id:t},i=jest.fn().mockImplementation((e,r)=>r===t?n:void 0),s=new r["default"]({metadata:{labels:{[o.Qw]:t,[o.Bt]:e}}},{rootGetters:{isRancher:!0,[`${a.e.MANAGEMENT}/byId`]:i}});expect(s.project).toBe(n)}),it("project resolves for a PSS-created copy using the copy labels",()=>{const n={id:`${e}/${t}`},i=jest.fn().mockReturnValue(n),s=new r["default"]({metadata:{labels:{[o.Qw]:t,[o.Bt]:e},annotations:{[o.c8]:"true"}}},{rootGetters:{isRancher:!0,[`${a.e.MANAGEMENT}/byId`]:i}});expect(s.project).toBe(n)}),it("project is undefined when there is no project name",()=>{const e=new r["default"]({metadata:{labels:{}}},{rootGetters:{isRancher:!0}});expect(e.project).toBeUndefined()})})},28688:function(e,t,n){"use strict";n.r(t);var r=n(1133),i=n(17259),o=n(35664),a=n(2841),s=n(14220),l=n(47034);describe("class Secret (SteveModel/Resource overrides)",()=>{describe("detailLocation",()=>{it("should return correct route for project scoped secret",()=>{const e=new r["default"]({metadata:{namespace:"c-cluster-p-project",labels:{[a.Qw]:"p-project"}},id:"c-cluster-p-project/my-secret"});Object.defineProperty(e,"$rootGetters",{value:{productId:"explorer",clusterId:"c-cluster",isRancher:!0}});const t=e.detailLocation;expect(t.name).toBe(`c-cluster-product-${o.cG.PROJECT_SECRETS}-namespace-id`),expect(t.params.resource).toBe(o.cG.PROJECT_SECRETS),expect(t.params.product).toBe("explorer"),expect(t.params.cluster).toBe("c-cluster"),expect(t.params.namespace).toBe("c-cluster-p-project"),expect(t.params.id).toBe("my-secret")}),it("should return default detailLocation for non-project scoped secret",()=>{const e=new r["default"]({metadata:{namespace:"default"},id:"default/my-secret"});Object.defineProperty(e,"$rootGetters",{value:{productId:"explorer",clusterId:"c-cluster",isRancher:!0}});const t={name:"some-route"};Object.defineProperty(e,"_detailLocation",{value:t}),expect(e.detailLocation).toBe(t)})}),describe("listLocation",()=>{const e={productId:"explorer",clusterId:"c-cluster",isRancher:!0};it("points at the project secrets list when the project-scoped query param is set",()=>{const t=new r["default"]({},{rootGetters:e});jest.spyOn(t,"currentRoute").mockReturnValue({query:{[s.SD]:s.dq.PROJECT_SCOPED}});const n=t.listLocation;expect(n.name).toBe("c-cluster-product-resource"),expect(n.params.resource).toBe(o.cG.PROJECT_SECRETS)}),it("points at the project secrets list when the secret is project scoped",()=>{const t=new r["default"]({metadata:{labels:{[a.Qw]:"p-project",[a.Bt]:"c-cluster"}}},{rootGetters:e});jest.spyOn(t,"currentRoute").mockReturnValue({query:{}});const n=t.listLocation;expect(n.params.resource).toBe(o.cG.PROJECT_SECRETS)}),it("falls back to the default secret list location otherwise",()=>{const t=new r["default"]({type:o.Sg,metadata:{}},{rootGetters:e,rootState:{$extension:{getPlugins:()=>({})}}});jest.spyOn(t,"currentRoute").mockReturnValue({query:{}});const n=t.listLocation;expect(n.params.resource).toBe(o.Sg)})}),describe("parentNameOverride / parentLocationOverride",()=>{it("override to the project secrets label/location when project scoped via query param",()=>{const e=jest.fn().mockReturnValue("Project Secrets "),t=new r["default"]({},{rootGetters:{productId:"explorer",clusterId:"c-cluster",isRancher:!0,"i18n/t":e}});jest.spyOn(t,"currentRoute").mockReturnValue({query:{[s.SD]:s.dq.PROJECT_SCOPED}}),expect(t.parentNameOverride).toBe("Project Secrets"),expect(t.parentLocationOverride).toStrictEqual(t.listLocation)}),it("fall back to undefined (no base override) otherwise",()=>{const e=new r["default"]({metadata:{}});jest.spyOn(e,"currentRoute").mockReturnValue({query:{}}),expect(e.parentNameOverride).toBeUndefined(),expect(e.parentLocationOverride).toBeUndefined()})}),describe("cleanForDownload",()=>{it("should contains the type attribute if cleanForDownload",async()=>{const e=new r["default"]({}),t="apiVersion: v1\nkind: Secret\nmetadata:\n name: my-secret\ntype: Opaque\n",n=await e.cleanForDownload(t);expect(n).toBe(t)}),it("should remove id, links and actions keys if cleanForDownload",async()=>{const e=new r["default"]({}),t="apiVersion: v1\nkind: Secret\nmetadata:\n name: my-secret\n namespace: default\ntype: Opaque\n",n="id: test_id\nlinks:\n view: https://example.com\nactions:\n remove: https://example.com",i=`${t}\n${n}`,o=await e.cleanForDownload(i);expect(o).toBe(t)})}),describe("cleanForSave",()=>{it("removes _type when creating a new secret",()=>{const e=new r["default"]({_type:i.J.OPAQUE,metadata:{name:"my-secret"}}),t=e.cleanForSave({_type:i.J.OPAQUE,metadata:{name:"my-secret"}},!0);expect(t._type).toBeUndefined()}),it("keeps _type when updating an existing secret",()=>{const e=new r["default"]({_type:i.J.OPAQUE,metadata:{name:"my-secret"}}),t=e.cleanForSave({_type:i.J.OPAQUE,metadata:{name:"my-secret"}},!1);expect(t._type).toBe(i.J.OPAQUE)})}),describe("doneRoute",()=>{it("returns the manager route when the current product is the manager",()=>{const e=new r["default"]({},{rootGetters:{currentProduct:{name:l.o}}});expect(e.doneRoute).toBe("c-cluster-manager-secret")}),it("returns the generic resource route otherwise",()=>{const e=new r["default"]({},{rootGetters:{currentProduct:{name:"explorer"}}});expect(e.doneRoute).toBe("c-cluster-product-resource")})}),describe("permissions (canUpdate, canDelete, canCreate, canEditYaml)",()=>{const e=(e,{isEditable:t=!0,isRemovable:n=!0,isCreatable:i=!0}={})=>new r["default"](e,{getters:{schemaFor:()=>{}},rootGetters:{"type-map/optionsFor":()=>({isEditable:t,isRemovable:n,isCreatable:i})}});it("are all false when the secret is a project scoped secret copy",()=>{const t=e({links:{update:"u",remove:"r"},metadata:{annotations:{[a.c8]:"true"}}});expect(t.canUpdate).toBe(!1),expect(t.canDelete).toBe(!1),expect(t.canCreate).toBe(!1),expect(t.canEditYaml).toBe(!1)}),it("canUpdate is false without an update link",()=>{const t=e({links:{}});expect(t.canUpdate).toBe(!1)}),it("canUpdate is false for service account secrets even with an update link and edit permission",()=>{const t=e({links:{update:"u"},_type:i.J.SERVICE_ACCT});expect(t.canUpdate).toBe(!1)}),it("canUpdate delegates to the update link and edit permission for other types",()=>{const t=e({links:{update:"u"},_type:i.J.OPAQUE});expect(t.canUpdate).toBe(!0)}),it("canDelete delegates to the remove link and remove permission",()=>{const t=e({links:{remove:"r"}}),n=e({links:{}});expect(t.canDelete).toBe(!0),expect(n.canDelete).toBe(!1)}),it("canCreate delegates to the create permission",()=>{const t=e({links:{}},{isCreatable:!0}),n=e({links:{}},{isCreatable:!1});expect(t.canCreate).toBe(!0),expect(n.canCreate).toBe(!1)}),it("canEditYaml mirrors canUpdate",()=>{const t=e({links:{update:"u"},_type:i.J.OPAQUE});expect(t.canEditYaml).toBe(t.canUpdate),expect(t.canEditYaml).toBe(!0)})})})},19147:function(e,t,n){"use strict";n.r(t);var r=n(1133),i=n(17259),o=n(35664),a=n(2841),s=n(14220),l=n(10213),c=n(73883),u=n(4514);const d="-----BEGIN CERTIFICATE-----\nMIIDVjCCAj6gAwIBAgIUCSnVWva2lqhAIsYNiWQ6/z5KX6AwDQYJKoZIhvcNAQEL\nBQAwGzEZMBcGA1UEAwwQdGVzdC5leGFtcGxlLmNvbTAeFw0yNjA4MDYxMjM5MTNa\nFw0zNjA4MDMxMjM5MTNaMBsxGTAXBgNVBAMMEHRlc3QuZXhhbXBsZS5jb20wggEi\nMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDW+mkSeXRrbO0DnTOD3nG4C254\nI33MOwqaBMP49y2u0W8oDHRznEVGo3mCLs3eP7upikoDhtG8Z0vAp24s6hiiYjOZ\n0xg00lcxy2zQ927vupbNcDexCVrPTltR6FEZeZpuBx3U1AgOu5+50BQBQf/p5Q2G\n7XXDYrGMV3zPfwfFACEm28ws4LzWJp6ZULRHtIYANRXuosuRPcZ3ivMD7lZ5Fbj7\n5E9zm/f267sQVlKc56abSHOPyxgvizD32PSOyOx65h0QGHsC4pNO+xuQK6nQlr7l\nxO3WLQxcsaXwbcmr3kqgpJN1LPY4B4ulIEvp7TlqWU8gl0z/Lkr1QSEN5/mhAgMB\nAAGjgZEwgY4wHQYDVR0OBBYEFEpsogHCd0+ofQgnKRnJ3r4l/nHyMB8GA1UdIwQY\nMBaAFEpsogHCd0+ofQgnKRnJ3r4l/nHyMA8GA1UdEwEB/wQFMAMBAf8wOwYDVR0R\nBDQwMoIQdGVzdC5leGFtcGxlLmNvbYINKi5leGFtcGxlLmNvbYIPd3d3LmV4YW1w\nbGUuY29tMA0GCSqGSIb3DQEBCwUAA4IBAQBzkPzuNf61zMFEfMKUKhNT1AHqey1e\nsBhaazf3FEcdIJBc6thFtaURUnAf4TwUpBCp03vZtAfqp43IG2J1E9ls5cLix/IH\nVGl/VSDkJonIEgDf82uHMe3G0z7TT7s1ip8WqfSy/dPEnrSzZZzegh0iKUZACEW5\nypd+n4cocaIunTTN0wjaEujoPmm5iqiGAVa7ThXVnjiMF339hcdoJvdS4wtEEcND\nOXBBoVgfus15ldfG1GWYjFgVL2yagdzDcp0xTD7VsFkn2DA4nm/LmO/LhpaSR4Zh\ny+lCdK7a+W0LW1MJu/aKYlCzkSEyErPA7hgxpeu95Wt5OdG/WH0UAVec\n-----END CERTIFICATE-----\n";describe("class Secret",()=>{describe("supportsSshKnownHosts",()=>{it.each([[!1,"type is not SSH","generic",{known_hosts:"S05PV05fSE9TVFM="}],[!1,"missing known_hosts",i.J.SSH,{}],[!1,"data is null",i.J.SSH,null],[!0,"type is SSH key and known_hosts exists",i.J.SSH,{known_hosts:"S05PV05fSE9TVFM="}]])("is %p if %p",(e,t,n,i)=>{const o=new r["default"]({_type:n,data:i}),a=o.supportsSshKnownHosts;expect(a).toBe(e)})}),describe("isGithubApp",()=>{const e={github_app_id:"MTI=",github_app_installation_id:"MzQ=",github_app_private_key:"a2V5"};it.each([[!1,"type is not Opaque",i.J.SSH,e],[!1,"data is null",i.J.OPAQUE,null],[!1,"Opaque but missing a GitHub App key",i.J.OPAQUE,{github_app_id:"MTI=",github_app_installation_id:"MzQ="}],[!0,"Opaque with all GitHub App keys",i.J.OPAQUE,e]])("is %p if %p",(e,t,n,i)=>{const o=new r["default"]({_type:n,data:i});expect(o.isGithubApp).toBe(e)})}),describe("GitHub App display",()=>{const e={[i.u.APP_ID]:(0,u.KA)("12345"),[i.u.INSTALLATION_ID]:(0,u.KA)("67890"),[i.u.PRIVATE_KEY]:(0,u.KA)("a-private-key")},t={rootGetters:{"i18n/withFallback":(e,t,n)=>n}};it("dataPreview should show the decoded App ID and Installation ID",()=>{const n=new r["default"]({_type:i.J.OPAQUE,data:e},t);expect(n.dataPreview).toBe("12345 / 67890")}),it("subTypeDisplay should resolve to the GitHub App label",()=>{const n=new r["default"]({_type:i.J.OPAQUE,data:e},t);expect(n.subTypeDisplay).toBe("GitHub App")}),it("subTypeDisplay should fall back to a stripped type name for non-GitHub-App secrets",()=>{const e=jest.fn((e,t,n)=>n),t=new r["default"]({_type:i.J.BASIC,data:{username:(0,u.KA)("bob")}},{rootGetters:{"i18n/withFallback":e}});expect(t.subTypeDisplay).toBe("basic-auth"),expect(e).toHaveBeenCalledWith(`secret.types."${i.J.BASIC}"`,null,"basic-auth")})}),describe("type classification",()=>{it.each([["isCertificate",i.J.TLS,!0],["isCertificate",i.J.OPAQUE,!1],["isRegistry",i.J.DOCKER_JSON,!0],["isRegistry",i.J.TLS,!1]])("%s is %p for type %s",(e,t,n)=>{const i=new r["default"]({_type:t});expect(i[e]).toBe(n)}),it("isCloudCredential is true when _type is the cloud credential type",()=>{const e=new r["default"]({_type:i.J.CLOUD_CREDENTIAL});expect(e.isCloudCredential).toBe(!0)}),it("isCloudCredential is true when namespace is cattle-global-data and generateName is cc-",()=>{const e=new r["default"]({_type:i.J.OPAQUE,metadata:{namespace:"cattle-global-data",generateName:"cc-"}});expect(e.isCloudCredential).toBe(!0)}),it("isCloudCredential is false for an unrelated opaque secret",()=>{const e=new r["default"]({_type:i.J.OPAQUE,metadata:{namespace:"default"}});expect(e.isCloudCredential).toBe(!1)})}),describe("certInfo (real PEM parsing)",()=>{it("parses issuer, cn, notBefore, notAfter and sans from a valid TLS cert",()=>{const e=new r["default"]({_type:i.J.TLS,data:{"tls.crt":(0,u.KA)(d)}}),t=e.certInfo;expect(t.cn).toBe("test.example.com"),expect(t.issuer).toBe("test.example.com"),expect(t.notBefore.getUTCFullYear()).toBe(2026),expect(t.notAfter.getUTCFullYear()).toBe(2036),expect(t.sans.array).toHaveLength(3)}),it("returns null when there is no tls.crt data key",()=>{const e=new r["default"]({_type:i.J.TLS,data:{}});expect(e.certInfo).toBeNull()}),it("returns null when the PEM cannot be parsed",()=>{const e=new r["default"]({_type:i.J.TLS,data:{"tls.crt":(0,u.KA)("not-a-real-certificate")}});expect(e.certInfo).toBeNull()}),it("isCertificate derived getters resolve using the parsed cert when there is no cert-manager annotation",()=>{const e=new r["default"]({_type:i.J.TLS,data:{"tls.crt":(0,u.KA)(d)},metadata:{}});expect(e.cn).toBe("test.example.com"),expect(e.issuer).toBe("test.example.com"),expect(e.plusMoreNames).toBe(3)}),it("issuer prefers the cert-manager annotation over the parsed cert issuer",()=>{const e=new r["default"]({_type:i.J.TLS,data:{"tls.crt":(0,u.KA)(d)},metadata:{annotations:{[a.G5.ISSUER]:"letsencrypt-prod"}}});expect(e.issuer).toBe("letsencrypt-prod")}),it("cn, issuer, notAfter and plusMoreNames are null for non-certificate secrets",()=>{const e=new r["default"]({_type:i.J.OPAQUE,data:{},metadata:{}});expect(e.cn).toBeNull(),expect(e.issuer).toBeNull(),expect(e.notAfter).toBeNull(),expect(e.plusMoreNames).toBeNull()})}),describe("cachedCertInfo",()=>{it("parses certInfo once and reuses the cached value",()=>{const e=new r["default"]({_type:i.J.TLS,data:{"tls.crt":(0,u.KA)(d)}}),t=jest.spyOn(e,"certInfo","get"),n=e.cachedCertInfo,o=e.cachedCertInfo;expect(n).toBe(o),expect(t).toHaveBeenCalledTimes(1)})}),describe("unrepeatedSans",()=>{const e=e=>{const t=new r["default"]({_type:i.J.TLS,data:{}});return Object.defineProperty(t,"cachedCertInfo",{get:()=>({sans:e}),configurable:!0}),t};it("returns null for non-certificate secrets",()=>{const e=new r["default"]({_type:i.J.OPAQUE,data:{}});expect(e.unrepeatedSans).toBeNull()}),it("removes sans that exactly match the suffix of a wildcard/www entry",()=>{const t=e(["app.example.com",".example.com","*.example.com"]);expect(t.unrepeatedSans).toStrictEqual(["app.example.com","*.example.com"])}),it("leaves sans unchanged when no entry matches the wildcard/www suffix",()=>{const t=e(["test.example.com","*.example.com","www.example.com"]);expect(t.unrepeatedSans).toStrictEqual(["test.example.com","*.example.com","www.example.com"])}),it("falls back to the .array property when sans is not a plain array (jsrsasign getExtSubjectAltName shape)",()=>{const t=[{dns:"test.example.com"},{dns:"*.example.com"}],n=e({extname:"subjectAltName",array:t});expect(n.unrepeatedSans).toBe(t)}),it("returns an empty array when there are no sans",()=>{const t=e(void 0);expect(t.unrepeatedSans).toStrictEqual([])})}),describe("TLS expiration state (dateClass, certState, certStateDisplay, certStateBackground, timeTilExpiration, timeTilExpirationDate)",()=>{const e=864e5,t=e=>{const t=new r["default"]({_type:i.J.TLS,data:{}});return Object.defineProperty(t,"cachedCertInfo",{get:()=>({notAfter:e}),configurable:!0}),t};afterEach(()=>{jest.restoreAllMocks()}),it("is not expiring when notAfter is well beyond the expiring window",()=>{const n=new Date(Date.now()+30*e),r=t(n);expect(r.certState).toBe(""),expect(r.dateClass).toBe(""),expect(r.certStateDisplay).toBe("Active"),expect(r.timeTilExpiration).toBeGreaterThan(8*e),expect(r.timeTilExpirationDate).toBe(n.valueOf())}),it("is expiring when notAfter is within the 8 day expiring window but still in the future",()=>{const n=new Date(Date.now()+3*e),r=t(n);expect(r.certState).toBe(c.jv.EXPIRING),expect(r.dateClass).toBe("text-warning"),expect(r.certStateDisplay).toBe("Expiring"),expect(r.certStateBackground).toBe("bg-warning"),expect(r.timeTilExpiration).toBeGreaterThan(0),expect(r.timeTilExpirationDate).toBe(n.valueOf())}),it("is expired when notAfter is in the past",()=>{const n=new Date(Date.now()-e),r=t(n);expect(r.certState).toBe(c.jv.EXPIRED),expect(r.dateClass).toBe("text-error"),expect(r.certStateDisplay).toBe("Expired"),expect(r.certStateBackground).toBe("bg-error"),expect(r.timeTilExpiration).toBe(0),expect(r.timeTilExpirationDate).toBeNull()}),it("is undefined/null for non-certificate secrets",()=>{const e=new r["default"]({_type:i.J.OPAQUE,data:{}});expect(e.certState).toBeUndefined(),expect(e.certStateDisplay).toBeUndefined(),expect(e.certStateBackground).toBeUndefined(),expect(e.dateClass).toBeNull(),expect(e.timeTilExpiration).toBeNull(),expect(e.timeTilExpirationDate).toBeNull()})}),describe("certLifetime",()=>{const e=e=>e;it("returns a formatted duration string for a certificate",()=>{const t=new r["default"]({_type:i.J.TLS,data:{}},{rootGetters:{"i18n/t":e}});Object.defineProperty(t,"cachedCertInfo",{get:()=>({notBefore:new Date("2026-01-01T00:00:00Z"),notAfter:new Date("2026-01-11T00:00:00Z")}),configurable:!0}),expect(t.certLifetime).toBe("10 unit.day")}),it("returns null when there is no cert info",()=>{const t=new r["default"]({_type:i.J.TLS,data:{}},{rootGetters:{"i18n/t":e}});Object.defineProperty(t,"cachedCertInfo",{get:()=>null,configurable:!0}),expect(t.certLifetime).toBeNull()}),it("returns null for non-certificate secrets",()=>{const t=new r["default"]({_type:i.J.OPAQUE,data:{}},{rootGetters:{"i18n/t":e}});expect(t.certLifetime).toBeNull()})}),describe("keysDisplay",()=>{it("joins data and binaryData keys",()=>{const e=new r["default"]({data:{foo:"YmFy"},binaryData:{img:"aW1n"}});expect(e.keysDisplay).toBe("foo, img")}),it("returns (none) when there are no keys",()=>{const e=new r["default"]({});expect(e.keysDisplay).toBe("(none)")})}),describe("dataPreview",()=>{it("lists the auths domains for a valid dockerconfigjson secret",()=>{const e={auths:{"index.docker.io":{},"quay.io":{}}},t=new r["default"]({_type:i.J.DOCKER_JSON,data:{".dockerconfigjson":(0,u.KA)(JSON.stringify(e))}});expect(t.dataPreview).toBe("index.docker.io, quay.io")}),it("falls back to the raw decoded string when dockerconfigjson is not valid JSON",()=>{const e=new r["default"]({_type:i.J.DOCKER_JSON,data:{".dockerconfigjson":(0,u.KA)("not json")}});expect(e.dataPreview).toBe("not json")}),it("shows the decoded username for basic-auth secrets",()=>{const e=new r["default"]({_type:i.J.BASIC,data:{username:(0,u.KA)("my-user")}});expect(e.dataPreview).toBe("my-user")}),it("shows the sshUser for ssh-auth secrets",()=>{const e=new r["default"]({_type:i.J.SSH,data:{"ssh-publickey":(0,u.KA)("ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQC user@host")}});expect(e.dataPreview).toBe("user@host")}),it("shows the service account name annotation for service account secrets",()=>{const e=new r["default"]({_type:i.J.SERVICE_ACCT,metadata:{annotations:{"kubernetes.io/service-account.name":"my-sa"}}});expect(e.dataPreview).toBe("my-sa")}),it("shows the cert info for TLS secrets",()=>{const e=new r["default"]({_type:i.J.TLS,data:{"tls.crt":(0,u.KA)(d)}});expect(e.dataPreview).toStrictEqual(e.certInfo)}),it("falls back to keysDisplay for unrecognized secret types",()=>{const e=new r["default"]({_type:i.J.OPAQUE,data:{key1:"dmFsdWU="}});expect(e.dataPreview).toBe("key1")})}),describe("sshUser",()=>{it("returns null when the secret is not an SSH secret",()=>{const e=new r["default"]({_type:i.J.OPAQUE,data:{}});expect(e.sshUser).toBeNull()}),it("returns null when there is no ssh-publickey data",()=>{const e=new r["default"]({_type:i.J.SSH,data:{}});expect(e.sshUser).toBeNull()}),it("extracts the user from an OpenSSH format public key",()=>{const e=new r["default"]({_type:i.J.SSH,data:{"ssh-publickey":(0,u.KA)("ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQC user@example.com")}});expect(e.sshUser).toBe("user@example.com")}),it("extracts the user from a PEM format public key comment",()=>{const e=new r["default"]({_type:i.J.SSH,data:{"ssh-publickey":(0,u.KA)('----BEGIN SSH2 PUBLIC KEY----\nComment: "imported-openssh-key from OpenSSH by someuser@host"\nAAAA\n----END SSH2 PUBLIC KEY----')}});expect(e.sshUser).toBe("someuser@host")}),it("returns null when the public key format is unrecognized",()=>{const e=new r["default"]({_type:i.J.SSH,data:{"ssh-publickey":(0,u.KA)("not-a-key")}});expect(e.sshUser).toBeNull()})}),describe("decodedData",()=>{it("base64 decodes every key in data",()=>{const e=new r["default"]({data:{foo:(0,u.KA)("bar"),baz:(0,u.KA)("qux")}});expect(e.decodedData).toStrictEqual({foo:"bar",baz:"qux"})}),it("returns an empty object when there is no data",()=>{const e=new r["default"]({});expect(e.decodedData).toStrictEqual({})})}),describe("setData",()=>{it("sets and base64 encodes a single key/value pair, initializing data",()=>{const e=new r["default"]({});e.setData("foo","bar"),expect((0,u.u)(e.data.foo)).toBe("bar")}),it("sets a map of key/value pairs, replacing existing data",()=>{const e=new r["default"]({data:{existing:(0,u.KA)("old")}});e.setData({foo:"bar",baz:"qux"}),expect(e.data.existing).toBeUndefined(),expect((0,u.u)(e.data.foo)).toBe("bar"),expect((0,u.u)(e.data.baz)).toBe("qux")}),it("handles keys containing dots without treating them as a path",()=>{const e=new r["default"]({});e.setData(".dockerconfigjson","{}"),expect((0,u.u)(e.data[".dockerconfigjson"])).toBe("{}")})}),describe("hasProjectScopedUrlQueryParam",()=>{it("is true when the current route has the project-scoped query param",()=>{const e=new r["default"]({});jest.spyOn(e,"currentRoute").mockReturnValue({query:{[s.SD]:s.dq.PROJECT_SCOPED}}),expect(e.hasProjectScopedUrlQueryParam).toBe(!0)}),it("is false without the query param",()=>{const e=new r["default"]({});jest.spyOn(e,"currentRoute").mockReturnValue({query:{}}),expect(e.hasProjectScopedUrlQueryParam).toBe(!1)}),it("is false when there is no current route",()=>{const e=new r["default"]({});jest.spyOn(e,"currentRoute").mockReturnValue(void 0),expect(e.hasProjectScopedUrlQueryParam).toBe(!1)})}),describe("groupByProject",()=>{it("is undefined when the secret is not project scoped",()=>{const e=new r["default"]({metadata:{labels:{}}},{rootGetters:{isRancher:!0}});expect(e.groupByProject).toBeUndefined()}),it("renders a translated group label using the project display name when project scoped",()=>{const e={nameDisplay:"My Project"},t=jest.fn().mockImplementation((e,t)=>`${e}:${t.name}`),n=new r["default"]({metadata:{labels:{[a.Qw]:"p-project",[a.Bt]:"c-cluster"}}},{rootGetters:{isRancher:!0,"i18n/t":t,[`${l.e.MANAGEMENT}/byId`]:()=>e}});expect(n.groupByProject).toBe("resourceTable.groupLabel.project:My Project")})}),describe("fullDetailPageOverride",()=>{it("is always true",()=>{const e=new r["default"]({});expect(e.fullDetailPageOverride).toBe(!0)})}),describe("details",()=>{const e={getters:{schemaFor:()=>({id:"secret"})},rootGetters:{"type-map/labelFor":()=>"Secret","i18n/t":e=>e,"i18n/withFallback":(e,t,n)=>n}};it("includes the raw secret type (not the kind) by default",()=>{const t=new r["default"]({_type:i.J.OPAQUE,metadata:{}},e);expect(t.details).toStrictEqual([{label:"secret.type",content:"Opaque"}])}),it("shows the raw secret type, matching the list column, rather than the friendly label",()=>{const t=new r["default"]({_type:i.J.DOCKER_JSON,metadata:{}},e),n=t.details.find(e=>"secret.type"===e.label);expect(null===n||void 0===n?void 0:n.content).toBe("kubernetes.io/dockerconfigjson")}),it("includes a Service Account link for service account secrets",()=>{const t=new r["default"]({_type:i.J.SERVICE_ACCT,metadata:{namespace:"default",annotations:{"kubernetes.io/service-account.name":"my-sa"}}},e),n=t.details.find(e=>"Service Account"===e.label);expect(n).toStrictEqual({label:"Service Account",formatter:"LinkName",formatterOpts:{value:"my-sa",type:o.Sg,namespace:"default"},content:"my-sa"})}),it("includes cn, issuer and expiry for certificate secrets",()=>{const t=new r["default"]({_type:i.J.TLS,data:{"tls.crt":(0,u.KA)(d)},metadata:{}},e),n=t.details.map(e=>e.label);expect(n).toStrictEqual(["secret.type","secret.certificate.cn","secret.certificate.issuer","Expires"])})})})},66888:function(e,t,n){"use strict";n.r(t);var r=n(45858),i=n(96730);describe("class SteveSchema",()=>{describe("schema diet",()=>{it("schema Definitions",async()=>{const e="cluster",t="steveTest";r["default"].reset(e);const n={id:t,metadata:{name:t},resourceFields:null,links:{self:`/v1/schemas/${t}`}},o={type:t,resourceFields:{a:{},b:{}}},a={a:{type:"a"},b:{type:"b"}},s=new r["default"](n,{dispatch:jest.fn().mockImplementation((e,n)=>(expect(e).toBe("request"),expect(n.type).toBe("schemaDefinition"),expect(n.url).toBe(`/v1/schemaDefinitions/${t}`),{definitionType:t,definitions:{[t]:o,...a}})),state:{config:{namespace:e}}});expect(s.schemaDefinition).toBeNull(),expect(s.schemaDefinitions).toBeNull(),expect(s.requiresResourceFields).toBeTruthy(),expect(s.hasResourceFields).toBeFalsy(),await s.fetchResourceFields(),expect(s.schemaDefinition).toStrictEqual(o),expect(s.schemaDefinitions).toStrictEqual(a),expect(s.requiresResourceFields).toBeTruthy(),expect(s.hasResourceFields).toBeTruthy(),(0,i.HC)(s,{...n}),expect(s.schemaDefinition).toStrictEqual(o),expect(s.schemaDefinitions).toStrictEqual(a),expect(s.requiresResourceFields).toBeTruthy(),expect(s.hasResourceFields).toBeTruthy()})})})},77107:function(e,t,n){"use strict";n.r(t);var r=n(63809);describe("class StorageClass",()=>{describe("checking if provisionerDisplay",()=>{it.each([["kubernetes.io/azure-disk",!0],["kubernetes.io/portworx-volume",!0],["rancher.io/local-path",!1],["some-random-string-as-provisioner",!1]])("should NOT show a suffix IF they are built-in (on the PROVISIONER_OPTIONS list)",(e,t)=>{const n=new r["default"]({metadata:{},spec:{},provisioner:e});jest.spyOn(n,"$rootGetters","get").mockReturnValue({"i18n/t":jest.fn()}),expect(!!r.PROVISIONER_OPTIONS.find(t=>t.value===e)).toBe(t)})})})},87819:function(e,t,n){"use strict";n.r(t);var r=n(2505),i=n(35664);const o={getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":jest.fn()}};describe("class: WorkloadService containers/initContainers getters",()=>{it("returns native pod containers and does not throw when initContainers is absent",()=>{const e=new r["default"]({type:"pod",metadata:{name:"p",namespace:"default"},spec:{containers:[{name:"container-0",image:"nginx"}]}},o);expect(e.containers).toHaveLength(1),expect(e.containers[0].name).toBe("container-0"),expect(()=>e.initContainers).not.toThrow(),expect(e.initContainers).toBeUndefined()}),it("still reads workload containers nested under spec.template.spec",()=>{const e=new r["default"]({type:i.oU.DEPLOYMENT,metadata:{name:"d",namespace:"default"},spec:{template:{spec:{containers:[{name:"c0"}],initContainers:[{name:"i0"}]}}}},o);expect(e.containers[0].name).toBe("c0"),expect(e.initContainers[0].name).toBe("i0")})})},91624:function(e,t,n){"use strict";var r=n(70775);const i="dsaf",o={type:i,__rehydrate:"whatever",__clone:"whatever"},a="asdasd",s={...o,type:a,__clone:"whatever",metadata:{clusterName:"whatever",creationTimestamp:"whatever",deletionGracePeriodSeconds:"whatever",deletionTimestamp:"whatever",fields:"whatever",finalizers:"whatever",generateName:"whatever",generation:"whatever",initializers:"whatever",managedFields:"whatever",ownerReferences:"whatever",relationships:"whatever",selfLink:"whatever",state:"whatever",uid:"whatever",resourceVersion:"whatever"},spec:{versions:{schema:"whatever"}},links:"whatever",status:"whatever",stringData:"whatever"};var l=n(35664),c=n(87784),u=n(99611),d=n(2841),h=n(76006),p=n(4364);describe("class: Workload",()=>{describe("given custom workload keys",()=>{const e="image",t={image:e,__active:"whatever",active:"whatever",_init:"whatever",error:"whatever"},n={...s,type:"123abv",__rehydrate:"whatever",__clone:"whatever",spec:{template:{spec:{containers:[t],initContainers:[t]}}}};n.metadata.name="abc",it("should keep internal keys",()=>{const e=new r["default"](n,{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":jest.fn()}});expect({...e}).toStrictEqual(n)}),describe("method: save",()=>{it("should remove all the internal keys",async()=>{const t=jest.fn(),i=new r["default"](n,{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:t,rootGetters:{"i18n/t":jest.fn(),"i18n/exists":()=>!0}}),o={metadata:{name:"abc",fields:"whatever",resourceVersion:"whatever",clusterName:"whatever",deletionGracePeriodSeconds:"whatever",generateName:"whatever",ownerReferences:"whatever"},spec:{template:{spec:{containers:[{image:e}],initContainers:[{image:e}]}}}};await i.save();const a={data:o,headers:{accept:"application/json","content-type":"application/json"},method:"post",url:void 0};expect(t).toHaveBeenCalledWith("request",{opt:a,type:n.type}),expect({...i}).toStrictEqual(n)})})}),describe.each([["scaleUp",2,3],["scaleDown",2,1]])("method: %s",(e,t,n)=>{const i=e=>{const n=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test-workload",namespace:"default"},spec:{replicas:t}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e}});return n.save=e,n},o=(e,t)=>()=>(e.spec.replicas=t,Promise.reject(Object.assign(new Error("Conflict"),{_status:409})));it("should show the new replica count before the save completes",()=>{const t=i(jest.fn().mockReturnValue(new Promise(()=>{})));t[e](),expect(t.spec.replicas).toStrictEqual(n)}),it("should go back to the previous replica count when the save fails",async()=>{const n=i(jest.fn().mockRejectedValue(new Error("Scale failed")));await n[e]().catch(()=>{}),expect(n.spec.replicas).toStrictEqual(t)}),it("should reject when the save fails",async()=>{const t=new Error("Scale failed"),n=i(jest.fn().mockRejectedValue(t));await expect(n[e]()).rejects.toStrictEqual(t)}),it("should keep the new replica count when the save after a conflict succeeds",async()=>{const r=jest.fn(),a=i(r);r.mockImplementationOnce(o(a,t)).mockResolvedValue(void 0),await a[e](),expect(a.spec.replicas).toStrictEqual(n)}),it("should only save twice when it keeps conflicting",async()=>{const n=jest.fn(),r=i(n);n.mockImplementation(o(r,t)),await r[e]().catch(()=>{}),expect(n).toHaveBeenCalledTimes(2)}),it("should not save again when the conflict changed the replica count",async()=>{const t=jest.fn(),n=i(t);t.mockImplementationOnce(o(n,7)).mockResolvedValue(void 0),await n[e]().catch(()=>{}),expect(t).toHaveBeenCalledTimes(1)}),it("should keep the reloaded replica count when the conflict changed it",async()=>{const t=jest.fn(),n=i(t);t.mockImplementationOnce(o(n,7)).mockResolvedValue(void 0),await n[e]().catch(()=>{}),expect(n.spec.replicas).toStrictEqual(7)})}),describe("method: scale",()=>{it("should call scaleUp when isUp is true",async()=>{const e=jest.fn().mockResolvedValue(void 0),t=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default"},spec:{replicas:1}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":jest.fn()}});t.scaleUp=e,await t.scale(!0),expect(e).toHaveBeenCalledWith()}),it("should call scaleDown when isUp is false",async()=>{const e=jest.fn().mockResolvedValue(void 0),t=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default"},spec:{replicas:2}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":jest.fn()}});t.scaleDown=e,await t.scale(!1),expect(e).toHaveBeenCalledWith()}),it("should dispatch growl error on failure",async()=>{const e=jest.fn(),t=jest.fn().mockRejectedValue(new Error("Scale failed")),n=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test-workload",namespace:"default"},spec:{replicas:1}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:e,rootGetters:{"i18n/t":e=>e}});n.scaleUp=t,await n.scale(!0),expect(e).toHaveBeenCalledWith("growl/fromError",expect.objectContaining({title:expect.stringContaining("workload.list.errorCannotScale"),err:expect.any(Error)}),{root:!0})})}),describe("getter: relatedServices",()=>{it("should return services that match workload pod template labels",()=>{const e={metadata:{name:"my-service",namespace:"default"},spec:{selector:{app:"my-app"}}},t=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default"},spec:{template:{metadata:{labels:{app:"my-app"}}}}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":jest.fn(),"cluster/all":t=>t===l.YV?[e]:[]}}),n=t.relatedServices;expect(n).toContain(e)}),it("should not return services from different namespace",()=>{const e={metadata:{name:"my-service",namespace:"other-namespace"},spec:{selector:{app:"my-app"}}},t=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default"},spec:{template:{metadata:{labels:{app:"my-app"}}}}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":jest.fn(),"cluster/all":t=>t===l.YV?[e]:[]}}),n=t.relatedServices;expect(n).toHaveLength(0)}),it("should not return services with non-matching selectors",()=>{const e={metadata:{name:"my-service",namespace:"default"},spec:{selector:{app:"different-app"}}},t=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default"},spec:{template:{metadata:{labels:{app:"my-app"}}}}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":jest.fn(),"cluster/all":t=>t===l.YV?[e]:[]}}),n=t.relatedServices;expect(n).toHaveLength(0)}),it("should return empty array when pod template has no labels",()=>{const e={metadata:{name:"my-service",namespace:"default"},spec:{selector:{app:"my-app"}}},t=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default"},spec:{template:{metadata:{}}}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":jest.fn(),"cluster/all":t=>t===l.YV?[e]:[]}}),n=t.relatedServices;expect(n).toHaveLength(0)})}),describe("getter: podsCard",()=>{const e={metadata:{name:"pod-1",namespace:"default"}};it("should return card for Deployment type",()=>{const t=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default"},spec:{}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e}});Object.defineProperty(t,"pods",{get:()=>[e]}),Object.defineProperty(t,"canUpdate",{get:()=>!0});const n=t.podsCard;expect(n).not.toBeNull(),expect(null===n||void 0===n?void 0:n.props.title).toBe("component.resource.detail.card.podsCard.title"),expect(null===n||void 0===n?void 0:n.props.showScaling).toBe(!0),expect(null===n||void 0===n?void 0:n.props.noResourcesMessage).toBe("component.resource.detail.card.podsCard.noPods")}),it("should scale by spec.replicas rather than the number of matching pods",()=>{var t;const n=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default"},spec:{replicas:2}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e}});Object.defineProperty(n,"pods",{get:()=>[e,e,e,e]}),Object.defineProperty(n,"canUpdate",{get:()=>!0}),expect(null===(t=n.podsCard)||void 0===t?void 0:t.props.scaleValue).toStrictEqual(2)}),it("should return the same component each time so the card is not remounted",()=>{var t,n;const i=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default"},spec:{replicas:2}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e}});Object.defineProperty(i,"pods",{get:()=>[e]}),Object.defineProperty(i,"canUpdate",{get:()=>!0}),expect(null===(t=i.podsCard)||void 0===t?void 0:t.component).toBe(null===(n=i.podsCard)||void 0===n?void 0:n.component)}),it("should return card for DaemonSet type without scaling",()=>{const t=new r["default"]({type:l.oU.DAEMON_SET,metadata:{name:"test",namespace:"default"},spec:{}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e}});Object.defineProperty(t,"pods",{get:()=>[e]}),Object.defineProperty(t,"canUpdate",{get:()=>!0});const n=t.podsCard;expect(n).not.toBeNull(),expect(null===n||void 0===n?void 0:n.props.showScaling).toBe(!1)}),it("should return null for unsupported types like CronJob",()=>{const e=new r["default"]({type:l.oU.CRON_JOB,metadata:{name:"test",namespace:"default"},spec:{}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e}}),t=e.podsCard;expect(t).toBeNull()}),it("should return card when pods array is empty (scaled to 0)",()=>{const e=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default"},spec:{}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e}});Object.defineProperty(e,"pods",{get:()=>[]}),Object.defineProperty(e,"canUpdate",{get:()=>!0});const t=e.podsCard;expect(t).not.toBeNull(),expect(null===t||void 0===t?void 0:t.props.resources).toStrictEqual([]),expect(null===t||void 0===t?void 0:t.props.noResourcesMessage).toBe("component.resource.detail.card.podsCard.noPods")}),it("should return null for non-scalable type with empty pods",()=>{const e=new r["default"]({type:l.oU.DAEMON_SET,metadata:{name:"test",namespace:"default"},spec:{}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e}});Object.defineProperty(e,"pods",{get:()=>[]}),Object.defineProperty(e,"canUpdate",{get:()=>!0});const t=e.podsCard;expect(t).toBeNull()}),it("should return null when pods is undefined",()=>{const e=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default"},spec:{}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e}});Object.defineProperty(e,"pods",{get:()=>{}});const t=e.podsCard;expect(t).toBeNull()}),it("should hide scaling when canUpdate is false",()=>{const t=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default"},spec:{}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e}});Object.defineProperty(t,"pods",{get:()=>[e]}),Object.defineProperty(t,"canUpdate",{get:()=>!1});const n=t.podsCard;expect(null===n||void 0===n?void 0:n.props.showScaling).toBe(!1)})}),describe("getter: jobsCard",()=>{const e={metadata:{name:"job-1",namespace:"default"}};it("should return card for CronJob type",()=>{const t=new r["default"]({type:l.oU.CRON_JOB,metadata:{name:"test",namespace:"default"},spec:{}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e}});Object.defineProperty(t,"jobs",{get:()=>[e]});const n=t.jobsCard;expect(n).not.toBeNull(),expect(null===n||void 0===n?void 0:n.props.title).toBe("component.resource.detail.card.jobsCard.title"),expect(null===n||void 0===n?void 0:n.props.showScaling).toBe(!1)}),it("should return null for non-CronJob types",()=>{const e=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default"},spec:{}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e}}),t=e.jobsCard;expect(t).toBeNull()}),it("should return null when jobs array is empty",()=>{const e=new r["default"]({type:l.oU.CRON_JOB,metadata:{name:"test",namespace:"default"},spec:{}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e}});Object.defineProperty(e,"jobs",{get:()=>[]});const t=e.jobsCard;expect(t).toBeNull()})}),describe("getter: cards",()=>{const e={metadata:{name:"pod-1",namespace:"default"}},t={metadata:{name:"job-1",namespace:"default"}};it("should include podsCard for Deployment",()=>{const t=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default"},spec:{},status:{}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e,"cluster/schemaFor":()=>{},"cluster/all":()=>[]}});Object.defineProperty(t,"pods",{get:()=>[e]}),Object.defineProperty(t,"canUpdate",{get:()=>!0});const n=t.cards,i=n.filter(e=>null!==e);expect(i.length).toBeGreaterThanOrEqual(1),expect(i[0].props.title).toBe("component.resource.detail.card.podsCard.title")}),it("should include jobsCard for CronJob",()=>{const e=new r["default"]({type:l.oU.CRON_JOB,metadata:{name:"test",namespace:"default"},spec:{},status:{}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e,"cluster/schemaFor":()=>{},"cluster/all":()=>[]}});Object.defineProperty(e,"jobs",{get:()=>[t]});const n=e.cards,i=n.filter(e=>null!==e),o=i.find(e=>"component.resource.detail.card.jobsCard.title"===e.props.title);expect(o).toBeDefined()})}),describe("getter: matchingIngresses",()=>{const e=(e,t,n=[])=>{const i=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default"},spec:{template:{metadata:{labels:{app:"my-app"}}}}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":jest.fn(),"cluster/all":n=>n===l.YV?e:n===l.kf?t:[]}});return Object.defineProperty(i,"pods",{get:()=>n}),i};it("should return empty array when no related services",()=>{const t=e([],[{metadata:{namespace:"default"},spec:{rules:[{http:{paths:[{backend:{service:{name:"svc1"}}}]}}]}}]);expect(t.matchingIngresses).toStrictEqual([])}),it("should find matching ingresses",()=>{const t={metadata:{name:"pod-1",namespace:"default",labels:{app:"my-app"}}},n={metadata:{name:"svc1",namespace:"default"},spec:{selector:{app:"my-app"}}},r={metadata:{namespace:"default"},spec:{rules:[{http:{paths:[{backend:{service:{name:"svc1"}}}]}}]}},i=e([n],[r],[t]);expect(i.matchingIngresses).toHaveLength(1),expect(i.matchingIngresses[0]).toStrictEqual(r)}),it("should not match ingresses from other namespaces",()=>{const t={metadata:{name:"pod-1",namespace:"default",labels:{app:"my-app"}}},n={metadata:{name:"svc1",namespace:"default"},spec:{selector:{app:"my-app"}}},r={metadata:{namespace:"other"},spec:{rules:[{http:{paths:[{backend:{service:{name:"svc1"}}}]}}]}},i=e([n],[r],[t]);expect(i.matchingIngresses).toHaveLength(0)}),it("should not match ingresses pointing to other services",()=>{const t={metadata:{name:"pod-1",namespace:"default",labels:{app:"my-app"}}},n={metadata:{name:"svc1",namespace:"default"},spec:{selector:{app:"my-app"}}},r={metadata:{namespace:"default"},spec:{rules:[{http:{paths:[{backend:{service:{name:"svc2"}}}]}}]}},i=e([n],[r],[t]);expect(i.matchingIngresses).toHaveLength(0)}),it("should handle ingresses with no rules",()=>{const t={metadata:{name:"pod-1",namespace:"default",labels:{app:"my-app"}}},n={metadata:{name:"svc1",namespace:"default"},spec:{selector:{app:"my-app"}}},r={metadata:{namespace:"default"},spec:{}},i=e([n],[r],[t]);expect(i.matchingIngresses).toHaveLength(0)}),it("should handle ingress rules with no paths",()=>{const t={metadata:{name:"pod-1",namespace:"default",labels:{app:"my-app"}}},n={metadata:{name:"svc1",namespace:"default"},spec:{selector:{app:"my-app"}}},r={metadata:{namespace:"default"},spec:{rules:[{http:{}}]}},i=e([n],[r],[t]);expect(i.matchingIngresses).toHaveLength(0)}),it("should handle ingress paths with no backend service",()=>{const t={metadata:{name:"pod-1",namespace:"default",labels:{app:"my-app"}}},n={metadata:{name:"svc1",namespace:"default"},spec:{selector:{app:"my-app"}}},r={metadata:{namespace:"default"},spec:{rules:[{http:{paths:[{backend:{}}]}}]}},i=e([n],[r],[t]);expect(i.matchingIngresses).toHaveLength(0)}),it("should find one of many ingresses",()=>{const t={metadata:{name:"pod-1",namespace:"default",labels:{app:"my-app"}}},n={metadata:{name:"svc1",namespace:"default"},spec:{selector:{app:"my-app"}}},r=[{metadata:{namespace:"other"},spec:{rules:[{http:{paths:[{backend:{service:{name:"svc1"}}}]}}]}},{metadata:{namespace:"default"},spec:{rules:[{http:{paths:[{backend:{service:{name:"svc1"}}}]}}]}},{metadata:{namespace:"default"},spec:{rules:[{http:{paths:[{backend:{service:{name:"svc2"}}}]}}]}}],i=e([n],r,[t]);expect(i.matchingIngresses).toHaveLength(1),expect(i.matchingIngresses[0]).toStrictEqual(r[1])})}),describe("getter: resourcesCardRows",()=>{it("should include services row when related services exist",()=>{const e={metadata:{name:"pod-1",namespace:"default",labels:{app:"my-app"}}},t={metadata:{name:"svc1",namespace:"default"},spec:{selector:{app:"my-app"}},stateDisplay:"Active",stateSimpleColor:"success"},n=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default"},spec:{template:{metadata:{labels:{app:"my-app"}}}}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e,"cluster/schemaFor":()=>{},"cluster/all":e=>e===l.YV?[t]:[]}});Object.defineProperty(n,"pods",{get:()=>[e]});const i=n.resourcesCardRows,o=i.find(e=>"component.resource.detail.card.resourcesCard.rows.services"===e.label);expect(o).toBeDefined()}),it("should include ingresses row when matching ingresses exist",()=>{const e={metadata:{name:"pod-1",namespace:"default",labels:{app:"my-app"}}},t={metadata:{name:"svc1",namespace:"default"},spec:{selector:{app:"my-app"}},stateDisplay:"Active",stateSimpleColor:"success"},n={metadata:{namespace:"default"},spec:{rules:[{http:{paths:[{backend:{service:{name:"svc1"}}}]}}]},stateDisplay:"Active",stateSimpleColor:"success"},i=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default"},spec:{template:{metadata:{labels:{app:"my-app"}}}}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e,"cluster/schemaFor":()=>{},"cluster/all":e=>e===l.YV?[t]:e===l.kf?[n]:[]}});Object.defineProperty(i,"pods",{get:()=>[e]});const o=i.resourcesCardRows,a=o.find(e=>"component.resource.detail.card.resourcesCard.rows.ingresses"===e.label);expect(a).toBeDefined(),expect(null===a||void 0===a?void 0:a.to).toBe("#ingresses")}),it("should order services before ingresses",()=>{const e={metadata:{name:"pod-1",namespace:"default",labels:{app:"my-app"}}},t={metadata:{name:"svc1",namespace:"default"},spec:{selector:{app:"my-app"}},stateDisplay:"Active",stateSimpleColor:"success"},n={metadata:{namespace:"default"},spec:{rules:[{http:{paths:[{backend:{service:{name:"svc1"}}}]}}]},stateDisplay:"Active",stateSimpleColor:"success"},i=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default"},spec:{template:{metadata:{labels:{app:"my-app"}}}}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e,"cluster/schemaFor":()=>{},"cluster/all":e=>e===l.YV?[t]:e===l.kf?[n]:[]}});Object.defineProperty(i,"pods",{get:()=>[e]});const o=i.resourcesCardRows;expect(o[0].label).toBe("component.resource.detail.card.resourcesCard.rows.services"),expect(o[1].label).toBe("component.resource.detail.card.resourcesCard.rows.ingresses")}),it("should not include ingresses row when no matching ingresses",()=>{const e={metadata:{name:"pod-1",namespace:"default",labels:{app:"my-app"}}},t={metadata:{name:"svc1",namespace:"default"},spec:{selector:{app:"my-app"}},stateDisplay:"Active",stateSimpleColor:"success"},n=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default"},spec:{template:{metadata:{labels:{app:"my-app"}}}}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e,"cluster/schemaFor":()=>{},"cluster/all":e=>e===l.YV?[t]:[]}});Object.defineProperty(n,"pods",{get:()=>[e]});const i=n.resourcesCardRows,o=i.find(e=>"component.resource.detail.card.resourcesCard.rows.ingresses"===e.label);expect(o).toBeUndefined()})}),describe("getter: matchingHttpRoutes",()=>{const e={metadata:{name:"svc1",namespace:"default"},spec:{selector:{app:"my-app"}}},t=(e,t=[],n="default")=>new c["default"]({metadata:{name:"route1",namespace:n},spec:e},{rootGetters:{"cluster/schemaFor":()=>({}),"cluster/all":e=>e===l.Yq.GATEWAY?t:[]}}),n=(e,t,n=!0)=>new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default"},spec:{template:{metadata:{labels:{app:"my-app"}}}}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":jest.fn(),"cluster/schemaFor":()=>n?{}:void 0,"cluster/all":n=>n===l.YV?e:n===l.Yq.HTTP_ROUTE?t:[]}});it("should return an empty array when there are no related services",()=>{const e=t({rules:[{backendRefs:[{name:"svc1"}]}]});expect(n([],[e]).matchingHttpRoutes).toStrictEqual([])}),it("should return an empty array when no HTTPRoutes exist",()=>{expect(n([e],[]).matchingHttpRoutes).toStrictEqual([])}),it("should not ask the store for a type with no schema, on a cluster without the Gateway API",()=>{const e=jest.fn().mockReturnValue([]),t=new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default"},spec:{template:{metadata:{labels:{app:"my-app"}}}}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":jest.fn(),"cluster/schemaFor":()=>{},"cluster/all":e}});expect(t.matchingHttpRoutes).toStrictEqual([]),expect(e).not.toHaveBeenCalledWith(l.Yq.HTTP_ROUTE)}),it("should find the routes that send traffic to a related service",()=>{const r=t({rules:[{backendRefs:[{name:"svc1"}]}]}),i=t({rules:[{backendRefs:[{name:"svc2"}]}]});expect(n([e],[i,r]).matchingHttpRoutes).toStrictEqual([r])}),it("should not match a route whose backendRef points at another namespace",()=>{const r=t({rules:[{backendRefs:[{name:"svc1",namespace:"elsewhere"}]}]});expect(n([e],[r]).matchingHttpRoutes).toStrictEqual([])})}),describe("getters: publicEndpoints / gatewayEndpoints / detailEndpoints",()=>{const e={addresses:["172.18.0.3"],port:80,protocol:"HTTP",serviceName:"default:svc1"},t={metadata:{name:"svc1",namespace:"default"},spec:{selector:{app:"my-app"}}},n=new u["default"]({metadata:{name:"gw",namespace:"default"},spec:{listeners:[{name:"http",protocol:"HTTP",port:80}]},status:{}}),i=new c["default"]({metadata:{name:"route1",namespace:"default"},spec:{parentRefs:[{name:"gw"}],hostnames:["demo.example.com"],rules:[{matches:[{path:{value:"/shop"}}],backendRefs:[{name:"svc1"}]}]}},{rootGetters:{"cluster/schemaFor":()=>({}),"cluster/all":e=>e===l.Yq.GATEWAY?[n]:[]}}),o=(e,n=[])=>new r["default"]({type:l.oU.DEPLOYMENT,metadata:{name:"test",namespace:"default",annotations:e},spec:{template:{metadata:{labels:{app:"my-app"}}}}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":jest.fn(),"cluster/schemaFor":()=>({}),"cluster/all":e=>e===l.YV?[t]:e===l.Yq.HTTP_ROUTE?n:[]}});it("should parse the publicEndpoints annotation",()=>{const t=o({[d.bs]:JSON.stringify([e])});expect(t.publicEndpoints).toStrictEqual([e])}),it.each([["no annotations at all",void 0],["no publicEndpoints annotation",{other:"value"}],["a malformed annotation",{[d.bs]:"not json"}],["an annotation that is not an array",{[d.bs]:'{"a":1}'}]])("should return no public endpoints for %s",(e,t)=>{const n=jest.spyOn(p,"warn").mockImplementation(()=>{});expect(o(t).publicEndpoints).toStrictEqual([]),n.mockRestore()}),it("should resolve gateway endpoints through the matching routes",()=>{expect(o(void 0,[i]).gatewayEndpoints).toStrictEqual([{link:"http://demo.example.com/shop",linkDisplay:"http://demo.example.com/shop"}])});const a=(e,t)=>new c["default"]({metadata:{name:e,namespace:"default"},spec:{parentRefs:[{name:"gw"}],hostnames:["demo.example.com"],rules:[{matches:[{path:{value:t}}],backendRefs:[{name:"svc1"}]}]}},{rootGetters:{"cluster/schemaFor":()=>({}),"cluster/all":e=>e===l.Yq.GATEWAY?[n]:[]}});it("should show a link once when two routes send it to the workload",()=>{const e=[i,a("route2","/shop")];expect(o(void 0,e).gatewayEndpoints).toStrictEqual([{link:"http://demo.example.com/shop",linkDisplay:"http://demo.example.com/shop"}])}),it("should keep the links of every route when they differ",()=>{const e=[i,a("route2","/cart")];expect(o(void 0,e).gatewayEndpoints).toStrictEqual([{link:"http://demo.example.com/shop",linkDisplay:"http://demo.example.com/shop"},{link:"http://demo.example.com/cart",linkDisplay:"http://demo.example.com/cart"}])}),it("should combine published endpoints with gateway endpoints",()=>{const t=o({[d.bs]:JSON.stringify([e])},[i]);expect(t.detailEndpoints).toStrictEqual([e,{link:"http://demo.example.com/shop",linkDisplay:"http://demo.example.com/shop"}])}),it("should be undefined when the workload is exposed by nothing, so the masthead row stays hidden",()=>{expect(o(void 0).detailEndpoints).toBeUndefined()})}),describe("getter: restartCount",()=>{const e=(e,t=l.oU.DEPLOYMENT)=>{const n=new r["default"]({type:t,metadata:{name:"test",namespace:"default"}},{getters:{schemaFor:()=>({linkFor:jest.fn()})},dispatch:jest.fn(),rootGetters:{"i18n/t":e=>e,"cluster/schemaFor":()=>{}}});return Object.defineProperty(n,"pods",{get:()=>e}),n},t=(e,t)=>new h["default"]({metadata:{name:"test-abcde",namespace:"default"},spec:e,status:t},{getters:{},dispatch:jest.fn(),rootGetters:{}});it.each([["no pods",[],0],["pods that never restarted",[{totalRestartCount:0},{totalRestartCount:0}],0],["pods that restarted",[{totalRestartCount:17},{totalRestartCount:16},{totalRestartCount:18}],51],["a pod without a restart count",[{totalRestartCount:2},{}],2],["a very large number of restarts",[{totalRestartCount:Number.MAX_SAFE_INTEGER-1},{totalRestartCount:1}],Number.MAX_SAFE_INTEGER]])("should add up the restarts of %s",(t,n,r)=>{expect(e(n).restartCount).toStrictEqual(r)}),it.each([l.oU.DEPLOYMENT,l.oU.DAEMON_SET,l.oU.STATEFUL_SET,l.oU.REPLICA_SET,l.oU.JOB,l.oU.CRON_JOB,l.oU.REPLICATION_CONTROLLER])("should count the restarts of sidecar containers like kubectl and the Pods list, for a %s",n=>{const r=t({initContainers:[{name:"sidecar",restartPolicy:"Always"}],containers:[{name:"app"}]},{conditions:[{type:"Initialized",status:"True"}],initContainerStatuses:[{name:"sidecar",restartCount:2,started:!0,ready:!0}],containerStatuses:[{name:"app",restartCount:3,ready:!0,state:{running:{}}}]});expect(e([r,r],n).restartCount).toStrictEqual(10)}),it("should show the restarts in the masthead",()=>{const t=e([{totalRestartCount:4}]).details.find(e=>"resourceDetail.masthead.restartCount"===e.label);expect(null===t||void 0===t?void 0:t.content).toStrictEqual(4)})}),describe("getter: ready",()=>{const e=(e,t,n)=>new r["default"]({type:e,metadata:{name:"test",namespace:"default"},spec:t,status:n},{getters:{},dispatch:jest.fn(),rootGetters:{}});it.each([[l.oU.DEPLOYMENT,{replicas:3},{replicas:3,unavailableReplicas:1},"2/3"],[l.oU.STATEFUL_SET,{replicas:3},{replicas:3},"3/3"],[l.oU.REPLICATION_CONTROLLER,{replicas:2},{replicas:2,unavailableReplicas:2},"0/2"],[l.oU.DAEMON_SET,{},{replicas:4,unavailableReplicas:1},3],[l.oU.DEPLOYMENT,{replicas:3},void 0,"0/3"]])("should count the replicas that are not unavailable for a %s",(t,n,r,i)=>{expect(e(t,n,r).ready).toStrictEqual(i)})})})},6856:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(35664),i=n(39975);class o extends i.A{get _availableActions(){const e=super._availableActions;return e.filter((e,t)=>1!==t&&!["goToEdit","goToEditYaml","cloneYaml","download"].includes(e.action))}get expiresAt(){var e,t;const n=null===(e=this.spec)||void 0===e?void 0:e.ttl,r=null===(t=this.metadata)||void 0===t?void 0:t.creationTimestamp;if(!n||!r)return null;const i=new Date(r),o=new Date(i.getTime()+1e3*n);return o.toISOString()}get referencedClusters(){var e;const t=(null===(e=this.spec)||void 0===e?void 0:e.clusters)||[];return t.map(e=>{const t=this.$rootGetters["management/byId"](r.Mc.CLUSTER,e),n=null===t||void 0===t?void 0:t.provCluster;return{label:(null===t||void 0===t?void 0:t.nameDisplay)||this.t('"ext.cattle.io.kubeconfig".deleted',{name:e}),location:(null===n||void 0===n?void 0:n.detailLocation)||(null===t||void 0===t?void 0:t.detailLocation)||null}})}get sortedReferencedClusters(){return this.referencedClusters.slice().sort((e,t)=>{const n=null!==e.location,r=null!==t.location;if(n&&!r)return-1;if(!n&&r)return 1;const i=e.label.toLowerCase(),o=t.label.toLowerCase();return i.localeCompare(o,void 0,{numeric:!0})})}get referencedClustersSortable(){return this.sortedReferencedClusters.map(e=>e.label.toLowerCase()).join(",")}}},2036:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return s}});var r=n(39975),i=n(76978);const o=["gitRepo","helmOp"];function a(e){return void 0===e||null===e||""===e||Array.isArray(e)&&0===e.length}class s extends r.A{applyDefaults(){const e=this.metadata||{};e.namespace=e.namespace||this.$rootGetters["workspace"],(0,i.hZ)(this,"metadata",e)}cleanForSave(e,t){const n=super.cleanForSave(e,t);return a(n.allowedServiceAccounts)&&delete n.allowedServiceAccounts,o.forEach(e=>{const t=n[e];t&&(Object.keys(t).forEach(e=>{a(t[e])&&delete t[e]}),Object.keys(t).length||delete n[e])}),n}}},45858:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return c}});var r=n(35664),i=n(2334),o=n(23330),a=n(4364);const s={},l=({schema:e,verb:t})=>!!e.hasLink("collection")&&!!e.attributes?.verbs?.find(e=>e.toLowerCase()===t);class c extends i["default"]{static reset(e){delete s[e]}constructor(e,t,n,r){super(e,t,n,r),s[this.store]||(s[this.store]={ids:{},definitions:{}}),this.requiresResourceFields=null===this._resourceFields}get hasResourceFields(){return this.requiresResourceFields?!!this.schemaDefinition?.resourceFields:!!this._resourceFields}get resourceFields(){if(this.requiresResourceFields){if(!this.schemaDefinitionsIds)throw new Error(`Cannot find resourceFields for Schema ${this.id} (schemaDefinitions have not been fetched) `);if(!this.schemaDefinition)throw new Error(`No schemaDefinition for ${this.id} found (not in schemaDefinition response) `);return this.schemaDefinition.resourceFields}return this._resourceFields}set resourceFields(e){this._resourceFields=e,this.requiresResourceFields=null===this._resourceFields}async fetchResourceFields(e=0){if(!this.requiresResourceFields)return;if(this.schemaDefinition)return this.schemaDefinition;const t=this.schemaDefinitionUrl;if(!t)return void a.warn(`Unable to fetch schema definitions for ${this.id} (failed to find url of schema definition)`);if(e>=4)return void a.warn(`Unable to fetch schema definitions for ${this.id} (too many failed requests)`);let n;try{n=await this.$dispatch("request",{type:r.m4.SCHEMA_DEFINITION,url:t})}catch(i){return 500===i?._status||503===i?._status?(await(0,o.u)(2e3),this.fetchResourceFields(++e)):void a.warn(`Unable to fetch schema definitions for ${this.id}`,i)}return this.cacheSchemaDefinitionResponse(n),this.schemaDefinition}cacheSchemaDefinitionResponse(e){const{[e.definitionType]:t,...n}=e.definitions,r=this.store;s[r].ids[this.id]={self:t.type,others:Object.keys(n)},Object.entries(e.definitions).forEach(([e,t])=>{s[r].definitions[e]=t})}get schemaDefinition(){return this.schemaDefinitionsIds?s[this.store].definitions[this.schemaDefinitionsIds.self]:null}get schemaDefinitions(){return this.schemaDefinitionsIds?this.schemaDefinitionsIds.others.reduce((e,t)=>(e[t]=s[this.store].definitions[t],e),{}):null}get schemaDefinitionUrl(){return this.links?.self?.replace("/schemas/","/schemaDefinitions/")}get canGet(){return l({schema:this.schema,verb:"get"})}get canList(){return l({schema:this.schema,verb:"list"})}get schema(){return this}get store(){return this.$ctx.state?.config?.namespace}get schemaDefinitionsIds(){return s[this.store]?.ids[this.id]}}},81565:function(e,t,n){"use strict";var r=n(18110),i=n(34765);class o{isApplicable(e){return Array.isArray(e.namespaced)}isEnabled(e){var t;const n=e["currentProduct"];if("cluster"!==(null===n||void 0===n?void 0:n.inStore))return!1;if(null===n||void 0===n?void 0:n.showWorkspaceSwitcher)return!1;const r=(0,i.fD)(e);return!!(null===(t=r.forceNsFilterV2)||void 0===t?void 0:t.enabled)}checkAndCreateParam(e){return this.isApplicable(e)?this.createParam(e.namespaced):""}createParam(e){if(!e||!e.length)return"";const t=e.reduce((e,t)=>{const n=t.replace(r.os,"").replace(r.tA,"");return n.startsWith("-")?e.exclude.push(t.substring(1,t.length)):e.include.push(n),e},{include:[],exclude:[]});let n="";return t.include.length&&(n=`${o.param}=${t.include.join(",")}`),t.exclude.length&&(n=`${o.param}!=${t.exclude.join(",")}`),n}}o.param="projectsornamespaces",t.A=new o},22915:function(e,t,n){"use strict";n.d(t,{C:function(){return s}});var r=n(76978),i=n(20246),o=n.n(i);const a=["uid","generation","resourceVersion","creationTimestamp","managedFields"];function s(e,t){if(!e)return;const{rootKeys:n=["id","links","type","actions"],metadataKeys:i=["fields","relationships","state"],conditionKeys:s=["error","transitioning"],editing:l=!1}=t||{},c=o().load(e);return(0,r.cX)(c,n),(0,r.cX)(c?.metadata,l?[...i,...a]:i),(c?.status?.conditions||[]).forEach(e=>(0,r.cX)(e,s)),o().dump(c)}},20926:function(e,t,n){"use strict";n.d(t,{J:function(){return r}});class r{constructor(e){this.revision=e,this.asNumber=Number(e),this.isNumber=!Number.isNaN(this.asNumber)}isNewerThan(e){return r.areAllNumbers([this,e])&&this.asNumber>e.asNumber}static areAllNumbers(e){return e.every(e=>e.isNumber)}}},82637:function(e,t,n){"use strict";n.d(t,{U:function(){return f}});var r=n(50025),i=n(18110),o=n(68851),a=n(35664),s=n(2841),l=n(15092),c=n(74302),u=n(11519),d=n(4364);class h{handlePrefAndSettingFilter(e){const{allNamespaces:t,showReservedRancherNamespaces:n,productHidesSystemNamespaces:r}=e;return t.reduce((e,t)=>{const i=!n&&t.isObscure,o=!!r&&t.isSystem;return(i||o)&&(e[t.name]=!1),e},{})}handleSystemOrUserFilter(e){const{allNamespaces:t,isAllSystem:n,isAllUser:r}=e,i=t.filter(e=>e.isSystem);return i.reduce((e,t)=>(n&&(e[t.name]=!0),r&&(e[t.name]=!1),e),{})}combineNsProjectFilterResults(e,t){const n={...e};return Object.entries(t).forEach(([e,t])=>{void 0===n[e]&&(n[e]=t)}),n}createFiltersFromNamespaceProjectFilterResult(e){const t=[],n=[];Object.entries(e).forEach(([e,r])=>{r?t.push(e):n.push(e)});const i=[];return t.length?i.push(new r.eY({fields:[{value:t.join(","),equality:r.D0.IN,field:"metadata.namespace"}]})):n.length&&i.push(new r.eY({fields:[{value:n.join(","),equality:r.D0.NOT_IN,field:"metadata.namespace"}]})),i}handleSelectionFilter(e,t){const n=[new r.B6({projectOrNamespace:e})];return t?{projectsOrNamespaces:n,filters:e.filter(e=>e.startsWith(i.tA)).map(e=>r.eY.createSingleField({field:"metadata.namespace",value:e.replace(i.tA,""),equals:!1}))}:{projectsOrNamespaces:n,filters:[]}}}class p extends h{convertArrayPath(e){return e.startsWith("metadata.fields.")?`metadata.fields[${e.substring(16)}]`:e}createSortForPagination(e){return this.convertArrayPath(e)}createParamsFromNsFilter({allNamespaces:e,selection:t,isAllNamespaces:n,isLocalCluster:r,showReservedRancherNamespaces:o,productHidesSystemNamespaces:a}){if(n&&o&&!a)return{projectsOrNamespaces:[],filters:[]};let s=[];const l=[];let c={};o&&!a||(c=this.combineNsProjectFilterResults(c,this.handlePrefAndSettingFilter({allNamespaces:e,showReservedRancherNamespaces:o,productHidesSystemNamespaces:a})));const u=t[0]===i.Rc,d=t[0]===i.bE;if(1===t.length&&(u||d))c=this.combineNsProjectFilterResults(c,this.handleSystemOrUserFilter({allNamespaces:e,isAllSystem:u,isAllUser:d})),l.push(...this.createFiltersFromNamespaceProjectFilterResult(c));else{l.push(...this.createFiltersFromNamespaceProjectFilterResult(c));const e=this.handleSelectionFilter(t,r);s=e.projectsOrNamespaces,l.push(...e.filters)}return{projectsOrNamespaces:s,filters:l}}createParamsForPagination({schema:e,opt:t}){var n,r;if(!t.pagination)return;const i=[],a=this.convertPaginationParams({schema:e,filters:t.pagination.projectsOrNamespaces});if(a&&i.push(a),t.pagination.page&&i.push(`page=${t.pagination.page}`),t.pagination.pageSize||0===t.pagination.pageSize?i.push(`pagesize=${t.pagination.pageSize}`):i.push(`pagesize=${l.A.defaultPageSize}`),null===(n=t.pagination.sort)||void 0===n?void 0:n.length){const n={checked:new Array,invalid:new Array},r=t.pagination.sort.map(t=>{const{field:r,reverse:i}=(0,c.cn)(t.field),o=i?!t.asc:t.asc;return this.validateField(n,e,r),`${o?"":"-"}${this.convertArrayPath(r)}`}).join(",");i.push(`sort=${r}`),n.invalid.length&&d.warn(`Pagination API does not support sorting '${(null===e||void 0===e?void 0:e.id)||t.url}' by the requested fields: ${(0,o.sb)(n.invalid).join(", ")}`)}if(null===(r=t.pagination.filters)||void 0===r?void 0:r.length){const n=this.convertPaginationParams({schema:e,filters:t.pagination.filters});n&&i.push(n)}if(t.pagination.labelSelector){const e=this.convertLabelSelectorPaginationParams({labelSelector:t.pagination.labelSelector});e&&i.push(e)}return t.includeAssociatedData&&i.push("includeAssociatedData=true"),i.join("&")}validateField(e,t,n){n&&(e.checked.includes(n)||(e.checked.push(n),t&&[p.VALID_FIELDS[""],p.VALID_FIELDS[t.id]].find(e=>null===e||void 0===e?void 0:e.find(e=>e.startsWith?!!n.startsWith(e.field)||void 0:n===e.field))||(null===t||void 0===t?void 0:t.attributes.columns.find(e=>e.field.replace("$.","").replace("[",".").replace("]","")===n))||e.invalid.push(n)))}convertPaginationParams({schema:e,filters:t=[]}){const n={checked:new Array,invalid:new Array},i=t.filter(e=>!!e.fields.length).map(t=>{const i=t.fields.map(t=>{if(t.field){if(this.validateField(n,e,t.field),t.exists)return t.field;const i=t.equality||r.Js.safeEquality(t);if(!i)throw new Error(`A pagination filter must contain an equality. ${JSON.stringify(t)}`);let o;if([r.D0.IN,r.D0.NOT_IN].includes(i))o=`(${t.value})`;else{const e="undefined"===typeof t.value||null===t.value?"":t.value,n=encodeURIComponent(e);o=p.VALID_FIELD_VALUE_REGEX.test(e)?n:`"${n.replaceAll("%22","")}"`}return`${this.convertArrayPath(t.field)}${i}${o}`}return t.value}).join(",");return`${t.param}${t.equals?"=":"!="}${i}`}),a=i.reduce((e,t)=>(e[t]=!0,e),{}),s=Object.keys(a).join("&");return n.invalid.length&&d.warn(`Pagination API does not support filtering '${(null===e||void 0===e?void 0:e.id)||"unknown"}' by the requested fields: ${(0,o.sb)(n.invalid).join(", ")}`),s}convertLabelSelectorPaginationParams({labelSelector:e}){const t=e.matchExpressions?[...e.matchExpressions]:[];e.matchLabels&&Object.entries(e.matchLabels).forEach(([e,n])=>{const r={key:e,values:[n],operator:"In"};t.push(r)});const n=t.reduce((e,t)=>{var n,r,i,o;const a=`metadata.labels[${t.key}]`;switch(t.operator){case"In":if(!(null===(n=t.values)||void 0===n?void 0:n.length))return d.error(`Skipping labelSelector to API filter param conversion for ${t.key}(IN) as no value was supplied`),e;e.push(`filter=${a} IN (${t.values.join(",")})`);break;case"NotIn":if(!(null===(r=t.values)||void 0===r?void 0:r.length))return d.error(`Skipping labelSelector to API filter param conversion for ${t.key}(NOTIN) as no value was supplied`),e;e.push(`filter=${a} NOTIN (${t.values.join(",")})`);break;case"Exists":if(null===(i=t.values)||void 0===i?void 0:i.length)return d.error(`Skipping labelSelector to API filter param conversion for ${t.key}(Exists) as no value was supplied`),e;e.push(`filter=${a}`);break;case"DoesNotExist":if(null===(o=t.values)||void 0===o?void 0:o.length)return d.error(`Skipping labelSelector to API filter param conversion for ${t.key}(DoesNotExist) as no value was supplied`),e;e.push(`filter=!${a}`);break;case"Gt":if("string"!==typeof t.values)return d.error(`Skipping labelSelector to API filter param conversion for ${t.key}(Gt) as no value was supplied`),e;e.push(`filter=${a} > (${t.values})`);break;case"Lt":if("string"!==typeof t.values)return d.error(`Skipping labelSelector to API filter param conversion for ${t.key}(Lt) as no value was supplied`),e;e.push(`filter=${a} < (${t.values})`);break}return e},[]);return n.join("&")}}p.VALID_FIELD_VALUE_REGEX=/^[\w.]+$/,p.VALID_FIELDS={"":[{field:"metadata.name"},{field:"metadata.namespace"},{field:"id"},{field:"metadata.state.name"},{field:"metadata.creationTimestamp"},{field:"metadata.labels",startsWith:!0},{field:`metadata.annotations[${s.tC}]`}],[a.NW]:[{field:"status.nodeInfo.kubeletVersion"},{field:"status.nodeInfo.operatingSystem"},{field:"spec.taints.key"},{field:"status.addresses.type"}],[a.Sm]:[{field:"spec.containers.image"},{field:"spec.nodeName"},{field:u.Nb},{field:u.AC}],[a.Mc.NODE]:[{field:"status.nodeName"}],[a.Mc.NODE_POOL]:[{field:"spec.clusterName"}],[a.Mc.NODE_TEMPLATE]:[{field:"spec.clusterName"}],[a.Mc.CLUSTER]:[{field:"spec.internal"},{field:"spec.displayName"},{field:"status.provider"},{field:"status.connected"},{field:"status.info.machineProvider"},{field:"status.driver"},{field:"status.provider"},{field:"status.info.kubernetesVersion"},{field:"spec.fleetWorkspaceName"},{field:"status.allocatable.cpuRaw"},{field:"status.allocatable.memoryRaw"},{field:"status.allocatable.pods"},{field:"status.requested.pods"}],[a.bB]:[{field:`metadata.annotations[${s.c8}]`},{field:"spec.displayName"},{field:"spec.clusterName"}],[a.CU]:[],[a.Z7.MACHINE]:[{field:"spec.clusterName"}],[a.Z7.MACHINE_DEPLOYMENT]:[{field:"spec.clusterName"}],[a.ll]:[{field:"_type"},{field:"reason"},{field:"involvedObject.kind"},{field:"involvedObject.uid"},{field:"message"}],[a.W8.CLUSTER_REPO]:[{field:"spec.gitRepo"},{field:"spec.gitBranch"},{field:"metadata.annotations[clusterrepo.cattle.io/hidden]"}],[a.W8.OPERATION]:[{field:"status.action"},{field:"status.namespace"},{field:"status.releaseName"}],[a.Z7.RANCHER_CLUSTER]:[{field:"status.provider"},{field:"status.clusterName"},{field:`metadata.annotations[${s.qt.HUMAN_NAME}]`}],[a.YV]:[{field:"spec.type"},{field:"spec.clusterIP"}],[a.kf]:[{field:"spec.rules.host"},{field:"spec.ingressClassName"}],[a.wT]:[{field:"spec.scaleTargetRef.name"},{field:"spec.minReplicas"},{field:"spec.maxReplicas"},{field:"spec.currentReplicas"}],[a.YH]:[{field:"spec.volumeName"}],[a.PV]:[{field:"status.reason"},{field:"spec.persistentVolumeReclaimPolicy"}],[a.fJ]:[{field:"provisioner"},{field:`metadata.annotations[${s.O3.DEFAULT_STORAGE_CLASS}]`}],[a.W8.APP]:[{field:"spec.chart.metadata.name"}],[a.oU.CRON_JOB]:[{field:`metadata.annotations[${s.bs}]`},{field:"spec.template.spec.containers.image"}],[a.oU.DAEMON_SET]:[{field:`metadata.annotations[${s.bs}]`},{field:"spec.template.spec.containers.image"}],[a.oU.DEPLOYMENT]:[{field:`metadata.annotations[${s.bs}]`},{field:"spec.template.spec.containers.image"}],[a.oU.JOB]:[{field:`metadata.annotations[${s.bs}]`},{field:"spec.template.spec.containers.image"}],[a.oU.STATEFUL_SET]:[{field:`metadata.annotations[${s.bs}]`},{field:"spec.template.spec.containers.image"}],[a.oU.REPLICA_SET]:[{field:"spec.template.spec.containers.image"}],[a.oU.REPLICATION_CONTROLLER]:[{field:"spec.template.spec.containers.image"}],[a.mm]:[]};const f={cluster:{resources:{enableAll:!1,enableSome:{enabled:[a.NW,a.ll,a.oU.CRON_JOB,a.oU.DAEMON_SET,a.oU.DEPLOYMENT,a.oU.JOB,a.oU.STATEFUL_SET,a.Sm,a.W8.APP,a.W8.OPERATION,a.wT,a.kf,a.YV,a.PV,a.K5,a.fJ,a.YH,a.bB,a.oU.REPLICA_SET,a.oU.REPLICATION_CONTROLLER,a.mm],generic:!0}}},management:{resources:{enableAll:!1,enableSome:{enabled:[{resource:a.Z7.RANCHER_CLUSTER,context:["side-bar","home","cluster-management"]},{resource:a.Mc.CLUSTER,context:["side-bar","home","cluster-management","token"]},{resource:a.W8.APP,context:["branding"]},a.bB],generic:!1}}}};t.A=new p},41418:function(e,t,n){"use strict";n.d(t,{j:function(){return r.A}});var r=n(79117)},9980:function(e,t,n){"use strict";n.d(t,{l:function(){return r.A}});var r=n(15554)},31019:function(e,t,n){"use strict";n.d(t,{Z:function(){return p}});var r=n(9274);const i={class:"card-wrap"},o={class:"card-title","data-modal-title":"","data-testid":"card-title-slot"},a={class:"card-body","data-testid":"card-body-slot"},s={key:0,class:"card-actions","data-testid":"card-actions-slot"};function l(e,t,n,l,c,u){const d=(0,r.resolveComponent)("RcSeparator");return(0,r.openBlock)(),(0,r.createElementBlock)("div",{id:"focus-trap-card-container-element",class:(0,r.normalizeClass)(["card-container",{"highlight-border":e.showHighlightBorder,"card-sticky":e.sticky}]),"data-testid":"card"},[(0,r.createElementVNode)("div",i,[(0,r.createElementVNode)("div",o,[(0,r.renderSlot)(e.$slots,"title",{},()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.title),1)],!0)]),(0,r.createVNode)(d),(0,r.createElementVNode)("div",a,[(0,r.renderSlot)(e.$slots,"body",{},()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.content),1)],!0)]),e.showActions?((0,r.openBlock)(),(0,r.createElementBlock)("div",s,[(0,r.renderSlot)(e.$slots,"actions",{},()=>[(0,r.createElementVNode)("button",{class:"btn role-primary",onClick:t[0]||(t[0]=(...t)=>e.buttonAction&&e.buttonAction(...t))},(0,r.toDisplayString)(e.buttonText),1)],!0)])):(0,r.createCommentVNode)("",!0)])],2)}var c=n(30342),u=(0,r.defineComponent)({name:"Card",components:{RcSeparator:c.A},props:{title:{type:String,default:""},content:{type:String,default:""},buttonAction:{type:Function,default:()=>{}},buttonText:{type:String,default:"go"},showHighlightBorder:{type:Boolean,default:!0},showActions:{type:Boolean,default:!0},sticky:{type:Boolean,default:!1}}}),d=(n(30336),n(47433));const h=(0,d.A)(u,[["render",l],["__scopeId","data-v-30ef2231"]]);var p=h},42200:function(e,t,n){"use strict";n.d(t,{S:function(){return r.A}});var r=n(71400)},79380:function(e,t,n){"use strict";n.d(t,{o:function(){return r.A}});var r=n(81548)},10196:function(e,t,n){"use strict";n.d(t,{z:function(){return r.A}});n(10096);var r=n(96531)},6879:function(e,t,n){"use strict";n.d(t,{V:function(){return r.A}});var r=n(55673)},13003:function(e,t,n){"use strict";n.d(t,{j:function(){return u}});var r=n(9274);const i={class:"switch hand"},o=["checked","disabled","aria-label"];function a(e,t,n,a,s,l){return(0,r.openBlock)(),(0,r.createElementBlock)("span",{class:(0,r.normalizeClass)(["toggle-container",{"toggle-disabled":e.disabled}])},[(0,r.createElementVNode)("span",{class:(0,r.normalizeClass)(["label no-select hand",{active:!e.state}]),onClick:t[0]||(t[0]=t=>e.toggle(!1))},(0,r.toDisplayString)(e.offLabel),3),(0,r.createElementVNode)("label",i,[(0,r.createElementVNode)("input",{type:"checkbox",role:"switch",checked:e.state,disabled:e.disabled,"aria-label":e.onLabel,onInput:t[1]||(t[1]=t=>e.toggle(null)),onKeydown:t[2]||(t[2]=(0,r.withKeys)(t=>e.toggle(null),["enter"]))},null,40,o),t[4]||(t[4]=(0,r.createElementVNode)("span",{class:"slider round"},null,-1))]),(0,r.createElementVNode)("span",{class:(0,r.normalizeClass)(["label no-select hand",{active:e.state}]),onClick:t[3]||(t[3]=t=>e.toggle(!0))},(0,r.toDisplayString)(e.onLabel),3)],2)}var s=(0,r.defineComponent)({props:{value:{type:[Boolean,String,Number,null],default:!1},offValue:{type:[Boolean,String,Number],default:!1},onValue:{type:[Boolean,String,Number],default:!0},offLabel:{type:String,default:""},onLabel:{type:String,default:""},disabled:{type:Boolean,default:!1}},emits:["update:value"],data(){return{state:!1}},watch:{value:{handler(){this.state=this.value===this.onValue},immediate:!0}},methods:{toggle(e){this.disabled||(this.state=null===e?!this.state:e,this.$emit("update:value",this.state?this.onValue:this.offValue))}}}),l=(n(41874),n(47433));const c=(0,l.A)(s,[["render",a],["__scopeId","data-v-0334e5ef"]]);var u=c},49924:function(e,t,n){"use strict";n.d(t,{Z:function(){return r.A}});var r=n(40811)},51433:function(e,t,n){"use strict";n.d(t,{a:function(){return r.A}});var r=n(71126)},63854:function(e,t,n){"use strict";n.d(t,{st:function(){return Ie},mK:function(){return oe},ji:function(){return ae},sN:function(){return le},Um:function(){return ce}});var r=n(9274),i=n(76528),o=n(81068),a=n(37323),s=n(43865),l=n(61163),c=n(29097),u=n(6516),d=n(71126),h=n(26977),p=n(55104),f=n(23045);function m(e){return"yaml"===e?(0,h.yaml)():"json"===e?(0,p.json)():"javascript"===e?new l.LanguageSupport(f.javascriptLanguage):[]}var g=n(4364);let v=o.getDrawSelectionConfig||function(){let e={cursorBlinkRate:1200};return function(){return e}}();class b{constructor(e,t,n,r,i,o,a,s,l,c){this.left=e,this.top=t,this.height=n,this.fontFamily=r,this.fontSize=i,this.fontWeight=o,this.color=a,this.className=s,this.letter=l,this.partial=c}draw(){let e=document.createElement("div");return e.className=this.className,this.adjust(e),e}adjust(e){e.style.left=this.left+"px",e.style.top=this.top+"px",e.style.height=this.height+"px",e.style.lineHeight=this.height+"px",e.style.fontFamily=this.fontFamily,e.style.fontSize=this.fontSize,e.style.fontWeight=this.fontWeight,e.style.color=this.partial?"transparent":this.color,e.className=this.className,e.textContent=this.letter}eq(e){return this.left==e.left&&this.top==e.top&&this.height==e.height&&this.fontFamily==e.fontFamily&&this.fontSize==e.fontSize&&this.fontWeight==e.fontWeight&&this.color==e.color&&this.className==e.className&&this.letter==e.letter}}class y{constructor(e,t){this.view=e,this.rangePieces=[],this.cursors=[],this.em=t,this.measureReq={read:this.readPos.bind(this),write:this.drawSel.bind(this)},this.cursorLayer=e.scrollDOM.appendChild(document.createElement("div")),this.cursorLayer.className="cm-cursorLayer cm-vimCursorLayer",this.cursorLayer.setAttribute("aria-hidden","true"),e.requestMeasure(this.measureReq),this.setBlinkRate()}setBlinkRate(){let e=v(this.view.state),t=e.cursorBlinkRate;this.cursorLayer.style.animationDuration=t+"ms"}update(e){(e.selectionSet||e.geometryChanged||e.viewportChanged)&&(this.view.requestMeasure(this.measureReq),this.cursorLayer.style.animationName="cm-blink"==this.cursorLayer.style.animationName?"cm-blink2":"cm-blink"),w(e)&&this.setBlinkRate()}scheduleRedraw(){this.view.requestMeasure(this.measureReq)}readPos(){let{state:e}=this.view,t=[];for(let n of e.selection.ranges){let r=n==e.selection.main,i=x(this.em,this.view,n,r);i&&t.push(i)}return{cursors:t}}drawSel({cursors:e}){if(e.length!=this.cursors.length||e.some((e,t)=>!e.eq(this.cursors[t]))){let t=this.cursorLayer.children;if(t.length!==e.length){this.cursorLayer.textContent="";for(const t of e)this.cursorLayer.appendChild(t.draw())}else e.forEach((e,n)=>e.adjust(t[n]));this.cursors=e}}destroy(){this.cursorLayer.remove()}}function w(e){return v(e.startState)!=v(e.state)}const O={".cm-line":{"& ::selection":{backgroundColor:"transparent !important"},"&::selection":{backgroundColor:"transparent !important"},caretColor:"transparent !important"},".cm-fat-cursor":{position:"absolute",background:"#ff9696",border:"none",whiteSpace:"pre"},"&:not(.cm-focused) .cm-fat-cursor":{background:"none",outline:"solid 1px #ff9696",color:"transparent !important"}},S=i.Prec.highest(o.EditorView.theme(O));function E(e){let t=e.scrollDOM.getBoundingClientRect(),n=e.textDirection==o.Direction.LTR?t.left:t.right-e.scrollDOM.clientWidth;return{left:n-e.scrollDOM.scrollLeft,top:t.top-e.scrollDOM.scrollTop}}function x(e,t,n,r){var i,o;let a=n.head,s=1;(e.$data.count||e.$data.keyChain)&&(s=.5);{let e=a<t.state.doc.length&&t.state.sliceDoc(a,a+1);e&&/[\uDC00-\uDFFF]/.test(e)&&a>1&&(a--,e=t.state.sliceDoc(a,a+1));let n=t.coordsAtPos(a,1);if(!n)return null;let c=E(t),u=t.domAtPos(a),d=u?u.node:t.contentDOM;while(u&&u.node instanceof HTMLElement)d=u.node,u={node:u.node.childNodes[u.offset],offset:0};if(!(d instanceof HTMLElement)){if(!d.parentNode)return null;d=d.parentNode}let h=getComputedStyle(d),p=n.left,f=null===(o=(i=t).coordsForChar)||void 0===o?void 0:o.call(i,a);if(f&&(p=f.left),e&&"\n"!=e&&"\r"!=e)if("\t"==e){e=" ";var l=t.coordsAtPos(a+1,-1);l&&(p=l.left-(l.left-n.left)/parseInt(h.tabSize))}else/[\uD800-\uDBFF]/.test(e)&&a<t.state.doc.length-1&&(e+=t.state.sliceDoc(a+1,a+2));else e=" ";let m=n.bottom-n.top;return new b(p-c.left,n.top-c.top+m*(1-s),m*s,h.fontFamily,h.fontSize,h.fontWeight,h.color,r?"cm-fat-cursor cm-cursor-primary":"cm-fat-cursor cm-cursor-secondary",e,1!=s)}}const _=o.EditorView.theme({".cm-emacsMode .cm-cursorLayer:not(.cm-vimCursorLayer)":{display:"none"},".cm-vim-panel":{padding:"5px 10px",backgroundColor:"#fffa8f",fontFamily:"monospace"},".cm-vim-panel input":{border:"none",outline:"none",backgroundColor:"#fffa8f"}}),k=o.ViewPlugin.fromClass(class{constructor(e){this.status="",this.view=e,this.em=new D(e),this.blockCursor=new y(e,this.em),this.view.scrollDOM.classList.add("cm-emacsMode")}update(e){e.docChanged&&(this.em.$emacsMark=null,this.em.updateMarksOnChange(e.changes)),this.blockCursor.update(e)}destroy(){this.view.scrollDOM.classList.remove("cm-emacsMode"),this.blockCursor.destroy()}},{eventHandlers:{keydown:function(e,t){var n=this.em.handleKeyboard(e);return n&&this.blockCursor.scheduleRedraw(),!!n},mousedown:function(){this.em.$emacsMark=null}}}),C=i.Facet.define({combine:e=>e[0]??!0}),A=i.StateEffect.define(),T=i.StateField.define({create:()=>!1,update(e,t){for(let n of t.effects)n.is(A)&&(e=n.value);return e},provide:e=>o.showPanel.from(e,e=>e?R:null)});function R(e){let t=document.createElement("div");return t.className="cm-vim-panel",{top:!1,dom:t}}function N(e={}){return[C.of(!1!==e.tabIndent),_,k,S,T]}var P={Return:"Return",Escape:"Esc",Insert:"Ins",ArrowLeft:"Left",ArrowRight:"Right",ArrowUp:"Up",ArrowDown:"Down",Enter:"Return",Divide:"/",Slash:"/",Multiply:"*",Subtract:"-",Minus:"-",Equal:"=",Semicolon:";",Comma:",",Period:"."},I={Shift:1,Alt:1,Command:1,Control:1,CapsLock:1};const M={};class D{constructor(e){this.view=e,this.$data={count:0,keyChain:"",lastCommand:""},this.$emacsMarkRing=[],this.$emacsMark=null}static bindKey(e,t){e.split("|").forEach(function(e){let n="",r=e.split(/\s+/);r.forEach(function(e,i){let o=e.split(/-(?=.)/),a=o.pop();o.length&&(n+=o.sort().join("-")+"-"),n+=a,i===r.length-1?M[n]=t:(M[n]="null",n+=" ")})})}static getKey(e){var t=e.code,n=e.key;if(I[n])return["","",""];t.length>1&&("N"==t[0]&&(t=t.replace(/^Numpad/,"")),"K"==t[0]&&(t=t.replace(/^Key/,""))),t=P[t]||t,1==t.length&&(t=t.toLowerCase());var r="";return e.ctrlKey&&(r+="C-"),e.metaKey&&(r+="CMD-"),e.altKey&&(r+="M-"),e.shiftKey&&(r+="S-"),[t,r,n]}static addCommands(e){Object.keys(e).forEach(function(t){var n=e[t];"function"==typeof n&&(n={exec:n}),D.commands[t]=n})}static execCommand(e,t,n,r=1){var i=void 0;if(r<0&&(r=-r),"function"===typeof e)for(var o=0;o<r;o++)e(t.view);else if("null"===e);else{if(!e.exec)throw new Error("missformed command");r>1&&e.handlesCount&&(n||(n={}),"object"===typeof n&&(n.count=r),r=1);for(o=0;o<r;o++)i=e.exec(t,n||{})}return i}handleKeyboard(e){var t=D.getKey(e),n=this.findCommand(t);if(!/Up|Down/.test(null===t||void 0===t?void 0:t[0])||!(0,c.completionStatus)(this.view.state)){if(n&&n.command){var r=D.execCommand(n.command,this,n.args,n.count);if(!1===r)return}return n}}findCommand([e,t,n]){if(e&&("Tab"!=e||""!=t&&"S-"!=t||this.view.state.facet(C)&&!this.view.state.readOnly)){var r=this,i=this.$data;if(!t&&1==e.length&&(r.pushEmacsMark(),i.count)){var o=new Array(i.count+1).join(n);return i.count=null,{command:"insertstring",args:o}}if("C-"==t||i.count){var s=parseInt(e[e.length-1]);if("number"===typeof s&&!isNaN(s))return i.count=Math.max(i.count||0,0),i.count=10*i.count+s,{command:"null"}}t&&(e=t+e),i.keyChain&&(e=i.keyChain+=" "+e);var l=M[e];if(i.keyChain="null"==l?e:"",l){if("null"===l)return{command:"null"};if("universalArgument"===l)return i.count=-4,{command:"null"};var c;if("string"!==typeof l&&(c=l.args,l.command&&(l=l.command)),"insertstring"!==l&&l!==a.splitLine&&l!==a.toggleComment||r.pushEmacsMark(),"string"!==typeof l||(l=D.commands[l],l)){l.readOnly||l.keepLastCommand||(i.lastCommand=null);s=i.count||1;return i.count&&(i.count=0),{command:l,args:c,count:s}}}}}showCommandLine(e){g.error("TODO")}updateMarksOnChange(e){this.$emacsMark&&(this.$emacsMark=this.updateMark(this.$emacsMark,e)),this.$emacsMarkRing=this.$emacsMarkRing.map(t=>this.updateMark(t,e)).filter(Boolean)}updateMark(e,t){if(e){var n=e.map(function(e){return t.mapPos(e,1,i.MapMode.TrackDel)}).filter(e=>null!=e);return 0==n.length?null:n}}emacsMark(){return this.$emacsMark}setEmacsMark(e){this.$emacsMark=e}pushEmacsMark(e,t){var n=this.$emacsMark;n&&L(this.$emacsMarkRing,n),!e||t?this.setEmacsMark(e):L(this.$emacsMarkRing,e)}popEmacsMark(){var e=this.emacsMark();return e?(this.setEmacsMark(null),e):this.$emacsMarkRing.pop()}getLastEmacsMark(){return this.$emacsMark||this.$emacsMarkRing.slice(-1)[0]}getCopyText(){var e=this.view.state;return e.selection.ranges.map(t=>e.sliceDoc(t.from,t.to)).join("\n")}clearSelection(){var e=this.view,t=e.state.selection,n=!t.ranges.some(e=>e.from!=e.to);if(n)return!1;var r=t.ranges.map(e=>i.EditorSelection.range(e.head,e.head));return e.dispatch({selection:i.EditorSelection.create(r,t.mainIndex)}),!0}onPaste(e){var t,n=this.view,r=n.state.selection;if(r.ranges.length>1){var o=e.split("\n");o.length==r.ranges.length&&(t=o)}var a=0,s=n.state.changeByRange(n=>{var r=t?t[a]:e;return a++,{changes:{from:n.from,to:n.to,insert:r},range:i.EditorSelection.cursor(n.from+r.length)}});n.dispatch(s)}selectionToEmacsMark(){var e=this.view.state.selection;return e.ranges.map(e=>e.head)}}function L(e,t){e.length&&e[e.length-1]+""==t+""||e.push(t)}function B(e){var t=e.state;if(t.readOnly)return!1;if(!h.yamlLanguage.isActiveAt(t,t.selection.main.head))return a.insertNewlineAndIndent(e);var n=t.changeByRange(e=>{var n=t.doc.lineAt(e.from),r=n.text.slice(0,e.from-n.from),o=/^\s*/.exec(r)[0],a=e.to,s=t.doc.lineAt(a);while(a<s.to&&/\s/.test(t.doc.sliceString(a,a+1)))a++;return{changes:{from:e.from,to:a,insert:t.lineBreak+o},range:i.EditorSelection.cursor(e.from+t.lineBreak.length+o.length)}});return e.dispatch(t.update(n,{scrollIntoView:!0,userEvent:"input"})),!0}D.commands={};const $={"Up|C-p":{command:"goOrSelect",args:[a.cursorLineUp,a.selectLineUp]},"Down|C-n":{command:"goOrSelect",args:[a.cursorLineDown,a.selectLineDown]},"Left|C-b":{command:"goOrSelect",args:[a.cursorCharBackward,a.selectCharBackward]},"Right|C-f":{command:"goOrSelect",args:[a.cursorCharForward,a.selectCharForward]},"C-Left|M-b":{command:"goOrSelect",args:[a.cursorGroupLeft,a.selectGroupLeft]},"C-Right|M-f":{command:"goOrSelect",args:[a.cursorGroupRight,a.selectGroupRight]},"Home|C-a":{command:"goOrSelect",args:[a.cursorLineStart,a.selectLineStart]},"End|C-e":{command:"goOrSelect",args:[a.cursorLineEnd,a.selectLineEnd]},"C-Home|S-M-,":{command:"goOrSelect",args:[a.cursorDocStart,a.selectDocStart]},"C-End|S-M-.":{command:"goOrSelect",args:[a.cursorDocEnd,a.selectDocEnd]},"S-Up|S-C-p":a.selectLineUp,"S-Down|S-C-n":a.selectLineDown,"S-Left|S-C-b":a.selectCharBackward,"S-Right|S-C-f":a.selectCharForward,"S-C-Left|S-M-b":a.selectGroupBackward,"S-C-Right|S-M-f":a.selectGroupForward,"S-Home|S-C-a":a.selectLineStart,"S-End|S-C-e":a.selectLineEnd,"S-C-Home":a.selectDocStart,"S-C-End":a.selectDocEnd,"C-l":"recenterTopBottom","M-s":"centerSelection","M-g":"gotoline","C-x C-p|C-x h":a.selectAll,"PageDown|C-v":{command:"goOrSelect",args:[a.cursorPageDown,a.selectPageDown]},"PageUp|M-v":{command:"goOrSelect",args:[a.cursorPageUp,a.selectPageDown]},"C-Down":{command:"moveParagraph",args:1},"C-Up":{command:"moveParagraph",args:-1},"S-C-Down":a.selectPageDown,"S-C-Up":a.selectPageUp,"M-C-s":"findnext","M-C-r":"findprevious","S-M-5":"replace",Backspace:e=>(0,c.deleteBracketPair)(e)||a.deleteCharBackward(e),"Delete|C-d":a.deleteCharForward,"Return|C-m":B,"C-j":e=>!e.state.readOnly&&a.insertNewline(e),Tab:a.indentMore,"S-Tab":a.indentLess,"C-o":a.splitLine,"M-d|C-Delete":{command:"killWord",args:"right"},"C-Backspace|M-Backspace|M-Delete":{command:"killWord",args:"left"},"C-k":"killLine","M-h":"selectParagraph","M-@|M-S-2":"markWord","C-y|S-Delete":"yank","M-y":"yankRotate","C-g":"keyboardQuit","C-w|C-S-w":"killRegion","M-w":"killRingSave","C-Space":"setMark","C-x C-x":"exchangePointAndMark","C-t":a.transposeChars,"M-u":{command:"changeCase",args:{dir:1}},"M-l":{command:"changeCase",args:{dir:-1}},"M-c":"capitalizeWord","M-Space":"justOneSpace","C-x C-u":{command:"changeCase",args:{dir:1,region:!0}},"C-x C-l":{command:"changeCase",args:{dir:1,region:!0}},"M-/":c.startCompletion,"C-u":"universalArgument","M-;":a.toggleComment,"C-/|C-x u|S-C--|C-z":a.undo,"S-C-/|S-C-x u|C--|S-C-z":a.redo,"C-x r":"selectRectangularRegion","M-x":{command:"focusCommandLine",args:"M-x "},Esc:"unsetTransientMark"};for(let Me in $)D.bindKey(Me,$[Me]);D.addCommands({unsetTransientMark:function(e){return e.setEmacsMark(null),!1},markWord:function(e,t){},selectParagraph:function(e,t){var n=e.view,r=n.state.selection.ranges[0].head,o=n.state.doc,a=o.lineAt(r),s=-1,l=-1,c=a;while(/\S/.test(c.text)&&c.from>0)s=c.from,c=n.state.doc.lineAt(c.from-1);if(-1==s)while(!/\S/.test(c.text)&&c.to<o.length)s=c.from,c=n.state.doc.lineAt(c.to+1);else c=a;while(/\S/.test(c.text)&&c.to<o.length)l=c.to,c=n.state.doc.lineAt(c.to+1);-1==l&&(l=a.to);var u=[i.EditorSelection.range(s,l)];n.dispatch({selection:i.EditorSelection.create(u)})},goOrSelect:{exec:function(e,t){var n=e.emacsMark()?t[1]:t[0];n(e.view)}},moveParagraph:function(e,t){for(var n=e.view,r=n.state.doc,i=n.state.selection.main.head,o=r.lineAt(i),a=/\S/.test(t<0?o.text.slice(0,i-o.from):o.text.slice(i-o.from));;){var s=o.number+t;if(s<1||s>r.lines){var l=t<0?o.from:o.to;return void n.dispatch({selection:{anchor:e.emacsMark()?n.state.selection.main.anchor:l,head:l},scrollIntoView:!0})}if(o=r.line(s),/\S/.test(o.text))a=!0;else if(a)return void n.dispatch({selection:{anchor:e.emacsMark()?n.state.selection.main.anchor:o.from,head:o.from},scrollIntoView:!0})}},capitalizeWord:function(e){var t=e.view;if(!t.state.readOnly){e.clearSelection(),a.selectGroupForward(t);var n=t.state.changeByRange(e=>{var n=t.state.sliceDoc(e.from,e.to),r=n.search(/\w/),o=r<0?n:n.slice(0,r)+n.charAt(r).toUpperCase()+n.slice(r+1).toLowerCase();return{changes:{from:e.from,to:e.to,insert:o},range:i.EditorSelection.cursor(e.from+o.length)}});t.dispatch(n)}},justOneSpace:function(e){var t=e.view;if(!t.state.readOnly){var n=t.state.selection.main.head,r=t.state.doc.lineAt(n),i=n,o=n;while(i>r.from&&/\s/.test(t.state.doc.sliceString(i-1,i)))i--;while(o<r.to&&/\s/.test(t.state.doc.sliceString(o,o+1)))o++;t.dispatch({changes:{from:i,to:o,insert:" "},selection:{anchor:i+1}})}},changeCase:function(e,t){var n=e.view;t.region||(e.clearSelection(),a.selectGroupForward(n));var r=n.state.changeByRange(e=>{var r=n.state.sliceDoc(e.from,e.to);return r=1==t.dir?r.toUpperCase():r.toLowerCase(),{changes:{from:e.from,to:e.to,insert:r},range:i.EditorSelection.cursor(e.from+r.length)}});n.dispatch(r)},centerSelection:function(e){e.view.dispatch({scrollIntoView:!0})},recenterTopBottom:function(e){var t=e.view,n=t.scrollDOM.scrollTop;t.dispatch({scrollIntoView:!0});try{t.measure(!0)}catch(l){}if(n==t.scrollDOM.scrollTop){var r=t.scrollDOM.getBoundingClientRect(),i=t.coordsAtPos(t.state.selection.main.head);if(i){var o=i.bottom-i.top,a=r.height,s=i.top-r.top;Math.abs(s)<o/4?n+=s+o-a+2:Math.abs(s-.5*a)<o/4?n+=s-2:n+=s-.5*a,t.scrollDOM.scrollTop=n}}},selectRectangularRegion:function(e){var t=e.view,n=t.state.selection.ranges,r=[];if(n.length>1)r.push(i.EditorSelection.range(n[0].from,n[n.length-1].to));else{let e=t.state.doc,o=e.lineAt(n[0].from),a=e.lineAt(n[0].to),s=n[0].from-o.from,l=n[0].to-a.from;while(o.from<a.to){if(r.push(i.EditorSelection.range(o.from+s,o.from+l)),o.to+1>=e.length)break;o=e.lineAt(o.to+1)}}t.dispatch({selection:i.EditorSelection.create(r)})},setMark:{exec:function(e,t){var n=e.view,r=n.state.selection.ranges;if(!t||!t.count){l=e.emacsMark();var o=r.map(function(e){return e.head}),a=r.every(function(e){return e.from==e.to});return l||!a?(e.clearSelection(),void(l&&e.pushEmacsMark(null))):l?void 0:(e.pushEmacsMark(o),void e.setEmacsMark(o))}var s=e.selectionToEmacsMark(),l=e.popEmacsMark();if(l){var c=l.map(e=>i.EditorSelection.cursor(e,e));n.dispatch({selection:i.EditorSelection.create(c)}),e.$emacsMarkRing.unshift(s)}},readOnly:!0,handlesCount:!0},exchangePointAndMark:{exec:function(e,t){var n=e.view,r=n.state.selection,o=!r.ranges.some(e=>e.from!=e.to);if(t.count||o){var a=e.$emacsMarkRing,s=a[a.length-1];if(s)if(t.count){a[a.length-1]=e.selectionToEmacsMark(),e.clearSelection();u=s.map(e=>i.EditorSelection.range(e,e));n.dispatch({selection:i.EditorSelection.create(u,r.mainIndex)})}else{var l=Math.min(s.length,r.ranges.length);u=[];for(var c=0;c<l;c++)u.push(i.EditorSelection.range(r.ranges[c].head,s[c]))}}else{var u=r.ranges.map(e=>i.EditorSelection.range(e.head,e.anchor));n.dispatch({selection:i.EditorSelection.create(u,r.mainIndex)})}},readOnly:!0,handlesCount:!0},killWord:{exec:function(e,t){var n=e.view,r=n.state.selection,o=r.ranges.map(e=>i.EditorSelection.range(e.head,e.head));n.dispatch({selection:i.EditorSelection.create(o,r.mainIndex)}),"left"==t?a.selectGroupBackward(n):a.selectGroupForward(n),r=n.state.selection,r.ranges.forEach(e=>{var t=n.state.sliceDoc(e.from,e.to);V.add(t)}),n.dispatch(n.state.replaceSelection(""))}},killLine:{exec:function(e){e.pushEmacsMark(null),e.clearSelection();var t=e.view,n=t.state,r=[],i=n.selection.ranges.map(function(e){var t=e.head,i=n.doc.lineAt(t),o=i.to,a=n.sliceDoc(t,o);return/^\s*$/.test(a)&&o<n.doc.length-1?(o+=1,r.push(a+"\n")):r.push(a),{from:t,to:o,insert:""}});"killLine"==e.$data.lastCommand?V.append(r.join("\n")):V.add(r.join("\n")),e.$data.lastCommand="killLine",t.dispatch({changes:i})},keepLastCommand:!0},yank:{exec:function(e){e.onPaste(V.get()),e.$data.lastCommand="yank"},keepLastCommand:!0},yankRotate:{exec:function(e){"yank"==e.$data.lastCommand&&(a.undo(e.view),e.$emacsMarkRing.pop(),e.onPaste(V.rotate()),e.$data.lastCommand="yank")},keepLastCommand:!0},killRegion:{exec:function(e){V.add(e.getCopyText());var t=e.view;t.dispatch(t.state.replaceSelection("")),e.setEmacsMark(null)}},killRingSave:{exec:function(e){var t=e.getCopyText();V.add(t),e.clearSelection(),e.setEmacsMark(null),navigator.clipboard.writeText(t)},readOnly:!0},keyboardQuit:function(e){var t=e.view,n=t.state.selection,r=!n.ranges.some(e=>e.from!=e.to);if(n.ranges.length>1&&!r){var o=n.ranges.map(e=>i.EditorSelection.range(e.head,e.head));t.dispatch({selection:i.EditorSelection.create(o,n.mainIndex)})}else a.simplifySelection(e.view);e.setEmacsMark(null),e.$data.count=null},focusCommandLine:function(e,t){e.showCommandLine(t)}});const V={$data:[],add:function(e){e&&this.$data.push(e),this.$data.length>30&&this.$data.shift()},append:function(e){var t=this.$data.length-1,n=this.$data[t]||"";e&&(n+=e),n&&(this.$data[t]=n)},get:function(e){return e=e||1,this.$data.slice(this.$data.length-e,this.$data.length).reverse().join("\n")},pop:function(){return this.$data.length>1&&this.$data.pop(),this.get()},rotate:function(){let e=this.$data.pop();return e&&this.$data.unshift(e),this.get()}};var F=n(59108);function j(e,t,n,r,i){const o=document.createElement("button"),a=document.createElement("i");return o.type="button",o.name=t,o.setAttribute("aria-label",e.state.phrase(r)),o.title=e.state.phrase(r),a.className=`icon ${n}`,a.setAttribute("aria-hidden","true"),o.appendChild(a),o.addEventListener("click",i),o}function U(e){const t=document.createElement("div"),n=document.createElement("div"),r=document.createElement("input"),i=document.createElement("div"),a=document.createElement("span"),l=document.createElement("i");let c=(0,s.getSearchQuery)(e.state);t.className="cm-search",n.className="cm-search-field",r.className="cm-textfield",r.name="search",r.value=c.search,r.placeholder=e.state.phrase("Find"),r.setAttribute("aria-label",e.state.phrase("Find")),r.setAttribute("main-field","true"),r.setAttribute("autocomplete","off"),r.setAttribute("spellcheck","false"),i.className="cm-search-controls",a.className="cm-search-count",a.setAttribute("role","status"),a.setAttribute("aria-live","polite"),l.className="icon icon-search cm-search-icon",l.setAttribute("aria-hidden","true");const u=j(e,"clear","icon-close","Clear search",()=>{r.value="",r.dispatchEvent(new Event("input",{bubbles:!0})),r.focus()}),d=j(e,"next","icon-chevron-down","next",()=>(0,s.findNext)(e)),h=j(e,"prev","icon-chevron-up","previous",()=>(0,s.findPrevious)(e));function p(){const t=e.state,n=t.selection.main;let r=0,i=0;if(c.valid){const e=c.getCursor(t);for(let t=e.next();!t.done;t=e.next())r++,t.value.from===n.from&&t.value.to===n.to&&(i=r)}a.textContent=c.search?t.phrase("$1 of $2",i,r):"",a.hidden=!c.search,u.hidden=!c.search,u.style.display=c.search?"":"none",l.hidden=!!c.search,l.style.display=c.search?"none":"",d.disabled=0===r,h.disabled=0===r}return i.append(d,a,h,u,l),n.append(r,i),t.append(n),r.addEventListener("input",()=>{var t;const n=e.state,i=new s.SearchQuery({...c,search:r.value});if(!i.eq(c)){c=i;const r=s.setSearchQuery.of(c);if(c.valid){const i=c.getCursor(n),o=[];for(let e=i.next();!e.done;e=i.next())o.push(e.value);const a=null!==(t=o.find(e=>e.from>=n.selection.main.from))&&void 0!==t?t:o[0];e.dispatch(a?{effects:r,selection:{anchor:a.from,head:a.to},scrollIntoView:!0}:{effects:r})}else e.dispatch({effects:r});p()}}),t.addEventListener("keydown",t=>{(0,o.runScopeHandlers)(e,t,"search-panel")?t.preventDefault():"Enter"===t.key&&t.target===r&&(t.preventDefault(),(t.shiftKey?s.findPrevious:s.findNext)(e))}),p(),{dom:t,top:!0,mount:()=>r.select(),update:e=>{const t=(0,s.getSearchQuery)(e.state);t.eq(c)||(c=t,r.value=c.search),(e.docChanged||e.selectionSet||e.transactions.some(e=>e.effects.some(e=>e.is(s.setSearchQuery))))&&p()}}}const G=[{key:"Mod-Shift-z",run:a.redo,preventDefault:!0},{mac:"Mod-y",run:a.redo,preventDefault:!0}];function H(e){const{state:t}=e;if(t.readOnly)return!1;if(t.selection.ranges.some(e=>!e.empty))return(0,a.indentMore)(e);const n=(0,l.getIndentUnit)(t);return e.dispatch(t.update(t.changeByRange(e=>{const r=t.doc.lineAt(e.head),o=(0,i.countColumn)(r.text.slice(0,e.head-r.from),t.tabSize),a=(0,l.indentString)(t,n-o%n);return{changes:{from:e.head,insert:a},range:i.EditorSelection.cursor(e.head+a.length)}}),{scrollIntoView:!0,userEvent:"input"})),!0}const q=a.defaultKeymap.filter(({key:e})=>"Alt-ArrowUp"!==e&&"Alt-ArrowDown"!==e),Q=q.filter(({key:e})=>"Mod-/"!==e),z=[{key:"Mod-d",run:s.selectNextOccurrence,preventDefault:!0},{key:"Mod-Shift-d",run:a.copyLineUp,preventDefault:!0},{mac:"Ctrl-Cmd-ArrowUp",run:a.moveLineUp,preventDefault:!0},{mac:"Ctrl-Cmd-ArrowDown",run:a.moveLineDown,preventDefault:!0},{win:"Shift-Ctrl-ArrowUp",linux:"Shift-Ctrl-ArrowUp",run:a.moveLineUp,preventDefault:!0},{win:"Shift-Ctrl-ArrowDown",linux:"Shift-Ctrl-ArrowDown",run:a.moveLineDown,preventDefault:!0},{key:"Mod-l",run:a.selectLine,preventDefault:!0}];function K(e){return(0,s.searchPanelOpen)(e.state)?(0,s.closeSearchPanel)(e):(0,s.openSearchPanel)(e)}const W=["Mod-f","F3","Mod-g","Escape"],X=s.searchKeymap.filter(({key:e})=>e&&W.includes(e)).map(e=>"Mod-f"===e.key?{...e,run:K}:e),Y=(0,s.search)({top:!0,createPanel:U});function Z(e,t){const n="input"!==t,r="input"!==t;return"vim"===e?[i.Prec.highest(o.keymap.of([{key:"Ctrl-/",run:()=>!0},...n?[{key:"Tab",run:e=>{var t;if(e.state.readOnly)return!1;const n=(0,F.getCM)(e);return(null===(t=null===n||void 0===n?void 0:n.state.vim)||void 0===t?void 0:t.insertMode)?H(e):(n&&F.Vim.handleKey(n,"<C-i>","user"),!0)}},{key:"Shift-Tab",run:e=>{var t,n;return!e.state.readOnly&&(!(null===(n=null===(t=(0,F.getCM)(e))||void 0===t?void 0:t.state.vim)||void 0===n?void 0:n.insertMode)||(0,a.indentLess)(e))}}]:[]])),(0,F.vim)(),o.keymap.of([{key:"Enter",run:e=>{var t,n;return!!(null===(n=null===(t=(0,F.getCM)(e))||void 0===t?void 0:t.state.vim)||void 0===n?void 0:n.insertMode)&&(0,a.insertNewlineAndIndent)(e)}},...c.closeBracketsKeymap,...l.foldKeymap])]:"emacs"===e?[i.Prec.highest(N({tabIndent:n})),o.keymap.of([{key:"Ctrl-h",run:a.deleteCharBackward},...r?[{key:"Ctrl-s",run:K,scope:"editor search-panel"},...X]:[],...Q,...a.historyKeymap,...G,...l.foldKeymap]),...r?[Y]:[]]:[o.keymap.of([...n?[{key:"Tab",run:H,shift:a.indentLess}]:[],...r?X:[],..."sublime"===e?z:[],...c.closeBracketsKeymap,...q,...a.historyKeymap,...G,...l.foldKeymap]),...r?[Y]:[]]}const J=l.foldService.of((e,t)=>{var n,r,i,o;const a=e.doc.lineAt(t),s=a.text,l=(null!==(r=null===(n=s.match(/^(\s*)/))||void 0===n?void 0:n[1])&&void 0!==r?r:"").length;if(""===s.trim())return null;let c=a.to;for(let u=a.number+1;u<=e.doc.lines;u++){const t=e.doc.line(u),n=t.text;if(""===n.trim()){c=t.to;continue}const r=(null!==(o=null===(i=n.match(/^(\s*)/))||void 0===i?void 0:i[1])&&void 0!==o?o:"").length;if(r<=l)break;c=t.to}return c===a.to?null:{from:a.to,to:c}}),ee=l.foldService.of((e,t)=>{const n=e.doc.lineAt(t);for(let r=0;r<n.text.length;r++){if(!"{[(".includes(n.text[r]))continue;const t=(0,l.matchBrackets)(e,n.from+r,1);if((null===t||void 0===t?void 0:t.matched)&&t.end&&e.doc.lineAt(t.end.from).number>n.number)return{from:t.start.to,to:t.end.from}}return null});function te(e){var t;const n=[(0,l.codeFolding)({placeholderText:"↔️"})],r=null!==(t=null===e||void 0===e?void 0:e.strategy)&&void 0!==t?t:"language";return"indent"===r?n.push(J):"bracket"===r&&n.push(ee),(null===e||void 0===e?void 0:e.custom)&&n.push(e.custom),n}function ne(e){return new RegExp(e.source,e.flags.replace(/[gy]/g,""))}function re(e,t){const n=[];for(let r=e.parent;r;r=r.parent)if("Pair"===r.name){const e=r.firstChild;"Key"===(null===e||void 0===e?void 0:e.name)&&n.unshift(t.doc.sliceString(e.from,e.to).trim())}else if("Item"===r.name){let e=0;for(let t=r.prevSibling;t;t=t.prevSibling)"Item"===t.name&&e++;n.unshift(`[${e}]`)}return n.reduce((e,t)=>t.startsWith("[")?`${e}${t}`:e?`${e}.${t}`:t,"")}function ie(e){var t,n,r;const i=e.match(/^\s*#(.*)$/);return i?(null!==(r=null===(n=(null!==(t=i[1])&&void 0!==t?t:"").match(/^(\s*)/))||void 0===n?void 0:n[1])&&void 0!==r?r:"").length:null}const oe=l.foldService.of((e,t)=>{const n=e.doc.lineAt(t),r=ie(n.text);if(null===r)return null;let i=n.to;for(let o=n.number+1;o<=e.doc.lines;o++){const t=e.doc.line(o),n=ie(t.text);if(null===n)break;if(n<=r)break;i=t.to}return i===n.to?null:{from:n.to,to:i}});function ae(e){const{state:t}=e,n=[];for(let r=1;r<=t.doc.lines;r++){const e=t.doc.line(r),i=ie(e.text);if(null===i)continue;let o=e.to;for(let n=r+1;n<=t.doc.lines;n++){const e=t.doc.line(n),r=ie(e.text);if(null===r)break;if(r<=i)break;o=e.to}o!==e.to&&n.push({from:e.to,to:o})}n.length>0&&e.dispatch({effects:n.map(e=>l.foldEffect.of(e))})}function se(e,t){const n=e.state.doc,r=e.dom.isConnected;function i(){e.state.doc!==n||r&&!e.dom.isConnected||(!e.state.facet(l.language)||(0,l.forceParsing)(e,n.length,100)?t():setTimeout(i,16))}i()}function le(e,t){const n=ne(t);se(e,()=>{const{state:t}=e,r=[];for(let e=1;e<=t.doc.lines;e++){const i=t.doc.line(e);if(!n.test(i.text))continue;const o=(0,l.foldable)(t,i.from,i.to);o&&r.push(o)}r.length>0&&e.dispatch({effects:r.map(e=>l.foldEffect.of(e))})})}function ce(e,t){const n=t.split("."),r=n[n.length-1];se(e,()=>{const{state:n}=e,i=(0,l.syntaxTree)(n);let o=null;if(i.iterate({enter(e){return null===o&&("Key"===e.name&&n.doc.sliceString(e.from,e.to).trim()===r&&re(e.node,n)===t?(o=n.doc.lineAt(e.from).from,!1):void 0)}}),null===o)return;const a=n.doc.lineAt(o),s=(0,l.foldable)(n,a.from,a.to);s&&e.dispatch({effects:l.foldEffect.of(s)})})}const ue=["auto","scroll","hidden","clip"];function de(e){var t,n;const r=e.dom.ownerDocument;let i=Math.min(null!==(n=null===(t=r.defaultView)||void 0===t?void 0:t.innerHeight)&&void 0!==n?n:1/0,e.scrollDOM.getBoundingClientRect().bottom);for(let o=e.dom.parentElement;o&&o!==r.body;o=o.parentElement)ue.includes(getComputedStyle(o).overflowY)&&(i=Math.min(i,o.getBoundingClientRect().top+o.clientTop+o.clientHeight));return i}function he(e){const t=e.dom.ownerDocument,n=e.scrollDOM.getBoundingClientRect(),r=de(e);if(r<=n.top||"function"!==typeof t.elementFromPoint)return 0;const i=t.elementFromPoint(n.left+n.width/2,r-1);if(!i||e.dom.contains(i))return 0;for(let o=i;o&&!o.contains(e.dom);o=o.parentElement){const{position:e}=getComputedStyle(o);if("sticky"===e||"fixed"===e)return Math.min(Math.max(0,r-o.getBoundingClientRect().top),(r-Math.max(0,n.top))/2)}return 0}function pe(e){return[(0,o.panels)({bottomContainer:e}),o.EditorView.scrollMargins.of(t=>({top:e.firstChild?Math.max(0,e.getBoundingClientRect().bottom-Math.max(0,t.scrollDOM.getBoundingClientRect().top)):0,bottom:he(t)}))]}var fe=n(88727);const me=(0,fe.tagHighlighter)([{tag:[fe.tags.propertyName,fe.tags.definition(fe.tags.propertyName)],class:"cm-rancher-key"},{tag:[fe.tags.string,fe.tags.attributeValue],class:"cm-rancher-string"},{tag:[fe.tags.keyword,fe.tags.atom,fe.tags.bool,fe.tags.null],class:"cm-rancher-keyword"},{tag:fe.tags.comment,class:"cm-rancher-comment"}]),ge=o.Decoration.mark({class:"cm-rancher-keyword"}),ve=/^(?:true|false|on|off|yes|no)$/i;function be(e){const t=[];for(const{from:n,to:r}of e.visibleRanges)(0,l.syntaxTree)(e.state).iterate({from:n,to:r,enter:n=>{var r;"Literal"===n.name&&"Key"!==(null===(r=n.node.parent)||void 0===r?void 0:r.name)&&ve.test(e.state.sliceDoc(n.from,n.to))&&t.push({from:n.from,to:n.to})}});return o.Decoration.set(t.map(({from:e,to:t})=>ge.range(e,t)),!0)}const ye=o.ViewPlugin.fromClass(class{constructor(e){this.decorations=be(e)}update(e){(e.docChanged||e.viewportChanged||e.startState.facet(l.language)!==e.state.facet(l.language))&&(this.decorations=be(e.view))}},{decorations:e=>e.decorations}),we=o.EditorView.theme({".cm-content":{caretColor:"var(--rc-cm-key)"},".cm-cursor, .cm-dropCursor":{borderLeftColor:"var(--rc-cm-key)"},".cm-rancher-key":{color:"var(--rc-cm-key)",fontWeight:"normal"},".cm-rancher-string":{color:"var(--rc-cm-string)"},".cm-rancher-keyword":{color:"var(--rc-cm-keyword)"},".cm-rancher-comment":{color:"var(--rc-cm-comment)",fontStyle:"italic"},".cm-tooltip":{color:"var(--rc-cm-text)",backgroundColor:"var(--rc-cm-bg)",border:"1px solid var(--rc-cm-gutter)",borderRadius:"4px"},".cm-tooltip.cm-tooltip-autocomplete > ul > li[aria-selected]":{color:"var(--primary-text, #FFFFFF)",backgroundColor:"var(--primary, #3D98D3)"}}),Oe=o.EditorView.theme({"&":{color:"var(--rc-cm-text)",backgroundColor:"var(--rc-cm-bg)"},"&.cm-focused > .cm-scroller > .cm-selectionLayer .cm-selectionBackground, .cm-selectionBackground, .cm-content ::selection":{backgroundColor:"var(--rc-cm-selection)"},".cm-gutters":{color:"var(--rc-cm-gutter)",backgroundColor:"var(--rc-cm-bg)",borderRight:"none"},".cm-activeLineGutter":{backgroundColor:"transparent"},".cm-activeLine":{backgroundColor:"var(--rc-cm-active-line)"},".cm-foldPlaceholder":{backgroundColor:"transparent",border:"none",borderRadius:"0",color:"inherit",fontSize:"12px",fontStyle:"normal",lineHeight:"1",margin:"0 1px",padding:"0"}}),Se=o.EditorView.theme({".cm-panels":{color:"var(--rc-cm-text)",backgroundColor:"var(--rc-cm-bg)",colorScheme:"var(--rc-cm-color-scheme, light)"},".cm-panels-top":{borderBottom:"1px solid var(--border, #DCDEE7)"},"&:has(.cm-panels-top .cm-search)":{overflowY:"clip"},".cm-panels-top::before":{content:'""',position:"absolute",bottom:"100%",left:"0",right:"0",height:"100vh",backgroundColor:"color-mix(in srgb, var(--rc-cm-bg) 75%, transparent)",backdropFilter:"blur(2px)",pointerEvents:"none"},".cm-panel.cm-search":{display:"flex",alignItems:"center",padding:"8px 4px",fontSize:"14px"},".cm-search-field":{display:"flex",flex:"1 1 auto",boxSizing:"border-box",minWidth:"0",height:"36px",border:"1px solid var(--input-border, #C4C8CF)",borderRadius:"var(--border-radius, 4px)",backgroundColor:"var(--input-bg, transparent)","&:hover":{borderColor:"var(--input-hover-border, var(--input-border, #C4C8CF))"},"&:focus-within":{borderColor:"var(--primary-border, var(--primary, #3D98D3))",boxShadow:"inset 0 0 0 1px var(--primary-border, var(--primary, #3D98D3))"}},".cm-panel.cm-search .cm-textfield":{display:"block",flex:"1 1 auto",boxSizing:"border-box",minWidth:"0",width:"100%",height:"100%",padding:"0 8px",margin:"0",fontSize:"inherit",color:"var(--input-text, inherit)",backgroundColor:"transparent",border:"0",outline:"none",boxShadow:"none"},".cm-search-controls":{display:"flex",alignItems:"center",flex:"0 0 auto",height:"100%",gap:"2px",padding:"0 4px",color:"var(--muted, #6B6D85)"},".cm-search-count":{whiteSpace:"nowrap",fontSize:"12px",padding:"0 2px"},".cm-panel.cm-search .cm-search-controls button":{display:"inline-flex",alignItems:"center",justifyContent:"center",width:"24px",height:"28px",minHeight:"0",boxSizing:"border-box",margin:"0",padding:"0",border:"0",backgroundColor:"transparent",color:"inherit",lineHeight:"1",cursor:"pointer","&:hover":{color:"var(--primary, #3D98D3)"},"&:disabled":{opacity:"0.4",cursor:"default"}},".cm-panel.cm-search .cm-search-controls [name=clear]":{fontSize:"12px"},".cm-search-icon":{padding:"0 5px"},".cm-panel.cm-search button:focus-visible":{outline:"2px solid var(--primary-keyboard-focus, #3D98D3)",outlineOffset:"-2px"},".cm-searchMatch":{backgroundColor:"var(--rc-cm-search-match)"},".cm-searchMatch-selected":{backgroundColor:"var(--rc-cm-search-match-selected)"}}),Ee=o.EditorView.theme({".cm-cursor, .cm-dropCursor":{borderLeftWidth:"2px"}}),xe=(0,l.syntaxHighlighting)(me),_e=[we,xe,ye],ke=[Oe,Se,_e],Ce=[Ee,_e],Ae={class:"rc-cm-bottom-panels"},Te="Press Escape, then Tab to leave the editor";var Re=(0,r.defineComponent)({inheritAttrs:!1,__name:"RcCodeMirror",props:{modelValue:{default:""},language:{default:void 0},keymap:{default:void 0},theme:{default:"rancher"},variant:{default:"editor"},readOnly:{type:Boolean,default:!1},lineNumbers:{type:Boolean,default:!0},foldGutter:{type:Boolean,default:!0},lineWrapping:{type:Boolean,default:!1},extensions:{default:void 0},foldOptions:{default:void 0},linter:{type:Function,default:void 0},keymapIndicator:{type:Boolean,default:!1}},emits:["update:modelValue","change","focus","blur","ready"],setup(e,{expose:t,emit:n}){const h=e,p=n,f=(0,r.useAttrs)(),g=(0,r.ref)(),v=(0,r.ref)(),b=(0,r.shallowRef)(),y=(0,r.ref)(!1),w=(0,r.ref)(!1);let O;const S=(0,r.computed)(()=>{var e,t;return null!==(t=null===(e=b.value)||void 0===e?void 0:e.state.phrase(Te))&&void 0!==t?t:Te}),E={vim:"Vim",emacs:"Emacs"},x=(0,r.ref)(!1),_=(0,r.computed)(()=>h.keymap?E[h.keymap]:void 0),k=(0,r.computed)(()=>!!b.value&&h.keymapIndicator&&"input"!==h.variant&&!!_.value&&!x.value&&!w.value);function C(e){var t;const n=null===(t=b.value)||void 0===t?void 0:t.state;return n&&_.value?n.phrase(e,n.phrase(_.value)):""}const A=(0,r.computed)(()=>C("Key mapping: $")),T=(0,r.computed)(()=>C("Hide key mapping: $"));function R(){var e;x.value=!0,null===(e=b.value)||void 0===e||e.focus()}function N(e){return e.startsWith("aria-")||"tabindex"===e.toLowerCase()}const P=(0,r.computed)(()=>Object.fromEntries(Object.entries(f).filter(([e])=>!N(e))));function I(){const e=Object.fromEntries(Object.entries(f).filter(([e,t])=>N(e)&&void 0!==t&&null!==t).map(([e,t])=>["tabindex"===e.toLowerCase()?"tabindex":e,String(t)]));return h.readOnly&&void 0===e.tabindex&&(e.tabindex="0"),e}const M=new i.Compartment,D=new i.Compartment,L=new i.Compartment,B=new i.Compartment,$=new i.Compartment,V=new i.Compartment,F=new i.Compartment,j=new i.Compartment,U=new i.Compartment;function G(e,t){return"rancher"===e?"input"===t?Ce:ke:[]}function H(e){return e?(0,o.lineNumbers)():[]}function q(){var e;return"input"!==h.variant&&(null===(e=h.lineNumbers)||void 0===e||e)}function Q(e){var t,n,r,i;const o=document.createElement("span"),a=document.createElementNS("http://www.w3.org/2000/svg","svg"),s=document.createElementNS("http://www.w3.org/2000/svg","path"),l=e?"Fold line":"Unfold line";return o.className="rc-cm-fold-marker",o.title=null!==(i=null===(r=null!==(n=null===(t=b.value)||void 0===t?void 0:t.state)&&void 0!==n?n:O)||void 0===r?void 0:r.phrase(l))&&void 0!==i?i:l,a.setAttribute("viewBox","0 0 10 10"),a.setAttribute("aria-hidden","true"),s.setAttribute("d",e?"M2.5 3 7.5 3 5 7.5z":"M3 2.5 7.5 5 3 7.5z"),a.appendChild(s),o.appendChild(a),o}function z(e){return e?(0,l.foldGutter)({markerDOM:Q}):[]}function K(){var e;return"input"!==h.variant&&(null===(e=h.foldGutter)||void 0===e||e)}function W(e,t){return e?"input"===t?(0,u.linter)(e):[(0,u.linter)(e),(0,u.lintGutter)()]:[]}function X(){var e;return"input"===h.variant||null!==(e=h.lineWrapping)&&void 0!==e&&e}function Y(e){return[i.EditorState.readOnly.of(e),o.EditorView.editable.of(!e)]}function J(e){return e?o.EditorView.lineWrapping:[]}function ee(e){return o.EditorView.contentAttributes.of(e)}function ne(e){var t;e.target===(null===(t=b.value)||void 0===t?void 0:t.contentDOM)&&(y.value=!0)}function re(e){var t;e.target===(null===(t=b.value)||void 0===t?void 0:t.contentDOM)&&(y.value=!1)}function ie(e){const t=b.value;t&&"Escape"===e.code&&!e.shiftKey&&e.target===t.contentDOM&&t.setTabFocusMode(2e3)}function oe(e){var t;const n=null===(t=b.value)||void 0===t?void 0:t.dom;"Escape"===e.code&&n&&e.composedPath().includes(n)&&e.stopPropagation()}return(0,r.onMounted)(()=>{var e,t,n;if(!g.value)return;const r=o.EditorView.updateListener.of(e=>{if(w.value=(0,s.searchPanelOpen)(e.state),e.docChanged){const t=e.state.doc.toString();p("update:modelValue",t),p("change",t)}e.focusChanged&&(e.view.hasFocus?p("focus",e.view):p("blur",e.view))}),u=i.EditorState.create({doc:null!==(e=h.modelValue)&&void 0!==e?e:"",extensions:[(0,a.history)(),(0,o.drawSelection)(),(0,o.dropCursor)(),i.EditorState.allowMultipleSelections.of(!0),(0,l.indentOnInput)(),(0,l.syntaxHighlighting)(l.defaultHighlightStyle,{fallback:!0}),(0,l.bracketMatching)(),(0,c.closeBrackets)(),(0,o.rectangularSelection)(),(0,o.crosshairCursor)(),(0,o.highlightActiveLineGutter)(),(0,o.highlightSpecialChars)(),(0,c.autocompletion)(),te(h.foldOptions),M.of(m(h.language)),D.of(Z(h.keymap,h.variant)),L.of(G(h.theme,h.variant)),$.of(H(q())),j.of(W(h.linter,h.variant)),F.of(z(K())),V.of(J(X())),B.of(Y(null!==(t=h.readOnly)&&void 0!==t&&t)),U.of(ee(I())),r,...v.value?[pe(v.value)]:[],...null!==(n=h.extensions)&&void 0!==n?n:[]]});O=u;const d=new o.EditorView({state:u,parent:g.value});b.value=d,p("ready",d)}),(0,r.onBeforeUnmount)(()=>{var e;null===(e=b.value)||void 0===e||e.destroy()}),(0,r.watch)(()=>h.modelValue,e=>{const t=b.value;if(!t)return;const n=t.state.doc.toString();e!==n&&t.dispatch({changes:{from:0,to:t.state.doc.length,insert:null!==e&&void 0!==e?e:""}})}),(0,r.watch)(()=>h.language,e=>{var t;null===(t=b.value)||void 0===t||t.dispatch({effects:M.reconfigure(m(e))})}),(0,r.watch)(()=>[h.keymap,h.variant],([e,t])=>{var n;null===(n=b.value)||void 0===n||n.dispatch({effects:D.reconfigure(Z(e,t))})}),(0,r.watch)(()=>[h.theme,h.variant],([e,t])=>{var n;null===(n=b.value)||void 0===n||n.dispatch({effects:L.reconfigure(G(e,t))})}),(0,r.watch)(()=>h.readOnly,e=>{var t;null===(t=b.value)||void 0===t||t.dispatch({effects:B.reconfigure(Y(null!==e&&void 0!==e&&e))})}),(0,r.watch)(()=>q(),e=>{var t;null===(t=b.value)||void 0===t||t.dispatch({effects:$.reconfigure(H(e))})}),(0,r.watch)(()=>[h.linter,h.variant],([e,t])=>{var n;null===(n=b.value)||void 0===n||n.dispatch({effects:j.reconfigure(W(e,t))})}),(0,r.watch)(()=>K(),e=>{var t;null===(t=b.value)||void 0===t||t.dispatch({effects:F.reconfigure(z(e))})}),(0,r.watch)(()=>X(),e=>{var t;null===(t=b.value)||void 0===t||t.dispatch({effects:V.reconfigure(J(e))})}),(0,r.watch)(I,e=>{var t;null===(t=b.value)||void 0===t||t.dispatch({effects:U.reconfigure(ee(e))})}),t({view:b}),(t,n)=>{const i=(0,r.resolveDirective)("clean-tooltip");return(0,r.openBlock)(),(0,r.createElementBlock)("div",(0,r.mergeProps)(P.value,{ref_key:"container",ref:g,class:["rc-code-mirror",`rc-code-mirror--${e.variant}`],onKeydownCapture:ie,onKeydown:oe,onFocusin:ne,onFocusout:re}),[(0,r.withDirectives)((0,r.createElementVNode)("span",{class:"rc-cm-escape-hint",role:"alert"},(0,r.toDisplayString)(S.value),513),[[r.vShow,y.value&&"input"!==e.variant&&!e.readOnly]]),k.value?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createBlock)(d.A,{key:0,type:"button",variant:"ghost",class:"rc-cm-keymap-indicator","data-testid":"code-mirror-keymap","aria-label":T.value,onClick:R},{default:(0,r.withCtx)(()=>[...n[0]||(n[0]=[(0,r.createElementVNode)("i",{class:"icon icon-keyboard rc-cm-keymap-icon","aria-hidden":"true"},null,-1),(0,r.createElementVNode)("i",{class:"icon icon-close icon-sm rc-cm-keymap-close","aria-hidden":"true"},null,-1)])]),_:1},8,["aria-label"])),[[i,A.value]]):(0,r.createCommentVNode)("",!0),(0,r.createElementVNode)("div",Ae,[(0,r.createElementVNode)("div",{ref_key:"bottomPanels",ref:v},null,512)])],16)}}}),Ne=(n(17492),n(47433));const Pe=(0,Ne.A)(Re,[["__scopeId","data-v-0d60681a"]]);var Ie=Pe},30588:function(e,t,n){"use strict";n.d(t,{Jj:function(){return jt},s$:function(){return Kt},Nm:function(){return tn},PU:function(){return sn},ue:function(){return kn},Gh:function(){return pn},ug:function(){return bn},Nq:function(){return Sn}});var r=n(9274),i=n(40597);const o=()=>{const e=(0,r.ref)([]),t=(0,r.ref)(null),n=(0,r.ref)(null),i=(0,r.ref)(null),o=r=>{var o;if(t.value=r,(null===(o=t.value)||void 0===o?void 0:o.firstElementChild)instanceof HTMLElement){a(),e.value[0]instanceof HTMLElement&&(n.value=e.value[0]);const t=e.value[e.value.length-1];t instanceof HTMLElement&&(i.value=t)}},a=()=>{var n;e.value=[];const r=null===(n=t.value)||void 0===n?void 0:n.querySelectorAll("[dropdown-menu-item]");null===r||void 0===r||r.forEach(t=>{e.value.push(t)})};return{dropdownItems:e,firstDropdownItem:n,lastDropdownItem:i,dropdownContainer:t,registerDropdownCollection:o}},a=300;let s=0;const l=(e,t)=>{const n="rc-dropdown-submenu-"+ ++s,i=(0,r.shallowRef)([]),o=(0,r.shallowRef)(null),l=(0,r.shallowRef)(null),c=(0,r.ref)(null),u=(0,r.ref)([]);let d,h=!1;const p=()=>{var e;u.value=Array.from((null===(e=c.value)||void 0===e?void 0:e.querySelectorAll("[dropdown-menu-item]"))||[])},f=e=>{var t;p();const n=u.value;null===(t=n["first"===e?0:n.length-1])||void 0===t||t.focus()},m=e=>{var t,n;clearTimeout(d),o.value&&o.value!==e&&(null===(t=c.value)||void 0===t?void 0:t.contains(document.activeElement))&&(null===(n=o.value.row())||void 0===n||n.focus()),o.value=e,e&&(l.value=e)},g=(e,t)=>{m(e),t&&(0,r.nextTick)(()=>{var e;f("first"),h=!(null===(e=c.value)||void 0===e?void 0:e.contains(document.activeElement))})},v=()=>{var e;const t=null===(e=o.value)||void 0===e?void 0:e.row();m(null),null===t||void 0===t||t.focus()},b=e=>{clearTimeout(d),o.value!==e&&(o.value?d=setTimeout(()=>m(e),a):e&&m(e))},y=()=>clearTimeout(d),w=e=>(i.value=[...i.value,e],()=>{i.value=i.value.filter(t=>t!==e),o.value===e&&m(null),l.value===e&&(l.value=null)}),O=()=>{h&&(h=!1,(0,r.nextTick)(()=>f("first")))},S=e=>{const n=o.value;if(!n||e.altKey||e.ctrlKey||e.metaKey)return;const r="ArrowLeft"===e.key||"left"===n.side&&"ArrowRight"===e.key;"Escape"===e.key||r?(e.preventDefault(),e.stopPropagation(),v()):"Tab"===e.key?t():"ArrowDown"!==e.key&&"ArrowUp"!==e.key||e.target!==c.value||(e.preventDefault(),f("ArrowDown"===e.key?"first":"last"))};(0,r.watch)(e,e=>{e||(clearTimeout(d),h=!1,o.value=null)}),(0,r.onBeforeUnmount)(()=>clearTimeout(d));const E=e=>(0,r.defineComponent)({name:"RcDropdownSubmenuContent",props:{submenu:{type:Object,required:!0}},setup(t){return(0,r.provide)("dropdownContext",{...e,dropdownItems:u,focusFirstElement:()=>f("first"),hoverSubmenu:()=>y(),registerSubmenu:()=>()=>null,openSubmenu:()=>null,inSubmenu:!0}),()=>t.submenu.render()}});return{submenuId:n,submenus:i,activeSubmenu:o,shownSubmenu:l,submenuTarget:c,registerSubmenu:w,openSubmenu:g,hoverSubmenu:b,cancelSubmenuSwitch:y,refreshSubmenuItems:p,onSubmenuShown:O,onSubmenuKeydown:S,makeSubmenuContent:E}},c=()=>{const e=document.activeElement;try{return!!e&&e!==document.body&&e.matches(":focus-visible")}catch(t){return!1}},u=e=>{const{dropdownItems:t,firstDropdownItem:n,lastDropdownItem:i,dropdownContainer:a,registerDropdownCollection:s}=o(),c=(0,r.ref)(!1);let u=null;const d=t=>{if(t){if(!c.value){const e=document.activeElement;u=e instanceof HTMLElement&&e!==document.body?e:null}}else m.value=!1;c.value=t,e("update:open",t)},h=(0,r.ref)(null),p=e=>{h.value=e},f=()=>{d(!1),h.value?h.value.focus():null===u||void 0===u||u.focus()},m=(0,r.ref)(!1),g=()=>{m.value=!0},v=e=>{(0,r.nextTick)(()=>{var t,r,o;m.value?("down"===e?null===(r=n.value)||void 0===r||r.focus():"up"===e&&(null===(o=i.value)||void 0===o||o.focus()),m.value=!1):null===(t=a.value)||void 0===t||t.focus()})},b=e=>{if(!e)return;const t=e.closest(".v-popper__inner")||e;t.style.overflowY="",e.style.height="";const{top:n,bottom:r}=e.getBoundingClientRect(),i=32;if(n-i<0||r+i>window.innerHeight){const o=Math.min(r,window.innerHeight-n,window.innerHeight);e.style.height=o-i+"px",t.style.overflowY="auto"}},y=l(c,()=>d(!1)),w={showMenu:d,registerTrigger:p,isMenuOpen:c,dropdownItems:t,close:()=>f(),focusFirstElement:()=>{v("down")},handleKeydown:g,submenuId:y.submenuId,activeSubmenu:y.activeSubmenu,registerSubmenu:y.registerSubmenu,openSubmenu:y.openSubmenu,hoverSubmenu:y.hoverSubmenu,cancelSubmenuSwitch:y.cancelSubmenuSwitch},O=()=>{(0,r.provide)("dropdownContext",w)},S=y.makeSubmenuContent(w);return{submenus:y,SubmenuContent:S,isMenuOpen:c,showMenu:d,returnFocus:f,setFocus:v,provideDropdownContext:O,registerDropdownCollection:s,handleKeydown:g,setDropdownDimensions:b}},d=["top","right","bottom","left"],h=["start","end"],p=d.reduce((e,t)=>e.concat(t,t+"-"+h[0],t+"-"+h[1]),[]),f=Math.min,m=Math.max,g=(Math.round,Math.floor,{left:"right",right:"left",bottom:"top",top:"bottom"});function v(e,t,n){return m(e,f(t,n))}function b(e,t){return"function"===typeof e?e(t):e}function y(e){return e.split("-")[0]}function w(e){return e.split("-")[1]}function O(e){return"x"===e?"y":"x"}function S(e){return"y"===e?"height":"width"}function E(e){const t=e[0];return"t"===t||"b"===t?"y":"x"}function x(e){return O(E(e))}function _(e,t,n){void 0===n&&(n=!1);const r=w(e),i=x(e),o=S(i);let a="x"===i?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[o]>t.floating[o]&&(a=M(a)),[a,M(a)]}function k(e){const t=M(e);return[C(e),t,C(t)]}function C(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}const A=["left","right"],T=["right","left"],R=["top","bottom"],N=["bottom","top"];function P(e,t,n){switch(e){case"top":case"bottom":return n?t?T:A:t?A:T;case"left":case"right":return t?R:N;default:return[]}}function I(e,t,n,r){const i=w(e);let o=P(y(e),"start"===n,r);return i&&(o=o.map(e=>e+"-"+i),t&&(o=o.concat(o.map(C)))),o}function M(e){const t=y(e);return g[t]+e.slice(t.length)}function D(e){return{top:0,right:0,bottom:0,left:0,...e}}function L(e){return"number"!==typeof e?D(e):{top:e,right:e,bottom:e,left:e}}function B(e){const{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}}function $(e,t,n){let{reference:r,floating:i}=e;const o=E(t),a=x(t),s=S(a),l=y(t),c="y"===o,u=r.x+r.width/2-i.width/2,d=r.y+r.height/2-i.height/2,h=r[s]/2-i[s]/2;let p;switch(l){case"top":p={x:u,y:r.y-i.height};break;case"bottom":p={x:u,y:r.y+r.height};break;case"right":p={x:r.x+r.width,y:d};break;case"left":p={x:r.x-i.width,y:d};break;default:p={x:r.x,y:r.y}}switch(w(t)){case"start":p[a]-=h*(n&&c?-1:1);break;case"end":p[a]+=h*(n&&c?-1:1);break}return p}async function V(e,t){var n;void 0===t&&(t={});const{x:r,y:i,platform:o,rects:a,elements:s,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:u="viewport",elementContext:d="floating",altBoundary:h=!1,padding:p=0}=b(t,e),f=L(p),m="floating"===d?"reference":"floating",g=s[h?m:d],v=B(await o.getClippingRect({element:null==(n=await(null==o.isElement?void 0:o.isElement(g)))||n?g:g.contextElement||await(null==o.getDocumentElement?void 0:o.getDocumentElement(s.floating)),boundary:c,rootBoundary:u,strategy:l})),y="floating"===d?{x:r,y:i,width:a.floating.width,height:a.floating.height}:a.reference,w=await(null==o.getOffsetParent?void 0:o.getOffsetParent(s.floating)),O=await(null==o.isElement?void 0:o.isElement(w))&&await(null==o.getScale?void 0:o.getScale(w))||{x:1,y:1},S=B(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:y,offsetParent:w,strategy:l}):y);return{top:(v.top-S.top+f.top)/O.y,bottom:(S.bottom-v.bottom+f.bottom)/O.y,left:(v.left-S.left+f.left)/O.x,right:(S.right-v.right+f.right)/O.x}}const F=50,j=async(e,t,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:o=[],platform:a}=n,s=a.detectOverflow?a:{...a,detectOverflow:V},l=await(null==a.isRTL?void 0:a.isRTL(t));let c=await a.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:d}=$(c,r,l),h=r,p=0;const f={};for(let m=0;m<o.length;m++){const n=o[m];if(!n)continue;const{name:g,fn:v}=n,{x:b,y:y,data:w,reset:O}=await v({x:u,y:d,initialPlacement:r,placement:h,strategy:i,middlewareData:f,rects:c,platform:s,elements:{reference:e,floating:t}});u=null!=b?b:u,d=null!=y?y:d,f[g]={...f[g],...w},O&&p<F&&(p++,"object"===typeof O&&(O.placement&&(h=O.placement),O.rects&&(c=!0===O.rects?await a.getElementRects({reference:e,floating:t,strategy:i}):O.rects),({x:u,y:d}=$(c,h,l))),m=-1)}return{x:u,y:d,placement:h,strategy:i,middlewareData:f}},U=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:i,rects:o,platform:a,elements:s,middlewareData:l}=t,{element:c,padding:u=0}=b(e,t)||{};if(null==c)return{};const d=L(u),h={x:n,y:r},p=x(i),m=S(p),g=await a.getDimensions(c),y="y"===p,O=y?"top":"left",E=y?"bottom":"right",_=y?"clientHeight":"clientWidth",k=o.reference[m]+o.reference[p]-h[p]-o.floating[m],C=h[p]-o.reference[p],A=await(null==a.getOffsetParent?void 0:a.getOffsetParent(c));let T=A?A[_]:0;T&&await(null==a.isElement?void 0:a.isElement(A))||(T=s.floating[_]||o.floating[m]);const R=k/2-C/2,N=T/2-g[m]/2-1,P=f(d[O],N),I=f(d[E],N),M=P,D=T-g[m]-I,B=T/2-g[m]/2+R,$=v(M,B,D),V=!l.arrow&&null!=w(i)&&B!==$&&o.reference[m]/2-(B<M?P:I)-g[m]/2<0,F=V?B<M?B-M:B-D:0;return{[p]:h[p]+F,data:{[p]:$,centerOffset:B-$-F,...V&&{alignmentOffset:F}},reset:V}}});function G(e,t,n){const r=e?[...n.filter(t=>w(t)===e),...n.filter(t=>w(t)!==e)]:n.filter(e=>y(e)===e);return r.filter(n=>!e||(w(n)===e||!!t&&C(n)!==n))}const H=function(e){return void 0===e&&(e={}),{name:"autoPlacement",options:e,async fn(t){var n,r,i;const{rects:o,middlewareData:a,placement:s,platform:l,elements:c}=t,{crossAxis:u=!1,alignment:d,allowedPlacements:h=p,autoAlignment:f=!0,...m}=b(e,t),g=void 0!==d||h===p?G(d||null,f,h):h,v=await l.detectOverflow(t,m),O=(null==(n=a.autoPlacement)?void 0:n.index)||0,S=g[O];if(null==S)return{};const E=_(S,o,await(null==l.isRTL?void 0:l.isRTL(c.floating)));if(s!==S)return{reset:{placement:g[0]}};const x=[v[y(S)],v[E[0]],v[E[1]]],k=[...(null==(r=a.autoPlacement)?void 0:r.overflows)||[],{placement:S,overflows:x}],C=g[O+1];if(C)return{data:{index:O+1,overflows:k},reset:{placement:C}};const A=k.map(e=>{const t=w(e.placement);return[e.placement,t&&u?e.overflows.slice(0,2).reduce((e,t)=>e+t,0):e.overflows[0],e.overflows]}).sort((e,t)=>e[1]-t[1]),T=A.filter(e=>e[2].slice(0,w(e[0])?2:3).every(e=>e<=0)),R=(null==(i=T[0])?void 0:i[0])||A[0][0];return R!==s?{data:{index:O+1,overflows:k},reset:{placement:R}}:{}}}},q=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:i,middlewareData:o,rects:a,initialPlacement:s,platform:l,elements:c}=t,{mainAxis:u=!0,crossAxis:d=!0,fallbackPlacements:h,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:f="none",flipAlignment:m=!0,...g}=b(e,t);if(null!=(n=o.arrow)&&n.alignmentOffset)return{};const v=y(i),w=E(s),O=y(s)===s,S=await(null==l.isRTL?void 0:l.isRTL(c.floating)),x=h||(O||!m?[M(s)]:k(s)),C="none"!==f;!h&&C&&x.push(...I(s,m,f,S));const A=[s,...x],T=await l.detectOverflow(t,g),R=[];let N=(null==(r=o.flip)?void 0:r.overflows)||[];if(u&&R.push(T[v]),d){const e=_(i,a,S);R.push(T[e[0]],T[e[1]])}if(N=[...N,{placement:i,overflows:R}],!R.every(e=>e<=0)){var P,D;const e=((null==(P=o.flip)?void 0:P.index)||0)+1,t=A[e];if(t){const n="alignment"===d&&w!==E(t);if(!n||N.every(e=>E(e.placement)!==w||e.overflows[0]>0))return{data:{index:e,overflows:N},reset:{placement:t}}}let n=null==(D=N.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0])?void 0:D.placement;if(!n)switch(p){case"bestFit":{var L;const e=null==(L=N.filter(e=>{if(C){const t=E(e.placement);return t===w||"y"===t}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0])?void 0:L[0];e&&(n=e);break}case"initialPlacement":n=s;break}if(i!==n)return{reset:{placement:n}}}return{}}}};const Q=new Set(["left","top"]);async function z(e,t){const{placement:n,platform:r,elements:i}=e,o=await(null==r.isRTL?void 0:r.isRTL(i.floating)),a=y(n),s=w(n),l="y"===E(n),c=Q.has(a)?-1:1,u=o&&l?-1:1,d=b(t,e);let{mainAxis:h,crossAxis:p,alignmentAxis:f}="number"===typeof d?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&"number"===typeof f&&(p="end"===s?-1*f:f),l?{x:p*u,y:h*c}:{x:h*c,y:p*u}}const K=function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:i,y:o,placement:a,middlewareData:s}=t,l=await z(t,e);return a===(null==(n=s.offset)?void 0:n.placement)&&null!=(r=s.arrow)&&r.alignmentOffset?{}:{x:i+l.x,y:o+l.y,data:{...l,placement:a}}}}},W=function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:i,platform:o}=t,{mainAxis:a=!0,crossAxis:s=!1,limiter:l={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...c}=b(e,t),u={x:n,y:r},d=await o.detectOverflow(t,c),h=E(y(i)),p=O(h);let f=u[p],m=u[h];if(a){const e="y"===p?"top":"left",t="y"===p?"bottom":"right",n=f+d[e],r=f-d[t];f=v(n,f,r)}if(s){const e="y"===h?"top":"left",t="y"===h?"bottom":"right",n=m+d[e],r=m-d[t];m=v(n,m,r)}const g=l.fn({...t,[p]:f,[h]:m});return{...g,data:{x:g.x-n,y:g.y-r,enabled:{[p]:a,[h]:s}}}}}},X=function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:i,rects:o,platform:a,elements:s}=t,{apply:l=()=>{},...c}=b(e,t),u=await a.detectOverflow(t,c),d=y(i),h=w(i),p="y"===E(i),{width:g,height:v}=o.floating;let O,S;"top"===d||"bottom"===d?(O=d,S=h===(await(null==a.isRTL?void 0:a.isRTL(s.floating))?"start":"end")?"left":"right"):(S=d,O="end"===h?"top":"bottom");const x=v-u.top-u.bottom,_=g-u.left-u.right,k=f(v-u[O],x),C=f(g-u[S],_),A=!t.middlewareData.shift;let T=k,R=C;if(null!=(n=t.middlewareData.shift)&&n.enabled.x&&(R=_),null!=(r=t.middlewareData.shift)&&r.enabled.y&&(T=x),A&&!h){const e=m(u.left,0),t=m(u.right,0),n=m(u.top,0),r=m(u.bottom,0);p?R=g-2*(0!==e||0!==t?e+t:m(u.left,u.right)):T=v-2*(0!==n||0!==r?n+r:m(u.top,u.bottom))}await l({...t,availableWidth:R,availableHeight:T});const N=await a.getDimensions(s.floating);return g!==N.width||v!==N.height?{reset:{rects:!0}}:{}}}};function Y(e){var t;return(null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function Z(e){return Y(e).getComputedStyle(e)}const J=Math.min,ee=Math.max,te=Math.round;function ne(e){const t=Z(e);let n=parseFloat(t.width),r=parseFloat(t.height);const i=e.offsetWidth,o=e.offsetHeight,a=te(n)!==i||te(r)!==o;return a&&(n=i,r=o),{width:n,height:r,fallback:a}}function re(e){return le(e)?(e.nodeName||"").toLowerCase():""}let ie;function oe(){if(ie)return ie;const e=navigator.userAgentData;return e&&Array.isArray(e.brands)?(ie=e.brands.map(e=>e.brand+"/"+e.version).join(" "),ie):navigator.userAgent}function ae(e){return e instanceof Y(e).HTMLElement}function se(e){return e instanceof Y(e).Element}function le(e){return e instanceof Y(e).Node}function ce(e){return"undefined"!=typeof ShadowRoot&&(e instanceof Y(e).ShadowRoot||e instanceof ShadowRoot)}function ue(e){const{overflow:t,overflowX:n,overflowY:r,display:i}=Z(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(i)}function de(e){return["table","td","th"].includes(re(e))}function he(e){const t=/firefox/i.test(oe()),n=Z(e),r=n.backdropFilter||n.WebkitBackdropFilter;return"none"!==n.transform||"none"!==n.perspective||!!r&&"none"!==r||t&&"filter"===n.willChange||t&&!!n.filter&&"none"!==n.filter||["transform","perspective"].some(e=>n.willChange.includes(e))||["paint","layout","strict","content"].some(e=>{const t=n.contain;return null!=t&&t.includes(e)})}function pe(){return!/^((?!chrome|android).)*safari/i.test(oe())}function fe(e){return["html","body","#document"].includes(re(e))}function me(e){return se(e)?e:e.contextElement}const ge={x:1,y:1};function ve(e){const t=me(e);if(!ae(t))return ge;const n=t.getBoundingClientRect(),{width:r,height:i,fallback:o}=ne(t);let a=(o?te(n.width):n.width)/r,s=(o?te(n.height):n.height)/i;return a&&Number.isFinite(a)||(a=1),s&&Number.isFinite(s)||(s=1),{x:a,y:s}}function be(e,t,n,r){var i,o;void 0===t&&(t=!1),void 0===n&&(n=!1);const a=e.getBoundingClientRect(),s=me(e);let l=ge;t&&(r?se(r)&&(l=ve(r)):l=ve(e));const c=s?Y(s):window,u=!pe()&&n;let d=(a.left+(u&&(null==(i=c.visualViewport)?void 0:i.offsetLeft)||0))/l.x,h=(a.top+(u&&(null==(o=c.visualViewport)?void 0:o.offsetTop)||0))/l.y,p=a.width/l.x,f=a.height/l.y;if(s){const e=Y(s),t=r&&se(r)?Y(r):r;let n=e.frameElement;for(;n&&r&&t!==e;){const e=ve(n),t=n.getBoundingClientRect(),r=getComputedStyle(n);t.x+=(n.clientLeft+parseFloat(r.paddingLeft))*e.x,t.y+=(n.clientTop+parseFloat(r.paddingTop))*e.y,d*=e.x,h*=e.y,p*=e.x,f*=e.y,d+=t.x,h+=t.y,n=Y(n).frameElement}}return{width:p,height:f,top:h,right:d+p,bottom:h+f,left:d,x:d,y:h}}function ye(e){return((le(e)?e.ownerDocument:e.document)||window.document).documentElement}function we(e){return se(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function Oe(e){return be(ye(e)).left+we(e).scrollLeft}function Se(e){if("html"===re(e))return e;const t=e.assignedSlot||e.parentNode||ce(e)&&e.host||ye(e);return ce(t)?t.host:t}function Ee(e){const t=Se(e);return fe(t)?t.ownerDocument.body:ae(t)&&ue(t)?t:Ee(t)}function xe(e,t){var n;void 0===t&&(t=[]);const r=Ee(e),i=r===(null==(n=e.ownerDocument)?void 0:n.body),o=Y(r);return i?t.concat(o,o.visualViewport||[],ue(r)?r:[]):t.concat(r,xe(r))}function _e(e,t,n){return"viewport"===t?B(function(e,t){const n=Y(e),r=ye(e),i=n.visualViewport;let o=r.clientWidth,a=r.clientHeight,s=0,l=0;if(i){o=i.width,a=i.height;const e=pe();(e||!e&&"fixed"===t)&&(s=i.offsetLeft,l=i.offsetTop)}return{width:o,height:a,x:s,y:l}}(e,n)):se(t)?B(function(e,t){const n=be(e,!0,"fixed"===t),r=n.top+e.clientTop,i=n.left+e.clientLeft,o=ae(e)?ve(e):{x:1,y:1};return{width:e.clientWidth*o.x,height:e.clientHeight*o.y,x:i*o.x,y:r*o.y}}(t,n)):B(function(e){const t=ye(e),n=we(e),r=e.ownerDocument.body,i=ee(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),o=ee(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let a=-n.scrollLeft+Oe(e);const s=-n.scrollTop;return"rtl"===Z(r).direction&&(a+=ee(t.clientWidth,r.clientWidth)-i),{width:i,height:o,x:a,y:s}}(ye(e)))}function ke(e){return ae(e)&&"fixed"!==Z(e).position?e.offsetParent:null}function Ce(e){const t=Y(e);let n=ke(e);for(;n&&de(n)&&"static"===Z(n).position;)n=ke(n);return n&&("html"===re(n)||"body"===re(n)&&"static"===Z(n).position&&!he(n))?t:n||function(e){let t=Se(e);for(;ae(t)&&!fe(t);){if(he(t))return t;t=Se(t)}return null}(e)||t}function Ae(e,t,n){const r=ae(t),i=ye(t),o=be(e,!0,"fixed"===n,t);let a={scrollLeft:0,scrollTop:0};const s={x:0,y:0};if(r||!r&&"fixed"!==n)if(("body"!==re(t)||ue(i))&&(a=we(t)),ae(t)){const e=be(t,!0);s.x=e.x+t.clientLeft,s.y=e.y+t.clientTop}else i&&(s.x=Oe(i));return{x:o.left+a.scrollLeft-s.x,y:o.top+a.scrollTop-s.y,width:o.width,height:o.height}}const Te={getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e;const o="clippingAncestors"===n?function(e,t){const n=t.get(e);if(n)return n;let r=xe(e).filter(e=>se(e)&&"body"!==re(e)),i=null;const o="fixed"===Z(e).position;let a=o?Se(e):e;for(;se(a)&&!fe(a);){const e=Z(a),t=he(a);(o?t||i:t||"static"!==e.position||!i||!["absolute","fixed"].includes(i.position))?i=e:r=r.filter(e=>e!==a),a=Se(a)}return t.set(e,r),r}(t,this._c):[].concat(n),a=[...o,r],s=a[0],l=a.reduce((e,n)=>{const r=_e(t,n,i);return e.top=ee(r.top,e.top),e.right=J(r.right,e.right),e.bottom=J(r.bottom,e.bottom),e.left=ee(r.left,e.left),e},_e(t,s,i));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}},convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{rect:t,offsetParent:n,strategy:r}=e;const i=ae(n),o=ye(n);if(n===o)return t;let a={scrollLeft:0,scrollTop:0},s={x:1,y:1};const l={x:0,y:0};if((i||!i&&"fixed"!==r)&&(("body"!==re(n)||ue(o))&&(a=we(n)),ae(n))){const e=be(n);s=ve(n),l.x=e.x+n.clientLeft,l.y=e.y+n.clientTop}return{width:t.width*s.x,height:t.height*s.y,x:t.x*s.x-a.scrollLeft*s.x+l.x,y:t.y*s.y-a.scrollTop*s.y+l.y}},isElement:se,getDimensions:function(e){return ae(e)?ne(e):e.getBoundingClientRect()},getOffsetParent:Ce,getDocumentElement:ye,getScale:ve,async getElementRects(e){let{reference:t,floating:n,strategy:r}=e;const i=this.getOffsetParent||Ce,o=this.getDimensions;return{reference:Ae(t,await i(n),r),floating:{x:0,y:0,...await o(n)}}},getClientRects:e=>Array.from(e.getClientRects()),isRTL:e=>"rtl"===Z(e).direction};const Re=(e,t,n)=>{const r=new Map,i={platform:Te,...n},o={...i.platform,_c:r};return j(e,t,{...i,platform:o})};var Ne=n(4364);const Pe={disabled:!1,distance:5,skidding:0,container:"body",boundary:void 0,instantMove:!1,disposeTimeout:150,popperTriggers:[],strategy:"absolute",preventOverflow:!0,flip:!0,shift:!0,overflowPadding:0,arrowPadding:0,arrowOverflow:!0,autoHideOnMousedown:!1,themes:{tooltip:{placement:"top",triggers:["hover","focus","touch"],hideTriggers:e=>[...e,"click"],delay:{show:200,hide:0},handleResize:!1,html:!1,loadingContent:"..."},dropdown:{placement:"bottom",triggers:["click"],delay:0,handleResize:!0,autoHide:!0},menu:{$extend:"dropdown",triggers:["hover","focus"],popperTriggers:["hover"],delay:{show:0,hide:400}}}};function Ie(e,t){let n,r=Pe.themes[e]||{};do{n=r[t],typeof n>"u"?r.$extend?r=Pe.themes[r.$extend]||{}:(r=null,n=Pe[t]):r=null}while(r);return n}function Me(e){const t=[e];let n=Pe.themes[e]||{};do{n.$extend&&!n.$resetCss?(t.push(n.$extend),n=Pe.themes[n.$extend]||{}):n=null}while(n);return t.map(e=>`v-popper--theme-${e}`)}function De(e){const t=[e];let n=Pe.themes[e]||{};do{n.$extend?(t.push(n.$extend),n=Pe.themes[n.$extend]||{}):n=null}while(n);return t}let Le=!1;if(typeof window<"u"){Le=!1;try{const e=Object.defineProperty({},"passive",{get(){Le=!0}});window.addEventListener("test",null,e)}catch{}}let Be=!1;typeof window<"u"&&typeof navigator<"u"&&(Be=/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream);const $e=["auto","top","bottom","left","right"].reduce((e,t)=>e.concat([t,`${t}-start`,`${t}-end`]),[]),Ve={hover:"mouseenter",focus:"focus",click:"click",touch:"touchstart",pointer:"pointerdown"},Fe={hover:"mouseleave",focus:"blur",click:"click",touch:"touchend",pointer:"pointerup"};function je(e,t){const n=e.indexOf(t);-1!==n&&e.splice(n,1)}function Ue(){return new Promise(e=>requestAnimationFrame(()=>{requestAnimationFrame(e)}))}const Ge=[];let He=null;const qe={};function Qe(e){let t=qe[e];return t||(t=qe[e]=[]),t}let ze=function(){};function Ke(e){return function(t){return Ie(t.theme,e)}}typeof window<"u"&&(ze=window.Element);const We="__floating-vue__popper",Xe=()=>(0,r.defineComponent)({name:"VPopper",provide(){return{[We]:{parentPopper:this}}},inject:{[We]:{default:null}},props:{theme:{type:String,required:!0},targetNodes:{type:Function,required:!0},referenceNode:{type:Function,default:null},popperNode:{type:Function,required:!0},shown:{type:Boolean,default:!1},showGroup:{type:String,default:null},ariaId:{default:null},disabled:{type:Boolean,default:Ke("disabled")},positioningDisabled:{type:Boolean,default:Ke("positioningDisabled")},placement:{type:String,default:Ke("placement"),validator:e=>$e.includes(e)},delay:{type:[String,Number,Object],default:Ke("delay")},distance:{type:[Number,String],default:Ke("distance")},skidding:{type:[Number,String],default:Ke("skidding")},triggers:{type:Array,default:Ke("triggers")},showTriggers:{type:[Array,Function],default:Ke("showTriggers")},hideTriggers:{type:[Array,Function],default:Ke("hideTriggers")},popperTriggers:{type:Array,default:Ke("popperTriggers")},popperShowTriggers:{type:[Array,Function],default:Ke("popperShowTriggers")},popperHideTriggers:{type:[Array,Function],default:Ke("popperHideTriggers")},container:{type:[String,Object,ze,Boolean],default:Ke("container")},boundary:{type:[String,ze],default:Ke("boundary")},strategy:{type:String,validator:e=>["absolute","fixed"].includes(e),default:Ke("strategy")},autoHide:{type:[Boolean,Function],default:Ke("autoHide")},handleResize:{type:Boolean,default:Ke("handleResize")},instantMove:{type:Boolean,default:Ke("instantMove")},eagerMount:{type:Boolean,default:Ke("eagerMount")},popperClass:{type:[String,Array,Object],default:Ke("popperClass")},computeTransformOrigin:{type:Boolean,default:Ke("computeTransformOrigin")},autoMinSize:{type:Boolean,default:Ke("autoMinSize")},autoSize:{type:[Boolean,String],default:Ke("autoSize")},autoMaxSize:{type:Boolean,default:Ke("autoMaxSize")},autoBoundaryMaxSize:{type:Boolean,default:Ke("autoBoundaryMaxSize")},preventOverflow:{type:Boolean,default:Ke("preventOverflow")},overflowPadding:{type:[Number,String],default:Ke("overflowPadding")},arrowPadding:{type:[Number,String],default:Ke("arrowPadding")},arrowOverflow:{type:Boolean,default:Ke("arrowOverflow")},flip:{type:Boolean,default:Ke("flip")},shift:{type:Boolean,default:Ke("shift")},shiftCrossAxis:{type:Boolean,default:Ke("shiftCrossAxis")},noAutoFocus:{type:Boolean,default:Ke("noAutoFocus")},disposeTimeout:{type:Number,default:Ke("disposeTimeout")}},emits:{show:()=>!0,hide:()=>!0,"update:shown":e=>!0,"apply-show":()=>!0,"apply-hide":()=>!0,"close-group":()=>!0,"close-directive":()=>!0,"auto-hide":()=>!0,resize:()=>!0},data(){return{isShown:!1,isMounted:!1,skipTransition:!1,classes:{showFrom:!1,showTo:!1,hideFrom:!1,hideTo:!0},result:{x:0,y:0,placement:"",strategy:this.strategy,arrow:{x:0,y:0,centerOffset:0},transformOrigin:null},randomId:`popper_${[Math.random(),Date.now()].map(e=>e.toString(36).substring(2,10)).join("_")}`,shownChildren:new Set,lastAutoHide:!0,pendingHide:!1,containsGlobalTarget:!1,isDisposed:!0,mouseDownContains:!1}},computed:{popperId(){return null!=this.ariaId?this.ariaId:this.randomId},shouldMountContent(){return this.eagerMount||this.isMounted},slotData(){return{popperId:this.popperId,isShown:this.isShown,shouldMountContent:this.shouldMountContent,skipTransition:this.skipTransition,autoHide:"function"==typeof this.autoHide?this.lastAutoHide:this.autoHide,show:this.show,hide:this.hide,handleResize:this.handleResize,onResize:this.onResize,classes:{...this.classes,popperClass:this.popperClass},result:this.positioningDisabled?null:this.result,attrs:this.$attrs}},parentPopper(){var e;return null==(e=this[We])?void 0:e.parentPopper},hasPopperShowTriggerHover(){var e,t;return(null==(e=this.popperTriggers)?void 0:e.includes("hover"))||(null==(t=this.popperShowTriggers)?void 0:t.includes("hover"))}},watch:{shown:"$_autoShowHide",disabled(e){e?this.dispose():this.init()},async container(){this.isShown&&(this.$_ensureTeleport(),await this.$_computePosition())},triggers:{handler:"$_refreshListeners",deep:!0},positioningDisabled:"$_refreshListeners",...["placement","distance","skidding","boundary","strategy","overflowPadding","arrowPadding","preventOverflow","shift","shiftCrossAxis","flip"].reduce((e,t)=>(e[t]="$_computePosition",e),{})},created(){this.autoMinSize&&Ne.warn('[floating-vue] `autoMinSize` option is deprecated. Use `autoSize="min"` instead.'),this.autoMaxSize&&Ne.warn("[floating-vue] `autoMaxSize` option is deprecated. Use `autoBoundaryMaxSize` instead.")},mounted(){this.init(),this.$_detachPopperNode()},activated(){this.$_autoShowHide()},deactivated(){this.hide()},beforeUnmount(){this.dispose()},methods:{show({event:e=null,skipDelay:t=!1,force:n=!1}={}){var r,i;null!=(r=this.parentPopper)&&r.lockedChild&&this.parentPopper.lockedChild!==this||(this.pendingHide=!1,(n||!this.disabled)&&((null==(i=this.parentPopper)?void 0:i.lockedChild)===this&&(this.parentPopper.lockedChild=null),this.$_scheduleShow(e,t),this.$emit("show"),this.$_showFrameLocked=!0,requestAnimationFrame(()=>{this.$_showFrameLocked=!1})),this.$emit("update:shown",!0))},hide({event:e=null,skipDelay:t=!1}={}){var n;if(!this.$_hideInProgress){if(this.shownChildren.size>0)return void(this.pendingHide=!0);if(this.hasPopperShowTriggerHover&&this.$_isAimingPopper())return void(this.parentPopper&&(this.parentPopper.lockedChild=this,clearTimeout(this.parentPopper.lockedChildTimer),this.parentPopper.lockedChildTimer=setTimeout(()=>{this.parentPopper.lockedChild===this&&(this.parentPopper.lockedChild.hide({skipDelay:t}),this.parentPopper.lockedChild=null)},1e3)));(null==(n=this.parentPopper)?void 0:n.lockedChild)===this&&(this.parentPopper.lockedChild=null),this.pendingHide=!1,this.$_scheduleHide(e,t),this.$emit("hide"),this.$emit("update:shown",!1)}},init(){var e;this.isDisposed&&(this.isDisposed=!1,this.isMounted=!1,this.$_events=[],this.$_preventShow=!1,this.$_referenceNode=(null==(e=this.referenceNode)?void 0:e.call(this))??this.$el,this.$_targetNodes=this.targetNodes().filter(e=>e.nodeType===e.ELEMENT_NODE),this.$_popperNode=this.popperNode(),this.$_innerNode=this.$_popperNode.querySelector(".v-popper__inner"),this.$_arrowNode=this.$_popperNode.querySelector(".v-popper__arrow-container"),this.$_swapTargetAttrs("title","data-original-title"),this.$_detachPopperNode(),this.triggers.length&&this.$_addEventListeners(),this.shown&&this.show())},dispose(){this.isDisposed||(this.isDisposed=!0,this.$_removeEventListeners(),this.hide({skipDelay:!0}),this.$_detachPopperNode(),this.isMounted=!1,this.isShown=!1,this.$_updateParentShownChildren(!1),this.$_swapTargetAttrs("data-original-title","title"))},async onResize(){this.isShown&&(await this.$_computePosition(),this.$emit("resize"))},async $_computePosition(){if(this.isDisposed||this.positioningDisabled)return;const e={strategy:this.strategy,middleware:[]};(this.distance||this.skidding)&&e.middleware.push(K({mainAxis:this.distance,crossAxis:this.skidding}));const t=this.placement.startsWith("auto");if(t?e.middleware.push(H({alignment:this.placement.split("-")[1]??""})):e.placement=this.placement,this.preventOverflow&&(this.shift&&e.middleware.push(W({padding:this.overflowPadding,boundary:this.boundary,crossAxis:this.shiftCrossAxis})),!t&&this.flip&&e.middleware.push(q({padding:this.overflowPadding,boundary:this.boundary}))),e.middleware.push(U({element:this.$_arrowNode,padding:this.arrowPadding})),this.arrowOverflow&&e.middleware.push({name:"arrowOverflow",fn:({placement:e,rects:t,middlewareData:n})=>{let r;const{centerOffset:i}=n.arrow;return r=e.startsWith("top")||e.startsWith("bottom")?Math.abs(i)>t.reference.width/2:Math.abs(i)>t.reference.height/2,{data:{overflow:r}}}}),this.autoMinSize||this.autoSize){const t=this.autoSize?this.autoSize:this.autoMinSize?"min":null;e.middleware.push({name:"autoSize",fn:({rects:e,placement:n,middlewareData:r})=>{var i;if(null!=(i=r.autoSize)&&i.skip)return{};let o,a;return n.startsWith("top")||n.startsWith("bottom")?o=e.reference.width:a=e.reference.height,this.$_innerNode.style["min"===t?"minWidth":"max"===t?"maxWidth":"width"]=null!=o?`${o}px`:null,this.$_innerNode.style["min"===t?"minHeight":"max"===t?"maxHeight":"height"]=null!=a?`${a}px`:null,{data:{skip:!0},reset:{rects:!0}}}})}(this.autoMaxSize||this.autoBoundaryMaxSize)&&(this.$_innerNode.style.maxWidth=null,this.$_innerNode.style.maxHeight=null,e.middleware.push(X({boundary:this.boundary,padding:this.overflowPadding,apply:({availableWidth:e,availableHeight:t})=>{this.$_innerNode.style.maxWidth=null!=e?`${e}px`:null,this.$_innerNode.style.maxHeight=null!=t?`${t}px`:null}})));const n=await Re(this.$_referenceNode,this.$_popperNode,e);Object.assign(this.result,{x:n.x,y:n.y,placement:n.placement,strategy:n.strategy,arrow:{...n.middlewareData.arrow,...n.middlewareData.arrowOverflow}})},$_scheduleShow(e,t=!1){if(this.$_updateParentShownChildren(!0),this.$_hideInProgress=!1,clearTimeout(this.$_scheduleTimer),He&&this.instantMove&&He.instantMove&&He!==this.parentPopper)return He.$_applyHide(!0),void this.$_applyShow(!0);t?this.$_applyShow():this.$_scheduleTimer=setTimeout(this.$_applyShow.bind(this),this.$_computeDelay("show"))},$_scheduleHide(e,t=!1){this.shownChildren.size>0?this.pendingHide=!0:(this.$_updateParentShownChildren(!1),this.$_hideInProgress=!0,clearTimeout(this.$_scheduleTimer),this.isShown&&(He=this),t?this.$_applyHide():this.$_scheduleTimer=setTimeout(this.$_applyHide.bind(this),this.$_computeDelay("hide")))},$_computeDelay(e){const t=this.delay;return parseInt(t&&t[e]||t||0)},async $_applyShow(e=!1){clearTimeout(this.$_disposeTimer),clearTimeout(this.$_scheduleTimer),this.skipTransition=e,!this.isShown&&(this.$_ensureTeleport(),await Ue(),await this.$_computePosition(),await this.$_applyShowEffect(),this.positioningDisabled||this.$_registerEventListeners([...xe(this.$_referenceNode),...xe(this.$_popperNode)],"scroll",()=>{this.$_computePosition()}))},async $_applyShowEffect(){if(this.$_hideInProgress)return;if(this.computeTransformOrigin){const e=this.$_referenceNode.getBoundingClientRect(),t=this.$_popperNode.querySelector(".v-popper__wrapper"),n=t.parentNode.getBoundingClientRect(),r=e.x+e.width/2-(n.left+t.offsetLeft),i=e.y+e.height/2-(n.top+t.offsetTop);this.result.transformOrigin=`${r}px ${i}px`}this.isShown=!0,this.$_applyAttrsToTarget({"aria-describedby":this.popperId,"data-popper-shown":""});const e=this.showGroup;if(e){let t;for(let n=0;n<Ge.length;n++)t=Ge[n],t.showGroup!==e&&(t.hide(),t.$emit("close-group"))}Ge.push(this),document.body.classList.add("v-popper--some-open");for(const t of De(this.theme))Qe(t).push(this),document.body.classList.add(`v-popper--some-open--${t}`);this.$emit("apply-show"),this.classes.showFrom=!0,this.classes.showTo=!1,this.classes.hideFrom=!1,this.classes.hideTo=!1,await Ue(),this.classes.showFrom=!1,this.classes.showTo=!0,this.noAutoFocus||this.$_popperNode.focus()},async $_applyHide(e=!1){if(this.shownChildren.size>0)return this.pendingHide=!0,void(this.$_hideInProgress=!1);if(clearTimeout(this.$_scheduleTimer),!this.isShown)return;this.skipTransition=e,je(Ge,this),0===Ge.length&&document.body.classList.remove("v-popper--some-open");for(const n of De(this.theme)){const e=Qe(n);je(e,this),0===e.length&&document.body.classList.remove(`v-popper--some-open--${n}`)}He===this&&(He=null),this.isShown=!1,this.$_applyAttrsToTarget({"aria-describedby":void 0,"data-popper-shown":void 0}),clearTimeout(this.$_disposeTimer);const t=this.disposeTimeout;null!==t&&(this.$_disposeTimer=setTimeout(()=>{this.$_popperNode&&(this.$_detachPopperNode(),this.isMounted=!1)},t)),this.$_removeEventListeners("scroll"),this.$emit("apply-hide"),this.classes.showFrom=!1,this.classes.showTo=!1,this.classes.hideFrom=!0,this.classes.hideTo=!1,await Ue(),this.classes.hideFrom=!1,this.classes.hideTo=!0},$_autoShowHide(){this.shown?this.show():this.hide()},$_ensureTeleport(){if(this.isDisposed)return;let e=this.container;if("string"==typeof e?e=window.document.querySelector(e):!1===e&&(e=this.$_targetNodes[0].parentNode),!e)throw new Error("No container for popover: "+this.container);e.appendChild(this.$_popperNode),this.isMounted=!0},$_addEventListeners(){const e=e=>{this.isShown&&!this.$_hideInProgress||(e.usedByTooltip=!0,!this.$_preventShow&&this.show({event:e}))};this.$_registerTriggerListeners(this.$_targetNodes,Ve,this.triggers,this.showTriggers,e),this.$_registerTriggerListeners([this.$_popperNode],Ve,this.popperTriggers,this.popperShowTriggers,e);const t=e=>{e.usedByTooltip||this.hide({event:e})};this.$_registerTriggerListeners(this.$_targetNodes,Fe,this.triggers,this.hideTriggers,t),this.$_registerTriggerListeners([this.$_popperNode],Fe,this.popperTriggers,this.popperHideTriggers,t)},$_registerEventListeners(e,t,n){this.$_events.push({targetNodes:e,eventType:t,handler:n}),e.forEach(e=>e.addEventListener(t,n,Le?{passive:!0}:void 0))},$_registerTriggerListeners(e,t,n,r,i){let o=n;null!=r&&(o="function"==typeof r?r(o):r),o.forEach(n=>{const r=t[n];r&&this.$_registerEventListeners(e,r,i)})},$_removeEventListeners(e){const t=[];this.$_events.forEach(n=>{const{targetNodes:r,eventType:i,handler:o}=n;e&&e!==i?t.push(n):r.forEach(e=>e.removeEventListener(i,o))}),this.$_events=t},$_refreshListeners(){this.isDisposed||(this.$_removeEventListeners(),this.$_addEventListeners())},$_handleGlobalClose(e,t=!1){this.$_showFrameLocked||(this.hide({event:e}),e.closePopover?this.$emit("close-directive"):this.$emit("auto-hide"),t&&(this.$_preventShow=!0,setTimeout(()=>{this.$_preventShow=!1},300)))},$_detachPopperNode(){this.$_popperNode.parentNode&&this.$_popperNode.parentNode.removeChild(this.$_popperNode)},$_swapTargetAttrs(e,t){for(const n of this.$_targetNodes){const r=n.getAttribute(e);r&&(n.removeAttribute(e),n.setAttribute(t,r))}},$_applyAttrsToTarget(e){for(const t of this.$_targetNodes)for(const n in e){const r=e[n];null==r?t.removeAttribute(n):t.setAttribute(n,r)}},$_updateParentShownChildren(e){let t=this.parentPopper;for(;t;)e?t.shownChildren.add(this.randomId):(t.shownChildren.delete(this.randomId),t.pendingHide&&t.hide()),t=t.parentPopper},$_isAimingPopper(){const e=this.$_referenceNode.getBoundingClientRect();if(ot>=e.left&&ot<=e.right&&at>=e.top&&at<=e.bottom){const e=this.$_popperNode.getBoundingClientRect(),t=ot-rt,n=at-it,r=e.left+e.width/2-rt+(e.top+e.height/2)-it+e.width+e.height,i=rt+t*r,o=it+n*r;return st(rt,it,i,o,e.left,e.top,e.left,e.bottom)||st(rt,it,i,o,e.left,e.top,e.right,e.top)||st(rt,it,i,o,e.right,e.top,e.right,e.bottom)||st(rt,it,i,o,e.left,e.bottom,e.right,e.bottom)}return!1}},render(){return this.$slots.default(this.slotData)}});if(typeof document<"u"&&typeof window<"u"){if(Be){const e=!Le||{passive:!0,capture:!0};document.addEventListener("touchstart",e=>Ye(e,!0),e),document.addEventListener("touchend",e=>Ze(e,!0),e)}else window.addEventListener("mousedown",e=>Ye(e,!1),!0),window.addEventListener("click",e=>Ze(e,!1),!0);window.addEventListener("resize",nt)}function Ye(e,t){if(Pe.autoHideOnMousedown)Je(e,t);else for(let n=0;n<Ge.length;n++){const t=Ge[n];try{t.mouseDownContains=t.popperNode().contains(e.target)}catch{}}}function Ze(e,t){Pe.autoHideOnMousedown||Je(e,t)}function Je(e,t){const n={};for(let r=Ge.length-1;r>=0;r--){const i=Ge[r];try{const r=i.containsGlobalTarget=i.mouseDownContains||i.popperNode().contains(e.target);i.pendingHide=!1,requestAnimationFrame(()=>{if(i.pendingHide=!1,!n[i.randomId]&&et(i,r,e)){if(i.$_handleGlobalClose(e,t),!e.closeAllPopover&&e.closePopover&&r){let e=i.parentPopper;for(;e;)n[e.randomId]=!0,e=e.parentPopper;return}let o=i.parentPopper;for(;o&&et(o,o.containsGlobalTarget,e);)o.$_handleGlobalClose(e,t),o=o.parentPopper}})}catch{}}}function et(e,t,n){return n.closeAllPopover||n.closePopover&&t||tt(e,n)&&!t}function tt(e,t){if("function"==typeof e.autoHide){const n=e.autoHide(t);return e.lastAutoHide=n,n}return e.autoHide}function nt(){for(let e=0;e<Ge.length;e++)Ge[e].$_computePosition()}let rt=0,it=0,ot=0,at=0;function st(e,t,n,r,i,o,a,s){const l=((a-i)*(t-o)-(s-o)*(e-i))/((s-o)*(n-e)-(a-i)*(r-t)),c=((n-e)*(t-o)-(r-t)*(e-i))/((s-o)*(n-e)-(a-i)*(r-t));return l>=0&&l<=1&&c>=0&&c<=1}typeof window<"u"&&window.addEventListener("mousemove",e=>{rt=ot,it=at,ot=e.clientX,at=e.clientY},Le?{passive:!0}:void 0);const lt={extends:Xe()},ct=(e,t)=>{const n=e.__vccOpts||e;for(const[r,i]of t)n[r]=i;return n};function ut(e,t,n,i,o,a){return(0,r.openBlock)(),(0,r.createElementBlock)("div",{ref:"reference",class:(0,r.normalizeClass)(["v-popper",{"v-popper--shown":e.slotData.isShown}])},[(0,r.renderSlot)(e.$slots,"default",(0,r.normalizeProps)((0,r.guardReactiveProps)(e.slotData)))],2)}const dt=ct(lt,[["render",ut]]);function ht(){var e=window.navigator.userAgent,t=e.indexOf("MSIE ");if(t>0)return parseInt(e.substring(t+5,e.indexOf(".",t)),10);var n=e.indexOf("Trident/");if(n>0){var r=e.indexOf("rv:");return parseInt(e.substring(r+3,e.indexOf(".",r)),10)}var i=e.indexOf("Edge/");return i>0?parseInt(e.substring(i+5,e.indexOf(".",i)),10):-1}let pt;function ft(){ft.init||(ft.init=!0,pt=-1!==ht())}var mt={name:"ResizeObserver",props:{emitOnMount:{type:Boolean,default:!1},ignoreWidth:{type:Boolean,default:!1},ignoreHeight:{type:Boolean,default:!1}},emits:["notify"],mounted(){ft(),(0,r.nextTick)(()=>{this._w=this.$el.offsetWidth,this._h=this.$el.offsetHeight,this.emitOnMount&&this.emitSize()});const e=document.createElement("object");this._resizeObject=e,e.setAttribute("aria-hidden","true"),e.setAttribute("tabindex",-1),e.onload=this.addResizeHandlers,e.type="text/html",pt&&this.$el.appendChild(e),e.data="about:blank",pt||this.$el.appendChild(e)},beforeUnmount(){this.removeResizeHandlers()},methods:{compareAndNotify(){(!this.ignoreWidth&&this._w!==this.$el.offsetWidth||!this.ignoreHeight&&this._h!==this.$el.offsetHeight)&&(this._w=this.$el.offsetWidth,this._h=this.$el.offsetHeight,this.emitSize())},emitSize(){this.$emit("notify",{width:this._w,height:this._h})},addResizeHandlers(){this._resizeObject.contentDocument.defaultView.addEventListener("resize",this.compareAndNotify),this.compareAndNotify()},removeResizeHandlers(){this._resizeObject&&this._resizeObject.onload&&(!pt&&this._resizeObject.contentDocument&&this._resizeObject.contentDocument.defaultView.removeEventListener("resize",this.compareAndNotify),this.$el.removeChild(this._resizeObject),this._resizeObject.onload=null,this._resizeObject=null)}}};const gt=(0,r.withScopeId)("data-v-b329ee4c");(0,r.pushScopeId)("data-v-b329ee4c");const vt={class:"resize-observer",tabindex:"-1"};(0,r.popScopeId)();const bt=gt((e,t,n,i,o,a)=>((0,r.openBlock)(),(0,r.createBlock)("div",vt)));mt.render=bt,mt.__scopeId="data-v-b329ee4c",mt.__file="src/components/ResizeObserver.vue";const yt=(e="theme")=>({computed:{themeClass(){return Me(this[e])}}}),wt=(0,r.defineComponent)({name:"VPopperContent",components:{ResizeObserver:mt},mixins:[yt()],props:{popperId:String,theme:String,shown:Boolean,mounted:Boolean,skipTransition:Boolean,autoHide:Boolean,handleResize:Boolean,classes:Object,result:Object},emits:["hide","resize"],methods:{toPx(e){return null==e||isNaN(e)?null:`${e}px`}}}),Ot=["id","aria-hidden","tabindex","data-popper-placement"],St={ref:"inner",class:"v-popper__inner"},Et=(0,r.createElementVNode)("div",{class:"v-popper__arrow-outer"},null,-1),xt=(0,r.createElementVNode)("div",{class:"v-popper__arrow-inner"},null,-1),_t=[Et,xt];function kt(e,t,n,i,o,a){const s=(0,r.resolveComponent)("ResizeObserver");return(0,r.openBlock)(),(0,r.createElementBlock)("div",{id:e.popperId,ref:"popover",class:(0,r.normalizeClass)(["v-popper__popper",[e.themeClass,e.classes.popperClass,{"v-popper__popper--shown":e.shown,"v-popper__popper--hidden":!e.shown,"v-popper__popper--show-from":e.classes.showFrom,"v-popper__popper--show-to":e.classes.showTo,"v-popper__popper--hide-from":e.classes.hideFrom,"v-popper__popper--hide-to":e.classes.hideTo,"v-popper__popper--skip-transition":e.skipTransition,"v-popper__popper--arrow-overflow":e.result&&e.result.arrow.overflow,"v-popper__popper--no-positioning":!e.result}]]),style:(0,r.normalizeStyle)(e.result?{position:e.result.strategy,transform:`translate3d(${Math.round(e.result.x)}px,${Math.round(e.result.y)}px,0)`}:void 0),"aria-hidden":e.shown?"false":"true",tabindex:e.autoHide?0:void 0,"data-popper-placement":e.result?e.result.placement:void 0,onKeyup:t[2]||(t[2]=(0,r.withKeys)(t=>e.autoHide&&e.$emit("hide"),["esc"]))},[(0,r.createElementVNode)("div",{class:"v-popper__backdrop",onClick:t[0]||(t[0]=t=>e.autoHide&&e.$emit("hide"))}),(0,r.createElementVNode)("div",{class:"v-popper__wrapper",style:(0,r.normalizeStyle)(e.result?{transformOrigin:e.result.transformOrigin}:void 0)},[(0,r.createElementVNode)("div",St,[e.mounted?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:0},[(0,r.createElementVNode)("div",null,[(0,r.renderSlot)(e.$slots,"default")]),e.handleResize?((0,r.openBlock)(),(0,r.createBlock)(s,{key:0,onNotify:t[1]||(t[1]=t=>e.$emit("resize",t))})):(0,r.createCommentVNode)("",!0)],64)):(0,r.createCommentVNode)("",!0)],512),(0,r.createElementVNode)("div",{ref:"arrow",class:"v-popper__arrow-container",style:(0,r.normalizeStyle)(e.result?{left:e.toPx(e.result.arrow.x),top:e.toPx(e.result.arrow.y)}:void 0)},_t,4)],4)],46,Ot)}const Ct=ct(wt,[["render",kt]]),At={methods:{show(...e){return this.$refs.popper.show(...e)},hide(...e){return this.$refs.popper.hide(...e)},dispose(...e){return this.$refs.popper.dispose(...e)},onResize(...e){return this.$refs.popper.onResize(...e)}}};let Tt=function(){};typeof window<"u"&&(Tt=window.Element);const Rt=(0,r.defineComponent)({name:"VPopperWrapper",components:{Popper:dt,PopperContent:Ct},mixins:[At,yt("finalTheme")],props:{theme:{type:String,default:null},referenceNode:{type:Function,default:null},shown:{type:Boolean,default:!1},showGroup:{type:String,default:null},ariaId:{default:null},disabled:{type:Boolean,default:void 0},positioningDisabled:{type:Boolean,default:void 0},placement:{type:String,default:void 0},delay:{type:[String,Number,Object],default:void 0},distance:{type:[Number,String],default:void 0},skidding:{type:[Number,String],default:void 0},triggers:{type:Array,default:void 0},showTriggers:{type:[Array,Function],default:void 0},hideTriggers:{type:[Array,Function],default:void 0},popperTriggers:{type:Array,default:void 0},popperShowTriggers:{type:[Array,Function],default:void 0},popperHideTriggers:{type:[Array,Function],default:void 0},container:{type:[String,Object,Tt,Boolean],default:void 0},boundary:{type:[String,Tt],default:void 0},strategy:{type:String,default:void 0},autoHide:{type:[Boolean,Function],default:void 0},handleResize:{type:Boolean,default:void 0},instantMove:{type:Boolean,default:void 0},eagerMount:{type:Boolean,default:void 0},popperClass:{type:[String,Array,Object],default:void 0},computeTransformOrigin:{type:Boolean,default:void 0},autoMinSize:{type:Boolean,default:void 0},autoSize:{type:[Boolean,String],default:void 0},autoMaxSize:{type:Boolean,default:void 0},autoBoundaryMaxSize:{type:Boolean,default:void 0},preventOverflow:{type:Boolean,default:void 0},overflowPadding:{type:[Number,String],default:void 0},arrowPadding:{type:[Number,String],default:void 0},arrowOverflow:{type:Boolean,default:void 0},flip:{type:Boolean,default:void 0},shift:{type:Boolean,default:void 0},shiftCrossAxis:{type:Boolean,default:void 0},noAutoFocus:{type:Boolean,default:void 0},disposeTimeout:{type:Number,default:void 0}},emits:{show:()=>!0,hide:()=>!0,"update:shown":e=>!0,"apply-show":()=>!0,"apply-hide":()=>!0,"close-group":()=>!0,"close-directive":()=>!0,"auto-hide":()=>!0,resize:()=>!0},computed:{finalTheme(){return this.theme??this.$options.vPopperTheme}},methods:{getTargetNodes(){return Array.from(this.$el.children).filter(e=>e!==this.$refs.popperContent.$el)}}});function Nt(e,t,n,i,o,a){const s=(0,r.resolveComponent)("PopperContent"),l=(0,r.resolveComponent)("Popper");return(0,r.openBlock)(),(0,r.createBlock)(l,(0,r.mergeProps)({ref:"popper"},e.$props,{theme:e.finalTheme,"target-nodes":e.getTargetNodes,"popper-node":()=>e.$refs.popperContent.$el,class:[e.themeClass],onShow:t[0]||(t[0]=()=>e.$emit("show")),onHide:t[1]||(t[1]=()=>e.$emit("hide")),"onUpdate:shown":t[2]||(t[2]=t=>e.$emit("update:shown",t)),onApplyShow:t[3]||(t[3]=()=>e.$emit("apply-show")),onApplyHide:t[4]||(t[4]=()=>e.$emit("apply-hide")),onCloseGroup:t[5]||(t[5]=()=>e.$emit("close-group")),onCloseDirective:t[6]||(t[6]=()=>e.$emit("close-directive")),onAutoHide:t[7]||(t[7]=()=>e.$emit("auto-hide")),onResize:t[8]||(t[8]=()=>e.$emit("resize"))}),{default:(0,r.withCtx)(({popperId:t,isShown:n,shouldMountContent:i,skipTransition:o,autoHide:a,show:l,hide:c,handleResize:u,onResize:d,classes:h,result:p})=>[(0,r.renderSlot)(e.$slots,"default",{shown:n,show:l,hide:c}),(0,r.createVNode)(s,{ref:"popperContent","popper-id":t,theme:e.finalTheme,shown:n,mounted:i,"skip-transition":o,"auto-hide":a,"handle-resize":u,classes:h,result:p,onHide:c,onResize:d},{default:(0,r.withCtx)(()=>[(0,r.renderSlot)(e.$slots,"popper",{shown:n,hide:c})]),_:2},1032,["popper-id","theme","shown","mounted","skip-transition","auto-hide","handle-resize","classes","result","onHide","onResize"])]),_:3},16,["theme","target-nodes","popper-node","class"])}const Pt=ct(Rt,[["render",Nt]]);(0,r.defineComponent)({name:"VTooltipDirective",components:{Popper:Xe(),PopperContent:Ct},mixins:[At],inheritAttrs:!1,props:{theme:{type:String,default:"tooltip"},html:{type:Boolean,default:e=>Ie(e.theme,"html")},content:{type:[String,Number,Function],default:null},loadingContent:{type:String,default:e=>Ie(e.theme,"loadingContent")},targetNodes:{type:Function,required:!0}},data(){return{asyncContent:null}},computed:{isContentAsync(){return"function"==typeof this.content},loading(){return this.isContentAsync&&null==this.asyncContent},finalContent(){return this.isContentAsync?this.loading?this.loadingContent:this.asyncContent:this.content}},watch:{content:{handler(){this.fetchContent(!0)},immediate:!0},async finalContent(){await this.$nextTick(),this.$refs.popper.onResize()}},created(){this.$_fetchId=0},methods:{fetchContent(e){if("function"==typeof this.content&&this.$_isShown&&(e||!this.$_loading&&null==this.asyncContent)){this.asyncContent=null,this.$_loading=!0;const e=++this.$_fetchId,t=this.content(this);t.then?t.then(t=>this.onResult(e,t)):this.onResult(e,t)}},onResult(e,t){e===this.$_fetchId&&(this.$_loading=!1,this.asyncContent=t)},onShow(){this.$_isShown=!0,this.fetchContent()},onHide(){this.$_isShown=!1}}});const It=16,Mt=e=>{let t=0,n=window.innerHeight;for(let r=e.parentElement;r&&r!==document.body;r=r.parentElement)if(/auto|scroll|hidden|clip/.test(getComputedStyle(r).overflowY)){const e=r.getBoundingClientRect();t=Math.max(t,e.top),n=Math.min(n,e.bottom)}return{top:t,bottom:n}},Dt=(e,t,n)=>{const i=(0,r.ref)(0),o=()=>{var r,i;const o=e(),a=null===(r=t.value)||void 0===r?void 0:r.row(),s=(null===(i=n.value)||void 0===i?void 0:i.closest(".v-popper__popper"))||n.value;return o&&a&&s?{box:o,row:a,popper:s}:null},a=()=>{var e;const t=o();if(!t)return;const n=Mt(t.popper),r=Math.max(n.bottom-It,t.row.getBoundingClientRect().bottom);null===(e=t.popper.querySelector(".v-popper__inner"))||void 0===e||e.style.setProperty("max-height",r-n.top-It+"px")},s=()=>{const e=o();if(!e)return void(i.value=0);const t=Mt(e.popper),{top:n}=e.box.getBoundingClientRect(),{height:r}=e.popper.getBoundingClientRect();i.value=Math.max(0,Math.min(n+r+It-t.bottom,n+r-e.row.getBoundingClientRect().bottom))},l=()=>{a(),s()};let c=0;const u=()=>{cancelAnimationFrame(c),c=requestAnimationFrame(()=>{l(),nt()})},d=()=>{cancelAnimationFrame(c),document.removeEventListener("scroll",s,!0),window.removeEventListener("resize",u)},h=()=>{l(),d(),document.addEventListener("scroll",s,{capture:!0,passive:!0}),window.addEventListener("resize",u,{passive:!0})};return(0,r.onBeforeUnmount)(d),(0,r.watch)(t,(e,t)=>{e&&t&&(0,r.nextTick)(l)}),{submenuLift:i,start:h,stop:d}},Lt=["aria-label"],Bt=["id","aria-labelledby"];var $t=(0,r.defineComponent)({__name:"RcDropdown",props:{ariaLabel:{},distance:{},referenceNode:{},open:{type:Boolean,default:!1},placement:{default:"bottom-end"}},emits:["update:open"],setup(e,{emit:t}){const n=e,o=t,{isMenuOpen:a,showMenu:s,returnFocus:l,setFocus:d,provideDropdownContext:h,registerDropdownCollection:p,handleKeydown:f,setDropdownDimensions:m,submenus:g,SubmenuContent:v}=u(o),{submenuId:b,submenus:y,activeSubmenu:w,shownSubmenu:O,submenuTarget:S,cancelSubmenuSwitch:E,refreshSubmenuItems:x,onSubmenuShown:_,onSubmenuKeydown:k}=g;h();const C=(0,r.ref)(null),A=(0,r.ref)(null);(0,r.watch)(()=>n.open,e=>{var t;e!==a.value&&(e?(c()&&f(),s(!0)):(null===(t=C.value)||void 0===t?void 0:t.contains(document.activeElement))?l():s(!1))},{immediate:!0}),(0,i.L)(A,()=>s(!1),{ignore:[".rc-dropdown-submenu"]});const T=e=>{var t;const n=e.target;return!!A.value&&(null===(t=null===n||void 0===n?void 0:n.closest)||void 0===t?void 0:t.call(n,"[dropdown-menu-collection]"))===A.value},R=e=>{T(e)&&f()},N=(e,t)=>{T(e)&&(e.preventDefault(),d(t))},P=e=>{T(e)&&s(!1)},I=e=>{T(e)&&l()},M=(0,r.ref)(0),D=()=>{var e;return(null===(e=A.value)||void 0===e?void 0:e.closest(".v-popper__popper"))||A.value},{submenuLift:L,start:B,stop:$}=Dt(D,O,S),V=()=>{B(),_()},F=()=>{const e=D();M.value=e&&parseFloat(getComputedStyle(e).borderTopWidth)||0,m(A.value),p(A.value),d("down")};return(t,n)=>{const i=(0,r.resolveComponent)("v-dropdown");return(0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,null,[(0,r.createVNode)(i,{"no-auto-focus":"",triggers:[],shown:(0,r.unref)(a),"auto-hide":!1,container:C.value,placement:e.placement,distance:e.distance,"reference-node":e.referenceNode,onApplyShow:F},{popper:(0,r.withCtx)(()=>{var o;return[(0,r.createElementVNode)("div",{ref_key:"dropdownTarget",ref:A,class:"dropdownTarget",tabindex:"-1",role:"menu","aria-orientation":"vertical","dropdown-menu-collection":"","aria-label":e.ariaLabel||"Dropdown Menu",onKeydown:[R,n[0]||(n[0]=(0,r.withKeys)(e=>N(e,"down"),["down"])),n[1]||(n[1]=(0,r.withKeys)(e=>N(e,"up"),["up"]))]},[(0,r.renderSlot)(t.$slots,"dropdownCollection")],40,Lt),(0,r.unref)(y).length?((0,r.openBlock)(),(0,r.createBlock)(i,{key:0,"no-auto-focus":"",triggers:[],shown:!!(0,r.unref)(w),"auto-hide":!1,container:C.value,placement:"left"===(null===(o=(0,r.unref)(O))||void 0===o?void 0:o.side)?"left-start":"right-start",distance:-M.value,flip:!1,shift:!1,skidding:-(0,r.unref)(L),"popper-class":"rc-dropdown-submenu","reference-node":D,onApplyShow:V,onApplyHide:(0,r.unref)($)},{popper:(0,r.withCtx)(()=>{var e;return[(0,r.createElementVNode)("div",{id:(0,r.unref)(b),ref_key:"submenuTarget",ref:S,class:"dropdownTarget",tabindex:"-1",role:"menu","aria-orientation":"vertical","dropdown-menu-collection":"","aria-labelledby":null===(e=(0,r.unref)(O))||void 0===e?void 0:e.labelId,onKeydownCapture:n[2]||(n[2]=(...e)=>(0,r.unref)(x)&&(0,r.unref)(x)(...e)),onKeydown:n[3]||(n[3]=(...e)=>(0,r.unref)(k)&&(0,r.unref)(k)(...e)),onMouseenter:n[4]||(n[4]=(...e)=>(0,r.unref)(E)&&(0,r.unref)(E)(...e))},[(0,r.unref)(O)?((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(v),{key:(0,r.unref)(O).labelId,submenu:(0,r.unref)(O)},null,8,["submenu"])):(0,r.createCommentVNode)("",!0)],40,Bt)]}),_:1},8,["shown","container","placement","distance","skidding","onApplyHide"])):(0,r.createCommentVNode)("",!0)]}),default:(0,r.withCtx)(()=>[(0,r.renderSlot)(t.$slots,"default")]),_:3},8,["shown","container","placement","distance","reference-node"]),(0,r.createElementVNode)("div",{ref_key:"popperContainer",ref:C,class:"popperContainer",onKeydown:[(0,r.withKeys)(P,["tab"]),(0,r.withKeys)(I,["escape"])]},null,544)],64)}}}),Vt=(n(66511),n(47433));const Ft=(0,Vt.A)($t,[["__scopeId","data-v-40d040dc"]]);var jt=Ft;n(44738);const Ut={handleKeydown:()=>null,showMenu:e=>null,registerTrigger:e=>null,dropdownItems:(0,r.ref)([]),focusFirstElement:()=>null,isMenuOpen:(0,r.ref)(!1),close:()=>null,submenuId:"",activeSubmenu:(0,r.ref)(null),registerSubmenu:()=>()=>null,openSubmenu:()=>null,hoverSubmenu:()=>null,cancelSubmenuSwitch:()=>null,inSubmenu:!1},Gt=()=>{const{dropdownItems:e,close:t,hoverSubmenu:n}=(0,r.inject)("dropdownContext")||Ut,i=t=>{if(t.altKey||t.ctrlKey||t.metaKey)return;const n=document.activeElement,r=e.value.indexOf(n||new HTMLElement);if(r<0)return;const i="ArrowDown"===t.key,a=o(i,r,e.value);e.value[a]instanceof HTMLElement&&e.value[a].focus()},o=(e,t,n)=>{const r=e?t+1:t-1;return r>n.length-1?0:r<0?n.length-1:r},a=e=>{var t;(null===e||void 0===e?void 0:e.target)===(null===e||void 0===e?void 0:e.currentTarget)&&e.preventDefault(),(null===e||void 0===e?void 0:e.target)instanceof HTMLElement&&(null===(t=null===e||void 0===e?void 0:e.target)||void 0===t||t.click())},s=e=>{const t=e.target;if(!(t instanceof HTMLElement))return;const n=t;"BUTTON"!==n.tagName&&(null===t||void 0===t||t.scrollIntoView({behavior:"smooth",block:"nearest",inline:"nearest"}))},l=()=>n(null);return{handleKeydown:i,close:t,handleActivate:a,scrollIntoView:s,handleMouseenter:l}},Ht=["disabled","aria-disabled"],qt={key:0,class:"dropdown-item-after"};var Qt=(0,r.defineComponent)({__name:"RcDropdownItem",props:{disabled:Boolean,actsOnCheckableItems:Boolean},emits:["click"],setup(e,{emit:t}){const n=e,i=t,{handleKeydown:o,close:a,handleActivate:s,scrollIntoView:l,handleMouseenter:c}=Gt(),u=e=>{n.disabled||(i("click",e),n.actsOnCheckableItems||a())};return(t,n)=>((0,r.openBlock)(),(0,r.createElementBlock)("div",{ref:"dropdownMenuItem","dropdown-menu-item":"",tabindex:"-1",role:"menuitem",disabled:e.disabled||null,"aria-disabled":e.disabled||!1,onClick:(0,r.withModifiers)(u,["stop"]),onKeydown:[n[0]||(n[0]=(0,r.withKeys)((...e)=>(0,r.unref)(s)&&(0,r.unref)(s)(...e),["enter","space"])),n[1]||(n[1]=(0,r.withKeys)((0,r.withModifiers)((...e)=>(0,r.unref)(o)&&(0,r.unref)(o)(...e),["prevent","stop"]),["up","down"]))],onMousedown:(0,r.withModifiers)(()=>{},["prevent"]),onFocusin:n[2]||(n[2]=(...e)=>(0,r.unref)(l)&&(0,r.unref)(l)(...e)),onMouseenter:n[3]||(n[3]=(...e)=>(0,r.unref)(c)&&(0,r.unref)(c)(...e))},[(0,r.renderSlot)(t.$slots,"before"),(0,r.renderSlot)(t.$slots,"default"),t.$slots.after?((0,r.openBlock)(),(0,r.createElementBlock)("span",qt,[(0,r.renderSlot)(t.$slots,"after")])):(0,r.createCommentVNode)("",!0)],40,Ht))}});n(68954);const zt=(0,Vt.A)(Qt,[["__scopeId","data-v-4347a406"]]);var Kt=zt,Wt=n(42200),Xt=n(47799);const Yt=["aria-checked","disabled","aria-disabled"],Zt={class:"dropdown-item-after"};var Jt=(0,r.defineComponent)({__name:"RcDropdownItemCheckbox",props:{modelValue:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},indicator:{default:"checkbox"}},emits:["click","update:modelValue"],setup(e,{emit:t}){const n=e,i=t,{handleKeydown:o,handleActivate:a,scrollIntoView:s,handleMouseenter:l}=Gt(),c=()=>{n.disabled||(i("click",!n.modelValue),i("update:modelValue",!n.modelValue))};return(t,n)=>((0,r.openBlock)(),(0,r.createElementBlock)("div",{ref:"dropdownMenuItem","dropdown-menu-item":"",tabindex:"-1",role:"menuitemcheckbox","aria-checked":e.modelValue,disabled:e.disabled||null,"aria-disabled":e.disabled||!1,onClick:(0,r.withModifiers)(c,["stop"]),onKeydown:[n[0]||(n[0]=(0,r.withKeys)((...e)=>(0,r.unref)(a)&&(0,r.unref)(a)(...e),["enter","space"])),n[1]||(n[1]=(0,r.withKeys)((0,r.withModifiers)((...e)=>(0,r.unref)(o)&&(0,r.unref)(o)(...e),["prevent","stop"]),["up","down"]))],onMousedown:(0,r.withModifiers)(()=>{},["prevent"]),onFocusin:n[2]||(n[2]=(...e)=>(0,r.unref)(s)&&(0,r.unref)(s)(...e)),onMouseenter:n[3]||(n[3]=(...e)=>(0,r.unref)(l)&&(0,r.unref)(l)(...e))},["checkmark"===e.indicator?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:0},[(0,r.renderSlot)(t.$slots,"before"),(0,r.renderSlot)(t.$slots,"default"),(0,r.createElementVNode)("span",Zt,[e.modelValue?((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(Xt.A),{key:0,type:"checkmark",size:"inherit"})):(0,r.createCommentVNode)("",!0)])],64)):((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(Wt.S),{key:1,value:e.modelValue},{label:(0,r.withCtx)(()=>[(0,r.renderSlot)(t.$slots,"default")]),_:3},8,["value"]))],40,Yt))}});n(3857);const en=(0,Vt.A)(Jt,[["__scopeId","data-v-278e9673"]]);var tn=en;const nn=["aria-checked","disabled","aria-disabled"],rn={class:"dropdown-item-after"};var on=(0,r.defineComponent)({__name:"RcDropdownItemRadio",props:{checked:Boolean,disabled:Boolean},emits:["click"],setup(e,{emit:t}){const n=e,i=t,{handleKeydown:o,handleActivate:a,scrollIntoView:s,handleMouseenter:l}=Gt(),c=e=>{n.disabled||i("click",e)};return(t,n)=>((0,r.openBlock)(),(0,r.createElementBlock)("div",{"dropdown-menu-item":"",tabindex:"-1",role:"menuitemradio","aria-checked":e.checked,disabled:e.disabled||null,"aria-disabled":e.disabled||!1,onClick:(0,r.withModifiers)(c,["stop"]),onKeydown:[n[0]||(n[0]=(0,r.withKeys)((...e)=>(0,r.unref)(a)&&(0,r.unref)(a)(...e),["enter","space"])),n[1]||(n[1]=(0,r.withKeys)((0,r.withModifiers)((...e)=>(0,r.unref)(o)&&(0,r.unref)(o)(...e),["prevent","stop"]),["up","down"]))],onMousedown:(0,r.withModifiers)(()=>{},["prevent"]),onFocusin:n[2]||(n[2]=(...e)=>(0,r.unref)(s)&&(0,r.unref)(s)(...e)),onMouseenter:n[3]||(n[3]=(...e)=>(0,r.unref)(l)&&(0,r.unref)(l)(...e))},[(0,r.renderSlot)(t.$slots,"before"),(0,r.renderSlot)(t.$slots,"default"),(0,r.createElementVNode)("span",rn,[e.checked?((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(Xt.A),{key:0,type:"checkmark",size:"inherit"})):(0,r.createCommentVNode)("",!0)])],40,nn))}});n(74236);const an=(0,Vt.A)(on,[["__scopeId","data-v-045833c6"]]);var sn=an,ln=n(49452);const cn=["disabled","aria-disabled"];Boolean,n(607);var un=n(30342),dn=(0,r.defineComponent)({__name:"RcDropdownSeparator",setup(e){return(e,t)=>((0,r.openBlock)(),(0,r.createBlock)(un.A,{decorative:!1}))}});const hn=dn;var pn=hn;const fn=["aria-expanded","aria-controls","disabled","aria-disabled"],mn={class:"dropdown-item-after"};var gn=(0,r.defineComponent)({__name:"RcDropdownSubmenu",props:{side:{default:"right"},disabled:{type:Boolean,default:!1}},setup(e){const t=e,{submenuId:n,activeSubmenu:i,registerSubmenu:o,openSubmenu:a,hoverSubmenu:s,cancelSubmenuSwitch:l,inSubmenu:c}=(0,r.inject)("dropdownContext")||Ut;const{handleKeydown:u,scrollIntoView:d}=Gt(),h=(0,r.useSlots)(),p=`rc-dropdown-submenu-item-${(0,r.useId)()}`,f=`${p}-label`,m=(0,r.ref)(null),g={get side(){return t.side},row:()=>m.value,labelId:f,render:()=>{var e;return null===(e=h.submenu)||void 0===e?void 0:e.call(h)}};(0,r.onBeforeUnmount)(o(g));const v=(0,r.computed)(()=>i.value===g),b=e=>{t.disabled||a(g,e)},y=e=>{if(e.altKey||e.ctrlKey||e.metaKey)return;const n="Enter"===e.key||" "===e.key||"ArrowRight"===e.key||"left"===t.side&&"ArrowLeft"===e.key;n&&(e.preventDefault(),e.stopPropagation(),b(!0))};return(t,i)=>(0,r.unref)(c)?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:0,id:p,ref_key:"row",ref:m,"dropdown-menu-item":"",tabindex:"-1",role:"menuitem","aria-haspopup":"menu","aria-expanded":v.value,"aria-controls":v.value?(0,r.unref)(n):void 0,class:(0,r.normalizeClass)({expanded:v.value}),disabled:e.disabled||null,"aria-disabled":e.disabled||!1,onClick:i[0]||(i[0]=(0,r.withModifiers)(e=>b(!1),["stop"])),onKeydown:[y,i[1]||(i[1]=(0,r.withKeys)((0,r.withModifiers)((...e)=>(0,r.unref)(u)&&(0,r.unref)(u)(...e),["prevent","stop"]),["up","down"]))],onMousedown:(0,r.withModifiers)(()=>{},["prevent"]),onMouseenter:i[2]||(i[2]=t=>!e.disabled&&(0,r.unref)(s)(g)),onMouseleave:i[3]||(i[3]=e=>(0,r.unref)(l)()),onFocusin:i[4]||(i[4]=(...e)=>(0,r.unref)(d)&&(0,r.unref)(d)(...e))},[(0,r.renderSlot)(t.$slots,"before"),(0,r.createElementVNode)("span",{id:f},[(0,r.renderSlot)(t.$slots,"default")]),(0,r.createElementVNode)("span",mn,[(0,r.renderSlot)(t.$slots,"after"),(0,r.createVNode)((0,r.unref)(Xt.A),{type:"chevron-right",size:"inherit"})])],42,fn))}});n(21197);const vn=(0,Vt.A)(gn,[["__scopeId","data-v-5423a193"]]);var bn=vn,yn=n(51433),wn=(0,r.defineComponent)({__name:"RcDropdownTrigger",props:{size:{}},setup(e,{expose:t}){const{showMenu:n,registerTrigger:i,isMenuOpen:o,handleKeydown:a}=(0,r.inject)("dropdownContext")||Ut,s=(0,r.ref)(null);(0,r.onMounted)(()=>{i(s.value)});const l=()=>{var e;null===(e=null===s||void 0===s?void 0:s.value)||void 0===e||e.focus()};return t({focus:l}),(t,i)=>((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(yn.a),{ref_key:"dropdownTrigger",ref:s,role:"button","aria-haspopup":"menu","aria-expanded":(0,r.unref)(o),size:e.size,onKeydown:(0,r.withKeys)((0,r.unref)(a),["enter","space"]),onClick:i[0]||(i[0]=e=>(0,r.unref)(n)(!0))},(0,r.createSlots)({default:(0,r.withCtx)(()=>[(0,r.renderSlot)(t.$slots,"default")]),_:2},[t.$slots.before?{name:"before",fn:(0,r.withCtx)(()=>[(0,r.renderSlot)(t.$slots,"before")]),key:"0"}:void 0,t.$slots.after?{name:"after",fn:(0,r.withCtx)(()=>[(0,r.renderSlot)(t.$slots,"after")]),key:"1"}:void 0]),1032,["aria-expanded","size","onKeydown"]))}});const On=wn;var Sn=On,En=n(74607),xn=(0,r.defineComponent)({__name:"RcDropdownMenu",props:{options:{},buttonVariant:{default:"primary"},buttonSize:{default:void 0},buttonAriaLabel:{},dropdownAriaLabel:{},dataTestid:{}},emits:["update:open","select"],setup(e,{emit:t}){const n=t,i=e=>void 0!==e.length?e.length:Object.keys(e).length>0;return(t,o)=>((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(jt),{"aria-label":e.dropdownAriaLabel,"onUpdate:open":o[0]||(o[0]=e=>n("update:open",e))},{dropdownCollection:(0,r.withCtx)(()=>[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(e.options,e=>((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:e.label},[e.divider?((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(pn),{key:1})):((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(Kt),{key:0,onClick:t=>n("select",t,e)},{before:(0,r.withCtx)(()=>[e.icon||e.svg?((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(En.A),{key:0,icon:e.icon,src:e.svg,class:"icon",color:"header"},null,8,["icon","src"])):(0,r.createCommentVNode)("",!0)]),default:(0,r.withCtx)(()=>[(0,r.createTextVNode)(" "+(0,r.toDisplayString)(e.label),1)]),_:2},1032,["onClick"]))],64))),128)),i(e.options)?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(Kt),{key:0,disabled:""},{default:(0,r.withCtx)(()=>[...o[2]||(o[2]=[(0,r.createTextVNode)(" No actions available ",-1)])]),_:1}))]),default:(0,r.withCtx)(()=>[(0,r.createVNode)((0,r.unref)(Sn),{variant:e.buttonVariant,size:e.buttonSize,"data-testid":e.dataTestid,"aria-label":e.buttonAriaLabel},{default:(0,r.withCtx)(()=>[...o[1]||(o[1]=[(0,r.createElementVNode)("i",{class:"icon icon-actions"},null,-1)])]),_:1},8,["variant","size","data-testid","aria-label"])]),_:1},8,["aria-label"]))}});const _n=xn;var kn=_n},25509:function(e,t,n){"use strict";n.d(t,{m:function(){return r.A}});var r=n(48989)},82110:function(e,t,n){"use strict";n.d(t,{S:function(){return c}});var r=n(9274),i=n(71126),o=n(47799),a=(0,r.defineComponent)({__name:"RcIconTooltip",props:{content:{default:null},label:{default:void 0},iconType:{default:"info"}},setup(e){const t=["hover","touch","focus","click"],n=e,a=(0,r.computed)(()=>{if(!n.content)return"";const e="string"===typeof n.content?{content:n.content}:{...n.content};return{...e,triggers:t}});return(t,n)=>{const s=(0,r.resolveDirective)("clean-tooltip");return(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createBlock)(i.A,{type:"button",variant:"ghost",size:"small",class:"rc-icon-tooltip","aria-label":e.label||t.t("generic.moreInfo")},{default:(0,r.withCtx)(()=>[(0,r.createVNode)(o.A,{type:e.iconType},null,8,["type"])]),_:1},8,["aria-label"])),[[s,a.value]])}}}),s=(n(54464),n(47433));const l=(0,s.A)(a,[["__scopeId","data-v-a4945d12"]]);var c=l},14384:function(e,t,n){"use strict";n.d(t,{v:function(){return r.A}});var r=n(30342)},28533:function(e,t,n){"use strict";n.d(t,{WZ:function(){return a}});var r=n(9274);const i={info:{primary:"--rc-info",secondary:"--rc-info-secondary"},success:{primary:"--rc-success",secondary:"--rc-success-secondary"},warning:{primary:"--rc-warning",secondary:"--rc-warning-secondary"},error:{primary:"--rc-error",secondary:"--rc-error-secondary"},unknown:{primary:"--rc-unknown",secondary:"--rc-unknown-secondary"},none:{primary:"--rc-none",secondary:"--rc-none-secondary"}};function o(e){return e.startsWith("--")?`var(${e})`:e}function a(e,t){const n=(0,r.computed)(()=>i[e.value]),a="outlined"===t,s=(0,r.computed)(()=>{const e=a?n.value.secondary:n.value.primary;return o(e)}),l=(0,r.computed)(()=>{if("none"===e.value)return"none";const t=a?n.value.secondary:n.value.primary;return o(t)}),c=(0,r.computed)(()=>{const e=a?n.value.primary:n.value.secondary;return o(e)});return{borderColor:s,backgroundColor:l,textColor:c}}},7325:function(e,t,n){"use strict";n.d(t,{CB:function(){return c},I0:function(){return l},bh:function(){return d},do:function(){return u}});n(35664);var r=n(2841),i=(n(50667),n(88339),n(76978),n(68851)),o=(n(99726),n(50382),n(74302),n(92043),n(83288)),a=n(88088),s=n.n(a);n(48074),n(4364);r.W8._RANCHER,r.W8._PARTNER;const l={NOT_APPLICABLE:"not_applicable",NO_UPGRADE:"no_upgrade",SINGLE_UPGRADE:"single_upgrade",MULTIPLE_UPGRADES:"multiple_upgrades"},c="windows",u="linux";function d(e,t,n=!0){const r=e.versions;return t&&!(0,i.cy)(t)&&(t=[t]),r.filter(r=>{const i=h(null===r||void 0===r?void 0:r.annotations,null===e||void 0===e?void 0:e.isRancherRepo);return!(!n&&(0,o.V1)(r.version))&&(!t||0===i.length||0===s()(t,i).length)})}function h(e,t){const n=null===e||void 0===e?void 0:e[r.W8.PERMITTED_OS],i=t?u:"";return(n||i).split(",").filter(Boolean)}},41476:function(e,t,n){"use strict";n.d(t,{AN:function(){return o},DX:function(){return S},EI:function(){return f},G$:function(){return E},HZ:function(){return _},Hu:function(){return h},IJ:function(){return x},JV:function(){return d},Ks:function(){return R},LU:function(){return D},Mu:function(){return g},Pz:function(){return k},Ri:function(){return l},UK:function(){return P},ZX:function(){return N},_E:function(){return p},aP:function(){return v},bc:function(){return C},cx:function(){return c},gM:function(){return T},jn:function(){return u},kJ:function(){return O},kc:function(){return b},qv:function(){return w},u1:function(){return m},xL:function(){return y}});n(45250),n(9262),n(35664),n(76978),n(38275),n(4364);const r={};const i=function(e,t,n={}){const i=!0===n.parseJSON,o=!0===n.asCookie,a=!1!==n.asUserPreference,s=n.options,l=n.inheritFrom;return r[e]={def:t,options:s,parseJSON:i,asCookie:o,asUserPreference:a,inheritFrom:l,mangleRead:n.mangleRead,mangleWrite:n.mangleWrite},e},o=function(e){return{get(){return this.$store.getters["prefs/get"](e)},set(t){this.$store.dispatch("prefs/set",{key:e,value:t})}}},a=!0,s=!0,l=(i("cluster",""),i("last-namespace","")),c=i("ns-by-cluster",{},{parseJSON:a}),u=(i("workspace",""),i("open-groups",["cluster","policy","rbac","serviceDiscovery","storage","workload"],{parseJSON:a})),d=i("fav-type",[],{parseJSON:a}),h=i("pinned-clusters",[],{parseJSON:a}),p=i("recent-clusters",[],{parseJSON:a}),f=i("group-by","namespace"),m=i("table-views",{},{parseJSON:a}),g=i("diff","unified",{options:["unified","split"]}),v=(i("theme","auto",{options:["light","auto","dark"],asCookie:s,parseJSON:a,mangleRead:e=>e.replace(/^ui-/,""),mangleWrite:e=>`ui-${e}`}),i("pcs","",{asCookie:s,asUserPreference:!1}),i("locale","en-us",{asCookie:s}),i("keymap","sublime",{options:["sublime","emacs","vim"]})),b=i("per-page",100,{options:[10,25,50,100],parseJSON:a}),y=(i("logs-wrap",!0,{parseJSON:a}),i("logs-time",!0,{parseJSON:a}),i("logs-range","30 minutes",{parseJSON:a}),i("hide-repos",[],{parseJSON:a}),i("hide-desc",[],{parseJSON:a})),w=i("hide-sensitive",!0,{options:[!0,!1],parseJSON:a}),O=i("show-pre-release",!1,{options:[!1,!0],parseJSON:a}),S=i("date-format","ddd, MMM D YYYY",{options:["ddd, MMM D YYYY","ddd, D MMM YYYY","D/M/YYYY","M/D/YYYY","YYYY-MM-DD"]}),E=i("time-format","h:mm:ss a",{options:["h:mm:ss a","HH:mm:ss"]}),x=(i("time-zone","local"),i("dev",!1,{parseJSON:a})),_=i("view-in-api",!1,{parseJSON:a,inheritFrom:x}),k=i("all-namespaces",!1,{parseJSON:a,inheritFrom:x}),C=(i("theme-shortcut",!1,{parseJSON:a,inheritFrom:x}),i("last-visited","home",{parseJSON:a}),i("seen-whatsnew","",{parseJSON:a}),i("read-whatsnew","",{parseJSON:a}),i("after-login-route","home",{parseJSON:a}),i("home-page-cards",{},{parseJSON:a}),i("plugin-developer",!1,{parseJSON:a,inheritFrom:x})),A="rke1",T="rke2",R=(i("provisioner",T,{options:[A,T]}),20),N=5,P=10;i("scale-pool-prompt",null,{parseJSON:a}),i("read-new-release","",{parseJSON:a}),i("read-support-notice","",{parseJSON:a}),i("read-upcoming-support-notice","",{parseJSON:a}),i("read-announcements","",{parseJSON:a}),i("hide-suse-app-collection-repo-banner",!1),new Map;let I=Promise.resolve();const M=3e4;function D(e){const t=I,n=t.then(e,e);return I=new Promise(e=>{let r;t.then(()=>{},()=>{}).then(()=>{r=setTimeout(e,M),r?.unref?.()}),n.then(()=>{},()=>{}).then(()=>{clearTimeout(r),e()})}),n}},46392:function(e,t,n){"use strict";n.d(t,{Bm:function(){return o},Ng:function(){return u},UQ:function(){return a},h1:function(){return c}});var r=n(68851);n(35664);const i=/^\$\.metadata\.fields\[([0-9]*)\]/;function o(e,t){const{headers:n,typeOptions:i,schema:o,columns:a,pagination:l}=t,{state:c,name:u,namespace:d,id:h,age:p}=a,{rootGetters:f}=e,m=i.showState?[c]:[],g=o?.attributes||{},v=g?.columns||[];if(n?.[o?.id]?.length)return n[o?.id].map(e=>{if("string"===typeof e){const t=(0,r.jq)(v,"name",e);return t?s(t,f,l,p):null}return e}).filter(e=>!!e);let b=!1;const y=g.namespaced||!1;for(const r of v)"name"===r.format?(b=!0,m.push(u||s(r,f,l,p)),y&&m.push(d)):m.push(s(r,f,l,p));b||((0,r.PT)(m,1,u||h),y&&(0,r.PT)(m,2,d));const w=m.find(e=>"age"===e.name.toLocaleLowerCase());return w&&((0,r.Gj)(m,w),i.showAge&&m.push(w)),m}function a(e,t,n,r,i){if(!t)throw new Error(`Unable to create header for column '${e}' from schema: schema is missing`);const o=t.attributes.columns.find(t=>t.name===e);if(!o)throw new Error(`Unable to find column '${e}' in schema '${t.id}'`);return s(o,n,r,i)}function s(e,t,n,r){let i,o,a;if((""===e.format||"date"===e.format||"date"===e.type)&&"age"===e.name.toLowerCase()&&r)return r;"date"!==e.format&&"date"!==e.type||(i="Date",o=120,a={multiline:!0}),"number"!==e.type&&"int"!==e.type||(i="Number");const s=e.name.includes(" ")?e.name.split(" ").map(e=>e.charAt(0).toUpperCase()+e.substring(1)).join(""):e.name,l=t["i18n/exists"],u=t["i18n/t"],d=`tableHeaders.${s.charAt(0).toLowerCase()+s.slice(1)}`,h=e.description||"",p=h&&"."===h[h.length-1]?h.slice(0,-1):h,f=c(e,!1),m=n?f:c(e,!0);return{name:e.name.toLowerCase(),label:l(d)?u(d):e.name,value:m,sort:[f],search:f,formatter:i,formatterOpts:a,width:o,tooltip:p}}function l(e){if("string"===typeof e&&e.startsWith("$")&&e.includes("\\.")){const t=e.split(".");let n=!1,r="";return t.forEach(e=>{let t=r.length?".":"";if(e.endsWith("\\"))n||(n=!0,t=`${t}["`),r=`${r}${t}${e.substr(0,e.length-1)}`;else{const i=n?'"]':"";r+=`${t}${e}${i}`,n=!1}}),r}return e}function c(e,t=!0){const n=e.field.startsWith(".")?`$${e.field}`:e.field,r=n.match(i);if(r&&2===r.length){const e=parseInt(r[1],10);return t?t=>t.metadata?.fields?.[e]:`metadata.fields.${e}`}return l(n)}const u=(e,t)=>"function"===typeof e?!!t&&e(t):e},15328:function(e,t,n){"use strict";n.d(t,{c:function(){return r},w:function(){return i}});const r={GROUP:"group",DIVIDER:"divider",NONE:"none"},i=[r.GROUP,r.DIVIDER]},51173:function(e,t,n){"use strict";var r;n.d(t,{SG:function(){return r}}),function(e){e[e["Announcement"]=0]="Announcement",e[e["Task"]=1]="Task",e[e["Info"]=2]="Info",e[e["Success"]=3]="Success",e[e["Warning"]=4]="Warning",e[e["Error"]=5]="Error",e[e["Hidden"]=6]="Hidden"}(r||(r={}));const i={title:!0,message:!0,level:!0,primaryAction:!0,secondaryAction:!0,preference:!0,handlerName:!0,data:!0};Object.keys(i)},75689:function(e,t,n){"use strict";n.d(t,{s:function(){return r}});const r={UNKNOWN_REVISION:"unknown revision"}},11519:function(e,t,n){"use strict";n.d(t,{AC:function(){return o},Nb:function(){return i},q0:function(){return r}});const r=/^(\d+)\s*\(([^)]+)\)/,i="metadata.fields[3][0]",o="metadata.fields[3][1]"},50025:function(e,t,n){"use strict";n.d(t,{B6:function(){return l},D0:function(){return r},Js:function(){return o},YU:function(){return u},eY:function(){return s},gR:function(){return c}});var r,i=n(18110);(function(e){e["IN"]=" IN ",e["NOT_IN"]=" NOTIN ",e["EQUALS"]="=",e["NOT_EQUALS"]="!=",e["STRICT_EQUALS"]="==",e["CONTAINS"]="~",e["NOT_CONTAINS"]="!~",e["GREATER_THAN"]="gt",e["LESS_THAN"]="lt"})(r||(r={}));class o{constructor(e){const{field:t,value:n="",equals:r=!0,exact:i=!0,equality:a,exists:s=!1}=e;this.field=t,this.value=n,this.equals=r,this.exact=i,this.exists=s;const l=o.safeEquality({field:t,value:n,equals:r,exact:i,equality:a,exists:s});if(!l)throw new Error("A pagination filter must have either equals or equality set");this.equality=l}static safeEquality(e){return e.equality?e.equality:!0===e.equals?!0===e.exact?r.EQUALS:r.CONTAINS:!1===e.equals?!0===e.exact?r.NOT_EQUALS:r.NOT_CONTAINS:void 0}}class a{constructor({param:e,equals:t=!0,fields:n=[]}){this.param=e,this.equals=t,this.fields=n}}class s extends a{constructor({equals:e=!0,fields:t=[]}){super({param:"filter",equals:e,fields:t})}static createSingleField(e){return new s({fields:[new o(e)]})}static createMultipleFields(e){return new s({fields:e})}}class l extends a{constructor({equals:e=!0,projectOrNamespace:t=[]}){const n=t.map(e=>new o({value:e.replace(i.os,"").replace(i.tA,"")}));super({param:"projectsornamespaces",equals:e,fields:n})}}class c{constructor({page:e=1,pageSize:t=10,sort:n=[],filters:r=[],projectsOrNamespaces:i=[],labelSelector:o}){this.page=e,this.pageSize=t,this.sort=n,this.filters=r?Array.isArray(r)?r:[r]:[],this.projectsOrNamespaces=i?Array.isArray(i)?i:[i]:[],this.labelSelector=o}}class u extends c{constructor({sort:e=[],filters:t=[],projectsOrNamespaces:n=[],labelSelector:r}){super({page:null,pageSize:null,sort:e,filters:t,projectsOrNamespaces:n,labelSelector:r})}}},88343:function(e,t,n){"use strict";var r,i;n.d(t,{g:function(){return r},r:function(){return i}}),function(e){e["DEFAULT"]="",e["RESOURCE_CHANGES"]="resource.changes"}(r||(r={})),function(e){e["START"]="resource.start",e["CREATE"]="resource.create",e["CHANGE"]="resource.change",e["CHANGES"]="resource.changes",e["REMOVE"]="resource.resource.remove",e["ERROR"]="resource.error",e["STOP"]="resource.stop"}(i||(i={}))},39669:function(e,t,n){"use strict";n.d(t,{c:function(){return r}});const r={TABLET:"tablet",LAPTOP:"laptop",DESKTOP:"desktop"}},80869:function(e,t,n){"use strict";n.d(t,{iP:function(){return m}});var r=n(92043);const i="polite",o="assertive",a="aria-live-announcer",s=100,l=350,c=1e3,u={};function d(e){return(0,r.iT)(String(e).replace(/<\/?[^>]+(>|$)/g,"")).trim()}function h(){if(!document.body)return document.addEventListener("DOMContentLoaded",()=>f(),{once:!0}),null;const e=document.getElementById(a);if(e)return e;const t=document.createElement("div");return t.id=a,t.setAttribute("style",["position:absolute","width:1px","height:1px","margin:-1px","padding:0","overflow:hidden","clip:rect(0,0,0,0)","white-space:nowrap","border:0"].join(";")),document.body.appendChild(t),t}function p(e){var t;const n=u[e];if(null===(t=null===n||void 0===n?void 0:n.nodes[0])||void 0===t?void 0:t.isConnected)return n;const r=h();if(!r)return null;const i=Array.from(r.querySelectorAll(`[aria-live="${e}"]`));if(i.length){const t={nodes:i,next:0,warmedUp:!0,lastNodeForText:new Map};return u[e]=t,t}const a=[0,1,2,3].map(()=>{const t=document.createElement("div");return t.setAttribute("role",e===o?"alert":"status"),t.setAttribute("aria-live",e),t.setAttribute("aria-atomic","true"),r.appendChild(t),t}),s={nodes:a,next:0,warmedUp:!1,lastNodeForText:new Map};return u[e]=s,s}function f(){"undefined"!==typeof document&&p(i)}function m(e,t=i){if("undefined"===typeof document)return;const n=d(e||"");if(!n)return;const r=p(t);if(!r)return;clearTimeout(r.writeTimer),clearTimeout(r.clearTimer);const o=r.lastNodeForText.get(n),a=void 0!==o?(o+1)%r.nodes.length:r.next,u=r.nodes[a];r.lastNodeForText.set(n,a),r.next=(a+1)%r.nodes.length;const h=r.warmedUp?s:l;r.warmedUp=!0,r.nodes.forEach(e=>{e.textContent=""}),r.writeTimer=setTimeout(()=>{u.textContent=n,r.clearTimer=setTimeout(()=>{u.textContent=""},c)},h)}},68851:function(e,t,n){"use strict";n.d(t,{$M:function(){return s},Gj:function(){return a},IU:function(){return p},P1:function(){return v},PG:function(){return l},PT:function(){return u},WP:function(){return m},Wq:function(){return h},cn:function(){return c},cy:function(){return d},jq:function(){return g},sb:function(){return y},yI:function(){return b}});var r=n(13182),i=n.n(r),o=n(76978);function a(e,t){const n=e.indexOf(t);return n>=0&&e.splice(n,1),e}function s(e,t){let n,r=[];for(n=0;n<t.length;n++){let i=e.indexOf(t[n]);while(-1!==i)r.push(i),i=e.indexOf(t[n],i+1)}if(!r.length)return e;r=r.sort((e,t)=>e-t);const i=[];let o,a;while(r.length){o=r.shift(),a=o;while(r.length&&r[0]===a+1)a=r.shift();i.push({start:o,end:a})}for(n=i.length-1;n>=0;n--){const{start:t,end:r}=i[n];e.splice(t,r-t+1)}return e}function l(e,t){const n=e.indexOf(t);-1===n&&e.push(t)}function c(e,t){const n=[];for(const r of t)e.includes(r)||n.includes(r)||n.push(r);e.push(...n)}function u(e,t,...n){e.splice(t,0,...n)}function d(e){return Array.isArray(e)}function h(e,t,n=1){if(t<0)throw new Error("Index too low");if(t+n>e.length)throw new Error("Index + length too high");return e.splice(t,n),e}function p(e){e.splice(0,e.length)}function f(e,t,n,r){return t=t||[],"object"===typeof n?t[e](e=>{for(const t in n){const r=n[t],i=(0,o.Jt)(e,t);if("undefined"===typeof r){if(!i)return!1}else if(i!==r)return!1}return!0}):void 0===r?t[e](e=>!!(0,o.Jt)(e,n)):t[e](e=>(0,o.Jt)(e,n)===r)}function m(e,t,n){return f("filter",e,t,n)}function g(e,t,n){return f("find",e,t,n)}function v(e,t){return 0===i()(e,t).length}function b(e,t,n=!1){if(!e&&!t)return!1;if(e?.length!==t?.length)return!1;if(n){const n={};t.forEach((e,t)=>{n[t]=!1});for(let r=0;r<e.length;r++){const i=e[r],a=t.findIndex((e,t)=>(0,o.n4)(e,i)&&!n[t]);if(!(a>=0))return!1;n[a]=!0}}else for(let r=0;r<e.length;r++)if(!(0,o.n4)(e[r],t[r]))return!1;return!0}function y(e){const t=[];return c(t,e),t}},23330:function(e,t,n){"use strict";n.d(t,{f:function(){return i},u:function(){return o}});var r=n(4364);const i=(e,t="",n=3e6,i=500,o=!1)=>{return a("Starting wait for",t),new Promise((r,o)=>{if(e())return a("Wait for",t||"unknown","done immediately"),void r(void 0);const s=setTimeout(()=>{a("Wait for",t,"timed out"),clearInterval(l),clearTimeout(s),o(new Error(t?`Failed waiting for: ${t}`:`waitFor timed out after ${n/1e3} seconds`))},n),l=setInterval(()=>{e()?(a("Wait for",t,"done"),clearInterval(l),clearTimeout(s),r(void 0)):t&&a("Wait for",t,"not done yet")},i)});function a(...e){o&&r.log(...e)}},o=e=>new Promise(t=>setTimeout(t,e))},12663:function(e,t,n){"use strict";var r=n(92043),i=n(4364);const o=e=>e?JSON.stringify(e,(e,t)=>void 0===t?"":t):"",a="font-weight: bold; font-style: italic;",s="font-weight: normal; font-style: normal;";var l;(function(e){e["EXECUTE"]="delay",e["RECURSE"]="recurse"})(l||(l={}));const c=!1,u=e=>{if(c||0!==e)return"info"};class d{constructor(){this.map={},this.sleep=e=>new Promise(t=>setTimeout(t,e)),this.calcDelay=e=>0===e?1:250*Math.pow(e,2),this.canRecurse=async(e,{id:t,description:n,metadata:r,canFn:i=async()=>!0})=>{var o,a;if(!this.map[t])return this.logAndError("info",{id:t,status:"Aborting (backoff was reset, do not continue to process)",description:n,metadata:r,type:l.RECURSE});if((null===(o=this.map[t].recurse)||void 0===o?void 0:o.id)!==(null===(a=e.recurse)||void 0===a?void 0:a.id))return this.logAndError("info",{id:t,status:"Aborting (stale backoff, a new one exists)",description:n,metadata:r,type:l.RECURSE});const s=await i();return s?void 0:this.logAndError("info",{id:t,status:"Skipping (canFn test failed)",description:n,metadata:r,type:l.RECURSE})}}getLogTypeFromMap(e){const t=this.getBackOff(e);let n="";return(null===t||void 0===t?void 0:t.execute)?n=l.EXECUTE:(null===t||void 0===t?void 0:t.recurse)&&(n=l.RECURSE),n}log(e,{id:t,status:n,description:r,metadata:l,type:c},...u){if(!e)return;let d=c||this.getLogTypeFromMap(t);d=d?` (${d})`:"",i[e](`%cBackOff${d}%c... \n%cId%c: ${t}\n%cDescription%c: ${r}\n%cStatus%c: ${n}\n%cMetadata%c: ${o(l)}\n%cCache %c: ${Object.keys(this.map).map(e=>`"${e}"`).join(" + ")}`,a,s,a,s,a,s,a,s,a,s,a,s,...u)}logAndError(e,{id:t,status:n,description:r,metadata:i,type:o},...a){return this.log(e,{id:t,status:n,description:r,metadata:i,type:o},...a),Promise.reject(new Error(n))}getBackOff(e){return this.map[e]}resetAll(){Object.keys(this.map).forEach(e=>{this.reset(e)})}resetPrefix(e){Object.keys(this.map).forEach(t=>{t.startsWith(e)&&this.reset(t)})}reset(e){var t;const n=this.map[e];if(!n)return;const r=this.getLogTypeFromMap(e);(null===(t=null===n||void 0===n?void 0:n.execute)||void 0===t?void 0:t.timeoutId)&&(this.log("info",{id:e,status:"Stopping (cancelling active back-off)",description:n.description,metadata:n.metadata,type:r}),clearTimeout(n.execute.timeoutId));const i=(null===n||void 0===n?void 0:n.try)||0,o=i<=1?void 0:"debug";delete this.map[e],this.log(o,{id:e,status:"Reset",description:n.description,metadata:n.metadata,type:r})}async recurse(e){const{id:t,description:n,retries:i=10,delayedFn:o,continueOnError:a,metadata:s}=e;if(this.map[t])return this.logAndError("info",{id:t,status:"Skipping (previous recurse back off process still running)",description:n,metadata:s,type:"recurse"});this.map[t]={try:1,retries:i,description:n,metadata:s,recurse:{id:(0,r.vx)()}};for(let r=0;r<i;r++){await this.canRecurse(this.map[t],e),this.map[t].try=r+1;const i=this.calcDelay(r),d=u(r);let h;this.log(d,{id:t,status:`Delaying call (attempt ${r+1}, delayed by ${i}ms)`,description:n,metadata:s,type:l.RECURSE}),await this.sleep(i),await this.canRecurse(this.map[t],e),this.log(d,{id:t,status:"Executing call",description:n,metadata:s,type:l.RECURSE});try{h=await o()}catch(c){const e=await a(c);if(!e){this.reset(t);const e="Failed call";return this.logAndError("error",{id:t,status:e,description:n,metadata:s,type:l.RECURSE},c)}}if(h)return await this.canRecurse(this.map[t],e),this.reset(t),this.log(d,{id:t,status:"Successful call",description:n,metadata:s,type:l.RECURSE}),h}}async execute({id:e,description:t,retries:n=10,delayedFn:r,canFn:i=async()=>!0,metadata:o}){var a,s;const c=this.map[e],d=await i();if(d){if(null===(a=null===c||void 0===c?void 0:c.execute)||void 0===a?void 0:a.timeoutId)return this.log("info",{id:e,status:"Skipping (previous back off process still running)",description:t,metadata:o,type:l.EXECUTE}),null===(s=null===c||void 0===c?void 0:c.execute)||void 0===s?void 0:s.timeoutId;{const i=(null===c||void 0===c?void 0:c.try)||0;if(i+1>n)return void this.log("error",{id:e,status:"Aborting (too many retries)",description:t,metadata:o,type:l.EXECUTE});const a=this.calcDelay(i),s=u(i);this.log(s,{id:e,status:`Delaying call (attempt ${i+1}, delayed by ${a}ms)`,description:t,metadata:o,type:l.EXECUTE});const d=setTimeout(async()=>{var n,i;try{this.log(s,{id:e,status:"Executing call",description:t,metadata:o,type:l.EXECUTE}),await r()}catch(a){this.log("error",{id:e,status:"Failed call",description:t,metadata:o,type:l.EXECUTE})}null===(i=null===(n=this.map[e])||void 0===n?void 0:n.execute)||void 0===i||delete i.timeoutId},a);return this.map[e]={execute:{timeoutId:d},try:(null===c||void 0===c?void 0:c.try)?c.try+1:1,retries:n,description:t,metadata:o},d}}this.log("info",{id:e,status:"Skipping (canExecute test failed)",description:t,metadata:o,type:l.EXECUTE})}}const h=new d;t.A=h},38275:function(e,t,n){"use strict";n.d(t,{V:function(){return i}});var r=n(52148);function i(e){let t={};if(e)try{t=(0,r.sG)(`~shell/assets/brand/${e}/metadata.json`)}catch{}return t}},78474:function(e,t,n){"use strict";n.d(t,{HX:function(){return o},Vc:function(){return a},pf:function(){return s}});var r=n(41476),i=(n(10213),n(4364));const o=(e,t)=>({key:r.Hu,apply:n=>{const r=(Array.isArray(n)?n:[]).filter(t=>!e.includes(t));return t?[...e,...r]:r}});function a(e,t,n){return Promise.resolve(n).then(n=>{(null===n||void 0===n?void 0:n.status)&&e.dispatch("growl/fromError",{title:t("nav.pinClusterError"),err:{...n,message:t("nav.pinClusterError")}})}).catch(e=>i.warn("Unable to toggle the cluster pin",e))}function s(e,t){const n=e("prefs/applyPrefsOptimistic",t);return(0,r.LU)(()=>n.then(n=>(null===n||void 0===n?void 0:n.status)?n:e("prefs/reconcilePrefs",{mutations:t,optimistic:n})))}},10078:function(e,t,n){"use strict";function r(e,t){return!(!e||!t)&&(e.topLevelProducts?Boolean(e.topLevelProducts.has(t)&&e.startRouteWithProductByProduct?.[t]):Boolean(e.topLevelProduct))}n.d(t,{e:function(){return r}})},39618:function(e,t,n){"use strict";n.d(t,{IL:function(){return i},nx:function(){return r}});n(4514),n(35664),n(2841),n(17259),n(4364);const r="oci://dp.apps.rancher.io/charts",i="SUSE AppCo"},40530:function(e,t,n){"use strict";var r=n(45250),i=n(73883),o=n(2841),a=n(27278),s=n(35664);function l(e){return`${e.kind}/${e.namespace}/${e.name}`}function c(e,t){return!!e&&!!e.find(e=>e.type===t&&"true"===e.status.toLowerCase())}class u{constructor(){this.includeAllWorkgroupRule={clusterSelector:{matchExpressions:[]}},this.excludeHarvesterRule={clusterSelector:{matchExpressions:[{key:o.qt.PROVIDER,operator:"NotIn",values:[s.BN]}]}}}getTargetMode(e,t,n){if("fleet-local"===t)return"local";if(!e.length)return"none";let i="all";for(const a of e){const{clusterName:e,clusterSelector:t,clusterGroup:n,clusterGroupSelector:o}=a;if(o)return"advanced";(e||n)&&(i="clusters"),(0,r.isEmpty)(t)||(i="clusters")}const o=[...e].map(e=>(delete e.name,e));return((0,r.isEqual)(o,[this.includeAllWorkgroupRule])||(0,r.isEqual)(o,[this.excludeHarvesterRule]))&&(i="all"),i}}class d{constructor(){this.resourceIcons={[s.Hs.GIT_REPO]:"icon icon-github",[s.Hs.HELM_OP]:"icon icon-helm"},this.dashboardIcons={[s.Hs.GIT_REPO]:"icon icon-git",[s.Hs.HELM_OP]:"icon icon-helm"},this.dashboardStates=[{index:0,id:"error",label:"Error",color:"#F64747",icon:"icon icon-error",stateBackground:"bg-error"},{index:1,id:"warning",label:"Warning",color:"#DAC342",icon:"icon icon-warning",stateBackground:"bg-warning"},{index:2,id:"success",label:"Active",color:"#5D995D",icon:"icon icon-checkmark",stateBackground:"bg-success"},{index:3,id:"info",label:"Pending",color:"#3d98d3",icon:"icon icon-warning",stateBackground:"bg-info"}],this.Application=new u,this.GIT_HTTPS_REGEX=/^https?:\/\/github\.com\/(.*?)(\.git)?\/*$/,this.GIT_SSH_REGEX=/^git@github\.com:.*\.git$/,this.HTTP_REGEX=/^(https?:\/\/[^\s]+)$/,this.OCI_REGEX=/^oci:\/\//}quacksLikeAHash(e){return!!e.match(/^[a-f0-9]{40,}$/i)}parseSSHUrl(e){var t;const n=(e||"").split(":"),r=n[0],i=null===(t=n[1])||void 0===t?void 0:t.replace(".git","");return{sshUserAndHost:r,repoPath:i}}resourceId(e){return e.namespace?`${e.namespace}/${e.name}`:e.name}resourceType(e){const t=e.kind.toLowerCase();return e.apiVersion&&"v1"!==e.apiVersion?`${e.apiVersion.split("/",2)[0]}.${t}`:t}detailLocation(e,t){const n=(0,i.hb)(e.state)===i.jv.MISSING?void 0:{name:`c-cluster-product-resource${e.namespace?"-namespace":""}-id`,params:{product:a.o,cluster:t,resource:this.resourceType(e),namespace:e.namespace,id:e.name}};return n&&!n.params.namespace&&delete n.params.namespace,n}resourcesFromBundleDeploymentStatus(e){var t;const n=((null===e||void 0===e?void 0:e.resources)||[]).reduce((e,t)=>(e[l(t)]=Object.assign({state:i.jv.READY},t),e),{}),r=[];for(const o of(null===e||void 0===e?void 0:e.modifiedStatus)||[]){const e=o.missing?i.jv.MISSING:o.delete?i.jv.ORPHANED:i.jv.MODIFIED,t=n[l(o)];t?t.state=e:r.push(Object.assign({state:e},o))}for(const o of(null===e||void 0===e?void 0:e.nonReadyStatus)||[]){const e=(null===(t=o.summary)||void 0===t?void 0:t.state)||i.jv.UNKNOWN,r=n[l(o)];r&&(r.state=e)}return r.concat(Object.values(n))}clusterIdFromBundleDeploymentLabels(e){const t=null===e||void 0===e?void 0:e[o.Hs.CLUSTER_NAMESPACE],n=null===e||void 0===e?void 0:e[o.Hs.CLUSTER];return`${t}/${n}`}bundleIdFromBundleDeploymentLabels(e){const t=null===e||void 0===e?void 0:e[o.Hs.BUNDLE_NAMESPACE],n=null===e||void 0===e?void 0:e[o.Hs.BUNDLE_NAME];return`${t}/${n}`}bundleDeploymentState(e){var t,n,r,o;return(null===(t=e.status)||void 0===t?void 0:t.appliedDeploymentId)!==e.spec.deploymentId?c(null===(n=e.status)||void 0===n?void 0:n.conditions,"Deployed")?i.jv.WAIT_APPLIED:i.jv.ERR_APPLIED:(null===(r=e.status)||void 0===r?void 0:r.ready)?e.spec.deploymentId!==e.spec.stagedDeploymentId?i.jv.OUT_OF_SYNC:(null===(o=e.status)||void 0===o?void 0:o.nonModified)?i.jv.READY:i.jv.MODIFIED:i.jv.NOT_READY}getResourcesDefaultState(e,t){return[i.jv.READY,i.jv.NOT_READY,i.jv.WAIT_APPLIED,i.jv.MODIFIED,i.jv.MISSING,i.jv.ORPHANED,i.jv.UNKNOWN].reduce((n,r)=>(n[r]={count:0,color:i.xj[r].color,label:e(`${t}.${r}`,null,i.xj[r].label),status:r},n),{})}getBundlesDefaultState(e,t){return[i.jv.READY,i.jv.INFO,i.jv.WARNING,i.jv.NOT_READY,i.jv.MODIFIED,i.jv.OUT_OF_SYNC,i.jv.PENDING,i.jv.ERROR,i.jv.ERR_APPLIED,i.jv.WAIT_APPLIED,i.jv.WAITING_FOR_DEPENDENCY,i.jv.UNKNOWN].reduce((n,r)=>(n[r]={count:0,color:i.xj[r].color,label:e(`${t}.${r}`,null,i.xj[r].label),status:r},n),{})}resourceStateObj(e){const t=(null===e||void 0===e?void 0:e.name)?i.xj[e.name.toLowerCase()]:void 0;return(null===e||void 0===e?void 0:e.error)&&t&&t.color!==i.xj[i.jv.ERROR].color?{...e,error:!1}:e}getDashboardStateId(e){var t;return(null===(t=null===e||void 0===e?void 0:e.stateColor)||void 0===t?void 0:t.replace("text-",""))||"warning"}getDashboardState(e){const t=this.getDashboardStateId(e);return this.dashboardStates.find(({id:e})=>t===e)||{}}}const h=new d;t.A=h},40207:function(e,t,n){"use strict";n.d(t,{W:function(){return r}});const r={enabled:!1,enabledInterval:!0,interval:300,enabledOnNavigate:!0,ageThreshold:120,countThreshold:500}},90599:function(e,t,n){"use strict";var r=n(9262),i=n(35664),o=n(40207),a=n(4364);class s{constructor(){this.cachedGcPrefs=o.W,this.cachedGcPrefsStamp="",this.debugLog=(...e)=>{s.ENABLE_DEBUG_LOGGING&&a.debug("GC",...e)},this.gcLastRun=0,this.getUiPerfGarbageCollection=e=>{var t,n;const o=null===(n=null===(t=e.management.types[i.Mc.SETTING])||void 0===t?void 0:t.list)||void 0===n?void 0:n.find(e=>e.id===r.HG.UI_PERFORMANCE);if(!o||!o.value)return;const a=`${o.metadata.generation}-${o.metadata.resourceVersion}`;if(this.cachedGcPrefsStamp!==a){this.debugLog(`Updating ${r.HG.UI_PERFORMANCE} cache`),this.cachedGcPrefsStamp=a;const e=JSON.parse(o.value);this.cachedGcPrefs=e.garbageCollection}return this.cachedGcPrefs},this.lastAccessedCache={},this.lastRouteChange=0}gcEnabledAll(e,t){return this.gcEnabledForStore(e.state)&&this.gcEnabledSetting(e)&&this.gcEnabledForType(e,t)}gcEnabledSetting(e){const{rootState:t}=e,n=this.getUiPerfGarbageCollection(t);return null===n||void 0===n?void 0:n.enabled}gcEnabledForStore(e){var t;return null===(t=null===e||void 0===e?void 0:e.config)||void 0===t?void 0:t.supportsGc}gcEnabledForType(e,t){const{getters:n}=e;return!(!t||n.gcIgnoreTypes[t])}gcEnabledInterval(e){const{rootState:t}=e,n=this.getUiPerfGarbageCollection(t);return{enabled:null===n||void 0===n?void 0:n.enabledInterval,interval:(null===n||void 0===n?void 0:n.interval)||0}}gcEnabledRoute(e){const{rootState:t}=e,n=this.getUiPerfGarbageCollection(t);return null===n||void 0===n?void 0:n.enabledOnNavigate}garbageCollect(e,t={}){const n=(new Date).getTime();if(null===this.gcLastRun||n-this.gcLastRun<s.GC_RE_RUN_GAP)return void this.debugLog("Skipping (running or recently run)",this.gcLastRun?new Date(this.gcLastRun):"running");this.gcLastRun=null;const r={};try{const{getters:o,rootState:a,dispatch:s}=e;if(!a.clusterReady)return this.debugLog("Skipping (cluster not ready)"),void(this.gcLastRun=(new Date).getTime());this.debugLog("------ Started ------");const l=this.getUiPerfGarbageCollection(a);if(!l)return;const c=1e3*l.ageThreshold,u=l.countThreshold;this.debugLog(`Max Age: ${c}. Max Count: ${u}`);const d=e.state.config.namespace;Object.entries(this.lastAccessedCache[d]||{}).forEach(([a,l])=>{var d;if(!l)return void this.debugLog(`${a}: Skipping (no accessed time)`);if(!this.gcEnabledForType(e,a))return void this.debugLog(`${a}: Skipping (type ignored by store)`);if(t[a])return void this.debugLog(`${a}: Skipping (navigating to type)`);if(n-l<=c)return void this.debugLog(`${a}: Skipping (recently accessed)`);if(void 0!==this.lastRouteChange&&this.lastRouteChange<l)return void this.debugLog(`${a}: Skipping (used in current route/page)`);const h=null===(d=o.all(i.i2)[0].counts[a])||void 0===d?void 0:d.summary.count,p=null!==h&&void 0!==h?h:0;void 0===p||p<u?this.debugLog(`${a}: Skipping (too few of resource)`):(this.debugLog(`${a}: Removing from store`),s("forgetType",a),r[a]=p)}),this.gcLastRun=(new Date).getTime()}catch(o){this.debugLog(": Error",o),this.gcLastRun=(new Date).getTime()}Object.keys(r).length>0&&a.info("Garbage Collected Resources",r),this.debugLog("------ Finished ------")}gcUpdateLastAccessed(e,t){if(!this.gcEnabledAll(e,t))return;const n=e.state.config.namespace;this.lastAccessedCache[n]||(this.lastAccessedCache[n]={}),this.lastAccessedCache[n][t]=(new Date).getTime()}gcUpdateRouteChanged(){this.lastRouteChange=(new Date).getTime()}gcResetStore(e){const t=e.config.namespace;delete this.lastAccessedCache[t],this.debugLog("Forgetting Store:",t)}gcResetType(e,t){const n=e.config.namespace;this.lastAccessedCache[n]&&(delete this.lastAccessedCache[n][t],this.debugLog("Forgetting Type:",n,t))}}s.ENABLE_DEBUG_LOGGING=!1,s.GC_RE_RUN_GAP=5e3;const l=new s;t.A=l},15092:function(e,t,n){"use strict";var r=n(18110),i=n(68851),o=n(76978),a=n(34765),s=n(82637),l=n(35664),c=n(89778),u=n(9262);const d={version:1,enabled:!1,configuration:{threshold:500,results:250,pagesPerRow:25}},h={homePageCluster:d};class p{constructor(){this.defaultPageSize=1e5,this.validNsProjectFilters=[r.tj,r.Rc,r.bE,r.Rc,r.T6.NAMESPACE,r.T6.PROJECT]}getSettings({rootGetters:e}){const t=(0,a.fD)(e);return t.serverPagination}getStoreSettings(e){const t=void 0!==(null===e||void 0===e?void 0:e.rootGetters)?this.getSettings(e):e;return(null===t||void 0===t?void 0:t.useDefaultStores)||void 0===(null===t||void 0===t?void 0:t.useDefaultStores)?this.getStoreDefault():(null===t||void 0===t?void 0:t.stores)||this.getStoreDefault()}getStoreDefault(){return s.U}async isDownstreamSteveCacheEnabled({dispatch:e},t){const n=`/k8s/clusters/${t}/v1/${l.Mc.FEATURE}s/ui-sql-cache`,r=await e("cluster/request",{url:n});return null!==r.status.lockedValue?r.status.lockedValue:null!==r.spec.value?r.spec.value:r.status.default}isEnabledInStore({ctx:{rootGetters:e},storeSettings:t,enabledFor:n}){var r,i,o;if(!t)return!1;if(!n.resource)return!0;if(t.resources.enableAll)return!0;if(!n.resource.id)return!1;const a=!e["type-map/configuredHeaders"](n.resource.id)&&!e["type-map/configuredPaginationHeaders"](n.resource.id)&&!e["type-map/hasCustomList"](n.resource.id);return!(!(null===(r=t.resources.enableSome)||void 0===r?void 0:r.generic)||!a)||!!(null===(o=null===(i=t.resources.enableSome)||void 0===i?void 0:i.enabled)||void 0===o?void 0:o.find(e=>{var t,r,i;return"string"===typeof e?e===(null===(t=n.resource)||void 0===t?void 0:t.id):e.resource===(null===(r=n.resource)||void 0===r?void 0:r.id)&&(!e.context||!!(null===(i=n.resource)||void 0===i?void 0:i.context)&&e.context.includes(n.resource.context))}))}isEnabled({rootGetters:e,$extension:t},n){var r;const i=this.getSettings({rootGetters:e});if(!i)return!1;if(!n)return!1;const o=t,a=o.getAll()[c.j.SERVER_SIDE_PAGINATION_RESOURCES];if(a){const t=Object.entries(a).find(([t,r])=>{if("function"!==typeof r)return!1;const i=r(),o=Object.entries(i).find(([t,r])=>t===n.store&&this.isEnabledInStore({ctx:{rootGetters:e},storeSettings:r,enabledFor:n}));return!!o||void 0});if(t)return!0}const s=null===(r=this.getStoreSettings(i))||void 0===r?void 0:r[n.store];return this.isEnabledInStore({ctx:{rootGetters:e},storeSettings:s,enabledFor:n})}listAutoRefreshToggleEnabled({rootGetters:e}){return this.isFeatureEnabled({rootGetters:e},"listAutoRefreshToggle")}isListManualRefreshEnabled({rootGetters:e}){return this.isFeatureEnabled({rootGetters:e},"listManualRefresh")}getFeature({rootGetters:e},t){var n;const r=this.getSettings({rootGetters:e});return(null===(n=r.features)||void 0===n?void 0:n[t])||h[t]}isFeatureEnabled({rootGetters:e},t){var n;return!!(null===(n=this.getFeature({rootGetters:e},t))||void 0===n?void 0:n.enabled)}resourceChangesDebounceMs({rootGetters:e}){const t=this.getSettings({rootGetters:e});return t.resourceChangesDebounceMs||u.$8.serverPagination.resourceChangesDebounceMs}validateNsProjectFilters(e){return null===e||void 0===e?void 0:e.every(e=>this.validateNsProjectFilter(e))}validateNsProjectFilter(e){return!(!e.startsWith(r.os)&&!e.startsWith(r.tA))||this.validNsProjectFilters.includes(e)}paginationFilterEqual(e,t){return e.param===t.param&&e.equals===t.equals&&(0,i.yI)(e.fields,t.fields,!0)}paginationFiltersEqual(e,t){if(e&&(null===e||void 0===e?void 0:e.length)!==(null===t||void 0===t?void 0:t.length))return!1;for(let n=0;n<e.length;n++)if(!this.paginationFilterEqual(e[n],t[n]))return!1;return!0}paginationEqual(e,t){const{filters:n=[],sort:r=[],projectsOrNamespaces:a=[],...s}=e||{},{filters:l=[],sort:c=[],projectsOrNamespaces:u=[],...d}=t||{};return(0,o.n4)(s,d)&&this.paginationFiltersEqual(n,l)&&this.paginationFiltersEqual(a,u)&&(0,i.yI)(r,c,!1)}}t.A=new p},10257:function(e,t){"use strict";class n{constructor(e){this.setting=e}isEnabled(e,t){return!e&&t[this.setting].enabled}}t.A={incrementalLoadingUtils:new n("incrementalLoading"),manualRefreshUtils:new n("manualRefresh")}},3704:function(e,t,n){"use strict";n.d(t,{Js:function(){return u},Og:function(){return d},wC:function(){return s}});var r=n(35664),i=n(50025),o=n(76978),a=n(38823);async function s({labelSelector:e,type:t,inStore:n,$store:o,inScopeCount:a,namespace:s,transient:d=!0}){var h,p,f,m,g,v,b,y;const w=null===(h=o.getters[`${n}/schemaFor`](t))||void 0===h?void 0:h.attributes.namespaced,O=Array.isArray(s)?s:s?[s]:[],S=w&&!!s;if("undefined"===typeof a){const e=(null===(f=null===(p=o.getters[`${n}/all`](r.i2))||void 0===p?void 0:p[0])||void 0===f?void 0:f.counts)||{};S?(a=0,O.forEach(n=>{var r,i;a+=(null===(i=null===(r=null===e||void 0===e?void 0:e[t])||void 0===r?void 0:r.namespaces[n])||void 0===i?void 0:i.count)||0})):a=(null===(g=null===(m=null===e||void 0===e?void 0:e[t])||void 0===m?void 0:m.summary)||void 0===g?void 0:g.count)||0}const E=0===(a||0),x=w&&!!s&&(!O||0===O.length),_=null===e||null===(null===e||void 0===e?void 0:e.matchLabels)&&null===!e.matchExpressions,k=Object.keys(e.matchLabels||{}),C=k.length&&k.filter(e=>!e).length,A=(null===(v=null===e||void 0===e?void 0:e.matchExpressions)||void 0===v?void 0:v.length)&&e.matchExpressions.filter(e=>!e.key).length;if(E||x||_||C||A)return l([],a||0);if(null===(y=(b=o.getters)[`${n}/paginationEnabled`])||void 0===y?void 0:y.call(b)){if(u(e)&&s&&!(null===O||void 0===O?void 0:O.length))throw new Error("Either populated labelSelector or namespace/s must be supplied in order to call findPage");const r={pagination:new i.YU({labelSelector:e,filters:i.eY.createMultipleFields(O.map(e=>new i.Js({field:"metadata.namespace",value:e})))}),transient:d};let c=await o.dispatch(`${n}/findPage`,{type:t,opt:r});return d&&(c=c.data),l(c,a||0)}{let r=await o.dispatch(`${n}/findAll`,{type:t});return a=r.length,w&&(null===O||void 0===O?void 0:O.length)>0&&(r=r.filter(e=>{var t;return O.includes(null===(t=e.metadata)||void 0===t?void 0:t.namespace)}),a=r.length),(e.matchLabels||e.matchExpressions)&&(r=c(r,e,"metadata.labels")),l(r,a||0)}}const l=(e,t)=>{var n;const r=e.length||0,i=null===(n=e[0])||void 0===n?void 0:n.nameDisplay;return{matched:r,matches:e,none:0===r,sample:i,total:t||0}};function c(e,t,n){const r=(0,a.C6)(t.matchLabels,t.matchExpressions);return(0,a.wC)(e,r,n)}function u(e){var t;return!(null===(t=null===e||void 0===e?void 0:e.matchExpressions)||void 0===t?void 0:t.length)&&(0,o.Im)(null===e||void 0===e?void 0:e.matchLabels)}function d(e){if(u(e))return"";const t=[];return Object.entries((null===e||void 0===e?void 0:e.matchLabels)||{}).forEach(([e,n])=>{t.push(`${e}=${n}`)}),((null===e||void 0===e?void 0:e.matchExpressions)||[]).forEach(e=>{var n;if("In"!==e.operator||void 0===e.values)throw new Error(`Unsupported matchExpression found when converting to selector string. ${e}`);1===(null===(n=e.values)||void 0===n?void 0:n.length)?t.push(`${e.key}=${e.values[0]}`):t.push(`${e.key} in (${e.values.join(",")})`)}),t.join(",")}},34765:function(e,t,n){"use strict";n.d(t,{eB:function(){return a},fD:function(){return s}});var r=n(35664),i=n(9262),o=(n(92043),n(63905),n(4364));const a=async(e,t,n,i=!0)=>{let o;try{o=await e.dispatch("management/find",{type:r.Mc.SETTING,id:t})}catch(a){const s=e.getters["management/schemaFor"](r.Mc.SETTING),l=s.linkFor("collection");o=await e.dispatch("management/create",{type:r.Mc.SETTING,metadata:{name:t},value:n,default:n||""}),i&&await o.save({url:l})}return o},s=e=>{const t=e["management/byId"](r.Mc.SETTING,i.HG.UI_PERFORMANCE);let n={};if(null===t||void 0===t?void 0:t.value)try{n=JSON.parse(t.value)}catch(s){o.warn("ui-performance setting contains invalid data")}const a=Object.assign({},i.$8);return Object.assign(a,n||{})}},8187:function(e,t,n){"use strict";n.d(t,{Ky:function(){return i},Rd:function(){return o},zL:function(){return r}});function r(e){return`var(--${e})`}function i(e,t){const n=["info","success","warning","error"],r=n.indexOf(e),i=n.indexOf(t);return r>i}const o="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"},70560:function(e,t,n){"use strict";n.d(t,{X:function(){return o}});var r=n(76978),i=n(4364);function o(e,t,n,{warn:o=!0}={}){var a;if("function"===typeof(null===t||void 0===t?void 0:t.value))return t.value(e);if(n){const n=null===(a=null===e||void 0===e?void 0:e.metadata)||void 0===a?void 0:a.labels;return t.label&&(null===n||void 0===n?void 0:n[t.label])?n[t.label]:""}const s=(null===t||void 0===t?void 0:t.value)||(null===t||void 0===t?void 0:t.name);if(!s)return o&&i.error("No path has been defined for this column, unable to get value of cell",t),"";const l=(0,r.Jt)(e,s);return null===l||void 0===l?"":l}},20138:function(e,t,n){"use strict";n.d(t,{Ei:function(){return p},hz:function(){return f},lH:function(){return d},lo:function(){return u}});var r=n(20246),i=n.n(r),o=n(20477),a=n(70560);function s(e){return/["\n,]/.test(e)?`"${e.replace(/"/g,'""')}"`:e}function l(e){return"function"===typeof e.value||"string"===typeof e.value&&!!e.value||"function"===typeof e.getValue}function c(e,t){var n;const r=t.field.header;if(!r||t.field.isLabel)return(0,o.ag)(e,t.field);try{const t=(0,a.X)(e,r,!1,{warn:!1});return void 0!==t&&null!==t&&""!==t?t:"function"===typeof r.getValue&&null!==(n=r.getValue(e))&&void 0!==n?n:""}catch(i){return""}}function u(e,t){return(e||[]).filter(e=>!(0,o.hn)(e)&&l(e)&&(e.label||e.labelKey)).map(e=>{const n=e.label||t(e.labelKey||"");return{label:n,field:{id:(0,o.vv)(e),label:n,isLabel:!1,header:e}}})}function d(e,t){const n=[t.map(e=>s(e.label)).join(",")];return e.forEach(e=>{n.push(t.map(t=>s((0,o.ng)(c(e,t)))).join(","))}),n.join("\n")}function h(e,t){return e.map(e=>t.reduce((t,n)=>(t[n.label]=(0,o.ng)(c(e,n)),t),{}))}function p(e,t){return i().dump(h(e,t))}function f(e,t){return JSON.stringify(h(e,t),null,2)}},81268:function(e,t,n){"use strict";n.d(t,{Q_:function(){return o},lt:function(){return s},o6:function(){return l}});var r=n(95265),i=n(37327);function o(e){const t=(e?.rootGetters||e?.getters)?.["features/get"];if("function"!==typeof t)return!0;try{return!!t(r.Kg)}catch{return!1}}const a=Object.freeze({}),s="tableViewsShell";function l({providedShell:e,route:t,extensions:n}){if(e&&e!==a)return!0;const r=t?(0,i.iF)(t):void 0;return!!r&&Object.values(n?.getPlugins?.()||{}).some(e=>e.name===r&&!e.builtin)}},20477:function(e,t,n){"use strict";n.d(t,{Bb:function(){return l},Ex:function(){return g},Ks:function(){return P},MK:function(){return R},UI:function(){return O},VV:function(){return w},WA:function(){return S},ag:function(){return m},bK:function(){return u},hn:function(){return y},jf:function(){return N},lP:function(){return x},mi:function(){return E},ng:function(){return v},u$:function(){return T},vv:function(){return b}});var r=n(23464),i=n.n(r),o=n(68774),a=n(76978),s=n(70560);const l="label:",c=[o.c4.name,o.o_.name];function u(e,t){const n=e||[],r=[];for(const o of n){if(!c.includes(o))break;r.push(o)}const i=r.length?r:n.slice(0,1);return t&&n.includes(t)&&!i.includes(t)&&i.push(t),i}const d=["check","actions","spacer"],h=1e3;function p(e,t){if(e&&t)try{return(0,a.Jt)(e,t)}catch(n){return}}function f(e){return"string"===typeof e.sort?e.sort.split(":")[0]:Array.isArray(e.sort)&&"string"===typeof e.sort[0]?e.sort[0].split(":")[0]:"string"===typeof e.search&&e.search?e.search:null}function m(e,t){var n,r,i,o,a;if(!e||!t)return"";if(t.isLabel)return null!==(i=null===(r=null===(n=e.metadata)||void 0===n?void 0:n.labels)||void 0===r?void 0:r[t.labelKey])&&void 0!==i?i:"";const l=t.header;if(!l)return null!==(o=p(e,t.id))&&void 0!==o?o:"";try{const t=(0,s.X)(e,l,!1,{warn:!1});if(void 0!==t&&null!==t&&""!==t)return t}catch(d){return""}const c=f(l),u=c?p(e,c):void 0;if(void 0!==u&&null!==u&&""!==u)return u;if("function"===typeof l.getValue)try{return null!==(a=l.getValue(e))&&void 0!==a?a:""}catch(d){return""}return""}function g(e,t){if(!e||!t||t.isLabel)return m(e,t);const n=S(t),r=Array.isArray(n)?n[0]:n;if("string"===typeof r){const t=p(e,r);if(void 0!==t&&null!==t&&""!==t)return t}return m(e,t)}function v(e){if(void 0===e||null===e)return"";if(Array.isArray(e))return e.map(e=>v(e)).filter(e=>!!e).join(", ");if(e instanceof Date)return Number.isNaN(e.getTime())?"":e.toISOString();if("object"===typeof e){const{label:t}=e;return"string"===typeof t?t:""}return`${e}`}function b(e){const t=e.name||e.label||"";return`${t}`.replace(/\s+/g,"-").toLowerCase()}function y(e){return!1===(null===e||void 0===e?void 0:e.tableViews)||d.includes(b(e))}function w(e,t,n,r){const i=[],o={},a={},s=(t||[]).slice(0,h);(r||[]).forEach(e=>{const t=b(e);t&&(a[t]=e)}),(e||[]).forEach(e=>{const t=b(e);if(!t||y(e)||o[t])return;let r=e.label;if(!r&&e.labelKey&&n&&(r=n(e.labelKey)),!r||!`${r}`.trim())return;o[t]=!0;const l={id:t,label:r,isLabel:!1,header:e,paginationHeader:a[t]};(k(e)||A(s,l))&&(l.isDate=!0),i.push(l)});const c={},u=(t||[]).slice(0,h);return u.forEach(e=>{var t;const n=null===(t=null===e||void 0===e?void 0:e.metadata)||void 0===t?void 0:t.labels;n&&Object.keys(n).forEach(e=>{c[e]=!0})}),Object.keys(c).sort().forEach(e=>{i.push({id:`${l}${e}`,label:e,isLabel:!0,labelKey:e})}),i}function O(e,t){if(!t)return;const n=t.toLowerCase();return e.find(e=>e.id.toLowerCase()===n)}function S(e){if(!e)return null;if(e.isLabel)return e.labelKey?`metadata.labels[${e.labelKey}]`:null;const{search:t,sort:n}=e.paginationHeader||{};if("string"===typeof t&&t)return t;if(Array.isArray(t)){const e=t.filter(e=>"string"===typeof e&&e);if(e.length)return e}const r=Array.isArray(n)?n[0]:n;return"string"===typeof r&&r?r.split(":")[0]:null}function E(e,t=50){var n,r;const i=(null===(r=null===(n=null===e||void 0===e?void 0:e.summary)||void 0===n?void 0:n[0])||void 0===r?void 0:r.counts)||{};return Object.keys(i).map(e=>{var t,n;return{value:e,count:null!==(n=null===(t=i[e])||void 0===t?void 0:t.total)&&void 0!==n?n:0}}).filter(e=>!!e.value).sort((e,t)=>t.count-e.count||e.value.localeCompare(t.value)).slice(0,t)}function x(e,t,n=25){const r={};return(e||[]).slice(0,h).forEach(e=>{const n=g(e,t),i=Array.isArray(n)?n:[n];i.forEach(e=>{const t=v(e).trim();t&&(r[t]=(r[t]||0)+1)})}),Object.entries(r).map(([e,t])=>({value:e,count:t})).sort((e,t)=>t.count-e.count||e.value.localeCompare(t.value)).slice(0,n)}const _=["LiveDate","Date"];function k(e){return _.includes((null===e||void 0===e?void 0:e.formatter)||"")}const C=/^\d{4}-\d{2}-\d{2}T/;function A(e,t){const n=[];for(const r of e){const e=v(m(r,t));if(e&&n.push(e),25===n.length)break}return n.length>0&&n.filter(e=>C.test(e)).length>=.8*n.length}function T(e,t){let n=0;for(const r of e){const e=R(m(r,t));if(C.test(e))return!0;if(e&&25===++n)return!1}return!1}function R(e){const t=v(e).trim();return t&&"0"!==t?/^\d{11,13}$/.test(t)?new Date(Number(t)).toISOString():t:""}function N(e){return/^\d{4}-\d{2}$/.test(e)?i()(`${e}-01`).format("MMMM YYYY"):e}function P(e){const t={},n={};e.forEach(({value:e,count:r})=>{const i=R(e);C.test(i)&&(t[i.slice(0,7)]=(t[i.slice(0,7)]||0)+r,n[i.slice(0,4)]=(n[i.slice(0,4)]||0)+r)});const r=e=>Object.keys(e).sort().reverse().map(t=>({value:t,count:e[t]})),i=r(n);return(i.length>1?i:[]).concat(r(t))}},51481:function(e,t,n){"use strict";n.d(t,{Fp:function(){return h},LE:function(){return p},c2:function(){return l},qx:function(){return d}});var r=n(23464),i=n.n(r),o=n(92043),a=n(41476),s=n(35664);function l(e){return!e||e===s.x8}const c=[60,60,24],u=["sec","min","hour","day"];function d(e,t,n){const r=i()();t=t||r;const o=e.diff(t,"seconds");let a=Math.abs(o),s=1,l="?",d=0;while(a>=c[d]&&d<c.length)a/=c[d],s*=Math.floor(c[d]/10),d++;l=a<5?Math.floor(10*a)/10:Math.floor(a);const h={diff:o,absDiff:a,label:l,unitsKey:`unit.${u[d]}`,units:u[d],next:s};return n&&(h.string=`${h.label} ${n(h.unitsKey,{count:h.label})}`),h}function h(e,t){return Math.round(Math.abs(Date.parse(t)-Date.parse(e))/1e3)}const p=(e,t)=>{if(!e)return"";const n=(0,o.ZD)(t.getters["prefs/get"](a.DX)),r=(0,o.ZD)(t.getters["prefs/get"](a.G$)),s=`${n} ${r}`;return i()(e).format(s)}},50667:function(e,t,n){"use strict";function r(e,t,n){let r=e+(e.includes("?")?"&":"?");return Array.isArray(n)||(n=[n]),r+=n.map(e=>null===e?`${encodeURIComponent(t)}`:`${encodeURIComponent(t)}=${encodeURIComponent(e)}`).join("&"),r}function i(e,t){return t&&"object"===typeof t&&Object.keys(t).forEach(n=>{e=r(e,n,t[n])}),e}function o(e,t){const n=t.toLowerCase();return a([e],[443,8443],["443"])||"https"===n}function a(e,t,n){for(let r=0;r<e.length;r++){const i=e[r];if(t.includes(i))return!0;for(let e=0;e<n.length;e++){const t=`${n[e]}`,r=`${i}`;if(r!==t&&r.endsWith(t))return!0}}return!1}function s(e){const t=s.options,n=t.parser[t.strictMode?"strict":"loose"].exec(e);if(!n)throw new Error(`Cannot parse as uri: ${e}`);const r={};let i=14;while(i--)r[t.key[i]]=n[i]||"";return r.query={},r.queryStr.replace(t.q.parser,(e,n,i)=>(n&&(r[t.q.name][n]=i),"")),r}function l(e){let t=`${e.protocol}://`;return e.user&&e.password?t+=`${e.user}:${e.password}@`:e.user&&(t+=`${e.user}@`),t+=e.host,e.port&&(t+=`:${e.port}`),t+=e.path||"/",t=i(t,e.query||{}),e.anchor&&(t+=`#${e.anchor}`),t}n.d(t,{As:function(){return l},E4:function(){return o},R_:function(){return r},g:function(){return i},qg:function(){return s}}),s.options={strictMode:!1,key:["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","queryStr","anchor"],q:{name:"query",parser:/(?:^|&)([^&=]*)=?([^&]*)/g},parser:{strict:/^(?:([^:\/?#]+):)?(?:\/\/((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?))?((((?:[^?#\/]*\/)*)([^?#]*))(?:\?([^#]*))?(?:#(.*))?)/,loose:/^(?:(?![^:@]+:[^:@\/]*@)([^:\/?#.]+):)?(?:\/\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/}}},71274:function(e,t,n){"use strict";n.d(t,{A:function(){return g}}),Object.defineProperty(g,"name",{value:"default",configurable:!0});var r=n(2722),i=n.n(r),o=n(50667),a=n(35664),s=n(2841),l=n(3514),c=n.n(l),u=n(52103),d=n.n(u),h=n(68094),p=n(70500);class f{constructor(e){this.string=String(e),this.int=parseInt(this.string,10),this.empty=!e&&0!==this.int,this.isNumber=!isNaN(this.int)&&!this.string.includes("e"),this.isInt=this.isNumber&&!this.string.includes(".")}}const m=(e,t)=>{for(const n of t){const t=n(e);if(t)return t}};function g(e,{key:t="Value"}){const n=n=>r=>"."===r?.slice(0,1)?e(`validation.dns.${n}.startDot`,{key:t}):void 0,r=n=>r=>"."===r?.slice(-1)?e(`validation.dns.${n}.endDot`,{key:t}):void 0,l=n=>r=>r?.slice(0,1)?.match(/[0-9]/)?e(`validation.dns.${n}.startNumber`,{key:t}):void 0,u=n=>r=>"-"===r?.slice(0,1)?e(`validation.dns.${n}.startHyphen`,{key:t}):void 0,g=n=>r=>"-"===r?.slice(-1)?e(`validation.dns.${n}.endHyphen`,{key:t}):void 0,v=n=>r=>Number(r)<Number(n)?e("validation.minValue",{key:t,min:n}):void 0,b=n=>r=>Number(r)>Number(n)?e("validation.maxValue",{key:t,max:n}):void 0,y=([n,r])=>i=>v(n)(i)||b(r)(i)?e("validation.betweenValues",{key:t,min:n,max:r}):void 0,w=n=>r=>r.length<Number(n)?e("validation.minLength",{key:t,min:n}):void 0,O=n=>r=>r.length>Number(n)?e("validation.maxLength",{key:t,max:n}):void 0,S=([n,r])=>i=>w(n)(i)||O(r)(i)?e("validation.betweenLengths",{key:t,min:n,max:r}):void 0,E=n=>isNaN(parseInt(n,10))?e("validation.number.requiredInt",{key:t}):void 0,x=n=>!Number.isInteger(+n)||`${n}`.match(/\.+/g)?e("validation.number.requiredInt",{key:t}):void 0,_=n=>+n<0?e("validation.number.isPositive",{key:t}):void 0,k=n=>{const r=`${n}`,i=r.match(/(^0+)(.+)/);return i?e("validation.number.isOctal",{key:t}):void 0},C=n=>parseInt(n,10)<1||parseInt(n,10)>65535?e("validation.number.between",{key:t,min:"1",max:"65535"}):void 0,A=n=>{const r=n?.match(/[^${'A-Za-z0-9-'}]/g);if(r)return e("validation.chars",{key:t,count:r.length,chars:r.map(e=>" "===e?"Space":`"${e}"`).join(", ")})},T=n=>"--"===n?.substr(2,2)&&"xn"!==n?.substr(0,2)?e("validation.dns.doubleHyphen",{key:t}):void 0,R=n=>"--"===n?.substr(2,2)&&"xn"!==n?.substr(0,2)?e("validation.dns.doubleHyphen",{key:t}):void 0,N=n=>(r="")=>0===r.length?e(`validation.dns.${n}.emptyLabel`,{key:t,min:1}):void 0,P=(n,r=63)=>(i="")=>i.length>r?e(`validation.dns.${n}.tooLongLabel`,{key:t,max:r}):void 0,I=(n="")=>n.length>253?e("validation.dns.hostname.tooLong",{key:t,max:253}):void 0,M=(n="")=>"/"!==n[0]&&n.length>0?e("validation.path",{key:t}):void 0,D=n=>n||!1===n?void 0:e("validation.required",{key:t}),L=(n="")=>n.toLowerCase()!==n?e("validation.noUpperCase",{key:t}):void 0,B=t=>{try{p.M.validation(t)}catch(n){return e(p.M.message)}},$=t=>t&&!(0,h.Q6)(t)?e("validation.setting.serverUrl.https"):void 0,V=t=>t&&!(0,h.Lk)(t)?e("validation.setting.serverUrl.awsStyleEndpoint"):void 0,F=t=>(0,h.M8)(t)?e("validation.setting.serverUrl.localhost"):void 0,j=t=>(0,h.fB)(t)?e("validation.setting.serverUrl.trailingForwardSlash"):void 0,U=t=>t&&!(0,h.AY)(t)?e("validation.setting.serverUrl.url"):void 0,G=t=>t&&!(0,h.AY)(t)?e("validation.genericUrl"):void 0,H=t=>{const n=e("validation.repository.url");if(!t)return n;if(t.includes(" "))return n;const{protocol:r,authority:i,host:a,port:s,path:l}=(0,o.qg)(t);if(!a||r===a)return n;if(r&&(!/^(http|https|ssh)$/gm.test(r)||!t.startsWith("https://")&&!t.startsWith("http://")&&!t.startsWith("ssh://")))return n;if(!r&&!s&&(!i.endsWith(":")||l.startsWith("/")))return n;const c=`${a}${l.replaceAll("%20","")}`;return/^([\w\.@\:\/\-]+)([\d\/\w.-]+?)(.git){0,1}(\/)?$/gm.test(c)?void 0:n},q=t=>{const n=e("validation.oci.url");if(!t)return n;if(t.includes(" "))return n;const{protocol:r,host:i,path:a}=(0,o.qg)(t);return i&&r!==i&&t.startsWith("oci://")&&/^([\w\.@\:\/\-]+)([\d\/\w.-]+?)(\/)?$/gm.test(`${i}${a}`)?void 0:n},Q=t=>t&&!i().valid(t)?e("validation.version"):void 0,z=t=>t&&!i().validRange(t)?e("validation.semanticVersion"):void 0,K=n=>n&&!/^[a-zA-Z0-9]+$/.test(n)?e("validation.alphanumeric",{key:t}):void 0,W=n=>/^\d+[hms]$/.test(n)?void 0:e("validation.monitoring.route.interval",{key:t}),X=t=>t?.image?void 0:e("workload.validation.containerImage",{name:t.name}),Y=t=>t?.name?void 0:e("workload.validation.containerName",{name:t.name}),Z=t=>"Localhost"!==t?.securityContext?.seccompProfile?.type||t?.securityContext.seccompProfile?.localhostProfile||t?.securityContext?.privileged?void 0:e("workload.validation.localhostProfile",{name:t.name}),J=t=>t?.volumeMounts?.some(e=>!e?.mountPath)?e("workload.validation.volumeMountPath",{name:t.name}):void 0,ee=t=>t?.spec?.resources?.requests?.storage?t?.spec?.accessModes?.length?void 0:e("validation.required",{key:e("persistentVolumeClaim.accessModes")}):e("validation.required",{key:e("persistentVolumeClaim.capacity")}),te=t=>{const n=t.jobTemplate?t?.jobTemplate?.spec?.template?.spec?.containers:t?.template?.spec?.containers;return n&&n.length?n.map(e=>X(e)).find(e=>e):e("validation.required",{key:e("workload.container.titles.containers")})},ne=t=>{if(!t)return;const n=new RegExp("^([a-z\\-0-9]+:\\/\\/?)?((([a-z\\d]([a-z\\d-]*[a-z\\d])*)\\.)+[a-z]{2,}|((\\d{1,3}\\.){3}\\d{1,3}))(\\:\\d+)?"),r=n.test(t);return r?void 0:e("cluster.privateRegistry.privateRegistryUrlError")},re=e=>{const t=[A,u("label"),g("label"),T,P("label")];return m(e,t)},ie=e=>{const t=[A,u("label"),g("label"),R,N("label"),P("label",15)];return m(e,t)},oe=e=>{const t=[A,l("label"),u("label"),g("label"),T,N("label"),P("label")];return m(e,t)},ae=e=>{if(e){const t=[n("hostname"),I,r("hostname")],i=m(e,t);if(i)return i;const o=e.split("."),a=[A,u("hostname"),g("hostname"),T,N("hostname"),P("hostname")];for(let e=0;e<o.length;e++){const t=m(o[e],a);if(t)return t}}},se=e=>(e=e?e.replace(/^\*\./,""):e,ae(e)),le=t=>c()(t)?e("validation.service.externalName.none"):ae(t),ce=e=>"This is an error returned by the testRule validator",ue=t=>c()(t?.groups)?e("validation.prometheusRule.groups.required"):void 0,de=t=>n=>t&&(n||"")?.match(/^(c-.{5}|local)$/i)?e("validation.cluster.name"):void 0,he=t=>{const{name:n,idx:r}=t,i=new f(t.nodePort),o=new f(t.port),a=new f(t.targetPort);if(c()(n))return e("validation.service.ports.name.required",{position:r+1});if(!i.empty){if(!i.isInt)return e("validation.service.ports.nodePort.requiredInt",{position:r+1});if(i.int<1||i.int>65535)return e("validation.service.ports.nodePort.between",{position:r+1})}if(o.empty)return e("validation.service.ports.port.required",{position:r+1});if(!o.isInt)return e("validation.service.ports.port.requiredInt",{position:r+1});if(o.int<1||o.int>65535)return e("validation.service.ports.port.between",{position:r+1});if(o.string?.includes("."))return o;if(a.empty)return e("validation.service.ports.targetPort.required",{position:r+1});if(a.isInt){if(a.int<1||a.int>65535)return e("validation.service.ports.targetPort.between",{position:r+1})}else{const e=ie(a.string);if(e)return e}},pe=(t,n)=>{let r;return c()(t?.name)?e("validation.prometheusRule.groups.valid.name",{index:n}):c()(t.rules)?e("validation.prometheusRule.groups.valid.singleEntry",{index:n}):(t.rules.forEach((t,i)=>{const o=i+1;d()(t,"alert")&&c()(t?.alert)&&!r?r=e("validation.prometheusRule.groups.valid.rule.alertName",{groupIndex:n,ruleIndex:o}):d()(t,"record")&&c()(t?.record)&&(r=e("validation.prometheusRule.groups.valid.rule.recordName",{groupIndex:n,ruleIndex:o})),(d()(t,"expr")&&c()(t.expr)&&!r||!d()(t,"expr")&&!r)&&(r=e("validation.prometheusRule.groups.valid.rule.expr",{groupIndex:n,ruleIndex:o})),d()(t,"alert")&&(d()(t,"labels")&&c()(t.labels)&&!r||!d()(t,"labels")&&!r)&&(r=e("validation.prometheusRule.groups.valid.rule.labels",{groupIndex:n,ruleIndex:o}))}),r)},fe=e=>{const t=[...e];let n;return t.forEach((e,t,r)=>{n=pe(e,t+1),n&&(r.length=t+1)}),n},me=t=>{if(c()(t?.match)&&c()(t?.["match_re"]))return e("validation.monitoring.route.match")},ge=t=>(n=[])=>{if(n.some(e=>c()(e.verbs)))return e("validation.roleTemplate.roleTemplateRules.missingVerb");if(n.some(e=>e.resources?.length&&e.nonResourceURLs?.length))return e("validation.roleTemplate.roleTemplateRules.noResourceAndNonResource");if(t===a.lk.ROLE){if(n.some(e=>c()(e.resources)))return e("validation.roleTemplate.roleTemplateRules.missingResource");if(n.some(e=>c()(e.apiGroups)))return e("validation.roleTemplate.roleTemplateRules.missingApiGroup")}else if(n.some(e=>c()(e.resources)&&c()(e.nonResourceURLs)))return e("validation.roleTemplate.roleTemplateRules.missingOneResource")},ve=e=>{},be=t=>{const n=JSON.parse(t),r=n.type;if(!r)return e("validation.required",{key:"Type"});if("s3"===r){if(!n.accessKeyId)return e("validation.required",{key:"accessKeyId"});if(!n.secretAccessKey)return e("validation.required",{key:"secretAccessKey"});if(!n.bucketRegion)return e("validation.required",{key:"bucketRegion"});if(!n.bucketName)return e("validation.required",{key:"bucketName"})}},ye=t=>{const n=["qcow","qcow2","raw","img","iso"];if(!t||""===t)return;const r=t.split("/").pop(),i=r.split(".").pop().toLowerCase();return n.includes(i)?void 0:e("harvester.validation.image.ruleTip")},we=(t={})=>{if(!t[s.rk.IMAGE_NAME])return e("validation.required",{key:e("harvester.image.fileName")})},Oe=i=>{const o=i?.match(/[^a-z0-9.-]/g);return o?e("validation.chars",{key:t,count:o.length,chars:o.map(e=>" "===e?"Space":`"${e}"`).join(", ")}):m(i,[u("label"),g("label"),n("label"),r("label"),D])};return{absolutePath:M,alphanumeric:K,backupTarget:be,betweenLengths:S,betweenValues:y,clusterIp:ve,clusterName:de,containerImage:X,containerImages:te,containerName:Y,localhostProfile:Z,volumeMountPath:J,persistentVolumeClaimSpec:ee,cronSchedule:B,dnsLabel:re,dnsLabelIanaServiceName:ie,dnsLabelRestricted:oe,externalName:le,fileRequired:we,urlRepository:H,groupsAreValid:fe,hostname:ae,imageUrl:ye,interval:W,https:$,awsStyleEndpoint:V,localhost:F,trailingForwardSlash:j,url:U,genericUrl:G,matching:me,maxLength:O,maxValue:b,minLength:w,minValue:v,noUpperCase:L,ociRegistry:q,portNumber:C,registryUrl:ne,required:D,requiredInt:E,isInteger:x,isPositive:_,isOctal:k,roleTemplateRules:ge,ruleGroups:ue,semanticVersion:z,servicePort:he,subDomain:Oe,testRule:ce,version:Q,wildcardHostname:se}}},20652:function(e,t,n){"use strict";n.d(t,{KR:function(){return r}});const r="harvester";n(53938)},50889:function(e,t,n){"use strict";n.d(t,{EP:function(){return r},LP:function(){return o},gh:function(){return i}});const r={BACKUP_TARGET:"backup-target",CONTAINERD_REGISTRY:"containerd-registry",LOG_LEVEL:"log-level",SERVER_VERSION:"server-version",SERVER_FLAVOR:"server-flavor",UI_INDEX:"ui-index",UPGRADE_CHECKER_ENABLED:"upgrade-checker-enabled",UPGRADE_CHECKER_URL:"upgrade-checker-url",VLAN:"vlan",UI_SOURCE:"ui-source",UI_PL:"ui-pl",HTTP_PROXY:"http-proxy",ADDITIONAL_CA:"additional-ca",OVERCOMMIT_CONFIG:"overcommit-config",CLUSTER_REGISTRATION_URL:"cluster-registration-url",DEFAULT_STORAGE_CLASS:"default-storage-class",SUPPORT_BUNDLE_TIMEOUT:"support-bundle-timeout",SUPPORT_BUNDLE_EXPIRATION:"support-bundle-expiration",SUPPORT_BUNDLE_FILE_NAME:"support-bundle-file-name",SUPPORT_BUNDLE_IMAGE:"support-bundle-image",SUPPORT_BUNDLE_NODE_COLLECTION_TIMEOUT:"support-bundle-node-collection-timeout",STORAGE_NETWORK:"storage-network",RWX_NETWORK:"rwx-network",VM_FORCE_RESET_POLICY:"vm-force-reset-policy",SSL_CERTIFICATES:"ssl-certificates",SSL_PARAMETERS:"ssl-parameters",SUPPORT_BUNDLE_NAMESPACES:"support-bundle-namespaces",AUTO_DISK_PROVISION_PATHS:"auto-disk-provision-paths",RELEASE_DOWNLOAD_URL:"release-download-url",CCM_CSI_VERSION:"harvester-csi-ccm-versions",CSI_DRIVER_CONFIG:"csi-driver-config",CSI_ONLINE_EXPAND_VALIDATION:"csi-online-expand-validation",VM_TERMINATION_PERIOD:"default-vm-termination-grace-period-seconds",NTP_SERVERS:"ntp-servers",AUTO_ROTATE_RKE2_CERTS:"auto-rotate-rke2-certs",KUBECONFIG_DEFAULT_TOKEN_TTL_MINUTES:"kubeconfig-default-token-ttl-minutes",LONGHORN_V2_DATA_ENGINE_ENABLED:"longhorn-v2-data-engine-enabled",LONGHORN_V2_DATA_ENGINE_HUGEPAGE_ENABLED:"longhorn-v2-data-engine-hugepage-enabled",LONGHORN_V2_DATA_ENGINE_MEMORY_SIZE:"longhorn-v2-data-engine-memory-size",ADDITIONAL_GUEST_MEMORY_OVERHEAD_RATIO:"additional-guest-memory-overhead-ratio",UPGRADE_CONFIG:"upgrade-config",VM_MIGRATION_NETWORK:"vm-migration-network",RANCHER_CLUSTER:"rancher-cluster",MAX_HOTPLUG_RATIO:"max-hotplug-ratio",KUBEVIRT_MIGRATION:"kubevirt-migration",INSTANCE_MANAGER_RESOURCES:"instance-manager-resources",CLUSTER_POD_SECURITY_STANDARD:"cluster-pod-security-standard",MAINTENANCE_MODE_DRAIN_TIMEOUT:"maintenance-mode-drain-timeout"},i={[r.BACKUP_TARGET]:{kind:"json",from:"import",canReset:!0},[r.LOG_LEVEL]:{kind:"enum",options:["info","debug","trace"]},[r.VLAN]:{kind:"custom",from:"import",alias:"vlan"},[r.AUTO_ROTATE_RKE2_CERTS]:{kind:"json",from:"import",featureFlag:"autoRotateRke2CertsSetting"},[r.CSI_DRIVER_CONFIG]:{kind:"json",from:"import"},[r.CSI_ONLINE_EXPAND_VALIDATION]:{kind:"json",from:"import",featureFlag:"csiOnlineExpandValidation"},[r.SERVER_VERSION]:{readOnly:!0},[r.SERVER_FLAVOR]:{readOnly:!0},[r.UPGRADE_CHECKER_ENABLED]:{kind:"boolean"},[r.UPGRADE_CHECKER_URL]:{kind:"url"},[r.HTTP_PROXY]:{kind:"json",from:"import"},[r.ADDITIONAL_CA]:{kind:"multiline",canReset:!0,from:"import"},[r.OVERCOMMIT_CONFIG]:{kind:"json",from:"import"},[r.SUPPORT_BUNDLE_TIMEOUT]:{kind:"number"},[r.SUPPORT_BUNDLE_EXPIRATION]:{kind:"number"},[r.SUPPORT_BUNDLE_FILE_NAME]:{kind:"string",canReset:!0,featureFlag:"supportBundleFileNameSetting"},[r.SUPPORT_BUNDLE_NODE_COLLECTION_TIMEOUT]:{kind:"number",featureFlag:"supportBundleNodeCollectionTimeoutSetting"},[r.SUPPORT_BUNDLE_IMAGE]:{kind:"json",from:"import"},[r.STORAGE_NETWORK]:{kind:"custom",from:"import",canReset:!0},[r.RWX_NETWORK]:{kind:"json",from:"import",canReset:!0,featureFlag:"rwxNetworkSetting"},[r.VM_FORCE_RESET_POLICY]:{kind:"json",from:"import"},[r.SSL_CERTIFICATES]:{kind:"json",from:"import"},[r.SSL_PARAMETERS]:{kind:"json",from:"import",canReset:!0},[r.SUPPORT_BUNDLE_NAMESPACES]:{from:"import",canReset:!0},[r.AUTO_DISK_PROVISION_PATHS]:{canReset:!0},[r.RELEASE_DOWNLOAD_URL]:{kind:"url"},[r.CONTAINERD_REGISTRY]:{kind:"json",from:"import",canReset:!0},[r.UI_SOURCE]:{kind:"enum",options:["auto","external","bundled"]},[r.UI_INDEX]:{kind:"url"},[r.VM_TERMINATION_PERIOD]:{kind:"string",from:"import"},[r.NTP_SERVERS]:{kind:"json",from:"import",canReset:!0},[r.KUBECONFIG_DEFAULT_TOKEN_TTL_MINUTES]:{kind:"number",featureFlag:"kubeconfigDefaultTokenTTLMinutesSetting"},[r.LONGHORN_V2_DATA_ENGINE_ENABLED]:{kind:"boolean",preview:!0,featureFlag:"longhornV2LVMSupport"},[r.LONGHORN_V2_DATA_ENGINE_HUGEPAGE_ENABLED]:{kind:"boolean",preview:!0,featureFlag:"longhornV2HugepageSettings"},[r.LONGHORN_V2_DATA_ENGINE_MEMORY_SIZE]:{kind:"number",preview:!0,featureFlag:"longhornV2HugepageSettings"},[r.ADDITIONAL_GUEST_MEMORY_OVERHEAD_RATIO]:{kind:"string",from:"import"},[r.UPGRADE_CONFIG]:{kind:"json",from:"import",featureFlag:"upgradeConfigSetting",docPath:"UPGRADE_CONFIG_URL"},[r.RANCHER_CLUSTER]:{kind:"custom",from:"import",canReset:!0,featureFlag:"rancherClusterSetting"},[r.MAX_HOTPLUG_RATIO]:{kind:"number",featureFlag:"cpuMemoryHotplug"},[r.VM_MIGRATION_NETWORK]:{kind:"json",from:"import",canReset:!0,featureFlag:"vmNetworkMigration"},[r.KUBEVIRT_MIGRATION]:{kind:"json",from:"import",canReset:!0,featureFlag:"kubevirtMigration"},[r.INSTANCE_MANAGER_RESOURCES]:{kind:"json",from:"import",featureFlag:"instanceManagerResourcesSetting"},[r.CLUSTER_POD_SECURITY_STANDARD]:{kind:"json",from:"import",canReset:!0,featureFlag:"clusterPodSecurityStandardSetting"},[r.MAINTENANCE_MODE_DRAIN_TIMEOUT]:{kind:"number",canReset:!0,featureFlag:"maintenanceModeDrainTimeoutSetting"}},o={[r.CLUSTER_REGISTRATION_URL]:{kind:"custom",from:"import",canReset:!0},[r.UI_PL]:{kind:"custom",from:"import",alias:"branding"}}},32766:function(e,t,n){"use strict";n.d(t,{Zq:function(){return a},nE:function(){return s},qY:function(){return i},rk:function(){return r},us:function(){return o}});const r={VM:"kubevirt.io.virtualmachine",VMI:"kubevirt.io.virtualmachineinstance",VMIM:"kubevirt.io.virtualmachineinstancemigration",VM_TEMPLATE:"harvesterhci.io.virtualmachinetemplate",VM_VERSION:"harvesterhci.io.virtualmachinetemplateversion",IMAGE:"harvesterhci.io.virtualmachineimage",SSH:"harvesterhci.io.keypair",VOLUME:"harvesterhci.io.volume",USER:"harvesterhci.io.user",SETTING:"harvesterhci.io.setting",UPGRADE:"harvesterhci.io.upgrade",UPGRADE_LOG:"harvesterhci.io.upgradelog",SCHEDULE_VM_BACKUP:"harvesterhci.io.schedulevmbackup",BACKUP:"harvesterhci.io.virtualmachinebackup",RESTORE:"harvesterhci.io.virtualmachinerestore",NODE_NETWORK:"network.harvesterhci.io.nodenetwork",CLUSTER_NETWORK:"network.harvesterhci.io.clusternetwork",HOST_NETWORK_CONFIG:"network.harvesterhci.io.hostnetworkconfig",SUBNET:"kubeovn.io.subnet",VPC:"kubeovn.io.vpc",IP:"kubeovn.io.ip",VLAN:"kubeovn.io.vlan",IPTABLES_EIP:"kubeovn.io.iptableseip",IPTABLES_SNAT_RULE:"kubeovn.io.iptablessnatrule",IPTABLES_DNAT_RULE:"kubeovn.io.iptablesdnatrule",PROVIDER_NETWORK:"kubeovn.io.providernetwork",VPC_NAT_GATEWAY:"kubeovn.io.vpcnatgateway",VM_IMAGE_DOWNLOADER:"harvesterhci.io.virtualmachineimagedownloader",SUPPORT_BUNDLE:"harvesterhci.io.supportbundle",NETWORK_ATTACHMENT:"harvesterhci.io.networkattachmentdefinition",CLUSTER:"harvesterhci.io.management.cluster",DASHBOARD:"harvesterhci.io.dashboard",COMPONENT_HEALTH:"health.harvesterhci.io.componenthealth",HEALTH_SUMMARY:"health.harvesterhci.io.healthsummary",HEALTH_IGNORE_RULE:"health.harvesterhci.io.healthignorerule",BLOCK_DEVICE:"harvesterhci.io.blockdevice",CLOUD_TEMPLATE:"harvesterhci.io.cloudtemplate",HOST:"harvesterhci.io.host",VERSION:"harvesterhci.io.version",SNAPSHOT:"harvesterhci.io.volumesnapshot",VM_SNAPSHOT:"harvesterhci.io.vmsnapshot",ALERTMANAGERCONFIG:"harvesterhci.io.monitoring.alertmanagerconfig",CLUSTER_FLOW:"harvesterhci.io.logging.clusterflow",CLUSTER_OUTPUT:"harvesterhci.io.logging.clusteroutput",FLOW:"harvesterhci.io.logging.flow",OUTPUT:"harvesterhci.io.logging.output",STORAGE:"harvesterhci.io.storage",RESOURCE_QUOTA:"harvesterhci.io.resourcequota",KSTUNED:"node.harvesterhci.io.ksmtuned",HUGEPAGES:"node.harvesterhci.io.hugepage",PCI_DEVICE:"devices.harvesterhci.io.pcidevice",PCI_CLAIM:"devices.harvesterhci.io.pcideviceclaim",SR_IOV:"devices.harvesterhci.io.sriovnetworkdevice",VGPU_DEVICE:"devices.harvesterhci.io.vgpudevice",SR_IOVGPU_DEVICE:"devices.harvesterhci.io.sriovgpudevice",USB_DEVICE:"devices.harvesterhci.io.usbdevice",USB_CLAIM:"devices.harvesterhci.io.usbdeviceclaim",MIG_CONFIGURATION:"devices.harvesterhci.io.migconfiguration",VLAN_CONFIG:"network.harvesterhci.io.vlanconfig",VLAN_STATUS:"network.harvesterhci.io.vlanstatus",ADD_ONS:"harvesterhci.io.addon",LINK_MONITOR:"network.harvesterhci.io.linkmonitor",SECRET:"harvesterhci.io.secret",INVENTORY:"metal.harvesterhci.io.inventory",LB:"loadbalancer.harvesterhci.io.loadbalancer",IP_POOL:"loadbalancer.harvesterhci.io.ippool",HARVESTER_CONFIG:"rke-machine-config.cattle.io.harvesterconfig",LVM_VOLUME_GROUP:"harvesterhci.io.lvmvolumegroup",VMIMPORT_SOURCE_V:"migration.harvesterhci.io.vmwaresource",VMIMPORT_SOURCE_O:"migration.harvesterhci.io.openstacksource",VMIMPORT_SOURCE_OVA:"migration.harvesterhci.io.ovasource",VMIMPORT:"migration.harvesterhci.io.virtualmachineimport",MIGRATION:"migration.harvesterhci.io",FORKLIFT_PROVIDER:"forklift.konveyor.io.provider",FORKLIFT_NETWORK_MAP:"forklift.konveyor.io.networkmap",FORKLIFT_STORAGE_MAP:"forklift.konveyor.io.storagemap",FORKLIFT_PLAN:"forklift.konveyor.io.plan",FORKLIFT_MIGRATION:"forklift.konveyor.io.migration"},i="snapshot.storage.k8s.io.volumesnapshot",o="cdi.kubevirt.io.datavolume",a="storage.k8s.io.csidriver",s="snapshot.storage.k8s.io.volumesnapshotclass"},69091:function(e,t,n){"use strict";n.d(t,{A:function(){return b}});var r=n(9274);const i={key:0},o=["disabled","data-testid","tabindex","onClick","onKeyup"],a={key:0,class:"no-actions"};function s(e,t,n,s,l,c){const u=(0,r.resolveComponent)("IconOrSvg"),d=(0,r.resolveDirective)("clean-html"),h=(0,r.resolveDirective)("t");return c.showing||n.open?((0,r.openBlock)(),(0,r.createElementBlock)("div",i,[(0,r.createElementVNode)("div",{class:"background",onClick:t[0]||(t[0]=(...e)=>c.hide&&c.hide(...e)),onContextmenu:t[1]||(t[1]=(0,r.withModifiers)(()=>{},["prevent"]))},null,32),(0,r.createElementVNode)("ul",{class:"list-unstyled menu",style:(0,r.normalizeStyle)(l.style)},[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(c.menuOptions,(e,t)=>((0,r.openBlock)(),(0,r.createElementBlock)("li",{key:t,disabled:!!e.disabled||null,class:(0,r.normalizeClass)({divider:e.divider}),"data-testid":n.componentTestid+"-"+t+"-item",tabindex:e.divider?-1:0,onClick:t=>c.execute(e,t),onKeyup:[(0,r.withKeys)(t=>c.execute(e,t),["enter"]),(0,r.withKeys)(t=>c.execute(e,t),["space"])]},[e.icon||e.svg?((0,r.openBlock)(),(0,r.createBlock)(u,{key:0,icon:e.icon,src:e.svg,class:"icon",color:"header"},null,8,["icon","src"])):(0,r.createCommentVNode)("",!0),(0,r.withDirectives)((0,r.createElementVNode)("span",null,null,512),[[d,e.label]])],42,o))),128)),c.hasOptions(c.menuOptions)?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createElementBlock)("li",a,[(0,r.withDirectives)((0,r.createElementVNode)("span",null,null,512),[[h,"sortableTable.noActions"]])]))],4)])):(0,r.createCommentVNode)("",!0)}var l=n(65359),c=n(14817),u=n(35881),d=n(74607);const h="hide",p="calculate",f="show";var m={name:"ActionMenu",emits:["close","action-invoked"],components:{IconOrSvg:d.A},props:{customActions:{type:Array,default:()=>[]},open:{type:Boolean,default:!1},useCustomTargetElement:{type:Boolean,default:!1},customTargetElement:{type:HTMLElement,default:null},customTargetEvent:{type:[PointerEvent,MouseEvent],default:null},componentTestid:{type:String,default:"action-menu"}},data(){return{phase:h,style:{}}},computed:{...(0,l.L8)({targetElem:"action-menu/elem",targetEvent:"action-menu/event",shouldShow:"action-menu/showing",options:"action-menu/options"}),showing(){return this.phase!==h},menuOptions(){return this.customActions.length>0?this.customActions:this.options}},watch:{shouldShow:{handler(e){e?(this.phase=p,this.updateStyle(),this.$nextTick(()=>{this.phase===p&&(this.phase=f,this.updateStyle())})):this.phase=h}},open(){this.updateStyle()},"$route.path"(e,t){this.hide()}},methods:{hide(){this.useCustomTargetElement?this.$emit("close"):this.$store.commit("action-menu/hide")},updateStyle(){if(this.phase===f&&!this.useCustomTargetElement){const e=this.$el?.querySelector&&this.$el.querySelector(".menu"),t=this.targetEvent,n=this.targetElem;return this.style=(0,c.Tb)(e,n||t,{overlapX:!0,fudgeX:n?-2:0,fudgeY:n?20:0,positionX:n?c.Q8:c.Q7,positionY:c.Q8}),void(this.style.visibility="visible")}if(this.open&&this.useCustomTargetElement){const e=this.$el?.querySelector&&this.$el.querySelector(".menu"),t=this.customTargetElement;return this.style=(0,c.Tb)(e,t,{overlapX:!0,fudgeX:t?4:0,fudgeY:t?4:0,positionX:t?c.Q8:c.Q7,positionY:c.Q8},!0),void(this.style.visibility="visible")}this.style={}},execute(e,t,n){if(!e.disabled){if(e.invoke){const n=e.invoke;if(n&&e.enabled){const r=this.$store.getters["action-menu/resources"],i={event:t,action:e,isAlt:(0,u.nN)(t)};1===r.length&&n.apply(this,[i,r])}}else if(this.useCustomTargetElement)this.$emit("action-invoked",{action:e.action,actionData:e,event:t,...n,route:this.$route});else{const r={alt:(0,u.nN)(t)};this.$store.dispatch("action-menu/execute",{action:e,args:n,opts:r})}this.hide()}},hasOptions(e){return void 0!==e.length?e.length:Object.keys(e).length>0}}},g=(n(68814),n(47433));const v=(0,g.A)(m,[["render",s],["__scopeId","data-v-375e9eb4"]]);var b=v},76204:function(e,t,n){"use strict";n.d(t,{A:function(){return u}});var r=n(9274),i=n(65359),o=n(3252),a=n(35881),s=n(30588),l=(0,r.defineComponent)({inheritAttrs:!1,__name:"ActionMenuShell",props:{buttonVariant:{},buttonSize:{},buttonAriaLabel:{},dropdownAriaLabel:{},dataTestid:{},resource:{},customActions:{}},emits:["action-invoked"],setup(e,{emit:t}){const n=(0,i.Pj)(),l=e,c=e=>{e&&n.dispatch("action-menu/setResource",l.resource)},u=t,d=(0,o.lq)(),h=(e,t,r)=>{if(e.disabled)return;const i={action:e.action,actionData:e,event:t,...r,route:d};if(u("action-invoked",i),e.invoke){const r=e.invoke;if(r&&e.enabled){const i=n.getters["action-menu/resources"],o={event:t,action:e,isAlt:(0,a.nN)(t)};1===i.length&&r.apply(this,[o,i])}}else if(!l.customActions){const i={alt:(0,a.nN)(t)};n.dispatch("action-menu/execute",{action:e,args:r,opts:i})}},p=(0,r.computed)(()=>n.getters["action-menu/optionsArray"]),f=()=>l.customActions&&l.customActions.length>0?l.customActions:p.value;return(t,n)=>((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(s.ue),{"button-variant":e.buttonVariant||"link","button-size":e.buttonSize||"medium","button-aria-label":e.buttonAriaLabel,"dropdown-aria-label":e.dropdownAriaLabel,options:f(),"data-testid":e.dataTestid,"onUpdate:open":c,onSelect:n[0]||(n[0]=(e,t)=>h(t,e))},null,8,["button-variant","button-size","button-aria-label","dropdown-aria-label","options","data-testid"]))}});const c=l;var u=c},79535:function(e,t,n){"use strict";n.d(t,{h:function(){return h}});var r=n(9274);const i=["data-modal"],o=["aria-labelledby"];function a(e,t,n,a,s,l){return(0,r.openBlock)(),(0,r.createBlock)(r.Teleport,{to:"#modals"},[(0,r.createVNode)(r.Transition,{name:"modal-fade",appear:""},{default:(0,r.withCtx)(()=>[(0,r.createElementVNode)("div",{class:"modal-overlay","data-modal":e.name,onClick:t[1]||(t[1]=(...t)=>e.handleClickOutside&&e.handleClickOutside(...t))},[(0,r.createElementVNode)("div",(0,r.mergeProps)(e.$attrs,{id:"modal-container-element",ref:"modalRef",class:[e.customClass,"modal-container"],style:e.modalStyles,role:"dialog","aria-modal":"true","aria-labelledby":e.labelledBy,onClick:t[0]||(t[0]=(0,r.withModifiers)(()=>{},["stop"]))}),[(0,r.renderSlot)(e.$slots,"default")],16,o)],8,i)]),_:3})])}var s=n(82149);const l="body;";var c=(0,r.defineComponent)({name:"AppModal",emits:["close"],inheritAttrs:!1,props:{clickToClose:{type:Boolean,default:!0},width:{type:[Number,String],default:600,validator(e){return"number"===typeof e?e>0:"string"===typeof e&&/^(0*(?:[1-9][0-9]*|0)\.?\d*)+(px|%)$/.test(e)}},customClass:{type:String,default:""},styles:{type:String,default:""},name:{type:String,default:""},triggerFocusTrap:{type:Boolean,default:!1},returnFocusSelector:{type:String,default:""},returnFocusFirstIterableNodeSelector:{type:String,default:l},focusTrapWatcherBasedVariable:{type:Boolean,default:void 0}},computed:{labelledBy(){return this.$attrs["aria-labelledby"]||(this.hasTitle?this.titleId:void 0)},modalWidth(){if(this.isValidWidth(this.width)){const e="number"===typeof this.width?"px":"";return`${this.width}${e}`}return"600px"},stylesPropToObj(){return this.styles.split(";").map(e=>e.trim().split(":")).reduce((e,[t,n])=>({...e,[t]:n}),{})},modalStyles(){return{width:this.modalWidth,...this.stylesPropToObj}}},setup(e){const t=(0,r.useId)();if(e.triggerFocusTrap){let t=s.mG;e.returnFocusFirstIterableNodeSelector&&e.returnFocusFirstIterableNodeSelector!==l&&e.returnFocusSelector?t={...s.mG,setReturnFocus:()=>document.querySelector(e.returnFocusSelector)?e.returnFocusSelector:(0,s.$4)(document.querySelector(e.returnFocusFirstIterableNodeSelector))}:e.returnFocusSelector&&(t={...s.mG,setReturnFocus:e.returnFocusSelector});const n=(0,r.ref)(!0);(0,s.ve)(()=>{var t;return null!==(t=e.focusTrapWatcherBasedVariable)&&void 0!==t?t:n},"#modal-container-element",t,!0)}return{titleId:t}},data(){return{hasTitle:!1,titleObserver:null}},mounted(){document.addEventListener("keydown",this.handleEscapeKey),this.syncTitle();const e=(0,r.markRaw)(new MutationObserver(()=>this.syncTitle()));e.observe(this.$refs.modalRef,{childList:!0,subtree:!0}),this.titleObserver=e},beforeUnmount(){var e;document.removeEventListener("keydown",this.handleEscapeKey),null===(e=this.titleObserver)||void 0===e||e.disconnect()},methods:{syncTitle(){const e=this.$refs.modalRef,t=null===e||void 0===e?void 0:e.querySelector("[data-modal-title]");t&&(t.id=this.titleId),this.hasTitle=!!t},handleClickOutside(e){this.clickToClose&&this.$refs.modalRef&&!this.$refs.modalRef.contains(e.target)&&this.$emit("close")},handleEscapeKey(e){this.clickToClose&&"Escape"===e.key&&this.$emit("close")},isValidWidth(e){return"number"===typeof e?e>0:"string"===typeof e&&/^(0*(?:[1-9][0-9]*|0)\.?\d*)+(px|%)$/.test(e)}}}),u=(n(27509),n(47433));const d=(0,u.A)(c,[["render",a]]);var h=d},30699:function(e,t,n){"use strict";n.d(t,{R:function(){return u},A:function(){return b}});var r=n(9274);const i=["name","type","disabled","aria-disabled","tab-index","data-testid","aria-label"],o=["alt"],a={key:2,"data-testid":"async-btn-display-label"};function s(e,t,n,s,l,c){const u=(0,r.resolveDirective)("clean-tooltip"),d=(0,r.resolveDirective)("clean-html");return(0,r.openBlock)(),(0,r.createElementBlock)("button",{ref:"btn",role:"button",class:(0,r.normalizeClass)(e.classes),name:e.name,type:e.type,disabled:e.disabled,"aria-disabled":e.appearsDisabled,"tab-index":e.tabIndex,"data-testid":e.componentTestid+"-async-button","aria-label":e.stableAriaLabel||void 0,onClick:t[0]||(t[0]=(...t)=>e.clicked&&e.clicked(...t))},[e.isManualRefresh?((0,r.openBlock)(),(0,r.createElementBlock)("span",{key:0,class:(0,r.normalizeClass)({"mr-10":e.displayIcon&&"sm"!==e.size,"mr-5":e.displayIcon&&"sm"===e.size})},(0,r.toDisplayString)(e.t("action.refresh")),3)):(0,r.createCommentVNode)("",!0),e.displayIcon?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("i",{key:1,class:(0,r.normalizeClass)({icon:!0,"icon-lg":!0,[e.displayIcon]:!0,"mr-0":e.isManualRefresh}),alt:e.t("asyncButton.alt.iconAlt")},null,10,o)),[[u,e.tooltip]]):(0,r.createCommentVNode)("",!0),"text"===e.labelAs&&e.displayLabel?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("span",a,null,512)),[[u,e.tooltip],[d,e.displayLabel]]):(0,r.createCommentVNode)("",!0)],10,i)}var l={memberOfObject:(e,t)=>Object.entries(e||{}).find(([e])=>e===t),memberOfComponent:(e,t)=>e[t]},c=n(80869);const u={ACTION:"action",WAITING:"waiting",SUCCESS:"success",ERROR:"error"},d="text",h="tooltip",p="btn-disabled",f={timer:void 0};var m=(0,r.defineComponent)({props:{mode:{type:String,default:"edit"},delay:{type:Number,default:5e3},name:{type:String,default:null},disabled:{type:Boolean,default:!1},type:{type:String,default:"button"},tabIndex:{type:Number,default:null},actionColor:{type:String,default:"role-primary"},waitingColor:{type:String,default:"bg-primary"},successColor:{type:String,default:"bg-success"},errorColor:{type:String,default:"bg-error"},actionLabel:{type:String,default:null},waitingLabel:{type:String,default:null},successLabel:{type:String,default:null},errorLabel:{type:String,default:null},icon:{type:String,default:null},labelAs:{type:String,default:d},size:{type:String,default:""},currentPhase:{type:String,default:u.ACTION},componentTestid:{type:String,default:"action-button"},manual:{type:Boolean,default:!1},announceStatus:{type:Boolean,default:!0}},setup(){const e=(0,r.inject)("timer",f.timer);return{timer:e}},emits:["click"],data(){return{phase:this.currentPhase}},watch:{currentPhase(e){this.phase=e},phase(e){this.announceStatus&&e!==u.ACTION&&(0,c.iP)(this.announcementFor(e))}},computed:{classes(){const e=`${this.phase}Color`,t=l.memberOfComponent(this,e),n={btn:!0,[t]:!0};return this.size&&(n[`btn-${this.size}`]=!0),this.phase===u.WAITING&&(n[p]=!0),this.phase===u.ACTION&&(n["ready-for-action"]=!0),n},appearsDisabled(){return this.disabled||this.phase===u.WAITING},displayIcon(){const e=this.$store.getters["i18n/exists"],t=this.$store.getters["i18n/t"],n=`asyncButton.${this.mode}.${this.phase}Icon`,r=`asyncButton.default.${this.phase}Icon`;let i="";return this.icon?i=this.icon:e(n)?i=`icon-${t(n)}`:e(r)&&(i=`icon-${t(r)}`),this.isSpinning&&(i||(i="icon-spinner"),i+=" icon-spin"),i},displayLabel(){return this.labelFor(this.phase)},stableAriaLabel(){return this.labelFor(u.ACTION)},isSpinning(){return this.phase===u.WAITING},isManualRefresh(){return"manual-refresh"===this.mode},tooltip(){return this.labelAs===h?{content:this.displayLabel,hideOnTargetClick:!1}:null}},beforeUnmount(){this.timer&&clearTimeout(this.timer)},methods:{labelFor(e){const t=l.memberOfComponent(this,`${e}Label`),n=this.$store.getters["i18n/exists"],r=this.$store.getters["i18n/t"],i=`asyncButton.${this.mode}.${e}`,o=`asyncButton.default.${e}`;return t||(n(i)?r(i):n(o)?r(o):"")},announcementFor(e){const t=this.$store.getters["i18n/exists"],n=this.$store.getters["i18n/t"],r=`asyncButton.${this.mode}.${e}Announcement`;if(t(r))return n(r);const i=this.labelFor(e),o=this.labelFor(u.ACTION);if(i&&i!==o)return i;const a=`asyncButton.announcement.${o?"withLabel.":""}${e}`;return t(a)?n(a,{label:o}):""},clicked(){if(this.appearsDisabled)return;this.timer&&clearTimeout(this.timer),this.manual||(this.phase=u.WAITING);const e=e=>{this.done(e)};this.$emit("click",e)},done(e){"cancelled"===e?this.phase=u.ACTION:(this.phase=e?u.SUCCESS:u.ERROR,this.timer=setTimeout(()=>{this.timerDone()},this.delay))},timerDone(){this.phase!==u.SUCCESS&&this.phase!==u.ERROR||(this.phase=u.ACTION)},focus(){this.$refs.btn.focus()}}}),g=(n(80818),n(47433));const v=(0,g.A)(m,[["render",s],["__scopeId","data-v-045ed346"]]);var b=v},23776:function(e,t,n){"use strict";n.d(t,{A:function(){return p}});var r=n(9274);const i=["src"];function o(e,t,n,o,a,s){return(0,r.openBlock)(),(0,r.createElementBlock)("img",(0,r.mergeProps)(e.$attrs,{src:s.pathToBrandedImage}),null,16,i)}var a=n(65359),s=n(35664),l=n(9262),c=n(52148),u={props:{fileName:{type:String,required:!0},dark:{type:Boolean,default:!1},supportCustomLogo:{type:Boolean,default:!1}},data(){const e=this.$store.getters["management/all"](s.Mc.SETTING),t=e?.filter(e=>e.id===l.HG.LOGIN_BACKGROUND_LIGHT)?.[0]?.value,n=e?.filter(e=>e.id===l.HG.LOGIN_BACKGROUND_DARK)?.[0]?.value;return{managementSettings:e,uiLoginBackgroundLight:t,uiLoginBackgroundDark:n}},computed:{...(0,a.L8)({theme:"prefs/theme",brand:"management/brand"}),brandBase(){const e=this.managementSettings.filter(e=>e.id===l.HG.BRAND)[0]||{};return e.value},uiLogoLight(){const e=this.managementSettings.filter(e=>e.id===l.HG.LOGO_LIGHT)[0]||{};return e.value},uiLogoDark(){const e=this.managementSettings.filter(e=>e.id===l.HG.LOGO_DARK)[0]||{};return e.value},uiBannerLight(){const e=this.managementSettings.filter(e=>e.id===l.HG.BANNER_LIGHT)[0]||{};return e.value},uiBannerDark(){const e=this.managementSettings.filter(e=>e.id===l.HG.BANNER_DARK)[0]||{};return e.value},defaultPathToBrandedImage(){const e="dark"===this.theme?"dark/":"";try{return(0,c.mS)(`~shell/assets/images/pl/${e}${this.fileName}`)}catch{return(0,c.mS)(`~shell/assets/images/pl/${this.fileName}`)}},isDark(){return"dark"===this.theme},pathToBrandedImage(){if("rancher-logo.svg"===this.fileName||this.supportCustomLogo){if(this.isDark&&this.uiLogoDark)return this.uiLogoDark;if(this.uiLogoLight)return this.uiLogoLight;if(this.brandBase!==this.brand)try{return(0,c.mS)(`~shell/assets/brand/${this.brandBase}/${this.isDark?"dark/":""}${this.fileName}`)}catch{}}if("banner.svg"===this.fileName){if(this.isDark&&this.uiBannerDark)return this.uiBannerDark;if(this.uiBannerLight)return this.uiBannerLight}if("login-landscape.svg"===this.fileName){if(this.isDark&&this.uiLoginBackgroundDark)return this.uiLoginBackgroundDark;if(this.uiLoginBackgroundLight)return this.uiLoginBackgroundLight}if(this.brand){if(this.isDark||this.dark)try{return(0,c.mS)(`~shell/assets/brand/${this.brand}/dark/${this.fileName}`)}catch{}try{return(0,c.mS)(`~shell/assets/brand/${this.brand}/${this.fileName}`)}catch{}return this.defaultPathToBrandedImage}return this.defaultPathToBrandedImage}}},d=n(47433);const h=(0,d.A)(u,[["render",o]]);var p=h},89958:function(e,t,n){"use strict";n.d(t,{A:function(){return f}});var r=n(9274);const i=["onClick"];function o(e,t,n,o,a,s){const l=(0,r.resolveComponent)("v-select");return(0,r.openBlock)(),(0,r.createBlock)(l,(0,r.mergeProps)({ref:"button-dropdown",class:["button-dropdown btn",{disabled:n.disabled,focused:a.focused}]},e.$attrs,{"append-to-body":!0,"calculate-position":s.withPopper,searchable:!1,clearable:!1,"close-on-select":n.closeOnSelect,filterable:!1,modelValue:n.buttonLabel,options:n.dropdownOptions,"map-keydown":e.mappedKeys,"get-option-key":e=>n.optionKey?s.get(e,n.optionKey):s.getOptionLabel(e),"get-option-label":e=>s.getOptionLabel(e),selectable:n.selectable,"onSearch:blur":s.onBlur,"onSearch:focus":s.onFocus,"onUpdate:modelValue":t[1]||(t[1]=t=>e.$emit("click-action",t))}),(0,r.createSlots)({"no-options":(0,r.withCtx)(()=>[(0,r.renderSlot)(e.$slots,"no-options",{},void 0,!0)]),"selected-option":(0,r.withCtx)(e=>[(0,r.createElementVNode)("button",{tabindex:"-1",type:"button",class:"dropdown-button-two btn","data-testid":"dropdown-button",onClick:t=>s.ddButtonAction(e),onFocus:t[0]||(t[0]=(...e)=>s.focusSearch&&s.focusSearch(...e))},(0,r.toDisplayString)(e.label),41,i)]),_:2},[(0,r.renderList)(e.$slots,(t,n)=>({name:n,fn:(0,r.withCtx)(t=>["selected-option"!==n&&"function"===typeof e.$slots[n]?(0,r.renderSlot)(e.$slots,n,(0,r.normalizeProps)((0,r.guardReactiveProps)(t)),void 0,!0,0):(0,r.createCommentVNode)("",!0)])}))]),1040,["class","calculate-position","close-on-select","modelValue","options","map-keydown","get-option-key","get-option-label","selectable","onSearch:blur","onSearch:focus"])}var a=n(60425),s=n(76978),l=n(8138),c=n.n(l),u=n(89626),d={emits:["dd-button-action","click-action"],mixins:[u.A],props:{buttonLabel:{default:"",type:String},closeOnSelect:{default:!0,type:Boolean},disabled:{default:!1,type:Boolean},dropdownOptions:{default:()=>[],type:Array},optionKey:{default:null,type:String},optionLabel:{default:"label",type:String},size:{default:null,type:String},value:{default:null,type:String},placement:{default:"bottom-start",type:String},selectable:{default:e=>!e||!e.disabled&&"group"!==e.kind&&"divider"!==e.kind&&!e.loading,type:Function}},data(){return{focused:!1}},methods:{withPopper(e,t,{width:n}){const r=t.$refs.search.clientWidth,i=e.clientWidth;e.style.width=i<r?`${r}px`:"min-content";const o=(0,a.n4)(t.$refs.toggle,e,{placement:this.placement||"bottom-start",modifiers:[{name:"offset",options:{offset:[-2,2]}},{name:"toggleClass",enabled:!0,phase:"write",fn({state:e}){t.$el.setAttribute("x-placement",e.placement)}}]});return()=>o.destroy()},ddButtonAction(e){this.focusSearch(),this.$emit("dd-button-action",e)},getOptionLabel(e){return c()(e)?e:this.$attrs["get-option-label"]?this.$attrs["get-option-label"](e):(0,s.Jt)(e,this.optionLabel)?this.localizedLabel?this.$store.getters["i18n/t"]((0,s.Jt)(e,this.optionLabel)):(0,s.Jt)(e,this.optionLabel):e},onFocus(){return this.onFocusLabeled()},onFocusLabeled(){this.focused=!0},onBlur(){return this.onBlurLabeled()},onBlurLabeled(){this.focused=!1},focusSearch(){this.$nextTick(()=>{const e=this.$refs["button-dropdown"].searchEl;e&&e.focus()})},get:s.Jt}},h=(n(9722),n(47433));const p=(0,h.A)(d,[["render",o],["__scopeId","data-v-2ab9ff7a"]]);var f=p},25375:function(e,t,n){"use strict";n.d(t,{A:function(){return h}});var r=n(9274);const i={class:"btn-group"},o=["data-testid","disabled","aria-label","aria-pressed","onClick"],a=["alt"],s={key:2};function l(e,t,n,l,c,u){const d=(0,r.resolveComponent)("t"),h=(0,r.resolveDirective)("clean-tooltip"),p=(0,r.resolveDirective)("trim-whitespace");return(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("div",i,[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(u.optionObjects,(t,i)=>(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:i,"data-testid":`button-group-child-${i}`,type:"button",class:(0,r.normalizeClass)(t.class),disabled:n.disabled||t.disabled,role:"button","aria-label":u.actionAriaLabel(t),"aria-pressed":u.isPressed(t),onClick:e=>u.change(t.value)},[(0,r.renderSlot)(e.$slots,"option",{label:t.label,value:t.value},()=>[t.icon?((0,r.openBlock)(),(0,r.createElementBlock)("i",{key:0,class:(0,r.normalizeClass)({icon:!0,[t.icon]:!0,[`icon-${n.iconSize}`]:!!n.iconSize}),alt:u.actionAriaLabel(t)},null,10,a)):(0,r.createCommentVNode)("",!0),t.labelKey?((0,r.openBlock)(),(0,r.createBlock)(d,{key:1,k:t.labelKey},null,8,["k"])):t.label?((0,r.openBlock)(),(0,r.createElementBlock)("span",s,(0,r.toDisplayString)(t.label),1)):(0,r.createCommentVNode)("",!0)],!0)],10,o)),[[h,t.tooltipKey?e.t(t.tooltipKey):t.tooltip]])),128))])),[[p]])}var c={emits:["update:value"],props:{value:{type:[String,Number,Boolean,Object],required:!0},inactiveClass:{type:String,default:"bg-disabled"},activeClass:{type:String,default:"bg-primary"},options:{type:Array,required:!0},iconSize:{type:String,default:null},disabled:{type:Boolean,default:!1},size:{type:String,default:"large",validator:e=>["small","medium","large"].includes(e)}},computed:{sizeClass(){return{small:"btn-sm",medium:"btn-md",large:null}[this.size]},optionObjects(){const e=this.value;return this.options.map(t=>{let n;n=t&&"object"===typeof t&&"undefined"!==typeof t.value?Object.assign({},t):{label:t,value:t};const r=e===n.value;return n.class={btn:!0,[this.sizeClass]:!!this.sizeClass,[this.inactiveClass]:!r,[this.activeClass]:r},n})}},methods:{change(e){this.$emit("update:value",e)},actionDescription(e){const t=e.tooltipKey?this.t(e.tooltipKey):e.tooltip,n=e.labelKey?this.t(e.labelKey):e.label;return t||n||""},actionAriaLabel(e){const t=e.ariaLabel,n=e.labelKey?this.t(e.labelKey):e.label,r=e.tooltipKey?this.t(e.tooltipKey):e.tooltip;return t||r||n||void 0},isPressed(e){return this.value===e.value}}},u=(n(7499),n(47433));const d=(0,u.A)(c,[["render",l],["__scopeId","data-v-d29e11fe"]]);var h=d},56601:function(e,t,n){"use strict";n.d(t,{A:function(){return l}});var r=n(9274);const i=["alt"];var o=(0,r.defineComponent)({__name:"ButtonMultiAction",props:{borderless:{type:Boolean},invisible:{type:Boolean}},emits:["click"],setup(e){const t=e,n=(0,r.computed)(()=>({borderless:null===t||void 0===t?void 0:t.borderless,invisible:null===t||void 0===t?void 0:t.invisible}));return(e,t)=>((0,r.openBlock)(),(0,r.createElementBlock)("button",{type:"button",class:(0,r.normalizeClass)(["btn btn-sm role-multi-action actions",n.value]),role:"button",onClick:t[0]||(t[0]=t=>e.$emit("click",t))},[(0,r.createElementVNode)("i",{class:"icon icon-actions",alt:e.t("sortableTable.tableActionsImgAlt")},null,8,i)],2))}}),a=(n(83520),n(47433));const s=(0,a.A)(o,[["__scopeId","data-v-a3361b40"]]);var l=s},6963:function(e,t,n){"use strict";n.d(t,{A:function(){return Q}});var r=n(9274);const i={class:"code-mirror code-mirror-container"},o={class:"codemirror-container"};function a(e,t,n,a,s,l){const c=(0,r.resolveComponent)("RcCodeMirror");return(0,r.openBlock)(),(0,r.createElementBlock)("div",i,[(0,r.createElementVNode)("div",o,[(0,r.createVNode)(c,{"model-value":e.value,language:e.language,keymap:e.keymap,theme:"rancher",variant:e.variant,"read-only":e.isReadOnly,"line-numbers":e.lineNumbers,"fold-gutter":e.foldGutter,"line-wrapping":e.lineWrapping,"keymap-indicator":e.showKeyMapBox,linter:e.linter,extensions:e.combinedExtensions,"aria-label":e.options.screenReaderLabel,onReady:e.onReady,"onUpdate:modelValue":e.onInput,onFocus:e.onFocus,onBlur:e.onBlur},null,8,["model-value","language","keymap","variant","read-only","line-numbers","fold-gutter","line-wrapping","keymap-indicator","linter","extensions","aria-label","onReady","onUpdate:modelValue","onFocus","onBlur"])])])}var s=n(20246),l=n.n(s),c=n(76528),u=n(63854),d=n(41476),h=n(14220),p=n(81068),f=n(61163),m=n(37323),g=n(29097),v=n(43865),b=n(4364);const y=["mode","readOnly","lint","lineNumbers","foldGutter","lineWrapping","screenReaderLabel"],w="See https://codemirror.net/docs/migration/",O=new Set;function S(e,t){O.has(e)||(O.add(e),b.warn(`[CodeMirror] ${e} is from CodeMirror 5 and is deprecated. ${t} ${w}`))}const E=new WeakMap;function x(e){var t;let n=E.get(e);return n||(n={name:(null===(t=e.state.facet(f.language))||void 0===t?void 0:t.name)||"null"},E.set(e,n)),n}const _=e=>{const{state:t}=e;return e.dispatch(t.update(t.changeByRange(e=>{const n=t.doc.lineAt(e.from),r=(0,c.countColumn)(n.text.slice(0,e.from-n.from),t.tabSize),i=" ".repeat(t.tabSize-r%t.tabSize);return{changes:{from:e.from,to:e.to,insert:i},range:c.EditorSelection.cursor(e.from+i.length)}}),{scrollIntoView:!0,userEvent:"input"})),!0},k={foldAll:e=>"yamlcomments"===x(e).fold?((0,u.ji)(e),!0):(0,f.foldAll)(e),unfoldAll:f.unfoldAll,fold:f.foldCode,unfold:f.unfoldCode,toggleFold:f.toggleFold,insertSoftTab:_,indentMore:m.indentMore,indentLess:m.indentLess,indentAuto:m.indentSelection,newlineAndIndent:m.insertNewlineAndIndent,undo:m.undo,redo:m.redo,selectAll:m.selectAll,goDocStart:m.cursorDocStart,goDocEnd:m.cursorDocEnd,toggleComment:m.toggleComment,autocomplete:g.startCompletion,find:v.openSearchPanel,findNext:v.findNext,findPrev:v.findPrevious};function C(e,t){const n=k[t];return n?n(e):(S(`The \`${t}\` command`,"It is not supported and does nothing."),!1)}function A(e,t){const n=e.state.doc.lineAt(t);return{line:n.number-1,ch:t-n.from}}function T(e,{line:t,ch:n}){const{doc:r}=e.state,i=r.line(Math.min(Math.max(t+1,1),r.lines));return i.from+Math.min(Math.max(n,0),i.length)}const R={getValue:{replacement:"Use `view.state.doc.toString()`.",run:e=>e.state.doc.toString()},setValue:{replacement:"Use `view.dispatch({ changes })`.",run:(e,t)=>e.dispatch({changes:{from:0,to:e.state.doc.length,insert:null!==t&&void 0!==t?t:""}})},refresh:{replacement:"CodeMirror 6 measures itself, use `view.requestMeasure()` if needed.",run:e=>e.requestMeasure()},getWrapperElement:{replacement:"Use `view.dom`.",run:e=>e.dom},getMode:{replacement:"Configure languages and folding with extensions.",run:e=>x(e)},execCommand:{replacement:"Call the CodeMirror 6 command, e.g. `foldAll(view)` from @codemirror/language.",run:(e,t)=>{C(e,t)}},somethingSelected:{replacement:"Use `view.state.selection.ranges.some((r) => !r.empty)`.",run:e=>e.state.selection.ranges.some(e=>!e.empty)},getSelection:{replacement:"Use `view.state.sliceDoc(from, to)` with the selection ranges.",run:(e,t="\n")=>e.state.selection.ranges.map(t=>e.state.sliceDoc(t.from,t.to)).join(t)},replaceSelection:{replacement:"Use `view.dispatch(view.state.replaceSelection(text))`.",run:(e,t)=>e.dispatch(e.state.replaceSelection(t))},indentSelection:{replacement:"Use `indentMore`, `indentLess` or `indentSelection` from @codemirror/commands.",run:(e,t)=>{"add"===t?(0,m.indentMore)(e):"subtract"===t?(0,m.indentLess)(e):(0,m.indentSelection)(e)}},getCursor:{replacement:"Use `view.state.selection.main.head`.",run:e=>A(e,e.state.selection.main.head)},setCursor:{replacement:"Use `view.dispatch({ selection })`.",run:(e,t,n)=>{const r="number"===typeof t?{line:t,ch:null!==n&&void 0!==n?n:0}:t;e.dispatch({selection:{anchor:T(e,r)},scrollIntoView:!0})}},lineCount:{replacement:"Use `view.state.doc.lines`.",run:e=>e.state.doc.lines},getLine:{replacement:"Use `view.state.doc.line(number).text`, whose line numbers start at 1.",run:(e,t)=>t>=0&&t<e.state.doc.lines?e.state.doc.line(t+1).text:void 0},foldLinesMatching:{replacement:"Use `foldMatchingLines(view, regex)` from @components/RcCodeMirror.",run:(e,t)=>(0,u.sN)(e,t)},foldYaml:{replacement:"Use `foldYamlPath(view, path)` from @components/RcCodeMirror.",run:(e,t)=>(0,u.Um)(e,t)}},N=Symbol("codemirror5");function P(e){return e[N]||(Object.entries(R).forEach(([t,{replacement:n,run:r}])=>{t in e||Object.defineProperty(e,t,{configurable:!0,value:(...i)=>(S(`\`${t}()\``,n),r(e,...i))})}),Object.defineProperty(e,N,{value:!0})),e}const I={Esc:"Escape",Up:"ArrowUp",Down:"ArrowDown",Left:"ArrowLeft",Right:"ArrowRight",Del:"Delete",Ins:"Insert"};function M(e){return e.split(" ").map(e=>{const[,t,n]=e.match(/^((?:(?:Shift|Ctrl|Alt|Cmd|Meta|Mod)-)*)(.+)$/)||["","",e];return`${t}${I[n]||(/^[A-Z]$/.test(n)?n.toLowerCase():n)}`}).join(" ")}const D=[c.EditorState.languageData.of(()=>[{autocomplete:g.completeAnyWord}]),(0,g.autocompletion)({activateOnTyping:!1})];function L(e){let t=!1;const n=[];return Object.entries(e||{}).forEach(([e,r])=>{const i=M(e);"function"===typeof r?n.push({key:i,run:e=>"CodeMirror.Pass"!==String(r(P(e)))}):"string"===typeof r&&(t=t||"autocomplete"===r,n.push({key:i,run:e=>C(e,r)}))}),[c.Prec.high(p.keymap.of(n)),t?D:[]]}function B(e){return e.indentWithTabs?f.indentUnit.of("\t"):"number"===typeof e.indentUnit?f.indentUnit.of(" ".repeat(e.indentUnit)):[]}const $={extraKeys:{replacement:"Pass a keymap with the `extensions` prop, e.g. `Prec.high(keymap.of(bindings))`.",extension:e=>L(e)},tabSize:{replacement:"Pass `EditorState.tabSize.of(size)` with the `extensions` prop.",extension:e=>"number"===typeof e&&e>0?c.EditorState.tabSize.of(e):[]},indentUnit:{replacement:"Pass `indentUnit.of(unit)` from @codemirror/language with the `extensions` prop.",extension:(e,t)=>t.indentWithTabs?[]:B(t)},indentWithTabs:{replacement:"Pass `indentUnit.of('\\t')` from @codemirror/language with the `extensions` prop.",extension:(e,t)=>B(t)},styleActiveLine:{replacement:"Pass `highlightActiveLine()` from @codemirror/view with the `extensions` prop.",extension:e=>e?(0,p.highlightActiveLine)():[]},cursorBlinkRate:{replacement:"Pass `drawSelection({ cursorBlinkRate })` from @codemirror/view with the `extensions` prop.",extension:e=>"number"===typeof e?(0,p.drawSelection)({cursorBlinkRate:Math.max(e,0)}):[]}};function V(e={}){return Object.entries(e||{}).reduce((t,[n,r])=>{if(y.includes(n)||void 0===r)return t;const i=$[n];return i?(S(`The \`${n}\` option`,i.replacement),t.push(i.extension(r,e)),t):(S(`The \`${n}\` option`,"It has no effect."),t)},[])}const F={sublime:"sublime",vim:"vim",emacs:"emacs"};function j(e){return"yaml"===e||"text/x-yaml"===e?"yaml":"json"===e||"application/json"===e||"object"===typeof e&&(null===e||void 0===e?void 0:e.json)?"json":"javascript"===e||"text/javascript"===e||"object"===typeof e&&"javascript"===(null===e||void 0===e?void 0:e.name)?"javascript":void 0}function U(e,t){var n;const{mark:r,message:i}=e,o=Math.min(Math.max(null!==(n=null===r||void 0===r?void 0:r.position)&&void 0!==n?n:0,0),t);return{from:o,to:o,severity:"error",message:(i||String(e)).split("\n")[0]}}var G=(0,r.defineComponent)({name:"CodeMirror",components:{RcCodeMirror:u.st},emits:["onReady","onInput","onFocus","validationChanged"],props:{mode:{type:String,default:h.G5},value:{type:String,required:!0},options:{type:Object,default:()=>({})},extensions:{type:Array,default:()=>[]},asTextArea:{type:Boolean,default:!1},showKeyMapBox:{type:Boolean,default:!1}},data(){return{view:null,hasLintErrors:!1,lintedValue:null,lintError:null}},computed:{isDisabled(){return this.mode===h.nW},isReadOnly(){var e;return this.isDisabled||!!(null===(e=this.options)||void 0===e?void 0:e.readOnly)},language(){return j(this.options&&"mode"in this.options?this.options.mode:"yaml")},lintEnabled(){var e;return!!(null===(e=this.options)||void 0===e?void 0:e.lint)&&"yaml"===this.language},linter(){if(this.lintEnabled&&!this.isReadOnly)return e=>{const t=e.state.doc.toString();return t!==this.lintedValue&&this.lint(t),this.lintError?[U(this.lintError,t.length)]:[]}},variant(){return this.asTextArea?"input":"editor"},lineNumbers(){var e,t;return null===(t=null===(e=this.options)||void 0===e?void 0:e.lineNumbers)||void 0===t||t},foldGutter(){var e,t;return null===(t=null===(e=this.options)||void 0===e?void 0:e.foldGutter)||void 0===t||t},lineWrapping(){var e,t;return null===(t=null===(e=this.options)||void 0===e?void 0:e.lineWrapping)||void 0===t||t},keymapPref(){return this.$store.getters["prefs/get"](d.aP)},keymap(){return F[this.keymapPref]||"default"},phrases(){const e=[["Fold line","codeMirror.foldLine"],["Unfold line","codeMirror.unfoldLine"],["Press Escape, then Tab to leave the editor","codeMirror.leaveEditor"],["Find","codeMirror.search.find"],["next","codeMirror.search.next"],["previous","codeMirror.search.previous"],["all","codeMirror.search.all"],["match case","codeMirror.search.matchCase"],["regexp","codeMirror.search.regexp"],["by word","codeMirror.search.byWord"],["Replace","codeMirror.search.replaceField"],["replace","codeMirror.search.replace"],["replace all","codeMirror.search.replaceAll"],["close","codeMirror.search.close"],["Clear search","codeMirror.search.clear"],["$1 of $2","codeMirror.search.count",{current:"$1",total:"$2"}],["Key mapping: $","codeMirror.keymap.indicatorToolip",{name:"$"}],["Hide key mapping: $","codeMirror.keymap.hideIndicator",{name:"$"}],["Vim","prefs.keymap.vim"],["Emacs","prefs.keymap.emacs"]],t=this.$store.getters["i18n/exists"]||(()=>!0);return c.EditorState.phrases.of(Object.fromEntries(e.filter(([,e])=>t(e)).map(([e,t,n])=>[e,this.t(t,n)])))},combinedExtensions(){return[this.phrases,...V((0,r.toRaw)(this.options)),...this.extensions.map(e=>(0,r.toRaw)(e))]}},watch:{hasLintErrors(e){this.$emit("validationChanged",!e)},value(e){this.lint(e)}},methods:{lint(e){if(this.lintEnabled&&e!==this.lintedValue){try{l().loadAll(e||"",()=>{}),this.lintError=null}catch(t){this.lintError=t}this.lintedValue=e,this.hasLintErrors=!!this.lintError}},focus(){var e;null===(e=this.view)||void 0===e||e.focus()},refresh(){var e;null===(e=this.view)||void 0===e||e.requestMeasure()},avoidHostShortcuts(e){var t,n;if(window.__codemirror)return;const r=null===(t=this.$.appContext.directives)||void 0===t?void 0:t.shortkey;null===(n=null===r||void 0===r?void 0:r.beforeMount)||void 0===n||n.call(r,e.contentDOM,{modifiers:{avoid:!0}},null)},onReady(e){this.view=(0,r.markRaw)(e),this.avoidHostShortcuts(e),this.$emit("validationChanged",!0),this.lint(this.value),this.$emit("onReady",P(e))},onInput(e){this.lint(e),this.$emit("onInput",e)},onFocus(){this.$emit("onFocus",!0)},onBlur(){this.$emit("onFocus",!1)},updateValue(e){const t=this.view;t&&t.state.doc.toString()!==e&&t.dispatch({changes:{from:0,to:t.state.doc.length,insert:e||""}})}}}),H=(n(26042),n(47433));const q=(0,H.A)(G,[["render",a]]);var Q=q},97007:function(e,t,n){"use strict";n.d(t,{A:function(){return u}});var r=n(9274);function i(e,t,n,i,o,a){const s=(0,r.resolveComponent)("AsyncButton");return(0,r.openBlock)(),(0,r.createBlock)(s,(0,r.mergeProps)({icon:"icon-copy","show-label":n.showLabel,"action-label":a.labels.action,"waiting-label":a.labels.waiting,"success-label":a.labels.success,"error-label":a.labels.error},e.$attrs,{"success-color":e.$attrs["action-color"]||"role-primary","waiting-color":e.$attrs["action-color"]||"role-primary",delay:2e3,onClick:a.clicked}),null,16,["show-label","action-label","waiting-label","success-label","error-label","success-color","waiting-color","onClick"])}var o=n(30699),a=n(48881),s={components:{AsyncButton:o.A},props:{text:{type:String,required:!0},showLabel:{type:Boolean,default:!0}},computed:{labels(){const e=this.$store.getters["i18n/exists"],t=this.$store.getters["i18n/t"],n=(n,r)=>"function"===typeof e&&e(n)?t(n):r;return{action:n("copyToClipboard.action","Copy"),waiting:n("copyToClipboard.waiting","Copying..."),success:n("copyToClipboard.success","Copied!"),error:n("copyToClipboard.error","Error Copying")}}},methods:{clicked(e){(0,a.e)(this.text).then(()=>{e(!0)}).catch(()=>{e(!1)})}}},l=(n(40617),n(47433));const c=(0,l.A)(s,[["render",i],["__scopeId","data-v-87bbedf0"]]);var u=c},2922:function(e,t,n){"use strict";n.d(t,{A:function(){return rt}});var r=n(9274);const i={key:0,class:"description"},o={key:0,id:"cru-errors",class:"cru__errors",role:"alert","aria-live":"assertive"},a={key:1,class:"subtypes-container cru__content"},s=["data-testid","aria-label","onClick","onKeyup"],l={class:"subtype-container"},c={class:"subtype-logo"},u=["src","alt"],d={key:1,class:"round-image"},h={key:0,class:"banner-abbrv"},p={key:0},f={key:1},m={class:"subtype-body"},g={key:0},v={key:1},b=["href"],y={key:1,class:"description"},w={key:0},O={key:1},S={key:0,class:"resource-container cru__content cru__content-wizard"},E={class:"controls-steps"},x=["onClick"],_=["disabled","onClick"],k=["data-testid"],C={key:4,class:"cru-resource-yaml-container resource-container cru__content"},A={class:"controls-middle"},T=["data-testid","onClick"],R=["data-testid","disabled","onClick"],N={key:0,class:"controls-right"},P=["data-testid","onClick"];function I(e,t,n,I,M,D){const L=(0,r.resolveComponent)("Banner"),B=(0,r.resolveComponent)("RcHeading"),$=(0,r.resolveComponent)("RcSeparator"),V=(0,r.resolveComponent)("t"),F=(0,r.resolveComponent)("AsyncButton"),j=(0,r.resolveComponent)("CruResourceFooter"),U=(0,r.resolveComponent)("Wizard"),G=(0,r.resolveComponent)("TableOfContents"),H=(0,r.resolveComponent)("ResourceYaml"),q=(0,r.resolveDirective)("clean-html");return(0,r.openBlock)(),(0,r.createElementBlock)("section",{ref:"cru-form",class:(0,r.normalizeClass)([{"show-toc":n.showToc},"cru"])},[(0,r.renderSlot)(e.$slots,"noticeBanner",{},void 0,!0),n.description?((0,r.openBlock)(),(0,r.createElementBlock)("p",i,(0,r.toDisplayString)(n.description),1)):(0,r.createCommentVNode)("",!0),((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(D.isView?"div":"form"),{value:n.resource,"data-testid":"cru-form",class:"create-resource-container cru__form",onSubmit:t[6]||(t[6]=(0,r.withModifiers)(()=>{},["prevent"])),onKeydown:t[7]||(t[7]=(0,r.withKeys)(e=>D.onPressEnter(e),["enter"]))},{default:(0,r.withCtx)(()=>[D.hasErrors?((0,r.openBlock)(),(0,r.createElementBlock)("div",o,[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(n.errors,(e,t)=>((0,r.openBlock)(),(0,r.createBlock)(L,{key:t,color:"error","data-testid":`error-banner${t}`,label:D.stringify(D.mappedErrors[e].message),icon:D.mappedErrors[e].icon,closable:!0,onClose:e=>D.closeError(t)},null,8,["data-testid","label","icon","onClose"]))),128))])):(0,r.createCommentVNode)("",!0),D.showSubtypeSelection?((0,r.openBlock)(),(0,r.createElementBlock)("div",a,[(0,r.renderSlot)(e.$slots,"subtypes",{subtypes:n.subtypes},()=>[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(n.subtypes,(i,o)=>((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:o,class:(0,r.normalizeClass)(["subtype-banner",{selected:i.id===D._selectedSubtype}]),"data-testid":`subtype-banner-item-${i.id}`,tabindex:"0","aria-disabled":!1,"aria-label":i.description?`${i.label} - ${i.description}`:i.label,role:"link",onClick:e=>D.selectType(i.id,e),onKeyup:(0,r.withKeys)(e=>D.selectType(i.id,e),["enter","space"])},[(0,r.renderSlot)(e.$slots,"subtype-content",{},()=>[(0,r.createElementVNode)("div",l,[(0,r.createElementVNode)("div",c,[i.bannerImage?((0,r.openBlock)(),(0,r.createElementBlock)("img",{key:0,src:i.bannerImage,alt:(n.resource.type?n.resource.type+": ":"")+(i.label||"")},null,8,u)):((0,r.openBlock)(),(0,r.createElementBlock)("div",d,[i.bannerAbbrv?((0,r.openBlock)(),(0,r.createElementBlock)("div",h,[e.$store.getters["i18n/exists"](i.bannerAbbrv)?((0,r.openBlock)(),(0,r.createElementBlock)("span",p,(0,r.toDisplayString)(e.t(i.bannerAbbrv)),1)):((0,r.openBlock)(),(0,r.createElementBlock)("span",{key:1,style:(0,r.normalizeStyle)({fontSize:M.abbrSizes[i.bannerAbbrv.length]})},(0,r.toDisplayString)(i.bannerAbbrv),5))])):((0,r.openBlock)(),(0,r.createElementBlock)("div",f,(0,r.toDisplayString)(i.id.slice(0,1).toUpperCase()),1))]))]),(0,r.createElementVNode)("div",m,[(0,r.createElementVNode)("div",{class:(0,r.normalizeClass)(["title",{"with-description":!!i.description}])},[(0,r.createVNode)(B,{size:5,class:"subtype-name"},{default:(0,r.withCtx)(()=>[e.$store.getters["i18n/exists"](i.label)?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("span",g,null,512)),[[q,e.t(i.label)]]):((0,r.openBlock)(),(0,r.createElementBlock)("span",v,(0,r.toDisplayString)(i.label),1))]),_:2},1024),i.docLink?((0,r.openBlock)(),(0,r.createElementBlock)("a",{key:0,href:i.docLink,target:"_blank",rel:"noopener nofollow",class:"flex-right"},[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("generic.moreInfo"))+" ",1),t[8]||(t[8]=(0,r.createElementVNode)("i",{class:"icon icon-external-link"},null,-1))],8,b)):(0,r.createCommentVNode)("",!0)],2),i.description?((0,r.openBlock)(),(0,r.createBlock)($,{key:0})):(0,r.createCommentVNode)("",!0),i.description?((0,r.openBlock)(),(0,r.createElementBlock)("div",y,[e.$store.getters["i18n/exists"](i.description)?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("span",w,null,512)),[[q,e.t(i.description,{},!0)]]):((0,r.openBlock)(),(0,r.createElementBlock)("span",O,(0,r.toDisplayString)(i.description),1))])):(0,r.createCommentVNode)("",!0)])])],!0)],42,s))),128))],!0)])):(0,r.createCommentVNode)("",!0),M.showAsForm&&n.steps.length?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:2},[D._selectedSubtype||!n.subtypes.length?((0,r.openBlock)(),(0,r.createElementBlock)("div",S,[n.resource?((0,r.openBlock)(),(0,r.createBlock)(U,{key:0,ref:"Wizard","header-mode":n.mode,steps:n.steps,"edit-first-step":n.stepsOptions.editFirstStep,errors:n.errors,"finish-mode":n.finishMode,"before-go-to-step":D.wizardBeforeGoToStep,class:"wizard",onError:t[2]||(t[2]=e=>n.errors=e)},{stepContainer:(0,r.withCtx)(({activeStep:t})=>[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(n.steps,(n,i)=>((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:i},[n.name===t.name||n.hidden?((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:n.name,class:(0,r.normalizeClass)(["step-container__step",{hide:n.name!==t.name&&n.hidden}])},[(0,r.renderSlot)(e.$slots,n.name,{step:n},void 0,!0)],2)):(0,r.createCommentVNode)("",!0)],64))),128))]),controlsContainer:(0,r.withCtx)(({showPrevious:i,next:o,back:a,activeStep:s,canNext:l,activeStepIndex:c,visibleSteps:u})=>[(0,r.createVNode)(j,{class:"cru__footer",mode:n.mode,"is-form":M.showAsForm,"show-cancel":n.showCancel,onCancelConfirmed:D.confirmCancel},(0,r.createSlots)({default:(0,r.withCtx)(()=>[(0,r.createElementVNode)("div",E,[D.showYaml?((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:0,type:"button",class:"btn role-secondary",onClick:t[0]||(t[0]=(...e)=>D.showPreviewYaml&&D.showPreviewYaml(...e))},[(0,r.createVNode)(V,{k:"cruResource.previewYaml"})])):(0,r.createCommentVNode)("",!0),i?((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:1,type:"button",class:"btn role-secondary",onClick:e=>a()},[(0,r.createVNode)(V,{k:"wizard.previous"})],8,x)):(0,r.createCommentVNode)("",!0),c===u.length-1?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:2},[D.showSubtypeSelection||D.isView?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createBlock)(F,{key:0,ref:"save",disabled:!s.ready,mode:n.finishButtonMode||n.mode,onClick:t[1]||(t[1]=t=>e.$emit("finish",t))},null,8,["disabled","mode"]))],64)):((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:3,disabled:!l||M.nextValidating,type:"button",class:"btn role-primary",onClick:e=>D.handleNext(o,s)},[(0,r.createVNode)(V,{k:"wizard.next"})],8,_))])]),_:2},[(0,r.renderList)(e.$slots,(t,n)=>({name:n,fn:(0,r.withCtx)(t=>[D.shouldProvideSlot(n)?(0,r.renderSlot)(e.$slots,n,(0,r.normalizeProps)((0,r.guardReactiveProps)(t)),void 0,!0,0):(0,r.createCommentVNode)("",!0)])}))]),1032,["mode","is-form","show-cancel","onCancelConfirmed"])]),_:3},8,["header-mode","steps","edit-first-step","errors","finish-mode","before-go-to-step"])):(0,r.createCommentVNode)("",!0)])):(0,r.createCommentVNode)("",!0)],64)):M.showAsForm?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:3},[n.showToc?((0,r.openBlock)(),(0,r.createBlock)(G,{key:0,class:"cru__toc",style:(0,r.normalizeStyle)(M.tocContainerHeight?{"--toc-container-height":`${M.tocContainerHeight}px`}:{}),accordions:I.accordions},null,8,["style","accordions"])):(0,r.createCommentVNode)("",!0),D._selectedSubtype||!n.subtypes.length?((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:1,class:"cru__content resource-container",style:(0,r.normalizeStyle)([n.minHeight?{"min-height":n.minHeight}:{}])},[(0,r.renderSlot)(e.$slots,"single",{},()=>[(0,r.renderSlot)(e.$slots,"default",{},void 0,!0)],!0)],4)):(0,r.createCommentVNode)("",!0),(0,r.renderSlot)(e.$slots,"form-footer",{},()=>[D.isView?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createBlock)(j,{key:0,class:"cru__footer",mode:n.mode,"is-form":M.showAsForm,"show-cancel":n.showCancel,"component-testid":n.componentTestid,onCancelConfirmed:D.confirmCancel},(0,r.createSlots)({_:2},[(0,r.renderList)(e.$slots,(t,n)=>({name:n,fn:(0,r.withCtx)(t=>[D.shouldProvideSlot(n)?(0,r.renderSlot)(e.$slots,n,(0,r.normalizeProps)((0,r.guardReactiveProps)(t)),void 0,!0,0):(0,r.createCommentVNode)("",!0)])})),D.isView?void 0:{name:"default",fn:(0,r.withCtx)(()=>[(0,r.createElementVNode)("div",null,[D.showYaml?((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:0,"data-testid":n.componentTestid+"-yaml",type:"button",class:"btn role-secondary",onClick:t[3]||(t[3]=(...e)=>D.showPreviewYaml&&D.showPreviewYaml(...e))},[(0,r.createVNode)(V,{k:"cruResource.previewYaml"})],8,k)):(0,r.createCommentVNode)("",!0),D.showSubtypeSelection?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createBlock)(F,{key:1,ref:"save",disabled:!D.canSave,mode:n.finishButtonMode||n.mode,"data-testid":n.componentTestid+"-save",onClick:t[4]||(t[4]=e=>D.clickSave(e))},null,8,["disabled","mode","data-testid"]))])]),key:"0"}]),1032,["mode","is-form","show-cancel","component-testid","onCancelConfirmed"]))],!0)],64)):D.showYaml&&!M.showAsForm?((0,r.openBlock)(),(0,r.createElementBlock)("section",C,[(0,r.createVNode)(H,{ref:"resourceyaml",value:n.resource,mode:n.mode,"initial-yaml-for-diff":M.initialYaml,yaml:M.resourceYaml,"offer-preview":D.isEdit,"done-route":n.doneRoute,"done-override":n.resource.doneOverride,"show-errors":!1,"apply-hooks":n.applyHooks,class:"resource-container cru__content",onError:t[5]||(t[5]=t=>e.$emit("error",t))},{yamlFooter:(0,r.withCtx)(({yamlSave:t,showPreview:i,yamlPreview:o,yamlUnpreview:a,canDiff:s})=>[(0,r.renderSlot)(e.$slots,"cru-yaml-footer",{},()=>[(0,r.createVNode)(j,{class:"cru__footer","done-route":n.doneRoute,mode:n.mode,"is-form":M.showAsForm,onCancelConfirmed:D.confirmCancel},{default:(0,r.withCtx)(({checkCancel:l})=>[(0,r.createElementVNode)("div",A,[i?((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:0,type:"button",class:"btn role-secondary","data-testid":n.componentTestid+"-yaml-yaml",onClick:a},[(0,r.createVNode)(V,{k:"resourceYaml.buttons.continue"})],8,T)):(0,r.createCommentVNode)("",!0),!i&&D.isEdit?((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:1,"data-testid":n.componentTestid+"-yaml-yaml-preview",disabled:!s,type:"button",class:"btn role-secondary",onClick:o},[(0,r.createVNode)(V,{k:"resourceYaml.buttons.diff"})],8,R)):(0,r.createCommentVNode)("",!0)]),D._selectedSubtype||!n.subtypes.length?((0,r.openBlock)(),(0,r.createElementBlock)("div",N,[(0,r.createElementVNode)("button",{"data-testid":n.componentTestid+"-yaml-cancel",type:"button",class:"btn role-secondary",onClick:e=>l(!1)},[(0,r.createVNode)(V,{k:"cruResource.backToForm"})],8,P),D.showSubtypeSelection?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createBlock)(F,{key:0,"data-testid":n.componentTestid+"-yaml-save",disabled:!D.canSave,"action-label":D.isEdit?e.t("generic.save"):e.t("generic.create"),onClick:e=>t(e)},null,8,["data-testid","disabled","action-label","onClick"]))])):(0,r.createCommentVNode)("",!0)]),_:2},1032,["done-route","mode","is-form","onCancelConfirmed"])],!0)]),_:3},8,["value","mode","initial-yaml-for-diff","yaml","offer-preview","done-route","done-override","apply-hooks"])])):(0,r.createCommentVNode)("",!0)]),_:3},40,["value"]))],2)}var M=n(3514),D=n.n(M),L=n(97331),B=n.n(L),$=n(37648),V=n(76978),F=n(35664),j=n(67100),U=n(9980),G=n(30699),H=n(65359),q=n(99726);const Q={class:"cru-resource-footer"};function z(e,t,n,i,o,a){const s=(0,r.resolveComponent)("t"),l=(0,r.resolveComponent)("RcButton"),c=(0,r.resolveComponent)("AsyncButton"),u=(0,r.resolveComponent)("ResourceCancelModal");return(0,r.openBlock)(),(0,r.createElementBlock)("div",Q,[(0,r.renderSlot)(e.$slots,"footer-prefix"),(0,r.renderSlot)(e.$slots,"cancel",{},()=>[!a.isView&&n.showCancel?((0,r.openBlock)(),(0,r.createBlock)(l,{key:0,id:"cru-cancel","data-testid":n.componentTestid+"-cancel",type:"button",variant:"secondary",size:"large",onClick:t[0]||(t[0]=t=>n.confirmCancelRequired?a.checkCancel(!0):e.$emit("cancel-confirmed",!0))},{default:(0,r.withCtx)(()=>[(0,r.createVNode)(s,{k:"generic.cancel"})]),_:1},8,["data-testid"])):(0,r.createCommentVNode)("",!0)]),(0,r.renderSlot)(e.$slots,"default",{checkCancel:a.checkCancel},()=>[a.isView?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createBlock)(c,{key:0,"data-testid":n.componentTestid+"-create",mode:n.finishButtonMode||n.mode,onClick:t[1]||(t[1]=t=>e.$emit("finish",t))},null,8,["data-testid","mode"]))]),(0,r.createVNode)(u,{ref:"cancelModal","is-cancel-modal":o.isCancelModal,"is-form":n.isForm,onConfirmCancel:t[2]||(t[2]=e=>a.confirmCancel(e))},null,8,["is-cancel-modal","is-form"])])}const K={class:"header"},W={class:"text-default-text","data-modal-title":""},X={key:1},Y={class:"body"},Z={key:0},J={key:1},ee={class:"footer"},te={key:0},ne={key:1};function re(e,t,n,i,o,a){const s=(0,r.resolveComponent)("t"),l=(0,r.resolveComponent)("app-modal");return o.showModal?((0,r.openBlock)(),(0,r.createBlock)(l,{key:0,customClass:"confirm-modal",name:"cancel-modal",width:440,height:"auto","trigger-focus-trap":!0,onClose:a.cancelCancel},{default:(0,r.withCtx)(()=>[(0,r.createElementVNode)("div",K,[(0,r.createElementVNode)("h4",W,[n.isCancelModal?((0,r.openBlock)(),(0,r.createBlock)(s,{key:0,k:"generic.cancel"})):((0,r.openBlock)(),(0,r.createElementBlock)("span",X,(0,r.toDisplayString)(e.t("cruResource.backToForm")),1))])]),(0,r.createElementVNode)("div",Y,[n.isCancelModal?((0,r.openBlock)(),(0,r.createElementBlock)("p",Z,[(0,r.createVNode)(s,{k:"cruResource.cancelBody"})])):((0,r.openBlock)(),(0,r.createElementBlock)("p",J,[(0,r.createVNode)(s,{k:"cruResource.backBody"})]))]),(0,r.createElementVNode)("div",ee,[(0,r.createElementVNode)("button",{type:"button",class:"btn role-secondary",onClick:t[0]||(t[0]=(...e)=>a.cancelCancel&&a.cancelCancel(...e))},(0,r.toDisplayString)(n.isForm?e.t("cruResource.reviewForm"):e.t("cruResource.reviewYaml")),1),(0,r.createElementVNode)("button",{type:"button",class:"btn role-primary",onClick:t[1]||(t[1]=(...e)=>a.confirmCancel&&a.confirmCancel(...e))},[n.isCancelModal?((0,r.openBlock)(),(0,r.createElementBlock)("span",te,(0,r.toDisplayString)(e.t("cruResource.confirmCancel")),1)):((0,r.openBlock)(),(0,r.createElementBlock)("span",ne,(0,r.toDisplayString)(e.t("cruResource.confirmBack")),1))])])]),_:1},8,["onClose"])):(0,r.createCommentVNode)("",!0)}var ie=n(79535),oe={emits:["cancel-cancel","confirm-cancel"],components:{AppModal:ie.h},props:{isCancelModal:{type:Boolean,default:!1},isForm:{type:Boolean,default:!1}},data(){return{showModal:!1}},watch:{},methods:{show(){this.showModal=!0},cancelCancel(){this.showModal=!1,this.$emit("cancel-cancel")},confirmCancel(){this.showModal=!1,this.$emit("confirm-cancel",this.isCancelModal)}}},ae=(n(83375),n(47433));const se=(0,ae.A)(oe,[["render",re],["__scopeId","data-v-fa4a262e"]]);var le=se,ce=n(51433),ue=n(14220),de={emits:["cancel-confirmed","finish"],components:{AsyncButton:G.A,RcButton:ce.a,ResourceCancelModal:le},props:{mode:{type:String,default:"create"},isForm:{type:Boolean,default:!0},finishButtonMode:{type:String,default:null},confirmCancelRequired:{type:Boolean,default:!1},confirmBackRequired:{type:Boolean,default:!0},showCancel:{type:Boolean,default:!0},componentTestid:{type:String,default:"form-footer"}},data(){return{isCancelModal:!1}},computed:{...(0,H.L8)({t:"i18n/t"}),isView(){return this.mode===ue.nW}},methods:{checkCancel(e){this.isCancelModal=!!e,this.$refs.cancelModal.show()},confirmCancel(e){this.$emit("cancel-confirmed",e)}}};n(55372);const he=(0,ae.A)(de,[["render",z]]);var pe=he,fe=n(3889),me=n(95811);const ge={class:"toc-root"},ve={class:"toc-container"},be=["data-testid"],ye=["onClick"],we={key:1},Oe={key:2,"data-testid":"toc-list"},Se=["data-testid"],Ee=["onClick"],xe={key:1};var _e={__name:"TableOfContents",props:{accordions:{type:Array,required:!0}},setup(e){const t=e,n=(e,t)=>{e?.scrollTo?.(),t?.currentTarget?.blur?.()};return(e,i)=>((0,r.openBlock)(),(0,r.createElementBlock)("div",ge,[(0,r.createElementVNode)("div",ve,[(0,r.createElementVNode)("h4",null,(0,r.toDisplayString)(e.t("cruResource.tableOfContents.jumpTo")),1),(0,r.createElementVNode)("ul",null,[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(t.accordions,(e,t)=>((0,r.openBlock)(),(0,r.createElementBlock)("li",{key:t,"data-testid":`toc-list-item-${t}`},[e.scrollTo?((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:0,type:"button",class:"btn role-link accordion-link toc-parent-link",onClick:t=>n(e,t)},(0,r.toDisplayString)(e.label),9,ye)):((0,r.openBlock)(),(0,r.createElementBlock)("span",we,(0,r.toDisplayString)(e.label),1)),e?.children?.length?((0,r.openBlock)(),(0,r.createElementBlock)("ul",Oe,[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(e.children,(e,i)=>((0,r.openBlock)(),(0,r.createElementBlock)("li",{key:i,"data-testid":`toc-list-item-${t}-${i}`},[e.scrollTo?((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:0,type:"button",class:"btn role-link accordion-link toc-child-link",onClick:t=>n(e,t)},(0,r.toDisplayString)(e.label),9,Ee)):((0,r.openBlock)(),(0,r.createElementBlock)("span",xe,(0,r.toDisplayString)(e.label),1))],8,Se))),128))])):(0,r.createCommentVNode)("",!0)],8,be))),128))])])]))}};n(41117);const ke=(0,ae.A)(_e,[["__scopeId","data-v-aa0292aa"]]);var Ce=ke,Ae=n(8135);const Te={ref:"wizard",class:"outer-container"},Re={class:"header"},Ne={key:0,class:"top choice-banner"},Pe={class:"title"},Ie={key:0,class:"round-image"},Me={class:"subtitle"},De={key:0},Le={key:1,class:"subtext"},Be={key:1,class:"subtitle"},$e={key:0,class:"subtext"},Ve=["aria-label"],Fe={key:0,class:"steps"},je=["id"],Ue=["id"],Ge={id:"wizard-footer-controls",class:"controls-row"},He={class:"controls-steps"};function qe(e,t,n,i,o,a){const s=(0,r.resolveComponent)("Loading"),l=(0,r.resolveComponent)("LazyImage"),c=(0,r.resolveComponent)("RcButton"),u=(0,r.resolveComponent)("Banner"),d=(0,r.resolveComponent)("t"),h=(0,r.resolveComponent)("AsyncButton");return(0,r.openBlock)(),(0,r.createElementBlock)("div",Te,[a.stepsLoaded?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createBlock)(s,{key:0,mode:"relative"})),(0,r.createElementVNode)("div",{class:(0,r.normalizeClass)(["outer-container",{hide:!a.stepsLoaded}])},[(0,r.createElementVNode)("div",null,[(0,r.createElementVNode)("div",Re,[(0,r.createElementVNode)("div",{class:(0,r.normalizeClass)(["title",n.showStepHeader?"":"mmb-4"])},[n.showBanner?((0,r.openBlock)(),(0,r.createElementBlock)("div",Ne,[n.bannerImage||n.bannerTitle?(0,r.renderSlot)(e.$slots,"bannerTitle",{},()=>[(0,r.withDirectives)((0,r.createElementVNode)("div",Pe,[(0,r.renderSlot)(e.$slots,"bannerTitleImage",{},()=>[n.bannerImage?((0,r.openBlock)(),(0,r.createElementBlock)("div",Ie,[(0,r.createVNode)(l,{src:n.bannerImage,class:"logo"},null,8,["src"])])):(0,r.createCommentVNode)("",!0)],!0),(0,r.createElementVNode)("div",Me,[n.bannerTitle?((0,r.openBlock)(),(0,r.createElementBlock)("h2",De,(0,r.toDisplayString)(n.bannerTitle),1)):(0,r.createCommentVNode)("",!0),n.bannerTitleSubtext?((0,r.openBlock)(),(0,r.createElementBlock)("span",Le,(0,r.toDisplayString)(n.bannerTitleSubtext),1)):(0,r.createCommentVNode)("",!0)])],512),[[r.vShow,n.initialTitle||a.activeStepIndex>0]])],!0,0):(0,r.createCommentVNode)("",!0),o.activeStep&&a.showSteps&&n.showStepHeader?((0,r.openBlock)(),(0,r.createElementBlock)("div",Be,[(0,r.createElementVNode)("h2",null,(0,r.toDisplayString)(n.headerMode?e.t(`wizard.${n.headerMode}`):e.t(`asyncButton.${n.finishMode}.action`))+": "+(0,r.toDisplayString)(e.t("wizard.step",{number:a.activeStepIndex+1})),1),(0,r.renderSlot)(e.$slots,"bannerSubtext",{},()=>[null!==o.activeStep.subtext?((0,r.openBlock)(),(0,r.createElementBlock)("span",$e,(0,r.toDisplayString)(o.activeStep.subtext||o.activeStep.label),1)):(0,r.createCommentVNode)("",!0)],!0)])):(0,r.createCommentVNode)("",!0)])):(0,r.createCommentVNode)("",!0),(0,r.createElementVNode)("nav",{class:"step-sequence","aria-label":e.t("wizard.stepList")},[a.showSteps?((0,r.openBlock)(),(0,r.createElementBlock)("ol",Fe,[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(a.visibleSteps,(e,t)=>((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:t},[(0,r.createElementVNode)("li",{id:e.name,class:(0,r.normalizeClass)({step:!0,active:e.name===o.activeStep.name,disabled:!a.isAvailable(e)})},[(0,r.createVNode)(c,{variant:"ghost",class:"controls","aria-current":e.name===o.activeStep.name?"step":null,disabled:!a.isAvailable(e),onClick:e=>a.goToStep(t+1,!0)},{default:(0,r.withCtx)(()=>[(0,r.createElementVNode)("span",{class:(0,r.normalizeClass)(["icon icon-lg",{"icon-dot":e.name===o.activeStep.name,"icon-dot-open":e.name!==o.activeStep.name}])},null,2),(0,r.createElementVNode)("span",null,(0,r.toDisplayString)(e.label),1)]),_:2},1032,["aria-current","disabled","onClick"])],10,je),t!==a.visibleSteps.length-1?((0,r.openBlock)(),(0,r.createElementBlock)("li",{key:e.name,class:"divider","aria-hidden":"true"})):(0,r.createCommentVNode)("",!0)],64))),128))])):(0,r.createCommentVNode)("",!0)],8,Ve)],2)]),(0,r.renderSlot)(e.$slots,"stepContainer",{class:"step-container",activeStep:o.activeStep},()=>[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(n.steps,(t,n)=>((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:n},[t.name===o.activeStep.name||t.hidden?((0,r.openBlock)(),(0,r.createElementBlock)("div",{id:"step-container-"+t.name,key:t.name,class:(0,r.normalizeClass)(["step-container__step",{hide:t.name!==o.activeStep.name&&t.hidden}])},[(0,r.renderSlot)(e.$slots,t.name,{step:t},void 0,!0)],10,Ue)):(0,r.createCommentVNode)("",!0)],64))),128))],!0)]),(0,r.renderSlot)(e.$slots,"controlsContainer",{showPrevious:a.showPrevious,next:a.next,back:a.back,canNext:a.canNext,activeStepIndex:a.activeStepIndex,visibleSteps:a.visibleSteps,errorStrings:a.errorStrings,finish:a.finish,cancel:a.cancel,activeStep:o.activeStep},()=>[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(a.errorStrings,(e,t)=>((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:t},[(0,r.createVNode)(u,{color:"error",role:"alert",label:e,closable:!0,class:"footer-error",onClose:e=>n.errors.splice(t,1)},null,8,["label","onClose"])]))),128)),(0,r.createElementVNode)("div",Ge,[(0,r.renderSlot)(e.$slots,"cancel",{cancel:a.cancel},()=>[(0,r.createVNode)(c,{type:"button",variant:"secondary",size:"large",onClick:a.cancel},{default:(0,r.withCtx)(()=>[(0,r.createVNode)(d,{k:"generic.cancel"})]),_:1},8,["onClick"])],!0),(0,r.createElementVNode)("div",He,[a.showPrevious?(0,r.renderSlot)(e.$slots,"back",{back:a.back},()=>[(0,r.createVNode)(c,{disabled:!a.canPrevious||!n.editFirstStep&&1===a.activeStepIndex,type:"button",variant:"secondary",size:"large",onClick:t[0]||(t[0]=e=>a.back())},{default:(0,r.withCtx)(()=>[(0,r.createVNode)(d,{k:"wizard.previous"})]),_:1},8,["disabled"])],!0,0):(0,r.createCommentVNode)("",!0),a.activeStepIndex===a.visibleSteps.length-1?(0,r.renderSlot)(e.$slots,"finish",{finish:a.finish},()=>[a.isView?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createBlock)(h,{key:0,disabled:!o.activeStep.ready,mode:n.finishMode,onClick:a.finish},null,8,["disabled","mode","onClick"]))],!0,1):(0,r.renderSlot)(e.$slots,"next",{next:a.next},()=>[(0,r.createVNode)(c,{disabled:!a.canNext,type:"button",variant:"primary",size:"large",onClick:t[1]||(t[1]=e=>a.next())},{default:(0,r.withCtx)(()=>[(0,r.createVNode)(d,{k:a.nextButtonLabel},null,8,["k"])]),_:1},8,["disabled"])],!0,2)])])],!0)],2)],512)}var Qe=n(58972),ze=n(40960),Ke={name:"Wizard",emits:["next","cancel","finish"],components:{AsyncButton:G.A,Banner:U.l,RcButton:ce.a,Loading:Qe.A,LazyImage:ze.A},props:{steps:{type:Array,required:!0},mode:{type:String,default:ue.YQ},initStepIndex:{type:Number,default:0},editFirstStep:{type:Boolean,default:!1},showBanner:{type:Boolean,default:!0},initialTitle:{type:Boolean,default:!0},bannerTitle:{type:String,default:null},bannerImage:{type:String,default:null},bannerTitleSubtext:{type:String,default:null},headerMode:{type:String,default:null},showStepHeader:{type:Boolean,default:!0},finishMode:{type:String,default:"finish"},errors:{type:Array,default:null},beforeGoToStep:{type:Function,default:null}},data(){return{activeStep:null}},computed:{isView(){return this.mode===ue.nW},errorStrings(){return(this.errors||[]).map(e=>(0,q.As)(e))},activeStepIndex(){return this.visibleSteps.findIndex(e=>e.name===this.activeStep.name)},showPrevious(){if(0===this.activeStepIndex)return!1;for(let e=0;e<this.activeStepIndex;e++){const t=this.visibleSteps[e];if(!t)break;if(!t.hidden)return!0}return!1},canPrevious(){return!this.activeStep?.previousButton?.disable&&(this.activeStepIndex>1||this.editFirstStep)},canNext(){const e=this.visibleSteps[this.activeStepIndex];return this.activeStepIndex<this.visibleSteps.length-1&&e.ready},readySteps(){return this.visibleSteps.filter(e=>e.ready)},showSteps(){return!1!==this.activeStep.showSteps&&this.visibleSteps.length>1},stepsLoaded(){return!this.steps.some(e=>!0===e.loading)},visibleSteps(){return this.steps.filter(e=>!e.hidden)},nextButtonLabel(){return this.activeStep.nextButton?.labelKey||"wizard.next"}},watch:{stepsLoaded(e,t){!t&&e&&(this.activeStep=this.visibleSteps[this.initStepIndex],this.goToStep(this.activeStepIndex+1))},errors(){this.$nextTick(()=>{this.$refs.wizard.scrollTop=this.$refs.wizard.scrollHeight})}},created(){this.activeStep=this.visibleSteps[this.initStepIndex],this.goToStep(this.activeStepIndex+1)},methods:{async goToStep(e,t){if(e<1)return;if(!this.editFirstStep&&1===e&&t)return;const n=this.visibleSteps[e-1];if(n&&(this.isAvailable(n)||1===e)){if(this.beforeGoToStep&&t)try{await this.beforeGoToStep(this.activeStep,n)}catch{return}this.activeStep=n,this.$emit("next",{step:n})}},cancel(){this.$emit("cancel")},finish(e){this.$emit("finish",e)},next(){this.goToStep(this.activeStepIndex+2)},back(){this.goToStep(this.activeStepIndex)},isAvailable(e){if(!e)return!1;const t=this.visibleSteps.findIndex(t=>t.name===e.name);if(0===t&&!this.editFirstStep)return!1;for(let n=0;n<t;n++)if(!1===this.visibleSteps[n].ready)return!1;return!0}}};n(65084);const We=(0,ae.A)(Ke,[["render",qe],["__scopeId","data-v-dd1aa210"]]);var Xe=We,Ye=n(14384),Ze=n(25509),Je=n(4364);const et="show-preview-yaml";var tt={name:"CruResource",emits:["select-type","error","cancel","finish"],components:{AsyncButton:G.A,Banner:U.l,CruResourceFooter:pe,ResourceYaml:j.A,Wizard:Xe,TableOfContents:Ce,RcSeparator:Ye.v,RcHeading:Ze.m},props:{doneRoute:{type:[String,Object],default:null},cancelEvent:{type:Boolean,default:!1},showCancel:{type:Boolean,default:!0},mode:{type:String,required:!0},resource:{type:[String,Object],required:!0},subtypes:{type:Array,default:()=>[]},selectedSubtype:{type:String,default:null},validationPassed:{type:Boolean,default:!0},errors:{type:Array,default:()=>[]},errorsMap:{type:Object,default:null},canYaml:{type:Boolean,default:!0},generateYaml:{type:Function,default:null},finishButtonMode:{type:String,default:null},preventEnterSubmit:{type:Boolean,default:!1},applyHooks:{type:Function,default:null},steps:{type:Array,default:()=>[]},beforeNext:{type:Function,default:null},stepsOptions:{type:Object,default:()=>({editFirstStep:!0})},finishMode:{type:String,default:"finish"},minHeight:{type:String,default:""},namespaceKey:{type:String,default:"metadata.namespace"},componentTestid:{type:String,default:"form"},description:{type:String,default:""},yamlModifiers:{type:Object,default:void 0},showToc:{type:Boolean,default:!1}},setup(){const e=(0,r.useTemplateRef)("cru-form"),{locatedComponents:t}=(0,me._)(e),n=t;return{accordions:n}},data(e){const t=this.$store.getters["currentStore"](this.resource),n=this.$store.getters[`${t}/schemaFor`](this.resource.type);return this.mode===ue.YQ?(0,fe.wQ)():this.mode===ue.G5&&(0,fe.eD)(),{isCancelModal:!1,showAsForm:this.$route.query[ue.AS]!==ue.zD,tocContainerHeight:0,mainLayoutEl:null,throttledComputeTocContainerHeight:null,nextValidating:!1,resourceYaml:null,initialYaml:null,initialResource:(0,V.o8)(this.resource),abbrSizes:{3:"24px",4:"18px",5:"16px",6:"14px"},schema:n}},computed:{canSave(){const{validationPassed:e,showAsForm:t,steps:n}=this;return t&&n?.length?e&&this.steps.every(e=>e.ready):!this.showAsForm||this.validationPassed},canEditYaml(){return!this.schema?.resourceMethods?.includes("blocked-PUT")},showYaml(){return this.canYaml&&(this._selectedSubtype||!this.subtypes.length)&&this.canEditYaml&&this.mode!==ue.nW},isView(){return this.mode===ue.nW},isEdit(){return this.mode===ue.G5},_selectedSubtype(){return this.selectedSubtype?this.selectedSubtype:this.$route.query[ue.UA]},showSubtypeSelection(){return!D()(this.subtypes)&&!this._selectedSubtype},...(0,H.L8)({t:"i18n/t"}),...(0,H.aH)("cru-resource",["createNamespace"]),...(0,H.i0)("cru-resource",["setCreateNamespace"]),hasErrors(){return this.errors?.length&&Array.isArray(this.errors)},mappedErrors(){return this.errors?this.errorsMap||this.errors.reduce((e,t)=>({...e,[t]:{message:this.formatError(t),icon:null}}),{}):{}}},created(){this.throttledComputeTocContainerHeight=B()(this.computeTocContainerHeight,20),this._selectedSubtype&&this.$emit("select-type",this._selectedSubtype)},mounted(){this.$store.dispatch("cru-resource/setCreateNamespace",!1)},beforeUnmount(){this.mainLayoutEl?.removeEventListener("scroll",this.throttledComputeTocContainerHeight),window.removeEventListener("resize",this.throttledComputeTocContainerHeight),this.throttledComputeTocContainerHeight?.cancel?.(),this.$store.dispatch("cru-resource/setCreateNamespace",!1)},methods:{stringify:q.As,computeTocContainerHeight(){const e=this.$el;if(!e)return this.tocContainerHeight=0,0;const t=e.querySelector(".cru__toc"),n=e.querySelector(".cru__footer");if(!t||!n)return this.tocContainerHeight=0,0;const r=t.getBoundingClientRect().top,i=n.getBoundingClientRect().top,o=getComputedStyle(e).getPropertyValue("--gap-lg").trim(),a=Number.parseFloat(o)||0;this.tocContainerHeight=Math.max(0,Math.round(i-r-a))},confirmCancel(e=!0){e?this.emitOrRoute():this.showAsForm||(this.resourceYaml=null,this.showAsForm=!0,this.$router.applyQuery({[ue.AS]:ue.xz}))},closeError(e){const t=this.errors.filter((t,n)=>n!==e);this.$emit("error",t,this.errors[e])},emitOrRoute(){if(this.cancelEvent)this.$emit("cancel");else{const{resource:e=this.resource.type}=this.$route.params,t=this.resource.doneOverride,n={name:this.doneRoute,params:{resource:e}};this.$router.replace(t||n)}},async createResourceYaml(e,t=this.resource){if(await(this.schema?.fetchResourceFields()),"function"===typeof this.generateYaml)return this.generateYaml.apply(this,t);{const n=this.$store.getters["currentStore"](t),r=this.$store.getters[`${n}/all`](F.yx),i=(0,V.o8)(t),o=(0,$.Yd)(r,t.type,i,e);return o}},async showPreviewYaml(){if(await(this.schema?.fetchResourceFields()),this.applyHooks)try{await this.applyHooks(Ae.Fm,et)}catch(t){return void Je.warn("Unable to show yaml: ",t)}const e=await this.createResourceYaml(this.yamlModifiers);this.resourceYaml=e,this.showAsForm=!1,this.$router.applyQuery({[ue.AS]:ue.zD})},selectType(e,t){"A"!==t?.srcElement?.tagName&&(this.$router.applyQuery({[ue.UA]:e}),this.$emit("select-type",e))},async clickSave(e){if(this.createNamespace)try{await this.createNamespaceIfNeeded()}catch(t){return this.$emit("error",(0,q.rz)(t.message)),void e(!1)}this.$emit("finish",e)},save(){this.$refs.save.clicked()},async createNamespaceIfNeeded(){const e=this.$store.getters["currentStore"](this.resource),t=(0,V.Jt)(this.resource,this.namespaceKey);let n=!1;try{n=!!await this.$store.dispatch(`${e}/find`,{type:F.CU,id:t})}catch{}if(!n)try{const n=await this.$store.dispatch(`${e}/createNamespace`,{name:t},{root:!0});n.applyDefaults(),await n.save()}catch(r){throw this.$emit("error",(0,q.rz)(r)),new Error(`Could not create the new namespace. ${r.message}`)}},onPressEnter(e){this.preventEnterSubmit&&e.preventDefault()},shouldProvideSlot(e){return"default"!==e&&"function"===typeof this.$slots[e]},async wizardBeforeGoToStep(e,t){if(!this.beforeNext)return;const n=this.steps.findIndex(t=>t.name===e.name),r=this.steps.findIndex(e=>e.name===t.name);if(!(r<=n))try{await this.beforeNext(e),this.$emit("error",[])}catch(i){throw this.$emit("error",(0,q.rz)(i)),i}},async handleNext(e,t){if(this.beforeNext){this.nextValidating=!0;try{await this.beforeNext(t),this.$emit("error",[]),e()}catch(n){this.$emit("error",(0,q.rz)(n))}finally{this.nextValidating=!1}}else e()},formatError(e){if("string"===typeof e)return e;if("ActionNotAvailable"===e?.code)return this.t("errors.actionNotAvailable");const t=e?.message?e.message:"";let n="";if(e?.message&&e.detail)n=this.t("errors.messageAndDetail",{message:e.message,detail:e.detail});else if(e?.message||e.detail){const t=e.message?e.message:e.detail;n=this.t("errors.messageOrDetail",{val:t})}if(422===e?.status){const t=e?.fieldName,r=e?.code;let i="";switch(e?.code){case"MissingRequired":i=this.t("errors.missingRequired");break;case"NotUnique":i=this.t("errors.notUnique");break;case"NotNullable":i=this.t("errors.notNullable");break;case"InvalidOption":i=this.t("errors.invalidOption");break;case"InvalidCharacters":i=this.t("errors.invalidCharacters");break;case"MinLengthExceeded":i=this.t("errors.minLengthExceeded");break;case"MaxLengthExceeded":i=this.t("errors.maxLengthExceeded");break;case"MinLimitExceeded":i=this.t("errors.minLimitExceeded");break;case"MaxLimitExceded":i=this.t("errors.maxLimitExceded");break}return t?i?n?this.t("errors.failedInApi.withName.withCodeExplanation.withMessageDetail",{name:t,codeExplanation:i,messageDetail:n}):this.t("errors.failedInApi.withName.withCodeExplanation.withoutMessageDetail",{name:t,codeExplanation:i}):n?this.t("errors.failedInApi.withName.withMessageDetail",{name:t,messageDetail:n}):this.t("errors.failedInApi.withName.withoutAnythingElse",{name:t}):n?i?this.t("errors.failedInApi.withoutName.withMessageDetail.withCodeExplanation",{codeExplanation:i,messageDetail:n}):this.t("errors.failedInApi.withoutName.withMessageDetail.withoutCodeExplanation",{messageDetail:n}):r?i?this.t("errors.failedInApi.withoutName.withCode.withCodeExplanation",{code:r,codeExplanation:i}):this.t("errors.failedInApi.withoutName.withCode.withoutCodeExplanation",{code:r}):this.t("errors.failedInApi.withoutAnything")}return 404===e?.status?e?.opt?.url?this.t("errors.notFound.withUrl",{msg:t,url:e.opt.url}):this.t("errors.notFound.withoutUrl",{msg:t}):n.length>0?n:e}},watch:{async showAsForm(e){e||this.initialYaml||(this.initialYaml=await this.createResourceYaml(void 0,this.initialResource))},showToc:{handler(e,t){e?(this.$nextTick(()=>{this.throttledComputeTocContainerHeight?.()}),this.mainLayoutEl=document.querySelector(".main-layout"),this.mainLayoutEl?.addEventListener("scroll",this.throttledComputeTocContainerHeight,{passive:!0}),window.addEventListener("resize",this.throttledComputeTocContainerHeight,{passive:!0})):t&&(this.mainLayoutEl?.removeEventListener("scroll",this.throttledComputeTocContainerHeight),window.removeEventListener("resize",this.throttledComputeTocContainerHeight))},immediate:!0}}};n(24039);const nt=(0,ae.A)(tt,[["render",I],["__scopeId","data-v-91e14576"]]);var rt=nt},14738:function(e,t,n){"use strict";n.d(t,{A:function(){return _}});var r=n(9274);const i=["id"],o=["id"],a=["value","placeholder","aria-labelledby","aria-label","aria-invalid","aria-describedby"],s={key:3,class:"text-italic"},l={key:4,class:"text-italic"},c={key:0,"data-testid":"detail-top_html",class:"conceal","aria-live":"polite"},u={class:"action-group"},d=["aria-label"],h=["alt"];function p(e,t,n,p,f,m){const g=(0,r.resolveComponent)("CodeMirror"),v=(0,r.resolveComponent)("CopyToClipboard"),b=(0,r.resolveComponent)("AsyncButton"),y=(0,r.resolveDirective)("t"),w=(0,r.resolveDirective)("clean-tooltip"),O=(0,r.resolveDirective)("clean-html");return(0,r.openBlock)(),(0,r.createElementBlock)("div",{class:(0,r.normalizeClass)({"force-wrap":!0,"with-copy":n.copy||n.paste})},[n.labelKey?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("h5",{key:0,id:f.labelId},null,8,i)),[[y,n.labelKey],[w,{content:m.itemLabel,popperClass:"detail-text-tooltip"}]]):n.label?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("h5",{key:1,id:f.labelId},[(0,r.createTextVNode)((0,r.toDisplayString)(n.label),1)],8,o)),[[w,{content:n.label,popperClass:"detail-text-tooltip"}]]):(0,r.createCommentVNode)("",!0),n.editable?((0,r.openBlock)(),(0,r.createElementBlock)("textarea",{key:2,class:"editable monospace",value:n.value,placeholder:n.placeholder,"aria-labelledby":n.labelKey||n.label?f.labelId:void 0,"aria-label":n.labelKey||n.label?void 0:m.itemLabel,"aria-invalid":n.invalid,"aria-describedby":n.describedBy||void 0,spellcheck:"false","data-testid":"detail-top_input",onInput:t[0]||(t[0]=t=>e.$emit("update:value",t.target.value))},null,40,a)):m.isEmpty?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("span",s,null,512)),[[y,"detailText.empty"]]):m.isBinary?((0,r.openBlock)(),(0,r.createElementBlock)("span",l,(0,r.toDisplayString)(m.body),1)):m.jsonStr&&!m.concealed?((0,r.openBlock)(),(0,r.createBlock)(g,{key:5,options:{mode:{name:"javascript",json:!0},lineNumbers:!1,foldGutter:!1,readOnly:!0},value:m.jsonStr,"aria-live":"polite"},null,8,["value"])):((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:6,class:(0,r.normalizeClass)({"conceal-wrapper":m.concealed})},[m.concealed?((0,r.openBlock)(),(0,r.createElementBlock)("span",c)):(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("span",{key:1,"data-testid":"detail-top_html",class:(0,r.normalizeClass)({monospace:n.monospace&&!m.isBinary}),"aria-live":"polite"},null,2)),[[O,m.bodyHtml]])],2)),n.editable||m.isBinary||m.jsonStr||!m.isLong||f.expanded?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createElementBlock)("a",{key:7,href:"#",class:"more-characters",onClick:t[1]||(t[1]=(0,r.withModifiers)((...e)=>m.expand&&m.expand(...e),["prevent"]))},(0,r.toDisplayString)(m.plusMore),1)),(0,r.createElementVNode)("div",u,[n.conceal&&n.concealStandAlone?((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:0,class:"sensitive btn ready-for-action role-tertiary","aria-label":m.sensitiveAria,onClick:t[2]||(t[2]=e=>f.standAloneHide=!f.standAloneHide)},[(0,r.createElementVNode)("i",{class:(0,r.normalizeClass)(["icon icon-lg",m.sensitiveIcon]),alt:m.sensitiveAria},null,10,h)],8,d)):(0,r.createCommentVNode)("",!0),n.copy&&!m.isBinary?((0,r.openBlock)(),(0,r.createBlock)(v,{key:1,text:n.value,class:"role-tertiary","action-color":"","aria-label":e.t("detailText.copyAriaLabel",{item:m.itemLabel})},null,8,["text","aria-label"])):(0,r.createCommentVNode)("",!0),n.paste?((0,r.openBlock)(),(0,r.createBlock)(b,{key:2,icon:"icon-document",class:"role-tertiary","action-color":"","waiting-color":"role-primary","success-color":"role-primary","action-label":e.t("detailText.paste.action"),"waiting-label":e.t("detailText.paste.waiting"),"success-label":e.t("detailText.paste.success"),"error-label":e.t("detailText.paste.error"),"aria-label":e.t("detailText.paste.ariaLabel",{item:m.itemLabel}),delay:2e3,"data-testid":"detail-text-paste",onClick:m.pasteValue},null,8,["action-label","waiting-label","success-label","error-label","aria-label","onClick"])):(0,r.createCommentVNode)("",!0)])],2)}var f=n(65359),m=n(92043),g=n(41476),v=n(30699),b=n(97007),y=n(6963),w=n(4514),O=n(48881),S={components:{AsyncButton:v.A,CopyToClipboard:b.A,CodeMirror:y.A},emits:["update:value"],props:{label:{type:String,default:null},labelKey:{type:String,default:null},value:{type:String,default:""},maxLength:{type:Number,default:640},binary:{type:Boolean,default:null},conceal:{type:Boolean,default:!1},concealStandAlone:{type:Boolean,default:!1},monospace:{type:Boolean,default:!0},copy:{type:Boolean,default:!0},editable:{type:Boolean,default:!1},paste:{type:Boolean,default:!1},placeholder:{type:String,default:null},invalid:{type:Boolean,default:!1},describedBy:{type:String,default:null}},data(){const e=this.value.length<=this.maxLength;return{expanded:e,standAloneHide:!0,labelId:`detail-text-label-${(0,m.vx)(4)}`}},computed:{itemLabel(){return this.labelKey?this.t(this.labelKey):this.label?this.label:this.t("labels.annotations.singular")},isBinary(){return null===this.binary?"string"===typeof this.value&&!(0,m.XC)(this.value):this.binary},size(){return`${this.value}`.length},isLong(){return this.size>this.maxLength},isEmpty(){return 0===this.size},body(){return this.isBinary?this.t("detailText.binary",{n:this.value.length?(0,w.dQ)(this.value):0},!0):this.expanded?this.value:this.value.slice(0,this.maxLength)},jsonStr(){const e=this.value;if(e&&(e.startsWith("{")||e.startsWith("[")))try{let t=JSON.parse(e);return t=JSON.stringify(t,null,2),t}catch{}return null},bodyHtml(){return(0,m.Kn)(this.body)},plusMore(){if(this.expanded)return this.t("detailText.collapse");const e=Math.max(this.size-this.maxLength,0);return this.t("detailText.plusMore",{n:e}).trim()},hideSensitiveData(){return this.concealStandAlone?this.standAloneHide:this.$store.getters["prefs/get"](g.qv)},concealed(){return this.conceal&&this.hideSensitiveData&&!this.isBinary},sensitiveIcon(){return this.standAloneHide?"icon-show":"icon-hide"},sensitiveAria(){return this.standAloneHide?this.t("detailText.sensitive.show"):this.t("detailText.sensitive.hide")},...(0,f.L8)({t:"i18n/t"})},methods:{expand(){this.expanded=!this.expanded},async pasteValue(e){try{const t=await(0,O.N)();t&&this.$emit("update:value",t),e(!!t)}catch{e(!1)}}}},E=(n(70336),n(37474),n(47433));const x=(0,E.A)(S,[["render",p],["__scopeId","data-v-60495cfd"]]);var _=x},48751:function(e,t,n){"use strict";n.d(t,{A:function(){return F}});var r=n(9274),i=n(95457),o=n(65359),a=n(71126);const s={class:"chrome"},l={class:"header pp-4"},c={class:"title"},u={class:"actions"},d=["aria-label"],h={class:"body pp-4"},p={key:0,class:"footer pp-4"},f={class:"actions"};var m=(0,r.defineComponent)({__name:"Chrome",props:{ariaTarget:{},removeFooter:{type:Boolean},closeLabel:{}},emits:["close"],setup(e,{emit:t}){const n=e,m=t,g=(0,o.Pj)(),v=(0,i.s)(g),b=(0,r.computed)(()=>v.t("component.drawer.chrome.ariaLabel.close",{target:n.ariaTarget}));return(t,n)=>((0,r.openBlock)(),(0,r.createElementBlock)("div",s,[(0,r.createElementVNode)("div",l,[(0,r.renderSlot)(t.$slots,"header",{},()=>[(0,r.createElementVNode)("div",c,[(0,r.renderSlot)(t.$slots,"title")]),(0,r.createElementVNode)("div",u,[(0,r.createElementVNode)("button",{class:"btn role-link","aria-label":b.value,onClick:n[0]||(n[0]=e=>m("close"))},[...n[2]||(n[2]=[(0,r.createElementVNode)("i",{class:"icon icon-close"},null,-1)])],8,d)])])]),(0,r.createElementVNode)("div",h,[(0,r.renderSlot)(t.$slots,"body")]),e.removeFooter?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createElementBlock)("div",p,[(0,r.renderSlot)(t.$slots,"footer",{},()=>[(0,r.createElementVNode)("div",f,[(0,r.createVNode)(a.A,{variant:"secondary",size:"large","aria-label":e.closeLabel?void 0:b.value,onClick:n[1]||(n[1]=e=>m("close"))},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.closeLabel||(0,r.unref)(v).t("component.drawer.chrome.close")),1)]),_:1},8,["aria-label"]),(0,r.renderSlot)(t.$slots,"additional-actions")])])]))]))}}),g=(n(64204),n(47433));const v=(0,g.A)(m,[["__scopeId","data-v-470bd9ef"]]);var b=v,y=n(94681),w=n(14220),O=n(97955),S=n(67100),E=(0,r.defineComponent)({__name:"YamlTab",props:{resource:{},yaml:{}},setup(e){const t=e,n=(0,o.Pj)(),a=(0,i.s)(n),s=(0,r.useTemplateRef)("yaml");return(e,n)=>((0,r.openBlock)(),(0,r.createBlock)(O.A,{class:"yaml-tab",name:"yaml-tab",label:(0,r.unref)(a).t("component.drawer.resourceDetailDrawer.yamlTab.title"),onActive:n[0]||(n[0]=()=>{var e;return null===(e=s.value)||void 0===e?void 0:e.refresh()})},{default:(0,r.withCtx)(()=>[(0,r.createVNode)(S.A,{ref:"yaml",value:t.resource,yaml:t.yaml,mode:(0,r.unref)(w.nW)},null,8,["value","yaml","mode"])]),_:1},8,["label"]))}});n(31806);const x=(0,g.A)(E,[["__scopeId","data-v-3f619296"]]);var _=x,k=n(89366);const C={class:"drawer-card"};function A(e,t){return(0,r.openBlock)(),(0,r.createElementBlock)("div",C,[(0,r.renderSlot)(e.$slots,"default",{},void 0,!0)])}n(91532);const T={},R=(0,g.A)(T,[["render",A],["__scopeId","data-v-9f186538"]]);var N=R,P=(0,r.defineComponent)({__name:"ConfigTab",props:{resource:{},component:{},resourceType:{},defaultTab:{}},setup(e){const t=e,n=(0,o.Pj)(),a=(0,i.s)(n);return(e,n)=>((0,r.openBlock)(),(0,r.createBlock)(O.A,{class:"config-tab",name:"config-tab",label:(0,r.unref)(a).t("component.drawer.resourceDetailDrawer.configTab.title")},{default:(0,r.withCtx)(()=>[(0,r.createVNode)(N,null,{default:(0,r.withCtx)(()=>[((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(t.component),{value:t.resource,liveValue:t.resource,resourceType:t.resourceType,mode:(0,r.unref)(w.nW),"real-mode":(0,r.unref)(w.nW),"initial-value":t.resource,"use-tabbed-hash":!1,"default-tab":t.defaultTab,as:"config"},null,8,["value","liveValue","resourceType","mode","real-mode","initial-value","default-tab"]))]),_:1})]),_:1},8,["label"]))}});n(97387);const I=(0,g.A)(P,[["__scopeId","data-v-7d0d0cce"]]);var M=I,D=n(35601);const L="save-configuration-bttn",B="configuration-drawer-tabbed";var $=(0,r.defineComponent)({__name:"index",props:{resource:{},defaultTab:{},onClose:{type:Function}},emits:["close"],setup(e,{emit:t}){const n=e,s=t,l=(0,o.Pj)(),c=(0,i.s)(l),u=(0,r.ref)(null),d=(0,k.Ep)(n.resource);(0,k.nx)(n.resource).then(e=>{u.value=null!==e&&void 0!==e?e:null}).catch(()=>{u.value=null});const h=(0,r.computed)(()=>{const e=l.getters["type-map/labelFor"]({id:n.resource.type}),t=n.resource.nameDisplay;return c.t("component.drawer.resourceDetailDrawer.title",{resourceType:e,resourceName:t})}),p=(0,r.ref)(d?"config-tab":"yaml-tab"),f=(0,r.computed)(()=>"config-tab"===p.value),m=(0,r.computed)(()=>{const e=f.value?c.t("component.drawer.resourceDetailDrawer.ariaLabel.editConfig"):c.t("component.drawer.resourceDetailDrawer.ariaLabel.editYaml"),t=f.value?c.t("component.drawer.resourceDetailDrawer.ariaLabel.editConfig"):c.t("component.drawer.resourceDetailDrawer.ariaLabel.editYaml"),r=f.value?()=>n.resource.goToEdit():()=>n.resource.goToEditYaml();return{ariaLabel:e,label:t,action:r}}),g=(0,r.computed)(()=>f.value?n.resource.canEdit:n.resource.canEditYaml);return(0,k.te)(),(t,i)=>((0,r.openBlock)(),(0,r.createBlock)(b,{ariaTarget:h.value,onClose:i[1]||(i[1]=e=>s("close"))},{title:(0,r.withCtx)(()=>[(0,r.createVNode)(D.A,{color:e.resource.stateSimpleColor,class:"mmr-3"},null,8,["color"]),(0,r.createTextVNode)(" "+(0,r.toDisplayString)(h.value),1)]),body:(0,r.withCtx)(()=>[(0,r.createVNode)(y.A,{useHash:!1,showExtensionTabs:!1,componentTestid:B,"remove-borders":!0,onChanged:i[0]||(i[0]=({selectedName:e})=>{p.value=e})},{default:(0,r.withCtx)(()=>[(0,r.unref)(d)?((0,r.openBlock)(),(0,r.createBlock)(M,(0,r.mergeProps)({key:0},(0,r.unref)(d),{"default-tab":n.defaultTab}),null,16,["default-tab"])):(0,r.createCommentVNode)("",!0),u.value?((0,r.openBlock)(),(0,r.createBlock)(_,(0,r.normalizeProps)((0,r.mergeProps)({key:1},u.value)),null,16)):(0,r.createCommentVNode)("",!0)]),_:1})]),"additional-actions":(0,r.withCtx)(()=>[g.value?((0,r.openBlock)(),(0,r.createBlock)(a.A,{key:0,variant:"primary",size:"large","aria-label":m.value.ariaLabel,"data-testid":L,onClick:m.value.action},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(m.value.label),1)]),_:1},8,["aria-label","onClick"])):(0,r.createCommentVNode)("",!0)]),_:1},8,["ariaTarget"]))}});const V=$;var F=V},10312:function(e,t,n){"use strict";n.d(t,{A:function(){return u}});var r=n(9274);const i={key:0};function o(e,t,n,o,a,s){return a.extensionData.length?((0,r.openBlock)(),(0,r.createElementBlock)("div",i,[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(a.extensionData,(e,t)=>((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:`extensionData${n.location}${t}`},[((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.component),{resource:n.resource},null,8,["resource"]))]))),128))])):(0,r.createCommentVNode)("",!0)}var a=n(25659),s={name:"ExtensionPanel",props:{resource:{type:Object,default:()=>({})},type:{type:String,default:""},location:{type:String,default:""}},data(){return{extensionData:(0,a.A)(this,this.type,this.location,this.$route)}}},l=n(47433);const c=(0,l.A)(s,[["render",o]]);var u=c},12925:function(e,t,n){"use strict";n.d(t,{A:function(){return v}});var r=n(9274),i=n(65359),o=n(23776),a=n(95457),s=n(99726);const l={class:"fail-whale error","data-testid":"fail-whale"},c={class:"text-center"},u={key:0},d={key:1},h={key:2,class:"text-secondary mt-20"},p={key:3,class:"text-secondary mt-20","data-testid":"fail-whale-suggestion"};var f=(0,r.defineComponent)({__name:"FailWhale",props:{error:{type:Object,default:null},suggestion:{type:Object,default:null}},setup(e){const t=e,n=(0,i.Pj)(),{t:f}=(0,a.s)(n),m=(0,r.computed)(()=>{var e;return(null===(e=t.error)||void 0===e?void 0:e.data)?t.error.data:(0,s.As)(t.error)}),g=(0,r.computed)(()=>t.suggestion?f("nav.failWhale.didYouMean",{url:t.suggestion.url,resource:t.suggestion.label},!0):null);return(t,n)=>{const i=(0,r.resolveDirective)("clean-html");return(0,r.openBlock)(),(0,r.createElementBlock)("div",l,[(0,r.createElementVNode)("div",c,[(0,r.createVNode)((0,r.unref)(o.A),{"file-name":"error-desert-landscape.svg",width:"900",height:"300"}),e.error&&e.error.status?((0,r.openBlock)(),(0,r.createElementBlock)("h1",u," HTTP Error "+(0,r.toDisplayString)(e.error.status)+": "+(0,r.toDisplayString)(e.error.statusText),1)):((0,r.openBlock)(),(0,r.createElementBlock)("h1",d," Error ")),e.error?((0,r.openBlock)(),(0,r.createElementBlock)("h2",h,(0,r.toDisplayString)(m.value),1)):(0,r.createCommentVNode)("",!0),g.value?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("h2",p,null,512)),[[i,g.value]]):(0,r.createCommentVNode)("",!0),(0,r.renderSlot)(t.$slots,"actions")])])}}}),m=(n(20770),n(47433));const g=(0,m.A)(f,[["__scopeId","data-v-44d3cb5a"]]);var v=g},27542:function(e,t,n){"use strict";n.d(t,{A:function(){return c}});var r=n(9274);const i={class:"message"};function o(e,t,n,o,a,s){return(0,r.openBlock)(),(0,r.createElementBlock)("div",{class:(0,r.normalizeClass)(["message-icon",{vertical:n.vertical,subtle:n.subtle}])},[(0,r.createElementVNode)("i",{class:(0,r.normalizeClass)(["icon",{[n.icon]:!0,[n.iconState]:!!n.iconState}])},null,2),(0,r.createElementVNode)("div",i,[(0,r.renderSlot)(e.$slots,"message",{},()=>[n.messageKey?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:0},[(0,r.createTextVNode)((0,r.toDisplayString)(e.t(n.messageKey)),1)],64)):((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:1},[(0,r.createTextVNode)((0,r.toDisplayString)(n.message),1)],64))],!0)])],2)}var a={props:{vertical:{type:Boolean,default:!1},icon:{type:String,required:!0},iconState:{type:String,default:null},message:{type:String,default:null},messageKey:{type:String,default:null},subtle:{type:Boolean,default:!1}}},s=(n(47668),n(47433));const l=(0,s.A)(a,[["render",o],["__scopeId","data-v-01996ade"]]);var c=l},74607:function(e,t,n){"use strict";n.d(t,{A:function(){return y}});var r=n(9274);const i=["src","alt"],o={key:2,class:"icon icon-extension"};function a(e,t,n,a,s,l){return n.src?((0,r.openBlock)(),(0,r.createElementBlock)("img",{key:0,src:n.src,class:(0,r.normalizeClass)(["svg-icon",s.className]),alt:n.imgAlt},null,10,i)):n.icon?((0,r.openBlock)(),(0,r.createElementBlock)("i",{key:1,class:(0,r.normalizeClass)(["icon group-icon",n.icon])},null,2)):((0,r.openBlock)(),(0,r.createElementBlock)("i",o))}class s{constructor(e,t,n){this.set(e,t,n)}toString(){return`rgb(${Math.round(this.r)}, ${Math.round(this.g)}, ${Math.round(this.b)})`}set(e,t,n){this.r=this.clamp(e),this.g=this.clamp(t),this.b=this.clamp(n)}hueRotate(e=0){e=e/180*Math.PI;const t=Math.sin(e),n=Math.cos(e);this.multiply([.213+.787*n-.213*t,.715-.715*n-.715*t,.072-.072*n+.928*t,.213-.213*n+.143*t,.715+.285*n+.14*t,.072-.072*n-.283*t,.213-.213*n-.787*t,.715-.715*n+.715*t,.072+.928*n+.072*t])}grayscale(e=1){this.multiply([.2126+.7874*(1-e),.7152-.7152*(1-e),.0722-.0722*(1-e),.2126-.2126*(1-e),.7152+.2848*(1-e),.0722-.0722*(1-e),.2126-.2126*(1-e),.7152-.7152*(1-e),.0722+.9278*(1-e)])}sepia(e=1){this.multiply([.393+.607*(1-e),.769-.769*(1-e),.189-.189*(1-e),.349-.349*(1-e),.686+.314*(1-e),.168-.168*(1-e),.272-.272*(1-e),.534-.534*(1-e),.131+.869*(1-e)])}saturate(e=1){this.multiply([.213+.787*e,.715-.715*e,.072-.072*e,.213-.213*e,.715+.285*e,.072-.072*e,.213-.213*e,.715-.715*e,.072+.928*e])}multiply(e){const t=this.clamp(this.r*e[0]+this.g*e[1]+this.b*e[2]),n=this.clamp(this.r*e[3]+this.g*e[4]+this.b*e[5]),r=this.clamp(this.r*e[6]+this.g*e[7]+this.b*e[8]);this.r=t,this.g=n,this.b=r}brightness(e=1){this.linear(e)}contrast(e=1){this.linear(e,-.5*e+.5)}linear(e=1,t=0){this.r=this.clamp(this.r*e+255*t),this.g=this.clamp(this.g*e+255*t),this.b=this.clamp(this.b*e+255*t)}invert(e=1){this.r=this.clamp(255*(e+this.r/255*(1-2*e))),this.g=this.clamp(255*(e+this.g/255*(1-2*e))),this.b=this.clamp(255*(e+this.b/255*(1-2*e)))}hsl(){const e=this.r/255,t=this.g/255,n=this.b/255,r=Math.max(e,t,n),i=Math.min(e,t,n),o=(r+i)/2;let a=o,s=o;if(r===i)a=s=0;else{const l=r-i;switch(s=o>.5?l/(2-r-i):l/(r+i),r){case e:a=(t-n)/l+(t<n?6:0);break;case t:a=(n-e)/l+2;break;case n:a=(e-t)/l+4;break}a/=6}return{h:100*a,s:100*s,l:100*o}}clamp(e){return e>255?e=255:e<0&&(e=0),e}}class l{constructor(e){this.target=new s(e.r,e.g,e.b),this.targetHSL=this.target.hsl(),this.reusedColor=new s(0,0,0)}solve(){const e=this.solveNarrow(this.solveWide());return{values:e.values,loss:e.loss,filter:this.css(e.values),filterVal:this.css(e.values).replace("filter: ","").replace(";","")}}solveWide(){const e=5,t=15,n=[60,180,18e3,600,1.2,1.2];let r={loss:1/0};for(let i=0;r.loss>25&&i<3;i++){const i=[50,20,3750,50,100,100],o=this.spsa(e,n,t,i,1e3);o.loss<r.loss&&(r=o)}return r}solveNarrow(e){const t=e.loss,n=2,r=t+1,i=[.25*r,.25*r,r,.25*r,.2*r,.2*r];return this.spsa(t,i,n,e.values,500)}spsa(e,t,n,r,i){const o=1,a=.16666666666666666;let s=null,l=1/0;const c=new Array(6),u=new Array(6),d=new Array(6);for(let p=0;p<i;p++){const i=n/Math.pow(p+1,a);for(let e=0;e<6;e++)c[e]=Math.random()>.5?1:-1,u[e]=r[e]+i*c[e],d[e]=r[e]-i*c[e];const f=this.loss(u)-this.loss(d);for(let n=0;n<6;n++){const a=f/(2*i)*c[n],s=t[n]/Math.pow(e+p+1,o);r[n]=h(r[n]-s*a,n)}const m=this.loss(r);m<l&&(s=r.slice(0),l=m)}return{values:s,loss:l};function h(e,t){let n=100;return 2===t?n=7500:4!==t&&5!==t||(n=200),3===t?e>n?e%=n:e<0&&(e=n+e%n):e<0?e=0:e>n&&(e=n),e}}loss(e){const t=this.reusedColor;t.set(0,0,0),t.invert(e[0]/100),t.sepia(e[1]/100),t.saturate(e[2]/100),t.hueRotate(3.6*e[3]),t.brightness(e[4]/100),t.contrast(e[5]/100);const n=t.hsl();return Math.abs(t.r-this.target.r)+Math.abs(t.g-this.target.g)+Math.abs(t.b-this.target.b)+Math.abs(n.h-this.targetHSL.h)+Math.abs(n.s-this.targetHSL.s)+Math.abs(n.l-this.targetHSL.l)}css(e){function t(t,n=1){return Math.round(e[t]*n)}return`filter: invert(${t(0)}%) sepia(${t(1)}%) saturate(${t(2)}%) hue-rotate(${t(3,3.6)}deg) brightness(${t(4)}%) contrast(${t(5)}%);`}}var c=n(39705),u=n(65359);const d={},h={header:{color:"--on-tertiary-header",hover:"--on-tertiary-header-hover",colorFallback:"--header-btn-text",hoverFallback:"--header-btn-text-hover",active:"--on-tertiary-header-hover",activeFallback:"--header-btn-text-hover"},primary:{color:"--on-tertiary",hover:"--tertiary-hover-app-bar",colorFallback:"--on-tertiary",hoverFallback:"--primary-hover-text",active:"--on-active",activeFallback:"--primary-hover-text"}},p={name:"IconOrSvg",props:{src:{type:String,default:()=>{}},icon:{type:String,default:()=>{}},imgAlt:{type:String,default:()=>{}},color:{type:String,default:()=>"primary"}},data(){return{className:"",mainFilter:null,hoverFilter:null,activeFilter:null}},created(){this.src&&this.setColor()},computed:{...(0,u.L8)({brand:"management/brand",theme:"prefs/theme"})},watch:{brand:"recomputeColor",theme:"recomputeColor",src:"recomputeColor"},methods:{getComputedStyleFor(e,t){const n=window.getComputedStyle(document.body).getPropertyValue(e).trim();return(0,c.Tv)((0,c.yq)(n??t))},resolveColorFilter(e,t){if(d[e])return d[e];const n=new l(t),r=n.solve(),i=r?.filterVal;return d[e]=i,i},setColor(){const e=h[this.color],t=this.getComputedStyleFor(e.color,e.colorFallback),n=this.getComputedStyleFor(e.hover,e.hoverFallback),r=this.getComputedStyleFor(e.active,e.activeFallback);if(!t||!n||!r)return;const i=(0,c.qe)(t),o=(0,c.qe)(n),a=(0,c.qe)(r),s=`${i.r}-${i.g}-${i.b}`,l=`${o.r}-${o.g}-${o.b}`,u=`svg-icon-${s}-${l}`;this.hoverFilter=this.resolveColorFilter(n,o),this.mainFilter=this.resolveColorFilter(t,i),this.activeFilter=this.resolveColorFilter(r,a),this["className"]=u},recomputeColor(){this.src&&(this.mainFilter=null,this.hoverFilter=null,this.activeFilter=null,this.setColor())}}},f=()=>{(0,r.useCssVars)(e=>({v6579a48c:e.mainFilter,v0ae929cb:e.hoverFilter,v55a59307:e.activeFilter}))},m=p.setup;p.setup=m?(e,t)=>(f(),m(e,t)):f;var g=p,v=(n(76258),n(47433));const b=(0,v.A)(g,[["render",a],["__scopeId","data-v-2e8d063a"]]);var y=b},56279:function(e,t,n){"use strict";n.d(t,{A:function(){return c}});var r=n(9274);const i={key:0,class:"step-number mb-10"};function o(e,t,n,o,a,s){return(0,r.openBlock)(),(0,r.createElementBlock)("div",{class:(0,r.normalizeClass)([{stepped:!!n.step},"info-box"])},[n.step?((0,r.openBlock)(),(0,r.createElementBlock)("div",i,[(0,r.createElementVNode)("h2",null,"Step "+(0,r.toDisplayString)(n.step),1)])):(0,r.createCommentVNode)("",!0),(0,r.renderSlot)(e.$slots,"default",{},void 0,!0)],2)}var a={props:{step:{type:Number,default:null}}},s=(n(9607),n(47433));const l=(0,s.A)(a,[["render",o],["__scopeId","data-v-4f4f1f5e"]]);var c=l},40960:function(e,t,n){"use strict";n.d(t,{A:function(){return d}});var r=n(9274);const i=["src"];function o(e,t,n,o,a,s){return(0,r.openBlock)(),(0,r.createElementBlock)("img",(0,r.mergeProps)({ref:"img",src:n.initialSrc},e.$attrs),null,16,i)}var a=n(8187),s=n.p+"img/generic-catalog.1842a50e.svg",l={props:{initialSrc:{type:String,default:a.Rd},errorSrc:{type:String,default:s},src:{type:String,default:null}},watch:{src(e,t){if(e!==t){if(!e)return this.onError();this.intersected?this.loadImage():this.observer||this.startObserver()}}},created(){this.observer=null,this.intersected=!1,this.boundError=null},mounted(){this.src?this.startObserver():this.onError()},beforeUnmount(){const e=this.$refs.img;e&&this.boundError&&e.removeEventListener("error",this.boundError),this.observer&&(this.observer.disconnect(),this.observer=null)},methods:{startObserver(){this.src&&!this.observer&&this.$refs.img&&(this.observer=new IntersectionObserver(e=>{const t=e[0];t.isIntersecting&&(this.intersected=!0,this.loadImage(),this.observer&&(this.observer.disconnect(),this.observer=null))}),this.observer.observe(this.$refs.img))},loadImage(){const e=this.$refs.img;this.src&&(e&&this.boundError&&e.removeEventListener("error",this.boundError),e.setAttribute("src",this.src),this.boundError=this.onError.bind(this),e.addEventListener("error",this.boundError))},onError(){const e=this.$refs.img;e&&e.setAttribute("src",this.errorSrc)}}},c=n(47433);const u=(0,c.A)(l,[["render",o]]);var d=u},58972:function(e,t,n){"use strict";n.d(t,{A:function(){return d}});var r=n(9274);const i={key:0,class:"loading-indicator"},o={key:1};function a(e,t,n,a,s,l){const c=(0,r.resolveComponent)("t");return n.loading?((0,r.openBlock)(),(0,r.createElementBlock)("div",i,[s.showMessage?((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:0,class:(0,r.normalizeClass)(["overlay",{"overlay-content-mode":"content"===n.mode,"overlay-main-mode":"main"===n.mode}])},[(0,r.createVNode)(c,{k:"generic.loading",raw:!0})],2)):(0,r.createCommentVNode)("",!0)])):((0,r.openBlock)(),(0,r.createElementBlock)("div",o,[(0,r.renderSlot)(e.$slots,"default",{},void 0,!0)]))}var s=n(80869),l={props:{loading:{type:Boolean,default:!0},mode:{type:String,default:"content"},noDelay:{type:Boolean,default:!1},announceStatus:{type:Boolean,default:!0}},data(){return{timer:null,showMessage:this.noDelay}},mounted(){this.timer=setTimeout(()=>{this.showMessage=!0,this.loading&&this.announceStatus&&(0,s.iP)(this.$store.getters["i18n/t"]("generic.loading"))},250)},beforeUnmount(){clearTimeout(this.timer)}},c=(n(73597),n(47433));const u=(0,c.A)(l,[["render",a],["__scopeId","data-v-c3588e48"]]);var d=u},12243:function(e,t,n){"use strict";n.d(t,{A:function(){return g}});var r=n(9274);const i={class:"percentage-bar"},o={key:0,class:"ml-5 percentage-value"};function a(e,t,n,a,s,l){const c=(0,r.resolveComponent)("Bar");return(0,r.openBlock)(),(0,r.createElementBlock)("span",i,[(0,r.createVNode)(c,{percentage:n.modelValue,"primary-color":l.primaryColor,slices:n.slices},null,8,["percentage","primary-color","slices"]),n.showPercentage?((0,r.openBlock)(),(0,r.createElementBlock)("span",o,(0,r.toDisplayString)(l.formattedPercentage),1)):(0,r.createCommentVNode)("",!0)])}function s(e,t,n,i,o,a){return(0,r.openBlock)(),(0,r.createElementBlock)("div",{class:"bar",style:(0,r.normalizeStyle)(a.barStyle)},[(0,r.createElementVNode)("div",{class:"indicator",style:(0,r.normalizeStyle)(a.indicatorStyle)},null,4),((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(a.sliceStyles,(e,t)=>((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:t,class:"slice",style:(0,r.normalizeStyle)(e)},null,4))),128))],4)}var l={props:{percentage:{type:Number,required:!0},primaryColor:{type:String,default:"--primary"},secondaryColor:{type:String,default:"--border"},slices:{type:Array,default:()=>[]}},computed:{indicatorStyle(){return{width:`${this.percentage}%`,backgroundColor:`var(${this.primaryColor})`}},barStyle(){return{backgroundColor:`var(${this.secondaryColor})`}},sliceStyles(){return this.slices.map(e=>({left:`${e}%`,visibility:e<this.percentage?"visible":"hidden"}))}}},c=(n(54752),n(47433));const u=(0,c.A)(l,[["render",s],["__scopeId","data-v-b4f4e2ae"]]);var d=u,h=n(92043);const p={LESS:"LESS",MORE:"MORE"};var f={components:{Bar:d},props:{modelValue:{type:Number,required:!0,validator(e){return e>=0}},preferredDirection:{type:String,default:p.LESS},showPercentage:{type:Boolean,default:!1},colorStops:{type:Object,default:null},slices:{type:Array,default:()=>[]}},computed:{primaryColor(){const e=this.preferredDirection===p.LESS;if(this.colorStops){const t=Object.keys(this.colorStops).sort();if(e){let e=t.length-1;while(this.modelValue<t[e])e--;return this.colorStops[t[e]]}{let e=0;while(this.modelValue>t[e])e++;return this.colorStops[t[e]]}}const t=e?80:20,n=e?this.modelValue:t,r=e?t:this.modelValue;return n<=r?"--primary":"--error"},formattedPercentage(){return(0,h.l9)(this.modelValue)}}};n(70738);const m=(0,c.A)(f,[["render",a],["__scopeId","data-v-4ade54a6"]]);var g=m},74315:function(e,t,n){"use strict";n.d(t,{A:function(){return h}});var r=n(9274);const i=["aria-label"];function o(e,t,n,o,a,s){const l=(0,r.resolveDirective)("trim-whitespace");return(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("div",{class:(0,r.normalizeClass)({progress:!0,multi:s.pieces.length>1}),"aria-label":s.ariaLabelText,role:"progressbar"},[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(s.pieces,(e,t)=>(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:t,class:(0,r.normalizeClass)({piece:!0,[e.color]:!0}),style:(0,r.normalizeStyle)(e.style)},null,6)),[[l]])),128))],10,i)),[[l]])}var a=n(74302),s=n(76978),l={props:{values:{type:Array,required:!0},colorKey:{type:String,default:"color"},labelKey:{type:String,default:"label"},valueKey:{type:String,default:"value"},min:{type:Number,default:0},max:{type:Number,default:null},minPercent:{type:Number,default:5},showZeros:{type:Boolean,default:!1}},computed:{pieces(){const e=[];for(const o of this.values){const t=(0,s.Jt)(o,this.colorKey),n=(0,s.Jt)(o,this.labelKey),r=(0,s.Jt)(o,this.valueKey);(0!==r||this.showZeros)&&e.push({color:t,label:n,value:r})}const t=this.minPercent||0,n=this.min||0;let r=this.max,i=0;this.max||(r=100,e.length&&(r=e.map(e=>e.value).reduce((e,t)=>e+t)));for(const o of e){const e=Math.max(t,c(o.value,n,r));o.percent=e,i+=e}i>100&&((0,a.Ul)(e,"percent",!0)[0].percent-=i-100);for(const o of e)o.style=`width: ${o.percent}%`;return e.filter(e=>e.percent)},ariaLabelText(){if(Array.isArray(this.values)&&this.values.length){let e="";return this.values.forEach(t=>{e+=`${t.value} ${1===t.value?"item":"items"} ${t.label}`}),e}return""}}};function c(e,t,n){e=Math.max(t,Math.min(n,e));let r=e/(n-t)*100;return r=Math.floor(100*r)/100,r}n(31782);var u=n(47433);const d=(0,u.A)(l,[["render",o],["__scopeId","data-v-154bda8a"]]);var h=d},65019:function(e,t,n){"use strict";n.d(t,{A:function(){return c}});var r=n(9274);const i={class:"vertical-gap"};function o(e,t){return(0,r.openBlock)(),(0,r.createElementBlock)("div",i," ")}n(17299);var a=n(47433);const s={},l=(0,a.A)(s,[["render",o],["__scopeId","data-v-43905492"]]);var c=l},28438:function(e,t,n){"use strict";n.d(t,{A:function(){return h}});var r=n(9274),i=n(65019);const o={class:"detail-card"},a={class:"heading"},s={class:"title"},l={class:"body"};var c=(0,r.defineComponent)({__name:"index",props:{title:{}},setup(e){return(t,n)=>((0,r.openBlock)(),(0,r.createElementBlock)("div",o,[(0,r.createElementVNode)("div",a,[(0,r.renderSlot)(t.$slots,"heading",{},()=>[(0,r.createElementVNode)("div",s,[(0,r.renderSlot)(t.$slots,"title",{},()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.title),1)])])]),(0,r.renderSlot)(t.$slots,"heading-action")]),(0,r.createVNode)(i.A),(0,r.createElementVNode)("div",l,[(0,r.renderSlot)(t.$slots,"default")])]))}}),u=(n(64454),n(47433));const d=(0,u.A)(c,[["__scopeId","data-v-ecc6c722"]]);var h=d},3049:function(e,t,n){"use strict";n.d(t,{A:function(){return Xn}});var r=n(9274);const i={key:3},o={key:1,id:"cru-errors",class:"cru__errors",role:"alert","aria-live":"assertive","aria-atomic":"true"},a=["data-testid"],s=["data-testid"],l=["data-testid"],c=["data-testid"];function u(e,t,n,u,d,h){const p=(0,r.resolveComponent)("Loading"),f=(0,r.resolveComponent)("FailWhale"),m=(0,r.resolveComponent)("DetailTop"),g=(0,r.resolveComponent)("Masthead"),v=(0,r.resolveComponent)("Banner"),b=(0,r.resolveComponent)("ResourceYaml"),y=(0,r.resolveDirective)("ui-context"),w=(0,r.resolveDirective)("shortkey");return e.$fetchState.pending||d.notFound?((0,r.openBlock)(),(0,r.createBlock)(p,{key:0})):d.resourceNotFoundError?((0,r.openBlock)(),(0,r.createBlock)(f,{key:1,error:d.resourceNotFoundError},null,8,["error"])):h.isFullPageOverride?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(h.showComponent),(0,r.mergeProps)({key:2,value:d.value,"onUpdate:value":t[0]||(t[0]=e=>d.value=e)},e.$data,{"done-params":e.doneParams,"done-route":e.doneRoute,mode:d.mode,"initial-value":d.initialModel,"live-value":d.liveModel,"real-mode":h.realMode,class:{"flex-content":n.flexContent},"resource-errors":d.errors,"onUpdate:value":t[1]||(t[1]=t=>e.$emit("input",t)),onSetSubtype:h.setSubtype}),null,16,["value","done-params","done-route","mode","initial-value","live-value","real-mode","class","resource-errors","onSetSubtype"])),[[y,{icon:"icon-folder",value:d.value.name,tag:d.value.kind?.toLowerCase(),description:d.value.kind}]]):((0,r.openBlock)(),(0,r.createElementBlock)("div",i,[e.showMasthead?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createBlock)(g,{key:0,resource:d.resourceType,value:d.liveModel,mode:d.mode,"real-mode":h.realMode,as:d.as,"has-detail":d.hasCustomDetail,"has-edit":d.hasCustomEdit,"can-view-yaml":d.canViewYaml,"resource-subtype":d.resourceSubtype,"parent-route-override":n.parentRouteOverride,"store-override":n.storeOverride},{default:(0,r.withCtx)(()=>[h.isView&&h.isDetail?((0,r.openBlock)(),(0,r.createBlock)(m,{key:0,value:d.liveModel},null,8,["value"])):(0,r.createCommentVNode)("",!0)]),_:1},8,["resource","value","mode","real-mode","as","has-detail","has-edit","can-view-yaml","resource-subtype","parent-route-override","store-override"])),[[y,{icon:"icon-folder",value:d.liveModel.name,tag:d.liveModel.kind?.toLowerCase(),description:d.liveModel.kind}]]):(0,r.createCommentVNode)("",!0),h.hasErrors?((0,r.openBlock)(),(0,r.createElementBlock)("div",o,[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(d.errors,(e,t)=>((0,r.openBlock)(),(0,r.createBlock)(v,{key:t,color:"error","data-testid":`error-banner${t}`,label:h.stringify(h.mappedErrors[e].message),icon:h.mappedErrors[e].icon,closable:!0,onClose:e=>h.closeError(t)},null,8,["data-testid","label","icon","onClose"]))),128))])):(0,r.createCommentVNode)("",!0),h.isYaml?((0,r.openBlock)(),(0,r.createBlock)(b,{key:2,ref:"resourceyaml",value:d.value,mode:d.mode,yaml:d.yaml,"offer-preview":h.offerPreview,"done-route":e.doneRoute,"done-override":d.value?d.value.doneOverride:null,"show-errors":!1,"onUpdate:value":t[2]||(t[2]=t=>e.$emit("input",t)),onError:h.onYamlError},null,8,["value","mode","yaml","offer-preview","done-route","done-override","onError"])):(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(h.showComponent),(0,r.mergeProps)({key:3,ref:"comp",value:d.value,"onUpdate:value":t[3]||(t[3]=e=>d.value=e)},e.$data,{"done-params":e.doneParams,"done-route":e.doneRoute,mode:d.mode,"initial-value":d.initialModel,"live-value":d.liveModel,"real-mode":h.realMode,class:{"flex-content":n.flexContent},"onUpdate:value":t[4]||(t[4]=t=>e.$emit("input",t)),onSetSubtype:h.setSubtype}),null,16,["value","done-params","done-route","mode","initial-value","live-value","real-mode","class","onSetSubtype"])),[[y,{icon:"icon-folder",value:d.value.name,tag:d.value.kind?.toLowerCase(),description:d.value.kind}]]),h.isView?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:4,"data-testid":n.componentTestid+"-detail",class:"hide",onShortkey:t[5]||(t[5]=e=>h.keyAction("goToDetail"))},null,40,a)),[[w,["shift","d"],void 0,{once:!0}]]):(0,r.createCommentVNode)("",!0),h.isView?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:5,"data-testid":n.componentTestid+"-config",class:"hide",onShortkey:t[6]||(t[6]=e=>h.keyAction("goToViewConfig"))},null,40,s)),[[w,["shift","c"],void 0,{once:!0}]]):(0,r.createCommentVNode)("",!0),h.isView?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:6,"data-testid":n.componentTestid+"-yaml",class:"hide",onShortkey:t[7]||(t[7]=e=>h.keyAction("goToViewYaml"))},null,40,l)),[[w,["shift","y"],void 0,{once:!0}]]):(0,r.createCommentVNode)("",!0),h.isView?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:7,"data-testid":n.componentTestid+"-edit",class:"hide",onShortkey:t[8]||(t[8]=e=>h.keyAction("goToEdit"))},null,40,c)),[[w,["shift","e"],void 0,{once:!0}]]):(0,r.createCommentVNode)("",!0)]))}var d=n(65375),h=n(58972),p=n(67100),f=n(14220),m=n(35664),g=n(37648),v=n(65359),b=n(9980),y=n(79117),w=n(3252);const O={class:"title"};function S(e,t){return(0,r.openBlock)(),(0,r.createElementBlock)("h1",O,[(0,r.renderSlot)(e.$slots,"default",{},void 0,!0)])}n(94068);var E=n(47433);const x={},_=(0,E.A)(x,[["render",S],["__scopeId","data-v-1e04f798"]]);var k=_;const C={class:"top"};function A(e,t){return(0,r.openBlock)(),(0,r.createElementBlock)("div",C,[(0,r.renderSlot)(e.$slots,"default",{},void 0,!0)])}n(85547);const T={},R=(0,E.A)(T,[["render",A],["__scopeId","data-v-9aaa96a4"]]);var N=R,P=n(76204),I=n(95457),M=n(71126),D=n(22896),L=n(31915),B=n(10312),$=n(45250);const V={class:"title-bar"},F={class:"title-row"},j={key:1,class:"resource-text"},U={class:"resource-name masthead-resource-title"},G={class:"actions"},H={key:0,class:"bottom description text-deemphasized"};var q=(0,r.defineComponent)({__name:"index",props:{resource:{},resourceTypeLabel:{},resourceName:{},resourceTo:{},description:{},badge:{},additionalActions:{},actionMenuResource:{},onShowConfiguration:{type:Function}},emits:["show-configuration"],setup(e,{emit:t}){var n,i,o;const a=(0,v.Pj)(),s=(0,I.s)(a),l=(0,w.rd)(),c=t,u="show-configuration-cta",d=(0,r.computed)(()=>`[data-testid="${u}"]`),h=(0,r.ref)((null===(o=null===(i=null===(n=null===l||void 0===l?void 0:l.currentRoute)||void 0===n?void 0:n.value)||void 0===i?void 0:i.query)||void 0===o?void 0:o.as)||f.au);(0,r.watch)(()=>h.value,()=>{l.push({query:{[f.AS]:h.value}})});const p=(0,r.computed)(()=>(0,$.isArray)(e.additionalActions));return(t,n)=>{const i=(0,r.resolveComponent)("router-link"),o=(0,r.resolveDirective)("ui-context");return(0,r.openBlock)(),(0,r.createElementBlock)("div",V,[(0,r.createVNode)(N,null,{default:(0,r.withCtx)(()=>[(0,r.createElementVNode)("div",F,[(0,r.createVNode)(k,{class:"title"},{default:(0,r.withCtx)(()=>[(0,r.createVNode)((0,r.unref)(D.A),{"show-child":!1},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.resourceTypeLabel),1)]),_:1}),e.resourceTo?((0,r.openBlock)(),(0,r.createBlock)(i,{key:0,to:e.resourceTo,class:"resource-link"},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.resourceTypeLabel)+": ",1)]),_:1},8,["to"])):((0,r.openBlock)(),(0,r.createElementBlock)("span",j,(0,r.toDisplayString)(e.resourceTypeLabel)+": ",1)),(0,r.createElementVNode)("span",U,(0,r.toDisplayString)(e.resourceName),1),e.badge?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createBlock)(y.A,{key:2,class:"badge-state",color:e.badge.color,label:e.badge.label},null,8,["color","label"])),[[o,{store:(0,r.unref)(a),icon:"icon-folder",hookable:!0,value:e.resource,tag:"__details-state",description:"Details"}]]):(0,r.createCommentVNode)("",!0)]),_:1}),(0,r.renderSlot)(t.$slots,"title-suffix")]),(0,r.createElementVNode)("div",G,[(0,r.renderSlot)(t.$slots,"additional-actions",{},()=>[e.additionalActions?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:0},[p.value?((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,{key:0},(0,r.renderList)(e.additionalActions,(e,t)=>((0,r.openBlock)(),(0,r.createBlock)(M.A,{key:`action-button-${t}`,variant:e.variant,size:e.size,onClick:e.onClick},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.label),1)]),_:2},1032,["variant","size","onClick"]))),128)):((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.additionalActions),{key:1}))],64)):(0,r.createCommentVNode)("",!0)]),e.onShowConfiguration?((0,r.openBlock)(),(0,r.createBlock)(M.A,{key:0,"data-testid":u,class:"show-configuration",variant:"primary",size:"large","aria-label":(0,r.unref)(s).t("component.resource.detail.titleBar.ariaLabel.showConfiguration",{resource:e.resourceName}),onClick:n[0]||(n[0]=()=>c("show-configuration",d.value))},{default:(0,r.withCtx)(()=>[n[1]||(n[1]=(0,r.createElementVNode)("i",{class:"icon icon-document","aria-hidden":"true"},null,-1)),(0,r.createTextVNode)(" "+(0,r.toDisplayString)((0,r.unref)(s).t("component.resource.detail.titleBar.showConfiguration")),1)]),_:1},8,["aria-label"])):(0,r.createCommentVNode)("",!0),e.actionMenuResource?((0,r.openBlock)(),(0,r.createBlock)(P.A,{key:1,"button-variant":"multiAction",resource:e.actionMenuResource,"data-testid":"masthead-action-menu","button-aria-label":(0,r.unref)(s).t("component.resource.detail.titleBar.ariaLabel.actionMenu",{resource:e.resourceName})},null,8,["resource","button-aria-label"])):(0,r.createCommentVNode)("",!0)])]),_:3}),e.description?((0,r.openBlock)(),(0,r.createElementBlock)("div",H,(0,r.toDisplayString)(e.description),1)):(0,r.createCommentVNode)("",!0),(0,r.createVNode)(B.A,{resource:e.resource,type:(0,r.unref)(L.c7).PANEL,location:(0,r.unref)(L.W7).DETAILS_MASTHEAD},null,8,["resource","type","location"])])}}});n(24511);const Q=(0,E.A)(q,[["__scopeId","data-v-01615b82"]]);var z=Q,K=n(73883);const W=e=>{const t=(0,v.Pj)(),n=(0,I.s)(t),i=(0,r.toValue)(e);return(0,r.computed)(()=>{var e,r,o;const a=t.getters["type-map/optionsFor"](i.type);if(!a.hideBanner){if(null===(e=null===i||void 0===i?void 0:i.stateObj)||void 0===e?void 0:e.error){const e=n.t("resourceDetail.masthead.defaultBannerMessage.error",void 0,!0);return{color:"error",label:i.stateObj.message||e}}if(null===(r=null===i||void 0===i?void 0:i.spec)||void 0===r?void 0:r.paused)return{color:"info",label:n.t("asyncButton.pause.description")};if(null===(o=null===i||void 0===i?void 0:i.stateObj)||void 0===o?void 0:o.transitioning){const e=n.t("resourceDetail.masthead.defaultBannerMessage.transitioning",void 0,!0);return{color:"info",label:i.stateObj.message||e}}}})},X=e=>(t,n)=>{const i=(0,r.toValue)(e),o=i.showConfiguration?i.showConfiguration.bind(i):K.Ay.prototype.showConfiguration.bind(i);o(t,n)},Y=(e,t)=>{const n=(0,w.lq)(),i=(0,v.Pj)(),o=(0,r.toValue)(e);return(0,r.computed)(()=>{const a=(0,r.toValue)(t),s=i.getters["currentStore"](o.type),l=i.getters[`${s}/schemaFor`](o.type),c=o.parentNameOverride||i.getters["type-map/labelFor"](l),u=a?`${a} - ${o.nameDisplay}`:o.nameDisplay,d=o.listLocation||{name:"c-cluster-product-resource",params:{product:"explorer",cluster:null===n||void 0===n?void 0:n.params.cluster,namespace:o.namespace,resource:o.type}},h=o.disableResourceDetailDrawer?void 0:X(e);return{resource:o,resourceTypeLabel:c,resourceTo:d,resourceName:u,actionMenuResource:o,badge:{color:o.stateBackground,label:o.stateDisplay},description:o.description,additionalActions:o.detailPageAdditionalActions,onShowConfiguration:h}})},Z={class:"identifying-information"},J=["data-testid"],ee=["for"],te=["id"],ne=["id"],re=["id"],ie=["data-testid","aria-label"],oe=["data-testid"];var ae=(0,r.defineComponent)({__name:"index",props:{rows:{}},setup(e){const t=e=>`value-${e.label}:${e.value}`.toLowerCase().replaceAll(" ","");return(n,i)=>{const o=(0,r.resolveComponent)("router-link");return(0,r.openBlock)(),(0,r.createElementBlock)("div",Z,[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(e.rows,e=>{var n,i,a,s,l,c,u,d,h;return(0,r.openBlock)(),(0,r.createElementBlock)("div",{key:`${e.label}:${e.value}`,class:"row","data-testid":e.dataTestid},[(0,r.createElementVNode)("label",{class:"label text-deemphasized",for:t(e)},(0,r.toDisplayString)(e.label),9,ee),"string"!==typeof(null===(n=e.valueOverride)||void 0===n?void 0:n.component)&&(null===(i=e.valueOverride)||void 0===i?void 0:i.component)&&e.value?((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:0,id:t(e),class:"full-custom-value"},[(null===(a=e.valueOverride)||void 0===a?void 0:a.component)?((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(null===(s=e.valueOverride)||void 0===s?void 0:s.component),(0,r.mergeProps)({key:0,ref_for:!0},null===(l=e.valueOverride)||void 0===l?void 0:l.props,{"data-testid":e.valueDataTestid}),null,16,["data-testid"])):(0,r.createCommentVNode)("",!0)],8,te)):(null===(c=e.valueOverride)||void 0===c?void 0:c.component)&&e.value?((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:1,id:t(e),class:"value"},[(null===(u=e.valueOverride)||void 0===u?void 0:u.component)?((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(null===(d=e.valueOverride)||void 0===d?void 0:d.component),(0,r.mergeProps)({key:0,ref_for:!0},null===(h=e.valueOverride)||void 0===h?void 0:h.props,{"data-testid":e.valueDataTestid}),null,16,["data-testid"])):(0,r.createCommentVNode)("",!0)],8,ne)):((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:2,id:t(e),class:"value"},[e.status?((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:0,class:(0,r.normalizeClass)(["status",e.status])},null,2)):(0,r.createCommentVNode)("",!0),e.value&&e.to?((0,r.openBlock)(),(0,r.createBlock)(o,{key:1,to:e.to,"data-testid":e.valueDataTestid},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.value),1)]),_:2},1032,["to","data-testid"])):e.value?((0,r.openBlock)(),(0,r.createElementBlock)("span",{key:2,"data-testid":e.valueDataTestid,tabindex:"0","aria-label":e.value},(0,r.toDisplayString)(e.value),9,ie)):((0,r.openBlock)(),(0,r.createElementBlock)("span",{key:3,class:"text-muted","data-testid":e.valueDataTestid},"—",8,oe))],8,re))],8,J)}),128))])}}});n(66324);const se=(0,E.A)(ae,[["__scopeId","data-v-e12d7178"]]);var le=se,ce=n(48881);const ue=["aria-label"];var de=(0,r.defineComponent)({__name:"CopyToClipboard",props:{value:{}},setup(e){const t=e,n=(0,v.Pj)(),i=(0,I.s)(n),o=(0,r.ref)(!1),a=(0,r.ref)(null),s=e=>{e.stopPropagation(),(0,ce.e)(t.value),o.value=!0,a.value||(a.value=setTimeout(()=>{o.value=!1,a.value=null},2e3))};return(e,t)=>((0,r.openBlock)(),(0,r.createElementBlock)("button",{class:(0,r.normalizeClass)(["copy-to-clipboard",{copied:o.value}]),"aria-label":(0,r.unref)(i).t("component.resource.detail.copyToClipboard.ariaLabel.copy"),onClick:s},[...t[0]||(t[0]=[(0,r.createElementVNode)("i",{class:"icon icon-copy"},null,-1)])],10,ue))}});n(26550);const he=(0,E.A)(de,[["__scopeId","data-v-24cd76d6"]]);var pe=he,fe=n(6963),me=n(92043);const ge={class:"content"},ve={key:0},be={key:2,"data-testid":"detail-top_html",class:(0,r.normalizeClass)({monospace:!0})};var ye=(0,r.defineComponent)({__name:"Content",props:{value:{}},setup(e){const t=e,n=(0,r.computed)(()=>0===t.value.length),i=(0,r.computed)(()=>{const e=t.value;if(e&&(e.startsWith("{")||e.startsWith("[")))try{let t=JSON.parse(e);return t=JSON.stringify(t,null,2),t}catch(n){}return null}),o=(0,r.computed)(()=>(0,me.Kn)(t.value));return(e,t)=>{const a=(0,r.resolveDirective)("t"),s=(0,r.resolveDirective)("clean-html");return(0,r.openBlock)(),(0,r.createElementBlock)("div",ge,[n.value?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("span",ve,null,512)),[[a,"detailText.empty"]]):i.value?((0,r.openBlock)(),(0,r.createBlock)(fe.A,{key:1,mode:(0,r.unref)(f.nW),options:{mode:{name:"javascript",json:!0},lineNumbers:!1,foldGutter:!1},value:i.value},null,8,["mode","value"])):(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("span",be,null,512)),[[s,o.value]])])}}});n(72023);const we=(0,E.A)(ye,[["__scopeId","data-v-a4c0d9ce"]]);var Oe=we,Se=n(82149);const Ee={class:"title"};var xe=(0,r.defineComponent)({inheritAttrs:!1,__name:"Preview",props:{title:{},value:{},anchorElement:{}},emits:["close"],setup(e,{emit:t}){(0,r.useCssVars)(e=>({v00bc9ff6:s.value,e48f64a2:a.value}));const n=e,i=t,o=(0,r.computed)(()=>{var e;return null===(e=n.anchorElement)||void 0===e?void 0:e.getBoundingClientRect()}),a=(0,r.computed)(()=>{var e;return((null===(e=o.value)||void 0===e?void 0:e.top)||0)-28+"px"}),s=(0,r.computed)(()=>{var e;return document.documentElement.clientWidth-((null===(e=o.value)||void 0===e?void 0:e.left)||0)+16+"px"}),l=(0,r.ref)(null),c=(0,r.ref)(!1),u=(0,r.ref)(!1),d=e=>{var t;!c.value&&(null===(t=l.value)||void 0===t?void 0:t.contains(e.relatedTarget))?u.value&&l.value.focus():i("close",c.value)},h=e=>{var t;"Escape"===e.key&&(c.value=!0,null===(t=l.value)||void 0===t||t.blur())};return(0,r.onMounted)(()=>{var e;null===(e=l.value)||void 0===e||e.focus()}),(0,Se.kS)("#focus-trap-preview-container-element"),(e,t)=>((0,r.openBlock)(),(0,r.createBlock)(r.Teleport,{to:"#preview"},[(0,r.createElementVNode)("div",{id:"focus-trap-preview-container-element",ref_key:"containerRef",ref:l,class:"preview",tabindex:"-1",onKeydown:h,onFocusout:d,onMousedown:t[0]||(t[0]=e=>u.value=!0),onMouseup:t[1]||(t[1]=e=>u.value=!1)},[(0,r.createElementVNode)("div",Ee,(0,r.toDisplayString)(n.title),1),(0,r.createVNode)(Oe,{class:"content",value:n.value},null,8,["value"]),(0,r.createVNode)(pe,{class:"copy-to-clipboard",value:n.value},null,8,["value"])],544)]))}});n(19935);const _e=(0,E.A)(xe,[["__scopeId","data-v-79b3e65a"]]);var ke=_e,Ce=n(53440);const Ae={class:"tag-data"};var Te=(0,r.defineComponent)({__name:"KeyValueRow",props:{row:{},type:{}},setup(e){const t=e,n=(0,v.Pj)(),i=(0,I.s)(n),o=(0,r.ref)(!1),a=(0,r.ref)(null),s=(0,r.ref)(null),l=e=>{o.value=!1,e&&(0,r.nextTick)(()=>{var e;null===(e=s.value)||void 0===e||e.focus()})},c=(0,me.vx)();return(n,u)=>((0,r.openBlock)(),(0,r.createElementBlock)("div",{ref_key:"element",ref:a,class:(0,r.normalizeClass)(["key-value-row",{"show-preview":o.value,[t.type]:!0}])},[(0,r.createVNode)(M.A,{ref_key:"button",ref:s,variant:"ghost","aria-haspopup":"dialog","aria-expanded":o.value,"aria-controls":(0,r.unref)(c),"aria-label":(0,r.unref)(i).t("component.resource.detail.metadata.keyValue.ariaLabel.showPreview"),onClick:u[0]||(u[0]=()=>o.value=!0)},{default:(0,r.withCtx)(()=>[(0,r.createVNode)(Ce.A,{type:e.type,highlight:o.value},{default:(0,r.withCtx)(()=>[(0,r.createElementVNode)("span",Ae,(0,r.toDisplayString)(t.row.key)+": "+(0,r.toDisplayString)(t.row.value),1)]),_:1},8,["type","highlight"])]),_:1},8,["aria-expanded","aria-controls","aria-label"]),(0,r.createVNode)(pe,{value:e.row.value},null,8,["value"]),o.value?((0,r.openBlock)(),(0,r.createBlock)(ke,{key:0,id:(0,r.unref)(c),class:"preview",title:e.row.key,value:e.row.value,"anchor-element":a.value,"aria-live":"polite",onClose:l},null,8,["id","title","value","anchor-element"])):(0,r.createCommentVNode)("",!0)],2))}});n(87752);const Re=(0,E.A)(Te,[["__scopeId","data-v-cd4e2248"]]);var Ne=Re;const Pe={class:"key-value"},Ie={class:"heading"},Me={class:"title text-deemphasized"},De={class:"count"},Le={key:0,class:"empty mmt-2 text-deemphasized"},Be={class:"no-rows"},$e={class:"show-configuration mmt-1"},Ve=["data-testid"],Fe=["data-testid"];var je=(0,r.defineComponent)({__name:"KeyValue",props:{propertyName:{},rows:{},type:{},maxRows:{default:4},onShowConfiguration:{type:Function,default:void 0}},emits:["show-configuration"],setup(e,{emit:t}){const n=e,{propertyName:i,rows:o,maxRows:a}=(0,r.toRefs)(n),s=(0,v.Pj)(),l=(0,I.s)(s),c=t,u=(0,r.computed)(()=>o.value.length>a.value?a.value-1:o.value.length),d=(0,r.computed)(()=>o.value.slice(0,u.value)),h=(0,r.computed)(()=>i.value.toLowerCase()),p=(0,r.computed)(()=>o.value.length>a.value),f=(0,r.computed)(()=>`Show all ${h.value}`),m=e=>`${e.key}: ${e.value}`,g=(0,r.computed)(()=>`empty-show-configuration_${i.value.replaceAll(" ","").toLowerCase()}`),b=(0,r.computed)(()=>`[data-testid="${g.value}"]`),y=(0,r.computed)(()=>`more-show-configuration_${i.value.replaceAll(" ","").toLowerCase()}`),w=(0,r.computed)(()=>`[data-testid="${y.value}"]`);return(e,t)=>((0,r.openBlock)(),(0,r.createElementBlock)("div",Pe,[(0,r.createElementVNode)("div",Ie,[(0,r.createElementVNode)("span",Me,(0,r.toDisplayString)((0,r.unref)(i)),1),(0,r.createElementVNode)("span",De,(0,r.toDisplayString)((0,r.unref)(o).length),1)]),0===d.value.length?((0,r.openBlock)(),(0,r.createElementBlock)("div",Le,[(0,r.createElementVNode)("div",Be,(0,r.toDisplayString)((0,r.unref)(l).t("component.resource.detail.metadata.keyValue.noRows",{propertyName:h.value})),1),(0,r.createElementVNode)("div",$e,[(0,r.createElementVNode)("a",{"data-testid":g.value,class:"secondary text-deemphasized",href:"#",onClick:t[0]||(t[0]=e=>{e.preventDefault(),c("show-configuration",b.value)})},(0,r.toDisplayString)((0,r.unref)(l).t("component.resource.detail.metadata.keyValue.showConfiguration")),9,Ve)])])):(0,r.createCommentVNode)("",!0),((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(d.value,e=>((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:m(e),class:"row"},[(0,r.createVNode)(Ne,{class:"rectangle",type:n.type,row:e},null,8,["type","row"])]))),128)),p.value?((0,r.openBlock)(),(0,r.createElementBlock)("a",{key:1,"data-testid":y.value,href:"#",class:"show-all",onClick:t[1]||(t[1]=e=>{e.preventDefault(),c("show-configuration",w.value)})},(0,r.toDisplayString)(f.value),9,Fe)):(0,r.createCommentVNode)("",!0)]))}});n(52339);const Ue=(0,E.A)(je,[["__scopeId","data-v-64f8c824"]]);var Ge=Ue,He=(0,r.defineComponent)({__name:"index",props:{labels:{},onShowConfiguration:{type:Function}},emits:["show-configuration"],setup(e,{emit:t}){const n=e,{labels:i}=(0,r.toRefs)(n),o=t,a=(0,v.Pj)(),s=(0,I.s)(a);return(e,t)=>((0,r.openBlock)(),(0,r.createBlock)(Ge,{propertyName:(0,r.unref)(s).t("component.resource.detail.metadata.labels.title"),rows:(0,r.unref)(i),type:"active",onShowConfiguration:t[0]||(t[0]=e=>o("show-configuration",e,"labels-and-annotations"))},null,8,["propertyName","rows"]))}});const qe=He;var Qe=qe,ze=(0,r.defineComponent)({__name:"index",props:{annotations:{},onShowConfiguration:{type:Function}},emits:["show-configuration"],setup(e,{emit:t}){const n=t,i=(0,v.Pj)(),o=(0,I.s)(i);return(t,i)=>((0,r.openBlock)(),(0,r.createBlock)(Ge,{propertyName:(0,r.unref)(o).t("component.resource.detail.metadata.annotations.title"),rows:e.annotations,type:"active",onShowConfiguration:i[0]||(i[0]=e=>n("show-configuration",e,"labels-and-annotations"))},null,8,["propertyName","rows"]))}});const Ke=ze;var We=Ke;const Xe={class:"spaced-row"};function Ye(e,t){return(0,r.openBlock)(),(0,r.createElementBlock)("div",Xe,[(0,r.renderSlot)(e.$slots,"default",{},void 0,!0)])}n(66592);const Ze={},Je=(0,E.A)(Ze,[["render",Ye],["__scopeId","data-v-be2be6f0"]]);var et=Je;const tt={key:0,class:"identifying-info"},nt={key:1,class:"labels-and-annotations-empty"},rt={key:2,class:"labels"},it={key:3,class:"annotations","data-testid":"resource-detail-annotations"};var ot=(0,r.defineComponent)({__name:"index",props:{resource:{},identifyingInformation:{},labels:{},annotations:{},onShowConfiguration:{type:Function}},emits:["show-configuration"],setup(e,{emit:t}){const n=t,i=(0,v.Pj)(),o=(0,I.s)(i),a=(0,r.computed)(()=>0===e.labels.length&&0===e.annotations.length),s=(0,r.computed)(()=>e.identifyingInformation.length>0);return(t,i)=>((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,null,[(0,r.createVNode)(et,(0,r.mergeProps)({class:"metadata"},t.$attrs),{default:(0,r.withCtx)(()=>[s.value?((0,r.openBlock)(),(0,r.createElementBlock)("div",tt,[(0,r.createVNode)(le,{rows:e.identifyingInformation},null,8,["rows"])])):(0,r.createCommentVNode)("",!0),a.value?((0,r.openBlock)(),(0,r.createElementBlock)("div",nt,[(0,r.createVNode)(Ge,{type:"active",rows:[],propertyName:(0,r.unref)(o).t("component.resource.detail.metadata.labelsAndAnnotations"),onShowConfiguration:i[0]||(i[0]=(e,t)=>n("show-configuration",e,t))},null,8,["propertyName"])])):(0,r.createCommentVNode)("",!0),a.value?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createElementBlock)("div",rt,[(0,r.createVNode)(Qe,{labels:e.labels,onShowConfiguration:i[1]||(i[1]=(e,t)=>n("show-configuration",e,t))},null,8,["labels"])])),a.value?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createElementBlock)("div",it,[(0,r.createVNode)(We,{annotations:e.annotations,onShowConfiguration:i[2]||(i[2]=(e,t)=>n("show-configuration",e,t))},null,8,["annotations"])]))]),_:1},16),(0,r.createVNode)(B.A,{class:"ppb-3",resource:e.resource,type:(0,r.unref)(L.c7).PANEL,location:(0,r.unref)(L.W7).DETAIL_TOP},null,8,["resource","type","location"])],64))}});n(26603);const at=(0,E.A)(ot,[["__scopeId","data-v-74b4d1b7"]]);var st=at;n(24025);var lt=n(2665),ct=(n(1133),n(2841));const ut=(0,r.markRaw)((0,r.defineAsyncComponent)(()=>n.e(411).then(n.bind(n,80411)))),dt=e=>{const t=(0,v.Pj)(),n=(0,I.s)(t),i=(0,r.toValue)(e);if(i.namespace&&!i.namespaces&&!i.isProjectScoped)return(0,r.computed)(()=>{const e=t.getters["currentStore"](m.CU),r=t.getters[`${e}/canList`](m.CU),o=null!==i.namespaceLocation,a=n.t("component.resource.detail.metadata.identifyingInformation.namespace"),s=i.namespace,l="masthead-subheader-namespace",c=r&&o?{component:ut,props:{type:m.CU,id:i.namespace,detailLocation:i.namespaceLocation}}:void 0;return{label:a,value:s,valueDataTestid:l,valueOverride:c}})},ht=e=>{var t;const n=(0,v.Pj)(),i=(0,I.s)(n),o=(0,r.toValue)(e),a=(0,w.lq)(),s=n.getters["productId"]===lt.o_&&!!(null===(t=null===o||void 0===o?void 0:o.metadata)||void 0===t?void 0:t.namespace);if(s)return(0,r.computed)(()=>({label:i.t("component.resource.detail.metadata.identifyingInformation.workspace"),value:o.namespace,to:{name:"c-cluster-product-resource-id",params:{product:n.getters["productId"],cluster:n.getters["clusterId"],resource:m.Hs.WORKSPACE,id:a.params.namespace}}}))},pt=e=>{const t=(0,v.Pj)(),n=(0,I.s)(t),i=(0,r.toValue)(e),o=t.getters["type-map/optionsFor"](e.type);if(o.showAge)return(0,r.computed)(()=>({label:n.t("component.resource.detail.metadata.identifyingInformation.age"),valueOverride:{component:"LiveDate",props:{value:i.creationTimestamp}},value:i.creationTimestamp}))},ft=e=>{const t=(0,v.Pj)(),n=(0,I.s)(t),i=(0,r.toValue)(e);if((e.type===m.CU||e.type===m.bB)&&i.project)return(0,r.computed)(()=>{var e,t;return{label:n.t("component.resource.detail.metadata.identifyingInformation.project"),value:null===(e=i.project)||void 0===e?void 0:e.nameDisplay,valueDataTestid:"masthead-subheader-project",valueOverride:{component:ut,props:{type:m.Mc.PROJECT,id:null===(t=i.project)||void 0===t?void 0:t.id,currentStore:"management"}}}})},mt=e=>{const t=(0,r.computed)(()=>e.details);if(!t.value)return;const n=e=>e.valueOverride?e.valueOverride:e.formatter?{component:e.formatter,props:{value:e.content,...e.formatterOpts}}:void 0;return(0,r.computed)(()=>t.value.filter(e=>!e.separator&&void 0!==e.content&&null!==e.content).map(e=>({label:e.label,value:e.content,valueOverride:n(e)})))};const gt=e=>{const t=(0,r.toValue)(e);return(0,r.computed)(()=>{const e=Object.entries(t.labels||{});return e.map(([e,t])=>({key:e,value:t}))})},vt=e=>{const t=(0,r.toValue)(e);return(0,r.computed)(()=>{const e=Object.entries(t.annotations||{});return e.map(([e,t])=>({key:e,value:t}))})};const bt=e=>{const t=gt(e),n=vt(e),i=X(e);return(0,r.computed)(()=>({resource:(0,r.toValue)(e),labels:t.value,annotations:n.value,onShowConfiguration:i}))},yt=e=>{const t=mt(e),n=ft(e),i=ht(e),o=dt(e),a=pt(e),s=(0,r.computed)(()=>{const e=[null===n||void 0===n?void 0:n.value,null===i||void 0===i?void 0:i.value,null===o||void 0===o?void 0:o.value,null===a||void 0===a?void 0:a.value],r=[...e,...(null===t||void 0===t?void 0:t.value)||[]];return r.filter(e=>"undefined"!==typeof e)}),l=bt(e);return(0,r.computed)(()=>({resource:(0,r.toValue)(e),identifyingInformation:s.value,labels:l.value.labels,annotations:l.value.annotations,onShowConfiguration:l.value.onShowConfiguration}))};var wt=n(47879),Ot=n(28438),St=n(10213),Et=n(86565),xt=n(49845);const _t={class:"message text-deemphasized"};var kt=(0,r.defineComponent)({__name:"ExtrasCard",setup(e){const t=(0,v.Pj)(),n=(0,I.s)(t),i=(0,r.computed)(()=>(0,Et.X2)(t.getters)),o={name:"c-cluster-uiplugins",params:{cluster:St.w}},a=`${xt.M0}/integrations-in-rancher/rancher-extensions`,s={name:"c-cluster-explorer-tools"},l=`${xt.M0}/reference-guides/rancher-cluster-tools`;return(e,t)=>{const c=(0,r.resolveComponent)("router-link");return(0,r.openBlock)(),(0,r.createBlock)(Ot.A,{title:(0,r.unref)(n).t("component.resource.detail.card.extrasCard.title")},{default:(0,r.withCtx)(()=>[(0,r.createElementVNode)("p",_t,[(0,r.createVNode)(wt.A,{k:"component.resource.detail.card.extrasCard.message"},{extensionsLink:(0,r.withCtx)(({content:e})=>[i.value?((0,r.openBlock)(),(0,r.createBlock)(c,{key:0,class:"secondary text-deemphasized",to:o},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e),1)]),_:2},1024)):((0,r.openBlock)(),(0,r.createElementBlock)("a",{key:1,class:"secondary text-deemphasized",href:a,target:"_blank"},(0,r.toDisplayString)(e),1))]),clusterToolsLink:(0,r.withCtx)(({content:e})=>[i.value?((0,r.openBlock)(),(0,r.createBlock)(c,{key:0,class:"secondary-text-link",to:s},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e),1)]),_:2},1024)):((0,r.openBlock)(),(0,r.createElementBlock)("a",{key:1,class:"secondary-text-link",href:l,target:"_blank"},(0,r.toDisplayString)(e),1))]),_:1})])]),_:1},8,["title"])}}});n(4241);const Ct=(0,E.A)(kt,[["__scopeId","data-v-3eb6f915"]]);var At=Ct,Tt=(0,r.defineComponent)({__name:"Cards",props:{resource:{}},setup(e){const t=(0,r.computed)(()=>{var t,n;return(null===(n=null===(t=e.resource)||void 0===t?void 0:t.cards)||void 0===n?void 0:n.filter(e=>e))||[]}),n=(0,r.computed)(()=>t.value.length>=1&&t.value.length<3);return(e,i)=>t.value.length>0?((0,r.openBlock)(),(0,r.createBlock)(et,{key:0},{default:(0,r.withCtx)(()=>[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(t.value,(e,t)=>((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.component),(0,r.mergeProps)({key:t},{ref_for:!0},e.props),null,16))),128)),n.value?((0,r.openBlock)(),(0,r.createBlock)(At,{key:0})):(0,r.createCommentVNode)("",!0)]),_:1})):(0,r.createCommentVNode)("",!0)}});const Rt=Tt;var Nt=Rt,Pt=(0,r.defineComponent)({__name:"latest",props:{value:{default:()=>({})},resourceSubtype:{default:void 0},isCustomDetailOrEdit:{type:Boolean,default:!1}},setup(e){const t=e,n=(0,r.computed)(()=>{const{name:e,metadata:n,kind:r,state:i}=t.value||{};return{name:e,namespace:null===n||void 0===n?void 0:n.namespace,kind:r,state:i}}),i=(0,r.computed)(()=>t.resourceSubtype),o=Y(t.value,i),a=yt(t.value),s=W(t.value),l=(0,v.Pj)();return(e,i)=>{const c=(0,r.resolveDirective)("ui-context");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[(0,r.createVNode)(z,(0,r.normalizeProps)((0,r.guardReactiveProps)((0,r.unref)(o))),null,16),(0,r.unref)(s)?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(b.l),(0,r.mergeProps)({key:0,class:"new state-banner"},(0,r.unref)(s),{role:"status"}),null,16)),[[c,{store:(0,r.unref)(l),icon:"icon-info",hookable:!0,value:{bannerProps:(0,r.unref)(s),resource:n.value},tag:"__details-state-banner",description:"Status Message"}]]):(0,r.createCommentVNode)("",!0),(0,r.createVNode)(st,(0,r.mergeProps)((0,r.unref)(a),{class:"metadata-section"}),null,16),t.isCustomDetailOrEdit?((0,r.openBlock)(),(0,r.createBlock)(Nt,{key:1,class:"cards-section",resource:t.value},null,8,["resource"])):(0,r.createCommentVNode)("",!0)])}}});n(86476);const It=(0,E.A)(Pt,[["__scopeId","data-v-356623d7"]]);var Mt=It;const Dt={class:"masthead"},Lt={class:"title"},Bt={class:"primaryheader"},$t={key:3},Vt={key:4},Ft={key:7,class:"masthead-istio"},jt={class:"icon icon-sm icon-istio"},Ut=["href"],Gt={key:0,class:"subheader"},Ht={key:0},qt={key:1},Qt={key:2},zt={key:1},Kt={key:3},Wt={class:"actions-container align-start"},Xt={class:"actions"},Yt=["disabled"];function Zt(e,t,n,i,o,a){const s=(0,r.resolveComponent)("TabTitle"),l=(0,r.resolveComponent)("router-link"),c=(0,r.resolveComponent)("t"),u=(0,r.resolveComponent)("BadgeState"),d=(0,r.resolveComponent)("LiveDate"),h=(0,r.resolveComponent)("ButtonGroup"),p=(0,r.resolveComponent)("ActionMenu"),f=(0,r.resolveComponent)("ExtensionPanel"),m=(0,r.resolveComponent)("Banner"),g=(0,r.resolveDirective)("clean-tooltip");return(0,r.openBlock)(),(0,r.createElementBlock)("div",Dt,[(0,r.createElementVNode)("header",null,[(0,r.createElementVNode)("div",Lt,[(0,r.createElementVNode)("div",Bt,[(0,r.createElementVNode)("h1",null,[a.isCreate?((0,r.openBlock)(),(0,r.createBlock)(s,{key:0,showChild:!1},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(a.parent.displayName),1)]),_:1})):((0,r.openBlock)(),(0,r.createBlock)(s,{key:1,showChild:!1},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(a.displayName),1)]),_:1})),a.location?((0,r.openBlock)(),(0,r.createBlock)(l,{key:2,to:a.location,role:"link",class:"masthead-resource-list-link","aria-label":a.parent.displayName},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(a.parent.displayName)+": ",1)]),_:1},8,["to","aria-label"])):((0,r.openBlock)(),(0,r.createElementBlock)("span",$t,(0,r.toDisplayString)(a.parent.displayName)+":",1)),n.value?.detailPageHeaderActionOverride&&n.value?.detailPageHeaderActionOverride(n.realMode)?((0,r.openBlock)(),(0,r.createElementBlock)("span",Vt,(0,r.toDisplayString)(n.value?.detailPageHeaderActionOverride(n.realMode)),1)):((0,r.openBlock)(),(0,r.createBlock)(c,{key:5,class:"masthead-resource-title",k:"resourceDetail.header."+n.realMode,subtype:n.resourceSubtype,name:a.displayName,escapehtml:!1},null,8,["k","subtype","name"])),!a.isCreate&&a.parent.showState?((0,r.openBlock)(),(0,r.createBlock)(u,{key:6,class:"masthead-state",value:n.value},null,8,["value"])):(0,r.createCommentVNode)("",!0),!a.isCreate&&n.value.injectionEnabled?((0,r.openBlock)(),(0,r.createElementBlock)("span",Ft,[(0,r.withDirectives)((0,r.createElementVNode)("i",jt,null,512),[[g,e.t("projectNamespaces.isIstioInjectionEnabled")]])])):(0,r.createCommentVNode)("",!0),a.dev&&a.resourceExternalLink?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("a",{key:8,class:"resource-external",rel:"nofollow noopener noreferrer",target:"_blank",href:a.resourceExternalLink.url},[...t[3]||(t[3]=[(0,r.createElementVNode)("i",{class:"icon icon-external-link"},null,-1)])],8,Ut)),[[g,e.t(a.resourceExternalLink.tipsKey||"generic.resourceExternalLinkTips")]]):(0,r.createCommentVNode)("",!0)])]),a.isCreate?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createElementBlock)("div",Gt,[a.isNamespace&&a.project?((0,r.openBlock)(),(0,r.createElementBlock)("span",Ht,[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("resourceDetail.masthead.project"))+": ",1),(0,r.createVNode)(l,{to:a.project.detailLocation},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(a.project.nameDisplay),1)]),_:1},8,["to"])])):a.isWorkspace?((0,r.openBlock)(),(0,r.createElementBlock)("span",qt,[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("resourceDetail.masthead.workspace"))+": ",1),(0,r.createVNode)(l,{to:a.workspaceLocation},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(a.namespace),1)]),_:1},8,["to"])])):a.namespace&&!a.hasMultipleNamespaces?((0,r.openBlock)(),(0,r.createElementBlock)("span",Qt,[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("resourceDetail.masthead.namespace"))+": ",1),a.hideNamespaceLocation?((0,r.openBlock)(),(0,r.createElementBlock)("span",zt,(0,r.toDisplayString)(a.namespace),1)):((0,r.openBlock)(),(0,r.createBlock)(l,{key:0,to:a.namespaceLocation,"data-testid":"masthead-subheader-namespace"},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(a.namespace),1)]),_:1},8,["to"]))])):(0,r.createCommentVNode)("",!0),a.parent.showAge?((0,r.openBlock)(),(0,r.createElementBlock)("span",Kt,[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("resourceDetail.masthead.age"))+": ",1),(0,r.createVNode)(d,{class:"live-date",value:n.value.creationTimestamp},null,8,["value"])])):(0,r.createCommentVNode)("",!0)]))]),(0,r.renderSlot)(e.$slots,"right",{},()=>[(0,r.createElementVNode)("div",Wt,[(0,r.createElementVNode)("div",Xt,[a.detailsAction&&a.currentView===o.DETAIL_VIEW&&a.isView?((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:0,type:"button",class:"btn role-primary actions mr-10",disabled:!a.detailsAction.enabled,onClick:t[0]||(t[0]=(...e)=>a.invokeDetailsAction&&a.invokeDetailsAction(...e))},(0,r.toDisplayString)(a.detailsAction.label),9,Yt)):(0,r.createCommentVNode)("",!0),a.showSensitiveToggle?((0,r.openBlock)(),(0,r.createBlock)(h,{key:1,value:!!a.hideSensitiveData,"icon-size":"lg",options:a.sensitiveOptions,class:"mr-10","onUpdate:value":a.toggleSensitiveData},null,8,["value","options","onUpdate:value"])):(0,r.createCommentVNode)("",!0),a.viewOptions&&a.isView?((0,r.openBlock)(),(0,r.createBlock)(h,{key:2,value:a.currentView,"onUpdate:value":t[1]||(t[1]=e=>a.currentView=e),options:a.viewOptions,class:"mr-10"},null,8,["value","options"])):(0,r.createCommentVNode)("",!0),i.featureDropdownMenu?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:3},[a.isView?((0,r.openBlock)(),(0,r.createBlock)(p,{key:0,"button-variant":"multiAction","button-size":"compact",resource:n.value,"data-testid":"masthead-action-menu"},null,8,["resource"])):(0,r.createCommentVNode)("",!0)],64)):((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:4},[a.isView?((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:0,ref:"actions","data-testid":"masthead-action-menu","aria-haspopup":"true",type:"button",class:"btn role-multi-action actions",onClick:t[2]||(t[2]=(...e)=>a.showActions&&a.showActions(...e))},[...t[4]||(t[4]=[(0,r.createElementVNode)("i",{class:"icon icon-actions"},null,-1)])],512)):(0,r.createCommentVNode)("",!0)],64))])])],!0)]),(0,r.createVNode)(f,{resource:n.value,type:o.extensionType,location:o.extensionLocation},null,8,["resource","type","location"]),a.banner&&a.isView&&!a.parent.hideBanner?((0,r.openBlock)(),(0,r.createBlock)(m,{key:0,class:"state-banner mb-10",color:a.banner.color,label:a.banner.message},null,8,["color","label"])):(0,r.createCommentVNode)("",!0),a.managedWarning.show?((0,r.openBlock)(),(0,r.createBlock)(m,{key:1,color:"warning",class:"mb-20",label:e.t("resourceDetail.masthead.managedWarning",a.managedWarning)},null,8,["label"])):(0,r.createCommentVNode)("",!0),(0,r.renderSlot)(e.$slots,"default",{},void 0,!0)])}var Jt=n(25375),en=n(41418),tn=n(76978),nn=n(41476),rn=n(75886),on={name:"MastheadResourceDetail",components:{BadgeState:en.j,Banner:b.l,ButtonGroup:Jt.A,ExtensionPanel:B.A,TabTitle:D.A,ActionMenu:P.A},props:{value:{type:Object,default:()=>({})},mode:{type:String,default:"create"},realMode:{type:String,default:"create"},as:{type:String,default:f.zD},hasGraph:{type:Boolean,default:!1},hasDetail:{type:Boolean,default:!1},hasEdit:{type:Boolean,default:!1},storeOverride:{type:String,default:null},resource:{type:String,default:null},resourceSubtype:{type:String,default:null},parentRouteOverride:{type:String,default:null},canViewYaml:{type:Boolean,default:!1}},setup(){const e=(0,v.Pj)(),{featureDropdownMenu:t}=(0,rn.K)(e);return{featureDropdownMenu:t}},data(){return{DETAIL_VIEW:f.fS,extensionType:L.c7.PANEL,extensionLocation:L.W7.DETAILS_MASTHEAD}},computed:{dev(){return this.$store.getters["prefs/dev"]},schema(){const e=this.storeOverride||this.$store.getters["currentStore"](this.resource);return this.$store.getters[`${e}/schemaFor`](this.resource)},isView(){return this.mode===f.nW},isEdit(){return this.mode===f.G5},isCreate(){return this.mode===f.YQ},isNamespace(){return this.schema?.id===m.CU},isProject(){return this.schema?.id===m.Mc.PROJECT},isProjectHelmChart(){return this.schema?.id===m.fj.PROJECTHELMCHART},hasMultipleNamespaces(){return!!this.value.namespaces},namespace(){return this.value?.metadata?.namespace?this.value?.metadata?.namespace:null},detailsAction(){return this.value?.detailsAction},shouldHifenize(){return("view"===this.mode||"edit"===this.mode)&&this.resourceSubtype?.length&&this.value?.nameDisplay?.length},namespaceLocation(){return this.isNamespace?null:this.value.namespaceLocation||{name:"c-cluster-product-resource-id",params:{cluster:this.$route.params.cluster,product:this.$store.getters["productId"],resource:m.CU,id:this.$route.params.namespace}}},isWorkspace(){return this.$store.getters["productId"]===lt.o_&&!!this.value?.metadata?.namespace},workspaceLocation(){return{name:"c-cluster-product-resource-id",params:{cluster:this.$route.params.cluster,product:this.$store.getters["productId"],resource:m.Hs.WORKSPACE,id:this.$route.params.namespace}}},project(){if(this.isNamespace){const e=this.$store.getters["currentCluster"];if(e){const t=(this.value?.metadata?.labels||{})[ct.yl];return this.$store.getters["management/byId"](m.Mc.PROJECT,`${e.id}/${t}`)}}return null},banner(){if(this.value?.stateObj?.error){const e=this.t("resourceDetail.masthead.defaultBannerMessage.error",void 0,!0);return{color:"error",message:this.value.stateObj.message||e}}if(this.value?.spec?.paused)return{color:"info",message:this.t("asyncButton.pause.description")};if(this.value?.stateObj?.transitioning){const e=this.t("resourceDetail.masthead.defaultBannerMessage.transitioning",void 0,!0);return{color:"info",message:this.value.stateObj.message||e}}return null},parent(){const e=this.value?.parentNameOverride||this.$store.getters["type-map/labelFor"](this.schema),t=this.$store.getters["currentProduct"].name,n={name:"c-cluster-product-resource",params:{resource:this.resource,product:t}},r=this.value?.parentLocationOverride||n;this.parentRouteOverride&&(r.name=this.parentRouteOverride);const i=this.$store.getters["type-map/optionsFor"](this.resource),o={displayName:e,location:r,...i};return o},hideSensitiveData(){return this.$store.getters["prefs/get"](nn.qv)},sensitiveOptions(){return[{tooltipKey:"resourceDetail.masthead.sensitive.hide",icon:"icon-hide",value:!0},{tooltipKey:"resourceDetail.masthead.sensitive.show",icon:"icon-show",value:!1}]},viewOptions(){const e=[];return this.hasDetail&&e.push({labelKey:"resourceDetail.masthead.detail",value:f.fS}),this.hasEdit&&!1!==this.parent?.showConfigView&&e.push({labelKey:"resourceDetail.masthead.config",value:f.au}),this.hasGraph&&e.push({labelKey:"resourceDetail.masthead.graph",value:f.Yq}),this.canViewYaml&&e.push({labelKey:"resourceDetail.masthead.yaml",value:f.zD}),e.length<2?null:e},currentView:{get(){return this.as},set(e){switch(e){case f.fS:this.$router.applyQuery({[f.g]:f.xz,[f.AS]:f.xz});break;case f.au:this.$router.applyQuery({[f.g]:f.xz,[f.AS]:f.au});break;case f.Yq:this.$router.applyQuery({[f.g]:f.xz,[f.AS]:f.Yq});break;case f.zD:this.$router.applyQuery({[f.g]:f.xz,[f.AS]:f.zD});break}}},showSensitiveToggle(){return!!this.value.hasSensitiveData&&this.mode===f.nW&&this.as!==f.zD},managedWarning(){const{value:e}=this,t=e?.metadata?.labels||{},n=t[ct.pS.MANAGED_BY]||"",r=t[ct.pS.MANAGED_NAME]||t[ct.pS.INSTANCE]||"";return{show:this.mode===f.G5&&!!n,type:e?.kind||"",hasName:r?"yes":"no",appName:r,managedBy:n}},displayName(){let e=this.value.nameDisplay;return this.isProjectHelmChart&&(e=this.value.projectDisplayName),this.shouldHifenize?` - ${e}`:e},location(){const{parent:e}=this;return e?.location},hideNamespaceLocation(){return this.$store.getters["currentProduct"].hideNamespaceLocation||null===this.value.namespaceLocation},resourceExternalLink(){return this.value.resourceExternalLink}},methods:{get:tn.Jt,showActions(){this.$store.commit("action-menu/show",{resources:this.value,elem:this.$refs.actions})},toggleSensitiveData(e){this.$store.dispatch("prefs/set",{key:nn.qv,value:!!e})},invokeDetailsAction(){const e=this.detailsAction;if(e){const t=this.value[e.action];t&&t.apply(this.value,[])}}}};n(60253);const an=(0,E.A)(on,[["render",Zt],["__scopeId","data-v-0f75302f"]]);var sn=an,ln=n(83288),cn=n(2722),un=n.n(cn);const dn=!0,hn=()=>{const e=(0,w.lq)();return(0,r.computed)(()=>{var t,n;const r=(0,v.Pj)(),{fullVersion:i}=(0,ln.hQ)(r),o=un().coerce(i)||{version:"0.0.0"};return!!un().gte(o.version,"2.12.0")&&(dn?"true"!==(null===(t=null===e||void 0===e?void 0:e.query)||void 0===t?void 0:t[f.qx]):"false"===(null===(n=null===e||void 0===e?void 0:e.query)||void 0===n?void 0:n[f.qx]))})};var pn=(0,r.defineComponent)({__name:"index",props:{value:{default:()=>({})},mode:{default:"create"},realMode:{default:"create"},as:{default:f.zD},hasGraph:{type:Boolean,default:!1},hasDetail:{type:Boolean,default:!1},hasEdit:{type:Boolean,default:!1},storeOverride:{default:void 0},resource:{default:void 0},resourceSubtype:{default:void 0},parentRouteOverride:{default:void 0},canViewYaml:{type:Boolean,default:!1}},setup(e){const t=e,n=hn(),i=(0,r.computed)(()=>t.mode===f.nW),o=(0,r.computed)(()=>n.value&&i.value);return(e,n)=>o.value?((0,r.openBlock)(),(0,r.createBlock)(Mt,{key:0,value:t.value,resourceSubtype:t.resourceSubtype,isCustomDetailOrEdit:t.hasDetail||t.hasEdit},null,8,["value","resourceSubtype","isCustomDetailOrEdit"])):((0,r.openBlock)(),(0,r.createBlock)(sn,(0,r.normalizeProps)((0,r.mergeProps)({key:1},t)),{default:(0,r.withCtx)(()=>[(0,r.renderSlot)(e.$slots,"default")]),_:3},16))}});n(53958);const fn=(0,E.A)(pn,[["__scopeId","data-v-7f6314f2"]]);var mn=fn;const gn={key:0,class:"labels"},vn={class:"label"},bn={key:1,class:"description"},yn={class:"label"},wn={class:"content"},On={key:2},Sn={class:"label"},En={key:1},xn={key:3,class:"labels"},_n={class:"tags"},kn={class:"label"},Cn={key:1},An={key:0},Tn={key:2},Rn={key:4,class:"annotations"},Nn={class:"label"},Pn={key:0};function In(e,t,n,i,o,a){const s=(0,r.resolveComponent)("router-link"),l=(0,r.resolveComponent)("Tag"),c=(0,r.resolveComponent)("DetailText"),u=(0,r.resolveComponent)("ExtensionPanel"),d=(0,r.resolveDirective)("clean-tooltip");return(0,r.openBlock)(),(0,r.createElementBlock)("div",{class:(0,r.normalizeClass)(["detail-top",{empty:a.isEmpty}])},[a.hasNamespaces?((0,r.openBlock)(),(0,r.createElementBlock)("div",gn,[(0,r.createElementVNode)("span",vn,(0,r.toDisplayString)(e.t("resourceDetail.detailTop.namespaces"))+": ",1),(0,r.createElementVNode)("span",null,[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(a.namespaces,e=>((0,r.openBlock)(),(0,r.createBlock)(s,{key:e.name,to:e.detailLocation,class:"namespaceLinkList"},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.name),1)]),_:2},1032,["to"]))),128))])])):(0,r.createCommentVNode)("",!0),a.description?((0,r.openBlock)(),(0,r.createElementBlock)("div",bn,[(0,r.createElementVNode)("span",yn,(0,r.toDisplayString)(e.t("resourceDetail.detailTop.description"))+": ",1),(0,r.createElementVNode)("span",wn,(0,r.toDisplayString)(a.description),1)])):(0,r.createCommentVNode)("",!0),a.hasDetails?((0,r.openBlock)(),(0,r.createElementBlock)("div",On,[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(a.details,(e,t)=>((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:t,class:"details"},[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(e,(e,t)=>((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:t,class:"detail"},[(0,r.createElementVNode)("span",Sn,(0,r.toDisplayString)(e.label)+": ",1),e.formatter?((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.formatter),(0,r.mergeProps)({key:0,value:e.content},{ref_for:!0},e.formatterOpts),null,16,["value"])):((0,r.openBlock)(),(0,r.createElementBlock)("span",En,(0,r.toDisplayString)(e.content),1))]))),128))]))),128))])):(0,r.createCommentVNode)("",!0),a.hasLabels?((0,r.openBlock)(),(0,r.createElementBlock)("div",xn,[(0,r.createElementVNode)("div",_n,[(0,r.createElementVNode)("span",kn,(0,r.toDisplayString)(e.t("resourceDetail.detailTop.labels"))+": ",1),((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(a.labels,(e,t)=>((0,r.openBlock)(),(0,r.createBlock)(l,{key:t},{default:(0,r.withCtx)(()=>[a.internalIcons[t]?((0,r.openBlock)(),(0,r.createElementBlock)("i",{key:0,class:(0,r.normalizeClass)(["icon",a.internalIcons[t]])},null,2)):(0,r.createCommentVNode)("",!0),a.internalTooltips[t]?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("span",Cn,[(0,r.createElementVNode)("span",null,(0,r.toDisplayString)(a.internalTooltips[t]?a.internalTooltips[t]:t),1),o.showAllLabels?((0,r.openBlock)(),(0,r.createElementBlock)("span",An,": "+(0,r.toDisplayString)(t),1)):(0,r.createCommentVNode)("",!0)])),[[d,e?`${t} : ${e}`:t]]):((0,r.openBlock)(),(0,r.createElementBlock)("span",Tn,(0,r.toDisplayString)(e?`${t} : ${e}`:t),1))]),_:2},1024))),128)),a.showFilteredSystemLabels?((0,r.openBlock)(),(0,r.createElementBlock)("a",{key:0,href:"#",class:"detail-top__label-button",onClick:t[0]||(t[0]=(0,r.withModifiers)((...e)=>a.toggleLabels&&a.toggleLabels(...e),["prevent"]))},(0,r.toDisplayString)(e.t("resourceDetail.detailTop."+(o.showAllLabels?"hideLabels":"showLabels"))),1)):(0,r.createCommentVNode)("",!0)])])):(0,r.createCommentVNode)("",!0),a.hasAnnotations?((0,r.openBlock)(),(0,r.createElementBlock)("div",Rn,[(0,r.createElementVNode)("span",Nn,(0,r.toDisplayString)(e.t("resourceDetail.detailTop.annotations"))+": ",1),(0,r.createElementVNode)("a",{href:"#",onClick:t[1]||(t[1]=(0,r.withModifiers)((...e)=>a.toggleAnnotations&&a.toggleAnnotations(...e),["prevent"]))},(0,r.toDisplayString)(e.t("resourceDetail.detailTop."+(o.annotationsVisible?"hideAnnotations":"showAnnotations"),{annotations:a.annotationCount})),1),o.annotationsVisible?((0,r.openBlock)(),(0,r.createElementBlock)("div",Pn,[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(a.annotations,(e,t)=>((0,r.openBlock)(),(0,r.createBlock)(c,{key:t,class:"annotation",value:e,label:t},null,8,["value","label"]))),128))])):(0,r.createCommentVNode)("",!0)])):(0,r.createCommentVNode)("",!0),(0,r.createVNode)(u,{resource:n.value,type:o.extensionType,location:o.extensionLocation},null,8,["resource","type","location"])],2)}var Mn=n(8529),Dn=n(3514),Ln=n.n(Dn),Bn=n(14738),$n={components:{DetailText:Bn.A,Tag:Mn.A,ExtensionPanel:B.A},props:{value:{type:Object,default:()=>({})},moreDetails:{type:Array,default:()=>[]},tooltips:{type:Object,default:()=>({})},icons:{type:Object,default:()=>({})}},data(){return{extensionType:L.c7.PANEL,extensionLocation:L.W7.DETAIL_TOP,annotationsVisible:!1,showAllLabels:!1,view:f.nW}},computed:{namespaces(){return(this.value?.namespaces||[]).map(e=>({name:e?.metadata?.name,detailLocation:e.detailLocation}))},details(){const e=[...this.moreDetails||[],...this.value?.details||[]].filter(e=>e.separator||!!`${e.content}`&&void 0!==e.content&&null!==e.content),t=[];let n=[];return e.forEach(e=>{e.separator?(t.push(n),n=[]):n.push(e)}),n.length&&t.push(n),t},labels(){return this.showAllLabels||!this.showFilteredSystemLabels?this.value?.labels||{}:this.value?.filteredSystemLabels},internalTooltips(){return this.value?.detailTopTooltips||this.tooltips},internalIcons(){return this.value?.detailTopIcons||this.icons},annotations(){return this.value?.annotations||{}},description(){return this.value?.description},hasDetails(){return!Ln()(this.details)},hasLabels(){return!Ln()(this.labels)},hasAnnotations(){return!Ln()(this.annotations)},hasDescription(){return!Ln()(this.description)},hasNamespaces(){return!Ln()(this.namespaces)},annotationCount(){return Object.keys(this.annotations||{}).length},isEmpty(){const e=this.hasDetails||this.hasLabels||this.hasAnnotations||this.hasDescription||this.hasNamespaces;return!e},showFilteredSystemLabels(){if(this.value?.labels&&this.value?.filteredSystemLabels){const e=Object.keys(this.value.labels).length,t=Object.keys(this.value.filteredSystemLabels).length;return e!==t}return!1}},methods:{toggleLabels(){this.showAllLabels=!this.showAllLabels},toggleAnnotations(e){this.annotationsVisible=!this.annotationsVisible}}};n(39066);const Vn=(0,E.A)($n,[["render",In]]);var Fn=Vn,jn=n(27542),Un=n(99726),Gn=n(12925),Hn=n(91452),qn=n(4364);function Qn(e){return e.query?.mode===f.HC?f.HC:e.params?.id?e.query.mode||f.nW:f.YQ}async function zn(e,t,n=!1){let r;const i={headers:{accept:"application/yaml"}};return t.hasLink("view")&&(r=(await t.followLink("view",i)).data),t.cleanForDownload(r,{editing:n})}var Kn={emits:["input"],components:{Loading:h.A,DetailTop:Fn,ResourceYaml:p.A,Masthead:mn,IconMessage:jn.A,Banner:b.l,FailWhale:Gn.A},mixins:[d.A],props:{storeOverride:{type:String,default:null},resourceOverride:{type:String,default:null},subTypeOverride:{type:String,default:null},parentRouteOverride:{type:String,default:null},flexContent:{type:Boolean,default:!1},componentTestid:{type:String,default:"resource-details"},errorsMap:{type:Object,default:null}},async fetch(){const e=this.$store,t=this.$route,n=t.params;let r=this.resourceOverride||n.resource;const i=this.storeOverride||e.getters["currentStore"](r),o=this.realMode;let{namespace:a,id:s}=n;const l=[f.dT,f.HC,f.wZ].includes(o)?f.YQ:o,c=this.subTypeOverride||s,u=e.getters["type-map/hasCustomDetail"](r,c),d=e.getters["type-map/hasCustomEdit"](r,c),h=e.getters[`${i}/all`](m.yx),p=t.query[f.AS];let v,b=!1;l!==f.nW||!u||p&&p!==f.fS?v=!d||p&&p!==f.au?f.zD:f.au:(v=f.fS,(0,Hn.L)()),this.as=v;const y=e.getters["type-map/optionsFor"](r);this.showMasthead=![f.YQ,f.G5].includes(l)||y.resourceEditMasthead;let w=y.canYaml;y.resource&&(r=y.resource);const O=e.getters[`${i}/schemaFor`](r);let S,E,x,_;if(!O&&o!==f.YQ&&o!==f.HC)return void(this.resourceNotFoundError=new Error(this.t("nav.failWhale.resourceNotFound",{resource:r},!0)));if(o===f.YQ||o===f.HC){a||(a=e.getters["defaultNamespace"]);const t={type:r};O?.attributes?.namespaced&&(t.metadata={namespace:a}),x=await e.dispatch(`${i}/create`,t),E=await e.dispatch(`${i}/clone`,{resource:x}),S=await e.dispatch(`${i}/clone`,{resource:x}),!0===S.forceYaml&&(v=f.zD,this.as=v),v===f.zD&&(O?.fetchResourceFields&&await O.fetchResourceFields(),_=(0,g.mH)(h,r,t))}else{let t=s;O?.attributes?.namespaced&&a&&(t=`${a}/${t}`);try{x=await e.dispatch(`${i}/find`,{type:r,id:t,opt:{watch:!0}})}catch(C){if(404===C.status||403===C.status)return void(this.resourceNotFoundError=new Error(this.t("nav.failWhale.resourceIdNotFound",{resource:r,fqid:t},!0)));qn.info(`Could not find '${r}' with id '${s}''`,C),x={},b=t}try{w&&!1===x?.canYaml&&(w=!1)}catch(C){w=!1}try{S=o===f.nW?x:await e.dispatch(`${i}/clone`,{resource:x}),E=await e.dispatch(`${i}/clone`,{resource:x}),v===f.zD&&(_=await zn(this.$store,x,o!==f.nW))}catch(C){qn.warn(`Could not set 'model' for '${r}' with id '${s}''`,C),this.errors.push(C)}if(v===f.zD)try{_=await zn(this.$store,x,o!==f.nW)}catch(C){this.errors.push(C)}[f.dT,f.HC,f.wZ].includes(o)&&(S?.cleanForNew(),_=S?.cleanYaml(_,o))}try{S=await e.dispatch(`${i}/cleanForDetail`,S||{})}catch(C){this.errors.push(C)}const k={hasCustomDetail:u,hasCustomEdit:d,canViewYaml:w,resourceType:r,as:v,yaml:_,initialModel:E,liveModel:x,mode:l,value:S,notFound:b};for(const f in k)this[f]=k[f];this.mode===f.YQ&&this.value?.applyDefaults(this,o)},data(){return{resourceSubtype:null,hasCustomDetail:null,hasCustomEdit:null,resourceType:null,asYaml:null,yaml:null,liveModel:null,initialModel:null,mode:null,as:null,value:null,model:null,notFound:null,canViewYaml:null,errors:[],resourceNotFoundError:null}},computed:{realMode(){const e=Qn(this.$route);return e},isView(){return this.mode===f.nW},isYaml(){return this.as===f.zD},isDetail(){return this.as===f.fS},offerPreview(){return this.as===f.zD&&[f.G5,f.dT,f.HC,f.wZ].includes(this.mode)},showComponent(){switch(this.as){case f.fS:return this.detailComponent;case f.au:return this.editComponent}return null},hasErrors(){return this.errors?.length&&Array.isArray(this.errors)},mappedErrors(){return this.errors?this.errorsMap||this.errors.reduce((e,t)=>({...e,[t]:{message:t?.data?.message||t,icon:null}}),{}):{}},isFullPageOverride(){return this.isView&&this.isDetail&&this.value?.fullDetailPageOverride}},watch:{$route(e,t){if(e.name!==t.name)return;const n=(0,tn.o8)(e.query),r=(0,tn.o8)(t.query);delete n[f.$y],delete r[f.$y],this.isView||(delete n[f.AS],delete r[f.AS]);const i=Object.keys((0,tn.Ui)(n,r));(i.includes(f.g)||i.includes(f.AS))&&this.$fetch()},async"value.metadata.resourceVersion"(e,t){this.mode===f.nW&&this.as===f.zD&&e&&t&&e!==t&&(this.yaml=await zn(this.$store,this.liveModel))}},created(){this.configureResource()},methods:{stringify:Un.As,setSubtype(e){this.resourceSubtype=e},keyAction(e){const t=this.liveModel;t?.[e]&&t[e]()},closeError(e){this.errors=this.errors.filter((t,n)=>n!==e)},onYamlError(e){this.errors=[];const t=Array.isArray(e)?e:[e];t.forEach(e=>{-1===this.errors.indexOf(e)&&this.errors.push(e)})},configureResource(e="",t=null){const n=e||this.subTypeOverride||this.$route.params.id,r=t||this.resourceOverride||this.$route.params.resource,i=this.$store.getters["type-map/optionsFor"](r),o=i.resourceDetail||i.resource||r,a=i.resourceEdit||i.resource||r;this.detailComponent=this.$store.getters["type-map/importDetail"](o,n),this.editComponent=this.$store.getters["type-map/importEdit"](a,n)}}};n(32715);const Wn=(0,E.A)(Kn,[["render",u],["__scopeId","data-v-77533c06"]]);var Xn=Wn},74887:function(e,t,n){"use strict";n.d(t,{A:function(){return C}});var r=n(9274);const i={class:"with-subheader"},o={class:"title"},a={class:"m-0"},s={class:"sub-header"},l={class:"actions-container"},c={class:"actions"};function u(e,t,n,u,d,h){const p=(0,r.resolveComponent)("TypeDescription"),f=(0,r.resolveComponent)("TabTitle"),m=(0,r.resolveComponent)("Favorite"),g=(0,r.resolveComponent)("ResourceLoadingIndicator"),v=(0,r.resolveComponent)("RcButton");return(0,r.openBlock)(),(0,r.createElementBlock)("header",i,[(0,r.renderSlot)(e.$slots,"typeDescription",{},()=>[(0,r.createVNode)(p,{resource:n.resource},null,8,["resource"])],!0),(0,r.createElementVNode)("div",o,[(0,r.createElementVNode)("h1",a,[(0,r.createVNode)(f,null,{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(h._typeDisplay),1)]),_:1}),t[0]||(t[0]=(0,r.createTextVNode)()),e.isExplorer&&n.showFavorite?((0,r.openBlock)(),(0,r.createBlock)(m,{key:0,resource:n.favoriteResource||n.resource},null,8,["resource"])):(0,r.createCommentVNode)("",!0)]),n.showIncrementalLoadingIndicator?((0,r.openBlock)(),(0,r.createBlock)(g,{key:0,resources:n.loadResources,indeterminate:n.loadIndeterminate},null,8,["resources","indeterminate"])):(0,r.createCommentVNode)("",!0)]),(0,r.createElementVNode)("div",s,[(0,r.renderSlot)(e.$slots,"subHeader",{},void 0,!0)]),(0,r.createElementVNode)("div",l,[(0,r.renderSlot)(e.$slots,"actions",{},()=>[(0,r.createElementVNode)("div",c,[(0,r.renderSlot)(e.$slots,"extraActions",{},void 0,!0),(0,r.renderSlot)(e.$slots,"createButton",{},()=>[d.hasEditComponent&&h._isCreatable?((0,r.openBlock)(),(0,r.createBlock)(v,{key:0,variant:"primary",size:"large","data-testid":n.componentTestid+"-create",to:h._createLocation},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(h._createButtonlabel),1)]),_:1},8,["data-testid","to"])):h._isYamlCreatable?((0,r.openBlock)(),(0,r.createBlock)(v,{key:1,variant:"primary",size:"large","data-testid":n.componentTestid+"-create-yaml",to:h._yamlCreateLocation},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("resourceList.head.createFromYaml")),1)]),_:1},8,["data-testid","to"])):(0,r.createCommentVNode)("",!0)],!0)])],!0)])])}var d=n(65359);const h=["aria-pressed","aria-label"];function p(e,t,n,i,o,a){return(0,r.openBlock)(),(0,r.createElementBlock)("i",{tabindex:0,"aria-pressed":!!a.isFavorite,class:(0,r.normalizeClass)(["favorite icon",{"icon-star-open":!a.isFavorite,"icon-star":a.isFavorite}]),role:"button","aria-label":a.ariaLabel,onClick:t[0]||(t[0]=(0,r.withModifiers)((...e)=>a.toggle&&a.toggle(...e),["stop","prevent"])),onKeydown:[t[1]||(t[1]=(0,r.withKeys)((0,r.withModifiers)((...e)=>a.toggle&&a.toggle(...e),["prevent"]),["enter"])),t[2]||(t[2]=(0,r.withKeys)((0,r.withModifiers)((...e)=>a.toggle&&a.toggle(...e),["prevent"]),["space"]))]},null,42,h)}var f={props:{resource:{type:String,required:!0}},computed:{isFavorite(){return this.$store.getters["type-map/isFavorite"](this.resource)},ariaLabel(){return this.t("resourceDetail.masthead.ariaLabel."+(this.isFavorite?"unfavoriteAction":"favoriteAction"),{resource:this.resource})}},methods:{toggle(){this.isFavorite?this.$store.dispatch("type-map/removeFavorite",this.resource):this.$store.dispatch("type-map/addFavorite",this.resource)}}},m=(n(54932),n(47433));const g=(0,m.A)(f,[["render",p],["__scopeId","data-v-71b15d4e"]]);var v=g,b=n(89559),y=n(51433),w=n(76978),O=n(14220),S=n(10078),E=n(44453),x=n(22896),_={name:"MastheadResourceList",components:{Favorite:v,RcButton:y.a,TypeDescription:b.A,ResourceLoadingIndicator:E.A,TabTitle:x.A},props:{resource:{type:String,required:!0},favoriteResource:{type:String,default:null},schema:{type:Object,default:null},typeDisplay:{type:String,default:null},isCreatable:{type:Boolean,default:null},isYamlCreatable:{type:Boolean,default:null},createLocation:{type:Object,default:null},yamlCreateLocation:{type:Object,default:null},createButtonLabel:{type:String,default:null},loadResources:{type:Array,default:()=>[]},loadIndeterminate:{type:Boolean,default:!1},showIncrementalLoadingIndicator:{type:Boolean,default:!1},showFavorite:{type:Boolean,default:!0},componentTestid:{type:String,default:"masthead"}},data(){const e={...this.$route.params};let t,n="",r=!1;const i=this.$extension?.getPlugins?.()||{},o=this.$store.getters["productId"];Object.keys(i).forEach(e=>{i[e].productNames.includes(o)&&(n=e)}),(0,S.e)(i[n],o)?(t={name:`${this.$route.name}-create`,params:{...e,product:o}},r=!0):t={name:`${this.$route.name}-create`,params:e};const a=this.$store.getters["type-map/hasCustomEdit"](this.resource),s={name:`${this.$route.name}-create`,params:e,query:{[O.AS]:O.zD}};return{overrideCreateLocationByExtension:r,formRoute:t,yamlRoute:s,hasEditComponent:a}},computed:{get:w.Jt,...(0,d.L8)(["isExplorer","currentCluster"]),resourceName(){return this.schema?this.$store.getters["type-map/labelFor"](this.schema):this.resource},_typeDisplay(){return null!==this.typeDisplay?this.typeDisplay:this.schema?this.$store.getters["type-map/labelFor"](this.schema,99):"?"},_isYamlCreatable(){return null!==this.isYamlCreatable?this.isYamlCreatable:this.schema&&this._isCreatable&&this.$store.getters["type-map/optionsFor"](this.resource).canYaml},_isCreatable(){return null!==this.isCreatable?this.isCreatable:!(this.schema&&this.schema?.collectionMethods&&!this.schema?.collectionMethods.find(e=>["blocked-post","post"].includes(e.toLowerCase())))&&this.$store.getters["type-map/optionsFor"](this.resource).isCreatable},_createLocation(){return this.overrideCreateLocationByExtension?this.formRoute:this.createLocation||this.formRoute},_yamlCreateLocation(){return this.yamlCreateLocation||this.yamlRoute},_createButtonlabel(){const e=this.$store.getters["type-map/optionsFor"](this.resource).listCreateButtonLabelKey;return e?this.t(e):this.createButtonLabel||this.t("resourceList.head.create")}}};n(54200);const k=(0,m.A)(_,[["render",u],["__scopeId","data-v-98e5f4d8"]]);var C=k},44453:function(e,t,n){"use strict";n.d(t,{A:function(){return g}});var r=n(9274);const i={key:0,class:"ml-10 resource-loading-indicator"},o={class:"inner"},a={class:"resource-loader"},s={class:"rl-bg"},l={key:0},c={class:"rl-fg"},u={key:0};function d(e,t,n,d,h,p){return p.count&&!p.haveAll?((0,r.openBlock)(),(0,r.createElementBlock)("div",i,[(0,r.createElementVNode)("div",o,[(0,r.createElementVNode)("div",a,[(0,r.createElementVNode)("div",s,[t[0]||(t[0]=(0,r.createElementVNode)("i",{class:"icon icon-spinner icon-spin"},null,-1)),(0,r.createElementVNode)("span",null,[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("resourceLoadingIndicator.loading"))+" ",1),n.indeterminate?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createElementBlock)("span",l,(0,r.toDisplayString)(p.count)+" / "+(0,r.toDisplayString)(p.total),1))])])]),(0,r.createElementVNode)("div",{class:"resource-loader",style:(0,r.normalizeStyle)({width:p.width})},[(0,r.createElementVNode)("div",c,[t[1]||(t[1]=(0,r.createElementVNode)("i",{class:"icon icon-spinner icon-spin"},null,-1)),(0,r.createElementVNode)("span",null,[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("resourceLoadingIndicator.loading"))+" ",1),n.indeterminate?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createElementBlock)("span",u,(0,r.toDisplayString)(p.count)+" / "+(0,r.toDisplayString)(p.total),1))])])],4)])])):(0,r.createCommentVNode)("",!0)}var h=n(35664),p={name:"ResourceLoadingIndicator",props:{resources:{type:Array,required:!0},indeterminate:{type:Boolean,default:!1}},data(){const e=this.$store.getters["currentStore"](this.resource);return{inStore:e}},computed:{rowsCount(){if(this.resources.length>0){const e=this.$store.getters[`${this.inStore}/all`](this.resources[0])||[];return(e||[]).length}return 0},haveAll(){return this.resources.reduce((e,t)=>e&&this.$store.getters[`${this.inStore}/haveAll`](t),!0)},total(){const e=this.$store.getters[`${this.inStore}/all`](h.i2);return this.resources.reduce((t,n)=>{const r=e?.[0]?.counts?.[n],i=r?.summary?.count,o=i||0;return t+o},0)},count(){return this.resources.reduce((e,t)=>e+(this.$store.getters[`${this.inStore}/all`](t)||[]).length,0)},width(){const e=Math.ceil(this.count/this.total*100);return`${e}%`}}},f=(n(97876),n(47433));const m=(0,f.A)(p,[["render",d],["__scopeId","data-v-6457c305"]]);var g=m},83927:function(e,t,n){"use strict";n.d(t,{A:function(){return _}});var r=n(9274);const i={key:3,class:"outlet"},o={key:1};function a(e,t,n,a,s,l){const c=(0,r.resolveComponent)("FailWhale"),u=(0,r.resolveComponent)("IconMessage"),d=(0,r.resolveComponent)("Masthead"),h=(0,r.resolveComponent)("ExtensionPanel"),p=(0,r.resolveComponent)("ResourceTable");return s.resourceNotFoundError?((0,r.openBlock)(),(0,r.createBlock)(c,{key:0,error:s.resourceNotFoundError,suggestion:s.resourceSuggestion},null,8,["error","suggestion"])):e.namespaceFilterRequired?((0,r.openBlock)(),(0,r.createBlock)(u,{key:1,vertical:!0,subtle:!1,icon:"icon-filter_alt"},{message:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("resourceList.nsFiltering")),1)]),_:1})):e.paginationNsFilterRequired?((0,r.openBlock)(),(0,r.createBlock)(u,{key:2,vertical:!0,subtle:!1,icon:"icon-filter_alt"},{message:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("resourceList.nsFilteringGeneric")),1)]),_:1})):((0,r.openBlock)(),(0,r.createElementBlock)("div",i,[s.showMasthead?((0,r.openBlock)(),(0,r.createBlock)(d,{key:0,"type-display":s.customTypeDisplay,schema:s.schema,resource:s.resource,"show-incremental-loading-indicator":l.showIncrementalLoadingIndicator,"load-resources":s.loadResources,"load-indeterminate":s.loadIndeterminate},{extraActions:(0,r.withCtx)(()=>[(0,r.renderSlot)(e.$slots,"extraActions",{},void 0,!0)]),_:3},8,["type-display","schema","resource","show-incremental-loading-indicator","load-resources","load-indeterminate"])):(0,r.createCommentVNode)("",!0),(0,r.createVNode)(h,{resource:{},type:s.extensionType,location:s.extensionLocation},null,8,["type","location"]),s.hasListComponent?((0,r.openBlock)(),(0,r.createElementBlock)("div",o,[((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.listComponent),(0,r.mergeProps)({"incremental-loading-indicator":l.showIncrementalLoadingIndicator,rows:e.rows},e.$data),null,16,["incremental-loading-indicator","rows"]))])):((0,r.openBlock)(),(0,r.createBlock)(p,{key:2,schema:s.schema,rows:e.rows,"alt-loading":e.canPaginate&&!e.isFirstLoad,loading:e.loading,headers:l.headers,"group-by":l.groupBy,"has-advanced-filtering":n.hasAdvancedFiltering,"adv-filter-hide-labels-as-cols":n.advFilterHideLabelsAsCols,"adv-filter-prevent-filtering-labels":n.advFilterPreventFilteringLabels,"use-query-params-for-simple-filtering":s.useQueryParamsForSimpleFiltering,"force-update-live-and-delayed":e.forceUpdateLiveAndDelayed,"external-pagination-enabled":e.canPaginate,"external-pagination-result":e.paginationResult,"external-pagination-args":e.pagination,"external-pagination-scope":e.paginationScope,onPaginationChanged:e.paginationChanged},null,8,["schema","rows","alt-loading","loading","headers","group-by","has-advanced-filtering","adv-filter-hide-labels-as-cols","adv-filter-prevent-filtering-labels","use-query-params-for-simple-filtering","force-update-live-and-delayed","external-pagination-enabled","external-pagination-result","external-pagination-args","external-pagination-scope","onPaginationChanged"]))]))}var s=n(31085),l=n(58972),c=n(12925),u=n(74887),d=n(44453),h=n(23667),p=n(27542),f=n(90703),m=n(31915),g=n(10312),v=n(68851);function b(e,t){if(e===t)return 0;if(!e.length)return t.length;if(!t.length)return e.length;let n=Array.from({length:t.length+1},(e,t)=>t);for(let r=0;r<e.length;r++){const i=[r+1];for(let o=0;o<t.length;o++){const a=e[r]===t[o]?0:1;i[o+1]=Math.min(i[o]+1,n[o+1]+1,n[o]+a)}n=i}return n[t.length]}function y(e,t,n=3){if(!e)return[];const r=e.toLowerCase(),i=Math.max(2,Math.floor(r.length/4));return t.map(e=>{const t=e.toLowerCase(),n=t.includes(r)||r.includes(t),i=n?0:b(r,t);return{candidate:e,distance:i}}).filter(e=>e.distance<=i).sort((e,t)=>e.distance-t.distance).slice(0,n).map(e=>e.candidate)}var w=n(35664),O=n(10257),S={name:f.v,components:{Loading:l.A,ResourceTable:s.A,FailWhale:c.A,Masthead:u.A,ResourceLoadingIndicator:d.A,IconMessage:p.A,ExtensionPanel:g.A},mixins:[h.A],props:{hasAdvancedFiltering:{type:Boolean,default:!1},advFilterHideLabelsAsCols:{type:Boolean,default:!1},advFilterPreventFilteringLabels:{type:Boolean,default:!1}},async fetch(){const e=this.resource,t=this.schema;if(this.hasListComponent){const t=this.listComponent,n=await t.__asyncLoader();if(n?.typeDisplay&&(this.customTypeDisplay=n.typeDisplay.apply(this)),(n?.fetch||n?.components?.["PaginatedResourceTable"])&&(this.componentWillFetch=!0),n?.$loadingResources){const{loadResources:t,loadIndeterminate:r}=n?.$loadingResources(this.$route,this.$store);this.loadResources=t||[e],this.loadIndeterminate=r||!1}}if(!this.componentWillFetch){if(!t)return this.resourceNotFoundError=new Error(this.t("nav.failWhale.resourceListNotFound",{resource:e},!0)),void(this.resourceSuggestion=this.nearestResourceSuggestion(e));if(this.resourceNotFoundError)return;this.namespaceFilterRequired||this.canPaginate&&!this.refreshFlag||await this.$fetchType(e)}},beforeMount(){if(!this.hasListComponent){const e=this.$store.getters["currentStore"](this.resource),t=this.$store.getters[`${e}/canList`](this.resource);t||(this.resourceNotFoundError=new Error(this.t("nav.failWhale.resourceListNotListable",{resource:this.schema?.id||this.resource||"unknown"},!0)))}},data(){const e=this.$store.getters,t={...this.$route.params},n=t.resource,r=e["type-map/hasCustomList"](n),i=e["currentStore"](n),o=e[`${i}/schemaFor`](n),a=e["type-map/optionsFor"](n).showListMasthead;return{schema:o,resourceNotFoundError:null,resourceSuggestion:null,overrideInStore:void 0,hasListComponent:r,showMasthead:void 0===a||a,resource:n,extensionType:m.c7.PANEL,extensionLocation:m.W7.RESOURCE_LIST,loadResources:[n],componentWillFetch:!1,manualRefreshInit:!1,watch:!1,force:!1,customTypeDisplay:null,loadIndeterminate:!1,useQueryParamsForSimpleFiltering:!0}},computed:{headers(){return this.hasListComponent||!this.schema?[]:this.$store.getters["type-map/headersFor"](this.schema,this.canPaginate)},groupBy(){return this.$store.getters["type-map/groupByFor"](this.schema)},showIncrementalLoadingIndicator(){return O.A.incrementalLoadingUtils.isEnabled(this.calcCanPaginate(),this.perfConfig)}},methods:{nearestResourceSuggestion(e){const t=this.$store.getters["currentStore"](e),n=this.$store.getters[`${t}/all`](w.yx)||[],r=n.map(e=>e.id).filter(Boolean),[i]=y(e,r,1);if(!i)return null;const{href:o}=this.$router.resolve({name:"c-cluster-product-resource",params:{...this.$route.params,resource:i}});return{label:i,url:o}}},watch:{namespaceFilter(e,t){if(e&&!this.componentWillFetch){if((0,v.P1)(e,t))return;this.$fetchType(this.resource)}},pagination(e,t){!e||this.componentWillFetch||this.paginationEqual(e,t)||this.$fetchType(this.resource)},rows(e){this.pagination&&this.pagination.page>1&&0===e.length&&this.setPagination({...this.pagination,page:this.pagination.page-1})}},created(){let e=!1;const t=this.$route.params.resource,n=this.$store.getters["type-map/hasCustomList"](t);n&&(e=this.$store.getters["type-map/importList"](t)),this.listComponent=e}},E=(n(42677),n(47433));const x=(0,E.A)(S,[["render",a],["__scopeId","data-v-77c563ea"]]);var _=x},31085:function(e,t,n){"use strict";n.d(t,{A:function(){return Nn},S:function(){return An}});var r=n(9274);const i={class:"group-tab"},o={key:0,class:"count"};function a(e,t,n,a,s,l){const c=(0,r.resolveComponent)("TableViewTabs"),u=(0,r.resolveComponent)("ButtonGroup"),d=(0,r.resolveComponent)("TableViewControls"),h=(0,r.resolveComponent)("ToggleSwitch"),p=(0,r.resolveComponent)("SortableTable"),f=(0,r.resolveDirective)("clean-html"),m=(0,r.resolveDirective)("shortkey");return(0,r.openBlock)(),(0,r.createBlock)(p,(0,r.mergeProps)({ref:"table"},e.$attrs,{headers:e.viewHeaders,rows:e.viewRows,loading:n.loading||e.viewSwitching,"alt-loading":n.altLoading&&!e.viewSwitching,"group-by":l.computedGroupBy,"group-ref":l.computedGroupRef,"group-sort":e.viewGroupSort,group:l.group,"group-options":l._groupOptions,search:!e.showTableViews&&n.search,"table-views-layout":e.showTableViews,paging:!0,"paging-params":l.parsedPagingParams,"paging-label":n.pagingLabel,"select-all-label":l.selectAllLabel,"rows-per-page":n.rowsPerPage,"row-actions":n.rowActions,"table-actions":l._showBulkActions,"overflow-x":n.overflowX,"overflow-y":n.overflowY,"get-custom-detail-link":n.getCustomDetailLink,"has-advanced-filtering":n.hasAdvancedFiltering,"adv-filter-hide-labels-as-cols":n.advFilterHideLabelsAsCols,"adv-filter-prevent-filtering-labels":n.advFilterPreventFilteringLabels,"key-field":n.keyField,sortGeneration:s.sortGeneration,"sort-generation-fn":l.safeSortGenerationFn,"use-query-params-for-simple-filtering":n.useQueryParamsForSimpleFiltering,"force-update-live-and-delayed":n.forceUpdateLiveAndDelayed,"external-pagination-enabled":n.externalPaginationEnabled,"external-pagination-result":n.externalPaginationResult,"view-filters":e.appliedViewFilters,queried:e.showTableViews&&e.viewTerms.length>0,"view-query":e.showTableViews?e.settledQuery:null,"aria-busy":e.viewBusy?"true":void 0,"mandatory-sort":l._mandatorySort,onClickedActionButton:l.handleActionButtonClick,onGroupValueChange:t[10]||(t[10]=e=>l.group=e),onEnter:l.handleEnterKeyPress,onSortableTableInteraction:l.handleSortableTableInteraction}),(0,r.createSlots)({"group-by":(0,r.withCtx)(({group:e})=>[(0,r.createElementVNode)("div",i,[(0,r.withDirectives)((0,r.createElementVNode)("span",null,null,512),[[f,e.ref]]),l.showNamespaceCounts&&Number.isInteger(l.namespaceCounts[e.rows?.[0]?.metadata?.namespace]?.count)?((0,r.openBlock)(),(0,r.createElementBlock)("span",o," ("+(0,r.toDisplayString)(l.namespaceCounts[e.rows?.[0]?.metadata?.namespace]?.count)+") ",1)):(0,r.createCommentVNode)("",!0)])]),shortkeys:(0,r.withCtx)(()=>[e.showTableViewTabs?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:0},[(0,r.withDirectives)((0,r.createElementVNode)("button",{class:"hide",onShortkey:t[3]||(t[3]=e=>l.tableViewShortcut("saveChanges"))},null,544),[[m,{windows:["ctrl","s"],mac:["meta","s"]},void 0,{anywhere:!0}]]),(0,r.withDirectives)((0,r.createElementVNode)("button",{class:"hide",onShortkey:t[4]||(t[4]=e=>l.tableViewShortcut("openSaveAsNew"))},null,544),[[m,{windows:["ctrl","shift","s"],mac:["meta","shift","s"]},void 0,{anywhere:!0}]]),(0,r.withDirectives)((0,r.createElementVNode)("button",{class:"hide",onShortkey:t[5]||(t[5]=e=>l.tableViewShortcut("duplicateCurrent"))},null,544),[[m,{windows:["ctrl","d"],mac:["meta","d"]},void 0,{anywhere:!0}]])],64)):(0,r.createCommentVNode)("",!0),l._showBulkActions?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:1,class:"hide",onShortkey:t[6]||(t[6]=e=>l.keyAction("edit"))},null,544)),[[m,["e"],void 0,{once:!0}]]):(0,r.createCommentVNode)("",!0),l._showBulkActions?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:2,class:"hide",onShortkey:t[7]||(t[7]=e=>l.keyAction("yaml"))},null,544)),[[m,["y"],void 0,{once:!0}]]):(0,r.createCommentVNode)("",!0),l._showBulkActions?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:3,class:"hide",onShortkey:t[8]||(t[8]=e=>l.keyAction("remove"))},null,544)),[[m,["del"],void 0,{once:!0}]]):(0,r.createCommentVNode)("",!0),l._showBulkActions?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:4,class:"hide",onShortkey:t[9]||(t[9]=e=>l.keyAction("remove"))},null,544)),[[m,["backspace"],void 0,{once:!0}]]):(0,r.createCommentVNode)("",!0)]),_:2},[e.showTableViewTabs?{name:"table-views",fn:(0,r.withCtx)(()=>[(0,r.createVNode)(c,{view:e.view,"view-counts":e.tabCounts,"match-count":e.viewMatchCount,"resource-type":n.schema?n.schema.id:"","table-views-page":e.tableViewsPage,"initial-view-id":e.openedViewId,"onUpdate:view":e.openTabView,onTabQueries:t[0]||(t[0]=t=>e.tabQueries=t),onExport:e.handleExport},null,8,["view","view-counts","match-count","resource-type","table-views-page","initial-view-id","onUpdate:view","onExport"])]),key:"0"}:void 0,l.showGrouping&&l._groupOptions.length>1&&!e.showTableViews?{name:"header-middle",fn:(0,r.withCtx)(()=>[(0,r.renderSlot)(e.$slots,"more-header-middle",{},void 0,!0),(0,r.createVNode)(u,{value:l.group,"onUpdate:value":t[1]||(t[1]=e=>l.group=e),options:l._groupOptions,size:"medium"},null,8,["value","options"])]),key:"1"}:void 0,l.showGrouping||e.showTableViews?{name:"header-right",fn:(0,r.withCtx)(()=>[e.showTableViews?((0,r.openBlock)(),(0,r.createBlock)(d,{key:0,view:e.view,fields:e.viewQueryFields,"group-fields":e.viewGroupFields,"default-group-by":l.defaultGroupBy,"filter-fields":e.viewFilterFields,"date-fields":e.viewDateFieldIds,"field-values":e.viewFieldValues,"pending-fields":e.viewPendingFields,"loading-values":e.fieldValuesLoading,rows:l.filteredRows,"unsupported-fields":e.unsupportedViewFields,"default-columns":e.defaultColumnIds,"core-columns":e.coreColumnIds,"onUpdate:view":t[2]||(t[2]=t=>e.view=t),onRequestValues:e.fetchFieldValues,onRefreshValues:e.refreshFieldValues},null,8,["view","fields","group-fields","default-group-by","filter-fields","date-fields","field-values","pending-fields","loading-values","rows","unsupported-fields","default-columns","core-columns","onRequestValues","onRefreshValues"])):(0,r.createCommentVNode)("",!0),(0,r.renderSlot)(e.$slots,"header-right",{},void 0,!0)]),key:"2"}:void 0,n.externalPaginationEnabled?{name:"watch-controls",fn:(0,r.withCtx)(()=>[s.listAutoRefreshToggleEnabled?((0,r.openBlock)(),(0,r.createBlock)(h,{key:0,class:"auto-update",value:e.watching,name:"label-system-toggle","on-label":e.t("resourceTable.autoRefresh.label"),"onUpdate:value":e.toggleWatch},null,8,["value","on-label","onUpdate:value"])):(0,r.createCommentVNode)("",!0)]),key:"3"}:void 0,(0,r.renderList)(e.passthroughSlots,(t,n)=>({name:n,fn:(0,r.withCtx)(t=>[(0,r.renderSlot)(e.$slots,n,(0,r.normalizeProps)((0,r.guardReactiveProps)(t)),void 0,!0)])}))]),1040,["headers","rows","loading","alt-loading","group-by","group-ref","group-sort","group","group-options","search","table-views-layout","paging-params","paging-label","select-all-label","rows-per-page","row-actions","table-actions","overflow-x","overflow-y","get-custom-detail-link","has-advanced-filtering","adv-filter-hide-labels-as-cols","adv-filter-prevent-filtering-labels","key-field","sortGeneration","sort-generation-fn","use-query-params-for-simple-filtering","force-update-live-and-delayed","external-pagination-enabled","external-pagination-result","view-filters","queried","view-query","aria-busy","mandatory-sort","onClickedActionButton","onEnter","onSortableTableInteraction"])}var s=n(65359),l=n(76978),c=n(41476),u=n(25375),d=n(33246),h=n(68774),p=n(35664),f=n(68851),m=n(31915),g=n(25659),v=n(13003),b=n(20477),y=n(12784),w=n.n(y),O=n(57699),S=n(95265);function E(e){const t=e.rootGetters||e.getters;return t["features/get"](S.E8)}const x={header:h.EY,paginationHeader:O.YI,before:"age"},_=[p.Mc.CLUSTER,p.Z7.RANCHER_CLUSTER,p.K5,p.bB,p.YV,p.Sg,p.NW,p.CU,p.PV,p.YH,p.fJ,p.wN,p.wT,p.kf,p.UR,p.oU.DEPLOYMENT,p.oU.STATEFUL_SET,p.oU.DAEMON_SET,p.oU.JOB,p.oU.CRON_JOB,p.Sm,p.Hs.GIT_REPO,p.Hs.HELM_OP,p.Hs.CLUSTER,p.Hs.CLUSTER_GROUP,p.Hs.POLICY,p.Hs.WORKSPACE,p.W8.CLUSTER_REPO,p.AQ.BACKUP,p.cm.FLOW,p.cm.CLUSTER_FLOW,p.cm.OUTPUT,p.cm.CLUSTER_OUTPUT,p.Rp.ALERTMANAGERCONFIG,p.Rp.PROMETHEUSRULE],k={[p.Mc.CLUSTER]:[{header:h.W6,paginationHeader:O.y4,before:"machines"},{header:h.vd,paginationHeader:O.$9,before:"machines"},{header:h.KF,paginationHeader:O.kW,before:"machines"},{header:h.Go,paginationHeader:O.o7,enabled:e=>E(e),before:"machines"},{header:h.C6,paginationHeader:O.UD},{header:h.K,paginationHeader:O.tm}],[p.Hs.GIT_REPO]:[{header:h.dn}]};function C(e,t,n=!1){const r=k[e];return(null===r||void 0===r?void 0:r.length)?r.filter(e=>!e.enabled||e.enabled(t)).map(e=>{const t=n&&e.paginationHeader?e.paginationHeader:e.header;return e.before?{...t,insertBefore:e.before}:t}):[]}_.forEach(e=>{k[e]=(k[e]||[]).concat([x])});var A=n(81268),T=n(51173),R=n(6198),N=n(20138);function P(e,t){const n=[(0,b.ag)(e,t),(0,b.Ex)(e,t)];return t.id===h.c4.name&&n.push(e.state),n}function I(e,t,n){const r=t.isDate?b.MK:b.ng,i=P(e,t).map(e=>r(e).toLowerCase());return i.some(e=>t.exact?e===n:e.includes(n))}function M(e,t,n){const r=t.value.toLowerCase();if(t.field){const i=(0,b.UI)(n,t.field);return!i||I(e,i,r)}return n.some(t=>!t.queryOnly&&!t.notInFreeText&&I(e,t,r))}function D(e,t,n){const r={},i=[];t.forEach(e=>{if(e.negated)i.push(e);else{const t=e.field||"__text__";r[t]=r[t]||[],r[t].push(e)}});for(const o of Object.values(r))if(!o.some(t=>M(e,t,n)))return!1;for(const o of i)if(M(e,o,n))return!1;return!0}function L(e,t,n){const r=(null===t||void 0===t?void 0:t.clauses)||[];return r.length?e.filter(e=>r.some(t=>t.groups.every(t=>D(e,t,n)))):e}const B=["and","or"],$=["not"];function V(e){return!!e&&B.includes(e.toLowerCase())}function F(e){return!!e&&$.includes(e.toLowerCase())}function j(e){return!!e&&"or"===e.toLowerCase()}function U(e){const t=[],n=e||"";let r=0;while(r<n.length){while(r<n.length&&" "===n[r])r++;if(r>=n.length)break;const e=r;let i=null;while(r<n.length){const e=n[r];if(i)e===i&&(i=null);else if('"'===e||"'"===e)i=e;else if(" "===e)break;r++}t.push({start:e,end:r,text:n.substring(e,r)})}return t}function G(e){return e.length>1&&('"'===e[0]||"'"===e[0])&&e[e.length-1]===e[0]?e.substring(1,e.length-1):e}function H(e){return/[\s:]/.test(e)?`"${e}"`:e}function q(e){const t=(Array.isArray(e)?e:[e]).flatMap(e=>"string"===typeof e?e.split(","):[]).map(e=>e.trim()).filter(Boolean);return Array.from(new Set(t)).map(e=>`state:${H(e)}`).join(" ")}function Q(e,t){const n=e.indexOf(":");if(n<=0)return null;const r=(0,b.UI)(t,e.substring(0,n));return r||(e.toLowerCase().startsWith(b.Bb)&&(0,b.UI)(t,e.substring(0,e.lastIndexOf(":")))||null)}function z(e,t){const n=U(e||""),r=[];let i=!1;for(let o=0;o<n.length;o++){const e=n[o];let a=e.text;if(V(a)){r.push({...e,kind:"connective",negate:"",negated:!1,field:null,fieldText:"",value:a,valueStart:e.start});continue}if(F(a)){i=!0,r.push({...e,kind:"connective",negate:"",negated:!1,field:null,fieldText:"",value:a,valueStart:e.start});continue}let s="";(a.startsWith("-")||a.startsWith("!"))&&(s=a.substring(0,1),a=a.substring(1));const l=!!s||i;i=!1;const c=Q(a,t);if(!c){r.push({...e,kind:"term",negate:s,negated:l,field:null,fieldText:"",value:G(a),valueStart:e.start+s.length});continue}const u=a.substring(c.id.length+1);r.push({start:e.start,end:e.end,text:e.text,kind:"term",negate:s,negated:l,field:c,fieldText:a.substring(0,c.id.length),value:G(u),valueStart:e.start+s.length+c.id.length+1})}return r}function K(e,t,n){const r=e||"",i=[];let o=0;const a=e=>{e>o&&(i.push({text:r.substring(o,e),kind:"plain"}),o=e)};return z(r,t).forEach(e=>{if(a(e.start),"connective"===e.kind)return i.push({text:e.text,kind:"connective"}),void(o=e.end);if(!e.field)return i.push({text:e.text,kind:"text"}),void(o=e.end);if(i.push({text:r.substring(e.start,e.start+e.negate.length+e.fieldText.length+1),kind:"field"}),o=e.start+e.negate.length+e.fieldText.length+1,a(e.valueStart),e.end>o){const t=!n||n(e.field.id,e.value);i.push({text:r.substring(o,e.end),kind:t?"value":"value-unknown"}),o=e.end}}),a(r.length),i}function W(e,t){return z(e,t).filter(e=>"term"===e.kind&&!!e.value).map(e=>({field:e.field?e.field.id:null,value:e.value,negated:e.negated}))}function X(e){let t=null;for(const n of e||"")t?n===t&&(t=null):'"'!==n&&"'"!==n||(t=n);return!!t}function Y(e,t){const n=z(e||"",t),r=[];if(!n.length)return r;const i=(e,t,n)=>{r.push({kind:e,start:t.start,end:t.end,text:t.text,label:n})},o=n.some(e=>"term"===e.kind&&!!e.value),a=n.find(e=>"connective"===e.kind);return!o&&a?(i("noTerms",a),r):(n.forEach((e,t)=>{var r;if("connective"===e.kind)return 0===t&&V(e.text)&&i("leadingJoiner",e),t===n.length-1&&i("trailingOperator",e),void(V(e.text)&&"connective"===(null===(r=n[t-1])||void 0===r?void 0:r.kind)&&i("consecutiveOperators",e));X(e.text)?i("unbalancedQuote",e):e.value||(e.field?i("emptyValue",e,e.field.label||e.field.id):e.negate&&i("danglingNegation",e))}),r)}function Z(e,t){const n=[];let r=[],i=[];const o=()=>{i.length&&(r.push(i),i=[])},a=()=>{o(),r.length&&(n.push({groups:r}),r=[])};return z(e||"",t).forEach(e=>{if("connective"!==e.kind)e.value&&i.push({field:e.field?e.field.id:null,value:e.value,negated:e.negated});else{if(F(e.text))return;j(e.text)?a():o()}}),a(),{clauses:n}}function J(e,t,n,r){if(t)return`${e.substring(0,t.start)}${n}${e.substring(t.end)}`;if("number"===typeof r){const t=Math.max(0,Math.min(r,e.length)),i=e.substring(0,t),o=!i||i.endsWith(" ")?i:`${i} `;return`${o}${n}${e.substring(t)}`}const i=e&&!e.endsWith(" ")?`${e} `:e||"";return`${i}${n}`}function ee(e,t,n){const r=n?z(e,n).filter(e=>"term"===e.kind):U(e);return r.find(e=>t>=e.start&&t<=e.end)||null}var te=n(50025);function ne(e,t){const n=[],r=[];if(!e||!e.length)return{filters:n,unsupported:r};const i=e=>{const n=(0,b.UI)(t,e);if(!n)return null;const r=(0,b.WA)(n);if(!r)return null;const i=(Array.isArray(r)?r:[r]).filter(e=>"string"===typeof e);return i.length?i:null},o=[],a={};t.forEach(e=>{var t;if(e.isLabel||e.queryOnly||e.notInFreeText||!1===(null===(t=e.paginationHeader)||void 0===t?void 0:t.search))return;const n=(0,b.WA)(e);n&&(Array.isArray(n)?n:[n]).forEach(e=>{"string"!==typeof e||a[e]||(a[e]=!0,o.push(e))})});const s={},l=[],c=[];return e.forEach(e=>{if(null===e.field||void 0===e.field)return void c.push(e);const t=`${e.negated?"!":""}${e.field}`;s[t]||(s[t]=[],l.push(t)),s[t].push(e)}),l.forEach(e=>{var o;const a=s[e],{negated:l}=a[0],c=a[0].field,u=i(c);if(!u)return void r.push(...a);const d=a.map(e=>e.value);if(null===(o=(0,b.UI)(t,c))||void 0===o?void 0:o.exact){const e=d.join(",");return void(l?u.forEach(t=>n.push(new te.eY({fields:[new te.Js({field:t,value:e,equality:te.D0.NOT_IN})]}))):n.push(new te.eY({fields:u.map(t=>new te.Js({field:t,value:e,equality:te.D0.IN}))})))}if(l)d.forEach(e=>{u.forEach(t=>{n.push(new te.eY({fields:[new te.Js({field:t,value:e,equality:te.D0.NOT_CONTAINS})]}))})});else{const e=[];d.forEach(t=>{u.forEach(n=>{e.push(new te.Js({field:n,value:t,equality:te.D0.CONTAINS}))})}),n.push(new te.eY({fields:e}))}}),c.forEach(e=>{o.length?e.negated?o.forEach(t=>{n.push(new te.eY({fields:[new te.Js({field:t,value:e.value,equality:te.D0.NOT_CONTAINS})]}))}):n.push(new te.eY({fields:o.map(t=>new te.Js({field:t,value:e.value,equality:te.D0.CONTAINS}))})):r.push(e)}),{filters:n,unsupported:r}}const re=16;function ie(e){return((null===e||void 0===e?void 0:e.clauses)||[]).reduce((e,t)=>e.concat(...t.groups),[])}function oe(e,t){const n=(null===e||void 0===e?void 0:e.clauses)||[];if(!n.length)return{filters:[],unsupported:[]};const r=[],i=n.map(e=>{const n=[];return e.groups.forEach(e=>{const i=ne(e,t);n.push(...i.filters),r.push(...i.unsupported)}),n});if(1===i.length)return{filters:i[0],unsupported:r};if(i.some(e=>!e.length))return{filters:[],unsupported:ie(e)};if(i.reduce((e,t)=>e*t.length,1)>re)return{filters:[],unsupported:ie(e)};let o=[[]];return i.forEach(e=>{const t=[];o.forEach(n=>{e.forEach(e=>t.push(n.concat(e.fields||[])))}),o=t}),{filters:o.map(e=>new te.eY({fields:e})),unsupported:r}}function ae(e,t){const n=t.filter(e=>"function"===typeof e.expand);if(!n.length)return e;const r=e=>{const t=[],r=[];return e.forEach(i=>{const o=i.field?n.find(e=>e.id===i.field):void 0;(null===o||void 0===o?void 0:o.expand)?r.includes(o.id)||(r.push(o.id),t.push(...o.expand(e.filter(e=>e.field===o.id)))):t.push(i)}),t};return{clauses:((null===e||void 0===e?void 0:e.clauses)||[]).map(e=>({groups:e.groups.map(r)}))}}const se=400;var le=n(14220),ce=n(20284),ue=n(74302),de=n(46343),he=n.n(de);const pe="none",fe=1;function me(e){if(!e||"object"!==typeof e)return{};const t=e;return t.metadata&&"object"===typeof t.metadata&&"payload"in t?t.payload||{}:e}function ge(e,t){const n={version:fe};return t&&(n.persistenceId=t),{metadata:n,payload:e}}function ve(e){var t;const n=null===(t=null===e||void 0===e?void 0:e.metadata)||void 0===t?void 0:t.persistenceId;return"string"===typeof n&&n?n:null}const be={query:"",groupBy:null,sort:null,sortDescending:!1,columns:null,columnOrder:null,labelColumns:[]};function ye(e){const t={};return Object.keys(be).forEach(n=>{var r;t[n]=null!==(r=e[n])&&void 0!==r?r:be[n]}),t}function we(e,t){return he()(ye(e),ye(t))}function Oe(e){var t;return!!e.query||!!e.groupBy||!!e.columns||!!(null===(t=e.labelColumns)||void 0===t?void 0:t.length)||!!e.columnOrder||!!e.sort}function Se(e,t){var n;return(null===(n=e.find(e=>we(e,t)))||void 0===n?void 0:n.id)||null}function Ee(e,t,n){var r;return void 0!==n?null===n?null:(null===(r=e.find(e=>e.id===n))||void 0===r?void 0:r.id)||Se(e,t):Oe(t)?Se(e,t):null}function xe(e,t,n){const r=n?e.find(e=>e.id===n):null;return r?!we(r,t):(null===n||!Se(e,t))&&Oe(t)}function _e(e,t,n){const r=[...e];return t<0||n<0||t>=r.length||t===n||r.splice(n,0,...r.splice(t,1)),r}var ke=n(4364);const Ce=5e4,Ae=1e4,Te=1e3,Re=8e3,Ne=2e3,Pe="group:",Ie="month:";function Me(e){let t;try{t=me(e.$store.getters["prefs/get"](c.u1))[e.schema?.id]}catch{return}const n=Array.isArray(t)?{views:t}:t;return e.tableViewsPage?n?.pages?.[e.tableViewsPage]:n}function De(e){return null!==e.tableViewTabs&&void 0!==e.tableViewTabs?e.tableViewTabs:null!==e.providedShowTableViewTabs&&void 0!==e.providedShowTableViewTabs?e.providedShowTableViewTabs:!e.$route?.params?.id}var Le={inject:{providedShowTableViewTabs:{from:"showTableViewTabs",default:null},providedTableViewsShell:{from:A.lt,default:null}},props:{tableViewTabs:{type:Boolean,default:null},tableViews:{type:Boolean,default:null},tableViewsPage:{type:String,default:null},queryFields:{type:Array,default:()=>[]}},data(){const e=Me(this),t=De(this)&&(0,A.Q_)(this.$store)?q(this.$route?.query?.[le.GH]):"",n=De(this)&&!t?(e?.views||[]).find(t=>t.id===e?.defaultViewId):void 0;return{openedViewId:t?null:n?.id,stateLinkPending:!!t,stateLinkQuery:t,fieldValues:{},fieldValuesLoading:[],fieldValuesRefreshing:[],fieldValuesAt:{},viewCounts:{},countingInFlight:!1,view:{query:t||n?.query||"",columns:n?.columns||null,columnOrder:n?.columnOrder||null,labelColumns:n?.labelColumns||[],groupBy:n?.groupBy||null,sort:n?.sort||null,sortDescending:n?.sortDescending||!1},defaultSort:null,tabQueries:[],settledQuery:t||n?.query||"",debouncedSettleQuery:w()(function(e){this.settledQuery=e},se),appliedViewFilters:[],lastViewFiltersKey:"[]",viewSwitching:!1,viewSwitchTimer:null,viewSwitchFromArgs:null,pendingViewFilters:[],supersededViewFilters:[],debouncedFetchViewCounts:w()(()=>this.fetchViewCounts(),800),debouncedRefreshViewCounts:w()(()=>this.fetchViewCounts(!0),400)}},mounted(){this.showTableViews&&this.debouncedFetchViewCounts()},beforeUnmount(){clearTimeout(this.viewSwitchTimer),this.debouncedSettleQuery.cancel()},watch:{summaryBaseUrl(e,t){if(e===t)return;const n=Object.keys(this.fieldValues);this.fieldValues={},n.forEach(e=>this.fetchFieldValues(e))},viewCountsKey(){this.debouncedFetchViewCounts()},queryFieldsKey(e,t){if(e===t)return;this.fetchViewCounts(!0);const n=(this.queryFields||[]).filter(e=>void 0!==this.fieldValues[e.id]);if(!n.length)return;const r={...this.fieldValues};n.forEach(e=>delete r[e.id]),this.fieldValues=r,n.forEach(e=>this.fetchFieldValues(e.id))},viewCountsScope(){this.debouncedRefreshViewCounts()},"serverViewFilters.filters"(e){if(!this.serverSideTableViews)return;const t=e||[],n=JSON.stringify(t);n!==this.lastViewFiltersKey&&(this.supersededViewFilters=this.pendingViewFilters,this.pendingViewFilters=t,this.lastViewFiltersKey=n,this.beginViewSwitch(),this.appliedViewFilters=t.length?t:[])},"view.query"(e,t){const n=e||"",r=t||"";if(this.stateLinkPending&&n!==this.stateLinkQuery&&this.dropStateLink(),n===(this.settledQuery||""))return void this.debouncedSettleQuery.cancel();const i=n.startsWith(r)||r.startsWith(n);this.debouncedSettleQuery(n),i&&n||this.debouncedSettleQuery.flush()},viewGroupSort(e,t){this.serverSideTableViews&&e!==t&&this.beginViewSwitch()},"view.sort"(){this.$nextTick(()=>this.applyViewSort())},"view.sortDescending"(){this.$nextTick(()=>this.applyViewSort())},viewHeaders(){this.$nextTick(()=>this.applyViewSort())},externalPaginationResult(){this.viewFiltersApplied&&this.externalPaginationArgs!==this.viewSwitchFromArgs&&this.endViewSwitch()},externalPaginationArgs(e){this.viewSwitching&&e!==this.viewSwitchFromArgs&&this.viewFiltersApplied&&JSON.stringify(e)===JSON.stringify(this.viewSwitchFromArgs)&&this.endViewSwitch()}},computed:{showTableViews(){return!!(0,A.Q_)(this.$store)&&(null!==this.tableViews?this.tableViews:!this.inExtension&&(!!this.schema?.id&&!this.hasAdvancedFiltering))},inExtension(){return(0,A.o6)({providedShell:this.providedTableViewsShell,route:this.$route,extensions:this.$store?.state?.$extension})},showTableViewTabs(){return null!==this.tableViewTabs?this.tableViewTabs:this.showTableViews&&De(this)},availableHeaders(){const e=this._headers||[];if(!this.schema)return e;const t={};e.forEach(e=>{t[(0,b.vv)(e)]=!0});const n=C(this.schema.id,this.$store,this.externalPaginationEnabled).filter(e=>{const n=(0,b.vv)(e);return!(0,b.hn)(e)&&!t[n]&&(t[n]=!0,!0)});if(!n.length)return e;let r=e.length;for(let s=e.length-1;s>=0;s--)if(!(0,b.hn)(e[s])){r=s+1;break}const i=n.filter(e=>!e.insertBefore),o=e.slice(0,r).concat(i,e.slice(r));let a=r+i.length;return n.filter(e=>e.insertBefore).forEach(e=>{const t=o.findIndex(t=>t.name===e.insertBefore);o.splice(t>=0?t:a++,0,e)}),o},defaultColumnIds(){return(this._headers||[]).filter(e=>!(0,b.hn)(e)).map(e=>(0,b.vv)(e))},defaultSortColumnId(){const e=(this._headers||[]).find(e=>e.defaultSort);return e?(0,b.vv)(e):null},coreColumnIds(){return(0,b.bK)(this.defaultColumnIds,this.defaultSortColumnId)},paginationHeaders(){return this.externalPaginationEnabled&&this.schema?this.$store.getters["type-map/headersFor"](this.schema,!0).concat(C(this.schema.id,this.$store,!0)):null},viewFields(){return(0,b.VV)(this.availableHeaders,this.filteredRows,e=>this.t(e),this.paginationHeaders)},viewQueryFields(){const e=new Set((this.viewHeaders||[]).map(e=>(0,b.vv)(e))),t=this.viewFields.map(t=>t.header?.freeTextWhenShown&&!e.has(t.id)?{...t,notInFreeText:!0}:t);return this.queryFields?.length?t.concat(this.queryFields):t},viewFieldValues(){const e=this.serverSideTableViews?[]:(this.queryFields||[]).filter(e=>e.values);return e.length?e.reduce((e,t)=>({...e,[t.id]:t.values}),{...this.fieldValues}):this.fieldValues},viewPendingFields(){const e=this.viewTerms.map(e=>e.field).filter(Boolean);return this.loading?e:e.filter(e=>this.fieldValuesLoading.includes(e))},queryFieldsKey(){return JSON.stringify((this.queryFields||[]).filter(e=>e.values&&e.expand).map(e=>e.values.map(({value:t})=>e.expand([{field:e.id,value:t,negated:!1}]))))},passthroughSlots(){const{"header-right":e,...t}=this.$slots;return this.viewGroupField&&delete t["group-by"],this.showGrouping||this.showTableViews?t:this.$slots},viewGroupFields(){const e=this.tableGroupings.map(e=>({id:`${Pe}${e.value}`,label:this.tableGroupingLabel(e),isLabel:!1})),t=this.tableGroupings.flatMap(e=>[e.hideColumn,e.field]).filter(Boolean),n=new Set(this.viewSortableFields.filter(e=>e.isLabel||!(t.includes(e.header?.name)||t.includes(e.header?.value)))),r=new Set(this.viewDateFields);return e.concat(this.viewFields.filter(e=>n.has(e)||r.has(e)).map(e=>r.has(e)?this.monthGrouping(e):e))},viewSortableFields(){return this.viewFields.filter(e=>{if(e.isLabel)return!0;const{header:t}=e;return!(!t?.sort||e.isDate||this.serverSideTableViews&&!(0,b.WA)(e))&&("function"===typeof t.value||!!t.value||"string"===typeof t.sort||Array.isArray(t.sort)&&"string"===typeof t.sort[0])})},viewTableGrouping(){const e=this.groupByOf(this.view);return this.tableGroupings.find(t=>`${Pe}${t.value}`===e)||null},viewFilterFields(){const e=[...this.viewSortableFields,...this.viewDateFields],t=this.viewFields.filter(t=>!t.isLabel&&e.includes(t)),n=(this.queryFields||[]).filter(e=>e.values),r=t.findIndex(e=>"name"===e.id)+1||t.length;return[...t.slice(0,r),...n,...t.slice(r)]},viewDateFields(){return this.viewFields.filter(e=>{if(!e.isDate||!e.header?.sort||!(0,b.u$)(this.filteredRows,e))return!1;if(!this.serverSideTableViews)return!0;const t=(0,b.WA)(e);return"string"===typeof t&&!t.startsWith("metadata.fields.")})},viewDateFieldIds(){return this.viewDateFields.map(e=>e.id)},viewTerms(){return W(this.settledQuery,this.viewQueryFields)},viewQuery(){return this.parseViewQuery(this.settledQuery)},viewBusy(){return this.showTableViews&&((this.view.query||"")!==(this.settledQuery||"")||this.viewSwitching)},serverSideTableViews(){return this.showTableViews&&this.externalPaginationEnabled&&!!this.schema},viewFiltersApplied(){const e=(this.externalPaginationArgs?.filters||[]).map(e=>JSON.stringify(e)),t=(this.pendingViewFilters||[]).map(e=>JSON.stringify(e)),n=(this.supersededViewFilters||[]).map(e=>JSON.stringify(e));return t.every(t=>e.includes(t))&&!n.some(n=>!t.includes(n)&&e.includes(n))},serverViewFilters(){return this.serverSideTableViews?oe(this.viewQuery,this.viewQueryFields):{filters:[],unsupported:[]}},unsupportedViewFields(){const e={};return(this.serverViewFilters.unsupported||[]).forEach(t=>{const n=t.field?(0,b.UI)(this.viewQueryFields,t.field):null,r=n?n.label||n.id:t.value;r&&(e[r]=!0)}),Object.keys(e)},listScopeFilters(){if(this.externalPaginationScope)return this.externalPaginationScope.filters||[];const e=this.externalPaginationArgs;if(!e?.filters?.length)return[];const t=this.serverViewFilters.filters.map(e=>JSON.stringify(e));return e.filters.filter(e=>!t.includes(JSON.stringify(e)))},listScopeNamespaces(){return this.externalPaginationScope?.projectsOrNamespaces||this.externalPaginationArgs?.projectsOrNamespaces||[]},summaryBaseUrl(){if(!this.serverSideTableViews)return null;const e=this.$store.getters[`${this.inStore}/urlFor`],t=this.externalPaginationArgs;return t?e(this.schema.id,null,{pagination:{filters:this.listScopeFilters,projectsOrNamespaces:this.listScopeNamespaces}}):e(this.schema.id)},viewRows(){return this.serverSideTableViews?this.filteredRows:this.showTableViews&&this.viewTerms.length?L(this.filteredRows,this.viewQuery,this.viewQueryFields):this.filteredRows},viewMatchCount(){return this.serverSideTableViews?this.externalPaginationResult?.count??this.filteredRows.length:this.viewRows.length},viewGroupField(){const e=this.groupByOf(this.view);return this.showTableViews&&e?this.groupFieldFor(e):null},viewGroupSort(){return this.viewGroupField&&this.groupSortFor(this.viewGroupField)||this.groupSort},viewHeaders(){return this.headersForView(this.view)},savedViews(){return Me(this)?.views||[]},countableQueries(){const e=[""].concat(this.savedViews.map(e=>e.query||"")).concat([this.view.query||""]).concat(this.tabQueries);return Array.from(new Set(e))},viewCountsKey(){return JSON.stringify(this.countableQueries)},viewCountsScope(){return JSON.stringify(this.listScopeFilters)+JSON.stringify(this.listScopeNamespaces)},localViewCounts(){const e={};return this.countableQueries.forEach(t=>{const n=this.parseViewQuery(t);e[t]=n.clauses.length?L(this.filteredRows,n,this.viewQueryFields).length:this.filteredRows.length}),e},tabCounts(){return this.serverSideTableViews?this.viewCounts:this.localViewCounts},exportColumns(){return(0,N.lo)(this.viewHeaders,e=>this.t(e))}},methods:{dropStateLink(){if(!this.stateLinkPending||!this.showTableViews)return;if(this.stateLinkPending=!1,!(le.GH in(this.$route?.query||{})))return;const e={...this.$route.query};delete e[le.GH],this.$router.replace({path:this.$route.path,query:e,hash:this.$route.hash}).catch(()=>{})},parseViewQuery(e){return ae(Z(e,this.viewQueryFields),this.viewQueryFields)},groupByOf(e){return e.groupBy===pe?null:e.groupBy||this.defaultGroupBy||null},groupFieldFor(e){if(e?.startsWith(Ie)){const t=(0,b.UI)(this.viewDateFields,e.slice(Ie.length));return t?this.monthGrouping(t):null}return(0,b.UI)(this.viewFields,e)||null},monthGrouping(e){return{...e,id:`${Ie}${e.id}`,byMonth:!0}},tableGroupingLabel(e){const t=e.labelKey||e.tooltipKey?.replace(/^resourceTable\.groupBy\./,"tableViews.group.by.");return t&&this.$store.getters["i18n/exists"](t)?this.t(t):e.tooltipKey?this.t(e.tooltipKey):e.tooltip||e.value},headersForView(e){const t=this._headers;if(!this.showTableViews)return t;let n=t;if(e.columns&&(n=this.availableHeaders.filter(t=>(0,b.hn)(t)||this.coreColumnIds.includes((0,b.vv)(t))||!this.viewFields.find(e=>!e.isLabel&&e.id===(0,b.vv)(t))||e.columns.includes((0,b.vv)(t)))),e.columnOrder?.length){const t=e.columnOrder,r=n.filter(e=>!(0,b.hn)(e)&&t.includes((0,b.vv)(e))),i=r.slice().sort((e,n)=>t.indexOf((0,b.vv)(e))-t.indexOf((0,b.vv)(n)));let o=0;n=n.map(e=>r.includes(e)?i[o++]:e)}if(e.labelColumns?.length){n=n.slice();const t=n.findIndex(e=>e.name===h.K.name),r=t>=0?t:n.length;e.labelColumns.forEach((e,t)=>{n.splice(r+t,0,{name:`${b.Bb}${e}`,label:e,value:t=>t?.metadata?.labels?.[e]||"",sort:!1,search:!1})})}return n},groupSortFor(e){const t=e?.header?.sort,n=Array.isArray(t)?t[0]:t;if("string"===typeof n&&n)return n.split(":")[0];const r=e?(0,b.WA)(e):null;return"string"===typeof r?r:null},fieldSummaryPath(e){const t=e?(0,b.WA)(e):null,n=Array.isArray(t)?t[0]:t,r=this.viewFilterFields.some(t=>t.id===e?.id);return"string"===typeof n&&r?n:null},async summaryValues(e,t){const n=`${this.summaryBaseUrl}&summary=${encodeURIComponent(t)}&summaryonly`,r=await this.$store.dispatch(`${this.inStore}/request`,{opt:{url:n}}),i=this.viewDateFieldIds.includes(e)?1/0:void 0;return(0,b.mi)(r,i)},async fetchFieldValues(e){if(!this.serverSideTableViews||void 0!==this.fieldValues[e])return;const t=(0,b.UI)(this.viewQueryFields,e);if(t?.queryOnly)return t.values?this.fetchQueryFieldCounts(t):void 0;const n=this.fieldSummaryPath(t);if(!n)return void(this.fieldValues={...this.fieldValues,[e]:[]});this.fieldValues={...this.fieldValues,[e]:[]},this.fieldValuesLoading=[...this.fieldValuesLoading,e];const r=this.summaryBaseUrl;try{const t=await this.summaryValues(e,n);r===this.summaryBaseUrl&&(this.fieldValues={...this.fieldValues,[e]:t},this.fieldValuesAt={...this.fieldValuesAt,[e]:Date.now()})}catch(i){if(r===this.summaryBaseUrl){const{[e]:t,...n}=this.fieldValues;this.fieldValues=n}}finally{this.fieldValuesLoading=this.fieldValuesLoading.filter(t=>t!==e)}},async refreshFieldValues(e){const t=this.fieldValuesLoading.includes(e)||this.fieldValuesRefreshing.includes(e),n=Date.now()-(this.fieldValuesAt[e]||0)<Ne;if(!this.serverSideTableViews||void 0===this.fieldValues[e]||t||n)return;const r=this.fieldSummaryPath((0,b.UI)(this.viewQueryFields,e));if(!r)return;const i=this.summaryBaseUrl;this.fieldValuesRefreshing=[...this.fieldValuesRefreshing,e];try{const t=await this.summaryValues(e,r);i===this.summaryBaseUrl&&(this.fieldValues={...this.fieldValues,[e]:t},this.fieldValuesAt={...this.fieldValuesAt,[e]:Date.now()})}catch(o){}finally{this.fieldValuesRefreshing=this.fieldValuesRefreshing.filter(t=>t!==e)}},async fetchQueryFieldCounts(e){this.fieldValues={...this.fieldValues,[e.id]:[]},this.fieldValuesLoading=[...this.fieldValuesLoading,e.id];try{const t=await Promise.all(e.values.map(async({value:t})=>{const{filters:n}=oe(this.parseViewQuery(`${e.id}:${t}`),this.viewQueryFields),r=await this.$store.dispatch(`${this.inStore}/request`,{opt:{url:this.countUrl(n)}});return{value:t,count:r?.count??r?.data?.length??0}}));this.fieldValues={...this.fieldValues,[e.id]:t}}catch(t){this.fieldValues={...this.fieldValues,[e.id]:e.values}}finally{this.fieldValuesLoading=this.fieldValuesLoading.filter(t=>t!==e.id)}},async fetchViewCounts(e=!1){if(!this.serverSideTableViews)return;const t=this.countableQueries.filter(t=>e||void 0===this.viewCounts[t]);if(t.length&&!this.countingInFlight){this.countingInFlight=!0;try{await this.requestViewCounts(t)}finally{this.countingInFlight=!1}}},async requestViewCounts(e){await Promise.all(e.map(async e=>{const t=this.parseViewQuery(e),{filters:n,unsupported:r}=oe(t,this.viewQueryFields);if(r.length)this.viewCounts={...this.viewCounts,[e]:null};else try{const t=this.countUrl(n),r=await this.$store.dispatch(`${this.inStore}/request`,{opt:{url:t}}),i=r?.count??r?.data?.length;void 0!==i&&(this.viewCounts={...this.viewCounts,[e]:i})}catch(i){this.viewCounts={...this.viewCounts,[e]:null}}}))},countUrl(e){const t=this.$store.getters[`${this.inStore}/urlFor`];return t(this.schema.id,null,{pagination:{filters:(this.listScopeFilters||[]).concat(e),projectsOrNamespaces:this.listScopeNamespaces,page:1,pageSize:1}})},recordSort(e){if(!this.showTableViews||!e?.sortBy)return;const{sortBy:t,descending:n}=e,r=this.view.sort;if(r&&!this.viewHeaders.some(e=>e.name===r))return;if(r===t&&!!this.view.sortDescending===!!n)return;if(!this.defaultSort&&(this.defaultSort={sortBy:t,descending:!!n},r))return void this.$nextTick(()=>this.applyViewSort());const i=t===this.defaultSort.sortBy&&!!n===this.defaultSort.descending,o=i?null:t;(this.view.sort||null)===o&&!!this.view.sortDescending===!!n||(this.view={...this.view,sort:o,sortDescending:!!n})},applyViewSort(){const e=this.$refs.table;if(!e||!this.defaultSort)return;const t=this.view.sort,n=t&&this.viewHeaders.some(e=>e.name===t),r=n?t:this.defaultSort.sortBy,i=n?!!this.view.sortDescending:this.defaultSort.descending;e.sortBy===r&&!!e.descending===i||e.changeSort(r,i)},async allMatchingRows(e,t=Ce){return this.externalPaginationEnabled&&this.externalPaginationArgs&&this.schema?this.fetchEveryPage(this.externalPaginationArgs,e,t,()=>this.viewRows):this.viewRows},async fetchEveryPage(e,t,n,r){const i=[];let o,a=null;try{for(let r=1;i.length<n;r++){const s=await this.$store.dispatch(`${this.inStore}/findPage`,{type:this.schema.id,opt:{transient:!0,watch:!1,revision:o,pagination:{...e,page:r,pageSize:Te}}}),l=s?.data||[];if(i.push(...l),null===a&&(a=Math.min(s?.pagination?.result?.count??l.length,n),o=s?.pagination?.result?.revision),t?.(Math.min(i.length,a),a),l.length<Te||i.length>=a)break}}catch(s){if(!i.length){if(r)return r();throw s}}return i},async rowsForView(e,t,n){const r=this.parseViewQuery(e.query||"");let i;if(this.serverSideTableViews){const{filters:o}=oe(r,this.viewQueryFields),{fields:a,descending:s}=this.sortFor(e);i=await this.fetchEveryPage({filters:(this.listScopeFilters||[]).concat(o),projectsOrNamespaces:this.listScopeNamespaces,sort:a.map(e=>({field:e,asc:!s}))},t,n)}else i=r.clauses.length?L(this.filteredRows,r,this.viewQueryFields):this.filteredRows;return this.serverSideTableViews?i:this.orderRowsFor(e,i)},sortFor(e){const t=this.headersForView(e),n=!!e.sort&&t.some(t=>t?.name===e.sort),r=n?e.sort:this.defaultSort?.sortBy,i=n?!!e.sortDescending:!!this.defaultSort?.descending,o=r?t.find(e=>e?.name?.toLowerCase()===r.toLowerCase()):null,a="string"===typeof o?.sort||Array.isArray(o?.sort)?[].concat(o.sort):[],s=this.groupByOf(e),l=s?this.groupSortFor(this.groupFieldFor(s)):null,c=(0,f.sb)([].concat(l||[],a).concat(this._mandatorySort||ce.J));return{fields:c,descending:i}},orderRowsFor(e,t){const{fields:n,descending:r}=this.sortFor(e);return(0,ue.Ul)(t,n,r)},openTabView(e){this.debouncedSettleQuery.cancel(),this.settledQuery=e?.query||"",this.view=e},beginViewSwitch(){this.viewSwitching||(this.viewSwitchFromArgs=this.externalPaginationArgs),this.viewSwitching=!0,clearTimeout(this.viewSwitchTimer),this.viewSwitchTimer=setTimeout(()=>{this.viewSwitching=!1},Re)},endViewSwitch(){this.viewSwitching&&(clearTimeout(this.viewSwitchTimer),this.viewSwitching=!1)},async handleExport({format:e,name:t,view:n}){const r=t||this.t("tableViews.tabs.all"),i=await this.$store.dispatch("notifications/add",{level:T.SG.Task,title:this.t("tableViews.export.notification.title"),message:this.t("tableViews.export.notification.message",{name:r,format:(e||"").toUpperCase()}),progress:0}),o="yaml"===e?20:90,a=(e,t,n,r)=>{this.$store.dispatch("notifications/update",{id:i,progress:Math.round(n+(r-n)*e/(t||1))})};try{const t="yaml"===e?Ae:Ce,s=(e,t)=>a(e,t,0,o),l=n?await this.rowsForView(n,s,t):await this.allMatchingRows(s,t);if(!l.length||!e)return this.$store.dispatch("notifications/remove",i);const c=n?(0,N.lo)(this.headersForView(n),e=>this.t(e)):this.exportColumns,u=await this.writeExport(l,e,(e,t)=>a(e,t,o,100),c);return this.$store.dispatch("notifications/update",{id:i,level:T.SG.Success,title:this.t("tableViews.export.notification.doneTitle"),message:this.t("tableViews.export.notification.doneMessage",{name:r,file:u}),progress:100})}catch(s){return ke.error("Unable to export the view",s),this.$store.dispatch("notifications/update",{id:i,level:T.SG.Error,title:this.t("tableViews.export.notification.failedTitle"),message:this.t("tableViews.export.notification.failedMessage",{name:r})})}},async writeExport(e,t,n,r=this.exportColumns){if("yaml"===t&&"function"===typeof e[0]?.downloadYaml)return 1===e.length?(await e[0].downloadYaml(),`${e[0].nameDisplay}.yaml`):(await e[0].downloadYamlBulk(e,n),"resources.zip");const i=(this.schema?.id||"resources").replace(/[^a-z0-9]+/gi,"-"),o={yaml:{write:N.Ei,type:"application/yaml;charset=utf-8"},json:{write:N.hz,type:"application/json;charset=utf-8"},csv:{write:N.lH,type:"text/csv;charset=utf-8"}},a=o[t]||o.csv,s=`${i}.${t}`;return await(0,R.PE)(s,a.write(e,r),a.type),s}}},Be=n(88343),$e={props:{schema:{type:Object,default:null}},data(){const e=this.schema?.id?{type:this.schema.id,mode:Be.g.RESOURCE_CHANGES}:void 0;return{watchOpts:e}},computed:{watching(){return this.$store.getters[`${this.inStore}/watchStarted`](this.watchOpts)}},methods:{toggleWatch(e){e?this.$store.dispatch(`${this.inStore}/resyncWatch`,{...this.watchOpts,resourceType:this.watchOpts?.type}):this.$store.dispatch(`${this.inStore}/unwatch`,this.watchOpts)}}},Ve=n(15092),Fe=n(30342),je=n(95457);const Ue=["aria-expanded","aria-controls","aria-activedescendant","data-placeholder","aria-label"],Ge={class:"query-affordance"},He=["aria-label"],qe={key:1,class:"icon icon-search"},Qe={class:"sr-only","aria-live":"polite","aria-atomic":"true"},ze=["id","aria-label","aria-busy"],Ke={key:0,class:"suggestion-rule",role:"presentation"},We=["id","aria-selected","onMousedown","onMouseenter"],Xe={class:"suggestion-detail"},Ye={key:0,class:"suggestion-loading",role:"presentation","data-testid":"table-views-suggestions-loading"},Ze=20,Je=260,et=13,tt=30,nt="\0";var rt=(0,r.defineComponent)({__name:"TableViewQueryInput",props:{value:{default:""},fields:{default:()=>[]},filterFields:{default:null},fieldValues:{default:()=>({})},rows:{default:()=>[]},dateFields:{default:()=>[]},pendingFields:{default:()=>[]},loadingValues:{default:()=>[]}},emits:["update:value","request-values","refresh-values","update:focused"],setup(e,{emit:t}){let n=0;const i=e,o=t,a=e=>{const t=i.fieldValues[e.id];return i.dateFields.includes(e.id)?(0,b.Ks)((null===t||void 0===t?void 0:t.length)?t:(0,b.lP)(i.rows,e,1/0)):(null===t||void 0===t?void 0:t.length)?t:(0,b.lP)(i.rows,e)},{t:l}=(0,je.s)((0,s.Pj)()),c=(0,r.ref)(null),u=(0,r.ref)(null),d=(0,r.ref)(null),h=(0,r.ref)(0),p=(0,r.ref)(!1),f=(0,r.ref)(!1),m=(0,r.ref)(0),g=(0,r.ref)(null),v=(0,r.ref)(!1),y=(0,r.ref)({top:0,left:0,width:0,clip:"none"}),w=(0,r.ref)(0),O=(0,r.ref)(!1),S=(0,r.ref)(!1);let E=0;const x=(0,r.ref)(!1),_=""+n++,k=(0,r.computed)(()=>`table-view-query-menu-${_}`),C=e=>`${k.value}-option-${e}`,A=(0,r.computed)(()=>z(i.value||"",i.fields).filter(e=>"term"===e.kind)),T=(0,r.computed)(()=>{const e={};return A.value.forEach(t=>{const n=t.field;n&&!e[n.id]&&(e[n.id]=new Set(a(n).map(e=>e.value.toLowerCase())))}),e}),R=(e,t)=>{var n;return!!t&&!!(null===(n=T.value[e])||void 0===n?void 0:n.has(`${t}`.toLowerCase()))},N=(0,r.ref)(!1),P=(0,r.computed)(()=>!N.value&&!p.value&&A.value.some(e=>e.field&&i.pendingFields.includes(e.field.id)));(0,r.watch)(P,e=>{e||(N.value=!0)},{immediate:!0});const I=(0,r.computed)(()=>K(i.value||"",i.fields,(e,t)=>R(e,t))),M=(0,r.computed)(()=>Array.from(new Set(A.value.map(e=>{var t;return null===(t=e.field)||void 0===t?void 0:t.id}).filter(e=>!!e)))),D=(0,r.computed)(()=>I.value.map(e=>`${e.kind}:${e.text}`).join(nt)),L=(0,r.computed)(()=>ee(i.value||"",h.value,i.fields)),V=(0,r.computed)(()=>{const e=L.value;return e?{negate:e.negate||"",field:e.field||null,typed:e.value}:{negate:"",field:null,typed:""}}),j=(0,r.computed)(()=>{const e=L.value,t=z(i.value||"",i.fields).filter(t=>t.end<=h.value&&(!e||t.start!==e.start));return t[t.length-1]||null}),U=(0,r.computed)(()=>{const{negate:e,field:t,typed:n}=V.value;if(t||e)return[];const r=j.value;let i;i=r?"connective"===r.kind?F(r.text)?[]:$:[...B,...$]:$;const o=n.toLowerCase();return i.filter(e=>e.includes(o)).map(e=>({key:`connective:${e}`,label:e,detail:l(`tableViews.query.connective.${e}`),insert:`${e} `,connective:!0}))}),G=(0,r.computed)(()=>!!i.value),q=(0,r.computed)(()=>i.filterFields||i.fields),Q=(0,r.computed)(()=>{const{field:e}=V.value;return e&&i.loadingValues.includes(e.id)&&q.value.some(t=>t.id===e.id)?e:null}),W=(0,r.computed)(()=>{const{negate:e,field:t,typed:n}=V.value,r=n.toLowerCase();return t?!q.value.some(e=>e.id===t.id)||Q.value?[]:a(t).filter(e=>e.value.toLowerCase().includes(r)).map(n=>({key:`${t.id}:${n.value}`,label:n.value,detail:l("tableViews.query.inUse",{count:n.count}),insert:`${e}${t.id}:${H(n.value)} `,value:n.value})):U.value.concat(q.value.filter(e=>e.id.toLowerCase().includes(r)||e.label.toLowerCase().includes(r)).slice(0,20).map(t=>({key:t.id,label:t.isLabel?`${b.Bb}${t.label}`:t.label,detail:t.isLabel?l("tableViews.query.label"):t.id,insert:`${e}${t.id}:`,field:t})))}),X=(0,r.computed)(()=>{const e=e=>{var t;return e.connective?"joiner":(null===(t=e.field)||void 0===t?void 0:t.isLabel)?"label":"field"},t=[];let n=null;return W.value.forEach((r,i)=>{const o=e(r);n&&n.kind===o||(n={kind:o,entries:[]},t.push(n)),n.entries.push({...r,index:i})}),t}),Y=(0,r.computed)(()=>W.value.map(e=>e.key).join(nt)),Z=(0,r.computed)(()=>p.value&&!f.value&&(!!W.value.length||!!Q.value)),te=(0,r.computed)(()=>Z.value&&W.value.length?C(m.value):void 0),ne=(0,r.computed)(()=>Z.value?W.value.length?l("tableViews.query.suggestionsAvailable",{count:W.value.length},!0):l("tableViews.query.loadingValues"):""),re=(0,r.computed)(()=>({top:`${y.value.top}px`,left:`${y.value.left}px`,clipPath:y.value.clip,"--query-menu-stack":w.value,...S.value?{}:{visibility:"hidden"}})),ie=()=>{const e=u.value,t=window.getSelection();if(!e||!(null===t||void 0===t?void 0:t.rangeCount))return null;const n=t.getRangeAt(0);if(!e.contains(n.endContainer))return null;const r=n.cloneRange();return r.selectNodeContents(e),r.setEnd(n.endContainer,n.endOffset),r.toString().length},oe=e=>{const t=u.value;if(!t)return;const n=document.createTreeWalker(t,NodeFilter.SHOW_TEXT),r=document.createRange();let i=Math.max(0,Math.min(e,(t.textContent||"").length)),o=n.nextNode(),a=null;while(o){if(i<=(o.textContent||"").length){r.setStart(o,i);break}i-=(o.textContent||"").length,a=o,o=n.nextNode()}o||(a?r.setStart(a,(a.textContent||"").length):r.selectNodeContents(t)),r.collapse(!0);const s=window.getSelection();null===s||void 0===s||s.removeAllRanges(),null===s||void 0===s||s.addRange(r),h.value=Math.max(0,Math.min(e,(t.textContent||"").length)),ae(r)},ae=e=>{const t=u.value,n=e.getBoundingClientRect();if(!t||!n.left&&!n.top)return;const r=t.getBoundingClientRect();n.left>r.right?t.scrollLeft+=n.left-r.right+1:n.left<r.left&&(t.scrollLeft-=r.left-n.left)},se=()=>{var e;const t=u.value;if(t&&!v.value&&(!x.value||t.textContent===(i.value||""))){x.value=!1;while(t.firstChild)t.removeChild(t.firstChild);I.value.forEach(e=>{const n=document.createElement("span");n.className=`segment-${e.kind}`,n.textContent=e.text,t.appendChild(n)}),document.activeElement===t&&oe(null!==(e=g.value)&&void 0!==e?e:h.value),g.value=null}},le=()=>{const e=u.value;if(!e)return null;const t=window.getSelection();if(null===t||void 0===t?void 0:t.rangeCount){const n=t.getRangeAt(0);if(e.contains(n.startContainer)){const e=n.getBoundingClientRect();if(e&&(e.left||e.top))return e.left}}return e.getBoundingClientRect().left},ce=()=>{var e;let t=null===(e=c.value)||void 0===e?void 0:e.parentElement,n=0;while(t&&t!==document.documentElement){const e=parseInt(getComputedStyle(t).zIndex,10);!isNaN(e)&&e>n&&(n=e),t=t.parentElement}return n?n+1:0},ue=()=>{var e;const t={top:0,left:0,bottom:window.innerHeight,right:window.innerWidth};for(let n=null===(e=c.value)||void 0===e?void 0:e.parentElement;n&&n!==document.body;n=n.parentElement){const{overflowX:e,overflowY:r}=getComputedStyle(n);if("visible"!==e||"visible"!==r){const e=n.getBoundingClientRect();t.top=Math.max(t.top,e.top),t.left=Math.max(t.left,e.left),t.bottom=Math.min(t.bottom,e.bottom),t.right=Math.min(t.right,e.right)}}return t},de=()=>{var e,t,n,r,i;const o=null===(t=null===(e=c.value)||void 0===e?void 0:e.getBoundingClientRect)||void 0===t?void 0:t.call(e);if(o){const e=(null===(n=d.value)||void 0===n?void 0:n.offsetWidth)||Je,t=(null===(r=d.value)||void 0===r?void 0:r.offsetHeight)||0,a=Math.max(Ze,window.innerWidth-e-Ze),s=o.bottom-1,l=Math.min((null!==(i=le())&&void 0!==i?i:o.left)-et,a),c=ue(),u=[c.top-s,l+e-c.right,s+t-c.bottom,c.left-l];y.value={top:s,left:l,width:o.width,clip:u.some(e=>e>0)?`inset(${u.map(e=>e>0?`${Math.ceil(e)}px`:`-${tt}px`).join(" ")})`:"none"},O.value=o.bottom<=c.top||o.bottom>c.bottom||o.right<=c.left||o.left>=c.right}w.value=ce()},he=()=>{Z.value&&(0,r.nextTick)(()=>de())},pe=()=>{const e=ie();null!==e&&(h.value=e)},fe=()=>{var e;return null===(e=u.value)||void 0===e?void 0:e.focus()},me=()=>{var e,t,n;if(v.value)return;f.value=!1;const r=null!==(t=null===(e=u.value)||void 0===e?void 0:e.textContent)&&void 0!==t?t:"";h.value=null!==(n=ie())&&void 0!==n?n:r.length,g.value=h.value,x.value=!0,o("update:value",r)},ge=()=>{v.value=!1,me()},ve=e=>{var t,n;const r=(null===(t=e.clipboardData)||void 0===t?void 0:t.getData("text"))||"",a=r.replace(/\s+/g," ").trim(),s=u.value;if(!s)return;const l=i.value||"",c=window.getSelection(),d=(null===c||void 0===c?void 0:c.rangeCount)?c.getRangeAt(0):null;let p=Math.min(null!==(n=h.value)&&void 0!==n?n:l.length,l.length),f=p;if(d&&s.contains(d.startContainer)&&s.contains(d.endContainer)){const e=d.cloneRange();e.selectNodeContents(s),e.setEnd(d.startContainer,d.startOffset),p=e.toString().length,f=p+d.toString().length}const m=`${l.substring(0,p)}${a}${l.substring(f)}`;g.value=p+a.length,x.value=!1,o("update:value",m)},be=()=>{p.value=!0,f.value=!1,o("update:focused",!0)},ye=()=>{f.value=!1,pe(),he()},we=e=>{var t,n,r,i;const a=c.value,s=e.target;a&&s&&!a.contains(s)&&!(null===(n=null===(t=d.value)||void 0===t?void 0:t.contains)||void 0===n?void 0:n.call(t,s))&&((null===(r=s.contains)||void 0===r?void 0:r.call(s,a))&&e.preventDefault(),p.value=!1,o("update:focused",!1),document.activeElement===u.value&&(null===(i=u.value)||void 0===i||i.blur()))},Oe=()=>{setTimeout(()=>{document.activeElement!==u.value&&(p.value=!1,o("update:focused",!1))},150)},Se=()=>{g.value=0,x.value=!1,o("update:value",""),fe()},Ee=e=>{if(!e)return;const t=L.value,n=i.value||"",r=J(n,t,e.insert,h.value);g.value=t?t.start+e.insert.length:h.value+(r.length-n.length),x.value=!1,o("update:value",r),fe()},xe=(0,r.ref)(!1),_e=e=>{const t=W.value.length;t&&(xe.value=!0,m.value=(m.value+e+t)%t,(0,r.nextTick)(()=>{var e;const t=d.value,n=m.value;t&&(0!==n&&n!==W.value.length-1?null===(e=t.querySelector(`[id="${C(n)}"]`))||void 0===e||e.scrollIntoView({block:"nearest"}):t.scrollTop=0===n?0:t.scrollHeight)}))},ke=e=>{xe.value||(m.value=e)},Ce=e=>{"Enter"===e.key&&e.preventDefault(),Z.value?O.value||("ArrowDown"===e.key?(e.preventDefault(),_e(1)):"ArrowUp"===e.key?(e.preventDefault(),_e(-1)):"Enter"===e.key?(e.preventDefault(),W.value[m.value]&&Ee(W.value[m.value])):"Escape"===e.key&&(f.value=!0)):"Escape"===e.key&&i.value&&(e.preventDefault(),Se())},Ae=(0,r.computed)(()=>{var e;return Array.from(new Set([...M.value,null===(e=V.value.field)||void 0===e?void 0:e.id].filter(e=>!!e))).join(nt)});(0,r.watch)(Ae,e=>{e.split(nt).filter(Boolean).forEach(e=>o("request-values",e))},{immediate:!0});const Te=(0,r.computed)(()=>{const{field:e}=V.value;return e&&q.value.some(t=>t.id===e.id)?e.id:null});let Re=null;return(0,r.watch)([Te,p,f],([e,t,n])=>{t&&!n?e&&e!==Re&&(Re=e,o("refresh-values",e)):Re=null}),(0,r.watch)(Y,()=>{m.value=0,he()}),(0,r.watch)(h,()=>he()),(0,r.watch)(Z,e=>{cancelAnimationFrame(E),e?(S.value=!1,E=requestAnimationFrame(()=>{pe(),(0,r.nextTick)(()=>{de(),S.value=!0})}),window.addEventListener("scroll",de,!0),window.addEventListener("resize",de)):(window.removeEventListener("scroll",de,!0),window.removeEventListener("resize",de))}),(0,r.watch)(D,()=>se()),(0,r.onMounted)(()=>{se(),document.addEventListener("mousedown",we,!0)}),(0,r.onBeforeUnmount)(()=>{cancelAnimationFrame(E),document.removeEventListener("mousedown",we,!0),window.removeEventListener("scroll",de,!0),window.removeEventListener("resize",de)}),(t,n)=>((0,r.openBlock)(),(0,r.createElementBlock)("div",{ref_key:"root",ref:c,class:(0,r.normalizeClass)(["table-view-query",{focused:p.value,"list-open":Z.value}])},[(0,r.createElementVNode)("div",{ref_key:"input",ref:u,class:(0,r.normalizeClass)(["query-input",{"is-empty":!e.value,holding:P.value}]),contenteditable:"true",role:"combobox","aria-multiline":"false","aria-autocomplete":"list","aria-expanded":Z.value?"true":"false","aria-controls":k.value,"aria-activedescendant":te.value,spellcheck:"false","data-testid":"table-views-query","data-placeholder":(0,r.unref)(l)("tableViews.query.placeholder"),"aria-label":(0,r.unref)(l)("tableViews.query.placeholder"),onInput:me,onPaste:(0,r.withModifiers)(ve,["prevent"]),onCompositionstart:n[0]||(n[0]=e=>v.value=!0),onCompositionend:ge,onClick:ye,onKeyup:pe,onKeydown:Ce,onFocus:be,onBlur:Oe},null,42,Ue),(0,r.createElementVNode)("span",Ge,[G.value?((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:0,type:"button",class:"query-clear","aria-label":(0,r.unref)(l)("tableViews.query.clear"),"data-testid":"table-views-query-clear",onMousedown:(0,r.withModifiers)(Se,["left","prevent"])},[...n[2]||(n[2]=[(0,r.createElementVNode)("i",{class:"icon icon-close"},null,-1)])],40,He)):e.value?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createElementBlock)("i",qe))]),(0,r.createElementVNode)("span",Qe,(0,r.toDisplayString)(ne.value),1),((0,r.openBlock)(),(0,r.createBlock)(r.Teleport,{to:"body"},[Z.value?((0,r.openBlock)(),(0,r.createElementBlock)("ul",{key:0,id:k.value,ref_key:"menu",ref:d,class:"vs__dropdown-menu table-view-query-menu",role:"listbox","aria-label":(0,r.unref)(l)("tableViews.query.suggestions"),"aria-busy":!!Q.value,style:(0,r.normalizeStyle)(re.value),"data-testid":"table-views-suggestions",onMousemove:n[1]||(n[1]=e=>xe.value=!1)},[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(X.value,(e,t)=>((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:e.kind},[t?((0,r.openBlock)(),(0,r.createElementBlock)("li",Ke,[(0,r.createVNode)(Fe.A)])):(0,r.createCommentVNode)("",!0),((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(e.entries,e=>((0,r.openBlock)(),(0,r.createElementBlock)("li",{id:C(e.index),key:e.key,role:"option","aria-selected":e.index===m.value?"true":"false",class:(0,r.normalizeClass)({active:e.index===m.value}),onMousedown:(0,r.withModifiers)(t=>Ee(e),["prevent"]),onMouseenter:t=>ke(e.index)},[(0,r.createElementVNode)("span",{class:(0,r.normalizeClass)(["suggestion-label",{connective:e.connective}])},(0,r.toDisplayString)(e.label),3),(0,r.createElementVNode)("span",Xe,(0,r.toDisplayString)(e.detail),1)],42,We))),128))],64))),128)),Q.value?((0,r.openBlock)(),(0,r.createElementBlock)("li",Ye,[n[3]||(n[3]=(0,r.createElementVNode)("i",{class:"icon icon-spinner icon-spin"},null,-1)),(0,r.createTextVNode)(" "+(0,r.toDisplayString)((0,r.unref)(l)("tableViews.query.loadingValues")),1)])):(0,r.createCommentVNode)("",!0)],44,ze)):(0,r.createCommentVNode)("",!0)]))],2))}}),it=(n(49436),n(54394),n(47433));const ot=(0,it.A)(rt,[["__scopeId","data-v-0e670ff7"]]);var at=ot;const st=4;function lt(){const e=e=>{e.stopPropagation(),e.preventDefault()};window.addEventListener("click",e,{capture:!0,once:!0}),setTimeout(()=>window.removeEventListener("click",e,!0),0)}function ct(e){const t=(0,r.ref)(null),n=(0,r.ref)(null),i=(0,r.ref)(!1),o=(0,r.ref)(0);let a=null,s=null;const l=t=>"x"===e.axis?t.clientX:t.clientY,c=()=>{const r=n.value;if(!r)return;const i=r.indexOf(t.value),a=e.indexAt(o.value);-1!==i&&-1!==a&&(n.value=_e(r,i,Math.max(a,e.firstMovable?e.firstMovable(r):0)))},u=()=>{var r;!i.value&&a&&(i.value=!0,t.value=a.key,n.value=e.initialOrder(),s=[...n.value],e.measure(),document.body.style.cursor="grabbing",null===(r=e.onBegin)||void 0===r||r.call(e))},d=e=>{a&&(o.value=l(e),!i.value&&Math.abs(o.value-a.at)<st||(u(),c()))},h=r=>{var o;window.removeEventListener("mousemove",d,!0),window.removeEventListener("mouseup",p,!0),window.removeEventListener("keydown",f,!0);const l=s||[],c=n.value,u=!!c&&c.some((e,t)=>e!==l[t]);i.value&<(),document.body.style.cursor="",null===(o=e.onEnd)||void 0===o||o.call(e),a=null,s=null,t.value=null,i.value=!1,r&&u&&c&&e.onCommit(c),n.value=null};function p(){h(i.value)}function f(e){"Escape"===e.key&&h(!1)}const m=(e,t)=>{a={key:e,at:l(t)},i.value=!1,window.addEventListener("mousemove",d,!0),window.addEventListener("mouseup",p,!0),window.addEventListener("keydown",f,!0)};return(0,r.onBeforeUnmount)(()=>h(!1)),{heldId:t,order:n,moved:i,pointer:o,start:m,end:h,place:c}}var ut=n(35881),dt=n(30588);const ht={class:"table-views","data-testid":"table-views-controls"},pt={class:"sr-only",role:"status","aria-live":"polite","data-testid":"table-views-announcement"},ft={class:"view-controls"},mt={class:"query-grow query-column"},gt=["data-testid"],vt={class:"view-menu"},bt={class:"menu-nav-value"},yt=["aria-label"],wt={class:"menu-nav-value"},Ot={key:0,class:"icon icon-lock column-handle"},St=["data-testid","onMousedown"],Et=12;var xt=(0,r.defineComponent)({__name:"TableViewControls",props:{view:{},coreColumns:{default:()=>[]},defaultColumns:{default:()=>[]},unsupportedFields:{default:()=>[]},fields:{default:()=>[]},groupFields:{default:null},defaultGroupBy:{default:null},filterFields:{default:null},dateFields:{default:()=>[]},fieldValues:{default:()=>({})},pendingFields:{default:()=>[]},loadingValues:{default:()=>[]},rows:{default:()=>[]}},emits:["update:view","request-values","refresh-values"],setup(e,{emit:t}){const n=e,i=t,o=(0,s.Pj)(),{t:a}=(0,je.s)(o),l=(0,r.ref)(null),c=(0,r.ref)(null),u=(0,r.ref)(!1),d=(0,r.ref)(null),h=(0,r.ref)(""),p=async e=>{h.value="",await(0,r.nextTick)(),h.value=e},f=(0,r.computed)(()=>a("tableViews.columns.moveKeys",{modifier:ut.cX?"Option":"Alt"})),m=(0,r.computed)(()=>u.value?[]:Y(n.view.query,n.fields)),g=(0,r.computed)(()=>a("tableViews.query.unsupported",{count:n.unsupportedFields.length,fields:n.unsupportedFields.join(", ")},!0)),v=e=>a(`tableViews.query.problem.${e.kind}`,{text:e.text,label:e.label||""},!0),b=(0,r.computed)(()=>m.value.length?m.value.map(e=>v(e)).join("<br>"):n.unsupportedFields.length?g.value:""),y=(0,r.computed)(()=>m.value.length?"error":"info"),w=(0,r.computed)(()=>n.fields.filter(e=>!e.isLabel&&!e.queryOnly)),O=(0,r.computed)(()=>({content:F.value?"":a("tableViews.columns.reorder"),placement:"left",distance:Et})),S=(0,r.computed)(()=>({content:a("tableViews.columns.locked"),placement:"left",distance:Et})),E=(0,r.computed)(()=>{const e=j.value||n.view.columnOrder;if(!(null===e||void 0===e?void 0:e.length))return w.value;const t={};w.value.forEach(e=>{t[e.id]=e});const r=e.map(e=>t[e]).filter(e=>!!e);return r.concat(w.value.filter(t=>!e.includes(t.id)))}),x=e=>n.view.columns?n.view.columns.includes(e.id):!n.defaultColumns.length||n.defaultColumns.includes(e.id),_=(0,r.computed)(()=>{var e;return!n.view.columns&&!(null===(e=n.view.labelColumns)||void 0===e?void 0:e.length)&&!n.view.columnOrder}),k=(0,r.computed)(()=>!n.view.groupBy),C=(0,r.computed)(()=>!Oe(n.view)),A=(0,r.computed)(()=>{var e;return w.value.filter(e=>x(e)).length+((null===(e=n.view.labelColumns)||void 0===e?void 0:e.length)||0)}),T=(0,r.computed)(()=>{var e;return _.value?a("tableViews.view.columnsDefault"):a("tableViews.view.columnsCount",{shown:A.value,total:w.value.length+((null===(e=n.view.labelColumns)||void 0===e?void 0:e.length)||0)})}),R=(0,r.computed)(()=>{const e={id:null,label:a("tableViews.group.none")};return[e].concat((n.groupFields||n.fields).filter(e=>!e.isLabel).map(e=>({id:e.id,label:e.label})))}),N=(0,r.computed)(()=>n.view.groupBy===pe?null:n.view.groupBy||n.defaultGroupBy||null),P=(0,r.computed)(()=>{var e;return(null===(e=R.value.find(e=>e.id===N.value))||void 0===e?void 0:e.label)||a("tableViews.group.none")}),I=e=>i("update:view",{...n.view,...e}),M=e=>!!(null===e||void 0===e?void 0:e.id)&&n.coreColumns.includes(e.id),D=e=>{if(M(e))return;const t=n.view.columns||w.value.filter(e=>x(e)).map(e=>e.id),r=t.includes(e.id)?t.filter(t=>t!==e.id):t.concat([e.id]);I({columns:r})},L=()=>{I({columns:w.value.map(e=>e.id)}),p(a("tableViews.columns.allShown",{count:w.value.length}))},B=()=>{const e=l.value,t=(null===e||void 0===e?void 0:e.querySelectorAll("[data-col-id]"))||[],n=e?e.getBoundingClientRect().top-e.scrollTop:0;d.value=Array.from(t).map(e=>{const t=e.getBoundingClientRect();return{top:t.top-n,bottom:t.bottom-n}})},$=e=>{const t=d.value||[],n=l.value;if(!t.length||!n)return-1;const r=e-n.getBoundingClientRect().top+n.scrollTop;return r<=t[0].top?0:r>=t[t.length-1].bottom?t.length-1:t.findIndex(e=>r>=e.top&&r<=e.bottom)},V=e=>{let t=0;while(t<e.length&&n.coreColumns.includes(e[t]))t++;return t},{heldId:F,order:j,start:U}=ct({axis:"y",initialOrder:()=>E.value.map(e=>e.id),measure:B,indexAt:$,firstMovable:V,onEnd:()=>{d.value=null},onCommit:e=>I({columnOrder:e})}),G=(e,t)=>{0===t.button&&(t.preventDefault(),U(e,t))},H=e=>I({groupBy:e===n.defaultGroupBy?null:e||pe}),q=e=>H(e===N.value?null:e),Q=()=>{I({columns:null,labelColumns:[],columnOrder:null}),p(a("tableViews.columns.resetDone"))},z=async()=>{I({groupBy:null}),await(0,r.nextTick)(),p(a("tableViews.group.resetDone",{label:P.value}))},K=async(e,t)=>{var n,i;const o=E.value.map(e=>e.id),s=o.indexOf(e.id),c=s+t;M(e)||c<V(o)||c>=o.length||(o.splice(c,0,o.splice(s,1)[0]),I({columnOrder:o}),p(a("tableViews.columns.moved",{label:e.label,position:c+1,total:o.length})),await(0,r.nextTick)(),null===(i=null===(n=l.value)||void 0===n?void 0:n.querySelector(`[data-col-id="${e.id}"]`))||void 0===i||i.focus())},W=()=>I({query:"",columns:null,labelColumns:[],columnOrder:null,groupBy:null,sort:null,sortDescending:!1});return(0,r.watch)(c,e=>{e&&requestAnimationFrame(()=>{const t=e.querySelector(`[data-testid="table-views-group-${N.value||"none"}"]`);if(!t)return;const n=e.getBoundingClientRect(),r=t.getBoundingClientRect();r.top<n.top?e.scrollTop-=n.top-r.top:r.bottom>n.bottom&&(e.scrollTop+=r.bottom-n.bottom)})}),(t,n)=>{const i=(0,r.resolveDirective)("clean-html"),o=(0,r.resolveDirective)("clean-tooltip");return(0,r.openBlock)(),(0,r.createElementBlock)("div",ht,[(0,r.createElementVNode)("div",pt,(0,r.toDisplayString)(h.value),1),(0,r.createElementVNode)("div",ft,[(0,r.createElementVNode)("div",mt,[(0,r.createVNode)(at,{value:e.view.query,fields:e.fields,"filter-fields":e.filterFields,"date-fields":e.dateFields,rows:e.rows,"field-values":e.fieldValues,"pending-fields":e.pendingFields,"loading-values":e.loadingValues,"onUpdate:value":n[0]||(n[0]=e=>I({query:e})),"onUpdate:focused":n[1]||(n[1]=e=>u.value=e),onRequestValues:n[2]||(n[2]=e=>t.$emit("request-values",e)),onRefreshValues:n[3]||(n[3]=e=>t.$emit("refresh-values",e))},null,8,["value","fields","filter-fields","date-fields","rows","field-values","pending-fields","loading-values"]),b.value?((0,r.openBlock)(),(0,r.createElementBlock)("p",{key:0,class:(0,r.normalizeClass)(["query-notice",y.value]),role:"alert","data-testid":"error"===y.value?"table-views-query-problem":"table-views-unsupported"},[(0,r.createElementVNode)("i",{class:(0,r.normalizeClass)(["icon","error"===y.value?"icon-notify-warning":"icon-notify-info"])},null,2),(0,r.withDirectives)((0,r.createElementVNode)("span",null,null,512),[[i,b.value]])],10,gt)):(0,r.createCommentVNode)("",!0)]),(0,r.createVNode)((0,r.unref)(dt.Jj),{placement:"bottom-end","aria-label":(0,r.unref)(a)("tableViews.view.label")},{dropdownCollection:(0,r.withCtx)(()=>[(0,r.createElementVNode)("div",vt,[(0,r.createVNode)((0,r.unref)(dt.ug),{side:"left","data-testid":"table-views-view-group"},{after:(0,r.withCtx)(()=>[(0,r.createElementVNode)("span",bt,(0,r.toDisplayString)(P.value),1)]),submenu:(0,r.withCtx)(()=>[(0,r.createElementVNode)("div",{ref_key:"groupPanel",ref:c,class:"menu-panel"},[(0,r.createElementVNode)("div",{role:"group","aria-label":(0,r.unref)(a)("tableViews.view.groupBy")},[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(R.value,e=>((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(dt.PU),{key:e.id||"none",checked:e.id===N.value,"data-testid":`table-views-group-${e.id||"none"}`,onClick:t=>q(e.id)},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.label),1)]),_:2},1032,["checked","data-testid","onClick"]))),128))],8,yt),(0,r.createVNode)((0,r.unref)(dt.Gh)),(0,r.createVNode)((0,r.unref)(dt.s$),{class:"menu-reset","acts-on-checkable-items":"","data-testid":"table-views-group-reset",disabled:k.value,onClick:z},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)((0,r.unref)(a)("tableViews.view.reset")),1)]),_:1},8,["disabled"])],512)]),default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)((0,r.unref)(a)("tableViews.view.groupBy"))+" ",1)]),_:1}),(0,r.createVNode)((0,r.unref)(dt.ug),{side:"left","data-testid":"table-views-view-columns"},{after:(0,r.withCtx)(()=>[(0,r.createElementVNode)("span",wt,(0,r.toDisplayString)(T.value),1)]),submenu:(0,r.withCtx)(()=>[(0,r.createElementVNode)("div",{ref_key:"columnsPanel",ref:l,class:"menu-panel columns-panel"},[(0,r.createVNode)(r.TransitionGroup,{name:"column-row",tag:"div",role:"group","aria-label":(0,r.unref)(a)("tableViews.view.columnsConfiguration"),class:(0,r.normalizeClass)({"is-reordering":null!==(0,r.unref)(F)})},{default:(0,r.withCtx)(()=>[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(E.value,e=>((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(dt.Nm),{key:e.id,indicator:"checkmark","model-value":x(e),class:(0,r.normalizeClass)({"column-row":!0,locked:M(e),shown:x(e),held:(0,r.unref)(F)===e.id}),disabled:M(e),"data-col-id":e.id,"data-testid":`table-views-col-${e.id}`,"aria-description":M(e)?(0,r.unref)(a)("tableViews.columns.locked"):f.value,onClick:t=>D(e),onKeydown:[(0,r.withKeys)((0,r.withModifiers)(t=>K(e,-1),["alt","prevent","stop"]),["up"]),(0,r.withKeys)((0,r.withModifiers)(t=>K(e,1),["alt","prevent","stop"]),["down"])]},{before:(0,r.withCtx)(()=>[M(e)?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("i",Ot,null,512)),[[o,S.value]]):(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("span",{key:1,class:"column-handle grip","data-testid":`table-views-col-handle-${e.id}`,onMousedown:t=>G(e.id,t)},null,40,St)),[[o,O.value]])]),default:(0,r.withCtx)(()=>[(0,r.createTextVNode)(" "+(0,r.toDisplayString)(e.label),1)]),_:2},1032,["model-value","class","disabled","data-col-id","data-testid","aria-description","onClick","onKeydown"]))),128))]),_:1},8,["aria-label","class"]),(0,r.createVNode)((0,r.unref)(dt.Gh)),(0,r.createVNode)((0,r.unref)(dt.s$),{"acts-on-checkable-items":"","data-testid":"table-views-columns-select-all",onClick:L},{before:(0,r.withCtx)(()=>[...n[5]||(n[5]=[(0,r.createElementVNode)("i",{class:"menu-gutter"},null,-1)])]),default:(0,r.withCtx)(()=>[(0,r.createTextVNode)(" "+(0,r.toDisplayString)((0,r.unref)(a)("tableViews.columns.selectAll")),1)]),_:1}),(0,r.createVNode)((0,r.unref)(dt.s$),{class:"menu-reset","acts-on-checkable-items":"","data-testid":"table-views-columns-reset",disabled:_.value,onClick:Q},{before:(0,r.withCtx)(()=>[...n[6]||(n[6]=[(0,r.createElementVNode)("i",{class:"menu-gutter"},null,-1)])]),default:(0,r.withCtx)(()=>[(0,r.createTextVNode)(" "+(0,r.toDisplayString)((0,r.unref)(a)("tableViews.columns.reset")),1)]),_:1},8,["disabled"])],512)]),default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)((0,r.unref)(a)("tableViews.view.columnsConfiguration"))+" ",1)]),_:1}),(0,r.createVNode)((0,r.unref)(dt.Gh)),(0,r.createVNode)((0,r.unref)(dt.s$),{class:"menu-reset","data-testid":"table-views-reset",disabled:C.value,onClick:W},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)((0,r.unref)(a)("tableViews.view.reset")),1)]),_:1},8,["disabled"])])]),default:(0,r.withCtx)(()=>[(0,r.createVNode)((0,r.unref)(dt.Nq),{variant:"tertiary",class:"view-control-btn","data-testid":"table-views-view-menu"},{before:(0,r.withCtx)(()=>[...n[4]||(n[4]=[(0,r.createElementVNode)("i",{class:"icon icon-gear"},null,-1)])]),default:(0,r.withCtx)(()=>[(0,r.createTextVNode)(" "+(0,r.toDisplayString)((0,r.unref)(a)("tableViews.view.label")),1)]),_:1})]),_:1},8,["aria-label"])])])}}});n(22151);const _t=(0,it.A)(xt,[["__scopeId","data-v-6012a68d"]]);var kt=_t,Ct=n(79535),At=n(38283),Tt=n(14738),Rt=n(47879),Nt=n(51433),Pt=n(25509);const It={name:"n",query:"q",columns:"c",columnOrder:"o",labelColumns:"l",groupBy:"g",sort:"s",sortDescending:"d"};function Mt(e,t){return t?`${e}@${t}`:e}function Dt(e){return e.split("@")[0]}function Lt(e){const t=(new TextEncoder).encode(e);let n="";return t.forEach(e=>{n+=String.fromCharCode(e)}),btoa(n).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")}function Bt(e){const t=atob(e.replace(/-/g,"+").replace(/_/g,"/"));return(new TextDecoder).decode(Uint8Array.from(t,e=>e.charCodeAt(0)))}const $t=e=>Array.isArray(e)&&e.every(e=>"string"===typeof e),Vt=e=>"string"===typeof e&&e?e:null;function Ft(e){const t={};return Object.keys(It).forEach(n=>{const r=e[n];null===r||void 0===r||""===r||!1===r||Array.isArray(r)&&!r.length||(t[It[n]]=r)}),t}function jt(e){if(!e||"object"!==typeof e)return null;const t=e,n=Vt(t[It.name]);return n?{name:n,query:Vt(t[It.query])||"",columns:$t(t[It.columns])?t[It.columns]:null,columnOrder:$t(t[It.columnOrder])?t[It.columnOrder]:null,labelColumns:$t(t[It.labelColumns])?t[It.labelColumns]:[],groupBy:Vt(t[It.groupBy]),sort:Vt(t[It.sort]),sortDescending:!0===t[It.sortDescending]}:null}function Ut(e){const t={};return Object.entries(e.tables).forEach(([e,n])=>{t[e]=Ft(n)}),Lt(JSON.stringify({k:e.key,t:t}))}function Gt(e){try{const t=JSON.parse(Bt(e.trim()));if(!t||!t.t||"object"!==typeof t.t)return null;const n={};return Object.entries(t.t).forEach(([e,t])=>{const r=jt(t);r&&(n[e]=r)}),Object.keys(n).length?{key:"string"===typeof t.k?t.k:"",tables:n}:null}catch(t){return null}}function Ht(e,t,n){return Ut({key:n||"",tables:{[e]:t}})}function qt(e,t){const n=e.trim()?Gt(e):null;if(!n)return{problem:"invalid"};const r=n.tables[t];return r?{view:r}:{problem:"otherTable",tableKey:Object.keys(n.tables)[0]}}const Qt=["data-testid"],zt={class:"share-content"},Kt=["id"],Wt={class:"share-actions"};var Xt=(0,r.defineComponent)({__name:"TableViewShareModal",props:{mode:{},value:{default:""},tableKey:{default:""},intoNewView:{type:Boolean,default:!1}},emits:["close","import"],setup(e,{emit:t}){const n=e,i=t,o=(0,s.Pj)(),{t:a}=(0,je.s)(o),l=(0,r.useId)(),c=(0,r.ref)(""),u=(0,r.computed)(()=>"share"===n.mode),d=(0,r.computed)(()=>u.value?"tableViews.share.intro":n.intoNewView?"tableViews.import.introNew":"tableViews.import.intro"),h=(0,r.computed)(()=>u.value?null:qt(c.value,n.tableKey)),p=(0,r.computed)(()=>{var e,t,r,i;const s=h.value;if(!s||!("problem"in s)||!c.value.trim())return"";if("invalid"===s.problem)return a("tableViews.import.invalid",void 0,!0);const l=Dt(s.tableKey),u=(null===(t=(e=o.getters)["cluster/schemaFor"])||void 0===t?void 0:t.call(e,l))||(null===(i=(r=o.getters)["management/schemaFor"])||void 0===i?void 0:i.call(r,l))||{id:l},d=o.getters["type-map/labelFor"](u,2);return a(l===Dt(n.tableKey)?"tableViews.import.otherPage":"tableViews.import.otherTable",{list:d},!0)}),f=(0,r.computed)(()=>!!h.value&&"view"in h.value),m=()=>{const e=h.value;e&&"view"in e&&(i("import",e.view),i("close"))};return(t,n)=>{const o=(0,r.resolveDirective)("clean-html");return(0,r.openBlock)(),(0,r.createElementBlock)("div",{class:"share-modal","data-testid":`table-views-${e.mode}-modal`},[(0,r.createElementVNode)("div",zt,[(0,r.createVNode)((0,r.unref)(Pt.m),{size:3,class:"share-title","data-modal-title":""},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)((0,r.unref)(a)(`tableViews.${e.mode}.title`)),1)]),_:1}),(0,r.createVNode)(Rt.A,{k:d.value,tag:"p",class:"share-intro"},{b:(0,r.withCtx)(({content:e})=>[(0,r.withDirectives)((0,r.createElementVNode)("b",null,null,512),[[o,e]])]),_:1},8,["k"]),u.value?((0,r.openBlock)(),(0,r.createBlock)(Tt.A,{key:0,label:(0,r.unref)(a)("tableViews.share.label"),value:e.value,"max-length":1/0,"data-testid":"table-views-share-text"},null,8,["label","value"])):((0,r.openBlock)(),(0,r.createBlock)(Tt.A,{key:1,value:c.value,"onUpdate:value":n[0]||(n[0]=e=>c.value=e),label:(0,r.unref)(a)("tableViews.share.label"),copy:!1,editable:"",paste:"",placeholder:(0,r.unref)(a)("tableViews.import.placeholder"),invalid:!!p.value,"described-by":p.value?`${(0,r.unref)(l)}-problem`:void 0,"data-testid":"table-views-import-text"},null,8,["value","label","placeholder","invalid","described-by"])),p.value?((0,r.openBlock)(),(0,r.createElementBlock)("p",{key:2,id:`${(0,r.unref)(l)}-problem`,class:"share-problem text-error","aria-live":"polite","data-testid":"table-views-import-problem"},(0,r.toDisplayString)(p.value),9,Kt)):(0,r.createCommentVNode)("",!0)]),(0,r.createElementVNode)("div",Wt,[(0,r.createVNode)((0,r.unref)(Nt.a),{variant:u.value?"primary":"link",size:"large","data-testid":`table-views-${e.mode}-close`,onClick:n[1]||(n[1]=e=>i("close"))},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)((0,r.unref)(a)("generic.close")),1)]),_:1},8,["variant","data-testid"]),u.value?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(Nt.a),{key:0,variant:"primary",size:"large",disabled:!f.value,"data-testid":"table-views-import-confirm",onClick:m},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)((0,r.unref)(a)("tableViews.import.import")),1)]),_:1},8,["disabled"]))])],8,Qt)}}});n(92421);const Yt=(0,it.A)(Xt,[["__scopeId","data-v-1f55815c"]]);var Zt=Yt;function Jt(e){return Object.fromEntries(Object.entries(e).filter(([,e])=>null!==e&&""!==e))}function en(e,t=()=>null){const n=(0,s.Pj)(),i=(0,r.computed)({get:()=>me(n.getters["prefs/get"](c.u1)),set:e=>n.dispatch("prefs/set",{key:c.u1,value:ge(e,ve(n.getters["prefs/get"](c.u1)))})}),o=(0,r.computed)(()=>{var t;const n=null===(t=i.value)||void 0===t?void 0:t[e()];return Array.isArray(n)?{views:n}:n}),a=(0,r.computed)(()=>{var e,n;return t()?null===(n=null===(e=o.value)||void 0===e?void 0:e.pages)||void 0===n?void 0:n[t()]:o.value}),l=(0,r.computed)(()=>{var e;return(null===(e=a.value)||void 0===e?void 0:e.views)||[]}),u=(0,r.computed)(()=>{var e;return(null===(e=a.value)||void 0===e?void 0:e.defaultViewId)||null}),d=(0,r.computed)(()=>{var e;const t=null===(e=a.value)||void 0===e?void 0:e.allIndex;return Math.min(Math.max(Number.isInteger(t)?t:0,0),l.value.length)}),h=(n,r,a=d.value)=>{const s=n.find(e=>e.id===r)?r:null,l=Jt({views:n.map(e=>Jt(e)),defaultViewId:s,allIndex:Math.min(Math.max(a,0),n.length)}),c=o.value||{views:[]},u={...c.pages||{}};t()&&(u[t()]=l);const h={...t()?c:l};Object.keys(u).forEach(e=>{u[e].views.length||delete u[e]}),Object.keys(u).length?h.pages=u:delete h.pages;const p={...i.value||{}};h.views.length||h.pages?p[e()]=h:delete p[e()],i.value=p},p=e=>h(e,u.value),f=(e,t)=>{let n=e,r=t;while(l.value.find(e=>e.name===n))n=`${e} ${r++}`;return n};return{savedViews:l,defaultViewId:u,allTabIndex:d,persistAll:h,persist:p,unusedViewName:f}}const tn=new Set;function nn(e){return tn.add(e),()=>{tn.delete(e)}}function rn(e,t=document.activeElement){const n=Array.from(tn).find(e=>e.owns(t));null===n||void 0===n||n.run(e)}var on=n(92043);const an={class:"view-tabs-row"},sn=["aria-label","aria-owns"],ln=["onMousedown"],cn=["size","aria-label","data-testid","onKeydown"],un=["id","aria-selected","tabindex","data-testid","onClick","onKeydown"],dn={key:0,class:"unsaved-dot","data-testid":"table-views-unsaved"},hn={class:"menu-notice"},pn={class:"menu-shortcut"},fn={class:"menu-shortcut"},mn={class:"menu-shortcut"},gn=56,vn=12,bn=1200,yn=600,wn=1e4,On=1;var Sn=(0,r.defineComponent)({__name:"TableViewTabs",props:{view:{},viewCounts:{default:()=>({})},matchCount:{default:0},resourceType:{default:""},tableViewsPage:{default:null},initialViewId:{}},emits:["update:view","export","tab-queries"],setup(e,{emit:t}){function n(e){return e.id||"all"}const i=e,o=t,a=(0,s.Pj)(),{t:l}=(0,je.s)(a),{savedViews:u,defaultViewId:d,allTabIndex:h,persistAll:p,persist:f,unusedViewName:m}=en(()=>i.resourceType,()=>i.tableViewsPage),g=(0,r.computed)(()=>Mt(i.resourceType,i.tableViewsPage)),v=(0,r.ref)(null),b=(0,r.ref)(null),y=new Map,w=new Map,O=new Map,S=new Map,E=(e,t,n)=>{n?e.set(t,n):e.delete(t)},x=(0,r.ref)(i.initialViewId),_=(0,r.ref)({}),k=(0,r.ref)(null),C=(0,r.ref)(null),A=(0,r.ref)(""),T=(0,r.ref)(null),R=(0,r.ref)(null),N=(0,r.ref)(null);let P,I=0,M=0;const D=(0,r.computed)(()=>{const e=ut.cX?"⌘":"Ctrl";return{save:(0,ut.hV)([e,"S"]),saveAsNew:(0,ut.hV)([e,"Shift","S"]),duplicate:(0,ut.hV)([e,"D"])}}),L=(0,r.computed)(()=>{const e={id:null,name:l("tableViews.tabs.all"),isDefaultTab:!0},t=u.value.map(e=>({id:e.id,name:e.name,view:e}));t.splice(h.value,0,e);const n=t.findIndex(e=>{var t;return d.value?(null===(t=e.view)||void 0===t?void 0:t.id)===d.value:e.isDefaultTab});return n<=0?t:[t[n]].concat(t.filter((e,t)=>t!==n))}),B=(0,r.computed)(()=>{if(!ie.value)return L.value;const e={};return L.value.forEach(t=>{e[n(t)]=t}),ie.value.map(t=>e[t]).filter(Boolean)}),$=(0,r.computed)(()=>Ee(u.value,i.view,x.value)),V=(0,r.computed)(()=>{var e;const t=B.value||[],n=t.find(e=>e.id===$.value);return null===(e=n||t[0])||void 0===e?void 0:e.id}),F=(0,r.computed)(()=>xe(u.value,i.view,x.value)),j=e=>e||"__default",U=e=>{var t;if(e.id===$.value)return i.view.query||"";const n=_.value[j(e.id)];return(n?n.query:null===(t=e.view)||void 0===t?void 0:t.query)||""},G=(0,r.computed)(()=>Array.from(new Set(B.value.map(e=>U(e))))),H=e=>i.viewCounts[U(e)],q=e=>{const t=H(e);return void 0===t||null===t?e.name:l("tableViews.tabs.count",{name:e.name,count:t})},Q=e=>e.id===$.value?F.value:!!_.value[j(e.id)],z=e=>{const t=v.value;if(!(null===t||void 0===t?void 0:t.closest)||!(e instanceof Element))return!1;const n=e=>e.closest(".has-table-views")||e.closest(".fixed-header-actions"),r=n(t);return!!r&&n(e)===r},K=e=>y.get(n(e)),W=e=>w.get(n(e)),X=(0,r.useId)(),Y=e=>`${X}-${n(e)}`,Z=e=>{const t=O.get(n(e));return t instanceof Element?t:null===t||void 0===t?void 0:t.$el},J=()=>{R.value=null},ee=()=>{var e;const t=null===(e=b.value)||void 0===e?void 0:e.querySelector(".view-tabs-list");if(!t)return;const n=t.getBoundingClientRect().left,r=L.value.map(e=>{var t;const r=null===(t=K(e))||void 0===t?void 0:t.getBoundingClientRect();return r?{left:r.left-n,right:r.right-n}:null}).filter(Boolean);T.value=r.slice(0,-1).map((e,t)=>(e.right+r[t+1].left)/2)},te=e=>{var t;const n=null===(t=b.value)||void 0===t?void 0:t.querySelector(".view-tabs-list");if(!n)return 0;const r=e-n.getBoundingClientRect().left,i=T.value||[];let o=0;while(o<i.length&&r>=i[o])o++;return o},ne=()=>{const e=()=>{if(!oe.value)return;const t=b.value;if(t){const e=t.getBoundingClientRect();ae.value<e.left+gn?(t.scrollLeft-=vn,le()):ae.value>e.right-gn&&(t.scrollLeft+=vn,le())}M=requestAnimationFrame(e)};cancelAnimationFrame(M),M=requestAnimationFrame(e)},{heldId:re,order:ie,moved:oe,pointer:ae,start:se,place:le}=ct({axis:"x",initialOrder:()=>L.value.map(n),measure:ee,indexAt:te,firstMovable:()=>On,onBegin:()=>{var e;J(),null===(e=window.getSelection())||void 0===e||e.removeAllRanges(),ne()},onEnd:()=>{cancelAnimationFrame(M),T.value=null},onCommit:e=>{const t={};u.value.forEach(e=>{t[e.id]=e}),p(e.map(e=>t[e]).filter(Boolean),d.value,e.indexOf("all"))}}),ce=(e,t)=>{const r=n(e);0!==t.button||C.value||L.value.findIndex(e=>n(e)===r)<On||se(r,t)},ue=e=>{const t=j(e);if(!_.value[t])return;const n={..._.value};delete n[t],_.value=n},de=e=>{const t=j(e);F.value?_.value={..._.value,[t]:{...i.view}}:ue(e)},he=e=>({query:(null===e||void 0===e?void 0:e.query)||"",columns:(null===e||void 0===e?void 0:e.columns)||null,columnOrder:(null===e||void 0===e?void 0:e.columnOrder)||null,labelColumns:(null===e||void 0===e?void 0:e.labelColumns)||[],groupBy:(null===e||void 0===e?void 0:e.groupBy)||null,sort:(null===e||void 0===e?void 0:e.sort)||null,sortDescending:(null===e||void 0===e?void 0:e.sortDescending)||!1}),pe=(e,t=!0)=>{const n=$.value,r=(null===e||void 0===e?void 0:e.id)||null,i=n!==r;if(!i&&t)return void(x.value=r);i&&de(n),x.value=r;const a=t?_.value[j(r)]:null;o("update:view",a?{...a}:he(e))},fe=()=>(B.value||[]).find(e=>e.id===$.value),me=e=>e.id===$.value?{...i.view}:_.value[j(e.id)]||he(e.view),ge=e=>{const t=(null===e||void 0===e?void 0:e.id)||null,n=_.value[j(t)];x.value=t,o("update:view",n?{...n}:he(null===e||void 0===e?void 0:e.view))},be=(e=fe())=>{e&&(ue(e.id),e.id===$.value&&pe(e.view||null,!1))},ye=(e,t=!1)=>{(0,r.nextTick)(()=>{const n=(B.value||[]).find(t=>t.id===e),r=n&&W(n);r&&(r.focus({preventScroll:!!t}),t?requestAnimationFrame(()=>{const e=b.value;e&&(e.scrollLeft=e.scrollWidth)}):r.scrollIntoView({block:"nearest",inline:"nearest"}))})},we=e=>{(null===e||void 0===e?void 0:e.id)&&(C.value=e.id,A.value=e.name||"",(0,r.nextTick)(()=>{const t=S.get(e.id);null===t||void 0===t||t.focus(),null===t||void 0===t||t.select()}))},Se=()=>m(l("tableViews.tab.newViewName"),1),_e=e=>{const t=m(`${e.name} ${l("tableViews.tab.copySuffix")}`,2),n={...e,id:(0,on.vx)(8),name:t};f(u.value.concat([n])),pe(n),ye(n.id,!0),(0,r.nextTick)(()=>we(n))},ke=(e=fe())=>{e&&(Q(e)||void 0!==x.value)&&_e({...he(me(e)),name:e.name})},Ce=(e=fe())=>{if(!(null===e||void 0===e?void 0:e.view)||!Q(e))return;const t=he(me(e));f(u.value.map(n=>{var r;return n.id===(null===(r=e.view)||void 0===r?void 0:r.id)?{...n,...t}:n})),ue(e.id)},Ae=()=>{const e={...he(),id:(0,on.vx)(8),name:Se()};return f(u.value.concat([e])),pe(e),ye(e.id,!0),e},Te=e=>{pe(e.view||null),ye(e.id)},Re=e=>{const t=B.value||[];if(t.length<2)return;const n=t.findIndex(e=>W(e)===document.activeElement),r=n>=0?n:t.findIndex(e=>e.id===V.value),i=t[((r<0?0:r)+e+t.length)%t.length];Te(i)},Ne=e=>{const t=B.value||[],n="first"===e?t[0]:t[t.length-1];n&&Te(n)},Pe=e=>{const t=Z(e);t&&(t.dispatchEvent(new KeyboardEvent("keydown",{key:"Enter",bubbles:!0})),t.click())},Ie=(e,t)=>{R.value=t?n(e):null,t||(0,r.nextTick)(()=>{var t;document.activeElement===Z(e)&&(null===(t=W(e))||void 0===t||t.focus())})},Me=(e,t)=>{clearTimeout(P),cancelAnimationFrame(I);const n=Date.now()+bn,r=()=>{e.scrollLeft>1&&Date.now()<n?I=requestAnimationFrame(r):(N.value=t,P=setTimeout(()=>{N.value=null},yn))};r()},De=()=>{const e=C.value,t=(A.value||"").trim(),n=u.value.find(t=>t.id===e);C.value=null,A.value="",t&&n&&t!==n.name&&f(u.value.map(n=>n.id===e?{...n,name:t}:n))},Le=()=>{C.value=null,A.value=""},Be=e=>{if(e.id===$.value)return void(k.value={kind:"export",name:e.name,count:i.matchCount});const t=_.value[j(e.id)],n=e.view,r=H(e);k.value={kind:"export",name:e.name,count:"number"===typeof r?r:null,view:t?{...t}:he(n)}},$e=e=>{const t={...he(me(e)),name:e.name};k.value={kind:"share",text:Ht(g.value,t,ve(a.getters["prefs/get"](c.u1)))}},Ve=e=>{k.value={kind:"import",tabId:e.id}},Fe=()=>{k.value=null},Ue=e=>{_e(e.view||{...he(),name:l("tableViews.tabs.all")})},Ge=e=>{const t=he();if(e.id===$.value)return x.value=e.id,void o("update:view",t);Oe(he(e.view))?_.value={..._.value,[j(e.id)]:t}:ue(e.id)},He=()=>{const e=B.value.find(e=>e.id===$.value);e&&Ue(e)},qe=e=>{var t,i;p(u.value,e.isDefaultTab?null:(null===(t=e.view)||void 0===t?void 0:t.id)||null);const o=n(e.isDefaultTab?{id:null}:{id:null===(i=e.view)||void 0===i?void 0:i.id});(0,r.nextTick)(()=>{const e=b.value;e&&(e.scrollTo({left:0,behavior:"smooth"}),Me(e,o))})},Qe=e=>{var t;return e.isDefaultTab?!d.value:d.value===(null===(t=e.view)||void 0===t?void 0:t.id)},ze=e=>{if(!e)return;const t=$.value===e.id,n=d.value===e.id,r=u.value.findIndex(t=>t.id===e.id),i=r>=0&&r<h.value,o=_.value[j(e.id)],s=B.value||[],c=s.findIndex(t=>t.id===e.id),f=s[c>0?c-1:c+1];ue(e.id),p(u.value.filter(t=>t.id!==e.id),d.value,h.value-(i?1:0)),t&&ge(f),f&&ye(f.id),a.dispatch("growl/success",{title:l("tableViews.tab.deleted"),message:l("tableViews.tab.deletedMessage",{name:e.name},!0),timeout:wn,action:{label:l("tableViews.tab.undo"),run:()=>{const a=[...u.value],s=Math.min(Math.max(r,0),a.length),l=h.value,c=s<l||s===l&&i;a.splice(s,0,e),p(a,n?e.id:d.value,l+(c?1:0)),o&&(_.value={..._.value,[j(e.id)]:o}),t&&pe(e)}}})},Ke=e=>{var t;const n="export"===(null===(t=k.value)||void 0===t?void 0:t.kind)?k.value:null,r=(null===n||void 0===n?void 0:n.name)||l("tableViews.tabs.all");o("export",{format:e,name:r,view:null===n||void 0===n?void 0:n.view}),Fe()},We=(e,t)=>{const n=(B.value||[]).find(t=>t.id===e);if(!(null===n||void 0===n?void 0:n.view))return;const r=he(t);n.id===$.value?(x.value=n.id,o("update:view",r)):(_.value={..._.value,[j(n.id)]:r},pe(n.view)),ye(n.id)},Xe=e=>{var t;if("import"!==(null===(t=k.value)||void 0===t?void 0:t.kind))return;const{tabId:n}=k.value;Fe(),(0,r.nextTick)(()=>setTimeout(()=>{if(n)return void We(n,e);const t=Ae();(0,r.nextTick)(()=>We(t.id,e))}))},Ye={saveChanges:Ce,openSaveAsNew:ke,duplicateCurrent:He};(0,r.watch)(G,e=>o("tab-queries",e),{immediate:!0});let Ze=null;return(0,r.onMounted)(()=>{Ze=nn({owns:z,run:e=>Ye[e]()})}),(0,r.onBeforeUnmount)(()=>{null===Ze||void 0===Ze||Ze(),clearTimeout(P),cancelAnimationFrame(I)}),(e,t)=>{const n=(0,r.resolveDirective)("clean-tooltip");return(0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,null,[(0,r.createElementVNode)("div",{ref_key:"root",ref:v,class:"table-views","data-testid":"table-views-tabs"},[(0,r.createElementVNode)("div",an,[(0,r.createElementVNode)("div",{role:"tablist","aria-label":(0,r.unref)(l)("tableViews.tabs.label"),"aria-owns":B.value.map(Y).join(" ")},null,8,sn),(0,r.createElementVNode)("div",{ref_key:"tabStrip",ref:b,class:"view-tabs",onScroll:J},[(0,r.createVNode)(r.TransitionGroup,{tag:"div",name:"view-tab",class:(0,r.normalizeClass)(["view-tabs-list",{"is-reordering":null!==(0,r.unref)(re)}])},{default:(0,r.withCtx)(()=>[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(B.value,e=>((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:e.id||"all",ref_for:!0,ref:t=>E((0,r.unref)(y),e.id||"all",t),class:(0,r.normalizeClass)(["view-tab-wrap",{active:$.value===e.id,held:(0,r.unref)(re)===(e.id||"all"),flash:N.value===(e.id||"all")}]),onMousedown:t=>ce(e,t)},[e.isDefaultTab||C.value!==e.id?((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:1,id:Y(e),ref_for:!0,ref:t=>E((0,r.unref)(w),e.id||"all",t),type:"button",role:"tab",class:"view-tab","aria-selected":$.value===e.id,tabindex:e.id===V.value?0:-1,"data-testid":e.isDefaultTab?"table-views-tab-all":`table-views-tab-${e.id}`,onClick:t=>pe(e.view||null),onKeydown:[t[2]||(t[2]=(0,r.withKeys)((0,r.withModifiers)(e=>Re(-1),["prevent"]),["left"])),t[3]||(t[3]=(0,r.withKeys)((0,r.withModifiers)(e=>Re(1),["prevent"]),["right"])),t[4]||(t[4]=(0,r.withKeys)((0,r.withModifiers)(e=>Ne("first"),["prevent"]),["home"])),t[5]||(t[5]=(0,r.withKeys)((0,r.withModifiers)(e=>Ne("last"),["prevent"]),["end"])),(0,r.withKeys)((0,r.withModifiers)(t=>Pe(e),["prevent"]),["down"])]},[(0,r.createTextVNode)((0,r.toDisplayString)(q(e))+" ",1),Q(e)?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("span",dn,null,512)),[[n,(0,r.unref)(l)("tableViews.view.unsavedShort")]]):(0,r.createCommentVNode)("",!0)],40,un)):(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("input",{key:0,ref_for:!0,ref:t=>E((0,r.unref)(S),e.id||"",t),"onUpdate:modelValue":t[0]||(t[0]=e=>A.value=e),type:"text",class:"view-tab rename-input",size:Math.max(A.value.length,4),"aria-label":(0,r.unref)(l)("tableViews.tab.rename"),"data-testid":`table-views-rename-input-${e.id}`,onKeydown:[(0,r.withKeys)((0,r.withModifiers)(De,["prevent"]),["enter"]),(0,r.withKeys)((0,r.withModifiers)(Le,["prevent"]),["esc"])],onBlur:De,onClick:t[1]||(t[1]=(0,r.withModifiers)(()=>{},["stop"]))},null,40,cn)),[[r.vModelText,A.value]]),(0,r.createVNode)((0,r.unref)(dt.Jj),{open:R.value===(e.id||"all"),placement:"bottom-start",distance:9,"reference-node":()=>K(e),"onUpdate:open":t=>Ie(e,t)},{dropdownCollection:(0,r.withCtx)(()=>[(0,r.createElementVNode)("div",{class:(0,r.normalizeClass)(["menu-panel",{"has-notice":Q(e)}])},[Q(e)?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:0},[(0,r.createElementVNode)("div",hn,[t[7]||(t[7]=(0,r.createElementVNode)("span",{class:"unsaved-dot"},null,-1)),(0,r.createTextVNode)(" "+(0,r.toDisplayString)((0,r.unref)(l)("tableViews.view.unsaved")),1)]),e.isDefaultTab?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(dt.s$),{key:0,"data-testid":"table-views-save-changes",onClick:t=>Ce(e)},{before:(0,r.withCtx)(()=>[...t[8]||(t[8]=[(0,r.createElementVNode)("i",{class:"icon icon-download"},null,-1)])]),after:(0,r.withCtx)(()=>[(0,r.createElementVNode)("span",pn,(0,r.toDisplayString)(D.value.save),1)]),default:(0,r.withCtx)(()=>[(0,r.createTextVNode)(" "+(0,r.toDisplayString)((0,r.unref)(l)("tableViews.view.saveChanges"))+" ",1)]),_:1},8,["onClick"])),(0,r.createVNode)((0,r.unref)(dt.s$),{"data-testid":"table-views-save-as-new",onClick:t=>ke(e)},{before:(0,r.withCtx)(()=>[...t[9]||(t[9]=[(0,r.createElementVNode)("i",{class:"menu-gutter"},null,-1)])]),after:(0,r.withCtx)(()=>[(0,r.createElementVNode)("span",fn,(0,r.toDisplayString)(D.value.saveAsNew),1)]),default:(0,r.withCtx)(()=>[(0,r.createTextVNode)(" "+(0,r.toDisplayString)((0,r.unref)(l)("tableViews.view.saveAsNew"))+" ",1)]),_:1},8,["onClick"]),(0,r.createVNode)((0,r.unref)(dt.s$),{"data-testid":"table-views-discard",onClick:t=>be(e)},{before:(0,r.withCtx)(()=>[...t[10]||(t[10]=[(0,r.createElementVNode)("i",{class:"menu-gutter"},null,-1)])]),default:(0,r.withCtx)(()=>[(0,r.createTextVNode)(" "+(0,r.toDisplayString)((0,r.unref)(l)("tableViews.view.discard")),1)]),_:1},8,["onClick"]),(0,r.createVNode)((0,r.unref)(dt.Gh))],64)):(0,r.createCommentVNode)("",!0),e.isDefaultTab?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(dt.s$),{key:1,"data-testid":`table-views-rename-${e.id}`,onClick:t=>we(e.view)},{before:(0,r.withCtx)(()=>[...t[11]||(t[11]=[(0,r.createElementVNode)("i",{class:"icon icon-edit"},null,-1)])]),default:(0,r.withCtx)(()=>[(0,r.createTextVNode)(" "+(0,r.toDisplayString)((0,r.unref)(l)("tableViews.tab.rename")),1)]),_:1},8,["data-testid","onClick"])),(0,r.createVNode)((0,r.unref)(dt.s$),{"data-testid":e.isDefaultTab?"table-views-duplicate-all":`table-views-duplicate-${e.id}`,onClick:t=>Ue(e)},{before:(0,r.withCtx)(()=>[...t[12]||(t[12]=[(0,r.createElementVNode)("i",{class:"icon icon-copy"},null,-1)])]),after:(0,r.withCtx)(()=>[(0,r.createElementVNode)("span",mn,(0,r.toDisplayString)(D.value.duplicate),1)]),default:(0,r.withCtx)(()=>[(0,r.createTextVNode)(" "+(0,r.toDisplayString)((0,r.unref)(l)("tableViews.tab.duplicate"))+" ",1)]),_:1},8,["data-testid","onClick"]),e.isDefaultTab?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(dt.s$),{key:2,disabled:!(0,r.unref)(Oe)(me(e)),"data-testid":`table-views-reset-${e.id}`,onClick:t=>Ge(e)},{before:(0,r.withCtx)(()=>[...t[13]||(t[13]=[(0,r.createElementVNode)("i",{class:"menu-gutter"},null,-1)])]),default:(0,r.withCtx)(()=>[(0,r.createTextVNode)(" "+(0,r.toDisplayString)((0,r.unref)(l)("tableViews.view.reset")),1)]),_:1},8,["disabled","data-testid","onClick"])),(0,r.createVNode)((0,r.unref)(dt.s$),{"data-testid":e.isDefaultTab?"table-views-export-all":`table-views-export-${e.id}`,onClick:t=>Be(e)},{before:(0,r.withCtx)(()=>[...t[14]||(t[14]=[(0,r.createElementVNode)("i",{class:"menu-gutter"},null,-1)])]),default:(0,r.withCtx)(()=>[(0,r.createTextVNode)(" "+(0,r.toDisplayString)((0,r.unref)(l)("tableViews.export.label")),1)]),_:1},8,["data-testid","onClick"]),(0,r.createVNode)((0,r.unref)(dt.s$),{class:(0,r.normalizeClass)({selected:Qe(e)}),"data-testid":e.isDefaultTab?"table-views-set-default-all":`table-views-set-default-${e.id}`,onClick:t=>qe(e)},(0,r.createSlots)({before:(0,r.withCtx)(()=>[t[15]||(t[15]=(0,r.createElementVNode)("i",{class:"menu-gutter"},null,-1))]),default:(0,r.withCtx)(()=>[(0,r.createTextVNode)(" "+(0,r.toDisplayString)((0,r.unref)(l)("tableViews.tab.setDefault"))+" ",1)]),_:2},[Qe(e)?{name:"after",fn:(0,r.withCtx)(()=>[t[16]||(t[16]=(0,r.createElementVNode)("i",{class:"icon icon-checkmark"},null,-1))]),key:"0"}:void 0]),1032,["class","data-testid","onClick"]),(0,r.createVNode)((0,r.unref)(dt.Gh)),(0,r.createVNode)((0,r.unref)(dt.s$),{"data-testid":e.isDefaultTab?"table-views-share-all":`table-views-share-${e.id}`,onClick:t=>$e(e)},{before:(0,r.withCtx)(()=>[...t[17]||(t[17]=[(0,r.createElementVNode)("i",{class:"menu-gutter"},null,-1)])]),default:(0,r.withCtx)(()=>[(0,r.createTextVNode)(" "+(0,r.toDisplayString)((0,r.unref)(l)("tableViews.tab.shareView")),1)]),_:1},8,["data-testid","onClick"]),(0,r.createVNode)((0,r.unref)(dt.s$),{"data-testid":e.isDefaultTab?"table-views-import-all":`table-views-import-${e.id}`,onClick:t=>Ve(e)},{before:(0,r.withCtx)(()=>[...t[18]||(t[18]=[(0,r.createElementVNode)("i",{class:"menu-gutter"},null,-1)])]),default:(0,r.withCtx)(()=>[(0,r.createTextVNode)(" "+(0,r.toDisplayString)((0,r.unref)(l)("tableViews.tab.importView")),1)]),_:1},8,["data-testid","onClick"]),e.isDefaultTab?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:3},[(0,r.createVNode)((0,r.unref)(dt.Gh)),(0,r.createVNode)((0,r.unref)(dt.s$),{"data-testid":`table-views-delete-${e.id}`,onClick:t=>ze(e.view)},{before:(0,r.withCtx)(()=>[...t[19]||(t[19]=[(0,r.createElementVNode)("i",{class:"icon icon-trash"},null,-1)])]),default:(0,r.withCtx)(()=>[(0,r.createTextVNode)(" "+(0,r.toDisplayString)((0,r.unref)(l)("tableViews.tab.delete")),1)]),_:1},8,["data-testid","onClick"])],64))],2)]),default:(0,r.withCtx)(()=>[(0,r.createVNode)((0,r.unref)(dt.Nq),{ref_for:!0,ref:t=>E((0,r.unref)(O),e.id||"all",t),variant:"link",class:"view-tab-caret",tabindex:"-1","aria-label":(0,r.unref)(l)("tableViews.tab.menu"),"data-testid":e.isDefaultTab?"table-views-tab-menu-all":`table-views-tab-menu-${e.id}`},{default:(0,r.withCtx)(()=>[...t[6]||(t[6]=[(0,r.createElementVNode)("i",{class:"icon icon-chevron-down"},null,-1)])]),_:1},8,["aria-label","data-testid"])]),_:2},1032,["open","reference-node","onUpdate:open"])],42,ln))),128))]),_:1},8,["class"]),(0,r.createElementVNode)("button",{type:"button",class:"view-tab new-view-tab","data-testid":"table-views-new-tab",onClick:Ae},[t[20]||(t[20]=(0,r.createElementVNode)("i",{class:"icon icon-plus"},null,-1)),(0,r.createTextVNode)(" "+(0,r.toDisplayString)((0,r.unref)(l)("tableViews.tabs.newView")),1)])],544)])],512),k.value&&"export"===k.value.kind?((0,r.openBlock)(),(0,r.createBlock)(Ct.h,{key:0,name:"tableViewsExportModal",width:640,height:"auto","trigger-focus-trap":!0,onClose:Fe},{default:(0,r.withCtx)(()=>[(0,r.createVNode)(At["default"],{count:k.value.count,"view-name":k.value.name,onClose:Fe,onExport:Ke},null,8,["count","view-name"])]),_:1})):k.value?((0,r.openBlock)(),(0,r.createBlock)(Ct.h,{key:1,name:"share"===k.value.kind?"tableViewsShareModal":"tableViewsImportModal",width:640,height:"auto","trigger-focus-trap":!0,onClose:Fe},{default:(0,r.withCtx)(()=>[(0,r.createVNode)(Zt,{mode:k.value.kind,value:"share"===k.value.kind?k.value.text:"","table-key":g.value,"into-new-view":"import"===k.value.kind&&!k.value.tabId,onClose:Fe,onImport:Xe},null,8,["mode","value","table-key","into-new-view"])]),_:1},8,["name"])):(0,r.createCommentVNode)("",!0)],64)}}});n(93386);const En=(0,it.A)(Sn,[["__scopeId","data-v-3990a09b"]]);var xn=En,_n=n(4364);const kn="namespace",Cn="metadata.namespace",An=(e,t)=>{if(!e)return null;const n=e.id;let r=n;const i=t.getters["currentStore"](n),o=t.getters[`${i}/currentGeneration`]?.(n);o&&(r+=`/${o}`);const a=t.getters["activeNamespaceCacheKey"];return a?`${r}/${a}`:r};var Tn={name:"ResourceTable",emits:["clickedActionButton","group-change"],components:{ButtonGroup:u.A,SortableTable:d.A,TableViewControls:kt,TableViewTabs:xn,ToggleSwitch:v.j},mixins:[$e,Le],props:{schema:{type:Object,default:null},rows:{type:Array,required:!0},loading:{type:Boolean,required:!1},altLoading:{type:Boolean,required:!1},keyField:{type:String,default:"_key"},headers:{type:Array,default:null},namespaced:{type:Boolean,default:null},search:{type:Boolean,default:!0},tableActions:{type:[Boolean,null],default:null},pagingLabel:{type:String,default:"sortableTable.paging.resource"},pagingParams:{type:Object,default:null},rowActions:{type:Boolean,default:!0},groupBy:{type:String,default:null},groupSort:{type:String,default:null},groupOptions:{type:Array,default:null},groupRef:{type:[String,Function],default:null},groupable:{type:Boolean,default:null},groupDefault:{type:String,default:kn},groupTooltip:{type:String,default:"resourceTable.groupBy.namespace"},overflowX:{type:Boolean,default:!1},overflowY:{type:Boolean,default:!1},sortGenerationFn:{type:Function,default:null},getCustomDetailLink:{type:Function,default:null},ignoreFilter:{type:Boolean,default:!1},hasAdvancedFiltering:{type:Boolean,default:!1},advFilterHideLabelsAsCols:{type:Boolean,default:!1},advFilterPreventFilteringLabels:{type:Boolean,default:!1},useQueryParamsForSimpleFiltering:{type:Boolean,default:!1},forceUpdateLiveAndDelayed:{type:Number,default:0},externalPaginationEnabled:{type:Boolean,default:!1},externalPaginationResult:{type:Object,default:null},rowsPerPage:{type:Number,default:null},overrideInStore:{type:String,default:void 0},externalPaginationArgs:{type:Object,default:null},externalPaginationScope:{type:Object,default:null}},data(){const e=this.overrideInStore||(this.schema?.id?this.$store.getters["currentStore"](this.schema.id):void 0);return{inStore:e,sortGeneration:void 0,listAutoRefreshToggleEnabled:Ve.A.listAutoRefreshToggleEnabled({rootGetters:this.$store.getters}),hasSearchFilter:!1}},watch:{filteredRows:{handler(){this.currentProduct.showWorkspaceSwitcher&&(this.sortGeneration=this.safeSortGenerationFn(this.schema,this.$store))},immediate:!0},group:{handler(e){this.$emit("group-change",e)},immediate:!0}},computed:{options(){return this.$store.getters["type-map/optionsFor"](this.schema,this.externalPaginationEnabled)},_listGroupMapped(){return this.options?.listGroups?.reduce((e,t)=>(e[t.value]=t,e),{})},_mandatorySort(){return this.options?.listMandatorySort},...(0,s.L8)(["currentProduct"]),isNamespaced(){return null!==this.namespaced?this.namespaced:!!(0,l.Jt)(this.schema,"attributes.namespaced")},showNamespaceColumn(){const e="namespace"===this.group&&!this.showTableViews,t=!this.showGrouping||!e;return t},_showBulkActions(){if(null!==this.tableActions)return this.tableActions;if(this.schema){const e=this.$store.getters["type-map/hideBulkActionsFor"](this.schema);return!e}return!1},_headers(){let e;const t=this.showNamespaceColumn;if(e=this.headers?this.headers.slice():this.$store.getters["type-map/headersFor"](this.schema,this.externalPaginationEnabled),this.$store.$extension?.getUIConfig){const t=(0,g.A)(this,m.c7.TABLE_COL,m.W3.RESOURCE,this.$route);t.forEach(t=>{let{column:n,paginationColumn:r}=t;this.externalPaginationEnabled&&(r?n=r:(!1===n.search||"string"===typeof n.search||Array.isArray(n.search)||"string"===typeof n.value||(_n.warn(`Unable to support server-side search for extension provided column "${n.name||n.label||n.labelKey}" (column must provide \`search\` or \`value\` property containing a path to a property in the resource. search can be an array).`),n.search=!1),!1===n.sort||"string"===typeof n.sort||Array.isArray(n.sort)||(_n.warn(`Unable to support server-side sort for extension provided column "${n.name||n.label||n.labelKey}" (column must provide \`sort\` property containing a path to a property, or array of paths, in the resource)`),n.sort=!1))),!n.value&&n.getValue&&(n.value=n.getValue);let i=e.length;if(e.length>0){const t=e.findIndex(e=>e.name===h.K.name);if(t>=0)i=t+1;else{const t=e.findIndex(e=>(!e.label||!e.label?.trim())&&(!e.labelKey||!e.labelKey?.trim()));t>=0&&(i=t)}}n.weight&&(n.weight<0?i=0:n.weight<i&&(i=n.weight)),e.splice(i,0,n)})}if(!t){const t=e.findIndex(e=>e.name===h.CU.name);t>=0&&e.splice(t,1)}const n=this._listGroupMapped?.[this.group];let r;if(n?.hideColumn)r=n.hideColumn;else{const e=this.groupOptions?.find(e=>e.value===this.group);r=e?.hideColumn}if(r&&!this.showTableViews){const t=e.findIndex(e=>e.name===r);t>=0&&e.splice(t,1)}return e},_applicableExtensionTableHooks(){if(this.$store.$extension?.getUIConfig){const e=(0,g.A)(this,m.c7.TABLE,m.vH.RESOURCE,this.$route);return e}return[]},filteredRows(){const e=this.$store.getters["isAllNamespaces"];if(!this.isNamespaced||this.ignoreFilter||this.externalPaginationEnabled||e&&!this.currentProduct?.hideSystemResources||this.inStore&&this.$store.getters[`${this.inStore}/haveNamespace`](this.schema.id)?.length)return this.rows||[];const t=this.$store.getters["namespaces"]();if(!this.rows)return[];const n=this.$store.getters["haveAllNamespace"];return this.rows.filter(e=>this.currentProduct?.hideSystemResources&&this.isNamespaced?!!t[e.metadata.namespace]&&!e.isSystemResource:!this.isNamespaced||(!!n||!!t[e.metadata.namespace]))},_group:(0,c.AN)(c.EI),group:{get(){if(this.showTableViews)return this.viewTableGrouping?.value||"none";const e=this._groupOptions.find(e=>e.value===this._group);return e?this._group:this._groupOptions.find(e=>e.value===this.groupDefault)?this.groupDefault:this._groupOptions[0]?.value||this.groupDefault||kn},set(e){this._group=e}},showGrouping(){if(null===this.groupable){const e=this.$store.getters["isMultipleNamespaces"]&&this.isNamespaced,t=!!this.options?.listGroups?.length;return e||t||this.groupOptions?.length}return this.groupable||!1},computedGroupBy(){if(this.viewGroupField){const e=this.viewGroupField,t=this.t("tableViews.group.empty");return e.byMonth?n=>{const r=(0,b.MK)((0,b.ag)(n,e));return/^\d{4}-\d{2}/.test(r)?r.slice(0,7):t}:n=>(0,b.ng)((0,b.ag)(n,e))||t}if(!this.showGrouping)return null;if(this.groupBy)return this.groupBy;if("namespace"===this.group)return"groupByLabel";const e=this._listGroupMapped?.[this.group];if(e?.field)return e.field;const t=this.groupOptions?.find(e=>e.value===this.group);return t?.field?t.field:null},computedGroupRef(){const e=this.viewGroupField,t=this.computedGroupBy;return e&&"function"===typeof t?e.byMonth?e=>(0,b.jf)(t(e)):t:this.groupRef},tableGroupings(){return this.showGrouping?this._groupOptions.filter(e=>"none"!==e.value).map(e=>e.value!==kn||e.field||e.hideColumn?e:{...e,hideColumn:h.CU.name}):[]},defaultGroupBy(){if(!this.showGrouping)return null;const e=e=>this.tableGroupings.find(t=>t.value===e),t=e(this.groupDefault)||e(kn)||e(Cn)||this.tableGroupings[0];return!t||this.groupBy&&!t.field?null:`${Pe}${t.value}`},_groupOptions(){if(this.groupOptions)return this.groupOptions;if(this.options?.listGroupsWillOverride&&this.options?.listGroups?.length)return this.options?.listGroups;const e=[{tooltipKey:"resourceTable.groupBy.none",icon:"icon-list-flat",value:"none"}];return this.options?.hiddenNamespaceGroupButton||e.push({tooltipKey:this.groupTooltip,icon:"icon-folder",value:"namespace"}),this.options?.listGroups?.length?e.concat(this.options.listGroups):e},parsedPagingParams(){return this.pagingParams?this.pagingParams:this.schema?{singularLabel:this.$store.getters["type-map/labelFor"](this.schema),pluralLabel:this.$store.getters["type-map/labelFor"](this.schema,99)}:{singularLabel:"",pluralLabel:""}},selectAllLabel(){return this.parsedPagingParams.pluralLabel},namespaceCounts(){if(!this.inStore||!this.schema?.id)return{};const e=this.$store.getters[`${this.inStore}/all`](p.i2)?.[0]?.counts||{};return e[this.schema.id]?.namespaces||{}},showNamespaceCounts(){return("namespace"===this.group||"metadata.namespace"===this.group)&&this.isNamespaced&&!this.hasSearchFilter&&!this.viewGroupField}},methods:{tableViewShortcut(e){rn(e)},keyAction(e){const t=this.$refs.table;if(!t)return;const n=t.selectedRows;if("remove"===e){const e=(0,f.jq)(t.availableActions,"action","promptRemove");return void(e&&(t.setBulkActionOfInterest(e),t.applyTableAction(e)))}if(1===n.length)switch(e){case"detail":n[0].goToDetail();break;case"edit":n[0].goToEdit();break;case"yaml":n[0].goToViewYaml();break}},clearSelection(){this.$refs.table.clearSelection()},safeSortGenerationFn(){return this.sortGenerationFn?this.sortGenerationFn(this.schema,this.$store):An(this.schema,this.$store)},handleActionButtonClick(e){this.$emit("clickedActionButton",e)},handleEnterKeyPress(e){"Enter"===e.key&&this.keyAction("detail")},handleSortableTableInteraction(e){this._applicableExtensionTableHooks?.length&&this._applicableExtensionTableHooks.forEach(t=>{t.tableHook&&t.tableHook(e)}),this.hasSearchFilter=!!e?.filtering?.searchQuery,this.recordSort(e?.sorting)}}};n(66397);const Rn=(0,it.A)(Tn,[["render",a],["__scopeId","data-v-7a818782"]]);var Nn=Rn},67100:function(e,t,n){"use strict";n.d(t,{A:function(){return S}});var r=n(9274);const i={class:"root resource-yaml flex-content"},o=["disabled"];function a(e,t,n,a,s,l){const c=(0,r.resolveComponent)("YamlEditor"),u=(0,r.resolveComponent)("FileSelector"),d=(0,r.resolveComponent)("t"),h=(0,r.resolveComponent)("Footer");return(0,r.openBlock)(),(0,r.createElementBlock)("div",i,[(0,r.createVNode)(c,{ref:"yamleditor",value:s.currentYaml,"onUpdate:value":t[0]||(t[0]=e=>s.currentYaml=e),mode:n.mode,"initial-yaml-values":s.initialYaml,class:"yaml-editor flex-content","editor-mode":l.editorMode,onOnReady:l.onReady},null,8,["value","mode","initial-yaml-values","editor-mode","onOnReady"]),(0,r.renderSlot)(e.$slots,"yamlFooter",{currentYaml:s.currentYaml,showPreview:s.showPreview,yamlPreview:l.preview,yamlSave:l.save,yamlUnpreview:l.unpreview,canDiff:l.canDiff},()=>[n.showFooter?((0,r.openBlock)(),(0,r.createBlock)(h,{key:0,class:(0,r.normalizeClass)(["footer",{edit:!l.isView}]),mode:n.mode,errors:n.showErrors?s.errors:[],onCloseError:l.closeError,onSave:l.save,onDone:l.done},(0,r.createSlots)({_:2},[l.isView?void 0:{name:"left",fn:(0,r.withCtx)(()=>[(0,r.createVNode)(u,{variant:"secondary",label:e.t("generic.readFromFile"),onSelected:l.onFileSelected},null,8,["label","onSelected"])]),key:"0"},l.isView?void 0:{name:"middle",fn:(0,r.withCtx)(()=>[s.showPreview?((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:0,type:"button",class:"btn role-secondary",onClick:t[1]||(t[1]=(...e)=>l.unpreview&&l.unpreview(...e))},[(0,r.createVNode)(d,{k:"resourceYaml.buttons.continue"})])):n.offerPreview?((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:1,disabled:!l.canDiff,type:"button",class:"btn role-secondary",onClick:t[2]||(t[2]=(...e)=>l.preview&&l.preview(...e))},[(0,r.createVNode)(d,{k:"resourceYaml.buttons.diff"})],8,o)):(0,r.createCommentVNode)("",!0)]),key:"1"}]),1032,["class","mode","errors","onCloseError","onSave","onDone"])):(0,r.createCommentVNode)("",!0)],!0)])}var s=n(20246),l=n.n(s),c=n(22247),u=n(57388),d=n(63854),h=n(65707),p=n(2841),f=n(92043),m=n(74302),g=n(14220),v=n(8135),b=n(99726),y={emits:["error"],components:{Footer:h.A,FileSelector:u.Ay,YamlEditor:c.A},props:{mode:{type:String,required:!0},value:{type:Object,required:!0},initialYamlForDiff:{type:String,default:null},yaml:{type:String,required:!0},doneRoute:{type:[String,Object],default:null},offerPreview:{type:Boolean,default:!0},parentParams:{type:Object,default:null},doneOverride:{type:[Function,Object],default:null},showFooter:{type:Boolean,default:!0},showErrors:{type:Boolean,default:!0},applyHooks:{type:Function,default:null}},data(){return this.$router.applyQuery({[g.$y]:g.xz}),{initialYaml:this.initialYamlForDiff||this.yaml,currentYaml:this.yaml,showPreview:!1,errors:null,cm:null,initialReady:!0}},computed:{schema(){const e=this.$store.getters["currentStore"](this.value.type);return this.$store.getters[`${e}/schemaFor`](this.value.type)},isCreate(){return this.mode===g.YQ},isView(){return this.mode===g.nW},isEdit(){return this.mode===g.G5},editorMode(){return this.$route.query.mode===g.nW||this.isView&&(this.$route.query.mode!==g.G5||this.$route.query.mode!==g.nW)?c.j.VIEW_CODE:this.showPreview?c.j.DIFF_CODE:c.j.EDIT_CODE},canDiff(){return this.initialYaml!==this.currentYaml}},watch:{yaml(e){this.mode===g.nW&&(this.currentYaml=e)},mode(e,t){e===g.YQ&&t===g.nW&&(this.currentYaml=this.value.cleanYaml(this.yaml,e))}},methods:{onInput(e){this.currentYaml=e,this.onReady(this.cm)},onReady(e){if(this.initialReady){this.initialReady=!1,this.cm=e,this.isEdit&&(0,d.sN)(e,/^status:\s*$/);try{const t=l().load(this.currentYaml),n=Object.keys(t?.metadata?.annotations||{}),r=p.VT.map(e=>(0,f.OF)(e));let i=!1;for(const e of n){if(i)break;for(const t of r)if(e.match(t)){i=!0;break}}i&&(0,d.sN)(e,/^\s+annotations:\s*$/)}catch(t){}(0,d.sN)(e,/managedFields/),this.value?.yamlFolding&&this.value.yamlFolding.forEach(t=>(0,d.Um)(e,t)),(0,d.ji)(e)}},updateValue(e){this.$refs.yamleditor.updateValue(e)},preview(){this.updateValue(this.currentYaml),this.showPreview=!0,this.$router.applyQuery({[g.$y]:g.Qp})},unpreview(){this.showPreview=!1,this.$router.applyQuery({[g.$y]:g.xz})},async save(e){const t=this.value.yamlForSave(this.currentYaml)||this.currentYaml;try{this.applyHooks&&await this.applyHooks(v.Fm);try{await this.value.saveYaml(t,this.initialYaml)}catch(r){return n.call(this,r)}this.applyHooks&&await this.applyHooks(v.Mz),this.isCreate&&this.value.notifyGeneratedName?.(),e(!0),this.done()}catch(r){return n.call(this,r)}function n(t){if(t&&t.response&&t.response.data){const e=t.response.data;e&&e.message?this.errors=[e.message]:this.errors=[t]}else this.errors=[t];e(!1),this.$emit("error",(0,b.rz)(t))}},done(){if(this.doneOverride)return"function"===typeof this.doneOverride?this.doneOverride():this.$router.replace(this.doneOverride);this.doneRoute&&("object"!==(0,m.QP)(this.doneRoute)?this.$router.replace({name:this.doneRoute,params:{resource:this.value.type}}):this.$router.replace(this.doneRoute))},onFileSelected(e){const t=this.$refs.yamleditor;t&&t.updateValue(e)},refresh(){this.$refs.yamleditor.refresh()},closeError(e){this.errors=(this.errors||[]).filter((t,n)=>n!==e)}}},w=(n(56376),n(52686),n(47433));const O=(0,w.A)(y,[["render",a],["__scopeId","data-v-6ed28bbe"]]);var S=O},47879:function(e,t,n){"use strict";n.d(t,{A:function(){return c}});var r=n(9274),i=n(65359),o=n(70176);const a=["b","i","span","a"];var s=(0,r.defineComponent)({name:"RichTranslation",props:{k:{type:String,required:!0},tag:{type:String,default:"span"},args:{type:Object,default:()=>({})}},setup(e,{slots:t}){const n=(0,i.Pj)();return()=>{const i=n.getters["i18n/t"](e.k,e.args);if(!i||"string"!==typeof i)return(0,r.h)(e.tag,{},[i]);const s=/<([a-zA-Z0-9]+)>(.*?)<\/\1>|<([a-zA-Z0-9]+)\/>/g,l=[];let c,u=0;while(null!==(c=s.exec(i))){c.index>u&&l.push((0,r.h)("span",{innerHTML:(0,o.P)(i.substring(u,c.index))}));const e=c[1],n=c[3],d=e||n;if(d){const n=e?c[2]:"";if(t[d]){const e=t[d]({content:(0,o.P)(n)});e&&l.push(...e)}else a.includes(d.toLowerCase())?n?l.push((0,r.h)(d,{innerHTML:(0,o.P)(n,{ALLOWED_TAGS:a})})):l.push((0,r.h)(d)):l.push((0,r.h)("span",{innerHTML:(0,o.P)(c[0])}))}u=s.lastIndex}return u<i.length&&l.push((0,r.h)("span",{innerHTML:(0,o.P)(i.substring(u))})),(0,r.h)(e.tag,{},l)}}});const l=s;var c=l},76750:function(e,t,n){"use strict";n.d(t,{A:function(){return p}});var r=n(9274);const i={key:0,class:"simple-box","data-testid":"simple-box-container"},o={key:0,class:"top"},a={key:0,"data-testid":"simple-box-title"},s={class:"content"};function l(e,t,n,l,c,u){return e.shown?((0,r.openBlock)(),(0,r.createElementBlock)("div",i,[n.title||n.canClose||e.$slots.title?((0,r.openBlock)(),(0,r.createElementBlock)("div",o,[(0,r.renderSlot)(e.$slots,"title",{},()=>[n.title?((0,r.openBlock)(),(0,r.createElementBlock)("h2",a,(0,r.toDisplayString)(n.title),1)):(0,r.createCommentVNode)("",!0)],!0),n.canClose||e.pref?((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:0,class:"close-button","data-testid":"simple-box-close",onClick:t[0]||(t[0]=e=>u.closeBox(e))},[...t[1]||(t[1]=[(0,r.createElementVNode)("i",{class:"icon icon-close"},null,-1)])])):(0,r.createCommentVNode)("",!0)])):(0,r.createCommentVNode)("",!0),(0,r.createElementVNode)("div",s,[(0,r.renderSlot)(e.$slots,"default",{},void 0,!0)])])):(0,r.createCommentVNode)("",!0)}var c=n(55277),u={name:"SimpleBox",emits:["close"],mixins:[c.A],props:{title:{type:String,default:null},canClose:{type:Boolean,default:!1}},methods:{closeBox(e){this.hide(),this.$emit("close",e)}}},d=(n(79086),n(73076),n(47433));const h=(0,d.A)(u,[["render",l],["__scopeId","data-v-35fec433"]]);var p=h},33246:function(e,t,n){"use strict";n.d(t,{A:function(){return Qt}});var r=n(9274);const i=["data-testid"],o=["disabled"],a={class:"list-unstyled menu"},s=["onClick","onMouseover"],l={key:0,class:"middle"},c={key:1,class:"table-views-row"},u={key:2,class:"search row","data-testid":"search-box-filter-row"},d={key:0,class:"advanced-filters-applied"},h={class:"label"},p=["onClick"],f={key:3,ref:"advanced-filter-group",class:"advanced-filter-group"},m={class:"advanced-filter-container"},g={class:"middle-block"},v={class:"bottom-block"},b=["disabled"],y={key:4,id:"describe-filter-sortable-table",hidden:""},w={key:1,class:"sub-header-row"},O={key:1},S={key:2},E=["colspan"],x={class:"data-loading"},_={key:3},k={class:"no-rows"},C=["colspan"],A={key:4},T={class:"no-results"},R=["colspan"],N={class:"group-row"},P=["colspan"],I={class:"group-tab"},M=["data-testid","data-node-id","data-cant-run-bulk-action-of-interest"],D={key:0,class:"row-check",align:"middle"},L={key:1,class:"row-expand",align:"middle"},B=["onClick"],$=["data-title","data-testid","align","width"],V={key:4,class:"text-muted"},F={key:2},j=["data-testid"],U={key:0,class:"row-check",align:"middle"},G=["colspan"],H={key:0,class:"paging"},q=["disabled","aria-label"],Q=["alt"],z=["disabled","aria-label"],K=["alt"],W=["disabled","aria-label"],X=["alt"],Y=["disabled","aria-label"],Z=["alt"];function J(e,t,n,J,ee,te){const ne=(0,r.resolveComponent)("RcButton"),re=(0,r.resolveComponent)("ActionDropdownShell"),ie=(0,r.resolveComponent)("ActionDropdown"),oe=(0,r.resolveComponent)("TableSelectionActions"),ae=(0,r.resolveComponent)("AsyncButton"),se=(0,r.resolveComponent)("LabeledInput"),le=(0,r.resolveComponent)("LabeledSelect"),ce=(0,r.resolveComponent)("THead"),ue=(0,r.resolveComponent)("t"),de=(0,r.resolveComponent)("Checkbox"),he=(0,r.resolveComponent)("ActionMenu"),pe=(0,r.resolveComponent)("ButtonMultiAction"),fe=(0,r.resolveDirective)("clean-html"),me=(0,r.resolveDirective)("clean-tooltip"),ge=(0,r.resolveDirective)("close-popper"),ve=(0,r.resolveDirective)("trim-whitespace"),be=(0,r.resolveDirective)("ui-context"),ye=(0,r.resolveDirective)("shortkey");return(0,r.openBlock)(),(0,r.createElementBlock)("div",{ref:"container",class:(0,r.normalizeClass)({"has-table-views":te.useTableViewsLayout}),"data-testid":n.componentTestid+"-list-container"},[(0,r.createElementVNode)("div",{class:(0,r.normalizeClass)([{titled:e.$slots.title&&e.$slots.title.length},"sortable-table-header"])},[(0,r.renderSlot)(e.$slots,"title",{},void 0,!0),te.showHeaderRow?((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:0,class:(0,r.normalizeClass)(["fixed-header-actions",{button:!!e.$slots["header-button"],"with-sub-header":!!e.$slots["sub-header-row"],"advanced-filtering":e.hasAdvancedFiltering,"table-views-layout":te.useTableViewsLayout,"no-top-row":te.tableViewsTopRowEmpty,"no-views-row":te.tableViewsTabsEmpty}])},[(0,r.createElementVNode)("div",{class:(0,r.normalizeClass)([e.bulkActionsClass,"bulk"])},[(0,r.renderSlot)(e.$slots,"header-left",{},()=>[n.tableActions&&!te.useTableViewsLayout?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:0},[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(e.availableActions,i=>(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createBlock)(ne,{id:i.action,key:i.action,type:"button",variant:"primary",class:(0,r.normalizeClass)({[e.bulkActionClass]:!0}),disabled:!i.enabled,"data-testid":n.componentTestid+"-"+i.action,"aria-label":i.label,onClick:t=>e.applyTableAction(i,null,t),onKeydown:t[0]||(t[0]=(0,r.withKeys)((0,r.withModifiers)(()=>{},["stop"]),["enter"])),onMouseover:e=>te.setBulkActionOfInterest(i),onMouseleave:t[1]||(t[1]=e=>te.setBulkActionOfInterest(null))},{default:(0,r.withCtx)(()=>[i.icon?((0,r.openBlock)(),(0,r.createElementBlock)("i",{key:0,class:(0,r.normalizeClass)(i.icon)},null,2)):(0,r.createCommentVNode)("",!0),(0,r.withDirectives)((0,r.createElementVNode)("span",null,null,512),[[fe,i.label]])]),_:2},1032,["id","class","disabled","data-testid","aria-label","onClick","onMouseover"])),[[me,e.actionTooltip]])),128)),J.featureDropdownMenu?((0,r.openBlock)(),(0,r.createBlock)(re,{key:0,disabled:!e.selectedRows.length,"hidden-actions":e.hiddenActions,"action-tooltip":e.actionTooltip,size:"medium",onClick:e.applyTableAction,onMouseover:te.setBulkActionOfInterest,onMouseleave:te.setBulkActionOfInterest},null,8,["disabled","hidden-actions","action-tooltip","onClick","onMouseover","onMouseleave"])):((0,r.openBlock)(),(0,r.createBlock)(ie,{key:1,class:(0,r.normalizeClass)([e.bulkActionsDropdownClass,"bulk-actions-dropdown"]),"disable-button":!e.selectedRows.length,size:"sm"},{"button-content":(0,r.withCtx)(({buttonSize:n})=>[(0,r.createElementVNode)("button",{ref:"actionDropDown",class:(0,r.normalizeClass)(["btn bg-primary mr-0",n]),disabled:!e.selectedRows.length},[t[22]||(t[22]=(0,r.createElementVNode)("i",{class:"icon icon-gear"},null,-1)),(0,r.createElementVNode)("span",null,(0,r.toDisplayString)(e.t("sortableTable.bulkActions.collapsed.label")),1),t[23]||(t[23]=(0,r.createElementVNode)("i",{class:"ml-10 icon icon-chevron-down"},null,-1))],10,o)]),"popover-content":(0,r.withCtx)(()=>[(0,r.createElementVNode)("ul",a,[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(e.hiddenActions,(n,i)=>(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("li",{key:i,class:(0,r.normalizeClass)({disabled:!n.enabled}),onClick:t=>e.applyTableAction(n,null,t),onMouseover:e=>te.setBulkActionOfInterest(n),onMouseleave:t[2]||(t[2]=e=>te.setBulkActionOfInterest(null))},[n.icon?((0,r.openBlock)(),(0,r.createElementBlock)("i",{key:0,class:(0,r.normalizeClass)(n.icon)},null,2)):(0,r.createCommentVNode)("",!0),(0,r.withDirectives)((0,r.createElementVNode)("span",null,null,512),[[fe,n.label]])],42,s)),[[ge],[me,{content:e.actionTooltip,placement:"right"}]])),128))])]),_:1},8,["class","disable-button"])),e.selectedRowsText?((0,r.openBlock)(),(0,r.createElementBlock)("label",{key:2,class:(0,r.normalizeClass)([e.bulkActionAvailabilityClass,"action-availability"])},(0,r.toDisplayString)(e.selectedRowsText),3)):(0,r.createCommentVNode)("",!0)],64)):(0,r.createCommentVNode)("",!0)],!0)],2),!e.hasAdvancedFiltering&&e.$slots["header-middle"]?((0,r.openBlock)(),(0,r.createElementBlock)("div",l,[(0,r.renderSlot)(e.$slots,"header-middle",{},void 0,!0)])):(0,r.createCommentVNode)("",!0),te.useTableViewsLayout&&!te.tableViewsTabsEmpty?((0,r.openBlock)(),(0,r.createElementBlock)("div",c,[(0,r.renderSlot)(e.$slots,"table-views",{},void 0,!0)])):(0,r.createCommentVNode)("",!0),n.search||e.hasAdvancedFiltering||e.isTooManyItemsToAutoUpdate||e.$slots["header-right"]?((0,r.openBlock)(),(0,r.createElementBlock)("div",u,[e.hasAdvancedFiltering?((0,r.openBlock)(),(0,r.createElementBlock)("ul",d,[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(e.advancedFilteringValues,(n,i)=>((0,r.openBlock)(),(0,r.createElementBlock)("li",{key:i},[(0,r.createElementVNode)("span",h,(0,r.toDisplayString)(`"${n.value}" ${e.t("sortableTable.in")} ${n.label}`),1),(0,r.createElementVNode)("span",{class:"cross",onClick:t=>e.clearAdvancedFilter(i)},"✕",8,p),t[24]||(t[24]=(0,r.createElementVNode)("div",{class:"bg"},null,-1))]))),128))])):(0,r.createCommentVNode)("",!0),te.useTableViewsLayout&&n.tableActions?((0,r.openBlock)(),(0,r.createBlock)(oe,{key:1,actions:e.availableActions,count:e.selectedRows.length,"action-tooltip":e.actionTooltip,testid:n.componentTestid,onClick:e.applyTableAction,onMouseover:te.setBulkActionOfInterest,onMouseleave:te.setBulkActionOfInterest},null,8,["actions","count","action-tooltip","testid","onClick","onMouseover","onMouseleave"])):(0,r.createCommentVNode)("",!0),(0,r.renderSlot)(e.$slots,"watch-controls",{},void 0,!0),(0,r.renderSlot)(e.$slots,"header-right",{},void 0,!0),!n.hideManualRefreshButton&&e.isTooManyItemsToAutoUpdate?((0,r.openBlock)(),(0,r.createBlock)(ae,{key:2,mode:"manual-refresh",size:n.manualRefreshButtonSize,"current-phase":ee.refreshButtonPhase,onClick:e.debouncedRefreshTableData},null,8,["size","current-phase","onClick"])):(0,r.createCommentVNode)("",!0),e.hasAdvancedFiltering?((0,r.openBlock)(),(0,r.createElementBlock)("div",f,[(0,r.createElementVNode)("button",{class:"btn role-primary",onClick:t[3]||(t[3]=t=>{e.advancedFilteringVisibility=!e.advancedFilteringVisibility})},(0,r.toDisplayString)(e.t("sortableTable.addFilter")),1),(0,r.withDirectives)((0,r.createElementVNode)("div",m,[(0,r.createVNode)(se,{ref:"advancedSearchQuery",value:e.advFilterSearchTerm,"onUpdate:value":t[4]||(t[4]=t=>e.advFilterSearchTerm=t),type:"search",class:"advanced-search-box","clear-button-label":e.t("sortableTable.clearFilter"),placeholder:e.t("sortableTable.filterFor")},null,8,["value","clear-button-label","placeholder"]),(0,r.createElementVNode)("div",g,[(0,r.createElementVNode)("span",null,(0,r.toDisplayString)(e.t("sortableTable.in")),1),(0,r.createVNode)(le,{value:e.advFilterSelectedProp,"onUpdate:value":t[5]||(t[5]=t=>e.advFilterSelectedProp=t),class:"filter-select",clearable:!0,options:e.advFilterSelectOptions,disabled:!1,searchable:!1,mode:"edit",multiple:!1,taggable:!1,placeholder:e.t("sortableTable.selectCol"),onSelecting:t[6]||(t[6]=t=>e.advFilterSelectedLabel=t.label)},null,8,["value","options","placeholder"])]),(0,r.createElementVNode)("div",v,[(0,r.createElementVNode)("button",{class:"btn role-secondary",disabled:!e.advancedFilteringValues.length,onClick:t[7]||(t[7]=(...t)=>e.clearAllAdvancedFilters&&e.clearAllAdvancedFilters(...t))},(0,r.toDisplayString)(e.t("sortableTable.resetFilters")),9,b),(0,r.createElementVNode)("button",{class:"btn role-primary",onClick:t[8]||(t[8]=(...t)=>e.addAdvancedFilter&&e.addAdvancedFilter(...t))},(0,r.toDisplayString)(e.t("sortableTable.add")),1)])],512),[[r.vShow,e.advancedFilteringVisibility]])],512)):n.search?((0,r.openBlock)(),(0,r.createElementBlock)("p",y,(0,r.toDisplayString)(e.t("sortableTable.filteringDescription")),1)):(0,r.createCommentVNode)("",!0),n.search?((0,r.openBlock)(),(0,r.createBlock)(se,{key:5,ref:"searchQuery",value:ee.eventualSearchQuery,"onUpdate:value":t[9]||(t[9]=e=>ee.eventualSearchQuery=e),type:"search",class:"search-box","aria-label":e.t("sortableTable.searchLabel"),"aria-describedby":"describe-filter-sortable-table","clear-button-label":e.t("sortableTable.clearFilter"),placeholder:e.t("sortableTable.search")},null,8,["value","aria-label","clear-button-label","placeholder"])):(0,r.createCommentVNode)("",!0),(0,r.renderSlot)(e.$slots,"header-button",{},void 0,!0)])):(0,r.createCommentVNode)("",!0)],2)):(0,r.createCommentVNode)("",!0),e.$slots["sub-header-row"]?((0,r.openBlock)(),(0,r.createElementBlock)("div",w,[(0,r.renderSlot)(e.$slots,"sub-header-row",{},void 0,!0)])):(0,r.createCommentVNode)("",!0)],2),(0,r.createElementVNode)("table",{ref:"table",class:(0,r.normalizeClass)(["sortable-table",te.classObject]),width:"100%",role:"table"},[n.showHeaders?((0,r.openBlock)(),(0,r.createBlock)(ce,{key:0,"label-for":te.labelFor,"select-all-label":te.selectAllCheckboxLabel,columns:te.columns,group:e.group,"group-options":e.advGroupOptions,"has-advanced-filtering":e.hasAdvancedFiltering,"adv-filter-hide-labels-as-cols":e.advFilterHideLabelsAsCols,"table-actions":n.tableActions,"table-cols-options":e.columnOptions,"row-actions":n.rowActions,"sub-expand-column":n.subExpandColumn,"row-actions-width":n.rowActionsWidth,"how-much-selected":e.howMuchSelected,"sort-by":e.sortBy,"default-sort-by":e._defaultSortBy,descending:e.descending,"no-rows":te.noRows,loading:ee.isLoading&&!ee.loadingDelay,"no-results":te.noResults,onOnToggleAll:e.onToggleAll,onOnSortChange:e.changeSort,onColVisibilityChange:e.changeColVisibility,onGroupValueChange:t[10]||(t[10]=t=>e.$emit("group-value-change",t)),onUpdateColsOptions:e.updateColsOptions},null,8,["label-for","select-all-label","columns","group","group-options","has-advanced-filtering","adv-filter-hide-labels-as-cols","table-actions","table-cols-options","row-actions","sub-expand-column","row-actions-width","how-much-selected","sort-by","default-sort-by","descending","no-rows","loading","no-results","onOnToggleAll","onOnSortChange","onColVisibilityChange","onUpdateColsOptions"])):(0,r.createCommentVNode)("",!0),ee.isLoading&&!ee.loadingDelay?((0,r.openBlock)(),(0,r.createElementBlock)("div",O)):ee.isLoading&&!n.altLoading?((0,r.openBlock)(),(0,r.createElementBlock)("tbody",S,[(0,r.renderSlot)(e.$slots,"loading",{},()=>[(0,r.createElementVNode)("tr",null,[(0,r.createElementVNode)("td",{colspan:te.fullColspan},[(0,r.createElementVNode)("div",x,[t[25]||(t[25]=(0,r.createElementVNode)("i",{class:"icon-spin icon icon-spinner"},null,-1)),(0,r.createVNode)(ue,{k:"generic.loading",raw:!0})])],8,E)])],!0)])):te.noRows?((0,r.openBlock)(),(0,r.createElementBlock)("tbody",_,[(0,r.renderSlot)(e.$slots,"no-rows",{},()=>[(0,r.createElementVNode)("tr",k,[(0,r.createElementVNode)("td",{colspan:te.fullColspan},[n.showNoRows?((0,r.openBlock)(),(0,r.createBlock)(ue,{key:0,k:n.noRowsKey},null,8,["k"])):(0,r.createCommentVNode)("",!0)],8,C)])],!0)])):te.noResults?((0,r.openBlock)(),(0,r.createElementBlock)("tbody",A,[(0,r.renderSlot)(e.$slots,"no-results",{},()=>[(0,r.createElementVNode)("tr",T,[(0,r.createElementVNode)("td",{colspan:te.fullColspan,class:"text-center"},[(0,r.createVNode)(ue,{k:n.noDataKey},null,8,["k"])],8,R)])],!0)])):((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,{key:5},(0,r.renderList)(te.displayRows,i=>((0,r.openBlock)(),(0,r.createElementBlock)("tbody",{key:i.key,tabindex:"-1",class:(0,r.normalizeClass)({group:n.groupBy})},[n.groupBy?(0,r.renderSlot)(e.$slots,"group-row",{group:i,fullColspan:te.fullColspan},()=>[(0,r.createElementVNode)("tr",N,[(0,r.createElementVNode)("td",{colspan:te.fullColspan},[(0,r.renderSlot)(e.$slots,"group-by",{group:i.grp},()=>[(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("div",I,[(0,r.createTextVNode)((0,r.toDisplayString)(i.ref),1)])),[[ve]])],!0)],8,P)])],!0,0):(0,r.createCommentVNode)("",!0),((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(i.rows,(i,o)=>((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:i.key},[(0,r.renderSlot)(e.$slots,"main-row",{row:i.row},()=>[(0,r.renderSlot)(e.$slots,"main-row:"+(i.row.mainRowKey||o),{fullColspan:te.fullColspan},()=>[(0,r.createElementVNode)("tr",{class:(0,r.normalizeClass)(["main-row",{"has-sub-row":i.showSubRow}]),"data-testid":n.componentTestid+"-"+o+"-row","data-node-id":i.key,"data-cant-run-bulk-action-of-interest":ee.actionOfInterest&&!i.canRunBulkActionOfInterest},[n.tableActions?((0,r.openBlock)(),(0,r.createElementBlock)("td",D,[(0,r.createTextVNode)((0,r.toDisplayString)(i.mainRowKey)+" ",1),(0,r.createVNode)(de,{class:"selection-checkbox","data-node-id":i.key,"data-testid":n.componentTestid+"-"+o+"-checkbox",value:e.selectedRows.includes(i.row),"alternate-label":te.rowCheckboxLabel(i)},null,8,["data-node-id","data-testid","value","alternate-label"])])):(0,r.createCommentVNode)("",!0),n.subExpandColumn?((0,r.openBlock)(),(0,r.createElementBlock)("td",L,[(0,r.createElementVNode)("i",{"data-title":"Toggle Expand",class:(0,r.normalizeClass)({icon:!0,"icon-chevron-right":!ee.expanded[i.row[n.keyField]],"icon-chevron-down":!!ee.expanded[i.row[n.keyField]]}),onClick:(0,r.withModifiers)(e=>te.toggleExpand(i.row),["stop"])},null,10,B)])):(0,r.createCommentVNode)("",!0),((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(i.columns,(t,a)=>(0,r.renderSlot)(e.$slots,"col:"+t.col.name,{row:i.row,col:t.col,dt:te.dt,expanded:ee.expanded,rowKey:i.key},()=>[(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("td",{key:t.col.name,"data-title":t.col.label,"data-testid":`sortable-cell-${o}-${a}`,align:t.col.align||"left",class:(0,r.normalizeClass)({["col-"+t.dasherize]:!!t.col.formatter,[t.col.breakpoint]:!!t.col.breakpoint,["skip-select"]:t.col.skipSelect}),width:t.col.width},[((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(t.limits?"LimitedCell":"CellContent"),{limits:t.limits},{default:(0,r.withCtx)(()=>[(0,r.renderSlot)(e.$slots,"cell:"+t.col.name,{row:i.row,col:t.col,value:t.value},()=>[t.component&&t.needRef?((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(t.component),(0,r.mergeProps)({key:0,ref_for:!0,ref:"column",value:t.value,row:i.row,col:t.col,"get-custom-detail-link":n.getCustomDetailLink},{ref_for:!0},t.col.formatterOpts,{"row-key":i.key}),null,16,["value","row","col","get-custom-detail-link","row-key"])):t.component?((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(t.component),(0,r.mergeProps)({key:1,value:t.value,row:i.row,col:t.col},{ref_for:!0},t.col.formatterOpts,{"row-key":i.key}),null,16,["value","row","col","row-key"])):t.col.formatter?((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(t.col.formatter),(0,r.mergeProps)({key:2,value:t.value,row:i.row,col:t.col},{ref_for:!0},t.col.formatterOpts,{"row-key":i.key}),null,16,["value","row","col","row-key"])):""!==t.value?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:3},[(0,r.createTextVNode)((0,r.toDisplayString)(t.formatted),1)],64)):t.col.dashIfEmpty?((0,r.openBlock)(),(0,r.createElementBlock)("span",V,"—")):(0,r.createCommentVNode)("",!0)],!0)]),_:2},1032,["limits"]))],10,$)),[[r.vShow,!e.hasAdvancedFiltering||e.hasAdvancedFiltering&&t.col.isColVisible],[be,"state"===t.col.name?{icon:"icon-folder",hookable:!0,value:i.row,tag:"__sortable-table-row",description:"Row"}:void 0]])],!0,a)),128)),n.rowActions?((0,r.openBlock)(),(0,r.createElementBlock)("td",F,[(0,r.renderSlot)(e.$slots,"row-actions",{row:i.row,index:o},()=>[J.featureDropdownMenu?((0,r.openBlock)(),(0,r.createBlock)(he,{key:0,resource:i.row,"data-testid":n.componentTestid+"-"+o+"-action-button","button-aria-label":e.t("sortableTable.tableActionsLabel",{resource:i?.row?.id||""})},null,8,["resource","data-testid","button-aria-label"])):((0,r.openBlock)(),(0,r.createBlock)(pe,{key:1,id:`actionButton+${o}+${i.row&&i.row.name?i.row.name:""}`,ref_for:!0,ref:`actionButton${o}`,"aria-haspopup":"true","aria-expanded":"false","aria-label":e.t("sortableTable.tableActionsLabel",{resource:i?.row?.id||""}),"data-testid":n.componentTestid+"-"+o+"-action-button",borderless:!0,onClick:e=>te.handleActionButtonClick(o,e),onKeyup:[(0,r.withKeys)(e=>te.handleActionButtonClick(o,e),["enter"]),(0,r.withKeys)(e=>te.handleActionButtonClick(o,e),["space"])]},null,8,["id","aria-label","data-testid","onClick","onKeyup"]))],!0)])):(0,r.createCommentVNode)("",!0)],10,M)],!0)],!0),i.showSubRow?(0,r.renderSlot)(e.$slots,"sub-row",{fullColspan:te.fullColspan,row:i.row,subMatches:ee.subMatches,keyField:n.keyField,componentTestid:n.componentTestid,i:o,onRowMouseEnter:e.onRowMouseEnter,onRowMouseLeave:e.onRowMouseLeave},()=>[(0,r.renderSlot)(e.$slots,"additional-sub-row",{fullColspan:te.fullColspan,row:i.row,showSubRow:i.row.stateDescription,subMatches:ee.subMatches,keyField:n.keyField,componentTestid:n.componentTestid,i:o,onRowMouseEnter:e.onRowMouseEnter,onRowMouseLeave:e.onRowMouseLeave},void 0,!0),i.row.stateDescription?((0,r.openBlock)(),(0,r.createElementBlock)("tr",{key:i.row[n.keyField]+"-description","data-testid":n.componentTestid+"-"+o+"-row-description",class:"state-description sub-row",onMouseenter:t[11]||(t[11]=(...t)=>e.onRowMouseEnter&&e.onRowMouseEnter(...t)),onMouseleave:t[12]||(t[12]=(...t)=>e.onRowMouseLeave&&e.onRowMouseLeave(...t))},[n.tableActions?((0,r.openBlock)(),(0,r.createElementBlock)("td",U)):(0,r.createCommentVNode)("",!0),(0,r.createElementVNode)("td",{colspan:te.fullColspan-(n.tableActions?1:0),class:(0,r.normalizeClass)({"text-error":i.row.stateObj.error})},(0,r.toDisplayString)(i.row.stateDescription),11,G)],40,j)):(0,r.createCommentVNode)("",!0)],!0,0):(0,r.createCommentVNode)("",!0)],64))),128))],2))),128))],2),e.showPaging?((0,r.openBlock)(),(0,r.createElementBlock)("div",H,[(0,r.createElementVNode)("button",{type:"button",class:"btn btn-sm role-multi-action","data-testid":"pagination-first",disabled:1==e.page||n.loading,role:"button","aria-label":e.t("sortableTable.ariaLabel.firstPageBtn"),onClick:t[13]||(t[13]=t=>e.goToPage("first"))},[(0,r.createElementVNode)("i",{class:"icon icon-chevron-beginning",alt:e.t("sortableTable.alt.firstPageBtn")},null,8,Q)],8,q),(0,r.createElementVNode)("button",{type:"button",class:"btn btn-sm role-multi-action","data-testid":"pagination-prev",disabled:1==e.page||n.loading,role:"button","aria-label":e.t("sortableTable.ariaLabel.prevPageBtn"),onClick:t[14]||(t[14]=t=>e.goToPage("prev"))},[(0,r.createElementVNode)("i",{class:"icon icon-chevron-left",alt:e.t("sortableTable.alt.prevPageBtn")},null,8,K)],8,z),(0,r.createElementVNode)("span",null,(0,r.toDisplayString)(e.pagingDisplay),1),(0,r.createElementVNode)("button",{type:"button",class:"btn btn-sm role-multi-action","data-testid":"pagination-next",disabled:e.page==e.totalPages||n.loading,role:"button","aria-label":e.t("sortableTable.ariaLabel.nextPageBtn"),onClick:t[15]||(t[15]=t=>e.goToPage("next"))},[(0,r.createElementVNode)("i",{class:"icon icon-chevron-right",alt:e.t("sortableTable.alt.nextPageBtn")},null,8,X)],8,W),(0,r.createElementVNode)("button",{type:"button",class:"btn btn-sm role-multi-action","data-testid":"pagination-last",disabled:e.page==e.totalPages||n.loading,role:"button","aria-label":e.t("sortableTable.ariaLabel.lastPageBtn"),onClick:t[16]||(t[16]=t=>e.goToPage("last"))},[(0,r.createElementVNode)("i",{class:"icon icon-chevron-end",alt:e.t("sortableTable.alt.lastPageBtn")},null,8,Z)],8,Y)])):(0,r.createCommentVNode)("",!0),n.search?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:1,class:"hide",onShortkey:t[17]||(t[17]=e=>te.focusSearch())},null,544)),[[ye,["/"],void 0,{once:!0}]]):(0,r.createCommentVNode)("",!0),n.tableActions?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:2},[(0,r.withDirectives)((0,r.createElementVNode)("button",{class:"hide",onShortkey:t[18]||(t[18]=e=>te.focusNext(e))},null,544),[[ye,["j"]]]),(0,r.withDirectives)((0,r.createElementVNode)("button",{class:"hide",onShortkey:t[19]||(t[19]=e=>te.focusPrevious(e))},null,544),[[ye,["k"]]]),(0,r.withDirectives)((0,r.createElementVNode)("button",{class:"hide",onShortkey:t[20]||(t[20]=e=>te.focusNext(e,!0))},null,544),[[ye,["shift","j"]]]),(0,r.withDirectives)((0,r.createElementVNode)("button",{class:"hide",onShortkey:t[21]||(t[21]=e=>te.focusPrevious(e,!0))},null,544),[[ye,["shift","k"]]])],64)):(0,r.createCommentVNode)("",!0),(0,r.renderSlot)(e.$slots,"shortkeys",{},void 0,!0)],10,i)}var ee=n(65359),te=n(23464),ne=n.n(te),re=n(3514),ie=n.n(re),oe=n(92043),ae=n(76978),se=n(70560),le=n(81268),ce=n(51433),ue=n(68851),de=n(42200),he=n(30699);const pe={class:"dropdown-button-group"},fe=["disabled"];function me(e,t,n,i,o,a){const s=(0,r.resolveComponent)("v-dropdown");return(0,r.openBlock)(),(0,r.createElementBlock)("div",pe,[(0,r.createElementVNode)("div",{class:(0,r.normalizeClass)(["dropdown-button bg-primary",{"one-action":!n.dualAction,[a.buttonSize]:!0,disabled:n.disableButton}])},[(0,r.createVNode)(s,{placement:"bottom",container:!1,disabled:n.disableButton,flip:!1},{popper:(0,r.withCtx)(()=>[(0,r.renderSlot)(e.$slots,"popover-content")]),default:(0,r.withCtx)(()=>[(0,r.renderSlot)(e.$slots,"button-content",{buttonSize:a.buttonSize},()=>[(0,r.createElementVNode)("button",{ref:"popoverButton",class:(0,r.normalizeClass)(["icon-container bg-primary no-left-border-radius",a.buttonSize]),disabled:n.disableButton,type:"button"},[...t[0]||(t[0]=[(0,r.createTextVNode)(" Button ",-1),(0,r.createElementVNode)("i",{class:"icon icon-chevron-down"},null,-1)])],10,fe)])]),_:3},8,["disabled"])],2)])}var ge={name:"ActionDropdown",props:{size:{type:String,default:""},dualAction:{type:Boolean,default:!0},disableButton:{type:Boolean,default:!1}},computed:{buttonSize(){const{size:e}=this;let t;switch(e){case"":t="btn";break;case"xs":t="btn btn-xs";break;case"sm":t="btn btn-sm";break;case"lg":t="btn btn-lg";break;default:}return t}},methods:{hasSlot(e="default"){return!!this.$slots[e]||!!this.$slots.name()},togglePopover(){}}},ve=(n(63864),n(47433));const be=(0,ve.A)(ge,[["render",me]]);var ye=be,we=n(30588),Oe=(0,r.defineComponent)({__name:"ActionDropdownShell",props:{disabled:{type:Boolean},hiddenActions:{},actionTooltip:{},size:{default:"large"}},emits:["click","mouseover","mouseleave"],setup(e,{emit:t}){const n=t,i=(e,t,r)=>{n("click",e,t,r)},o=(e,t="mouseover")=>{n(t,e)};return(t,n)=>{const a=(0,r.resolveDirective)("clean-html"),s=(0,r.resolveDirective)("clean-tooltip");return(0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(we.Jj),{distance:14,placement:"bottom"},{dropdownCollection:(0,r.withCtx)(()=>[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(e.hiddenActions,(t,l)=>(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(we.s$),{key:l,disabled:!t.enabled,onClick:e=>i(t,null,e),onMouseover:e=>o(t),onMouseleave:n[0]||(n[0]=e=>o(null,"mouseleave"))},{before:(0,r.withCtx)(()=>[t.icon?((0,r.openBlock)(),(0,r.createElementBlock)("i",{key:0,class:(0,r.normalizeClass)(t.icon)},null,2)):(0,r.createCommentVNode)("",!0)]),default:(0,r.withCtx)(()=>[(0,r.withDirectives)((0,r.createElementVNode)("span",null,null,512),[[a,t.label]])]),_:2},1032,["disabled","onClick","onMouseover"])),[[s,{content:e.actionTooltip,placement:"right"}]])),128))]),default:(0,r.withCtx)(()=>[(0,r.createVNode)((0,r.unref)(we.Nq),{class:"bulk-actions-dropdown",size:e.size,disabled:e.disabled},{before:(0,r.withCtx)(()=>[...n[1]||(n[1]=[(0,r.createElementVNode)("i",{class:"icon icon-gear"},null,-1)])]),after:(0,r.withCtx)(()=>[...n[2]||(n[2]=[(0,r.createElementVNode)("i",{class:"icon icon-chevron-down"},null,-1)])]),default:(0,r.withCtx)(()=>[(0,r.createElementVNode)("span",null,(0,r.toDisplayString)(t.t("sortableTable.bulkActions.collapsed.label")),1)]),_:1},8,["size","disabled"])]),_:1})}}});const Se=Oe;var Ee=Se,xe=n(97331),_e=n.n(xe),ke=n(12784),Ce=n.n(ke);const Ae=["width"],Te=["width"],Re={class:"content"},Ne={class:"sr-only"},Pe=["align","width","tabindex","aria-sort","onClick","onKeyup"],Ie={class:"content"},Me={key:0,class:"text-muted text-no-break"},De={key:0,class:"sort","aria-hidden":"true"},Le={class:"icon icon-info not-filter-icon"},Be={class:"icon-stack"},$e=["alt"],Ve=["alt"],Fe=["width"],je={class:"content"},Ue={class:"sr-only"},Ge={key:0,ref:"table-options",class:"table-options-group"},He={key:0,class:"table-options-grouping"},qe={class:"table-options-col-subtitle"},Qe={class:"table-options-col-subtitle mb-20"};function ze(e,t,n,i,o,a){const s=(0,r.resolveComponent)("Checkbox"),l=(0,r.resolveComponent)("LabeledSelect"),c=(0,r.resolveDirective)("clean-html"),u=(0,r.resolveDirective)("clean-tooltip");return(0,r.openBlock)(),(0,r.createElementBlock)("thead",null,[(0,r.createElementVNode)("tr",{class:(0,r.normalizeClass)({loading:n.loading,"top-aligned":a.hasColumnWithSubLabel})},[n.tableActions?((0,r.openBlock)(),(0,r.createElementBlock)("th",{key:0,width:n.checkWidth},[(0,r.createVNode)(s,{value:a.isAll,"onUpdate:value":t[0]||(t[0]=e=>a.isAll=e),class:"check","data-testid":"sortable-table_check_select_all",indeterminate:a.isIndeterminate,disabled:n.noRows||n.noResults,"alternate-label":n.selectAllLabel||e.t("sortableTable.genericGroupCheckbox")},null,8,["value","indeterminate","disabled","alternate-label"])],8,Ae)):(0,r.createCommentVNode)("",!0),n.subExpandColumn?((0,r.openBlock)(),(0,r.createElementBlock)("th",{key:1,width:n.expandWidth},[(0,r.createElementVNode)("div",Re,[(0,r.createElementVNode)("span",Ne,(0,r.toDisplayString)(e.t("sortableTable.expandColumnHeader")),1)])],8,Te)):(0,r.createCommentVNode)("",!0),((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(n.columns,i=>(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("th",{key:i.name,align:i.align||"left",width:i.width,class:(0,r.normalizeClass)([{sortable:i.sort,[i.breakpoint]:!!i.breakpoint},"sortable-table-head-element"]),tabindex:i.sort?0:-1,"aria-sort":a.ariaSort(i),onClick:(0,r.withModifiers)(e=>a.changeSort(e,i),["prevent"]),onKeyup:[(0,r.withKeys)(e=>a.changeSort(e,i),["enter"]),(0,r.withKeys)(e=>a.changeSort(e,i),["space"])]},[(0,r.createElementVNode)("div",{class:(0,r.normalizeClass)(["table-header-container",{"not-filterable":n.hasAdvancedFiltering&&!i.isFilter}])},[(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("div",Ie,[(0,r.withDirectives)((0,r.createElementVNode)("span",{class:(0,r.normalizeClass)(["text-no-break",{"sr-only":i.labelVisuallyHidden}])},null,2),[[c,n.labelFor(i)]]),i.subLabel?((0,r.openBlock)(),(0,r.createElementBlock)("span",Me,(0,r.toDisplayString)(i.subLabel),1)):(0,r.createCommentVNode)("",!0)])),[[u,a.tooltip(i)]]),i.sort?((0,r.openBlock)(),(0,r.createElementBlock)("div",De,[(0,r.withDirectives)((0,r.createElementVNode)("i",Le,null,512),[[r.vShow,n.hasAdvancedFiltering&&!i.isFilter],[u,e.t("sortableTable.tableHeader.noFilter")]]),(0,r.createElementVNode)("span",Be,[t[3]||(t[3]=(0,r.createElementVNode)("i",{class:"icon icon-sort icon-stack-1x faded"},null,-1)),a.isCurrent(i)&&!n.descending?((0,r.openBlock)(),(0,r.createElementBlock)("i",{key:0,class:"icon icon-sort-down icon-stack-1x",alt:e.t("sortableTable.alt.sortingIconDesc")},null,8,$e)):(0,r.createCommentVNode)("",!0),a.isCurrent(i)&&n.descending?((0,r.openBlock)(),(0,r.createElementBlock)("i",{key:1,class:"icon icon-sort-up icon-stack-1x",alt:e.t("sortableTable.alt.sortingIconAsc")},null,8,Ve)):(0,r.createCommentVNode)("",!0)])])):(0,r.createCommentVNode)("",!0)],2)],42,Pe)),[[r.vShow,!n.hasAdvancedFiltering||n.hasAdvancedFiltering&&i.isColVisible]])),128)),n.rowActions?((0,r.openBlock)(),(0,r.createElementBlock)("th",{key:2,width:n.rowActionsWidth},[(0,r.createElementVNode)("div",je,[(0,r.createElementVNode)("span",Ue,(0,r.toDisplayString)(e.t("sortableTable.actionsColumnHeader")),1)]),n.hasAdvancedFiltering&&n.tableColsOptions.length?((0,r.openBlock)(),(0,r.createElementBlock)("div",Ge,[(0,r.createElementVNode)("button",{"aria-haspopup":"true","aria-expanded":"false",type:"button",class:"btn btn-sm role-multi-action table-options-btn",onClick:t[1]||(t[1]=(...e)=>a.tableColsOptionsClick&&a.tableColsOptionsClick(...e))},[...t[4]||(t[4]=[(0,r.createElementVNode)("i",{class:"icon icon-actions"},null,-1)])]),(0,r.withDirectives)((0,r.createElementVNode)("div",{class:"table-options-container",style:(0,r.normalizeStyle)(o.tableColsMenuPosition)},[a.hasAdvGrouping?((0,r.openBlock)(),(0,r.createElementBlock)("div",He,[(0,r.createElementVNode)("span",qe,(0,r.toDisplayString)(e.t("sortableTable.tableHeader.groupBy"))+":",1),(0,r.createVNode)(l,{value:a.advGroup,"onUpdate:value":t[2]||(t[2]=e=>a.advGroup=e),class:"table-options-grouping-select",clearable:!0,options:n.groupOptions,disabled:!1,searchable:!1,mode:"edit",multiple:!1,taggable:!1},null,8,["value","options"])])):(0,r.createCommentVNode)("",!0),(0,r.createElementVNode)("p",Qe,(0,r.toDisplayString)(e.t("sortableTable.tableHeader.show"))+": ",1),(0,r.createElementVNode)("ul",null,[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(n.tableColsOptions,(e,t)=>(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("li",{key:t,class:(0,r.normalizeClass)({visible:!e.preventColToggle})},[(0,r.withDirectives)((0,r.createVNode)(s,{value:e.isColVisible,"onUpdate:value":[t=>e.isColVisible=t,t=>a.tableOptionsCheckbox(t,e.label)],class:"table-options-checkbox",label:e.label},null,8,["value","onUpdate:value","label"]),[[r.vShow,!e.preventColToggle]])],2)),[[r.vShow,e.isTableOption]])),128))])],4),[[r.vShow,o.tableColsOptionsVisibility]])],512)):(0,r.createCommentVNode)("",!0)],8,Fe)):(0,r.createCommentVNode)("",!0)],2)])}var Ke=n(35881);function We(e,t){if(e=e?.parentElement,!e)return null;const n=e.matches||e.matchesSelector;return n.call(e,t)?e:We(e,t)}const Xe=(e,t)=>(0,r.toRaw)(e)===(0,r.toRaw)(t),Ye="all",Ze="some",Je="none";var et={mounted(){const e=this.$el.querySelector("TABLE");this._onRowClickBound=this.onRowClick.bind(this),this._onRowMousedownBound=this.onRowMousedown.bind(this),this._onRowContextBound=this.onRowContext.bind(this),e.addEventListener("click",this._onRowClickBound),e.addEventListener("mousedown",this._onRowMousedownBound),e.addEventListener("contextmenu",this._onRowContextBound)},beforeUnmount(){const e=this.$el.querySelector("TABLE");e.removeEventListener("click",this._onRowClickBound),e.removeEventListener("mousedown",this._onRowMousedownBound),e.removeEventListener("contextmenu",this._onRowContextBound)},computed:{...(0,ee.L8)({targetElem:"action-menu/elem",shouldShow:"action-menu/showing"}),howMuchSelected(){const e=this.pagedRows.length,t=this.selectedRows.length;return t>=e&&e>0?Ye:t>0?Ze:Je},bulkActionsForSelection(){let e=!1;const t=this.pagedRows,n=this.arrangedRows||t;let r=this.selectedRows;if(!this.selectedRows.length){if(!n)return[];const t=n[0];r=t?[t]:[],e=!0}const i={};for(const a of t)if(a.availableActions)for(const e of a.availableActions)e.bulkable&&nt(i,e,!1);for(const a of r)if(a.availableActions)for(const e of a.availableActions)e.bulkable&&e.enabled&&nt(i,e,!1);const o=rt(i,e);return o.forEach(e=>{const t=this.selectedRows.some(t=>{const n=t.availableActions||[];return n.some(t=>t.action===e.action&&t.enabled)});e.enabled=this.selectedRows.length>0&&t}),o.sort((e,t)=>(t.weight||0)-(e.weight||0))}},data(){return{selectedRows:[],prevNode:null}},watch:{externalPaginationResult(){this.pageChanged(this.pagedRows)},pagedRows(){this.pageChanged(this.pagedRows)}},methods:{pageChanged(e){const t=[];for(const n of this.selectedRows)e.some(e=>Xe(e,n))||t.push(n);this.update([],t)},onToggleAll(e){return e?(this.update(this.pagedRows,[]),!0):(this.update([],this.pagedRows),!1)},onRowMousedown(e){((0,Ke._Z)(e)||this.isSelectionCheckbox(e.target))&&e.preventDefault()},removeOrAddHover(e,t){const n=t.target.closest("TR");if(n.classList.contains("sub-row")||n.classList.contains("additional-sub-row")){const t=n.previousElementSibling,r=n.nextElementSibling;if(t.classList[e]("sub-row-hovered"),!t.classList.contains("main-row")){const n=t.previousElementSibling;n.classList[e]("sub-row-hovered")}r?.classList.contains("sub-row")&&r.classList[e]("sub-row-hovered")}},onRowMouseEnter(e){this.removeOrAddHover("add",e)},onRowMouseLeave(e){this.removeOrAddHover("remove",e)},nodeForEvent(e){const t=e.target.tagName,n=e.target,r=n.closest(".actions");if(n.classList.contains("select-all-check"))return;if(!r&&("A"===t||"BUTTON"===t||We(n,".btn")))return;const i=e.target.closest("TR");return this.nodeForRow(i)},nodeForRow(e){if(e?.classList.contains("separator-row"))return;while(e&&!e.classList.contains("main-row"))e=e.previousElementSibling;if(!e)return;const t=e.dataset.nodeId;if(!t)return;const n=this.pagedRows.find(e=>(0,ae.Jt)(e,this.keyField)===t);return n},async onRowClick(e){const t=this.nodeForEvent(e),n=e.target.closest("TD"),r=n?.classList.contains("skip-select");if(r)return;const i=this.selectedRows,o=this.isSelectionCheckbox(e.target)||n?.classList.contains("row-check"),a=n?.classList.contains("row-expand"),s=this.pagedRows;if(this.$emit("rowClick",e),!t)return;if(a)return void this.toggleExpand(t);const l=e.target.closest(".actions");if(l){let n=[t];if(this.mangleActionResources){const e=l.querySelector("i");e.classList.remove("icon-actions"),e.classList.add("icon-spinner"),e.classList.add("icon-spin");try{n=await this.mangleActionResources(n)}finally{e.classList.remove("icon-spinner"),e.classList.remove("icon-spin"),e.classList.add("icon-actions")}}return void(this.targetElem||this.shouldShow?this.targetElem===l&&this.shouldShow&&this.$store.commit("action-menu/hide"):this.$store.commit("action-menu/show",{resources:n,event:e,elem:l}))}const c=i.includes(t);let u=this.prevNode;if(u&&s.includes(u)||(u=t),(0,Ke.yC)(e))this.toggle(t);else if((0,Ke._Z)(e)){const e=this.nodesBetween(u,t);c?this.update([],e):this.update(e,[])}else o?this.toggle(t):this.update([t],s);this.prevNode=t},async onRowContext(e){const t=this.nodeForEvent(e);if((0,Ke.A0)(e))return;if(!t)return;e.stopPropagation(),this.prevNode=t;const n=this.selectedRows.includes(t);n||this.update([t],this.selectedRows.slice())},keySelectRow(e,t=!1){const n=this.nodeForRow(e),r=this.pagedRows;n&&(t?this.update([n],[]):this.update([n],r),this.prevNode=n)},isSelectionCheckbox(e){return"INPUT"===e.tagName&&"checkbox"===e.type&&null!==e.closest(".selection-checkbox")},nodesBetween(e,t){let n=[];const r=this.groupBy;if(r){const r=this.groupedRows;let i=this.groupIdx(e),o=this.groupIdx(t);if(!i||!o)return[];(i.group>o.group||i.group===o.group&&i.item>o.item)&&([i,o]=[o,i]);for(let e=i.group;e<=o.group;e++){const t=r[e].rows;let a=i.group===e?i.item:0;while(t[a]&&(e<o.group||a<=o.item))n.push(t[a]),a++}}else{const r=this.pagedRows;let i=r.indexOf(e),o=r.indexOf(t);[i,o]=[Math.min(i,o),Math.max(i,o)],n=r.slice(i,o+1)}return n=n.filter(e=>!this.selectedRows.includes(e)),n},groupIdx(e){const t=this.groupedRows;for(let n=0;n<t.length;n++){const r=t[n].rows;for(let t=0;t<r.length;t++)if(r[t]===e)return{group:n,item:t}}return null},toggle(e){const t=[],n=[];this.selectedRows.includes(e)?n.push(e):t.push(e),this.update(t,n)},update(e,t){t.forEach(e=>{const t=this.selectedRows.findIndex(t=>Xe(t,e));-1!==t&&this.selectedRows.splice(t,1)}),e&&this.selectedRows.push(...e),t.length&&this.$nextTick(()=>{for(let e=0;e<t.length;e++)this.updateInput(t[e],!1,this.keyField)}),e.length&&this.$nextTick(()=>{for(let t=0;t<e.length;t++)this.updateInput(e[t],!0,this.keyField)}),this.$nextTick(()=>{if(this.$emit("selection",this.selectedRows),this.selectedRows&&this.selectedRows.length)for(let e=0;e<this.selectedRows.length;e++)this.updateInput(this.selectedRows[e],!0,this.keyField)})},updateInput(e,t,n){const r=(0,ae.Jt)(e,n);if(r){const e=this.$el.querySelector(`div[data-checkbox-ctrl][data-node-id="${r}"]`);if(e&&!e.disabled){const n=e.querySelector("label");n&&(n.value=t);let r=e.closest("tr"),i=!0;while(r&&(i||r.classList.contains("sub-row")||r.classList.contains("additional-sub-row")))t?r.classList.add("row-selected"):r.classList.remove("row-selected"),r=r.nextElementSibling,i=!1}}},select(e){e.forEach(e=>{const t=(0,ae.Jt)(e,this.keyField),n=this.$el.querySelector(`label[data-node-id="${t}"]`);n.dispatchEvent(new Event("click"))})},applyTableAction(e,t,n){const r={alt:n&&(0,Ke.nN)(n),event:n},i=this.selectedRows.filter(t=>{const n=t.availableActions.find(t=>t.action===e.action);return n?.enabled});it(i,e,t,r,this),this.actionOfInterest=null},clearSelection(){this.update([],[...this.selectedRows])}}};let tt=0;function nt(e,t,n=!0){let r=t.action;r||(r=`anon${tt}`,tt++);let i=e[r];return i||(i=Object.assign({},t),e[r]=i,i.allEnabled=!1),t.enabled?i.anyEnabled=!0:i.allEnabled=!1,n&&(i.available=(i.available||0)+(t.enabled?1:0),i.total=(i.total||0)+1),i}function rt(e,t=!1){const n=(0,ue.WP)(Object.values(e),"anyEnabled",!0);for(const r of n)r.enabled=!t&&r.available>=r.total;return n}function it(e,t,n,r={},i){if(n=n||[],t.invoke){const o={action:t,event:r.event,isAlt:!!r.alt};return t.invoke.apply(i,[o,e||[],n])}const o=e=>{const n=e.availableActions.find(e=>e.action===t.action);return n?.altResource||e};if(e.length>1&&t.bulkAction&&!r.alt){const r=o(e[0]),i=r[t.bulkAction];if(i){const t=e.map(o);return i.call(r,t,...n)}}const a=[];for(const s of e){let e;const i=o(s);e=r.alt&&t.altAction?i[t.altAction]:i[t.action],e&&a.push(e.apply(i,n))}return Promise.all(a)}var ot=n(14817),at=n(49452),st={emits:["update-cols-options","on-toggle-all","group-value-change","on-sort-change","col-visibility-change"],components:{Checkbox:de.S,LabeledSelect:at.A},props:{columns:{type:Array,required:!0},sortBy:{type:String,required:!0},defaultSortBy:{type:String,default:""},group:{type:String,default:""},groupOptions:{type:Array,default:()=>[]},descending:{type:Boolean,required:!1,default:!1},hasAdvancedFiltering:{type:Boolean,required:!1},tableColsOptions:{type:Array,default:()=>[]},tableActions:{type:Boolean,required:!0},rowActions:{type:Boolean,required:!0},howMuchSelected:{type:String,required:!0},checkWidth:{type:Number,default:30},rowActionsWidth:{type:Number,required:!0},subExpandColumn:{type:Boolean,default:!1},expandWidth:{type:Number,default:30},labelFor:{type:Function,required:!0},selectAllLabel:{type:String,default:""},noRows:{type:Boolean,default:!0},noResults:{type:Boolean,default:!0},loading:{type:Boolean,required:!1}},data(){return{tableColsOptionsVisibility:!1,tableColsMenuPosition:null}},watch:{advancedFilteringValues(){this.watcherUpdateLiveAndDelayed(!0,!1)},tableColsOptionsVisibility(e){e?(window.addEventListener("click",this.onClickOutside),this.$emit("update-cols-options")):window.removeEventListener("click",this.onClickOutside)}},computed:{isAll:{get(){return this.howMuchSelected!==Je},set(e){this.$emit("on-toggle-all",e)}},hasAdvGrouping(){return this.group?.length&&this.groupOptions?.length},advGroup:{get(){return this.group||this.advGroup},set(e){this.$emit("group-value-change",e)}},isIndeterminate(){return this.howMuchSelected===Ze},hasColumnWithSubLabel(){return this.columns.some(e=>e.subLabel)}},methods:{changeSort(e,t){if(!t.sort)return;let n=!1;this.sortBy===t.name&&(n=!this.descending),this.$emit("on-sort-change",t.name,n)},isCurrent(e){return e.name===this.sortBy},ariaSort(e){return this.isCurrent(e)?this.descending?this.t("generic.descending"):this.t("generic.ascending"):this.t("generic.none")},tableColsOptionsClick(e){const t=document.querySelector(".table-options-container"),n=document.querySelector(".table-options-btn");this.tableColsMenuPosition=(0,ot.Tb)(t,e||n,{overlapX:!0,fudgeX:326,fudgeY:-22,positionX:ot.Q7,positionY:ot.Q8}),this.tableColsOptionsVisibility=!this.tableColsOptionsVisibility},onClickOutside(e){const t=this.$refs["table-options"];t&&!t.contains(e.target)&&(this.tableColsOptionsVisibility=!1)},tableOptionsCheckbox(e,t){this.$emit("col-visibility-change",{label:t,value:e})},tooltip(e){if(!e.tooltip)return null;const t=this.$store.getters["i18n/exists"];return t(e.tooltip)?this.t(e.tooltip):e.tooltip}}};n(17639),n(53421);const lt=(0,ve.A)(st,[["render",ze],["__scopeId","data-v-480d6580"]]);var ct=lt;const ut="allcols",dt="All Columns",ht=":::islabel";var pt={data(){return{searchQuery:null,previousFilter:null,previousResult:null}},computed:{searchFields(){const e=ft(this.columns);return this.extraSearchFields&&(0,ue.cn)(e,this.extraSearchFields),e},filteredRows(){if(!this.externalPaginationEnabled)return this.hasAdvancedFiltering?this.handleAdvancedFiltering():this.handleFiltering()}},methods:{handleAdvancedFiltering(){if(this.subMatches=null,this.searchQuery.length){const e=(this.arrangedRows||[]).slice(),t=e.filter(e=>this.searchQuery.every(t=>{if(t.prop===ut){const n=this.advFilterSelectOptions.slice(1);let r=[];return n.forEach(e=>{if(e.value.includes("[")&&e.value.includes("]"))r=r.concat(JSON.parse(e.value));else{const t=e.isLabel?`${e.label}${ht}`:e.value;r.push(t)}}),gt(r,[t.value],e)}{if(t.prop.includes("[")&&t.prop.includes("]"))return gt(JSON.parse(t.prop),[t.value],e);let n=t.prop;return t.prop.includes("metadata.labels")&&(n=`${t.label}${ht}`),gt([n],[t.value],e)}}));return t}return this.arrangedRows},handleFiltering(){const e=(this.searchQuery||"").trim().toLowerCase();let t;if(e&&this.previousResult&&e.startsWith(this.previousFilter)?t=this.previousResult.slice():(this.previousResult=null,t=(this.arrangedRows||[]).slice()),this.previousFilter=e,!e.length)return this.subMatches=null,this.previousResult=null,t;const n=this.searchFields,r=e.split(/\s*[, ]\s*/),i=this.subSearch,o=this.subFields,a={};for(let s=t.length-1;s>=0;s--){const e=t[s];let l=0,c=!0;if(c=gt(n,r,e),o&&i){const t=e[i]||[];for(let n=t.length-1;n>=0;n--){let t=!0;t=gt(o,r,e),t&&l++}a[(0,ae.Jt)(e,this.keyField)]=l}c||0!==l||(0,ue.Wq)(t,s)}return this.subMatches=a,this.previousResult=t,t}},watch:{arrangedRows(e){this.previousResult=null},searchQuery(){this.debouncedPaginationChanged()}}};function ft(e){const t=[];return(e||[]).forEach(e=>{const n=e.search;n?"string"===typeof n?(0,ue.PG)(t,n):(0,ue.cy)(n)&&(0,ue.cn)(t,n):!1===n||(0,ue.PG)(t,e.value||e.name)}),t.filter(e=>!!e)}const mt=/^[0-9a-f\.:]+$/i;function gt(e,t,n){for(let r=0;r<t.length;r++){let i=!0,o=t[r];return"!"===o.substr(0,1)&&(i=!1,o=o.substr(1)),!o||vt(e,o,n)===i}}function vt(e,t,n){for(let r of e){if(!r)continue;if("function"!==typeof r&&r.includes(ht)&&(!n.metadata.labels||!n.metadata.labels[r.replace(ht,"")]))continue;let e,i;if("function"===typeof r)i=r(n);else if(r.includes(ht))i=n.metadata.labels[r.replace(ht,"")];else{const t=r.indexOf(":");t>0&&(e=r.substr(t+1),r=r.substr(0,t)),i=r.includes(".")?(0,ae.Jt)(n,r):n[r]}if(void 0!==i&&(i=`${i}`.toLowerCase(),i))if(e){if("exact"===e){if(i===t)return!0}else if("ip"===e){const e=mt.test(t);if(e){const e=new RegExp(`(?:^|\\.)${t}(?:\\.|$)`);if(e.test(i))return!0}}else if("prefix"===e&&0===i.indexOf(t))return!0}else if(i.includes(`${t}`.toLowerCase()))return!0}return!1}var bt=n(20284),yt=n(41476),wt={computed:{totalRows(){return this.externalPaginationEnabled?this.externalPaginationResult?.count||0:this.filteredRows.length},indexFrom(){return Math.max(0,1+this.perPage*(this.page-1))},indexTo(){return Math.min(this.totalRows,this.indexFrom+this.perPage-1)},totalPages(){return Math.ceil(this.totalRows/this.perPage)},showPaging(){if(!this.paging)return!1;const e=this.totalPages>1;return(this.altLoading||!this.loading)&&e},pagingDisplay(){const e={...this.pagingParams||{},count:this.totalRows,pages:this.totalPages,from:this.indexFrom,to:this.indexTo};return this.$store.getters["i18n/t"](this.pagingLabel,e)},perPage(){let e=this.rowsPerPage||0;return e<=0&&(e=parseInt(this.$store.getters["prefs/get"](yt.kc),10)||0),e<=0&&(e=10),e},pagedRows(){return this.externalPaginationEnabled?this.rows:this.paging?this.filteredRows.slice(this.indexFrom-1,this.indexTo):this.filteredRows}},data(){return{page:1}},watch:{pagedRows(){const e=this.indexFrom,t=this.totalRows;this.totalPages>0&&this.page>1&&e>t&&this.setPage(this.totalPages)},page(){this.debouncedPaginationChanged()},perPage(){this.debouncedPaginationChanged()},totalRows(){this.updateTabCount(this.totalRows)}},methods:{setPage(e){this.page!==e&&(this.page=e)},goToPage(e){let t;switch(e){case"first":t=1;break;case"prev":t=Math.max(1,this.page-1);break;case"next":t=Math.min(this.totalPages,this.page+1);break;case"last":t=this.totalPages;break}this.setPage(t)},getPageByRow(e,t=e=>e){const n=this.filteredRows.map(t).indexOf(e);return-1===n?null:Math.ceil(n/this.perPage)}}},Ot={computed:{selectedGroupOption(){return this.groupOptions?.find(e=>e.value===this.group)},groupedRows(){const e=this.groupBy,t=this.groupRef||this.selectedGroupOption?.groupLabelKey||e;if(!e)return[{key:"default",ref:"default",rows:this.pagedRows}];const n=[],r={};for(const i of this.pagedRows){const o=("function"===typeof e?e(i):(0,ae.Jt)(i,e))||"",a="function"===typeof t?t(i):(0,ae.Jt)(i,t);let s=r[o];s?s.rows.push(i):(s={key:o,ref:a,rows:[i]},r[o]=s,n.push(s))}return n}}};const St="inline-flex";var Et={data(){return{bulkActionsClass:"bulk",bulkActionClass:"bulk-action",bulkActionsDropdownClass:"bulk-actions-dropdown",bulkActionAvailabilityClass:"action-availability",hiddenActions:[],updateHiddenBulkActions:Ce()(this.protectedUpdateHiddenBulkActions,10)}},beforeUnmount(){window.removeEventListener("resize",this.onWindowResize)},mounted(){window.addEventListener("resize",this.onWindowResize),this.updateHiddenBulkActions()},watch:{selectedRows(){this.updateHiddenBulkActions()},keyedAvailableActions(){this.updateHiddenBulkActions()}},computed:{availableActions(){return this.bulkActionsForSelection.filter(e=>!e.external)},keyedAvailableActions(){return this.availableActions.map(e=>e.action)},selectedRowsText(){return this.selectedRows.length?this.t("sortableTable.actionAvailability.selected",{actionable:this.selectedRows.length}):null},actionTooltip(){if(!this.selectedRows.length||!this.actionOfInterest)return null;const e=this.selectedRows.filter(this.canRunBulkActionOfInterest).length;return e===this.selectedRows.length?null:this.t("sortableTable.actionAvailability.some",{actionable:e,total:this.selectedRows.length})}},methods:{onWindowResize(){this.updateHiddenBulkActions(),this.onScroll()},protectedUpdateHiddenBulkActions(){if(!this.$refs.container)return;const e=this.$refs.container.querySelector(`.${this.bulkActionsClass}`),t=this.$refs.container.querySelector(`.${this.bulkActionsDropdownClass}`);if(!e||!t)return;const n=e.offsetWidth,r=this.$refs.container.querySelectorAll(`.${this.bulkActionClass}`),i=Array.from(r||[]),o=this.$refs.container.querySelector(`.${this.bulkActionAvailabilityClass}`);let a=0;this.selectedRowsText&&(o?(o.style.display=St,a=o.offsetWidth):o.style.display="none;"),this.hiddenActions=[];let s=0,l=!1,c=n-a;for(let u=0;u<i.length;u++){const e=i[u];e.style.display=St;const r=e.offsetWidth;if(s+=r+15,s>=c)if(l){const t=e.attributes.getNamedItem("id").value;this.hiddenActions.push(this.availableActions.find(e=>e.action===t)),e.style.display="none"}else t.style.display=St,u=-1,s=0,l=!0,c=n-t.offsetWidth-a}l||(t.style.display="none")}}};const xt=ut;var _t={props:{group:{type:String,default:()=>""},groupOptions:{type:Array,default:()=>[]},hasAdvancedFiltering:{type:Boolean,default:!1},advFilterHideLabelsAsCols:{type:Boolean,default:!1},advFilterPreventFilteringLabels:{type:Boolean,default:!1}},data(){return{columnOptions:[],colOptionsWatcher:null,advancedFilteringVisibility:!1,advancedFilteringValues:[],advFilterSearchTerm:null,advFilterSelectedProp:xt,advFilterSelectedLabel:dt,column:null}},mounted(){this.hasAdvancedFiltering&&this.updateColsOptions()},watch:{advancedFilteringValues(){this.watcherUpdateLiveAndDelayed(!0,!1)},advancedFilteringVisibility(e){e?(window.addEventListener("click",this.onClickOutside),this.updateColsOptions()):window.removeEventListener("click",this.onClickOutside)}},computed:{advFilterSelectOptions(){return this.columnOptions.filter(e=>e.isFilter&&!e.preventFiltering)},advGroupOptions(){return this.groupOptions.map(e=>({label:this.t(e.tooltipKey),value:e.value}))}},methods:{handleColsVisibilyAndFiltering(e){const t=e;return this.columnOptions.forEach(e=>{if(e.isTableOption){const n=t.findIndex(t=>t.name===e.name);-1!==n?(t[n].isColVisible=e.isColVisible,t[n].isFilter=e.isFilter):t.push(e)}}),t},setColsOptions(){let e=[];const t=[],n=[],r=this.headers.slice().filter(e=>!e.maxPageSize||e.maxPageSize&&e.maxPageSize>=this.perPage);return r.forEach(e=>{const t=e.name,r=e.labelKey?this.t(`${e.labelKey}`):e.label,i=!(Object.keys(e).includes("search")&&!e.search);let o=e.sort;const a=e.valueProp||e.value;let s=null,l=!0;if(e.sort&&a?("string"===typeof e.sort&&(o=e.sort.includes(":")?[e.sort.split(":")[0]]:[e.sort]),s=o.includes(a)?JSON.stringify([a]):JSON.stringify(o.concat([a]))):s=a?JSON.stringify([a]):null,this.columnOptions?.length){const e=this.columnOptions.find(e=>e.name===t&&e.label===r);e&&(l=e.isColVisible)}n.push({name:t,label:r,value:s,isFilter:i,isTableOption:!0,isColVisible:l})}),this.rows.length&&this.rows.forEach(e=>{e.metadata?.labels&&Object.keys(e.metadata?.labels).length&&Object.keys(e.metadata?.labels).forEach(e=>{const n={name:e,label:e,value:`metadata.labels.${e}`,isFilter:!0,isTableOption:!0,isColVisible:!1,isLabel:!0,preventFiltering:this.advFilterPreventFilteringLabels,preventColToggle:this.advFilterHideLabelsAsCols};if(this.columnOptions?.length){const t=this.columnOptions.find(t=>t.name===e&&t.label===e);t&&(n.isColVisible=t.isColVisible)}t.filter(t=>t.label===e).length||t.push(n)})}),e=n.concat(t),e.length&&e.unshift({name:dt,label:dt,value:ut,isFilter:!0,isTableOption:!1}),e},addAdvancedFilter(){this.advFilterSelectedProp&&this.advFilterSearchTerm&&(this.advancedFilteringValues.push({prop:this.advFilterSelectedProp,value:this.advFilterSearchTerm,label:this.advFilterSelectedLabel}),this.eventualSearchQuery=this.advancedFilteringValues,this.advancedFilteringVisibility=!1,this.advFilterSelectedProp=xt,this.advFilterSelectedLabel=dt,this.advFilterSearchTerm=null)},clearAllAdvancedFilters(){this.advancedFilteringValues=[],this.eventualSearchQuery=this.advancedFilteringValues,this.advancedFilteringVisibility=!1,this.advFilterSelectedProp=xt,this.advFilterSelectedLabel=dt,this.advFilterSearchTerm=null},clearAdvancedFilter(e){this.advancedFilteringValues.splice(e,1),this.eventualSearchQuery=this.advancedFilteringValues},onClickOutside(e){const t=this.$refs["advanced-filter-group"];t&&!t.contains(e.target)&&(this.advancedFilteringVisibility=!1)},updateColsOptions(){this.columnOptions=this.setColsOptions()},changeColVisibility(e){const t=this.columnOptions.findIndex(t=>t.label===e.label);-1!==t&&(this.columnOptions[t].isColVisible=e.value)}}},kt=n(79380);const Ct={};var At=n(56601),Tt=n(76204),Rt=n(74607),Nt=n(95457),Pt=(0,r.defineComponent)({__name:"TableSelectionActions",props:{actions:{default:()=>[]},count:{default:0},actionTooltip:{default:null},testid:{default:"sortable-table"}},emits:["click","mouseover","mouseleave"],setup(e,{emit:t}){const n=e,i=t,{t:o}=(0,Nt.s)((0,ee.Pj)()),a=(0,r.computed)(()=>n.actions.find(e=>"promptRemove"===e.action)||n.actions.find(e=>!!e.icon&&`${e.icon}`.includes("icon-trash")||/delete|remove/i.test(e.action||""))||null),s=(0,r.computed)(()=>{const e=a.value;return n.actions.filter(t=>!e||t.action!==e.action)}),l=(e,t)=>i("click",e,null,t);return(t,n)=>{const c=(0,r.resolveDirective)("clean-html"),u=(0,r.resolveDirective)("clean-tooltip");return e.count?((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(we.Jj),{key:0,distance:4,placement:"bottom-start"},{dropdownCollection:(0,r.withCtx)(()=>[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(s.value,(t,o)=>(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(we.s$),{key:o,disabled:!t.enabled,"data-testid":`${e.testid}-selection-action-${t.action}`,onClick:e=>l(t,e),onMouseover:e=>i("mouseover",t),onMouseleave:n[0]||(n[0]=e=>i("mouseleave",null))},{before:(0,r.withCtx)(()=>[t.icon||t.svg?((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(Rt.A),{key:0,icon:t.icon,src:t.svg,class:"icon"},null,8,["icon","src"])):(0,r.createCommentVNode)("",!0)]),default:(0,r.withCtx)(()=>[(0,r.withDirectives)((0,r.createElementVNode)("span",null,null,512),[[c,t.label]])]),_:2},1032,["disabled","data-testid","onClick","onMouseover"])),[[u,{content:e.actionTooltip,placement:"right"}]])),128)),a.value?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:0},[s.value.length?((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(we.Gh),{key:0})):(0,r.createCommentVNode)("",!0),(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createBlock)((0,r.unref)(we.s$),{disabled:!a.value.enabled,"data-testid":`${e.testid}-selection-action-delete`,onClick:n[1]||(n[1]=e=>l(a.value,e)),onMouseover:n[2]||(n[2]=e=>i("mouseover",a.value)),onMouseleave:n[3]||(n[3]=e=>i("mouseleave",null))},{before:(0,r.withCtx)(()=>[(0,r.createVNode)((0,r.unref)(Rt.A),{icon:a.value.icon||"icon icon-delete",src:a.value.svg,class:"icon"},null,8,["icon","src"])]),default:(0,r.withCtx)(()=>[(0,r.createElementVNode)("span",null,(0,r.toDisplayString)((0,r.unref)(o)("tableViews.bulk.deleteSelected")),1)]),_:1},8,["disabled","data-testid"])),[[u,{content:e.actionTooltip,placement:"right"}]])],64)):(0,r.createCommentVNode)("",!0)]),default:(0,r.withCtx)(()=>[(0,r.createVNode)((0,r.unref)(we.Nq),{variant:"primary",size:"medium",class:"selection-trigger","data-testid":`${e.testid}-selection-actions`},{after:(0,r.withCtx)(()=>[...n[4]||(n[4]=[(0,r.createElementVNode)("i",{class:"icon icon-chevron-down"},null,-1)])]),default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)((0,r.unref)(o)("tableViews.bulk.selected",{count:e.count}))+" ",1)]),_:1},8,["data-testid"])]),_:1})):(0,r.createCommentVNode)("",!0)}}});n(78786);const It=(0,ve.A)(Pt,[["__scopeId","data-v-4de6ba3f"]]);var Mt=It;const Dt=new Map;let Lt=null;function Bt(e,t){return"undefined"===typeof ResizeObserver?()=>{}:(Lt=Lt||new ResizeObserver(e=>e.forEach(e=>{var t;return null===(t=Dt.get(e.target))||void 0===t?void 0:t()})),Dt.set(e,t),Lt.observe(e),()=>{Dt.delete(e),null===Lt||void 0===Lt||Lt.unobserve(e)})}var $t=(0,r.defineComponent)({__name:"LimitedCell",props:{limits:{}},setup(e){const t=e,n=(0,r.ref)(null),i=(0,r.ref)(""),o=(0,r.computed)(()=>({minWidth:t.limits.minWidth?`${t.limits.minWidth}px`:void 0,maxWidth:t.limits.maxWidth?`${t.limits.maxWidth}px`:void 0,"-webkit-line-clamp":t.limits.lineClamp||void 0,lineClamp:t.limits.lineClamp||void 0})),a=()=>{const e=n.value,r=!!e&&!!t.limits.lineClamp&&(e.scrollHeight>e.clientHeight+1||e.scrollWidth>e.clientWidth+1);i.value=r?(0,oe.ZD)(((null===e||void 0===e?void 0:e.textContent)||"").trim()):""};let s=()=>{};return(0,r.onMounted)(()=>{a(),n.value&&(s=Bt(n.value,a))}),(0,r.onUpdated)(a),(0,r.onBeforeUnmount)(()=>s()),(t,a)=>{const s=(0,r.resolveDirective)("clean-tooltip");return(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("div",{ref_key:"box",ref:n,class:(0,r.normalizeClass)(["limited-cell",{clamped:!!e.limits.lineClamp}]),style:(0,r.normalizeStyle)(o.value)},[(0,r.renderSlot)(t.$slots,"default")],6)),[[s,{content:i.value,placement:"auto",popperClass:["limited-cell-tooltip"]}]])}}});n(48773),n(70803);const Vt=(0,ve.A)($t,[["__scopeId","data-v-c7d17876"]]);var Ft=Vt,jt=n(75886),Ut=n(44544);const Gt=(e,{slots:t})=>t.default?.();Gt.props=["limits"];var Ht={name:"SortableTable",emits:["clickedActionButton","pagination-changed","group-value-change","selection","rowClick","enter","sortable-table-interaction"],components:{THead:ct,Checkbox:de.S,AsyncButton:he.A,ActionDropdown:ye,ActionDropdownShell:Ee,LabeledSelect:at.A,LabeledInput:kt.o,ButtonMultiAction:At.A,ActionMenu:Tt.A,TableSelectionActions:Mt,LimitedCell:Ft,CellContent:Gt,RcButton:ce.a},inject:{providedTableViewsShell:{from:le.lt,default:null}},mixins:[pt,bt.A,wt,Ot,et,Et,_t],props:{headers:{type:Array,required:!0},rows:{type:Array,required:!0},keyField:{type:String,default:"_key"},loading:{type:Boolean,required:!1},altLoading:{type:Boolean,required:!1},groupBy:{type:[String,Function],default:null},groupRef:{type:[String,Function],default:null},groupSort:{type:String,default:null},defaultSortBy:{type:String,default:null},tableActions:{type:Boolean,default:!0},viewFilters:{type:Array,default:()=>[]},queried:{type:Boolean,default:!1},viewQuery:{type:String,default:null},tableViewsLayout:{type:Boolean,default:null},rowActions:{type:Boolean,default:!0},mangleActionResources:{type:Function,default:null},rowActionsWidth:{type:Number,default:40},search:{type:Boolean,default:!0},extraSearchFields:{type:Array,default:null},subRows:{type:Boolean,default:!1},subRowsDescription:{type:Boolean,default:!0},subExpandable:{type:Boolean,default:!1},subExpandColumn:{type:Boolean,default:!1},subSearch:{type:String,default:null},subFields:{type:Array,default:null},topDivider:{type:Boolean,default:!0},bodyDividers:{type:Boolean,default:!1},overflowX:{type:Boolean,default:!1},overflowY:{type:Boolean,default:!1},paging:{type:Boolean,default:!1},pagingLabel:{type:String,default:"sortableTable.paging.generic"},pagingParams:{type:Object,default:null},selectAllLabel:{type:String,default:null},rowsPerPage:{type:Number,default:null},noRowsKey:{type:String,default:"sortableTable.noRows"},showNoRows:{type:Boolean,default:!0},noDataKey:{type:String,default:"sortableTable.noData"},showHeaders:{type:Boolean,default:!0},sortGenerationFn:{type:Function,default:null},sortGeneration:{type:String,default:null},mandatorySort:{type:Array,default:null},getCustomDetailLink:{type:Function,default:null},componentTestid:{type:String,default:"sortable-table"},useQueryParamsForSimpleFiltering:{type:Boolean,default:!1},forceUpdateLiveAndDelayed:{type:Number,default:0},externalPaginationEnabled:{type:Boolean,default:!1},externalPaginationResult:{type:Object,default:null},manualRefreshButtonSize:{type:String,default:""},hideManualRefreshButton:{type:Boolean,default:!1}},data(){let e="",t="";!this.hasAdvancedFiltering&&this.useQueryParamsForSimpleFiltering&&this.$route.query?.q&&(e=this.$route.query?.q,t=this.$route.query?.q);const n=this.loading||!1;return{refreshButtonPhase:n?he.R.WAITING:he.R.ACTION,expanded:{},searchQuery:e,eventualSearchQuery:t,subMatches:null,actionOfInterest:null,loadingDelay:!1,debouncedPaginationChanged:null,isLoading:n}},mounted(){this._loadingDelayTimer=setTimeout(()=>{this.loadingDelay=!0},200);const e=document.querySelector("main");this._onScroll=this.onScroll.bind(this),e?.addEventListener("scroll",this._onScroll),this.debouncedPaginationChanged(),this.updateTabCount(this.totalRows)},beforeUnmount(){clearTimeout(this._scrollTimer),clearTimeout(this._loadingDelayTimer),clearTimeout(this._altLoadingDelayTimer),clearTimeout(this._liveColumnsTimer),clearTimeout(this._delayedColumnsTimer),clearTimeout(this.manualRefreshTimer);const e=document.querySelector("main");e?.removeEventListener("scroll",this._onScroll),this.clearTabCount()},watch:{viewFilters(e,t){JSON.stringify(e||[])!==JSON.stringify(t||[])&&(this.setPage(1),this.debouncedPaginationChanged())},viewQuery(){this.debouncedPaginationChanged()},eventualSearchQuery:Ce()(function(e){if(this.searchQuery=e,!this.hasAdvancedFiltering&&this.useQueryParamsForSimpleFiltering){const t={name:this.$route.name,params:{...this.$route.params},query:{...this.$route.query,q:e}};!e&&this.$route.query?.q&&(t.query={}),this.$router.replace(t)}},200),descending(e,t){this.watcherUpdateLiveAndDelayed(e,t)},searchQuery(e,t){this.watcherUpdateLiveAndDelayed(e,t)},sortFields(e,t){this.watcherUpdateLiveAndDelayed(e,t)},groupBy(e,t){this.watcherUpdateLiveAndDelayed(e,t)},namespaces(e,t){this.watcherUpdateLiveAndDelayed(e,t)},page(e,t){this.watcherUpdateLiveAndDelayed(e,t)},forceUpdateLiveAndDelayed(e,t){this.watcherUpdateLiveAndDelayed(e,t)},initalLoad:{handler(e){e&&(this._didinit=!0,this.$nextTick(()=>this.updateLiveAndDelayed()))},immediate:!0},manualRefreshLoadingFinished:{handler(e,t){this.refreshButtonPhase=e?he.R.ACTION:he.R.WAITING,e&&e!==t&&this.$nextTick(()=>this.updateLiveAndDelayed())},immediate:!0},loading:{handler(e,t){this.refreshButtonPhase=e?he.R.WAITING:he.R.ACTION,this.altLoading?e?this._altLoadingDelayTimer=setTimeout(()=>{this.isLoading=!0},200):(clearTimeout(this._altLoadingDelayTimer),this.isLoading=!1):this.isLoading=e},immediate:!0}},setup(e,{emit:t}){const n=(0,r.ref)(null),i=e=>{"Enter"!==e.key||e.target?.classList?.contains("checkbox-custom")||t("enter",e)};(0,r.onMounted)(()=>{n.value.addEventListener("keyup",i)}),(0,r.onBeforeUnmount)(()=>{n.value.removeEventListener("keyup",i)});const o=(0,ee.Pj)(),{featureDropdownMenu:a}=(0,jt.K)(o),{updateTabCount:s,clearTabCount:l}=(0,Ut.Dg)();return{table:n,featureDropdownMenu:a,updateTabCount:s,clearTabCount:l}},created(){this.debouncedRefreshTableData=Ce()(this.refreshTableData,500),this.debouncedPaginationChanged=Ce()(this.paginationChanged,50)},computed:{...(0,ee.L8)({isTooManyItemsToAutoUpdate:"resource-fetch/isTooManyItemsToAutoUpdate"}),...(0,ee.L8)({isManualRefreshLoading:"resource-fetch/manualRefreshIsLoading"}),namespaces(){return this.$store.getters["activeNamespaceCache"]},initalLoad(){return!(this.isLoading||this._didinit||!this.rows?.length)},selectAllCheckboxLabel(){const e=this.selectAllLabel||this.pagingParams?.pluralLabel;return e?this.t("sortableTable.selectAllResources",{resource:e}):this.t("sortableTable.genericGroupCheckbox")},manualRefreshLoadingFinished(){const e=!(this.isLoading||!this._didinit||!this.rows?.length||this.isManualRefreshLoading);return e},fullColspan(){let e=0;for(let t=0;t<this.columns.length;t++)this.columns[t].hide||e++;return this.tableActions&&e++,this.subExpandColumn&&e++,this.rowActions&&e++,e},noResults(){return(!!this.searchQuery||this.queried)&&0===this.pagedRows.length},noRows(){return!this.noResults&&0===(this.rows||[]).length},useTableViewsLayout(){const e=this.tableViewsLayout;return null!==e&&void 0!==e?e:(0,le.Q_)(this.$store)&&!(0,le.o6)({providedShell:this.providedTableViewsShell,route:this.$route,extensions:this.$store?.state?.$extension})},tableViewsTopRowEmpty(){return this.useTableViewsLayout&&!this.$slots["header-left"]&&!this.$slots["header-middle"]},tableViewsTabsEmpty(){return this.useTableViewsLayout&&!this.$slots["table-views"]},showHeaderRow(){return this.search||this.tableActions||this.$slots["header-left"]||this.$slots["header-middle"]||this.$slots["header-right"]||this.isTooManyItemsToAutoUpdate},columns(){const e=this.headers.slice().filter(e=>!e.maxPageSize||e.maxPageSize&&e.maxPageSize>=this.perPage);if(this.groupBy){const t=e.find(e=>e.name===this.groupBy);t&&(0,ue.Gj)(e,t)}const t=e.find(e=>!e.width);if(!t){const t=e.find(e=>e.canBeVariable);if(t){const n=(0,ae.o8)(t);delete n.width,e.splice(e.indexOf(t),1,n)}}if(this.hasAdvancedFiltering){const t=this.handleColsVisibilyAndFiltering(e);return t}return e},dt(){const e={check:"Select: ",actions:"Actions: "};return this.columns.forEach(t=>{e[t.name]=`${t.label||t.name}:`}),e},classObject(){return{"top-divider":this.topDivider,"body-dividers":this.bodyDividers,"overflow-y":this.overflowY,"overflow-x":this.overflowX,"alt-loading":this.altLoading&&this.isLoading}},hasLiveColumns(){const e=this.columns.find(e=>e.formatter?.startsWith("Live")||e.liveUpdates);return!!e},hasDelayedColumns(){const e=this.columns.find(e=>e.delayLoading);return!!e},columnFormmatterIDs(){const e={};return this.columns.forEach(t=>{t.formatter&&(e[t.formatter]=(0,oe._k)(t.formatter))}),e},displayRows(){const e=[],t=this.columnFormmatterIDs,n={};return this.columns.forEach(e=>{(e.minWidth||e.maxWidth||e.lineClamp)&&(n[e.name]={minWidth:e.minWidth,maxWidth:e.maxWidth,lineClamp:e.lineClamp})}),this.groupedRows.forEach(i=>{const o={grp:i,key:i.key,ref:i.ref,rows:[]};e.push(o),i.rows.forEach(e=>{const i={row:e,key:this.get(e,this.keyField)??(0,oe.vx)(),showSubRow:this.showSubRow(e,this.keyField),canRunBulkActionOfInterest:this.canRunBulkActionOfInterest(e),columns:[]};o.rows.push(i),this.columns.forEach(o=>{const a=o.delayLoading?void 0:this.valueFor(e,o,o.isLabel);let s,l=a,c=!1;if(Array.isArray(a)&&(l=a.join(", ")),o.formatter)if(Ct[o.formatter])s=Ct[o.formatter],c=!0;else{const e=this.$extension?.getDynamic("formatters",o.formatter);e&&(s=(0,r.defineAsyncComponent)(e),c=!0)}i.columns.push({col:o,value:a,formatted:l,component:s,needRef:c,delayed:o.delayLoading,live:o.formatter?.startsWith("Live")||o.liveUpdates,label:this.labelFor(o),dasherize:t[o.formatter]||"",limits:n[o.name]})})})}),e}},methods:{refreshTableData(){this.$store.dispatch("resource-fetch/doManualRefresh")},get:ae.Jt,dasherize:oe._k,onScroll(){(this.hasLiveColumns||this.hasDelayedColumns)&&(clearTimeout(this._liveColumnsTimer),clearTimeout(this._scrollTimer),clearTimeout(this._delayedColumnsTimer),this._scrollTimer=setTimeout(()=>{this.updateLiveColumns(),this.updateDelayedColumns()},300))},watcherUpdateLiveAndDelayed(e,t){e!==t&&this.$nextTick(()=>this.updateLiveAndDelayed())},updateLiveAndDelayed(){this.hasLiveColumns&&this.updateLiveColumns(),this.hasDelayedColumns&&this.updateDelayedColumns()},updateDelayedColumns(){if(clearTimeout(this._delayedColumnsTimer),!this.$refs.column||0===this.pagedRows.length)return;const e=this.$refs.column.filter(e=>e.startDelayedLoading&&!e.__delayedLoading),t=(window.innerHeight||document.documentElement.clientHeight)+100;let n=0;for(let r=0;r<e.length;r++){const i=e[r],o=i.$el.getBoundingClientRect().y;if(o>=0&&o<=t&&(i.startDelayedLoading(!0),i.__delayedLoading=!0,n++,4===n))return void(this._delayedColumnsTimer=setTimeout(this.updateDelayedColumns,100))}},updateLiveColumns(){if(clearTimeout(this._liveColumnsTimer),!this.$refs.column||!this.hasLiveColumns||0===this.pagedRows.length)return;const e=window.innerHeight||document.documentElement.clientHeight,t=this.$refs.column.filter(e=>!!e.liveUpdate),n=ne()();let r=Number.MAX_SAFE_INTEGER;for(let i=0;i<t.length;i++){const o=t[i],a=o.$el.getBoundingClientRect().y;if(a>=0&&a<=e){const e=o.liveUpdate(n);e<r&&(r=e)}}r<1&&(r=1),this._liveColumnsTimer=setTimeout(()=>this.updateLiveColumns(),1e3*r)},labelFor(e){return e.labelKey?this.t(e.labelKey,void 0,!0):e.label?e.label:(0,oe.TF)(e.name)},rowCheckboxLabel(e){const t=e?.row?.id;return t?this.t("sortableTable.genericRowCheckbox",{item:t}):this.t("sortableTable.genericRowCheckboxNoItem")},valueFor(e,t,n){return(0,se.X)(e,t,n)},isExpanded(e){const t=e[this.keyField];return!!this.expanded[t]},toggleExpand(e){const t=e[this.keyField],n=!this.expanded[t];return this.expanded[t]=n,this.expanded={...this.expanded},n},setBulkActionOfInterest(e){this.actionOfInterest=e},canRunBulkActionOfInterest(e){if(!this.actionOfInterest||ie()(e?.availableActions))return!1;const t=e.availableActions?.find(e=>e.action===this.actionOfInterest.action);return t?.enabled},focusSearch(){this.$refs.searchQuery&&(this.$refs.searchQuery.focus(),this.$refs.searchQuery.select())},nearestCheckbox(){return document.activeElement.closest("tr.main-row")?.querySelector(".checkbox-custom")},focusAdjacent(e=!0){const t=Array.from(this.$el.querySelectorAll(".checkbox-custom")),n=this.nearestCheckbox();let r=-1;return r=n?t.indexOf(n)+(e?1:-1):e?1:t.length-1,r<1?(r=1,null):r>=t.length?(r=t.length-1,null):t[r]?(t[r].focus(),t[r]):void 0},focusNext:_e()(function(e,t=!1){const n=this.focusAdjacent(!0),r=We(n,"tr");r?.classList.contains("row-selected")||this.keySelectRow(r,t)},50),focusPrevious:_e()(function(e,t=!1){const n=this.focusAdjacent(!1),r=We(n,"tr");r?.classList.contains("row-selected")||this.keySelectRow(r,t)},50),showSubRow(e,t){const n=this.subRows&&(!this.subExpandable||this.expanded[(0,ae.Jt)(e,t)]),r=this.subRowsDescription&&e.stateDescription;return n||r},handleActionButtonClick(e,t){this.$emit("clickedActionButton",{event:t,targetElement:this.$refs[`actionButton${e}`][0]})},paginationChanged(){this.$emit("sortable-table-interaction",{pagination:{page:this.page,perPage:this.perPage},filtering:{searchFields:this.searchFields,searchQuery:this.viewQuery??this.searchQuery},sorting:{sort:this.sortFields,sortBy:this.sortBy,descending:this.descending}}),this.externalPaginationEnabled&&this.$emit("pagination-changed",{page:this.page,perPage:this.perPage,filter:{searchFields:this.searchFields,searchQuery:this.searchQuery},sort:this.sortFields,descending:this.descending,viewFilters:this.viewFilters})}}};n(88743),n(45825);const qt=(0,ve.A)(Ht,[["render",J],["__scopeId","data-v-3b705a56"]]);var Qt=qt},35601:function(e,t,n){"use strict";n.d(t,{A:function(){return c}});var r=n(9274),i=n(8187);const o={class:"state-dot"};var a=(0,r.defineComponent)({__name:"index",props:{color:{},size:{default:"8px"}},setup(e){(0,r.useCssVars)(e=>({v34a0a70d:t.size,v7e32a647:n.value}));const t=e,n=(0,r.computed)(()=>(0,i.zL)(t.color));return(e,t)=>((0,r.openBlock)(),(0,r.createElementBlock)("span",o))}}),s=(n(94210),n(47433));const l=(0,s.A)(a,[["__scopeId","data-v-2001ed60"]]);var c=l},22896:function(e,t,n){"use strict";n.d(t,{A:function(){return c}});var r=n(65359);function i(...e){document.title=e.filter(e=>e).join(" - ")}var o=n(49845),a=n(4364),s={props:{breadcrumb:{type:[String,Boolean],default:"full",validator(e){return["full","vendor-only"].includes(e)||!1===e}},includeVendor:{type:Boolean,default:!0},showChild:{type:Boolean,default:!0}},computed:{...(0,r.L8)(["isExplorer","currentCluster","currentProduct"])},methods:{computeTitle(){if(!this.$slots.default||"string"!==typeof this.$slots.default()[0].children)return a.error("The <TabTitle> component only supports text as the child."),[];const e=[this.$slots.default()[0].children.trim()];if("full"===this.breadcrumb)if(this.currentCluster&&(this.isExplorer||this.currentCluster.isHarvester))e.unshift(this.currentCluster.nameDisplay);else if(this.currentProduct?.name){const t=this.$store.getters["i18n/withFallback"](`product.${this.currentProduct.name}`,null,null);t&&e.unshift(t)}return this.includeVendor&&["full","vendor-only"].includes(this.breadcrumb)&&e.unshift((0,o.f7)()),e},updatePageTitle(){i(...this.computeTitle())}},created(){this.updatePageTitle()},render(){return this.updatePageTitle(),this.showChild?this.$slots.default():null}};const l=s;var c=l},97955:function(e,t,n){"use strict";n.d(t,{A:function(){return m}});var r=n(9274);const i=["id","aria-labelledby","data-testid"],o={key:0,class:"tab-header"},a={key:0,class:"icon icon-info icon-lg"};function s(e,t,n,s,l,c){const u=(0,r.resolveDirective)("clean-tooltip");return(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("section",{id:`${c.instanceUid}-${n.name}`,ref:"tab-summarized-container",class:"tab-panel",role:"tabpanel","aria-labelledby":`tab-${c.instanceUid}-${n.name}`,"data-testid":`tab-panel-${n.name}`,tabindex:"0"},[c.shouldShowHeader?((0,r.openBlock)(),(0,r.createElementBlock)("div",o,[(0,r.createElementVNode)("h2",null,[(0,r.createTextVNode)((0,r.toDisplayString)(c.labelDisplay)+" ",1),n.tooltip?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("i",a,null,512)),[[u,n.tooltip]]):(0,r.createCommentVNode)("",!0)]),(0,r.renderSlot)(e.$slots,"tab-header-right",{},void 0,!0)])):(0,r.createCommentVNode)("",!0),(0,r.renderSlot)(e.$slots,"default",(0,r.normalizeProps)((0,r.guardReactiveProps)({active:l.active})),void 0,!0)],8,i)),[[r.vShow,l.active]])}var l=n(44544),c=n(95811),u=n(65359),d=n(95457),h={name:"Tab",inject:["addTab","removeTab","sideTabs","select","instanceUid"],emits:["active"],props:{label:{default:null,type:String},labelKey:{default:null,type:String},labelIcon:{type:String,default:null},name:{required:!0,type:String},tooltip:{default:null,type:[String,Object]},weight:{default:0,required:!1,type:Number},showHeader:{type:Boolean,default:null},displayAlertIcon:{type:Boolean,default:null},error:{type:Boolean,default:!1},errorIconTooltip:{type:String,default:""},badge:{default:0,required:!1,type:Number},count:{default:void 0,type:[Number,Boolean]}},setup(e){const t=(0,r.inject)("select"),n=(0,u.Pj)(),{t:i}=(0,d.s)(n),o=(0,r.computed)(()=>e.labelKey&&"function"===typeof i?i(e.labelKey):e.label??e.name),{count:a,isCountVisible:s}=(0,l.qz)(),h=(0,r.useTemplateRef)("tab-summarized-container"),{summary:p}=(0,c.B)({scrollTo:()=>t(e.name),label:o,elementRef:h});return{inferredCount:a,isInferredCountVisible:s,summary:p}},data(){return{active:null}},computed:{baseLabelDisplay(){return this.labelKey?this.$store.getters["i18n/t"](this.labelKey):this.label?this.label:this.name},labelDisplay(){const e=this.baseLabelDisplay;return!1===this.displayCount?e:`${e} (${this.displayCount})`},shouldShowHeader(){return null!==this.showHeader?this.showHeader:this.sideTabs||!1},displayCount(){return!1!==this.count&&("number"===typeof this.count?this.count:!!this.isInferredCountVisible&&this.inferredCount)}},watch:{active(e){e&&this.$emit("active")}},mounted(){this.addTab(this)},beforeUnmount(){this.removeTab(this)}},p=(n(46863),n(47433));const f=(0,p.A)(h,[["render",s],["__scopeId","data-v-7eb30ea9"]]);var m=f},94681:function(e,t,n){"use strict";n.d(t,{A:function(){return M}});var r=n(9274);const i=["data-testid"],o=["data-testid","aria-orientation"],a=["data-testid"],s=["id","data-testid","aria-controls","aria-selected","aria-disabled","aria-label","tabindex","onClick","onKeydown"],l={key:1,class:"tab-badge"},c={key:2,class:"conditions-alert-icon icon-error"},u={key:0,class:"tab disabled",role:"presentation"},d={key:1,class:"tab-list-footer",role:"presentation"},h={class:"tab-list-footer-controls"},p=["aria-label"],f=["disabled","aria-label"];function m(e,t,n,m,g,v){const b=(0,r.resolveComponent)("Tab"),y=(0,r.resolveDirective)("clean-tooltip");return(0,r.openBlock)(),(0,r.createElementBlock)("div",{ref:"tabbed-summarized-container",class:(0,r.normalizeClass)(["tabbed-container",{"side-tabs":!!n.sideTabs,"tabs-only":n.tabsOnly,"remove-borders":n.removeBorders}]),"data-testid":n.componentTestid},[v.hideTabs?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:0,class:(0,r.normalizeClass)(["tabs",{clearfix:!n.sideTabs,vertical:n.sideTabs,horizontal:!n.sideTabs,"remove-borders":n.removeBorders}])},[(0,r.createElementVNode)("ul",{ref:"tablist",role:"tablist",class:"tab-list","data-testid":`${n.componentTestid}-block`,"aria-orientation":n.sideTabs?"vertical":"horizontal"},[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(v.sortedTabs,i=>((0,r.openBlock)(),(0,r.createElementBlock)("li",{key:i.name,"data-testid":i.name,role:"presentation",class:(0,r.normalizeClass)({tab:!0,active:i.active,disabled:i.disabled,error:i.error})},[(0,r.createElementVNode)("a",{id:v.tabButtonId(i.name),ref_for:!0,ref:e=>{e&&(g.tabRefs[i.name]=e)},"data-testid":`btn-${i.name}`,"aria-controls":n.externalPanelId||`${m.instanceUid}-${i.name}`,"aria-selected":!!i.active,"aria-disabled":i.disabled?"true":void 0,"aria-label":i.labelDisplay||"",role:"tab",tabindex:i.active?"0":"-1",onClick:(0,r.withModifiers)(e=>v.select(i.name,e),["prevent"]),onKeydown:[(0,r.withKeys)((0,r.withModifiers)(e=>v.select(i.name,e),["prevent"]),["enter"]),(0,r.withKeys)((0,r.withModifiers)(e=>v.select(i.name,e),["prevent"]),["space"]),t[0]||(t[0]=(0,r.withKeys)((0,r.withModifiers)(e=>v.selectNext(1),["prevent"]),["right"])),t[1]||(t[1]=(0,r.withKeys)((0,r.withModifiers)(e=>v.selectNext(-1),["prevent"]),["left"])),t[2]||(t[2]=(0,r.withKeys)((0,r.withModifiers)(e=>v.selectNext(1),["prevent"]),["down"])),t[3]||(t[3]=(0,r.withKeys)((0,r.withModifiers)(e=>v.selectNext(-1),["prevent"]),["up"])),t[4]||(t[4]=(0,r.withKeys)((0,r.withModifiers)(e=>v.selectEdge("first"),["prevent"]),["home"])),t[5]||(t[5]=(0,r.withKeys)((0,r.withModifiers)(e=>v.selectEdge("last"),["prevent"]),["end"]))]},[i.labelIcon?((0,r.openBlock)(),(0,r.createElementBlock)("i",{key:0,class:(0,r.normalizeClass)(`tab-label-icon icon ${i.labelIcon}`)},null,2)):(0,r.createCommentVNode)("",!0),(0,r.createElementVNode)("span",null,(0,r.toDisplayString)(i.labelDisplay),1),i.badge?((0,r.openBlock)(),(0,r.createElementBlock)("span",l,(0,r.toDisplayString)(i.badge),1)):(0,r.createCommentVNode)("",!0),v.hasErrorIcon(i)?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("i",c,null,512)),[[y,i.errorIconTooltip||e.t("validation.tab")]]):(0,r.createCommentVNode)("",!0)],40,s)],10,a))),128))],8,o),n.sideTabs&&!v.sortedTabs.length?((0,r.openBlock)(),(0,r.createElementBlock)("div",u,[(0,r.createElementVNode)("a",{href:"#",onClick:t[6]||(t[6]=(0,r.withModifiers)(()=>{},["prevent"]))},"(None)")])):(0,r.createCommentVNode)("",!0),n.sideTabs&&n.showTabsAddRemove?((0,r.openBlock)(),(0,r.createElementBlock)("div",d,[(0,r.createElementVNode)("div",h,[(0,r.createElementVNode)("button",{type:"button",class:"btn bg-transparent","data-testid":"tab-list-add","aria-label":e.t("tabs.addItem"),onClick:t[7]||(t[7]=(...e)=>v.tabAddClicked&&v.tabAddClicked(...e))},[...t[9]||(t[9]=[(0,r.createElementVNode)("i",{class:"icon icon-plus"},null,-1)])],8,p),(0,r.createElementVNode)("button",{type:"button",class:"btn bg-transparent",disabled:!v.sortedTabs.length,"data-testid":"tab-list-remove","aria-label":e.t("tabs.removeItem"),onClick:t[8]||(t[8]=(...e)=>v.tabRemoveClicked&&v.tabRemoveClicked(...e))},[...t[10]||(t[10]=[(0,r.createElementVNode)("i",{class:"icon icon-minus"},null,-1)])],8,f)])])):(0,r.createCommentVNode)("",!0),(0,r.renderSlot)(e.$slots,"tab-row-extras",{},void 0,!0)],2)),(0,r.createElementVNode)("div",{class:(0,r.normalizeClass)({"tab-container":!!g.tabs.length||!!n.sideTabs,"no-content":n.noContent,"tab-container--flat":!!n.flat})},[(0,r.renderSlot)(e.$slots,"default",{},void 0,!0),((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(g.extensionTabs,(e,t)=>((0,r.openBlock)(),(0,r.createBlock)(b,{key:`${e.name}${t}`,name:e.name,label:e.label,"label-key":e.labelKey,"label-icon":e.labelIcon,weight:e.weight,tooltip:e.tooltip,"show-header":e.showHeader,"display-alert-icon":e.displayAlertIcon,error:e.error,"error-icon-tooltip":e.errorIconTooltip,badge:e.badge},{default:(0,r.withCtx)(()=>[((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(e.component),{resource:n.resource,onSelect:t=>v.select(e.name)},null,40,["resource","onSelect"]))]),_:2},1032,["name","label","label-key","label-icon","weight","tooltip","show-header","display-alert-icon","error","error-icon-tooltip","badge"]))),128))],2)],10,i)}var g=n(13981),v=n.n(g),b=n(3514),y=n.n(b),w=n(68851),O=n(74302),S=n(92154),E=n.n(S),x=n(31915),_=n(25659),k=n(97955),C=n(89366),A=n(91452),T=n(3889),R=n(95811),N={name:"Tabbed",components:{Tab:k.A},emits:["changed","addTab","removeTab"],props:{defaultTab:{type:String,default:null},sideTabs:{type:Boolean,default:!1},hideSingleTab:{type:Boolean,default:!1},showTabsAddRemove:{type:Boolean,default:!1},scrollOnChange:{type:Boolean,default:!1},useHash:{type:Boolean,default:!0},noContent:{type:Boolean,default:!1},flat:{type:Boolean,default:!1},tabsOnly:{type:Boolean,default:!1},resource:{type:Object,default:()=>{}},showExtensionTabs:{type:Boolean,default:!0},extensionParams:{type:Object,default:null},componentTestid:{type:String,default:"tabbed"},removeBorders:{type:Boolean,default:!1},title:{type:String,default:null},externalPanelId:{type:String,default:null}},provide(){const e=this.tabs;return{select:this.select,sideTabs:this.sideTabs,instanceUid:this.instanceUid,addTab(t){const n=(0,w.jq)(e,"name",t.name);n&&(0,w.Gj)(e,n),(0,w.PG)(e,t)},removeTab(t){(0,w.Gj)(e,t)}}},data(){const e=this.getInitialTabLocation();let t=this.showExtensionTabs&&(0,_.A)(this,x.c7.TAB,e,this.$route,this,this.extensionParams)||[];const n=this.showExtensionTabs&&(0,_.A)(this,x.c7.TAB,x.lX.RESOURCE_DETAIL,this.$route,this,this.extensionParams)||[];t.length||(t=n);const r=t.map(e=>({...e,active:!1}));return{tabs:[...r],extensionTabs:r,activeTabName:null,tabRefs:{}}},computed:{sortedTabs(){return(0,O.Ul)(this.tabs,["weight:desc","labelDisplay","name"])},hideTabs(){return this.hideSingleTab&&1===this.sortedTabs.length}},setup(e){const t=(0,r.useId)(),n=(0,r.ref)((0,C.R7)()),i=(0,r.ref)((0,A.x)()),o=(0,r.ref)((0,T.UN)()),a=(0,r.ref)((0,T.cB)()),s=(0,r.useTemplateRef)("tabbed-summarized-container"),{summary:l}=(0,R.B)({label:(0,r.computed)(()=>e.title??""),scrollTo:()=>s.value?.scrollIntoView(!0),elementRef:s});return{instanceUid:t,isInResourceDetailDrawer:n,isInResourceDetailPage:i,isInResourceEditPage:o,isInResourceCreatePage:a,summary:l}},watch:{sortedTabs(e){const{defaultTab:t,useHash:n}=this,r=e.find(e=>e.active),i=n?this.$route.hash:void 0,o=n?i.slice(1):void 0,a=e.find(e=>e.name===o&&!e.active),s=v()(e)||null;y()(r)?n&&!y()(a)?this.select(a.name):y()(t)||y()(e.find(e=>e.name===t))?s?.name&&this.select(s.name):this.select(t):n&&r?.name===o&&this.select(r.name)},"$route.hash"(){this.useHash&&this.hashChange()}},methods:{tabButtonId(e){return`tab-${this.instanceUid}-${e}`},getInitialTabLocation(){return this.isInResourceEditPage?x.lX.RESOURCE_EDIT_PAGE:this.isInResourceDetailDrawer?x.lX.RESOURCE_SHOW_CONFIGURATION:this.isInResourceDetailPage?x.lX.RESOURCE_DETAIL_PAGE:this.isInResourceCreatePage?x.lX.RESOURCE_CREATE_PAGE:x.lX.OTHER},hasErrorIcon(e){return e.displayAlertIcon||e.error&&!e.active},hashChange(){if(this.scrollOnChange){const e=document.getElementsByTagName("main")[0];e&&(e.scrollTop=0)}this.select(this.$route.hash)},find(e){return this.sortedTabs.find(t=>t.name===e)},select(e){const{sortedTabs:t}=this,n=e.replace("#",""),r=this.find(n),i=`#${n}`;if(r&&!r.disabled){if(this.useHash){const e=this.$router.currentRoute._value,t=e.hash;if(this.useHash&&t!==i){const t={...e};t.hash=i,this.$router.replace(t)}}for(const e of t)e.active=e.name===r.name;this.$emit("changed",{tab:r,selectedName:r.name,tabButtonId:this.tabButtonId(r.name)}),this.activeTabName=r.name}},selectNext(e){const{sortedTabs:t}=this;if(!t.length)return;const n=t.findIndex(e=>e.active),r=i(n,e,t.length);function i(e,t,n){const r=e+t;return r>=n?0:r<0?n-1:r}this.selectAndFocus(t[r].name)},selectEdge(e){const{sortedTabs:t}=this;if(!t.length)return;const n="first"===e?t[0]:t[t.length-1];this.selectAndFocus(n.name)},selectAndFocus(e){this.select(e),this.$nextTick(()=>{this.tabRefs[e]?.focus()})},tabAddClicked(){const e=E()(this.tabs,e=>e.active);this.$emit("addTab",e)},tabRemoveClicked(){const e=E()(this.tabs,e=>e.active);this.$emit("removeTab",e)}}},P=(n(3184),n(47433));const I=(0,P.A)(N,[["render",m],["__scopeId","data-v-616212ec"]]);var M=I},38283:function(e,t,n){"use strict";n.d(t,{default:function(){return S}});var r=n(9274),i=n(65359),o=n(10196),a=n(47879),s=n(51433),l=n(25509),c=n(6198),u=n(92043),d=n(20138),h=n(95457),p=n(51173),f=n(4364);const m={class:"export-modal","data-testid":"table-views-export-modal"},g={class:"export-content"},v={class:"export-actions"},b=1e3;var y=(0,r.defineComponent)({__name:"TableViewExportModal",props:{count:{default:0},viewName:{default:""},isSelection:{type:Boolean,default:!1},resources:{default:()=>[]}},emits:["close","export"],setup(e,{emit:t}){const n=["yaml","json","csv"],y=e,w=t,O=(0,i.Pj)(),{t:S}=(0,h.s)(O),E=(0,r.ref)(y.isSelection?"yaml":"csv"),x=(0,r.computed)(()=>n.map(e=>({value:e,label:S(`tableViews.export.format.${e}`)}))),_=(0,r.computed)(()=>{var e,t,n;const r=y.resources[0],i=null===r||void 0===r?void 0:r.schema;if(!i)return[];const o=!!(null===(n=null===(t=null===(e=r.$ctx)||void 0===e?void 0:e.getters)||void 0===t?void 0:t.paginationEnabled)||void 0===n?void 0:n.call(t,{id:r.type})),a=O.getters["type-map/headersFor"](i,o);return(0,d.lo)(a,e=>S(e))}),k=(0,r.computed)(()=>y.isSelection?S("tableViews.export.selectionTitle"):S("tableViews.export.title")),C=(0,r.computed)(()=>{var e;const t=(null!==(e=y.count)&&void 0!==e?e:0)>b;if(y.isSelection)return{k:t?"tableViews.export.selectionIntroSlow":"tableViews.export.selectionIntro",args:{count:y.count}};const n=(0,u.ZD)(y.viewName);return null===y.count?{k:"tableViews.export.introUncounted",args:{name:n}}:{k:t?"tableViews.export.introSlow":"tableViews.export.intro",args:{count:y.count,name:n}}}),A=async(e,t,n,r)=>{const i=e[0];if("yaml"===t)return 1===e.length?(await i.downloadYaml(),`${i.nameDisplay}.yaml`):(await i.downloadYamlBulk(e,r),"resources.zip");const o=((null===i||void 0===i?void 0:i.type)||"resources").replace(/[^a-z0-9]+/gi,"-");return"json"===t?(await(0,c.PE)(`${o}.json`,(0,d.hz)(e,n),"application/json;charset=utf-8"),`${o}.json`):(await(0,c.PE)(`${o}.csv`,(0,d.lH)(e,n),"text/csv;charset=utf-8"),`${o}.csv`)},T=e=>{const t=e.length,{schema:n,type:r}=e[0]||{};return n&&e.every(e=>e.type===r)?O.getters["type-map/labelFor"](n,t):S("tableViews.export.notification.items",{count:t})},R=async(e,t,n)=>{const r=e.length,i=T(e),o=await O.dispatch("notifications/add",{level:p.SG.Task,title:S("tableViews.export.notification.title"),message:S("tableViews.export.notification.selectionMessage",{count:r,type:i,format:t.toUpperCase()},!0),progress:0}),a=(e,t)=>O.dispatch("notifications/update",{id:o,progress:Math.round(100*e/(t||1))});try{const s=await A(e,t,n,a);await O.dispatch("notifications/update",{id:o,level:p.SG.Success,title:S("tableViews.export.notification.doneTitle"),message:S("tableViews.export.notification.selectionDoneMessage",{count:r,type:i,file:s},!0),progress:100})}catch(s){f.error("Unable to export the selection",s),await O.dispatch("notifications/update",{id:o,level:p.SG.Error,title:S("tableViews.export.notification.failedTitle"),message:S("tableViews.export.notification.selectionFailedMessage",{count:r,type:i},!0)})}},N=()=>{if(y.resources.length){const e=[...y.resources],t=E.value,n=_.value;return w("close"),void R(e,t,n).catch(e=>f.error("Unable to export the selection",e))}w("export",E.value),w("close")};return(e,t)=>{const n=(0,r.resolveDirective)("clean-html");return(0,r.openBlock)(),(0,r.createElementBlock)("div",m,[(0,r.createElementVNode)("div",g,[(0,r.createVNode)((0,r.unref)(l.m),{size:3,class:"export-title","data-modal-title":""},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(k.value),1)]),_:1}),(0,r.createVNode)(a.A,{k:C.value.k,args:C.value.args,tag:"p",class:"export-intro"},{b:(0,r.withCtx)(({content:e})=>[(0,r.withDirectives)((0,r.createElementVNode)("b",null,null,512),[[n,e]])]),_:1},8,["k","args"]),(0,r.createVNode)(a.A,{k:"tableViews.export.choose",tag:"p",class:"export-choose"},{b:(0,r.withCtx)(({content:e})=>[(0,r.withDirectives)((0,r.createElementVNode)("b",null,null,512),[[n,e]])]),_:1}),(0,r.createVNode)((0,r.unref)(o.z),{value:E.value,"onUpdate:value":t[0]||(t[0]=e=>E.value=e),name:"table-views-export-format",class:"export-formats",options:x.value,row:!0,"aria-label":k.value,"data-testid":"table-views-export-formats"},null,8,["value","options","aria-label"])]),(0,r.createElementVNode)("div",v,[(0,r.createVNode)((0,r.unref)(s.a),{variant:"link",size:"large","data-testid":"table-views-export-cancel",onClick:t[1]||(t[1]=e=>w("close"))},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)((0,r.unref)(S)("generic.cancel")),1)]),_:1}),(0,r.createVNode)((0,r.unref)(s.a),{variant:"primary",size:"large","left-icon":"download","data-testid":"table-views-export-download",onClick:N},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)((0,r.unref)(S)("tableViews.export.download")),1)]),_:1})])])}}}),w=(n(40533),n(47433));const O=(0,w.A)(y,[["__scopeId","data-v-015f7b08"]]);var S=O},8529:function(e,t,n){"use strict";n.d(t,{A:function(){return c}});var r=n(9274);const i={class:"tag"};function o(e,t,n,o,a,s){return(0,r.openBlock)(),(0,r.createElementBlock)("span",i,[(0,r.renderSlot)(e.$slots,"default",{},void 0,!0)])}var a={},s=(n(4901),n(47433));const l=(0,s.A)(a,[["render",o],["__scopeId","data-v-0d281a35"]]);var c=l},89559:function(e,t,n){"use strict";n.d(t,{A:function(){return p}});var r=n(9274);function i(e,t,n,i,o,a){const s=(0,r.resolveComponent)("Banner");return a.typeDescriptionKey?((0,r.openBlock)(),(0,r.createBlock)(s,{key:0,class:"type-banner mb-20 mt-0",color:"info",closable:!0,"label-key":a.typeDescriptionKey,onClose:a.hideTypeDescription},null,8,["label-key","onClose"])):(0,r.createCommentVNode)("",!0)}var o=n(65359),a=n(9980),s=n(41476),l=n(68851),c=n(35664),u={components:{Banner:a.l},props:{resource:{type:String,required:!0}},computed:{...(0,o.L8)(["currentCluster"]),hideDescriptions:(0,s.AN)(s.xL),typeDescriptionKey(){let e;return e=this.resource===c.W8.CLUSTER_REPO?!this.currentCluster||this.currentCluster.isLocal?'typeDescription."catalog.cattle.io.clusterrepo.local"':'typeDescription."catalog.cattle.io.clusterrepo"':`typeDescription."${this.resource}"`,!this.hideDescriptions.includes(this.resource)&&!this.hideDescriptions.includes("ALL")&&(!!this.$store.getters["i18n/exists"](e)&&e)}},methods:{hideTypeDescription(){const e=this.hideDescriptions.slice();(0,l.PG)(e,this.resource),this.hideDescriptions=e}}},d=n(47433);const h=(0,d.A)(u,[["render",i]]);var p=h},22247:function(e,t,n){"use strict";n.d(t,{j:function(){return $},A:function(){return j}});var r=n(9274);const i={class:"yaml-editor"},o={class:"text-right"},a={key:0,class:"btn-group btn-sm diff-mode"},s=["aria-label"],l=["aria-label"];function c(e,t,n,c,u,d){const h=(0,r.resolveComponent)("CodeMirror"),p=(0,r.resolveComponent)("FileDiff"),f=(0,r.resolveDirective)("trim-whitespace");return(0,r.openBlock)(),(0,r.createElementBlock)("div",i,[(0,r.createElementVNode)("div",o,[d.isPreview&&!n.hidePreviewButtons?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("span",a,[(0,r.createElementVNode)("button",{role:"button","aria-label":e.t("generic.unified"),type:"button",class:(0,r.normalizeClass)(["btn btn-sm bg-default",{active:"split"!==d.diffMode}]),onClick:t[0]||(t[0]=e=>d.diffMode="unified")},(0,r.toDisplayString)(e.t("generic.unified")),11,s),(0,r.createElementVNode)("button",{role:"button","aria-label":e.t("generic.split"),type:"button",class:(0,r.normalizeClass)(["btn btn-sm bg-default",{active:"split"===d.diffMode}]),onClick:t[1]||(t[1]=e=>d.diffMode="split")},(0,r.toDisplayString)(e.t("generic.split")),11,l)])),[[f]]):(0,r.createCommentVNode)("",!0)]),d.showCodeEditor?((0,r.openBlock)(),(0,r.createBlock)(h,{key:0,ref:"cm",class:(0,r.normalizeClass)({fill:!0,scrolling:n.scrolling}),value:u.curValue,options:d.codeMirrorOptions,extensions:d.codeMirrorExtensions,showKeyMapBox:!0,"data-testid":n.componentTestid+"-code-mirror",mode:n.mode,onOnInput:d.onInput,onOnReady:d.onReady,onValidationChanged:t[2]||(t[2]=t=>e.$emit("validationChanged",t))},null,8,["class","value","options","extensions","data-testid","mode","onOnInput","onOnReady"])):((0,r.openBlock)(),(0,r.createBlock)(p,{key:1,class:(0,r.normalizeClass)({fill:!0,scrolling:n.scrolling}),filename:".yaml","side-by-side":"split"===d.diffMode,orig:u.original,neu:u.curValue,"footer-space":80},null,8,["class","side-by-side","orig","neu"]))])}var u=n(20246),d=n.n(u),h=n(41476),p=n(3514),f=n.n(p),m=n(37648),g=n(63854),v=n(6963);const b={id:"diffElement",ref:"root",class:"root"};function y(e,t,n,i,o,a){const s=(0,r.resolveComponent)("resize-observer");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[(0,r.createVNode)(s,{onNotify:a.fit},null,8,["onNotify"]),(0,r.createElementVNode)("div",b,null,512)])}var w=n(34312);class O{diff(e,t,n={}){let r;"function"===typeof n?(r=n,n={}):"callback"in n&&(r=n.callback);const i=this.castInput(e,n),o=this.castInput(t,n),a=this.removeEmpty(this.tokenize(i,n)),s=this.removeEmpty(this.tokenize(o,n));return this.diffWithOptionsObj(a,s,n,r)}diffWithOptionsObj(e,t,n,r){var i;const o=e=>(e=this.postProcess(e,n),r?void setTimeout(function(){r(e)},0):e),a=t.length,s=e.length;let l=1,c=a+s;null!=n.maxEditLength&&(c=Math.min(c,n.maxEditLength));const u=null!==(i=n.timeout)&&void 0!==i?i:1/0,d=Date.now()+u,h=[{oldPos:-1,lastComponent:void 0}];let p=this.extractCommon(h[0],t,e,0,n);if(h[0].oldPos+1>=s&&p+1>=a)return o(this.buildValues(h[0].lastComponent,t,e));let f=-1/0,m=1/0;const g=()=>{for(let r=Math.max(f,-l);r<=Math.min(m,l);r+=2){let i;const l=h[r-1],c=h[r+1];l&&(h[r-1]=void 0);let u=!1;if(c){const e=c.oldPos-r;u=c&&0<=e&&e<a}const d=l&&l.oldPos+1<s;if(u||d){if(i=!d||u&&l.oldPos<c.oldPos?this.addToPath(c,!0,!1,0,n):this.addToPath(l,!1,!0,1,n),p=this.extractCommon(i,t,e,r,n),i.oldPos+1>=s&&p+1>=a)return o(this.buildValues(i.lastComponent,t,e))||!0;h[r]=i,i.oldPos+1>=s&&(m=Math.min(m,r-1)),p+1>=a&&(f=Math.max(f,r+1))}else h[r]=void 0}l++};if(r)(function e(){setTimeout(function(){if(l>c||Date.now()>d)return r(void 0);g()||e()},0)})();else while(l<=c&&Date.now()<=d){const e=g();if(e)return e}}addToPath(e,t,n,r,i){const o=e.lastComponent;return o&&!i.oneChangePerToken&&o.added===t&&o.removed===n?{oldPos:e.oldPos+r,lastComponent:{count:o.count+1,added:t,removed:n,previousComponent:o.previousComponent}}:{oldPos:e.oldPos+r,lastComponent:{count:1,added:t,removed:n,previousComponent:o}}}extractCommon(e,t,n,r,i){const o=t.length,a=n.length;let s=e.oldPos,l=s-r,c=0;while(l+1<o&&s+1<a&&this.equals(n[s+1],t[l+1],i))l++,s++,c++,i.oneChangePerToken&&(e.lastComponent={count:1,previousComponent:e.lastComponent,added:!1,removed:!1});return c&&!i.oneChangePerToken&&(e.lastComponent={count:c,previousComponent:e.lastComponent,added:!1,removed:!1}),e.oldPos=s,l}equals(e,t,n){return n.comparator?n.comparator(e,t):e===t||!!n.ignoreCase&&e.toLowerCase()===t.toLowerCase()}removeEmpty(e){const t=[];for(let n=0;n<e.length;n++)e[n]&&t.push(e[n]);return t}castInput(e,t){return e}tokenize(e,t){return Array.from(e)}join(e){return e.join("")}postProcess(e,t){return e}get useLongestToken(){return!1}buildValues(e,t,n){const r=[];let i;while(e)r.push(e),i=e.previousComponent,delete e.previousComponent,e=i;r.reverse();const o=r.length;let a=0,s=0,l=0;for(;a<o;a++){const e=r[a];if(e.removed)e.value=this.join(n.slice(l,l+e.count)),l+=e.count;else{if(!e.added&&this.useLongestToken){let r=t.slice(s,s+e.count);r=r.map(function(e,t){const r=n[l+t];return r.length>e.length?r:e}),e.value=this.join(r)}else e.value=this.join(t.slice(s,s+e.count));s+=e.count,e.added||(l+=e.count)}}return r}}class S extends O{constructor(){super(...arguments),this.tokenize=_}equals(e,t,n){return n.ignoreWhitespace?(n.newlineIsToken&&e.includes("\n")||(e=e.trim()),n.newlineIsToken&&t.includes("\n")||(t=t.trim())):n.ignoreNewlineAtEof&&!n.newlineIsToken&&(e.endsWith("\n")&&(e=e.slice(0,-1)),t.endsWith("\n")&&(t=t.slice(0,-1))),super.equals(e,t,n)}}const E=new S;function x(e,t,n){return E.diff(e,t,n)}function _(e,t){t.stripTrailingCr&&(e=e.replace(/\r\n/g,"\n"));const n=[],r=e.split(/(\n|\r\n)/);r[r.length-1]||r.pop();for(let i=0;i<r.length;i++){const e=r[i];i%2&&!t.newlineIsToken?n[n.length-1]+=e:n.push(e)}return n}function k(e){for(let t=0;t<e.length;t++)if(e[t]<" "||e[t]>"~"||'"'===e[t]||"\\"===e[t])return!0;return!1}function C(e){if(!k(e))return e;let t='"';const n=(new TextEncoder).encode(e);let r=0;while(r<n.length){const e=n[r];t+=7===e?"\\a":8===e?"\\b":9===e?"\\t":10===e?"\\n":11===e?"\\v":12===e?"\\f":13===e?"\\r":34===e?'\\"':92===e?"\\\\":e>=32&&e<=126?String.fromCharCode(e):"\\"+e.toString(8).padStart(3,"0"),r++}return t+='"',t}const A={includeIndex:!0,includeUnderline:!0,includeFileHeaders:!0};function T(e,t,n,r,i,o,a){let s;s=a?"function"===typeof a?{callback:a}:a:{},"undefined"===typeof s.context&&(s.context=4);const l=s.context;if(s.newlineIsToken)throw new Error("newlineIsToken may not be used with patch-generation functions, only with diffing functions");if(!s.callback)return c(x(n,r,s));{const{callback:e}=s;x(n,r,Object.assign(Object.assign({},s),{callback:t=>{const n=c(t);e(n)}}))}function c(n){if(!n)return;function r(e){return e.map(function(e){return" "+e})}n.push({value:"",lines:[]});const a=[];let s=0,c=0,u=[],d=1,h=1;for(let e=0;e<n.length;e++){const t=n[e],i=t.lines||I(t.value);if(t.lines=i,t.added||t.removed){if(!s){const t=n[e-1];s=d,c=h,t&&(u=l>0?r(t.lines.slice(-l)):[],s-=u.length,c-=u.length)}for(const e of i)u.push((t.added?"+":"-")+e);t.added?h+=i.length:d+=i.length}else{if(s)if(i.length<=2*l&&e<n.length-2)for(const e of r(i))u.push(e);else{const e=Math.min(i.length,l);for(const n of r(i.slice(0,e)))u.push(n);const t={oldStart:s,oldLines:d-s+e,newStart:c,newLines:h-c+e,lines:u};a.push(t),s=0,c=0,u=[]}d+=i.length,h+=i.length}}for(const e of a)for(let t=0;t<e.lines.length;t++)e.lines[t].endsWith("\n")?e.lines[t]=e.lines[t].slice(0,-1):(e.lines.splice(t+1,0,"\\ No newline at end of file"),t++);return{oldFileName:e,newFileName:t,oldHeader:i,newHeader:o,hunks:a}}}function R(e,t){var n,r,i,o,a,s;if(t||(t=A),Array.isArray(e)){if(e.length>1&&!t.includeFileHeaders&&!e.every(e=>e.isGit))throw new Error("Cannot omit file headers on a multi-file patch. (The result would be unparseable; how would a tool trying to apply the patch know which changes are to which file?)");return e.map(e=>R(e,t)).join("\n")}const l=[];if(e.isGit){if(t=A,!e.oldFileName)throw new Error("oldFileName must be specified for Git patches");if(!e.newFileName)throw new Error("newFileName must be specified for Git patches");let c=e.oldFileName,u=e.newFileName;e.isCreate&&"/dev/null"===c?c=u.replace(/^b\//,"a/"):e.isDelete&&"/dev/null"===u&&(u=c.replace(/^a\//,"b/")),l.push("diff --git "+C(c)+" "+C(u)),e.isDelete&&l.push("deleted file mode "+(null!==(n=e.oldMode)&&void 0!==n?n:"100644")),e.isCreate&&l.push("new file mode "+(null!==(r=e.newMode)&&void 0!==r?r:"100644")),e.oldMode&&e.newMode&&!e.isDelete&&!e.isCreate&&(l.push("old mode "+e.oldMode),l.push("new mode "+e.newMode)),e.isRename&&(l.push("rename from "+C((null!==(i=e.oldFileName)&&void 0!==i?i:"").replace(/^a\//,""))),l.push("rename to "+C((null!==(o=e.newFileName)&&void 0!==o?o:"").replace(/^b\//,"")))),e.isCopy&&(l.push("copy from "+C((null!==(a=e.oldFileName)&&void 0!==a?a:"").replace(/^a\//,""))),l.push("copy to "+C((null!==(s=e.newFileName)&&void 0!==s?s:"").replace(/^b\//,""))))}else t.includeIndex&&e.oldFileName==e.newFileName&&void 0!==e.oldFileName&&l.push("Index: "+e.oldFileName),t.includeUnderline&&l.push("===================================================================");const c=e.hunks.length>0;!t.includeFileHeaders||void 0===e.oldFileName||void 0===e.newFileName||e.isGit&&!c||(l.push("--- "+C(e.oldFileName)+(e.oldHeader?"\t"+e.oldHeader:"")),l.push("+++ "+C(e.newFileName)+(e.newHeader?"\t"+e.newHeader:"")));for(let u=0;u<e.hunks.length;u++){const t=e.hunks[u],n=0===t.oldLines?t.oldStart-1:t.oldStart,r=0===t.newLines?t.newStart-1:t.newStart;l.push("@@ -"+n+","+t.oldLines+" +"+r+","+t.newLines+" @@");for(const e of t.lines)l.push(e)}return l.join("\n")+"\n"}function N(e,t,n,r,i,o,a){if("function"===typeof a&&(a={callback:a}),!(null===a||void 0===a?void 0:a.callback)){const s=T(e,t,n,r,i,o,a);if(!s)return;return R(s,null===a||void 0===a?void 0:a.headerOptions)}{const{callback:s}=a;T(e,t,n,r,i,o,Object.assign(Object.assign({},a),{callback:e=>{s(e?R(e,a.headerOptions):void 0)}}))}}function P(e,t,n,r,i,o){return N(e,e,t,n,r,i,o)}function I(e){const t=e.endsWith("\n"),n=e.split("\n").map(e=>e+"\n");return t?n.pop():n.push(n.pop().slice(0,-1)),n}var M={props:{filename:{type:String,default:"file.txt"},sideBySide:{type:Boolean,default:!1},orig:{type:String,required:!0},neu:{type:String,required:!0},autoResize:{type:Boolean,default:!0},footerSpace:{type:Number,default:0},minHeight:{type:Number,default:200}},mounted(){this.draw()},watch:{sideBySide(){this.draw()}},methods:{draw(){const e=document.getElementById("diffElement"),t=P(this.filename,this.orig,this.neu),n={synchronisedScroll:!0,outputFormat:this.sideBySide?"side-by-side":"line-by-line",drawFileList:!1,matching:"words"},r=new w.Diff2HtmlUI(e,t,n);r.draw(),this.fit()},fit(){if(!this.autoResize)return;const e=this.$refs.root;if(!e)return;const t=e.getBoundingClientRect();if(!t)return;const n=window.innerHeight-t.top-this.footerSpace;e.style.height=`${Math.max(0,n)}px`}}},D=(n(32435),n(45978),n(47433));const L=(0,D.A)(M,[["render",y],["__scopeId","data-v-639a852a"]]);var B=L;const $={EDIT_CODE:"EDIT_CODE",VIEW_CODE:"VIEW_CODE",DIFF_CODE:"DIFF_CODE"};var V={emits:["update:value","newObject","onInput","onReady","validationChanged"],components:{CodeMirror:v.A,FileDiff:B},props:{editorMode:{type:String,default:$.EDIT_CODE,validator(e){return Object.values($).includes(e)}},mode:{type:String,default:""},asObject:{type:Boolean,default:!1},initialYamlValues:{type:[String,Object],default:""},scrolling:{type:Boolean,default:!0},value:{type:[String,Object],default:""},hidePreviewButtons:{type:Boolean,default:!1},componentTestid:{type:String,default:"yaml-editor"},extensions:{type:Array,default:()=>[]}},data(){const{initialYamlValues:e,value:t}=this;let n,r;return n=this.asObject?(0,m.Kq)(t):t||"",r=this.asObject&&e?(0,m.Kq)(e):e,f()(r)&&(r=t),{original:r,curValue:n}},computed:{codeMirrorOptions(){const e=this.editorMode===$.VIEW_CODE;return{readOnly:e,mode:"yaml",lint:!e,lineNumbers:!e,screenReaderLabel:this.t("import.editor.label")}},codeMirrorExtensions(){return[g.mK,...this.extensions]},isPreview(){return this.editorMode===$.DIFF_CODE},diffMode:(0,h.AN)(h.Mu),showCodeEditor(){return[$.EDIT_CODE,$.VIEW_CODE].includes(this.editorMode)}},watch:{showUploadPrompt(e){e&&this.$refs.yamluploader.click()}},methods:{focus(){this.$refs.cm&&this.$refs.cm.focus()},refresh(){this.$refs.cm&&this.$refs.cm.refresh()},onInput(e){this.asObject||this.$emit("update:value",...arguments);try{const t=d().load(e);this.asObject?this.$emit("update:value",t):this.$emit("newObject",t)}catch(t){}this.$emit("onInput",...arguments)},onReady(){this.$emit("onReady",...arguments)},updateValue(e){this.curValue=e,this.$refs.cm?.updateValue(e)}}};n(66586);const F=(0,D.A)(V,[["render",c]]);var j=F},41462:function(e,t,n){"use strict";n.d(t,{A:function(){return I}});var r=n(9274);const i=["aria-label"],o={key:0,class:"clearfix",role:"group"},a={key:0,class:"required","aria-hidden":"true"},s={key:1,class:"icon icon-info",tabindex:"0"},l={key:0,class:"array-list-header-group",role:"group"},c={class:"value text-label mb-10"},u=["data-testid"],d={class:"value"},h=["onUpdate:modelValue","data-testid","placeholder","disabled","aria-label","onPaste"],p={key:0,class:"remove"},f=["disabled","data-testid","aria-label","onClick"],m={key:1},g={key:0,class:"text-muted"},v={key:2,class:"footer mmt-6"},b=["disabled","data-testid","aria-label"];function y(e,t,n,y,w,O){const S=(0,r.resolveComponent)("Banner"),E=(0,r.resolveComponent)("TextAreaAutoGrow"),x=(0,r.resolveComponent)("LabeledInput"),_=(0,r.resolveDirective)("clean-tooltip");return(0,r.openBlock)(),(0,r.createElementBlock)("div",{class:"array-list-main-container",role:"group","aria-label":n.title||e.t("generic.ariaLabel.arrayList")},[n.title?((0,r.openBlock)(),(0,r.createElementBlock)("div",o,[(0,r.renderSlot)(e.$slots,"title",{},()=>[(0,r.createElementVNode)("h3",null,[(0,r.createTextVNode)((0,r.toDisplayString)(n.title)+" ",1),n.required?((0,r.openBlock)(),(0,r.createElementBlock)("span",a,"*")):(0,r.createCommentVNode)("",!0),O.showProtip?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("i",s,null,512)),[[_,{content:n.protip,triggers:["hover","touch","focus"]}]]):(0,r.createCommentVNode)("",!0)])],!0)])):(0,r.createCommentVNode)("",!0),y.effectiveValidationMessage?((0,r.openBlock)(),(0,r.createBlock)(S,{key:1,class:"validation-banner",color:"error",label:y.effectiveValidationMessage},null,8,["label"])):(0,r.createCommentVNode)("",!0),(0,r.createElementVNode)("div",null,[y.rows.length?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:0},[n.showHeader?((0,r.openBlock)(),(0,r.createElementBlock)("div",l,[(0,r.renderSlot)(e.$slots,"column-headers",{},()=>[(0,r.createElementVNode)("label",c,(0,r.toDisplayString)(n.valueLabel),1)],!0)])):(0,r.createCommentVNode)("",!0),((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(y.rows,(i,o)=>((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:o,"data-testid":`${n.componentTestid}-box${o}`,class:(0,r.normalizeClass)(["box",{"hide-remove-is-view":y.isView}]),role:"group"},[(0,r.renderSlot)(e.$slots,"columns",{queueUpdate:y.queueUpdate,i:o,rows:y.rows,row:i,mode:n.mode,isView:y.isView},()=>[(0,r.createElementVNode)("div",d,[(0,r.renderSlot)(e.$slots,"value",{row:i,mode:n.mode,isView:y.isView,queueUpdate:y.queueUpdate},()=>[n.valueMultiline?((0,r.openBlock)(),(0,r.createBlock)(E,{key:0,ref_for:!0,ref:"value",value:i.value,"onUpdate:value":[e=>i.value=e,y.queueUpdate],"data-testid":`${n.componentTestid}-textarea-${o}`,placeholder:n.valuePlaceholder,mode:n.mode,disabled:n.disabled||O.disabledIndexList?.includes(o),"aria-label":n.a11yLabel?`${n.a11yLabel} ${e.t("generic.ariaLabel.genericRow",{index:o+1})}`:void 0,onPaste:e=>O.onPaste(o,e),onBlur:y.validate},null,8,["value","onUpdate:value","data-testid","placeholder","mode","disabled","aria-label","onPaste","onBlur"])):n.rules.length>0?((0,r.openBlock)(),(0,r.createBlock)(x,{key:1,ref_for:!0,ref:"value",value:i.value,"onUpdate:value":[e=>i.value=e,y.queueUpdate],"data-testid":`${n.componentTestid}-labeled-input-${o}`,placeholder:n.valuePlaceholder,disabled:y.isView||n.disabled||O.disabledIndexList?.includes(o),rules:n.rules,compact:!1,"aria-label":n.a11yLabel?`${n.a11yLabel} ${e.t("generic.ariaLabel.genericRow",{index:o+1})}`:void 0,onPaste:e=>O.onPaste(o,e),onBlur:y.validate},null,8,["value","onUpdate:value","data-testid","placeholder","disabled","rules","aria-label","onPaste","onBlur"])):(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("input",{key:2,ref_for:!0,ref:"value","onUpdate:modelValue":e=>i.value=e,"data-testid":`${n.componentTestid}-input-${o}`,placeholder:n.valuePlaceholder,disabled:y.isView||n.disabled||O.disabledIndexList?.includes(o),"aria-label":n.a11yLabel?`${n.a11yLabel} ${e.t("generic.ariaLabel.genericRow",{index:o+1})}`:void 0,onPaste:e=>O.onPaste(o,e),onBlur:t[0]||(t[0]=(...e)=>y.validate&&y.validate(...e))},null,40,h)),[[r.vModelText,i.value]])],!0)])],!0),!O.showRemove||y.isView||O.disabledIndexList?.includes(o)?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createElementBlock)("div",p,[(0,r.renderSlot)(e.$slots,"remove-button",{remove:()=>O.remove(i,o),i:o,row:i},()=>[(0,r.createElementVNode)("button",{type:"button",disabled:y.isView,class:"btn role-link","data-testid":`${n.componentTestid}-remove-item-${o}`,"aria-label":e.t("generic.ariaLabel.remove",{index:o+1}),role:"button",onClick:e=>O.remove(i,o)},(0,r.toDisplayString)(O._removeLabel),9,f)],!0)])),(0,r.renderSlot)(e.$slots,"value-sub-row",{row:i,mode:n.mode,isView:y.isView},void 0,!0)],10,u))),128))],64)):((0,r.openBlock)(),(0,r.createElementBlock)("div",m,[(0,r.renderSlot)(e.$slots,"empty",{},()=>["view"===n.mode?((0,r.openBlock)(),(0,r.createElementBlock)("div",g," — ")):(0,r.createCommentVNode)("",!0)],!0)])),O.showAdd&&!y.isView?((0,r.openBlock)(),(0,r.createElementBlock)("div",v,[O.showAdd?(0,r.renderSlot)(e.$slots,"add",{add:O.add},()=>[(0,r.createElementVNode)("button",{type:"button",class:(0,r.normalizeClass)(["btn role-tertiary add",[n.addClass]]),disabled:n.loading||O.disableAdd,"data-testid":`${n.componentTestid}-button`,"aria-label":n.addBtnAriaLabel||O._addLabel,role:"button",onClick:t[1]||(t[1]=e=>O.add())},[(0,r.createElementVNode)("i",{class:(0,r.normalizeClass)(["mr-5 icon",n.loading?["icon-lg","icon-spinner","icon-spin"]:[n.addIcon]])},null,2),(0,r.createTextVNode)(" "+(0,r.toDisplayString)(O._addLabel),1)],10,b)],!0,0):(0,r.createCommentVNode)("",!0)])):(0,r.createCommentVNode)("",!0)])],8,i)}var w=n(12784),O=n.n(w),S=n(14220),E=n(68851),x=n(6879),_=n(76978),k=n(79380),C=n(15554),A=n(16824);const T="Tip: Paste lines into any list field for easy bulk entry";var R={emits:["add","remove","update:value"],components:{TextAreaAutoGrow:x.V,LabeledInput:k.o,Banner:C.A},props:{value:{type:Array,default:null},mode:{type:String,default:S.G5},initialEmptyRow:{type:Boolean,default:!1},title:{type:String,default:""},protip:{type:[String,Boolean],default:T},showHeader:{type:Boolean,default:!1},valueLabel:{type:String,default:"Value"},valuePlaceholder:{type:String,default:"e.g. bar"},valueMultiline:{type:Boolean,default:!1},addClass:{type:String,default:""},addIcon:{type:String,default:""},addLabel:{type:String,default:""},addBtnAriaLabel:{type:String,default:""},addAllowed:{type:Boolean,default:!0},addDisabled:{type:Boolean,default:!1},removeLabel:{type:String,default:""},removeAllowed:{type:Boolean,default:!0},defaultAddValue:{type:[String,Number,Object,Array],default:""},loading:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},disabledList:{type:Array,default:null},required:{type:Boolean,default:!1},rules:{default:()=>[],type:Array,validator:e=>e.every(e=>["function"].includes(typeof e))},a11yLabel:{type:String,default:""},componentTestid:{type:String,default:"array-list"},name:{type:String,default:null}},setup(e,{emit:t}){const n=(Array.isArray(e.value)?e.value:[]).slice(),i=(0,r.ref)([]);for(const r of n)i.value.push({value:r});if(!i.value.length&&e.initialEmptyRow){const t=e.defaultAddValue?(0,_.o8)(e.defaultAddValue):"";i.value.push({value:t})}const o=(0,r.computed)(()=>e.mode===S.nW),a=(0,r.computed)(()=>e.value||[]),{effectiveValidationMessage:s,veeHandleBlur:l,veeValidate:c}=(0,A.U)({name:(0,r.toRef)(e,"name"),rules:(0,r.ref)([]),value:a,validationMessage:(0,r.ref)(null)}),u=(0,r.ref)(!1),d=()=>{l(void 0,!1),c()},h=()=>{if(o.value)return;const n=[];for(const t of i.value){const r=!e.valueMultiline&&"string"===typeof t.value,i=r?t.value.trim():t.value;"undefined"!==typeof i&&n.push(i)}t("update:value",n),u.value&&(d(),u.value=!1)},p=(0,r.ref)(!1),f=O()(h,50);return(0,r.watch)(i,()=>{p.value||f(),p.value=!1},{deep:!0}),(0,r.watch)(()=>e.value,()=>{p.value=!0,i.value=(e.value||[]).map(e=>({value:e}))},{deep:!0}),{rows:i,lastUpdateWasFromValue:p,queueUpdate:f,isView:o,update:h,effectiveValidationMessage:s,isStructuralChange:u,validate:d}},computed:{_addLabel(){return this.addLabel||this.t("generic.ariaLabel.genericAddRow")},_removeLabel(){return this.removeLabel||this.t("generic.remove")},showAdd(){return this.addAllowed},disableAdd(){return this.addDisabled},showRemove(){return this.removeAllowed},isDefaultProtip(){return this.protip===T},showProtip(){return!(!this.protip||this.isDefaultProtip)||!this.valueMultiline&&this.protip},disabledIndexList(){return this.disabledList?.map(e=>this.rows.findIndex(t=>t.value===e))}},created(){},methods:{add(){this.isStructuralChange=!0,this.rows.push({value:(0,_.o8)(this.defaultAddValue)}),this.defaultAddValue&&this.queueUpdate(),this.$nextTick(()=>{const e=this.$refs.value;e&&e.length>0&&e[e.length-1].focus(),this.$emit("add")})},remove(e,t){this.$emit("remove",{row:e,index:t}),this.isStructuralChange=!0,(0,E.Wq)(this.rows,t),this.queueUpdate()},onPaste(e,t){t.preventDefault();const n=t.clipboardData.getData("text/plain");if(this.isStructuralChange=!0,this.valueMultiline)this.rows[e].value=n;else{const r=n.split("\n").map(e=>({value:e}));t.preventDefault(),this.rows.splice(e,1,...r)}this.update()}}},N=(n(42358),n(47433));const P=(0,N.A)(R,[["render",y],["__scopeId","data-v-80314c1e"]]);var I=P},31097:function(e,t,n){"use strict";n.d(t,{A:function(){return p}});var r=n(9274);const i=["data-testid","onClick"],o={key:1};function a(e,t,n,a,s,l){const c=(0,r.resolveComponent)("InfoBox"),u=(0,r.resolveComponent)("ArrayList");return(0,r.openBlock)(),(0,r.createBlock)(u,(0,r.mergeProps)({class:"array-list-grouped",value:n.value},e.$attrs,{"add-allowed":n.canAdd&&!l.isView,mode:n.mode,"initial-empty-row":n.initialEmptyRow,"onUpdate:value":t[0]||(t[0]=t=>e.$emit("update:value",t)),onAdd:t[1]||(t[1]=t=>e.$emit("add")),onRemove:t[2]||(t[2]=t=>e.$emit("remove",t))}),(0,r.createSlots)({columns:(0,r.withCtx)(t=>[(0,r.createVNode)(c,null,{default:(0,r.withCtx)(()=>[(0,r.renderSlot)(e.$slots,"default",(0,r.normalizeProps)((0,r.guardReactiveProps)(t)))]),_:2},1024)]),"remove-button":(0,r.withCtx)(e=>[l.canRemoveRow(e.row,e.i)?((0,r.openBlock)(),(0,r.createElementBlock)("button",{key:0,type:"button",class:"btn role-link close btn-sm","data-testid":`remove-item-${e.i}`,onClick:e.remove},[...t[3]||(t[3]=[(0,r.createElementVNode)("i",{class:"icon icon-x"},null,-1)])],8,i)):((0,r.openBlock)(),(0,r.createElementBlock)("span",o))]),_:2},[(0,r.renderList)(e.$slots,(t,n)=>({name:n,fn:(0,r.withCtx)(t=>["function"===typeof e.$slots[n]?(0,r.renderSlot)(e.$slots,n,(0,r.normalizeProps)((0,r.guardReactiveProps)(t)),void 0,void 0,0):(0,r.createCommentVNode)("",!0)])}))]),1040,["value","add-allowed","mode","initial-empty-row"])}var s=n(41462),l=n(56279),c=n(14220),u={name:"ArrayListGrouped",components:{ArrayList:s.A,InfoBox:l.A},props:{canRemove:{type:[Boolean,Function],default:!0},canAdd:{type:Boolean,default:!0},initialEmptyRow:{type:Boolean,default:!1},mode:{type:String,default:c.G5},value:{type:Object,default:()=>({})}},emits:["update:value","add","remove"],computed:{isView(){return this.mode===c.nW}},methods:{canRemoveRow(e,t){return!this.isView&&("function"===typeof this.canRemove?this.canRemove(e,t):this.canRemove)}}},d=(n(53575),n(47433));const h=(0,d.A)(u,[["render",a]]);var p=h},57388:function(e,t,n){"use strict";n.d(t,{BS:function(){return c},Ay:function(){return f},Xv:function(){return u}});var r=n(9274);const i=["multiple","webkitdirectory","accept"];function o(e,t,n,o,a,s){const l=(0,r.resolveComponent)("RcButton");return s.isView?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createBlock)(l,{key:0,variant:n.variant,size:n.size,disabled:n.disabled,"aria-label":n.label,class:"file-selector","data-testid":"file-selector__uploader-button",onClick:s.selectFile},{default:(0,r.withCtx)(()=>[(0,r.createElementVNode)("span",null,(0,r.toDisplayString)(n.label),1),(0,r.createElementVNode)("input",{ref:"uploader",type:"file",class:"hide",multiple:n.multiple,webkitdirectory:n.directory,accept:n.accept,onChange:t[0]||(t[0]=(...e)=>s.fileChange&&s.fileChange(...e))},null,40,i)]),_:1},8,["variant","size","disabled","aria-label","onClick"]))}var a=n(14220),s=n(76978),l=n(51433);function c(e){return function(t){(0,s.hZ)(this,e,t)}}function u(e,t=!1){return new Promise((n,r)=>{const i=new FileReader;i.onload=e=>n(e.target.result),i.onerror=()=>r(i.error||new Error(`Could not read ${e.name}`)),t?i.readAsDataURL(e):i.readAsText(e)})}var d={emits:["error","selected"],components:{RcButton:l.a},props:{label:{type:String,required:!0},mode:{type:String,default:a.G5},disabled:{type:Boolean,default:!1},includeFileName:{type:Boolean,default:!1},showGrowlError:{type:Boolean,default:!0},multiple:{type:Boolean,default:!1},byteLimit:{type:Number,default:0},readAsDataUrl:{type:Boolean,default:!1},directory:{type:Boolean,default:!1},rawData:{type:Boolean,default:!1},accept:{type:String,default:"*"},variant:{type:String,default:"secondary"},size:{type:String,default:"medium"}},computed:{isView(){return this.mode===a.nW}},methods:{selectFile(){this.$refs.uploader.value=null,this.$refs.uploader.click()},async fileChange(e){const t=e.target,n=Array.from(t.files||[]);if(this.byteLimit)for(const i of n)if(i.size>this.byteLimit)return void this.$emit("error",this.t("generic.byteLimitExceeded",{name:i.name,byteLimit:this.byteLimit}));if(this.rawData){const e=this.multiple||1!==n.length?n:n[0];return void this.$emit("selected",e)}try{const e=n.map(this.getFileContents),t=await Promise.all(e),r=this.multiple||1!==t.length?t:t[0];this.$emit("selected",r)}catch(r){this.$emit("error",r),this.showGrowlError&&this.$store.dispatch("growl/fromError",{title:this.t("generic.errorReadingFile"),err:r},{root:!0})}},async getFileContents(e){const t=await u(e,this.readAsDataUrl);return this.includeFileName?{value:t,name:e.name}:t}}},h=n(47433);const p=(0,h.A)(d,[["render",o]]);var f=p},65707:function(e,t,n){"use strict";n.d(t,{A:function(){return m}});var r=n(9274);const i={key:0},o={class:"buttons"},a={class:"left"},s={class:"right"};function l(e,t,n,l,c,u){const d=(0,r.resolveComponent)("Banner"),h=(0,r.resolveComponent)("t"),p=(0,r.resolveComponent)("AsyncButton");return e.isView?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createElementBlock)("div",i,[t[1]||(t[1]=(0,r.createElementVNode)("div",{class:"spacer-small"},null,-1)),((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(e.errors,(t,n)=>((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:n},[(0,r.createVNode)(d,{color:"error",role:"alert",label:t,closable:!0,onClose:t=>e.closeError(n)},null,8,["label","onClose"])]))),128)),(0,r.createElementVNode)("div",o,[(0,r.createElementVNode)("div",a,[(0,r.renderSlot)(e.$slots,"left")]),(0,r.createElementVNode)("div",s,[(0,r.renderSlot)(e.$slots,"cancel",{},()=>[(0,r.createElementVNode)("button",{type:"button",class:"btn role-secondary",onClick:t[0]||(t[0]=(...t)=>e.done&&e.done(...t))},[(0,r.createVNode)(h,{k:"generic.cancel"})])]),(0,r.renderSlot)(e.$slots,"middle"),(0,r.renderSlot)(e.$slots,"save",{},()=>[e.isView?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createBlock)(p,{key:0,mode:e.mode,disabled:e.disableSave,onClick:e.save},null,8,["mode","disabled","onClick"]))]),(0,r.renderSlot)(e.$slots,"right")])])]))}var c=n(14220),u=n(30699),d=n(15554),h=(0,r.defineComponent)({emits:["save","done","closeError"],components:{AsyncButton:u.A,Banner:d.A},props:{mode:{type:String,required:!0},errors:{type:Array,default:()=>[]},disableSave:{type:Boolean,default:!1}},computed:{isView(){return this.mode===c.nW}},methods:{closeError(e){this.$emit("closeError",e)},save(e){this.$emit("save",e)},done(){this.$emit("done")}}}),p=(n(37945),n(47433));const f=(0,p.A)(h,[["render",l]]);var m=f},49452:function(e,t,n){"use strict";n.d(t,{A:function(){return G}});var r=n(9274);const i=["id","tabindex","aria-expanded","aria-describedby","aria-required"],o=["for"],a={key:2,class:"required","aria-hidden":!0},s={key:0,class:"only-user-opts"},l={key:1,class:"vs__option-kind-group"},c={key:1},u={key:3,class:"option-kind-highlighted"},d={key:0,class:"icon icon-warning pull-right",style:{"font-size":"20px"}},h=["data-locked"],p={key:0,class:"pagination-slot"},f={class:"load-more"},m={key:0,class:"icon icon-spinner icon-spin"},g={key:1},v={class:"count"},b={class:"no-options-slot"},y={key:0},w={key:1,class:"paginating"},O={key:0,class:"icon icon-spinner icon-spin icon-lg"};function S(e,t,n,S,E,x){const _=(0,r.resolveComponent)("t"),k=(0,r.resolveComponent)("RcSeparator"),C=(0,r.resolveComponent)("v-select"),A=(0,r.resolveComponent)("LabeledTooltip");return(0,r.openBlock)(),(0,r.createElementBlock)("div",{id:x.hasLabel?E.labeledSelectLabelId:void 0,ref:"select",class:(0,r.normalizeClass)(["labeled-select",[e.$attrs.class,{disabled:S.isView||e.disabled,focused:S.focused,[e.mode]:!0,[n.status]:n.status,taggable:e.$attrs.taggable,taggable:e.$attrs.multiple,hoverable:n.hoverTooltip,"muted-value":n.mutedValue,"compact-input":e.isCompact,"no-label":!x.hasLabel,[`ls-${n.size}`]:!0}]]),tabindex:S.isView||e.disabled?-1:0,role:"combobox","aria-expanded":S.isOpen,"aria-describedby":e.$attrs["aria-describedby"]||void 0,"aria-required":S.requiredField,onClick:t[4]||(t[4]=(...e)=>x.clickSelect&&x.clickSelect(...e)),onKeydown:[t[5]||(t[5]=(0,r.withKeys)((0,r.withModifiers)((...e)=>x.clickSelect&&x.clickSelect(...e),["self"]),["enter"])),t[6]||(t[6]=(0,r.withKeys)((0,r.withModifiers)((...e)=>x.clickSelect&&x.clickSelect(...e),["self","prevent"]),["down"])),t[7]||(t[7]=(0,r.withKeys)((0,r.withModifiers)((...e)=>x.clickSelect&&x.clickSelect(...e),["self","prevent"]),["space"]))]},[(0,r.createElementVNode)("div",{class:(0,r.normalizeClass)({"labeled-container":!0,raised:S.raised,empty:S.empty,[e.mode]:!0}),style:{border:"none"}},[x.hasLabel?((0,r.openBlock)(),(0,r.createElementBlock)("label",{key:0,for:E.labeledSelectLabelId},[e.labelKey?((0,r.openBlock)(),(0,r.createBlock)(_,{key:0,k:e.labelKey},null,8,["k"])):e.label?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:1},[(0,r.createTextVNode)((0,r.toDisplayString)(e.label),1)],64)):(0,r.createCommentVNode)("",!0),S.requiredField?((0,r.openBlock)(),(0,r.createElementBlock)("span",a,"*")):(0,r.createCommentVNode)("",!0)],8,o)):(0,r.createCommentVNode)("",!0)],2),(0,r.createVNode)(C,(0,r.mergeProps)({ref:"select-input"},x.filteredAttrs,{class:["inline",{"no-label":!(e.label||"").length}],"close-on-select":!1,"append-to-body":n.appendToBody,"calculate-position":x.positionDropdown,clearable:n.clearable,disabled:S.isView||e.disabled||n.loading,"get-option-key":x.getOptionKey,"get-option-label":e=>x.getOptionLabel(e),label:n.optionLabel,options:S._options,"map-keydown":e.mappedKeys,placeholder:e.placeholder,reduce:e=>n.reduce(e),filterable:S.isFilterable,filter:x.filterOptions,searchable:S.isSearchable,selectable:n.selectable,modelValue:null==n.value||n.loading?"":n.value,"dropdown-should-open":x.dropdownShouldOpen,tabindex:-1,uid:E.generatedUid,"aria-label":`- ${n.value}`,"onUpdate:modelValue":t[1]||(t[1]=t=>{e.$emit("selecting",t),e.$emit("update:value",t)}),"onSearch:blur":x.onBlur,"onSearch:focus":x.onFocus,onSearch:x.onSearch,onOpen:x.onOpen,onClose:x.onClose,"onOption:selecting":x.closeOnSelecting,"onOption:selected":x.close,"onOption:deselecting":t[2]||(t[2]=t=>e.$emit("deselecting",t)),onKeydown:t[3]||(t[3]=(0,r.withKeys)((0,r.withModifiers)(()=>{},["stop"]),["enter"]))}),(0,r.createSlots)({option:(0,r.withCtx)(t=>[x.showTagPrompts?((0,r.openBlock)(),(0,r.createElementBlock)("div",s,(0,r.toDisplayString)(e.t("labeledSelect.pressEnter",{input:x.getOptionLabel(t.label)})),1)):"group"===t.kind?((0,r.openBlock)(),(0,r.createElementBlock)("div",l,[t.icon?((0,r.openBlock)(),(0,r.createElementBlock)("i",{key:0,class:(0,r.normalizeClass)(["icon",{[t.icon]:!0}])},null,2)):(0,r.createCommentVNode)("",!0),(0,r.createElementVNode)("b",null,(0,r.toDisplayString)(x.getOptionLabel(t)),1),t.badge?((0,r.openBlock)(),(0,r.createElementBlock)("div",c,(0,r.toDisplayString)(t.badge),1)):(0,r.createCommentVNode)("",!0)])):"divider"===t.kind?((0,r.openBlock)(),(0,r.createBlock)(k,{key:2})):"highlighted"===t.kind?((0,r.openBlock)(),(0,r.createElementBlock)("div",u,(0,r.toDisplayString)(t.label),1)):((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:4,class:(0,r.normalizeClass)(["vs__option-kind",{"has-icon":x.hasGroupIcon}])},[(0,r.createTextVNode)((0,r.toDisplayString)(x.getOptionLabel(t))+" ",1),t.error?((0,r.openBlock)(),(0,r.createElementBlock)("i",d)):(0,r.createCommentVNode)("",!0)],2))]),"list-footer":(0,r.withCtx)(()=>[S.canPaginate&&S.totalResults&&S.pages>1?((0,r.openBlock)(),(0,r.createElementBlock)("div",p,[(0,r.createElementVNode)("div",f,[S.paginating?((0,r.openBlock)(),(0,r.createElementBlock)("i",m)):((0,r.openBlock)(),(0,r.createElementBlock)("div",g,[S.canLoadMore?((0,r.openBlock)(),(0,r.createElementBlock)("a",{key:0,onClick:t[0]||(t[0]=(...e)=>S.loadMore&&S.loadMore(...e))},(0,r.toDisplayString)(e.t("labelSelect.pagination.more")),1)):(0,r.createCommentVNode)("",!0)]))]),(0,r.createElementVNode)("div",v,(0,r.toDisplayString)(S.optionCounts),1)])):(0,r.createCommentVNode)("",!0)]),"no-options":(0,r.withCtx)(({search:i})=>[(0,r.createElementVNode)("div",b,[x.showTagPrompts?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:0},[e.searching?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createElementBlock)("span",y,(0,r.toDisplayString)(e.t("labeledSelect.startTyping")),1))],64)):S.paginating?((0,r.openBlock)(),(0,r.createElementBlock)("div",w,[...t[8]||(t[8]=[(0,r.createElementVNode)("i",{class:"icon icon-spinner icon-spin"},null,-1)])])):i?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:2},[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("labelSelect.noOptions.noMatch")),1)],64)):((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:3},[(0,r.createTextVNode)((0,r.toDisplayString)(e.t(n.noOptionsLabelKey)),1)],64))])]),_:2},[n.lockedOptions.length?{name:"selected-option",fn:(0,r.withCtx)(e=>[(0,r.createElementVNode)("span",{"data-locked":x.isOptionLocked(e)||void 0},(0,r.toDisplayString)(x.getOptionLabel(e)),9,h)]),key:"0"}:void 0,(0,r.renderList)(e.$slots,(t,n)=>({name:n,fn:(0,r.withCtx)(t=>[(0,r.renderSlot)(e.$slots,n,(0,r.normalizeProps)((0,r.guardReactiveProps)(t)),void 0,!0)])}))]),1040,["append-to-body","calculate-position","class","clearable","disabled","get-option-key","get-option-label","label","options","map-keydown","placeholder","reduce","filterable","filter","searchable","selectable","modelValue","dropdown-should-open","uid","aria-label","onSearch:blur","onSearch:focus","onSearch","onOpen","onClose","onOption:selecting","onOption:selected"]),n.loading?((0,r.openBlock)(),(0,r.createElementBlock)("i",O)):(0,r.createCommentVNode)("",!0),n.tooltip&&!S.focused?((0,r.openBlock)(),(0,r.createBlock)(A,{key:1,hover:n.hoverTooltip,value:n.tooltip,status:n.status},null,8,["hover","value","status"])):(0,r.createCommentVNode)("",!0),S.validationMessage?((0,r.openBlock)(),(0,r.createBlock)(A,{key:2,hover:n.hoverTooltip,value:S.validationMessage},null,8,["hover","value"])):(0,r.createCommentVNode)("",!0)],42,i)}var E={props:{compact:{type:Boolean,default:null},label:{type:String,default:null},labelKey:{type:String,default:null}},computed:{isCompact(){return null!==this.compact?this.compact:!(this.label||this.labelKey)}}},x=n(76978),_=n(49924),k=n(89626),C=n(20162),A=n(92043),T=n(65359),R=n(45250),N=n(15328);const P={paginate:{default:null,type:Function},inStore:{type:String,default:"cluster"},context:{type:String,default:null},resourceType:{type:String,default:null}},I=e=>{const t=(0,T.Pj)(),n=(0,r.ref)(1),i=(0,r.ref)(""),o=(0,r.ref)(10),a=(0,r.ref)(0),s=(0,r.ref)([]),l=(0,r.ref)(0),c=(0,r.ref)(!1),u=(0,r.computed)(()=>!!e.paginate&&!!e.resourceType&&t.getters[`${e.inStore}/paginationEnabled`]({id:e.resourceType,context:e.context})),d=(0,r.computed)(()=>u.value?s.value:e.options||[]),h=(0,r.computed)(()=>a.value>n.value),p=(0,r.computed)(()=>u.value?d.value.filter(e=>e.kind!==N.c.NONE&&!N.w.includes(e.kind)).length:0),f=(0,r.computed)(()=>u.value&&p.value!==l.value?t.getters["i18n/t"]("labelSelect.pagination.counts",{count:p.value,totalCount:l.value}):""),m=async(t=!1)=>{c.value=!0;const{page:r,pages:u,total:d}=await e.paginate({resetPage:t,pageContent:s.value||[],page:n.value,filter:i.value,pageSize:o.value});s.value=r,a.value=u||0,l.value=d||0,c.value=!1},g=(0,R.debounce)(m,700),v=e=>{c.value=!0,n.value=1,i.value=e,g(!0)},b=()=>{n.value++,m()};return(0,r.onMounted)(async()=>{u.value&&await m()}),{canPaginate:u,canLoadMore:h,optionCounts:f,_options:d,pages:a,totalResults:l,paginating:c,loadMore:b,setPaginationFilter:v}};var M=n(14220),D=n(40597),L=n(2117),B=n(97693),$=n(16824),V=n(14384),F={name:"LabeledSelect",inheritAttrs:!1,components:{LabeledTooltip:_.Z,RcSeparator:V.v},mixins:[E,k.A],emits:["on-open","on-close","on-focus","on-blur","selecting","deselecting","search","update:validation","update:value"],props:{...L.K,...P,value:{default:null,type:[String,Object,Number,Array,Boolean]},appendToBody:{default:!0,type:Boolean},clearable:{default:!1,type:Boolean},hoverTooltip:{default:!0,type:Boolean},loading:{default:!1,type:Boolean},localizedLabel:{default:!1,type:Boolean},optionKey:{default:null,type:String},optionLabel:{default:"label",type:String},placement:{default:null,type:String},reduce:{default:e=>e&&"object"===typeof e&&void 0!==e.value?e.value:e,type:Function},selectable:{default:e=>!e||!(e.disabled||N.w.includes(e.kind)||e.loading),type:Function},status:{default:null,type:String},mutedValue:{default:!1,type:Boolean},tooltip:{default:null,type:[String,Object]},options:{type:Array,default:()=>[]},searchable:{default:!1,type:Boolean},filterable:{default:!0,type:Boolean},closeOnSelect:{type:Boolean,default:!0},noOptionsLabelKey:{type:String,default:"labelSelect.noOptions.empty"},lockedOptions:{type:Array,default:()=>[]},size:{type:String,default:"large",validator:e=>["small","medium","large"].includes(e)},name:{type:String,default:null}},setup(e,{emit:t}){const n=(0,r.ref)(null),i=(0,r.ref)(!1);(0,D.L)(n,()=>{i.value=!1});const{raised:o,focused:a,blurred:s,empty:l,isView:c,onFocusLabeled:u,onBlurLabeled:d,isDisabled:h,validationMessage:p,requiredField:f}=(0,L.x)(e,t),{canPaginate:m,canLoadMore:g,optionCounts:v,_options:b,pages:y,totalResults:w,paginating:O,loadMore:S,setPaginationFilter:E}=I(e),{isSearchable:x,isFilterable:_,resizeHandler:k}=(0,B.v)(e,m),C=()=>{k(n)},{effectiveValidationMessage:A,veeHandleBlur:T,veeValidate:R}=(0,$.U)({name:(0,r.toRef)(e,"name"),rules:(0,r.toRef)(e,"rules"),value:(0,r.toRef)(e,"value"),validationMessage:p});return{isOpen:i,select:n,raised:o,focused:a,blurred:s,empty:l,isView:c,onFocusLabeled:u,onBlurLabeled:d,isDisabled:h,validationMessage:A,requiredField:f,isSearchable:x,isFilterable:_,resizeHandler:C,canPaginate:m,canLoadMore:g,optionCounts:v,_options:b,pages:y,totalResults:w,paginating:O,loadMore:S,setPaginationFilter:E,veeHandleBlur:T,veeValidate:R}},data(){return{selectedVisibility:"visible",shouldOpen:!0,labeledSelectLabelId:`ls-label-id-${(0,A.aR)(12)}`,generatedUid:`ls-uid-${(0,A.aR)(12)}`}},computed:{...(0,T.L8)({t:"i18n/t"}),hasLabel(){return!this.isCompact&&(!!this.label||!!this.labelKey||!!this.$slots.label)},hasGroupIcon(){return!!this.canPaginate&&!!this._options.find(e=>"group"===e.kind&&!!e.icon)},filteredAttrs(){const{class:e,...t}=this.$attrs;return t},showTagPrompts(){return!this.options.length&&this.$attrs.taggable&&this.isSearchable}},watch:{_options:{handler(){const e=this.$refs["select-input"];e?.isTrackingValues&&!e.modelValue&&void 0!==e.modelValue&&e.setInternalValueFromOptions(e.modelValue)},flush:"post"}},methods:{clickSelect(e){this.mode!==M.nW&&!0!==this.loading&&!0!==this.disabled&&(this.$attrs.multiple&&"vs__deselect"===e?.target.className||(this.isOpen=!this.isOpen,this.isOpen&&this.focusSearch()))},focusSearch(){this.isView||this.disabled||this.loading||this.$nextTick(()=>{const e=this.$refs["select-input"]?.searchEl;e&&e.focus()})},focusWrapper(){this.$refs.select.focus()},onFocus(){this.$emit("on-focus"),this.selectedVisibility="hidden",this.onFocusLabeled()},onBlur(){this.$emit("on-blur"),this.selectedVisibility="visible",this.onBlurLabeled(),this.veeHandleBlur(void 0,!1),this.veeValidate()},onOpen(){this.focusSearch(),this.$emit("on-open"),this.resizeHandler()},closeOnSelecting(e){e&&e.value===this.value&&this.close(),this.$emit("selecting",e)},filterOptions(e,t){if(!t)return e;const n=t.toLowerCase(),r=[];let i=null;return e.forEach(e=>{if(!e)return;const t="object"===typeof e;if(t&&["group","title"].includes(e.kind))return void(i=e);if(t&&"divider"===e.kind)return void(i=null);let o=t?this.getOptionLabel(e):e;"number"===typeof o&&(o=o.toString());const a=(o||"").toLowerCase().includes(n);a&&(i&&(r.push(i),i=null),r.push(e))}),r},close(){this.isOpen=!1,this.onClose()},onClose(){this.$emit("on-close"),this.focusWrapper()},getOptionLabel(e){if(e){if(this.$attrs["get-option-label"])return this.$attrs["get-option-label"](e);if((0,x.Jt)(e,this.optionLabel)){if(this.localizedLabel){const t=(0,x.Jt)(e,this.optionLabel);return this.$store.getters["i18n/t"](t)||t}return(0,x.Jt)(e,this.optionLabel)}return e}},positionDropdown(e,t,{width:n}){(0,C.s)(e,t,n,this.placement)},get:x.Jt,dropdownShouldOpen(e,t=!1){if(!this.isOpen)return!1;const{noDrop:n,mutableLoading:r}=e,{open:i}=e,o=this.shouldOpen;return t?(e.open=!0,!0):(!1===o&&(this.shouldOpen=!0,e.closeSearchOptions()),!n&&(i&&o&&!r))},onSearch(e,t){this.canPaginate?this.setPaginationFilter(e):e&&this.dropdownShouldOpen(this.$refs["select-input"],!0),this.$emit("search",e,t)},getOptionKey(e){return this.optionKey?(0,x.Jt)(e,this.optionKey):this.getOptionLabel(e)},isOptionLocked(e){if(!this.lockedOptions.length)return!1;const t=this.getOptionLabel(e);return this.lockedOptions.includes("string"===typeof t?t.trim():String(t))}}},j=(n(41452),n(47433));const U=(0,j.A)(F,[["render",S],["__scopeId","data-v-35b810d8"]]);var G=U},89437:function(e,t,n){"use strict";n.d(t,{A:function(){return p}});var r=n(9274);function i(e,t,n,i,o,a){const s=(0,r.resolveComponent)("LabeledSelect");return(0,r.openBlock)(),(0,r.createBlock)(s,(0,r.mergeProps)(e.labelSelectAttributes,{loading:e.$fetchState.pending,options:e.allOfType,paginate:e.paginate?e.paginateType:void 0,multiple:e.$attrs.multiple||!1,"onUpdate:value":t[0]||(t[0]=t=>e.$emit("update:value",t))}),(0,r.createSlots)({_:2},[(0,r.renderList)(e.$slots,(t,n)=>({name:n,fn:(0,r.withCtx)(t=>[(0,r.renderSlot)(e.$slots,n,(0,r.normalizeProps)((0,r.guardReactiveProps)(t)))])}))]),1040,["loading","options","paginate","multiple"])}var o,a=n(49452),s=n(50025),l=n(4364);async function c({opts:e,type:t,ctx:n,filters:r=[],sort:i=[{asc:!0,field:"metadata.namespace"},{asc:!0,field:"metadata.name"}],store:o="cluster",groupByNamespace:a=!0,classify:c=!1}){const{pageContent:u,page:d,pageSize:h,resetPage:p}=e;try{const e=new s.gR({page:d,pageSize:h,sort:i,filters:r}),l=n.getters[`${o}/urlFor`](t,null,{pagination:e}),f=await n.dispatch(`${o}/request`,{url:l});let m=f.data;c&&(m=await n.dispatch("cluster/createMany",m));const g=p?m:u.concat(m);let v;if(a){const e={};g.forEach(t=>{const n=t.metadata.namespace;"group"!==t.kind&&(e[n]||(e[n]=[]),e[n].push(t))}),v=[],Object.keys(e).sort().forEach(t=>{v.push({kind:"group",icon:"icon-namespace",id:t,metadata:{name:t},disabled:!0}),v=v.concat(e[t])})}else v=g;return{page:v,pages:f.pages||Math.ceil(f.count/(h||Number.MAX_SAFE_INTEGER)),total:f.count}}catch(f){l.error(f)}return{page:[],pages:0,total:0}}(function(e){e["ALL_RESOURCES"]="ALL",e["DYNAMIC"]="DYNAMIC"})(o||(o={}));var u=(0,r.defineComponent)({name:"ResourceLabeledSelect",components:{LabeledSelect:a.A},emits:["update:value"],props:{resourceType:{type:String,required:!0},context:{type:String,default:null},inStore:{type:String,default:void 0},paginateMode:{type:String,default:o.DYNAMIC},allResourcesSettings:{type:Object,default:null},paginatedResourceSettings:{type:Object,default:null}},data(){let e=this.inStore;return!e&&this.resourceType&&(e=this.$store.getters["currentStore"](this.resourceType)),e||(e="cluster"),{paginate:!1,validInStore:e}},async fetch(){switch(this.paginateMode){case o.ALL_RESOURCES:this.paginate=!1;break;case o.DYNAMIC:this.paginate=this.$store.getters[`${this.validInStore}/paginationEnabled`](this.resourceType);break}this.paginate||await this.$store.dispatch(`${this.validInStore}/findAll`,{type:this.resourceType})},computed:{labelSelectAttributes(){var e,t;const n={...this.$attrs,...this.$props};return this.paginate?{...n,...(null===(e=this.paginatedResourceSettings)||void 0===e?void 0:e.labelSelectOptions)||{}}:{...n,...(null===(t=this.allResourcesSettings)||void 0===t?void 0:t.labelSelectOptions)||{}}},allOfType(){var e;if(this.$fetchState.pending||this.paginate)return[];const t=this.$store.getters[`${this.validInStore}/all`](this.resourceType);return(null===(e=this.allResourcesSettings)||void 0===e?void 0:e.updateResources)?this.allResourcesSettings.updateResources(t):t}},methods:{async paginateType(e){var t,n,r,i;if(null===(t=this.paginatedResourceSettings)||void 0===t?void 0:t.overrideRequest)return await this.paginatedResourceSettings.overrideRequest(e);const{filter:o}=e,a=o?[s.eY.createSingleField({field:"metadata.name",value:o,exact:!1})]:[],l=this.$store.getters[`${this.validInStore}/schema`](this.resourceType),u="undefined"!==typeof(null===(n=null===l||void 0===l?void 0:l.attributes)||void 0===n?void 0:n.namespaced)&&l.attributes.namespaced,d={opts:e,filters:a,type:this.resourceType,ctx:{getters:this.$store.getters,dispatch:this.$store.dispatch},sort:[{asc:!0,field:"metadata.name"}],store:this.validInStore,groupByNamespace:u},h=(null===(r=this.paginatedResourceSettings)||void 0===r?void 0:r.requestSettings)?this.paginatedResourceSettings.requestSettings(d):d,p=await c(h);return(null===(i=this.paginatedResourceSettings)||void 0===i?void 0:i.updateResources)?{...p,page:this.paginatedResourceSettings.updateResources(p.page)}:p}}}),d=n(47433);const h=(0,d.A)(u,[["render",i]]);var p=h},44047:function(e,t,n){"use strict";n.d(t,{A:function(){return y}});var r=n(9274);const i=["tabindex","aria-expanded","aria-label","aria-labelledby","aria-describedby"],o=["lang"];function a(e,t,n,a,s,l){const c=(0,r.resolveComponent)("v-select"),u=(0,r.resolveComponent)("LabeledTooltip");return(0,r.openBlock)(),(0,r.createElementBlock)("div",{ref:"select",class:(0,r.normalizeClass)(["unlabeled-select",{disabled:e.disabled||a.isView,focused:a.focused,[e.mode]:!0,[n.status]:n.status,taggable:e.$attrs.taggable,taggable:e.$attrs.multiple,"compact-input":n.compact,[e.$attrs.class]:e.$attrs.class}]),tabindex:e.disabled||a.isView?-1:0,role:"combobox","aria-expanded":a.isOpen,"aria-label":e.$attrs["aria-label"]||void 0,"aria-labelledby":e.$attrs["aria-labelledby"]||void 0,"aria-describedby":e.$attrs["aria-describedby"]||void 0,onClick:t[4]||(t[4]=(...e)=>l.clickSelect&&l.clickSelect(...e)),onKeydown:[t[5]||(t[5]=(0,r.withKeys)((0,r.withModifiers)((...e)=>l.clickSelect&&l.clickSelect(...e),["self"]),["enter"])),t[6]||(t[6]=(0,r.withKeys)((0,r.withModifiers)((...e)=>l.clickSelect&&l.clickSelect(...e),["self","prevent"]),["down"])),t[7]||(t[7]=(0,r.withKeys)((0,r.withModifiers)((...e)=>l.clickSelect&&l.clickSelect(...e),["self","prevent"]),["space"]))]},[(0,r.createVNode)(c,(0,r.mergeProps)({ref:"select-input"},l.deClassedAttrs,{class:["inline",{"select-input-view":"view"===e.mode}],autoscroll:!0,"append-to-body":n.appendToBody,"calculate-position":l.positionDropdown,disabled:a.isView||e.disabled,"get-option-key":e=>l.getOptionKey(e),"get-option-label":e=>l.getOptionLabel(e),label:n.optionLabel,options:n.options,"close-on-select":!1,"map-keydown":e.mappedKeys,placeholder:e.placeholder,reduce:e=>n.reduce(e),searchable:a.isSearchable,selectable:l.selectable,modelValue:null!=n.value?n.value:"",dropdownShouldOpen:l.handleDropdownOpen,tabindex:-1,uid:s.generatedUid,"aria-label":"-","onUpdate:modelValue":t[0]||(t[0]=t=>e.$emit("update:value",t)),"onSearch:blur":a.onBlur,"onSearch:focus":a.onFocus,onOpen:l.onOpen,onClose:l.onClose,"onOption:created":t[1]||(t[1]=t=>e.$emit("createdListItem",t)),"onOption:selecting":l.closeOnSelecting,"onOption:selected":t[2]||(t[2]=e=>n.closeOnSelect&&l.close),onKeydown:t[3]||(t[3]=(0,r.withKeys)((0,r.withModifiers)(()=>{},["stop"]),["enter"]))}),(0,r.createSlots)({option:(0,r.withCtx)(e=>[(0,r.createElementVNode)("div",{lang:n.isLangSelect?e.value:void 0},(0,r.toDisplayString)(l.getOptionLabel(e.label)),9,o)]),_:2},[(0,r.renderList)(e.$slots,(t,n)=>({name:n,fn:(0,r.withCtx)(t=>[(0,r.renderSlot)(e.$slots,n,(0,r.normalizeProps)((0,r.guardReactiveProps)(t)),void 0,!0)])}))]),1040,["class","append-to-body","calculate-position","disabled","get-option-key","get-option-label","label","options","map-keydown","placeholder","reduce","searchable","selectable","modelValue","dropdownShouldOpen","uid","onSearch:blur","onSearch:focus","onOpen","onClose","onOption:selecting"]),n.tooltip&&!a.focused?((0,r.openBlock)(),(0,r.createBlock)(u,{key:0,hover:n.hoverTooltip,value:n.tooltip,status:n.status},null,8,["hover","value","status"])):(0,r.createCommentVNode)("",!0),a.validationMessage?((0,r.openBlock)(),(0,r.createBlock)(u,{key:1,hover:n.hoverTooltip,value:a.validationMessage},null,8,["hover","value"])):(0,r.createCommentVNode)("",!0)],42,i)}var s=n(76978),l=n(89626),c=n(92043),u=n(49924),d=n(20162),h=n(14220),p=n(40597),f=n(2117),m=n(97693),g={inheritAttrs:!1,emits:["update:value","createdListItem","on-open","on-close","on-focus","on-blur","update:validation"],components:{LabeledTooltip:u.Z},mixins:[l.A],props:{...f.K,value:{default:null,type:[String,Object,Number,Array,Boolean]},appendToBody:{default:!0,type:Boolean},getKeyForOption:{default:null,type:Function},optionKey:{default:null,type:String},optionLabel:{default:"label",type:String},placement:{default:null,type:String},popperOverride:{type:Function,default:null},reduce:{default:e=>e&&"object"===typeof e&&void 0!==e.value?e.value:e,type:Function},tooltip:{type:String,default:null},hoverTooltip:{type:Boolean,default:!0},status:{type:String,default:null},closeOnSelect:{type:Boolean,default:!0},compact:{type:Boolean,default:null},isLangSelect:{type:Boolean,default:!1},loading:{default:!1,type:Boolean},options:{type:Array,default:()=>[]},searchable:{default:!1,type:Boolean},filterable:{default:!0,type:Boolean}},setup(e,{emit:t}){const n=(0,r.ref)(null),i=(0,r.ref)(!1);(0,p.L)(n,()=>{i.value=!1});const{raised:o,focused:a,blurred:s,empty:l,isView:c,onFocusLabeled:u,onBlurLabeled:d,isDisabled:h,validationMessage:g,requiredField:v}=(0,f.x)(e,t),b=()=>{t("on-focus"),u()},y=()=>{t("on-blur"),d()},{isSearchable:w,isFilterable:O,resizeHandler:S}=(0,m.v)(e),E=()=>{S(n)};return{isOpen:i,select:n,raised:o,focused:a,blurred:s,empty:l,isView:c,onFocus:b,onBlur:y,isDisabled:h,validationMessage:g,requiredField:v,isSearchable:w,isFilterable:O,resizeHandler:E}},data(){return{generatedUid:`s-uid-${(0,c.aR)(12)}`}},methods:{getOptionLabel(e){return this.$attrs["get-option-label"]?this.$attrs["get-option-label"](e):(0,s.Jt)(e,this.optionLabel)?this.localizedLabel?this.$store.getters["i18n/t"]((0,s.Jt)(e,this.optionLabel)):(0,s.Jt)(e,this.optionLabel):e},positionDropdown(e,t,{width:n}){if(this.popperOverride)return this.popperOverride(e,t,{width:n});(0,d.s)(e,t,n,this.placement)},clickSelect(e){this.mode!==h.nW&&!0!==this.loading&&!0!==this.disabled&&(this.$attrs.multiple&&"vs__deselect"===e?.target.className||(this.isOpen=!this.isOpen,this.isOpen&&this.focusSearch(e)))},focusSearch(){this.$nextTick(()=>{const e=this.$refs["select-input"]?.searchEl;e&&e.focus()})},focusWrapper(){this.$refs.select.focus()},get:s.Jt,selectable(e){return!e||!e.disabled&&"group"!==e.kind&&"divider"!==e.kind&&!e.loading},getOptionKey(e){if(e&&this.optionKey)return(0,s.Jt)(e,this.optionKey);if(e?.optionKey)return(0,s.Jt)(e,e.optionKey);const t=this.getOptionLabel(e);return"string"===typeof t||"number"===typeof t?t:Math.random(1e5)},report(e){alert(e)},handleDropdownOpen(e){return!!this.isOpen&&(!e.noDrop&&!e.disabled&&e.open)},onOpen(){this.focusSearch(),this.$emit("on-open"),this.resizeHandler()},closeOnSelecting(){this.closeOnSelect&&this.close()},close(){this.isOpen=!1,this.onClose()},onClose(){this.$emit("on-close"),this.focusWrapper()}},computed:{deClassedAttrs(){const{class:e,...t}=this.$attrs;return t}}},v=(n(39828),n(47433));const b=(0,v.A)(g,[["render",a],["__scopeId","data-v-7b7d6df0"]]);var y=b},89455:function(e,t,n){"use strict";n.d(t,{A:function(){return b}});var r=n(9274);const i={class:"secret-selector show-key-selector"},o={class:"input-container"};function a(e,t,n,a,s,l){const c=(0,r.resolveComponent)("ResourceLabeledSelect"),u=(0,r.resolveComponent)("LabeledSelect");return(0,r.openBlock)(),(0,r.createElementBlock)("div",i,[(0,r.createElementVNode)("div",o,[(0,r.createVNode)(c,{value:s.name,"onUpdate:value":t[0]||(t[0]=e=>s.name=e),class:"col span-6",disabled:!l.isView&&n.disabled,loading:e.$fetchState.pending,label:n.secretNameLabel,mode:n.mode,"resource-type":s.SECRET,"paginated-resource-settings":s.paginateSecretsSetting,"all-resources-settings":s.allSecretsSettings,onSelecting:l.updateSecretName},null,8,["value","disabled","loading","label","mode","resource-type","paginated-resource-settings","all-resources-settings","onSelecting"]),(0,r.createVNode)(u,{value:s.key,"onUpdate:value":t[1]||(t[1]=e=>s.key=e),class:"col span-6",disabled:l.isKeyDisabled,options:l.keys,label:n.keyNameLabel,mode:n.mode,onSelecting:l.updateSecretKey},null,8,["value","disabled","options","label","mode","onSelecting"])])])}var s=n(49452),l=n(89437),c=n(35664),u=n(14220),d=n(1133),h=n(15328),p=n(50025);const f="__[[NONE]]__";var m={emits:["updateSecretName","updateSecretKey"],components:{LabeledSelect:s.A,ResourceLabeledSelect:l.A},props:{test:{type:String,default:""},initialName:{type:String,required:!0},initialKey:{type:String,required:!0},namespace:{type:String,required:!0},types:{type:Array,default:()=>Object.values(d.TYPES)},disabled:{type:Boolean,default:!1},secretNameLabel:{type:String,default:"Secret Name"},keyNameLabel:{type:String,default:"Key"},mode:{type:String,default:u.G5}},data(e){return{secrets:[],name:e.initialName,key:e.initialKey,none:f,SECRET:c.bB,allSecretsSettings:{updateResources:e=>{const t=e.filter(e=>this.types.includes(e._type)&&e.namespace===this.namespace),n=this.mapSecrets(t.sort((e,t)=>e.name.localeCompare(t.name)));return this.secrets=t,n}},paginateSecretsSetting:{requestSettings:this.paginatePageOptions,updateResources:e=>{const t=this.mapSecrets(e);return this.secrets=e,t}}}},computed:{keys(){const e=(this.secrets||[]).find(e=>e.name===this.name)||{};return Object.keys(e.data||{}).map(e=>({label:e,value:e}))},isView(){return this.mode===u.nW},isKeyDisabled(){return!this.isView&&(!this.name||this.name===f||this.disabled)}},methods:{mapSecrets(e){const t=e.reduce((e,t)=>(t.kind===h.c.NONE||(t.id?e.push({label:t.name,value:t.name}):e.push(t)),e),[]);return[{label:"None",value:f,kind:h.c.NONE},...t]},paginatePageOptions(e){const{opts:{filter:t}}=e,n=t?[p.eY.createSingleField({field:"metadata.name",value:t,exact:!1,equals:!0})]:[];return n.push(p.eY.createSingleField({field:"metadata.namespace",value:this.namespace}),p.eY.createMultipleFields(this.types.map(e=>({field:"metadata.fields.1",equals:!0,exact:!0,value:e})))),{...e,filters:n,groupByNamespace:!1,classify:!0,sort:[{asc:!0,field:"metadata.name"}]}},updateSecretName(e){e.value===this.none&&(this.key=""),e.value&&this.$emit("updateSecretName",e.value)},updateSecretKey(e){e.value&&this.$emit("updateSecretKey",e.value)}}},g=(n(88178),n(47433));const v=(0,g.A)(m,[["render",a]]);var b=v},73344:function(e,t,n){"use strict";n.d(t,{A:function(){return p}});var r=n(9274);const i=["id"];function o(e,t,n,o,a,s){const l=(0,r.resolveComponent)("LabeledInput");return(0,r.openBlock)(),(0,r.createBlock)(l,(0,r.mergeProps)({ref:"value",value:s.displayValue},e.$attrs,{type:"number",min:n.min,mode:n.mode,disabled:n.disabled,label:n.label,delay:n.delay,"label-key":n.labelKey,tooltip:n.tooltip,"tooltip-key":n.tooltipKey,required:n.required,placeholder:n.placeholder,"hide-arrows":n.hideArrows,"aria-describedby":s.displayUnit?a.describedById:void 0,"sub-label":n.subLabel,"onUpdate:value":s.update,onBlur:t[0]||(t[0]=e=>s.update(e.target.value))}),{suffix:(0,r.withCtx)(()=>[s.displayUnit?((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:0,id:a.describedById,class:(0,r.normalizeClass)(["addon",{"with-tooltip":n.tooltip||n.tooltipKey}])},(0,r.toDisplayString)(s.displayUnit),11,i)):(0,r.createCommentVNode)("",!0)]),_:1},16,["value","min","mode","disabled","label","delay","label-key","tooltip","tooltip-key","required","placeholder","hide-arrows","aria-describedby","sub-label","onUpdate:value"])}var a=n(95799),s=n(79380),l=n(14220),c=n(92043),u={components:{LabeledInput:s.o},emits:["update:value","update:validation","change","blur"],props:{outputAs:{type:String,default:"number"},outputModifier:{type:Boolean,default:!1},inputExponent:{type:Number,default:0},baseUnit:{type:String,default:"B"},hideArrows:{type:Boolean,default:!1},increment:{type:Number,default:1e3},suffix:{type:String,default:null},mode:{type:String,default:l.G5},value:{type:[Number,String],default:null},label:{type:String,default:null},labelKey:{type:String,default:null},tooltip:{type:[String,Object],default:null},tooltipKey:{type:String,default:null},required:{type:Boolean,default:!1},min:{type:[Number,String],default:0},placeholder:{type:[String,Number],default:""},delay:{type:Number,default:0},positive:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},subLabel:{type:String,default:null}},data(){return{describedById:`unit-describedbyid-${(0,c.aR)(12)}`}},computed:{unit(){let e;return e=this.inputExponent>=0?a.QN[this.inputExponent]:a.kq[-1*this.inputExponent],1024===this.increment&&e&&(e+="i"),e},parsedValue(){return"string"===typeof this.value?(0,a.ao)(this.value):this.value},displayValue(){let e="";return(this.parsedValue||0===this.parsedValue)&&(e=(0,a.Mo)(this.parsedValue,{increment:this.increment,addSuffix:!1,maxExponent:this.inputExponent,minExponent:this.inputExponent})),e},displayUnit(){return this.suffix?this.suffix:this.unit+this.baseUnit}},methods:{focus(){const e=this.$refs.value;e&&e.focus()},update(e){let t=""===e?null:e;this.positive&&e<0&&(t=0),this.outputModifier?t=null===t?null:`${parseInt(e)}${this.unit}`:"string"===this.outputAs?t=null===t?"":`${e}`:t&&(t=this.unit?(0,a.ao)(`${t}${this.unit}`):parseInt(t)),this.$emit("update:value",t)}}},d=(n(38241),n(47433));const h=(0,d.A)(u,[["render",o],["__scopeId","data-v-e5242b74"]]);var p=h},99383:function(e,t,n){"use strict";n.d(t,{A:function(){return y}});var r=n(9274);const i={class:"row"},o={class:"col span-12"},a={class:"row mb-20"},s={class:"row mb-20"},l={class:"row mb-20"},c={class:"row mb-20"},u={class:"col span-12"};function d(e,t,n,d,h,p){const f=(0,r.resolveComponent)("SimpleSecretSelector"),m=(0,r.resolveComponent)("Banner"),g=(0,r.resolveComponent)("LabeledInput");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[(0,r.createElementVNode)("div",i,[(0,r.createElementVNode)("div",o,[(0,r.createElementVNode)("h3",null,(0,r.toDisplayString)(e.t("monitoring.receiver.tls.label")),1)])]),(0,r.createElementVNode)("div",a,[n.namespace?((0,r.openBlock)(),(0,r.createBlock)(f,{key:0,"initial-key":h.initialCaSecretKey,"initial-name":h.initialCaSecretName,mode:n.mode,namespace:n.namespace,disabled:n.mode===h.view,"secret-name-label":e.t("monitoringReceiver.tls.ca"),onUpdateSecretName:p.updateCaSecretName,onUpdateSecretKey:p.updateCaSecretKey},null,8,["initial-key","initial-name","mode","namespace","disabled","secret-name-label","onUpdateSecretName","onUpdateSecretKey"])):((0,r.openBlock)(),(0,r.createBlock)(m,{key:1,color:"error"},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("alertmanagerConfigReceiver.namespaceWarning")),1)]),_:1}))]),(0,r.createElementVNode)("div",s,[n.namespace?((0,r.openBlock)(),(0,r.createBlock)(f,{key:0,"initial-key":h.initialClientCertSecretKey,"initial-name":h.initialClientCertSecretName,mode:n.mode,namespace:n.namespace,disabled:n.mode===h.view,"secret-name-label":e.t("monitoringReceiver.tls.cert"),onUpdateSecretName:p.updateClientCertSecretName,onUpdateSecretKey:p.updateClientCertSecretKey},null,8,["initial-key","initial-name","mode","namespace","disabled","secret-name-label","onUpdateSecretName","onUpdateSecretKey"])):((0,r.openBlock)(),(0,r.createBlock)(m,{key:1,color:"error"},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("alertmanagerConfigReceiver.namespaceWarning")),1)]),_:1}))]),(0,r.createElementVNode)("div",l,[n.namespace?((0,r.openBlock)(),(0,r.createBlock)(f,{key:0,"initial-key":h.initialClientKeySecretKey,"initial-name":h.initialClientKeySecretName,mode:n.mode,namespace:n.namespace,disabled:n.mode===h.view,"secret-name-label":e.t("monitoringReceiver.tls.key"),onUpdateSecretName:p.updateClientKeySecretName,onUpdateSecretKey:p.updateClientKeySecretKey},null,8,["initial-key","initial-name","mode","namespace","disabled","secret-name-label","onUpdateSecretName","onUpdateSecretKey"])):((0,r.openBlock)(),(0,r.createBlock)(m,{key:1,color:"error"},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("alertmanagerConfigReceiver.namespaceWarning")),1)]),_:1}))]),(0,r.createElementVNode)("div",c,[(0,r.createElementVNode)("div",u,[(0,r.createVNode)(g,{value:n.value.tlsConfig.serverName,"onUpdate:value":t[0]||(t[0]=e=>n.value.tlsConfig.serverName=e),mode:n.mode,label:e.t("monitoringReceiver.tls.serverName"),tooltip:e.t("monitoringReceiver.tls.serverNameTooltip")},null,8,["value","mode","label","tooltip"])])])])}var h=n(79380),p=n(9980),f=n(89455),m=n(14220),g={components:{Banner:p.l,LabeledInput:h.o,SimpleSecretSelector:f.A},props:{mode:{type:String,required:!0},value:{type:Object,required:!0},namespace:{type:String,required:!0}},data(){return this.value["tlsConfig"]=this.value.tlsConfig||{},{initialCaSecretKey:this.value.tlsConfig.ca?.secret?.key?this.value.tlsConfig.ca.secret.key:"",initialCaSecretName:this.value.tlsConfig.ca?.secret?.name?this.value.tlsConfig.ca.secret.name:"",initialClientCertSecretKey:this.value.tlsConfig.cert?.secret?.key?this.value.tlsConfig.cert.secret.key:"",initialClientCertSecretName:this.value.tlsConfig.cert?.secret?.name?this.value.tlsConfig.cert.secret.name:"",initialClientKeySecretKey:this.value.tlsConfig.keySecret?.key?this.value.tlsConfig.keySecret.key:"",initialClientKeySecretName:this.value.tlsConfig.keySecret?.name?this.value.tlsConfig.keySecret.name:"",view:m.nW,none:"__[[NONE]]__"}},methods:{updateCaSecretName(e){const t=this.value.tlsConfig.ca?.secret?.key||"";this.value.tlsConfig.ca||(this.value.tlsConfig["ca"]={secret:{name:e,key:""}}),this.value.tlsConfig.ca?.secret?e===this.none?this.value.tlsConfig.ca={}:this.value.tlsConfig.ca.secret={key:t,name:e}:this.value.tlsConfig.ca["secret"]={key:t,name:e}},updateCaSecretKey(e){const t=this.value.tlsConfig.ca?.secret?.name||"";this.value.tlsConfig.ca||(this.value.tlsConfig["ca"]={secret:{name:"",key:e}}),this.value.tlsConfig.ca?.secret?this.value.tlsConfig.ca.secret={name:t,key:e}:this.value.tlsConfig.ca["secret"]={key:"",name:t}},updateClientCertSecretName(e){const t=this.value.tlsConfig.cert?.secret?.key||"";this.value.tlsConfig.cert||(this.value.tlsConfig["cert"]={secret:{name:e,key:""}}),this.value.tlsConfig.cert?.secret?e===this.none?this.value.tlsConfig.cert={}:this.value.tlsConfig.cert.secret={key:t,name:e}:this.value.tlsConfig.cert["secret"]={key:"",name:e}},updateClientCertSecretKey(e){const t=this.value.tlsConfig.cert?.secret?.name||"";this.value.tlsConfig.cert||(this.value.tlsConfig["cert"]={secret:{name:"",key:e}}),this.value.tlsConfig.cert?.secret?this.value.tlsConfig.cert.secret={name:t,key:e}:this.value.tlsConfig.cert["secret"]={key:"",name:t}},updateClientKeySecretName(e){const t=this.value.tlsConfig.keySecret?.key||"";this.value.tlsConfig.keySecret?e===this.none?this.value.tlsConfig.keySecret={}:this.value.tlsConfig.keySecret={key:t,name:e}:this.value.tlsConfig["keySecret"]={key:"",name:e}},updateClientKeySecretKey(e){const t=this.value.tlsConfig.keySecret?.name||"";this.value.tlsConfig.keySecret?this.value.tlsConfig.keySecret={name:t,key:e}:this.value.tlsConfig["keySecret"]={key:e,name:""}}}},v=n(47433);const b=(0,v.A)(g,[["render",d]]);var y=b},51557:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return x}});var r=n(9274);const i={class:"row mb-20"},o={class:"col span-6"},a={class:"col span-6"},s={class:"row mb-20"},l={class:"col span-12"},c={class:"row mb-20"},u={class:"col span-6"},d={class:"col span-6"},h={key:0,class:"row mb-20"},p={class:"col span-6"},f={class:"row mb-20"};function m(e,t,n,m,g,v){const b=(0,r.resolveComponent)("LabeledInput"),y=(0,r.resolveComponent)("Checkbox"),w=(0,r.resolveComponent)("SimpleSecretSelector"),O=(0,r.resolveComponent)("Banner"),S=(0,r.resolveComponent)("TLS");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[t[7]||(t[7]=(0,r.createElementVNode)("div",{class:"row"},[(0,r.createElementVNode)("div",{class:"col span-12"},[(0,r.createElementVNode)("h3",null,"Target")])],-1)),(0,r.createElementVNode)("div",i,[(0,r.createElementVNode)("div",o,[(0,r.createVNode)(b,{value:n.value.to,"onUpdate:value":t[0]||(t[0]=e=>n.value.to=e),mode:n.mode,label:"Default Recipient Address",placeholder:"e.g. admin@example.com"},null,8,["value","mode"])]),(0,r.createElementVNode)("div",a,[(0,r.createVNode)(y,{value:n.value.sendResolved,"onUpdate:value":t[1]||(t[1]=e=>n.value.sendResolved=e),mode:n.mode,class:"mt-20",label:"Enable send resolved alerts"},null,8,["value","mode"])])]),t[8]||(t[8]=(0,r.createElementVNode)("h2",{class:"mb-10"}," SMTP ",-1)),(0,r.createElementVNode)("div",s,[(0,r.createElementVNode)("div",l,[(0,r.createVNode)(b,{value:n.value.from,"onUpdate:value":t[2]||(t[2]=e=>n.value.from=e),mode:n.mode,label:"Sender",placeholder:"e.g. admin@example.com"},null,8,["value","mode"])])]),(0,r.createElementVNode)("div",c,[(0,r.createElementVNode)("div",u,[(0,r.createVNode)(b,{value:n.value.smarthost,"onUpdate:value":t[3]||(t[3]=e=>n.value.smarthost=e),mode:n.mode,label:"Host",placeholder:"e.g. 192.168.1.121:587"},null,8,["value","mode"])]),(0,r.createElementVNode)("div",d,[(0,r.createVNode)(y,{value:n.value.requireTLS,"onUpdate:value":t[4]||(t[4]=e=>n.value.requireTLS=e),mode:n.mode,class:"mt-20",label:"Use TLS"},null,8,["value","mode"])])]),n.namespace?((0,r.openBlock)(),(0,r.createElementBlock)("div",h,[(0,r.createElementVNode)("div",p,[(0,r.createVNode)(b,{value:n.value.authUsername,"onUpdate:value":t[5]||(t[5]=e=>n.value.authUsername=e),mode:n.mode,label:e.t("monitoring.alertmanagerConfig.email.username"),placeholder:"e.g. John"},null,8,["value","mode","label"])])])):(0,r.createCommentVNode)("",!0),(0,r.createElementVNode)("div",f,[n.namespace?((0,r.openBlock)(),(0,r.createBlock)(w,{key:0,"initial-key":g.initialAuthPasswordSecretKey,mode:n.mode,"initial-name":g.initialAuthPasswordSecretName,namespace:n.namespace,disabled:n.mode===g.view,"secret-name-label":e.t("monitoring.alertmanagerConfig.email.password"),onUpdateSecretName:v.updateAuthPasswordSecretName,onUpdateSecretKey:v.updateAuthPasswordSecretKey},null,8,["initial-key","mode","initial-name","namespace","disabled","secret-name-label","onUpdateSecretName","onUpdateSecretKey"])):((0,r.openBlock)(),(0,r.createBlock)(O,{key:1,color:"error"},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("alertmanagerConfigReceiver.namespaceWarning")),1)]),_:1}))]),(0,r.createVNode)(S,{value:n.value,class:"mb-20",mode:n.mode,namespace:n.namespace,"onUpdate:value":t[6]||(t[6]=t=>e.$emit("input",t))},null,8,["value","mode","namespace"])])}var g=n(79380),v=n(42200),b=n(99383),y=n(89455),w=n(14220),O={emits:["input"],components:{Checkbox:v.S,LabeledInput:g.o,SimpleSecretSelector:y.A,TLS:b.A},props:{mode:{type:String,required:!0},value:{type:Object,required:!0},namespace:{type:String,default:""}},data(){return this.value["sendResolved"]=this.value.sendResolved||!1,this.value["requireTLS"]=this.value.requireTLS||!1,{view:w.nW,initialAuthPasswordSecretName:this.value?.authPassword?.name?this.value.authPassword.name:"",initialAuthPasswordSecretKey:this.value.authPassword?.key?this.value.authPassword.key:"",none:"__[[NONE]]__"}},methods:{updateAuthPasswordSecretName(e){const t=this.value.authPassword?.key||"";this.value.authPassword?e===this.none?delete this.value.authPassword:this.value.authPassword={key:t,name:e}:this.value["authPassword"]={key:"",name:e}},updateAuthPasswordSecretKey(e){const t=this.value.authPassword?.name||"";this.value.authPassword?this.value.authPassword={name:t,key:e}:this.value["authPassword"]={name:"",key:e}}}},S=n(47433);const E=(0,S.A)(O,[["render",m]]);var x=E},22243:function(e,t,n){"use strict";n.r(t),n.d(t,{TARGETS:function(){return R},TYPES:function(){return N},default:function(){return M}});var r=n(9274);const i={class:"row mb-20"},o={class:"row mb-20"},a={class:"col span-12"},s={class:"row mb-20"},l={class:"row"},c={class:"col span-12"},u={class:"responders-heading"},d={class:"row responder"},h={class:"col span-6"},p={key:0},f={class:"col-span-6 target-container"},m={key:0};function g(e,t,n,g,v,b){const y=(0,r.resolveComponent)("SimpleSecretSelector"),w=(0,r.resolveComponent)("Banner"),O=(0,r.resolveComponent)("LabeledInput"),S=(0,r.resolveComponent)("Checkbox"),E=(0,r.resolveComponent)("Select"),x=(0,r.resolveComponent)("InputWithSelect"),_=(0,r.resolveComponent)("ArrayList");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[t[5]||(t[5]=(0,r.createElementVNode)("div",{class:"row"},[(0,r.createElementVNode)("div",{class:"col span-12"},[(0,r.createElementVNode)("h3",null,"Target")])],-1)),(0,r.createElementVNode)("div",i,[n.namespace?((0,r.openBlock)(),(0,r.createBlock)(y,{key:0,"initial-key":v.initialApiKeySecretKey,mode:n.mode,"initial-name":v.initialApiKeySecretName,namespace:n.namespace,disabled:n.mode===v.view,"secret-name-label":e.t("monitoring.alertmanagerConfig.opsgenie.apiKey"),onUpdateSecretName:b.updateApiKeySecretName,onUpdateSecretKey:b.updateApiKeySecretKey},null,8,["initial-key","mode","initial-name","namespace","disabled","secret-name-label","onUpdateSecretName","onUpdateSecretKey"])):((0,r.openBlock)(),(0,r.createBlock)(w,{key:1,color:"error"},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("alertmanagerConfigReceiver.namespaceWarning")),1)]),_:1}))]),(0,r.createElementVNode)("div",o,[(0,r.createElementVNode)("div",a,[(0,r.createVNode)(O,{value:n.value.httpConfig.proxyURL,"onUpdate:value":t[0]||(t[0]=e=>n.value.httpConfig.proxyURL=e),mode:n.mode,label:"Proxy URL",placeholder:"e.g. http://my-proxy/"},null,8,["value","mode"])])]),(0,r.createElementVNode)("div",s,[(0,r.createVNode)(S,{value:n.value.sendResolved,"onUpdate:value":t[1]||(t[1]=e=>n.value.sendResolved=e),mode:n.mode,label:"Enable send resolved alerts"},null,8,["value","mode"])]),(0,r.createElementVNode)("div",l,[(0,r.createElementVNode)("div",c,[t[4]||(t[4]=(0,r.createElementVNode)("h3",null,"Responders",-1)),(0,r.createVNode)(_,{value:v.responders,"onUpdate:value":t[2]||(t[2]=e=>v.responders=e),mode:n.mode,"default-add-value":v.defaultResponder,"show-header":!0},{"column-headers":(0,r.withCtx)(()=>[(0,r.createElementVNode)("div",u,[(0,r.createElementVNode)("div",{class:(0,r.normalizeClass)(["row",{"mb-15":b.isView,"mb-10":!b.isView}])},[...t[3]||(t[3]=[(0,r.createElementVNode)("div",{class:"col span-6"},[(0,r.createElementVNode)("span",{class:"text-label"},"Type")],-1),(0,r.createElementVNode)("div",{class:"col span-6 send-to"},[(0,r.createElementVNode)("span",{class:"text-label"},"Send To")],-1)])],2)])]),columns:(0,r.withCtx)(e=>[(0,r.createElementVNode)("div",d,[(0,r.createElementVNode)("div",h,[b.isView?((0,r.openBlock)(),(0,r.createElementBlock)("span",p,(0,r.toDisplayString)(b.typeLabel(e.row.value.type)),1)):((0,r.openBlock)(),(0,r.createBlock)(E,{key:1,value:e.row.value.type,"onUpdate:value":t=>e.row.value.type=t,mode:n.mode,options:v.TYPES},null,8,["value","onUpdate:value","mode","options"]))]),(0,r.createElementVNode)("div",f,[b.isView?((0,r.openBlock)(),(0,r.createElementBlock)("span",m,(0,r.toDisplayString)(b.targetLabel(e.row.value.target))+": "+(0,r.toDisplayString)(e.row.value.value),1)):((0,r.openBlock)(),(0,r.createBlock)(x,{key:1,class:"target",mode:n.mode,options:v.TARGETS,"select-value":e.row.value.target,"text-value":e.row.value.value,"onUpdate:value":t=>b.updateResponder(t,e.row.value)},null,8,["mode","options","select-value","text-value","onUpdate:value"]))])])]),_:1},8,["value","mode","default-add-value"])])])])}var v=n(41462),b=n(79380),y=n(44047),w=n(42200);const O=["disabled","placeholder"];function S(e,t,n,i,o,a){const s=(0,r.resolveComponent)("LabeledSelect"),l=(0,r.resolveComponent)("Select"),c=(0,r.resolveComponent)("LabeledInput");return(0,r.openBlock)(),(0,r.createElementBlock)("div",{class:(0,r.normalizeClass)([{"select-after":!n.selectBeforeText},"input-container row"])},[n.selectLabel?((0,r.openBlock)(),(0,r.createBlock)(s,{key:0,value:o.selected,"onUpdate:value":[t[0]||(t[0]=e=>o.selected=e),a.change],label:n.selectLabel,class:(0,r.normalizeClass)({"in-input":!i.isView}),options:n.options,searchable:!1,clearable:!1,disabled:n.disabled||i.isView,taggable:n.taggable,"create-option":e=>({label:e,value:e}),multiple:!1,mode:n.mode,"option-label":n.optionLabel,placement:e.$attrs.placement?e.$attrs.placement:null,"v-bind":e.$attrs,rules:n.selectRules},null,8,["value","label","class","options","disabled","taggable","create-option","mode","option-label","placement","v-bind","rules","onUpdate:value"])):((0,r.openBlock)(),(0,r.createBlock)(l,{key:1,value:o.selected,"onUpdate:value":[t[1]||(t[1]=e=>o.selected=e),a.change],options:n.options,searchable:n.searchable,disabled:n.disabled||i.isView,clearable:!1,class:"in-input",taggable:n.taggable,"create-option":e=>({label:e,value:e}),multiple:!1,mode:n.mode,"option-label":n.optionLabel,placement:e.$attrs.placement?e.$attrs.placement:null,"v-bind":e.$attrs},null,8,["value","options","searchable","disabled","taggable","create-option","mode","option-label","placement","v-bind","onUpdate:value"])),n.textLabel||n.textRules.length>0?((0,r.openBlock)(),(0,r.createBlock)(c,(0,r.mergeProps)({key:2,ref:"text",value:o.string,"onUpdate:value":t[2]||(t[2]=e=>o.string=e),class:"input-string col span-8",label:n.textLabel,placeholder:n.placeholder,disabled:n.disabled||n.textDisabled,required:n.textRequired,mode:n.mode,rules:n.textRules},e.$attrs,{"onUpdate:value":a.change}),{label:(0,r.withCtx)(()=>[(0,r.renderSlot)(e.$slots,"label",{},void 0,!0)]),suffix:(0,r.withCtx)(()=>[(0,r.renderSlot)(e.$slots,"suffix",{},void 0,!0)]),_:3},16,["value","label","placeholder","disabled","required","mode","rules","onUpdate:value"])):(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("input",{key:3,ref:"text","onUpdate:modelValue":t[3]||(t[3]=e=>o.string=e),class:"input-string",disabled:i.isView,placeholder:n.placeholder,autocomplete:"off",onInput:t[4]||(t[4]=(...e)=>a.change&&a.change(...e))},null,40,O)),[[r.vModelText,o.string]])],2)}var E=n(49452),x=n(14220),_={name:"InputWithSelect",inheritAttrs:!1,emits:["update:value"],components:{LabeledInput:b.o,LabeledSelect:E.A,Select:y.A},props:{disabled:{type:Boolean,default:!1},searchable:{type:Boolean,default:!0},taggable:{type:Boolean,default:!1},selectLabel:{type:String,default:""},selectValue:{type:String,default:null},optionLabel:{type:String,default:"label"},options:{type:Array,required:!0},selectBeforeText:{type:Boolean,default:!0},textLabel:{type:String,default:""},textRequired:{type:Boolean,default:!1},textDisabled:{type:Boolean,default:!1},textValue:{type:[String,Number],default:""},placeholder:{type:String,default:""},textRules:{default:()=>[],type:Array},selectRules:{default:()=>[],type:Array},mode:{type:String,default:x.G5}},setup(e){const t=(0,r.computed)(()=>e.mode===x.nW);return{isView:t}},data(){return{selected:this.selectValue||this.options[0].value,string:this.textValue}},methods:{focus(){const e=this.$refs.text;e&&e.focus()},change(){this.$emit("update:value",{selected:this.selected,text:this.string})}},watch:{textValue(e){this.string=e}}},k=(n(31072),n(47433));const C=(0,k.A)(_,[["render",S],["__scopeId","data-v-6f50f528"]]);var A=C,T=n(89455);const R=[{label:"Id",value:"id"},{label:"Name",value:"name"},{label:"Username",value:"username"}],N=[{label:"Team",value:"team"},{label:"User",value:"user"},{label:"Escalation",value:"escalation"},{label:"Schedule",value:"schedule"}];var P={components:{ArrayList:v.A,Checkbox:w.S,InputWithSelect:A,LabeledInput:b.o,Select:y.A,SimpleSecretSelector:T.A},props:{mode:{type:String,required:!0},value:{type:Object,required:!0},namespace:{type:String,default:""}},data(){this.value["httpConfig"]=this.value.httpConfig||{},this.value["sendResolved"]="boolean"!==typeof this.value.sendResolved||this.value.send_resolved,this.value["responders"]=this.value.responders||[];const e=this.value.responders.map(e=>{const t=R.find(t=>e[t.value]);return{type:e.type,target:t.value,value:e[t.value]}});return{defaultResponder:{type:N[0].value,target:R[0].value,value:""},responders:e,TARGETS:R,TYPES:N,view:x.nW,initialApiKeySecretName:this.value?.apiKey?.name?this.value.apiKey.name:"",initialApiKeySecretKey:this.value?.apiKey?.key?this.value.apiKey.key:"",none:"__[[NONE]]__"}},computed:{isView(){return this.mode===x.nW}},watch:{responders:{deep:!0,handler(){const e=this.responders.map(e=>({type:e.type,[e.target]:e.value}));this.value["responders"]=e}}},methods:{updateResponder({selected:e,text:t},n){n.target=e,n.value=t},typeLabel(e){return N.find(t=>t.value===e).label},targetLabel(e){return R.find(t=>t.value===e).label},updateApiKeySecretName(e){const t=this.value.apiKey?.key||"";this.value.apiKey?e===this.none?delete this.value.apiKey:this.value.apiKey={key:t,name:e}:this.value["apiKey"]={key:"",name:e}},updateApiKeySecretKey(e){const t=this.value.apiKey?.name||"";this.value.apiKey?this.value.apiKey={name:t,key:e}:this.value["apiKey"]={name:"",key:e}}}};n(7156);const I=(0,k.A)(P,[["render",g],["__scopeId","data-v-174af1a6"]]);var M=I},87450:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return w}});var r=n(9274);const i={key:0,class:"row mb-20"},o={class:"col span-6"},a={key:1,class:"row mb-20"},s={class:"row mb-20"},l={class:"col span-12"},c={class:"row"};function u(e,t,n,u,d,h){const p=(0,r.resolveComponent)("LabeledSelect"),f=(0,r.resolveComponent)("SimpleSecretSelector"),m=(0,r.resolveComponent)("Banner"),g=(0,r.resolveComponent)("LabeledInput"),v=(0,r.resolveComponent)("Checkbox");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[t[3]||(t[3]=(0,r.createElementVNode)("div",{class:"row"},[(0,r.createElementVNode)("div",{class:"col span-12"},[(0,r.createElementVNode)("h3",null,"Target")])],-1)),n.namespace?((0,r.openBlock)(),(0,r.createElementBlock)("div",i,[(0,r.createElementVNode)("div",o,[(0,r.createVNode)(p,{value:d.integrationType,"onUpdate:value":t[0]||(t[0]=e=>d.integrationType=e),options:d.integrationTypeOptions,mode:n.mode,label:"Integration Type"},null,8,["value","options","mode"])])])):(0,r.createCommentVNode)("",!0),n.namespace?((0,r.openBlock)(),(0,r.createElementBlock)("div",a,["Events API v2"===d.integrationType?((0,r.openBlock)(),(0,r.createBlock)(f,{key:0,"initial-key":d.initialRoutingKeySecretKey,mode:n.mode,"initial-name":d.initialRoutingKeySecretName,namespace:n.namespace,disabled:n.mode===d.view,"secret-name-label":e.t("monitoring.alertmanagerConfig.pagerDuty.routingKey"),onUpdateSecretName:h.updateRoutingKeySecretName,onUpdateSecretKey:h.updateRoutingKeySecretKey},null,8,["initial-key","mode","initial-name","namespace","disabled","secret-name-label","onUpdateSecretName","onUpdateSecretKey"])):(0,r.createCommentVNode)("",!0),"Prometheus"===d.integrationType?((0,r.openBlock)(),(0,r.createBlock)(f,{key:1,"initial-key":d.initialServiceKeySecretKey,mode:n.mode,"initial-name":d.initialServiceKeySecretName,namespace:n.namespace,disabled:n.mode===d.view,"secret-name-label":e.t("monitoring.alertmanagerConfig.pagerDuty.serviceKey"),onUpdateSecretName:h.updateServiceKeySecretName,onUpdateSecretKey:h.updateServiceKeySecretKey},null,8,["initial-key","mode","initial-name","namespace","disabled","secret-name-label","onUpdateSecretName","onUpdateSecretKey"])):(0,r.createCommentVNode)("",!0)])):((0,r.openBlock)(),(0,r.createBlock)(m,{key:2,color:"error"},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("alertmanagerConfigReceiver.namespaceWarning")),1)]),_:1})),(0,r.createElementVNode)("div",s,[(0,r.createElementVNode)("div",l,[(0,r.createVNode)(g,{value:n.value.httpConfig.proxyURL,"onUpdate:value":t[1]||(t[1]=e=>n.value.httpConfig.proxyURL=e),mode:n.mode,label:"Proxy URL",placeholder:"e.g. http://my-proxy/","data-testid":"v2-monitoring-receiver-pagerduty-proxy-url"},null,8,["value","mode"])])]),(0,r.createElementVNode)("div",c,[(0,r.createVNode)(v,{value:n.value.sendResolved,"onUpdate:value":t[2]||(t[2]=e=>n.value.sendResolved=e),mode:n.mode,label:"Enable send resolved alerts"},null,8,["value","mode"])])])}var d=n(79380),h=n(49452),p=n(42200),f=n(89455),m=n(14220),g=n(15554),v={components:{Banner:g.A,Checkbox:p.S,LabeledInput:d.o,LabeledSelect:h.A,SimpleSecretSelector:f.A},props:{mode:{type:String,required:!0},value:{type:Object,required:!0},namespace:{type:String,default:""}},data(){this.value["httpConfig"]=this.value.httpConfig||{},this.value["sendResolved"]="boolean"!==typeof this.value.send_resolved||this.value.send_resolved;const e={"Events API v2":"routingKey",Prometheus:"serviceKey"},t=Object.keys(e);return{integrationMapping:e,integrationTypeOptions:t,integrationType:this.value.serviceKey?t[1]:t[0],initialRoutingKeySecretKey:this.value.routingKey?.key||"",initialRoutingKeySecretName:this.value.routingKey?.name||"",initialServiceKeySecretKey:this.value.serviceKey?.key||"",initialServiceKeySecretName:this.value.serviceKey?.name||"",view:m.nW,none:"__[[NONE]]__"}},watch:{integrationType(){this.integrationTypeOptions.forEach(e=>{this.value[this.integrationMapping[e]]=null})}},methods:{updateRoutingKeySecretName(e){const t=this.value.routingKey?.key||"";this.value.routingKey?e===this.none?delete this.value.routingKey:this.value.routingKey={key:t,name:e}:this.value["routingKey"]={key:"",name:e}},updateRoutingKeySecretKey(e){const t=this.value.routingKey?.name||"";this.value.routingKey?this.value.routingKey={name:t,key:e}:this.value["routingKey"]={name:"",key:e}},updateServiceKeySecretName(e){const t=this.value.serviceKey?.key||"";this.value.serviceKey?e===this.none?delete this.value.serviceKey:this.value.serviceKey={key:t,name:e}:this.value["serviceKey"]={key:"",name:e}},updateServiceKeySecretKey(e){const t=this.value.serviceKey?.name||"";this.value.serviceKey?this.value.serviceKey={name:t,key:e}:this.value["serviceKey"]={name:"",key:e}}}},b=n(47433);const y=(0,b.A)(v,[["render",u]]);var w=y},33427:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return y}});var r=n(9274);const i={class:"row mb-20"},o={class:"helper-text text-right mt-10"},a={class:"row mb-20"},s={class:"col span-6"},l={class:"col span-6"},c={class:"row"};function u(e,t,n,u,d,h){const p=(0,r.resolveComponent)("SimpleSecretSelector"),f=(0,r.resolveComponent)("Banner"),m=(0,r.resolveComponent)("t"),g=(0,r.resolveComponent)("LabeledInput"),v=(0,r.resolveComponent)("Checkbox");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[t[3]||(t[3]=(0,r.createElementVNode)("div",{class:"row"},[(0,r.createElementVNode)("div",{class:"col span-12"},[(0,r.createElementVNode)("h3",null,"Target")])],-1)),(0,r.createElementVNode)("div",i,[n.namespace?((0,r.openBlock)(),(0,r.createBlock)(p,{key:0,"initial-key":d.initialSecretKey,mode:n.mode,"initial-name":d.initialSecretName,tooltip:e.t("alertmanagerConfigReceiver.slack.apiUrlTooltip"),namespace:n.namespace,disabled:n.mode===d.view,"secret-name-label":e.t("monitoring.alertmanagerConfig.slack.apiUrl"),onUpdateSecretName:h.updateSecretName,onUpdateSecretKey:h.updateSecretKey},null,8,["initial-key","mode","initial-name","tooltip","namespace","disabled","secret-name-label","onUpdateSecretName","onUpdateSecretKey"])):((0,r.openBlock)(),(0,r.createBlock)(f,{key:1,color:"error"},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("alertmanagerConfigReceiver.namespaceWarning")),1)]),_:1})),(0,r.createElementVNode)("p",o,[(0,r.createVNode)(m,{k:"monitoringReceiver.slack.info",raw:!0})])]),(0,r.createElementVNode)("div",a,[(0,r.createElementVNode)("div",s,[(0,r.createVNode)(g,{value:n.value.channel,"onUpdate:value":t[0]||(t[0]=e=>n.value.channel=e),mode:n.mode,label:"Default Channel",placeholder:"e.g. #example"},null,8,["value","mode"])]),(0,r.createElementVNode)("div",l,[(0,r.createVNode)(g,{value:n.value.httpConfig.proxyURL,"onUpdate:value":t[1]||(t[1]=e=>n.value.httpConfig.proxyURL=e),mode:n.mode,label:"Proxy URL",placeholder:"e.g. http://my-proxy/"},null,8,["value","mode"])])]),(0,r.createElementVNode)("div",c,[(0,r.createVNode)(v,{value:n.value.sendResolved,"onUpdate:value":t[2]||(t[2]=e=>n.value.sendResolved=e),mode:n.mode,label:"Enable send resolved alerts"},null,8,["value","mode"])])])}var d=n(79380),h=n(42200),p=n(9980),f=n(89455),m=n(14220),g={components:{Banner:p.l,Checkbox:h.S,LabeledInput:d.o,SimpleSecretSelector:f.A},props:{mode:{type:String,required:!0},value:{type:Object,required:!0},namespace:{type:String,default:""}},data(){return this.value["httpConfig"]=this.value.httpConfig||{},this.value["sendResolved"]=this.value.sendResolved||!1,this.mode===m.YQ&&(this.value.text=this.value.text||'{{ template "slack.rancher.text" . }}'),{view:m.nW,initialSecretKey:this.value?.apiURL?.key?this.value.apiURL.key:"",initialSecretName:this.value.apiURL?.name?this.value.apiURL.name:"",none:"__[[NONE]]__"}},methods:{updateSecretName(e){const t=this.value.apiURL?.key||"";this.value.apiURL?e===this.none?delete this.value.apiURL:this.value.apiURL={key:t,name:e}:this.value["apiURL"]={key:"",name:e}},updateSecretKey(e){const t=this.value.apiURL?.name||"";this.value.apiURL?this.value.apiURL={key:e,name:t}:this.value["apiURL"]={key:e,name:""}}}},v=n(47433);const b=(0,v.A)(g,[["render",u]]);var y=b},81655:function(e,t,n){"use strict";n.r(t),n.d(t,{ALIBABA_CLOUD_SMS_URL:function(){return D},MS_TEAMS_URL:function(){return M},WEBHOOK_TYPES:function(){return L},default:function(){return V}});var r=n(9274);const i={class:"row mb-20"},o={class:"row mb-20"},a={class:"col span-12"},s={class:"row mb-20"},l={class:"row mb-20"},c={class:"col span-12"},u={class:"row mb-20"};function d(e,t,n,d,h,p){const f=(0,r.resolveComponent)("Banner"),m=(0,r.resolveComponent)("LabeledSelect"),g=(0,r.resolveComponent)("LabeledInput"),v=(0,r.resolveComponent)("SimpleSecretSelector"),b=(0,r.resolveComponent)("Checkbox"),y=(0,r.resolveComponent)("TLS"),w=(0,r.resolveComponent)("Auth"),O=(0,r.resolveDirective)("clean-html");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[n.mode!==h.view?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createBlock)(f,{key:0,color:"info"},null,512)),[[O,e.t("monitoringReceiver.webhook.banner",{},e.raw=!0)]]):(0,r.createCommentVNode)("",!0),(0,r.createElementVNode)("div",i,[(0,r.createVNode)(m,{value:h.selectedWebhookType,"onUpdate:value":[t[0]||(t[0]=e=>h.selectedWebhookType=e),t[1]||(t[1]=e=>p.updateWebhookType(e))],disabled:n.mode===h.view,label:e.t("monitoringReceiver.webhook.add.selectWebhookType"),placeholder:e.t("monitoringReceiver.webhook.add.generic"),"localized-label":!0,options:h.webhookOptons},null,8,["value","disabled","label","placeholder","options"])]),t[7]||(t[7]=(0,r.createElementVNode)("div",{class:"row"},[(0,r.createElementVNode)("div",{class:"col span-12"},[(0,r.createElementVNode)("h3",{class:"mb-0"}," Target ")])],-1)),h.showNamespaceBanner?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createBlock)(f,{key:1,color:"info"},null,512)),[[O,e.t("monitoringReceiver.webhook.modifyNamespace",{},e.raw=!0)]]):(0,r.createCommentVNode)("",!0),(0,r.createElementVNode)("div",o,[(0,r.createElementVNode)("div",a,[(0,r.createVNode)(g,{value:n.value.url,"onUpdate:value":t[2]||(t[2]=e=>n.value.url=e),mode:n.mode,label:e.t("monitoring.alertmanagerConfig.webhook.url"),tooltip:e.t("monitoring.alertmanagerConfig.webhook.urlSecretTooltip")},null,8,["value","mode","label","tooltip"])])]),(0,r.createElementVNode)("div",s,[n.namespace?((0,r.openBlock)(),(0,r.createBlock)(v,{key:0,"initial-key":h.initialUrlSecretKey,"initial-name":h.initialUrlSecretName,mode:n.mode,namespace:n.namespace,disabled:n.mode===h.view,"secret-name-label":e.t("monitoring.alertmanagerConfig.webhook.urlSecret"),onUpdateSecretName:p.updateUrlSecretName,onUpdateSecretKey:p.updateUrlSecretKey},null,8,["initial-key","initial-name","mode","namespace","disabled","secret-name-label","onUpdateSecretName","onUpdateSecretKey"])):((0,r.openBlock)(),(0,r.createBlock)(f,{key:1,color:"error"},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("alertmanagerConfigReceiver.namespaceWarning")),1)]),_:1}))]),(0,r.createElementVNode)("div",l,[(0,r.createElementVNode)("div",c,[(0,r.createVNode)(g,{value:n.value.httpConfig.proxyURL,"onUpdate:value":t[3]||(t[3]=e=>n.value.httpConfig.proxyURL=e),mode:n.mode,label:e.t("monitoringReceiver.shared.proxyUrl.label"),placeholder:e.t("monitoringReceiver.shared.proxyUrl.placeholder")},null,8,["value","mode","label","placeholder"])])]),(0,r.createElementVNode)("div",u,[(0,r.createVNode)(b,{value:n.value.sendResolved,"onUpdate:value":t[4]||(t[4]=e=>n.value.sendResolved=e),mode:n.mode,label:e.t("monitoringReceiver.shared.sendResolved.label")},null,8,["value","mode","label"])]),(0,r.createVNode)(y,{value:n.value.httpConfig,"onUpdate:value":t[5]||(t[5]=e=>n.value.httpConfig=e),class:"mb-20",mode:n.mode,namespace:n.namespace},null,8,["value","mode","namespace"]),(0,r.createVNode)(w,{value:n.value.httpConfig,"onUpdate:value":t[6]||(t[6]=e=>n.value.httpConfig=e),mode:n.mode,namespace:n.namespace},null,8,["value","mode","namespace"])])}var h=n(79380),p=n(49452),f=n(42200),m=n(9980),g=n(89455),v=n(14220),b=n(99383);const y={class:"row"},w={class:"col span-6"},O={class:"row mb-20"},S={class:"col span-12"},E={key:0,class:"row mb-20"},x={key:1,class:"row mb-20"},_={key:2,class:"row mb-20"};function k(e,t,n,i,o,a){const s=(0,r.resolveComponent)("LabeledSelect"),l=(0,r.resolveComponent)("SimpleSecretSelector"),c=(0,r.resolveComponent)("Banner");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[(0,r.createElementVNode)("div",y,[(0,r.createElementVNode)("div",w,[(0,r.createElementVNode)("h3",null,(0,r.toDisplayString)(e.t("monitoringReceiver.auth.label")),1)])]),(0,r.createElementVNode)("div",O,[(0,r.createElementVNode)("div",S,[(0,r.createVNode)(s,{value:o.authType,"onUpdate:value":[t[0]||(t[0]=e=>o.authType=e),t[1]||(t[1]=e=>a.initializeType(o.authOptions,o.authType))],disabled:n.mode===o.view,options:o.authOptions,label:"Auth Type"},null,8,["value","disabled","options"])])]),"basicAuth"===o.authType?((0,r.openBlock)(),(0,r.createElementBlock)("div",E,[n.namespace?((0,r.openBlock)(),(0,r.createBlock)(l,{key:0,"initial-key":o.initialBasicAuthUsernameSecretKey,"initial-name":o.initialBasicAuthUsernameSecretName,mode:n.mode,namespace:n.namespace,disabled:n.mode===o.view,"secret-name-label":e.t("monitoring.alertmanagerConfig.auth.basicAuthUsername"),onUpdateSecretName:a.updateBasicAuthUsernameSecretName,onUpdateSecretKey:a.updateBasicAuthUsernameSecretKey},null,8,["initial-key","initial-name","mode","namespace","disabled","secret-name-label","onUpdateSecretName","onUpdateSecretKey"])):((0,r.openBlock)(),(0,r.createBlock)(c,{key:1,color:"error"},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("alertmanagerConfigReceiver.namespaceWarning")),1)]),_:1}))])):(0,r.createCommentVNode)("",!0),"basicAuth"===o.authType?((0,r.openBlock)(),(0,r.createElementBlock)("div",x,[n.namespace?((0,r.openBlock)(),(0,r.createBlock)(l,{key:0,"initial-key":o.initialBasicAuthPasswordSecretKey,"initial-name":o.initialBasicAuthPasswordSecretName,mode:n.mode,namespace:n.namespace,disabled:n.mode===o.view,"secret-name-label":e.t("monitoring.alertmanagerConfig.auth.basicAuthPassword"),onUpdateSecretName:a.updateBasicAuthPasswordSecretName,onUpdateSecretKey:a.updateBasicAuthPasswordSecretKey},null,8,["initial-key","initial-name","mode","namespace","disabled","secret-name-label","onUpdateSecretName","onUpdateSecretKey"])):((0,r.openBlock)(),(0,r.createBlock)(c,{key:1,color:"error"},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("alertmanagerConfigReceiver.namespaceWarning")),1)]),_:1}))])):(0,r.createCommentVNode)("",!0),"bearerTokenSecret"===o.authType?((0,r.openBlock)(),(0,r.createElementBlock)("div",_,[n.namespace?((0,r.openBlock)(),(0,r.createBlock)(l,{key:0,"initial-key":o.initialBearerTokenSecretKey,"initial-name":o.initialBearerTokenSecretName,mode:n.mode,namespace:n.namespace,disabled:n.mode===o.view,"secret-name-label":e.t("monitoring.alertmanagerConfig.auth.bearerTokenSecret"),onUpdateSecretName:a.updateBearerTokenSecretName,onUpdateSecretKey:a.updateBearerTokenSecretKey},null,8,["initial-key","initial-name","mode","namespace","disabled","secret-name-label","onUpdateSecretName","onUpdateSecretKey"])):((0,r.openBlock)(),(0,r.createBlock)(c,{key:1,color:"error"},{default:(0,r.withCtx)(()=>[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("alertmanagerConfigReceiver.namespaceWarning")),1)]),_:1}))])):(0,r.createCommentVNode)("",!0)])}var C=n(15554),A=n(3514),T=n.n(A),R={components:{Banner:C.A,LabeledSelect:p.A,SimpleSecretSelector:g.A},props:{mode:{type:String,required:!0},value:{type:Object,required:!0},namespace:{type:String,required:!0}},data(){this.value["basicAuth"]=this.value.basicAuth||{};const e=[{value:"none",label:this.t("monitoringReceiver.auth.none.label")},{value:"basicAuth",label:this.t("monitoringReceiver.auth.basicAuth.label"),default:{}},{value:"bearerTokenSecret",label:this.t("monitoringReceiver.auth.bearerToken.label"),default:{}}],t=e.map(e=>e.value),n=t.find(e=>!T()(this.value[e]))||t[0];return this.initializeType(e,n),{authOptions:e,authTypes:t,authType:n,view:v.nW,none:"__[[NONE]]__",initialBearerTokenSecretName:this.value?.bearerTokenSecret?.name?this.value.bearerTokenSecret.name:"",initialBearerTokenSecretKey:this.value?.bearerTokenSecret?.key?this.value.bearerTokenSecret.key:"",initialBasicAuthUsernameSecretName:this.value?.basicAuth?.username?.name?this.value.basicAuth.username.name:"",initialBasicAuthUsernameSecretKey:this.value?.basicAuth?.username?.key?this.value.basicAuth.username.key:"",initialBasicAuthPasswordSecretName:this.value?.basicAuth?.password?.name?this.value.basicAuth.password.name:"",initialBasicAuthPasswordSecretKey:this.value?.basicAuth?.password?.key?this.value.basicAuth.password.key:""}},methods:{initializeType(e,t){e.forEach(e=>{e.value===t&&"none"!==t?this.value[e.value]=this.value[e.value]||e.default:"undefined"!==typeof this.value[e.value]&&delete this.value[e.value]})},updateBearerTokenSecretName(e){const t=this.value.bearerTokenSecret?.key||"";this.value.bearerTokenSecret?e===this.none?delete this.value.bearerTokenSecret:this.value.bearerTokenSecret={key:t,name:e}:this.value["bearerTokenSecret"]={key:"",name:e}},updateBearerTokenSecretKey(e){const t=this.value.bearerTokenSecret?.name||"";this.value.bearerTokenSecret?this.value.bearerTokenSecret={name:t,key:e}:this.value["bearerTokenSecret"]={name:"",key:e}},updateBasicAuthUsernameSecretName(e){this.value.basicAuth||(this.value["basicAuth"]={username:{key:"",name:e},password:{key:"",name:""}});const t=this.value.basicAuth.username?.key||"";this.value.basicAuth.username?e===this.none?delete this.value.basicAuth.username:this.value.basicAuth.username={key:t,name:e}:this.value.basicAuth["username"]={key:"",name:e}},updateBasicAuthUsernameSecretKey(e){this.value.basicAuth||(this.value["basicAuth"]={username:{key:e,name:""},password:{key:"",name:""}});const t=this.value.basicAuth.username?.name||"";this.value.basicAuth.username?this.value.basicAuth.username={key:e,name:t}:this.value.basicAuth["username"]={key:e,name:""}},updateBasicAuthPasswordSecretName(e){this.value.basicAuth||(this.value["basicAuth"]={username:{key:"",name:""},password:{key:"",name:e}});const t=this.value.basicAuth.password?.key||"";this.value.basicAuth.password?e===this.none?delete this.value.basicAuth.password:this.value.basicAuth.password={key:t,name:e}:this.value.basicAuth["password"]={key:"",name:e}},updateBasicAuthPasswordSecretKey(e){this.value.basicAuth||(this.value["basicAuth"]={username:{key:"",name:""},password:{key:e,name:""}});const t=this.value.basicAuth.password?.name||"";this.value.basicAuth.password?this.value.basicAuth.password={key:e,name:t}:this.value.basicAuth["password"]={key:e,name:""}}}},N=n(47433);const P=(0,N.A)(R,[["render",k]]);var I=P;const M="http://rancher-alerting-drivers-prom2teams.cattle-monitoring-system.svc:8089/v2/connector",D="http://rancher-alerting-drivers-sachet.cattle-monitoring-system.svc:9876/alert",L={ALIBABA_CLOUD_SMS:"alibaba-cloud-sms",GENERIC:"generic",MS_TEAMS:"ms-teams"};var B={components:{Auth:I,Banner:m.l,Checkbox:f.S,LabeledInput:h.o,LabeledSelect:p.A,SimpleSecretSelector:g.A,TLS:b.A},props:{mode:{type:String,required:!0},value:{type:Object,required:!0},namespace:{type:String,default:""}},data(e){this.value["httpConfig"]=this.value.httpConfig||{},this.value["sendResolved"]=this.value.sendResolved||!1;const t=this.value.url===M||this.value.url===D;return{showNamespaceBanner:t&&this.mode!==v.nW,view:v.nW,initialUrlSecretName:this.value?.urlSecret?.name?this.value.urlSecret.name:"",initialUrlSecretKey:this.value?.urlSecret?.key?this.value.urlSecret.key:"",webhookOptons:[{label:this.t("monitoringReceiver.webhook.add.generic"),value:L.GENERIC},{label:this.t("monitoringReceiver.webhook.add.msTeams"),value:L.MS_TEAMS},{label:this.t("monitoringReceiver.webhook.add.alibabaCloudSms"),value:L.ALIBABA_CLOUD_SMS}],msTeamsUrl:M,alibabaCloudSmsUrl:D,selectedWebhookType:this.getTypeFromUrl(this.value.url),none:"__[[NONE]]__"}},methods:{getTypeFromUrl(e){switch(e){case M:return L.MS_TEAMS;case D:return L.ALIBABA_CLOUD_SMS;default:return L.GENERIC}},updateUrlSecretName(e){const t=this.value.urlSecret?.key||"";this.value.urlSecret?e===this.none?delete this.value.urlSecret:this.value.urlSecret={key:t,name:e}:this.value["urlSecret"]={key:"",name:e}},updateUrlSecretKey(e){const t=this.value.urlSecret?.name||"";this.value.urlSecret?this.value.urlSecret={name:t,key:e}:this.value["urlSecret"]={name:"",key:e}},updateWebhookType(e){switch(e){case"ms-teams":this.value.url=this.msTeamsUrl,this.selectedWebhookType=L.MS_TEAMS;break;case"alibaba-cloud-sms":this.value.url=this.alibabaCloudSmsUrl,this.selectedWebhookType=L.ALIBABA_CLOUD_SMS;break;default:this.value.url="",this.selectedWebhookType=L.GENERIC}},updateWebhookUrl(e){this.value.url=e}}};const $=(0,N.A)(B,[["render",d]]);var V=$},2572:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return g}});var r=n(9274);const i={class:"mt-10"},o={class:"mb-10"},a={class:"description"};function s(e,t,n,s,l,c){const u=(0,r.resolveComponent)("Banner"),d=(0,r.resolveDirective)("clean-html");return(0,r.openBlock)(),(0,r.createElementBlock)("div",i,[(0,r.createElementVNode)("div",o,[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("promptRemove.attemptingToRemove",{type:n.type}))+" ",1),(0,r.withDirectives)((0,r.createElementVNode)("span",a,null,512),[[d,c.resourceNames(n.names,null,e.t)]])]),(0,r.createVNode)(u,{color:"warning",class:"warning"},{default:(0,r.withCtx)(()=>[(0,r.withDirectives)((0,r.createElementVNode)("span",null,null,512),[[d,e.t("fleet.workspaces.remove.warning",{},!0)]])]),_:1}),((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(l.errors,(e,t)=>((0,r.openBlock)(),(0,r.createBlock)(u,{key:t,class:"",color:"error",label:e},null,8,["label"]))),128))])}var l=n(99726),c=n(92043),u=n(9980),d=n(65359),h=n(49845),p={name:"PromptRemoveFleetWorkspacesDialog",emits:["errors"],components:{Banner:u.l},props:{value:{type:Array,default:()=>[]},names:{type:Array,default:()=>[]},type:{type:String,required:!0},close:{type:Function,required:!0}},data(){return{vendor:(0,h.f7)(),errors:[]}},computed:{...(0,d.aH)("action-menu",["toRemove"]),...(0,d.L8)({t:"i18n/t"})},methods:{resourceNames:c.Nr,async remove(e){try{await Promise.all(this.value.map(e=>e.remove())),this.close(e)}catch(t){this.errors=(0,l.rz)(t),e(!1)}}}},f=(n(81133),n(47433));const m=(0,f.A)(p,[["render",s],["__scopeId","data-v-07ec0ff4"]]);var g=m},39126:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return d}});var r=n(9274);const i={key:0,class:"text info mb-10 mt-20"},o={key:1,class:"text-warning mb-10 mt-20"};function a(e,t,n,a,s,l){const c=(0,r.resolveDirective)("clean-html");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("promptRemove.attemptingToRemove",{type:n.type}))+" ",1),(0,r.withDirectives)((0,r.createElementVNode)("span",null,null,512),[[c,e.resourceNames(e.names,null,e.t)]]),e.info?((0,r.openBlock)(),(0,r.createElementBlock)("div",i,[(0,r.withDirectives)((0,r.createElementVNode)("span",null,null,512),[[c,e.info]])])):(0,r.createCommentVNode)("",!0),e.warning?((0,r.openBlock)(),(0,r.createElementBlock)("div",o,(0,r.toDisplayString)(e.warning),1)):(0,r.createCommentVNode)("",!0)])}var s=n(55105),l={name:"GlobalRolePromptRemove",mixins:[s["default"]],props:{value:{type:Array,default:()=>[]},type:{type:String,required:!0}}},c=(n(99447),n(47433));const u=(0,c.A)(l,[["render",a],["__scopeId","data-v-7155ccc2"]]);var d=u},11193:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return y}});var r=n(9274);const i={class:"mb-10"},o={class:"display-name"},a={class:"delete-warning"},s={class:"mt-10"},l={key:0,class:"mt-20 remove-project-dialog"},c={class:"mt-10 ml-20"};function u(e,t,n,u,d,h){const p=(0,r.resolveComponent)("Checkbox"),f=(0,r.resolveDirective)("clean-html");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[(0,r.createElementVNode)("div",null,[(0,r.createElementVNode)("div",i,[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("promptRemove.attemptingToRemove",{type:n.type}))+" ",1),(0,r.createElementVNode)("span",o,(0,r.toDisplayString)(`${h.displayName}.`),1),h.canSeeProjectlessNamespaces?(0,r.createCommentVNode)("",!0):((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:0},[(0,r.createElementVNode)("span",a,(0,r.toDisplayString)(e.t("promptRemove.willDeleteAssociatedNamespaces")),1),t[1]||(t[1]=(0,r.createTextVNode)()),t[2]||(t[2]=(0,r.createElementVNode)("br",null,null,-1)),(0,r.withDirectives)((0,r.createElementVNode)("div",s,null,512),[[f,h.resourceNames(h.names,null,e.t)]])],64))]),h.filteredNamespaces.length>0&&h.canSeeProjectlessNamespaces?((0,r.openBlock)(),(0,r.createElementBlock)("div",l,[(0,r.createVNode)(p,{value:d.deleteProjectNamespaces,"onUpdate:value":t[0]||(t[0]=e=>d.deleteProjectNamespaces=e),label:e.t("promptRemove.deleteAssociatedNamespaces")},null,8,["value","label"]),(0,r.createElementVNode)("div",c,[(0,r.withDirectives)((0,r.createElementVNode)("span",null,null,512),[[f,h.resourceNames(h.names,null,e.t)]])])])):(0,r.createCommentVNode)("",!0)])])}var d=n(65359),h=n(2841),p=n(35664),f=n(42200),m=n(92043),g={name:"ProjectAndNamespacesPromptRemove",components:{Checkbox:f.S},props:{value:{type:Array,default:()=>[]},type:{type:String,required:!0}},async fetch(){this.allNamespaces=await this.$store.dispatch("cluster/findAll",{type:p.CU}),this.allProjects=await this.$store.dispatch("management/findAll",{type:p.Mc.PROJECT})},data(){return{deleteProjectNamespaces:!1,allNamespaces:[],allProjects:[]}},computed:{...(0,d.aH)("action-menu",["toRemove"]),...(0,d.L8)({t:"i18n/t"}),...(0,d.L8)(["currentCluster"]),currentProject(){return this.allProjects?this.value[0]:{}},filteredNamespaces(){return this.currentProject?this.allNamespaces.filter(e=>e.metadata.labels[h.yl]===this.currentProject.metadata?.name):[]},displayName(){return this.currentProject?.spec?.displayName},names(){return this.filteredNamespaces.map(e=>e.nameDisplay).slice(0,5)},canSeeProjectlessNamespaces(){return this.currentCluster.canUpdate}},methods:{resourceNames:m.Nr,remove(){return!(!this.deleteProjectNamespaces&&this.canSeeProjectlessNamespaces)&&Promise.all(this.filteredNamespaces.map(e=>e.remove())).then(()=>!1)}}},v=(n(28022),n(47433));const b=(0,v.A)(g,[["render",u],["__scopeId","data-v-017c9f08"]]);var y=b},24093:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return d}});var r=n(9274);const i={key:0,class:"text info mb-10 mt-20"},o={key:1,class:"text-warning mb-10 mt-20"};function a(e,t,n,a,s,l){const c=(0,r.resolveDirective)("clean-html");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("promptRemove.attemptingToRemove",{type:n.type}))+" ",1),(0,r.withDirectives)((0,r.createElementVNode)("span",null,null,512),[[c,e.resourceNames(e.names,null,e.t)]]),e.info?((0,r.openBlock)(),(0,r.createElementBlock)("div",i,[(0,r.withDirectives)((0,r.createElementVNode)("span",null,null,512),[[c,e.info]])])):(0,r.createCommentVNode)("",!0),e.warning?((0,r.openBlock)(),(0,r.createElementBlock)("div",o,(0,r.toDisplayString)(e.warning),1)):(0,r.createCommentVNode)("",!0)])}var s=n(55105),l={name:"RoleTemplatePromptRemove",mixins:[s["default"]],props:{value:{type:Array,default:()=>[]},type:{type:String,required:!0}}},c=(n(12214),n(47433));const u=(0,c.A)(l,[["render",a],["__scopeId","data-v-224f553f"]]);var d=u},4563:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return v}});var r=n(9274);const i={class:"mt-10"},o={class:"mb-30"},a={class:"body"},s={class:"mb-30"};function l(e,t,n,l,c,u){const d=(0,r.resolveComponent)("Checkbox"),h=(0,r.resolveComponent)("Banner"),p=(0,r.resolveDirective)("clean-html");return(0,r.openBlock)(),(0,r.createElementBlock)("div",i,[(0,r.createElementVNode)("div",o,[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("promptRemove.attemptingToRemove",{type:n.type}))+" ",1),(0,r.withDirectives)((0,r.createElementVNode)("span",a,null,512),[[p,u.resourceNames(n.names,null,e.t)]])]),(0,r.createElementVNode)("div",s,[(0,r.createVNode)(d,{value:c.forceDelete,"onUpdate:value":t[0]||(t[0]=e=>c.forceDelete=e),label:e.t("promptForceRemove.forceDelete")},null,8,["value","label"])]),(0,r.createVNode)(h,{color:"warning","label-key":"promptForceRemove.podRemoveWarning"}),((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(c.errors,(e,t)=>((0,r.openBlock)(),(0,r.createBlock)(h,{key:t,class:"",color:"error",label:e},null,8,["label"]))),128))])}var c=n(92043),u=n(9980),d=n(71400),h=n(65359),p=n(45250),f={name:"PromptRemovePodDialog",emits:["errors"],components:{Banner:u.l,Checkbox:d.A},props:{value:{type:Array,default:()=>[]},names:{type:Array,default:()=>[]},type:{type:String,required:!0},close:{type:Function,required:!0},doneLocation:{type:Object,default:()=>{}}},data(){return{errors:[],forceDelete:!1}},computed:{...(0,h.aH)("action-menu",["toRemove"]),...(0,h.L8)({t:"i18n/t"})},methods:{resourceNames:c.Nr,async remove(e){let t;this.doneLocation&&(t={...this.doneLocation});try{await Promise.all(this.value.map(e=>this.removePod(e))),t&&!(0,p.isEmpty)(t)&&this.value?.[0]?.currentRouter().push(t),this.close()}catch(n){this.$emit("errors",n),e(!1)}},removePod(e){const t=this.forceDelete?{data:{gracePeriod:0,force:!0}}:void 0;return e.remove(t)}}},m=(n(25916),n(47433));const g=(0,m.A)(f,[["render",l],["__scopeId","data-v-44bed663"]]);var v=g},79117:function(e,t,n){"use strict";n.d(t,{A:function(){return c}});var r=n(9274);const i={class:"msg"};function o(e,t,n,o,a,s){return(0,r.openBlock)(),(0,r.createElementBlock)("span",{class:(0,r.normalizeClass)(["badge-state",e.bg])},[e.icon?((0,r.openBlock)(),(0,r.createElementBlock)("i",{key:0,class:(0,r.normalizeClass)(["icon",{[e.icon]:!0,"mr-5":!!e.msg}])},null,2)):(0,r.createCommentVNode)("",!0),(0,r.createElementVNode)("span",i,(0,r.toDisplayString)(e.msg),1),(0,r.renderSlot)(e.$slots,"content-right",{},void 0,!0)],2)}var a=(0,r.defineComponent)({props:{value:{type:Object,default:null},color:{type:String,default:null},icon:{type:String,default:null},label:{type:String,default:null}},computed:{bg(){var e;return(null===(e=this.value)||void 0===e?void 0:e.stateBackground)||this.color},msg(){var e;return(null===(e=this.value)||void 0===e?void 0:e.stateDisplay)||this.label}}}),s=(n(36261),n(13643),n(47433));const l=(0,s.A)(a,[["render",o],["__scopeId","data-v-544b3117"]]);var c=l},15554:function(e,t,n){"use strict";n.d(t,{A:function(){return v}});var r=n(9274);const i=["role","tabindex"],o={key:0,class:"banner__icon","data-testid":"banner-icon"},a=["alt"],s={key:1},l={key:2},c=["aria-label"],u=["alt"];function d(e,t,n,d,h,p){const f=(0,r.resolveComponent)("t"),m=(0,r.resolveDirective)("clean-html");return(0,r.openBlock)(),(0,r.createElementBlock)("div",{class:(0,r.normalizeClass)(["banner",{[e.color]:!0,"banner-disabled":e.disabled}]),role:e.role||void 0,tabindex:"alert"===e.role?-1:0},[e.icon?((0,r.openBlock)(),(0,r.createElementBlock)("div",o,[(0,r.createElementVNode)("i",{class:(0,r.normalizeClass)(["icon icon-2x",e.icon]),alt:e.t("generic.banners.bannerIcon")},null,10,a)])):(0,r.createCommentVNode)("",!0),(0,r.createElementVNode)("div",{class:(0,r.normalizeClass)(["banner__content",{closable:e.closable,stacked:e.stacked,icon:e.icon}]),"data-testid":"banner-content"},[(0,r.renderSlot)(e.$slots,"default",{},()=>[e.labelKey?((0,r.openBlock)(),(0,r.createBlock)(f,{key:0,k:e.labelKey,raw:!0},null,8,["k"])):e.messageLabel?((0,r.openBlock)(),(0,r.createElementBlock)("span",s,(0,r.toDisplayString)(e.messageLabel),1)):(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("span",l,null,512)),[[m,e.nlToBr(e.label)]])],!0),e.closable?((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:0,class:"banner__content__closer",tabindex:"0",role:"button","aria-label":e.t("generic.close"),onClick:t[0]||(t[0]=t=>e.$emit("close")),onKeyup:[t[1]||(t[1]=(0,r.withKeys)(t=>e.$emit("close"),["enter"])),t[2]||(t[2]=(0,r.withKeys)(t=>e.$emit("close"),["space"]))]},[(0,r.createElementVNode)("i",{"data-testid":"banner-close",class:"icon icon-close closer-icon",alt:e.t("generic.banners.altCloseBanner")},null,8,u)],40,c)):(0,r.createCommentVNode)("",!0)],2)],10,i)}var h=n(92043),p=n(99726),f=(0,r.defineComponent)({props:{color:{type:String,default:"secondary"},label:{type:[String,Error,Object],default:null},labelKey:{type:String,default:null},icon:{type:String,default:null},closable:{type:Boolean,default:!1},stacked:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},role:{type:String,default:null,validator:e=>["alert","status",null].includes(e)}},emits:["close"],computed:{messageLabel(){return"string"!==typeof this.label?(0,p.As)(this.label):void 0}},methods:{nlToBr:h.Kn}}),m=(n(97944),n(47433));const g=(0,m.A)(f,[["render",d],["__scopeId","data-v-1a28c7f8"]]);var v=g},71400:function(e,t,n){"use strict";n.d(t,{A:function(){return O}});var r=n(9274);const i=["id","checked","value"],o=["tabindex","aria-disabled","aria-label","aria-checked","aria-labelledby","aria-describedby"],a=["id"],s=["id"],l={key:0,class:"checkbox-outer-container-description"},c=["id"],u={key:1,class:"checkbox-outer-container-extra"};function d(e,t,n,d,h,p){const f=(0,r.resolveComponent)("t"),m=(0,r.resolveComponent)("rc-icon-tooltip");return(0,r.openBlock)(),(0,r.createElementBlock)("div",{class:(0,r.normalizeClass)(["checkbox-outer-container",{"has-clean-tooltip":e.hasTooltip}]),"data-checkbox-ctrl":""},[(0,r.createElementVNode)("label",{class:(0,r.normalizeClass)(["checkbox-container",{disabled:e.isDisabled}]),onKeydown:[t[5]||(t[5]=(0,r.withKeys)((0,r.withModifiers)(t=>e.clicked(t),["prevent"]),["enter"])),t[6]||(t[6]=(0,r.withKeys)((0,r.withModifiers)(t=>e.clicked(t),["prevent"]),["space"]))],onClick:t[7]||(t[7]=t=>e.clicked(t))},[(0,r.createElementVNode)("input",{id:e.id,checked:e.isChecked,value:e.valueWhenTrue,type:"checkbox",tabindex:"-1","aria-hidden":"true",onClick:t[0]||(t[0]=(0,r.withModifiers)(()=>{},["stop","prevent"])),onKeyup:t[1]||(t[1]=(0,r.withKeys)((0,r.withModifiers)(()=>{},["stop","prevent"]),["enter"]))},null,40,i),(0,r.createElementVNode)("span",{ref:"checkbox",class:(0,r.normalizeClass)(["checkbox-custom",{indeterminate:e.indeterminate}]),tabindex:e.isDisabled?-1:0,"aria-disabled":e.isDisabled,"aria-label":e.replacementLabel,"aria-checked":!!e.value,"aria-labelledby":e.labelKey||e.label?e.idForLabel:void 0,"aria-describedby":e.ariaDescribedBy,role:"checkbox"},null,10,o),e.$slots.label||e.label||e.labelKey||e.hasTooltip?((0,r.openBlock)(),(0,r.createElementBlock)("span",{key:0,class:(0,r.normalizeClass)(["checkbox-label",{"checkbox-primary":e.primary}])},[(0,r.renderSlot)(e.$slots,"label",{},()=>[e.labelKey?((0,r.openBlock)(),(0,r.createElementBlock)("span",{key:0,id:e.idForLabel,class:(0,r.normalizeClass)({"body-text-color":e.useBodyTextColor})},[(0,r.createVNode)(f,{k:e.labelKey,raw:!0},null,8,["k"])],10,a)):e.label?((0,r.openBlock)(),(0,r.createElementBlock)("span",{key:1,id:e.idForLabel,class:(0,r.normalizeClass)({"body-text-color":e.useBodyTextColor})},(0,r.toDisplayString)(e.label),11,s)):(0,r.createCommentVNode)("",!0),e.hasTooltip?((0,r.openBlock)(),(0,r.createBlock)(m,{key:2,content:e.tooltipKey?e.t(e.tooltipKey):e.tooltip,class:"checkbox-info","data-testid":e.componentTestid+"-info-icon",tabindex:e.isDisabled?-1:0,onClick:t[2]||(t[2]=(0,r.withModifiers)(()=>{},["stop","prevent"])),onKeydown:[t[3]||(t[3]=(0,r.withKeys)((0,r.withModifiers)(()=>{},["stop"]),["enter"])),t[4]||(t[4]=(0,r.withKeys)((0,r.withModifiers)(()=>{},["stop"]),["space"]))]},null,8,["content","data-testid","tabindex"])):(0,r.createCommentVNode)("",!0)],!0)],2)):(0,r.createCommentVNode)("",!0)],34),e.descriptionKey||e.description?((0,r.openBlock)(),(0,r.createElementBlock)("div",l,[e.descriptionKey?((0,r.openBlock)(),(0,r.createBlock)(f,{key:0,id:e.describedById,k:e.descriptionKey},null,8,["id","k"])):e.description?((0,r.openBlock)(),(0,r.createElementBlock)("p",{key:1,id:e.describedById},(0,r.toDisplayString)(e.description),9,c)):(0,r.createCommentVNode)("",!0)])):(0,r.createCommentVNode)("",!0),e.$slots.extra?((0,r.openBlock)(),(0,r.createElementBlock)("div",u,[(0,r.renderSlot)(e.$slots,"extra",{},void 0,!0)])):(0,r.createCommentVNode)("",!0)],2)}var h=n(14220),p=n(68851),f=n(46108),m=n.n(f),g=n(92043),v=n(82110),b=(0,r.defineComponent)({name:"Checkbox",components:{RcIconTooltip:v.S},props:{value:{type:[Boolean,Array,String],default:!1},label:{type:String,default:null},labelKey:{type:String,default:null},id:{type:String,default:(0,g.aR)(12)},disabled:{type:Boolean,default:!1},indeterminate:{type:Boolean,default:!1},mode:{type:String,default:h.G5},tooltip:{type:[String,Object],default:null},tooltipKey:{type:String,default:null},valueWhenTrue:{type:[Boolean,String,Number],default:!0},descriptionKey:{type:String,default:null},description:{type:String,default:null},primary:{type:Boolean,default:!1},alternateLabel:{type:String,default:void 0},useBodyTextColor:{type:Boolean,default:!1},componentTestid:{type:String,default:"checkbox"}},emits:["update:value"],data(){return{describedById:`described-by-${(0,g.aR)(12)}`}},computed:{ariaDescribedBy(){const e=this.$attrs["aria-describedby"],t=this.descriptionKey||this.description?this.describedById:void 0;return e&&t?`${e} ${t}`:e||t?`${e||t}`:void 0},isDisabled(){return this.disabled||this.mode===h.nW},isChecked(){return this.isMulti(this.value)?this.findTrueValues(this.value):this.value===this.valueWhenTrue},hasTooltip(){return!!this.tooltip||!!this.tooltipKey},replacementLabel(){if(!this.label&&!this.labelKey&&this.alternateLabel)return this.alternateLabel},idForLabel(){return`${(0,g.aR)(12)}-checkbox-label`}},methods:{clicked(e){if("A"===e.target.tagName&&e.target.href)return!0;if(e.stopPropagation(),e.preventDefault(),this.isDisabled)return;const t={bubbles:!0,cancelable:!1,shiftKey:e.shiftKey,altKey:e.altKey,ctrlKey:e.ctrlKey,metaKey:e.metaKey},n=new CustomEvent("click",t),r=m()(this.value);this.isMulti(r)?(this.isChecked?(0,p.Gj)(r,this.valueWhenTrue):(0,p.PG)(r,this.valueWhenTrue),this.$emit("update:value",r)):this.isString(this.valueWhenTrue)?this.isChecked?this.$emit("update:value",null):this.$emit("update:value",this.valueWhenTrue):(this.$emit("update:value",!r),this.$el.dispatchEvent(n))},isMulti(e){return Array.isArray(e)},isString(e){return"string"===typeof e},findTrueValues(e){return e.find(e=>e===this.valueWhenTrue)||!1},focus(){var e;this.isDisabled||null===(e=this.$refs.checkbox)||void 0===e||e.focus()}}}),y=(n(23415),n(47433));const w=(0,y.A)(b,[["render",d],["__scopeId","data-v-688406d2"]]);var O=w},81548:function(e,t,n){"use strict";n.d(t,{A:function(){return k}});var r=n(9274);const i=["for"],o={key:2,class:"required","aria-hidden":!0},a=["id","name","maxlength","disabled","aria-disabled","type","inputmode","value","placeholder","data-lpignore","aria-describedby","aria-required"],s={key:3,class:"sub-label","data-testid":"sub-label"},l=["id","aria-label"],c=["id"];function u(e,t,n,u,d,h){const p=(0,r.resolveComponent)("t"),f=(0,r.resolveComponent)("TextAreaAutoGrow"),m=(0,r.resolveComponent)("RcButton"),g=(0,r.resolveComponent)("LabeledTooltip"),v=(0,r.resolveDirective)("stripped-aria-label"),b=(0,r.resolveDirective)("clean-html");return(0,r.openBlock)(),(0,r.createElementBlock)("div",{class:(0,r.normalizeClass)({"labeled-input":!0,focused:e.focused,[e.mode]:!0,disabled:e.isDisabled,[e.effectiveStatus]:e.effectiveStatus,suffix:e.hasSuffix,"has-clean-tooltip":e.hasTooltip,"compact-input":e.isCompact,hideArrows:e.hideArrows,[e.className]:!0})},[(0,r.renderSlot)(e.$slots,"label",{},()=>[e.hasLabel?((0,r.openBlock)(),(0,r.createElementBlock)("label",{key:0,for:e.inputId},[e.labelKey?((0,r.openBlock)(),(0,r.createBlock)(p,{key:0,k:e.labelKey},null,8,["k"])):e.label?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:1},[(0,r.createTextVNode)((0,r.toDisplayString)(e.label),1)],64)):(0,r.createCommentVNode)("",!0),e.requiredField?((0,r.openBlock)(),(0,r.createElementBlock)("span",o,"*")):(0,r.createCommentVNode)("",!0)],8,i)):(0,r.createCommentVNode)("",!0)],!0),(0,r.renderSlot)(e.$slots,"prefix",{},void 0,!0),(0,r.renderSlot)(e.$slots,"field",{},()=>["multiline"===e.type||"multiline-password"===e.type?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createBlock)(f,(0,r.mergeProps)({key:0,id:e.inputId,ref:"value"},e.$attrs,{name:e.name||void 0,maxlength:e._maxlength,disabled:e.isDisabled,"aria-disabled":e.isDisabled,value:e.value||"",placeholder:e._placeholder,autocapitalize:"off",class:{"multiline-password":"multiline-password"===e.type,"auto-grow-labeled":e.hasLabel},"aria-describedby":e.ariaDescribedBy,"aria-required":e.requiredField,"onUpdate:value":e.onInput,onFocus:e.onFocus,onBlur:e.onBlur}),null,16,["id","name","maxlength","disabled","aria-disabled","value","placeholder","class","aria-describedby","aria-required","onUpdate:value","onFocus","onBlur"])),[[v,e.strippedAriaLabel]]):(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("input",(0,r.mergeProps)({key:1,id:e.inputId,ref:"value",class:{"no-label":!e.hasLabel}},e.$attrs,{name:e.name||void 0,maxlength:e._maxlength,disabled:e.isDisabled,"aria-disabled":e.isDisabled,type:e.nativeType,inputmode:e.inputMode,value:e.value,placeholder:e._placeholder,autocomplete:"off",autocapitalize:"off","data-lpignore":e.ignorePasswordManagers,"aria-describedby":e.ariaDescribedBy,"aria-required":e.requiredField,onInput:t[0]||(t[0]=(...t)=>e.onInput&&e.onInput(...t)),onKeydown:t[1]||(t[1]=(...t)=>e.onKeydown&&e.onKeydown(...t)),onPaste:t[2]||(t[2]=(...t)=>e.onPaste&&e.onPaste(...t)),onFocus:t[3]||(t[3]=(...t)=>e.onFocus&&e.onFocus(...t)),onBlur:t[4]||(t[4]=(...t)=>e.onBlur&&e.onBlur(...t)),onChange:t[5]||(t[5]=(...t)=>e.onChange&&e.onChange(...t))}),null,16,a)),[[v,e.strippedAriaLabel]])],!0),(0,r.renderSlot)(e.$slots,"suffix",{},void 0,!0),e.shouldShowClearButton?((0,r.openBlock)(),(0,r.createBlock)(m,{key:0,type:"button",size:"small",variant:"ghost","left-icon":"close",class:"labeled-input-clear-button","aria-label":e.clearButtonAriaLabel,disabled:e.isDisabled,onClick:e.clearInput,onKeydown:[(0,r.withKeys)((0,r.withModifiers)(e.clearInput,["prevent"]),["enter"]),(0,r.withKeys)((0,r.withModifiers)(e.clearInput,["prevent"]),["space"])]},null,8,["aria-label","disabled","onClick","onKeydown"])):(0,r.createCommentVNode)("",!0),e.hasTooltip?((0,r.openBlock)(),(0,r.createBlock)(g,{key:1,hover:e.hoverTooltip,value:e.tooltipValue,status:e.status},null,8,["hover","value","status"])):(0,r.createCommentVNode)("",!0),e.validationMessage?((0,r.openBlock)(),(0,r.createBlock)(g,{key:2,hover:e.hoverTooltip,value:e.validationMessage},null,8,["hover","value"])):(0,r.createCommentVNode)("",!0),e.cronHint||e.subLabel?((0,r.openBlock)(),(0,r.createElementBlock)("div",s,[e.cronHint?((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:0,id:e.describedById,role:"alert","aria-label":e.cronHint},(0,r.toDisplayString)(e.cronHint),9,l)):e.subLabel?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:1,id:e.describedById},null,8,c)),[[b,e.subLabel]]):(0,r.createCommentVNode)("",!0)])):(0,r.createCommentVNode)("",!0)],2)}var d=n(55673),h=n(40811),p=n(71126),f=n(92043),m=n(37021),g=n.n(m),v=n(3369),b=n(45250),y=n(2117);const w=e=>{const t=(0,r.computed)(()=>null!==e.compact&&void 0!==e.compact?!!e.compact:!(e.label||e.labelKey));return{isCompact:t}};var O=n(16824);const S={onInput(){}};var E=(0,r.defineComponent)({components:{LabeledTooltip:h.A,RcButton:p.A,TextAreaAutoGrow:d.A},inheritAttrs:!1,props:{...y.K,type:{type:String,default:"text"},status:{type:String,default:null},subLabel:{type:String,default:null},tooltip:{default:null,type:[String,Object]},hoverTooltip:{type:Boolean,default:!0},ignorePasswordManagers:{default:!1,type:Boolean},maxlength:{type:Number,default:null},hideArrows:{type:Boolean,default:!1},delay:{type:Number,default:0},class:{type:String,default:""},overrideAriaLabel:{type:Boolean,default:!1},ariaLabel:{type:String,default:""},name:{type:String,default:null},showClearButton:{type:Boolean,default:void 0},clearButtonLabel:{type:String,default:void 0}},emits:["change","update:value","blur","update:validation"],setup(e,{emit:t}){const{focused:n,onFocusLabeled:i,onBlurLabeled:o,isDisabled:a,validationMessage:s,requiredField:l}=(0,y.x)(e,t),{isCompact:c}=w(e),u=(0,r.inject)("onInput",S.onInput),{effectiveValidationMessage:d,veeHandleBlur:h,veeValidate:p}=(0,O.U)({name:(0,r.toRef)(e,"name"),rules:(0,r.toRef)(e,"rules"),value:(0,r.toRef)(e,"value"),validationMessage:s}),f=(0,r.computed)(()=>e.status),m=(0,r.computed)(()=>"integer"===e.type),g=(0,r.computed)(()=>"cron"===e.type||"integer"===e.type?"text":e.type),v=(0,r.computed)(()=>m.value?"numeric":void 0),b=(0,r.computed)(()=>void 0!==e.showClearButton?e.showClearButton&&!!e.value:"search"===e.type&&!!e.value);return{focused:n,onFocusLabeled:i,onBlurLabeled:o,onInput:u,isDisabled:a,validationMessage:d,requiredField:l,isCompact:c,veeHandleBlur:h,veeValidate:p,effectiveStatus:f,isInteger:m,nativeType:g,inputMode:v,shouldShowClearButton:b}},data(){return{updated:!1,validationErrors:"",inputId:`input-${(0,f.aR)(12)}`,describedById:`described-by-${(0,f.aR)(12)}`}},computed:{strippedAriaLabel(){return this.overrideAriaLabel?this.ariaLabel||void 0:!this.hasLabel&&this.ariaLabel?this.ariaLabel:void 0},hasLabel(){return!this.isCompact&&(!!this.label||!!this.labelKey||!!this.$slots.label)},ariaDescribedBy(){const e=this.$attrs["aria-describedby"],t=this.cronHint||this.subLabel?this.describedById:void 0;return e&&t?`${e} ${t}`:e||t?`${e||t}`:void 0},hasTooltip(){return!!this.tooltip||!!this.tooltipKey},tooltipValue(){if(this.hasTooltip)return this.tooltipKey?this.t(this.tooltipKey):this.tooltip},hasSuffix(){return!!this.$slots.suffix},clearButtonAriaLabel(){return this.clearButtonLabel||this.t("generic.clear")},cronHint(){if("cron"!==this.type||!this.value)return;const e=["@yearly","@annually","@monthly","@weekly","@daily","@midnight","@hourly"],t=e.includes(this.value);if(!t&&!(0,v.isValidCron)(this.value,{alias:!0,allowBlankDay:!0,allowSevenAsSunday:!0}))return this.t("generic.invalidCron");try{const e=g().toString(this.value||"",{verbose:!0});return e}catch(n){return this.t("generic.invalidCron")}},_placeholder(){return this.placeholder?this.placeholder.toString():this.placeholderKey?this.t(this.placeholderKey):""},_maxlength(){if("text"===this.type&&this.maxlength)return this.maxlength},className(){return this.class}},mounted(){var e;const t=null===(e=this.$attrs)||void 0===e?void 0:e.id;t&&(this.inputId=t)},created(){this.onInput=this.delay?(0,b.debounce)(this.delayInput,this.delay):this.delayInput},methods:{focus(){const e=this.$refs.value;e&&e.focus()},select(){const e=this.$refs.value;e&&e.select()},isValidIntegerInput(e){const t=/^-?[0-9]*$/,n=/^[0-9]*$/,r=Number(this.$attrs.min)>=0?n:t;if(!r.test(e))return!1;const i=Number(e);return!(""!==e&&"-"!==e&&!Number.isSafeInteger(i))},prospectiveValue(e,t){var n,r;const i=null!==(n=e.selectionStart)&&void 0!==n?n:0,o=null!==(r=e.selectionEnd)&&void 0!==r?r:0;return e.value.slice(0,i)+t+e.value.slice(o)},onKeydown(e){if(!this.isInteger||1!==e.key.length||e.ctrlKey||e.metaKey)return;const t=this.prospectiveValue(e.target,e.key);this.isValidIntegerInput(t)||e.preventDefault()},onPaste(e){var t,n;if(!this.isInteger)return;const r=null!==(n=null===(t=e.clipboardData)||void 0===t?void 0:t.getData("text/plain"))&&void 0!==n?n:"",i=this.prospectiveValue(e.target,r);this.isValidIntegerInput(i)||e.preventDefault()},onChange(e){this.$emit("change",e)},delayInput(e){var t;const n="string"===typeof e?e:null===(t=null===e||void 0===e?void 0:e.target)||void 0===t?void 0:t.value;this.$emit("update:value",n)},onFocus(){this.onFocusLabeled()},onBlur(e){this.$emit("blur",e),this.onBlurLabeled(),this.veeHandleBlur(e instanceof FocusEvent?e:void 0,!1),this.veeValidate()},clearInput(){this.$emit("update:value",""),this.$nextTick(()=>{this.focus()})},escapeHtml:f.ZD}}),x=(n(94532),n(91460),n(47433));const _=(0,x.A)(E,[["render",u],["__scopeId","data-v-3a63eca7"]]);var k=_},10096:function(e,t,n){"use strict";n.d(t,{A:function(){return v}});var r=n(9274);const i=["id","disabled","name","value","data-testid","checked"],o=["id","tabindex","aria-label","aria-checked","aria-disabled","aria-describedby"],a={class:"labeling"},s=["for"],l={key:1},c=["id"],u={key:1,class:"radio-button-outer-container-description"};function d(e,t,n,d,h,p){const f=(0,r.resolveComponent)("t"),m=(0,r.resolveDirective)("clean-html");return(0,r.openBlock)(),(0,r.createElementBlock)("label",{class:(0,r.normalizeClass)({disabled:e.isDisabled,"radio-container":!0,"radio-button-checked":e.isChecked}),onKeydown:[t[1]||(t[1]=(0,r.withKeys)(t=>e.clicked(t),["enter"])),t[2]||(t[2]=(0,r.withKeys)(t=>e.clicked(t),["space"]))],onClick:t[3]||(t[3]=(0,r.withModifiers)(t=>e.clicked(t),["stop"]))},[(0,r.createElementVNode)("input",{id:e.randomString,disabled:e.isDisabled,name:e.name,value:""+e.val,"data-testid":e.label,checked:e.isChecked,type:"radio",tabindex:-1,onClick:t[0]||(t[0]=(0,r.withModifiers)(()=>{},["stop","prevent"]))},null,8,i),(0,r.createElementVNode)("span",{id:e.radioOptionId,ref:"custom",class:(0,r.normalizeClass)([e.isDisabled?"text-muted":"","radio-custom"]),tabindex:e.isDisabled||e.preventFocusOnRadioGroups?-1:0,"aria-label":e.label,"aria-checked":e.isChecked,"aria-disabled":e.isDisabled,"aria-describedby":e.descriptionKey||e.description?e.describeById:void 0,role:"radio"},null,10,o),(0,r.createElementVNode)("div",a,[(0,r.createElementVNode)("label",{class:(0,r.normalizeClass)(["radio-label m-0",{"text-muted":e.muteLabel,"body-text-color":e.useBodyTextColor}]),for:e.name},[e.hasLabelSlot?(0,r.renderSlot)(e.$slots,"label",{},void 0,!0,0):e.label?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("span",l,null,512)),[[m,e.label]]):(0,r.createCommentVNode)("",!0)],10,s),e.descriptionKey||e.description?((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:0,id:e.describeById,class:"radio-button-outer-container-description"},[e.descriptionKey?((0,r.openBlock)(),(0,r.createBlock)(f,{key:0,k:e.descriptionKey},null,8,["k"])):e.description?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:1},[(0,r.createTextVNode)((0,r.toDisplayString)(e.description),1)],64)):(0,r.createCommentVNode)("",!0)],8,c)):e.hasDescriptionSlot?((0,r.openBlock)(),(0,r.createElementBlock)("div",u,[(0,r.renderSlot)(e.$slots,"description",{},void 0,!0)])):(0,r.createCommentVNode)("",!0)])],34)}var h=n(14220),p=n(92043),f=(0,r.defineComponent)({inheritAttrs:!1,props:{name:{type:String,default:""},val:{required:!0,validator:()=>!0},value:{required:!0,validator:()=>!0},label:{type:String,default:""},disabled:{type:Boolean,default:!1},mode:{type:String,default:"edit"},descriptionKey:{type:String,default:null},description:{type:String,default:null},preventFocusOnRadioGroups:{type:Boolean,default:!1},useBodyTextColor:{type:Boolean,default:!1},radioOptionId:{type:String,default:void 0}},emits:["update:value"],data(){return{isChecked:this.value===this.val,randomString:`${(0,p.aR)(12)}-radio`,describeById:`${(0,p.aR)(12)}-radio-described-id`}},computed:{isDisabled(){return this.mode===h.nW||this.disabled},muteLabel(){return this.disabled&&!(this.mode===h.nW&&this.isChecked)},hasDescriptionSlot(){return!!this.$slots.description},hasLabelSlot(){return!!this.$slots.label}},watch:{value(e){this.isChecked=this.val===e,this.isChecked&&!this.preventFocusOnRadioGroups&&this.$refs.custom.focus()}},methods:{clicked(e){const t=e.target;this.isDisabled||t instanceof HTMLElement&&"A"===t.tagName||this.$emit("update:value",this.val)}}}),m=(n(54782),n(47433));const g=(0,m.A)(f,[["render",d],["__scopeId","data-v-36919aac"]]);var v=g},96531:function(e,t,n){"use strict";n.d(t,{A:function(){return m}});var r=n(9274);const i={key:0,class:"radio-group label"},o={key:2,class:"icon icon-info icon-lg"},a={key:3,class:"icon icon-info icon-lg"},s=["aria-label","aria-describedby","aria-activedescendant","tabindex","aria-disabled"];function l(e,t,n,l,c,u){const d=(0,r.resolveComponent)("t"),h=(0,r.resolveComponent)("RadioButton"),p=(0,r.resolveDirective)("clean-tooltip");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[e.label||e.labelKey||e.tooltip||e.tooltipKey||e.$slots.label?((0,r.openBlock)(),(0,r.createElementBlock)("div",i,[(0,r.renderSlot)(e.$slots,"label",{},()=>[(0,r.createElementVNode)("h3",null,[e.labelKey?((0,r.openBlock)(),(0,r.createBlock)(d,{key:0,k:e.labelKey},null,8,["k"])):e.label?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:1},[(0,r.createTextVNode)((0,r.toDisplayString)(e.label),1)],64)):(0,r.createCommentVNode)("",!0),e.tooltipKey?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("i",o,null,512)),[[p,e.t(e.tooltipKey)]]):e.tooltip?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("i",a,null,512)),[[p,e.tooltip]]):(0,r.createCommentVNode)("",!0)])],!0)])):(0,r.createCommentVNode)("",!0),(0,r.createElementVNode)("div",{ref:"radioGroup",role:"radiogroup","aria-label":e.radioGroupAriaLabel,"aria-describedby":e.radioGroupAriaDescribedBy,"aria-activedescendant":e.ariaActiveDescendant,class:(0,r.normalizeClass)(["radio-group",{row:e.row}]),tabindex:e.isDisabled?-1:0,"aria-disabled":e.isDisabled,onKeydown:[t[1]||(t[1]=(0,r.withKeys)((0,r.withModifiers)(t=>e.clickNext(1),["prevent","stop"]),["down"])),t[2]||(t[2]=(0,r.withKeys)((0,r.withModifiers)(t=>e.clickNext(-1),["prevent","stop"]),["up"])),t[3]||(t[3]=(0,r.withKeys)((0,r.withModifiers)(()=>{},["stop","prevent"]),["space","enter"]))]},[((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(e.normalizedOptions,(n,i)=>((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:i},[(0,r.renderSlot)(e.$slots,i,{vBind:e.$attrs,option:n,isDisabled:e.isDisabled},()=>[(0,r.createVNode)(h,{name:e.name,value:e.value,label:n.label,"radio-option-id":n.radioOptionId,description:n.description,val:n.value,disabled:e.isDisabled,"data-testid":`radio-button-${i}`,mode:e.mode,"use-body-text-color":e.useBodyTextColor,"prevent-focus-on-radio-groups":!0,"onUpdate:value":t[0]||(t[0]=t=>e.$emit("update:value",t))},null,8,["name","value","label","radio-option-id","description","val","disabled","data-testid","mode","use-body-text-color"])],!0)]))),128))],42,s)])}var c=n(14220),u=n(10096),d=n(92043),h=(0,r.defineComponent)({name:"RadioGroup",components:{RadioButton:u.A},props:{name:{type:String,required:!0},options:{type:Array,required:!0},labels:{type:Array,default:null},value:{type:[Boolean,String,Object],default:null},disabled:{type:Boolean,default:!1},mode:{type:String,default:"edit"},label:{type:String,default:null},labelKey:{type:String,default:null},tooltip:{type:[String,Object],default:null},tooltipKey:{type:String,default:null},row:{type:Boolean,default:!1},useBodyTextColor:{type:Boolean,default:!1}},emits:["update:value"],data(){return{currFocusedElem:void 0,radioOptionsIdPrefix:`radio-option-${(0,d.aR)(12)}-`}},computed:{normalizedOptions(){const e=[];for(let t=0;t<this.options.length;t++){const n=this.options[t];"object"===typeof n&&n?e.push({...n,radioOptionId:`${this.radioOptionsIdPrefix}${t}`}):this.labels?e.push({label:this.labels[t],value:n,radioOptionId:`${this.radioOptionsIdPrefix}${t}`}):e.push({label:n,value:n,radioOptionId:`${this.radioOptionsIdPrefix}${t}`})}return e},isView(){return this.mode===c.nW},isDisabled(){return this.disabled||this.isView},radioGroupAriaLabel(){return this.$attrs["aria-label"]?this.$attrs["aria-label"]||void 0:this.labelKey?this.t(this.labelKey):this.label?this.label:void 0},radioGroupAriaDescribedBy(){return this.$attrs["aria-describedby"]||void 0},ariaActiveDescendant(){const e=this.normalizedOptions.find(e=>e.value===this.value);return this.value&&e?e.radioOptionId:""}},beforeUnmount(){var e;const t=null===(e=this.$refs)||void 0===e?void 0:e.radioGroup;t.removeEventListener("focusin",this.focusChanged)},mounted(){var e;const t=null===(e=this.$refs)||void 0===e?void 0:e.radioGroup;t.addEventListener("focusin",this.focusChanged)},methods:{focusChanged(e){this.currFocusedElem=e.target},clickNext(e){var t;if(this.currFocusedElem!==(null===(t=this.$refs)||void 0===t?void 0:t.radioGroup))return;const n=this.normalizedOptions,r=n.find(e=>e.value===this.value);let i=(r?n.indexOf(r):-1)+e;i>=n.length?i=n.length-1:i<0&&(i=0),this.$emit("update:value",n[i].value)}}}),p=(n(72214),n(47433));const f=(0,p.A)(h,[["render",l],["__scopeId","data-v-1157638b"]]);var m=f},55673:function(e,t,n){"use strict";n.d(t,{A:function(){return p}});var r=n(9274);const i=["value","data-testid","disabled","placeholder","spellcheck"];function o(e,t,n,o,a,s){return(0,r.openBlock)(),(0,r.createElementBlock)("textarea",(0,r.mergeProps)({ref:"ta",value:e.value,"data-testid":e.$attrs["data-testid"]?e.$attrs["data-testid"]:"text-area-auto-grow",disabled:e.isDisabled,style:e.style,placeholder:e.placeholder,class:[e.className,"no-resize no-ease"]},e.$attrs,{spellcheck:e.spellcheck,onPaste:t[0]||(t[0]=t=>e.$emit("paste",t)),onInput:t[1]||(t[1]=t=>e.onInput(t)),onFocus:t[2]||(t[2]=t=>e.$emit("focus",t)),onBlur:t[3]||(t[3]=t=>e.$emit("blur",t))}),null,16,i)}var a=n(45250),s=n(14220);const l={queueResize(){}},c=["boxSizing","paddingTop","paddingRight","paddingBottom","paddingLeft","borderTopWidth","borderRightWidth","borderBottomWidth","borderLeftWidth","fontFamily","fontSize","fontStyle","fontVariant","fontWeight","fontStretch","lineHeight","letterSpacing","wordSpacing","textTransform","textIndent","tabSize"];var u=(0,r.defineComponent)({inheritAttrs:!1,props:{value:{type:String,required:!0},class:{type:[String,Array,Object],default:""},mode:{type:String,default:s.G5},minHeight:{type:Number,default:25},maxHeight:{type:Number,default:200},placeholder:{type:String,default:""},spellcheck:{type:Boolean,default:!0},disabled:{type:Boolean,default:!1},resizeOnValueChangeAndResizeWindow:{type:Boolean,default:!1}},emits:["update:value","paste","focus","blur"],setup(){const e=(0,r.inject)("queueResize",l.queueResize);return{queueResize:e}},data(){return{curHeight:this.minHeight,overflow:"hidden",mirror:null}},computed:{isDisabled(){return this.disabled||this.mode===s.nW},style(){return`height: ${this.curHeight}px; overflow: ${this.overflow};`},className(){return this.class}},watch:{value(){this.resizeOnValueChangeAndResizeWindow&&this.queueResize()},$attrs:{deep:!0,handler(){this.queueResize()}}},created(){this.queueResize=(0,a.debounce)(this.autoSize,100)},mounted(){this.$refs.ta.style.height=`${this.curHeight}px`,this.$nextTick(()=>{this.autoSize()}),this.resizeOnValueChangeAndResizeWindow&&window.addEventListener("resize",this.queueResize)},beforeUnmount(){this.resizeOnValueChangeAndResizeWindow&&window.removeEventListener("resize",this.queueResize),this.mirror&&(this.mirror.remove(),this.mirror=null)},methods:{onInput(e){var t;const n=null===(t=null===e||void 0===e?void 0:e.target)||void 0===t?void 0:t.value;this.$emit("update:value",n),this.autoSize()},focus(){var e;(null===(e=this.$refs)||void 0===e?void 0:e.ta).focus()},autoSize(){const e=this.$refs.ta;if(!e)return;const t=this.measureContentHeight(e),n=Math.max(this.minHeight,Math.min(t,this.maxHeight)),r=t>this.maxHeight,i=e.scrollTop;e.style.overflowY=r?"auto":"hidden",e.style.height=`${n}px`,r&&(e.scrollTop=i),this.overflow=r?"auto":"hidden",this.curHeight=n},measureContentHeight(e){const t=getComputedStyle(e);let n=this.mirror;n||(n=document.createElement("div"),n.setAttribute("aria-hidden","true"),document.body.appendChild(n),this.mirror=n);const r=n.style;r.position="absolute",r.top="0",r.left="-9999px",r.visibility="hidden",r.pointerEvents="none",r.whiteSpace="pre-wrap",r.overflowWrap="break-word",r.width=`${e.clientWidth}px`,r.height="auto";for(const o of c)r[o]=t[o];n.textContent=`${e.value||""} `;const i=(parseInt(t.borderTopWidth,10)||0)+(parseInt(t.borderBottomWidth,10)||0);return n.scrollHeight+i}}}),d=n(47433);const h=(0,d.A)(u,[["render",o]]);var p=h},40811:function(e,t,n){"use strict";n.d(t,{A:function(){return d}});var r=n(9274);const i={key:0,class:"tooltip","x-placement":"bottom"},o={class:"tooltip-inner"};function a(e,t,n,a,s,l){const c=(0,r.resolveComponent)("rc-icon-tooltip");return(0,r.openBlock)(),(0,r.createElementBlock)("div",{ref:"container",class:(0,r.normalizeClass)(["labeled-tooltip",{[e.status]:!0,hoverable:e.hover}])},[e.hover?((0,r.openBlock)(),(0,r.createBlock)(c,{key:0,content:e.tooltipContent,label:e.iconAriaLabel,"icon-type":e.iconType,class:(0,r.normalizeClass)([{hover:!e.value},"status-icon"]),"data-testid":e.componentTestid,onClick:t[0]||(t[0]=(0,r.withModifiers)(()=>{},["stop"]))},null,8,["content","label","icon-type","class","data-testid"])):((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:1},[(0,r.createElementVNode)("i",{class:(0,r.normalizeClass)([{hover:!e.value},"icon status-icon"])},null,2),e.value?((0,r.openBlock)(),(0,r.createElementBlock)("div",i,[t[1]||(t[1]=(0,r.createElementVNode)("div",{class:"tooltip-arrow"},null,-1)),(0,r.createElementVNode)("div",o,(0,r.toDisplayString)(e.value),1)])):(0,r.createCommentVNode)("",!0)],64))],2)}var s=n(82110),l=(0,r.defineComponent)({components:{RcIconTooltip:s.S},props:{value:{type:[String,Object],default:null},status:{type:String,default:"error"},hover:{type:Boolean,default:!0},componentTestid:{type:String,default:"labeledTooltip-info-icon"}},computed:{iconType(){return"error"===this.status?"warning":"info"},iconAriaLabel(){return"error"===this.status||"warning"===this.status?this.t(`generic.${this.status}`):this.t("generic.moreInfo")},tooltipContent(){return this.isObject(this.value)?{content:this.value.content,popperClass:[`tooltip-${status}`],...this.value}:this.value||""}},methods:{isObject(e){return"object"===typeof e&&null!==e&&!!e.content}}}),c=(n(42137),n(47433));const u=(0,c.A)(l,[["render",a],["__scopeId","data-v-3ed54754"]]);var d=u},53440:function(e,t,n){"use strict";n.d(t,{A:function(){return l}});var r=n(9274),i=n(71126),o=(0,r.defineComponent)({__name:"RcTag",props:{type:{},disabled:{type:Boolean,default:!1},showClose:{type:Boolean,default:!1},closeAriaLabel:{},highlight:{type:Boolean,default:void 0}},emits:["close"],setup(e,{emit:t}){const n=e,o=t;return(e,t)=>((0,r.openBlock)(),(0,r.createElementBlock)("div",{class:(0,r.normalizeClass)(["rc-tag",{[n.type]:!0,disabled:n.disabled,highlight:n.highlight}])},[(0,r.renderSlot)(e.$slots,"default"),n.showClose?((0,r.openBlock)(),(0,r.createBlock)(i.A,{key:0,variant:"ghost","aria-label":n.closeAriaLabel,onClick:t[0]||(t[0]=e=>o("close"))},{default:(0,r.withCtx)(()=>[...t[1]||(t[1]=[(0,r.createElementVNode)("i",{class:"icon icon-close"},null,-1)])]),_:1},8,["aria-label"])):(0,r.createCommentVNode)("",!0)],2))}}),a=(n(4015),n(47433));const s=(0,a.A)(o,[["__scopeId","data-v-1eeacc78"]]);var l=s},71126:function(e,t,n){"use strict";n.d(t,{A:function(){return c}});var r=n(9274),i=n(47799),o=n(4364),a=(0,r.defineComponent)({__name:"RcButton",props:{primary:{type:Boolean},secondary:{type:Boolean},tertiary:{type:Boolean},link:{type:Boolean},multiAction:{type:Boolean},ghost:{type:Boolean},small:{type:Boolean},variant:{},size:{default:"medium"},leftIcon:{},rightIcon:{},to:{default:void 0},href:{default:void 0}},setup(e,{expose:t}){const n=[{variant:"primary",className:"variant-primary"},{variant:"secondary",className:"variant-secondary"},{variant:"tertiary",className:"variant-tertiary"},{variant:"link",className:"variant-link"},{variant:"multiAction",className:"variant-multi-action"},{variant:"ghost",className:"variant-ghost"}],a=[{size:"small",className:"btn-sm"}],s=[{size:"small",className:"btn-small"},{size:"medium",className:"btn-medium"},{size:"large",className:"btn-large"}],l=e;const c=(0,r.computed)(()=>l.to?(0,r.resolveComponent)("RouterLink"):l.href?"a":"button"),u=(0,r.computed)(()=>l.to||l.href?"link":"button"),d=(0,r.computed)(()=>l.to?{to:l.to}:l.href?{href:l.href}:{}),h=(0,r.computed)(()=>{("multiAction"===l.variant||l.multiAction)&&o.warn('[RcButton] The "multiAction" variant is deprecated and will be removed in a future version.');const e=n.find(({variant:e})=>l[e]);if(e)return o.warn(`[RcButton] The "${e.variant}" prop is deprecated and will be removed in a future version. Please use variant="${e.variant}" instead.`),e.className;{const e=n.find(({variant:e})=>e===l.variant);return(null===e||void 0===e?void 0:e.className)||"variant-primary"}}),p=(0,r.computed)(()=>{const e=a.find(({size:e})=>l[e]);if(e)return o.warn(`[RcButton] The "${e.size}" prop is deprecated and will be removed in a future version. Please use size="${e.size}" instead.`),e.className;{const e=s.find(({size:e})=>e===l.size);return(null===e||void 0===e?void 0:e.className)||""}}),f=(0,r.computed)(()=>({"rc-button":!0,btn:!0,[h.value]:!0,[p.value]:!!p.value})),m=(0,r.ref)(null),g=()=>{var e;null===(e=null===m||void 0===m?void 0:m.value)||void 0===e||e.focus()},v=e=>{"button"!==c.value&&e.preventDefault()},b=e=>{"button"!==c.value&&e.target.click()};return t({focus:g}),(e,t)=>((0,r.openBlock)(),(0,r.createBlock)((0,r.resolveDynamicComponent)(c.value),(0,r.mergeProps)({ref_key:"RcFocusTarget",ref:m,role:u.value},d.value,{class:{...f.value},onKeydown:(0,r.withKeys)(v,["space"]),onKeyup:(0,r.withKeys)(b,["space"])}),{default:(0,r.withCtx)(()=>[e.$slots.before||l.leftIcon?(0,r.renderSlot)(e.$slots,"before",{},()=>[l.leftIcon?((0,r.openBlock)(),(0,r.createBlock)(i.A,{key:0,class:"left-icon",type:l.leftIcon,size:"inherit"},null,8,["type"])):(0,r.createCommentVNode)("",!0)],void 0,0):(0,r.createCommentVNode)("",!0),(0,r.renderSlot)(e.$slots,"default"),e.$slots.after||l.rightIcon?(0,r.renderSlot)(e.$slots,"after",{},()=>[l.rightIcon?((0,r.openBlock)(),(0,r.createBlock)(i.A,{key:0,class:"right-icon",type:l.rightIcon,size:"inherit"},null,8,["type"])):(0,r.createCommentVNode)("",!0)],void 0,1):(0,r.createCommentVNode)("",!0)]),_:3},16,["role","class"]))}}),s=(n(75148),n(47433));const l=(0,s.A)(a,[["__scopeId","data-v-7a42fdd6"]]);var c=l},48989:function(e,t,n){"use strict";n.d(t,{A:function(){return s}});var r=n(9274),i=(0,r.defineComponent)({__name:"RcHeading",props:{size:{}},setup(e){return(t,n)=>((0,r.openBlock)(),(0,r.createElementBlock)("div",{class:(0,r.normalizeClass)(`size-${e.size}`)},[(0,r.renderSlot)(t.$slots,"default")],2))}}),o=(n(91319),n(47433));const a=(0,o.A)(i,[["__scopeId","data-v-49193dc2"]]);var s=a},47799:function(e,t,n){"use strict";n.d(t,{A:function(){return d}});var r=n(9274);const i={actions:"icon-actions",ai:"icon-ai","alert-alt":"icon-alert-alt",alert:"icon-alert",anchor:"icon-anchor",apple:"icon-apple",application:"icon-application",apps:"icon-apps",archive:"icon-archive","backup-restore":"icon-backup-restore",backup:"icon-backup","brush-icon":"icon-brush-icon","category-alt":"icon-category-alt",checkmark:"icon-checkmark","chevron-beginning":"icon-chevron-beginning","chevron-down":"icon-chevron-down","chevron-end":"icon-chevron-end","chevron-left":"icon-chevron-left","chevron-right":"icon-chevron-right","chevron-up":"icon-chevron-up","circle-plus":"icon-circle-plus",cis:"icon-cis",close:"icon-close","cluster-management":"icon-cluster-management",cluster:"icon-cluster",code:"icon-code",comment:"icon-comment",commit:"icon-commit",compass:"icon-compass","confirmation-alt":"icon-confirmation-alt",copy:"icon-copy",dashboard:"icon-dashboard",dock:"icon-dock",docker:"icon-docker",document:"icon-document","dot-half":"icon-dot-half","dot-open":"icon-dot-open",dot:"icon-dot","downgrade-alt":"icon-downgrade-alt",download:"icon-download",edit:"icon-edit",elemental:"icon-elemental",endpoints_connected:"icon-endpoints_connected",endpoints_disconnected:"icon-endpoints_disconnected",epinio:"icon-epinio",error:"icon-error",explore:"icon-explore",extension:"icon-extension","external-link":"icon-external-link",file:"icon-file",filter_alt:"icon-filter_alt",flask:"icon-flask",fleet:"icon-fleet",folder:"icon-folder",fork:"icon-fork",gatekeeper:"icon-gatekeeper",gear:"icon-gear",gemini:"icon-gemini",git:"icon-git",github:"icon-github",gitlab:"icon-gitlab",globe:"icon-globe",groups:"icon-groups",harvester:"icon-harvester",helm:"icon-helm",hide:"icon-hide",history:"icon-history",home:"icon-home","info-circle":"icon-info-circle",info:"icon-info",init_container:"icon-init_container",istio:"icon-istio",keyboard:"icon-keyboard",keyboard_tab:"icon-keyboard_tab",linux:"icon-linux","list-flat":"icon-list-flat","list-grouped":"icon-list-grouped",lock:"icon-lock",logging:"icon-logging",longhorn:"icon-longhorn",marketplace:"icon-marketplace",menu:"icon-menu",minus:"icon-minus",monitoring:"icon-monitoring",more:"icon-more",namespace:"icon-namespace",notifier:"icon-notifier","notify-announcement":"icon-notify-announcement","notify-bell":"icon-notify-bell","notify-busy":"icon-notify-busy","notify-error":"icon-notify-error","notify-info":"icon-notify-info","notify-tick":"icon-notify-tick","notify-warning":"icon-notify-warning",ollama:"icon-ollama",openai:"icon-openai","os-management":"icon-os-management",pause:"icon-pause","pin-outlined":"icon-pin-outlined",pin:"icon-pin",pipeline:"icon-pipeline",play:"icon-play",plus:"icon-plus",pod_security:"icon-pod_security",print:"icon-print","question-mark":"icon-question-mark","quick-action":"icon-quick-action","rancher-desktop":"icon-rancher-desktop","rancher-observability":"icon-rancher-observability","refresh-alt":"icon-refresh-alt",refresh:"icon-refresh","repository-alt":"icon-repository-alt",repository:"icon-repository",rio:"icon-rio","role-binding":"icon-role-binding",search:"icon-search",send:"icon-send",service:"icon-service",show:"icon-show",snapshot:"icon-snapshot","sort-down":"icon-sort-down","sort-up":"icon-sort-up",sort:"icon-sort",sources:"icon-sources",spinner:"icon-spinner",stackstate:"icon-stackstate","star-open":"icon-star-open",star:"icon-star",storage:"icon-storage","tag-alt":"icon-tag-alt",terminal:"icon-terminal","thinking-process":"icon-thinking-process",trash:"icon-trash",unlock:"icon-unlock","upgrade-alt":"icon-upgrade-alt",upload:"icon-upload","user-check":"icon-user-check","user-xmark":"icon-user-xmark",user:"icon-user","version-alt":"icon-version-alt",warning:"icon-warning",windows:"icon-windows"},o={xxlarge:"40px",xlarge:"32px",large:"24px",medium:"16px",small:"14px",inherit:"inherit"};var a=n(28533);const s=["aria-hidden"];var l=(0,r.defineComponent)({__name:"RcIcon",props:{type:{},size:{default:"small"},ariaHidden:{type:Boolean,default:!0},status:{default:"inherit"}},setup(e){(0,r.useCssVars)(e=>({v4e6c3731:n.value,v17bbae7c:d.value}));const t=e,n=(0,r.computed)(()=>o[t.size]),l=(0,r.computed)(()=>i[t.type]),c=(0,r.computed)(()=>t.status&&"inherit"!==t.status?t.status:"none"),{textColor:u}=(0,a.WZ)(c,"outlined"),d=(0,r.computed)(()=>void 0===t.status||"inherit"===t.status?"inherit":u.value);return(e,n)=>((0,r.openBlock)(),(0,r.createElementBlock)("i",{class:(0,r.normalizeClass)(["rc-icon",{[t.size]:!0,[l.value]:!0}]),"aria-hidden":t.ariaHidden},null,10,s))}}),c=(n(47497),n(47433));const u=(0,c.A)(l,[["__scopeId","data-v-2624fc9a"]]);var d=u},30342:function(e,t,n){"use strict";n.d(t,{A:function(){return l}});var r=n(9274);const i=["role","aria-orientation"];var o=(0,r.defineComponent)({__name:"RcSeparator",props:{decorative:{type:Boolean,default:!0},orientation:{default:"horizontal"}},setup(e){const t=e,n=(0,r.computed)(()=>t.decorative?"none":"separator"),o=(0,r.computed)(()=>t.decorative?void 0:t.orientation);return(e,a)=>((0,r.openBlock)(),(0,r.createElementBlock)("hr",{role:n.value,"aria-orientation":o.value,class:(0,r.normalizeClass)({vertical:"vertical"===t.orientation})},null,10,i))}}),a=(n(9888),n(47433));const s=(0,a.A)(o,[["__scopeId","data-v-44167622"]]);var l=s},17252:function(e,t,n){"use strict";n.d(t,{A:function(){return f}});var r=n(9274);const i={class:"mb-5"},o={class:"mb-5"},a=["href"];function s(e,t,n,s,l,c){const u=(0,r.resolveComponent)("Banner"),d=(0,r.resolveDirective)("clean-html");return(0,r.openBlock)(),(0,r.createElementBlock)("div",null,[(0,r.createVNode)(u,{color:"warning"},{default:(0,r.withCtx)(()=>[(0,r.createElementVNode)("div",null,[(0,r.createElementVNode)("strong",null,(0,r.toDisplayString)(e.t("harvester.upgradePage.upgradeInfo.warning"))+":",1),(0,r.withDirectives)((0,r.createElementVNode)("p",i,null,512),[[d,e.t("harvester.upgradePage.upgradeInfo.doc",{url:c.upgradeLink},!0)]]),(0,r.createElementVNode)("p",o,(0,r.toDisplayString)(e.t("harvester.upgradePage.upgradeInfo.tip")),1),(0,r.createElementVNode)("p",null,[(0,r.createTextVNode)((0,r.toDisplayString)(e.t("harvester.upgradePage.upgradeInfo.moreNotes"))+" ",1),(0,r.createElementVNode)("a",{href:c.releaseVersion,target:"_blank"},(0,r.toDisplayString)(e.t("generic.moreInfo")),9,a)])])]),_:1})])}var l=n(9980),c=n(66242),u=n(3791),d={name:"HarvesterUpgradeInfo",components:{Banner:l.l},props:{version:{type:String,default:""}},computed:{releaseVersion(){return this.version?`https://github.com/harvester/harvester/releases/tag/${this.version}`:"https://github.com/harvester/harvester/releases"},upgradeLink(){const e=this.$store.getters["harvester-common/getServerVersion"]();return(0,u.nn)(c.d.UPGRADE_URL,e)}}},h=n(47433);const p=(0,h.A)(d,[["render",s]]);var f=p},7042:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return q}});var r=n(9274);const i={class:"bundleModal"},o={class:"p-20"},a={class:"content"},s={key:0,class:"circle mb-20"},l={key:0,class:"mb-20"},c={class:"footer mt-20"};function u(e,t,n,u,d,h){const p=(0,r.resolveComponent)("GraphCircle"),f=(0,r.resolveComponent)("LabeledInput"),m=(0,r.resolveComponent)("LabeledSelect"),g=(0,r.resolveComponent)("UnitInput"),v=(0,r.resolveComponent)("Banner"),b=(0,r.resolveComponent)("AsyncButton"),y=(0,r.resolveComponent)("app-modal"),w=(0,r.resolveDirective)("clean-html");return(0,r.openBlock)(),(0,r.createElementBlock)("div",i,[d.isOpen?((0,r.openBlock)(),(0,r.createBlock)(y,{key:0,name:"bundle-modal","custom-class":"bundleModal","click-to-close":!1,width:550,height:390,class:"remove-modal support-modal",onClose:h.close},{default:(0,r.withCtx)(()=>[(0,r.createElementVNode)("div",o,[(0,r.createElementVNode)("h2",null,(0,r.toDisplayString)(e.t("harvester.modal.bundle.title")),1),(0,r.createElementVNode)("div",a,[h.bundlePending?((0,r.openBlock)(),(0,r.createElementBlock)("div",s,[(0,r.createVNode)(p,{"primary-stroke-color":"green","secondary-stroke-color":"lightgrey","stroke-width":6,percentage:h.percentage,"show-text":!0},null,8,["percentage"])])):((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:1},[h.customSupportBundleFeatureEnabled?(0,r.withDirectives)(((0,r.openBlock)(),(0,r.createElementBlock)("p",l,null,512)),[[w,e.t("harvester.modal.bundle.tip",{doc:h.docLink},!0)]]):(0,r.createCommentVNode)("",!0),(0,r.createVNode)(f,{value:d.url,"onUpdate:value":t[0]||(t[0]=e=>d.url=e),label:e.t("harvester.modal.bundle.url"),class:"mb-10"},null,8,["value","label"]),(0,r.createVNode)(f,{value:d.description,"onUpdate:value":t[1]||(t[1]=e=>d.description=e),required:"",label:e.t("harvester.modal.bundle.description"),type:"multiline","min-height":80,class:"mb-10"},null,8,["value","label"]),h.customSupportBundleFeatureEnabled?((0,r.openBlock)(),(0,r.createElementBlock)(r.Fragment,{key:1},[(0,r.createVNode)(m,{value:d.namespaces,"onUpdate:value":[t[2]||(t[2]=e=>d.namespaces=e),h.updateNamespaces],label:e.t("harvester.modal.bundle.namespaces.label"),clearable:!0,multiple:!0,"append-to-body":!1,options:h.namespaceOptions,class:"mb-10 namespace-select",tooltip:e.t("harvester.modal.bundle.namespaces.tooltip",e._,!0)},null,8,["value","label","options","tooltip","onUpdate:value"]),(0,r.createVNode)(g,{value:d.timeout,"onUpdate:value":[t[3]||(t[3]=e=>d.timeout=e),t[4]||(t[4]=e=>h.updateNumberValue("timeout",e))],label:e.t("harvester.modal.bundle.timeout.label"),class:"mb-10",type:"number",min:0,tooltip:e.t("harvester.modal.bundle.timeout.tooltip",e._,!0),suffix:d.timeout>1?"Minutes":"Minute",onKeydown:h.onKeyDown},null,8,["value","label","tooltip","suffix","onKeydown"]),(0,r.createVNode)(g,{value:d.expiration,"onUpdate:value":[t[5]||(t[5]=e=>d.expiration=e),t[6]||(t[6]=e=>h.updateNumberValue("expiration",e))],label:e.t("harvester.modal.bundle.expiration.label"),class:"mb-10",type:"number",min:0,tooltip:e.t("harvester.modal.bundle.expiration.tooltip",e._,!0),suffix:d.expiration>1?"Minutes":"Minute",onKeydown:h.onKeyDown},null,8,["value","label","tooltip","suffix","onKeydown"]),(0,r.createVNode)(g,{value:d.nodeTimeout,"onUpdate:value":[t[7]||(t[7]=e=>d.nodeTimeout=e),t[8]||(t[8]=e=>h.updateNumberValue("nodeTimeout",e))],label:e.t("harvester.modal.bundle.nodeTimeout.label"),class:"mb-10",type:"number",min:0,tooltip:e.t("harvester.modal.bundle.nodeTimeout.tooltip",e._,!0),suffix:d.nodeTimeout>1?"Minutes":"Minute",onKeydown:h.onKeyDown},null,8,["value","label","tooltip","suffix","onKeydown"])],64)):(0,r.createCommentVNode)("",!0)],64)),((0,r.openBlock)(!0),(0,r.createElementBlock)(r.Fragment,null,(0,r.renderList)(d.errors,(e,t)=>((0,r.openBlock)(),(0,r.createElementBlock)("div",{key:t},[(0,r.createVNode)(v,{color:"error",label:h.stringify(e)},null,8,["label"])]))),128)),(0,r.createElementVNode)("div",c,[(0,r.createElementVNode)("button",{class:"btn btn-sm role-secondary mr-10",onClick:t[9]||(t[9]=(...e)=>h.close&&h.close(...e))},(0,r.toDisplayString)(e.t("generic.close")),1),(0,r.createVNode)(b,{type:"submit",mode:"generate",class:"btn btn-sm bg-primary",disabled:h.bundlePending,onClick:h.save},null,8,["disabled","onClick"])])])])]),_:1},8,["onClose"])):(0,r.createCommentVNode)("",!0)])}var d=n(35664),h=n(92043),p=n(99726),f=n(79380),m=n(30699);const g=["viewBox"],v=["transform"],b=["id"],y=["stop-color"],w=["stop-color"],O=["id"],S=["stop-color"],E=["stop-color"],x=["r","cy","cx","stroke-width","stroke"],_=["r","cy","cx","stroke-width","stroke","stroke-dasharray","stroke-dashoffset"],k=["x","y","fill"];function C(e,t,n,i,o,a){return(0,r.openBlock)(),(0,r.createElementBlock)("svg",{class:"circle",width:"100%",height:"100%",viewBox:a.viewBox},[(0,r.createElementVNode)("g",{transform:a.transform},[(0,r.createElementVNode)("defs",null,[(0,r.createElementVNode)("linearGradient",{id:a.primaryStrokeColorId,x1:"0%",y1:"0%",x2:"100%",y2:"0%"},[(0,r.createElementVNode)("stop",{offset:"50%","stop-color":n.primaryStrokeGradientColor||n.primaryStrokeColor},null,8,y),(0,r.createElementVNode)("stop",{offset:"100%","stop-color":n.primaryStrokeColor},null,8,w)],8,b),(0,r.createElementVNode)("linearGradient",{id:a.secondaryStrokeColorId,x1:"0%",y1:"0%",x2:"100%",y2:"0%"},[(0,r.createElementVNode)("stop",{offset:"50%","stop-color":n.secondaryStrokeGradientColor||n.secondaryStrokeColor},null,8,S),(0,r.createElementVNode)("stop",{offset:"100%","stop-color":n.secondaryStrokeColor},null,8,E)],8,O)]),(0,r.createElementVNode)("circle",{r:a.radius,cy:a.center,cx:a.center,"stroke-width":n.strokeWidth,stroke:`url(#${a.secondaryStrokeColorId})`,fill:"none"},null,8,x),(0,r.createElementVNode)("circle",{r:a.radius,cy:a.center,cx:a.center,"stroke-width":n.strokeWidth,stroke:`url(#${a.primaryStrokeColorId})`,"stroke-dasharray":a.circumference,"stroke-dashoffset":a.circumference*(1-n.percentage),fill:"none"},null,8,_)],8,v),n.showText?((0,r.openBlock)(),(0,r.createElementBlock)("text",{key:0,x:a.center,y:a.center,style:{"font-size":"25px","dominant-baseline":"middle","text-anchor":"middle"},fill:`url(#${a.primaryStrokeColorId})`},(0,r.toDisplayString)(a.parsePercentage)+"% ",9,k)):(0,r.createCommentVNode)("",!0)],8,g)}let A=0;var T={props:{percentage:{type:Number,default:.75},strokeWidth:{type:Number,default:22},primaryStrokeColor:{type:String,required:!0},primaryStrokeGradientColor:{type:String,default:null},secondaryStrokeColor:{type:String,required:!0},secondaryStrokeGradientColor:{type:String,default:null},rotate:{type:Number,default:90},showText:{type:Boolean,default:!1}},data(){return{id:A++}},computed:{viewportSize(){return 100},radius(){const e=this.viewportSize/2,t=this.strokeWidth/2;return e-t},center(){return this.viewportSize/2},viewBox(){return`0 0 ${this.viewportSize} ${this.viewportSize}`},circumference(){return 2*Math.PI*this.radius},transform(){return`rotate(${this.rotate}, ${this.center}, ${this.center})`},strokeDasharray(){return this.circumference},strokeDashoffset(){return this.circumference*(1-this.percentage)},primaryStrokeColorId(){return`primary-${A}`},secondaryStrokeColorId(){return`secondary-${A}`},parsePercentage(){return parseInt(100*this.percentage)||0}}},R=(n(97137),n(47433));const N=(0,R.A)(T,[["render",C],["__scopeId","data-v-0343103a"]]);var P=N,I=n(9980),M=n(79535),D=n(49452),L=n(73344),B=n(32766),$=n(50889),V=n(66242),F=n(3791);const j="select_all",U="unselect_all";var G={name:"SupportBundle",components:{LabeledInput:f.o,GraphCircle:P,AsyncButton:m.A,Banner:I.l,AppModal:M.h,LabeledSelect:D.A,UnitInput:L.A},async fetch(){await this.$store.dispatch("harvester/findAll",{type:d.CU});try{const e=this.$store.getters["harvester-common/getHarvesterClusterUrl"]("v1/harvester/namespaces?link=supportbundle"),t=await this.$store.dispatch("harvester/request",{url:e});this.defaultNamespaces=t.data||[]}catch(p){this.defaultNamespaces=[]}},data(){return{isOpen:!1,errors:[],version:"",clusterName:"",url:"",description:"",namespaces:[],defaultNamespaces:[],timeout:"",expiration:"",nodeTimeout:""}},computed:{bundlePending(){return this.$store.getters["harvester-common/isBundlePending"]},isShowBundleModal(){return this.$store.getters["harvester-common/isShowBundleModal"]},percentage(){return this.$store.getters["harvester-common/getBundlePercentage"]},availableNamespaces(){const e=this.$store.getters["harvester/all"](d.CU).map(e=>e.id),t=this.defaultNamespaces.map(e=>e.id);return e.filter(e=>!t.includes(e)||this.namespaces.includes(e))},namespaceOptions(){if(0===this.availableNamespaces.length)return[];const e=this.namespaces.length===this.availableNamespaces.length&&this.availableNamespaces.every(e=>this.namespaces.includes(e)),t=e?{label:this.t("harvester.modal.bundle.namespaces.unselectAll"),value:U}:{label:this.t("harvester.modal.bundle.namespaces.selectAll"),value:j};return[t,...this.availableNamespaces]},docLink(){const e=this.$store.getters["harvester-common/getServerVersion"]();return(0,F.nn)(V.d.SUPPORT_BUNDLE_NAMESPACES,e)},customSupportBundleFeatureEnabled(){return this.$store.getters["harvester-common/getFeatureEnabled"]("customSupportBundle")}},watch:{isShowBundleModal:{immediate:!0,handler(e){this.isOpen=e}},isOpen(e){e?this.loadDefaultSettings():this.resetForm()}},methods:{stringify:p.As,close(){this.isOpen=!1,this.$store.commit("harvester-common/toggleBundleModal",!1)},loadDefaultSettings(){const e=this.$store.getters["currentCluster"],t=this.$store.getters["harvester/byId"](B.rk.SETTING,$.EP.SERVER_VERSION),n=this.$store.getters["harvester/byId"](B.rk.SETTING,$.EP.SUPPORT_BUNDLE_NAMESPACES),r=this.$store.getters["harvester/byId"](B.rk.SETTING,$.EP.SUPPORT_BUNDLE_TIMEOUT),i=this.$store.getters["harvester/byId"](B.rk.SETTING,$.EP.SUPPORT_BUNDLE_EXPIRATION),o=this.$store.getters["harvester/byId"](B.rk.SETTING,$.EP.SUPPORT_BUNDLE_NODE_COLLECTION_TIMEOUT);this.version=t?.currentVersion||"",this.clusterName=e?.id||"",this.namespaces=(n?.value??n?.default??"").split(",").map(e=>e.trim()).filter(e=>e),this.timeout=r?.value??r?.default??"",this.expiration=i?.value??i?.default??"",this.nodeTimeout=o?.value??o?.default??"",this.url="",this.description="",this.errors=[]},resetForm(){this.url="",this.description="",this.namespaces=[],this.timeout="",this.expiration="",this.nodeTimeout="",this.errors=[]},updateNamespaces(e){e.includes(j)?this.namespaces=[...this.availableNamespaces]:e.includes(U)?this.namespaces=[]:this.namespaces=e.filter(e=>e!==j&&e!==U)},updateNumberValue(e,t){if(""===t||null===t||isNaN(t))return void(this[e]="");const n=Number(t),r=Number.isInteger(n)&&n>=0;this[e]=r?String(n):""},onKeyDown(e){["e","E","+","-","."].includes(e.key)&&e.preventDefault()},async save(e){this.errors=[];const t=`bundle-${this.clusterName}-${this.version}-${(0,h.vx)(5).toLowerCase()}`,n="harvester-system",r={description:this.description.trim(),...this.url.trim()&&{issueURL:this.url.trim()},...this.namespaces.length>0&&{extraCollectionNamespaces:this.namespaces},...""!==this.timeout&&{timeout:Number(this.timeout)},...""!==this.expiration&&{expiration:Number(this.expiration)},...""!==this.nodeTimeout&&{nodeTimeout:Number(this.nodeTimeout)}},i={apiVersion:"harvesterhci.io/v1beta1",type:B.rk.SUPPORT_BUNDLE,kind:"SupportBundle",metadata:{name:t,namespace:n},spec:r};try{const e=this.$store.getters["currentProduct"].inStore,r=await this.$store.dispatch(`${e}/create`,i);await r.save(),this.$store.commit("harvester-common/setLatestBundleId",`${n}/${t}`,{root:!0}),this.$store.dispatch("harvester-common/bundleProgress",{root:!0})}catch(o){this.errors=(0,p.rz)(o),e(!1)}}}};n(25737);const H=(0,R.A)(G,[["render",u],["__scopeId","data-v-edef926a"]]);var q=H},68165:function(e,t,n){"use strict";var r=n(79138),i=n(6095),o=n(64531),a=n(87196);e.exports=a||r.call(o,i)},62012:function(e,t,n){"use strict";var r=n(79138),i=n(6095),o=n(68165);e.exports=function(){return o(r,i,arguments)}},6095:function(e){"use strict";e.exports=Function.prototype.apply},64531:function(e){"use strict";e.exports=Function.prototype.call},79903:function(e,t,n){"use strict";var r=n(79138),i=n(3468),o=n(64531),a=n(68165);e.exports=function(e){if(e.length<1||"function"!==typeof e[0])throw new i("a function is required");return a(r,o,e)}},87196:function(e){"use strict";e.exports="undefined"!==typeof Reflect&&Reflect&&Reflect.apply},79818:function(e,t,n){"use strict";var r=n(528),i=n(28498),o=i(r("String.prototype.indexOf"));e.exports=function(e,t){var n=r(e,!!t);return"function"===typeof n&&o(e,".prototype.")>-1?i(n):n}},28498:function(e,t,n){"use strict";var r=n(26108),i=n(64940),o=n(79903),a=n(62012);e.exports=function(e){var t=o(arguments),n=1+e.length-(arguments.length-1);return r(t,n>0?n:0,!0)},i?i(e.exports,"apply",{value:a}):e.exports.apply=a},14607:function(e,t,n){"use strict";var r=n(528),i=n(79903),o=i([r("%String.prototype.indexOf%")]);e.exports=function(e,t){var n=r(e,!!t);return"function"===typeof n&&o(e,".prototype.")>-1?i([n]):n}},59246:function(e,t,n){const r=n(76931),i={};for(const s of Object.keys(r))i[r[s]]=s;const o={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};e.exports=o;for(const s of Object.keys(o)){if(!("channels"in o[s]))throw new Error("missing channels property: "+s);if(!("labels"in o[s]))throw new Error("missing channel labels property: "+s);if(o[s].labels.length!==o[s].channels)throw new Error("channel and label counts mismatch: "+s);const{channels:e,labels:t}=o[s];delete o[s].channels,delete o[s].labels,Object.defineProperty(o[s],"channels",{value:e}),Object.defineProperty(o[s],"labels",{value:t})}function a(e,t){return(e[0]-t[0])**2+(e[1]-t[1])**2+(e[2]-t[2])**2}o.rgb.hsl=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,i=Math.min(t,n,r),o=Math.max(t,n,r),a=o-i;let s,l;o===i?s=0:t===o?s=(n-r)/a:n===o?s=2+(r-t)/a:r===o&&(s=4+(t-n)/a),s=Math.min(60*s,360),s<0&&(s+=360);const c=(i+o)/2;return l=o===i?0:c<=.5?a/(o+i):a/(2-o-i),[s,100*l,100*c]},o.rgb.hsv=function(e){let t,n,r,i,o;const a=e[0]/255,s=e[1]/255,l=e[2]/255,c=Math.max(a,s,l),u=c-Math.min(a,s,l),d=function(e){return(c-e)/6/u+.5};return 0===u?(i=0,o=0):(o=u/c,t=d(a),n=d(s),r=d(l),a===c?i=r-n:s===c?i=1/3+t-r:l===c&&(i=2/3+n-t),i<0?i+=1:i>1&&(i-=1)),[360*i,100*o,100*c]},o.rgb.hwb=function(e){const t=e[0],n=e[1];let r=e[2];const i=o.rgb.hsl(e)[0],a=1/255*Math.min(t,Math.min(n,r));return r=1-1/255*Math.max(t,Math.max(n,r)),[i,100*a,100*r]},o.rgb.cmyk=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,i=Math.min(1-t,1-n,1-r),o=(1-t-i)/(1-i)||0,a=(1-n-i)/(1-i)||0,s=(1-r-i)/(1-i)||0;return[100*o,100*a,100*s,100*i]},o.rgb.keyword=function(e){const t=i[e];if(t)return t;let n,o=1/0;for(const i of Object.keys(r)){const t=r[i],s=a(e,t);s<o&&(o=s,n=i)}return n},o.keyword.rgb=function(e){return r[e]},o.rgb.xyz=function(e){let t=e[0]/255,n=e[1]/255,r=e[2]/255;t=t>.04045?((t+.055)/1.055)**2.4:t/12.92,n=n>.04045?((n+.055)/1.055)**2.4:n/12.92,r=r>.04045?((r+.055)/1.055)**2.4:r/12.92;const i=.4124*t+.3576*n+.1805*r,o=.2126*t+.7152*n+.0722*r,a=.0193*t+.1192*n+.9505*r;return[100*i,100*o,100*a]},o.rgb.lab=function(e){const t=o.rgb.xyz(e);let n=t[0],r=t[1],i=t[2];n/=95.047,r/=100,i/=108.883,n=n>.008856?n**(1/3):7.787*n+16/116,r=r>.008856?r**(1/3):7.787*r+16/116,i=i>.008856?i**(1/3):7.787*i+16/116;const a=116*r-16,s=500*(n-r),l=200*(r-i);return[a,s,l]},o.hsl.rgb=function(e){const t=e[0]/360,n=e[1]/100,r=e[2]/100;let i,o,a;if(0===n)return a=255*r,[a,a,a];i=r<.5?r*(1+n):r+n-r*n;const s=2*r-i,l=[0,0,0];for(let c=0;c<3;c++)o=t+1/3*-(c-1),o<0&&o++,o>1&&o--,a=6*o<1?s+6*(i-s)*o:2*o<1?i:3*o<2?s+(i-s)*(2/3-o)*6:s,l[c]=255*a;return l},o.hsl.hsv=function(e){const t=e[0];let n=e[1]/100,r=e[2]/100,i=n;const o=Math.max(r,.01);r*=2,n*=r<=1?r:2-r,i*=o<=1?o:2-o;const a=(r+n)/2,s=0===r?2*i/(o+i):2*n/(r+n);return[t,100*s,100*a]},o.hsv.rgb=function(e){const t=e[0]/60,n=e[1]/100;let r=e[2]/100;const i=Math.floor(t)%6,o=t-Math.floor(t),a=255*r*(1-n),s=255*r*(1-n*o),l=255*r*(1-n*(1-o));switch(r*=255,i){case 0:return[r,l,a];case 1:return[s,r,a];case 2:return[a,r,l];case 3:return[a,s,r];case 4:return[l,a,r];case 5:return[r,a,s]}},o.hsv.hsl=function(e){const t=e[0],n=e[1]/100,r=e[2]/100,i=Math.max(r,.01);let o,a;a=(2-n)*r;const s=(2-n)*i;return o=n*i,o/=s<=1?s:2-s,o=o||0,a/=2,[t,100*o,100*a]},o.hwb.rgb=function(e){const t=e[0]/360;let n=e[1]/100,r=e[2]/100;const i=n+r;let o;i>1&&(n/=i,r/=i);const a=Math.floor(6*t),s=1-r;o=6*t-a,0!==(1&a)&&(o=1-o);const l=n+o*(s-n);let c,u,d;switch(a){default:case 6:case 0:c=s,u=l,d=n;break;case 1:c=l,u=s,d=n;break;case 2:c=n,u=s,d=l;break;case 3:c=n,u=l,d=s;break;case 4:c=l,u=n,d=s;break;case 5:c=s,u=n,d=l;break}return[255*c,255*u,255*d]},o.cmyk.rgb=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100,i=e[3]/100,o=1-Math.min(1,t*(1-i)+i),a=1-Math.min(1,n*(1-i)+i),s=1-Math.min(1,r*(1-i)+i);return[255*o,255*a,255*s]},o.xyz.rgb=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100;let i,o,a;return i=3.2406*t+-1.5372*n+-.4986*r,o=-.9689*t+1.8758*n+.0415*r,a=.0557*t+-.204*n+1.057*r,i=i>.0031308?1.055*i**(1/2.4)-.055:12.92*i,o=o>.0031308?1.055*o**(1/2.4)-.055:12.92*o,a=a>.0031308?1.055*a**(1/2.4)-.055:12.92*a,i=Math.min(Math.max(0,i),1),o=Math.min(Math.max(0,o),1),a=Math.min(Math.max(0,a),1),[255*i,255*o,255*a]},o.xyz.lab=function(e){let t=e[0],n=e[1],r=e[2];t/=95.047,n/=100,r/=108.883,t=t>.008856?t**(1/3):7.787*t+16/116,n=n>.008856?n**(1/3):7.787*n+16/116,r=r>.008856?r**(1/3):7.787*r+16/116;const i=116*n-16,o=500*(t-n),a=200*(n-r);return[i,o,a]},o.lab.xyz=function(e){const t=e[0],n=e[1],r=e[2];let i,o,a;o=(t+16)/116,i=n/500+o,a=o-r/200;const s=o**3,l=i**3,c=a**3;return o=s>.008856?s:(o-16/116)/7.787,i=l>.008856?l:(i-16/116)/7.787,a=c>.008856?c:(a-16/116)/7.787,i*=95.047,o*=100,a*=108.883,[i,o,a]},o.lab.lch=function(e){const t=e[0],n=e[1],r=e[2];let i;const o=Math.atan2(r,n);i=360*o/2/Math.PI,i<0&&(i+=360);const a=Math.sqrt(n*n+r*r);return[t,a,i]},o.lch.lab=function(e){const t=e[0],n=e[1],r=e[2],i=r/360*2*Math.PI,o=n*Math.cos(i),a=n*Math.sin(i);return[t,o,a]},o.rgb.ansi16=function(e,t=null){const[n,r,i]=e;let a=null===t?o.rgb.hsv(e)[2]:t;if(a=Math.round(a/50),0===a)return 30;let s=30+(Math.round(i/255)<<2|Math.round(r/255)<<1|Math.round(n/255));return 2===a&&(s+=60),s},o.hsv.ansi16=function(e){return o.rgb.ansi16(o.hsv.rgb(e),e[2])},o.rgb.ansi256=function(e){const t=e[0],n=e[1],r=e[2];if(t===n&&n===r)return t<8?16:t>248?231:Math.round((t-8)/247*24)+232;const i=16+36*Math.round(t/255*5)+6*Math.round(n/255*5)+Math.round(r/255*5);return i},o.ansi16.rgb=function(e){let t=e%10;if(0===t||7===t)return e>50&&(t+=3.5),t=t/10.5*255,[t,t,t];const n=.5*(1+~~(e>50)),r=(1&t)*n*255,i=(t>>1&1)*n*255,o=(t>>2&1)*n*255;return[r,i,o]},o.ansi256.rgb=function(e){if(e>=232){const t=10*(e-232)+8;return[t,t,t]}let t;e-=16;const n=Math.floor(e/36)/5*255,r=Math.floor((t=e%36)/6)/5*255,i=t%6/5*255;return[n,r,i]},o.rgb.hex=function(e){const t=((255&Math.round(e[0]))<<16)+((255&Math.round(e[1]))<<8)+(255&Math.round(e[2])),n=t.toString(16).toUpperCase();return"000000".substring(n.length)+n},o.hex.rgb=function(e){const t=e.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!t)return[0,0,0];let n=t[0];3===t[0].length&&(n=n.split("").map(e=>e+e).join(""));const r=parseInt(n,16),i=r>>16&255,o=r>>8&255,a=255&r;return[i,o,a]},o.rgb.hcg=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,i=Math.max(Math.max(t,n),r),o=Math.min(Math.min(t,n),r),a=i-o;let s,l;return s=a<1?o/(1-a):0,l=a<=0?0:i===t?(n-r)/a%6:i===n?2+(r-t)/a:4+(t-n)/a,l/=6,l%=1,[360*l,100*a,100*s]},o.hsl.hcg=function(e){const t=e[1]/100,n=e[2]/100,r=n<.5?2*t*n:2*t*(1-n);let i=0;return r<1&&(i=(n-.5*r)/(1-r)),[e[0],100*r,100*i]},o.hsv.hcg=function(e){const t=e[1]/100,n=e[2]/100,r=t*n;let i=0;return r<1&&(i=(n-r)/(1-r)),[e[0],100*r,100*i]},o.hcg.rgb=function(e){const t=e[0]/360,n=e[1]/100,r=e[2]/100;if(0===n)return[255*r,255*r,255*r];const i=[0,0,0],o=t%1*6,a=o%1,s=1-a;let l=0;switch(Math.floor(o)){case 0:i[0]=1,i[1]=a,i[2]=0;break;case 1:i[0]=s,i[1]=1,i[2]=0;break;case 2:i[0]=0,i[1]=1,i[2]=a;break;case 3:i[0]=0,i[1]=s,i[2]=1;break;case 4:i[0]=a,i[1]=0,i[2]=1;break;default:i[0]=1,i[1]=0,i[2]=s}return l=(1-n)*r,[255*(n*i[0]+l),255*(n*i[1]+l),255*(n*i[2]+l)]},o.hcg.hsv=function(e){const t=e[1]/100,n=e[2]/100,r=t+n*(1-t);let i=0;return r>0&&(i=t/r),[e[0],100*i,100*r]},o.hcg.hsl=function(e){const t=e[1]/100,n=e[2]/100,r=n*(1-t)+.5*t;let i=0;return r>0&&r<.5?i=t/(2*r):r>=.5&&r<1&&(i=t/(2*(1-r))),[e[0],100*i,100*r]},o.hcg.hwb=function(e){const t=e[1]/100,n=e[2]/100,r=t+n*(1-t);return[e[0],100*(r-t),100*(1-r)]},o.hwb.hcg=function(e){const t=e[1]/100,n=e[2]/100,r=1-n,i=r-t;let o=0;return i<1&&(o=(r-i)/(1-i)),[e[0],100*i,100*o]},o.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]},o.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]},o.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]},o.gray.hsl=function(e){return[0,0,e[0]]},o.gray.hsv=o.gray.hsl,o.gray.hwb=function(e){return[0,100,e[0]]},o.gray.cmyk=function(e){return[0,0,0,e[0]]},o.gray.lab=function(e){return[e[0],0,0]},o.gray.hex=function(e){const t=255&Math.round(e[0]/100*255),n=(t<<16)+(t<<8)+t,r=n.toString(16).toUpperCase();return"000000".substring(r.length)+r},o.rgb.gray=function(e){const t=(e[0]+e[1]+e[2])/3;return[t/255*100]}},99047:function(e,t,n){const r=n(59246),i=n(30802),o={},a=Object.keys(r);function s(e){const t=function(...t){const n=t[0];return void 0===n||null===n?n:(n.length>1&&(t=n),e(t))};return"conversion"in e&&(t.conversion=e.conversion),t}function l(e){const t=function(...t){const n=t[0];if(void 0===n||null===n)return n;n.length>1&&(t=n);const r=e(t);if("object"===typeof r)for(let e=r.length,i=0;i<e;i++)r[i]=Math.round(r[i]);return r};return"conversion"in e&&(t.conversion=e.conversion),t}a.forEach(e=>{o[e]={},Object.defineProperty(o[e],"channels",{value:r[e].channels}),Object.defineProperty(o[e],"labels",{value:r[e].labels});const t=i(e),n=Object.keys(t);n.forEach(n=>{const r=t[n];o[e][n]=l(r),o[e][n].raw=s(r)})}),e.exports=o},30802:function(e,t,n){const r=n(59246);function i(){const e={},t=Object.keys(r);for(let n=t.length,r=0;r<n;r++)e[t[r]]={distance:-1,parent:null};return e}function o(e){const t=i(),n=[e];t[e].distance=0;while(n.length){const e=n.pop(),i=Object.keys(r[e]);for(let r=i.length,o=0;o<r;o++){const r=i[o],a=t[r];-1===a.distance&&(a.distance=t[e].distance+1,a.parent=e,n.unshift(r))}}return t}function a(e,t){return function(n){return t(e(n))}}function s(e,t){const n=[t[e].parent,e];let i=r[t[e].parent][e],o=t[e].parent;while(t[o].parent)n.unshift(t[o].parent),i=a(r[t[o].parent][o],i),o=t[o].parent;return i.conversion=n,i}e.exports=function(e){const t=o(e),n={},r=Object.keys(t);for(let i=r.length,o=0;o<i;o++){const e=r[o],i=t[e];null!==i.parent&&(n[e]=s(e,t))}return n}},76931:function(e){"use strict";e.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}},43269:function(e,t,n){var r=n(76931),i=n(59975),o=Object.hasOwnProperty,a=Object.create(null);for(var s in r)o.call(r,s)&&(a[r[s]]=s);var l=e.exports={to:{},get:{}};function c(e,t,n){return Math.min(Math.max(t,e),n)}function u(e){var t=Math.round(e).toString(16).toUpperCase();return t.length<2?"0"+t:t}l.get=function(e){var t,n,r=e.substring(0,3).toLowerCase();switch(r){case"hsl":t=l.get.hsl(e),n="hsl";break;case"hwb":t=l.get.hwb(e),n="hwb";break;default:t=l.get.rgb(e),n="rgb";break}return t?{model:n,value:t}:null},l.get.rgb=function(e){if(!e)return null;var t,n,i,a=/^#([a-f0-9]{3,4})$/i,s=/^#([a-f0-9]{6})([a-f0-9]{2})?$/i,l=/^rgba?\(\s*([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/,u=/^rgba?\(\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/,d=/^(\w+)$/,h=[0,0,0,1];if(t=e.match(s)){for(i=t[2],t=t[1],n=0;n<3;n++){var p=2*n;h[n]=parseInt(t.slice(p,p+2),16)}i&&(h[3]=parseInt(i,16)/255)}else if(t=e.match(a)){for(t=t[1],i=t[3],n=0;n<3;n++)h[n]=parseInt(t[n]+t[n],16);i&&(h[3]=parseInt(i+i,16)/255)}else if(t=e.match(l)){for(n=0;n<3;n++)h[n]=parseInt(t[n+1],0);t[4]&&(t[5]?h[3]=.01*parseFloat(t[4]):h[3]=parseFloat(t[4]))}else{if(!(t=e.match(u)))return(t=e.match(d))?"transparent"===t[1]?[0,0,0,0]:o.call(r,t[1])?(h=r[t[1]],h[3]=1,h):null:null;for(n=0;n<3;n++)h[n]=Math.round(2.55*parseFloat(t[n+1]));t[4]&&(t[5]?h[3]=.01*parseFloat(t[4]):h[3]=parseFloat(t[4]))}for(n=0;n<3;n++)h[n]=c(h[n],0,255);return h[3]=c(h[3],0,1),h},l.get.hsl=function(e){if(!e)return null;var t=/^hsla?\(\s*([+-]?(?:\d{0,3}\.)?\d+)(?:deg)?\s*,?\s*([+-]?[\d\.]+)%\s*,?\s*([+-]?[\d\.]+)%\s*(?:[,|\/]\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/,n=e.match(t);if(n){var r=parseFloat(n[4]),i=(parseFloat(n[1])%360+360)%360,o=c(parseFloat(n[2]),0,100),a=c(parseFloat(n[3]),0,100),s=c(isNaN(r)?1:r,0,1);return[i,o,a,s]}return null},l.get.hwb=function(e){if(!e)return null;var t=/^hwb\(\s*([+-]?\d{0,3}(?:\.\d+)?)(?:deg)?\s*,\s*([+-]?[\d\.]+)%\s*,\s*([+-]?[\d\.]+)%\s*(?:,\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/,n=e.match(t);if(n){var r=parseFloat(n[4]),i=(parseFloat(n[1])%360+360)%360,o=c(parseFloat(n[2]),0,100),a=c(parseFloat(n[3]),0,100),s=c(isNaN(r)?1:r,0,1);return[i,o,a,s]}return null},l.to.hex=function(){var e=i(arguments);return"#"+u(e[0])+u(e[1])+u(e[2])+(e[3]<1?u(Math.round(255*e[3])):"")},l.to.rgb=function(){var e=i(arguments);return e.length<4||1===e[3]?"rgb("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+")":"rgba("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+", "+e[3]+")"},l.to.rgb.percent=function(){var e=i(arguments),t=Math.round(e[0]/255*100),n=Math.round(e[1]/255*100),r=Math.round(e[2]/255*100);return e.length<4||1===e[3]?"rgb("+t+"%, "+n+"%, "+r+"%)":"rgba("+t+"%, "+n+"%, "+r+"%, "+e[3]+")"},l.to.hsl=function(){var e=i(arguments);return e.length<4||1===e[3]?"hsl("+e[0]+", "+e[1]+"%, "+e[2]+"%)":"hsla("+e[0]+", "+e[1]+"%, "+e[2]+"%, "+e[3]+")"},l.to.hwb=function(){var e=i(arguments),t="";return e.length>=4&&1!==e[3]&&(t=", "+e[3]),"hwb("+e[0]+", "+e[1]+"%, "+e[2]+"%"+t+")"},l.to.keyword=function(e){return a[e.slice(0,3)]}},70465:function(e,t,n){const r=n(43269),i=n(99047),o=["keyword","gray","hex"],a={};for(const m of Object.keys(i))a[[...i[m].labels].sort().join("")]=m;const s={};function l(e,t){if(!(this instanceof l))return new l(e,t);if(t&&t in o&&(t=null),t&&!(t in i))throw new Error("Unknown model: "+t);let n,c;if(null==e)this.model="rgb",this.color=[0,0,0],this.valpha=1;else if(e instanceof l)this.model=e.model,this.color=[...e.color],this.valpha=e.valpha;else if("string"===typeof e){const t=r.get(e);if(null===t)throw new Error("Unable to parse color from string: "+e);this.model=t.model,c=i[this.model].channels,this.color=t.value.slice(0,c),this.valpha="number"===typeof t.value[c]?t.value[c]:1}else if(e.length>0){this.model=t||"rgb",c=i[this.model].channels;const n=Array.prototype.slice.call(e,0,c);this.color=f(n,c),this.valpha="number"===typeof e[c]?e[c]:1}else if("number"===typeof e)this.model="rgb",this.color=[e>>16&255,e>>8&255,255&e],this.valpha=1;else{this.valpha=1;const t=Object.keys(e);"alpha"in e&&(t.splice(t.indexOf("alpha"),1),this.valpha="number"===typeof e.alpha?e.alpha:0);const r=t.sort().join("");if(!(r in a))throw new Error("Unable to parse color from object: "+JSON.stringify(e));this.model=a[r];const{labels:o}=i[this.model],s=[];for(n=0;n<o.length;n++)s.push(e[o[n]]);this.color=f(s)}if(s[this.model])for(c=i[this.model].channels,n=0;n<c;n++){const e=s[this.model][n];e&&(this.color[n]=e(this.color[n]))}this.valpha=Math.max(0,Math.min(1,this.valpha)),Object.freeze&&Object.freeze(this)}l.prototype={toString(){return this.string()},toJSON(){return this[this.model]()},string(e){let t=this.model in r.to?this:this.rgb();t=t.round("number"===typeof e?e:1);const n=1===t.valpha?t.color:[...t.color,this.valpha];return r.to[t.model](n)},percentString(e){const t=this.rgb().round("number"===typeof e?e:1),n=1===t.valpha?t.color:[...t.color,this.valpha];return r.to.rgb.percent(n)},array(){return 1===this.valpha?[...this.color]:[...this.color,this.valpha]},object(){const e={},{channels:t}=i[this.model],{labels:n}=i[this.model];for(let r=0;r<t;r++)e[n[r]]=this.color[r];return 1!==this.valpha&&(e.alpha=this.valpha),e},unitArray(){const e=this.rgb().color;return e[0]/=255,e[1]/=255,e[2]/=255,1!==this.valpha&&e.push(this.valpha),e},unitObject(){const e=this.rgb().object();return e.r/=255,e.g/=255,e.b/=255,1!==this.valpha&&(e.alpha=this.valpha),e},round(e){return e=Math.max(e||0,0),new l([...this.color.map(u(e)),this.valpha],this.model)},alpha(e){return void 0!==e?new l([...this.color,Math.max(0,Math.min(1,e))],this.model):this.valpha},red:d("rgb",0,h(255)),green:d("rgb",1,h(255)),blue:d("rgb",2,h(255)),hue:d(["hsl","hsv","hsl","hwb","hcg"],0,e=>(e%360+360)%360),saturationl:d("hsl",1,h(100)),lightness:d("hsl",2,h(100)),saturationv:d("hsv",1,h(100)),value:d("hsv",2,h(100)),chroma:d("hcg",1,h(100)),gray:d("hcg",2,h(100)),white:d("hwb",1,h(100)),wblack:d("hwb",2,h(100)),cyan:d("cmyk",0,h(100)),magenta:d("cmyk",1,h(100)),yellow:d("cmyk",2,h(100)),black:d("cmyk",3,h(100)),x:d("xyz",0,h(95.047)),y:d("xyz",1,h(100)),z:d("xyz",2,h(108.833)),l:d("lab",0,h(100)),a:d("lab",1),b:d("lab",2),keyword(e){return void 0!==e?new l(e):i[this.model].keyword(this.color)},hex(e){return void 0!==e?new l(e):r.to.hex(this.rgb().round().color)},hexa(e){if(void 0!==e)return new l(e);const t=this.rgb().round().color;let n=Math.round(255*this.valpha).toString(16).toUpperCase();return 1===n.length&&(n="0"+n),r.to.hex(t)+n},rgbNumber(){const e=this.rgb().color;return(255&e[0])<<16|(255&e[1])<<8|255&e[2]},luminosity(){const e=this.rgb().color,t=[];for(const[n,r]of e.entries()){const e=r/255;t[n]=e<=.04045?e/12.92:((e+.055)/1.055)**2.4}return.2126*t[0]+.7152*t[1]+.0722*t[2]},contrast(e){const t=this.luminosity(),n=e.luminosity();return t>n?(t+.05)/(n+.05):(n+.05)/(t+.05)},level(e){const t=this.contrast(e);return t>=7?"AAA":t>=4.5?"AA":""},isDark(){const e=this.rgb().color,t=(2126*e[0]+7152*e[1]+722*e[2])/1e4;return t<128},isLight(){return!this.isDark()},negate(){const e=this.rgb();for(let t=0;t<3;t++)e.color[t]=255-e.color[t];return e},lighten(e){const t=this.hsl();return t.color[2]+=t.color[2]*e,t},darken(e){const t=this.hsl();return t.color[2]-=t.color[2]*e,t},saturate(e){const t=this.hsl();return t.color[1]+=t.color[1]*e,t},desaturate(e){const t=this.hsl();return t.color[1]-=t.color[1]*e,t},whiten(e){const t=this.hwb();return t.color[1]+=t.color[1]*e,t},blacken(e){const t=this.hwb();return t.color[2]+=t.color[2]*e,t},grayscale(){const e=this.rgb().color,t=.3*e[0]+.59*e[1]+.11*e[2];return l.rgb(t,t,t)},fade(e){return this.alpha(this.valpha-this.valpha*e)},opaquer(e){return this.alpha(this.valpha+this.valpha*e)},rotate(e){const t=this.hsl();let n=t.color[0];return n=(n+e)%360,n=n<0?360+n:n,t.color[0]=n,t},mix(e,t){if(!e||!e.rgb)throw new Error('Argument to "mix" was not a Color instance, but rather an instance of '+typeof e);const n=e.rgb(),r=this.rgb(),i=void 0===t?.5:t,o=2*i-1,a=n.alpha()-r.alpha(),s=((o*a===-1?o:(o+a)/(1+o*a))+1)/2,c=1-s;return l.rgb(s*n.red()+c*r.red(),s*n.green()+c*r.green(),s*n.blue()+c*r.blue(),n.alpha()*i+r.alpha()*(1-i))}};for(const m of Object.keys(i)){if(o.includes(m))continue;const{channels:e}=i[m];l.prototype[m]=function(...e){return this.model===m?new l(this):e.length>0?new l(e,m):new l([...p(i[this.model][m].raw(this.color)),this.valpha],m)},l[m]=function(...t){let n=t[0];return"number"===typeof n&&(n=f(t,e)),new l(n,m)}}function c(e,t){return Number(e.toFixed(t))}function u(e){return function(t){return c(t,e)}}function d(e,t,n){e=Array.isArray(e)?e:[e];for(const r of e)(s[r]||(s[r]=[]))[t]=n;return e=e[0],function(r){let i;return void 0!==r?(n&&(r=n(r)),i=this[e](),i.color[t]=r,i):(i=this[e]().color[t],n&&(i=n(i)),i)}}function h(e){return function(t){return Math.max(0,Math.min(e,t))}}function p(e){return Array.isArray(e)?e:[e]}function f(e,t){for(let n=0;n<t;n++)"number"!==typeof e[n]&&(e[n]=0);return e}e.exports=l},4364:function(e,t,n){var r=n(49208),i=n(26093);function o(){return(new Date).getTime()}var a,s=Array.prototype.slice,l={};a="undefined"!==typeof n.g&&n.g.console?n.g.console:"undefined"!==typeof window&&window.console?window.console:{};for(var c=[[f,"log"],[m,"info"],[g,"warn"],[v,"error"],[b,"time"],[y,"timeEnd"],[w,"trace"],[O,"dir"],[S,"assert"]],u=0;u<c.length;u++){var d=c[u],h=d[0],p=d[1];a[p]||(a[p]=h)}function f(){}function m(){a.log.apply(a,arguments)}function g(){a.log.apply(a,arguments)}function v(){a.warn.apply(a,arguments)}function b(e){l[e]=o()}function y(e){var t=l[e];if(!t)throw new Error("No such label: "+e);delete l[e];var n=o()-t;a.log(e+": "+n+"ms")}function w(){var e=new Error;e.name="Trace",e.message=r.format.apply(null,arguments),a.error(e.stack)}function O(e){a.log(r.inspect(e)+"\n")}function S(e){if(!e){var t=s.call(arguments,1);i.ok(!1,r.format.apply(null,t))}}e.exports=a},3369:function(e,t){"use strict";var n=this&&this.__assign||function(){return n=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n],t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},n.apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.isValidCron=void 0;var r=function(e){return/^\d+$/.test(e)?Number(e):NaN},i=function(e){return"*"===e},o=function(e){return"?"===e},a=function(e,t,n){return e>=t&&e<=n},s=function(e,t,n){var o=e.split("-");switch(o.length){case 1:return i(e)||a(r(e),t,n);case 2:var s=o.map(function(e){return r(e)}),l=s[0],c=s[1];return l<=c&&a(l,t,n)&&a(c,t,n);default:return!1}},l=function(e){return void 0===e||-1===e.search(/[^\d]/)&&r(e)>0},c=function(e,t,n){if(-1!==e.search(/[^\d-,\/*]/))return!1;var r=e.split(",");return r.every(function(e){var r=e.split("/");if(e.trim().endsWith("/"))return!1;if(r.length>2)return!1;var i=r[0],o=r[1];return s(i,t,n)&&l(o)})},u=function(e){return c(e,0,59)},d=function(e){return c(e,0,59)},h=function(e){return c(e,0,23)},p=function(e,t){return t&&o(e)||c(e,1,31)},f={jan:"1",feb:"2",mar:"3",apr:"4",may:"5",jun:"6",jul:"7",aug:"8",sep:"9",oct:"10",nov:"11",dec:"12"},m=function(e,t){if(-1!==e.search(/\/[a-zA-Z]/))return!1;if(t){var n=e.toLowerCase().replace(/[a-z]{3}/g,function(e){return void 0===f[e]?e:f[e]});return c(n,1,12)}return c(e,1,12)},g={sun:"0",mon:"1",tue:"2",wed:"3",thu:"4",fri:"5",sat:"6"},v=function(e,t){var n=t.allowBlankDay,i=t.alias,s=t.allowSevenAsSunday,l=t.allowNthWeekdayOfMonth;if(n&&o(e))return!0;if(!n&&o(e))return!1;if(-1!==e.search(/\/[a-zA-Z]/))return!1;var u=i?e.toLowerCase().replace(/[a-z]{3}/g,function(e){return void 0===g[e]?e:g[e]}):e,d=s?7:6,h=u.split("#");if(l&&h.length>=2){var p=h[0],f=h[1],m=h.slice(2);return 0===m.length&&(a(r(f),1,5)&&a(r(p),0,d))}return c(u,0,d)},b=function(e,t,n){return!(n&&o(e)&&o(t))},y=function(e){return e.trim().split(/\s+/)},w={alias:!1,seconds:!1,allowBlankDay:!1,allowSevenAsSunday:!1,allowNthWeekdayOfMonth:!1};t.isValidCron=function(e,t){var r=n(n({},w),t),i=y(e);if(i.length>(r.seconds?6:5)||i.length<5)return!1;var o=[];if(6===i.length){var a=i.shift();a&&o.push(u(a))}var s=i[0],l=i[1],c=i[2],f=i[3],g=i[4];return o.push(d(s)),o.push(h(l)),o.push(p(c,r.allowBlankDay)),o.push(m(f,r.alias)),o.push(v(g,r)),o.push(b(c,g,r.allowBlankDay)),o.every(Boolean)}},37021:function(e,t,n){var r=n(4364);(function(t,n){e.exports=n()})(globalThis,()=>(()=>{"use strict";var e={949:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CronParser=void 0;var r=n(515),i=function(){function e(e,t,n){void 0===t&&(t=!0),void 0===n&&(n=!1),this.expression=e,this.dayOfWeekStartIndexZero=t,this.monthStartIndexZero=n}return e.prototype.parse=function(){var e,t,n=null!==(e=this.expression)&&void 0!==e?e:"";if(n.startsWith("@")){var r=this.parseSpecial(this.expression);t=this.extractParts(r)}else t=this.extractParts(this.expression);return this.normalize(t),this.validate(t),t},e.prototype.parseSpecial=function(e){var t={"@yearly":"0 0 1 1 *","@annually":"0 0 1 1 *","@monthly":"0 0 1 * *","@weekly":"0 0 * * 0","@daily":"0 0 * * *","@midnight":"0 0 * * *","@hourly":"0 * * * *"},n=t[e];if(!n)throw new Error("Unknown special expression.");return n},e.prototype.extractParts=function(e){if(!this.expression)throw new Error("cron expression is empty");for(var t=e.trim().split(/[ ]+/),n=0;n<t.length;n++)if(t[n].includes(",")){var r=t[n].split(",").map(function(e){return e.trim()}).filter(function(e){return""!==e}).map(function(e){return isNaN(Number(e))?e:Number(e)}).filter(function(e){return null!==e&&""!==e});0===r.length&&r.push("*"),r.sort(function(e,t){return null!==e&&null!==t?e-t:0}),t[n]=r.map(function(e){return null!==e?e.toString():""}).join(",")}if(t.length<5)throw new Error("Expression has only ".concat(t.length," part").concat(1==t.length?"":"s",". At least 5 parts are required."));if(5==t.length)t.unshift(""),t.push("");else if(6==t.length){var i=/\d{4}$/.test(t[5])||"?"==t[4]||"?"==t[2];i?t.unshift(""):t.push("")}else if(t.length>7)throw new Error("Expression has ".concat(t.length," parts; too many!"));return t},e.prototype.normalize=function(e){var t=this;if(e[3]=e[3].replace("?","*"),e[5]=e[5].replace("?","*"),e[2]=e[2].replace("?","*"),0==e[0].indexOf("0/")&&(e[0]=e[0].replace("0/","*/")),0==e[1].indexOf("0/")&&(e[1]=e[1].replace("0/","*/")),0==e[2].indexOf("0/")&&(e[2]=e[2].replace("0/","*/")),0==e[3].indexOf("1/")&&(e[3]=e[3].replace("1/","*/")),0==e[4].indexOf("1/")&&(e[4]=e[4].replace("1/","*/")),0==e[6].indexOf("1/")&&(e[6]=e[6].replace("1/","*/")),e[5]=e[5].replace(/(^\d)|([^#/\s]\d)/g,function(e){var n=e.replace(/\D/,""),r=n;return t.dayOfWeekStartIndexZero?"7"==n&&(r="0"):r=(parseInt(n)-1).toString(),e.replace(n,r)}),"L"==e[5]&&(e[5]="6"),"?"==e[3]&&(e[3]="*"),e[3].indexOf("W")>-1&&(e[3].indexOf(",")>-1||e[3].indexOf("-")>-1))throw new Error("The 'W' character can be specified only when the day-of-month is a single day, not a range or list of days.");var n={SUN:0,MON:1,TUE:2,WED:3,THU:4,FRI:5,SAT:6};for(var r in n)e[5]=e[5].replace(new RegExp(r,"gi"),n[r].toString());e[4]=e[4].replace(/(^\d{1,2})|([^#/\s]\d{1,2})/g,function(e){var n=e.replace(/\D/,""),r=n;return t.monthStartIndexZero&&(r=(parseInt(n)+1).toString()),e.replace(n,r)});var i={JAN:1,FEB:2,MAR:3,APR:4,MAY:5,JUN:6,JUL:7,AUG:8,SEP:9,OCT:10,NOV:11,DEC:12};for(var o in i)e[4]=e[4].replace(new RegExp(o,"gi"),i[o].toString());"0"==e[0]&&(e[0]=""),/\*|\-|\,|\//.test(e[2])||!/\*|\//.test(e[1])&&!/\*|\//.test(e[0])||(e[2]+="-".concat(e[2]));for(var a=0;a<e.length;a++)if(-1!=e[a].indexOf(",")&&(e[a]=e[a].split(",").filter(function(e){return""!==e}).join(",")||"*"),"*/1"==e[a]&&(e[a]="*"),e[a].indexOf("/")>-1&&!/^\*|\-|\,/.test(e[a])){var s=null;switch(a){case 4:s="12";break;case 5:s="6";break;case 6:s="9999";break;default:s=null;break}if(null!==s){var l=e[a].split("/");e[a]="".concat(l[0],"-").concat(s,"/").concat(l[1])}}},e.prototype.validate=function(e){var t="0-9,\\-*/";this.validateOnlyExpectedCharactersFound(e[0],t),this.validateOnlyExpectedCharactersFound(e[1],t),this.validateOnlyExpectedCharactersFound(e[2],t),this.validateOnlyExpectedCharactersFound(e[3],"0-9,\\-*/LW"),this.validateOnlyExpectedCharactersFound(e[4],t),this.validateOnlyExpectedCharactersFound(e[5],"0-9,\\-*/L#"),this.validateOnlyExpectedCharactersFound(e[6],t),this.validateAnyRanges(e)},e.prototype.validateAnyRanges=function(e){r.default.secondRange(e[0]),r.default.minuteRange(e[1]),r.default.hourRange(e[2]),r.default.dayOfMonthRange(e[3]),r.default.monthRange(e[4],this.monthStartIndexZero),r.default.dayOfWeekRange(e[5],this.dayOfWeekStartIndexZero)},e.prototype.validateOnlyExpectedCharactersFound=function(e,t){var n=e.match(new RegExp("[^".concat(t,"]+"),"gi"));if(n&&n.length)throw new Error("Expression contains invalid values: '".concat(n.toString(),"'"))},e}();t.CronParser=i},333:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ExpressionDescriptor=void 0;var i=n(823),o=n(949),a=function(){function e(t,n){if(this.expression=t,this.options=n,this.expressionParts=new Array(5),!this.options.locale&&e.defaultLocale&&(this.options.locale=e.defaultLocale),!e.locales[this.options.locale]){var i=Object.keys(e.locales)[0];r.warn("Locale '".concat(this.options.locale,"' could not be found; falling back to '").concat(i,"'.")),this.options.locale=i}this.i18n=e.locales[this.options.locale],void 0===n.use24HourTimeFormat&&(n.use24HourTimeFormat=this.i18n.use24HourTimeFormatByDefault())}return e.toString=function(t,n){var i=void 0===n?{}:n,o=i.throwExceptionOnParseError,a=void 0===o||o,s=i.verbose,l=void 0!==s&&s,c=i.dayOfWeekStartIndexZero,u=void 0===c||c,d=i.monthStartIndexZero,h=void 0!==d&&d,p=i.use24HourTimeFormat,f=i.locale,m=void 0===f?null:f,g=i.tzOffset,v=void 0===g?0:g,b={throwExceptionOnParseError:a,verbose:l,dayOfWeekStartIndexZero:u,monthStartIndexZero:h,use24HourTimeFormat:p,locale:m,tzOffset:v};b.tzOffset&&r.warn("'tzOffset' option has been deprecated and will be removed in a future release.");var y=new e(t,b);return y.getFullDescription()},e.initialize=function(t,n){void 0===n&&(n="en"),e.specialCharacters=["/","-",",","*"],e.defaultLocale=n,t.load(e.locales)},e.prototype.getFullDescription=function(){var e="";try{var t=new o.CronParser(this.expression,this.options.dayOfWeekStartIndexZero,this.options.monthStartIndexZero);this.expressionParts=t.parse();var n=this.getTimeOfDayDescription(),r=this.getDayOfMonthDescription(),i=this.getMonthDescription(),a=this.getDayOfWeekDescription(),s=this.getYearDescription();e+=n+r+a+i+s,e=this.transformVerbosity(e,!!this.options.verbose),e=e.charAt(0).toLocaleUpperCase()+e.substr(1)}catch(l){if(this.options.throwExceptionOnParseError)throw"".concat(l);e=this.i18n.anErrorOccuredWhenGeneratingTheExpressionD()}return e},e.prototype.getTimeOfDayDescription=function(){var t=this.expressionParts[0],n=this.expressionParts[1],r=this.expressionParts[2],o="";if(i.StringUtilities.containsAny(n,e.specialCharacters)||i.StringUtilities.containsAny(r,e.specialCharacters)||i.StringUtilities.containsAny(t,e.specialCharacters))if(t||!(n.indexOf("-")>-1)||n.indexOf(",")>-1||n.indexOf("/")>-1||i.StringUtilities.containsAny(r,e.specialCharacters))if(!t&&r.indexOf(",")>-1&&-1==r.indexOf("-")&&-1==r.indexOf("/")&&!i.StringUtilities.containsAny(n,e.specialCharacters)){var a=r.split(",");o+=this.i18n.at();for(var s=0;s<a.length;s++)o+=" ",o+=this.formatTime(a[s],n,""),s<a.length-2&&(o+=","),s==a.length-2&&(o+=this.i18n.spaceAnd())}else{var l=this.getSecondsDescription(),c=this.getMinutesDescription(),u=this.getHoursDescription();if(o+=l,o&&c&&(o+=", "),o+=c,c===u)return o;o&&u&&(o+=", "),o+=u}else{var d=n.split("-");o+=i.StringUtilities.format(this.i18n.everyMinuteBetweenX0AndX1(),this.formatTime(r,d[0],""),this.formatTime(r,d[1],""))}else o+=this.i18n.atSpace()+this.formatTime(r,n,t);return o},e.prototype.getSecondsDescription=function(){var e=this,t=this.getSegmentDescription(this.expressionParts[0],this.i18n.everySecond(),function(e){return e},function(t){return i.StringUtilities.format(e.i18n.everyX0Seconds(t),t)},function(t){return e.i18n.secondsX0ThroughX1PastTheMinute()},function(t){return"0"==t?"":parseInt(t)<20?e.i18n.atX0SecondsPastTheMinute(t):e.i18n.atX0SecondsPastTheMinuteGt20()||e.i18n.atX0SecondsPastTheMinute(t)});return t},e.prototype.getMinutesDescription=function(){var e=this,t=this.expressionParts[0],n=this.expressionParts[2],r=this.getSegmentDescription(this.expressionParts[1],this.i18n.everyMinute(),function(e){return e},function(t){return i.StringUtilities.format(e.i18n.everyX0Minutes(t),t)},function(t){return e.i18n.minutesX0ThroughX1PastTheHour()},function(r){try{return"0"==r&&-1==n.indexOf("/")&&""==t?e.i18n.everyHour():parseInt(r)<20?e.i18n.atX0MinutesPastTheHour(r):e.i18n.atX0MinutesPastTheHourGt20()||e.i18n.atX0MinutesPastTheHour(r)}catch(i){return e.i18n.atX0MinutesPastTheHour(r)}});return r},e.prototype.getHoursDescription=function(){var e=this,t=this.expressionParts[2],n=0,r=[];t.split("/")[0].split(",").forEach(function(e){var t=e.split("-");2===t.length&&r.push({value:t[1],index:n+1}),n+=t.length});var o=0,a=this.getSegmentDescription(t,this.i18n.everyHour(),function(t){var n=r.find(function(e){return e.value===t&&e.index===o}),i=n&&"0"!==e.expressionParts[1];return o++,i?e.formatTime(t,"59",""):e.formatTime(t,"0","")},function(t){return i.StringUtilities.format(e.i18n.everyX0Hours(t),t)},function(t){return e.i18n.betweenX0AndX1()},function(t){return e.i18n.atX0()});return a},e.prototype.getDayOfWeekDescription=function(){var e=this,t=this.i18n.daysOfTheWeek(),n=null;return n="*"==this.expressionParts[5]?"":this.getSegmentDescription(this.expressionParts[5],this.i18n.commaEveryDay(),function(n,r){var i=n;n.indexOf("#")>-1?i=n.substring(0,n.indexOf("#")):n.indexOf("L")>-1&&(i=i.replace("L",""));var o=parseInt(i);if(e.options.tzOffset){var a=e.expressionParts[2],s=parseInt(a)+(e.options.tzOffset?e.options.tzOffset:0);s>=24?o++:s<0&&o--,o>6?o=0:o<0&&(o=6)}var l=e.i18n.daysOfTheWeekInCase?e.i18n.daysOfTheWeekInCase(r)[o]:t[o];if(n.indexOf("#")>-1){var c=null,u=n.substring(n.indexOf("#")+1),d=n.substring(0,n.indexOf("#"));switch(u){case"1":c=e.i18n.first(d);break;case"2":c=e.i18n.second(d);break;case"3":c=e.i18n.third(d);break;case"4":c=e.i18n.fourth(d);break;case"5":c=e.i18n.fifth(d);break}l=c+" "+l}return l},function(t){return 1==parseInt(t)?"":i.StringUtilities.format(e.i18n.commaEveryX0DaysOfTheWeek(t),t)},function(t){var n=t.substring(0,t.indexOf("-")),r="*"!=e.expressionParts[3];return r?e.i18n.commaAndX0ThroughX1(n):e.i18n.commaX0ThroughX1(n)},function(t){var n=null;if(t.indexOf("#")>-1){var r=t.substring(t.indexOf("#")+1),i=t.substring(0,t.indexOf("#"));n=e.i18n.commaOnThe(r,i).trim()+e.i18n.spaceX0OfTheMonth()}else if(t.indexOf("L")>-1)n=e.i18n.commaOnTheLastX0OfTheMonth(t.replace("L",""));else{var o="*"!=e.expressionParts[3];n=o?e.i18n.commaAndOnX0():e.i18n.commaOnlyOnX0(t)}return n}),n},e.prototype.getMonthDescription=function(){var e=this,t=this.i18n.monthsOfTheYear(),n=this.getSegmentDescription(this.expressionParts[4],"",function(n,r){return r&&e.i18n.monthsOfTheYearInCase?e.i18n.monthsOfTheYearInCase(r)[parseInt(n)-1]:t[parseInt(n)-1]},function(t){return 1==parseInt(t)?"":i.StringUtilities.format(e.i18n.commaEveryX0Months(t),t)},function(t){return e.i18n.commaMonthX0ThroughMonthX1()||e.i18n.commaX0ThroughX1()},function(t){return e.i18n.commaOnlyInMonthX0?e.i18n.commaOnlyInMonthX0():e.i18n.commaOnlyInX0()});return n},e.prototype.getDayOfMonthDescription=function(){var e=this,t=null,n=this.expressionParts[3];switch(n){case"L":t=this.i18n.commaOnTheLastDayOfTheMonth();break;case"WL":case"LW":t=this.i18n.commaOnTheLastWeekdayOfTheMonth();break;default:var r=n.match(/(\d{1,2}W)|(W\d{1,2})/);if(r){var o=parseInt(r[0].replace("W","")),a=1==o?this.i18n.firstWeekday():i.StringUtilities.format(this.i18n.weekdayNearestDayX0(),o.toString());t=i.StringUtilities.format(this.i18n.commaOnTheX0OfTheMonth(),a);break}var s=n.match(/L-(\d{1,2})/);if(s){var l=s[1];t=i.StringUtilities.format(this.i18n.commaDaysBeforeTheLastDayOfTheMonth(l),l);break}if("*"==n&&"*"!=this.expressionParts[5])return"";t=this.getSegmentDescription(n,this.i18n.commaEveryDay(),function(t){return"L"==t?e.i18n.lastDay():e.i18n.dayX0?i.StringUtilities.format(e.i18n.dayX0(),t):t},function(t){return"1"==t?e.i18n.commaEveryDay():e.i18n.commaEveryX0Days(t)},function(t){return e.i18n.commaBetweenDayX0AndX1OfTheMonth(t)},function(t){return e.i18n.commaOnDayX0OfTheMonth(t)});break}return t},e.prototype.getYearDescription=function(){var e=this,t=this.getSegmentDescription(this.expressionParts[6],"",function(e){return/^\d+$/.test(e)?new Date(parseInt(e),1).getFullYear().toString():e},function(t){return i.StringUtilities.format(e.i18n.commaEveryX0Years(t),t)},function(t){return e.i18n.commaYearX0ThroughYearX1()||e.i18n.commaX0ThroughX1()},function(t){return e.i18n.commaOnlyInYearX0?e.i18n.commaOnlyInYearX0():e.i18n.commaOnlyInX0()});return t},e.prototype.getSegmentDescription=function(e,t,n,r,o,a){var s=null,l=e.indexOf("/")>-1,c=e.indexOf("-")>-1,u=e.indexOf(",")>-1;if(e)if("*"===e)s=t;else if(l||c||u)if(u){for(var d=e.split(","),h="",p=0;p<d.length;p++)if(p>0&&d.length>2&&(h+=",",p<d.length-1&&(h+=" ")),p>0&&d.length>1&&(p==d.length-1||2==d.length)&&(h+="".concat(this.i18n.spaceAnd()," ")),d[p].indexOf("/")>-1||d[p].indexOf("-")>-1){var f=d[p].indexOf("-")>-1&&-1==d[p].indexOf("/"),m=this.getSegmentDescription(d[p],t,n,r,f?this.i18n.commaX0ThroughX1:o,a);f&&(m=m.replace(", ","")),h+=m}else h+=l?this.getSegmentDescription(d[p],t,n,r,o,a):n(d[p]);s=l?h:i.StringUtilities.format(a(e),h)}else if(l){d=e.split("/");if(s=i.StringUtilities.format(r(d[1]),d[1]),d[0].indexOf("-")>-1){var g=this.generateRangeSegmentDescription(d[0],o,n);0!=g.indexOf(", ")&&(s+=", "),s+=g}else if(-1==d[0].indexOf("*")){var v=i.StringUtilities.format(a(d[0]),n(d[0]));v=v.replace(", ",""),s+=i.StringUtilities.format(this.i18n.commaStartingX0(),v)}}else c&&(s=this.generateRangeSegmentDescription(e,o,n));else s=i.StringUtilities.format(a(e),n(e));else s="";return s},e.prototype.generateRangeSegmentDescription=function(e,t,n){var r="",o=e.split("-"),a=n(o[0],1),s=n(o[1],2),l=t(e);return r+=i.StringUtilities.format(l,a,s),r},e.prototype.formatTime=function(e,t,n){var r=0,i=0;this.options.tzOffset&&(r=this.options.tzOffset>0?Math.floor(this.options.tzOffset):Math.ceil(this.options.tzOffset),i=parseFloat((this.options.tzOffset%1).toFixed(2)),0!=i&&(i*=60));var o=parseInt(e)+r,a=parseInt(t)+i;a>=60?(a-=60,o+=1):a<0&&(a+=60,o-=1),o>=24?o-=24:o<0&&(o=24+o);var s="",l=!1;this.options.use24HourTimeFormat||(l=!(!this.i18n.setPeriodBeforeTime||!this.i18n.setPeriodBeforeTime()),s=l?"".concat(this.getPeriod(o)," "):" ".concat(this.getPeriod(o)),o>12&&(o-=12),0===o&&(o=12));var c="";return n&&(c=":".concat(("00"+n).substring(n.length))),"".concat(l?s:"").concat(("00"+o.toString()).substring(o.toString().length),":").concat(("00"+a.toString()).substring(a.toString().length)).concat(c).concat(l?"":s)},e.prototype.transformVerbosity=function(e,t){if(!t&&(e=e.replace(new RegExp(", ".concat(this.i18n.everyMinute()),"g"),""),e=e.replace(new RegExp(", ".concat(this.i18n.everyHour()),"g"),""),e=e.replace(new RegExp(this.i18n.commaEveryDay(),"g"),""),e=e.replace(/\, ?$/,""),this.i18n.conciseVerbosityReplacements))for(var n=0,r=Object.entries(this.i18n.conciseVerbosityReplacements());n<r.length;n++){var i=r[n],o=i[0],a=i[1];e=e.replace(new RegExp(o,"g"),a)}return e},e.prototype.getPeriod=function(e){return e>=12?this.i18n.pm&&this.i18n.pm()||"PM":this.i18n.am&&this.i18n.am()||"AM"},e.locales={},e}();t.ExpressionDescriptor=a},747:(e,t,n)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.enLocaleLoader=void 0;var r=n(486),i=function(){function e(){}return e.prototype.load=function(e){e["en"]=new r.en},e}();t.enLocaleLoader=i},486:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.en=void 0;var n=function(){function e(){}return e.prototype.atX0SecondsPastTheMinuteGt20=function(){return null},e.prototype.atX0MinutesPastTheHourGt20=function(){return null},e.prototype.commaMonthX0ThroughMonthX1=function(){return null},e.prototype.commaYearX0ThroughYearX1=function(){return null},e.prototype.use24HourTimeFormatByDefault=function(){return!1},e.prototype.anErrorOccuredWhenGeneratingTheExpressionD=function(){return"An error occurred when generating the expression description. Check the cron expression syntax."},e.prototype.everyMinute=function(){return"every minute"},e.prototype.everyHour=function(){return"every hour"},e.prototype.atSpace=function(){return"At "},e.prototype.everyMinuteBetweenX0AndX1=function(){return"Every minute between %s and %s"},e.prototype.at=function(){return"At"},e.prototype.spaceAnd=function(){return" and"},e.prototype.everySecond=function(){return"every second"},e.prototype.everyX0Seconds=function(){return"every %s seconds"},e.prototype.secondsX0ThroughX1PastTheMinute=function(){return"seconds %s through %s past the minute"},e.prototype.atX0SecondsPastTheMinute=function(){return"at %s seconds past the minute"},e.prototype.everyX0Minutes=function(){return"every %s minutes"},e.prototype.minutesX0ThroughX1PastTheHour=function(){return"minutes %s through %s past the hour"},e.prototype.atX0MinutesPastTheHour=function(){return"at %s minutes past the hour"},e.prototype.everyX0Hours=function(){return"every %s hours"},e.prototype.betweenX0AndX1=function(){return"between %s and %s"},e.prototype.atX0=function(){return"at %s"},e.prototype.commaEveryDay=function(){return", every day"},e.prototype.commaEveryX0DaysOfTheWeek=function(){return", every %s days of the week"},e.prototype.commaX0ThroughX1=function(){return", %s through %s"},e.prototype.commaAndX0ThroughX1=function(){return", %s through %s"},e.prototype.first=function(){return"first"},e.prototype.second=function(){return"second"},e.prototype.third=function(){return"third"},e.prototype.fourth=function(){return"fourth"},e.prototype.fifth=function(){return"fifth"},e.prototype.commaOnThe=function(){return", on the "},e.prototype.spaceX0OfTheMonth=function(){return" %s of the month"},e.prototype.lastDay=function(){return"the last day"},e.prototype.commaOnTheLastX0OfTheMonth=function(){return", on the last %s of the month"},e.prototype.commaOnlyOnX0=function(){return", only on %s"},e.prototype.commaAndOnX0=function(){return", and on %s"},e.prototype.commaEveryX0Months=function(){return", every %s months"},e.prototype.commaOnlyInX0=function(){return", only in %s"},e.prototype.commaOnTheLastDayOfTheMonth=function(){return", on the last day of the month"},e.prototype.commaOnTheLastWeekdayOfTheMonth=function(){return", on the last weekday of the month"},e.prototype.commaDaysBeforeTheLastDayOfTheMonth=function(){return", %s days before the last day of the month"},e.prototype.firstWeekday=function(){return"first weekday"},e.prototype.weekdayNearestDayX0=function(){return"weekday nearest day %s"},e.prototype.commaOnTheX0OfTheMonth=function(){return", on the %s of the month"},e.prototype.commaEveryX0Days=function(){return", every %s days"},e.prototype.commaBetweenDayX0AndX1OfTheMonth=function(){return", between day %s and %s of the month"},e.prototype.commaOnDayX0OfTheMonth=function(){return", on day %s of the month"},e.prototype.commaEveryHour=function(){return", every hour"},e.prototype.commaEveryX0Years=function(){return", every %s years"},e.prototype.commaStartingX0=function(){return", starting %s"},e.prototype.daysOfTheWeek=function(){return["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},e.prototype.monthsOfTheYear=function(){return["January","February","March","April","May","June","July","August","September","October","November","December"]},e}();t.en=n},515:(e,t)=>{function n(e,t){if(!e)throw new Error(t)}Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(){}return e.secondRange=function(e){for(var t=e.split(","),r=0;r<t.length;r++)if(!isNaN(parseInt(t[r],10))){var i=parseInt(t[r],10);n(i>=0&&i<=59,"seconds part must be >= 0 and <= 59")}},e.minuteRange=function(e){for(var t=e.split(","),r=0;r<t.length;r++)if(!isNaN(parseInt(t[r],10))){var i=parseInt(t[r],10);n(i>=0&&i<=59,"minutes part must be >= 0 and <= 59")}},e.hourRange=function(e){for(var t=e.split(","),r=0;r<t.length;r++)if(!isNaN(parseInt(t[r],10))){var i=parseInt(t[r],10);n(i>=0&&i<=23,"hours part must be >= 0 and <= 23")}},e.dayOfMonthRange=function(e){for(var t=e.split(","),r=0;r<t.length;r++)if(!isNaN(parseInt(t[r],10))){var i=parseInt(t[r],10);n(i>=1&&i<=31,"DOM part must be >= 1 and <= 31")}},e.monthRange=function(e,t){for(var r=e.split(","),i=0;i<r.length;i++)if(!isNaN(parseInt(r[i],10))){var o=parseInt(r[i],10);n(o>=1&&o<=12,t?"month part must be >= 0 and <= 11":"month part must be >= 1 and <= 12")}},e.dayOfWeekRange=function(e,t){for(var r=e.split(","),i=0;i<r.length;i++)if(!isNaN(parseInt(r[i],10))){var o=parseInt(r[i],10);n(o>=0&&o<=6,t?"DOW part must be >= 0 and <= 6":"DOW part must be >= 1 and <= 7")}},e}();t["default"]=r},823:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),t.StringUtilities=void 0;var n=function(){function e(){}return e.format=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];return e.replace(/%s/g,function(e){for(var n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];return t.shift()})},e.containsAny=function(e,t){return t.some(function(t){return e.indexOf(t)>-1})},e}();t.StringUtilities=n}},t={};function n(r){var i=t[r];if(void 0!==i)return i.exports;var o=t[r]={exports:{}};return e[r](o,o.exports,n),o.exports}var i={};return(()=>{var e=i;Object.defineProperty(e,"__esModule",{value:!0}),e.toString=void 0;var t=n(333),r=n(747);t.ExpressionDescriptor.initialize(new r.enLocaleLoader),e["default"]=t.ExpressionDescriptor;var o=t.ExpressionDescriptor.toString;e.toString=o})(),i})())},5845:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".validation-message{padding:5px;position:absolute;bottom:-35px}",""]),t["default"]=s},43112:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,"#__layout,#__nuxt,#app,.vm-console,.vm-console>DIV,.vm-console>DIV>DIV,BODY,HTML,MAIN{height:100%}",""]),t["default"]=s},63766:function(e,t,n){"use strict";var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".xterm{cursor:text;position:relative;-moz-user-select:none;user-select:none;-ms-user-select:none;-webkit-user-select:none}.xterm.focus,.xterm:focus{outline:none}.xterm .xterm-helpers{position:absolute;top:0;z-index:5}.xterm .xterm-helper-textarea{padding:0;border:0;margin:0;position:absolute;opacity:0;left:-9999em;top:0;width:0;height:0;z-index:-5;white-space:nowrap;overflow:hidden;resize:none}.xterm .composition-view{background:#000;color:#fff;display:none;position:absolute;white-space:nowrap;z-index:1}.xterm .composition-view.active{display:block}.xterm .xterm-viewport{background-color:#000;overflow-y:scroll;cursor:default;position:absolute;right:0;left:0;top:0;bottom:0}.xterm .xterm-screen{position:relative}.xterm .xterm-screen canvas{position:absolute;left:0;top:0}.xterm-char-measure-element{display:inline-block;visibility:hidden;position:absolute;top:0;left:-9999em;line-height:normal}.xterm.enable-mouse-events{cursor:default}.xterm .xterm-cursor-pointer,.xterm.xterm-cursor-pointer{cursor:pointer}.xterm.column-select.focus{cursor:crosshair}.xterm .xterm-accessibility:not(.debug),.xterm .xterm-message{position:absolute;left:0;top:0;bottom:0;right:0;z-index:10;color:transparent;pointer-events:none}.xterm .xterm-accessibility-tree:not(.debug) ::-moz-selection{color:transparent}.xterm .xterm-accessibility-tree:not(.debug) ::selection{color:transparent}.xterm .xterm-accessibility-tree{font-family:monospace;-webkit-user-select:text;-moz-user-select:text;user-select:text;white-space:pre}.xterm .xterm-accessibility-tree>div{transform-origin:left;width:-moz-fit-content;width:fit-content}.xterm .live-region{position:absolute;left:-9999px;width:1px;height:1px;overflow:hidden}.xterm-dim{opacity:1!important}.xterm-underline-1{text-decoration:underline}.xterm-underline-2{-webkit-text-decoration:double underline;text-decoration:double underline}.xterm-underline-3{-webkit-text-decoration:wavy underline;text-decoration:wavy underline}.xterm-underline-4{-webkit-text-decoration:dotted underline;text-decoration:dotted underline}.xterm-underline-5{-webkit-text-decoration:dashed underline;text-decoration:dashed underline}.xterm-overline{text-decoration:overline}.xterm-overline.xterm-underline-1{text-decoration:overline underline}.xterm-overline.xterm-underline-2{-webkit-text-decoration:overline double underline;text-decoration:overline double underline}.xterm-overline.xterm-underline-3{-webkit-text-decoration:overline wavy underline;text-decoration:overline wavy underline}.xterm-overline.xterm-underline-4{-webkit-text-decoration:overline dotted underline;text-decoration:overline dotted underline}.xterm-overline.xterm-underline-5{-webkit-text-decoration:overline dashed underline;text-decoration:overline dashed underline}.xterm-strikethrough{text-decoration:line-through}.xterm-screen .xterm-decoration-container .xterm-decoration{z-index:6;position:absolute}.xterm-screen .xterm-decoration-container .xterm-decoration.xterm-decoration-top-layer{z-index:7}.xterm-decoration-overview-ruler{z-index:8;position:absolute;top:0;right:0;pointer-events:none}.xterm-decoration-top{z-index:2;position:relative}.xterm .xterm-scrollable-element>.scrollbar{cursor:default}.xterm .xterm-scrollable-element>.scrollbar>.scra{cursor:pointer;font-size:11px!important}.xterm .xterm-scrollable-element>.visible{opacity:1;background:transparent;transition:opacity .1s linear;z-index:11}.xterm .xterm-scrollable-element>.invisible{opacity:0;pointer-events:none}.xterm .xterm-scrollable-element>.invisible.fade{transition:opacity .8s linear}.xterm .xterm-scrollable-element>.shadow{position:absolute;display:none}.xterm .xterm-scrollable-element>.shadow.top{display:block;top:0;left:3px;height:3px;width:100%;box-shadow:var(--vscode-scrollbar-shadow,#000) 0 6px 6px -6px inset}.xterm .xterm-scrollable-element>.shadow.left{display:block;top:3px;left:0;height:100%;width:3px;box-shadow:var(--vscode-scrollbar-shadow,#000) 6px 0 6px -6px inset}.xterm .xterm-scrollable-element>.shadow.top-left-corner{display:block;top:0;left:0;height:3px;width:3px}.xterm .xterm-scrollable-element>.shadow.top.left{box-shadow:var(--vscode-scrollbar-shadow,#000) 6px 0 6px -6px inset}",""]),t.A=s},8199:function(e,t,n){"use strict";var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,'.d2h-wrapper{text-align:left}.d2h-file-header{background-color:#f7f7f7;border-bottom:1px solid #d8d8d8;display:flex;font-family:Source Sans Pro,Helvetica Neue,Helvetica,Arial,sans-serif;height:35px;padding:5px 10px}.d2h-file-header.d2h-sticky-header{position:sticky;top:0;z-index:1}.d2h-file-stats{display:flex;font-size:14px;margin-left:auto}.d2h-lines-added{border:1px solid #b4e2b4;border-radius:5px 0 0 5px;color:#399839;padding:2px;text-align:right;vertical-align:middle}.d2h-lines-deleted{border:1px solid #e9aeae;border-radius:0 5px 5px 0;color:#c33;margin-left:1px;padding:2px;text-align:left;vertical-align:middle}.d2h-file-name-wrapper{align-items:center;display:flex;font-size:15px;width:100%}.d2h-file-name{overflow-x:hidden;text-overflow:ellipsis;white-space:nowrap}.d2h-file-wrapper{margin-bottom:1em}.d2h-file-collapse,.d2h-file-wrapper{border:1px solid #ddd;border-radius:3px}.d2h-file-collapse{-webkit-box-pack:end;-ms-flex-pack:end;align-items:center;cursor:pointer;display:none;font-size:12px;justify-content:flex-end;padding:4px 8px}.d2h-file-collapse.d2h-selected{background-color:#c8e1ff}.d2h-file-collapse-input{margin:0 4px 0 0}.d2h-diff-table{border-collapse:collapse;font-family:Menlo,Consolas,monospace;font-size:13px;width:100%}.d2h-files-diff{display:flex;width:100%}.d2h-file-diff{overflow-y:hidden}.d2h-file-diff.d2h-d-none,.d2h-files-diff.d2h-d-none{display:none}.d2h-file-side-diff{display:inline-block;overflow-x:scroll;overflow-y:hidden;width:50%}.d2h-code-line{padding:0 8em}.d2h-code-line,.d2h-code-side-line{display:inline-block;-webkit-user-select:none;-moz-user-select:none;user-select:none;white-space:nowrap;width:100%}.d2h-code-side-line{padding:0 4.5em}.d2h-code-line-ctn{word-wrap:normal;background:none;display:inline-block;padding:0;-webkit-user-select:text;-moz-user-select:text;user-select:text;vertical-align:middle;white-space:pre;width:100%}.d2h-code-line del,.d2h-code-side-line del{background-color:#ffb6ba}.d2h-code-line del,.d2h-code-line ins,.d2h-code-side-line del,.d2h-code-side-line ins{border-radius:.2em;display:inline-block;margin-top:-1px;text-decoration:none;vertical-align:middle}.d2h-code-line ins,.d2h-code-side-line ins{background-color:#97f295;text-align:left}.d2h-code-line-prefix{word-wrap:normal;background:none;display:inline;padding:0;white-space:pre}.line-num1{float:left}.line-num1,.line-num2{box-sizing:border-box;overflow:hidden;padding:0 .5em;text-overflow:ellipsis;width:3.5em}.line-num2{float:right}.d2h-code-linenumber{background-color:#fff;border:solid #eee;border-width:0 1px;box-sizing:border-box;color:rgba(0,0,0,.3);cursor:pointer;display:inline-block;position:absolute;text-align:right;width:7.5em}.d2h-code-linenumber:after{content:"\\200b"}.d2h-code-side-linenumber{background-color:#fff;border:solid #eee;border-width:0 1px;box-sizing:border-box;color:rgba(0,0,0,.3);cursor:pointer;display:inline-block;overflow:hidden;padding:0 .5em;position:absolute;text-align:right;text-overflow:ellipsis;width:4em}.d2h-code-side-linenumber:after{content:"\\200b"}.d2h-code-side-emptyplaceholder,.d2h-emptyplaceholder{background-color:#f1f1f1;border-color:#e1e1e1}.d2h-code-line-prefix,.d2h-code-linenumber,.d2h-code-side-linenumber,.d2h-emptyplaceholder{-webkit-user-select:none;-moz-user-select:none;user-select:none}.d2h-code-linenumber,.d2h-code-side-linenumber{direction:rtl}.d2h-del{background-color:#fee8e9;border-color:#e9aeae}.d2h-ins{background-color:#dfd;border-color:#b4e2b4}.d2h-info{background-color:#f8fafd;border-color:#d5e4f2;color:rgba(0,0,0,.3)}.d2h-file-diff .d2h-del.d2h-change{background-color:#fdf2d0}.d2h-file-diff .d2h-ins.d2h-change{background-color:#ded}.d2h-file-list-wrapper{margin-bottom:10px}.d2h-file-list-wrapper a{color:#3572b0;text-decoration:none}.d2h-file-list-wrapper a:visited{color:#3572b0}.d2h-file-list-header{text-align:left}.d2h-file-list-title{font-weight:700}.d2h-file-list-line{display:flex;text-align:left}.d2h-file-list{display:block;list-style:none;margin:0;padding:0}.d2h-file-list>li{border-bottom:1px solid #ddd;margin:0;padding:5px 10px}.d2h-file-list>li:last-child{border-bottom:none}.d2h-file-switch{cursor:pointer;display:none;font-size:10px}.d2h-icon{fill:currentColor;margin-right:10px;vertical-align:middle}.d2h-deleted{color:#c33}.d2h-added{color:#399839}.d2h-changed{color:#d0b44c}.d2h-moved{color:#3572b0}.d2h-tag{background-color:#fff;display:flex;font-size:10px;margin-left:5px;padding:0 2px}.d2h-deleted-tag{border:1px solid #c33}.d2h-added-tag{border:1px solid #399839}.d2h-changed-tag{border:1px solid #d0b44c}.d2h-moved-tag{border:1px solid #3572b0}',""]),t.A=s},96696:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".dropdown-button-group .no-left-border-radius{border-top-left-radius:0;border-bottom-left-radius:0}.dropdown-button-group .no-right-border-radius{border-top-right-radius:0;border-bottom-right-radius:0}.dropdown-button-group .btn{line-height:normal;border:0}.dropdown-button-group .btn-group-xs>.btn,.dropdown-button-group .btn-xs,.dropdown-button-group .btn-xs .btn-label{padding:2px 3px;font-size:13px}.dropdown-button-group .v-popper .text-right{margin-top:5px}.dropdown-button-group .v-popper .trigger{height:100%}.dropdown-button-group .v-popper .trigger .icon-container{height:100%;padding:10px 10px 10px 10px}.dropdown-button-group .v-popper .trigger .icon-container i{transform:scale(1)}.dropdown-button-group .v-popper .trigger .icon-container.btn-xs{padding:2px 4px 4px 4px}.dropdown-button-group .v-popper .trigger .icon-container.btn-sm{padding:10px 10px 10px 10px}.dropdown-button-group .v-popper .trigger .icon-container.btn-lg{padding:18px 10px 10px 10px}.dropdown-button-group .v-popper .trigger .icon-container:focus{outline-style:none;box-shadow:none;border-color:transparent}.dropdown-button-group .dropdown-button{background:var(--tooltip-bg);color:var(--link-text);padding:0;display:inline-flex}.dropdown-button-group .dropdown-button .wrapper-content button{border-right:0}.dropdown-button-group .dropdown-button .icon-chevron-down,.dropdown-button-group .dropdown-button>*{color:var(--primary);background-color:transparent}.dropdown-button-group .dropdown-button.bg-primary:hover{background:var(--accent-btn-hover)}.dropdown-button-group .dropdown-button.one-action{position:relative}.dropdown-button-group .dropdown-button.one-action>.btn{padding:15px 35px 15px 15px}.dropdown-button-group .dropdown-button.one-action .v-popper .trigger{position:absolute;top:0;right:0;left:0;bottom:0}.dropdown-button-group .dropdown-button.one-action .v-popper .trigger BUTTON{position:absolute;right:0}.dropdown-button-group .v-popper__popper{border:none;margin-top:0}.dropdown-button-group .v-popper__popper[data-popper-placement^=bottom] .v-popper__arrow-container{display:none}.dropdown-button-group .v-popper__popper .v-popper__inner{color:var(--dropdown-text);background-color:var(--dropdown-bg);border:1px solid var(--dropdown-border);padding:0;text-align:left}.dropdown-button-group .v-popper__popper .v-popper__inner LI{padding:10px}.dropdown-button-group .v-popper__popper .v-popper__inner LI.divider{padding-top:0;padding-bottom:0}.dropdown-button-group .v-popper__popper .v-popper__inner LI.divider>.divider-inner{padding:0;border-bottom:1px solid var(--dropdown-divider);width:125%;margin:0 auto}.dropdown-button-group .v-popper__popper .v-popper__inner LI:not(.divider):hover{background-color:var(--dropdown-hover-bg);color:var(--dropdown-hover-text);cursor:pointer}.dropdown-button-group .user-info{border-bottom:1px solid var(--border);display:block}",""]),t["default"]=s},36942:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".menu[data-v-375e9eb4],.root[data-v-375e9eb4]{position:absolute}.menu[data-v-375e9eb4]{visibility:hidden;top:0;left:0;z-index:56;min-width:145px;color:var(--dropdown-text);background-color:var(--dropdown-bg);border:1px solid var(--dropdown-border);border-radius:5px;box-shadow:0 5px 20px var(--shadow)}.menu LI[data-v-375e9eb4]{align-items:center;display:flex;padding:8px 10px;margin:0}.menu LI[data-v-375e9eb4]:focus-visible{outline:2px solid var(--primary-keyboard-focus);outline-offset:-2px}.menu LI[disabled][data-v-375e9eb4]{cursor:not-allowed!important;color:var(--disabled-text)}.menu LI.divider[data-v-375e9eb4]{padding:0;border-bottom:1px solid var(--dropdown-divider)}.menu LI[data-v-375e9eb4]:not(.divider):hover{background-color:var(--dropdown-hover-bg);color:var(--dropdown-hover-text);cursor:pointer}.menu LI .icon[data-v-375e9eb4]{display:unset;width:14px;text-align:center;margin-right:8px}.menu LI.no-actions[data-v-375e9eb4],.menu LI.no-actions[data-v-375e9eb4]:hover{color:var(--disabled-text)}.menu LI.no-actions[data-v-375e9eb4]:hover{background-color:initial;cursor:default}.background[data-v-375e9eb4]{position:fixed;top:0;left:0;right:0;bottom:0;opacity:0;z-index:55}",""]),t["default"]=s},97301:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".modal-overlay{position:absolute;top:0;left:0;width:100vw;height:100vh;background-color:var(--overlay-bg);display:flex;justify-content:center;align-items:center;z-index:53}.modal-overlay .modal-container{background-color:var(--modal-bg);border-radius:var(--border-radius);max-height:95vh;overflow:auto;border:2px solid var(--modal-border)}.modal-fade-enter-active,.modal-fade-leave-active{transition:opacity .2s}.modal-fade-enter,.modal-fade-leave-to{opacity:0}",""]),t["default"]=s},46962:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".manual-refresh i[data-v-045ed346]{margin:0 0 0 8px!important;font-size:1rem!important}",""]),t["default"]=s},31912:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".banner-graphic-area[data-v-2692661e]{position:relative}.banner-graphic-area .graphic[data-v-2692661e]{display:flex;flex-direction:column;overflow:hidden}.banner-graphic-area .graphic>img.banner[data-v-2692661e]{flex:1;-o-object-fit:cover;object-fit:cover}.banner-graphic-area .title[data-v-2692661e]{display:flex;align-items:center;position:absolute;text-align:center;top:0;height:100%;width:100%}.banner-graphic-area.banner-text-center .title[data-v-2692661e]{justify-content:center;margin-top:-20px}.banner-graphic-area.banner-text-left .title[data-v-2692661e]{justify-content:left;padding-left:5%}@media only screen and (max-width:992px){.banner-graphic-area.banner-text-left .title[data-v-2692661e]{padding-left:20px}}.banner-graphic-height[data-v-2692661e]{height:var(--banner-graphic-height,200px)}",""]),t["default"]=s},31354:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".button-dropdown.btn-sm[data-v-2ab9ff7a] >.vs__dropdown-toggle .vs__actions:after{font-size:1.6rem}.button-dropdown.btn-lg[data-v-2ab9ff7a] >.vs__dropdown-toggle .vs__actions:after{font-size:2.6rem}.button-dropdown[data-v-2ab9ff7a]{background:var(--accent-btn);border:solid 1px var(--link);color:var(--link);padding:0}.button-dropdown.vs--open[data-v-2ab9ff7a] {outline:none;box-shadow:none}.button-dropdown[data-v-2ab9ff7a]:hover .vs__dropdown-toggle .vs__actions,.button-dropdown[data-v-2ab9ff7a]:hover .vs__selected-options{background:var(--accent-btn-hover)}.button-dropdown[data-v-2ab9ff7a]:hover .vs__selected-options .vs__selected button{background-color:transparent;color:var(--accent-btn-hover-text)}.button-dropdown[data-v-2ab9ff7a]:hover .vs__dropdown-toggle .vs__actions:after{color:var(--accent-btn-hover-text)}.button-dropdown[data-v-2ab9ff7a] >.vs__dropdown-toggle{width:100%;display:grid;grid-template-columns:75% 25%;border:none;background:transparent}.button-dropdown[data-v-2ab9ff7a] >.vs__dropdown-toggle .vs__actions:after{color:var(--link);line-height:1}.button-dropdown[data-v-2ab9ff7a] .vs__selected-options .vs__selected{margin:unset;border:none}.button-dropdown[data-v-2ab9ff7a] .vs__selected-options .vs__selected button{border:none;background:transparent;color:var(--link)}.button-dropdown[data-v-2ab9ff7a] .vs__selected-options .vs__search{position:absolute;opacity:0;padding:0}.button-dropdown[data-v-2ab9ff7a] .vs__dropdown-menu{min-width:unset;width:-moz-fit-content;width:fit-content}",""]),t["default"]=s},21483:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".btn-group .btn-md[data-v-d29e11fe]{padding:0 12px;min-height:32px;line-height:32px}",""]),t["default"]=s},53184:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".borderless[data-v-a3361b40]{background-color:transparent;border:none}.borderless[data-v-a3361b40]:focus-visible{outline:2px solid var(--primary-keyboard-focus);outline-offset:-2px}.borderless[data-v-a3361b40]:focus,.borderless[data-v-a3361b40]:hover{background-color:var(--accent-btn);box-shadow:none}",""]),t["default"]=s},57178:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".code-mirror{position:relative;margin-bottom:20px}.code-mirror .codemirror-container{z-index:0;font-size:inherit!important}.code-mirror .codemirror-container .rc-code-mirror .rc-cm-escape-hint{top:auto;right:auto;bottom:-20px;left:0;padding:0;color:inherit;background-color:transparent}.code-mirror>.codemirror-container{display:block;width:auto;height:auto;overflow:visible}",""]),t["default"]=s},33289:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,"h2[data-v-50534f1b]{display:flex;align-items:center}h2 i[data-v-50534f1b]{font-size:12px;margin-left:5px}.support-link[data-v-50534f1b]:not(:last-child){margin-bottom:15px}",""]),t["default"]=s},86249:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".icon-btn[data-v-87bbedf0]{min-height:24px;min-width:24px;justify-content:center}.bg-transparent[data-v-87bbedf0]:active{background-color:var(--primary-keyboard-focus);color:var(--primary-text)}.bg-transparent[data-v-87bbedf0]:focus-visible{outline:2px solid var(--primary-keyboard-focus)}.role-primary[data-v-87bbedf0]:active{background-color:var(--primary-keyboard-focus);color:var(--primary-text)}",""]),t["default"]=s},18983:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".subtype-body .title .subtype-name[data-v-91e14576]{margin:0}.cru-resource-yaml-container .resource-yaml .yaml-editor[data-v-91e14576]{min-height:100px}.create-resource-container .resource-container[data-v-91e14576]{display:flex;flex-direction:column}.create-resource-container .subtype-banner .round-image[data-v-91e14576]{background-color:var(--primary)}.create-resource-container .subtype-banner[data-v-91e14576]:focus-visible{outline:2px solid var(--primary-keyboard-focus)}.title[data-v-91e14576]{margin-top:20px}.title.with-description[data-v-91e14576]{margin-top:0}.subtype-container[data-v-91e14576]{position:relative;display:flex;height:100%}.subtype-body[data-v-91e14576]{flex:1;padding:10px}.subtype-logo[data-v-91e14576]{align-items:center;display:flex;justify-content:center;min-width:100px;min-height:100px;overflow:hidden;background-color:var(--box-bg)}.subtype-logo img[data-v-91e14576]{width:56px;height:56px;-o-object-fit:contain;object-fit:contain;position:relative;top:2px}form.create-resource-container .cru__footer[data-v-91e14576]{border-top:var(--header-border-size) solid var(--header-border)}.cru[data-v-91e14576],.cru__form[data-v-91e14576]{display:flex;flex-direction:column;flex-grow:1}.cru__toc[data-v-91e14576]{width:250px;margin:20px var(--gap-lg) 20px var(--gap-lg);min-width:250px;max-width:250px;position:sticky;top:24px;align-self:flex-start;max-height:var(--toc-container-height,calc(100vh - 209px - var(--gap-lg)*2));transition:max-height 50ms ease-in-out;overflow-y:auto;overflow-x:hidden}.cru__content[data-v-91e14576]{flex-grow:1}.cru__content-wizard[data-v-91e14576]{display:flex}.cru__footer[data-v-91e14576]{right:0;bottom:0;height:60px;box-sizing:border-box;margin-left:-24px;margin-right:-24px;margin-bottom:-24px;padding:10px 24px}.cru__errors[data-v-91e14576],.cru__footer[data-v-91e14576]{position:sticky;background-color:var(--header-bg)}.cru__errors[data-v-91e14576]{top:0;z-index:1;margin:10px 0}.show-toc.cru>.cru__form[data-v-91e14576]{display:grid;grid-template-columns:[content] 1fr [toc] calc(250px + var(--gap-lg));grid-template-rows:[errors] auto [content] 1fr [footer] min-content}.show-toc.cru>.cru__form>.cru__errors[data-v-91e14576]{grid-column:content;grid-row:errors}.show-toc.cru>.cru__form>.cru__toc[data-v-91e14576]{grid-column:toc;grid-row:errors/footer}.show-toc.cru>.cru__form>.cru__content[data-v-91e14576]{grid-column:content;grid-row:content}.show-toc.cru>.cru__form>.cru__footer[data-v-91e14576]{grid-column:content/3;grid-row:footer}@media(max-width:992px){.show-toc.cru>.cru__form[data-v-91e14576]{display:flex;grid-template-columns:none;grid-template-rows:none}.show-toc.cru>.cru__form>.cru__toc[data-v-91e14576]{display:none}}.description[data-v-91e14576]{margin-bottom:15px;margin-top:5px}",""]),t["default"]=s},18956:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".cru-resource-footer{display:flex;justify-content:flex-end;margin-top:20px;z-index:19}.cru-resource-footer .btn{margin-left:20px}",""]),t["default"]=s},80288:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,'.with-copy[data-v-60495cfd]{border:solid 1px var(--border);padding:10px;position:relative;background-color:var(--input-bg);border-radius:var(--border-radius);border:solid var(--border-width) var(--input-border);contain:inline-size}.with-copy h5[data-v-60495cfd]{margin-bottom:15px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;width:-moz-fit-content;width:fit-content;max-width:calc(100% - 150px)}.with-copy .conceal-wrapper[data-v-60495cfd]{overflow-x:auto;padding-bottom:10px;margin-bottom:-10px}.with-copy .conceal[data-v-60495cfd]{white-space:nowrap;display:block}.with-copy .conceal[data-v-60495cfd]:before{content:"••••••••••••••••••••••••"}.with-copy .action-group[data-v-60495cfd]{position:absolute;top:-1px;right:-1px;white-space-collapse:collapse;display:flex;flex-direction:row;justify-content:flex-end}.with-copy .action-group button[data-v-60495cfd]{border-radius:0}.with-copy .action-group button[data-v-60495cfd]:first-of-type{border-radius:0 0 0 var(--border-radius)}.with-copy .action-group button.sensitive[data-v-60495cfd]{margin-right:-1px;padding:12px 16px}.monospace[data-v-60495cfd]{white-space:pre-wrap}.editable[data-v-60495cfd]{display:block;width:100%;min-height:120px;padding:0;border:0;background:transparent;color:var(--input-text);resize:vertical;overflow-wrap:anywhere}.editable[data-v-60495cfd]:focus-visible{outline:1px solid var(--outline)}.more-characters[data-v-60495cfd]{margin-top:8px;display:inline-block}',""]),t["default"]=s},61250:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".detail-text-tooltip.v-popper__popper.v-popper--theme-tooltip{overflow-wrap:anywhere}",""]),t["default"]=s},6618:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,'.detail-top:not(.empty){padding-top:10px;border-top:1px solid var(--border);margin-top:10px}.detail-top .namespaceLinkList:not(:first-child):before{content:", "}.detail-top .tags{display:inline-flex;flex-direction:row;flex-wrap:wrap;position:relative;top:-2px}.detail-top .tags .label{position:relative;top:4px}.detail-top .tags .tag{margin:2px 4px 0 2px;font-size:12px}.detail-top .annotation{margin-top:10px}.detail-top .label{color:var(--input-label);margin:0 4px 0 0}.detail-top__label-button{padding:4px}.detail-top .details{display:flex;flex-direction:row;flex-wrap:wrap}.detail-top .details .detail{margin-right:20px;margin-bottom:3px}.detail-top .details:not(:first-of-type){margin-top:3px}.detail-top>div:not(:last-of-type){margin-bottom:4px}.detail-top .icon{vertical-align:top}',""]),t["default"]=s},83852:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".chrome[data-v-470bd9ef]{position:absolute;top:0;bottom:0;left:0;right:0;display:flex;flex-direction:column}.chrome>.header[data-v-470bd9ef]{display:flex;flex-direction:row;align-items:center;background-color:var(--body-bg);border-bottom:1px solid var(--border);height:var(--header-height)}.chrome>.header>.title[data-v-470bd9ef]{display:flex;align-items:center;flex:1;font-size:16px}.chrome>.header>.actions button[data-v-470bd9ef]{display:inline-flex;width:24px;height:24px;color:var(--body-text);justify-content:center}.chrome .body[data-v-470bd9ef]{background-color:var(--drawer-body-bg);flex:1;overflow-y:scroll}.chrome .footer[data-v-470bd9ef]{display:flex;flex-direction:row;justify-content:flex-end;background-color:var(--body-bg);border-top:1px solid var(--border);height:72px}.chrome .footer .actions[data-v-470bd9ef]>*{margin-left:16px}",""]),t["default"]=s},80172:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".drawer-card[data-v-9f186538]{background-color:var(--body-bg);border-radius:var(--border-radius-md);padding:16px;max-width:100%;width:100%;position:relative}",""]),t["default"]=s},37899:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".config-tab[data-v-7d0d0cce] .overlay-content-mode{left:0;top:0}.config-tab[data-v-7d0d0cce] .cru-resource-footer{display:none}",""]),t["default"]=s},49630:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".yaml-tab[data-v-3f619296] .codemirror-container{background-color:var(--body-bg);border-radius:var(--border-radius-md);padding:16px}",""]),t["default"]=s},51758:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".empty-product-page[data-v-53430412]{align-items:center;display:flex;justify-content:center;opacity:.75}.empty-product-page>img[data-v-53430412]{width:128px;margin-bottom:20px}.empty-product-page .err-messages[data-v-53430412]{display:flex;align-items:center;text-align:center;flex-direction:column}.empty-product-page .err-messages[data-v-53430412]>*{margin-bottom:8px;font-size:16px}.empty-product-page .err-messages[data-v-53430412]>:last-child{font-weight:700;color:var(--error)}",""]),t["default"]=s},98824:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".invisible[data-v-d8cca17c]{display:inline-block;min-width:28px}.project-namespaces[data-v-d8cca17c] .project-name{line-height:30px}.project-namespaces[data-v-d8cca17c] .project-bar{contain:inline-size;display:flex;flex-direction:row;justify-content:space-between}.project-namespaces[data-v-d8cca17c] .project-bar .group-tab{max-width:calc(100% - 230px)}.project-namespaces[data-v-d8cca17c] .project-bar .project-name{display:flex;flex-direction:row;align-items:center}.project-namespaces[data-v-d8cca17c] .project-bar .project-name span:first-child{padding-right:8px}.project-namespaces[data-v-d8cca17c] .project-bar .project-name span:last-child{text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.project-namespaces[data-v-d8cca17c] .project-bar.has-description .right{margin-top:5px}.project-namespaces[data-v-d8cca17c] .project-bar.has-description .group-tab,.project-namespaces[data-v-d8cca17c] .project-bar.has-description .group-tab:after{height:50px}.project-namespaces[data-v-d8cca17c] .project-bar.has-description .group-tab:after{right:-20px}.project-namespaces[data-v-d8cca17c] .project-bar.has-description .group-tab .description{margin-top:-20px}.project-namespaces[data-v-d8cca17c] .namespace-name{display:flex;align-items:center}.project-namespaces[data-v-d8cca17c] .namespace-name .icon-istio{color:var(--primary)}",""]),t["default"]=s},91890:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".psa-tooltip{margin:3px 0;padding:0 8px 0 22px}",""]),t["default"]=s},4738:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".fail-whale.error[data-v-44d3cb5a]{height:100%;display:flex;flex-direction:column;flex:1;justify-content:center;overflow:hidden}.fail-whale.error .row[data-v-44d3cb5a]{align-items:center}.fail-whale.error h1[data-v-44d3cb5a]{font-size:5rem}",""]),t["default"]=s},9299:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".root[data-v-639a852a]{max-width:100%;position:relative;overflow:auto}",""]),t["default"]=s},20602:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=n(8199),l=a()(i());l.i(s.A),l.push([e.id,"[data-v-639a852a] .d2h-wrapper .d2h-file-header{display:none}[data-v-639a852a] .d2h-wrapper .d2h-file-wrapper{border-color:var(--diff-border)}[data-v-639a852a] .d2h-wrapper .d2h-diff-table{font-family:Menlo,Consolas,monospace;font-size:13px}[data-v-639a852a] .d2h-wrapper .d2h-code-side-emptyplaceholder,[data-v-639a852a] .d2h-wrapper .d2h-emptyplaceholder{border-color:var(--diff-linenum-border);background-color:var(--diff-empty-placeholder)}[data-v-639a852a] .d2h-wrapper .d2h-code-linenumber,[data-v-639a852a] .d2h-wrapper .d2h-code-side-linenumber{background-color:var(--diff-linenum-bg);color:var(--diff-linenum);border-color:var(--diff-linenum-border);border-left:0}[data-v-639a852a] .d2h-wrapper .d2h-code-line del,[data-v-639a852a] .d2h-wrapper .d2h-code-side-line del{background-color:var(--diff-line-del-bg)}[data-v-639a852a] .d2h-wrapper .d2h-code-line ins,[data-v-639a852a] .d2h-wrapper .d2h-code-side-line ins{background-color:var(--diff-line-ins-bg)}[data-v-639a852a] .d2h-wrapper .d2h-del{background-color:var(--diff-del-bg);border-color:var(--diff-del-border);color:var(--body-text)}[data-v-639a852a] .d2h-wrapper .d2h-ins{background-color:var(--diff-ins-bg);border-color:var(--diff-ins-border);color:var(--body-text)}[data-v-639a852a] .d2h-wrapper .d2h-info{background-color:var(--diff-header-bg);color:var(--diff-header);border-color:var(--diff-header-border)}[data-v-639a852a] .d2h-wrapper .d2h-file-diff .d2h-del.d2h-change{background-color:var(--diff-chg-del)}[data-v-639a852a] .d2h-wrapper .d2h-file-diff .d2h-ins.d2h-change{background-color:var(--diff-chg-ins)}",""]),t["default"]=l},71124:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".vertical[data-v-01996ade]{flex-direction:column;width:100%}.subtle[data-v-01996ade]{opacity:.7}.message-icon[data-v-01996ade]{display:flex;align-items:center;justify-content:center;flex:1;flex-direction:column}.message-icon>I[data-v-01996ade]{font-size:64px;margin-bottom:20px}.message-icon>I.info[data-v-01996ade]{color:var(--primary)}.message-icon>I.error[data-v-01996ade]{color:var(--error)}.message-icon>I.warning[data-v-01996ade]{color:var(--warning)}.message-icon>I.success[data-v-01996ade]{color:var(--success)}.message-icon>.message[data-v-01996ade]{font-size:20px;margin-bottom:40px;max-width:60%;text-align:center;line-height:30px}",""]),t["default"]=s},9570:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,"img.svg-icon[data-v-2e8d063a]{filter:var(--v6579a48c)}button:hover>img.svg-icon[data-v-2e8d063a],li:hover>img.svg-icon[data-v-2e8d063a]{filter:var(--v0ae929cb)}.side-menu .category div a>img.svg-icon[data-v-2e8d063a]{height:24px;width:24px;filter:var(--v6579a48c)}.side-menu .category div a:hover>img.svg-icon[data-v-2e8d063a]{filter:var(--v0ae929cb)}.side-menu .category div a.active-menu-link>img.svg-icon[data-v-2e8d063a],.side-menu .category div a.active-menu-link>img.svg-icon[data-v-2e8d063a]:hover{filter:var(--v55a59307)}",""]),t["default"]=s},83234:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".indented-panel{height:100%;width:90%;margin-left:5%}@media only screen and (max-width:992px){.indented-panel{margin:0 20px;width:auto}}",""]),t["default"]=s},98343:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".info-box[data-v-4f4f1f5e]{border:1px solid var(--tabbed-border);padding:10px;margin-bottom:20px;border-radius:var(--border-radius);flex-grow:1;flex-basis:0;position:relative}.info-box .stepped[data-v-4f4f1f5e]{padding-left:40px}.info-box .step-number[data-v-4f4f1f5e]{border-radius:var(--border-radius);background:var(--secondary);color:var(--input-text);display:inline-block;padding:5px 10px}.info-box .step-list[data-v-4f4f1f5e]{margin:0}.info-box .info-column[data-v-4f4f1f5e]:not(:last-child){border-right:1px solid var(--tabbed-border)}.info-box .info-row[data-v-4f4f1f5e]{margin-bottom:10px}.info-box .info-row .info-row-label[data-v-4f4f1f5e]{padding-top:2px;display:inline-block}.info-box .info-column label[data-v-4f4f1f5e],.info-box .info-row label[data-v-4f4f1f5e]{color:var(--input-label)}.info-box .info-column .usage[data-v-4f4f1f5e]{margin-bottom:10px}.info-box .info-column .usage label[data-v-4f4f1f5e]{display:inline-block;font-size:12px;padding-top:6px}.info-box .info-column .flex-item-half[data-v-4f4f1f5e]{align-items:center}",""]),t["default"]=s},58749:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".overlay[data-v-c3588e48]{align-items:center;background-color:var(--subtle-overlay-bg);display:flex;justify-content:center;position:absolute;bottom:0;top:0;left:0;right:0;text-align:center;z-index:12}.overlay-main-mode[data-v-c3588e48]{top:var(--header-height);z-index:51}.overlay-content-mode[data-v-c3588e48]{left:calc(var(--nav-width));top:var(--header-height)}",""]),t["default"]=s},56530:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".percentage-bar[data-v-4ade54a6]{display:flex;flex-direction:row}.percentage-bar .percentage-value[data-v-4ade54a6]{word-break:keep-all}",""]),t["default"]=s},51558:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".progress[data-v-154bda8a]{display:block;border-radius:90px;background-color:var(--progress-bg);height:10px;width:100px}.progress .piece[data-v-154bda8a]{display:inline-block;height:10px;border-radius:0;border-right:1px solid var(--progress-divider);vertical-align:top}.progress .piece[data-v-154bda8a]:first-child{border-top-left-radius:90px;border-bottom-left-radius:90px}.progress .piece[data-v-154bda8a]:last-child{border-top-right-radius:90px;border-bottom-right-radius:90px;border-right:0}.piece.bg-success[data-v-154bda8a]:only-child{opacity:.5}",""]),t["default"]=s},4025:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".more[data-v-53ecaf14]{margin-top:4px;cursor:help;font-size:.8em}",""]),t["default"]=s},1777:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".message[data-v-3eb6f915]{margin:0;margin-top:-2px;line-height:20px}",""]),t["default"]=s},94739:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".vertical-gap[data-v-43905492]{height:12px}",""]),t["default"]=s},26374:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".detail-card[data-v-ecc6c722]{padding:16px;border-radius:var(--border-radius-md);border:1px solid var(--border)}.detail-card .heading[data-v-ecc6c722]{display:flex;justify-content:space-between;align-items:center;height:32px}.detail-card .heading .title[data-v-ecc6c722]{font-size:18px;font-weight:600;line-height:21px}.detail-card .body[data-v-ecc6c722]{display:flex;flex-direction:column;justify-content:flex-start}",""]),t["default"]=s},2582:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".copy-to-clipboard[data-v-24cd76d6]{z-index:2;display:inline-flex;width:36px;height:36px;font-size:14px;border-radius:50%;justify-content:center;align-items:center;padding:0;line-height:normal;min-height:auto;border:1px solid var(--primary);color:var(--primary);background-color:var(--body-bg)}.copy-to-clipboard[data-v-24cd76d6]:hover{color:var(--body-text)}.copy-to-clipboard.copied[data-v-24cd76d6]{background-color:var(--success);border-color:var(--success-border);color:var(--success-text);transition:background-color .25s ease,border-color .25s ease,color .25s ease}.copy-to-clipboard[data-v-24cd76d6]:focus-visible{outline:2px solid var(--primary-keyboard-focus)}",""]),t["default"]=s},43431:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".identifying-information[data-v-e12d7178]{display:flex;flex-direction:column}.identifying-information .row[data-v-e12d7178]{display:flex;align-items:center;gap:8px}.identifying-information .row[data-v-e12d7178]:after,.identifying-information .row[data-v-e12d7178]:before{display:none}.identifying-information .row[data-v-e12d7178]:not(:last-of-type){margin-bottom:8px}.identifying-information .row .full-custom-value[data-v-e12d7178]{flex:1;min-width:0}.identifying-information .row .full-custom-value[data-v-e12d7178] .popover-card-target{width:100%}.identifying-information .row .value[data-v-e12d7178]{display:flex;flex-direction:row;align-items:center;flex:1}.identifying-information .row .value>div[data-v-e12d7178],.identifying-information .row .value>span[data-v-e12d7178]{max-width:100%}.identifying-information .row .value[data-v-e12d7178],.identifying-information .row .value>div[data-v-e12d7178],.identifying-information .row .value>span[data-v-e12d7178]{text-overflow:ellipsis;overflow:hidden;white-space:nowrap;word-wrap:break-word}.identifying-information .row .label[data-v-e12d7178]{width:30%;min-width:-moz-min-content;min-width:min-content}.identifying-information .row .status[data-v-e12d7178]{display:inline-block;border-radius:50%;width:8px;height:8px;margin-right:12px}.identifying-information .row .status.success[data-v-e12d7178]{background-color:var(--success)}.identifying-information .row .status.warning[data-v-e12d7178]{background-color:var(--warning)}.identifying-information .row .status.error[data-v-e12d7178]{background-color:var(--error)}.identifying-information .row .status.info[data-v-e12d7178]{background-color:var(--info)}",""]),t["default"]=s},97491:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".key-value[data-v-64f8c824]{display:flex;flex-direction:column;align-items:flex-start}.key-value .count[data-v-64f8c824]{margin-left:24px}.key-value .heading[data-v-64f8c824]{margin-bottom:8px}.key-value .row[data-v-64f8c824]{display:inline-block;width:100%}.key-value .row[data-v-64f8c824]:after,.key-value .row[data-v-64f8c824]:before{display:none}.key-value .row[data-v-64f8c824]:not(:nth-child(2)){margin-top:4px}.key-value .show-all[data-v-64f8c824]{margin-top:8px}.key-value .no-rows[data-v-64f8c824]{line-height:21px}",""]),t["default"]=s},28360:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".key-value-row[data-v-cd4e2248]{display:inline-block;position:relative;padding:0}.key-value-row .copy-to-clipboard[data-v-cd4e2248]{position:fixed;right:-20px;top:-100vh;z-index:20}.key-value-row[data-v-cd4e2248],.key-value-row .btn[data-v-cd4e2248],.key-value-row .rc-tag[data-v-cd4e2248]{max-width:100%}.key-value-row .tag-data[data-v-cd4e2248]{display:inline-block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0;max-width:100%;line-height:1}.key-value-row .btn.btn-medium.rc-button.variant-ghost[data-v-cd4e2248]{line-height:normal;min-height:auto;padding:0}.key-value-row.active.show-preview .copy-to-clipboard[data-v-cd4e2248]{position:fixed}.key-value-row.active .copy-to-clipboard:focus-visible .rc-tag .tag-data[data-v-cd4e2248],.key-value-row.active button:focus-visible .rc-tag .tag-data[data-v-cd4e2248],.key-value-row.active button:hover .rc-tag .tag-data[data-v-cd4e2248]{padding-right:22px}.key-value-row.active .copy-to-clipboard:focus-visible+.copy-to-clipboard[data-v-cd4e2248],.key-value-row.active button:focus-visible+.copy-to-clipboard[data-v-cd4e2248],.key-value-row.active button:hover+.copy-to-clipboard[data-v-cd4e2248]{position:absolute;top:-6px}.key-value-row.active .copy-to-clipboard[data-v-cd4e2248]:focus-visible,.key-value-row.active .copy-to-clipboard[data-v-cd4e2248]:hover{position:absolute;top:-6px}.key-value-row.active .btn:has(+.copy-to-clipboard:focus-visible) .rc-tag .tag-data[data-v-cd4e2248],.key-value-row.active .btn:has(+.copy-to-clipboard:hover) .rc-tag .tag-data[data-v-cd4e2248]{padding-right:22px}",""]),t["default"]=s},46571:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".metadata .identifying-info[data-v-74b4d1b7]{min-width:0}.metadata .labels-and-annotations-empty[data-v-74b4d1b7]{grid-column:span 2}",""]),t["default"]=s},78359:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,"[data-v-a4c0d9ce] .cm-gutters{display:none}",""]),t["default"]=s},9567:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".preview-mouse-catcher[data-v-79b3e65a]{cursor:default;position:fixed;top:0;bottom:0;left:0;right:0;z-index:120}.preview[data-v-79b3e65a]{cursor:default;position:fixed;right:var(--v00bc9ff6);top:var(--e48f64a2);z-index:121;display:flex;flex-direction:column;min-width:420px;max-width:550px;max-height:550px;padding:16px;background-color:var(--body-bg);border:1px solid var(--border);border-radius:var(--border-radius-md)}.preview[data-v-79b3e65a]:focus{outline:none}.preview .title[data-v-79b3e65a]{margin-bottom:16px;font-size:14px;font-style:normal;font-weight:400}.preview .content[data-v-79b3e65a]{flex:1;overflow:auto;padding:1px 0}.preview .copy-to-clipboard[data-v-79b3e65a]{position:absolute;right:-8px;top:-8px}",""]),t["default"]=s},70624:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".spaced-row[data-v-be2be6f0]{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));grid-auto-flow:dense;grid-gap:24px;justify-content:space-evenly;min-width:740px}",""]),t["default"]=s},6772:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,"h1.title[data-v-1e04f798]{display:inline-block;align-items:center;display:flex;flex-direction:row}",""]),t["default"]=s},97867:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".top[data-v-9aaa96a4]{display:flex;flex-direction:row;justify-content:space-between;align-items:center}",""]),t["default"]=s},50399:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".title-bar[data-v-01615b82]{min-width:740px}.title-bar .badge-state[data-v-01615b82]{font-size:16px;margin-left:12px;position:relative;flex:0 0 auto}.title-bar .actions[data-v-01615b82]{display:flex;align-items:center;flex:0 0 auto;margin-left:16px}.title-bar .show-configuration[data-v-01615b82],.title-bar[data-v-01615b82] .actions>button{margin-left:16px}.title-bar[data-v-01615b82] button[data-testid=masthead-action-menu]{border-radius:4px;width:35px;height:40px;margin-left:16px;display:inline-flex;flex-direction:row;justify-content:center;align-items:center}.title-bar .description[data-v-01615b82]{max-width:60%}.title-bar .title-row[data-v-01615b82]{display:flex;align-items:center;flex:1 1 auto;min-width:0;margin-bottom:10px}.title-bar .title[data-v-01615b82]{min-width:0;margin-bottom:0}.title-bar .resource-name[data-v-01615b82]{display:inline-block;flex:0 1 auto;min-width:0;white-space:nowrap;overflow-x:hidden;overflow-y:clip;text-overflow:ellipsis;margin-left:4px}",""]),t["default"]=s},40143:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".confirm-modal .btn[data-v-fa4a262e]{margin:0 10px}.confirm-modal .body[data-v-fa4a262e]{min-height:75px;padding:10px 0 0 15px}.confirm-modal .body p[data-v-fa4a262e]{margin-top:10px}.confirm-modal .header[data-v-fa4a262e]{background-color:var(--error);padding:15px 0 0 15px;height:50px}.confirm-modal .header h4[data-v-fa4a262e]{color:#fff}.confirm-modal .footer[data-v-fa4a262e]{border-top:1px solid var(--border);text-align:center;padding:10px 0 0 15px;height:60px}",""]),t["default"]=s},61446:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".new.state-banner[data-v-7f6314f2]{margin:0;margin-top:16px}",""]),t["default"]=s},77612:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".new.state-banner[data-v-356623d7]{margin:0;margin-top:16px}[data-v-356623d7] .metadata-section{margin-top:16px;margin-bottom:24px}.cards-section[data-v-356623d7]{margin:0;margin-bottom:24px}",""]),t["default"]=s},25309:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".masthead[data-v-0f75302f]{padding-bottom:10px;border-bottom:1px solid var(--border);margin-bottom:10px}HEADER[data-v-0f75302f]{margin:0;grid-template-columns:minmax(0,1fr) auto}.primaryheader[data-v-0f75302f],.primaryheader h1[data-v-0f75302f]{display:flex;flex-direction:row;align-items:center}.primaryheader h1[data-v-0f75302f]{margin:0 0 0 -5px;overflow:hidden}.primaryheader h1 .masthead-resource-title[data-v-0f75302f]{text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.primaryheader h1 .masthead-resource-list-link[data-v-0f75302f]{margin:5px}.subheader[data-v-0f75302f]{display:flex;flex-direction:row;color:var(--input-label)}.subheader[data-v-0f75302f]>*{margin:5px 20px 5px 0}.subheader .live-data[data-v-0f75302f]{color:var(--body-text);margin-left:3px}.state-banner[data-v-0f75302f]{margin:3px 0 0 0}.masthead-state[data-v-0f75302f]{margin-left:8px;font-size:medium}.masthead-istio .icon[data-v-0f75302f]{vertical-align:middle;color:var(--primary)}.left-right-split[data-v-0f75302f]{display:grid;align-items:center}.left-right-split .left-half[data-v-0f75302f]{grid-column:1}.left-right-split .right-half[data-v-0f75302f]{grid-column:2}div.actions-container>div.actions[data-v-0f75302f]{display:flex;flex-direction:row;justify-content:flex-end}.resource-external[data-v-0f75302f]{font-size:18px}",""]),t["default"]=s},68171:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".flex-content[data-v-77533c06]{display:flex;flex-direction:column;flex-grow:1}.cru__errors[data-v-77533c06]{position:sticky;top:0;z-index:1;background-color:var(--header-bg)}",""]),t["default"]=s},8344:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,'.title[data-v-98e5f4d8]{align-items:center;display:flex}.title h1[data-v-98e5f4d8]{margin:0}header[data-v-98e5f4d8]{margin-bottom:20px}header.with-subheader[data-v-98e5f4d8]{grid-template-areas:"type-banner type-banner" "title actions" "sub-header sub-header" "state-banner state-banner";margin-bottom:24px}.sub-header[data-v-98e5f4d8]{grid-area:sub-header}.sub-header a[data-v-98e5f4d8]{display:inline-block}',""]),t["default"]=s},50612:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".resource-loading-indicator[data-v-6457c305]{border:1px solid var(--link);border-radius:10px;position:relative;width:-moz-min-content;width:min-content;overflow:hidden}.resource-loading-indicator .resource-loader[data-v-6457c305]:last-child{position:absolute;top:0;background-color:var(--link);color:var(--link-text);overflow:hidden;white-space:nowrap}.resource-loading-indicator .resource-loader[data-v-6457c305]{padding:1px 10px;width:-moz-max-content;width:max-content}.resource-loading-indicator .resource-loader .rl-bg[data-v-6457c305],.resource-loading-indicator .resource-loader .rl-fg[data-v-6457c305]{align-content:center;display:flex}.resource-loading-indicator .resource-loader .rl-bg>i[data-v-6457c305],.resource-loading-indicator .resource-loader .rl-fg>i[data-v-6457c305]{font-size:18px;line-height:18px}.resource-loading-indicator .resource-loader .rl-bg>span[data-v-6457c305],.resource-loading-indicator .resource-loader .rl-fg>span[data-v-6457c305]{margin-left:5px}",""]),t["default"]=s},68085:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".header[data-v-77c563ea],H2[data-v-77c563ea]{position:relative}H2[data-v-77c563ea]{margin:0 0 20px 0}.filter[data-v-77c563ea]{line-height:45px}.right-action[data-v-77c563ea]{position:absolute;top:10px;right:10px}",""]),t["default"]=s},89565:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".auto-update[data-v-7a818782]{min-width:150px;height:40px}.group-tab .count[data-v-7a818782]{opacity:.7;margin-left:2px}",""]),t["default"]=s},20696:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".flex-content[data-v-6ed28bbe]{display:flex;flex-direction:column;flex-grow:1}.footer[data-v-6ed28bbe]{margin-top:20px;right:0;position:sticky;bottom:0;background-color:var(--header-bg);margin-left:-24px;margin-right:-24px;margin-bottom:-24px;padding:10px 24px}.footer.edit[data-v-6ed28bbe]{border-top:var(--header-border-size) solid var(--header-border)}",""]),t["default"]=s},16462:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".resource-yaml .yaml-editor{min-height:200px}.resource-yaml footer .actions{text-align:right}.resource-yaml .spacer-small{padding:0}",""]),t["default"]=s},59182:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".top[data-v-35fec433]{display:flex;position:relative}.top>h2[data-v-35fec433]{flex:1}.close-button[data-v-35fec433]{cursor:pointer;display:flex;align-items:center;justify-content:center;padding:2px}.close-button>i[data-v-35fec433]{font-size:14px;opacity:.5}.close-button[data-v-35fec433]:hover{background-color:var(--wm-closer-hover-bg)}",""]),t["default"]=s},42676:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".simple-box{background:var(--simple-box-bg) 0 0 no-repeat padding-box;box-shadow:0 0 10px var(--simple-box-shadow);border:1px solid var(--simple-box-border);padding:15px}.simple-box .top{line-height:24px;font-size:18px;border-bottom:1px solid var(--simple-box-divider);padding-bottom:15px;margin:0 -15px 10px -15px;padding:0 15px 15px 15px;align-items:center;display:flex}.simple-box .top BUTTON{padding:0;height:-moz-fit-content;height:fit-content;align-self:flex-start}.simple-box .top H2{margin-bottom:0}.simple-box .content{padding:15px}",""]),t["default"]=s},42693:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".limited-cell[data-v-c7d17876]{overflow-wrap:anywhere}.limited-cell.clamped[data-v-c7d17876]{display:-webkit-box;-webkit-box-orient:vertical;overflow:hidden;white-space:normal}",""]),t["default"]=s},81280:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".limited-cell-tooltip{overflow-wrap:break-word}",""]),t["default"]=s},34087:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".table-options-group .table-options-btn.role-multi-action[data-v-480d6580]{background-color:transparent;border:none;font-size:18px}.table-options-group .table-options-btn.role-multi-action[data-v-480d6580]:focus,.table-options-group .table-options-btn.role-multi-action[data-v-480d6580]:hover{background-color:var(--accent-btn);box-shadow:none}.table-options-group .table-options-container[data-v-480d6580]{width:350px;border:1px solid var(--primary);background-color:var(--body-bg);padding:20px;z-index:1}.table-options-group .table-options-container .table-options-grouping[data-v-480d6580]{display:flex;align-items:center;margin-bottom:20px}.table-options-group .table-options-container .table-options-grouping span[data-v-480d6580]{white-space:nowrap;margin-right:10px}.table-options-group .table-options-container ul[data-v-480d6580]{list-style:none;margin:0;padding:0;max-height:200px;overflow-y:auto}.table-options-group .table-options-container ul li[data-v-480d6580]{margin:0;padding:0}.table-options-group .table-options-container ul li.visible[data-v-480d6580]{margin:0 0 10px 0}.sortable>SPAN[data-v-480d6580]{cursor:pointer;-webkit-user-select:none;-moz-user-select:none;user-select:none;white-space:nowrap}.sortable>SPAN[data-v-480d6580]:active,.sortable>SPAN[data-v-480d6580]:hover{text-decoration:underline;color:var(--body-text)}.top-aligned th[data-v-480d6580]{vertical-align:top;padding-top:10px}thead tr[data-v-480d6580]{background-color:var(--sortable-table-header-bg);text-align:left;border-bottom:1px solid var(--sortable-table-top-divider)}th[data-v-480d6580],thead tr[data-v-480d6580]{color:var(--body-text)}th[data-v-480d6580]{padding:8px 5px;font-weight:400;border:0}th.sortable-table-head-element[data-v-480d6580]:focus-visible{outline:2px solid var(--primary-keyboard-focus);outline-offset:-4px}th .content[data-v-480d6580]{position:relative}th .table-header-container[data-v-480d6580]{display:inline-flex}th .table-header-container .content[data-v-480d6580]{display:flex;flex-direction:column}th .table-header-container.not-filterable[data-v-480d6580],th .table-header-container.not-filterable .icon-stack[data-v-480d6580]{margin-top:-2px}th .table-header-container .not-filter-icon[data-v-480d6580]{font-size:16px;color:var(--primary);vertical-align:super}th[data-v-480d6580]:first-child{padding-left:10px}th[data-v-480d6580]:last-child{padding-right:10px}th:not(.sortable)>SPAN[data-v-480d6580]{display:block;margin-bottom:2px}th A[data-v-480d6580]{color:var(--body-text)}@media only screen and (max-width:480px){th.desktop[data-v-480d6580],th.laptop[data-v-480d6580],th.tablet[data-v-480d6580]{display:none}}@media only screen and (max-width:992px){th.desktop[data-v-480d6580],th.laptop[data-v-480d6580]{display:none}}@media only screen and (max-width:1281px){th.desktop[data-v-480d6580]{display:none}}.icon-stack[data-v-480d6580]{width:12px}.icon-sort.faded[data-v-480d6580]{opacity:.3}",""]),t["default"]=s},83469:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".table-options-checkbox .checkbox-custom{min-width:14px}.table-options-checkbox .checkbox-label{color:var(--body-text)}",""]),t["default"]=s},18727:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".sortable-table.alt-loading[data-v-3b705a56]{opacity:.5;pointer-events:none}.advanced-filter-group[data-v-3b705a56]{position:relative;margin-left:10px}.advanced-filter-group .advanced-filter-container[data-v-3b705a56]{position:absolute;top:38px;right:0;width:300px;border:1px solid var(--primary);background-color:var(--body-bg);padding:20px;z-index:2}.advanced-filter-group .advanced-filter-container .middle-block[data-v-3b705a56]{display:flex;align-items:center;margin-top:20px}.advanced-filter-group .advanced-filter-container .middle-block span[data-v-3b705a56]{margin-right:20px}.advanced-filter-group .advanced-filter-container .middle-block button[data-v-3b705a56]{margin-left:20px}.advanced-filter-group .advanced-filter-container .bottom-block[data-v-3b705a56]{display:flex;align-items:center;margin-top:40px;justify-content:space-between}.advanced-filters-applied[data-v-3b705a56]{display:inline-flex;margin:0;padding:0;list-style:none;max-width:100%;flex-wrap:wrap;justify-content:flex-end}.advanced-filters-applied li[data-v-3b705a56]{margin:0 20px 10px 0;padding:2px 5px;border:1px solid;display:flex;align-items:center;position:relative;height:20px}.advanced-filters-applied li[data-v-3b705a56]:nth-child(4n+1){border-color:var(--success)}.advanced-filters-applied li:nth-child(4n+1) .bg[data-v-3b705a56]{background-color:var(--success)}.advanced-filters-applied li[data-v-3b705a56]:nth-child(4n+2){border-color:var(--warning)}.advanced-filters-applied li:nth-child(4n+2) .bg[data-v-3b705a56]{background-color:var(--warning)}.advanced-filters-applied li[data-v-3b705a56]:nth-child(4n+3){border-color:var(--info)}.advanced-filters-applied li:nth-child(4n+3) .bg[data-v-3b705a56]{background-color:var(--info)}.advanced-filters-applied li[data-v-3b705a56]:nth-child(4n+4){border-color:var(--error)}.advanced-filters-applied li:nth-child(4n+4) .bg[data-v-3b705a56]{background-color:var(--error)}.advanced-filters-applied li .bg[data-v-3b705a56]{position:absolute;top:0;left:0;width:100%;height:100%;opacity:.2;z-index:-1}.advanced-filters-applied li .label[data-v-3b705a56]{margin-right:10px;font-size:11px}.advanced-filters-applied li .cross[data-v-3b705a56]{font-size:12px;font-weight:700;cursor:pointer}@media only screen and (max-width:480px){td.desktop[data-v-3b705a56],td.laptop[data-v-3b705a56],td.tablet[data-v-3b705a56]{display:none}}@media only screen and (max-width:992px){td.desktop[data-v-3b705a56],td.laptop[data-v-3b705a56]{display:none}}@media only screen and (max-width:1281px){td.desktop[data-v-3b705a56]{display:none}}tr td div.data-loading[data-v-3b705a56]{align-items:center;display:flex;justify-content:center;padding:20px 0}tr td div.data-loading>i[data-v-3b705a56]{font-size:20px;height:20px;margin-right:5px;width:20px}.advanced-search-box.labeled-input[data-v-3b705a56],.search-box.labeled-input[data-v-3b705a56]{display:flex;align-items:center;min-height:32px;height:32px;padding:0 8px}.advanced-search-box.labeled-input[data-v-3b705a56]:focus-within,.search-box.labeled-input[data-v-3b705a56]:focus-within{border-color:var(--primary-border)}.advanced-search-box[data-v-3b705a56] input[type=search],.search-box[data-v-3b705a56] input[type=search]{flex:1;height:100%;min-height:0;padding:0 32px 0 0;border:none;background-color:transparent;border-radius:0;box-shadow:none;outline:none;line-height:normal}.advanced-search-box[data-v-3b705a56] .labeled-input-clear-button,.search-box[data-v-3b705a56] .labeled-input-clear-button{right:8px}.search-box[data-v-3b705a56]{margin-left:10px;min-width:180px}.advanced-search-box[data-v-3b705a56]{width:100%}",""]),t["default"]=s},24609:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,'.filter-select .vs__selected-options .vs__selected{text-align:left}.sortable-table{border-collapse:collapse;min-width:400px;border-radius:5px 5px 0 0;outline:1px solid var(--border);background:var(--sortable-table-bg);border-radius:4px}.sortable-table.overflow-x{overflow-x:visible}.sortable-table.overflow-y{overflow-y:visible}.sortable-table td{padding:8px 5px;border:0}.sortable-table td:first-child{padding-left:10px}.sortable-table td:last-child{padding-right:10px}.sortable-table td.row-check{padding-top:12px}.sortable-table tbody tr{border-bottom:1px solid var(--sortable-table-top-divider);background-color:var(--sortable-table-row-bg)}.sortable-table tbody tr.additional-sub-row.has-sub-row,.sortable-table tbody tr.main-row.has-sub-row{border-bottom:0}.sortable-table tbody tr.main-row:not(.row-selected):hover+.additional-sub-row,.sortable-table tbody tr.main-row:not(.row-selected):hover+.additional-sub-row+.sub-row,.sortable-table tbody tr.main-row:not(.row-selected):hover+.sub-row{background-color:var(--sortable-table-hover-bg)}.sortable-table tbody tr:last-of-type{border-bottom:0}.sortable-table tbody tr.sub-row-hovered,.sortable-table tbody tr:hover{background-color:var(--sortable-table-hover-bg)}.sortable-table tbody tr.state-description>td{font-size:13px;padding-top:0;overflow-wrap:anywhere}.sortable-table tbody tr.active-row{color:var(--sortable-table-header-bg)}.sortable-table tbody tr.row-selected{background:var(--sortable-table-selected-bg)}.sortable-table tbody .no-rows td{padding:30px 0;text-align:center}.sortable-table tbody .no-results:hover,.sortable-table tbody .no-rows:hover{background-color:var(--body-bg)}.sortable-table tbody.group:before{content:"";display:block;height:20px;background-color:transparent}.sortable-table tbody tr.group-row{background-color:initial}.sortable-table tbody tr.group-row:first-child{border-bottom:2px solid var(--sortable-table-row-bg)}.sortable-table tbody tr.group-row:not(:first-child){margin-top:20px}.sortable-table tbody tr.group-row td{padding:0}.sortable-table tbody tr.group-row td:first-of-type{border-left:1px solid var(--sortable-table-accent-bg)}.sortable-table tbody tr.group-row .group-tab:after,.sortable-table tbody tr.group-row .group-tab:before{content:" ";display:table}.sortable-table tbody tr.group-row .group-tab:after{clear:both}.sortable-table tbody tr.group-row .group-tab{height:40px;line-height:40px;padding:0 10px;border-radius:4px 4px 0 0;background-color:var(--sortable-table-row-bg);position:relative;top:1px;display:inline-block;z-index:10;min-width:72px}.sortable-table tbody tr.group-row .group-tab>SPAN{color:var(--sortable-table-group-label)}.sortable-table tbody tr.group-row .group-tab:after{height:40px;width:70px;border-radius:5px 5px 0 0;background-color:var(--sortable-table-row-bg);content:"";position:absolute;right:-15px;top:0;transform:skewX(40deg);z-index:-1}.for-inputs TABLE.sortable-table{width:100%;border-collapse:collapse;margin-bottom:10px}.for-inputs TABLE.sortable-table>TBODY>TR>TD,.for-inputs TABLE.sortable-table>THEAD>TR>TH{padding-right:10px;padding-bottom:10px}.for-inputs TABLE.sortable-table>TBODY>TR>TD:last-of-type,.for-inputs TABLE.sortable-table>THEAD>TR>TH:last-of-type{padding-right:0}.for-inputs TABLE.sortable-table>TBODY>TR:first-of-type>TD{padding-top:10px}.for-inputs TABLE.sortable-table>TBODY>TR:last-of-type>TD{padding-bottom:0}.for-inputs.clone TABLE.sortable-table>THEAD>TR>TH,.for-inputs.create TABLE.sortable-table>THEAD>TR>TH,.for-inputs.edit TABLE.sortable-table>THEAD>TR>TH{border-color:transparent}.sortable-table-header{position:relative;z-index:11}.sortable-table-header.titled{display:flex;align-items:center}.fixed-header-actions.button{grid-template-columns:[bulk] auto [middle] min-content [search] minmax(min-content,350px)}.has-table-views .sortable-table-header{z-index:13}.sub-header-row{padding:0 0 10px 0}.fixed-header-actions{padding:0 0 20px 0}.fixed-header-actions.with-sub-header{padding:0 0 5px 0}.fixed-header-actions{width:100%;z-index:11;background:transparent;display:grid;grid-template-columns:[bulk] auto [middle] min-content [search] minmax(min-content,200px);grid-column-gap:10px}.fixed-header-actions.advanced-filtering{grid-template-columns:[bulk] auto [middle] minmax(min-content,auto) [search] minmax(min-content,auto)}.fixed-header-actions.table-views-layout{grid-template-columns:[left] auto [middle] minmax(0,1fr);grid-template-areas:"bulk middle" "views views" "filter filter";align-items:center;row-gap:16px;padding-bottom:24px}.fixed-header-actions.table-views-layout.no-top-row{grid-template-areas:"views views" "filter filter"}.fixed-header-actions.table-views-layout.no-top-row .bulk{display:none}.fixed-header-actions.table-views-layout.no-views-row{grid-template-areas:"bulk middle" "filter filter"}.fixed-header-actions.table-views-layout.no-top-row.no-views-row{grid-template-areas:"filter filter"}.fixed-header-actions.table-views-layout.no-top-row.no-views-row .bulk{display:none}.fixed-header-actions.table-views-layout .bulk{grid-area:bulk;height:32px}.fixed-header-actions.table-views-layout .middle{grid-area:middle;display:flex;align-items:center;justify-content:flex-end;height:32px}.fixed-header-actions.table-views-layout .table-views-row{grid-area:views}.fixed-header-actions.table-views-layout .search{grid-area:filter;display:flex;align-items:flex-start;align-self:start;min-height:32px;margin-top:8px;justify-content:flex-start;gap:10px;max-width:none;width:100%;margin-left:0;text-align:left}.fixed-header-actions.table-views-layout .search:after,.fixed-header-actions.table-views-layout .search:before{display:none}.fixed-header-actions .bulk{grid-area:bulk}.fixed-header-actions .bulk>BUTTON{display:none}.fixed-header-actions .bulk>BUTTON:not(:last-of-type){margin-right:10px}.fixed-header-actions .bulk .action-availability{display:none;margin-left:10px;vertical-align:middle;margin-top:2px}.fixed-header-actions .bulk .dropdown-button li.disabled{color:var(--disabled-text);cursor:not-allowed}.fixed-header-actions .bulk .dropdown-button li.disabled:hover{color:var(--disabled-text);background-color:unset;cursor:not-allowed}.fixed-header-actions .middle{grid-area:middle;white-space:nowrap}.fixed-header-actions .middle .icon.icon-backup.animate{animation-name:spin;animation-duration:1s;animation-iteration-count:infinite;animation-timing-function:linear}@keyframes spin{0%{transform:rotate(0deg)}to{transform:rotate(1turn)}}.fixed-header-actions .search{grid-area:search;text-align:right;justify-content:flex-end}.fixed-header-actions .bulk-actions-dropdown{display:none}.fixed-header-actions .bulk-actions-dropdown .dropdown-button{background-color:var(--primary)}.fixed-header-actions .bulk-actions-dropdown .dropdown-button:hover{background-color:var(--primary-hover-bg);color:var(--primary-hover-text)}.fixed-header-actions .bulk-actions-dropdown .dropdown-button .icon-chevron-down,.fixed-header-actions .bulk-actions-dropdown .dropdown-button>*{color:var(--primary-text)}.fixed-header-actions .bulk-actions-dropdown .dropdown-button .button-divider{border-color:var(--primary-text)}.fixed-header-actions .bulk-actions-dropdown .dropdown-button.disabled{border-color:var(--disabled-bg)}.fixed-header-actions .bulk-actions-dropdown .dropdown-button.disabled .icon-chevron-down{color:var(--disabled-text)!important}.fixed-header-actions .bulk-actions-dropdown .dropdown-button.disabled .button-divider{border-color:var(--disabled-text)}.paging{margin-top:10px;text-align:center}.paging SPAN{display:inline-block;min-width:200px}',""]),t["default"]=s},67042:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".state-dot[data-v-2001ed60]{display:inline-block;width:var(--v34a0a70d);height:var(--v34a0a70d);border-radius:50%;background-color:var(--v7e32a647)}",""]),t["default"]=s},29007:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".tab-panel[data-v-7eb30ea9]:focus-visible{outline:2px solid var(--primary-keyboard-focus);outline-offset:-2px}.tab-header[data-v-7eb30ea9]{display:flex;justify-content:space-between;margin-bottom:15px;align-items:center}.tab-header h2[data-v-7eb30ea9]{margin:0}",""]),t["default"]=s},72400:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".tabbed-container[data-v-616212ec]{min-width:-moz-fit-content;min-width:fit-content}.tabs .tab-list[data-v-616212ec]{list-style-type:none;margin:0;padding:0;display:flex;flex-direction:inherit}.tabs.horizontal[data-v-616212ec]{border:solid thin var(--border);border-bottom:0;display:flex;flex-direction:row}.tabs.horizontal.remove-borders[data-v-616212ec]{border:none}.tabs.horizontal.remove-borders+.tab-container[data-v-616212ec]{border:none;border-top:1px solid var(--border);padding:0;padding-top:24px}.tabs.horizontal+.tab-container[data-v-616212ec]{border:solid thin var(--border)}.tabs.horizontal .tab.active[data-v-616212ec]{border-bottom:solid 2px var(--active,var(--primary))}.tabs .tab[data-v-616212ec]{position:relative;float:left;padding:0 4px 0 4px;cursor:pointer}.tabs .tab A[data-v-616212ec]{display:flex;align-items:center;padding:10px 15px}.tabs .tab A[data-v-616212ec]:hover{text-decoration:none}.tabs .tab A:hover span[data-v-616212ec]{text-decoration:underline}.tabs .tab A[data-v-616212ec]:focus-visible{outline:2px solid var(--primary-keyboard-focus);outline-offset:-2px}.tabs .tab A:focus-visible span[data-v-616212ec]{text-decoration:underline}.tabs .tab .conditions-alert-icon[data-v-616212ec]{color:var(--error);padding-left:4px;margin-left:auto}.tabs .tab[data-v-616212ec]:last-child{padding-right:0}.tabs .tab.active>A[data-v-616212ec]{color:var(--active,var(--primary));text-decoration:none}.tabs .tab.error A>.icon-error[data-v-616212ec]{color:var(--error)}.tabs .tab .tab-label-icon[data-v-616212ec]{margin-right:8px}.tabs .tab .tab-badge[data-v-616212ec]{margin-left:5px;background-color:var(--link);color:#fff;border-radius:6px;padding:1px 7px;font-size:11px}.tab-container[data-v-616212ec]{padding:20px}.tab-container.no-content[data-v-616212ec]{padding:0 0 3px 0}.tab-container--flat[data-v-616212ec]{padding:0}.tab-container--flat .side-tabs[data-v-616212ec]{box-shadow:unset}.tabs-only[data-v-616212ec]{margin-bottom:20px}.tabs-only .tab-container[data-v-616212ec]{display:none}.tabs-only .tabs[data-v-616212ec]{border:0;border-bottom:2px solid var(--border)}.side-tabs[data-v-616212ec]{display:flex;box-shadow:0 0 20px var(--shadow);border-radius:calc(var(--border-radius)*2);background-color:var(--tabbed-sidebar-bg)}.side-tabs .tab-container[data-v-616212ec]{padding:20px}.side-tabs .tabs[data-v-616212ec]{width:200px;min-width:200px;display:flex;flex:1 0;flex-direction:column}.side-tabs .tabs .tab[data-v-616212ec]{width:100%;border-left:5px solid transparent}.side-tabs .tabs .tab.toggle A[data-v-616212ec]{color:var(--active,var(--primary))}.side-tabs .tabs .tab A[data-v-616212ec]{color:var(--link,var(--primary))}.side-tabs .tabs .tab.active[data-v-616212ec]{background-color:var(--body-bg);border-left:solid 5px var(--active,var(--primary))}.side-tabs .tabs .tab.active A[data-v-616212ec]{color:var(--input-label)}.side-tabs .tabs .tab.disabled[data-v-616212ec]{background-color:var(--disabled-bg)}.side-tabs .tabs .tab.disabled A[data-v-616212ec]{color:var(--disabled-text);text-decoration:none}.side-tabs .tabs .tab-list-footer[data-v-616212ec]{list-style:none;padding:0;margin:auto 0 0;z-index:1}.side-tabs .tabs .tab-list-footer .tab-list-footer-controls[data-v-616212ec]{display:flex;flex:1}.side-tabs .tabs .tab-list-footer .tab-list-footer-controls .btn[data-v-616212ec]{flex:1 1;display:flex;justify-content:center}.side-tabs .tabs .tab-list-footer .tab-list-footer-controls .btn[data-v-616212ec]:focus-visible{outline:2px solid var(--primary-keyboard-focus)}.side-tabs .tabs .tab-list-footer .tab-list-footer-controls button[data-v-616212ec]:first-of-type{border-top:solid 1px var(--border);border-right:solid 1px var(--border);border-top-left-radius:0;border-top-right-radius:0;border-bottom-right-radius:0}.side-tabs .tabs .tab-list-footer .tab-list-footer-controls button[data-v-616212ec]:last-of-type{border-top:solid 1px var(--border);border-top-right-radius:0;border-top-left-radius:0;border-bottom-left-radius:0;border-bottom-right-radius:0}.side-tabs .tab-container[data-v-616212ec]{width:calc(100% - 200px);flex-grow:1;background-color:var(--body-bg)}",""]),t["default"]=s},83325:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,"ul[data-v-aa0292aa]{list-style-type:none;margin:0;padding:0}li[data-v-aa0292aa]:not(:last-child){margin-bottom:var(--gap)}h4[data-v-aa0292aa]{margin-bottom:12px;margin-top:0}li ul[data-v-aa0292aa]{padding-left:var(--gap-md)}li ul li[data-v-aa0292aa]{margin-top:var(--gap);margin-bottom:0}.toc-container[data-v-aa0292aa]{padding:var(--gap-md);border-radius:var(--border-radius);background-color:var(--subtle-overlay-bg)}.accordion-link[data-v-aa0292aa]{padding:0;min-height:0;line-height:1.3em;text-align:left;width:100%}.accordion-link[data-v-aa0292aa],li>span[data-v-aa0292aa]{white-space:normal;overflow-wrap:anywhere;word-break:break-word;display:block}.toc-parent-link[data-v-aa0292aa]{font-weight:700}",""]),t["default"]=s},3874:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".selection-trigger[data-v-4de6ba3f]{white-space:nowrap}",""]),t["default"]=s},6087:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,'.table-views[data-v-6012a68d]{min-width:544px;margin:0;width:100%}.menu-panel[data-v-6012a68d],.table-views[data-v-6012a68d]{display:flex;flex-direction:column}.menu-panel[data-v-6012a68d]{min-width:240px;min-height:0;overflow-x:hidden;overflow-y:auto;text-align:left;margin:-3px 0;padding:3px 0}.menu-panel .menu-gutter[data-v-6012a68d]{display:inline-block;flex:none;width:14px}.menu-panel [dropdown-menu-item][data-v-6012a68d]:focus-visible{position:relative;z-index:1}.menu-panel [dropdown-menu-item].selected[data-v-6012a68d],.menu-panel [role=menuitemradio][aria-checked=true][data-v-6012a68d]{color:var(--active,var(--primary))}.table-views .view-controls[data-v-6012a68d]{display:flex;flex-wrap:nowrap;align-items:flex-start;gap:16px;width:100%;min-width:-moz-min-content;min-width:min-content}.table-views .query-grow[data-v-6012a68d]{flex:1 1 auto}.table-views .query-column[data-v-6012a68d]{display:flex;flex-direction:column;gap:8px;min-width:0}.table-views .query-notice[data-v-6012a68d]{display:flex;align-items:center;gap:8px;margin:0;color:var(--error);font-size:13px;line-height:18px}.table-views .query-notice .icon[data-v-6012a68d]{flex:none;font-size:14px}.table-views .view-control-btn[data-v-6012a68d]{display:flex;align-items:center;gap:8px;height:32px;padding:0 12px;white-space:nowrap}.table-views .view-control-btn .icon[data-v-6012a68d]{display:inline-flex;align-items:center;justify-content:center;flex:none;width:14px;height:14px;font-size:14px;line-height:1}.view-menu[data-v-6012a68d]{min-width:300px}.view-menu .menu-nav-value[data-v-6012a68d]{color:var(--muted);max-width:150px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.menu-panel .is-reordering .column-row-move[data-v-6012a68d]{transition:transform .2s cubic-bezier(.2,0,0,1)}.menu-panel .is-reordering[data-v-6012a68d],.menu-panel .is-reordering .column-handle[data-v-6012a68d],.menu-panel .is-reordering [dropdown-menu-item][data-v-6012a68d],.menu-panel .is-reordering [dropdown-menu-item][data-v-6012a68d]:hover{cursor:grabbing}.menu-panel .is-reordering .column-row[data-v-6012a68d]{transition:background-color .1s ease-in-out,transform .33s cubic-bezier(.2,1,.1,1),box-shadow .33s cubic-bezier(.2,1,.1,1)}.menu-panel .column-row[data-v-6012a68d]{transition:background-color .1s ease-in-out;-webkit-user-select:none;-moz-user-select:none;user-select:none}.menu-panel .column-row .column-handle[data-v-6012a68d]{font-size:14px;cursor:grab}.menu-panel .column-row .grip[data-v-6012a68d]{color:var(--muted);position:relative;display:inline-block;width:14px;height:12px}.menu-panel .column-row .grip[data-v-6012a68d]:after,.menu-panel .column-row .grip[data-v-6012a68d]:before{content:"";position:absolute;left:1px;right:1px;height:1.5px;border-radius:1px;background:currentColor}.menu-panel .column-row .grip[data-v-6012a68d]:before{top:3.5px}.menu-panel .column-row .grip[data-v-6012a68d]:after{top:7px}.menu-panel .column-row.shown[data-v-6012a68d]{color:var(--active,var(--primary))}.menu-panel .column-row.locked[data-v-6012a68d]{color:color-mix(in srgb,var(--active,var(--primary)) 50%,transparent);cursor:default}.menu-panel .column-row.locked .column-handle[data-v-6012a68d]{cursor:default}.menu-panel .column-row.held[data-v-6012a68d]{position:relative;z-index:1;background:color-mix(in srgb,var(--primary) 14%,transparent);transform:scale(1.02);box-shadow:0 6px 16px rgba(0,0,0,.28);transition:transform .2s cubic-bezier(.2,0,0,1),box-shadow .2s cubic-bezier(.2,0,0,1),background-color .2s cubic-bezier(.2,0,0,1)}',""]),t["default"]=s},42453:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".export-modal[data-v-015f7b08]{display:flex;flex-direction:column;align-items:flex-start;gap:40px;padding:24px;min-width:540px;max-width:860px}.export-modal .export-actions[data-v-015f7b08],.export-modal .export-content[data-v-015f7b08]{align-self:stretch}.export-modal .export-title[data-v-015f7b08]{margin:0 0 16px 0;font-weight:600}.export-modal .export-choose b[data-v-015f7b08],.export-modal .export-intro b[data-v-015f7b08]{font-weight:600}.export-modal .export-intro[data-v-015f7b08]{margin-bottom:16px;line-height:20px}.export-modal .export-choose[data-v-015f7b08]{margin-bottom:16px}.export-modal .export-formats[data-v-015f7b08]{margin-bottom:0}.export-modal .export-actions[data-v-015f7b08]{display:flex;justify-content:flex-end;align-items:center;gap:16px}",""]),t["default"]=s},14716:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".table-view-query[data-v-0e670ff7]{position:relative;display:flex;align-items:center;flex:1;min-width:240px;height:32px;border:1px solid var(--input-border);border-radius:var(--border-radius);background:var(--input-bg);padding:0 12px}.table-view-query.focused[data-v-0e670ff7]{border-color:var(--primary-border)}.table-view-query.list-open[data-v-0e670ff7]{border-bottom-left-radius:0;border-bottom-right-radius:0}.table-view-query .query-input[data-v-0e670ff7]{position:relative;flex:1;min-width:0;height:100%;font-family:inherit;font-size:14px;line-height:30px;color:var(--input-text);white-space:pre;overflow-x:auto;overflow-y:hidden;scrollbar-width:none;contain:inline-size}.table-view-query .query-input[data-v-0e670ff7]::-webkit-scrollbar{display:none}.table-view-query .query-input[data-v-0e670ff7]:focus{outline:none;box-shadow:none}.table-view-query .query-input.is-empty[data-v-0e670ff7]:before{content:attr(data-placeholder);position:absolute;top:0;right:0;bottom:0;left:0;overflow:hidden;color:var(--input-placeholder);text-overflow:ellipsis;white-space:nowrap;pointer-events:none}.table-view-query>.query-affordance[data-v-0e670ff7]{flex:none;display:flex;align-items:center;justify-content:center;align-self:stretch;width:14px;margin-left:8px}.table-view-query .icon-search[data-v-0e670ff7]{color:var(--muted);font-size:14px}.table-view-query .query-clear[data-v-0e670ff7]{flex:none;display:flex;align-items:center;justify-content:center;align-self:stretch;width:100%;min-height:0;padding:0;border:none;background:none;color:var(--muted);line-height:1;cursor:pointer}.table-view-query .query-clear .icon[data-v-0e670ff7]{font-size:14px}.table-view-query .query-clear[data-v-0e670ff7]:hover{color:var(--input-text)}.table-view-query .query-clear[data-v-0e670ff7]:focus-visible{outline:2px solid var(--primary-keyboard-focus)}.table-view-query-menu[data-v-0e670ff7]{position:fixed;left:auto;z-index:max(56,var(--query-menu-stack,0));width:auto;min-width:260px;max-width:380px;margin:0;list-style:none}.table-view-query-menu li[data-v-0e670ff7]{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:6px 12px;cursor:pointer}.table-view-query-menu li.active[data-v-0e670ff7]{background:var(--dropdown-hover-bg);color:var(--dropdown-hover-text)}.table-view-query-menu li.suggestion-rule[data-v-0e670ff7]{display:block;padding:0;cursor:default}.table-view-query-menu li.suggestion-rule hr[data-v-0e670ff7]{margin:7px 0}.table-view-query-menu .suggestion-label.connective[data-v-0e670ff7]{font-style:italic}.table-view-query-menu .suggestion-detail[data-v-0e670ff7]{opacity:.6;font-size:12px;white-space:nowrap}.table-view-query-menu .suggestion-loading[data-v-0e670ff7]{display:flex;align-items:center;gap:8px;color:var(--muted);cursor:default}",""]),t["default"]=s},76858:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".table-view-query .segment-field{color:var(--input-text)}.table-view-query .segment-value{margin-left:4px;padding:0 4px;border-radius:4px;background:color-mix(in srgb,var(--active,var(--primary)) 12%,transparent);color:var(--active,var(--primary))}.table-view-query .segment-value-unknown{color:var(--input-text)}.table-view-query .query-input.holding>span{visibility:hidden}.table-view-query .segment-connective{color:var(--input-text);font-style:italic}",""]),t["default"]=s},39685:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".share-modal[data-v-1f55815c]{display:flex;flex-direction:column;align-items:flex-start;gap:40px;padding:24px;min-width:540px;max-width:860px}.share-modal .share-actions[data-v-1f55815c],.share-modal .share-content[data-v-1f55815c]{align-self:stretch}.share-modal .share-title[data-v-1f55815c]{margin:0 0 16px 0;font-weight:600}.share-modal .share-intro[data-v-1f55815c]{margin-bottom:16px;line-height:20px}.share-modal .share-intro b[data-v-1f55815c]{font-weight:600}.share-modal .share-problem[data-v-1f55815c]{margin:8px 0 0 0}.share-modal .share-actions[data-v-1f55815c]{display:flex;justify-content:flex-end;align-items:center;gap:16px}",""]),t["default"]=s},40138:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,'.table-views[data-v-3990a09b]{min-width:544px;margin:0;width:100%}.menu-panel[data-v-3990a09b],.table-views[data-v-3990a09b]{display:flex;flex-direction:column}.menu-panel[data-v-3990a09b]{min-width:240px;min-height:0;overflow-x:hidden;overflow-y:auto;text-align:left;margin:-3px 0;padding:3px 0}.menu-panel .menu-gutter[data-v-3990a09b]{display:inline-block;flex:none;width:14px}.menu-panel [dropdown-menu-item][data-v-3990a09b]:focus-visible{position:relative;z-index:1}.menu-panel [dropdown-menu-item].selected[data-v-3990a09b],.menu-panel [role=menuitemradio][aria-checked=true][data-v-3990a09b]{color:var(--active,var(--primary))}@keyframes view-tab-scroll-shadow-3990a09b{0%,88%{opacity:1}to{opacity:0}}.table-views .view-tabs-row[data-v-3990a09b]{width:100%;border-bottom:1px solid var(--border)}.table-views .view-tabs[data-v-3990a09b]{display:flex;align-items:stretch;gap:24px;overflow-x:auto;overflow-y:hidden;padding:3px 0 3px 3px;margin:-3px 0 -4px -3px}.table-views .view-tabs[data-v-3990a09b]>*{flex:none}.table-views .view-tabs[data-v-3990a09b]{scrollbar-width:thin}.table-views .view-tabs[data-v-3990a09b]::-webkit-scrollbar{height:4px}.table-views .view-tabs[data-v-3990a09b]::-webkit-scrollbar-thumb{border-radius:2px;background:var(--scrollbar-thumb,var(--border))}.table-views .view-tabs[data-v-3990a09b]::-webkit-scrollbar-track{background:transparent}.table-views .view-tabs-list[data-v-3990a09b]{display:flex;align-items:stretch;gap:24px}.table-views .view-tabs-list[data-v-3990a09b]>*{flex:none}.table-views .view-tabs-list.is-reordering[data-v-3990a09b]{cursor:grabbing}.table-views .view-tabs-list.is-reordering .view-tab-move[data-v-3990a09b]{transition:transform .2s cubic-bezier(.2,0,0,1)}.table-views .view-tabs-list.is-reordering .view-tab[data-v-3990a09b],.table-views .view-tabs-list.is-reordering .view-tab-caret[data-v-3990a09b],.table-views .view-tabs-list.is-reordering .view-tab-wrap[data-v-3990a09b]{cursor:grabbing}.table-views .view-tabs-list.is-reordering .view-tab-wrap.held[data-v-3990a09b]{position:relative;z-index:1;transform:scale(1.02);transition:transform .2s cubic-bezier(.2,0,0,1);border-bottom-color:transparent}.table-views .view-tabs-list.is-reordering .view-tab-wrap.held[data-v-3990a09b]:before{content:"";position:absolute;inset:0 -12px;z-index:-1;border-radius:var(--border-radius);background:color-mix(in srgb,var(--primary) 14%,transparent);box-shadow:0 6px 16px rgba(0,0,0,.28)}@keyframes view-tab-arrive-3990a09b{0%{opacity:0;transform:translateX(-6px) scale(.985)}to{opacity:1;transform:none}}@keyframes view-tab-wash-3990a09b{0%{background:color-mix(in srgb,var(--primary) 15%,transparent)}to{background:transparent}}.table-views .view-tab-wrap.flash[data-v-3990a09b]{position:relative;animation:view-tab-arrive-3990a09b .16s ease-out}.table-views .view-tab-wrap.flash[data-v-3990a09b]:before{content:"";position:absolute;inset:0 -12px;z-index:-1;border-radius:var(--border-radius);animation:view-tab-wash-3990a09b .6s ease-out}@media(prefers-reduced-motion:reduce){.table-views .view-tab-wrap.flash[data-v-3990a09b]{animation:none}}.table-views .view-tab-wrap[data-v-3990a09b]{-webkit-user-select:none;-moz-user-select:none;user-select:none;display:flex;align-items:center;gap:8px;height:32px;border-bottom:2px solid transparent}.table-views .view-tab-wrap[data-v-3990a09b]:has(>.view-tab:focus-visible):not(:has(.rename-input)){border-radius:var(--border-radius);outline:none;box-shadow:0 0 0 1px var(--body-bg),0 0 0 3px var(--primary-keyboard-focus)}.table-views .view-tab-wrap .view-tab-caret[data-v-3990a09b]:focus,.table-views .view-tab-wrap .view-tab-caret[data-v-3990a09b]:focus-visible,.table-views .view-tab-wrap .view-tab[data-v-3990a09b]:focus,.table-views .view-tab-wrap .view-tab[data-v-3990a09b]:focus-visible{outline:none!important}.table-views .view-tab-wrap.active[data-v-3990a09b]{border-bottom-color:var(--active,var(--primary))}.table-views .view-tab-wrap.active .view-tab[data-v-3990a09b],.table-views .view-tab-wrap.active .view-tab-caret[data-v-3990a09b]{color:var(--active,var(--primary))}.table-views .view-tab[data-v-3990a09b]{position:relative;display:flex;align-items:center;gap:8px;height:100%}.table-views .view-tab>.unsaved-dot[data-v-3990a09b]{position:absolute;top:2px;left:100%;margin-left:1px}.table-views .view-tab[data-v-3990a09b]{min-height:32px;background:transparent;border:none;padding:0;cursor:pointer;color:var(--link);font-size:14px;line-height:20px;white-space:nowrap}.table-views .view-tab.rename-input[data-v-3990a09b]{min-width:60px;max-width:220px;height:28px;min-height:28px;padding:0 8px;border:1px solid var(--primary);border-radius:var(--border-radius);background:var(--input-bg);color:var(--input-text);font:inherit;outline:none}.table-views .view-tab.rename-input[data-v-3990a09b]:focus-visible{outline:2px solid var(--primary-keyboard-focus)!important;outline-offset:-1px}.table-views .view-tab.new-view-tab[data-v-3990a09b]{position:sticky;z-index:1;gap:8px;height:auto;min-height:32px;padding:3px 3px 3px 8px;right:0;margin:-3px 0 -3px -8px;align-self:stretch;border-radius:0;background-color:var(--body-bg);background-image:linear-gradient(var(--border),var(--border));background-repeat:no-repeat;background-position:left calc(100% - 3px);background-size:100% 1px;color:var(--link)}.table-views .view-tab.new-view-tab[data-v-3990a09b]:before{content:"";position:absolute;top:0;bottom:4px;right:100%;width:8px;pointer-events:none;background:linear-gradient(90deg,transparent 0,color-mix(in srgb,var(--body-text) 8%,transparent) 100%);opacity:0;animation:view-tab-scroll-shadow-3990a09b linear both;animation-timeline:scroll(nearest inline)}@supports not (animation-timeline:scroll()){.table-views .view-tab.new-view-tab[data-v-3990a09b]:before{opacity:1}}.table-views .view-tab.new-view-tab[data-v-3990a09b]:focus-visible{outline:none}.table-views .view-tab.new-view-tab[data-v-3990a09b]:focus-visible:after{content:"";position:absolute;inset:0;pointer-events:none;border:2px solid var(--primary-keyboard-focus);border-radius:var(--border-radius)}.table-views .view-tab.new-view-tab .icon[data-v-3990a09b]{display:inline-flex;align-items:center;justify-content:center;flex:none;width:14px;height:14px;font-size:14px;line-height:1}.table-views .view-tab-wrap .view-tab-caret[data-v-3990a09b]{display:flex;align-items:center;background:transparent;border:none;cursor:pointer;color:var(--link);height:100%;min-height:32px;padding:0}.table-views .view-tab-wrap .view-tab-caret .icon[data-v-3990a09b]{font-size:14px}.unsaved-dot[data-v-3990a09b]{width:6px;height:6px;flex:none;border-radius:50%;background:var(--error)}.menu-panel.has-notice[data-v-3990a09b]{margin-top:-16px}.menu-panel .menu-notice[data-v-3990a09b]{display:flex;align-items:center;gap:8px;height:40px;margin:0 0 8px;border-radius:var(--border-radius-lg) var(--border-radius-lg) 0 0;padding:0 17px;background:var(--info-badge,var(--info-banner));color:var(--body-text);font-size:14px}.menu-panel .menu-notice .unsaved-dot[data-v-3990a09b]{box-sizing:content-box;border:5px solid transparent;background-clip:content-box}.menu-panel .menu-shortcut[data-v-3990a09b]{margin-left:auto;padding-left:24px;color:var(--dropdown-secondary-text);font-size:12px;white-space:nowrap}',""]),t["default"]=s},32101:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".tag[data-v-0d281a35]{border-radius:var(--border-radius);color:var(--tag-primary);background-color:var(--tag-bg);padding:4px 6px 3px 6px;font-size:12px}",""]),t["default"]=s},19036:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".outer-container[data-v-dd1aa210]{display:flex;flex-direction:column;flex:1;padding:0;justify-content:space-between}.header[data-v-dd1aa210]{display:flex;align-content:space-between;align-items:center;margin-bottom:20px;border-bottom:var(--header-border-size) solid var(--header-border)}.header .step-sequence[data-v-dd1aa210],.header>.title[data-v-dd1aa210]{flex:1;min-height:60px;display:flex}.header .step-sequence .steps[data-v-dd1aa210]{flex:1;margin:0 30px;display:flex;justify-content:space-between;list-style-type:none;padding:0}.header .step-sequence .steps li.step[data-v-dd1aa210]{display:flex;flex-direction:row;flex-grow:1;align-items:center}.header .step-sequence .steps li.step>.controls>span[data-v-dd1aa210]:last-of-type{padding-bottom:0}.header .step-sequence .steps li.step[data-v-dd1aa210]:last-of-type{flex-grow:0}.header .step-sequence .steps li.step .controls[data-v-dd1aa210]{display:flex;flex-direction:column;align-items:center;font:inherit;min-height:0;gap:0;width:40px;overflow:visible;padding-top:7px}.header .step-sequence .steps li.step .controls[data-v-dd1aa210]:disabled{background:transparent}.header .step-sequence .steps li.step .controls>span[data-v-dd1aa210]{padding-bottom:3px;margin-bottom:5px;white-space:nowrap}.header .step-sequence .steps li.step.active .controls[data-v-dd1aa210]{color:var(--primary)}.header .step-sequence .steps li.step:not(.disabled) .controls[data-v-dd1aa210]:hover>*{color:var(--primary)!important;cursor:pointer}.header .step-sequence .steps li.step:not(.active) .controls[data-v-dd1aa210]>*{color:var(--input-disabled-text);text-decoration:none}.header .step-sequence .steps .divider[data-v-dd1aa210]{flex-basis:100%;border-top:1px solid var(--border);position:relative;top:23px}.cru__content .header .step-sequence .steps .divider[data-v-dd1aa210]{top:17px}.header .choice-banner[data-v-dd1aa210]{flex-basis:40%;display:flex;align-items:center;margin-bottom:10px}.header .choice-banner.selected[data-v-dd1aa210]{background-color:var(--accent-btn)}.header .choice-banner.top H2[data-v-dd1aa210]{margin:0}.header .choice-banner.top .title[data-v-dd1aa210]{display:flex;align-items:center;justify-content:space-evenly;position:relative}.header .choice-banner.top .title>.subtitle[data-v-dd1aa210]{margin-right:20px}.header .choice-banner.top .subtitle[data-v-dd1aa210]{display:flex;flex-direction:column}.header .choice-banner.top .subtitle .subtext[data-v-dd1aa210]{color:var(--input-label)}.header .choice-banner[data-v-dd1aa210]:not(.top){box-shadow:0 0 12px 3px var(--box-bg);flex-direction:row;align-items:center;justify-content:start}.header .choice-banner[data-v-dd1aa210]:not(.top):hover{outline:var(--outline-width) solid var(--outline);cursor:pointer}.header .choice-banner .round-image[data-v-dd1aa210]{min-width:50px;height:50px;margin:10px 10px 10px 0;border-radius:50%;overflow:hidden}.header .choice-banner .round-image .logo[data-v-dd1aa210]{min-width:50px;height:50px}.step-container[data-v-dd1aa210]{position:relative;flex:1 1 auto;height:0;overflow-y:auto;padding:20px 2px 2px 2px;display:flex;flex-direction:column}.step-container__step[data-v-dd1aa210]{overflow:hidden;display:flex;flex-direction:column;flex:1}.footer-error[data-v-dd1aa210]{margin-top:-40px;margin-bottom:70px}.controls-row[data-v-dd1aa210]{margin-left:-24px;margin-right:-24px;padding:10px 24px;display:flex;justify-content:space-between;padding-top:10px;border-top:var(--header-border-size) solid var(--header-border);position:absolute;bottom:0;width:100%;background:var(--body-bg)}.controls-row .controls-steps .btn[data-v-dd1aa210]{margin-left:10px}",""]),t["default"]=s},24794:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".yaml-editor{display:flex;flex-direction:column}.yaml-editor .fill{flex:1}.yaml-editor .codemirror-container{position:relative}.yaml-editor .diff-mode{background-color:var(--diff-header-bg);padding:5px 5px;border-bottom-right-radius:0;border-bottom-left-radius:0}.yaml-editor .d2h-file-wrapper{border-top-right-radius:0}",""]),t["default"]=s},81334:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".title[data-v-80314c1e]{margin-bottom:10px}.validation-banner[data-v-80314c1e]{margin-top:0}.box[data-v-80314c1e]{display:grid;grid-template-columns:auto 75px;align-items:center;margin-bottom:10px}.box .value[data-v-80314c1e]{flex:1}.box .value INPUT[data-v-80314c1e]{height:40px}.box.hide-remove-is-view[data-v-80314c1e]{grid-template-columns:auto}.remove[data-v-80314c1e]{text-align:right}.footer .protip[data-v-80314c1e]{float:right;padding:5px 0}.required[data-v-80314c1e]{color:var(--error)}",""]),t["default"]=s},67271:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".array-list-grouped>.box{position:relative;display:block}.array-list-grouped>.box>.remove{position:absolute;top:0;right:0}.array-list-grouped>.box>.info-box{margin-bottom:0;padding-right:25px}",""]),t["default"]=s},47460:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".color-input[data-v-66bade12]{border:1px solid var(--border);border-radius:var(--border-radius);padding:10px}.color-input[data-v-66bade12]:focus-visible{outline:2px solid var(--primary-keyboard-focus)}.color-input.disabled[data-v-66bade12],.color-input.disabled .selected[data-v-66bade12],.color-input[disabled][data-v-66bade12],.color-input[disabled][data-v-66bade12]:hover{color:var(--input-disabled-text);background-color:var(--input-disabled-bg);outline-width:0;border-color:var(--input-disabled-border);cursor:not-allowed}.color-input.disabled .selected div[data-v-66bade12],.color-input.disabled .selected input[data-v-66bade12],.color-input.disabled .selected label[data-v-66bade12],.color-input.disabled .selected span[data-v-66bade12],.color-input.disabled div[data-v-66bade12],.color-input.disabled input[data-v-66bade12],.color-input.disabled label[data-v-66bade12],.color-input.disabled span[data-v-66bade12],.color-input[disabled] div[data-v-66bade12],.color-input[disabled] input[data-v-66bade12],.color-input[disabled] label[data-v-66bade12],.color-input[disabled] span[data-v-66bade12],.color-input[disabled]:hover div[data-v-66bade12],.color-input[disabled]:hover input[data-v-66bade12],.color-input[disabled]:hover label[data-v-66bade12],.color-input[disabled]:hover span[data-v-66bade12]{cursor:not-allowed!important}.color-input.disabled .selected label[data-v-66bade12],.color-input.disabled label[data-v-66bade12],.color-input[disabled] label[data-v-66bade12],.color-input[disabled]:hover label[data-v-66bade12]{color:var(--input-disabled-label);display:inline-block;z-index:1}.color-input.disabled .selected[data-v-66bade12]::-moz-placeholder,.color-input.disabled[data-v-66bade12]::-moz-placeholder,.color-input[disabled][data-v-66bade12]::-moz-placeholder,.color-input[disabled][data-v-66bade12]:hover::-moz-placeholder{color:var(--input-disabled-placeholder)}.color-input.disabled .selected[data-v-66bade12]::placeholder,.color-input.disabled[data-v-66bade12]::placeholder,.color-input[disabled][data-v-66bade12]::placeholder,.color-input[disabled][data-v-66bade12]:hover::placeholder{color:var(--input-disabled-placeholder)}.color-input LABEL[data-v-66bade12]{display:block}.color-input .preview-container[data-v-66bade12]:hover{cursor:pointer}.color-input .preview-container .color-value[data-v-66bade12]{margin-left:4px}.color-input .color-display[data-v-66bade12]{border:1px solid var(--border)}.color-input .color-display[data-v-66bade12]:focus{outline:none;box-shadow:0 0 0 var(--outline-width) var(--outline);background:var(--input-focus-bg)}.color-input INPUT[data-v-66bade12]{border:none;padding:0;width:23px;height:23px;-webkit-appearance:none;opacity:0}.color-input INPUT[data-v-66bade12]:hover{cursor:pointer}",""]),t["default"]=s},68985:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,'.buttons{display:grid;grid-template-areas:"left right"}.buttons .left{grid-area:left;text-align:left}.buttons .left .btn,.buttons .left button{margin:0 1.75% 0 0}.buttons .right{grid-area:right;text-align:right}.buttons .right .btn,.buttons .right button{margin:0 0 0 1.75%}',""]),t["default"]=s},6496:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".input-container[data-v-6f50f528]{display:flex}.input-container.select-after[data-v-6f50f528]{height:100%;flex-direction:row-reverse}.input-container.select-after .input-string[data-v-6f50f528]{border-radius:var(--border-radius) 0 0 var(--border-radius);border-right:0;border-left-width:1px}.input-container.select-after .in-input[data-v-6f50f528]{border-radius:0 var(--border-radius) var(--border-radius) 0}.input-container.select-after .in-input.labeled-select .selected[data-v-6f50f528]{color:var(--input-text);text-align:center;margin-right:1em}.input-container.select-after .in-input.focused[data-v-6f50f528]:not(.vs__dropdown-up){border-bottom-right-radius:0}.input-container.select-after .in-input.focused.vs__dropdown-up[data-v-6f50f528]{border-top-right-radius:0}.input-container.select-after .input-string.focused[data-v-6f50f528],.input-container.select-after .input-string[data-v-6f50f528]:focus,.input-container.select-after .input-string[data-v-6f50f528]:hover:not(.focused):not(.disabled):not(:focus){padding-left:10px!important}.input-container .input-string[data-v-6f50f528]{padding-right:0;width:60%;flex-grow:1;border-radius:0 var(--border-radius) var(--border-radius) 0;border-left-width:0;margin-left:-1px;position:relative;display:table;border-collapse:separate}.input-container .input-string[data-v-6f50f528]:hover:not(.focused):not(.disabled):not(:focus):not(.view){border-left:1px solid var(--input-hover-border);border-right:1px solid var(--input-hover-border);padding-left:9px}.input-container .input-string.focused[data-v-6f50f528],.input-container .input-string[data-v-6f50f528]:focus{border-left:1px solid var(--outline)!important;border-right:1px solid var(--outline)!important;padding-left:9px}.input-container .in-input[data-v-6f50f528]{margin-right:0}.input-container .in-input[data-v-6f50f528]:hover:not(.focused):not(.disabled),.input-container .in-input[data-v-6f50f528]:hover:not(.focused):not(.disabled):not(.view){border:1px solid var(--input-hover-border)!important}.input-container .in-input.focused[data-v-6f50f528]{border:1px solid var(--outline)!important}.input-container .in-input.labeled-select.focused[data-v-6f50f528] ,.input-container .in-input.unlabeled-select.focused[data-v-6f50f528] {outline:none}.input-container .in-input.labeled-select[data-v-6f50f528]:not(.disabled):not(.view) ,.input-container .in-input.unlabeled-select[data-v-6f50f528]:not(.disabled):not(.view) {border:solid 1px var(--input-border)}.input-container .in-input.labeled-select[data-v-6f50f528] ,.input-container .in-input.unlabeled-select[data-v-6f50f528] {box-shadow:none;width:20%;margin-right:1px}.input-container .in-input.labeled-select[data-v-6f50f528] .vs__selected,.input-container .in-input.unlabeled-select[data-v-6f50f528] .vs__selected{color:var(--input-text)}.input-container .in-input.labeled-select[data-v-6f50f528] .vs__dropdown-menu,.input-container .in-input.unlabeled-select[data-v-6f50f528] .vs__dropdown-menu{box-shadow:none}.input-container .in-input.labeled-select[data-v-6f50f528] .vs__dropdown-menu .vs__dropdown-option,.input-container .in-input.unlabeled-select[data-v-6f50f528] .vs__dropdown-menu .vs__dropdown-option{padding:3px 5px}.input-container .in-input.labeled-select[data-v-6f50f528] .v-select:not(.vs--disabled) .vs__dropdown-toggle,.input-container .in-input.unlabeled-select[data-v-6f50f528] .v-select:not(.vs--disabled) .vs__dropdown-toggle{border-radius:var(--border-radius) 0 0 var(--border-radius)}.input-container .in-input.labeled-select[data-v-6f50f528] .v-select:not(.vs--disabled).vs--open .vs__dropdown-toggle,.input-container .in-input.unlabeled-select[data-v-6f50f528] .v-select:not(.vs--disabled).vs--open .vs__dropdown-toggle{color:var(--outline)!important}",""]),t["default"]=s},27180:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".labeled-select[data-v-35b810d8]{position:relative;padding-bottom:1px}.labeled-select.no-label.compact-input[data-v-35b810d8] .vs__actions:after{top:-2px}.labeled-select.no-label.compact-input .labeled-container[data-v-35b810d8]{padding:5px 0 1px 10px}.labeled-select.no-label[data-v-35b810d8]:not(.compact-input){height:61px;padding-top:4px}.labeled-select.no-label[data-v-35b810d8]:not(.compact-input) .vs__actions:after{top:0}.labeled-select.no-label.ls-medium[data-v-35b810d8]{height:32px;padding:0}.labeled-select.no-label.ls-medium .labeled-container[data-v-35b810d8]{height:0;padding:0;overflow:hidden}.labeled-select.no-label.ls-medium[data-v-35b810d8] .vs__dropdown-toggle{height:100%;box-sizing:border-box;border:none;padding:0 10px;align-items:center}.labeled-select.no-label.ls-medium[data-v-35b810d8] .vs__actions:after{height:auto;padding-top:0;line-height:1;top:0}.labeled-select.no-label.ls-medium[data-v-35b810d8] .vs__selected-options{margin-top:0}.labeled-select.no-label.ls-medium[data-v-35b810d8] .vs__selected{margin-top:0;margin-left:0}.labeled-select.no-label.ls-medium[data-v-35b810d8] .vs__search{margin-left:0}.labeled-select .icon-spinner[data-v-35b810d8]{position:absolute;left:calc(50% - .5em);top:calc(50% - .5em)}.labeled-select .labeled-container[data-v-35b810d8]{padding:7px 0 0 10px;padding:10px 0 0 10px}.labeled-select .labeled-container label[data-v-35b810d8]{margin:0}.labeled-select .labeled-container .selected[data-v-35b810d8]{background-color:transparent}.labeled-select.view.labeled-input .labeled-container[data-v-35b810d8]{padding:0}.labeled-select.muted-value[data-v-35b810d8] .vs__selected{color:var(--muted)}.labeled-select.taggable.compact-input[data-v-35b810d8]{min-height:40px}.labeled-select.taggable.compact-input[data-v-35b810d8] .vs__selected-options{padding-top:8px!important}.labeled-select.taggable[data-v-35b810d8]:not(.compact-input){min-height:61px}.labeled-select.taggable[data-v-35b810d8]:not(.compact-input) .vs__selected-options{margin-top:0}.labeled-select[data-v-35b810d8]:not(.taggable) .vs__selected-options .vs__selected{width:100%}.labeled-select.taggable[data-v-35b810d8] .vs__selected-options{padding:3px 0}.labeled-select.taggable[data-v-35b810d8] .vs__selected-options .vs__selected{border-color:var(--accent-btn);height:20px;min-height:unset!important;padding:0 0 0 7px!important}.labeled-select.taggable[data-v-35b810d8] .vs__selected-options .vs__selected:has([data-locked]){padding:0 7px 0 7px!important}.labeled-select.taggable[data-v-35b810d8] .vs__selected-options .vs__selected:has([data-locked]) .vs__deselect{display:none}.labeled-select.taggable[data-v-35b810d8] .vs__selected-options .vs__selected>button{height:20px;line-height:14px}.labeled-select.taggable[data-v-35b810d8] .vs__selected-options .vs__selected>button:hover{background-color:var(--primary);border-radius:0}.labeled-select.taggable[data-v-35b810d8] .vs__selected-options .vs__selected>button:hover:after{color:#fff}.labeled-select.taggable[data-v-35b810d8] .vs--disabled .vs__selected-options .vs__selected{padding:0 7px 0 7px!important}.labeled-select.taggable[data-v-35b810d8] .vs--disabled .vs__selected-options .vs__selected .vs__deselect{display:none}.labeled-select[data-v-35b810d8] .vs__selected-options{margin-top:-5px}.labeled-select[data-v-35b810d8] .v-select:not(.vs--single) .vs__selected-options{padding:5px 0}.labeled-select[data-v-35b810d8] .vs__actions:after{position:relative;top:-10px}.labeled-select[data-v-35b810d8] .v-select.vs--open .vs__dropdown-toggle{color:var(--outline)!important}[data-v-35b810d8] .labeled-select.disabled .labeled-container,[data-v-35b810d8] .labeled-select.disabled .vs__dropdown-toggle,[data-v-35b810d8] .labeled-select.disabled input,[data-v-35b810d8] .labeled-select.disabled label{cursor:not-allowed}.labeled-select .no-label[data-v-35b810d8] .v-select:not(.vs--single){min-height:33px}.labeled-select .no-label[data-v-35b810d8] .selected{padding-top:8px;padding-bottom:9px;position:relative;max-height:2.3em;overflow:hidden}.labeled-select .no-label[data-v-35b810d8] .vs__selected-options{padding:8px 0 7px 0}.vs__dropdown-menu .vs__dropdown-option .vs__option-kind-group[data-v-35b810d8]{display:flex;align-items:center}.vs__dropdown-menu .vs__dropdown-option .vs__option-kind-group i[data-v-35b810d8]{width:18px}.vs__dropdown-menu .vs__dropdown-option .vs__option-kind-group>b[data-v-35b810d8]{flex:1}.vs__dropdown-menu .vs__dropdown-option .vs__option-kind-group>div[data-v-35b810d8]{background-color:var(--primary);border-radius:4px;color:var(--primary-text);font-size:12px;height:18px;line-height:18px;margin-top:1px;padding:0 10px}.vs__dropdown-menu .vs__dropdown-option .vs__option-kind.has-icon[data-v-35b810d8],.vs__dropdown-menu.has-icon .vs__option-kind div[data-v-35b810d8]{padding-left:18px}.vs__dropdown-menu .pagination-slot[data-v-35b810d8]{display:flex;align-items:center;justify-content:center;position:relative;margin-top:5px}.vs__dropdown-menu .pagination-slot .load-more[data-v-35b810d8]{display:flex;align-items:center;height:19px}.vs__dropdown-menu .pagination-slot .load-more a[data-v-35b810d8]{cursor:pointer}.vs__dropdown-menu .pagination-slot .count[data-v-35b810d8]{position:absolute;right:10px}.vs__dropdown-menu .no-options-slot .paginating[data-v-35b810d8]{display:flex;align-items:center;justify-content:center}.vs__dropdown-option>.option-kind-highlighted[data-v-35b810d8]{color:var(--dropdown-highlight-text)}.vs__dropdown-option.vs__dropdown-option--highlight>.option-kind-highlighted[data-v-35b810d8],.vs__dropdown-option.vs__dropdown-option--selected>.option-kind-highlighted[data-v-35b810d8],.vs__dropdown-option>.option-kind-highlighted[data-v-35b810d8]:hover{color:var(--dropdown-hover-text)}.vs__dropdown-menu .vs__dropdown-option .only-user-opts[data-v-35b810d8]{color:var(--dropdown-text);background-color:var(--dropdown-bg);margin:0 -5px;padding:3px 20px}",""]),t["default"]=s},5012:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".unlabeled-select[data-v-7b7d6df0]{position:relative}.unlabeled-select[data-v-7b7d6df0] .v-select.select-input-view .vs__actions{visibility:hidden}.unlabeled-select .vs--multiple[data-v-7b7d6df0] .vs__selected-options .vs__selected{width:auto}.unlabeled-select[data-v-7b7d6df0] .labeled-tooltip.error .status-icon{top:7px;right:2px}.unlabeled-select[data-v-7b7d6df0] .vs__selected-options{display:flex;margin:3px}.unlabeled-select[data-v-7b7d6df0] .vs__selected-options .vs__selected{width:auto}.unlabeled-select[data-v-7b7d6df0] .v-select.vs--open .vs__dropdown-toggle{color:var(--outline)!important}.unlabeled-select.focused.success[data-v-7b7d6df0],.unlabeled-select.success[data-v-7b7d6df0]{border:solid 1px var(--success)}.unlabeled-select.focused.success .selected[data-v-7b7d6df0],.unlabeled-select.focused.success .vs__actions[data-v-7b7d6df0]:after,.unlabeled-select.focused.success input[data-v-7b7d6df0],.unlabeled-select.success .selected[data-v-7b7d6df0],.unlabeled-select.success .vs__actions[data-v-7b7d6df0]:after,.unlabeled-select.success input[data-v-7b7d6df0]{color:var(--success)}.unlabeled-select.focused.warning[data-v-7b7d6df0],.unlabeled-select.warning[data-v-7b7d6df0]{border:solid 1px var(--warning)}.unlabeled-select.focused.warning .selected[data-v-7b7d6df0],.unlabeled-select.focused.warning .vs__actions[data-v-7b7d6df0]:after,.unlabeled-select.focused.warning input[data-v-7b7d6df0],.unlabeled-select.warning .selected[data-v-7b7d6df0],.unlabeled-select.warning .vs__actions[data-v-7b7d6df0]:after,.unlabeled-select.warning input[data-v-7b7d6df0]{color:var(--warning)}.unlabeled-select.error[data-v-7b7d6df0],.unlabeled-select.focused.error[data-v-7b7d6df0]{border:solid 1px var(--error)}.unlabeled-select.error .vs__actions[data-v-7b7d6df0]:after,.unlabeled-select.error>label[data-v-7b7d6df0],.unlabeled-select.focused.error .vs__actions[data-v-7b7d6df0]:after,.unlabeled-select.focused.error>label[data-v-7b7d6df0]{color:var(--error)}.unlabeled-select.compact-input[data-v-7b7d6df0]{min-height:40px;line-height:18px}",""]),t["default"]=s},83858:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".secret-selector{width:100%}.secret-selector label{display:block}.secret-selector .labeled-select{min-height:61px}.secret-selector .vs__selected-options{padding:8px 0 7px 0}.secret-selector label{display:inline-block}.secret-selector.show-key-selector .input-container>*{display:inline-block;width:50%}.secret-selector.show-key-selector .input-container>.labeled-select.focused{z-index:10}.secret-selector.show-key-selector .input-container>:first-child{border-top-right-radius:0;border-bottom-right-radius:0;margin-right:0}.secret-selector.show-key-selector .input-container>:last-child{border-top-left-radius:0;border-bottom-left-radius:0;border-left:none;float:right}",""]),t["default"]=s},58625:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".addon.with-tooltip[data-v-e5242b74]{padding-right:42px}",""]),t["default"]=s},38276:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,'.parent[data-v-5ad5aa7a]{display:grid;grid-template-areas:"progress text";grid-template-columns:auto 80px;align-items:center}.parent .progress[data-v-5ad5aa7a]{background-color:#b8c3dc;width:100%}.parent .progress-box[data-v-5ad5aa7a]{grid-area:progress}.parent .text[data-v-5ad5aa7a]{grid-area:text;text-align:center}',""]),t["default"]=s},22880:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".bar[data-v-b4f4e2ae]{width:100%;height:15px;border-radius:7.5px;overflow:hidden;position:relative}.bar .indicator[data-v-b4f4e2ae]{height:100%}.bar .slice[data-v-b4f4e2ae]{position:absolute;top:0;bottom:0;width:1px;background-color:var(--body-bg)}",""]),t["default"]=s},84593:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,"svg.text[data-v-0343103a]{fill:red}",""]),t["default"]=s},18388:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".favorite[data-v-71b15d4e]{position:relative;cursor:pointer;font-size:20px}.favorite.icon-star-open[data-v-71b15d4e]{color:var(--muted)}.favorite.icon-star-closed[data-v-71b15d4e]{color:var(--body-text)}.favorite[data-v-71b15d4e]:focus-visible{outline:2px solid var(--primary-keyboard-focus)}",""]),t["default"]=s},28232:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".receiver .box-container.create-resource-container{display:flex;justify-content:space-between;flex-wrap:wrap;margin:0 -10px}.receiver .box-container.create-resource-container .subtype-banner{justify-content:space-between;align-items:center;flex-direction:row}.receiver .right{padding:30px;border-left:1px solid var(--border)}.receiver .logo{text-align:center;width:60px;height:60px;border-radius:calc(var(--border-radius)*2);overflow:hidden;background-color:#fff;display:inline-block;vertical-align:middle}.receiver .logo img{width:56px;height:56px;-o-object-fit:contain;object-fit:contain;position:relative;top:2px}.receiver .name{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-bottom:0;display:inline-block;vertical-align:middle}",""]),t["default"]=s},42836:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".responders-heading[data-v-174af1a6]{display:grid;grid-template-columns:auto 75px}.responder[data-v-174af1a6],.responder .target-container[data-v-174af1a6]{width:100%}.responder .target-container[data-v-174af1a6] .unlabeled-select{min-width:35%;height:100%}.responder .target[data-v-174af1a6]{height:100%}",""]),t["default"]=s},32397:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".description[data-v-07ec0ff4]{font-weight:600}",""]),t["default"]=s},95671:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".text.info[data-v-7155ccc2]{display:flex;align-items:center}.text.info>span[data-v-7155ccc2]{margin-right:5px}",""]),t["default"]=s},71286:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".delete-warning[data-v-017c9f08]{color:var(--error)}.remove-project-dialog[data-v-017c9f08]{border:1px solid var(--border);padding:10px;border-radius:5px}.remove-project-dialog .display-name[data-v-017c9f08]{font-weight:700}",""]),t["default"]=s},59766:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".text.info[data-v-224f553f]{display:flex;align-items:center}.text.info>span[data-v-224f553f]{margin-right:5px}",""]),t["default"]=s},78268:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".body[data-v-44bed663]{font-weight:600}.actions[data-v-44bed663]{text-align:right}",""]),t["default"]=s},99365:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".badge-state[data-v-544b3117]{align-items:center;display:inline-flex;padding:2px 10px;border:1px solid transparent;border-radius:20px}.badge-state.bg-info[data-v-544b3117]{color:var(--on-info-banner);background:var(--info-badge,var(--info-banner))}.badge-state.bg-error[data-v-544b3117]{color:var(--on-error-banner);background:var(--error-badge,var(--error-banner))}.badge-state.bg-warning[data-v-544b3117]{color:var(--on-warning-banner);background:var(--warning-badge,var(--warning-banner))}.badge-state.bg-success[data-v-544b3117]{color:var(--on-success-banner,var(--success-text));background:var(--success-badge,var(--success))}.badge-state.badge-disabled[data-v-544b3117]{color:var(--badge-state-disabled-text);background-color:var(--badge-state-disabled-bg);border:1px solid var(--badge-state-disabled-border)}",""]),t["default"]=s},28811:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".sortable-table TD .badge-state{text-overflow:ellipsis;overflow:hidden;white-space:nowrap;word-wrap:break-word;display:inline-block;max-width:100%;position:relative;max-width:110px;font-size:.85em;vertical-align:middle}",""]),t["default"]=s},55768:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".banner[data-v-1a28c7f8]{display:flex;margin:15px 0;position:relative;width:100%;color:var(--body-text)}.banner__icon[data-v-1a28c7f8]{width:48px;flex-grow:1;display:flex;justify-content:center;align-items:center;box-sizing:content-box}.primary .banner__icon[data-v-1a28c7f8]{background:var(--primary)}.secondary .banner__icon[data-v-1a28c7f8]{background:var(--default)}.success .banner__icon[data-v-1a28c7f8]{background:var(--success)}.info .banner__icon[data-v-1a28c7f8]{background:var(--info)}.warning .banner__icon[data-v-1a28c7f8]{background:var(--warning)}.error .banner__icon[data-v-1a28c7f8]{background:var(--error);color:var(--primary-text)}.banner.banner-disabled[data-v-1a28c7f8]{filter:grayscale(1)}.banner__content[data-v-1a28c7f8]{padding:10px;transition:all .2s ease;line-height:20px;width:100%;border-left:4px solid transparent;display:flex;gap:3px}.primary .banner__content[data-v-1a28c7f8]{background:var(--primary);border-color:var(--primary)}.secondary .banner__content[data-v-1a28c7f8]{background:var(--default-banner-bg);border-color:var(--default)}.success .banner__content[data-v-1a28c7f8]{background:var(--success-banner-bg);border-color:var(--success)}.info .banner__content[data-v-1a28c7f8]{background:var(--info-banner-bg);border-color:var(--info)}.warning .banner__content[data-v-1a28c7f8]{background:var(--warning-banner-bg);border-color:var(--warning);color:var(--warning-banner-text,var(--body-text))}.error .banner__content[data-v-1a28c7f8]{background:var(--error-banner-bg);border-color:var(--error);color:var(--error-banner-text,var(--error))}.banner__content.stacked[data-v-1a28c7f8]{padding:0 10px;margin:0;transition:none}.banner__content.stacked[data-v-1a28c7f8]:first-child{padding-top:10px}.banner__content.stacked[data-v-1a28c7f8]:last-child{padding-bottom:10px}.banner__content.closable[data-v-1a28c7f8]{padding-right:48px}.banner__content__closer[data-v-1a28c7f8]{display:flex;align-items:center;cursor:pointer;position:absolute;top:0;right:0;bottom:0;width:24px;line-height:24px;text-align:center;outline:none}.banner__content__closer .closer-icon[data-v-1a28c7f8]{opacity:.7}.banner__content__closer .closer-icon[data-v-1a28c7f8]:hover{opacity:1;color:var(--link)}.banner__content__closer:focus-visible i[data-v-1a28c7f8]{outline:2px solid var(--primary-keyboard-focus);outline-offset:2px}.banner__content.icon[data-v-1a28c7f8]{border-left:none}",""]),t["default"]=s},98176:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".card-container.highlight-border[data-v-30ef2231]{border-left:5px solid var(--primary)}.card-container[data-v-30ef2231]{border-radius:var(--border-radius);display:flex;flex-basis:40%;margin:10px;min-height:100px;padding:10px;box-shadow:0 0 20px var(--shadow)}.card-container[data-v-30ef2231]:not(.top){flex-direction:row;justify-content:start}.card-container .card-wrap[data-v-30ef2231]{width:100%}.card-container .card-body[data-v-30ef2231]{color:var(--input-label);display:flex;flex-direction:column;justify-content:center}.card-container .card-actions[data-v-30ef2231]{align-self:end;display:flex;padding-top:20px}.card-container .card-title[data-v-30ef2231]{align-items:center;display:flex;width:100%}.card-container .card-title h5[data-v-30ef2231]{margin:0}.card-container .card-title .flex-right[data-v-30ef2231]{margin-left:auto}.card-container.card-sticky[data-v-30ef2231]{overflow:hidden}.card-container.card-sticky .card-wrap[data-v-30ef2231]{display:flex;flex-direction:column}.card-container.card-sticky .card-wrap .card-body[data-v-30ef2231]{justify-content:flex-start;overflow:auto}.card-container.card-sticky .card-wrap[data-v-30ef2231]>*{flex:0}.card-container.card-sticky .card-wrap .card-body[data-v-30ef2231]{flex:1}",""]),t["default"]=s},43063:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,'.checkbox-outer-container[data-v-688406d2]{display:inline-flex;flex-direction:column}.checkbox-outer-container-description[data-v-688406d2]{color:var(--deemphasized);font-size:12px;margin-left:19px;margin-top:4px}.checkbox-outer-container-extra[data-v-688406d2]{font-size:14px;margin-left:19px;margin-top:4px}.checkbox-container[data-v-688406d2]{position:relative;display:inline-flex;align-items:center;margin:0;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;user-select:none;border-radius:var(--border-radius)}.checkbox-container .checkbox-label[data-v-688406d2]{color:var(--input-label);display:inline-flex;margin:0 10px 0 5px}.checkbox-container .checkbox-label .body-text-color[data-v-688406d2]{color:var(--body-text)}.checkbox-container .checkbox-label.checkbox-primary[data-v-688406d2]{color:inherit;font-weight:600}.checkbox-container .checkbox-info[data-v-688406d2]{line-height:normal;margin-left:4px}.checkbox-container .checkbox-info[data-v-688406d2] .rc-icon{line-height:normal}.checkbox-container .checkbox-custom[data-v-688406d2]{height:14px;width:14px;background-color:var(--body-bg);border-radius:var(--border-radius);border:1px solid var(--input-border);flex-shrink:0}.checkbox-container .checkbox-custom[data-v-688406d2]:focus-visible{outline:2px solid var(--primary-keyboard-focus);outline-offset:2px;border-radius:0}.checkbox-container input[data-v-688406d2]{opacity:0;position:absolute;z-index:-1}.checkbox-container input:focus-visible~.checkbox-custom[data-v-688406d2]{outline:2px solid var(--primary-keyboard-focus);outline-offset:2px;border-radius:0}.checkbox-container input:checked~.checkbox-custom[data-v-688406d2]{background-color:var(--active,var(--primary));transform:rotate(0deg) scale(1);opacity:1;border:1px solid var(--checkbox-border,var(--primary))}.checkbox-container .checkbox-custom[data-v-688406d2]:after{position:absolute;content:"";left:0;top:0;height:0;width:0;border-radius:var(--border-radius);border:solid;border-color:var(--input-text);border-width:0 3px 3px 0;transform:rotate(0deg) scale(0);opacity:1}.checkbox-container input:checked~.checkbox-custom[data-v-688406d2]:after{transform:rotate(45deg) scale(1);opacity:1;left:4px;width:4px;height:10px;border:solid;border-color:var(--checkbox-tick);border-width:0 2px 2px 0;background-color:transparent}.checkbox-container input:checked~.checkbox-custom.indeterminate[data-v-688406d2]:after{transform:scale(1);opacity:1;left:3px;top:2px;width:6px;height:5px;border:solid;border-color:var(--checkbox-tick);border-width:0 0 2px 0;background-color:transparent}.checkbox-container.disabled .checkbox-custom[data-v-688406d2],.checkbox-container.disabled input:checked~.checkbox-custom[data-v-688406d2]{background-color:var(--checkbox-disabled-bg);border-color:var(--checkbox-disabled-bg)}.checkbox-container.disabled input:checked~.checkbox-custom[data-v-688406d2]:after{border-color:var(--checkbox-tick-disabled)}.checkbox-container.disabled[data-v-688406d2]{cursor:not-allowed}.checkbox-container .checkbox-view[data-v-688406d2]{display:flex;flex-direction:column}.checkbox-container .checkbox-view LABEL[data-v-688406d2]{color:var(--input-label)}',""]),t["default"]=s},9284:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".labeled-input[data-v-3a63eca7]{position:relative}.multiline-password[data-v-3a63eca7]:not(:focus){-webkit-text-security:disc}.labeled-input.view input[data-v-3a63eca7]{text-overflow:ellipsis}.hideArrows input[data-v-3a63eca7]::-webkit-inner-spin-button,.hideArrows input[data-v-3a63eca7]::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}.hideArrows input[type=number][data-v-3a63eca7]{-moz-appearance:textfield}input[type=search][data-v-3a63eca7]::-webkit-search-cancel-button{-webkit-appearance:none;appearance:none}.labeled-input-clear-button[data-v-3a63eca7]{--rc-button-padding:0;position:absolute;right:10px;top:50%;transform:translateY(-50%);width:24px;color:var(--input-text)}.labeled-input-clear-button[data-v-3a63eca7]:hover:not(:disabled){color:var(--primary)}.labeled-input-clear-button[data-v-3a63eca7]:disabled{cursor:not-allowed;opacity:.5}.labeled-input-clear-button[data-v-3a63eca7] .rc-icon{font-size:14px}.labeled-input.suffix .labeled-input-clear-button[data-v-3a63eca7]{right:40px}",""]),t["default"]=s},90910:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".radio-view[data-v-36919aac]{display:flex;flex-direction:column}.radio-view LABEL[data-v-36919aac]{color:var(--input-label)}.radio-group .text-label[data-v-36919aac]{display:block;padding-bottom:5px}.radio-container[data-v-36919aac]{position:relative;display:inline-flex;align-items:flex-start;margin:0;left:-4px;-webkit-user-select:none;-moz-user-select:none;user-select:none;border-radius:var(--border-radius);padding-bottom:5px;padding-left:4px}.radio-container[data-v-36919aac],.radio-container .radio-button-outer-container-description[data-v-36919aac],.radio-container .radio-label[data-v-36919aac]{cursor:pointer}.radio-container.disabled[data-v-36919aac],.radio-container.disabled .radio-button-outer-container-description[data-v-36919aac],.radio-container.disabled .radio-label[data-v-36919aac]{cursor:not-allowed}.radio-container .radio-custom[data-v-36919aac]{height:14px;width:14px;min-height:14px;min-width:14px;background-color:var(--input-bg);border-radius:50%;border:1.5px solid var(--input-border);margin-top:5px}.radio-container input[data-v-36919aac]{display:none}.radio-container .radio-custom[aria-checked=true][data-v-36919aac]{background-color:var(--active,var(--primary));transform:rotate(0deg) scale(1);opacity:1;border:1.5px solid var(--active,var(--primary))}.radio-container .radio-custom[aria-checked=true].text-muted[data-v-36919aac]{opacity:.25}.radio-container input:disabled~.radio-custom[data-v-36919aac]:not([aria-checked=true]){background-color:var(--disabled-bg);opacity:.25}.radio-container .radio-button-outer-container-description[data-v-36919aac]{color:var(--deemphasized);font-size:12px;margin-top:4px}.radio-container .labeling[data-v-36919aac]{display:inline-flex;flex-direction:column;margin:3px 10px 0 5px}.radio-container .labeling .body-text-color[data-v-36919aac]{color:var(--body-text)}",""]),t["default"]=s},87689:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".radio-group[data-v-1157638b]:focus,.radio-group[data-v-1157638b]:focus-visible{border:none;outline:none}.radio-group:focus-visible .radio-button-checked[data-v-1157638b]{outline:2px solid var(--primary-keyboard-focus)}.radio-group h3[data-v-1157638b]{position:relative}.radio-group.row[data-v-1157638b]{display:flex}.radio-group.row .radio-container[data-v-1157638b]{margin-right:10px}.radio-group .label[data-v-1157638b]{font-size:14px!important}",""]),t["default"]=s},97394:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,'.toggle-container[data-v-0334e5ef]{align-items:center;display:flex}.toggle-container span[data-v-0334e5ef]:first-child{padding-right:6px}.toggle-container span[data-v-0334e5ef]:last-child{padding-left:6px}.toggle-container.toggle-disabled[data-v-0334e5ef]{pointer-events:none}.toggle-container.toggle-disabled .slider[data-v-0334e5ef]{background-color:var(--checkbox-disabled-bg)}.toggle-container.toggle-disabled .slider[data-v-0334e5ef]:before{opacity:.6}.switch[data-v-0334e5ef]{position:relative;display:inline-block;width:48px;min-width:48px;height:24px}.switch input[data-v-0334e5ef]{opacity:0;width:0;height:0}.slider[data-v-0334e5ef]{cursor:pointer;top:0;left:0;right:0;bottom:0;background-color:var(--checkbox-disabled-bg)}.slider[data-v-0334e5ef],.slider[data-v-0334e5ef]:before{position:absolute;transition:.4s}.slider[data-v-0334e5ef]:before{content:"";height:16px;width:16px;left:4px;bottom:4px;background-color:var(--checkbox-tick)}input:checked+.slider[data-v-0334e5ef]{background-color:var(--checkbox-ticked-bg)}input:focus+.slider[data-v-0334e5ef]{box-shadow:0 0 1px var(--checkbox-ticked-bg)}input:focus-visible+.slider[data-v-0334e5ef]{outline:2px solid var(--primary-keyboard-focus);outline-offset:2px;transition:0s}input:checked+.slider[data-v-0334e5ef]:before{transform:translateX(24px)}.slider.round[data-v-0334e5ef]{border-radius:34px}.slider.round[data-v-0334e5ef]:before{border-radius:50%}',""]),t["default"]=s},33177:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".labeled-tooltip[data-v-3ed54754]{position:absolute;width:100%;height:100%;left:0;top:0}.labeled-tooltip.hoverable[data-v-3ed54754]{height:0}.labeled-tooltip .status-icon[data-v-3ed54754]{position:absolute;right:30px;top:18px;z-index:3}.labeled-tooltip.error .status-icon[data-v-3ed54754]{color:var(--error);top:7px;right:5px}.labeled-tooltip.warning .status-icon[data-v-3ed54754]{color:var(--warning)}.labeled-tooltip.success .status-icon[data-v-3ed54754]{color:var(--success)}",""]),t["default"]=s},48815:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".rc-tag[data-v-1eeacc78]{display:inline-flex;min-height:24px;padding:2px 8px;align-items:center;gap:8px;border-radius:4px;border:1px solid var(--rc-active-border);overflow:hidden;text-overflow:ellipsis;font-family:Lato;font-size:13px;font-style:normal;font-weight:400;line-height:20px;color:var(--body-text)}.rc-tag button[data-v-1eeacc78]{padding:0;line-height:12px;min-height:12px;background:none}.rc-tag button[data-v-1eeacc78],.rc-tag button .icon-close[data-v-1eeacc78]{width:12px;height:12px;font-size:12px}.rc-tag.disabled button[data-v-1eeacc78]{cursor:not-allowed}.rc-tag.active[data-v-1eeacc78]{border-color:var(--rc-active-border);background:var(--rc-active-background);cursor:pointer}.rc-tag.active.highlight[data-v-1eeacc78],.rc-tag.active[data-v-1eeacc78]:hover{border-color:var(--rc-primary-hover);background:var(--rc-active-background)}.rc-tag.active.disabled[data-v-1eeacc78]{border-color:var(--rc-active-border);background:var(--rc-active-disabled-background);color:var(--rc-disabled-text-color);cursor:not-allowed}.rc-tag.inactive[data-v-1eeacc78]{background:var(--rc-inactive-background);border-color:var(--rc-inactive-border)}.rc-tag.inactive.disabled[data-v-1eeacc78]{border-color:var(--rc-inactive-disabled-border);color:var(--rc-disabled-text-color)}",""]),t["default"]=s},40236:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".rc-button[data-v-7a42fdd6]{display:inline-flex;align-items:center;justify-content:center}.rc-button[data-v-7a42fdd6]> .icon:not(:only-child){margin-right:0}.rc-button.variant-primary[data-v-7a42fdd6]{background:var(--primary);color:var(--primary-text)}.rc-button.variant-primary._hover[data-v-7a42fdd6],.rc-button.variant-primary.focused[data-v-7a42fdd6],.rc-button.variant-primary[data-v-7a42fdd6]:focus,.rc-button.variant-primary[data-v-7a42fdd6]:hover{background-color:var(--primary-hover-bg);color:var(--primary-text)}.rc-button.variant-primary[data-v-7a42fdd6]:focus-visible{outline:2px solid var(--primary-keyboard-focus);outline-offset:2px}.rc-button.variant-primary[data-v-7a42fdd6]:disabled,.rc-button.variant-primary[data-v-7a42fdd6]:disabled:focus,.rc-button.variant-primary[data-v-7a42fdd6]:disabled:hover{color:var(--disabled-text);background:var(--disabled-bg);border-color:var(--disabled-bg);cursor:not-allowed}.rc-button.variant-secondary[data-v-7a42fdd6]{background:var(--secondary,transparent);color:var(--on-secondary,var(--primary));border:solid 1px var(--secondary-border,var(--primary))}.rc-button.variant-secondary._hover[data-v-7a42fdd6],.rc-button.variant-secondary[data-v-7a42fdd6]:hover{background:var(--secondary-hover,transparent);color:var(--on-secondary,var(--lightest))}.rc-button.variant-secondary.focused[data-v-7a42fdd6],.rc-button.variant-secondary[data-v-7a42fdd6]:focus{background-color:var(--secondary-hover,var(--primary-hover-bg));color:var(--on-secondary,var(--primary-text))}.rc-button.variant-secondary[data-v-7a42fdd6]:focus-visible{outline:2px solid var(--primary-keyboard-focus);outline-offset:2px}.rc-button.variant-secondary[data-v-7a42fdd6]:disabled,.rc-button.variant-secondary[data-v-7a42fdd6]:disabled:focus,.rc-button.variant-secondary[data-v-7a42fdd6]:disabled:hover{color:var(--disabled-text);background:var(--disabled-bg);border-color:var(--disabled-bg);cursor:not-allowed}.rc-button.variant-tertiary[data-v-7a42fdd6]{background:var(--tertiary,var(--accent-btn));color:var(--on-tertiary,var(--primary));border:solid 1px var(--tertiary-border,var(--primary))}.rc-button.variant-tertiary[data-v-7a42fdd6]:hover{background:var(--tertiary-hover,var(--accent-btn));color:var(--on-tertiary-hover,var(--lightest))}.rc-button.variant-tertiary.focused[data-v-7a42fdd6],.rc-button.variant-tertiary[data-v-7a42fdd6]:focus{background-color:var(--tertiary-hover,var(--primary-hover-bg));color:var(--on-tertiary,var(--primary-text))}.rc-button.variant-tertiary[data-v-7a42fdd6]:focus-visible{outline:2px solid var(--primary-keyboard-focus);outline-offset:2px}.rc-button.variant-tertiary[data-v-7a42fdd6]:disabled,.rc-button.variant-tertiary[data-v-7a42fdd6]:disabled:focus,.rc-button.variant-tertiary[data-v-7a42fdd6]:disabled:hover{color:var(--disabled-text);background:var(--disabled-bg);border-color:var(--disabled-bg);cursor:not-allowed}.rc-button.variant-link[data-v-7a42fdd6]{background:transparent;color:var(--link)}.rc-button.variant-link._hover[data-v-7a42fdd6],.rc-button.variant-link[data-v-7a42fdd6]:hover{color:var(--lightest);background-color:var(--accent-btn);box-shadow:none}.rc-button.variant-link[data-v-7a42fdd6]:focus-visible{outline:2px solid var(--primary-keyboard-focus);outline-offset:2px}.rc-button.variant-multi-action[data-v-7a42fdd6]{background:var(--accent-btn);border:solid thin var(--primary);color:var(--primary);border-radius:2px}.rc-button.variant-ghost[data-v-7a42fdd6]{padding:0;background-color:transparent}.rc-button.variant-ghost[data-v-7a42fdd6]:focus-visible{outline:2px solid var(--primary-keyboard-focus);outline-offset:0}.rc-button.btn-small[data-v-7a42fdd6],.rc-button.btn-small[data-v-7a42fdd6]:not(.btn-sm){line-height:1.3333333333;font-size:12px;min-height:24px;padding:var(--rc-button-padding,0 8px);gap:8px}.rc-button.btn-medium[data-v-7a42fdd6],.rc-button.btn-medium[data-v-7a42fdd6]:not(.btn-sm){line-height:1.4285714286;font-size:14px;min-height:32px;padding:var(--rc-button-padding,0 12px);gap:8px}.rc-button.btn-large[data-v-7a42fdd6],.rc-button.btn-large[data-v-7a42fdd6]:not(.btn-sm){line-height:1.5;font-size:16px;min-height:40px;padding:var(--rc-button-padding,0 16px);gap:12px}",""]),t["default"]=s},40628:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,'.rc-code-mirror[data-v-0d60681a]{--rc-cm-bg:#fff;--rc-cm-selection:#e0e0e0;--rc-cm-key:#1a4fa8;--rc-cm-string:#8a4b10;--rc-cm-keyword:#9a2b94;--rc-cm-comment:#5b616d;--rc-cm-text:#16181d;--rc-cm-gutter:#5b626c;--rc-cm-fold-hover:#e8ecf2;--rc-cm-active-line:rgba(0,0,0,.04);--rc-cm-search-match:rgba(255,213,0,.4);--rc-cm-search-match-selected:rgba(255,140,0,.5);--rc-cm-color-scheme:light;display:flex;flex-direction:column;height:100%;box-sizing:border-box;position:relative}.rc-code-mirror .rc-cm-escape-hint[data-v-0d60681a]{position:absolute;right:8px;bottom:4px;z-index:2;padding:2px 4px;color:var(--rc-cm-text);background-color:var(--rc-cm-bg);font-size:12px;pointer-events:none}.rc-code-mirror .rc-cm-keymap-indicator[data-v-0d60681a]{--rc-button-padding:0;position:absolute;top:7px;right:7px;z-index:2;width:48px;height:32px;display:flex;align-items:center;justify-content:center;gap:0;border:1px solid transparent;border-radius:var(--border-radius);color:var(--darker);background-color:var(--subtle-overlay-bg);cursor:pointer}.rc-code-mirror .rc-cm-keymap-indicator .rc-cm-keymap-icon[data-v-0d60681a]{font-size:24px;opacity:.8;transition:margin-right .1s ease-in-out}.rc-code-mirror .rc-cm-keymap-indicator .rc-cm-keymap-close[data-v-0d60681a]{width:0;overflow:hidden;color:var(--primary);opacity:0}.rc-code-mirror .rc-cm-keymap-indicator[data-v-0d60681a]:focus-visible,.rc-code-mirror .rc-cm-keymap-indicator[data-v-0d60681a]:hover{border-color:var(--primary)}.rc-code-mirror .rc-cm-keymap-indicator:focus-visible .rc-cm-keymap-icon[data-v-0d60681a],.rc-code-mirror .rc-cm-keymap-indicator:hover .rc-cm-keymap-icon[data-v-0d60681a]{opacity:.6;margin-right:4px}.rc-code-mirror .rc-cm-keymap-indicator:focus-visible .rc-cm-keymap-close[data-v-0d60681a],.rc-code-mirror .rc-cm-keymap-indicator:hover .rc-cm-keymap-close[data-v-0d60681a]{width:auto;opacity:1;transition:opacity .1s ease-in-out .1s}.rc-code-mirror .rc-cm-keymap-indicator[data-v-0d60681a]:focus-visible{outline:2px solid var(--primary-keyboard-focus);outline-offset:1px}.rc-code-mirror[data-v-0d60681a] .cm-editor{height:100%;min-height:0}.rc-code-mirror .rc-cm-bottom-panels[data-v-0d60681a]{position:sticky;top:0;z-index:302}.rc-code-mirror .rc-cm-bottom-panels[data-v-0d60681a] .cm-panels{position:static;box-sizing:border-box;height:40px;color:var(--rc-cm-text);background-color:var(--rc-cm-bg);border:none;border-bottom:1px solid var(--border,#dcdee7)}.rc-code-mirror .rc-cm-bottom-panels[data-v-0d60681a] .cm-vim-panel{display:flex;align-items:center;box-sizing:border-box;height:100%;min-height:0;padding:0 8px;font-size:14px}.rc-code-mirror .rc-cm-bottom-panels[data-v-0d60681a] .cm-vim-panel span{font-family:Roboto Mono,monospace!important;align-items:center}.rc-code-mirror .rc-cm-bottom-panels[data-v-0d60681a] .cm-vim-panel span+span{color:var(--rc-cm-comment)!important;font-family:inherit!important}.rc-code-mirror .rc-cm-bottom-panels[data-v-0d60681a] .cm-vim-panel input{display:inline-block;width:auto;min-width:0;height:auto;padding:0 0 0 2px;border:none;border-radius:0;outline:none;color:inherit;caret-color:var(--rc-cm-key);background-color:transparent;font:inherit}.rc-code-mirror[data-v-0d60681a] .cm-editor.cm-focused{outline:none}.rc-code-mirror.rc-code-mirror--editor[data-v-0d60681a] .cm-scroller,.rc-code-mirror.rc-code-mirror--editor[data-v-0d60681a] .cm-tooltip-autocomplete>ul{font-family:Roboto Mono,monospace}.rc-code-mirror.rc-code-mirror--editor[data-v-0d60681a] .cm-foldGutter{width:22px}.rc-code-mirror.rc-code-mirror--editor[data-v-0d60681a] .cm-foldGutter .cm-gutterElement{width:22px;display:flex;align-items:center;justify-content:center;border-radius:4px}.rc-code-mirror.rc-code-mirror--editor[data-v-0d60681a] .cm-foldGutter .cm-gutterElement:has(.rc-cm-fold-marker){cursor:pointer}.rc-code-mirror.rc-code-mirror--editor[data-v-0d60681a] .cm-foldGutter .cm-gutterElement:has(.rc-cm-fold-marker):hover{background-color:var(--rc-cm-fold-hover)}.rc-code-mirror.rc-code-mirror--editor[data-v-0d60681a] .cm-foldGutter .rc-cm-fold-marker{display:flex;align-items:center;justify-content:center;width:100%;height:100%;box-sizing:border-box;padding:0}.rc-code-mirror.rc-code-mirror--editor[data-v-0d60681a] .cm-foldGutter svg{display:block;width:10px;height:10px;fill:currentColor}.rc-code-mirror.rc-code-mirror--editor[data-v-0d60681a] .cm-editor.cm-focused{outline:none}.rc-code-mirror.rc-code-mirror--editor[data-v-0d60681a] .cm-editor.cm-focused:after{content:"";position:absolute;inset:0;border:2px solid var(--primary-keyboard-focus);pointer-events:none;z-index:301}.rc-code-mirror.rc-code-mirror--input[data-v-0d60681a] .cm-editor{min-height:40px;box-sizing:border-box;padding:10px;background-color:var(--input-bg);border-radius:var(--border-radius);border:solid var(--border-width) var(--input-border);color:var(--input-text)}.rc-code-mirror.rc-code-mirror--input[data-v-0d60681a] .cm-editor:hover{border-color:var(--input-hover-border)}.rc-code-mirror.rc-code-mirror--input[data-v-0d60681a] .cm-editor.cm-focused{border-color:var(--primary-border)}.rc-code-mirror.rc-code-mirror--input[data-v-0d60681a] .cm-editor .cm-scroller{font-family:Lato,arial,helvetica,sans-serif}.rc-code-mirror.rc-code-mirror--input[data-v-0d60681a] .cm-editor .cm-content,.rc-code-mirror.rc-code-mirror--input[data-v-0d60681a] .cm-editor .cm-line{padding:0}.rc-code-mirror.rc-code-mirror--input[data-v-0d60681a] .cm-editor .cm-line:not(:last-child):after{content:"↵"/"";margin-left:2px;color:var(--muted);pointer-events:none}.rc-code-mirror.rc-code-mirror--input[data-v-0d60681a] .cm-editor .cm-selectionBackground,.rc-code-mirror.rc-code-mirror--input[data-v-0d60681a] .cm-editor.cm-focused .cm-selectionBackground{background-color:var(--primary)}.rc-code-mirror[data-v-0d60681a]:is(.theme-dark *){--rc-cm-bg:#171c22;--rc-cm-selection:#303030;--rc-cm-key:#79b8ff;--rc-cm-string:#e0a458;--rc-cm-keyword:#e48ad8;--rc-cm-comment:#9aa1ac;--rc-cm-text:#e6e9ef;--rc-cm-gutter:#9aa1ac;--rc-cm-fold-hover:#3c4655;--rc-cm-active-line:hsla(0,0%,100%,.04);--rc-cm-search-match:rgba(255,213,0,.25);--rc-cm-search-match-selected:rgba(255,140,0,.45);--rc-cm-color-scheme:dark}',""]),t["default"]=s},35087:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".popperContainer[data-v-40d040dc]{display:contents}.popperContainer[data-v-40d040dc] .v-popper__popper .v-popper__wrapper{box-shadow:0 6px 18px 0 rgba(0,0,0,.25),0 4px 10px 0 rgba(0,0,0,.15);border-radius:var(--border-radius-lg)}.popperContainer[data-v-40d040dc] .v-popper__popper .v-popper__wrapper .v-popper__arrow-container{display:none}.popperContainer[data-v-40d040dc] .v-popper__popper .v-popper__wrapper .v-popper__inner{overflow:unset;padding:10px 0 10px 0}.popperContainer[data-v-40d040dc] .rc-dropdown-submenu{transition:none}.popperContainer[data-v-40d040dc] .rc-dropdown-submenu .v-popper__inner{display:flex;flex-direction:column;box-sizing:border-box}.popperContainer[data-v-40d040dc] .rc-dropdown-submenu .v-popper__inner .dropdownTarget,.popperContainer[data-v-40d040dc] .rc-dropdown-submenu .v-popper__inner>div{display:flex;flex-direction:column;min-height:0}.popperContainer[data-v-40d040dc] .rc-dropdown-submenu .v-popper__inner .dropdownTarget{overflow-y:auto}.dropdownTarget[data-v-40d040dc]{padding:3px 0}.dropdownTarget[data-v-40d040dc]:focus,.dropdownTarget[data-v-40d040dc]:focus-visible{outline:none}",""]),t["default"]=s},12066:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".rc-dropdown-group-label[data-v-659e63c8]{padding:4px 8px;margin:0 9px;color:var(--dropdown-group-text);font-size:11px;font-weight:600;line-height:16px;letter-spacing:.6px;text-transform:uppercase}",""]),t["default"]=s},48282:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,"[dropdown-menu-item][data-v-4347a406]{display:flex;gap:8px;align-items:center;padding:9px 8px;margin:0 9px;border-radius:4px}[dropdown-menu-item][data-v-4347a406]:hover{cursor:pointer;background-color:var(--dropdown-hover-bg)}[dropdown-menu-item][data-v-4347a406]:focus-visible{outline:2px solid var(--primary-keyboard-focus);outline-offset:0}[dropdown-menu-item][disabled][data-v-4347a406]{color:var(--disabled-text)}[dropdown-menu-item][disabled][data-v-4347a406]:hover{cursor:not-allowed}[dropdown-menu-item] .dropdown-item-after[data-v-4347a406]{display:flex;align-items:center;margin-left:auto;padding-left:16px}",""]),t["default"]=s},11121:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,"[dropdown-menu-item][data-v-278e9673]{display:flex;gap:8px;align-items:center;padding:9px 8px;margin:0 9px;border-radius:4px}[dropdown-menu-item][data-v-278e9673]:hover{cursor:pointer;background-color:var(--dropdown-hover-bg)}[dropdown-menu-item][data-v-278e9673]:focus-visible{outline:2px solid var(--primary-keyboard-focus);outline-offset:0}[dropdown-menu-item][disabled][data-v-278e9673]{color:var(--disabled-text)}[dropdown-menu-item][disabled][data-v-278e9673]:hover{cursor:not-allowed}[dropdown-menu-item] .dropdown-item-after[data-v-278e9673]{display:flex;align-items:center;margin-left:auto;padding-left:16px}",""]),t["default"]=s},76444:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,"[dropdown-menu-item][data-v-045833c6]{display:flex;gap:8px;align-items:center;padding:9px 8px;margin:0 9px;border-radius:4px}[dropdown-menu-item][data-v-045833c6]:hover{cursor:pointer;background-color:var(--dropdown-hover-bg)}[dropdown-menu-item][data-v-045833c6]:focus-visible{outline:2px solid var(--primary-keyboard-focus);outline-offset:0}[dropdown-menu-item][disabled][data-v-045833c6]{color:var(--disabled-text)}[dropdown-menu-item][disabled][data-v-045833c6]:hover{cursor:not-allowed}[dropdown-menu-item] .dropdown-item-after[data-v-045833c6]{display:flex;align-items:center;margin-left:auto;padding-left:16px}",""]),t["default"]=s},51487:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,"[dropdown-menu-item][data-v-5643239d]{display:flex;gap:8px;align-items:center;padding:9px 8px;margin:0 9px;border-radius:4px}[dropdown-menu-item][data-v-5643239d]:hover{cursor:pointer;background-color:var(--dropdown-hover-bg)}[dropdown-menu-item][data-v-5643239d]:focus-visible{outline:2px solid var(--primary-keyboard-focus);outline-offset:0}[dropdown-menu-item][disabled][data-v-5643239d]{color:var(--disabled-text)}[dropdown-menu-item][disabled][data-v-5643239d]:hover{cursor:not-allowed}",""]),t["default"]=s},99853:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,"[dropdown-menu-item][data-v-5423a193]{display:flex;gap:8px;align-items:center;padding:9px 8px;margin:0 9px;border-radius:4px}[dropdown-menu-item].expanded[data-v-5423a193],[dropdown-menu-item][data-v-5423a193]:hover{cursor:pointer;background-color:var(--dropdown-hover-bg)}[dropdown-menu-item][data-v-5423a193]:focus-visible{outline:2px solid var(--primary-keyboard-focus);outline-offset:0}[dropdown-menu-item][disabled][data-v-5423a193]{color:var(--disabled-text)}[dropdown-menu-item][disabled][data-v-5423a193]:hover{cursor:not-allowed}[dropdown-menu-item] .dropdown-item-after[data-v-5423a193]{display:flex;align-items:center;gap:8px;margin-left:auto;padding-left:16px}",""]),t["default"]=s},43383:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,"div[data-v-49193dc2]{margin:0 0 10px 0;color:var(--body-text);font-family:var(--title-font-family,unset);font-style:normal;font-weight:400;text-transform:none}.size-1[data-v-49193dc2]{font-size:24px}.size-2[data-v-49193dc2]{font-size:21px}.size-3[data-v-49193dc2]{font-size:18px}.size-4[data-v-49193dc2]{font-size:16px}.size-5[data-v-49193dc2]{font-size:14px}.size-6[data-v-49193dc2]{font-size:12px;text-transform:uppercase}",""]),t["default"]=s},78761:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".rc-icon[data-v-2624fc9a]{font-size:var(--v4e6c3731);color:var(--v17bbae7c)}",""]),t["default"]=s},33440:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".rc-icon-tooltip[data-v-a4945d12]{color:inherit}.rc-icon-tooltip.rc-button.btn.btn-small[data-v-a4945d12]{--rc-button-padding:0;min-height:0;font-size:inherit;line-height:inherit;vertical-align:baseline}",""]),t["default"]=s},10557:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".item-card[data-v-280664a8]{display:flex;padding:16px;align-items:flex-start;gap:var(--gap-lg);border-radius:var(--border-radius-md);border:1px solid var(--border);background:var(--body-bg);cursor:var(--v4111c564)}.item-card.clickable[data-v-280664a8]:hover,.item-card.selected[data-v-280664a8]{border-color:var(--primary)}.item-card.disabled[data-v-280664a8]{cursor:not-allowed;color:var(--disabled-text)}.item-card.disabled[data-v-280664a8],.item-card.disabled .item-card-image[data-v-280664a8]{background-color:var(--disabled-bg)}.item-card.disabled .item-card-content[data-v-280664a8],.item-card.disabled .item-card-header-title[data-v-280664a8]{color:var(--disabled-text)}.item-card[data-v-280664a8]:has(.item-card-header-left:focus-visible){border-color:var(--primary);outline:2px solid var(--primary-keyboard-focus);outline-offset:-2px}.item-card[data-v-280664a8]:focus-visible{outline:none}.item-card-image[data-v-280664a8]{width:48px;height:48px;display:flex;align-items:center;justify-content:center;background:var(--rc-image-bg);border-radius:var(--border-radius);color:var(--rc-image-color)}.item-card-image.small[data-v-280664a8]{width:32px;height:32px;margin-right:12px}.item-card-header[data-v-280664a8]{display:flex;align-items:center;justify-content:space-between;width:100%;height:24px;color:var(--body-text)}.item-card-header.small[data-v-280664a8]{height:32px}.item-card-header-left[data-v-280664a8],.item-card-header-right[data-v-280664a8]{display:flex;align-items:center}.item-card-header-left[data-v-280664a8]{flex-grow:1;min-width:0}.item-card-header-left[data-v-280664a8]:focus-visible{outline:none}.item-card-header-title[data-v-280664a8]{max-width:80%;font-size:18px;font-weight:600;margin-bottom:0;line-height:24px;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.item-card-header-statuses[data-v-280664a8]{display:flex;align-items:flex-start;gap:12px}.item-card-header-statuses-status[data-v-280664a8]{width:24px;height:24px;display:flex;align-items:center;justify-content:center}.item-card-header-statuses-status .icon[data-v-280664a8]{font-size:23px}.item-card-header-statuses-status .icon.error[data-v-280664a8]{color:var(--error)}.item-card-header-statuses-status .icon.info[data-v-280664a8]{color:var(--info)}.item-card-header-statuses-status .icon.success[data-v-280664a8]{color:var(--success)}.item-card-header-action-menu[data-v-280664a8]{margin-left:8px;margin-right:-8px}.item-card-content[data-v-280664a8]{display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden;text-overflow:ellipsis;line-height:21px;word-break:break-word}.item-card-pill[data-v-280664a8]{display:flex;width:48px;padding:4px 8px;margin-top:16px;justify-content:center;align-items:center;border-radius:var(--border-radius);background:var(--default);text-transform:uppercase;color:var(--disabled-text);font-size:10px;font-weight:600}.item-card-body[data-v-280664a8]{display:flex;flex-direction:row;width:100%;gap:var(--gap-lg)}.item-card-body-details[data-v-280664a8],.item-card-body.small[data-v-280664a8]{flex-direction:column;align-items:flex-start;gap:var(--gap);flex:1}.item-card-body-details[data-v-280664a8]{display:flex;width:calc(100% - var(--gap-lg) - 48px)}.item-card-body-details.small[data-v-280664a8]{width:100%}",""]),t["default"]=s},7007:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".rc-item-card-action .v-popper .icon-actions{color:var(--body-text);font-size:19px}",""]),t["default"]=s},32128:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,"hr.vertical[data-v-44167622]{align-self:stretch;height:auto;margin:0;border-top:none;border-left:1px solid var(--border)}",""]),t["default"]=s},89906:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".mappings-cell[data-v-5bd9a608]{display:flex;flex-direction:column;gap:8px}.mapping-entry[data-v-5bd9a608]{display:flex;align-items:center;gap:6px;font-size:13px;color:var(--muted)}.mapping-entry .icon[data-v-5bd9a608]{font-size:16px}",""]),t["default"]=s},79496:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".role[data-v-54d15ef1]{align-items:center;background-color:rgba(0,0,0,.05);border:1px solid var(--header-border);border-radius:5px;color:var(--tag-text);line-height:20px;padding:2px 5px;white-space:nowrap;display:inline-flex;margin-right:3px}.role-value.text-link-enabled[data-v-54d15ef1]{cursor:pointer}.role-value.text-link-enabled[data-v-54d15ef1]:hover{color:var(--primary)}.role-value+.icon-close[data-v-54d15ef1]{margin-left:3px;cursor:pointer}.role-value+.icon-close[data-v-54d15ef1]:hover{color:var(--primary)}.project-members[data-v-54d15ef1] .group-bar{display:flex;justify-content:space-between}.cluster-add[data-v-54d15ef1]{justify-content:flex-end}",""]),t["default"]=s},34579:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=n(63766),l=a()(i());l.i(s.A),l.push([e.id,"#__layout,#__nuxt,MAIN,body{height:100%}.harvester-shell-container{display:flex;flex-direction:column;position:relative;height:100%;min-height:0;overflow:hidden}.harvester-shell-container .resize-observer{display:none}.harvester-shell-container .shell-search{display:flex;align-items:center;gap:8px;justify-content:flex-end;position:absolute;top:8px;right:10px;z-index:5;padding:8px;border-radius:6px;border:1px solid var(--border);background:color-mix(in srgb,var(--body-bg) 88%,transparent)}.harvester-shell-container .shell-search-input{min-width:220px;max-width:420px;flex:0 1 320px;border:1px solid var(--border);border-radius:4px;background:var(--body-bg);color:var(--body-text);padding:6px 8px}.harvester-shell-container .shell-search-btn{min-width:64px}.harvester-shell-container .shell-body{flex:1 1 auto;height:100%;width:100%;min-height:0;padding:0 10px;box-sizing:border-box}.harvester-shell-container .terminal.xterm,.harvester-shell-container .terminal.xterm .xterm-screen,.harvester-shell-container .terminal.xterm .xterm-scrollable-element,.harvester-shell-container .terminal.xterm .xterm-viewport{width:100%;height:100%}.harvester-shell-container .terminal.xterm .xterm-scrollable-element{min-height:100%}",""]),t["default"]=l},76113:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".mappings-columns[data-v-fb484656]{display:flex;flex-direction:column;gap:32px}@media only screen and (min-width:768px){.mappings-columns[data-v-fb484656]{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr)}}@media only screen and (min-width:992px){.mappings-columns[data-v-fb484656]{gap:48px}}@media only screen and (min-width:1281px){.mappings-columns[data-v-fb484656]{gap:64px}}.configure-mappings[data-v-fb484656]{display:flex;flex-direction:column;gap:24px}.configure-mappings .line-height-20[data-v-fb484656]{line-height:20px}.source-detail[data-v-fb484656]{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}",""]),t["default"]=s},79415:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".requirements-banner[data-v-4846def2]{font-weight:400}.requirements-banner .requirements-banner-title[data-v-4846def2]{font-weight:600}.configure-provider-step[data-v-4846def2]{display:flex;flex-direction:column;gap:24px}.configure-provider-step .line-height-20[data-v-4846def2]{line-height:20px}.configure-provider-step .configure-provider-step-content[data-v-4846def2]{display:flex;flex-direction:column;gap:12px}.configure-provider-step .configure-provider-step-content .configure-provider-step-form[data-v-4846def2]{display:flex;flex-direction:column;gap:20px}.configure-provider-step[data-v-4846def2] .checkbox-label{color:var(--body-text)}",""]),t["default"]=s},82466:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".mapping-column[data-v-2e6ca264]{display:flex;gap:12px;flex-direction:column}.mapping-column[data-v-2e6ca264] .item-card-header{display:none}.mapping-section-title[data-v-2e6ca264]{font-weight:600;margin:0 0 5px 0;line-height:28px}.card-content-row[data-v-2e6ca264]{display:flex;align-items:center;gap:16px;width:100%}.card-content-column[data-v-2e6ca264]{display:flex;flex-direction:column;gap:8px;width:100%}.mapping-source[data-v-2e6ca264]{display:flex;flex-direction:column;flex:2;min-width:100px;font-size:14px;line-height:20px}.mapping-source .source-name[data-v-2e6ca264]{font-weight:600;font-size:14px}.mapping-source .source-detail[data-v-2e6ca264],.mapping-source .source-name[data-v-2e6ca264]{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.mapping-source .used-by[data-v-2e6ca264]{margin-top:4px;font-size:14px;line-height:24px}.mapping-arrow[data-v-2e6ca264]{font-size:22px;flex-shrink:0}.mapping-target[data-v-2e6ca264]{flex:3;min-width:0;overflow:hidden}.line-height-20[data-v-2e6ca264]{line-height:20px}.storage-defaults-row[data-v-2e6ca264]{width:100%}.storage-defaults[data-v-2e6ca264]{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:8px 12px;border-radius:4px;background-color:var(--body-bg)}.storage-defaults .storage-defaults-info[data-v-2e6ca264]{display:flex;flex-direction:column;min-width:0}.storage-defaults .storage-defaults-summary[data-v-2e6ca264]{font-size:13px;line-height:20px}.storage-defaults .storage-defaults-inherited[data-v-2e6ca264]{font-size:12px;line-height:18px}.storage-defaults .storage-defaults-edit[data-v-2e6ca264]{flex-shrink:0;cursor:pointer}.bg-light-gray[data-v-2e6ca264]{background-color:var(--category-active)!important;border:0}",""]),t["default"]=s},68936:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".review-migration[data-v-2a853fb2]{gap:36px}.review-migration-content[data-v-2a853fb2]{display:flex;flex-direction:column;gap:20px}.section-title[data-v-2a853fb2]{font-weight:600}.name-row[data-v-2a853fb2]{align-items:start}.name-row[data-v-2a853fb2],.summary-row[data-v-2a853fb2]{display:grid;grid-template-columns:1fr 1fr;gap:12px clamp(12px,1vw,96px)}.summary-row[data-v-2a853fb2]{line-height:20px;margin-top:12px}.section-header[data-v-2a853fb2]{display:flex;flex-direction:column;gap:4px}.section-header .section-description[data-v-2a853fb2]{font-size:14px}.migration-mode-column[data-v-2a853fb2]{display:flex;flex-direction:column;align-items:flex-start;gap:8px;font-size:14px}.migration-mode-column .cold-migration-badge[data-v-2a853fb2]{padding:2px 10px;border-radius:4px;opacity:.8;background:rgba(224,191,90,.16);color:#e0bf5a;font-size:12px;line-height:18px;font-weight:600}.theme-light .migration-mode-column .cold-migration-badge[data-v-2a853fb2]{background:rgba(168,128,26,.16)}.stats-column[data-v-2a853fb2]{display:grid;grid-template-columns:auto auto;justify-content:start;align-content:start;-moz-column-gap:clamp(24px,4vw,64px);column-gap:clamp(24px,4vw,64px);row-gap:8px}.detail-label[data-v-2a853fb2]{font-size:14px;color:var(--muted)}.detail-value[data-v-2a853fb2]{font-weight:600;font-size:14px}.edit-selection-link[data-v-2a853fb2]{cursor:pointer;color:var(--link);font-size:14px}.vm-sortable-table[data-v-2a853fb2] .fixed-header-actions{align-items:end}.vm-sortable-table[data-v-2a853fb2] table{table-layout:fixed}.vm-sortable-table[data-v-2a853fb2] td{vertical-align:middle;overflow:hidden}.vm-sortable-table[data-v-2a853fb2] td:first-child,.vm-sortable-table[data-v-2a853fb2] th:first-child{padding-left:16px}.vm-name-cell[data-v-2a853fb2]{display:flex;flex-direction:column}.vm-name-cell .vm-name[data-v-2a853fb2]{font-weight:600}.vm-name-cell .vm-id[data-v-2a853fb2]{font-size:12px}.mapping-cell .mapping-target[data-v-2a853fb2]{margin-left:4px;white-space:nowrap}.mapping-cell+.mapping-cell[data-v-2a853fb2]{margin-top:8px}.banner-title[data-v-2a853fb2]{font-weight:600}.migration-details[data-v-2a853fb2]{display:flex;flex-direction:column;gap:12px}header[data-v-2a853fb2]{margin:0}.vm-section[data-v-2a853fb2]{display:flex;flex-direction:column;gap:16px}",""]),t["default"]=s},72559:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".vm-table-title .text-deemphasized[data-v-010bc59d]{font-size:13px}.vm-table-title .selected-actions[data-v-010bc59d]{display:flex;align-items:center;gap:8px;font-size:13px}.vm-table-title .selected-actions a[data-v-010bc59d]{cursor:pointer}.vm-table-title .selected-actions a.disabled[data-v-010bc59d]{color:var(--muted);cursor:default;pointer-events:none}.vm-name-cell[data-v-010bc59d]{display:flex;flex-direction:column;font-size:14px}.vm-name-cell .vm-id[data-v-010bc59d],.vm-name-cell .vm-name[data-v-010bc59d]{line-height:20px}.select-vms-step[data-v-010bc59d]{position:relative;display:flex;flex-direction:column;gap:20px}.select-vms-step .line-height-20[data-v-010bc59d]{line-height:20px}[data-v-010bc59d] .select-all-banner-row .select-all-banner-cell{text-align:center;padding:8px 16px;background-color:var(--sortable-table-header-bg);border-bottom:1px solid var(--border);font-size:13px}[data-v-010bc59d] .select-all-banner-row .select-all-banner-cell a{color:var(--primary);cursor:pointer;font-weight:600;margin-left:5px}[data-v-010bc59d] .select-all-banner-row .select-all-banner-cell a:hover{text-decoration:underline}",""]),t["default"]=s},65897:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".storage-defaults-modal[data-v-b0278fe2]{z-index:45}.storage-defaults-card[data-v-b0278fe2]{margin:0;padding:20px}.description[data-v-b0278fe2]{margin-bottom:16px;line-height:20px}.settings-box[data-v-b0278fe2]{display:flex;flex-direction:column;gap:20px;padding:16px;border-radius:6px;background-color:var(--category-active)}.access-mode[data-v-b0278fe2],.volume-mode[data-v-b0278fe2]{max-width:280px}.buttons[data-v-b0278fe2]{align-items:center;justify-content:space-between;width:100%}.buttons[data-v-b0278fe2],.buttons .right-buttons[data-v-b0278fe2]{display:flex}",""]),t["default"]=s},11881:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".bundleModal .support-modal[data-v-edef926a]{border-radius:var(--border-radius);max-height:100vh}.bundleModal .labeled-select.taggable[data-v-edef926a] .vs__selected-options .vs__selected.vs__selected>button{margin:0 7px}.bundleModal .bundle[data-v-edef926a]{cursor:pointer;color:var(--primary)}.bundleModal .icon-spinner[data-v-edef926a]{font-size:100px}.bundleModal .content .circle[data-v-edef926a]{padding:10px 0;height:160px}.bundleModal .content .namespace-select[data-v-edef926a] .vs__dropdown-menu{max-height:210px}.bundleModal div[data-v-edef926a]{line-height:normal}.bundleModal .footer[data-v-edef926a]{display:flex;justify-content:center}",""]),t["default"]=s},48964:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,"#air-gap[data-v-cb2a8aec]{padding:20px}#air-gap[data-v-cb2a8aec] .image-group .radio-group{display:flex}#air-gap[data-v-cb2a8aec] .image-group .radio-group .radio-container{margin-right:30px}#air-gap .parent[data-v-cb2a8aec]{grid-template-columns:auto 40px}#air-gap .chooseFile[data-v-cb2a8aec]{display:flex;align-items:center}",""]),t["default"]=s},64970:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".header H1[data-v-a0fecebc]{flex:1}.header[data-v-a0fecebc]{border-bottom:1px solid var(--border);margin-bottom:0;padding-bottom:20px}",""]),t["default"]=s},18164:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".link-example[data-v-07e5f612]{display:flex;align-content:center}.link-example a[data-v-07e5f612]{margin:auto}.logo-container[data-v-07e5f612]{display:flex;flex-direction:column}.logo-container[data-v-07e5f612] .simple-box{position:relative;flex:1;max-height:120px}.logo-container[data-v-07e5f612] .simple-box .content{height:100%;display:flex}.logo-container[data-v-07e5f612] .simple-box .logo-preview{max-width:100%}.logo-container LABEL[data-v-07e5f612]{position:absolute;top:10px;left:10px}",""]),t["default"]=s},70908:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,'#__layout,#__nuxt,body,html,main{height:100%}.serial-console-page{position:fixed;inset:0;min-height:0;background:var(--body-bg);color:var(--terminal-text)}.serial-console-page:after{content:"";position:absolute;left:0;right:0;bottom:0;height:6px;pointer-events:none;background:linear-gradient(180deg,transparent,rgba(0,0,0,.15),rgba(0,0,0,.25))}.serial-console-page .harvester-shell-container{height:100%;background:var(--terminal-bg)}',""]),t["default"]=s},81945:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".content[data-v-74e3f663]{display:grid;grid-column-gap:20px;grid-row-gap:20px;grid-template-columns:70% 30%}.only-community[data-v-74e3f663]{display:grid;grid-template-columns:100%}.community[data-v-74e3f663]{border-left:1px solid var(--border);padding-left:20px}.community>h2[data-v-74e3f663]{font-size:18px;font-weight:300;margin-bottom:20px}.community .support-link[data-v-74e3f663]{margin:10px 0}.box[data-v-74e3f663]{padding:20px;border:1px solid var(--border)}.box.box-primary[data-v-74e3f663]{border-color:var(--primary)}.box>h2[data-v-74e3f663]{font-size:20px;font-weight:300}.box>div[data-v-74e3f663]{font-weight:300;line-height:18px;opacity:.8}.role-secondary[data-v-74e3f663]:focus{background-color:transparent}.warning[data-v-74e3f663]{margin:0 -5px 0 -5px;padding:5px;background-color:var(--warning-banner-bg)}",""]),t["default"]=s},66208:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,'.dashboard-root[data-v-140c2578]{display:flex;flex-direction:column;height:100vh}.dashboard-content[data-v-140c2578]{display:grid;flex-grow:1;grid-template-areas:"main";grid-template-columns:auto;grid-template-rows:auto}.logo[data-v-140c2578]{margin:200px 0 40px 0}.logo[data-v-140c2578],.tagline[data-v-140c2578]{display:flex;justify-content:center}.tagline[data-v-140c2578]{margin-top:30px}.tagline>div[data-v-140c2578]{font-size:16px;line-height:22px;max-width:80%;text-align:center}.description[data-v-140c2578]{font-size:24px!important;font-weight:400}',""]),t["default"]=s},78622:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".plan-name-cell .plan-name[data-v-3ddd027e]{font-weight:500;line-height:20px}.plan-name-cell .plan-vms[data-v-3ddd027e]{font-size:12px;line-height:20px;color:var(--muted)}.progress-cells[data-v-3ddd027e]{display:flex;flex-direction:column;gap:16px}.vm-progress-header[data-v-3ddd027e]{display:flex;justify-content:space-between;align-items:center;margin-bottom:4px}.vm-name[data-v-3ddd027e]{font-size:14px;gap:4px}.vm-detail-link[data-v-3ddd027e],.vm-name[data-v-3ddd027e]{display:inline-flex;align-items:center}.vm-name-block[data-v-3ddd027e]{display:flex;flex-direction:row;gap:8px;align-items:center}.vm-id[data-v-3ddd027e]{font-size:11px}.vm-pct[data-v-3ddd027e]{font-size:14px;min-width:40px;text-align:left}.vm-pct-block[data-v-3ddd027e]{display:flex;align-items:center;gap:14px;justify-content:space-between}.vm-bar[data-v-3ddd027e]{width:100%}.step-label[data-v-3ddd027e]{font-size:13px;margin-top:4px;line-height:20px}.step-label.text-error[data-v-3ddd027e]{color:var(--error)}.table-title[data-v-3ddd027e]{font-weight:600}",""]),t["default"]=s},24135:function(e,t,n){"use strict";var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".vue-flow__controls{box-shadow:0 0 2px 1px rgba(0,0,0,.08)}.vue-flow__controls-button{background:#fefefe;border:none;border-bottom:1px solid #eee;box-sizing:content-box;display:flex;justify-content:center;align-items:center;width:16px;height:16px;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;user-select:none;padding:5px}.vue-flow__controls-button svg{width:100%;max-width:12px;max-height:12px}.vue-flow__controls-button:hover{background:#f4f4f4}.vue-flow__controls-button:disabled{pointer-events:none}.vue-flow__controls-button:disabled svg{fill-opacity:.4}",""]),t.A=s},72790:function(e,t,n){"use strict";var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".vue-flow{position:relative;width:100%;height:100%;overflow:hidden;z-index:0;direction:ltr}.vue-flow__container{position:absolute;height:100%;width:100%;left:0;top:0}.vue-flow__pane{z-index:1}.vue-flow__pane.draggable{cursor:grab}.vue-flow__pane.selection{cursor:pointer}.vue-flow__pane.dragging{cursor:grabbing}.vue-flow__transformationpane{transform-origin:0 0;z-index:2;pointer-events:none}.vue-flow__viewport{z-index:4;overflow:clip}.vue-flow__selection{z-index:6}.vue-flow__edge-labels{position:absolute;width:100%;height:100%;pointer-events:none;-webkit-user-select:none;-moz-user-select:none;user-select:none}.vue-flow__nodesselection-rect:focus,.vue-flow__nodesselection-rect:focus-visible{outline:none}.vue-flow .vue-flow__edges{pointer-events:none;overflow:visible}.vue-flow__connection-path,.vue-flow__edge-path{stroke:#b1b1b7;stroke-width:1;fill:none}.vue-flow__edge{pointer-events:visibleStroke;cursor:pointer}.vue-flow__edge.animated path{stroke-dasharray:5;animation:dashdraw .5s linear infinite}.vue-flow__edge.animated path.vue-flow__edge-interaction{stroke-dasharray:none;animation:none}.vue-flow__edge.inactive{pointer-events:none}.vue-flow__edge.selected,.vue-flow__edge:focus,.vue-flow__edge:focus-visible{outline:none}.vue-flow__edge.selected .vue-flow__edge-path,.vue-flow__edge:focus .vue-flow__edge-path,.vue-flow__edge:focus-visible .vue-flow__edge-path{stroke:#555}.vue-flow__edge-textwrapper{pointer-events:all}.vue-flow__edge-textbg{fill:#fff}.vue-flow__edge-text{pointer-events:none;-webkit-user-select:none;-moz-user-select:none;user-select:none}.vue-flow__connection{pointer-events:none}.vue-flow__connection .animated{stroke-dasharray:5;animation:dashdraw .5s linear infinite}.vue-flow__connectionline{z-index:1001}.vue-flow__nodes{pointer-events:none;transform-origin:0 0}.vue-flow__node{position:absolute;-webkit-user-select:none;-moz-user-select:none;user-select:none;pointer-events:all;transform-origin:0 0;box-sizing:border-box;cursor:default}.vue-flow__node.draggable{cursor:grab;pointer-events:all}.vue-flow__node.draggable.dragging{cursor:grabbing}.vue-flow__nodesselection{z-index:3;transform-origin:left top;pointer-events:none}.vue-flow__nodesselection-rect{position:absolute;pointer-events:all;cursor:grab}.vue-flow__nodesselection-rect.dragging{cursor:grabbing}.vue-flow__handle{position:absolute;pointer-events:none;min-width:5px;min-height:5px}.vue-flow__handle.connectable{pointer-events:all;cursor:crosshair}.vue-flow__handle-bottom{left:50%;bottom:0;transform:translate(-50%,50%)}.vue-flow__handle-top{left:50%;top:0;transform:translate(-50%,-50%)}.vue-flow__handle-left{top:50%;left:0;transform:translate(-50%,-50%)}.vue-flow__handle-right{top:50%;right:0;transform:translate(50%,-50%)}.vue-flow__edgeupdater{cursor:move;pointer-events:all}.vue-flow__panel{position:absolute;z-index:5;margin:15px}.vue-flow__panel.top{top:0}.vue-flow__panel.bottom{bottom:0}.vue-flow__panel.left{left:0}.vue-flow__panel.right{right:0}.vue-flow__panel.center{left:50%;transform:translateX(-50%)}@keyframes dashdraw{0%{stroke-dashoffset:10}}",""]),t.A=s},47142:function(e,t,n){"use strict";var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,":root{--vf-node-bg:#fff;--vf-node-text:#222;--vf-connection-path:#b1b1b7;--vf-handle:#555}.vue-flow__edge.updating .vue-flow__edge-path{stroke:#777}.vue-flow__edge-text{font-size:10px}.vue-flow__edge-textbg{fill:#fff}.vue-flow__connection-path{stroke:var(--vf-connection-path)}.vue-flow__node{cursor:grab}.vue-flow__node.selectable:focus,.vue-flow__node.selectable:focus-visible{outline:none}.vue-flow__node-default,.vue-flow__node-input,.vue-flow__node-output{padding:10px;border-radius:3px;width:150px;font-size:12px;text-align:center;border-width:1px;border-style:solid;color:var(--vf-node-text);background-color:var(--vf-node-bg);border-color:var(--vf-node-color)}.vue-flow__node-default.selected,.vue-flow__node-default.selected:hover,.vue-flow__node-input.selected,.vue-flow__node-input.selected:hover,.vue-flow__node-output.selected,.vue-flow__node-output.selected:hover{box-shadow:0 0 0 .5px var(--vf-box-shadow)}.vue-flow__node-default.selected,.vue-flow__node-default:focus,.vue-flow__node-default:focus-visible,.vue-flow__node-input.selected,.vue-flow__node-input:focus,.vue-flow__node-input:focus-visible,.vue-flow__node-output.selected,.vue-flow__node-output:focus,.vue-flow__node-output:focus-visible{outline:none;border:1px solid #555}.vue-flow__node-default .vue-flow__handle,.vue-flow__node-input .vue-flow__handle,.vue-flow__node-output .vue-flow__handle{background:var(--vf-handle)}.vue-flow__node-default.selectable:hover,.vue-flow__node-input.selectable:hover,.vue-flow__node-output.selectable:hover{box-shadow:0 1px 4px 1px rgba(0,0,0,.08)}.vue-flow__node-input{--vf-node-color:var(--vf-node-color,#0041d0);--vf-handle:var(--vf-node-color,#0041d0);--vf-box-shadow:var(--vf-node-color,#0041d0);background:var(--vf-node-bg);border-color:var(--vf-node-color,#0041d0)}.vue-flow__node-input.selected,.vue-flow__node-input:focus,.vue-flow__node-input:focus-visible{outline:none;border:1px solid var(--vf-node-color,#0041d0)}.vue-flow__node-default{--vf-handle:var(--vf-node-color,#1a192b);--vf-box-shadow:var(--vf-node-color,#1a192b);background:var(--vf-node-bg);border-color:var(--vf-node-color,#1a192b)}.vue-flow__node-default.selected,.vue-flow__node-default:focus,.vue-flow__node-default:focus-visible{outline:none;border:1px solid var(--vf-node-color,#1a192b)}.vue-flow__node-output{--vf-handle:var(--vf-node-color,#ff0072);--vf-box-shadow:var(--vf-node-color,#ff0072);background:var(--vf-node-bg);border-color:var(--vf-node-color,#ff0072)}.vue-flow__node-output.selected,.vue-flow__node-output:focus,.vue-flow__node-output:focus-visible{outline:none;border:1px solid var(--vf-node-color,#ff0072)}.vue-flow__nodesselection-rect,.vue-flow__selection{background:rgba(0,89,220,.08);border:1px dotted rgba(0,89,220,.8)}.vue-flow__nodesselection-rect:focus,.vue-flow__nodesselection-rect:focus-visible,.vue-flow__selection:focus,.vue-flow__selection:focus-visible{outline:none}.vue-flow__handle{width:6px;height:6px;background:var(--vf-handle);border:1px solid #fff;border-radius:100%}",""]),t.A=s},60912:function(e,t,n){"use strict";var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=a()(i());s.push([e.id,".vue-flow__minimap{background-color:#fff}.vue-flow__minimap.pannable{cursor:grab}.vue-flow__minimap.dragging{cursor:grabbing}.vue-flow__minimap-mask.pannable{cursor:grab}",""]),t.A=s},89009:function(e,t,n){"use strict";n.r(t);var r=n(36758),i=n.n(r),o=n(40935),a=n.n(o),s=n(72790),l=n(47142),c=n(24135),u=n(60912),d=a()(i());d.i(s.A),d.i(l.A),d.i(c.A),d.i(u.A),d.push([e.id,"",""]),t["default"]=d},40935:function(e){"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map(function(t){var n="",r="undefined"!==typeof t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),r&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),r&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n}).join("")},t.i=function(e,n,r,i,o){"string"===typeof e&&(e=[[null,e,void 0]]);var a={};if(r)for(var s=0;s<this.length;s++){var l=this[s][0];null!=l&&(a[l]=!0)}for(var c=0;c<e.length;c++){var u=[].concat(e[c]);r&&a[u[0]]||("undefined"!==typeof o&&("undefined"===typeof u[5]||(u[1]="@layer".concat(u[5].length>0?" ".concat(u[5]):""," {").concat(u[1],"}")),u[5]=o),n&&(u[2]?(u[1]="@media ".concat(u[2]," {").concat(u[1],"}"),u[2]=n):u[2]=n),i&&(u[4]?(u[1]="@supports (".concat(u[4],") {").concat(u[1],"}"),u[4]=i):u[4]="".concat(i)),t.push(u))}},t}},36758:function(e){"use strict";e.exports=function(e){return e[1]}},23464:function(e){!function(t,n){e.exports=n()}(0,function(){"use strict";var e=1e3,t=6e4,n=36e5,r="millisecond",i="second",o="minute",a="hour",s="day",l="week",c="month",u="quarter",d="year",h="date",p="Invalid Date",f=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,m=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,g={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(e){var t=["th","st","nd","rd"],n=e%100;return"["+e+(t[(n-20)%10]||t[n]||t[0])+"]"}},v=function(e,t,n){var r=String(e);return!r||r.length>=t?e:""+Array(t+1-r.length).join(n)+e},b={s:v,z:function(e){var t=-e.utcOffset(),n=Math.abs(t),r=Math.floor(n/60),i=n%60;return(t<=0?"+":"-")+v(r,2,"0")+":"+v(i,2,"0")},m:function e(t,n){if(t.date()<n.date())return-e(n,t);var r=12*(n.year()-t.year())+(n.month()-t.month()),i=t.clone().add(r,c),o=n-i<0,a=t.clone().add(r+(o?-1:1),c);return+(-(r+(n-i)/(o?i-a:a-i))||0)},a:function(e){return e<0?Math.ceil(e)||0:Math.floor(e)},p:function(e){return{M:c,y:d,w:l,d:s,D:h,h:a,m:o,s:i,ms:r,Q:u}[e]||String(e||"").toLowerCase().replace(/s$/,"")},u:function(e){return void 0===e}},y="en",w={};w[y]=g;var O="$isDayjsObject",S=function(e){return e instanceof k||!(!e||!e[O])},E=function e(t,n,r){var i;if(!t)return y;if("string"==typeof t){var o=t.toLowerCase();w[o]&&(i=o),n&&(w[o]=n,i=o);var a=t.split("-");if(!i&&a.length>1)return e(a[0])}else{var s=t.name;w[s]=t,i=s}return!r&&i&&(y=i),i||!r&&y},x=function(e,t){if(S(e))return e.clone();var n="object"==typeof t?t:{};return n.date=e,n.args=arguments,new k(n)},_=b;_.l=E,_.i=S,_.w=function(e,t){return x(e,{locale:t.$L,utc:t.$u,x:t.$x,$offset:t.$offset})};var k=function(){function g(e){this.$L=E(e.locale,null,!0),this.parse(e),this.$x=this.$x||e.x||{},this[O]=!0}var v=g.prototype;return v.parse=function(e){this.$d=function(e){var t=e.date,n=e.utc;if(null===t)return new Date(NaN);if(_.u(t))return new Date;if(t instanceof Date)return new Date(t);if("string"==typeof t&&!/Z$/i.test(t)){var r=t.match(f);if(r){var i=r[2]-1||0,o=(r[7]||"0").substring(0,3);return n?new Date(Date.UTC(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,o)):new Date(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,o)}}return new Date(t)}(e),this.init()},v.init=function(){var e=this.$d;this.$y=e.getFullYear(),this.$M=e.getMonth(),this.$D=e.getDate(),this.$W=e.getDay(),this.$H=e.getHours(),this.$m=e.getMinutes(),this.$s=e.getSeconds(),this.$ms=e.getMilliseconds()},v.$utils=function(){return _},v.isValid=function(){return!(this.$d.toString()===p)},v.isSame=function(e,t){var n=x(e);return this.startOf(t)<=n&&n<=this.endOf(t)},v.isAfter=function(e,t){return x(e)<this.startOf(t)},v.isBefore=function(e,t){return this.endOf(t)<x(e)},v.$g=function(e,t,n){return _.u(e)?this[t]:this.set(n,e)},v.unix=function(){return Math.floor(this.valueOf()/1e3)},v.valueOf=function(){return this.$d.getTime()},v.startOf=function(e,t){var n=this,r=!!_.u(t)||t,u=_.p(e),p=function(e,t){var i=_.w(n.$u?Date.UTC(n.$y,t,e):new Date(n.$y,t,e),n);return r?i:i.endOf(s)},f=function(e,t){return _.w(n.toDate()[e].apply(n.toDate("s"),(r?[0,0,0,0]:[23,59,59,999]).slice(t)),n)},m=this.$W,g=this.$M,v=this.$D,b="set"+(this.$u?"UTC":"");switch(u){case d:return r?p(1,0):p(31,11);case c:return r?p(1,g):p(0,g+1);case l:var y=this.$locale().weekStart||0,w=(m<y?m+7:m)-y;return p(r?v-w:v+(6-w),g);case s:case h:return f(b+"Hours",0);case a:return f(b+"Minutes",1);case o:return f(b+"Seconds",2);case i:return f(b+"Milliseconds",3);default:return this.clone()}},v.endOf=function(e){return this.startOf(e,!1)},v.$set=function(e,t){var n,l=_.p(e),u="set"+(this.$u?"UTC":""),p=(n={},n[s]=u+"Date",n[h]=u+"Date",n[c]=u+"Month",n[d]=u+"FullYear",n[a]=u+"Hours",n[o]=u+"Minutes",n[i]=u+"Seconds",n[r]=u+"Milliseconds",n)[l],f=l===s?this.$D+(t-this.$W):t;if(l===c||l===d){var m=this.clone().set(h,1);m.$d[p](f),m.init(),this.$d=m.set(h,Math.min(this.$D,m.daysInMonth())).$d}else p&&this.$d[p](f);return this.init(),this},v.set=function(e,t){return this.clone().$set(e,t)},v.get=function(e){return this[_.p(e)]()},v.add=function(r,u){var h,p=this;r=Number(r);var f=_.p(u),m=function(e){var t=x(p);return _.w(t.date(t.date()+Math.round(e*r)),p)};if(f===c)return this.set(c,this.$M+r);if(f===d)return this.set(d,this.$y+r);if(f===s)return m(1);if(f===l)return m(7);var g=(h={},h[o]=t,h[a]=n,h[i]=e,h)[f]||1,v=this.$d.getTime()+r*g;return _.w(v,this)},v.subtract=function(e,t){return this.add(-1*e,t)},v.format=function(e){var t=this,n=this.$locale();if(!this.isValid())return n.invalidDate||p;var r=e||"YYYY-MM-DDTHH:mm:ssZ",i=_.z(this),o=this.$H,a=this.$m,s=this.$M,l=n.weekdays,c=n.months,u=n.meridiem,d=function(e,n,i,o){return e&&(e[n]||e(t,r))||i[n].slice(0,o)},h=function(e){return _.s(o%12||12,e,"0")},f=u||function(e,t,n){var r=e<12?"AM":"PM";return n?r.toLowerCase():r};return r.replace(m,function(e,r){return r||function(e){switch(e){case"YY":return String(t.$y).slice(-2);case"YYYY":return _.s(t.$y,4,"0");case"M":return s+1;case"MM":return _.s(s+1,2,"0");case"MMM":return d(n.monthsShort,s,c,3);case"MMMM":return d(c,s);case"D":return t.$D;case"DD":return _.s(t.$D,2,"0");case"d":return String(t.$W);case"dd":return d(n.weekdaysMin,t.$W,l,2);case"ddd":return d(n.weekdaysShort,t.$W,l,3);case"dddd":return l[t.$W];case"H":return String(o);case"HH":return _.s(o,2,"0");case"h":return h(1);case"hh":return h(2);case"a":return f(o,a,!0);case"A":return f(o,a,!1);case"m":return String(a);case"mm":return _.s(a,2,"0");case"s":return String(t.$s);case"ss":return _.s(t.$s,2,"0");case"SSS":return _.s(t.$ms,3,"0");case"Z":return i}return null}(e)||i.replace(":","")})},v.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},v.diff=function(r,h,p){var f,m=this,g=_.p(h),v=x(r),b=(v.utcOffset()-this.utcOffset())*t,y=this-v,w=function(){return _.m(m,v)};switch(g){case d:f=w()/12;break;case c:f=w();break;case u:f=w()/3;break;case l:f=(y-b)/6048e5;break;case s:f=(y-b)/864e5;break;case a:f=y/n;break;case o:f=y/t;break;case i:f=y/e;break;default:f=y}return p?f:_.a(f)},v.daysInMonth=function(){return this.endOf(c).$D},v.$locale=function(){return w[this.$L]},v.locale=function(e,t){if(!e)return this.$L;var n=this.clone(),r=E(e,t,!0);return r&&(n.$L=r),n},v.clone=function(){return _.w(this.$d,this)},v.toDate=function(){return new Date(this.valueOf())},v.toJSON=function(){return this.isValid()?this.toISOString():null},v.toISOString=function(){return this.$d.toISOString()},v.toString=function(){return this.$d.toUTCString()},g}(),C=k.prototype;return x.prototype=C,[["$ms",r],["$s",i],["$m",o],["$H",a],["$W",s],["$M",c],["$y",d],["$D",h]].forEach(function(e){C[e[1]]=function(t){return this.$g(t,e[0],e[1])}}),x.extend=function(e,t){return e.$i||(e(t,k,x),e.$i=!0),x},x.locale=E,x.isDayjs=S,x.unix=function(e){return x(1e3*e)},x.en=w[y],x.Ls=w,x.p={},x})},70686:function(e,t,n){"use strict";var r=n(64940),i=n(5731),o=n(3468),a=n(69336);e.exports=function(e,t,n){if(!e||"object"!==typeof e&&"function"!==typeof e)throw new o("`obj` must be an object or a function`");if("string"!==typeof t&&"symbol"!==typeof t)throw new o("`property` must be a string or a symbol`");if(arguments.length>3&&"boolean"!==typeof arguments[3]&&null!==arguments[3])throw new o("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&"boolean"!==typeof arguments[4]&&null!==arguments[4])throw new o("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&"boolean"!==typeof arguments[5]&&null!==arguments[5])throw new o("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&"boolean"!==typeof arguments[6])throw new o("`loose`, if provided, must be a boolean");var s=arguments.length>3?arguments[3]:null,l=arguments.length>4?arguments[4]:null,c=arguments.length>5?arguments[5]:null,u=arguments.length>6&&arguments[6],d=!!a&&a(e,t);if(r)r(e,t,{configurable:null===c&&d?d.configurable:!c,enumerable:null===s&&d?d.enumerable:!s,value:n,writable:null===l&&d?d.writable:!l});else{if(!u&&(s||l||c))throw new i("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.");e[t]=n}}},41857:function(e,t,n){"use strict";var r=n(49228),i="function"===typeof Symbol&&"symbol"===typeof Symbol("foo"),o=Object.prototype.toString,a=Array.prototype.concat,s=n(70686),l=function(e){return"function"===typeof e&&"[object Function]"===o.call(e)},c=n(17239)(),u=function(e,t,n,r){if(t in e)if(!0===r){if(e[t]===n)return}else if(!l(r)||!r())return;c?s(e,t,n,!0):s(e,t,n)},d=function(e,t){var n=arguments.length>2?arguments[2]:{},o=r(t);i&&(o=a.call(o,Object.getOwnPropertySymbols(t)));for(var s=0;s<o.length;s+=1)u(e,o[s],t[o[s]],n[o[s]])};d.supportsDescriptors=!!c,e.exports=d},18841:function(e,t,n){"use strict";var r=n(4364),i=this&&this.__spreadArray||function(e,t,n){if(n||2===arguments.length)for(var r,i=0,o=t.length;i<o;i++)!r&&i in t||(r||(r=Array.prototype.slice.call(t,0,i)),r[i]=t[i]);return e.concat(r||Array.prototype.slice.call(t))};Object.defineProperty(t,"__esModule",{value:!0}),t.parse=void 0;var o=n(51305),a=n(44869);function s(e,t){var n=e.split(".");return n.length>1?n[n.length-1]:t}function l(e,t){return t.reduce(function(t,n){return t||e.startsWith(n)},!1)}var c=["a/","b/","i/","w/","c/","o/"];function u(e,t,n){var r=void 0!==n?i(i([],c,!0),[n],!1):c,o=t?new RegExp("^".concat((0,a.escapeForRegExp)(t),' "?(.+?)"?$')):new RegExp('^"?(.+?)"?$'),s=o.exec(e)||[],l=s[1],u=void 0===l?"":l,d=r.find(function(e){return 0===u.indexOf(e)}),h=d?u.slice(d.length):u;return h.replace(/\s+\d{4}-\d{2}-\d{2} \d{2}:\d{2}:\d{2}(?:\.\d+)? [+-]\d{4}.*$/,"")}function d(e,t){return u(e,"---",t)}function h(e,t){return u(e,"+++",t)}function p(e,t){void 0===t&&(t={});var n=[],i=null,a=null,c=null,p=null,f=null,m=null,g=null,v="--- ",b="+++ ",y="@@",w=/^old mode (\d{6})/,O=/^new mode (\d{6})/,S=/^deleted file mode (\d{6})/,E=/^new file mode (\d{6})/,x=/^copy from "?(.+)"?/,_=/^copy to "?(.+)"?/,k=/^rename from "?(.+)"?/,C=/^rename to "?(.+)"?/,A=/^similarity index (\d+)%/,T=/^dissimilarity index (\d+)%/,R=/^index ([\da-z]+)\.\.([\da-z]+)\s*(\d{6})?/,N=/^Binary files (.*) and (.*) differ/,P=/^GIT binary patch/,I=/^index ([\da-z]+),([\da-z]+)\.\.([\da-z]+)/,M=/^mode (\d{6}),(\d{6})\.\.(\d{6})/,D=/^new file mode (\d{6})/,L=/^deleted file mode (\d{6}),(\d{6})/,B=e.replace(/\\ No newline at end of file/g,"").replace(/\r\n?/g,"\n").split("\n");function $(){null!==a&&null!==i&&(i.blocks.push(a),a=null)}function V(){null!==i&&(i.oldName||null===m||(i.oldName=m),i.newName||null===g||(i.newName=g),i.newName&&(n.push(i),i=null)),m=null,g=null}function F(){$(),V(),i={blocks:[],deletedLines:0,addedLines:0}}function j(e){var t;$(),null!==i&&((t=/^@@ -(\d+)(?:,\d+)? \+(\d+)(?:,\d+)? @@.*/.exec(e))?(i.isCombined=!1,c=parseInt(t[1],10),f=parseInt(t[2],10)):(t=/^@@@ -(\d+)(?:,\d+)? -(\d+)(?:,\d+)? \+(\d+)(?:,\d+)? @@@.*/.exec(e))?(i.isCombined=!0,c=parseInt(t[1],10),p=parseInt(t[2],10),f=parseInt(t[3],10)):(e.startsWith(y)&&r.error("Failed to parse lines, starting in 0!"),c=0,f=0,i.isCombined=!1)),a={lines:[],oldStartLine:c,oldStartLine2:p,newStartLine:f,header:e}}function U(e){if(null!==i&&null!==a&&null!==c&&null!==f){var t={content:e},n=i.isCombined?["+ "," +","++"]:["+"],r=i.isCombined?["- "," -","--"]:["-"];l(e,n)?(i.addedLines++,t.type=o.LineType.INSERT,t.oldNumber=void 0,t.newNumber=f++):l(e,r)?(i.deletedLines++,t.type=o.LineType.DELETE,t.oldNumber=c++,t.newNumber=void 0):(t.type=o.LineType.CONTEXT,t.oldNumber=c++,t.newNumber=f++),a.lines.push(t)}}function G(e,t){var n=t;while(n<B.length-3){if(e.startsWith("diff"))return!1;if(B[n].startsWith(v)&&B[n+1].startsWith(b)&&B[n+2].startsWith(y))return!0;n++}return!1}return B.forEach(function(e,r){if(e&&!e.startsWith("*")){var o,l=B[r-1],c=B[r+1],p=B[r+2];if(e.startsWith("diff")){F();var f=/^diff --git "?([a-ciow]\/.+)"? "?([a-ciow]\/.+)"?/;if((o=f.exec(e))&&(m=u(o[1],void 0,t.dstPrefix),g=u(o[2],void 0,t.srcPrefix)),null===i)throw new Error("Where is my file !!!");i.isGitDiff=!0}else if((!i||!i.isGitDiff&&i&&e.startsWith(v)&&c.startsWith(b)&&p.startsWith(y))&&F(),!(null===i||void 0===i?void 0:i.isTooBig))if(i&&("number"===typeof t.diffMaxChanges&&i.addedLines+i.deletedLines>t.diffMaxChanges||"number"===typeof t.diffMaxLineLength&&e.length>t.diffMaxLineLength)){i.isTooBig=!0,i.addedLines=0,i.deletedLines=0,i.blocks=[],a=null;var $="function"===typeof t.diffTooBigMessage?t.diffTooBigMessage(n.length):"Diff too big to be displayed";j($)}else{if(e.startsWith(v)&&c.startsWith(b)||e.startsWith(b)&&l.startsWith(v)){if(i&&!i.oldName&&e.startsWith("--- ")&&(o=d(e,t.srcPrefix)))return i.oldName=o,void(i.language=s(i.oldName,i.language));if(i&&!i.newName&&e.startsWith("+++ ")&&(o=h(e,t.dstPrefix)))return i.newName=o,void(i.language=s(i.newName,i.language))}if(i&&(e.startsWith(y)||i.isGitDiff&&i.oldName&&i.newName&&!a))j(e);else if(a&&(e.startsWith("+")||e.startsWith("-")||e.startsWith(" ")))U(e);else{var V=!G(e,r);if(null===i)throw new Error("Where is my file !!!");(o=w.exec(e))?i.oldMode=o[1]:(o=O.exec(e))?i.newMode=o[1]:(o=S.exec(e))?(i.deletedFileMode=o[1],i.isDeleted=!0):(o=E.exec(e))?(i.newFileMode=o[1],i.isNew=!0):(o=x.exec(e))?(V&&(i.oldName=o[1]),i.isCopy=!0):(o=_.exec(e))?(V&&(i.newName=o[1]),i.isCopy=!0):(o=k.exec(e))?(V&&(i.oldName=o[1]),i.isRename=!0):(o=C.exec(e))?(V&&(i.newName=o[1]),i.isRename=!0):(o=N.exec(e))?(i.isBinary=!0,i.oldName=u(o[1],void 0,t.srcPrefix),i.newName=u(o[2],void 0,t.dstPrefix),j("Binary file")):P.test(e)?(i.isBinary=!0,j(e)):(o=A.exec(e))?i.unchangedPercentage=parseInt(o[1],10):(o=T.exec(e))?i.changedPercentage=parseInt(o[1],10):(o=R.exec(e))?(i.checksumBefore=o[1],i.checksumAfter=o[2],o[3]&&(i.mode=o[3])):(o=I.exec(e))?(i.checksumBefore=[o[2],o[3]],i.checksumAfter=o[1]):(o=M.exec(e))?(i.oldMode=[o[2],o[3]],i.newMode=o[1]):(o=D.exec(e))?(i.newFileMode=o[1],i.isNew=!0):(o=L.exec(e))&&(i.deletedFileMode=o[1],i.isDeleted=!0)}}}}),$(),V(),n}t.parse=p},53052:function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e["default"]=t}),o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&r(t,e,n);return i(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.defaultTemplates=void 0;var a=o(n(62133));t.defaultTemplates={},t.defaultTemplates["file-summary-line"]=new a.Template({code:function(e,t,n){var r=this;return r.b(n=n||""),r.b('<li class="d2h-file-list-line">'),r.b("\n"+n),r.b(' <span class="d2h-file-name-wrapper">'),r.b("\n"+n),r.b(r.rp("<fileIcon0",e,t," ")),r.b(' <a href="#'),r.b(r.v(r.f("fileHtmlId",e,t,0))),r.b('" class="d2h-file-name">'),r.b(r.v(r.f("fileName",e,t,0))),r.b("</a>"),r.b("\n"+n),r.b(' <span class="d2h-file-stats">'),r.b("\n"+n),r.b(' <span class="d2h-lines-added">'),r.b(r.v(r.f("addedLines",e,t,0))),r.b("</span>"),r.b("\n"+n),r.b(' <span class="d2h-lines-deleted">'),r.b(r.v(r.f("deletedLines",e,t,0))),r.b("</span>"),r.b("\n"+n),r.b(" </span>"),r.b("\n"+n),r.b(" </span>"),r.b("\n"+n),r.b("</li>"),r.fl()},partials:{"<fileIcon0":{name:"fileIcon",partials:{},subs:{}}},subs:{}}),t.defaultTemplates["file-summary-wrapper"]=new a.Template({code:function(e,t,n){var r=this;return r.b(n=n||""),r.b('<div class="d2h-file-list-wrapper">'),r.b("\n"+n),r.b(' <div class="d2h-file-list-header">'),r.b("\n"+n),r.b(' <span class="d2h-file-list-title">Files changed ('),r.b(r.v(r.f("filesNumber",e,t,0))),r.b(")</span>"),r.b("\n"+n),r.b(' <a class="d2h-file-switch d2h-hide">hide</a>'),r.b("\n"+n),r.b(' <a class="d2h-file-switch d2h-show">show</a>'),r.b("\n"+n),r.b(" </div>"),r.b("\n"+n),r.b(' <ol class="d2h-file-list">'),r.b("\n"+n),r.b(" "),r.b(r.t(r.f("files",e,t,0))),r.b("\n"+n),r.b(" </ol>"),r.b("\n"+n),r.b("</div>"),r.fl()},partials:{},subs:{}}),t.defaultTemplates["generic-block-header"]=new a.Template({code:function(e,t,n){var r=this;return r.b(n=n||""),r.b("<tr>"),r.b("\n"+n),r.b(' <td class="'),r.b(r.v(r.f("lineClass",e,t,0))),r.b(" "),r.b(r.v(r.d("CSSLineClass.INFO",e,t,0))),r.b('"></td>'),r.b("\n"+n),r.b(' <td class="'),r.b(r.v(r.d("CSSLineClass.INFO",e,t,0))),r.b('">'),r.b("\n"+n),r.b(' <div class="'),r.b(r.v(r.f("contentClass",e,t,0))),r.b('">'),r.b(r.t(r.f("blockHeader",e,t,0))),r.b("</div>"),r.b("\n"+n),r.b(" </td>"),r.b("\n"+n),r.b("</tr>"),r.fl()},partials:{},subs:{}}),t.defaultTemplates["generic-empty-diff"]=new a.Template({code:function(e,t,n){var r=this;return r.b(n=n||""),r.b("<tr>"),r.b("\n"+n),r.b(' <td class="'),r.b(r.v(r.d("CSSLineClass.INFO",e,t,0))),r.b('">'),r.b("\n"+n),r.b(' <div class="'),r.b(r.v(r.f("contentClass",e,t,0))),r.b('">'),r.b("\n"+n),r.b(" File without changes"),r.b("\n"+n),r.b(" </div>"),r.b("\n"+n),r.b(" </td>"),r.b("\n"+n),r.b("</tr>"),r.fl()},partials:{},subs:{}}),t.defaultTemplates["generic-file-path"]=new a.Template({code:function(e,t,n){var r=this;return r.b(n=n||""),r.b('<span class="d2h-file-name-wrapper">'),r.b("\n"+n),r.b(r.rp("<fileIcon0",e,t," ")),r.b(' <span class="d2h-file-name">'),r.b(r.v(r.f("fileDiffName",e,t,0))),r.b("</span>"),r.b("\n"+n),r.b(r.rp("<fileTag1",e,t," ")),r.b("</span>"),r.b("\n"+n),r.b('<label class="d2h-file-collapse">'),r.b("\n"+n),r.b(' <input class="d2h-file-collapse-input" type="checkbox" name="viewed" value="viewed">'),r.b("\n"+n),r.b(" Viewed"),r.b("\n"+n),r.b("</label>"),r.fl()},partials:{"<fileIcon0":{name:"fileIcon",partials:{},subs:{}},"<fileTag1":{name:"fileTag",partials:{},subs:{}}},subs:{}}),t.defaultTemplates["generic-line"]=new a.Template({code:function(e,t,n){var r=this;return r.b(n=n||""),r.b("<tr>"),r.b("\n"+n),r.b(' <td class="'),r.b(r.v(r.f("lineClass",e,t,0))),r.b(" "),r.b(r.v(r.f("type",e,t,0))),r.b('">'),r.b("\n"+n),r.b(" "),r.b(r.t(r.f("lineNumber",e,t,0))),r.b("\n"+n),r.b(" </td>"),r.b("\n"+n),r.b(' <td class="'),r.b(r.v(r.f("type",e,t,0))),r.b('">'),r.b("\n"+n),r.b(' <div class="'),r.b(r.v(r.f("contentClass",e,t,0))),r.b('">'),r.b("\n"+n),r.s(r.f("prefix",e,t,1),e,t,0,162,238,"{{ }}")&&(r.rs(e,t,function(e,t,r){r.b(' <span class="d2h-code-line-prefix">'),r.b(r.t(r.f("prefix",e,t,0))),r.b("</span>"),r.b("\n"+n)}),e.pop()),r.s(r.f("prefix",e,t,1),e,t,1,0,0,"")||(r.b(' <span class="d2h-code-line-prefix"> </span>'),r.b("\n"+n)),r.s(r.f("content",e,t,1),e,t,0,371,445,"{{ }}")&&(r.rs(e,t,function(e,t,r){r.b(' <span class="d2h-code-line-ctn">'),r.b(r.t(r.f("content",e,t,0))),r.b("</span>"),r.b("\n"+n)}),e.pop()),r.s(r.f("content",e,t,1),e,t,1,0,0,"")||(r.b(' <span class="d2h-code-line-ctn"><br></span>'),r.b("\n"+n)),r.b(" </div>"),r.b("\n"+n),r.b(" </td>"),r.b("\n"+n),r.b("</tr>"),r.fl()},partials:{},subs:{}}),t.defaultTemplates["generic-wrapper"]=new a.Template({code:function(e,t,n){var r=this;return r.b(n=n||""),r.b('<div class="d2h-wrapper">'),r.b("\n"+n),r.b(" "),r.b(r.t(r.f("content",e,t,0))),r.b("\n"+n),r.b("</div>"),r.fl()},partials:{},subs:{}}),t.defaultTemplates["icon-file-added"]=new a.Template({code:function(e,t,n){var r=this;return r.b(n=n||""),r.b('<svg aria-hidden="true" class="d2h-icon d2h-added" height="16" title="added" version="1.1" viewBox="0 0 14 16"'),r.b("\n"+n),r.b(' width="14">'),r.b("\n"+n),r.b(' <path d="M13 1H1C0.45 1 0 1.45 0 2v12c0 0.55 0.45 1 1 1h12c0.55 0 1-0.45 1-1V2c0-0.55-0.45-1-1-1z m0 13H1V2h12v12zM6 9H3V7h3V4h2v3h3v2H8v3H6V9z"></path>'),r.b("\n"+n),r.b("</svg>"),r.fl()},partials:{},subs:{}}),t.defaultTemplates["icon-file-changed"]=new a.Template({code:function(e,t,n){var r=this;return r.b(n=n||""),r.b('<svg aria-hidden="true" class="d2h-icon d2h-changed" height="16" title="modified" version="1.1"'),r.b("\n"+n),r.b(' viewBox="0 0 14 16" width="14">'),r.b("\n"+n),r.b(' <path d="M13 1H1C0.45 1 0 1.45 0 2v12c0 0.55 0.45 1 1 1h12c0.55 0 1-0.45 1-1V2c0-0.55-0.45-1-1-1z m0 13H1V2h12v12zM4 8c0-1.66 1.34-3 3-3s3 1.34 3 3-1.34 3-3 3-3-1.34-3-3z"></path>'),r.b("\n"+n),r.b("</svg>"),r.fl()},partials:{},subs:{}}),t.defaultTemplates["icon-file-deleted"]=new a.Template({code:function(e,t,n){var r=this;return r.b(n=n||""),r.b('<svg aria-hidden="true" class="d2h-icon d2h-deleted" height="16" title="removed" version="1.1"'),r.b("\n"+n),r.b(' viewBox="0 0 14 16" width="14">'),r.b("\n"+n),r.b(' <path d="M13 1H1C0.45 1 0 1.45 0 2v12c0 0.55 0.45 1 1 1h12c0.55 0 1-0.45 1-1V2c0-0.55-0.45-1-1-1z m0 13H1V2h12v12zM11 9H3V7h8v2z"></path>'),r.b("\n"+n),r.b("</svg>"),r.fl()},partials:{},subs:{}}),t.defaultTemplates["icon-file-renamed"]=new a.Template({code:function(e,t,n){var r=this;return r.b(n=n||""),r.b('<svg aria-hidden="true" class="d2h-icon d2h-moved" height="16" title="renamed" version="1.1"'),r.b("\n"+n),r.b(' viewBox="0 0 14 16" width="14">'),r.b("\n"+n),r.b(' <path d="M6 9H3V7h3V4l5 4-5 4V9z m8-7v12c0 0.55-0.45 1-1 1H1c-0.55 0-1-0.45-1-1V2c0-0.55 0.45-1 1-1h12c0.55 0 1 0.45 1 1z m-1 0H1v12h12V2z"></path>'),r.b("\n"+n),r.b("</svg>"),r.fl()},partials:{},subs:{}}),t.defaultTemplates["icon-file"]=new a.Template({code:function(e,t,n){var r=this;return r.b(n=n||""),r.b('<svg aria-hidden="true" class="d2h-icon" height="16" version="1.1" viewBox="0 0 12 16" width="12">'),r.b("\n"+n),r.b(' <path d="M6 5H2v-1h4v1zM2 8h7v-1H2v1z m0 2h7v-1H2v1z m0 2h7v-1H2v1z m10-7.5v9.5c0 0.55-0.45 1-1 1H1c-0.55 0-1-0.45-1-1V2c0-0.55 0.45-1 1-1h7.5l3.5 3.5z m-1 0.5L8 2H1v12h10V5z"></path>'),r.b("\n"+n),r.b("</svg>"),r.fl()},partials:{},subs:{}}),t.defaultTemplates["line-by-line-file-diff"]=new a.Template({code:function(e,t,n){var r=this;return r.b(n=n||""),r.b('<div id="'),r.b(r.v(r.f("fileHtmlId",e,t,0))),r.b('" class="d2h-file-wrapper" data-lang="'),r.b(r.v(r.d("file.language",e,t,0))),r.b('">'),r.b("\n"+n),r.b(' <div class="d2h-file-header">'),r.b("\n"+n),r.b(" "),r.b(r.t(r.f("filePath",e,t,0))),r.b("\n"+n),r.b(" </div>"),r.b("\n"+n),r.b(' <div class="d2h-file-diff">'),r.b("\n"+n),r.b(' <div class="d2h-code-wrapper">'),r.b("\n"+n),r.b(' <table class="d2h-diff-table">'),r.b("\n"+n),r.b(' <tbody class="d2h-diff-tbody">'),r.b("\n"+n),r.b(" "),r.b(r.t(r.f("diffs",e,t,0))),r.b("\n"+n),r.b(" </tbody>"),r.b("\n"+n),r.b(" </table>"),r.b("\n"+n),r.b(" </div>"),r.b("\n"+n),r.b(" </div>"),r.b("\n"+n),r.b("</div>"),r.fl()},partials:{},subs:{}}),t.defaultTemplates["line-by-line-numbers"]=new a.Template({code:function(e,t,n){var r=this;return r.b(n=n||""),r.b('<div class="line-num1">'),r.b(r.v(r.f("oldNumber",e,t,0))),r.b("</div>"),r.b("\n"+n),r.b('<div class="line-num2">'),r.b(r.v(r.f("newNumber",e,t,0))),r.b("</div>"),r.fl()},partials:{},subs:{}}),t.defaultTemplates["side-by-side-file-diff"]=new a.Template({code:function(e,t,n){var r=this;return r.b(n=n||""),r.b('<div id="'),r.b(r.v(r.f("fileHtmlId",e,t,0))),r.b('" class="d2h-file-wrapper" data-lang="'),r.b(r.v(r.d("file.language",e,t,0))),r.b('">'),r.b("\n"+n),r.b(' <div class="d2h-file-header">'),r.b("\n"+n),r.b(" "),r.b(r.t(r.f("filePath",e,t,0))),r.b("\n"+n),r.b(" </div>"),r.b("\n"+n),r.b(' <div class="d2h-files-diff">'),r.b("\n"+n),r.b(' <div class="d2h-file-side-diff">'),r.b("\n"+n),r.b(' <div class="d2h-code-wrapper">'),r.b("\n"+n),r.b(' <table class="d2h-diff-table">'),r.b("\n"+n),r.b(' <tbody class="d2h-diff-tbody">'),r.b("\n"+n),r.b(" "),r.b(r.t(r.d("diffs.left",e,t,0))),r.b("\n"+n),r.b(" </tbody>"),r.b("\n"+n),r.b(" </table>"),r.b("\n"+n),r.b(" </div>"),r.b("\n"+n),r.b(" </div>"),r.b("\n"+n),r.b(' <div class="d2h-file-side-diff">'),r.b("\n"+n),r.b(' <div class="d2h-code-wrapper">'),r.b("\n"+n),r.b(' <table class="d2h-diff-table">'),r.b("\n"+n),r.b(' <tbody class="d2h-diff-tbody">'),r.b("\n"+n),r.b(" "),r.b(r.t(r.d("diffs.right",e,t,0))),r.b("\n"+n),r.b(" </tbody>"),r.b("\n"+n),r.b(" </table>"),r.b("\n"+n),r.b(" </div>"),r.b("\n"+n),r.b(" </div>"),r.b("\n"+n),r.b(" </div>"),r.b("\n"+n),r.b("</div>"),r.fl()},partials:{},subs:{}}),t.defaultTemplates["tag-file-added"]=new a.Template({code:function(e,t,n){var r=this;return r.b(n=n||""),r.b('<span class="d2h-tag d2h-added d2h-added-tag">ADDED</span>'),r.fl()},partials:{},subs:{}}),t.defaultTemplates["tag-file-changed"]=new a.Template({code:function(e,t,n){var r=this;return r.b(n=n||""),r.b('<span class="d2h-tag d2h-changed d2h-changed-tag">CHANGED</span>'),r.fl()},partials:{},subs:{}}),t.defaultTemplates["tag-file-deleted"]=new a.Template({code:function(e,t,n){var r=this;return r.b(n=n||""),r.b('<span class="d2h-tag d2h-deleted d2h-deleted-tag">DELETED</span>'),r.fl()},partials:{},subs:{}}),t.defaultTemplates["tag-file-renamed"]=new a.Template({code:function(e,t,n){var r=this;return r.b(n=n||""),r.b('<span class="d2h-tag d2h-moved d2h-moved-tag">RENAMED</span>'),r.fl()},partials:{},subs:{}})},9402:function(e,t,n){"use strict";var r=this&&this.__assign||function(){return r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n],t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},r.apply(this,arguments)},i=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),o=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e["default"]=t}),a=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&i(t,e,n);return o(t,e),t},s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.html=t.parse=t.defaultDiff2HtmlConfig=void 0;var l=a(n(18841)),c=a(n(82417)),u=a(n(14023)),d=a(n(39959)),h=n(51305),p=s(n(29706));function f(e,n){return void 0===n&&(n={}),l.parse(e,r(r({},t.defaultDiff2HtmlConfig),n))}function m(e,n){void 0===n&&(n={});var i=r(r({},t.defaultDiff2HtmlConfig),n),o="string"===typeof e?l.parse(e,i):e,a=new p.default(i),s=i.drawFileList?c.render(o,a):"",h="side-by-side"===i.outputFormat?new d.default(a,i).render(o):new u.default(a,i).render(o);return s+h}t.defaultDiff2HtmlConfig=r(r(r({},u.defaultLineByLineRendererConfig),d.defaultSideBySideRendererConfig),{outputFormat:h.OutputFormatType.LINE_BY_LINE,drawFileList:!0}),t.parse=f,t.html=m},82417:function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),i=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e["default"]=t}),o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&r(t,e,n);return i(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.render=void 0;var a=o(n(94762)),s="file-summary",l="icon";function c(e,t){var n=e.map(function(e){return t.render(s,"line",{fileHtmlId:a.getHtmlId(e),oldName:e.oldName,newName:e.newName,fileName:a.filenameDiff(e),deletedLines:"-"+e.deletedLines,addedLines:"+"+e.addedLines},{fileIcon:t.template(l,a.getFileIcon(e))})}).join("\n");return t.render(s,"wrapper",{filesNumber:e.length,files:n})}t.render=c},29706:function(e,t,n){"use strict";var r=this&&this.__assign||function(){return r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n],t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},r.apply(this,arguments)},i=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),o=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e["default"]=t}),a=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&i(t,e,n);return o(t,e),t};Object.defineProperty(t,"__esModule",{value:!0});var s=a(n(62133)),l=n(53052),c=function(){function e(e){var t=e.compiledTemplates,n=void 0===t?{}:t,i=e.rawTemplates,o=void 0===i?{}:i,a=Object.entries(o).reduce(function(e,t){var n,i=t[0],o=t[1],a=s.compile(o,{asString:!1});return r(r({},e),(n={},n[i]=a,n))},{});this.preCompiledTemplates=r(r(r({},l.defaultTemplates),n),a)}return e.compile=function(e){return s.compile(e,{asString:!1})},e.prototype.render=function(e,t,n,r,i){var o=this.templateKey(e,t);try{var a=this.preCompiledTemplates[o];return a.render(n,r,i)}catch(s){throw new Error("Could not find template to render '".concat(o,"'"))}},e.prototype.template=function(e,t){return this.preCompiledTemplates[this.templateKey(e,t)]},e.prototype.templateKey=function(e,t){return"".concat(e,"-").concat(t)},e}();t["default"]=c},14023:function(e,t,n){"use strict";var r=n(4364),i=this&&this.__assign||function(){return i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n],t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},i.apply(this,arguments)},o=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),a=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e["default"]=t}),s=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&o(t,e,n);return a(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.defaultLineByLineRendererConfig=void 0;var l=s(n(54166)),c=s(n(94762)),u=n(51305);t.defaultLineByLineRendererConfig=i(i({},c.defaultRenderConfig),{renderNothingWhenEmpty:!1,matchingMaxComparisons:2500,maxLineSizeInBlockForComparison:200});var d="generic",h="line-by-line",p="icon",f="tag",m=function(){function e(e,n){void 0===n&&(n={}),this.hoganUtils=e,this.config=i(i({},t.defaultLineByLineRendererConfig),n)}return e.prototype.render=function(e){var t=this,n=e.map(function(e){var n;return n=e.blocks.length?t.generateFileHtml(e):t.generateEmptyDiff(),t.makeFileDiffHtml(e,n)}).join("\n");return this.hoganUtils.render(d,"wrapper",{content:n})},e.prototype.makeFileDiffHtml=function(e,t){if(this.config.renderNothingWhenEmpty&&Array.isArray(e.blocks)&&0===e.blocks.length)return"";var n=this.hoganUtils.template(h,"file-diff"),r=this.hoganUtils.template(d,"file-path"),i=this.hoganUtils.template(p,"file"),o=this.hoganUtils.template(f,c.getFileIcon(e));return n.render({file:e,fileHtmlId:c.getHtmlId(e),diffs:t,filePath:r.render({fileDiffName:c.filenameDiff(e)},{fileIcon:i,fileTag:o})})},e.prototype.generateEmptyDiff=function(){return this.hoganUtils.render(d,"empty-diff",{contentClass:"d2h-code-line",CSSLineClass:c.CSSLineClass})},e.prototype.generateFileHtml=function(e){var t=this,n=l.newMatcherFn(l.newDistanceFn(function(t){return c.deconstructLine(t.content,e.isCombined).content}));return e.blocks.map(function(i){var o=t.hoganUtils.render(d,"block-header",{CSSLineClass:c.CSSLineClass,blockHeader:e.isTooBig?i.header:c.escapeForHtml(i.header),lineClass:"d2h-code-linenumber",contentClass:"d2h-code-line"});return t.applyLineGroupping(i).forEach(function(i){var a=i[0],s=i[1],l=i[2];if(s.length&&l.length&&!a.length)t.applyRematchMatching(s,l,n).map(function(n){var r=n[0],i=n[1],a=t.processChangedLines(e.isCombined,r,i),s=a.left,l=a.right;o+=s,o+=l});else if(a.length)a.forEach(function(n){var r=c.deconstructLine(n.content,e.isCombined),i=r.prefix,a=r.content;o+=t.generateSingleLineHtml({type:c.CSSLineClass.CONTEXT,prefix:i,content:a,oldNumber:n.oldNumber,newNumber:n.newNumber})});else if(s.length||l.length){var u=t.processChangedLines(e.isCombined,s,l),d=u.left,h=u.right;o+=d,o+=h}else r.error("Unknown state reached while processing groups of lines",a,s,l)}),o}).join("\n")},e.prototype.applyLineGroupping=function(e){for(var t=[],n=[],r=[],i=0;i<e.lines.length;i++){var o=e.lines[i];(o.type!==u.LineType.INSERT&&r.length||o.type===u.LineType.CONTEXT&&n.length>0)&&(t.push([[],n,r]),n=[],r=[]),o.type===u.LineType.CONTEXT?t.push([[o],[],[]]):o.type===u.LineType.INSERT&&0===n.length?t.push([[],[],[o]]):o.type===u.LineType.INSERT&&n.length>0?r.push(o):o.type===u.LineType.DELETE&&n.push(o)}return(n.length||r.length)&&(t.push([[],n,r]),n=[],r=[]),t},e.prototype.applyRematchMatching=function(e,t,n){var r=e.length*t.length,i=Math.max.apply(null,[0].concat(e.concat(t).map(function(e){return e.content.length}))),o=r<this.config.matchingMaxComparisons&&i<this.config.maxLineSizeInBlockForComparison&&("lines"===this.config.matching||"words"===this.config.matching);return o?n(e,t):[[e,t]]},e.prototype.processChangedLines=function(e,t,n){for(var r={right:"",left:""},o=Math.max(t.length,n.length),a=0;a<o;a++){var s=t[a],l=n[a],u=void 0!==s&&void 0!==l?c.diffHighlight(s.content,l.content,e,this.config):void 0,d=void 0!==s&&void 0!==s.oldNumber?i(i({},void 0!==u?{prefix:u.oldLine.prefix,content:u.oldLine.content,type:c.CSSLineClass.DELETE_CHANGES}:i(i({},c.deconstructLine(s.content,e)),{type:c.toCSSClass(s.type)})),{oldNumber:s.oldNumber,newNumber:s.newNumber}):void 0,h=void 0!==l&&void 0!==l.newNumber?i(i({},void 0!==u?{prefix:u.newLine.prefix,content:u.newLine.content,type:c.CSSLineClass.INSERT_CHANGES}:i(i({},c.deconstructLine(l.content,e)),{type:c.toCSSClass(l.type)})),{oldNumber:l.oldNumber,newNumber:l.newNumber}):void 0,p=this.generateLineHtml(d,h),f=p.left,m=p.right;r.left+=f,r.right+=m}return r},e.prototype.generateLineHtml=function(e,t){return{left:this.generateSingleLineHtml(e),right:this.generateSingleLineHtml(t)}},e.prototype.generateSingleLineHtml=function(e){if(void 0===e)return"";var t=this.hoganUtils.render(h,"numbers",{oldNumber:e.oldNumber||"",newNumber:e.newNumber||""});return this.hoganUtils.render(d,"line",{type:e.type,lineClass:"d2h-code-linenumber",contentClass:"d2h-code-line",prefix:" "===e.prefix?" ":e.prefix,content:e.content,lineNumber:t})},e}();t["default"]=m},54166:function(e,t){"use strict";function n(e,t){if(0===e.length)return t.length;if(0===t.length)return e.length;var n,r,i=[];for(n=0;n<=t.length;n++)i[n]=[n];for(r=0;r<=e.length;r++)i[0][r]=r;for(n=1;n<=t.length;n++)for(r=1;r<=e.length;r++)t.charAt(n-1)===e.charAt(r-1)?i[n][r]=i[n-1][r-1]:i[n][r]=Math.min(i[n-1][r-1]+1,Math.min(i[n][r-1]+1,i[n-1][r]+1));return i[t.length][e.length]}function r(e){return function(t,r){var i=e(t).trim(),o=e(r).trim(),a=n(i,o);return a/(i.length+o.length)}}function i(e){function t(t,n,r){void 0===r&&(r=new Map);for(var i,o=1/0,a=0;a<t.length;++a)for(var s=0;s<n.length;++s){var l=JSON.stringify([t[a],n[s]]),c=void 0;r.has(l)&&(c=r.get(l))||(c=e(t[a],n[s]),r.set(l,c)),c<o&&(o=c,i={indexA:a,indexB:s,score:o})}return i}function n(e,r,i,o){void 0===i&&(i=0),void 0===o&&(o=new Map);var a=t(e,r,o);if(!a||e.length+r.length<3)return[[e,r]];var s=e.slice(0,a.indexA),l=r.slice(0,a.indexB),c=[e[a.indexA]],u=[r[a.indexB]],d=a.indexA+1,h=a.indexB+1,p=e.slice(d),f=r.slice(h),m=n(s,l,i+1,o),g=n(c,u,i+1,o),v=n(p,f,i+1,o),b=g;return(a.indexA>0||a.indexB>0)&&(b=m.concat(b)),(e.length>d||r.length>h)&&(b=b.concat(v)),b}return n}Object.defineProperty(t,"__esModule",{value:!0}),t.newMatcherFn=t.newDistanceFn=t.levenshtein=void 0,t.levenshtein=n,t.newDistanceFn=r,t.newMatcherFn=i},94762:function(e,t,n){"use strict";var r=this&&this.__assign||function(){return r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n],t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},r.apply(this,arguments)},i=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),o=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e["default"]=t}),a=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&i(t,e,n);return o(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.diffHighlight=t.getFileIcon=t.getHtmlId=t.filenameDiff=t.deconstructLine=t.escapeForHtml=t.toCSSClass=t.defaultRenderConfig=t.CSSLineClass=void 0;var s=a(n(48063)),l=n(44869),c=a(n(54166)),u=n(51305);t.CSSLineClass={INSERTS:"d2h-ins",DELETES:"d2h-del",CONTEXT:"d2h-cntx",INFO:"d2h-info",INSERT_CHANGES:"d2h-ins d2h-change",DELETE_CHANGES:"d2h-del d2h-change"},t.defaultRenderConfig={matching:u.LineMatchingType.NONE,matchWordsThreshold:.25,maxLineLengthHighlight:1e4,diffStyle:u.DiffStyleType.WORD};var d="/",h=c.newDistanceFn(function(e){return e.value}),p=c.newMatcherFn(h);function f(e){return-1!==e.indexOf("dev/null")}function m(e){return e.replace(/(<ins[^>]*>((.|\n)*?)<\/ins>)/g,"")}function g(e){return e.replace(/(<del[^>]*>((.|\n)*?)<\/del>)/g,"")}function v(e){switch(e){case u.LineType.CONTEXT:return t.CSSLineClass.CONTEXT;case u.LineType.INSERT:return t.CSSLineClass.INSERTS;case u.LineType.DELETE:return t.CSSLineClass.DELETES}}function b(e){return e?2:1}function y(e){return e.slice(0).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'").replace(/\//g,"/")}function w(e,t,n){void 0===n&&(n=!0);var r=b(t);return{prefix:e.substring(0,r),content:n?y(e.substring(r)):e.substring(r)}}function O(e){var t=(0,l.unifyPath)(e.oldName),n=(0,l.unifyPath)(e.newName);if(t===n||f(t)||f(n))return f(n)?t:n;var r=[],i=[],o=t.split(d),a=n.split(d),s=o.length,c=a.length,u=0,h=s-1,p=c-1;while(u<h&&u<p){if(o[u]!==a[u])break;r.push(a[u]),u+=1}while(h>u&&p>u){if(o[h]!==a[p])break;i.unshift(a[p]),h-=1,p-=1}var m=r.join(d),g=i.join(d),v=o.slice(u,h+1).join(d),b=a.slice(u,p+1).join(d);return m.length&&g.length?m+d+"{"+v+" → "+b+"}"+d+g:m.length?m+d+"{"+v+" → "+b+"}":g.length?"{"+v+" → "+b+"}"+d+g:t+" → "+n}function S(e){return"d2h-".concat((0,l.hashCode)(O(e)).toString().slice(-6))}function E(e){var t="file-changed";return e.isRename||e.isCopy?t="file-renamed":e.isNew?t="file-added":e.isDeleted?t="file-deleted":e.newName!==e.oldName&&(t="file-renamed"),t}function x(e,n,i,o){void 0===o&&(o={});var a=r(r({},t.defaultRenderConfig),o),l=a.matching,c=a.maxLineLengthHighlight,u=a.matchWordsThreshold,d=a.diffStyle,f=w(e,i,!1),v=w(n,i,!1);if(f.content.length>c||v.content.length>c)return{oldLine:{prefix:f.prefix,content:y(f.content)},newLine:{prefix:v.prefix,content:y(v.content)}};var b="char"===d?s.diffChars(f.content,v.content):s.diffWordsWithSpace(f.content,v.content),O=[];if("word"===d&&"words"===l){var S=b.filter(function(e){return e.removed}),E=b.filter(function(e){return e.added}),x=p(E,S);x.forEach(function(e){if(1===e[0].length&&1===e[1].length){var t=h(e[0][0],e[1][0]);t<u&&(O.push(e[0][0]),O.push(e[1][0]))}})}var _=b.reduce(function(e,t){var n=t.added?"ins":t.removed?"del":null,r=O.indexOf(t)>-1?' class="d2h-change"':"",i=y(t.value);return null!==n?"".concat(e,"<").concat(n).concat(r,">").concat(i,"</").concat(n,">"):"".concat(e).concat(i)},"");return{oldLine:{prefix:f.prefix,content:m(_)},newLine:{prefix:v.prefix,content:g(_)}}}t.toCSSClass=v,t.escapeForHtml=y,t.deconstructLine=w,t.filenameDiff=O,t.getHtmlId=S,t.getFileIcon=E,t.diffHighlight=x},39959:function(e,t,n){"use strict";var r=n(4364),i=this&&this.__assign||function(){return i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n],t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},i.apply(this,arguments)},o=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),a=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e["default"]=t}),s=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&o(t,e,n);return a(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.defaultSideBySideRendererConfig=void 0;var l=s(n(54166)),c=s(n(94762)),u=n(51305);t.defaultSideBySideRendererConfig=i(i({},c.defaultRenderConfig),{renderNothingWhenEmpty:!1,matchingMaxComparisons:2500,maxLineSizeInBlockForComparison:200});var d="generic",h="side-by-side",p="icon",f="tag",m=function(){function e(e,n){void 0===n&&(n={}),this.hoganUtils=e,this.config=i(i({},t.defaultSideBySideRendererConfig),n)}return e.prototype.render=function(e){var t=this,n=e.map(function(e){var n;return n=e.blocks.length?t.generateFileHtml(e):t.generateEmptyDiff(),t.makeFileDiffHtml(e,n)}).join("\n");return this.hoganUtils.render(d,"wrapper",{content:n})},e.prototype.makeFileDiffHtml=function(e,t){if(this.config.renderNothingWhenEmpty&&Array.isArray(e.blocks)&&0===e.blocks.length)return"";var n=this.hoganUtils.template(h,"file-diff"),r=this.hoganUtils.template(d,"file-path"),i=this.hoganUtils.template(p,"file"),o=this.hoganUtils.template(f,c.getFileIcon(e));return n.render({file:e,fileHtmlId:c.getHtmlId(e),diffs:t,filePath:r.render({fileDiffName:c.filenameDiff(e)},{fileIcon:i,fileTag:o})})},e.prototype.generateEmptyDiff=function(){return{right:"",left:this.hoganUtils.render(d,"empty-diff",{contentClass:"d2h-code-side-line",CSSLineClass:c.CSSLineClass})}},e.prototype.generateFileHtml=function(e){var t=this,n=l.newMatcherFn(l.newDistanceFn(function(t){return c.deconstructLine(t.content,e.isCombined).content}));return e.blocks.map(function(i){var o={left:t.makeHeaderHtml(i.header,e),right:t.makeHeaderHtml("")};return t.applyLineGroupping(i).forEach(function(i){var a=i[0],s=i[1],l=i[2];if(s.length&&l.length&&!a.length)t.applyRematchMatching(s,l,n).map(function(n){var r=n[0],i=n[1],a=t.processChangedLines(e.isCombined,r,i),s=a.left,l=a.right;o.left+=s,o.right+=l});else if(a.length)a.forEach(function(n){var r=c.deconstructLine(n.content,e.isCombined),i=r.prefix,a=r.content,s=t.generateLineHtml({type:c.CSSLineClass.CONTEXT,prefix:i,content:a,number:n.oldNumber},{type:c.CSSLineClass.CONTEXT,prefix:i,content:a,number:n.newNumber}),l=s.left,u=s.right;o.left+=l,o.right+=u});else if(s.length||l.length){var u=t.processChangedLines(e.isCombined,s,l),d=u.left,h=u.right;o.left+=d,o.right+=h}else r.error("Unknown state reached while processing groups of lines",a,s,l)}),o}).reduce(function(e,t){return{left:e.left+t.left,right:e.right+t.right}},{left:"",right:""})},e.prototype.applyLineGroupping=function(e){for(var t=[],n=[],r=[],i=0;i<e.lines.length;i++){var o=e.lines[i];(o.type!==u.LineType.INSERT&&r.length||o.type===u.LineType.CONTEXT&&n.length>0)&&(t.push([[],n,r]),n=[],r=[]),o.type===u.LineType.CONTEXT?t.push([[o],[],[]]):o.type===u.LineType.INSERT&&0===n.length?t.push([[],[],[o]]):o.type===u.LineType.INSERT&&n.length>0?r.push(o):o.type===u.LineType.DELETE&&n.push(o)}return(n.length||r.length)&&(t.push([[],n,r]),n=[],r=[]),t},e.prototype.applyRematchMatching=function(e,t,n){var r=e.length*t.length,i=Math.max.apply(null,[0].concat(e.concat(t).map(function(e){return e.content.length}))),o=r<this.config.matchingMaxComparisons&&i<this.config.maxLineSizeInBlockForComparison&&("lines"===this.config.matching||"words"===this.config.matching);return o?n(e,t):[[e,t]]},e.prototype.makeHeaderHtml=function(e,t){return this.hoganUtils.render(d,"block-header",{CSSLineClass:c.CSSLineClass,blockHeader:(null===t||void 0===t?void 0:t.isTooBig)?e:c.escapeForHtml(e),lineClass:"d2h-code-side-linenumber",contentClass:"d2h-code-side-line"})},e.prototype.processChangedLines=function(e,t,n){for(var r={right:"",left:""},o=Math.max(t.length,n.length),a=0;a<o;a++){var s=t[a],l=n[a],u=void 0!==s&&void 0!==l?c.diffHighlight(s.content,l.content,e,this.config):void 0,d=void 0!==s&&void 0!==s.oldNumber?i(i({},void 0!==u?{prefix:u.oldLine.prefix,content:u.oldLine.content,type:c.CSSLineClass.DELETE_CHANGES}:i(i({},c.deconstructLine(s.content,e)),{type:c.toCSSClass(s.type)})),{number:s.oldNumber}):void 0,h=void 0!==l&&void 0!==l.newNumber?i(i({},void 0!==u?{prefix:u.newLine.prefix,content:u.newLine.content,type:c.CSSLineClass.INSERT_CHANGES}:i(i({},c.deconstructLine(l.content,e)),{type:c.toCSSClass(l.type)})),{number:l.newNumber}):void 0,p=this.generateLineHtml(d,h),f=p.left,m=p.right;r.left+=f,r.right+=m}return r},e.prototype.generateLineHtml=function(e,t){return{left:this.generateSingleHtml(e),right:this.generateSingleHtml(t)}},e.prototype.generateSingleHtml=function(e){var t="d2h-code-side-linenumber",n="d2h-code-side-line";return this.hoganUtils.render(d,"line",{type:(null===e||void 0===e?void 0:e.type)||"".concat(c.CSSLineClass.CONTEXT," d2h-emptyplaceholder"),lineClass:void 0!==e?t:"".concat(t," d2h-code-side-emptyplaceholder"),contentClass:void 0!==e?n:"".concat(n," d2h-code-side-emptyplaceholder"),prefix:" "===(null===e||void 0===e?void 0:e.prefix)?" ":null===e||void 0===e?void 0:e.prefix,content:null===e||void 0===e?void 0:e.content,lineNumber:null===e||void 0===e?void 0:e.number})},e}();t["default"]=m},51305:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DiffStyleType=t.LineMatchingType=t.OutputFormatType=t.LineType=void 0,function(e){e["INSERT"]="insert",e["DELETE"]="delete",e["CONTEXT"]="context"}(t.LineType||(t.LineType={})),t.OutputFormatType={LINE_BY_LINE:"line-by-line",SIDE_BY_SIDE:"side-by-side"},t.LineMatchingType={LINES:"lines",WORDS:"words",NONE:"none"},t.DiffStyleType={WORD:"word",CHAR:"char"}},33908:function(e,t,n){"use strict";var r=n(4364),i=this&&this.__assign||function(){return i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n],t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},i.apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.Diff2HtmlUI=t.defaultDiff2HtmlUIConfig=void 0;var o=n(53126),a=n(9402);t.defaultDiff2HtmlUIConfig=i(i({},a.defaultDiff2HtmlConfig),{synchronisedScroll:!0,highlight:!0,fileListToggle:!0,fileListStartVisible:!1,highlightLanguages:new Map,smartSelection:!0,fileContentToggle:!0,stickyFileHeaders:!0});var s=function(){function e(e,n,r,o){void 0===r&&(r={}),this.hljs=null,this.currentSelectionColumnId=-1,this.config=i(i({},t.defaultDiff2HtmlUIConfig),r),this.diffHtml=void 0!==n?(0,a.html)(n,this.config):e.innerHTML,this.targetElement=e,void 0!==o&&(this.hljs=o)}return e.prototype.draw=function(){this.targetElement.innerHTML=this.diffHtml,this.config.synchronisedScroll&&this.synchronisedScroll(),this.config.highlight&&this.highlightCode(),this.config.fileListToggle&&this.fileListToggle(this.config.fileListStartVisible),this.config.fileContentToggle&&this.fileContentToggle(),this.config.stickyFileHeaders&&this.stickyFileHeaders()},e.prototype.synchronisedScroll=function(){this.targetElement.querySelectorAll(".d2h-file-wrapper").forEach(function(e){var t=Array().slice.call(e.querySelectorAll(".d2h-file-side-diff")),n=t[0],r=t[1];if(void 0!==n&&void 0!==r){var i=function(e){null!==e&&null!==e.target&&(e.target===n?(r.scrollTop=n.scrollTop,r.scrollLeft=n.scrollLeft):(n.scrollTop=r.scrollTop,n.scrollLeft=r.scrollLeft))};n.addEventListener("scroll",i),r.addEventListener("scroll",i)}})},e.prototype.fileListToggle=function(e){var t=this.targetElement.querySelector(".d2h-show"),n=this.targetElement.querySelector(".d2h-hide"),r=this.targetElement.querySelector(".d2h-file-list");if(null!==t&&null!==n&&null!==r){var i=function(){t.style.display="none",n.style.display="inline",r.style.display="block"},o=function(){t.style.display="inline",n.style.display="none",r.style.display="none"};t.addEventListener("click",function(){return i()}),n.addEventListener("click",function(){return o()});var a=this.getHashTag();"files-summary-show"===a?i():"files-summary-hide"===a?o():e?i():o()}},e.prototype.fileContentToggle=function(){this.targetElement.querySelectorAll(".d2h-file-collapse").forEach(function(e){e.style.display="flex";var t=function(t){var n,r=null===(n=e.closest(".d2h-file-wrapper"))||void 0===n?void 0:n.querySelector(t);null!==r&&void 0!==r&&(e.classList.toggle("d2h-selected"),r.classList.toggle("d2h-d-none"))},n=function(n){e!==n.target&&(t(".d2h-file-diff"),t(".d2h-files-diff"))};e.addEventListener("click",function(e){return n(e)})})},e.prototype.highlightCode=function(){var e=this,t=this.hljs;if(null===t)throw new Error("Missing a `highlight.js` implementation. Please provide one when instantiating Diff2HtmlUI.");var n=this.targetElement.querySelectorAll(".d2h-file-wrapper");n.forEach(function(n){var r=n.getAttribute("data-lang");e.config.highlightLanguages instanceof Map||(e.config.highlightLanguages=new Map(Object.entries(e.config.highlightLanguages)));var i=r&&e.config.highlightLanguages.has(r)?e.config.highlightLanguages.get(r):r?(0,o.getLanguage)(r):"plaintext",a=n.querySelectorAll(".d2h-code-line-ctn");a.forEach(function(n){var r=n.textContent,a=n.parentNode;if(null!==r&&null!==a&&e.isElement(a)){var s=(0,o.closeTags)(t.highlight(r,{language:i,ignoreIllegals:!0})),l=(0,o.nodeStream)(n);if(l.length){var c=document.createElementNS("http://www.w3.org/1999/xhtml","div");c.innerHTML=s.value,s.value=(0,o.mergeStreams)(l,(0,o.nodeStream)(c),r)}n.classList.add("hljs"),s.language&&n.classList.add(s.language),n.innerHTML=s.value}})})},e.prototype.stickyFileHeaders=function(){this.targetElement.querySelectorAll(".d2h-file-header").forEach(function(e){e.classList.add("d2h-sticky-header")})},e.prototype.smartSelection=function(){r.warn("Smart selection is now enabled by default with CSS. No need to call this method anymore.")},e.prototype.getHashTag=function(){var e=document.URL,t=e.indexOf("#"),n=null;return-1!==t&&(n=e.substr(t+1)),n},e.prototype.isElement=function(e){return null!==e&&void 0!==(null===e||void 0===e?void 0:e.classList)},e}();t.Diff2HtmlUI=s},34312:function(e,t,n){"use strict";var r=this&&this.__extends||function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},e(t,n)};return function(t,n){if("function"!==typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(t,"__esModule",{value:!0}),t.defaultDiff2HtmlUIConfig=t.Diff2HtmlUI=void 0;var i=n(42418),o=n(33908);Object.defineProperty(t,"defaultDiff2HtmlUIConfig",{enumerable:!0,get:function(){return o.defaultDiff2HtmlUIConfig}});var a=function(e){function t(t,n,r){return void 0===r&&(r={}),e.call(this,t,n,r,i.hljs)||this}return r(t,e),t}(o.Diff2HtmlUI);t.Diff2HtmlUI=a},53126:function(e,t){"use strict";function n(e){return e.replace(/&/gm,"&").replace(/</gm,"<").replace(/>/gm,">")}function r(e){return e.nodeName.toLowerCase()}function i(e){var t=[],n=function(e,i){for(var o=e.firstChild;o;o=o.nextSibling)3===o.nodeType&&null!==o.nodeValue?i+=o.nodeValue.length:1===o.nodeType&&(t.push({event:"start",offset:i,node:o}),i=n(o,i),r(o).match(/br|hr|img|input/)||t.push({event:"stop",offset:i,node:o}));return i};return n(e,0),t}function o(e,t,i){var o=0,a="",s=[];function l(e){return null!==e&&void 0!==(null===e||void 0===e?void 0:e.attributes)}function c(){return e.length&&t.length?e[0].offset!==t[0].offset?e[0].offset<t[0].offset?e:t:"start"===t[0].event?e:t:e.length?e:t}function u(e){if(!l(e))throw new Error("Node is not an Element");a+="<".concat(r(e)," ").concat(Array().map.call(e.attributes,function(e){return"".concat(e.nodeName,'="').concat(n(e.value).replace(/"/g,"""),'"')}).join(" "),">")}function d(e){a+="</"+r(e)+">"}function h(e){("start"===e.event?u:d)(e.node)}while(e.length||t.length){var p=c();if(a+=n(i.substring(o,p[0].offset)),o=p[0].offset,p===e){s.reverse().forEach(d);do{h(p.splice(0,1)[0]),p=c()}while(p===e&&p.length&&p[0].offset===o);s.reverse().forEach(u)}else"start"===p[0].event?s.push(p[0].node):s.pop(),h(p.splice(0,1)[0])}return a+n(i.substr(o))}function a(e){var t=new Array;return e.value=e.value.split("\n").map(function(e){var n=t.map(function(e){return'<span class="'.concat(e,'">')}).join(""),r=e.matchAll(/(<span class="(.*?)">|<\/span>)/g);Array.from(r).forEach(function(e){"</span>"===e[0]?t.shift():t.unshift(e[2])});var i="</span>".repeat(t.length);return n+e+i}).join("\n"),e}Object.defineProperty(t,"__esModule",{value:!0}),t.getLanguage=t.closeTags=t.mergeStreams=t.nodeStream=void 0,t.nodeStream=i,t.mergeStreams=o,t.closeTags=a;var s={"1c":"1c",abnf:"abnf",accesslog:"accesslog",as:"actionscript",adb:"ada",ada:"ada",ads:"ada",angelscript:"angelscript",apache:"apache",applescript:"applescript",scpt:"applescript",arcade:"arcade",cpp:"cpp",hpp:"cpp",arduino:"arduino",ino:"arduino",armasm:"armasm",arm:"armasm",xml:"xml",html:"xml",xhtml:"xml",rss:"xml",atom:"xml",xjb:"xml",xsd:"xml",xsl:"xml",plist:"xml",svg:"xml",asciidoc:"asciidoc",adoc:"asciidoc",asc:"asciidoc",aspectj:"aspectj",ahk:"autohotkey",ahkl:"autohotkey",au3:"autoit",avrasm:"avrasm",awk:"awk",axapta:"axapta","x++":"axapta",bash:"bash",sh:"bash",zsh:"bash",b:"basic",bnf:"bnf",bf:"brainfuck",c:"c",h:"c",cats:"c",idc:"c",cal:"cal",capnproto:"capnproto",capnp:"capnproto",ceylon:"ceylon",clean:"clean",clj:"clojure",boot:"clojure",cl2:"clojure",cljc:"clojure",cljs:"clojure","cljs.hl":"clojure",cljscm:"clojure",cljx:"clojure",hic:"clojure","clojure-repl":"clojure-repl",cmake:"cmake","cmake.in":"cmake",coffee:"coffeescript",_coffee:"coffeescript",cake:"coffeescript",cjsx:"coffeescript",iced:"coffeescript",cson:"coffeescript",coq:"coq",cos:"cos",cls:"cos",crmsh:"crmsh",crm:"crmsh",pcmk:"crmsh",cr:"crystal",cs:"csharp",csx:"csharp",csp:"csp",css:"css",d:"d",di:"d",md:"markdown",markdown:"markdown",mdown:"markdown",mdwn:"markdown",mkd:"markdown",mkdn:"markdown",mkdown:"markdown",ronn:"markdown",workbook:"markdown",dart:"dart",dpr:"delphi",dfm:"delphi",pas:"delphi",pascal:"delphi",diff:"diff",patch:"diff",django:"django",jinja:"django",dns:"dns",zone:"dns",bind:"dns",dockerfile:"dockerfile",docker:"dockerfile",dos:"dos",bat:"dos",cmd:"dos",dsconfig:"dsconfig",dts:"dts",dust:"dust",dst:"dust",ebnf:"ebnf",ex:"elixir",exs:"elixir",elm:"elm",rb:"ruby",builder:"ruby",eye:"ruby",gemspec:"ruby",god:"ruby",jbuilder:"ruby",mspec:"ruby",pluginspec:"ruby",podspec:"ruby",rabl:"ruby",rake:"ruby",rbuild:"ruby",rbw:"ruby",rbx:"ruby",ru:"ruby",ruby:"ruby",spec:"ruby",thor:"ruby",watchr:"ruby",erb:"erb","erlang-repl":"erlang-repl",erl:"erlang","app.src":"erlang",escript:"erlang",hrl:"erlang",xrl:"erlang",yrl:"erlang",excel:"excel",xls:"excel",xlsx:"excel",fix:"fix",flix:"flix",f90:"fortran",f:"fortran",f03:"fortran",f08:"fortran",f77:"fortran",f95:"fortran",for:"fortran",fpp:"fortran",fs:"fsharp",fsx:"fsharp",gams:"gams",gms:"gams",gauss:"gauss",gss:"gauss",gcode:"gcode",nc:"gcode",gherkin:"gherkin",glsl:"glsl",fp:"glsl",frag:"glsl",frg:"glsl",fsh:"glsl",fshader:"glsl",geo:"glsl",geom:"glsl",glslv:"glsl",gshader:"glsl",shader:"glsl",tesc:"glsl",tese:"glsl",vert:"glsl",vrx:"glsl",vsh:"glsl",vshader:"glsl",gml:"gml",go:"go",bal:"go",golo:"golo",gololang:"golo",gradle:"gradle",groovy:"groovy",grt:"groovy",gtpl:"groovy",gvy:"groovy",haml:"haml","haml.deface":"haml",handlebars:"handlebars",hbs:"handlebars","html.hbs":"handlebars","html.handlebars":"handlebars",hs:"haskell",hsc:"haskell",idr:"haskell",purs:"haskell",hx:"haxe",hxsl:"haxe",hsp:"hsp",htmlbars:"htmlbars",http:"http",https:"http",hy:"hy",inform7:"inform7",i7:"inform7",ini:"ini",toml:"ini",cfg:"ini",prefs:"ini",irpf90:"irpf90",isbl:"isbl",java:"java",jsp:"java",js:"javascript",jsx:"javascript",_js:"javascript",bones:"javascript",es:"javascript",es6:"javascript",gs:"javascript",jake:"javascript",jsb:"javascript",jscad:"javascript",jsfl:"javascript",jsm:"javascript",jss:"javascript",mjs:"javascript",njs:"javascript",pac:"javascript",sjs:"javascript",ssjs:"javascript",xsjs:"javascript",xsjslib:"javascript",cfc:"javascript","jboss-cli":"jboss-cli",json:"json",avsc:"json",geojson:"json",gltf:"json","JSON-tmLanguage":"json",jsonl:"json",tfstate:"json","tfstate.backup":"json",topojson:"json",webapp:"json",webmanifest:"json",jl:"julia","julia-repl":"julia-repl",kt:"kotlin",ktm:"kotlin",kts:"kotlin",lasso:"lasso",lassoscript:"lasso",tex:"latex",ldif:"ldif",leaf:"leaf",less:"less",lisp:"lisp",factor:"lisp",livecodeserver:"livecodeserver",ls:"livescript",_ls:"livescript",llvm:"llvm",lsl:"lsl",lua:"lua",nse:"lua",p8:"lua",pd_lua:"lua",rbxs:"lua",wlua:"lua",mak:"makefile",make:"makefile",mk:"makefile",mkfile:"makefile",mathematica:"mathematica",mma:"mathematica",wl:"mathematica",matlab:"matlab",maxima:"maxima",mel:"mel",mercury:"mercury",mipsasm:"mipsasm",miz:"mizar",voc:"mizar",al:"perl",cgi:"perl",fcgi:"perl",perl:"perl",ph:"perl",plx:"perl",pl:"perl",pm:"perl",psgi:"perl",t:"perl",mojolicious:"mojolicious",monkey:"monkey",monkey2:"monkey",moonscript:"moonscript",moon:"moonscript",n1ql:"n1ql",nginxconf:"nginx",nim:"nim",nimrod:"nim",nix:"nix",nsi:"nsis",nsh:"nsis",m:"objectivec",objc:"objectivec",mm:"objectivec","obj-c":"objectivec","obj-c++":"objectivec","objective-c++":"objectivec",fun:"ocaml",sig:"ocaml",ml:"ocaml",mli:"ocaml",eliom:"ocaml",eliomi:"ocaml",ml4:"ocaml",mll:"ocaml",mly:"ocaml",openscad:"openscad",oxygene:"oxygene",parser3:"parser3",pf:"pf","pf.conf":"pf",pgsql:"pgsql",postgres:"pgsql",postgresql:"pgsql",php:"php",aw:"php",ctp:"php",inc:"php",php3:"php",php4:"php",php5:"php",phps:"php",phpt:"php","php-template":"php-template",plaintext:"plaintext",txt:"plaintext",text:"plaintext",pony:"pony",ps:"powershell",ps1:"powershell",psd1:"powershell",psm1:"powershell",pde:"processing",profile:"profile",pro:"prolog",prolog:"prolog",yap:"prolog",properties:"properties",proto:"protobuf",puppet:"puppet",pp:"puppet",purebasic:"purebasic",py:"python",bzl:"python",gyp:"python",gypi:"python",lmi:"python",py3:"python",pyde:"python",pyi:"python",pyp:"python",pyt:"python",pyw:"python",rpy:"python",tac:"python",wsgi:"python",xpy:"python","python-repl":"python-repl",pycon:"python-repl",q:"q",k:"q",kdb:"q",qml:"qml",r:"r",rd:"r",rsx:"r",reasonml:"reasonml",re:"reasonml",rib:"rib",roboconf:"roboconf",graph:"roboconf",instances:"roboconf",routeros:"routeros",rsl:"rsl",ruleslanguage:"ruleslanguage",rs:"rust","rs.in":"rust",sas:"sas",scala:"scala",kojo:"scala",sbt:"scala",sc:"scala",scm:"scheme",sch:"scheme",sld:"scheme",sls:"scheme",sps:"scheme",ss:"scheme",rkt:"scheme",scilab:"scilab",scss:"scss",shell:"shell",smali:"smali",st:"smalltalk",sml:"sml",sqf:"sqf",sql:"sql",cql:"sql",ddl:"sql",mysql:"sql",prc:"sql",tab:"sql",udf:"sql",viw:"sql",stan:"stan",stanfuncs:"stan",stata:"stata",step21:"step21",step:"step21",stp:"step21",styl:"stylus",subunit:"subunit",swift:"swift",taggerscript:"taggerscript",yml:"yaml",mir:"yaml",reek:"yaml",rviz:"yaml","sublime-syntax":"yaml",syntax:"yaml",yaml:"yaml","yaml-tmlanguage":"yaml","yml.mysql":"yaml",tap:"tap",tcl:"tcl",adp:"tcl",tm:"tcl",thrift:"thrift",tp:"tp",twig:"twig",craftcms:"twig",ts:"typescript",tsx:"typescript",vala:"vala",vbnet:"vbnet",vb:"vbnet",vbscript:"vbscript",vbs:"vbscript","vbscript-html":"vbscript-html",v:"verilog",veo:"verilog",vhdl:"vhdl",vhd:"vhdl",vhf:"vhdl",vhi:"vhdl",vho:"vhdl",vhs:"vhdl",vht:"vhdl",vhw:"vhdl",vim:"vim",x86asm:"x86asm",xl:"xl",xquery:"xquery",xpath:"xquery",xq:"xquery",zephir:"zephir",zep:"zephir"};function l(e){var t;return null!==(t=s[e])&&void 0!==t?t:"plaintext"}t.getLanguage=l},42418:function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.hljs=void 0;var i=r(n(3973)),o=r(n(68049)),a=r(n(21869)),s=r(n(69205)),l=r(n(46760)),c=r(n(33089)),u=r(n(37620)),d=r(n(25326)),h=r(n(17025)),p=r(n(35678)),f=r(n(63355)),m=r(n(50687)),g=r(n(92835)),v=r(n(16361)),b=r(n(82476)),y=r(n(74809)),w=r(n(42892)),O=r(n(79386)),S=r(n(84441)),E=r(n(25236)),x=r(n(51468)),_=r(n(95541)),k=r(n(53528)),C=r(n(88842)),A=r(n(74192)),T=r(n(99682)),R=r(n(26418)),N=r(n(73113)),P=r(n(90020)),I=r(n(44063)),M=r(n(1075)),D=r(n(8090)),L=r(n(77190)),B=r(n(30374)),$=r(n(3315)),V=r(n(86072)),F=r(n(69318)),j=r(n(74071)),U=r(n(37592)),G=r(n(50619)),H=r(n(45107)),q=r(n(76015)),Q=r(n(2061)),z=r(n(90944)),K=r(n(8368)),W=r(n(31914)),X=r(n(74222)),Y=r(n(7846)),Z=r(n(90984)),J=r(n(72723)),ee=r(n(98005)),te=r(n(45745));i.default.registerLanguage("cpp",o.default),i.default.registerLanguage("xml",a.default),i.default.registerLanguage("awk",s.default),i.default.registerLanguage("bash",l.default),i.default.registerLanguage("c",c.default),i.default.registerLanguage("clojure",u.default),i.default.registerLanguage("crystal",d.default),i.default.registerLanguage("csharp",h.default),i.default.registerLanguage("csp",p.default),i.default.registerLanguage("css",f.default),i.default.registerLanguage("markdown",m.default),i.default.registerLanguage("dart",g.default),i.default.registerLanguage("diff",v.default),i.default.registerLanguage("dockerfile",b.default),i.default.registerLanguage("elixir",y.default),i.default.registerLanguage("elm",w.default),i.default.registerLanguage("ruby",O.default),i.default.registerLanguage("erlang",S.default),i.default.registerLanguage("fsharp",E.default),i.default.registerLanguage("go",x.default),i.default.registerLanguage("gradle",_.default),i.default.registerLanguage("groovy",k.default),i.default.registerLanguage("handlebars",C.default),i.default.registerLanguage("haskell",A.default),i.default.registerLanguage("ini",T.default),i.default.registerLanguage("java",R.default),i.default.registerLanguage("javascript",N.default),i.default.registerLanguage("json",P.default),i.default.registerLanguage("kotlin",I.default),i.default.registerLanguage("less",M.default),i.default.registerLanguage("lisp",D.default),i.default.registerLanguage("lua",L.default),i.default.registerLanguage("makefile",B.default),i.default.registerLanguage("perl",$.default),i.default.registerLanguage("nginx",V.default),i.default.registerLanguage("objectivec",F.default),i.default.registerLanguage("pgsql",j.default),i.default.registerLanguage("php",U.default),i.default.registerLanguage("plaintext",G.default),i.default.registerLanguage("powershell",H.default),i.default.registerLanguage("properties",q.default),i.default.registerLanguage("protobuf",Q.default),i.default.registerLanguage("python",z.default),i.default.registerLanguage("rust",K.default),i.default.registerLanguage("scala",W.default),i.default.registerLanguage("scss",X.default),i.default.registerLanguage("shell",Y.default),i.default.registerLanguage("sql",Z.default),i.default.registerLanguage("swift",J.default),i.default.registerLanguage("yaml",ee.default),i.default.registerLanguage("typescript",te.default),t.hljs=i.default},44869:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hashCode=t.unifyPath=t.escapeForRegExp=void 0;var n=["-","[","]","/","{","}","(",")","*","+","?",".","\\","^","$","|"],r=RegExp("["+n.join("\\")+"]","g");function i(e){return e.replace(r,"\\$&")}function o(e){return e?e.replace(/\\/g,"/"):e}function a(e){var t,n,r,i=0;for(t=0,r=e.length;t<r;t++)n=e.charCodeAt(t),i=(i<<5)-i+n,i|=0;return i}t.escapeForRegExp=i,t.unifyPath=o,t.hashCode=a},26990:function(e,t){"use strict";function n(e){for(var t,n,r=[],i=0;i<e.length;i++)t=e[i],n=t.added?1:t.removed?-1:0,r.push([n,t.value]);return r}Object.defineProperty(t,"__esModule",{value:!0}),t.convertChangesToDMP=n},69438:function(e,t){"use strict";function n(e){for(var t=[],n=0;n<e.length;n++){var i=e[n];i.added?t.push("<ins>"):i.removed&&t.push("<del>"),t.push(r(i.value)),i.added?t.push("</ins>"):i.removed&&t.push("</del>")}return t.join("")}function r(e){var t=e;return t=t.replace(/&/g,"&"),t=t.replace(/</g,"<"),t=t.replace(/>/g,">"),t=t.replace(/"/g,"""),t}Object.defineProperty(t,"__esModule",{value:!0}),t.convertChangesToXML=n},49906:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.diffArrays=a,t.arrayDiff=void 0;var r=i(n(22458));function i(e){return e&&e.__esModule?e:{default:e}}var o=new r["default"];function a(e,t,n){return o.diff(e,t,n)}t.arrayDiff=o,o.tokenize=function(e){return e.slice()},o.join=o.removeEmpty=function(e){return e}},22458:function(e,t){"use strict";function n(){}function r(e,t,n,r,i){for(var o=0,a=t.length,s=0,l=0;o<a;o++){var c=t[o];if(c.removed){if(c.value=e.join(r.slice(l,l+c.count)),l+=c.count,o&&t[o-1].added){var u=t[o-1];t[o-1]=t[o],t[o]=u}}else{if(!c.added&&i){var d=n.slice(s,s+c.count);d=d.map(function(e,t){var n=r[l+t];return n.length>e.length?n:e}),c.value=e.join(d)}else c.value=e.join(n.slice(s,s+c.count));s+=c.count,c.added||(l+=c.count)}}var h=t[a-1];return a>1&&"string"===typeof h.value&&(h.added||h.removed)&&e.equals("",h.value)&&(t[a-2].value+=h.value,t.pop()),t}function i(e){return{newPos:e.newPos,components:e.components.slice(0)}}Object.defineProperty(t,"__esModule",{value:!0}),t["default"]=n,n.prototype={diff:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=n.callback;"function"===typeof n&&(o=n,n={}),this.options=n;var a=this;function s(e){return o?(setTimeout(function(){o(void 0,e)},0),!0):e}e=this.castInput(e),t=this.castInput(t),e=this.removeEmpty(this.tokenize(e)),t=this.removeEmpty(this.tokenize(t));var l=t.length,c=e.length,u=1,d=l+c;n.maxEditLength&&(d=Math.min(d,n.maxEditLength));var h=[{newPos:-1,components:[]}],p=this.extractCommon(h[0],t,e,0);if(h[0].newPos+1>=l&&p+1>=c)return s([{value:this.join(t),count:t.length}]);function f(){for(var n=-1*u;n<=u;n+=2){var o=void 0,d=h[n-1],p=h[n+1],f=(p?p.newPos:0)-n;d&&(h[n-1]=void 0);var m=d&&d.newPos+1<l,g=p&&0<=f&&f<c;if(m||g){if(!m||g&&d.newPos<p.newPos?(o=i(p),a.pushComponent(o.components,void 0,!0)):(o=d,o.newPos++,a.pushComponent(o.components,!0,void 0)),f=a.extractCommon(o,t,e,n),o.newPos+1>=l&&f+1>=c)return s(r(a,o.components,t,e,a.useLongestToken));h[n]=o}else h[n]=void 0}u++}if(o)(function e(){setTimeout(function(){if(u>d)return o();f()||e()},0)})();else while(u<=d){var m=f();if(m)return m}},pushComponent:function(e,t,n){var r=e[e.length-1];r&&r.added===t&&r.removed===n?e[e.length-1]={count:r.count+1,added:t,removed:n}:e.push({count:1,added:t,removed:n})},extractCommon:function(e,t,n,r){var i=t.length,o=n.length,a=e.newPos,s=a-r,l=0;while(a+1<i&&s+1<o&&this.equals(t[a+1],n[s+1]))a++,s++,l++;return l&&e.components.push({count:l}),e.newPos=a,s},equals:function(e,t){return this.options.comparator?this.options.comparator(e,t):e===t||this.options.ignoreCase&&e.toLowerCase()===t.toLowerCase()},removeEmpty:function(e){for(var t=[],n=0;n<e.length;n++)e[n]&&t.push(e[n]);return t},castInput:function(e){return e},tokenize:function(e){return e.split("")},join:function(e){return e.join("")}}},14960:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.diffChars=a,t.characterDiff=void 0;var r=i(n(22458));function i(e){return e&&e.__esModule?e:{default:e}}var o=new r["default"];function a(e,t,n){return o.diff(e,t,n)}t.characterDiff=o},91224:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.diffCss=a,t.cssDiff=void 0;var r=i(n(22458));function i(e){return e&&e.__esModule?e:{default:e}}var o=new r["default"];function a(e,t,n){return o.diff(e,t,n)}t.cssDiff=o,o.tokenize=function(e){return e.split(/([{}:;,]|\s+)/)}},69593:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.diffJson=c,t.canonicalize=u,t.jsonDiff=void 0;var r=o(n(22458)),i=n(91617);function o(e){return e&&e.__esModule?e:{default:e}}function a(e){return a="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},a(e)}var s=Object.prototype.toString,l=new r["default"];function c(e,t,n){return l.diff(e,t,n)}function u(e,t,n,r,i){var o,l;for(t=t||[],n=n||[],r&&(e=r(i,e)),o=0;o<t.length;o+=1)if(t[o]===e)return n[o];if("[object Array]"===s.call(e)){for(t.push(e),l=new Array(e.length),n.push(l),o=0;o<e.length;o+=1)l[o]=u(e[o],t,n,r,i);return t.pop(),n.pop(),l}if(e&&e.toJSON&&(e=e.toJSON()),"object"===a(e)&&null!==e){t.push(e),l={},n.push(l);var c,d=[];for(c in e)e.hasOwnProperty(c)&&d.push(c);for(d.sort(),o=0;o<d.length;o+=1)c=d[o],l[c]=u(e[c],t,n,r,c);t.pop(),n.pop()}else l=e;return l}t.jsonDiff=l,l.useLongestToken=!0,l.tokenize=i.lineDiff.tokenize,l.castInput=function(e){var t=this.options,n=t.undefinedReplacement,r=t.stringifyReplacer,i=void 0===r?function(e,t){return"undefined"===typeof t?n:t}:r;return"string"===typeof e?e:JSON.stringify(u(e,null,null,i),i," ")},l.equals=function(e,t){return r["default"].prototype.equals.call(l,e.replace(/,([\r\n])/g,"$1"),t.replace(/,([\r\n])/g,"$1"))}},91617:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.diffLines=s,t.diffTrimmedLines=l,t.lineDiff=void 0;var r=o(n(22458)),i=n(85928);function o(e){return e&&e.__esModule?e:{default:e}}var a=new r["default"];function s(e,t,n){return a.diff(e,t,n)}function l(e,t,n){var r=(0,i.generateOptions)(n,{ignoreWhitespace:!0});return a.diff(e,t,r)}t.lineDiff=a,a.tokenize=function(e){var t=[],n=e.split(/(\n|\r\n)/);n[n.length-1]||n.pop();for(var r=0;r<n.length;r++){var i=n[r];r%2&&!this.options.newlineIsToken?t[t.length-1]+=i:(this.options.ignoreWhitespace&&(i=i.trim()),t.push(i))}return t}},82402:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.diffSentences=a,t.sentenceDiff=void 0;var r=i(n(22458));function i(e){return e&&e.__esModule?e:{default:e}}var o=new r["default"];function a(e,t,n){return o.diff(e,t,n)}t.sentenceDiff=o,o.tokenize=function(e){return e.split(/(\S.+?[.!?])(?=\s+|$)/)}},59843:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.diffWords=c,t.diffWordsWithSpace=u,t.wordDiff=void 0;var r=o(n(22458)),i=n(85928);function o(e){return e&&e.__esModule?e:{default:e}}var a=/^[A-Za-z\xC0-\u02C6\u02C8-\u02D7\u02DE-\u02FF\u1E00-\u1EFF]+$/,s=/\S/,l=new r["default"];function c(e,t,n){return n=(0,i.generateOptions)(n,{ignoreWhitespace:!0}),l.diff(e,t,n)}function u(e,t,n){return l.diff(e,t,n)}t.wordDiff=l,l.equals=function(e,t){return this.options.ignoreCase&&(e=e.toLowerCase(),t=t.toLowerCase()),e===t||this.options.ignoreWhitespace&&!s.test(e)&&!s.test(t)},l.tokenize=function(e){for(var t=e.split(/([^\S\r\n]+|[()[\]{}'"\r\n]|\b)/),n=0;n<t.length-1;n++)!t[n+1]&&t[n+2]&&a.test(t[n])&&a.test(t[n+2])&&(t[n]+=t[n+2],t.splice(n+1,2),n--);return t}},48063:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"Diff",{enumerable:!0,get:function(){return r["default"]}}),Object.defineProperty(t,"diffChars",{enumerable:!0,get:function(){return i.diffChars}}),Object.defineProperty(t,"diffWords",{enumerable:!0,get:function(){return o.diffWords}}),Object.defineProperty(t,"diffWordsWithSpace",{enumerable:!0,get:function(){return o.diffWordsWithSpace}}),Object.defineProperty(t,"diffLines",{enumerable:!0,get:function(){return a.diffLines}}),Object.defineProperty(t,"diffTrimmedLines",{enumerable:!0,get:function(){return a.diffTrimmedLines}}),Object.defineProperty(t,"diffSentences",{enumerable:!0,get:function(){return s.diffSentences}}),Object.defineProperty(t,"diffCss",{enumerable:!0,get:function(){return l.diffCss}}),Object.defineProperty(t,"diffJson",{enumerable:!0,get:function(){return c.diffJson}}),Object.defineProperty(t,"canonicalize",{enumerable:!0,get:function(){return c.canonicalize}}),Object.defineProperty(t,"diffArrays",{enumerable:!0,get:function(){return u.diffArrays}}),Object.defineProperty(t,"applyPatch",{enumerable:!0,get:function(){return d.applyPatch}}),Object.defineProperty(t,"applyPatches",{enumerable:!0,get:function(){return d.applyPatches}}),Object.defineProperty(t,"parsePatch",{enumerable:!0,get:function(){return h.parsePatch}}),Object.defineProperty(t,"merge",{enumerable:!0,get:function(){return p.merge}}),Object.defineProperty(t,"structuredPatch",{enumerable:!0,get:function(){return f.structuredPatch}}),Object.defineProperty(t,"createTwoFilesPatch",{enumerable:!0,get:function(){return f.createTwoFilesPatch}}),Object.defineProperty(t,"createPatch",{enumerable:!0,get:function(){return f.createPatch}}),Object.defineProperty(t,"convertChangesToDMP",{enumerable:!0,get:function(){return m.convertChangesToDMP}}),Object.defineProperty(t,"convertChangesToXML",{enumerable:!0,get:function(){return g.convertChangesToXML}});var r=v(n(22458)),i=n(14960),o=n(59843),a=n(91617),s=n(82402),l=n(91224),c=n(69593),u=n(49906),d=n(55474),h=n(7709),p=n(26694),f=n(37668),m=n(26990),g=n(69438);function v(e){return e&&e.__esModule?e:{default:e}}},55474:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.applyPatch=a,t.applyPatches=s;var r=n(7709),i=o(n(55772));function o(e){return e&&e.__esModule?e:{default:e}}function a(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if("string"===typeof t&&(t=(0,r.parsePatch)(t)),Array.isArray(t)){if(t.length>1)throw new Error("applyPatch only works with a single input.");t=t[0]}var o,a,s=e.split(/\r\n|[\n\v\f\r\x85]/),l=e.match(/\r\n|[\n\v\f\r\x85]/g)||[],c=t.hunks,u=n.compareLine||function(e,t,n,r){return t===r},d=0,h=n.fuzzFactor||0,p=0,f=0;function m(e,t){for(var n=0;n<e.lines.length;n++){var r=e.lines[n],i=r.length>0?r[0]:" ",o=r.length>0?r.substr(1):r;if(" "===i||"-"===i){if(!u(t+1,s[t],i,o)&&(d++,d>h))return!1;t++}}return!0}for(var g=0;g<c.length;g++){for(var v=c[g],b=s.length-v.oldLines,y=0,w=f+v.oldStart-1,O=(0,i["default"])(w,p,b);void 0!==y;y=O())if(m(v,w+y)){v.offset=f+=y;break}if(void 0===y)return!1;p=v.offset+v.oldStart+v.oldLines}for(var S=0,E=0;E<c.length;E++){var x=c[E],_=x.oldStart+x.offset+S-1;S+=x.newLines-x.oldLines;for(var k=0;k<x.lines.length;k++){var C=x.lines[k],A=C.length>0?C[0]:" ",T=C.length>0?C.substr(1):C,R=x.linedelimiters[k];if(" "===A)_++;else if("-"===A)s.splice(_,1),l.splice(_,1);else if("+"===A)s.splice(_,0,T),l.splice(_,0,R),_++;else if("\\"===A){var N=x.lines[k-1]?x.lines[k-1][0]:null;"+"===N?o=!0:"-"===N&&(a=!0)}}}if(o)while(!s[s.length-1])s.pop(),l.pop();else a&&(s.push(""),l.push("\n"));for(var P=0;P<s.length-1;P++)s[P]=s[P]+l[P];return s.join("")}function s(e,t){"string"===typeof e&&(e=(0,r.parsePatch)(e));var n=0;function i(){var r=e[n++];if(!r)return t.complete();t.loadFile(r,function(e,n){if(e)return t.complete(e);var o=a(n,r,t);t.patched(r,o,function(e){if(e)return t.complete(e);i()})})}i()}},37668:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.structuredPatch=u,t.formatPatch=d,t.createTwoFilesPatch=h,t.createPatch=p;var r=n(91617);function i(e){return l(e)||s(e)||a(e)||o()}function o(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function a(e,t){if(e){if("string"===typeof e)return c(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?c(e,t):void 0}}function s(e){if("undefined"!==typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}function l(e){if(Array.isArray(e))return c(e)}function c(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function u(e,t,n,o,a,s,l){l||(l={}),"undefined"===typeof l.context&&(l.context=4);var c=(0,r.diffLines)(n,o,l);if(c){c.push({value:"",lines:[]});for(var u=[],d=0,h=0,p=[],f=1,m=1,g=function(e){var t=c[e],r=t.lines||t.value.replace(/\n$/,"").split("\n");if(t.lines=r,t.added||t.removed){var a;if(!d){var s=c[e-1];d=f,h=m,s&&(p=l.context>0?b(s.lines.slice(-l.context)):[],d-=p.length,h-=p.length)}(a=p).push.apply(a,i(r.map(function(e){return(t.added?"+":"-")+e}))),t.added?m+=r.length:f+=r.length}else{if(d)if(r.length<=2*l.context&&e<c.length-2){var g;(g=p).push.apply(g,i(b(r)))}else{var v,y=Math.min(r.length,l.context);(v=p).push.apply(v,i(b(r.slice(0,y))));var w={oldStart:d,oldLines:f-d+y,newStart:h,newLines:m-h+y,lines:p};if(e>=c.length-2&&r.length<=l.context){var O=/\n$/.test(n),S=/\n$/.test(o),E=0==r.length&&p.length>w.oldLines;!O&&E&&n.length>0&&p.splice(w.oldLines,0,"\\ No newline at end of file"),(O||E)&&S||p.push("\\ No newline at end of file")}u.push(w),d=0,h=0,p=[]}f+=r.length,m+=r.length}},v=0;v<c.length;v++)g(v);return{oldFileName:e,newFileName:t,oldHeader:a,newHeader:s,hunks:u}}function b(e){return e.map(function(e){return" "+e})}}function d(e){var t=[];e.oldFileName==e.newFileName&&t.push("Index: "+e.oldFileName),t.push("==================================================================="),t.push("--- "+e.oldFileName+("undefined"===typeof e.oldHeader?"":"\t"+e.oldHeader)),t.push("+++ "+e.newFileName+("undefined"===typeof e.newHeader?"":"\t"+e.newHeader));for(var n=0;n<e.hunks.length;n++){var r=e.hunks[n];0===r.oldLines&&(r.oldStart-=1),0===r.newLines&&(r.newStart-=1),t.push("@@ -"+r.oldStart+","+r.oldLines+" +"+r.newStart+","+r.newLines+" @@"),t.push.apply(t,r.lines)}return t.join("\n")+"\n"}function h(e,t,n,r,i,o,a){return d(u(e,t,n,r,i,o,a))}function p(e,t,n,r,i,o){return h(e,e,t,n,r,i,o)}},26694:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.calcLineCount=h,t.merge=p;var r=n(37668),i=n(7709),o=n(73361);function a(e){return u(e)||c(e)||l(e)||s()}function s(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function l(e,t){if(e){if("string"===typeof e)return d(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?d(e,t):void 0}}function c(e){if("undefined"!==typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}function u(e){if(Array.isArray(e))return d(e)}function d(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function h(e){var t=T(e.lines),n=t.oldLines,r=t.newLines;void 0!==n?e.oldLines=n:delete e.oldLines,void 0!==r?e.newLines=r:delete e.newLines}function p(e,t,n){e=f(e,n),t=f(t,n);var r={};(e.index||t.index)&&(r.index=e.index||t.index),(e.newFileName||t.newFileName)&&(m(e)?m(t)?(r.oldFileName=g(r,e.oldFileName,t.oldFileName),r.newFileName=g(r,e.newFileName,t.newFileName),r.oldHeader=g(r,e.oldHeader,t.oldHeader),r.newHeader=g(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=[];var i=0,o=0,a=0,s=0;while(i<e.hunks.length||o<t.hunks.length){var l=e.hunks[i]||{oldStart:1/0},c=t.hunks[o]||{oldStart:1/0};if(v(l,c))r.hunks.push(b(l,a)),i++,s+=l.newLines-l.oldLines;else if(v(c,l))r.hunks.push(b(c,s)),o++,a+=c.newLines-c.oldLines;else{var u={oldStart:Math.min(l.oldStart,c.oldStart),oldLines:0,newStart:Math.min(l.newStart+a,c.oldStart+s),newLines:0,lines:[]};y(u,l.oldStart,l.lines,c.oldStart,c.lines),o++,i++,r.hunks.push(u)}}return r}function f(e,t){if("string"===typeof e){if(/^@@/m.test(e)||/^Index:/m.test(e))return(0,i.parsePatch)(e)[0];if(!t)throw new Error("Must provide a base reference or pass in a patch");return(0,r.structuredPatch)(void 0,void 0,t,e)}return e}function m(e){return e.newFileName&&e.newFileName!==e.oldFileName}function g(e,t,n){return t===n?t:(e.conflict=!0,{mine:t,theirs:n})}function v(e,t){return e.oldStart<t.oldStart&&e.oldStart+e.oldLines<t.oldStart}function b(e,t){return{oldStart:e.oldStart,oldLines:e.oldLines,newStart:e.newStart+t,newLines:e.newLines,lines:e.lines}}function y(e,t,n,r,i){var o={offset:t,lines:n,index:0},s={offset:r,lines:i,index:0};E(e,o,s),E(e,s,o);while(o.index<o.lines.length&&s.index<s.lines.length){var l=o.lines[o.index],c=s.lines[s.index];if("-"!==l[0]&&"+"!==l[0]||"-"!==c[0]&&"+"!==c[0])if("+"===l[0]&&" "===c[0]){var u;(u=e.lines).push.apply(u,a(_(o)))}else if("+"===c[0]&&" "===l[0]){var d;(d=e.lines).push.apply(d,a(_(s)))}else"-"===l[0]&&" "===c[0]?O(e,o,s):"-"===c[0]&&" "===l[0]?O(e,s,o,!0):l===c?(e.lines.push(l),o.index++,s.index++):S(e,_(o),_(s));else w(e,o,s)}x(e,o),x(e,s),h(e)}function w(e,t,n){var r=_(t),i=_(n);if(C(r)&&C(i)){var s,l;if((0,o.arrayStartsWith)(r,i)&&A(n,r,r.length-i.length))return void(s=e.lines).push.apply(s,a(r));if((0,o.arrayStartsWith)(i,r)&&A(t,i,i.length-r.length))return void(l=e.lines).push.apply(l,a(i))}else if((0,o.arrayEqual)(r,i)){var c;return void(c=e.lines).push.apply(c,a(r))}S(e,r,i)}function O(e,t,n,r){var i,o=_(t),s=k(n,o);s.merged?(i=e.lines).push.apply(i,a(s.merged)):S(e,r?s:o,r?o:s)}function S(e,t,n){e.conflict=!0,e.lines.push({conflict:!0,mine:t,theirs:n})}function E(e,t,n){while(t.offset<n.offset&&t.index<t.lines.length){var r=t.lines[t.index++];e.lines.push(r),t.offset++}}function x(e,t){while(t.index<t.lines.length){var n=t.lines[t.index++];e.lines.push(n)}}function _(e){var t=[],n=e.lines[e.index][0];while(e.index<e.lines.length){var r=e.lines[e.index];if("-"===n&&"+"===r[0]&&(n="+"),n!==r[0])break;t.push(r),e.index++}return t}function k(e,t){var n=[],r=[],i=0,o=!1,a=!1;while(i<t.length&&e.index<e.lines.length){var s=e.lines[e.index],l=t[i];if("+"===l[0])break;if(o=o||" "!==s[0],r.push(l),i++,"+"===s[0]){a=!0;while("+"===s[0])n.push(s),s=e.lines[++e.index]}l.substr(1)===s.substr(1)?(n.push(s),e.index++):a=!0}if("+"===(t[i]||"")[0]&&o&&(a=!0),a)return n;while(i<t.length)r.push(t[i++]);return{merged:r,changes:n}}function C(e){return e.reduce(function(e,t){return e&&"-"===t[0]},!0)}function A(e,t,n){for(var r=0;r<n;r++){var i=t[t.length-n+r].substr(1);if(e.lines[e.index+r]!==" "+i)return!1}return e.index+=n,!0}function T(e){var t=0,n=0;return e.forEach(function(e){if("string"!==typeof e){var r=T(e.mine),i=T(e.theirs);void 0!==t&&(r.oldLines===i.oldLines?t+=r.oldLines:t=void 0),void 0!==n&&(r.newLines===i.newLines?n+=r.newLines:n=void 0)}else void 0===n||"+"!==e[0]&&" "!==e[0]||n++,void 0===t||"-"!==e[0]&&" "!==e[0]||t++}),{oldLines:t,newLines:n}}},7709:function(e,t){"use strict";function n(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=e.split(/\r\n|[\n\v\f\r\x85]/),r=e.match(/\r\n|[\n\v\f\r\x85]/g)||[],i=[],o=0;function a(){var e={};i.push(e);while(o<n.length){var r=n[o];if(/^(\-\-\-|\+\+\+|@@)\s/.test(r))break;var a=/^(?:Index:|diff(?: -r \w+)+)\s+(.+?)\s*$/.exec(r);a&&(e.index=a[1]),o++}s(e),s(e),e.hunks=[];while(o<n.length){var c=n[o];if(/^(Index:|diff|\-\-\-|\+\+\+)\s/.test(c))break;if(/^@@/.test(c))e.hunks.push(l());else{if(c&&t.strict)throw new Error("Unknown line "+(o+1)+" "+JSON.stringify(c));o++}}}function s(e){var t=/^(---|\+\+\+)\s+(.*)$/.exec(n[o]);if(t){var r="---"===t[1]?"old":"new",i=t[2].split("\t",2),a=i[0].replace(/\\\\/g,"\\");/^".*"$/.test(a)&&(a=a.substr(1,a.length-2)),e[r+"FileName"]=a,e[r+"Header"]=(i[1]||"").trim(),o++}}function l(){var e=o,i=n[o++],a=i.split(/@@ -(\d+)(?:,(\d+))? \+(\d+)(?:,(\d+))? @@/),s={oldStart:+a[1],oldLines:"undefined"===typeof a[2]?1:+a[2],newStart:+a[3],newLines:"undefined"===typeof a[4]?1:+a[4],lines:[],linedelimiters:[]};0===s.oldLines&&(s.oldStart+=1),0===s.newLines&&(s.newStart+=1);for(var l=0,c=0;o<n.length;o++){if(0===n[o].indexOf("--- ")&&o+2<n.length&&0===n[o+1].indexOf("+++ ")&&0===n[o+2].indexOf("@@"))break;var u=0==n[o].length&&o!=n.length-1?" ":n[o][0];if("+"!==u&&"-"!==u&&" "!==u&&"\\"!==u)break;s.lines.push(n[o]),s.linedelimiters.push(r[o]||"\n"),"+"===u?l++:"-"===u?c++:" "===u&&(l++,c++)}if(l||1!==s.newLines||(s.newLines=0),c||1!==s.oldLines||(s.oldLines=0),t.strict){if(l!==s.newLines)throw new Error("Added line count did not match for hunk at line "+(e+1));if(c!==s.oldLines)throw new Error("Removed line count did not match for hunk at line "+(e+1))}return s}while(o<n.length)a();return i}Object.defineProperty(t,"__esModule",{value:!0}),t.parsePatch=n},73361:function(e,t){"use strict";function n(e,t){return e.length===t.length&&r(e,t)}function r(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(t,"__esModule",{value:!0}),t.arrayEqual=n,t.arrayStartsWith=r},55772:function(e,t){"use strict";function n(e,t,n){var r=!0,i=!1,o=!1,a=1;return function s(){if(r&&!o){if(i?a++:r=!1,e+a<=n)return a;o=!0}if(!i)return o||(r=!0),t<=e-a?-a++:(i=!0,s())}}Object.defineProperty(t,"__esModule",{value:!0}),t["default"]=n},85928:function(e,t){"use strict";function n(e,t){if("function"===typeof e)t.callback=e;else if(e)for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t}Object.defineProperty(t,"__esModule",{value:!0}),t.generateOptions=n},46423:function(e,t,n){"use strict";var r,i=n(79903),o=n(69336);try{r=[].__proto__===Array.prototype}catch(c){if(!c||"object"!==typeof c||!("code"in c)||"ERR_PROTO_ACCESS"!==c.code)throw c}var a=!!r&&o&&o(Object.prototype,"__proto__"),s=Object,l=s.getPrototypeOf;e.exports=a&&"function"===typeof a.get?i([a.get]):"function"===typeof l&&function(e){return l(null==e?e:s(e))}},64940:function(e){"use strict";var t=Object.defineProperty||!1;if(t)try{t({},"a",{value:1})}catch(n){t=!1}e.exports=t},29110:function(e){"use strict";e.exports=EvalError},29838:function(e){"use strict";e.exports=Error},61155:function(e){"use strict";e.exports=RangeError},94943:function(e){"use strict";e.exports=ReferenceError},5731:function(e){"use strict";e.exports=SyntaxError},3468:function(e){"use strict";e.exports=TypeError},32140:function(e){"use strict";e.exports=URIError},9629:function(e){"use strict";e.exports=Object},50046:function(e,t,n){"use strict";var r,i=n(4364),o="object"===typeof Reflect?Reflect:null,a=o&&"function"===typeof o.apply?o.apply:function(e,t,n){return Function.prototype.apply.call(e,t,n)};function s(e){i&&i.warn&&i.warn(e)}r=o&&"function"===typeof o.ownKeys?o.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var l=Number.isNaN||function(e){return e!==e};function c(){c.init.call(this)}e.exports=c,e.exports.once=O,c.EventEmitter=c,c.prototype._events=void 0,c.prototype._eventsCount=0,c.prototype._maxListeners=void 0;var u=10;function d(e){if("function"!==typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function h(e){return void 0===e._maxListeners?c.defaultMaxListeners:e._maxListeners}function p(e,t,n,r){var i,o,a;if(d(n),o=e._events,void 0===o?(o=e._events=Object.create(null),e._eventsCount=0):(void 0!==o.newListener&&(e.emit("newListener",t,n.listener?n.listener:n),o=e._events),a=o[t]),void 0===a)a=o[t]=n,++e._eventsCount;else if("function"===typeof a?a=o[t]=r?[n,a]:[a,n]:r?a.unshift(n):a.push(n),i=h(e),i>0&&a.length>i&&!a.warned){a.warned=!0;var l=new Error("Possible EventEmitter memory leak detected. "+a.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");l.name="MaxListenersExceededWarning",l.emitter=e,l.type=t,l.count=a.length,s(l)}return e}function f(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function m(e,t,n){var r={fired:!1,wrapFn:void 0,target:e,type:t,listener:n},i=f.bind(r);return i.listener=n,r.wrapFn=i,i}function g(e,t,n){var r=e._events;if(void 0===r)return[];var i=r[t];return void 0===i?[]:"function"===typeof i?n?[i.listener||i]:[i]:n?w(i):b(i,i.length)}function v(e){var t=this._events;if(void 0!==t){var n=t[e];if("function"===typeof n)return 1;if(void 0!==n)return n.length}return 0}function b(e,t){for(var n=new Array(t),r=0;r<t;++r)n[r]=e[r];return n}function y(e,t){for(;t+1<e.length;t++)e[t]=e[t+1];e.pop()}function w(e){for(var t=new Array(e.length),n=0;n<t.length;++n)t[n]=e[n].listener||e[n];return t}function O(e,t){return new Promise(function(n,r){function i(n){e.removeListener(t,o),r(n)}function o(){"function"===typeof e.removeListener&&e.removeListener("error",i),n([].slice.call(arguments))}E(e,t,o,{once:!0}),"error"!==t&&S(e,i,{once:!0})})}function S(e,t,n){"function"===typeof e.on&&E(e,"error",t,n)}function E(e,t,n,r){if("function"===typeof e.on)r.once?e.once(t,n):e.on(t,n);else{if("function"!==typeof e.addEventListener)throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof e);e.addEventListener(t,function i(o){r.once&&e.removeEventListener(t,i),n(o)})}}Object.defineProperty(c,"defaultMaxListeners",{enumerable:!0,get:function(){return u},set:function(e){if("number"!==typeof e||e<0||l(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");u=e}}),c.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},c.prototype.setMaxListeners=function(e){if("number"!==typeof e||e<0||l(e))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this},c.prototype.getMaxListeners=function(){return h(this)},c.prototype.emit=function(e){for(var t=[],n=1;n<arguments.length;n++)t.push(arguments[n]);var r="error"===e,i=this._events;if(void 0!==i)r=r&&void 0===i.error;else if(!r)return!1;if(r){var o;if(t.length>0&&(o=t[0]),o instanceof Error)throw o;var s=new Error("Unhandled error."+(o?" ("+o.message+")":""));throw s.context=o,s}var l=i[e];if(void 0===l)return!1;if("function"===typeof l)a(l,this,t);else{var c=l.length,u=b(l,c);for(n=0;n<c;++n)a(u[n],this,t)}return!0},c.prototype.addListener=function(e,t){return p(this,e,t,!1)},c.prototype.on=c.prototype.addListener,c.prototype.prependListener=function(e,t){return p(this,e,t,!0)},c.prototype.once=function(e,t){return d(t),this.on(e,m(this,e,t)),this},c.prototype.prependOnceListener=function(e,t){return d(t),this.prependListener(e,m(this,e,t)),this},c.prototype.removeListener=function(e,t){var n,r,i,o,a;if(d(t),r=this._events,void 0===r)return this;if(n=r[e],void 0===n)return this;if(n===t||n.listener===t)0===--this._eventsCount?this._events=Object.create(null):(delete r[e],r.removeListener&&this.emit("removeListener",e,n.listener||t));else if("function"!==typeof n){for(i=-1,o=n.length-1;o>=0;o--)if(n[o]===t||n[o].listener===t){a=n[o].listener,i=o;break}if(i<0)return this;0===i?n.shift():y(n,i),1===n.length&&(r[e]=n[0]),void 0!==r.removeListener&&this.emit("removeListener",e,a||t)}return this},c.prototype.off=c.prototype.removeListener,c.prototype.removeAllListeners=function(e){var t,n,r;if(n=this._events,void 0===n)return this;if(void 0===n.removeListener)return 0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==n[e]&&(0===--this._eventsCount?this._events=Object.create(null):delete n[e]),this;if(0===arguments.length){var i,o=Object.keys(n);for(r=0;r<o.length;++r)i=o[r],"removeListener"!==i&&this.removeAllListeners(i);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if(t=n[e],"function"===typeof t)this.removeListener(e,t);else if(void 0!==t)for(r=t.length-1;r>=0;r--)this.removeListener(e,t[r]);return this},c.prototype.listeners=function(e){return g(this,e,!0)},c.prototype.rawListeners=function(e){return g(this,e,!1)},c.listenerCount=function(e,t){return"function"===typeof e.listenerCount?e.listenerCount(t):v.call(e,t)},c.prototype.listenerCount=v,c.prototype.eventNames=function(){return this._eventsCount>0?r(this._events):[]}},80705:function(e,t,n){"use strict";var r=n(89617),i=Object.prototype.toString,o=Object.prototype.hasOwnProperty,a=function(e,t,n){for(var r=0,i=e.length;r<i;r++)o.call(e,r)&&(null==n?t(e[r],r,e):t.call(n,e[r],r,e))},s=function(e,t,n){for(var r=0,i=e.length;r<i;r++)null==n?t(e.charAt(r),r,e):t.call(n,e.charAt(r),r,e)},l=function(e,t,n){for(var r in e)o.call(e,r)&&(null==n?t(e[r],r,e):t.call(n,e[r],r,e))};function c(e){return"[object Array]"===i.call(e)}e.exports=function(e,t,n){if(!r(t))throw new TypeError("iterator must be a function");var i;arguments.length>=3&&(i=n),c(e)?a(e,t,i):"string"===typeof e?s(e,t,i):l(e,t,i)}},28794:function(e){"use strict";var t="Function.prototype.bind called on incompatible ",n=Object.prototype.toString,r=Math.max,i="[object Function]",o=function(e,t){for(var n=[],r=0;r<e.length;r+=1)n[r]=e[r];for(var i=0;i<t.length;i+=1)n[i+e.length]=t[i];return n},a=function(e,t){for(var n=[],r=t||0,i=0;r<e.length;r+=1,i+=1)n[i]=e[r];return n},s=function(e,t){for(var n="",r=0;r<e.length;r+=1)n+=e[r],r+1<e.length&&(n+=t);return n};e.exports=function(e){var l=this;if("function"!==typeof l||n.apply(l)!==i)throw new TypeError(t+l);for(var c,u=a(arguments,1),d=function(){if(this instanceof c){var t=l.apply(this,o(u,arguments));return Object(t)===t?t:this}return l.apply(e,o(u,arguments))},h=r(0,l.length-u.length),p=[],f=0;f<h;f++)p[f]="$"+f;if(c=Function("binder","return function ("+s(p,",")+"){ return binder.apply(this,arguments); }")(d),l.prototype){var m=function(){};m.prototype=l.prototype,c.prototype=new m,m.prototype=null}return c}},79138:function(e,t,n){"use strict";var r=n(28794);e.exports=Function.prototype.bind||r},14898:function(e){"use strict";const t=function*(){}.constructor;e.exports=()=>t},528:function(e,t,n){"use strict";var r,i=n(9629),o=n(29838),a=n(29110),s=n(61155),l=n(94943),c=n(5731),u=n(3468),d=n(32140),h=n(58479),p=n(18449),f=n(88129),m=n(22387),g=n(85865),v=n(1319),b=n(36882),y=Function,w=function(e){try{return y('"use strict"; return ('+e+").constructor;")()}catch(t){}},O=n(69336),S=n(64940),E=function(){throw new u},x=O?function(){try{return E}catch(e){try{return O(arguments,"callee").get}catch(t){return E}}}():E,_=n(53558)(),k=n(46369),C=n(17345),A=n(57859),T=n(6095),R=n(64531),N={},P="undefined"!==typeof Uint8Array&&k?k(Uint8Array):r,I={__proto__:null,"%AggregateError%":"undefined"===typeof AggregateError?r:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"===typeof ArrayBuffer?r:ArrayBuffer,"%ArrayIteratorPrototype%":_&&k?k([][Symbol.iterator]()):r,"%AsyncFromSyncIteratorPrototype%":r,"%AsyncFunction%":N,"%AsyncGenerator%":N,"%AsyncGeneratorFunction%":N,"%AsyncIteratorPrototype%":N,"%Atomics%":"undefined"===typeof Atomics?r:Atomics,"%BigInt%":"undefined"===typeof BigInt?r:BigInt,"%BigInt64Array%":"undefined"===typeof BigInt64Array?r:BigInt64Array,"%BigUint64Array%":"undefined"===typeof BigUint64Array?r:BigUint64Array,"%Boolean%":Boolean,"%DataView%":"undefined"===typeof DataView?r:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":o,"%eval%":eval,"%EvalError%":a,"%Float16Array%":"undefined"===typeof Float16Array?r:Float16Array,"%Float32Array%":"undefined"===typeof Float32Array?r:Float32Array,"%Float64Array%":"undefined"===typeof Float64Array?r:Float64Array,"%FinalizationRegistry%":"undefined"===typeof FinalizationRegistry?r:FinalizationRegistry,"%Function%":y,"%GeneratorFunction%":N,"%Int8Array%":"undefined"===typeof Int8Array?r:Int8Array,"%Int16Array%":"undefined"===typeof Int16Array?r:Int16Array,"%Int32Array%":"undefined"===typeof Int32Array?r:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":_&&k?k(k([][Symbol.iterator]())):r,"%JSON%":"object"===typeof JSON?JSON:r,"%Map%":"undefined"===typeof Map?r:Map,"%MapIteratorPrototype%":"undefined"!==typeof Map&&_&&k?k((new Map)[Symbol.iterator]()):r,"%Math%":Math,"%Number%":Number,"%Object%":i,"%Object.getOwnPropertyDescriptor%":O,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"===typeof Promise?r:Promise,"%Proxy%":"undefined"===typeof Proxy?r:Proxy,"%RangeError%":s,"%ReferenceError%":l,"%Reflect%":"undefined"===typeof Reflect?r:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"===typeof Set?r:Set,"%SetIteratorPrototype%":"undefined"!==typeof Set&&_&&k?k((new Set)[Symbol.iterator]()):r,"%SharedArrayBuffer%":"undefined"===typeof SharedArrayBuffer?r:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":_&&k?k(""[Symbol.iterator]()):r,"%Symbol%":_?Symbol:r,"%SyntaxError%":c,"%ThrowTypeError%":x,"%TypedArray%":P,"%TypeError%":u,"%Uint8Array%":"undefined"===typeof Uint8Array?r:Uint8Array,"%Uint8ClampedArray%":"undefined"===typeof Uint8ClampedArray?r:Uint8ClampedArray,"%Uint16Array%":"undefined"===typeof Uint16Array?r:Uint16Array,"%Uint32Array%":"undefined"===typeof Uint32Array?r:Uint32Array,"%URIError%":d,"%WeakMap%":"undefined"===typeof WeakMap?r:WeakMap,"%WeakRef%":"undefined"===typeof WeakRef?r:WeakRef,"%WeakSet%":"undefined"===typeof WeakSet?r:WeakSet,"%Function.prototype.call%":R,"%Function.prototype.apply%":T,"%Object.defineProperty%":S,"%Object.getPrototypeOf%":C,"%Math.abs%":h,"%Math.floor%":p,"%Math.max%":f,"%Math.min%":m,"%Math.pow%":g,"%Math.round%":v,"%Math.sign%":b,"%Reflect.getPrototypeOf%":A};if(k)try{null.error}catch(K){var M=k(k(K));I["%Error.prototype%"]=M}var D=function e(t){var n;if("%AsyncFunction%"===t)n=w("async function () {}");else if("%GeneratorFunction%"===t)n=w("function* () {}");else if("%AsyncGeneratorFunction%"===t)n=w("async function* () {}");else if("%AsyncGenerator%"===t){var r=e("%AsyncGeneratorFunction%");r&&(n=r.prototype)}else if("%AsyncIteratorPrototype%"===t){var i=e("%AsyncGenerator%");i&&k&&(n=k(i.prototype))}return I[t]=n,n},L={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},B=n(79138),$=n(78554),V=B.call(R,Array.prototype.concat),F=B.call(T,Array.prototype.splice),j=B.call(R,String.prototype.replace),U=B.call(R,String.prototype.slice),G=B.call(R,RegExp.prototype.exec),H=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,q=/\\(\\)?/g,Q=function(e){var t=U(e,0,1),n=U(e,-1);if("%"===t&&"%"!==n)throw new c("invalid intrinsic syntax, expected closing `%`");if("%"===n&&"%"!==t)throw new c("invalid intrinsic syntax, expected opening `%`");var r=[];return j(e,H,function(e,t,n,i){r[r.length]=n?j(i,q,"$1"):t||e}),r},z=function(e,t){var n,r=e;if($(L,r)&&(n=L[r],r="%"+n[0]+"%"),$(I,r)){var i=I[r];if(i===N&&(i=D(r)),"undefined"===typeof i&&!t)throw new u("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:n,name:r,value:i}}throw new c("intrinsic "+e+" does not exist!")};e.exports=function(e,t){if("string"!==typeof e||0===e.length)throw new u("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!==typeof t)throw new u('"allowMissing" argument must be a boolean');if(null===G(/^%?[^%]*%?$/,e))throw new c("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var n=Q(e),r=n.length>0?n[0]:"",i=z("%"+r+"%",t),o=i.name,a=i.value,s=!1,l=i.alias;l&&(r=l[0],F(n,V([0,1],l)));for(var d=1,h=!0;d<n.length;d+=1){var p=n[d],f=U(p,0,1),m=U(p,-1);if(('"'===f||"'"===f||"`"===f||'"'===m||"'"===m||"`"===m)&&f!==m)throw new c("property names with quotes must have matching quotes");if("constructor"!==p&&h||(s=!0),r+="."+p,o="%"+r+"%",$(I,o))a=I[o];else if(null!=a){if(!(p in a)){if(!t)throw new u("base intrinsic for "+e+" exists, but the property is not available.");return}if(O&&d+1>=n.length){var g=O(a,p);h=!!g,a=h&&"get"in g&&!("originalValue"in g.get)?g.get:a[p]}else h=$(a,p),a=a[p];h&&!s&&(I[o]=a)}}return a}},17345:function(e,t,n){"use strict";var r=n(9629);e.exports=r.getPrototypeOf||null},57859:function(e){"use strict";e.exports="undefined"!==typeof Reflect&&Reflect.getPrototypeOf||null},46369:function(e,t,n){"use strict";var r=n(57859),i=n(17345),o=n(46423);e.exports=r?function(e){return r(e)}:i?function(e){if(!e||"object"!==typeof e&&"function"!==typeof e)throw new TypeError("getProto: not an object");return i(e)}:o?function(e){return o(e)}:null},61292:function(e){"use strict";e.exports=Object.getOwnPropertyDescriptor},69336:function(e,t,n){"use strict";var r=n(61292);if(r)try{r([],"length")}catch(i){r=null}e.exports=r},17239:function(e,t,n){"use strict";var r=n(64940),i=function(){return!!r};i.hasArrayLengthDefineBug=function(){if(!r)return null;try{return 1!==r([],"length",{value:1}).length}catch(e){return!0}},e.exports=i},53558:function(e,t,n){"use strict";var r="undefined"!==typeof Symbol&&Symbol,i=n(62908);e.exports=function(){return"function"===typeof r&&("function"===typeof Symbol&&("symbol"===typeof r("foo")&&("symbol"===typeof Symbol("bar")&&i())))}},62908:function(e){"use strict";e.exports=function(){if("function"!==typeof Symbol||"function"!==typeof Object.getOwnPropertySymbols)return!1;if("symbol"===typeof Symbol.iterator)return!0;var e={},t=Symbol("test"),n=Object(t);if("string"===typeof t)return!1;if("[object Symbol]"!==Object.prototype.toString.call(t))return!1;if("[object Symbol]"!==Object.prototype.toString.call(n))return!1;var r=42;for(var i in e[t]=r,e)return!1;if("function"===typeof Object.keys&&0!==Object.keys(e).length)return!1;if("function"===typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(e).length)return!1;var o=Object.getOwnPropertySymbols(e);if(1!==o.length||o[0]!==t)return!1;if(!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if("function"===typeof Object.getOwnPropertyDescriptor){var a=Object.getOwnPropertyDescriptor(e,t);if(a.value!==r||!0!==a.enumerable)return!1}return!0}},51913:function(e,t,n){"use strict";var r=n(62908);e.exports=function(){return r()&&!!Symbol.toStringTag}},78554:function(e,t,n){"use strict";var r=Function.prototype.call,i=Object.prototype.hasOwnProperty,o=n(79138);e.exports=o.call(r,i)},51815:function(e,t){(function(e){var t=/\S/,n=/\"/g,r=/\n/g,i=/\r/g,o=/\\/g,a=/\u2028/,s=/\u2029/;function l(e){"}"===e.n.substr(e.n.length-1)&&(e.n=e.n.substring(0,e.n.length-1))}function c(e){return e.trim?e.trim():e.replace(/^\s*|\s*$/g,"")}function u(e,t,n){if(t.charAt(n)!=e.charAt(0))return!1;for(var r=1,i=e.length;r<i;r++)if(t.charAt(n+r)!=e.charAt(r))return!1;return!0}e.tags={"#":1,"^":2,"<":3,$:4,"/":5,"!":6,">":7,"=":8,_v:9,"{":10,"&":11,_t:12},e.scan=function(n,r){var i=n.length,o=0,a=1,s=2,d=o,h=null,p=null,f="",m=[],g=!1,v=0,b=0,y="{{",w="}}";function O(){f.length>0&&(m.push({tag:"_t",text:new String(f)}),f="")}function S(){for(var n=!0,r=b;r<m.length;r++)if(n=e.tags[m[r].tag]<e.tags["_v"]||"_t"==m[r].tag&&null===m[r].text.match(t),!n)return!1;return n}function E(e,t){if(O(),e&&S())for(var n,r=b;r<m.length;r++)m[r].text&&((n=m[r+1])&&">"==n.tag&&(n.indent=m[r].text.toString()),m.splice(r,1));else t||m.push({tag:"\n"});g=!1,b=m.length}function x(e,t){var n="="+w,r=e.indexOf(n,t),i=c(e.substring(e.indexOf("=",t)+1,r)).split(" ");return y=i[0],w=i[i.length-1],r+n.length-1}for(r&&(r=r.split(" "),y=r[0],w=r[1]),v=0;v<i;v++)d==o?u(y,n,v)?(--v,O(),d=a):"\n"==n.charAt(v)?E(g):f+=n.charAt(v):d==a?(v+=y.length-1,p=e.tags[n.charAt(v+1)],h=p?n.charAt(v+1):"_v","="==h?(v=x(n,v),d=o):(p&&v++,d=s),g=v):u(w,n,v)?(m.push({tag:h,n:c(f),otag:y,ctag:w,i:"/"==h?g-y.length:v+w.length}),f="",v+=w.length-1,d=o,"{"==h&&("}}"==w?v++:l(m[m.length-1]))):f+=n.charAt(v);return E(g,!0),m};var d={_t:!0,"\n":!0,$:!0,"/":!0};function h(t,n,r,i){var o=[],a=null,s=null,l=null;s=r[r.length-1];while(t.length>0){if(l=t.shift(),s&&"<"==s.tag&&!(l.tag in d))throw new Error("Illegal content in < super tag.");if(e.tags[l.tag]<=e.tags["$"]||p(l,i))r.push(l),l.nodes=h(t,l.tag,r,i);else{if("/"==l.tag){if(0===r.length)throw new Error("Closing tag without opener: /"+l.n);if(a=r.pop(),l.n!=a.n&&!f(l.n,a.n,i))throw new Error("Nesting error: "+a.n+" vs. "+l.n);return a.end=l.i,o}"\n"==l.tag&&(l.last=0==t.length||"\n"==t[0].tag)}o.push(l)}if(r.length>0)throw new Error("missing closing tag: "+r.pop().n);return o}function p(e,t){for(var n=0,r=t.length;n<r;n++)if(t[n].o==e.n)return e.tag="#",!0}function f(e,t,n){for(var r=0,i=n.length;r<i;r++)if(n[r].c==e&&n[r].o==t)return!0}function m(e){var t=[];for(var n in e)t.push('"'+b(n)+'": function(c,p,t,i) {'+e[n]+"}");return"{ "+t.join(",")+" }"}function g(e){var t=[];for(var n in e.partials)t.push('"'+b(n)+'":{name:"'+b(e.partials[n].name)+'", '+g(e.partials[n])+"}");return"partials: {"+t.join(",")+"}, subs: "+m(e.subs)}e.stringify=function(t,n,r){return"{code: function (c,p,i) { "+e.wrapMain(t.code)+" },"+g(t)+"}"};var v=0;function b(e){return e.replace(o,"\\\\").replace(n,'\\"').replace(r,"\\n").replace(i,"\\r").replace(a,"\\u2028").replace(s,"\\u2029")}function y(e){return~e.indexOf(".")?"d":"f"}function w(e,t){var n="<"+(t.prefix||""),r=n+e.n+v++;return t.partials[r]={name:e.n,partials:{}},t.code+='t.b(t.rp("'+b(r)+'",c,p,"'+(e.indent||"")+'"));',r}function O(e,t){t.code+="t.b(t.t(t."+y(e.n)+'("'+b(e.n)+'",c,p,0)));'}function S(e){return"t.b("+e+");"}e.generate=function(t,n,r){v=0;var i={code:"",subs:{},partials:{}};return e.walk(t,i),r.asString?this.stringify(i,n,r):this.makeTemplate(i,n,r)},e.wrapMain=function(e){return'var t=this;t.b(i=i||"");'+e+"return t.fl();"},e.template=e.Template,e.makeTemplate=function(e,t,n){var r=this.makePartials(e);return r.code=new Function("c","p","i",this.wrapMain(e.code)),new this.template(r,t,this,n)},e.makePartials=function(e){var t,n={subs:{},partials:e.partials,name:e.name};for(t in n.partials)n.partials[t]=this.makePartials(n.partials[t]);for(t in e.subs)n.subs[t]=new Function("c","p","t","i",e.subs[t]);return n},e.codegen={"#":function(t,n){n.code+="if(t.s(t."+y(t.n)+'("'+b(t.n)+'",c,p,1),c,p,0,'+t.i+","+t.end+',"'+t.otag+" "+t.ctag+'")){t.rs(c,p,function(c,p,t){',e.walk(t.nodes,n),n.code+="});c.pop();}"},"^":function(t,n){n.code+="if(!t.s(t."+y(t.n)+'("'+b(t.n)+'",c,p,1),c,p,1,0,0,"")){',e.walk(t.nodes,n),n.code+="};"},">":w,"<":function(t,n){var r={partials:{},code:"",subs:{},inPartial:!0};e.walk(t.nodes,r);var i=n.partials[w(t,n)];i.subs=r.subs,i.partials=r.partials},$:function(t,n){var r={subs:{},code:"",partials:n.partials,prefix:t.n};e.walk(t.nodes,r),n.subs[t.n]=r.code,n.inPartial||(n.code+='t.sub("'+b(t.n)+'",c,p,i);')},"\n":function(e,t){t.code+=S('"\\n"'+(e.last?"":" + i"))},_v:function(e,t){t.code+="t.b(t.v(t."+y(e.n)+'("'+b(e.n)+'",c,p,0)));'},_t:function(e,t){t.code+=S('"'+b(e.text)+'"')},"{":O,"&":O},e.walk=function(t,n){for(var r,i=0,o=t.length;i<o;i++)r=e.codegen[t[i].tag],r&&r(t[i],n);return n},e.parse=function(e,t,n){return n=n||{},h(e,"",[],n.sectionTags||[])},e.cache={},e.cacheKey=function(e,t){return[e,!!t.asString,!!t.disableLambda,t.delimiters,!!t.modelGet].join("||")},e.compile=function(t,n){n=n||{};var r=e.cacheKey(t,n),i=this.cache[r];if(i){var o=i.partials;for(var a in o)delete o[a].instance;return i}return i=this.generate(this.parse(this.scan(t,n.delimiters),t,n),t,n),this.cache[r]=i}})(t)},62133:function(e,t,n){var r=n(51815);r.Template=n(72252).Template,r.template=r.Template,e.exports=r},72252:function(e,t){(function(e){function t(e,t,n){var r;return t&&"object"==typeof t&&(void 0!==t[e]?r=t[e]:n&&t.get&&"function"==typeof t.get&&(r=t.get(e))),r}function n(e,t,n,r,i,o){function a(){}function s(){}var l;a.prototype=e,s.prototype=e.subs;var c=new a;for(l in c.subs=new s,c.subsText={},c.buf="",r=r||{},c.stackSubs=r,c.subsText=o,t)r[l]||(r[l]=t[l]);for(l in r)c.subs[l]=r[l];for(l in i=i||{},c.stackPartials=i,n)i[l]||(i[l]=n[l]);for(l in i)c.partials[l]=i[l];return c}e.Template=function(e,t,n,r){e=e||{},this.r=e.code||this.r,this.c=n,this.options=r||{},this.text=t||"",this.partials=e.partials||{},this.subs=e.subs||{},this.buf=""},e.Template.prototype={r:function(e,t,n){return""},v:u,t:c,render:function(e,t,n){return this.ri([e],t||{},n)},ri:function(e,t,n){return this.r(e,t,n)},ep:function(e,t){var r=this.partials[e],i=t[r.name];if(r.instance&&r.base==i)return r.instance;if("string"==typeof i){if(!this.c)throw new Error("No compiler available.");i=this.c.compile(i,this.options)}if(!i)return null;if(this.partials[e].base=i,r.subs){for(key in t.stackText||(t.stackText={}),r.subs)t.stackText[key]||(t.stackText[key]=void 0!==this.activeSub&&t.stackText[this.activeSub]?t.stackText[this.activeSub]:this.text);i=n(i,r.subs,r.partials,this.stackSubs,this.stackPartials,t.stackText)}return this.partials[e].instance=i,i},rp:function(e,t,n,r){var i=this.ep(e,n);return i?i.ri(t,n,r):""},rs:function(e,t,n){var r=e[e.length-1];if(d(r))for(var i=0;i<r.length;i++)e.push(r[i]),n(e,t,this),e.pop();else n(e,t,this)},s:function(e,t,n,r,i,o,a){var s;return(!d(e)||0!==e.length)&&("function"==typeof e&&(e=this.ms(e,t,n,r,i,o,a)),s=!!e,!r&&s&&t&&t.push("object"==typeof e?e:t[t.length-1]),s)},d:function(e,n,r,i){var o,a=e.split("."),s=this.f(a[0],n,r,i),l=this.options.modelGet,c=null;if("."===e&&d(n[n.length-2]))s=n[n.length-1];else for(var u=1;u<a.length;u++)o=t(a[u],s,l),void 0!==o?(c=s,s=o):s="";return!(i&&!s)&&(i||"function"!=typeof s||(n.push(c),s=this.mv(s,n,r),n.pop()),s)},f:function(e,n,r,i){for(var o=!1,a=null,s=!1,l=this.options.modelGet,c=n.length-1;c>=0;c--)if(a=n[c],o=t(e,a,l),void 0!==o){s=!0;break}return s?(i||"function"!=typeof o||(o=this.mv(o,n,r)),o):!i&&""},ls:function(e,t,n,r,i){var o=this.options.delimiters;return this.options.delimiters=i,this.b(this.ct(c(e.call(t,r)),t,n)),this.options.delimiters=o,!1},ct:function(e,t,n){if(this.options.disableLambda)throw new Error("Lambda features disabled.");return this.c.compile(e,this.options).render(t,n)},b:function(e){this.buf+=e},fl:function(){var e=this.buf;return this.buf="",e},ms:function(e,t,n,r,i,o,a){var s,l=t[t.length-1],c=e.call(l);return"function"==typeof c?!!r||(s=this.activeSub&&this.subsText&&this.subsText[this.activeSub]?this.subsText[this.activeSub]:this.text,this.ls(c,l,n,s.substring(i,o),a)):c},mv:function(e,t,n){var r=t[t.length-1],i=e.call(r);return"function"==typeof i?this.ct(c(i.call(r)),r,n):i},sub:function(e,t,n,r){var i=this.subs[e];i&&(this.activeSub=e,i(t,n,this,r),this.activeSub=!1)}};var r=/&/g,i=/</g,o=/>/g,a=/\'/g,s=/\"/g,l=/[&<>\"\']/;function c(e){return String(null===e||void 0===e?"":e)}function u(e){return e=c(e),l.test(e)?e.replace(r,"&").replace(i,"<").replace(o,">").replace(a,"'").replace(s,"""):e}var d=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)}})(t)},27500:function(e,t,n){var r=n(4865),i=n(75442),o=e.exports;for(var a in r)r.hasOwnProperty(a)&&(o[a]=r[a]);function s(e){if("string"===typeof e&&(e=i.parse(e)),e.protocol||(e.protocol="https:"),"https:"!==e.protocol)throw new Error('Protocol "'+e.protocol+'" not supported. Expected "https:"');return e}o.request=function(e,t){return e=s(e),r.request.call(this,e,t)},o.get=function(e,t){return e=s(e),r.get.call(this,e,t)}},36313:function(e,t,n){var r=n(1048)["Buffer"];(function(){var t;t="undefined"!==typeof e.exports?n(86530):window.PNGlib;var i=function(e,t){if("string"!==typeof e||e.length<15)throw"A hash of at least 15 characters is required.";this.defaults={background:[240,240,240,255],margin:.08,size:64,saturation:.7,brightness:.5,format:"png"},this.options="object"===typeof t?t:this.defaults,"number"===typeof arguments[1]&&(this.options.size=arguments[1]),arguments[2]&&(this.options.margin=arguments[2]),this.hash=e,this.background=this.options.background||this.defaults.background,this.size=this.options.size||this.defaults.size,this.format=this.options.format||this.defaults.format,this.margin=void 0!==this.options.margin?this.options.margin:this.defaults.margin;var n=parseInt(this.hash.substr(-7),16)/268435455,r=this.options.saturation||this.defaults.saturation,i=this.options.brightness||this.defaults.brightness;this.foreground=this.options.foreground||this.hsl2rgb(n,r,i)};i.prototype={background:null,foreground:null,hash:null,margin:null,size:null,format:null,image:function(){return this.isSvg()?new o(this.size,this.foreground,this.background):new t(this.size,this.size,256)},render:function(){var e,t,n=this.image(),r=this.size,i=Math.floor(r*this.margin),o=Math.floor((r-2*i)/5),a=Math.floor((r-5*o)/2),s=n.color.apply(n,this.background),l=n.color.apply(n,this.foreground);for(e=0;e<15;e++)t=parseInt(this.hash.charAt(e),16)%2?s:l,e<5?this.rectangle(2*o+a,e*o+a,o,o,t,n):e<10?(this.rectangle(1*o+a,(e-5)*o+a,o,o,t,n),this.rectangle(3*o+a,(e-5)*o+a,o,o,t,n)):e<15&&(this.rectangle(0*o+a,(e-10)*o+a,o,o,t,n),this.rectangle(4*o+a,(e-10)*o+a,o,o,t,n));return n},rectangle:function(e,t,n,r,i,o){var a,s;if(this.isSvg())o.rectangles.push({x:e,y:t,w:n,h:r,color:i});else for(a=e;a<e+n;a++)for(s=t;s<t+r;s++)o.buffer[o.index(a,s)]=i},hsl2rgb:function(e,t,n){return e*=6,t=[n+=t*=n<.5?n:1-n,n-e%1*t*2,n-=t*=2,n,n+e%1*t,n+t],[255*t[~~e%6],255*t[(16|e)%6],255*t[(8|e)%6]]},toString:function(e){return e?this.render().getDump():this.render().getBase64()},isSvg:function(){return this.format.match(/svg/i)}};var o=function(e,t,n){this.size=e,this.foreground=this.color.apply(this,t),this.background=this.color.apply(this,n),this.rectangles=[]};o.prototype={size:null,foreground:null,background:null,rectangles:null,color:function(e,t,n,r){var i=[e,t,n].map(Math.round);return i.push(r>=0&&r<=255?r/255:1),"rgba("+i.join(",")+")"},getDump:function(){var e,t,n,r=this.foreground,i=this.background,o=.005*this.size;for(t="<svg xmlns='http://www.w3.org/2000/svg' width='"+this.size+"' height='"+this.size+"' style='background-color:"+i+";'><g style='fill:"+r+"; stroke:"+r+"; stroke-width:"+o+";'>",e=0;e<this.rectangles.length;e++)n=this.rectangles[e],n.color!=i&&(t+="<rect x='"+n.x+"' y='"+n.y+"' width='"+n.w+"' height='"+n.h+"'/>");return t+="</g></svg>",t},getBase64:function(){if("function"===typeof btoa)return btoa(this.getDump());if(r)return new r(this.getDump(),"binary").toString("base64");throw"Cannot generate base64 output"}},"undefined"!==typeof e.exports?e.exports=i:window.Identicon=i})()},86530:function(e){
|
||
/**
|
||
* A handy class to calculate color values.
|
||
*
|
||
* @version 1.0
|
||
* @author Robert Eisele <robert@xarg.org>
|
||
* @copyright Copyright (c) 2010, Robert Eisele
|
||
* @link http://www.xarg.org/2010/03/generate-client-side-png-files-using-javascript/
|
||
* @license http://www.opensource.org/licenses/bsd-license.php BSD License
|
||
*
|
||
*/
|
||
(function(){function t(e,t){for(var n=2;n<arguments.length;n++)for(var r=0;r<arguments[n].length;r++)e[t++]=arguments[n].charAt(r)}function n(e){return String.fromCharCode(e>>8&255,255&e)}function r(e){return String.fromCharCode(e>>24&255,e>>16&255,e>>8&255,255&e)}function i(e){return String.fromCharCode(255&e,e>>8&255)}var o=function(e,o,a){this.width=e,this.height=o,this.depth=a,this.pix_size=o*(e+1),this.data_size=2+this.pix_size+5*Math.floor((65534+this.pix_size)/65535)+4,this.ihdr_offs=0,this.ihdr_size=25,this.plte_offs=this.ihdr_offs+this.ihdr_size,this.plte_size=8+3*a+4,this.trns_offs=this.plte_offs+this.plte_size,this.trns_size=8+a+4,this.idat_offs=this.trns_offs+this.trns_size,this.idat_size=8+this.data_size+4,this.iend_offs=this.idat_offs+this.idat_size,this.iend_size=12,this.buffer_size=this.iend_offs+this.iend_size,this.buffer=new Array,this.palette=new Object,this.pindex=0;for(var s=new Array,l=0;l<this.buffer_size;l++)this.buffer[l]="\0";t(this.buffer,this.ihdr_offs,r(this.ihdr_size-12),"IHDR",r(e),r(o),"\b"),t(this.buffer,this.plte_offs,r(this.plte_size-12),"PLTE"),t(this.buffer,this.trns_offs,r(this.trns_size-12),"tRNS"),t(this.buffer,this.idat_offs,r(this.idat_size-12),"IDAT"),t(this.buffer,this.iend_offs,r(this.iend_size-12),"IEND");var c=30912;c+=31-c%31,t(this.buffer,this.idat_offs+8,n(c));for(l=0;(l<<16)-1<this.pix_size;l++){var u,d;l+65535<this.pix_size?(u=65535,d="\0"):(u=this.pix_size-(l<<16)-l,d=""),t(this.buffer,this.idat_offs+8+2+(l<<16)+(l<<2),d,i(u),i(~u))}for(l=0;l<256;l++){for(var h=l,p=0;p<8;p++)h=1&h?-306674912^h>>1&2147483647:h>>1&2147483647;s[l]=h}this.index=function(e,t){var n=t*(this.width+1)+e+1,r=this.idat_offs+8+2+5*Math.floor(n/65535+1)+n;return r},this.color=function(e,t,n,r){r=r>=0?r:255;var i=((r<<8|e)<<8|t)<<8|n;if("undefined"==typeof this.palette[i]){if(this.pindex==this.depth)return"\0";var o=this.plte_offs+8+3*this.pindex;this.buffer[o+0]=String.fromCharCode(e),this.buffer[o+1]=String.fromCharCode(t),this.buffer[o+2]=String.fromCharCode(n),this.buffer[this.trns_offs+8+this.pindex]=String.fromCharCode(r),this.palette[i]=String.fromCharCode(this.pindex++)}return this.palette[i]},this.getBase64=function(){var e,t,n,r,i,o,a,s=this.getDump(),l="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",c=s.length,u=0,d="";do{e=s.charCodeAt(u),r=e>>2,t=s.charCodeAt(u+1),i=(3&e)<<4|t>>4,n=s.charCodeAt(u+2),o=c<u+2?64:(15&t)<<2|n>>6,a=c<u+3?64:63&n,d+=l.charAt(r)+l.charAt(i)+l.charAt(o)+l.charAt(a)}while((u+=3)<c);return d},this.getDump=function(){for(var e=65521,n=5552,i=1,o=0,a=n,l=0;l<this.height;l++)for(var c=-1;c<this.width;c++)i+=this.buffer[this.index(c,l)].charCodeAt(0),o+=i,0==(a-=1)&&(i%=e,o%=e,a=n);function u(e,n,i){for(var o=-1,a=4;a<i-4;a+=1)o=s[255&(o^e[n+a].charCodeAt(0))]^o>>8&16777215;t(e,n+i-4,r(-1^o))}return i%=e,o%=e,t(this.buffer,this.idat_offs+this.idat_size-8,r(o<<16|i)),u(this.buffer,this.ihdr_offs,this.ihdr_size),u(this.buffer,this.plte_offs,this.plte_size),u(this.buffer,this.trns_offs,this.trns_size),u(this.buffer,this.idat_offs,this.idat_size),u(this.buffer,this.iend_offs,this.iend_size),"PNG\r\n\n"+this.buffer.join("")}};"undefined"!==typeof e.exports?e.exports=o:window.PNGlib=o})()},39318:function(e,t){
|
||
/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
||
t.read=function(e,t,n,r,i){var o,a,s=8*i-r-1,l=(1<<s)-1,c=l>>1,u=-7,d=n?i-1:0,h=n?-1:1,p=e[t+d];for(d+=h,o=p&(1<<-u)-1,p>>=-u,u+=s;u>0;o=256*o+e[t+d],d+=h,u-=8);for(a=o&(1<<-u)-1,o>>=-u,u+=r;u>0;a=256*a+e[t+d],d+=h,u-=8);if(0===o)o=1-c;else{if(o===l)return a?NaN:1/0*(p?-1:1);a+=Math.pow(2,r),o-=c}return(p?-1:1)*a*Math.pow(2,o-r)},t.write=function(e,t,n,r,i,o){var a,s,l,c=8*o-i-1,u=(1<<c)-1,d=u>>1,h=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,p=r?0:o-1,f=r?1:-1,m=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,a=u):(a=Math.floor(Math.log(t)/Math.LN2),t*(l=Math.pow(2,-a))<1&&(a--,l*=2),t+=a+d>=1?h/l:h*Math.pow(2,1-d),t*l>=2&&(a++,l/=2),a+d>=u?(s=0,a=u):a+d>=1?(s=(t*l-1)*Math.pow(2,i),a+=d):(s=t*Math.pow(2,d-1)*Math.pow(2,i),a=0));i>=8;e[n+p]=255&s,p+=f,s/=256,i-=8);for(a=a<<i|s,c+=i;c>0;e[n+p]=255&a,p+=f,a/=256,c-=8);e[n+p-f]|=128*m}},35615:function(e){"function"===typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){if(t){e.super_=t;var n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}}},55387:function(e,t,n){"use strict";var r=n(51913)(),i=n(14607),o=i("Object.prototype.toString"),a=function(e){return!(r&&e&&"object"===typeof e&&Symbol.toStringTag in e)&&"[object Arguments]"===o(e)},s=function(e){return!!a(e)||null!==e&&"object"===typeof e&&"length"in e&&"number"===typeof e.length&&e.length>=0&&"[object Array]"!==o(e)&&"callee"in e&&"[object Function]"===o(e.callee)},l=function(){return a(arguments)}();a.isLegacyArguments=s,e.exports=l?a:s},89617:function(e){"use strict";var t,n,r=Function.prototype.toString,i="object"===typeof Reflect&&null!==Reflect&&Reflect.apply;if("function"===typeof i&&"function"===typeof Object.defineProperty)try{t=Object.defineProperty({},"length",{get:function(){throw n}}),n={},i(function(){throw 42},null,t)}catch(y){y!==n&&(i=null)}else i=null;var o=/^\s*class\b/,a=function(e){try{var t=r.call(e);return o.test(t)}catch(n){return!1}},s=function(e){try{return!a(e)&&(r.call(e),!0)}catch(t){return!1}},l=Object.prototype.toString,c="[object Object]",u="[object Function]",d="[object GeneratorFunction]",h="[object HTMLAllCollection]",p="[object HTML document.all class]",f="[object HTMLCollection]",m="function"===typeof Symbol&&!!Symbol.toStringTag,g=!(0 in[,]),v=function(){return!1};if("object"===typeof document){var b=document.all;l.call(b)===l.call(document.all)&&(v=function(e){if((g||!e)&&("undefined"===typeof e||"object"===typeof e))try{var t=l.call(e);return(t===h||t===p||t===f||t===c)&&null==e("")}catch(n){}return!1})}e.exports=i?function(e){if(v(e))return!0;if(!e)return!1;if("function"!==typeof e&&"object"!==typeof e)return!1;try{i(e,null,t)}catch(r){if(r!==n)return!1}return!a(e)&&s(e)}:function(e){if(v(e))return!0;if(!e)return!1;if("function"!==typeof e&&"object"!==typeof e)return!1;if(m)return s(e);if(a(e))return!1;var t=l.call(e);return!(t!==u&&t!==d&&!/^\[object HTML/.test(t))&&s(e)}},2625:function(e,t,n){"use strict";var r=n(14607),i=n(46132),o=i(/^\s*(?:function)?\*/),a=n(51913)(),s=n(46369),l=r("Object.prototype.toString"),c=r("Function.prototype.toString"),u=n(14898);e.exports=function(e){if("function"!==typeof e)return!1;if(o(c(e)))return!0;if(!a){var t=l(e);return"[object GeneratorFunction]"===t}if(!s)return!1;var n=u();return n&&s(e)===n.prototype}},98006:function(e){"use strict";e.exports=function(e){return e!==e}},7838:function(e,t,n){"use strict";var r=n(28498),i=n(41857),o=n(98006),a=n(41591),s=n(61641),l=r(a(),Number);i(l,{getPolyfill:a,implementation:o,shim:s}),e.exports=l},41591:function(e,t,n){"use strict";var r=n(98006);e.exports=function(){return Number.isNaN&&Number.isNaN(NaN)&&!Number.isNaN("a")?Number.isNaN:r}},61641:function(e,t,n){"use strict";var r=n(41857),i=n(41591);e.exports=function(){var e=i();return r(Number,{isNaN:e},{isNaN:function(){return Number.isNaN!==e}}),e}},52672:function(e,t,n){"use strict";var r,i=n(14607),o=n(51913)(),a=n(78554),s=n(69336);if(o){var l=i("RegExp.prototype.exec"),c={},u=function(){throw c},d={toString:u,valueOf:u};"symbol"===typeof Symbol.toPrimitive&&(d[Symbol.toPrimitive]=u),r=function(e){if(!e||"object"!==typeof e)return!1;var t=s(e,"lastIndex"),n=t&&a(t,"value");if(!n)return!1;try{l(e,d)}catch(r){return r===c}}}else{var h=i("Object.prototype.toString"),p="[object RegExp]";r=function(e){return!(!e||"object"!==typeof e&&"function"!==typeof e)&&h(e)===p}}e.exports=r},95943:function(e,t,n){"use strict";var r=n(52730);e.exports=function(e){return!!r(e)}},49037:function(e){const t=[{wizard:{create:"Create",next:"Proceed",previous:"Back"},generic:{tip:"Tip",resourceExternalLinkTips:"External Link",namespace:"Namespace",notReady:"Not Ready",labels:"Labels",inProgress:"In Progress",basic:"Basic",loading:"Loading...",none:"None",duration:{infinite:"Infinite","1s":"1 second","5s":"5 seconds","10s":"10 seconds","30s":"30 seconds","1m":"1 minute","3m":"3 minutes","5m":"5 minutes"}},unsupported:{serverVersion:"Current version: <code>{serverVersion}</code>",description:"[[Harvester]] ui only supports [[Harvester]] cluster version greater or equal to 1.3.0.",learnMore:'Learn more about [[Harvester]] from the <a target="_blank" href="https://harvesterhci.io/" rel="noopener noreferrer nofollow">[[Harvester]] Web Site</a> or read the <a target="_blank" href="https://docs.harvesterhci.io/" rel="noopener noreferrer nofollow">[[Harvester]] Docs</a>'},nav:{group:{networks:"Networks",backupAndSnapshot:"Backup and Snapshots",hardwareDevices:"Hardware Devices",Monitoring:"Monitoring",Logging:"Logging","Monitoring and Logging":"Monitoring and Logging",vmimport:"Virtual Machine Imports",vmMigration:"Virtual Machine Migration",Configurations:"Configurations"}},resourceTable:{groupBy:{device:"Group by Device"}},validation:{arrayCountRequired:"At least {count} {key} {count, plural, =1 {is} other {are}} required, and {key} can not be empty."},members:{clusterMemebership:"Cluster Membership",projectMembership:"Project Membership"},asyncButton:{createAndStart:{action:"Create and Start"},restart:{action:"Save and Restart",success:"Restarted",waiting:"Restarting…"}},dialog:{confirmExecution:{title:"Are you sure?",andOthers:"{count, plural,\n=0 {}\n=1 { and <b>one other </b>}\nother { and <b>{count} other </b>}\n}",protip:"Tip: Hold the {alternateLabel} key while clicking action to bypass this confirmation",stop:{message:"Are you sure you want to stop the {type} {names}?"},pause:{message:"Are you sure you want to pause the {type} {names}?"},restart:{message:"Are you sure you want to restart the {type} {names}?"},softreboot:{message:"Are you sure you want to soft reboot the {type} {names}?"}},promptRemove:{title:"Delete {type}",warningMessage:"Deleting the selected {type} permanently removes all resources on {thisOrThese} {type}. This action is irreversible. Do you want to continue?",confirmName:"Type <b>{nameToMatch}</b> to delete the {type}:",protip:"Tip: Hold the {alternateLabel} key while clicking Delete to bypass the confirmation step."}},harvester:{branding:{primeLabel:"{vendor}",primeEmptyLabel:"",logos:{tip:"Upload a logo to replace the [[Harvester]] logo in the top-level navigation header. Image height should be 21 pixels with a max width of 200 pixels. Max file size is 20KB. Accepted formats: JPEG, PNG, SVG."},favicon:{tip:"Upload an icon to replace the [[Harvester]] favicon in the browser tab. Max file size is 20KB"}},productLabel:"[[Harvester]]",modal:{backup:{success:"Backup { backUpName } has been initiated.",addBackup:"Add Backup",fileSystemFreezeDeadline:{label:"File System Freeze Deadline"}},quota:{editVMQuota:"Edit VM Quota",editQuota:"Edit Quota",bannerMessage:"Set to empty string or 0 to remove total snapshot size quota."},restore:{success:"Restore { name } created successfully.",title:"Backup and Restore",selectBackup:"Select Backup",message:{backup:"Please select the backup that needs to be restored."}},createTemplate:{title:"Generate Template",name:"Name",description:"Description",message:{tip:"Please enter a template name!",success:"Template { templateName } created successfully.",failed:"Failed generated template!"}},schedule:{title:"Create Schedule",message:{tip:"Please enter a schedule name!",success:"Schedule { name } created successfully.",failed:"Failed create schedule!"}},cloneVM:{title:"Clone Virtual Machine",name:"New Virtual Machine Name",type:"Clone volume data",action:{create:"Create",clone:"Clone"},message:{tip:"Please enter a virtual machine name!",success:"Virtual machine { name } cloned successfully.",failed:"Failed clone virtual machine!"}},osImage:{title:"Delete Image",message:"Are you sure you want to delete the image { name } ?"},downloadImage:{title:"Download Image",banner:"This action takes a while depending on the image size ({ size }). Please be patient.",startMessage:"The download process will auto start once the conversion is complete.",download:"Download"},exportImage:{title:"Export to Image",name:"Name",namespace:"Namespace",message:{success:"Image { name } created successfully."}},storageMigration:{title:"Storage Migration",fields:{sourceVolume:{label:"Source Volume",placeholder:"Select a source volume"},targetVolume:{label:"Target Volume",placeholder:"Select a target volume"}}},dataMigration:{title:"Data Migration",fields:{targetVolumeName:{label:"Target Volume Name",placeholder:"Enter a target volume name"},targetStorageClassName:{label:"Target Storage Class",placeholder:"Select a storage class"}}},migration:{failedMessage:"Latest migration failed!",title:"Migration",vmMigrationTitle:"{count, plural, one {Migrating # VM} other {Migrating # VMs}}",selectedVMs:"The following virtual machine(s) will be migrated to the target node",unknownNode:"(unknown node)",alreadyOnTarget:"Already on Target",fields:{nodeName:{label:"Target Node",placeholder:"Choose Target Node"}}},ejectCDROM:{title:"Eject CD-ROM",warnTip:"Eject volume will restart the virtual machine.",operationTip:"Select the volume you want to delete:",delete:"Delete"},bundle:{title:"Generate a Support Bundle",titleDescription:"Collect system-related logs in [[Harvester]] to assist with troubleshooting and support.",tip:'Each field below specifies an aspect of the support bundle. For detailed explanations, please refer to the <a href="{doc}" target="_blank">documentation</a>.',url:"Issue URL",description:"Description",namespaces:{label:"Namespaces",tooltip:"Select additional namespaces to include in the support bundle.<br/>See docs support-bundle-namespaces for detail.",selectAll:"Select All",unselectAll:"Unselect All"},timeout:{label:"Timeout",tooltip:"Minutes allows for completion of the support bundle generation process.<br/>See docs support-bundle-timeout for detail."},expiration:{label:"Expiration",tooltip:"Minutes before deleting packaged but not downloaded support bundle.<br/>See docs support-bundle-expiration for detail."},nodeTimeout:{label:"Node Collection Timeout",tooltip:"Minutes allowed for collecting logs/configurations on nodes.<br/>See docs support-bundle-node-collection-timeout for detail."}},hotplugVolume:{success:"Volume { diskName } is mounted to the virtual machine { vm }.",title:"Add Volume"},hotplugNic:{success:"The settings have been saved, but the network interface {interfaceName} will be attached only after the virtual machine is migrated.",title:"Add Network Interface",vmNetwork:"Virtual Machine Network",macAddress:"MAC Address",macAddressTooltip:"If left blank, the MAC address will be automatically generated."},insertCdRomVolume:{success:"{ imageName } is inserted into device { deviceName }.",title:"Insert Image",image:"Image",actionLabel:"Insert Image"},cpuMemoryHotplug:{success:"CPU and Memory are updated to the virtual machine { vm }.",title:"Edit CPU and Memory",maxResourcesMessage:"You can increase the CPU to maximum { maxCpu }C and memory to maximum { maxMemory }."},snapshot:{title:"Take Snapshot",name:"Name",message:{success:"Take Snapshot { name } successfully."}},volumeClone:{title:"Clone Volume",name:"Name",message:{success:"New Volume { name } cloned successfully."}},restoreSnapshot:{title:"Restore Snapshot",name:"New Volume Name",success:"New Volume { name } restored successfully."},vmSnapshot:{title:"Take Virtual Machine Snapshot",name:"Name",success:"Take virtual machine Snapshot { name } successfully.",fileSystemFreezeDeadline:{label:"File System Freeze Deadline"}},restart:{title:"Restart Virtual Machine",tip:"Restart the virtual machine for configuration changes to take effect.",cancel:"Save"}},notification:{title:{succeed:"Succeed",info:"Info",warning:"Warning",error:"Error"},restartRequired:{title:"{count} {count, plural, =1 {Virtual Machine is} other {Virtual Machines are}} Pending Restart",message:"Please restart { vmNames } to apply updated configurations"}},action:{createVM:"Create Virtual Machine",start:"Start",restart:"Restart",softreboot:"Soft Reboot",stop:"Stop",pause:"Pause",deepClone:"Clone",shallowClone:"Clone Template",unpause:"Unpause",encryptImage:"Encrypt Image",decryptImage:"Decrypt Image",ejectCDROM:"Eject CD-ROM",editVMQuota:"Edit Virtual Machine Quota",launchFormTemplate:"Launch instance from template",modifyTemplate:"Modify template (Create new version)",setDefaultVersion:"Set default version",addTemplateVersion:"Add template version",backup:"Take Backup",createSchedule:"Create Schedule",restore:"Restore",restoreNewVM:"Restore New",resumeSchedule:"Resume",suspendSchedule:"Suspend",restoreExistingVM:"Replace Existing",migrate:"Migrate",vmMigrate:"Virtual Machine Migration",cpuAndMemoryHotplug:"Edit CPU and Memory",abortMigration:"Abort Migration",storageMigration:"Storage Migration",cancelStorageMigration:"Cancel Storage Migration",dataMigration:"Data Migration",createTemplate:"Generate Template",enableMaintenance:"Enable Maintenance Mode",disableMaintenance:"Disable Maintenance Mode",clearMaintenance:"Clear Maintenance Mode Error",enableCPUManager:"Enable CPU Manager",disableCPUManager:"Disable CPU Manager",cordon:"Cordon",uncordon:"Uncordon",addHotplugVolume:"Add Volume",addHotplugNic:"Hotplug Network Interface",exportImage:"Export Image",viewlogs:"View Logs",cancelExpand:"Cancel Expand",snapshot:"Take Snapshot",pvcClone:"Clone Volume",vmSnapshot:"Take Virtual Machine Snapshot",shutdown:"Shut Down",powerOn:"Power On",reboot:"Reboot",reconnect:"Reconnect",forceStop:"Force Stop"},formatters:{hardwareResourceGauge:{allocated:"Allocated",consumption:"{useful} of {total} {units} {suffix}",cores:"CPU",pods:"Pods",ram:"Memory",used:"Used",reserved:"Reserved",units:{cores:"{count, plural,\n=1 {core}\nother {cores}}"}},harvesterIpAddress:{customIpTooltip:"Custom IP (set via annotation)"}},tableHeaders:{hostNetworkConfig:{underlay:"Underlay",underlayTooltip:"Allow this interface to act as the underlay for VM overlay networks.",vlanID:"VLAN ID",mode:"Mode",clusterNetwork:"Cluster Network"},imageEncryption:"Encryption",size:"Size",virtualSize:"Virtual Size",progress:"Progress",message:"Message",phase:"Phase",attachedVM:"Attached Virtual Machine",cpuManager:"CPU<br>Manager",diskState:"Disk",routeConnectivityTooltip:"Connectivity between the VM network and the management network, which the [[Harvester]] nodes are connected to.",fingerprint:"Fingerprint",value:"Value",actions:"Actions",readyToUse:"Ready To Use",backupTarget:"Backup Target",targetVm:"Target Virtual Machine",cronExpression:"Cron Expression",retain:"Retain",scheduleType:"Type",configuredProfiles:"Configured Profiles",maxFailure:"Max Failure",sourceVm:"Source Virtual Machine",vmSchedule:"Virtual Machine Schedule",hostIp:"Host IP",vm:{ipAddress:"IP Address",node:"Node",defaultVersion:"Default Version"},network:{type:"Type",vlan:"VLAN ID"},snapshotTargetVolume:"Original Volume",volumeSnapshotCounts:"Snapshot Counts",networkState:"Network State",totalSnapshotQuota:"Total Snapshot Quota",storageClass:"Storage Class",restore:"Restore",vmImportSourceVm:"Source VM",vmImportSourceCluster:"Source Cluster",vmImportStatus:"Import Status",vmImportSourceVDatacenter:"Datacenter",vmImportSourceVEndpoint:"Endpoint",vmImportSourceVClusterStatus:"Cluster Status",vmImportSourceORegion:"Region",vmImportSourceOEndpoint:"Endpoint",vmImportSourceOClusterStatus:"Cluster Status",vmImportSourceOVAUrl:"URL",vmImportSourceOVAStatus:"Status",v4ip:"V4 IP",v6ip:"V6 IP",eipName:"EIP Name",vmMigrationProviderType:"Type",vmMigrationProviderUrl:"URL",vmMigrationMapSourceProvider:"Source Provider",vmMigrationMapDestProvider:"Destination Provider",vmMigrationPlanTargetNs:"Target Namespace",vmMigrationPlanVmCount:"VM Count",vmMigrationMigrationPlan:"Plan"},tab:{volume:"Volumes",network:"Networks",advanced:"Advanced Options",accessCredentials:"Access Credentials",pciDevices:"PCI Devices",vGpuDevices:"vGPU Devices",usbDevices:"USB Devices",vmScheduling:"Virtual Machine Scheduling",quotas:"Quotas",snapshots:"Snapshots",instanceLabel:"Instance Labels",annotations:"Annotations",filesystem:"Filesystem Volume"},fields:{version:"Version",name:"Name",type:"Type",image:"Image",size:"Size",volume:"Volume",network:"Network",model:"Model",macAddress:"MAC address",staticIp:"Static IP",port:"Port",protocol:"Protocol",remove:"Remove",PhysicalNic:"Physical NIC",cpu:"CPU",memory:"Memory",virtualName:"Virtual machine name",promiscuous:"Promiscuous",ipv4Address:"IPv4 address",filterLabels:"Filter labels",filterSchedule:"Filter schedule",storageClass:"Storage class",dockerImage:"Docker image"},pci:{available:"Available Devices",compatibleNodes:"Compatible Nodes",impossibleSelection:"There are no hosts with all of the selected devices.",howToUseDeviceInVMCreation:{prefix:"Use the table below to enable PCI passthrough on each device you want to use in this virtual machine. <br>For vGPU devices, please enable them on the",middle:"vGPU Devices",suffix:"page first."},howToUseDevice:{prefix:"Select the device in the table to enable PCI passthrough. <br>For vGPU devices, please enable them on the",middle:"vGPU Devices",suffix:"page."},deviceInTheSameHost:"You can only select devices on the same host.",showCompatibility:"Show device compatibility matrix",hideCompatibility:"Hide device compatibility matrix",claimError:"Error enabling passthrough on {name}",unclaimError:"Error disabling passthrough on {name}",cantUnclaim:"You cannot disable passthrough on a device claimed by another user.",detachWarning:{title:"Cannot Disable Passthrough",message:"Please detach the device from the VM and save it first before disabling passthrough."},enableGroup:"Enable Group",disableGroup:"Disable Group",labelRequired:"This rule should not be manually altered: it ensures that the PCI devices selected for this virtual machine are available on the virtual machine's host.",goSetting:{prefix:"The pcidevices-controller add-on is not enabled, click",middle:"here",suffix:"to enable the add-on to successfully manage your PCI devices."},noPCIPermission:"Please contact your system administrator to enable the PCI devices first.",enablePassthroughWarning:"Please be careful not to use host-owned PCI devices (e.g., management and VLAN NICs). Incorrect device allocation may cause damage to your cluster, including node failure.",disableResourcePooling:"Disable Resource Pooling",disableResourcePoolingDescription:"Assigns this device a unique resource name so it can be pinned to a specific VM, instead of sharing the pool with other identical devices."},devices:{matrixHostName:"Host Name",matrixDeviceClaimName:"Device Claim Name"},generic:{close:"Close",open:"Open",showMore:"Show More",hideMore:"Hide More",memory:"Memory",cpu:"CPU",storage:"Storage",noFileChosen:"No file chosen",noSchema:"Can not find the custom resource definition: {schema}."},validation:{custom:{tooLongName:'"Name" cannot be more than {max} characters.'},generic:{hasDelete:'{type} "{name}" has been deleted.',maxLength:'"{key}" cannot be more than {max} characters',tabError:"{prefix}: {message}",maximumSize:"Exceed maximum size {max}!",regex:'Invalid {lowerType} "{name}": {upperType} must match the regex "{regex}"'},vm:{name:"name is required!",memory:'"Memory" is required!',duplicatedName:'duplicate {type} name: "{name}"',network:{macFormat:"Invalid MAC address format.",upperType:"Network name",lowerType:"network name"},volume:{upperType:"Volume name",lowerType:"volume name"}},image:{ruleTip:"The URL you have entered ends in an extension that we do not support. We only accept image files that end in .img, .iso, .qcow, .qcow2, .raw.",ruleFileTip:"The file you have chosen ends in an extension that we do not support. We only accept image files that end in .img, .iso, .qcow, .qcow2, .raw."},hash:{sha512:"Invalid SHA512 checksum."},subnet:{excludeIps:"Exclude IPs cannot be empty. Please remove or fill in the exclude IPs.",aclEmptyError:"The fields in subnet access control list rule can not be empty."}},dashboard:{label:"Dashboard",header:"[[Harvester]] Cluster: {cluster}",hardwareResourceGauge:{cpu:"CPU",memory:"Memory",storage:"Storage",allocated:"Allocated"},sections:{events:{label:"Events"},vmMetrics:{label:"Virtual Machine Metrics"},healthSummary:{component:"Component",severity:"Severity",errorCount:"Errors",warningCount:"Warnings",expandAll:"Expand All",collapseAll:"Collapse All"},componentHealth:{label:"Components",errors:"{count, plural, =1 {1 error} other {# errors}}",component:"Component",check:"Check",severity:"Severity",message:"Message",affectedCount:"Affected Resources",noAffectedResources:"No affected resources",noIssues:"No issues detected",checksNotLoaded:"Unable to load the checks",showIgnored:"Show ignored ({counts})",ignoredChecks:"{count, plural, =1 {1 check} other {# checks}}",ignoredResources:"{count, plural, =1 {1 resource} other {# resources}}",loadFailed:{healthSummaries:"Unable to load the health summary: {error}",componentHealths:"Unable to load the checks: {error}",ignoreRules:"Unable to load the ignore rules: {error}"},ignore:{create:"Create Ignore Rule",view:"View Ignore Rule",edit:"Edit Ignore Rule",delete:"Delete Ignore Rule",ignored:"Ignored",plusIgnored:"+ {n} ignored",scope:"Scope",scopeResources:"Selected resources",scopeCheck:"Entire check",resources:"Resources",duration:"Ignore for",days7:"7 days",days30:"30 days",forever:"Forever",expiresOn:"Expires on {date}",expiredOn:"Expired on {date}",neverExpires:"Never expires",willExpireOn:"Will expire on {date}",willNeverExpire:"Will never expire",staysExpired:"This rule expired on {date} and stays expired unless you choose how long to ignore for.",reason:"Reason",reasonPlaceholder:"Why is it ignored? (optional)",created:"The ignore rule of {name} is created",updated:"The ignore rule of {name} is updated",attemptingToDelete:"You are attempting to delete the ignore rule of",reportedAgain:"What it ignores will be reported again."}}},version:"Version"},host:{console:"Console",label:"Hosts",inconsistentIP:"Host IP is inconsistent, current IP: { currentIP }, initial IP: { initIP }",noConsoleUrl:"Console URL not specified",promote:{none:" ",running:"Promoting",failed:"Promote failed",unknown:"Promote halted",promoteRestart:"Restarting",promoteSucceed:"Promote completed"},tabs:{network:"Network",overview:"Overview",basics:"Basics",instance:"Virtual Machines",monitor:"Monitor Data",storage:"Storage",labels:"Labels",ksmtuned:"Ksmtuned",hugepages:"Hugepages",seeder:"Out-of-band Access"},detail:{kvm:{disableMessage:"Hardware-based virtualization is disabled or not supported. Hardware-based virtualization must be enabled before creating any virtual machines."},title:{network:"Network Configuration"},hostIP:"Host IP",role:"Role",os:"Operating System",create:"Creation Time",update:"Last Update Time",customName:"Custom Name",consoleUrl:"Console URL",more:"More Information",uuid:"UUID",containerRuntime:"Container Runtime",kernel:"Kernel",management:"Management Node",compute:"Compute Node",storage:"Storage",nic:"Physical NIC",notRecommended:"Not recommended",networkType:"Type",manufacturer:"Manufacturer",serialNumber:"Serial Number",model:"Model",etcd:"Witness Node",cpuManager:"CPU Manager"},enableMaintenance:{title:"Enable Maintenance Mode",protip:"The operation will migrate all virtual machines on this node to other nodes.",shutDownVMs:"Check <b>Force</b> option to shutdown virtual machines which cannot be migrated in live mode.",force:"Force"},cordon:{title:"Cordon",protip:"This operation will mark the node { node } as unschedulable."},ksmtuned:{run:"Run Strategy",configure:"Configure",mode:"Mode",modeLink:'Mode <a href="{url}" target="_blank"><i class="icon icon-info" /></a>',thresCoef:"Threshold Coefficient",enableMergeNodes:"Enable merging across nodes",enable:"Enable",disable:"Disable",ksmStatus:"KSM Status",modeOption:{standard:"Standard",high:"High-performance",customized:"Customized"},parameters:{title:"Ksmtuned Parameters",boost:"Boost",decay:"Decay",sleepMsec:"Sleep Time (Millisecond)",minPages:"Minimum Pages",maxPages:"Maximum Pages",description:{boost:"The number of scanned pages is incremented each time if the available memory is less than the threshold coefficient.",decay:"The number of scanned pages is decremented each time if the available memory is greater than the threshold coefficient.",sleepMsec:"The interval between two scans (the minimum value is 10ms), which is calculated by the formula (Sleep Milliseconds * 16 * 1024 * 1024/Total Memory).",minPages:"The minimum number of pages per scan, also the configuration for the first run.",maxPages:"Maximum number of pages per scan."}},statistics:{title:'Statistics <a href="https://www.kernel.org/doc/html/latest/admin-guide/mm/ksm.html#ksm-daemon-sysfs-interface" target="_blank"><i class="icon icon-info" /></a>',sharing:"Sharing",shared:"Shared",unshared:"Unshared",volatile:"Volatile",fullScans:"Full Scans",stableNodeChains:"Stable Node Chains",stableNodeDups:"Stable Node Dups"}},hugepages:{meminfo:"Meminfo",transparent:{title:'Transparent Hugepages <a href="{url}" target="_blank"><i class="icon icon-info" /></a>',enabled:"Enabled",shmemEnabled:"Shared Memory Enabled",defrag:"Defragmentation"},status:{anon:"Anonymous Hugepages (bytes)",size:"Default Hugepage Size (bytes)",total:"Total Hugepages",free:"Free Hugepages",rsvd:"Reserved Hugepages",surp:"Surplus Hugepages"}},disk:{add:"Add Disk",path:{label:"Path"},storageReserved:{label:"Storage Reserved"},allowScheduling:{label:"Scheduling",tooltip:"Disk {name} ({path}) scheduling is disabled"},evictionRequested:{label:"Eviction Requested"},forceFormatted:{label:"Force Formatted",toolTip:"Force formatted will clean up disk data, make sure you backup all available data to prevent data loss.",yes:"Yes (Ext4 File System)"},description:{label:"Description"},lastFormattedAt:{info:"The disk has already been force-formatted."},notification:{success:'Update host "{name}" storage configurations successfully.'},error:"Host has unready or unschedulable disks.",mounted:"Already Mounted",fileSystem:{info:"Current file system is {system}, You can format it manually.",formatting:"Disk is formatting, please wait."},tags:{label:"Disk Tags",addLabel:"Add Disk Tag"},conditions:"Conditions",storageAvailable:{label:"Storage Available"},storageScheduled:{label:"Storage Scheduled"},storageMaximum:{label:"Storage Maximum"},provisioner:"Provisioner",lvmVolumeGroup:{label:"Volume Group",create:"Create New..."},storage:{longhorn:{LonghornV1:{label:"Longhorn V1 (CSI)"},LonghornV2:{label:"Longhorn V2 (CSI)"}},lvm:{label:"LVM"}}},tags:{label:"Host Tags",addLabel:"Add Host Tag"},powerAction:{message:{success:"Perform host { name } { operation } successfully."}},ntp:{label:"NTP Server Addresses",tips:"You can configure multiple IPv4 addresses or host addresses.",placeholder:"e.g. IPv4",ntpSyncStatus:{isDisabled:"NTP is disabled. Please check the NTP service is active.",isUnsynced:"NTP is not synchronized with the NTP server {current}."}}},virtualMachine:{label:"Virtual Machines",osType:"OS Type",osTypeTooltip:"Selecting an image with an OS label on the Volumes tab may change the OS Type selection.",cpuModel:{label:"CPU Model",fetchError:"Failed to load CPU model configuration: {error}",optionLabel:"{modelName} ({count} {count, plural, one {node} other {nodes}})"},hotplug:{title:"Enable CPU and memory hotplug",tooltip:"The default maximum CPU and maximum memory are {hotPlugTimes} times based on CPU and memory.",restartVMMessage:"Restart action is required for the virtual machine configuration change to take effect"},hotUnplug:{actionLabel:"Detach",detachVolume:{title:"Are you sure that you want to detach volume {name}?",actionLabel:"Detach Volume",success:"Volume { name } is detached successfully."},ejectCdRomVolume:{title:"Are you sure that you want to eject image from device {name}?",actionLabel:"Eject Image",success:"Image from device { name } is ejected successfully."},detachNIC:{title:"Are you sure that you want to detach network interface {name}?",actionLabel:"Detach Network Interface",success:"The settings have been saved, but the network interface {name} will be detached only after the virtual machine is migrated."}},instance:{singleInstance:null,multipleInstance:null,single:{label:"Single Instance",nameLabel:"Name",host:{label:"Hostname",placeholder:"Default to the virtual machine name."}},multiple:{label:"Multiple Instance",nameNsDescription:"Name prefix for each instance",count:"Count",countTip:"Count should be between 1 and 10",nameLabel:"Name Prefix",host:{label:"Host Prefix Name",placeholder:"Default to the virtual machine name."}}},useTemplate:{label:"Use the virtual machine template:",template:{label:"Template"},version:{label:"Version"}},console:{novnc:"Open in WebVNC",serial:"Open in Serial Console"},promptRemove:{title:"Select the volume you want to delete:",deleteAll:"Delete All",tips:"Warn: The snapshots of the virtual machine will be deleted with virtual machine and the snapshots of volume will be deleted with volume."},restartTip:"{restart, select,\n true {Restart}\n other {Start}\n} the virtual machine now to take effect of the configuration changes.",runStrategy:"Run Strategy",maintenanceStrategy:{label:"Maintenance Strategy",options:{Migrate:"Migrate",ShutdownAndRestartAfterEnable:"Shutdown and Restart After Enable",ShutdownAndRestartAfterDisable:"Shutdown and Restart After Disable",Shutdown:"Shutdown"}},cpuPinning:{label:"Enable CPU Pinning",tooltip:"Enable CPU Pinning brings better performance and reduce latency for the virtual machine",restartVMMessage:"Changing the CPU Pinning setting requires a virtual machine reboot for the change to take effect",migrationMessage:"This virtual machine can only be migrated to a target node that has CPU Manager enabled, as CPU Pinning is configured.",cpuManager:{prefix:"You must enable CPU Manager for at least one node in",middle:"host page",suffix:"to enable CPU Pinning for VM"}},restartNow:"{restart, select,\n true {Restart}\n other {Start}\n} Now",createSSHKey:"Create a New...",genericLoginError:"Authentication failed. Please re-log in and try again.",installAgent:"Install guest agent",enableUsb:"Enable USB Tablet",systemOptions:{tpm:"Enable TPM",tpmPersistentState:"TPM Persistent State",efiEnabled:"Booting in EFI mode",efiPersistentState:"EFI Persistent State",secureBoot:"Secure Boot"},usbTip:"Provides an absolute pointer device which often helps with getting a consistent mouse cursor position in VNC.",sshTitle:"Add Public SSH Key",imageTip:"An external URL to the .iso, .img, .qcow2 or .raw that the virtual machine should be created from.",volume:{dragTip:"Drag and drop volumes, or use the volume's arrows, to change the boot order.",volumeTip:"The virtual machine only contains a CD-ROM volume. You may want to add additional disk volumes.",macTip:"MAC address as seen inside the guest system.",staticIpTip:"Static IP that will be stored to annotation static-ip.harvesterhci.io/{nic_name}.",volumeUpdate:"Set volume { name } successfully",type:"Type",size:"Size",edit:"Edit",bus:"Bus",readyToUse:"Ready To Use",bootOrder:"Boot Order",volume:"Volume",dockerImage:"Docker Image",addVolume:"Add Volume",addExistingVolume:"Add Existing Volume",addVmImage:"Add a Virtual Machine Image",addContainer:"Add Container",setFirst:"Set as root volume",saveVolume:"Update Volume",encryption:"Encryption",performance:{profile:{label:"Storage Performance Profile",tip:'"High Performance" switches the disk to the virtio bus, disables the host cache, uses native AIO and gives the disk a dedicated I/O thread. Choose "Custom" to set each option yourself.',default:"Default",highPerformance:"High Performance",custom:"Custom"},highProfileTip:"This disk will use the virtio bus, no host cache, native AIO and a dedicated I/O thread.",cacheMode:{label:"Cache Mode",tip:'How the host caches disk I/O. "None" is best for high-throughput guests on block storage, "WriteBack" favors performance and "WriteThrough" favors durability.',default:"Default (hypervisor)",none:"None (no host cache)",writeback:"WriteBack",writethrough:"WriteThrough",filesystemWarning:'"None" (O_DIRECT) requires storage that supports direct I/O. It is recommended only for Block volume mode; on Filesystem volumes the VM may fail to start.'},ioMode:{label:"I/O Mode",tip:'How QEMU submits I/O. "Native" (Linux AIO) has the lowest overhead and needs cache mode "None". "Threads" uses a host thread pool.',default:"Default (hypervisor)",native:"Native (AIO)",threads:"Threads",nativeRequiresNoCacheTip:"Native I/O mode needs the host cache disabled, so cache mode is set to None."},dedicatedIOThread:{label:"Dedicated I/O Thread",tip:"Give this disk its own I/O thread instead of sharing one. Useful for disks with heavy I/O."},busTip:"This disk uses the {bus} bus. A dedicated I/O thread needs the virtio bus."},diskPerformance:{title:"Storage Performance",description:"These options apply to all volumes of the virtual machine.",blockMultiQueue:{label:"Virtio Block Multi-Queue",tip:"Spread disk I/O over one queue per vCPU so that it is processed on multiple CPUs.",noVirtioTip:"Add at least one disk on the virtio bus to enable Block Multi-Queue."},ioThreadsPolicy:{label:"I/O Threads Policy",tip:'"Shared" uses one I/O thread for all disks. "Auto" spreads disks over a pool of threads. "Supplemental Pool" uses a fixed number of threads.',default:"Disabled (default)",shared:"Shared",auto:"Auto",supplementalPool:"Supplemental Pool",autoEnabledTip:"A volume asks for a dedicated I/O thread, so the Shared policy will be used."},ioThreadCount:{label:"I/O Thread Count",tip:"Number of I/O threads in the supplemental pool."}},shareable:{label:"Shareable",tip:"Allow multiple virtual machines to attach and write to this volume simultaneously.",warning:"Multiple virtual machines can write to this volume at the same time. The guest workloads must coordinate access to the shared block device, otherwise concurrent writes will corrupt the data. Workloads that fence through SCSI-3 Persistent Reservations (e.g. Windows Server Failover Clustering) also require persistent reservation support from the storage backend. Host cache and hypervisor disk locking are disabled, and backup or snapshot operations are rejected while the volume is shareable."},vmImageVolumeTip:"Disk size ({diskSize}) should greater than selected image virtual size ({imageVirtualSize})",lockTooltip:{all:"All volumes are encrypted.",partial:"Some volumes are encrypted."},title:{vmImage:"Image Volume",existingVolume:"Existing Volume",volume:"Volume",container:"Container"},unmount:{title:"Are you sure?",message:"Are you sure you want to unmount this volume?"},emptyImage:"No media"},network:{title:"Network",addNetwork:"Add Network",addPort:"Add Port",networkBoot:{label:"Enable network boot (PXE)",tip:"Adds this interface to the VM boot order so the guest firmware can boot from the network. Requires a DHCP/TFTP (PXE) server reachable on the selected network; the management network does not provide one.",order:"Network boot order",first:"Before volumes",last:"After volumes"}},cloudConfig:{title:"Cloud Configuration",createTemplateTitle:"Create {name}",createNew:"Create new...",cloudInit:{label:"Cloud Init",placeholder:"Select a template"},user:{label:"User Data Template",title:"User Data:",tip:"You can specify user data to configure an instance or run a configuration script during launch. If you launch more than one instance at a time, the user data is available to all the instances in that reservation. <a href='https://cloudinit.readthedocs.io/en/latest/topics/examples.html' target='_blank'>Learn more</a>",invalidYaml:"Invalid User Data YAML syntax"},network:{label:"Network Data Template",title:"Network Data:",tip:"The network-data configuration allows you to customize the instance's networking interfaces by assigning subnet configuration, virtual device creation (bonds, bridges, VLANs) routes and DNS configuration. <a href='https://cloudinit.readthedocs.io/en/latest/reference/network-config-format-v1.html' target='_blank'>Learn more</a>",invalidYaml:"Invalid Network Data YAML syntax"}},sysprep:{title:"Windows Unattended & Sysprep Configuration",description:"Configure Windows automated installation using autounattend.xml. The configuration will be stored in a Kubernetes Secret and mounted as a CD-ROM during installation. <a href='https://docs.microsoft.com/en-us/windows-hardware/manufacture/desktop/automate-windows-setup' target='_blank'>Learn more</a>",createNew:"Create new...",createNewTitle:"Create Windows Unattended & Sysprep Template",xmlContent:"autounattend.xml content",secret:{label:"Windows Unattended & Sysprep Template"},validation:{invalidXml:"Invalid XML syntax",invalidNamespace:"Invalid unattend.xml namespace. Expected 'urn:schemas-microsoft-com:unattend'"}},scheduling:{affinity:{anyNode:"Run virtual machine on any available node",schedulingRules:"Run virtual machine on node(s) matching scheduling rules",specificNode:"Run virtual machine on specific node - (Live migration is not supported)"},networkNotSupport:"Network not support schedule"},accessCredentials:{resetPwd:{label:"Add Basic Auth"},injectSSH:{label:"Add SSH Key",users:"Select Users",addUser:"Add User"},tips:"qemu-guest-agent must be installed to enable the accessing of credentials. The virtual machine needs to be restarted after credentials added. You need to be in the virtual machine to edit your password or remove an SSH-Key after deleting the credentials.",userTips:"The user to be added must already exist; otherwise, the credentials will not take effect.",duplicatedUser:"User already exists.",invalidUser:"Invalid Username."},input:{name:"Name",cpu:"CPU",maxCpu:"Maximum CPU",maxMemory:"Maximum Memory",memory:"Memory",image:"Image",sshKey:"SSHKey",sshKeyValue:"SSH-Key",MachineType:"Machine Type",username:"Username",password:"Password",reservedMemory:"Reserved Memory",customizeDisplayName:"Customize virtual machine display name",displayNamePlaceholder:"Virtual machine alias name",displayName:"Display Name"},filesystem:{description:"[[Harvester]] supports filesystem volumes for VM via virtiofs.",type:"Filesystem Type",volume:"Volume",resource:"Resource",add:"Add",mountBannerHint:"Please update the mount path (e.g. /mnt/appconfigfs) to your preferred location, then add the corresponding commands to the",mountBannerHintLink:"runcmd",mountBannerHintSuffix:"in Advanced tab User Data."},machineTypeTip:"Specify a processor architecture to emulate. To see a list of supported architectures, run: qemu-system-x86_64 -cpu ?",detail:{tabs:{overview:"Overview",details:"Details",environment:"Environment",events:"Events",migration:"Migration",console:"Console",networkInterfaces:"Network Interfaces",disks:"Disks",networks:"Networks",basics:"Basics",configurations:"Configurations",inventory:"Inventory",hostBasic:"Basic Attributes",instance:"Virtual Machines",monitor:"Monitor Data",keypairs:"SSH Keys",cloudConfig:"Cloud Configuration",metrics:"Virtual Machine Metrics"},details:{title:{vmDetails:"Virtual Machine Details",requirements:"Scheduling and resources requirements",services:"Services",users:"Logged in users"},name:"Name",totalSnapshotQuota:"Total Snapshot Quota",namespace:"Namespace",created:"Created",hostname:"Hostname",node:"Node",ipAddress:"IP Address",status:"Status",pod:"Pod",labels:"Labels",bootOrder:"Boot Order",annotations:"Annotations",CDROMs:"CD-ROMs",description:"Description",operatingSystem:"Operating System",template:"Template",kernelRelease:"Kernel Release",owner:"Owner",workloadProfile:"Workload Profile",nodeSelector:"Node Selector",flavor:"Flavor",tolerations:"Tolerations",dedicatedResources:"Dedicated Resources",down:"Virtual machine not running",affinityRules:"Affinity Rules",phase:"Phase",sourceNode:"Source Node",targetNode:"Target Node",started:"Started",ended:"Ended"},notAvailable:"Not available",GuestAgentNotInstalled:"Guest agent required",noOwner:"No Owner",events:{from:"Generated from",down:"No events in the past hour"},console:{down:"This virtual machine is down. Please start it to access its console.",shortcutKeys:"Shortcut Keys",customShortcutKeys:"Custom Shortcut Keys",management:"Management Shortcut Keys",record:{start:"Record",recording:"Recording",stop:"Stop Recording",tips:"Press the record button to capture your keyboard inputs.",send:"Send",preferredKeys:"Preferred Custom Shortcut Keys"},settings:{label:"Settings",viewMode:{label:"Display",scale:"Scale the display to fit the window",none:"Manual zoom"},zoom:"Zoom",viewOnly:"View only",quality:"JPEG quality",compression:"Compression level"},fullscreen:{enter:"Full Screen",exit:"Exit Full Screen"},ctrlAltDel:"Ctrl+Alt+Del",confirm:{ctrlAltDel:{title:"Send Ctrl+Alt+Del?",message:"Windows opens its sign-in or security screen. Most Linux systems restart the virtual machine.",button:"Send"},softReboot:{title:"Soft reboot this virtual machine?",message:"The guest operating system is asked to restart. Unsaved work inside the virtual machine is lost.",button:"Soft Reboot"}},takeOver:{label:"Take Over",title:"Take over this console?",confirm:"The other VNC session connected to this virtual machine will be disconnected."},failure:{inUse:"This console is in use",unavailable:"Unable to connect",dropped:"Disconnected",error:"Connection failed"},failureDetail:{inUse:"Another VNC session is connected to this virtual machine. Retry once it is released, or take over the console to disconnect the other session.",unavailable:"The console is not available. Check that the virtual machine is running, then retry.",dropped:"The console connection was closed. Another VNC session may have opened this console."},status:{connecting:"Connecting",connected:"Connected",connectedViewOnly:"Connected (view only)",disconnected:"Disconnected",failed:"Connection failed",reconnecting:"Reconnecting {retryTimes} of {maximumRetryTimes}",credentialsRequired:"This console requires credentials that the dashboard cannot provide.",inUse:"Another VNC session may be using this console. Retrying until it is released."}}},terminationGracePeriodSeconds:{label:"Termination Grace Period"},affinity:{addLabel:"Add Workload Selector",topologyKey:{placeholder:"topology.kubernetes.io/zone"},thisPodNamespace:"This virtual machine's namespace",matchExpressions:{inNamespaces:"Workloads in these namespaces"},namespaces:{label:"Namespaces"}},instanceLabels:{banner:"These labels are automatically synchronized to the virtual machine instance."},labels:{banner:"These key values are added as labels to the virtual machine."},annotations:{banner:"These key values are added as annotations to the virtual machine."}},volume:{label:"Volumes",tabs:{basics:"Basics",snapshots:"Snapshots",datasource:"Data Source",details:"Details",conditions:"Conditions"},size:"Size",volumeMode:"Volume Mode",accessModes:"Access Modes",createWithDataVolume:"Create with DataVolume",createWithDataVolumeTooltip:"Create Volume with Kubevirt/Containerized Data Importer way. It can fill accessMode/volumeMode automatically.",showAdvanced:"Show Advanced Options",hideAdvanced:"Hide Advanced Options",performance:{pvcTip:"These high-performance options are saved as defaults on the volume and applied when it is attached to a virtual machine as a disk."},source:"Source",kind:"Kind",sourceOptions:{new:"New",vmImage:"Virtual Machine Image"},image:"Image",frontend:"Frontend",blockdev:"Block Device",attachedNode:"Attached Node",endpoint:"Endpoint",diskTags:"Disk Tags",nodeTags:"Node Tags",lastBackup:"Last Backup",lastBackupAt:"Last Backup At",replicasNumber:"Replicas Number",promptRemove:{tips:"Warn: The volume's snapshots will be deleted with this volume."},externalLink:{tips:"Check volume details"},rebuildingMessage:"Rebuilding: {percentage}%",longhorn:{disableResize:"Longhorn V2 volumes cannot be resized."}},image:{label:"Images",tabs:{basics:"Basics"},url:"URL",size:"Size",isEncryption:"Encryption",encryptionSecret:"Encryption Secret",virtualSize:"Virtual Size",urlTip:'Supports the <code>raw</code> and <code>qcow2</code> image formats which are supported by <a href="https://www.qemu.org/docs/master/system/images.html#disk-image-file-formats" target="_blank">qemu</a>. Bootable ISO images can also be used and are treated like <code>raw</code> images.',fileName:"File Name",uploadFile:"Upload File",source:"Source Type",sourceType:{download:"URL",upload:"File",clone:"Clone",encrypt:"Encrypt",decrypt:"Decrypt"},sourceImage:"Source Image",cryptoOperation:"Crypto Operation",warning:{uploading:"{count, plural,\n=1 {1 image is uploading, please do not refresh or close the page.}\nother {{count} images are uploading, please do not refresh or close the page.}\n}",osUpgrade:{uploading:"{name} is uploading, please do not refresh or close the page."}},checksum:"Checksum",checksumTip:"Validate the image using the SHA512 checksum, if specified.",tooltip:{imported:"Created automatically by the vm-import-controller"},errors:{unsupportedBackend:"Unsupported backend type: {backend}"}},vmTemplate:{label:"Templates",tabs:{basics:"Basics"},nameNsDescription:{name:"Template Name"},tips:{notExistImage:{title:"Image {name} does not exist!",message:"Please select a new image."},notExistNode:{title:"Node {name} does not exist!",message:"Please select a new node."}}},upgradePage:{upgradeApp:"Upgrade Software",upgrade:"Upgrade",upgradeTip:"Please select the version you want to upgrade to",currentVersion:"CURRENT VERSION",versionLabel:"AVAILABLE COMPATIBLE VERSIONS",enableLogging:"Enable Logging",skipSingleReplicaDetachedVol:"Skip checking single-replica detached volumes",upgradeNode:"Upgrading Node",upgradeSysService:"Upgrading System Service",upgradeImage:"Download Upgrade Image",osUpgrade:"Cluster Upgrade",uploadNew:"Upload New Image",deleteHeader:"Please select an image to delete.",deleteExisting:"Delete Existing Image",selectExisting:"Select Existing Image",createRepository:"Creating Upgrade Repository",succeeded:"Succeeded",releaseTip:'Please read the upgrade documentation carefully. You can view details on the <a href="{url}" target="_blank">[[Harvester]] Release Notes</a>.',checkReady:"I have read and understood the upgrade instructions related to this [[Harvester]] version.",pending:"Pending",upload:{duplicatedFile:"The file you are trying to upload already exists."},repoInfo:{upgradeStatus:"Upgrade Status",os:"OS",kubernetes:"Kubernetes",monitoringChart:"Monitoring Chart",harvesterChart:"[[Harvester]] Chart",success:"Success",fail:"Fail",ongoing:"On-going",downloadLog:"Download Log",logStatus:"Log Download Status"},dismissMessage:"Dismiss it",upgradeAvailable:"Upgrade Available",upgradeUnavailable:"Upgrade Unavailable",upgradeInfo:{warning:"WARNING",doc:'Read the <a href="{url}" target="_blank">documentation</a> before starting the upgrade process. Ensure that you complete procedures that are relevant to your environment and the version you are upgrading to.',tip:"Unmet system requirements and incorrectly performed procedures may cause complete upgrade failure and other issues that require manual workarounds.",moreNotes:"For more details about the release notes, please visit -"}},schedule:{label:"Virtual Machine Schedules",createTitle:"Create Schedule",createButtonText:"Create Schedule",scheduleType:"Virtual Machine Schedule Type",cron:{label:"Cron Schedule",editButton:"Edit"},detail:{namespace:"Namespace",sourceVM:"Source Virtual Machine"},tabs:{basic:"Basic",backups:"Backups",snapshots:"Snapshots"},message:{noSetting:{suffix:"before creating a backup schedule"}},retain:{label:"Retain",count:"Count",tooltip:"Number of up-to-date VM backups to retain. Maximum to 250, minimum to 2."},maxFailure:{label:"Max Failure",count:"Count",tooltip:"Max number of consecutive failed backups that could be tolerated. If reach this threshold, [[Harvester]] controller will suspend the schedule job. This value should less than retain count"},virtualMachine:{title:"Virtual Machine Name",placeholder:"Select a virtual machine"},type:{snapshot:"Snapshot",backup:"Backup"}},backup:{label:"Virtual Machine Backups",createText:"Restore Backup",title:"Restore Virtual Machine",refreshInterval:{label:"Refresh Interval",tip:"The interval for the backup target to sync data to [[Harvester]] cluster. Set to 0 to disable refresh mechanism."},backupTargetTip:"The endpoint used to access the backupstore. NFS and S3 are supported.",message:{noSetting:{prefix:"You must configure the backup target",middle:"setting",suffix:"before creating a new backup."},errorTip:{prefix:"Backup target value in",middle:"setting",suffix:"is invalid, error: "},viewSetting:{prefix:"Click",middle:"here",suffix:"to view the backup configuration."},testConnect:{actionLabel:"Test connection",waitingLabel:"Testing connection...",successLabel:"Connection tested",successMessage:"[[Harvester]] can successfully connect to the endpoint {endpoint}"}},restore:{backup:"Backup",deletePreviousVolumes:"Delete Previous Volumes",createNew:"Create new",replaceExisting:"Replace existing",virtualMachineName:"Virtual Machine Name",keepMacAddress:"Keep MAC Address",haltAfterRestore:"Keep powered off after restore"},matchTarget:"The current backup target does not match the existing one.",progress:{details:"Volume details",tooltip:{starting:"Backup initiating",progress:"Backup in progress",complete:"Backup completed"}}},restore:{progress:{details:"Volume details",tooltip:{starting:"Restore initiating",progress:"Restore in progress",complete:"Restore completed"}}},subnet:{cidrBlock:{tooltip:"The subnet range in CIDR notation. Note that the CIDR blocks of different Subnets' within the same VPC cannot overlap.",label:"CIDR Block",placeholder:"e.g. 172.20.0.0/16"},protocol:{label:"Protocol"},provider:{tooltip:"Network provider for this Subnet. Must be one of the Virtual Machine Networks in OverlayNetwork type.",label:"Provider"},vpc:{label:"Virtual Private Cloud"},gateway:{label:"Gateway IP",placeholder:"e.g. 172.20.0.1"},vlan:{label:"VLAN",placeholder:"Select a VLAN"},dhcp:{label:"Dynamic Host Configuration Protocol (DHCP)",v4Options:"DHCPV4Options",v6Options:"DHCPV6Options",placeholder:"key1=value1, key2=value2",dhcpOptionBanner:'DHCP options is a key/value string concatenate with comma. For more detail, please refer to <a href="https://kubeovn.github.io/docs/v1.13.x/en/kubevirt/dhcp/" target="_blank">KubOVN document</a>',tooltip:"Enable DHCP server for this subnet. When enabled, VMs can automatically obtain IP addresses from this subnet."},externalConnectivity:{label:"NAT Outgoing",tooltip:"Enable NAT for VMs using this subnet to access external networks."},private:{label:"Private Subnet",tooltip:"Enable network isolation for this Subnet. When enabled, VMs can only communicate within this subnet, even if other subnets exist under the same VPC."},allowSubnet:{label:"Allow Subnets",tooltip:"You can specify certain subnets which can communicate with this subnet.",addSubnet:"Add Allow Subnet",placeholder:"e.g. 172.16.0.0/16"},excludeIPs:{tooltip:"The IP address list to reserve from automatic assignment. The gateway IP address is always excluded and will be automatically added to the list.",placeholder:"single IP or 192.168.0.100..192.168.0.200"},acl:{label:"Access Control List",tooltip:"The ACL to apply to this Subnet. Must be one of the ACLs in the same namespace.",action:{label:"Action",placeholder:"Please select an action"},direction:{label:"Direction",placeholder:"Please select a direction"},addRule:"Add Rule",priority:{label:"Priority",placeholder:"Please select a priority"},match:{label:"Match",placeholder:"e.g. ip4.dst == 10.10.0.2"},banner:'The supported field in ACL match can refer to <a href="https://kubeovn.github.io/docs/v1.14.x/en/guide/subnet/#subnet-acl" target="_blank">KubeOvn Subnet ACL document</a>'}},vpc:{viewTopology:"Topology",topology:{loading:"Loading topology...",empty:"No resources found",visibility:{vpc:"VPC",subnets:"Subnets",overlayNetworks:"Overlay Networks",vms:"VMs"},labels:{cidr:"CIDR",provider:"Provider",type:"Type",clusterNetwork:"Cluster Network",network:"Network",subnet:"Subnet",ip:"IP",mac:"MAC",peering:"Peering"}},noAddonEnabled:{prefix:"The kubeovn-operator add-on is not enabled, click",middle:"here",suffix:"to enable the add-on to successfully create VPC and subnet."},label:"Virtual Private Cloud",noChild:"There is no subnet defined in this Virtual Private Cloud.",createSubnet:"Create Subnet",staticRoutes:{label:"Static Routes",cidr:{label:"CIDR",placeholder:"e.g. 172.16.0.0/16"},nextHopIP:{tooltip:"The localConnectIP on the other end of the peering VPC.",label:"Next Hop IP",placeholder:"e.g. 169.254.0.2"}},vpcPeerings:{label:"VPC Peerings",localConnectIP:{tooltip:"The designated IP address in CIDR notation of the VPC peering endpoint. Note that both IP addresses (for the VPC and the other VPC) should belong to the same subnet range and should not conflict with the cidrBlock in any existing subnets.",label:"Local Connect IP",placeholder:"e.g. 169.254.0.1/16"},remoteVpc:{label:"Remote VPC"},infoBanner:'The static route destination CIDR must cover all subnets CIDR from remote VPC Peer. Read <a href="{url}" target="_blank">VPC Peering Configuration Examples</a> for more information.'}},natGateway:{label:"Gateways",internalTenantNetwork:{label:"Internal Tenant Network",placeholder:"Select a Virtual Machine Network"},vpc:{label:"VPC",placeholder:"Select a VPC"},subnet:{label:"Subnet",placeholder:"Select a subnet"},lanIp:{label:"LAN IP",placeholder:"Enter LAN IP"},externalSubnets:{label:"External Subnets",addLabel:"Add",placeholder:"Select a subnet"}},externalIP:{label:"External IPs",natGateway:{label:"VpcNatGateway",placeholder:"Select a VpcNatGateway"},externalSubnet:{label:"External Subnet",placeholder:"Select an external subnet"},v4ip:{label:"V4 IP",placeholder:"public ip from external subnet"}},snat:{label:"Source Rules",eip:{label:"EIP",placeholder:"Select an external IP"},internalCIDR:{label:"Internal CIDR",placeholder:"internal subnet CIDR"}},dnat:{label:"Destination Rules",eip:{label:"EIP",placeholder:"Select an external IP"},externalPort:{label:"External Port",placeholder:"port number"},internalIp:{label:"Internal IP",placeholder:"internal IP address"},internalPort:{label:"Internal Port",placeholder:"port number"},protocol:{label:"Protocol",placeholder:"Select protocol (tcp or udp)"}},providerNetwork:{label:"Provider Networks",defaultInterface:{label:"Default Interface",placeholder:"Select the interface the same as master interface of external overlay network"},customInterfaces:{label:"Custom Interfaces",addLabel:"Add Custom Interface",interface:{label:"Network Interface",placeholder:"e.g. eth2"},nodes:{label:"Nodes",addLabel:"Add Node",placeholder:"Select a node"}},excludedNodes:{label:"Excluded Nodes",addLabel:"Add Excluded Node",placeholder:"Select node to exclude from this provider network"}},vlanNetwork:{label:"VLANs"},vlan:{id:{label:"VLAN ID",placeholder:"e.g. 1-4094"},provider:{label:"Provider Network",placeholder:"Select a provider network"}},networkPolicy:{label:"Policies",banner:'The network policies must be used for VMs attached to overlay networks. Please read the <a href="{url}" target="_blank">[[Harvester]] documentation</a> on how network policies work.'},network:{label:"Virtual Machine Networks",tabs:{basics:"Basics",layer3Network:"Route",nic:"Network Interface Card"},clusterNetwork:{label:"Cluster Network",create:"Create a new cluster network",toolTip:"Define your custom cluster scope network name",createPlaceholder:"Input a new cluster network name",selectOrCreatePlaceholder:"Select or create a new cluster network",selectPlaceholder:"Select a cluster network"},layer3Network:{mode:{label:"Mode",auto:"Auto (DHCP)",manual:"Manual"},serverIPAddr:{label:"DHCP Server IP"},gateway:{label:"Gateway",placeholder:"e.g. 172.16.0.1"},cidr:{label:"CIDR",placeholder:"e.g. 172.16.0.1/24"}}},sshKey:{label:"SSH Keys",keypair:"SSH Key",tabs:{basics:"Basics"}},setting:{label:"Settings",tabs:{advanced:"Advanced",ui:"UI"},validation:{physicalNIC:"DefaultPhysicalNIC"},placeholder:{accessKeyId:"Specify your access key ID",secretAccessKey:"Specify your secret access key",cert:"Upload a self-signed SSL certificate"},noSearchMatch:"No settings match your search.",vlanChangeTip:"The newly modified default network interface only applies to newly added nodes, not existing ones.",defaultPhysicalNIC:"Default Network Interface",modifiedMessage:"Settings that have been customized from default settings are tagged with 'Modified'.",percentTip:"The value in parentheses represents the distribution percentage of the network interface on all hosts. If an interface less than 100% is selected, the user needs to manually specify the network interface on the host where the vlan network configuration fails.",message:{ca:{prefix:"Click",middle:"here",suffix:"to add a custom certificate."}},sslCertificates:{publicCertificate:"Public Certificate",privateKey:"Private Key",ca:"CA"},rancherCluster:{kubeConfig:"Rancher KubeConfig",removeUpstreamClusterWhenNamespaceIsDeleted:"Remove Upstream Cluster When Namespace Is Deleted"},clusterPodSecurityStandard:{whitelistedNamespaces:{label:"Whitelisted Namespaces"},privilegedNamespaces:{label:"Privileged Namespaces"},restrictedNamespaces:{label:"Restricted Namespaces"}},storageNetwork:{range:{placeholder:"e.g. 172.16.0.0/24",label:"IP Range",invalid:'"Range" is invalid.'},clusterNetwork:"Cluster Network",vlan:"VLAN ID",exclusiveVlan:"Exclusive VLAN",exclude:{label:"Exclude IPs",placeholder:"CIDR format, e.g. 172.16.0.10/32",invalid:'"Exclude list" is invalid.',addIp:"Add Exclude IP"},warning:"WARNING: <br/> Any change to storage-network requires shutting down all virtual machines before applying this setting. <br/> Users have to ensure the cluster network is configured and VLAN Configuration will cover all nodes and ensure the network connectivity is working and expected in all nodes.",tip:'Specify an IP range in the IPv4 CIDR format. <code>Number of IPs Required = Number of Nodes * 2 + Number of Disks * 2 + Number of Images to Download/Upload </code>. For more information about storage network settings, see the <a href="{url}" target="_blank">documentation</a>.'},rwxNetwork:{warning:"WARNING: <br/> Any change to rwx-network requires longhorn RWX volumes detached before applying this setting.<br/>Users have to ensure the cluster network is configured and VLAN Configuration will cover all nodes and ensure the network connectivity is working and expected in all nodes.",shareStorageNetwork:"Share Storage Network",dedicatedRwxNetwork:"Dedicated RWX Network",shareStorageNetworkWarning:"The rwx-network is governed by storage-network, and changes here won't take effect until share-storage-network is set to false."},vmForceDeletionPolicy:{period:"Period",vmMigrationTimeout:"VM Migration Timeout"},vmMigrationNetwork:{parseError:"Failed to parse existing configuration.",fetchError:"Failed to load required network resources: {error}. Please refresh the page or try again later.",clusterNetwork:"Cluster Network",vlan:"VLAN ID",range:{placeholder:"e.g. 172.16.0.0/24",label:"IP Range",invalid:'"Range" is invalid.'},exclude:{label:"Excluded IPs",placeholder:"e.g. 172.16.0.1/32",invalid:'"Exclude list" is invalid.',addButton:"Add Exclude IP"}},ratio:"Ratio",autoRotateRKE2Certs:{expiringInHours:"Expiring in"},httpProxy:{warning:'WARNING: <br/> If you configure "http-proxy" and "https-proxy", you must also put [[Harvester]] node's CIDR into "no-proxy", otherwise the [[Harvester]] cluster will be broken.'},supportBundleImage:{imagePullPolicy:"Pull Policy",repo:"Repository",tag:"Tag"},csiDriverConfig:{provisioner:"Provisioner",volumeSnapshotClassName:"Volume Snapshot Class Name",backupVolumeSnapshotClassName:"Backup Volume Snapshot Class Name"},csiOnlineExpandValidation:{provisioner:"Provisioner",value:"Value",invalidJsonFormat:"Configuration value is not a valid JSON format: {error}",failedToLoadDrivers:"Failed to load CSI drivers. Error: {error}"},containerdRegistry:{mirrors:{mirrors:"Mirrors",registryName:"Registry Name",endpoints:"Endpoints",rewrite:{rewrite:"Rewrite",addRewrite:"Add Rewrite"},addMirror:"Add Mirror"},configs:{configs:"Configurations",registryEDQNorIP:"Registry FDQN or IP",registryPlaceholder:"myregistry.local:5000",username:"Username",password:"Password",auth:"Auth",identityToken:"Identity Token",insecureSkipVerify:"InsecureSkipVerify",addConfig:"Add Configuration"}},upgrade:{unknownImageName:"Image name is not found.",imageUrl:"Please input a valid image URL.",chooseFile:"Please select to upload an image.",checksum:"Checksum",networkError:"Unable to upload the image. Resolve network issues that may have occurred and try again.",cancelUpload:"Cancelled the image upload.",uploadSuccess:"{name} uploaded successfully. Press Upgrade button to start the cluster upgrade process.",deleteImage:"Please select an image to delete.",deleteSuccess:"{name} deleted successfully.",imagePreloadStrategy:"Image Preload Strategy",nodeUpgradeOption:"Node Upgrade Option",restoreVM:"Restore VM",strategy:"Strategy",pauseNodes:"Pause Nodes",strategyType:"Strategy Type",concurrency:"Concurrency"},harvesterMonitoring:{label:"[[Harvester]] Monitoring",section:{prometheus:"Prometheus",prometheusNodeExporter:"Prometheus Node Exporter",grafana:"Grafana",alertmanager:"Alertmanager"},tips:{scrape:"Interval between consecutive scrapes",evaluation:"Interval between consecutive evaluations",retention:"How long to retain metrics",retentionSize:"Maximum size of metrics"}},clusterRegistrationUrl:{url:"URL",insecureSkipTLSVerify:"Insecure Skip TLS Verify",tip:{prefix:'[[Harvester]] secures cluster registration via TLS by default. If opt out "Insecure Skip TLS Verify", you must provide custom CA certificates using the',middle:"additional-ca",suffix:"setting."},message:"To completely unset the imported [[Harvester]] cluster, please also remove it on the Rancher Dashboard UI via the <code> Virtualization Management </code> page."},ntpServers:{isNotIPV4:"The address you entered is not IPv4 or host. Please enter a valid IPv4 address or a host address.",isDuplicate:"There are duplicate NTP server configurations."},instanceManagerResources:{parseError:"Failed to parse configuration: {error}",v1:"V1 Data Engine",v2:"V2 Data Engine"},kubevirtMigration:{parseError:"Failed to parse configuration: {error}",parallelMigrationsPerCluster:"Parallel Migrations Per Cluster",parallelOutboundMigrationsPerNode:"Parallel Outbound Migrations Per Node",bandwidthPerMigration:"Bandwidth Per Migration",bandwidthPerMigrationTooltip:"0 is KubeVirt default, representing unlimited bandwidth",completionTimeoutPerGiB:"Completion Timeout Per GiB",progressTimeout:"Progress Timeout",allowAutoConverge:"Allow Auto Converge",allowPostCopy:"Allow Post Copy",unsafeMigrationOverride:"Unsafe Migration Override",allowWorkloadDisruption:"Allow Workload Disruption",disableTLS:"Disable TLS",matchSELinuxLevelOnMigration:"Match SELinux Level On Migration"}},cloudTemplate:{label:"Cloud Configuration Templates",templateType:"Template Type",userData:"User Data",networkData:"Network Data"},support:{title:"[[Harvester]] Support",kubeconfig:{title:"Download KubeConfig",titleDescription:"Download kubeconfig for debugging."},internal:{rancher:{title:"Access Embedded Rancher UI",titleDescription:'You can only use the embedded Rancher UI for debugging and validation purposes. For more information about how [[Harvester]] integrates with Rancher, see the <a target="_blank" href="{url}" rel="noopener noreferrer nofollow">documentation</a>.'},longhorn:{title:"Access Embedded Longhorn UI",titleDescription:"We only support to use the embedded Longhorn UI for debugging and validation purpose."}},community:{learnMore:"Find out more about [[Harvester]] support",pricing:"Contact us for pricing"}},namespace:{label:"Namespaces"},projectNamespace:{label:"Projects/Namespaces"},vip:{namespace:{label:"Namespace"},cidr:{label:"CIDR/IP Range",invalid:'"CIDR/IP Range" is invalid.',toolTip:"We can apply multiple pools or ranges by separating them with commas. For example: 192.168.0.200/30,192.168.0.200/29 or 192.168.0.10-192.168.0.11"},add:{label:"Add IP Pools"}},sslParameters:{protocols:{label:"Protocols"},ciphers:{label:"Ciphers"}},monitoring:{configuration:{label:"Configuration"},alertmanagerConfig:{label:"Alertmanager Configurations",diabledMonitoringTips:{prefix:"Enable the",middle:"monitoring",suffix:"add-on first."},diabledAlertingTips:{prefix:"Enable",middle:"Alertmanager",suffix:"for configuration to take effect."},disabledAddon:{prefix:"The monitoring add-on is disabled, click",middle:"here",suffix:"to enable it."}}},logging:{configuration:{section:{fluentbit:"Fluentbit",fluentd:"Fluentd"}},clusterFlow:{label:"Cluster Flows"},clusterOutput:{label:"Cluster Outputs"},flow:{label:"Flows"},output:{label:"Outputs"},diabledTips:{prefix:"Enable",middle:"logging",suffix:"for configuration to take effect."}},snapshot:{totalSnapshotSize:"Total Snapshot Size",label:"Volume Snapshots",targetVolume:"Original Volume",size:"Size",image:"Image"},vmSnapshot:{label:"Virtual Machine Snapshots",createText:"Restore Snapshot",title:"Restore Virtual Machine",snapshot:"Snapshot"},storage:{label:"Storage",useDefault:"Use the default storage",volumeEncryption:"Volume Encryption",secret:"Secret",volumeExpansionCheckbox:"Enable Expansion",migratable:{label:"Migratable"},numberOfReplicas:{label:"Number Of Replicas"},staleReplicaTimeout:{label:"Stale Replica Timeout"},nodeSelector:{label:"Host Selector"},diskSelector:{label:"Disk Selector"},storageClass:{label:"Storage Class",longhorn:{v1:{label:"Longhorn V1 (CSI)"},v2:{label:"Longhorn V2 (CSI)"},versionTooltip:"Longhorn V2 is disabled for this node."},lvm:{label:"LVM"}},title:"Storage Classes",customize:{volumeBindingMode:{later:"Bind and provision a persistent volume once a virtual machine using the PersistentVolumeClaim is created"}},parameters:{numberOfReplicas:{label:"Number Of Replicas"},staleReplicaTimeout:{label:"Stale Replica Timeout"},diskSelector:{label:"Disk Selector","no-options":"No available tags, please add in the `Host > Storage` page"},nodeSelector:{label:"Node Selector","no-options":"No available tags, please add in the `Host > Storage` page"},migratable:{label:"Migratable"},lvmVolumeGroupType:{label:"Volume Group Type"},lvmVolumeGroup:{label:"Volume Group Name","no-options":"No available Volume Groups, please add in the `Host > Storage` page"},node:{label:"Node"}},allowedTopologies:{title:"Allowed Topologies",tooltip:"Allowed Topologies helps scheduling virtual machines on hosts which match all of below expressions."},internal:{label:"Internal Storage Class",cannotDeleteTooltip:"Internal storage class volumes cannot be deleted",cannotDeleteOrDefaultTooltip:"Internal storage classes cannot be deleted or set as default"},cdiSettings:{label:"CDI Settings",volumeModeAccessModes:{label:"Volume Mode / Access Modes",tooltip:"Specifies the default volume mode and access modes.",add:"Add",volumeMode:"Volume Mode",accessModes:{label:"Access Modes"}},volumeSnapshotClass:{label:"Volume Snapshot Class",tooltip:"Sets the Volume Snapshot Class name to be used when taking snapshots of PVCs under this StorageClass."},cloneStrategy:{label:"Clone Strategy",tooltip:"Defines the clone strategy to use for volumes created with this StorageClass.",copy:"Copy",snapshot:"Snapshot",csiClone:"CSI Clone"},fileSystemOverhead:{label:"File System Overhead",tooltip:"Specifies the percentage of filesystem overhead to consider when calculating PVC size.",placeholder:"e.g. 0.05 (up to 3 decimal places, between 0 and 1)"}}},vlanConfig:{title:"Network Configuration",createNetworkConfig:"Create Network Configuration",action:{migrate:"Migrate"},titles:{nodeSelector:"Node Selector",uplink:"Uplink",bondOptions:"Bond Options",attributes:"Attributes",host:"Selected Hosts"},scheduling:{affinity:{allNodes:"Select all nodes",specificNode:"Select specific node",schedulingRules:"Select node(s) matching rules"}},uplink:{nics:{label:"NIC",addLabel:"Add NIC",overlayWarning:"The NIC selected here must match the NIC provided in the provider network.",placeholder:"Select a NIC that is available on all the selected nodes",validate:{available:'NIC "{nic}" is not available on the selected nodes'}},linkAttributes:{mtu:{label:"MTU"}},bondOptions:{mode:{label:"Mode"},miimon:{label:"Miimon",tooltip:"Miimon specifies the MII link monitoring frequency in milliseconds. <Code>-1</Code> means to keep the original value."}}},nodeSelector:{matchingNodes:{matchesSome:'{matched, plural,\n =0 {Matches 0 of {total, number} Nodes.}\n =1 {Matches 1 of {total, number} Nodes: "{sample}"}\n other {Matches {matched, number} of {total, number} existing Nodes, including "{sample}"}\n}'}}},vlanStatus:{vlanConfig:{label:"Network Configuration",l2VlanMode:{access:"Access",trunk:"Trunk",label:"Mode"},vlanTrunk:{minId:"Minimum VLAN ID",maxId:"Maximum VLAN ID",add:"Add VLAN Trunk"}}},clusterNetwork:{title:"Cluster Network Configuration",create:{button:{label:"Create a Cluster Network"}},clusterNetwork:"There are no network configurations defined.",mgmt:"mgmt is a built-in cluster management network and does not support any additional network configurations.",notExist:'Cluster Network "{ clusterNetwork }" does not exist',notReady:'Cluster Network "{ clusterNetwork }" is not ready'},addons:{descriptions:{"harvester-system/vm-import-controller":"vm-import-controller is an add-on to help migrate virtual machine workloads from other source clusters to an existing [[Harvester]] cluster.","harvester-system/pcidevices-controller":"pcidevices-controller is an add-on to help discover PCI devices for nodes in your cluster and allow users to prepare devices for PCI Passthrough, for use with [[Harvester]] virtual machine and guest clusters.","cattle-logging-system/rancher-logging":"rancher-logging is an add-on to collect versatile logs, events, and audits from the [[Harvester]] cluster and route them to many kinds of servers based on flows.","harvester-system/rancher-vcluster":"rancher-vcluster deploys a virtual cluster (vcluster) with Rancher installed.","cattle-monitoring-system/rancher-monitoring":"rancher-monitoring is an add-on that collects [[Harvester]] cluster and virtual machine metrics and allows you to view the metrics on an embedded dashboard and send alert(s) to remote servers.","vm-import-controller":"vm-import-controller is an add-on to help migrate virtual machine workloads from other source clusters to an existing [[Harvester]] cluster.","pcidevices-controller":"pcidevices-controller is an add-on to help discover PCI devices for nodes in your cluster and allow users to prepare devices for PCI Passthrough, for use with [[Harvester]] virtual machines and guest clusters.","nvidia-driver-toolkit":"nvidia-driver-toolkit is an add-on to enable vGPU devices and assign them to [[Harvester]] virtual machines.","rancher-logging":"rancher-logging is an add-on to collect versatile logs, events, and audits from the [[Harvester]] cluster and route them to many kinds of servers based on flows.","rancher-monitoring":"rancher-monitoring is an add-on to collect [[Harvester]] cluster and virtual machine metrics, view them on the embedded dashboard, and send alert(s) to remote servers.","rancher-vcluster":"rancher-vcluster deploys a virtual cluster (vcluster) with Rancher installed.",k3k:"k3k is an add-on to deploy the k3k controller.","rancher-k3k":"rancher-k3k deploys a k3k virtual cluster with Rancher installed.","harvester-seeder":"harvester-seeder is an add-on that uses IPMI and Redfish to discover hardware information and perform out-of-band operations.","harvester-system/harvester-seeder":"harvester-seeder is an add-on that uses IPMI and Redfish to discover hardware information and perform out-of-band operations.","harvester-csi-driver-lvm":"harvester-csi-driver-lvm is an add-on allowing users to create PVC through the LVM with local devices.",descheduler:"The virtual machine auto balance optimizes workload scheduling by evicting pods that are not optimally placed according to administrator-defined policies."},vmMigration:{generic:{unknown:"Unknown",identifier:"Identifier",podNetwork:"Pod Network",ignored:"Ignored",usedBy:"Used by:",vlan:"VLAN {id}",vCpu:"{count} vCPU",memoryGb:"{value} GB",memoryTb:"{value} TB",elapsed:{hoursAndMinutes:"{hours} {hours, plural, one {hour} other {hours}} and {minutes} {minutes, plural, one {minute} other {minutes}}",hours:"{hours} {hours, plural, one {hour} other {hours}}",minutes:"{minutes} {minutes, plural, one {minute} other {minutes}}"}},errors:{failedLoadPlans:"Failed to load migration plans",failedLoadVms:"Failed to load virtual machines",failedRefreshVms:"Failed to refresh virtual machines",failedLoadProviders:"Failed to load providers",failedLoadProvider:"Failed to load provider: {error}",failedResolveDetails:"Failed to resolve network and datastore details",failedDecodeCredentials:"Failed to decode provider credentials",connectionFailed:"Connection failed",providerNotReady:"Provider not ready"},labels:{dashboard:"Migration Overview",provider:"Providers",networkMap:"Network Maps",storageMap:"Storage Maps",plan:"Migration Plans",migration:"Migrations"},providerWizard:{title:"Create Provider",editTitle:"Edit Provider"},wizard:{title:"VM Migration",steps:{configureProvider:{label:"Provider",description:"Configure Provider"},selectVms:{label:"VMs",description:"Select VMs"},configureMappings:{label:"Mappings",description:"Define Mappings"},reviewMigration:{label:"Migration Plan",description:"Review Migration Plan"}}},fields:{username:"Username",password:"Password"},configureProvider:{title:"Configure Provider",description:"Connect to your VMware vCenter or ESXi host to discover virtual machines for migration",connectionDetails:"Connection Details",providerSelect:"Provider",createNew:"Create new provider",requirementsTitle:"Requirements",requirementsText:"To migrate virtual machines from VMware, you will need a vCenter Server running version 6.5 or higher with a user account that has at least read permissions, and the source environment must be network-accessible from [[Harvester]] Node.",name:"Name",urlLabel:"vCenter/ESXi URL",urlPlaceholder:"https://vcenter.example.com/sdk",urlHint:"Enter the full URL including https://",vddkImageLabel:"VMware VDDK Image",vddkImagePlaceholder:"[your-private-registry]/vddk-image:latest",vddkImageTooltip:"Specify the VMware VDDK (Virtual Disk Development Kit) Image to accelerate and optimize VMware virtual machine migration.",skipSsl:"Skip SSL certificate verification",skipSslHint:"Not recommended for production environments",testConnection:{action:"Test Connection",success:"Connection successful",error:"Connection failed",waiting:"Testing connection..."},testSuccess:"Connection test passed",testFailed:"Connection test failed",testMissingFields:"Please fill in all required fields before testing",testTimeout:"Connection test timed out — the provider did not report a status in time",save:"Save Provider and Continue",saveExisting:"Check Provider and Continue"},selectVms:{title:"Select Virtual Machines",description:"Select the virtual machines you want to migrate from the source provider",discovered:"{count} VMs discovered from",lastSynced:"Last synced {time} ago • ",refreshNow:"Refresh now",availableVms:"Available Virtual Machines",selected:"selected",clearAll:"Clear All",saveSelection:"Save Selection and Continue",selectAllBanner:{pageOnly:"Your current selection includes only VMs currently shown on the page.",selectAll:"Select all {count} VMs from this provider",allSelected:"Your current selection includes all VMs.",clearSelection:"Clear Selection"},manualEntry:{title:"Add Virtual Machines",description:"No VMs were discovered from the provider inventory. Add VMs manually by entering their IDs and names.",vmId:"VM ID",vmIdPlaceholder:"e.g. vm-60527",add:"Add",added:"VMs added"},columns:{vmName:"VM Name",vmId:"VM ID",os:"Operating System",resources:"Resources",powerState:"Power State",network:"Network",datastore:"Datastore"}},dashboard:{title:"Virtual Machine Migration Overview",description:"Migrate virtual machines from VMware vSphere to [[Harvester]] using cold migration for data consistency. Create a migration plan to select VMs, map networks and storage, and prepare a migration to [[Harvester]].",createPlan:"Create Migration",tableTitle:"Migrations",columns:{status:"Status",plan:"Migration Plan",progress:"Progress",mappings:"Mappings",duration:"Duration"},progress:{failed:"Failed",migration:"Migration",initializingMigration:"Initializing migration",finishedSuccessfully:"Finished Successfully",step:"Step {index}",vmCount:"{count, plural, one {# VM} other {# VMs}}",vmId:"id: {id}",checkMigratedVm:"Click to check migrated VM details"}},configureMappings:{title:"Set Mappings",description:"Map VMware networks and datastores to [[Harvester]] and Longhorn target resources",save:"Save Mappings and Continue",noTemplate:"Start from scratch",removeMap:"Remove mapping",networkMapping:{title:"Network Mapping",description:"Map VMware port groups to [[Harvester]] networks",placeholder:"Choose a [[Harvester]] network",template:"Use existing network mapping as template",options:{podNetworking:"Management Network",ignored:"Ignored (No NIC will be created)"}},storageMapping:{title:"Storage Mapping",description:"Map VMware datastores to [[Harvester]] storage classes",placeholder:"Choose a [[Harvester]] Storage Class",template:"Use existing storage mapping as template"}},storageDefaults:{title:"Storage defaults — {name}",description:"Set the volume mode and access modes applied to every datastore in this storage map that maps to {name}.",descriptionInherited:"Applies to every datastore in this storage map that maps to {name}. The provider default for {provider} stays unchanged.",summary:"Volume mode: {volumeMode} · Access mode: {accessModes}",inherited:"Inherited from provider {provider}",volumeMode:"Volume Mode",accessMode:"Access Mode",edit:"Edit",cancel:"Cancel",apply:"Apply",resetToProviderDefault:"Reset to Provider Default",applyOverride:"Apply Override"},reviewMigration:{title:"Review Migration Plan",description:"Confirm your migration settings before starting the transfer of VMs to the target cluster.",planName:"Name",planNamePlaceholder:"e.g. my-migration-plan",planNameProviderConflict:"The name “{name}” is already used by an existing provider. Please input a different plan name.",planNamePlanConflict:"The name “{name}” is already used by an existing migration plan. Please input a different plan name.",migrationDetails:"Migration Details",migrationDetailsDescription:"Name this plan and choose the namespace where migrated VMs will be created.",totalVms:"Total VMs",vcpu:"vCPU",memory:"Memory",storage:"Storage",source:"Source",provider:"Provider",targetNamespace:"Namespace",targetNamespacePlaceholder:"Select target namespace",migrationMode:"Migration Mode",coldMigration:"Cold Migration",coldMigrationDescription:"All source VMs will be powered off during migration.",coldMigrationHint:"Plan a maintenance window and notify relevant stakeholders before starting.",virtualMachines:"Virtual Machines",editSelection:"Edit selection",noVmSelected:"No VMs selected. Return to ",noVmSelectedLink:"Step 2 to select virtual machines.",columns:{vmName:"VM Name",os:"Operating System",resources:"Resources",powerState:"Power State",networkMapping:"Network Mapping",storageMapping:"Storage Mapping",sourceTarget:"Source → Target"},actions:{menuLabel:"Actions",editMappings:"Edit Mappings",removeFromPlan:"Remove from Plan"},warningTitle:"Cold Migration Warning",warningMessage:"All source VMs will be powered off, and downtime will occur during migration. Plan your maintenance window accordingly and notify relevant stakeholders",startMigration:"Start Migration Plan"},plan:{states:{error:"Error",canceled:"Canceled",inProgress:"In Progress",active:"Succeeded"},actions:{start:"Start",restart:"Restart",stop:"Stop"}},deleteDialog:{warning:"Deleting this migration plan will also delete the following related resources"}},vmImport:{titles:{basic:"Basic",auth:"Authentication",pvc:"Volume",networking:"Network Mapping",advanced:"Advanced"},labels:{vmimport:"Virtual Machine Import",vmimportSourceVMWare:"Source VMWare",vmimportSourceOpenStack:"Source OpenStack",vmimportSourceOVA:"Source OVA"},fields:{sourceProvider:"Source Provider Type",sourceCluster:"Source Cluster",vmName:"VM Name",targetStorageClass:"Target Storage Class",sourceNetwork:"Source Network Name",destNetwork:"Destination Network",interfaceModel:"Interface Model",folder:"Folder",diskBus:"Default Disk Bus",defaultInterface:"Default Network Interface",skipPreflight:"Skip Preflight Checks",forcePowerOff:"Force Power Off Source VM",username:"Username",password:"Password",caCert:"CA Certificate (PEM)",selectSecret:"Select Secret",createSecret:"Create New Credentials",useSecret:"Use Existing Secret",none:"None (Public URL)"},placeholders:{selectCluster:"Select a cluster...",selectProviderFirst:"Select a provider type first",matchSource:"Must match the name in the source cluster",folderExample:"e.g. /Datacenters/DC1/vm",caCert:"-----BEGIN CERTIFICATE----- ..."},options:{useDefault:"Use Default"},actions:{addNetwork:"Add Network Mapping",remove:"Remove"},errors:{rfc1123:'Invalid format. Name must be lowercase, alphanumeric, and cannot contain spaces (e.g. "my-vm-1"). If your Source VM name does not match this, you must rename it on the Source cluster first.',networkMappingRequired:"Every Network Mapping row must have a Source and Destination selected."},openstack:{fields:{endpoint:"Identity Service Endpoint",region:"Region",projectName:"Project Name",domainName:"Domain Name",retryCount:"Upload Image Retry Count",retryDelay:"Upload Image Retry Delay"},placeholders:{endpoint:"e.g. https://devstack/identity",region:"e.g. RegionOne",projectName:"e.g. admin",domainName:"e.g. default",retryCount:"Default: 30",retryDelay:"Default: 10"}},vmware:{fields:{endpoint:"vCenter Endpoint",datacenter:"Datacenter"},placeholders:{endpoint:"e.g. https://vscim/sdk",datacenter:"e.g. DC0"},tooltips:{datacenter:"The exact name of the Datacenter object in vCenter"}},ova:{fields:{url:"URL",httpTimeout:"HTTP Timeout"},placeholders:{url:"e.g. https://download.example.com/images/my-vm.ova",httpTimeout:"Default: 600"}}},rancherVcluster:{accessRancher:"Access the Rancher Dashboard",hostname:"Hostname",rancherVersion:"Rancher Version",password:"Bootstrap Password"},rancherK3k:{accessRancher:"Access the Rancher Dashboard",hostname:"Hostname",version:"Rancher Version",password:"Bootstrap Password",passwordTooltip:"The initial password in Rancher for the first time login.",enable:{title:"Enable K3k"}},switchFailed:"{action} {name} failed!",nvidiaDriverToolkit:{titles:{basic:"Controller",image:"Image",driver:"Driver"},image:{tag:"Image Tag",repository:"Image Repository"},driver:{location:"Driver Location"},enable:{title:"Enable NVIDIA Driver Toolkit"},parsingSpecError:"The field 'spec.valuesContent' has invalid format."},usbController:{titles:{basic:"Basic"}}},loadBalancer:{label:"Load Balancers",tabs:{basic:"Basic",listeners:"Listeners",healthCheck:"Health Check",backendServer:"Backend Server Selector"},workloadType:{label:"Workload Type",options:{cluster:"Guest Kubernetes Cluster",vm:"Virtual Machine"}},ipam:{label:"IPAM",options:{dhcp:"DHCP",pool:"Pool"}},ipPool:{label:"IP Pool",options:{none:"Auto (Select IP Pool automatically)"}},listeners:{name:{label:"Name"},protocol:{label:"Protocol"},port:{label:"Port"},backendPort:{label:"Backend Port",placeholder:"e.g. 80"}},backendServerSelector:{matchingVMs:{matchesSome:'{matched, plural,\n =0 {Matches 0 of {total, number} virtual machines in the namespace where the load balancer is.}\n =1 {Matches 1 of {total, number} virtual machines in the namespace where the load balancer is: "{sample}"}\n other {Matches {matched, number} of {total, number} existing virtual machines in the namespace where the load balancer is, including "{sample}"}\n}'}},backendServers:{label:"Backend Servers"},healthCheck:{warning:{portInUse:"Warning, the Backend Port {port} is in use in Health Check settings. If you need to update the port, update the Health Check settings accordingly."}}},ipPool:{label:"IP Pools",network:{label:"Virtual Machine Network"},tabs:{range:"Range",scope:"Scope",selector:"Selector"},subnet:{label:"Subnet"},startIP:{label:"Start IP"},endIP:{label:"End IP"},gateway:{label:"Gateway"},namespace:{label:"Namespace"},project:{label:"Project"},guestCluster:{label:"Guest Kubernetes Cluster"},availableIP:{label:"Available IP Count"},scope:{label:"Scope",addLabel:"Add Scope"},priority:{label:"Priority"},cidr:{addLabel:"Add CIDR"},range:{addLabel:"Add Range"}},hostNetworkConfig:{label:"Host Networks",mode:{label:"Mode"},tabs:{mode:"Mode",nodeSelector:"Node Selector"},nodeSelector:{addButton:"Add Node Selector"},underlay:{label:"Underlay",tooltip:"Allow this interface to act as the underlay for VM overlay networks.",conflict:"`{name}` host network config already has underlay enabled. Only one underlay is allowed in the cluster.",noKubeovn:{prefix:"The kubeovn-operator add-on is not enabled. Click",middle:"here",suffix:"to enable the add-on for overlay networking."}},vlanID:{label:"VLAN ID"},ipRange:{label:"IP Range ({node})",placeholder:"e.g. 192.168.1.10/24"},ips:{nodeLabel:"Node",label:"IP",placeholder:"e.g. 192.168.1.10/24"}},service:{healthCheckPort:{label:"Health Check Port"},healthCheckSuccessThreshold:{label:"Health Check Success Threshold",description:"If the number of times the probe continuously detects an address successfully reaches the success threshold, then the backend server can start to forward traffic."},healthCheckFailureThreshold:{label:"Health Check Failure Threshold",description:"The backend server will stop forwarding traffic if the number of health check failures reaches the failure threshold."},healthCheckPeriod:{label:"Health Check Period"},healthCheckTimeout:{label:"Health Check Timeout"},healthCheckEnabled:{label:"Health Check"}},secret:{label:"Secrets"},sriov:{label:"SR-IOV Network Devices",nodeName:"Node",numVFs:"Number Of Virtual Functions",vfAddresses:"Virtual Functions Addresses",showMore:"Show More",parentSriov:"Filter By Parent SR-IOV Netork Device",parentSriovGPU:"Filter By Parent SR-IOV GPU Device"},sriovgpu:{label:"SR-IOV GPU Devices",nodeName:"Node",numVFs:"Number of Virtual Functions",vfAddresses:"Virtual Functions Addresses",vGpuDevices:"vGPU Devices",showMore:"Show More",parentSriov:"Filter By Parent SR-IOV GPU",noPermission:"Please contact your system administrator to add [[Harvester]] add-ons first.",goSetting:{prefix:"The nvidia-driver-toolkit add-on is not enabled, click",middle:"here",suffix:"to enable it to manage your SR-IOV GPU devices."},enable:{title:"Enable SR-IOV GPU Device",skipMigConfiguration:"Use timesliced mode (skip MIG configuration)",note:"If unchecked, MIG mode will be attempted by default. If MIG mode is not supported or fails to initialize, it will fall back to timesliced mode. The actual mode depends on whether the GPU supports MIG."},timeslicedBadge:"timesliced mode",timesliced:"Timesliced"},migconfiguration:{label:"vGPU MIG Configurations",status:{outOfSync:"Out of Sync"},infoBanner:"To configure the MIG configuration, please disable it first and re-enable after editing the configuration.",profileSpec:"Profile Specs",profileStatus:"Profile Status",tableHeaders:{profileName:"Profile Name",total:"Total",vGPUID:"vGPU ID",available:"Available",requested:"Requested"},requested:"Requested",available:"Available",total:"Total",vGPUID:"vGPU ID",goSriovGPU:{prefix:"Please enable the supported GPU devices in",middle:"SR-IOV GPU Devices",suffix:"page to manage the vGPU MIG configurations."}},vgpu:{label:"vGPU Devices",noPermission:"Please contact system administrator to add [[Harvester]] add-ons first.",detachWarning:{title:"Cannot Disable vGPU",message:"Please detach the device from the VM and save it first before disabling this vGPU device."},goSetting:{prefix:"The nvidia-driver-toolkit add-on is not enabled, click",middle:"here",suffix:"to enable it to manage your vGPU devices."},enableGroup:"Enable Group",disableGroup:"Disable Group",enable:{title:"Select vGPU",type:"Type"},available:"Available Devices",compatibleNodes:"Compatible Nodes",impossibleSelection:"There are no hosts with all of the selected devices.",howToUseDevice:"Use the table below to enable vGPU devices you want to use in this virtual machine.",deviceInTheSameHost:"You can only select devices on the same host."},usb:{label:"USB Devices",noPermission:"Please contact system admin to add [[Harvester]] add-ons first",goSetting:{prefix:"The pcidevices-controller add-on is not enabled, click",middle:"here",suffix:"to enable it to manage your USB devices."},enableGroup:"Enable Group",disableGroup:"Disable Group",available:"Available USB Devices",compatibleNodes:"Compatible Nodes",impossibleSelection:"There are no hosts with all of the selected devices.",howToUseDevice:"Use the table below to enable USB passthrough on each device you want to use in this VM.",deviceInTheSameHost:"You can only select devices on the same host.",showCompatibility:"Show device compatibility matrix",hideCompatibility:"Hide device compatibility matrix",claimError:"Error enabling passthrough on {name}",unclaimError:"Error disabling passthrough on {name}",cantUnclaim:"You cannot disable passthrough on a device claimed by another user.",detachWarning:{title:"Cannot Disable Passthrough",message:"Please detach the device from the VM and save it first before disabling passthrough."},enablePassthroughWarning:"Please re-enable the USB device if the device path changes in the following situations:<br/> 1) Re-plugging the USB device.<br/> 2) Rebooting the node.<br/><br/>An incorrect device path may cause passthrough to fail.",classType:"Class Type"},harvesterVlanConfigMigrateDialog:{targetClusterNetwork:{label:"Target Cluster Network",placeholder:"Choose Target Cluster Network"}},seeder:{banner:{enable:{prefix:'The "harvester-seeder" add-on is disabled.',middle:"Click here",suffix:"to enable it."},noAccess:"Please contact your system administrator to enable the Out-of-Band Access first.",noAddon:'The "harvester-seeder" add-on does not exist, please check if it is installed.',noInventory:'Waiting for "inventories.metal.harvesterhci.io" to be ready.'},inventory:{host:{label:"Host",placeholder:"e.g. 172.16.1.1"},port:{label:"Port",placeholder:"e.g. 623"},insecureTLS:{label:"Insecure TLS"},secret:{label:"Secret",create:{title:"Add Secret"}},event:{label:"Event"},pollingInterval:{label:"Polling Interval"}}}},typeDescription:{harvester:"Branding allows administrators to globally re-brand the UI by customizing the [[Harvester]] product name, logos and color scheme."},advancedSettings:{tags:{modified:{label:"Modified"},experimental:{label:"Experimental",description:"Experimental: The feature is incomplete but its essential functionality is operational. The feature is not recommended for use in production environments."},preview:{label:"Technical Preview",description:"Technical Preview: The feature is almost complete and its functionality is not expected to change significantly. Explore the feature extensively before using in production environments."}},descriptions:{"harv-vlan":"Default Network Interface name of the VLAN network.","harv-backup-target":"Custom backup target to store virtual machine backups.",branding:"Branding allows administrators to globally re-brand the UI by customizing the [[Harvester]] product name, logos, and color scheme.","harv-csi-driver-config":"Configure additional information for CSI drivers.","harv-csi-online-expand-validation":"Allow online volume expansion for specific CSI drivers.","harv-containerd-registry":"Containerd Registry Configuration to connect private registries.","harv-log-level":"Configure [[Harvester]] server log level. Defaults to Info.","harv-server-version":"[[Harvester]] server version.","harv-server-flavor":"Indicates the [[Harvester]] edition: Prime or Community.","harv-upgrade-checker-enabled":"Specifies whether to enable [[Harvester]] upgrade check or not. Default is True.","harv-upgrade-checker-url":"Default [[Harvester]] upgrade check url. Only used when the <code>upgrade-checker-enabled</code> is equal to True.","harv-ui-source":"Configure how to load the UI source. The `External` option is used to load the UI from a ui-index URL, while the `Bundled` option loads the UI from the local [[Harvester]] server.","harv-ui-index":"HTML index location for the UI.","harv-cluster-registration-url":"Registration URL for multi-cluster management.","harv-http-proxy":"HTTP proxy for [[Harvester]] to access external services.","harv-additional-ca":"Custom CA root certificates for TLS validation.","harv-overcommit-config":"Resource overcommit configuration.","harv-support-bundle-timeout":"Support bundle timeout configuration in minutes, use 0 to disable the timeout.","harv-support-bundle-file-name":"Support bundle file name configuration.","harv-support-bundle-expiration":"Support bundle expiration configuration in minutes.","harv-support-bundle-node-collection-timeout":"Support bundle node collection timeout configuration in minutes.","harv-vm-force-reset-policy":"Configuration for the force-reset action when a virtual machine is stuck on a node that is down.","harv-ssl-parameters":"Custom SSL Parameters for TLS validation.","harv-storage-network":"Longhorn storage-network setting.","harv-rwx-network":"Configure RWX network behavior for shared or dedicated storage network usage.","harv-support-bundle-namespaces":"Select additional namespaces to include in the support bundle.","harv-auto-disk-provision-paths":"Specify the disks(using glob pattern) that [[Harvester]] will automatically add as virtual machine storage.","harv-support-bundle-image":'Support bundle image configuration. Find different versions in <a href="https://hub.docker.com/r/rancher/support-bundle-kit/tags" target="_blank">rancher/support-bundle-kit</a>.',"harv-release-download-url":"This setting allows you to configure the <code>upgrade release download</code> URL address. [[Harvester]] will get the ISO URL and checksum value from the (<code>$URL</code>/<code>$VERSION</code>/version.yaml) file hosted by the configured URL.","harv-default-vm-termination-grace-period-seconds":"Configure the virtual machine termination grace period for virtual machine stop.","harv-ntp-servers":"Configure NTP server. You can configure multiple IPv4 addresses or host addresses.","harv-auto-rotate-rke2-certs":"The certificate rotation mechanism relies on Rancher. [[Harvester]] will automatically update certificates generation to trigger rotation.","harv-kubeconfig-default-token-ttl-minutes":"TTL (in minutes) applied on [[Harvester]] administration kubeconfig files. Default is 0, which means to never expire.","harv-longhorn-v2-data-engine-enabled":'Enable the Longhorn V2 data engine. Default is false. <ul><li>Changing this setting will restart RKE2 on all nodes. This will not affect running VM workloads.</li><li>If you see "not enough hugepages-2Mi capacity" errors when enabling this setting, wait a minute for the error to clear. If the error remains, reboot the affected node.</li></ul>',"harv-longhorn-v2-data-engine-hugepage-enabled":"Enable hugepages when using the Longhorn V2 data engine. Default is true. Disabling hugepages reduces memory pressure on low-spec nodes and increases deployment flexibility. However, performance may be lower compared to running with hugepages.","harv-longhorn-v2-data-engine-memory-size":"Configure the amount of memory allocated to the SPDK target daemon when using the Longhorn V2 data engine. Default is 2048 MiB.","harv-additional-guest-memory-overhead-ratio":"The ratio for kubevirt to adjust the VM overhead memory. The value could be zero, empty value or floating number between 1.0 and 10.0, default to 1.5.","harv-upgrade-config":'Configure image preloading and VM restore options for upgrades. See related fields in <a href="{url}" target="_blank" rel="noopener">settings/upgrade-config</a>',"harv-vm-migration-network":"Segregated network for VM migration traffic.","harv-rancher-cluster":"Configure Rancher cluster integration settings for guest cluster management.","harv-max-hotplug-ratio":"The ratio for kubevirt to limit the maximum CPU and memory that can be hotplugged to a VM. The value could be an integer between 1 and 20, default to 4.","harv-kubevirt-migration":"Configure cluster-wide KubeVirt live migration parameters.","harv-instance-manager-resources":"Configure resource percentage reservations for Longhorn instance manager V1 and V2. Valid instance manager CPU range between 0 - 40.","harv-cluster-pod-security-standard":"Enforce Kubernetes Pod Security Standards (PSS) at the cluster level.","harv-maintenance-mode-drain-timeout":"Maintenance mode drain timeout in minutes. Use 0 to disable the timeout."}},typeLabel:{"kubevirt.io.virtualmachine":"{count, plural,\n one { Virtual Machine }\n other { Virtual Machines }\n}","harvesterhci.io.virtualmachineimage":"{count, plural,\n one { Image }\n other { Images }\n}","harvesterhci.io.keypair":"{count, plural,\n one { SSH Key }\n other { SSH Keys }\n}","harvesterhci.io.host":"{count, plural,\n one { Host }\n other { Hosts }\n}","harvesterhci.io.networkattachmentdefinition":"{count, plural,\n one { Virtual Machine Network }\n other { Virtual Machine Networks }\n}","harvesterhci.io.volume":"{count, plural,\n one { Volume }\n other { Volumes }\n}","harvesterhci.io.user":"{count, plural,\n one { User }\n other { Users }\n}","harvesterhci.io.setting":"{count, plural,\n one { Setting }\n other { Settings }\n}","harvesterhci.io.virtualmachinetemplateversion":"{count, plural,\n one { Template }\n other { Templates }\n}","harvesterhci.io.schedulevmbackup":"{count, plural,\n one { Virtual Machine Schedule }\n other { Virtual Machine Schedules }\n}","harvesterhci.io.virtualmachinebackup":"{count, plural,\n one { Virtual Machine Backup }\n other { Virtual Machine Backups }\n}","kubeovn.io.vpc":"{count, plural,\n one { Virtual Private Cloud }\n other { Virtual Private Clouds }\n}","kubeovn.io.vlan":"{count, plural,\n one { VLAN Network }\n other { VLAN Networks }\n}","kubeovn.io.providernetwork":"{count, plural,\n one { Provider Network }\n other { Provider Networks }\n}","kubeovn.io.vpcnatgateway":"{count, plural,\n one { NAT Gateway }\n other { NAT Gateways }\n}","kubeovn.io.iptablessnatrule":"{count, plural,\n one { Source Rule }\n other { Source Rules }\n}","kubeovn.io.iptablesdnatrule":"{count, plural,\n one { Destination Rule }\n other { Destination Rules }\n}","kubeovn.io.iptableseip":"{count, plural,\n one { External IP }\n other { External IPs }\n}","networking.k8s.io.networkpolicy":"{count, plural,\n one { Network Policy }\n other { Network Policies }\n}","harvesterhci.io.cloudtemplate":"{count, plural,\n one { Cloud Configuration Template }\n other { Cloud Configuration Templates }\n}","harvesterhci.io.volumesnapshot":"{count, plural,\n one { Volume Snapshot }\n other { Volume Snapshots }\n}","harvesterhci.io.vmsnapshot":"{count, plural,\n one { Virtual Machine Snapshot }\n other { Virtual Machine Snapshots }\n}","network.harvesterhci.io.vlanconfig":"{count, plural,\n one { Network Configuration }\n other { Network Configurations }\n}","harvesterhci.io.monitoring.alertmanagerconfig":"{count, plural,\n one { Alertmanager Configuration }\n other { Alertmanager Configurations }\n}","harvesterhci.io.logging.clusterflow":"{count, plural,\n one { Cluster Flow }\n other { Cluster Flows }\n}","harvesterhci.io.logging.clusteroutput":"{count, plural,\n one { Cluster Output }\n other { Cluster Outputs }\n}","harvesterhci.io.logging.flow":"{count, plural,\n one { Flow }\n other { Flows }\n}","harvesterhci.io.logging.output":"{count, plural,\n one { Output }\n other { Outputs }\n}","harvesterhci.io.storage":"{count, plural,\n one { Storage Class }\n other { Storage Classes }\n}","devices.harvesterhci.io.pcidevice":"{count, plural,\n one { PCI Device }\n other { PCI Devices }\n}","network.harvesterhci.io.clusternetwork":"{count, plural,\n one { Cluster Network }\n other { Cluster Networks }\n}","network.harvesterhci.io.hostnetworkconfig":"{count, plural,\n one { Host Network }\n other { Host Networks }\n}","harvesterhci.io.addon":"{count, plural,\n one { Add-on }\n other { Add-ons }\n}","devices.harvesterhci.io.sriovnetworkdevice":"{count, plural,\n one { SR-IOV Network Device }\n other { SR-IOV Network Devices }\n}","devices.harvesterhci.io.sriovgpudevice":"{count, plural,\n one { SR-IOV GPU Device }\n other { SR-IOV GPU Devices }\n}","devices.harvesterhci.io.vgpudevice":"{count, plural,\n one { vGPU Device }\n other { vGPU Devices }\n}","devices.harvesterhci.io.migconfiguration":"{count, plural,\n one { vGPU MIG Configuration }\n other { vGPU MIG Configurations }\n}","harvesterhci.io.secret":"{count, plural,\n one { Secret }\n other { Secrets }\n}","harvesterhci.io.blockdevice":"{count, plural,\n one { Disk }\n other { Disks }\n}","loadbalancer.harvesterhci.io.loadbalancer":"{count, plural,\n one { Load Balancer }\n other { Load Balancers }\n}","loadbalancer.harvesterhci.io.ippool":"{count, plural,\n one { IP Pool }\n other { IP Pools }\n}","migration.harvesterhci.io.openstacksource":"{count, plural,\n one { OpenStack Source }\n other { OpenStack Sources }\n}","migration.harvesterhci.io.vmwaresource":"{count, plural,\n one { VMware Source }\n other { VMware Sources }\n}","migration.harvesterhci.io.ovasource":"{count, plural,\n one { OVA Source }\n other { OVA Sources }\n}","migration.harvesterhci.io.virtualmachineimport":"{count, plural,\n one { Virtual Machine Import }\n other { Virtual Machine Imports }\n}","forklift.konveyor.io.provider":"{count, plural,\n one { Provider }\n other { Providers }\n}","forklift.konveyor.io.networkmap":"{count, plural,\n one { Network Map }\n other { Network Maps }\n}","forklift.konveyor.io.storagemap":"{count, plural,\n one { Storage Map }\n other { Storage Maps }\n}","forklift.konveyor.io.plan":"{count, plural,\n one { Migration Plan }\n other { Migration Plans }\n}","forklift.konveyor.io.migration":"{count, plural,\n one { Migration }\n other { Migrations }\n}"}}];e.exports=t.length<=1?t[0]:t},39198:function(e,t,n){var r=n(1048)["Buffer"],i={userAgent:!1},o={},a="11.1.1",s="jsrsasign(all) 11.1.1 (2026-02-21) (c) 2010-2023 Kenji Urushima | kjur.github.io/jsrsasign/license",l=l||function(e,t){var n={},r=n.lib={},i=r.Base=function(){function e(){}return{extend:function(t){e.prototype=this;var n=new e;return t&&n.mixIn(t),n.hasOwnProperty("init")||(n.init=function(){n.$super.init.apply(this,arguments)}),n.init.prototype=n,n.$super=this,n},create:function(){var e=this.extend();return e.init.apply(e,arguments),e},init:function(){},mixIn:function(e){for(var t in e)e.hasOwnProperty(t)&&(this[t]=e[t]);e.hasOwnProperty("toString")&&(this.toString=e.toString)},clone:function(){return this.init.prototype.extend(this)}}}(),o=r.WordArray=i.extend({init:function(e,n){e=this.words=e||[],this.sigBytes=n!=t?n:4*e.length},toString:function(e){return(e||s).stringify(this)},concat:function(e){var t=this.words,n=e.words,r=this.sigBytes,i=e.sigBytes;if(this.clamp(),r%4)for(var o=0;o<i;o++){var a=n[o>>>2]>>>24-o%4*8&255;t[r+o>>>2]|=a<<24-(r+o)%4*8}else for(o=0;o<i;o+=4)t[r+o>>>2]=n[o>>>2];return this.sigBytes+=i,this},clamp:function(){var t=this.words,n=this.sigBytes;t[n>>>2]&=4294967295<<32-n%4*8,t.length=e.ceil(n/4)},clone:function(){var e=i.clone.call(this);return e.words=this.words.slice(0),e},random:function(t){for(var n=[],r=0;r<t;r+=4)n.push(4294967296*e.random()|0);return new o.init(n,t)}}),a=n.enc={},s=a.Hex={stringify:function(e){for(var t=e.words,n=e.sigBytes,r=[],i=0;i<n;i++){var o=t[i>>>2]>>>24-i%4*8&255;r.push((o>>>4).toString(16)),r.push((15&o).toString(16))}return r.join("")},parse:function(e){for(var t=e.length,n=[],r=0;r<t;r+=2)n[r>>>3]|=parseInt(e.substr(r,2),16)<<24-r%8*4;return new o.init(n,t/2)}},l=a.Latin1={stringify:function(e){for(var t=e.words,n=e.sigBytes,r=[],i=0;i<n;i++){var o=t[i>>>2]>>>24-i%4*8&255;r.push(String.fromCharCode(o))}return r.join("")},parse:function(e){for(var t=e.length,n=[],r=0;r<t;r++)n[r>>>2]|=(255&e.charCodeAt(r))<<24-r%4*8;return new o.init(n,t)}},c=a.Utf8={stringify:function(e){try{return decodeURIComponent(escape(l.stringify(e)))}catch(t){throw new Error("Malformed UTF-8 data")}},parse:function(e){return l.parse(unescape(encodeURIComponent(e)))}},u=r.BufferedBlockAlgorithm=i.extend({reset:function(){this._data=new o.init,this._nDataBytes=0},_append:function(e){"string"==typeof e&&(e=c.parse(e)),this._data.concat(e),this._nDataBytes+=e.sigBytes},_process:function(t){var n=this._data,r=n.words,i=n.sigBytes,a=this.blockSize,s=4*a,l=i/s;l=t?e.ceil(l):e.max((0|l)-this._minBufferSize,0);var c=l*a,u=e.min(4*c,i);if(c){for(var d=0;d<c;d+=a)this._doProcessBlock(r,d);var h=r.splice(0,c);n.sigBytes-=u}return new o.init(h,u)},clone:function(){var e=i.clone.call(this);return e._data=this._data.clone(),e},_minBufferSize:0}),d=(r.Hasher=u.extend({cfg:i.extend(),init:function(e){this.cfg=this.cfg.extend(e),this.reset()},reset:function(){u.reset.call(this),this._doReset()},update:function(e){return this._append(e),this._process(),this},finalize:function(e){e&&this._append(e);var t=this._doFinalize();return t},blockSize:16,_createHelper:function(e){return function(t,n){return new e.init(n).finalize(t)}},_createHmacHelper:function(e){return function(t,n){return new d.HMAC.init(e,n).finalize(t)}}}),n.algo={});return n}(Math);(function(e){var t=l,n=t.lib,r=n.Base,i=n.WordArray;t=t.x64={};t.Word=r.extend({init:function(e,t){this.high=e,this.low=t}}),t.WordArray=r.extend({init:function(t,n){t=this.words=t||[],this.sigBytes=n!=e?n:8*t.length},toX32:function(){for(var e=this.words,t=e.length,n=[],r=0;r<t;r++){var o=e[r];n.push(o.high),n.push(o.low)}return i.create(n,this.sigBytes)},clone:function(){for(var e=r.clone.call(this),t=e.words=this.words.slice(0),n=t.length,i=0;i<n;i++)t[i]=t[i].clone();return e}})})(),l.lib.Cipher||function(e){var t=l,n=t.lib,r=n.Base,i=n.WordArray,o=n.BufferedBlockAlgorithm,a=t.enc.Base64,s=t.algo.EvpKDF,c=n.Cipher=o.extend({cfg:r.extend(),createEncryptor:function(e,t){return this.create(this._ENC_XFORM_MODE,e,t)},createDecryptor:function(e,t){return this.create(this._DEC_XFORM_MODE,e,t)},init:function(e,t,n){this.cfg=this.cfg.extend(n),this._xformMode=e,this._key=t,this.reset()},reset:function(){o.reset.call(this),this._doReset()},process:function(e){return this._append(e),this._process()},finalize:function(e){return e&&this._append(e),this._doFinalize()},keySize:4,ivSize:4,_ENC_XFORM_MODE:1,_DEC_XFORM_MODE:2,_createHelper:function(e){return{encrypt:function(t,n,r){return("string"==typeof n?m:f).encrypt(e,t,n,r)},decrypt:function(t,n,r){return("string"==typeof n?m:f).decrypt(e,t,n,r)}}}});n.StreamCipher=c.extend({_doFinalize:function(){return this._process(!0)},blockSize:1});var u=t.mode={},d=function(t,n,r){var i=this._iv;i?this._iv=e:i=this._prevBlock;for(var o=0;o<r;o++)t[n+o]^=i[o]},h=(n.BlockCipherMode=r.extend({createEncryptor:function(e,t){return this.Encryptor.create(e,t)},createDecryptor:function(e,t){return this.Decryptor.create(e,t)},init:function(e,t){this._cipher=e,this._iv=t}})).extend();h.Encryptor=h.extend({processBlock:function(e,t){var n=this._cipher,r=n.blockSize;d.call(this,e,t,r),n.encryptBlock(e,t),this._prevBlock=e.slice(t,t+r)}}),h.Decryptor=h.extend({processBlock:function(e,t){var n=this._cipher,r=n.blockSize,i=e.slice(t,t+r);n.decryptBlock(e,t),d.call(this,e,t,r),this._prevBlock=i}}),u=u.CBC=h,h=(t.pad={}).Pkcs7={pad:function(e,t){for(var n=4*t,r=(n=n-e.sigBytes%n,n<<24|n<<16|n<<8|n),o=[],a=0;a<n;a+=4)o.push(r);n=i.create(o,n),e.concat(n)},unpad:function(e){e.sigBytes-=255&e.words[e.sigBytes-1>>>2]}},n.BlockCipher=c.extend({cfg:c.cfg.extend({mode:u,padding:h}),reset:function(){c.reset.call(this);var e=this.cfg,t=e.iv;e=e.mode;if(this._xformMode==this._ENC_XFORM_MODE)var n=e.createEncryptor;else n=e.createDecryptor,this._minBufferSize=1;this._mode=n.call(e,this,t&&t.words)},_doProcessBlock:function(e,t){this._mode.processBlock(e,t)},_doFinalize:function(){var e=this.cfg.padding;if(this._xformMode==this._ENC_XFORM_MODE){e.pad(this._data,this.blockSize);var t=this._process(!0)}else t=this._process(!0),e.unpad(t);return t},blockSize:4});var p=n.CipherParams=r.extend({init:function(e){this.mixIn(e)},toString:function(e){return(e||this.formatter).stringify(this)}}),f=(u=(t.format={}).OpenSSL={stringify:function(e){var t=e.ciphertext;return e=e.salt,(e?i.create([1398893684,1701076831]).concat(e).concat(t):t).toString(a)},parse:function(e){e=a.parse(e);var t=e.words;if(1398893684==t[0]&&1701076831==t[1]){var n=i.create(t.slice(2,4));t.splice(0,4),e.sigBytes-=16}return p.create({ciphertext:e,salt:n})}},n.SerializableCipher=r.extend({cfg:r.extend({format:u}),encrypt:function(e,t,n,r){r=this.cfg.extend(r);var i=e.createEncryptor(n,r);return t=i.finalize(t),i=i.cfg,p.create({ciphertext:t,key:n,iv:i.iv,algorithm:e,mode:i.mode,padding:i.padding,blockSize:e.blockSize,formatter:r.format})},decrypt:function(e,t,n,r){return r=this.cfg.extend(r),t=this._parse(t,r.format),e.createDecryptor(n,r).finalize(t.ciphertext)},_parse:function(e,t){return"string"==typeof e?t.parse(e,this):e}})),m=(t=(t.kdf={}).OpenSSL={execute:function(e,t,n,r){return r||(r=i.random(8)),e=s.create({keySize:t+n}).compute(e,r),n=i.create(e.words.slice(t),4*n),e.sigBytes=4*t,p.create({key:e,iv:n,salt:r})}},n.PasswordBasedCipher=f.extend({cfg:f.cfg.extend({kdf:t}),encrypt:function(e,t,n,r){return r=this.cfg.extend(r),n=r.kdf.execute(n,e.keySize,e.ivSize),r.iv=n.iv,e=f.encrypt.call(this,e,t,n.key,r),e.mixIn(n),e},decrypt:function(e,t,n,r){return r=this.cfg.extend(r),t=this._parse(t,r.format),n=r.kdf.execute(n,e.keySize,e.ivSize,t.salt),r.iv=n.iv,f.decrypt.call(this,e,t,n.key,r)}}))}(),function(){for(var e=l,t=e.lib.BlockCipher,n=e.algo,r=[],i=[],o=[],a=[],s=[],c=[],u=[],d=[],h=[],p=[],f=[],m=0;256>m;m++)f[m]=128>m?m<<1:m<<1^283;var g=0,v=0;for(m=0;256>m;m++){var b=v^v<<1^v<<2^v<<3^v<<4;b=b>>>8^255&b^99;r[g]=b,i[b]=g;var y=f[g],w=f[y],O=f[w],S=257*f[b]^16843008*b;o[g]=S<<24|S>>>8,a[g]=S<<16|S>>>16,s[g]=S<<8|S>>>24,c[g]=S,S=16843009*O^65537*w^257*y^16843008*g,u[b]=S<<24|S>>>8,d[b]=S<<16|S>>>16,h[b]=S<<8|S>>>24,p[b]=S,g?(g=y^f[f[f[O^y]]],v^=f[f[v]]):g=v=1}var E=[0,1,2,4,8,16,32,64,128,27,54];n=n.AES=t.extend({_doReset:function(){for(var e=this._key,t=e.words,n=e.sigBytes/4,i=(e=4*((this._nRounds=n+6)+1),this._keySchedule=[]),o=0;o<e;o++)if(o<n)i[o]=t[o];else{var a=i[o-1];o%n?6<n&&4==o%n&&(a=r[a>>>24]<<24|r[a>>>16&255]<<16|r[a>>>8&255]<<8|r[255&a]):(a=a<<8|a>>>24,a=r[a>>>24]<<24|r[a>>>16&255]<<16|r[a>>>8&255]<<8|r[255&a],a^=E[o/n|0]<<24),i[o]=i[o-n]^a}for(t=this._invKeySchedule=[],n=0;n<e;n++)o=e-n,a=n%4?i[o]:i[o-4],t[n]=4>n||4>=o?a:u[r[a>>>24]]^d[r[a>>>16&255]]^h[r[a>>>8&255]]^p[r[255&a]]},encryptBlock:function(e,t){this._doCryptBlock(e,t,this._keySchedule,o,a,s,c,r)},decryptBlock:function(e,t){var n=e[t+1];e[t+1]=e[t+3],e[t+3]=n,this._doCryptBlock(e,t,this._invKeySchedule,u,d,h,p,i),n=e[t+1],e[t+1]=e[t+3],e[t+3]=n},_doCryptBlock:function(e,t,n,r,i,o,a,s){for(var l=this._nRounds,c=e[t]^n[0],u=e[t+1]^n[1],d=e[t+2]^n[2],h=e[t+3]^n[3],p=4,f=1;f<l;f++){var m=r[c>>>24]^i[u>>>16&255]^o[d>>>8&255]^a[255&h]^n[p++],g=r[u>>>24]^i[d>>>16&255]^o[h>>>8&255]^a[255&c]^n[p++],v=r[d>>>24]^i[h>>>16&255]^o[c>>>8&255]^a[255&u]^n[p++];h=r[h>>>24]^i[c>>>16&255]^o[u>>>8&255]^a[255&d]^n[p++],c=m,u=g,d=v}m=(s[c>>>24]<<24|s[u>>>16&255]<<16|s[d>>>8&255]<<8|s[255&h])^n[p++],g=(s[u>>>24]<<24|s[d>>>16&255]<<16|s[h>>>8&255]<<8|s[255&c])^n[p++],v=(s[d>>>24]<<24|s[h>>>16&255]<<16|s[c>>>8&255]<<8|s[255&u])^n[p++],h=(s[h>>>24]<<24|s[c>>>16&255]<<16|s[u>>>8&255]<<8|s[255&d])^n[p++],e[t]=m,e[t+1]=g,e[t+2]=v,e[t+3]=h},keySize:8});e.AES=t._createHelper(n)}(),function(){function e(e,t){var n=(this._lBlock>>>e^this._rBlock)&t;this._rBlock^=n,this._lBlock^=n<<e}function t(e,t){var n=(this._rBlock>>>e^this._lBlock)&t;this._lBlock^=n,this._rBlock^=n<<e}var n=l,r=n.lib,i=r.WordArray,o=(r=r.BlockCipher,n.algo),a=[57,49,41,33,25,17,9,1,58,50,42,34,26,18,10,2,59,51,43,35,27,19,11,3,60,52,44,36,63,55,47,39,31,23,15,7,62,54,46,38,30,22,14,6,61,53,45,37,29,21,13,5,28,20,12,4],s=[14,17,11,24,1,5,3,28,15,6,21,10,23,19,12,4,26,8,16,7,27,20,13,2,41,52,31,37,47,55,30,40,51,45,33,48,44,49,39,56,34,53,46,42,50,36,29,32],c=[1,2,4,6,8,10,12,14,15,17,19,21,23,25,27,28],u=[{0:8421888,268435456:32768,536870912:8421378,805306368:2,1073741824:512,1342177280:8421890,1610612736:8389122,1879048192:8388608,2147483648:514,2415919104:8389120,2684354560:33280,2952790016:8421376,3221225472:32770,3489660928:8388610,3758096384:0,4026531840:33282,134217728:0,402653184:8421890,671088640:33282,939524096:32768,1207959552:8421888,1476395008:512,1744830464:8421378,2013265920:2,2281701376:8389120,2550136832:33280,2818572288:8421376,3087007744:8389122,3355443200:8388610,3623878656:32770,3892314112:514,4160749568:8388608,1:32768,268435457:2,536870913:8421888,805306369:8388608,1073741825:8421378,1342177281:33280,1610612737:512,1879048193:8389122,2147483649:8421890,2415919105:8421376,2684354561:8388610,2952790017:33282,3221225473:514,3489660929:8389120,3758096385:32770,4026531841:0,134217729:8421890,402653185:8421376,671088641:8388608,939524097:512,1207959553:32768,1476395009:8388610,1744830465:2,2013265921:33282,2281701377:32770,2550136833:8389122,2818572289:514,3087007745:8421888,3355443201:8389120,3623878657:0,3892314113:33280,4160749569:8421378},{0:1074282512,16777216:16384,33554432:524288,50331648:1074266128,67108864:1073741840,83886080:1074282496,100663296:1073758208,117440512:16,134217728:540672,150994944:1073758224,167772160:1073741824,184549376:540688,201326592:524304,218103808:0,234881024:16400,251658240:1074266112,8388608:1073758208,25165824:540688,41943040:16,58720256:1073758224,75497472:1074282512,92274688:1073741824,109051904:524288,125829120:1074266128,142606336:524304,159383552:0,176160768:16384,192937984:1074266112,209715200:1073741840,226492416:540672,243269632:1074282496,260046848:16400,268435456:0,285212672:1074266128,301989888:1073758224,318767104:1074282496,335544320:1074266112,352321536:16,369098752:540688,385875968:16384,402653184:16400,419430400:524288,436207616:524304,452984832:1073741840,469762048:540672,486539264:1073758208,503316480:1073741824,520093696:1074282512,276824064:540688,293601280:524288,310378496:1074266112,327155712:16384,343932928:1073758208,360710144:1074282512,377487360:16,394264576:1073741824,411041792:1074282496,427819008:1073741840,444596224:1073758224,461373440:524304,478150656:0,494927872:16400,511705088:1074266128,528482304:540672},{0:260,1048576:0,2097152:67109120,3145728:65796,4194304:65540,5242880:67108868,6291456:67174660,7340032:67174400,8388608:67108864,9437184:67174656,10485760:65792,11534336:67174404,12582912:67109124,13631488:65536,14680064:4,15728640:256,524288:67174656,1572864:67174404,2621440:0,3670016:67109120,4718592:67108868,5767168:65536,6815744:65540,7864320:260,8912896:4,9961472:256,11010048:67174400,12058624:65796,13107200:65792,14155776:67109124,15204352:67174660,16252928:67108864,16777216:67174656,17825792:65540,18874368:65536,19922944:67109120,20971520:256,22020096:67174660,23068672:67108868,24117248:0,25165824:67109124,26214400:67108864,27262976:4,28311552:65792,29360128:67174400,30408704:260,31457280:65796,32505856:67174404,17301504:67108864,18350080:260,19398656:67174656,20447232:0,21495808:65540,22544384:67109120,23592960:256,24641536:67174404,25690112:65536,26738688:67174660,27787264:65796,28835840:67108868,29884416:67109124,30932992:67174400,31981568:4,33030144:65792},{0:2151682048,65536:2147487808,131072:4198464,196608:2151677952,262144:0,327680:4198400,393216:2147483712,458752:4194368,524288:2147483648,589824:4194304,655360:64,720896:2147487744,786432:2151678016,851968:4160,917504:4096,983040:2151682112,32768:2147487808,98304:64,163840:2151678016,229376:2147487744,294912:4198400,360448:2151682112,425984:0,491520:2151677952,557056:4096,622592:2151682048,688128:4194304,753664:4160,819200:2147483648,884736:4194368,950272:4198464,1015808:2147483712,1048576:4194368,1114112:4198400,1179648:2147483712,1245184:0,1310720:4160,1376256:2151678016,1441792:2151682048,1507328:2147487808,1572864:2151682112,1638400:2147483648,1703936:2151677952,1769472:4198464,1835008:2147487744,1900544:4194304,1966080:64,2031616:4096,1081344:2151677952,1146880:2151682112,1212416:0,1277952:4198400,1343488:4194368,1409024:2147483648,1474560:2147487808,1540096:64,1605632:2147483712,1671168:4096,1736704:2147487744,1802240:2151678016,1867776:4160,1933312:2151682048,1998848:4194304,2064384:4198464},{0:128,4096:17039360,8192:262144,12288:536870912,16384:537133184,20480:16777344,24576:553648256,28672:262272,32768:16777216,36864:537133056,40960:536871040,45056:553910400,49152:553910272,53248:0,57344:17039488,61440:553648128,2048:17039488,6144:553648256,10240:128,14336:17039360,18432:262144,22528:537133184,26624:553910272,30720:536870912,34816:537133056,38912:0,43008:553910400,47104:16777344,51200:536871040,55296:553648128,59392:16777216,63488:262272,65536:262144,69632:128,73728:536870912,77824:553648256,81920:16777344,86016:553910272,90112:537133184,94208:16777216,98304:553910400,102400:553648128,106496:17039360,110592:537133056,114688:262272,118784:536871040,122880:0,126976:17039488,67584:553648256,71680:16777216,75776:17039360,79872:537133184,83968:536870912,88064:17039488,92160:128,96256:553910272,100352:262272,104448:553910400,108544:0,112640:553648128,116736:16777344,120832:262144,124928:537133056,129024:536871040},{0:268435464,256:8192,512:270532608,768:270540808,1024:268443648,1280:2097152,1536:2097160,1792:268435456,2048:0,2304:268443656,2560:2105344,2816:8,3072:270532616,3328:2105352,3584:8200,3840:270540800,128:270532608,384:270540808,640:8,896:2097152,1152:2105352,1408:268435464,1664:268443648,1920:8200,2176:2097160,2432:8192,2688:268443656,2944:270532616,3200:0,3456:270540800,3712:2105344,3968:268435456,4096:268443648,4352:270532616,4608:270540808,4864:8200,5120:2097152,5376:268435456,5632:268435464,5888:2105344,6144:2105352,6400:0,6656:8,6912:270532608,7168:8192,7424:268443656,7680:270540800,7936:2097160,4224:8,4480:2105344,4736:2097152,4992:268435464,5248:268443648,5504:8200,5760:270540808,6016:270532608,6272:270540800,6528:270532616,6784:8192,7040:2105352,7296:2097160,7552:0,7808:268435456,8064:268443656},{0:1048576,16:33555457,32:1024,48:1049601,64:34604033,80:0,96:1,112:34603009,128:33555456,144:1048577,160:33554433,176:34604032,192:34603008,208:1025,224:1049600,240:33554432,8:34603009,24:0,40:33555457,56:34604032,72:1048576,88:33554433,104:33554432,120:1025,136:1049601,152:33555456,168:34603008,184:1048577,200:1024,216:34604033,232:1,248:1049600,256:33554432,272:1048576,288:33555457,304:34603009,320:1048577,336:33555456,352:34604032,368:1049601,384:1025,400:34604033,416:1049600,432:1,448:0,464:34603008,480:33554433,496:1024,264:1049600,280:33555457,296:34603009,312:1,328:33554432,344:1048576,360:1025,376:34604032,392:33554433,408:34603008,424:0,440:34604033,456:1049601,472:1024,488:33555456,504:1048577},{0:134219808,1:131072,2:134217728,3:32,4:131104,5:134350880,6:134350848,7:2048,8:134348800,9:134219776,10:133120,11:134348832,12:2080,13:0,14:134217760,15:133152,2147483648:2048,2147483649:134350880,2147483650:134219808,2147483651:134217728,2147483652:134348800,2147483653:133120,2147483654:133152,2147483655:32,2147483656:134217760,2147483657:2080,2147483658:131104,2147483659:134350848,2147483660:0,2147483661:134348832,2147483662:134219776,2147483663:131072,16:133152,17:134350848,18:32,19:2048,20:134219776,21:134217760,22:134348832,23:131072,24:0,25:131104,26:134348800,27:134219808,28:134350880,29:133120,30:2080,31:134217728,2147483664:131072,2147483665:2048,2147483666:134348832,2147483667:133152,2147483668:32,2147483669:134348800,2147483670:134217728,2147483671:134219808,2147483672:134350880,2147483673:134217760,2147483674:134219776,2147483675:0,2147483676:133120,2147483677:2080,2147483678:131104,2147483679:134350848}],d=[4160749569,528482304,33030144,2064384,129024,8064,504,2147483679],h=o.DES=r.extend({_doReset:function(){for(var e=this._key.words,t=[],n=0;56>n;n++){var r=a[n]-1;t[n]=e[r>>>5]>>>31-r%32&1}for(e=this._subKeys=[],r=0;16>r;r++){var i=e[r]=[],o=c[r];for(n=0;24>n;n++)i[n/6|0]|=t[(s[n]-1+o)%28]<<31-n%6,i[4+(n/6|0)]|=t[28+(s[n+24]-1+o)%28]<<31-n%6;for(i[0]=i[0]<<1|i[0]>>>31,n=1;7>n;n++)i[n]>>>=4*(n-1)+3;i[7]=i[7]<<5|i[7]>>>27}for(t=this._invSubKeys=[],n=0;16>n;n++)t[n]=e[15-n]},encryptBlock:function(e,t){this._doCryptBlock(e,t,this._subKeys)},decryptBlock:function(e,t){this._doCryptBlock(e,t,this._invSubKeys)},_doCryptBlock:function(n,r,i){this._lBlock=n[r],this._rBlock=n[r+1],e.call(this,4,252645135),e.call(this,16,65535),t.call(this,2,858993459),t.call(this,8,16711935),e.call(this,1,1431655765);for(var o=0;16>o;o++){for(var a=i[o],s=this._lBlock,l=this._rBlock,c=0,h=0;8>h;h++)c|=u[h][((l^a[h])&d[h])>>>0];this._lBlock=l,this._rBlock=s^c}i=this._lBlock,this._lBlock=this._rBlock,this._rBlock=i,e.call(this,1,1431655765),t.call(this,8,16711935),t.call(this,2,858993459),e.call(this,16,65535),e.call(this,4,252645135),n[r]=this._lBlock,n[r+1]=this._rBlock},keySize:2,ivSize:2,blockSize:2});n.DES=r._createHelper(h),o=o.TripleDES=r.extend({_doReset:function(){var e=this._key.words;this._des1=h.createEncryptor(i.create(e.slice(0,2))),this._des2=h.createEncryptor(i.create(e.slice(2,4))),this._des3=h.createEncryptor(i.create(e.slice(4,6)))},encryptBlock:function(e,t){this._des1.encryptBlock(e,t),this._des2.decryptBlock(e,t),this._des3.encryptBlock(e,t)},decryptBlock:function(e,t){this._des3.decryptBlock(e,t),this._des2.encryptBlock(e,t),this._des1.decryptBlock(e,t)},keySize:6,ivSize:2,blockSize:2}),n.TripleDES=r._createHelper(o)}(),function(){var e=l,t=e.lib.WordArray;e.enc.Base64={stringify:function(e){var t=e.words,n=e.sigBytes,r=this._map;e.clamp(),e=[];for(var i=0;i<n;i+=3)for(var o=(t[i>>>2]>>>24-i%4*8&255)<<16|(t[i+1>>>2]>>>24-(i+1)%4*8&255)<<8|t[i+2>>>2]>>>24-(i+2)%4*8&255,a=0;4>a&&i+.75*a<n;a++)e.push(r.charAt(o>>>6*(3-a)&63));if(t=r.charAt(64))for(;e.length%4;)e.push(t);return e.join("")},parse:function(e){var n=e.length,r=this._map,i=r.charAt(64);i&&(i=e.indexOf(i),-1!=i&&(n=i));i=[];for(var o=0,a=0;a<n;a++)if(a%4){var s=r.indexOf(e.charAt(a-1))<<a%4*2,l=r.indexOf(e.charAt(a))>>>6-a%4*2;i[o>>>2]|=(s|l)<<24-o%4*8,o++}return t.create(i,o)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="}}(),function(e){function t(e,t,n,r,i,o,a){return e=e+(t&n|~t&r)+i+a,(e<<o|e>>>32-o)+t}function n(e,t,n,r,i,o,a){return e=e+(t&r|n&~r)+i+a,(e<<o|e>>>32-o)+t}function r(e,t,n,r,i,o,a){return e=e+(t^n^r)+i+a,(e<<o|e>>>32-o)+t}function i(e,t,n,r,i,o,a){return e=e+(n^(t|~r))+i+a,(e<<o|e>>>32-o)+t}for(var o=l,a=o.lib,s=a.WordArray,c=a.Hasher,u=(a=o.algo,[]),d=0;64>d;d++)u[d]=4294967296*e.abs(e.sin(d+1))|0;a=a.MD5=c.extend({_doReset:function(){this._hash=new s.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(e,o){for(var a=0;16>a;a++){var s=o+a,l=e[s];e[s]=16711935&(l<<8|l>>>24)|4278255360&(l<<24|l>>>8)}a=this._hash.words,s=e[o+0],l=e[o+1];var c=e[o+2],d=e[o+3],h=e[o+4],p=e[o+5],f=e[o+6],m=e[o+7],g=e[o+8],v=e[o+9],b=e[o+10],y=e[o+11],w=e[o+12],O=e[o+13],S=e[o+14],E=e[o+15],x=a[0],_=a[1],k=a[2],C=a[3];x=t(x,_,k,C,s,7,u[0]),C=t(C,x,_,k,l,12,u[1]),k=t(k,C,x,_,c,17,u[2]),_=t(_,k,C,x,d,22,u[3]),x=t(x,_,k,C,h,7,u[4]),C=t(C,x,_,k,p,12,u[5]),k=t(k,C,x,_,f,17,u[6]),_=t(_,k,C,x,m,22,u[7]),x=t(x,_,k,C,g,7,u[8]),C=t(C,x,_,k,v,12,u[9]),k=t(k,C,x,_,b,17,u[10]),_=t(_,k,C,x,y,22,u[11]),x=t(x,_,k,C,w,7,u[12]),C=t(C,x,_,k,O,12,u[13]),k=t(k,C,x,_,S,17,u[14]),_=t(_,k,C,x,E,22,u[15]),x=n(x,_,k,C,l,5,u[16]),C=n(C,x,_,k,f,9,u[17]),k=n(k,C,x,_,y,14,u[18]),_=n(_,k,C,x,s,20,u[19]),x=n(x,_,k,C,p,5,u[20]),C=n(C,x,_,k,b,9,u[21]),k=n(k,C,x,_,E,14,u[22]),_=n(_,k,C,x,h,20,u[23]),x=n(x,_,k,C,v,5,u[24]),C=n(C,x,_,k,S,9,u[25]),k=n(k,C,x,_,d,14,u[26]),_=n(_,k,C,x,g,20,u[27]),x=n(x,_,k,C,O,5,u[28]),C=n(C,x,_,k,c,9,u[29]),k=n(k,C,x,_,m,14,u[30]),_=n(_,k,C,x,w,20,u[31]),x=r(x,_,k,C,p,4,u[32]),C=r(C,x,_,k,g,11,u[33]),k=r(k,C,x,_,y,16,u[34]),_=r(_,k,C,x,S,23,u[35]),x=r(x,_,k,C,l,4,u[36]),C=r(C,x,_,k,h,11,u[37]),k=r(k,C,x,_,m,16,u[38]),_=r(_,k,C,x,b,23,u[39]),x=r(x,_,k,C,O,4,u[40]),C=r(C,x,_,k,s,11,u[41]),k=r(k,C,x,_,d,16,u[42]),_=r(_,k,C,x,f,23,u[43]),x=r(x,_,k,C,v,4,u[44]),C=r(C,x,_,k,w,11,u[45]),k=r(k,C,x,_,E,16,u[46]),_=r(_,k,C,x,c,23,u[47]),x=i(x,_,k,C,s,6,u[48]),C=i(C,x,_,k,m,10,u[49]),k=i(k,C,x,_,S,15,u[50]),_=i(_,k,C,x,p,21,u[51]),x=i(x,_,k,C,w,6,u[52]),C=i(C,x,_,k,d,10,u[53]),k=i(k,C,x,_,b,15,u[54]),_=i(_,k,C,x,l,21,u[55]),x=i(x,_,k,C,g,6,u[56]),C=i(C,x,_,k,E,10,u[57]),k=i(k,C,x,_,f,15,u[58]),_=i(_,k,C,x,O,21,u[59]),x=i(x,_,k,C,h,6,u[60]),C=i(C,x,_,k,y,10,u[61]),k=i(k,C,x,_,c,15,u[62]),_=i(_,k,C,x,v,21,u[63]);a[0]=a[0]+x|0,a[1]=a[1]+_|0,a[2]=a[2]+k|0,a[3]=a[3]+C|0},_doFinalize:function(){var t=this._data,n=t.words,r=8*this._nDataBytes,i=8*t.sigBytes;n[i>>>5]|=128<<24-i%32;var o=e.floor(r/4294967296);for(n[15+(i+64>>>9<<4)]=16711935&(o<<8|o>>>24)|4278255360&(o<<24|o>>>8),n[14+(i+64>>>9<<4)]=16711935&(r<<8|r>>>24)|4278255360&(r<<24|r>>>8),t.sigBytes=4*(n.length+1),this._process(),t=this._hash,n=t.words,r=0;4>r;r++)i=n[r],n[r]=16711935&(i<<8|i>>>24)|4278255360&(i<<24|i>>>8);return t},clone:function(){var e=c.clone.call(this);return e._hash=this._hash.clone(),e}}),o.MD5=c._createHelper(a),o.HmacMD5=c._createHmacHelper(a)}(Math),function(){var e=l,t=e.lib,n=t.WordArray,r=t.Hasher,i=[];t=e.algo.SHA1=r.extend({_doReset:function(){this._hash=new n.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(e,t){for(var n=this._hash.words,r=n[0],o=n[1],a=n[2],s=n[3],l=n[4],c=0;80>c;c++){if(16>c)i[c]=0|e[t+c];else{var u=i[c-3]^i[c-8]^i[c-14]^i[c-16];i[c]=u<<1|u>>>31}u=(r<<5|r>>>27)+l+i[c],u=20>c?u+(1518500249+(o&a|~o&s)):40>c?u+(1859775393+(o^a^s)):60>c?u+((o&a|o&s|a&s)-1894007588):u+((o^a^s)-899497514),l=s,s=a,a=o<<30|o>>>2,o=r,r=u}n[0]=n[0]+r|0,n[1]=n[1]+o|0,n[2]=n[2]+a|0,n[3]=n[3]+s|0,n[4]=n[4]+l|0},_doFinalize:function(){var e=this._data,t=e.words,n=8*this._nDataBytes,r=8*e.sigBytes;return t[r>>>5]|=128<<24-r%32,t[14+(r+64>>>9<<4)]=Math.floor(n/4294967296),t[15+(r+64>>>9<<4)]=n,e.sigBytes=4*t.length,this._process(),this._hash},clone:function(){var e=r.clone.call(this);return e._hash=this._hash.clone(),e}});e.SHA1=r._createHelper(t),e.HmacSHA1=r._createHmacHelper(t)}(),function(e){for(var t=l,n=t.lib,r=n.WordArray,i=n.Hasher,o=(n=t.algo,[]),a=[],s=function(e){return 4294967296*(e-(0|e))|0},c=2,u=0;64>u;){var d;e:{d=c;for(var h=e.sqrt(d),p=2;p<=h;p++)if(!(d%p)){d=!1;break e}d=!0}d&&(8>u&&(o[u]=s(e.pow(c,.5))),a[u]=s(e.pow(c,1/3)),u++),c++}var f=[];n=n.SHA256=i.extend({_doReset:function(){this._hash=new r.init(o.slice(0))},_doProcessBlock:function(e,t){for(var n=this._hash.words,r=n[0],i=n[1],o=n[2],s=n[3],l=n[4],c=n[5],u=n[6],d=n[7],h=0;64>h;h++){if(16>h)f[h]=0|e[t+h];else{var p=f[h-15],m=f[h-2];f[h]=((p<<25|p>>>7)^(p<<14|p>>>18)^p>>>3)+f[h-7]+((m<<15|m>>>17)^(m<<13|m>>>19)^m>>>10)+f[h-16]}p=d+((l<<26|l>>>6)^(l<<21|l>>>11)^(l<<7|l>>>25))+(l&c^~l&u)+a[h]+f[h],m=((r<<30|r>>>2)^(r<<19|r>>>13)^(r<<10|r>>>22))+(r&i^r&o^i&o),d=u,u=c,c=l,l=s+p|0,s=o,o=i,i=r,r=p+m|0}n[0]=n[0]+r|0,n[1]=n[1]+i|0,n[2]=n[2]+o|0,n[3]=n[3]+s|0,n[4]=n[4]+l|0,n[5]=n[5]+c|0,n[6]=n[6]+u|0,n[7]=n[7]+d|0},_doFinalize:function(){var t=this._data,n=t.words,r=8*this._nDataBytes,i=8*t.sigBytes;return n[i>>>5]|=128<<24-i%32,n[14+(i+64>>>9<<4)]=e.floor(r/4294967296),n[15+(i+64>>>9<<4)]=r,t.sigBytes=4*n.length,this._process(),this._hash},clone:function(){var e=i.clone.call(this);return e._hash=this._hash.clone(),e}});t.SHA256=i._createHelper(n),t.HmacSHA256=i._createHmacHelper(n)}(Math),function(){var e=l,t=e.lib.WordArray,n=e.algo,r=n.SHA256;n=n.SHA224=r.extend({_doReset:function(){this._hash=new t.init([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428])},_doFinalize:function(){var e=r._doFinalize.call(this);return e.sigBytes-=4,e}});e.SHA224=r._createHelper(n),e.HmacSHA224=r._createHmacHelper(n)}(),function(){function e(){return i.create.apply(i,arguments)}for(var t=l,n=t.lib.Hasher,r=t.x64,i=r.Word,o=r.WordArray,a=(r=t.algo,[e(1116352408,3609767458),e(1899447441,602891725),e(3049323471,3964484399),e(3921009573,2173295548),e(961987163,4081628472),e(1508970993,3053834265),e(2453635748,2937671579),e(2870763221,3664609560),e(3624381080,2734883394),e(310598401,1164996542),e(607225278,1323610764),e(1426881987,3590304994),e(1925078388,4068182383),e(2162078206,991336113),e(2614888103,633803317),e(3248222580,3479774868),e(3835390401,2666613458),e(4022224774,944711139),e(264347078,2341262773),e(604807628,2007800933),e(770255983,1495990901),e(1249150122,1856431235),e(1555081692,3175218132),e(1996064986,2198950837),e(2554220882,3999719339),e(2821834349,766784016),e(2952996808,2566594879),e(3210313671,3203337956),e(3336571891,1034457026),e(3584528711,2466948901),e(113926993,3758326383),e(338241895,168717936),e(666307205,1188179964),e(773529912,1546045734),e(1294757372,1522805485),e(1396182291,2643833823),e(1695183700,2343527390),e(1986661051,1014477480),e(2177026350,1206759142),e(2456956037,344077627),e(2730485921,1290863460),e(2820302411,3158454273),e(3259730800,3505952657),e(3345764771,106217008),e(3516065817,3606008344),e(3600352804,1432725776),e(4094571909,1467031594),e(275423344,851169720),e(430227734,3100823752),e(506948616,1363258195),e(659060556,3750685593),e(883997877,3785050280),e(958139571,3318307427),e(1322822218,3812723403),e(1537002063,2003034995),e(1747873779,3602036899),e(1955562222,1575990012),e(2024104815,1125592928),e(2227730452,2716904306),e(2361852424,442776044),e(2428436474,593698344),e(2756734187,3733110249),e(3204031479,2999351573),e(3329325298,3815920427),e(3391569614,3928383900),e(3515267271,566280711),e(3940187606,3454069534),e(4118630271,4000239992),e(116418474,1914138554),e(174292421,2731055270),e(289380356,3203993006),e(460393269,320620315),e(685471733,587496836),e(852142971,1086792851),e(1017036298,365543100),e(1126000580,2618297676),e(1288033470,3409855158),e(1501505948,4234509866),e(1607167915,987167468),e(1816402316,1246189591)]),s=[],c=0;80>c;c++)s[c]=e();r=r.SHA512=n.extend({_doReset:function(){this._hash=new o.init([new i.init(1779033703,4089235720),new i.init(3144134277,2227873595),new i.init(1013904242,4271175723),new i.init(2773480762,1595750129),new i.init(1359893119,2917565137),new i.init(2600822924,725511199),new i.init(528734635,4215389547),new i.init(1541459225,327033209)])},_doProcessBlock:function(e,t){for(var n=this._hash.words,r=n[0],i=n[1],o=n[2],l=n[3],c=n[4],u=n[5],d=n[6],h=(n=n[7],r.high),p=r.low,f=i.high,m=i.low,g=o.high,v=o.low,b=l.high,y=l.low,w=c.high,O=c.low,S=u.high,E=u.low,x=d.high,_=d.low,k=n.high,C=n.low,A=h,T=p,R=f,N=m,P=g,I=v,M=b,D=y,L=w,B=O,$=S,V=E,F=x,j=_,U=k,G=C,H=0;80>H;H++){var q=s[H];if(16>H)var Q=q.high=0|e[t+2*H],z=q.low=0|e[t+2*H+1];else{Q=s[H-15],z=Q.high;var K=Q.low,W=(Q=(z>>>1|K<<31)^(z>>>8|K<<24)^z>>>7,K=(K>>>1|z<<31)^(K>>>8|z<<24)^(K>>>7|z<<25),s[H-2]),X=(z=W.high,W.low),Y=(W=(z>>>19|X<<13)^(z<<3|X>>>29)^z>>>6,X=(X>>>19|z<<13)^(X<<3|z>>>29)^(X>>>6|z<<26),z=s[H-7],z.high),Z=s[H-16],J=Z.high;Z=Z.low,z=K+z.low,Q=Q+Y+(z>>>0<K>>>0?1:0),z=z+X,Q=Q+W+(z>>>0<X>>>0?1:0),z=z+Z,Q=Q+J+(z>>>0<Z>>>0?1:0);q.high=Q,q.low=z}Y=L&$^~L&F,Z=B&V^~B&j,q=A&R^A&P^R&P;var ee=T&N^T&I^N&I,te=(K=(A>>>28|T<<4)^(A<<30|T>>>2)^(A<<25|T>>>7),W=(T>>>28|A<<4)^(T<<30|A>>>2)^(T<<25|A>>>7),X=a[H],X.high),ne=X.low;X=G+((B>>>14|L<<18)^(B>>>18|L<<14)^(B<<23|L>>>9)),J=U+((L>>>14|B<<18)^(L>>>18|B<<14)^(L<<23|B>>>9))+(X>>>0<G>>>0?1:0),X=X+Z,J=J+Y+(X>>>0<Z>>>0?1:0),X=X+ne,J=J+te+(X>>>0<ne>>>0?1:0),X=X+z,J=J+Q+(X>>>0<z>>>0?1:0),z=W+ee,q=K+q+(z>>>0<W>>>0?1:0),U=F,G=j,F=$,j=V,$=L,V=B,B=D+X|0,L=M+J+(B>>>0<D>>>0?1:0)|0,M=P,D=I,P=R,I=N,R=A,N=T,T=X+z|0,A=J+q+(T>>>0<X>>>0?1:0)|0}p=r.low=p+T,r.high=h+A+(p>>>0<T>>>0?1:0),m=i.low=m+N,i.high=f+R+(m>>>0<N>>>0?1:0),v=o.low=v+I,o.high=g+P+(v>>>0<I>>>0?1:0),y=l.low=y+D,l.high=b+M+(y>>>0<D>>>0?1:0),O=c.low=O+B,c.high=w+L+(O>>>0<B>>>0?1:0),E=u.low=E+V,u.high=S+$+(E>>>0<V>>>0?1:0),_=d.low=_+j,d.high=x+F+(_>>>0<j>>>0?1:0),C=n.low=C+G,n.high=k+U+(C>>>0<G>>>0?1:0)},_doFinalize:function(){var e=this._data,t=e.words,n=8*this._nDataBytes,r=8*e.sigBytes;return t[r>>>5]|=128<<24-r%32,t[30+(r+128>>>10<<5)]=Math.floor(n/4294967296),t[31+(r+128>>>10<<5)]=n,e.sigBytes=4*t.length,this._process(),this._hash.toX32()},clone:function(){var e=n.clone.call(this);return e._hash=this._hash.clone(),e},blockSize:32}),t.SHA512=n._createHelper(r),t.HmacSHA512=n._createHmacHelper(r)}(),function(){var e=l,t=e.x64,n=t.Word,r=t.WordArray,i=(t=e.algo,t.SHA512);t=t.SHA384=i.extend({_doReset:function(){this._hash=new r.init([new n.init(3418070365,3238371032),new n.init(1654270250,914150663),new n.init(2438529370,812702999),new n.init(355462360,4144912697),new n.init(1731405415,4290775857),new n.init(2394180231,1750603025),new n.init(3675008525,1694076839),new n.init(1203062813,3204075428)])},_doFinalize:function(){var e=i._doFinalize.call(this);return e.sigBytes-=16,e}});e.SHA384=i._createHelper(t),e.HmacSHA384=i._createHmacHelper(t)}(),function(){var e=l,t=e.lib,n=t.WordArray,r=t.Hasher,i=(t=e.algo,n.create([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13])),o=n.create([5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11]),a=n.create([11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6]),s=n.create([8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11]),c=n.create([0,1518500249,1859775393,2400959708,2840853838]),u=n.create([1352829926,1548603684,1836072691,2053994217,0]);t=t.RIPEMD160=r.extend({_doReset:function(){this._hash=n.create([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(e,t){for(var n=0;16>n;n++){var r=t+n,l=e[r];e[r]=16711935&(l<<8|l>>>24)|4278255360&(l<<24|l>>>8)}r=this._hash.words,l=c.words;var d,h,p,f,m,g,v,b,y,w,O=u.words,S=i.words,E=o.words,x=a.words,_=s.words;g=d=r[0],v=h=r[1],b=p=r[2],y=f=r[3],w=m=r[4];var k;for(n=0;80>n;n+=1)k=d+e[t+S[n]]|0,k=16>n?k+((h^p^f)+l[0]):32>n?k+((h&p|~h&f)+l[1]):48>n?k+(((h|~p)^f)+l[2]):64>n?k+((h&f|p&~f)+l[3]):k+((h^(p|~f))+l[4]),k|=0,k=k<<x[n]|k>>>32-x[n],k=k+m|0,d=m,m=f,f=p<<10|p>>>22,p=h,h=k,k=g+e[t+E[n]]|0,k=16>n?k+((v^(b|~y))+O[0]):32>n?k+((v&y|b&~y)+O[1]):48>n?k+(((v|~b)^y)+O[2]):64>n?k+((v&b|~v&y)+O[3]):k+((v^b^y)+O[4]),k|=0,k=k<<_[n]|k>>>32-_[n],k=k+w|0,g=w,w=y,y=b<<10|b>>>22,b=v,v=k;k=r[1]+p+y|0,r[1]=r[2]+f+w|0,r[2]=r[3]+m+g|0,r[3]=r[4]+d+v|0,r[4]=r[0]+h+b|0,r[0]=k},_doFinalize:function(){var e=this._data,t=e.words,n=8*this._nDataBytes,r=8*e.sigBytes;for(t[r>>>5]|=128<<24-r%32,t[14+(r+64>>>9<<4)]=16711935&(n<<8|n>>>24)|4278255360&(n<<24|n>>>8),e.sigBytes=4*(t.length+1),this._process(),e=this._hash,t=e.words,n=0;5>n;n++)r=t[n],t[n]=16711935&(r<<8|r>>>24)|4278255360&(r<<24|r>>>8);return e},clone:function(){var e=r.clone.call(this);return e._hash=this._hash.clone(),e}});e.RIPEMD160=r._createHelper(t),e.HmacRIPEMD160=r._createHmacHelper(t)}(Math),function(){var e=l,t=e.enc.Utf8;e.algo.HMAC=e.lib.Base.extend({init:function(e,n){e=this._hasher=new e.init,"string"==typeof n&&(n=t.parse(n));var r=e.blockSize,i=4*r;n.sigBytes>i&&(n=e.finalize(n)),n.clamp();for(var o=this._oKey=n.clone(),a=this._iKey=n.clone(),s=o.words,l=a.words,c=0;c<r;c++)s[c]^=1549556828,l[c]^=909522486;o.sigBytes=a.sigBytes=i,this.reset()},reset:function(){var e=this._hasher;e.reset(),e.update(this._iKey)},update:function(e){return this._hasher.update(e),this},finalize:function(e){var t=this._hasher;return e=t.finalize(e),t.reset(),t.finalize(this._oKey.clone().concat(e))}})}(),function(){var e=l,t=e.lib,n=t.Base,r=t.WordArray,i=(t=e.algo,t.HMAC),o=t.PBKDF2=n.extend({cfg:n.extend({keySize:4,hasher:t.SHA1,iterations:1}),init:function(e){this.cfg=this.cfg.extend(e)},compute:function(e,t){var n=this.cfg,o=i.create(n.hasher,e),a=r.create(),s=r.create([1]),l=a.words,c=s.words,u=n.keySize;for(n=n.iterations;l.length<u;){var d=o.update(t).finalize(s);o.reset();for(var h=d.words,p=h.length,f=d,m=1;m<n;m++){f=o.finalize(f),o.reset();for(var g=f.words,v=0;v<p;v++)h[v]^=g[v]}a.concat(d),c[0]++}return a.sigBytes=4*u,a}});e.PBKDF2=function(e,t,n){return o.create(n).compute(e,t)}}();
|
||
/*! (c) Tom Wu | http://www-cs-students.stanford.edu/~tjw/jsbn/
|
||
*/
|
||
var c,u="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",d="=";function h(e){var t,n,r="";for(t=0;t+3<=e.length;t+=3)n=parseInt(e.substring(t,t+3),16),r+=u.charAt(n>>6)+u.charAt(63&n);if(t+1==e.length?(n=parseInt(e.substring(t,t+1),16),r+=u.charAt(n<<2)):t+2==e.length&&(n=parseInt(e.substring(t,t+2),16),r+=u.charAt(n>>2)+u.charAt((3&n)<<4)),d)while((3&r.length)>0)r+=d;return r}function p(e){var t,n,r,i="",o=0;for(t=0;t<e.length;++t){if(e.charAt(t)==d)break;r=u.indexOf(e.charAt(t)),r<0||(0==o?(i+=C(r>>2),n=3&r,o=1):1==o?(i+=C(n<<2|r>>4),n=15&r,o=2):2==o?(i+=C(n),i+=C(r>>2),n=3&r,o=3):(i+=C(n<<2|r>>4),i+=C(15&r),o=0))}return 1==o&&(i+=C(n<<2)),i}function f(e){var t,n=p(e),r=new Array;for(t=0;2*t<n.length;++t)r[t]=parseInt(n.substring(2*t,2*t+2),16);return r}var m=0xdeadbeefcafe,g=15715070==(16777215&m);function v(e,t,n){null!=e&&("number"==typeof e?this.fromNumber(e,t,n):null==t&&"string"!=typeof e?this.fromString(e,256):this.fromString(e,t))}function b(){return new v(null)}function y(e,t,n,r,i,o){while(--o>=0){var a=t*this[e++]+n[r]+i;i=Math.floor(a/67108864),n[r++]=67108863&a}return i}function w(e,t,n,r,i,o){var a=32767&t,s=t>>15;while(--o>=0){var l=32767&this[e],c=this[e++]>>15,u=s*l+c*a;l=a*l+((32767&u)<<15)+n[r]+(1073741823&i),i=(l>>>30)+(u>>>15)+s*c+(i>>>30),n[r++]=1073741823&l}return i}function O(e,t,n,r,i,o){var a=16383&t,s=t>>14;while(--o>=0){var l=16383&this[e],c=this[e++]>>14,u=s*l+c*a;l=a*l+((16383&u)<<14)+n[r]+i,i=(l>>28)+(u>>14)+s*c,n[r++]=268435455&l}return i}g&&"Microsoft Internet Explorer"==i.appName?(v.prototype.am=w,c=30):g&&"Netscape"!=i.appName?(v.prototype.am=y,c=26):(v.prototype.am=O,c=28),v.prototype.DB=c,v.prototype.DM=(1<<c)-1,v.prototype.DV=1<<c;var S=52;v.prototype.FV=Math.pow(2,S),v.prototype.F1=S-c,v.prototype.F2=2*c-S;var E,x,_="0123456789abcdefghijklmnopqrstuvwxyz",k=new Array;for(E="0".charCodeAt(0),x=0;x<=9;++x)k[E++]=x;for(E="a".charCodeAt(0),x=10;x<36;++x)k[E++]=x;for(E="A".charCodeAt(0),x=10;x<36;++x)k[E++]=x;function C(e){return _.charAt(e)}function A(e,t){var n=k[e.charCodeAt(t)];return null==n?-1:n}function T(e){for(var t=this.t-1;t>=0;--t)e[t]=this[t];e.t=this.t,e.s=this.s}function R(e){this.t=1,this.s=e<0?-1:0,e>0?this[0]=e:e<-1?this[0]=e+this.DV:this.t=0}function N(e){var t=b();return t.fromInt(e),t}function P(e,t){var n;if(16==t)n=4;else if(8==t)n=3;else if(256==t)n=8;else if(2==t)n=1;else if(32==t)n=5;else{if(4!=t)return void this.fromRadix(e,t);n=2}this.t=0,this.s=0;var r=e.length,i=!1,o=0;while(--r>=0){var a=8==n?255&e[r]:A(e,r);a<0?"-"==e.charAt(r)&&(i=!0):(i=!1,0==o?this[this.t++]=a:o+n>this.DB?(this[this.t-1]|=(a&(1<<this.DB-o)-1)<<o,this[this.t++]=a>>this.DB-o):this[this.t-1]|=a<<o,o+=n,o>=this.DB&&(o-=this.DB))}8==n&&0!=(128&e[0])&&(this.s=-1,o>0&&(this[this.t-1]|=(1<<this.DB-o)-1<<o)),this.clamp(),i&&v.ZERO.subTo(this,this)}function I(){var e=this.s&this.DM;while(this.t>0&&this[this.t-1]==e)--this.t}function M(e){if(this.s<0)return"-"+this.negate().toString(e);var t;if(16==e)t=4;else if(8==e)t=3;else if(2==e)t=1;else if(32==e)t=5;else{if(4!=e)return this.toRadix(e);t=2}var n,r=(1<<t)-1,i=!1,o="",a=this.t,s=this.DB-a*this.DB%t;if(a-- >0){s<this.DB&&(n=this[a]>>s)>0&&(i=!0,o=C(n));while(a>=0)s<t?(n=(this[a]&(1<<s)-1)<<t-s,n|=this[--a]>>(s+=this.DB-t)):(n=this[a]>>(s-=t)&r,s<=0&&(s+=this.DB,--a)),n>0&&(i=!0),i&&(o+=C(n))}return i?o:"0"}function D(){var e=b();return v.ZERO.subTo(this,e),e}function L(){return this.s<0?this.negate():this}function B(e){var t=this.s-e.s;if(0!=t)return t;var n=this.t;if(t=n-e.t,0!=t)return this.s<0?-t:t;while(--n>=0)if(0!=(t=this[n]-e[n]))return t;return 0}function $(e){var t,n=1;return 0!=(t=e>>>16)&&(e=t,n+=16),0!=(t=e>>8)&&(e=t,n+=8),0!=(t=e>>4)&&(e=t,n+=4),0!=(t=e>>2)&&(e=t,n+=2),0!=(t=e>>1)&&(e=t,n+=1),n}function V(){return this.t<=0?0:this.DB*(this.t-1)+$(this[this.t-1]^this.s&this.DM)}function F(e,t){var n;for(n=this.t-1;n>=0;--n)t[n+e]=this[n];for(n=e-1;n>=0;--n)t[n]=0;t.t=this.t+e,t.s=this.s}function j(e,t){for(var n=e;n<this.t;++n)t[n-e]=this[n];t.t=Math.max(this.t-e,0),t.s=this.s}function U(e,t){var n,r=e%this.DB,i=this.DB-r,o=(1<<i)-1,a=Math.floor(e/this.DB),s=this.s<<r&this.DM;for(n=this.t-1;n>=0;--n)t[n+a+1]=this[n]>>i|s,s=(this[n]&o)<<r;for(n=a-1;n>=0;--n)t[n]=0;t[a]=s,t.t=this.t+a+1,t.s=this.s,t.clamp()}function G(e,t){t.s=this.s;var n=Math.floor(e/this.DB);if(n>=this.t)t.t=0;else{var r=e%this.DB,i=this.DB-r,o=(1<<r)-1;t[0]=this[n]>>r;for(var a=n+1;a<this.t;++a)t[a-n-1]|=(this[a]&o)<<i,t[a-n]=this[a]>>r;r>0&&(t[this.t-n-1]|=(this.s&o)<<i),t.t=this.t-n,t.clamp()}}function H(e,t){var n=0,r=0,i=Math.min(e.t,this.t);while(n<i)r+=this[n]-e[n],t[n++]=r&this.DM,r>>=this.DB;if(e.t<this.t){r-=e.s;while(n<this.t)r+=this[n],t[n++]=r&this.DM,r>>=this.DB;r+=this.s}else{r+=this.s;while(n<e.t)r-=e[n],t[n++]=r&this.DM,r>>=this.DB;r-=e.s}t.s=r<0?-1:0,r<-1?t[n++]=this.DV+r:r>0&&(t[n++]=r),t.t=n,t.clamp()}function q(e,t){var n=this.abs(),r=e.abs(),i=n.t;t.t=i+r.t;while(--i>=0)t[i]=0;for(i=0;i<r.t;++i)t[i+n.t]=n.am(0,r[i],t,i,0,n.t);t.s=0,t.clamp(),this.s!=e.s&&v.ZERO.subTo(t,t)}function Q(e){var t=this.abs(),n=e.t=2*t.t;while(--n>=0)e[n]=0;for(n=0;n<t.t-1;++n){var r=t.am(n,t[n],e,2*n,0,1);(e[n+t.t]+=t.am(n+1,2*t[n],e,2*n+1,r,t.t-n-1))>=t.DV&&(e[n+t.t]-=t.DV,e[n+t.t+1]=1)}e.t>0&&(e[e.t-1]+=t.am(n,t[n],e,2*n,0,1)),e.s=0,e.clamp()}function z(e,t,n){var r=e.abs();if(!(r.t<=0)){var i=this.abs();if(i.t<r.t)return null!=t&&t.fromInt(0),void(null!=n&&this.copyTo(n));null==n&&(n=b());var o=b(),a=this.s,s=e.s,l=this.DB-$(r[r.t-1]);l>0?(r.lShiftTo(l,o),i.lShiftTo(l,n)):(r.copyTo(o),i.copyTo(n));var c=o.t,u=o[c-1];if(0!=u){var d=u*(1<<this.F1)+(c>1?o[c-2]>>this.F2:0),h=this.FV/d,p=(1<<this.F1)/d,f=1<<this.F2,m=n.t,g=m-c,y=null==t?b():t;o.dlShiftTo(g,y),n.compareTo(y)>=0&&(n[n.t++]=1,n.subTo(y,n)),v.ONE.dlShiftTo(c,y),y.subTo(o,o);while(o.t<c)o[o.t++]=0;while(--g>=0){var w=n[--m]==u?this.DM:Math.floor(n[m]*h+(n[m-1]+f)*p);if((n[m]+=o.am(0,w,n,g,0,c))<w){o.dlShiftTo(g,y),n.subTo(y,n);while(n[m]<--w)n.subTo(y,n)}}null!=t&&(n.drShiftTo(c,t),a!=s&&v.ZERO.subTo(t,t)),n.t=c,n.clamp(),l>0&&n.rShiftTo(l,n),a<0&&v.ZERO.subTo(n,n)}}}function K(e){var t=b();return this.abs().divRemTo(e,null,t),this.s<0&&t.compareTo(v.ZERO)>0&&e.subTo(t,t),t}function W(e){this.m=e}function X(e){return e.s<0||e.compareTo(this.m)>=0?e.mod(this.m):e}function Y(e){return e}function Z(e){e.divRemTo(this.m,null,e)}function J(e,t,n){e.multiplyTo(t,n),this.reduce(n)}function ee(e,t){e.squareTo(t),this.reduce(t)}function te(){if(this.t<1)return 0;var e=this[0];if(0==(1&e))return 0;var t=3&e;return t=t*(2-(15&e)*t)&15,t=t*(2-(255&e)*t)&255,t=t*(2-((65535&e)*t&65535))&65535,t=t*(2-e*t%this.DV)%this.DV,t>0?this.DV-t:-t}function ne(e){this.m=e,this.mp=e.invDigit(),this.mpl=32767&this.mp,this.mph=this.mp>>15,this.um=(1<<e.DB-15)-1,this.mt2=2*e.t}function re(e){var t=b();return e.abs().dlShiftTo(this.m.t,t),t.divRemTo(this.m,null,t),e.s<0&&t.compareTo(v.ZERO)>0&&this.m.subTo(t,t),t}function ie(e){var t=b();return e.copyTo(t),this.reduce(t),t}function oe(e){while(e.t<=this.mt2)e[e.t++]=0;for(var t=0;t<this.m.t;++t){var n=32767&e[t],r=n*this.mpl+((n*this.mph+(e[t]>>15)*this.mpl&this.um)<<15)&e.DM;n=t+this.m.t,e[n]+=this.m.am(0,r,e,t,0,this.m.t);while(e[n]>=e.DV)e[n]-=e.DV,e[++n]++}e.clamp(),e.drShiftTo(this.m.t,e),e.compareTo(this.m)>=0&&e.subTo(this.m,e)}function ae(e,t){e.squareTo(t),this.reduce(t)}function se(e,t,n){e.multiplyTo(t,n),this.reduce(n)}function le(){return 0==(this.t>0?1&this[0]:this.s)}function ce(e,t){if(e>4294967295||e<1)return v.ONE;var n=b(),r=b(),i=t.convert(this),o=$(e)-1;i.copyTo(n);while(--o>=0)if(t.sqrTo(n,r),(e&1<<o)>0)t.mulTo(r,i,n);else{var a=n;n=r,r=a}return t.revert(n)}function ue(e,t){var n;return n=e<256||t.isEven()?new W(t):new ne(t),this.exp(e,n)}
|
||
/*! (c) Tom Wu | http://www-cs-students.stanford.edu/~tjw/jsbn/
|
||
*/
|
||
function de(){var e=b();return this.copyTo(e),e}function he(){if(this.s<0){if(1==this.t)return this[0]-this.DV;if(0==this.t)return-1}else{if(1==this.t)return this[0];if(0==this.t)return 0}return(this[1]&(1<<32-this.DB)-1)<<this.DB|this[0]}function pe(){return 0==this.t?this.s:this[0]<<24>>24}function fe(){return 0==this.t?this.s:this[0]<<16>>16}function me(e){return Math.floor(Math.LN2*this.DB/Math.log(e))}function ge(){return this.s<0?-1:this.t<=0||1==this.t&&this[0]<=0?0:1}function ve(e){if(null==e&&(e=10),0==this.signum()||e<2||e>36)return"0";var t=this.chunkSize(e),n=Math.pow(e,t),r=N(n),i=b(),o=b(),a="";this.divRemTo(r,i,o);while(i.signum()>0)a=(n+o.intValue()).toString(e).substr(1)+a,i.divRemTo(r,i,o);return o.intValue().toString(e)+a}function be(e,t){this.fromInt(0),null==t&&(t=10);for(var n=this.chunkSize(t),r=Math.pow(t,n),i=!1,o=0,a=0,s=0;s<e.length;++s){var l=A(e,s);l<0?"-"==e.charAt(s)&&0==this.signum()&&(i=!0):(a=t*a+l,++o>=n&&(this.dMultiply(r),this.dAddOffset(a,0),o=0,a=0))}o>0&&(this.dMultiply(Math.pow(t,o)),this.dAddOffset(a,0)),i&&v.ZERO.subTo(this,this)}function ye(e,t,n){if("number"==typeof t)if(e<2)this.fromInt(1);else{this.fromNumber(e,n),this.testBit(e-1)||this.bitwiseTo(v.ONE.shiftLeft(e-1),Ce,this),this.isEven()&&this.dAddOffset(1,0);while(!this.isProbablePrime(t))this.dAddOffset(2,0),this.bitLength()>e&&this.subTo(v.ONE.shiftLeft(e-1),this)}else{var r=new Array,i=7&e;r.length=1+(e>>3),t.nextBytes(r),i>0?r[0]&=(1<<i)-1:r[0]=0,this.fromString(r,256)}}function we(){var e=this.t,t=new Array;t[0]=this.s;var n,r=this.DB-e*this.DB%8,i=0;if(e-- >0){r<this.DB&&(n=this[e]>>r)!=(this.s&this.DM)>>r&&(t[i++]=n|this.s<<this.DB-r);while(e>=0)r<8?(n=(this[e]&(1<<r)-1)<<8-r,n|=this[--e]>>(r+=this.DB-8)):(n=this[e]>>(r-=8)&255,r<=0&&(r+=this.DB,--e)),0!=(128&n)&&(n|=-256),0==i&&(128&this.s)!=(128&n)&&++i,(i>0||n!=this.s)&&(t[i++]=n)}return t}function Oe(e){return 0==this.compareTo(e)}function Se(e){return this.compareTo(e)<0?this:e}function Ee(e){return this.compareTo(e)>0?this:e}function xe(e,t,n){var r,i,o=Math.min(e.t,this.t);for(r=0;r<o;++r)n[r]=t(this[r],e[r]);if(e.t<this.t){for(i=e.s&this.DM,r=o;r<this.t;++r)n[r]=t(this[r],i);n.t=this.t}else{for(i=this.s&this.DM,r=o;r<e.t;++r)n[r]=t(i,e[r]);n.t=e.t}n.s=t(this.s,e.s),n.clamp()}function _e(e,t){return e&t}function ke(e){var t=b();return this.bitwiseTo(e,_e,t),t}function Ce(e,t){return e|t}function Ae(e){var t=b();return this.bitwiseTo(e,Ce,t),t}function Te(e,t){return e^t}function Re(e){var t=b();return this.bitwiseTo(e,Te,t),t}function Ne(e,t){return e&~t}function Pe(e){var t=b();return this.bitwiseTo(e,Ne,t),t}function Ie(){for(var e=b(),t=0;t<this.t;++t)e[t]=this.DM&~this[t];return e.t=this.t,e.s=~this.s,e}function Me(e){var t=b();return e<0?this.rShiftTo(-e,t):this.lShiftTo(e,t),t}function De(e){var t=b();return e<0?this.lShiftTo(-e,t):this.rShiftTo(e,t),t}function Le(e){if(0==e)return-1;var t=0;return 0==(65535&e)&&(e>>=16,t+=16),0==(255&e)&&(e>>=8,t+=8),0==(15&e)&&(e>>=4,t+=4),0==(3&e)&&(e>>=2,t+=2),0==(1&e)&&++t,t}function Be(){for(var e=0;e<this.t;++e)if(0!=this[e])return e*this.DB+Le(this[e]);return this.s<0?this.t*this.DB:-1}function $e(e){var t=0;while(0!=e)e&=e-1,++t;return t}function Ve(){for(var e=0,t=this.s&this.DM,n=0;n<this.t;++n)e+=$e(this[n]^t);return e}function Fe(e){var t=Math.floor(e/this.DB);return t>=this.t?0!=this.s:0!=(this[t]&1<<e%this.DB)}function je(e,t){var n=v.ONE.shiftLeft(e);return this.bitwiseTo(n,t,n),n}function Ue(e){return this.changeBit(e,Ce)}function Ge(e){return this.changeBit(e,Ne)}function He(e){return this.changeBit(e,Te)}function qe(e,t){var n=0,r=0,i=Math.min(e.t,this.t);while(n<i)r+=this[n]+e[n],t[n++]=r&this.DM,r>>=this.DB;if(e.t<this.t){r+=e.s;while(n<this.t)r+=this[n],t[n++]=r&this.DM,r>>=this.DB;r+=this.s}else{r+=this.s;while(n<e.t)r+=e[n],t[n++]=r&this.DM,r>>=this.DB;r+=e.s}t.s=r<0?-1:0,r>0?t[n++]=r:r<-1&&(t[n++]=this.DV+r),t.t=n,t.clamp()}function Qe(e){var t=b();return this.addTo(e,t),t}function ze(e){var t=b();return this.subTo(e,t),t}function Ke(e){var t=b();return this.multiplyTo(e,t),t}function We(){var e=b();return this.squareTo(e),e}function Xe(e){var t=b();return this.divRemTo(e,t,null),t}function Ye(e){var t=b();return this.divRemTo(e,null,t),t}function Ze(e){var t=b(),n=b();return this.divRemTo(e,t,n),new Array(t,n)}function Je(e){this[this.t]=this.am(0,e-1,this,0,0,this.t),++this.t,this.clamp()}function et(e,t){if(0!=e){while(this.t<=t)this[this.t++]=0;this[t]+=e;while(this[t]>=this.DV)this[t]-=this.DV,++t>=this.t&&(this[this.t++]=0),++this[t]}}function tt(){}function nt(e){return e}function rt(e,t,n){e.multiplyTo(t,n)}function it(e,t){e.squareTo(t)}function ot(e){return this.exp(e,new tt)}function at(e,t,n){var r,i=Math.min(this.t+e.t,t);n.s=0,n.t=i;while(i>0)n[--i]=0;for(r=n.t-this.t;i<r;++i)n[i+this.t]=this.am(0,e[i],n,i,0,this.t);for(r=Math.min(e.t,t);i<r;++i)this.am(0,e[i],n,i,0,t-i);n.clamp()}function st(e,t,n){--t;var r=n.t=this.t+e.t-t;n.s=0;while(--r>=0)n[r]=0;for(r=Math.max(t-this.t,0);r<e.t;++r)n[this.t+r-t]=this.am(t-r,e[r],n,0,0,this.t+r-t);n.clamp(),n.drShiftTo(1,n)}function lt(e){this.r2=b(),this.q3=b(),v.ONE.dlShiftTo(2*e.t,this.r2),this.mu=this.r2.divide(e),this.m=e}function ct(e){if(e.s<0||e.t>2*this.m.t)return e.mod(this.m);if(e.compareTo(this.m)<0)return e;var t=b();return e.copyTo(t),this.reduce(t),t}function ut(e){return e}function dt(e){e.drShiftTo(this.m.t-1,this.r2),e.t>this.m.t+1&&(e.t=this.m.t+1,e.clamp()),this.mu.multiplyUpperTo(this.r2,this.m.t+1,this.q3),this.m.multiplyLowerTo(this.q3,this.m.t+1,this.r2);while(e.compareTo(this.r2)<0)e.dAddOffset(1,this.m.t+1);e.subTo(this.r2,e);while(e.compareTo(this.m)>=0)e.subTo(this.m,e)}function ht(e,t){e.squareTo(t),this.reduce(t)}function pt(e,t,n){e.multiplyTo(t,n),this.reduce(n)}function ft(e,t){var n,r,i=e.bitLength(),o=N(1);if(i<=0)return o;n=i<18?1:i<48?3:i<144?4:i<768?5:6,r=i<8?new W(t):t.isEven()?new lt(t):new ne(t);var a=new Array,s=3,l=n-1,c=(1<<n)-1;if(a[1]=r.convert(this),n>1){var u=b();r.sqrTo(a[1],u);while(s<=c)a[s]=b(),r.mulTo(u,a[s-2],a[s]),s+=2}var d,h,p=e.t-1,f=!0,m=b();i=$(e[p])-1;while(p>=0){i>=l?d=e[p]>>i-l&c:(d=(e[p]&(1<<i+1)-1)<<l-i,p>0&&(d|=e[p-1]>>this.DB+i-l)),s=n;while(0==(1&d))d>>=1,--s;if((i-=s)<0&&(i+=this.DB,--p),f)a[d].copyTo(o),f=!1;else{while(s>1)r.sqrTo(o,m),r.sqrTo(m,o),s-=2;s>0?r.sqrTo(o,m):(h=o,o=m,m=h),r.mulTo(m,a[d],o)}while(p>=0&&0==(e[p]&1<<i))r.sqrTo(o,m),h=o,o=m,m=h,--i<0&&(i=this.DB-1,--p)}return r.revert(o)}function mt(e){var t=this.s<0?this.negate():this.clone(),n=e.s<0?e.negate():e.clone();if(t.compareTo(n)<0){var r=t;t=n,n=r}var i=t.getLowestSetBit(),o=n.getLowestSetBit();if(o<0)return t;i<o&&(o=i),o>0&&(t.rShiftTo(o,t),n.rShiftTo(o,n));while(t.signum()>0)(i=t.getLowestSetBit())>0&&t.rShiftTo(i,t),(i=n.getLowestSetBit())>0&&n.rShiftTo(i,n),t.compareTo(n)>=0?(t.subTo(n,t),t.rShiftTo(1,t)):(n.subTo(t,n),n.rShiftTo(1,n));return o>0&&n.lShiftTo(o,n),n}function gt(e){if(e<=0)return 0;var t=this.DV%e,n=this.s<0?e-1:0;if(this.t>0)if(0==t)n=this[0]%e;else for(var r=this.t-1;r>=0;--r)n=(t*n+this[r])%e;return n}function vt(e){var t=e.isEven();if(this.isEven()&&t||0==e.signum())return v.ZERO;var n=e.clone(),r=this.clone(),i=N(1),o=N(0),a=N(0),s=N(1);while(0!=n.signum()){while(n.isEven())n.rShiftTo(1,n),t?(i.isEven()&&o.isEven()||(i.addTo(this,i),o.subTo(e,o)),i.rShiftTo(1,i)):o.isEven()||o.subTo(e,o),o.rShiftTo(1,o);while(r.isEven())r.rShiftTo(1,r),t?(a.isEven()&&s.isEven()||(a.addTo(this,a),s.subTo(e,s)),a.rShiftTo(1,a)):s.isEven()||s.subTo(e,s),s.rShiftTo(1,s);n.compareTo(r)>=0?(n.subTo(r,n),t&&i.subTo(a,i),o.subTo(s,o)):(r.subTo(n,r),t&&a.subTo(i,a),s.subTo(o,s))}return 0!=r.compareTo(v.ONE)?v.ZERO:s.compareTo(e)>=0?s.subtract(e):s.signum()<0?(s.addTo(e,s),s.signum()<0?s.add(e):s):s}W.prototype.convert=X,W.prototype.revert=Y,W.prototype.reduce=Z,W.prototype.mulTo=J,W.prototype.sqrTo=ee,ne.prototype.convert=re,ne.prototype.revert=ie,ne.prototype.reduce=oe,ne.prototype.mulTo=se,ne.prototype.sqrTo=ae,v.prototype.copyTo=T,v.prototype.fromInt=R,v.prototype.fromString=P,v.prototype.clamp=I,v.prototype.dlShiftTo=F,v.prototype.drShiftTo=j,v.prototype.lShiftTo=U,v.prototype.rShiftTo=G,v.prototype.subTo=H,v.prototype.multiplyTo=q,v.prototype.squareTo=Q,v.prototype.divRemTo=z,v.prototype.invDigit=te,v.prototype.isEven=le,v.prototype.exp=ce,v.prototype.toString=M,v.prototype.negate=D,v.prototype.abs=L,v.prototype.compareTo=B,v.prototype.bitLength=V,v.prototype.mod=K,v.prototype.modPowInt=ue,v.ZERO=N(0),v.ONE=N(1),tt.prototype.convert=nt,tt.prototype.revert=nt,tt.prototype.mulTo=rt,tt.prototype.sqrTo=it,lt.prototype.convert=ct,lt.prototype.revert=ut,lt.prototype.reduce=dt,lt.prototype.mulTo=pt,lt.prototype.sqrTo=ht;var bt=[2,3,5,7,11,13,17,19,23,29,31,37,41,43,47,53,59,61,67,71,73,79,83,89,97,101,103,107,109,113,127,131,137,139,149,151,157,163,167,173,179,181,191,193,197,199,211,223,227,229,233,239,241,251,257,263,269,271,277,281,283,293,307,311,313,317,331,337,347,349,353,359,367,373,379,383,389,397,401,409,419,421,431,433,439,443,449,457,461,463,467,479,487,491,499,503,509,521,523,541,547,557,563,569,571,577,587,593,599,601,607,613,617,619,631,641,643,647,653,659,661,673,677,683,691,701,709,719,727,733,739,743,751,757,761,769,773,787,797,809,811,821,823,827,829,839,853,857,859,863,877,881,883,887,907,911,919,929,937,941,947,953,967,971,977,983,991,997],yt=(1<<26)/bt[bt.length-1];function wt(e){var t,n=this.abs();if(1==n.t&&n[0]<=bt[bt.length-1]){for(t=0;t<bt.length;++t)if(n[0]==bt[t])return!0;return!1}if(n.isEven())return!1;t=1;while(t<bt.length){var r=bt[t],i=t+1;while(i<bt.length&&r<yt)r*=bt[i++];r=n.modInt(r);while(t<i)if(r%bt[t++]==0)return!1}return n.millerRabin(e)}function Ot(e){var t=this.subtract(v.ONE),n=t.getLowestSetBit();if(n<=0)return!1;var r=t.shiftRight(n);e=e+1>>1,e>bt.length&&(e=bt.length);for(var i=b(),o=0;o<e;++o){i.fromInt(bt[Math.floor(Math.random()*bt.length)]);var a=i.modPow(r,this);if(0!=a.compareTo(v.ONE)&&0!=a.compareTo(t)){var s=1;while(s++<n&&0!=a.compareTo(t))if(a=a.modPowInt(2,this),0==a.compareTo(v.ONE))return!1;if(0!=a.compareTo(t))return!1}}return!0}
|
||
/*! (c) Tom Wu | http://www-cs-students.stanford.edu/~tjw/jsbn/
|
||
*/
|
||
function St(){this.i=0,this.j=0,this.S=new Array}function Et(e){var t,n,r;for(t=0;t<256;++t)this.S[t]=t;for(n=0,t=0;t<256;++t)n=n+this.S[t]+e[t%e.length]&255,r=this.S[t],this.S[t]=this.S[n],this.S[n]=r;this.i=0,this.j=0}function xt(){var e;return this.i=this.i+1&255,this.j=this.j+this.S[this.i]&255,e=this.S[this.i],this.S[this.i]=this.S[this.j],this.S[this.j]=e,this.S[e+this.S[this.i]&255]}function _t(){return new St}v.prototype.chunkSize=me,v.prototype.toRadix=ve,v.prototype.fromRadix=be,v.prototype.fromNumber=ye,v.prototype.bitwiseTo=xe,v.prototype.changeBit=je,v.prototype.addTo=qe,v.prototype.dMultiply=Je,v.prototype.dAddOffset=et,v.prototype.multiplyLowerTo=at,v.prototype.multiplyUpperTo=st,v.prototype.modInt=gt,v.prototype.millerRabin=Ot,v.prototype.clone=de,v.prototype.intValue=he,v.prototype.byteValue=pe,v.prototype.shortValue=fe,v.prototype.signum=ge,v.prototype.toByteArray=we,v.prototype.equals=Oe,v.prototype.min=Se,v.prototype.max=Ee,v.prototype.and=ke,v.prototype.or=Ae,v.prototype.xor=Re,v.prototype.andNot=Pe,v.prototype.not=Ie,v.prototype.shiftLeft=Me,v.prototype.shiftRight=De,v.prototype.getLowestSetBit=Be,v.prototype.bitCount=Ve,v.prototype.testBit=Fe,v.prototype.setBit=Ue,v.prototype.clearBit=Ge,v.prototype.flipBit=He,v.prototype.add=Qe,v.prototype.subtract=ze,v.prototype.multiply=Ke,v.prototype.divide=Xe,v.prototype.remainder=Ye,v.prototype.divideAndRemainder=Ze,v.prototype.modPow=ft,v.prototype.modInverse=vt,v.prototype.pow=ot,v.prototype.gcd=mt,v.prototype.isProbablePrime=wt,v.prototype.square=We,St.prototype.init=Et,St.prototype.next=xt;var kt,Ct,At,Tt=256;
|
||
/*! (c) Tom Wu | http://www-cs-students.stanford.edu/~tjw/jsbn/
|
||
*/function Rt(e){Ct[At++]^=255&e,Ct[At++]^=e>>8&255,Ct[At++]^=e>>16&255,Ct[At++]^=e>>24&255,At>=Tt&&(At-=Tt)}function Nt(){Rt((new Date).getTime())}if(null==Ct){var Pt;if(Ct=new Array,At=0,void 0!==o&&(void 0!==o.crypto||void 0!==o.msCrypto)){var It=o.crypto||o.msCrypto;if(It.getRandomValues){var Mt=new Uint8Array(32);for(It.getRandomValues(Mt),Pt=0;Pt<32;++Pt)Ct[At++]=Mt[Pt]}else if("Netscape"==i.appName&&i.appVersion<"5"){var Dt=o.crypto.random(32);for(Pt=0;Pt<Dt.length;++Pt)Ct[At++]=255&Dt.charCodeAt(Pt)}}while(At<Tt)Pt=Math.floor(65536*Math.random()),Ct[At++]=Pt>>>8,Ct[At++]=255&Pt;At=0,Nt()}function Lt(){if(null==kt){for(Nt(),kt=_t(),kt.init(Ct),At=0;At<Ct.length;++At)Ct[At]=0;At=0}return kt.next()}function Bt(e){var t;for(t=0;t<e.length;++t)e[t]=Lt()}function $t(){}
|
||
/*! (c) Tom Wu | http://www-cs-students.stanford.edu/~tjw/jsbn/
|
||
*/
|
||
function Vt(e,t){return new v(e,t)}function Ft(){this.n=null,this.e=0,this.d=null,this.p=null,this.q=null,this.dmp1=null,this.dmq1=null,this.coeff=null}function jt(e,t){if(this.isPublic=!0,this.isPrivate=!1,"string"!==typeof e)this.n=e,this.e=t;else{if(!(null!=e&&null!=t&&e.length>0&&t.length>0))throw"Invalid RSA public key";this.n=Vt(e,16),this.e=parseInt(t,16)}if(null==this.n||"function"!==typeof this.n.compareTo||this.n.compareTo(v.ONE)<=0||null==this.e||isNaN(this.e)||this.e<=0)throw"Invalid RSA public key"}function Ut(e){return e.modPowInt(this.e,this.n)}function Gt(e,t,n){if(this.isPrivate=!0,"string"!==typeof e)this.n=e,this.e=t,this.d=n;else{if(!(null!=e&&null!=t&&e.length>0&&t.length>0))throw"Invalid RSA private key";this.n=Vt(e,16),this.e=parseInt(t,16),this.d=Vt(n,16)}}function Ht(e,t,n,r,i,o,a,s){if(this.isPrivate=!0,this.isPublic=!1,null==e)throw"RSASetPrivateEx N == null";if(null==t)throw"RSASetPrivateEx E == null";if(0==e.length)throw"RSASetPrivateEx N.length == 0";if(0==t.length)throw"RSASetPrivateEx E.length == 0";if(!(null!=e&&null!=t&&e.length>0&&t.length>0))throw"Invalid RSA private key in RSASetPrivateEx";this.n=Vt(e,16),this.e=parseInt(t,16),this.d=Vt(n,16),this.p=Vt(r,16),this.q=Vt(i,16),this.dmp1=Vt(o,16),this.dmq1=Vt(a,16),this.coeff=Vt(s,16)}function qt(e,t){var n=new $t,r=e>>1;this.e=parseInt(t,16);for(var i=new v(t,16),o=e/2-100,a=v.ONE.shiftLeft(o);;){for(;;)if(this.p=new v(e-r,1,n),0==this.p.subtract(v.ONE).gcd(i).compareTo(v.ONE)&&this.p.isProbablePrime(10))break;for(;;)if(this.q=new v(r,1,n),0==this.q.subtract(v.ONE).gcd(i).compareTo(v.ONE)&&this.q.isProbablePrime(10))break;if(this.p.compareTo(this.q)<=0){var s=this.p;this.p=this.q,this.q=s}var l=this.q.subtract(this.p).abs();if(!(l.bitLength()<o||l.compareTo(a)<=0)){var c=this.p.subtract(v.ONE),u=this.q.subtract(v.ONE),d=c.multiply(u);if(0==d.gcd(i).compareTo(v.ONE)&&(this.n=this.p.multiply(this.q),this.n.bitLength()==e)){this.d=i.modInverse(d),this.dmp1=this.d.mod(c),this.dmq1=this.d.mod(u),this.coeff=this.q.modInverse(this.p);break}}}this.isPrivate=!0}function Qt(e){if(null==this.p||null==this.q)return e.modPow(this.d,this.n);var t=e.mod(this.p).modPow(this.dmp1,this.p),n=e.mod(this.q).modPow(this.dmq1,this.q);while(t.compareTo(n)<0)t=t.add(this.p);return t.subtract(n).multiply(this.coeff).mod(this.p).multiply(this.q).add(n)}
|
||
/*! (c) Tom Wu | http://www-cs-students.stanford.edu/~tjw/jsbn/
|
||
*/
|
||
function zt(e,t){this.x=t,this.q=e}function Kt(e){return e==this||this.q.equals(e.q)&&this.x.equals(e.x)}function Wt(){return this.x}function Xt(){return new zt(this.q,this.x.negate().mod(this.q))}function Yt(e){return new zt(this.q,this.x.add(e.toBigInteger()).mod(this.q))}function Zt(e){return new zt(this.q,this.x.subtract(e.toBigInteger()).mod(this.q))}function Jt(e){return new zt(this.q,this.x.multiply(e.toBigInteger()).mod(this.q))}function en(){return new zt(this.q,this.x.square().mod(this.q))}function tn(e){return new zt(this.q,this.x.multiply(e.toBigInteger().modInverse(this.q)).mod(this.q))}function nn(e,t,n,r){this.curve=e,this.x=t,this.y=n,this.z=null==r?v.ONE:r,this.zinv=null}function rn(){return null==this.zinv&&(this.zinv=this.z.modInverse(this.curve.q)),this.curve.fromBigInteger(this.x.toBigInteger().multiply(this.zinv).mod(this.curve.q))}function on(){return null==this.zinv&&(this.zinv=this.z.modInverse(this.curve.q)),this.curve.fromBigInteger(this.y.toBigInteger().multiply(this.zinv).mod(this.curve.q))}function an(e){return e==this||(this.isInfinity()?e.isInfinity():e.isInfinity()?this.isInfinity():(t=e.y.toBigInteger().multiply(this.z).subtract(this.y.toBigInteger().multiply(e.z)).mod(this.curve.q),!!t.equals(v.ZERO)&&(n=e.x.toBigInteger().multiply(this.z).subtract(this.x.toBigInteger().multiply(e.z)).mod(this.curve.q),n.equals(v.ZERO))));var t,n}function sn(){return null==this.x&&null==this.y||this.z.equals(v.ZERO)&&!this.y.toBigInteger().equals(v.ZERO)}function ln(){return new nn(this.curve,this.x,this.y.negate(),this.z)}function cn(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var t=e.y.toBigInteger().multiply(this.z).subtract(this.y.toBigInteger().multiply(e.z)).mod(this.curve.q),n=e.x.toBigInteger().multiply(this.z).subtract(this.x.toBigInteger().multiply(e.z)).mod(this.curve.q);if(v.ZERO.equals(n))return v.ZERO.equals(t)?this.twice():this.curve.getInfinity();var r=new v("3"),i=this.x.toBigInteger(),o=this.y.toBigInteger(),a=(e.x.toBigInteger(),e.y.toBigInteger(),n.square()),s=a.multiply(n),l=i.multiply(a),c=t.square().multiply(this.z),u=c.subtract(l.shiftLeft(1)).multiply(e.z).subtract(s).multiply(n).mod(this.curve.q),d=l.multiply(r).multiply(t).subtract(o.multiply(s)).subtract(c.multiply(t)).multiply(e.z).add(t.multiply(s)).mod(this.curve.q),h=s.multiply(this.z).multiply(e.z).mod(this.curve.q);return new nn(this.curve,this.curve.fromBigInteger(u),this.curve.fromBigInteger(d),h)}function un(){if(this.isInfinity())return this;if(0==this.y.toBigInteger().signum())return this.curve.getInfinity();var e=new v("3"),t=this.x.toBigInteger(),n=this.y.toBigInteger(),r=n.multiply(this.z),i=r.multiply(n).mod(this.curve.q),o=this.curve.a.toBigInteger(),a=t.square().multiply(e);v.ZERO.equals(o)||(a=a.add(this.z.square().multiply(o))),a=a.mod(this.curve.q);var s=a.square().subtract(t.shiftLeft(3).multiply(i)).shiftLeft(1).multiply(r).mod(this.curve.q),l=a.multiply(e).multiply(t).subtract(i.shiftLeft(1)).shiftLeft(2).multiply(i).subtract(a.square().multiply(a)).mod(this.curve.q),c=r.square().multiply(r).shiftLeft(3).mod(this.curve.q);return new nn(this.curve,this.curve.fromBigInteger(s),this.curve.fromBigInteger(l),c)}function dn(e){if(this.isInfinity())return this;if(0==e.signum())return this.curve.getInfinity();var t,n=e,r=n.multiply(new v("3")),i=this.negate(),o=this,a=this.curve.q.subtract(e),s=a.multiply(new v("3")),l=new nn(this.curve,this.x,this.y),c=l.negate();for(t=r.bitLength()-2;t>0;--t){o=o.twice();var u=r.testBit(t),d=n.testBit(t);u!=d&&(o=o.add(u?this:i))}for(t=s.bitLength()-2;t>0;--t){l=l.twice();var h=s.testBit(t),p=a.testBit(t);h!=p&&(l=l.add(h?l:c))}return o}function hn(e,t,n){var r;r=e.bitLength()>n.bitLength()?e.bitLength()-1:n.bitLength()-1;var i=this.curve.getInfinity(),o=this.add(t);while(r>=0)i=i.twice(),e.testBit(r)?i=n.testBit(r)?i.add(o):i.add(this):n.testBit(r)&&(i=i.add(t)),--r;return i}function pn(e,t,n){this.q=e,this.a=this.fromBigInteger(t),this.b=this.fromBigInteger(n),this.infinity=new nn(this,null,null)}function fn(){return this.q}function mn(){return this.a}function gn(){return this.b}function vn(e){return e==this||this.q.equals(e.q)&&this.a.equals(e.a)&&this.b.equals(e.b)}function bn(){return this.infinity}function yn(e){return new zt(this.q,e)}function wn(e){switch(parseInt(e.substr(0,2),16)){case 0:return this.infinity;case 2:case 3:var t=e.substr(0,2),n=(e.substr(2),this.fromBigInteger(new v(l,16))),r=this.getA(),i=this.getB(),o=n.square().add(r).multiply(n).add(i),a=o.sqrt();return"03"==t&&(a=a.negate()),new nn(this,n,a);case 4:case 6:case 7:var s=(e.length-2)/2,l=e.substr(2,s),c=e.substr(s+2,s);return new nn(this,this.fromBigInteger(new v(l,16)),this.fromBigInteger(new v(c,16)));default:return null}}$t.prototype.nextBytes=Bt,Ft.prototype.doPublic=Ut,Ft.prototype.setPublic=jt,Ft.prototype.type="RSA",Ft.prototype.doPrivate=Qt,Ft.prototype.setPrivate=Gt,Ft.prototype.setPrivateEx=Ht,Ft.prototype.generate=qt,zt.prototype.equals=Kt,zt.prototype.toBigInteger=Wt,zt.prototype.negate=Xt,zt.prototype.add=Yt,zt.prototype.subtract=Zt,zt.prototype.multiply=Jt,zt.prototype.square=en,zt.prototype.divide=tn,zt.prototype.sqrt=function(){return new zt(this.q,this.x.sqrt().mod(this.q))},nn.prototype.getX=rn,nn.prototype.getY=on,nn.prototype.equals=an,nn.prototype.isInfinity=sn,nn.prototype.negate=ln,nn.prototype.add=cn,nn.prototype.twice=un,nn.prototype.multiply=dn,nn.prototype.multiplyTwo=hn,pn.prototype.getQ=fn,pn.prototype.getA=mn,pn.prototype.getB=gn,pn.prototype.equals=vn,pn.prototype.getInfinity=bn,pn.prototype.fromBigInteger=yn,pn.prototype.decodePointHex=wn,
|
||
/*! (c) Stefan Thomas | https://github.com/bitcoinjs/bitcoinjs-lib
|
||
*/
|
||
zt.prototype.getByteLength=function(){return Math.floor((this.toBigInteger().bitLength()+7)/8)},nn.prototype.getEncoded=function(e){var t=function(e,t){var n=e.toByteArrayUnsigned();if(t<n.length)n=n.slice(n.length-t);else while(t>n.length)n.unshift(0);return n},n=this.getX().toBigInteger(),r=this.getY().toBigInteger(),i=t(n,32);return e?r.isEven()?i.unshift(2):i.unshift(3):(i.unshift(4),i=i.concat(t(r,32))),i},nn.decodeFrom=function(e,t){t[0];var n=t.length-1,r=t.slice(1,1+n/2),i=t.slice(1+n/2,1+n);r.unshift(0),i.unshift(0);var o=new v(r),a=new v(i);return new nn(e,e.fromBigInteger(o),e.fromBigInteger(a))},nn.decodeFromHex=function(e,t){t.substr(0,2);var n=t.length-2,r=t.substr(2,n/2),i=t.substr(2+n/2,n/2),o=new v(r,16),a=new v(i,16);return new nn(e,e.fromBigInteger(o),e.fromBigInteger(a))},nn.prototype.add2D=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;if(this.x.equals(e.x))return this.y.equals(e.y)?this.twice():this.curve.getInfinity();var t=e.x.subtract(this.x),n=e.y.subtract(this.y),r=n.divide(t),i=r.square().subtract(this.x).subtract(e.x),o=r.multiply(this.x.subtract(i)).subtract(this.y);return new nn(this.curve,i,o)},nn.prototype.twice2D=function(){if(this.isInfinity())return this;if(0==this.y.toBigInteger().signum())return this.curve.getInfinity();var e=this.curve.fromBigInteger(v.valueOf(2)),t=this.curve.fromBigInteger(v.valueOf(3)),n=this.x.square().multiply(t).add(this.curve.a).divide(this.y.multiply(e)),r=n.square().subtract(this.x.multiply(e)),i=n.multiply(this.x.subtract(r)).subtract(this.y);return new nn(this.curve,r,i)},nn.prototype.multiply2D=function(e){if(this.isInfinity())return this;if(0==e.signum())return this.curve.getInfinity();var t,n=e,r=n.multiply(new v("3")),i=this.negate(),o=this;for(t=r.bitLength()-2;t>0;--t){o=o.twice();var a=r.testBit(t),s=n.testBit(t);a!=s&&(o=o.add2D(a?this:i))}return o},nn.prototype.isOnCurve=function(){var e=this.getX().toBigInteger(),t=this.getY().toBigInteger(),n=this.curve.getA().toBigInteger(),r=this.curve.getB().toBigInteger(),i=this.curve.getQ(),o=t.multiply(t).mod(i),a=e.multiply(e).multiply(e).add(n.multiply(e)).add(r).mod(i);return o.equals(a)},nn.prototype.toString=function(){return"("+this.getX().toBigInteger().toString()+","+this.getY().toBigInteger().toString()+")"},nn.prototype.validate=function(){var e=this.curve.getQ();if(this.isInfinity())throw new Error("Point is at infinity.");var t=this.getX().toBigInteger(),n=this.getY().toBigInteger();if(t.compareTo(v.ONE)<0||t.compareTo(e.subtract(v.ONE))>0)throw new Error("x coordinate out of bounds");if(n.compareTo(v.ONE)<0||n.compareTo(e.subtract(v.ONE))>0)throw new Error("y coordinate out of bounds");if(!this.isOnCurve())throw new Error("Point is not on the curve.");if(this.multiply(e).isInfinity())throw new Error("Point is not a scalar multiple of G.");return!0};
|
||
/*! Mike Samuel (c) 2009 | code.google.com/p/json-sans-eval
|
||
*/
|
||
var On=function(){var e="(?:-?\\b(?:0|[1-9][0-9]*)(?:\\.[0-9]+)?(?:[eE][+-]?[0-9]+)?\\b)",t='(?:[^\\0-\\x08\\x0a-\\x1f"\\\\]|\\\\(?:["/\\\\bfnrt]|u[0-9A-Fa-f]{4}))',n='(?:"'+t+'*")',r=new RegExp("(?:false|true|null|[\\{\\}\\[\\]]|"+e+"|"+n+")","g"),i=new RegExp("\\\\(?:([^u])|u(.{4}))","g"),o={'"':'"',"/":"/","\\":"\\",b:"\b",f:"\f",n:"\n",r:"\r",t:"\t"};function a(e,t,n){return t?o[t]:String.fromCharCode(parseInt(n,16))}var s=new String(""),l="\\",c=Object.hasOwnProperty;return function(e,t){var n,o,u=e.match(r),d=u[0],h=!1;"{"===d?n={}:"["===d?n=[]:(n=[],h=!0);for(var p=[n],f=1-h,m=u.length;f<m;++f){var g;switch(d=u[f],d.charCodeAt(0)){default:g=p[0],g[o||g.length]=+d,o=void 0;break;case 34:if(d=d.substring(1,d.length-1),-1!==d.indexOf(l)&&(d=d.replace(i,a)),g=p[0],!o){if(!(g instanceof Array)){o=d||s;break}o=g.length}g[o]=d,o=void 0;break;case 91:g=p[0],p.unshift(g[o||g.length]=[]),o=void 0;break;case 93:p.shift();break;case 102:g=p[0],g[o||g.length]=!1,o=void 0;break;case 110:g=p[0],g[o||g.length]=null,o=void 0;break;case 116:g=p[0],g[o||g.length]=!0,o=void 0;break;case 123:g=p[0],p.unshift(g[o||g.length]={}),o=void 0;break;case 125:p.shift();break}}if(h){if(1!==p.length)throw new Error;n=n[0]}else if(p.length)throw new Error;if(t){var v=function(e,n){var r=e[n];if(r&&"object"===typeof r){var i=null;for(var o in r)if(c.call(r,o)&&r!==e){var a=v(r,o);void 0!==a?r[o]=a:(i||(i=[]),i.push(o))}if(i)for(var s=i.length;--s>=0;)delete r[i[s]]}return t.call(e,n,r)};n=v({"":n},"")}return n}}();"undefined"!=typeof Sn&&Sn||(Sn={}),"undefined"!=typeof Sn.asn1&&Sn.asn1||(Sn.asn1={}),Sn.asn1.ASN1Util=new function(){this.integerToByteHex=function(e){var t=e.toString(16);return t.length%2==1&&(t="0"+t),t},this.bigIntToMinTwosComplementsHex=function(e){return Cr(e)},this.getPEMStringFromHex=function(e,t){return Xn(e,t)},this.newObject=function(e){var t=Sn,n=t.asn1,r=n.ASN1Object,i=n.DERBoolean,o=n.DERInteger,a=n.DERBitString,s=n.DEROctetString,l=n.DERNull,c=n.DERObjectIdentifier,u=n.DEREnumerated,d=n.DERUTF8String,h=n.DERNumericString,p=n.DERPrintableString,f=n.DERTeletexString,m=n.DERIA5String,g=n.DERUTCTime,v=n.DERGeneralizedTime,b=n.DERVisibleString,y=n.DERBMPString,w=n.DERSequence,O=n.DERSet,S=n.DERTaggedObject,E=n.ASN1Util.newObject;if(e instanceof n.ASN1Object)return e;var x=Object.keys(e);if(1!=x.length)throw new Error("key of param shall be only one.");var _=x[0];if(-1==":asn1:bool:int:bitstr:octstr:null:oid:enum:utf8str:numstr:prnstr:telstr:ia5str:utctime:gentime:visstr:bmpstr:seq:set:tag:".indexOf(":"+_+":"))throw new Error("undefined key: "+_);if("bool"==_)return new i(e[_]);if("int"==_)return new o(e[_]);if("bitstr"==_)return new a(e[_]);if("octstr"==_)return new s(e[_]);if("null"==_)return new l(e[_]);if("oid"==_)return new c(e[_]);if("enum"==_)return new u(e[_]);if("utf8str"==_)return new d(e[_]);if("numstr"==_)return new h(e[_]);if("prnstr"==_)return new p(e[_]);if("telstr"==_)return new f(e[_]);if("ia5str"==_)return new m(e[_]);if("utctime"==_)return new g(e[_]);if("gentime"==_)return new v(e[_]);if("visstr"==_)return new b(e[_]);if("bmpstr"==_)return new y(e[_]);if("asn1"==_)return new r(e[_]);if("seq"==_){for(var k=e[_],C=[],A=0;A<k.length;A++){var T=E(k[A]);C.push(T)}return new w({array:C})}if("set"==_){for(k=e[_],C=[],A=0;A<k.length;A++){T=E(k[A]);C.push(T)}return new O({array:C})}if("tag"==_){var R=e[_];if("[object Array]"===Object.prototype.toString.call(R)&&3==R.length){var N=E(R[2]);return new S({tag:R[0],explicit:R[1],obj:N})}return new S(R)}},this.jsonToASN1HEX=function(e){var t=this.newObject(e);return t.tohex()}},Sn.asn1.ASN1Util.oidHexToInt=function(e){for(var t="",n=parseInt(e.substr(0,2),16),r=Math.floor(n/40),i=n%40,o=(t=r+"."+i,""),a=2;a<e.length;a+=2){var s=parseInt(e.substr(a,2),16),l=("00000000"+s.toString(2)).slice(-8);if(o+=l.substr(1,7),"0"==l.substr(0,1)){var c=new v(o,2);t=t+"."+c.toString(10),o=""}}return t},Sn.asn1.ASN1Util.oidIntToHex=function(e){var t=function(e){var t=e.toString(16);return 1==t.length&&(t="0"+t),t},n=function(e){var n="",r=new v(e,10),i=r.toString(2),o=7-i.length%7;7==o&&(o=0);for(var a="",s=0;s<o;s++)a+="0";i=a+i;for(s=0;s<i.length-1;s+=7){var l=i.substr(s,7);s!=i.length-7&&(l="1"+l),n+=t(parseInt(l,2))}return n};if(!e.match(/^[0-9.]+$/))throw"malformed oid string: "+e;var r="",i=e.split("."),o=40*parseInt(i[0])+parseInt(i[1]);r+=t(o),i.splice(0,2);for(var a=0;a<i.length;a++)r+=n(i[a]);return r},Sn.asn1.ASN1Object=function(e){var t="";this.params=null,this.getLengthHexFromValue=function(){if("undefined"==typeof this.hV||null==this.hV)throw new Error("this.hV is null or undefined");if(this.hV.length%2==1)throw new Error("value hex must be even length: n="+t.length+",v="+this.hV);var e=this.hV.length/2,n=e.toString(16);if(n.length%2==1&&(n="0"+n),e<128)return n;var r=n.length/2;if(r>15)throw new Error("ASN.1 length too long to represent by 8x: n = "+e.toString(16));var i=128+r;return i.toString(16)+n},this.tohex=function(){return(null==this.hTLV||this.isModified)&&(this.hV=this.getFreshValueHex(),this.hL=this.getLengthHexFromValue(),this.hTLV=this.hT+this.hL+this.hV,this.isModified=!1),this.hTLV},this.getEncodedHex=function(){return this.tohex()},this.getValueHex=function(){return this.tohex(),this.hV},this.getFreshValueHex=function(){return""},this.setByParam=function(e){this.params=e},void 0!=e&&void 0!=e.tlv&&(this.hTLV=e.tlv,this.isModified=!1)},Sn.asn1.DERAbstractString=function(e){Sn.asn1.DERAbstractString.superclass.constructor.call(this);this.getString=function(){return this.s},this.setString=function(e){this.hTLV=null,this.isModified=!0,this.s=e,this.hV=Vn(this.s).toLowerCase()},this.setStringHex=function(e){this.hTLV=null,this.isModified=!0,this.s=null,this.hV=e},this.getFreshValueHex=function(){return this.hV},"undefined"!=typeof e&&("string"==typeof e?this.setString(e):"undefined"!=typeof e.str?this.setString(e.str):"undefined"!=typeof e.hex&&this.setStringHex(e.hex))},Dr(Sn.asn1.DERAbstractString,Sn.asn1.ASN1Object),Sn.asn1.DERAbstractTime=function(e){Sn.asn1.DERAbstractTime.superclass.constructor.call(this);this.localDateToUTC=function(e){var t=e.getTime()+6e4*e.getTimezoneOffset(),n=new Date(t);return n},this.formatDate=function(e,t,n){var r=this.zeroPadding,i=this.localDateToUTC(e),o=String(i.getFullYear());"utc"==t&&(o=o.substr(2,2));var a=r(String(i.getMonth()+1),2),s=r(String(i.getDate()),2),l=r(String(i.getHours()),2),c=r(String(i.getMinutes()),2),u=r(String(i.getSeconds()),2),d=o+a+s+l+c+u;if(!0===n){var h=i.getMilliseconds();if(0!=h){var p=r(String(h),3);p=p.replace(/[0]+$/,""),d=d+"."+p}}return d+"Z"},this.zeroPadding=function(e,t){return e.length>=t?e:new Array(t-e.length+1).join("0")+e},this.setByParam=function(e){this.hV=null,this.hTLV=null,this.params=e},this.getString=function(){},this.setString=function(e){this.hTLV=null,this.isModified=!0,void 0==this.params&&(this.params={}),this.params.str=e},this.setByDate=function(e){this.hTLV=null,this.isModified=!0,void 0==this.params&&(this.params={}),this.params.date=e},this.setByDateValue=function(e,t,n,r,i,o){var a=new Date(Date.UTC(e,t-1,n,r,i,o,0));this.setByDate(a)},this.getFreshValueHex=function(){return this.hV}},Dr(Sn.asn1.DERAbstractTime,Sn.asn1.ASN1Object),Sn.asn1.DERAbstractStructured=function(e){Sn.asn1.DERAbstractString.superclass.constructor.call(this);this.setByASN1ObjectArray=function(e){this.hTLV=null,this.isModified=!0,this.asn1Array=e},this.appendASN1Object=function(e){this.hTLV=null,this.isModified=!0,this.asn1Array.push(e)},this.asn1Array=new Array,"undefined"!=typeof e&&"undefined"!=typeof e.array&&(this.asn1Array=e.array)},Dr(Sn.asn1.DERAbstractStructured,Sn.asn1.ASN1Object),Sn.asn1.DERBoolean=function(e){Sn.asn1.DERBoolean.superclass.constructor.call(this),this.hT="01",this.hTLV=0==e?"010100":"0101ff"},Dr(Sn.asn1.DERBoolean,Sn.asn1.ASN1Object),Sn.asn1.DERInteger=function(e){Sn.asn1.DERInteger.superclass.constructor.call(this),this.hT="02",this.params=null;var t=Cr;this.setByBigInteger=function(e){this.isModified=!0,this.params={bigint:e}},this.setByInteger=function(e){this.isModified=!0,this.params=e},this.setValueHex=function(e){this.isModified=!0,this.params={hex:e}},this.getFreshValueHex=function(){var e=this.params,n=null;if(null==e)throw new Error("value not set");if("object"==typeof e&&void 0!=e.hex)return this.hV=e.hex,this.hV;if("number"==typeof e)n=new v(String(e),10);else if(void 0!=e["int"])n=new v(String(e["int"]),10);else{if(void 0==e.bigint)throw new Error("wrong parameter");n=e.bigint}return this.hV=t(n),this.hV},void 0!=e&&(this.params=e)},Dr(Sn.asn1.DERInteger,Sn.asn1.ASN1Object),Sn.asn1.DERBitString=function(e){if(void 0!==e&&"undefined"!==typeof e.obj){var t=Sn.asn1.ASN1Util.newObject(e.obj);e.hex="00"+t.tohex()}Sn.asn1.DERBitString.superclass.constructor.call(this),this.hT="03",this.setHexValueIncludingUnusedBits=function(e){this.hTLV=null,this.isModified=!0,this.hV=e},this.setUnusedBitsAndHexValue=function(e,t){if(e<0||7<e)throw"unused bits shall be from 0 to 7: u = "+e;var n="0"+e;this.hTLV=null,this.isModified=!0,this.hV=n+t},this.setByBinaryString=function(e){e=e.replace(/0+$/,"");var t=8-e.length%8;8==t&&(t=0),e+="0000000".substr(0,t);for(var n="",r=0;r<e.length-1;r+=8){var i=e.substr(r,8),o=parseInt(i,2).toString(16);1==o.length&&(o="0"+o),n+=o}this.hTLV=null,this.isModified=!0,this.hV="0"+t+n},this.setByBooleanArray=function(e){for(var t="",n=0;n<e.length;n++)1==e[n]?t+="1":t+="0";this.setByBinaryString(t)},this.newFalseArray=function(e){for(var t=new Array(e),n=0;n<e;n++)t[n]=!1;return t},this.getFreshValueHex=function(){return this.hV},"undefined"!=typeof e&&("string"==typeof e&&e.toLowerCase().match(/^[0-9a-f]+$/)?this.setHexValueIncludingUnusedBits(e):"undefined"!=typeof e.hex?this.setHexValueIncludingUnusedBits(e.hex):"undefined"!=typeof e.bin?this.setByBinaryString(e.bin):"undefined"!=typeof e.array&&this.setByBooleanArray(e.array))},Dr(Sn.asn1.DERBitString,Sn.asn1.ASN1Object),Sn.asn1.DEROctetString=function(e){if(void 0!==e&&"undefined"!==typeof e.obj){var t=Sn.asn1.ASN1Util.newObject(e.obj);e.hex=t.tohex()}Sn.asn1.DEROctetString.superclass.constructor.call(this,e),this.hT="04"},Dr(Sn.asn1.DEROctetString,Sn.asn1.DERAbstractString),Sn.asn1.DERNull=function(){Sn.asn1.DERNull.superclass.constructor.call(this),this.hT="05",this.hTLV="0500"},Dr(Sn.asn1.DERNull,Sn.asn1.ASN1Object),Sn.asn1.DERObjectIdentifier=function(e){Sn.asn1.DERObjectIdentifier.superclass.constructor.call(this),this.hT="06",this.setValueHex=function(e){this.hTLV=null,this.isModified=!0,this.s=null,this.hV=e},this.setValueOidString=function(e){var t=xr(e);if(null==t)throw new Error("malformed oid string: "+e);this.hTLV=null,this.isModified=!0,this.s=null,this.hV=t},this.setValueName=function(e){var t=Sn.asn1.x509.OID.name2oid(e);if(""===t)throw new Error("DERObjectIdentifier oidName undefined: "+e);this.setValueOidString(t)},this.setValueNameOrOid=function(e){e.match(/^[0-2].[0-9.]+$/)?this.setValueOidString(e):this.setValueName(e)},this.getFreshValueHex=function(){return this.hV},this.setByParam=function(e){"string"===typeof e?this.setValueNameOrOid(e):void 0!==e.oid?this.setValueNameOrOid(e.oid):void 0!==e.name?this.setValueNameOrOid(e.name):void 0!==e.hex&&this.setValueHex(e.hex)},void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.DERObjectIdentifier,Sn.asn1.ASN1Object),Sn.asn1.DEREnumerated=function(e){Sn.asn1.DEREnumerated.superclass.constructor.call(this),this.hT="0a",this.setByBigInteger=function(e){this.hTLV=null,this.isModified=!0,this.hV=Cr(e)},this.setByInteger=function(e){var t=new v(String(e),10);this.setByBigInteger(t)},this.setValueHex=function(e){this.hV=e},this.getFreshValueHex=function(){return this.hV},"undefined"!=typeof e&&("undefined"!=typeof e["int"]?this.setByInteger(e["int"]):"number"==typeof e?this.setByInteger(e):"undefined"!=typeof e.hex&&this.setValueHex(e.hex))},Dr(Sn.asn1.DEREnumerated,Sn.asn1.ASN1Object),Sn.asn1.DERUTF8String=function(e){Sn.asn1.DERUTF8String.superclass.constructor.call(this,e),this.hT="0c"},Dr(Sn.asn1.DERUTF8String,Sn.asn1.DERAbstractString),Sn.asn1.DERNumericString=function(e){Sn.asn1.DERNumericString.superclass.constructor.call(this,e),this.hT="12"},Dr(Sn.asn1.DERNumericString,Sn.asn1.DERAbstractString),Sn.asn1.DERPrintableString=function(e){Sn.asn1.DERPrintableString.superclass.constructor.call(this,e),this.hT="13"},Dr(Sn.asn1.DERPrintableString,Sn.asn1.DERAbstractString),Sn.asn1.DERTeletexString=function(e){Sn.asn1.DERTeletexString.superclass.constructor.call(this,e),this.hT="14"},Dr(Sn.asn1.DERTeletexString,Sn.asn1.DERAbstractString),Sn.asn1.DERIA5String=function(e){Sn.asn1.DERIA5String.superclass.constructor.call(this,e),this.hT="16"},Dr(Sn.asn1.DERIA5String,Sn.asn1.DERAbstractString),Sn.asn1.DERVisibleString=function(e){Sn.asn1.DERIA5String.superclass.constructor.call(this,e),this.hT="1a"},Dr(Sn.asn1.DERVisibleString,Sn.asn1.DERAbstractString),Sn.asn1.DERBMPString=function(e){Sn.asn1.DERBMPString.superclass.constructor.call(this,e),this.hT="1e"},Dr(Sn.asn1.DERBMPString,Sn.asn1.DERAbstractString),Sn.asn1.DERUTCTime=function(e){Sn.asn1.DERUTCTime.superclass.constructor.call(this,e),this.hT="17",this.params=void 0,this.getFreshValueHex=function(){var e=this.params;if(void 0==this.params&&(e={date:new Date}),"string"==typeof e){if(!e.match(/^[0-9]{12}Z$/)&&!e.match(/^[0-9]{12}\.[0-9]+Z$/))throw new Error("malformed string for UTCTime: "+e);this.hV=Tn(e)}else if(void 0!=e.str)this.hV=Tn(e.str);else if(void 0==e.date&&1==e.millis){var t=new Date;this.hV=Tn(this.formatDate(t,"utc",!0))}else if(void 0!=e.date&&e.date instanceof Date){var n=!0===e.millis;this.hV=Tn(this.formatDate(e.date,"utc",n))}else e instanceof Date&&(this.hV=Tn(this.formatDate(e,"utc")));if(void 0==this.hV)throw new Error("parameter not specified properly for UTCTime");return this.hV},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.DERUTCTime,Sn.asn1.DERAbstractTime),Sn.asn1.DERGeneralizedTime=function(e){Sn.asn1.DERGeneralizedTime.superclass.constructor.call(this,e),this.hT="18",this.params=e,this.getFreshValueHex=function(){var e=this.params;if(void 0==this.params&&(e={date:new Date}),"string"==typeof e){if(!e.match(/^[0-9]{14}Z$/)&&!e.match(/^[0-9]{14}\.[0-9]+Z$/))throw new Error("malformed string for GeneralizedTime: "+e);this.hV=Tn(e)}else if(void 0!=e.str)this.hV=Tn(e.str);else if(void 0==e.date&&1==e.millis){var t=new Date;this.hV=Tn(this.formatDate(t,"gen",!0))}else if(void 0!=e.date&&e.date instanceof Date){var n=!0===e.millis;this.hV=Tn(this.formatDate(e.date,"gen",n))}else e instanceof Date&&(this.hV=Tn(this.formatDate(e,"gen")));if(void 0==this.hV)throw new Error("parameter not specified properly for GeneralizedTime");return this.hV},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.DERGeneralizedTime,Sn.asn1.DERAbstractTime),Sn.asn1.DERSequence=function(e){Sn.asn1.DERSequence.superclass.constructor.call(this,e),this.hT="30",this.getFreshValueHex=function(){for(var e="",t=0;t<this.asn1Array.length;t++){var n=this.asn1Array[t];e+=n.tohex()}return this.hV=e,this.hV}},Dr(Sn.asn1.DERSequence,Sn.asn1.DERAbstractStructured),Sn.asn1.DERSet=function(e){Sn.asn1.DERSet.superclass.constructor.call(this,e),this.hT="31",this.sortFlag=!0,this.getFreshValueHex=function(){for(var e=new Array,t=0;t<this.asn1Array.length;t++){var n=this.asn1Array[t];e.push(n.tohex())}return 1==this.sortFlag&&e.sort(),this.hV=e.join(""),this.hV},"undefined"!=typeof e&&"undefined"!=typeof e.sortflag&&0==e.sortflag&&(this.sortFlag=!1)},Dr(Sn.asn1.DERSet,Sn.asn1.DERAbstractStructured),Sn.asn1.DERTaggedObject=function(e){Sn.asn1.DERTaggedObject.superclass.constructor.call(this);var t=Sn.asn1,n=_n,r=n.getV,i=(n.isASN1HEX,t.ASN1Util.newObject);this.hT="a0",this.hV="",this.isExplicit=!0,this.asn1Object=null,this.params={tag:"a0",explicit:!0},this.setASN1Object=function(e,t,n){this.params={tag:t,explicit:e,obj:n}},this.getFreshValueHex=function(){var e=this.params;if(void 0==e.explicit&&(e.explicit=!0),void 0!=e.tage&&(e.tag=e.tage,e.explicit=!0),void 0!=e.tagi&&(e.tag=e.tagi,e.explicit=!1),void 0!=e.str)this.hV=Vn(e.str);else if(void 0!=e.hex)this.hV=e.hex;else{if(void 0==e.obj)throw new Error("str, hex nor obj not specified");var n;e.obj instanceof t.ASN1Object?n=e.obj.tohex():"object"==typeof e.obj&&(n=i(e.obj).tohex()),e.explicit?this.hV=n:this.hV=r(n,0)}return void 0==e.tag&&(e.tag="a0"),this.hT=e.tag,this.hTLV=null,this.isModified=!0,this.hV},this.setByParam=function(e){this.params=e},void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.DERTaggedObject,Sn.asn1.ASN1Object);var Sn,En,xn,_n=new function(){};function kn(e){for(var t=new Array,n=0;n<e.length;n++)t[n]=e.charCodeAt(n);return t}function Cn(e){for(var t="",n=0;n<e.length;n++)t+=String.fromCharCode(e[n]);return t}function An(e){for(var t="",n=0;n<e.length;n++){var r=e[n].toString(16);1==r.length&&(r="0"+r),t+=r}return t}function Tn(e){return An(kn(e))}function Rn(e){return h(Tn(e))}function Nn(e){return In(h(Tn(e)))}function Pn(e){return Cn(f(Mn(e)))}function In(e){return e=e.replace(/\=/g,""),e=e.replace(/\+/g,"-"),e=e.replace(/\//g,"_"),e}function Mn(e){return e.length%4==2?e+="==":e.length%4==3&&(e+="="),e=e.replace(/-/g,"+"),e=e.replace(/_/g,"/"),e}function Dn(e){return e.length%2==1&&(e="0"+e),In(h(e))}function Ln(e){return p(Mn(e))}function Bn(e){return h(sr(gr(e)))}function $n(e){return decodeURIComponent(lr(p(e)))}function Vn(e){return sr(gr(e)).toLowerCase()}function Fn(e){try{return decodeURIComponent(lr(e))}catch(t){return null}}function jn(e){return Fn(Un(e))}function Un(e){for(var t=e.match(/.{1,2}/g),n=[],r=0;r<t.length;r++){var i=parseInt(t[r],16);161<=i&&i<=191?(n.push("c2"),n.push(t[r])):192<=i&&i<=255?(n.push("c3"),n.push((i-64).toString(16))):n.push(t[r])}return n.join("")}function Gn(e){for(var t="",n=0;n<e.length-1;n+=2)t+=String.fromCharCode(parseInt(e.substr(n,2),16));return t}function Hn(e){for(var t="",n=0;n<e.length;n++)t+=("0"+e.charCodeAt(n).toString(16)).slice(-2);return t}function qn(e){return h(e)}function Qn(e){return zn(qn(e),64)}function zn(e,t){return e=e.replace(new RegExp("(.{"+t+"})","g"),"$1\r\n"),e=e.replace(/\s+$/,""),e}function Kn(e){var t=e.replace(/[^0-9A-Za-z\/+=]*/g,""),n=p(t);return n}function Wn(e,t){return"-----BEGIN "+t+"-----\r\n"+zn(e,64)+"\r\n-----END "+t+"-----\r\n"}function Xn(e,t){return"-----BEGIN "+t+"-----\r\n"+zn(qn(e),64)+"\r\n-----END "+t+"-----\r\n"}function Yn(e,t){if(-1==e.indexOf("-----BEGIN "))throw new Error("can't find PEM header");return void 0!==t?(e=e.replace(new RegExp("^[^]*-----BEGIN "+t+"-----"),""),e=e.replace(new RegExp("-----END "+t+"-----[^]*$"),"")):(e=e.replace(/^[^]*-----BEGIN [^-]+-----/,""),e=e.replace(/-----END [^-]+-----[^]*$/,"")),Kn(e)}function Zn(e){return-1==e.indexOf("-----BEGIN ")||-1==e.indexOf("-----END ")?null:(e=e.replace(/^[\s\S]*?-----BEGIN [^-]+-----/m,""),e=e.replace(/-----END [\s\S]+$/m,""),e=e.replace(/\s+/g,""),e.match(/^[0-9a-zA-Z+/=]+$/)?e:null)}function Jn(e){if(e.length%2!=0)throw"input is not even length";if(null==e.match(/^[0-9A-Fa-f]+$/))throw"input is not hexadecimal";for(var t=new ArrayBuffer(e.length/2),n=new DataView(t),r=0;r<e.length/2;r++)n.setUint8(r,parseInt(e.substr(2*r,2),16));return t}function er(e){for(var t="",n=new DataView(e),r=0;r<e.byteLength;r++)t+=("00"+n.getUint8(r).toString(16)).slice(-2);return t}function tr(e){var t,n,r,i,o,a,s,l,c,u;if(e=ar(e),u=e.match(/^(\d{4})(\d\d)(\d\d)(\d\d)(\d\d)(\d\d)(|\.\d+)Z$/),u)return t=parseInt(u[1]),n=parseInt(u[2])-1,r=parseInt(u[3]),i=parseInt(u[4]),o=parseInt(u[5]),a=parseInt(u[6]),s=0,l=u[7],""!==l&&(c=(l.substr(1)+"00").substr(0,3),s=parseInt(c)),Date.UTC(t,n,r,i,o,a,s);throw new Error("unsupported zulu format: "+e)}function nr(e){var t=new Date(e),n=("0000"+t.getUTCFullYear()).slice(-4),r=("00"+(t.getUTCMonth()+1)).slice(-2),i=("00"+t.getUTCDate()).slice(-2),o=("00"+t.getUTCHours()).slice(-2),a=("00"+t.getUTCMinutes()).slice(-2),s=("00"+t.getUTCSeconds()).slice(-2),l=("000"+t.getUTCMilliseconds()).slice(-3);return l=l.replace(/0+$/,""),l=""!=l?"."+l:l,n+r+i+o+a+s+l+"Z"}function rr(e){return Math.round(tr(e)/1e3)}function ir(e){return new Date(tr(e))}function or(e,t,n){var r,i=e.getUTCFullYear();if(t){if(i<1950||2049<i)throw"not proper year for UTCTime: "+i;r=(""+i).slice(-2)}else r=("000"+i).slice(-4);if(r+=("0"+(e.getUTCMonth()+1)).slice(-2),r+=("0"+e.getUTCDate()).slice(-2),r+=("0"+e.getUTCHours()).slice(-2),r+=("0"+e.getUTCMinutes()).slice(-2),r+=("0"+e.getUTCSeconds()).slice(-2),n){var o=e.getUTCMilliseconds();0!==o&&(o=("00"+o).slice(-3),o=o.replace(/0+$/g,""),r+="."+o)}return r+="Z",r}function ar(e){return e.match(/^[0-9]{12}Z$/)||e.match(/^[0-9]{12}[.][0-9]*Z$/)?e.match(/^[0-4]/)?"20"+e:"19"+e:e}function sr(e){return e.replace(/%/g,"")}function lr(e){return e.replace(/(..)/g,"%$1")}function cr(e){var t="malformed IPv6 address";if(!e.match(/^[0-9A-Fa-f:]+$/))throw t;e=e.toLowerCase();var n=e.split(":").length-1;if(n<2)throw t;var r=":".repeat(7-n+2);e=e.replace("::",r);var i=e.split(":");if(8!=i.length)throw t;for(var o=0;o<8;o++)i[o]=("0000"+i[o]).slice(-4);return i.join("")}function ur(e){if(!e.match(/^[0-9A-Fa-f]{32}$/))throw new Error("malformed IPv6 address: "+e);e=e.toLowerCase();var t=e.match(/.{1,4}/g);t=t.map(function(e){return e.replace(/^0+/,"")}),t=t.map(function(e){return""==e?"0":e}),e=":"+t.join(":")+":";var n=e.match(/:(0:){2,}/g);if(null==n)return e.slice(1,-1);var r=n.sort().slice(-1)[0];return e=e.replace(r.substr(0,r.length-1),":"),"::"!=e.substr(0,2)&&(e=e.substr(1)),"::"!=e.substr(-2,2)&&(e=e.substr(0,e.length-1)),e}function dr(e){var t,n=new Error("malformed hex value");if(!e.match(/^([0-9A-Fa-f][0-9A-Fa-f]){1,}$/))throw n;if(8==e.length)try{return t=parseInt(e.substr(0,2),16)+"."+parseInt(e.substr(2,2),16)+"."+parseInt(e.substr(4,2),16)+"."+parseInt(e.substr(6,2),16),t}catch(r){throw n}else if(16==e.length)try{return dr(e.substr(0,8))+"/"+hr(e.substr(8))}catch(r){throw n}else{if(32==e.length)return ur(e);if(64!=e.length)return e;try{return ur(e.substr(0,32))+"/"+hr(e.substr(32))}catch(r){throw n}}}function hr(e){var t,n=new Error("malformed mask");try{t=new v(e,16).toString(2)}catch(r){throw n}if(!t.match(/^1*0*$/))throw n;return t.replace(/0+$/,"").length}function pr(e){var t=new Error("malformed IP address");if(e=e.toLowerCase(e),!e.match(/^[0-9a-f.:/]+$/))throw t;if(!e.match(/^[0-9.]+$/)){if(e.match(/^[0-9.]+\/[0-9]+$/)){var n=e.split("/");return pr(n[0])+fr(parseInt(n[1]),32)}if(e.match(/^[0-9a-f:]+$/)&&-1!==e.indexOf(":"))return cr(e);if(e.match(/^[0-9a-f:]+\/[0-9]+$/)&&-1!==e.indexOf(":")){n=e.split("/");return cr(n[0])+fr(parseInt(n[1]),128)}throw t}var r=e.split(".");if(4!==r.length)throw t;var i="";try{for(var o=0;o<4;o++){var a=parseInt(r[o]);i+=("0"+a.toString(16)).slice(-2)}return i}catch(s){throw t}}function fr(e,t){if(32==t&&0==e)return"00000000";if(128==t&&0==e)return"00000000000000000000000000000000";var n=Array(e+1).join("1")+Array(t-e+1).join("0");return new v(n,2).toString(16)}function mr(e){function t(e){var t=parseInt(e.substr(0,2),16),n=parseInt(e.substr(2),16);if(0==t&n<128)return String.fromCharCode(n);if(t<8){var r=192|(7&t)<<3|(192&n)>>6,i=128|63&n;return Fn(r.toString(16)+i.toString(16))}r=224|(240&t)>>4,i=128|(15&t)<<2|(192&n)>>6;var o=128|63&n;return Fn(r.toString(16)+i.toString(16)+o.toString(16))}var n=e.match(/.{4}/g),r=n.map(t);return r.join("")}function gr(e){for(var t=encodeURIComponent(e),n="",r=0;r<t.length;r++)"%"==t[r]?(n+=t.substr(r,3),r+=2):n=n+"%"+Tn(t[r]);return n}function vr(e){return e=e.replace(/\r\n/gm,"\n"),e}function br(e){return e=e.replace(/\r\n/gm,"\n"),e=e.replace(/\n/gm,"\r\n"),e}function yr(e){return!(e.length%2!=0||!e.match(/^[0-9a-f]+$/)&&!e.match(/^[0-9A-F]+$/))}function wr(e){return!!e.match(/^[0-9A-Za-z-_.]+$/)}function Or(e){return e.length%2==1?"0"+e:e.substr(0,1)>"7"?"00"+e:e}function Sr(e){e=e.replace(/^\s*\[\s*/,""),e=e.replace(/\s*\]\s*$/,""),e=e.replace(/\s*/g,"");try{var t=e.split(/,/).map(function(e,t,n){var r=parseInt(e);if(r<0||255<r)throw"integer not in range 0-255";var i=("00"+r.toString(16)).slice(-2);return i}).join("");return t}catch(n){throw"malformed integer array string: "+n}}_n.getLblen=function(e,t){if("8"!=e.substr(t+2,1))return 1;var n=parseInt(e.substr(t+3,1));return 0==n?-1:0<n&&n<10?n+1:-2},_n.getL=function(e,t){var n=_n.getLblen(e,t);return n<1?"":e.substr(t+2,2*n)},_n.getVblen=function(e,t){var n,r;return n=_n.getL(e,t),""==n?-1:(r="8"===n.substr(0,1)?new v(n.substr(2),16):new v(n,16),r.intValue())},_n.getVidx=function(e,t){var n=_n.getLblen(e,t);return n<0?n:t+2*(n+1)},_n.getV=function(e,t){var n=_n.getVidx(e,t),r=_n.getVblen(e,t);return e.substr(n,2*r)},_n.getTLV=function(e,t){return e.substr(t,2)+_n.getL(e,t)+_n.getV(e,t)},_n.getTLVblen=function(e,t){return 2+2*_n.getLblen(e,t)+2*_n.getVblen(e,t)},_n.getNextSiblingIdx=function(e,t){var n=_n.getVidx(e,t),r=_n.getVblen(e,t);return n+2*r},_n.getChildIdx=function(e,t){var n,r,i,o=_n,a=[];n=o.getVidx(e,t),r=2*o.getVblen(e,t),"03"==e.substr(t,2)&&(n+=2,r-=2),i=0;var s=n;while(i<=r){var l=o.getTLVblen(e,s);if(i+=l,i<=r&&a.push(s),s+=l,i>=r)break}return a},_n.getNthChildIdx=function(e,t,n){var r=_n.getChildIdx(e,t);return r[n]},_n.getIdxbyList=function(e,t,n,r){var i,o,a=_n;return 0==n.length?void 0!==r&&e.substr(t,2)!==r?-1:t:(i=n.shift(),o=a.getChildIdx(e,t),i>=o.length?-1:a.getIdxbyList(e,o[i],n,r))},_n.getIdxbyListEx=function(e,t,n,r){var i,o,a=_n;if(0==n.length)return void 0!==r&&e.substr(t,2)!==r?-1:t;i=n.shift(),o=a.getChildIdx(e,t);for(var s=0,l=0;l<o.length;l++){var c=e.substr(o[l],2);if("number"==typeof i&&!a.isContextTag(c)&&s==i||"string"==typeof i&&a.isContextTag(c,i))return a.getIdxbyListEx(e,o[l],n,r);a.isContextTag(c)||s++}return-1},_n.getTLVbyList=function(e,t,n,r){var i=_n,o=i.getIdxbyList(e,t,n,r);return-1==o||o>=e.length?null:i.getTLV(e,o)},_n.getTLVbyListEx=function(e,t,n,r){var i=_n,o=i.getIdxbyListEx(e,t,n,r);return-1==o?null:i.getTLV(e,o)},_n.getVbyList=function(e,t,n,r,i){var o,a,s=_n;return o=s.getIdxbyList(e,t,n,r),-1==o||o>=e.length?null:(a=s.getV(e,o),!0===i&&(a=a.substr(2)),a)},_n.getVbyListEx=function(e,t,n,r,i){var o,a,s=_n;return o=s.getIdxbyListEx(e,t,n,r),-1==o?null:(a=s.getV(e,o),"03"==e.substr(o,2)&&!1!==i&&(a=a.substr(2)),a)},_n.getInt=function(e,t,n){void 0==n&&(n=-1);try{var r=e.substr(t,2);if("02"!=r&&"03"!=r)return n;var i=_n.getV(e,t);return"02"==r?parseInt(i,16):Tr(i)}catch(o){return n}},_n.getOID=function(e,t,n){void 0==n&&(n=null);try{if("06"!=e.substr(t,2))return n;var r=_n.getV(e,t);return _r(r)}catch(i){return n}},_n.getOIDName=function(e,t,n){void 0==n&&(n=null);try{var r=_n.getOID(e,t,n);if(r==n)return n;var i=Sn.asn1.x509.OID.oid2name(r);return""==i?r:i}catch(o){return n}},_n.getString=function(e,t,n){void 0==n&&(n=null);try{var r=_n.getV(e,t);return Gn(r)}catch(i){return n}},_n.hextooidstr=function(e){var t=function(e,t){return e.length>=t?e:new Array(t-e.length+1).join("0")+e},n=[],r=e.substr(0,2),i=parseInt(r,16);n[0]=new String(Math.floor(i/40)),n[1]=new String(i%40);for(var o=e.substr(2),a=[],s=0;s<o.length/2;s++)a.push(parseInt(o.substr(2*s,2),16));var l=[],c="";for(s=0;s<a.length;s++)128&a[s]?c+=t((127&a[s]).toString(2),7):(c+=t((127&a[s]).toString(2),7),l.push(new String(parseInt(c,2))),c="");var u=n.join(".");return l.length>0&&(u=u+"."+l.join(".")),u},_n.dump=function(e,t,n,r){var i=_n,o=i.getV,a=i.dump,s=i.getChildIdx,l=e;e instanceof Sn.asn1.ASN1Object&&(l=e.tohex());var c=function(e,t){if(e.length<=2*t)return e;var n=e.substr(0,t)+"..(total "+e.length/2+"bytes).."+e.substr(e.length-t,t);return n};void 0===t&&(t={ommit_long_octet:32}),void 0===n&&(n=0),void 0===r&&(r="");var u=t.ommit_long_octet,d=l.substr(n,2);if("01"==d){var h=o(l,n);return"00"==h?r+"BOOLEAN FALSE\n":r+"BOOLEAN TRUE\n"}if("02"==d){h=o(l,n);return r+"INTEGER "+c(h,u)+"\n"}if("03"==d){h=o(l,n);if(i.isASN1HEX(h.substr(2))){var p=r+"BITSTRING, encapsulates\n";return p+=a(h.substr(2),t,0,r+" "),p}return r+"BITSTRING "+c(h,u)+"\n"}if("04"==d){h=o(l,n);if(i.isASN1HEX(h)){p=r+"OCTETSTRING, encapsulates\n";return p+=a(h,t,0,r+" "),p}return r+"OCTETSTRING "+c(h,u)+"\n"}if("05"==d)return r+"NULL\n";if("06"==d){var f=o(l,n),m=Sn.asn1.ASN1Util.oidHexToInt(f),g=Sn.asn1.x509.OID.oid2name(m),v=m.replace(/\./g," ");return""!=g?r+"ObjectIdentifier "+g+" ("+v+")\n":r+"ObjectIdentifier ("+v+")\n"}if("0a"==d)return r+"ENUMERATED "+parseInt(o(l,n))+"\n";if("0c"==d)return r+"UTF8String '"+Fn(o(l,n))+"'\n";if("13"==d)return r+"PrintableString '"+Fn(o(l,n))+"'\n";if("14"==d)return r+"TeletexString '"+Fn(o(l,n))+"'\n";if("16"==d)return r+"IA5String '"+Fn(o(l,n))+"'\n";if("17"==d)return r+"UTCTime "+Fn(o(l,n))+"\n";if("18"==d)return r+"GeneralizedTime "+Fn(o(l,n))+"\n";if("1a"==d)return r+"VisualString '"+Fn(o(l,n))+"'\n";if("1e"==d)return r+"BMPString '"+mr(o(l,n))+"'\n";if("30"==d){if("3000"==l.substr(n,4))return r+"SEQUENCE {}\n";p=r+"SEQUENCE\n";var b=s(l,n),y=t;if((2==b.length||3==b.length)&&"06"==l.substr(b[0],2)&&"04"==l.substr(b[b.length-1],2)){g=i.oidname(o(l,b[0]));var w=JSON.parse(JSON.stringify(t));w.x509ExtName=g,y=w}for(var O=0;O<b.length;O++)p+=a(l,y,b[O],r+" ");return p}if("31"==d){for(p=r+"SET\n",b=s(l,n),O=0;O<b.length;O++)p+=a(l,t,b[O],r+" ");return p}d=parseInt(d,16);if(0!=(128&d)){var S=31&d;if(0!=(32&d)){for(p=r+"["+S+"]\n",b=s(l,n),O=0;O<b.length;O++)p+=a(l,t,b[O],r+" ");return p}h=o(l,n);if(_n.isASN1HEX(h)){p=r+"["+S+"]\n";return p+=a(h,t,0,r+" "),p}("68747470"==h.substr(0,8)||"subjectAltName"===t.x509ExtName&&2==S)&&(h=Fn(h));p=r+"["+S+"] "+h+"\n";return p}return r+"UNKNOWN("+d+") "+o(l,n)+"\n"},_n.parse=function(e){var t=_n,n=t.parse,r=t.isASN1HEX,i=t.getV,o=t.getTLV,a=t.getChildIdx,s=Sn.asn1,l=s.ASN1Util.oidHexToInt,c=s.x509.OID.oid2name,u=Fn,d=mr,h=jn,p={"0c":"utf8str",12:"numstr",13:"prnstr",14:"telstr",16:"ia5str",17:"utctime",18:"gentime","1a":"visstr","1e":"bmpstr",30:"seq",31:"set"},f=function(e){for(var t=[],r=a(e,0),i=0;i<r.length;i++){var s=r[i],l=o(e,s),c=n(l);t.push(c)}return t},m=e.substr(0,2),g={},v=i(e,0);if("01"==m)return"0101ff"==e?{bool:!0}:{bool:!1};if("02"==m)return{int:{hex:v}};if("03"==m)try{if("00"!=v.substr(0,2))throw"not encap";var b=v.substr(2);if(!r(b))throw"not encap";return{bitstr:{obj:n(b)}}}catch(Dt){var y=null;return v.length<=10&&(y=Nr(v)),null==y?{bitstr:{hex:v}}:{bitstr:{bin:y}}}else if("04"==m)try{if(!r(v))throw"not encap";return{octstr:{obj:n(v)}}}catch(Dt){return{octstr:{hex:v}}}else{if("05"==m)return{null:""};if("06"==m){var w=l(v),O=c(w);return""==O?{oid:w}:{oid:O}}if("0a"==m)return v.length>4?{enum:{hex:v}}:{enum:parseInt(v,16)};if("30"==m||"31"==m)return g[p[m]]=f(e),g;if("14"==m){var S=h(v);return g[p[m]]={str:S},g}if("1e"==m){S=d(v);return g[p[m]]={str:S},g}if(-1!=":0c:12:13:16:17:18:1a:".indexOf(m)){S=u(v);return g[p[m]]={str:S},g}if(m.match(/^8[0-9]$/)){S=u(v);return null==S|""==S||null!=S.match(/[\x00-\x1F\x7F-\x9F]/)||null!=S.match(/[\u0000-\u001F\u0080–\u009F]/)?{tag:{tag:m,explicit:!1,hex:v}}:{tag:{tag:m,explicit:!1,str:S}}}if(!m.match(/^a[0-9]$/)){var E=new Sn.asn1.ASN1Object;E.hV=v;var x=E.getLengthHexFromValue();return{asn1:{tlv:m+x+v}}}try{if(!r(v))throw new Error("not encap");return{tag:{tag:m,explicit:!0,obj:n(v)}}}catch(Dt){return{tag:{tag:m,explicit:!0,hex:v}}}}},_n.isContextTag=function(e,t){var n,r;e=e.toLowerCase();try{n=parseInt(e,16)}catch(o){return-1}if(void 0===t)return 128==(192&n);try{var i=t.match(/^\[[0-9]+\]$/);return null!=i&&(r=parseInt(t.substr(1,t.length-1),10),!(r>31)&&(128==(192&n)&&(31&n)==r))}catch(o){return!1}},_n.isASN1HEX=function(e){var t=_n;if(e.length%2==1)return!1;var n=t.getVblen(e,0),r=e.substr(0,2),i=t.getL(e,0),o=e.length-r.length-i.length;return o==2*n},_n.checkStrictDER=function(e,t,n,r,i){var o=_n;if(void 0===n){if("string"!=typeof e)throw new Error("not hex string");if(e=e.toLowerCase(),!Sn.lang.String.isHex(e))throw new Error("not hex string");n=e.length,r=e.length/2,i=r<128?1:Math.ceil(r.toString(16))+1}var a=o.getL(e,t);if(a.length>2*i)throw new Error("L of TLV too long: idx="+t);var s=o.getVblen(e,t);if(s>r)throw new Error("value of L too long than hex: idx="+t);var l=o.getTLV(e,t),c=l.length-2-o.getL(e,t).length;if(c!==2*s)throw new Error("V string length and L's value not the same:"+c+"/"+2*s);if(0===t&&e.length!=l.length)throw new Error("total length and TLV length unmatch:"+e.length+"!="+l.length);var u=e.substr(t,2);if("02"===u){var d=o.getVidx(e,t);if("00"==e.substr(d,2)&&e.charCodeAt(d+2)<56)throw new Error("not least zeros for DER INTEGER")}if(32&parseInt(u,16)){for(var h=o.getVblen(e,t),p=0,f=o.getChildIdx(e,t),m=0;m<f.length;m++){var g=o.getTLV(e,f[m]);p+=g.length,o.checkStrictDER(e,f[m],n,r,i)}if(2*h!=p)throw new Error("sum of children's TLV length and L unmatch: "+2*h+"!="+p)}},_n.oidname=function(e){var t=Sn.asn1;Sn.lang.String.isHex(e)&&(e=t.ASN1Util.oidHexToInt(e));var n=t.x509.OID.oid2name(e);return""===n&&(n=e),n},"undefined"!=typeof Sn&&Sn||(Sn={}),"undefined"!=typeof Sn.asn1&&Sn.asn1||(Sn.asn1={}),"undefined"!=typeof Sn.asn1.x509&&Sn.asn1.x509||(Sn.asn1.x509={}),Sn.asn1.x509.Certificate=function(e){Sn.asn1.x509.Certificate.superclass.constructor.call(this);var t=Sn,n=t.asn1,r=n.DERBitString,i=n.DERSequence,o=n.x509,a=o.TBSCertificate,s=o.AlgorithmIdentifier;this.params=void 0,this.setByParam=function(e){this.params=e},this.sign=function(){var e=this.params,t=e.sigalg;void 0!=e.sigalg.name&&(t=e.sigalg.name);var n=e.tbsobj.tohex(),r=new Sn.crypto.Signature({alg:t});r.init(e.cakey),r.updateHex(n),e.sighex=r.sign()},this.getPEM=function(){return Xn(this.tohex(),"CERTIFICATE")},this.tohex=function(){var e=this.params;if(void 0!=e.tbsobj&&null!=e.tbsobj||(e.tbsobj=new a(e)),void 0==e.sighex&&void 0!=e.cakey&&this.sign(),void 0==e.sighex)throw new Error("sighex or cakey parameter not defined");var t=[];t.push(e.tbsobj),t.push(new s({name:e.sigalg})),t.push(new r({hex:"00"+e.sighex}));var n=new i({array:t});return n.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&(this.params=e)},Dr(Sn.asn1.x509.Certificate,Sn.asn1.ASN1Object),Sn.asn1.x509.TBSCertificate=function(e){Sn.asn1.x509.TBSCertificate.superclass.constructor.call(this);var t=Sn,n=t.asn1,r=n.x509,i=n.DERTaggedObject,o=n.DERInteger,a=n.DERSequence,s=r.AlgorithmIdentifier,l=r.Time,c=r.X500Name,u=r.Extensions,d=r.SubjectPublicKeyInfo;this.params=null,this.setByParam=function(e){this.params=e},this.tohex=function(){var e=[],t=this.params;if(void 0!=t.version||1!=t.version){var n=2;void 0!=t.version&&(n=t.version-1);var r=new i({obj:new o({int:n})});e.push(r)}e.push(new o(t.serial)),e.push(new s({name:t.sigalg})),e.push(new c(t.issuer)),e.push(new a({array:[new l(t.notbefore),new l(t.notafter)]})),e.push(new c(t.subject)),e.push(new d(Lr.getKey(t.sbjpubkey))),void 0!==t.ext&&t.ext.length>0&&e.push(new i({tag:"a3",obj:new u(t.ext)}));var h=new Sn.asn1.DERSequence({array:e});return h.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.x509.TBSCertificate,Sn.asn1.ASN1Object),Sn.asn1.x509.Extensions=function(e){Sn.asn1.x509.Extensions.superclass.constructor.call(this);var t=Sn,n=t.asn1,r=n.DERSequence,i=n.x509;this.aParam=[],this.setByParam=function(e){this.aParam=e},this.tohex=function(){for(var e=[],t=0;t<this.aParam.length;t++){var n=this.aParam[t],o=n.extname,a=null;if(void 0!=n.extn)a=new i.PrivateExtension(n);else if("subjectKeyIdentifier"==o)a=new i.SubjectKeyIdentifier(n);else if("keyUsage"==o)a=new i.KeyUsage(n);else if("subjectAltName"==o)a=new i.SubjectAltName(n);else if("issuerAltName"==o)a=new i.IssuerAltName(n);else if("basicConstraints"==o)a=new i.BasicConstraints(n);else if("nameConstraints"==o)a=new i.NameConstraints(n);else if("cRLDistributionPoints"==o)a=new i.CRLDistributionPoints(n);else if("certificatePolicies"==o)a=new i.CertificatePolicies(n);else if("policyMappings"==o)a=new i.PolicyMappings(n);else if("policyConstraints"==o)a=new i.PolicyConstraints(n);else if("inhibitAnyPolicy"==o)a=new i.InhibitAnyPolicy(n);else if("authorityKeyIdentifier"==o)a=new i.AuthorityKeyIdentifier(n);else if("extKeyUsage"==o)a=new i.ExtKeyUsage(n);else if("authorityInfoAccess"==o)a=new i.AuthorityInfoAccess(n);else if("cRLNumber"==o)a=new i.CRLNumber(n);else if("cRLReason"==o)a=new i.CRLReason(n);else if("ocspNonce"==o)a=new i.OCSPNonce(n);else if("ocspNoCheck"==o)a=new i.OCSPNoCheck(n);else if("adobeTimeStamp"==o)a=new i.AdobeTimeStamp(n);else{if("subjectDirectoryAttributes"!=o)throw new Error("extension not supported:"+JSON.stringify(n));a=new i.SubjectDirectoryAttributes(n)}null!=a&&e.push(a)}var s=new r({array:e});return s.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.x509.Extensions,Sn.asn1.ASN1Object),Sn.asn1.x509.Extension=function(e){Sn.asn1.x509.Extension.superclass.constructor.call(this);var t=Sn,n=t.asn1,r=n.DERObjectIdentifier,i=n.DEROctetString,o=(n.DERBitString,n.DERBoolean),a=n.DERSequence;this.tohex=function(){var e=new r({oid:this.oid}),t=new i({hex:this.getExtnValueHex()}),n=new Array;n.push(e),this.critical&&n.push(new o),n.push(t);var s=new a({array:n});return s.tohex()},this.getEncodedHex=function(){return this.tohex()},this.critical=!1,void 0!==e&&void 0!==e.critical&&(this.critical=e.critical)},Dr(Sn.asn1.x509.Extension,Sn.asn1.ASN1Object),Sn.asn1.x509.KeyUsage=function(e){Sn.asn1.x509.KeyUsage.superclass.constructor.call(this,e);var t=Error,n={digitalSignature:0,nonRepudiation:1,keyEncipherment:2,dataEncipherment:3,keyAgreement:4,keyCertSign:5,cRLSign:6,encipherOnly:7,decipherOnly:8};this.getExtnValueHex=function(){var e=this.getBinValue();return this.asn1ExtnValue=new Sn.asn1.DERBitString({bin:e}),this.asn1ExtnValue.tohex()},this.getBinValue=function(){var e=this.params;if("object"!=typeof e||"object"!=typeof e.names&&"string"!=typeof e.bin)throw new t("parameter not yet set");if(void 0!=e.names)return Ir(e.names,n);if(void 0!=e.bin)return e.bin;throw new t("parameter not set properly")},this.oid="2.5.29.15",void 0!==e&&(this.params=e)},Dr(Sn.asn1.x509.KeyUsage,Sn.asn1.x509.Extension),Sn.asn1.x509.BasicConstraints=function(e){Sn.asn1.x509.BasicConstraints.superclass.constructor.call(this,e);var t=Sn.asn1,n=t.DERBoolean,r=t.DERInteger,i=t.DERSequence;this.getExtnValueHex=function(){var e=new Array;this.cA&&e.push(new n),this.pathLen>-1&&e.push(new r({int:this.pathLen}));var t=new i({array:e});return this.asn1ExtnValue=t,this.asn1ExtnValue.tohex()},this.oid="2.5.29.19",this.cA=!1,this.pathLen=-1,void 0!==e&&(void 0!==e.cA&&(this.cA=e.cA),void 0!==e.pathLen&&(this.pathLen=e.pathLen))},Dr(Sn.asn1.x509.BasicConstraints,Sn.asn1.x509.Extension),Sn.asn1.x509.CRLDistributionPoints=function(e){Sn.asn1.x509.CRLDistributionPoints.superclass.constructor.call(this,e);var t=Sn,n=t.asn1,r=n.x509;this.getExtnValueHex=function(){return this.asn1ExtnValue.tohex()},this.setByDPArray=function(e){for(var t=[],i=0;i<e.length;i++)if(e[i]instanceof Sn.asn1.ASN1Object)t.push(e[i]);else{var o=new r.DistributionPoint(e[i]);t.push(o)}this.asn1ExtnValue=new n.DERSequence({array:t})},this.setByOneURI=function(e){var t=new r.DistributionPoint({fulluri:e});this.setByDPArray([t])},this.oid="2.5.29.31",void 0!==e&&(void 0!==e.array?this.setByDPArray(e.array):void 0!==e.uri&&this.setByOneURI(e.uri))},Dr(Sn.asn1.x509.CRLDistributionPoints,Sn.asn1.x509.Extension),Sn.asn1.x509.DistributionPoint=function(e){Sn.asn1.x509.DistributionPoint.superclass.constructor.call(this);var t=Sn,n=t.asn1,r=n.x509.DistributionPointName;this.tohex=function(){var e=new n.DERSequence;if(null!=this.asn1DP){var t=new n.DERTaggedObject({explicit:!0,tag:"a0",obj:this.asn1DP});e.appendASN1Object(t)}return this.hTLV=e.tohex(),this.hTLV},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&(void 0!==e.dpobj?this.asn1DP=e.dpobj:void 0!==e.dpname?this.asn1DP=new r(e.dpname):void 0!==e.fulluri&&(this.asn1DP=new r({full:[{uri:e.fulluri}]})))},Dr(Sn.asn1.x509.DistributionPoint,Sn.asn1.ASN1Object),Sn.asn1.x509.DistributionPointName=function(e){Sn.asn1.x509.DistributionPointName.superclass.constructor.call(this);var t=Sn,n=t.asn1,r=n.DERTaggedObject;if(this.tohex=function(){if("full"!=this.type)throw new Error("currently type shall be 'full': "+this.type);return this.asn1Obj=new r({explicit:!1,tag:this.tag,obj:this.asn1V}),this.hTLV=this.asn1Obj.tohex(),this.hTLV},this.getEncodedHex=function(){return this.tohex()},void 0!==e)if(n.x509.GeneralNames.prototype.isPrototypeOf(e))this.type="full",this.tag="a0",this.asn1V=e;else{if(void 0===e.full)throw new Error("This class supports GeneralNames only as argument");this.type="full",this.tag="a0",this.asn1V=new n.x509.GeneralNames(e.full)}},Dr(Sn.asn1.x509.DistributionPointName,Sn.asn1.ASN1Object),Sn.asn1.x509.CertificatePolicies=function(e){Sn.asn1.x509.CertificatePolicies.superclass.constructor.call(this,e);var t=Sn,n=t.asn1,r=n.x509,i=n.DERSequence,o=r.PolicyInformation;this.params=null,this.getExtnValueHex=function(){for(var e=[],t=0;t<this.params.array.length;t++)e.push(new o(this.params.array[t]));var n=new i({array:e});return this.asn1ExtnValue=n,this.asn1ExtnValue.tohex()},this.oid="2.5.29.32",void 0!==e&&(this.params=e)},Dr(Sn.asn1.x509.CertificatePolicies,Sn.asn1.x509.Extension),Sn.asn1.x509.PolicyInformation=function(e){Sn.asn1.x509.PolicyInformation.superclass.constructor.call(this,e);var t=Sn.asn1,n=t.DERSequence,r=t.DERObjectIdentifier,i=t.x509.PolicyQualifierInfo;this.params=null,this.tohex=function(){if(void 0===this.params.policyoid&&void 0===this.params.array)throw new Error("parameter oid and array missing");var e=[new r(this.params.policyoid)];if(void 0!==this.params.array){for(var t=[],o=0;o<this.params.array.length;o++)t.push(new i(this.params.array[o]));t.length>0&&e.push(new n({array:t}))}var a=new n({array:e});return a.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&(this.params=e)},Dr(Sn.asn1.x509.PolicyInformation,Sn.asn1.ASN1Object),Sn.asn1.x509.PolicyQualifierInfo=function(e){Sn.asn1.x509.PolicyQualifierInfo.superclass.constructor.call(this,e);var t=Sn.asn1,n=t.DERSequence,r=t.DERIA5String,i=t.DERObjectIdentifier,o=t.x509.UserNotice;this.params=null,this.tohex=function(){if(void 0!==this.params.cps){var e=new n({array:[new i({oid:"1.3.6.1.5.5.7.2.1"}),new r({str:this.params.cps})]});return e.tohex()}if(void 0!=this.params.unotice){e=new n({array:[new i({oid:"1.3.6.1.5.5.7.2.2"}),new o(this.params.unotice)]});return e.tohex()}},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&(this.params=e)},Dr(Sn.asn1.x509.PolicyQualifierInfo,Sn.asn1.ASN1Object),Sn.asn1.x509.UserNotice=function(e){Sn.asn1.x509.UserNotice.superclass.constructor.call(this,e);var t=Sn.asn1.DERSequence,n=(Sn.asn1.DERInteger,Sn.asn1.x509.DisplayText),r=Sn.asn1.x509.NoticeReference;this.params=null,this.tohex=function(){var e=[];void 0!==this.params.noticeref&&e.push(new r(this.params.noticeref)),void 0!==this.params.exptext&&e.push(new n(this.params.exptext));var i=new t({array:e});return i.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&(this.params=e)},Dr(Sn.asn1.x509.UserNotice,Sn.asn1.ASN1Object),Sn.asn1.x509.NoticeReference=function(e){Sn.asn1.x509.NoticeReference.superclass.constructor.call(this,e);var t=Sn.asn1.DERSequence,n=Sn.asn1.DERInteger,r=Sn.asn1.x509.DisplayText;this.params=null,this.tohex=function(){var e=[];if(void 0!==this.params.org&&e.push(new r(this.params.org)),void 0!==this.params.noticenum){for(var i=[],o=this.params.noticenum,a=0;a<o.length;a++)i.push(new n(o[a]));e.push(new t({array:i}))}if(0==e.length)throw new Error("parameter is empty");var s=new t({array:e});return s.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&(this.params=e)},Dr(Sn.asn1.x509.NoticeReference,Sn.asn1.ASN1Object),Sn.asn1.x509.DisplayText=function(e){Sn.asn1.x509.DisplayText.superclass.constructor.call(this,e),this.hT="0c",void 0!==e&&("ia5"===e.type?this.hT="16":"vis"===e.type?this.hT="1a":"bmp"===e.type&&(this.hT="1e"))},Dr(Sn.asn1.x509.DisplayText,Sn.asn1.DERAbstractString),Sn.asn1.x509.PolicyMappings=function(e){Sn.asn1.x509.PolicyMappings.superclass.constructor.call(this,e);var t=Sn,n=t.asn1,r=(n.x509,n.ASN1Util.newObject);this.params=null,this.getExtnValueHex=function(){for(var e=this.params,t=[],n=0;n<e.array.length;n++){var i=e.array[n];t.push({seq:[{oid:i[0]},{oid:i[1]}]})}return this.asn1ExtnValue=r({seq:t}),this.asn1ExtnValue.tohex()},this.oid="2.5.29.33",void 0!==e&&(this.params=e)},Dr(Sn.asn1.x509.PolicyMappings,Sn.asn1.x509.Extension),Sn.asn1.x509.PolicyConstraints=function(e){Sn.asn1.x509.PolicyConstraints.superclass.constructor.call(this,e);var t=Sn,n=t.asn1,r=(n.x509,n.ASN1Util.newObject);this.params=null,this.getExtnValueHex=function(){var e=this.params,t=[];return void 0!=e.reqexp&&t.push({tag:{tagi:"80",obj:{int:e.reqexp}}}),void 0!=e.inhibit&&t.push({tag:{tagi:"81",obj:{int:e.inhibit}}}),this.asn1ExtnValue=r({seq:t}),this.asn1ExtnValue.tohex()},this.oid="2.5.29.36",void 0!==e&&(this.params=e)},Dr(Sn.asn1.x509.PolicyConstraints,Sn.asn1.x509.Extension),Sn.asn1.x509.InhibitAnyPolicy=function(e){Sn.asn1.x509.InhibitAnyPolicy.superclass.constructor.call(this,e);var t=Sn,n=t.asn1,r=(n.x509,n.ASN1Util.newObject);this.params=null,this.getExtnValueHex=function(){return this.asn1ExtnValue=r({int:this.params.skip}),this.asn1ExtnValue.tohex()},this.oid="2.5.29.54",void 0!==e&&(this.params=e)},Dr(Sn.asn1.x509.InhibitAnyPolicy,Sn.asn1.x509.Extension),Sn.asn1.x509.NameConstraints=function(e){Sn.asn1.x509.NameConstraints.superclass.constructor.call(this,e);var t=Sn,n=t.asn1,r=n.x509,i=n.ASN1Util.newObject,o=r.GeneralSubtree;this.params=null,this.getExtnValueHex=function(){var e=this.params,t=[];if(void 0!=e.permit&&void 0!=e.permit.length){for(var n=[],r=0;r<e.permit.length;r++)n.push(new o(e.permit[r]));t.push({tag:{tagi:"a0",obj:{seq:n}}})}if(void 0!=e.exclude&&void 0!=e.exclude.length){var a=[];for(r=0;r<e.exclude.length;r++)a.push(new o(e.exclude[r]));t.push({tag:{tagi:"a1",obj:{seq:a}}})}return this.asn1ExtnValue=i({seq:t}),this.asn1ExtnValue.tohex()},this.oid="2.5.29.30",void 0!==e&&(this.params=e)},Dr(Sn.asn1.x509.NameConstraints,Sn.asn1.x509.Extension),Sn.asn1.x509.GeneralSubtree=function(e){Sn.asn1.x509.GeneralSubtree.superclass.constructor.call(this);var t=Sn.asn1,n=t.x509,r=n.GeneralName,i=t.ASN1Util.newObject;this.params=null,this.setByParam=function(e){this.params=e},this.tohex=function(){var e=this.params,t=[new r(e)];void 0!=e.min&&t.push({tag:{tagi:"80",obj:{int:e.min}}}),void 0!=e.max&&t.push({tag:{tagi:"81",obj:{int:e.max}}});var n=i({seq:t});return n.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.x509.GeneralSubtree,Sn.asn1.ASN1Object),Sn.asn1.x509.ExtKeyUsage=function(e){Sn.asn1.x509.ExtKeyUsage.superclass.constructor.call(this,e);var t=Sn,n=t.asn1;this.setPurposeArray=function(e){this.asn1ExtnValue=new n.DERSequence;for(var t=0;t<e.length;t++){var r=new n.DERObjectIdentifier(e[t]);this.asn1ExtnValue.appendASN1Object(r)}},this.getExtnValueHex=function(){return this.asn1ExtnValue.tohex()},this.oid="2.5.29.37",void 0!==e&&void 0!==e.array&&this.setPurposeArray(e.array)},Dr(Sn.asn1.x509.ExtKeyUsage,Sn.asn1.x509.Extension),Sn.asn1.x509.AuthorityKeyIdentifier=function(e){Sn.asn1.x509.AuthorityKeyIdentifier.superclass.constructor.call(this,e);var t=Sn,n=t.asn1,r=n.DERTaggedObject,i=n.x509.GeneralNames;t.crypto.Util.isKey;this.asn1KID=null,this.asn1CertIssuer=null,this.asn1CertSN=null,this.getExtnValueHex=function(){var e=new Array;this.asn1KID&&e.push(new r({explicit:!1,tag:"80",obj:this.asn1KID})),this.asn1CertIssuer&&e.push(new r({explicit:!1,tag:"a1",obj:new i([{dn:this.asn1CertIssuer}])})),this.asn1CertSN&&e.push(new r({explicit:!1,tag:"82",obj:this.asn1CertSN}));var t=new n.DERSequence({array:e});return this.asn1ExtnValue=t,this.asn1ExtnValue.tohex()},this.setKIDByParam=function(e){if(void 0!==e.str||void 0!==e.hex)this.asn1KID=new Sn.asn1.DEROctetString(e);else if("object"===typeof e&&Sn.crypto.Util.isKey(e)||"string"===typeof e&&-1!=e.indexOf("BEGIN ")){var t=e;"string"===typeof e&&(t=Lr.getKey(e));var n=Lr.getKeyID(t);this.asn1KID=new Sn.asn1.DEROctetString({hex:n})}},this.setCertIssuerByParam=function(e){void 0!==e.str||void 0!==e.ldapstr||void 0!==e.hex||void 0!==e.certsubject||void 0!==e.certissuer?this.asn1CertIssuer=new Sn.asn1.x509.X500Name(e):"string"===typeof e&&-1!=e.indexOf("BEGIN ")&&-1!=e.indexOf("CERTIFICATE")&&(this.asn1CertIssuer=new Sn.asn1.x509.X500Name({certissuer:e}))},this.setCertSNByParam=function(e){if(void 0!==e.str||void 0!==e.bigint||void 0!==e.hex)this.asn1CertSN=new Sn.asn1.DERInteger(e);else if("string"===typeof e&&-1!=e.indexOf("BEGIN ")&&e.indexOf("CERTIFICATE")){var t=new Fr;t.readCertPEM(e);var n=t.getSerialNumberHex();this.asn1CertSN=new Sn.asn1.DERInteger({hex:n})}},this.oid="2.5.29.35",void 0!==e&&(void 0!==e.kid&&this.setKIDByParam(e.kid),void 0!==e.issuer&&this.setCertIssuerByParam(e.issuer),void 0!==e.sn&&this.setCertSNByParam(e.sn),void 0!==e.issuersn&&"string"===typeof e.issuersn&&-1!=e.issuersn.indexOf("BEGIN ")&&e.issuersn.indexOf("CERTIFICATE")&&(this.setCertSNByParam(e.issuersn),this.setCertIssuerByParam(e.issuersn)))},Dr(Sn.asn1.x509.AuthorityKeyIdentifier,Sn.asn1.x509.Extension),Sn.asn1.x509.SubjectKeyIdentifier=function(e){Sn.asn1.x509.SubjectKeyIdentifier.superclass.constructor.call(this,e);var t=Sn,n=t.asn1,r=n.DEROctetString;this.asn1KID=null,this.getExtnValueHex=function(){return this.asn1ExtnValue=this.asn1KID,this.asn1ExtnValue.tohex()},this.setKIDByParam=function(e){if(void 0!==e.str||void 0!==e.hex)this.asn1KID=new r(e);else if("object"===typeof e&&Sn.crypto.Util.isKey(e)||"string"===typeof e&&-1!=e.indexOf("BEGIN")){var t=e;"string"===typeof e&&(t=Lr.getKey(e));var n=Lr.getKeyID(t);this.asn1KID=new Sn.asn1.DEROctetString({hex:n})}},this.oid="2.5.29.14",void 0!==e&&void 0!==e.kid&&this.setKIDByParam(e.kid)},Dr(Sn.asn1.x509.SubjectKeyIdentifier,Sn.asn1.x509.Extension),Sn.asn1.x509.AuthorityInfoAccess=function(e){Sn.asn1.x509.AuthorityInfoAccess.superclass.constructor.call(this,e),this.setAccessDescriptionArray=function(e){for(var t=new Array,n=Sn,r=n.asn1,i=r.DERSequence,o=r.DERObjectIdentifier,a=r.x509.GeneralName,s=0;s<e.length;s++){var l,c=e[s];if(void 0!==c.ocsp)l=new i({array:[new o({oid:"1.3.6.1.5.5.7.48.1"}),new a({uri:c.ocsp})]});else{if(void 0===c.caissuer)throw new Error("unknown AccessMethod parameter: "+JSON.stringify(c));l=new i({array:[new o({oid:"1.3.6.1.5.5.7.48.2"}),new a({uri:c.caissuer})]})}t.push(l)}this.asn1ExtnValue=new i({array:t})},this.getExtnValueHex=function(){return this.asn1ExtnValue.tohex()},this.oid="1.3.6.1.5.5.7.1.1",void 0!==e&&void 0!==e.array&&this.setAccessDescriptionArray(e.array)},Dr(Sn.asn1.x509.AuthorityInfoAccess,Sn.asn1.x509.Extension),Sn.asn1.x509.SubjectAltName=function(e){Sn.asn1.x509.SubjectAltName.superclass.constructor.call(this,e),this.setNameArray=function(e){this.asn1ExtnValue=new Sn.asn1.x509.GeneralNames(e)},this.getExtnValueHex=function(){return this.asn1ExtnValue.tohex()},this.oid="2.5.29.17",void 0!==e&&void 0!==e.array&&this.setNameArray(e.array)},Dr(Sn.asn1.x509.SubjectAltName,Sn.asn1.x509.Extension),Sn.asn1.x509.IssuerAltName=function(e){Sn.asn1.x509.IssuerAltName.superclass.constructor.call(this,e),this.setNameArray=function(e){this.asn1ExtnValue=new Sn.asn1.x509.GeneralNames(e)},this.getExtnValueHex=function(){return this.asn1ExtnValue.tohex()},this.oid="2.5.29.18",void 0!==e&&void 0!==e.array&&this.setNameArray(e.array)},Dr(Sn.asn1.x509.IssuerAltName,Sn.asn1.x509.Extension),Sn.asn1.x509.SubjectDirectoryAttributes=function(e){Sn.asn1.x509.SubjectDirectoryAttributes.superclass.constructor.call(this,e);var t=Sn.asn1,n=t.DERSequence,r=t.ASN1Util.newObject,i=t.x509.OID.name2oid;this.params=null,this.getExtnValueHex=function(){for(var e=[],t=0;t<this.params.array.length;t++){var o=this.params.array[t];if(void 0==o.attr||void 0==o.array){var a={seq:[{oid:"1.2.3.4"},{set:[{utf8str:"DE"}]}]};if("dateOfBirth"==o.attr)a.seq[0].oid=i(o.attr),a.seq[1].set[0]={gentime:o.str};else if("placeOfBirth"==o.attr)a.seq[0].oid=i(o.attr),a.seq[1].set[0]={utf8str:o.str};else if("gender"==o.attr)a.seq[0].oid=i(o.attr),a.seq[1].set[0]={prnstr:o.str};else if("countryOfCitizenship"==o.attr)a.seq[0].oid=i(o.attr),a.seq[1].set[0]={prnstr:o.str};else{if("countryOfResidence"!=o.attr)throw new Error("unsupported attribute: "+o.attr);a.seq[0].oid=i(o.attr),a.seq[1].set[0]={prnstr:o.str}}e.push(new r(a))}else{var s={seq:[{oid:o.attr},{set:o.array}]};e.push(r(s))}}var l=new n({array:e});return this.asn1ExtnValue=l,this.asn1ExtnValue.tohex()},this.oid="2.5.29.9",void 0!==e&&(this.params=e)},Dr(Sn.asn1.x509.SubjectDirectoryAttributes,Sn.asn1.x509.Extension),Sn.asn1.x509.PrivateExtension=function(e){Sn.asn1.x509.PrivateExtension.superclass.constructor.call(this,e);var t=Sn,n=t.lang.String.isHex,r=t.asn1,i=r.x509.OID.name2oid,o=r.ASN1Util.newObject;this.params=null,this.setByParam=function(e){this.oid=i(e.extname),this.params=e},this.getExtnValueHex=function(){if(void 0==this.params.extname||void 0==this.params.extn)throw new Error("extname or extnhex not specified");var e=this.params.extn;if("string"==typeof e&&n(e))return e;if("object"==typeof e)try{return o(e).tohex()}catch(t){}throw new Error("unsupported extn value")},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.x509.PrivateExtension,Sn.asn1.x509.Extension),Sn.asn1.x509.CRL=function(e){Sn.asn1.x509.CRL.superclass.constructor.call(this);var t=Sn,n=t.asn1,r=n.DERSequence,i=n.DERBitString,o=n.x509,a=o.AlgorithmIdentifier,s=o.TBSCertList;this.params=void 0,this.setByParam=function(e){this.params=e},this.sign=function(){var e=new s(this.params).tohex(),t=new Sn.crypto.Signature({alg:this.params.sigalg});t.init(this.params.cakey),t.updateHex(e);var n=t.sign();this.params.sighex=n},this.getPEM=function(){return Xn(this.tohex(),"X509 CRL")},this.tohex=function(){var e=this.params;if(void 0==e.tbsobj&&(e.tbsobj=new s(e)),void 0==e.sighex&&void 0!=e.cakey&&this.sign(),void 0==e.sighex)throw new Error("sighex or cakey parameter not defined");var t=[];t.push(e.tbsobj),t.push(new a({name:e.sigalg})),t.push(new i({hex:"00"+e.sighex}));var n=new r({array:t});return n.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&(this.params=e)},Dr(Sn.asn1.x509.CRL,Sn.asn1.ASN1Object),Sn.asn1.x509.TBSCertList=function(e){Sn.asn1.x509.TBSCertList.superclass.constructor.call(this);var t=Sn,n=t.asn1,r=n.DERInteger,i=n.DERSequence,o=n.DERTaggedObject,a=(n.DERObjectIdentifier,n.x509),s=a.AlgorithmIdentifier,l=a.Time,c=a.Extensions,u=a.X500Name;this.params=null,this.setByParam=function(e){this.params=e},this.getRevCertSequence=function(){for(var e=[],t=this.params.revcert,n=0;n<t.length;n++){var o=[new r(t[n].sn),new l(t[n].date)];void 0!=t[n].ext&&o.push(new c(t[n].ext)),e.push(new i({array:o}))}return new i({array:e})},this.tohex=function(){var e=[],t=this.params;if(void 0!=t.version){var n=t.version-1,a=new r({int:n});e.push(a)}if(e.push(new s({name:t.sigalg})),e.push(new u(t.issuer)),e.push(new l(t.thisupdate)),void 0!=t.nextupdate&&e.push(new l(t.nextupdate)),void 0!=t.revcert&&e.push(this.getRevCertSequence()),void 0!=t.ext){var d=new c(t.ext);e.push(new o({tag:"a0",explicit:!0,obj:d}))}var h=new i({array:e});return h.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.x509.TBSCertList,Sn.asn1.ASN1Object),Sn.asn1.x509.CRLEntry=function(e){Sn.asn1.x509.CRLEntry.superclass.constructor.call(this);var t=Sn,n=t.asn1;this.setCertSerial=function(e){this.sn=new n.DERInteger(e)},this.setRevocationDate=function(e){this.time=new n.x509.Time(e)},this.tohex=function(){var e=new n.DERSequence({array:[this.sn,this.time]});return this.TLV=e.tohex(),this.TLV},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&(void 0!==e.time&&this.setRevocationDate(e.time),void 0!==e.sn&&this.setCertSerial(e.sn))},Dr(Sn.asn1.x509.CRLEntry,Sn.asn1.ASN1Object),Sn.asn1.x509.CRLNumber=function(e){Sn.asn1.x509.CRLNumber.superclass.constructor.call(this,e),this.params=void 0,this.getExtnValueHex=function(){return this.asn1ExtnValue=new Sn.asn1.DERInteger(this.params.num),this.asn1ExtnValue.tohex()},this.oid="2.5.29.20",void 0!=e&&(this.params=e)},Dr(Sn.asn1.x509.CRLNumber,Sn.asn1.x509.Extension),Sn.asn1.x509.CRLReason=function(e){Sn.asn1.x509.CRLReason.superclass.constructor.call(this,e),this.params=void 0,this.getExtnValueHex=function(){return this.asn1ExtnValue=new Sn.asn1.DEREnumerated(this.params.code),this.asn1ExtnValue.tohex()},this.oid="2.5.29.21",void 0!=e&&(this.params=e)},Dr(Sn.asn1.x509.CRLReason,Sn.asn1.x509.Extension),Sn.asn1.x509.OCSPNonce=function(e){Sn.asn1.x509.OCSPNonce.superclass.constructor.call(this,e),this.params=void 0,this.getExtnValueHex=function(){return this.asn1ExtnValue=new Sn.asn1.DEROctetString(this.params),this.asn1ExtnValue.tohex()},this.oid="1.3.6.1.5.5.7.48.1.2",void 0!=e&&(this.params=e)},Dr(Sn.asn1.x509.OCSPNonce,Sn.asn1.x509.Extension),Sn.asn1.x509.OCSPNoCheck=function(e){Sn.asn1.x509.OCSPNoCheck.superclass.constructor.call(this,e),this.params=void 0,this.getExtnValueHex=function(){return this.asn1ExtnValue=new Sn.asn1.DERNull,this.asn1ExtnValue.tohex()},this.oid="1.3.6.1.5.5.7.48.1.5",void 0!=e&&(this.params=e)},Dr(Sn.asn1.x509.OCSPNoCheck,Sn.asn1.x509.Extension),Sn.asn1.x509.AdobeTimeStamp=function(e){Sn.asn1.x509.AdobeTimeStamp.superclass.constructor.call(this,e);var t=Sn,n=t.asn1,r=n.DERInteger,i=n.DERBoolean,o=n.DERSequence,a=n.x509.GeneralName;this.params=null,this.getExtnValueHex=function(){var e=this.params,t=[new r(1)];return t.push(new a({uri:e.uri})),void 0!=e.reqauth&&t.push(new i(e.reqauth)),this.asn1ExtnValue=new o({array:t}),this.asn1ExtnValue.tohex()},this.oid="1.2.840.113583.1.1.9.1",void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.x509.AdobeTimeStamp,Sn.asn1.x509.Extension),Sn.asn1.x509.X500Name=function(e){Sn.asn1.x509.X500Name.superclass.constructor.call(this),this.asn1Array=[],this.paramArray=[],this.sRule="utf8";var t=Sn,n=t.asn1,r=n.x509,i=r.RDN;this.setByString=function(e,t){void 0!==t&&(this.sRule=t);var n=e.split("/");n.shift();for(var r=[],o=0;o<n.length;o++)if(n[o].match(/^[^=]+=.+$/))r.push(n[o]);else{var a=r.length-1;r[a]=r[a]+"/"+n[o]}for(o=0;o<r.length;o++)this.asn1Array.push(new i({str:r[o],rule:this.sRule}))},this.setByLdapString=function(e,t){void 0!==t&&(this.sRule=t);var n=r.X500Name.ldapToCompat(e);this.setByString(n,t)},this.setByObject=function(e,t){for(var n in void 0!==t&&(this.sRule=t),e)if(e.hasOwnProperty(n)){var r=new i({str:n+"="+e[n],rule:this.sRule});this.asn1Array?this.asn1Array.push(r):this.asn1Array=[r]}},this.setByParam=function(e){if(void 0!==e.rule&&(this.sRule=e.rule),void 0!==e.array)this.paramArray=e.array;else if(void 0!==e.str)this.setByString(e.str);else if(void 0!==e.ldapstr)this.setByLdapString(e.ldapstr);else if(void 0!==e.hex)this.hTLV=e.hex;else if(void 0!==e.certissuer){var t=new Fr;t.readCertPEM(e.certissuer),this.hTLV=t.getIssuerHex()}else if(void 0!==e.certsubject){t=new Fr;t.readCertPEM(e.certsubject),this.hTLV=t.getSubjectHex()}else"object"===typeof e&&void 0===e.certsubject&&void 0===e.certissuer&&this.setByObject(e)},this.tohex=function(){if("string"==typeof this.hTLV)return this.hTLV;if(0==this.asn1Array.length&&this.paramArray.length>0)for(var e=0;e<this.paramArray.length;e++){var t={array:this.paramArray[e]};"utf8"!=this.sRule&&(t.rule=this.sRule);var r=new i(t);this.asn1Array.push(r)}var o=new n.DERSequence({array:this.asn1Array});return this.hTLV=o.tohex(),this.hTLV},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.x509.X500Name,Sn.asn1.ASN1Object),Sn.asn1.x509.X500Name.compatToLDAP=function(e){if("/"!==e.substr(0,1))throw"malformed input";e=e.substr(1);var t=e.split("/");return t.reverse(),t=t.map(function(e){return e.replace(/,/,"\\,")}),t.join(",")},Sn.asn1.x509.X500Name.onelineToLDAP=function(e){return Sn.asn1.x509.X500Name.compatToLDAP(e)},Sn.asn1.x509.X500Name.ldapToCompat=function(e){for(var t=e.split(","),n=!1,r=[],i=0;t.length>0;i++){var o=t.shift();if(!0===n){var a=r.pop(),s=(a+","+o).replace(/\\,/g,",");r.push(s),n=!1}else r.push(o);"\\"===o.substr(-1,1)&&(n=!0)}return r=r.map(function(e){return e.replace("/","\\/")}),r.reverse(),"/"+r.join("/")},Sn.asn1.x509.X500Name.ldapToOneline=function(e){return Sn.asn1.x509.X500Name.ldapToCompat(e)},Sn.asn1.x509.RDN=function(e){Sn.asn1.x509.RDN.superclass.constructor.call(this),this.asn1Array=[],this.paramArray=[],this.sRule="utf8";var t=Sn.asn1.x509.AttributeTypeAndValue;this.setByParam=function(e){void 0!==e.rule&&(this.sRule=e.rule),void 0!==e.str&&this.addByMultiValuedString(e.str),void 0!==e.array&&(this.paramArray=e.array)},this.addByString=function(e){this.asn1Array.push(new Sn.asn1.x509.AttributeTypeAndValue({str:e,rule:this.sRule}))},this.addByMultiValuedString=function(e){for(var t=Sn.asn1.x509.RDN.parseString(e),n=0;n<t.length;n++)this.addByString(t[n])},this.tohex=function(){if(0==this.asn1Array.length&&this.paramArray.length>0)for(var e=0;e<this.paramArray.length;e++){var n=this.paramArray[e];void 0!==n.rule&&"utf8"!=this.sRule&&(n.rule=this.sRule);var r=new t(n);this.asn1Array.push(r)}var i=new Sn.asn1.DERSet({array:this.asn1Array});return this.TLV=i.tohex(),this.TLV},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.x509.RDN,Sn.asn1.ASN1Object),Sn.asn1.x509.RDN.parseString=function(e){for(var t=e.split(/\+/),n=!1,r=[],i=0;t.length>0;i++){var o=t.shift();if(!0===n){var a=r.pop(),s=(a+"+"+o).replace(/\\\+/g,"+");r.push(s),n=!1}else r.push(o);"\\"===o.substr(-1,1)&&(n=!0)}var l=!1,c=[];for(i=0;r.length>0;i++){o=r.shift();if(!0===l){var u=c.pop();if(o.match(/"$/)){s=(u+"+"+o).replace(/^([^=]+)="(.*)"$/,"$1=$2");c.push(s),l=!1}else c.push(u+"+"+o)}else c.push(o);o.match(/^[^=]+="/)&&(l=!0)}return c},Sn.asn1.x509.AttributeTypeAndValue=function(e){Sn.asn1.x509.AttributeTypeAndValue.superclass.constructor.call(this),this.sRule="utf8",this.sType=null,this.sValue=null,this.dsType=null;var t=Sn,n=t.asn1,r=n.DERSequence,i=n.DERUTF8String,o=n.DERPrintableString,a=n.DERTeletexString,s=n.DERIA5String,l=n.DERVisibleString,c=n.DERBMPString,u=t.lang.String.isMail,d=t.lang.String.isPrintable;this.setByParam=function(e){if(void 0!==e.rule&&(this.sRule=e.rule),void 0!==e.ds&&(this.dsType=e.ds),void 0===e.value&&void 0!==e.str){var t=e.str,n=t.match(/^([^=]+)=(.+)$/);if(!n)throw new Error("malformed attrTypeAndValueStr: "+attrTypeAndValueStr);this.sType=n[1],this.sValue=n[2]}else this.sType=e.type,this.sValue=e.value},this.setByString=function(e,t){void 0!==t&&(this.sRule=t);var n=e.match(/^([^=]+)=(.+)$/);if(!n)throw new Error("malformed attrTypeAndValueStr: "+attrTypeAndValueStr);this.setByAttrTypeAndValueStr(n[1],n[2])},this._getDsType=function(){var e=this.sType,t=this.sValue,n=this.sRule;return"prn"===n?"CN"==e&&u(t)?"ia5":d(t)?"prn":"utf8":"utf8"===n?"CN"==e&&u(t)?"ia5":"C"==e?"prn":"utf8":"utf8"},this.setByAttrTypeAndValueStr=function(e,t,n){void 0!==n&&(this.sRule=n),this.sType=e,this.sValue=t},this.getValueObj=function(e,t){if("utf8"==e)return new i({str:t});if("prn"==e)return new o({str:t});if("tel"==e)return new a({str:t});if("ia5"==e)return new s({str:t});if("vis"==e)return new l({str:t});if("bmp"==e)return new c({str:t});throw new Error("unsupported directory string type: type="+e+" value="+t)},this.tohex=function(){null==this.dsType&&(this.dsType=this._getDsType());var e=Sn.asn1.x509.OID.atype2obj(this.sType),t=this.getValueObj(this.dsType,this.sValue),n=new r({array:[e,t]});return this.TLV=n.tohex(),this.TLV},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.x509.AttributeTypeAndValue,Sn.asn1.ASN1Object),Sn.asn1.x509.SubjectPublicKeyInfo=function(e){Sn.asn1.x509.SubjectPublicKeyInfo.superclass.constructor.call(this);var t=Sn,n=t.asn1,r=n.DERInteger,i=n.DERBitString,o=n.DERObjectIdentifier,a=n.DERSequence,s=n.ASN1Util.newObject,l=n.x509,c=l.AlgorithmIdentifier,u=t.crypto;u.ECDSA,u.DSA;this.getASN1Object=function(){if(null==this.asn1AlgId||null==this.asn1SubjPKey)throw"algId and/or subjPubKey not set";var e=new a({array:[this.asn1AlgId,this.asn1SubjPKey]});return e},this.tohex=function(){var e=this.getASN1Object();return this.hTLV=e.tohex(),this.hTLV},this.getEncodedHex=function(){return this.tohex()},this.setPubKey=function(e){try{if(e instanceof Ft){var t=s({seq:[{int:{bigint:e.n}},{int:{int:e.e}}]}),n=t.tohex();this.asn1AlgId=new c({name:"rsaEncryption"}),this.asn1SubjPKey=new i({hex:"00"+n})}}catch(u){}try{if(e instanceof Sn.crypto.ECDSA){var a=new o({name:e.curveName});this.asn1AlgId=new c({name:"ecPublicKey",asn1params:a}),this.asn1SubjPKey=new i({hex:"00"+e.pubKeyHex})}}catch(u){}try{if(e instanceof Sn.crypto.DSA){a=new s({seq:[{int:{bigint:e.p}},{int:{bigint:e.q}},{int:{bigint:e.g}}]});this.asn1AlgId=new c({name:"dsa",asn1params:a});var l=new r({bigint:e.y});this.asn1SubjPKey=new i({hex:"00"+l.tohex()})}}catch(u){}},void 0!==e&&this.setPubKey(e)},Dr(Sn.asn1.x509.SubjectPublicKeyInfo,Sn.asn1.ASN1Object),Sn.asn1.x509.Time=function(e){Sn.asn1.x509.Time.superclass.constructor.call(this);var t=Sn,n=t.asn1,r=n.DERUTCTime,i=n.DERGeneralizedTime;this.params=null,this.type=null,this.setTimeParams=function(e){this.timeParams=e},this.setByParam=function(e){this.params=e},this.getType=function(e){return e.match(/^[0-9]{12}Z$/)?"utc":e.match(/^[0-9]{14}Z$/)?"gen":e.match(/^[0-9]{12}\.[0-9]+Z$/)?"utc":e.match(/^[0-9]{14}\.[0-9]+Z$/)?"gen":null},this.tohex=function(){var e=this.params,t=null;if("string"==typeof e&&(e={str:e}),null==e||!e.str||null!=e.type&&void 0!=e.type||(e.type=this.getType(e.str)),null!=e&&e.str?("utc"==e.type&&(t=new r(e.str)),"gen"==e.type&&(t=new i(e.str))):t="gen"==this.type?new i:new r,null==t)throw new Error("wrong setting for Time");return this.TLV=t.tohex(),this.TLV},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Sn.asn1.x509.Time_bak=function(e){Sn.asn1.x509.Time_bak.superclass.constructor.call(this);var t=Sn,n=t.asn1,r=n.DERUTCTime,i=n.DERGeneralizedTime;this.setTimeParams=function(e){this.timeParams=e},this.tohex=function(){var e=null;return e=null!=this.timeParams?"utc"==this.type?new r(this.timeParams):new i(this.timeParams):"utc"==this.type?new r:new i,this.TLV=e.tohex(),this.TLV},this.getEncodedHex=function(){return this.tohex()},this.type="utc",void 0!==e&&(void 0!==e.type?this.type=e.type:void 0!==e.str&&(e.str.match(/^[0-9]{12}Z$/)&&(this.type="utc"),e.str.match(/^[0-9]{14}Z$/)&&(this.type="gen")),this.timeParams=e)},Dr(Sn.asn1.x509.Time,Sn.asn1.ASN1Object),Sn.asn1.x509.AlgorithmIdentifier=function(e){Sn.asn1.x509.AlgorithmIdentifier.superclass.constructor.call(this),this.nameAlg=null,this.asn1Alg=null,this.asn1Params=null,this.paramEmpty=!1;var t=Sn,n=t.asn1,r=n.x509.AlgorithmIdentifier.PSSNAME2ASN1TLV;if(this.tohex=function(){if(null===this.nameAlg&&null===this.asn1Alg)throw new Error("algorithm not specified");if(null!==this.nameAlg){var e=null;for(var t in r)t===this.nameAlg&&(e=r[t]);if(null!==e)return this.hTLV=e,this.hTLV}null!==this.nameAlg&&null===this.asn1Alg&&(this.asn1Alg=n.x509.OID.name2obj(this.nameAlg));var i=[this.asn1Alg];null!==this.asn1Params&&i.push(this.asn1Params);var o=new n.DERSequence({array:i});return this.hTLV=o.tohex(),this.hTLV},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&(void 0!==e.name&&(this.nameAlg=e.name),void 0!==e.asn1params&&(this.asn1Params=e.asn1params),void 0!==e.paramempty&&(this.paramEmpty=e.paramempty)),null===this.asn1Params&&!1===this.paramEmpty&&null!==this.nameAlg){void 0!==this.nameAlg.name&&(this.nameAlg=this.nameAlg.name);var i=this.nameAlg.toLowerCase();"withdsa"!==i.substr(-7,7)&&"withecdsa"!==i.substr(-9,9)&&(this.asn1Params=new n.DERNull)}},Dr(Sn.asn1.x509.AlgorithmIdentifier,Sn.asn1.ASN1Object),Sn.asn1.x509.AlgorithmIdentifier.PSSNAME2ASN1TLV={SHAwithRSAandMGF1:"300d06092a864886f70d01010a3000",SHA256withRSAandMGF1:"303d06092a864886f70d01010a3030a00d300b0609608648016503040201a11a301806092a864886f70d010108300b0609608648016503040201a203020120",SHA384withRSAandMGF1:"303d06092a864886f70d01010a3030a00d300b0609608648016503040202a11a301806092a864886f70d010108300b0609608648016503040202a203020130",SHA512withRSAandMGF1:"303d06092a864886f70d01010a3030a00d300b0609608648016503040203a11a301806092a864886f70d010108300b0609608648016503040203a203020140"},Sn.asn1.x509.GeneralName=function(e){Sn.asn1.x509.GeneralName.superclass.constructor.call(this);var t=Sn,n=t.asn1,r=n.x509,i=r.X500Name,o=r.OtherName,a=n.DERIA5String,s=(n.DERPrintableString,n.DEROctetString),l=n.DERTaggedObject,c=n.ASN1Object,u=Error;this.params=null,this.setByParam=function(e){this.params=e},this.tohex=function(){var e,t,n=this.params,r=!1;if(void 0!==n.other)e="a0",t=new o(n.other);else if(void 0!==n.rfc822)e="81",t=new a({str:n.rfc822});else if(void 0!==n.dns)e="82",t=new a({str:n.dns});else if(void 0!==n.dn)e="a4",r=!0,t="string"===typeof n.dn?new i({str:n.dn}):n.dn instanceof Sn.asn1.x509.X500Name?n.dn:new i(n.dn);else if(void 0!==n.ldapdn)e="a4",r=!0,t=new i({ldapstr:n.ldapdn});else if(void 0!==n.certissuer||void 0!==n.certsubj){var d,h;e="a4",r=!0;var p=null;if(void 0!==n.certsubj?(d=!1,h=n.certsubj):(d=!0,h=n.certissuer),h.match(/^[0-9A-Fa-f]+$/),-1!=h.indexOf("-----BEGIN ")&&(p=Yn(h)),null==p)throw new Error("certsubj/certissuer not cert");var f,m=new Fr;m.hex=p,f=d?m.getIssuerHex():m.getSubjectHex(),t=new c,t.hTLV=f}else if(void 0!==n.uri)e="86",t=new a({str:n.uri});else{if(void 0===n.ip)throw new u("improper params");var g;e="87";var v=n.ip;try{if(v.match(/^[0-9a-f]+$/)){var b=v.length;if(8!=b&&16!=b&&32!=b&&64!=b)throw"err";g=v}else g=pr(v)}catch(w){throw new u("malformed IP address: "+n.ip+":"+w.message)}t=new s({hex:g})}var y=new l({tag:e,explicit:r,obj:t});return y.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.x509.GeneralName,Sn.asn1.ASN1Object),Sn.asn1.x509.GeneralNames=function(e){Sn.asn1.x509.GeneralNames.superclass.constructor.call(this);var t=Sn,n=t.asn1;this.setByParamArray=function(e){for(var t=0;t<e.length;t++){var r=new n.x509.GeneralName(e[t]);this.asn1Array.push(r)}},this.tohex=function(){var e=new n.DERSequence({array:this.asn1Array});return e.tohex()},this.getEncodedHex=function(){return this.tohex()},this.asn1Array=new Array,"undefined"!=typeof e&&this.setByParamArray(e)},Dr(Sn.asn1.x509.GeneralNames,Sn.asn1.ASN1Object),Sn.asn1.x509.OtherName=function(e){Sn.asn1.x509.OtherName.superclass.constructor.call(this);var t=Sn,n=t.asn1,r=n.DERObjectIdentifier,i=n.DERSequence,o=n.ASN1Util.newObject;this.params=null,this.setByParam=function(e){this.params=e},this.tohex=function(){var e=this.params;if(void 0==e.oid||void 0==e.value)throw new Error("oid or value not specified");var t=new r({oid:e.oid}),n=o({tag:{tag:"a0",explicit:!0,obj:e.value}}),a=new i({array:[t,n]});return a.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.x509.OtherName,Sn.asn1.ASN1Object),Sn.asn1.x509.OID=new function(){var e=Sn.asn1.DERObjectIdentifier;this.name2oidList={"aes128-CBC":"2.16.840.1.101.3.4.1.2","aes256-CBC":"2.16.840.1.101.3.4.1.42",sha1:"1.3.14.3.2.26",sha256:"2.16.840.1.101.3.4.2.1",sha384:"2.16.840.1.101.3.4.2.2",sha512:"2.16.840.1.101.3.4.2.3",sha224:"2.16.840.1.101.3.4.2.4",md5:"1.2.840.113549.2.5",md2:"1.3.14.7.2.2.1",ripemd160:"1.3.36.3.2.1",hmacWithSHA1:"1.2.840.113549.2.7",hmacWithSHA224:"1.2.840.113549.2.8",hmacWithSHA256:"1.2.840.113549.2.9",hmacWithSHA384:"1.2.840.113549.2.10",hmacWithSHA512:"1.2.840.113549.2.11",MD2withRSA:"1.2.840.113549.1.1.2",MD4withRSA:"1.2.840.113549.1.1.3",MD5withRSA:"1.2.840.113549.1.1.4",SHA1withRSA:"1.2.840.113549.1.1.5","pkcs1-MGF":"1.2.840.113549.1.1.8",rsaPSS:"1.2.840.113549.1.1.10",SHA224withRSA:"1.2.840.113549.1.1.14",SHA256withRSA:"1.2.840.113549.1.1.11",SHA384withRSA:"1.2.840.113549.1.1.12",SHA512withRSA:"1.2.840.113549.1.1.13",SHA1withECDSA:"1.2.840.10045.4.1",SHA224withECDSA:"1.2.840.10045.4.3.1",SHA256withECDSA:"1.2.840.10045.4.3.2",SHA384withECDSA:"1.2.840.10045.4.3.3",SHA512withECDSA:"1.2.840.10045.4.3.4",dsa:"1.2.840.10040.4.1",SHA1withDSA:"1.2.840.10040.4.3",SHA224withDSA:"2.16.840.1.101.3.4.3.1",SHA256withDSA:"2.16.840.1.101.3.4.3.2",rsaEncryption:"1.2.840.113549.1.1.1",commonName:"2.5.4.3",countryName:"2.5.4.6",localityName:"2.5.4.7",stateOrProvinceName:"2.5.4.8",streetAddress:"2.5.4.9",organizationName:"2.5.4.10",organizationalUnitName:"2.5.4.11",domainComponent:"0.9.2342.19200300.100.1.25",userId:"0.9.2342.19200300.100.1.1",surname:"2.5.4.4",givenName:"2.5.4.42",title:"2.5.4.12",distinguishedName:"2.5.4.49",emailAddress:"1.2.840.113549.1.9.1",description:"2.5.4.13",businessCategory:"2.5.4.15",postalCode:"2.5.4.17",uniqueIdentifier:"2.5.4.45",organizationIdentifier:"2.5.4.97",jurisdictionOfIncorporationL:"1.3.6.1.4.1.311.60.2.1.1",jurisdictionOfIncorporationSP:"1.3.6.1.4.1.311.60.2.1.2",jurisdictionOfIncorporationC:"1.3.6.1.4.1.311.60.2.1.3",subjectDirectoryAttributes:"2.5.29.9",subjectKeyIdentifier:"2.5.29.14",keyUsage:"2.5.29.15",subjectAltName:"2.5.29.17",issuerAltName:"2.5.29.18",basicConstraints:"2.5.29.19",cRLNumber:"2.5.29.20",cRLReason:"2.5.29.21",nameConstraints:"2.5.29.30",cRLDistributionPoints:"2.5.29.31",certificatePolicies:"2.5.29.32",anyPolicy:"2.5.29.32.0",policyMappings:"2.5.29.33",authorityKeyIdentifier:"2.5.29.35",policyConstraints:"2.5.29.36",extKeyUsage:"2.5.29.37",inhibitAnyPolicy:"2.5.29.54",authorityInfoAccess:"1.3.6.1.5.5.7.1.1",ocsp:"1.3.6.1.5.5.7.48.1",ocspBasic:"1.3.6.1.5.5.7.48.1.1",ocspNonce:"1.3.6.1.5.5.7.48.1.2",ocspNoCheck:"1.3.6.1.5.5.7.48.1.5",caIssuers:"1.3.6.1.5.5.7.48.2",anyExtendedKeyUsage:"2.5.29.37.0",serverAuth:"1.3.6.1.5.5.7.3.1",clientAuth:"1.3.6.1.5.5.7.3.2",codeSigning:"1.3.6.1.5.5.7.3.3",emailProtection:"1.3.6.1.5.5.7.3.4",timeStamping:"1.3.6.1.5.5.7.3.8",ocspSigning:"1.3.6.1.5.5.7.3.9",smtpUTF8Mailbox:"1.3.6.1.5.5.7.8.9",dateOfBirth:"1.3.6.1.5.5.7.9.1",placeOfBirth:"1.3.6.1.5.5.7.9.2",gender:"1.3.6.1.5.5.7.9.3",countryOfCitizenship:"1.3.6.1.5.5.7.9.4",countryOfResidence:"1.3.6.1.5.5.7.9.5",ecPublicKey:"1.2.840.10045.2.1","P-256":"1.2.840.10045.3.1.7",secp256r1:"1.2.840.10045.3.1.7",secp256k1:"1.3.132.0.10",secp384r1:"1.3.132.0.34",secp521r1:"1.3.132.0.35",pkcs5PBES2:"1.2.840.113549.1.5.13",pkcs5PBKDF2:"1.2.840.113549.1.5.12","des-EDE3-CBC":"1.2.840.113549.3.7",data:"1.2.840.113549.1.7.1","signed-data":"1.2.840.113549.1.7.2","enveloped-data":"1.2.840.113549.1.7.3","digested-data":"1.2.840.113549.1.7.5","encrypted-data":"1.2.840.113549.1.7.6","authenticated-data":"1.2.840.113549.1.9.16.1.2",tstinfo:"1.2.840.113549.1.9.16.1.4",signingCertificate:"1.2.840.113549.1.9.16.2.12",timeStampToken:"1.2.840.113549.1.9.16.2.14",signaturePolicyIdentifier:"1.2.840.113549.1.9.16.2.15",etsArchiveTimeStamp:"1.2.840.113549.1.9.16.2.27",signingCertificateV2:"1.2.840.113549.1.9.16.2.47",etsArchiveTimeStampV2:"1.2.840.113549.1.9.16.2.48",extensionRequest:"1.2.840.113549.1.9.14",contentType:"1.2.840.113549.1.9.3",messageDigest:"1.2.840.113549.1.9.4",signingTime:"1.2.840.113549.1.9.5",counterSignature:"1.2.840.113549.1.9.6",archiveTimeStampV3:"0.4.0.1733.2.4",pdfRevocationInfoArchival:"1.2.840.113583.1.1.8",adobeTimeStamp:"1.2.840.113583.1.1.9.1",smimeMailboxLegacy:"2.23.140.1.5.1.1",smimeMailboxMulti:"2.23.140.1.5.1.2",smimeMailboxStrict:"2.23.140.1.5.1.3",smimeOrganizationLegacy:"2.23.140.1.5.2.1",smimeOrganizationMulti:"2.23.140.1.5.2.2",smimeOrganizationStrict:"2.23.140.1.5.2.3",smimeSponsorLegacy:"2.23.140.1.5.3.1",smimeSponsorMulti:"2.23.140.1.5.3.2",smimeSponsorStrict:"2.23.140.1.5.3.3",smimeIndividualLegacy:"2.23.140.1.5.4.1",smimeIndividualMulti:"2.23.140.1.5.4.2",smimeIndividualStrict:"2.23.140.1.5.4.3"},this.atype2oidList={CN:"2.5.4.3",L:"2.5.4.7",ST:"2.5.4.8",O:"2.5.4.10",OU:"2.5.4.11",C:"2.5.4.6",STREET:"2.5.4.9",DC:"0.9.2342.19200300.100.1.25",UID:"0.9.2342.19200300.100.1.1",SN:"2.5.4.4",T:"2.5.4.12",GN:"2.5.4.42",DN:"2.5.4.49",E:"1.2.840.113549.1.9.1",description:"2.5.4.13",businessCategory:"2.5.4.15",postalCode:"2.5.4.17",serialNumber:"2.5.4.5",uniqueIdentifier:"2.5.4.45",organizationIdentifier:"2.5.4.97",jurisdictionOfIncorporationL:"1.3.6.1.4.1.311.60.2.1.1",jurisdictionOfIncorporationSP:"1.3.6.1.4.1.311.60.2.1.2",jurisdictionOfIncorporationC:"1.3.6.1.4.1.311.60.2.1.3"},this.objCache={},this.name2obj=function(t){if("undefined"!=typeof this.objCache[t])return this.objCache[t];if("undefined"==typeof this.name2oidList[t])throw"Name of ObjectIdentifier not defined: "+t;var n=this.name2oidList[t],r=new e({oid:n});return this.objCache[t]=r,r},this.atype2obj=function(t){if(void 0!==this.objCache[t])return this.objCache[t];var n;if(t.match(/^\d+\.\d+\.[0-9.]+$/))n=t;else if(void 0!==this.atype2oidList[t])n=this.atype2oidList[t];else{if(void 0===this.name2oidList[t])throw new Error("AttributeType name undefined: "+t);n=this.name2oidList[t]}var r=new e({oid:n});return this.objCache[t]=r,r},this.registerOIDs=function(e){if(this.checkOIDs(e))for(var t in e)this.name2oidList[t]=e[t]},this.checkOIDs=function(e){try{var t=Object.keys(e);return 0!=t.length&&(t.map(function(e,t,n){var r=this[e];if(!r.match(/^[0-2]\.[0-9.]+$/))throw new Error("value is not OID")},e),!0)}catch(n){return!1}}},Sn.asn1.x509.OID.oid2name=function(e){var t=Sn.asn1.x509.OID.name2oidList;for(var n in t)if(t[n]==e)return n;return""},Sn.asn1.x509.OID.oid2atype=function(e){var t=Sn.asn1.x509.OID.atype2oidList;for(var n in t)if(t[n]==e)return n;return e},Sn.asn1.x509.OID.name2oid=function(e){if(e.match(/^[0-9.]+$/))return e;var t=Sn.asn1.x509.OID.name2oidList;return void 0===t[e]?"":t[e]},Sn.asn1.x509.X509Util={},Sn.asn1.x509.X509Util.newCertPEM=function(e){var t=Sn.asn1.x509,n=(t.TBSCertificate,t.Certificate),r=new n(e);return r.getPEM()},"undefined"!=typeof Sn&&Sn||(Sn={}),"undefined"!=typeof Sn.asn1&&Sn.asn1||(Sn.asn1={}),"undefined"!=typeof Sn.asn1.cms&&Sn.asn1.cms||(Sn.asn1.cms={}),Sn.asn1.cms.Attribute=function(e){var t=Error,n=Sn,r=n.asn1,i=r.DERSequence,o=r.DERSet,a=r.DERObjectIdentifier;this.params=null,this.typeOid=null,this.setByParam=function(e){this.params=e},this.getValueArray=function(){throw new t("not yet implemented abstract")},this.tohex=function(){var e=new a({oid:this.typeOid}),t=new o({array:this.getValueArray()}),n=new i({array:[e,t]});return n.tohex()},this.getEncodedHex=function(){return this.tohex()}},Dr(Sn.asn1.cms.Attribute,Sn.asn1.ASN1Object),Sn.asn1.cms.ContentType=function(e){var t=Sn,n=t.asn1;n.cms.ContentType.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.3",this.getValueArray=function(){var e=new n.DERObjectIdentifier(this.params.type);return[e]},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cms.ContentType,Sn.asn1.cms.Attribute),Sn.asn1.cms.MessageDigest=function(e){var t=Sn,n=t.asn1,r=n.DEROctetString,i=n.cms;i.MessageDigest.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.4",this.getValueArray=function(){var e=new r(this.params);return[e]},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cms.MessageDigest,Sn.asn1.cms.Attribute),Sn.asn1.cms.SigningTime=function(e){var t=Sn,n=t.asn1;n.cms.SigningTime.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.5",this.getValueArray=function(){var e=new n.x509.Time(this.params);return[e]},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cms.SigningTime,Sn.asn1.cms.Attribute),Sn.asn1.cms.SigningCertificate=function(e){var t=Error,n=Sn,r=n.asn1,i=r.DERSequence,o=r.cms,a=o.ESSCertID;n.crypto;o.SigningCertificate.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.16.2.12",this.getValueArray=function(){if(null==this.params||void 0==this.params||void 0==this.params.array)throw new t("parameter 'array' not specified");for(var n=this.params.array,r=[],o=0;o<n.length;o++){var s=n[o];0!=e.hasis||"string"!=typeof s||-1==s.indexOf("-----BEGIN")&&!_n.isASN1HEX(s)||(s={cert:s}),0!=s.hasis&&0==e.hasis&&(s.hasis=!1),r.push(new a(s))}var l=new i({array:r}),c=new i({array:[l]});return[c]},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cms.SigningCertificate,Sn.asn1.cms.Attribute),Sn.asn1.cms.ESSCertID=function(e){Sn.asn1.cms.ESSCertID.superclass.constructor.call(this);var t=Error,n=Sn,r=n.asn1,i=r.DEROctetString,o=r.DERSequence,a=r.cms.IssuerSerial;this.params=null,this.getCertHash=function(e,r){if(void 0!=e.hash)return e.hash;if("string"==typeof e&&-1==e.indexOf("-----BEGIN")&&!_n.isASN1HEX(e))return e;var i,o,a;if("string"==typeof e)i=e;else{if(void 0==e.cert)throw new t("hash nor cert unspecified");i=e.cert}if(o=-1!=i.indexOf("-----BEGIN")?Yn(i):i,"string"==typeof e&&(-1!=e.indexOf("-----BEGIN")?o=Yn(e):_n.isASN1HEX(e)&&(o=e)),void 0!=e.alg)a=e.alg;else{if(void 0==r)throw new t("hash alg unspecified");a=r}return n.crypto.Util.hashHex(o,a)},this.tohex=function(){var e=this.params,t=this.getCertHash(e,"sha1"),n=[];n.push(new i({hex:t})),("string"==typeof e&&-1!=e.indexOf("-----BEGIN")||void 0!=e.cert&&0!=e.hasis||void 0!=e.issuer&&void 0!=e.serial)&&n.push(new a(e));var r=new o({array:n});return r.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cms.ESSCertID,Sn.asn1.ASN1Object),Sn.asn1.cms.SigningCertificateV2=function(e){var t=Error,n=Sn,r=n.asn1,i=r.DERSequence,o=(r.x509,r.cms),a=o.ESSCertIDv2;n.crypto;o.SigningCertificateV2.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.16.2.47",this.getValueArray=function(){if(null==this.params||void 0==this.params||void 0==this.params.array)throw new t("parameter 'array' not specified");for(var n=this.params.array,r=[],o=0;o<n.length;o++){var s=n[o];void 0==e.alg&&0!=e.hasis||"string"!=typeof s||-1==s.indexOf("-----BEGIN")&&!_n.isASN1HEX(s)||(s={cert:s}),void 0==s.alg&&void 0!=e.alg&&(s.alg=e.alg),0!=s.hasis&&0==e.hasis&&(s.hasis=!1),r.push(new a(s))}var l=new i({array:r}),c=new i({array:[l]});return[c]},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cms.SigningCertificateV2,Sn.asn1.cms.Attribute),Sn.asn1.cms.ESSCertIDv2=function(e){Sn.asn1.cms.ESSCertIDv2.superclass.constructor.call(this);Error;var t=Sn,n=t.asn1,r=n.DEROctetString,i=n.DERSequence,o=n.cms.IssuerSerial,a=n.x509.AlgorithmIdentifier;this.params=null,this.tohex=function(){var e=this.params,t=this.getCertHash(e,"sha256"),n=[];void 0!=e.alg&&"sha256"!=e.alg&&n.push(new a({name:e.alg})),n.push(new r({hex:t})),("string"==typeof e&&-1!=e.indexOf("-----BEGIN")||void 0!=e.cert&&0!=e.hasis||void 0!=e.issuer&&void 0!=e.serial)&&n.push(new o(e));var s=new i({array:n});return s.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cms.ESSCertIDv2,Sn.asn1.cms.ESSCertID),Sn.asn1.cms.IssuerSerial=function(e){var t=Error,n=Sn,r=n.asn1,i=r.DERInteger,o=r.DERSequence,a=r.cms,s=r.x509,l=s.GeneralNames,c=Fr;a.IssuerSerial.superclass.constructor.call(this),this.setByParam=function(e){this.params=e},this.tohex=function(){var e,n,r=this.params;if("string"==typeof r&&-1!=r.indexOf("-----BEGIN")||void 0!=r.cert){var a;a=void 0!=r.cert?r.cert:r;var s=new c;s.readCertPEM(a),e=s.getIssuer(),n={hex:s.getSerialNumberHex()}}else{if(void 0==r.issuer||!r.serial)throw new t("cert or issuer and serial parameter not specified");e=r.issuer,n=r.serial}var u=new l([{dn:e}]),d=new i(n),h=new o({array:[u,d]});return h.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cms.IssuerSerial,Sn.asn1.ASN1Object),Sn.asn1.cms.SignerIdentifier=function(e){var t=Sn,n=t.asn1,r=(n.DERInteger,n.DERSequence,n.cms),i=r.IssuerAndSerialNumber,o=r.SubjectKeyIdentifier,a=n.x509;a.X500Name,Error;r.SignerIdentifier.superclass.constructor.call(this),this.params=null,this.tohex=function(){var e=this.params;if("isssn"==e.type){var t=new i(e);return t.tohex()}if("skid"==e.type){var n=new o(e);return n.tohex()}throw new Error("wrong property for isssn or skid")},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cms.SignerIdentifier,Sn.asn1.ASN1Object),Sn.asn1.cms.IssuerAndSerialNumber=function(e){var t=Sn,n=t.asn1,r=n.DERInteger,i=n.DERSequence,o=n.cms,a=n.x509,s=a.X500Name,l=Fr,c=Error;o.IssuerAndSerialNumber.superclass.constructor.call(this),this.params=null,this.tohex=function(){var e,t,n=this.params;if("string"==typeof n&&-1!=n.indexOf("-----BEGIN")||void 0!=n.cert){var o;o=void 0!=n.cert?n.cert:n;var a=new l;a.readCertPEM(o),e=a.getIssuer(),t={hex:a.getSerialNumberHex()}}else{if(void 0==n.issuer||!n.serial)throw new c("cert or issuer and serial parameter not specified");e=n.issuer,t=n.serial}var u=new s(e),d=new r(t),h=new i({array:[u,d]});return h.tohex()},this.getEncodedHex=function(){return this.tohex()},this.setByParam=function(e){this.params=e},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cms.IssuerAndSerialNumber,Sn.asn1.ASN1Object),Sn.asn1.cms.SubjectKeyIdentifier=function(e){var t=Sn,n=t.asn1,r=(n.DERInteger,n.DERSequence,n.ASN1Util.newObject),i=n.cms,o=(i.IssuerAndSerialName,i.SubjectKeyIdentifier,n.x509),a=(o.X500Name,Fr),s=Error;i.SubjectKeyIdentifier.superclass.constructor.call(this),this.tohex=function(){var e,t=this.params;if(void 0==t.cert&&void 0==t.skid)throw new s("property cert nor skid undefined");if(void 0!=t.cert){var n=new a(t.cert),i=n.getExtSubjectKeyIdentifier();e=i.kid.hex}else void 0!=t.skid&&(e=t.skid);var o=r({tag:{tage:"a0",obj:{octstr:{hex:e}}}});return o.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cms.SubjectKeyIdentifier,Sn.asn1.ASN1Object),Sn.asn1.cms.AttributeList=function(e){var t=Error,n=Sn,r=n.asn1,i=r.DERSet,o=r.cms;o.AttributeList.superclass.constructor.call(this),this.params=null,this.hTLV=null,this.setByParam=function(e){this.params=e},this.tohex=function(){var e=this.params;if(null!=this.hTLV)return this.hTLV;var n=!0;void 0!=e.sortflag&&(n=e.sortflag);for(var r=e.array,a=[],s=0;s<r.length;s++){var l=r[s],c=l.attr;if("contentType"==c)a.push(new o.ContentType(l));else if("messageDigest"==c)a.push(new o.MessageDigest(l));else if("signingTime"==c)a.push(new o.SigningTime(l));else if("signingCertificate"==c)a.push(new o.SigningCertificate(l));else if("signingCertificateV2"==c)a.push(new o.SigningCertificateV2(l));else if("signaturePolicyIdentifier"==c)a.push(new Sn.asn1.cades.SignaturePolicyIdentifier(l));else{if("signatureTimeStamp"!=c&&"timeStampToken"!=c)throw new t("unknown attr: "+c);a.push(new Sn.asn1.cades.SignatureTimeStamp(l))}}var u=new i({array:a,sortflag:n});return this.hTLV=u.tohex(),this.hTLV},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cms.AttributeList,Sn.asn1.ASN1Object),Sn.asn1.cms.SignerInfo=function(e){var t=Error,n=Sn,r=n.asn1,i=r.DERInteger,o=r.DEROctetString,a=r.DERSequence,s=r.DERTaggedObject,l=r.cms,c=l.SignerIdentifier,u=l.AttributeList,d=(l.ContentType,l.EncapsulatedContentInfo,l.MessageDigest,l.SignedData,r.x509),h=d.AlgorithmIdentifier,p=n.crypto,f=Lr;l.SignerInfo.superclass.constructor.call(this),this.params=null,this.sign=function(){var e=this.params,t=e.sigalg,n=new u(e.sattrs).tohex(),r=f.getKey(e.signkey),i=new p.Signature({alg:t});i.init(r),i.updateHex(n);var o=i.sign();e.sighex=o},this.tohex=function(){var e=this.params,n=[];if(n.push(new i({int:e.version})),n.push(new c(e.id)),n.push(new h({name:e.hashalg})),void 0!=e.sattrs){var r=new u(e.sattrs);try{n.push(new s({tag:"a0",explicit:!1,obj:r}))}catch(d){throw new t("si sattr error: "+d)}}if(void 0!=e.sigalgfield?n.push(new h({name:e.sigalgfield})):n.push(new h({name:e.sigalg})),void 0==e.sighex&&void 0!=e.signkey&&this.sign(),n.push(new o({hex:e.sighex})),void 0!=e.uattrs){r=new u(e.uattrs);try{n.push(new s({tag:"a1",explicit:!1,obj:r}))}catch(d){throw new t("si uattr error: "+d)}}var l=new a({array:n});return l.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cms.SignerInfo,Sn.asn1.ASN1Object),Sn.asn1.cms.EncapsulatedContentInfo=function(e){var t=Sn,n=t.asn1,r=n.DERTaggedObject,i=n.DERSequence,o=n.DERObjectIdentifier,a=n.DEROctetString,s=n.cms;s.EncapsulatedContentInfo.superclass.constructor.call(this),this.params=null,this.tohex=function(){var e=this.params,t=[];if(t.push(new o(e.type)),void 0!=e.content&&(void 0!=e.content.hex||void 0!=e.content.str)&&1!=e.isDetached){var n=new a(e.content),s=new r({tag:"a0",explicit:!0,obj:n});t.push(s)}var l=new i({array:t});return l.tohex()},this.getEncodedHex=function(){return this.tohex()},this.setByParam=function(e){this.params=e},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cms.EncapsulatedContentInfo,Sn.asn1.ASN1Object),Sn.asn1.cms.ContentInfo=function(e){var t=Sn,n=t.asn1,r=n.DERTaggedObject,i=n.DERSequence,o=n.DERObjectIdentifier,a=n.x509;a.OID.name2obj;Sn.asn1.cms.ContentInfo.superclass.constructor.call(this),this.params=null,this.tohex=function(){var e=this.params,t=[];t.push(new o(e.type));var n=new r({tag:"a0",explicit:!0,obj:e.obj});t.push(n);var a=new i({array:t});return a.tohex()},this.getEncodedHex=function(){return this.tohex()},this.setByParam=function(e){this.params=e},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cms.ContentInfo,Sn.asn1.ASN1Object),Sn.asn1.cms.SignedData=function(e){Error;var t=Sn,n=t.asn1,r=(n.ASN1Object,n.DERInteger),i=n.DERSet,o=n.DERSequence,a=(n.DERTaggedObject,n.cms),s=a.EncapsulatedContentInfo,l=a.SignerInfo,c=a.ContentInfo,u=a.CertificateSet,d=a.RevocationInfoChoices,h=n.x509,p=h.AlgorithmIdentifier;Sn.asn1.cms.SignedData.superclass.constructor.call(this),this.params=null,this.checkAndFixParam=function(){var e=this.params;this._setDigestAlgs(e),this._setContentTypeByEContent(e),this._setMessageDigestByEContent(e),this._setSignerInfoVersion(e),this._setSignedDataVersion(e)},this._setDigestAlgs=function(e){for(var t={},n=e.sinfos,r=0;r<n.length;r++){var i=n[r];t[i.hashalg]=1}e.hashalgs=Object.keys(t).sort()},this._setContentTypeByEContent=function(e){for(var t=e.econtent.type,n=e.sinfos,r=0;r<n.length;r++){var i=n[r],o=this._getAttrParamByName(i,"contentType");o.type=t}},this._setMessageDigestByEContent=function(e){var t=e.econtent,n=(e.econtent.type,t.content.hex);void 0==n&&"data"==t.type&&void 0!=t.content.str&&(n=Hn(t.content.str));for(var r=e.sinfos,i=0;i<r.length;i++){var o=r[i],a=o.hashalg,s=this._getAttrParamByName(o,"messageDigest"),l=Sn.crypto.Util.hashHex(n,a);s.hex=l}},this._getAttrParamByName=function(e,t){for(var n=e.sattrs.array,r=0;r<n.length;r++)if(n[r].attr==t)return n[r]},this._setSignerInfoVersion=function(e){for(var t=e.sinfos,n=0;n<t.length;n++){var r=t[n],i=1;"skid"==r.id.type&&(i=3),r.version=i}},this._setSignedDataVersion=function(e){var t=this._getSignedDataVersion(e);e.version=t},this._getSignedDataVersion=function(e){if(void 0!=e.revinfos)for(var t=e.revinfos,n=0;n<t.length;n++){var r=t[n];if(void 0!=r.ocsp)return 5}var i=e.sinfos;for(n=0;n<i.length;n++){var o=e.sinfos[n];if(3==o.version)return 3}return"data"!=e.econtent.type?3:1},this.tohex=function(){var e=this.params;void 0!=this.getEncodedHexPrepare&&this.getEncodedHexPrepare(),1!=e.fixed&&this.checkAndFixParam();var t=[];t.push(new r({int:e.version}));for(var n=[],a=0;a<e.hashalgs.length;a++){var c=e.hashalgs[a];n.push(new p({name:c}))}t.push(new i({array:n})),t.push(new s(e.econtent)),void 0!=e.certs&&t.push(new u(e.certs)),void 0!=e.revinfos&&t.push(new d(e.revinfos));var h=[];for(a=0;a<e.sinfos.length;a++){var f=e.sinfos[a];h.push(new l(f))}t.push(new i({array:h}));var m=new o({array:t});return m.tohex()},this.getEncodedHex=function(){return this.tohex()},this.getContentInfo=function(){var e=new c({type:"signed-data",obj:this});return e},this.getContentInfoEncodedHex=function(){return this.getContentInfo().tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cms.SignedData,Sn.asn1.ASN1Object),Sn.asn1.cms.CertificateSet=function(e){Sn.asn1.cms.CertificateSet.superclass.constructor.call(this);var t=Error,n=Sn.asn1,r=n.DERTaggedObject,i=n.DERSet,o=n.ASN1Object;this.params=null,this.tohex=function(){var e,n=this.params,a=[];if(n instanceof Array)e=n;else{if(void 0==n.array)throw new t("cert array not specified");e=n.array}for(var s=0;s<e.length;s++){var l=e[s],c=Yn(l),u=new o;u.hTLV=c,a.push(u)}var d={array:a};0==n.sortflag&&(d.sortflag=!1);var h=new i(d),p=new r({tag:"a0",explicit:!1,obj:h});return p.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cms.CertificateSet,Sn.asn1.ASN1Object),Sn.asn1.cms.RevocationInfoChoices=function(e){Sn.asn1.cms.RevocationInfoChoices.superclass.constructor.call(this),this.params=null,this.tohex=function(){var e=this.params;if(!e instanceof Array)throw new Error("params is not array");for(var t=[],n=0;n<e.length;n++)t.push(new Sn.asn1.cms.RevocationInfoChoice(e[n]));var r=Sn.asn1.ASN1Util.newObject({tag:{tagi:"a1",obj:{set:t}}});return r.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cms.RevocationInfoChoices,Sn.asn1.ASN1Object),Sn.asn1.cms.RevocationInfoChoice=function(e){Sn.asn1.cms.RevocationInfoChoice.superclass.constructor.call(this),this.params=null,this.tohex=function(){var e=this.params;if(void 0!=e.crl&&"string"==typeof e.crl){var t=e.crl;return-1!=e.crl.indexOf("-----BEGIN")&&(t=Yn(e.crl)),t}if(void 0!=e.ocsp){var n=Sn.asn1.ASN1Util.newObject({tag:{tagi:"a1",obj:new Sn.asn1.cms.OtherRevocationFormat(e)}});return n.tohex()}throw new Error("property crl or ocsp undefined")},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cms.RevocationInfoChoice,Sn.asn1.ASN1Object),Sn.asn1.cms.OtherRevocationFormat=function(e){Sn.asn1.cms.OtherRevocationFormat.superclass.constructor.call(this);var t=Error,n=Sn,r=n.asn1,i=r.ASN1Util.newObject,o=n.lang.String.isHex;this.params=null,this.tohex=function(){var e=this.params;if(void 0==e.ocsp)throw new t("property ocsp not specified");if(!o(e.ocsp)||!_n.isASN1HEX(e.ocsp))throw new t("ocsp value not ASN.1 hex string");var n=i({seq:[{oid:"1.3.6.1.5.5.7.16.2"},{asn1:{tlv:e.ocsp}}]});return n.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cms.OtherRevocationFormat,Sn.asn1.ASN1Object),Sn.asn1.cms.CMSUtil=new function(){},Sn.asn1.cms.CMSUtil.newSignedData=function(e){return new Sn.asn1.cms.SignedData(e)},Sn.asn1.cms.CMSUtil.verifySignedData=function(e){var t=Sn,n=t.asn1,r=n.cms,i=(r.SignerInfo,r.SignedData,r.SigningTime,r.SigningCertificate,r.SigningCertificateV2,n.cades),o=(i.SignaturePolicyIdentifier,t.lang.String.isHex),a=_n,s=a.getVbyList,l=a.getTLVbyList,c=a.getIdxbyList,u=a.getChildIdx,d=a.getTLV,h=a.oidname,p=t.crypto.Util.hashHex;void 0===e.cms&&o(e.cms);var f=e.cms,m=function(e,t){for(var n,r=3;r<6;r++)if(n=c(e,0,[1,0,r]),void 0!==n){var i=e.substr(n,2);"a0"===i&&(t.certsIdx=n),"a1"===i&&(t.revinfosIdx=n),"31"===i&&(t.signerinfosIdx=n)}},g=function(e,t){var n=t.signerinfosIdx;if(void 0!==n){var r=u(e,n);t.signerInfoIdxList=r;for(var i=0;i<r.length;i++){var o=r[i],a={idx:o};v(e,a),t.signerInfos.push(a)}}},v=function(e,t){var n=t.idx;t.signerid_issuer1=l(e,n,[1,0],"30"),t.signerid_serial1=s(e,n,[1,1],"02"),t.hashalg=h(s(e,n,[2,0],"06"));var r=c(e,n,[3],"a0");t.idxSignedAttrs=r,b(e,t,r);var i=u(e,n),o=i.length;if(o<6)throw"malformed SignerInfo";t.sigalg=h(s(e,n,[o-2,0],"06")),t.sigval=s(e,n,[o-1],"04")},b=function(e,t,n){var r=u(e,n);t.signedAttrIdxList=r;for(var i=0;i<r.length;i++){var o,a=r[i],l=s(e,a,[0],"06");"2a864886f70d010905"===l?(o=Fn(s(e,a,[1,0])),t.saSigningTime=o):"2a864886f70d010904"===l&&(o=s(e,a,[1,0],"04"),t.saMessageDigest=o)}},y=function(e,t){if("2a864886f70d010702"!==s(e,0,[0],"06"))return t;t.cmsType="signedData",t.econtent=s(e,0,[1,0,2,1,0]),m(e,t),t.signerInfos=[],g(e,t)},w=function(e,t){for(var n=t.parse.signerInfos,r=n.length,i=!0,o=0;o<r;o++){var a=n[o];S(e,t,a,o),a.isValid||(i=!1)}t.isValid=i},O=function(e,t,n,r){var i,o=t.parse.certsIdx;if(void 0===t.certs){i=[],t.certkeys=[];for(var a=u(e,o),s=0;s<a.length;s++){var l=d(e,a[s]),c=new Fr;c.readCertHex(l),i[s]=c,t.certkeys[s]=c.getPublicKey()}t.certs=i}else i=t.certs;t.cccc=i.length,t.cccci=a.length;for(s=0;s<i.length;s++){var h=c.getIssuerHex(),p=c.getSerialNumberHex();n.signerid_issuer1===h&&n.signerid_serial1===p&&(n.certkey_idx=s)}},S=function(e,t,n,r){n.verifyDetail={};var i=n.verifyDetail,o=t.parse.econtent,a=n.hashalg,s=n.saMessageDigest;i.validMessageDigest=!1,p(o,a)===s&&(i.validMessageDigest=!0),O(e,t,n,r),i.validSignatureValue=!1;var l=n.sigalg,c="31"+d(e,n.idxSignedAttrs).substr(2);n.signedattrshex=c;var u=t.certs[n.certkey_idx].getPublicKey(),h=new Sn.crypto.Signature({alg:l});h.init(u),h.updateHex(c);var f=h.verify(n.sigval);i.validSignatureValue_isValid=f,!0===f&&(i.validSignatureValue=!0),n.isValid=!1,i.validMessageDigest&&i.validSignatureValue&&(n.isValid=!0)},E={isValid:!1,parse:{}};return y(f,E.parse),w(f,E),E},Sn.asn1.cms.CMSParser=function(){var e=Error,t=Fr,n=new t,r=_n,i=r.getV,o=r.getTLV,a=(r.getIdxbyList,r.getTLVbyList),s=r.getTLVbyListEx,l=r.getVbyList,c=r.getVbyListEx,u=r.getChildIdx;this.getCMSSignedData=function(e){var t=a(e,0,[1,0]),n=this.getSignedData(t);return n},this.getSignedData=function(e){var t=u(e,0),n={},r=i(e,t[0]),a=parseInt(r,16);n.version=a;var l=o(e,t[1]);n.hashalgs=this.getHashAlgArray(l);var c=o(e,t[2]);n.econtent=this.getEContent(c);var d=s(e,0,["[0]"]);null!=d&&(n.certs=this.getCertificateSet(d));s(e,0,["[1]"]);var h=s(e,0,[3]);return n.sinfos=this.getSignerInfos(h),n},this.getHashAlgArray=function(e){for(var n=u(e,0),r=new t,i=[],a=0;a<n.length;a++){var s=o(e,n[a]),l=r.getAlgorithmIdentifierName(s);i.push(l)}return i},this.getEContent=function(e){var t={},n=l(e,0,[0]),r=l(e,0,[1,0]);return t.type=Sn.asn1.x509.OID.oid2name(_n.hextooidstr(n)),t.content={hex:r},t},this.getSignerInfos=function(e){for(var t=[],n=u(e,0),r=0;r<n.length;r++){var i=o(e,n[r]),a=this.getSignerInfo(i);t.push(a)}return t},this.getSignerInfo=function(e){var t={},i=u(e,0),a=r.getInt(e,i[0],-1);-1!=a&&(t.version=a);var l=o(e,i[1]),d=this.getIssuerAndSerialNumber(l);t.id=d;var h=o(e,i[2]),p=n.getAlgorithmIdentifierName(h);t.hashalg=p;var f=s(e,0,["[0]"]);if(null!=f){var m=this.getAttributeList(f);t.sattrs=m}var g=s(e,0,[3]),v=n.getAlgorithmIdentifierName(g);t.sigalg=v;var b=c(e,0,[4]);t.sighex=b;var y=s(e,0,["[1]"]);if(null!=y){var w=this.getAttributeList(y);t.uattrs=w}return t},this.getSignerIdentifier=function(e){if("30"==e.substr(0,2))return this.getIssuerAndSerialNumber(e);throw new Error("SKID of signerIdentifier not supported")},this.getIssuerAndSerialNumber=function(e){var t={type:"isssn"},r=u(e,0),a=o(e,r[0]);t.issuer=n.getX500Name(a);var s=i(e,r[1]);return t.serial={hex:s},t},this.getAttributeList=function(e){for(var t=[],n=u(e,0),r=0;r<n.length;r++){var i=o(e,n[r]),a=this.getAttribute(i);t.push(a)}return{array:t}},this.getAttribute=function(e){var t={},n=u(e,0),i=r.getOID(e,n[0]),a=Sn.asn1.x509.OID.oid2name(i);t.attr=a;var s=o(e,n[1]),l=u(s,0);if(1==l.length)t.valhex=o(s,l[0]);else{for(var c=[],d=0;d<l.length;d++)c.push(o(s,l[d]));t.valhex=c}return"contentType"==a?this.setContentType(t):"messageDigest"==a?this.setMessageDigest(t):"signingTime"==a?this.setSigningTime(t):"signingCertificate"==a?this.setSigningCertificate(t):"signingCertificateV2"==a?this.setSigningCertificateV2(t):"signaturePolicyIdentifier"==a&&this.setSignaturePolicyIdentifier(t),t},this.setContentType=function(e){var t=r.getOIDName(e.valhex,0,null);null!=t&&(e.type=t,delete e.valhex)},this.setSigningTime=function(e){var t=i(e.valhex,0),n=Fn(t);e.str=n,delete e.valhex},this.setMessageDigest=function(e){var t=i(e.valhex,0);e.hex=t,delete e.valhex},this.setSigningCertificate=function(e){var t=u(e.valhex,0);if(t.length>0){for(var n=o(e.valhex,t[0]),r=u(n,0),i=[],a=0;a<r.length;a++){var s=o(n,r[a]),l=this.getESSCertID(s);i.push(l)}e.array=i}if(t.length>1){var c=o(e.valhex,t[1]);e.polhex=c}delete e.valhex},this.setSignaturePolicyIdentifier=function(e){var n=u(e.valhex,0);if(n.length>0){var a=r.getOID(e.valhex,n[0]);e.oid=a}if(n.length>1){var s=new t,l=u(e.valhex,n[1]),c=o(e.valhex,l[0]),d=s.getAlgorithmIdentifierName(c);e.alg=d;var h=i(e.valhex,l[1]);e.hash=h}delete e.valhex},this.setSigningCertificateV2=function(e){var t=u(e.valhex,0);if(t.length>0){for(var n=o(e.valhex,t[0]),r=u(n,0),i=[],a=0;a<r.length;a++){var s=o(n,r[a]),l=this.getESSCertIDv2(s);i.push(l)}e.array=i}if(t.length>1){var c=o(e.valhex,t[1]);e.polhex=c}delete e.valhex},this.getESSCertID=function(e){var t={},n=u(e,0);if(n.length>0){var r=i(e,n[0]);t.hash=r}if(n.length>1){var a=o(e,n[1]),s=this.getIssuerSerial(a);void 0!=s.serial&&(t.serial=s.serial),void 0!=s.issuer&&(t.issuer=s.issuer)}return t},this.getESSCertIDv2=function(t){var r={},a=u(t,0);if(a.length<1||3<a.length)throw new e("wrong number of elements");var s=0;if("30"==t.substr(a[0],2)){var l=o(t,a[0]);r.alg=n.getAlgorithmIdentifierName(l),s++}else r.alg="sha256";var c=i(t,a[s]);if(r.hash=c,a.length>s+1){var d=o(t,a[s+1]),h=this.getIssuerSerial(d);r.issuer=h.issuer,r.serial=h.serial}return r},this.getIssuerSerial=function(e){var t={},r=u(e,0),a=o(e,r[0]),s=n.getGeneralNames(a),l=s[0].dn;t.issuer=l;var c=i(e,r[1]);return t.serial={hex:c},t},this.getCertificateSet=function(e){for(var t=u(e,0),n=[],r=0;r<t.length;r++){var i=o(e,t[r]);if("30"==i.substr(0,2)){var a=Xn(i,"CERTIFICATE");n.push(a)}}return{array:n,sortflag:!1}}},"undefined"!=typeof Sn&&Sn||(Sn={}),"undefined"!=typeof Sn.asn1&&Sn.asn1||(Sn.asn1={}),"undefined"!=typeof Sn.asn1.tsp&&Sn.asn1.tsp||(Sn.asn1.tsp={}),Sn.asn1.tsp.TimeStampToken=function(e){var t=Sn,n=t.asn1,r=n.tsp;r.TimeStampToken.superclass.constructor.call(this),this.params=null,this.getEncodedHexPrepare=function(){var e=new r.TSTInfo(this.params.econtent.content);this.params.econtent.content.hex=e.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.tsp.TimeStampToken,Sn.asn1.cms.SignedData),Sn.asn1.tsp.TSTInfo=function(e){Error;var t=Sn,n=t.asn1,r=n.DERSequence,i=n.DERInteger,o=n.DERBoolean,a=n.DERGeneralizedTime,s=n.DERObjectIdentifier,l=n.DERTaggedObject,c=n.tsp,u=c.MessageImprint,d=c.Accuracy,h=(n.x509.X500Name,n.x509.GeneralName);if(c.TSTInfo.superclass.constructor.call(this),this.dVersion=new i({int:1}),this.dPolicy=null,this.dMessageImprint=null,this.dSerial=null,this.dGenTime=null,this.dAccuracy=null,this.dOrdering=null,this.dNonce=null,this.dTsa=null,this.tohex=function(){var e=[this.dVersion];if(null==this.dPolicy)throw new Error("policy shall be specified.");if(e.push(this.dPolicy),null==this.dMessageImprint)throw new Error("messageImprint shall be specified.");if(e.push(this.dMessageImprint),null==this.dSerial)throw new Error("serialNumber shall be specified.");if(e.push(this.dSerial),null==this.dGenTime)throw new Error("genTime shall be specified.");e.push(this.dGenTime),null!=this.dAccuracy&&e.push(this.dAccuracy),null!=this.dOrdering&&e.push(this.dOrdering),null!=this.dNonce&&e.push(this.dNonce),null!=this.dTsa&&e.push(this.dTsa);var t=new r({array:e});return this.hTLV=t.tohex(),this.hTLV},this.getEncodedHex=function(){return this.tohex()},void 0!==e){if("string"==typeof e.policy){if(!e.policy.match(/^[0-9.]+$/))throw"policy shall be oid like 0.1.4.134";this.dPolicy=new s({oid:e.policy})}void 0!==e.messageImprint&&(this.dMessageImprint=new u(e.messageImprint)),void 0!==e.serial&&(this.dSerial=new i(e.serial)),void 0!==e.genTime&&(this.dGenTime=new a(e.genTime)),void 0!==e.accuracy&&(this.dAccuracy=new d(e.accuracy)),void 0!==e.ordering&&1==e.ordering&&(this.dOrdering=new o),void 0!==e.nonce&&(this.dNonce=new i(e.nonce)),void 0!==e.tsa&&(this.dTsa=new l({tag:"a0",explicit:!0,obj:new h({dn:e.tsa})}))}},Dr(Sn.asn1.tsp.TSTInfo,Sn.asn1.ASN1Object),Sn.asn1.tsp.Accuracy=function(e){var t=Sn,n=t.asn1,r=n.ASN1Util.newObject;n.tsp.Accuracy.superclass.constructor.call(this),this.params=null,this.tohex=function(){var e=this.params,t=[];return void 0!=e.seconds&&"number"==typeof e.seconds&&t.push({int:e.seconds}),void 0!=e.millis&&"number"==typeof e.millis&&t.push({tag:{tagi:"80",obj:{int:e.millis}}}),void 0!=e.micros&&"number"==typeof e.micros&&t.push({tag:{tagi:"81",obj:{int:e.micros}}}),r({seq:t}).tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.tsp.Accuracy,Sn.asn1.ASN1Object),Sn.asn1.tsp.MessageImprint=function(e){var t=Sn,n=t.asn1,r=n.DERSequence,i=n.DEROctetString,o=n.x509,a=o.AlgorithmIdentifier;n.tsp.MessageImprint.superclass.constructor.call(this),this.params=null,this.tohex=function(){var e=this.params,t=new a({name:e.alg}),n=new i({hex:e.hash}),o=new r({array:[t,n]});return o.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.tsp.MessageImprint,Sn.asn1.ASN1Object),Sn.asn1.tsp.TimeStampReq=function(e){var t=Sn,n=t.asn1,r=n.DERSequence,i=n.DERInteger,o=n.DERBoolean,a=(n.ASN1Object,n.DERObjectIdentifier),s=n.tsp,l=s.MessageImprint;s.TimeStampReq.superclass.constructor.call(this),this.params=null,this.tohex=function(){var e=this.params,t=[];t.push(new i({int:1})),e.messageImprint instanceof Sn.asn1.ASN1Object?t.push(e.messageImprint):t.push(new l(e.messageImprint)),void 0!=e.policy&&t.push(new a(e.policy)),void 0!=e.nonce&&t.push(new i(e.nonce)),1==e.certreq&&t.push(new o);var n=new r({array:t});return n.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.tsp.TimeStampReq,Sn.asn1.ASN1Object),Sn.asn1.tsp.TimeStampResp=function(e){var t=Sn,n=t.asn1,r=n.DERSequence,i=(n.ASN1Object,n.tsp),o=i.PKIStatusInfo;i.TimeStampResp.superclass.constructor.call(this),this.params=null,this.tohex=function(){var e=this.params,t=[];if(void 0!=e.econtent||void 0!=e.tst)if(void 0!=e.statusinfo?t.push(new o(e.statusinfo)):t.push(new o("granted")),void 0!=e.econtent)t.push(new i.TimeStampToken(e).getContentInfo());else{if(!(e.tst instanceof n.ASN1Object))throw new Error("improper member tst value");t.push(e.tst)}else{if(void 0==e.statusinfo)throw new Error("parameter for token nor statusinfo not specified");t.push(new o(e.statusinfo))}var a=new r({array:t});return a.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.tsp.TimeStampResp,Sn.asn1.ASN1Object),Sn.asn1.tsp.PKIStatusInfo=function(e){var t=Error,n=Sn,r=n.asn1,i=r.DERSequence,o=r.tsp,a=o.PKIStatus,s=o.PKIFreeText,l=o.PKIFailureInfo;o.PKIStatusInfo.superclass.constructor.call(this),this.params=null,this.tohex=function(){var e=this.params,n=[];if("string"==typeof e)n.push(new a(e));else{if(void 0==e.status)throw new t("property 'status' unspecified");n.push(new a(e.status)),void 0!=e.statusstr&&n.push(new s(e.statusstr)),void 0!=e.failinfo&&n.push(new l(e.failinfo))}var r=new i({array:n});return r.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.tsp.PKIStatusInfo,Sn.asn1.ASN1Object),Sn.asn1.tsp.PKIStatus=function(e){var t=Error,n=Sn,r=n.asn1,i=r.DERInteger,o=r.tsp;o.PKIStatus.superclass.constructor.call(this);var a={granted:0,grantedWithMods:1,rejection:2,waiting:3,revocationWarning:4,revocationNotification:5};this.params=null,this.tohex=function(){var e,n=this.params;if("string"==typeof n)try{e=a[n]}catch(r){throw new t("undefined name: "+n)}else{if("number"!=typeof n)throw new t("unsupported params");e=n}return new i({int:e}).tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.tsp.PKIStatus,Sn.asn1.ASN1Object),Sn.asn1.tsp.PKIFreeText=function(e){var t=Error,n=Sn,r=n.asn1,i=r.DERSequence,o=r.DERUTF8String,a=r.tsp;a.PKIFreeText.superclass.constructor.call(this),this.params=null,this.tohex=function(){var e=this.params;if(!(e instanceof Array))throw new t("wrong params: not array");for(var n=[],r=0;r<e.length;r++)n.push(new o({str:e[r]}));var a=new i({array:n});return a.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.tsp.PKIFreeText,Sn.asn1.ASN1Object),Sn.asn1.tsp.PKIFailureInfo=function(e){var t=Error,n=Sn,r=n.asn1,i=r.DERBitString,o=r.tsp,a=o.PKIFailureInfo,s={badAlg:0,badRequest:2,badDataFormat:5,timeNotAvailable:14,unacceptedPolicy:15,unacceptedExtension:16,addInfoNotAvailable:17,systemFailure:25};a.superclass.constructor.call(this),this.params=null,this.getBinValue=function(){var e=this.params,n=0;if("number"==typeof e&&0<=e&&e<=25){n|=1<<e;for(var r=n.toString(2),i="",o=r.length-1;o>=0;o--)i+=r[o];return i}if("string"==typeof e&&void 0!=s[e])return Ir([e],s);if("object"==typeof e&&void 0!=e.length)return Ir(e,s);throw new t("wrong params")},this.tohex=function(){this.params;var e=this.getBinValue();return new i({bin:e}).tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.tsp.PKIFailureInfo,Sn.asn1.ASN1Object),Sn.asn1.tsp.AbstractTSAAdapter=function(e){this.getTSTHex=function(e,t){throw"not implemented yet"}},Sn.asn1.tsp.SimpleTSAAdapter=function(e){var t=Sn,n=t.asn1,r=n.tsp,i=t.crypto.Util.hashHex;r.SimpleTSAAdapter.superclass.constructor.call(this),this.params=null,this.serial=0,this.getTSTHex=function(e,t){var n=i(e,t);this.params.econtent.content.messageImprint={alg:t,hash:n},this.params.econtent.content.serial={int:this.serial++};var o=Math.floor(1e9*Math.random());this.params.econtent.content.nonce={int:o};var a=new r.TimeStampToken(this.params);return a.getContentInfoEncodedHex()},void 0!==e&&(this.params=e)},Dr(Sn.asn1.tsp.SimpleTSAAdapter,Sn.asn1.tsp.AbstractTSAAdapter),Sn.asn1.tsp.FixedTSAAdapter=function(e){var t=Sn,n=t.asn1,r=n.tsp,i=t.crypto.Util.hashHex;r.FixedTSAAdapter.superclass.constructor.call(this),this.params=null,this.getTSTHex=function(e,t){var n=i(e,t);this.params.econtent.content.messageImprint={alg:t,hash:n};var o=new r.TimeStampToken(this.params);return o.getContentInfoEncodedHex()},void 0!==e&&(this.params=e)},Dr(Sn.asn1.tsp.FixedTSAAdapter,Sn.asn1.tsp.AbstractTSAAdapter),Sn.asn1.tsp.TSPUtil=new function(){},Sn.asn1.tsp.TSPUtil.newTimeStampToken=function(e){return new Sn.asn1.tsp.TimeStampToken(e)},Sn.asn1.tsp.TSPUtil.parseTimeStampReq=function(e){var t=new Sn.asn1.tsp.TSPParser;return t.getTimeStampReq(e)},Sn.asn1.tsp.TSPUtil.parseMessageImprint=function(e){var t=new Sn.asn1.tsp.TSPParser;return t.getMessageImprint(e)},Sn.asn1.tsp.TSPParser=function(){Error;var e=Fr,t=new e,n=_n,r=n.getV,i=n.getTLV,o=n.getIdxbyList,a=(n.getTLVbyListEx,n.getChildIdx),s=["granted","grantedWithMods","rejection","waiting","revocationWarning","revocationNotification"],l={0:"badAlg",2:"badRequest",5:"badDataFormat",14:"timeNotAvailable",15:"unacceptedPolicy",16:"unacceptedExtension",17:"addInfoNotAvailable",25:"systemFailure"};this.getResponse=function(e){var t=a(e,0);if(1==t.length)return this.getPKIStatusInfo(i(e,t[0]));if(t.length>1){var n=this.getPKIStatusInfo(i(e,t[0])),r=i(e,t[1]),o=this.getToken(r);return o.statusinfo=n,o}},this.getToken=function(e){var t=new Sn.asn1.cms.CMSParser,n=t.getCMSSignedData(e);return this.setTSTInfo(n),n},this.setTSTInfo=function(e){var t=e.econtent;if("tstinfo"==t.type){var n=t.content.hex,r=this.getTSTInfo(n);t.content=r}},this.getTSTInfo=function(e){var n={},o=a(e,0),s=r(e,o[1]);n.policy=_r(s);var l=i(e,o[2]);n.messageImprint=this.getMessageImprint(l);var c=r(e,o[3]);n.serial={hex:c};var u=r(e,o[4]);n.genTime={str:Fn(u)};var d=0;if(o.length>5&&"30"==e.substr(o[5],2)){var h=i(e,o[5]);n.accuracy=this.getAccuracy(h),d++}if(o.length>5+d&&"01"==e.substr(o[5+d],2)){var p=r(e,o[5+d]);"ff"==p&&(n.ordering=!0),d++}if(o.length>5+d&&"02"==e.substr(o[5+d],2)){var f=r(e,o[5+d]);n.nonce={hex:f},d++}if(o.length>5+d&&"a0"==e.substr(o[5+d],2)){var m=i(e,o[5+d]);m="30"+m.substr(2),pGeneralNames=t.getGeneralNames(m);var g=pGeneralNames[0].dn;n.tsa=g,d++}if(o.length>5+d&&"a1"==e.substr(o[5+d],2)){var v=i(e,o[5+d]);v="30"+v.substr(2);var b=t.getExtParamArray(v);n.ext=b,d++}return n},this.getAccuracy=function(e){for(var t={},n=a(e,0),i=0;i<n.length;i++){var o=e.substr(n[i],2),s=r(e,n[i]),l=parseInt(s,16);"02"==o?t.seconds=l:"80"==o?t.millis=l:"81"==o&&(t.micros=l)}return t},this.getMessageImprint=function(e){if("30"!=e.substr(0,2))throw new Error("head of messageImprint hex shall be x30");var t={},i=(a(e,0),o(e,0,[0,0])),s=r(e,i),l=n.hextooidstr(s),c=Sn.asn1.x509.OID.oid2name(l);if(""==c)throw new Error("hashAlg name undefined: "+l);var u=c,d=o(e,0,[1]);return t.alg=u,t.hash=r(e,d),t},this.getPKIStatusInfo=function(e){var t={},n=a(e,0),o=0;try{var l=r(e,n[0]),c=parseInt(l,16);t.status=s[c]}catch(h){}if(n.length>1&&"30"==e.substr(n[1],2)){var u=i(e,n[1]);t.statusstr=this.getPKIFreeText(u),o++}if(n.length>o&&"03"==e.substr(n[1+o],2)){var d=i(e,n[1+o]);t.failinfo=this.getPKIFailureInfo(d)}return t},this.getPKIFreeText=function(e){for(var t=[],r=a(e,0),i=0;i<r.length;i++)t.push(n.getString(e,r[i]));return t},this.getPKIFailureInfo=function(e){var t=n.getInt(e,0);return void 0!=l[t]?l[t]:t},this.getTimeStampReq=function(e){var t={certreq:!1},o=a(e,0);if(o.length<2)throw new Error("TimeStampReq must have at least 2 items");var s=i(e,o[1]);t.messageImprint=Sn.asn1.tsp.TSPUtil.parseMessageImprint(s);for(var l=2;l<o.length;l++){var c=o[l],u=e.substr(c,2);if("06"==u){var d=r(e,c);t.policy=n.hextooidstr(d)}"02"==u&&(t.nonce=r(e,c)),"01"==u&&(t.certreq=!0)}return t}},"undefined"!=typeof Sn&&Sn||(Sn={}),"undefined"!=typeof Sn.asn1&&Sn.asn1||(Sn.asn1={}),"undefined"!=typeof Sn.asn1.cades&&Sn.asn1.cades||(Sn.asn1.cades={}),Sn.asn1.cades.SignaturePolicyIdentifier=function(e){var t=Sn,n=t.asn1,r=n.cades,i=r.SignaturePolicyId;r.SignaturePolicyIdentifier.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.16.2.15",this.params=null,this.getValueArray=function(){return[new i(this.params)]},this.setByParam=function(e){this.params=e},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cades.SignaturePolicyIdentifier,Sn.asn1.cms.Attribute),Sn.asn1.cades.SignaturePolicyId=function(e){var t=Sn,n=t.asn1,r=n.DERSequence,i=n.DERObjectIdentifier,o=n.x509,a=(o.AlgorithmIdentifier,n.cades),s=a.SignaturePolicyId,l=a.OtherHashAlgAndValue;s.superclass.constructor.call(this),this.params=null,this.tohex=function(){var e=this.params,t=[];t.push(new i(e.oid)),t.push(new l(e));var n=new r({array:t});return n.tohex()},this.getEncodedHex=function(){return this.tohex()},this.setByParam=function(e){this.params=e},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cades.SignaturePolicyId,Sn.asn1.ASN1Object),Sn.asn1.cades.OtherHashAlgAndValue=function(e){var t=Error,n=Sn,r=n.asn1,i=r.DERSequence,o=r.DEROctetString,a=r.x509,s=a.AlgorithmIdentifier,l=r.cades,c=l.OtherHashAlgAndValue;c.superclass.constructor.call(this),this.params=null,this.tohex=function(){var e=this.params;if(void 0==e.alg)throw new t("property 'alg' not specified");if(void 0==e.hash&&void 0==e.cert)throw new t("property 'hash' nor 'cert' not specified");var n=null;if(void 0!=e.hash)n=e.hash;else if(void 0!=e.cert){if("string"!=typeof e.cert)throw new t("cert not string");var r=e.cert;-1!=e.cert.indexOf("-----BEGIN")&&(r=Yn(e.cert)),n=Sn.crypto.Util.hashHex(r,e.alg)}var a=[];a.push(new s({name:e.alg})),a.push(new o({hex:n}));var l=new i({array:a});return l.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cades.OtherHashAlgAndValue,Sn.asn1.ASN1Object),Sn.asn1.cades.OtherHashValue=function(e){Sn.asn1.cades.OtherHashValue.superclass.constructor.call(this);var t=Error,n=Sn,r=(n.lang.String.isHex,n.asn1),i=r.DEROctetString;n.crypto.Util.hashHex;this.params=null,this.tohex=function(){var e=this.params;if(void 0==e.hash&&void 0==e.cert)throw new t("hash or cert not specified");var n=null;if(void 0!=e.hash)n=e.hash;else if(void 0!=e.cert){if("string"!=typeof e.cert)throw new t("cert not string");var r=e.cert;-1!=e.cert.indexOf("-----BEGIN")&&(r=Yn(e.cert)),n=Sn.crypto.Util.hashHex(r,"sha1")}return new i({hex:n}).tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cades.OtherHashValue,Sn.asn1.ASN1Object),Sn.asn1.cades.SignatureTimeStamp=function(e){var t=Error,n=Sn,r=n.lang.String.isHex,i=n.asn1,o=i.ASN1Object,a=(i.x509,i.cades);a.SignatureTimeStamp.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.16.2.14",this.params=null,this.getValueArray=function(){var e=this.params;if(void 0!=e.tst){if(r(e.tst)){var n=new o;return n.hTLV=e.tst,[n]}if(e.tst instanceof o)return[e.tst];throw new t("params.tst has wrong value")}if(void 0!=e.res){var i=e.res;if(i instanceof o&&(i=i.tohex()),"string"!=typeof i||!r(i))throw new t("params.res has wrong value");_n.getTLVbyList(i,0,[1]),n=new o;return n.hTLV=e.tst,[n]}},null!=e&&this.setByParam(e)},Dr(Sn.asn1.cades.SignatureTimeStamp,Sn.asn1.cms.Attribute),Sn.asn1.cades.CompleteCertificateRefs=function(e){var t=Error,n=Sn,r=n.asn1,i=r.DERSequence,o=r.cades,a=o.OtherCertID,s=n.lang.String.isHex;o.CompleteCertificateRefs.superclass.constructor.call(this),this.typeOid="1.2.840.113549.1.9.16.2.21",this.params=null,this.getValueArray=function(){for(var e=this.params,n=[],r=0;r<e.array.length;r++){var o=e.array[r];if("string"==typeof o)if(-1!=o.indexOf("-----BEGIN"))o={cert:o};else{if(!s(o))throw new t("unsupported value: "+o);o={hash:o}}void 0!=e.alg&&void 0==o.alg&&(o.alg=e.alg),void 0!=e.hasis&&void 0==o.hasis&&(o.hasis=e.hasis);var l=new a(o);n.push(l)}var c=new i({array:n});return[c]},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cades.CompleteCertificateRefs,Sn.asn1.cms.Attribute),Sn.asn1.cades.OtherCertID=function(e){var t=Sn,n=t.asn1,r=n.DERSequence,i=n.cms,o=i.IssuerSerial,a=n.cades,s=a.OtherHashValue,l=a.OtherHashAlgAndValue;a.OtherCertID.superclass.constructor.call(this),this.params=e,this.tohex=function(){var e=this.params;"string"==typeof e&&(-1!=e.indexOf("-----BEGIN")?e={cert:e}:_isHex(e)&&(e={hash:e}));var t=[],n=null;if(n=void 0!=e.alg?new l(e):new s(e),t.push(n),void 0!=e.cert&&1==e.hasis||void 0!=e.issuer&&void 0!=e.serial){var i=new o(e);t.push(i)}var a=new r({array:t});return a.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cades.OtherCertID,Sn.asn1.ASN1Object),Sn.asn1.cades.OtherHash=function(e){Error;var t=Sn,n=t.asn1,r=(n.cms,n.cades),i=r.OtherHashAlgAndValue,o=r.OtherHashValue,a=(t.crypto.Util.hashHex,t.lang.String.isHex);r.OtherHash.superclass.constructor.call(this),this.params=null,this.tohex=function(){var e=this.params;"string"==typeof e&&(-1!=e.indexOf("-----BEGIN")?e={cert:e}:a(e)&&(e={hash:e}));var t=null;return t=void 0!=e.alg?new i(e):new o(e),t.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.cades.OtherHash,Sn.asn1.ASN1Object),Sn.asn1.cades.CAdESUtil=new function(){},Sn.asn1.cades.CAdESUtil.parseSignedDataForAddingUnsigned=function(e){var t=new Sn.asn1.cms.CMSParser,n=t.getCMSSignedData(e);return n},Sn.asn1.cades.CAdESUtil.parseSignerInfoForAddingUnsigned=function(e,t,n){var r=_n,i=r.getChildIdx,o=r.getTLV,a=r.getV,s=Sn,l=s.asn1,c=l.ASN1Object,u=l.cms,d=u.AttributeList,h=u.SignerInfo,p={},f=i(e,t);if(6!=f.length)throw"not supported items for SignerInfo (!=6)";var m=f.shift();p.version=o(e,m);var g=f.shift();p.si=o(e,g);var v=f.shift();p.digalg=o(e,v);var b=f.shift();p.sattrs=o(e,b);var y=f.shift();p.sigalg=o(e,y);var w=f.shift();p.sig=o(e,w),p.sigval=a(e,w);var O=null;return p.obj=new h,O=new c,O.hTLV=p.version,p.obj.dCMSVersion=O,O=new c,O.hTLV=p.si,p.obj.dSignerIdentifier=O,O=new c,O.hTLV=p.digalg,p.obj.dDigestAlgorithm=O,O=new c,O.hTLV=p.sattrs,p.obj.dSignedAttrs=O,O=new c,O.hTLV=p.sigalg,p.obj.dSigAlg=O,O=new c,O.hTLV=p.sig,p.obj.dSig=O,p.obj.dUnsignedAttrs=new d,p},"undefined"!=typeof Sn.asn1.csr&&Sn.asn1.csr||(Sn.asn1.csr={}),Sn.asn1.csr.CertificationRequest=function(e){var t=Sn,n=t.asn1,r=n.DERBitString,i=n.DERSequence,o=n.csr,a=(n.x509,o.CertificationRequestInfo);o.CertificationRequest.superclass.constructor.call(this),this.setByParam=function(e){this.params=e},this.sign=function(){var e=new a(this.params).tohex(),t=new Sn.crypto.Signature({alg:this.params.sigalg});t.init(this.params.sbjprvkey),t.updateHex(e);var n=t.sign();this.params.sighex=n},this.getPEM=function(){return Xn(this.tohex(),"CERTIFICATE REQUEST")},this.tohex=function(){var e=this.params,t=new Sn.asn1.csr.CertificationRequestInfo(this.params),n=new Sn.asn1.x509.AlgorithmIdentifier({name:e.sigalg});if(void 0==e.sighex&&void 0!=e.sbjprvkey&&this.sign(),void 0==e.sighex)throw new Error("sighex or sbjprvkey parameter not defined");var o=new r({hex:"00"+e.sighex}),a=new i({array:[t,n,o]});return a.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.csr.CertificationRequest,Sn.asn1.ASN1Object),Sn.asn1.csr.CertificationRequestInfo=function(e){var t=Sn,n=t.asn1,r=(n.DERBitString,n.DERSequence),i=n.DERInteger,o=n.DERUTF8String,a=n.DERTaggedObject,s=n.ASN1Util.newObject,l=n.csr,c=n.x509,u=c.X500Name,d=c.Extensions,h=c.SubjectPublicKeyInfo;l.AttributeList;function p(e){for(var t=Error,n=Sn.asn1.x509.Extensions,r=[],i=0;i<e.length;i++){var o=e[i],a=o.attr;if("extensionRequest"==a){var s=new n(o.ext),l={seq:[{oid:"1.2.840.113549.1.9.14"},{set:[s]}]};r.push(l)}else if("unstructuredName"==a){l={seq:[{oid:"1.2.840.113549.1.9.2"},{set:o.names}]};r.push(l)}else{if("challengePassword"!=a)throw new t("unknown CSR attribute");l={seq:[{oid:"1.2.840.113549.1.9.7"},{set:[{utf8str:o.password}]}]};r.push(l)}}return{set:r}}l.CertificationRequestInfo.superclass.constructor.call(this),this.params=null,this.setByParam=function(e){void 0!=e&&(this.params=e)},this.tohex=function(){var e=this.params,t=[];if(t.push(new i({int:0})),t.push(new u(e.subject)),t.push(new h(Lr.getKey(e.sbjpubkey))),void 0!=e.attrs){var n=p(e.attrs),l=s({tag:{tage:"a0",obj:n}});t.push(l)}else if(void 0!=e.extreq){var c=new d(e.extreq);l=s({tag:{tage:"a0",obj:{seq:[{oid:"1.2.840.113549.1.9.14"},{set:[c]}]}}});t.push(l)}else t.push(new a({tag:"a0",explicit:!1,obj:new o({str:""})}));var f=new r({array:t});return f.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!=e&&this.setByParam(e)},Dr(Sn.asn1.csr.CertificationRequestInfo,Sn.asn1.ASN1Object),Sn.asn1.csr.AttributeList=function(e){},Dr(Sn.asn1.csr.AttributeList,Sn.asn1.ASN1Object),Sn.asn1.csr.CSRUtil=new function(){},Sn.asn1.csr.CSRUtil.newCSRPEM=function(e){var t=Sn.asn1.csr,n=new t.CertificationRequest(e),r=n.getPEM();return r},Sn.asn1.csr.CSRUtil.getParam=function(e,t){var n=_n,r=n.getV,i=n.getIdxbyList,o=n.getTLVbyList,a=n.getTLVbyListEx,s=n.getVbyListEx,l=function(e){var t=i(e,0,[0,3,0,0],"06");return"2a864886f70d01090e"!=r(e,t)?null:o(e,0,[0,3,0,1,0],"30")},c={};if(-1==e.indexOf("-----BEGIN CERTIFICATE REQUEST"))throw new Error("argument is not PEM file");var u=Yn(e,"CERTIFICATE REQUEST");t&&(c.tbs=o(u,0,[0]));try{var d=a(u,0,[0,1]);if("3000"==d)c.subject={};else{var h=new Fr;c.subject=h.getX500Name(d)}}catch(b){}var p=a(u,0,[0,2]),f=Lr.getKey(p,null,"pkcs8pub");c.sbjpubkey=Lr.getPEM(f,"PKCS8PUB");var m=l(u);h=new Fr;null!=m&&(c.extreq=h.getExtParamArray(m));try{var g=a(u,0,[1],"30");h=new Fr;c.sigalg=h.getAlgorithmIdentifierName(g)}catch(b){}try{var v=s(u,0,[2]);c.sighex=v}catch(b){}return c},Sn.asn1.csr.CSRUtil.verifySignature=function(e){try{var t=null;if("string"==typeof e&&-1!=e.indexOf("-----BEGIN CERTIFICATE REQUEST")?t=Sn.asn1.csr.CSRUtil.getParam(e,!0):"object"==typeof e&&void 0!=e.sbjpubkey&&void 0!=e.sigalg&&void 0!=e.sighex&&void 0!=e.tbs&&(t=e),null==t)return!1;var n=new Sn.crypto.Signature({alg:t.sigalg});return n.init(t.sbjpubkey),n.updateHex(t.tbs),n.verify(t.sighex)}catch(r){return alert(r),!1}},"undefined"!=typeof Sn&&Sn||(Sn={}),"undefined"!=typeof Sn.asn1&&Sn.asn1||(Sn.asn1={}),"undefined"!=typeof Sn.asn1.ocsp&&Sn.asn1.ocsp||(Sn.asn1.ocsp={}),Sn.asn1.ocsp.DEFAULT_HASH="sha1",Sn.asn1.ocsp.OCSPResponse=function(e){Sn.asn1.ocsp.OCSPResponse.superclass.constructor.call(this);Sn.asn1.DEREnumerated;var t=Sn.asn1.ASN1Util.newObject,n=Sn.asn1.ocsp.ResponseBytes,r=["successful","malformedRequest","internalError","tryLater","_not_used_","sigRequired","unauthorized"];this.params=null,this._getStatusCode=function(){var e=this.params.resstatus;return"number"==typeof e?e:"string"!=typeof e?-1:r.indexOf(e)},this.setByParam=function(e){this.params=e},this.tohex=function(){var e=this.params,r=this._getStatusCode();if(-1==r)throw new Error("responseStatus not supported: "+e.resstatus);if(0!=r)return t({seq:[{enum:{int:r}}]}).tohex();var i=new n(e);return t({seq:[{enum:{int:0}},{tag:{tag:"a0",explicit:!0,obj:i}}]}).tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.ocsp.OCSPResponse,Sn.asn1.ASN1Object),Sn.asn1.ocsp.ResponseBytes=function(e){Sn.asn1.ocsp.ResponseBytes.superclass.constructor.call(this);var t=Sn.asn1,n=t.DERSequence,r=t.DERObjectIdentifier,i=t.DEROctetString,o=t.ocsp.BasicOCSPResponse;this.params=null,this.setByParam=function(e){this.params=e},this.tohex=function(){var e=this.params;if("ocspBasic"!=e.restype)throw new Error("not supported responseType: "+e.restype);var t=new o(e),a=[];a.push(new r({name:"ocspBasic"})),a.push(new i({hex:t.tohex()}));var s=new n({array:a});return s.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.ocsp.ResponseBytes,Sn.asn1.ASN1Object),Sn.asn1.ocsp.BasicOCSPResponse=function(e){Sn.asn1.ocsp.BasicOCSPResponse.superclass.constructor.call(this);var t=Error,n=Sn.asn1,r=n.ASN1Object,i=n.DERSequence,o=(n.DERGeneralizedTime,n.DERTaggedObject),a=n.DERBitString,s=(n.x509.Extensions,n.x509.AlgorithmIdentifier),l=n.ocsp;l.ResponderID;_SingleResponseList=l.SingleResponseList,_ResponseData=l.ResponseData,this.params=null,this.setByParam=function(e){this.params=e},this.sign=function(){var e=this.params,t=e.tbsresp.tohex(),n=new Sn.crypto.Signature({alg:e.sigalg});n.init(e.reskey),n.updateHex(t),e.sighex=n.sign()},this.tohex=function(){var e=this.params;void 0==e.tbsresp&&(e.tbsresp=new _ResponseData(e)),void 0==e.sighex&&void 0!=e.reskey&&this.sign();var n=[];if(n.push(e.tbsresp),n.push(new s({name:e.sigalg})),n.push(new a({hex:"00"+e.sighex})),void 0!=e.certs&&void 0!=e.certs.length){for(var l=[],c=0;c<e.certs.length;c++){var u=e.certs[c],d=null;if(_n.isASN1HEX(u))d=u;else{if(!u.match(/-----BEGIN/))throw new t("certs["+c+"] not hex or PEM");d=Yn(u)}l.push(new r({tlv:d}))}var h=new i({array:l});n.push(new o({tag:"a0",explicit:!0,obj:h}))}var p=new i({array:n});return p.tohex()},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.ocsp.BasicOCSPResponse,Sn.asn1.ASN1Object),Sn.asn1.ocsp.ResponseData=function(e){Sn.asn1.ocsp.ResponseData.superclass.constructor.call(this);var t=Error,n=Sn.asn1,r=n.DERSequence,i=n.DERGeneralizedTime,o=n.DERTaggedObject,a=n.x509.Extensions,s=n.ocsp,l=s.ResponderID;_SingleResponseList=s.SingleResponseList,this.params=null,this.tohex=function(){var e=this.params;void 0!=e.respid&&new t("respid not specified"),void 0!=e.prodat&&new t("prodat not specified"),void 0!=e.array&&new t("array not specified");var n=[];if(n.push(new l(e.respid)),n.push(new i(e.prodat)),n.push(new _SingleResponseList(e.array)),void 0!=e.ext){var s=new a(e.ext);n.push(new o({tag:"a1",explicit:!0,obj:s}))}var c=new r({array:n});return c.tohex()},this.getEncodedHex=function(){return this.tohex()},this.setByParam=function(e){this.params=e},void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.ocsp.ResponseData,Sn.asn1.ASN1Object),Sn.asn1.ocsp.ResponderID=function(e){Sn.asn1.ocsp.ResponderID.superclass.constructor.call(this);var t=Sn,n=t.asn1,r=n.ASN1Util.newObject,i=n.x509.X500Name,o=t.lang.String.isHex,a=Error;this.params=null,this.tohex=function(){var e=this.params;if(void 0!=e.key){var t=null;if("string"==typeof e.key){if(o(e.key)&&(t=e.key),e.key.match(/-----BEGIN CERTIFICATE/)){var n=new Fr(e.key),s=n.getExtSubjectKeyIdentifier();null!=s&&(t=s.kid.hex)}}else if(e.key instanceof Fr){s=e.key.getExtSubjectKeyIdentifier();null!=s&&(t=s.kid.hex)}if(null==t)throw new a("wrong key member value");var l=r({tag:{tag:"a2",explicit:!0,obj:{octstr:{hex:t}}}});return l.tohex()}if(void 0!=e.name){var c=null;if("string"==typeof e.name&&e.name.match(/-----BEGIN CERTIFICATE/)){n=new Fr(e.name);c=n.getSubject()}else e.name instanceof Fr?c=e.name.getSubject():"object"!=typeof e.name||void 0==e.name.array&&void 0==e.name.str||(c=e.name);if(null==c)throw new a("wrong name member value");l=r({tag:{tag:"a1",explicit:!0,obj:new i(c)}});return l.tohex()}throw new a("key or name not specified")},this.getEncodedHex=function(){return this.tohex()},this.setByParam=function(e){this.params=e},void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.ocsp.ResponderID,Sn.asn1.ASN1Object),Sn.asn1.ocsp.SingleResponseList=function(e){Sn.asn1.ocsp.SingleResponseList.superclass.constructor.call(this);var t=Sn.asn1,n=t.DERSequence,r=t.ocsp.SingleResponse;this.params=null,this.tohex=function(){var e=this.params;if("object"!=typeof e||void 0==e.length)throw new Error("params not specified properly");for(var t=[],i=0;i<e.length;i++)t.push(new r(e[i]));var o=new n({array:t});return o.tohex()},this.getEncodedHex=function(){return this.tohex()},this.setByParam=function(e){this.params=e},void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.ocsp.SingleResponseList,Sn.asn1.ASN1Object),Sn.asn1.ocsp.SingleResponse=function(e){var t=Error,n=Sn,r=n.asn1,i=r.DERSequence,o=r.DERGeneralizedTime,a=r.DERTaggedObject,s=r.ocsp,l=s.CertID,c=s.CertStatus,u=r.x509,d=u.Extensions;s.SingleResponse.superclass.constructor.call(this),this.params=null,this.tohex=function(){var e=this.params,n=[];if(void 0==e.certid)throw new t("certid unspecified");if(void 0==e.status)throw new t("status unspecified");if(void 0==e.thisupdate)throw new t("thisupdate unspecified");if(n.push(new l(e.certid)),n.push(new c(e.status)),n.push(new o(e.thisupdate)),void 0!=e.nextupdate){var r=new o(e.nextupdate);n.push(new a({tag:"a0",explicit:!0,obj:r}))}if(void 0!=e.ext){var s=new d(e.ext);n.push(new a({tag:"a1",explicit:!0,obj:s}))}var u=new i({array:n});return u.tohex()},this.getEncodedHex=function(){return this.tohex()},this.setByParam=function(e){this.params=e},void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.ocsp.SingleResponse,Sn.asn1.ASN1Object),Sn.asn1.ocsp.CertID=function(e){var t=Sn,n=t.asn1,r=n.DEROctetString,i=n.DERInteger,o=n.DERSequence,a=n.x509,s=a.AlgorithmIdentifier,l=n.ocsp,c=(l.DEFAULT_HASH,t.crypto),u=c.Util.hashHex,d=Fr,h=_n,p=h.getVbyList;l.CertID.superclass.constructor.call(this),this.DEFAULT_HASH="sha1",this.params=null,this.setByValue=function(e,t,n,r){void 0==r&&(r=this.DEFAULT_HASH),this.params={alg:r,issname:e,isskey:t,sbjsn:n}},this.setByCert=function(e,t,n){void 0==n&&(n=this.DEFAULT_HASH),this.params={alg:n,issuerCert:e,subjectCert:t}},this.getParamByCerts=function(e,t,n){void 0==n&&(n=this.DEFAULT_HASH);var r=new d(e),i=new d(t),o=u(r.getSubjectHex(),n),a=r.getPublicKeyHex(),s=u(p(a,0,[1],"03",!0),n),l=i.getSerialNumberHex(),c={alg:n,issname:o,isskey:s,sbjsn:l};return c},this.tohex=function(){if("object"!=typeof this.params)throw new Error("params not set");var e,t,n,a,l=this.params;if(a=void 0==l.alg?this.DEFAULT_HASH:l.alg,void 0!=l.issuerCert&&void 0!=l.subjectCert){var c=this.getParamByCerts(l.issuerCert,l.subjectCert,a);e=c.issname,t=c.isskey,n=c.sbjsn}else{if(void 0==l.issname||void 0==l.isskey||void 0==l.sbjsn)throw new Error("required param members not defined");e=l.issname,t=l.isskey,n=l.sbjsn}var u=new s({name:a}),d=new r({hex:e}),h=new r({hex:t}),p=new i({hex:n}),f=new o({array:[u,d,h,p]});return this.hTLV=f.tohex(),this.hTLV},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.ocsp.CertID,Sn.asn1.ASN1Object),Sn.asn1.ocsp.CertStatus=function(e){Sn.asn1.ocsp.CertStatus.superclass.constructor.call(this),this.params=null,this.tohex=function(){var e=this.params;if("good"==e.status)return"8000";if("unknown"==e.status)return"8200";if("revoked"==e.status){var t=[{gentime:{str:e.time}}];void 0!=e.reason&&t.push({tag:{tag:"a0",explicit:!0,obj:{enum:{int:e.reason}}}});var n={tag:"a1",explicit:!1,obj:{seq:t}};return Sn.asn1.ASN1Util.newObject({tag:n}).tohex()}throw new Error("bad status")},this.getEncodedHex=function(){return this.tohex()},this.setByParam=function(e){this.params=e},void 0!==e&&this.setByParam(e)},Dr(Sn.asn1.ocsp.CertStatus,Sn.asn1.ASN1Object),Sn.asn1.ocsp.Request=function(e){var t=Sn,n=t.asn1,r=n.DERSequence,i=n.ocsp;if(i.Request.superclass.constructor.call(this),this.dReqCert=null,this.dExt=null,this.tohex=function(){var e=[];if(null===this.dReqCert)throw"reqCert not set";e.push(this.dReqCert);var t=new r({array:e});return this.hTLV=t.tohex(),this.hTLV},this.getEncodedHex=function(){return this.tohex()},"undefined"!==typeof e){var o=new i.CertID(e);this.dReqCert=o}},Dr(Sn.asn1.ocsp.Request,Sn.asn1.ASN1Object),Sn.asn1.ocsp.TBSRequest=function(e){var t=Sn,n=t.asn1,r=n.DERSequence,i=n.ocsp;i.TBSRequest.superclass.constructor.call(this),this.version=0,this.dRequestorName=null,this.dRequestList=[],this.dRequestExt=null,this.setRequestListByParam=function(e){for(var t=[],n=0;n<e.length;n++){var r=new i.Request(e[0]);t.push(r)}this.dRequestList=t},this.tohex=function(){var e=[];if(0!==this.version)throw"not supported version: "+this.version;if(null!==this.dRequestorName)throw"requestorName not supported";var t=new r({array:this.dRequestList});if(e.push(t),null!==this.dRequestExt)throw"requestExtensions not supported";var n=new r({array:e});return this.hTLV=n.tohex(),this.hTLV},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&void 0!==e.reqList&&this.setRequestListByParam(e.reqList)},Dr(Sn.asn1.ocsp.TBSRequest,Sn.asn1.ASN1Object),Sn.asn1.ocsp.OCSPRequest=function(e){var t=Sn,n=t.asn1,r=n.DERSequence,i=n.ocsp;if(i.OCSPRequest.superclass.constructor.call(this),this.dTbsRequest=null,this.dOptionalSignature=null,this.tohex=function(){var e=[];if(null===this.dTbsRequest)throw"tbsRequest not set";if(e.push(this.dTbsRequest),null!==this.dOptionalSignature)throw"optionalSignature not supported";var t=new r({array:e});return this.hTLV=t.tohex(),this.hTLV},this.getEncodedHex=function(){return this.tohex()},void 0!==e&&void 0!==e.reqList){var o=new i.TBSRequest(e);this.dTbsRequest=o}},Dr(Sn.asn1.ocsp.OCSPRequest,Sn.asn1.ASN1Object),Sn.asn1.ocsp.OCSPUtil={},Sn.asn1.ocsp.OCSPUtil.getRequestHex=function(e,t,n){var r=Sn,i=r.asn1,o=i.ocsp;void 0===n&&(n=o.DEFAULT_HASH);var a={alg:n,issuerCert:e,subjectCert:t},s=new o.OCSPRequest({reqList:[a]});return s.tohex()},Sn.asn1.ocsp.OCSPUtil.getOCSPResponseInfo=function(e){var t=_n,n=t.getVbyList,r=t.getVbyListEx,i=t.getIdxbyList,o=(t.getIdxbyListEx,t.getV),a={};try{var s=r(e,0,[0],"0a");a.responseStatus=parseInt(s,16)}catch(d){}if(0!==a.responseStatus)return a;try{var l=i(e,0,[1,0,1,0,0,2,0,1]);"80"===e.substr(l,2)?a.certStatus="good":"a1"===e.substr(l,2)?(a.certStatus="revoked",a.revocationTime=Fn(n(e,l,[0]))):"82"===e.substr(l,2)&&(a.certStatus="unknown")}catch(d){}try{var c=i(e,0,[1,0,1,0,0,2,0,2]);a.thisUpdate=Fn(o(e,c))}catch(d){}try{var u=i(e,0,[1,0,1,0,0,2,0,3]);"a0"===e.substr(u,2)&&(a.nextUpdate=Fn(n(e,u,[0])))}catch(d){}return a},Sn.asn1.ocsp.OCSPParser=function(){var e=Error,t=Fr,n=new t,r=_n,i=r.getV,o=r.getTLV,a=r.getIdxbyList,s=r.getVbyList,l=r.getTLVbyList,c=r.getVbyListEx,u=r.getTLVbyListEx,d=r.getChildIdx;this.getOCSPRequest=function(t){var n=d(t,0);if(1!=n.length&&2!=n.length)throw new e("wrong number elements: "+n.length);var r=this.getTBSRequest(o(t,n[0]));return r},this.getTBSRequest=function(e){var t={},r=u(e,0,[0],"30");t.array=this.getRequestList(r);var i=u(e,0,["[2]",0],"30");return null!=i&&(t.ext=n.getExtParamArray(i)),t},this.getRequestList=function(e){for(var t=[],n=d(e,0),r=0;r<n.length;r++){e=o(e,n[r]);t.push(this.getRequest(e))}return t},this.getRequest=function(t){var r=d(t,0);if(1!=r.length&&2!=r.length)throw new e("wrong number elements: "+r.length);var i=this.getCertID(o(t,r[0]));if(2==r.length){var s=a(t,0,[1,0]);i.ext=n.getExtParamArray(o(t,s))}return i},this.getCertID=function(n){var r=d(n,0);if(4!=r.length)throw new e("wrong number elements: "+r.length);var a=new t,s={};return s.alg=a.getAlgorithmIdentifierName(o(n,r[0])),s.issname=i(n,r[1]),s.isskey=i(n,r[2]),s.sbjsn=i(n,r[3]),s},this.getOCSPResponse=function(e){var t,n=d(e,0),r=i(e,n[0]),o=parseInt(r);if(1==n.length)return{resstatus:o};var a=l(e,0,[1,0]);return t=this.getResponseBytes(a),t.resstatus=o,t},this.getResponseBytes=function(e){var t,n=d(e,0),r=l(e,0,[1,0]);t=this.getBasicOCSPResponse(r);var o=i(e,n[0]);return t.restype=Sn.asn1.x509.OID.oid2name(_r(o)),t},this.getBasicOCSPResponse=function(e){var t,n=d(e,0);t=this.getResponseData(o(e,n[0]));var r=new Fr;t.alg=r.getAlgorithmIdentifierName(o(e,n[1]));var a=i(e,n[2]);t.sighex=a.substr(2);var s=c(e,0,["[0]"]);if(null!=s){for(var l=d(s,0),u=[],h=0;h<l.length;h++){var p=o(s,l[h]);u.push(p)}t.certs=u}return t},this.getResponseData=function(e){var t=d(e,0),n=t.length,r={},a=0;"a0"==e.substr(t[0],2)&&a++,r.respid=this.getResponderID(o(e,t[a++]));var s=i(e,t[a++]);if(r.prodat=Fn(s),r.array=this.getSingleResponseList(o(e,t[a++])),"a1"==e.substr(t[n-1],2)){var c=l(e,t[n-1],[0]),u=new Fr;r.ext=u.getExtParamArray(c)}return r},this.getResponderID=function(e){var t={};if("a2"==e.substr(0,2)){var n=s(e,0,[0]);t.key=n}if("a1"==e.substr(0,2)){var r=l(e,0,[0]),i=new Fr;t.name=i.getX500Name(r)}return t},this.getSingleResponseList=function(e){for(var t=d(e,0),n=[],r=0;r<t.length;r++){var i=this.getSingleResponse(o(e,t[r]));n.push(i)}return n},this.getSingleResponse=function(e){var t=d(e,0),n={},r=this.getCertID(o(e,t[0]));n.certid=r;var a=this.getCertStatus(o(e,t[1]));if(n.status=a,"18"==e.substr(t[2],2)){var c=i(e,t[2]);n.thisupdate=Fn(c)}for(var u=3;u<t.length;u++){if("a0"==e.substr(t[u],2)){var h=s(e,t[u],[0],"18");n.nextupdate=Fn(h)}if("a1"==e.substr(t[u],2)){var p=new Fr,f=l(e,0,[u,0]);n.ext=p.getExtParamArray(f)}}return n},this.getCertStatus=function(e){var t={};if("8000"==e)return{status:"good"};if("8200"==e)return{status:"unknown"};if("a1"==e.substr(0,2)){t.status="revoked";var n=s(e,0,[0]),r=Fn(n);t.time=r}return t}},"undefined"!=typeof Sn&&Sn||(Sn={}),"undefined"!=typeof Sn.lang&&Sn.lang||(Sn.lang={}),Sn.lang.String=function(){},"function"===typeof r?(En=function(e){return In(r.from(e,"utf8").toString("base64"))},xn=function(e){return r.from(Mn(e),"base64").toString("utf8")}):(En=function(e){return Dn(sr(gr(e)))},xn=function(e){return decodeURIComponent(lr(Ln(e)))}),Sn.lang.String.isInteger=function(e){return!!e.match(/^[0-9]+$/)||!!e.match(/^-[0-9]+$/)},Sn.lang.String.isHex=function(e){return yr(e)},Sn.lang.String.isBase64=function(e){return e=e.replace(/\s+/g,""),!(!e.match(/^[0-9A-Za-z+\/]+={0,3}$/)||e.length%4!=0)},Sn.lang.String.isBase64URL=function(e){return!e.match(/[+/=]/)&&(e=Mn(e),Sn.lang.String.isBase64(e))},Sn.lang.String.isIntegerArray=function(e){return e=e.replace(/\s+/g,""),!!e.match(/^\[[0-9,]+\]$/)},Sn.lang.String.isPrintable=function(e){return null!==e.match(/^[0-9A-Za-z '()+,-./:=?]*$/)},Sn.lang.String.isIA5=function(e){return null!==e.match(/^[\x20-\x21\x23-\x7f]*$/)},Sn.lang.String.isMail=function(e){return null!==e.match(/^[A-Za-z0-9]{1}[A-Za-z0-9_.-]*@{1}[A-Za-z0-9_.-]{1,}\.[A-Za-z0-9]{1,}$/)};var Er=function(e,t){var n=e.length;e.length>t.length&&(n=t.length);for(var r=0;r<n;r++)if(e.charCodeAt(r)!=t.charCodeAt(r))return r;return e.length!=t.length?n:-1};function xr(e){var t=function(e){var t=e.toString(16);return 1==t.length&&(t="0"+t),t},n=function(e){var n="",r=parseInt(e,10),i=r.toString(2),o=7-i.length%7;7==o&&(o=0);for(var a="",s=0;s<o;s++)a+="0";i=a+i;for(s=0;s<i.length-1;s+=7){var l=i.substr(s,7);s!=i.length-7&&(l="1"+l),n+=t(parseInt(l,2))}return n};try{if(!e.match(/^[0-9.]+$/))return null;var r="",i=e.split("."),o=40*parseInt(i[0],10)+parseInt(i[1],10);r+=t(o),i.splice(0,2);for(var a=0;a<i.length;a++)r+=n(i[a]);return r}catch(s){return null}}function _r(e){if(!yr(e))return null;try{var t=[],n=e.substr(0,2),r=parseInt(n,16);t[0]=new String(Math.floor(r/40)),t[1]=new String(r%40);for(var i=e.substr(2),o=[],a=0;a<i.length/2;a++)o.push(parseInt(i.substr(2*a,2),16));var s=[],l="";for(a=0;a<o.length;a++)128&o[a]?l+=Ar((127&o[a]).toString(2),7):(l+=Ar((127&o[a]).toString(2),7),s.push(new String(parseInt(l,2))),l="");var c=t.join(".");return s.length>0&&(c=c+"."+s.join(".")),c}catch(u){return null}}function kr(e){var t=new v(String(e),10);return Cr(t)}function Cr(e){var t=e.toString(16);if("-"!=t.substr(0,1))return t.length%2==1?t="0"+t:t.match(/^[0-7]/)||(t="00"+t),t;var n=t.substr(1),r=n.length;r%2==1?r+=1:t.match(/^[0-7]/)||(r+=2);for(var i="",o=0;o<r;o++)i+="f";var a=new v(i,16),s=a.xor(e).add(v.ONE);return t=s.toString(16).replace(/^-/,""),t}var Ar=function(e,t,n){return void 0==n&&(n="0"),e.length>=t?e:new Array(t-e.length+1).join(n)+e};function Tr(e){if(e.length%2!=0)return-1;if(e=e.toLowerCase(),null==e.match(/^[0-9a-f]+$/))return-1;try{var t=e.substr(0,2);if("00"==t)return parseInt(e.substr(2),16);var n=parseInt(t,16);if(n>7)return-1;var r=e.substr(2),i=parseInt(r,16).toString(2);"0"==i&&(i="00000000"),i=i.slice(0,0-n);var o=parseInt(i,2);return NaN==o?-1:o}catch(a){return-1}}function Rr(e){if("number"!=typeof e)return null;if(e<0)return null;var t=Number(e).toString(2),n=8-t.length%8;8==n&&(n=0),t+=Ar("",n,"0");var r=parseInt(t,2).toString(16);r.length%2==1&&(r="0"+r);var i="0"+n;return i+r}function Nr(e){if("string"!=typeof e)return null;if(e.length%2!=0)return null;if(!e.match(/^[0-9a-f]+$/))return null;try{var t=parseInt(e.substr(0,2),16);if(t<0||7<t)return null;for(var n=e.substr(2),r="",i=0;i<n.length;i+=2){var o=n.substr(i,2),a=parseInt(o,16).toString(2);a=("0000000"+a).slice(-8),r+=a}return r.substr(0,r.length-t)}catch(s){return null}}function Pr(e){if("string"!=typeof e)return null;if(null==e.match(/^[01]+$/))return null;try{var t=parseInt(e,2);return Rr(t)}catch(n){return null}}function Ir(e,t){for(var n=0,r=0;r<e.length;r++)n|=1<<t[e[r]];var i=n.toString(2),o="";for(r=i.length-1;r>=0;r--)o+=i[r];return o}function Mr(e,t,n){if("object"==typeof e){t=String(t).split(".");for(var r=0;r<t.length&&e;r++){var i=t[r];i.match(/^[0-9]+$/)&&(i=parseInt(i)),e=e[i]}return e||!1===e?e:n}}function Dr(e,t){var n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e,e.superclass=t.prototype,t.prototype.constructor==Object.prototype.constructor&&(t.prototype.constructor=t)}"undefined"!=typeof Sn&&Sn||(Sn={}),"undefined"!=typeof Sn.crypto&&Sn.crypto||(Sn.crypto={}),Sn.crypto.Util=new function(){this.DIGESTINFOHEAD={sha1:"3021300906052b0e03021a05000414",sha224:"302d300d06096086480165030402040500041c",sha256:"3031300d060960864801650304020105000420",sha384:"3041300d060960864801650304020205000430",sha512:"3051300d060960864801650304020305000440",md2:"3020300c06082a864886f70d020205000410",md5:"3020300c06082a864886f70d020505000410",ripemd160:"3021300906052b2403020105000414"},this.DEFAULTPROVIDER={md5:"cryptojs",sha1:"cryptojs",sha224:"cryptojs",sha256:"cryptojs",sha384:"cryptojs",sha512:"cryptojs",ripemd160:"cryptojs",hmacmd5:"cryptojs",hmacsha1:"cryptojs",hmacsha224:"cryptojs",hmacsha256:"cryptojs",hmacsha384:"cryptojs",hmacsha512:"cryptojs",hmacripemd160:"cryptojs",MD5withRSA:"cryptojs/jsrsa",SHA1withRSA:"cryptojs/jsrsa",SHA224withRSA:"cryptojs/jsrsa",SHA256withRSA:"cryptojs/jsrsa",SHA384withRSA:"cryptojs/jsrsa",SHA512withRSA:"cryptojs/jsrsa",RIPEMD160withRSA:"cryptojs/jsrsa",MD5withECDSA:"cryptojs/jsrsa",SHA1withECDSA:"cryptojs/jsrsa",SHA224withECDSA:"cryptojs/jsrsa",SHA256withECDSA:"cryptojs/jsrsa",SHA384withECDSA:"cryptojs/jsrsa",SHA512withECDSA:"cryptojs/jsrsa",RIPEMD160withECDSA:"cryptojs/jsrsa",SHA1withDSA:"cryptojs/jsrsa",SHA224withDSA:"cryptojs/jsrsa",SHA256withDSA:"cryptojs/jsrsa",MD5withRSAandMGF1:"cryptojs/jsrsa",SHAwithRSAandMGF1:"cryptojs/jsrsa",SHA1withRSAandMGF1:"cryptojs/jsrsa",SHA224withRSAandMGF1:"cryptojs/jsrsa",SHA256withRSAandMGF1:"cryptojs/jsrsa",SHA384withRSAandMGF1:"cryptojs/jsrsa",SHA512withRSAandMGF1:"cryptojs/jsrsa",RIPEMD160withRSAandMGF1:"cryptojs/jsrsa"},this.CRYPTOJSMESSAGEDIGESTNAME={md5:l.algo.MD5,sha1:l.algo.SHA1,sha224:l.algo.SHA224,sha256:l.algo.SHA256,sha384:l.algo.SHA384,sha512:l.algo.SHA512,ripemd160:l.algo.RIPEMD160},this.getDigestInfoHex=function(e,t){if("undefined"==typeof this.DIGESTINFOHEAD[t])throw"alg not supported in Util.DIGESTINFOHEAD: "+t;return this.DIGESTINFOHEAD[t]+e},this.getPaddedDigestInfoHex=function(e,t,n){var r=this.getDigestInfoHex(e,t),i=n/4;if(r.length+22>i)throw"key is too short for SigAlg: keylen="+n+","+t;for(var o="0001",a="00"+r,s="",l=i-o.length-a.length,c=0;c<l;c+=2)s+="ff";var u=o+s+a;return u},this.hashString=function(e,t){var n=new Sn.crypto.MessageDigest({alg:t});return n.digestString(e)},this.hashHex=function(e,t){var n=new Sn.crypto.MessageDigest({alg:t});return n.digestHex(e)},this.sha1=function(e){return this.hashString(e,"sha1")},this.sha256=function(e){return this.hashString(e,"sha256")},this.sha256Hex=function(e){return this.hashHex(e,"sha256")},this.sha512=function(e){return this.hashString(e,"sha512")},this.sha512Hex=function(e){return this.hashHex(e,"sha512")},this.isKey=function(e){return e instanceof Ft||e instanceof Sn.crypto.DSA||e instanceof Sn.crypto.ECDSA}},Sn.crypto.Util.md5=function(e){var t=new Sn.crypto.MessageDigest({alg:"md5",prov:"cryptojs"});return t.digestString(e)},Sn.crypto.Util.ripemd160=function(e){var t=new Sn.crypto.MessageDigest({alg:"ripemd160",prov:"cryptojs"});return t.digestString(e)},Sn.crypto.Util.SECURERANDOMGEN=new $t,Sn.crypto.Util.getRandomHexOfNbytes=function(e){var t=new Array(e);return Sn.crypto.Util.SECURERANDOMGEN.nextBytes(t),An(t)},Sn.crypto.Util.getRandomBigIntegerOfNbytes=function(e){return new v(Sn.crypto.Util.getRandomHexOfNbytes(e),16)},Sn.crypto.Util.getRandomHexOfNbits=function(e){var t=e%8,n=(e-t)/8,r=new Array(n+1);return Sn.crypto.Util.SECURERANDOMGEN.nextBytes(r),r[0]=(255<<t&255^255)&r[0],An(r)},Sn.crypto.Util.getRandomBigIntegerOfNbits=function(e){return new v(Sn.crypto.Util.getRandomHexOfNbits(e),16)},Sn.crypto.Util.getRandomBigIntegerZeroToMax=function(e){var t=e.bitLength();while(1){var n=Sn.crypto.Util.getRandomBigIntegerOfNbits(t);if(e.compareTo(n)>=0)return n}},Sn.crypto.Util.getRandomBigIntegerMinToMax=function(e,t){var n=e.compareTo(t);if(n>0)throw"biMin is greater than biMax";if(0==n)return e;var r=t.subtract(e),i=Sn.crypto.Util.getRandomBigIntegerZeroToMax(r);return i.add(e)},Sn.crypto.MessageDigest=function(e){this.setAlgAndProvider=function(e,t){if(e=Sn.crypto.MessageDigest.getCanonicalAlgName(e),null!==e&&void 0===t&&(t=Sn.crypto.Util.DEFAULTPROVIDER[e]),-1!=":md5:sha1:sha224:sha256:sha384:sha512:ripemd160:".indexOf(e)&&"cryptojs"==t){try{this.md=Sn.crypto.Util.CRYPTOJSMESSAGEDIGESTNAME[e].create()}catch(n){throw"setAlgAndProvider hash alg set fail alg="+e+"/"+n}this.updateString=function(e){this.md.update(e)},this.updateHex=function(e){var t=l.enc.Hex.parse(e);this.md.update(t)},this.digest=function(){var e=this.md.finalize();return e.toString(l.enc.Hex)},this.digestString=function(e){return this.updateString(e),this.digest()},this.digestHex=function(e){return this.updateHex(e),this.digest()}}if(-1!=":sha256:".indexOf(e)&&"sjcl"==t){try{this.md=new sjcl.hash.sha256}catch(n){throw"setAlgAndProvider hash alg set fail alg="+e+"/"+n}this.updateString=function(e){this.md.update(e)},this.updateHex=function(e){var t=sjcl.codec.hex.toBits(e);this.md.update(t)},this.digest=function(){var e=this.md.finalize();return sjcl.codec.hex.fromBits(e)},this.digestString=function(e){return this.updateString(e),this.digest()},this.digestHex=function(e){return this.updateHex(e),this.digest()}}},this.updateString=function(e){throw"updateString(str) not supported for this alg/prov: "+this.algName+"/"+this.provName},this.updateHex=function(e){throw"updateHex(hex) not supported for this alg/prov: "+this.algName+"/"+this.provName},this.digest=function(){throw"digest() not supported for this alg/prov: "+this.algName+"/"+this.provName},this.digestString=function(e){throw"digestString(str) not supported for this alg/prov: "+this.algName+"/"+this.provName},this.digestHex=function(e){throw"digestHex(hex) not supported for this alg/prov: "+this.algName+"/"+this.provName},void 0!==e&&void 0!==e.alg&&(this.algName=e.alg,void 0===e.prov&&(this.provName=Sn.crypto.Util.DEFAULTPROVIDER[this.algName]),this.setAlgAndProvider(this.algName,this.provName))},Sn.crypto.MessageDigest.getCanonicalAlgName=function(e){return"string"===typeof e&&(e=e.toLowerCase(),e=e.replace(/-/,"")),e},Sn.crypto.MessageDigest.getHashLength=function(e){var t=Sn.crypto.MessageDigest,n=t.getCanonicalAlgName(e);if(void 0===t.HASHLENGTH[n])throw"not supported algorithm: "+e;return t.HASHLENGTH[n]},Sn.crypto.MessageDigest.HASHLENGTH={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,ripemd160:20},Sn.crypto.Mac=function(e){this.setAlgAndProvider=function(e,t){if(e=e.toLowerCase(),null==e&&(e="hmacsha1"),e=e.toLowerCase(),"hmac"!=e.substr(0,4))throw"setAlgAndProvider unsupported HMAC alg: "+e;void 0===t&&(t=Sn.crypto.Util.DEFAULTPROVIDER[e]),this.algProv=e+"/"+t;var n=e.substr(4);if(-1!=":md5:sha1:sha224:sha256:sha384:sha512:ripemd160:".indexOf(n)&&"cryptojs"==t){try{var r=Sn.crypto.Util.CRYPTOJSMESSAGEDIGESTNAME[n];this.mac=l.algo.HMAC.create(r,this.pass)}catch(i){throw"setAlgAndProvider hash alg set fail hashAlg="+n+"/"+i}this.updateString=function(e){this.mac.update(e)},this.updateHex=function(e){var t=l.enc.Hex.parse(e);this.mac.update(t)},this.doFinal=function(){var e=this.mac.finalize();return e.toString(l.enc.Hex)},this.doFinalString=function(e){return this.updateString(e),this.doFinal()},this.doFinalHex=function(e){return this.updateHex(e),this.doFinal()}}},this.updateString=function(e){throw"updateString(str) not supported for this alg/prov: "+this.algProv},this.updateHex=function(e){throw"updateHex(hex) not supported for this alg/prov: "+this.algProv},this.doFinal=function(){throw"digest() not supported for this alg/prov: "+this.algProv},this.doFinalString=function(e){throw"digestString(str) not supported for this alg/prov: "+this.algProv},this.doFinalHex=function(e){throw"digestHex(hex) not supported for this alg/prov: "+this.algProv},this.setPassword=function(e){if("string"==typeof e){var t=e;return e.length%2!=1&&e.match(/^[0-9A-Fa-f]+$/)||(t=Hn(e)),void(this.pass=l.enc.Hex.parse(t))}if("object"!=typeof e)throw"KJUR.crypto.Mac unsupported password type: "+e;t=null;if(void 0!==e.hex){if(e.hex.length%2!=0||!e.hex.match(/^[0-9A-Fa-f]+$/))throw"Mac: wrong hex password: "+e.hex;t=e.hex}if(void 0!==e.utf8&&(t=Vn(e.utf8)),void 0!==e.rstr&&(t=Hn(e.rstr)),void 0!==e.b64&&(t=p(e.b64)),void 0!==e.b64u&&(t=Ln(e.b64u)),null==t)throw"KJUR.crypto.Mac unsupported password type: "+e;this.pass=l.enc.Hex.parse(t)},void 0!==e&&(void 0!==e.pass&&this.setPassword(e.pass),void 0!==e.alg&&(this.algName=e.alg,void 0===e.prov&&(this.provName=Sn.crypto.Util.DEFAULTPROVIDER[this.algName]),this.setAlgAndProvider(this.algName,this.provName)))},Sn.crypto.Signature=function(e){var t=null;if(this._setAlgNames=function(){var e=this.algName.match(/^(.+)with(.+)$/);e&&(this.mdAlgName=e[1].toLowerCase(),this.pubkeyAlgName=e[2].toLowerCase(),"rsaandmgf1"==this.pubkeyAlgName&&"sha"==this.mdAlgName&&(this.mdAlgName="sha1"))},this._zeroPaddingOfSignature=function(e,t){for(var n="",r=t/4-e.length,i=0;i<r;i++)n+="0";return n+e},this.setAlgAndProvider=function(e,t){if(this._setAlgNames(),"cryptojs/jsrsa"!=t)throw new Error("provider not supported: "+t);if(-1!=":md5:sha1:sha224:sha256:sha384:sha512:ripemd160:".indexOf(this.mdAlgName)){try{this.md=new Sn.crypto.MessageDigest({alg:this.mdAlgName})}catch(n){throw new Error("setAlgAndProvider hash alg set fail alg="+this.mdAlgName+"/"+n)}this.init=function(e,t){var n=null;try{n=void 0===t?Lr.getKey(e):Lr.getKey(e,t)}catch(r){throw"init failed:"+r}if(!0===n.isPrivate)this.prvKey=n,this.state="SIGN";else{if(!0!==n.isPublic)throw"init failed.:"+n;this.pubKey=n,this.state="VERIFY"}},this.updateString=function(e){this.md.updateString(e)},this.updateHex=function(e){this.md.updateHex(e)},this.sign=function(){if(this.sHashHex=this.md.digest(),void 0===this.prvKey&&void 0!==this.ecprvhex&&void 0!==this.eccurvename&&void 0!==Sn.crypto.ECDSA&&(this.prvKey=new Sn.crypto.ECDSA({curve:this.eccurvename,prv:this.ecprvhex})),this.prvKey instanceof Ft&&"rsaandmgf1"===this.pubkeyAlgName)this.hSign=this.prvKey.signWithMessageHashPSS(this.sHashHex,this.mdAlgName,this.pssSaltLen);else if(this.prvKey instanceof Ft&&"rsa"===this.pubkeyAlgName)this.hSign=this.prvKey.signWithMessageHash(this.sHashHex,this.mdAlgName);else if(this.prvKey instanceof Sn.crypto.ECDSA)this.hSign=this.prvKey.signWithMessageHash(this.sHashHex);else{if(!(this.prvKey instanceof Sn.crypto.DSA))throw"Signature: unsupported private key alg: "+this.pubkeyAlgName;this.hSign=this.prvKey.signWithMessageHash(this.sHashHex)}return this.hSign},this.signString=function(e){return this.updateString(e),this.sign()},this.signHex=function(e){return this.updateHex(e),this.sign()},this.verify=function(e){if(this.sHashHex=this.md.digest(),void 0===this.pubKey&&void 0!==this.ecpubhex&&void 0!==this.eccurvename&&void 0!==Sn.crypto.ECDSA&&(this.pubKey=new Sn.crypto.ECDSA({curve:this.eccurvename,pub:this.ecpubhex})),this.pubKey instanceof Ft&&"rsaandmgf1"===this.pubkeyAlgName)return this.pubKey.verifyWithMessageHashPSS(this.sHashHex,e,this.mdAlgName,this.pssSaltLen);if(this.pubKey instanceof Ft&&"rsa"===this.pubkeyAlgName)return this.pubKey.verifyWithMessageHash(this.sHashHex,e);if(void 0!==Sn.crypto.ECDSA&&this.pubKey instanceof Sn.crypto.ECDSA)return this.pubKey.verifyWithMessageHash(this.sHashHex,e);if(void 0!==Sn.crypto.DSA&&this.pubKey instanceof Sn.crypto.DSA)return this.pubKey.verifyWithMessageHash(this.sHashHex,e);throw"Signature: unsupported public key alg: "+this.pubkeyAlgName}}},this.init=function(e,t){throw"init(key, pass) not supported for this alg:prov="+this.algProvName},this.updateString=function(e){throw"updateString(str) not supported for this alg:prov="+this.algProvName},this.updateHex=function(e){throw"updateHex(hex) not supported for this alg:prov="+this.algProvName},this.sign=function(){throw"sign() not supported for this alg:prov="+this.algProvName},this.signString=function(e){throw"digestString(str) not supported for this alg:prov="+this.algProvName},this.signHex=function(e){throw"digestHex(hex) not supported for this alg:prov="+this.algProvName},this.verify=function(e){throw"verify(hSigVal) not supported for this alg:prov="+this.algProvName},this.initParams=e,void 0!==e&&(void 0!==e.alg&&(this.algName=e.alg,void 0===e.prov?this.provName=Sn.crypto.Util.DEFAULTPROVIDER[this.algName]:this.provName=e.prov,this.algProvName=this.algName+":"+this.provName,this.setAlgAndProvider(this.algName,this.provName),this._setAlgNames()),void 0!==e.psssaltlen&&(this.pssSaltLen=e.psssaltlen),void 0!==e.prvkeypem)){if(void 0!==e.prvkeypas)throw"both prvkeypem and prvkeypas parameters not supported";try{t=Lr.getKey(e.prvkeypem);this.init(t)}catch(n){throw"fatal error to load pem private key: "+n}}},Sn.crypto.Cipher=function(e){},Sn.crypto.Cipher.encrypt=function(e,t,n,r){if(void 0!=Mr(r,"enclag")&&(n=r.encalg),"string"==typeof n&&"-CBC"==n.substr(-4)){var i=t,o=e;void 0!=Mr(r,"key")&&(i=r.key),void 0!=Mr(r,"enc")&&(hEnc=r.enc);var a,s=l.enc.Hex.parse(i),c=l.enc.Hex.parse(o),u=l.enc.Hex.parse(r.iv);if("des-EDE3-CBC"==n)a=l.TripleDES.encrypt(c,s,{iv:u});else{if("aes128-CBC"!=n&&"aes256-CBC"!=n)throw new Error("unsupported algorithm: "+n);a=l.AES.encrypt(c,s,{iv:u})}return a+""}throw new Error("Cipher.encrypt: unsupported key or algorithm")},Sn.crypto.Cipher.decrypt=function(e,t,n,r){if(void 0!=Mr(r,"enclag")&&(n=r.encalg),"string"==typeof n&&"-CBC"==n.substr(-4)){var i=t,o=e;void 0!=Mr(r,"key")&&(i=r.key),void 0!=Mr(r,"enc")&&(o=r.enc);var a,s=l.enc.Hex.parse(i),c=l.enc.Hex.parse(o),u=l.enc.Hex.parse(r.iv);if("des-EDE3-CBC"==n)a=l.TripleDES.decrypt({ciphertext:c},s,{iv:u});else{if("aes128-CBC"!=n&&"aes256-CBC"!=n)throw new Error("unsupported algorithm: "+n);a=l.AES.decrypt({ciphertext:c},s,{iv:u})}return l.enc.Hex.stringify(a)}throw new Error("Cipher.decrypt: unsupported key or algorithm")},Sn.crypto.OID=new function(){this.oidhex2name={"2a864886f70d010101":"rsaEncryption","2a8648ce3d0201":"ecPublicKey","2a8648ce380401":"dsa","2a8648ce3d030107":"secp256r1","2b8104001f":"secp192k1","2b81040021":"secp224r1","2b8104000a":"secp256k1","2b81040022":"secp384r1","2b81040023":"secp521r1","2a8648ce380403":"SHA1withDSA","608648016503040301":"SHA224withDSA","608648016503040302":"SHA256withDSA"}},"undefined"!=typeof Sn&&Sn||(Sn={}),"undefined"!=typeof Sn.crypto&&Sn.crypto||(Sn.crypto={}),Sn.crypto.ECDSA=function(e){var t="secp256r1",n=Error,r=v,i=nn,o=Sn.crypto.ECDSA,a=Sn.crypto.ECParameterDB,s=o.getName,l=_n,c=l.getVbyListEx,u=l.isASN1HEX,d=new $t;this.type="EC",this.isPrivate=!1,this.isPublic=!1,this.getBigRandom=function(e){return new r(e.bitLength(),d).mod(e.subtract(r.ONE)).add(r.ONE)},this.setNamedCurve=function(e){this.ecparams=a.getByName(e),this.prvKeyHex=null,this.pubKeyHex=null,this.curveName=e},this.setPrivateKeyHex=function(e){this.isPrivate=!0,this.prvKeyHex=e},this.setPublicKeyHex=function(e){this.isPublic=!0,this.pubKeyHex=e},this.getPublicKeyXYHex=function(){var e=this.pubKeyHex;if("04"!==e.substr(0,2))throw"this method supports uncompressed format(04) only";var t=this.ecparams.keycharlen;if(e.length!==2+2*t)throw"malformed public key hex length";var n={};return n.x=e.substr(2,t),n.y=e.substr(2+t),n},this.getShortNISTPCurveName=function(){var e=this.curveName;return"secp256r1"===e||"NIST P-256"===e||"P-256"===e||"prime256v1"===e?"P-256":"secp384r1"===e||"NIST P-384"===e||"P-384"===e?"P-384":"secp521r1"===e||"NIST P-521"===e||"P-521"===e?"P-521":null},this.generateKeyPairHex=function(){var e=this.ecparams.n,t=this.getBigRandom(e),n=this.ecparams.keycharlen,r=("0000000000"+t.toString(16)).slice(-n);this.setPrivateKeyHex(r);var i=this.generatePublicKeyHex();return{ecprvhex:r,ecpubhex:i}},this.generatePublicKeyHex=function(){var e=new r(this.prvKeyHex,16),t=this.ecparams.G.multiply(e),n=t.getX().toBigInteger(),i=t.getY().toBigInteger(),o=this.ecparams.keycharlen,a=("0000000000"+n.toString(16)).slice(-o),s=("0000000000"+i.toString(16)).slice(-o),l="04"+a+s;return this.setPublicKeyHex(l),l},this.signWithMessageHash=function(e){return this.signHex(e,this.prvKeyHex)},this.signHex=function(e,t){var n=new r(t,16),i=this.ecparams.n,a=new r(e.substring(0,this.ecparams.keycharlen),16);do{var s=this.getBigRandom(i),l=this.ecparams.G,c=l.multiply(s),u=c.getX().toBigInteger().mod(i)}while(u.compareTo(r.ZERO)<=0);var d=s.modInverse(i).multiply(a.add(n.multiply(u))).mod(i);return o.biRSSigToASN1Sig(u,d)},this.sign=function(e,t){var n=t,i=this.ecparams.n,o=r.fromByteArrayUnsigned(e);do{var a=this.getBigRandom(i),s=this.ecparams.G,l=s.multiply(a),c=l.getX().toBigInteger().mod(i)}while(c.compareTo(v.ZERO)<=0);var u=a.modInverse(i).multiply(o.add(n.multiply(c))).mod(i);return this.serializeSig(c,u)},this.verifyWithMessageHash=function(e,t){return this.verifyHex(e,t,this.pubKeyHex)},this.verifyHex=function(e,t,n){try{var a,s,l=o.parseSigHex(t);a=l.r,s=l.s;var c=i.decodeFromHex(this.ecparams.curve,n),u=new r(e.substring(0,this.ecparams.keycharlen),16);return this.verifyRaw(u,a,s,c)}catch(d){return!1}},this.verify=function(e,t,n){var o,a,s;if(Bitcoin.Util.isArray(t)){var l=this.parseSig(t);o=l.r,a=l.s}else{if("object"!==typeof t||!t.r||!t.s)throw"Invalid value for signature";o=t.r,a=t.s}if(n instanceof nn)s=n;else{if(!Bitcoin.Util.isArray(n))throw"Invalid format for pubkey value, must be byte array or ECPointFp";s=i.decodeFrom(this.ecparams.curve,n)}var c=r.fromByteArrayUnsigned(e);return this.verifyRaw(c,o,a,s)},this.verifyRaw=function(e,t,n,i){var o=this.ecparams.n,a=this.ecparams.G;if(t.compareTo(r.ONE)<0||t.compareTo(o)>=0)return!1;if(n.compareTo(r.ONE)<0||n.compareTo(o)>=0)return!1;var s=n.modInverse(o),l=e.multiply(s).mod(o),c=t.multiply(s).mod(o),u=a.multiply(l).add(i.multiply(c)),d=u.getX().toBigInteger().mod(o);return d.equals(t)},this.serializeSig=function(e,t){var n=e.toByteArraySigned(),r=t.toByteArraySigned(),i=[];return i.push(2),i.push(n.length),i=i.concat(n),i.push(2),i.push(r.length),i=i.concat(r),i.unshift(i.length),i.unshift(48),i},this.parseSig=function(e){var t;if(48!=e[0])throw new Error("Signature not a valid DERSequence");if(t=2,2!=e[t])throw new Error("First element in signature must be a DERInteger");var n=e.slice(t+2,t+2+e[t+1]);if(t+=2+e[t+1],2!=e[t])throw new Error("Second element in signature must be a DERInteger");var i=e.slice(t+2,t+2+e[t+1]);t+=2+e[t+1];var o=r.fromByteArrayUnsigned(n),a=r.fromByteArrayUnsigned(i);return{r:o,s:a}},this.parseSigCompact=function(e){if(65!==e.length)throw"Signature has the wrong length";var t=e[0]-27;if(t<0||t>7)throw"Invalid signature type";var n=this.ecparams.n,i=r.fromByteArrayUnsigned(e.slice(1,33)).mod(n),o=r.fromByteArrayUnsigned(e.slice(33,65)).mod(n);return{r:i,s:o,i:t}},this.readPKCS5PrvKeyHex=function(e){if(!1===u(e))throw new Error("not ASN.1 hex string");var t,n,r;try{t=c(e,0,["[0]",0],"06"),n=c(e,0,[1],"04");try{r=c(e,0,["[1]",0],"03")}catch(i){}}catch(i){throw new Error("malformed PKCS#1/5 plain ECC private key")}if(this.curveName=s(t),void 0===this.curveName)throw"unsupported curve name";this.setNamedCurve(this.curveName),this.setPublicKeyHex(r),this.setPrivateKeyHex(n),this.isPublic=!1},this.readPKCS8PrvKeyHex=function(e){if(!1===u(e))throw new n("not ASN.1 hex string");var t,r,i;try{c(e,0,[1,0],"06"),t=c(e,0,[1,1],"06"),r=c(e,0,[2,0,1],"04");try{i=c(e,0,[2,0,"[1]",0],"03")}catch(o){}}catch(o){throw new n("malformed PKCS#8 plain ECC private key")}if(this.curveName=s(t),void 0===this.curveName)throw new n("unsupported curve name");this.setNamedCurve(this.curveName),this.setPublicKeyHex(i),this.setPrivateKeyHex(r),this.isPublic=!1},this.readPKCS8PubKeyHex=function(e){if(!1===u(e))throw new n("not ASN.1 hex string");var t,r;try{c(e,0,[0,0],"06"),t=c(e,0,[0,1],"06"),r=c(e,0,[1],"03")}catch(i){throw new n("malformed PKCS#8 ECC public key")}if(this.curveName=s(t),null===this.curveName)throw new n("unsupported curve name");this.setNamedCurve(this.curveName),this.setPublicKeyHex(r)},this.readCertPubKeyHex=function(e,t){if(!1===u(e))throw new n("not ASN.1 hex string");var r,i;try{r=c(e,0,[0,5,0,1],"06"),i=c(e,0,[0,5,1],"03")}catch(o){throw new n("malformed X.509 certificate ECC public key")}if(this.curveName=s(r),null===this.curveName)throw new n("unsupported curve name");this.setNamedCurve(this.curveName),this.setPublicKeyHex(i)},void 0!==e&&void 0!==e.curve&&(this.curveName=e.curve),void 0===this.curveName&&(this.curveName=t),this.setNamedCurve(this.curveName),void 0!==e&&(void 0!==e.prv&&this.setPrivateKeyHex(e.prv),void 0!==e.pub&&this.setPublicKeyHex(e.pub))},Sn.crypto.ECDSA.parseSigHex=function(e){var t=Sn.crypto.ECDSA.parseSigHexInHexRS(e),n=new v(t.r,16),r=new v(t.s,16);return{r:n,s:r}},Sn.crypto.ECDSA.parseSigHexInHexRS=function(e){var t=_n,n=t.getChildIdx,r=t.getV;if(t.checkStrictDER(e,0),"30"!=e.substr(0,2))throw new Error("signature is not a ASN.1 sequence");var i=n(e,0);if(2!=i.length)throw new Error("signature shall have two elements");var o=i[0],a=i[1];if("02"!=e.substr(o,2))throw new Error("1st item not ASN.1 integer");if("02"!=e.substr(a,2))throw new Error("2nd item not ASN.1 integer");var s=r(e,o),l=r(e,a);return{r:s,s:l}},Sn.crypto.ECDSA.asn1SigToConcatSig=function(e){var t=Sn.crypto.ECDSA.parseSigHexInHexRS(e),n=t.r,r=t.s;if(n.length>=130&&n.length<=134){if(n.length%2!=0)throw Error("unknown ECDSA sig r length error");if(r.length%2!=0)throw Error("unknown ECDSA sig s length error");"00"==n.substr(0,2)&&(n=n.substr(2)),"00"==r.substr(0,2)&&(r=r.substr(2));var i=Math.max(n.length,r.length);return n=("000000"+n).slice(-i),r=("000000"+r).slice(-i),n+r}if("00"==n.substr(0,2)&&n.length%32==2&&(n=n.substr(2)),"00"==r.substr(0,2)&&r.length%32==2&&(r=r.substr(2)),n.length%32==30&&(n="00"+n),r.length%32==30&&(r="00"+r),n.length%32!=0)throw Error("unknown ECDSA sig r length error");if(r.length%32!=0)throw Error("unknown ECDSA sig s length error");return n+r},Sn.crypto.ECDSA.concatSigToASN1Sig=function(e){if(e.length%4!=0)throw Error("unknown ECDSA concatinated r-s sig length error");var t=e.substr(0,e.length/2),n=e.substr(e.length/2);return Sn.crypto.ECDSA.hexRSSigToASN1Sig(t,n)},Sn.crypto.ECDSA.hexRSSigToASN1Sig=function(e,t){var n=new v(e,16),r=new v(t,16);return Sn.crypto.ECDSA.biRSSigToASN1Sig(n,r)},Sn.crypto.ECDSA.biRSSigToASN1Sig=function(e,t){var n=Sn.asn1,r=new n.DERInteger({bigint:e}),i=new n.DERInteger({bigint:t}),o=new n.DERSequence({array:[r,i]});return o.tohex()},Sn.crypto.ECDSA.getName=function(e){return"2b8104001f"===e?"secp192k1":"2a8648ce3d030107"===e?"secp256r1":"2b8104000a"===e?"secp256k1":"2b81040021"===e?"secp224r1":"2b81040022"===e?"secp384r1":"2b81040023"===e?"secp521r1":-1!=="|secp256r1|NIST P-256|P-256|prime256v1|".indexOf(e)?"secp256r1":-1!=="|secp256k1|".indexOf(e)?"secp256k1":-1!=="|secp224r1|NIST P-224|P-224|".indexOf(e)?"secp224r1":-1!=="|secp384r1|NIST P-384|P-384|".indexOf(e)?"secp384r1":-1!=="|secp521r1|NIST P-521|P-521|".indexOf(e)?"secp521r1":null},"undefined"!=typeof Sn&&Sn||(Sn={}),"undefined"!=typeof Sn.crypto&&Sn.crypto||(Sn.crypto={}),Sn.crypto.ECParameterDB=new function(){var e={},t={};function n(e){return new v(e,16)}this.getByName=function(n){var r=n;if("undefined"!=typeof t[r]&&(r=t[n]),"undefined"!=typeof e[r])return e[r];throw"unregistered EC curve name: "+r},this.regist=function(r,i,o,a,s,l,c,u,d,h,p,f){e[r]={};var m=n(o),g=n(a),v=n(s),b=n(l),y=n(c),w=new pn(m,g,v),O=w.decodePointHex("04"+u+d);e[r]["name"]=r,e[r]["keylen"]=i,e[r]["keycharlen"]=2*Math.ceil(i/8),e[r]["curve"]=w,e[r]["G"]=O,e[r]["n"]=b,e[r]["h"]=y,e[r]["oid"]=p,e[r]["info"]=f;for(var S=0;S<h.length;S++)t[h[S]]=r}},Sn.crypto.ECParameterDB.regist("secp128r1",128,"FFFFFFFDFFFFFFFFFFFFFFFFFFFFFFFF","FFFFFFFDFFFFFFFFFFFFFFFFFFFFFFFC","E87579C11079F43DD824993C2CEE5ED3","FFFFFFFE0000000075A30D1B9038A115","1","161FF7528B899B2D0C28607CA52C5B86","CF5AC8395BAFEB13C02DA292DDED7A83",[],"","secp128r1 : SECG curve over a 128 bit prime field"),Sn.crypto.ECParameterDB.regist("secp160k1",160,"FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFAC73","0","7","0100000000000000000001B8FA16DFAB9ACA16B6B3","1","3B4C382CE37AA192A4019E763036F4F5DD4D7EBB","938CF935318FDCED6BC28286531733C3F03C4FEE",[],"","secp160k1 : SECG curve over a 160 bit prime field"),Sn.crypto.ECParameterDB.regist("secp160r1",160,"FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF7FFFFFFF","FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF7FFFFFFC","1C97BEFC54BD7A8B65ACF89F81D4D4ADC565FA45","0100000000000000000001F4C8F927AED3CA752257","1","4A96B5688EF573284664698968C38BB913CBFC82","23A628553168947D59DCC912042351377AC5FB32",[],"","secp160r1 : SECG curve over a 160 bit prime field"),Sn.crypto.ECParameterDB.regist("secp192k1",192,"FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFEE37","0","3","FFFFFFFFFFFFFFFFFFFFFFFE26F2FC170F69466A74DEFD8D","1","DB4FF10EC057E9AE26B07D0280B7F4341DA5D1B1EAE06C7D","9B2F2F6D9C5628A7844163D015BE86344082AA88D95E2F9D",[]),Sn.crypto.ECParameterDB.regist("secp192r1",192,"FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFFFFFFFFFF","FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFFFFFFFFFC","64210519E59C80E70FA7E9AB72243049FEB8DEECC146B9B1","FFFFFFFFFFFFFFFFFFFFFFFF99DEF836146BC9B1B4D22831","1","188DA80EB03090F67CBF20EB43A18800F4FF0AFD82FF1012","07192B95FFC8DA78631011ED6B24CDD573F977A11E794811",[]),Sn.crypto.ECParameterDB.regist("secp224r1",224,"FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF000000000000000000000001","FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFFFFFFFFFFFFFFFFFE","B4050A850C04B3ABF54132565044B0B7D7BFD8BA270B39432355FFB4","FFFFFFFFFFFFFFFFFFFFFFFFFFFF16A2E0B8F03E13DD29455C5C2A3D","1","B70E0CBD6BB4BF7F321390B94A03C1D356C21122343280D6115C1D21","BD376388B5F723FB4C22DFE6CD4375A05A07476444D5819985007E34",[]),Sn.crypto.ECParameterDB.regist("secp256k1",256,"FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFC2F","0","7","FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141","1","79BE667EF9DCBBAC55A06295CE870B07029BFCDB2DCE28D959F2815B16F81798","483ADA7726A3C4655DA4FBFC0E1108A8FD17B448A68554199C47D08FFB10D4B8",[]),Sn.crypto.ECParameterDB.regist("secp256r1",256,"FFFFFFFF00000001000000000000000000000000FFFFFFFFFFFFFFFFFFFFFFFF","FFFFFFFF00000001000000000000000000000000FFFFFFFFFFFFFFFFFFFFFFFC","5AC635D8AA3A93E7B3EBBD55769886BC651D06B0CC53B0F63BCE3C3E27D2604B","FFFFFFFF00000000FFFFFFFFFFFFFFFFBCE6FAADA7179E84F3B9CAC2FC632551","1","6B17D1F2E12C4247F8BCE6E563A440F277037D812DEB33A0F4A13945D898C296","4FE342E2FE1A7F9B8EE7EB4A7C0F9E162BCE33576B315ECECBB6406837BF51F5",["NIST P-256","P-256","prime256v1"]),Sn.crypto.ECParameterDB.regist("secp384r1",384,"FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFF0000000000000000FFFFFFFF","FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFF0000000000000000FFFFFFFC","B3312FA7E23EE7E4988E056BE3F82D19181D9C6EFE8141120314088F5013875AC656398D8A2ED19D2A85C8EDD3EC2AEF","FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFC7634D81F4372DDF581A0DB248B0A77AECEC196ACCC52973","1","AA87CA22BE8B05378EB1C71EF320AD746E1D3B628BA79B9859F741E082542A385502F25DBF55296C3A545E3872760AB7","3617de4a96262c6f5d9e98bf9292dc29f8f41dbd289a147ce9da3113b5f0b8c00a60b1ce1d7e819d7a431d7c90ea0e5f",["NIST P-384","P-384"]),Sn.crypto.ECParameterDB.regist("secp521r1",521,"1FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF","1FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFC","051953EB9618E1C9A1F929A21A0B68540EEA2DA725B99B315F3B8B489918EF109E156193951EC7E937B1652C0BD3BB1BF073573DF883D2C34F1EF451FD46B503F00","1FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFA51868783BF2F966B7FCC0148F709A5D03BB5C9B8899C47AEBB6FB71E91386409","1","00C6858E06B70404E9CD9E3ECB662395B4429C648139053FB521F828AF606B4D3DBAA14B5E77EFE75928FE1DC127A2FFA8DE3348B3C1856A429BF97E7E31C2E5BD66","011839296a789a3bc0045c8a5fb42c7d1bd998f54449579b446817afbd17273e662c97ee72995ef42640c550b9013fad0761353c7086a272c24088be94769fd16650",["NIST P-521","P-521"]),"undefined"!=typeof Sn&&Sn||(Sn={}),"undefined"!=typeof Sn.crypto&&Sn.crypto||(Sn.crypto={}),Sn.crypto.DSA=function(){var e=_n,t=(e.getVbyList,e.getVbyListEx),n=e.isASN1HEX,r=v,i=v.ONE,o=function(e,t,n,r){if(null==e||null==t||null==n||null==r)throw new Error("invalid DSA public key");if(i.compareTo(t)>=0||t.compareTo(e)>=0)throw new Error("invalid DSA public key");if(i.compareTo(n)>=0||n.compareTo(e)>=0)throw new Error("invalid DSA public key");if(i.compareTo(r)>=0||r.compareTo(e)>=0)throw new Error("invalid DSA public key");if(0!=n.modPow(t,e).compareTo(i))throw new Error("invalid DSA public key")};this.p=null,this.q=null,this.g=null,this.y=null,this.x=null,this.type="DSA",this.isPrivate=!1,this.isPublic=!1,this.setPrivate=function(e,t,n,r,i){this.isPrivate=!0,this.p=e,this.q=t,this.g=n,this.y=r,this.x=i},this.setPrivateHex=function(e,t,n,r,i){var o,a,s,l,c;o=new v(e,16),a=new v(t,16),s=new v(n,16),l="string"===typeof r&&r.length>1?new v(r,16):null,c=new v(i,16),this.setPrivate(o,a,s,l,c)},this.setPublic=function(e,t,n,r){o(e,t,n,r),this.isPublic=!0,this.p=e,this.q=t,this.g=n,this.y=r,this.x=null},this.setPublicHex=function(e,t,n,r){var i,o,a,s;i=new v(e,16),o=new v(t,16),a=new v(n,16),s=new v(r,16),this.setPublic(i,o,a,s)},this.signWithMessageHash=function(e){var t,n,r,i=this.p,o=this.q,a=this.g,s=(this.y,this.x),l=e.substr(0,o.bitLength()/4),c=new v(l,16);do{t=Sn.crypto.Util.getRandomBigIntegerMinToMax(v.ONE.add(v.ONE),o.subtract(v.ONE)),n=a.modPow(t,i).mod(o),r=t.modInverse(o).multiply(c.add(s.multiply(n))).mod(o)}while(0==n.compareTo(v.ZERO)||0==r.compareTo(v.ZERO));var u=Sn.asn1.ASN1Util.jsonToASN1HEX({seq:[{int:{bigint:n}},{int:{bigint:r}}]});return u},this.verifyWithMessageHash=function(e,t){var n=this.p,r=this.q,i=this.g,o=this.y,a=this.parseASN1Signature(t),s=a[0],l=a[1],c=e.substr(0,r.bitLength()/4),u=new v(c,16);if(v.ZERO.compareTo(s)>0||s.compareTo(r)>0)throw"invalid DSA signature";if(v.ZERO.compareTo(l)>=0||l.compareTo(r)>0)throw"invalid DSA signature";var d=l.modInverse(r),h=u.multiply(d).mod(r),p=s.multiply(d).mod(r),f=i.modPow(h,n).multiply(o.modPow(p,n)).mod(n).mod(r);return 0==f.compareTo(s)},this.parseASN1Signature=function(e){try{var n=new r(t(e,0,[0],"02"),16),i=new r(t(e,0,[1],"02"),16);return[n,i]}catch(o){throw new Error("malformed ASN.1 DSA signature")}},this.readPKCS5PrvKeyHex=function(e){var r,i,o,a,s;if(!1===n(e))throw new Error("not ASN.1 hex string");try{r=t(e,0,[1],"02"),i=t(e,0,[2],"02"),o=t(e,0,[3],"02"),a=t(e,0,[4],"02"),s=t(e,0,[5],"02")}catch(l){throw new Error("malformed PKCS#1/5 plain DSA private key")}this.setPrivateHex(r,i,o,a,s)},this.readPKCS8PrvKeyHex=function(e){var r,i,o,a;if(!1===n(e))throw new Error("not ASN.1 hex string");try{r=t(e,0,[1,1,0],"02"),i=t(e,0,[1,1,1],"02"),o=t(e,0,[1,1,2],"02"),a=t(e,0,[2,0],"02")}catch(s){throw new Error("malformed PKCS#8 plain DSA private key")}this.setPrivateHex(r,i,o,null,a)},this.readPKCS8PubKeyHex=function(e){var r,i,o,a;if(!1===n(e))throw new Error("not ASN.1 hex string");try{r=t(e,0,[0,1,0],"02"),i=t(e,0,[0,1,1],"02"),o=t(e,0,[0,1,2],"02"),a=t(e,0,[1,0],"02")}catch(s){throw new Error("malformed PKCS#8 DSA public key")}this.setPublicHex(r,i,o,a)},this.readCertPubKeyHex=function(e,r){var i,o,a,s;if(!1===n(e))throw new Error("not ASN.1 hex string");try{i=t(e,0,[0,5,0,1,0],"02"),o=t(e,0,[0,5,0,1,1],"02"),a=t(e,0,[0,5,0,1,2],"02"),s=t(e,0,[0,5,1,0],"02")}catch(l){throw new Error("malformed X.509 certificate DSA public key")}this.setPublicHex(i,o,a,s)}};var Lr=function(){var e=function(e,t,n){return r(l.AES,e,t,n)},t=function(e,t,n){return r(l.TripleDES,e,t,n)},n=function(e,t,n){return r(l.DES,e,t,n)},r=function(e,t,n,r){var i=l.enc.Hex.parse(t),o=l.enc.Hex.parse(n),a=l.enc.Hex.parse(r),s={};s.key=o,s.iv=a,s.ciphertext=i;var c=e.decrypt(s,o,{iv:a});return l.enc.Hex.stringify(c)},i=function(e,t,n){return s(l.AES,e,t,n)},o=function(e,t,n){return s(l.TripleDES,e,t,n)},a=function(e,t,n){return s(l.DES,e,t,n)},s=function(e,t,n,r){var i=l.enc.Hex.parse(t),o=l.enc.Hex.parse(n),a=l.enc.Hex.parse(r),s=e.encrypt(i,o,{iv:a}),c=l.enc.Hex.parse(s.toString()),u=l.enc.Base64.stringify(c);return u},c={"AES-256-CBC":{proc:e,eproc:i,keylen:32,ivlen:16},"AES-192-CBC":{proc:e,eproc:i,keylen:24,ivlen:16},"AES-128-CBC":{proc:e,eproc:i,keylen:16,ivlen:16},"DES-EDE3-CBC":{proc:t,eproc:o,keylen:24,ivlen:8},"DES-CBC":{proc:n,eproc:a,keylen:8,ivlen:8}},u=function(e){var t=l.lib.WordArray.random(e),n=l.enc.Hex.stringify(t);return n},d=function(e){var t={},n=e.match(new RegExp("DEK-Info: ([^,]+),([0-9A-Fa-f]+)","m"));n&&(t.cipher=n[1],t.ivsalt=n[2]);var r=e.match(new RegExp("-----BEGIN ([A-Z]+) PRIVATE KEY-----"));r&&(t.type=r[1]);var i=-1,o=0;-1!=e.indexOf("\r\n\r\n")&&(i=e.indexOf("\r\n\r\n"),o=2),-1!=e.indexOf("\n\n")&&(i=e.indexOf("\n\n"),o=1);var a=e.indexOf("-----END");if(-1!=i&&-1!=a){var s=e.substring(i+2*o,a-o);s=s.replace(/\s+/g,""),t.data=s}return t},h=function(e,t,n){for(var r=n.substring(0,16),i=l.enc.Hex.parse(r),o=l.enc.Utf8.parse(t),a=c[e]["keylen"]+c[e]["ivlen"],s="",u=null;;){var d=l.algo.MD5.create();if(null!=u&&d.update(u),d.update(o),d.update(i),u=d.finalize(),s+=l.enc.Hex.stringify(u),s.length>=2*a)break}var h={};return h.keyhex=s.substr(0,2*c[e]["keylen"]),h.ivhex=s.substr(2*c[e]["keylen"],2*c[e]["ivlen"]),h},p=function(e,t,n,r){var i=l.enc.Base64.parse(e),o=l.enc.Hex.stringify(i),a=c[t]["proc"],s=a(o,n,r);return s},f=function(e,t,n,r){var i=c[t]["eproc"],o=i(e,n,r);return o};return{version:"1.0.0",parsePKCS5PEM:function(e){return d(e)},getKeyAndUnusedIvByPasscodeAndIvsalt:function(e,t,n){return h(e,t,n)},decryptKeyB64:function(e,t,n,r){return p(e,t,n,r)},getDecryptedKeyHex:function(e,t){var n=d(e),r=(n.type,n.cipher),i=n.ivsalt,o=n.data,a=h(r,t,i),s=a.keyhex,l=p(o,r,s,i);return l},getEncryptedPKCS5PEMFromPrvKeyHex:function(e,t,n,r,i){var o="";if("undefined"!=typeof r&&null!=r||(r="AES-256-CBC"),"undefined"==typeof c[r])throw new Error("KEYUTIL unsupported algorithm: "+r);if("undefined"==typeof i||null==i){var a=c[r]["ivlen"],s=u(a);i=s.toUpperCase()}var l=h(r,n,i),d=l.keyhex,p=f(t,r,d,i),m=p.replace(/(.{64})/g,"$1\r\n");o="-----BEGIN "+e+" PRIVATE KEY-----\r\n";return o+="Proc-Type: 4,ENCRYPTED\r\n",o+="DEK-Info: "+r+","+i+"\r\n",o+="\r\n",o+=m,o+="\r\n-----END "+e+" PRIVATE KEY-----\r\n",o},getEncryptedPKCS8PEM:function(e,t,n){var r=this.getEncryptedPKCS8Hex(e,t,n);return Xn(r,"ENCRYPTED PRIVATE KEY")},getEncryptedPKCS8Hex:function(e,t,n){var r;r=void 0==n||null==n?{}:JSON.parse(JSON.stringify(n)),r.plain=e,this.initPBES2Param(r),this.encryptPBES2Param(r,t);var i=this.generatePBES2ASN1Param(r);return Sn.asn1.ASN1Util.newObject(i).tohex()},initPBES2Param:function(e){var t;(void 0==Mr(e,"encalg")&&(e.encalg="aes256-CBC"),void 0==Mr(e,"iter")&&(e.iter=2048),void 0==Mr(e,"prf")&&(e.prf="hmacWithSHA256"),void 0==Mr(e,"salt")&&(e.salt=l.enc.Hex.stringify(l.lib.WordArray.random(8))),void 0==Mr(e,"enciv"))&&("des-EDE3-CBC"==e.encalg&&(t=8),"aes128-CBC"==e.encalg&&(t=16),"aes256-CBC"==e.encalg&&(t=16),e.enciv=l.enc.Hex.stringify(l.lib.WordArray.random(t)))},encryptPBES2Param:function(e,t){var n=Lr.getDKFromPBES2Param(e,t);try{var r=Sn.crypto.Cipher.encrypt(e.plain,n,e.encalg,{iv:e.enciv})}catch(i){throw new Error("encrypt error: "+e.plain+" "+n+" "+e.encalg+" "+e.enciv)}e.enc=r},generatePBES2ASN1Param:function(e){var t={seq:[{seq:[{oid:"pkcs5PBES2"},{seq:[{seq:[{oid:"pkcs5PBKDF2"},{seq:[{octstr:{hex:e.salt}},{int:{hex:kr(e.iter)}}]}]},{seq:[{oid:e.encalg},{octstr:{hex:e.enciv}}]}]}]},{octstr:{hex:e.enc}}]};return"hmacWithSHA1"!=e.prf&&t.seq[0].seq[1].seq[0].seq[1].seq.push({seq:[{oid:e.prf},{null:""}]}),t},parseHexOfEncryptedPKCS8:function(e){var t=_n,n=t.getChildIdx,r=t.getV,i={},o=n(e,0);if(2!=o.length)throw new Error("malformed format: SEQUENCE(0).items != 2: "+o.length);i.ciphertext=r(e,o[1]);var a=n(e,o[0]);if(2!=a.length)throw new Error("malformed format: SEQUENCE(0.0).items != 2: "+a.length);if("2a864886f70d01050d"!=r(e,a[0]))throw new Error("this only supports pkcs5PBES2");var s=n(e,a[1]);if(2!=a.length)throw new Error("malformed format: SEQUENCE(0.0.1).items != 2: "+s.length);var l=n(e,s[1]);if(2!=l.length)throw new Error("malformed format: SEQUENCE(0.0.1.1).items != 2: "+l.length);if("2a864886f70d0307"!=r(e,l[0]))throw"this only supports TripleDES";i.encryptionSchemeAlg="TripleDES",i.encryptionSchemeIV=r(e,l[1]);var c=n(e,s[0]);if(2!=c.length)throw new Error("malformed format: SEQUENCE(0.0.1.0).items != 2: "+c.length);if("2a864886f70d01050c"!=r(e,c[0]))throw new Error("this only supports pkcs5PBKDF2");var u=n(e,c[1]);if(u.length<2)throw new Error("malformed format: SEQUENCE(0.0.1.0.1).items < 2: "+u.length);i.pbkdf2Salt=r(e,u[0]);var d=r(e,u[1]);try{i.pbkdf2Iter=parseInt(d,16)}catch(h){throw new Error("malformed format pbkdf2Iter: "+d)}return i},getPBKDF2KeyHexFromParam:function(e,t){var n=l.enc.Hex.parse(e.pbkdf2Salt),r=e.pbkdf2Iter,i=l.PBKDF2(t,n,{keySize:6,iterations:r}),o=l.enc.Hex.stringify(i);return o},_getPlainPKCS8HexFromEncryptedPKCS8PEM:function(e,t){var n=Yn(e,"ENCRYPTED PRIVATE KEY"),r=this.parseHexOfEncryptedPKCS8(n),i=Lr.getPBKDF2KeyHexFromParam(r,t),o={};o.ciphertext=l.enc.Hex.parse(r.ciphertext);var a=l.enc.Hex.parse(i),s=l.enc.Hex.parse(r.encryptionSchemeIV),c=l.TripleDES.decrypt(o,a,{iv:s}),u=l.enc.Hex.stringify(c);return u},parsePBES2:function(e){var t=_n.parse(e);if("pkcs5PBES2"!=Mr(t,"seq.0.seq.0.oid")||"pkcs5PBKDF2"!=Mr(t,"seq.0.seq.1.seq.0.seq.0.oid"))throw new Error("not pkcs5PBES2 and pkcs5PBKDF2 used");var n=Mr(t,"seq.0.seq.1.seq.0.seq.1.seq");if(void 0==n)throw new Error("PBKDF2 parameter not found");var r=Mr(n,"0.octstr.hex"),i=Mr(n,"1.int.hex"),o=Mr(n,"2.seq.0.oid","hmacWithSHA1"),a=-1;try{a=parseInt(i,16)}catch(d){throw new Error("iter not proper value")}var s=Mr(t,"seq.0.seq.1.seq.1.seq.0.oid"),l=Mr(t,"seq.0.seq.1.seq.1.seq.1.octstr.hex"),c=Mr(t,"seq.1.octstr.hex");if(void 0==s||void 0==l||void 0==c)throw new Error("encalg, enciv or enc is undefined");var u={salt:r,iter:a,prf:o,encalg:s,enciv:l,enc:c};return u},getDKFromPBES2Param:function(e,t){var n={hmacWithSHA1:l.algo.SHA1,hmacWithSHA224:l.algo.SHA224,hmacWithSHA256:l.algo.SHA256,hmacWithSHA384:l.algo.SHA384,hmacWithSHA512:l.algo.SHA512},r={"des-EDE3-CBC":6,"aes128-CBC":4,"aes256-CBC":8},i=n[e.prf];if(void 0==i)throw new Error("unsupported prf");var o=r[e.encalg];if(void 0==o)throw new Error("unsupported encalg");var a=l.enc.Hex.parse(e.salt),s=e.iter;try{var c=l.PBKDF2(t,a,{keySize:o,iterations:s,hasher:i});return l.enc.Hex.stringify(c)}catch(Pt){throw new Error("PBKDF2 error: "+Pt+" "+JSON.stringify(e)+" "+t)}},getPlainHexFromEncryptedPKCS8PEM:function(e,t){if(-1==e.indexOf("BEGIN ENCRYPTED PRIVATE KEY"))throw new Error("not Encrypted PKCS#8 PEM string");var n,r=Yn(e);try{n=Lr.parsePBES2(r)}catch(o){throw new Error("malformed PBES2 format: "+o.message)}var i=Lr.getDKFromPBES2Param(n,t);return Sn.crypto.Cipher.decrypt(n.enc,i,n.encalg,{iv:n.enciv})},getKeyFromEncryptedPKCS8PEM:function(e,t){var n=this.getPlainHexFromEncryptedPKCS8PEM(e,t),r=this.getKeyFromPlainPrivatePKCS8Hex(n);return r},parsePlainPrivatePKCS8Hex:function(e){var t=_n,n=t.getChildIdx,r=t.getV,i={algparam:null};if("30"!=e.substr(0,2))throw new Error("malformed plain PKCS8 private key(code:001)");var o=n(e,0);if(o.length<3)throw new Error("malformed plain PKCS8 private key(code:002)");if("30"!=e.substr(o[1],2))throw new Error("malformed PKCS8 private key(code:003)");var a=n(e,o[1]);if(2!=a.length)throw new Error("malformed PKCS8 private key(code:004)");if("06"!=e.substr(a[0],2))throw new Error("malformed PKCS8 private key(code:005)");if(i.algoid=r(e,a[0]),"06"==e.substr(a[1],2)&&(i.algparam=r(e,a[1])),"04"!=e.substr(o[2],2))throw new Error("malformed PKCS8 private key(code:006)");return i.keyidx=t.getVidx(e,o[2]),i},getKeyFromPlainPrivatePKCS8PEM:function(e){var t=Yn(e,"PRIVATE KEY"),n=this.getKeyFromPlainPrivatePKCS8Hex(t);return n},getKeyFromPlainPrivatePKCS8Hex:function(e){var t,n=this.parsePlainPrivatePKCS8Hex(e);if("2a864886f70d010101"==n.algoid)t=new Ft;else if("2a8648ce380401"==n.algoid)t=new Sn.crypto.DSA;else{if("2a8648ce3d0201"!=n.algoid)throw new Error("unsupported private key algorithm");t=new Sn.crypto.ECDSA}return t.readPKCS8PrvKeyHex(e),t},_getKeyFromPublicPKCS8Hex:function(e){var t,n=_n.getVbyList(e,0,[0,0],"06");if("2a864886f70d010101"===n)t=new Ft;else if("2a8648ce380401"===n)t=new Sn.crypto.DSA;else{if("2a8648ce3d0201"!==n)throw new Error("unsupported PKCS#8 public key hex");t=new Sn.crypto.ECDSA}return t.readPKCS8PubKeyHex(e),t},parsePublicRawRSAKeyHex:function(e){var t=_n,n=t.getChildIdx,r=t.getV,i={};if("30"!=e.substr(0,2))throw new Error("malformed RSA key(code:001)");var o=n(e,0);if(2!=o.length)throw new Error("malformed RSA key(code:002)");if("02"!=e.substr(o[0],2))throw new Error("malformed RSA key(code:003)");if(i.n=r(e,o[0]),"02"!=e.substr(o[1],2))throw new Error("malformed RSA key(code:004)");return i.e=r(e,o[1]),i},parsePublicPKCS8Hex:function(e){var t=_n,n=t.getChildIdx,r=t.getV,i={algparam:null},o=n(e,0);if(2!=o.length)throw new Error("outer DERSequence shall have 2 elements: "+o.length);var a=o[0];if("30"!=e.substr(a,2))throw new Error("malformed PKCS8 public key(code:001)");var s=n(e,a);if(2!=s.length)throw new Error("malformed PKCS8 public key(code:002)");if("06"!=e.substr(s[0],2))throw new Error("malformed PKCS8 public key(code:003)");if(i.algoid=r(e,s[0]),"06"==e.substr(s[1],2)?i.algparam=r(e,s[1]):"30"==e.substr(s[1],2)&&(i.algparam={},i.algparam.p=t.getVbyList(e,s[1],[0],"02"),i.algparam.q=t.getVbyList(e,s[1],[1],"02"),i.algparam.g=t.getVbyList(e,s[1],[2],"02")),"03"!=e.substr(o[1],2))throw new Error("malformed PKCS8 public key(code:004)");return i.key=r(e,o[1]).substr(2),i}}}();Lr.getKey=function(e,t,n){var r=_n,i=r.getChildIdx,o=(r.getV,r.getVbyList),a=Sn.crypto,s=a.ECDSA,l=a.DSA,c=Ft,u=Yn,d=Lr;if("undefined"!=typeof c&&e instanceof c)return e;if("undefined"!=typeof s&&e instanceof s)return e;if("undefined"!=typeof l&&e instanceof l)return e;if(void 0!==e.curve&&void 0!==e.xy&&void 0===e.d)return new s({pub:e.xy,curve:e.curve});if(void 0!==e.curve&&void 0!==e.d)return new s({prv:e.d,curve:e.curve});if(void 0===e.kty&&void 0!==e.n&&void 0!==e.e&&void 0===e.d){var h=new c;return h.setPublic(e.n,e.e),h}if(void 0===e.kty&&void 0!==e.n&&void 0!==e.e&&void 0!==e.d&&void 0!==e.p&&void 0!==e.q&&void 0!==e.dp&&void 0!==e.dq&&void 0!==e.co&&void 0===e.qi){h=new c;return h.setPrivateEx(e.n,e.e,e.d,e.p,e.q,e.dp,e.dq,e.co),h}if(void 0===e.kty&&void 0!==e.n&&void 0!==e.e&&void 0!==e.d&&void 0===e.p){h=new c;return h.setPrivate(e.n,e.e,e.d),h}if(void 0!==e.p&&void 0!==e.q&&void 0!==e.g&&void 0!==e.y&&void 0===e.x){h=new l;return h.setPublic(e.p,e.q,e.g,e.y),h}if(void 0!==e.p&&void 0!==e.q&&void 0!==e.g&&void 0!==e.y&&void 0!==e.x){h=new l;return h.setPrivate(e.p,e.q,e.g,e.y,e.x),h}if("RSA"===e.kty&&void 0!==e.n&&void 0!==e.e&&void 0===e.d){h=new c;return h.setPublic(Ln(e.n),Ln(e.e)),h}if("RSA"===e.kty&&void 0!==e.n&&void 0!==e.e&&void 0!==e.d&&void 0!==e.p&&void 0!==e.q&&void 0!==e.dp&&void 0!==e.dq&&void 0!==e.qi){h=new c;return h.setPrivateEx(Ln(e.n),Ln(e.e),Ln(e.d),Ln(e.p),Ln(e.q),Ln(e.dp),Ln(e.dq),Ln(e.qi)),h}if("RSA"===e.kty&&void 0!==e.n&&void 0!==e.e&&void 0!==e.d){h=new c;return h.setPrivate(Ln(e.n),Ln(e.e),Ln(e.d)),h}if("EC"===e.kty&&void 0!==e.crv&&void 0!==e.x&&void 0!==e.y&&void 0===e.d){var p=new s({curve:e.crv}),f=p.ecparams.keycharlen,m=("0000000000"+Ln(e.x)).slice(-f),g=("0000000000"+Ln(e.y)).slice(-f),b="04"+m+g;return p.setPublicKeyHex(b),p}if("EC"===e.kty&&void 0!==e.crv&&void 0!==e.x&&void 0!==e.y&&void 0!==e.d){p=new s({curve:e.crv}),f=p.ecparams.keycharlen,m=("0000000000"+Ln(e.x)).slice(-f),g=("0000000000"+Ln(e.y)).slice(-f),b="04"+m+g;var y=("0000000000"+Ln(e.d)).slice(-f);return p.setPublicKeyHex(b),p.setPrivateKeyHex(y),p}if("pkcs5prv"===n){var w,O=e;r=_n;if(w=i(O,0),9===w.length)h=new c,h.readPKCS5PrvKeyHex(O);else if(6===w.length)h=new l,h.readPKCS5PrvKeyHex(O);else{if(!(w.length>2&&"04"===O.substr(w[1],2)))throw new Error("unsupported PKCS#1/5 hexadecimal key");h=new s,h.readPKCS5PrvKeyHex(O)}return h}if("pkcs8prv"===n){h=d.getKeyFromPlainPrivatePKCS8Hex(e);return h}if("pkcs8pub"===n)return d._getKeyFromPublicPKCS8Hex(e);if("x509pub"===n)return Fr.getPublicKeyFromCertHex(e);if(-1!=e.indexOf("-END CERTIFICATE-",0)||-1!=e.indexOf("-END X509 CERTIFICATE-",0)||-1!=e.indexOf("-END TRUSTED CERTIFICATE-",0))return Fr.getPublicKeyFromCertPEM(e);if(-1!=e.indexOf("-END PUBLIC KEY-")){var S=Yn(e,"PUBLIC KEY");return d._getKeyFromPublicPKCS8Hex(S)}if(-1!=e.indexOf("-END RSA PRIVATE KEY-")&&-1==e.indexOf("4,ENCRYPTED")){var E=u(e,"RSA PRIVATE KEY");return d.getKey(E,null,"pkcs5prv")}if(-1!=e.indexOf("-END DSA PRIVATE KEY-")&&-1==e.indexOf("4,ENCRYPTED")){var x=u(e,"DSA PRIVATE KEY"),_=o(x,0,[1],"02"),k=o(x,0,[2],"02"),C=o(x,0,[3],"02"),A=o(x,0,[4],"02"),T=o(x,0,[5],"02");h=new l;return h.setPrivate(new v(_,16),new v(k,16),new v(C,16),new v(A,16),new v(T,16)),h}if(-1!=e.indexOf("-END EC PRIVATE KEY-")&&-1==e.indexOf("4,ENCRYPTED")){E=u(e,"EC PRIVATE KEY");return d.getKey(E,null,"pkcs5prv")}if(-1!=e.indexOf("-END PRIVATE KEY-"))return d.getKeyFromPlainPrivatePKCS8PEM(e);if(-1!=e.indexOf("-END RSA PRIVATE KEY-")&&-1!=e.indexOf("4,ENCRYPTED")){var R=d.getDecryptedKeyHex(e,t),N=new Ft;return N.readPKCS5PrvKeyHex(R),N}if(-1!=e.indexOf("-END EC PRIVATE KEY-")&&-1!=e.indexOf("4,ENCRYPTED")){x=d.getDecryptedKeyHex(e,t),h=o(x,0,[1],"04");var P=o(x,0,[2,0],"06"),I=o(x,0,[3,0],"03").substr(2),M="";if(void 0===Sn.crypto.OID.oidhex2name[P])throw new Error("undefined OID(hex) in KJUR.crypto.OID: "+P);M=Sn.crypto.OID.oidhex2name[P];p=new s({curve:M});return p.setPublicKeyHex(I),p.setPrivateKeyHex(h),p.isPublic=!1,p}if(-1!=e.indexOf("-END DSA PRIVATE KEY-")&&-1!=e.indexOf("4,ENCRYPTED")){x=d.getDecryptedKeyHex(e,t),_=o(x,0,[1],"02"),k=o(x,0,[2],"02"),C=o(x,0,[3],"02"),A=o(x,0,[4],"02"),T=o(x,0,[5],"02"),h=new l;return h.setPrivate(new v(_,16),new v(k,16),new v(C,16),new v(A,16),new v(T,16)),h}if(-1!=e.indexOf("-END ENCRYPTED PRIVATE KEY-"))return d.getKeyFromEncryptedPKCS8PEM(e,t);throw new Error("not supported argument")},Lr.generateKeypair=function(e,t){if("RSA"==e){var n=t,r=new Ft;r.generate(n,"10001"),r.isPrivate=!0,r.isPublic=!0;var i=new Ft,o=r.n.toString(16),a=r.e.toString(16);i.setPublic(o,a),i.isPrivate=!1,i.isPublic=!0;var s={};return s.prvKeyObj=r,s.pubKeyObj=i,s}if("EC"==e){var l=t,c=new Sn.crypto.ECDSA({curve:l}),u=c.generateKeyPairHex();r=new Sn.crypto.ECDSA({curve:l});r.setPublicKeyHex(u.ecpubhex),r.setPrivateKeyHex(u.ecprvhex),r.isPrivate=!0,r.isPublic=!1;i=new Sn.crypto.ECDSA({curve:l});i.setPublicKeyHex(u.ecpubhex),i.isPrivate=!1,i.isPublic=!0;s={};return s.prvKeyObj=r,s.pubKeyObj=i,s}throw new Error("unknown algorithm: "+e)},Lr.getPEM=function(e,t,n,r,i,o){var a=Sn,s=a.asn1,l=s.DERObjectIdentifier,c=s.DERInteger,u=s.ASN1Util.newObject,d=s.x509,h=d.SubjectPublicKeyInfo,p=a.crypto,f=p.DSA,m=p.ECDSA,g=Ft;function v(e){var t=u({seq:[{int:0},{int:{bigint:e.n}},{int:e.e},{int:{bigint:e.d}},{int:{bigint:e.p}},{int:{bigint:e.q}},{int:{bigint:e.dmp1}},{int:{bigint:e.dmq1}},{int:{bigint:e.coeff}}]});return t}function b(e){var t=u({seq:[{int:1},{octstr:{hex:e.prvKeyHex}},{tag:["a0",!0,{oid:{name:e.curveName}}]},{tag:["a1",!0,{bitstr:{hex:"00"+e.pubKeyHex}}]}]});return t}function y(e){var t=u({seq:[{int:0},{int:{bigint:e.p}},{int:{bigint:e.q}},{int:{bigint:e.g}},{int:{bigint:e.y}},{int:{bigint:e.x}}]});return t}if((void 0!==g&&e instanceof g||void 0!==f&&e instanceof f||void 0!==m&&e instanceof m)&&1==e.isPublic&&(void 0===t||"PKCS8PUB"==t)){var w=new h(e),O=w.tohex();return Xn(O,"PUBLIC KEY")}if("PKCS1PRV"==t&&void 0!==g&&e instanceof g&&(void 0===n||null==n)&&1==e.isPrivate){w=v(e),O=w.tohex();return Xn(O,"RSA PRIVATE KEY")}if("PKCS1PRV"==t&&void 0!==m&&e instanceof m&&(void 0===n||null==n)&&1==e.isPrivate){var S=new l({name:e.curveName}),E=S.tohex(),x=b(e),_=x.tohex(),k="";return k+=Xn(E,"EC PARAMETERS"),k+=Xn(_,"EC PRIVATE KEY"),k}if("PKCS1PRV"==t&&void 0!==f&&e instanceof f&&(void 0===n||null==n)&&1==e.isPrivate){w=y(e),O=w.tohex();return Xn(O,"DSA PRIVATE KEY")}if("PKCS5PRV"==t&&void 0!==g&&e instanceof g&&void 0!==n&&null!=n&&1==e.isPrivate){w=v(e),O=w.tohex();return void 0===r&&(r="DES-EDE3-CBC"),this.getEncryptedPKCS5PEMFromPrvKeyHex("RSA",O,n,r,o)}if("PKCS5PRV"==t&&void 0!==m&&e instanceof m&&void 0!==n&&null!=n&&1==e.isPrivate){w=b(e),O=w.tohex();return void 0===r&&(r="DES-EDE3-CBC"),this.getEncryptedPKCS5PEMFromPrvKeyHex("EC",O,n,r,o)}if("PKCS5PRV"==t&&void 0!==f&&e instanceof f&&void 0!==n&&null!=n&&1==e.isPrivate){w=y(e),O=w.tohex();return void 0===r&&(r="DES-EDE3-CBC"),this.getEncryptedPKCS5PEMFromPrvKeyHex("DSA",O,n,r,o)}var C=function(e,t){if("string"==typeof t)return Lr.getEncryptedPKCS8PEM(e,t);if("object"==typeof t&&void 0!=Mr(t,"passcode")){var n=JSON.parse(JSON.stringify(t)),r=n.passcode;return delete n.passcode,Lr.getEncryptedPKCS8PEM(e,r,n)}};if("PKCS8PRV"==t&&void 0!=g&&e instanceof g&&1==e.isPrivate){var A=v(e),T=A.tohex();w=u({seq:[{int:0},{seq:[{oid:{name:"rsaEncryption"}},{null:!0}]},{octstr:{hex:T}}]}),O=w.tohex();return void 0===n||null==n?Xn(O,"PRIVATE KEY"):C(O,n)}if("PKCS8PRV"==t&&void 0!==m&&e instanceof m&&1==e.isPrivate){var R={seq:[{int:1},{octstr:{hex:e.prvKeyHex}}]};"string"==typeof e.pubKeyHex&&R.seq.push({tag:["a1",!0,{bitstr:{hex:"00"+e.pubKeyHex}}]});A=new u(R),T=A.tohex(),w=u({seq:[{int:0},{seq:[{oid:{name:"ecPublicKey"}},{oid:{name:e.curveName}}]},{octstr:{hex:T}}]}),O=w.tohex();return void 0===n||null==n?Xn(O,"PRIVATE KEY"):C(O,n)}if("PKCS8PRV"==t&&void 0!==f&&e instanceof f&&1==e.isPrivate){A=new c({bigint:e.x}),T=A.tohex(),w=u({seq:[{int:0},{seq:[{oid:{name:"dsa"}},{seq:[{int:{bigint:e.p}},{int:{bigint:e.q}},{int:{bigint:e.g}}]}]},{octstr:{hex:T}}]}),O=w.tohex();return void 0===n||null==n?Xn(O,"PRIVATE KEY"):C(O,n)}throw new Error("unsupported object nor format")},Lr.getKeyFromCSRPEM=function(e){var t=Yn(e,"CERTIFICATE REQUEST"),n=Lr.getKeyFromCSRHex(t);return n},Lr.getKeyFromCSRHex=function(e){var t=Lr.parseCSRHex(e),n=Lr.getKey(t.p8pubkeyhex,null,"pkcs8pub");return n},Lr.parseCSRHex=function(e){var t=_n,n=t.getChildIdx,r=t.getTLV,i={},o=e;if("30"!=o.substr(0,2))throw new Error("malformed CSR(code:001)");var a=n(o,0);if(a.length<1)throw new Error("malformed CSR(code:002)");if("30"!=o.substr(a[0],2))throw new Error("malformed CSR(code:003)");var s=n(o,a[0]);if(s.length<3)throw new Error("malformed CSR(code:004)");return i.p8pubkeyhex=r(o,s[2]),i},Lr.getKeyID=function(e){var t=Lr,n=_n;"string"===typeof e&&-1!=e.indexOf("BEGIN ")&&(e=t.getKey(e));var r=Yn(t.getPEM(e)),i=n.getIdxbyList(r,0,[1]),o=n.getV(r,i).substring(2);return Sn.crypto.Util.hashHex(o,"sha1")},Lr.getJWK=function(e,t,n,r,i){var o,a,s={},l=Sn.crypto.Util.hashHex;if("string"==typeof e)o=Lr.getKey(e),-1!=e.indexOf("CERTIFICATE")&&(a=Yn(e));else{if("object"!=typeof e)throw new Error("unsupported keyinfo type");e instanceof Fr?(o=e.getPublicKey(),a=e.hex):o=e}if(o instanceof Ft&&o.isPrivate)s.kty="RSA",s.n=Dn(o.n.toString(16)),s.e=Dn(o.e.toString(16)),s.d=Dn(o.d.toString(16)),s.p=Dn(o.p.toString(16)),s.q=Dn(o.q.toString(16)),s.dp=Dn(o.dmp1.toString(16)),s.dq=Dn(o.dmq1.toString(16)),s.qi=Dn(o.coeff.toString(16));else if(o instanceof Ft&&o.isPublic)s.kty="RSA",s.n=Dn(o.n.toString(16)),s.e=Dn(o.e.toString(16));else if(o instanceof Sn.crypto.ECDSA&&o.isPrivate){var c=o.getShortNISTPCurveName();if("P-256"!==c&&"P-384"!==c&&"P-521"!==c)throw new Error("unsupported curve name for JWT: "+c);var u=o.getPublicKeyXYHex();s.kty="EC",s.crv=c,s.x=Dn(u.x),s.y=Dn(u.y),s.d=Dn(o.prvKeyHex)}else if(o instanceof Sn.crypto.ECDSA&&o.isPublic){c=o.getShortNISTPCurveName();if("P-256"!==c&&"P-384"!==c&&"P-521"!==c)throw new Error("unsupported curve name for JWT: "+c);u=o.getPublicKeyXYHex();s.kty="EC",s.crv=c,s.x=Dn(u.x),s.y=Dn(u.y)}if(void 0==s.kty)throw new Error("unsupported keyinfo");return o.isPrivate||1==t||(s.kid=Sn.jws.JWS.getJWKthumbprint(s)),void 0!=a&&1!=n&&(s.x5c=[h(a)]),void 0!=a&&1!=r&&(s.x5t=In(h(l(a,"sha1")))),void 0!=a&&1!=i&&(s["x5t#S256"]=In(h(l(a,"sha256")))),s},Lr.getJWKFromKey=function(e){return Lr.getJWK(e,!0,!0,!0,!0)},Ft.getPosArrayOfChildrenFromHex=function(e){return _n.getChildIdx(e,0)},Ft.getHexValueArrayOfChildrenFromHex=function(e){var t=_n,n=t.getV,r=Ft.getPosArrayOfChildrenFromHex(e),i=n(e,r[0]),o=n(e,r[1]),a=n(e,r[2]),s=n(e,r[3]),l=n(e,r[4]),c=n(e,r[5]),u=n(e,r[6]),d=n(e,r[7]),h=n(e,r[8]);r=new Array;return r.push(i,o,a,s,l,c,u,d,h),r},Ft.prototype.readPrivateKeyFromPEMString=function(e){var t=Yn(e),n=Ft.getHexValueArrayOfChildrenFromHex(t);this.setPrivateEx(n[1],n[2],n[3],n[4],n[5],n[6],n[7],n[8])},Ft.prototype.readPKCS5PrvKeyHex=function(e){var t=Ft.getHexValueArrayOfChildrenFromHex(e);this.setPrivateEx(t[1],t[2],t[3],t[4],t[5],t[6],t[7],t[8])},Ft.prototype.readPKCS8PrvKeyHex=function(e){var t,n,r,i,o,a,s,l,c=_n,u=c.getVbyListEx;if(!1===c.isASN1HEX(e))throw new Error("not ASN.1 hex string");try{t=u(e,0,[2,0,1],"02"),n=u(e,0,[2,0,2],"02"),r=u(e,0,[2,0,3],"02"),i=u(e,0,[2,0,4],"02"),o=u(e,0,[2,0,5],"02"),a=u(e,0,[2,0,6],"02"),s=u(e,0,[2,0,7],"02"),l=u(e,0,[2,0,8],"02")}catch(d){throw new Error("malformed PKCS#8 plain RSA private key")}this.setPrivateEx(t,n,r,i,o,a,s,l)},Ft.prototype.readPKCS5PubKeyHex=function(e){var t=_n,n=t.getV;if(!1===t.isASN1HEX(e))throw new Error("keyHex is not ASN.1 hex string");var r=t.getChildIdx(e,0);if(2!==r.length||"02"!==e.substr(r[0],2)||"02"!==e.substr(r[1],2))throw new Error("wrong hex for PKCS#5 public key");var i=n(e,r[0]),o=n(e,r[1]);this.setPublic(i,o)},Ft.prototype.readPKCS8PubKeyHex=function(e){var t=_n;if(!1===t.isASN1HEX(e))throw new Error("not ASN.1 hex string");if("06092a864886f70d010101"!==t.getTLVbyListEx(e,0,[0,0]))throw new Error("not PKCS8 RSA public key");var n=t.getTLVbyListEx(e,0,[1,0]);this.readPKCS5PubKeyHex(n)},Ft.prototype.readCertPubKeyHex=function(e,t){var n,r;n=new Fr,n.readCertHex(e),r=n.getPublicKeyHex(),this.readPKCS8PubKeyHex(r)};function Br(e,t){for(var n="",r=t/4-e.length,i=0;i<r;i++)n+="0";return n+e}function $r(e,t,n){var r="",i=0;while(r.length<t)r+=Gn(n(Hn(e+String.fromCharCode.apply(String,[(4278190080&i)>>24,(16711680&i)>>16,(65280&i)>>8,255&i])))),i+=1;return r}function Vr(e){for(var t in Sn.crypto.Util.DIGESTINFOHEAD){var n=Sn.crypto.Util.DIGESTINFOHEAD[t],r=n.length;if(e.substring(0,r)==n){var i=[t,e.substring(r)];return i}}return[]}function Fr(e){var t,n=_n,r=n.getChildIdx,i=n.getV,o=(n.dump,n.parse),a=n.getTLV,s=n.getVbyList,l=n.getVbyListEx,c=n.getTLVbyList,u=n.getTLVbyListEx,d=n.getIdxbyList,h=n.getIdxbyListEx,p=n.getVidx,f=n.getInt,m=n.oidname,g=n.hextooidstr,v=Yn,b=Error;try{t=Sn.asn1.x509.AlgorithmIdentifier.PSSNAME2ASN1TLV}catch(Pt){}this.HEX2STAG={"0c":"utf8",13:"prn",16:"ia5","1a":"vis","1e":"bmp"},this.hex=null,this.version=0,this.foffset=0,this.aExtInfo=null,this.getVersion=function(){if(null===this.hex||0!==this.version)return this.version;var e=c(this.hex,0,[0,0]);if("a0"==e.substr(0,2)){var t=c(e,0,[0]),n=f(t,0);if(n<0||2<n)throw new Error("malformed version field");return this.version=n+1,this.version}return this.version=1,this.foffset=-1,1},this.getSerialNumberHex=function(){return l(this.hex,0,[0,0],"02")},this.getSignatureAlgorithmField=function(){var e=u(this.hex,0,[0,1]);return this.getAlgorithmIdentifierName(e)},this.getAlgorithmIdentifierName=function(e){for(var n in t)if(e===t[n])return n;return m(l(e,0,[0],"06"))},this.getIssuer=function(e,t){return this.getX500Name(this.getIssuerHex(),e,t)},this.getIssuerHex=function(){return c(this.hex,0,[0,3+this.foffset],"30")},this.getIssuerString=function(){var e=this.getIssuer();return e.str},this.getSubject=function(e,t){return this.getX500Name(this.getSubjectHex(),e,t)},this.getSubjectHex=function(){return c(this.hex,0,[0,5+this.foffset],"30")},this.getSubjectString=function(){var e=this.getSubject();return e.str},this.getNotBefore=function(){var e=s(this.hex,0,[0,4+this.foffset,0]);return e=e.replace(/(..)/g,"%$1"),e=decodeURIComponent(e),e},this.getNotAfter=function(){var e=s(this.hex,0,[0,4+this.foffset,1]);return e=e.replace(/(..)/g,"%$1"),e=decodeURIComponent(e),e},this.getPublicKeyHex=function(){return this.getSPKI()},this.getSPKI=function(){return c(this.hex,0,[0,6+this.foffset],"30")},this.getSPKIValue=function(){var e=this.getSPKI();return null==e?null:s(e,0,[1],"03",!0)},this.getPublicKeyIdx=function(){return d(this.hex,0,[0,6+this.foffset],"30")},this.getPublicKeyContentIdx=function(){var e=this.getPublicKeyIdx();return d(this.hex,e,[1,0],"30")},this.getPublicKey=function(){return Lr.getKey(this.getPublicKeyHex(),null,"pkcs8pub")},this.getSignatureAlgorithmName=function(){var e=c(this.hex,0,[1],"30");return this.getAlgorithmIdentifierName(e)},this.getSignatureValueHex=function(){return s(this.hex,0,[2],"03",!0)},this.verifySignature=function(e){var t=this.getSignatureAlgorithmField(),n=this.getSignatureValueHex(),r=c(this.hex,0,[0],"30"),i=new Sn.crypto.Signature({alg:t});return i.init(e),i.updateHex(r),i.verify(n)},this.parseExt=function(e){var t,o,a;if(void 0===e){if(a=this.hex,3!==this.version)return-1;t=d(a,0,[0,7,0],"30"),o=r(a,t)}else{a=Yn(e);var l=d(a,0,[0,3,0,0],"06");if("2a864886f70d01090e"!=i(a,l))return void(this.aExtInfo=new Array);t=d(a,0,[0,3,0,1,0],"30"),o=r(a,t),this.hex=a}this.aExtInfo=new Array;for(var c=0;c<o.length;c++){var u={critical:!1},h=r(a,o[c]),f=0;3===h.length&&(u.critical=!0,f=1),u.oid=n.hextooidstr(s(a,o[c],[0],"06"));var m=d(a,o[c],[1+f]);u.vidx=p(a,m),this.aExtInfo.push(u)}},this.getExtInfo=function(e){var t=this.aExtInfo,n=e;if(e.match(/^[0-9.]+$/)||(n=Sn.asn1.x509.OID.name2oid(e)),""!==n)for(var r=0;r<t.length;r++)if(t[r].oid===n)return t[r]},this.getCriticalExtV=function(e,t,n){if(void 0!=t)return[t,n];var r=this.getExtInfo(e);return void 0==r?[null,null]:[a(this.hex,r.vidx),r.critical]},this.getExtBasicConstraints=function(e,t){if(void 0===e&&void 0===t){var n=this.getExtInfo("basicConstraints");if(void 0===n)return;e=a(this.hex,n.vidx),t=n.critical}var r={extname:"basicConstraints"};if(t&&(r.critical=!0),"3000"===e)return r;if("30030101ff"===e)return r.cA=!0,r;if("30060101ff02"===e.substr(0,12)){var o=i(e,10),s=parseInt(o,16);return r.cA=!0,r.pathLen=s,r}throw new Error("hExtV parse error: "+e)},this.getExtNameConstraints=function(e,t){var n=this.getCriticalExtV("nameConstraints",e,t);if(e=n[0],t=n[1],null!=e){var i={extname:"nameConstraints"};t&&(i.critical=!0);for(var o=r(e,0),s=0;s<o.length;s++){for(var l=[],c=r(e,o[s]),u=0;u<c.length;u++){var d=a(e,c[u]),h=this.getGeneralSubtree(d);l.push(h)}var p=e.substr(o[s],2);"a0"==p?i.permit=l:"a1"==p&&(i.exclude=l)}return i}},this.getGeneralSubtree=function(e){var t=r(e,0),n=t.length;if(n<1||2<n)throw new Error("wrong num elements");for(var o=this.getGeneralName(a(e,t[0])),s=1;s<n;s++){var l=e.substr(t[s],2),c=i(e,t[s]),u=parseInt(c,16);"80"==l&&(o.min=u),"81"==l&&(o.max=u)}return o},this.getExtKeyUsage=function(e,t){var n=this.getCriticalExtV("keyUsage",e,t);if(e=n[0],t=n[1],null!=e){var r={extname:"keyUsage"};return t&&(r.critical=!0),r.names=this.getExtKeyUsageString(e).split(","),r}},this.getExtKeyUsageBin=function(e){if(void 0===e){var t=this.getExtInfo("keyUsage");if(void 0===t)return"";e=a(this.hex,t.vidx)}if(8!=e.length&&10!=e.length)throw new Error("malformed key usage value: "+e);var n="000000000000000"+parseInt(e.substr(6),16).toString(2);return 8==e.length&&(n=n.slice(-8)),10==e.length&&(n=n.slice(-16)),n=n.replace(/0+$/,""),""==n&&(n="0"),n},this.getExtKeyUsageString=function(e){for(var t=this.getExtKeyUsageBin(e),n=new Array,r=0;r<t.length;r++)"1"==t.substr(r,1)&&n.push(Fr.KEYUSAGE_NAME[r]);return n.join(",")},this.getExtSubjectKeyIdentifier=function(e,t){if(void 0===e&&void 0===t){var n=this.getExtInfo("subjectKeyIdentifier");if(void 0===n)return;e=a(this.hex,n.vidx),t=n.critical}var r={extname:"subjectKeyIdentifier"};t&&(r.critical=!0);var o=i(e,0);return r.kid={hex:o},r},this.getExtAuthorityKeyIdentifier=function(e,t){if(void 0===e&&void 0===t){var n=this.getExtInfo("authorityKeyIdentifier");if(void 0===n)return;e=a(this.hex,n.vidx),t=n.critical}var o={extname:"authorityKeyIdentifier"};t&&(o.critical=!0);for(var s=r(e,0),l=0;l<s.length;l++){var c=e.substr(s[l],2);if("80"===c&&(o.kid={hex:i(e,s[l])}),"a1"===c){var u=a(e,s[l]),d=this.getGeneralNames(u);o.issuer=d[0]["dn"]}"82"===c&&(o.sn={hex:i(e,s[l])})}return o},this.getExtExtKeyUsage=function(e,t){if(void 0===e&&void 0===t){var n=this.getExtInfo("extKeyUsage");if(void 0===n)return;e=a(this.hex,n.vidx),t=n.critical}var o={extname:"extKeyUsage",array:[]};t&&(o.critical=!0);for(var s=r(e,0),l=0;l<s.length;l++)o.array.push(m(i(e,s[l])));return o},this.getExtExtKeyUsageName=function(){var e=this.getExtInfo("extKeyUsage");if(void 0===e)return e;var t=new Array,n=a(this.hex,e.vidx);if(""===n)return t;for(var o=r(n,0),s=0;s<o.length;s++)t.push(m(i(n,o[s])));return t},this.getExtSubjectAltName=function(e,t){if(void 0===e&&void 0===t){var n=this.getExtInfo("subjectAltName");if(void 0===n)return;e=a(this.hex,n.vidx),t=n.critical}var r={extname:"subjectAltName",array:[]};return t&&(r.critical=!0),r.array=this.getGeneralNames(e),r},this.getExtIssuerAltName=function(e,t){if(void 0===e&&void 0===t){var n=this.getExtInfo("issuerAltName");if(void 0===n)return;e=a(this.hex,n.vidx),t=n.critical}var r={extname:"issuerAltName",array:[]};return t&&(r.critical=!0),r.array=this.getGeneralNames(e),r},this.getGeneralNames=function(e){for(var t=r(e,0),n=[],i=0;i<t.length;i++){var o=this.getGeneralName(a(e,t[i]));void 0!==o&&n.push(o)}return n},this.getGeneralName=function(e){var t=e.substr(0,2),n=i(e,0),r=Gn(n);return"81"==t?{rfc822:r}:"82"==t?{dns:r}:"86"==t?{uri:r}:"87"==t?{ip:dr(n)}:"a4"==t?{dn:this.getX500Name(n)}:"a0"==t?{other:this.getOtherName(e)}:void 0},this.getExtSubjectAltName2=function(){var e,t,n,o=this.getExtInfo("subjectAltName");if(void 0===o)return o;for(var s=new Array,l=a(this.hex,o.vidx),c=r(l,0),u=0;u<c.length;u++)n=l.substr(c[u],2),e=i(l,c[u]),"81"===n&&(t=Fn(e),s.push(["MAIL",t])),"82"===n&&(t=Fn(e),s.push(["DNS",t])),"84"===n&&(t=Fr.hex2dn(e,0),s.push(["DN",t])),"86"===n&&(t=Fn(e),s.push(["URI",t])),"87"===n&&(t=dr(e),s.push(["IP",t]));return s},this.getExtCRLDistributionPoints=function(e,t){if(void 0===e&&void 0===t){var n=this.getExtInfo("cRLDistributionPoints");if(void 0===n)return;e=a(this.hex,n.vidx),t=n.critical}var i={extname:"cRLDistributionPoints",array:[]};t&&(i.critical=!0);for(var o=r(e,0),s=0;s<o.length;s++){var l=a(e,o[s]);i.array.push(this.getDistributionPoint(l))}return i},this.getDistributionPoint=function(e){for(var t={},n=r(e,0),i=0;i<n.length;i++){var o=e.substr(n[i],2),s=a(e,n[i]);"a0"==o&&(t.dpname=this.getDistributionPointName(s))}return t},this.getDistributionPointName=function(e){for(var t={},n=r(e,0),i=0;i<n.length;i++){var o=e.substr(n[i],2),s=a(e,n[i]);"a0"==o&&(t.full=this.getGeneralNames(s))}return t},this.getExtCRLDistributionPointsURI=function(){var e=this.getExtCRLDistributionPoints();if(void 0==e)return e;for(var t=e.array,n=[],r=0;r<t.length;r++)try{void 0!=t[r].dpname.full[0].uri&&n.push(t[r].dpname.full[0].uri)}catch(i){}return n},this.getExtAIAInfo=function(){var e=this.getExtInfo("authorityInfoAccess");if(void 0===e)return e;for(var t={ocsp:[],caissuer:[]},n=r(this.hex,e.vidx),i=0;i<n.length;i++){var o=s(this.hex,n[i],[0],"06"),a=s(this.hex,n[i],[1],"86");"2b06010505073001"===o&&t.ocsp.push(Fn(a)),"2b06010505073002"===o&&t.caissuer.push(Fn(a))}return t},this.getExtAuthorityInfoAccess=function(e,t){if(void 0===e&&void 0===t){var n=this.getExtInfo("authorityInfoAccess");if(void 0===n)return;e=a(this.hex,n.vidx),t=n.critical}var i={extname:"authorityInfoAccess",array:[]};t&&(i.critical=!0);for(var o=r(e,0),c=0;c<o.length;c++){var u=l(e,o[c],[0],"06"),d=s(e,o[c],[1],"86"),h=Fn(d);if("2b06010505073001"==u)i.array.push({ocsp:h});else{if("2b06010505073002"!=u)throw new Error("unknown method: "+u);i.array.push({caissuer:h})}}return i},this.getExtCertificatePolicies=function(e,t){if(void 0===e&&void 0===t){var n=this.getExtInfo("certificatePolicies");if(void 0===n)return;e=a(this.hex,n.vidx),t=n.critical}var i={extname:"certificatePolicies",array:[]};t&&(i.critical=!0);for(var o=r(e,0),s=0;s<o.length;s++){var l=a(e,o[s]),c=this.getPolicyInformation(l);i.array.push(c)}return i},this.getPolicyInformation=function(e){var t={},n=s(e,0,[0],"06");t.policyoid=m(n);var i=h(e,0,[1],"30");if(-1!=i){t.array=[];for(var o=r(e,i),l=0;l<o.length;l++){var c=a(e,o[l]),u=this.getPolicyQualifierInfo(c);t.array.push(u)}}return t},this.getOtherName=function(e){var t={},n=r(e,0),i=s(e,n[0],[],"06"),a=s(e,n[1],[]);return t.oid=m(i),t.value=o(a),t},this.getPolicyQualifierInfo=function(e){var t={},n=s(e,0,[0],"06");if("2b06010505070201"===n){var r=l(e,0,[1],"16");t.cps=Gn(r)}else if("2b06010505070202"===n){var i=c(e,0,[1],"30");t.unotice=this.getUserNotice(i)}return t},this.getUserNotice=function(e){var t=null;try{t=n.parse(e);var r=this._asn1ToUnotice(t);return r}catch(i){return}},this._asn1ToUnotice=function(e){try{for(var t={},n=Mr(e,"seq"),r=0;r<n.length;r++){var i=this._asn1ToNoticeRef(n[r]);void 0!=i&&(t.noticeref=i);var o=this.asn1ToDisplayText(n[r]);void 0!=o&&(t.exptext=o)}return Object.keys(t).length>0?t:void 0}catch(a){return}},this._asn1ToNoticeRef=function(e){try{for(var t={},n=Mr(e,"seq"),r=0;r<n.length;r++){var i=this._asn1ToNoticeNum(n[r]);void 0!=i&&(t.noticenum=i);var o=this.asn1ToDisplayText(n[r]);void 0!=o&&(t.org=o)}return Object.keys(t).length>0?t:void 0}catch(a){return}},this._asn1ToNoticeNum=function(e){try{for(var t=Mr(e,"seq"),n=[],r=0;r<t.length;r++){var i=t[r];n.push(parseInt(Mr(i,"int.hex"),16))}return n}catch(o){return}},this.getDisplayText=function(e){var t={"0c":"utf8",16:"ia5","1a":"vis","1e":"bmp"},n={};return n.type=t[e.substr(0,2)],n.str=Gn(i(e,0)),n},this.asn1ToDisplayText=function(e){return void 0!=e.utf8str?{type:"utf8",str:e.utf8str.str}:void 0!=e.ia5str?{type:"ia5",str:e.ia5str.str}:void 0!=e.visstr?{type:"vis",str:e.visstr.str}:void 0!=e.bmpstr?{type:"bmp",str:e.bmpstr.str}:void 0!=e.prnstr?{type:"prn",str:e.prnstr.str}:void 0},this.getExtPolicyMappings=function(e,t){var n=this.getCriticalExtV("policyMappings",e,t);if(e=n[0],t=n[1],null!=e){var r={extname:"policyMappings"};t&&(r.critical=!0);try{for(var i=o(e),a=i.seq,s=[],l=0;l<a.length;l++){var c=a[l].seq;s.push([c[0].oid,c[1].oid])}r.array=s}catch(u){throw new b("malformed policyMappings")}return r}},this.getExtPolicyConstraints=function(e,t){var n=this.getCriticalExtV("policyConstraints",e,t);if(e=n[0],t=n[1],null!=e){var r={extname:"policyConstraints"};t&&(r.critical=!0);var i=o(e);try{for(var a=i.seq,s=0;s<a.length;s++){var l=a[s].tag;0==l.explicit&&("80"==l.tag&&(r.reqexp=parseInt(l.hex,16)),"81"==l.tag&&(r.inhibit=parseInt(l.hex,16)))}}catch(c){return new b("malformed policyConstraints value")}return r}},this.getExtInhibitAnyPolicy=function(e,t){var n=this.getCriticalExtV("inhibitAnyPolicy",e,t);if(e=n[0],t=n[1],null!=e){var r={extname:"inhibitAnyPolicy"};t&&(r.critical=!0);var i=f(e,0);return-1==i?new b("wrong value"):(r.skip=i,r)}},this.getExtCRLNumber=function(e,t){var n={extname:"cRLNumber"};if(t&&(n.critical=!0),"02"==e.substr(0,2))return n.num={hex:i(e,0)},n;throw new b("hExtV parse error: "+e)},this.getExtCRLReason=function(e,t){var n={extname:"cRLReason"};if(t&&(n.critical=!0),"0a"==e.substr(0,2))return n.code=parseInt(i(e,0),16),n;throw new Error("hExtV parse error: "+e)},this.getExtOcspNonce=function(e,t){var n={extname:"ocspNonce"};t&&(n.critical=!0);var r=i(e,0);return n.hex=r,n},this.getExtOcspNoCheck=function(e,t){var n={extname:"ocspNoCheck"};return t&&(n.critical=!0),n},this.getExtAdobeTimeStamp=function(e,t){if(void 0===e&&void 0===t){var n=this.getExtInfo("adobeTimeStamp");if(void 0===n)return;e=a(this.hex,n.vidx),t=n.critical}var i={extname:"adobeTimeStamp"};t&&(i.critical=!0);var o=r(e,0);if(o.length>1){var s=a(e,o[1]),l=this.getGeneralName(s);void 0!=l.uri&&(i.uri=l.uri)}if(o.length>2){var c=a(e,o[2]);"0101ff"==c&&(i.reqauth=!0),"010100"==c&&(i.reqauth=!1)}return i},this.getExtSubjectDirectoryAttributes=function(e,t){if(void 0===e&&void 0===t){var n=this.getExtInfo("subjectDirectoryAttributes");if(void 0===n)return;e=a(this.hex,n.vidx),t=n.critical}var r={extname:"subjectDirectoryAttributes"};t&&(r.critical=!0);try{for(var i=o(e),s=[],l=0;l<i.seq.length;l++){var c=i.seq[l],u=Mr(c,"seq.0.oid"),d=Mr(c,"seq.1.set");if(void 0==u||void 0==d)throw"error";s.push({attr:u,array:d})}return r.array=s,r}catch(h){throw new Error("malformed subjectDirectoryAttributes extension value")}};var y=function(e){var t={};try{var n=e.seq[0].oid,r=Sn.asn1.x509.OID.name2oid(n);t.type=Sn.asn1.x509.OID.oid2atype(r);var i=e.seq[1];if(void 0!=i.utf8str)t.ds="utf8",t.value=i.utf8str.str;else if(void 0!=i.numstr)t.ds="num",t.value=i.numstr.str;else if(void 0!=i.telstr)t.ds="tel",t.value=i.telstr.str;else if(void 0!=i.prnstr)t.ds="prn",t.value=i.prnstr.str;else if(void 0!=i.ia5str)t.ds="ia5",t.value=i.ia5str.str;else if(void 0!=i.visstr)t.ds="vis",t.value=i.visstr.str;else{if(void 0==i.bmpstr)throw"error";t.ds="bmp",t.value=i.bmpstr.str}return t}catch(o){throw new Erorr("improper ASN.1 parsed AttrTypeAndValue")}},w=function(e){try{return e.set.map(function(e){return y(e)})}catch(Dt){throw new Error("improper ASN.1 parsed RDN: "+Dt)}},O=function(e){try{return e.seq.map(function(e){return w(e)})}catch(Dt){throw new Error("improper ASN.1 parsed X500Name: "+Dt)}};this.getX500NameRule=function(e){for(var t=null,n=[],r=0;r<e.length;r++)for(var i=e[r],o=0;o<i.length;o++)n.push(i[o]);for(r=0;r<n.length;r++){var a=n[r],s=a.ds,l=a.value,c=a.type;if("prn"!=s&&"utf8"!=s&&"ia5"!=s)return"mixed";if("ia5"==s){if("CN"!=c)return"mixed";if(Sn.lang.String.isMail(l))continue;return"mixed"}if("C"==c){if("prn"==s)continue;return"mixed"}if(null==t)t=s;else if(t!==s)return"mixed"}return null==t?"prn":t},this.getAttrTypeAndValue=function(e){var t=o(e);return y(t)},this.getRDN=function(e){var t=o(e);return w(t)},this.getX500NameArray=function(e){var t=o(e);return O(t)},this.getX500Name=function(e,t,n){var r=this.getX500NameArray(e),i=this.dnarraytostr(r),o={str:i};return o.array=r,1==n&&(o.hex=e),1==t&&(o.canon=this.c14nRDNArray(r)),o},this.readCertPEM=function(e){this.readCertHex(v(e))},this.readCertHex=function(e){this.hex=e,this.getVersion();try{d(this.hex,0,[0,7],"a3"),this.parseExt()}catch(t){}},this.getParam=function(e){var t={};return void 0==e&&(e={}),t.version=this.getVersion(),t.serial={hex:this.getSerialNumberHex()},t.sigalg=this.getSignatureAlgorithmField(),t.issuer=this.getIssuer(e.dncanon,e.dnhex),t.notbefore=this.getNotBefore(),t.notafter=this.getNotAfter(),t.subject=this.getSubject(e.dncanon,e.dnhex),t.sbjpubkey=Xn(this.getPublicKeyHex(),"PUBLIC KEY"),void 0!=this.aExtInfo&&this.aExtInfo.length>0&&(t.ext=this.getExtParamArray()),t.sighex=this.getSignatureValueHex(),1==e.tbshex&&(t.tbshex=c(this.hex,0,[0])),1==e.nodnarray&&(delete t.issuer.array,delete t.subject.array),t},this.getExtParamArray=function(e){if(void 0==e){var t=h(this.hex,0,[0,"[3]"]);-1!=t&&(e=u(this.hex,0,[0,"[3]",0],"30"))}for(var n=[],i=r(e,0),o=0;o<i.length;o++){var s=a(e,i[o]),l=this.getExtParam(s);null!=l&&n.push(l)}return n},this.getExtParam=function(e){var t=r(e,0),n=t.length;if(2!=n&&3!=n)throw new Error("wrong number elements in Extension: "+n+" "+e);var i=g(s(e,0,[0],"06")),a=!1;3==n&&"0101ff"==c(e,0,[1])&&(a=!0);var l=c(e,0,[n-1,0]),u=void 0;if("2.5.29.14"==i?u=this.getExtSubjectKeyIdentifier(l,a):"2.5.29.15"==i?u=this.getExtKeyUsage(l,a):"2.5.29.17"==i?u=this.getExtSubjectAltName(l,a):"2.5.29.18"==i?u=this.getExtIssuerAltName(l,a):"2.5.29.19"==i?u=this.getExtBasicConstraints(l,a):"2.5.29.30"==i?u=this.getExtNameConstraints(l,a):"2.5.29.31"==i?u=this.getExtCRLDistributionPoints(l,a):"2.5.29.32"==i?u=this.getExtCertificatePolicies(l,a):"2.5.29.33"==i?u=this.getExtPolicyMappings(l,a):"2.5.29.35"==i?u=this.getExtAuthorityKeyIdentifier(l,a):"2.5.29.36"==i?u=this.getExtPolicyConstraints(l,a):"2.5.29.37"==i?u=this.getExtExtKeyUsage(l,a):"2.5.29.54"==i?u=this.getExtInhibitAnyPolicy(l,a):"1.3.6.1.5.5.7.1.1"==i?u=this.getExtAuthorityInfoAccess(l,a):"2.5.29.20"==i?u=this.getExtCRLNumber(l,a):"2.5.29.21"==i?u=this.getExtCRLReason(l,a):"2.5.29.9"==i?u=this.getExtSubjectDirectoryAttributes(l,a):"1.3.6.1.5.5.7.48.1.2"==i?u=this.getExtOcspNonce(l,a):"1.3.6.1.5.5.7.48.1.5"==i?u=this.getExtOcspNoCheck(l,a):"1.2.840.113583.1.1.9.1"==i?u=this.getExtAdobeTimeStamp(l,a):void 0!=Fr.EXT_PARSER[i]&&(u=Fr.EXT_PARSER[i](i,a,l)),void 0!=u)return u;var d={extname:i,extn:l};try{d.extn=o(l)}catch(h){}return a&&(d.critical=!0),d},this.findExt=function(e,t){for(var n=0;n<e.length;n++)if(e[n].extname==t)return e[n];return null},this.updateExtCDPFullURI=function(e,t){var n=this.findExt(e,"cRLDistributionPoints");if(null!=n&&void 0!=n.array)for(var r=n.array,i=0;i<r.length;i++)if(void 0!=r[i].dpname&&void 0!=r[i].dpname.full)for(var o=r[i].dpname.full,a=0;a<o.length;a++){var s=o[i];void 0!=s.uri&&(s.uri=t)}},this.updateExtAIAOCSP=function(e,t){var n=this.findExt(e,"authorityInfoAccess");if(null!=n&&void 0!=n.array)for(var r=n.array,i=0;i<r.length;i++)void 0!=r[i].ocsp&&(r[i].ocsp=t)},this.updateExtAIACAIssuer=function(e,t){var n=this.findExt(e,"authorityInfoAccess");if(null!=n&&void 0!=n.array)for(var r=n.array,i=0;i<r.length;i++)void 0!=r[i].caissuer&&(r[i].caissuer=t)},this.dnarraytostr=function(e){function t(e){return e.map(function(e){return n(e).replace(/\+/,"\\+")}).join("+")}function n(e){return e.type+"="+e.value}return"/"+e.map(function(e){return t(e).replace(/\//,"\\/")}).join("/")},this.setCanonicalizedDN=function(e){var t;if(void 0!=e.str&&void 0==e.array){var n=new Sn.asn1.x509.X500Name({str:e.str}),r=n.tohex();t=this.getX500NameArray(r)}else t=e.array;void 0==e.canon&&(e.canon=this.c14nRDNArray(t))},this.c14nRDNArray=function(e){for(var t=[],n=0;n<e.length;n++){for(var r=e[n],i=[],o=0;o<r.length;o++){var a=r[o],s=a.value;s=s.replace(/^\s*/,""),s=s.replace(/\s*$/,""),s=s.replace(/\s+/g," "),s=s.toLowerCase(),i.push(a.type.toLowerCase()+"="+s)}t.push(i.join("+"))}return"/"+t.join("/")},this.getInfo=function(){var e,t,n,r=function(e){for(var t="",n=" ",r="\n",i=e.array,o=0;o<i.length;o++){var a=i[o];if(void 0!=a.dn&&(t+=n+"dn: "+a.dn.str+r),void 0!=a.ip&&(t+=n+"ip: "+a.ip+r),void 0!=a.rfc822&&(t+=n+"rfc822: "+a.rfc822+r),void 0!=a.dns&&(t+=n+"dns: "+a.dns+r),void 0!=a.uri&&(t+=n+"uri: "+a.uri+r),void 0!=a.other){var s=a.other.oid,l=JSON.stringify(a.other.value).replace(/\"/g,"");t+=n+"other: "+s+"="+l+r}}return t=t.replace(/\n$/,""),t},i=function(e){for(var t="",n=e.array,r=0;r<n.length;r++){var i=n[r];if(t+=" policy oid: "+i.policyoid+"\n",void 0!==i.array)for(var o=0;o<i.array.length;o++){var a=i.array[o];void 0!==a.cps&&(t+=" cps: "+a.cps+"\n")}}return t},o=function(e){for(var t="",n=e.array,r=0;r<n.length;r++){var i=n[r];try{void 0!==i.dpname.full[0].uri&&(t+=" "+i.dpname.full[0].uri+"\n")}catch(o){}try{void 0!==i.dname.full[0].dn.hex&&(t+=" "+Fr.hex2dn(i.dpname.full[0].dn.hex)+"\n")}catch(o){}}return t},a=function(e){for(var t="",n=e.array,r=0;r<n.length;r++){var i=n[r];void 0!==i.caissuer&&(t+=" caissuer: "+i.caissuer+"\n"),void 0!==i.ocsp&&(t+=" ocsp: "+i.ocsp+"\n")}return t};if(e="Basic Fields\n",e+=" serial number: "+this.getSerialNumberHex()+"\n",e+=" signature algorithm: "+this.getSignatureAlgorithmField()+"\n",e+=" issuer: "+this.getIssuerString()+"\n",e+=" notBefore: "+this.getNotBefore()+"\n",e+=" notAfter: "+this.getNotAfter()+"\n",e+=" subject: "+this.getSubjectString()+"\n",e+=" subject public key info: \n",t=this.getPublicKey(),e+=" key algorithm: "+t.type+"\n","RSA"===t.type&&(e+=" n="+Or(t.n.toString(16)).substr(0,16)+"...\n",e+=" e="+Or(t.e.toString(16))+"\n"),n=this.aExtInfo,void 0!==n&&null!==n){e+="X509v3 Extensions:\n";for(var s=0;s<n.length;s++){var l=n[s],c=Sn.asn1.x509.OID.oid2name(l.oid);""===c&&(c=l.oid);var u="";if(!0===l.critical&&(u="CRITICAL"),e+=" "+c+" "+u+":\n","basicConstraints"===c){var d=this.getExtBasicConstraints();void 0===d.cA?e+=" {}\n":(e+=" cA=true",void 0!==d.pathLen&&(e+=", pathLen="+d.pathLen),e+="\n")}else if("policyMappings"==c){var h=this.getExtPolicyMappings().array,p=h.map(function(e){var t=e;return t[0]+":"+t[1]}).join(", ");e+=" "+p+"\n"}else if("policyConstraints"==c){var f=this.getExtPolicyConstraints();e+=" ",void 0!=f.reqexp&&(e+=" reqexp="+f.reqexp),void 0!=f.inhibit&&(e+=" inhibit="+f.inhibit),e+="\n"}else if("inhibitAnyPolicy"==c){f=this.getExtInhibitAnyPolicy();e+=" skip="+f.skip+"\n"}else if("keyUsage"==c)e+=" "+this.getExtKeyUsageString()+"\n";else if("subjectKeyIdentifier"==c)e+=" "+this.getExtSubjectKeyIdentifier().kid.hex+"\n";else if("authorityKeyIdentifier"==c){var m=this.getExtAuthorityKeyIdentifier();void 0!==m.kid&&(e+=" kid="+m.kid.hex+"\n")}else if("extKeyUsage"==c){var g=this.getExtExtKeyUsage().array;e+=" "+g.join(", ")+"\n"}else if("subjectAltName"==c){var v=r(this.getExtSubjectAltName());e+=v+"\n"}else if("cRLDistributionPoints"==c){var b=this.getExtCRLDistributionPoints();e+=o(b)}else if("authorityInfoAccess"==c){var y=this.getExtAuthorityInfoAccess();e+=a(y)}else"certificatePolicies"==c&&(e+=i(this.getExtCertificatePolicies()))}}return e+="signature algorithm: "+this.getSignatureAlgorithmName()+"\n",e+="signature: "+this.getSignatureValueHex().substr(0,16)+"...\n",e},"string"==typeof e&&(-1!=e.indexOf("-----BEGIN")?this.readCertPEM(e):Sn.lang.String.isHex(e)&&this.readCertHex(e))}Ft.prototype.sign=function(e,t){var n=function(e){return Sn.crypto.Util.hashString(e,t)},r=n(e);return this.signWithMessageHash(r,t)},Ft.prototype.signWithMessageHash=function(e,t){var n=Sn.crypto.Util.getPaddedDigestInfoHex(e,t,this.n.bitLength()),r=Vt(n,16),i=this.doPrivate(r),o=i.toString(16);return Br(o,this.n.bitLength())},Ft.prototype.signPSS=function(e,t,n){var r=function(e){return Sn.crypto.Util.hashHex(e,t)},i=r(Hn(e));return void 0===n&&(n=-1),this.signWithMessageHashPSS(i,t,n)},Ft.prototype.signWithMessageHashPSS=function(e,t,n){var r,i=Gn(e),o=i.length,a=this.n.bitLength()-1,s=Math.ceil(a/8),l=function(e){return Sn.crypto.Util.hashHex(e,t)};if(-1===n||void 0===n)n=o;else if(-2===n)n=s-o-2;else if(n<-2)throw new Error("invalid salt length");if(s<o+n+2)throw new Error("data too long");var c="";n>0&&(c=new Array(n),(new $t).nextBytes(c),c=String.fromCharCode.apply(String,c));var u=Gn(l(Hn("\0\0\0\0\0\0\0\0"+i+c))),d=[];for(r=0;r<s-n-o-2;r+=1)d[r]=0;var h=String.fromCharCode.apply(String,d)+""+c,p=$r(u,h.length,l),f=[];for(r=0;r<h.length;r+=1)f[r]=h.charCodeAt(r)^p.charCodeAt(r);var m=65280>>8*s-a&255;for(f[0]&=~m,r=0;r<o;r++)f.push(u.charCodeAt(r));return f.push(188),Br(this.doPrivate(new v(f)).toString(16),this.n.bitLength())},Ft.prototype.verify=function(e,t){if(t=t.toLowerCase(),null==t.match(/^[0-9a-f]+$/))return!1;var n=Vt(t,16),r=this.n.bitLength();if(n.bitLength()>r)return!1;var i=this.doPublic(n),o=i.toString(16);if(o.length+3!=r/4)return!1;var a=o.replace(/^1f+00/,""),s=Vr(a);if(0==s.length)return!1;var l=s[0],c=s[1],u=function(e){return Sn.crypto.Util.hashString(e,l)},d=u(e);return c==d},Ft.prototype.verifyWithMessageHash=function(e,t){if(t.length!=Math.ceil(this.n.bitLength()/4))return!1;var n=Vt(t,16);if(n.bitLength()>this.n.bitLength())return 0;var r=this.doPublic(n),i=r.toString(16).replace(/^1f+00/,""),o=Vr(i);if(0==o.length)return!1;o[0];var a=o[1];return a==e},Ft.prototype.verifyPSS=function(e,t,n,r){var i=function(e){return Sn.crypto.Util.hashHex(e,n)},o=i(Hn(e));return void 0===r&&(r=-1),this.verifyWithMessageHashPSS(o,t,n,r)},Ft.prototype.verifyWithMessageHashPSS=function(e,t,n,r){if(t.length!=Math.ceil(this.n.bitLength()/4))return!1;var i,o=new v(t,16),a=function(e){return Sn.crypto.Util.hashHex(e,n)},s=Gn(e),l=s.length,c=this.n.bitLength()-1,u=Math.ceil(c/8);if(-1===r||void 0===r)r=l;else if(-2===r)r=u-l-2;else if(r<-2)throw new Error("invalid salt length");if(u<l+r+2)throw new Error("data too long");var d=this.doPublic(o).toByteArray();for(i=0;i<d.length;i+=1)d[i]&=255;while(d.length<u)d.unshift(0);if(188!==d[u-1])throw new Error("encoded message does not end in 0xbc");d=String.fromCharCode.apply(String,d);var h=d.substr(0,u-l-1),p=d.substr(h.length,l),f=65280>>8*u-c&255;if(0!==(h.charCodeAt(0)&f))throw new Error("bits beyond keysize not zero");var m=$r(p,h.length,a),g=[];for(i=0;i<h.length;i+=1)g[i]=h.charCodeAt(i)^m.charCodeAt(i);g[0]&=~f;var b=u-l-r-2;for(i=0;i<b;i+=1)if(0!==g[i])throw new Error("leftmost octets not zero");if(1!==g[b])throw new Error("0x01 marker not found");return p===Gn(a(Hn("\0\0\0\0\0\0\0\0"+s+String.fromCharCode.apply(String,g.slice(-r)))))},Ft.SALT_LEN_HLEN=-1,Ft.SALT_LEN_MAX=-2,Ft.SALT_LEN_RECOVER=-2,Fr.EXT_PARSER={},Fr.registExtParser=function(e,t){Fr.EXT_PARSER[e]=t},Fr.hex2dn=function(e,t){void 0===t&&(t=0);var n=new Fr,r=(_n.getTLV(e,t),n.getX500Name(e));return r.str},Fr.hex2rdn=function(e,t){if(void 0===t&&(t=0),"31"!==e.substr(t,2))throw new Error("malformed RDN");for(var n=new Array,r=_n.getChildIdx(e,t),i=0;i<r.length;i++)n.push(Fr.hex2attrTypeValue(e,r[i]));return n=n.map(function(e){return e.replace("+","\\+")}),n.join("+")},Fr.hex2attrTypeValue=function(e,t){var n=_n,r=n.getV;if(void 0===t&&(t=0),"30"!==e.substr(t,2))throw new Error("malformed attribute type and value");var i=n.getChildIdx(e,t);2!==i.length||e.substr(i[0],2);var o=r(e,i[0]),a=Sn.asn1.ASN1Util.oidHexToInt(o),s=Sn.asn1.x509.OID.oid2atype(a),l=r(e,i[1]),c=Gn(l);return s+"="+c},Fr.getPublicKeyFromCertHex=function(e){var t=new Fr;return t.readCertHex(e),t.getPublicKey()},Fr.getPublicKeyFromCertPEM=function(e){var t=new Fr;return t.readCertPEM(e),t.getPublicKey()},Fr.getPublicKeyInfoPropOfCertPEM=function(e){var t,n,r=_n,i=r.getVbyList,o={};return o.algparam=null,t=new Fr,t.readCertPEM(e),n=t.getPublicKeyHex(),o.keyhex=i(n,0,[1],"03").substr(2),o.algoid=i(n,0,[0,0],"06"),"2a8648ce3d0201"===o.algoid&&(o.algparam=i(n,0,[0,1],"06")),o},Fr.KEYUSAGE_NAME=["digitalSignature","nonRepudiation","keyEncipherment","dataEncipherment","keyAgreement","keyCertSign","cRLSign","encipherOnly","decipherOnly"];var jr=function(e){var t=Sn,n=t.lang.String.isHex,r=_n,i=r.getV,o=r.getTLV,a=r.getVbyList,s=r.getTLVbyList,l=r.getTLVbyListEx,c=r.getIdxbyList,u=r.getIdxbyListEx,d=r.getChildIdx,h=new Fr;this.hex=null,this.posSigAlg=null,this.posRevCert=null,this.parsed=null,this._setPos=function(){var e=c(this.hex,0,[0,0]),t=this.hex.substr(e,2);if("02"==t)this.posSigAlg=1;else{if("30"!=t)throw new Error("malformed 1st item of TBSCertList: "+t);this.posSigAlg=0}var n,r,i=c(this.hex,0,[0,this.posSigAlg+3]),o=this.hex.substr(i,2);if("17"==o||"18"==o)n=c(this.hex,0,[0,this.posSigAlg+4]),this.posRevCert=null,-1!=n&&(r=this.hex.substr(n,2),"30"==r&&(this.posRevCert=this.posSigAlg+4));else if("30"==o)this.posRevCert=this.posSigAlg+3;else{if("a0"!=o)throw new Error("malformed nextUpdate or revCert tag: "+o);this.posRevCert=null}},this.getVersion=function(){return 0==this.posSigAlg?null:parseInt(a(this.hex,0,[0,0],"02"),16)+1},this.getSignatureAlgorithmField=function(){var e=s(this.hex,0,[0,this.posSigAlg],"30");return h.getAlgorithmIdentifierName(e)},this.getIssuer=function(){return h.getX500Name(this.getIssuerHex())},this.getIssuerHex=function(){return s(this.hex,0,[0,this.posSigAlg+1],"30")},this.getThisUpdate=function(){var e=a(this.hex,0,[0,this.posSigAlg+2]);return result=Gn(e)},this.getNextUpdate=function(){var e=c(this.hex,0,[0,this.posSigAlg+3]),t=this.hex.substr(e,2);return"17"!=t&&"18"!=t?null:Gn(i(this.hex,e))},this.getRevCertArray=function(){if(null==this.posRevCert)return null;for(var e=[],t=c(this.hex,0,[0,this.posRevCert]),n=d(this.hex,t),r=0;r<n.length;r++){var i=o(this.hex,n[r]);e.push(this.getRevCert(i))}return e},this.getRevCert=function(e){var t={},n=d(e,0);return t.sn={hex:a(e,0,[0],"02")},t.date=Gn(a(e,0,[1])),3==n.length&&(t.ext=h.getExtParamArray(s(e,0,[2]))),t},this.findRevCert=function(e){var t=new Fr(e),n=t.getSerialNumberHex();return this.findRevCertBySN(n)},this.findRevCertBySN=function(e){if(null==this.parsed&&this.getParam(),null==this.parsed.revcert)return null;for(var t=this.parsed.revcert,n=0;n<t.length;n++)if(e==t[n].sn.hex)return t[n];return null},this.getSignatureValueHex=function(){return a(this.hex,0,[2],"03",!0)},this.verifySignature=function(e){var t=this.getSignatureAlgorithmField(),n=this.getSignatureValueHex(),r=s(this.hex,0,[0],"30"),i=new Sn.crypto.Signature({alg:t});return i.init(e),i.updateHex(r),i.verify(n)},this.getParam=function(e){var t={},n=this.getVersion();null!=n&&(t.version=n),t.sigalg=this.getSignatureAlgorithmField(),t.issuer=this.getIssuer(),t.thisupdate=this.getThisUpdate();var r=this.getNextUpdate();null!=r&&(t.nextupdate=r);var i=this.getRevCertArray();null!=i&&(t.revcert=i);var o=u(this.hex,0,[0,"[0]"]);if(-1!=o){var a=l(this.hex,0,[0,"[0]",0]);t.ext=h.getExtParamArray(a)}return t.sighex=this.getSignatureValueHex(),this.parsed=t,"object"==typeof e&&(1==e.tbshex&&(t.tbshex=s(this.hex,0,[0])),1==e.nodnarray&&delete t.issuer.array),t},"string"==typeof e&&(n(e)?this.hex=e:e.match(/-----BEGIN X509 CRL/)&&(this.hex=Yn(e)),this._setPos())};"undefined"!=typeof Sn&&Sn||(Sn={}),"undefined"!=typeof Sn.jws&&Sn.jws||(Sn.jws={}),Sn.jws.JWS=function(){var e=Sn,t=e.jws.JWS,n=t.isSafeJSONString;this.parseJWS=function(e,t){if(void 0===this.parsedJWS||!t&&void 0===this.parsedJWS.sigvalH){var r=e.match(/^([^.]+)\.([^.]+)\.([^.]+)$/);if(null==r)throw"JWS signature is not a form of 'Head.Payload.SigValue'.";var i=r[1],o=r[2],a=r[3],s=i+"."+o;if(this.parsedJWS={},this.parsedJWS.headB64U=i,this.parsedJWS.payloadB64U=o,this.parsedJWS.sigvalB64U=a,this.parsedJWS.si=s,!t){var l=Ln(a),c=Vt(l,16);this.parsedJWS.sigvalH=l,this.parsedJWS.sigvalBI=c}var u=xn(i),d=xn(o);if(this.parsedJWS.headS=u,this.parsedJWS.payloadS=d,!n(u,this.parsedJWS,"headP"))throw"malformed JSON string for JWS Head: "+u}}},Sn.jws.JWS.sign=function(e,t,n,r,i){var o,a,s,l=Sn,c=l.jws,u=c.JWS,d=u.readSafeJSONString,h=u.isSafeJSONString,p=l.crypto,f=(p.ECDSA,p.Mac),m=p.Signature,g=JSON;if("string"!=typeof t&&"object"!=typeof t)throw"spHeader must be JSON string or object: "+t;if("object"==typeof t&&(a=t,o=g.stringify(a)),"string"==typeof t){if(o=t,!h(o))throw"JWS Head is not safe JSON string: "+o;a=d(o)}if(s=n,"object"==typeof n&&(s=g.stringify(n)),""!=e&&null!=e||void 0===a.alg||(e=a.alg),""!=e&&null!=e&&void 0===a.alg&&(a.alg=e,o=g.stringify(a)),e!==a.alg)throw"alg and sHeader.alg doesn't match: "+e+"!="+a.alg;var v=null;if(void 0===u.jwsalg2sigalg[e])throw"unsupported alg name: "+e;v=u.jwsalg2sigalg[e];var b=En(o),y=En(s),w=b+"."+y,O="";if("Hmac"==v.substr(0,4)){if(void 0===r)throw"mac key shall be specified for HS* alg";var S=new f({alg:v,prov:"cryptojs",pass:r});S.updateString(w),O=S.doFinal()}else if(-1!=v.indexOf("withECDSA")){var E=new m({alg:v});E.init(r,i),E.updateString(w);var x=E.sign();O=Sn.crypto.ECDSA.asn1SigToConcatSig(x)}else if("none"!=v){E=new m({alg:v});E.init(r,i),E.updateString(w),O=E.sign()}var _=Dn(O);return w+"."+_},Sn.jws.JWS.verify=function(e,t,n){var r,i=Sn,o=i.jws,a=o.JWS,s=a.readSafeJSONString,l=i.crypto,c=l.ECDSA,u=l.Mac,d=l.Signature;if(void 0!==typeof Ft&&(r=Ft),!wr(e))return!1;var h=e.split(".");if(3!==h.length)return!1;var p=h[0],f=h[1],m=p+"."+f,g=Ln(h[2]),v=s(xn(h[0])),b=null,y=null;if(void 0===v.alg)throw"algorithm not specified in header";if(b=v.alg,y=b.substr(0,2),null!=n&&"[object Array]"===Object.prototype.toString.call(n)&&n.length>0){var w=":"+n.join(":")+":";if(-1==w.indexOf(":"+b+":"))throw"algorithm '"+b+"' not accepted in the list"}if("none"!=b&&null===t)throw"key shall be specified to verify.";if("string"==typeof t&&-1!=t.indexOf("-----BEGIN ")&&(t=Lr.getKey(t)),("RS"==y||"PS"==y)&&!(t instanceof r))throw"key shall be a RSAKey obj for RS* and PS* algs";if("ES"==y&&!(t instanceof c))throw"key shall be a ECDSA obj for ES* algs";var O=null;if(void 0===a.jwsalg2sigalg[v.alg])throw"unsupported alg name: "+b;if(O=a.jwsalg2sigalg[b],"none"==O)throw"not supported";if("Hmac"==O.substr(0,4)){var S=null;if(void 0===t)throw"hexadecimal key shall be specified for HMAC";var E=new u({alg:O,pass:t});return E.updateString(m),S=E.doFinal(),g==S}if(-1!=O.indexOf("withECDSA")){var x=null;try{x=c.concatSigToASN1Sig(g)}catch(k){return!1}var _=new d({alg:O});return _.init(t),_.updateString(m),_.verify(x)}_=new d({alg:O});return _.init(t),_.updateString(m),_.verify(g)},Sn.jws.JWS.parse=function(e){var t,n,r,i=e.split("."),o={};if(2!=i.length&&3!=i.length)throw"malformed sJWS: wrong number of '.' splitted elements";return t=i[0],n=i[1],3==i.length&&(r=i[2]),o.headerObj=Sn.jws.JWS.readSafeJSONString(xn(t)),o.payloadObj=Sn.jws.JWS.readSafeJSONString(xn(n)),o.headerPP=JSON.stringify(o.headerObj,null," "),null==o.payloadObj?o.payloadPP=xn(n):o.payloadPP=JSON.stringify(o.payloadObj,null," "),void 0!==r&&(o.sigHex=Ln(r)),o},Sn.jws.JWS.verifyJWT=function(e,t,n){var r=Sn,i=r.jws,o=i.JWS,a=o.readSafeJSONString,s=o.inArray,l=o.includedArray;if(!wr(e))return!1;var c=e.split(".");if(3!=c.length)return!1;var u=c[0],d=c[1],h=(Ln(c[2]),a(xn(u))),p=a(xn(d));if(void 0===h.alg)return!1;if(void 0===n.alg)throw"acceptField.alg shall be specified";if(!s(h.alg,n.alg))return!1;if(void 0!==p.iss&&"object"===typeof n.iss&&!s(p.iss,n.iss))return!1;if(void 0!==p.sub&&"object"===typeof n.sub&&!s(p.sub,n.sub))return!1;if(void 0!==p.aud&&"object"===typeof n.aud)if("string"==typeof p.aud){if(!s(p.aud,n.aud))return!1}else if("object"==typeof p.aud&&!l(p.aud,n.aud))return!1;var f=i.IntDate.getNow();return void 0!==n.verifyAt&&"number"===typeof n.verifyAt&&(f=n.verifyAt),void 0!==n.gracePeriod&&"number"===typeof n.gracePeriod||(n.gracePeriod=0),!(void 0!==p.exp&&"number"==typeof p.exp&&p.exp+n.gracePeriod<f)&&(!(void 0!==p.nbf&&"number"==typeof p.nbf&&f<p.nbf-n.gracePeriod)&&(!(void 0!==p.iat&&"number"==typeof p.iat&&f<p.iat-n.gracePeriod)&&((void 0===p.jti||void 0===n.jti||p.jti===n.jti)&&!!o.verify(e,t,n.alg))))},Sn.jws.JWS.includedArray=function(e,t){var n=Sn.jws.JWS.inArray;if(null===e)return!1;if("object"!==typeof e)return!1;if("number"!==typeof e.length)return!1;for(var r=0;r<e.length;r++)if(!n(e[r],t))return!1;return!0},Sn.jws.JWS.inArray=function(e,t){if(null===t)return!1;if("object"!==typeof t)return!1;if("number"!==typeof t.length)return!1;for(var n=0;n<t.length;n++)if(t[n]==e)return!0;return!1},Sn.jws.JWS.jwsalg2sigalg={HS256:"HmacSHA256",HS384:"HmacSHA384",HS512:"HmacSHA512",RS256:"SHA256withRSA",RS384:"SHA384withRSA",RS512:"SHA512withRSA",ES256:"SHA256withECDSA",ES384:"SHA384withECDSA",ES512:"SHA512withECDSA",PS256:"SHA256withRSAandMGF1",PS384:"SHA384withRSAandMGF1",PS512:"SHA512withRSAandMGF1",none:"none"},Sn.jws.JWS.isSafeJSONString=function(e,t,n){var r=null;try{return r=On(e),"object"!=typeof r?0:r.constructor===Array?0:(t&&(t[n]=r),1)}catch(i){return 0}},Sn.jws.JWS.readSafeJSONString=function(e){var t=null;try{return t=On(e),"object"!=typeof t||t.constructor===Array?null:t}catch(n){return null}},Sn.jws.JWS.getEncodedSignatureValueFromJWS=function(e){var t=e.match(/^[^.]+\.[^.]+\.([^.]+)$/);if(null==t)throw"JWS signature is not a form of 'Head.Payload.SigValue'.";return t[1]},Sn.jws.JWS.getJWKthumbprint=function(e){if("RSA"!==e.kty&&"EC"!==e.kty&&"oct"!==e.kty)throw"unsupported algorithm for JWK Thumprint";var t="{";if("RSA"===e.kty){if("string"!=typeof e.n||"string"!=typeof e.e)throw"wrong n and e value for RSA key";t+='"e":"'+e.e+'",',t+='"kty":"'+e.kty+'",',t+='"n":"'+e.n+'"}'}else if("EC"===e.kty){if("string"!=typeof e.crv||"string"!=typeof e.x||"string"!=typeof e.y)throw"wrong crv, x and y value for EC key";t+='"crv":"'+e.crv+'",',t+='"kty":"'+e.kty+'",',t+='"x":"'+e.x+'",',t+='"y":"'+e.y+'"}'}else if("oct"===e.kty){if("string"!=typeof e.k)throw"wrong k value for oct(symmetric) key";t+='"kty":"'+e.kty+'",',t+='"k":"'+e.k+'"}'}var n=Hn(t),r=Sn.crypto.Util.hashHex(n,"sha256"),i=Dn(r);return i},Sn.jws.IntDate={},Sn.jws.IntDate.get=function(e){var t=Sn.jws.IntDate,n=t.getNow,r=t.getZulu;if("now"==e)return n();if("now + 1hour"==e)return n()+3600;if("now + 1day"==e)return n()+86400;if("now + 1month"==e)return n()+2592e3;if("now + 1year"==e)return n()+31536e3;if(e.match(/Z$/))return r(e);if(e.match(/^[0-9]+$/))return parseInt(e);throw"unsupported format: "+e},Sn.jws.IntDate.getZulu=function(e){return rr(e)},Sn.jws.IntDate.getNow=function(){var e=~~(new Date/1e3);return e},Sn.jws.IntDate.intDate2UTCString=function(e){var t=new Date(1e3*e);return t.toUTCString()},Sn.jws.IntDate.intDate2Zulu=function(e){var t=new Date(1e3*e),n=("0000"+t.getUTCFullYear()).slice(-4),r=("00"+(t.getUTCMonth()+1)).slice(-2),i=("00"+t.getUTCDate()).slice(-2),o=("00"+t.getUTCHours()).slice(-2),a=("00"+t.getUTCMinutes()).slice(-2),s=("00"+t.getUTCSeconds()).slice(-2);return n+r+i+o+a+s+"Z"},"undefined"!=typeof Sn&&Sn||(Sn={}),"undefined"!=typeof Sn.jws&&Sn.jws||(Sn.jws={}),Sn.jws.JWSJS=function(){var e=Sn,t=e.jws,n=t.JWS,r=n.readSafeJSONString;this.aHeader=[],this.sPayload="",this.aSignature=[],this.init=function(){this.aHeader=[],this.sPayload=void 0,this.aSignature=[]},this.initWithJWS=function(e){this.init();var t=e.split(".");if(3!=t.length)throw"malformed input JWS";this.aHeader.push(t[0]),this.sPayload=t[1],this.aSignature.push(t[2])},this.addSignature=function(e,t,n,r){if(void 0===this.sPayload||null===this.sPayload)throw"there's no JSON-JS signature to add.";var i=this.aHeader.length;if(this.aHeader.length!=this.aSignature.length)throw"aHeader.length != aSignature.length";try{var o=Sn.jws.JWS.sign(e,t,this.sPayload,n,r),a=o.split(".");a[0],a[2];this.aHeader.push(a[0]),this.aSignature.push(a[2])}catch(s){throw this.aHeader.length>i&&this.aHeader.pop(),this.aSignature.length>i&&this.aSignature.pop(),"addSignature failed: "+s}},this.verifyAll=function(e){if(this.aHeader.length!==e.length||this.aSignature.length!==e.length)return!1;for(var t=0;t<e.length;t++){var n=e[t];if(2!==n.length)return!1;var r=this.verifyNth(t,n[0],n[1]);if(!1===r)return!1}return!0},this.verifyNth=function(e,t,r){if(this.aHeader.length<=e||this.aSignature.length<=e)return!1;var i=this.aHeader[e],o=this.aSignature[e],a=i+"."+this.sPayload+"."+o,s=!1;try{s=n.verify(a,t,r)}catch(l){return!1}return s},this.readJWSJS=function(e){if("string"===typeof e){var t=r(e);if(null==t)throw"argument is not safe JSON object string";this.aHeader=t.headers,this.sPayload=t.payload,this.aSignature=t.signatures}else try{if(!(e.headers.length>0))throw"malformed header";if(this.aHeader=e.headers,"string"!==typeof e.payload)throw"malformed signatures";if(this.sPayload=e.payload,!(e.signatures.length>0))throw"malformed signatures";this.aSignature=e.signatures}catch(n){throw"malformed JWS-JS JSON object: "+n}},this.getJSON=function(){return{headers:this.aHeader,payload:this.sPayload,signatures:this.aSignature}},this.isEmpty=function(){return 0==this.aHeader.length?1:0}},t.SecureRandom=$t,t.rng_seed_time=Nt,t.BigInteger=v,t.RSAKey=Ft,t.ECDSA=Sn.crypto.ECDSA,t.DSA=Sn.crypto.DSA,t.Signature=Sn.crypto.Signature,t.MessageDigest=Sn.crypto.MessageDigest,t.Mac=Sn.crypto.Mac,t.KEYUTIL=Lr,t.ASN1HEX=_n,t.X509=Fr,t.X509CRL=jr,t.CryptoJS=l,t.b64tohex=p,t.b64toBA=f,t.ECFieldElementFp=zt,t.ECPointFp=nn,t.ECCurveFp=pn,t.stoBA=kn,t.BAtos=Cn,t.BAtohex=An,t.stohex=Tn,t.stob64=Rn,t.stob64u=Nn,t.b64utos=Pn,t.b64tob64u=In,t.b64utob64=Mn,t.hex2b64=h,t.hextob64u=Dn,t.b64utohex=Ln,t.utf8tob64u=En,t.b64utoutf8=xn,t.utf8tob64=Bn,t.b64toutf8=$n,t.utf8tohex=Vn,t.hextoutf8=Fn,t.hextorstr=Gn,t.rstrtohex=Hn,t.hextob64=qn,t.hextob64nl=Qn,t.b64nltohex=Kn,t.hextopem=Xn,t.pemtohex=Yn,t.hextoArrayBuffer=Jn,t.ArrayBuffertohex=er,t.zulutomsec=tr,t.msectozulu=nr,t.zulutosec=rr,t.zulutodate=ir,t.datetozulu=or,t.uricmptohex=sr,t.hextouricmp=lr,t.ipv6tohex=cr,t.hextoipv6=ur,t.hextoip=dr,t.iptohex=pr,t.ucs2hextoutf8=mr,t.encodeURIComponentAll=gr,t.newline_toUnix=vr,t.newline_toDos=br,t.hextoposhex=Or,t.intarystrtohex=Sr,t.strdiffidx=Er,t.oidtohex=xr,t.hextooid=_r,t.strpad=Ar,t.bitstrtoint=Tr,t.inttobitstr=Rr,t.bitstrtobinstr=Nr,t.binstrtobitstr=Pr,t.isBase64URLDot=wr,t.namearraytobinstr=Ir,t.extendClass=Dr,t.foldnl=zn,t.b64topem=Wn,t.pemtob64=Zn,t.timeogen=ar,t.aryval=Mr,t.inttohex=kr,t.twoscompl=Cr,t.KJUR=Sn,t.crypto=Sn.crypto,t.asn1=Sn.asn1,t.jws=Sn.jws,t.lang=Sn.lang,t.VERSION=a,t.VERSION_FULL=s},33103:function(e,t,n){var r=n(94715),i=n(78942),o=r(i,"DataView");e.exports=o},25098:function(e,t,n){var r=n(23305),i=n(39361),o=n(11112),a=n(25276),s=n(57452);function l(e){var t=-1,n=null==e?0:e.length;this.clear();while(++t<n){var r=e[t];this.set(r[0],r[1])}}l.prototype.clear=r,l.prototype["delete"]=i,l.prototype.get=o,l.prototype.has=a,l.prototype.set=s,e.exports=l},1386:function(e,t,n){var r=n(12393),i=n(62049),o=n(7144),a=n(7452),s=n(13964);function l(e){var t=-1,n=null==e?0:e.length;this.clear();while(++t<n){var r=e[t];this.set(r[0],r[1])}}l.prototype.clear=r,l.prototype["delete"]=i,l.prototype.get=o,l.prototype.has=a,l.prototype.set=s,e.exports=l},19770:function(e,t,n){var r=n(94715),i=n(78942),o=r(i,"Map");e.exports=o},68250:function(e,t,n){var r=n(49753),i=n(5681),o=n(80088),a=n(54732),s=n(59068);function l(e){var t=-1,n=null==e?0:e.length;this.clear();while(++t<n){var r=e[t];this.set(r[0],r[1])}}l.prototype.clear=r,l.prototype["delete"]=i,l.prototype.get=o,l.prototype.has=a,l.prototype.set=s,e.exports=l},89413:function(e,t,n){var r=n(94715),i=n(78942),o=r(i,"Promise");e.exports=o},64512:function(e,t,n){var r=n(94715),i=n(78942),o=r(i,"Set");e.exports=o},23212:function(e,t,n){var r=n(68250),i=n(1877),o=n(8006);function a(e){var t=-1,n=null==e?0:e.length;this.__data__=new r;while(++t<n)this.add(e[t])}a.prototype.add=a.prototype.push=i,a.prototype.has=o,e.exports=a},51340:function(e,t,n){var r=n(1386),i=n(64103),o=n(21779),a=n(34162),s=n(7462),l=n(96638);function c(e){var t=this.__data__=new r(e);this.size=t.size}c.prototype.clear=i,c.prototype["delete"]=o,c.prototype.get=a,c.prototype.has=s,c.prototype.set=l,e.exports=c},65650:function(e,t,n){var r=n(78942),i=r.Symbol;e.exports=i},31623:function(e,t,n){var r=n(78942),i=r.Uint8Array;e.exports=i},19270:function(e,t,n){var r=n(94715),i=n(78942),o=r(i,"WeakMap");e.exports=o},86912:function(e){function t(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}e.exports=t},79968:function(e){function t(e,t){var n=-1,r=null==e?0:e.length;while(++n<r)if(!1===t(e[n],n,e))break;return e}e.exports=t},79847:function(e){function t(e,t){var n=-1,r=null==e?0:e.length,i=0,o=[];while(++n<r){var a=e[n];t(a,n,e)&&(o[i++]=a)}return o}e.exports=t},59756:function(e,t,n){var r=n(2478);function i(e,t){var n=null==e?0:e.length;return!!n&&r(e,t,0)>-1}e.exports=i},43316:function(e){function t(e,t,n){var r=-1,i=null==e?0:e.length;while(++r<i)if(n(t,e[r]))return!0;return!1}e.exports=t},10358:function(e,t,n){var r=n(26137),i=n(3283),o=n(53142),a=n(75853),s=n(69632),l=n(8666),c=Object.prototype,u=c.hasOwnProperty;function d(e,t){var n=o(e),c=!n&&i(e),d=!n&&!c&&a(e),h=!n&&!c&&!d&&l(e),p=n||c||d||h,f=p?r(e.length,String):[],m=f.length;for(var g in e)!t&&!u.call(e,g)||p&&("length"==g||d&&("offset"==g||"parent"==g)||h&&("buffer"==g||"byteLength"==g||"byteOffset"==g)||s(g,m))||f.push(g);return f}e.exports=d},65111:function(e){function t(e,t){var n=-1,r=null==e?0:e.length,i=Array(r);while(++n<r)i[n]=t(e[n],n,e);return i}e.exports=t},11129:function(e){function t(e,t){var n=-1,r=t.length,i=e.length;while(++n<r)e[i+n]=t[n];return e}e.exports=t},44187:function(e){function t(e,t,n,r){var i=-1,o=null==e?0:e.length;r&&o&&(n=e[++i]);while(++i<o)n=t(n,e[i],i,e);return n}e.exports=t},36465:function(e){function t(e,t){var n=-1,r=null==e?0:e.length;while(++n<r)if(t(e[n],n,e))return!0;return!1}e.exports=t},52837:function(e){function t(e){return e.split("")}e.exports=t},39546:function(e){var t=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function n(e){return e.match(t)||[]}e.exports=n},24810:function(e,t,n){var r=n(57073),i=n(46285);function o(e,t,n){(void 0!==n&&!i(e[t],n)||void 0===n&&!(t in e))&&r(e,t,n)}e.exports=o},3422:function(e,t,n){var r=n(57073),i=n(46285),o=Object.prototype,a=o.hasOwnProperty;function s(e,t,n){var o=e[t];a.call(e,t)&&i(o,n)&&(void 0!==n||t in e)||r(e,t,n)}e.exports=s},97034:function(e,t,n){var r=n(46285);function i(e,t){var n=e.length;while(n--)if(r(e[n][0],t))return n;return-1}e.exports=i},37930:function(e,t,n){var r=n(39032),i=n(81211);function o(e,t){return e&&r(t,i(t),e)}e.exports=o},30125:function(e,t,n){var r=n(39032),i=n(25288);function o(e,t){return e&&r(t,i(t),e)}e.exports=o},57073:function(e,t,n){var r=n(72532);function i(e,t,n){"__proto__"==t&&r?r(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}e.exports=i},69334:function(e,t,n){var r=n(51340),i=n(79968),o=n(3422),a=n(37930),s=n(30125),l=n(17099),c=n(84354),u=n(83546),d=n(24733),h=n(80393),p=n(93650),f=n(28486),m=n(97350),g=n(50424),v=n(75964),b=n(53142),y=n(75853),w=n(37681),O=n(41580),S=n(83943),E=n(81211),x=n(25288),_=1,k=2,C=4,A="[object Arguments]",T="[object Array]",R="[object Boolean]",N="[object Date]",P="[object Error]",I="[object Function]",M="[object GeneratorFunction]",D="[object Map]",L="[object Number]",B="[object Object]",$="[object RegExp]",V="[object Set]",F="[object String]",j="[object Symbol]",U="[object WeakMap]",G="[object ArrayBuffer]",H="[object DataView]",q="[object Float32Array]",Q="[object Float64Array]",z="[object Int8Array]",K="[object Int16Array]",W="[object Int32Array]",X="[object Uint8Array]",Y="[object Uint8ClampedArray]",Z="[object Uint16Array]",J="[object Uint32Array]",ee={};function te(e,t,n,T,R,N){var P,D=t&_,L=t&k,$=t&C;if(n&&(P=R?n(e,T,R,N):n(e)),void 0!==P)return P;if(!O(e))return e;var V=b(e);if(V){if(P=m(e),!D)return c(e,P)}else{var F=f(e),j=F==I||F==M;if(y(e))return l(e,D);if(F==B||F==A||j&&!R){if(P=L||j?{}:v(e),!D)return L?d(e,s(P,e)):u(e,a(P,e))}else{if(!ee[F])return R?e:{};P=g(e,F,D)}}N||(N=new r);var U=N.get(e);if(U)return U;N.set(e,P),S(e)?e.forEach(function(r){P.add(te(r,t,n,r,e,N))}):w(e)&&e.forEach(function(r,i){P.set(i,te(r,t,n,i,e,N))});var G=$?L?p:h:L?x:E,H=V?void 0:G(e);return i(H||e,function(r,i){H&&(i=r,r=e[i]),o(P,i,te(r,t,n,i,e,N))}),P}ee[A]=ee[T]=ee[G]=ee[H]=ee[R]=ee[N]=ee[q]=ee[Q]=ee[z]=ee[K]=ee[W]=ee[D]=ee[L]=ee[B]=ee[$]=ee[V]=ee[F]=ee[j]=ee[X]=ee[Y]=ee[Z]=ee[J]=!0,ee[P]=ee[I]=ee[U]=!1,e.exports=te},39747:function(e,t,n){var r=n(41580),i=Object.create,o=function(){function e(){}return function(t){if(!r(t))return{};if(i)return i(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();e.exports=o},96576:function(e,t,n){var r=n(23212),i=n(59756),o=n(43316),a=n(65111),s=n(49460),l=n(65568),c=200;function u(e,t,n,u){var d=-1,h=i,p=!0,f=e.length,m=[],g=t.length;if(!f)return m;n&&(t=a(t,s(n))),u?(h=o,p=!1):t.length>=c&&(h=l,p=!1,t=new r(t));e:while(++d<f){var v=e[d],b=null==n?v:n(v);if(v=u||0!==v?v:0,p&&b===b){var y=g;while(y--)if(t[y]===b)continue e;m.push(v)}else h(t,b,u)||m.push(v)}return m}e.exports=u},37250:function(e){function t(e,t,n,r){var i=e.length,o=n+(r?1:-1);while(r?o--:++o<i)if(t(e[o],o,e))return o;return-1}e.exports=t},90313:function(e,t,n){var r=n(11129),i=n(20714);function o(e,t,n,a,s){var l=-1,c=e.length;n||(n=i),s||(s=[]);while(++l<c){var u=e[l];t>0&&n(u)?t>1?o(u,t-1,n,a,s):r(s,u):a||(s[s.length]=u)}return s}e.exports=o},35636:function(e,t,n){var r=n(86596),i=r();e.exports=i},47170:function(e,t,n){var r=n(35636),i=n(81211);function o(e,t){return e&&r(e,t,i)}e.exports=o},57923:function(e,t,n){var r=n(93526),i=n(66040);function o(e,t){t=r(t,e);var n=0,o=t.length;while(null!=e&&n<o)e=e[i(t[n++])];return n&&n==o?e:void 0}e.exports=o},48244:function(e,t,n){var r=n(11129),i=n(53142);function o(e,t,n){var o=t(e);return i(e)?o:r(o,n(e))}e.exports=o},87379:function(e,t,n){var r=n(65650),i=n(8870),o=n(29005),a="[object Null]",s="[object Undefined]",l=r?r.toStringTag:void 0;function c(e){return null==e?void 0===e?s:a:l&&l in Object(e)?i(e):o(e)}e.exports=c},63599:function(e){var t=Object.prototype,n=t.hasOwnProperty;function r(e,t){return null!=e&&n.call(e,t)}e.exports=r},43636:function(e){function t(e,t){return null!=e&&t in Object(e)}e.exports=t},2478:function(e,t,n){var r=n(37250),i=n(69454),o=n(97706);function a(e,t,n){return t===t?o(e,t,n):r(e,i,n)}e.exports=a},56027:function(e,t,n){var r=n(87379),i=n(80547),o="[object Arguments]";function a(e){return i(e)&&r(e)==o}e.exports=a},94687:function(e,t,n){var r=n(90353),i=n(80547);function o(e,t,n,a,s){return e===t||(null==e||null==t||!i(e)&&!i(t)?e!==e&&t!==t:r(e,t,n,a,o,s))}e.exports=o},90353:function(e,t,n){var r=n(51340),i=n(33934),o=n(88861),a=n(31182),s=n(28486),l=n(53142),c=n(75853),u=n(8666),d=1,h="[object Arguments]",p="[object Array]",f="[object Object]",m=Object.prototype,g=m.hasOwnProperty;function v(e,t,n,m,v,b){var y=l(e),w=l(t),O=y?p:s(e),S=w?p:s(t);O=O==h?f:O,S=S==h?f:S;var E=O==f,x=S==f,_=O==S;if(_&&c(e)){if(!c(t))return!1;y=!0,E=!1}if(_&&!E)return b||(b=new r),y||u(e)?i(e,t,n,m,v,b):o(e,t,O,n,m,v,b);if(!(n&d)){var k=E&&g.call(e,"__wrapped__"),C=x&&g.call(t,"__wrapped__");if(k||C){var A=k?e.value():e,T=C?t.value():t;return b||(b=new r),v(A,T,n,m,b)}}return!!_&&(b||(b=new r),a(e,t,n,m,v,b))}e.exports=v},80777:function(e,t,n){var r=n(28486),i=n(80547),o="[object Map]";function a(e){return i(e)&&r(e)==o}e.exports=a},38330:function(e,t,n){var r=n(51340),i=n(94687),o=1,a=2;function s(e,t,n,s){var l=n.length,c=l,u=!s;if(null==e)return!c;e=Object(e);while(l--){var d=n[l];if(u&&d[2]?d[1]!==e[d[0]]:!(d[0]in e))return!1}while(++l<c){d=n[l];var h=d[0],p=e[h],f=d[1];if(u&&d[2]){if(void 0===p&&!(h in e))return!1}else{var m=new r;if(s)var g=s(p,f,h,e,t,m);if(!(void 0===g?i(f,p,o|a,s,m):g))return!1}}return!0}e.exports=s},69454:function(e){function t(e){return e!==e}e.exports=t},89624:function(e,t,n){var r=n(93655),i=n(64759),o=n(41580),a=n(64066),s=/[\\^$.*+?()[\]{}|]/g,l=/^\[object .+?Constructor\]$/,c=Function.prototype,u=Object.prototype,d=c.toString,h=u.hasOwnProperty,p=RegExp("^"+d.call(h).replace(s,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function f(e){if(!o(e)||i(e))return!1;var t=r(e)?p:l;return t.test(a(e))}e.exports=f},81935:function(e,t,n){var r=n(28486),i=n(80547),o="[object Set]";function a(e){return i(e)&&r(e)==o}e.exports=a},70674:function(e,t,n){var r=n(87379),i=n(65387),o=n(80547),a="[object Arguments]",s="[object Array]",l="[object Boolean]",c="[object Date]",u="[object Error]",d="[object Function]",h="[object Map]",p="[object Number]",f="[object Object]",m="[object RegExp]",g="[object Set]",v="[object String]",b="[object WeakMap]",y="[object ArrayBuffer]",w="[object DataView]",O="[object Float32Array]",S="[object Float64Array]",E="[object Int8Array]",x="[object Int16Array]",_="[object Int32Array]",k="[object Uint8Array]",C="[object Uint8ClampedArray]",A="[object Uint16Array]",T="[object Uint32Array]",R={};function N(e){return o(e)&&i(e.length)&&!!R[r(e)]}R[O]=R[S]=R[E]=R[x]=R[_]=R[k]=R[C]=R[A]=R[T]=!0,R[a]=R[s]=R[y]=R[l]=R[w]=R[c]=R[u]=R[d]=R[h]=R[p]=R[f]=R[m]=R[g]=R[v]=R[b]=!1,e.exports=N},3334:function(e,t,n){var r=n(36526),i=n(12343),o=n(22053),a=n(53142),s=n(43282);function l(e){return"function"==typeof e?e:null==e?o:"object"==typeof e?a(e)?i(e[0],e[1]):r(e):s(e)}e.exports=l},195:function(e,t,n){var r=n(84882),i=n(98121),o=Object.prototype,a=o.hasOwnProperty;function s(e){if(!r(e))return i(e);var t=[];for(var n in Object(e))a.call(e,n)&&"constructor"!=n&&t.push(n);return t}e.exports=s},57200:function(e,t,n){var r=n(41580),i=n(84882),o=n(38546),a=Object.prototype,s=a.hasOwnProperty;function l(e){if(!r(e))return o(e);var t=i(e),n=[];for(var a in e)("constructor"!=a||!t&&s.call(e,a))&&n.push(a);return n}e.exports=l},36526:function(e,t,n){var r=n(38330),i=n(24367),o=n(23904);function a(e){var t=i(e);return 1==t.length&&t[0][2]?o(t[0][0],t[0][1]):function(n){return n===e||r(n,e,t)}}e.exports=a},12343:function(e,t,n){var r=n(94687),i=n(46123),o=n(27276),a=n(65187),s=n(67267),l=n(23904),c=n(66040),u=1,d=2;function h(e,t){return a(e)&&s(t)?l(c(e),t):function(n){var a=i(n,e);return void 0===a&&a===t?o(n,e):r(t,a,u|d)}}e.exports=h},40091:function(e,t,n){var r=n(51340),i=n(24810),o=n(35636),a=n(26885),s=n(41580),l=n(25288),c=n(78763);function u(e,t,n,d,h){e!==t&&o(t,function(o,l){if(h||(h=new r),s(o))a(e,t,l,n,u,d,h);else{var p=d?d(c(e,l),o,l+"",e,t,h):void 0;void 0===p&&(p=o),i(e,l,p)}},l)}e.exports=u},26885:function(e,t,n){var r=n(24810),i=n(17099),o=n(92264),a=n(84354),s=n(75964),l=n(3283),c=n(53142),u=n(65406),d=n(75853),h=n(93655),p=n(41580),f=n(48360),m=n(8666),g=n(78763),v=n(64207);function b(e,t,n,b,y,w,O){var S=g(e,n),E=g(t,n),x=O.get(E);if(x)r(e,n,x);else{var _=w?w(S,E,n+"",e,t,O):void 0,k=void 0===_;if(k){var C=c(E),A=!C&&d(E),T=!C&&!A&&m(E);_=E,C||A||T?c(S)?_=S:u(S)?_=a(S):A?(k=!1,_=i(E,!0)):T?(k=!1,_=o(E,!0)):_=[]:f(E)||l(E)?(_=S,l(S)?_=v(S):p(S)&&!h(S)||(_=s(E))):k=!1}k&&(O.set(E,_),y(_,E,b,w,O),O["delete"](E)),r(e,n,_)}}e.exports=b},90242:function(e,t,n){var r=n(35031),i=n(27276);function o(e,t){return r(e,t,function(t,n){return i(e,n)})}e.exports=o},35031:function(e,t,n){var r=n(57923),i=n(87655),o=n(93526);function a(e,t,n){var a=-1,s=t.length,l={};while(++a<s){var c=t[a],u=r(e,c);n(u,c)&&i(l,o(c,e),u)}return l}e.exports=a},12762:function(e){function t(e){return function(t){return null==t?void 0:t[e]}}e.exports=t},98880:function(e,t,n){var r=n(57923);function i(e){return function(t){return r(t,e)}}e.exports=i},51035:function(e){function t(e){return function(t){return null==e?void 0:e[t]}}e.exports=t},23945:function(e,t,n){var r=n(22053),i=n(75234),o=n(80796);function a(e,t){return o(i(e,t,r),e+"")}e.exports=a},87655:function(e,t,n){var r=n(3422),i=n(93526),o=n(69632),a=n(41580),s=n(66040);function l(e,t,n,l){if(!a(e))return e;t=i(t,e);var c=-1,u=t.length,d=u-1,h=e;while(null!=h&&++c<u){var p=s(t[c]),f=n;if("__proto__"===p||"constructor"===p||"prototype"===p)return e;if(c!=d){var m=h[p];f=l?l(m,p,h):void 0,void 0===f&&(f=a(m)?m:o(t[c+1])?[]:{})}r(h,p,f),h=h[p]}return e}e.exports=l},47403:function(e,t,n){var r=n(82619),i=n(72532),o=n(22053),a=i?function(e,t){return i(e,"toString",{configurable:!0,enumerable:!1,value:r(t),writable:!0})}:o;e.exports=a},73501:function(e){function t(e,t,n){var r=-1,i=e.length;t<0&&(t=-t>i?0:i+t),n=n>i?i:n,n<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;var o=Array(i);while(++r<i)o[r]=e[r+t];return o}e.exports=t},26137:function(e){function t(e,t){var n=-1,r=Array(e);while(++n<e)r[n]=t(n);return r}e.exports=t},52291:function(e,t,n){var r=n(65650),i=n(65111),o=n(53142),a=n(51187),s=1/0,l=r?r.prototype:void 0,c=l?l.toString:void 0;function u(e){if("string"==typeof e)return e;if(o(e))return i(e,u)+"";if(a(e))return c?c.call(e):"";var t=e+"";return"0"==t&&1/e==-s?"-0":t}e.exports=u},86403:function(e,t,n){var r=n(62945),i=/^\s+/;function o(e){return e?e.slice(0,r(e)+1).replace(i,""):e}e.exports=o},49460:function(e){function t(e){return function(t){return e(t)}}e.exports=t},15630:function(e,t,n){var r=n(23212),i=n(59756),o=n(43316),a=n(65568),s=n(36208),l=n(49828),c=200;function u(e,t,n){var u=-1,d=i,h=e.length,p=!0,f=[],m=f;if(n)p=!1,d=o;else if(h>=c){var g=t?null:s(e);if(g)return l(g);p=!1,d=a,m=new r}else m=t?[]:f;e:while(++u<h){var v=e[u],b=t?t(v):v;if(v=n||0!==v?v:0,p&&b===b){var y=m.length;while(y--)if(m[y]===b)continue e;t&&m.push(b),f.push(v)}else d(m,b,n)||(m!==f&&m.push(b),f.push(v))}return f}e.exports=u},3905:function(e,t,n){var r=n(65111);function i(e,t){return r(t,function(t){return e[t]})}e.exports=i},80214:function(e,t,n){var r=n(96576),i=n(90313),o=n(15630);function a(e,t,n){var a=e.length;if(a<2)return a?o(e[0]):[];var s=-1,l=Array(a);while(++s<a){var c=e[s],u=-1;while(++u<a)u!=s&&(l[s]=r(l[s]||c,e[u],t,n))}return o(i(l,1),t,n)}e.exports=a},65568:function(e){function t(e,t){return e.has(t)}e.exports=t},23997:function(e,t,n){var r=n(22053);function i(e){return"function"==typeof e?e:r}e.exports=i},93526:function(e,t,n){var r=n(53142),i=n(65187),o=n(96493),a=n(95243);function s(e,t){return r(e)?e:i(e,t)?[e]:o(a(e))}e.exports=s},28931:function(e,t,n){var r=n(73501);function i(e,t,n){var i=e.length;return n=void 0===n?i:n,!t&&n>=i?e:r(e,t,n)}e.exports=i},58898:function(e,t,n){var r=n(31623);function i(e){var t=new e.constructor(e.byteLength);return new r(t).set(new r(e)),t}e.exports=i},17099:function(e,t,n){e=n.nmd(e);var r=n(78942),i=t&&!t.nodeType&&t,o=i&&e&&!e.nodeType&&e,a=o&&o.exports===i,s=a?r.Buffer:void 0,l=s?s.allocUnsafe:void 0;function c(e,t){if(t)return e.slice();var n=e.length,r=l?l(n):new e.constructor(n);return e.copy(r),r}e.exports=c},92480:function(e,t,n){var r=n(58898);function i(e,t){var n=t?r(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}e.exports=i},78340:function(e){var t=/\w*$/;function n(e){var n=new e.constructor(e.source,t.exec(e));return n.lastIndex=e.lastIndex,n}e.exports=n},18069:function(e,t,n){var r=n(65650),i=r?r.prototype:void 0,o=i?i.valueOf:void 0;function a(e){return o?Object(o.call(e)):{}}e.exports=a},92264:function(e,t,n){var r=n(58898);function i(e,t){var n=t?r(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}e.exports=i},84354:function(e){function t(e,t){var n=-1,r=e.length;t||(t=Array(r));while(++n<r)t[n]=e[n];return t}e.exports=t},39032:function(e,t,n){var r=n(3422),i=n(57073);function o(e,t,n,o){var a=!n;n||(n={});var s=-1,l=t.length;while(++s<l){var c=t[s],u=o?o(n[c],e[c],c,n,e):void 0;void 0===u&&(u=e[c]),a?i(n,c,u):r(n,c,u)}return n}e.exports=o},83546:function(e,t,n){var r=n(39032),i=n(77979);function o(e,t){return r(e,i(e),t)}e.exports=o},24733:function(e,t,n){var r=n(39032),i=n(85832);function o(e,t){return r(e,i(e),t)}e.exports=o},41950:function(e,t,n){var r=n(78942),i=r["__core-js_shared__"];e.exports=i},77848:function(e,t,n){var r=n(23945),i=n(74535);function o(e){return r(function(t,n){var r=-1,o=n.length,a=o>1?n[o-1]:void 0,s=o>2?n[2]:void 0;a=e.length>3&&"function"==typeof a?(o--,a):void 0,s&&i(n[0],n[1],s)&&(a=o<3?void 0:a,o=1),t=Object(t);while(++r<o){var l=n[r];l&&e(t,l,r,a)}return t})}e.exports=o},86596:function(e){function t(e){return function(t,n,r){var i=-1,o=Object(t),a=r(t),s=a.length;while(s--){var l=a[e?s:++i];if(!1===n(o[l],l,o))break}return t}}e.exports=t},4326:function(e,t,n){var r=n(28931),i=n(83417),o=n(82237),a=n(95243);function s(e){return function(t){t=a(t);var n=i(t)?o(t):void 0,s=n?n[0]:t.charAt(0),l=n?r(n,1).join(""):t.slice(1);return s[e]()+l}}e.exports=s},93640:function(e,t,n){var r=n(44187),i=n(45881),o=n(39850),a="['’]",s=RegExp(a,"g");function l(e){return function(t){return r(o(i(t).replace(s,"")),e,"")}}e.exports=l},77317:function(e,t,n){var r=n(3334),i=n(36529),o=n(81211);function a(e){return function(t,n,a){var s=Object(t);if(!i(t)){var l=r(n,3);t=o(t),n=function(e){return l(s[e],e,s)}}var c=e(t,n,a);return c>-1?s[l?t[c]:c]:void 0}}e.exports=a},36208:function(e,t,n){var r=n(64512),i=n(79071),o=n(49828),a=1/0,s=r&&1/o(new r([,-0]))[1]==a?function(e){return new r(e)}:i;e.exports=s},69968:function(e,t,n){var r=n(51035),i={"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"},o=r(i);e.exports=o},72532:function(e,t,n){var r=n(94715),i=function(){try{var e=r(Object,"defineProperty");return e({},"",{}),e}catch(t){}}();e.exports=i},33934:function(e,t,n){var r=n(23212),i=n(36465),o=n(65568),a=1,s=2;function l(e,t,n,l,c,u){var d=n&a,h=e.length,p=t.length;if(h!=p&&!(d&&p>h))return!1;var f=u.get(e),m=u.get(t);if(f&&m)return f==t&&m==e;var g=-1,v=!0,b=n&s?new r:void 0;u.set(e,t),u.set(t,e);while(++g<h){var y=e[g],w=t[g];if(l)var O=d?l(w,y,g,t,e,u):l(y,w,g,e,t,u);if(void 0!==O){if(O)continue;v=!1;break}if(b){if(!i(t,function(e,t){if(!o(b,t)&&(y===e||c(y,e,n,l,u)))return b.push(t)})){v=!1;break}}else if(y!==w&&!c(y,w,n,l,u)){v=!1;break}}return u["delete"](e),u["delete"](t),v}e.exports=l},88861:function(e,t,n){var r=n(65650),i=n(31623),o=n(46285),a=n(33934),s=n(95894),l=n(49828),c=1,u=2,d="[object Boolean]",h="[object Date]",p="[object Error]",f="[object Map]",m="[object Number]",g="[object RegExp]",v="[object Set]",b="[object String]",y="[object Symbol]",w="[object ArrayBuffer]",O="[object DataView]",S=r?r.prototype:void 0,E=S?S.valueOf:void 0;function x(e,t,n,r,S,x,_){switch(n){case O:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case w:return!(e.byteLength!=t.byteLength||!x(new i(e),new i(t)));case d:case h:case m:return o(+e,+t);case p:return e.name==t.name&&e.message==t.message;case g:case b:return e==t+"";case f:var k=s;case v:var C=r&c;if(k||(k=l),e.size!=t.size&&!C)return!1;var A=_.get(e);if(A)return A==t;r|=u,_.set(e,t);var T=a(k(e),k(t),r,S,x,_);return _["delete"](e),T;case y:if(E)return E.call(e)==E.call(t)}return!1}e.exports=x},31182:function(e,t,n){var r=n(80393),i=1,o=Object.prototype,a=o.hasOwnProperty;function s(e,t,n,o,s,l){var c=n&i,u=r(e),d=u.length,h=r(t),p=h.length;if(d!=p&&!c)return!1;var f=d;while(f--){var m=u[f];if(!(c?m in t:a.call(t,m)))return!1}var g=l.get(e),v=l.get(t);if(g&&v)return g==t&&v==e;var b=!0;l.set(e,t),l.set(t,e);var y=c;while(++f<d){m=u[f];var w=e[m],O=t[m];if(o)var S=c?o(O,w,m,t,e,l):o(w,O,m,e,t,l);if(!(void 0===S?w===O||s(w,O,n,o,l):S)){b=!1;break}y||(y="constructor"==m)}if(b&&!y){var E=e.constructor,x=t.constructor;E==x||!("constructor"in e)||!("constructor"in t)||"function"==typeof E&&E instanceof E&&"function"==typeof x&&x instanceof x||(b=!1)}return l["delete"](e),l["delete"](t),b}e.exports=s},41439:function(e,t,n){var r=n(75857),i=n(75234),o=n(80796);function a(e){return o(i(e,void 0,r),e+"")}e.exports=a},74967:function(e,t,n){var r="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g;e.exports=r},80393:function(e,t,n){var r=n(48244),i=n(77979),o=n(81211);function a(e){return r(e,o,i)}e.exports=a},93650:function(e,t,n){var r=n(48244),i=n(85832),o=n(25288);function a(e){return r(e,o,i)}e.exports=a},44700:function(e,t,n){var r=n(79067);function i(e,t){var n=e.__data__;return r(t)?n["string"==typeof t?"string":"hash"]:n.map}e.exports=i},24367:function(e,t,n){var r=n(67267),i=n(81211);function o(e){var t=i(e),n=t.length;while(n--){var o=t[n],a=e[o];t[n]=[o,a,r(a)]}return t}e.exports=o},94715:function(e,t,n){var r=n(89624),i=n(20155);function o(e,t){var n=i(e,t);return r(n)?n:void 0}e.exports=o},74784:function(e,t,n){var r=n(3766),i=r(Object.getPrototypeOf,Object);e.exports=i},8870:function(e,t,n){var r=n(65650),i=Object.prototype,o=i.hasOwnProperty,a=i.toString,s=r?r.toStringTag:void 0;function l(e){var t=o.call(e,s),n=e[s];try{e[s]=void 0;var r=!0}catch(l){}var i=a.call(e);return r&&(t?e[s]=n:delete e[s]),i}e.exports=l},77979:function(e,t,n){var r=n(79847),i=n(99306),o=Object.prototype,a=o.propertyIsEnumerable,s=Object.getOwnPropertySymbols,l=s?function(e){return null==e?[]:(e=Object(e),r(s(e),function(t){return a.call(e,t)}))}:i;e.exports=l},85832:function(e,t,n){var r=n(11129),i=n(74784),o=n(77979),a=n(99306),s=Object.getOwnPropertySymbols,l=s?function(e){var t=[];while(e)r(t,o(e)),e=i(e);return t}:a;e.exports=l},28486:function(e,t,n){var r=n(33103),i=n(19770),o=n(89413),a=n(64512),s=n(19270),l=n(87379),c=n(64066),u="[object Map]",d="[object Object]",h="[object Promise]",p="[object Set]",f="[object WeakMap]",m="[object DataView]",g=c(r),v=c(i),b=c(o),y=c(a),w=c(s),O=l;(r&&O(new r(new ArrayBuffer(1)))!=m||i&&O(new i)!=u||o&&O(o.resolve())!=h||a&&O(new a)!=p||s&&O(new s)!=f)&&(O=function(e){var t=l(e),n=t==d?e.constructor:void 0,r=n?c(n):"";if(r)switch(r){case g:return m;case v:return u;case b:return h;case y:return p;case w:return f}return t}),e.exports=O},20155:function(e){function t(e,t){return null==e?void 0:e[t]}e.exports=t},85899:function(e,t,n){var r=n(93526),i=n(3283),o=n(53142),a=n(69632),s=n(65387),l=n(66040);function c(e,t,n){t=r(t,e);var c=-1,u=t.length,d=!1;while(++c<u){var h=l(t[c]);if(!(d=null!=e&&n(e,h)))break;e=e[h]}return d||++c!=u?d:(u=null==e?0:e.length,!!u&&s(u)&&a(h,u)&&(o(e)||i(e)))}e.exports=c},83417:function(e){var t="\\ud800-\\udfff",n="\\u0300-\\u036f",r="\\ufe20-\\ufe2f",i="\\u20d0-\\u20ff",o=n+r+i,a="\\ufe0e\\ufe0f",s="\\u200d",l=RegExp("["+s+t+o+a+"]");function c(e){return l.test(e)}e.exports=c},15813:function(e){var t=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function n(e){return t.test(e)}e.exports=n},23305:function(e,t,n){var r=n(94497);function i(){this.__data__=r?r(null):{},this.size=0}e.exports=i},39361:function(e){function t(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}e.exports=t},11112:function(e,t,n){var r=n(94497),i="__lodash_hash_undefined__",o=Object.prototype,a=o.hasOwnProperty;function s(e){var t=this.__data__;if(r){var n=t[e];return n===i?void 0:n}return a.call(t,e)?t[e]:void 0}e.exports=s},25276:function(e,t,n){var r=n(94497),i=Object.prototype,o=i.hasOwnProperty;function a(e){var t=this.__data__;return r?void 0!==t[e]:o.call(t,e)}e.exports=a},57452:function(e,t,n){var r=n(94497),i="__lodash_hash_undefined__";function o(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=r&&void 0===t?i:t,this}e.exports=o},97350:function(e){var t=Object.prototype,n=t.hasOwnProperty;function r(e){var t=e.length,r=new e.constructor(t);return t&&"string"==typeof e[0]&&n.call(e,"index")&&(r.index=e.index,r.input=e.input),r}e.exports=r},50424:function(e,t,n){var r=n(58898),i=n(92480),o=n(78340),a=n(18069),s=n(92264),l="[object Boolean]",c="[object Date]",u="[object Map]",d="[object Number]",h="[object RegExp]",p="[object Set]",f="[object String]",m="[object Symbol]",g="[object ArrayBuffer]",v="[object DataView]",b="[object Float32Array]",y="[object Float64Array]",w="[object Int8Array]",O="[object Int16Array]",S="[object Int32Array]",E="[object Uint8Array]",x="[object Uint8ClampedArray]",_="[object Uint16Array]",k="[object Uint32Array]";function C(e,t,n){var C=e.constructor;switch(t){case g:return r(e);case l:case c:return new C(+e);case v:return i(e,n);case b:case y:case w:case O:case S:case E:case x:case _:case k:return s(e,n);case u:return new C;case d:case f:return new C(e);case h:return o(e);case p:return new C;case m:return a(e)}}e.exports=C},75964:function(e,t,n){var r=n(39747),i=n(74784),o=n(84882);function a(e){return"function"!=typeof e.constructor||o(e)?{}:r(i(e))}e.exports=a},20714:function(e,t,n){var r=n(65650),i=n(3283),o=n(53142),a=r?r.isConcatSpreadable:void 0;function s(e){return o(e)||i(e)||!!(a&&e&&e[a])}e.exports=s},69632:function(e){var t=9007199254740991,n=/^(?:0|[1-9]\d*)$/;function r(e,r){var i=typeof e;return r=null==r?t:r,!!r&&("number"==i||"symbol"!=i&&n.test(e))&&e>-1&&e%1==0&&e<r}e.exports=r},74535:function(e,t,n){var r=n(46285),i=n(36529),o=n(69632),a=n(41580);function s(e,t,n){if(!a(n))return!1;var s=typeof t;return!!("number"==s?i(n)&&o(t,n.length):"string"==s&&t in n)&&r(n[t],e)}e.exports=s},65187:function(e,t,n){var r=n(53142),i=n(51187),o=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,a=/^\w*$/;function s(e,t){if(r(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!i(e))||(a.test(e)||!o.test(e)||null!=t&&e in Object(t))}e.exports=s},79067:function(e){function t(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}e.exports=t},64759:function(e,t,n){var r=n(41950),i=function(){var e=/[^.]+$/.exec(r&&r.keys&&r.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function o(e){return!!i&&i in e}e.exports=o},84882:function(e){var t=Object.prototype;function n(e){var n=e&&e.constructor,r="function"==typeof n&&n.prototype||t;return e===r}e.exports=n},67267:function(e,t,n){var r=n(41580);function i(e){return e===e&&!r(e)}e.exports=i},12393:function(e){function t(){this.__data__=[],this.size=0}e.exports=t},62049:function(e,t,n){var r=n(97034),i=Array.prototype,o=i.splice;function a(e){var t=this.__data__,n=r(t,e);if(n<0)return!1;var i=t.length-1;return n==i?t.pop():o.call(t,n,1),--this.size,!0}e.exports=a},7144:function(e,t,n){var r=n(97034);function i(e){var t=this.__data__,n=r(t,e);return n<0?void 0:t[n][1]}e.exports=i},7452:function(e,t,n){var r=n(97034);function i(e){return r(this.__data__,e)>-1}e.exports=i},13964:function(e,t,n){var r=n(97034);function i(e,t){var n=this.__data__,i=r(n,e);return i<0?(++this.size,n.push([e,t])):n[i][1]=t,this}e.exports=i},49753:function(e,t,n){var r=n(25098),i=n(1386),o=n(19770);function a(){this.size=0,this.__data__={hash:new r,map:new(o||i),string:new r}}e.exports=a},5681:function(e,t,n){var r=n(44700);function i(e){var t=r(this,e)["delete"](e);return this.size-=t?1:0,t}e.exports=i},80088:function(e,t,n){var r=n(44700);function i(e){return r(this,e).get(e)}e.exports=i},54732:function(e,t,n){var r=n(44700);function i(e){return r(this,e).has(e)}e.exports=i},59068:function(e,t,n){var r=n(44700);function i(e,t){var n=r(this,e),i=n.size;return n.set(e,t),this.size+=n.size==i?0:1,this}e.exports=i},95894:function(e){function t(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}e.exports=t},23904:function(e){function t(e,t){return function(n){return null!=n&&(n[e]===t&&(void 0!==t||e in Object(n)))}}e.exports=t},76853:function(e,t,n){var r=n(69011),i=500;function o(e){var t=r(e,function(e){return n.size===i&&n.clear(),e}),n=t.cache;return t}e.exports=o},94497:function(e,t,n){var r=n(94715),i=r(Object,"create");e.exports=i},98121:function(e,t,n){var r=n(3766),i=r(Object.keys,Object);e.exports=i},38546:function(e){function t(e){var t=[];if(null!=e)for(var n in Object(e))t.push(n);return t}e.exports=t},2306:function(e,t,n){e=n.nmd(e);var r=n(74967),i=t&&!t.nodeType&&t,o=i&&e&&!e.nodeType&&e,a=o&&o.exports===i,s=a&&r.process,l=function(){try{var e=o&&o.require&&o.require("util").types;return e||s&&s.binding&&s.binding("util")}catch(t){}}();e.exports=l},29005:function(e){var t=Object.prototype,n=t.toString;function r(e){return n.call(e)}e.exports=r},3766:function(e){function t(e,t){return function(n){return e(t(n))}}e.exports=t},75234:function(e,t,n){var r=n(86912),i=Math.max;function o(e,t,n){return t=i(void 0===t?e.length-1:t,0),function(){var o=arguments,a=-1,s=i(o.length-t,0),l=Array(s);while(++a<s)l[a]=o[t+a];a=-1;var c=Array(t+1);while(++a<t)c[a]=o[a];return c[t]=n(l),r(e,this,c)}}e.exports=o},78942:function(e,t,n){var r=n(74967),i="object"==typeof self&&self&&self.Object===Object&&self,o=r||i||Function("return this")();e.exports=o},78763:function(e){function t(e,t){if(("constructor"!==t||"function"!==typeof e[t])&&"__proto__"!=t)return e[t]}e.exports=t},1877:function(e){var t="__lodash_hash_undefined__";function n(e){return this.__data__.set(e,t),this}e.exports=n},8006:function(e){function t(e){return this.__data__.has(e)}e.exports=t},49828:function(e){function t(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}e.exports=t},80796:function(e,t,n){var r=n(47403),i=n(3316),o=i(r);e.exports=o},3316:function(e){var t=800,n=16,r=Date.now;function i(e){var i=0,o=0;return function(){var a=r(),s=n-(a-o);if(o=a,s>0){if(++i>=t)return arguments[0]}else i=0;return e.apply(void 0,arguments)}}e.exports=i},64103:function(e,t,n){var r=n(1386);function i(){this.__data__=new r,this.size=0}e.exports=i},21779:function(e){function t(e){var t=this.__data__,n=t["delete"](e);return this.size=t.size,n}e.exports=t},34162:function(e){function t(e){return this.__data__.get(e)}e.exports=t},7462:function(e){function t(e){return this.__data__.has(e)}e.exports=t},96638:function(e,t,n){var r=n(1386),i=n(19770),o=n(68250),a=200;function s(e,t){var n=this.__data__;if(n instanceof r){var s=n.__data__;if(!i||s.length<a-1)return s.push([e,t]),this.size=++n.size,this;n=this.__data__=new o(s)}return n.set(e,t),this.size=n.size,this}e.exports=s},97706:function(e){function t(e,t,n){var r=n-1,i=e.length;while(++r<i)if(e[r]===t)return r;return-1}e.exports=t},82237:function(e,t,n){var r=n(52837),i=n(83417),o=n(92013);function a(e){return i(e)?o(e):r(e)}e.exports=a},96493:function(e,t,n){var r=n(76853),i=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,o=/\\(\\)?/g,a=r(function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(i,function(e,n,r,i){t.push(r?i.replace(o,"$1"):n||e)}),t});e.exports=a},66040:function(e,t,n){var r=n(51187),i=1/0;function o(e){if("string"==typeof e||r(e))return e;var t=e+"";return"0"==t&&1/e==-i?"-0":t}e.exports=o},64066:function(e){var t=Function.prototype,n=t.toString;function r(e){if(null!=e){try{return n.call(e)}catch(t){}try{return e+""}catch(t){}}return""}e.exports=r},62945:function(e){var t=/\s/;function n(e){var n=e.length;while(n--&&t.test(e.charAt(n)));return n}e.exports=n},92013:function(e){var t="\\ud800-\\udfff",n="\\u0300-\\u036f",r="\\ufe20-\\ufe2f",i="\\u20d0-\\u20ff",o=n+r+i,a="\\ufe0e\\ufe0f",s="["+t+"]",l="["+o+"]",c="\\ud83c[\\udffb-\\udfff]",u="(?:"+l+"|"+c+")",d="[^"+t+"]",h="(?:\\ud83c[\\udde6-\\uddff]){2}",p="[\\ud800-\\udbff][\\udc00-\\udfff]",f="\\u200d",m=u+"?",g="["+a+"]?",v="(?:"+f+"(?:"+[d,h,p].join("|")+")"+g+m+")*",b=g+m+v,y="(?:"+[d+l+"?",l,h,p,s].join("|")+")",w=RegExp(c+"(?="+c+")|"+y+b,"g");function O(e){return e.match(w)||[]}e.exports=O},10482:function(e){var t="\\ud800-\\udfff",n="\\u0300-\\u036f",r="\\ufe20-\\ufe2f",i="\\u20d0-\\u20ff",o=n+r+i,a="\\u2700-\\u27bf",s="a-z\\xdf-\\xf6\\xf8-\\xff",l="\\xac\\xb1\\xd7\\xf7",c="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",u="\\u2000-\\u206f",d=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",h="A-Z\\xc0-\\xd6\\xd8-\\xde",p="\\ufe0e\\ufe0f",f=l+c+u+d,m="['’]",g="["+f+"]",v="["+o+"]",b="\\d+",y="["+a+"]",w="["+s+"]",O="[^"+t+f+b+a+s+h+"]",S="\\ud83c[\\udffb-\\udfff]",E="(?:"+v+"|"+S+")",x="[^"+t+"]",_="(?:\\ud83c[\\udde6-\\uddff]){2}",k="[\\ud800-\\udbff][\\udc00-\\udfff]",C="["+h+"]",A="\\u200d",T="(?:"+w+"|"+O+")",R="(?:"+C+"|"+O+")",N="(?:"+m+"(?:d|ll|m|re|s|t|ve))?",P="(?:"+m+"(?:D|LL|M|RE|S|T|VE))?",I=E+"?",M="["+p+"]?",D="(?:"+A+"(?:"+[x,_,k].join("|")+")"+M+I+")*",L="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",B="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",$=M+I+D,V="(?:"+[y,_,k].join("|")+")"+$,F=RegExp([C+"?"+w+"+"+N+"(?="+[g,C,"$"].join("|")+")",R+"+"+P+"(?="+[g,C+T,"$"].join("|")+")",C+"?"+T+"+"+N,C+"+"+P,B,L,b,V].join("|"),"g");function j(e){return e.match(F)||[]}e.exports=j},56005:function(e,t,n){var r=n(95243),i=n(5485);function o(e){return i(r(e).toLowerCase())}e.exports=o},46108:function(e,t,n){var r=n(69334),i=1,o=4;function a(e){return r(e,i|o)}e.exports=a},16238:function(e){function t(e){var t=-1,n=null==e?0:e.length,r=0,i=[];while(++t<n){var o=e[t];o&&(i[r++]=o)}return i}e.exports=t},82619:function(e){function t(e){return function(){return e}}e.exports=t},12784:function(e,t,n){var r=n(41580),i=n(94495),o=n(6131),a="Expected a function",s=Math.max,l=Math.min;function c(e,t,n){var c,u,d,h,p,f,m=0,g=!1,v=!1,b=!0;if("function"!=typeof e)throw new TypeError(a);function y(t){var n=c,r=u;return c=u=void 0,m=t,h=e.apply(r,n),h}function w(e){return m=e,p=setTimeout(E,t),g?y(e):h}function O(e){var n=e-f,r=e-m,i=t-n;return v?l(i,d-r):i}function S(e){var n=e-f,r=e-m;return void 0===f||n>=t||n<0||v&&r>=d}function E(){var e=i();if(S(e))return x(e);p=setTimeout(E,O(e))}function x(e){return p=void 0,b&&c?y(e):(c=u=void 0,h)}function _(){void 0!==p&&clearTimeout(p),m=0,c=f=u=p=void 0}function k(){return void 0===p?h:x(i())}function C(){var e=i(),n=S(e);if(c=arguments,u=this,f=e,n){if(void 0===p)return w(f);if(v)return clearTimeout(p),p=setTimeout(E,t),y(f)}return void 0===p&&(p=setTimeout(E,t)),h}return t=o(t)||0,r(n)&&(g=!!n.leading,v="maxWait"in n,d=v?s(o(n.maxWait)||0,t):d,b="trailing"in n?!!n.trailing:b),C.cancel=_,C.flush=k,C}e.exports=c},45881:function(e,t,n){var r=n(69968),i=n(95243),o=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,a="\\u0300-\\u036f",s="\\ufe20-\\ufe2f",l="\\u20d0-\\u20ff",c=a+s+l,u="["+c+"]",d=RegExp(u,"g");function h(e){return e=i(e),e&&e.replace(o,r).replace(d,"")}e.exports=h},88088:function(e,t,n){var r=n(96576),i=n(90313),o=n(23945),a=n(65406),s=o(function(e,t){return a(e)?r(e,i(t,1,a,!0)):[]});e.exports=s},46285:function(e){function t(e,t){return e===t||e!==e&&t!==t}e.exports=t},81936:function(e,t,n){var r=n(77317),i=n(92154),o=r(i);e.exports=o},92154:function(e,t,n){var r=n(37250),i=n(3334),o=n(67642),a=Math.max;function s(e,t,n){var s=null==e?0:e.length;if(!s)return-1;var l=null==n?0:o(n);return l<0&&(l=a(s+l,0)),r(e,i(t,3),l)}e.exports=s},24576:function(e,t,n){var r=n(77317),i=n(40458),o=r(i);e.exports=o},40458:function(e,t,n){var r=n(37250),i=n(3334),o=n(67642),a=Math.max,s=Math.min;function l(e,t,n){var l=null==e?0:e.length;if(!l)return-1;var c=l-1;return void 0!==n&&(c=o(n),c=n<0?a(l+c,0):s(c,l-1)),r(e,i(t,3),c,!0)}e.exports=l},75857:function(e,t,n){var r=n(90313);function i(e){var t=null==e?0:e.length;return t?r(e,1):[]}e.exports=i},53435:function(e,t,n){var r=n(90313),i=1/0;function o(e){var t=null==e?0:e.length;return t?r(e,i):[]}e.exports=o},68371:function(e,t,n){var r=n(35636),i=n(23997),o=n(25288);function a(e,t){return null==e?e:r(e,i(t),o)}e.exports=a},46123:function(e,t,n){var r=n(57923);function i(e,t,n){var i=null==e?void 0:r(e,t);return void 0===i?n:i}e.exports=i},52103:function(e,t,n){var r=n(63599),i=n(85899);function o(e,t){return null!=e&&i(e,t,r)}e.exports=o},27276:function(e,t,n){var r=n(43636),i=n(85899);function o(e,t){return null!=e&&i(e,t,r)}e.exports=o},13981:function(e){function t(e){return e&&e.length?e[0]:void 0}e.exports=t},22053:function(e){function t(e){return e}e.exports=t},87526:function(e,t,n){var r=n(2478),i=n(36529),o=n(8138),a=n(67642),s=n(39817),l=Math.max;function c(e,t,n,c){e=i(e)?e:s(e),n=n&&!c?a(n):0;var u=e.length;return n<0&&(n=l(u+n,0)),o(e)?n<=u&&e.indexOf(t,n)>-1:!!u&&r(e,t,n)>-1}e.exports=c},3283:function(e,t,n){var r=n(56027),i=n(80547),o=Object.prototype,a=o.hasOwnProperty,s=o.propertyIsEnumerable,l=r(function(){return arguments}())?r:function(e){return i(e)&&a.call(e,"callee")&&!s.call(e,"callee")};e.exports=l},53142:function(e){var t=Array.isArray;e.exports=t},36529:function(e,t,n){var r=n(93655),i=n(65387);function o(e){return null!=e&&i(e.length)&&!r(e)}e.exports=o},65406:function(e,t,n){var r=n(36529),i=n(80547);function o(e){return i(e)&&r(e)}e.exports=o},75853:function(e,t,n){e=n.nmd(e);var r=n(78942),i=n(34772),o=t&&!t.nodeType&&t,a=o&&e&&!e.nodeType&&e,s=a&&a.exports===o,l=s?r.Buffer:void 0,c=l?l.isBuffer:void 0,u=c||i;e.exports=u},3514:function(e,t,n){var r=n(195),i=n(28486),o=n(3283),a=n(53142),s=n(36529),l=n(75853),c=n(84882),u=n(8666),d="[object Map]",h="[object Set]",p=Object.prototype,f=p.hasOwnProperty;function m(e){if(null==e)return!0;if(s(e)&&(a(e)||"string"==typeof e||"function"==typeof e.splice||l(e)||u(e)||o(e)))return!e.length;var t=i(e);if(t==d||t==h)return!e.size;if(c(e))return!r(e).length;for(var n in e)if(f.call(e,n))return!1;return!0}e.exports=m},46343:function(e,t,n){var r=n(94687);function i(e,t){return r(e,t)}e.exports=i},93655:function(e,t,n){var r=n(87379),i=n(41580),o="[object AsyncFunction]",a="[object Function]",s="[object GeneratorFunction]",l="[object Proxy]";function c(e){if(!i(e))return!1;var t=r(e);return t==a||t==s||t==o||t==l}e.exports=c},65387:function(e){var t=9007199254740991;function n(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=t}e.exports=n},37681:function(e,t,n){var r=n(80777),i=n(49460),o=n(2306),a=o&&o.isMap,s=a?i(a):r;e.exports=s},41580:function(e){function t(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}e.exports=t},80547:function(e){function t(e){return null!=e&&"object"==typeof e}e.exports=t},48360:function(e,t,n){var r=n(87379),i=n(74784),o=n(80547),a="[object Object]",s=Function.prototype,l=Object.prototype,c=s.toString,u=l.hasOwnProperty,d=c.call(Object);function h(e){if(!o(e)||r(e)!=a)return!1;var t=i(e);if(null===t)return!0;var n=u.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&c.call(n)==d}e.exports=h},83943:function(e,t,n){var r=n(81935),i=n(49460),o=n(2306),a=o&&o.isSet,s=a?i(a):r;e.exports=s},8138:function(e,t,n){var r=n(87379),i=n(53142),o=n(80547),a="[object String]";function s(e){return"string"==typeof e||!i(e)&&o(e)&&r(e)==a}e.exports=s},51187:function(e,t,n){var r=n(87379),i=n(80547),o="[object Symbol]";function a(e){return"symbol"==typeof e||i(e)&&r(e)==o}e.exports=a},8666:function(e,t,n){var r=n(70674),i=n(49460),o=n(2306),a=o&&o.isTypedArray,s=a?i(a):r;e.exports=s},81211:function(e,t,n){var r=n(10358),i=n(195),o=n(36529);function a(e){return o(e)?r(e):i(e)}e.exports=a},25288:function(e,t,n){var r=n(10358),i=n(57200),o=n(36529);function a(e){return o(e)?r(e,!0):i(e)}e.exports=a},45250:function(e,t,n){var r;
|
||
/**
|
||
* @license
|
||
* Lodash <https://lodash.com/>
|
||
* Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
|
||
* Released under MIT license <https://lodash.com/license>
|
||
* Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
|
||
* Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
|
||
*/e=n.nmd(e),function(){var i,o="4.18.1",a=200,s="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",l="Expected a function",c="Invalid `variable` option passed into `_.template`",u="Invalid `imports` option passed into `_.template`",d="__lodash_hash_undefined__",h=500,p="__lodash_placeholder__",f=1,m=2,g=4,v=1,b=2,y=1,w=2,O=4,S=8,E=16,x=32,_=64,k=128,C=256,A=512,T=30,R="...",N=800,P=16,I=1,M=2,D=3,L=1/0,B=9007199254740991,$=17976931348623157e292,V=NaN,F=4294967295,j=F-1,U=F>>>1,G=[["ary",k],["bind",y],["bindKey",w],["curry",S],["curryRight",E],["flip",A],["partial",x],["partialRight",_],["rearg",C]],H="[object Arguments]",q="[object Array]",Q="[object AsyncFunction]",z="[object Boolean]",K="[object Date]",W="[object DOMException]",X="[object Error]",Y="[object Function]",Z="[object GeneratorFunction]",J="[object Map]",ee="[object Number]",te="[object Null]",ne="[object Object]",re="[object Promise]",ie="[object Proxy]",oe="[object RegExp]",ae="[object Set]",se="[object String]",le="[object Symbol]",ce="[object Undefined]",ue="[object WeakMap]",de="[object WeakSet]",he="[object ArrayBuffer]",pe="[object DataView]",fe="[object Float32Array]",me="[object Float64Array]",ge="[object Int8Array]",ve="[object Int16Array]",be="[object Int32Array]",ye="[object Uint8Array]",we="[object Uint8ClampedArray]",Oe="[object Uint16Array]",Se="[object Uint32Array]",Ee=/\b__p \+= '';/g,xe=/\b(__p \+=) '' \+/g,_e=/(__e\(.*?\)|\b__t\)) \+\n'';/g,ke=/&(?:amp|lt|gt|quot|#39);/g,Ce=/[&<>"']/g,Ae=RegExp(ke.source),Te=RegExp(Ce.source),Re=/<%-([\s\S]+?)%>/g,Ne=/<%([\s\S]+?)%>/g,Pe=/<%=([\s\S]+?)%>/g,Ie=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Me=/^\w*$/,De=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Le=/[\\^$.*+?()[\]{}|]/g,Be=RegExp(Le.source),$e=/^\s+/,Ve=/\s/,Fe=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,je=/\{\n\/\* \[wrapped with (.+)\] \*/,Ue=/,? & /,Ge=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,He=/[()=,{}\[\]\/\s]/,qe=/\\(\\)?/g,Qe=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,ze=/\w*$/,Ke=/^[-+]0x[0-9a-f]+$/i,We=/^0b[01]+$/i,Xe=/^\[object .+?Constructor\]$/,Ye=/^0o[0-7]+$/i,Ze=/^(?:0|[1-9]\d*)$/,Je=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,et=/($^)/,tt=/['\n\r\u2028\u2029\\]/g,nt="\\ud800-\\udfff",rt="\\u0300-\\u036f",it="\\ufe20-\\ufe2f",ot="\\u20d0-\\u20ff",at=rt+it+ot,st="\\u2700-\\u27bf",lt="a-z\\xdf-\\xf6\\xf8-\\xff",ct="\\xac\\xb1\\xd7\\xf7",ut="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",dt="\\u2000-\\u206f",ht=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",pt="A-Z\\xc0-\\xd6\\xd8-\\xde",ft="\\ufe0e\\ufe0f",mt=ct+ut+dt+ht,gt="['’]",vt="["+nt+"]",bt="["+mt+"]",yt="["+at+"]",wt="\\d+",Ot="["+st+"]",St="["+lt+"]",Et="[^"+nt+mt+wt+st+lt+pt+"]",xt="\\ud83c[\\udffb-\\udfff]",_t="(?:"+yt+"|"+xt+")",kt="[^"+nt+"]",Ct="(?:\\ud83c[\\udde6-\\uddff]){2}",At="[\\ud800-\\udbff][\\udc00-\\udfff]",Tt="["+pt+"]",Rt="\\u200d",Nt="(?:"+St+"|"+Et+")",Pt="(?:"+Tt+"|"+Et+")",It="(?:"+gt+"(?:d|ll|m|re|s|t|ve))?",Mt="(?:"+gt+"(?:D|LL|M|RE|S|T|VE))?",Dt=_t+"?",Lt="["+ft+"]?",Bt="(?:"+Rt+"(?:"+[kt,Ct,At].join("|")+")"+Lt+Dt+")*",$t="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Vt="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",Ft=Lt+Dt+Bt,jt="(?:"+[Ot,Ct,At].join("|")+")"+Ft,Ut="(?:"+[kt+yt+"?",yt,Ct,At,vt].join("|")+")",Gt=RegExp(gt,"g"),Ht=RegExp(yt,"g"),qt=RegExp(xt+"(?="+xt+")|"+Ut+Ft,"g"),Qt=RegExp([Tt+"?"+St+"+"+It+"(?="+[bt,Tt,"$"].join("|")+")",Pt+"+"+Mt+"(?="+[bt,Tt+Nt,"$"].join("|")+")",Tt+"?"+Nt+"+"+It,Tt+"+"+Mt,Vt,$t,wt,jt].join("|"),"g"),zt=RegExp("["+Rt+nt+at+ft+"]"),Kt=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Wt=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],Xt=-1,Yt={};Yt[fe]=Yt[me]=Yt[ge]=Yt[ve]=Yt[be]=Yt[ye]=Yt[we]=Yt[Oe]=Yt[Se]=!0,Yt[H]=Yt[q]=Yt[he]=Yt[z]=Yt[pe]=Yt[K]=Yt[X]=Yt[Y]=Yt[J]=Yt[ee]=Yt[ne]=Yt[oe]=Yt[ae]=Yt[se]=Yt[ue]=!1;var Zt={};Zt[H]=Zt[q]=Zt[he]=Zt[pe]=Zt[z]=Zt[K]=Zt[fe]=Zt[me]=Zt[ge]=Zt[ve]=Zt[be]=Zt[J]=Zt[ee]=Zt[ne]=Zt[oe]=Zt[ae]=Zt[se]=Zt[le]=Zt[ye]=Zt[we]=Zt[Oe]=Zt[Se]=!0,Zt[X]=Zt[Y]=Zt[ue]=!1;var Jt={"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"},en={"&":"&","<":"<",">":">",'"':""","'":"'"},tn={"&":"&","<":"<",">":">",""":'"',"'":"'"},nn={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},rn=parseFloat,on=parseInt,an="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g,sn="object"==typeof self&&self&&self.Object===Object&&self,ln=an||sn||Function("return this")(),cn=t&&!t.nodeType&&t,un=cn&&e&&!e.nodeType&&e,dn=un&&un.exports===cn,hn=dn&&an.process,pn=function(){try{var e=un&&un.require&&un.require("util").types;return e||hn&&hn.binding&&hn.binding("util")}catch(t){}}(),fn=pn&&pn.isArrayBuffer,mn=pn&&pn.isDate,gn=pn&&pn.isMap,vn=pn&&pn.isRegExp,bn=pn&&pn.isSet,yn=pn&&pn.isTypedArray;function wn(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function On(e,t,n,r){var i=-1,o=null==e?0:e.length;while(++i<o){var a=e[i];t(r,a,n(a),e)}return r}function Sn(e,t){var n=-1,r=null==e?0:e.length;while(++n<r)if(!1===t(e[n],n,e))break;return e}function En(e,t){var n=null==e?0:e.length;while(n--)if(!1===t(e[n],n,e))break;return e}function xn(e,t){var n=-1,r=null==e?0:e.length;while(++n<r)if(!t(e[n],n,e))return!1;return!0}function _n(e,t){var n=-1,r=null==e?0:e.length,i=0,o=[];while(++n<r){var a=e[n];t(a,n,e)&&(o[i++]=a)}return o}function kn(e,t){var n=null==e?0:e.length;return!!n&&$n(e,t,0)>-1}function Cn(e,t,n){var r=-1,i=null==e?0:e.length;while(++r<i)if(n(t,e[r]))return!0;return!1}function An(e,t){var n=-1,r=null==e?0:e.length,i=Array(r);while(++n<r)i[n]=t(e[n],n,e);return i}function Tn(e,t){var n=-1,r=t.length,i=e.length;while(++n<r)e[i+n]=t[n];return e}function Rn(e,t,n,r){var i=-1,o=null==e?0:e.length;r&&o&&(n=e[++i]);while(++i<o)n=t(n,e[i],i,e);return n}function Nn(e,t,n,r){var i=null==e?0:e.length;r&&i&&(n=e[--i]);while(i--)n=t(n,e[i],i,e);return n}function Pn(e,t){var n=-1,r=null==e?0:e.length;while(++n<r)if(t(e[n],n,e))return!0;return!1}var In=Un("length");function Mn(e){return e.split("")}function Dn(e){return e.match(Ge)||[]}function Ln(e,t,n){var r;return n(e,function(e,n,i){if(t(e,n,i))return r=n,!1}),r}function Bn(e,t,n,r){var i=e.length,o=n+(r?1:-1);while(r?o--:++o<i)if(t(e[o],o,e))return o;return-1}function $n(e,t,n){return t===t?fr(e,t,n):Bn(e,Fn,n)}function Vn(e,t,n,r){var i=n-1,o=e.length;while(++i<o)if(r(e[i],t))return i;return-1}function Fn(e){return e!==e}function jn(e,t){var n=null==e?0:e.length;return n?Qn(e,t)/n:V}function Un(e){return function(t){return null==t?i:t[e]}}function Gn(e){return function(t){return null==e?i:e[t]}}function Hn(e,t,n,r,i){return i(e,function(e,i,o){n=r?(r=!1,e):t(n,e,i,o)}),n}function qn(e,t){var n=e.length;e.sort(t);while(n--)e[n]=e[n].value;return e}function Qn(e,t){var n,r=-1,o=e.length;while(++r<o){var a=t(e[r]);a!==i&&(n=n===i?a:n+a)}return n}function zn(e,t){var n=-1,r=Array(e);while(++n<e)r[n]=t(n);return r}function Kn(e,t){return An(t,function(t){return[t,e[t]]})}function Wn(e){return e?e.slice(0,br(e)+1).replace($e,""):e}function Xn(e){return function(t){return e(t)}}function Yn(e,t){return An(t,function(t){return e[t]})}function Zn(e,t){return e.has(t)}function Jn(e,t){var n=-1,r=e.length;while(++n<r&&$n(t,e[n],0)>-1);return n}function er(e,t){var n=e.length;while(n--&&$n(t,e[n],0)>-1);return n}function tr(e,t){var n=e.length,r=0;while(n--)e[n]===t&&++r;return r}var nr=Gn(Jt),rr=Gn(en);function ir(e){return"\\"+nn[e]}function or(e,t){return null==e?i:e[t]}function ar(e){return zt.test(e)}function sr(e){return Kt.test(e)}function lr(e){var t,n=[];while(!(t=e.next()).done)n.push(t.value);return n}function cr(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}function ur(e,t){return function(n){return e(t(n))}}function dr(e,t){var n=-1,r=e.length,i=0,o=[];while(++n<r){var a=e[n];a!==t&&a!==p||(e[n]=p,o[i++]=n)}return o}function hr(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}function pr(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=[e,e]}),n}function fr(e,t,n){var r=n-1,i=e.length;while(++r<i)if(e[r]===t)return r;return-1}function mr(e,t,n){var r=n+1;while(r--)if(e[r]===t)return r;return r}function gr(e){return ar(e)?wr(e):In(e)}function vr(e){return ar(e)?Or(e):Mn(e)}function br(e){var t=e.length;while(t--&&Ve.test(e.charAt(t)));return t}var yr=Gn(tn);function wr(e){var t=qt.lastIndex=0;while(qt.test(e))++t;return t}function Or(e){return e.match(qt)||[]}function Sr(e){return e.match(Qt)||[]}var Er=function e(t){t=null==t?ln:xr.defaults(ln.Object(),t,xr.pick(ln,Wt));var n=t.Array,r=t.Date,Ve=t.Error,Ge=t.Function,nt=t.Math,rt=t.Object,it=t.RegExp,ot=t.String,at=t.TypeError,st=n.prototype,lt=Ge.prototype,ct=rt.prototype,ut=t["__core-js_shared__"],dt=lt.toString,ht=ct.hasOwnProperty,pt=0,ft=function(){var e=/[^.]+$/.exec(ut&&ut.keys&&ut.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}(),mt=ct.toString,gt=dt.call(rt),vt=ln._,bt=it("^"+dt.call(ht).replace(Le,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),yt=dn?t.Buffer:i,wt=t.Symbol,Ot=t.Uint8Array,St=yt?yt.allocUnsafe:i,Et=ur(rt.getPrototypeOf,rt),xt=rt.create,_t=ct.propertyIsEnumerable,kt=st.splice,Ct=wt?wt.isConcatSpreadable:i,At=wt?wt.iterator:i,Tt=wt?wt.toStringTag:i,Rt=function(){try{var e=Ka(rt,"defineProperty");return e({},"",{}),e}catch(t){}}(),Nt=t.clearTimeout!==ln.clearTimeout&&t.clearTimeout,Pt=r&&r.now!==ln.Date.now&&r.now,It=t.setTimeout!==ln.setTimeout&&t.setTimeout,Mt=nt.ceil,Dt=nt.floor,Lt=rt.getOwnPropertySymbols,Bt=yt?yt.isBuffer:i,$t=t.isFinite,Vt=st.join,Ft=ur(rt.keys,rt),jt=nt.max,Ut=nt.min,qt=r.now,Qt=t.parseInt,zt=nt.random,Kt=st.reverse,Jt=Ka(t,"DataView"),en=Ka(t,"Map"),tn=Ka(t,"Promise"),nn=Ka(t,"Set"),an=Ka(t,"WeakMap"),sn=Ka(rt,"create"),cn=an&&new an,un={},hn=Is(Jt),pn=Is(en),In=Is(tn),Mn=Is(nn),Gn=Is(an),fr=wt?wt.prototype:i,wr=fr?fr.valueOf:i,Or=fr?fr.toString:i;function Er(e){if(ku(e)&&!cu(e)&&!(e instanceof Ar)){if(e instanceof Cr)return e;if(ht.call(e,"__wrapped__"))return Ds(e)}return new Cr(e)}var _r=function(){function e(){}return function(t){if(!_u(t))return{};if(xt)return xt(t);e.prototype=t;var n=new e;return e.prototype=i,n}}();function kr(){}function Cr(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=i}function Ar(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=F,this.__views__=[]}function Tr(){var e=new Ar(this.__wrapped__);return e.__actions__=oa(this.__actions__),e.__dir__=this.__dir__,e.__filtered__=this.__filtered__,e.__iteratees__=oa(this.__iteratees__),e.__takeCount__=this.__takeCount__,e.__views__=oa(this.__views__),e}function Rr(){if(this.__filtered__){var e=new Ar(this);e.__dir__=-1,e.__filtered__=!0}else e=this.clone(),e.__dir__*=-1;return e}function Nr(){var e=this.__wrapped__.value(),t=this.__dir__,n=cu(e),r=t<0,i=n?e.length:0,o=Ja(0,i,this.__views__),a=o.start,s=o.end,l=s-a,c=r?s:a-1,u=this.__iteratees__,d=u.length,h=0,p=Ut(l,this.__takeCount__);if(!n||!r&&i==l&&p==l)return Fo(e,this.__actions__);var f=[];e:while(l--&&h<p){c+=t;var m=-1,g=e[c];while(++m<d){var v=u[m],b=v.iteratee,y=v.type,w=b(g);if(y==M)g=w;else if(!w){if(y==I)continue e;break e}}f[h++]=g}return f}function Pr(e){var t=-1,n=null==e?0:e.length;this.clear();while(++t<n){var r=e[t];this.set(r[0],r[1])}}function Ir(){this.__data__=sn?sn(null):{},this.size=0}function Mr(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}function Dr(e){var t=this.__data__;if(sn){var n=t[e];return n===d?i:n}return ht.call(t,e)?t[e]:i}function Lr(e){var t=this.__data__;return sn?t[e]!==i:ht.call(t,e)}function Br(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=sn&&t===i?d:t,this}function $r(e){var t=-1,n=null==e?0:e.length;this.clear();while(++t<n){var r=e[t];this.set(r[0],r[1])}}function Vr(){this.__data__=[],this.size=0}function Fr(e){var t=this.__data__,n=di(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():kt.call(t,n,1),--this.size,!0}function jr(e){var t=this.__data__,n=di(t,e);return n<0?i:t[n][1]}function Ur(e){return di(this.__data__,e)>-1}function Gr(e,t){var n=this.__data__,r=di(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}function Hr(e){var t=-1,n=null==e?0:e.length;this.clear();while(++t<n){var r=e[t];this.set(r[0],r[1])}}function qr(){this.size=0,this.__data__={hash:new Pr,map:new(en||$r),string:new Pr}}function Qr(e){var t=Qa(this,e)["delete"](e);return this.size-=t?1:0,t}function zr(e){return Qa(this,e).get(e)}function Kr(e){return Qa(this,e).has(e)}function Wr(e,t){var n=Qa(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}function Xr(e){var t=-1,n=null==e?0:e.length;this.__data__=new Hr;while(++t<n)this.add(e[t])}function Yr(e){return this.__data__.set(e,d),this}function Zr(e){return this.__data__.has(e)}function Jr(e){var t=this.__data__=new $r(e);this.size=t.size}function ei(){this.__data__=new $r,this.size=0}function ti(e){var t=this.__data__,n=t["delete"](e);return this.size=t.size,n}function ni(e){return this.__data__.get(e)}function ri(e){return this.__data__.has(e)}function ii(e,t){var n=this.__data__;if(n instanceof $r){var r=n.__data__;if(!en||r.length<a-1)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new Hr(r)}return n.set(e,t),this.size=n.size,this}function oi(e,t){var n=cu(e),r=!n&&lu(e),i=!n&&!r&&fu(e),o=!n&&!r&&!i&&ju(e),a=n||r||i||o,s=a?zn(e.length,ot):[],l=s.length;for(var c in e)!t&&!ht.call(e,c)||a&&("length"==c||i&&("offset"==c||"parent"==c)||o&&("buffer"==c||"byteLength"==c||"byteOffset"==c)||ss(c,l))||s.push(c);return s}function ai(e){var t=e.length;return t?e[yo(0,t-1)]:i}function si(e,t){return Rs(oa(e),vi(t,0,e.length))}function li(e){return Rs(oa(e))}function ci(e,t,n){(n!==i&&!ou(e[t],n)||n===i&&!(t in e))&&mi(e,t,n)}function ui(e,t,n){var r=e[t];ht.call(e,t)&&ou(r,n)&&(n!==i||t in e)||mi(e,t,n)}function di(e,t){var n=e.length;while(n--)if(ou(e[n][0],t))return n;return-1}function hi(e,t,n,r){return Ei(e,function(e,i,o){t(r,e,n(e),o)}),r}function pi(e,t){return e&&aa(t,Ed(t),e)}function fi(e,t){return e&&aa(t,xd(t),e)}function mi(e,t,n){"__proto__"==t&&Rt?Rt(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}function gi(e,t){var r=-1,o=t.length,a=n(o),s=null==e;while(++r<o)a[r]=s?i:vd(e,t[r]);return a}function vi(e,t,n){return e===e&&(n!==i&&(e=e<=n?e:n),t!==i&&(e=e>=t?e:t)),e}function bi(e,t,n,r,o,a){var s,l=t&f,c=t&m,u=t&g;if(n&&(s=o?n(e,r,o,a):n(e)),s!==i)return s;if(!_u(e))return e;var d=cu(e);if(d){if(s=ns(e),!l)return oa(e,s)}else{var h=Za(e),p=h==Y||h==Z;if(fu(e))return Wo(e,l);if(h==ne||h==H||p&&!o){if(s=c||p?{}:rs(e),!l)return c?la(e,fi(s,e)):sa(e,pi(s,e))}else{if(!Zt[h])return o?e:{};s=is(e,h,l)}}a||(a=new Jr);var v=a.get(e);if(v)return v;a.set(e,s),$u(e)?e.forEach(function(r){s.add(bi(r,t,n,r,e,a))}):Cu(e)&&e.forEach(function(r,i){s.set(i,bi(r,t,n,i,e,a))});var b=u?c?ja:Fa:c?xd:Ed,y=d?i:b(e);return Sn(y||e,function(r,i){y&&(i=r,r=e[i]),ui(s,i,bi(r,t,n,i,e,a))}),s}function yi(e){var t=Ed(e);return function(n){return wi(n,e,t)}}function wi(e,t,n){var r=n.length;if(null==e)return!r;e=rt(e);while(r--){var o=n[r],a=t[o],s=e[o];if(s===i&&!(o in e)||!a(s))return!1}return!0}function Oi(e,t,n){if("function"!=typeof e)throw new at(l);return ks(function(){e.apply(i,n)},t)}function Si(e,t,n,r){var i=-1,o=kn,s=!0,l=e.length,c=[],u=t.length;if(!l)return c;n&&(t=An(t,Xn(n))),r?(o=Cn,s=!1):t.length>=a&&(o=Zn,s=!1,t=new Xr(t));e:while(++i<l){var d=e[i],h=null==n?d:n(d);if(d=r||0!==d?d:0,s&&h===h){var p=u;while(p--)if(t[p]===h)continue e;c.push(d)}else o(t,h,r)||c.push(d)}return c}Er.templateSettings={escape:Re,evaluate:Ne,interpolate:Pe,variable:"",imports:{_:Er}},Er.prototype=kr.prototype,Er.prototype.constructor=Er,Cr.prototype=_r(kr.prototype),Cr.prototype.constructor=Cr,Ar.prototype=_r(kr.prototype),Ar.prototype.constructor=Ar,Pr.prototype.clear=Ir,Pr.prototype["delete"]=Mr,Pr.prototype.get=Dr,Pr.prototype.has=Lr,Pr.prototype.set=Br,$r.prototype.clear=Vr,$r.prototype["delete"]=Fr,$r.prototype.get=jr,$r.prototype.has=Ur,$r.prototype.set=Gr,Hr.prototype.clear=qr,Hr.prototype["delete"]=Qr,Hr.prototype.get=zr,Hr.prototype.has=Kr,Hr.prototype.set=Wr,Xr.prototype.add=Xr.prototype.push=Yr,Xr.prototype.has=Zr,Jr.prototype.clear=ei,Jr.prototype["delete"]=ti,Jr.prototype.get=ni,Jr.prototype.has=ri,Jr.prototype.set=ii;var Ei=da(Pi),xi=da(Ii,!0);function _i(e,t){var n=!0;return Ei(e,function(e,r,i){return n=!!t(e,r,i),n}),n}function ki(e,t,n){var r=-1,o=e.length;while(++r<o){var a=e[r],s=t(a);if(null!=s&&(l===i?s===s&&!Fu(s):n(s,l)))var l=s,c=a}return c}function Ci(e,t,n,r){var o=e.length;n=Wu(n),n<0&&(n=-n>o?0:o+n),r=r===i||r>o?o:Wu(r),r<0&&(r+=o),r=n>r?0:Xu(r);while(n<r)e[n++]=t;return e}function Ai(e,t){var n=[];return Ei(e,function(e,r,i){t(e,r,i)&&n.push(e)}),n}function Ti(e,t,n,r,i){var o=-1,a=e.length;n||(n=as),i||(i=[]);while(++o<a){var s=e[o];t>0&&n(s)?t>1?Ti(s,t-1,n,r,i):Tn(i,s):r||(i[i.length]=s)}return i}var Ri=ha(),Ni=ha(!0);function Pi(e,t){return e&&Ri(e,t,Ed)}function Ii(e,t){return e&&Ni(e,t,Ed)}function Mi(e,t){return _n(t,function(t){return Su(e[t])})}function Di(e,t){t=qo(t,e);var n=0,r=t.length;while(null!=e&&n<r)e=e[Ps(t[n++])];return n&&n==r?e:i}function Li(e,t,n){var r=t(e);return cu(e)?r:Tn(r,n(e))}function Bi(e){return null==e?e===i?ce:te:Tt&&Tt in rt(e)?Wa(e):ws(e)}function $i(e,t){return e>t}function Vi(e,t){return null!=e&&ht.call(e,t)}function Fi(e,t){return null!=e&&t in rt(e)}function ji(e,t,n){return e>=Ut(t,n)&&e<jt(t,n)}function Ui(e,t,r){var o=r?Cn:kn,a=e[0].length,s=e.length,l=s,c=n(s),u=1/0,d=[];while(l--){var h=e[l];l&&t&&(h=An(h,Xn(t))),u=Ut(h.length,u),c[l]=!r&&(t||a>=120&&h.length>=120)?new Xr(l&&h):i}h=e[0];var p=-1,f=c[0];e:while(++p<a&&d.length<u){var m=h[p],g=t?t(m):m;if(m=r||0!==m?m:0,!(f?Zn(f,g):o(d,g,r))){l=s;while(--l){var v=c[l];if(!(v?Zn(v,g):o(e[l],g,r)))continue e}f&&f.push(g),d.push(m)}}return d}function Gi(e,t,n,r){return Pi(e,function(e,i,o){t(r,n(e),i,o)}),r}function Hi(e,t,n){t=qo(t,e),e=Ss(e,t);var r=null==e?e:e[Ps(al(t))];return null==r?i:wn(r,e,n)}function qi(e){return ku(e)&&Bi(e)==H}function Qi(e){return ku(e)&&Bi(e)==he}function zi(e){return ku(e)&&Bi(e)==K}function Ki(e,t,n,r,i){return e===t||(null==e||null==t||!ku(e)&&!ku(t)?e!==e&&t!==t:Wi(e,t,n,r,Ki,i))}function Wi(e,t,n,r,i,o){var a=cu(e),s=cu(t),l=a?q:Za(e),c=s?q:Za(t);l=l==H?ne:l,c=c==H?ne:c;var u=l==ne,d=c==ne,h=l==c;if(h&&fu(e)){if(!fu(t))return!1;a=!0,u=!1}if(h&&!u)return o||(o=new Jr),a||ju(e)?La(e,t,n,r,i,o):Ba(e,t,l,n,r,i,o);if(!(n&v)){var p=u&&ht.call(e,"__wrapped__"),f=d&&ht.call(t,"__wrapped__");if(p||f){var m=p?e.value():e,g=f?t.value():t;return o||(o=new Jr),i(m,g,n,r,o)}}return!!h&&(o||(o=new Jr),$a(e,t,n,r,i,o))}function Xi(e){return ku(e)&&Za(e)==J}function Yi(e,t,n,r){var o=n.length,a=o,s=!r;if(null==e)return!a;e=rt(e);while(o--){var l=n[o];if(s&&l[2]?l[1]!==e[l[0]]:!(l[0]in e))return!1}while(++o<a){l=n[o];var c=l[0],u=e[c],d=l[1];if(s&&l[2]){if(u===i&&!(c in e))return!1}else{var h=new Jr;if(r)var p=r(u,d,c,e,t,h);if(!(p===i?Ki(d,u,v|b,r,h):p))return!1}}return!0}function Zi(e){if(!_u(e)||hs(e))return!1;var t=Su(e)?bt:Xe;return t.test(Is(e))}function Ji(e){return ku(e)&&Bi(e)==oe}function eo(e){return ku(e)&&Za(e)==ae}function to(e){return ku(e)&&xu(e.length)&&!!Yt[Bi(e)]}function no(e){return"function"==typeof e?e:null==e?Nh:"object"==typeof e?cu(e)?lo(e[0],e[1]):so(e):Hh(e)}function ro(e){if(!fs(e))return Ft(e);var t=[];for(var n in rt(e))ht.call(e,n)&&"constructor"!=n&&t.push(n);return t}function io(e){if(!_u(e))return ys(e);var t=fs(e),n=[];for(var r in e)("constructor"!=r||!t&&ht.call(e,r))&&n.push(r);return n}function oo(e,t){return e<t}function ao(e,t){var r=-1,i=du(e)?n(e.length):[];return Ei(e,function(e,n,o){i[++r]=t(e,n,o)}),i}function so(e){var t=za(e);return 1==t.length&&t[0][2]?gs(t[0][0],t[0][1]):function(n){return n===e||Yi(n,e,t)}}function lo(e,t){return cs(e)&&ms(t)?gs(Ps(e),t):function(n){var r=vd(n,e);return r===i&&r===t?yd(n,e):Ki(t,r,v|b)}}function co(e,t,n,r,o){e!==t&&Ri(t,function(a,s){if(o||(o=new Jr),_u(a))uo(e,t,s,n,co,r,o);else{var l=r?r(xs(e,s),a,s+"",e,t,o):i;l===i&&(l=a),ci(e,s,l)}},xd)}function uo(e,t,n,r,o,a,s){var l=xs(e,n),c=xs(t,n),u=s.get(c);if(u)ci(e,n,u);else{var d=a?a(l,c,n+"",e,t,s):i,h=d===i;if(h){var p=cu(c),f=!p&&fu(c),m=!p&&!f&&ju(c);d=c,p||f||m?cu(l)?d=l:hu(l)?d=oa(l):f?(h=!1,d=Wo(c,!0)):m?(h=!1,d=ea(c,!0)):d=[]:Du(c)||lu(c)?(d=l,lu(l)?d=Zu(l):_u(l)&&!Su(l)||(d=rs(c))):h=!1}h&&(s.set(c,d),o(d,c,r,a,s),s["delete"](c)),ci(e,n,d)}}function ho(e,t){var n=e.length;if(n)return t+=t<0?n:0,ss(t,n)?e[t]:i}function po(e,t,n){t=t.length?An(t,function(e){return cu(e)?function(t){return Di(t,1===e.length?e[0]:e)}:e}):[Nh];var r=-1;t=An(t,Xn(qa()));var i=ao(e,function(e,n,i){var o=An(t,function(t){return t(e)});return{criteria:o,index:++r,value:e}});return qn(i,function(e,t){return na(e,t,n)})}function fo(e,t){return mo(e,t,function(t,n){return yd(e,n)})}function mo(e,t,n){var r=-1,i=t.length,o={};while(++r<i){var a=t[r],s=Di(e,a);n(s,a)&&_o(o,qo(a,e),s)}return o}function go(e){return function(t){return Di(t,e)}}function vo(e,t,n,r){var i=r?Vn:$n,o=-1,a=t.length,s=e;e===t&&(t=oa(t)),n&&(s=An(e,Xn(n)));while(++o<a){var l=0,c=t[o],u=n?n(c):c;while((l=i(s,u,l,r))>-1)s!==e&&kt.call(s,l,1),kt.call(e,l,1)}return e}function bo(e,t){var n=e?t.length:0,r=n-1;while(n--){var i=t[n];if(n==r||i!==o){var o=i;ss(i)?kt.call(e,i,1):Bo(e,i)}}return e}function yo(e,t){return e+Dt(zt()*(t-e+1))}function wo(e,t,r,i){var o=-1,a=jt(Mt((t-e)/(r||1)),0),s=n(a);while(a--)s[i?a:++o]=e,e+=r;return s}function Oo(e,t){var n="";if(!e||t<1||t>B)return n;do{t%2&&(n+=e),t=Dt(t/2),t&&(e+=e)}while(t);return n}function So(e,t){return Cs(Os(e,t,Nh),e+"")}function Eo(e){return ai(Ud(e))}function xo(e,t){var n=Ud(e);return Rs(n,vi(t,0,n.length))}function _o(e,t,n,r){if(!_u(e))return e;t=qo(t,e);var o=-1,a=t.length,s=a-1,l=e;while(null!=l&&++o<a){var c=Ps(t[o]),u=n;if("__proto__"===c||"constructor"===c||"prototype"===c)return e;if(o!=s){var d=l[c];u=r?r(d,c,l):i,u===i&&(u=_u(d)?d:ss(t[o+1])?[]:{})}ui(l,c,u),l=l[c]}return e}var ko=cn?function(e,t){return cn.set(e,t),e}:Nh,Co=Rt?function(e,t){return Rt(e,"toString",{configurable:!0,enumerable:!1,value:Ch(t),writable:!0})}:Nh;function Ao(e){return Rs(Ud(e))}function To(e,t,r){var i=-1,o=e.length;t<0&&(t=-t>o?0:o+t),r=r>o?o:r,r<0&&(r+=o),o=t>r?0:r-t>>>0,t>>>=0;var a=n(o);while(++i<o)a[i]=e[i+t];return a}function Ro(e,t){var n;return Ei(e,function(e,r,i){return n=t(e,r,i),!n}),!!n}function No(e,t,n){var r=0,i=null==e?r:e.length;if("number"==typeof t&&t===t&&i<=U){while(r<i){var o=r+i>>>1,a=e[o];null!==a&&!Fu(a)&&(n?a<=t:a<t)?r=o+1:i=o}return i}return Po(e,t,Nh,n)}function Po(e,t,n,r){var o=0,a=null==e?0:e.length;if(0===a)return 0;t=n(t);var s=t!==t,l=null===t,c=Fu(t),u=t===i;while(o<a){var d=Dt((o+a)/2),h=n(e[d]),p=h!==i,f=null===h,m=h===h,g=Fu(h);if(s)var v=r||m;else v=u?m&&(r||p):l?m&&p&&(r||!f):c?m&&p&&!f&&(r||!g):!f&&!g&&(r?h<=t:h<t);v?o=d+1:a=d}return Ut(a,j)}function Io(e,t){var n=-1,r=e.length,i=0,o=[];while(++n<r){var a=e[n],s=t?t(a):a;if(!n||!ou(s,l)){var l=s;o[i++]=0===a?0:a}}return o}function Mo(e){return"number"==typeof e?e:Fu(e)?V:+e}function Do(e){if("string"==typeof e)return e;if(cu(e))return An(e,Do)+"";if(Fu(e))return Or?Or.call(e):"";var t=e+"";return"0"==t&&1/e==-L?"-0":t}function Lo(e,t,n){var r=-1,i=kn,o=e.length,s=!0,l=[],c=l;if(n)s=!1,i=Cn;else if(o>=a){var u=t?null:Ra(e);if(u)return hr(u);s=!1,i=Zn,c=new Xr}else c=t?[]:l;e:while(++r<o){var d=e[r],h=t?t(d):d;if(d=n||0!==d?d:0,s&&h===h){var p=c.length;while(p--)if(c[p]===h)continue e;t&&c.push(h),l.push(d)}else i(c,h,n)||(c!==l&&c.push(h),l.push(d))}return l}function Bo(e,t){t=qo(t,e);var n=-1,r=t.length;if(!r)return!0;while(++n<r){var i=Ps(t[n]);if("__proto__"===i&&!ht.call(e,"__proto__"))return!1;if(("constructor"===i||"prototype"===i)&&n<r-1)return!1}var o=Ss(e,t);return null==o||delete o[Ps(al(t))]}function $o(e,t,n,r){return _o(e,t,n(Di(e,t)),r)}function Vo(e,t,n,r){var i=e.length,o=r?i:-1;while((r?o--:++o<i)&&t(e[o],o,e));return n?To(e,r?0:o,r?o+1:i):To(e,r?o+1:0,r?i:o)}function Fo(e,t){var n=e;return n instanceof Ar&&(n=n.value()),Rn(t,function(e,t){return t.func.apply(t.thisArg,Tn([e],t.args))},n)}function jo(e,t,r){var i=e.length;if(i<2)return i?Lo(e[0]):[];var o=-1,a=n(i);while(++o<i){var s=e[o],l=-1;while(++l<i)l!=o&&(a[o]=Si(a[o]||s,e[l],t,r))}return Lo(Ti(a,1),t,r)}function Uo(e,t,n){var r=-1,o=e.length,a=t.length,s={};while(++r<o){var l=r<a?t[r]:i;n(s,e[r],l)}return s}function Go(e){return hu(e)?e:[]}function Ho(e){return"function"==typeof e?e:Nh}function qo(e,t){return cu(e)?e:cs(e,t)?[e]:Ns(ed(e))}var Qo=So;function zo(e,t,n){var r=e.length;return n=n===i?r:n,!t&&n>=r?e:To(e,t,n)}var Ko=Nt||function(e){return ln.clearTimeout(e)};function Wo(e,t){if(t)return e.slice();var n=e.length,r=St?St(n):new e.constructor(n);return e.copy(r),r}function Xo(e){var t=new e.constructor(e.byteLength);return new Ot(t).set(new Ot(e)),t}function Yo(e,t){var n=t?Xo(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}function Zo(e){var t=new e.constructor(e.source,ze.exec(e));return t.lastIndex=e.lastIndex,t}function Jo(e){return wr?rt(wr.call(e)):{}}function ea(e,t){var n=t?Xo(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}function ta(e,t){if(e!==t){var n=e!==i,r=null===e,o=e===e,a=Fu(e),s=t!==i,l=null===t,c=t===t,u=Fu(t);if(!l&&!u&&!a&&e>t||a&&s&&c&&!l&&!u||r&&s&&c||!n&&c||!o)return 1;if(!r&&!a&&!u&&e<t||u&&n&&o&&!r&&!a||l&&n&&o||!s&&o||!c)return-1}return 0}function na(e,t,n){var r=-1,i=e.criteria,o=t.criteria,a=i.length,s=n.length;while(++r<a){var l=ta(i[r],o[r]);if(l){if(r>=s)return l;var c=n[r];return l*("desc"==c?-1:1)}}return e.index-t.index}function ra(e,t,r,i){var o=-1,a=e.length,s=r.length,l=-1,c=t.length,u=jt(a-s,0),d=n(c+u),h=!i;while(++l<c)d[l]=t[l];while(++o<s)(h||o<a)&&(d[r[o]]=e[o]);while(u--)d[l++]=e[o++];return d}function ia(e,t,r,i){var o=-1,a=e.length,s=-1,l=r.length,c=-1,u=t.length,d=jt(a-l,0),h=n(d+u),p=!i;while(++o<d)h[o]=e[o];var f=o;while(++c<u)h[f+c]=t[c];while(++s<l)(p||o<a)&&(h[f+r[s]]=e[o++]);return h}function oa(e,t){var r=-1,i=e.length;t||(t=n(i));while(++r<i)t[r]=e[r];return t}function aa(e,t,n,r){var o=!n;n||(n={});var a=-1,s=t.length;while(++a<s){var l=t[a],c=r?r(n[l],e[l],l,n,e):i;c===i&&(c=e[l]),o?mi(n,l,c):ui(n,l,c)}return n}function sa(e,t){return aa(e,Xa(e),t)}function la(e,t){return aa(e,Ya(e),t)}function ca(e,t){return function(n,r){var i=cu(n)?On:hi,o=t?t():{};return i(n,e,qa(r,2),o)}}function ua(e){return So(function(t,n){var r=-1,o=n.length,a=o>1?n[o-1]:i,s=o>2?n[2]:i;a=e.length>3&&"function"==typeof a?(o--,a):i,s&&ls(n[0],n[1],s)&&(a=o<3?i:a,o=1),t=rt(t);while(++r<o){var l=n[r];l&&e(t,l,r,a)}return t})}function da(e,t){return function(n,r){if(null==n)return n;if(!du(n))return e(n,r);var i=n.length,o=t?i:-1,a=rt(n);while(t?o--:++o<i)if(!1===r(a[o],o,a))break;return n}}function ha(e){return function(t,n,r){var i=-1,o=rt(t),a=r(t),s=a.length;while(s--){var l=a[e?s:++i];if(!1===n(o[l],l,o))break}return t}}function pa(e,t,n){var r=t&y,i=ga(e);function o(){var t=this&&this!==ln&&this instanceof o?i:e;return t.apply(r?n:this,arguments)}return o}function fa(e){return function(t){t=ed(t);var n=ar(t)?vr(t):i,r=n?n[0]:t.charAt(0),o=n?zo(n,1).join(""):t.slice(1);return r[e]()+o}}function ma(e){return function(t){return Rn(Sh(Wd(t).replace(Gt,"")),e,"")}}function ga(e){return function(){var t=arguments;switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3]);case 5:return new e(t[0],t[1],t[2],t[3],t[4]);case 6:return new e(t[0],t[1],t[2],t[3],t[4],t[5]);case 7:return new e(t[0],t[1],t[2],t[3],t[4],t[5],t[6])}var n=_r(e.prototype),r=e.apply(n,t);return _u(r)?r:n}}function va(e,t,r){var o=ga(e);function a(){var s=arguments.length,l=n(s),c=s,u=Ha(a);while(c--)l[c]=arguments[c];var d=s<3&&l[0]!==u&&l[s-1]!==u?[]:dr(l,u);if(s-=d.length,s<r)return Aa(e,t,wa,a.placeholder,i,l,d,i,i,r-s);var h=this&&this!==ln&&this instanceof a?o:e;return wn(h,this,l)}return a}function ba(e){return function(t,n,r){var o=rt(t);if(!du(t)){var a=qa(n,3);t=Ed(t),n=function(e){return a(o[e],e,o)}}var s=e(t,n,r);return s>-1?o[a?t[s]:s]:i}}function ya(e){return Va(function(t){var n=t.length,r=n,o=Cr.prototype.thru;e&&t.reverse();while(r--){var a=t[r];if("function"!=typeof a)throw new at(l);if(o&&!s&&"wrapper"==Ga(a))var s=new Cr([],!0)}r=s?r:n;while(++r<n){a=t[r];var c=Ga(a),u="wrapper"==c?Ua(a):i;s=u&&ds(u[0])&&u[1]==(k|S|x|C)&&!u[4].length&&1==u[9]?s[Ga(u[0])].apply(s,u[3]):1==a.length&&ds(a)?s[c]():s.thru(a)}return function(){var e=arguments,r=e[0];if(s&&1==e.length&&cu(r))return s.plant(r).value();var i=0,o=n?t[i].apply(this,e):r;while(++i<n)o=t[i].call(this,o);return o}})}function wa(e,t,r,o,a,s,l,c,u,d){var h=t&k,p=t&y,f=t&w,m=t&(S|E),g=t&A,v=f?i:ga(e);function b(){var i=arguments.length,y=n(i),w=i;while(w--)y[w]=arguments[w];if(m)var O=Ha(b),S=tr(y,O);if(o&&(y=ra(y,o,a,m)),s&&(y=ia(y,s,l,m)),i-=S,m&&i<d){var E=dr(y,O);return Aa(e,t,wa,b.placeholder,r,y,E,c,u,d-i)}var x=p?r:this,_=f?x[e]:e;return i=y.length,c?y=Es(y,c):g&&i>1&&y.reverse(),h&&u<i&&(y.length=u),this&&this!==ln&&this instanceof b&&(_=v||ga(_)),_.apply(x,y)}return b}function Oa(e,t){return function(n,r){return Gi(n,e,t(r),{})}}function Sa(e,t){return function(n,r){var o;if(n===i&&r===i)return t;if(n!==i&&(o=n),r!==i){if(o===i)return r;"string"==typeof n||"string"==typeof r?(n=Do(n),r=Do(r)):(n=Mo(n),r=Mo(r)),o=e(n,r)}return o}}function Ea(e){return Va(function(t){return t=An(t,Xn(qa())),So(function(n){var r=this;return e(t,function(e){return wn(e,r,n)})})})}function xa(e,t){t=t===i?" ":Do(t);var n=t.length;if(n<2)return n?Oo(t,e):t;var r=Oo(t,Mt(e/gr(t)));return ar(t)?zo(vr(r),0,e).join(""):r.slice(0,e)}function _a(e,t,r,i){var o=t&y,a=ga(e);function s(){var t=-1,l=arguments.length,c=-1,u=i.length,d=n(u+l),h=this&&this!==ln&&this instanceof s?a:e;while(++c<u)d[c]=i[c];while(l--)d[c++]=arguments[++t];return wn(h,o?r:this,d)}return s}function ka(e){return function(t,n,r){return r&&"number"!=typeof r&&ls(t,n,r)&&(n=r=i),t=Ku(t),n===i?(n=t,t=0):n=Ku(n),r=r===i?t<n?1:-1:Ku(r),wo(t,n,r,e)}}function Ca(e){return function(t,n){return"string"==typeof t&&"string"==typeof n||(t=Yu(t),n=Yu(n)),e(t,n)}}function Aa(e,t,n,r,o,a,s,l,c,u){var d=t&S,h=d?s:i,p=d?i:s,f=d?a:i,m=d?i:a;t|=d?x:_,t&=~(d?_:x),t&O||(t&=~(y|w));var g=[e,t,o,f,h,m,p,l,c,u],v=n.apply(i,g);return ds(e)&&_s(v,g),v.placeholder=r,As(v,e,t)}function Ta(e){var t=nt[e];return function(e,n){if(e=Yu(e),n=null==n?0:Ut(Wu(n),292),n&&$t(e)){var r=(ed(e)+"e").split("e"),i=t(r[0]+"e"+(+r[1]+n));return r=(ed(i)+"e").split("e"),+(r[0]+"e"+(+r[1]-n))}return t(e)}}var Ra=nn&&1/hr(new nn([,-0]))[1]==L?function(e){return new nn(e)}:Vh;function Na(e){return function(t){var n=Za(t);return n==J?cr(t):n==ae?pr(t):Kn(t,e(t))}}function Pa(e,t,n,r,o,a,s,c){var u=t&w;if(!u&&"function"!=typeof e)throw new at(l);var d=r?r.length:0;if(d||(t&=~(x|_),r=o=i),s=s===i?s:jt(Wu(s),0),c=c===i?c:Wu(c),d-=o?o.length:0,t&_){var h=r,p=o;r=o=i}var f=u?i:Ua(e),m=[e,t,n,r,o,h,p,a,s,c];if(f&&bs(m,f),e=m[0],t=m[1],n=m[2],r=m[3],o=m[4],c=m[9]=m[9]===i?u?0:e.length:jt(m[9]-d,0),!c&&t&(S|E)&&(t&=~(S|E)),t&&t!=y)g=t==S||t==E?va(e,t,c):t!=x&&t!=(y|x)||o.length?wa.apply(i,m):_a(e,t,n,r);else var g=pa(e,t,n);var v=f?ko:_s;return As(v(g,m),e,t)}function Ia(e,t,n,r){return e===i||ou(e,ct[n])&&!ht.call(r,n)?t:e}function Ma(e,t,n,r,o,a){return _u(e)&&_u(t)&&(a.set(t,e),co(e,t,i,Ma,a),a["delete"](t)),e}function Da(e){return Du(e)?i:e}function La(e,t,n,r,o,a){var s=n&v,l=e.length,c=t.length;if(l!=c&&!(s&&c>l))return!1;var u=a.get(e),d=a.get(t);if(u&&d)return u==t&&d==e;var h=-1,p=!0,f=n&b?new Xr:i;a.set(e,t),a.set(t,e);while(++h<l){var m=e[h],g=t[h];if(r)var y=s?r(g,m,h,t,e,a):r(m,g,h,e,t,a);if(y!==i){if(y)continue;p=!1;break}if(f){if(!Pn(t,function(e,t){if(!Zn(f,t)&&(m===e||o(m,e,n,r,a)))return f.push(t)})){p=!1;break}}else if(m!==g&&!o(m,g,n,r,a)){p=!1;break}}return a["delete"](e),a["delete"](t),p}function Ba(e,t,n,r,i,o,a){switch(n){case pe:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case he:return!(e.byteLength!=t.byteLength||!o(new Ot(e),new Ot(t)));case z:case K:case ee:return ou(+e,+t);case X:return e.name==t.name&&e.message==t.message;case oe:case se:return e==t+"";case J:var s=cr;case ae:var l=r&v;if(s||(s=hr),e.size!=t.size&&!l)return!1;var c=a.get(e);if(c)return c==t;r|=b,a.set(e,t);var u=La(s(e),s(t),r,i,o,a);return a["delete"](e),u;case le:if(wr)return wr.call(e)==wr.call(t)}return!1}function $a(e,t,n,r,o,a){var s=n&v,l=Fa(e),c=l.length,u=Fa(t),d=u.length;if(c!=d&&!s)return!1;var h=c;while(h--){var p=l[h];if(!(s?p in t:ht.call(t,p)))return!1}var f=a.get(e),m=a.get(t);if(f&&m)return f==t&&m==e;var g=!0;a.set(e,t),a.set(t,e);var b=s;while(++h<c){p=l[h];var y=e[p],w=t[p];if(r)var O=s?r(w,y,p,t,e,a):r(y,w,p,e,t,a);if(!(O===i?y===w||o(y,w,n,r,a):O)){g=!1;break}b||(b="constructor"==p)}if(g&&!b){var S=e.constructor,E=t.constructor;S==E||!("constructor"in e)||!("constructor"in t)||"function"==typeof S&&S instanceof S&&"function"==typeof E&&E instanceof E||(g=!1)}return a["delete"](e),a["delete"](t),g}function Va(e){return Cs(Os(e,i,Ws),e+"")}function Fa(e){return Li(e,Ed,Xa)}function ja(e){return Li(e,xd,Ya)}var Ua=cn?function(e){return cn.get(e)}:Vh;function Ga(e){var t=e.name+"",n=un[t],r=ht.call(un,t)?n.length:0;while(r--){var i=n[r],o=i.func;if(null==o||o==e)return i.name}return t}function Ha(e){var t=ht.call(Er,"placeholder")?Er:e;return t.placeholder}function qa(){var e=Er.iteratee||Ph;return e=e===Ph?no:e,arguments.length?e(arguments[0],arguments[1]):e}function Qa(e,t){var n=e.__data__;return us(t)?n["string"==typeof t?"string":"hash"]:n.map}function za(e){var t=Ed(e),n=t.length;while(n--){var r=t[n],i=e[r];t[n]=[r,i,ms(i)]}return t}function Ka(e,t){var n=or(e,t);return Zi(n)?n:i}function Wa(e){var t=ht.call(e,Tt),n=e[Tt];try{e[Tt]=i;var r=!0}catch(a){}var o=mt.call(e);return r&&(t?e[Tt]=n:delete e[Tt]),o}var Xa=Lt?function(e){return null==e?[]:(e=rt(e),_n(Lt(e),function(t){return _t.call(e,t)}))}:Kh,Ya=Lt?function(e){var t=[];while(e)Tn(t,Xa(e)),e=Et(e);return t}:Kh,Za=Bi;function Ja(e,t,n){var r=-1,i=n.length;while(++r<i){var o=n[r],a=o.size;switch(o.type){case"drop":e+=a;break;case"dropRight":t-=a;break;case"take":t=Ut(t,e+a);break;case"takeRight":e=jt(e,t-a);break}}return{start:e,end:t}}function es(e){var t=e.match(je);return t?t[1].split(Ue):[]}function ts(e,t,n){t=qo(t,e);var r=-1,i=t.length,o=!1;while(++r<i){var a=Ps(t[r]);if(!(o=null!=e&&n(e,a)))break;e=e[a]}return o||++r!=i?o:(i=null==e?0:e.length,!!i&&xu(i)&&ss(a,i)&&(cu(e)||lu(e)))}function ns(e){var t=e.length,n=new e.constructor(t);return t&&"string"==typeof e[0]&&ht.call(e,"index")&&(n.index=e.index,n.input=e.input),n}function rs(e){return"function"!=typeof e.constructor||fs(e)?{}:_r(Et(e))}function is(e,t,n){var r=e.constructor;switch(t){case he:return Xo(e);case z:case K:return new r(+e);case pe:return Yo(e,n);case fe:case me:case ge:case ve:case be:case ye:case we:case Oe:case Se:return ea(e,n);case J:return new r;case ee:case se:return new r(e);case oe:return Zo(e);case ae:return new r;case le:return Jo(e)}}function os(e,t){var n=t.length;if(!n)return e;var r=n-1;return t[r]=(n>1?"& ":"")+t[r],t=t.join(n>2?", ":" "),e.replace(Fe,"{\n/* [wrapped with "+t+"] */\n")}function as(e){return cu(e)||lu(e)||!!(Ct&&e&&e[Ct])}function ss(e,t){var n=typeof e;return t=null==t?B:t,!!t&&("number"==n||"symbol"!=n&&Ze.test(e))&&e>-1&&e%1==0&&e<t}function ls(e,t,n){if(!_u(n))return!1;var r=typeof t;return!!("number"==r?du(n)&&ss(t,n.length):"string"==r&&t in n)&&ou(n[t],e)}function cs(e,t){if(cu(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!Fu(e))||(Me.test(e)||!Ie.test(e)||null!=t&&e in rt(t))}function us(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}function ds(e){var t=Ga(e),n=Er[t];if("function"!=typeof n||!(t in Ar.prototype))return!1;if(e===n)return!0;var r=Ua(n);return!!r&&e===r[0]}function hs(e){return!!ft&&ft in e}(Jt&&Za(new Jt(new ArrayBuffer(1)))!=pe||en&&Za(new en)!=J||tn&&Za(tn.resolve())!=re||nn&&Za(new nn)!=ae||an&&Za(new an)!=ue)&&(Za=function(e){var t=Bi(e),n=t==ne?e.constructor:i,r=n?Is(n):"";if(r)switch(r){case hn:return pe;case pn:return J;case In:return re;case Mn:return ae;case Gn:return ue}return t});var ps=ut?Su:Wh;function fs(e){var t=e&&e.constructor,n="function"==typeof t&&t.prototype||ct;return e===n}function ms(e){return e===e&&!_u(e)}function gs(e,t){return function(n){return null!=n&&(n[e]===t&&(t!==i||e in rt(n)))}}function vs(e){var t=jc(e,function(e){return n.size===h&&n.clear(),e}),n=t.cache;return t}function bs(e,t){var n=e[1],r=t[1],i=n|r,o=i<(y|w|k),a=r==k&&n==S||r==k&&n==C&&e[7].length<=t[8]||r==(k|C)&&t[7].length<=t[8]&&n==S;if(!o&&!a)return e;r&y&&(e[2]=t[2],i|=n&y?0:O);var s=t[3];if(s){var l=e[3];e[3]=l?ra(l,s,t[4]):s,e[4]=l?dr(e[3],p):t[4]}return s=t[5],s&&(l=e[5],e[5]=l?ia(l,s,t[6]):s,e[6]=l?dr(e[5],p):t[6]),s=t[7],s&&(e[7]=s),r&k&&(e[8]=null==e[8]?t[8]:Ut(e[8],t[8])),null==e[9]&&(e[9]=t[9]),e[0]=t[0],e[1]=i,e}function ys(e){var t=[];if(null!=e)for(var n in rt(e))t.push(n);return t}function ws(e){return mt.call(e)}function Os(e,t,r){return t=jt(t===i?e.length-1:t,0),function(){var i=arguments,o=-1,a=jt(i.length-t,0),s=n(a);while(++o<a)s[o]=i[t+o];o=-1;var l=n(t+1);while(++o<t)l[o]=i[o];return l[t]=r(s),wn(e,this,l)}}function Ss(e,t){return t.length<2?e:Di(e,To(t,0,-1))}function Es(e,t){var n=e.length,r=Ut(t.length,n),o=oa(e);while(r--){var a=t[r];e[r]=ss(a,n)?o[a]:i}return e}function xs(e,t){if(("constructor"!==t||"function"!==typeof e[t])&&"__proto__"!=t)return e[t]}var _s=Ts(ko),ks=It||function(e,t){return ln.setTimeout(e,t)},Cs=Ts(Co);function As(e,t,n){var r=t+"";return Cs(e,os(r,Ms(es(r),n)))}function Ts(e){var t=0,n=0;return function(){var r=qt(),o=P-(r-n);if(n=r,o>0){if(++t>=N)return arguments[0]}else t=0;return e.apply(i,arguments)}}function Rs(e,t){var n=-1,r=e.length,o=r-1;t=t===i?r:t;while(++n<t){var a=yo(n,o),s=e[a];e[a]=e[n],e[n]=s}return e.length=t,e}var Ns=vs(function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(De,function(e,n,r,i){t.push(r?i.replace(qe,"$1"):n||e)}),t});function Ps(e){if("string"==typeof e||Fu(e))return e;var t=e+"";return"0"==t&&1/e==-L?"-0":t}function Is(e){if(null!=e){try{return dt.call(e)}catch(t){}try{return e+""}catch(t){}}return""}function Ms(e,t){return Sn(G,function(n){var r="_."+n[0];t&n[1]&&!kn(e,r)&&e.push(r)}),e.sort()}function Ds(e){if(e instanceof Ar)return e.clone();var t=new Cr(e.__wrapped__,e.__chain__);return t.__actions__=oa(e.__actions__),t.__index__=e.__index__,t.__values__=e.__values__,t}function Ls(e,t,r){t=(r?ls(e,t,r):t===i)?1:jt(Wu(t),0);var o=null==e?0:e.length;if(!o||t<1)return[];var a=0,s=0,l=n(Mt(o/t));while(a<o)l[s++]=To(e,a,a+=t);return l}function Bs(e){var t=-1,n=null==e?0:e.length,r=0,i=[];while(++t<n){var o=e[t];o&&(i[r++]=o)}return i}function $s(){var e=arguments.length;if(!e)return[];var t=n(e-1),r=arguments[0],i=e;while(i--)t[i-1]=arguments[i];return Tn(cu(r)?oa(r):[r],Ti(t,1))}var Vs=So(function(e,t){return hu(e)?Si(e,Ti(t,1,hu,!0)):[]}),Fs=So(function(e,t){var n=al(t);return hu(n)&&(n=i),hu(e)?Si(e,Ti(t,1,hu,!0),qa(n,2)):[]}),js=So(function(e,t){var n=al(t);return hu(n)&&(n=i),hu(e)?Si(e,Ti(t,1,hu,!0),i,n):[]});function Us(e,t,n){var r=null==e?0:e.length;return r?(t=n||t===i?1:Wu(t),To(e,t<0?0:t,r)):[]}function Gs(e,t,n){var r=null==e?0:e.length;return r?(t=n||t===i?1:Wu(t),t=r-t,To(e,0,t<0?0:t)):[]}function Hs(e,t){return e&&e.length?Vo(e,qa(t,3),!0,!0):[]}function qs(e,t){return e&&e.length?Vo(e,qa(t,3),!0):[]}function Qs(e,t,n,r){var i=null==e?0:e.length;return i?(n&&"number"!=typeof n&&ls(e,t,n)&&(n=0,r=i),Ci(e,t,n,r)):[]}function zs(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var i=null==n?0:Wu(n);return i<0&&(i=jt(r+i,0)),Bn(e,qa(t,3),i)}function Ks(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var o=r-1;return n!==i&&(o=Wu(n),o=n<0?jt(r+o,0):Ut(o,r-1)),Bn(e,qa(t,3),o,!0)}function Ws(e){var t=null==e?0:e.length;return t?Ti(e,1):[]}function Xs(e){var t=null==e?0:e.length;return t?Ti(e,L):[]}function Ys(e,t){var n=null==e?0:e.length;return n?(t=t===i?1:Wu(t),Ti(e,t)):[]}function Zs(e){var t=-1,n=null==e?0:e.length,r={};while(++t<n){var i=e[t];mi(r,i[0],i[1])}return r}function Js(e){return e&&e.length?e[0]:i}function el(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var i=null==n?0:Wu(n);return i<0&&(i=jt(r+i,0)),$n(e,t,i)}function tl(e){var t=null==e?0:e.length;return t?To(e,0,-1):[]}var nl=So(function(e){var t=An(e,Go);return t.length&&t[0]===e[0]?Ui(t):[]}),rl=So(function(e){var t=al(e),n=An(e,Go);return t===al(n)?t=i:n.pop(),n.length&&n[0]===e[0]?Ui(n,qa(t,2)):[]}),il=So(function(e){var t=al(e),n=An(e,Go);return t="function"==typeof t?t:i,t&&n.pop(),n.length&&n[0]===e[0]?Ui(n,i,t):[]});function ol(e,t){return null==e?"":Vt.call(e,t)}function al(e){var t=null==e?0:e.length;return t?e[t-1]:i}function sl(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var o=r;return n!==i&&(o=Wu(n),o=o<0?jt(r+o,0):Ut(o,r-1)),t===t?mr(e,t,o):Bn(e,Fn,o,!0)}function ll(e,t){return e&&e.length?ho(e,Wu(t)):i}var cl=So(ul);function ul(e,t){return e&&e.length&&t&&t.length?vo(e,t):e}function dl(e,t,n){return e&&e.length&&t&&t.length?vo(e,t,qa(n,2)):e}function hl(e,t,n){return e&&e.length&&t&&t.length?vo(e,t,i,n):e}var pl=Va(function(e,t){var n=null==e?0:e.length,r=gi(e,t);return bo(e,An(t,function(e){return ss(e,n)?+e:e}).sort(ta)),r});function fl(e,t){var n=[];if(!e||!e.length)return n;var r=-1,i=[],o=e.length;t=qa(t,3);while(++r<o){var a=e[r];t(a,r,e)&&(n.push(a),i.push(r))}return bo(e,i),n}function ml(e){return null==e?e:Kt.call(e)}function gl(e,t,n){var r=null==e?0:e.length;return r?(n&&"number"!=typeof n&&ls(e,t,n)?(t=0,n=r):(t=null==t?0:Wu(t),n=n===i?r:Wu(n)),To(e,t,n)):[]}function vl(e,t){return No(e,t)}function bl(e,t,n){return Po(e,t,qa(n,2))}function yl(e,t){var n=null==e?0:e.length;if(n){var r=No(e,t);if(r<n&&ou(e[r],t))return r}return-1}function wl(e,t){return No(e,t,!0)}function Ol(e,t,n){return Po(e,t,qa(n,2),!0)}function Sl(e,t){var n=null==e?0:e.length;if(n){var r=No(e,t,!0)-1;if(ou(e[r],t))return r}return-1}function El(e){return e&&e.length?Io(e):[]}function xl(e,t){return e&&e.length?Io(e,qa(t,2)):[]}function _l(e){var t=null==e?0:e.length;return t?To(e,1,t):[]}function kl(e,t,n){return e&&e.length?(t=n||t===i?1:Wu(t),To(e,0,t<0?0:t)):[]}function Cl(e,t,n){var r=null==e?0:e.length;return r?(t=n||t===i?1:Wu(t),t=r-t,To(e,t<0?0:t,r)):[]}function Al(e,t){return e&&e.length?Vo(e,qa(t,3),!1,!0):[]}function Tl(e,t){return e&&e.length?Vo(e,qa(t,3)):[]}var Rl=So(function(e){return Lo(Ti(e,1,hu,!0))}),Nl=So(function(e){var t=al(e);return hu(t)&&(t=i),Lo(Ti(e,1,hu,!0),qa(t,2))}),Pl=So(function(e){var t=al(e);return t="function"==typeof t?t:i,Lo(Ti(e,1,hu,!0),i,t)});function Il(e){return e&&e.length?Lo(e):[]}function Ml(e,t){return e&&e.length?Lo(e,qa(t,2)):[]}function Dl(e,t){return t="function"==typeof t?t:i,e&&e.length?Lo(e,i,t):[]}function Ll(e){if(!e||!e.length)return[];var t=0;return e=_n(e,function(e){if(hu(e))return t=jt(e.length,t),!0}),zn(t,function(t){return An(e,Un(t))})}function Bl(e,t){if(!e||!e.length)return[];var n=Ll(e);return null==t?n:An(n,function(e){return wn(t,i,e)})}var $l=So(function(e,t){return hu(e)?Si(e,t):[]}),Vl=So(function(e){return jo(_n(e,hu))}),Fl=So(function(e){var t=al(e);return hu(t)&&(t=i),jo(_n(e,hu),qa(t,2))}),jl=So(function(e){var t=al(e);return t="function"==typeof t?t:i,jo(_n(e,hu),i,t)}),Ul=So(Ll);function Gl(e,t){return Uo(e||[],t||[],ui)}function Hl(e,t){return Uo(e||[],t||[],_o)}var ql=So(function(e){var t=e.length,n=t>1?e[t-1]:i;return n="function"==typeof n?(e.pop(),n):i,Bl(e,n)});function Ql(e){var t=Er(e);return t.__chain__=!0,t}function zl(e,t){return t(e),e}function Kl(e,t){return t(e)}var Wl=Va(function(e){var t=e.length,n=t?e[0]:0,r=this.__wrapped__,o=function(t){return gi(t,e)};return!(t>1||this.__actions__.length)&&r instanceof Ar&&ss(n)?(r=r.slice(n,+n+(t?1:0)),r.__actions__.push({func:Kl,args:[o],thisArg:i}),new Cr(r,this.__chain__).thru(function(e){return t&&!e.length&&e.push(i),e})):this.thru(o)});function Xl(){return Ql(this)}function Yl(){return new Cr(this.value(),this.__chain__)}function Zl(){this.__values__===i&&(this.__values__=zu(this.value()));var e=this.__index__>=this.__values__.length,t=e?i:this.__values__[this.__index__++];return{done:e,value:t}}function Jl(){return this}function ec(e){var t,n=this;while(n instanceof kr){var r=Ds(n);r.__index__=0,r.__values__=i,t?o.__wrapped__=r:t=r;var o=r;n=n.__wrapped__}return o.__wrapped__=e,t}function tc(){var e=this.__wrapped__;if(e instanceof Ar){var t=e;return this.__actions__.length&&(t=new Ar(this)),t=t.reverse(),t.__actions__.push({func:Kl,args:[ml],thisArg:i}),new Cr(t,this.__chain__)}return this.thru(ml)}function nc(){return Fo(this.__wrapped__,this.__actions__)}var rc=ca(function(e,t,n){ht.call(e,n)?++e[n]:mi(e,n,1)});function ic(e,t,n){var r=cu(e)?xn:_i;return n&&ls(e,t,n)&&(t=i),r(e,qa(t,3))}function oc(e,t){var n=cu(e)?_n:Ai;return n(e,qa(t,3))}var ac=ba(zs),sc=ba(Ks);function lc(e,t){return Ti(vc(e,t),1)}function cc(e,t){return Ti(vc(e,t),L)}function uc(e,t,n){return n=n===i?1:Wu(n),Ti(vc(e,t),n)}function dc(e,t){var n=cu(e)?Sn:Ei;return n(e,qa(t,3))}function hc(e,t){var n=cu(e)?En:xi;return n(e,qa(t,3))}var pc=ca(function(e,t,n){ht.call(e,n)?e[n].push(t):mi(e,n,[t])});function fc(e,t,n,r){e=du(e)?e:Ud(e),n=n&&!r?Wu(n):0;var i=e.length;return n<0&&(n=jt(i+n,0)),Vu(e)?n<=i&&e.indexOf(t,n)>-1:!!i&&$n(e,t,n)>-1}var mc=So(function(e,t,r){var i=-1,o="function"==typeof t,a=du(e)?n(e.length):[];return Ei(e,function(e){a[++i]=o?wn(t,e,r):Hi(e,t,r)}),a}),gc=ca(function(e,t,n){mi(e,n,t)});function vc(e,t){var n=cu(e)?An:ao;return n(e,qa(t,3))}function bc(e,t,n,r){return null==e?[]:(cu(t)||(t=null==t?[]:[t]),n=r?i:n,cu(n)||(n=null==n?[]:[n]),po(e,t,n))}var yc=ca(function(e,t,n){e[n?0:1].push(t)},function(){return[[],[]]});function wc(e,t,n){var r=cu(e)?Rn:Hn,i=arguments.length<3;return r(e,qa(t,4),n,i,Ei)}function Oc(e,t,n){var r=cu(e)?Nn:Hn,i=arguments.length<3;return r(e,qa(t,4),n,i,xi)}function Sc(e,t){var n=cu(e)?_n:Ai;return n(e,Uc(qa(t,3)))}function Ec(e){var t=cu(e)?ai:Eo;return t(e)}function xc(e,t,n){t=(n?ls(e,t,n):t===i)?1:Wu(t);var r=cu(e)?si:xo;return r(e,t)}function _c(e){var t=cu(e)?li:Ao;return t(e)}function kc(e){if(null==e)return 0;if(du(e))return Vu(e)?gr(e):e.length;var t=Za(e);return t==J||t==ae?e.size:ro(e).length}function Cc(e,t,n){var r=cu(e)?Pn:Ro;return n&&ls(e,t,n)&&(t=i),r(e,qa(t,3))}var Ac=So(function(e,t){if(null==e)return[];var n=t.length;return n>1&&ls(e,t[0],t[1])?t=[]:n>2&&ls(t[0],t[1],t[2])&&(t=[t[0]]),po(e,Ti(t,1),[])}),Tc=Pt||function(){return ln.Date.now()};function Rc(e,t){if("function"!=typeof t)throw new at(l);return e=Wu(e),function(){if(--e<1)return t.apply(this,arguments)}}function Nc(e,t,n){return t=n?i:t,t=e&&null==t?e.length:t,Pa(e,k,i,i,i,i,t)}function Pc(e,t){var n;if("function"!=typeof t)throw new at(l);return e=Wu(e),function(){return--e>0&&(n=t.apply(this,arguments)),e<=1&&(t=i),n}}var Ic=So(function(e,t,n){var r=y;if(n.length){var i=dr(n,Ha(Ic));r|=x}return Pa(e,r,t,n,i)}),Mc=So(function(e,t,n){var r=y|w;if(n.length){var i=dr(n,Ha(Mc));r|=x}return Pa(t,r,e,n,i)});function Dc(e,t,n){t=n?i:t;var r=Pa(e,S,i,i,i,i,i,t);return r.placeholder=Dc.placeholder,r}function Lc(e,t,n){t=n?i:t;var r=Pa(e,E,i,i,i,i,i,t);return r.placeholder=Lc.placeholder,r}function Bc(e,t,n){var r,o,a,s,c,u,d=0,h=!1,p=!1,f=!0;if("function"!=typeof e)throw new at(l);function m(t){var n=r,a=o;return r=o=i,d=t,s=e.apply(a,n),s}function g(e){return d=e,c=ks(y,t),h?m(e):s}function v(e){var n=e-u,r=e-d,i=t-n;return p?Ut(i,a-r):i}function b(e){var n=e-u,r=e-d;return u===i||n>=t||n<0||p&&r>=a}function y(){var e=Tc();if(b(e))return w(e);c=ks(y,v(e))}function w(e){return c=i,f&&r?m(e):(r=o=i,s)}function O(){c!==i&&Ko(c),d=0,r=u=o=c=i}function S(){return c===i?s:w(Tc())}function E(){var e=Tc(),n=b(e);if(r=arguments,o=this,u=e,n){if(c===i)return g(u);if(p)return Ko(c),c=ks(y,t),m(u)}return c===i&&(c=ks(y,t)),s}return t=Yu(t)||0,_u(n)&&(h=!!n.leading,p="maxWait"in n,a=p?jt(Yu(n.maxWait)||0,t):a,f="trailing"in n?!!n.trailing:f),E.cancel=O,E.flush=S,E}var $c=So(function(e,t){return Oi(e,1,t)}),Vc=So(function(e,t,n){return Oi(e,Yu(t)||0,n)});function Fc(e){return Pa(e,A)}function jc(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new at(l);var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var a=e.apply(this,r);return n.cache=o.set(i,a)||o,a};return n.cache=new(jc.Cache||Hr),n}function Uc(e){if("function"!=typeof e)throw new at(l);return function(){var t=arguments;switch(t.length){case 0:return!e.call(this);case 1:return!e.call(this,t[0]);case 2:return!e.call(this,t[0],t[1]);case 3:return!e.call(this,t[0],t[1],t[2])}return!e.apply(this,t)}}function Gc(e){return Pc(2,e)}jc.Cache=Hr;var Hc=Qo(function(e,t){t=1==t.length&&cu(t[0])?An(t[0],Xn(qa())):An(Ti(t,1),Xn(qa()));var n=t.length;return So(function(r){var i=-1,o=Ut(r.length,n);while(++i<o)r[i]=t[i].call(this,r[i]);return wn(e,this,r)})}),qc=So(function(e,t){var n=dr(t,Ha(qc));return Pa(e,x,i,t,n)}),Qc=So(function(e,t){var n=dr(t,Ha(Qc));return Pa(e,_,i,t,n)}),zc=Va(function(e,t){return Pa(e,C,i,i,i,t)});function Kc(e,t){if("function"!=typeof e)throw new at(l);return t=t===i?t:Wu(t),So(e,t)}function Wc(e,t){if("function"!=typeof e)throw new at(l);return t=null==t?0:jt(Wu(t),0),So(function(n){var r=n[t],i=zo(n,0,t);return r&&Tn(i,r),wn(e,this,i)})}function Xc(e,t,n){var r=!0,i=!0;if("function"!=typeof e)throw new at(l);return _u(n)&&(r="leading"in n?!!n.leading:r,i="trailing"in n?!!n.trailing:i),Bc(e,t,{leading:r,maxWait:t,trailing:i})}function Yc(e){return Nc(e,1)}function Zc(e,t){return qc(Ho(t),e)}function Jc(){if(!arguments.length)return[];var e=arguments[0];return cu(e)?e:[e]}function eu(e){return bi(e,g)}function tu(e,t){return t="function"==typeof t?t:i,bi(e,g,t)}function nu(e){return bi(e,f|g)}function ru(e,t){return t="function"==typeof t?t:i,bi(e,f|g,t)}function iu(e,t){return null==t||wi(e,t,Ed(t))}function ou(e,t){return e===t||e!==e&&t!==t}var au=Ca($i),su=Ca(function(e,t){return e>=t}),lu=qi(function(){return arguments}())?qi:function(e){return ku(e)&&ht.call(e,"callee")&&!_t.call(e,"callee")},cu=n.isArray,uu=fn?Xn(fn):Qi;function du(e){return null!=e&&xu(e.length)&&!Su(e)}function hu(e){return ku(e)&&du(e)}function pu(e){return!0===e||!1===e||ku(e)&&Bi(e)==z}var fu=Bt||Wh,mu=mn?Xn(mn):zi;function gu(e){return ku(e)&&1===e.nodeType&&!Du(e)}function vu(e){if(null==e)return!0;if(du(e)&&(cu(e)||"string"==typeof e||"function"==typeof e.splice||fu(e)||ju(e)||lu(e)))return!e.length;var t=Za(e);if(t==J||t==ae)return!e.size;if(fs(e))return!ro(e).length;for(var n in e)if(ht.call(e,n))return!1;return!0}function bu(e,t){return Ki(e,t)}function yu(e,t,n){n="function"==typeof n?n:i;var r=n?n(e,t):i;return r===i?Ki(e,t,i,n):!!r}function wu(e){if(!ku(e))return!1;var t=Bi(e);return t==X||t==W||"string"==typeof e.message&&"string"==typeof e.name&&!Du(e)}function Ou(e){return"number"==typeof e&&$t(e)}function Su(e){if(!_u(e))return!1;var t=Bi(e);return t==Y||t==Z||t==Q||t==ie}function Eu(e){return"number"==typeof e&&e==Wu(e)}function xu(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=B}function _u(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function ku(e){return null!=e&&"object"==typeof e}var Cu=gn?Xn(gn):Xi;function Au(e,t){return e===t||Yi(e,t,za(t))}function Tu(e,t,n){return n="function"==typeof n?n:i,Yi(e,t,za(t),n)}function Ru(e){return Mu(e)&&e!=+e}function Nu(e){if(ps(e))throw new Ve(s);return Zi(e)}function Pu(e){return null===e}function Iu(e){return null==e}function Mu(e){return"number"==typeof e||ku(e)&&Bi(e)==ee}function Du(e){if(!ku(e)||Bi(e)!=ne)return!1;var t=Et(e);if(null===t)return!0;var n=ht.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&dt.call(n)==gt}var Lu=vn?Xn(vn):Ji;function Bu(e){return Eu(e)&&e>=-B&&e<=B}var $u=bn?Xn(bn):eo;function Vu(e){return"string"==typeof e||!cu(e)&&ku(e)&&Bi(e)==se}function Fu(e){return"symbol"==typeof e||ku(e)&&Bi(e)==le}var ju=yn?Xn(yn):to;function Uu(e){return e===i}function Gu(e){return ku(e)&&Za(e)==ue}function Hu(e){return ku(e)&&Bi(e)==de}var qu=Ca(oo),Qu=Ca(function(e,t){return e<=t});function zu(e){if(!e)return[];if(du(e))return Vu(e)?vr(e):oa(e);if(At&&e[At])return lr(e[At]());var t=Za(e),n=t==J?cr:t==ae?hr:Ud;return n(e)}function Ku(e){if(!e)return 0===e?e:0;if(e=Yu(e),e===L||e===-L){var t=e<0?-1:1;return t*$}return e===e?e:0}function Wu(e){var t=Ku(e),n=t%1;return t===t?n?t-n:t:0}function Xu(e){return e?vi(Wu(e),0,F):0}function Yu(e){if("number"==typeof e)return e;if(Fu(e))return V;if(_u(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=_u(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=Wn(e);var n=We.test(e);return n||Ye.test(e)?on(e.slice(2),n?2:8):Ke.test(e)?V:+e}function Zu(e){return aa(e,xd(e))}function Ju(e){return e?vi(Wu(e),-B,B):0===e?e:0}function ed(e){return null==e?"":Do(e)}var td=ua(function(e,t){if(fs(t)||du(t))aa(t,Ed(t),e);else for(var n in t)ht.call(t,n)&&ui(e,n,t[n])}),nd=ua(function(e,t){aa(t,xd(t),e)}),rd=ua(function(e,t,n,r){aa(t,xd(t),e,r)}),id=ua(function(e,t,n,r){aa(t,Ed(t),e,r)}),od=Va(gi);function ad(e,t){var n=_r(e);return null==t?n:pi(n,t)}var sd=So(function(e,t){e=rt(e);var n=-1,r=t.length,o=r>2?t[2]:i;o&&ls(t[0],t[1],o)&&(r=1);while(++n<r){var a=t[n],s=xd(a),l=-1,c=s.length;while(++l<c){var u=s[l],d=e[u];(d===i||ou(d,ct[u])&&!ht.call(e,u))&&(e[u]=a[u])}}return e}),ld=So(function(e){return e.push(i,Ma),wn(Ad,i,e)});function cd(e,t){return Ln(e,qa(t,3),Pi)}function ud(e,t){return Ln(e,qa(t,3),Ii)}function dd(e,t){return null==e?e:Ri(e,qa(t,3),xd)}function hd(e,t){return null==e?e:Ni(e,qa(t,3),xd)}function pd(e,t){return e&&Pi(e,qa(t,3))}function fd(e,t){return e&&Ii(e,qa(t,3))}function md(e){return null==e?[]:Mi(e,Ed(e))}function gd(e){return null==e?[]:Mi(e,xd(e))}function vd(e,t,n){var r=null==e?i:Di(e,t);return r===i?n:r}function bd(e,t){return null!=e&&ts(e,t,Vi)}function yd(e,t){return null!=e&&ts(e,t,Fi)}var wd=Oa(function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=mt.call(t)),e[t]=n},Ch(Nh)),Od=Oa(function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=mt.call(t)),ht.call(e,t)?e[t].push(n):e[t]=[n]},qa),Sd=So(Hi);function Ed(e){return du(e)?oi(e):ro(e)}function xd(e){return du(e)?oi(e,!0):io(e)}function _d(e,t){var n={};return t=qa(t,3),Pi(e,function(e,r,i){mi(n,t(e,r,i),e)}),n}function kd(e,t){var n={};return t=qa(t,3),Pi(e,function(e,r,i){mi(n,r,t(e,r,i))}),n}var Cd=ua(function(e,t,n){co(e,t,n)}),Ad=ua(function(e,t,n,r){co(e,t,n,r)}),Td=Va(function(e,t){var n={};if(null==e)return n;var r=!1;t=An(t,function(t){return t=qo(t,e),r||(r=t.length>1),t}),aa(e,ja(e),n),r&&(n=bi(n,f|m|g,Da));var i=t.length;while(i--)Bo(n,t[i]);return n});function Rd(e,t){return Pd(e,Uc(qa(t)))}var Nd=Va(function(e,t){return null==e?{}:fo(e,t)});function Pd(e,t){if(null==e)return{};var n=An(ja(e),function(e){return[e]});return t=qa(t),mo(e,n,function(e,n){return t(e,n[0])})}function Id(e,t,n){t=qo(t,e);var r=-1,o=t.length;o||(o=1,e=i);while(++r<o){var a=null==e?i:e[Ps(t[r])];a===i&&(r=o,a=n),e=Su(a)?a.call(e):a}return e}function Md(e,t,n){return null==e?e:_o(e,t,n)}function Dd(e,t,n,r){return r="function"==typeof r?r:i,null==e?e:_o(e,t,n,r)}var Ld=Na(Ed),Bd=Na(xd);function $d(e,t,n){var r=cu(e),i=r||fu(e)||ju(e);if(t=qa(t,4),null==n){var o=e&&e.constructor;n=i?r?new o:[]:_u(e)&&Su(o)?_r(Et(e)):{}}return(i?Sn:Pi)(e,function(e,r,i){return t(n,e,r,i)}),n}function Vd(e,t){return null==e||Bo(e,t)}function Fd(e,t,n){return null==e?e:$o(e,t,Ho(n))}function jd(e,t,n,r){return r="function"==typeof r?r:i,null==e?e:$o(e,t,Ho(n),r)}function Ud(e){return null==e?[]:Yn(e,Ed(e))}function Gd(e){return null==e?[]:Yn(e,xd(e))}function Hd(e,t,n){return n===i&&(n=t,t=i),n!==i&&(n=Yu(n),n=n===n?n:0),t!==i&&(t=Yu(t),t=t===t?t:0),vi(Yu(e),t,n)}function qd(e,t,n){return t=Ku(t),n===i?(n=t,t=0):n=Ku(n),e=Yu(e),ji(e,t,n)}function Qd(e,t,n){if(n&&"boolean"!=typeof n&&ls(e,t,n)&&(t=n=i),n===i&&("boolean"==typeof t?(n=t,t=i):"boolean"==typeof e&&(n=e,e=i)),e===i&&t===i?(e=0,t=1):(e=Ku(e),t===i?(t=e,e=0):t=Ku(t)),e>t){var r=e;e=t,t=r}if(n||e%1||t%1){var o=zt();return Ut(e+o*(t-e+rn("1e-"+((o+"").length-1))),t)}return yo(e,t)}var zd=ma(function(e,t,n){return t=t.toLowerCase(),e+(n?Kd(t):t)});function Kd(e){return Oh(ed(e).toLowerCase())}function Wd(e){return e=ed(e),e&&e.replace(Je,nr).replace(Ht,"")}function Xd(e,t,n){e=ed(e),t=Do(t);var r=e.length;n=n===i?r:vi(Wu(n),0,r);var o=n;return n-=t.length,n>=0&&e.slice(n,o)==t}function Yd(e){return e=ed(e),e&&Te.test(e)?e.replace(Ce,rr):e}function Zd(e){return e=ed(e),e&&Be.test(e)?e.replace(Le,"\\$&"):e}var Jd=ma(function(e,t,n){return e+(n?"-":"")+t.toLowerCase()}),eh=ma(function(e,t,n){return e+(n?" ":"")+t.toLowerCase()}),th=fa("toLowerCase");function nh(e,t,n){e=ed(e),t=Wu(t);var r=t?gr(e):0;if(!t||r>=t)return e;var i=(t-r)/2;return xa(Dt(i),n)+e+xa(Mt(i),n)}function rh(e,t,n){e=ed(e),t=Wu(t);var r=t?gr(e):0;return t&&r<t?e+xa(t-r,n):e}function ih(e,t,n){e=ed(e),t=Wu(t);var r=t?gr(e):0;return t&&r<t?xa(t-r,n)+e:e}function oh(e,t,n){return n||null==t?t=0:t&&(t=+t),Qt(ed(e).replace($e,""),t||0)}function ah(e,t,n){return t=(n?ls(e,t,n):t===i)?1:Wu(t),Oo(ed(e),t)}function sh(){var e=arguments,t=ed(e[0]);return e.length<3?t:t.replace(e[1],e[2])}var lh=ma(function(e,t,n){return e+(n?"_":"")+t.toLowerCase()});function ch(e,t,n){return n&&"number"!=typeof n&&ls(e,t,n)&&(t=n=i),n=n===i?F:n>>>0,n?(e=ed(e),e&&("string"==typeof t||null!=t&&!Lu(t))&&(t=Do(t),!t&&ar(e))?zo(vr(e),0,n):e.split(t,n)):[]}var uh=ma(function(e,t,n){return e+(n?" ":"")+Oh(t)});function dh(e,t,n){return e=ed(e),n=null==n?0:vi(Wu(n),0,e.length),t=Do(t),e.slice(n,n+t.length)==t}function hh(e,t,n){var r=Er.templateSettings;n&&ls(e,t,n)&&(t=i),e=ed(e),t=id({},t,r,Ia);var o=id({},t.imports,r.imports,Ia),a=Ed(o),s=Yn(o,a);Sn(a,function(e){if(He.test(e))throw new Ve(u)});var l,d,h=0,p=t.interpolate||et,f="__p += '",m=it((t.escape||et).source+"|"+p.source+"|"+(p===Pe?Qe:et).source+"|"+(t.evaluate||et).source+"|$","g"),g="//# sourceURL="+(ht.call(t,"sourceURL")?(t.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++Xt+"]")+"\n";e.replace(m,function(t,n,r,i,o,a){return r||(r=i),f+=e.slice(h,a).replace(tt,ir),n&&(l=!0,f+="' +\n__e("+n+") +\n'"),o&&(d=!0,f+="';\n"+o+";\n__p += '"),r&&(f+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),h=a+t.length,t}),f+="';\n";var v=ht.call(t,"variable")&&t.variable;if(v){if(He.test(v))throw new Ve(c)}else f="with (obj) {\n"+f+"\n}\n";f=(d?f.replace(Ee,""):f).replace(xe,"$1").replace(_e,"$1;"),f="function("+(v||"obj")+") {\n"+(v?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(l?", __e = _.escape":"")+(d?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+f+"return __p\n}";var b=Eh(function(){return Ge(a,g+"return "+f).apply(i,s)});if(b.source=f,wu(b))throw b;return b}function ph(e){return ed(e).toLowerCase()}function fh(e){return ed(e).toUpperCase()}function mh(e,t,n){if(e=ed(e),e&&(n||t===i))return Wn(e);if(!e||!(t=Do(t)))return e;var r=vr(e),o=vr(t),a=Jn(r,o),s=er(r,o)+1;return zo(r,a,s).join("")}function gh(e,t,n){if(e=ed(e),e&&(n||t===i))return e.slice(0,br(e)+1);if(!e||!(t=Do(t)))return e;var r=vr(e),o=er(r,vr(t))+1;return zo(r,0,o).join("")}function vh(e,t,n){if(e=ed(e),e&&(n||t===i))return e.replace($e,"");if(!e||!(t=Do(t)))return e;var r=vr(e),o=Jn(r,vr(t));return zo(r,o).join("")}function bh(e,t){var n=T,r=R;if(_u(t)){var o="separator"in t?t.separator:o;n="length"in t?Wu(t.length):n,r="omission"in t?Do(t.omission):r}e=ed(e);var a=e.length;if(ar(e)){var s=vr(e);a=s.length}if(n>=a)return e;var l=n-gr(r);if(l<1)return r;var c=s?zo(s,0,l).join(""):e.slice(0,l);if(o===i)return c+r;if(s&&(l+=c.length-l),Lu(o)){if(e.slice(l).search(o)){var u,d=c;o.global||(o=it(o.source,ed(ze.exec(o))+"g")),o.lastIndex=0;while(u=o.exec(d))var h=u.index;c=c.slice(0,h===i?l:h)}}else if(e.indexOf(Do(o),l)!=l){var p=c.lastIndexOf(o);p>-1&&(c=c.slice(0,p))}return c+r}function yh(e){return e=ed(e),e&&Ae.test(e)?e.replace(ke,yr):e}var wh=ma(function(e,t,n){return e+(n?" ":"")+t.toUpperCase()}),Oh=fa("toUpperCase");function Sh(e,t,n){return e=ed(e),t=n?i:t,t===i?sr(e)?Sr(e):Dn(e):e.match(t)||[]}var Eh=So(function(e,t){try{return wn(e,i,t)}catch(n){return wu(n)?n:new Ve(n)}}),xh=Va(function(e,t){return Sn(t,function(t){t=Ps(t),mi(e,t,Ic(e[t],e))}),e});function _h(e){var t=null==e?0:e.length,n=qa();return e=t?An(e,function(e){if("function"!=typeof e[1])throw new at(l);return[n(e[0]),e[1]]}):[],So(function(n){var r=-1;while(++r<t){var i=e[r];if(wn(i[0],this,n))return wn(i[1],this,n)}})}function kh(e){return yi(bi(e,f))}function Ch(e){return function(){return e}}function Ah(e,t){return null==e||e!==e?t:e}var Th=ya(),Rh=ya(!0);function Nh(e){return e}function Ph(e){return no("function"==typeof e?e:bi(e,f))}function Ih(e){return so(bi(e,f))}function Mh(e,t){return lo(e,bi(t,f))}var Dh=So(function(e,t){return function(n){return Hi(n,e,t)}}),Lh=So(function(e,t){return function(n){return Hi(e,n,t)}});function Bh(e,t,n){var r=Ed(t),i=Mi(t,r);null!=n||_u(t)&&(i.length||!r.length)||(n=t,t=e,e=this,i=Mi(t,Ed(t)));var o=!(_u(n)&&"chain"in n)||!!n.chain,a=Su(e);return Sn(i,function(n){var r=t[n];e[n]=r,a&&(e.prototype[n]=function(){var t=this.__chain__;if(o||t){var n=e(this.__wrapped__),i=n.__actions__=oa(this.__actions__);return i.push({func:r,args:arguments,thisArg:e}),n.__chain__=t,n}return r.apply(e,Tn([this.value()],arguments))})}),e}function $h(){return ln._===this&&(ln._=vt),this}function Vh(){}function Fh(e){return e=Wu(e),So(function(t){return ho(t,e)})}var jh=Ea(An),Uh=Ea(xn),Gh=Ea(Pn);function Hh(e){return cs(e)?Un(Ps(e)):go(e)}function qh(e){return function(t){return null==e?i:Di(e,t)}}var Qh=ka(),zh=ka(!0);function Kh(){return[]}function Wh(){return!1}function Xh(){return{}}function Yh(){return""}function Zh(){return!0}function Jh(e,t){if(e=Wu(e),e<1||e>B)return[];var n=F,r=Ut(e,F);t=qa(t),e-=F;var i=zn(r,t);while(++n<e)t(n);return i}function ep(e){return cu(e)?An(e,Ps):Fu(e)?[e]:oa(Ns(ed(e)))}function tp(e){var t=++pt;return ed(e)+t}var np=Sa(function(e,t){return e+t},0),rp=Ta("ceil"),ip=Sa(function(e,t){return e/t},1),op=Ta("floor");function ap(e){return e&&e.length?ki(e,Nh,$i):i}function sp(e,t){return e&&e.length?ki(e,qa(t,2),$i):i}function lp(e){return jn(e,Nh)}function cp(e,t){return jn(e,qa(t,2))}function up(e){return e&&e.length?ki(e,Nh,oo):i}function dp(e,t){return e&&e.length?ki(e,qa(t,2),oo):i}var hp=Sa(function(e,t){return e*t},1),pp=Ta("round"),fp=Sa(function(e,t){return e-t},0);function mp(e){return e&&e.length?Qn(e,Nh):0}function gp(e,t){return e&&e.length?Qn(e,qa(t,2)):0}return Er.after=Rc,Er.ary=Nc,Er.assign=td,Er.assignIn=nd,Er.assignInWith=rd,Er.assignWith=id,Er.at=od,Er.before=Pc,Er.bind=Ic,Er.bindAll=xh,Er.bindKey=Mc,Er.castArray=Jc,Er.chain=Ql,Er.chunk=Ls,Er.compact=Bs,Er.concat=$s,Er.cond=_h,Er.conforms=kh,Er.constant=Ch,Er.countBy=rc,Er.create=ad,Er.curry=Dc,Er.curryRight=Lc,Er.debounce=Bc,Er.defaults=sd,Er.defaultsDeep=ld,Er.defer=$c,Er.delay=Vc,Er.difference=Vs,Er.differenceBy=Fs,Er.differenceWith=js,Er.drop=Us,Er.dropRight=Gs,Er.dropRightWhile=Hs,Er.dropWhile=qs,Er.fill=Qs,Er.filter=oc,Er.flatMap=lc,Er.flatMapDeep=cc,Er.flatMapDepth=uc,Er.flatten=Ws,Er.flattenDeep=Xs,Er.flattenDepth=Ys,Er.flip=Fc,Er.flow=Th,Er.flowRight=Rh,Er.fromPairs=Zs,Er.functions=md,Er.functionsIn=gd,Er.groupBy=pc,Er.initial=tl,Er.intersection=nl,Er.intersectionBy=rl,Er.intersectionWith=il,Er.invert=wd,Er.invertBy=Od,Er.invokeMap=mc,Er.iteratee=Ph,Er.keyBy=gc,Er.keys=Ed,Er.keysIn=xd,Er.map=vc,Er.mapKeys=_d,Er.mapValues=kd,Er.matches=Ih,Er.matchesProperty=Mh,Er.memoize=jc,Er.merge=Cd,Er.mergeWith=Ad,Er.method=Dh,Er.methodOf=Lh,Er.mixin=Bh,Er.negate=Uc,Er.nthArg=Fh,Er.omit=Td,Er.omitBy=Rd,Er.once=Gc,Er.orderBy=bc,Er.over=jh,Er.overArgs=Hc,Er.overEvery=Uh,Er.overSome=Gh,Er.partial=qc,Er.partialRight=Qc,Er.partition=yc,Er.pick=Nd,Er.pickBy=Pd,Er.property=Hh,Er.propertyOf=qh,Er.pull=cl,Er.pullAll=ul,Er.pullAllBy=dl,Er.pullAllWith=hl,Er.pullAt=pl,Er.range=Qh,Er.rangeRight=zh,Er.rearg=zc,Er.reject=Sc,Er.remove=fl,Er.rest=Kc,Er.reverse=ml,Er.sampleSize=xc,Er.set=Md,Er.setWith=Dd,Er.shuffle=_c,Er.slice=gl,Er.sortBy=Ac,Er.sortedUniq=El,Er.sortedUniqBy=xl,Er.split=ch,Er.spread=Wc,Er.tail=_l,Er.take=kl,Er.takeRight=Cl,Er.takeRightWhile=Al,Er.takeWhile=Tl,Er.tap=zl,Er.throttle=Xc,Er.thru=Kl,Er.toArray=zu,Er.toPairs=Ld,Er.toPairsIn=Bd,Er.toPath=ep,Er.toPlainObject=Zu,Er.transform=$d,Er.unary=Yc,Er.union=Rl,Er.unionBy=Nl,Er.unionWith=Pl,Er.uniq=Il,Er.uniqBy=Ml,Er.uniqWith=Dl,Er.unset=Vd,Er.unzip=Ll,Er.unzipWith=Bl,Er.update=Fd,Er.updateWith=jd,Er.values=Ud,Er.valuesIn=Gd,Er.without=$l,Er.words=Sh,Er.wrap=Zc,Er.xor=Vl,Er.xorBy=Fl,Er.xorWith=jl,Er.zip=Ul,Er.zipObject=Gl,Er.zipObjectDeep=Hl,Er.zipWith=ql,Er.entries=Ld,Er.entriesIn=Bd,Er.extend=nd,Er.extendWith=rd,Bh(Er,Er),Er.add=np,Er.attempt=Eh,Er.camelCase=zd,Er.capitalize=Kd,Er.ceil=rp,Er.clamp=Hd,Er.clone=eu,Er.cloneDeep=nu,Er.cloneDeepWith=ru,Er.cloneWith=tu,Er.conformsTo=iu,Er.deburr=Wd,Er.defaultTo=Ah,Er.divide=ip,Er.endsWith=Xd,Er.eq=ou,Er.escape=Yd,Er.escapeRegExp=Zd,Er.every=ic,Er.find=ac,Er.findIndex=zs,Er.findKey=cd,Er.findLast=sc,Er.findLastIndex=Ks,Er.findLastKey=ud,Er.floor=op,Er.forEach=dc,Er.forEachRight=hc,Er.forIn=dd,Er.forInRight=hd,Er.forOwn=pd,Er.forOwnRight=fd,Er.get=vd,Er.gt=au,Er.gte=su,Er.has=bd,Er.hasIn=yd,Er.head=Js,Er.identity=Nh,Er.includes=fc,Er.indexOf=el,Er.inRange=qd,Er.invoke=Sd,Er.isArguments=lu,Er.isArray=cu,Er.isArrayBuffer=uu,Er.isArrayLike=du,Er.isArrayLikeObject=hu,Er.isBoolean=pu,Er.isBuffer=fu,Er.isDate=mu,Er.isElement=gu,Er.isEmpty=vu,Er.isEqual=bu,Er.isEqualWith=yu,Er.isError=wu,Er.isFinite=Ou,Er.isFunction=Su,Er.isInteger=Eu,Er.isLength=xu,Er.isMap=Cu,Er.isMatch=Au,Er.isMatchWith=Tu,Er.isNaN=Ru,Er.isNative=Nu,Er.isNil=Iu,Er.isNull=Pu,Er.isNumber=Mu,Er.isObject=_u,Er.isObjectLike=ku,Er.isPlainObject=Du,Er.isRegExp=Lu,Er.isSafeInteger=Bu,Er.isSet=$u,Er.isString=Vu,Er.isSymbol=Fu,Er.isTypedArray=ju,Er.isUndefined=Uu,Er.isWeakMap=Gu,Er.isWeakSet=Hu,Er.join=ol,Er.kebabCase=Jd,Er.last=al,Er.lastIndexOf=sl,Er.lowerCase=eh,Er.lowerFirst=th,Er.lt=qu,Er.lte=Qu,Er.max=ap,Er.maxBy=sp,Er.mean=lp,Er.meanBy=cp,Er.min=up,Er.minBy=dp,Er.stubArray=Kh,Er.stubFalse=Wh,Er.stubObject=Xh,Er.stubString=Yh,Er.stubTrue=Zh,Er.multiply=hp,Er.nth=ll,Er.noConflict=$h,Er.noop=Vh,Er.now=Tc,Er.pad=nh,Er.padEnd=rh,Er.padStart=ih,Er.parseInt=oh,Er.random=Qd,Er.reduce=wc,Er.reduceRight=Oc,Er.repeat=ah,Er.replace=sh,Er.result=Id,Er.round=pp,Er.runInContext=e,Er.sample=Ec,Er.size=kc,Er.snakeCase=lh,Er.some=Cc,Er.sortedIndex=vl,Er.sortedIndexBy=bl,Er.sortedIndexOf=yl,Er.sortedLastIndex=wl,Er.sortedLastIndexBy=Ol,Er.sortedLastIndexOf=Sl,Er.startCase=uh,Er.startsWith=dh,Er.subtract=fp,Er.sum=mp,Er.sumBy=gp,Er.template=hh,Er.times=Jh,Er.toFinite=Ku,Er.toInteger=Wu,Er.toLength=Xu,Er.toLower=ph,Er.toNumber=Yu,Er.toSafeInteger=Ju,Er.toString=ed,Er.toUpper=fh,Er.trim=mh,Er.trimEnd=gh,Er.trimStart=vh,Er.truncate=bh,Er.unescape=yh,Er.uniqueId=tp,Er.upperCase=wh,Er.upperFirst=Oh,Er.each=dc,Er.eachRight=hc,Er.first=Js,Bh(Er,function(){var e={};return Pi(Er,function(t,n){ht.call(Er.prototype,n)||(e[n]=t)}),e}(),{chain:!1}),Er.VERSION=o,Sn(["bind","bindKey","curry","curryRight","partial","partialRight"],function(e){Er[e].placeholder=Er}),Sn(["drop","take"],function(e,t){Ar.prototype[e]=function(n){n=n===i?1:jt(Wu(n),0);var r=this.__filtered__&&!t?new Ar(this):this.clone();return r.__filtered__?r.__takeCount__=Ut(n,r.__takeCount__):r.__views__.push({size:Ut(n,F),type:e+(r.__dir__<0?"Right":"")}),r},Ar.prototype[e+"Right"]=function(t){return this.reverse()[e](t).reverse()}}),Sn(["filter","map","takeWhile"],function(e,t){var n=t+1,r=n==I||n==D;Ar.prototype[e]=function(e){var t=this.clone();return t.__iteratees__.push({iteratee:qa(e,3),type:n}),t.__filtered__=t.__filtered__||r,t}}),Sn(["head","last"],function(e,t){var n="take"+(t?"Right":"");Ar.prototype[e]=function(){return this[n](1).value()[0]}}),Sn(["initial","tail"],function(e,t){var n="drop"+(t?"":"Right");Ar.prototype[e]=function(){return this.__filtered__?new Ar(this):this[n](1)}}),Ar.prototype.compact=function(){return this.filter(Nh)},Ar.prototype.find=function(e){return this.filter(e).head()},Ar.prototype.findLast=function(e){return this.reverse().find(e)},Ar.prototype.invokeMap=So(function(e,t){return"function"==typeof e?new Ar(this):this.map(function(n){return Hi(n,e,t)})}),Ar.prototype.reject=function(e){return this.filter(Uc(qa(e)))},Ar.prototype.slice=function(e,t){e=Wu(e);var n=this;return n.__filtered__&&(e>0||t<0)?new Ar(n):(e<0?n=n.takeRight(-e):e&&(n=n.drop(e)),t!==i&&(t=Wu(t),n=t<0?n.dropRight(-t):n.take(t-e)),n)},Ar.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},Ar.prototype.toArray=function(){return this.take(F)},Pi(Ar.prototype,function(e,t){var n=/^(?:filter|find|map|reject)|While$/.test(t),r=/^(?:head|last)$/.test(t),o=Er[r?"take"+("last"==t?"Right":""):t],a=r||/^find/.test(t);o&&(Er.prototype[t]=function(){var t=this.__wrapped__,s=r?[1]:arguments,l=t instanceof Ar,c=s[0],u=l||cu(t),d=function(e){var t=o.apply(Er,Tn([e],s));return r&&h?t[0]:t};u&&n&&"function"==typeof c&&1!=c.length&&(l=u=!1);var h=this.__chain__,p=!!this.__actions__.length,f=a&&!h,m=l&&!p;if(!a&&u){t=m?t:new Ar(this);var g=e.apply(t,s);return g.__actions__.push({func:Kl,args:[d],thisArg:i}),new Cr(g,h)}return f&&m?e.apply(this,s):(g=this.thru(d),f?r?g.value()[0]:g.value():g)})}),Sn(["pop","push","shift","sort","splice","unshift"],function(e){var t=st[e],n=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",r=/^(?:pop|shift)$/.test(e);Er.prototype[e]=function(){var e=arguments;if(r&&!this.__chain__){var i=this.value();return t.apply(cu(i)?i:[],e)}return this[n](function(n){return t.apply(cu(n)?n:[],e)})}}),Pi(Ar.prototype,function(e,t){var n=Er[t];if(n){var r=n.name+"";ht.call(un,r)||(un[r]=[]),un[r].push({name:t,func:n})}}),un[wa(i,w).name]=[{name:"wrapper",func:i}],Ar.prototype.clone=Tr,Ar.prototype.reverse=Rr,Ar.prototype.value=Nr,Er.prototype.at=Wl,Er.prototype.chain=Xl,Er.prototype.commit=Yl,Er.prototype.next=Zl,Er.prototype.plant=ec,Er.prototype.reverse=tc,Er.prototype.toJSON=Er.prototype.valueOf=Er.prototype.value=nc,Er.prototype.first=Er.prototype.head,At&&(Er.prototype[At]=Jl),Er},xr=Er();ln._=xr,r=function(){return xr}.call(t,n,t,e),r===i||(e.exports=r)}.call(this)},69011:function(e,t,n){var r=n(68250),i="Expected a function";function o(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new TypeError(i);var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var a=e.apply(this,r);return n.cache=o.set(i,a)||o,a};return n.cache=new(o.Cache||r),n}o.Cache=r,e.exports=o},82451:function(e,t,n){var r=n(40091),i=n(77848),o=i(function(e,t,n){r(e,t,n)});e.exports=o},48875:function(e,t,n){var r=n(40091),i=n(77848),o=i(function(e,t,n,i){r(e,t,n,i)});e.exports=o},21517:function(e){var t="Expected a function";function n(e){if("function"!=typeof e)throw new TypeError(t);return function(){var t=arguments;switch(t.length){case 0:return!e.call(this);case 1:return!e.call(this,t[0]);case 2:return!e.call(this,t[0],t[1]);case 3:return!e.call(this,t[0],t[1],t[2])}return!e.apply(this,t)}}e.exports=n},79071:function(e){function t(){}e.exports=t},94495:function(e,t,n){var r=n(78942),i=function(){return r.Date.now()};e.exports=i},38403:function(e,t,n){var r=n(3334),i=n(21517),o=n(16735);function a(e,t){return o(e,i(r(t)))}e.exports=a},74874:function(e,t,n){var r=n(90242),i=n(41439),o=i(function(e,t){return null==e?{}:r(e,t)});e.exports=o},16735:function(e,t,n){var r=n(65111),i=n(3334),o=n(35031),a=n(93650);function s(e,t){if(null==e)return{};var n=r(a(e),function(e){return[e]});return t=i(t),o(e,n,function(e,n){return t(e,n[0])})}e.exports=s},43282:function(e,t,n){var r=n(12762),i=n(98880),o=n(65187),a=n(66040);function s(e){return o(e)?r(a(e)):i(e)}e.exports=s},95479:function(e,t,n){var r=n(93640),i=n(5485),o=r(function(e,t,n){return e+(n?" ":"")+i(t)});e.exports=o},99306:function(e){function t(){return[]}e.exports=t},34772:function(e){function t(){return!1}e.exports=t},97331:function(e,t,n){var r=n(12784),i=n(41580),o="Expected a function";function a(e,t,n){var a=!0,s=!0;if("function"!=typeof e)throw new TypeError(o);return i(n)&&(a="leading"in n?!!n.leading:a,s="trailing"in n?!!n.trailing:s),r(e,t,{leading:a,maxWait:t,trailing:s})}e.exports=a},43301:function(e,t,n){var r=n(6131),i=1/0,o=17976931348623157e292;function a(e){if(!e)return 0===e?e:0;if(e=r(e),e===i||e===-i){var t=e<0?-1:1;return t*o}return e===e?e:0}e.exports=a},67642:function(e,t,n){var r=n(43301);function i(e){var t=r(e),n=t%1;return t===t?n?t-n:t:0}e.exports=i},6131:function(e,t,n){var r=n(86403),i=n(41580),o=n(51187),a=NaN,s=/^[-+]0x[0-9a-f]+$/i,l=/^0b[01]+$/i,c=/^0o[0-7]+$/i,u=parseInt;function d(e){if("number"==typeof e)return e;if(o(e))return a;if(i(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=i(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=r(e);var n=l.test(e);return n||c.test(e)?u(e.slice(2),n?2:8):s.test(e)?a:+e}e.exports=d},64207:function(e,t,n){var r=n(39032),i=n(25288);function o(e){return r(e,i(e))}e.exports=o},95243:function(e,t,n){var r=n(52291);function i(e){return null==e?"":r(e)}e.exports=i},2011:function(e,t,n){var r=n(79968),i=n(39747),o=n(47170),a=n(3334),s=n(74784),l=n(53142),c=n(75853),u=n(93655),d=n(41580),h=n(8666);function p(e,t,n){var p=l(e),f=p||c(e)||h(e);if(t=a(t,4),null==n){var m=e&&e.constructor;n=f?p?new m:[]:d(e)&&u(m)?i(s(e)):{}}return(f?r:o)(e,function(e,r,i){return t(n,e,r,i)}),n}e.exports=p},82438:function(e,t,n){var r=n(15630);function i(e){return e&&e.length?r(e):[]}e.exports=i},5485:function(e,t,n){var r=n(4326),i=r("toUpperCase");e.exports=i},39817:function(e,t,n){var r=n(3905),i=n(81211);function o(e){return null==e?[]:r(e,i(e))}e.exports=o},39850:function(e,t,n){var r=n(39546),i=n(15813),o=n(95243),a=n(10482);function s(e,t,n){return e=o(e),t=n?void 0:t,void 0===t?i(e)?a(e):r(e):e.match(t)||[]}e.exports=s},13182:function(e,t,n){var r=n(79847),i=n(23945),o=n(80214),a=n(65406),s=i(function(e){return o(r(e,a))});e.exports=s},58479:function(e){"use strict";e.exports=Math.abs},18449:function(e){"use strict";e.exports=Math.floor},62422:function(e){"use strict";e.exports=Number.isNaN||function(e){return e!==e}},88129:function(e){"use strict";e.exports=Math.max},22387:function(e){"use strict";e.exports=Math.min},85865:function(e){"use strict";e.exports=Math.pow},1319:function(e){"use strict";e.exports=Math.round},36882:function(e,t,n){"use strict";var r=n(62422);e.exports=function(e){return r(e)||0===e?e:e<0?-1:1}},48660:function(e,t,n){var r="function"===typeof Map&&Map.prototype,i=Object.getOwnPropertyDescriptor&&r?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,o=r&&i&&"function"===typeof i.get?i.get:null,a=r&&Map.prototype.forEach,s="function"===typeof Set&&Set.prototype,l=Object.getOwnPropertyDescriptor&&s?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,c=s&&l&&"function"===typeof l.get?l.get:null,u=s&&Set.prototype.forEach,d="function"===typeof WeakMap&&WeakMap.prototype,h=d?WeakMap.prototype.has:null,p="function"===typeof WeakSet&&WeakSet.prototype,f=p?WeakSet.prototype.has:null,m="function"===typeof WeakRef&&WeakRef.prototype,g=m?WeakRef.prototype.deref:null,v=Boolean.prototype.valueOf,b=Object.prototype.toString,y=Function.prototype.toString,w=String.prototype.match,O=String.prototype.slice,S=String.prototype.replace,E=String.prototype.toUpperCase,x=String.prototype.toLowerCase,_=RegExp.prototype.test,k=Array.prototype.concat,C=Array.prototype.join,A=Array.prototype.slice,T=Math.floor,R="function"===typeof BigInt?BigInt.prototype.valueOf:null,N=Object.getOwnPropertySymbols,P="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?Symbol.prototype.toString:null,I="function"===typeof Symbol&&"object"===typeof Symbol.iterator,M="function"===typeof Symbol&&Symbol.toStringTag&&(typeof Symbol.toStringTag===I||"symbol")?Symbol.toStringTag:null,D=Object.prototype.propertyIsEnumerable,L=("function"===typeof Reflect?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(e){return e.__proto__}:null);function B(e,t){if(e===1/0||e===-1/0||e!==e||e&&e>-1e3&&e<1e3||_.call(/e/,t))return t;var n=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if("number"===typeof e){var r=e<0?-T(-e):T(e);if(r!==e){var i=String(r),o=O.call(t,i.length+1);return S.call(i,n,"$&_")+"."+S.call(S.call(o,/([0-9]{3})/g,"$&_"),/_$/,"")}}return S.call(t,n,"$&_")}var $=n(86973),V=$.custom,F=J(V)?V:null,j={__proto__:null,double:'"',single:"'"},U={__proto__:null,double:/(["\\])/g,single:/(['\\])/g};function G(e,t,n){var r=n.quoteStyle||t,i=j[r];return i+e+i}function H(e){return S.call(String(e),/"/g,""")}function q(e){return!M||!("object"===typeof e&&(M in e||"undefined"!==typeof e[M]))}function Q(e){return"[object Array]"===re(e)&&q(e)}function z(e){return"[object Date]"===re(e)&&q(e)}function K(e){return"[object RegExp]"===re(e)&&q(e)}function W(e){return"[object Error]"===re(e)&&q(e)}function X(e){return"[object String]"===re(e)&&q(e)}function Y(e){return"[object Number]"===re(e)&&q(e)}function Z(e){return"[object Boolean]"===re(e)&&q(e)}function J(e){if(I)return e&&"object"===typeof e&&e instanceof Symbol;if("symbol"===typeof e)return!0;if(!e||"object"!==typeof e||!P)return!1;try{return P.call(e),!0}catch(t){}return!1}function ee(e){if(!e||"object"!==typeof e||!R)return!1;try{return R.call(e),!0}catch(t){}return!1}e.exports=function e(t,r,i,s){var l=r||{};if(ne(l,"quoteStyle")&&!ne(j,l.quoteStyle))throw new TypeError('option "quoteStyle" must be "single" or "double"');if(ne(l,"maxStringLength")&&("number"===typeof l.maxStringLength?l.maxStringLength<0&&l.maxStringLength!==1/0:null!==l.maxStringLength))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var d=!ne(l,"customInspect")||l.customInspect;if("boolean"!==typeof d&&"symbol"!==d)throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(ne(l,"indent")&&null!==l.indent&&"\t"!==l.indent&&!(parseInt(l.indent,10)===l.indent&&l.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(ne(l,"numericSeparator")&&"boolean"!==typeof l.numericSeparator)throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var h=l.numericSeparator;if("undefined"===typeof t)return"undefined";if(null===t)return"null";if("boolean"===typeof t)return t?"true":"false";if("string"===typeof t)return he(t,l);if("number"===typeof t){if(0===t)return 1/0/t>0?"0":"-0";var p=String(t);return h?B(t,p):p}if("bigint"===typeof t){var f=String(t)+"n";return h?B(t,f):f}var m="undefined"===typeof l.depth?5:l.depth;if("undefined"===typeof i&&(i=0),i>=m&&m>0&&"object"===typeof t)return Q(t)?"[Array]":"[Object]";var g=be(l,i);if("undefined"===typeof s)s=[];else if(oe(s,t)>=0)return"[Circular]";function b(t,n,r){if(n&&(s=A.call(s),s.push(n)),r){var o={depth:l.depth};return ne(l,"quoteStyle")&&(o.quoteStyle=l.quoteStyle),e(t,o,i+1,s)}return e(t,l,i+1,s)}if("function"===typeof t&&!K(t)){var y=ie(t),w=we(t,b);return"[Function"+(y?": "+y:" (anonymous)")+"]"+(w.length>0?" { "+C.call(w,", ")+" }":"")}if(J(t)){var E=I?S.call(String(t),/^(Symbol\(.*\))_[^)]*$/,"$1"):P.call(t);return"object"!==typeof t||I?E:fe(E)}if(de(t)){for(var _="<"+x.call(String(t.nodeName)),T=t.attributes||[],N=0;N<T.length;N++)_+=" "+T[N].name+"="+G(H(T[N].value),"double",l);return _+=">",t.childNodes&&t.childNodes.length&&(_+="..."),_+="</"+x.call(String(t.nodeName))+">",_}if(Q(t)){if(0===t.length)return"[]";var V=we(t,b);return g&&!ve(V)?"["+ye(V,g)+"]":"[ "+C.call(V,", ")+" ]"}if(W(t)){var U=we(t,b);return"cause"in Error.prototype||!("cause"in t)||D.call(t,"cause")?0===U.length?"["+String(t)+"]":"{ ["+String(t)+"] "+C.call(U,", ")+" }":"{ ["+String(t)+"] "+C.call(k.call("[cause]: "+b(t.cause),U),", ")+" }"}if("object"===typeof t&&d){if(F&&"function"===typeof t[F]&&$)return $(t,{depth:m-i});if("symbol"!==d&&"function"===typeof t.inspect)return t.inspect()}if(ae(t)){var q=[];return a&&a.call(t,function(e,n){q.push(b(n,t,!0)+" => "+b(e,t))}),ge("Map",o.call(t),q,g)}if(ce(t)){var te=[];return u&&u.call(t,function(e){te.push(b(e,t))}),ge("Set",c.call(t),te,g)}if(se(t))return me("WeakMap");if(ue(t))return me("WeakSet");if(le(t))return me("WeakRef");if(Y(t))return fe(b(Number(t)));if(ee(t))return fe(b(R.call(t)));if(Z(t))return fe(v.call(t));if(X(t))return fe(b(String(t)));if("undefined"!==typeof window&&t===window)return"{ [object Window] }";if("undefined"!==typeof globalThis&&t===globalThis||"undefined"!==typeof n.g&&t===n.g)return"{ [object globalThis] }";if(!z(t)&&!K(t)){var pe=we(t,b),Oe=L?L(t)===Object.prototype:t instanceof Object||t.constructor===Object,Se=t instanceof Object?"":"null prototype",Ee=!Oe&&M&&Object(t)===t&&M in t?O.call(re(t),8,-1):Se?"Object":"",xe=Oe||"function"!==typeof t.constructor?"":t.constructor.name?t.constructor.name+" ":"",_e=xe+(Ee||Se?"["+C.call(k.call([],Ee||[],Se||[]),": ")+"] ":"");return 0===pe.length?_e+"{}":g?_e+"{"+ye(pe,g)+"}":_e+"{ "+C.call(pe,", ")+" }"}return String(t)};var te=Object.prototype.hasOwnProperty||function(e){return e in this};function ne(e,t){return te.call(e,t)}function re(e){return b.call(e)}function ie(e){if(e.name)return e.name;var t=w.call(y.call(e),/^function\s*([\w$]+)/);return t?t[1]:null}function oe(e,t){if(e.indexOf)return e.indexOf(t);for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1}function ae(e){if(!o||!e||"object"!==typeof e)return!1;try{o.call(e);try{c.call(e)}catch(t){return!0}return e instanceof Map}catch(n){}return!1}function se(e){if(!h||!e||"object"!==typeof e)return!1;try{h.call(e,h);try{f.call(e,f)}catch(t){return!0}return e instanceof WeakMap}catch(n){}return!1}function le(e){if(!g||!e||"object"!==typeof e)return!1;try{return g.call(e),!0}catch(t){}return!1}function ce(e){if(!c||!e||"object"!==typeof e)return!1;try{c.call(e);try{o.call(e)}catch(t){return!0}return e instanceof Set}catch(n){}return!1}function ue(e){if(!f||!e||"object"!==typeof e)return!1;try{f.call(e,f);try{h.call(e,h)}catch(t){return!0}return e instanceof WeakSet}catch(n){}return!1}function de(e){return!(!e||"object"!==typeof e)&&("undefined"!==typeof HTMLElement&&e instanceof HTMLElement||"string"===typeof e.nodeName&&"function"===typeof e.getAttribute)}function he(e,t){if(e.length>t.maxStringLength){var n=e.length-t.maxStringLength,r="... "+n+" more character"+(n>1?"s":"");return he(O.call(e,0,t.maxStringLength),t)+r}var i=U[t.quoteStyle||"single"];i.lastIndex=0;var o=S.call(S.call(e,i,"\\$1"),/[\x00-\x1f]/g,pe);return G(o,"single",t)}function pe(e){var t=e.charCodeAt(0),n={8:"b",9:"t",10:"n",12:"f",13:"r"}[t];return n?"\\"+n:"\\x"+(t<16?"0":"")+E.call(t.toString(16))}function fe(e){return"Object("+e+")"}function me(e){return e+" { ? }"}function ge(e,t,n,r){var i=r?ye(n,r):C.call(n,", ");return e+" ("+t+") {"+i+"}"}function ve(e){for(var t=0;t<e.length;t++)if(oe(e[t],"\n")>=0)return!1;return!0}function be(e,t){var n;if("\t"===e.indent)n="\t";else{if(!("number"===typeof e.indent&&e.indent>0))return null;n=C.call(Array(e.indent+1)," ")}return{base:n,prev:C.call(Array(t+1),n)}}function ye(e,t){if(0===e.length)return"";var n="\n"+t.prev+t.base;return n+C.call(e,","+n)+"\n"+t.prev}function we(e,t){var n=Q(e),r=[];if(n){r.length=e.length;for(var i=0;i<e.length;i++)r[i]=ne(e,i)?t(e[i],e):""}var o,a="function"===typeof N?N(e):[];if(I){o={};for(var s=0;s<a.length;s++)o["$"+a[s]]=a[s]}for(var l in e)ne(e,l)&&(n&&String(Number(l))===l&&l<e.length||I&&o["$"+l]instanceof Symbol||(_.call(/[^\w$]/,l)?r.push(t(l,e)+": "+t(e[l],e)):r.push(l+": "+t(e[l],e))));if("function"===typeof N)for(var c=0;c<a.length;c++)D.call(e,a[c])&&r.push("["+t(a[c])+"]: "+t(e[a[c]],e));return r}},82372:function(e){"use strict";var t=function(e){return e!==e};e.exports=function(e,n){return 0===e&&0===n?1/e===1/n:e===n||!(!t(e)||!t(n))}},55968:function(e,t,n){"use strict";var r=n(41857),i=n(28498),o=n(82372),a=n(61937),s=n(85087),l=i(a(),Object);r(l,{getPolyfill:a,implementation:o,shim:s}),e.exports=l},61937:function(e,t,n){"use strict";var r=n(82372);e.exports=function(){return"function"===typeof Object.is?Object.is:r}},85087:function(e,t,n){"use strict";var r=n(61937),i=n(41857);e.exports=function(){var e=r();return i(Object,{is:e},{is:function(){return Object.is!==e}}),e}},78160:function(e,t,n){"use strict";var r;if(!Object.keys){var i=Object.prototype.hasOwnProperty,o=Object.prototype.toString,a=n(50968),s=Object.prototype.propertyIsEnumerable,l=!s.call({toString:null},"toString"),c=s.call(function(){},"prototype"),u=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],d=function(e){var t=e.constructor;return t&&t.prototype===e},h={$applicationCache:!0,$console:!0,$external:!0,$frame:!0,$frameElement:!0,$frames:!0,$innerHeight:!0,$innerWidth:!0,$onmozfullscreenchange:!0,$onmozfullscreenerror:!0,$outerHeight:!0,$outerWidth:!0,$pageXOffset:!0,$pageYOffset:!0,$parent:!0,$scrollLeft:!0,$scrollTop:!0,$scrollX:!0,$scrollY:!0,$self:!0,$webkitIndexedDB:!0,$webkitStorageInfo:!0,$window:!0},p=function(){if("undefined"===typeof window)return!1;for(var e in window)try{if(!h["$"+e]&&i.call(window,e)&&null!==window[e]&&"object"===typeof window[e])try{d(window[e])}catch(t){return!0}}catch(t){return!0}return!1}(),f=function(e){if("undefined"===typeof window||!p)return d(e);try{return d(e)}catch(t){return!1}};r=function(e){var t=null!==e&&"object"===typeof e,n="[object Function]"===o.call(e),r=a(e),s=t&&"[object String]"===o.call(e),d=[];if(!t&&!n&&!r)throw new TypeError("Object.keys called on a non-object");var h=c&&n;if(s&&e.length>0&&!i.call(e,0))for(var p=0;p<e.length;++p)d.push(String(p));if(r&&e.length>0)for(var m=0;m<e.length;++m)d.push(String(m));else for(var g in e)h&&"prototype"===g||!i.call(e,g)||d.push(String(g));if(l)for(var v=f(e),b=0;b<u.length;++b)v&&"constructor"===u[b]||!i.call(e,u[b])||d.push(u[b]);return d}}e.exports=r},49228:function(e,t,n){"use strict";var r=Array.prototype.slice,i=n(50968),o=Object.keys,a=o?function(e){return o(e)}:n(78160),s=Object.keys;a.shim=function(){if(Object.keys){var e=function(){var e=Object.keys(arguments);return e&&e.length===arguments.length}(1,2);e||(Object.keys=function(e){return i(e)?s(r.call(e)):s(e)})}else Object.keys=a;return Object.keys||a},e.exports=a},50968:function(e){"use strict";var t=Object.prototype.toString;e.exports=function(e){var n=t.call(e),r="[object Arguments]"===n;return r||(r="[object Array]"!==n&&null!==e&&"object"===typeof e&&"number"===typeof e.length&&e.length>=0&&"[object Function]"===t.call(e.callee)),r}},25164:function(e,t,n){"use strict";var r=n(49228),i=n(62908)(),o=n(14607),a=n(9629),s=o("Array.prototype.push"),l=o("Object.prototype.propertyIsEnumerable"),c=i?a.getOwnPropertySymbols:null;e.exports=function(e,t){if(null==e)throw new TypeError("target must be an object");var n=a(e);if(1===arguments.length)return n;for(var o=1;o<arguments.length;++o){var u=a(arguments[o]),d=r(u),h=i&&(a.getOwnPropertySymbols||c);if(h)for(var p=h(u),f=0;f<p.length;++f){var m=p[f];l(u,m)&&s(d,m)}for(var g=0;g<d.length;++g){var v=d[g];if(l(u,v)){var b=u[v];n[v]=b}}}return n}},23225:function(e,t,n){"use strict";var r=n(25164),i=function(){if(!Object.assign)return!1;for(var e="abcdefghijklmnopqrst",t=e.split(""),n={},r=0;r<t.length;++r)n[t[r]]=t[r];var i=Object.assign({},n),o="";for(var a in i)o+=a;return e!==o},o=function(){if(!Object.assign||!Object.preventExtensions)return!1;var e=Object.preventExtensions({1:2});try{Object.assign(e,"xy")}catch(t){return"y"===e[1]}return!1};e.exports=function(){return Object.assign?i()||o()?r:Object.assign:r}},69501:function(e){"use strict";e.exports=["Float16Array","Float32Array","Float64Array","Int8Array","Int16Array","Int32Array","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array"]},39907:function(e){var t,n,r=e.exports={};function i(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function a(e){if(t===setTimeout)return setTimeout(e,0);if((t===i||!t)&&setTimeout)return t=setTimeout,setTimeout(e,0);try{return t(e,0)}catch(n){try{return t.call(null,e,0)}catch(n){return t.call(this,e,0)}}}function s(e){if(n===clearTimeout)return clearTimeout(e);if((n===o||!n)&&clearTimeout)return n=clearTimeout,clearTimeout(e);try{return n(e)}catch(t){try{return n.call(null,e)}catch(t){return n.call(this,e)}}}(function(){try{t="function"===typeof setTimeout?setTimeout:i}catch(e){t=i}try{n="function"===typeof clearTimeout?clearTimeout:o}catch(e){n=o}})();var l,c=[],u=!1,d=-1;function h(){u&&l&&(u=!1,l.length?c=l.concat(c):d=-1,c.length&&p())}function p(){if(!u){var e=a(h);u=!0;var t=c.length;while(t){l=c,c=[];while(++d<t)l&&l[d].run();d=-1,t=c.length}l=null,u=!1,s(e)}}function f(e,t){this.fun=e,this.array=t}function m(){}r.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];c.push(new f(e,t)),1!==c.length||u||a(p)},f.prototype.run=function(){this.fun.apply(null,this.array)},r.title="browser",r.browser=!0,r.env={},r.argv=[],r.version="",r.versions={},r.on=m,r.addListener=m,r.once=m,r.off=m,r.removeListener=m,r.removeAllListeners=m,r.emit=m,r.prependListener=m,r.prependOnceListener=m,r.listeners=function(e){return[]},r.binding=function(e){throw new Error("process.binding is not supported")},r.cwd=function(){return"/"},r.chdir=function(e){throw new Error("process.chdir is not supported")},r.umask=function(){return 0}},1830:function(e){"use strict";var t=String.prototype.replace,n=/%20/g,r={RFC1738:"RFC1738",RFC3986:"RFC3986"};e.exports={default:r.RFC3986,formatters:{RFC1738:function(e){return t.call(e,n,"+")},RFC3986:function(e){return String(e)}},RFC1738:r.RFC1738,RFC3986:r.RFC3986}},45810:function(e,t,n){"use strict";var r=n(16623),i=n(26193),o=n(1830);e.exports={formats:o,parse:i,stringify:r}},26193:function(e,t,n){"use strict";var r=n(91539),i=Object.prototype.hasOwnProperty,o=Array.isArray,a={allowDots:!1,allowEmptyArrays:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decodeDotInKeys:!1,decoder:r.decode,delimiter:"&",depth:5,duplicates:"combine",ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictDepth:!1,strictMerge:!0,strictNullHandling:!1,throwOnLimitExceeded:!1},s=function(e){return e.replace(/&#(\d+);/g,function(e,t){return String.fromCharCode(parseInt(t,10))})},l=function(e,t,n){if(e&&"string"===typeof e&&t.comma&&e.indexOf(",")>-1){if(t.throwOnLimitExceeded){var r=0,i=e.indexOf(",");while(i>-1){if(r+=1,r>=t.arrayLimit)throw new RangeError("Array limit exceeded. Only "+t.arrayLimit+" element"+(1===t.arrayLimit?"":"s")+" allowed in an array.");i=e.indexOf(",",i+1)}}return e.split(",")}if(t.throwOnLimitExceeded&&n>=t.arrayLimit)throw new RangeError("Array limit exceeded. Only "+t.arrayLimit+" element"+(1===t.arrayLimit?"":"s")+" allowed in an array.");return e},c="utf8=%26%2310003%3B",u="utf8=%E2%9C%93",d=function(e,t){var n={__proto__:null},d=t.ignoreQueryPrefix?e.replace(/^\?/,""):e;d=d.replace(/%5B/gi,"[").replace(/%5D/gi,"]");var h=t.parameterLimit===1/0?void 0:t.parameterLimit,p=d.split(t.delimiter,t.throwOnLimitExceeded&&"undefined"!==typeof h?h+1:h);if(t.throwOnLimitExceeded&&"undefined"!==typeof h&&p.length>h)throw new RangeError("Parameter limit exceeded. Only "+h+" parameter"+(1===h?"":"s")+" allowed.");var f,m=-1,g=t.charset;if(t.charsetSentinel)for(f=0;f<p.length;++f)0===p[f].indexOf("utf8=")&&(p[f]===u?g="utf-8":p[f]===c&&(g="iso-8859-1"),m=f,f=p.length);for(f=0;f<p.length;++f)if(f!==m){var v,b,y=p[f],w=y.indexOf("]="),O=-1===w?y.indexOf("="):w+1;if(-1===O?(v=t.decoder(y,a.decoder,g,"key"),b=t.strictNullHandling?null:""):(v=t.decoder(y.slice(0,O),a.decoder,g,"key"),null!==v&&(b=r.maybeMap(l(y.slice(O+1),t,o(n[v])?n[v].length:0),function(e){return t.decoder(e,a.decoder,g,"value")}))),b&&t.interpretNumericEntities&&"iso-8859-1"===g&&(b=s(String(b))),y.indexOf("[]=")>-1&&(b=o(b)?[b]:b),t.comma&&o(b)&&b.length>t.arrayLimit&&(b=r.combine([],b,t.arrayLimit,t.plainObjects,t.throwOnLimitExceeded)),null!==v){var S=i.call(n,v);S&&("combine"===t.duplicates||y.indexOf("[]=")>-1)?n[v]=r.combine(n[v],b,t.arrayLimit,t.plainObjects,t.throwOnLimitExceeded):S&&"last"!==t.duplicates||(n[v]=b)}}return n},h=function(e,t,n,i){var o=0;if(e.length>0&&"[]"===e[e.length-1]){var a=e.slice(0,-1).join("");o=Array.isArray(t)&&t[a]?t[a].length:0}for(var s=i?t:l(t,n,o),c=e.length-1;c>=0;--c){var u,d=e[c];if("[]"===d&&n.parseArrays)u=r.isOverflow(s)?s:n.allowEmptyArrays&&(""===s||n.strictNullHandling&&null===s)?[]:r.combine([],s,n.arrayLimit,n.plainObjects,n.throwOnLimitExceeded);else{u=n.plainObjects?{__proto__:null}:{};var h="["===d.charAt(0)&&"]"===d.charAt(d.length-1)?d.slice(1,-1):d,p=n.decodeDotInKeys?h.replace(/%2E/g,"."):h,f=parseInt(p,10),m=!isNaN(f)&&d!==p&&String(f)===p&&f>=0&&n.parseArrays;if(n.parseArrays||""!==p)if(m&&f<n.arrayLimit)u=[],u[f]=s;else{if(m&&n.throwOnLimitExceeded)throw new RangeError("Array limit exceeded. Only "+n.arrayLimit+" element"+(1===n.arrayLimit?"":"s")+" allowed in an array.");m?(u[f]=s,r.markOverflow(u,f)):"__proto__"!==p&&(u[p]=s)}else u={0:s}}s=u}return s},p=function(e,t){var n=t.allowDots?e.replace(/\.([^.[]+)/g,"[$1]"):e;if(t.depth<=0){if(!t.plainObjects&&i.call(Object.prototype,n)&&!t.allowPrototypes)return;return[n]}var r=[],o=n.indexOf("["),a=o>=0?n.slice(0,o):n;if(a){if(!t.plainObjects&&i.call(Object.prototype,a)&&!t.allowPrototypes)return;r[r.length]=a}var s=n.length,l=o,c=0;while(l>=0&&c<t.depth){var u=1,d=l+1,h=-1;while(d<s&&h<0){var p=n.charCodeAt(d);91===p?u+=1:93===p&&(u-=1,0===u&&(h=d)),d+=1}if(h<0)return r[r.length]="["+n.slice(l)+"]",r;var f=n.slice(l,h+1),m=f.slice(1,-1);if(!t.plainObjects&&i.call(Object.prototype,m)&&!t.allowPrototypes)return;r[r.length]=f,c+=1,l=n.indexOf("[",h+1)}if(l>=0){if(!0===t.strictDepth)throw new RangeError("Input depth exceeded depth option of "+t.depth+" and strictDepth is true");r[r.length]="["+n.slice(l)+"]"}return r},f=function(e,t,n,r){if(e){var i=p(e,n);if(i)return h(i,t,n,r)}},m=function(e){if(!e)return a;if("undefined"!==typeof e.allowEmptyArrays&&"boolean"!==typeof e.allowEmptyArrays)throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");if("undefined"!==typeof e.decodeDotInKeys&&"boolean"!==typeof e.decodeDotInKeys)throw new TypeError("`decodeDotInKeys` option can only be `true` or `false`, when provided");if(null!==e.decoder&&"undefined"!==typeof e.decoder&&"function"!==typeof e.decoder)throw new TypeError("Decoder has to be a function.");if("undefined"!==typeof e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");if("undefined"!==typeof e.throwOnLimitExceeded&&"boolean"!==typeof e.throwOnLimitExceeded)throw new TypeError("`throwOnLimitExceeded` option must be a boolean");var t="undefined"===typeof e.charset?a.charset:e.charset,n="undefined"===typeof e.duplicates?a.duplicates:e.duplicates;if("combine"!==n&&"first"!==n&&"last"!==n)throw new TypeError("The duplicates option must be either combine, first, or last");var i="undefined"===typeof e.allowDots?!0===e.decodeDotInKeys||a.allowDots:!!e.allowDots;return{allowDots:i,allowEmptyArrays:"boolean"===typeof e.allowEmptyArrays?!!e.allowEmptyArrays:a.allowEmptyArrays,allowPrototypes:"boolean"===typeof e.allowPrototypes?e.allowPrototypes:a.allowPrototypes,allowSparse:"boolean"===typeof e.allowSparse?e.allowSparse:a.allowSparse,arrayLimit:"number"===typeof e.arrayLimit?e.arrayLimit:a.arrayLimit,charset:t,charsetSentinel:"boolean"===typeof e.charsetSentinel?e.charsetSentinel:a.charsetSentinel,comma:"boolean"===typeof e.comma?e.comma:a.comma,decodeDotInKeys:"boolean"===typeof e.decodeDotInKeys?e.decodeDotInKeys:a.decodeDotInKeys,decoder:"function"===typeof e.decoder?e.decoder:a.decoder,delimiter:"string"===typeof e.delimiter||r.isRegExp(e.delimiter)?e.delimiter:a.delimiter,depth:"number"===typeof e.depth||!1===e.depth?+e.depth:a.depth,duplicates:n,ignoreQueryPrefix:!0===e.ignoreQueryPrefix,interpretNumericEntities:"boolean"===typeof e.interpretNumericEntities?e.interpretNumericEntities:a.interpretNumericEntities,parameterLimit:"number"===typeof e.parameterLimit?e.parameterLimit:a.parameterLimit,parseArrays:!1!==e.parseArrays,plainObjects:"boolean"===typeof e.plainObjects?e.plainObjects:a.plainObjects,strictDepth:"boolean"===typeof e.strictDepth?!!e.strictDepth:a.strictDepth,strictMerge:"boolean"===typeof e.strictMerge?!!e.strictMerge:a.strictMerge,strictNullHandling:"boolean"===typeof e.strictNullHandling?e.strictNullHandling:a.strictNullHandling,throwOnLimitExceeded:"boolean"===typeof e.throwOnLimitExceeded&&e.throwOnLimitExceeded}};e.exports=function(e,t){var n=m(t);if(""===e||null===e||"undefined"===typeof e)return n.plainObjects?{__proto__:null}:{};for(var i="string"===typeof e?d(e,n):e,o=n.plainObjects?{__proto__:null}:{},a=Object.keys(i),s=0;s<a.length;++s){var l=a[s],c=f(l,i[l],n,"string"===typeof e);o=r.merge(o,c,n)}return!0===n.allowSparse?o:r.compact(o)}},16623:function(e,t,n){"use strict";var r=n(77575),i=n(91539),o=n(1830),a=Object.prototype.hasOwnProperty,s={brackets:function(e){return e+"[]"},comma:"comma",indices:function(e,t){return e+"["+t+"]"},repeat:function(e){return e}},l=Array.isArray,c=Array.prototype.push,u=function(e,t){c.apply(e,l(t)?t:[t])},d=Date.prototype.toISOString,h=o["default"],p={addQueryPrefix:!1,allowDots:!1,allowEmptyArrays:!1,arrayFormat:"indices",charset:"utf-8",charsetSentinel:!1,commaRoundTrip:!1,delimiter:"&",depth:1/0,encode:!0,encodeDotInKeys:!1,encoder:i.encode,encodeValuesOnly:!1,filter:void 0,format:h,formatter:o.formatters[h],indices:!1,serializeDate:function(e){return d.call(e)},skipNulls:!1,strictNullHandling:!1},f=function(e){return"string"===typeof e||"number"===typeof e||"boolean"===typeof e||"symbol"===typeof e||"bigint"===typeof e},m={},g=function e(t,n,o,a,s,c,d,h,g,v,b,y,w,O,S,E,x,_,k,C){var A=t;if(C>k)throw new RangeError("Input depth exceeded depth option of "+k);var T=_,R=0,N=!1;while(void 0!==(T=T.get(m))&&!N){var P=T.get(t);if(R+=1,"undefined"!==typeof P){if(P===R)throw new RangeError("Cyclic object value");N=!0}"undefined"===typeof T.get(m)&&(R=0)}if(A="function"===typeof v?v(n,A):A,A instanceof Date?A=w(A):"comma"===o&&l(A)&&(A=i.maybeMap(A,function(e){return e instanceof Date?w(e):e})),null===A){if(c)return S(g&&!E?g(n,p.encoder,x,"key",O):n);A=""}if(f(A)||i.isBuffer(A)){if(g){var I=E?n:g(n,p.encoder,x,"key",O);return[S(I)+"="+S(g(A,p.encoder,x,"value",O))]}return[S(n)+"="+S(String(A))]}var M,D=[];if("undefined"===typeof A)return D;if("comma"===o&&l(A))E&&g&&(A=i.maybeMap(A,function(e){return null==e?e:g(e)})),M=[{value:A.length>0?A.join(",")||null:void 0}];else if(l(v))M=v;else{var L=Object.keys(A);M=b?L.sort(b):L}var B=h?String(n).replace(/\./g,"%2E"):String(n),$=a&&l(A)&&1===A.length?B+"[]":B;if(s&&l(A)&&0===A.length&&0===Object.keys(A).length)return $+"[]";for(var V=0;V<M.length;++V){var F=M[V],j="object"===typeof F&&F&&"undefined"!==typeof F.value?F.value:A[F];if(!d||null!==j){var U=y&&h?String(F).replace(/\./g,"%2E"):String(F),G=l(A)?"function"===typeof o?o($,U):$:$+(y?"."+U:"["+U+"]");_.set(t,R);var H=r();H.set(m,_),u(D,e(j,G,o,a,s,c,d,h,"comma"===o&&E&&l(A)?null:g,v,b,y,w,O,S,E,x,H,k,C+1))}}return D},v=function(e){if(!e)return p;if("undefined"!==typeof e.allowEmptyArrays&&"boolean"!==typeof e.allowEmptyArrays)throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");if("undefined"!==typeof e.encodeDotInKeys&&"boolean"!==typeof e.encodeDotInKeys)throw new TypeError("`encodeDotInKeys` option can only be `true` or `false`, when provided");if(null!==e.encoder&&"undefined"!==typeof e.encoder&&"function"!==typeof e.encoder)throw new TypeError("Encoder has to be a function.");var t=e.charset||p.charset;if("undefined"!==typeof e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var n=o["default"];if("undefined"!==typeof e.format){if(!a.call(o.formatters,e.format))throw new TypeError("Unknown format option provided.");n=e.format}var r,i=o.formatters[n],c=p.filter;if(("function"===typeof e.filter||l(e.filter))&&(c=e.filter),r=e.arrayFormat in s?e.arrayFormat:"indices"in e?e.indices?"indices":"repeat":p.arrayFormat,"commaRoundTrip"in e&&"boolean"!==typeof e.commaRoundTrip)throw new TypeError("`commaRoundTrip` must be a boolean, or absent");var u="undefined"===typeof e.allowDots?!0===e.encodeDotInKeys||p.allowDots:!!e.allowDots;return{addQueryPrefix:"boolean"===typeof e.addQueryPrefix?e.addQueryPrefix:p.addQueryPrefix,allowDots:u,allowEmptyArrays:"boolean"===typeof e.allowEmptyArrays?!!e.allowEmptyArrays:p.allowEmptyArrays,arrayFormat:r,charset:t,charsetSentinel:"boolean"===typeof e.charsetSentinel?e.charsetSentinel:p.charsetSentinel,commaRoundTrip:!!e.commaRoundTrip,delimiter:"undefined"===typeof e.delimiter?p.delimiter:e.delimiter,depth:"number"===typeof e.depth?e.depth:p.depth,encode:"boolean"===typeof e.encode?e.encode:p.encode,encodeDotInKeys:"boolean"===typeof e.encodeDotInKeys?e.encodeDotInKeys:p.encodeDotInKeys,encoder:"function"===typeof e.encoder?e.encoder:p.encoder,encodeValuesOnly:"boolean"===typeof e.encodeValuesOnly?e.encodeValuesOnly:p.encodeValuesOnly,filter:c,format:n,formatter:i,serializeDate:"function"===typeof e.serializeDate?e.serializeDate:p.serializeDate,skipNulls:"boolean"===typeof e.skipNulls?e.skipNulls:p.skipNulls,sort:"function"===typeof e.sort?e.sort:null,strictNullHandling:"boolean"===typeof e.strictNullHandling?e.strictNullHandling:p.strictNullHandling}};e.exports=function(e,t){var n,i,o=e,a=v(t);"function"===typeof a.filter?(i=a.filter,o=i("",o)):l(a.filter)&&(i=a.filter,n=i);var c=[];if("object"!==typeof o||null===o)return"";var d=s[a.arrayFormat],h="comma"===d&&a.commaRoundTrip;n||(n=Object.keys(o)),a.sort&&n.sort(a.sort);for(var p=r(),f=0;f<n.length;++f){var m=n[f];if("undefined"!==typeof m&&null!==m){var b=o[m];if(!a.skipNulls||null!==b){var y=a.encodeDotInKeys?String(m).replace(/\./g,"%2E"):String(m);u(c,g(b,y,d,h,a.allowEmptyArrays,a.strictNullHandling,a.skipNulls,a.encodeDotInKeys,a.encode?a.encoder:null,a.filter,a.sort,a.allowDots,a.serializeDate,a.format,a.formatter,a.encodeValuesOnly,a.charset,p,a.depth,0))}}}var w=c.join(a.delimiter),O=!0===a.addQueryPrefix?"?":"";return a.charsetSentinel&&("iso-8859-1"===a.charset?O+="utf8=%26%2310003%3B"+a.delimiter:O+="utf8=%E2%9C%93"+a.delimiter),w.length>0?O+w:""}},91539:function(e,t,n){"use strict";var r=n(1830),i=n(77575),o=n(64940),a=Object.prototype.hasOwnProperty,s=Array.isArray,l=i(),c=function(e,t){return l.set(e,t),e},u=function(e){return l.has(e)},d=function(e){return l.get(e)},h=function(e,t){l.set(e,t)},p=function(){for(var e=[],t=0;t<256;++t)e[e.length]="%"+((t<16?"0":"")+t.toString(16)).toUpperCase();return e}(),f=function(e){while(e.length>1){var t=e.pop(),n=t.obj[t.prop];if(s(n)){for(var r=[],i=0;i<n.length;++i)"undefined"!==typeof n[i]&&(r[r.length]=n[i]);t.obj[t.prop]=r}}},m=function(e,t){for(var n=t&&t.plainObjects?{__proto__:null}:{},r=0;r<e.length;++r)"undefined"!==typeof e[r]&&(n[r]=e[r]);return n},g=function(e,t,n){"__proto__"===t&&o?o(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n},v=function e(t,n,r){if(!n)return t;if("object"!==typeof n&&"function"!==typeof n){if(s(t)){var i=t.length;if(r&&"number"===typeof r.arrayLimit&&i>=r.arrayLimit){if(r.throwOnLimitExceeded)throw new RangeError("Array limit exceeded. Only "+r.arrayLimit+" element"+(1===r.arrayLimit?"":"s")+" allowed in an array.");return c(m(t.concat(n),r),i)}t[i]=n}else{if(!t||"object"!==typeof t)return[t,n];if(u(t)){var o=d(t)+1;t[o]=n,h(t,o)}else{if(r&&r.strictMerge)return[t,n];(r&&(r.plainObjects||r.allowPrototypes)||!a.call(Object.prototype,n))&&(t[n]=!0)}}return t}if(!t||"object"!==typeof t){if(u(n)){for(var l=Object.keys(n),p=r&&r.plainObjects?{__proto__:null,0:t}:{0:t},f=0;f<l.length;f++){var v=parseInt(l[f],10);p[v+1]=n[l[f]]}return c(p,d(n)+1)}var b=[t].concat(n);if(r&&"number"===typeof r.arrayLimit&&b.length>r.arrayLimit){if(r.throwOnLimitExceeded)throw new RangeError("Array limit exceeded. Only "+r.arrayLimit+" element"+(1===r.arrayLimit?"":"s")+" allowed in an array.");return c(m(b,r),b.length-1)}return b}var y=t;if(s(t)&&!s(n)&&(y=m(t,r)),s(t)&&s(n)){if(n.forEach(function(n,i){if(a.call(t,i)){var o=t[i];o&&"object"===typeof o&&n&&"object"===typeof n?t[i]=e(o,n,r):t[t.length]=n}else t[i]=n}),r&&"number"===typeof r.arrayLimit&&t.length>r.arrayLimit){if(r.throwOnLimitExceeded)throw new RangeError("Array limit exceeded. Only "+r.arrayLimit+" element"+(1===r.arrayLimit?"":"s")+" allowed in an array.");return c(m(t,r),t.length-1)}return t}return Object.keys(n).reduce(function(t,i){var o=n[i];if(a.call(t,i)?g(t,i,e(t[i],o,r)):g(t,i,o),u(n)&&!u(t)&&c(t,d(n)),u(t)){var s=parseInt(i,10);String(s)===i&&s>=0&&s>d(t)&&h(t,s)}return t},y)},b=function(e,t){return Object.keys(t).reduce(function(e,n){return g(e,n,t[n]),e},e)},y=function(e,t,n){var r=e.replace(/\+/g," ");if("iso-8859-1"===n)return r.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(r)}catch(i){return r}},w=1024,O=function(e,t,n,i,o){if(0===e.length)return e;var a=e;if("symbol"===typeof e?a=Symbol.prototype.toString.call(e):"string"!==typeof e&&(a=String(e)),"iso-8859-1"===n)return escape(a).replace(/%u[0-9a-f]{4}/gi,function(e){return"%26%23"+parseInt(e.slice(2),16)+"%3B"});for(var s="",l=0;l<a.length;l+=w){var c=a.length>=w?a.slice(l,l+w):a;if(l+w<a.length){var u=c.charCodeAt(c.length-1);u>=55296&&u<=56319&&(c=c.slice(0,-1),l-=1)}for(var d=[],h=0;h<c.length;++h){var f=c.charCodeAt(h);45===f||46===f||95===f||126===f||f>=48&&f<=57||f>=65&&f<=90||f>=97&&f<=122||o===r.RFC1738&&(40===f||41===f)?d[d.length]=c.charAt(h):f<128?d[d.length]=p[f]:f<2048?d[d.length]=p[192|f>>6]+p[128|63&f]:f<55296||f>=57344?d[d.length]=p[224|f>>12]+p[128|f>>6&63]+p[128|63&f]:(h+=1,f=65536+((1023&f)<<10|1023&c.charCodeAt(h)),d[d.length]=p[240|f>>18]+p[128|f>>12&63]+p[128|f>>6&63]+p[128|63&f])}s+=d.join("")}return s},S=function(e){for(var t=[{obj:{o:e},prop:"o"}],n=i(),r=0;r<t.length;++r)for(var o=t[r],a=o.obj[o.prop],s=Object.keys(a),l=0;l<s.length;++l){var c=s[l],u=a[c];"object"!==typeof u||null===u||n.has(u)||(t[t.length]={obj:a,prop:c},n.set(u,!0))}return f(t),e},E=function(e){return"[object RegExp]"===Object.prototype.toString.call(e)},x=function(e){return!(!e||"object"!==typeof e)&&!(!e.constructor||"function"!==typeof e.constructor.isBuffer||!e.constructor.isBuffer(e))},_=function(e,t,n,r,i){if(u(e)){if(i)throw new RangeError("Array limit exceeded. Only "+n+" element"+(1===n?"":"s")+" allowed in an array.");for(var o=s(t)?t:[t],a=d(e),l=0;l<o.length;++l)a+=1,e[a]=o[l];return h(e,a),e}var p=[].concat(e,t);if(p.length>n){if(i)throw new RangeError("Array limit exceeded. Only "+n+" element"+(1===n?"":"s")+" allowed in an array.");return c(m(p,{plainObjects:r}),p.length-1)}return p},k=function(e,t){if(s(e)){for(var n=[],r=0;r<e.length;r+=1)n[n.length]=t(e[r]);return n}return t(e)};e.exports={arrayToObject:m,assign:b,combine:_,compact:S,decode:y,encode:O,isBuffer:x,isOverflow:u,isRegExp:E,markOverflow:c,maybeMap:k,merge:v}},1359:function(e,t){"use strict";var n,r=Object.prototype.hasOwnProperty;function i(e){try{return decodeURIComponent(e.replace(/\+/g," "))}catch(t){return null}}function o(e){try{return encodeURIComponent(e)}catch(t){return null}}function a(e){var t,n=/([^=?#&]+)=?([^&]*)/g,r={};while(t=n.exec(e)){var o=i(t[1]),a=i(t[2]);null===o||null===a||o in r||(r[o]=a)}return r}function s(e,t){t=t||"";var i,a,s=[];for(a in"string"!==typeof t&&(t="?"),e)if(r.call(e,a)){if(i=e[a],i||null!==i&&i!==n&&!isNaN(i)||(i=""),a=o(a),i=o(i),null===a||null===i)continue;s.push(a+"="+i)}return s.length?t+s.join("&"):""}t.stringify=s,t.parse=a},33062:function(e){"use strict";e.exports=function(e,t){if(t=t.split(":")[0],e=+e,!e)return!1;switch(t){case"http":case"ws":return 80!==e;case"https":case"wss":return 443!==e;case"ftp":return 21!==e;case"gopher":return 70!==e;case"file":return!1}return 0!==e}},25636:function(e,t,n){
|
||
/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
||
var r=n(1048),i=r.Buffer;function o(e,t){for(var n in e)t[n]=e[n]}function a(e,t,n){return i(e,t,n)}i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?e.exports=r:(o(r,t),t.Buffer=a),a.prototype=Object.create(i.prototype),o(i,a),a.from=function(e,t,n){if("number"===typeof e)throw new TypeError("Argument must not be a number");return i(e,t,n)},a.alloc=function(e,t,n){if("number"!==typeof e)throw new TypeError("Argument must be a number");var r=i(e);return void 0!==t?"string"===typeof n?r.fill(t,n):r.fill(t):r.fill(0),r},a.allocUnsafe=function(e){if("number"!==typeof e)throw new TypeError("Argument must be a number");return i(e)},a.allocUnsafeSlow=function(e){if("number"!==typeof e)throw new TypeError("Argument must be a number");return r.SlowBuffer(e)}},46132:function(e,t,n){"use strict";var r=n(14607),i=n(52672),o=r("RegExp.prototype.exec"),a=n(3468);e.exports=function(e){if(!i(e))throw new a("`regex` must be a RegExp");return function(t){return null!==o(e,t)}}},51565:function(e,t,n){"use strict";const r=Symbol("SemVer ANY");class i{static get ANY(){return r}constructor(e,t){if(t=o(t),e instanceof i){if(e.loose===!!t.loose)return e;e=e.value}e=e.trim().split(/\s+/).join(" "),c("comparator",e,t),this.options=t,this.loose=!!t.loose,this.parse(e),this.semver===r?this.value="":this.value=this.operator+this.semver.version,c("comp",this)}parse(e){const t=this.options.loose?a[s.COMPARATORLOOSE]:a[s.COMPARATOR],n=e.match(t);if(!n)throw new TypeError(`Invalid comparator: ${e}`);this.operator=void 0!==n[1]?n[1]:"","="===this.operator&&(this.operator=""),n[2]?this.semver=new u(n[2],this.options.loose):this.semver=r}toString(){return this.value}test(e){if(c("Comparator.test",e,this.options.loose),this.semver===r||e===r)return!0;if("string"===typeof e)try{e=new u(e,this.options)}catch(t){return!1}return l(e,this.operator,this.semver,this.options)}intersects(e,t){if(!(e instanceof i))throw new TypeError("a Comparator is required");return""===this.operator?""===this.value||new d(e.value,t).test(this.value):""===e.operator?""===e.value||new d(this.value,t).test(e.semver):(t=o(t),(!t.includePrerelease||"<0.0.0-0"!==this.value&&"<0.0.0-0"!==e.value)&&(!(!t.includePrerelease&&(this.value.startsWith("<0.0.0")||e.value.startsWith("<0.0.0")))&&(!(!this.operator.startsWith(">")||!e.operator.startsWith(">"))||(!(!this.operator.startsWith("<")||!e.operator.startsWith("<"))||(!(this.semver.version!==e.semver.version||!this.operator.includes("=")||!e.operator.includes("="))||(!!(l(this.semver,"<",e.semver,t)&&this.operator.startsWith(">")&&e.operator.startsWith("<"))||!!(l(this.semver,">",e.semver,t)&&this.operator.startsWith("<")&&e.operator.startsWith(">"))))))))}}e.exports=i;const o=n(13990),{safeRe:a,t:s}=n(72841),l=n(54004),c=n(41361),u=n(24517),d=n(37476)},37476:function(e,t,n){"use strict";const r=/\s+/g;class i{constructor(e,t){if(t=s(t),e instanceof i)return e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease?e:new i(e.raw,t);if(e instanceof l)return this.raw=e.value,this.set=[[e]],this.formatted=void 0,this;if(this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease,this.raw=e.trim().replace(r," "),this.set=this.raw.split("||").map(e=>this.parseRange(e.trim())).filter(e=>e.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${this.raw}`);if(this.set.length>1){const e=this.set[0];if(this.set=this.set.filter(e=>!w(e[0])),0===this.set.length)this.set=[e];else if(this.set.length>1)for(const t of this.set)if(1===t.length&&O(t[0])){this.set=[t];break}}this.formatted=void 0}get range(){if(void 0===this.formatted){this.formatted="";for(let e=0;e<this.set.length;e++){e>0&&(this.formatted+="||");const t=this.set[e];for(let e=0;e<t.length;e++)e>0&&(this.formatted+=" "),this.formatted+=t[e].toString().trim()}}return this.formatted}format(){return this.range}toString(){return this.range}parseRange(e){e=e.replace(y,"");const t=(this.options.includePrerelease&&v)|(this.options.loose&&b),n=t+":"+e,r=a.get(n);if(r)return r;const i=this.options.loose,o=i?d[p.HYPHENRANGELOOSE]:d[p.HYPHENRANGE];e=e.replace(o,M(this.options.includePrerelease)),c("hyphen replace",e),e=e.replace(d[p.COMPARATORTRIM],f),c("comparator trim",e),e=e.replace(d[p.TILDETRIM],m),c("tilde trim",e),e=e.replace(d[p.CARETTRIM],g),c("caret trim",e);let s=e.split(" ").map(e=>E(e,this.options)).join(" ").split(/\s+/).map(e=>I(e,this.options));i&&(s=s.filter(e=>(c("loose invalid filter",e,this.options),!!e.match(d[p.COMPARATORLOOSE])))),c("range list",s);const u=new Map,h=s.map(e=>new l(e,this.options));for(const a of h){if(w(a))return[a];u.set(a.value,a)}u.size>1&&u.has("")&&u.delete("");const O=[...u.values()];return a.set(n,O),O}intersects(e,t){if(!(e instanceof i))throw new TypeError("a Range is required");return this.set.some(n=>S(n,t)&&e.set.some(e=>S(e,t)&&n.every(n=>e.every(e=>n.intersects(e,t)))))}test(e){if(!e)return!1;if("string"===typeof e)try{e=new u(e,this.options)}catch(t){return!1}for(let n=0;n<this.set.length;n++)if(D(this.set[n],e,this.options))return!0;return!1}}e.exports=i;const o=n(58953),a=new o,s=n(13990),l=n(51565),c=n(41361),u=n(24517),{safeRe:d,src:h,t:p,comparatorTrimReplace:f,tildeTrimReplace:m,caretTrimReplace:g}=n(72841),{FLAG_INCLUDE_PRERELEASE:v,FLAG_LOOSE:b}=n(79543),y=new RegExp(h[p.BUILD],"g"),w=e=>"<0.0.0-0"===e.value,O=e=>""===e.value,S=(e,t)=>{let n=!0;const r=e.slice();let i=r.pop();while(n&&r.length)n=r.every(e=>i.intersects(e,t)),i=r.pop();return n},E=(e,t)=>(e=e.replace(d[p.BUILD],""),c("comp",e,t),e=A(e,t),c("caret",e),e=k(e,t),c("tildes",e),e=R(e,t),c("xrange",e),e=P(e,t),c("stars",e),e),x=e=>!e||"x"===e.toLowerCase()||"*"===e,_=(e,t,n)=>x(e)&&!x(t)||x(t)&&n&&!x(n),k=(e,t)=>e.trim().split(/\s+/).map(e=>C(e,t)).join(" "),C=(e,t)=>{const n=t.loose?d[p.TILDELOOSE]:d[p.TILDE],r=t.includePrerelease?"-0":"";return e.replace(n,(t,n,i,o,a)=>{let s;return c("tilde",e,t,n,i,o,a),x(n)?s="":x(i)?s=`>=${n}.0.0${r} <${+n+1}.0.0-0`:x(o)?s=`>=${n}.${i}.0${r} <${n}.${+i+1}.0-0`:a?(c("replaceTilde pr",a),s=`>=${n}.${i}.${o}-${a} <${n}.${+i+1}.0-0`):s=`>=${n}.${i}.${o} <${n}.${+i+1}.0-0`,c("tilde return",s),s})},A=(e,t)=>e.trim().split(/\s+/).map(e=>T(e,t)).join(" "),T=(e,t)=>{c("caret",e,t);const n=t.loose?d[p.CARETLOOSE]:d[p.CARET],r=t.includePrerelease?"-0":"";return e.replace(n,(t,n,i,o,a)=>{let s;return c("caret",e,t,n,i,o,a),x(n)?s="":x(i)?s=`>=${n}.0.0${r} <${+n+1}.0.0-0`:x(o)?s="0"===n?`>=${n}.${i}.0${r} <${n}.${+i+1}.0-0`:`>=${n}.${i}.0${r} <${+n+1}.0.0-0`:a?(c("replaceCaret pr",a),s="0"===n?"0"===i?`>=${n}.${i}.${o}-${a} <${n}.${i}.${+o+1}-0`:`>=${n}.${i}.${o}-${a} <${n}.${+i+1}.0-0`:`>=${n}.${i}.${o}-${a} <${+n+1}.0.0-0`):(c("no pr"),s="0"===n?"0"===i?`>=${n}.${i}.${o} <${n}.${i}.${+o+1}-0`:`>=${n}.${i}.${o} <${n}.${+i+1}.0-0`:`>=${n}.${i}.${o} <${+n+1}.0.0-0`),c("caret return",s),s})},R=(e,t)=>(c("replaceXRanges",e,t),e.split(/\s+/).map(e=>N(e,t)).join(" ")),N=(e,t)=>{e=e.trim();const n=t.loose?d[p.XRANGELOOSE]:d[p.XRANGE];return e.replace(n,(n,r,i,o,a,s)=>{if(c("xRange",e,n,r,i,o,a,s),_(i,o,a))return e;const l=x(i),u=l||x(o),d=u||x(a),h=d;return"="===r&&h&&(r=""),s=t.includePrerelease?"-0":"",l?n=">"===r||"<"===r?"<0.0.0-0":"*":r&&h?(u&&(o=0),a=0,">"===r?(r=">=",u?(i=+i+1,o=0,a=0):(o=+o+1,a=0)):"<="===r&&(r="<",u?i=+i+1:o=+o+1),"<"===r&&(s="-0"),n=`${r+i}.${o}.${a}${s}`):u?n=`>=${i}.0.0${s} <${+i+1}.0.0-0`:d&&(n=`>=${i}.${o}.0${s} <${i}.${+o+1}.0-0`),c("xRange return",n),n})},P=(e,t)=>(c("replaceStars",e,t),e.trim().replace(d[p.STAR],"")),I=(e,t)=>(c("replaceGTE0",e,t),e.trim().replace(d[t.includePrerelease?p.GTE0PRE:p.GTE0],"")),M=e=>(t,n,r,i,o,a,s,l,c,u,d,h)=>(n=x(r)?"":x(i)?`>=${r}.0.0${e?"-0":""}`:x(o)?`>=${r}.${i}.0${e?"-0":""}`:a?`>=${n}`:`>=${n}${e?"-0":""}`,l=x(c)?"":x(u)?`<${+c+1}.0.0-0`:x(d)?`<${c}.${+u+1}.0-0`:h?`<=${c}.${u}.${d}-${h}`:e?`<${c}.${u}.${+d+1}-0`:`<=${l}`,`${n} ${l}`.trim()),D=(e,t,n)=>{for(let r=0;r<e.length;r++)if(!e[r].test(t))return!1;if(t.prerelease.length&&!n.includePrerelease){for(let n=0;n<e.length;n++)if(c(e[n].semver),e[n].semver!==l.ANY&&e[n].semver.prerelease.length>0){const r=e[n].semver;if(r.major===t.major&&r.minor===t.minor&&r.patch===t.patch)return!0}return!1}return!0}},24517:function(e,t,n){"use strict";const r=n(41361),{MAX_LENGTH:i,MAX_SAFE_INTEGER:o}=n(79543),{safeRe:a,t:s}=n(72841),l=n(13990),{compareIdentifiers:c}=n(93806),u=(e,t)=>{const n=t.split(".");if(n.length>e.length)return!1;for(let r=0;r<n.length;r++)if(0!==c(e[r],n[r]))return!1;return!0};class d{constructor(e,t){if(t=l(t),e instanceof d){if(e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease)return e;e=e.version}else if("string"!==typeof e)throw new TypeError(`Invalid version. Must be a string. Got type "${typeof e}".`);if(e.length>i)throw new TypeError(`version is longer than ${i} characters`);r("SemVer",e,t),this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease;const n=e.trim().match(t.loose?a[s.LOOSE]:a[s.FULL]);if(!n)throw new TypeError(`Invalid Version: ${e}`);if(this.raw=e,this.major=+n[1],this.minor=+n[2],this.patch=+n[3],this.major>o||this.major<0)throw new TypeError("Invalid major version");if(this.minor>o||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>o||this.patch<0)throw new TypeError("Invalid patch version");n[4]?this.prerelease=n[4].split(".").map(e=>{if(/^[0-9]+$/.test(e)){const t=+e;if(t>=0&&t<o)return t}return e}):this.prerelease=[],this.build=n[5]?n[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(e){if(r("SemVer.compare",this.version,this.options,e),!(e instanceof d)){if("string"===typeof e&&e===this.version)return 0;e=new d(e,this.options)}return e.version===this.version?0:this.compareMain(e)||this.comparePre(e)}compareMain(e){return e instanceof d||(e=new d(e,this.options)),this.major<e.major?-1:this.major>e.major?1:this.minor<e.minor?-1:this.minor>e.minor?1:this.patch<e.patch?-1:this.patch>e.patch?1:0}comparePre(e){if(e instanceof d||(e=new d(e,this.options)),this.prerelease.length&&!e.prerelease.length)return-1;if(!this.prerelease.length&&e.prerelease.length)return 1;if(!this.prerelease.length&&!e.prerelease.length)return 0;let t=0;do{const n=this.prerelease[t],i=e.prerelease[t];if(r("prerelease compare",t,n,i),void 0===n&&void 0===i)return 0;if(void 0===i)return 1;if(void 0===n)return-1;if(n!==i)return c(n,i)}while(++t)}compareBuild(e){e instanceof d||(e=new d(e,this.options));let t=0;do{const n=this.build[t],i=e.build[t];if(r("build compare",t,n,i),void 0===n&&void 0===i)return 0;if(void 0===i)return 1;if(void 0===n)return-1;if(n!==i)return c(n,i)}while(++t)}inc(e,t,n){if(e.startsWith("pre")){if(!t&&!1===n)throw new Error("invalid increment argument: identifier is empty");if(t){const e=`-${t}`.match(this.options.loose?a[s.PRERELEASELOOSE]:a[s.PRERELEASE]);if(!e||e[1]!==t)throw new Error(`invalid identifier: ${t}`)}}switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",t,n);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",t,n);break;case"prepatch":this.prerelease.length=0,this.inc("patch",t,n),this.inc("pre",t,n);break;case"prerelease":0===this.prerelease.length&&this.inc("patch",t,n),this.inc("pre",t,n);break;case"release":if(0===this.prerelease.length)throw new Error(`version ${this.raw} is not a prerelease`);this.prerelease.length=0;break;case"major":0===this.minor&&0===this.patch&&0!==this.prerelease.length||this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":0===this.patch&&0!==this.prerelease.length||this.minor++,this.patch=0,this.prerelease=[];break;case"patch":0===this.prerelease.length&&this.patch++,this.prerelease=[];break;case"pre":{const e=Number(n)?1:0;if(0===this.prerelease.length)this.prerelease=[e];else{let r=this.prerelease.length;while(--r>=0)"number"===typeof this.prerelease[r]&&(this.prerelease[r]++,r=-2);if(-1===r){if(t===this.prerelease.join(".")&&!1===n)throw new Error("invalid increment argument: identifier already exists");this.prerelease.push(e)}}if(t){let r=[t,e];if(!1===n&&(r=[t]),u(this.prerelease,t)){const e=this.prerelease[t.split(".").length];isNaN(e)&&(this.prerelease=r)}else this.prerelease=r}break}default:throw new Error(`invalid increment argument: ${e}`)}return this.raw=this.format(),this.build.length&&(this.raw+=`+${this.build.join(".")}`),this}}e.exports=d},92281:function(e,t,n){"use strict";const r=n(93955),i=(e,t)=>{const n=r(e.trim().replace(/^[=v]+/,""),t);return n?n.version:null};e.exports=i},54004:function(e,t,n){"use strict";const r=n(28848),i=n(28220),o=n(89761),a=n(72386),s=n(51262),l=n(89639),c=(e,t,n,c)=>{switch(t){case"===":return"object"===typeof e&&(e=e.version),"object"===typeof n&&(n=n.version),e===n;case"!==":return"object"===typeof e&&(e=e.version),"object"===typeof n&&(n=n.version),e!==n;case"":case"=":case"==":return r(e,n,c);case"!=":return i(e,n,c);case">":return o(e,n,c);case">=":return a(e,n,c);case"<":return s(e,n,c);case"<=":return l(e,n,c);default:throw new TypeError(`Invalid operator: ${t}`)}};e.exports=c},56783:function(e,t,n){"use strict";const r=n(24517),i=n(93955),{safeRe:o,t:a}=n(72841),s=(e,t)=>{if(e instanceof r)return e;if("number"===typeof e&&(e=String(e)),"string"!==typeof e)return null;t=t||{};let n=null;if(t.rtl){const r=t.includePrerelease?o[a.COERCERTLFULL]:o[a.COERCERTL];let i;while((i=r.exec(e))&&(!n||n.index+n[0].length!==e.length))n&&i.index+i[0].length===n.index+n[0].length||(n=i),r.lastIndex=i.index+i[1].length+i[2].length;r.lastIndex=-1}else n=e.match(t.includePrerelease?o[a.COERCEFULL]:o[a.COERCE]);if(null===n)return null;const s=n[2],l=n[3]||"0",c=n[4]||"0",u=t.includePrerelease&&n[5]?`-${n[5]}`:"",d=t.includePrerelease&&n[6]?`+${n[6]}`:"";return i(`${s}.${l}.${c}${u}${d}`,t)};e.exports=s},6106:function(e,t,n){"use strict";const r=n(24517),i=(e,t,n)=>{const i=new r(e,n),o=new r(t,n);return i.compare(o)||i.compareBuild(o)};e.exports=i},52132:function(e,t,n){"use strict";const r=n(87851),i=(e,t)=>r(e,t,!0);e.exports=i},87851:function(e,t,n){"use strict";const r=n(24517),i=(e,t,n)=>new r(e,n).compare(new r(t,n));e.exports=i},73269:function(e,t,n){"use strict";const r=n(93955),i=(e,t)=>{const n=r(e,null,!0),i=r(t,null,!0),o=n.compare(i);if(0===o)return null;const a=o>0,s=a?n:i,l=a?i:n,c=!!s.prerelease.length,u=!!l.prerelease.length;if(u&&!c){if(!l.patch&&!l.minor)return"major";if(0===l.compareMain(s))return l.minor&&!l.patch?"minor":"patch"}const d=c?"pre":"";return n.major!==i.major?d+"major":n.minor!==i.minor?d+"minor":n.patch!==i.patch?d+"patch":"prerelease"};e.exports=i},28848:function(e,t,n){"use strict";const r=n(87851),i=(e,t,n)=>0===r(e,t,n);e.exports=i},89761:function(e,t,n){"use strict";const r=n(87851),i=(e,t,n)=>r(e,t,n)>0;e.exports=i},72386:function(e,t,n){"use strict";const r=n(87851),i=(e,t,n)=>r(e,t,n)>=0;e.exports=i},38868:function(e,t,n){"use strict";const r=n(24517),i=(e,t,n,i,o)=>{"string"===typeof n&&(o=i,i=n,n=void 0);try{return new r(e instanceof r?e.version:e,n).inc(t,i,o).version}catch(a){return null}};e.exports=i},51262:function(e,t,n){"use strict";const r=n(87851),i=(e,t,n)=>r(e,t,n)<0;e.exports=i},89639:function(e,t,n){"use strict";const r=n(87851),i=(e,t,n)=>r(e,t,n)<=0;e.exports=i},26381:function(e,t,n){"use strict";const r=n(24517),i=(e,t)=>new r(e,t).major;e.exports=i},31353:function(e,t,n){"use strict";const r=n(24517),i=(e,t)=>new r(e,t).minor;e.exports=i},28220:function(e,t,n){"use strict";const r=n(87851),i=(e,t,n)=>0!==r(e,t,n);e.exports=i},93955:function(e,t,n){"use strict";const r=n(24517),i=(e,t,n=!1)=>{if(e instanceof r)return e;try{return new r(e,t)}catch(i){if(!n)return null;throw i}};e.exports=i},96082:function(e,t,n){"use strict";const r=n(24517),i=(e,t)=>new r(e,t).patch;e.exports=i},69428:function(e,t,n){"use strict";const r=n(93955),i=(e,t)=>{const n=r(e,t);return n&&n.prerelease.length?n.prerelease:null};e.exports=i},87555:function(e,t,n){"use strict";const r=n(87851),i=(e,t,n)=>r(t,e,n);e.exports=i},93810:function(e,t,n){"use strict";const r=n(6106),i=(e,t)=>e.sort((e,n)=>r(n,e,t));e.exports=i},27229:function(e,t,n){"use strict";const r=n(37476),i=(e,t,n)=>{try{t=new r(t,n)}catch(i){return!1}return t.test(e)};e.exports=i},34042:function(e,t,n){"use strict";const r=n(6106),i=(e,t)=>e.sort((e,n)=>r(e,n,t));e.exports=i},78668:function(e,t,n){"use strict";const r=n(93955),i=n(79543),o=n(24517),a=(e,t,n)=>{if(!i.RELEASE_TYPES.includes(t))return null;const r=s(e,n);return r&&l(r,t)},s=(e,t)=>{const n=e instanceof o?e.version:e;return r(n,t)},l=(e,t)=>{if(c(t))return e.version;switch(e.prerelease=[],t){case"major":e.minor=0,e.patch=0;break;case"minor":e.patch=0;break}return e.format()},c=e=>e.startsWith("pre");e.exports=a},28474:function(e,t,n){"use strict";const r=n(93955),i=(e,t)=>{const n=r(e,t);return n?n.version:null};e.exports=i},2722:function(e,t,n){"use strict";const r=n(72841),i=n(79543),o=n(24517),a=n(93806),s=n(93955),l=n(28474),c=n(92281),u=n(38868),d=n(73269),h=n(26381),p=n(31353),f=n(96082),m=n(69428),g=n(87851),v=n(87555),b=n(52132),y=n(6106),w=n(34042),O=n(93810),S=n(89761),E=n(51262),x=n(28848),_=n(28220),k=n(72386),C=n(89639),A=n(54004),T=n(56783),R=n(78668),N=n(51565),P=n(37476),I=n(27229),M=n(26364),D=n(55039),L=n(55357),B=n(71280),$=n(37403),V=n(58854),F=n(27226),j=n(37183),U=n(18623),G=n(76486),H=n(40583);e.exports={parse:s,valid:l,clean:c,inc:u,diff:d,major:h,minor:p,patch:f,prerelease:m,compare:g,rcompare:v,compareLoose:b,compareBuild:y,sort:w,rsort:O,gt:S,lt:E,eq:x,neq:_,gte:k,lte:C,cmp:A,coerce:T,truncate:R,Comparator:N,Range:P,satisfies:I,toComparators:M,maxSatisfying:D,minSatisfying:L,minVersion:B,validRange:$,outside:V,gtr:F,ltr:j,intersects:U,simplifyRange:G,subset:H,SemVer:o,re:r.re,src:r.src,tokens:r.t,SEMVER_SPEC_VERSION:i.SEMVER_SPEC_VERSION,RELEASE_TYPES:i.RELEASE_TYPES,compareIdentifiers:a.compareIdentifiers,rcompareIdentifiers:a.rcompareIdentifiers}},79543:function(e){"use strict";const t="2.0.0",n=256,r=Number.MAX_SAFE_INTEGER||9007199254740991,i=16,o=n-6,a=["major","premajor","minor","preminor","patch","prepatch","prerelease"];e.exports={MAX_LENGTH:n,MAX_SAFE_COMPONENT_LENGTH:i,MAX_SAFE_BUILD_LENGTH:o,MAX_SAFE_INTEGER:r,RELEASE_TYPES:a,SEMVER_SPEC_VERSION:t,FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2}},41361:function(e,t,n){"use strict";var r=n(39907),i=n(4364);const o="object"===typeof r&&{NODE_ENV:"production",BASE_URL:"/"}.NODE_DEBUG&&/\bsemver\b/i.test({NODE_ENV:"production",BASE_URL:"/"}.NODE_DEBUG)?(...e)=>i.error("SEMVER",...e):()=>{};e.exports=o},93806:function(e){"use strict";const t=/^[0-9]+$/,n=(e,n)=>{if("number"===typeof e&&"number"===typeof n)return e===n?0:e<n?-1:1;const r=t.test(e),i=t.test(n);return r&&i&&(e=+e,n=+n),e===n?0:r&&!i?-1:i&&!r?1:e<n?-1:1},r=(e,t)=>n(t,e);e.exports={compareIdentifiers:n,rcompareIdentifiers:r}},58953:function(e){"use strict";class t{constructor(){this.max=1e3,this.map=new Map}get(e){const t=this.map.get(e);return void 0===t?void 0:(this.map.delete(e),this.map.set(e,t),t)}delete(e){return this.map.delete(e)}set(e,t){const n=this.delete(e);if(!n&&void 0!==t){if(this.map.size>=this.max){const e=this.map.keys().next().value;this.delete(e)}this.map.set(e,t)}return this}}e.exports=t},13990:function(e){"use strict";const t=Object.freeze({loose:!0}),n=Object.freeze({}),r=e=>e?"object"!==typeof e?t:e:n;e.exports=r},72841:function(e,t,n){"use strict";const{MAX_SAFE_COMPONENT_LENGTH:r,MAX_SAFE_BUILD_LENGTH:i,MAX_LENGTH:o}=n(79543),a=n(41361);t=e.exports={};const s=t.re=[],l=t.safeRe=[],c=t.src=[],u=t.safeSrc=[],d=t.t={};let h=0;const p="[a-zA-Z0-9-]",f=[["\\s",1],["\\d",o],[p,i]],m=e=>{for(const[t,n]of f)e=e.split(`${t}*`).join(`${t}{0,${n}}`).split(`${t}+`).join(`${t}{1,${n}}`);return e},g=(e,t,n)=>{const r=m(t),i=h++;a(e,i,t),d[e]=i,c[i]=t,u[i]=r,s[i]=new RegExp(t,n?"g":void 0),l[i]=new RegExp(r,n?"g":void 0)};g("NUMERICIDENTIFIER","0|[1-9]\\d*"),g("NUMERICIDENTIFIERLOOSE","\\d+"),g("NONNUMERICIDENTIFIER",`\\d*[a-zA-Z-]${p}*`),g("MAINVERSION",`(${c[d.NUMERICIDENTIFIER]})\\.(${c[d.NUMERICIDENTIFIER]})\\.(${c[d.NUMERICIDENTIFIER]})`),g("MAINVERSIONLOOSE",`(${c[d.NUMERICIDENTIFIERLOOSE]})\\.(${c[d.NUMERICIDENTIFIERLOOSE]})\\.(${c[d.NUMERICIDENTIFIERLOOSE]})`),g("PRERELEASEIDENTIFIER",`(?:${c[d.NONNUMERICIDENTIFIER]}|${c[d.NUMERICIDENTIFIER]})`),g("PRERELEASEIDENTIFIERLOOSE",`(?:${c[d.NONNUMERICIDENTIFIER]}|${c[d.NUMERICIDENTIFIERLOOSE]})`),g("PRERELEASE",`(?:-(${c[d.PRERELEASEIDENTIFIER]}(?:\\.${c[d.PRERELEASEIDENTIFIER]})*))`),g("PRERELEASELOOSE",`(?:-?(${c[d.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${c[d.PRERELEASEIDENTIFIERLOOSE]})*))`),g("BUILDIDENTIFIER",`${p}+`),g("BUILD",`(?:\\+(${c[d.BUILDIDENTIFIER]}(?:\\.${c[d.BUILDIDENTIFIER]})*))`),g("FULLPLAIN",`v?${c[d.MAINVERSION]}${c[d.PRERELEASE]}?${c[d.BUILD]}?`),g("FULL",`^${c[d.FULLPLAIN]}$`),g("LOOSEPLAIN",`[v=\\s]*${c[d.MAINVERSIONLOOSE]}${c[d.PRERELEASELOOSE]}?${c[d.BUILD]}?`),g("LOOSE",`^${c[d.LOOSEPLAIN]}$`),g("GTLT","((?:<|>)?=?)"),g("XRANGEIDENTIFIERLOOSE",`${c[d.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`),g("XRANGEIDENTIFIER",`${c[d.NUMERICIDENTIFIER]}|x|X|\\*`),g("XRANGEPLAIN",`[v=\\s]*(${c[d.XRANGEIDENTIFIER]})(?:\\.(${c[d.XRANGEIDENTIFIER]})(?:\\.(${c[d.XRANGEIDENTIFIER]})(?:${c[d.PRERELEASE]})?${c[d.BUILD]}?)?)?`),g("XRANGEPLAINLOOSE",`[v=\\s]*(${c[d.XRANGEIDENTIFIERLOOSE]})(?:\\.(${c[d.XRANGEIDENTIFIERLOOSE]})(?:\\.(${c[d.XRANGEIDENTIFIERLOOSE]})(?:${c[d.PRERELEASELOOSE]})?${c[d.BUILD]}?)?)?`),g("XRANGE",`^${c[d.GTLT]}\\s*${c[d.XRANGEPLAIN]}$`),g("XRANGELOOSE",`^${c[d.GTLT]}\\s*${c[d.XRANGEPLAINLOOSE]}$`),g("COERCEPLAIN",`(^|[^\\d])(\\d{1,${r}})(?:\\.(\\d{1,${r}}))?(?:\\.(\\d{1,${r}}))?`),g("COERCE",`${c[d.COERCEPLAIN]}(?:$|[^\\d])`),g("COERCEFULL",c[d.COERCEPLAIN]+`(?:${c[d.PRERELEASE]})?`+`(?:${c[d.BUILD]})?(?:$|[^\\d])`),g("COERCERTL",c[d.COERCE],!0),g("COERCERTLFULL",c[d.COERCEFULL],!0),g("LONETILDE","(?:~>?)"),g("TILDETRIM",`(\\s*)${c[d.LONETILDE]}\\s+`,!0),t.tildeTrimReplace="$1~",g("TILDE",`^${c[d.LONETILDE]}${c[d.XRANGEPLAIN]}$`),g("TILDELOOSE",`^${c[d.LONETILDE]}${c[d.XRANGEPLAINLOOSE]}$`),g("LONECARET","(?:\\^)"),g("CARETTRIM",`(\\s*)${c[d.LONECARET]}\\s+`,!0),t.caretTrimReplace="$1^",g("CARET",`^${c[d.LONECARET]}${c[d.XRANGEPLAIN]}$`),g("CARETLOOSE",`^${c[d.LONECARET]}${c[d.XRANGEPLAINLOOSE]}$`),g("COMPARATORLOOSE",`^${c[d.GTLT]}\\s*(${c[d.LOOSEPLAIN]})$|^$`),g("COMPARATOR",`^${c[d.GTLT]}\\s*(${c[d.FULLPLAIN]})$|^$`),g("COMPARATORTRIM",`(\\s*)${c[d.GTLT]}\\s*(${c[d.LOOSEPLAIN]}|${c[d.XRANGEPLAIN]})`,!0),t.comparatorTrimReplace="$1$2$3",g("HYPHENRANGE",`^\\s*(${c[d.XRANGEPLAIN]})\\s+-\\s+(${c[d.XRANGEPLAIN]})\\s*$`),g("HYPHENRANGELOOSE",`^\\s*(${c[d.XRANGEPLAINLOOSE]})\\s+-\\s+(${c[d.XRANGEPLAINLOOSE]})\\s*$`),g("STAR","(<|>)?=?\\s*\\*"),g("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$"),g("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")},27226:function(e,t,n){"use strict";const r=n(58854),i=(e,t,n)=>r(e,t,">",n);e.exports=i},18623:function(e,t,n){"use strict";const r=n(37476),i=(e,t,n)=>(e=new r(e,n),t=new r(t,n),e.intersects(t,n));e.exports=i},37183:function(e,t,n){"use strict";const r=n(58854),i=(e,t,n)=>r(e,t,"<",n);e.exports=i},55039:function(e,t,n){"use strict";const r=n(24517),i=n(37476),o=(e,t,n)=>{let o=null,a=null,s=null;try{s=new i(t,n)}catch(l){return null}return e.forEach(e=>{s.test(e)&&(o&&-1!==a.compare(e)||(o=e,a=new r(o,n)))}),o};e.exports=o},55357:function(e,t,n){"use strict";const r=n(24517),i=n(37476),o=(e,t,n)=>{let o=null,a=null,s=null;try{s=new i(t,n)}catch(l){return null}return e.forEach(e=>{s.test(e)&&(o&&1!==a.compare(e)||(o=e,a=new r(o,n)))}),o};e.exports=o},71280:function(e,t,n){"use strict";const r=n(24517),i=n(37476),o=n(89761),a=(e,t)=>{e=new i(e,t);let n=new r("0.0.0");if(e.test(n))return n;if(n=new r("0.0.0-0"),e.test(n))return n;n=null;for(let i=0;i<e.set.length;++i){const t=e.set[i];let a=null;t.forEach(e=>{const t=new r(e.semver.version);switch(e.operator){case">":0===t.prerelease.length?t.patch++:t.prerelease.push(0),t.raw=t.format();case"":case">=":a&&!o(t,a)||(a=t);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${e.operator}`)}}),!a||n&&!o(n,a)||(n=a)}return n&&e.test(n)?n:null};e.exports=a},58854:function(e,t,n){"use strict";const r=n(24517),i=n(51565),{ANY:o}=i,a=n(37476),s=n(27229),l=n(89761),c=n(51262),u=n(89639),d=n(72386),h=(e,t,n,h)=>{let p,f,m,g,v;switch(e=new r(e,h),t=new a(t,h),n){case">":p=l,f=u,m=c,g=">",v=">=";break;case"<":p=c,f=d,m=l,g="<",v="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(s(e,t,h))return!1;for(let r=0;r<t.set.length;++r){const n=t.set[r];let a=null,s=null;if(n.forEach(e=>{e.semver===o&&(e=new i(">=0.0.0")),a=a||e,s=s||e,p(e.semver,a.semver,h)?a=e:m(e.semver,s.semver,h)&&(s=e)}),a.operator===g||a.operator===v)return!1;if((!s.operator||s.operator===g)&&f(e,s.semver))return!1;if(s.operator===v&&m(e,s.semver))return!1}return!0};e.exports=h},76486:function(e,t,n){"use strict";const r=n(27229),i=n(87851);e.exports=(e,t,n)=>{const o=[];let a=null,s=null;const l=e.sort((e,t)=>i(e,t,n));for(const i of l){const e=r(i,t,n);e?(s=i,a||(a=i)):(s&&o.push([a,s]),s=null,a=null)}a&&o.push([a,null]);const c=[];for(const[r,i]of o)r===i?c.push(r):i||r!==l[0]?i?r===l[0]?c.push(`<=${i}`):c.push(`${r} - ${i}`):c.push(`>=${r}`):c.push("*");const u=c.join(" || "),d="string"===typeof t.raw?t.raw:String(t);return u.length<d.length?u:t}},40583:function(e,t,n){"use strict";const r=n(37476),i=n(51565),{ANY:o}=i,a=n(27229),s=n(87851),l=(e,t,n={})=>{if(e===t)return!0;e=new r(e,n),t=new r(t,n);let i=!1;e:for(const r of e.set){for(const e of t.set){const t=d(r,e,n);if(i=i||null!==t,t)continue e}if(i)return!1}return!0},c=[new i(">=0.0.0-0")],u=[new i(">=0.0.0")],d=(e,t,n)=>{if(e===t)return!0;if(1===e.length&&e[0].semver===o){if(1===t.length&&t[0].semver===o)return!0;e=n.includePrerelease?c:u}if(1===t.length&&t[0].semver===o){if(n.includePrerelease)return!0;t=u}const r=new Set;let i,l,d,f,m,g,v;for(const o of e)">"===o.operator||">="===o.operator?i=h(i,o,n):"<"===o.operator||"<="===o.operator?l=p(l,o,n):r.add(o.semver);if(r.size>1)return null;if(i&&l){if(d=s(i.semver,l.semver,n),d>0)return null;if(0===d&&(">="!==i.operator||"<="!==l.operator))return null}for(const o of r){if(i&&!a(o,String(i),n))return null;if(l&&!a(o,String(l),n))return null;for(const e of t)if(!a(o,String(e),n))return!1;return!0}let b=!(!l||n.includePrerelease||!l.semver.prerelease.length)&&l.semver,y=!(!i||n.includePrerelease||!i.semver.prerelease.length)&&i.semver;b&&1===b.prerelease.length&&"<"===l.operator&&0===b.prerelease[0]&&(b=!1);for(const o of t){if(v=v||">"===o.operator||">="===o.operator,g=g||"<"===o.operator||"<="===o.operator,i)if(y&&o.semver.prerelease&&o.semver.prerelease.length&&o.semver.major===y.major&&o.semver.minor===y.minor&&o.semver.patch===y.patch&&(y=!1),">"===o.operator||">="===o.operator){if(f=h(i,o,n),f===o&&f!==i)return!1}else if(">="===i.operator&&!o.test(i.semver))return!1;if(l)if(b&&o.semver.prerelease&&o.semver.prerelease.length&&o.semver.major===b.major&&o.semver.minor===b.minor&&o.semver.patch===b.patch&&(b=!1),"<"===o.operator||"<="===o.operator){if(m=p(l,o,n),m===o&&m!==l)return!1}else if("<="===l.operator&&!o.test(l.semver))return!1;if(!o.operator&&(l||i)&&0!==d)return!1}return!(i&&g&&!l&&0!==d)&&(!(l&&v&&!i&&0!==d)&&(!y&&!b))},h=(e,t,n)=>{if(!e)return t;const r=s(e.semver,t.semver,n);return r>0?e:r<0||">"===t.operator&&">="===e.operator?t:e},p=(e,t,n)=>{if(!e)return t;const r=s(e.semver,t.semver,n);return r<0?e:r>0||"<"===t.operator&&"<="===e.operator?t:e};e.exports=l},26364:function(e,t,n){"use strict";const r=n(37476),i=(e,t)=>new r(e,t).set.map(e=>e.map(e=>e.value).join(" ").trim().split(" "));e.exports=i},37403:function(e,t,n){"use strict";const r=n(37476),i=(e,t)=>{try{return new r(e,t).range||"*"}catch(n){return null}};e.exports=i},26108:function(e,t,n){"use strict";var r=n(528),i=n(70686),o=n(17239)(),a=n(69336),s=n(3468),l=r("%Math.floor%");e.exports=function(e,t){if("function"!==typeof e)throw new s("`fn` is not a function");if("number"!==typeof t||t<0||t>4294967295||l(t)!==t)throw new s("`length` must be a positive 32-bit integer");var n=arguments.length>2&&!!arguments[2],r=!0,c=!0;if("length"in e&&a){var u=a(e,"length");u&&!u.configurable&&(r=!1),u&&!u.writable&&(c=!1)}return(r||c||!n)&&(o?i(e,"length",t,!0,!0):i(e,"length",t)),e}},83346:function(e,t,n){"use strict";var r=n(48660),i=n(3468),o=function(e,t,n){for(var r,i=e;null!=(r=i.next);i=r)if(r.key===t)return i.next=r.next,n||(r.next=e.next,e.next=r),r},a=function(e,t){if(e){var n=o(e,t);return n&&n.value}},s=function(e,t,n){var r=o(e,t);r?r.value=n:e.next={key:t,next:e.next,value:n}},l=function(e,t){return!!e&&!!o(e,t)},c=function(e,t){if(e)return o(e,t,!0)};e.exports=function(){var e,t={assert:function(e){if(!t.has(e))throw new i("Side channel does not contain "+r(e))},delete:function(t){var n=c(e,t);return n&&e&&!e.next&&(e=void 0),!!n},get:function(t){return a(e,t)},has:function(t){return l(e,t)},set:function(t,n){e||(e={next:void 0}),s(e,t,n)}};return t}},27004:function(e,t,n){"use strict";var r=n(528),i=n(14607),o=n(48660),a=n(3468),s=r("%Map%",!0),l=i("Map.prototype.get",!0),c=i("Map.prototype.set",!0),u=i("Map.prototype.has",!0),d=i("Map.prototype.delete",!0),h=i("Map.prototype.size",!0);e.exports=!!s&&function(){var e,t={assert:function(e){if(!t.has(e))throw new a("Side channel does not contain "+o(e))},delete:function(t){if(e){var n=d(e,t);return 0===h(e)&&(e=void 0),n}return!1},get:function(t){if(e)return l(e,t)},has:function(t){return!!e&&u(e,t)},set:function(t,n){e||(e=new s),c(e,t,n)}};return t}},66348:function(e,t,n){"use strict";var r=n(528),i=n(14607),o=n(48660),a=n(27004),s=n(3468),l=r("%WeakMap%",!0),c=i("WeakMap.prototype.get",!0),u=i("WeakMap.prototype.set",!0),d=i("WeakMap.prototype.has",!0),h=i("WeakMap.prototype.delete",!0);e.exports=l?function(){var e,t,n={assert:function(e){if(!n.has(e))throw new s("Side channel does not contain "+o(e))},delete:function(n){if(l&&n&&("object"===typeof n||"function"===typeof n)){if(e)return h(e,n)}else if(a&&t)return t["delete"](n);return!1},get:function(n){return l&&n&&("object"===typeof n||"function"===typeof n)&&e?c(e,n):t&&t.get(n)},has:function(n){return l&&n&&("object"===typeof n||"function"===typeof n)&&e?d(e,n):!!t&&t.has(n)},set:function(n,r){l&&n&&("object"===typeof n||"function"===typeof n)?(e||(e=new l),u(e,n,r)):a&&(t||(t=a()),t.set(n,r))}};return n}:a},77575:function(e,t,n){"use strict";var r=n(3468),i=n(48660),o=n(83346),a=n(27004),s=n(66348),l=s||a||o;e.exports=function(){var e,t={assert:function(e){if(!t.has(e)){var n=e&&Object(e)===e?"the given object key":i(e);throw new r("Side channel does not contain "+n)}},delete:function(t){return!!e&&e["delete"](t)},get:function(t){return e&&e.get(t)},has:function(t){return!!e&&e.has(t)},set:function(t,n){e||(e=l()),e.set(t,n)}};return t}},59975:function(e,t,n){"use strict";var r=n(37101),i=Array.prototype.concat,o=Array.prototype.slice,a=e.exports=function(e){for(var t=[],n=0,a=e.length;n<a;n++){var s=e[n];r(s)?t=i.call(t,o.call(s)):t.push(s)}return t};a.wrap=function(e){return function(){return e(a(arguments))}}},37101:function(e){e.exports=function(e){return!(!e||"string"===typeof e)&&(e instanceof Array||Array.isArray(e)||e.length>=0&&(e.splice instanceof Function||Object.getOwnPropertyDescriptor(e,e.length-1)&&"String"!==e.constructor.name))}},4865:function(e,t,n){var r=n(98636),i=n(36846),o=n(93227),a=n(30049),s=n(75442),l=t;l.request=function(e,t){e="string"===typeof e?s.parse(e):o(e);var i=-1===n.g.location.protocol.search(/^https?:$/)?"http:":"",a=e.protocol||i,l=e.hostname||e.host,c=e.port,u=e.path||"/";l&&-1!==l.indexOf(":")&&(l="["+l+"]"),e.url=(l?a+"//"+l:"")+(c?":"+c:"")+u,e.method=(e.method||"GET").toUpperCase(),e.headers=e.headers||{};var d=new r(e);return t&&d.on("response",t),d},l.get=function(e,t){var n=l.request(e,t);return n.end(),n},l.ClientRequest=r,l.IncomingMessage=i.IncomingMessage,l.Agent=function(){},l.Agent.defaultMaxSockets=4,l.globalAgent=new l.Agent,l.STATUS_CODES=a,l.METHODS=["CHECKOUT","CONNECT","COPY","DELETE","GET","HEAD","LOCK","M-SEARCH","MERGE","MKACTIVITY","MKCOL","MOVE","NOTIFY","OPTIONS","PATCH","POST","PROPFIND","PROPPATCH","PURGE","PUT","REPORT","SEARCH","SUBSCRIBE","TRACE","UNLOCK","UNSUBSCRIBE"]},42271:function(e,t,n){var r;function i(){if(void 0!==r)return r;if(n.g.XMLHttpRequest){r=new n.g.XMLHttpRequest;try{r.open("GET",n.g.XDomainRequest?"/":"https://example.com")}catch(e){r=null}}else r=null;return r}function o(e){var t=i();if(!t)return!1;try{return t.responseType=e,t.responseType===e}catch(n){}return!1}function a(e){return"function"===typeof e}t.fetch=a(n.g.fetch)&&a(n.g.ReadableStream),t.writableStream=a(n.g.WritableStream),t.abortController=a(n.g.AbortController),t.arraybuffer=t.fetch||o("arraybuffer"),t.msstream=!t.fetch&&o("ms-stream"),t.mozchunkedarraybuffer=!t.fetch&&o("moz-chunked-arraybuffer"),t.overrideMimeType=t.fetch||!!i()&&a(i().overrideMimeType),r=null},98636:function(e,t,n){var r=n(1048)["Buffer"],i=n(39907),o=n(42271),a=n(35615),s=n(36846),l=n(48635),c=s.IncomingMessage,u=s.readyStates;function d(e,t){return o.fetch&&t?"fetch":o.mozchunkedarraybuffer?"moz-chunked-arraybuffer":o.msstream?"ms-stream":o.arraybuffer&&e?"arraybuffer":"text"}var h=e.exports=function(e){var t,n=this;l.Writable.call(n),n._opts=e,n._body=[],n._headers={},e.auth&&n.setHeader("Authorization","Basic "+r.from(e.auth).toString("base64")),Object.keys(e.headers).forEach(function(t){n.setHeader(t,e.headers[t])});var i=!0;if("disable-fetch"===e.mode||"requestTimeout"in e&&!o.abortController)i=!1,t=!0;else if("prefer-streaming"===e.mode)t=!1;else if("allow-wrong-content-type"===e.mode)t=!o.overrideMimeType;else{if(e.mode&&"default"!==e.mode&&"prefer-fast"!==e.mode)throw new Error("Invalid value for opts.mode");t=!0}n._mode=d(t,i),n._fetchTimer=null,n._socketTimeout=null,n._socketTimer=null,n.on("finish",function(){n._onFinish()})};function p(e){try{var t=e.status;return null!==t&&0!==t}catch(n){return!1}}a(h,l.Writable),h.prototype.setHeader=function(e,t){var n=this,r=e.toLowerCase();-1===f.indexOf(r)&&(n._headers[r]={name:e,value:t})},h.prototype.getHeader=function(e){var t=this._headers[e.toLowerCase()];return t?t.value:null},h.prototype.removeHeader=function(e){var t=this;delete t._headers[e.toLowerCase()]},h.prototype._onFinish=function(){var e=this;if(!e._destroyed){var t=e._opts;"timeout"in t&&0!==t.timeout&&e.setTimeout(t.timeout);var r=e._headers,a=null;"GET"!==t.method&&"HEAD"!==t.method&&(a=new Blob(e._body,{type:(r["content-type"]||{}).value||""}));var s=[];if(Object.keys(r).forEach(function(e){var t=r[e].name,n=r[e].value;Array.isArray(n)?n.forEach(function(e){s.push([t,e])}):s.push([t,n])}),"fetch"===e._mode){var l=null;if(o.abortController){var c=new AbortController;l=c.signal,e._fetchAbortController=c,"requestTimeout"in t&&0!==t.requestTimeout&&(e._fetchTimer=n.g.setTimeout(function(){e.emit("requestTimeout"),e._fetchAbortController&&e._fetchAbortController.abort()},t.requestTimeout))}n.g.fetch(e._opts.url,{method:e._opts.method,headers:s,body:a||void 0,mode:"cors",credentials:t.withCredentials?"include":"same-origin",signal:l}).then(function(t){e._fetchResponse=t,e._resetTimers(!1),e._connect()},function(t){e._resetTimers(!0),e._destroyed||e.emit("error",t)})}else{var d=e._xhr=new n.g.XMLHttpRequest;try{d.open(e._opts.method,e._opts.url,!0)}catch(h){return void i.nextTick(function(){e.emit("error",h)})}"responseType"in d&&(d.responseType=e._mode),"withCredentials"in d&&(d.withCredentials=!!t.withCredentials),"text"===e._mode&&"overrideMimeType"in d&&d.overrideMimeType("text/plain; charset=x-user-defined"),"requestTimeout"in t&&(d.timeout=t.requestTimeout,d.ontimeout=function(){e.emit("requestTimeout")}),s.forEach(function(e){d.setRequestHeader(e[0],e[1])}),e._response=null,d.onreadystatechange=function(){switch(d.readyState){case u.LOADING:case u.DONE:e._onXHRProgress();break}},"moz-chunked-arraybuffer"===e._mode&&(d.onprogress=function(){e._onXHRProgress()}),d.onerror=function(){e._destroyed||(e._resetTimers(!0),e.emit("error",new Error("XHR error")))};try{d.send(a)}catch(h){return void i.nextTick(function(){e.emit("error",h)})}}}},h.prototype._onXHRProgress=function(){var e=this;e._resetTimers(!1),p(e._xhr)&&!e._destroyed&&(e._response||e._connect(),e._response._onXHRProgress(e._resetTimers.bind(e)))},h.prototype._connect=function(){var e=this;e._destroyed||(e._response=new c(e._xhr,e._fetchResponse,e._mode,e._resetTimers.bind(e)),e._response.on("error",function(t){e.emit("error",t)}),e.emit("response",e._response))},h.prototype._write=function(e,t,n){var r=this;r._body.push(e),n()},h.prototype._resetTimers=function(e){var t=this;n.g.clearTimeout(t._socketTimer),t._socketTimer=null,e?(n.g.clearTimeout(t._fetchTimer),t._fetchTimer=null):t._socketTimeout&&(t._socketTimer=n.g.setTimeout(function(){t.emit("timeout")},t._socketTimeout))},h.prototype.abort=h.prototype.destroy=function(e){var t=this;t._destroyed=!0,t._resetTimers(!0),t._response&&(t._response._destroyed=!0),t._xhr?t._xhr.abort():t._fetchAbortController&&t._fetchAbortController.abort(),e&&t.emit("error",e)},h.prototype.end=function(e,t,n){var r=this;"function"===typeof e&&(n=e,e=void 0),l.Writable.prototype.end.call(r,e,t,n)},h.prototype.setTimeout=function(e,t){var n=this;t&&n.once("timeout",t),n._socketTimeout=e,n._resetTimers(!1)},h.prototype.flushHeaders=function(){},h.prototype.setNoDelay=function(){},h.prototype.setSocketKeepAlive=function(){};var f=["accept-charset","accept-encoding","access-control-request-headers","access-control-request-method","connection","content-length","cookie","cookie2","date","dnt","expect","host","keep-alive","origin","referer","te","trailer","transfer-encoding","upgrade","via"]},36846:function(e,t,n){var r=n(39907),i=n(1048)["Buffer"],o=n(42271),a=n(35615),s=n(48635),l=t.readyStates={UNSENT:0,OPENED:1,HEADERS_RECEIVED:2,LOADING:3,DONE:4},c=t.IncomingMessage=function(e,t,n,a){var l=this;if(s.Readable.call(l),l._mode=n,l.headers={},l.rawHeaders=[],l.trailers={},l.rawTrailers=[],l.on("end",function(){r.nextTick(function(){l.emit("close")})}),"fetch"===n){if(l._fetchResponse=t,l.url=t.url,l.statusCode=t.status,l.statusMessage=t.statusText,t.headers.forEach(function(e,t){l.headers[t.toLowerCase()]=e,l.rawHeaders.push(t,e)}),o.writableStream){var c=new WritableStream({write:function(e){return a(!1),new Promise(function(t,n){l._destroyed?n():l.push(i.from(e))?t():l._resumeFetch=t})},close:function(){a(!0),l._destroyed||l.push(null)},abort:function(e){a(!0),l._destroyed||l.emit("error",e)}});try{return void t.body.pipeTo(c).catch(function(e){a(!0),l._destroyed||l.emit("error",e)})}catch(m){}}var u=t.body.getReader();function d(){u.read().then(function(e){l._destroyed||(a(e.done),e.done?l.push(null):(l.push(i.from(e.value)),d()))}).catch(function(e){a(!0),l._destroyed||l.emit("error",e)})}d()}else{l._xhr=e,l._pos=0,l.url=e.responseURL,l.statusCode=e.status,l.statusMessage=e.statusText;var h=e.getAllResponseHeaders().split(/\r?\n/);if(h.forEach(function(e){var t=e.match(/^([^:]+):\s*(.*)/);if(t){var n=t[1].toLowerCase();"set-cookie"===n?(void 0===l.headers[n]&&(l.headers[n]=[]),l.headers[n].push(t[2])):void 0!==l.headers[n]?l.headers[n]+=", "+t[2]:l.headers[n]=t[2],l.rawHeaders.push(t[1],t[2])}}),l._charset="x-user-defined",!o.overrideMimeType){var p=l.rawHeaders["mime-type"];if(p){var f=p.match(/;\s*charset=([^;])(;|$)/);f&&(l._charset=f[1].toLowerCase())}l._charset||(l._charset="utf-8")}}};a(c,s.Readable),c.prototype._read=function(){var e=this,t=e._resumeFetch;t&&(e._resumeFetch=null,t())},c.prototype._onXHRProgress=function(e){var t=this,r=t._xhr,o=null;switch(t._mode){case"text":if(o=r.responseText,o.length>t._pos){var a=o.substr(t._pos);if("x-user-defined"===t._charset){for(var s=i.alloc(a.length),c=0;c<a.length;c++)s[c]=255&a.charCodeAt(c);t.push(s)}else t.push(a,t._charset);t._pos=o.length}break;case"arraybuffer":if(r.readyState!==l.DONE||!r.response)break;o=r.response,t.push(i.from(new Uint8Array(o)));break;case"moz-chunked-arraybuffer":if(o=r.response,r.readyState!==l.LOADING||!o)break;t.push(i.from(new Uint8Array(o)));break;case"ms-stream":if(o=r.response,r.readyState!==l.LOADING)break;var u=new n.g.MSStreamReader;u.onprogress=function(){u.result.byteLength>t._pos&&(t.push(i.from(new Uint8Array(u.result.slice(t._pos)))),t._pos=u.result.byteLength)},u.onload=function(){e(!0),t.push(null)},u.readAsArrayBuffer(o);break}t._xhr.readyState===l.DONE&&"ms-stream"!==t._mode&&(e(!0),t.push(null))}},5692:function(e){"use strict";function t(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}var n={};function r(e,r,i){function o(e,t,n){return"string"===typeof r?r:r(e,t,n)}i||(i=Error);var a=function(e){function n(t,n,r){return e.call(this,o(t,n,r))||this}return t(n,e),n}(i);a.prototype.name=i.name,a.prototype.code=e,n[e]=a}function i(e,t){if(Array.isArray(e)){var n=e.length;return e=e.map(function(e){return String(e)}),n>2?"one of ".concat(t," ").concat(e.slice(0,n-1).join(", "),", or ")+e[n-1]:2===n?"one of ".concat(t," ").concat(e[0]," or ").concat(e[1]):"of ".concat(t," ").concat(e[0])}return"of ".concat(t," ").concat(String(e))}function o(e,t,n){return e.substr(!n||n<0?0:+n,t.length)===t}function a(e,t,n){return(void 0===n||n>e.length)&&(n=e.length),e.substring(n-t.length,n)===t}function s(e,t,n){return"number"!==typeof n&&(n=0),!(n+t.length>e.length)&&-1!==e.indexOf(t,n)}r("ERR_INVALID_OPT_VALUE",function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'},TypeError),r("ERR_INVALID_ARG_TYPE",function(e,t,n){var r,l;if("string"===typeof t&&o(t,"not ")?(r="must not be",t=t.replace(/^not /,"")):r="must be",a(e," argument"))l="The ".concat(e," ").concat(r," ").concat(i(t,"type"));else{var c=s(e,".")?"property":"argument";l='The "'.concat(e,'" ').concat(c," ").concat(r," ").concat(i(t,"type"))}return l+=". Received type ".concat(typeof n),l},TypeError),r("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),r("ERR_METHOD_NOT_IMPLEMENTED",function(e){return"The "+e+" method is not implemented"}),r("ERR_STREAM_PREMATURE_CLOSE","Premature close"),r("ERR_STREAM_DESTROYED",function(e){return"Cannot call "+e+" after a stream was destroyed"}),r("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),r("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),r("ERR_STREAM_WRITE_AFTER_END","write after end"),r("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),r("ERR_UNKNOWN_ENCODING",function(e){return"Unknown encoding: "+e},TypeError),r("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),e.exports.F=n},60634:function(e,t,n){"use strict";var r=n(39907),i=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};e.exports=u;var o=n(56040),a=n(65464);n(35615)(u,o);for(var s=i(a.prototype),l=0;l<s.length;l++){var c=s[l];u.prototype[c]||(u.prototype[c]=a.prototype[c])}function u(e){if(!(this instanceof u))return new u(e);o.call(this,e),a.call(this,e),this.allowHalfOpen=!0,e&&(!1===e.readable&&(this.readable=!1),!1===e.writable&&(this.writable=!1),!1===e.allowHalfOpen&&(this.allowHalfOpen=!1,this.once("end",d)))}function d(){this._writableState.ended||r.nextTick(h,this)}function h(e){e.end()}Object.defineProperty(u.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(u.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(u.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(u.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}})},82108:function(e,t,n){"use strict";e.exports=i;var r=n(91846);function i(e){if(!(this instanceof i))return new i(e);r.call(this,e)}n(35615)(i,r),i.prototype._transform=function(e,t,n){n(null,e)}},56040:function(e,t,n){"use strict";var r,i=n(39907);e.exports=T,T.ReadableState=A;n(50046).EventEmitter;var o=function(e,t){return e.listeners(t).length},a=n(97845),s=n(1048).Buffer,l=("undefined"!==typeof n.g?n.g:"undefined"!==typeof window?window:"undefined"!==typeof self?self:{}).Uint8Array||function(){};function c(e){return s.from(e)}function u(e){return s.isBuffer(e)||e instanceof l}var d,h=n(78314);d=h&&h.debuglog?h.debuglog("stream"):function(){};var p,f,m,g=n(80317),v=n(34532),b=n(79983),y=b.getHighWaterMark,w=n(5692).F,O=w.ERR_INVALID_ARG_TYPE,S=w.ERR_STREAM_PUSH_AFTER_EOF,E=w.ERR_METHOD_NOT_IMPLEMENTED,x=w.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;n(35615)(T,a);var _=v.errorOrDestroy,k=["error","close","destroy","pause","resume"];function C(e,t,n){if("function"===typeof e.prependListener)return e.prependListener(t,n);e._events&&e._events[t]?Array.isArray(e._events[t])?e._events[t].unshift(n):e._events[t]=[n,e._events[t]]:e.on(t,n)}function A(e,t,i){r=r||n(60634),e=e||{},"boolean"!==typeof i&&(i=t instanceof r),this.objectMode=!!e.objectMode,i&&(this.objectMode=this.objectMode||!!e.readableObjectMode),this.highWaterMark=y(this,e,"readableHighWaterMark",i),this.buffer=new g,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(p||(p=n(18888).I),this.decoder=new p(e.encoding),this.encoding=e.encoding)}function T(e){if(r=r||n(60634),!(this instanceof T))return new T(e);var t=this instanceof r;this._readableState=new A(e,this,t),this.readable=!0,e&&("function"===typeof e.read&&(this._read=e.read),"function"===typeof e.destroy&&(this._destroy=e.destroy)),a.call(this)}function R(e,t,n,r,i){d("readableAddChunk",t);var o,a=e._readableState;if(null===t)a.reading=!1,L(e,a);else if(i||(o=P(a,t)),o)_(e,o);else if(a.objectMode||t&&t.length>0)if("string"===typeof t||a.objectMode||Object.getPrototypeOf(t)===s.prototype||(t=c(t)),r)a.endEmitted?_(e,new x):N(e,a,t,!0);else if(a.ended)_(e,new S);else{if(a.destroyed)return!1;a.reading=!1,a.decoder&&!n?(t=a.decoder.write(t),a.objectMode||0!==t.length?N(e,a,t,!1):V(e,a)):N(e,a,t,!1)}else r||(a.reading=!1,V(e,a));return!a.ended&&(a.length<a.highWaterMark||0===a.length)}function N(e,t,n,r){t.flowing&&0===t.length&&!t.sync?(t.awaitDrain=0,e.emit("data",n)):(t.length+=t.objectMode?1:n.length,r?t.buffer.unshift(n):t.buffer.push(n),t.needReadable&&B(e)),V(e,t)}function P(e,t){var n;return u(t)||"string"===typeof t||void 0===t||e.objectMode||(n=new O("chunk",["string","Buffer","Uint8Array"],t)),n}Object.defineProperty(T.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),T.prototype.destroy=v.destroy,T.prototype._undestroy=v.undestroy,T.prototype._destroy=function(e,t){t(e)},T.prototype.push=function(e,t){var n,r=this._readableState;return r.objectMode?n=!0:"string"===typeof e&&(t=t||r.defaultEncoding,t!==r.encoding&&(e=s.from(e,t),t=""),n=!0),R(this,e,t,!1,n)},T.prototype.unshift=function(e){return R(this,e,null,!0,!1)},T.prototype.isPaused=function(){return!1===this._readableState.flowing},T.prototype.setEncoding=function(e){p||(p=n(18888).I);var t=new p(e);this._readableState.decoder=t,this._readableState.encoding=this._readableState.decoder.encoding;var r=this._readableState.buffer.head,i="";while(null!==r)i+=t.write(r.data),r=r.next;return this._readableState.buffer.clear(),""!==i&&this._readableState.buffer.push(i),this._readableState.length=i.length,this};var I=1073741824;function M(e){return e>=I?e=I:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function D(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!==e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=M(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function L(e,t){if(d("onEofChunk"),!t.ended){if(t.decoder){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,t.sync?B(e):(t.needReadable=!1,t.emittedReadable||(t.emittedReadable=!0,$(e)))}}function B(e){var t=e._readableState;d("emitReadable",t.needReadable,t.emittedReadable),t.needReadable=!1,t.emittedReadable||(d("emitReadable",t.flowing),t.emittedReadable=!0,i.nextTick($,e))}function $(e){var t=e._readableState;d("emitReadable_",t.destroyed,t.length,t.ended),t.destroyed||!t.length&&!t.ended||(e.emit("readable"),t.emittedReadable=!1),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,Q(e)}function V(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(F,e,t))}function F(e,t){while(!t.reading&&!t.ended&&(t.length<t.highWaterMark||t.flowing&&0===t.length)){var n=t.length;if(d("maybeReadMore read 0"),e.read(0),n===t.length)break}t.readingMore=!1}function j(e){return function(){var t=e._readableState;d("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&o(e,"data")&&(t.flowing=!0,Q(e))}}function U(e){var t=e._readableState;t.readableListening=e.listenerCount("readable")>0,t.resumeScheduled&&!t.paused?t.flowing=!0:e.listenerCount("data")>0&&e.resume()}function G(e){d("readable nexttick read 0"),e.read(0)}function H(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(q,e,t))}function q(e,t){d("resume",t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit("resume"),Q(e),t.flowing&&!t.reading&&e.read(0)}function Q(e){var t=e._readableState;d("flow",t.flowing);while(t.flowing&&null!==e.read());}function z(e,t){return 0===t.length?null:(t.objectMode?n=t.buffer.shift():!e||e>=t.length?(n=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.first():t.buffer.concat(t.length),t.buffer.clear()):n=t.buffer.consume(e,t.decoder),n);var n}function K(e){var t=e._readableState;d("endReadable",t.endEmitted),t.endEmitted||(t.ended=!0,i.nextTick(W,t,e))}function W(e,t){if(d("endReadableNT",e.endEmitted,e.length),!e.endEmitted&&0===e.length&&(e.endEmitted=!0,t.readable=!1,t.emit("end"),e.autoDestroy)){var n=t._writableState;(!n||n.autoDestroy&&n.finished)&&t.destroy()}}function X(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1}T.prototype.read=function(e){d("read",e),e=parseInt(e,10);var t=this._readableState,n=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&((0!==t.highWaterMark?t.length>=t.highWaterMark:t.length>0)||t.ended))return d("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?K(this):B(this),null;if(e=D(e,t),0===e&&t.ended)return 0===t.length&&K(this),null;var r,i=t.needReadable;return d("need readable",i),(0===t.length||t.length-e<t.highWaterMark)&&(i=!0,d("length less than watermark",i)),t.ended||t.reading?(i=!1,d("reading or ended",i)):i&&(d("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=D(n,t))),r=e>0?z(e,t):null,null===r?(t.needReadable=t.length<=t.highWaterMark,e=0):(t.length-=e,t.awaitDrain=0),0===t.length&&(t.ended||(t.needReadable=!0),n!==e&&t.ended&&K(this)),null!==r&&this.emit("data",r),r},T.prototype._read=function(e){_(this,new E("_read()"))},T.prototype.pipe=function(e,t){var n=this,r=this._readableState;switch(r.pipesCount){case 0:r.pipes=e;break;case 1:r.pipes=[r.pipes,e];break;default:r.pipes.push(e);break}r.pipesCount+=1,d("pipe count=%d opts=%j",r.pipesCount,t);var a=(!t||!1!==t.end)&&e!==i.stdout&&e!==i.stderr,s=a?c:b;function l(e,t){d("onunpipe"),e===n&&t&&!1===t.hasUnpiped&&(t.hasUnpiped=!0,p())}function c(){d("onend"),e.end()}r.endEmitted?i.nextTick(s):n.once("end",s),e.on("unpipe",l);var u=j(n);e.on("drain",u);var h=!1;function p(){d("cleanup"),e.removeListener("close",g),e.removeListener("finish",v),e.removeListener("drain",u),e.removeListener("error",m),e.removeListener("unpipe",l),n.removeListener("end",c),n.removeListener("end",b),n.removeListener("data",f),h=!0,!r.awaitDrain||e._writableState&&!e._writableState.needDrain||u()}function f(t){d("ondata");var i=e.write(t);d("dest.write",i),!1===i&&((1===r.pipesCount&&r.pipes===e||r.pipesCount>1&&-1!==X(r.pipes,e))&&!h&&(d("false write response, pause",r.awaitDrain),r.awaitDrain++),n.pause())}function m(t){d("onerror",t),b(),e.removeListener("error",m),0===o(e,"error")&&_(e,t)}function g(){e.removeListener("finish",v),b()}function v(){d("onfinish"),e.removeListener("close",g),b()}function b(){d("unpipe"),n.unpipe(e)}return n.on("data",f),C(e,"error",m),e.once("close",g),e.once("finish",v),e.emit("pipe",n),r.flowing||(d("pipe resume"),n.resume()),e},T.prototype.unpipe=function(e){var t=this._readableState,n={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes||(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,n)),this;if(!e){var r=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)r[o].emit("unpipe",this,{hasUnpiped:!1});return this}var a=X(t.pipes,e);return-1===a||(t.pipes.splice(a,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,n)),this},T.prototype.on=function(e,t){var n=a.prototype.on.call(this,e,t),r=this._readableState;return"data"===e?(r.readableListening=this.listenerCount("readable")>0,!1!==r.flowing&&this.resume()):"readable"===e&&(r.endEmitted||r.readableListening||(r.readableListening=r.needReadable=!0,r.flowing=!1,r.emittedReadable=!1,d("on readable",r.length,r.reading),r.length?B(this):r.reading||i.nextTick(G,this))),n},T.prototype.addListener=T.prototype.on,T.prototype.removeListener=function(e,t){var n=a.prototype.removeListener.call(this,e,t);return"readable"===e&&i.nextTick(U,this),n},T.prototype.removeAllListeners=function(e){var t=a.prototype.removeAllListeners.apply(this,arguments);return"readable"!==e&&void 0!==e||i.nextTick(U,this),t},T.prototype.resume=function(){var e=this._readableState;return e.flowing||(d("resume"),e.flowing=!e.readableListening,H(this,e)),e.paused=!1,this},T.prototype.pause=function(){return d("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(d("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},T.prototype.wrap=function(e){var t=this,n=this._readableState,r=!1;for(var i in e.on("end",function(){if(d("wrapped end"),n.decoder&&!n.ended){var e=n.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on("data",function(i){if(d("wrapped data"),n.decoder&&(i=n.decoder.write(i)),(!n.objectMode||null!==i&&void 0!==i)&&(n.objectMode||i&&i.length)){var o=t.push(i);o||(r=!0,e.pause())}}),e)void 0===this[i]&&"function"===typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var o=0;o<k.length;o++)e.on(k[o],this.emit.bind(this,k[o]));return this._read=function(t){d("wrapped _read",t),r&&(r=!1,e.resume())},this},"function"===typeof Symbol&&(T.prototype[Symbol.asyncIterator]=function(){return void 0===f&&(f=n(87743)),f(this)}),Object.defineProperty(T.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Object.defineProperty(T.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(T.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(e){this._readableState&&(this._readableState.flowing=e)}}),T._fromList=z,Object.defineProperty(T.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}}),"function"===typeof Symbol&&(T.from=function(e,t){return void 0===m&&(m=n(2769)),m(T,e,t)})},91846:function(e,t,n){"use strict";e.exports=u;var r=n(5692).F,i=r.ERR_METHOD_NOT_IMPLEMENTED,o=r.ERR_MULTIPLE_CALLBACK,a=r.ERR_TRANSFORM_ALREADY_TRANSFORMING,s=r.ERR_TRANSFORM_WITH_LENGTH_0,l=n(60634);function c(e,t){var n=this._transformState;n.transforming=!1;var r=n.writecb;if(null===r)return this.emit("error",new o);n.writechunk=null,n.writecb=null,null!=t&&this.push(t),r(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function u(e){if(!(this instanceof u))return new u(e);l.call(this,e),this._transformState={afterTransform:c.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"===typeof e.transform&&(this._transform=e.transform),"function"===typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",d)}function d(){var e=this;"function"!==typeof this._flush||this._readableState.destroyed?h(this,null,null):this._flush(function(t,n){h(e,t,n)})}function h(e,t,n){if(t)return e.emit("error",t);if(null!=n&&e.push(n),e._writableState.length)throw new s;if(e._transformState.transforming)throw new a;return e.push(null)}n(35615)(u,l),u.prototype.push=function(e,t){return this._transformState.needTransform=!1,l.prototype.push.call(this,e,t)},u.prototype._transform=function(e,t,n){n(new i("_transform()"))},u.prototype._write=function(e,t,n){var r=this._transformState;if(r.writecb=n,r.writechunk=e,r.writeencoding=t,!r.transforming){var i=this._readableState;(r.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},u.prototype._read=function(e){var t=this._transformState;null===t.writechunk||t.transforming?t.needTransform=!0:(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform))},u.prototype._destroy=function(e,t){l.prototype._destroy.call(this,e,function(e){t(e)})}},65464:function(e,t,n){"use strict";var r,i=n(39907);function o(e){var t=this;this.next=null,this.entry=null,this.finish=function(){q(t,e)}}e.exports=A,A.WritableState=C;var a={deprecate:n(66732)},s=n(97845),l=n(1048).Buffer,c=("undefined"!==typeof n.g?n.g:"undefined"!==typeof window?window:"undefined"!==typeof self?self:{}).Uint8Array||function(){};function u(e){return l.from(e)}function d(e){return l.isBuffer(e)||e instanceof c}var h,p=n(34532),f=n(79983),m=f.getHighWaterMark,g=n(5692).F,v=g.ERR_INVALID_ARG_TYPE,b=g.ERR_METHOD_NOT_IMPLEMENTED,y=g.ERR_MULTIPLE_CALLBACK,w=g.ERR_STREAM_CANNOT_PIPE,O=g.ERR_STREAM_DESTROYED,S=g.ERR_STREAM_NULL_VALUES,E=g.ERR_STREAM_WRITE_AFTER_END,x=g.ERR_UNKNOWN_ENCODING,_=p.errorOrDestroy;function k(){}function C(e,t,i){r=r||n(60634),e=e||{},"boolean"!==typeof i&&(i=t instanceof r),this.objectMode=!!e.objectMode,i&&(this.objectMode=this.objectMode||!!e.writableObjectMode),this.highWaterMark=m(this,e,"writableHighWaterMark",i),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var a=!1===e.decodeStrings;this.decodeStrings=!a,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){L(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new o(this)}function A(e){r=r||n(60634);var t=this instanceof r;if(!t&&!h.call(A,this))return new A(e);this._writableState=new C(e,this,t),this.writable=!0,e&&("function"===typeof e.write&&(this._write=e.write),"function"===typeof e.writev&&(this._writev=e.writev),"function"===typeof e.destroy&&(this._destroy=e.destroy),"function"===typeof e.final&&(this._final=e.final)),s.call(this)}function T(e,t){var n=new E;_(e,n),i.nextTick(t,n)}function R(e,t,n,r){var o;return null===n?o=new S:"string"===typeof n||t.objectMode||(o=new v("chunk",["string","Buffer"],n)),!o||(_(e,o),i.nextTick(r,o),!1)}function N(e,t,n){return e.objectMode||!1===e.decodeStrings||"string"!==typeof t||(t=l.from(t,n)),t}function P(e,t,n,r,i,o){if(!n){var a=N(t,r,i);r!==a&&(n=!0,i="buffer",r=a)}var s=t.objectMode?1:r.length;t.length+=s;var l=t.length<t.highWaterMark;if(l||(t.needDrain=!0),t.writing||t.corked){var c=t.lastBufferedRequest;t.lastBufferedRequest={chunk:r,encoding:i,isBuf:n,callback:o,next:null},c?c.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else I(e,t,!1,s,r,i,o);return l}function I(e,t,n,r,i,o,a){t.writelen=r,t.writecb=a,t.writing=!0,t.sync=!0,t.destroyed?t.onwrite(new O("write")):n?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function M(e,t,n,r,o){--t.pendingcb,n?(i.nextTick(o,r),i.nextTick(G,e,t),e._writableState.errorEmitted=!0,_(e,r)):(o(r),e._writableState.errorEmitted=!0,_(e,r),G(e,t))}function D(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function L(e,t){var n=e._writableState,r=n.sync,o=n.writecb;if("function"!==typeof o)throw new y;if(D(n),t)M(e,n,r,t,o);else{var a=F(n)||e.destroyed;a||n.corked||n.bufferProcessing||!n.bufferedRequest||V(e,n),r?i.nextTick(B,e,n,a,o):B(e,n,a,o)}}function B(e,t,n,r){n||$(e,t),t.pendingcb--,r(),G(e,t)}function $(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function V(e,t){t.bufferProcessing=!0;var n=t.bufferedRequest;if(e._writev&&n&&n.next){var r=t.bufferedRequestCount,i=new Array(r),a=t.corkedRequestsFree;a.entry=n;var s=0,l=!0;while(n)i[s]=n,n.isBuf||(l=!1),n=n.next,s+=1;i.allBuffers=l,I(e,t,!0,t.length,i,"",a.finish),t.pendingcb++,t.lastBufferedRequest=null,a.next?(t.corkedRequestsFree=a.next,a.next=null):t.corkedRequestsFree=new o(t),t.bufferedRequestCount=0}else{while(n){var c=n.chunk,u=n.encoding,d=n.callback,h=t.objectMode?1:c.length;if(I(e,t,!1,h,c,u,d),n=n.next,t.bufferedRequestCount--,t.writing)break}null===n&&(t.lastBufferedRequest=null)}t.bufferedRequest=n,t.bufferProcessing=!1}function F(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function j(e,t){e._final(function(n){t.pendingcb--,n&&_(e,n),t.prefinished=!0,e.emit("prefinish"),G(e,t)})}function U(e,t){t.prefinished||t.finalCalled||("function"!==typeof e._final||t.destroyed?(t.prefinished=!0,e.emit("prefinish")):(t.pendingcb++,t.finalCalled=!0,i.nextTick(j,e,t)))}function G(e,t){var n=F(t);if(n&&(U(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"),t.autoDestroy))){var r=e._readableState;(!r||r.autoDestroy&&r.endEmitted)&&e.destroy()}return n}function H(e,t,n){t.ending=!0,G(e,t),n&&(t.finished?i.nextTick(n):e.once("finish",n)),t.ended=!0,e.writable=!1}function q(e,t,n){var r=e.entry;e.entry=null;while(r){var i=r.callback;t.pendingcb--,i(n),r=r.next}t.corkedRequestsFree.next=e}n(35615)(A,s),C.prototype.getBuffer=function(){var e=this.bufferedRequest,t=[];while(e)t.push(e),e=e.next;return t},function(){try{Object.defineProperty(C.prototype,"buffer",{get:a.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"===typeof Symbol&&Symbol.hasInstance&&"function"===typeof Function.prototype[Symbol.hasInstance]?(h=Function.prototype[Symbol.hasInstance],Object.defineProperty(A,Symbol.hasInstance,{value:function(e){return!!h.call(this,e)||this===A&&(e&&e._writableState instanceof C)}})):h=function(e){return e instanceof this},A.prototype.pipe=function(){_(this,new w)},A.prototype.write=function(e,t,n){var r=this._writableState,i=!1,o=!r.objectMode&&d(e);return o&&!l.isBuffer(e)&&(e=u(e)),"function"===typeof t&&(n=t,t=null),o?t="buffer":t||(t=r.defaultEncoding),"function"!==typeof n&&(n=k),r.ending?T(this,n):(o||R(this,r,e,n))&&(r.pendingcb++,i=P(this,r,o,e,t,n)),i},A.prototype.cork=function(){this._writableState.corked++},A.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.bufferProcessing||!e.bufferedRequest||V(this,e))},A.prototype.setDefaultEncoding=function(e){if("string"===typeof e&&(e=e.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())>-1))throw new x(e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(A.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(A.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),A.prototype._write=function(e,t,n){n(new b("_write()"))},A.prototype._writev=null,A.prototype.end=function(e,t,n){var r=this._writableState;return"function"===typeof e?(n=e,e=null,t=null):"function"===typeof t&&(n=t,t=null),null!==e&&void 0!==e&&this.write(e,t),r.corked&&(r.corked=1,this.uncork()),r.ending||H(this,r,n),this},Object.defineProperty(A.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(A.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),A.prototype.destroy=p.destroy,A.prototype._undestroy=p.undestroy,A.prototype._destroy=function(e,t){t(e)}},87743:function(e,t,n){"use strict";var r,i=n(39907);function o(e,t,n){return t=a(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function a(e){var t=s(e,"string");return"symbol"===typeof t?t:String(t)}function s(e,t){if("object"!==typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!==typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}var l=n(86138),c=Symbol("lastResolve"),u=Symbol("lastReject"),d=Symbol("error"),h=Symbol("ended"),p=Symbol("lastPromise"),f=Symbol("handlePromise"),m=Symbol("stream");function g(e,t){return{value:e,done:t}}function v(e){var t=e[c];if(null!==t){var n=e[m].read();null!==n&&(e[p]=null,e[c]=null,e[u]=null,t(g(n,!1)))}}function b(e){i.nextTick(v,e)}function y(e,t){return function(n,r){e.then(function(){t[h]?n(g(void 0,!0)):t[f](n,r)},r)}}var w=Object.getPrototypeOf(function(){}),O=Object.setPrototypeOf((r={get stream(){return this[m]},next:function(){var e=this,t=this[d];if(null!==t)return Promise.reject(t);if(this[h])return Promise.resolve(g(void 0,!0));if(this[m].destroyed)return new Promise(function(t,n){i.nextTick(function(){e[d]?n(e[d]):t(g(void 0,!0))})});var n,r=this[p];if(r)n=new Promise(y(r,this));else{var o=this[m].read();if(null!==o)return Promise.resolve(g(o,!1));n=new Promise(this[f])}return this[p]=n,n}},o(r,Symbol.asyncIterator,function(){return this}),o(r,"return",function(){var e=this;return new Promise(function(t,n){e[m].destroy(null,function(e){e?n(e):t(g(void 0,!0))})})}),r),w),S=function(e){var t,n=Object.create(O,(t={},o(t,m,{value:e,writable:!0}),o(t,c,{value:null,writable:!0}),o(t,u,{value:null,writable:!0}),o(t,d,{value:null,writable:!0}),o(t,h,{value:e._readableState.endEmitted,writable:!0}),o(t,f,{value:function(e,t){var r=n[m].read();r?(n[p]=null,n[c]=null,n[u]=null,e(g(r,!1))):(n[c]=e,n[u]=t)},writable:!0}),t));return n[p]=null,l(e,function(e){if(e&&"ERR_STREAM_PREMATURE_CLOSE"!==e.code){var t=n[u];return null!==t&&(n[p]=null,n[c]=null,n[u]=null,t(e)),void(n[d]=e)}var r=n[c];null!==r&&(n[p]=null,n[c]=null,n[u]=null,r(g(void 0,!0))),n[h]=!0}),e.on("readable",b.bind(null,n)),n};e.exports=S},80317:function(e,t,n){"use strict";function r(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?r(Object(n),!0).forEach(function(t){o(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function o(e,t,n){return t=c(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function s(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,c(r.key),r)}}function l(e,t,n){return t&&s(e.prototype,t),n&&s(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function c(e){var t=u(e,"string");return"symbol"===typeof t?t:String(t)}function u(e,t){if("object"!==typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!==typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}var d=n(1048),h=d.Buffer,p=n(62080),f=p.inspect,m=f&&f.custom||"inspect";function g(e,t,n){h.prototype.copy.call(e,t,n)}e.exports=function(){function e(){a(this,e),this.head=null,this.tail=null,this.length=0}return l(e,[{key:"push",value:function(e){var t={data:e,next:null};this.length>0?this.tail.next=t:this.head=t,this.tail=t,++this.length}},{key:"unshift",value:function(e){var t={data:e,next:this.head};0===this.length&&(this.tail=t),this.head=t,++this.length}},{key:"shift",value:function(){if(0!==this.length){var e=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(e){if(0===this.length)return"";var t=this.head,n=""+t.data;while(t=t.next)n+=e+t.data;return n}},{key:"concat",value:function(e){if(0===this.length)return h.alloc(0);var t=h.allocUnsafe(e>>>0),n=this.head,r=0;while(n)g(n.data,t,r),r+=n.data.length,n=n.next;return t}},{key:"consume",value:function(e,t){var n;return e<this.head.data.length?(n=this.head.data.slice(0,e),this.head.data=this.head.data.slice(e)):n=e===this.head.data.length?this.shift():t?this._getString(e):this._getBuffer(e),n}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(e){var t=this.head,n=1,r=t.data;e-=r.length;while(t=t.next){var i=t.data,o=e>i.length?i.length:e;if(o===i.length?r+=i:r+=i.slice(0,e),e-=o,0===e){o===i.length?(++n,t.next?this.head=t.next:this.head=this.tail=null):(this.head=t,t.data=i.slice(o));break}++n}return this.length-=n,r}},{key:"_getBuffer",value:function(e){var t=h.allocUnsafe(e),n=this.head,r=1;n.data.copy(t),e-=n.data.length;while(n=n.next){var i=n.data,o=e>i.length?i.length:e;if(i.copy(t,t.length-e,0,o),e-=o,0===e){o===i.length?(++r,n.next?this.head=n.next:this.head=this.tail=null):(this.head=n,n.data=i.slice(o));break}++r}return this.length-=r,t}},{key:m,value:function(e,t){return f(this,i(i({},t),{},{depth:0,customInspect:!1}))}}]),e}()},34532:function(e,t,n){"use strict";var r=n(39907);function i(e,t){var n=this,i=this._readableState&&this._readableState.destroyed,s=this._writableState&&this._writableState.destroyed;return i||s?(t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,r.nextTick(l,this,e)):r.nextTick(l,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?n._writableState?n._writableState.errorEmitted?r.nextTick(a,n):(n._writableState.errorEmitted=!0,r.nextTick(o,n,e)):r.nextTick(o,n,e):t?(r.nextTick(a,n),t(e)):r.nextTick(a,n)}),this)}function o(e,t){l(e,t),a(e)}function a(e){e._writableState&&!e._writableState.emitClose||e._readableState&&!e._readableState.emitClose||e.emit("close")}function s(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function l(e,t){e.emit("error",t)}function c(e,t){var n=e._readableState,r=e._writableState;n&&n.autoDestroy||r&&r.autoDestroy?e.destroy(t):e.emit("error",t)}e.exports={destroy:i,undestroy:s,errorOrDestroy:c}},86138:function(e,t,n){"use strict";var r=n(5692).F.ERR_STREAM_PREMATURE_CLOSE;function i(e){var t=!1;return function(){if(!t){t=!0;for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];e.apply(this,r)}}}function o(){}function a(e){return e.setHeader&&"function"===typeof e.abort}function s(e,t,n){if("function"===typeof t)return s(e,null,t);t||(t={}),n=i(n||o);var l=t.readable||!1!==t.readable&&e.readable,c=t.writable||!1!==t.writable&&e.writable,u=function(){e.writable||h()},d=e._writableState&&e._writableState.finished,h=function(){c=!1,d=!0,l||n.call(e)},p=e._readableState&&e._readableState.endEmitted,f=function(){l=!1,p=!0,c||n.call(e)},m=function(t){n.call(e,t)},g=function(){var t;return l&&!p?(e._readableState&&e._readableState.ended||(t=new r),n.call(e,t)):c&&!d?(e._writableState&&e._writableState.ended||(t=new r),n.call(e,t)):void 0},v=function(){e.req.on("finish",h)};return a(e)?(e.on("complete",h),e.on("abort",g),e.req?v():e.on("request",v)):c&&!e._writableState&&(e.on("end",u),e.on("close",u)),e.on("end",f),e.on("finish",h),!1!==t.error&&e.on("error",m),e.on("close",g),function(){e.removeListener("complete",h),e.removeListener("abort",g),e.removeListener("request",v),e.req&&e.req.removeListener("finish",h),e.removeListener("end",u),e.removeListener("close",u),e.removeListener("finish",h),e.removeListener("end",f),e.removeListener("error",m),e.removeListener("close",g)}}e.exports=s},2769:function(e){e.exports=function(){throw new Error("Readable.from is not available in the browser")}},55506:function(e,t,n){"use strict";var r;function i(e){var t=!1;return function(){t||(t=!0,e.apply(void 0,arguments))}}var o=n(5692).F,a=o.ERR_MISSING_ARGS,s=o.ERR_STREAM_DESTROYED;function l(e){if(e)throw e}function c(e){return e.setHeader&&"function"===typeof e.abort}function u(e,t,o,a){a=i(a);var l=!1;e.on("close",function(){l=!0}),void 0===r&&(r=n(86138)),r(e,{readable:t,writable:o},function(e){if(e)return a(e);l=!0,a()});var u=!1;return function(t){if(!l&&!u)return u=!0,c(e)?e.abort():"function"===typeof e.destroy?e.destroy():void a(t||new s("pipe"))}}function d(e){e()}function h(e,t){return e.pipe(t)}function p(e){return e.length?"function"!==typeof e[e.length-1]?l:e.pop():l}function f(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r,i=p(t);if(Array.isArray(t[0])&&(t=t[0]),t.length<2)throw new a("streams");var o=t.map(function(e,n){var a=n<t.length-1,s=n>0;return u(e,a,s,function(e){r||(r=e),e&&o.forEach(d),a||(o.forEach(d),i(r))})});return t.reduce(h)}e.exports=f},79983:function(e,t,n){"use strict";var r=n(5692).F.ERR_INVALID_OPT_VALUE;function i(e,t,n){return null!=e.highWaterMark?e.highWaterMark:t?e[n]:null}function o(e,t,n,o){var a=i(t,o,n);if(null!=a){if(!isFinite(a)||Math.floor(a)!==a||a<0){var s=o?n:"highWaterMark";throw new r(s,a)}return Math.floor(a)}return e.objectMode?16:16384}e.exports={getHighWaterMark:o}},97845:function(e,t,n){e.exports=n(50046).EventEmitter},48635:function(e,t,n){t=e.exports=n(56040),t.Stream=t,t.Readable=t,t.Writable=n(65464),t.Duplex=n(60634),t.Transform=n(91846),t.PassThrough=n(82108),t.finished=n(86138),t.pipeline=n(55506)},18888:function(e,t,n){"use strict";var r=n(25636).Buffer,i=r.isEncoding||function(e){switch(e=""+e,e&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function o(e){if(!e)return"utf8";var t;while(1)switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}function a(e){var t=o(e);if("string"!==typeof t&&(r.isEncoding===i||!i(e)))throw new Error("Unknown encoding: "+e);return t||e}function s(e){var t;switch(this.encoding=a(e),this.encoding){case"utf16le":this.text=f,this.end=m,t=4;break;case"utf8":this.fillLast=d,t=4;break;case"base64":this.text=g,this.end=v,t=3;break;default:return this.write=b,void(this.end=y)}this.lastNeed=0,this.lastTotal=0,this.lastChar=r.allocUnsafe(t)}function l(e){return e<=127?0:e>>5===6?2:e>>4===14?3:e>>3===30?4:e>>6===2?-1:-2}function c(e,t,n){var r=t.length-1;if(r<n)return 0;var i=l(t[r]);return i>=0?(i>0&&(e.lastNeed=i-1),i):--r<n||-2===i?0:(i=l(t[r]),i>=0?(i>0&&(e.lastNeed=i-2),i):--r<n||-2===i?0:(i=l(t[r]),i>=0?(i>0&&(2===i?i=0:e.lastNeed=i-3),i):0))}function u(e,t,n){if(128!==(192&t[0]))return e.lastNeed=0,"�";if(e.lastNeed>1&&t.length>1){if(128!==(192&t[1]))return e.lastNeed=1,"�";if(e.lastNeed>2&&t.length>2&&128!==(192&t[2]))return e.lastNeed=2,"�"}}function d(e){var t=this.lastTotal-this.lastNeed,n=u(this,e,t);return void 0!==n?n:this.lastNeed<=e.length?(e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(e.copy(this.lastChar,t,0,e.length),void(this.lastNeed-=e.length))}function h(e,t){var n=c(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=n;var r=e.length-(n-this.lastNeed);return e.copy(this.lastChar,0,r),e.toString("utf8",t,r)}function p(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+"�":t}function f(e,t){if((e.length-t)%2===0){var n=e.toString("utf16le",t);if(n){var r=n.charCodeAt(n.length-1);if(r>=55296&&r<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],n.slice(0,-1)}return n}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function m(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var n=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,n)}return t}function g(e,t){var n=(e.length-t)%3;return 0===n?e.toString("base64",t):(this.lastNeed=3-n,this.lastTotal=3,1===n?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-n))}function v(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function b(e){return e.toString(this.encoding)}function y(e){return e&&e.length?this.write(e):""}t.I=s,s.prototype.write=function(e){if(0===e.length)return"";var t,n;if(this.lastNeed){if(t=this.fillLast(e),void 0===t)return"";n=this.lastNeed,this.lastNeed=0}else n=0;return n<e.length?t?t+this.text(e,n):this.text(e,n):t||""},s.prototype.end=p,s.prototype.text=h,s.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length}},90703:function(e,t,n){"use strict";n.d(t,{v:function(){return r}});const r="ResourceList"},20284:function(e,t,n){"use strict";n.d(t,{J:function(){return o}});var r=n(74302),i=n(68851);const o=["nameSort","id"];t.A={computed:{sortFields(){const e=this.groupSort||("function"===typeof this.groupBy?null:this.groupBy);let t=(this.groupBy?e:null)||[],n=[];const r=(this.columns||this.headers).find(e=>e&&e.name&&e.name.toLowerCase()===this.sortBy.toLowerCase());return this.sortBy&&r&&r.sort&&(n=r.sort),Array.isArray(t)||(t=[t]),Array.isArray(n)||(n=[n]),(0,i.sb)([...t,...n].concat(...this.mandatorySort||o))},arrangedRows(){if(this.externalPaginationEnabled)return;let e;const t=this.sortGeneration||this.sortGenerationFn?.apply(this);if(t&&(e=`${t}/${this.rows.length}/${this.descending}/${this.sortFields.join(",")}`,this.cacheKey===e&&this.cachedRowsRef===this.rows))return this.cachedRows;const n=(0,r.Ul)(this.rows,this.sortFields,this.descending);return e&&(this.cacheKey=e,this.cachedRows=n,this.cachedRowsRef=this.rows),n}},data(){let e=null,t=!1;if(this._defaultSortBy=this.defaultSortBy,!this._defaultSortBy){const e=this.headers.find(e=>!!e.defaultSort),n=this.headers.find(e=>"name"===e.name);if(e)this._defaultSortBy=e.name,t=e.defaultSortDescending||!1;else if(n)this._defaultSortBy=n.name;else{const e=this.headers.filter(e=>"state"!==e.name)[0];this._defaultSortBy=e?e.name:"id"}}return e&&this.headers.find(t=>t.name===e)||(e=this._defaultSortBy),{sortBy:e,descending:t,cachedRows:null,cachedRowsRef:null,cacheKey:null}},methods:{changeSort(e,t){this.sortBy=e,this.descending=t,this.setPage(1)}},watch:{sortFields(e,t){e?.join(",")!==t?.join(",")&&this.debouncedPaginationChanged()},descending(){this.debouncedPaginationChanged()}}}},11518:function(e,t,n){"use strict";n.d(t,{IY:function(){return a},R8:function(){return o},T3:function(){return i},r6:function(){return r}});const r=["token-hashing","multi-cluster-management"],i="harvester",o="cluster-agent-scheduling-customization",a="imported-day-2-ops"},2841:function(e,t,n){"use strict";n.d(t,{$E:function(){return u},B9:function(){return P},Bt:function(){return y},Do:function(){return E},G5:function(){return O},Hs:function(){return A},MW:function(){return c},O3:function(){return S},P0:function(){return N},Pl:function(){return g},Qw:function(){return v},Rw:function(){return f},S5:function(){return D},Ub:function(){return _},VT:function(){return L},W8:function(){return C},XH:function(){return $},Z_:function(){return T},_n:function(){return m},bs:function(){return d},c8:function(){return b},d6:function(){return p},eG:function(){return a},ks:function(){return r},lq:function(){return M},nN:function(){return h},ol:function(){return l},pS:function(){return w},qt:function(){return k},rk:function(){return B},tC:function(){return i},uf:function(){return V},vi:function(){return x},xO:function(){return R},yA:function(){return o},yl:function(){return s}});const r="field.cattle.io/name",i="field.cattle.io/description",o="kubernetes.io/hostname",a="management.cattle.io/system-namespace",s="field.cattle.io/projectId",l="authz.management.cattle.io/default-project",c="authz.management.cattle.io/system-project",u="field.cattle.io/containerDefaultResourceLimit",d="field.cattle.io/publicEndpoints",h="field.cattle.io/targetWorkloadIds",p="management.cattle.io/ui-managed",f="field.cattle.io/creatorId",m="field.cattle.io/resourceQuota",g="kubernetes.io/arch",v="management.cattle.io/project-scoped-secret",b="management.cattle.io/project-scoped-secret-copy",y="management.cattle.io/project-scoped-secret-cluster",w={SERVICE_ACCOUNT_UID:"kubernetes.io/service-account.uid",SERVICE_ACCOUNT_NAME:"kubernetes.io/service-account.name",MANAGED_BY:"app.kubernetes.io/managed-by",MANAGED_NAME:"app.kubernetes.io/name",INSTANCE:"app.kubernetes.io/instance"},O={ISSUER:"cert-manager.io/issuer-name"},S={DEFAULT_STORAGE_CLASS:"storageclass.kubernetes.io/is-default-class",BETA_DEFAULT_STORAGE_CLASS:"storageclass.beta.kubernetes.io/is-default-class"},E={NODE_NAME:"management.cattle.io/nodename"},x={CONTROL_PLANE_OLD:"node-role.kubernetes.io/controlplane",CONTROL_PLANE:"node-role.kubernetes.io/control-plane",WORKER:"node-role.kubernetes.io/worker",ETCD:"node-role.kubernetes.io/etcd"},_={CONTROL_PLANE:"rke.cattle.io/control-plane-role",WORKER:"rke.cattle.io/worker-role",ETCD:"rke.cattle.io/etcd-role"},k={DEPLOYMENT_NAME:"cluster.x-k8s.io/deployment-name",CREDENTIAL_DRIVER:"provisioning.cattle.io/driver",CLUSTER_NAMESPACE:"cluster.x-k8s.io/cluster-namespace",FORCE_MACHINE_REMOVE:"provisioning.cattle.io/force-machine-remove",MANAGEMENT_CLUSTER_NAME:"provisioning.cattle.io/management-cluster-name",MACHINE_NAME:"cluster.x-k8s.io/machine",DELETE_MACHINE:"cluster.x-k8s.io/delete-machine",PROVIDER:"provider.cattle.io",HUMAN_NAME:"provisioning.cattle.io/management-cluster-display-name",SECRET_AUTH:"v2prov-secret-authorized-for-cluster",SECRET_WILL_DELETE:"v2prov-authorized-secret-deletes-on-cluster-removal",UI_CUSTOM_PROVIDER:"ui.rancher/provider",AUTOSCALER_CLUSTER_PAUSE:"provisioning.cattle.io/cluster-autoscaler-paused",AUTOSCALER_MACHINE_POOL_MIN_SIZE:"cluster.x-k8s.io/cluster-api-autoscaler-node-group-min-size",AUTOSCALER_MACHINE_POOL_MAX_SIZE:"cluster.x-k8s.io/cluster-api-autoscaler-node-group-max-size"},C={CERTIFIED:"catalog.cattle.io/certified",_RANCHER:"rancher",_PARTNER:"partner",_OTHER:"other",PRIME_ONLY:"catalog.cattle.io/prime-only",EXPERIMENTAL:"catalog.cattle.io/experimental",DEPRECATED:"catalog.cattle.io/deprecated",NAMESPACE:"catalog.cattle.io/namespace",RELEASE_NAME:"catalog.cattle.io/release-name",FEATURED:"catalog.cattle.io/featured",REQUIRES_GVK:"catalog.cattle.io/requires-gvr",PROVIDES:"catalog.cattle.io/provides-gvr",AUTO_INSTALL_GVK:"catalog.cattle.io/auto-install-gvr",AUTO_INSTALL:"catalog.cattle.io/auto-install",HIDDEN:"catalog.cattle.io/hidden",REQUESTS_CPU:"catalog.cattle.io/requests-cpu",REQUESTS_MEMORY:"catalog.cattle.io/requests-memory",SCOPE:"catalog.cattle.io/scope",_MANAGEMENT:"management",_DOWNSTREAM:"downstream",TYPE:"catalog.cattle.io/type",_APP:"app",_CLUSTER_TPL:"cluster-template",_CLUSTER_TOOL:"cluster-tool",COMPONENT:"catalog.cattle.io/ui-component",SOURCE_REPO_TYPE:"catalog.cattle.io/ui-source-repo-type",SOURCE_REPO_NAME:"catalog.cattle.io/ui-source-repo",COLOR:"catalog.cattle.io/ui-color",DISPLAY_NAME:"catalog.cattle.io/display-name",CLUSTER_REPO_NAME:"catalog.cattle.io/cluster-repo-name",SUSE_APP_COLLECTION:"catalog.cattle.io/suse-application-collection",SUPPORTED_OS:"catalog.cattle.io/os",PERMITTED_OS:"catalog.cattle.io/permits-os",DEPLOYED_OS:"catalog.cattle.io/deploys-on-os",MIGRATED:"apps.cattle.io/migrated",MANAGED:"catalog.cattle.io/managed",HIDDEN_REPO:"clusterrepo.cattle.io/hidden"},A={REPO_NAME:"fleet.cattle.io/repo-name",HELM_NAME:"fleet.cattle.io/fleet-helm-name",CLUSTER_DISPLAY_NAME:"management.cattle.io/cluster-display-name",CLUSTER_NAME:"management.cattle.io/cluster-name",BUNDLE_ID:"fleet.cattle.io/bundle-id",BUNDLE_NAME:"fleet.cattle.io/bundle-name",BUNDLE_NAMESPACE:"fleet.cattle.io/bundle-namespace",MANAGED:"fleet.cattle.io/managed",CLUSTER_NAMESPACE:"fleet.cattle.io/cluster-namespace",CLUSTER:"fleet.cattle.io/cluster",CREATED_BY_USER_ID:"fleet.cattle.io/created-by-user-id",OCI_STORAGE_SECRET_DEFAULT:"ui-default-oci-registry",OCI_STORAGE_SECRET_GENERATED:"fleet.cattle.io/bundle-internal-secret"},T={EXTERNAL_IP:"rke.cattle.io/external-ip"},R={CLUSTER_NAME:"rke.cattle.io/cluster-name"},N={ENABLED:"rancher.io/operations-enabled"},P={AUTO_INJECTION:"istio-injection"},I=/cattle\.io\//,M=[I],D=[I],L=[/^kubectl\.kubernetes\.io\/.*$/,/^objectset\.rio\.cattle\.io\/.*$/],B={CLOUD_INIT:"harvesterhci.io/cloud-init-template",CLOUD_PROVIDER_IPAM:"cloudprovider.harvesterhci.io/ipam",CLOUD_PROVIDER_NETWORK:"cloudprovider.harvesterhci.io/network",NETWORK_ROUTE:"network.harvesterhci.io/route",IMAGE_NAME:"harvesterhci.io/image-name",NETWORK_TYPE:"network.harvesterhci.io/type",CLUSTER_NETWORK:"network.harvesterhci.io/clusternetwork",PRIMARY_SERVICE:"cloudprovider.harvesterhci.io/primary-service",CPU_MANAGER:"cpumanager"},$={TEXT:"ui.rancher/badge-text",COLOR:"ui.rancher/badge-color",ICON_TEXT:"ui.rancher/badge-icon-text"},V=["io.cattle.lifecycle.","beta.kubernetes.io","failure-domain.beta.kubernetes.io","node-role.kubernetes.io","kubernetes.io","cattle.io","authz.management.cattle.io","rke.cattle.io","field.cattle.io","workload.user.cattle.io","k3s.io","node.kubernetes.io","egress.rke2.io"]},57699:function(e,t,n){"use strict";n.d(t,{$9:function(){return v},IZ:function(){return u},UD:function(){return m},Xc:function(){return s},YI:function(){return g},ce:function(){return p},kW:function(){return b},ke:function(){return d},l3:function(){return o},nl:function(){return a},o7:function(){return y},qI:function(){return h},r1:function(){return c},tm:function(){return l},y4:function(){return f}});var r=n(2841),i=n(68774);const o={...i.o_,defaultSort:!0,value:"metadata.name",sort:["metadata.name"],search:"metadata.name"},a={name:"steve-id",labelKey:"tableHeaders.id",value:"id",sort:["id"],search:"id"},s={...i.c4,sort:["metadata.state.name","metadata.name"],search:"metadata.state.name"},l={...i.K,value:"metadata.creationTimestamp",sort:"metadata.creationTimestamp",search:!1},c={...i.CU,value:"metadata.namespace",sort:"metadata.namespace",search:"metadata.namespace"},u=(i.qv,{...i.ys,value:"metadata.fields.7",sort:"metadata.fields.7:desc"}),d={...i.g6,value:"metadata.fields.0",sort:"metadata.fields.0:desc"},h={...i.cP,value:"_type",sort:"_type"},p=[{tooltipKey:"resourceTable.groupBy.none",icon:"icon-list-flat",value:"none"},{icon:"icon-folder",value:"metadata.namespace",field:"metadata.namespace",hideColumn:i.CU.name,tooltipKey:"resourceTable.groupBy.namespace",groupLabelKey:"groupByLabel"}],f=(i.OI,r.c8,i.uL,i.zU,i.Cy,{...i.W6}),m={...i.C6,sort:"status.info.nodeCount"},g={...i.EY,sort:`metadata.annotations[${r.tC}]`,search:`metadata.annotations[${r.tC}]`},v={...i.vd},b={...i.KF},y={...i.Go,sort:!1,search:!1}},49845:function(e,t,n){"use strict";n.d(t,{M0:function(){return a},f7:function(){return h},xc:function(){return d}});var r=n(9262),i=n(83297),o=n(52148);const a=`https://ranchermanager.docs.rancher.com/v${i.ji}`,s="Rancher Community",l={suse:"Rancher Prime"};let c=s,u=null;function d(e){c=e,p()}function h(){return c===r.HG.PL_RANCHER_VALUE?u&&l[u]?l[u]:s:c}function p(){const e=h();if("Harvester"===e){const e=(0,o.mS)("~shell/assets/images/pl/harvester.png");document.title="Harvester";const t=document.createElement("link");t.hid="icon",t.rel="icon",t.type="image/x-icon",t.hrefv=e;const n=document.getElementsByTagName("head")[0];n.appendChild(t)}}},90598:function(e,t,n){"use strict";n.d(t,{o_:function(){return r}});n(86565),n(35664),n(68774);const r="compliance"},27278:function(e,t,n){"use strict";n.d(t,{o:function(){return r}});n(35664),n(68774),n(86565),n(57699),n(39669),n(46392),n(2841);const r="explorer"},2665:function(e,t,n){"use strict";n.d(t,{o_:function(){return i},xO:function(){return r}});n(86565),n(35664),n(68774),n(95265),n(10213);const r={REPO:"repo",OCI:"oci",TARBALL:"tarball"},i="fleet"},47034:function(e,t,n){"use strict";n.d(t,{o:function(){return r}});n(68774),n(35664),n(95265),n(86565),n(10213),n(9274),n(57699);const r="manager"},14220:function(e,t,n){"use strict";n.d(t,{$y:function(){return E},AS:function(){return v},CU:function(){return R},Dk:function(){return P},Eo:function(){return _},G5:function(){return d},G8:function(){return r},GH:function(){return s},GQ:function(){return I},HC:function(){return m},Ku:function(){return i},L_:function(){return S},NO:function(){return k},Qp:function(){return o},RX:function(){return C},Rm:function(){return M},SD:function(){return F},Sd:function(){return L},UA:function(){return x},XJ:function(){return N},YQ:function(){return c},Yq:function(){return O},_N:function(){return $},au:function(){return y},dT:function(){return p},dV:function(){return D},dq:function(){return V},fS:function(){return b},g:function(){return l},iJ:function(){return B},nW:function(){return u},o_:function(){return T},qx:function(){return g},wC:function(){return h},wZ:function(){return f},xv:function(){return A},xz:function(){return a},zD:function(){return w}});const r="local",i="editConfig",o=null,a=void 0,s="stateFilter",l="mode",c="create",u="view",d="edit",h="list",p="clone",f="stage",m="import",g="legacy",v="as",b="detail",y="config",w="yaml",O="graph",S="focus",E="preview",x="type",_="repo-type",k="repo",C="chart",A="version",T="name",R="namespace",N="category",P="tag",I="deprecated",M="tools",D="hide-side-nav",L="cloud",B="projectId",$="flatView",V={NAMESPACED:"namespaced",PROJECT_SCOPED:"project-scoped"},F="scope"},71025:function(e,t){"use strict";t.A=["cattle-dashboards","cattle-global-data","cattle-system","gatekeeper-system","ingress-nginx","kube-node-lease","kube-public","kube-system","linkerd","security-scan","tekton-pipelines","compliance-operator-system","istio-system","k3k-system","longhorn-system"]},68774:function(e,t,n){"use strict";n.d(t,{BD:function(){return x},C6:function(){return U},CU:function(){return v},Cy:function(){return z},EY:function(){return G},Go:function(){return q},K:function(){return y},KF:function(){return j},OI:function(){return E},P4:function(){return c},Qg:function(){return D},RP:function(){return l},Si:function(){return O},UA:function(){return k},W6:function(){return V},X:function(){return h},X0:function(){return u},Yf:function(){return f},ZE:function(){return _},ZU:function(){return g},_:function(){return M},aQ:function(){return p},c4:function(){return a},cP:function(){return C},dn:function(){return H},g6:function(){return R},hX:function(){return m},nv:function(){return b},o_:function(){return s},qv:function(){return P},rh:function(){return N},tC:function(){return w},uL:function(){return L},vd:function(){return F},w5:function(){return I},wS:function(){return d},ys:function(){return T},z7:function(){return $},zU:function(){return Q}});var r=n(2841),i=n(35664),o=n(39669);const a={name:"state",labelKey:"tableHeaders.state",sort:["stateSort","nameSort"],value:"stateDisplay",getValue:e=>e.stateDisplay,width:100,default:"unknown",formatter:"BadgeStateFormatter"},s={name:"name",labelKey:"tableHeaders.name",value:"nameDisplay",getValue:e=>e.nameDisplay,sort:["nameSort"],formatter:"LinkDetail",canBeVariable:!0},l={...s,search:["nameDisplay","projectNameDisplay"]},c={name:"logging-output-providers",labelKey:"tableHeaders.loggingOutputProviders",value:"providersDisplay",sort:["providersSortable"],formatter:"List"},u={name:"name",labelKey:"tableHeaders.simpleName",value:"name",sort:["name"],width:200,canBeVariable:!0},d={name:"storage_class_provisioner",labelKey:"tableHeaders.storage_class_provisioner",value:"provisionerListDisplay",sort:["provisioner"]},h={name:"storage_class_default",labelKey:"tableHeaders.default",value:"isDefault",sort:["isDefault"],formatter:"Checked"},p={name:"localOutputRefs",labelKey:"tableHeaders.output",value:"outputs",sort:["outputsSortable"],formatter:"ListLink",formatterOpts:{options:{internal:!0}}},f={name:"providers",labelKey:"tableHeaders.providers",value:"providersDisplay",sort:"providersSortable",formatter:"List"},m={...p,name:"globalOutputRefs",value:"clusterOutputs",sort:["clusterOutputsSortable"],labelKey:"tableHeaders.clusterOutput"},g={name:"name",labelKey:"tableHeaders.nameUnlinked",value:"nameDisplay",sort:["nameSort"],canBeVariable:!0},v={name:"namespace",labelKey:"tableHeaders.namespace",value:"namespace",getValue:e=>e.namespace,sort:"namespace",dashIfEmpty:!0,formatter:"LinkName",formatterOpts:{type:i.CU}},b=(i.NW,{name:"principal",labelKey:"tableHeaders.name",sort:"principal.loginName",value:"principalId",formatter:"Principal"}),y={name:"age",labelKey:"tableHeaders.age",value:"creationTimestamp",getValue:e=>e.creationTimestamp,sort:"creationTimestamp:desc",search:!1,formatter:"LiveDate",width:100,align:"left"},w={name:"description",labelKey:"tableHeaders.description",align:"left",value:"description",sort:["description"],formatter:"Description",width:300},O={name:"NamespaceSnapshotQuota",labelKey:"harvester.tableHeaders.totalSnapshotQuota",value:"snapshotSizeQuota",sort:"snapshotSizeQuota",align:"center",formatter:"Si",formatterOpts:{opts:{increment:1024,addSuffix:!0,suffix:"i"},needParseSi:!1}},S={name:"pod_images",labelKey:"tableHeaders.podImages",value:"imageNames",getValue:e=>e.imageNames,sort:"imageNames",formatter:"PodImages"},E={name:"secret-origin",labelKey:"tableHeaders.secret.origin",tooltip:"tableHeaders.secret.originTooltip",formatter:"SecretOrigin",sort:"project.spec.displayName",search:!1},x={name:"address",labelKey:"tableHeaders.address",value:"address",sort:["address"]},_={name:"type",labelKey:"tableHeaders.type",value:"typeDisplay",getValue:e=>e.typeDisplay,sort:["typeDisplay"],width:100},k={name:"subType",labelKey:"tableHeaders.subType",value:"subTypeDisplay",sort:["subTypeDisplay"],width:120},C={name:"type",labelKey:"tableHeaders.type",value:"eventType",sort:"eventType"},A={name:"lastSeen",labelKey:"tableHeaders.lastSeen",value:"lastSeen",sort:"lastTimestamp:desc",tooltip:"tableHeaders.lastSeenTooltip"},T={name:"firstSeen",labelKey:"tableHeaders.firstSeen",tooltip:"tableHeaders.firstSeenTooltip",value:"firstSeen",sort:"firstSeen:desc"},R={...A,defaultSort:!0},N={name:"reason",labelKey:"tableHeaders.reason",value:"reason",sort:["reason"]},P={name:"object",labelKey:"tableHeaders.object",value:"involvedObject",sort:["involvedObject.kind","involvedObject.name"],canBeVariable:!0,formatter:"InvolvedObjectLink"},I={name:"message",labelKey:"tableHeaders.message",value:"message",sort:["message"]},M={name:"key",labelKey:"tableHeaders.key",value:"key",sort:["key"]},D={name:"value",labelKey:"tableHeaders.value",value:"value",sort:["value"]},L=(o.c.LAPTOP,r.bs,o.c.DESKTOP,{name:"workloadHealthScale",labelKey:"tableHeaders.health",formatter:"WorkloadHealthScale",getValue:()=>{},width:150,skipSelect:!0,delayLoading:!0,search:!1,liveUpdates:!0}),B={name:"scope",value:"clusterName",labelKey:"tableHeaders.scope",dashIfEmpty:!0,align:"left",sort:["scope"],width:100},$={name:"role",value:"roleDisplay",labelKey:"tableHeaders.role"},V={name:"cpu",labelKey:"tableHeaders.cpu",value:"",sort:["status.allocatable.cpuRaw"],search:["status.allocatable.cpuRaw"],formatter:"ClusterCpu"},F={name:"memory",labelKey:"tableHeaders.memory",value:"",sort:["status.allocatable.memoryRaw"],search:["status.allocatable.memoryRaw"],formatter:"ClusterMemory"},j={name:"pods",labelKey:"tableHeaders.pods",value:"",sort:["status.allocatable.pods","status.requested.pods"],search:["status.allocatable.pods","status.requested.pods"],formatter:"PodsUsage",delayLoading:!0},U={name:"machines",labelKey:"tableHeaders.machines",sort:"statusInfo.nodeCount",search:!1,formatter:"ClusterMachineSummary",align:"center",width:100},G={...w,value:`metadata.annotations."${r.tC}"`,sort:[`metadata.annotations."${r.tC}"`],formatter:void 0,minWidth:100,maxWidth:300,lineClamp:3,freeTextWhenShown:!0},H={name:"commit",labelKey:"tableHeaders.commit",value:"status.commit",sort:["status.commit"],search:["status.commit"]},q={name:"autoscaler",labelKey:"tableHeaders.autoscaler",value:"isAutoscalerEnabled",sort:["isAutoscalerEnabled"],formatter:"Autoscaler"},Q={name:"provider",labelKey:"tableHeaders.provider",subLabel:"Distro",value:"statusInfo.machineProvider",sort:["status.info.machineProvider","status.provider","status.driver"],search:["status.info.machineProvider","status.provider","status.driver"],formatter:"ClusterProvider"},z={name:"kubernetesVersion",labelKey:"tableHeaders.version",subLabel:"Architecture",sort:"statusInfo.kubernetesVersion",search:"statusInfo.kubernetesVersion",formatter:"ClusterKubeVersion"}},35664:function(e,t,n){"use strict";n.d(t,{$v:function(){return L},AQ:function(){return ee},B9:function(){return Y},BN:function(){return oe},CU:function(){return h},FV:function(){return ae},GQ:function(){return de},Hr:function(){return c},Hs:function(){return X},I$:function(){return K},JF:function(){return ce},K5:function(){return o},Mc:function(){return Q},NW:function(){return p},Nc:function(){return fe},PV:function(){return v},Rp:function(){return V},SB:function(){return G},Sg:function(){return S},Sm:function(){return m},UI:function(){return ne},UP:function(){return C},UR:function(){return f},W8:function(){return B},XG:function(){return _},YA:function(){return te},YH:function(){return b},YV:function(){return w},Yq:function(){return Z},Z7:function(){return W},ZV:function(){return he},Zd:function(){return U},Zq:function(){return x},bB:function(){return O},cG:function(){return re},cm:function(){return J},d_:function(){return le},eo:function(){return se},fJ:function(){return E},fj:function(){return $},i2:function(){return a},k$:function(){return i},kf:function(){return d},lI:function(){return j},lk:function(){return A},ll:function(){return l},m3:function(){return k},m4:function(){return r},mm:function(){return s},oU:function(){return T},oe:function(){return F},qR:function(){return q},qt:function(){return z},rW:function(){return N},rk:function(){return ie},w3:function(){return pe},wN:function(){return g},wT:function(){return u},x8:function(){return ue},xO:function(){return H},yx:function(){return y}});const r={PREFERENCE:"userpreference",SCHEMA_DEFINITION:"schemaDefinition"},i={APP:"app",AUTH_CONFIG:"authconfig",CLUSTER:"cluster",CLUSTER_TOKEN:"clusterregistrationtoken",CLUSTER_ROLE_TEMPLATE_BINDING:"clusterroletemplatebinding",CLOUD_CREDENTIAL:"cloudcredential",FLEET_WORKSPACES:"fleetworkspace",GLOBAL_ROLE:"globalRole",GLOBAL_ROLE_BINDING:"globalRoleBinding",NODE_POOL:"nodePool",NODE:"node",PRINCIPAL:"principal",PROJECT:"project",PROJECT_ROLE_TEMPLATE_BINDING:"projectroletemplatebinding",SETTING:"setting",SPOOFED:{GROUP_PRINCIPAL:"group.principal"},ROLE_TEMPLATE:"roleTemplate",TOKEN:"token",USER:"user",KONTAINER_DRIVER:"kontainerDriver",NODE_DRIVER:"nodeDriver"},o="configmap",a="count",s="apiextensions.k8s.io.customresourcedefinition",l="event",c="endpoints",u="autoscaling.horizontalpodautoscaler",d="networking.k8s.io.ingress",h="namespace",p="node",f="networking.k8s.io.networkpolicy",m="pod",g="policy.poddisruptionbudget",v="persistentvolume",b="persistentvolumeclaim",y="schema",w="service",O="secret",S="serviceaccount",E="storage.k8s.io.storageclass",x="storage.k8s.io.csidriver",_="k8s.cni.cncf.io.networkattachmentdefinition",k="user",C="group",A={ROLE:"rbac.authorization.k8s.io.role",CLUSTER_ROLE:"rbac.authorization.k8s.io.clusterrole",ROLE_BINDING:"rbac.authorization.k8s.io.rolebinding",CLUSTER_ROLE_BINDING:"rbac.authorization.k8s.io.clusterrolebinding"},T={DEPLOYMENT:"apps.deployment",CRON_JOB:"batch.cronjob",DAEMON_SET:"apps.daemonset",JOB:"batch.job",STATEFUL_SET:"apps.statefulset",REPLICA_SET:"apps.replicaset",REPLICATION_CONTROLLER:"replicationcontroller"},R={DEPLOYMENT:"Deployment",CRON_JOB:"CronJob",DAEMON_SET:"DaemonSet",JOB:"Job",STATEFUL_SET:"StatefulSet",REPLICA_SET:"ReplicaSet",REPLICATION_CONTROLLER:"ReplicationController"},N={[T.DEPLOYMENT]:R.REPLICA_SET,[T.CRON_JOB]:R.CRON_JOB,[T.DAEMON_SET]:R.DAEMON_SET,[T.JOB]:R.JOB,[T.STATEFUL_SET]:R.STATEFUL_SET,[T.REPLICA_SET]:R.REPLICA_SET,[T.REPLICATION_CONTROLLER]:R.REPLICATION_CONTROLLER},{DAEMON_SET:P,CRON_JOB:I,JOB:M,...D}=(R.DEPLOYMENT,T.DEPLOYMENT,R.CRON_JOB,T.CRON_JOB,R.DAEMON_SET,T.DAEMON_SET,R.JOB,T.JOB,R.STATEFUL_SET,T.STATEFUL_SET,R.REPLICA_SET,T.REPLICA_SET,R.REPLICATION_CONTROLLER,T.REPLICATION_CONTROLLER,T.DAEMON_SET,T.REPLICA_SET,T.STATEFUL_SET,T.DEPLOYMENT,T),L={NODE:"metrics.k8s.io.nodemetrics",POD:"metrics.k8s.io.podmetrics"},B={CLUSTER_REPO:"catalog.cattle.io.clusterrepo",OPERATION:"catalog.cattle.io.operation",APP:"catalog.cattle.io.app",REPO:"catalog.cattle.io.repo"},$={PROJECTHELMCHART:"helm.cattle.io.projecthelmchart"},V={ALERTMANAGER:"monitoring.coreos.com.alertmanager",ALERTMANAGERCONFIG:"monitoring.coreos.com.alertmanagerconfig",PODMONITOR:"monitoring.coreos.com.podmonitor",PROMETHEUS:"monitoring.coreos.com.prometheus",PROMETHEUSRULE:"monitoring.coreos.com.prometheusrule",SERVICEMONITOR:"monitoring.coreos.com.servicemonitor",THANOSRULER:"monitoring.coreos.com.thanosruler",SPOOFED:{RECEIVER:"monitoring.coreos.com.receiver",RECEIVER_SPEC:"monitoring.coreos.com.receiver.spec",RECEIVER_EMAIL:"monitoring.coreos.com.receiver.email",RECEIVER_SLACK:"monitoring.coreos.com.receiver.slack",RECEIVER_WEBHOOK:"monitoring.coreos.com.receiver.webhook",RECEIVER_PAGERDUTY:"monitoring.coreos.com.receiver.pagerduty",RECEIVER_OPSGENIE:"monitoring.coreos.com.receiver.opsgenie",RECEIVER_HTTP_CONFIG:"monitoring.coreos.com.receiver.httpconfig",RESPONDER:"monitoring.coreos.com.receiver.responder",ROUTE:"monitoring.coreos.com.route",ROUTE_SPEC:"monitoring.coreos.com.route.spec"}},F={ENGINES:"longhorn.io.engine",ENGINE_IMAGES:"longhorn.io.engineimage",NODES:"longhorn.io.node",REPLICAS:"longhorn.io.replica",SETTINGS:"longhorn.io.setting",VOLUMES:"longhorn.io.volume"},j="driver.longhorn.io",U="LonghornV1",G="LonghornV2",H="rke.cattle.io.etcdsnapshot",q={ETCD_SNAPSHOT:"operation.cattle.io.etcdsnapshotsave",ETCD_SNAPSHOT_RESTORE:"operation.cattle.io.etcdsnapshotrestore",ENCRYPTION_KEY_ROTATE:"operation.cattle.io.encryptionkeyrotation"},Q={AUTH_CONFIG:"management.cattle.io.authconfig",CATALOG_TEMPLATE:"management.cattle.io.catalogtemplate",CLUSTER:"management.cattle.io.cluster",CLUSTER_ROLE_TEMPLATE_BINDING:"management.cattle.io.clusterroletemplatebinding",FEATURE:"management.cattle.io.feature",KONTAINER_DRIVER:"management.cattle.io.kontainerdriver",MULTI_CLUSTER_APP:"management.cattle.io.multiclusterapp",NODE:"management.cattle.io.node",NODE_DRIVER:"management.cattle.io.nodedriver",NODE_POOL:"management.cattle.io.nodepool",NODE_TEMPLATE:"management.cattle.io.nodetemplate",PROJECT:"management.cattle.io.project",PROJECT_ROLE_TEMPLATE_BINDING:"management.cattle.io.projectroletemplatebinding",ROLE_TEMPLATE:"management.cattle.io.roletemplate",SETTING:"management.cattle.io.setting",USER:"management.cattle.io.user",TOKEN:"management.cattle.io.token",GLOBAL_ROLE:"management.cattle.io.globalrole",GLOBAL_ROLE_BINDING:"management.cattle.io.globalrolebinding",PSA:"management.cattle.io.podsecurityadmissionconfigurationtemplate",MANAGED_CHART:"management.cattle.io.managedchart",USER_NOTIFICATION:"management.cattle.io.rancherusernotification",GLOBAL_DNS_PROVIDER:"management.cattle.io.globaldnsprovider",RKE_TEMPLATE:"management.cattle.io.clustertemplate",RKE_TEMPLATE_REVISION:"management.cattle.io.clustertemplaterevision",CLUSTER_PROXY_CONFIG:"management.cattle.io.clusterproxyconfig",OIDC_CLIENT:"management.cattle.io.oidcclient",PROXY_ENDPOINT:"management.cattle.io.proxyEndpoint"},z={SUSE:"suse",FEDERAL:"federal",RGS:"rgs"},K={USER_ACTIVITY:"ext.cattle.io.useractivity",SELFUSER:"ext.cattle.io.selfuser",GROUP_MEMBERSHIP_REFRESH_REQUESTS:"ext.cattle.io.groupmembershiprefreshrequest",PASSWORD_CHANGE_REQUESTS:"ext.cattle.io.passwordchangerequest",KUBECONFIG:"ext.cattle.io.kubeconfig"},W={CAPI_CLUSTER:"cluster.x-k8s.io.cluster",MACHINE_DEPLOYMENT:"cluster.x-k8s.io.machinedeployment",MACHINE_SET:"cluster.x-k8s.io.machineset",MACHINE:"cluster.x-k8s.io.machine",RANCHER_CLUSTER:"provisioning.cattle.io.cluster",MACHINE_CONFIG_GROUP:"rke-machine-config.cattle.io",CAPI_PROVIDER:"turtles-capi.cattle.io.capiprovider"},X={APPLICATION:"fleet.cattle.io.application",BUNDLE:"fleet.cattle.io.bundle",BUNDLE_DEPLOYMENT:"fleet.cattle.io.bundledeployment",CLUSTER:"fleet.cattle.io.cluster",CLUSTER_GROUP:"fleet.cattle.io.clustergroup",DASHBOARD:"fleet.cattle.io.dashboard",GIT_REPO:"fleet.cattle.io.gitrepo",HELM_OP:"fleet.cattle.io.helmop",SUSE_APP_COLLECTION:"suse-application-collection",WORKSPACE:"management.cattle.io.fleetworkspace",TOKEN:"fleet.cattle.io.clusterregistrationtoken",BUNDLE_NAMESPACE_MAPPING:"fleet.cattle.io.bundlenamespacemapping",GIT_REPO_RESTRICTION:"fleet.cattle.io.gitreporestriction",POLICY:"fleet.cattle.io.policy"},Y={VIRTUAL_SERVICE:"networking.istio.io.virtualservice",DESTINATION_RULE:"networking.istio.io.destinationrule",GATEWAY:"networking.istio.io.gateway"},Z={GATEWAY:"gateway.networking.k8s.io.gateway",HTTP_ROUTE:"gateway.networking.k8s.io.httproute"},J={CLUSTER_FLOW:"logging.banzaicloud.io.clusterflow",CLUSTER_OUTPUT:"logging.banzaicloud.io.clusteroutput",FLOW:"logging.banzaicloud.io.flow",OUTPUT:"logging.banzaicloud.io.output",SPOOFED:{FILTERS:"logging.banzaicloud.io.output.filters",FILTER:"logging.banzaicloud.io.output.filter",CONCAT:"logging.banzaicloud.io.output.filters.concat",DEDOT:"logging.banzaicloud.io.output.filters.dedot",DETECTEXCEPTIONS:"logging.banzaicloud.io.output.filters.detectExceptions",GEOIP:"logging.banzaicloud.io.output.filters.geoip",GREP:"logging.banzaicloud.io.output.filters.grep",PARSER:"logging.banzaicloud.io.output.filters.parser",PROMETHEUS:"logging.banzaicloud.io.output.filters.prometheus",RECORD_MODIFIER:"logging.banzaicloud.io.output.filters.record_modifier",RECORD_TRANSFORMER:"logging.banzaicloud.io.output.filters.record_transformer",STDOUT:"logging.banzaicloud.io.output.filters.stdout",SUMOLOGIC:"logging.banzaicloud.io.output.filters.sumologic",TAG_NORMALISER:"logging.banzaicloud.io.output.filters.tag_normaliser",THROTTLE:"logging.banzaicloud.io.output.filters.throttle",RECORD:"logging.banzaicloud.io.output.filters.record",REGEXPSECTION:"logging.banzaicloud.io.output.filters.regexpsection",EXCLUDESECTION:"logging.banzaicloud.io.output.filters.excludesection",ORSECTION:"logging.banzaicloud.io.output.filters.orsection",ANDSECTION:"logging.banzaicloud.io.output.filters.andsection",PARSESECTION:"logging.banzaicloud.io.output.filters.parsesection",METRICSECTION:"logging.banzaicloud.io.output.filters.metricsection",REPLACE:"logging.banzaicloud.io.output.filters.replace",SINGLEPARSESECTION:"logging.banzaicloud.io.output.filters.replace.singleparsesection"}},ee={RESOURCE_SET:"resources.cattle.io.resourceset",BACKUP:"resources.cattle.io.backup",RESTORE:"resources.cattle.io.restore"},te={CLUSTER_SCAN:"compliance.cattle.io.clusterscan",CLUSTER_SCAN_PROFILE:"compliance.cattle.io.clusterscanprofile",BENCHMARK:"compliance.cattle.io.clusterscanbenchmark",REPORT:"compliance.cattle.io.clusterscanreport"},ne={NAV_LINK:"ui.cattle.io.navlink"},re={CLUSTER_MEMBERS:"cluster-members",PROJECT_NAMESPACES:"projects-namespaces",NAMESPACES:"namespaces",PROJECT_SECRETS:"projectsecret",JWT_AUTHENTICATION:"jwt.authentication"},ie={CLUSTER:"harvesterhci.io.management.cluster",DASHBOARD:"harvesterhci.io.dashboard",IMAGE:"harvesterhci.io.virtualmachineimage",VGPU_DEVICE:"devices.harvesterhci.io.vgpudevice",SETTING:"harvesterhci.io.setting",RESOURCE_QUOTA:"harvesterhci.io.resourcequota",HARVESTER_CONFIG:"rke-machine-config.cattle.io.harvesterconfig"},oe="harvester",ae={HOSTNAME:"Hostname",INTERNAL_IP:"InternalIP",EXTERNAL_IP:"ExternalIP"},se="fleet-default",le="local",ce="clusterrepo-appco-auth-",ue="0001-01-01T00:00:00Z",de="Deprecated",he="Experimental",pe="kube-system/cluster-autoscaler-status",fe={K8S_CLUSTERS:"k8sClusters"}},91251:function(e,t,n){"use strict";n.d(t,{Z1:function(){return s}});var r=n(2722),i=n.n(r);n(83297);const o="rancher-manager",a={UI:"uiVersion",EXTENSIONS_API_MISSING:"extensionsApiVersionMissing",EXTENSIONS_API:"extensionsApiVersion",KUBE:"kubeVersion",HOST:"host",PRIME_ONLY:"primeOnly"};a.UI,a.EXTENSIONS_API_MISSING,a.EXTENSIONS_API,a.KUBE,a.HOST,a.PRIME_ONLY;function s(e){let t=i().coerce(e)?.version;const n=t?.split(".");return e.includes("-")&&3===n?.length&&(t=`${n[0]}.${n[1]}.999`),t}},83297:function(e,t,n){"use strict";n.d(t,{f$:function(){return i},ji:function(){return a},nv:function(){return o}});let r={Version:"",RancherPrime:"false",GitCommit:""};function i(){return"true"===r.RancherPrime?.toLowerCase()}function o(){return r}const a="2.15"},8135:function(e,t,n){"use strict";n.d(t,{Fm:function(){return s},Mz:function(){return l}});var r=n(68851),i=n(74302),o=n(4364);let a=1;const s="_beforeSaveHooks",l="_afterSaveHooks";t.Ay={methods:{registerHook(e,t,n,r=99,i){this._registerHook(e,t,n,r,i)},registerBeforeHook(e,t,n=99,r){this.registerHook(s,e,t,n,r)},unregisterHook(e,t){this[e]=(this[e]||[]).filter(e=>e.name!==t)},unregisterBeforeSaveHook(e){this.unregisterHook(s,e)},registerAfterHook(e,t,n=99,r){this.registerHook(l,e,t,n,r)},async applyHooks(e,...t){if(!e)throw new Error("Must specify key");const n=(0,i.Ul)(this[e]||[],["priority","name"]),r={};for(const i of n)o.debug("Applying hook",i.name),r[i.name]=await i.fn.apply(i.fnContext||this,t);return r},_registerHook(e,t,n,i,o){if(!e)throw new Error("Must specify key");n||(n=`hook_${a}`,a++),i||(i=99);let s=this[e];s||(s=[],this[e]=s);let l=(0,r.jq)(s,"name",n);l?(l.priority=i,l.fn=t,l.fnContext=o):(l={name:n,priority:i,fn:t,fnContext:o},s.push(l))}}}},55277:function(e,t){"use strict";t.A={props:{pref:{type:String,default:null},prefKey:{type:String,default:null}},computed:{shown(){let e=!0;if(this.pref){const t=this.$store.getters["prefs/get"](this.pref);e=this.prefKey?!t[this.prefKey]:!t}return e}},methods:{async hide(){if(this.pref){let e=this.$store.getters["prefs/get"](this.pref);this.prefKey&&((!0===e||!1===e||e.length>0)&&(e={}),e[this.prefKey]=!0),await this.$store.dispatch("prefs/set",{key:this.pref,value:e})}}}}},65375:function(e,t,n){"use strict";var r=n(14220),i=n(41476),o=n(99726),a=n(8135),s=n(68851),l=n(35664),c=n(79401),u=n(4364);t.A={name:"CreateEditView",mixins:[a.Ay],emits:["done"],data(){return{errors:[]}},computed:{isCreate(){return this.mode===r.YQ},isEdit(){return this.mode===r.G5},isView(){return this.mode===r.nW},schema(){const e=this.storeOverride||this.$store.getters["currentStore"](this.value.type);return this.$store.getters[`${e}/schemaFor`](this.value.type)},isNamespaced(){return this.schema?.attributes?.namespaced||!1},labels:{get(){return this.value?.labels},set(e){this.value.setLabels(e)}},annotations:{get(){return this.value?.annotations},set(e){this.value.setAnnotations(e)}},doneRoute(){if(this.value?.doneRoute)return this.value.doneRoute;let e=this.$route.name;return e?.endsWith("-id")?e=e.replace(/(-namespace)?-id$/,""):e?.endsWith("-create")&&(e=e.replace(/-create$/,"")),e},doneParams(){if(this.value?.doneParams)return this.value.doneParams;const e={...this.$route.params};return delete e.namespace,delete e.id,e}},methods:{done(){if(!this.doneEvent)return this.doneLocationOverride?this.$router.replace(this.doneLocationOverride):void(this.doneRoute&&this.$router.replace({name:this.doneRoute,params:this.doneParams||{resource:this.value.type}}));this.$emit("done")},async conflict(){return await(0,c.Rq)(this.initialValue,this.value,this.liveValue,{dispatch:this.$store.dispatch,getters:this.$store.getters},this.storeOverride||this.$store.getters["currentStore"](this.value.type))},async save(e,t,n=0){this.errors&&(0,s.IU)(this.errors);try{if(await this.applyHooks(a.Fm,this.value),this.value?.metadata?.labels&&0===Object.keys(this.value.metadata.labels||{}).length&&delete this.value.metadata.labels,this.value?.metadata?.annotations&&0===Object.keys(this.value.metadata.annotations||{}).length&&delete this.value.metadata.annotations,this.isCreate){const e=this.value?.metadata?.namespace;e&&e!==l.eo&&this.value.$dispatch("prefs/set",{key:i.Ri,value:e},{root:!0})}await this.actuallySave(t),this.$store.getters["type-map/isSpoofed"](this.value.type)&&await this.$store.dispatch("cluster/findAll",{type:this.value.type,opt:{force:!0}},{root:!0}),await this.applyHooks(a.Mz,this.value),this.isCreate&&this.value.notifyGeneratedName?.(),e&&e(!0),this.done()}catch(r){const i=409===r.status||409===r._status;if(i&&0===n&&this.isEdit){const r=await this.conflict();if(!1===r)return this.save(e,t,n+1);this.errors=r}else this.errors=(0,o.rz)(r);(0,o.D7)(r)||u.error("CreateEditView mixin failed to save: ",r),e&&e(!1)}},async actuallySave(e){if(this.isCreate){e=e||this.schema.linkFor("collection");const t=await this.value.save({url:e});t&&Object.assign(this.value,t)}else await this.value.save()},setErrors(e){this.errors=e}}}},91825:function(e,t,n){"use strict";var r=n(14220),i=n(9274),o=n(65375);t.A=(0,i.defineComponent)({...o.A,props:{mode:{type:String,default:r.G5},realMode:{type:String,default:r.G5},as:{type:String,default:r.zD},value:{type:Object,required:!0},initialValue:{type:Object,default:null},liveValue:{type:Object,default:null},doneEvent:{type:Boolean,default:!1},useTabbedHash:{type:Boolean,default:void 0},defaultTab:{type:String,default:void 0}}})},77651:function(e,t,n){"use strict";var r=n(76978),i=n(71274);t.A={data(){return{fvFormRuleSets:[],fvReportedValidationPaths:[]}},methods:{fvGetPathRules(e){return this.fvRulesets.find(t=>t.path===e)?.rules||[]},fvGetAndReportPathRules(e){const t=this.fvGetPathRules(e);return t.length>0&&!this.fvReportedValidationPaths.includes(e)&&(this.fvReportedValidationPaths=[...this.fvReportedValidationPaths,e]),t},fvGetPathValues(e){const t=this.fvRulesets.find(t=>t.path===e);return t?(0,r.Ib)(t?.rootObject||this.value,t?.path):[]},fvGetValues(e,t,n){return n.length>1&&"object"===typeof e&&!Array.isArray(e)&&null!==e?{...e,idx:t}:e},fvGetPathErrors(e=[]){const t=e.reduce((e,t)=>{const n=[],r=this.fvGetPathRules(t),i=this.fvGetPathValues(t).map(this.fvGetValues);return r.forEach(e=>{i.forEach(t=>{n.push(e(t))})}),[...e,...n].filter(Boolean)},[]);return t}},computed:{fvExtraRules(){return{}},fvRulesets(){const e=()=>{};return[...this.fvFormRuleSets.map(t=>{const n={...(0,i.A)(this.$store.getters["i18n/t"],{key:t?.translationKey?this.$store.getters["i18n/t"](t.translationKey):"Value"}),...this.fvExtraRules};return{...t,rules:t.rules.map(t=>n[t]||e),formValidationRule:!0}}),...(this?.value?.modelValidationRules||[]).map(e=>({...e,formValidationRule:!1}))]},fvUnreportedValidationErrors(){const e=this.fvRulesets.filter(e=>!!e.formValidationRule&&!this.fvReportedValidationPaths.includes(e.path)).map(e=>e.path),t=this.fvGetPathErrors(e),n=this.value.customValidationErrors?this.value.customValidationErrors(this.value,this.fvReportedValidationPaths):[];return[...t,...n,...this.errors||[]]},fvValidationErrors(){const e=this.fvRulesets.filter(e=>!!e.formValidationRule).map(e=>e.path),t=this.fvGetPathErrors(e),n=this.value.customValidationErrors?this.value.customValidationErrors(this.value):[];return[...t,...n]},fvFormIsValid(){return 0===this.fvValidationErrors.length}}}},23667:function(e,t,n){"use strict";n.d(t,{A:function(){return S}});var r=n(65359),i=n(35664),o=n(9262),a=n(18110),s=n(90703),l=n(81565),c={data(){return{forceUpdateLiveAndDelayed:0}},computed:{...(0,r.L8)(["currentProduct","currentCluster","namespaceFilters"]),namespaceFilterRequired(){return this.__namespaceRequired&&!this.__validFilter},namespaceFilter(){return this.__namespaceRequired?this.__validFilter:""},__validFilter(){const e=this.namespaceFilters.length&&this.namespaceFilters.every(e=>e.startsWith(a.EF)||e.startsWith(a.xs));return e?this.namespaceFilters:null},__namespaceRequired(){return!!l.A.isEnabled(this.$store.getters)&&this.__areResourcesNamespaced},__areResourcesNamespaced(){return"cluster"===this.currentProduct.inStore&&(this.loadResources||[]).every(e=>{const t=this.$store.getters["cluster/schemaFor"](e);return t?.attributes?.namespaced})}},watch:{async namespaceFilter(e){e&&(this.$options.name!==s.v&&this.$fetch&&await this.$fetch(),this.forceUpdateLiveAndDelayed=(new Date).getTime())}}},u=n(41476),d=n(15092),h=n(12784),p=n.n(h),f=n(50025),m=n(82637),g=n(88343),v=n(4364),b={props:{namespaced:{type:Boolean,default:null},context:{type:String,default:null}},data(){return{forceUpdateLiveAndDelayed:0,pPagination:null,debouncedSetPagination:p()(this.setPagination,50),requestFilters:{filters:[],projectsOrNamespaces:[]},paginationFromList:null,isPaginationManualRefreshEnabled:d.A.isListManualRefreshEnabled({rootGetters:this.$store.getters})}},methods:{setPagination(e){e&&(this.pPagination=e)},paginationChanged(e){if(!e)return;this.paginationFromList=e;const{page:t,perPage:n,filter:r,sort:i,descending:o,viewFilters:a}=e,s=r.searchQuery?r.searchFields.map(e=>new f.Js({field:e,value:r.searchQuery,exact:!1})):[],l=new f.gR({page:t,pageSize:n,sort:i?.map(e=>({field:e,asc:!o})),projectsOrNamespaces:this.requestFilters.projectsOrNamespaces,filters:[new f.eY({fields:s}),...this.requestFilters.filters,...a||[]]});this.debouncedSetPagination(l)},paginationEqual(e,t){return!!e.page&&!!d.A.paginationEqual(e,t)},calcCanPaginate(){if(!this.resource)return!1;const e={id:this.resource.id||this.resource,context:this.context};return this.$store.getters[`${this.overrideInStore||this.inStore}/paginationEnabled`]?.(e)}},computed:{...(0,r.L8)(["currentProduct","isAllNamespaces"]),namespaceFilters(){return this.$store.getters["namespaceFilters"]},paginationNsFilterRequired(){return this.canPaginate&&!this.__validPaginationNsFilter},__validPaginationNsFilter(){return d.A.validateNsProjectFilters(this.namespaceFilters)},isResourceList(){return!!this.hasListComponent},pagination(){if(!this.isResourceList)return this.canPaginate?this.pPagination:""},paginationScope(){const e={page:1,sort:[],filters:[...this.requestFilters.filters],projectsOrNamespaces:this.requestFilters.projectsOrNamespaces};return this.apiFilter?this.apiFilter(e):e},canPaginate(){if(!this.isResourceList)return this.calcCanPaginate()},paginationResult(){if(!this.isResourceList&&this.canPaginate)return this.havePaginated?.result},havePaginated(){if(!this.isResourceList)return this.$store.getters[`${this.overrideInStore||this.inStore}/havePage`](this.resource)},productHidesSystemNamespaces(){return this.currentProduct?.hideSystemResources},showDynamicRancherNamespaces(){return this.$store.getters["prefs/get"](u.Pz)},isNamespaced(){return null!==this.namespaced?!!this.namespaced:this.schema?.attributes?.namespaced}},watch:{rows(e){this.canPaginate&&this.pagination&&!this.isResourceList&&this.pagination.page>1&&0===e.length&&this.setPagination({...this.pagination,page:this.pagination.page-1})},namespaceFilters:{immediate:!0,async handler(e,t){if(!this.canPaginate||!this.isNamespaced||!this.currentProduct?.showNamespaceFilter)return;if(this.isResourceList)return;const n=!e||0===e.length||e[0]===a.tj,r=!t||0===t.length||t[0]===a.tj;if(n&&r){const e=this.isAllNamespaces&&(!this.showDynamicRancherNamespaces||this.productHidesSystemNamespaces);if(!e)return}const{projectsOrNamespaces:o,filters:s}=m.A.createParamsFromNsFilter({allNamespaces:this.$store.getters[`${this.currentProduct?.inStore}/all`](i.CU),selection:e,isAllNamespaces:this.isAllNamespaces,isLocalCluster:this.$store.getters["currentCluster"]?.isLocal,showReservedRancherNamespaces:this.showDynamicRancherNamespaces,productHidesSystemNamespaces:this.productHidesSystemNamespaces});this.requestFilters.filters=s,this.requestFilters.projectsOrNamespaces=o}},"requestFilters.filters"(){this.paginationChanged(this.paginationFromList)},"requestFilters.projectsOrNamespaces"(){this.paginationChanged(this.paginationFromList)},async pagination(e,t){this.canPaginate&&(this.isResourceList||e&&this.$options.name!==s.v&&this.$fetch&&!this.paginationEqual(e,t)&&(await this.$fetch(!1),this.forceUpdateLiveAndDelayed=(new Date).getTime()))},async paginationResult(e,t){this.fetchPageSecondaryResources&&e&&e.timestamp!==t?.timestamp&&await this.fetchPageSecondaryResources({canPaginate:this.canPaginate,force:!1,page:this.rows,pagResult:this.paginationResult})}},async beforeUnmount(){if(this.havePaginated){const t=this.overrideInStore||this.inStore,n={type:this.resource,mode:g.g.RESOURCE_CHANGES},r=this.resource===i.Mc.CLUSTER&&this.currentCluster?this.currentCluster:null;if(await this.$store.dispatch(`${t}/forgetType`,{type:this.resource,compareWatches:e=>e.type===n.type&&e.mode===n.mode,unwatch:!0,forget:!r}),r)try{const e=await this.$store.dispatch(`${t}/clone`,{resource:r});await this.$store.dispatch(`${t}/load`,{data:e,existing:r,invalidatePageCache:!0}),await this.$store.dispatch(`${t}/watch`,{type:this.resource,id:r.id})}catch(e){v.error("Error occurred whilst trying to retain the management cluster in cache and correctly watched",e)}}}},y=n(10257),w=n(4364);const O=4;var S={mixins:[c,b],inheritAttrs:!1,data(){const e=this.$store.getters["management/byId"](i.Mc.SETTING,o.HG.UI_PERFORMANCE);let t={};if(e&&e.value)try{t=JSON.parse(e.value)}catch(s){w.warn("ui-performance setting contains invalid data")}else t=o.$8;const n={...this.$route.params},r=this.schema?.id||n.resource,a=this.$store.getters["currentStore"](r);return{inStore:a,perfConfig:t,init:!1,multipleResources:[],loadResources:[r],hasManualRefresh:!1,watch:!0,isTooManyItemsToAutoUpdate:!1,force:!1,incremental:!1,fetchedResourceType:[],paginating:null,isFirstLoad:!0}},beforeUnmount(){this.init&&(this.$store.dispatch("resource-fetch/clearData"),this.fetchedResourceType.forEach(e=>{this.$store.dispatch(`${e.currStore}/incrementLoadCounter`,e.type)}))},props:{localFilter:{type:Function,default:null},apiFilter:{type:Function,default:null},includeAssociatedData:{type:Boolean,default:!1}},computed:{...(0,r.L8)({refreshFlag:"resource-fetch/refreshFlag"}),rows(){const e=this.fetchedResourceType.find(e=>e.type===this.resource);if(e){const t=this.$store.getters[`${e.currStore}/all`](this.resource);if(!this.canPaginate)return this.localFilter?this.localFilter(t):t;if(this.havePaginated)return t}return[]},loading(){return this.canPaginate?null===this.paginating||this.paginating:!this.rows.length&&this.$fetchState.pending}},watch:{async refreshFlag(e){this.init&&e&&(await this.$fetch(),this.clearSelection&&this.clearSelection(),this.canPaginate&&this.fetchPageSecondaryResources&&this.fetchPageSecondaryResources({canPaginate:this.canPaginate,force:!0,page:this.rows,pagResult:this.paginationResult}))},loading(e,t){t&&!e&&(this.isFirstLoad=!1)}},methods:{$initializeFetchData(e,t=[],n){if(!this.init){const r=n||this.$store.getters["currentStore"]();this.__gatherResourceFetchData(e,t,r),this.watch||(this.force=!0),this.isTooManyItemsToAutoUpdate&&(this.hasManualRefresh=!0)}},$fetchType(e,t=[],n){const r=n||this.$store.getters["currentStore"]();this.$initializeFetchData(e,t,r),this.fetchedResourceType.find(t=>t.type===e)||this.fetchedResourceType.push({type:e,currStore:r});const i=this.$store.getters[`${r}/schemaFor`](e);if(this.canPaginate){if(!this.pagination)return;const t={hasManualRefresh:this.hasManualRefresh,pagination:{...this.pagination},force:null!==this.paginating,includeAssociatedData:this.includeAssociatedData};this.apiFilter&&(t.paginating=this.apiFilter(t.pagination)),this["paginating"]=!0;const n=this;return t.requesterId=`list-${this.$?.uid}`,this.$store.dispatch(`${r}/findPage`,{type:e,opt:t}).finally(()=>n["paginating"]=!1)}let o=null;if(this.incremental){const t=this.__getCountForResources([e],this.namespaceFilter,r);o={quickLoadCount:100,resourcesPerIncrement:Math.ceil(t/O),increments:O,pageByNumber:this.$store.getters[`${this.inStore}/paginationEnabled`]?.()}}const a={incremental:o,watch:this.watch,force:this.force,hasManualRefresh:this.hasManualRefresh};return i?.attributes?.namespaced&&(a.namespaced=this.namespaceFilter),this.$store.dispatch(`${r}/findAll`,{type:e,opt:a})},__getCountForResources(e,t,n){const r=n||this.$store.getters["currentStore"]();return e.reduce((e,n)=>e+this.__getCountForResource(n,t,r),0)},__getCountForResource(e,t,n){const r=n||this.$store.getters["currentStore"](),o=this.$store.getters[`${r}/all`](i.i2)[0]?.counts[`${e}`],a=t&&o?.namespaces?o?.namespaces[t]?.count:o?.summary?.count;return a||0},__gatherResourceFetchData(e,t,n){this.init=!0;const r=y.A.manualRefreshUtils.isEnabled(this.calcCanPaginate(),this.perfConfig),i=parseInt(this.perfConfig?.manualRefresh?.threshold||"0",10),o=y.A.incrementalLoadingUtils.isEnabled(this.calcCanPaginate(),this.perfConfig),a=parseInt(this.perfConfig?.incrementalLoading?.threshold||"0",10);this.multipleResources=t;let s=0,l=!0,c=!1,u=!1;const d=this.multipleResources.length?this.multipleResources:[e];s=this.__getCountForResources(d,this.namespaceFilter,n),r&&s>=i?(l=!1,c=!0):this.canPaginate&&this.isPaginationManualRefreshEnabled&&(c=!0),u=o&&a>0&&s>=a,this.$store.dispatch("resource-fetch/updateIsTooManyItems",c),this.watch=l,this.isTooManyItemsToAutoUpdate=c,this.incremental=u}}}},89626:function(e,t){"use strict";t.A={methods:{mappedKeys(e,t){const n={...e};return n[9]=e=>{t.open&&e.preventDefault()},n[27]=e=>(e.preventDefault(),e.stopPropagation(),this.isOpen=!1,t.open=!1,t.search="",this.$refs.select.focus(),!1),n[13]=(e,n)=>{if(!t.open)return void(t.open=!0);if(-1===t.typeAheadPointer)return;let r=t.filteredOptions[t.typeAheadPointer];r&&"function"===typeof t.selectable&&!t.selectable(r)||(t.$emit("option:selecting",r),t.isOptionSelected(r)||(t.taggable&&!t.optionExists(r)&&t.$emit("option:created",r),t.multiple&&(r=t.selectedValue.concat(r)),t.updateValue(r),t.$emit("option:selected",r),t.closeOnSelect&&(t.open=!1,t.typeAheadPointer=-1),t.clearSearchOnSelect&&(t.search="")))},n[38]=e=>(e.preventDefault(),t.open||(t.open=!0),t.typeAheadUp()),n[40]=e=>(e.preventDefault(),t.open||(t.open=!0),t.typeAheadDown()),n}}}},98962:function(e,t,n){"use strict";n.r(t);var r=n(22513);describe("class: ComplianceProfile",()=>{describe("getter: numberTestsSkipped",()=>{it("should return 0 if skipTests is not present in spec",()=>{const e=new r["default"]({spec:{}});expect(e.numberTestsSkipped).toBe(0)}),it("should return 0 if skipTests is null",()=>{const e=new r["default"]({spec:{skipTests:null}});expect(e.numberTestsSkipped).toBe(0)}),it("should return 0 if skipTests is an empty array",()=>{const e=new r["default"]({spec:{skipTests:[]}});expect(e.numberTestsSkipped).toBe(0)}),it("should return the correct number of skipped tests",()=>{const e=["test-1","test-2","test-3"],t=new r["default"]({spec:{skipTests:e}});expect(t.numberTestsSkipped).toBe(e.length)})})})},68115:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(39975),i=n(35664);class o extends r.A{get resourceType(){return`${this.spec.group}.${this.spec.names.singular}`}get resourceCount(){return this.$getters.all(i.i2)?.[0].counts[this.resourceType]?.summary.count}get resourceLink(){const e={...this.listLocation};return e.params.resource=this.resourceType,{text:`${this.resourceType}`+(this.resourceCount?` (${this.resourceCount})`:""),to:e}}}},426:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return s}});var r=n(14220),i=n(89865);const o={KIND_SEPARATOR:"://",GROUP_SEPARATOR:":",BASE_SEPARATOR:"*",ID_SEPARATOR:":",KIND_ALL:"containers",SYSTEM_CATEGORIES:["Rancher services"],CATALOG_DEFAULT_GROUP:"library"};function a(e){const t={kind:null,group:null,base:null,id:null,name:null,version:null};if(!e)return t;const n=e.indexOf(o.KIND_SEPARATOR);if(n>=0){t.kind=e.substr(0,n);let r=e.substr(n+o.KIND_SEPARATOR.length+1);t.id=e,r=r.split("&"),r.forEach(e=>{const[n,r]=e.split("=");t[n]=r})}let r=t.catalog;return r=r.includes("/")?r.replace("/",":"):`cattle-global-data:${r}`,t.templateId=`${r}-${t.template}`,t.templateVersionId=`${r}-${t.template}-${t.version}`,t}class s extends i.A{get appEditUrl(){return this.detailLocation}goToEdit(e={}){const t=this.appEditUrl;t.query={...t.query,[r.g]:r.G5,...e},this.currentRouter().push(t)}get currentVersion(){return a(this.externalId).version}}},54686:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(39975);class i extends r.A{get revisionNumber(){return this.revision}}},89395:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(70775);class i extends r["default"]{async rollBack(e,t,n){const r=[{op:"replace",path:"/spec/template",value:{metadata:n.data.spec.template.metadata,spec:n.data.spec.template.spec}},{op:"replace",path:"/metadata/generation",value:n.revision}];await this.rollBackWorkload(e,t,"daemonsets",r)}}},41212:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return s}});var r=n(35664),i=n(70775);const o=["kubectl.kubernetes.io/last-applied-configuration","deployment.kubernetes.io/revision","deployment.kubernetes.io/revision-history","deployment.kubernetes.io/desired-replicas","deployment.kubernetes.io/max-replicas","deprecated.deployment.rollback.to"],a=/Replicas: (\d+)/;class s extends i["default"]{get replicaSetId(){const e=this.metadata?.relationships||[],t=e.filter(e=>"owner"===e.rel&&e.toType===r.oU.REPLICA_SET),n=t.find(e=>{const t=e.message?.match(a),n=t?parseInt(t[1],10):0;return n>0}),i=n||t[0];return i?.toId?.replace(`${this.namespace}/`,"")}async rollBack(e,t,n){const r=[{op:"replace",path:"/spec/template",value:{metadata:{creationTimestamp:null,labels:Object.keys(n.spec.template.metadata?.labels||{}).reduce((e,t)=>("pod-template-hash"!==t&&(e[t]=n.spec.template.metadata.labels[t]),e),{}),annotations:Object.keys(n.spec.template.metadata?.annotations||{}).reduce((e,t)=>(o.includes(t)||(e[t]=n.spec.template.metadata.annotations[t]),e),{})},spec:n.spec.template.spec}},{op:"replace",path:"/metadata/annotations",value:{"deployment.kubernetes.io/revision":n.metadata.annotations["deployment.kubernetes.io/revision"]}}];await this.rollBackWorkload(e,t,"deployments",r)}}},77763:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return l}});var r=n(70775),i=n(35664),o=n(38823);const a=[i.YV,i.Yq.HTTP_ROUTE,i.Yq.GATEWAY],s=new WeakMap;class l extends r["default"]{get revisionNumber(){if(this.ownedByWorkload)return this.metadata.annotations["deployment.kubernetes.io/revision"]}get readyReplicas(){return this.status?.readyReplicas||0}get ready(){return`${this.readyReplicas}/${this.desired}`}get podsInStore(){if(!this.spec?.selector||!this.$getters["typeRegistered"](i.Sm))return;const e=this.$getters["matching"](i.Sm,(0,o._R)(this.spec.selector),this.metadata.namespace);return e.length>=(this.status?.replicas||0)?e:void 0}fetchGlancePods(){const e=this.metadata?.resourceVersion,t=s.get(this);if(t&&t.resourceVersion===e)return t.pods;const n=this.matchingPods();return s.set(this,{resourceVersion:e,pods:n}),n.catch(()=>s.delete(this)),n}get glanceGatewayEndpoints(){const e=a.every(e=>this.$rootGetters["cluster/typeRegistered"](e));return e?this.gatewayEndpoints:[]}get hasGatewayApi(){return a.every(e=>this.$rootGetters["cluster/schemaFor"](e))}async fetchGatewayEndpointResources(){this.hasGatewayApi&&await Promise.all([this.$dispatch("cluster/findAll",{type:i.YV,opt:{namespaced:this.metadata.namespace}},{root:!0}),this.$dispatch("cluster/findAll",{type:i.Yq.HTTP_ROUTE},{root:!0}),this.$dispatch("cluster/findAll",{type:i.Yq.GATEWAY},{root:!0})])}get glance(){const e=[...this._glance],t=this.readyReplicas,n=this.desired,r=this.publicEndpoints.length>0,i=[{name:"ready",label:this.t("component.resource.detail.glance.ready"),formatter:"ReadyIndicator",formatterOpts:{ready:t,total:n,status:0===n?"none":void 0},content:this.ready},{name:"podRestarts",label:this.t("component.resource.detail.glance.podRestarts"),formatter:"WorkloadPodRestarts",formatterOpts:{row:this}},{name:"endpoints",label:this.t("component.resource.detail.glance.endpoints"),formatter:r||this.hasGatewayApi?"WorkloadGlanceEndpoints":void 0,formatterOpts:{row:this,col:{}},content:r?this.endpoint:"—"}],o=e.findIndex(e=>"age"===e.name);return e.splice(o>-1?o:e.length,0,...i),e}}},86791:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(70775),i=n(35664);class o extends r["default"]{async rollBack(e,t,n){const r=[{op:"replace",path:"/spec/template",value:{metadata:n.data.spec.template.metadata,spec:n.data.spec.template.spec}},{op:"replace",path:"/metadata/generation",value:n.revision}];await this.rollBackWorkload(e,t,"statefulsets",r)}get pods(){return this.podMatchExpression?super.pods.filter(e=>{if(e.metadata?.ownerReferences?.length){const t=e.metadata?.ownerReferences?.find(e=>e.kind===i.rW[i.oU.STATEFUL_SET]);if(t)return`${e.metadata.namespace}/${t.name}`===this.id}return!1}):[]}}},8488:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(68851),i=n(39975);class o extends i.A{get _availableActions(){const e=super._availableActions;return(0,r.PT)(e,0,{action:"enable",label:this.t("action.enable"),icon:"icon icon-play",enabled:(this.canEdit||this.canEditYaml)&&!this.spec.enabled,bulkable:!0,weight:2}),(0,r.PT)(e,0,{action:"disable",label:this.t("action.disable"),icon:"icon icon-pause",enabled:(this.canEdit||this.canEditYaml)&&this.spec.enabled,bulkable:!0,weight:1}),e}enable(){this.enableOrDisable("enable")}disable(){this.enableOrDisable("disable")}async enableOrDisable(e){const t=await this.$dispatch("rancher/clone",{resource:this},{root:!0});t.spec.enabled="enable"===e,await t.save().catch(t=>{this.$dispatch("growl/fromError",{title:this.t("auditPolicy.error.enableOrDisable",{flag:e,id:this.id}),err:t,timeout:5e3},{root:!0})})}}},20763:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(39975);class i extends r.A{get customValidationRules(){return[{nullable:!1,path:"metadata.name",required:!0,translationKey:"generic.name",type:"dnsLabel"}]}get details(){const{spec:e={},status:t}=this,n=[{label:e?.scaleTargetRef?.kind??this.t("hpa.tabs.workload"),content:e?.scaleTargetRef?.name},{label:this.t("hpa.workloadTab.min"),content:e?.minReplicas},{label:this.t("hpa.workloadTab.max"),content:e?.maxReplicas},{label:this.t("hpa.workloadTab.current"),content:t?.currentReplicas??0},{label:this.t("hpa.workloadTab.last"),content:t?.lastScaleTime,formatter:"LiveDate"}];return n}}},77684:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return a}});var r=n(92043),i=n(39975),o=n(35664);class a extends i.A{get cluster(){if(!this.spec.clusterName)return null;const e=`${this.metadata.namespace}/${this.spec.clusterName}`;return this.$rootGetters["management/byId"](o.Z7.RANCHER_CLUSTER,e)}get clusterName(){return this.cluster?.nameDisplay||this.spec.clusterName}get groupByLabel(){return this.$rootGetters["i18n/t"]("resourceTable.groupLabel.cluster",{name:(0,r.ZD)(this.clusterName)})}}},43020:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return s}});var r=n(68851),i=n(76978),o=n(35664),a=n(70775);class s extends a["default"]{get state(){return this.spec?.suspend?"suspended":super.state}get _availableActions(){const e=super._availableActions,t=this.spec?.suspend||!1,n=this.$getters["schemaFor"](o.oU.JOB),i=!!n?.collectionMethods.find(e=>["blocked-post","post"].includes(e.toLowerCase()));return(0,r.PT)(e,0,{action:"runNow",label:this.t("action.runNow"),icon:"icon icon-spinner",enabled:i,bulkable:!0}),(0,r.PT)(e,1,{action:"suspend",label:this.t("action.suspend"),icon:"icon icon-pause",enabled:!t&&this.canUpdate,bulkable:!0}),(0,r.PT)(e,2,{action:"resume",label:this.t("action.resume"),icon:"icon icon-play",enabled:t&&this.canUpdate,bulkable:!0}),e}async runNow(){const e={apiVersion:this.apiVersion,controller:!0,kind:this.kind,name:this.metadata.name,uid:this.metadata.uid},t=await this.$dispatch("create",{type:o.oU.JOB,kind:o.rW[o.oU.JOB],...(0,i.o8)(this.spec.jobTemplate)});t.metadata=t.metadata||{},t.metadata.namespace=this.metadata.namespace,t.metadata.name=`${this.metadata.name}-${Date.now()}`,t.metadata.ownerReferences=[e],await t.save(),t.goToDetail()}suspend(){this.spec.suspend=!0,this.save()}resume(){this.spec.suspend=!1,this.save()}}},66184:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(70775),i=n(51481);class o extends r["default"]{get duration(){const e=this.$getters["schemaFor"](this.type),t=this.$rootGetters["type-map/rowValueGetter"],{completionTime:n,startTime:r}=this.status,o=e&&t?t(e,"Duration")(this):null,a=o&&r?(0,i.Fp)(r,n||new Date):0;return{value:n?{staticValue:o}:{startTime:r},seconds:a}}}},65502:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return p}});var r=n(14220),i=n(2841),o=n(83288),a=n(68851),s=n(35664),l=n(41476),c=n(76978),u=n(39975),d=n(7325),h=n(4364);class p extends u.A{showMasthead(e){return e===r.nW}applyDefaults(){(0,c.hZ)(this,"disableOpenApiValidation",!1),(0,c.hZ)(this,"noHooks",!1),(0,c.hZ)(this,"skipCRDs",!1),(0,c.hZ)(this,"timeout",300),(0,c.hZ)(this,"wait",!0),(0,c.hZ)(this,"upgradeAvailableVersion","")}get _availableActions(){const e=super._availableActions,t={action:"goToUpgrade",enabled:!0,icon:"icon icon-edit",label:this.t("catalog.install.action.goToUpgrade")};return e.unshift(t),e}get warnDeletionMessage(){if(this.upgradeAvailable===d.I0.NOT_APPLICABLE){const e=this.spec?.chart?.metadata?.annotations?.[i.W8.MANAGED]||"Rancher";return this.t("catalog.delete.warning.managed",{manager:"true"===e?"Rancher":e,name:this.name})}return null}matchingCharts(e){const t=this.spec?.chart;if(!t)return[];const n=t.metadata?.name,r=t.metadata?.annotations?.[i.W8.SOURCE_REPO_NAME]||this.metadata?.labels?.[i.W8.CLUSTER_REPO_NAME],o=this.$rootGetters["catalog/chart"]({chartName:n,repoName:r,includeHidden:e,multiple:!0})||[];if(0===o.length)return[];if(!r||o.length>1){const e=t?.metadata?.home,n=o.filter(({versions:t})=>{if(e===t[0]?.home)return!0;for(let n=1;n<t.length;n++){const{version:r,home:i}=t[n];if(r===this.currentVersion&&i===e)return!0}return!1});return n}return o}get currentVersion(){return this.spec?.chart?.metadata?.version}get upgradeAvailable(){if(this.spec?.chart?.metadata?.annotations?.[i.W8.MANAGED]||this.spec?.chart?.metadata?.annotations?.[i.Hs.BUNDLE_ID])return d.I0.NOT_APPLICABLE;const e=this.matchingCharts(!1);return 0===e.length?d.I0.NO_UPGRADE:1===e.length?this.evaluateUpgradeForChart(e[0]):this.handleMultipleUpgradeMatches(e)}evaluateUpgradeForChart(e){const t=this.$rootGetters["currentCluster"].workerOSs,n=this.$rootGetters["prefs/get"](l.kJ),r=(0,d.bh)(e,t,n),i=r?.[0],a=i?.version;return this.currentVersion&&a&&(0,o.UD)(this.currentVersion,a)<0?(this.upgradeAvailableVersion=f(a),d.I0.SINGLE_UPGRADE):d.I0.NO_UPGRADE}handleMultipleUpgradeMatches(e){const t=[];for(const n of e){const e=this.evaluateUpgradeForChart(n);e===d.I0.SINGLE_UPGRADE&&t.push(n)}if(t.length>1)return d.I0.MULTIPLE_UPGRADES;if(1===t.length){const e=t[0]?.versions?.[0]?.version;return this.upgradeAvailableVersion=f(e),d.I0.SINGLE_UPGRADE}return d.I0.NO_UPGRADE}get upgradeAvailableSort(){return this.upgradeAvailable===d.I0.SINGLE_UPGRADE?(0,o.Xt)(this.upgradeAvailableVersion):"~"}get currentVersionCompatible(){const e=this.$rootGetters["currentCluster"].workerOSs,t=this.matchingCharts(!1)[0];if(!t)return!0;const n=t.versions.find(e=>e.version===this.currentVersion);if(!n)return!0;const r=(0,d.bh)(t,e,!0)||[],i=!!r.find(e=>e.version===this.currentVersion);return i}get stateDescription(){return this.currentVersionCompatible?null:this.upgradeAvailableVersion?this.t("catalog.os.versionIncompatible"):this.t("catalog.os.chartIncompatible")}goToUpgrade(e,t){const n=this.matchingCharts(!0)[0],i={[r.CU]:this.metadata.namespace,[r.o_]:this.metadata.name,[r.xv]:e||this.currentVersion};n&&(i[r.NO]=n.repoName,i[r.Eo]=n.repoType,i[r.RX]=n.chartName),t&&(i[r.Rm]=r.Qp),this.currentRouter().push({name:"c-cluster-apps-charts-install",params:{product:this.$rootGetters["productId"],cluster:this.$rootGetters["clusterId"]},query:i})}get details(){const e=this.$rootGetters["i18n/t"],t=this.spec?.info?.firstDeployed,n=this.spec?.info?.lastDeployed;return t&&n&&t!==n?[{label:e('model."catalog.cattle.io.app".lastDeployed'),formatter:"LiveDate",content:n}]:[]}get nameDisplay(){const e=this.spec?.name||this.metadata?.name||this.id||"";return e}get chartDisplay(){const e=this.spec?.chart?.metadata?.name||"?";return`${e}:${this.versionDisplay}`}get versionDisplay(){return f(this.currentVersion)}get versionSort(){return(0,o.Xt)(this.versionDisplay)}async remove(e={}){const t=await this.doAction("uninstall",e),n=await this.$dispatch("find",{type:s.W8.OPERATION,id:`${t.operationNamespace}/${t.operationName}`});try{await n.waitForLink("logs"),n.openLogs()}catch(r){}}get relatedResourcesToRemove(){return async()=>{const e=this.spec?.chart?.metadata?.annotations?.[i.W8.AUTO_INSTALL]?.replace("=match","");return await this.$dispatch("find",{type:s.W8.APP,id:`${this.metadata.namespace}/${e}`})}}get canDelete(){return this.hasAction("uninstall")}get deployedResources(){return(0,a.WP)(this.metadata?.relationships||[],"rel","helmresource")}async fetchValues(e=!1){if(!this.secretId)return;const t=!!this._values&&!!this._chartValues;if(!t||e)try{await this.$dispatch("find",{type:s.bB,id:this.secretId,opt:{force:e||!!this._secret&&!t,watch:!1,params:{includeHelmData:!0}}})}catch(n){h.error(`Cannot find values for ${this.id} (unable to fetch)`,n)}}get secretId(){const e=this.metadata,t=e.ownerReferences?.find(e=>e.kind.toLowerCase()===s.bB),n=t?.name,r=e.namespace;return r&&n?`${r}/${n}`:(h.warn(`Cannot find values for ${this.id} (cannot find related secret namespace or id)`),null)}get _secret(){return this.secretId?this.$getters["byId"](s.bB,this.secretId):null}_validateSecret(e){if(void 0===this._secret)throw new Error(`Cannot find ${e} for ${this.id} (chart secret has not been fetched via app \`fetchValues\`)`);if(null===this._secret)throw new Error(`Cannot find ${e} for ${this.id} (chart secret cannot or has failed to fetch) `)}get valuesLoaded(){return!!this._values&&!!this._chartValues}get values(){return this._validateSecret("values"),this._values}get _values(){return this._secret?.data?.release?.config}get chartValues(){return this._validateSecret("chartValues"),this._chartValues}get _chartValues(){return this._secret?.data?.release?.chart?.values}}function f(e){if(!e)return"?";e.match(/^v/i)&&(e=e.substr(1));const t=e.match(/[0-9a-f]{32,}/);return t&&(e=e.replace(t[0],t[0].substr(0,7))),e}},75348:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return m}});var r=n(50667),i=n(2841),o=n(68851),a=n(35664),s=n(9262),l=n(73883),c=n(14220);const u={s:1,m:60,h:3600,d:86400};const d=[{divisor:u.d,suffix:"d"},{divisor:u.h,suffix:"h"},{divisor:u.m,suffix:"m"},{divisor:u.s,suffix:"s"}];function h(e){if(e<=0)return"0s";let t=e;return d.map(({divisor:e,suffix:n})=>{const r=Math.floor(t/e);return t%=e,r>0?`${r}${n}`:""}).filter(Boolean).join(" ")}var p=n(39975),f=n(39618);class m extends p.A{applyDefaults(){this.spec||(this["spec"]={url:""})}get _isClusterRepoDisabled(){return!1===this.spec?.enabled}get _availableActions(){const e=super._availableActions;return(0,o.PT)(e,0,{divider:!0}),this._isClusterRepoDisabled?(0,o.PT)(e,1,{action:"enableClusterRepo",label:this.t("action.enable"),icon:"icon icon-play",enabled:!0,bulkable:!0}):((0,o.PT)(e,1,{action:"disableClusterRepo",label:this.t("action.disable"),icon:"icon icon-pause",enabled:!0,bulkable:!0}),(0,o.PT)(e,0,{action:"refresh",label:this.t("action.refresh"),icon:"icon icon-refresh",enabled:!!this.links.update,bulkable:!0,bulkAction:"refreshBulk"})),e}async refresh(e=!0){try{const t=(new Date).toISOString().replace(/\.\d+Z$/,"Z");this.spec.forceUpdate=t,await this.save(),await this.waitForState("active",3e4,1e3),e&&this.$dispatch("catalog/load",{force:!0,repoKeys:[this._key]},{root:!0})}catch(t){this.$dispatch("growl/fromError",{title:this.t("catalog.repo.error.refresh",{},"Error refreshing repository"),err:t},{root:!0})}}async refreshBulk(e){await Promise.allSettled(e.map(e=>e.refresh(!1))),this.$dispatch("catalog/load",{force:!0,repoKeys:e.map(e=>e._key)},{root:!0})}async disableClusterRepo(){this.spec.enabled=!1,await this.save()}async enableClusterRepo(){this.spec.enabled=!0,await this.save()}get isGit(){return!!this.spec?.gitRepo}get isOciType(){const e="oci"===this.spec.url?.split(":")[0],t=Object.prototype.hasOwnProperty.call(this.spec,"insecurePlainHttp");return e||t}get isAirgap(){return"bundled"===this.$rootGetters["management/byId"](a.Mc.SETTING,s.HG.SYSTEM_CATALOG)?.value}get isRancherSource(){return this.isRancherHost||this.isAirgapMirror}get isAirgapMirror(){return this.isAirgap&&!this.isRancherHost&&["rancher-charts","rancher-partner-charts"].includes(this.metadata?.name)}get isRancherHost(){let e;return(!this.spec?.url||!this.spec?.gitRepo)&&(!!(this.spec?.url&&(e=(0,r.qg)(this.spec.url),e&&t(e.host)))||!!(this.spec?.gitRepo&&(e=(0,r.qg)(this.spec.gitRepo),e&&t(e.host))));function t(e){return e=(e||"").toLowerCase(),"rancher.io"===e||e.endsWith(".rancher.io")}}get isRancher(){return this.isRancherSource&&"rancher-charts"===this.metadata.name}get isPartner(){return this.isRancherSource&&"rancher-partner-charts"===this.metadata.name}get canLoad(){return"active"===this.metadata?.state?.name}get isSuseAppCollectionFromUI(){return this.metadata?.annotations?.[i.W8.SUSE_APP_COLLECTION]}get isSuseAppCollection(){return this.isSuseAppCollectionFromUI||this.spec?.url?.startsWith("oci://dp.apps.rancher.io/charts")}get typeDisplay(){return this.isSuseAppCollectionFromUI?f.IL:this.spec.gitRepo?"git":this.spec.url?this.isOciType?"oci":"http":"?"}get nameDisplay(){const e=this.metadata?.name,t=`catalog.repo.name."${e}"`;return this.$rootGetters["i18n/withFallback"](t,null,e)}detailPageHeaderActionOverride(e){return e===c.YQ?this.t("catalog.repo.add"):null}get urlDisplay(){return this.status?.url||this.spec.gitRepo||this.spec.url}get branchDisplay(){return this.spec?.gitBranch||"(default)"}get defaultRefreshIntervalHours(){return this.isOciType?24:1}get defaultRefreshInterval(){return 3600*this.defaultRefreshIntervalHours}get refreshIntervalDisplay(){const e=this.spec?.refreshInterval;return e<0?this.t("generic.disabled"):h(e??this.defaultRefreshInterval)}get details(){return[{label:this.t("generic.type"),content:this.typeDisplay},{label:this.t("catalog.repo.refreshInterval.label"),content:this.refreshIntervalDisplay},{label:this.t("catalog.repo.downloaded.label"),content:this.status?.downloadTime,formatter:"LiveDate",formatterOpts:{addSuffix:!0}}]}get stateObj(){return this.metadata?.state?{...this.metadata.state,transitioning:!(this.metadata.generation>this.status?.observedGeneration)&&this.metadata.state.transitioning}:void 0}get stateDisplay(){return this._isClusterRepoDisabled?this.t("generic.disabled"):(0,l.ch)(this.state)}get stateBackground(){return this._isClusterRepoDisabled?"badge-disabled":(0,l.uU)(this.state,this.stateObj?.error,this.stateObj?.transitioning).replace("text-","bg-")}waitForOperation(e,t,n=2e3){return this.waitForTestFn(()=>!!this.$getters["schemaFor"](a.W8.OPERATION)&&(!!this.$getters["byId"](a.W8.OPERATION,e)||void this.$dispatch("find",{type:a.W8.OPERATION,id:e})),"catalog operation fetch",t,n)}async save(){return 0===this.spec.clientSecret?.name?.search(a.JF)&&(this.metadata.annotations||(this.metadata.annotations={}),this.metadata.annotations[i.W8.SUSE_APP_COLLECTION]="true"),super.save()}}},67784:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return a}});var r=n(68851),i=n(92043),o=n(39975);class a extends o.A{get _availableActions(){const e=super._availableActions,t=(0,r.jq)(e,"altAction"," remove");let n=e.length-1;t&&(n=e.indexOf(t));const i={action:"openLogs",enabled:!0,icon:"icon icon-chevron-right",label:this.t("action.openLogs"),total:1};return(0,r.PT)(e,n+1,i),(0,r.PT)(e,n+2,{divider:!0}),e}openLogs(){this.$dispatch("wm/open",{id:`${this.id}-logs`,label:`${(0,i.TF)(this.status.action)} ${this.status.namespace}:${this.status?.releaseName||"chart"}`,icon:"file",component:"ContainerLogs",attrs:{pod:this,url:this.links.logs}},{root:!0})}}},71029:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(75348);class i extends r["default"]{}},97960:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(39975);const i=Object.freeze({CACHED:"cached",DISABLED:"disabled",PENDING:"pending"});class o extends r.A{get name(){return this.spec?.plugin?.name}get description(){return this.spec?.plugin?.description}get version(){return this.spec?.plugin?.version}get isInitialized(){return this.status?.cacheState!==i.PENDING}get pluginMetadata(){return this.spec?.plugin?.metadata||{}}get isDeveloper(){return"true"===this.pluginMetadata?.developer}get plugin(){return this.spec?.plugin||{}}}},92737:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return f}});var r=n(7325),i=n(14220),o=n(10213),a=n(41476),s=n(11524),l=n(51481),c=n(39975),u=n(35664),d=n(2841),h=n(23464),p=n.n(h);class f extends c.A{queryParams(e,t){const n=this.latestCompatibleVersion.version,r={[i.Eo]:this.repoType,[i.NO]:this.repoName,[i.RX]:this.chartName,[i.xv]:n};return this.deprecated&&(r[i.GQ]=!0),e&&(r[e]=i.Qp),t&&(r[i.dV]=i.Qp),r}goToInstall(e,t,n){const r=this.queryParams(e,n),i=this.$rootGetters["currentCluster"];this.currentRouter().push({name:"c-cluster-apps-charts-install",params:{cluster:t||i?.id||o.w},query:r})}get matchingInstalledApps(){const e=this.versions?.[0]||[],t=e?.home,n=this.$rootGetters["cluster/all"](u.W8.APP);return n.filter(e=>{const n=e?.spec?.chart?.metadata,r=n?.name,i=n?.version,o=n?.home,a=n?.annotations?.[d.W8.SOURCE_REPO_NAME]||e?.metadata?.labels?.[d.W8.CLUSTER_REPO_NAME];return!(r!==this.chartName||!a||a!==this.repoName)&&(!(!t||o!==t)||this.versions?.some(e=>e.version===i&&o===t))})}get isInstalled(){return this.matchingInstalledApps.length>=1}get upgradeable(){return this.isInstalled&&this.matchingInstalledApps.some(e=>e.upgradeAvailable===r.I0.SINGLE_UPGRADE)}get installedCount(){return this.matchingInstalledApps.length}get latestCompatibleVersion(){if(this._latestCompatibleVersion)return this._latestCompatibleVersion;const e=this.$rootGetters["currentCluster"],t=e?.workerOSs,n=this.$rootGetters["prefs/get"](a.kJ);return this._latestCompatibleVersion=(0,s.Gl)(this,t,n),this._latestCompatibleVersion}get cardContent(){const e=this.latestCompatibleVersion,t=[];e&&(t.push({icon:"icon-version-alt",iconTooltip:{key:"tableHeaders.version"},label:e.version}),(0,l.c2)(e.created)||t.push({icon:"icon-refresh-alt",iconTooltip:{key:"tableHeaders.lastUpdated"},label:p()(e.created).format("MMM D, YYYY")}));const n=[{type:i.NO,icon:"repository-alt",iconTooltip:{key:"tableHeaders.repoName"},labels:[this.repoNameDisplay],labelTooltip:this.t("catalog.charts.findSimilar.message",{type:this.t("catalog.charts.findSimilar.types.repo")},!0)}];this.categories.length&&n.push({type:i.XJ,icon:"category-alt",iconTooltip:{key:"generic.category"},labels:this.categories,labelTooltip:this.t("catalog.charts.findSimilar.message",{type:this.t("catalog.charts.findSimilar.types.category")},!0)}),this.tags.length&&n.push({type:i.Dk,icon:"tag-alt",iconTooltip:{key:"generic.tags"},labels:this.tags,labelTooltip:this.t("catalog.charts.findSimilar.message",{type:this.t("catalog.charts.findSimilar.types.tag")},!0)});const r=[];if(this.deprecated&&r.push({icon:"icon-alert-alt",color:"error",tooltip:{key:"generic.deprecated"}}),this.upgradeable&&r.push({icon:"icon-upgrade-alt",color:"info",tooltip:{key:"generic.upgradeable"}}),this.isInstalled){const e=this.installedCount>1,t=this.matchingInstalledApps[0]?.spec?.chart?.metadata?.version;let n=e?this.t("generic.installedMultiple"):this.t("generic.installed");e||(n=`${n} (${t})`),r.push({icon:"icon-confirmation-alt",color:"success",tooltip:{text:n}})}return{subHeaderItems:t,footerItems:n,statuses:r}}}},91380:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return a}});var r=n(14220),i=n(76978),o=n(39975);class a extends o.A{showMasthead(e){return e===r.nW}applyDefaults(){this.charts||(0,i.hZ)(this,"charts",[{}])}}},4451:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(76978),i=n(39975);class o extends i.A{applyDefaults(){this.charts||(0,r.hZ)(this,"charts",[{}])}}},45231:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return h}});var r=n(2841);n(68851),n(4364);function i(e){return e.toLowerCase().replace(/[^a-z0-9]/gi,"")}["username","password","accesskey","secretkey","accesskeyid","secretkeyid","accesskeysecret","token","apikey","secret","clientid","clientsecret","subscriptionid","tenantid"].map(e=>i(e)),["location","region"].map(e=>i(e));const o=["username","accesskey","accesskeyid","clientid"].map(e=>i(e)),a=["token","apikey","secret"].map(e=>i(e)),s=[].map(e=>i(e));var l=n(76978),c=n(35664),u=n(92043),d=n(89865);class h extends d.A{get hasSensitiveData(){return!0}get canCustomEdit(){return!0}get disableResourceDetailDrawer(){return!0}get _detailLocation(){return{name:"c-cluster-manager-cloudCredential-id",params:{product:this.$rootGetters["productId"],cluster:this.$rootGetters["clusterId"],id:this.id}}}get parentLocationOverride(){return{name:"c-cluster-manager-cloudCredential",params:{cluster:this.$rootGetters["clusterId"]}}}get secretName(){return this.id.replace(":","/")}get secret(){return this.$rootGetters["management/byId"](c.bB,this.secretName)}async getSecret(){await this.$dispatch("management/find",{type:c.bB,id:this.secretName},{root:!0})}get configKey(){return Object.keys(this).find(e=>e.endsWith("credentialConfig"))}get provider(){const e=this.annotations?.[r.qt.CREDENTIAL_DRIVER];if(e)return e;const t=this.configKey;if(t){const e=this.$rootGetters["plugins/credentialDriverFor"](t.replace(/credentialConfig$/,""));return e}return null}setProvider(e){this.setAnnotation(r.qt.CREDENTIAL_DRIVER,e),Object.keys(this).forEach(t=>{t=t.toLowerCase(),t.endsWith("config")&&t!==`${e}config`&&(0,l.hZ)(this,t,null)}),this[`${e}credentialConfig`]||(0,l.hZ)(this,`${e}credentialConfig`,{})}get decodedData(){const e=this.configKey;return e?this[e]:{}}setData(e,t){const n=e&&"object"===typeof e;let r;this[this.configKey]&&!n||(0,l.hZ)(this,this.configKey,{}),r=n?e:{[e]:t};for(const i in r)(0,l.hZ)(this,`"${this.configKey}"."${i}"`,r[i])}get providerDisplay(){const e=(this.provider||"").toLowerCase();return this.$rootGetters["i18n/withFallback"](`cluster.provider."${e}"`,null,e)}get publicData(){let{publicKey:e,publicMode:t}=this.$rootGetters["plugins/credentialOptions"](this.provider);const n={full:o,prefix:a,suffix:s};if(!e)for(const o in this.decodedData||{}){if(e)break;if(!(0,l.Im)(this.decodedData[o]))for(const r in n)if(n[r].includes(i(o))){e=o,t=r;break}}if(!e)return null;let r=this.decodedData[e];if(r||(r=this.secret?.decodedData?.[`${this.provider}credentialConfig-${e}`]),!r)return null;const c=Math.min(8,Math.floor(r.length/2));return"prefix"===t?`${(0,u.ZD)(r.substr(0,c))}…`:"suffix"===t?`…${(0,u.ZD)(r.substr(-1*c))}`:(0,u.ZD)(r)}get doneRoute(){return"c-cluster-manager-cloudCredential"}}},16787:function(e,t,n){"use strict";n.r(t),n.d(t,{ANNOTATIONS_CONTAINS_PROTECTED:function(){return a},LABEL_CONTAINS_PROTECTED:function(){return o},default:function(){return s}});var r=n(89865),i=n(35664);const o=["io.cattle.lifecycle","kubernetes.io","cattle.io","k3s.io"],a=["coreos.com","cattle.io","k3s.io","kubernetes.io","k3s.io","rancher.io"];class s extends r.A{get systemLabels(){return Object.keys(this.labels||{}).filter(e=>o.find(t=>e.includes(t)))}get systemAnnotations(){return Object.keys(this.annotations||{}).filter(e=>a.find(t=>e.includes(t)))}get hasSystemLabels(){return!!(this.systemLabels||[]).length}get hasSystemAnnotations(){return!!(this.systemAnnotations||[]).length}get provisioningClusterNs(){return this.annotations?.["objectset.rio.cattle.io/owner-namespace"]||"fleet-default"}get provisioningClusterName(){return this.annotations?.["objectset.rio.cattle.io/owner-name"]||this.id}get provisioningClusterId(){return`${this.provisioningClusterNs}/${this.provisioningClusterName}`}waitForProvisioning(e=6e4,t){return this.waitForTestFn(()=>{const e=this.provisioningClusterId;return e&&!!this.$rootGetters["management/byId"](i.Z7.RANCHER_CLUSTER,e)},this.$rootGetters["i18n/t"]("cluster.managementTimeout",{type:i.Z7.RANCHER_CLUSTER,name:this.provisioningClusterId}),e,t)}}},61843:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return h},notOnlyOfRole:function(){return d}});var r=n(35664),i=n(2841),o=n(27278),a=n(44458),s=n(68851),l=n(76978),c=n(6198),u=n(77684);function d(e,t){const n={};if(e.isControlPlane&&(n.isControlPlane=!1),e.isEtcd&&(n.isEtcd=!1),0===Object.keys(n).length)return!0;for(const r of t)if(Object.keys(n).forEach(e=>{r[e]&&(n[e]?delete n[e]:n[e]=!0)}),0===Object.keys(n).length)return!0;return!1}class h extends u["default"]{get _availableActions(){const e=super._availableActions,t={action:"openSsh",enabled:!!this.links.shell&&this.isRunning,icon:"icon icon-chevron-right",label:"SSH Shell"},n={action:"downloadKeys",enabled:!!this.links.sshkeys,icon:"icon icon-download",label:this.t("node.actions.downloadSSHKey")},r={action:"toggleForceRemoveModal",altAction:"forceMachineRemove",enabled:!!this.isRemoveForceable,label:this.t("node.actions.forceDelete"),icon:"icon icon-trash"},i={action:"toggleScaleDownModal",bulkAction:"toggleScaleDownModal",enabled:!!this.canScaleDown,icon:"icon icon-minus",label:this.t("node.actions.scaleDown"),bulkable:!0};return(0,s.PT)(e,0,{divider:!0}),(0,s.PT)(e,0,n),(0,s.PT)(e,0,t),(0,s.PT)(e,0,i),(0,s.PT)(e,0,r),e}get canClone(){return!1}openSsh(e){const t=e||this.nameDisplay;this.$dispatch("wm/open",{id:`${this.id}-ssh`,label:t,icon:"terminal",component:"MachineSsh",attrs:{machine:this,pod:{}}},{root:!0})}downloadKeys(){(0,c.Is)(this.links.sshkeys)}toggleForceRemoveModal(e=this){this.$dispatch("promptModal",{componentProps:{machine:e},component:"ForceMachineRemoveDialog"})}async forceMachineRemove(){const e=await this.machineRef();e.setAnnotation(i.qt.FORCE_MACHINE_REMOVE,"true"),await e.save()}toggleScaleDownModal(e=this){this.$dispatch("promptModal",{resources:e,component:"ScaleMachineDownDialog",modalWidth:"450px"})}async machineRef(){const e=this.spec.infrastructureRef,t=`${this.metadata.namespace}/${e.name}`,n=`rke-machine.cattle.io.${e.kind.toLowerCase()}`;return await this.$dispatch("find",{type:n,id:t})}get poolName(){return this.metadata?.labels?.[i.qt.DEPLOYMENT_NAME]||""}get poolId(){const e=`${this.metadata.namespace}/${this.poolName}`;return e}get pool(){return this.$rootGetters["management/byId"](r.Z7.MACHINE_DEPLOYMENT,this.poolId)}get operatingSystem(){return this.metadata?.labels["cattle.io/os"]||"linux"}get kubeNodeDetailLocation(){const e=this.status?.nodeRef?.name,t=this.cluster?.status?.clusterName;return e&&t?{name:"c-cluster-product-resource-id",params:{cluster:t,product:o.o,resource:r.NW,id:e}}:e}get labels(){return this.metadata?.labels||{}}get isWorker(){return"true"===`${this.labels[i.Ub.WORKER]}`}get isControlPlane(){return"true"===`${this.labels[i.Ub.CONTROL_PLANE]}`}get isEtcd(){return"true"===`${this.labels[i.Ub.ETCD]}`}get isRemoveForceable(){const e=(0,l.Jt)(this,"status.conditions"),t=((0,s.jq)(e,"type","InfrastructureReady")||{}).reason;return"DeleteError"===t||null}get canScaleDown(){return!(!this.canUpdate||!this.pool?.canUpdate)&&d(this,this.cluster?.machines)}get roles(){const{isControlPlane:e,isWorker:t,isEtcd:n}=this;return(0,a.listNodeRoles)(e,t,n,this.t("generic.all"))}get isRunning(){return"Running"===this.status?.phase}get internalIps(){return this.status?.addresses?.filter(({type:e})=>e===r.FV.INTERNAL_IP).map(e=>e.address)||[]}get externalIps(){return this.status?.addresses?.filter(({type:e})=>e===r.FV.EXTERNAL_IP).map(e=>e.address)||[]}get internalIp(){return this.internalIps[0]}get externalIp(){return this.externalIps[0]}}},22456:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return p}});var r=n(35664),i=n(92043),o=n(74302),a=n(99726),s=n(79401),l=n(2841),c=n(61843);const u={MACHINE_INV_SELECTOR_TEMPLATES:"MachineInventorySelectorTemplate"},d={MACHINE_TEMPLATE:"HarvesterMachineTemplate"};var h=n(77684);class p extends h["default"]{get groupByPoolLabel(){return`${this.$rootGetters["i18n/t"]("resourceTable.groupLabel.machinePool",{name:(0,i.ZD)(this.nameDisplay)})}`}get groupByPoolShortLabel(){return`${this.$rootGetters["i18n/t"]("resourceTable.groupLabel.machinePool",{name:(0,i.ZD)(this.nameDisplay)})}`}get infrastructureRefKind(){return this.spec?.template?.spec?.infrastructureRef?.kind}get templateType(){return this.infrastructureRefKind?`rke-machine.cattle.io.${this.infrastructureRefKind.toLowerCase()}`:null}get template(){const e=this.spec.template.spec.infrastructureRef,t=`${this.metadata.namespace}/${e.name}`,n=this.$rootGetters["management/byId"](this.templateType,t);return n}get providerName(){return this.template?.nameDisplay}get providerDisplay(){const e=(this.template?.provider||"").toLowerCase();return this.$rootGetters["i18n/withFallback"](`cluster.provider."${e}"`,null,"generic.unknown",!0)}get providerLocation(){return this.template?.providerLocation||this.t("node.list.poolDescription.noLocation")}get providerSize(){return this.template?.providerSize||this.t("node.list.poolDescription.noSize")}get providerSummary(){if(this.template)switch(this.infrastructureRefKind){case d.MACHINE_TEMPLATE:return null;default:return`${this.providerDisplay} – ${this.providerLocation} / ${this.providerSize} (${this.providerName})`}return null}get desired(){return this.spec?.replicas||0}get pending(){return Math.max(0,this.desired-(this.status?.replicas||0))}get outdated(){return Math.max(0,(this.status?.replicas||0)-(this.status?.upToDateReplicas||0))}get ready(){return this.status?.availableReplicas||0}get unavailable(){return Math.max(0,(this.status?.replicas||0)-(this.status?.availableReplicas||0))}get isControlPlane(){return"true"===`${this.spec?.template?.metadata?.labels?.[l.Ub.CONTROL_PLANE]}`}get isEtcd(){return"true"===`${this.spec?.template?.metadata?.labels?.[l.Ub.ETCD]}`}get inClusterSpec(){const e=this.template?.metadata?.annotations["rke.cattle.io/cloned-from-name"],t=this.spec?.template?.spec?.infrastructureRef?.name,n=e||t,r=this.cluster.spec.rkeConfig.machinePools;return r.find(e=>e.machineConfigRef.name===n)}scalePool(e,t=!0,n=0){if(!this.inClusterSpec)return;const i=this.cluster;if(this.inClusterSpec.quantity+=e,!t)return;const o=this.cluster,l=this.$rootGetters["management/byId"](r.Z7.RANCHER_CLUSTER,this.cluster.id);this.scaleTimer&&clearTimeout(this.scaleTimer),this.scaleTimer=setTimeout(()=>{this.cluster.save().catch(async t=>{let r=(0,a.rz)(t);if(409===t.status&&n<2){const t=await(0,s.Rq)(i,o,l,{dispatch:this.$dispatch,getters:this.$rootGetters},"management");if(!1===t)return this.scalePool(e,!0,n+1);r=t}this.$dispatch("growl/fromError",{title:"Error scaling pool",err:r},{root:!0})})},1e3)}get isAutoscalerEnabled(){return this.annotations?.[l.qt.AUTOSCALER_MACHINE_POOL_MIN_SIZE]||this.annotations?.[l.qt.AUTOSCALER_MACHINE_POOL_MAX_SIZE]}canScaleDownPool(){return!(!this.canUpdate||0===this.inClusterSpec?.quantity||this.infrastructureRefKind===u.MACHINE_INV_SELECTOR_TEMPLATES)&&(!this.isEtcd&&!this.isControlPlane||(0,c.notOnlyOfRole)(this,this.cluster.machines))}canScaleUpPool(){return this.infrastructureRefKind!==u.MACHINE_INV_SELECTOR_TEMPLATES}get showScalePool(){return this.canScaleDownPool()||this.canScaleUpPool()}get stateParts(){const e=[{label:"Pending",color:"bg-info",textColor:"text-info",value:this.pending,sort:1},{label:"Outdated",color:"bg-warning",textColor:"text-warning",value:this.outdated,sort:2},{label:"Unavailable",color:"bg-error",textColor:"text-error",value:this.unavailable,sort:3},{label:"Ready",color:"bg-success",textColor:"text-success",value:this.ready,sort:4}].filter(e=>e.value>0);return(0,o.Ul)(e,"sort:desc")}}},5555:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(77684);class i extends r["default"]{}},44458:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return d},listNodeRoles:function(){return m}});var r=n(92043),i=n(2841),o=n(35664),a=n(95799),s=n(39975),l=n(14220),c=n(50025);const u="nodeRunningPods";class d extends s.A{get _availableActions(){const e=this.norman?.actions||{},t={action:"cordon",enabled:!!e.cordon,icon:"icon icon-pause",label:"Cordon",total:1,bulkable:!0},n={action:"uncordon",enabled:!!e.uncordon,icon:"icon icon-play",label:"Uncordon",total:1,bulkable:!0},r={action:"drain",enabled:!!e.drain,icon:"icon icon-dot-open",label:this.t("drainNode.action"),bulkable:!0,bulkAction:"drain"},i={action:"stopDrain",enabled:!!e.stopDrain,icon:"icon icon-x",label:this.t("drainNode.actionStop"),bulkable:!0},o={action:"openSsh",enabled:!!this.provisionedMachine?.links?.shell,icon:"icon icon-chevron-right",label:"SSH Shell"},a={action:"downloadKeys",enabled:!!this.provisionedMachine?.links?.sshkeys,icon:"icon icon-download",label:this.t("node.actions.downloadSSHKey")};return[o,a,{divider:!0},t,n,r,i,{divider:!0},...super._availableActions]}openSsh(){this.provisionedMachine.openSsh(this.nameDisplay)}downloadKeys(){this.provisionedMachine.downloadKeys()}get showDetailStateBadge(){return!0}get name(){return this.metadata.name}get addresses(){return this.status?.addresses||[]}get internalIps(){return this.addresses.filter(e=>"InternalIP"===e.type).map(e=>e.address)}get externalIps(){const e=this.metadata.annotations[i.Z_.EXTERNAL_IP],t=this.addresses.filter(e=>"ExternalIP"===e.type).map(e=>e.address);return t.concat(e||[])}get internalIp(){return this.internalIps[0]}get externalIp(){return this.externalIps[0]}get labels(){return this.metadata?.labels||{}}get customLabelCount(){return this.customLabels.length}get customLabels(){const e=[];if(this.labels)for(const t in this.labels){const[n]=t.split("/");i.uf.includes(n)||e.push(`${t}=${this.labels[t]}`)}return e}get isWorker(){return this.managementNode?this.managementNode.isWorker:"true"===`${this.labels[i.vi.WORKER]}`}get isControlPlane(){return this.managementNode?this.managementNode.isControlPlane:"true"===`${this.labels[i.vi.CONTROL_PLANE]}`||"true"===`${this.labels[i.vi.CONTROL_PLANE_OLD]}`}get isEtcd(){return this.managementNode?this.managementNode.isEtcd:"true"===`${this.labels[i.vi.ETCD]}`}get hasARole(){const e=Object.values(i.vi);return Object.keys(this.labels).some(t=>{const n=e.includes(t),r="true"===`${this.labels[t]}`;return n&&r})}get roles(){const{isControlPlane:e,isWorker:t,isEtcd:n}=this;return m(e,t,n,this.t("generic.all"))}get version(){return this.status.nodeInfo.kubeletVersion}get cpuUsage(){return this.isFromNorman&&"eks"===this.provider?(0,a.ao)(this.podRequests.cpu||"0"):(0,a.ao)(this.$rootGetters["cluster/byId"](o.$v.NODE,this.id)?.usage?.cpu||"0")}get cpuAllocatable(){return(0,a.ao)(this.status?.allocatable?.cpu||"0")}get cpuCapacity(){return(0,a.ao)(this.status?.capacity?.cpu||"0")}get cpuUsagePercentage(){return(100*this.cpuUsage/this.cpuAllocatable).toString()}get ramUsage(){return this.isFromNorman&&"eks"===this.provider?(0,a.ao)(this.podRequests.memory||"0"):(0,a.ao)(this.$rootGetters["cluster/byId"](o.$v.NODE,this.id)?.usage?.memory||"0")}get ramCapacity(){return(0,a.ao)(this.status.capacity?.memory)}get ramUsagePercentage(){return(100*this.ramUsage/this.ramCapacity).toString()}get ramAllocatable(){return(0,a.ao)(this.status?.allocatable?.memory)}get ramReserved(){return(0,a.ao)(this.podRequests?.memory||"0")}get cpuReserved(){return(0,a.ao)(this.podRequests?.cpu||"0")}get podReserved(){return(0,a.ao)(this.podRequests?.pods||"0")}get systemReservedRam(){return Math.max(this.ramCapacity-this.ramAllocatable,0)}get systemReservedCpu(){return Math.max(this.cpuCapacity-this.cpuAllocatable,0)}get podUsage(){return f(this.status.allocatable?.pods,this.status.capacity?.pods)}get podConsumedUsage(){return(this.podConsumed/this.podCapacity*100).toString()}get podCapacity(){return(0,a.ao)(this.status.capacity?.pods)}get podConsumed(){const e=this.pods.filter(e=>"running"===e.state);return e.length||0}get podRequests(){return JSON.parse(this.metadata.annotations["management.cattle.io/pod-requests"]||"{}")}get isPidPressureOk(){return this.isCondition("PIDPressure","False")}get isDiskPressureOk(){return this.isCondition("DiskPressure","False")}get isMemoryPressureOk(){return this.isCondition("MemoryPressure","False")}get isKubeletOk(){return this.isCondition("Ready")}get isCordoned(){return!!this.spec.unschedulable}get isSchedulable(){return!this.spec.unschedulable}get drainedState(){const e=this.managementNode?.status.conditions.find(e=>"Drained"===e.type);if(e){if("True"===e.status)return"drained";if(e.transitioning)return"draining"}return null}get containerRuntimeVersion(){return this.status.nodeInfo.containerRuntimeVersion.replace("docker://","")}get containerRuntimeIcon(){return this.status.nodeInfo.containerRuntimeVersion.includes("docker")?"icon-docker":""}async cordon(e){const t=Array.isArray(e)?e:[this];await Promise.all(t.map(e=>e.norman?.doAction("cordon")))}async uncordon(e){const t=Array.isArray(e)?e:[this];await Promise.all(t.map(e=>e.norman?.doAction("uncordon")))}get clusterId(){const e=this.links.self.split("/");return e.length>6&&"k8s"===e[e.length-6]&&"clusters"===e[e.length-5]?e[e.length-4]:l.G8}get normanNodeId(){const e=(this.$rootGetters["management/all"](o.Mc.NODE)||[]).find(e=>e.id.startsWith(this.clusterId)&&e.status.nodeName===this.name);return e?e.id.replace("/",":"):null}get norman(){return this.$rootGetters["rancher/byId"](o.k$.NODE,this.normanNodeId)}get managementNode(){return this.$rootGetters["management/all"](o.Mc.NODE).find(e=>e.id.startsWith(this.clusterId)&&e.status.nodeName===this.id)}drain(e){this.$dispatch("promptModal",{component:"DrainNode",componentProps:{kubeNodes:e||[this],normanNodeId:this.normanNodeId}})}async stopDrain(e){const t=Array.isArray(e)?e:[this];await Promise.all(t.map(e=>e.norman?.doAction("stopDrain")))}get state(){return this.drainedState?this.drainedState:this.isCordoned?"cordoned":this.metadata?.state?.name||"unknown"}get details(){const e=[{label:this.t("node.detail.detailTop.version"),content:this.version},{label:this.t("node.detail.detailTop.os"),content:this.status.nodeInfo.osImage},{label:this.t("node.detail.detailTop.containerRuntime"),formatter:"IconText",formatterOpts:{iconClass:this.containerRuntimeIcon},content:this.containerRuntimeVersion}];return this.internalIp&&e.unshift({label:this.t("node.detail.detailTop.internalIP"),formatter:"CopyToClipboard",content:this.internalIp}),this.externalIp&&e.unshift({label:this.t("node.detail.detailTop.externalIP"),formatter:"CopyToClipboard",content:this.externalIp}),e}get glance(){const e=[...this._glance],t=e.findIndex(e=>"namespace"===e.name);t>-1&&e.splice(t,1);const n=[h("externalIp",this.t("component.resource.detail.glance.externalIp"),this.externalIp),h("internalIp",this.t("component.resource.detail.glance.internalIp"),this.internalIp),{name:"version",label:this.t("component.resource.detail.glance.version"),content:this.version||"—"},{name:"os",label:this.t("component.resource.detail.glance.os"),content:this.status?.nodeInfo?.osImage||"—"}],r=e.findIndex(e=>"age"===e.name);return e.splice(r>-1?r:e.length,0,...n),e}get glanceUsage(){return[{name:"cpu",label:this.t("component.resource.detail.glance.cpu"),percentage:p(this.cpuUsagePercentage)},{name:"memory",label:this.t("component.resource.detail.glance.memory"),percentage:p(this.ramUsagePercentage)},{name:"pods",label:this.t("component.resource.detail.glance.pods"),percentage:p(this.glancePodConsumedUsage)}]}get glancePodConsumedUsage(){if(this.hasAllPods)return this.podConsumedUsage;const e=this.$rootGetters["cluster/getSavedCount"](this.runningPodsCountName);return void 0===e?void 0:(e/this.podCapacity*100).toString()}get hasAllPods(){return!this.$rootGetters["cluster/paginationEnabled"](o.Sm)&&!!this.$rootGetters["cluster/haveAll"](o.Sm)}get runningPodsCountName(){return`${u}/${this.$rootGetters["clusterId"]}/${this.id}`}async fetchGlanceResources(e){const t=[];this.$rootGetters["cluster/schemaFor"](o.$v.NODE)&&t.push(this.$dispatch("cluster/find",{type:o.$v.NODE,id:this.id,opt:{force:!0,watch:!1,signal:e}},{root:!0})),this.$rootGetters["cluster/schemaFor"](o.Sm)&&t.push(this.fetchRunningPods(e));const n=(await Promise.allSettled(t)).find(e=>"rejected"===e.status);if(n)throw n.reason}async fetchRunningPods(e){if(!this.hasAllPods)try{if(this.$rootGetters["cluster/paginationEnabled"](o.Sm))return void await this.$dispatch("cluster/findPage",{type:o.Sm,opt:{transient:!0,saveCountAs:this.runningPodsCountName,signal:e,pagination:new c.gR({page:1,pageSize:1,filters:[c.eY.createSingleField({field:"spec.nodeName",value:this.id}),c.eY.createSingleField({field:"metadata.state.name",value:"running"})]})}},{root:!0});const t=this.$rootGetters["cluster/urlFor"](o.Sm),n=`${t}${t.includes("?")?"&":"?"}filter=spec.nodeName=${encodeURIComponent(this.name)}`,r=await this.$dispatch("cluster/request",{url:n,signal:e},{root:!0}),i=(r?.data||[]).filter(e=>e.spec?.nodeName===this.name&&"running"===e.metadata?.state?.name);this.saveRunningPodsCount(i.length)}catch(t){throw e?.aborted||this.saveRunningPodsCount(void 0),t}}saveRunningPodsCount(e){this.$ctx.commit("cluster/setSavedCount",{name:this.runningPodsCountName,count:e},{root:!0})}get pods(){const e=this.$rootGetters["cluster/all"](o.Sm);return e.filter(e=>e.spec.nodeName===this.name)}get confirmRemove(){return!0}get canClone(){return!1}get canDelete(){const e=["aks","azureaks","azurekubernetesservice","eks","amazoneks","gke","googlegke"];return!e.includes(this.provider)}get provisionedMachine(){const e=this.metadata?.annotations?.[i.qt.CLUSTER_NAMESPACE],t=this.metadata?.annotations?.[i.qt.MACHINE_NAME];return e&&t?this.$rootGetters["management/byId"](o.Z7.MACHINE,`${e}/${t}`):null}get isFromNorman(){return"norman"===(this.$rootGetters["currentCluster"].metadata.labels||{})["cattle.io/creator"]}get provider(){return this.$rootGetters["currentCluster"].provisioner.toLowerCase()}get displayTaintsAndLabels(){return!!this.spec.taints?.length||!!this.customLabelCount}}function h(e,t,n){return{name:e,label:t,formatter:n?"CopyToClipboard":void 0,content:n||"—"}}function p(e){const t=Number.parseFloat(e);return Number.isFinite(t)&&t>0?t:void 0}function f(e,t){const n=Number.parseFloat(t),i=Number.parseFloat(e),o=(n-i)/n*100;return(0,r.l9)(o)}function m(e,t,n,r){const i=[];return e&&i.push("Control Plane"),t&&i.push("Worker"),n&&i.push("Etcd"),3===i.length||0===i.length?r:i.join(", ")}},62973:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(45858);class i extends r["default"]{}},40408:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(35664),i=n(89865);class o extends i.A{get principalId(){return this.userPrincipalId||this.groupPrincipalId}get roleDisplay(){return this.roleTemplate.nameDisplay}get roleDescription(){return this.roleTemplate.description}get roleTemplate(){return this.$rootGetters["management/byId"](r.Mc.ROLE_TEMPLATE,this.roleTemplateId)}get clusterroletemplatebinding(){return this.$rootGetters["management/byId"](r.Mc.CLUSTER_ROLE_TEMPLATE_BINDING,this.id?.replace(":","/"))}get steve(){return this.$dispatch("management/find",{type:r.Mc.CLUSTER_ROLE_TEMPLATE_BINDING,id:this.id?.replace(":","/")},{root:!0})}}},53622:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return m},fetchSpecsScheduledScanConfig:function(){return p},hasSpecsScheduledScanConfig:function(){return f}});var r=n(90598),i=n(35664),o=n(68851),a=n(6198),s=n(76978),l=n(74302),c=n(23464),u=n.n(c),d=n(39975),h=n(4364);const p=async e=>(await e.fetchResourceFields(),f(e)),f=e=>{const t=(0,s.Jt)(e,"resourceFields.spec.type"),n=e.schemaDefinitions?.[t];return!!n&&!!(0,s.Jt)(n,"resourceFields.scheduledScanConfig")};class m extends d.A{get _availableActions(){let e=super._availableActions;const t=["cloneYaml","goToEditYaml","download"];e=e.filter(e=>{if(!t.includes(e.action))return e});const n=this.$rootGetters["i18n/t"],r={action:"downloadLatestReport",enabled:this.hasReport,icon:"icon icon-download",label:n("compliance.downloadReport"),total:1},i={action:"downloadAllReports",enabled:this.hasReport,icon:"icon icon-download",label:n("compliance.downloadAllReports"),total:1},o={action:"downloadLatestReportXCCDF",enabled:this.hasReport,icon:"icon icon-download",label:n("compliance.downloadReportXCCDF"),total:1},a={action:"downloadAllReportsXCCDF",enabled:this.hasReport,icon:"icon icon-download",label:n("compliance.downloadAllReportsXCCDF"),total:1};return this.hasReports&&(e.unshift({divider:!0}),this.spec?.scheduledScanConfig?.cronSchedule&&(e.unshift(a),o.label=n("compliance.downloadLatestReportXCCDF")),e.unshift(o),this.spec?.scheduledScanConfig?.cronSchedule&&(e.unshift(i),r.label=n("compliance.downloadLatestReport")),e.unshift(r)),e}canBeScheduled(){return f(this.$getters["schemaFor"](this.type))}get isScheduled(){return!!(0,s.Jt)(this,"spec.scheduledScanConfig.cronSchedule")}get canUpdate(){return this.hasLink("update")&&this.isScheduled}get hasReports(){const{relationships:e=[]}=this.metadata,t=(0,o.jq)(e,"toType",i.YA.REPORT);return!!t}async getReports(){const e=await this.findOwned(),t=e.filter(e=>e.type===i.YA.REPORT)||[];return(0,l.Ul)(t,"metadata.creationTimestamp",!0)}async downloadLatestReport(){const e=await this.getReports()||[],t=(0,l.Ul)(e,"metadata.creationTimestamp",!0)[0],r=await n.e(829).then(n.t.bind(n,41880,23));try{const e=(t.aggregatedTests||[]).map(e=>(delete e.actual_value_per_node,e)),n=r.unparse(e);(0,a.PE)(`${g(t)}.csv`,n,"application/csv")}catch(i){this.$dispatch("growl/fromError",{title:this.t("compliance.scan.errorDownload"),err:i},{root:!0})}}async downloadAllReports(){const e={},t=await this.getReports()||[],r=await n.e(829).then(n.t.bind(n,41880,23));t.forEach(t=>{try{const n=(t.aggregatedTests||[]).map(e=>(delete e.actual_value_per_node,e)),i=r.unparse(n);e[`${g(t)}.csv`]=i}catch(n){this.$dispatch("growl/fromError",{title:this.t("compliance.scan.errorDownload"),err:n},{root:!0})}}),(0,s.Im)(e)||(0,a.jl)(e).then(e=>{(0,a.PE)(`${this.id}-reports`,e,"application/zip")})}async _resolveBenchmark(){const e=this.status?.lastRunScanProfileName;if(!e)return null;const t=await this.$dispatch("find",{type:i.YA.CLUSTER_SCAN_PROFILE,id:e}),n=t?.spec?.benchmarkVersion;return n?this.$dispatch("find",{type:i.YA.BENCHMARK,id:n}):null}async _resolveExportMetadata(e){const t=e?.spec?.customBenchmarkConfigMapName,r=e?.spec?.customBenchmarkConfigMapNamespace,i={metadata:{},decorations:{}};if(!t||!r)return i;try{const e=await this.$dispatch("find",{type:"configmap",id:`${r}/${t}`}),o=e?.data?.["metadata.yaml"];if(!o)return i;const a=await Promise.resolve().then(n.t.bind(n,20246,23)),s=a.load(o)||{},{checks:l={},...c}=s;return{metadata:c,decorations:l}}catch(o){return h.error("[_resolveExportMetadata] failed to fetch or parse benchmark ConfigMap:",o),i}}async downloadLatestReportXCCDF(){const e=await this.getReports()||[],t=(0,l.Ul)(e,"metadata.creationTimestamp",!0)[0];try{const e=await this._resolveBenchmark(),{metadata:r,decorations:i}=await this._resolveExportMetadata(e),{generateXCCDFPerNode:o}=await n.e(461).then(n.bind(n,71026)),l=t.parsedReport||{},c={report:l,benchmarkVersion:l.version||e?.spec?.benchmarkVersion||"",metadata:r,decorations:i},u={};if(Object.entries(l.nodes||{}).length){if(Object.entries(l.nodes||{}).forEach(([e,n])=>{(n||[]).forEach(n=>{const r=o({...c,hostname:n,role:e});u[`${g(t)}--${n}.xml`]=r})}),!(0,s.Im)(u)){const e=await(0,a.jl)(u);(0,a.PE)(`${g(t)}-per-node.zip`,e,"application/zip")}}else this.$dispatch("growl/fromError",{title:this.t("compliance.scan.errorNoParsedNodes")},{root:!0})}catch(r){this.$dispatch("growl/fromError",{title:this.t("compliance.scan.errorDownload"),err:r},{root:!0})}}async downloadAllReportsXCCDF(){const e={},t=await this.getReports()||[];try{const r=await this._resolveBenchmark(),{metadata:i,decorations:o}=await this._resolveExportMetadata(r),{generateXCCDFPerNode:l}=await n.e(461).then(n.bind(n,71026)),c=t.some(e=>Object.entries(e.parsedReport?.nodes||{}).length);c?(t.forEach(t=>{try{const n=t.parsedReport||{},a={report:n,benchmarkVersion:n.version||r?.spec?.benchmarkVersion||"",metadata:i,decorations:o},s=g(t);Object.entries(n.nodes||{}).forEach(([t,n])=>{(n||[]).forEach(n=>{const r=l({...a,hostname:n,role:t});e[`${s}/${n}.xml`]=r})})}catch(n){this.$dispatch("growl/fromError",{title:this.t("compliance.scan.errorDownload"),err:n},{root:!0})}}),(0,s.Im)(e)||(0,a.jl)(e).then(e=>{(0,a.PE)(`${this.id}-reports-xccdf-per-node.zip`,e,"application/zip")})):this.$dispatch("growl/fromError",{title:this.t("compliance.scan.errorNoParsedNodes")},{root:!0})}catch(r){this.$dispatch("growl/fromError",{title:this.t("compliance.scan.errorDownload"),err:r},{root:!0})}}get scanProfileLink(){return this.status?.lastRunScanProfileName?{name:"c-cluster-product-resource-id",params:{resource:i.YA.CLUSTER_SCAN_PROFILE,product:r.o_,id:this.status?.lastRunScanProfileName}}:{}}}const g=e=>{const{creationTimestamp:t}=e.metadata,n=u()(t).format("YYYY-MM-DD-HHmmss"),r=e.id.replace(/^scan-report-/,"");return`${r}--${n}`}},87923:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(35664),i=n(39975);class o extends i.A{warnDeletionMessage(e=[]){return this.$rootGetters["i18n/t"]("compliance.deleteBenchmarkWarning",{count:e.length})}get isDefault(){const{relationships:e=[]}=this.metadata;return!!e&&e.filter(e=>e.fromType===r.W8.APP).length>0}}},22513:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return a}});var r=n(39975),i=n(90598),o=n(35664);class a extends r.A{warnDeletionMessage(e=[]){return this.$rootGetters["i18n/t"]("compliance.deleteProfileWarning",{count:e.length})}get numberTestsSkipped(){const{skipTests:e=[]}=this.spec;return e?.length||0}get benchmarkVersionLink(){return this.spec?.benchmarkVersion?{name:"c-cluster-product-resource-id",params:{resource:o.YA.BENCHMARK,product:i.o_,id:this.spec?.benchmarkVersion}}:{}}}},98728:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(74302),i=n(39975);class o extends i.A{get aggregatedTests(){const e=this.parsedReport,t=e?.results,n=t?t.reduce((e,t)=>(t.checks&&e.push(...t.checks),e),[]):null,i=e=>(e||"").split(".").map(e=>+e+1e3).join("."),o=e=>{const t={other:7,notApplicable:6,skip:5,pass:4,warn:3,mixed:2,fail:1};return`${t[e]||t["other"]} ${e}`},a=n.slice().sort((e,t)=>{const n=(0,r.UD)(o(e.state),o(t.state)),a=(0,r.UD)(i(e.id),i(t.id));return n||a});return a}get nodes(){return this.parsedReport?this.parsedReport.nodes:{}}get parsedReport(){try{const e=this.spec?.reportJSON,t=JSON.parse(e);return t}catch(e){}return null}}},79925:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(39975);class i extends r.A{get keysDisplay(){const e=[...Object.keys(this.data||[]),...Object.keys(this.binaryData||[])];return e.length?e.join(", "):"(none)"}get fullDetailPageOverride(){return!0}}},40172:function(e,t,n){"use strict";n.r(t),n.d(t,{ENFORCEMENT_ACTION_VALUES:function(){return s},default:function(){return l}});var r=n(20246),i=n.n(r),o=n(39975),a=n(6198);const s={DENY:"deny",DRYRUN:"dryrun"};class l extends o.A{get _availableActions(){const e=super._availableActions,t=this.$rootGetters["i18n/t"],n={action:"downloadViolations",icon:"icon icon-download",label:t("gatekeeperConstraint.downloadViolations"),total:1};return e.unshift(n),e}async save(){let e,t;this.constraint?(e=await this.findLatestConstraint(),t=e?.metadata?.resourceVersion):e=await this.$dispatch("cluster/create",{type:`constraints.gatekeeper.sh.${this.kind.toLowerCase()}`},{root:!0}),e.spec=this.spec,e.metadata=this.metadata,t&&(e.metadata.resourceVersion=t),await e.save()}async downloadViolations(){const e=await n.e(829).then(n.t.bind(n,41880,23));try{const t=(this.violations||[]).map(e=>(delete e.resourceLink,delete e.constraintLink,e)),n=e.unparse(t);(0,a.PE)(`violations-${this.name}.csv`,n,"application/csv")}catch(t){this.$dispatch("growl/fromError",{title:"Error downloading file",err:t},{root:!0})}}cleanForNew(){this.$dispatch("cleanForNew",this),this.constraint&&delete this.constraint}saveYaml(e){const t=i().load(e);return Object.assign(this,t),this.save()}async remove(){const e=await this.findLatestConstraint();return e.remove()}findLatestConstraint(){return this.$dispatch("cluster/find",{type:this.constraint.type,id:this.constraint.id,opt:{force:!0}},{root:!0})}get totalViolations(){return this.status?.totalViolations||this.violations.length}get violations(){const e=this.status?.violations||[];return e.map(e=>({...e,resourceLink:{text:e.name,to:{name:"c-cluster-product-resource-id",params:{resource:e.kind.toLowerCase(),id:e.name,product:"explorer"}}},constraintLink:{text:this.nameDisplay,to:this.detailLocation}}))}}},81147:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return l}});var r=n(2841),i=n(89865),o=n(44660),a=n(56005),s=n.n(a);class l extends i.A{get canViewYaml(){return!1}get driverName(){if(!this.builtIn){const e=this.status?.displayName?.toLowerCase();if(e)return o.KONTAINER_TO_DRIVER[e]||e}return o.KONTAINER_TO_DRIVER[this.id]||this.name||this.id}get nameDisplay(){const e=`cluster.provider.${this.driverName}`,t=s()(this.driverName);return this.$rootGetters["i18n/withFallback"](e,t)}get description(){return this.builtIn||this.builtin?this.$rootGetters["i18n/withFallback"]("tableHeaders.builtIn"):this.url}set description(e){this.annotations&&(this.annotations[r.tC]=e),this._description=e}cleanForSave(e,t){const n=super.cleanForSave(e,t);return t&&(n.active=!0),delete n.metadata,n}}},28473:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return s}});var r=n(3514),i=n.n(r),o=n(92043),a=n(39975);class s extends a.A{get displayInvolvedObject(){const e=this.involvedObject;return i()(e)?"N/A":`${e.kind} ${e.name}`}get displayMessage(){return(0,o.TF)(this.message)}get timestamp(){return this.lastTimestamp||this.metadata?.creationTimestamp}get eventType(){return this._type}get firstSeen(){const e=this.$getters["schemaFor"](this.type),t=this.$rootGetters["type-map/rowValueGetter"];return e&&t?t(e,"First Seen")(this):null}get lastSeen(){const e=this.$getters["schemaFor"](this.type),t=this.$rootGetters["type-map/rowValueGetter"];return e&&t?t(e,"Last Seen")(this):null}get insightsColor(){return"disabled"}}},42510:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(39975);class i extends r.A{get canRefreshMemberships(){return this.schema?.collectionMethods.find(e=>"post"===e.toLowerCase())}cleanForSave(e){const t=super.cleanForSave(e);return delete t.type,t}}},61607:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(39975);class i extends r.A{get canChangePassword(){return this.schema?.collectionMethods.find(e=>"post"===e.toLowerCase())}cleanForSave(e){const t=super.cleanForSave(e);return delete t.type,t}}},76448:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(39975);class i extends r.A{get canGetUser(){return this.schema?.collectionMethods.find(e=>"post"===e.toLowerCase())}cleanForSave(e){const t=super.cleanForSave(e);return delete t.type,t}}},91970:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return m}});var r=n(38823),i=n(3514),o=n.n(i),a=n(92043),s=n(35664),l=n(2841),c=n(68851),u=n(39975),d=n(73883),h=n(40530),p=n(95265);function f(e){if(o()(e))return{total:0,states:{}};const{desiredReady:t,...n}=e,r=Object.entries(n).reduce((e,[t,n])=>(e[(0,d.hb)(t)]=n,e),{});return{total:t,states:r}}class m extends u.A{get applicationType(){return this.kind}async getCurrentUser(){const e=this.$rootGetters["auth/user"];if(e?.id)return e;const t=await this.$dispatch("auth/getSelfUser");if(t?.canGetUser&&t.status?.userID){const e=await this.$dispatch("management/find",{type:s.Mc.USER,id:t.status?.userID},{root:!0});if(e)return this.$dispatch("auth/gotUser",e,{root:!0}),e}return{}}pause(){this.spec.paused=!0,this.save()}unpause(){this.spec.paused=!1,this.save()}goToClone(){this.metadata?.labels?.[l.Hs.CREATED_BY_USER_ID]&&delete this.metadata.labels[l.Hs.CREATED_BY_USER_ID],super.goToClone()}get state(){return!0===this.spec?.paused?"paused":this.metadata?.state?.name||"unknown"}get stateObj(){return h.A.resourceStateObj(this.metadata?.state)}get stateDescription(){const{error:e,transitioning:t,message:n}=this.metadata?.state||{};return e||t?(0,a.TF)(n):""}get targetClusters(){const e=this.$getters["byId"](s.Hs.WORKSPACE,this.metadata.namespace),t=[...e?.clusters||[]],n=[...e?.clusterGroups||[]];if("fleet-local"===e?.id){const e=(0,c.jq)(n,"id","fleet-local/default");return e?e.targetClusters:[]}if(!this.spec.targets)return[];const i=this.$getters["all"](s.Hs.BUNDLE_NAMESPACE_MAPPING)||[],o=this.metadata.namespace;for(const l of i)if(l.metadata?.namespace===o){if(l.bundleSelector){const e=(0,r._R)(l.bundleSelector);if(!(0,r.cK)(this,e))continue}if(l.namespaceSelector){const e=this.$getters["all"](s.Hs.WORKSPACE)||[],i=(0,r._R)(l.namespaceSelector);for(const a of e){if(a.metadata?.name===o)continue;const e={...a.metadata?.labels||{},"kubernetes.io/metadata.name":a.metadata?.name};(0,r.cK)({metadata:{labels:e}},i)&&((0,c.cn)(t,a.clusters||[]),(0,c.cn)(n,a.clusterGroups||[]))}}}const a=[];for(const s of this.spec.targets)if(s.clusterName){const e=(0,c.jq)(t,"metadata.name",s.clusterName)||(0,c.jq)(t,"nameDisplay",s.clusterName);e&&(0,c.PG)(a,e)}else if(s.clusterGroup){const e=(0,c.jq)(n,{"metadata.namespace":this.metadata.namespace,"metadata.name":s.clusterGroup});e&&(0,c.cn)(a,e.targetClusters)}else if(s.clusterGroupSelector){const e=(0,r._R)(s.clusterGroupSelector),t=(0,r.wC)(n,e);for(const n of t)(0,c.cn)(a,n.targetClusters)}else if(s.clusterSelector){const e=(0,r._R)(s.clusterSelector),n=(0,r.wC)(t,e);(0,c.cn)(a,n)}return a}get targetInfo(){const e=this.$rootGetters["features/get"](p.lc),t=h.A.Application.getTargetMode(this.spec.targets||[],this.metadata.namespace,e);return{mode:t,modeDisplay:this.t(`fleet.gitRepo.targetDisplay."${t}"`)}}get groupByLabel(){const e=this.metadata.namespace;return e?this.$rootGetters["i18n/t"]("resourceTable.groupLabel.workspace",{name:(0,a.ZD)(e)}):this.$rootGetters["i18n/t"]("resourceTable.groupLabel.notInAWorkspace")}get allResourceStatuses(){return f(this.status?.resourceCounts||{})}statusResourceCountsForCluster(e){return(this.targetClusters||[]).some(t=>t.id===e)?this.status?.perClusterResourceCounts?.[e]||{desiredReady:0}:{}}get resourcesStatuses(){if(o()(this.status?.resources))return[];const e=(this.targetClusters||[]).reduce((e,t)=>(e[t.id]=t,e),{}),t=this.status?.resources?.reduce((t,n)=>{const{perClusterState:r,...i}=n;return 0===Object.entries(r).length?(this.targetClusters||[]).forEach(e=>{t.push(Object.assign({},i,{clusterId:e.id,state:i.state}))}):Object.entries(r).forEach(([n,r])=>{r.filter(t=>!!e[t]).forEach(e=>{t.push(Object.assign({},i,{clusterId:e,state:n}))})}),t},[]);return t.map(t=>{const{namespace:n,name:r,clusterId:i}=t,o=h.A.resourceType(t),a=e[i];return{key:`${i}-${o}-${n}-${r}`,id:h.A.resourceId(t),type:o,clusterId:i,state:(0,d.hb)(t.state),clusterName:a.nameDisplay,apiVersion:t.apiVersion,kind:t.kind,name:r,namespace:n,detailLocation:h.A.detailLocation(t,a.metadata.labels[l.Hs.CLUSTER_NAME])}})}get clusterInfo(){const e=this.status?.readyClusters||0,t=this.status?.desiredReadyClusters||0;return{ready:e,unready:t-e,total:t}}clusterState(e){const t=this.statusResourceCountsForCluster(e);return(0,d.aB)(t)||d.jv.ACTIVE}get clustersList(){return this.$getters["all"](s.Hs.CLUSTER)}get readyClusters(){return this.status?.readyClusters||0}get meta(){return this.currentRoute()?.meta||{}}get _detailLocation(){return{...super._detailLocation,name:this.meta.detailLocation||super._detailLocation.name}}get doneOverride(){return{...super.listLocation,name:this.meta.doneOverride||super.listLocation.name}}get doneRoute(){return this.doneOverride?.name}get parentNameOverride(){return this.$rootGetters["i18n/t"](`typeLabel."${s.Hs.APPLICATION}"`,{count:1})?.trim()}}},5096:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return u}});var r=n(92043),i=n(39975),o=n(68851),a=n(35664),s=n(2841),l=n(38823),c=n(40530);class u extends i.A{get lastUpdateTime(){return this.status?.conditions?.[0].lastUpdateTime}get repoName(){const e=this.metadata?.labels||{};return e[s.Hs.REPO_NAME]}get helmName(){const e=this.metadata?.labels||{};return e[s.Hs.HELM_NAME]}get appSourceName(){return this.helmName||this.repoName}get targetClusters(){const e=this.$getters["byId"](a.Hs.WORKSPACE,this.metadata.namespace),t=[...e?.clusters||[]],n=[...e?.clusterGroups||[]],r=[];if("fleet-local"===e.id){const e=(0,o.jq)(n,"id","fleet-local/default");return e?e.targetClusters:[]}const i=this.$getters["all"](a.Hs.BUNDLE_NAMESPACE_MAPPING)||[],s=this.metadata.namespace;for(const c of i)if(c.metadata?.namespace===s){if(c.bundleSelector){const e=(0,l._R)(c.bundleSelector);if(!(0,l.cK)(this,e))continue}if(c.namespaceSelector){const e=this.$getters["all"](a.Hs.WORKSPACE)||[],r=(0,l._R)(c.namespaceSelector);for(const i of e){if(i.metadata?.name===s)continue;const e={...i.metadata?.labels||{},"kubernetes.io/metadata.name":i.metadata?.name};(0,l.cK)({metadata:{labels:e}},r)&&((0,o.cn)(t,i.clusters||[]),(0,o.cn)(n,i.clusterGroups||[]))}}}for(const a of this.spec.targets)if(a.clusterName){const e=(0,o.jq)(t,"metadata.name",a.clusterName)||(0,o.jq)(t,"nameDisplay",a.clusterName);e&&(0,o.PG)(r,e)}else if(a.clusterGroup){const e=(0,o.jq)(n,{"metadata.namespace":this.metadata.namespace,"metadata.name":a.clusterGroup});e&&(0,o.cn)(r,e.targetClusters)}else if(a.clusterGroupSelector){const e=(0,l._R)(a.clusterGroupSelector),t=(0,l.wC)(n,e);for(const n of t)(0,o.cn)(r,n.targetClusters)}else if(a.clusterSelector){const e=(0,l._R)(a.clusterSelector),n=(0,l.wC)(t,e);(0,o.cn)(r,n)}return r}get readyCondition(){return this.status?.conditions?.find(e=>"Ready"===e.type)}get stateObj(){return c.A.resourceStateObj(this.metadata?.state)||{}}get stateDescription(){const{status:e,message:t}=this.readyCondition||{};return"True"!==e&&t?(0,r.TF)(t):""}get groupByLabel(){const e=this.metadata.namespace;return e?this.$rootGetters["i18n/t"]("resourceTable.groupLabel.workspace",{name:(0,r.ZD)(e)}):this.$rootGetters["i18n/t"]("resourceTable.groupLabel.notInAWorkspace")}}},5904:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return h}});var r=n(35664),i=n(2841),o=n(41476),a=n(39975),s=n(92043),l=n(68851),c=n(20246),u=n.n(c),d=n(95265);class h extends a.A{get _availableActions(){const e=super._availableActions;return(0,l.PT)(e,0,{action:"pause",label:"Pause",icon:"icon icon-pause",bulkable:!0,enabled:!!this.links.update&&!this.spec?.paused}),(0,l.PT)(e,1,{action:"unpause",label:"Unpause",icon:"icon icon-play",bulkable:!0,enabled:!!this.links.update&&!0===this.spec?.paused}),(0,l.PT)(e,2,{action:"forceUpdate",label:"Force Update",icon:"icon icon-refresh",bulkable:!0,enabled:!!this.links.update}),this.canChangeWorkspace&&(0,l.PT)(e,3,{action:"assignTo",label:"Change workspace",icon:"icon icon-copy",bulkable:!0,bulkAction:"assignToBulk",enabled:!!this.links.update&&!!this.mgmt}),(0,l.PT)(e,4,{divider:!0}),e}pause(){this.spec.paused=!0,this.save()}unpause(){this.spec.paused=!1,this.save()}forceUpdate(){const e=this.spec.redeployAgentGeneration||1;this.spec.redeployAgentGeneration=e+1,this.save()}assignTo(){this.$dispatch("promptModal",{component:"AssignToDialog",componentProps:{toAssign:[this]}})}assignToBulk(e){this.$dispatch("promptModal",{component:"AssignToDialog",componentProps:{toAssign:e}})}get canDelete(){return!1}get canChangeWorkspace(){return!this.isLocal&&(!this.isRke2||this.$rootGetters["features/get"](d.N8))}get isLocal(){return this.metadata.name===r.d_||this.metadata?.labels?.[i.Hs.CLUSTER_NAME]===r.d_}get isRke2(){const e=this?.metadata?.labels?.[i.qt.PROVIDER]||this?.status?.provider;return e===o.gM}get nameDisplay(){return this.metadata?.labels?.[i.Hs.CLUSTER_DISPLAY_NAME]||this.metadata?.name||this.id}get name(){return this.metadata?.name||this.metadata?.labels?.[i.Hs.CLUSTER_NAME]}get state(){return!0===this.spec?.paused?"paused":this.metadata?.state?.name||"unknown"}get repoInfo(){const e=this.status?.readyGitRepos||0,t=this.status?.desiredReadyGitRepos||0;return{ready:e,unready:t-e,total:t}}get helmOpsInfo(){const e=this.status?.readyHelmOps||0,t=this.status?.desiredReadyHelmOps||0;return{ready:e,unready:t-e,total:t}}get bundleInfo(){const e={ready:0,total:0},t=this.status?.display?.readyBundles;if(t&&t.includes("/")){const n=t.split("/");if(2===n.length&&parseInt(n[0])>=0&&parseInt(n[1])>=0)return e.ready=parseInt(n[0]),e.total=parseInt(n[1]),e}return e.noValidData=!0,e}get mgmt(){const e=this.$getters["byId"](r.Mc.CLUSTER,this.metadata?.labels?.[i.Hs.CLUSTER_NAME]);return e}get basicNorman(){const e=this.$rootGetters["rancher/byId"](r.k$.CLUSTER,this.metadata?.labels?.[i.Hs.CLUSTER_NAME]);return e}get norman(){return this.basicNorman?this.basicNorman:this.$dispatch("rancher/find",{type:r.k$.CLUSTER,id:this.metadata.labels[i.Hs.CLUSTER_NAME]},{root:!0})}async normanClone(){const e=await this.norman;return this.$dispatch("rancher/clone",{resource:e},{root:!0})}get groupByLabel(){const e=this.metadata.namespace;return e?this.$rootGetters["i18n/t"]("resourceTable.groupLabel.workspace",{name:(0,s.ZD)(e)}):this.$rootGetters["i18n/t"]("resourceTable.groupLabel.notInAWorkspace")}get customLabels(){const e=[];if(this.labels)for(const t in this.labels){const[n]=t.split("/");i.uf.includes(n)||t===i.qt.PROVIDER||e.push(`${t}=${this.labels[t]}`)}return e}async saveYaml(e,t){await this._saveYaml(e,t);const n=u().load(e),r=await this.normanClone();r.setLabels(n.metadata.labels),r.setAnnotations(n.metadata.annotations),await r.save()}}},11173:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return l}});var r=n(92043),i=n(38823),o=n(35664),a=n(76978),s=n(39975);class l extends s.A{applyDefaults(){const e=this.spec||{};e.selector=e.selector||{},e.selector.matchExpressions=e.selector.matchExpressions||[],(0,a.hZ)(this,"spec",e)}get targetClusters(){const e=this.$getters["byId"](o.Hs.WORKSPACE,this.metadata.namespace),t=(0,i.C6)(this.spec?.selector?.matchLabels||{},this.spec?.selector?.matchExpressions||[]);if(!t.length)return e.clusters;const n=(0,i.wC)(e.clusters,t);return n}get groupByLabel(){const e=this.metadata.namespace;return e?this.$rootGetters["i18n/t"]("resourceTable.groupLabel.workspace",{name:(0,r.ZD)(e)}):this.$rootGetters["i18n/t"]("resourceTable.groupLabel.notInAWorkspace")}get clusterInfo(){const e=this.status?.clusterCount||0,t=this.status?.nonReadyClusterCount||0,n=e-t;return{ready:n,unready:t,total:e}}get details(){const e=[{label:"Clusters Ready",content:`${this.clusterInfo.ready} of ${this.clusterInfo.total}`}];return e}}},67424:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(92043),i=n(39975);class o extends i.A{get groupByLabel(){const e=this.metadata.namespace;return e?this.$rootGetters["i18n/t"]("resourceTable.groupLabel.workspace",{name:(0,r.ZD)(e)}):this.$rootGetters["i18n/t"]("resourceTable.groupLabel.notInAWorkspace")}}},84402:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return c}});var r=n(76978),i=n(68851),o=n(35664),a=n(2841),s=n(91970),l=n(40530);class c extends s["default"]{applyDefaults(){const e=this.spec||{},t=this.metadata||{};t.namespace=t.namespace||this.$rootGetters["workspace"],e.repo=e.repo||"",e.branch||e.revision||(e.branch="master"),e.paths=e.paths||[],e.clientSecretName=e.clientSecretName||null,e["correctDrift"]=e.correctDrift||{enabled:!1},(0,r.hZ)(this,"spec",e),(0,r.hZ)(this,"metadata",t)}get _availableActions(){const e=super._availableActions;return(0,i.PT)(e,0,{action:"pause",label:this.t("fleet.gitRepo.actions.pause.label"),icon:"icon icon-pause",bulkable:!0,enabled:!!this.links.update&&!this.spec?.paused}),(0,i.PT)(e,1,{action:"unpause",label:this.t("fleet.gitRepo.actions.unpause.label"),icon:"icon icon-play",bulkable:!0,enabled:!!this.links.update&&!0===this.spec?.paused}),(0,i.PT)(e,2,{action:"enablePollingAction",label:this.t("fleet.gitRepo.actions.enablePolling.label"),icon:"icon icon-endpoints_connected",bulkable:!0,enabled:!!this.links.update&&!!this.spec?.disablePolling}),(0,i.PT)(e,3,{action:"disablePollingAction",label:this.t("fleet.gitRepo.actions.disablePolling.label"),icon:"icon icon-endpoints_disconnected",bulkable:!0,enabled:!!this.links.update&&!this.spec?.disablePolling}),(0,i.PT)(e,4,{action:"forceUpdate",label:this.t("fleet.gitRepo.actions.forceUpdate.label"),icon:"icon icon-refresh",bulkable:!0,bulkAction:"forceUpdateBulk",enabled:!!this.links.update}),(0,i.PT)(e,5,{divider:!0}),e}enablePollingAction(){this.spec.disablePolling=!1,this.save()}disablePollingAction(){this.spec.disablePolling=!0,this.save()}forceUpdate(e=[this]){this.$dispatch("promptModal",{componentProps:{repositories:e},component:"GitRepoForceUpdateDialog"})}forceUpdateBulk(e){this.$dispatch("promptModal",{componentProps:{repositories:e},component:"GitRepoForceUpdateDialog"})}get isPollingEnabled(){return!this.spec.disablePolling}get isWebhookConfigured(){return!!this.status?.webhookCommit}get github(){const e=this.spec.repo||"",t=e.match(l.A.GIT_HTTPS_REGEX);if(t)return t[1];const n=e.match(l.A.GIT_SSH_REGEX);return!!n&&l.A.parseSSHUrl(n[0]).repoPath}get dashboardIcon(){return l.A.dashboardIcons[o.Hs.GIT_REPO]}get resourceIcon(){return this.github?"icon icon-github":l.A.resourceIcons[o.Hs.GIT_REPO]}get repoDisplay(){let e=this.spec.repo||"";return e?this.github?this.github:(e=e.replace(/.git$/,""),e=e.replace(/^https:\/\//,""),e=e.replace(/\/+$/,""),e):null}get commitDisplay(){const e=this.spec,t=this.status?.commit?.substr(0,7);return e&&e.repo?e.revision&&l.A.quacksLikeAHash(e.revision)?e.revision.substr(0,7):e.revision?e.revision:e.branch?e.branch+(t?` @ ${t}`:""):t:null}get bundles(){return this.$getters["matching"](o.Hs.BUNDLE,{[a.Hs.REPO_NAME]:this.name},this.namespace)}get bundleDeployments(){return this.$getters["matching"](o.Hs.BUNDLE_DEPLOYMENT,{[a.Hs.REPO_NAME]:this.name})}get source(){let e=this.spec.repo||"";const t=e.match(l.A.GIT_HTTPS_REGEX),n=e.match(l.A.GIT_SSH_REGEX);if(n){const{sshUserAndHost:t,repoPath:r}=l.A.parseSSHUrl(n[0]);e=`https://${t.replace("git@","")}/${r}`}return{value:e,display:this.repoDisplay,icon:this.resourceIcon,showLink:!(!t&&!n)}}get sourceSub(){return{value:this.status?.commit,display:this.commitDisplay}}get fullDetailPageOverride(){return!0}}},80591:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return h}});var r=n(50667),i=n(68851),o=n(76978),a=n(2665),s=n(40530),l=n(35664),c=n(2841),u=n(91970),d=n(39618);class h extends u["default"]{get isSuseAppCollectionFromUI(){return!!this.metadata?.annotations?.[c.W8.SUSE_APP_COLLECTION]}get isSuseAppCollection(){return this.isSuseAppCollectionFromUI||(this.spec?.helm?.repo||"").startsWith(d.nx)}get applicationType(){return this.isSuseAppCollectionFromUI?d.IL:this.kind}applyDefaults(){const e=this.spec||{},t=this.metadata||{};t.namespace=t.namespace||this.$rootGetters["workspace"],e.helm=e.helm||{},e["correctDrift"]=e.correctDrift||{enabled:!1},(0,o.hZ)(this,"spec",e),(0,o.hZ)(this,"metadata",t)}get _availableActions(){const e=super._availableActions;return(0,i.PT)(e,0,{action:"pause",label:this.t("fleet.helmOp.actions.pause.label"),icon:"icon icon-pause",bulkable:!0,enabled:!!this.links.update&&!this.spec?.paused}),(0,i.PT)(e,1,{action:"unpause",label:this.t("fleet.helmOp.actions.unpause.label"),icon:"icon icon-play",bulkable:!0,enabled:!!this.links.update&&!0===this.spec?.paused}),(0,i.PT)(e,5,{divider:!0}),e}get dashboardIcon(){return s.A.dashboardIcons[l.Hs.HELM_OP]}get resourceIcon(){return s.A.resourceIcons[l.Hs.HELM_OP]}github(e){const t=e||"",n=t.match(s.A.GIT_HTTPS_REGEX);if(n)return n[1];const r=t.match(s.A.GIT_SSH_REGEX);return!!r&&s.A.parseSSHUrl(r[0]).repoPath}sourceDisplay(e){if(!e)return null;const t=this.github(e);return t||(e=e.replace(/.git$/,""),e=e.replace(/^https:\/\//,""),e=e.replace(/\/+$/,""),e)}get sourceType(){return this.spec.helm?.repo?.startsWith("oci://")?a.xO.OCI:this.spec.helm?.repo&&this.spec.helm?.chart?a.xO.REPO:this.spec.helm?.chart?a.xO.TARBALL:null}get source(){let e="";switch(this.sourceType){case a.xO.REPO:e=this.spec.helm?.repo||"";break;case a.xO.OCI:{const t=(0,r.qg)(this.spec.helm?.repo||"");e=t?.host?`oci://${t.host}`:"";break}case a.xO.TARBALL:e=this.spec.helm?.chart||""}const t=e.match(s.A.HTTP_REGEX),n=e.match(s.A.GIT_SSH_REGEX);if(n){const{sshUserAndHost:t,repoPath:r}=s.A.parseSSHUrl(n[0]);e=`https://${t.replace("git@","")}/${r}`}return{value:e,display:this.sourceDisplay(e),icon:"icon icon-application",showLink:!(!t&&!n)}}get sourceSub(){const e=this.spec.helm?.version||"",t=this.status?.version||"";let n=e||t||"";e&&t&&e!==t&&(n=`${e} -> ${t}`);let i="";switch(this.sourceType){case a.xO.REPO:i=this.spec.helm.chart||"";break;case a.xO.OCI:{const e=(0,r.qg)(this.spec.helm.repo||"");i=e?.path?e?.path.substring(1):"";break}}let o=i||n||"";return i&&n&&(o=`${i} : ${n}`),{value:o,display:o}}get bundles(){return this.$getters["matching"](l.Hs.BUNDLE,{[c.Hs.HELM_NAME]:this.name},this.namespace)}get bundleDeployments(){return this.$getters["matching"](l.Hs.BUNDLE_DEPLOYMENT,{[c.Hs.HELM_NAME]:this.name})}get fullDetailPageOverride(){return!0}}},99611:function(e,t,n){"use strict";n.r(t),n.d(t,{GATEWAY_GROUP:function(){return i},default:function(){return s},schemeForListener:function(){return a}});var r=n(39975);const i="gateway.networking.k8s.io",o={HTTP:"http",HTTPS:"https"};function a(e){const t=e?.protocol;return Object.hasOwn(o,t)?o[t]:void 0}class s extends r.A{get addresses(){return(this.status?.addresses||[]).map(e=>e.value).filter(e=>!!e)}get listeners(){return this.spec?.listeners||[]}allowsRoute(e,t,n){const r=e?.allowedRoutes,o=r?.kinds;return!(o?.length&&!o.some(e=>e?.kind===n&&(e?.group??i)===i))&&("Same"!==(r?.namespaces?.from??"Same")||t===this.metadata?.namespace)}listenersFor(e,t,n="HTTPRoute"){const{sectionName:r,port:i}=e||{};return this.listeners.filter(e=>!!a(e)&&((!r||e.name===r)&&((!i||e.port===i)&&this.allowsRoute(e,t,n))))}}},87784:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return f}});var r=n(35664),i=n(68851),o=n(39975),a=n(99611);const s={http:80,https:443},l=["Exact","PathPrefix"],c=e=>!!e?.startsWith("*.");function u(e,t){return e.endsWith(t.slice(1))}function d(e,t){const n=e?.toLowerCase(),r=t?.toLowerCase();return r&&n!==r?c(r)&&!c(n)&&u(n,r)?n:c(n)&&!c(r)&&u(r,n)?r:void 0:n}const h=e=>e.includes(":")?`[${e}]`:e,p=e=>(e?.group??a.GATEWAY_GROUP)===a.GATEWAY_GROUP&&"Gateway"===(e?.kind??"Gateway");class f extends o.A{get rules(){return this.spec?.rules||[]}get hostnamesDisplay(){return(this.spec?.hostnames||[]).join(", ")}get parentRefsDisplay(){return(this.spec?.parentRefs||[]).filter(p).map(e=>{const t=e.namespace;return t&&t!==this.metadata?.namespace?`${t}/${e.name}`:e.name}).join(", ")}backendRefTargets(e,t){if(!e||!t)return!1;const n=e.group??"",r=e.kind??"Service",i=e.namespace??this.metadata?.namespace;return""===n&&"Service"===r&&e.name===t.metadata?.name&&i===t.metadata?.namespace}rulesForServices(e=[]){return e.length?this.rules.filter(t=>(t?.backendRefs||[]).some(t=>e.some(e=>this.backendRefTargets(t,e)))):[]}targetsAnyService(e=[]){return this.rulesForServices(e).length>0}pathsForRule(e){const t=(e?.matches||[]).map(e=>e?.path??{type:"PathPrefix",value:"/"});return t.length?(0,i.sb)(t.filter(e=>l.includes(e.type??"PathPrefix")).map(e=>e.value||"/")):["/"]}get parentGateways(){if(!this.$rootGetters["cluster/schemaFor"](r.Yq.GATEWAY))return[];const e=(this.spec?.parentRefs||[]).filter(p);if(!e.length)return[];const t=this.$rootGetters["cluster/all"](r.Yq.GATEWAY)||[];return e.reduce((e,n)=>{const r=n.namespace??this.metadata?.namespace,i=t.find(e=>e.metadata?.name===n.name&&e.metadata?.namespace===r);return i&&e.push({parentRef:n,gateway:i}),e},[])}hostsFor(e,t){const n=this.spec?.hostnames||[],r=t?.hostname;return n.length?(0,i.sb)(n.map(e=>d(e,r)).filter(e=>e&&!c(e))):r?c(r)?[]:[r]:e?.addresses||[]}endpointsForServices(e=[]){const t=this.rulesForServices(e);if(!t.length)return[];const n=(0,i.sb)(t.flatMap(e=>this.pathsForRule(e)));if(!n.length)return[];const r=this.parentGateways.flatMap(({parentRef:e,gateway:t})=>t.listenersFor(e,this.metadata?.namespace).flatMap(e=>{const r=(0,a.schemeForListener)(e),i=e.port&&e.port!==s[r]?`:${e.port}`:"";return this.hostsFor(t,e).flatMap(e=>n.map(t=>`${r}://${h(e)}${i}${t}`))}));return(0,i.sb)(r).map(e=>({link:e,linkDisplay:e}))}}},97030:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return a}});var r=n(35664),i=n(76978),o=n(97219);class a extends o["default"]{get canViewInApi(){return!1}get nameDisplay(){return this.principalNameDisplay}get principalNameDisplay(){const e=this.$rootGetters["rancher/byId"](r.k$.PRINCIPAL,this.id);return`${e.name} (${e.displayType})`}get detailLocation(){const e=(0,i.o8)(this._detailLocation);return e.params.id=this.id,e}get globalRoleBindings(){return this.$rootGetters["management/all"](r.Mc.GLOBAL_ROLE_BINDING).filter(e=>this.id===e.groupPrincipalName)}get _availableActions(){return[{action:"goToEdit",label:this.t("action.edit"),icon:"icon icon-edit",enabled:!0},{action:"promptUnassignGroupRoles",altAction:"unassignGroupRoles",label:this.t("action.unassign"),icon:"icon icon-trash",bulkable:!0,enabled:!!this.globalRoleBindings.length,bulkAction:"unassignGroupRoles"}]}promptUnassignGroupRoles(e=this){const t=Array.isArray(e)?e:[e],n=this.$rootGetters["management/all"](r.Mc.GLOBAL_ROLE_BINDING).filter(e=>t.find(t=>t.id===e.groupPrincipalName));this.$dispatch("promptRemove",n)}async unassignGroupRoles(e=this){const t=Array.isArray(e)?e:[e],n=this.$rootGetters["management/all"](r.Mc.GLOBAL_ROLE_BINDING).filter(e=>t.find(t=>t.id===e.groupPrincipalName));await Promise.all(n.map(e=>e.remove())),this.$dispatch("promptRemove",null)}}},7899:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(39975),i=n(35664);class o extends r.A{applyDefaults(){this.spec||(this["spec"]={helmApiVersion:"monitoring.cattle.io/v1alpha1"},this["metadata"]={name:"project-monitoring"})}get projectId(){const e=this.$rootGetters["currentProduct"].inStore,t=this.$rootGetters[`${e}/all`](i.CU),{projectId:n}=t.find(e=>e.id===this.metadata.namespace);return n}get projectDisplayName(){const e=this.$rootGetters["currentCluster"]?.id,t=this.$rootGetters["management/byId"](i.Mc.PROJECT,`${e}/${this.projectId}`);return t?.spec.displayName}get namespaces(){const e=this.$rootGetters["currentProduct"].inStore,t=this.$rootGetters[`${e}/all`](i.CU),n=t.filter(e=>e.projectId===this.projectId);return[...n]}get parentNameOverride(){return this.$rootGetters["i18n/t"](`typeLabel."${i.fj.PROJECTHELMCHART}"`,{count:1})?.trim()}}},72183:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(39975),i=n(2841);class o extends r.A{applyDefaults(){const e=this.spec||{config:JSON.stringify({cniVersion:"0.3.1",name:"",type:"bridge",bridge:"",promiscMode:!0,vlan:"",ipam:{}})};this["spec"]=e}get parseConfig(){try{return JSON.parse(this.spec.config)||{}}catch(e){return{}}}get isIpamStatic(){return"static"===this.parseConfig.ipam?.type}get clusterNetwork(){return this?.metadata?.labels?.[i.rk.CLUSTER_NETWORK]}get vlanType(){const e=this.metadata?.labels||{},t=e[i.rk.NETWORK_TYPE];return t}get vlanId(){return"UntaggedNetwork"===this.vlanType?"N/A":this.parseConfig.vlan}get customValidationRules(){const e=[{nullable:!1,path:"metadata.name",required:!0,minLength:1,maxLength:63,translationKey:"harvester.fields.name"}];return e}get connectivity(){const e=this.metadata?.annotations||{},t=e[i.rk.NETWORK_ROUTE];let n={};if("UntaggedNetwork"===this.vlanType)return"N/A";try{n=JSON.parse(t||"{}")}catch{return"invalid"}const r=n.connectivity;return"false"===r?"inactive":"true"===r?"active":r}}},83448:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(81147);class i extends r["default"]{get doneRoute(){return"c-cluster-manager-driver-kontainerdriver"}get parentLocationOverride(){return{name:"c-cluster-manager-driver-kontainerdriver",params:{cluster:this.$rootGetters["clusterId"]}}}get _availableActions(){const e=[{action:"activate",label:this.t("action.activate"),icon:"icon icon-play",bulkable:!0,bulkAction:"activateBulk",enabled:!!this.links.update&&!this.active},{action:"deactivate",label:this.t("action.deactivate"),icon:"icon icon-pause",bulkable:!0,bulkAction:"deactivateBulk",enabled:!!this.links.update&&!!this.active,weight:-1},{divider:!0},{action:"viewInApi",enabled:!0,icon:"icon icon-external-link",label:this.t("action.viewInApi")},{divider:!0},{action:"goToEdit",label:this.t("action.edit"),icon:"icon icon-edit",bulkable:!1,enabled:!!this.links.update&&!this.builtin},{action:"promptRemove",altAction:"remove",bulkAction:"promptRemove",label:this.t("action.remove"),bulkable:!0,icon:"icon icon-delete",enabled:!!this.links.remove,weight:-10}];return e}get isEmber(){return!this.builtIn&&!this.builtin}deactivate(e=[this]){this.$dispatch("promptModal",{componentProps:{drivers:e,driverType:"kontainerDrivers"},component:"DeactivateDriverDialog"})}deactivateBulk(e){this.$dispatch("promptModal",{componentProps:{drivers:e,driverType:"kontainerDrivers"},component:"DeactivateDriverDialog"})}activate(){return this.$dispatch("rancher/request",{url:`v3/kontainerDrivers/${encodeURIComponent(this.id)}?action=activate`,method:"post"},{root:!0}).catch(e=>{this.$dispatch("growl/fromError",{title:this.t("drivers.error.activate",{name:this.nameDisplay}),err:e},{root:!0})})}async activateBulk(e){await Promise.all(e.map(e=>this.$dispatch("rancher/request",{url:`v3/kontainerDrivers/${encodeURIComponent(e.id)}?action=activate`,method:"post"},{root:!0}).catch(t=>{this.$dispatch("growl/fromError",{title:this.t("drivers.error.activate",{name:e.nameDisplay}),err:t},{root:!0})})))}}},78694:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return s}});var r=n(35664),i=n(82438),o=n.n(i),a=n(21766);class s extends a["default"]{get allOutputs(){return this.$rootGetters["cluster/all"](r.cm.CLUSTER_OUTPUT)||[]}get outputs(){if(!this.allOutputs)return[];const e=this?.spec?.globalOutputRefs||this?.spec?.outputRefs||[];return this.allOutputs.filter(t=>e.includes(t.name))}get outputProviders(){const e=this.outputs.flatMap(e=>e.providers);return o()(e)||[]}get customValidationRules(){return[{path:"spec",validators:["flowOutput"]}]}}},63331:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(44931);class i extends r["default"]{}},21766:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return c},matchRuleIsPopulated:function(){return l}});var r=n(35664),i=n(76978),o=n(82438),a=n.n(o),s=n(39975);function l(e){return!!e&&(!(!e.labels||!Object.keys(e.labels).length)||(!!e.hosts?.length||(!!e.container_names?.length||!!e.namespaces?.length)))}class c extends s.A{applyDefaults(){(0,i.hZ)(this,"spec",this.spec||{}),(0,i.hZ)(this.spec,"match",this.spec.match||[]),(0,i.hZ)(this.spec,"filters",this.spec.filters||[]),(0,i.hZ)(this.spec,"localOutputRefs",this.spec.localOutputRefs||[]),(0,i.hZ)(this.spec,"globalOutputRefs",this.spec.globalOutputRefs||[])}get canCustomEdit(){if(!this.spec?.match?.length)return!0;let e=!0;for(const t of this.spec.match)if(l(t.select)&&l(t.exclude)){e=!1;break}return e}get allOutputs(){return this.$rootGetters["cluster/all"](r.cm.OUTPUT)||[]}get allClusterOutputs(){return this.$rootGetters["cluster/all"](r.cm.CLUSTER_OUTPUT)||[]}get outputs(){const e=this.spec?.localOutputRefs||[];return this.allOutputs.filter(t=>e.includes(t.name)&&t.metadata?.namespace===this.metadata?.namespace)}get outputsSortable(){const e=this.outputs.map(e=>e.nameDisplay);return e.sort(),e.join("")}get clusterOutputs(){const e=this.spec?.globalOutputRefs||[];return this.allClusterOutputs?this.allClusterOutputs.filter(t=>e.includes(t.name)):[]}get clusterOutputsSortable(){const e=this.clusterOutputs.map(e=>e.nameDisplay);return e.sort(),e.join("")}get providersDisplay(){const e=[...this.outputs,...this.clusterOutputs],t=e.flatMap(e=>e.providersDisplay);return a()(t)||[]}get customValidationRules(){return[{path:"spec",validators:["flowOutput:verifyLocal"]}]}}},44931:function(e,t,n){"use strict";n.r(t),n.d(t,{PROVIDERS:function(){return i},default:function(){return o}});var r=n(39975);const i=[{name:"awsElasticsearch",labelKey:"logging.outputProviders.awsElasticsearch",default:{endpoint:{}}},{name:"azurestorage",labelKey:"logging.outputProviders.azurestorage",default:{}},{name:"cloudwatch",labelKey:"logging.outputProviders.cloudwatch",default:{}},{name:"datadog",labelKey:"logging.outputProviders.datadog",default:{}},{name:"elasticsearch",labelKey:"logging.outputProviders.elasticsearch",default:{}},{name:"file",labelKey:"logging.outputProviders.file",default:{}},{name:"forward",labelKey:"logging.outputProviders.forward",default:{servers:[{}]}},{name:"gelf",labelKey:"logging.outputProviders.gelf",default:{}},{name:"gcs",labelKey:"logging.outputProviders.gcs",default:{}},{name:"kafka",labelKey:"logging.outputProviders.kafka",default:{format:{type:"json"}}},{name:"kinesisStream",labelKey:"logging.outputProviders.kinesisStream",default:{}},{name:"logdna",labelKey:"logging.outputProviders.logdna",default:{}},{name:"logz",labelKey:"logging.outputProviders.logz",default:{endpoint:{}}},{name:"loki",labelKey:"logging.outputProviders.loki",default:{configure_kubernetes_labels:!0}},{name:"newrelic",labelKey:"logging.outputProviders.newrelic",default:{}},{name:"opensearch",labelKey:"logging.outputProviders.opensearch",default:{}},{name:"redis",labelKey:"logging.outputProviders.redis",default:{port:6379,db_number:0,ttl:0}},{name:"splunkHec",labelKey:"logging.outputProviders.splunkHec",default:{}},{name:"sumologic",labelKey:"logging.outputProviders.sumologic",default:{}},{name:"syslog",labelKey:"logging.outputProviders.syslog",default:{}},{name:"s3",labelKey:"logging.outputProviders.s3",default:{}}];class o extends r.A{get canCustomEdit(){return this.allProvidersSupported}get providers(){const e=this.spec||{};return Object.keys(e).filter(e=>"loggingRef"!==e)}get providersDisplay(){return this.providers.map(e=>{const t=this.t(`logging.outputProviders.${e}`);return t||this.t("logging.outputProviders.unknown")})}isSupportedProvider(e){return!!i.find(t=>t.name===e)}get allProvidersSupported(){return this.providers.every(this.isSupportedProvider)}get providersSortable(){const e=[...this.providersDisplay];return e.sort(),e.join("")}get text(){return this.nameDisplay}get url(){return{name:"c-cluster-product-resource-namespace-id",params:{resource:this.type,id:this.name,namespace:this.namespace}}}get customValidationRules(){return[{path:"spec.logdna",validators:["logdna"]}]}}},78277:function(e,t,n){"use strict";n.r(t),n.d(t,{configType:function(){return u},configTypeForProvider:function(){return d},configTypeName:function(){return c},default:function(){return m},providerIcon:function(){return p},providerKey:function(){return l}});var r=n(39975),i=n(52148),o=n(35664),a=n(14220),s=n(60754);const l=e=>`${e||""}`.toLowerCase().replace(/(config|provider)$/,""),c=e=>`${e||""}`.replace(/Provider$/,"Config"),u={activedirectory:"ldap",openldap:"ldap",freeipa:"ldap",azuread:"oauth",googleoauth:"oauth",github:"oauth",githubapp:"oauth",adfs:"saml",keycloak:"saml",okta:"saml",ping:"saml",shibboleth:"saml",genericsaml:"saml",cognito:"oidc",genericoidc:"oidc",keycloakoidc:"oidc",oidc:"oidc",local:""},d=e=>u[l(e)],h={azuread:"entraid",genericoidc:"openid",genericsaml:"custom",keycloakoidc:"keycloak",oidc:"openid"},p=e=>{try{const t=l(e);return(0,i.mS)(`~shell/assets/images/vendor/${h[t]||t}.svg`)}catch(t){return""}},f=["promptDisable","promptRemove"];class m extends r.A{get disableResourceDetailDrawer(){return!0}goToEdit(e={}){super.goToEdit({[a.Ku]:"true",...e})}get _availableActions(){const e=super._availableActions.filter(e=>!e.divider),t={action:"promptDisable",label:this.t("authConfig.disable.action"),icon:"icon icon-close",enabled:!0===this.enabled},n=e.filter(e=>!f.includes(e.action)),r=[t,...e.filter(e=>f.includes(e.action))];return[...n,{divider:!0},...r]}promptDisable(){return(0,s.iV)({dispatch:(e,t)=>this.$dispatch(e,t,{root:!0}),getters:this.$rootGetters,id:this.id,name:this.nameDisplay,disableCb:()=>this.disable()})}async disable(){try{const e=await this.$dispatch("rancher/find",{type:o.k$.AUTH_CONFIG,id:this.id,opt:{url:`/v3/${o.k$.AUTH_CONFIG}/${this.id}`,force:!0}},{root:!0});if(!await this.runDisableAction(e)){const t=await this.$dispatch("rancher/clone",{resource:e},{root:!0});t.enabled=!1,await t.save()}await this.$dispatch("find",{type:o.Mc.AUTH_CONFIG,id:this.id,opt:{force:!0}})}catch(e){this.$dispatch("growl/fromError",{title:this.$rootGetters["i18n/t"]("generic.notification.title.error"),err:e.data||e},{root:!0})}}async runDisableAction(e){if(!e.hasAction("disable"))return!1;try{return await e.doAction("disable"),!0}catch(t){if("ActionNotAvailable"===(t?.code||t?.data?.code))return!1;throw t}}get detailLocation(){return{name:"c-cluster-auth-config-id",params:{cluster:this.$rootGetters["clusterId"],id:this.id}}}get canCustomEdit(){return this.$rootGetters["type-map/hasCustomEdit"](this.type,l(this._type))}get nameDisplay(){const e=this.$rootGetters["i18n/withFallback"](`model.authConfig.name."${this.id}"`,null,this.provider);return this.id===l(this._type)?e:`${e} — ${this.id}`}get provider(){return this.$rootGetters["i18n/withFallback"](`model.authConfig.provider."${l(this._type)}"`,null,this.id)}get configType(){return d(this._type)}get sideLabel(){return this.$rootGetters["i18n/withFallback"](`model.authConfig.description."${this.configType}"`,null,this.configType)}get icon(){return p(this._type)}get state(){return this.enabled?"active":"inactive"}}},65230:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return I}});var r=n(2841),i=n(35664),o=n(68851),a=n(6198),s=n(95799),l=n(39705),c=n(76978),u=n(11518),d=n(85042),h=n(39975),p=n(7325),f=n(44660),m=n(52148),g=n(41476),v=n(78474),b=n(48881);function y(e){var t,n;return(null===(n=null===(t=null===e||void 0===e?void 0:e.$extension)||void 0===t?void 0:t.getProviders(e))||void 0===n?void 0:n.filter(e=>"hosted"===e.group))||[]}function w(e){var t,n;return(null===(n=null===(t=null===e||void 0===e?void 0:e.$extension)||void 0===t?void 0:t.getProviders(e))||void 0===n?void 0:n.filter(e=>"capi"===e.group))||[]}function O(e,t){if(!t)return!1;const n=new Set(y(e).map(e=>e.id.toLowerCase()));return n.has(t.toLowerCase())}function S(e,t){if(!t)return!1;const n=new Set(w(e).map(e=>e.id.toLowerCase()));return n.has(t.toLowerCase())}var E=n(92043),x=n(74302),_=n(9262),k=n(4364);function C(e,t,n){return(t=A(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function A(e){var t=T(e,"string");return"symbol"==typeof t?t:t+""}function T(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}const R="#707070",N={};function P(e,t,n=[]){const r=`${e}Type`,i=`${e}Id`;return n.find(e=>e[r]===t)?.[i]}class I extends h.A{constructor(...e){super(...e),C(this,"_statusInfoWarned",!1)}get details(){const e=[{label:"Provisioner",content:this.provisionerDisplay},{label:"Machine Provider",content:this.machineProviderDisplay},{label:"Kubernetes Version",content:this.kubernetesVersion}];return e}get canCreateKubeconfig(){const e=this.$rootGetters["management/schemaFor"](i.I$.KUBECONFIG);return(e?.collectionMethods||[]).includes("POST")}get availableActions(){const e=this.provCluster?.listLocation||{},t=this.currentRoute(),{cluster:n,...r}=e.params||{},{cluster:i,...o}=t.params,a=(0,c.n4)(r,o),s=e?.name===t?.name&&a;return s?this.provCluster?.availableActions.map(e=>({...e,altResource:this.provCluster})):super.availableActions}get _availableActions(){const e=super._availableActions;return(0,o.PT)(e,0,{action:"openShell",label:this.t("nav.shell"),icon:"icon icon-terminal",enabled:!!this.links.shell}),(0,o.PT)(e,1,{action:"downloadKubeConfig",bulkAction:"downloadKubeConfigBulk",label:this.t("nav.kubeconfig.download"),icon:"icon icon-download",bulkable:!0,enabled:this.$rootGetters["isRancher"]&&this.canCreateKubeconfig}),(0,o.PT)(e,2,{action:"copyKubeConfig",bulkAction:"copyKubeConfigBulk",label:this.t("cluster.copyConfig"),bulkable:!0,enabled:this.$rootGetters["isRancher"]&&this.canCreateKubeconfig,icon:"icon icon-copy"}),e}get canDelete(){return this.hasLink("remove")&&!this?.spec?.internal}get machinePools(){const e=this.$getters["all"](i.Mc.NODE_POOL);return e.filter(e=>e.spec?.clusterName===this.id)}get provisioner(){return this.status?.provider?["gke","eks","aks","k3s"].includes(this.status.provider)?this.status.provider.toUpperCase():this.status.provider:this.status?.driver?this.status.driver:"imported"}get provisionerDisplay(){if(this.customProvisionerHelper?.provisionerDisplay)return this.customProvisionerHelper?.provisionerDisplay(this);let e=this.provisioner?.toLowerCase();return"rke.windows"===e&&(e="rkeWindows"),this.$rootGetters["i18n/exists"](`cluster.provider.${e}`)||(e="other"),this.$rootGetters["i18n/withFallback"](`cluster.provider."${e}"`,null,(0,E.TF)(this.provisioner))}get customProvisionerHelper(){return this.provCluster?this.modelExtensions.find(e=>!!e.useFor&&e.useFor(this.provCluster)):null}get provider(){return this.status?.provider}get machineProvider(){return this.status?.info?.machineProvider}get machineProviderDisplay(){if(this.customProvisionerHelper?.machineProviderDisplay)return this.customProvisionerHelper?.machineProviderDisplay(this);const e=(this.machineProvider||"").toLowerCase();return e?this.$rootGetters["i18n/withFallback"](`cluster.provider."${e}"`,null,e):this.$rootGetters["i18n/t"]("generic.unknown")}get isKev1(){return f.KEV1.includes(this.spec?.genericEngineConfig?.driverName)}get isImported(){const e=this.status?.provider,t=this.status?.driver;return"k3s"===e||"rke2"===e?t===e:!(e||"k3s"!==t&&"rke2"!==t)||(!(!this.isHostedKubernetesProvider||!this.provCluster?.providerConfig?.imported)||"imported"===this.provisioner)}get isCustom(){return!!this.isRke2&&!this.provCluster?.spec?.rkeConfig?.machinePools?.length}get isImportedK3s(){return this.isImported&&this.isK3s}get isImportedRke2(){return this.isImported&&this.provider?.startsWith("rke2")}get isK3s(){return this.status?"k3s"===this.status.provider:(this.kubernetesVersion||"").includes("k3s")}get isRke2(){return!!this.provCluster?.isRke2}get isCapiHybrid(){if(!this.isRke2)return!1;const e=(this.provCluster.spec?.rkeConfig?.machinePools||[]).map(e=>e.machineConfigRef),t=e.find(e=>e?.apiVersion?.includes("cluster.x-k8s.io"));return!!t}get isCAPIProvider(){if(!this.isCapiHybrid||!this.machineProvider)return!1;const e={dispatch:this.$dispatch,getters:this.$getters,axios:this.$axios,$extension:this.$extension,t:(...e)=>this.t.apply(this,e)};return S(e,this.machineProvider.toLowerCase())}get isHostedKubernetesProvider(){const e={dispatch:this.$dispatch,getters:this.$getters,axios:this.$axios,$extension:this.$extension,t:(...e)=>this.t.apply(this,e)};return O(e,this.provisioner)}get isPrivateHostedProvider(){if(this.isHostedKubernetesProvider&&this.provisioner)switch(this.provisioner.toLowerCase()){case"gke":return this.spec?.gkeConfig?.privateClusterConfig?.enablePrivateEndpoint;case"eks":return this.spec?.eksConfig?.privateAccess;case"aks":return this.spec?.aksConfig?.privateCluster}return!1}get groupByLabel(){return`Workspace: ${this.spec.fleetWorkspaceName}`}get isReady(){return this.hasCondition("Connected")?this.isCondition("Connected"):this.isCondition("Ready")}get config(){if(!this.spec?.[`${this.provisioner}Config`]){const e=Object.keys(this.spec),t=e.find(e=>e.endsWith("Config"));return this.spec[t]}return this.spec?.[`${this.provisioner}Config`]}get kubernetesVersionRaw(){return this.statusInfo.kubernetesVersion}get kubernetesVersion(){return this.kubernetesVersionRaw||this.$rootGetters["i18n/t"]("generic.provisioning")}get kubernetesVersionBase(){return this.kubernetesVersion.replace(/[+-].*$/,"")}get kubernetesVersionExtension(){return this.kubernetesVersion.match(/[+-]/)?this.kubernetesVersion.replace(/^.*([+-])/,"$1"):""}get providerOs(){return this.provider?.endsWith(".windows")?"windows":"linux"}get providerOsLogo(){return(0,m.mS)(`~shell/assets/images/vendor/${this.providerOs}.svg`)}get workerOSs(){const e=this.status?.windowsWorkerCount,t=this.status?.linuxWorkerCount;if(e||t){const n=[];return e&&n.push(p.CB),t&&n.push(p["do"]),n}return this.providerOs===p.CB?[p.CB]:[p["do"]]}get isLocal(){return!0===this.spec?.internal}get isDayTwoOpsFeatureEnabled(){return this.$rootGetters["management/byId"](i.Mc.FEATURE,u.IY)?.enabled||!1}get isDayTwoOpsEnabled(){const e=!this.isLocal&&(this.isImportedK3s||this.isImportedRke2),t="undefined"!==typeof this.metadata?.annotations?.[r.P0.ENABLED],n="true"===this.metadata?.annotations?.[r.P0.ENABLED],o="true"===this.$rootGetters["management/byId"](i.Mc.SETTING,_.HG.IMPORTED_CLUSTER_DAY2_OPS_DEFAULT)?.value,a=t?n:o;return this.isDayTwoOpsFeatureEnabled&&e&&a}get isHarvester(){return(0,d.F0)(this)}get providerLogo(){let e=this.provider||"kubernetes";this.isHarvester&&(e=u.T3);const t=e.split(".")[0],n=N[t]||t;let r;try{r=(0,m.mS)(`~shell/assets/images/providers/${t}.svg`)}catch(i){k.warn(`Can not find provider logo for provider ${n}`),r=(0,m.mS)("~shell/assets/images/providers/kubernetes.svg")}return r}get providerMenuLogo(){return this.providerLogo}get providerNavLogo(){return this.providerLogo}get pools(){const e=this.$rootGetters["management/all"](i.Z7.MACHINE_DEPLOYMENT).filter(e=>e.spec?.clusterName===this.provClusterName);return e.length?e:this.machinePools}get desired(){return this.pools.reduce((e,t)=>e+(t.desired||0),0)}get pending(){return this.pools.reduce((e,t)=>e+(t.pending||0),0)}get outdated(){return this.pools.reduce((e,t)=>e+(t.outdated||0),0)}get ready(){return this.pools.reduce((e,t)=>e+(t.ready||0),0)}get stateParts(){const e=[{label:"Pending",color:"bg-info",textColor:"text-info",value:this.pending,sort:1},{label:"Outdated",color:"bg-warning",textColor:"text-warning",value:this.outdated,sort:2},{label:"Unavailable",color:"bg-error",textColor:"text-error",value:this.unavailable,sort:3},{label:"Ready",color:"bg-success",textColor:"text-success",value:this.ready,sort:4}].filter(e=>e.value>0);return(0,x.Ul)(e,"sort:desc")}get nodes(){return this.$getters["all"](i.Mc.NODE).filter(e=>e.id.startsWith(this.id))}get nodesArchitecture(){const e={};return this.nodes?.forEach(t=>{if(!t.metadata?.state?.transitioning){const n=t.status?.nodeLabels?.[r.Pl],i=n||this.t("cluster.architecture.label.unknown");e[i]=(e[i]||0)+1}}),e}get architecture(){return this.statusInfo.arch?"mixed"===this.statusInfo.arch?{label:this.t("cluster.architecture.label.mixed")}:{label:this.statusInfo.arch}:{label:this.t("generic.provisioning")}}get machines(){return this.$rootGetters["management/all"](i.Z7.MACHINE).filter(e=>e.metadata?.namespace===this.provClusterNamespace&&e.spec?.clusterName===this.provClusterName)}get unavailable(){return this.pools.reduce((e,t)=>e+(t.unavailable||0),0)}get unavailableMachines(){if(this.isReady){const e=this.machines.filter(e=>e.status?.conditions?.find(e=>e.error&&"NodeHealthy"===e.type)).map(e=>e.status?.nodeRef?.name?this.t("cluster.availabilityWarnings.node",{name:e.status.nodeRef.name}):this.t("cluster.availabilityWarnings.machine",{name:e.metadata.name}));return e.join("<br>")}return""}get eksNodeGroups(){return this.spec?.eksConfig?.nodeGroups||[]}get iconColor(){return this.metadata?.annotations?.[r.XH.COLOR]}get badge(){const e=this.metadata?.annotations?.[r.XH.ICON_TEXT],t=this.metadata?.annotations?.[r.XH.TEXT];if(!e&&!t)return;let n=this.iconColor||R;const i=this.metadata?.annotations[r.XH.ICON_TEXT]||"";let o;try{o=(0,l.hk)((0,l.H0)(n.trim()))}catch(a){n=R,o=(0,l.hk)((0,l.H0)(n))}return{text:t||void 0,color:n,textColor:o,iconText:i.substr(0,3)}}get scope(){return this.isLocal?r.W8._MANAGEMENT:r.W8._DOWNSTREAM}setClusterNameLabel(e){if(!this.ownerReferences?.length&&this.metadata?.labels?.[i.Hs.CLUSTER_NAME]!==this.id)return this.metadata=this.metadata||{},this.metadata.labels=this.metadata.labels||{},this.metadata.labels[i.Hs.CLUSTER_NAME]=this.id,e?this.save():void 0}get availableCpu(){const e=(0,s.ao)(this.status?.requested?.cpu),t=(0,s.ao)(this.status?.allocatable?.cpu);return t>0&&e>=0?Math.max(0,t-e):null}get availableMemory(){const e=(0,s.ao)(this.status?.requested?.memory),t=(0,s.ao)(this.status?.allocatable?.memory);return t>0&&e>=0?Math.max(0,t-e):null}openShell(){this.$dispatch("wm/open",{id:`kubectl-${this.id}`,label:this.$rootGetters["i18n/t"]("wm.kubectlShell.title",{name:this.nameDisplay}),icon:"terminal",component:"KubectlShell",attrs:{cluster:this,pod:{}}},{root:!0})}kubeConfigClusterIds(e=[]){return this.mgmtClusterIds(e)}mgmtClusterIds(e=[]){return(0,o.sb)(e.map(e=>e.mgmt?.id||e.id).filter(e=>!!e))}async generateKubeConfig(e=[this.id]){if(!e.length)return void this.$dispatch("growl/error",{title:this.t("cluster.kubeConfig.error.title"),message:this.t("cluster.kubeConfig.error.noClusters")},{root:!0});const t=await this.$dispatch("management/create",{type:i.I$.KUBECONFIG,spec:{clusters:e,includeDefaultEntry:!1}},{root:!0}),n=await t.save();return n.status?.value}async downloadKubeConfig(){const e=await this.generateKubeConfig();(0,a.PE)(`${this.nameDisplay}.yaml`,e,"application/yaml")}async downloadKubeConfigBulk(e){const t=this.kubeConfigClusterIds(e),n=await this.generateKubeConfig(t);n&&(0,a.PE)("kubeconfig.yaml",n,"application/yaml")}async copyKubeConfig(){try{const e=await this.generateKubeConfig();e&&await(0,b.e)(e)}catch{}}async copyKubeConfigBulk(e){try{const t=this.kubeConfigClusterIds(e),n=await this.generateKubeConfig(t);n&&await(0,b.e)(n)}catch{}}async fetchNodeMetrics(){const e=await this.$dispatch("cluster/findAll",{type:i.NW},{root:!0}),t=await this.$dispatch("cluster/findAll",{type:i.NW},{root:!0}),n=e.some(e=>e.hasARole&&!e.isWorker),r=t.filter(t=>{const r=e.find(e=>e.id===t.id);return r&&(!n||r.isWorker)}),o={cpu:0,memory:0};return(0,c.Im)(r)?null:r.reduce((e,t)=>(e.cpu+=(0,s.ao)(t?.usage?.cpu),e.memory+=(0,s.ao)(t?.usage?.memory),e),o)}get normanCluster(){return this.$rootGetters["rancher/byId"](i.k$.CLUSTER,this.id)}async findNormanCluster(){return await this.$dispatch("rancher/find",{type:i.k$.CLUSTER,id:this.id},{root:!0})}get provCluster(){return this.$rootGetters["management/byId"](i.Z7.RANCHER_CLUSTER,this.provClusterId)}get provClusterId(){const e=this.isLocal||this.isHostedKubernetesProvider?"to":"from",t=P(e,i.Z7.RANCHER_CLUSTER,this.metadata?.relationships);return t||P("to"===e?"from":"to",i.Z7.RANCHER_CLUSTER,this.metadata?.relationships)}get provClusterNamespace(){const[e]=this.provClusterId?.split("/")||[];return e}get provClusterName(){const[,e]=this.provClusterId?.split("/")||[];return e}get pinned(){return this.$rootGetters["prefs/get"](g.Hu).includes(this.id)}get clusterPrefDispatch(){return(e,t)=>this.$dispatch(e,t,{root:!0})}pin(){return this.pinBulk([this])}unpin(){return this.unpinBulk([this])}pinBulk(e){return(0,v.pf)(this.clusterPrefDispatch,[(0,v.HX)(this.mgmtClusterIds(e),!0)])}unpinBulk(e){return(0,v.pf)(this.clusterPrefDispatch,[(0,v.HX)(this.mgmtClusterIds(e),!1)])}get canExplore(){return this.isReady&&!this.hasError}get hasError(){if(this.status?.conditions&&this.status?.conditions.length&&this.status?.conditions.some(e=>!0===e.error)){if(!this.status?.conditions.some(e=>"Ready"===e.type))return!0;const e=this.status?.conditions.filter(e=>!0===e.error||"Ready"===e.type),t=e.reduce((e,t)=>e.lastUpdateTime>t.lastUpdateTime?e:t);return t.error}return!1}get isAutoscalerEnabled(){return!!this.provCluster&&!!this.provCluster.spec?.rkeConfig?.machinePools?.some(e=>"undefined"!==typeof e.autoscalingMinSize||"undefined"!==typeof e.autoscalingMaxSize)}get statusInfo(){return this.status?.info?this.status.info:(this._statusInfoWarned||(this._statusInfoWarned=!0,k.warn(`management.cattle.io.cluster '${this.id}' is missing 'status.info'. This could mean the resource is troubled, or an extension has brought in this new model which is used in an older rancher`)),{})}async goToHarvesterCluster(){const e=await this.$dispatch("create",{...this.provCluster,type:i.rk.CLUSTER});try{await e.goToCluster()}catch{}}}},54820:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return l}});var r=n(2841),i=n(14220),o=n(35664),a=n(82614),s=n(11518);class l extends a.A{detailPageHeaderActionOverride(e){if(e===i.YQ)return this.t("members.createActionLabel")}get canCustomEdit(){return!1}get canYaml(){return!1}get canClone(){return!1}get user(){return this.$rootGetters["management/byId"](o.Mc.USER,this.userName)}get principal(){const e=encodeURIComponent(this.principalId);return this.$dispatch("rancher/find",{type:o.k$.PRINCIPAL,id:this.principalId,opt:{url:`/v3/principals/${e}`}},{root:!0})}get syncPrincipal(){return this.$rootGetters["rancher/byId"](o.k$.PRINCIPAL,this.principalId)}get principalId(){return this.principalName||this.userPrincipalName||this.groupPrincipalName||""}get nameDisplay(){return this.user?.nameDisplay||this.userName||this.syncPrincipal?.nameDisplay||this.principalId}get roleDisplay(){return this.roleTemplate?.nameDisplay}get roleDescription(){return this.roleTemplate?.description}get roleTemplate(){return this.$rootGetters["management/byId"](o.Mc.ROLE_TEMPLATE,this.roleTemplateName)}get cluster(){return this.$rootGetters["management/byId"](o.Mc.CLUSTER,this.clusterName)}get clusterDisplayName(){return this.cluster?this.cluster.nameDisplay:this.clusterName}get clusterDetailLocation(){return this.cluster?.canExplore?{name:"c-cluster-explorer",params:{cluster:this.clusterName}}:null}get listLocation(){return this.$rootGetters["currentProduct"].inStore===s.T3?{name:`${s.T3}-c-cluster-members`}:{name:"c-cluster-product-members"}}get doneOverride(){return this.listLocation}get parentLocationOverride(){return this.listLocation}get subSearch(){return[{nameDisplay:this.nameDisplay}]}get isSystem(){return!this.metadata.annotations[r.Rw]}get norman(){return(async()=>{const e=await this.principal,t="group"===e?.principalType?"groupPrincipalId":"userPrincipalId";return this.$dispatch("rancher/create",{type:o.k$.CLUSTER_ROLE_TEMPLATE_BINDING,roleTemplateId:this.roleTemplateName,[t]:e?.id,clusterId:this.clusterName,id:this.id?.replace("/",":")},{root:!0})})()}async save(){const e=await this.norman;return e.save()}async remove(){const e=await this.norman;await e.remove({url:`/v3/clusterRoleTemplateBindings/${e.id}`})}}},58975:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return a}});var r=n(11518),i=n(83297),o=n(82614);class a extends o.A{get state(){return this.enabled?"active":"off"}get primeUnavailable(){return!!this.status?.prime&&!(0,i.f$)()}get enabled(){return!this.primeUnavailable&&(this.status&&null!==this.status.lockedValue?this.status.lockedValue:null!==this.spec.value?this.spec.value:this.status.default)}get restartRequired(){return!this.status?.dynamic}get canYaml(){return!1}get canDisable(){return this.canUpdate&&!r.r6.includes(this.id)}get _availableActions(){const e=super._availableActions,t=this.enabled,n={action:"toggleFeatureFlag",label:t?this.t("action.deactivate"):this.t("action.activate"),icon:"icon icon-edit",enabled:t?this.canDisable:this.canUpdate};return n.enabled=n.enabled&&this.status&&null===this.status.lockedValue&&!this.primeUnavailable,e.unshift(n),e}toggleFeatureFlag(e=this){this.$dispatch("promptModal",{component:"FeatureFlagListDialog",resources:Array.isArray(e)?e:[e],modalWidth:"450",height:"auto",styles:"max-height: 100vh;"})}}},61504:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return s}});var r=n(35664),i=n(68851),o=n(82614),a=n(2841);class s extends o.A{get isLocal(){return"fleet-local"===this.metadata.name}get counts(){const e=this.$rootGetters["management/all"](r.i2)[0].counts||{},t=this.metadata.name,n={clusterGroups:e[r.Hs.CLUSTER_GROUP]?.namespaces?.[t]?.count||0,clusters:e[r.Hs.CLUSTER]?.namespaces?.[t]?.count||0,gitRepos:e[r.Hs.GIT_REPO]?.namespaces?.[t]?.count||0,helmOps:e[r.Hs.HELM_OP]?.namespaces?.[t]?.count||0};return n}get clusters(){const e=this.$getters["all"](r.Hs.CLUSTER),t=(0,i.WP)(e,"metadata.namespace",this.metadata.name);return t}get clusterGroups(){const e=this.$getters["all"](r.Hs.CLUSTER_GROUP),t=(0,i.WP)(e,"metadata.namespace",this.metadata.name);return t}get repos(){const e=this.$getters["all"](r.Hs.GIT_REPO),t=(0,i.WP)(e,"namespace",this.id);return t}get helmOps(){const e=this.$getters["all"](r.Hs.HELM_OP),t=(0,i.WP)(e,"namespace",this.id);return t}get basicNorman(){return this.id?this.$dispatch("rancher/find",{id:this.id,type:r.k$.FLEET_WORKSPACES},{root:!0}):this.$dispatch("rancher/create",{type:r.k$.FLEET_WORKSPACES,name:this.metadata.name},{root:!0})}get norman(){return(async()=>{const e=await this.basicNorman;return e.annotations=this.metadata.annotations,e.labels=this.metadata.labels,e})()}async save(){const e=await this.norman;await e.save()}waitForWorkspaceSchema(e=2e4,t){return this.waitForTestFn(()=>{const e=this.$rootGetters["management/schemaFor"](r.Hs.WORKSPACE);return t?t(e):e},this.$rootGetters["i18n/t"]("fleet.workspaces.timeout"),e)}async remove(){const e=await this.norman;await e.remove()}get confirmRemove(){return!0}get systemAnnotations(){return[a.Hs.OCI_STORAGE_SECRET_DEFAULT]}}},33707:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(39975);class i extends r.A{}},14606:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return m}});var r=n(2841),i=n(35664),o=n(4799),a=n(68851),s=n(76978),l=n(63928),c=n(14220);const u="user-base",d="user",h="admin",p=[u,h,d],f=o.SUBTYPE_MAPPING.GLOBAL.key;class m extends l.A{get customValidationRules(){return[{path:"rules",validators:[`roleTemplateRules:${this.type}`],nullable:!1,type:"array"}]}get details(){const e=this._details;return e.unshift({label:this.t("resourceDetail.detailTop.name"),content:(0,s.Jt)(this,"name")}),e}get nameDisplay(){const e=`rbac.globalRoles.role.${this.id}.label`,t=this.displayName||this.metadata?.name||this.id;return this.$rootGetters["i18n/withFallback"](e,t)}get descriptionDisplay(){return this.description||this.metadata?.annotations?.[r.tC]||this.$rootGetters["i18n/withFallback"](`rbac.globalRoles.role.${this.id}.description`,this.t("rbac.globalRoles.unknownRole.description"))}get isSpecial(){return p.includes(this.id)}get subtype(){return f}get default(){return!!this.newUserDefault}get allResources(){return this.$getters["all"](i.yx).filter(e=>e.attributes?.kind)}get globalResources(){return this.allResources.filter(e=>e.attributes.group.includes(o.CATTLE_API_GROUP))}get resources(){return(0,a.sb)(this.globalResources.map(e=>e.attributes?.resource)).sort()}get listLocation(){return{name:"c-cluster-auth-roles",hash:`#${f}`}}get detailLocation(){return{...this._detailLocation,name:"c-cluster-auth-roles-resource-id"}}get doneOverride(){return this.listLocation}get parentLocationOverride(){return this.listLocation}get basicNorman(){return this.id?this.$dispatch("rancher/find",{id:this.id,type:i.k$.GLOBAL_ROLE},{root:!0}):this.$dispatch("rancher/create",{type:i.k$.GLOBAL_ROLE,name:this.displayName},{root:!0})}get norman(){return(async()=>{const e=await this.basicNorman;return e.rules=this.rules,e.newUserDefault=this.newUserDefault,e.id=this.id,e.name=this.displayName,e.description=this.description,e.inheritedClusterRoles=this.inheritedClusterRoles,e})()}get canCreate(){const e=this.$getters["schemaFor"](this.type);return e?.resourceMethods.find(e=>o.CREATE_VERBS.has(e))}goToClone(e={}){const t=this.detailLocation;t.query={...t.query,[c.g]:c.dT,[c.AS]:c.xz,roleContext:f,...e},this.currentRouter().push(t)}async save(){const e=await this.norman;for(const t of e.rules)t.nonResourceURLs&&t.nonResourceURLs.length?(delete t.resources,delete t.apiGroups):delete t.nonResourceURLs;return e.save()}async remove(){const e=await this.norman;await e.remove()}}},97621:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(35664),i=n(82614);class o extends i.A{get nameDisplay(){const e=this.$getters["byId"](r.Mc.GLOBAL_ROLE,this.globalRoleName);if(!e)return this.globalRoleName;const t=this.groupPrincipalName?this._displayPrincipal:this._displayUser;return t?`${e.displayName} (${t})`:e.displayName}get _displayPrincipal(){const e=this.$rootGetters["rancher/byId"](r.k$.PRINCIPAL,this.groupPrincipalName);return e?`${e.name} - ${e.displayType}`:null}get _displayUser(){return this.user}get basicNorman(){return this.id?this.$dispatch("rancher/find",{id:this.id,type:r.k$.GLOBAL_ROLE_BINDING},{root:!0}):this.$dispatch("rancher/create",{type:r.k$.GLOBAL_ROLE_BINDING,name:this.displayName},{root:!0})}get norman(){return(async()=>{const e=await this.basicNorman;return e.globalRoleId=this.globalRoleName,e.userId=this.userName,e.newUserDefault=this.newUserDefault,e.groupPrincipalId=this.groupPrincipalName,e})()}async save(){const e=await this.norman;return e.save()}async remove(){const e=await this.norman;await e.remove()}}},44660:function(e,t,n){"use strict";n.r(t),n.d(t,{KEV1:function(){return s},KONTAINER_TO_DRIVER:function(){return a},default:function(){return l}});var r=n(82614);const i=["rke","rancherkubernetesengine"],o=["amazoneks","googlegke","azureaks"],a={amazonelasticcontainerservice:"amazoneks",azurekubernetesservice:"azureaks",aks:"azureaksv2",eks:"amazoneksv2",gke:"googlegkev2",googlekubernetesengine:"googlegke",huaweicontainercloudengine:"huaweicce",huaweiengine:"huaweicce",linodekubernetesengine:"linodelke",lke:"linodelke",lkeengine:"linodelke",okeengine:"oracleoke",oke:"oracleoke",oraclecontainerengine:"oracleoke",rke2:"rke2",tencentengine:"tencenttke",tencentkubernetesengine:"tencenttke",aliyunkubernetescontainerservice:"aliyun",baiducloudcontainerengine:"baidu",opentelekomcloudcontainerengine:"otccce"},s=["amazonelasticcontainerservice","azurekubernetesservice","googlekubernetesengine"];class l extends r.A{get showCreate(){return!i.includes(this.driverName)&&!!this.spec.active}get showImport(){return this.showCreate&&o.includes(this.driverName)}get driverName(){if(!this.spec.builtIn){const e=this.status?.displayName?.toLowerCase();if(e)return a[e]||e}return a[this.id]||this.id}}},77917:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return p}});var r=n(2841),i=n(35664),o=n(27278),a=n(44458),s=n(6198),l=n(24576),c=n.n(l),u=n(82614),d=n(61843);const h=["goToViewYaml","download","viewInApi","showConfiguration"];class p extends u.A{get _availableActions(){const e=super._availableActions;return e.filter(e=>e.divider||h.includes(e.action))}get kubeNodeName(){return this.metadata.labels[r.Do.NODE_NAME]}get mgmtCluster(){return this.$rootGetters["management/byId"](i.Mc.CLUSTER,this.mgmtClusterId)}get mgmtClusterId(){return this.id.substring(0,this.id.indexOf("/"))}get kubeNodeDetailLocation(){return this.kubeNodeName?{name:"c-cluster-product-resource-id",params:{cluster:this.mgmtClusterId,product:o.o,resource:i.NW,id:this.kubeNodeName}}:null}get isWorker(){return this.spec.worker}get isControlPlane(){return this.spec.controlPlane}get isEtcd(){return this.spec.etcd}get roles(){const{isControlPlane:e,isWorker:t,isEtcd:n}=this;return(0,a.listNodeRoles)(e,t,n,this.t("generic.all"))}get pool(){if(!this.spec?.nodePoolName)return;const e=this.spec.nodePoolName.replace(":","/");return this.$rootGetters["management/byId"](i.Mc.NODE_POOL,e)}get norman(){const e=this.id.replace("/",":");return this.$rootGetters["rancher/byId"](i.k$.NODE,e)}get canDelete(){return this.norman?.hasLink("remove")}get canUpdate(){return this.hasLink("update")&&this.norman?.hasLink("update")}remove(){return this.norman?.remove()}downloadKeys(){const e=this.norman?.links?.nodeConfig;e&&(0,s.Is)(e)}async scaleDown(e=this){this.$dispatch("promptModal",{resources:e,component:"ScaleMachineDownDialog",modalWidth:"450px"})}get provisioningCluster(){return this.mgmtCluster?.provCluster}get doneOverride(){return this.provisioningCluster?.detailLocation}get canClone(){return!1}get addresses(){return this.status?.addresses||this.status?.internalNodeStatus?.addresses||[]}get internalIps(){const e=this.addresses.filter(({type:e})=>e===i.FV.INTERNAL_IP);return e.length?e.map(({address:e})=>e):this.status?.rkeNode&&this.status.rkeNode.internalAddress?[this.status.rkeNode.internalAddress]:[]}get externalIps(){const e=this.addresses.filter(({type:e})=>e===i.FV.EXTERNAL_IP);return e.length?e.map(({address:e})=>e):this.status?.rkeNode&&this.status.rkeNode.address?[this.status.rkeNode.address]:[]}get internalIp(){const e=this.addresses.find(({type:e})=>e===i.FV.INTERNAL_IP);return e?e.address:!e&&this.status?.rkeNode?this.status.rkeNode.internalAddress:this.t("generic.none")}get externalIp(){const e=c()(this.addresses,e=>"ExternalIP"===e.type)?.address;return e||(!e&&this.status?.rkeNode?this.status.rkeNode.address:this.t("generic.none"))}get canScaleDown(){const e=this.norman?.actions?.scaledown;return!(this.isEtcd||this.isControlPlane||!e)||e&&(0,d.notOnlyOfRole)(this,this.provisioningCluster?.nodes)}}},68959:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return l}});var r=n(35664),i=n(74302),o=n(82614),a=n(61843);const s=["goToViewYaml","download","viewInApi"];class l extends o.A{get _availableActions(){const e=super._availableActions;return e.filter(e=>e.divider||s.includes(e.action))}get nodeTemplateId(){return(this.spec?.nodeTemplateName||"").replace(/:/,"/")}get nodeTemplate(){return this.$getters["byId"](r.Mc.NODE_TEMPLATE,this.nodeTemplateId)}get provider(){return this.nodeTemplate?.provider}get providerName(){return this.nodeTemplate?.nameDisplay}get providerDisplay(){return this.nodeTemplate?.providerDisplay}get providerLocation(){return this.nodeTemplate?.providerLocation}get providerSize(){return this.nodeTemplate?.providerSize}get provisioningCluster(){return this.$getters["byId"](r.Z7.RANCHER_CLUSTER,`${this.metadata.namespace}/${this.spec.clusterName}`)}get doneOverride(){return{name:"c-cluster-product-resource-namespace-id",params:{resource:r.Z7.RANCHER_CLUSTER,namespace:this.provisioningCluster?.namespace,id:this.spec.clusterName}}}get scale(){return this.norman.quantity}scalePool(e){this.norman.quantity+=e,this.scaleTimer&&clearTimeout(this.scaleTimer),this.scaleTimer=setTimeout(()=>{try{this.norman.save()}catch(e){this.$dispatch("growl/fromError",{title:"Error scaling pool",error:e},{root:!0})}},1e3)}get nodes(){const e=this.id.replace("/",":");return this.$getters["all"](r.Mc.NODE).filter(t=>t.spec.nodePoolName===e)}get nodeSummary(){const e={pending:0,unavailable:0,ready:0};return this.nodes?this.nodes.reduce((e,t)=>(t.metadata.state.error?e.unavailable++:t.metadata.state.transitioning?e.pending++:"active"!==t.state?e.unavailable++:e.ready++,e),{...e}):e}get desired(){return this.spec?.quantity||0}get pending(){return this.nodeSummary.pending}get ready(){return this.nodeSummary.ready}get unavailable(){return this.nodeSummary.unavailable}get stateParts(){const e=[{label:"Pending",color:"bg-info",textColor:"text-info",value:this.pending,sort:1},{label:"Unavailable",color:"bg-error",textColor:"text-error",value:this.unavailable,sort:3},{label:"Ready",color:"bg-success",textColor:"text-success",value:this.ready,sort:4}].filter(e=>e.value>0);return(0,i.Ul)(e,"sort:desc")}get norman(){const e=this.id.replace("/",":");return this.$rootGetters["rancher/byId"](r.k$.NODE_POOL,e)}get canDelete(){return this.norman?.hasLink("remove")}get canUpdate(){return this.norman?.hasLink("update")}get isControlPlane(){return!0===this.spec?.controlPlane}get isEtcd(){return!0===this.spec?.etcd}canScaleDownPool(){return!this.isEtcd&&!this.isControlPlane||(0,a.notOnlyOfRole)(this,this?.provisioningCluster?.nodes)}remove(){return this.norman?.remove()}}},57075:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return a}});var r=n(95799),i=n(82614);const o=[{driver:"aliyunecs",size:{key:"instanceType"},location:{getDisplayProperty(e){return`${e.providerConfig?.region}${e.providerConfig?.zone}`}}},{driver:"amazonec2",size:{key:"instanceType"},location:{getDisplayProperty(e){return`${e.providerConfig?.region}${e.providerConfig?.zone}`}}},{driver:"azure",size:{key:"size"},location:{key:"location"}},{driver:"digitalocean",size:{key:"size"},location:{key:"region"}},{driver:"exoscale",size:{key:"instanceProfile"},location:{key:"availabilityZone"}},{driver:"linode",size:{key:"instanceType"},location:{key:"region"}},{driver:"oci",size:{key:"nodeShape"},location:{}},{driver:"packet",size:{key:"plan"},location:{key:"facilityCode"}},{driver:"pnap",size:{key:"serverType"},location:{key:"serverLocation"}},{driver:"rackspace",size:{key:"flavorId"},location:{key:"region"}},{driver:"vmwarevsphere",size:{getDisplayProperty(e){const t=(0,r.Mo)(1048576*e.providerConfig?.memorySize,1024,"iB");return`${t}, ${e.providerConfig?.cpuCount} Core`}},location:{key:null}}];class a extends i.A{get provider(){const e=Object.keys(this),t=e.filter(e=>null!==this[e]).find(e=>e.endsWith("Config"));return t?t.replace(/config$/i,""):null}get providerConfig(){return this[`${this.provider}Config`]}get providerDisplay(){const e=(this.provider||"").toLowerCase();return this.$rootGetters["i18n/withFallback"](`cluster.provider."${e}"`,null,"generic.unknown",!0)}get providerLocation(){if(this.provider){const e=o.find(e=>e.driver===this.provider);if(e?.location){if(e.location.getDisplayProperty)return e.location.getDisplayProperty(this);const t=this.providerConfig?.[e.location.key];if(t)return t}}return this.providerConfig?.region||this.t("node.list.poolDescription.noLocation")}get providerSize(){if(this.provider){const e=o.find(e=>e.driver===this.provider);if(e?.size){if(e.size.getDisplayProperty)return e.size.getDisplayProperty(this);const t=this.providerConfig?.[e.size.key];if(t)return t}}return this.providerConfig?.size||this.t("node.list.poolDescription.noSize")}}},81831:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(39975);class i extends r.A{get details(){return[...this._details,{label:this.t("oidcclient.redirectURIs.label"),content:this.spec.redirectURIs?.join(", ")},{label:this.t("oidcclient.refreshTokenExpirationSeconds.detailLabel"),content:this.spec.refreshTokenExpirationSeconds},{label:this.t("oidcclient.tokenExpirationSeconds.detailLabel"),content:this.spec.tokenExpirationSeconds}]}}},10311:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(63928);class i extends r.A{}},24220:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return d}});var r=n(2841),i=n(35664),o=n(82614),a=n(3514),s=n.n(a),l=n(11518),c=n(27278);function u(e,t){return t.forEach(t=>{e[t]?.limit&&!s()(e[t].limit)&&Object.keys(e[t].limit).forEach(n=>{e[t].limit[n]||delete e[t].limit[n]}),e[t]?.usedLimit&&!s()(e[t].usedLimit)&&Object.keys(e[t].usedLimit).forEach(n=>{e[t].usedLimit[n]||delete e[t].usedLimit[n]}),e[t]?.limit&&s()(e[t].limit)&&(e[t].limit=null),e[t]?.usedLimit&&s()(e[t].usedLimit)&&(e[t].usedLimit=null),e[t]&&!s()(e[t])&&Object.keys(e[t]).every(n=>null===e[t][n])&&(e[t]=null)}),e}class d extends o.A{get isSystem(){return"true"===this.metadata?.labels?.[r.MW]}get isDefault(){return"true"===this.metadata?.labels?.[r.ol]}get namespaces(){if(!this.$rootGetters["isRancher"])return[];const e=this.$rootGetters["currentProduct"].inStore,t=this.$rootGetters[`${e}/all`](i.CU);return t.filter(e=>e.projectId===this.metadata.name)}get description(){return this.spec?.description}get doneOverride(){return this.listLocation}get listLocation(){return this.$rootGetters["currentProduct"].inStore===l.T3?{name:`${l.T3}-c-cluster-projectsnamespaces`}:{name:"c-cluster-product-projectsnamespaces"}}get _detailLocation(){const e=super._detailLocation;return this.$rootGetters["currentProduct"].inStore===l.T3?e.name=`${l.T3}-${e.name}`.replace("-product",""):(e.params.cluster=this.spec.clusterName,e.params.product=c.o),e}get parentLocationOverride(){return this.listLocation}async save(e){const t=await this.norman,n=await t.save({replace:e});return n}async remove(){const e=await this.norman;await e.remove(...arguments),await this.$dispatch("management/findAll",{type:i.Mc.PROJECT,opt:{force:!0}},{root:!0})}get norman(){return this.id?this.normanEditProject:this.normanNewProject}get normanNewProject(){return(async()=>{const e=u(this.spec,["resourceQuota","namespaceDefaultResourceQuota"]),t=await this.$dispatch("rancher/create",{type:i.k$.PROJECT,name:this.spec.displayName,description:this.spec.description,annotations:this.metadata.annotations,labels:this.metadata.labels,clusterId:this.$rootGetters["currentCluster"].id,creatorId:this.$rootGetters["auth/principalId"],containerDefaultResourceLimit:this.spec.containerDefaultResourceLimit},{root:!0});return t.setAnnotations(this.metadata.annotations),t.setLabels(this.metadata.labels),t.setResourceQuotas(e),t})()}get normanEditProject(){return(async()=>{const e=await this.$dispatch("rancher/find",{type:i.k$.PROJECT,id:this.id.replace("/",":")},{root:!0}),t=u(this.spec,["resourceQuota","namespaceDefaultResourceQuota"]);return e.setAnnotations(this.metadata.annotations),e.setLabels(this.metadata.labels),e.setResourceQuotas(t),e.description=this.spec.description,e.name=this.spec.displayName,e.containerDefaultResourceLimit=this.spec.containerDefaultResourceLimit,e})()}get canUpdate(){return super.canUpdate||this.canUpdateProjectBindings}get canUpdateProjectBindings(){const e=this.$rootGetters["rancher/schemaFor"](i.k$.PROJECT_ROLE_TEMPLATE_BINDING);return e?.collectionMethods.includes("POST")}get canEditYaml(){return!this.schema?.resourceMethods?.find(e=>"blocked-PUT"===e)&&super.canUpdate}get confirmRemove(){return!0}get glance(){const e=[...this._glance],t=e.findIndex(e=>"namespace"===e.name);return t>-1&&e.splice(t,1),e}}},91673:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return s}});var r=n(2841),i=n(35664),o=n(82614),a=n(27278);class s extends o.A{get canCustomEdit(){return!1}get canYaml(){return!1}get canClone(){return!1}get user(){return this.$rootGetters["management/byId"](i.Mc.USER,this.userName)}get principal(){const e=encodeURIComponent(this.principalId);return this.$dispatch("rancher/find",{type:i.k$.PRINCIPAL,id:this.principalId,opt:{url:`/v3/principals/${e}`}},{root:!0})}get principalId(){return this.principalName||this.userPrincipalName||this.groupPrincipalName||""}get nameDisplay(){return this.user?.nameDisplay}get projectId(){return this.projectName?.replace(":","/")}get clusterId(){return this.projectName.substring(0,this.projectName.lastIndexOf(":"))}get project(){return this.$rootGetters["management/byId"](i.Mc.PROJECT,this.projectId)}get cluster(){return this.$rootGetters["management/byId"](i.Mc.CLUSTER,this.clusterId)}get projectDisplayName(){return this.project?this.project.nameDisplay:this.projectName}get clusterDisplayName(){return this.cluster?this.cluster.nameDisplay:this.clusterId}get userAvatar(){return{nameDisplay:this.nameDisplay,userName:this.user.username,avatarSrc:this.user.avatarSrc}}get projectDetailLocation(){return this.project?this.project.detailLocation:{name:"c-cluster-product-resource-namespace-id",params:{cluster:this.clusterId,product:a.o,resource:i.Mc.PROJECT,namespace:this.clusterId,id:this.projectId.replace(/.*\//,"")}}}get clusterDetailLocation(){return this.cluster?.canExplore?{name:"c-cluster-explorer",params:{cluster:this.clusterId}}:null}get roleTemplate(){return this.$rootGetters["management/byId"](i.Mc.ROLE_TEMPLATE,this.roleTemplateName)}get roleDisplay(){return this.roleTemplate.nameDisplay}get listLocation(){return{name:"c-cluster-explorer-project-members"}}get isSystem(){return!this.metadata.annotations[r.Rw]}get norman(){return(async()=>{const e=await this.principal,t="group"===e?.principalType?"groupPrincipalId":"userPrincipalId";return this.$dispatch("rancher/create",{type:i.k$.PROJECT_ROLE_TEMPLATE_BINDING,roleTemplateId:this.roleTemplateName,[t]:e?.id,projectId:this.projectName,projectRoleTemplateId:"",id:this.id?.replace("/",":")},{root:!0})})()}async save(){const e=await this.norman;return e.save()}async remove(){const e=await this.norman;await e.remove({url:`/v3/projectRoleTemplateBindings/${e.id}`})}}},4372:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(63928);class i extends r.A{}},4799:function(e,t,n){"use strict";n.r(t),n.d(t,{CATTLE_API_GROUP:function(){return l},CREATE_VERBS:function(){return d},SUBTYPE_MAPPING:function(){return c},VERBS:function(){return u},default:function(){return h}});var r=n(76978),i=n(2841),o=n(35664),a=n(63928),s=n(14220);const l=".cattle.io",c={GLOBAL:{key:"GLOBAL",type:"management.cattle.io.globalrole",defaultKey:"newUserDefault",id:"GLOBAL",labelKey:"rbac.roletemplate.subtypes.GLOBAL.label"},CLUSTER:{key:"CLUSTER",type:"management.cattle.io.roletemplate",context:"cluster",defaultKey:"clusterCreatorDefault",id:"CLUSTER",labelKey:"rbac.roletemplate.subtypes.CLUSTER.label"},NAMESPACE:{key:"NAMESPACE",type:"management.cattle.io.roletemplate",context:"project",defaultKey:"projectCreatorDefault",id:"NAMESPACE",labelKey:"rbac.roletemplate.subtypes.NAMESPACE.label"},RBAC_ROLE:{key:"RBAC_ROLE",type:"rbac.authorization.k8s.io.role",id:"RBAC_ROLE",labelKey:"rbac.roletemplate.subtypes.RBAC_ROLE.label"},RBAC_CLUSTER_ROLE:{key:"RBAC_CLUSTER_ROLE",type:"rbac.authorization.k8s.io.clusterrole",id:"RBAC_CLUSTER_ROLE",labelKey:"rbac.roletemplate.subtypes.RBAC_CLUSTER_ROLE.label"}},u=["create","delete","get","list","patch","update","watch"],d=new Set(["PUT","blocked-PUT"]);class h extends a.A{get customValidationRules(){return[{path:"rules",validators:[`roleTemplateRules:${this.type}`],nullable:!1,type:"array"}]}get details(){const e=this._details;return e.unshift({label:this.t("resourceDetail.detailTop.name"),content:(0,r.Jt)(this,"name")},{label:this.t("resourceDetail.detailTop.description"),content:this.metadata?.annotations?.[i.tC]}),e}get state(){return this.locked?"locked":this.metadata?.state?.name||"unknown"}get subtype(){return this._subtype?this._subtype:this.type===c.CLUSTER.type&&this.context===c.CLUSTER.context?c.CLUSTER.key:this.type===c.NAMESPACE.type&&this.context===c.NAMESPACE.context?c.NAMESPACE.key:null}updateSubtype(e){this["_subtype"]=e,this.context=c[e].context}get default(){const e=c[this.subtype]?.defaultKey;return!!this[e]}updateDefault(e){const t=c[this.subtype].defaultKey;this[t]=e}get listLocation(){return{name:"c-cluster-auth-roles",hash:`#${this.subtype}`}}get detailLocation(){return{...this._detailLocation,name:"c-cluster-auth-roles-resource-id"}}get doneOverride(){return this.listLocation}get parentLocationOverride(){return this.listLocation}get basicNorman(){return this.id?this.$dispatch("rancher/find",{id:this.id,type:o.k$.ROLE_TEMPLATE},{root:!0}):this.$dispatch("rancher/create",{type:o.k$.ROLE_TEMPLATE,name:this.displayName},{root:!0})}get norman(){return(async()=>{const e=await this.basicNorman;return e.rules=this.rules,e.locked=this.locked,e.clusterCreatorDefault=this.clusterCreatorDefault||!1,e.projectCreatorDefault=this.projectCreatorDefault||!1,e.context=this.context,e.description=this.description,e.roleTemplateIds=this.roleTemplateNames,e})()}get canCreate(){const e=this.$getters["schemaFor"](this.type);return e?.resourceMethods.find(e=>d.has(e))}goToClone(e={}){const t=this.detailLocation;t.query={...t.query,[s.g]:s.dT,[s.AS]:s.xz,roleContext:this.subtype,...e},this.currentRouter().push(t)}async save(){const e=await this.norman;for(const t of e.rules)t.nonResourceURLs&&t.nonResourceURLs.length?(delete t.resources,delete t.apiGroups):delete t.nonResourceURLs;return e.save()}async remove(){const e=await this.norman;await e.remove()}}},76061:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return l}});var r=n(9262),i=n(82614),o=n(68094),a=n(11518),s=n(14220);class l extends i.A{get fromEnv(){return"env"===(this.source||"").toLowerCase()}get _availableActions(){const e=["cloneYaml","download","goToEditYaml","goToViewYaml","goToViewConfig"],t=r.Df[this.id];let n=super._availableActions;t?.readOnly&&e.push("goToEdit"),n=n.filter(t=>!e.includes(t.action));const i=n.find(e=>"goToEdit"===e.action);return i&&(i.label=this.t("advancedSettings.edit.label")),n}get customValidationRules(){const e=[];return(0,o.L6)(this.metadata.name)&&e.push({path:"value",validators:["required","https","url","trailingForwardSlash"]}),e}goToEdit(e={}){this.$rootGetters["currentProduct"].inStore===a.T3?(location.name=`${a.T3}-c-cluster-brand`,location.params={cluster:this.$rootGetters["currentCluster"].id,product:a.T3},location.query={...location.query,[s.g]:s.G5,[s.AS]:s.xz,...e},this.currentRouter().push(location)):super.goToEdit()}get disableResourceDetailDrawer(){return!0}}},69754:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return l}});var r=n(35664),i=n(39975),o=n(23464),a=n.n(o),s=n(4364);class l extends i.A{constructor(e,t,n=null,r=!1){const i=e.description;super(e,t,n,r),this.description=i}get isSystem(){for(const e of this.principalIds||[])if(e.startsWith("system://"))return!0;return!1}get isCurrentUser(){const e=this.$rootGetters["auth/principalId"];return!!(this.principalIds||[]).find(t=>t===e)}get principals(){return this.principalIds.map(e=>this.$rootGetters["rancher/byId"](r.k$.PRINCIPAL,e)).filter(e=>e)}get nameDisplay(){return this.displayName||this.username||this.id}get labelForSelect(){const e=this.nameDisplay,t=this.id;return e===t?t:`${e} (${t})`}get provider(){const e=this.principalIds||[];let t,n=!1,r=!0,i="";for(const o of e){const e=o.indexOf(":"),t=o.substr(0,e).toLowerCase().split("_")[0];"system"===t?n=!0:"local"===t||(r=!1,i=i?"multiple":t)}return t=n?"system":r?"local":i,t}get providerDisplay(){return this.$rootGetters["i18n/withFallback"](`model.authConfig.provider."${this.provider}"`,null,this.provider)}get userLastLogin(){return 1e3*this.metadata?.labels?.["cattle.io/last-login"]||0}get userDisabledIn(){return 1e3*this.metadata?.labels?.["cattle.io/disable-after"]||0}get userDisabledInDisplay(){return"inactive"===this.state?null:this.userDisabledIn}get userDeletedIn(){return 1e3*this.metadata?.labels?.["cattle.io/delete-after"]||0}get state(){return!1===this.enabled?"inactive":this.metadata?.state?.name||"unknown"}get stateDisplay(){switch(this.state){case"inactive":return this.t("user.state.inactive");case"active":return this.t("user.state.active");case"unknown":return this.t("user.state.unknown");default:return this.state}}get description(){return this._description}set description(e){this._description=e}toJSON(){const e=super.toJSON();return e.description=this._description,delete e._description,e}async save(e){const t=await this.$dispatch("clone",{resource:this});return delete t.canRefreshMemberships,t._save(e)}async setEnabled(e){const t=await this.$dispatch("clone",{resource:this});t.enabled=e,await t.save()}async activate(){await this.setEnabled(!0)}async activateBulk(e){await Promise.all(e.map(e=>e.setEnabled(!0)))}async deactivate(){await this.setEnabled(!1)}async deactivateBulk(e){await Promise.all(e.map(e=>e.setEnabled(!1)))}async refreshGroupMembership(){const e=await this.$dispatch("create",{type:r.I$.GROUP_MEMBERSHIP_REFRESH_REQUESTS});e.spec={userId:this.id},await e.save()}get canRefreshMemberships(){const e=this.$getters["schemaFor"](r.I$.GROUP_MEMBERSHIP_REFRESH_REQUESTS);return!!e&&e?.collectionMethods.find(e=>"post"===e.toLowerCase())}canActivate(e){const t=e?"inactive"===this.state:"active"===this.state,n=this.hasLink("update");return t&&n&&!this.isCurrentUser}get _availableActions(){return[{action:"activate",label:this.t("action.enable"),icon:"icon icon-play",bulkable:!0,bulkAction:"activateBulk",enabled:this.canActivate(!0),weight:2},{action:"deactivate",label:this.t("action.disable"),icon:"icon icon-pause",bulkable:!0,bulkAction:"deactivateBulk",enabled:this.canActivate(!1),weight:1},{action:"refreshGroupMembership",label:this.t("authGroups.actions.refresh"),icon:"icon icon-refresh",enabled:this.canRefreshMemberships},{divider:!0},...super._availableActions]}get details(){return[{label:this.t("user.detail.username"),formatter:"CopyToClipboard",content:this.username},{separator:!0},{label:this.t("tableHeaders.userLastLogin"),formatter:"LiveDate",formatterOpts:{addSuffix:!0,suffix:`${this.t("suffix.ago")} (${a()(this.userLastLogin)})`},content:this.userLastLogin},{label:this.t("tableHeaders.userDisabledIn"),formatter:"LiveDate",formatterOpts:{isCountdown:!0},content:this.userDisabledInDisplay},{label:this.t("tableHeaders.userDeletedIn"),formatter:"LiveDate",formatterOpts:{isCountdown:!0},content:this.userDeletedIn},...this._details]}get confirmRemove(){return!0}cleanForSave(e){const t=super.cleanForSave(e);return delete t.type,t}get norman(){return s.warn('Norman "user" is deprecated. Use Steve "management.cattle.io.user" user instead.'),this.$rootGetters["rancher/byId"](r.k$.USER,this.id)}}},95694:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(45858);class i extends r["default"]{}},86465:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return a}});var r=n(35664),i=n(95799),o=n(39975);class a extends o.A{get cpuUsage(){return(0,i.ao)(this?.usage?.cpu||"0")}get cpuCapacity(){return(0,i.ao)(this.$rootGetters[`${this.inStore}/byId`](r.NW,this.id)?.status?.allocatable?.cpu||"0")}get cpuUsagePercentage(){return(1e4*this.cpuUsage/this.cpuCapacity).toString()}get memoryUsage(){return(0,i.ao)(this?.usage?.memory||"0")}get memoryCapacity(){return(0,i.ao)(this.$rootGetters[`${this.inStore}/byId`](r.NW,this.id)?.status?.capacity?.memory||"0")}get memoryUsagePercentage(){return(1e4*this.ramUsage/this.ramCapacity).toString()}get storageUsage(){return(0,i.ao)(this.$rootGetters[`${this.inStore}/byId`](r.NW,this.id)?.status?.capacity?.["ephemeral-storage"])-(0,i.ao)(this.$rootGetters[`${this.inStore}/byId`](r.NW,this.id)?.status?.allocatable?.["ephemeral-storage"])}get storageTotal(){return(0,i.ao)(this.$rootGetters[`${this.inStore}/byId`](r.NW,this.id)?.status?.capacity?.["ephemeral-storage"])}get inStore(){return this.$rootGetters["currentProduct"].inStore}}},34858:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return s}});var r=n(39975),i=n(35664),o=n(14220),a=n(76978);class s extends r.A{applyDefaults(){const e=this.spec||{};e.receivers=e.receivers||[];const t={...e.route||{}};t.groupBy=t.groupBy||[],t.groupWait=t.groupWait||"30s",t.groupInterval=t.groupInterval||"5m",t.repeatInterval=t.repeatInterval||"4h",t.matchers=t.matchers||[],e.route=t,(0,a.hZ)(this,"spec",e)}cleanForSave(e,t){const n=super.cleanForSave(e,t),r=n?.spec?.route;return r&&(r.receiver||delete n.spec.route),n}get _availableActions(){const e=super._availableActions;return e}getReceiverActions(e){return e.filter(e=>{if(e.divider)return!0;switch(e.action){case"goToEdit":return!0;case"goToEditYaml":return!0;case"promptRemove":return!0;default:return!1}})}get alertmanagerConfigDoneRouteName(){return"c-cluster-product-resource-namespace-id"}get _detailLocation(){return{name:this.alertmanagerConfigDoneRouteName,params:{cluster:this.$rootGetters["clusterId"],product:"monitoring",resource:i.Rp.ALERTMANAGERCONFIG,namespace:this.metadata?.namespace,id:this.name},hash:"#receivers",query:{as:"config"}}}getCreateReceiverRoute(){return{name:"c-cluster-monitoring-alertmanagerconfig-alertmanagerconfigid-receiver",params:{cluster:this.$rootGetters["clusterId"],alertmanagerconfigid:this.id},query:{mode:o.YQ,currentView:o.au}}}getReceiverDetailLink(e){return{name:"c-cluster-monitoring-alertmanagerconfig-alertmanagerconfigid-receiver",params:{cluster:this.$rootGetters["clusterId"],alertmanagerconfigid:this.id,receiverName:e},query:{mode:o.nW,receiverName:e,currentView:o.au}}}getEditReceiverYamlRoute(e,t){return{name:"c-cluster-monitoring-alertmanagerconfig-alertmanagerconfigid-receiver",params:{cluster:this.$rootGetters["clusterId"],alertmanagerconfigid:this.id},query:{mode:t||o.nW,receiverName:e,currentView:o.zD}}}getEditReceiverConfigRoute(e,t){return{name:"c-cluster-monitoring-alertmanagerconfig-alertmanagerconfigid-receiver",params:{cluster:this.$rootGetters["clusterId"],alertmanagerconfigid:this.id},query:{mode:t||o.nW,receiverName:e,currentView:o.au}}}}},67750:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(39975);class i extends r.A{get _detailLocation(){const e=this.id?.replace(/.*\//,"");return{name:"c-cluster-monitoring-monitor-namespace-id",params:{cluster:this.$rootGetters["clusterId"],id:e,namespace:this.metadata.namespace},query:{resource:this.type}}}get doneOverride(){return{name:"c-cluster-monitoring-monitor",params:{cluster:this.$rootGetters["clusterId"]},query:{resource:this.type}}}}},61403:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(39975);class i extends r.A{get _availableActions(){const e=super._availableActions.filter(e=>!this.metadata.name.includes(".")||!["goToEdit","goToEditYaml","goToClone"].includes(e.action));return e}get customValidationRules(){return[{nullable:!1,path:"metadata.name",required:!0,translationKey:"generic.name",type:"dnsLabel"},{nullable:!1,path:"spec",required:!0,type:"array",validators:["ruleGroups"]},{nullable:!1,path:"spec.groups",required:!0,type:"array",validators:["groupsAreValid"]}]}}},57e3:function(e,t,n){"use strict";n.r(t),n.d(t,{RECEIVERS_TYPES:function(){return f},default:function(){return m}});var r=n(39589),i=n(76978),o=n(35664),a=n(20246),s=n.n(a),l=n(39975),c=n(69742),u=n(41778),d=n(75495),h=n(94569),p=n(98283);const f=[{name:"slack",label:"monitoringReceiver.slack.label",title:"monitoringReceiver.slack.title",info:"monitoringReceiver.slack.info",key:"slack_configs",logo:c},{name:"email",label:"monitoringReceiver.email.label",title:"monitoringReceiver.email.title",key:"email_configs",logo:u},{name:"pagerduty",label:"monitoringReceiver.pagerduty.label",title:"monitoringReceiver.pagerduty.title",info:"monitoringReceiver.pagerduty.info",key:"pagerduty_configs",logo:d},{name:"opsgenie",label:"monitoringReceiver.opsgenie.label",title:"monitoringReceiver.opsgenie.title",key:"opsgenie_configs",logo:u},{name:"webhook",label:"monitoringReceiver.webhook.label",title:"monitoringReceiver.webhook.title",key:"webhook_configs",logo:h,banner:"webhook.banner",addButton:"webhook.add"},{name:"custom",label:"monitoringReceiver.custom.label",title:"monitoringReceiver.custom.title",info:"monitoringReceiver.custom.info",key:"webhook_configs",logo:p}];class m extends l.A{get removeSerially(){return!0}remove(){return this.updateReceivers(e=>e.filter(e=>e.name!==this.spec?.name))}async save(){const e=this.validationErrors(this);return(0,i.Im)(e)?(await this.updateReceivers(e=>{const t=e.find(e=>e.name===this.spec?.name);return t?Object.assign(t,this.spec):e.push(this.spec),e}),{}):Promise.reject(e)}get canUpdate(){return this.secret.canUpdate}get canCustomEdit(){return!0}get canCreate(){return(0,r.BA)(this.$rootGetters)}get canDelete(){return"null"!==this.id&&"null"!==!this.spec.name&&this.secret.canDelete}get canViewInApi(){return!1}get canYaml(){return!0}get _detailLocation(){return{name:"c-cluster-monitoring-route-receiver-id",params:{cluster:this.$rootGetters["clusterId"],id:this.id},query:{resource:this.type}}}get doneOverride(){return{name:"c-cluster-monitoring-route-receiver",params:{cluster:this.$rootGetters["clusterId"]},query:{resource:this.type}}}get receiverTypes(){const e=f.filter(e=>"custom"!==e.name&&this.spec[e.key]?.length>0).map(e=>this.t(e.label)),t=f.map(e=>e.key).filter(e=>"custom"!==e);t.push("name");const n=Object.keys(this.spec).filter(e=>!t.includes(e));if(n.length>0){const t=this.t(f.find(e=>"custom"===e.name).label);e.push(t)}return e}get updateReceivers(){return e=>(0,r._R)(this.$dispatch,"receivers",this.type,e)}saveYaml(e){const t=s().load(e);return Object.assign(this,t),this.save()}get customValidationRules(){const e=[{nullable:!1,path:"spec.name",required:!0,translationKey:"monitoring.receiver.fields.name"}];return e}get routes(){if(!this.$rootGetters["cluster/haveAll"](o.Rp.SPOOFED.ROUTE))throw new Error("The routes have not been loaded");return this.$rootGetters["cluster/all"](o.Rp.SPOOFED.ROUTE)}get hasDependentRoutes(){return!!this.routes.find(e=>e.spec.receiver===this.id)}get preventDeletionMessage(){return this.hasDependentRoutes?"There are still routes using this receiver. You cannot delete this receiver while it's in use.":null}}},55162:function(e,t,n){"use strict";n.r(t),n.d(t,{ROOT_NAME:function(){return u},default:function(){return d}});var r=n(76978),i=n(39589),o=n(35664);n(86565),n(68774);const a="monitoring";var s=n(20246),l=n.n(s),c=n(39975);const u="root";class d extends c.A{applyDefaults(){const e=this.spec||{};e.group_by=e.group_by||[],e.group_wait=e.group_wait||"30s",e.group_interval=e.group_interval||"5m",e.repeat_interval=e.repeat_interval||"4h",e.match=e.match||{},e.match_re=e.match||{},(0,r.hZ)(this,"spec",e)}get removeSerially(){return!0}remove(){return this.updateRoutes(e=>e.filter((e,t)=>(0,i.Eb)(t)!==this.id))}async save(){const e=this.validationErrors(this);return(0,r.Im)(e)?(await this.updateRoutes(e=>{const t=e.find((e,t)=>(0,i.Eb)(t)===this.id);return t?Object.assign(t,this.spec):e.push(this.spec),e}),{}):Promise.reject(e)}get canUpdate(){return this.secret.canUpdate}get canCustomEdit(){return!0}get canCreate(){return(0,i.BA)(this.$rootGetters)&&(0,i.gb)(this.secret)}get canDelete(){return!this.isRoot&&this.secret.canDelete}get canViewInApi(){return!1}get canYaml(){return(0,i.gb)(this.secret)}get _detailLocation(){return{name:"c-cluster-monitoring-route-receiver-id",params:{cluster:this.$rootGetters["clusterId"],id:this.id},query:{resource:this.type}}}get doneOverride(){return{name:"c-cluster-monitoring-route-receiver",params:{cluster:this.$rootGetters["clusterId"]},query:{resource:this.type}}}get customValidationRules(){const e=[{nullable:!1,path:"spec.receiver",required:!0,translationKey:"monitoring.route.fields.receiver"},{path:"spec.group_wait",validators:["interval"],translationKey:"monitoring.route.fields.groupWait"},{path:"spec.group_interval",validators:["interval"],translationKey:"monitoring.route.fields.groupInterval"},{path:"spec.repeat_interval",validators:["interval"],translationKey:"monitoring.route.fields.repeatInterval"}];return this.isRoot||e.push({path:"spec",validators:["matching"]}),e}updateRoutes(e){return(0,i._R)(this.$dispatch,"route.routes",this.type,e)}get isRoot(){return this.id===u}saveYaml(e){const t=l().load(e);return Object.assign(this,t),this.save()}get receiverLink(){return{text:this.spec.receiver,to:{name:"c-cluster-product-resource-id",params:{resource:o.Rp.SPOOFED.RECEIVER,product:a,id:this.spec.receiver}}}}}},906:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(39975);class i extends r.A{get _detailLocation(){const e=this.id?.replace(/.*\//,"");return{name:"c-cluster-monitoring-monitor-namespace-id",params:{cluster:this.$rootGetters["clusterId"],id:e,namespace:this.metadata.namespace},query:{resource:this.type}}}get doneOverride(){return{name:"c-cluster-monitoring-monitor",params:{cluster:this.$rootGetters["clusterId"]},query:{resource:this.type}}}}},67867:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return C}});var r=n(71025),i=n(2841),o=n(35664),a=n(76978),s=n(68851),l=n(39975),c=n(11518),u=n(47034),d=n(27278),h=n(21342),p=n(45250);const f="pod-security.kubernetes.io/",m=["enforce","audit","warn"],g=["privileged","baseline","restricted"],v=(g[0],m.reduce((e,t)=>[...e,`${f}${t}`],[])),b=m.reduce((e,t)=>[...e,`${f}${t}-version`],[]),y=[...v,...b],w=Object.assign({},...y.map(e=>({[e]:"icon-pod_security"})));var O=n(92043);const S=e=>(0,p.filter)((0,p.keys)(e?.metadata?.labels),e=>y.includes(e)),E=e=>S(e).length>0,x=e=>(0,p.reduce)(e?.metadata?.labels,(t,n,r)=>{const i=y.includes(r),o="-version",a=r.includes(o),s=e?.metadata?.labels[`${r}${o}`],l=s||"latest";return i&&!a?{...t,[r]:`${(0,O._R)(r.replace(f,""))} ${(0,O._R)(n)} (${l})`}:t},{}),_=["c-","p-","user-","local"];function k(e){try{const t=JSON.parse(e);return t&&"object"===typeof t&&!Array.isArray(t)?t:void 0}catch{return}}class C extends l.A{applyDefaults(){(0,a.hZ)(this,"disableOpenApiValidation",!1)}get _availableActions(){const e=super._availableActions;return(0,s.PT)(e,0,{divider:!0}),this.istioInstalled&&((0,s.PT)(e,0,{action:"enableAutoInjection",label:this.t("namespace.enableAutoInjection"),bulkable:!0,bulkAction:"enableAutoInjection",enabled:!this.injectionEnabled,icon:"icon icon-plus",weight:2}),(0,s.PT)(e,0,{action:"disableAutoInjection",label:this.t("namespace.disableAutoInjection"),bulkable:!0,bulkAction:"disableAutoInjection",enabled:this.injectionEnabled,icon:"icon icon-minus",weight:1})),this.$rootGetters["isRancher"]&&!this.$rootGetters["isSingleProduct"]&&(0,s.PT)(e,0,{action:"move",label:this.t("namespace.move"),bulkable:!0,bulkAction:"move",enabled:this.canUpdate,icon:"icon icon-fork",weight:3}),e}move(e=this){this.$dispatch("promptModal",{component:"MoveNamespaceDialog",resources:Array.isArray(e)?e:[e],modalWidth:"440",height:"auto",styles:"max-height: 100vh;"})}get isSystem(){return"true"===this.metadata?.annotations?.[i.eG]||(!!r.A.includes(this.metadata.name)||(!(!this.metadata.name.startsWith("cattle-")||!this.metadata.name.endsWith("-system"))||!!this.project&&this.project.isSystem))}get isFleetManaged(){return"true"===(0,a.Jt)(this,`metadata.labels."${i.Hs.MANAGED}"`)}get isObscure(){return _.some(e=>this.metadata.name.startsWith(e))&&this.isSystem}get projectId(){const e=this.metadata?.annotations?.[i.yl]||"";return e.split(":")[1]||null}get project(){if(!this.projectId||!this.$rootGetters["isRancher"])return null;const e=this.$rootGetters["currentCluster"]?.id,t=this.$rootGetters["management/byId"](o.Mc.PROJECT,`${e}/${this.projectId}`);return t}get projectNameDisplay(){return this.project?.nameDisplay||""}get groupById(){const e=this.project?.id;return e||this.$rootGetters["i18n/t"]("resourceTable.groupLabel.notInAProject")}get projectNameSort(){return this.project?.nameSort||""}get istioInstalled(){const e=this.$rootGetters["cluster/schemaFor"](o.B9.GATEWAY);return!!e}get injectionEnabled(){return"enabled"===this.labels[i.B9.AUTO_INJECTION]}enableAutoInjection(e=this,t=!0){(0,s.cy)(e)||(e=[e]),e.forEach(e=>{!t&&e?.metadata?.labels?delete e.metadata.labels[i.B9.AUTO_INJECTION]:(e.metadata.labels||(e.metadata.labels={}),e.metadata.labels[i.B9.AUTO_INJECTION]="enabled"),e.save()})}disableAutoInjection(e=this){this.enableAutoInjection(e,!1)}get confirmRemove(){return!0}get listLocation(){const e=this.$rootGetters["productId"],t=e===u.o,n=t?o.d_:this.$rootGetters["clusterId"],r={name:this.$rootGetters["isRancher"]?"c-cluster-product-projectsnamespaces":"c-cluster-product-resource",params:{cluster:n,product:d.o}};return this.$rootGetters["currentProduct"].inStore===c.T3&&(r.name=`${c.T3}-${r.name}`.replace("-product",""),r.params={resource:"namespace"}),r}get _detailLocation(){const e=super._detailLocation;return this.$rootGetters["productId"]===u.o&&(e.params.cluster=o.d_,e.params.product=d.o),e}get parentLocationOverride(){return this.listLocation}get doneOverride(){return this.listLocation}get resourceQuota(){return k(this.metadata.annotations?.[i._n])||{limit:{}}}get hasInvalidResourceQuota(){const e=this.metadata.annotations?.[i._n];return!!e&&!k(e)}set resourceQuota(e){this.metadata.annotations[i._n]=JSON.stringify(e)}get detailTopTooltips(){return this.psaTooltipsDescription}get detailTopIcons(){return w}get hasSystemLabels(){return E(this)}get filteredSystemLabels(){return Object.entries(this.labels).reduce((e,[t,n])=>(b.includes(t)||(e[t]=n),e),{})}get systemLabels(){return S(this)}get psaTooltipsDescription(){return x(this)}cleanForNew(){const e=this.metadata?.labels?.[i.yl];super.cleanForNew(),e&&(this.metadata=this.metadata||{},this.metadata.labels=this.metadata.labels||{},this.metadata.labels[i.yl]=e)}get hideDetailLocation(){const e=this.$rootGetters["currentProduct"];return!e||!!e.hideNamespaceLocation}get glance(){const e=[...this._glance],t=e.findIndex(e=>"namespace"===e.name);t>-1&&e.splice(t,1,this.projectGlance);const n=this.$rootGetters["productId"];if(n===u.o){const t=h.Ay.helper.clustersLocal.some(e=>e.id===o.d_),n=e.findIndex(e=>"type"===e.name);!t&&n>-1&&(e[n]={...e[n],formatter:void 0,formatterOpts:void 0})}return e.filter(Boolean)}get projectGlance(){if(this.project)return{name:"project",label:this.t("component.resource.detail.glance.project"),formatter:"Link",formatterOpts:{to:this.project.detailLocation,row:{},options:{internal:!0}},content:this.project.nameDisplay}}}},1835:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(39975);class i extends r.A{applyDefaults(){this["spec"]={host:"",subsets:[],trafficPolicy:{loadBalancer:{simple:"ROUND_ROBIN"},connectionPool:{tcp:{},http:{}},outlierDetection:{},tls:{}}}}}},67462:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return h},ingressFullPath:function(){return d}});var r=n(35664),i=n(68094),o=n(76978),a=n(3514),s=n.n(a),l=n(39975);function c(e){const t=e.tls||[];return t.flatMap(e=>e.hosts||[])}function u(e,t){return c(e).includes(t)}function d(e,t,n={}){const r=e.spec,i=t.host||"",o=n.path||"";let a="";return i&&(a=u(r,i)?"https://":"http://"),`${a}${i}${o}`}class h extends l.A{get tlsHosts(){return c(this.spec)}get isTlsHost(){return e=>u(this.spec,e)}targetTo(e,t){if(!t)return null;const n=t.startsWith("ingress-"),i=`${this.namespace}/${t}`;if(n){const t=e.find(e=>e.id===i);return t?.detailLocation||""}return{name:"c-cluster-product-resource-namespace-id",params:{resource:r.YV,id:t,namespace:this.namespace}}}createRulesForListPage(e,t){const n=this.spec.rules||[];return n.flatMap(n=>{const r=n?.http?.paths||[];return r.map(r=>this.createPathForListPage(e,n,r,t))})}createPathForListPage(e,t,n,r){const a=(0,o.Jt)(n?.backend,this.serviceNamePath),s=this.fullPath(t,n);return{isUrl:(0,i.AY)(s)&&!s.includes("*"),pathType:n.pathType,fullPath:s,serviceName:a,serviceTargetTo:this.targetTo(e,a),certs:this.certLinks(t,r),targetLink:this.targetLink(e,a),port:(0,o.Jt)(n?.backend,this.servicePortPath)||(0,o.Jt)(n?.backend,this.servicePortNamePath)}}fullPath(e,t){return d(this,e,t)}certLink(e,t=[]){const n=e.secretName||this.t("ingress.rulesAndCertificates.defaultCertificate");let i;return e.secretName&&t.includes(n)&&(i={name:"c-cluster-product-resource-namespace-id",params:{resource:r.bB,id:n}}),{to:i,text:n,options:{internal:!0}}}certLinks(e,t){const n=this.spec.tls||[],r=n.filter(t=>{const n=t.hosts||[];return n.includes(e.host)});return r.map(e=>this.certLink(e,t))}targetLink(e,t){return{to:this.targetTo(e,t),text:t,options:{internal:!0}}}createDefaultService(e){const t=(0,o.Jt)(this.spec,this.defaultBackendPath),n=(0,o.Jt)(t,this.serviceNamePath);return n?{name:n,targetTo:this.targetTo(e,n)}:null}get cache(){return this.cacheObject||(this.cacheObject={}),this.cacheObject}get showPathType(){return this.cache.showPathType||(this.cache.showPathType=this.$rootGetters["cluster/pathExistsInSchema"](this.type,"spec.rules.http.paths.pathType")),this.cache.showPathType}get useNestedBackendField(){return this.cache.useNestedBackendField||(this.cache.useNestedBackendField=this.$rootGetters["cluster/pathExistsInSchema"](this.type,"spec.rules.http.paths.backend.service.name")),this.cache.useNestedBackendField}get serviceNamePath(){const e="service.name",t="serviceName";return this.useNestedBackendField?e:t}get servicePortPath(){const e="service.port.number",t="servicePort";return this.useNestedBackendField?e:t}get servicePortNamePath(){const e="service.port.name",t="servicePort";return this.useNestedBackendField?e:t}get defaultBackendPath(){const e=this.$rootGetters["cluster/pathExistsInSchema"](this.type,"spec.defaultBackend");return e?"defaultBackend":"backend"}get hasDefaultBackend(){return!s()(this.spec[this.defaultBackendPath])}get details(){const e=this._details;return this.spec?.ingressClassName&&e.push({label:this.t("ingress.ingressClass.label"),content:this.spec.ingressClassName}),e}}},80903:function(e,t,n){"use strict";n.r(t),n.d(t,{CLOUD_CREDENTIAL_OVERRIDE:function(){return i},default:function(){return o}});var r=n(81147);const i={nutanix:!0,oci:!0};class o extends r["default"]{get doneRoute(){return"c-cluster-manager-driver-nodedriver"}get parentLocationOverride(){return{name:"c-cluster-manager-driver-nodedriver",params:{cluster:this.$rootGetters["clusterId"]}}}get _availableActions(){const e=[{action:"activate",label:this.t("action.activate"),icon:"icon icon-play",bulkable:!0,bulkAction:"activateBulk",enabled:!!this.actions?.activate&&"inactive"===this.state},{action:"deactivate",label:this.t("action.deactivate"),icon:"icon icon-pause",bulkable:!0,bulkAction:"deactivateBulk",enabled:!!this.actions?.deactivate&&"active"===this.state,weight:-1},{divider:!0},{action:"viewInApi",enabled:!0,icon:"icon icon-external-link",label:this.t("action.viewInApi")},{divider:!0},{action:"goToEdit",label:this.t("action.edit"),icon:"icon icon-edit",bulkable:!1,enabled:!!this.links.update&&!this.builtin},{action:"promptRemove",altAction:"remove",bulkAction:"promptRemove",label:this.t("action.remove"),bulkable:!0,icon:"icon icon-delete",enabled:!!this.links.update&&!this.active,weight:-10}];return e}deactivate(e=[this]){this.$dispatch("promptModal",{componentProps:{drivers:e,driverType:"nodeDrivers"},component:"DeactivateDriverDialog"})}deactivateBulk(e){this.$dispatch("promptModal",{componentProps:{drivers:e,driverType:"nodeDrivers"},component:"DeactivateDriverDialog"})}activate(){return this.$dispatch("rancher/request",{url:`v3/nodeDrivers/${encodeURIComponent(this.id)}?action=activate`,method:"post"},{root:!0}).catch(e=>{this.$dispatch("growl/fromError",{title:this.t("drivers.error.activate",{name:this.nameDisplay}),err:e},{root:!0})})}async activateBulk(e){await Promise.all(e.map(e=>this.$dispatch("rancher/request",{url:`v3/nodeDrivers/${encodeURIComponent(e.id)}?action=activate`,method:"post"},{root:!0}).catch(t=>{this.$dispatch("growl/fromError",{title:this.t("drivers.error.activate",{name:e.nameDisplay}),err:t},{root:!0})})))}}},13070:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return a}});var r=n(35664);const i=[{labelKey:"persistentVolume.awsElasticBlockStore.label",value:"awsElasticBlockStore",supported:!0},{labelKey:"persistentVolume.azureDisk.label",value:"azureDisk",supported:!0},{labelKey:"persistentVolume.azureFile.label",value:"azureFile",supported:!0},{labelKey:"persistentVolume.cephfs.label",value:"cephfs"},{labelKey:"persistentVolume.rbd.label",value:"rbd"},{labelKey:"persistentVolume.csi.label",value:"csi",supported:!0},{labelKey:"persistentVolume.fc.label",value:"fc"},{labelKey:"persistentVolume.flexVolume.label",value:"flexVolume"},{labelKey:"persistentVolume.flocker.label",value:"flocker"},{labelKey:"persistentVolume.glusterfs.label",value:"glusterfs"},{labelKey:"persistentVolume.gcePersistentDisk.label",value:"gcePersistentDisk",supported:!0},{labelKey:"persistentVolume.hostPath.label",value:"hostPath",supported:!0},{labelKey:"persistentVolume.iscsi.label",value:"iscsi"},{labelKey:"persistentVolume.local.label",value:"local",supported:!0},{labelKey:"persistentVolume.longhorn.label",value:"longhorn",supported:!0},{labelKey:"persistentVolume.nfs.label",value:"nfs",supported:!0},{labelKey:"persistentVolume.cinder.label",value:"cinder"},{labelKey:"persistentVolume.photonPersistentDisk.label",value:"photonPersistentDisk"},{labelKey:"persistentVolume.portworxVolume.label",value:"portworxVolume"},{labelKey:"persistentVolume.quobyte.label",value:"quobyte"},{labelKey:"persistentVolume.scaleIO.label",value:"scaleIO"},{labelKey:"persistentVolume.storageos.label",value:"storageos"},{labelKey:"persistentVolume.vsphereVolume.label",value:"vsphereVolume",supported:!0}];i.find(e=>"longhorn"===e.value);var o=n(39975);class a extends o.A{get source(){const e=this.spec?.csi?.driver,t=`${e} ${this.t("persistentVolume.csi.suffix")}`;if(e)return this.$rootGetters["i18n/withFallback"](`persistentVolume.csi.drivers.${e.replaceAll(".","-")}`,null,t);const n=i.find(e=>this.spec[e.value]);return n?this.t(n.labelKey):this.t("generic.unknown")}get isLonghorn(){return this.spec.csi&&this.spec.csi.driver===r.lI}get claim(){return this.name?this.$getters["all"](r.YH).find(e=>e.spec.volumeName===this.name):null}get claimName(){return this.claim?.nameDisplay||this.t("generic.na")}get canDelete(){return"bound"!==this.state}}},17544:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return l}});var r=n(68851),i=n(14220),o=n(39975),a=n(73883),s=n(35664);class l extends o.A{applyDefaults(e,t){const n=t===i.dT?this.spec.accessModes:[],r=t===i.dT?this.spec.resources.requests.storage:null;this["spec"]={accessModes:n,storageClassName:"",volumeName:"",resources:{requests:{storage:r}}}}get bound(){return this.state===a.jv.BOUND}get expandable(){return!!this.$getters["byId"](s.fJ,this.spec?.storageClassName)?.allowVolumeExpansion}get _availableActions(){const e=super._availableActions;return(0,r.PT)(e,0,{divider:!0}),(0,r.PT)(e,0,{action:"goToEditVolumeSize",enabled:this.expandable&&this.bound,icon:"icon icon-plus",label:this.t("persistentVolumeClaim.expand.label")}),e}goToEditVolumeSize(){const e=this.detailLocation;e.query={...e.query,[i.g]:i.G5,[i.AS]:i.xz,[i.L_]:"volumeclaim"},this.currentRouter().push(e)}}},76006:function(e,t,n){"use strict";n.r(t),n.d(t,{WORKLOAD_PRIORITY:function(){return v},default:function(){return y}});var r=n(9274),i=n(68851),o=n(73883),a=n(35664),s=n(92043),l=n(2505),c=n(76978),u=n(11519),d=n(6855),h=n(95265);function p(e,t,n){return(t=f(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function f(e){var t=m(e,"string");return"symbol"==typeof t?t:t+""}function m(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}const g=(0,r.markRaw)((0,r.defineAsyncComponent)(()=>n.e(411).then(n.bind(n,80411)))),v={[a.oU.DEPLOYMENT]:1,[a.oU.CRON_JOB]:2,[a.oU.DAEMON_SET]:3,[a.oU.STATEFUL_SET]:4,[a.oU.JOB]:5,[a.oU.REPLICA_SET]:6,[a.oU.REPLICATION_CONTROLLER]:7},b=(0,r.markRaw)((0,r.defineAsyncComponent)(()=>n.e(714).then(n.bind(n,94714))));class y extends l["default"]{constructor(...e){super(...e),p(this,"_os",void 0)}get inStore(){return this.$rootGetters["currentProduct"].inStore}set os(e){this._os=e}get os(){return this._os?this._os:this?.node?.status?.nodeInfo?.operatingSystem}get node(){try{const e=this.$store.getters["cluster/schemaFor"](a.NW);e&&this.$dispatch("find",{type:a.NW,id:this.spec.nodeName})}catch{}return this.$getters["byId"](a.NW,this.spec.nodeName)}get customValidationRules(){const e=[{nullable:!1,path:"metadata.name",required:!0,translationKey:"generic.name",type:"subDomain"}];return e}get _availableActions(){const e=super._availableActions,t=!!this.$rootGetters["features/get"](h.nR);return(0,i.PT)(e,0,{divider:!0}),(0,i.PT)(e,0,this.openLogsMenuItem),t&&(0,i.PT)(e,0,this.openShellMenuItem),e}get openShellMenuItem(){return{action:"openShell",enabled:!!this.links.view&&this.isRunning,icon:"icon-chevron-right",label:"Execute Shell",total:1}}get openLogsMenuItem(){return{action:"openLogs",enabled:!!this.links.view,icon:"icon icon-chevron-right",label:"View Logs",total:1}}get containerActions(){const e=[],t=!!this.$rootGetters["features/get"](h.nR);return(0,i.PT)(e,0,this.openLogsMenuItem),t&&(0,i.PT)(e,0,this.openShellMenuItem),e}get defaultContainerName(){const e=this.spec.containers,t=e.filter(e=>"istio-proxy"!==e.name);return t.length?t[0].name:e[0]?.name}openShell(e=this.defaultContainerName){this.$dispatch("wm/open",{id:`${this.id}-shell`,label:this.nameDisplay,icon:"terminal",component:"ContainerShell",attrs:{pod:this,initialContainer:e}},{root:!0})}openLogs(e=this.defaultContainerName){this.$dispatch("wm/open",{id:`${this.id}-logs`,label:this.nameDisplay,icon:"file",component:"ContainerLogs",attrs:{pod:this,initialContainer:e}},{root:!0})}containerStateDisplay(e){const t=Object.keys(e.state||{})[0];return(0,o.ch)(t)}containerStateColor(e){const t=Object.keys(e.state||{})[0];return(0,o.uU)(t)}containerIsInit(e){const{initContainers:t=[]}=this.spec;return t.includes(e)}get resourceContainers(){const e=[...this.status?.containerStatuses||[],...this.status?.initContainerStatuses||[]];return e.map(e=>{const t=Object.keys(e.state||{})[0]||"unknown";return{stateDisplay:(0,o.ch)(t),stateSimpleColor:(0,o.Cb)(t)}})}get resourcesCardRows(){const e=[...this._resourcesCardRows];return this.resourceContainers.length&&e.unshift((0,d.G)(this.t("workload.container.titles.containers"),this.resourceContainers,"stateSimpleColor","stateDisplay","#containers")),e}get cards(){return[this.resourcesCard,this.insightCard,...this._cards].filter(e=>e)}get imageNames(){return this.spec.containers.map(e=>(0,s.qO)(e.image))}get workloadRef(){const e=this.getOwners()||[],t=e.filter(e=>Object.values(a.oU).includes(e.type)).sort((e,t)=>{const n=v[e.type],r=v[t.type];return n-r});return t[0]}get ownedByWorkload(){return!!this.workloadRef}get workloadTypeLabel(){const e=this.workloadRef?this.$getters["schemaFor"](this.workloadRef.type):null;return e?this.$rootGetters["type-map/labelFor"](e):this.t("component.resource.detail.glance.workload")}get details(){const e=[{label:this.t("workload.detailTop.podIP"),content:this.status.podIP}];if(this.workloadRef){const t=this.workloadRef.type===a.oU.REPLICA_SET&&!!this.$getters["schemaFor"](a.oU.REPLICA_SET);e.push({label:this.workloadTypeLabel,formatter:"LinkName",formatterOpts:{value:this.workloadRef.name,type:this.workloadRef.type,namespace:this.workloadRef.namespace},content:this.workloadRef.name,valueOverride:t?{component:g,props:{type:this.workloadRef.type,id:this.workloadRef.id,name:this.workloadRef.name,showStatus:!1,detailLocation:{name:"c-cluster-product-resource-namespace-id",params:{product:this.$rootGetters["productId"],cluster:this.$rootGetters["clusterId"],resource:this.workloadRef.type,namespace:this.workloadRef.namespace,id:this.workloadRef.name}}}}:void 0})}return this.spec.nodeName&&e.push({label:"Node",formatter:"LinkName",formatterOpts:{type:a.NW,value:this.spec.nodeName},content:this.spec.nodeName,valueOverride:{component:b,props:{type:a.NW,value:this.spec.nodeName}}}),e}get isRunning(){return"Running"===this.status.phase}get groupByNode(){const e=this.spec?.nodeName||this.$rootGetters["i18n/t"]("generic.none");return this.$rootGetters["i18n/t"]("resourceTable.groupLabel.node",{name:(0,s.ZD)(e)})}get restartCount(){return this.status.containerStatuses&&this.status?.containerStatuses[0].restartCount||0}get kubectlContainerCounts(){const e=(this.spec?.initContainers||[]).filter(e=>"Always"===e.restartPolicy).map(e=>e.name);let t=0,n=0,r=0,i=!1;for(const s of this.status?.initContainerStatuses||[]){const o=e.includes(s.name);if(n+=s.restartCount||0,o&&(r+=s.restartCount||0),0!==s.state?.terminated?.exitCode){if(!o||!s.started){i=!0;break}t+=s.ready?1:0}}const o=(this.status?.conditions||[]).some(e=>"Initialized"===e.type&&"True"===e.status);let a=n;if(!i||o){a=r;for(const e of this.status?.containerStatuses||[])a+=e.restartCount||0,t+=e.ready&&e.state?.running?1:0}return{ready:t,total:(this.spec?.containers?.length||0)+e.length,restarts:a}}get containerReadiness(){const{ready:e,total:t}=this.kubectlContainerCounts;return{ready:e,total:t}}get totalRestartCount(){return this.kubectlContainerCounts.restarts}get restartsCount(){return this.metadata?.fields?.[3]?.match(u.q0)?.[1]||""}get restartsLaster(){return this.metadata?.fields?.[3]?.match(u.q0)?.[2]||""}get glance(){const e=[...this._glance],{ready:t,total:n}=this.containerReadiness,r=this.status?.podIP,i=["Succeeded","Failed"].includes(this.status?.phase),o=[{name:"ready",label:this.t("component.resource.detail.glance.ready"),formatter:"ReadyIndicator",formatterOpts:{ready:t,total:n,status:i?"none":void 0},content:`${t}/${n}`},{name:"restarts",label:this.t("component.resource.detail.glance.restarts"),content:this.totalRestartCount},{name:"podIp",label:this.t("component.resource.detail.glance.podIp"),formatter:r?"CopyToClipboard":void 0,formatterOpts:{plain:!0},content:r||"—"}];this.workloadRef&&o.push({name:"workload",label:this.workloadTypeLabel,formatter:"LinkName",formatterOpts:{value:this.workloadRef.name,type:this.workloadRef.type,namespace:this.workloadRef.namespace},content:this.workloadRef.name}),this.spec?.nodeName&&o.push({name:"node",label:this.t("component.resource.detail.glance.node"),formatter:"LinkName",formatterOpts:{type:a.NW,value:this.spec.nodeName},content:this.spec.nodeName});const s=e.findIndex(e=>"age"===e.name);return e.splice(s>-1?s:e.length,0,...o),e}processSaveResponse(e){if(e._headers&&e._headers.warning){const t=e._headers.warning.split("299")||[],n=t.filter(e=>e.includes("violate PodSecurity")).length;n&&this.$dispatch("growl/warning",{title:this.$rootGetters["i18n/t"]("growl.podSecurity.title"),message:this.$rootGetters["i18n/t"]("growl.podSecurity.message"),timeout:5e3},{root:!0})}}save(){const e={...this};if(this.spec?.template){const{metadata:e,spec:t}=this.spec.template;this.spec={...this.spec,...t},this.metadata={...this.metadata,...e},delete this.spec.template}return this._save(...arguments).catch(t=>(this.spec=e.spec,this.metadata=e.metadata,Promise.reject(t)))}cleanForSave(e){const t=super.cleanForSave(e);return t.spec?.containers?.forEach(e=>{this.cleanContainerForSave(e)}),t.spec?.initContainers?.forEach(e=>{this.cleanContainerForSave(e)}),(0,c.BJ)(t,"spec.selector"),t}}},97219:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return c}});var r=n(36313),i=n.n(r),o=n(4514),a=n(50667),s=n(92043),l=n(89865);class c extends l.A{get avatarSrc(){if("github"===this.provider&&this.profilePicture)return(0,a.R_)(this.profilePicture,"s",80);let e=this.id||"Unknown";e=e.replace(/[^:]+:\/\//,"");const t=(0,o.Fx)(e,"hex"),n=`data:image/png;base64,${new(i())(t,80,.01).toString()}`;return n}get roundAvatar(){return"github"===this.provider}get providerSpecificType(){const e=this.id.replace(/:.*$/,"").split("_",2);return 2===e.length?e[1]:null}get displayType(){const e=this.$rootGetters["i18n/withFallback"](`model.authConfig.provider."${this.provider}"`,null,this.provider);return`${e} ${(0,s.TF)(this.providerSpecificType)}`}}},99493:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(35664),i=n(89865);class o extends i.A{get principalId(){return this.userPrincipalId||this.groupPrincipalId}get roleDisplay(){return this.roleTemplate?.nameDisplay}get roleDescription(){return this.roleTemplate?.description}get roleTemplate(){return this.$rootGetters["management/byId"](r.Mc.ROLE_TEMPLATE,this.roleTemplateId)}get steve(){return this.$dispatch("management/find",{type:r.Mc.PROJECT_ROLE_TEMPLATE_BINDING,id:this.id?.replace(":","/")},{root:!0})}get syncPrincipal(){return this.$rootGetters["rancher/byId"](r.k$.PRINCIPAL,this.principalId)}get nameDisplay(){return this.syncPrincipal?.nameDisplay||super.nameDisplay}}},47685:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return E}});var r=n(35664),i=n(27278),o=n(21342),a=n(39975),s=n(68851),l=n(76978),c=n(83288),u=n(11518),d=n(2841),h=n(9262),p=n(19463),f=n(78474),m=n(20246),g=n.n(m),v=n(9274),b=n(82637),y=n(50025),w=n(4364);const O=["promptRemove","openShell","pinCluster","unpinCluster","downloadKubeConfig","copyKubeConfig","download","viewInApi"],S={PROVISIONING:"provisioning",UNAVAILABLE:"unavailable"};class E extends a.A{isAnnotationIgnored(e){return e!==d.qt.MANAGEMENT_CLUSTER_NAME&&super.isAnnotationIgnored(e)}get allowedSystemAnnotationKeys(){return this.id?[]:[d.qt.MANAGEMENT_CLUSTER_NAME]}get readOnlyAnnotationKeys(){return this.id&&this.metadata?.annotations?.[d.qt.MANAGEMENT_CLUSTER_NAME]?[d.qt.MANAGEMENT_CLUSTER_NAME]:[]}get details(){const e=[{label:this.t("cluster.detail.provisioner"),content:this.provisionerDisplay||this.t("generic.none")},{label:this.t("cluster.detail.machineProvider"),content:this.machineProvider?this.machineProviderDisplay:null},{label:this.t("cluster.detail.kubernetesVersion"),content:this.kubernetesVersion},{label:this.t("cluster.detail.machinePools"),content:this.pools.length},{label:this.t("cluster.detail.machines"),content:this.desired},{label:"Autoscaler",content:this.isAutoscalerEnabled,valueOverride:{component:(0,v.markRaw)((0,v.defineAsyncComponent)(()=>n.e(460).then(n.bind(n,31460)))),props:{value:!0,row:this}}}].filter(e=>!!e.content);return this.machineProvider||e.splice(1,1),e}get creationTimestamp(){const e=Date.parse(this.metadata?.creationTimestamp),t=Date.parse(this.mgmt?.metadata?.creationTimestamp);return t&&t<e?this.mgmt?.metadata?.creationTimestamp:super.creationTimestamp}get canExplore(){return this.mgmt?.canExplore}get canEdit(){return!(this.isKev1||this.isHarvester||this.isCapiWithoutExtension)&&super.canEdit}get canCustomEdit(){return!this.isCapiWithoutExtension&&super.canCustomEdit}get _availableActions(){const e=super._availableActions,t=this.mgmt?.isLocal;if(t){const t=e.findIndex(e=>"promptRemove"===e.action);t>-1&&e.splice(t,1)}const n=this.mgmt?.isReady,r=n&&this.isDayTwoOpsEnabled&&this.canUpdate,i=this.isRke2&&n&&this.canUpdate,o=!!this.mgmt&&!t,a=[{action:"pinCluster",bulkAction:"pinClusterBulk",label:this.t("cluster.pinAction"),icon:"icon icon-pin flip-x",bulkable:!0,enabled:o&&!this.mgmt.pinned,weight:2},{action:"unpinCluster",bulkAction:"unpinClusterBulk",label:this.t("cluster.unpinAction"),icon:"icon icon-pin-outlined flip-x",bulkable:!0,enabled:o&&this.mgmt.pinned,weight:1},{action:"openShell",label:this.$rootGetters["i18n/t"]("nav.shell"),icon:"icon icon-terminal",enabled:!!this.mgmt?.links.shell&&n},{action:"downloadKubeConfig",bulkAction:"downloadKubeConfigBulk",label:this.$rootGetters["i18n/t"]("nav.kubeconfig.download"),icon:"icon icon-download",bulkable:!0,enabled:this.mgmt?.canCreateKubeconfig},{action:"copyKubeConfig",bulkAction:"copyKubeConfigBulk",label:this.t("cluster.copyConfig"),bulkable:!0,enabled:this.mgmt?.canCreateKubeconfig,icon:"icon icon-copy"},{action:"snapshotAction",label:this.$rootGetters["i18n/t"]("nav.takeSnapshot"),icon:"icon icon-snapshot",bulkAction:"snapshotBulk",bulkable:!0,enabled:r},{action:"restoreSnapshotAction",label:this.$rootGetters["i18n/t"]("nav.restoreSnapshot"),icon:"icon icon-backup-restore",enabled:r},{action:"rotateCertificates",label:this.$rootGetters["i18n/t"]("nav.rotateCertificates"),icon:"icon icon-backup",enabled:i||this.mgmt?.hasAction("rotateCertificates")&&n},{action:"rotateEncryptionKey",label:this.$rootGetters["i18n/t"]("nav.rotateEncryptionKeys"),icon:"icon icon-refresh",enabled:r},{action:"toggleAutoscalerRunner",label:this.isAutoscalerPaused?"Resume Autoscaler":"Pause Autoscaler",icon:"icon "+(this.isAutoscalerPaused?"icon-play":"icon-pause"),enabled:this.canPauseResumeAutoscaler},{divider:!0}],s=a.concat(e);if(this.isKev1||this.isHarvester){const e=s.find(e=>"goToEdit"===e.action);e&&(e.enabled=!1)}return this.isRke1&&s.forEach(e=>{e.divider||O.includes(e.action)||(e.enabled=!1)}),this.customProvisionerHelper?.availableActions&&this.customProvisionerHelper?.availableActions(this,s)||s}get detailLocation(){if(!this.isKev1)return super.detailLocation}get normanCluster(){return this.mgmt?.normanCluster}async findNormanCluster(){return this.mgmt?.findNormanCluster()}explore(){const e={name:"c-cluster",params:{cluster:this.mgmt.id}};this.currentRouter().push(e)}async goToHarvesterCluster(){return this.mgmt?.goToHarvesterCluster()}get canDelete(){return super.canDelete&&"removing"!==this.stateObj?.name}get canEditYaml(){return!!this.isRke2&&super.canEditYaml}get isHostedKubernetesProvider(){return this.mgmt?.isHostedKubernetesProvider}get providerConfig(){return this.isRke2?this.spec.rkeConfig:this.mgmt&&this.mgmt.config?this.mgmt.config:null}get isPrivateHostedProvider(){return this.mgmt?.isPrivateHostedProvider||!1}get isLocal(){return this.mgmt?.isLocal}get isKev1(){return this.mgmt?.isKev1}get isImported(){return!this.isLocal&&this.mgmt?.isImported}get isCustom(){return this.mgmt?.isCustom}get confirmRemove(){return!0}get isImportedK3s(){return this.mgmt?.isImportedK3s}get isImportedRke2(){return this.mgmt?.isImportedRke2}get isImportedRke2K3s(){return this.isImportedRke2||this.isImportedK3s}get isDayTwoOpsEnabled(){return!(!this.isRke2&&!this.isImportedWithDayTwoOps)}get isDayTwoOpsFeatureEnabled(){return this.$rootGetters["management/byId"](r.Mc.FEATURE,u.IY)?.enabled||!1}get isImportedWithDayTwoOps(){const e="undefined"!==typeof this.mgmt?.metadata?.annotations?.[d.P0.ENABLED],t="true"===this.mgmt?.metadata?.annotations?.[d.P0.ENABLED],n="true"===this.$rootGetters["management/byId"](r.Mc.SETTING,h.HG.IMPORTED_CLUSTER_DAY2_OPS_DEFAULT)?.value,i=t||!e&&n,o=this.$getters["schemaFor"](r.qR.ETCD_SNAPSHOT);return!this.isLocal&&o&&this.isDayTwoOpsFeatureEnabled&&this.isImportedRke2K3s&&i}get isK3s(){return this.mgmt?this.mgmt.isK3s:(this.spec?.kubernetesVersion||"").includes("k3s")}get isRke2(){return!!this.spec?.rkeConfig}get isRke1(){return!1}get isHarvester(){return!!this.mgmt?.isHarvester}get isCapiWithoutExtension(){return this.mgmt?.isCapiHybrid&&!this.mgmt?.isCAPIProvider}get mgmtClusterId(){if(this.status?.clusterName)return this.status.clusterName;const e=this.$rootGetters["management/byId"](r.Z7.RANCHER_CLUSTER,this.id);return e?.status?.clusterName}get mgmt(){return this.$rootGetters["management/byId"](r.Mc.CLUSTER,this.mgmtClusterId)}get isReady(){return!!this.mgmt?.isReady}get eksNodeGroups(){return this.mgmt?.eksNodeGroups||[]}waitForProvisioner(e,t){return this.waitForTestFn(()=>!!this.provisioner,"set provisioner",e,t)}waitForMgmt(e=6e4,t){return this.waitForTestFn(()=>{const e=this.mgmtClusterId;try{e&&this.$dispatch("find",{type:r.Mc.CLUSTER,id:e})}catch{}return e&&!!this.$rootGetters["management/byId"](r.Mc.CLUSTER,e)},this.$rootGetters["i18n/t"]("cluster.managementTimeout",{type:r.Mc.CLUSTER,name:this.mgmtClusterId}),e,t)}get provisioner(){return this.mgmt?.provisioner}get provisionerDisplay(){return this.mgmt?.provisionerDisplay}get providerLogo(){return this.mgmt?.providerLogo}get architecture(){return this.mgmt?.architecture}get kubernetesVersion(){return this.mgmt?.kubernetesVersion}get machineProvider(){return this.mgmt?.machineProvider?.toLowerCase()}get machineProviderDisplay(){return this.mgmt?.machineProviderDisplay}get machinePoolDefaults(){return this.spec.rkeConfig?.machinePoolDefaults}set defaultHostnameLengthLimit(e){this.spec.rkeConfig=this.spec.rkeConfig||{},this.spec.rkeConfig.machinePoolDefaults=this.spec.rkeConfig.machinePoolDefaults||{},this.spec.rkeConfig.machinePoolDefaults.hostnameLengthLimit=e}get defaultHostnameLengthLimit(){return this.spec.rkeConfig?.machinePoolDefaults?.hostnameLengthLimit}removeDefaultHostnameLengthLimit(){this.machinePoolDefaults?.hostnameLengthLimit&&(delete this.spec.rkeConfig.machinePoolDefaults.hostnameLengthLimit,0===Object.keys(this.spec?.rkeConfig?.machinePoolDefaults).length&&delete this.spec.rkeConfig.machinePoolDefaults)}get nodes(){return this.mgmt?.nodes||[]}get machines(){return this.mgmt?.machines||[]}get displayName(){return this.mgmt?.nameDisplay||null}get pools(){return this.mgmt?.pools||[]}get desired(){return this.mgmt?.desired||0}get pending(){return this.mgmt?.pending||0}get outdated(){return this.mgmt?.outdated||0}get ready(){return this.mgmt?.ready||0}get unavailable(){return this.mgmt?.unavailable||0}get unavailableMachines(){return this.mgmt?.unavailableMachines||""}get stateParts(){return this.mgmt?.stateParts}async getOrCreateToken(){if(await this.waitForMgmt(),!this.mgmt)return;const e=await this.$dispatch("rancher/findAll",{type:r.k$.CLUSTER_TOKEN,force:!0},{root:!0});let t=(0,s.jq)(e,"clusterId",this.mgmt.id);return t||(this.links.update?(t=await this.$dispatch("rancher/create",{type:r.k$.CLUSTER_TOKEN,clusterId:this.mgmt.id},{root:!0}),t.save()):void 0)}openShell(){return this.mgmt?.openShell()}generateKubeConfig(){return this.mgmt?.generateKubeConfig()}async copyKubeConfig(){await(this.mgmt?.copyKubeConfig()),this.$dispatch("growl/info",{title:this.t("cluster.copiedConfig"),timeout:3e3},{root:!0})}downloadKubeConfig(){return this.mgmt?.downloadKubeConfig()}downloadKubeConfigBulk(e){return this.mgmt?.downloadKubeConfigBulk(e)}copyKubeConfigBulk(e){return this.mgmt?.copyKubeConfigBulk(e)}reportPin(e){const t=(e,t)=>this.$dispatch(e,t,{root:!0});return(0,f.Vc)({dispatch:t},this.t,e)}pinCluster(){return this.reportPin(this.mgmt?.pin())}unpinCluster(){return this.reportPin(this.mgmt?.unpin())}pinClusterBulk(e){return this.reportPin(this.mgmt?.pinBulk(e))}unpinClusterBulk(e){return this.reportPin(this.mgmt?.unpinBulk(e))}async snapshotAction(){try{await this.takeSnapshot(),this.$dispatch("growl/info",{title:this.$rootGetters["i18n/t"]("cluster.snapshot.successTitle",{name:this.nameDisplay}),message:this.$rootGetters["i18n/t"]("cluster.snapshot.successMessage",{name:this.nameDisplay})},{root:!0})}catch(e){this.$dispatch("growl/fromError",{title:this.$rootGetters["i18n/t"]("cluster.snapshot.errorTitle",{name:this.nameDisplay}),err:e},{root:!0})}}async snapshotBulk(e){const t=await Promise.allSettled(e.map(e=>e.takeSnapshot())),n=t.filter(e=>"fulfilled"===e.status).length;n&&this.$dispatch("growl/info",{title:this.$rootGetters["i18n/t"]("cluster.snapshot.bulkSuccessTitle"),message:this.$rootGetters["i18n/t"]("cluster.snapshot.bulkSuccessMessage",{count:n})},{root:!0});for(let r=0;r<t.length;r++)"fulfilled"!==t[r].status&&this.$dispatch("growl/fromError",{title:this.$rootGetters["i18n/t"]("cluster.snapshot.errorTitle",{name:e[r].nameDisplay}),err:t[r].value},{root:!0})}takeSnapshot(){if(this.isRke1)return this.$dispatch("rancher/request",{url:`/v3/clusters/${escape(this.mgmt.id)}?action=backupEtcd`,method:"post"},{root:!0});if(this.isImportedWithDayTwoOps){const e=this.mgmt?.id,t=this.mgmt?.metadata?.name||this.mgmt?.id,n={clusterRef:{apiVersion:"management.cattle.io/v3",kind:"Cluster",name:this.mgmt?.id}};return(0,p.l)(this.$dispatch,r.qR.ETCD_SNAPSHOT,n,e,t)}if(this.isImportedRke2K3s&&!this.isDayTwoOpsFeatureEnabled)throw new Error(this.$rootGetters["i18n/t"]("cluster.snapshot.day2OpsNotEnabled"));{const e=this.spec?.rkeConfig?.etcdSnapshotCreate?.generation||0,t={generation:e+1};return this.spec?.rkeConfig?.etcd?.s3&&(t.s3=this.spec.rkeConfig.etcd.s3),(0,l.hZ)(this.spec.rkeConfig,"etcdSnapshotCreate",t),this.save()}}get etcdSnapshots(){const e=this.$rootGetters["management/all"]({type:r.xO});return this.isImportedWithDayTwoOps?e.filter(e=>e.metadata.namespace===this.mgmt?.id&&e.spec?.clusterName===this.mgmt?.metadata?.name):e.filter(e=>e.metadata.namespace===this.namespace&&e.clusterName===this.name)}restoreSnapshotAction(e=this){this.$dispatch("promptRestore",[e])}rotateCertificates(e=this){this.$dispatch("promptModal",{componentProps:{cluster:e},component:"RotateCertificatesDialog"})}rotateEncryptionKey(e=this){this.$dispatch("promptModal",{componentProps:{cluster:e},component:"RotateEncryptionKeyDialog"})}get stateObj(){return this._stateObj}get _stateObj(){return this.isRke2?this.metadata?.state:this.mgmt?.stateObj||this.metadata?.state}get supportsWindows(){if(this.isK3s||this.isImportedK3s)return!1;if(this.isRke1)return this.mgmt?.spec?.windowsPreferedCluster||!1;if(!this.isRke2)return!1;if(!this.kubernetesVersion||(0,c.UD)(this.kubernetesVersion,"v1.21.0")<0)return!1;const e=this.spec?.rkeConfig?.machineGlobalConfig?.cni;return!("flannel"===e&&(0,c.UD)(this.kubernetesVersion,"v1.29.2")<0)&&(!e||"calico"===e||"flannel"===e)}get customValidationRules(){return[{path:"metadata.name",translationKey:"cluster.name.label",validators:[`clusterName:${this.isRke2}`],maxLength:63}]}get agentConfig(){return this.spec.rkeConfig?.machineSelectorConfig?.find(e=>!e.machineLabelSelector)?.config||{}}get cloudProvider(){return this.agentConfig?.["cloud-provider-name"]}get canClone(){return!1}async remove(e={}){e.url||(e.url=(this.links||{})["self"]),e.method="delete";const t=await this.$dispatch("request",e),n=(this.spec?.rkeConfig?.machinePools||[])[0];if("HarvesterConfig"===n?.machineConfigRef?.kind){const e=this.spec.cloudCredentialSecretName;await this.$dispatch("rancher/findAll",{type:r.k$.CLOUD_CREDENTIAL},{root:!0});const t=this.$rootGetters["rancher/byId"](r.k$.CLOUD_CREDENTIAL,e);if(t){const e=(0,l.Jt)(t,"decodedData.clusterId");try{const t=await this.$dispatch("management/find",{type:`${r.Z7.MACHINE_CONFIG_GROUP}.${(n?.machineConfigRef?.kind||"").toLowerCase()}`,id:`${this.metadata.namespace}/${n?.machineConfigRef?.name}`},{root:!0});await this.$dispatch("management/request",{url:`/k8s/clusters/${e}/v1/harvester/serviceaccounts/${t.vmNamespace}/${this.metadata.name}`,method:"DELETE"},{root:!0})}catch(i){w.error(i)}}}if(204===t?._status&&await this.$dispatch("ws.resource.remove",{data:this}),this.customProvisionerHelper?.postDelete)return this.customProvisionerHelper?.postDelete(this)}get customProvisionerHelper(){return this.modelExtensions.find(e=>!!e.useFor&&e.useFor(this))}get groupByParent(){return this.customProvisionerHelper?.parentCluster?.(this)||this.t("resourceTable.groupLabel.notInACluster")}get hasError(){return!this.mgmt||this.mgmt.hasError}get namespaceLocation(){const e=o.Ay.helper.clustersLocal.some(e=>e.id===r.d_);return e?{name:"c-cluster-product-resource-id",params:{cluster:r.d_,product:i.o,resource:r.CU,id:this.namespace}}:null}get commentFieldsOptions(){return this.isRke2?[{path:"spec.rkeConfig.machineGlobalConfig",key:"profile"}]:null}get yamlFolding(){return["spec.rkeConfig.machinePools.dynamicSchemaSpec"]}get description(){return super.description||this.mgmt?.description}get disableResourceDetailDrawerConfigTab(){return!!this.isHarvester||this.isCapiWithoutExtension}get fullDetailPageOverride(){return!0}async loadAutoscalerEvents(){const e=await this.loadAutoscalerConfigMap(),t=this.$rootGetters["management/schemaFor"](r.ll),n=[new y.Js({field:"involvedObject.uid",value:e.metadata.uid,exact:!0}),new y.Js({field:"metadata.namespace",value:"kube-system",exact:!0})],i={page:1,pageSize:200,filters:[new y.eY({fields:n})]},o=b.A.createParamsForPagination({schema:t,opt:{pagination:i}}),a=`/k8s/clusters/${this.mgmtClusterId}/v1/${r.ll}?${o}`,s=(await this.$dispatch("cluster/request",{url:a},{root:!0}))?.data||[];return s.filter(e=>"cluster-autoscaler-status"===e.involvedObject.name)}get hasAccessToAutoscalerConfigMap(){return this.canEdit}async loadAutoscalerConfigMap(){const e=`/k8s/clusters/${this.mgmtClusterId}/v1/${r.K5}/${r.w3}`;return await this.$dispatch("cluster/request",{url:e},{root:!0})}get canPauseResumeAutoscaler(){return this.isAutoscalerEnabled&&this.canExplore&&this.hasAccessToAutoscalerConfigMap}async loadAutoscalerStatus(){if(!this.canExplore)return S.PROVISIONING;if(!this.hasAccessToAutoscalerConfigMap)return S.UNAVAILABLE;try{const e=await this.loadAutoscalerConfigMap(),t=e?.data?.status||"";return g().load(t)}catch(e){return w.error(e),S.UNAVAILABLE}}async loadAutoscalerDetails(){const e=[];if(this.isAutoscalerPaused)return e.push({label:this.t("autoscaler.card.details.status"),value:this.t("autoscaler.card.details.paused")}),e;const t=await this.loadAutoscalerStatus();if(t===S.UNAVAILABLE)return e.push({label:this.t("autoscaler.card.details.status"),value:this.t("autoscaler.card.details.unavailable")}),e;if(t===S.PROVISIONING)return e.push({label:this.t("autoscaler.card.details.status"),value:this.t("autoscaler.card.details.provisioning")}),e;if(t.autoscalerStatus&&e.push({label:this.t("autoscaler.card.details.status"),value:t.autoscalerStatus}),t.clusterWide?.health?.status){const n=t.clusterWide.health.status;e.push({label:this.t("autoscaler.card.details.health"),value:{component:"BadgeStateFormatter",props:{value:n,arbitrary:!0,row:{}}}})}return t.clusterWide?.scaleDown?.lastTransitionTime&&e.push({label:this.t("autoscaler.card.details.scaleDown"),value:{component:"LiveDate",props:{value:t.clusterWide.scaleDown.lastTransitionTime,addSuffix:!0}}}),t.clusterWide?.scaleUp?.lastTransitionTime&&e.push({label:this.t("autoscaler.card.details.scaleUp"),value:{component:"LiveDate",props:{value:t.clusterWide.scaleUp.lastTransitionTime,addSuffix:!0}}}),t.clusterWide?.health?.nodeCounts?.registered&&(e.push({label:this.t("autoscaler.card.details.nodes")}),e.push({label:this.t("autoscaler.card.details.ready"),value:t.clusterWide.health.nodeCounts.registered.ready||"0"}),e.push({label:this.t("autoscaler.card.details.notStarted"),value:t.clusterWide.health.nodeCounts.registered.notStarted||"0"}),e.push({label:this.t("autoscaler.card.details.inTotal"),value:t.clusterWide.health.nodeCounts.registered.total||"0"})),e}get isAutoscalerEnabled(){return this.mgmt?.isAutoscalerEnabled}get isAutoscalerPaused(){return!!this.metadata?.annotations?.[d.qt.AUTOSCALER_CLUSTER_PAUSE]}pauseAutoscaler(){this.setAnnotation(d.qt.AUTOSCALER_CLUSTER_PAUSE,"true")}resumeAutoscaler(){this.setAnnotation(d.qt.AUTOSCALER_CLUSTER_PAUSE,void 0)}toggleAutoscalerRunner(){return this.isAutoscalerPaused?this.resumeAutoscaler():this.pauseAutoscaler(),this.save()}}},8324:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return a}});var r=n(4799),i=n(68851),o=n(51700);class a extends o["default"]{get subtype(){return r.SUBTYPE_MAPPING.RBAC_CLUSTER_ROLE.key}get namespaceResources(){return this.allResources.filter(e=>e.attributes.namespaced&&!e.attributes.group.includes(r.CATTLE_API_GROUP))}get resources(){return(0,i.sb)(this.namespaceResources.map(e=>e.attributes?.kind)).sort()}}},69791:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(82614),i=n(35664);class o extends r.A{get users(){return this.subjects?.filter(({kind:e})=>e?.toLowerCase()===i.m3)}get serviceAccounts(){return this.subjects?.filter(({kind:e})=>e?.toLowerCase()===i.Sg)}get groups(){return this.subjects?.filter(({kind:e})=>e?.toLowerCase()===i.UP)}}},51700:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return s}});var r=n(35664),i=n(4799),o=n(68851),a=n(39975);class s extends a.A{get customValidationRules(){return[{path:"name",translationKey:"nameNsDescription.name.label",required:!0,nullable:!1,type:"string"},{path:"rules",validators:[`roleTemplateRules:${this.type}`],nullable:!1,type:"array"}]}get nameWithinProduct(){return this.$rootGetters["i18n/withFallback"](`rbac.displayRole.${this.name}`,this.name)}get subtype(){return i.SUBTYPE_MAPPING.RBAC_ROLE.key}get allResources(){return this.$getters["all"](r.yx).filter(e=>e.attributes?.kind)}get clusterResources(){return this.allResources.filter(e=>!e.attributes.namespaced&&!e.attributes.group.includes(i.CATTLE_API_GROUP))}get resources(){return(0,o.sb)(this.clusterResources.map(e=>e.attributes?.kind)).sort()}set displayName(e){this.metadata.name=e}get displayName(){return this.metadata?.name}}},559:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(82614),i=n(35664);class o extends r.A{get users(){return this.subjects.filter(({kind:e})=>e?.toLowerCase()===i.m3)}get serviceAccounts(){return this.subjects.filter(({kind:e})=>e?.toLowerCase()===i.Sg)}get groups(){return this.subjects.filter(({kind:e})=>e?.toLowerCase()===i.UP)}}},12299:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(70775);class i extends r["default"]{}},89713:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return s}});var r=n(73883),i=n(68851),o=n(76978),a=n(39975);class s extends a.A{get readyMessage(){const e=(0,o.Jt)(this,"status.conditions"),t=((0,i.jq)(e,"type","Ready")||{}).message;return t}get colorForState(){return this.readyMessage?(0,r.uU)(this.readyMessage):(0,r.uU)()}get stateDisplay(){return this.readyMessage?(0,r.ch)(this.readyMessage):(0,r.ch)()}}},23741:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return s}});var r=n(73883),i=n(68851),o=n(76978),a=n(39975);class s extends a.A{get canUpdate(){return this?.metadata?.state?.error}get readyMessage(){const e=(0,o.Jt)(this,"status.conditions"),t=((0,i.jq)(e,"type","Ready")||{}).message;return t}get colorForState(){return this.readyMessage?(0,r.uU)(this.readyMessage):(0,r.uU)()}get stateDisplay(){return this.readyMessage?(0,r.ch)(this.readyMessage):(0,r.ch)()}}},81689:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return l}});var r=n(46108),i=n.n(r),o=n(82451),a=n.n(o),s=n(39975);class l extends s.A{applyDefaults(e,t){const n=i()(t);if(n[e]){const t=n[e]?.config;delete t.id,delete t.links,delete t.metadata,delete t.apiVersion,a()(this,t)}}}},39651:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(38799);class i extends r["default"]{get provider(){return"amazonec2"}get providerLocation(){return`${this.spec.template.spec.region}${this.spec.template.spec.zone}`}get providerSize(){return this.spec.template.spec.instanceType}}},79144:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(38799);class i extends r["default"]{get provider(){return"azure"}get providerLocation(){return this.spec.template.spec.location}get providerSize(){return this.spec.template.spec.size}}},81593:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(38799);class i extends r["default"]{get provider(){return"digitalocean"}get providerLocation(){return this.spec.template.spec.region}get providerSize(){return this.spec.template.spec.size}}},69770:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(38799);class i extends r["default"]{get provider(){return"linode"}get providerLocation(){return this.spec.template.spec.region}get providerSize(){return this.spec.template.spec.instanceType}}},38799:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(39975);class i extends r.A{get nameDisplay(){return this.name.replace(`${this.metadata.annotations["objectset.rio.cattle.io/owner-name"]}-`,"")}get provider(){return null}get providerLocation(){return null}get providerSize(){return null}}},82186:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(38799);class i extends r["default"]{get provider(){return"pnap"}get providerLocation(){return this.spec.template.spec.serverLocation}get providerSize(){return this.spec.template.spec.serverType}}},38816:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return a}});var r=n(95799),i=n(38799);const o=/\/host\/([^/]+)\/Resources(?:\/|$)/;class a extends i["default"]{get provider(){return"vmwarevsphere"}get providerLocation(){const e=this.spec?.template?.spec?.pool,t=e?.match(o);return t?.[1]||null}get providerSize(){const e=(0,r.Mo)(1048576*this.spec.template.spec.memorySize,1024,"iB");return`${e}, ${this.spec.template.spec.cpuCount} Core`}}},7100:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return u}});var r=n(89865),i=n(2841),o=n(35664),a=n(76978),s=n(4514),l=n(92043),c=n(73883);class u extends r.A{get _availableActions(){return[{action:"promptRestore",enabled:this.restoreEnabled,icon:"icon icon-backup-restore",label:"Restore"}]}promptRestore(){this.$dispatch("promptRestore",[this])}get clusterName(){return this.metadata.labels[i.xO.CLUSTER_NAME]}get clusterId(){return this.cluster?.id}get name(){return this.metadata.name}get cluster(){const e=this.metadata?.namespace||o.eo;return this.$rootGetters["management/byId"](o.Z7.RANCHER_CLUSTER,`${e}/${this.clusterName}`)}get rke2(){return this.cluster?.isRke2}get nameDisplay(){return this.snapshotFile?.name||this.name}get restoreEnabled(){return this.snapshotFile?.status===c.jv.SUCCESSFUL&&!this.isSnapshotTooOld}get isSnapshotTooOld(){return this.snapshotFile?.createdAt<=this.cluster?.metadata?.creationTimestamp}get errorMessage(){const e=(0,a.Jt)(this,"snapshotFile.status")===c.jv.FAILED;return e?(0,s.u)(this.snapshotFile?.message):null}get stateDescription(){const e=this.stateObj?.transitioning||!1,t=this.stateObj?.error||this.snapshotFile?.status===c.jv.FAILED||!1,n=this.stateObj?.message,r=this.snapshotFile?.status===c.jv.FAILED?(0,s.u)(this.snapshotFile?.message):null;return e||t?r||(0,l.TF)(n):""}get backupLocation(){return this.metadata?.annotations?.["etcdsnapshot.rke.io/storage"]}}},2334:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i},parseType:function(){return a}});var r=n(73883);class i extends r.Ay{get groupName(){return this.attributes.namespaced?"ns":"cluster"}get canGet(){return this.hasLink("collection")}get canList(){return this.hasLink("collection")}}const o=/([^[\s]*)(\[(.*)\])?/;function a(e,t){const n=o.exec(e),r=n[3]||t?.subtype,i=[n[1]];return r&&i.push(r),i}},1133:function(e,t,n){"use strict";n.r(t),n.d(t,{TYPES:function(){return E},default:function(){return _}});var r=n(39198),i=n(2841),o=n(17259),a=n(4514),s=n(68851),l=n(35664),c=n(14220),u=n(76978),d=n(47034),h=n(39975),p=n(73883),f=n(51481),m=n(23464),g=n.n(m),v=n(22915),b=n(10213),y=n(92043);function w(e,t,n){return(t=O(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function O(e){var t=S(e,"string");return"symbol"==typeof t?t:t+""}function S(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}const E={OPAQUE:"Opaque",SERVICE_ACCT:"kubernetes.io/service-account-token",DOCKER:"kubernetes.io/dockercfg",DOCKER_JSON:"kubernetes.io/dockerconfigjson",BASIC:"kubernetes.io/basic-auth",SSH:"kubernetes.io/ssh-auth",TLS:"kubernetes.io/tls",BOOTSTRAP:"bootstrap.kubernetes.io/token",ISTIO_TLS:"istio.io/key-and-cert",HELM_RELEASE:"helm.sh/release.v1",FLEET_CLUSTER:"fleet.cattle.io/cluster-registration-values",CLOUD_CREDENTIAL:"provisioning.cattle.io/cloud-credential",RKE_AUTH_CONFIG:"rke.cattle.io/auth-config"},x=6912e5;class _ extends h.A{constructor(...e){super(...e),w(this,"_cachedCertInfo",void 0)}get hasSensitiveData(){return!0}get isCertificate(){return this._type===E.TLS}get isRegistry(){return this._type===E.DOCKER_JSON}get isCloudCredential(){return this._type===E.CLOUD_CREDENTIAL||"cattle-global-data"===this.metadata.namespace&&"cc-"===this.metadata.generateName}get supportsSshKnownHosts(){return this._type===E.SSH&&!!this.data&&"known_hosts"in this.data}get isGithubApp(){return this._type===E.OPAQUE&&!!this.data&&o.u.APP_ID in this.data&&o.u.INSTALLATION_ID in this.data&&o.u.PRIVATE_KEY in this.data}get issuer(){const{metadata:{annotations:e={}}}=this;return e[i.G5.ISSUER]?e[i.G5.ISSUER]:this.isCertificate?this.cachedCertInfo?.issuer:null}get notAfter(){return this.isCertificate?this.cachedCertInfo?.notAfter:null}get cn(){return this.isCertificate?this.cachedCertInfo?.cn:null}get plusMoreNames(){return this.isCertificate?this.unrepeatedSans.length:null}get dateClass(){if(this.isCertificate)switch(this.certState){case p.jv.EXPIRING:return"text-warning";case p.jv.EXPIRED:return"text-error";default:return""}return null}get details(){const e=[{label:this.t("secret.type"),content:this._type}];if(this._type===E.SERVICE_ACCT){const t=this.metadata?.annotations?.[i.pS.SERVICE_ACCOUNT_NAME];t&&e.push({label:"Service Account",formatter:"LinkName",formatterOpts:{value:t,type:l.Sg,namespace:this.namespace},content:t})}return this.cn&&e.push({label:this.t("secret.certificate.cn"),content:this.plusMoreNames?`${this.cn} ${this.t("secret.certificate.plusMore",{n:this.plusMoreNames})}`:this.cn}),this.issuer&&e.push({label:this.t("secret.certificate.issuer"),content:this.issuer}),this.notAfter&&e.push({label:"Expires",formatter:"Date",formatterOpts:{class:this.dateClass},content:this.notAfter}),e}get canUpdate(){return!this.isProjectSecretCopy&&(!!this.hasLink("update")&&(this._type!==E.SERVICE_ACCT&&this.$rootGetters["type-map/optionsFor"](this.type).isEditable))}get canDelete(){return!this.isProjectSecretCopy&&super.canDelete}get canCreate(){return!this.isProjectSecretCopy&&super.canCreate}get canEditYaml(){return!this.isProjectSecretCopy&&super.canEditYaml}get keysDisplay(){const e=[...Object.keys(this.data||[]),...Object.keys(this.binaryData||[])];return e.length?e.join(", "):"(none)"}get dataPreview(){if(this._type===E.DOCKER_JSON){const t=this.data[".dockerconfigjson"];if(t){const n=(0,a.u)(t);try{const e=JSON.parse(n).auths,t=[];for(const n in e)t.push(n);return t.join(", ")}catch(e){return n}}}else{if(this._type===E.TLS)return this.certInfo||this.keysDisplay;if(this._type===E.BASIC)return(0,a.u)(this.data.username);if(this._type===E.SSH)return this.sshUser;if(this._type===E.SERVICE_ACCT)return this.metadata?.annotations?.["kubernetes.io/service-account.name"];if(this.isGithubApp){const e=(0,a.u)(this.data[o.u.APP_ID]),t=(0,a.u)(this.data[o.u.INSTALLATION_ID]);return`${e} / ${t}`}}return this.keysDisplay}get sshUser(){if(this._type!==E.SSH)return null;const e=(0,a.u)(this.data["ssh-publickey"]);if(!e)return null;if(e.startsWith("----")){const t=e.match(/from OpenSSH by ([^"]+)"/);if(t)return t[1]}else if(e.startsWith("ssh-")){const t=e.replace(/\n/g,"").split(/\s+/);if(t&&3===t.length)return t[2]}return null}get subTypeDisplay(){const e=this._type||"";if(this.isGithubApp)return this.$rootGetters["i18n/withFallback"]("secret.githubApp.label",null,"GitHub App");const t=e.replace(/^kubernetes.io\//,"");return this.$rootGetters["i18n/withFallback"](`secret.types."${e}"`,null,t)}get certInfo(){const e=(0,a.u)(this.data["tls.crt"]);let t,n,i,o,s,l;const c="-----END CERTIFICATE-----";if(e){const a=e.split(c);let d=e;a.length>1&&(d=`${a[0]}${c}`);try{l=new r.X509,l.readCertPEM(d);const e=l.getIssuerString();t=e.slice(e.indexOf("CN=")+3),n=r.zulutodate(l.getNotBefore()),i=r.zulutodate(l.getNotAfter());const a=l.getSubjectString();o=a.slice(a.indexOf("CN=")+3)}catch{return null}try{s=l.getExtSubjectAltName()}catch(u){s=[]}const h={issuer:t,notBefore:n,notAfter:i,cn:o,sans:s};return h}return null}get cachedCertInfo(){return this._cachedCertInfo||(this._cachedCertInfo=this.certInfo),this._cachedCertInfo}get unrepeatedSans(){if(this._type===E.TLS){const e=this.cachedCertInfo;if(e?.sans?.filter){const t=e?.sans.filter(e=>0===e.indexOf("*.")||0===e.indexOf("www.")).map(e=>e.substr(e.indexOf("."))),n=(0,s.$M)(e?.sans,t);return n}return e?.sans?.array||e?.sans||[]}return null}get timeTilExpiration(){if(this._type===E.TLS){const e=this.cachedCertInfo;if(!e?.notAfter)return null;const t=e.notAfter,n=t.valueOf(),r=Date.now(),i=n-r;return i<0?0:i}return null}get timeTilExpirationDate(){return this.timeTilExpiration>0?this.cachedCertInfo?.notAfter?.valueOf():null}get decodedData(){const e={};for(const t in this.data||{})e[t]=(0,a.u)(this.data[t]);return e}get setData(){return(e,t)=>{const n=e&&"object"===typeof e;let r;this.data&&!n||(0,u.hZ)(this,"data",{}),r=n?e:{[e]:t};for(const i in r)(0,u.hZ)(this.data,`"${i}"`,(0,a.KA)(r[i]))}}get doneRoute(){return this.$rootGetters["currentProduct"].name===d.o?"c-cluster-manager-secret":"c-cluster-product-resource"}get certLifetime(){if(this._type===E.TLS){const e=this.cachedCertInfo;if(e)return(0,f.qx)(g()(e.notBefore),g()(e.notAfter),(e,t)=>this.t(e,t)).string}return null}get certState(){if(this._type===E.TLS)return"number"!==typeof this.timeTilExpiration||this.timeTilExpiration>x?"":this.timeTilExpiration>0?p.jv.EXPIRING:p.jv.EXPIRED}get certStateDisplay(){if(this._type===E.TLS)return(0,p.ch)(this.certState)}get certStateBackground(){if(this._type!==E.TLS)return;const e=(0,p.uU)(this.certState);return e.replace("text-","bg-")}cleanForSave(e,t){const n=super.cleanForSave(e,t);return t&&delete n._type,n}async cleanForDownload(e,t={}){return(0,v.C)(e,{rootKeys:["id","links","actions"],...t})}get isProjectScoped(){return!!this.projectScopedProjectName&&!this.isProjectSecretCopy&&this.$rootGetters["isRancher"]}get projectScopedProjectName(){return this.metadata.labels?.[i.Qw]}get projectScopedClusterId(){return this.metadata?.labels?.[i.Bt]}get projectCluster(){if(this.isProjectScoped)return this.$rootGetters[`${b.e.MANAGEMENT}/byId`](l.Mc.CLUSTER,this.projectScopedClusterId)}get isProjectSecretCopy(){return"true"===this.metadata?.annotations?.[i.c8]}get projectSecretCopyProjectName(){return this.metadata.labels?.[i.Qw]}get projectSecretCopyClusterId(){return this.metadata?.labels?.[i.Bt]}get project(){let e,t;if(this.isProjectSecretCopy&&(e=this.projectSecretCopyClusterId,t=this.projectSecretCopyProjectName),this.isProjectScoped&&(e=this.projectScopedClusterId,t=this.projectScopedProjectName),t){const n=`${e}/${t}`,r=t,i=this.$rootGetters[`${b.e.MANAGEMENT}/byId`](l.Mc.PROJECT,n)||this.$rootGetters[`${b.e.MANAGEMENT}/byId`](l.Mc.PROJECT,r);return i}}get detailLocation(){if(this.isProjectScoped){const e=this.id?.replace(/.*\//,"");return{name:`c-cluster-product-${l.cG.PROJECT_SECRETS}-namespace-id`,params:{product:this.$rootGetters["productId"],cluster:this.$rootGetters["clusterId"],namespace:this.metadata?.namespace,resource:l.cG.PROJECT_SECRETS,id:e}}}return this._detailLocation}get listLocation(){return this.hasProjectScopedUrlQueryParam||this.isProjectScoped?{name:"c-cluster-product-resource",params:{product:this.$rootGetters["productId"],cluster:this.$rootGetters["clusterId"],resource:l.cG.PROJECT_SECRETS}}:super.listLocation}get hasProjectScopedUrlQueryParam(){return this.currentRoute()?.query?.[c.SD]===c.dq.PROJECT_SCOPED}get parentNameOverride(){return this.hasProjectScopedUrlQueryParam||this.isProjectScoped?this.$rootGetters["i18n/t"](`typeLabel."${l.cG.PROJECT_SECRETS}"`,{count:1})?.trim():super.parentNameOverride}get parentLocationOverride(){return this.hasProjectScopedUrlQueryParam||this.isProjectScoped?this.listLocation:super.parentLocationOverride}get groupByProject(){if(this.isProjectScoped)return this.t("resourceTable.groupLabel.project",{name:(0,y.ZD)(this?.project?.nameDisplay||"")},!0)}get fullDetailPageOverride(){return!0}}},96258:function(e,t,n){"use strict";n.r(t),n.d(t,{CLUSTERIP:function(){return h},DEFAULT_SERVICE_TYPES:function(){return u},HEADLESS:function(){return d},default:function(){return f},fetchNodesForServiceTargets:function(){return p},proxyUrlFromBase:function(){return g},proxyUrlFromParts:function(){return m}});var r=n(81936),i=n.n(r),o=n(35664),a=n(39975),s=n(38823),l=n(50025),c=n(4364);const u=[{id:"ClusterIP",label:"servicesPage.serviceTypes.clusterIp.label",description:"servicesPage.serviceTypes.clusterIp.description",bannerAbbrv:"servicesPage.serviceTypes.clusterIp.abbrv"},{id:"ExternalName",label:"servicesPage.serviceTypes.externalName.label",description:"servicesPage.serviceTypes.externalName.description",bannerAbbrv:"servicesPage.serviceTypes.externalName.abbrv"},{id:"Headless",label:"servicesPage.serviceTypes.headless.label",description:"servicesPage.serviceTypes.headless.description",bannerAbbrv:"servicesPage.serviceTypes.headless.abbrv"},{id:"LoadBalancer",label:"servicesPage.serviceTypes.loadBalancer.label",description:"servicesPage.serviceTypes.loadBalancer.description",bannerAbbrv:"servicesPage.serviceTypes.loadBalancer.abbrv"},{id:"NodePort",label:"servicesPage.serviceTypes.nodePort.label",description:"servicesPage.serviceTypes.nodePort.description",bannerAbbrv:"servicesPage.serviceTypes.nodePort.abbrv"}],d=(()=>{const e=i()(u,["id","Headless"]);return e.id})(),h=(()=>{const e=i()(u,["id","ClusterIP"]);return e.id})(),p=async({$store:e,inStore:t})=>{try{const n=e.getters[`${t}/schemaFor`](o.NW);if(n){if(e.getters[`${t}/paginationEnabled`](o.NW)){const n={pagination:{pageSize:1,filters:[l.eY.createSingleField({field:"status.addresses.type",value:"ExternalIP",equality:l.D0.CONTAINS})]}};return e.dispatch(`${t}/findPage`,{type:o.NW,opt:n})}return e.dispatch(`${t}/findAll`,{type:o.NW})}return[]}catch(n){return c.warn("Failed to fetch nodes for service targets:",n),[]}};class f extends a.A{get customValidationRules(){return[{nullable:!1,path:"metadata.name",required:!0,translationKey:"generic.name",type:"dnsLabel"},{nullable:!1,path:"spec",required:!0,type:"array",validators:["servicePort"]},{nullable:!0,path:"spec",required:!0,type:"string",validators:["clusterIp"]},{nullable:!0,path:"spec",required:!0,type:"array",validators:["externalName"]}]}get details(){const e=[{label:this.t("generic.type"),content:this.serviceType?.id||this.serviceType}],{clusterIP:t,externalName:n,sessionAffinity:r,loadBalancerIP:i}=this.spec;if(t&&e.push({label:this.t("servicesPage.serviceTypes.clusterIp.label"),content:t}),"LoadBalancer"===this.serviceType){const t=this.status.loadBalancer?.ingress?.map(e=>e.hostname||e.ip).join(", "),n=i||t||"";n&&e.push({label:this.t("servicesPage.ips.loadBalancer.label"),content:n})}return n&&e.push({label:this.t("servicesPage.serviceTypes.externalName.label"),content:n}),r&&e.push({label:this.t("servicesPage.affinity.label"),content:r}),e}get podRelationship(){const{metadata:{relationships:e=[]}}=this;return(e||[]).filter(e=>e.toType===o.Sm)[0]}async fetchPods(){return this.podRelationship?await this.$dispatch("findLabelSelector",{type:o.Sm,matching:{namespace:this.metadata.namespace,labelSelector:{matchExpressions:(0,s.qg)(this.podRelationship?.selector)}}}):[]}async unWatchPods(){return await this.$dispatch("unwatch",{type:o.Sm,all:!0})}get pods(){return this.podRelationship?.selector?this.$getters["matchingLabelSelector"](o.Sm,{matchExpressions:(0,s.qg)(this.podRelationship?.selector)},this.metadata.namespace):[]}get serviceType(){const e=this.spec?.type,t=this.spec?.clusterIP,n=i()(u,["id",h]);return e?e===h&&"None"===t?d:e:n}proxyUrl(e,t){const n=this.linkFor("view"),r=n.lastIndexOf("/");return g(n.slice(0,r),e,this.metadata.name,t)}}function m(e,t,n,r,i,o){const a=`/k8s/clusters/${escape(e)}/api/v1/namespaces/${escape(t)}/services`;return g(a,r,n,i,o)}function g(e,t,n,r,i){const o=(t?`${escape(t)}:`:"")+escape(n)+(r?`:${escape(r)}`:""),a=`/${(i||"").replace(/^\/+/g,"")}`,s=e.replace(/\/+$/g,""),l=`${s}/${o}/proxy${a}`;return l}},63809:function(e,t,n){"use strict";n.r(t),n.d(t,{PROVISIONER_OPTIONS:function(){return a}});var r=n(2841),i=n(35664),o=n(39975);const a=[{labelKey:"storageClass.aws-ebs.title",value:"kubernetes.io/aws-ebs",supported:!0,deprecated:!0},{labelKey:"storageClass.azure-disk.title",value:"kubernetes.io/azure-disk",supported:!0,deprecated:!0},{labelKey:"storageClass.azure-file.title",value:"kubernetes.io/azure-file",supported:!0,deprecated:!0},{labelKey:"storageClass.rbd.title",value:"kubernetes.io/rbd"},{labelKey:"storageClass.glusterfs.title",value:"kubernetes.io/glusterfs"},{labelKey:"storageClass.gce-pd.title",value:"kubernetes.io/gce-pd",supported:!0,deprecated:!0},{labelKey:"storageClass.no-provisioner.title",value:"kubernetes.io/no-provisioner"},{labelKey:"storageClass.longhorn.title",value:"driver.longhorn.io",supported:!0},{labelKey:"storageClass.cinder.title",value:"kubernetes.io/cinder",deprecated:!0},{labelKey:"storageClass.portworx-volume.title",value:"kubernetes.io/portworx-volume"},{labelKey:"storageClass.quobyte.title",value:"kubernetes.io/quobyte"},{labelKey:"storageClass.scaleio.title",value:"kubernetes.io/scaleio"},{labelKey:"storageClass.storageos.title",value:"kubernetes.io/storageos"},{labelKey:"storageClass.vsphere-volume.title",value:"kubernetes.io/vsphere-volume",supported:!0,deprecated:!0},{labelKey:"storageClass.harvesterhci.title",value:"driver.harvesterhci.io",supported:!0,hideCustomize:!0}];t["default"]=class extends o.A{get provisionerListDisplay(){return`${this.provisioner} (${this.provisionerDisplay})`}get provisionerDisplay(){const e=a.find(e=>e.value===this.provisioner),t=`${this.provisioner} ${this.t("persistentVolume.csi.suffix")}`;return e?this.t(e.labelKey):this.$rootGetters["i18n/withFallback"](`persistentVolume.csi.drivers.${this.provisioner.replaceAll(".","-")}`,null,t)}get isDefault(){return"true"===this.annotations[r.O3.DEFAULT_STORAGE_CLASS]}updateDefault(e){this.setAnnotation(r.O3.DEFAULT_STORAGE_CLASS,e.toString()),this.setAnnotation(r.O3.BETA_DEFAULT_STORAGE_CLASS,e.toString());const t={metadata:{annotations:{[r.O3.DEFAULT_STORAGE_CLASS]:e.toString(),[r.O3.BETA_DEFAULT_STORAGE_CLASS]:e.toString()}}};return this.patch(t,{},!0,!0)}async setDefault(){const e=this.$rootGetters["currentProduct"].inStore,t=this.$rootGetters[`${e}/all`](i.fJ)||[];for(const n of t)await n.resetDefault();t.forEach(e=>e.resetDefault()),this.updateDefault(!0)}async resetDefault(){this.isDefault&&await this.updateDefault(!1)}get _availableActions(){const e=super._availableActions;return this.isDefault?e.unshift({action:"resetDefault",enabled:!0,icon:"icon icon-checkmark",label:this.t("storageClass.actions.resetDefault")}):e.unshift({action:"setDefault",enabled:!0,icon:"icon icon-checkmark",label:this.t("storageClass.actions.setAsDefault")}),e}cleanForNew(){this.$dispatch("cleanForNew",this),delete this?.metadata?.annotations?.[r.O3.DEFAULT_STORAGE_CLASS]}},(Object.getOwnPropertyDescriptor(t["default"],"name")||{}).writable||Object.defineProperty(t["default"],"name",{value:"default",configurable:!0})},66491:function(e,t,n){"use strict";n.r(t);var r=n(39975);t["default"]=class extends r.A{get constraints(){const e=`constraints.gatekeeper.sh.${this.id}`;if(!this.$rootGetters["cluster/haveAll"](e))throw new Error("The constraints have not been loaded");return this.$rootGetters["cluster/all"](e)}get preventDeletionMessage(){const e=this.constraints;return e.length>0?"There are still constraints using this template. You cannot delete this template while it's in use.":null}},(Object.getOwnPropertyDescriptor(t["default"],"name")||{}).writable||Object.defineProperty(t["default"],"name",{value:"default",configurable:!0})},24364:function(e,t,n){"use strict";n.r(t);var r=n(23464),i=n.n(r),o=n(89865);t["default"]=class extends o.A{get _availableActions(){return super._availableActions.filter(e=>["viewInApi","promptRemove"].includes(e.action))}get state(){return this.isExpired?"expired":"active"}get isExpired(){const e=i()(this.expiresAt);return e.isBefore(i()())}},(Object.getOwnPropertyDescriptor(t["default"],"name")||{}).writable||Object.defineProperty(t["default"],"name",{value:"default",configurable:!0})},51225:function(e,t,n){"use strict";n.r(t);var r=n(96258),i=n(39975);t["default"]=class extends i.A{get labelDisplay(){return this.spec?.label||this.metadata.name||"?"}get link(){if(this.spec?.toURL)return this.spec.toURL;if(this.spec?.toService){const e=this.spec.toService;return(0,r.proxyUrlFromParts)(this.$rootGetters["clusterId"],e.namespace,e.name,e.scheme,e.port,e.path)}return null}get normalizedGroup(){return this.spec.group?this.spec.group.toLowerCase().trim().replace(/[^a-z0-9]/g,"-").replace(/-+/g,"-").replace(/^-+/,"").replace(/-+$/,""):null}get actualTarget(){return(this.spec.target||"").trim()||"_blank"}},(Object.getOwnPropertyDescriptor(t["default"],"name")||{}).writable||Object.defineProperty(t["default"],"name",{value:"default",configurable:!0})},70775:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return w},defaultContainer:function(){return y}});var r=n(68851),i=n(2841),o=n(35664),a=n(76978),s=n(23464),l=n.n(s),c=n(38823);const u={separator:!0};var d=n(2505),h=n(3704),p=n(9274),f=n(6855),m=n(73883),g=n(95265),v=n(4364);const b=(0,p.markRaw)((0,p.defineAsyncComponent)(()=>n.e(814).then(n.bind(n,98814)))),y={imagePullPolicy:"Always",name:"container-0",securityContext:{runAsNonRoot:!1,readOnlyRootFilesystem:!1,privileged:!1,allowPrivilegeEscalation:!1},volumeMounts:[]};class w extends d["default"]{get _availableActions(){let e=super._availableActions;const t=this._type?this._type:this.type,n=!!this.$rootGetters["features/get"](g.nR),i=(0,r.jq)(e,"action","goToEditYaml"),a=i?e.indexOf(i):0;(0,r.PT)(e,a,{action:"addSidecar",label:this.t("action.addSidecar"),icon:"icon icon-plus",enabled:!!this.links.update}),t!==o.oU.JOB&&t!==o.oU.CRON_JOB&&t!==o.oU.REPLICA_SET&&((0,r.PT)(e,0,{action:"toggleRollbackModal",label:this.t("action.rollback"),icon:"icon icon-downgrade-alt",enabled:!!this.links.update}),(0,r.PT)(e,0,{action:"redeploy",label:this.t("action.redeploy"),icon:"icon icon-refresh",enabled:!!this.links.update,bulkable:!0,bulkAction:"redeploy"}),(0,r.PT)(e,0,{action:"pause",label:this.t("asyncButton.pause.action"),icon:"icon icon-pause",enabled:!!this.links.update&&!this.spec?.paused}),(0,r.PT)(e,0,{action:"resume",label:this.t("asyncButton.resume.action"),icon:"icon icon-play",enabled:!!this.links.update&&!0===this.spec?.paused})),(0,r.PT)(e,0,{divider:!0}),n&&(0,r.PT)(e,0,{action:"openShell",enabled:!!this.links.view,icon:"icon icon-chevron-right",label:this.t("action.openShell"),total:1});const s=["cloneYaml"];return e=e.filter(e=>{if(!s.includes(e.action))return e}),e}applyDefaults(){const{spec:e={}}=this;this.type===o.oU.CRON_JOB?e.jobTemplate||(e.jobTemplate={spec:{template:{spec:{restartPolicy:"Never",containers:[{imagePullPolicy:"Always",name:"container-0"}],initContainers:[]}}}}):(e.replicas||0===e.replicas||(e.replicas=1),e.template||(e.template={spec:{restartPolicy:this.type===o.oU.JOB?"Never":"Always",containers:[{...structuredClone(y)}],initContainers:[]}}),e.selector||(e.selector={})),this.spec=e}toggleRollbackModal(e=this){this.$dispatch("promptModal",{componentProps:{workload:e},component:"RollbackWorkloadDialog"})}async rollBackWorkload(e,t,n,r){const i=JSON.stringify(r);if(Array.isArray(t))throw new TypeError(this.t("promptRollback.multipleWorkloadError"));const o=t.metadata.namespace,a=t.metadata.name;await this.patch(i,{url:`/k8s/clusters/${e.id}/apis/apps/v1/namespaces/${o}/${n}/${a}`})}pause(){(0,a.hZ)(this.spec,"paused",!0),this.save()}resume(){(0,a.hZ)(this.spec,"paused",!1),this.save()}async _scaleTo(e,t=!0){const n=this.spec.replicas;(0,a.hZ)(this.spec,"replicas",e);try{await this.save()}catch(r){if(409===r?._status){const r=this.spec.replicas===n;if(t&&r)return this._scaleTo(e,!1)}else(0,a.hZ)(this.spec,"replicas",n);throw r}}async scaleDown(){const e=this.spec.replicas-1;e>=0&&await this._scaleTo(e)}async scaleUp(){await this._scaleTo(this.spec.replicas+1)}async scale(e){try{e?await this.scaleUp():await this.scaleDown()}catch(t){this.$dispatch("growl/fromError",{title:this.t("workload.list.errorCannotScale",{direction:e?"up":"down",workloadName:this.name}),err:t},{root:!0})}}get state(){return!0===this.spec?.paused?"paused":super.state}async openShell(){const e=await this.matchingPods();for(const t of e)if(t.isRunning)return void t.openShell();this.$dispatch("growl/error",{title:"Unavailable",message:"There are no running pods to execute a shell in."},{root:!0})}addSidecar(){return this.goToEdit({sidecar:!0})}get restartCount(){return this.pods.reduce((e,t)=>e+(t.totalRestartCount||0),0)}get hasSidecars(){const e=this.type===o.oU.CRON_JOB?this?.spec?.jobTemplate?.spec?.template?.spec:this.spec?.template?.spec,{containers:t=[],initContainers:n=[]}=e;return t.length>1||n.length}get customValidationRules(){const e=this._type?this._type:this.type,t=e===o.oU.CRON_JOB?"spec.jobTemplate.spec.template.spec":"spec.template.spec",n=[{nullable:!1,path:"metadata.name",required:!0,translationKey:"generic.name",type:"subDomain"},{nullable:!1,path:"spec",required:!0,type:"object",validators:["containerImages"]},{nullable:!0,path:`${t}.affinity`,type:"object",validators:["podAffinity"]}];switch(e){case o.oU.DEPLOYMENT:case o.oU.REPLICA_SET:n.push({nullable:!1,path:"spec.replicas",required:!0,type:"number",translationKey:"workload.replicas"});break;case o.oU.STATEFUL_SET:n.push({nullable:!1,path:"spec.replicas",required:!0,type:"number",translationKey:"workload.replicas"}),n.push({nullable:!1,path:"spec.serviceName",required:!1,type:"string",translationKey:"workload.serviceName"});break;case o.oU.CRON_JOB:n.push({nullable:!1,path:"spec.schedule",required:!0,type:"string",validators:["cronSchedule"],translationKey:"workload.cronSchedule"})}return n}get endpoint(){return this?.metadata?.annotations?.[i.bs]}get publicEndpoints(){const e=this.endpoint;if(!e)return[];try{const t=JSON.parse(e);return Array.isArray(t)?t:[]}catch(t){return v.warn(`publicEndpoints: failed to parse the ${i.bs} annotation on "${this.id}"`,t),[]}}get detailEndpoints(){const e=[...this.publicEndpoints,...this.gatewayEndpoints];return e.length?e:void 0}get desired(){return this.spec?.replicas||0}get available(){return this.status?.readyReplicas||0}get ready(){const e=Math.max(0,(this.status?.replicas||0)-(this.status?.unavailableReplicas||0));return this.type===o.oU.DAEMON_SET?e:`${e}/${this.desired}`}get unavailable(){return this.status?.unavailableReplicas||0}get upToDate(){return this.status?.updatedReplicas}get details(){const e=[],t=this._type?this._type:this.type,n={restarts:{label:this.t("resourceDetail.masthead.restartCount"),content:this.restartCount},endpoint:{label:"Endpoints",content:this.detailEndpoints,formatter:"WorkloadDetailEndpoints"},ready:{label:"Ready",content:this.ready},upToDate:{label:"Up-to-date",content:this.upToDate},available:{label:"Available",content:this.available}};if(t===o.oU.JOB){const{completionTime:t,startTime:n}=this.status,r=[60,60,24],i=["sec","min","hour","day"];if(n&&e.push({label:"Started",content:n,formatter:"LiveDate",formatterOpts:{addSuffix:!0}}),t&&n){const o=l()(t),a=l()(n);let s,c=o.diff(a)/1e3,u=0;while(c>=r[u]&&u<r.length)c/=r[u],u++;s=c<5?Math.floor(10*c)/10:Math.floor(c),s+=` ${this.t(`unit.${i[u]}`,{count:s})} `,s=s.trim(),e.push({label:"Duration",content:s})}}else t===o.oU.CRON_JOB&&e.push({label:"Last Scheduled Time",content:this?.status?.lastScheduleTime,formatter:"LiveDate"});switch(e.push({label:"Image",content:this.imageNames,formatter:"PodImages"},{label:n.restarts.label,content:n.restarts.content}),t){case o.oU.DEPLOYMENT:e.push(n.ready,n.upToDate,n.available,u,n.endpoint);break;case o.oU.DAEMON_SET:e.push(n.ready,u,n.endpoint);break;case o.oU.REPLICA_SET:e.push(n.ready,u,n.endpoint);break;case o.oU.STATEFUL_SET:e.push(n.ready,u,n.endpoint);break;case o.oU.REPLICATION_CONTROLLER:e.push(n.ready,u,n.endpoint);break;case o.oU.JOB:e.push(n.endpoint);break;case o.oU.CRON_JOB:e.push(n.endpoint);break;case o.Sm:e.push(n.ready);break;default:break}return e}redeploy(e=this){const t=Array.isArray(e)?e:[e];this.$dispatch("promptModal",{modalWidth:"500px",componentProps:{workloads:t},component:"RedeployWorkloadDialog"})}async getPortsWithServiceType(){const e=[];this.containers.forEach(t=>e.push(...t.ports||[])),(this.initContainers||[]).forEach(t=>e.push(...t.ports||[]));const t=this.$getters["schemaFor"](o.YV),n=t?await this.getServicesOwned():[],i=[],a=[],s=[];return n.length&&n.forEach(e=>{switch(e.spec.type){case"ClusterIP":i.push(...e?.spec?.ports||[]);break;case"LoadBalancer":a.push(...e?.spec?.ports||[]);break;case"NodePort":s.push(...e?.spec?.ports||[]);break;default:break}}),e.forEach(e=>{const t=e.name?e.name:`${e.containerPort}${e.protocol.toLowerCase()}${e.hostPort||e._listeningPort||""}`;if(e.name=t,!e._serviceType||""===e._serviceType){if(a.length){const n=(0,r.jq)(a,"name",t);if(n)return e._listeningPort=n.port,void(e._serviceType="LoadBalancer")}if(s.length){const n=(0,r.jq)(s,"name",t);if(n)return e._listeningPort=n.nodePort,void(e._serviceType="NodePort")}i.length&&(0,r.jq)(i,"name",t)&&(e._serviceType="ClusterIP")}}),e}get ownedByWorkload(){const e=Object.values(o.oU);if(this.metadata?.ownerReferences)for(const t of this.metadata.ownerReferences){const n=`${t.apiVersion.replace(/\/.*/,"")}.${t.kind}`.toLowerCase();if(e.includes(n))return!0}return!1}get isFromNorman(){return"norman"===(this.metadata.labels||{})["cattle.io/creator"]}get warnDeletionMessage(){return this.isFromNorman?this.t("workload.normanWarning"):null}async fetchPods(){if(this.podMatchExpression)return this.$dispatch("findLabelSelector",{type:o.Sm,matching:{namespace:this.metadata.namespace,labelSelector:{matchExpressions:this.podMatchExpression}}})}async fetchSummaries(){const e={pods:null};try{this.podMatchExpression&&(e.pods=await this.$dispatch("fetchResourceSummary",{type:o.Sm,opt:{summaryField:"metadata.state.name",namespace:this.metadata.namespace,labelSelector:{matchExpressions:this.podMatchExpression}}}))}catch(t){v.warn("fetchSummaries: failed to fetch pod summary",t)}return(0,a.hZ)(this,"_summaries",e),e}async unWatchPods(){return await this.$dispatch("unwatch",{type:o.Sm,all:!0})}get pods(){return this.podMatchExpression?this.$getters["matchingLabelSelector"](o.Sm,{matchExpressions:this.podMatchExpression},this.metadata.namespace):[]}get podSelector(){const e=this.metadata?.relationships||[],t=e.filter(e=>e.toType===o.Sm)[0]?.selector;return t}get podMatchExpression(){return this.podSelector?(0,c.qg)(this.podSelector):null}calcPodGauges(e){const t={};let n=e;return this.metadata.associatedData&&(n=[],this.metadata.associatedData.forEach(e=>{if(e.gvk.kind.toLowerCase()===o.Sm)return e.data.forEach(e=>{n.push({stateColor:(0,m.uU)(e.state.name,"true"===e.state.error,"true"===e.state.transitioning),stateDisplay:(0,m.ch)(e.state.name)})})})),n?(n.map(e=>{const{stateColor:n,stateDisplay:r}=e;t[r]?t[r].count++:t[r]={color:n.replace("text-",""),count:1}}),t):t}get podGauges(){return this.calcPodGauges(this.pods)}get jobRelationships(){if(this.type===o.oU.CRON_JOB)return this.metadata?.relationships?.filter(e=>e.toType===o.oU.JOB)||[]}async matchingJobs(){if(this.type===o.oU.CRON_JOB)return Promise.all(this.jobRelationships.map(e=>this.$dispatch("find",{type:o.oU.JOB,id:e.toId})))}get jobs(){if(this.type===o.oU.CRON_JOB)return this.jobRelationships.map(e=>this.$getters["byId"](o.oU.JOB,e.toId)).filter(e=>!!e)}get currentRevisionNumber(){if(!this.ownedByWorkload&&"Job"!==this.kind&&"CronJob"!==this.kind)return"Deployment"===this.kind?this.metadata.annotations["deployment.kubernetes.io/revision"]:this.metadata.generation}async matchingPods(){const e=await(0,h.wC)({labelSelector:{matchExpressions:(0,c._R)(this.spec.selector)},type:o.Sm,$store:this.$store||{getters:this.$rootGetters,dispatch:(e,t)=>this.$dispatch(e.split("/")[1],t)},inStore:this.$rootGetters["currentProduct"].inStore,namespace:this.metadata.namespace,transient:!0});return e.matches}cleanForSave(e){const t=super.cleanForSave(e);return t.spec?.template?.spec?.containers?.forEach(e=>{this.cleanContainerForSave(e)}),t.spec?.template?.spec?.initContainers?.forEach(e=>{this.cleanContainerForSave(e)}),t}get servicesInNamespace(){return this.$rootGetters["cluster/all"](o.YV).filter(e=>e.metadata.namespace===this.metadata.namespace)}get relatedServices(){if(this.type===o.oU.JOB||this.type===o.oU.CRON_JOB)return[];const e=this.spec?.template?.metadata?.labels;if(!e||0===Object.keys(e).length)return[];const t={metadata:{labels:e}};return this.servicesInNamespace.filter(e=>{const n=e.spec.selector;return!(!n||"object"!==typeof n)&&(0,c.cK)(t,(0,c.C6)(n))})}get matchingIngresses(){const e=this.$rootGetters["cluster/all"](o.kf),t=this.relatedServices;return t.length?e.filter(e=>{try{const n=e.spec?.rules;if(!n||!Array.isArray(n))return!1;for(const r of n){const n=r?.http?.paths;if(n&&Array.isArray(n))for(const r of n){const n=r?.backend?.service?.name;if(n)for(const r of t)if(e.metadata?.namespace===this.metadata?.namespace&&r?.metadata?.name===n)return!0}}}catch(n){return v.warn(`matchingIngresses: failed to match ingress "${e.id}"`,n),!1}return!1}):[]}get matchingHttpRoutes(){if(!this.$rootGetters["cluster/schemaFor"](o.Yq.HTTP_ROUTE))return[];const e=this.relatedServices;if(!e.length)return[];const t=this.$rootGetters["cluster/all"](o.Yq.HTTP_ROUTE)||[];return t.filter(t=>t.targetsAnyService(e))}get gatewayEndpoints(){const e=this.matchingHttpRoutes;if(!e.length)return[];const t=this.relatedServices,n=e.flatMap(e=>e.endpointsForServices(t));return n.filter((e,t)=>n.findIndex(({link:t})=>t===e.link)===t)}get resourcesCardRows(){const e=[...this._resourcesCardRows],t=this.type!==o.oU.JOB&&this.type!==o.oU.CRON_JOB;if(t){const t=this.relatedServices||[],n=this.matchingIngresses||[],r=this.matchingHttpRoutes||[];r.length&&e.unshift((0,f.G)(this.t("component.resource.detail.card.resourcesCard.rows.httpRoutes"),r,void 0,void 0,"#httproutes")),n.length&&e.unshift((0,f.G)(this.t("component.resource.detail.card.resourcesCard.rows.ingresses"),n,void 0,void 0,"#ingresses")),t.length&&e.unshift((0,f.G)(this.t("component.resource.detail.card.resourcesCard.rows.services"),t,void 0,void 0,"#services"))}return e}get podsCard(){const e=[o.oU.DEPLOYMENT,o.oU.DAEMON_SET,o.oU.JOB,o.oU.STATEFUL_SET];if(!e.includes(this.type))return null;const t=[o.oU.DEPLOYMENT,o.oU.STATEFUL_SET],n=this.canUpdate&&t.includes(this.type),r=this._summaries?.pods||null,i=this.pods?.length>0,a=r?.count>0;return i||a||n?{component:b,props:{title:this.t("component.resource.detail.card.podsCard.title"),resources:this.pods,summaryData:r,showScaling:n,scaleValue:this.desired,onIncrease:()=>this.scale(!0),onDecrease:()=>this.scale(!1),noResourcesMessage:this.t("component.resource.detail.card.podsCard.noPods")}}:null}get jobsCard(){const e=[o.oU.CRON_JOB];return!e.includes(this.type)||(this.jobs?.length||0)<=0?null:{component:b,props:{title:this.t("component.resource.detail.card.jobsCard.title"),resources:this.jobs,showScaling:!1}}}get cards(){return[this.podsCard,this.jobsCard,this.resourcesCard,this.insightCard,...this._cards].filter(e=>e)}}},2505:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return u}});var r=n(68851),i=n(2841),o=n(35664),a=n(76978),s=n(39975),l=n(92043),c=n(73883);class u extends s.A{get stateDisplay(){return(0,c.ch)(this.state,!0)}async getPortsWithServiceType(){const e=[];this.containers.forEach(t=>e.push(...t.ports||[])),(this.initContainers||[]).forEach(t=>e.push(...t.ports||[]));const t=this.$getters["schemaFor"](o.YV),n=t?await this.getServicesOwned():[],i=[],a=[],s=[];return n.length&&n.forEach(e=>{switch(e.spec.type){case"ClusterIP":i.push(...e?.spec?.ports||[]);break;case"LoadBalancer":a.push(...e?.spec?.ports||[]);break;case"NodePort":s.push(...e?.spec?.ports||[]);break;default:break}}),e.forEach(e=>{const t=e.name?e.name:`${e.containerPort}${e.protocol.toLowerCase()}${e.hostPort||e._listeningPort||""}`;if(e.name=t,!e._serviceType||""===e._serviceType){if(a.length){const n=(0,r.jq)(a,"name",t);if(n)return e._listeningPort=n.port,void(e._serviceType="LoadBalancer")}if(s.length){const n=(0,r.jq)(s,"name",t);if(n)return e._listeningPort=n.nodePort,void(e._serviceType="NodePort")}i.length&&(0,r.jq)(i,"name",t)&&(e._serviceType="ClusterIP")}}),e}async getServicesOwned(e=!1){const t={[o.oU.REPLICA_SET]:"replicaSet",[o.oU.DEPLOYMENT]:"deployment",[o.oU.STATEFUL_SET]:"statefulSet",[o.oU.DAEMON_SET]:"daemonSet"},n=Object.keys(this.workloadSelector)[0],r=`${t[this._type?this._type:this.type]}-${this.metadata.namespace}-${this.metadata.name}`,i=this.workloadSelector[n],a=await this.$dispatch("cluster/findAll",{type:o.YV,opt:{force:e}},{root:!0});return(a||[]).filter(e=>(e.spec?.selector||{})[n]===i||(e.spec?.selector||{})[n]===r)}get imageNames(){let e;const t=[];return e=this.type===o.oU.CRON_JOB?(0,a.Jt)(this,"spec.jobTemplate.spec.template.spec.containers"):(0,a.Jt)(this,"spec.template.spec.containers"),e&&e.forEach(e=>{t.includes(e.image)||t.push(e.image)}),t.map(l.qO)}get containers(){if(this.type===o.oU.CRON_JOB){const{spec:{jobTemplate:{spec:{template:{spec:{containers:e}}}}}}=this;return e}return this.spec?.containers??this.spec?.template?.spec?.containers}get initContainers(){if(this.type===o.oU.CRON_JOB){const{spec:{jobTemplate:{spec:{template:{spec:{initContainers:e}}}}}}=this;return e}return this.spec?.initContainers??this.spec?.template?.spec?.initContainers}get workloadSelector(){return{"workload.user.cattle.io/workloadselector":`${this._type?this._type:this.type}-${this.metadata.namespace}-${this.metadata.name}`}}async servicesFromContainerPorts(e,t){const n={apiVersion:this.apiVersion,controller:!0,kind:this.kind,name:this.metadata.name,uid:this.metadata.uid},r={[i.nN]:JSON.stringify([`${this.metadata.namespace}/${this.metadata.name}`]),[i.d6]:"true"};let s={type:o.YV,spec:{ports:[],selector:this.workloadSelector,type:"ClusterIP"},metadata:{name:this.metadata.name,namespace:this.metadata.namespace,annotations:r,ownerReferences:[n]}},l={type:o.YV,spec:{ports:[],selector:this.workloadSelector,type:"NodePort"},metadata:{name:`${this.metadata.name}-nodeport`,namespace:this.metadata.namespace,annotations:r,ownerReferences:[n]}},c={type:o.YV,spec:{ports:[],selector:this.workloadSelector,type:"LoadBalancer",externalTrafficPolicy:"Cluster"},metadata:{name:`${this.metadata.name}-loadbalancer`,namespace:this.metadata.namespace,annotations:r,ownerReferences:[n]}};const u=await this.getServicesOwned(this.isFromNorman);u&&u.length&&u.forEach(e=>{switch(e.spec.type){case"ClusterIP":s=e,s.spec.ports=[];break;case"NodePort":l=e,l.spec.ports=[];break;case"LoadBalancer":c=e,c.spec.ports=[];break;default:break}}),t.forEach(e=>{const t={name:e.name,protocol:e.protocol,port:e.containerPort,targetPort:e.containerPort};if(""!==e._serviceType)switch(s.spec.ports.push(t),e._serviceType){case"NodePort":{const n=(0,a.o8)(t);e._listeningPort&&(n.nodePort=e._listeningPort),l.spec.ports.push(n);break}case"LoadBalancer":{const n=(0,a.o8)(t);e._listeningPort&&(n.port=e._listeningPort),c.spec.ports.push(n);break}default:break}});const d=[],h=[];let p;if(s.spec.ports.length>0?(p=s.id?s:await this.$dispatch("cluster/create",s,{root:!0}),d.push(p)):s.id&&h.push(s),l.spec.ports.length>0){let e;e=l.id?l:await this.$dispatch("cluster/create",l,{root:!0}),d.push(e)}else l.id&&h.push(l);if(c.spec.ports.length>0){let e;e=c.id?c:await this.$dispatch("cluster/create",c,{root:!0});const n=t.filter(e=>e._ipam)||[];n.length>0&&(e.metadata.annotations[i.rk.CLOUD_PROVIDER_IPAM]=n[0]._ipam),d.push(e)}else c.id&&h.push(c);return{toSave:d,toRemove:h}}cleanForSave(e){const t=super.cleanForSave(e);return delete t.__active,delete t.type,t}cleanContainerForSave(e){return delete e.__active,delete e.active,delete e._init,delete e.error,e}}},27436:function(e,t,n){"use strict";function r(e){return()=>{}}function i(e){return()=>{}}function o(e){return()=>{}}function a(e){return()=>{}}function s(e){return()=>{}}function l(e){return()=>{}}function c(e){return()=>{}}function u(e){return()=>{}}function d(e){return()=>{}}function h(e){}function p(e){}function f(e){}function m(e){}function g(e){return()=>{}}function v(e){}function b(e){}function y(e){}n.d(t,{Gw:function(){return s},L7:function(){return d},Lk:function(){return i},Nh:function(){return h},PP:function(){return l},dM:function(){return p},eG:function(){return a},gc:function(){return v},hi:function(){return b},ho:function(){return o},iE:function(){return u},lB:function(){return f},oe:function(){return m},qq:function(){return r},ro:function(){return g},uc:function(){return c},yo:function(){return y}})},52148:function(e,t,n){"use strict";function r(e){if("undefined"!==typeof window&&window.__shell_requireAsset)return window.__shell_requireAsset(e);throw new Error(`Asset context not available for: ${e}`)}function i(e){if("undefined"!==typeof window&&window.__shell_requireJson)return window.__shell_requireJson(e);throw new Error(`JSON context not available for: ${e}`)}n.d(t,{mS:function(){return r},sG:function(){return i}})},3252:function(e,t,n){"use strict";n.d(t,{Wk:function(){return d},lq:function(){return c},rd:function(){return u}});var r=n(9274);const i=()=>"undefined"===typeof window?void 0:window.__vueRouter,o=()=>(0,r.getCurrentInstance)()?.proxy,a=e=>(...t)=>{const n=i()?.[e];if(!n)throw new Error(`vue-router's ${e}() is not available to extensions on this Rancher version (requires 2.15 or later)`);return n(...t)},s=(e,t)=>i()?.[e]||t,l=()=>{const e=o();if(e)return(0,r.reactive)(new Proxy({},{get:(t,n)=>e.$route?.[n],has:(t,n)=>n in(e.$route||{}),ownKeys:()=>Reflect.ownKeys(e.$route||{}),getOwnPropertyDescriptor:()=>({enumerable:!0,configurable:!0})}))};function c(...e){const t=i();return t?t.useRoute(...e):l()}function u(...e){const t=i();return t?t.useRouter(...e):o()?.$router}const d=s("RouterLink","router-link");s("RouterView","router-view"),a("createMemoryHistory"),a("createRouter"),a("createRouterMatcher"),a("createWebHashHistory"),a("createWebHistory"),a("isNavigationFailure"),a("loadRouteLocation"),a("onBeforeRouteLeave"),a("onBeforeRouteUpdate"),a("parseQuery"),a("stringifyQuery"),a("useLink"),s("NavigationFailureType"),s("START_LOCATION"),s("matchedRouteKey"),s("routeLocationKey"),s("routerKey"),s("routerViewLocationKey"),s("viewDepthKey")},70176:function(e,t,n){"use strict";n.d(t,{OD:function(){return l},P:function(){return s}});var r=n(97519),i=n(68851);n(4364);const o=["center","code","li","a","p","b","br","ul","pre","span","div","i","img","em","strong","h1","h2","h3","h4","h5","h6","table","thead","tr","th","tbody","td","blockquote"];let a=[];r.A.addHook("uponSanitizeAttribute",(e,t)=>{"A"===e.tagName&&"target"===t.attrName&&"_blank"===t.attrValue&&(t.forceKeepAttr=!0)}),r.A.addHook("afterSanitizeAttributes",e=>{if("A"===e.tagName&&"_blank"===e?.target){const t=["noopener","noreferrer","nofollow"],n=e.rel?.length?e.rel.split(" "):[],r=(0,i.sb)([...t,...n]);e.setAttribute("rel",r.join(" "))}if("A"===e.tagName&&a.length){let t=e.href;t=l(t),t!==e.href&&(e.href=t)}});const s=(e,t={ALLOWED_TAGS:o})=>r.A.sanitize(e,t);function l(e){for(let t=0;t<a.length;t++){const n=a[t](e);n&&(e=n)}return e}},63905:function(e,t,n){"use strict";n.d(t,{BH:function(){return k},m9:function(){return y},wA:function(){return _}});var r=n(82451),i=n.n(r),o=n(35664),a=n(86565),s=n(37648),l=n(50382),c=n(79401),u=n(90599),d=n(37417),h=n(50667),p=n(46392),f=n(88343),m=n(50025),g=n(3704),v=n(4364);const b="all",y="merge",w="multi",O="none",S=15,E=15,x=10;async function _(e,t,n,r){if(n.url.includes(a.QF)||n.url.includes(a.lm)){const[i,l,c,...u]=n.url.split("/"),d=u.join("/"),h=l===a.lm,p=d?"getSpoofedInstance":"getSpoofedInstances",f=e[`${t}/all`](o.yx),m=await e[`type-map/${p}`](c,r,d),g=h?(0,s.mH)(f,c,m):m;return d&&!h?g:{data:g}}}async function k(e,t=!0){const{getters:n,dispatch:r,commit:i,rootGetters:a}=e,s=await r("findAll",{type:o.yx,opt:{url:"schemas",load:!1}}),l=a["type-map/allSpoofedSchemas"];Array.isArray(s.data)?s.data=s.data.concat(l):Array.isArray(s)&&(s.data=s.concat(l)),s.data.forEach(d.w),i("loadAll",{ctx:e,type:o.yx,data:s.data,revision:s.revision}),!1!==t&&r("watch",{type:o.yx,revision:s.revision});const c=n.all(o.yx);return c}const C=(e,t,n)=>n.namespaced?e.matching(t,null,n.namespaced,{skipSelector:!0}):e.all(t),A=({type:e,id:t,opt:n,res:r})=>{const i="undefined"!==typeof n.revision?n.revision:r?.metadata?.resourceVersion,o={type:e,id:t,namespace:n.namespaced,revision:i||"",force:!0===n.forceWatch},a=t.indexOf("/");return a>0&&(o.namespace=t.substr(0,a),o.id=t.substr(a+1)),o};function T(e,t){return`${e}/${t?.requesterId||"default"}`}function R(e){return e.state.latestPageRequests||(e.state.latestPageRequests={}),e.state.latestPageRequests}function N(e,t,n){const r=T(t,n),i=R(e),o=(i[r]||0)+1;return i[r]=o,{key:r,id:o}}function P(e,{key:t,id:n}){return R(e)[t]===n}t.Ay={request(){throw new Error("Not Implemented")},loadSchemas:k,async loadDataPage(e,{type:t,opt:n,pageByLimit:r,pageByNumber:i}){const{getters:o,commit:a,dispatch:s}=e;t=o.normalizeType(t),o.typeRegistered(t)||a("registerType",t);const l=o["loadCounter"](t);try{if(r)n.url=r.next;else{if(!i)throw Error("loadDataPage requires either pageByLimit or pageByNumber");{const{url:e,page:t,pageSize:r}=i;n.url=(0,h.R_)(e,"page",`${t}`),n.url=(0,h.R_)(n.url,"pagesize",`${r}`)}}const c=await s("request",{opt:n,type:t}),u=o["loadCounter"](t);if(l!==u)return;a("loadAdd",{ctx:e,type:t,data:c.data}),r&&c.pagination?.next?s("loadDataPage",{type:t,opt:n,pageByLimit:{next:c.pagination.next}}):i&&i.page!==i.pages?s("loadDataPage",{type:t,opt:n,pageByNumber:{...i,page:i.page+1}}):(n.hasManualRefresh&&s("resource-fetch/updateManualRefreshIsLoading",!1,{root:!0}),n.namespaced?a("setHaveNamespace",{type:t,namespace:n.namespaced}):a("setHaveAll",{type:t}))}catch(c){return n.hasManualRefresh&&s("resource-fetch/updateManualRefreshIsLoading",!1,{root:!0}),Promise.reject(c)}},async findAll(e,{type:t,opt:n}){const{getters:r,commit:i,dispatch:o,rootGetters:a}=e;if(n=n||{},t=r.normalizeType(t),r.typeRegistered(t)||i("registerType",t),!n.force&&(r["haveAll"](t)||r["haveAllNamespace"](t,n.namespaced))){if(!1!==n.watch){const e={type:t,revision:"",namespace:n.watchNamespace||n.namespaced};o("watch",e)}return C(r,t,n)}let s=void 0===n.load?b:n.load;!1!==n.load&&n.load!==O||(s=O);const l=a["type-map/optionsFor"](t);v.log(`Find All: [${e.state.config.namespace}] ${t}`),n=n||{},n.isCollection=!0,n.url=r.urlFor(t,null,n),n.stream=!1!==n.stream&&s!==O,n.depaginate=(0,p.Ng)(l?.depaginate,{ctx:e,args:{type:t,opt:n}});let c,d,f=!1;n.incremental&&(i("incrementLoadCounter",t),n.hasManualRefresh&&o("resource-fetch/updateManualRefreshIsLoading",!0,{root:!0}),n.incremental.pageByNumber&&r.isSteveUrl((0,h.qg)(n.url).path)?(d={url:n.url,page:1,pages:n.incremental.increments,pageSize:n.incremental.resourcesPerIncrement},n.url=(0,h.R_)(n.url,"pagesize",`${n.incremental.quickLoadCount}`)):(c={next:(0,h.R_)(n.url,"limit",`${n.incremental.resourcesPerIncrement}`)},n.url=(0,h.R_)(n.url,"limit",`${n.incremental.quickLoadCount}`)),f=!0,n.force&&i("forgetType",t));let m,g,S=!1,E=[];n.onData=function(n){if(S){if(E.push(n),E.length>10){const t=E;E=[],i("loadMulti",{ctx:e,data:t})}}else i("forgetAll",{type:t}),S=!0,g=n};try{!n.incremental&&n.hasManualRefresh&&o("resource-fetch/updateManualRefreshIsLoading",!0,{root:!0});const a=await o("request",{opt:n,type:t});if(S){E.length&&(i("loadMulti",{ctx:e,data:E}),E=[]),i("loadedAll",{type:t});const n=r.all(t);a.finishDeferred(n),m=g}else m=a}catch(_){return!n.incremental&&n.hasManualRefresh&&o("resource-fetch/updateManualRefreshIsLoading",!1,{root:!0}),Promise.reject(_)}if(s===O)return!n.incremental&&n.hasManualRefresh&&o("resource-fetch/updateManualRefreshIsLoading",!1,{root:!0}),m;if(m.data&&(s===w?i("loadMulti",{ctx:e,data:m.data}):s===y?i("loadMerge",{ctx:e,type:t,data:m.data,existing:!0}):i("loadAll",{ctx:e,type:t,data:m.data,revision:m.revision,skipHaveAll:f,namespace:n.namespaced,pagination:n.pagination?{request:n.pagination,result:{count:m.count,pages:m.pages,timestamp:(new Date).getTime()}}:void 0}),n.incremental&&o("loadDataPage",{type:t,opt:n,pageByLimit:c,pageByNumber:d})),!1!==n.watch){const e={type:t,revision:m.revision,namespace:n.watchNamespace||n.namespaced,force:!0===n.forceWatch};o("watch",e)}const x=C(r,t,n);return!n.incremental&&n.hasManualRefresh&&o("resource-fetch/updateManualRefreshIsLoading",!1,{root:!0}),u.A.gcUpdateLastAccessed(e,t),x},async findPage(e,{type:t,opt:n}){const{getters:r,commit:i,dispatch:o}=e;if(n=n||{},!n.pagination)return void v.error("Attempting to find a page for a resource but no pagination settings supplied",t);t=r.normalizeType(t),r.typeRegistered(t)||i("registerType",t);const a={type:t,namespace:n.watchNamespace||n.namespaced,force:!0===n.forceWatch,mode:f.g.RESOURCE_CHANGES};if(!n.transient&&!n.force&&r["havePaginatedPage"](t,n))return!1!==n.watch&&o("watch",a),C(r,t,n);let s;v.log(`Find Page: [${e.state.config.namespace}] ${t}. Page: ${n.pagination.page}. Revision: ${n.revision||"none"}. Size: ${n.pagination.pageSize}. Sort: ${n.pagination.sort?.map(e=>e.field).join(", ")}`),n=n||{},n.url=r.urlFor(t,null,n);const l=n.transient?null:N(e,t,n);try{n.hasManualRefresh&&o("resource-fetch/updateManualRefreshIsLoading",!0,{root:!0}),s=await o("request",{opt:n,type:t})}catch(h){return n.hasManualRefresh&&o("resource-fetch/updateManualRefreshIsLoading",!1,{root:!0}),Promise.reject(h)}const c=!!l&&!P(e,l),d=n.pagination?{request:{namespace:n.namespaced,pagination:n.pagination,includeAssociatedData:n.includeAssociatedData},result:{count:s.count,pages:s.pages||Math.ceil(s.count/(n.pagination.pageSize||Number.MAX_SAFE_INTEGER)),timestamp:(new Date).getTime(),revision:s.revision}}:void 0;return n.transient||c||i("loadPage",{ctx:e,type:t,data:s.data,pagination:d,revision:s.revision}),n.saveCountAs&&!c&&i("setSavedCount",{name:n.saveCountAs,count:s.count}),n.transient||!1===n.watch||o("watch",a),n.hasManualRefresh&&o("resource-fetch/updateManualRefreshIsLoading",!1,{root:!0}),u.A.gcUpdateLastAccessed(e,t),n.transient?{data:await o("createMany",s.data),pagination:d}:C(r,t,n)},async findLabelSelector(e,{type:t,matching:{namespace:n,labelSelector:r},opt:i}){const{getters:o,dispatch:a}=e;if(i=i||{},o["paginationEnabled"]?.()){if((0,g.Js)(r))throw new Error("labelSelector must not be empty when using findLabelSelector (avoid fetching all resources)");return a("findPage",{type:t,opt:{...i,namespaced:n,pagination:new m.YU({labelSelector:r}),transient:void 0!==i?.transient&&i.transient}})}const s=await a("findMatching",{type:t,selector:(0,g.Og)(r),opt:i,namespace:n});return i.transient?{data:s}:s},async findMatching(e,{type:t,selector:n,opt:r,namespace:i}){const{getters:o,commit:a,dispatch:s,rootGetters:l}=e;if(r=r||{},v.log(`Find Matching: [${e.state.config.namespace}] ${t}`,n),t=o.normalizeType(t),o.typeRegistered(t)||a("registerType",t),!0!==r.force&&o["haveSelector"](t,n))return o.all(t);if(!0!==r.force&&o["haveAll"](t))return o.matching(t,n,i);const c=l["type-map/optionsFor"](t);r=r||{},r.labelSelector=n,r.isCollection=!0,r.namespaced=i,r.url=o.urlFor(t,null,r),r.depaginate=(0,p.Ng)(c?.depaginate,{ctx:e,args:{type:t,opt:r}});const d=await s("request",{opt:r,type:t});return!1===r.load?d.data:(a("loadSelector",{ctx:e,type:t,entries:d.data,selector:n,revision:d.revision}),!1!==r.watch&&s("watch",{type:t,selector:n,revision:d.revision,force:!0===r.forceWatch}),u.A.gcUpdateLastAccessed(e,t),o.all(t))},async find(e,{type:t,id:n,opt:r}){if(!n)return void v.error("Attempting to find a resource with no id",t,n);const{getters:i,dispatch:o}=e;let a;if(r=r||{},t=(0,c.AZ)(t),v.log(`Find: [${e.state.config.namespace}] ${t} ${n}`),!0!==r.force&&(a=i.byId(t,n),a))return!1!==r.watch&&o("watch",A({type:t,id:n,opt:r,res:void 0})),a;const s=i.havePage(t);r=r||{},r.url=i.urlFor(t,n,r);const l=await o("request",{opt:r,type:t});if(s||!i.havePage(t))return r.transient||await o("load",{data:l,invalidatePageCache:r.invalidatePageCache}),r.transient||!1===r.watch||o("watch",A({type:t,id:n,opt:r,res:l})),u.A.gcUpdateLastAccessed(e,t),r.transient?await o("create",l):i.byId(t,n);v.warn(`Prevented \`find\` action from polluting cache for type "${t}" (currently represents a page).`)},load(e,{data:t,existing:n,invalidatePageCache:r}){const{getters:i,commit:a}=e;let s=(0,c.AZ)(t.type);i.typeRegistered(s)||a("registerType",s),t.baseType&&t.baseType!==t.type&&(s=(0,c.AZ)(t.baseType),i.typeRegistered(s)||a("registerType",s)),s===o.yx&&(0,d.w)(t);const l=i.keyFieldForType(s),u=t?.[l]||n?.[l];if(u)return a("load",{ctx:e,data:t,existing:n,invalidatePageCache:r}),s===o.yx&&a("type-map/schemaChanged",null,{root:!0}),i["byId"](s,u);v.warn("Attempting to load a resource with no id",t,n)},loadMulti(e,t){const{commit:n}=e;n("loadMulti",{data:t,ctx:e})},batchChanges(e,t){const{commit:n}=e;n("batchChanges",{ctx:e,batch:t})},loadAll(e,{type:t,data:n}){const{commit:r}=e;r("loadAll",{ctx:e,type:t,data:n})},create(e,t){return(0,l.L8)(e,t)},createMany(e,t){return t.map(t=>(0,l.L8)(e,t))},async createPopulated(e,t){let n=null;const r=e.getters["schemaFor"](t.type);return r&&(r.fetchResourceFields&&await r.fetchResourceFields(),n=e.getters["defaultFor"](t.type,r)),i()(n,t),(0,l.L8)(e,n)},clone(e,{resource:t}={}){return(0,l.L8)(e,t.toJSON(),!0)},forgetType({commit:e,dispatch:t,state:n},r){let i=r,o={};"object"===typeof r&&null!==r&&r.type&&(i=r.type,o=r);const{compareWatches:a,unwatch:s=!0,forget:l=!0}=o;s&&(n.started.filter(e=>a?a(e):e.type===i).forEach(e=>t("unwatch",e)),t("resetWatchBackOff",{type:i,compareWatches:a,resetStarted:!1})),l&&e("forgetType",i)},promptRemove({commit:e,state:t},n){e("action-menu/togglePromptRemove",n,{root:!0})},promptModal({commit:e,state:t},n){e("action-menu/togglePromptModal",n,{root:!0})},resourceAction({getters:e,dispatch:t},{resource:n,actionName:r,body:i,opt:o}){throw new Error("Not Implemented")},collectionAction({getters:e,dispatch:t},{type:n,actionName:r,body:i,opt:o}){throw new Error("Not Implemented")},cleanForNew(e,t){throw new Error("Not Implemented")},createNamespace(e,t){throw new Error("Not Implemented")},cleanForDiff(e,t){throw new Error("Not Implemented")},cleanForDetail(e,t){return t},cleanForDownload(e,t){const{yaml:n}="string"===typeof t?{yaml:t}:t||{};return n},async waitForSchema({getters:e,dispatch:t},{type:n}){let r=S,i=null;while(!i&&r>0)i=e["schemaFor"](n,!1,!1),i||(r===x&&v.warn(`Schema for ${n} not available... retrying...`),await new Promise(e=>setTimeout(e,1e3)),r--);0===r&&(v.warn(`Schema for ${n} still unavailable... loading schemas again...`),await t("loadSchemas",!0))},async waitForHaveAll({getters:e},{type:t,throwError:n=!1,attempts:r=E}){let i=r,o=null;while(!o&&i>0)o=e["haveAll"](t),o||(i===x&&v.warn(`wait for all of ${t} continuing...`),await new Promise(e=>setTimeout(e,1e3)),i--);if(0===i&&n)throw new Error(`Failed to wait for all of ${t}`)},incrementLoadCounter({commit:e},t){e("incrementLoadCounter",t)},garbageCollect(e,t){return u.A.garbageCollect(e,t)},gcResetStore({state:e}){u.A.gcResetStore(e)}}},50382:function(e,t,n){"use strict";n.d(t,{L8:function(){return o},vX:function(){return i}});var r=n(73883);const i="byType";function o(e,t,n=!1){if(t instanceof r.Ay)return t;const i=e.getters["classify"](t),o=new i(t,e,null,n);return o}},86794:function(e,t,n){"use strict";n.d(t,{d:function(){return m}});var r=n(35664),i=n(9262),o=n(38823),a=n(37648),s=n(73883),l=n(96730),c=n(79401),u=n(48074),d=n(90599),h=n(15092),p=n(3704),f=n(4364);const m=(e,t)=>(n,r,i)=>{i=i||{},n=t.normalizeType(n);let o,a=i.url;if(!a){if(o=t.schemaFor(n),!o)throw new Error(`Unknown schema for type: ${n}`);if(a=o.links.collection,!a)throw new Error(`You don't have permission to list this type: ${n}`);r&&(a+=`/${r}`)}if(!a.startsWith("/")&&!a.startsWith("http")){const t=e.config.baseUrl.replace(/\/$/,"");a=`${t}/${a}`}return a=t.urlOptions(a,i,o),a};function g(e,t,n){let i=n;const{name:o,count:a}=i;if(!o)throw new Error(`Resource type required to calc count: ${JSON.stringify(n)}`);if(!a){const e=t.schemaFor(o),n=t.all(r.i2)?.[0]?.counts||{},a=n[o];i={count:a?a.summary.count||0:null,byNamespace:a?a.namespaces:{},revision:a?a.revision:null,namespaced:e?.attributes?.namespaced}}const s=i?.namespaced&&!e.isAllNamespaces?Object.keys(e.activeNamespaceCache||{}):[];return v(i,s.length?s:null)}function v(e,t){if(!e.namespaced||!e.byNamespace||null===t||null===e.count)return e.count;let n=0;for(const r of t)n+=e.byNamespace[r]?.count||0;return n}t.A={all:(e,t,n)=>r=>(r=t.normalizeType(r),t.typeRegistered(r)||(f.warn(`All of ${r} is not loaded yet`),l.Ay.registerType(e,r)),d.A.gcUpdateLastAccessed({state:e,getters:t,rootState:n},r),e.types[r].list),matchingLabelSelector:(e,t,n)=>(e,n,r)=>{e=t.normalizeType(e);const i=(0,p.Og)(n),o=t["havePage"](e,i)?.request;return o?.namespace===r&&0===o?.pagination?.filters?.length&&o?.pagination.labelSelector&&i===(0,p.Og)(o?.pagination.labelSelector)||t["haveSelector"](e,i)?t.all(e):t["havePage"](e)||t["haveAll"](e)?t.matching(e,i,r):[]},matching:(e,t,n)=>(i,a,s,l={skipSelector:!1})=>{let c=t["all"](i);return s&&"string"===typeof s&&(c=i!==r.Sm||a?c.filter(e=>e.namespace===s):t["podsByNamespace"](s)),d.A.gcUpdateLastAccessed({state:e,getters:t,rootState:n},i),l.skipSelector?c:c.filter(e=>(0,o.cK)(e,a))},byId:(e,t,n)=>(r,i)=>{r=t.normalizeType(r);const o=e.types[r];if(o)return d.A.gcUpdateLastAccessed({state:e,getters:t,rootState:n},r),o.map.get(i)},brand:(e,t)=>{const n=t["byId"](r.Mc.SETTING,i.HG.BRAND);if(n?.value)return[r.qt.FEDERAL,r.qt.RGS].includes(n.value)?r.qt.SUSE:n.value},pathExistsInSchema:(e,t)=>(e,t)=>!1,schema:(e,t)=>n=>{n=t.normalizeType(n);const i=e.types[r.yx],o=t.keyFieldForType(r.yx);return i.list.find(e=>{const r=t.normalizeType(e[o]);return r===n||r.endsWith(`.${n}`)})},schemaName:(e,t)=>n=>{n=t.normalizeType(n);const i=e.types[r.yx],o=t.keyFieldForType(r.yx),a=i.list.find(e=>{const r=t.normalizeType(e[o]);return r===n||r.endsWith(`.${n}`)});if(!a)return;const s=Array.isArray(a)?a:[a],l=s.map(e=>e[o]).sort((e,t)=>e.length-t.length);return l[0]?l[0]:n},schemaFor:(e,t)=>(n,i=!1,o=!0)=>{const a=e.types[r.yx];if(n=t.normalizeType(n),!a){if(o)throw new Error("Schemas aren't loaded yet");return null}const s=a.map.get(n);if(!s&&i){const e=t.schemaName(n);if(e)return t.schemaFor(e)}return s},defaultFor:(e,t)=>(e,n,r=null)=>{let i;if(r)if(n.requiresResourceFields)i=r[e]?.resourceFields||{};else{const n=t["schemaFor"](e);i=n?.resourceFields||{}}else r=n.schemaDefinitions||{},i=n.resourceFields||{};const o={};for(const s in i){const e=i[s];if(!e)continue;const l=(0,a.fs)(e.type),c=(0,a.Cd)("map",l,e),u=(0,a.Cd)("array",l,e),d=(0,a.Cd)("reference",l);c||"map"===l||"json"===l?o[s]=t.defaultFor(l,n,r):u||"array"===l?o[s]=[]:d?o[s]=void 0:a.xs.includes(l)?"undefined"===typeof e["default"]?o[s]=void 0:o[s]=e["default"]:o[s]=t.defaultFor(l,n,r)}return o},canGet:(e,t)=>e=>{const n=t.schemaFor(e);return n?.canGet},canList:(e,t)=>e=>{const n=t.schemaFor(e);return n?.canList},typeRegistered:(e,t)=>n=>(n=t.normalizeType(n),!!e.types[n]),typeEntry:(e,t)=>n=>(n=t.normalizeType(n),e.types[n]),haveAll:(e,t)=>n=>{n=t.normalizeType(n);const r=e.types[n];return r&&r.haveAll||!1},haveAllNamespace:(e,t)=>(n,r)=>{if(!r)return!1;n=t.normalizeType(n);const i=e.types[n];return!!i&&i.haveNamespace===r},havePaginatedPage:(e,t)=>(n,r)=>{if(!r.pagination)return!1;n=t.normalizeType(n);const i=e.types[n];if(i?.havePage){const{namespace:e,pagination:t}=i.havePage.request,{namespace:n,pagination:o}={namespace:r.namespaced,pagination:r.pagination};return i.havePage&&e===n&&h.A.paginationEqual(t,o)}return!1},haveNamespace:(e,t)=>n=>(n=t.normalizeType(n),e.types[n]?.haveNamespace||null),havePage:(e,t)=>n=>(n=t.normalizeType(n),e.types[n]?.havePage||null),haveSelector:(e,t)=>(n,r)=>{n=t.normalizeType(n);const i=e.types[n];return i&&i.haveSelector[r]||!1},normalizeType:()=>e=>(0,c.AZ)(e),keyFieldForType:()=>e=>(0,c.BZ)(e),urlFor:m,urlOptions:()=>(e,t,n)=>e,storeName:e=>e.config.namespace,defaultModel:()=>()=>{},classify:(e,t,n)=>t=>(0,u.$)(e.config.namespace,t?.type,t?.metadata?.name,n)||s.Ay,cleanResource:()=>(e,t)=>t,isClusterStore:e=>e.config.isClusterStore,loadCounter:(e,t)=>n=>(n=t.normalizeType(n),e.types[n]?e.types[n].loadCounter:0),gcIgnoreTypes:()=>({}),count:(e,t,n,r)=>e=>{const n=r["type-map/optionsFor"](e.name).subTypes||[];return n.length?n.reduce((e,n)=>e+g(r,t,{name:n}),0):g(r,t,e)},generation:(e,t)=>n=>{n=t.normalizeType(n);const r=e.types[n];if(r)return r.generation},paginationEnabled:(e,t,n,r)=>t=>{if(!t)return!0;const i="object"===typeof t?t.id:t,o="object"===typeof t?t.context:void 0,a=e.config.namespace,s=i||o?{id:i,context:o}:null;return h.A.isEnabled({rootGetters:r,$extension:n.$extension},{store:a,resource:s})},isSteveUrl:e=>()=>!1,getSavedCount:e=>t=>e.savedCounts[t]}},25314:function(e,t,n){"use strict";n.d(t,{Ut:function(){return l},fs:function(){return s}});var r=n(63905),i=n(86794),o=n(96730),a=n(9274);const s={strict:!1,namespaced:!0,state(){return{...l()}},getters:{...i.A},mutations:{...o.Ay},actions:{...r.Ay}},l=(e,t,n)=>({config:{baseUrl:t,namespace:e,isClusterStore:n},types:{},savedCounts:{},latestPageRequests:{},$ctx:(0,a.markRaw)({})});var c=(e,t,n)=>{const r=t.namespace||"";return function(i){i.registerModule(r,e),i.commit(`${r}/applyConfig`,t);const o=i._modules.root._children[r],a=new Proxy(o.context,{get(e,t){return"rootGetters"===t?i.getters:e[t]}});n&&n(i,a)}};(Object.getOwnPropertyDescriptor(c,"name")||{}).writable||Object.defineProperty(c,"name",{value:"default",configurable:!0})},48074:function(e,t,n){"use strict";n.d(t,{$:function(){return l}});var r=n(79401);function i(e){return n(93197)(`./${e}`)}var o=n(4364);const a={};function s(e,t,n){const r=e[t];if(r)return r;if("undefined"!==typeof r)return null;try{const r=n.$extension.getDynamic("models",t);let o;if(o=r?"function"===typeof r?r():r:i(t),o?.default?.prototype)return e[t]=o.default,o.default}catch(a){"MODULE_NOT_FOUND"!==a?.code&&o.error("Find error",t,a)}return e[t]=null,null}function l(e,t,n,i){let o;t=(0,r.AZ)(t).replace(/\//g,"");const l=[`${e}/${t}`,t];for(const r of l)if(o=s(a,r,i),o)return o;return null}},96730:function(e,t,n){"use strict";n.d(t,{AJ:function(){return y},HC:function(){return h},Hh:function(){return m},TF:function(){return b},WI:function(){return g},aW:function(){return O},gh:function(){return w},zp:function(){return v}});var r=n(9274),i=n(68851),o=n(35664),a=n(79401),s=n(37417),l=n(50382),c=n(90599),u=n(4364);function d(e,t){let n=e.types[t];return n||(n={list:[],haveAll:!1,haveSelector:{},haveNamespace:void 0,havePage:void 0,revision:0,generation:0,loadCounter:0,map:new Map},e.types[t]=n),n}function h(e,t){const n={};for(const r of Object.keys(e))delete e[r],n[r]=!0;let i=!1;for(const r of Object.keys(t))i||n[r]||(i=!0),e[r]=t[r];return i?(0,r.reactive)(e):e}function p(e,t,n){return t=n.cleanResource(e,t),h(e,t)}function f(e,t){const{getters:n}=e,r=(0,a.AZ)(t),i=n.keyFieldForType(r),o=e.rootGetters["type-map/optionsFor"](r);return{type:r,keyField:i,opts:o}}function m(e,{data:t,ctx:n,existing:c,cachedArgs:u,invalidatePageCache:h=!0}){const{getters:m}=n,{type:g,keyField:v,opts:b}=u||f(n,t.type);let y=g;const w=b?.limit;y===o.yx&&(0,s.w)(t);const O=t[v];let S=d(e,y);S.generation++;let E=S.map.get(O);const x=!!E;if(c&&!c.id){const e=p(c,t,m);E=x?p(E,e,m):e}else if(x){const e=c&&E!==c?p(c,t,m):t;E=p(E,e,m)}else E=(0,r.reactive)((0,l.L8)(n,t));if(x||(S.list.push(E),S.map.set(O,E)),w&&S.list.length>w){const e=S.list.shift();S.map.delete(e.id)}return t.baseType&&(y=(0,a.AZ)(t.baseType),S=e.types[y],S&&((0,i.PG)(S.list,E),S.map.set(O,E))),S.havePage=!h&&S.havePage,E}function g(e,t){const n=e.types[t];if(n)return n.haveAll=!1,n.haveSelector={},n.haveNamespace=void 0,n.havePage=void 0,n.revision=0,n.generation=0,(0,i.IU)(n.list),n.map.clear(),delete e.types[t],c.A.gcResetType(e,t),!0}function v(e,t){u.log("Reset store: ",e.config.namespace);for(const n of Object.keys(e.types))t(`${e.config.namespace}/forgetType`,n);c.A.gcResetStore(e)}function b(e,t,n){if(t){let r=(0,a.AZ)(t.type);const o=n[`${e.config.namespace}/keyFieldForType`](r),s=t[o];let l=e.types[r];l&&((0,i.Gj)(l.list,t),l.map.delete(s)),t.baseType&&(r=(0,a.AZ)(t.baseType),l=e.types[r],l&&((0,i.Gj)(l.list,t),l.map.delete(s)))}}function y(e,{ctx:t,batch:n}){const i=Object.keys(n),c={};i.forEach(e=>{c[e]=n[e];const r=t.rootGetters["type-map/optionsFor"](e);if(r?.alias?.length>0){const t=r?.alias||[];t.forEach(t=>{c[t]={};for(const[r,i]of Object.entries(n[e]))c[t][r]={...i,type:t}})}});const u=Object.keys(c);u.forEach(n=>{const i=(0,a.AZ)("counts"===n?o.i2:n),u=(0,a.BZ)(i),h=d(e,i),f={};h.list.forEach((e,t)=>{f[e[u]]=t});const m=[];Object.keys(c[i]).forEach(e=>{const n=f[e],a=c[i][e];if(0===Object.keys(a).length&&void 0!==n)h.map.delete(e),m.push(n);else if(0===Object.keys(a).length);else{i===o.yx&&(0,s.w)(a);const c=(0,r.reactive)((0,l.L8)(t,a));void 0===n?(h.list.push(c),h.map.set(e,c),f[c[u]]=h.list.length-1):p(h.list[n],a,t.getters)}}),m.sort().forEach((e,t)=>{h.list.splice(e-t,1)});const g=t.rootGetters["type-map/optionsFor"](n),v=g?.limit;if(v&&h.list.length>v){const e=h.list.shift();h.map.delete(e.id)}h.generation++})}function w(e,{type:t,data:n,ctx:o,skipHaveAll:a,namespace:s,revision:c}){const{getters:u}=o;if(!n)return;const h=o.rootGetters["type-map/optionsFor"](t),p=h?.limit;p&&(n=n.slice(-p));const f=u.keyFieldForType(t),m=(0,r.reactive)(n.map(e=>(0,l.L8)(o,e))),g=d(e,t);(0,i.IU)(g.list),g.map.clear(),g.revision=c||0,g.generation++,(0,i.cn)(g.list,m);for(let r=0;r<m.length;r++)g.map.set(m[r][f],m[r]);return a||(s?(g.havePage=!1,g.haveNamespace=s,g.haveAll=!1):(g.havePage=!1,g.haveNamespace=!1,g.haveAll=!0)),m}function O(e,{type:t,data:n,ctx:r}){const{getters:i}=r,o=i.keyFieldForType(t),a=f(r,n?.[0]?.type);n.forEach(n=>{const i=e.types[t].map.get(n[o]);m(e,{data:n,ctx:r,existing:i,cachedArgs:a})})}t.Ay={registerType:d,load:m,applyConfig(e,t){e.config||(e.config={}),Object.assign(e.config,t)},loadMulti(e,{data:t,ctx:n}){for(const r of t)m(e,{data:r,ctx:n})},loadSelector(e,{type:t,entries:n,ctx:o,selector:a,revision:s}){const c=o.getters.keyFieldForType(t),u=d(e,t),h=(0,r.reactive)(n.map(e=>(0,l.L8)(o,e)));(0,i.IU)(u.list),u.map.clear(),u.generation++,(0,i.cn)(u.list,h);for(let r=0;r<h.length;r++)u.map.set(h[r][c],h[r]);u.havePage=void 0,u.haveNamespace=void 0,u.haveSelector={[a]:!0},u.haveAll=void 0,u.revision=s||0},loadAll:w,batchChanges:y,loadMerge(e,{type:t,data:n,ctx:r}){const{commit:i,getters:o}=r,a=o.keyFieldForType(t),s=e.types[t],l=f(r,n?.[0].type);n.forEach(n=>{const i=e.types[t].map.get(n[a]);m(e,{data:n,ctx:r,existing:i,cachedArgs:l})}),s.list.forEach(e=>{n.find(t=>t.id===e.id)||i("remove",e)})},loadAdd:O,loadPage(e,{type:t,data:n,ctx:i,pagination:o,revision:a}){if(!n)return;const s=i.getters.keyFieldForType(t),c={},u=(0,r.reactive)(n.map(e=>(c[e[s]]=!0,(0,l.L8)(i,e)))),h=d(e,t);h.generation++;const f=new Map(h.list.map(e=>[e[s],e])),m=u.map(e=>{const t=f.get(e[s]);return t?(p(t,e,i.getters),t):e});h.list.splice(0,h.list.length,...m),h.map.forEach((e,t)=>{c[e[s]]||h.map.delete(t)});for(let r=0;r<u.length;r++){const e=h.map.get(u[r][s]),t=u[r];e?p(e,t,i.getters):h.map.set(t[s],t)}return h.havePage=o,h.haveNamespace=void 0,h.haveAll=void 0,h.revision=a,u},forgetAll(e,{type:t}){const n=d(e,t);(0,i.IU)(n.list),n.map.clear(),n.generation++},setHaveAll(e,{type:t}){const n=d(e,t);n.haveAll=!0},setHaveNamespace(e,{type:t,namespace:n}){const r=d(e,t);r.haveNamespace=n},setSavedCount(e,{name:t,count:n}){e.savedCounts[t]=n},loadedAll(e,{type:t}){const n=d(e,t);n.generation++,n.haveAll=!0},remove(e,t){t&&b(e,t,this.getters)},reset(e){v(e,this.commit)},forgetType:g,incrementLoadCounter(e,t){const n=e.types[t];n&&n.loadCounter++}}},79401:function(e,t,n){"use strict";n.d(t,{AZ:function(){return l},BZ:function(){return s},Rq:function(){return c}});var r=n(35664),i=n(76978),o=n(4364);const a={[r.yx]:"_id",default:"id"};function s(e){return a[e]||a["default"]}function l(e){return e=(e?.type||e||"").toLowerCase(),e}async function c(e,t,n,r,a,s=e=>e.toJSON()){const l=await r.dispatch(`${a}/cleanForDiff`,s(e),{root:!0}),c=await r.dispatch(`${a}/cleanForDiff`,s(t),{root:!0}),u=await r.dispatch(`${a}/cleanForDiff`,s(n),{root:!0}),d=(0,i.no)(l,u),h=(0,i.no)(l,c),p=(0,i.MA)(d,h);if(o.log("Background Change",d),o.log("User Change",h),o.log("Conflicts",p),t.metadata.resourceVersion=n.metadata.resourceVersion,(0,i.TJ)(t,d),p.length){const e=[r.getters["i18n/t"]("validation.conflict",{fields:p.join(", "),fieldCount:p.length})];return e}return!1}},73883:function(e,t,n){"use strict";n.d(t,{qE:function(){return oe},xj:function(){return pe},jv:function(){return de},uU:function(){return me},Ay:function(){return Se},rv:function(){return we},hb:function(){return he},aB:function(){return be},Cb:function(){return ge},ch:function(){return ve},gs:function(){return ye}});var r=n(2841),i=n(83297),o=n(91251),a=n(2722),s=n.n(a),l=n(14220),c=n(35664),u=n(41476),d=n(68851),h=n(3514),p=n.n(h);function f(e,t,n,r){const i=r.includes("verifyLocal"),o=e.localOutputRefs||[],a=e.globalOutputRefs||[];i?p()(o)&&p()(a)&&n.push(t["i18n/t"]("validation.flowOutput.both")):p()(a)&&n.push(t["i18n/t"]("validation.flowOutput.global"))}function m(e,t,n,r){p()(e)||p()(e.api_key)&&n.push(t["i18n/t"]("validation.output.logdna.apiKey"))}var g=n(96047);function v(e,t,n,r){const{ports:i,type:o}=e;return"ExternalName"===o?n:p()(i)?(n.push(t["i18n/t"]("validation.required",{key:"Port Rules"})),n):(i.forEach((e,r,i)=>{const{name:o,nodePort:a,port:s,targetPort:l}=e,c=r+1;if(i.length>1&&p()(o)&&n.push(t["i18n/t"]("validation.service.ports.name.required",{position:c})),!p()(o)){const e=(0,g.um)(o,"name",t,void 0,n);p()(e)||(n=n.length&&n.length>0?[...n,...e]:e)}if(a){const e=parseInt(a,10);isNaN(e)&&n.push(t["i18n/t"]("validation.service.ports.nodePort.requiredInt",{position:c}))}if(s){const e=parseInt(s,10);isNaN(e)&&n.push(t["i18n/t"]("validation.service.ports.port.requiredInt",{position:c}))}else n.push(t["i18n/t"]("validation.service.ports.port.required",{position:c}));if(l){const e=t["i18n/t"]("validation.service.ports.targetPort.ianaAt",{position:c}),r=parseInt(l,10),i=new RegExp("^\\d+$"),o=i.test(l);if(o)(r<1||r>65535)&&n.push(t["i18n/t"]("validation.service.ports.targetPort.between",{position:c}));else{const r={ianaServiceName:!0,maxLength:15,validChars:"A-Za-z0-9-"},i=(0,g.um)(l,e,t,r,n);p()(i)||n.push(...i)}}else n.push(t["i18n/t"]("validation.service.ports.targetPort.required",{position:c}))}),n)}function b(e,t,n,r){const i=["ClusterIP","NodePort","LoadBalancer"],o=e?.type;return i.includes(o),n}function y(e,t,n,r){if("ExternalName"===e?.type)if(p()(e?.externalName))n.push(t["i18n/t"]("validation.service.externalName.none"));else{const r=(0,g.cO)(e.externalName,"ExternalName",t,void 0,n);p()(r)||(n=n.length&&n.length>0?[...n,...r]:r)}return n}var w=n(52103),O=n.n(w);function S(e,t,n,r){return p()(e?.groups)&&n.push(t["i18n/t"]("validation.prometheusRule.groups.required")),n}function E(e=[],t,n,r){return e.forEach((e,r)=>{const i=r+1;p()(e?.name)&&n.push(t["i18n/t"]("validation.prometheusRule.groups.valid.name",{index:i})),p()(e?.rules)?n.push(t["i18n/t"]("validation.prometheusRule.groups.valid.singleEntry",{index:i})):e.rules.forEach((e,r)=>{const o=r+1;O()(e,"alert")&&p()(e?.alert)?n.push(t["i18n/t"]("validation.prometheusRule.groups.valid.rule.alertName",{groupIndex:i,ruleIndex:o})):O()(e,"record")&&p()(e?.record)&&n.push(t["i18n/t"]("validation.prometheusRule.groups.valid.rule.recordName",{groupIndex:i,ruleIndex:o})),(O()(e,"expr")&&p()(e.expr)||!O()(e,"expr"))&&n.push(t["i18n/t"]("validation.prometheusRule.groups.valid.rule.expr",{groupIndex:i,ruleIndex:o})),O()(e,"alert")&&(O()(e,"labels")&&p()(e.labels)||!O()(e,"labels"))&&n.push(t["i18n/t"]("validation.prometheusRule.groups.valid.rule.labels",{groupIndex:i,ruleIndex:o}))})}),n}function x(e,t,n,r){p()(e?.match)&&p()(e?.["match_re"])&&n.push(t["i18n/t"]("validation.monitoring.route.match"))}function _(e,t,n,r,i){/^\d+[hms]$/.test(e)||n.push(t["i18n/t"]("validation.monitoring.route.interval",{key:i}))}var k=n(76978);function C(e,t,n){let r;r=e.jobTemplate?(0,k.Jt)(e,"jobTemplate.spec.template.spec"):(0,k.Jt)(e,"template.spec"),r.containers&&r.containers.length?r.containers.forEach(e=>{e&&!e.image&&n.push(t["i18n/t"]("workload.validation.containerImage",{name:e.name}))}):n.push(t["i18n/t"]("validation.required",{key:t["i18n/t"]("workload.container.titles.containers")}))}var A=n(70500);function T(e,t,n){if(!e)return;const{podAffinity:r,podAntiAffinity:i}=e;if(r&&!(0,k.Im)(r)){const{preferredDuringSchedulingIgnoredDuringExecution:e=[],requiredDuringSchedulingIgnoredDuringExecution:i=[]}=r;e.forEach((e,r)=>{const i={index:r,group:t["i18n/t"]("validation.podAffinity.affinityTitle"),rules:t["i18n/t"]("validation.podAffinity.preferredDuringSchedulingIgnoredDuringExecution")};R(e,i,t,n);const{podAffinityTerm:o={}}=e;N(o,i,t,n),P(o,i,t,n)}),i.forEach((e,r)=>{const i={index:r,group:t["i18n/t"]("validation.podAffinity.affinityTitle"),rules:t["i18n/t"]("validation.podAffinity.requiredDuringSchedulingIgnoredDuringExecution")};N(e,i,t,n),P(e,i,t,n)})}if(i&&!(0,k.Im)(i)){const{preferredDuringSchedulingIgnoredDuringExecution:e=[],requiredDuringSchedulingIgnoredDuringExecution:r=[]}=i;e.forEach((e,r)=>{const i={index:r,group:t["i18n/t"]("validation.podAffinity.antiAffinityTitle"),rules:t["i18n/t"]("validation.podAffinity.preferredDuringSchedulingIgnoredDuringExecution")};R(e,i,t,n);const{podAffinityTerm:o={}}=e;N(o,i,t,n),P(o,i,t,n)}),r.forEach((e,r)=>{const i={index:r,group:t["i18n/t"]("validation.podAffinity.antiAffinityTitle"),rules:t["i18n/t"]("validation.podAffinity.requiredDuringSchedulingIgnoredDuringExecution")};N(e,i,t,n),P(e,i,t,n)})}}function R(e,t,n,r){const{weight:i=1}=e;("number"!==typeof i||i>100||i<1)&&r.push(n["i18n/t"]("validation.number.between",{key:n["i18n/t"]("workload.scheduling.matchExpressions.weight"),min:1,max:100,...t}))}function N(e,t,n,r){const{topologyKey:i}=e,o=RegExp("([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]");i&&o.test(i)||r.push(n["i18n/t"]("validation.podAffinity.topologyKey",t))}function P(e,t,n,r){const i=["In","NotIn","Exists","DoesNotExist"],{labelSelector:o}=e;if(o&&!(0,k.Im)(o)){const{matchExpressions:e=[]}=o;e.forEach((e,o)=>{const{operator:a,values:s}=e;i.includes(a)||r.push(n["i18n/t"]("validation.podAffinity.matchExpressions.operator",t)),"In"===a||"NotIn"===a?s&&s.length||r.push(n["i18n/t"]("validation.podAffinity.matchExpressions.valuesMustBeDefined",t)):s&&s.length&&r.push(n["i18n/t"]("validation.podAffinity.matchExpressions.valueMustBeEmpty",t))})}}function I(e=[],t,n,r=[]){e.some(e=>p()(e.verbs))&&n.push(t["i18n/t"]("validation.roleTemplate.roleTemplateRules.missingVerb")),e.some(e=>e.resources?.length&&e.nonResourceURLs?.length)&&n.push(t["i18n/t"]("validation.roleTemplate.roleTemplateRules.noResourceAndNonResource")),r[0]===c.lk.ROLE?(e.some(e=>p()(e.resources))&&n.push(t["i18n/t"]("validation.roleTemplate.roleTemplateRules.missingResource")),e.some(e=>p()(e.apiGroups))&&n.push(t["i18n/t"]("validation.roleTemplate.roleTemplateRules.missingApiGroup"))):e.some(e=>e.resources?.length&&e.nonResourceUrls?.length)&&n.push(t["i18n/t"]("validation.roleTemplate.roleTemplateRules.noResourceAndNonResource")),e.some(e=>p()(e.resources)&&p()(e.nonResourceURLs))&&n.push(t["i18n/t"]("validation.roleTemplate.roleTemplateRules.missingOneResource"))}function M(e,t,n,r,i){const o="true"===r[0];return o&&(e||"").match(/^(c-.{5}|local)$/i)&&n.push(t["i18n/t"]("validation.cluster.name")),n}var D={clusterName:M,clusterIp:b,externalName:y,flowOutput:f,groupsAreValid:E,logdna:m,ruleGroups:S,interval:_,servicePort:v,matching:x,containerImages:C,cronSchedule:A.u,podAffinity:T,roleTemplateRules:I},L=n(6198),B=n(88339),$=n(74302),V=n(92043),F=n(10078),j=n(71274),U=n(23330),G=n(20246),H=n.n(G),q=n(16238),Q=n.n(q),z=(n(68371),n(93655)),K=n.n(z),W=n(8138),X=n.n(W),Y=n(9274),Z=n(79401),J=n(31915),ee=n(25659),te=n(38823),ne=n(6855),re=n(81268),ie=n(4364);const oe=["dnsLabel","dnsLabelRestricted","hostname"],ae={disabled:"inactive",notapplied:"Not Applied",notready:"Not Ready",waitapplied:"Wait Applied",outofsync:"Out of Sync","in-progress":"In Progress",gitupdating:"Git Updating",errapplied:"Err Applied",waitcheckin:"Wait Check-In",off:"Disabled",waitingforinfrastructure:"Waiting for Infra",waitingfornoderef:"Waiting for Node Ref",waitingfordependency:"Waiting for Dependency"},se="warning",le="x",ce=1e3,ue=3e4,de={IN_USE:"in-use",IN_PROGRESS:"in-progress",PENDING_ROLLBACK:"pending-rollback",PENDING_UPGRADE:"pending-upgrade",ABORTED:"aborted",ACTIVATING:"activating",ACTIVE:"active",AVAILABLE:"available",BACKED_UP:"backedup",BOUND:"bound",BUILDING:"building",COMPLETED:"completed",CORDONED:"cordoned",CANCELLED:"cancelled",COUNT:"count",CREATED:"created",CREATING:"creating",DEACTIVATING:"deactivating",DEGRADED:"degraded",DENIED:"denied",DEPLOYED:"deployed",DEPLOYING:"deploying",DISABLED:"disabled",DISCONNECTED:"disconnected",DRAINED:"drained",DRAINING:"draining",ENABLED:"enabled",ERR_APPLIED:"errapplied",ERROR:"error",ERRORING:"erroring",ERRORS:"errors",EXPIRED:"expired",EXPIRING:"expiring",FAIL:"fail",FAILED:"failed",HEALTHY:"healthy",INACTIVE:"inactive",INFO:"info",INITIALIZING:"initializing",INPROGRESS:"inprogress",LOCKED:"locked",MIGRATING:"migrating",MISSING:"missing",MODIFIED:"modified",NOT_APPLICABLE:"notApplicable",NOT_APLLIED:"notapplied",NOT_READY:"notready",OFF:"off",ORPHANED:"orphaned",OTHER:"other",OUT_OF_SYNC:"outofsync",ON_GOING:"on-going",PASS:"pass",PASSED:"passed",PAUSED:"paused",PENDING:"pending",PROVISIONING:"provisioning",PROVISIONED:"provisioned",PURGED:"purged",PURGING:"purging",READY:"ready",RECONNECTING:"reconnecting",REGISTERING:"registering",REINITIALIZING:"reinitializing",RELEASED:"released",REMOVED:"removed",REMOVING:"removing",REQUESTED:"requested",RESTARTING:"restarting",RESTORING:"restoring",RESIZING:"resizing",RUNNING:"running",SKIP:"skip",SKIPPED:"skipped",STARTING:"starting",STOPPED:"stopped",STOPPING:"stopping",SUCCEEDED:"succeeded",SUCCESS:"success",SUCCESSFUL:"successful",SUPERSEDED:"superseded",SUSPENDED:"suspended",UNAVAILABLE:"unavailable",UNHEALTHY:"unhealthy",UNINSTALLED:"uninstalled",UNINSTALLING:"uninstalling",UNKNOWN:"unknown",UNTRIGGERED:"untriggered",UPDATING:"updating",WAIT_APPLIED:"waitapplied",WAIT_CHECKIN:"waitcheckin",WAITING:"waiting",WAITING_FOR_DEPENDENCY:"waitingfordependency",WARNING:"warning"};function he(e){return Object.values(de).find(t=>t.toLowerCase()===e.toLocaleLowerCase())}const pe={[de.IN_USE]:{color:"success",icon:"dot-open",label:"In Use",compoundIcon:"checkmark"},[de.IN_PROGRESS]:{color:"info",icon:"tag",label:"In Progress",compoundIcon:"info"},[de.PENDING_ROLLBACK]:{color:"info",icon:"dot-half",label:"Pending Rollback",compoundIcon:"info"},[de.PENDING_UPGRADE]:{color:"info",icon:"dot-half",label:"Pending Update",compoundIcon:"info"},[de.ABORTED]:{color:"warning",icon:"error",label:"Aborted",compoundIcon:"warning"},[de.ACTIVATING]:{color:"info",icon:"tag",label:"Activating",compoundIcon:"info"},[de.ACTIVE]:{color:"success",icon:"dot-open",label:"Active",compoundIcon:"checkmark"},[de.AVAILABLE]:{color:"success",icon:"dot-open",label:"Available",compoundIcon:"checkmark"},[de.BACKED_UP]:{color:"success",icon:"backup",label:"Backed Up",compoundIcon:"checkmark"},[de.BOUND]:{color:"success",icon:"dot",label:"Bound",compoundIcon:"checkmark"},[de.BUILDING]:{color:"success",icon:"dot-open",label:"Building",compoundIcon:"checkmark"},[de.COMPLETED]:{color:"success",icon:"dot",label:"Completed",compoundIcon:"checkmark"},[de.CORDONED]:{color:"info",icon:"tag",label:"Cordoned",compoundIcon:"info"},[de.CANCELLED]:{color:"warning",icon:"error",label:"Cancelled",compoundIcon:"warning"},[de.COUNT]:{color:"success",icon:"dot-open",label:"Count",compoundIcon:"checkmark"},[de.CREATED]:{color:"info",icon:"tag",label:"Created",compoundIcon:"info"},[de.CREATING]:{color:"info",icon:"tag",label:"Creating",compoundIcon:"info"},[de.DEACTIVATING]:{color:"info",icon:"adjust",label:"Deactivating",compoundIcon:"info"},[de.DEGRADED]:{color:"warning",icon:"error",label:"Degraded",compoundIcon:"warning"},[de.DENIED]:{color:"error",icon:"adjust",label:"Denied",compoundIcon:"error"},[de.DEPLOYED]:{color:"success",icon:"dot-open",label:"Deployed",compoundIcon:"checkmark"},[de.DISABLED]:{color:"warning",icon:"error",label:"Disabled",compoundIcon:"warning"},[de.DISCONNECTED]:{color:"warning",icon:"error",label:"Disconnected",compoundIcon:"warning"},[de.DRAINED]:{color:"info",icon:"tag",label:"Drained",compoundIcon:"info"},[de.DRAINING]:{color:"warning",icon:"tag",label:"Draining",compoundIcon:"warning"},[de.ENABLED]:{color:"success",icon:"dot-open",label:"Enabled",compoundIcon:"checkmark"},[de.ERR_APPLIED]:{color:"error",icon:"error",label:"Error Applied",compoundIcon:"error"},[de.ERROR]:{color:"error",icon:"error",label:"Error",compoundIcon:"error"},[de.ERRORING]:{color:"error",icon:"error",label:"Erroring",compoundIcon:"error"},[de.ERRORS]:{color:"error",icon:"error",label:"Errors",compoundIcon:"error"},[de.EXPIRED]:{color:"error",icon:"error",label:"Expired",compoundIcon:"warning"},[de.EXPIRING]:{color:"warning",icon:"error",label:"Expiring",compoundIcon:"error"},[de.FAIL]:{color:"error",icon:"error",label:"Fail",compoundIcon:"error"},[de.FAILED]:{color:"error",icon:"error",label:"Failed",compoundIcon:"error"},[de.HEALTHY]:{color:"success",icon:"dot-open",label:"Healthy",compoundIcon:"checkmark"},[de.INACTIVE]:{color:"error",icon:"dot",label:"Inactive",compoundIcon:"error"},[de.INITIALIZING]:{color:"warning",icon:"error",label:"Initializing",compoundIcon:"warning"},[de.INPROGRESS]:{color:"info",icon:"spinner",label:"In Progress",compoundIcon:"info"},[de.INFO]:{color:"info",icon:"info",label:"Info",compoundIcon:"info"},[de.LOCKED]:{color:"warning",icon:"adjust",label:"Locked",compoundIcon:"warning"},[de.MIGRATING]:{color:"info",icon:"info",label:"Migrated",compoundIcon:"info"},[de.MISSING]:{color:"warning",icon:"adjust",label:"Missing",compoundIcon:"warning"},[de.MODIFIED]:{color:"warning",icon:"edit",label:"Modified",compoundIcon:"warning"},[de.NOT_APPLICABLE]:{color:"warning",icon:"tag",label:"Not Applicable",compoundIcon:"warning"},[de.NOT_APLLIED]:{color:"warning",icon:"tag",label:"Not Applied",compoundIcon:"warning"},[de.NOT_READY]:{color:"warning",icon:"tag",label:"Not Ready",compoundIcon:"warning"},[de.OFF]:{color:"darker",icon:"error",label:"Off"},[de.ON_GOING]:{color:"info",icon:"info",label:"Info",compoundIcon:"info"},[de.ORPHANED]:{color:"warning",icon:"tag",label:"Orphaned",compoundIcon:"warning"},[de.OTHER]:{color:"info",icon:"info",label:"Other",compoundIcon:"info"},[de.OUT_OF_SYNC]:{color:"warning",icon:"tag",label:"Out Of Sync",compoundIcon:"warning"},[de.PASS]:{color:"success",icon:"dot-dotfill",label:"Pass",compoundIcon:"checkmark"},[de.PASSED]:{color:"success",icon:"dot-dotfill",label:"Passed",compoundIcon:"checkmark"},[de.PAUSED]:{color:"info",icon:"info",label:"Paused",compoundIcon:"info"},[de.PENDING]:{color:"info",icon:"tag",label:"Pending",compoundIcon:"info"},[de.PROVISIONING]:{color:"info",icon:"dot",label:"Provisioning",compoundIcon:"info"},[de.PROVISIONED]:{color:"success",icon:"dot",label:"Provisioned",compoundIcon:"checkmark"},[de.PURGED]:{color:"error",icon:"purged",label:"Purged",compoundIcon:"error"},[de.PURGING]:{color:"info",icon:"purged",label:"Purging",compoundIcon:"info"},[de.READY]:{color:"success",icon:"dot-open",label:"Ready",compoundIcon:"checkmark"},[de.RECONNECTING]:{color:"error",icon:"error",label:"Reconnecting",compoundIcon:"error"},[de.REGISTERING]:{color:"info",icon:"tag",label:"Registering",compoundIcon:"info"},[de.REINITIALIZING]:{color:"warning",icon:"error",label:"Reinitializing",compoundIcon:"warning"},[de.RELEASED]:{color:"warning",icon:"error",label:"Released",compoundIcon:"warning"},[de.REMOVED]:{color:"error",icon:"trash",label:"Removed",compoundIcon:"error"},[de.REMOVING]:{color:"info",icon:"trash",label:"Removing",compoundIcon:"info"},[de.REQUESTED]:{color:"info",icon:"tag",label:"Requested",compoundIcon:"info"},[de.RESTARTING]:{color:"info",icon:"adjust",label:"Restarting",compoundIcon:"info"},[de.RESTORING]:{color:"info",icon:"medicalcross",label:"Restoring",compoundIcon:"info"},[de.RESIZING]:{color:"warning",icon:"dot",label:"Resizing",compoundIcon:"warning"},[de.RUNNING]:{color:"success",icon:"dot-open",label:"Running",compoundIcon:"checkmark"},[de.SKIP]:{color:"info",icon:"dot-open",label:"Skip",compoundIcon:"info"},[de.SKIPPED]:{color:"info",icon:"dot-open",label:"Skipped",compoundIcon:"info"},[de.STARTING]:{color:"info",icon:"adjust",label:"Starting",compoundIcon:"info"},[de.STOPPED]:{color:"error",icon:"dot",label:"Stopped",compoundIcon:"error"},[de.STOPPING]:{color:"info",icon:"adjust",label:"Stopping",compoundIcon:"info"},[de.SUCCEEDED]:{color:"success",icon:"dot-dotfill",label:"Succeeded",compoundIcon:"checkmark"},[de.SUCCESS]:{color:"success",icon:"dot-open",label:"Success",compoundIcon:"checkmark"},[de.SUCCESSFUL]:{color:"success",icon:"dot-open",label:"Successful"},[de.SUPERSEDED]:{color:"info",icon:"dot-open",label:"Superseded",compoundIcon:"info"},[de.SUSPENDED]:{color:"info",icon:"pause",label:"Suspended",compoundIcon:"info"},[de.UNAVAILABLE]:{color:"error",icon:"error",label:"Unavailable",compoundIcon:"error"},[de.UNHEALTHY]:{color:"error",icon:"error",label:"Unhealthy",compoundIcon:"error"},[de.UNINSTALLED]:{color:"info",icon:"trash",label:"Uninstalled",compoundIcon:"info"},[de.UNINSTALLING]:{color:"info",icon:"trash",label:"Uninstalling",compoundIcon:"info"},[de.UNKNOWN]:{color:"warning",icon:"x",label:"Unknown",compoundIcon:"warning"},[de.UNTRIGGERED]:{color:"success",icon:"tag",label:"Untriggered",compoundIcon:"checkmark"},[de.UPDATING]:{color:"warning",icon:"tag",label:"Updating",compoundIcon:"warning"},[de.WAIT_APPLIED]:{color:"info",icon:"tag",label:"Wait Applied",compoundIcon:"info"},[de.WAIT_CHECKIN]:{color:"warning",icon:"tag",label:"Wait Checkin",compoundIcon:"warning"},[de.WAITING]:{color:"info",icon:"tag",label:"Waiting",compoundIcon:"info"},[de.WAITING_FOR_DEPENDENCY]:{color:"info",icon:"tag",label:"Waiting for Dependency",compoundIcon:"info"},[de.WARNING]:{color:"warning",icon:"error",label:"Warning",compoundIcon:"warning"},[de.DEPLOYING]:{color:"info",icon:"info",label:"Deploying",compoundIcon:"info"}};const fe={error:1,warning:2,info:3,success:4,ready:5,notready:6,other:7};function me(e,t,n){if(t)return"text-error";if(n)return"text-info";const r=(e||"active").toLowerCase();let i;return pe[r]&&pe[r].color&&(i=Oe.call(this,pe[r].color)),i||(i=se),`text-${i}`}function ge(e,t=!1,n=!1){return me(e,t,n).replace("text-","")||"disabled"}function ve(e,t=!1){const n=(e||"active").toLowerCase();return ae[n]?ae[n]:t?(0,V.TF)(e):n.split(/-/).map(V.TF).join("-")}function be(e){const t=[de.ERROR,de.FAILED,de.WARNING,de.MODIFIED,de.WAIT_APPLIED,de.ORPHANED,de.MISSING,de.UNKNOWN,de.NOT_READY,de.READY],n=Object.keys(e).filter(n=>e[n]>0&&t.includes(n.toLowerCase())).sort((e,n)=>t.indexOf(e.toLowerCase())-t.indexOf(n.toLowerCase()));return n[0]?n[0]:de.UNKNOWN}function ye(e,t){return e=e.replace(/^(text|bg)-/,""),`${fe[e]||fe["other"]} ${t}`}function we(e){return!!e&&("ready"===e?.type?.toLowerCase()&&"waiting"===e?.reason?.toLowerCase())}function Oe(e){return K()(e)?e(this):e}class Se{constructor(e,t={},n=null,r=!1){for(const i in e)this[i]=e[i];Object.defineProperty(this,"$ctx",{value:(0,Y.markRaw)(t),enumerable:!1}),n&&Object.defineProperty(this,"__rehydrate",{value:n,enumerable:!0,configurable:!0}),r&&Object.defineProperty(this,"__clone",{value:!0,enumerable:!0,configurable:!0,writable:!0})}get $getters(){return this.$ctx.getters}get $rootGetters(){return this.$ctx.rootGetters}get $dispatch(){return this.$ctx.dispatch}get $state(){return this.$ctx.state}get $rootState(){return this.$ctx.rootState}get $plugin(){return this.$ctx.rootState?.$extension||this.$ctx.rootState?.$plugin}get $extension(){return this.$ctx.rootState?.$extension||this.$ctx.rootState?.$plugin}get customValidationRules(){return[]}get _key(){const e=this.metadata;if(e){if(e.uid)return e.uid;if(e.namespace)return`${this.type}/${e.namespace}/${e.name}`}return this.id?`${this.type}/${this.id}`:`${this.type}/${Math.random()}`}get schema(){return this.$getters["schemaFor"](this.type)}toString(){return`[${this.type}: ${this.id}]`}get typeDisplay(){const e=this.schema;return e?this.$rootGetters["type-map/labelFor"](e):"?"}get nameDisplay(){return this.displayName||this.spec?.displayName||this.metadata?.annotations?.[r.ks]||this.name||this.metadata?.name||this.id}get nameSort(){return(0,$.RY)(this.nameDisplay).toLowerCase()}get namespacedName(){const e=this.metadata?.namespace,t=this.nameDisplay;return e?`${e}:${t}`:t}get namespacedNameSort(){return(0,$.RY)(this.namespacedName).toLowerCase()}get groupByLabel(){const e=this.metadata?.namespace;let t;return t=e?this.t("resourceTable.groupLabel.namespace",{name:(0,V.ZD)(e)}):this.t("resourceTable.groupLabel.notInANamespace"),t}setLabels(){throw new Error("Implement setLabels in subclass")}setLabel(){throw new Error("Implement setLabel in subclass")}setAnnotations(e){throw new Error("Implement setAnnotations in subclass")}setAnnotation(e,t){throw new Error("Implement setAnnotation in subclass")}get stateDisplay(){return ve(this.state)}get stateColor(){return me.call(this,this.state,this.stateObj?.error,this.stateObj?.transitioning)}get stateColorPair(){return{state:this.stateDisplay,color:this.stateSimpleColor}}get stateSimpleColor(){return ge(this.state,this.stateObj?.error,this.stateObj?.transitioning)}get stateBackground(){return this.stateColor.replace("text-","bg-")}get stateIcon(){let e=!1,t=!1;if(this.metadata&&this.metadata.state&&(e=this.metadata.state.transitioning,t=this.metadata.state.error),e)return"icon icon-spinner icon-spin";if(t)return"icon icon-error";const n=(this.state||"").toLowerCase();let r;return pe[n]&&pe[n].icon&&(r=Oe.call(this,pe[n].icon)),r||(r=le),`icon icon-${r}`}get stateSort(){return ye(this.stateColor,this.stateDisplay)}get stateDescription(){const e=this.stateObj?.transitioning||!1,t=this.stateObj?.error||!1,n=this.stateObj?.message;return e||t?(0,V.TF)(n):""}get stateObj(){return this.metadata?.state}waitForTestFn(e,t,n,r){return(0,U.f)(()=>e.apply(this),t,n||ue,r||ce,!0)}waitForState(e,t,n){return this.waitForTestFn(()=>(this.state||"").toLowerCase()===e.toLowerCase(),`state=${e}`,t,n)}waitForTransition(){return this.waitForTestFn(()=>!this.transitioning,"transition completion",void 0,void 0)}waitForAction(e){return this.waitForTestFn(()=>this.hasAction(e),`action=${e}`,void 0,void 0)}waitForLink(e){return this.waitForTestFn(()=>this.hasLink(e),`link=${e}`,void 0,void 0)}condition(e){return(0,d.jq)(this.status?.conditions||[],"type",e)}hasCondition(e){return this.isCondition(e,null)}isCondition(e,t="True"){if(!this.status||!this.status.conditions)return!1;const n=this.condition(e);return!!n&&(!t||(n.status||"").toLowerCase()===`${t}`.toLowerCase())}waitForCondition(e,t="True",n=ue,r=ce){return this.waitForTestFn(()=>this.isCondition(e,t),`condition ${e}=${t}`,n,r)}get canEdit(){return this.canUpdate&&this.canCustomEdit}get availableActions(){const e=this._availableActions;let t=null;const n=e.filter(e=>{if(!1===e.enabled)return!1;const n=e.divider,r=!n||n&&!t;return t=n,r});while(n.length&&n[0].divider)n.shift();while(n.length&&n[n.length-1].divider)n.pop();for(let r=1;r<n.length;r++)n[r].divider&&n[r-1].divider&&((0,d.Wq)(n,r,1),r--);return n}showConfiguration(e,t){const r=()=>this.$ctx.commit("slideInPanel/close",void 0,{root:!0});this.$ctx.commit("slideInPanel/open",{component:n(48751).A,componentProps:{resource:this,onClose:r,width:"wide",height:"full",closeOnRouteChange:["name","params","query"],triggerFocusTrap:!0,returnFocusSelector:e,defaultTab:t}},{root:!0})}get _availableActions(){const e=this.currentRouter().currentRoute.value,t=(0,ee.A)(this.$rootState,J.c7.ACTION,J.ug.TABLE,e,this),n=(0,i.nv)(),r=(0,o.Z1)(n.Version),a=s().satisfies(r,">= 2.13.0"),l=a&&!0!==this.disableResourceDetailDrawer&&(this.canCustomEdit||this.canYaml),c=[{action:"showConfiguration",label:this.t("action.showConfiguration"),icon:"icon icon-document",enabled:l},{divider:!0},{action:this.canUpdate?"goToEdit":"goToViewConfig",label:this.t(this.canUpdate?"action.edit":"action.view"),icon:"icon icon-edit",enabled:this.canCustomEdit&&(this.canUpdate||!l)},{action:this.canEditYaml?"goToEditYaml":"goToViewYaml",label:this.t(this.canEditYaml?"action.editYaml":"action.viewYaml"),icon:"icon icon-file",enabled:this.canYaml&&(this.canEditYaml||!l)},{action:this.canCustomEdit?"goToClone":"cloneYaml",label:this.t("action.clone"),icon:"icon icon-copy",enabled:this.canClone&&this.canCreate&&(this.canCustomEdit||this.canYaml)},{divider:!0},{action:"download",label:this.t(this.configurableTables?"action.downloadExport":"action.download"),icon:"icon icon-download",bulkable:!0,bulkAction:"downloadBulk",enabled:this.canYaml,weight:-9},{action:"viewInApi",label:this.t("action.viewInApi"),icon:"icon icon-external-link",enabled:this.canViewInApi},{action:"promptRemove",altAction:"remove",label:this.t("action.remove"),icon:"icon icon-trash",bulkable:!0,enabled:this.canDelete,bulkAction:"promptRemove",weight:-10}];return t.length&&(c.push({divider:!0}),t.forEach(e=>{const t={...e},n=t.enabled,r=typeof n;switch(r){case"undefined":t.enabled=!0;break;case"function":Object.defineProperty(t,"enabled",{get:()=>n(this)});break;case"boolean":break;default:ie.warn(`Unsupported 'enabled' property type for action: ${e.label||e.labelKey}`),delete t.enabled;break}c.push(t)})),c}get canDelete(){return this._canDelete}get _canDelete(){return this.hasLink("remove")&&this.$rootGetters["type-map/optionsFor"](this.type).isRemovable}get canClone(){return!0}get canUpdate(){return this.hasLink("update")&&this.$rootGetters["type-map/optionsFor"](this.type).isEditable}get canCustomEdit(){return this.$rootGetters["type-map/hasCustomEdit"](this.type,this.id)}get canCreate(){return!(this.schema&&!this.schema?.collectionMethods.find(e=>"post"===e.toLowerCase()))&&this.$rootGetters["type-map/optionsFor"](this.type).isCreatable}get canViewInApi(){try{return this.hasLink("self")&&this.$rootGetters["prefs/get"](u.HZ)}catch{return this.hasLink("self")&&this.$rootGetters["prefs/get"](u.IJ)}}get canYaml(){return this.hasLink("view")}get canEditYaml(){return!this.schema?.resourceMethods?.find(e=>"blocked-PUT"===e)&&this.canUpdate}hasLink(e){return!!this.linkFor(e)}linkFor(e){return(this.links||{})[e]}followLink(e,t={}){if(t.url||(t.url=(this.links||{})[e]),t.urlSuffix&&(t.url+=t.urlSuffix),!t.url)throw new Error(`Unknown link ${e} on ${this.type} ${this.id}`);return this.$dispatch("request",{opt:t,type:this.type})}hasAction(e){return!!this.actionLinkFor(e)}actionLinkFor(e){return(this.actions||this.actionLinks||{})[e]}doAction(e,t,n={}){return this.$dispatch("resourceAction",{resource:this,actionName:e,body:t,opt:n})}async doActionGrowl(e,t,n={}){try{return await this.$dispatch("resourceAction",{resource:this,actionName:e,body:t,opt:n})}catch(r){this.$dispatch("growl/fromError",{title:this.$rootGetters["i18n/t"]("generic.notification.title.error"),err:r.data||r},{root:!0})}}patch(e,t={},n=!1,r=!1){if(t.url||(t.url=this.linkFor("view")||this.linkFor("self")),t.method="patch",t.headers=t.headers||{},!t.headers["content-type"]){const e=n?"application/strategic-merge-patch+json":"application/json-patch+json";t.headers["content-type"]=e}t.data=e;const i=this.$dispatch("request",{opt:t,type:this.type});return r?i.catch(e=>{const t=this.t("resource.errors.update",{name:this.name});ie.error(t,e),this.$dispatch("growl/error",{title:t,message:e?.message,timeout:5e3},{root:!0})}):i}save(){return this._save(...arguments)}_collectionUrl(){const e=this.$getters["schemaFor"](this.type);if(!e)throw new Error(`${this.type}: ${this.t("validation.createResourceFailed",{type:this.typeDisplay},!0)}`);let t=e.linkFor("collection");return e.attributes&&e.attributes.namespaced&&this.metadata&&this.metadata.namespace&&(t+=`/${this.metadata.namespace}`),t}async dryRunCreate(e){try{const t=this._collectionUrl(),n=t.includes("?")?"&":"?",r=e||this.cleanForSave(this.toSave()||JSON.parse(JSON.stringify(this)),!0);return this.$dispatch("request",{opt:{method:"post",url:`${t}${n}dryRun=All`,data:r,headers:{"content-type":"application/json",accept:"application/json"}},type:this.type})}catch(t){return Promise.reject(t)}}cleanForSave(e,t){return delete e.__rehydrate,delete e.__clone,e}processSaveResponse(e,t={}){}notifyGeneratedName(){}async _save(e={}){const t=!this.id;let n;if(e.skipUIValidation||(n=this.validationErrors(this,e)),!p()(n))return Promise.reject(n);this.metadata?.resourceVersion&&(this.metadata.resourceVersion=`${this.metadata.resourceVersion}`);try{e.url||(e.url=t?this._collectionUrl():this.linkFor("update")||this.linkFor("self"))}catch(i){return Promise.reject(i)}if(e.method||(e.method=t?"post":"put"),e.headers||(e.headers={}),e.headers["content-type"]||(e.headers["content-type"]="application/json"),e.headers["accept"]||(e.headers["accept"]="application/json"),"patch"!==e.method&&(e.data=this.toSave()||JSON.parse(JSON.stringify(this))),e.data._type&&(e.data.type=e.data._type),e.data._name&&(e.data.name=e.data._name),e.data._labels&&(e.data.labels=e.data._labels),e.data._annotations&&(e.data.annotations=e.data._annotations),"patch"!==e.method&&(e.data=this.cleanForSave(e.data,t)),e?.replace&&"put"===e.method){const t=e.url.includes("?")?"&":"?";e.url=`${e.url}${t}_replace=true`,delete e.replace}const r=e.invalidatePageCache||!1;try{const n=await this.$dispatch("request",{opt:e,type:this.type});if(this.processSaveResponse(n,e),n&&"Table"!==n.kind){const e=this.$getters.keyFieldForType(this.type),i=n[e];i&&await this.$dispatch("load",{data:n,existing:t?this:void 0,invalidatePageCache:r})}}catch(i){return this.type&&this.id&&409===i?._status&&await this.$dispatch("find",{type:this.type,id:this.id,opt:{force:!0,watch:!1,invalidatePageCache:r}}),Promise.reject(i)}return this}remove(){return this._remove(...arguments)}async _remove(e={}){e.url||(e.url=this.linkFor("self")),e.method="delete";const t=await this.$dispatch("request",{opt:e,type:this.type});200===t?._status?await this.$dispatch("load",{data:t,existing:this,invalidatePageCache:!1}):204===t?._status&&await this.$dispatch("ws.resource.remove",{data:this})}currentRoute(){return window.$globalApp.$route}currentRouter(){return window.$globalApp.$router}get isProdRegistrationV2TopLevelProductResoure(){let e="";const t=this.$extension.getPlugins(),n=this.$rootGetters["productId"];return Object.keys(t).forEach(r=>{t[r].productNames.includes(n)&&(e=r)}),(0,F.e)(t[e],n)}get listLocation(){return this.isProdRegistrationV2TopLevelProductResoure?{name:`${this.$rootGetters["productId"]}-c-cluster-resource`,params:{product:this.$rootGetters["productId"],cluster:this.$rootGetters["clusterId"],resource:this.type}}:{name:"c-cluster-product-resource",params:{product:this.$rootGetters["productId"],cluster:this.$rootGetters["clusterId"],resource:this.type}}}get _detailLocation(){const e=this.$getters["schemaFor"](this.type),t=e?.attributes?.namespaced,n=this.id?.replace(/.*\//,"");return this.isProdRegistrationV2TopLevelProductResoure?{name:`${this.$rootGetters["productId"]}-c-cluster-resource${e?.attributes?.namespaced?"-namespace":""}-id`,params:{product:this.$rootGetters["productId"],cluster:this.$rootGetters["clusterId"],resource:this.type,namespace:t&&this.metadata?.namespace?this.metadata.namespace:void 0,id:n}}:{name:`c-cluster-product-resource${e?.attributes?.namespaced?"-namespace":""}-id`,params:{product:this.$rootGetters["productId"],cluster:this.$rootGetters["clusterId"],resource:this.type,namespace:t&&this.metadata?.namespace?this.metadata.namespace:void 0,id:n}}}get detailLocation(){return this._detailLocation}get detailPageAdditionalActions(){}goToDetail(){this.currentRouter().push(this.detailLocation)}goToClone(e={}){const t=this.detailLocation;t.query={...t.query,[l.g]:l.dT,[l.AS]:l.xz,...e},this.currentRouter().push(t)}goToEdit(e={},t=this.detailLocation){t.query={...t.query,[l.g]:l.G5,[l.AS]:l.xz,...e},this.currentRouter().push(t)}goToViewConfig(e={}){const t=this.detailLocation;t.query={...t.query,[l.g]:l.nW,[l.AS]:l.au,...e},this.currentRouter().push(t)}goToEditYaml(){const e=this.detailLocation;e.query={...e.query,[l.g]:l.G5,[l.AS]:l.zD},this.currentRouter().push(e)}goToViewYaml(){const e=this.detailLocation;e.query={...e.query,[l.g]:l.nW,[l.AS]:l.zD},this.currentRouter().push(e)}cloneYaml(e={}){const t=this.detailLocation;t.query={...t.query,[l.g]:l.dT,[l.AS]:l.zD,...e},this.currentRouter().push(t)}get configurableTables(){return(0,re.Q_)({rootGetters:this.$rootGetters})}download(){return this.configurableTables?this.openExportModal([this]):this.downloadYaml()}downloadBulk(e){return this.configurableTables?this.openExportModal(e):this.downloadYamlBulk(e)}async openExportModal(e){const{default:t}=await Promise.resolve().then(n.bind(n,38283));this.$ctx.commit("modal/openModal",{component:(0,Y.markRaw)(t),componentProps:{count:e.length,isSelection:!0},resources:e,closeOnClickOutside:!0,modalWidth:"640px"},{root:!0})}async downloadYaml(){const e=await this.followLink("view",{headers:{accept:"application/yaml"}}),t=await this.cleanForDownload(e.data);(0,L.PE)(`${this.nameDisplay}.yaml`,t,"application/yaml")}async downloadYamlBulk(e,t){const n={},r=[];let i=0;for(const a of e){let e=`${a.nameDisplay}.yaml`,t=2;while(r.includes(e))e=`${a.nameDisplay}_${t++}.yaml`;r.push(e)}await(0,B.hF)(e,10,(o,a)=>o.followLink("view",{headers:{accept:"application/yaml"}}).then(async o=>{const s=o.data||o,l=await this.cleanForDownload(s);n[`resources/${r[a]}`]=l,t?.(++i,e.length)}));const o=await(0,L.jl)(n);(0,L.PE)("resources.zip",o,"application/zip")}viewInApi(){window.open(this.links.self,"_blank")}promptRemove(e){e||(e=this),this.$dispatch("promptRemove",e)}get confirmRemove(){return!1}applyDefaults(){}get urlFromAttrs(){const e=this.$getters["schemaFor"](this.type),{metadata:{namespace:t="default"}}=this;let n=e.links.collection;const r=e?.attributes;if(!r)throw new Error("Attributes must be present on the schema");const{group:i,resource:o}=r;return n=`${n.slice(0,n.indexOf("/v1"))}/apis/${i}/namespaces/${t}/${o}`,n}cleanYaml(e,t="edit"){try{const n=H().load(e);"edit"!==t&&this.$dispatch("cleanForNew",n),n._type&&(n.type=n._type,delete n._type);const r=H().dump(n,{skipInvalid:!0});return r}catch(n){return null}}cleanForNew(){this.$dispatch("cleanForNew",this)}cleanForDiff(){this.$dispatch("cleanForDiff",this.toJSON())}async cleanForDownload(e,t={}){return this.$dispatch("cleanForDownload",{yaml:e,opt:t})}yamlForSave(e){try{const t=H().load(e);if(t)return this._type&&(t._type=t.type),H().dump(t)}catch(t){return null}}async saveYaml(e,t){await this._saveYaml(e,t)}async _saveYaml(e,t,n=0){const r=H().load(e);if(this.schema?.attributes?.namespaced&&!r.metadata.namespace){const e=this.$rootGetters["i18n/t"]("resourceYaml.errors.namespaceRequired");throw e}let i;const o=!this.id;!o&&r?.metadata&&!r.metadata.resourceVersion&&this.metadata?.resourceVersion&&(r.metadata.resourceVersion=this.metadata.resourceVersion,e=H().dump(r));const a={"content-type":"application/yaml",accept:"application/json"};if(o)i=await this.schema.followLink("collection",{method:"POST",headers:a,data:e});else try{i=await this.followLink("update",{method:"PUT",headers:a,data:e})}catch(s){const r=409===s.status||409===s._status;if(!r||0!==n||!t)throw s;{const r=this.$rootGetters["currentStore"](this.type),i=H().load(t),o=H().load(e),a=this.$rootGetters[`${r}/byId`](this.type,this.id),s=await(0,Z.Rq)(i,o,a,{dispatch:this.$dispatch,getters:this.$rootGetters},this.$rootGetters["currentStore"](this.type),e=>e.toJSON?e.toJSON():e);if(!1!==s)throw s;await this._saveYaml(H().dump(o),null,n+1)}}i&&(await this.$dispatch("load",{data:i,existing:o?this:void 0}),this.isSpoofed&&await this.$dispatch("cluster/findAll",{type:this.type,opt:{force:!0}},{root:!0}))}get modelValidationRules(){const e=[],t=this?.customValidationRules.filter(e=>!!e.validators||!!e.required).map(e=>{const t=(0,j.A)(this.t,{key:e?.translationKey?this.t(e.translationKey):"Value"});return{path:e.path,rules:[...e.validators||[],...e.required?["required"]:[],...["dnsLabel","dnsLabelRestricted","hostname"].includes(e.type)?[e.type]:[]].map(e=>{if(e.includes(":")){const[n,r]=e.split(":");return t[n](r)}return t[e]}).filter(e=>!!e)}}).filter(e=>e.rules.length>0);return e.push(...t),e}customValidationErrors(e,t=[]){const n=[];let{customValidationRules:r}=this;return p()(r)||(K()(r)&&(r=r()),r.filter(e=>!t.includes(e.path)).forEach(t=>{const{path:r,requiredIf:i,validators:o=[],type:a}=t;let s=(0,k.Jt)(e,r);const l=Q()(o||[]);let c=r;if(t.translationKey&&this.$rootGetters["i18n/exists"](t.translationKey)&&(c=this.t(t.translationKey)),X()(s)&&(s=s.trim()),i){const t=(0,k.Jt)(e,i);!p()(t)&&p()(s)&&0!==s&&n.push(this.t("validation.required",{key:c}))}if((0,g.xR)(s,t,c,this.$rootGetters,n),(0,g.iK)(s,t,c,this.$rootGetters,n),!p()(s)&&oe.includes(a)){const t=(s||"").toLowerCase();t!==s&&(s=t,e[r]=s),n.push(...(0,g.OH)(s,a,c,this.$rootGetters,n))}l.forEach(t=>{const r=t.split(":"),i=r.slice(0,1),o=r.slice(1)||null,a=Object.prototype.hasOwnProperty.call(D,i);if(!p()(i)&&a)D[i](s,this.$rootGetters,n,o,c,e);else if(!p()(i)&&!a){const t=this.$rootState.$extension?.getValidator(i);t?t(s,this.$rootGetters,n,o,c,e):ie.warn(this.t("validation.custom.missing",{validatorName:i}))}})})),n}validationErrors(e=this,t={}){return this.customValidationErrors(e)}get ownersByType(){const e=this.metadata?.ownerReferences||[],t={};return e.forEach(e=>{t[e.kind]?t[e.kind].push(e):t[e.kind]=[e]}),t}get owners(){const e=[];for(const t in this.ownersByType){const n=this.$rootGetters["cluster/schema"](t);if(n){const r=n.id,i=this.$rootGetters["cluster/all"](r);this.ownersByType[t].forEach((t,n)=>{const r=i.find(e=>e?.metadata?.uid===t.uid);r&&e.push(r)})}}return e}get details(){return this._details}get _details(){const e=[];return this.owners?.length>0&&e.push({label:this.t("resourceDetail.detailTop.ownerReferences",{count:this.owners.length}),formatter:"ListLinkDetail",content:this.owners.map(e=>({key:e.id,row:e,col:{},value:e.metadata.name}))}),(0,k.Jt)(this,"metadata.deletionTimestamp")&&e.push({label:this.t("resourceDetail.detailTop.deleted"),formatter:"LiveDate",formatterOpts:{addSuffix:!0},content:(0,k.Jt)(this,"metadata.deletionTimestamp")}),e}get glance(){return this._glance}get _glance(){const e=this.parentNameOverride||this.$rootGetters["type-map/labelFor"](this.schema);return[{name:"state",label:this.t("component.resource.detail.glance.state"),formatter:"BadgeStateFormatter",formatterOpts:{row:{stateDisplay:this.stateDisplay,stateBackground:this.glanceStateBackground}},content:this.stateDisplay},{name:"type",label:this.t("component.resource.detail.glance.type"),formatter:"Link",formatterOpts:{to:this.listLocation,row:{},options:{internal:!0}},content:e},...this.metadata?.namespace?[{name:"namespace",label:this.t("component.resource.detail.glance.namespace"),formatter:this.glanceNamespaceLocation?"Link":void 0,formatterOpts:{to:this.glanceNamespaceLocation,row:{},options:{internal:!0}},content:this.metadata.namespace}]:[],{name:"age",label:this.t("component.resource.detail.glance.age"),formatter:"LiveDate",content:this.creationTimestamp}]}get glanceStateBackground(){return this.stateObj?.transitioning&&"text-error"===me.call(this,this.state)?"bg-error":this.stateBackground}get glanceNamespaceLocation(){const e=this.metadata?.namespace,t=this.$rootGetters["currentStore"]?.(c.CU);return e&&t&&this.$rootGetters[`${t}/canList`]?.(c.CU)?null===this.namespaceLocation||this.$rootGetters["currentProduct"]?.hideNamespaceLocation?null:this.namespaceLocation||{name:"c-cluster-product-resource-id",params:{cluster:this.$rootGetters["clusterId"],product:this.$rootGetters["productId"],resource:c.CU,id:e}}:null}get t(){return this.$rootGetters["i18n/t"]}findOwners(){return this._getRelationship("owner","from")}getOwners(){return this._getRelationship("owner","from")}findOwned(){return this._findRelationship("owner","to")}_relationshipsFor(e,t){const n={selectors:[],ids:[]};if(!this.metadata?.relationships?.length)return n;for(const r of this.metadata.relationships)if(("any"===e||r.rel===e)&&r[`${t}Type`])if(r.selector)(0,d.PG)(n.selectors,{type:r.toType,namespace:r.toNamespace,selector:r.selector});else{const e=r[`${t}Type`];let i=r[`${t}Namespace`],o=r[`${t}Id`];if(!i&&o?.includes("/")){const e=o.indexOf("/");i=o.substr(0,e),o=o.substr(e+1)}const a=(i?`${i}/`:"")+o;(0,d.PG)(n.ids,{type:e,namespace:i,name:o,id:a})}return n}_getRelationship(e,t){const n=this._relationshipsFor(e,t);return n.selectors?.length&&ie.warn("Sync request for a relationship that is a selector"),n.ids||[]}async _findRelationship(e,t){const{selectors:n,ids:r}=this._relationshipsFor(e,t),i=[];for(const o of n){const{type:e,selector:t,namespace:n,opt:r}=o,a=await this.$dispatch("findLabelSelector",{type:e,matching:{namespace:n,labelSelector:{matchExpressions:(0,te.qg)(t)}},opts:{transient:!0,...r}});(0,d.cn)(i,a.data)}for(const o of r){const{type:e,id:t}=o;let n=this.$getters["byId"](e,t);if(!n)try{n=await this.$dispatch("find",{type:e,id:t})}catch{}n&&(0,d.PG)(i,n)}return i}get shortId(){const e=this.id.split("/");return e.length>1?e[1]:e[0]}toJSON(){const e={},t=Object.keys(this);for(const n of t)this[n]?.toJSON?e[n]=this[n].toJSON():e[n]=(0,k.o8)(this[n]);return e}toSave(){}get creationTimestamp(){return this.metadata?.creationTimestamp}get yamlFolding(){return[]}get resourceConditions(){return(this.status?.conditions||[]).map(e=>{let t=e.message||"";return e.reason&&(t=`[${e.reason}] ${t}`.trim()),{condition:e.type||"Unknown",status:e.status||"Unknown",stateSimpleColor:e.error?"error":"disabled",error:e.error,time:e.lastProbeTime||e.lastUpdateTime||e.lastTransitionTime,message:t}})}get resourceEvents(){return this.$rootGetters["cluster/all"](c.ll).filter(e=>e.involvedObject?.uid===this.metadata?.uid)}get insightCardProps(){const e=[(0,ne.G)(this.t("component.resource.detail.card.insightsCard.rows.conditions"),this.resourceConditions,void 0,"condition","#conditions"),(0,ne.G)(this.t("component.resource.detail.card.insightsCard.rows.events"),this.resourceEvents,"insightsColor","eventType","#events")];return{title:this.t("component.resource.detail.card.insightsCard.title"),rows:e}}get insightCard(){return{component:(0,Y.markRaw)((0,Y.defineAsyncComponent)(()=>n.e(67).then(n.bind(n,20067)))),props:this.insightCardProps}}get _resourcesCardRows(){const e=[],t=this.metadata?.relationships||[],n=t.filter(e=>e.fromType&&e.fromId&&!e.selector),r=t.filter(e=>e.toType&&e.toId&&!e.selector&&!e.fromType);return n.length&&e.push((0,ne.t)(this.t("component.resource.detail.card.resourcesCard.rows.referredToBy"),n,{hash:"#related"})),r.length&&e.push((0,ne.t)(this.t("component.resource.detail.card.resourcesCard.rows.refersTo"),r,{hash:"#related"})),e}get resourcesCardRows(){return this._resourcesCardRows}get resourcesCard(){const e=this.resourcesCardRows;return e.length?{component:(0,Y.markRaw)((0,Y.defineAsyncComponent)(()=>n.e(67).then(n.bind(n,20067)))),props:{title:this.t("component.resource.detail.card.resourcesCard.title"),rows:e}}:null}get _cards(){return[]}get cards(){return[this.resourcesCard,...this._cards].filter(e=>e)}}},82614:function(e,t,n){"use strict";n.d(t,{A:function(){return d},T:function(){return u}});var r=n(2841),i=n(38403),o=n.n(i),a=n(16735),s=n.n(a),l=n(92043),c=n(73883);function u(e){const t=["state","name","description","labels","annotations"];return t.forEach(t=>delete e[t]),e}class d extends c.Ay{constructor(e,t,n=null,r=!1){const i=u(e);super(i,t,n,r)}get labels(){const e=this.metadata?.labels||{};return o()(e,(e,t)=>(0,l.HV)(t,r.lq))}setLabels(e){this.metadata||(this.metadata={});const t=this.metadata.labels||{},n=s()(t,(e,t)=>(0,l.HV)(t,r.lq));this.metadata["labels"]={...n,...e}}setLabel(e,t){t?(this.metadata||(this.metadata={}),this.metadata.labels||(this.metadata.labels={}),this.metadata.labels[e]=t):this.metadata?.labels&&(this.metadata.labels[e]=void 0,delete this.metadata.labels[e])}get annotations(){const e=this.metadata?.annotations||{};return o()(e,(e,t)=>this.isAnnotationIgnored(t))}isAnnotationIgnored(e){return(0,l.HV)(e,r.S5)}setAnnotations(e){this.metadata||(this.metadata={});const t=this.metadata.annotations||{},n=s()(t,(e,t)=>this.isAnnotationIgnored(t));this.metadata["annotations"]={...n,...e}}setAnnotation(e,t){t?(this.metadata||(this.metadata={}),this.metadata.annotations||(this.metadata.annotations={}),this.metadata.annotations[e]=t):this.metadata?.annotations&&(this.metadata.annotations[e]=void 0,delete this.metadata.annotations[e])}get state(){return this.stateObj?.name||"unknown"}}},89865:function(e,t,n){"use strict";n.d(t,{A:function(){return w}});var r=n(2841),i=n(16735),o=n.n(i),a=n(68851),s=n(92043),l=n(73883),c=n(76978),u=n(96047),d=n(79401),h=n(8138),p=n.n(h),f=n(82438),m=n.n(f),g=n(3514),v=n.n(g),b=n(4364);const y=["string","date","blob","enum","multiline","masked","password","dnsLabel","hostname"];class w extends l.Ay{setLabels(e){const t=this.labels||{},n=o()(t,(e,t)=>(0,s.HV)(t,r.lq));this["labels"]={...n,...e}}setLabel(e,t){t?(this.labels||(this.labels={}),this.labels[e]=t):this.labels&&(this.labels[e]=void 0,delete this.labels[e])}setAnnotations(e){const t=this.annotations||{},n=o()(t,(e,t)=>(0,s.HV)(t,r.S5));this["annotations"]={...n,...e}}setAnnotation(e,t){t?(this.annotations||(this.annotations={}),this.annotations[e]=t):this.annotations&&(this.annotations[e]=void 0,delete this.annotations[e])}setResourceQuotas(e){const t=["resourceQuota","namespaceDefaultResourceQuota"];t.forEach(t=>{this[t]={...e[t]}})}isCondition(e,t="True"){if(!this.conditions)return!1;const n=(0,a.jq)(this.conditions||[],"type",e);return!!n&&(!t||(n.status||"").toLowerCase()===`${t}`.toLowerCase())}validationErrors(e=this,t={ignoreFields:void 0}){const n=[],{type:r,schema:i}=e,o=(0,d.AZ)(r);if(!r)return b.warn(this.t("validation.noType"),e),n;if(!i)return n;const a=i.resourceFields||{},h=Object.keys(a);let f,g,w,O;for(let m=0;m<h.length;m++){const r=[];g=h[m],f=a[g],w=(0,c.Jt)(e,g),O=(0,u.HK)(o,g,this.$rootGetters);const i=f?.type?(0,d.AZ)(f.type):null,b=p()(w);if(!t.ignoreFields||!t.ignoreFields.includes(g))if(void 0===w&&(w=null),b&&(i&&(e[g]=(0,s.i6)(w,i)),f.nullable&&0===w.length&&y.includes(i)&&(w=null,e[g]=w)),"boolean"===i?(0,u.p6)(w,f,O,this.$rootGetters,r):((0,u.xR)(w,f,O,this.$rootGetters,r),(0,u.iK)(w,f,O,this.$rootGetters,r)),r.length>0)r.push(this.t("validation.required",{key:O})),n.push(...r);else{if("id"!==g&&!v()(w)&&l.qE.includes(i)){const t=(w||"").toLowerCase();t!==w&&(w=t,e[g]=w),r.push(...(0,u.OH)(w,i,O,this.$rootGetters,r))}n.push(...r)}}const S=super.validationErrors(this,t);return m()([...n,...S])}}},37417:function(e,t,n){"use strict";n.d(t,{P:function(){return o},w:function(){return i}});var r=n(79401);function i(e){e._id=(0,r.AZ)(e.id),e._group=(0,r.AZ)(e.attributes?.group)}function o(e){delete e._id,delete e._group}},39975:function(e,t,n){"use strict";n.d(t,{A:function(){return y}});var r=n(2841),i=n(82614),o=n(37648),a=n(76978),s=n(89778),l=n(4364);const c={STRATEGIC_MERGE:"application/strategic-merge-patch+json",MERGE:"application/merge-patch+json"},u=415,d=/unsupported media type|unknown format|accepted media types/i;let h={};const p=(e,t)=>`${e}::${t}`;function f(e,t){return!!h[p(e,t)]}function m(e){const t=e?._status??e?.status??e?.response?.status;return t===u||d.test(`${e?.message??""}`)}async function g({storeName:e,resourceType:t,send:n,onFallback:r=(e,t)=>l.warn(e,t)}){if(f(e,t))return n(c.MERGE);try{return await n(c.STRATEGIC_MERGE)}catch(i){if(!m(i))throw i;h[p(e,t)]=!0,r(`"${t}" does not accept "${c.STRATEGIC_MERGE}", retrying with "${c.MERGE}". List fields will be replaced rather than merged by key.`,i)}return n(c.MERGE)}const v=["metadata.resourceVersion","metadata.fields","metadata.clusterName","metadata.deletionGracePeriodSeconds","metadata.generateName","metadata.ownerReferences"],b=o.Ng.filter(e=>!v.includes(e));class y extends i.A{get name(){return this.metadata?.name||this._name}get namespace(){return this.metadata?.namespace}get description(){return this.metadata?.annotations?.[r.tC]||this.spec?.description||this._description}set description(e){this.metadata?.annotations&&(this.metadata.annotations[r.tC]=e),this.spec&&(this.spec.description=e),this._description=e}get modelExtensions(){return this.$extension.getDynamic(s.j.MODEL_EXTENSION,this.type)||[]}cleanForSave(e,t){const n=super.cleanForSave(e);for(const r of b)(0,a.BJ)(n,r);return n}paginationEnabled(){return this.$getters["paginationEnabled"](this.type)}notifyGeneratedName(){if(this.metadata?.generateName&&this.id){const e=this.id.split("/").pop();if(e.length>0){const t=this.typeDisplay;this.$dispatch("growl/success",{title:this.t("generic.autogeneratedCreated.title",{resource:t}),message:this.t("generic.autogeneratedCreated.message",{id:e,resource:t}),timeout:3e3},{root:!0})}}}async update(e){if(!this.canEdit)throw new Error(`ResourceInstance API error - ${this.type}/${this.id} - Cannot patch: permission denied`);return await g({storeName:this.$getters["storeName"],resourceType:this.type,send:t=>this.save({data:e,method:"patch",headers:{"content-type":t}})}),this}async replace(){if(!this.canEdit)throw new Error(`ResourceInstance API error - ${this.type}/${this.id} - Cannot update: permission denied`);return await this.save(),this}async delete(){if(!this.canDelete)throw new Error(`ResourceInstance API error - ${this.type}/${this.id} - Cannot delete: permission denied`);await this.remove()}}},63928:function(e,t,n){"use strict";n.d(t,{A:function(){return i}});var r=n(39975);class i extends r.A{constructor(e,t,n=null,r=!1){const i=e.description;super(e,t,n,r),this.description=i}get description(){return this._description}set description(e){this._description=e}toJSON(){const e=super.toJSON();return e.description=this.description,delete e._description,e}toSave(){return this.toJSON()}}},55105:function(e,t,n){"use strict";n.r(t);var r=n(65359),i=n(92043),o=n(35664),a=n(4799);const s=a.SUBTYPE_MAPPING.CLUSTER.key;t["default"]={data(){return{warning:"",info:""}},computed:{...(0,r.aH)("action-menu",["toRemove"]),...(0,r.L8)({t:"i18n/t"}),names(){return this.toRemove.map(e=>e.nameDisplay)}},watch:{value:{handler(e){this.handleRoleDeletionCheck(e,e[0].type,this.$route.hash)},immediate:!0}},methods:{resourceNames:i.Nr,async handleRoleDeletionCheck(e,t,n){let r,i;this.warning="";let a=0;const l=new Set;switch(this.info=this.t("rbac.globalRoles.waiting",{count:e.length}),t){case o.Mc.GLOBAL_ROLE:r=o.Mc.GLOBAL_ROLE_BINDING,i="globalRoleName";break;default:r=n.includes(s)?o.Mc.CLUSTER_ROLE_TEMPLATE_BINDING:o.Mc.PROJECT_ROLE_TEMPLATE_BINDING,i="roleTemplateName";break}try{const t=await this.$store.dispatch("management/request",{url:`/v1/${r}`,method:"get"},{root:!0}),n=await this.$store.dispatch("management/request",{url:`/v1/${o.Mc.USER}`,method:"get"},{root:!0}),s=n.data?.reduce((e,t)=>(t.username&&(e[t.id]=t),e),{});t.data&&t.data.length?(e.forEach(e=>{const n=t.data.filter(t=>t[i]===e.id);if(n.length){const e=[...new Set(n.map(e=>e.userName).filter(e=>s[e]))];e.length&&(a++,e.forEach(e=>l.add(e)))}}),a&&l.size?(this.info="",this.warning=this.t("rbac.globalRoles.usersBound",{count:l.size})):this.info=this.t("rbac.globalRoles.notBound",null,!0)):this.info=this.t("rbac.globalRoles.notBound",null,!0)}catch(c){this.info=this.t("rbac.globalRoles.unableToCheck")}}}}},95265:function(e,t,n){"use strict";n.d(t,{E8:function(){return u},Et:function(){return h},Kg:function(){return p},N8:function(){return c},Wt:function(){return s},lc:function(){return l},nR:function(){return d},r$:function(){return a}});n(35664);var r=n(11518);const i={},o=function(e,t){return i[e]={def:t},e},a=function(e){return{get(){return this.$store.getters["features/get"](e)},set(e){throw new Error("The feature store only supports getting")}}},s=(o("multi-cluster-management",!0),o("rke2",!0),o("unsupported-storage-drivers",!1)),l=(o("continuous-delivery",!0),o("harvester",!0),o("harvester-baremetal-container-workload",!1)),c=o("provisioningv2-fleet-workspace-back-population",!1),u=(o("ui-sql-cache",!0),o("uiextension",!0),o("provisioningprebootstrap",!1),o(r.R8,!1),o("rancher-scc-registration-extension",!0),o("cluster-autoscaling",!1)),d=(o("cluster-shell",!0),o("node-shell",!0),o("pod-shell",!0)),h=o("hide-local-auth-provider",!1),p=(o("multiple-auth-providers",!1),o("ui-configurable-tables",!0))},10213:function(e,t,n){"use strict";n.d(t,{e:function(){return r},w:function(){return i}});const r={CLUSTER:"cluster",RANCHER:"rancher",MANAGEMENT:"management"},i="_"},86565:function(e,t,n){"use strict";n.d(t,{f7:function(){return a},lm:function(){return o},QF:function(){return i},X2:function(){return s}});n(68774);var r=n(35664);n(41476),n(68851),n(76978),n(92043),n(27436),n(27278),n(41580),n(79401),n(74302),n(83416);n(46392),n(9274),n(37327);const i="__[[spoofed]]__",o="__[[spoofedapi]]__",a={V2_MONITORING:"v2-monitoring",PROJECT:"project",NO_PROJECT:"no-project",NOT_V1_ISTIO:"not-v1-istio",MULTI_CLUSTER:"multi-cluster",NEUVECTOR_NAMESPACE:"neuvector-namespace",ADMIN:"admin-user",MCM_DISABLED:"mcm-disabled",NOT_STANDALONE_HARVESTER:"not-standalone-harvester",CLUSTER_OR_PROJECT_MEMBERS:"cluster-or-project-members"};function s(e){const t=(e["management/schemaFor"](r.Mc.SETTING)?.resourceMethods||[]).includes("PUT"),n=(e["management/schemaFor"](r.Mc.FEATURE)?.resourceMethods||[]).includes("PUT"),i=(e["management/schemaFor"](r.W8.APP)?.resourceMethods||[]).includes("PUT"),o=(e["management/schemaFor"](r.W8.CLUSTER_REPO)?.resourceMethods||[]).includes("PUT"),a=(e["management/schemaFor"](r.W8.OPERATION)?.resourceMethods||[]).includes("PUT");return t&&n&&i&&o&&a}},39589:function(e,t,n){"use strict";n.d(t,{BA:function(){return E},ER:function(){return d},Eb:function(){return O},_R:function(){return y},gb:function(){return S}});var r=n(20246),i=n.n(r),o=n(4514),a=n(35664),s=n(76978),l=n(3514),c=n.n(l),u=n(55162);const d=async e=>{const t=e.getters["cluster/schemaFor"](a.Rp.ALERTMANAGERCONFIG);if(t)return await t.fetchResourceFields(),{receiverSchema:t.schemaDefinitions?.[`${t.schemaDefinition.type}.spec.receivers`],routeSchema:t.schemaDefinitions?.[`${t.schemaDefinition.type}.spec.route`]}},h="cattle-monitoring-system/alertmanager-rancher-monitoring-alertmanager",p="cattle-monitoring-system/rancher-monitoring-alertmanager",f="alertmanager.yaml";async function m(e){const t=await e("cluster/find",{type:a.Rp.ALERTMANAGER,id:p},{root:!0});return t?.spec?.configSecret?`${t.namespace}/${t?.spec?.configSecret}`:h}async function g(e){const t=await m(e,!1);try{return await e("cluster/find",{type:a.bB,id:t},{root:!0})}catch(n){const[r,i]=t.split("/"),o=await e("cluster/create",{type:a.bB},{root:!0});return o.metadata={namespace:r,name:i},o}}function v(e){e.data=e.data||{};const t=e.data[f],n=t?(0,o.u)(t):"{}",r=i().load(n);return r.receivers=r.receivers||[],r.route=r.route||{},r.route.routes=r.route.routes||[],r}async function b(e){const t=await g(e);return{config:v(t),secret:t}}async function y(e,t,n,r){const{config:a,secret:l}=await b(e);(0,s.hZ)(a,t,(0,s.Jt)(a,t)||[]),w(a.route.routes);const c=r((0,s.Jt)(a,t));(0,s.hZ)(a,t,c);const d=a.route.routes,h=d.findIndex(e=>e.name===u.ROOT_NAME);if(d.forEach(e=>{e.name&&delete e.name}),h>=0){const e=d.splice(h,1)[0];e.routes=d,a.route=e}const p=i().dump(a),m=(0,o.KA)(p);l.data[f]=m,await l.save()}function w(e){e.forEach((e,t)=>{e.name=e.name||O(t)})}function O(e){return`route-${e}`}function S(e){try{const t=v(e),n=t.route?.routes||[];return!n.some(c())}catch(t){return!1}}function E(e){return e["type-map/optionsFor"](a.bB).isCreatable}},60754:function(e,t,n){"use strict";n.d(t,{Se:function(){return h},iV:function(){return d}});n(50667),n(14220);var r=n(35664);n(88339),n(68851),n(2722),n(92043),n(2841),n(91251),n(4364);const i=[1e3,2e3,4e3,8e3];i.length;var o=n(95265);n(4364);const a="local";function s(e=[],t,n){return!!n&&!e.some(e=>e.enabled&&e.id!==a&&e.id!==t)}function l(e){return e["management/byId"](r.Mc.FEATURE,o.Et)}function c(e){const t=e["management/schemaFor"](r.Mc.FEATURE),n=(t?.resourceMethods||[]).includes("PUT"),i=l(e);return n&&!!i&&null===i.status?.lockedValue}async function u(e){const t=l(e);if(t){t.spec.value=!1;try{await t.save()}catch(n){throw t.spec.value=!0,n}}}async function d({dispatch:e,getters:t,id:n,name:i,disableCb:a}){let l=[],d=!1;try{l=await e("management/findAll",{type:r.Mc.AUTH_CONFIG})||[]}catch(p){d=!0}const h=t["features/get"](o.Et);return h&&(d||s(l,n,h))?e("management/promptModal",{component:"DisableLastAuthProviderDialog",modalWidth:"640px",height:"auto",styles:"max-height: 100vh;",componentProps:{name:i,canRestore:c(t),restoreCb:()=>u(t)}}):e("management/promptModal",{component:"DisableAuthProviderDialog",ownsModal:!0,componentProps:{name:i,disableCb:a}})}const h=(e,t)=>{const n=e.getters["currentStore"](t),r=e.getters[`${n}/schemaFor`];if(!n||!r)return!1;const i=r(t)||e.getters["type-map/isVirtual"](t);return!!i}},11524:function(e,t,n){"use strict";n.d(t,{Gl:function(){return i}});n(2722),n(83288);var r=n(7325);n(14220);function i(e,t,n){if(!e?.versions?.length)return{};const i=(0,r.bh)(e,t,n);return(i.length?i[0]:e.versions[0])||{}}},48881:function(e,t,n){"use strict";n.d(t,{e:function(){return U},N:function(){return G}});var r=n(4364),i="text/plain",o=e=>{};function a(e){o(e)}function s(){(r.warn||r.log).apply(r,arguments)}s.bind("[clipboard-polyfill]");var l,c,u,d="undefined"===typeof window?void 0:window,h="undefined"===typeof globalThis?void 0:globalThis,p=null!=(u=null==(l=d)?void 0:l.Promise)?u:null==(c=h)?void 0:c.Promise;function f(){if(!p)throw new Error("No `Promise` implementation available for `clipboard-polyfill`. Consider using: https://github.com/lgarron/clipboard-polyfill#flat-file-version-with-promise-included");return p}var m,g,v,b,y,w="undefined"===typeof navigator?void 0:navigator,O=null==w?void 0:w.clipboard,S=(null==(m=null==O?void 0:O.read)||m.bind(O),null==(g=null==O?void 0:O.readText)?void 0:g.bind(O)),E=(null==(v=null==O?void 0:O.write)||v.bind(O),null==(b=null==O?void 0:O.writeText)?void 0:b.bind(O)),x=(null==(y=d)||y.ClipboardItem,f()),_=d;function k(){return"undefined"===typeof ClipboardEvent&&"undefined"!==typeof(null==_?void 0:_.clipboardData)&&"undefined"!==typeof(null==_?void 0:_.clipboardData.setData)}function C(e){if(!_.clipboardData)return!1;var t=_.clipboardData.setData("Text",e);return t&&a("writeTextIE worked"),t}function A(){if(!_.clipboardData)throw new Error("Cannot read IE clipboard Data ");var e=_.clipboardData.getData("Text");if(""===e)throw new Error("Empty clipboard or could not read plain text from clipboard");return e}function T(e,t,n){for(var r in a("listener called"),e.success=!0,t){var o=t[r],s=n.clipboardData;s.setData(r,o),r===i&&s.getData(r)!==o&&(a("setting text/plain failed"),e.success=!1)}n.preventDefault()}function R(e){var t={success:!1},n=T.bind(this,t,e);document.addEventListener("copy",n);try{document.execCommand("copy")}finally{document.removeEventListener("copy",n)}return t.success}function N(e,t){M(e);var n=R(t);return D(),n}function P(e){var t=document.createElement("div");t.setAttribute("style","-webkit-user-select: text !important"),t.textContent="temporary element",document.body.appendChild(t);var n=N(t,e);return document.body.removeChild(t),n}function I(e){a("copyTextUsingDOM");var t=document.createElement("div");t.setAttribute("style","-webkit-user-select: text !important");var n=t;t.attachShadow&&(a("Using shadow DOM."),n=t.attachShadow({mode:"open"}));var r=document.createElement("span");r.innerText=e,n.appendChild(r),document.body.appendChild(t),M(r);var i=document.execCommand("copy");return D(),document.body.removeChild(t),i}function M(e){var t=document.getSelection();if(t){var n=document.createRange();n.selectNodeContents(e),t.removeAllRanges(),t.addRange(n)}}function D(){var e=document.getSelection();e&&e.removeAllRanges()}function L(e){var t=i in e;if(k()){if(!t)throw new Error("No `text/plain` value was specified.");if(C(e[i]))return!0;throw new Error("Copying failed, possibly because the user rejected it.")}return R(e)?(a("regular execCopy worked"),!0):navigator.userAgent.indexOf("Edge")>-1?(a('UA "Edge" => assuming success'),!0):N(document.body,e)?(a("copyUsingTempSelection worked"),!0):P(e)?(a("copyUsingTempElem worked"),!0):!!I(e[i])&&(a("copyTextUsingDOM worked"),!0)}x.resolve(),x.resolve(!1);function B(e){return new x((t,n)=>{try{t(e())}catch(r){n(r)}})}function $(e){var t={};return t[i]=e,t}function V(e){return B(()=>E?(a("Using `navigator.clipboard.writeText()`."),E(e).catch(F)):x.resolve(F(e)))}function F(e){if(!L($(e)))throw new Error("writeText() failed")}function j(){return B(()=>{if(S)return a("Using `navigator.clipboard.readText()`."),S();if(k()){var e=A();return x.resolve(e)}throw new Error("Read is not supported in your browser.")})}async function U(e){await V(e)}async function G(){return await j()}},85042:function(e,t,n){"use strict";n.d(t,{F0:function(){return f},WJ:function(){return p},gF:function(){return c},uY:function(){return m},xl:function(){return u}});n(2722),n(92043);var r=n(2841),i=n(35664),o=n(9262),a=n(50025),s=(n(83288),n(74302),n(95265));n(14220),n(3514),n(76978),n(4364);function l(e){const t=e.getters["management/byId"](i.Mc.SETTING,o.HG.HIDE_LOCAL_CLUSTER)||{};return"true"===(t.value||t.default||"false")}function c(e,t=!0){const n=[],r=h(e),i=d(e,t);return r&&n.push(...r),i&&n.push(i),n}function u(e,t=!0){return JSON.stringify(c(e,t))}function d(e,t=!0){if(!l(e))return null;const n=t?[new a.Js({field:"spec.internal",value:!1})]:[new a.Js({field:"id",value:"fleet-local/local",exact:!0,equals:!1})];return a.eY.createMultipleFields(n)}function h(e){const t=e.getters["features/get"](s.lc);return t?null:[a.eY.createSingleField(new a.Js({field:`metadata.labels[${r.qt.PROVIDER}]`,equals:!1,value:i.BN,exact:!0})),a.eY.createSingleField(new a.Js({field:"status.provider",equals:!1,value:i.BN,exact:!0}))]}function p(e,t){const n=t.getters["features/get"](s.lc);return n?e:e?.filter(e=>!f(e))}function f(e){const t=e?.metadata?.labels?.[r.qt.PROVIDER]||e?.status?.provider;return t===i.BN}function m(e,t){return l(t)?e.filter(e=>{const t=e.mgmt||e;return!t.isLocal}):e}},39705:function(e,t,n){"use strict";n.d(t,{qe:function(){return Q},yq:function(){return H},Tv:function(){return z},H0:function(){return j},hk:function(){return U}});const r={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]};for(const K in r)Object.freeze(r[K]);var i=Object.freeze(r);const o=Object.create(null);for(const K in i)Object.hasOwn(i,K)&&(o[i[K]]=K);const a={to:{},get:{}};function s(e,t,n){return Math.min(Math.max(t,e),n)}function l(e){const t=Math.round(e).toString(16).toUpperCase();return t.length<2?"0"+t:t}a.get=function(e){const t=e.slice(0,3).toLowerCase();let n,r;switch(t){case"hsl":n=a.get.hsl(e),r="hsl";break;case"hwb":n=a.get.hwb(e),r="hwb";break;default:n=a.get.rgb(e),r="rgb";break}return n?{model:r,value:n}:null},a.get.rgb=function(e){if(!e)return null;const t=/^#([a-f\d]{3,4})$/i,n=/^#([a-f\d]{6})([a-f\d]{2})?$/i,r=/^rgba?\(\s*([+-]?(?:\d*\.)?\d+(?:e\d+)?)(?=[\s,])\s*(?:,\s*)?([+-]?(?:\d*\.)?\d+(?:e\d+)?)(?=[\s,])\s*(?:,\s*)?([+-]?(?:\d*\.)?\d+(?:e\d+)?)\s*(?:[\s,|/]\s*([+-]?(?:\d*\.)?\d+(?:e\d+)?)(%?)\s*)?\)$/i,o=/^rgba?\(\s*([+-]?[\d.]+)%\s*,?\s*([+-]?[\d.]+)%\s*,?\s*([+-]?[\d.]+)%\s*(?:[\s,|/]\s*([+-]?[\d.]+)(%?)\s*)?\)$/i,a=/^(\w+)$/;let l,c,u,d=[0,0,0,1];if(l=e.match(n)){for(u=l[2],l=l[1],c=0;c<3;c++){const e=2*c;d[c]=Number.parseInt(l.slice(e,e+2),16)}u&&(d[3]=Number.parseInt(u,16)/255)}else if(l=e.match(t)){for(l=l[1],u=l[3],c=0;c<3;c++)d[c]=Number.parseInt(l[c]+l[c],16);u&&(d[3]=Number.parseInt(u+u,16)/255)}else if(l=e.match(r)){for(c=0;c<3;c++)d[c]=Number.parseFloat(l[c+1]);l[4]&&(d[3]=l[5]?.01*Number.parseFloat(l[4]):Number.parseFloat(l[4]))}else{if(!(l=e.match(o)))return(l=e.toLowerCase().match(a))?"transparent"===l[1]?[0,0,0,0]:Object.hasOwn(i,l[1])?(d=i[l[1]].slice(),d[3]=1,d):null:null;for(c=0;c<3;c++)d[c]=Math.round(2.55*Number.parseFloat(l[c+1]));l[4]&&(d[3]=l[5]?.01*Number.parseFloat(l[4]):Number.parseFloat(l[4]))}for(c=0;c<3;c++)d[c]=s(d[c],0,255);return d[3]=s(d[3],0,1),d},a.get.hsl=function(e){if(!e)return null;const t=/^hsla?\(\s*([+-]?(?:\d{0,3}\.)?\d+)(?:deg)?\s*,?\s*([+-]?[\d.]+)%\s*,?\s*([+-]?[\d.]+)%\s*(?:[,|/]\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:e[+-]?\d+)?)\s*)?\)$/i,n=e.match(t);if(n){const e=Number.parseFloat(n[4]),t=(Number.parseFloat(n[1])%360+360)%360,r=s(Number.parseFloat(n[2]),0,100),i=s(Number.parseFloat(n[3]),0,100),o=s(Number.isNaN(e)?1:e,0,1);return[t,r,i,o]}return null},a.get.hwb=function(e){if(!e)return null;const t=/^hwb\(\s*([+-]?\d{0,3}(?:\.\d+)?)(?:deg)?\s*[\s,]\s*([+-]?[\d.]+)%\s*[\s,]\s*([+-]?[\d.]+)%\s*(?:[\s,]\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:e[+-]?\d+)?)\s*)?\)$/i,n=e.match(t);if(n){const e=Number.parseFloat(n[4]),t=(Number.parseFloat(n[1])%360+360)%360,r=s(Number.parseFloat(n[2]),0,100),i=s(Number.parseFloat(n[3]),0,100),o=s(Number.isNaN(e)?1:e,0,1);return[t,r,i,o]}return null},a.to.hex=function(...e){return"#"+l(e[0])+l(e[1])+l(e[2])+(e[3]<1?l(Math.round(255*e[3])):"")},a.to.rgb=function(...e){return e.length<4||1===e[3]?"rgb("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+")":"rgba("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+", "+e[3]+")"},a.to.rgb.percent=function(...e){const t=Math.round(e[0]/255*100),n=Math.round(e[1]/255*100),r=Math.round(e[2]/255*100);return e.length<4||1===e[3]?"rgb("+t+"%, "+n+"%, "+r+"%)":"rgba("+t+"%, "+n+"%, "+r+"%, "+e[3]+")"},a.to.hsl=function(...e){return e.length<4||1===e[3]?"hsl("+e[0]+", "+e[1]+"%, "+e[2]+"%)":"hsla("+e[0]+", "+e[1]+"%, "+e[2]+"%, "+e[3]+")"},a.to.hwb=function(...e){let t="";return e.length>=4&&1!==e[3]&&(t=", "+e[3]),"hwb("+e[0]+", "+e[1]+"%, "+e[2]+"%"+t+")"},a.to.keyword=function(...e){return o[e.slice(0,3)]};var c=a;const u={};for(const K of Object.keys(i))u[i[K]]=K;const d={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},oklab:{channels:3,labels:["okl","oka","okb"]},lch:{channels:3,labels:"lch"},oklch:{channels:3,labels:["okl","okc","okh"]},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};var h=d;const p=(6/29)**3;function f(e){const t=e>.0031308?1.055*e**(1/2.4)-.055:12.92*e;return Math.min(Math.max(0,t),1)}function m(e){return e>.04045?((e+.055)/1.055)**2.4:e/12.92}for(const K of Object.keys(d)){if(!("channels"in d[K]))throw new Error("missing channels property: "+K);if(!("labels"in d[K]))throw new Error("missing channel labels property: "+K);if(d[K].labels.length!==d[K].channels)throw new Error("channel and label counts mismatch: "+K);const{channels:e,labels:t}=d[K];delete d[K].channels,delete d[K].labels,Object.defineProperty(d[K],"channels",{value:e}),Object.defineProperty(d[K],"labels",{value:t})}function g(e,t){return(e[0]-t[0])**2+(e[1]-t[1])**2+(e[2]-t[2])**2}function v(){const e={},t=Object.keys(h);for(let{length:n}=t,r=0;r<n;r++)e[t[r]]={distance:-1,parent:null};return e}function b(e){const t=v(),n=[e];t[e].distance=0;while(n.length>0){const e=n.pop(),r=Object.keys(h[e]);for(let{length:i}=r,o=0;o<i;o++){const i=r[o],a=t[i];-1===a.distance&&(a.distance=t[e].distance+1,a.parent=e,n.unshift(i))}}return t}function y(e,t){return function(n){return t(e(n))}}function w(e,t){const n=[t[e].parent,e];let r=h[t[e].parent][e],i=t[e].parent;while(t[i].parent)n.unshift(t[i].parent),r=y(h[t[i].parent][i],r),i=t[i].parent;return r.conversion=n,r}function O(e){const t=b(e),n={},r=Object.keys(t);for(let{length:i}=r,o=0;o<i;o++){const e=r[o],i=t[e];null!==i.parent&&(n[e]=w(e,t))}return n}d.rgb.hsl=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,i=Math.min(t,n,r),o=Math.max(t,n,r),a=o-i;let s,l;switch(o){case i:s=0;break;case t:s=(n-r)/a;break;case n:s=2+(r-t)/a;break;case r:s=4+(t-n)/a;break}s=Math.min(60*s,360),s<0&&(s+=360);const c=(i+o)/2;return l=o===i?0:c<=.5?a/(o+i):a/(2-o-i),[s,100*l,100*c]},d.rgb.hsv=function(e){let t,n,r,i,o;const a=e[0]/255,s=e[1]/255,l=e[2]/255,c=Math.max(a,s,l),u=c-Math.min(a,s,l),d=function(e){return(c-e)/6/u+.5};if(0===u)i=0,o=0;else{switch(o=u/c,t=d(a),n=d(s),r=d(l),c){case a:i=r-n;break;case s:i=1/3+t-r;break;case l:i=2/3+n-t;break}i<0?i+=1:i>1&&(i-=1)}return[360*i,100*o,100*c]},d.rgb.hwb=function(e){const t=e[0],n=e[1];let r=e[2];const i=d.rgb.hsl(e)[0],o=1/255*Math.min(t,Math.min(n,r));return r=1-1/255*Math.max(t,Math.max(n,r)),[i,100*o,100*r]},d.rgb.oklab=function(e){const t=m(e[0]/255),n=m(e[1]/255),r=m(e[2]/255),i=Math.cbrt(.4122214708*t+.5363325363*n+.0514459929*r),o=Math.cbrt(.2119034982*t+.6806995451*n+.1073969566*r),a=Math.cbrt(.0883024619*t+.2817188376*n+.6299787005*r),s=.2104542553*i+.793617785*o-.0040720468*a,l=1.9779984951*i-2.428592205*o+.4505937099*a,c=.0259040371*i+.7827717662*o-.808675766*a;return[100*s,100*l,100*c]},d.rgb.cmyk=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,i=Math.min(1-t,1-n,1-r),o=(1-t-i)/(1-i)||0,a=(1-n-i)/(1-i)||0,s=(1-r-i)/(1-i)||0;return[100*o,100*a,100*s,100*i]},d.rgb.keyword=function(e){const t=u[e];if(t)return t;let n,r=Number.POSITIVE_INFINITY;for(const o of Object.keys(i)){const t=i[o],a=g(e,t);a<r&&(r=a,n=o)}return n},d.keyword.rgb=function(e){return[...i[e]]},d.rgb.xyz=function(e){const t=m(e[0]/255),n=m(e[1]/255),r=m(e[2]/255),i=.4124564*t+.3575761*n+.1804375*r,o=.2126729*t+.7151522*n+.072175*r,a=.0193339*t+.119192*n+.9503041*r;return[100*i,100*o,100*a]},d.rgb.lab=function(e){const t=d.rgb.xyz(e);let n=t[0],r=t[1],i=t[2];n/=95.047,r/=100,i/=108.883,n=n>p?n**(1/3):7.787*n+16/116,r=r>p?r**(1/3):7.787*r+16/116,i=i>p?i**(1/3):7.787*i+16/116;const o=116*r-16,a=500*(n-r),s=200*(r-i);return[o,a,s]},d.hsl.rgb=function(e){const t=e[0]/360,n=e[1]/100,r=e[2]/100;let i,o;if(0===n)return o=255*r,[o,o,o];const a=r<.5?r*(1+n):r+n-r*n,s=2*r-a,l=[0,0,0];for(let c=0;c<3;c++)i=t+1/3*-(c-1),i<0&&i++,i>1&&i--,o=6*i<1?s+6*(a-s)*i:2*i<1?a:3*i<2?s+(a-s)*(2/3-i)*6:s,l[c]=255*o;return l},d.hsl.hsv=function(e){const t=e[0];let n=e[1]/100,r=e[2]/100,i=n;const o=Math.max(r,.01);r*=2,n*=r<=1?r:2-r,i*=o<=1?o:2-o;const a=(r+n)/2,s=0===r?2*i/(o+i):2*n/(r+n);return[t,100*s,100*a]},d.hsv.rgb=function(e){const t=e[0]/60,n=e[1]/100;let r=e[2]/100;const i=Math.floor(t)%6,o=t-Math.floor(t),a=255*r*(1-n),s=255*r*(1-n*o),l=255*r*(1-n*(1-o));switch(r*=255,i){case 0:return[r,l,a];case 1:return[s,r,a];case 2:return[a,r,l];case 3:return[a,s,r];case 4:return[l,a,r];case 5:return[r,a,s]}},d.hsv.hsl=function(e){const t=e[0],n=e[1]/100,r=e[2]/100,i=Math.max(r,.01);let o,a;a=(2-n)*r;const s=(2-n)*i;return o=n*i,o/=s<=1?s:2-s,o=o||0,a/=2,[t,100*o,100*a]},d.hwb.rgb=function(e){const t=e[0]/360;let n=e[1]/100,r=e[2]/100;const i=n+r;let o;i>1&&(n/=i,r/=i);const a=Math.floor(6*t),s=1-r;o=6*t-a,0!==(1&a)&&(o=1-o);const l=n+o*(s-n);let c,u,d;switch(a){default:case 6:case 0:c=s,u=l,d=n;break;case 1:c=l,u=s,d=n;break;case 2:c=n,u=s,d=l;break;case 3:c=n,u=l,d=s;break;case 4:c=l,u=n,d=s;break;case 5:c=s,u=n,d=l;break}return[255*c,255*u,255*d]},d.cmyk.rgb=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100,i=e[3]/100,o=1-Math.min(1,t*(1-i)+i),a=1-Math.min(1,n*(1-i)+i),s=1-Math.min(1,r*(1-i)+i);return[255*o,255*a,255*s]},d.xyz.rgb=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100;let i,o,a;return i=3.2404542*t+-1.5371385*n+-.4985314*r,o=-.969266*t+1.8760108*n+.041556*r,a=.0556434*t+-.2040259*n+1.0572252*r,i=f(i),o=f(o),a=f(a),[255*i,255*o,255*a]},d.xyz.lab=function(e){let t=e[0],n=e[1],r=e[2];t/=95.047,n/=100,r/=108.883,t=t>p?t**(1/3):7.787*t+16/116,n=n>p?n**(1/3):7.787*n+16/116,r=r>p?r**(1/3):7.787*r+16/116;const i=116*n-16,o=500*(t-n),a=200*(n-r);return[i,o,a]},d.xyz.oklab=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100,i=Math.cbrt(.8189330101*t+.3618667424*n-.1288597137*r),o=Math.cbrt(.0329845436*t+.9293118715*n+.0361456387*r),a=Math.cbrt(.0482003018*t+.2643662691*n+.633851707*r),s=.2104542553*i+.793617785*o-.0040720468*a,l=1.9779984951*i-2.428592205*o+.4505937099*a,c=.0259040371*i+.7827717662*o-.808675766*a;return[100*s,100*l,100*c]},d.oklab.oklch=function(e){return d.lab.lch(e)},d.oklab.xyz=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100,i=(.999999998*t+.396337792*n+.215803758*r)**3,o=(1.000000008*t-.105561342*n-.063854175*r)**3,a=(1.000000055*t-.089484182*n-1.291485538*r)**3,s=1.227013851*i-.55779998*o+.281256149*a,l=-.040580178*i+1.11225687*o-.071676679*a,c=-.076381285*i-.421481978*o+1.58616322*a;return[100*s,100*l,100*c]},d.oklab.rgb=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100,i=(t+.3963377774*n+.2158037573*r)**3,o=(t-.1055613458*n-.0638541728*r)**3,a=(t-.0894841775*n-1.291485548*r)**3,s=f(4.0767416621*i-3.3077115913*o+.2309699292*a),l=f(-1.2684380046*i+2.6097574011*o-.3413193965*a),c=f(-.0041960863*i-.7034186147*o+1.707614701*a);return[255*s,255*l,255*c]},d.oklch.oklab=function(e){return d.lch.lab(e)},d.lab.xyz=function(e){const t=e[0],n=e[1],r=e[2];let i,o,a;o=(t+16)/116,i=n/500+o,a=o-r/200;const s=o**3,l=i**3,c=a**3;return o=s>p?s:(o-16/116)/7.787,i=l>p?l:(i-16/116)/7.787,a=c>p?c:(a-16/116)/7.787,i*=95.047,o*=100,a*=108.883,[i,o,a]},d.lab.lch=function(e){const t=e[0],n=e[1],r=e[2];let i;const o=Math.atan2(r,n);i=360*o/2/Math.PI,i<0&&(i+=360);const a=Math.sqrt(n*n+r*r);return[t,a,i]},d.lch.lab=function(e){const t=e[0],n=e[1],r=e[2],i=r/360*2*Math.PI,o=n*Math.cos(i),a=n*Math.sin(i);return[t,o,a]},d.rgb.ansi16=function(e,t=null){const[n,r,i]=e;let o=null===t?d.rgb.hsv(e)[2]:t;if(o=Math.round(o/50),0===o)return 30;let a=30+(Math.round(i/255)<<2|Math.round(r/255)<<1|Math.round(n/255));return 2===o&&(a+=60),a},d.hsv.ansi16=function(e){return d.rgb.ansi16(d.hsv.rgb(e),e[2])},d.rgb.ansi256=function(e){const t=e[0],n=e[1],r=e[2];if(t>>4===n>>4&&n>>4===r>>4)return t<8?16:t>248?231:Math.round((t-8)/247*24)+232;const i=16+36*Math.round(t/255*5)+6*Math.round(n/255*5)+Math.round(r/255*5);return i},d.ansi16.rgb=function(e){e=e[0];let t=e%10;if(0===t||7===t)return e>50&&(t+=3.5),t=t/10.5*255,[t,t,t];const n=.5*(Math.trunc(e>50)+1),r=(1&t)*n*255,i=(t>>1&1)*n*255,o=(t>>2&1)*n*255;return[r,i,o]},d.ansi256.rgb=function(e){if(e=e[0],e>=232){const t=10*(e-232)+8;return[t,t,t]}let t;e-=16;const n=Math.floor(e/36)/5*255,r=Math.floor((t=e%36)/6)/5*255,i=t%6/5*255;return[n,r,i]},d.rgb.hex=function(e){const t=((255&Math.round(e[0]))<<16)+((255&Math.round(e[1]))<<8)+(255&Math.round(e[2])),n=t.toString(16).toUpperCase();return"000000".slice(n.length)+n},d.hex.rgb=function(e){const t=e.toString(16).match(/[a-f\d]{6}|[a-f\d]{3}/i);if(!t)return[0,0,0];let n=t[0];3===t[0].length&&(n=[...n].map(e=>e+e).join(""));const r=Number.parseInt(n,16),i=r>>16&255,o=r>>8&255,a=255&r;return[i,o,a]},d.rgb.hcg=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,i=Math.max(Math.max(t,n),r),o=Math.min(Math.min(t,n),r),a=i-o;let s;const l=a<1?o/(1-a):0;return s=a<=0?0:i===t?(n-r)/a%6:i===n?2+(r-t)/a:4+(t-n)/a,s/=6,s%=1,[360*s,100*a,100*l]},d.hsl.hcg=function(e){const t=e[1]/100,n=e[2]/100,r=n<.5?2*t*n:2*t*(1-n);let i=0;return r<1&&(i=(n-.5*r)/(1-r)),[e[0],100*r,100*i]},d.hsv.hcg=function(e){const t=e[1]/100,n=e[2]/100,r=t*n;let i=0;return r<1&&(i=(n-r)/(1-r)),[e[0],100*r,100*i]},d.hcg.rgb=function(e){const t=e[0]/360,n=e[1]/100,r=e[2]/100;if(0===n)return[255*r,255*r,255*r];const i=[0,0,0],o=t%1*6,a=o%1,s=1-a;let l=0;switch(Math.floor(o)){case 0:i[0]=1,i[1]=a,i[2]=0;break;case 1:i[0]=s,i[1]=1,i[2]=0;break;case 2:i[0]=0,i[1]=1,i[2]=a;break;case 3:i[0]=0,i[1]=s,i[2]=1;break;case 4:i[0]=a,i[1]=0,i[2]=1;break;default:i[0]=1,i[1]=0,i[2]=s}return l=(1-n)*r,[255*(n*i[0]+l),255*(n*i[1]+l),255*(n*i[2]+l)]},d.hcg.hsv=function(e){const t=e[1]/100,n=e[2]/100,r=t+n*(1-t);let i=0;return r>0&&(i=t/r),[e[0],100*i,100*r]},d.hcg.hsl=function(e){const t=e[1]/100,n=e[2]/100,r=n*(1-t)+.5*t;let i=0;return r>0&&r<.5?i=t/(2*r):r>=.5&&r<1&&(i=t/(2*(1-r))),[e[0],100*i,100*r]},d.hcg.hwb=function(e){const t=e[1]/100,n=e[2]/100,r=t+n*(1-t);return[e[0],100*(r-t),100*(1-r)]},d.hwb.hcg=function(e){const t=e[1]/100,n=e[2]/100,r=1-n,i=r-t;let o=0;return i<1&&(o=(r-i)/(1-i)),[e[0],100*i,100*o]},d.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]},d.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]},d.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]},d.gray.hsl=function(e){return[0,0,e[0]]},d.gray.hsv=d.gray.hsl,d.gray.hwb=function(e){return[0,100,e[0]]},d.gray.cmyk=function(e){return[0,0,0,e[0]]},d.gray.lab=function(e){return[e[0],0,0]},d.gray.hex=function(e){const t=255&Math.round(e[0]/100*255),n=(t<<16)+(t<<8)+t,r=n.toString(16).toUpperCase();return"000000".slice(r.length)+r},d.rgb.gray=function(e){const t=(e[0]+e[1]+e[2])/3;return[t/255*100]};var S=O;const E={},x=Object.keys(h);function _(e){const t=function(...t){const n=t[0];return void 0===n||null===n?n:(n.length>1&&(t=n),e(t))};return"conversion"in e&&(t.conversion=e.conversion),t}function k(e){const t=function(...t){const n=t[0];if(void 0===n||null===n)return n;n.length>1&&(t=n);const r=e(t);if("object"===typeof r)for(let{length:e}=r,i=0;i<e;i++)r[i]=Math.round(r[i]);return r};return"conversion"in e&&(t.conversion=e.conversion),t}for(const K of x){E[K]={},Object.defineProperty(E[K],"channels",{value:h[K].channels}),Object.defineProperty(E[K],"labels",{value:h[K].labels});const e=S(K),t=Object.keys(e);for(const n of t){const t=e[n];E[K][n]=k(t),E[K][n].raw=_(t)}}var C=E;const A=["keyword","gray","hex"],T={};for(const K of Object.keys(C))T[[...C[K].labels].sort().join("")]=K;const R={};function N(e,t){if(!(this instanceof N))return new N(e,t);if(t&&t in A&&(t=null),t&&!(t in C))throw new Error("Unknown model: "+t);let n,r;if(null==e)this.model="rgb",this.color=[0,0,0],this.valpha=1;else if(e instanceof N)this.model=e.model,this.color=[...e.color],this.valpha=e.valpha;else if("string"===typeof e){const t=c.get(e);if(null===t)throw new Error("Unable to parse color from string: "+e);this.model=t.model,r=C[this.model].channels,this.color=t.value.slice(0,r),this.valpha="number"===typeof t.value[r]?t.value[r]:1}else if(e.length>0){this.model=t||"rgb",r=C[this.model].channels;const n=Array.prototype.slice.call(e,0,r);this.color=B(n,r),this.valpha="number"===typeof e[r]?e[r]:1}else if("number"===typeof e)this.model="rgb",this.color=[e>>16&255,e>>8&255,255&e],this.valpha=1;else{this.valpha=1;const t=Object.keys(e);"alpha"in e&&(t.splice(t.indexOf("alpha"),1),this.valpha="number"===typeof e.alpha?e.alpha:0);const r=t.sort().join("");if(!(r in T))throw new Error("Unable to parse color from object: "+JSON.stringify(e));this.model=T[r];const{labels:i}=C[this.model],o=[];for(n=0;n<i.length;n++)o.push(e[i[n]]);this.color=B(o)}if(R[this.model])for(r=C[this.model].channels,n=0;n<r;n++){const e=R[this.model][n];e&&(this.color[n]=e(this.color[n]))}this.valpha=Math.max(0,Math.min(1,this.valpha)),Object.freeze&&Object.freeze(this)}N.prototype={toString(){return this.string()},toJSON(){return this[this.model]()},string(e){let t=this.model in c.to?this:this.rgb();t=t.round("number"===typeof e?e:1);const n=1===t.valpha?t.color:[...t.color,this.valpha];return c.to[t.model](...n)},percentString(e){const t=this.rgb().round("number"===typeof e?e:1),n=1===t.valpha?t.color:[...t.color,this.valpha];return c.to.rgb.percent(...n)},array(){return 1===this.valpha?[...this.color]:[...this.color,this.valpha]},object(){const e={},{channels:t}=C[this.model],{labels:n}=C[this.model];for(let r=0;r<t;r++)e[n[r]]=this.color[r];return 1!==this.valpha&&(e.alpha=this.valpha),e},unitArray(){const e=this.rgb().color;return e[0]/=255,e[1]/=255,e[2]/=255,1!==this.valpha&&e.push(this.valpha),e},unitObject(){const e=this.rgb().object();return e.r/=255,e.g/=255,e.b/=255,1!==this.valpha&&(e.alpha=this.valpha),e},round(e){return e=Math.max(e||0,0),new N([...this.color.map(I(e)),this.valpha],this.model)},alpha(e){return void 0!==e?new N([...this.color,Math.max(0,Math.min(1,e))],this.model):this.valpha},red:M("rgb",0,D(255)),green:M("rgb",1,D(255)),blue:M("rgb",2,D(255)),hue:M(["hsl","hsv","hsl","hwb","hcg"],0,e=>(e%360+360)%360),saturationl:M("hsl",1,D(100)),lightness:M("hsl",2,D(100)),saturationv:M("hsv",1,D(100)),value:M("hsv",2,D(100)),chroma:M("hcg",1,D(100)),gray:M("hcg",2,D(100)),white:M("hwb",1,D(100)),wblack:M("hwb",2,D(100)),cyan:M("cmyk",0,D(100)),magenta:M("cmyk",1,D(100)),yellow:M("cmyk",2,D(100)),black:M("cmyk",3,D(100)),x:M("xyz",0,D(95.047)),y:M("xyz",1,D(100)),z:M("xyz",2,D(108.833)),l:M("lab",0,D(100)),a:M("lab",1),b:M("lab",2),keyword(e){return void 0!==e?new N(e):C[this.model].keyword(this.color)},hex(e){return void 0!==e?new N(e):c.to.hex(...this.rgb().round().color)},hexa(e){if(void 0!==e)return new N(e);const t=this.rgb().round().color;let n=Math.round(255*this.valpha).toString(16).toUpperCase();return 1===n.length&&(n="0"+n),c.to.hex(...t)+n},rgbNumber(){const e=this.rgb().color;return(255&e[0])<<16|(255&e[1])<<8|255&e[2]},luminosity(){const e=this.rgb().color,t=[];for(const[n,r]of e.entries()){const e=r/255;t[n]=e<=.04045?e/12.92:((e+.055)/1.055)**2.4}return.2126*t[0]+.7152*t[1]+.0722*t[2]},contrast(e){const t=this.luminosity(),n=e.luminosity();return t>n?(t+.05)/(n+.05):(n+.05)/(t+.05)},level(e){const t=this.contrast(e);return t>=7?"AAA":t>=4.5?"AA":""},isDark(){const e=this.rgb().color,t=(2126*e[0]+7152*e[1]+722*e[2])/1e4;return t<128},isLight(){return!this.isDark()},negate(){const e=this.rgb();for(let t=0;t<3;t++)e.color[t]=255-e.color[t];return e},lighten(e){const t=this.hsl();return t.color[2]+=t.color[2]*e,t},darken(e){const t=this.hsl();return t.color[2]-=t.color[2]*e,t},saturate(e){const t=this.hsl();return t.color[1]+=t.color[1]*e,t},desaturate(e){const t=this.hsl();return t.color[1]-=t.color[1]*e,t},whiten(e){const t=this.hwb();return t.color[1]+=t.color[1]*e,t},blacken(e){const t=this.hwb();return t.color[2]+=t.color[2]*e,t},grayscale(){const e=this.rgb().color,t=.3*e[0]+.59*e[1]+.11*e[2];return N.rgb(t,t,t)},fade(e){return this.alpha(this.valpha-this.valpha*e)},opaquer(e){return this.alpha(this.valpha+this.valpha*e)},rotate(e){const t=this.hsl();let n=t.color[0];return n=(n+e)%360,n=n<0?360+n:n,t.color[0]=n,t},mix(e,t){if(!e||!e.rgb)throw new Error('Argument to "mix" was not a Color instance, but rather an instance of '+typeof e);const n=e.rgb(),r=this.rgb(),i=void 0===t?.5:t,o=2*i-1,a=n.alpha()-r.alpha(),s=((o*a===-1?o:(o+a)/(1+o*a))+1)/2,l=1-s;return N.rgb(s*n.red()+l*r.red(),s*n.green()+l*r.green(),s*n.blue()+l*r.blue(),n.alpha()*i+r.alpha()*(1-i))}};for(const K of Object.keys(C)){if(A.includes(K))continue;const{channels:e}=C[K];N.prototype[K]=function(...e){return this.model===K?new N(this):e.length>0?new N(e,K):new N([...L(C[this.model][K].raw(this.color)),this.valpha],K)},N[K]=function(...t){let n=t[0];return"number"===typeof n&&(n=B(t,e)),new N(n,K)}}function P(e,t){return Number(e.toFixed(t))}function I(e){return function(t){return P(t,e)}}function M(e,t,n){e=Array.isArray(e)?e:[e];for(const r of e)(R[r]||=[])[t]=n;return e=e[0],function(r){let i;return void 0!==r?(n&&(r=n(r)),i=this[e](),i.color[t]=r,i):(i=this[e]().color[t],n&&(i=n(i)),i)}}function D(e){return function(t){return Math.max(0,Math.min(e,t))}}function L(e){return Array.isArray(e)?e:[e]}function B(e,t){for(let n=0;n<t;n++)"number"!==typeof e[n]&&(e[n]=0);return e}var $=N,V=n(4364);const F={black:"#000000",white:"#ffffff"};function j(e){return $(e)}function U(e){const t=e.rgb().array(),n=Math.round((299*parseInt(t[0])+587*parseInt(t[1])+114*parseInt(t[2]))/1e3);return n>125?"black":"white"}function G(e){const t=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(e);return t?{r:parseInt(t[1],16),g:parseInt(t[2],16),b:parseInt(t[3],16)}:null}function H(e){return F[e]||e}function q(e){const t=/^rgb\(([0-9]{1,3}),\s*([0-9]{1,3}),\s*([0-9]{1,3})\)$/i.exec(e);return t?{r:parseInt(t[1],10),g:parseInt(t[2],10),b:parseInt(t[3],10)}:null}function Q(e){let t;return e.startsWith("rgb(")?t=q(e):e.startsWith("#")?t=G(e):V.warn(`Unable to parse color: ${e}`),t||{r:0,g:0,b:0}}function z(e){return e.includes("#")&&4===e.length?`#${e[1]}${e[1]}${e[2]}${e[2]}${e[3]}${e[3]}`:e.includes("#")||3!==e.length?e:`${e[0]}${e[0]}${e[1]}${e[1]}${e[2]}${e[2]}`}},37648:function(e,t,n){"use strict";n.d(t,{Cd:function(){return x},Kq:function(){return k},Ng:function(){return h},Yd:function(){return g},fs:function(){return _},mH:function(){return v},xs:function(){return u}});var r=n(92043),i=n(68851),o=n(20246),a=n.n(o),s=n(76978),l=n(2334),c=n(4364);const u=["string","multiline","masked","password","float","int","date","blob","boolean","version"],d=["apiVersion","kind","metadata","metadata.name","spec","spec.selector","spec.selector.matchLabels","spec.template","spec.template.metadata","spec.template.metadata.labels","spec.template.spec.containers.name","spec.template.spec.containers.image"],h=["metadata.clusterName","metadata.creationTimestamp","metadata.deletionGracePeriodSeconds","metadata.deletionTimestamp","metadata.finalizers","metadata.generateName","metadata.generation","metadata.initializers","metadata.managedFields","metadata.ownerReferences","metadata.resourceVersion","metadata.relationships","metadata.selfLink","metadata.state","metadata.uid","spec.versions.schema","status","stringData","links","_name","_labels","_annotations"],p=["metadata.managedFields","metadata.relationships","metadata.state","status","links","type","id"],f=2;function m(e){return null===e||void 0===e||""===e||(Array.isArray(e)?e.every(m):"object"===typeof e&&Object.values(e).every(m))}function g(e,t,n,r,i){return v(e,t,n,!0,0,"",null,r,i)}function v(e,t,n,r=!0,o=0,l="",f=null,g={},O=null){let S,E,k,A;if(n=n||{},0===o){if(S=(0,i.jq)(e,"id",t),!S)return`Error loading schema for ${t}`;E=S,k=E.schemaDefinitions,A=E.resourceFields;const r=S.attributes||{};n.apiVersion=(r.group?`${r.group}/${r.version}`:r.version)||n.apiVersion,n.kind=r.kind||n.kind}else if(E=(0,i.jq)(e,"id",f),E.requiresResourceFields)k=E.schemaDefinitions,A=k[t]?.resourceFields;else{if(S=(0,i.jq)(e,"id",t),!S)return`Error loading schema for ${t}`;A=S.resourceFields}f||(f=t);const T=[];if(O||(O=n?.commentFieldsOptions),r){const e=d.slice();for(let t=e.length-1;t>=0;t--){let n=e[t].split(/\./);while(n.length)(0,i.PG)(e,n.join(".")),n=n.slice(0,-1)}for(const t of e){const e=t.split(/\./),n=e[e.length-1],r=e.slice(0,-1).join(".");r===l&&A&&A[n]&&(0,i.PG)(T,n)}}const R=Object.keys(A||{});R.forEach(e=>{("undefined"!==typeof n[e]||0===o&&"_type"===e)&&(0,i.PG)(T,e)});for(const a in n)"undefined"!==typeof n[a]&&(0,i.PG)(T,a);for(const a of g.activelyRemove||p){const e=a.split(/\./),t=e[e.length-1],n=e.slice(0,-1).join(".");n===l&&(0,i.Gj)(T,t)}for(const a of h){const e=a.split(/\./),t=e[e.length-1],n=e.slice(0,-1).join(".");n===l&&A&&A[t]&&(0,i.Gj)(R,t)}(0,i.$M)(R,T);const N=T.map(e=>M(e)),P=R.map(e=>"metadata"===l&&"namespace"===e&&E&&!E.attributes?.namespaced?null:b(M(e))),I=[...N,...P].filter(e=>null!==e).join("\n").trim();return I;function M(t){const d=A?.[t];let h=`${t}:`;if("_type"===t&&(h="type:"),O=D(O,n,l,t),Array.isArray(O)&&O.length){const e=l?`${l}.${t}`:t;O.some(t=>`${t.path}.${t.key}`===e)&&(h=`#${h}`)}if(!d){if(n[t])try{const e=(0,s.nY)(n),r=a().dump(e[t]);return"object"===typeof n[t]||Array.isArray(n[t])?h+=`\n${y(r.trim())}`:h+=` ${r.trim()}`,h}catch(R){c.error(`Error: Unable to parse map data for yaml key: ${t}`,R)}return null}const p=_(d.type),b=x("map",p,d),S=x("array",p,d),E=x("reference",p);if(b){if(n[t])try{const e=(0,s.nY)(n),r=C(e[t],g[t]);h+=`\n${y(r)}`}catch(R){c.error(`Error: Unable to parse map data for yaml of type: ${p}`,R)}if(u.includes(b))h+=`# key: ${b}`;else{const n=v(e,b,null,r,o+1,l?`${l}.${t}`:t,f,g,O);let i=y(n);i=i.replace(/^(#)?\s\s\s\s/,"$1"),h+=`${i}`}return h}if(S){if(n[t])try{const e=(0,s.nY)(n);if(e?.[t]){const r=a().dump(e[t]);let i;if(Array.isArray(O)&&O.length){let e=r.split("\n");O.forEach(r=>{`${l}.${t}`===r.path&&void 0!==n[t][r.key]&&(e=e.map((e,t)=>t===Number(r.key)?`#${e}`:e))}),i=e.join("\n").trim()}else i=r.trim();h+=`\n${y(i)}`}}catch(R){c.error(`Error: Unable to parse array data for yaml of type: ${p}`,R)}if(u.includes(S))h+=`\n# - ${S}`;else{const n=v(e,S,null,!1,o+1,l?`${l}.${t}`:t,f,g,O);let r=y(n,2);r=r.replace(/^(#)?\s*\s\s([^\s])/,"$1 - $2"),h+=`\n${r}`}return h}if(E)return h+=` #${E}`,h;if(u.includes(p))return"_type"===t&&"undefined"===typeof n[t]&&"undefined"!==typeof n["type"]?h+=` ${w(n["type"])}`:"undefined"===typeof n[t]?h+=` #${w(p)}`:h+=` ${w(n[t])}`,h;if("json"===p||".spec"===p)try{const e=a().dump(n[t]);return h+=e?`\n${y(e.trim())}`:` #${p}`,h}catch(R){}const T=k?.[p]||(0,i.jq)(e,"id",p);if(T){let i;if(g?.collapseEmptyObjects&&n[t]&&"object"===typeof n[t]&&!Array.isArray(n[t])&&m(n[t]))return h+=" {}",h;if(T?.resourceFields&&!(0,s.Im)(T?.resourceFields))i=v(e,p,n[t],r,o+1,l?`${l}.${t}`:t,f,g,O);else if(n[t])try{const e=a().dump(n[t]);if(Array.isArray(O)&&O.length){let r=e.split("\n");O.forEach(e=>{if(`${l}.${t}`===e.path&&void 0!==n[t][e.key]){const t=`${e.key}:`;r=r.map(e=>e.trim().startsWith(t)?`# ${e}`:e)}}),i=r.join("\n").trim()}else i=e.trim()}catch(R){c.error(`Error: Unable to parse data for yaml of type: ${p}`,R)}h+=`\n${y(i)}`}else h+=` #${p}`;return h}function D(e,t,n,r){if(e&&Array.isArray(e)&&e.length){const i=n?`${n}.${r}`:r;e.some(e=>`${e.path}.${e.key}`===i)&&(e=[...e,...Object.keys(t[r]).map(e=>({path:`${n}.${r}`,key:e}))])}return e}}function b(e){return(e||"").split("\n").map(e=>`#${e.replace(/#/g,"")}`).join("\n")}function y(e,t=1){return(0,r.pZ)(e,t*f," ",/^#/)}function w(e){return a().dump(e).trim()}function O(e,t){const n=S(e,t);return{header:n,indentation:E(n)}}function S(e,t){const n=`(${t})[\\:][\\s|\\t]+[\\|\\>][\\d]*[\\-\\+]?`,r=new RegExp(n,"gi"),i=e.match(r);return i?.[0]||""}function E(e){const t=e.substr(e.indexOf(":")+1),n=t.match(/\d+/);return n?.[0]||""}function x(e,t,n=null){const[r,i]=(0,l.parseType)(t,n);if(e===r)return _(i||r)}function _(e){return"integer"===e?"int":"io.k8s.apimachinery.pkg.api.resource.Quantity"===e?"string":e}function k(e){const t=a().dump(e||{});return"{}\n"===t?"":t}function C(e,t={lineWidth:-1}){const n=a().dump(e,t);let r=n;const i=Object.keys(e).filter(t=>{if("string"===typeof e[t])return e[t].includes("\n")});if(i.length)for(const o of i){const{header:e,indentation:n}=O(r,o),i=t[o]?.scalarStyle??"|",a=t[o]?.chomping??"";e&&(r=r.replace(e,`${o}: ${i}${a}${n}`))}return r}},8755:function(e,t,n){"use strict";n.d(t,{Kz:function(){return a},en:function(){return o},pP:function(){return s}});var r=n(1048);function i(e){let t=0;for(let n=0;n<e.length;n++){const r=e.charCodeAt(n);t=(t<<5)-t+r,t&=t}return new Uint32Array([t])[0].toString(36)}function o(e){return i(JSON.stringify(e,null,2))}function a(e){return"string"===typeof e?0===e.length:0===e.byteLength}function s(e){return"string"===typeof e&&(e=new r.Buffer(e,"utf8")),ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength/Uint8Array.BYTES_PER_ELEMENT):new Uint8Array(e)}},4514:function(e,t,n){"use strict";n.d(t,{u:function(){return A},KA:function(){return k},dQ:function(){return R},Fx:function(){return T}});var r=n(1048),i=n(8755);const o=64,a=16;function s(){this.state=[1732584193,4023233417,2562383102,271733878],this.buffer=new DataView(new ArrayBuffer(o)),this.bufferLength=0,this.bytesHashed=0,this.finished=!1}var l=s;function c(e,t,n,r,i,o){return t=(t+e&4294967295)+(r+o&4294967295)&4294967295,(t<<i|t>>>32-i)+n&4294967295}function u(e,t,n,r,i,o,a){return c(t&n|~t&r,e,t,i,o,a)}function d(e,t,n,r,i,o,a){return c(t&r|n&~r,e,t,i,o,a)}function h(e,t,n,r,i,o,a){return c(t^n^r,e,t,i,o,a)}function p(e,t,n,r,i,o,a){return c(n^(t|~r),e,t,i,o,a)}s.BLOCK_SIZE=o,s.prototype.update=function(e){if((0,i.Kz)(e))return this;if(this.finished)throw new Error("Attempted to update an already finished hash.");const t=(0,i.pP)(e);let n=0,r=t.byteLength;this.bytesHashed+=r;while(r>0)this.buffer.setUint8(this.bufferLength++,t[n++]),r--,this.bufferLength===o&&(this.hashBuffer(),this.bufferLength=0);return this},s.prototype.digest=function(e){if(!this.finished){const e=this,t=e.buffer,n=e.bufferLength,r=e.bytesHashed,i=8*r;if(t.setUint8(this.bufferLength++,128),n%o>=o-8){for(let e=this.bufferLength;e<o;e++)t.setUint8(e,0);this.hashBuffer(),this.bufferLength=0}for(let a=this.bufferLength;a<o-8;a++)t.setUint8(a,0);t.setUint32(o-8,i>>>0,!0),t.setUint32(o-4,Math.floor(i/4294967296),!0),this.hashBuffer(),this.finished=!0}const t=new DataView(new ArrayBuffer(a));for(let r=0;r<4;r++)t.setUint32(4*r,this.state[r],!0);const n=new r.Buffer(t.buffer,t.byteOffset,t.byteLength);return e?n.toString(e):n},s.prototype.hashBuffer=function(){const e=this,t=e.buffer,n=e.state;let r=n[0],i=n[1],o=n[2],a=n[3];r=u(r,i,o,a,t.getUint32(0,!0),7,3614090360),a=u(a,r,i,o,t.getUint32(4,!0),12,3905402710),o=u(o,a,r,i,t.getUint32(8,!0),17,606105819),i=u(i,o,a,r,t.getUint32(12,!0),22,3250441966),r=u(r,i,o,a,t.getUint32(16,!0),7,4118548399),a=u(a,r,i,o,t.getUint32(20,!0),12,1200080426),o=u(o,a,r,i,t.getUint32(24,!0),17,2821735955),i=u(i,o,a,r,t.getUint32(28,!0),22,4249261313),r=u(r,i,o,a,t.getUint32(32,!0),7,1770035416),a=u(a,r,i,o,t.getUint32(36,!0),12,2336552879),o=u(o,a,r,i,t.getUint32(40,!0),17,4294925233),i=u(i,o,a,r,t.getUint32(44,!0),22,2304563134),r=u(r,i,o,a,t.getUint32(48,!0),7,1804603682),a=u(a,r,i,o,t.getUint32(52,!0),12,4254626195),o=u(o,a,r,i,t.getUint32(56,!0),17,2792965006),i=u(i,o,a,r,t.getUint32(60,!0),22,1236535329),r=d(r,i,o,a,t.getUint32(4,!0),5,4129170786),a=d(a,r,i,o,t.getUint32(24,!0),9,3225465664),o=d(o,a,r,i,t.getUint32(44,!0),14,643717713),i=d(i,o,a,r,t.getUint32(0,!0),20,3921069994),r=d(r,i,o,a,t.getUint32(20,!0),5,3593408605),a=d(a,r,i,o,t.getUint32(40,!0),9,38016083),o=d(o,a,r,i,t.getUint32(60,!0),14,3634488961),i=d(i,o,a,r,t.getUint32(16,!0),20,3889429448),r=d(r,i,o,a,t.getUint32(36,!0),5,568446438),a=d(a,r,i,o,t.getUint32(56,!0),9,3275163606),o=d(o,a,r,i,t.getUint32(12,!0),14,4107603335),i=d(i,o,a,r,t.getUint32(32,!0),20,1163531501),r=d(r,i,o,a,t.getUint32(52,!0),5,2850285829),a=d(a,r,i,o,t.getUint32(8,!0),9,4243563512),o=d(o,a,r,i,t.getUint32(28,!0),14,1735328473),i=d(i,o,a,r,t.getUint32(48,!0),20,2368359562),r=h(r,i,o,a,t.getUint32(20,!0),4,4294588738),a=h(a,r,i,o,t.getUint32(32,!0),11,2272392833),o=h(o,a,r,i,t.getUint32(44,!0),16,1839030562),i=h(i,o,a,r,t.getUint32(56,!0),23,4259657740),r=h(r,i,o,a,t.getUint32(4,!0),4,2763975236),a=h(a,r,i,o,t.getUint32(16,!0),11,1272893353),o=h(o,a,r,i,t.getUint32(28,!0),16,4139469664),i=h(i,o,a,r,t.getUint32(40,!0),23,3200236656),r=h(r,i,o,a,t.getUint32(52,!0),4,681279174),a=h(a,r,i,o,t.getUint32(0,!0),11,3936430074),o=h(o,a,r,i,t.getUint32(12,!0),16,3572445317),i=h(i,o,a,r,t.getUint32(24,!0),23,76029189),r=h(r,i,o,a,t.getUint32(36,!0),4,3654602809),a=h(a,r,i,o,t.getUint32(48,!0),11,3873151461),o=h(o,a,r,i,t.getUint32(60,!0),16,530742520),i=h(i,o,a,r,t.getUint32(8,!0),23,3299628645),r=p(r,i,o,a,t.getUint32(0,!0),6,4096336452),a=p(a,r,i,o,t.getUint32(28,!0),10,1126891415),o=p(o,a,r,i,t.getUint32(56,!0),15,2878612391),i=p(i,o,a,r,t.getUint32(20,!0),21,4237533241),r=p(r,i,o,a,t.getUint32(48,!0),6,1700485571),a=p(a,r,i,o,t.getUint32(12,!0),10,2399980690),o=p(o,a,r,i,t.getUint32(40,!0),15,4293915773),i=p(i,o,a,r,t.getUint32(4,!0),21,2240044497),r=p(r,i,o,a,t.getUint32(32,!0),6,1873313359),a=p(a,r,i,o,t.getUint32(60,!0),10,4264355552),o=p(o,a,r,i,t.getUint32(24,!0),15,2734768916),i=p(i,o,a,r,t.getUint32(52,!0),21,1309151649),r=p(r,i,o,a,t.getUint32(16,!0),6,4149444226),a=p(a,r,i,o,t.getUint32(44,!0),10,3174756917),o=p(o,a,r,i,t.getUint32(8,!0),15,718787259),i=p(i,o,a,r,t.getUint32(36,!0),21,3951481745),n[0]=r+n[0]&4294967295,n[1]=i+n[1]&4294967295,n[2]=o+n[2]&4294967295,n[3]=a+n[3]&4294967295};const f=64,m=32,g=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),v=2**53-1;function b(){this.state=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.temp=new Int32Array(64),this.buffer=new Uint8Array(64),this.bufferLength=0,this.bytesHashed=0,this.finished=!1}var y=b;b.BLOCK_SIZE=f,b.prototype.update=function(e){if(this.finished)throw new Error("Attempted to update an already finished hash.");if((0,i.Kz)(e))return this;e=(0,i.pP)(e);let t=0,n=e.byteLength;if(this.bytesHashed+=n,8*this.bytesHashed>v)throw new Error("Cannot hash more than 2^53 - 1 bits");while(n>0)this.buffer[this.bufferLength++]=e[t++],n--,this.bufferLength===f&&(this.hashBuffer(),this.bufferLength=0);return this},b.prototype.digest=function(e){if(!this.finished){const e=8*this.bytesHashed,t=new DataView(this.buffer.buffer,this.buffer.byteOffset,this.buffer.byteLength),n=this.bufferLength;if(t.setUint8(this.bufferLength++,128),n%f>=f-8){for(let e=this.bufferLength;e<f;e++)t.setUint8(e,0);this.hashBuffer(),this.bufferLength=0}for(let r=this.bufferLength;r<f-8;r++)t.setUint8(r,0);t.setUint32(f-8,Math.floor(e/4294967296),!0),t.setUint32(f-4,e),this.hashBuffer(),this.finished=!0}const t=new r.Buffer(m);for(let n=0;n<8;n++)t[4*n]=this.state[n]>>>24&255,t[4*n+1]=this.state[n]>>>16&255,t[4*n+2]=this.state[n]>>>8&255,t[4*n+3]=this.state[n]>>>0&255;return e?t.toString(e):t},b.prototype.hashBuffer=function(){const e=this,t=e.buffer,n=e.state;let r=n[0],i=n[1],o=n[2],a=n[3],s=n[4],l=n[5],c=n[6],u=n[7];for(let d=0;d<f;d++){if(d<16)this.temp[d]=(255&t[4*d])<<24|(255&t[4*d+1])<<16|(255&t[4*d+2])<<8|255&t[4*d+3];else{let e=this.temp[d-2];const t=(e>>>17|e<<15)^(e>>>19|e<<13)^e>>>10;e=this.temp[d-15];const n=(e>>>7|e<<25)^(e>>>18|e<<14)^e>>>3;this.temp[d]=(t+this.temp[d-7]|0)+(n+this.temp[d-16]|0)}const e=(((s>>>6|s<<26)^(s>>>11|s<<21)^(s>>>25|s<<7))+(s&l^~s&c)|0)+(u+(g[d]+this.temp[d]|0)|0)|0,n=((r>>>2|r<<30)^(r>>>13|r<<19)^(r>>>22|r<<10))+(r&i^r&o^i&o)|0;u=c,c=l,l=s,s=a+e|0,a=o,o=i,i=r,r=e+n|0}n[0]+=r,n[1]+=i,n[2]+=o,n[3]+=a,n[4]+=s,n[5]+=l,n[6]+=c,n[7]+=u};const w=64,O=20;function S(){this.h0=1732584193,this.h1=4023233417,this.h2=2562383102,this.h3=271733878,this.h4=3285377520,this.block=new Uint32Array(80),this.offset=0,this.shift=24,this.totalLength=0}var E=S;S.BLOCK_SIZE=w,S.prototype.update=function(e){if(this.finished)throw new Error("Attempted to update an already finished hash.");if((0,i.Kz)(e))return this;e=(0,i.pP)(e);const t=e.length;this.totalLength+=8*t;for(let n=0;n<t;n++)this.write(e[n]);return this},S.prototype.write=function(e){this.block[this.offset]|=(255&e)<<this.shift,this.shift?this.shift-=8:(this.offset++,this.shift=24),16===this.offset&&this.processBlock()},S.prototype.digest=function(e){this.write(128),(this.offset>14||14===this.offset&&this.shift<24)&&this.processBlock(),this.offset=14,this.shift=24,this.write(0),this.write(0),this.write(this.totalLength>0xffffffffff?this.totalLength/1099511627776:0),this.write(this.totalLength>4294967295?this.totalLength/4294967296:0);for(let r=24;r>=0;r-=8)this.write(this.totalLength>>r);const t=new r.Buffer(O),n=new DataView(t.buffer);return n.setUint32(0,this.h0,!1),n.setUint32(4,this.h1,!1),n.setUint32(8,this.h2,!1),n.setUint32(12,this.h3,!1),n.setUint32(16,this.h4,!1),e?t.toString(e):t},S.prototype.processBlock=function(){for(let s=16;s<80;s++){const e=this.block[s-3]^this.block[s-8]^this.block[s-14]^this.block[s-16];this.block[s]=e<<1|e>>>31}let e,t,n=this.h0,r=this.h1,i=this.h2,o=this.h3,a=this.h4;for(let s=0;s<80;s++){s<20?(e=o^r&(i^o),t=1518500249):s<40?(e=r^i^o,t=1859775393):s<60?(e=r&i|o&(r|i),t=2400959708):(e=r^i^o,t=3395469782);const l=(n<<5|n>>>27)+e+a+t+(0|this.block[s]);a=o,o=i,i=r<<30|r>>>2,r=n,n=l}this.h0=this.h0+n|0,this.h1=this.h1+r|0,this.h2=this.h2+i|0,this.h3=this.h3+o|0,this.h4=this.h4+a|0,this.offset=0;for(let s=0;s<16;s++)this.block[s]=0};const x="normal",_="url";function k(e,t=x){let n;if(null===e||"undefined"===typeof e)return e;if(n="function"===typeof r.Buffer.from&&r.Buffer.from!==Uint8Array.from?r.Buffer.from(e):new r.Buffer(e),t===_){const e={"+":"-","/":"_"};return n.toString("base64").replace(/[+/]|=+$/g,t=>e[t]||"")}return n.toString("base64")}function C(e){return null===e||"undefined"===typeof e?e:"function"===typeof r.Buffer.from&&r.Buffer.from!==Uint8Array.from?r.Buffer.from(e,"base64"):new r.Buffer(e,"base64")}function A(e){return e?C(e.replace(/[-_]/g,e=>"-"===e?"+":"/")).toString():e}function T(e,t,n){return N("md5",e,t,n)}function R(e){const t=`${e}`.length;let n=3*t/4;return e.length>0&&"="===e[e.length-1]&&(n--,e.length>1&&"="===e[e.length-2]&&n--),n}function N(e,t,n,i){const o=P(e);n||(n="binary"),"buffer"===n&&(n=void 0),"string"===typeof t&&(t=new r.Buffer(t));const a=I(t);let s=r.Buffer.isBuffer(t);if("undefined"!==typeof ArrayBuffer&&t&&t.buffer instanceof ArrayBuffer&&(s=!0),i&&"object"===typeof t&&"function"===typeof t.on&&!s)t.on("data",e=>{o.update(e)}),t.on("error",e=>{i(e)}),t.on("end",()=>{i(null,o.digest(n))});else{if(!i||!a||s||"undefined"===typeof FileReader){"object"!==typeof t||s||(t=new r.Buffer(new Uint8Array(t)));const e=o.update(t).digest(n);return i&&i(null,e),e}{let e=0;const s=524288,l=new FileReader;l.onerror=function(){i(new Error("Failed to read data."))},l.onload=function(){const t=new r.Buffer(new Uint8Array(l.result));o.update(t),e+=t.length,l._continueReading()},l._continueReading=function(){if(e>=t.size)return void i(null,o.digest(n));let r=e+s;r>t.size&&(r=t.size),l.readAsArrayBuffer(a.call(t,e,r))},l._continueReading()}}}function P(e){if(e=e.toLowerCase(),"md5"===e)return new l;if("sha256"===e)return new y;if("sha1"===e)return new E;throw new Error(`Hash algorithm ${e} is not supported`)}function I(e){const t=e.slice||e.webkitSlice||e.mozSlice;return"function"===typeof t?t:null}},6198:function(e,t,n){"use strict";n.d(t,{Is:function(){return s},PE:function(){return o},jl:function(){return a}});var r=n(47008),i=n.n(r);async function o(e,t,r="text/plain;charset=utf-8"){const i=new Blob([t],{type:r}),o=(await n.e(60).then(n.t.bind(n,45060,23))).default;return o(i,e)}function a(e){const t=new(i());for(const n in e)t.file(n,e[n]);return t.generateAsync({type:"blob"}).then(e=>e)}function s(e,t="__downloadIframe"){let n=document.getElementById(t);n||(n=document.createElement("iframe"),n.style.display="none",n.id=t,document.body.appendChild(n)),n.src=e}},99726:function(e,t,n){"use strict";n.d(t,{As:function(){return u},D7:function(){return h},cQ:function(){return p},oV:function(){return l},rz:function(){return d}});var r=n(68851);function i(e,t,n){return(t=o(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function o(e){var t=a(e,"string");return"symbol"==typeof t?t:t+""}function a(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}const s="__doNotLogError";class l extends Error{constructor(e){super(e),this.name=l.NAME}}i(l,"NAME","ClusterNotFoundError");class c extends Error{constructor(e,t){super(e),this.url=t,this.name=c.NAME}}i(c,"NAME","RedirectToError");Error;function u(e){let t;if("string"===typeof e)t=e;else if(e&&"object"===typeof e)if(e.message){if(t=e.message,"string"===typeof t)try{const e=JSON.parse(t).data;if(e)return e}catch{}e.detail&&(t?t+=` (${e.detail})`:t=e.detail)}else e.detail?t=e.detail:e.url&&(t=`from ${e.url}`);return t||(t=JSON.stringify(e)),t}function d(e){if(e?.response?.data){const t=e.response.data;return t&&t.message?[t.message]:[e]}return e.status&&e.message?[e.message]:(0,r.cy)(e)?e:[e]}function h(e){return!(!e?.[s]&&!e?.doNotLog)}const p=e=>{let t;if(e.message||"string"===typeof e)t=e.message||e;else try{t=JSON.stringify(e,null,2)}catch(n){t=`[${e.constructor.name}]`}return{...e,message:t,statusCode:e.statusCode||e.status||e.response&&e.response.status||500}}},83416:function(e,t,n){"use strict";n.d(t,{Xg:function(){return c},de:function(){return a}});var r=n(35664),i=n(79401),o=n(68851);n(76978);function a(e){const t=e["getStoreNameByProductId"],n=e[`${t}/all`](r.yx),a=(0,o.jq)(n,"id",(0,i.AZ)(r.Rp.PODMONITOR));return!!a}const s="cattle-monitoring-system";async function l(e,t){if(!e.getters[`${t}/canList`](r.W8.APP))return null;const n=[`${s}/rancher-monitoring-dashboards`,`${s}/rancher-monitoring`];for(const o of n)try{const n=await e.dispatch(`${t}/find`,{type:r.W8.APP,id:o});if(n)return n}catch(i){}return null}async function c(e,t){const n=await l(e,t);return n?.currentVersion||""}},18110:function(e,t,n){"use strict";n.d(t,{EF:function(){return i},Rc:function(){return c},T6:function(){return h},bE:function(){return u},os:function(){return a},pF:function(){return d},tA:function(){return s},tj:function(){return l},xs:function(){return o},yK:function(){return f}});const r="all",i="ns",o="project",a=`${i}://`,s=`${o}://`,l=r,c=`${r}://system`,u=`${r}://user`,d=`${r}://orphans`,h={DIVIDER:"divider",PROJECT:"project",NAMESPACE:"namespace",SPECIAL:"special"},p="__%%__",f=(e,t)=>`${e}${p}${t}`},76978:function(e,t,n){"use strict";n.d(t,{TJ:function(){return oe},no:function(){return re},MA:function(){return ie},nY:function(){return J},o8:function(){return Y},yo:function(){return se},BJ:function(){return X},Ui:function(){return te},cX:function(){return ae},Jt:function(){return K},Ib:function(){return z},Im:function(){return Z},n4:function(){return ne},TF:function(){return W},hZ:function(){return Q}});var r=n(9274),i=n(46108),o=n.n(i),a=n(53435),s=n.n(a),l=n(16238),c=n.n(l);class u{add(e,t,n){if("string"!=typeof arguments[0])for(let r in arguments[0])this.add(r,arguments[0][r],arguments[1]);else(Array.isArray(e)?e:[e]).forEach(function(e){this[e]=this[e]||[],t&&this[e][n?"unshift":"push"](t)},this)}run(e,t){this[e]=this[e]||[],this[e].forEach(function(e){e.call(t&&t.context?t.context:t,t)})}}class d{constructor(e){this.jsep=e,this.registered={}}register(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];t.forEach(e=>{if("object"!==typeof e||!e.name||!e.init)throw new Error("Invalid JSEP plugin format");this.registered[e.name]||(e.init(this.jsep),this.registered[e.name]=e)})}}class h{static get version(){return"1.4.0"}static toString(){return"JavaScript Expression Parser (JSEP) v"+h.version}static addUnaryOp(e){return h.max_unop_len=Math.max(e.length,h.max_unop_len),h.unary_ops[e]=1,h}static addBinaryOp(e,t,n){return h.max_binop_len=Math.max(e.length,h.max_binop_len),h.binary_ops[e]=t,n?h.right_associative.add(e):h.right_associative.delete(e),h}static addIdentifierChar(e){return h.additional_identifier_chars.add(e),h}static addLiteral(e,t){return h.literals[e]=t,h}static removeUnaryOp(e){return delete h.unary_ops[e],e.length===h.max_unop_len&&(h.max_unop_len=h.getMaxKeyLen(h.unary_ops)),h}static removeAllUnaryOps(){return h.unary_ops={},h.max_unop_len=0,h}static removeIdentifierChar(e){return h.additional_identifier_chars.delete(e),h}static removeBinaryOp(e){return delete h.binary_ops[e],e.length===h.max_binop_len&&(h.max_binop_len=h.getMaxKeyLen(h.binary_ops)),h.right_associative.delete(e),h}static removeAllBinaryOps(){return h.binary_ops={},h.max_binop_len=0,h}static removeLiteral(e){return delete h.literals[e],h}static removeAllLiterals(){return h.literals={},h}get char(){return this.expr.charAt(this.index)}get code(){return this.expr.charCodeAt(this.index)}constructor(e){this.expr=e,this.index=0}static parse(e){return new h(e).parse()}static getMaxKeyLen(e){return Math.max(0,...Object.keys(e).map(e=>e.length))}static isDecimalDigit(e){return e>=48&&e<=57}static binaryPrecedence(e){return h.binary_ops[e]||0}static isIdentifierStart(e){return e>=65&&e<=90||e>=97&&e<=122||e>=128&&!h.binary_ops[String.fromCharCode(e)]||h.additional_identifier_chars.has(String.fromCharCode(e))}static isIdentifierPart(e){return h.isIdentifierStart(e)||h.isDecimalDigit(e)}throwError(e){const t=new Error(e+" at character "+this.index);throw t.index=this.index,t.description=e,t}runHook(e,t){if(h.hooks[e]){const n={context:this,node:t};return h.hooks.run(e,n),n.node}return t}searchHook(e){if(h.hooks[e]){const t={context:this};return h.hooks[e].find(function(e){return e.call(t.context,t),t.node}),t.node}}gobbleSpaces(){let e=this.code;while(e===h.SPACE_CODE||e===h.TAB_CODE||e===h.LF_CODE||e===h.CR_CODE)e=this.expr.charCodeAt(++this.index);this.runHook("gobble-spaces")}parse(){this.runHook("before-all");const e=this.gobbleExpressions(),t=1===e.length?e[0]:{type:h.COMPOUND,body:e};return this.runHook("after-all",t)}gobbleExpressions(e){let t,n,r=[];while(this.index<this.expr.length)if(t=this.code,t===h.SEMCOL_CODE||t===h.COMMA_CODE)this.index++;else if(n=this.gobbleExpression())r.push(n);else if(this.index<this.expr.length){if(t===e)break;this.throwError('Unexpected "'+this.char+'"')}return r}gobbleExpression(){const e=this.searchHook("gobble-expression")||this.gobbleBinaryExpression();return this.gobbleSpaces(),this.runHook("after-expression",e)}gobbleBinaryOp(){this.gobbleSpaces();let e=this.expr.substr(this.index,h.max_binop_len),t=e.length;while(t>0){if(h.binary_ops.hasOwnProperty(e)&&(!h.isIdentifierStart(this.code)||this.index+e.length<this.expr.length&&!h.isIdentifierPart(this.expr.charCodeAt(this.index+e.length))))return this.index+=t,e;e=e.substr(0,--t)}return!1}gobbleBinaryExpression(){let e,t,n,r,i,o,a,s,l;if(o=this.gobbleToken(),!o)return o;if(t=this.gobbleBinaryOp(),!t)return o;i={value:t,prec:h.binaryPrecedence(t),right_a:h.right_associative.has(t)},a=this.gobbleToken(),a||this.throwError("Expected expression after "+t),r=[o,i,a];while(t=this.gobbleBinaryOp()){if(n=h.binaryPrecedence(t),0===n){this.index-=t.length;break}i={value:t,prec:n,right_a:h.right_associative.has(t)},l=t;const s=e=>i.right_a&&e.right_a?n>e.prec:n<=e.prec;while(r.length>2&&s(r[r.length-2]))a=r.pop(),t=r.pop().value,o=r.pop(),e={type:h.BINARY_EXP,operator:t,left:o,right:a},r.push(e);e=this.gobbleToken(),e||this.throwError("Expected expression after "+l),r.push(i,e)}s=r.length-1,e=r[s];while(s>1)e={type:h.BINARY_EXP,operator:r[s-1].value,left:r[s-2],right:e},s-=2;return e}gobbleToken(){let e,t,n,r;if(this.gobbleSpaces(),r=this.searchHook("gobble-token"),r)return this.runHook("after-token",r);if(e=this.code,h.isDecimalDigit(e)||e===h.PERIOD_CODE)return this.gobbleNumericLiteral();if(e===h.SQUOTE_CODE||e===h.DQUOTE_CODE)r=this.gobbleStringLiteral();else if(e===h.OBRACK_CODE)r=this.gobbleArray();else{t=this.expr.substr(this.index,h.max_unop_len),n=t.length;while(n>0){if(h.unary_ops.hasOwnProperty(t)&&(!h.isIdentifierStart(this.code)||this.index+t.length<this.expr.length&&!h.isIdentifierPart(this.expr.charCodeAt(this.index+t.length)))){this.index+=n;const e=this.gobbleToken();return e||this.throwError("missing unaryOp argument"),this.runHook("after-token",{type:h.UNARY_EXP,operator:t,argument:e,prefix:!0})}t=t.substr(0,--n)}h.isIdentifierStart(e)?(r=this.gobbleIdentifier(),h.literals.hasOwnProperty(r.name)?r={type:h.LITERAL,value:h.literals[r.name],raw:r.name}:r.name===h.this_str&&(r={type:h.THIS_EXP})):e===h.OPAREN_CODE&&(r=this.gobbleGroup())}return r?(r=this.gobbleTokenProperty(r),this.runHook("after-token",r)):this.runHook("after-token",!1)}gobbleTokenProperty(e){this.gobbleSpaces();let t=this.code;while(t===h.PERIOD_CODE||t===h.OBRACK_CODE||t===h.OPAREN_CODE||t===h.QUMARK_CODE){let n;if(t===h.QUMARK_CODE){if(this.expr.charCodeAt(this.index+1)!==h.PERIOD_CODE)break;n=!0,this.index+=2,this.gobbleSpaces(),t=this.code}this.index++,t===h.OBRACK_CODE?(e={type:h.MEMBER_EXP,computed:!0,object:e,property:this.gobbleExpression()},e.property||this.throwError('Unexpected "'+this.char+'"'),this.gobbleSpaces(),t=this.code,t!==h.CBRACK_CODE&&this.throwError("Unclosed ["),this.index++):t===h.OPAREN_CODE?e={type:h.CALL_EXP,arguments:this.gobbleArguments(h.CPAREN_CODE),callee:e}:(t===h.PERIOD_CODE||n)&&(n&&this.index--,this.gobbleSpaces(),e={type:h.MEMBER_EXP,computed:!1,object:e,property:this.gobbleIdentifier()}),n&&(e.optional=!0),this.gobbleSpaces(),t=this.code}return e}gobbleNumericLiteral(){let e,t,n="";while(h.isDecimalDigit(this.code))n+=this.expr.charAt(this.index++);if(this.code===h.PERIOD_CODE){n+=this.expr.charAt(this.index++);while(h.isDecimalDigit(this.code))n+=this.expr.charAt(this.index++)}if(e=this.char,"e"===e||"E"===e){n+=this.expr.charAt(this.index++),e=this.char,"+"!==e&&"-"!==e||(n+=this.expr.charAt(this.index++));while(h.isDecimalDigit(this.code))n+=this.expr.charAt(this.index++);h.isDecimalDigit(this.expr.charCodeAt(this.index-1))||this.throwError("Expected exponent ("+n+this.char+")")}return t=this.code,h.isIdentifierStart(t)?this.throwError("Variable names cannot start with a number ("+n+this.char+")"):(t===h.PERIOD_CODE||1===n.length&&n.charCodeAt(0)===h.PERIOD_CODE)&&this.throwError("Unexpected period"),{type:h.LITERAL,value:parseFloat(n),raw:n}}gobbleStringLiteral(){let e="";const t=this.index,n=this.expr.charAt(this.index++);let r=!1;while(this.index<this.expr.length){let t=this.expr.charAt(this.index++);if(t===n){r=!0;break}if("\\"===t)switch(t=this.expr.charAt(this.index++),t){case"n":e+="\n";break;case"r":e+="\r";break;case"t":e+="\t";break;case"b":e+="\b";break;case"f":e+="\f";break;case"v":e+="\v";break;default:e+=t}else e+=t}return r||this.throwError('Unclosed quote after "'+e+'"'),{type:h.LITERAL,value:e,raw:this.expr.substring(t,this.index)}}gobbleIdentifier(){let e=this.code,t=this.index;h.isIdentifierStart(e)?this.index++:this.throwError("Unexpected "+this.char);while(this.index<this.expr.length){if(e=this.code,!h.isIdentifierPart(e))break;this.index++}return{type:h.IDENTIFIER,name:this.expr.slice(t,this.index)}}gobbleArguments(e){const t=[];let n=!1,r=0;while(this.index<this.expr.length){this.gobbleSpaces();let i=this.code;if(i===e){n=!0,this.index++,e===h.CPAREN_CODE&&r&&r>=t.length&&this.throwError("Unexpected token "+String.fromCharCode(e));break}if(i===h.COMMA_CODE){if(this.index++,r++,r!==t.length)if(e===h.CPAREN_CODE)this.throwError("Unexpected token ,");else if(e===h.CBRACK_CODE)for(let e=t.length;e<r;e++)t.push(null)}else if(t.length!==r&&0!==r)this.throwError("Expected comma");else{const e=this.gobbleExpression();e&&e.type!==h.COMPOUND||this.throwError("Expected comma"),t.push(e)}}return n||this.throwError("Expected "+String.fromCharCode(e)),t}gobbleGroup(){this.index++;let e=this.gobbleExpressions(h.CPAREN_CODE);if(this.code===h.CPAREN_CODE)return this.index++,1===e.length?e[0]:!!e.length&&{type:h.SEQUENCE_EXP,expressions:e};this.throwError("Unclosed (")}gobbleArray(){return this.index++,{type:h.ARRAY_EXP,elements:this.gobbleArguments(h.CBRACK_CODE)}}}const p=new u;Object.assign(h,{hooks:p,plugins:new d(h),COMPOUND:"Compound",SEQUENCE_EXP:"SequenceExpression",IDENTIFIER:"Identifier",MEMBER_EXP:"MemberExpression",LITERAL:"Literal",THIS_EXP:"ThisExpression",CALL_EXP:"CallExpression",UNARY_EXP:"UnaryExpression",BINARY_EXP:"BinaryExpression",ARRAY_EXP:"ArrayExpression",TAB_CODE:9,LF_CODE:10,CR_CODE:13,SPACE_CODE:32,PERIOD_CODE:46,COMMA_CODE:44,SQUOTE_CODE:39,DQUOTE_CODE:34,OPAREN_CODE:40,CPAREN_CODE:41,OBRACK_CODE:91,CBRACK_CODE:93,QUMARK_CODE:63,SEMCOL_CODE:59,COLON_CODE:58,unary_ops:{"-":1,"!":1,"~":1,"+":1},binary_ops:{"||":1,"??":1,"&&":2,"|":3,"^":4,"&":5,"==":6,"!=":6,"===":6,"!==":6,"<":7,">":7,"<=":7,">=":7,"<<":8,">>":8,">>>":8,"+":9,"-":9,"*":10,"/":10,"%":10,"**":11},right_associative:new Set(["**"]),additional_identifier_chars:new Set(["$","_"]),literals:{true:!0,false:!1,null:null},this_str:"this"}),h.max_unop_len=h.getMaxKeyLen(h.unary_ops),h.max_binop_len=h.getMaxKeyLen(h.binary_ops);const f=e=>new h(e).parse(),m=Object.getOwnPropertyNames(class{});Object.getOwnPropertyNames(h).filter(e=>!m.includes(e)&&void 0===f[e]).forEach(e=>{f[e]=h[e]}),f.Jsep=h;const g="ConditionalExpression";var v={name:"ternary",init(e){e.hooks.add("after-expression",function(t){if(t.node&&this.code===e.QUMARK_CODE){this.index++;const n=t.node,r=this.gobbleExpression();if(r||this.throwError("Expected expression"),this.gobbleSpaces(),this.code===e.COLON_CODE){this.index++;const i=this.gobbleExpression();if(i||this.throwError("Expected expression"),t.node={type:g,test:n,consequent:r,alternate:i},n.operator&&e.binary_ops[n.operator]<=.9){let r=n;while(r.right.operator&&e.binary_ops[r.right.operator]<=.9)r=r.right;t.node.test=r.right,r.right=t.node,t.node=n}}else this.throwError("Expected :")}})}};f.plugins.register(v);const b=47,y=92;var w={name:"regex",init(e){e.hooks.add("gobble-token",function(t){if(this.code===b){const r=++this.index;let i=!1;while(this.index<this.expr.length){if(this.code===b&&!i){const i=this.expr.slice(r,this.index);let o,a="";while(++this.index<this.expr.length){const e=this.code;if(!(e>=97&&e<=122||e>=65&&e<=90||e>=48&&e<=57))break;a+=this.char}try{o=new RegExp(i,a)}catch(n){this.throwError(n.message)}return t.node={type:e.LITERAL,value:o,raw:this.expr.slice(r-1,this.index)},t.node=this.gobbleTokenProperty(t.node),t.node}this.code===e.OBRACK_CODE?i=!0:i&&this.code===e.CBRACK_CODE&&(i=!1),this.index+=this.code===y?2:1}this.throwError("Unclosed Regex")}})}};const O=43,S=45,E={name:"assignment",assignmentOperators:new Set(["=","*=","**=","/=","%=","+=","-=","<<=",">>=",">>>=","&=","^=","|=","||=","&&=","??="]),updateOperators:[O,S],assignmentPrecedence:.9,init(e){const t=[e.IDENTIFIER,e.MEMBER_EXP];function n(e){E.assignmentOperators.has(e.operator)?(e.type="AssignmentExpression",n(e.left),n(e.right)):e.operator||Object.values(e).forEach(e=>{e&&"object"===typeof e&&n(e)})}E.assignmentOperators.forEach(t=>e.addBinaryOp(t,E.assignmentPrecedence,!0)),e.hooks.add("gobble-token",function(e){const n=this.code;E.updateOperators.some(e=>e===n&&e===this.expr.charCodeAt(this.index+1))&&(this.index+=2,e.node={type:"UpdateExpression",operator:n===O?"++":"--",argument:this.gobbleTokenProperty(this.gobbleIdentifier()),prefix:!0},e.node.argument&&t.includes(e.node.argument.type)||this.throwError(`Unexpected ${e.node.operator}`))}),e.hooks.add("after-token",function(e){if(e.node){const n=this.code;E.updateOperators.some(e=>e===n&&e===this.expr.charCodeAt(this.index+1))&&(t.includes(e.node.type)||this.throwError(`Unexpected ${e.node.operator}`),this.index+=2,e.node={type:"UpdateExpression",operator:n===O?"++":"--",argument:e.node,prefix:!1})}}),e.hooks.add("after-expression",function(e){e.node&&n(e.node)})}};f.plugins.register(w,E),f.addUnaryOp("typeof"),f.addLiteral("null",null),f.addLiteral("undefined",void 0);const x=new Set(["constructor","__proto__","__defineGetter__","__defineSetter__"]),_={evalAst(e,t){switch(e.type){case"BinaryExpression":case"LogicalExpression":return _.evalBinaryExpression(e,t);case"Compound":return _.evalCompound(e,t);case"ConditionalExpression":return _.evalConditionalExpression(e,t);case"Identifier":return _.evalIdentifier(e,t);case"Literal":return _.evalLiteral(e,t);case"MemberExpression":return _.evalMemberExpression(e,t);case"UnaryExpression":return _.evalUnaryExpression(e,t);case"ArrayExpression":return _.evalArrayExpression(e,t);case"CallExpression":return _.evalCallExpression(e,t);case"AssignmentExpression":return _.evalAssignmentExpression(e,t);default:throw SyntaxError("Unexpected expression",e)}},evalBinaryExpression(e,t){const n={"||":(e,t)=>e||t(),"&&":(e,t)=>e&&t(),"|":(e,t)=>e|t(),"^":(e,t)=>e^t(),"&":(e,t)=>e&t(),"==":(e,t)=>e==t(),"!=":(e,t)=>e!=t(),"===":(e,t)=>e===t(),"!==":(e,t)=>e!==t(),"<":(e,t)=>e<t(),">":(e,t)=>e>t(),"<=":(e,t)=>e<=t(),">=":(e,t)=>e>=t(),"<<":(e,t)=>e<<t(),">>":(e,t)=>e>>t(),">>>":(e,t)=>e>>>t(),"+":(e,t)=>e+t(),"-":(e,t)=>e-t(),"*":(e,t)=>e*t(),"/":(e,t)=>e/t(),"%":(e,t)=>e%t()}[e.operator](_.evalAst(e.left,t),()=>_.evalAst(e.right,t));return n},evalCompound(e,t){let n;for(let r=0;r<e.body.length;r++){"Identifier"===e.body[r].type&&["var","let","const"].includes(e.body[r].name)&&e.body[r+1]&&"AssignmentExpression"===e.body[r+1].type&&(r+=1);const i=e.body[r];n=_.evalAst(i,t)}return n},evalConditionalExpression(e,t){return _.evalAst(e.test,t)?_.evalAst(e.consequent,t):_.evalAst(e.alternate,t)},evalIdentifier(e,t){if(Object.hasOwn(t,e.name))return t[e.name];throw ReferenceError(`${e.name} is not defined`)},evalLiteral(e){return e.value},evalMemberExpression(e,t){const n=String(e.computed?_.evalAst(e.property):e.property.name),r=_.evalAst(e.object,t);if(void 0===r||null===r)throw TypeError(`Cannot read properties of ${r} (reading '${n}')`);if(!Object.hasOwn(r,n)&&x.has(n))throw TypeError(`Cannot read properties of ${r} (reading '${n}')`);const i=r[n];return"function"===typeof i?i.bind(r):i},evalUnaryExpression(e,t){const n={"-":e=>-_.evalAst(e,t),"!":e=>!_.evalAst(e,t),"~":e=>~_.evalAst(e,t),"+":e=>+_.evalAst(e,t),typeof:e=>typeof _.evalAst(e,t)}[e.operator](e.argument);return n},evalArrayExpression(e,t){return e.elements.map(e=>_.evalAst(e,t))},evalCallExpression(e,t){const n=e.arguments.map(e=>_.evalAst(e,t)),r=_.evalAst(e.callee,t);return r(...n)},evalAssignmentExpression(e,t){if("Identifier"!==e.left.type)throw SyntaxError("Invalid left-hand side in assignment");const n=e.left.name,r=_.evalAst(e.right,t);return t[n]=r,t[n]}};class k{constructor(e){this.code=e,this.ast=f(this.code)}runInNewContext(e){const t=Object.assign(Object.create(null),e);return _.evalAst(this.ast,t)}}function C(e,t){return e=e.slice(),e.push(t),e}function A(e,t){return t=t.slice(),t.unshift(e),t}class T extends Error{constructor(e){super('JSONPath should not be called with "new" (it prevents return of (unwrapped) scalar values)'),this.avoidNew=!0,this.value=e,this.name="NewError"}}function R(e,t,n,r,i){if(!(this instanceof R))try{return new R(e,t,n,r,i)}catch(a){if(!a.avoidNew)throw a;return a.value}"string"===typeof e&&(i=r,r=n,n=t,t=e,e=null);const o=e&&"object"===typeof e;if(e=e||{},this.json=e.json||n,this.path=e.path||t,this.resultType=e.resultType||"value",this.flatten=e.flatten||!1,this.wrap=!Object.hasOwn(e,"wrap")||e.wrap,this.sandbox=e.sandbox||{},this.eval=void 0===e.eval?"safe":e.eval,this.ignoreEvalErrors="undefined"!==typeof e.ignoreEvalErrors&&e.ignoreEvalErrors,this.parent=e.parent||null,this.parentProperty=e.parentProperty||null,this.callback=e.callback||r||null,this.otherTypeCallback=e.otherTypeCallback||i||function(){throw new TypeError("You must supply an otherTypeCallback callback option with the @other() operator.")},!1!==e.autostart){const r={path:o?e.path:t};o?"json"in e&&(r.json=e.json):r.json=n;const i=this.evaluate(r);if(!i||"object"!==typeof i)throw new T(i);return i}}R.prototype.evaluate=function(e,t,n,r){let i=this.parent,o=this.parentProperty,{flatten:a,wrap:s}=this;if(this.currResultType=this.resultType,this.currEval=this.eval,this.currSandbox=this.sandbox,n=n||this.callback,this.currOtherTypeCallback=r||this.otherTypeCallback,t=t||this.json,e=e||this.path,e&&"object"===typeof e&&!Array.isArray(e)){if(!e.path&&""!==e.path)throw new TypeError('You must supply a "path" property when providing an object argument to JSONPath.evaluate().');if(!Object.hasOwn(e,"json"))throw new TypeError('You must supply a "json" property when providing an object argument to JSONPath.evaluate().');({json:t}=e),a=Object.hasOwn(e,"flatten")?e.flatten:a,this.currResultType=Object.hasOwn(e,"resultType")?e.resultType:this.currResultType,this.currSandbox=Object.hasOwn(e,"sandbox")?e.sandbox:this.currSandbox,s=Object.hasOwn(e,"wrap")?e.wrap:s,this.currEval=Object.hasOwn(e,"eval")?e.eval:this.currEval,n=Object.hasOwn(e,"callback")?e.callback:n,this.currOtherTypeCallback=Object.hasOwn(e,"otherTypeCallback")?e.otherTypeCallback:this.currOtherTypeCallback,i=Object.hasOwn(e,"parent")?e.parent:i,o=Object.hasOwn(e,"parentProperty")?e.parentProperty:o,e=e.path}if(i=i||null,o=o||null,Array.isArray(e)&&(e=R.toPathString(e)),!e&&""!==e||!t)return;const l=R.toPathArray(e);"$"===l[0]&&l.length>1&&l.shift(),this._hasParentSelector=null;const c=this._trace(l,t,["$"],i,o,n).filter(function(e){return e&&!e.isParentSelector});return c.length?s||1!==c.length||c[0].hasArrExpr?c.reduce((e,t)=>{const n=this._getPreferredOutput(t);return a&&Array.isArray(n)?e=e.concat(n):e.push(n),e},[]):this._getPreferredOutput(c[0]):s?[]:void 0},R.prototype._getPreferredOutput=function(e){const t=this.currResultType;switch(t){case"all":{const t=Array.isArray(e.path)?e.path:R.toPathArray(e.path);return e.pointer=R.toPointer(t),e.path="string"===typeof e.path?e.path:R.toPathString(e.path),e}case"value":case"parent":case"parentProperty":return e[t];case"path":return R.toPathString(e[t]);case"pointer":return R.toPointer(e.path);default:throw new TypeError("Unknown result type")}},R.prototype._handleCallback=function(e,t,n){if(t){const r=this._getPreferredOutput(e);e.path="string"===typeof e.path?e.path:R.toPathString(e.path),t(r,n,e)}},R.prototype._trace=function(e,t,n,r,i,o,a,s){let l;if(!e.length)return l={path:n,value:t,parent:r,parentProperty:i,hasArrExpr:a},this._handleCallback(l,o,"value"),l;const c=e[0],u=e.slice(1),d=[];function h(e){Array.isArray(e)?e.forEach(e=>{d.push(e)}):d.push(e)}if(("string"!==typeof c||s)&&t&&Object.hasOwn(t,c))h(this._trace(u,t[c],C(n,c),t,c,o,a));else if("*"===c)this._walk(t,e=>{h(this._trace(u,t[e],C(n,e),t,e,o,!0,!0))});else if(".."===c)h(this._trace(u,t,n,r,i,o,a)),this._walk(t,r=>{"object"===typeof t[r]&&h(this._trace(e.slice(),t[r],C(n,r),t,r,o,!0))});else{if("^"===c)return this._hasParentSelector=!0,{path:n.slice(0,-1),expr:u,isParentSelector:!0};if("~"===c)return l={path:C(n,c),value:i,parent:r,parentProperty:null},this._handleCallback(l,o,"property"),l;if("$"===c)h(this._trace(u,t,n,null,null,o,a));else if(/^(-?\d*):(-?\d*):?(\d*)$/u.test(c))h(this._slice(c,u,t,n,r,i,o));else if(0===c.indexOf("?(")){if(!1===this.currEval)throw new Error("Eval [?(expr)] prevented in JSONPath expression.");const e=c.replace(/^\?\((.*?)\)$/u,"$1"),a=/@.?([^?]*)[['](\??\(.*?\))(?!.\)\])[\]']/gu.exec(e);a?this._walk(t,e=>{const s=[a[2]],l=a[1]?t[e][a[1]]:t[e],c=this._trace(s,l,n,r,i,o,!0);c.length>0&&h(this._trace(u,t[e],C(n,e),t,e,o,!0))}):this._walk(t,a=>{this._eval(e,t[a],a,n,r,i)&&h(this._trace(u,t[a],C(n,a),t,a,o,!0))})}else if("("===c[0]){if(!1===this.currEval)throw new Error("Eval [(expr)] prevented in JSONPath expression.");h(this._trace(A(this._eval(c,t,n.at(-1),n.slice(0,-1),r,i),u),t,n,r,i,o,a))}else if("@"===c[0]){let e=!1;const a=c.slice(1,-2);switch(a){case"scalar":t&&["object","function"].includes(typeof t)||(e=!0);break;case"boolean":case"string":case"undefined":case"function":typeof t===a&&(e=!0);break;case"integer":!Number.isFinite(t)||t%1||(e=!0);break;case"number":Number.isFinite(t)&&(e=!0);break;case"nonFinite":"number"!==typeof t||Number.isFinite(t)||(e=!0);break;case"object":t&&typeof t===a&&(e=!0);break;case"array":Array.isArray(t)&&(e=!0);break;case"other":e=this.currOtherTypeCallback(t,n,r,i);break;case"null":null===t&&(e=!0);break;default:throw new TypeError("Unknown value type "+a)}if(e)return l={path:n,value:t,parent:r,parentProperty:i},this._handleCallback(l,o,"value"),l}else if("`"===c[0]&&t&&Object.hasOwn(t,c.slice(1))){const e=c.slice(1);h(this._trace(u,t[e],C(n,e),t,e,o,a,!0))}else if(c.includes(",")){const e=c.split(",");for(const a of e)h(this._trace(A(a,u),t,n,r,i,o,!0))}else!s&&t&&Object.hasOwn(t,c)&&h(this._trace(u,t[c],C(n,c),t,c,o,a,!0))}if(this._hasParentSelector)for(let p=0;p<d.length;p++){const e=d[p];if(e&&e.isParentSelector){const n=this._trace(e.expr,t,e.path,r,i,o,a);if(Array.isArray(n)){d[p]=n[0];const e=n.length;for(let t=1;t<e;t++)p++,d.splice(p,0,n[t])}else d[p]=n}}return d},R.prototype._walk=function(e,t){if(Array.isArray(e)){const n=e.length;for(let e=0;e<n;e++)t(e)}else e&&"object"===typeof e&&Object.keys(e).forEach(e=>{t(e)})},R.prototype._slice=function(e,t,n,r,i,o,a){if(!Array.isArray(n))return;const s=n.length,l=e.split(":"),c=l[2]&&Number.parseInt(l[2])||1;let u=l[0]&&Number.parseInt(l[0])||0,d=l[1]&&Number.parseInt(l[1])||s;u=u<0?Math.max(0,u+s):Math.min(s,u),d=d<0?Math.max(0,d+s):Math.min(s,d);const h=[];for(let p=u;p<d;p+=c){const e=this._trace(A(p,t),n,r,i,o,a,!0);e.forEach(e=>{h.push(e)})}return h},R.prototype._eval=function(e,t,n,r,i,o){this.currSandbox._$_parentProperty=o,this.currSandbox._$_parent=i,this.currSandbox._$_property=n,this.currSandbox._$_root=this.json,this.currSandbox._$_v=t;const a=e.includes("@path");a&&(this.currSandbox._$_path=R.toPathString(r.concat([n])));const s=this.currEval+"Script:"+e;if(!R.cache[s]){let t=e.replaceAll("@parentProperty","_$_parentProperty").replaceAll("@parent","_$_parent").replaceAll("@property","_$_property").replaceAll("@root","_$_root").replaceAll(/@([.\s)[])/gu,"_$_v$1");if(a&&(t=t.replaceAll("@path","_$_path")),"safe"===this.currEval||!0===this.currEval||void 0===this.currEval)R.cache[s]=new this.safeVm.Script(t);else if("native"===this.currEval)R.cache[s]=new this.vm.Script(t);else if("function"===typeof this.currEval&&this.currEval.prototype&&Object.hasOwn(this.currEval.prototype,"runInNewContext")){const e=this.currEval;R.cache[s]=new e(t)}else{if("function"!==typeof this.currEval)throw new TypeError(`Unknown "eval" property "${this.currEval}"`);R.cache[s]={runInNewContext:e=>this.currEval(t,e)}}}try{return R.cache[s].runInNewContext(this.currSandbox)}catch(l){if(this.ignoreEvalErrors)return!1;throw new Error("jsonPath: "+l.message+": "+e)}},R.cache={},R.toPathString=function(e){const t=e,n=t.length;let r="$";for(let i=1;i<n;i++)/^(~|\^|@.*?\(\))$/u.test(t[i])||(r+=/^[0-9*]+$/u.test(t[i])?"["+t[i]+"]":"['"+t[i]+"']");return r},R.toPointer=function(e){const t=e,n=t.length;let r="";for(let i=1;i<n;i++)/^(~|\^|@.*?\(\))$/u.test(t[i])||(r+="/"+t[i].toString().replaceAll("~","~0").replaceAll("/","~1"));return r},R.toPathArray=function(e){const{cache:t}=R;if(t[e])return t[e].concat();const n=[],r=e.replaceAll(/@(?:null|boolean|number|string|integer|undefined|nonFinite|scalar|array|object|function|other)\(\)/gu,";$&;").replaceAll(/[['](\??\(.*?\))[\]'](?!.\])/gu,function(e,t){return"[#"+(n.push(t)-1)+"]"}).replaceAll(/\[['"]([^'\]]*)['"]\]/gu,function(e,t){return"['"+t.replaceAll(".","%@%").replaceAll("~","%%@@%%")+"']"}).replaceAll("~",";~;").replaceAll(/['"]?\.['"]?(?![^[]*\])|\[['"]?/gu,";").replaceAll("%@%",".").replaceAll("%%@@%%","~").replaceAll(/(?:;)?(\^+)(?:;)?/gu,function(e,t){return";"+t.split("").join(";")+";"}).replaceAll(/;;;|;;/gu,";..;").replaceAll(/;$|'?\]|'$/gu,""),i=r.split(";").map(function(e){const t=e.match(/#(\d+)/u);return t&&t[1]?n[t[1]]:e});return t[e]=i,t[e].concat()},R.prototype.safeVm={Script:k};const N=function(e,t,n){const r=e.length;for(let i=0;i<r;i++){const r=e[i];n(r)&&t.push(e.splice(i--,1)[0])}};class P{constructor(e){this.code=e}runInNewContext(e){let t=this.code;const n=Object.keys(e),r=[];N(n,r,t=>"function"===typeof e[t]);const i=n.map(t=>e[t]),o=r.reduce((t,n)=>{let r=e[n].toString();return/function/u.test(r)||(r="function "+r),"var "+n+"="+r+";"+t},"");t=o+t,/(['"])use strict\1/u.test(t)||n.includes("arguments")||(t="var arguments = undefined;"+t),t=t.replace(/;\s*$/u,"");const a=t.lastIndexOf(";"),s=-1!==a?t.slice(0,a+1)+" return "+t.slice(a+1):" return "+t;return new Function(...n,s)(...i)}}R.prototype.vm={Script:P};var I=n(2011),M=n.n(I),D=n(41580),L=n.n(D),B=n(53142),$=n.n(B),V=n(46343),F=n.n(V),j=n(88088),U=n.n(j),G=(n(48875),n(92043)),H=n(68851),q=n(4364);function Q(e,t,n){let r=e;if(!r)return;const i=(0,G.jg)(t);for(let o=0;o<i.length;o++){const e=i[o];o===i.length-1?r[e]=n:r[e]||(r[e]={}),r=r[e]}return e}function z(e,t){const n=t.split(".");let r=[e];return n.forEach(e=>{r=r.map(t=>Array.isArray(t)?t.map(t=>t[e]).flat():t?t[e]:null).flat()}),r.filter(e=>null!==e)}function K(e,t){if(!t)throw new Error("Cannot translate an empty input. The t function requires a string.");if(t.startsWith("$"))try{return R({path:t,json:e,wrap:!1})}catch(r){return q.log("JSON Path error",r,t,e),"(JSON Path err)"}if(!t.includes("."))return e?.[t];const n=(0,G.jg)(t);for(let i=0;i<n.length;i++){if(!e)return;e=e[n[i]]}return e}function W(e,t,n=!1){const r=(0,G.jg)(t);if(1===r.length)e[t]=void 0,delete e[t];else{const t=r.pop(),i=K(e,(0,G.ZM)(r));if(i&&(i[t]=void 0,delete i[t],n))while(r.length){const t=r.pop(),n=r.length?K(e,(0,G.ZM)(r)):e;if(!n||!Z(n[t]))break;delete n[t]}}return e}function X(e,t){const n=t.split("."),r=n.pop();delete n.reduce((e,t)=>e[t]||{},e)[r]}function Y(e){return o()(e)}function Z(e){return!e||!Object.keys(e).length}function J(e){return e&&"object"===typeof e?(Object.keys(e).map(t=>{const n=e[t];Array.isArray(n)?(e[t]=n.map(e=>{if(null!==e&&void 0!==e)return J(e)}),0===e[t].length&&delete e[t]):"undefined"===typeof n||null===n?delete e[t]:L()(n)&&(Z(n)&&delete e[t],e[t]=J(n))}),e):e}function ee(e){const t=Object.keys(e).map(t=>{const n=e[t];return Array.isArray(n)?`"${t}"`:L()(n)?(ee(n)||[]).map(e=>`"${t}".${e}`):`"${t}"`});return c()(s()(t))}function te(e,t,n=!1){e=e||{},t=t||{};const r=M()(t,(t,r,i)=>{const o=e[i];if(!F()(r,o))if(Array.isArray(r)||Array.isArray(o))t[i]=r;else if(L()(r)&&L()(o)){const e=te(o,r,n);Z(r)&&!Z(o)?t[i]={}:Z(e)||(t[i]=e)}else t[i]=r}),i=ee(e),o=ee(t),a=U()(i,o);for(const s of a){const t=o.some(e=>e.startsWith(`${s}.`));if(t)continue;const i=(0,G.jg)(s);let a=!1;for(let e=1;e<i.length;e++){const t=(0,G.ZM)(i.slice(0,e));if(void 0!==K(r,t)){a=!0;break}}if(!a)if(n){let t=s;s.includes(".")||(t=s.replaceAll('"',"")),void 0!==e[t]&&null!==e[t]?Q(r,t,e[t]):Q(r,t,null)}else{const e=(0,G.jg)(s),t=e.some(e=>{const t=r?.[e];if(void 0!==t&&!L()(t))return!0});t||Q(r,s,null)}}return r}function ne(e,t){const n=Object.keys(e||{}),r=Object.keys(t||{});if(n.length!==r.length)return!1;for(let i=0;i<n.length;i++){const r=e[n[i]],o=t[n[i]];if(r!==o)return!1}return!0}function re(e,t,n=[]){let r={};if(F()(e,t))return r;for(const i in e){const o=(0,G.ZM)([...n,i]);i in t?L()(e[i])&&L()(t[i])||$()(e[i])&&$()(t[i])?r={...r,...re(e[i],t[i],[...n,i])}:F()(e[i],t[i])||(r[o]={op:"change",from:e[i],value:t[i]}):r[o]={op:"remove",path:o}}for(const i in t)if(!(i in e)){const e=(0,G.ZM)([...n,i]);r[e]={op:"add",value:t[i]}}return r}function ie(e,t){let n=Object.keys(e).sort();const r=[],i={};for(const a of n){let n=!0;const s=e[a],l=t[a];for(const e of o(a))if(i[e]){n=!1;break}if(i[a]=!0,n&&l)switch(`${s.op}-${l.op}`){case"add-add":case"add-change":case"change-add":case"change-change":n=F()(s.value,l.value);break;case"add-remove":case"change-remove":case"remove-add":case"remove-change":n=!1;break;case"remove-remove":default:n=!0;break}n||(0,H.PG)(r,a)}n=Object.keys(t).sort();for(const a of n){let e=!0;for(const t of o(a))if(i[t]){e=!1;break}i[a]=!0,e||(0,H.PG)(r,a)}return r.sort();function o(e){const t=[],n=(0,G.jg)(e);n.pop();while(n.length){const e=(0,G.ZM)(n);t.push(e),n.pop()}return t}}function oe(e,t){let n;for(const r in t)if(n=t[r],"add"===n.op||"change"===n.op)Q(e,r,n.value);else{if("remove"!==n.op)throw new Error(`Unknown operation:${n.op}`);W(e,r)}return e}function ae(e,t){if(e)for(const n of t)delete e[n]}function se(e,t=new WeakSet){if(null===e||"object"!==typeof e)return e;if(t.has(e))return e;if(t.add(e),Array.isArray(e))return e.map(e=>se(e,t));{const n=(0,r.toRaw)(e),i={};for(const e in n)"function"===typeof n[e]||"symbol"===typeof n[e]?i[e]=null:i[e]=se(n[e],t);return i}}},19463:function(e,t,n){"use strict";async function r(e,t,n,r,i,{notifyGeneratedName:o=!1}={}){const a=await e("management/create",{type:t,metadata:{namespace:r,generateName:`${i}-`},spec:{ttl:60,...n}},{root:!0}),s=await a.save();return o&&s.notifyGeneratedName(),s}n.d(t,{l:function(){return r}})},35881:function(e,t,n){"use strict";n.d(t,{A0:function(){return f},ZA:function(){return s},_Z:function(){return p},cX:function(){return o},hV:function(){return l},nN:function(){return d},nr:function(){return g},yC:function(){return h}});const r="undefined"===typeof window?"server":window.navigator.platform.toLowerCase(),i="undefined"===typeof window?"server":window.navigator.userAgent,o=(r.includes("linux")||r.includes("unix"),r.includes("mac")),a=(r.includes("win"),o?"metaKey":"ctrlKey"),s=o?"Command":"Control";function l(e){return e.join("-")}const c=a,u="shiftKey";function d(e){return!!e[a]}function h(e){return!!e[c]}function p(e){return!!e[u]}function f(e){return e.ctrlKey&&2===e.button}i.includes("Gecko/");const m=i.includes("Chrome/"),g=(!m&&i.includes("AppleWebKit/"),!m&&i.includes("Safari/"));/Android|webOS|iPhone|iPad|iPod|IEMobile/i.test(i)},14817:function(e,t,n){"use strict";n.d(t,{Q7:function(){return a},Q8:function(){return c},Tb:function(){return p}});const r="left",i="right",o="top",a="center",s="center",l="bottom",c="auto";function u(e){const t=e.getBoundingClientRect(),n=e.offsetWidth,r=e.offsetHeight;return{top:t.top,right:t.left+n,bottom:t.top+r,left:t.left,width:n,height:r}}function d(e){return{top:e.clientY,left:e.clientX,bottom:e.clientY,right:e.clientX,width:0,height:0}}function h(){const e=window.innerWidth,t=window.innerHeight,n=window.pageYOffset,r=window.pageXOffset;return{top:n,right:r+e,bottom:n+t,left:r,width:e,height:t}}function p(e,t,n,p){let{positionX:f=c,positionY:m=c}=n||{};const{fudgeX:g=0,fudgeY:v=0,overlapX:b=!0,overlapY:y=!1}=n||{},w=h();let O;O=t instanceof Event?d(t):u(t);let S={};e&&(S=u(e)),p&&(S={top:0,right:147,bottom:163,left:0,width:147,height:80});const E={position:"absolute"},x={left:b?O.left:O.right,center:(O.left+O.right)/2,right:b?O.right:O.left,top:y?O.bottom:O.top,middle:(O.top+O.bottom)/2,bottom:y?O.top:O.bottom},_={left:w.right-S.width-x.left,center:Math.min(w.right-S.width/2-x.center,x.center-S.width/2-w.left),right:x.right-S.width-w.left,top:x.bottom-S.height-w.top,middle:Math.min(x.middle-S.height/2-w.top,w.bottom-S.height/2-x.middle),bottom:w.bottom-S.height-x.top};switch(f===a&&_.center<0&&(f=c),f===c?f=_.left<0||1.5*_.right>_.left?i:r:m===r&&_.left<0?f=i:m===i&&_.right<0&&(f=r),f){case r:E.left=x.left-g+"px";break;case a:E.left=(x.left+x.right)/2-S.width/2-g+"px";break;case i:E.left=x.right+g-S.width+"px";break}switch(m===s&&_.middle<0&&(m=c),m===c?m=_.top<0||1.5*_.bottom>_.top?l:o:m===o&&_.top<0?m=l:m===l&&_.bottom<0&&(m=o),m){case o:E.top=x.top+v-S.height+"px";break;case a:E.top=(x.top+x.bottom)/2+v-S.height+"px";break;case l:E.top=x.bottom-v+"px";break}return E}},88339:function(e,t,n){"use strict";function r(){this.queue=[],this.offset=0,this.getLength=function(){return this.queue.length-this.offset},this.isEmpty=function(){return 0===this.queue.length},this.enqueue=function(e){this.queue.push(e)},this.dequeue=function(){if(0===this.queue.length)return;const e=this.queue[this.offset];return 2*++this.offset>=this.queue.length&&(this.queue=this.queue.slice(this.offset),this.offset=0),e},this.peek=function(){return this.queue.length>0?this.queue[this.offset]:void 0},this.clear=function(){this.offset=0,this.queue.length=0}}n.d(t,{kR:function(){return a},$t:function(){return s},yX:function(){return c},hF:function(){return l},DD:function(){return u}});var i=n(4364);async function o(e,t){const n=Object.keys(e),r=Object.values(e),i=await Promise[t](r),o={};for(let a=0;a<n.length;a++)o[n[a]]=i[a];return o}function a(e){return o(e,"all")}function s(e){return o(e,"allSettled")}function l(e,t,n,o=!1){return o&&i.log("eachLimit of",e.length," items",t,"at a time"),new Promise((a,s)=>{const l=new r;let c=0,u=!1;const d=[];for(let t=0;t<e.length;t++)l.enqueue({item:e[t],idx:t});function h(){if(o&&i.log(`process, queue=${l.getLength()}, pending=${c}, failed=${u}`),!u){if(l.isEmpty()&&0===c)return a(d);while(!l.isEmpty()&&c<t&&!u){const{item:e,idx:t}=l.dequeue();o&&i.log("Running",e),c++,n(e,t).then(n=>{o&&i.log("Done",e),d[t]=n,c--,h()}).catch(t=>{o&&i.log("Failed",t,e),u=!0,s(t)})}}}h()})}function c(e){const t={};return t.promise=new Promise((e,n)=>{t.resolve=e,t.reject=n},e),t}function u(e,t,n,r){e.then(e=>{t[n]=e}).catch(e=>{i.warn("Failed to: ",r,e)})}},37327:function(e,t,n){"use strict";n.d(t,{Q5:function(){return l},iF:function(){return o},P:function(){return i}});n(14220),n(4364);var r=n(4364);function i(e){let t=e.params?.product;if(!t){const n=e.name?.match(/^c-cluster-([^-]+)/);n&&(t=n[1])}return t||(t=a(e,"product")),t}const o=e=>{if(!e?.meta)return;const t=Array.isArray(e.meta)?e.meta:[e.meta];return t.find(e=>!!e.pkg)?.pkg};function a(e,t){if(e?.meta){const n=Array.isArray(e.meta)?e.meta:[e.meta];for(let e=0;e<n.length;e++)if(n[e][t])return n[e][t]}}function s(e,t){const n=e.getRoutes();return n.find(e=>e.name===t)}function l(e,t){if(!t||!t.name||!t.params)return r.warn("filterLocationValidParams received invalid arguments"),t;const n=s(e,t.name);if(!n)return r.warn("Could not find a route definition given the routeRecord",t),t;const i=t.params,o={};return Object.entries(i).forEach(([e,t])=>{const r=`:${e}`;n.path.includes(r)&&(o[e]=t)}),{...t,params:o}}},20162:function(e,t,n){"use strict";function r(e,t,n,r){const i=t.$parent.$el,o=i.getBoundingClientRect(),a=r||"bottom-start",s=document.body.offsetHeight,l=s-window.scrollY-o.y-1;let c;if(!a.includes("top")){c=o.y+o.height-1;const t=c+e.offsetHeight;t>window.innerHeight?c=void 0:c+=window.scrollY}c?(e.style.top=`${c}px`,e.classList.remove("vs__dropdown-up"),i.classList.remove("vs__dropdown-up")):(e.style.bottom=`${l}px`,e.classList.add("vs__dropdown-up"),i.classList.add("vs__dropdown-up")),e.style.left=`${o.x}px`,e.style.width="min-content",e.style.minWidth=`${o.width}px`}n.d(t,{s:function(){return r}})},38823:function(e,t,n){"use strict";n.d(t,{C6:function(){return c},CR:function(){return u},_R:function(){return l},cK:function(){return d},qg:function(){return s},wC:function(){return h}});var r=n(68851),i=n(76978);const o={},a={"=":"In","==":"In","!=":"NotIn","<":"Lt",">":"Gt"};function s(e){if(!e)return[];if(e=e.replace(/\+/g," "),o[e])return o[e];let t;const n=[],r=[];if(t=e.match(/\([^)]+\)/g),t&&t.length)for(const o of t){const t=o.replace(/^\s*\(\s*/,"").replace(/\s*\)\s*$/,"").split(/\s*,\s*/);r.push(t),e=e.replace(o,` @${r.length-1} `)}const i=e.split(/\s*,\s*/).filter(e=>!!e);for(let o of i)o=o.trim(),t=o.match(/^(.*?)\s+((not\s*)?in)\s+@(\d+)*$/i),t?n.push({key:t[1].trim(),operator:"notin"===t[2].toLowerCase().replace(/\s/g,"")?"NotIn":"In",values:r[t[4].trim()]}):(t=o.match(/^([^!=]*)\s*(\!=|=|==|>|<)\s*([^!=]*)$/),t?n.push({key:t[1].trim(),operator:a[t[2]],values:[t[3].trim()]}):o.startsWith("!")?n.push({key:o.substr(1).trim(),operator:"DoesNotExist"}):n.push({key:o.trim(),operator:"Exists"}));return o[e]=n,n}function l(e){return c(e.matchLabels||{},e.matchExpressions||[])}function c(e,t){const n=Object.keys(e||{}),i=t||[];for(const o of n){const t=e[o],n=(0,r.jq)(i,{key:o,operator:"In"});n?(0,r.PG)(n.values,t):i.push({key:o,operator:"In",values:(0,r.cy)(t)?t:[t]})}return i}function u(e){const t={},n=[],i=[],o={};for(const a of e)"In"===a.operator&&(o[a.key]?(0,r.PG)(i,a.key):o[a.key]=!0);for(const r of e)"In"!==r.operator||1!==r.values.length||i.includes(r.key)?n.push(Object.assign({},r)):t[r.key]=r.values[0];return{matchLabels:t,matchExpressions:n}}function d(e,t,n="metadata.labels"){let o=[];if("string"===typeof t)o=s(t);else if((0,r.cy)(t))o=t;else{if("object"!==typeof t||!t)return!1;o=c(t)}const a=(0,i.Jt)(e,n)||{};for(const r of o){const e=a[r.key],t=parseInt(e,10),n="undefined"!==typeof a[r.key];switch(r.operator){case"Exists":if(!n)return!1;break;case"DoesNotExist":if(n)return!1;break;case"In":if(!r.values.length||!r.values.includes(e))return!1;break;case"NotIn":if(r.values.includes(e))return!1;break;case"Lt":if(isNaN(t)||t>=Math.min.apply(null,r.values))return!1;break;case"Gt":if(isNaN(t)||t<=Math.max.apply(null,r.values))return!1;break}}return!0}function h(e,t,n){return e.filter(e=>d(e,t,n))}},74302:function(e,t,n){"use strict";n.d(t,{QP:function(){return s},RY:function(){return m},UD:function(){return u},Ul:function(){return h},cn:function(){return d}});var r=n(76978),i=n(92043);const o={"[object Boolean]":"boolean","[object Number]":"number","[object String]":"string","[object Function]":"function","[object Array]":"array","[object Date]":"date","[object RegExp]":"regexp","[object Object]":"object","[object FileList]":"filelist"},{toString:a}=Object.prototype;function s(e){if(null===e)return"null";if(void 0===e)return"undefined";let t=o[a.call(e)]||"object";return"object"===t&&(e instanceof Error?t="error":e instanceof Date&&(t="date")),t}function l(e,t){const n=e-t;return(n>0)-(n<0)}const c={undefined:0,null:1,boolean:2,number:3,string:4,array:5,object:6,instance:7,function:8,class:9,date:10};function u(e,t){const n=s(e),r=s(t),i=l(c[n],c[r]);if(i)return i;switch(n){case"boolean":case"number":return l(e,t);case"string":return l(e.localeCompare(t),0);case"array":{const n=e.length,r=t.length,i=Math.min(n,r);for(let o=0;o<i;o++){const n=u(e[o],t[o]);if(0!==n)return n}return l(n,r)}case"date":return l(e.getTime(),t.getTime())}return 0}function d(e){const t=e.split(/:/);return 2===t.length&&"desc"===t[1]?{field:t[0],reverse:!0}:{field:e,reverse:!1}}function h(e,t,n=!1){return Array.isArray(t)||(t=[t]),(e||[]).slice().sort((e,i)=>{for(let o=0;o<t.length;o++){const a=d(t[o]),s=(0,r.Jt)(e,a.field),l=(0,r.Jt)(i,a.field);let c=u(s,l);if(c)return n&&(c*=-1),a.reverse&&(c*=-1),c}return 0})}const p=/([^\d]+)/,f=/^[0-9]+$/;function m(e){return"string"!==typeof e?e:e.split(p).map(e=>e.match(f)?(0,i.DZ)(e,10,"0"):e).join("").trim()}},92043:function(e,t,n){"use strict";function r(e){return E(e||"").split("-").map(e=>i(e)).join(" ")}function i(e){return e=e||"",e.substr(0,1).toUpperCase()+e.substr(1)}function o(e,t,n=" ",r=!1){if(e=`${e}`,e.length>=t)return e;const i=t-e.length+1,o=new Array(i).join(n).substr(0,i);return r?e+o:o+e}n.d(t,{$f:function(){return c},DZ:function(){return o},HV:function(){return k},Kn:function(){return A},LQ:function(){return f},Nr:function(){return b},OF:function(){return C},TF:function(){return i},XC:function(){return x},ZD:function(){return s},ZM:function(){return N},_R:function(){return r},_k:function(){return E},aR:function(){return M},eH:function(){return I},i6:function(){return _},iT:function(){return l},jg:function(){return R},l9:function(){return g},pZ:function(){return y},qO:function(){return P},td:function(){return v},vx:function(){return m}});const a={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"};function s(e){return String(e).replace(/[&<>"']/g,e=>a[e])}function l(e){const t=document.createElement("div");return t.innerHTML=e,t.textContent||t.innerText||""}function c(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function u(e){e=Math.max(0,e||1);const t=[];let n;if(window.crypto&&window.crypto.getRandomValues){const r=new Uint32Array(e);for(window.crypto.getRandomValues(r),n=0;n<r.length;n++)t[n]=r[n]}else for(n=0;n<e;n++)t[n]=4294967296*Math.random();return 1===e?t[0]:t}const d="abcdefghijklmnopqrstuvwxyz",h="0123456789",p="!@#$%^&*()_+-=[]{};:,./<>?|",f={NUMERIC:h,NO_VOWELS:"bcdfghjklmnpqrstvwxz2456789",ALPHA:d+d.toUpperCase(),ALPHA_NUM:d+d.toUpperCase()+h,ALPHA_LOWER:d,ALPHA_UPPER:d.toUpperCase(),HEX:`${h}ABCDEF`,PASSWORD:d+d.toUpperCase()+h+d+d.toUpperCase()+h+p};function m(e=16,t=f.ALPHA_NUM){return t&&t.length?u(e).map(e=>t[e%t.length]).join(""):null}function g(e,t=2){return e<1&&t>=2?Math.round(100*e)/100+"%":e<10&&t>=1?Math.round(10*e)/10+"%":`${Math.round(e)}%`}function v(e){return e.match(/.*[^aeiou]y$/i)?`${e.substr(0,e.length-1)}ies`:e.endsWith("ics")?e:e.endsWith("s")?`${e}es`:`${e}s`}function b(e,t,n,r){const i=5;return t||(t=n("promptRemove.andOthers",{count:e.length>i?e.length-i:0})),r||(r=!1===r?" ":"."),e.reduce((o,a,l)=>(l<i&&(o+=`<b>${s(a)}</b>`,l===e.length-1?o+=r:l===e.length-2?o+=e.length<=5?n("generic.and"):"":o+=l<i-1?n("generic.comma"):""),l===i&&(o+=t),o),"")}function y(e,t=2,n=" ",r=null){e="string"===typeof e?e.split(/\n/):e||[];const i=new Array(t+1).join(n),o=e.map(e=>{let t="",n=e;if(r){const i=e.match(r);i&&(t=i[i.length-1],n=e.substr(i[0].length))}return`${t}${i}${n}`}),a=o.join("\n");return a}const w=/([a-z\d])([A-Z])/g;function O(e){return e.replace(w,"$1_$2").toLowerCase()}const S=/[ _]/g;function E(e){return O(e).replace(S,"-")}function x(e){return e=e||"",!e.match(/[^\r\n\t\x20-\x7F]/)}function _(e,t){return"float"===t?e=parseFloat(e)||null:"int"===t?(e=parseInt(e,10),isNaN(e)&&(e=null)):"boolean"===t&&("true"===e.toLowerCase()?e=!0:"false"===e.toLowerCase()&&(e=!1)),e}function k(e,t=[]){return t.some(t=>{const n=e||"",r=C(t);return n.match(r)})}function C(e,t=!0){return"string"===typeof e?t?new RegExp(`^${c(e)}$`,"i"):new RegExp(`${c(e)}`,"i"):e}function A(e){return s(e||"").replace(/(\r\n|\r|\n)/g,"<br/>\n")}const T=/[^."']+|"([^"]*)"|'([^']*)'/g;function R(e){return e.includes('"')||e.includes("'")?e.match(T).map(e=>e.replace(/['"]/g,"")):e.split(".")}function N(e){let t="";for(const n of e)n.includes(".")?t+=`."${n}"`:t+=`.${n}`;return t.startsWith(".")&&(t=t.substr(1)),t}function P(e){return(e||"").replace(/^(index\.)?docker.io\/(library\/)?/,"").replace(/:latest$/,"").replace(/^(.*@sha256:)([0-9a-f]{8})[0-9a-f]+$/i,"$1$2…")}function I(e){const t=/^((25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(25[0-5]|2[0-4]\d|[01]?\d\d?)$/;return t.test(e)}function M(e){return Array.from({length:e},()=>String.fromCharCode(97+26*Math.random()|0)).join("")}},95799:function(e,t,n){"use strict";n.d(t,{$W:function(){return a},Mo:function(){return o},QN:function(){return r},ao:function(){return s},kq:function(){return i}});const r=["","K","M","G","T","P","E","Z","Y"],i=["","m","u","n","p","f","a","z","y"];function o(e,{increment:t=1e3,addSuffix:n=!0,addSuffixSpace:s=!0,suffix:l="",firstSuffix:c=null,startingExponent:u=0,minExponent:d=0,maxExponent:h=99,maxPrecision:p=2,canRoundToZero:f=!0}={}){let m=e,g=u;const v=h>=0;if(v)while(m>=t&&g+1<r.length&&g<h||g<d)m/=t,g++;else while(m<t&&g+1<i.length&&g<-1*h||g<-1*d)m*=t,g++;let b="";if(b=m<10&&p>=1?""+Math.round(m*10**p)/10**p:`${Math.round(m)}`,"0"===b&&!f&&0!==e){const r=a(e,t);return o(e,{increment:t,addSuffix:n,suffix:l,firstSuffix:c,startingExponent:u,minExponent:r,maxExponent:r,maxPrecision:p,canRoundToZero:!0})}return n&&(s&&(b+=" "),b+=0===g&&null!==c?`${c}`:`${v?r[g]:i[g]}${l}`||""),b}function a(e,t=1e3){let n=0;while(e>=t)e/=t,n++;return n}function s(e,t){t=t||{};let n=t.increment;const o=!1!==t.allowFractional;if(!e||"string"!==typeof e||!e.length)return NaN;e=e.replace(/,/g,"");let[,a,s,l]=e.match(/^([0-9.-]+)\s*([^0-9.-]?)([^0-9.-]?)/);const c=parseFloat(a);if(!s)return c;181===s.charCodeAt(0)&&(s="u");const u=i.includes(s),d=r.includes(s.toUpperCase());if(n||(n=(d||u)&&"i"===l?1024:1e3),u&&o){const e=i.indexOf(s);return c/n**e}if(d){const e=r.indexOf(s.toUpperCase());return c*n**e}return c}},70500:function(e,t,n){"use strict";n.d(t,{M:function(){return a},u:function(){return o}});var r=n(37021),i=n.n(r);function o(e="",t,n){try{a.validation(e)}catch(r){n.push(t["i18n/t"](a.message))}}const a={validation:e=>i().toString(e,{verbose:!0}),message:"validation.invalidCron"}},96047:function(e,t,n){"use strict";n.d(t,{HK:function(){return u},p6:function(){return g},iK:function(){return h},um:function(){return f},OH:function(){return m},cO:function(){return p},xR:function(){return d}});var r=n(3514),i=n.n(r),o=n(82438),a=n.n(o),s=n(76978),l=n(92043);function c(e,t,n,r,i=[]){r=r||{};const{invalidChars:o,forHostname:a=!1,errorKey:s=(a?"hostname":"label"),maxLength:l=63,minLength:c=1,validChars:u="A-Za-z0-9-"}=r;h(e,{validChars:u,invalidChars:o},t,n,i),"-"===e.slice(0,1)&&i.push(n["i18n/t"](`validation.dns.${s}.startHyphen`,{key:t})),"-"===e.slice(-1)&&i.push(n["i18n/t"](`validation.dns.${s}.endHyphen`,{key:t}));const d=c,p=l;return e.length<d?i.push(n["i18n/t"](`validation.dns.${s}.emptyLabel`,{key:t,min:d})):e.length>p&&i.push(n["i18n/t"](`validation.dns.${s}.tooLongLabel`,{key:t,max:p})),i}function u(e,t,n){const r=`model.${e}.${t}`,i=`${r}.label`;return n["i18n/exists"](`${r}.label`)?n["i18n/t"](i):n["i18n/exists"](r)?n["i18n/t"](r):t.match(/.Id$/)?(0,l._R)(t.replace(/Id$/,"")):(0,l._R)(t)}function d(e,t,n,r,o=[]){const{nullable:a,required:l,type:c="",minLength:u,maxLength:d,min:h,max:p}=t,f=e?(0,s.Jt)(e,"length"):0;if(!a&&l&&("object"===typeof e&&i()(e)||!e&&0!==e))return o.push(r["i18n/t"]("validation.required",{key:n})),o;if(null===e)return o;const m=0===c.indexOf("array[")?"arrayLength":"stringLength";let g=u,v=d;return g&&v?(f<g||f>v)&&(g===v?o.push(r["i18n/t"](`validation.${m}.exactly`,{key:n,count:g})):o.push(r["i18n/t"](`validation.${m}.between`,{key:n,min:g,max:v}))):g&&f<g?o.push(r["i18n/t"](`validation.${m}.min`,{key:n,count:g})):v&&f>v&&o.push(r["i18n/t"](`validation.${m}.max`,{key:n,count:v})),g=h,v=p,null!==e&&g&&v?(e<g||e>v)&&(g===v?o.push(r["i18n/t"]("validation.number.exactly",{key:n,val:v})):o.push(r["i18n/t"]("validation.number.between",{key:n,min:g,max:v}))):g&&e<g?o.push(r["i18n/t"]("validation.number.min",{key:n,val:g})):v&&e>v&&o.push(r["i18n/t"]("validation.number.max",{key:n,val:v})),o}function h(e,t,n,r,i=[]){const{validChars:o,invalidChars:s}=t,l=[];if(o&&l.push(`[^${t.validChars}]`),s&&l.push(`[${t.invalidChars}]`),l.length){const t=new RegExp(`(${l.join("|")})`,"g");let o=e.match(t);o&&(o=a()(o).map(e=>" "===e?"[space]":e),i.push(r["i18n/t"]("validation.chars",{key:n,count:o.length,chars:o.join(" ")})))}return i}function p(e,t,n,r,i=[]){r=r||{};const{max:o=253,restricted:a=!1}=r;"."===e.slice(0,1)&&i.push(n["i18n/t"]("validation.dns.hostname.startDot",{key:t})),a&&e.length>1&&"."===e.slice(-1)&&i.push(n["i18n/t"]("validation.dns.hostname.endDot",{key:t})),0===e.length&&i.push(n["i18n/t"]("validation.dns.hostname.empty",{key:t})),e.length>o&&i.push(n["i18n/t"]("validation.dns.hostname.tooLong",{key:t,max:o}));const s=e.split(/\./);let l;for(let c=0;c<s.length;c++)l=s[c],0===c&&""===l||c===s.length-1&&""===l||f(l,t,n,{forHostname:!0},i);return i}function f(e,t,n,r,i=[]){r=r||{};const{forHostname:o=!1,errorKey:a=(o?"hostname":"label"),ianaServiceName:s=!1,restricted:l=!1}=r;return c(e,t,n,r,i),l&&e.slice(0,1).match(/[0-9]/)&&i.push(n["i18n/t"](`validation.dns.${a}.startNumber`,{key:t})),("--"===e.substr(2,2)&&"xn"!==e.substr(0,2)||s&&e.includes("--"))&&i.push(n["i18n/t"]("validation.dns.doubleHyphen",{key:t})),i}function m(e,t,n,r,i,o=[]){switch(t){case"dnsLabel":f(e,n,r,{restricted:!1},o);break;case"dnsLabelRestricted":f(e,n,r,{restricted:!0},o);break;case"hostname":p(e,n,r,{restricted:!1},o);break;default:break}return o}function g(e,t,n,r,i=[]){const{required:o}=t;!o||e||!1===e?"boolean"!==typeof e&&e&&i.push(r["i18n/t"]("validation.boolean",{key:n})):i.push(r["i18n/t"]("validation.required",{key:n}))}},68094:function(e,t,n){"use strict";n.d(t,{AY:function(){return s},L6:function(){return r},Lk:function(){return o},M8:function(){return a},Q6:function(){return i},fB:function(){return l}});const r=e=>"server-url"===e,i=e=>e.toLowerCase().startsWith("https://"),o=e=>/^(?=.{1,254}$)(?![a-z][a-z0-9+.-]*:\/\/)(?:[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?\.)+[a-z]{2,}(?::\d{1,5})?(?:\/\S*)?$/i.test(e),a=e=>/^(?:https?:\/\/)?(?:localhost|127\.0\.0\.1)/i.test(e),s=e=>{if("string"!==typeof e||!e)return!1;try{const t=new URL(e);return!!t.hostname}catch{return!1}},l=e=>s(e)&&e?.toLowerCase().endsWith("/")},83288:function(e,t,n){"use strict";n.d(t,{UD:function(){return d},V1:function(){return f},Xt:function(){return u},hQ:function(){return m}});var r=n(74302),i=n(2722),o=n.n(i),a=n(35664),s=(n(41476),n(9262)),l=n(83297);function c(e){e=`${e}`,"v"===e.substr(0,1).toLowerCase()&&(e=e.substr(1));const t=e.split(/[.+-]/);return t}function u(e){return c(e).map(e=>(0,r.RY)(e)).join(".")}function d(e,t){if(!e)return 1;if(!t)return-1;const n=c(e),r=c(t),i=Math.min(n.length,r.length);for(let o=0;o<i;o++){const e=p(n[o],r[o]);if(0!==e)return e}return n.length-r.length}function h(e){return`${e}`.match(/^([0-9]+\.)?[0-9]*$/)}function p(e,t){if(e=`${e}`.toLowerCase(),t=`${t}`.toLowerCase(),h(e)&&h(t)){const n=parseInt(e,10),r=parseInt(t,10);if(!isNaN(n)&&!isNaN(r))return n-r}return e.localeCompare(t)}function f(e=""){return o().valid(e)||(e=o().clean(e,{loose:!0})),!!o().prerelease(e)}function m(e){const t=e.getters["management/byId"](a.Mc.SETTING,s.HG.VERSION_RANCHER)?.value??(0,l.nv)()?.Version??"unknown";let n=t;const r=t.match(/^(.*)-([0-9a-f]{40})-(.*)$/);return r&&(n=r[2].substr(0,7)),{displayVersion:n,fullVersion:t}}},66242:function(e,t,n){"use strict";n.d(t,{d:function(){return r}});const r={CONSOLE_URL:"/host/#remote-console",RANCHER_INTEGRATION_URL:"/rancher/rancher-integration",KSMTUNED_MODE:"/host/#ksmtuned-mode",UPGRADE_URL:"/upgrade/index",UPGRADE_CONFIG_URL:"/advanced/index#upgrade-config",STORAGE_NETWORK_EXAMPLE:"/advanced/storagenetwork#configuration-example",SUPPORT_BUNDLE_NAMESPACES:"/advanced/index/#support-bundle-namespaces",VPC_CONFIGURATION_EXAMPLES:"/networking/kubeovn-vpc#vpc-peering-configuration-examples",NETWORK_POLICY:"/networking/kubeovn-vm-isolation/#network-policies",TRANSPARENT_HUGEPAGES:"https://docs.kernel.org/admin-guide/mm/transhuge.html"}},48050:function(e,t,n){"use strict";n.r(t),n.d(t,{IP_POOL_HEADERS:function(){return T},PRODUCT_NAME:function(){return A},init:function(){return R}});var r=n(35664),i=n(32766),o=n(68774),a=n(86565),s=n(1371),l=n(66905),c=n(41476);function u(e,t,{addonName:n,resourceType:r,navGroup:i,types:o,requireSchema:a=!0}){if("undefined"===typeof window)return;const s=()=>{const t="ui.refresh.trigger";[0,600,1500].forEach(n=>{setTimeout(()=>{const n=(e.getters["prefs/get"](c.JV)||[]).filter(e=>e!==t);e.commit("prefs/load",{key:c.JV,value:[...n,t]}),setTimeout(()=>e.commit("prefs/load",{key:c.JV,value:[...n]}),300)},n)})},l=n=>{try{return!!e.getters[`${t}/schemaFor`]?.(n)}catch(r){return!1}},u=n=>{e.commit("type-map/basicType",{product:t,group:i,types:n})},d=()=>{const n=e.state["type-map"].basicTypes[t];n&&o.forEach(e=>delete n[e])},h=e=>{const t=e?a?o.filter(l):o:[];d(),t.length>0&&u(t),s()};let p=0;const f=60,m=setInterval(()=>{p++;try{const i=e.getters[`${t}/schemaFor`]&&e.getters[`${t}/schemaFor`](r),s=e.getters[`${t}/haveAll`]&&e.getters[`${t}/haveAll`](r);i&&s?(clearInterval(m),e.watch((e,i)=>{const s=i[`${t}/all`](r),c=s.find(e=>e.metadata.name===n),u=!0===c?.spec?.enabled,d=!a||o.every(l);return`${u}:${d}`},()=>{const i=e.getters[`${t}/all`](r),o=i.find(e=>e.metadata.name===n);h(!0===o?.spec?.enabled)},{immediate:!0,deep:!0})):i&&!s?e.dispatch(`${t}/findAll`,{type:r}):p>=f&&clearInterval(m)}catch(i){p>=f&&clearInterval(m)}},1e3)}var d=n(22827),h=n(49845),p=n(95265);function f(){return{id:p.Kg,type:r.Mc.FEATURE,metadata:{name:p.Kg},spec:{value:!1},status:{default:!0,dynamic:!0,lockedValue:null}}}var m=n(9262);function g(){let e;return(t,n)=>{if(!t)return;t.value!==r.qt.SUSE&&(e=t.value);const i=n?r.qt.SUSE:e??t.value;t.value!==i&&(t.value=i)}}const v=i.rk.VM_VERSION,b="Monitoring & Logging::Monitoring",y="Monitoring & Logging::Logging",w="Overlay Networks",O="Underlay Networks",S=`${w}::NAT & Internet`,E=`${S}::Gateways`,x=`${S}::External IPs`,_=`${S}::Rules`,k=`${_}::Source Rules`,C=`${_}::Destination Rules`,A="harvester",T=[o.c4,o.o_,{name:"subnet",labelKey:"harvester.ipPool.subnet.label",value:"subnetDisplay"},{name:"availableIP",labelKey:"harvester.ipPool.availableIP.label",value:"status.available"},o.K];function R(e,t){const{product:c,basicType:S,headers:_,configureType:R,virtualType:N,weightGroup:P}=e.DSL(t,A),I={NODE_ENV:"production",BASE_URL:"/"}.rancherEnv===A;if(I){const e={name:`${A}-c-cluster-resource`,params:{product:A,resource:i.rk.DASHBOARD}};t.watch((e,t)=>JSON.stringify([!!t["harvester-common/isHarvesterPrime"],"dark"===t["prefs/theme"],t["harvester-common/privateLabel"]]),r=>{const[o,a,s]=JSON.parse(r),l=n(a?49401:96456);(0,d.ji)(o),(0,h.xc)(s||"");const c=s?"harvester.branding.primeLabel":"harvester.branding.primeEmptyLabel";t.dispatch("setIsSingleProduct",{productName:A,logo:o?l:n(53938),productNameKey:o?c:"harvester.productLabel",getVersionInfo:e=>e.getters[`${A}/byId`]?.(i.rk.SETTING,"server-version")?.value||"unknown",afterLoginRoute:e,logoRoute:e,supportCustomLogo:!o})},{immediate:!0}),t.watch((e,t)=>t["management/byId"](r.Mc.FEATURE,p.Kg),e=>{e||t.dispatch("management/load",{data:f()})},{immediate:!0});const o=g();t.watch((e,t)=>{const n=t["management/byId"](r.Mc.SETTING,m.HG.BRAND);return[!!t["harvester-common/isHarvesterPrime"],n,n?.value]},([e,t])=>o(t,e),{immediate:!0})}c({inStore:"harvester",removable:!1,showNamespaceFilter:!0,hideKubeShell:!0,hideKubeConfig:!0,showClusterSwitcher:!0,hideCopyConfig:!0,hideSystemResources:!0,customNamespaceFilter:!0,typeStoreMap:{[r.Mc.PROJECT]:"management",[r.Mc.CLUSTER_ROLE_TEMPLATE_BINDING]:"management",[r.Mc.PROJECT_ROLE_TEMPLATE_BINDING]:"management"},supportRoute:{name:`${A}-c-cluster-support`},to:{name:`${A}-c-cluster-resource`,params:{product:A,resource:i.rk.DASHBOARD}},hideNamespaceLocation:!0}),S([i.rk.DASHBOARD]),N({labelKey:"harvester.dashboard.label",group:"Root",name:i.rk.DASHBOARD,weight:500,route:{name:`${A}-c-cluster-resource`,params:{product:A,resource:i.rk.DASHBOARD}}}),R(i.rk.DASHBOARD,{showListMasthead:!1}),R(i.rk.HOST,{location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.HOST}},resource:r.NW,resourceDetail:i.rk.HOST,resourceEdit:i.rk.HOST,canYaml:!1}),R(i.rk.HOST,{isCreatable:!1,isEditable:!0}),S([i.rk.HOST]),N({ifHaveType:r.NW,labelKey:"harvester.host.label",group:"Root",name:i.rk.HOST,namespaced:!0,weight:499,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.HOST}},exact:!1}),S(["cluster-members"],"rbac"),N({ifHave:a.f7.MULTI_CLUSTER,labelKey:"members.clusterMembers",group:"root",namespaced:!1,name:r.cG.CLUSTER_MEMBERS,weight:100,route:{name:`${A}-c-cluster-members`},exact:!0,ifHaveType:{type:r.Mc.CLUSTER_ROLE_TEMPLATE_BINDING,store:"management"}}),S([i.rk.VM]),R(i.rk.VM,{canYaml:!1}),N({labelKey:"harvester.virtualMachine.label",group:"root",name:i.rk.VM,namespaced:!0,weight:498,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.VM}},exact:!1}),P("vmimport",0,!1),_(i.rk.VMIMPORT,[o.c4,o.o_,o.CU,s.Ad,s.R_,s.$G,o.K]),R(i.rk.VMIMPORT,{resource:i.rk.VMIMPORT,resourceDetail:i.rk.VMIMPORT,resourceEdit:i.rk.VMIMPORT,location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.VMIMPORT}}}),N({name:i.rk.VMIMPORT,labelKey:"harvester.addons.vmImport.labels.vmimport",group:"vmimport",namespaced:!0,ifHaveType:i.rk.VMIMPORT,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.VMIMPORT}}}),_(i.rk.VMIMPORT_SOURCE_V,[o.c4,o.o_,s.Vv,s.H4,s.y2,o.K]),R(i.rk.VMIMPORT_SOURCE_V,{resource:i.rk.VMIMPORT_SOURCE_V,resourceDetail:i.rk.VMIMPORT_SOURCE_V,resourceEdit:i.rk.VMIMPORT_SOURCE_V,location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.VMIMPORT_SOURCE_V}}}),N({name:i.rk.VMIMPORT_SOURCE_V,labelKey:"harvester.addons.vmImport.labels.vmimportSourceVMWare",group:"vmimport",namespaced:!0,ifHaveType:i.rk.VMIMPORT_SOURCE_V,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.VMIMPORT_SOURCE_V}}}),_(i.rk.VMIMPORT_SOURCE_O,[o.c4,o.o_,s.ap,s.Jb,s.Bc,o.K]),R(i.rk.VMIMPORT_SOURCE_O,{resource:i.rk.VMIMPORT_SOURCE_O,resourceDetail:i.rk.VMIMPORT_SOURCE_O,resourceEdit:i.rk.VMIMPORT_SOURCE_O,location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.VMIMPORT_SOURCE_O}}}),N({name:i.rk.VMIMPORT_SOURCE_O,labelKey:"harvester.addons.vmImport.labels.vmimportSourceOpenStack",group:"vmimport",namespaced:!0,ifHaveType:i.rk.VMIMPORT_SOURCE_O,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.VMIMPORT_SOURCE_O}}}),_(i.rk.VMIMPORT_SOURCE_OVA,[o.c4,o.o_,s.Jw,s.M2,o.K]),R(i.rk.VMIMPORT_SOURCE_OVA,{resource:i.rk.VMIMPORT_SOURCE_OVA,resourceDetail:i.rk.VMIMPORT_SOURCE_OVA,resourceEdit:i.rk.VMIMPORT_SOURCE_OVA,location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.VMIMPORT_SOURCE_OVA}}}),N({name:i.rk.VMIMPORT_SOURCE_OVA,labelKey:"harvester.addons.vmImport.labels.vmimportSourceOVA",group:"vmimport",namespaced:!0,ifHaveType:i.rk.VMIMPORT_SOURCE_OVA,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.VMIMPORT_SOURCE_OVA}}}),u(t,A,{addonName:l.Jo.VM_IMPORT_CONTROLLER,resourceType:i.rk.ADD_ONS,navGroup:"vmimport",types:[i.rk.VMIMPORT_SOURCE_V,i.rk.VMIMPORT_SOURCE_O,i.rk.VMIMPORT_SOURCE_OVA,i.rk.VMIMPORT]}),S([i.rk.VOLUME]),R(i.rk.VOLUME,{location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.VOLUME}},resource:r.YH,resourceDetail:i.rk.VOLUME,resourceEdit:i.rk.VOLUME,canYaml:!1}),N({labelKey:"harvester.volume.label",group:"root",ifHaveType:r.YH,name:i.rk.VOLUME,namespaced:!0,weight:497,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.VOLUME}},exact:!1}),S([i.rk.IMAGE]),_(i.rk.IMAGE,[o.c4,o.o_,o.CU,s.EJ,s.r,s.IL,s.tI,s.WR,o.K]),R(i.rk.IMAGE,{canYaml:!1}),N({labelKey:"harvester.image.label",group:"root",name:i.rk.IMAGE,namespaced:!0,weight:496,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.IMAGE}},exact:!1}),S(["projects-namespaces"]),N({ifHave:a.f7.MULTI_CLUSTER,labelKey:"harvester.projectNamespace.label",group:"root",namespaced:!0,name:"projects-namespaces",weight:495,route:{name:`${A}-c-cluster-projectsnamespaces`},exact:!0}),I&&(_(r.CU,[o.c4,o.ZU,o.tC,o.K]),S([r.CU]),N({labelKey:"harvester.namespace.label",name:r.CU,namespaced:!0,weight:495,route:{name:`${A}-c-cluster-resource`,params:{resource:r.CU}},exact:!1})),S([i.rk.ALERTMANAGERCONFIG],b),S([i.rk.CLUSTER_FLOW,i.rk.CLUSTER_OUTPUT,i.rk.FLOW,i.rk.OUTPUT],y),P("Monitoring",2,!0),P("Logging",1,!0),_(i.rk.ALERTMANAGERCONFIG,[o.c4,o.o_,o.CU,{name:"receivers",labelKey:"tableHeaders.receivers",formatter:"ReceiverIcons",value:"name"}]),R(i.rk.ALERTMANAGERCONFIG,{location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.ALERTMANAGERCONFIG}},resource:r.Rp.ALERTMANAGERCONFIG,resourceDetail:i.rk.ALERTMANAGERCONFIG,resourceEdit:i.rk.ALERTMANAGERCONFIG,canYaml:!1}),N({ifHaveType:r.Rp.ALERTMANAGERCONFIG,labelKey:"harvester.monitoring.alertmanagerConfig.label",name:i.rk.ALERTMANAGERCONFIG,namespaced:!0,weight:87,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.ALERTMANAGERCONFIG}},exact:!1}),R(i.rk.CLUSTER_FLOW,{location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.CLUSTER_FLOW}},resource:r.cm.CLUSTER_FLOW,resourceDetail:i.rk.CLUSTER_FLOW,resourceEdit:i.rk.CLUSTER_FLOW,canYaml:!1}),N({ifHaveType:r.cm.CLUSTER_FLOW,labelKey:"harvester.logging.clusterFlow.label",name:i.rk.CLUSTER_FLOW,namespaced:!0,weight:79,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.CLUSTER_FLOW}},exact:!1}),R(i.rk.CLUSTER_OUTPUT,{location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.CLUSTER_OUTPUT}},resource:r.cm.CLUSTER_OUTPUT,resourceDetail:i.rk.CLUSTER_OUTPUT,resourceEdit:i.rk.CLUSTER_OUTPUT,canYaml:!1}),N({ifHaveType:r.cm.CLUSTER_OUTPUT,labelKey:"harvester.logging.clusterOutput.label",name:i.rk.CLUSTER_OUTPUT,namespaced:!0,weight:78,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.CLUSTER_OUTPUT}},exact:!1}),R(i.rk.FLOW,{location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.FLOW}},resource:r.cm.FLOW,resourceDetail:i.rk.FLOW,resourceEdit:i.rk.FLOW,canYaml:!1}),N({ifHaveType:r.cm.FLOW,labelKey:"harvester.logging.flow.label",name:i.rk.FLOW,namespaced:!0,weight:77,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.FLOW}},exact:!1}),R(i.rk.OUTPUT,{location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.OUTPUT}},resource:r.cm.OUTPUT,resourceDetail:i.rk.OUTPUT,resourceEdit:i.rk.OUTPUT,canYaml:!1}),N({ifHaveType:r.cm.OUTPUT,labelKey:"harvester.logging.output.label",name:i.rk.OUTPUT,namespaced:!0,weight:76,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.OUTPUT}},exact:!1}),_(i.rk.FLOW,[o.c4,o.o_,o.CU,o.aQ,o.hX,o.Yf,o.K]),_(i.rk.OUTPUT,[o.c4,o.o_,o.CU,o.P4,o.K]),_(i.rk.CLUSTER_FLOW,[o.c4,o.o_,o.CU,o.hX,o.Yf,o.K]),_(i.rk.CLUSTER_OUTPUT,[o.c4,o.o_,o.CU,o.P4,o.K]),S([i.rk.CLUSTER_NETWORK,i.rk.NETWORK_ATTACHMENT,i.rk.HOST_NETWORK_CONFIG,i.rk.LB,i.rk.IP_POOL],"networks"),S([i.rk.VPC],w),S([r.UR],w),S([i.rk.VPC_NAT_GATEWAY],E),S([i.rk.IPTABLES_EIP],x),S([i.rk.IPTABLES_SNAT_RULE],k),S([i.rk.IPTABLES_DNAT_RULE],C),S([i.rk.PROVIDER_NETWORK],O),S([i.rk.VLAN],O),S([i.rk.SCHEDULE_VM_BACKUP,i.rk.BACKUP,i.rk.SNAPSHOT,i.rk.VM_SNAPSHOT],"backupAndSnapshot"),P("networks",494,!0),P("Overlay Networks",493,!0),P("NAT & Internet",492,!0),P("Rules",491,!0),P("Underlay Networks",490,!0),P("backupAndSnapshot",489,!0),S([i.rk.SR_IOV,i.rk.PCI_DEVICE,i.rk.SR_IOVGPU_DEVICE,i.rk.VGPU_DEVICE,i.rk.MIG_CONFIGURATION,i.rk.USB_DEVICE],"hardwareDevices"),P("hardwareDevices",488,!0),S([v,i.rk.SSH,i.rk.CLOUD_TEMPLATE,i.rk.STORAGE,i.rk.ADD_ONS,i.rk.SECRET,i.rk.SETTING],"advanced"),R(i.rk.CLUSTER_NETWORK,{realResource:i.rk.SETTING,showState:!1}),N({labelKey:"harvester.vmTemplate.label",group:"root",name:v,namespaced:!0,weight:289,route:{name:`${A}-c-cluster-resource`,params:{resource:v}},exact:!1}),R(v,{canYaml:!1}),R(i.rk.SCHEDULE_VM_BACKUP,{showListMasthead:!1,showConfigView:!1,canYaml:!1}),N({labelKey:"harvester.schedule.label",name:i.rk.SCHEDULE_VM_BACKUP,namespaced:!0,weight:201,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.SCHEDULE_VM_BACKUP}},exact:!1,ifHaveType:i.rk.SCHEDULE_VM_BACKUP}),R(i.rk.BACKUP,{showListMasthead:!1,showConfigView:!1,canYaml:!1}),N({labelKey:"harvester.backup.label",name:i.rk.BACKUP,namespaced:!0,weight:200,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.BACKUP}},exact:!1}),R(i.rk.VLAN_CONFIG,{hiddenNamespaceGroupButton:!0,canYaml:!1}),R(i.rk.CLUSTER_NETWORK,{showListMasthead:!1,canYaml:!1}),N({labelKey:"harvester.clusterNetwork.title",name:i.rk.CLUSTER_NETWORK,ifHaveType:i.rk.CLUSTER_NETWORK,namespaced:!1,weight:484,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.CLUSTER_NETWORK}},exact:!1}),R(i.rk.NETWORK_ATTACHMENT,{location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.NETWORK_ATTACHMENT}},resource:r.XG,resourceDetail:i.rk.NETWORK_ATTACHMENT,resourceEdit:i.rk.NETWORK_ATTACHMENT}),N({labelKey:"harvester.network.label",name:i.rk.NETWORK_ATTACHMENT,namespaced:!0,weight:485,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.NETWORK_ATTACHMENT}},exact:!1}),R(i.rk.VPC,{hiddenNamespaceGroupButton:!0,canYaml:!1}),N({labelKey:"harvester.vpc.label",name:i.rk.VPC,namespaced:!0,weight:195,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.VPC}},exact:!1,ifHaveType:i.rk.VPC}),R(i.rk.VPC_NAT_GATEWAY,{hiddenNamespaceGroupButton:!0,canYaml:!1}),N({labelKey:"harvester.natGateway.label",name:i.rk.VPC_NAT_GATEWAY,namespaced:!1,weight:193,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.VPC_NAT_GATEWAY}},exact:!1,ifHaveType:i.rk.VPC_NAT_GATEWAY}),R(i.rk.IPTABLES_EIP,{hiddenNamespaceGroupButton:!0,canYaml:!1}),N({labelKey:"harvester.externalIP.label",name:i.rk.IPTABLES_EIP,namespaced:!1,weight:192,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.IPTABLES_EIP}},exact:!1,ifHaveType:i.rk.IPTABLES_EIP}),R(i.rk.IPTABLES_SNAT_RULE,{hiddenNamespaceGroupButton:!0,canYaml:!1}),N({labelKey:"harvester.snat.label",name:i.rk.IPTABLES_SNAT_RULE,namespaced:!1,weight:191,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.IPTABLES_SNAT_RULE}},exact:!1,ifHaveType:i.rk.IPTABLES_SNAT_RULE}),R(i.rk.IPTABLES_DNAT_RULE,{hiddenNamespaceGroupButton:!0,canYaml:!1}),N({labelKey:"harvester.dnat.label",name:i.rk.IPTABLES_DNAT_RULE,namespaced:!1,weight:190,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.IPTABLES_DNAT_RULE}},exact:!1,ifHaveType:i.rk.IPTABLES_DNAT_RULE}),R(r.UR,{hiddenNamespaceGroupButton:!0,canYaml:!1}),N({labelKey:"harvester.networkPolicy.label",name:r.UR,namespaced:!0,weight:194,route:{name:`${A}-c-cluster-resource`,params:{resource:r.UR}},exact:!1,ifHaveType:r.UR}),R(i.rk.PROVIDER_NETWORK,{hiddenNamespaceGroupButton:!0,canYaml:!1}),N({labelKey:"harvester.providerNetwork.label",name:i.rk.PROVIDER_NETWORK,namespaced:!1,weight:189,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.PROVIDER_NETWORK}},exact:!1,ifHaveType:i.rk.PROVIDER_NETWORK}),R(i.rk.VLAN,{hiddenNamespaceGroupButton:!0,canYaml:!1}),_(i.rk.VLAN,[o.c4,o.o_,{name:"id",label:"ID",value:"spec.id",sort:"spec.id"},{name:"provider",labelKey:"harvester.subnet.provider.label",value:"spec.provider",sort:"spec.provider"}]),N({labelKey:"harvester.vlanNetwork.label",name:i.rk.VLAN,namespaced:!1,weight:188,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.VLAN}},exact:!1,ifHaveType:i.rk.VLAN}),R(i.rk.SNAPSHOT,{isCreatable:!1,location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.SNAPSHOT}},resource:i.qY,resourceDetail:i.rk.SNAPSHOT,resourceEdit:i.rk.SNAPSHOT,canYaml:!1}),_(i.rk.SNAPSHOT,[o.c4,o.o_,o.CU,s.mt,o.K]),N({labelKey:"harvester.snapshot.label",name:i.rk.SNAPSHOT,namespaced:!0,weight:190,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.SNAPSHOT}},exact:!1}),R(i.rk.VM_SNAPSHOT,{showListMasthead:!1,location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.VM_SNAPSHOT}},resource:i.rk.BACKUP,resourceDetail:i.rk.VM_SNAPSHOT,resourceEdit:i.rk.VM_SNAPSHOT,canYaml:!1}),N({labelKey:"harvester.vmSnapshot.label",name:i.rk.VM_SNAPSHOT,namespaced:!0,weight:191,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.VM_SNAPSHOT}},exact:!1}),_(i.rk.SSH,[o.c4,o.o_,o.CU,s.lj,o.K]),N({labelKey:"harvester.sshKey.label",name:i.rk.SSH,namespaced:!0,weight:170,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.SSH}},exact:!1}),R(i.rk.CLOUD_TEMPLATE,{location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.CLOUD_TEMPLATE}},resource:r.K5,resourceDetail:i.rk.CLOUD_TEMPLATE,resourceEdit:i.rk.CLOUD_TEMPLATE,canYaml:!1}),N({labelKey:"harvester.cloudTemplate.label",name:i.rk.CLOUD_TEMPLATE,namespaced:!0,weight:87,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.CLOUD_TEMPLATE}},exact:!1}),_(i.rk.SECRET,[o.c4,o.o_,o.CU,o.UA,{name:"data",labelKey:"tableHeaders.data",value:"dataPreview",formatter:"SecretData"},o.K]),R(i.rk.SECRET,{location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.SECRET}},resource:r.bB,resourceDetail:i.rk.SECRET,resourceEdit:i.rk.SECRET,canYaml:!1,notFilterNamespace:["cattle-monitoring-system","cattle-logging-system"]}),N({labelKey:"harvester.secret.label",name:i.rk.SECRET,namespaced:!0,weight:-999,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.SECRET}},exact:!1}),R(i.rk.SETTING,{isCreatable:!1}),N({ifHaveType:i.rk.SETTING,ifHaveVerb:"POST",labelKey:"harvester.setting.label",name:i.rk.SETTING,namespaced:!0,weight:-1e3,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.SETTING}},exact:!1}),R(i.rk.STORAGE,{location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.STORAGE}},resource:r.fJ,resourceDetail:i.rk.STORAGE,resourceEdit:i.rk.STORAGE,isCreatable:!0,canYaml:!1}),N({labelKey:"harvester.storage.title",group:"root",ifHaveType:r.fJ,name:i.rk.STORAGE,namespaced:!1,weight:79,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.STORAGE}},exact:!1}),N({label:"PCI Devices",group:"hardwareDevices",weight:14,name:i.rk.PCI_DEVICE,namespaced:!1,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.PCI_DEVICE}},exact:!1}),R(i.rk.PCI_DEVICE,{isCreatable:!1,hiddenNamespaceGroupButton:!0,canYaml:!0,listGroups:[{icon:"icon-list-grouped",value:"description",field:"groupByDevice",hideColumn:"description",tooltipKey:"resourceTable.groupBy.device"},{icon:"icon-cluster",value:"node",field:"groupByNode",hideColumn:"node",tooltipKey:"resourceTable.groupBy.node"}]}),N({ifHaveType:i.rk.SR_IOV,labelKey:"harvester.sriov.label",group:"hardwareDevices",weight:15,name:i.rk.SR_IOV,namespaced:!1,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.SR_IOV}},exact:!1}),R(i.rk.SR_IOV,{isCreatable:!1,hiddenNamespaceGroupButton:!0,canYaml:!1}),N({ifHaveType:i.rk.SR_IOVGPU_DEVICE,labelKey:"harvester.sriovgpu.label",group:"hardwareDevices",weight:13,name:i.rk.SR_IOVGPU_DEVICE,namespaced:!1,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.SR_IOVGPU_DEVICE}},exact:!1}),R(i.rk.SR_IOVGPU_DEVICE,{isCreatable:!1,hiddenNamespaceGroupButton:!0,canYaml:!1}),N({labelKey:"harvester.vgpu.label",group:"hardwareDevices",weight:12,name:i.rk.VGPU_DEVICE,namespaced:!1,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.VGPU_DEVICE}},exact:!1}),R(i.rk.VGPU_DEVICE,{isCreatable:!1,hiddenNamespaceGroupButton:!0,canYaml:!1,listGroups:[{icon:"icon-cluster",value:"node",field:"groupByNode",hideColumn:"node",tooltipKey:"resourceTable.groupBy.node"}]}),N({labelKey:"harvester.migconfiguration.label",group:"hardwareDevices",weight:12,name:i.rk.MIG_CONFIGURATION,namespaced:!1,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.MIG_CONFIGURATION}},exact:!1,ifHaveType:i.rk.MIG_CONFIGURATION}),R(i.rk.MIG_CONFIGURATION,{isCreatable:!1,hiddenNamespaceGroupButton:!0,canYaml:!1}),N({labelKey:"harvester.usb.label",group:"hardwareDevices",weight:11,name:i.rk.USB_DEVICE,namespaced:!1,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.USB_DEVICE}},exact:!1,ifHaveType:i.rk.USB_DEVICE}),R(i.rk.USB_DEVICE,{isCreatable:!1,hiddenNamespaceGroupButton:!0,canYaml:!1,listGroups:[{icon:"icon-list-grouped",value:"description",field:"groupByDevice",hideColumn:"description",tooltipKey:"resourceTable.groupBy.device"},{icon:"icon-cluster",value:"node",field:"groupByNode",hideColumn:"node",tooltipKey:"resourceTable.groupBy.node"}]}),R(i.rk.ADD_ONS,{isCreatable:!1,isRemovable:!1,showState:!1,canYaml:!1}),N({label:"Add-ons",group:"advanced",name:i.rk.ADD_ONS,ifHaveType:i.rk.ADD_ONS,weight:-900,namespaced:!1,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.ADD_ONS}},exact:!1}),R(i.rk.LB,{location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.LB}},canYaml:!1}),N({labelKey:"harvester.loadBalancer.label",name:i.rk.LB,namespaced:!0,weight:483,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.LB}},exact:!1,ifHaveType:i.rk.LB}),_(i.rk.LB,[o.c4,o.o_,{...o.BD,formatter:"HarvesterListener"},{name:"workloadType",labelKey:"harvester.loadBalancer.workloadType.label",value:"workloadTypeDisplay"},{name:"ipam",labelKey:"harvester.loadBalancer.ipam.label",value:"ipamDisplay"},o.K]),R(i.rk.IP_POOL,{location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.IP_POOL}},canYaml:!1}),N({labelKey:"harvester.ipPool.label",name:i.rk.IP_POOL,namespaced:!1,weight:482,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.IP_POOL}},exact:!1,ifHaveType:i.rk.IP_POOL}),_(i.rk.IP_POOL,T),R(i.rk.HOST_NETWORK_CONFIG,{location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.HOST_NETWORK_CONFIG}},canYaml:!1}),N({labelKey:"harvester.hostNetworkConfig.label",name:i.rk.HOST_NETWORK_CONFIG,namespaced:!1,weight:481,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.HOST_NETWORK_CONFIG}},exact:!1,ifHaveType:i.rk.HOST_NETWORK_CONFIG}),P("vmMigration",0,!1),_(i.rk.FORKLIFT_PROVIDER,[o.c4,o.o_,o.CU,s.DT,s.kQ,o.K]),R(i.rk.FORKLIFT_PROVIDER,{resource:i.rk.FORKLIFT_PROVIDER,location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.FORKLIFT_PROVIDER}}}),N({name:i.rk.FORKLIFT_PROVIDER,labelKey:"harvester.addons.vmMigration.labels.provider",group:"vmMigration",namespaced:!0,weight:100,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.FORKLIFT_PROVIDER}}}),_(i.rk.FORKLIFT_NETWORK_MAP,[o.c4,o.o_,o.CU,s.xO,s.MY,o.K]),R(i.rk.FORKLIFT_NETWORK_MAP,{resource:i.rk.FORKLIFT_NETWORK_MAP,location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.FORKLIFT_NETWORK_MAP}}}),N({name:i.rk.FORKLIFT_NETWORK_MAP,labelKey:"harvester.addons.vmMigration.labels.networkMap",group:"vmMigration::Configurations",namespaced:!0,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.FORKLIFT_NETWORK_MAP}}}),_(i.rk.FORKLIFT_STORAGE_MAP,[o.c4,o.o_,o.CU,s.xO,s.MY,o.K]),R(i.rk.FORKLIFT_STORAGE_MAP,{resource:i.rk.FORKLIFT_STORAGE_MAP,location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.FORKLIFT_STORAGE_MAP}}}),N({name:i.rk.FORKLIFT_STORAGE_MAP,labelKey:"harvester.addons.vmMigration.labels.storageMap",group:"vmMigration::Configurations",namespaced:!0,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.FORKLIFT_STORAGE_MAP}}}),_(i.rk.FORKLIFT_PLAN,[o.c4,o.o_,o.CU,s.xO,s.a8,s.WF,o.K]),R(i.rk.FORKLIFT_PLAN,{resource:i.rk.FORKLIFT_PLAN,location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.FORKLIFT_PLAN}}}),N({name:i.rk.FORKLIFT_PLAN,labelKey:"harvester.addons.vmMigration.labels.plan",group:"vmMigration::Configurations",namespaced:!0,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.FORKLIFT_PLAN}}}),_(i.rk.FORKLIFT_MIGRATION,[o.c4,o.o_,o.CU,s.zI,o.K]),R(i.rk.FORKLIFT_MIGRATION,{resource:i.rk.FORKLIFT_MIGRATION,location:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.FORKLIFT_MIGRATION}}}),N({name:i.rk.FORKLIFT_MIGRATION,labelKey:"harvester.addons.vmMigration.labels.migration",group:"vmMigration::Configurations",namespaced:!0,route:{name:`${A}-c-cluster-resource`,params:{resource:i.rk.FORKLIFT_MIGRATION}}}),R("forklift-create",{subTypes:[i.rk.FORKLIFT_PLAN]}),N({name:"forklift-create",labelKey:"harvester.addons.vmMigration.labels.dashboard",group:"vmMigration",namespaced:!0,weight:200,route:{name:`${A}-c-cluster-vm-migration`,params:{}}}),u(t,A,{addonName:l.Jo.FORKLIFT_OPERATOR,resourceType:i.rk.ADD_ONS,navGroup:"vmMigration",requireSchema:!1,types:["forklift-create"]}),u(t,A,{addonName:l.Jo.FORKLIFT_OPERATOR,resourceType:i.rk.ADD_ONS,navGroup:"vmMigration",types:[i.rk.FORKLIFT_PROVIDER]}),u(t,A,{addonName:l.Jo.FORKLIFT_OPERATOR,resourceType:i.rk.ADD_ONS,navGroup:"vmMigration::Configurations",types:[i.rk.FORKLIFT_NETWORK_MAP,i.rk.FORKLIFT_STORAGE_MAP,i.rk.FORKLIFT_PLAN,i.rk.FORKLIFT_MIGRATION]})}},66905:function(e,t,n){"use strict";n.d(t,{$E:function(){return m},$z:function(){return i},Et:function(){return b},Ex:function(){return y},Ih:function(){return w},Jo:function(){return v},LL:function(){return s},UQ:function(){return g},_w:function(){return a},cI:function(){return h},gq:function(){return c},hg:function(){return f},ni:function(){return u},uH:function(){return d},vo:function(){return p},xO:function(){return o},zr:function(){return l}});var r=n(32766);const i=[{label:"VirtIO",value:"virtio"},{label:"SATA",value:"sata"},{label:"SCSI",value:"scsi"}],o={NEW:"New",IMAGE:"Virtual Machine Image",ATTACH_VOLUME:"Existing Volume",CONTAINER:"Container"},a=[{label:"disk",value:"disk"},{label:"cd-rom",value:"cd-rom"}],s=["","none","writeback","writethrough"],l=["","native","threads"],c=["","shared","auto","supplementalPool"],u={DEFAULT:"default",HIGH:"highPerformance",CUSTOM:"custom"},d={INSERT_CDROM_IMAGE:"INSERT_CDROM_IMAGE",EJECT_CDROM_IMAGE:"EJECT_CDROM_IMAGE",DETACH_DISK:"DETACH_DISK"},h={RESET_PWD:"userPassword",INJECT_SSH:"sshPublicKey"},p=["Always","RerunOnFailure","Manual","Halted"],f=["Migrate","ShutdownAndRestartAfterEnable","ShutdownAndRestartAfterDisable","Shutdown"],m={VolumeSnapshot:"VolumeSnapshot",PersistentVolumeClaim:"Volume"},g={LOGGING:"Logging",AUDIT:"Audit",EVENT:"Event"},v={HARVESTER_SEEDER:"harvester-seeder",PCI_DEVICE_CONTROLLER:"pcidevices-controller",NVIDIA_DRIVER_TOOLKIT_CONTROLLER:"nvidia-driver-toolkit",RANCHER_LOGGING:"rancher-logging",RANCHER_MONITORING:"rancher-monitoring",VM_IMPORT_CONTROLLER:"vm-import-controller",LVM_DRIVER:"lvm.driver.harvesterhci.io",KUBEOVN_OPERATOR:"kubeovn-operator",FORKLIFT_OPERATOR:"forklift-operator"},b={CSI_PROVISIONER_SECRET_NAME:"csi.storage.k8s.io/provisioner-secret-name",CSI_PROVISIONER_SECRET_NAMESPACE:"csi.storage.k8s.io/provisioner-secret-namespace",CSI_NODE_PUBLISH_SECRET_NAME:"csi.storage.k8s.io/node-publish-secret-name",CSI_NODE_PUBLISH_SECRET_NAMESPACE:"csi.storage.k8s.io/node-publish-secret-namespace",CSI_NODE_STAGE_SECRET_NAME:"csi.storage.k8s.io/node-stage-secret-name",CSI_NODE_STAGE_SECRET_NAMESPACE:"csi.storage.k8s.io/node-stage-secret-namespace",CSI_NODE_EXPAND_SECRET_NAME:"csi.storage.k8s.io/node-expand-secret-name",CSI_NODE_EXPAND_SECRET_NAMESPACE:"csi.storage.k8s.io/node-expand-secret-namespace"},y="forklift",w={node:r.rk.HOST,configmap:r.rk.CLOUD_TEMPLATE,persistentvolumeclaim:r.rk.VOLUME,"snapshot.storage.k8s.io.volumesnapshot":r.rk.SNAPSHOT,"network.harvesterhci.io.vlanconfig":r.rk.CLUSTER_NETWORK,"kubeovn.io.subnet":r.rk.VPC}},2602:function(e,t,n){"use strict";n.d(t,{l:function(){return o},r:function(){return a}});const r=/cattle\.io\//,i=/harvesterhci\.io\/maintain-mode-strategy/,o=[r,i],a={CLOUD_INIT:"harvesterhci.io/cloud-init-template",CURRENT_IP:"rke2.io/internal-ip",IMAGE_ID:"harvesterhci.io/imageId",SSH_NAMES:"harvesterhci.io/sshNames",NETWORK_IPS:"network.harvesterhci.io/ips",TEMPLATE_VERSION_CUSTOM_NAME:"template-version.harvesterhci.io/customName",CREATOR:"harvesterhci.io/creator",OS:"harvesterhci.io/os",GOLDEN_IMAGE:"harvesterhci.io/goldenImage",CLUSTER_NETWORK:"network.harvesterhci.io/clusternetwork",NETWORK_TYPE:"network.harvesterhci.io/type",VM_NAME:"harvesterhci.io/vmName",VM_NAME_PREFIX:"harvesterhci.io/vmNamePrefix",VM_DISPLAY_NAME:"harvesterhci.io/vmDisplayName",VM_RESERVED_MEMORY:"harvesterhci.io/reservedMemory",MAINTENANCE_STATUS:"harvesterhci.io/maintain-status",HOST_CUSTOM_NAME:"harvesterhci.io/host-custom-name",HOST_CONSOLE_URL:"harvesterhci.io/host-console-url",RESTORE_NAME:"restore.harvesterhci.io/name",NODE_ROLE_MASTER:"node-role.kubernetes.io/master",NODE_ROLE_CONTROL_PLANE:"node-role.kubernetes.io/control-plane",NODE_ROLE_ETCD:"node-role.harvesterhci.io/witness",PROMOTE_STATUS:"harvesterhci.io/promote-status",CLONE_BACKEND_STORAGE_STATUS:"harvesterhci.io/clone-backend-storage-status",MIGRATION_STATE:"harvesterhci.io/migrationState",VOLUME_CLAIM_TEMPLATE:"harvesterhci.io/volumeClaimTemplates",DISK_CACHE_MODE:"harvesterhci.io/disk-cache-mode",DISK_IO_MODE:"harvesterhci.io/disk-io-mode",DISK_DEDICATED_IOTHREAD:"harvesterhci.io/disk-dedicated-iothread",IMAGE_NAME:"harvesterhci.io/image-name",INIT_IP:"etcd.rke2.cattle.io/node-address",NODE_SCHEDULABLE:"kubevirt.io/schedulable",NETWORK_ROUTE:"network.harvesterhci.io/route",MATCHED_NODES:"network.harvesterhci.io/matched-nodes",UPGRADE:"harvesterhci.io/upgrade",OS_UPGRADE_IMAGE:"harvesterhci.io/os-upgrade-image",LATEST_UPGRADE:"harvesterhci.io/latestUpgrade",UPGRADE_STATE:"harvesterhci.io/upgradeState",REAY_MESSAGE:"harvesterhci.io/read-message",DYNAMIC_SSHKEYS_NAMES:"harvesterhci.io/dynamic-ssh-key-names",DYNAMIC_SSHKEYS_USERS:"harvesterhci.io/dynamic-ssh-key-users",IMAGE_SUFFIX:"harvesterhci.io/image-type",OS_TYPE:"harvesterhci.io/os-type",STORAGE_PROVISIONER:"harvesterhci.io/storageProvisioner",SKIP_SINGLE_REPLICA_DETACHED_VOL:"harvesterhci.io/skipSingleReplicaDetachedVol",HOST_REQUEST:"management.cattle.io/pod-requests",STORAGE_CLASS:"harvesterhci.io/storageClassName",STORAGE_NETWORK:"storage-network.settings.harvesterhci.io",ADDON_EXPERIMENTAL:"addon.harvesterhci.io/experimental",ADDON_DISPLAYNAME:"addon.harvesterhci.io/displayName",VOLUME_ERROR:"longhorn.io/volume-scheduling-error",VOLUME_FOR_VM:"harvesterhci.io/volumeForVirtualMachine",KVM_AMD_CPU:"cpu-feature.node.kubevirt.io/svm",KVM_INTEL_CPU:"cpu-feature.node.kubevirt.io/vmx",NODE_MANUFACTURER:"manufacturer",NODE_MODEL:"model",NODE_SERIAL_NUMBER:"serialNumber",VM_INSUFFICIENT:"harvesterhci.io/insufficient-resource-quota",NODE_NTP_SYNC_STATUS:"node.harvesterhci.io/ntp-service",PARENT_SRIOV:"harvesterhci.io/parent-sriov-network-device",PARENT_SRIOV_GPU:"harvesterhci.io/parentSRIOVGPUDevice",VM_MAINTENANCE_MODE_STRATEGY:"harvesterhci.io/maintain-mode-strategy",NODE_CPU_MANAGER_UPDATE_STATUS:"harvesterhci.io/cpu-manager-update-status",CPU_MANAGER:"cpumanager",VM_DEVICE_ALLOCATION_DETAILS:"harvesterhci.io/deviceAllocationDetails",SVM_BACKUP_ID:"harvesterhci.io/svmbackupId",DISABLE_LONGHORN_V2_ENGINE:"node.longhorn.io/disable-v2-data-engine",K8S_ARCH:"kubernetes.io/arch",IMAGE_DISPLAY_NAME:"harvesterhci.io/imageDisplayName",CUSTOM_IP:"harvesterhci.io/custom-ip",IMPORTED_IMAGE:"migration.harvesterhci.io/imported",VM_CPU_MEMORY_HOTPLUG:"harvesterhci.io/enableCPUAndMemoryHotplug",FILESYSTEM_OVERHEAD:"cdi.harvesterhci.io/filesystemOverhead",CLONE_STRATEGY:"cdi.harvesterhci.io/storageProfileCloneStrategy",VOLUME_MODE_ACCESS_MODES:"cdi.harvesterhci.io/storageProfileVolumeModeAccessModes",VOLUME_SNAPSHOT_CLASS:"cdi.harvesterhci.io/storageProfileVolumeSnapshotClass",MAC_ADDRESS:"harvesterhci.io/mac-address",STATIC_IP:"static-ip.harvesterhci.io",NODE_UPGRADE_PAUSE_MAP:"harvesterhci.io/node-upgrade-pause-map",CDI_POPULATOR_KIND:"cdi.kubevirt.io/storage.populator.kind",CNI_NETWORKS:"k8s.v1.cni.cncf.io/networks",WINDOWS_SYSPREP:"harvesterhci.io/windows-sysprep",SKIP_MIG_CONFIGURATION:"harvesterhci.io/skip-mig-configuration"}},1371:function(e,t,n){"use strict";n.d(t,{$G:function(){return w},Ad:function(){return b},Bc:function(){return k},D9:function(){return m},DT:function(){return T},EJ:function(){return f},H4:function(){return O},IL:function(){return a},Jb:function(){return x},Jw:function(){return C},KG:function(){return u},M2:function(){return A},MY:function(){return P},R_:function(){return y},Su:function(){return v},Vv:function(){return S},WF:function(){return M},WR:function(){return o},a8:function(){return I},ap:function(){return _},iu:function(){return d},kQ:function(){return R},lA:function(){return h},lj:function(){return s},mt:function(){return l},nl:function(){return g},r:function(){return p},tC:function(){return c},tI:function(){return i},xO:function(){return N},y2:function(){return E},zI:function(){return D}});var r=n(68774);const i={name:"downloadedBytes",labelKey:"tableHeaders.size",value:"downSize",sort:"status.size"},o={name:"virtualSize",labelKey:"harvester.tableHeaders.virtualSize",value:"virtualSize",sort:"status.virtualSize"},a={name:"Uploaded",labelKey:"tableHeaders.progress",value:"status.progress",sort:"status.progress",formatter:"ImagePercentageBar"},s={name:"Fingerprint",labelKey:"tableHeaders.fingerprint",value:"status.fingerPrint"},l={name:"TargetVolume",labelKey:"harvester.tableHeaders.snapshotTargetVolume",value:"spec.source.persistentVolumeClaimName",sort:"spec.source.persistentVolumeClaimName",formatter:"SnapshotTargetVolume"},c={name:"CronExpression",labelKey:"harvester.tableHeaders.cronExpression",value:"spec.cron",align:"center",sort:"spec.cron",formatter:"HarvesterCronExpression"},u={name:"Retain",labelKey:"harvester.tableHeaders.retain",value:"spec.retain",sort:"spec.retain",align:"center"},d={name:"MaxFailure",labelKey:"harvester.tableHeaders.maxFailure",value:"spec.maxFailure",sort:"spec.maxFailure",align:"center"},h={name:"Type",labelKey:"harvester.tableHeaders.scheduleType",value:"spec.vmbackup.type",sort:"spec.vmbackup.type",align:"center"},p={name:"imageStorageClass",labelKey:"harvester.tableHeaders.storageClass",sort:"imageStorageClass",value:"imageStorageClass",align:"left",width:150},f={...r.tC,width:150},m={name:"cidrBlock",labelKey:"harvester.subnet.cidrBlock.label",sort:"cidrBlock",value:"spec.cidrBlock",align:"left"},g={name:"protocol",labelKey:"harvester.subnet.protocol.label",sort:"protocol",value:"spec.protocol",align:"left"},v={name:"provider",labelKey:"harvester.subnet.provider.label",sort:"provider",value:"spec.provider",align:"left"},b={name:"sourceVm",labelKey:"harvester.tableHeaders.vmImportSourceVm",value:"spec.virtualMachineName",sort:"spec.virtualMachineName",align:"left"},y={name:"sourceCluster",labelKey:"harvester.tableHeaders.vmImportSourceCluster",value:"spec.sourceCluster.name",sort:"spec.sourceCluster.name",align:"left"},w={name:"importStatus",labelKey:"harvester.tableHeaders.vmImportStatus",value:"status.importStatus",sort:"status.importStatus",align:"left"},O={name:"datacenter",labelKey:"harvester.tableHeaders.vmImportSourceVDatacenter",value:"spec.dc",sort:"spec.dc",align:"left"},S={name:"endpoint",labelKey:"harvester.tableHeaders.vmImportSourceVEndpoint",value:"spec.endpoint",sort:"spec.endpoint",align:"left"},E={name:"clusterStatus",labelKey:"harvester.tableHeaders.vmImportSourceVClusterStatus",value:"status.status",sort:"status.status",align:"left"},x={name:"region",labelKey:"harvester.tableHeaders.vmImportSourceORegion",value:"spec.region",sort:"spec.region",align:"left"},_={name:"endpoint",labelKey:"harvester.tableHeaders.vmImportSourceOEndpoint",value:"spec.endpoint",sort:"spec.endpoint",align:"left"},k={name:"clusterStatus",labelKey:"harvester.tableHeaders.vmImportSourceOClusterStatus",value:"status.status",sort:"status.status",align:"left"},C={name:"url",labelKey:"harvester.tableHeaders.vmImportSourceOVAUrl",value:"spec.url",sort:"spec.url",align:"left"},A={name:"status",labelKey:"harvester.tableHeaders.vmImportSourceOVAStatus",value:"status.status",sort:"status.status",align:"left"},T={name:"providerType",labelKey:"harvester.tableHeaders.vmMigrationProviderType",value:"spec.type",sort:"spec.type",align:"left"},R={name:"providerUrl",labelKey:"harvester.tableHeaders.vmMigrationProviderUrl",value:"spec.url",sort:"spec.url",align:"left"},N={name:"sourceProvider",labelKey:"harvester.tableHeaders.vmMigrationMapSourceProvider",value:"spec.provider.source.name",sort:"spec.provider.source.name",align:"left"},P={name:"destProvider",labelKey:"harvester.tableHeaders.vmMigrationMapDestProvider",value:"spec.provider.destination.name",sort:"spec.provider.destination.name",align:"left"},I={name:"targetNamespace",labelKey:"harvester.tableHeaders.vmMigrationPlanTargetNs",value:"spec.targetNamespace",sort:"spec.targetNamespace",align:"left"},M={name:"vmCount",labelKey:"harvester.tableHeaders.vmMigrationPlanVmCount",value:"spec.vms.length",sort:"spec.vms.length",align:"center"},D={name:"plan",labelKey:"harvester.tableHeaders.vmMigrationMigrationPlan",value:"spec.plan.name",sort:"spec.plan.name",align:"left"}},41837:function(e,t,n){"use strict";n.d(t,{AW:function(){return i},Nb:function(){return a},Nu:function(){return l},QD:function(){return c},aS:function(){return r},dt:function(){return h},pG:function(){return u},r4:function(){return d},s4:function(){return s},tB:function(){return p},vU:function(){return o}});const r={BACKUP:"backup",SNAPSHOT:"snapshot"},i={L2VLAN:"L2VlanNetwork",UNTAGGED:"UntaggedNetwork",OVERLAY:"OverlayNetwork",L2TRUNK_VLAN:"L2VlanTrunkNetwork"},o={BLOCK:"Block",FILE_SYSTEM:"Filesystem"},a={READ_WRITE_MANY:"ReadWriteMany",READ_WRITE_ONCE:"ReadWriteOnce",READ_ONLY_MANY:"ReadOnlyMany",READ_WRITE_ONCE_POD:"ReadWriteOncePod"},s={IPv4:"IPv4",IPv6:"IPv6"},l={VMSTATE_PERSISTENCE:"vmstate-persistence",LONGHORN_STATIC:"longhorn-static"},c={ACCESS:"access",TRUNK:"trunk"},u={VMWARE:"vmware",OPENSTACK:"openstack",OVA:"ova"},d={VMWARE:"VmwareSource",OPENSTACK:"OpenstackSource",OVA:"OvaSource"},h={VOLUME_IMPORT_SOURCE:"VolumeImportSource",VOLUME_CLONE_SOURCE:"VolumeCloneSource"},p={CONFIGMAP:"configmap",SECRET:"secret",SERVICEACCOUNT:"serviceaccount"}},7054:function(e,t,n){"use strict";n.r(t);var r=n(9274),i=n(50784),o=n(35664),a=n(32766);jest.mock("../harvester",()=>({__esModule:!0,default:class{}})),jest.mock("@shell/plugins/dashboard-store/resource-class",()=>({colorForState:e=>"Running"===e?"text-success":"text-info",stateSort:(e,t)=>`${e.replace(/^text-/,"")} ${t}`}));const s="ns1/vm1";function l({vm:e={},vmi:t,pods:n=[],pvcs:l=[],restores:c=[],backups:u=[],claims:d=["disk-pvc"],printableStatus:h}={}){const p=(0,r.reactive)({[o.Sm]:n,[o.YH]:l,[a.rk.RESTORE]:c,[a.rk.BACKUP]:u}),f={[a.rk.VMI]:t?[t]:[]},m={all:e=>p[e]||[],byId:(e,t)=>(f[e]||p[e]||[]).find(e=>e.id===t),schemaFor:()=>{}},g=[],v=new Proxy({"harvester-common/getFeatureEnabled":()=>!1},{get(e,t){return g.push(t),e[t]}}),b=Object.create(i["default"].prototype);return Object.assign(b,{id:s,type:a.rk.VM,metadata:{name:"vm1",namespace:"ns1",annotations:{}},spec:{runStrategy:"Always",template:{spec:{domain:{cpu:{cores:1},resources:{limits:{memory:"1Gi"}}},volumes:d.map(e=>({name:e,persistentVolumeClaim:{claimName:e}}))}}},status:{created:!0,ready:!0,printableStatus:h||"Running",conditions:[]},...e}),Object.defineProperty(b,"$rootGetters",{value:v}),Object.defineProperty(b,"$getters",{value:m}),Object.defineProperty(b,"t",{value:e=>e}),{vm:b,lists:p,globalReads:g}}const c=(e={})=>({id:s,metadata:{name:"vm1",namespace:"ns1"},status:{phase:"Running",conditions:[{type:"Ready",status:"True"}],...e}}),u=(e,t,n="ns1")=>({id:`${n}/${e}`,metadata:{name:e,namespace:n},isEncrypted:t});describe("class VirtVm",()=>{describe("restoreResource",()=>{it("should distinguish snapshots from backups and follow backup updates",()=>{const{vm:e,lists:t}=l({vm:{metadata:{namespace:"ns1",name:"vm1",annotations:{"restore.harvesterhci.io/name":"r1"}}},restores:[{id:"ns1/r1",isComplete:!1,spec:{virtualMachineBackupNamespace:"ns1",virtualMachineBackupName:"b1"}}],backups:[{id:"ns2/b1",spec:{type:"snapshot"}},{id:"ns1/b1",spec:{type:"backup"}}]});expect(e.restoreResource.fromSnapshot).toBe(!1),expect(e.restoreState).toBe(!1),t[a.rk.BACKUP][1].spec.type="snapshot",expect(e.restoreResource.fromSnapshot).toBe(!0),t[a.rk.BACKUP].splice(1,1),expect(e.restoreResource.fromSnapshot).toBe(!1),t[a.rk.RESTORE][0].isComplete=!0,expect(e.restoreState).toBe(!0)})}),describe("encryptedVolumeType",()=>{it("should be none without volumes",()=>{const{vm:e}=l({claims:[]});expect(e.encryptedVolumeType).toBe("none")}),it("should be none if no PVC is encrypted",()=>{const{vm:e}=l({pvcs:[u("disk-pvc",!1)]});expect(e.encryptedVolumeType).toBe("none")}),it("should be all if every PVC is encrypted",()=>{const{vm:e}=l({claims:["a","b"],pvcs:[u("a",!0),u("b",!0),u("other",!1)]});expect(e.encryptedVolumeType).toBe("all")}),it("should be partial if some PVCs are encrypted",()=>{const{vm:e}=l({claims:["a","b"],pvcs:[u("a",!0),u("b",!1)]});expect(e.encryptedVolumeType).toBe("partial")}),it("should follow PVCs that are added to the store later",()=>{const{vm:e,lists:t}=l({claims:["a"],pvcs:[]});expect(e.encryptedVolumeType).toBe("none"),t[o.YH].push(u("a",!0)),expect(e.encryptedVolumeType).toBe("all")})}),describe("actualState",()=>{it("should be Off if the VM is halted",()=>{const{vm:e}=l({vm:{spec:{runStrategy:"Halted",template:{spec:{volumes:[],domain:{}}}},status:{created:!1,conditions:[]}}});expect(e.actualState).toBe("Off")}),it("should be Running if the VMI is running and ready",()=>{const{vm:e}=l({vmi:c()});expect(e.actualState).toBe("Running")}),it("should be Not Ready if the VMI is running but not ready",()=>{const{vm:e}=l({vmi:c({conditions:[{type:"Ready",status:"False"}]})});expect(e.actualState).toBe("Not Ready")}),it("should be Paused if the VMI has the Paused condition",()=>{const{vm:e}=l({vmi:c({conditions:[{type:"Ready",status:"True"},{type:"Paused",status:"True"}]})});expect(e.actualState).toBe("Paused")}),it("should be Stopping if the VM is not expected to run anymore but the VMI exists",()=>{const{vm:e}=l({vm:{spec:{runStrategy:"Halted",template:{spec:{volumes:[],domain:{}}}}},vmi:c()});expect(e.actualState).toBe("Stopping")}),it("should be Starting while the launcher pod is not ready",()=>{const{vm:e}=l({vmi:c({phase:"Scheduling",conditions:[]}),pods:[{metadata:{namespace:"ns1",ownerReferences:[{name:"vm1"}]},getPodStatus:{status:"POD_NOT_SCHEDULABLE"}}]});expect(e.actualState).toBe("Starting")}),it("should be Unschedulable if the VM is starting and has an unschedulable condition",()=>{const{vm:e}=l({vmi:c({phase:"Pending",conditions:[]}),vm:{status:{created:!0,conditions:[{reason:"Unschedulable",message:"no node"}]}}});expect(e.actualState).toBe("Unschedulable"),expect(e.isUnschedulable.message).toBe("no node")}),it("should not be Unschedulable without an unschedulable condition",()=>{const{vm:e}=l({vmi:c()});expect(e.isUnschedulable).toBeNull(),expect(e.actualState).toBe("Running")}),it("should not be Unschedulable if the VM is neither starting nor stopping",()=>{const{vm:e}=l({vm:{spec:{runStrategy:"Halted",template:{spec:{volumes:[],domain:{}}}},status:{created:!1,conditions:[{reason:"Unschedulable"}]}}});expect(e.isUnschedulable).toBeNull(),expect(e.actualState).toBe("Off")}),it("should be Terminating if the VM is being deleted",()=>{const{vm:e}=l({vmi:c(),vm:{metadata:{name:"vm1",namespace:"ns1",annotations:{},deletionTimestamp:"now"}}});expect(e.actualState).toBe("Terminating")}),it("should be VM error if the VM has a failure condition",()=>{const{vm:e}=l({vm:{status:{created:!0,conditions:[{type:"Failure",message:"boom"}]}}});expect(e.actualState).toBe("VM error")}),it("should be Restoring while a restore is in progress",()=>{const{vm:e}=l({vmi:c(),vm:{metadata:{name:"vm1",namespace:"ns1",annotations:{"restore.harvesterhci.io/name":"r1"}}},restores:[{id:"ns1/r1",isComplete:!1}]});expect(e.actualState).toBe("Restoring")}),it("should not be Restoring if the restore of the annotation does not exist",()=>{const{vm:e}=l({vmi:c(),vm:{metadata:{name:"vm1",namespace:"ns1",annotations:{"restore.harvesterhci.io/name":"other"}}},restores:[{id:"ns1/r1",isComplete:!1}]});expect(e.actualState).toBe("Running")})}),describe("stateSort",()=>{it("should be built from the same state as stateDisplay and stateColor",()=>{const{vm:e}=l({vmi:c()});expect(e.stateSort).toBe(`${e.stateColor.replace(/^text-/,"")} ${e.stateDisplay}`)}),it("should evaluate the state only once",()=>{const{vm:e}=l({vmi:c()}),t=jest.spyOn(e,"actualState","get");expect(e.stateSort).toBe("success Running"),expect(t).toHaveBeenCalledTimes(1),t.mockRestore()})}),describe("podResource",()=>{it("should find the launcher pod by owner name",()=>{const e={metadata:{namespace:"ns1",ownerReferences:[{name:"vm1"}]}},{vm:t}=l({vmi:c(),pods:[e]});expect(t.podResource).toStrictEqual(e)}),it("should return the last pod if several pods have the same owner",()=>{const e={metadata:{name:"launcher-source",namespace:"ns1",ownerReferences:[{name:"vm1"}]}},t={metadata:{name:"launcher-target",namespace:"ns1",ownerReferences:[{name:"vm1"}]}},{vm:n}=l({vmi:c(),pods:[e,t]});expect(n.podResource.metadata.name).toBe("launcher-target")}),it("should find pods that are added to the store later",()=>{const{vm:e,lists:t}=l({vmi:c(),pods:[]});expect(e.podResource).toBeUndefined();const n={metadata:{namespace:"ns1",ownerReferences:[{name:"vm1"}]}};t[o.Sm].push(n),expect(e.podResource).toStrictEqual(n)}),it("should not return a pod of a VM with the same name in another namespace",()=>{const e={metadata:{namespace:"ns2",ownerReferences:[{name:"vm1"}]}},t={metadata:{namespace:"ns1",ownerReferences:[{name:"vm1"}]}},{vm:n}=l({vmi:c(),pods:[t,e]});expect(n.podResource).toStrictEqual(t)}),it("should not return pods that were removed from the store",()=>{const e={metadata:{namespace:"ns1",ownerReferences:[{name:"vm1"}]}},{vm:t,lists:n}=l({vmi:c(),pods:[e]});expect(t.podResource).toStrictEqual(e),n[o.Sm].splice(0,1),expect(t.podResource).toBeUndefined()})}),describe("store",()=>{it("should read the data of the VM from the store the VM lives in, not from a fixed one",()=>{const e={metadata:{namespace:"ns1",ownerReferences:[{name:"vm1"}]}},{vm:t,globalReads:n}=l({vmi:c(),pods:[e],pvcs:[u("disk-pvc",!1)],restores:[{id:"ns1/r1",isComplete:!0}],vm:{metadata:{name:"vm1",namespace:"ns1",annotations:{"restore.harvesterhci.io/name":"r1"}}}});expect(t.vmi.id).toBe(s),expect(t.podResource).toStrictEqual(e),expect(t.volumes).toHaveLength(1),expect(t.restoreResource.id).toBe("ns1/r1"),expect(t.actualState).toBe("Running"),expect(n.filter(e=>/^(harvester|cluster)\//.test(e))).toStrictEqual([])})}),describe("isRestartRequired",()=>{it("should reflect the RestartRequired condition",()=>{const{vm:e}=l({vm:{status:{conditions:[{type:"RestartRequired",status:"True"}]}}});expect(e.isRestartRequired).toBe(!0)})})})},7915:function(e,t,n){"use strict";n.r(t);var r=n(9274),i=n(79095),o=n(32766),a=n(2602);function s(e,t,n="Running"){return{metadata:{namespace:e,creationTimestamp:t},spec:{vmiName:"vm1"},status:{phase:n}}}function l(e){const t=(0,r.reactive)(e),n=Object.create(i["default"].prototype);return Object.assign(n,{metadata:{namespace:"ns1",name:"vm1",annotations:{[a.r.MIGRATION_STATE]:"Migrating"}},$getters:{all:e=>e===o.rk.VMIM?t:[]}}),{vmi:n,list:t}}jest.mock("../harvester",()=>({__esModule:!0,default:class{}})),jest.mock("@shell/plugins/dashboard-store/resource-class",()=>({colorForState:()=>"text-info"})),describe("class VirtVmInstance",()=>{it("should select the newest migration in the VMI namespace regardless of list order",()=>{const{vmi:e}=l([s("ns1","2026-01-03T00:00:00Z"),s("ns2","2026-01-04T00:00:00Z","Failed"),s("ns1","2026-01-01T00:00:00Z","Failed")]);expect(e.vmimResource.metadata.creationTimestamp).toBe("2026-01-03T00:00:00Z"),expect(e.migrationState.status).toBe("Migrating")}),it("should follow additions, timestamp changes, phase changes and removals in the same list",()=>{const{vmi:e,list:t}=l([]);expect(e.vmimResource).toStrictEqual([]),expect(e.migrationState).toBeNull(),t.push(s("ns1","2026-01-01T00:00:00Z")),expect(e.migrationState.status).toBe("Migrating"),t.push(s("ns1","2026-01-02T00:00:00Z","Failed")),expect(e.migrationState.status).toBe("Failed"),t[0].metadata.creationTimestamp="2026-01-03T00:00:00Z",expect(e.vmimResource).toBe(t[0]),expect(e.migrationState.status).toBe("Migrating"),t[0].status.phase="Failed",expect(e.migrationState.status).toBe("Failed"),t.splice(0,2),expect(e.migrationState).toBeNull()}),it("should follow a migration reassigned to another VMI or namespace",()=>{const{vmi:e,list:t}=l([s("ns1","2026-01-01T00:00:00Z")]);expect(e.migrationState.status).toBe("Migrating"),t[0].spec.vmiName="vm2",expect(e.migrationState).toBeNull(),t[0].spec.vmiName="vm1",t[0].metadata.namespace="ns2",expect(e.migrationState).toBeNull()}),it("should invalidate the index when the store replaces properties on an existing migration",()=>{const{vmi:e,list:t}=l([s("ns1","2026-01-01T00:00:00Z")]);expect(e.migrationState.status).toBe("Migrating");const n=t[0];for(const r of Object.keys(n))delete n[r];Object.assign(n,s("ns2","2026-01-02T00:00:00Z","Failed")),expect(e.migrationState).toBeNull()})})},83727:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(35664),i=n(89865);class o extends i.A{get clusterroletemplatebinding(){return this.$rootGetters["management/byId"](r.Mc.CLUSTER_ROLE_TEMPLATE_BINDING,this.id?.replace(":","/"))}get principalId(){return this.userPrincipalId||this.groupPrincipalId}get roleDisplay(){return this.roleTemplate.nameDisplay}get roleDescription(){return this.roleTemplate.description}get roleTemplate(){return this.$rootGetters["management/byId"](r.Mc.ROLE_TEMPLATE,this.roleTemplateId)}}},17976:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return a}});var r=n(92043),i=n(73883),o=n(24222);class a extends o["default"]{get _availableActions(){let e=super._availableActions;const t=!!this.linkFor("update");return e=e.map(e=>"showConfiguration"===e.action||"goToEditYaml"===e.action?{...e,enabled:!this.spec.enabled}:"goToEdit"===e.action?{...e,enabled:!this.spec.enabled&&["disabled",""].includes(this.configStatus)}:e),e.push({action:"enableConfig",enabled:!this.isEnabled&&t,icon:"icon icon-fw icon-dot",label:"Enable"},{action:"disableConfig",enabled:this.isEnabled&&t,icon:"icon icon-fw icon-dot-open",label:"Disable"}),e}get canYaml(){return!1}get disableResourceDetailDrawer(){return!0}get canDelete(){return!1}get configStatus(){return this.status.status}get actualState(){return this.isEnabled?"Enabled":"Disabled"}get stateDisplay(){return"out-of-sync"===this.configStatus?this.t("harvester.migconfiguration.status.outOfSync"):this.actualState}get stateDescription(){return this.status?.message?this.status.message:super.stateDescription}get stateColor(){return"out-of-sync"===this.configStatus?"text-warning":(0,i.uU)(this.actualState)}get isEnabled(){return this.spec.enabled}get configuredProfiles(){const e=this.spec?.profileSpec?.filter(e=>e.requested>0)||[];return 0===e.length?"":e.map(e=>`${e.name} * ${e.requested}`).join(", ")}async enableConfig(){try{this.spec.enabled=!0,await this.save()}catch(e){this.$dispatch("growl/fromError",{title:this.t("generic.notification.title.error",{name:(0,r.ZD)(this.name)}),err:e},{root:!0})}}async disableConfig(){const{enabled:e}=this.spec;try{this.spec.enabled=!1,await this.save()}catch(t){this.spec.enabled=e,this.$dispatch("growl/fromError",{title:this.t("generic.notification.title.error",{name:(0,r.ZD)(this.name)}),err:t},{root:!0})}}}},66529:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return c}});var r=n(39975),i=n(92043),o=n(32766),a=n(2602),s=n(94741);const l={enabled:{displayKey:"generic.enabled",color:"bg-success"},pending:{displayKey:"generic.inProgress",color:"bg-info"},disabled:{displayKey:"generic.disabled",color:"bg-warning"},error:{displayKey:"generic.disabled",color:"bg-warning"}};class c extends r.A{get _availableActions(){const e=super._availableActions;return e.push({action:"enablePassthroughBulk",enabled:!this.isEnabling&&!this.isvGPUDevice&&this.canUpdate,icon:"icon icon-fw icon-dot",label:"Enable Passthrough",bulkable:!0,bulkAction:"enablePassthroughBulk",weight:1},{action:"disablePassthrough",enabled:this.isEnabling&&this.claimedByMe&&!this.isvGPUDevice&&this.canUpdate,icon:"icon icon-fw icon-dot-open",label:"Disable Passthrough",bulkable:!0,weight:0}),e}get canUpdate(){return!!this.linkFor("update")}get isvGPUDevice(){return!!this.vGPUAsPCIDeviceFeatureEnabled&&!!this.metadata?.labels?.[a.r.PARENT_SRIOV_GPU]}get canYaml(){return!1}get canDelete(){return!1}goToDetail(){return!1}goToEdit(){return!1}get passthroughClaim(){const e=this.$getters["all"](o.rk.PCI_CLAIM)||[];return!!this.status&&e.find(e=>e?.spec?.nodeName===this.status?.nodeName&&e?.spec?.address===this.status?.address)}get uniqueId(){return`${this.status?.vendorId}:${this.status?.deviceId}`}get claimedBy(){return this.passthroughClaim?.spec?.userName}get claimedByMe(){if(!this.passthroughClaim)return!1;const e=(0,s.x)(this.$rootGetters);return this.claimedBy===e}get isEnabled(){return!!this.passthroughClaim?.status?.passthroughEnabled}get isEnabling(){return!!this.passthroughClaim}get claimStatusDisplay(){return this.passthroughClaim?this.isEnabled?l.enabled:l.pending:l.disabled}get stateDisplay(){const e=this.$rootGetters["i18n/t"];return e(this.claimStatusDisplay.displayKey)}get stateBackground(){return this.claimStatusDisplay.color}enablePassthroughBulk(e=this){this.$dispatch("promptModal",{resources:e,component:"EnablePciPassthrough"})}async disablePassthrough(){if(this.allowDisable)try{if(!this.claimedByMe)throw new Error(this.$rootGetters["i18n/t"]("harvester.pci.cantUnclaim",{name:(0,i.ZD)(this.metadata.name)}));await this.passthroughClaim.remove()}catch(e){this.$dispatch("growl/fromError",{title:this.$rootGetters["i18n/t"]("harvester.pci.unclaimError",{name:(0,i.ZD)(this.metadata.name)}),err:e},{root:!0})}else this.showDetachWarning()}get groupByNode(){const e=this.status?.nodeName||this.$rootGetters["i18n/t"]("generic.none");return this.$rootGetters["i18n/t"]("resourceTable.groupLabel.node",{name:(0,i.ZD)(e)})}get groupByDevice(){return this.status?.description}get vGPUAsPCIDeviceFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("vGPUAsPCIDevice")}showDetachWarning(){this.$dispatch("growl/warning",{title:this.$rootGetters["i18n/t"]("harvester.pci.detachWarning.title"),message:this.$rootGetters["i18n/t"]("harvester.pci.detachWarning.message"),timeout:5e3},{root:!0})}get allowDisable(){return this._allowDisable}set allowDisable(e){this._allowDisable=e}}},66325:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(39975);class i extends r.A{cleanForSave(e,t){return e}}},13520:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return c}});var r=n(39975),i=n(92043),o=n(73883),a=n(35664),s=n(2602),l=n(32766);class c extends r.A{get _availableActions(){const e=super._availableActions;return e.push({action:"enableDevice",enabled:!this.isEnabled&&this.canUpdate,icon:"icon icon-fw icon-dot",label:"Enable"},{action:"disableDevice",enabled:this.isEnabled&&this.canUpdate,icon:"icon icon-fw icon-dot-open",label:"Disable"}),e}get canUpdate(){return!!this.linkFor("update")}get canYaml(){return!1}get canDelete(){return!1}goToDetail(){return!1}goToEdit(){return!1}get actualState(){return this.isEnabled?"Enabled":"Disabled"}get stateDisplay(){return this.actualState}get stateColor(){const e=this.actualState;return(0,o.uU)(e)}get isEnabled(){return this.spec.enabled&&this.status?.vfAddresses?.length>0&&this.status?.vGPUDevices?.length>0}get isTimesliced(){return"true"===this.metadata?.annotations?.[s.r.SKIP_MIG_CONFIGURATION]}enableDevice(){this.$dispatch("promptModal",{resources:[this],component:"EnableSriovGpuDevice"})}async disableDevice(){const e=this.$rootGetters["currentProduct"].inStore,t=this.$rootGetters[`${e}/schemaFor`](l.rk.VGPU_DEVICE);if(t){const t=this.$rootGetters[`${e}/all`](l.rk.VGPU_DEVICE)||[],n=t.filter(e=>e.labels[s.r.PARENT_SRIOV_GPU]===this.id&&e.spec?.enabled).map(e=>e.id);if(n.length>0)return void this.$dispatch("growl/error",{title:this.t("generic.notification.title.error",{name:(0,i.ZD)(this.metadata.name)}),message:`\n Cannot disable ${this.metadata.name}, following vGPU devices are enabled:\n [${n.join(", ")}]\n `},{root:!0})}try{this.spec.enabled=!1,await this.save()}catch(n){this.$dispatch("growl/fromError",{title:this.t("generic.notification.title.error",{name:(0,i.ZD)(this.metadata.name)}),err:n},{root:!0})}}get realNodeName(){const e=this.$rootGetters["currentProduct"].inStore,t=this.spec?.nodeName,n=this.$rootGetters[`${e}/all`](a.NW),r=n.find(e=>e.id===t);return r?.nameDisplay||""}get numVFs(){return this.status?.vfAddresses?.length||0}get childDevice(){return l.rk.VGPU_DEVICE}}},75128:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return l}});var r=n(39975),i=n(92043),o=n(73883),a=n(35664),s=n(32766);class l extends r.A{get _availableActions(){const e=super._availableActions;return e.push({action:"enableDevice",enabled:!this.isEnabled,icon:"icon icon-fw icon-dot",label:"Enable"},{action:"disableDevice",enabled:this.isEnabled,icon:"icon icon-fw icon-dot-open",label:"Disable"}),e}get canYaml(){return!1}get canDelete(){return!1}goToDetail(){return!1}goToEdit(){return!1}get actualState(){return this.isEnabled?"Enabled":"Disabled"}get stateDisplay(){return this.actualState}get stateColor(){const e=this.actualState;return(0,o.uU)(e)}get isEnabled(){return"sriovNetworkDeviceEnabled"===this.status?.status&&this.spec?.numVFs>0}enableDevice(e=this){this.$dispatch("promptModal",{resources:e,component:"EnableSriovDevice"})}async disableDevice(){const e=this.spec.numVFs;try{this.spec.numVFs=0,await this.save()}catch(t){this.spec.numVFs=e,this.$dispatch("growl/fromError",{title:this.t("generic.notification.title.error",{name:(0,i.ZD)(this.metadata.name)}),err:t},{root:!0})}}get realNodeName(){const e=this.$rootGetters["currentProduct"].inStore,t=this.spec?.nodeName,n=this.$rootGetters[`${e}/all`](a.NW),r=n.find(e=>e.id===t);return r?.nameDisplay||""}get numVFs(){return this.spec?.numVFs}get childDevice(){return s.rk.PCI_DEVICE}}},95311:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return l}});var r=n(39975),i=n(92043),o=n(32766),a=n(94741);const s={enabled:{displayKey:"generic.enabled",color:"bg-success"},pending:{displayKey:"generic.inProgress",color:"bg-info"},disabled:{displayKey:"generic.disabled",color:"bg-warning"},error:{displayKey:"generic.disabled",color:"bg-warning"}};class l extends r.A{get _availableActions(){const e=super._availableActions;return e.push({action:"enablePassthroughBulk",enabled:!this.passthroughClaim&&!this.status.enabled&&this.canUpdate,icon:"icon icon-fw icon-dot",label:"Enable Passthrough",bulkable:!0,bulkAction:"enablePassthroughBulk",weight:1},{action:"disablePassthrough",enabled:this.status.enabled&&this.canUpdate,icon:"icon icon-fw icon-dot-open",label:"Disable Passthrough",bulkable:!0,weight:0}),e}get canUpdate(){return!!this.linkFor("update")}get canYaml(){return!1}get canDelete(){return!1}goToDetail(){return!1}goToEdit(){return!1}get passthroughClaim(){const e=this.$getters["all"](o.rk.USB_CLAIM)||[];return!!this.status&&e.find(e=>e?.status?.nodeName===this.status?.nodeName&&e?.metadata?.name===this.metadata?.name)}get uniqueId(){return`${this.status?.vendorId}:${this.status?.deviceId}`}get claimedBy(){return this.passthroughClaim?.spec?.userName}get claimedByMe(){if(!this.passthroughClaim)return!1;const e=(0,a.x)(this.$rootGetters);return this.claimedBy===e}get claimStatusDisplay(){return this.passthroughClaim?this.status.enabled?s.enabled:s.pending:s.disabled}get stateDisplay(){const e=this.$rootGetters["i18n/t"];return e(this.claimStatusDisplay.displayKey)}get stateBackground(){return this.claimStatusDisplay.color}enablePassthroughBulk(e=this){this.$dispatch("promptModal",{resources:e,component:"EnableUSBPassthrough"})}async disablePassthrough(){if(this.allowDisable)try{if(!this.claimedByMe)throw new Error(this.$rootGetters["i18n/t"]("harvester.usb.cantUnclaim",{name:(0,i.ZD)(this.metadata.name)}));await this.passthroughClaim.remove()}catch(e){this.$dispatch("growl/fromError",{title:this.$rootGetters["i18n/t"]("harvester.usb.unclaimError",{name:(0,i.ZD)(this.metadata.name)}),err:e},{root:!0})}else this.showDetachWarning()}get groupByNode(){const e=this.status?.nodeName||this.$rootGetters["i18n/t"]("generic.none");return this.$rootGetters["i18n/t"]("resourceTable.groupLabel.node",{name:(0,i.ZD)(e)})}get groupByDevice(){return this.status?.description}showDetachWarning(){this.$dispatch("growl/warning",{title:this.$rootGetters["i18n/t"]("harvester.usb.detachWarning.title"),message:this.$rootGetters["i18n/t"]("harvester.usb.detachWarning.message"),timeout:5e3},{root:!0})}get allowDisable(){return this._allowDisable}set allowDisable(e){this._allowDisable=e}}},17467:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(39975);class i extends r.A{cleanForSave(e,t){return e}}},46505:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return a}});var r=n(39975),i=n(92043);const o={enabled:{displayKey:"generic.enabled",color:"bg-success"},pending:{displayKey:"generic.inProgress",color:"bg-info"},disabled:{displayKey:"generic.disabled",color:"bg-warning"},error:{displayKey:"generic.disabled",color:"bg-warning"}};class a extends r.A{get _availableActions(){const e=super._availableActions,t=!!this.linkFor("update");return e.push({action:"enableVGpu",enabled:!this.isEnabled&&t,icon:"icon icon-fw icon-dot",label:"Enable"},{action:"disableVGpu",enabled:this.isEnabled&&t,icon:"icon icon-fw icon-dot-open",label:"Disable",bulkable:!0}),e}get canYaml(){return!1}get canDelete(){return!1}goToDetail(){return!1}goToEdit(){return!1}get isEnabled(){return!0===this?.spec?.enabled}get isEnabling(){return this.status?.vGPUStatus&&"vGPUConfigured"!==this.status?.vGPUStatus}get statusDisplay(){return this.isEnabling?o.pending:this.isEnabled?o.enabled:o.disabled}get stateDisplay(){const e=this.$rootGetters["i18n/t"];return e(this.statusDisplay.displayKey)}get stateBackground(){return this.statusDisplay.color}enableVGpu(e=this){this.$dispatch("promptModal",{resources:e,component:"EnableVGpuDevice"})}async disableVGpu(){if(!this.allowDisable)return void this.showDetachWarning();const{vGPUTypeName:e,enabled:t}=this.spec;try{this.spec.vGPUTypeName=void 0,this.spec.enabled=!1,await this.save()}catch(n){this.spec.vGPUTypeName=e,this.spec.enabled=t,this.$dispatch("growl/fromError",{title:this.t("generic.notification.title.error",{name:(0,i.ZD)(this.metadata.name)}),err:n},{root:!0})}}get groupByNode(){const e=this.spec?.nodeName||this.$rootGetters["i18n/t"]("generic.none");return this.$rootGetters["i18n/t"]("resourceTable.groupLabel.node",{name:(0,i.ZD)(e)})}get vGpuAvailableTypes(){return this.status?.availableTypes?Object.keys(this.status.availableTypes):[]}showDetachWarning(){this.$dispatch("growl/warning",{title:this.$rootGetters["i18n/t"]("harvester.vgpu.detachWarning.title"),message:this.$rootGetters["i18n/t"]("harvester.vgpu.detachWarning.message"),timeout:5e3},{root:!0})}get allowDisable(){return this._allowDisable}set allowDisable(e){this._allowDisable=e}}},94175:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return s}});var r=n(24222),i=n(32766),o=n(20652),a=n(92043);class s extends r["default"]{get listLocation(){return{name:`${o.KR}-c-cluster-vm-migration`,params:{product:this.$rootGetters["productId"],cluster:this.$rootGetters["clusterId"]}}}get doneOverride(){}get planFailed(){const e=this.status?.conditions||[];return e.some(e=>"Failed"===e.type&&"True"===e.status)}get planCritical(){const e=this.status?.conditions||[];return e.some(e=>"Critical"===e.category&&"True"===e.status)}get criticalMessages(){const e=this.status?.conditions||[];return e.filter(e=>"Critical"===e.category&&"True"===e.status).map(e=>e.message)}get stateDescription(){if(this.metadata?.deletionTimestamp)return null;const e=[],t=this.status?.conditions||[];if(this.planFailed){const n=t.find(e=>"Failed"===e.type&&"True"===e.status)?.message;n&&e.push(n)}return this.planCritical&&e.push(...this.criticalMessages),e.length>0?e.join(" "):null}get stateObj(){return{error:this.planFailed||this.planCritical,transitioning:this.isMigrating||this.isPendingMigrationStart||!!this.metadata?.deletionTimestamp,message:this.stateDescription}}get isMigrating(){const e=this.status?.migration;return!!e?.started&&!e?.completed}get isPendingMigrationStart(){const e=this.spec?.vms?.length||0;return e>0&&!this.planFailed&&!this.planCritical&&!this.planCanceled&&!this.planSucceeded&&!this.isMigrating}get planCanceled(){const e=this.status?.migration?.history||[];if(0===e.length)return!1;const t=e[e.length-1],n=t.conditions||[];return n.some(e=>"Canceled"===e.type&&"True"===e.status)}get planSucceeded(){const e=this.status?.migration;return!!e?.completed&&!this.planFailed&&!this.planCanceled}get stateDisplay(){return this.metadata?.deletionTimestamp?"Terminating":this.planFailed||this.planCritical?this.t("harvester.addons.vmMigration.plan.states.error"):this.planCanceled?this.t("harvester.addons.vmMigration.plan.states.canceled"):this.isMigrating||this.isPendingMigrationStart?this.t("harvester.addons.vmMigration.plan.states.inProgress"):this.t("harvester.addons.vmMigration.plan.states.active")}get stateBackground(){return this.metadata?.deletionTimestamp?"bg-info":this.planFailed||this.planCritical?"bg-error":this.planCanceled?"bg-warning":this.isMigrating||this.isPendingMigrationStart?"bg-info":"bg-success"}get isForkliftDashboard(){const e=this.currentRouter()?.currentRoute?.value;return e?.name?.endsWith("-vm-migration")}get _availableActions(){const e=this.isMigrating&&!this.planCanceled,t=!this.planSucceeded&&(!this.isMigrating||this.planFailed||this.planCanceled||this.planCritical),n=[];return t&&n.push({action:"startMigration",enabled:!0,icon:"icon icon-play",label:this.isForkliftDashboard?this.t("harvester.addons.vmMigration.plan.actions.restart"):this.t("harvester.addons.vmMigration.plan.actions.start")}),e&&n.push({action:"stopMigration",enabled:!0,icon:"icon icon-pause",label:this.t("harvester.addons.vmMigration.plan.actions.stop")}),this.isForkliftDashboard?(n.push({action:"promptRemove",altAction:"remove",label:this.t("action.remove"),icon:"icon icon-trash",bulkable:!0,enabled:this.canDelete,bulkAction:"promptRemove",weight:-10}),n):(n.push(...super._availableActions),n)}async stopMigration(){const e=this.status?.migration?.history||[];if(0===e.length)return;const t=e[e.length-1],n=t.migration?.name;if(n){const e=this.linkFor("self"),t=e.replace("forklift.konveyor.io.plans","forklift.konveyor.io.migrations").replace(`/${this.metadata.name}`,`/${n}`);await this.$dispatch("request",{url:t,method:"DELETE"})}}async startMigration(){const e=this.metadata.namespace,t=this.status?.migration?.history||[];for(const i of t){const e=i.migration?.name;if(e){const t=this.linkFor("self"),n=t.replace("forklift.konveyor.io.plans","forklift.konveyor.io.migrations").replace(`/${this.metadata.name}`,`/${e}`);try{await this.$dispatch("request",{url:n,method:"DELETE"})}catch(r){}}}const n=await this.$dispatch("create",{type:i.rk.FORKLIFT_MIGRATION,metadata:{name:`${this.metadata.name}-migration-${(0,a.vx)(5).toLowerCase()}`,namespace:e,ownerReferences:[{apiVersion:"forklift.konveyor.io/v1beta1",kind:"Plan",name:this.metadata.name,uid:this.metadata.uid,blockOwnerDeletion:!0}]},spec:{plan:{apiVersion:"forklift.konveyor.io/v1beta1",kind:"Plan",name:this.metadata.name,namespace:e}}});await n.save()}async deletePlan(){await this.remove()}}},89553:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(24222),i=n(20652);class o extends r["default"]{get _createLocation(){return{name:`${i.KR}-c-cluster-vm-migration-provider-wizard`,params:{product:this.$rootGetters["productId"],cluster:this.$rootGetters["clusterId"]}}}get _editLocation(){return{name:`${i.KR}-c-cluster-vm-migration-provider-wizard`,params:{product:this.$rootGetters["productId"],cluster:this.$rootGetters["clusterId"]},query:{providerId:`${this.metadata.namespace}/${this.metadata.name}`}}}remove(e={}){return e.params={...e.params||{},propagationPolicy:"Foreground"},this._remove(e)}}},24222:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return s}});var r=n(39975),i=n(41476),o=n(20652),a=n(66905);class s extends r.A{get listLocation(){const e=this.harvesterResourcesInExplorer?"c-cluster-product-resource":`${o.KR}-c-cluster-resource`,t=a.Ih[this.type]||this.type;return this.$rootGetters["type-map/optionsFor"](this.type).customRoute||{name:e,params:{product:this.$rootGetters["productId"],cluster:this.$rootGetters["clusterId"],resource:t}}}get parentLocationOverride(){return this.listLocation}get doneRoute(){return this.listLocation.name}get doneOverride(){return this.listLocation}get harvesterResourcesInExplorer(){return this.$rootGetters["productId"]!==o.KR}get _detailLocation(){const e=this.$getters["schemaFor"](this.type),t=this.id?.replace(/.*\//,""),n=this.harvesterResourcesInExplorer?`c-cluster-product-resource${e?.attributes?.namespaced?"-namespace":""}-id`:`${o.KR}-c-cluster-resource${e?.attributes?.namespaced?"-namespace":""}-id`,r={name:n,params:{product:this.$rootGetters["productId"],cluster:this.$rootGetters["clusterId"],resource:this.type,namespace:this.metadata?.namespace,id:t}};return this.harvesterResourcesInExplorer&&(r.query={as:"yaml"}),r}get forceYaml(){return this.harvesterResourcesInExplorer}get canViewInApi(){try{return this.hasLink("self")&&this.$rootGetters["prefs/get"](i.HZ)}catch{return this.hasLink("self")&&this.$rootGetters["prefs/get"](i.IJ)}}get resourcesCardRows(){return[]}cleanForSave(e,t){return e}}},24481:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return s}});var r=n(76978),i=n(32766),o=n(24222),a=n(20652);class s extends o["default"]{get detailLocation(){const e=(0,r.o8)(this._detailLocation);return e.params.resource=i.rk.CLOUD_TEMPLATE,e}get doneOverride(){const e=(0,r.o8)(this._detailLocation);return delete e.params.namespace,delete e.params.id,e.params.resource=i.rk.CLOUD_TEMPLATE,e.name=`${a.KR}-c-cluster-resource`,e}get parentNameOverride(){return this.$rootGetters["i18n/t"](`typeLabel."${i.rk.CLOUD_TEMPLATE}"`,{count:1})?.trim()}get parentLocationOverride(){return this.doneOverride}}},4987:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return l}});var r=n(76978),i=n(43842),o=n(32766),a=n(20652);const s="Not Ready";class l extends i["default"]{get listLocation(){return this.$rootGetters["type-map/optionsFor"](this.type).customRoute||{name:`${a.KR}-c-cluster-resource`,params:{product:a.KR,cluster:this.$rootGetters["clusterId"],resource:o.rk.NETWORK_ATTACHMENT}}}get doneRoute(){return this.listLocation.name}get detailLocation(){const e=(0,r.o8)(this._detailLocation);return e.params.resource=o.rk.NETWORK_ATTACHMENT,e.name=`${a.KR}-c-cluster-resource-namespace-id`,e}get doneOverride(){const e=(0,r.o8)(this._detailLocation);return delete e.params.namespace,delete e.params.id,e.params.resource=o.rk.NETWORK_ATTACHMENT,e.name=`${a.KR}-c-cluster-resource`,e}get parentNameOverride(){return this.$rootGetters["i18n/t"](`typeLabel."${o.rk.NETWORK_ATTACHMENT}"`,{count:1})?.trim()}get parentLocationOverride(){return this.doneOverride}get inStore(){return this.$rootGetters["currentProduct"].inStore}get clusterNetworkResource(){const e=this.$rootGetters[`${this.inStore}/all`](o.rk.CLUSTER_NETWORK);return e.find(e=>e.id===this.clusterNetwork)}get clusterNetworkErrorMessage(){return this.clusterNetworkResource?this.clusterNetworkResource.isReady?"":this.t("harvester.clusterNetwork.notReady",{clusterNetwork:this.clusterNetwork}):this.t("harvester.clusterNetwork.notExist",{clusterNetwork:this.clusterNetwork})}get stateDisplay(){return this.clusterNetworkErrorMessage?s:super.stateDisplay}get stateBackground(){return this.stateDisplay===s?"bg-warning":super.stateBackground}get isNotReady(){return this.clusterNetworkErrorMessage}}},50826:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return l}});var r=n(76978),i=n(35664),o=n(32766),a=n(20652),s=n(40322);class l extends s["default"]{get allOutputs(){return this.$rootGetters["harvester/all"](i.cm.CLUSTER_OUTPUT)||[]}get listLocation(){const e=(0,r.o8)(super.listLocation);return e.name=this.harvesterResourcesInExplorer?"c-cluster-product-resource":`${a.KR}-c-cluster-resource`,e.params.resource=o.rk.CLUSTER_FLOW,e}get harvesterResourcesInExplorer(){return this.$rootGetters["productId"]!==a.KR}get _detailLocation(){const e=this.$getters["schemaFor"](this.type),t=this.id?.replace(/.*\//,"");return{name:`${a.KR}-c-cluster-resource${e?.attributes?.namespaced?"-namespace":""}-id`,params:{product:a.KR,cluster:this.$rootGetters["clusterId"],resource:this.type,id:t,namespace:this.metadata.namespace}}}get detailLocation(){const e=(0,r.o8)(this._detailLocation);return e.params.resource=o.rk.CLUSTER_FLOW,e}get doneOverride(){const e=(0,r.o8)(this._detailLocation);return delete e.params.namespace,delete e.params.id,e.params.resource=o.rk.CLUSTER_FLOW,e.name=`${a.KR}-c-cluster-resource`,e}get parentNameOverride(){return this.$rootGetters["i18n/t"](`typeLabel."${o.rk.CLUSTER_FLOW}"`,{count:1})?.trim()}get parentLocationOverride(){return this.doneOverride}}},49039:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return s}});var r=n(76978),i=n(32766),o=n(20652),a=n(15895);class s extends a["default"]{get _detailLocation(){const e=this.$getters["schemaFor"](this.type),t=this.id?.replace(/.*\//,"");return{name:`${o.KR}-c-cluster-resource${e?.attributes?.namespaced?"-namespace":""}-id`,params:{product:o.KR,cluster:this.$rootGetters["clusterId"],resource:this.type,id:t,namespace:this.metadata.namespace}}}get listLocation(){const e=(0,r.o8)(super.listLocation);return e.name=this.harvesterResourcesInExplorer?"c-cluster-product-resource":`${o.KR}-c-cluster-resource`,e.params.resource=i.rk.CLUSTER_OUTPUT,e}get harvesterResourcesInExplorer(){return this.$rootGetters["productId"]!==o.KR}get detailLocation(){const e=(0,r.o8)(this._detailLocation);return e.params.resource=i.rk.CLUSTER_OUTPUT,e}get doneOverride(){const e=(0,r.o8)(this._detailLocation);return delete e.params.namespace,delete e.params.id,e.params.resource=i.rk.CLUSTER_OUTPUT,e.name=`${o.KR}-c-cluster-resource`,e}get parentNameOverride(){return this.$rootGetters["i18n/t"](`typeLabel."${i.rk.CLUSTER_OUTPUT}"`,{count:1})?.trim()}get parentLocationOverride(){return this.doneOverride}}},40322:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return c}});var r=n(35664),i=n(76978),o=n(21766),a=n(32766),s=n(20652),l=n(66905);class c extends o["default"]{get allOutputs(){return this.$rootGetters["harvester/all"](r.cm.OUTPUT)||[]}get allClusterOutputs(){return this.$rootGetters["harvester/all"](r.cm.CLUSTER_OUTPUT)||[]}get listLocation(){const e=(0,i.o8)(super.listLocation);return e.name=this.harvesterResourcesInExplorer?"c-cluster-product-resource":`${s.KR}-c-cluster-resource`,e.params.resource=a.rk.FLOW,e}get harvesterResourcesInExplorer(){return this.$rootGetters["productId"]!==s.KR}get _detailLocation(){const e=this.$getters["schemaFor"](this.type),t=this.id?.replace(/.*\//,"");return{name:`${s.KR}-c-cluster-resource${e?.attributes?.namespaced?"-namespace":""}-id`,params:{product:s.KR,cluster:this.$rootGetters["clusterId"],resource:this.type,id:t,namespace:this.metadata.namespace}}}get detailLocation(){const e=(0,i.o8)(this._detailLocation);return e.params.resource=a.rk.FLOW,e}get doneOverride(){const e=(0,i.o8)(this._detailLocation);return delete e.params.namespace,delete e.params.id,e.params.resource=a.rk.FLOW,e.name=`${s.KR}-c-cluster-resource`,e}get parentNameOverride(){return this.$rootGetters["i18n/t"](`typeLabel."${a.rk.FLOW}"`,{count:1})?.trim()}get parentLocationOverride(){return this.doneOverride}get loggingType(){return"harvester-kube-audit-log-ref"===this.spec.loggingRef?l.UQ.AUDIT:(this.spec.match||[]).find(e=>!!e?.select?.labels?.["app.kubernetes.io/name"])?l.UQ.EVENT:l.UQ.LOGGING}}},15895:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return l}});var r=n(76978),i=n(44931),o=n(32766),a=n(20652),s=n(66905);class l extends i["default"]{get _detailLocation(){const e=this.$getters["schemaFor"](this.type),t=this.id?.replace(/.*\//,"");return{name:`${a.KR}-c-cluster-resource${e?.attributes?.namespaced?"-namespace":""}-id`,params:{product:a.KR,cluster:this.$rootGetters["clusterId"],resource:this.type,id:t,namespace:this.metadata.namespace}}}get listLocation(){const e=(0,r.o8)(super.listLocation);return e.name=this.harvesterResourcesInExplorer?"c-cluster-product-resource":`${a.KR}-c-cluster-resource`,e.params.resource=o.rk.OUTPUT,e}get harvesterResourcesInExplorer(){return this.$rootGetters["productId"]!==a.KR}get detailLocation(){const e=(0,r.o8)(this._detailLocation);return e.params.resource=o.rk.OUTPUT,e}get doneOverride(){const e=(0,r.o8)(this._detailLocation);return delete e.params.namespace,delete e.params.id,e.params.resource=o.rk.OUTPUT,e.name=`${a.KR}-c-cluster-resource`,e}get parentNameOverride(){return this.$rootGetters["i18n/t"](`typeLabel."${o.rk.OUTPUT}"`,{count:1})?.trim()}get parentLocationOverride(){return this.doneOverride}get url(){return this.detailLocation}get loggingType(){return"harvester-kube-audit-log-ref"===this.spec.loggingRef?s.UQ.AUDIT:s.UQ.LOGGING}}},65073:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return s}});var r=n(76978),i=n(76061),o=n(32766),a=n(20652);class s extends i["default"]{get detailLocation(){const e=(0,r.o8)(this._detailLocation);return e.params.resource=o.rk.SETTING,e}get doneOverride(){const e=(0,r.o8)(this._detailLocation);return delete e.params.namespace,delete e.params.id,e.params.resource=o.rk.SETTING,e.name=`${a.KR}-c-cluster-resource`,e}get doneRoute(){return null}get parentNameOverride(){return this.$rootGetters["i18n/t"](`typeLabel."${o.rk.SETTING}"`,{count:1})?.trim()}get parentLocationOverride(){return this.doneOverride}get doneParams(){return{product:this.$rootGetters["productId"],cluster:this.$rootGetters["clusterId"],resource:o.rk.SETTING}}}},53942:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return l}});var r=n(76978),i=n(14220),o=n(39975),a=n(32766),s=n(20652);class l extends o.A{get _detailLocation(){return{name:this.alertmanagerConfigDoneRouteName,params:{cluster:this.$rootGetters["clusterId"],resource:a.rk.ALERTMANAGERCONFIG,namespace:this.metadata?.namespace,id:this.name},hash:"#receivers",query:{as:"config"}}}get listLocation(){const e=(0,r.o8)(super.listLocation);return e.name=this.harvesterResourcesInExplorer?"c-cluster-product-resource":`${s.KR}-c-cluster-resource`,e.params.resource=a.rk.ALERTMANAGERCONFIG,e}get harvesterResourcesInExplorer(){return this.$rootGetters["productId"]!==s.KR}get doneOverride(){const e=(0,r.o8)(this._detailLocation);return delete e.params.namespace,delete e.params.id,e.params.resource=a.rk.ALERTMANAGERCONFIG,e.name=`${s.KR}-c-cluster-resource`,e}get parentNameOverride(){return this.$rootGetters["i18n/t"](`typeLabel."${a.rk.ALERTMANAGERCONFIG}"`,{count:1})?.trim()}get parentLocationOverride(){return this.doneOverride}applyDefaults(){if(this.spec)return this.spec;const e=this.spec?.route?.receivers||[],t={receivers:[...e],route:{receivers:this.spec?.route?.receivers||[],groupBy:this.spec?.route?.groupBy||[],groupWait:this.spec?.route?.groupWait||"30s",groupInterval:this.spec?.route?.groupInterval||"5m",repeatInterval:this.spec?.route?.repeatInterval||"4h",match:this.spec?.route?.match||{},matchRe:this.spec?.route?.matchRe||{}}};(0,r.hZ)(this,"spec",t)}get _availableActions(){const e=super._availableActions;return e}getReceiverActions(e){return e.filter(e=>{if(e.divider)return!0;switch(e.action){case"goToEdit":return!0;case"goToEditYaml":return!0;case"promptRemove":return!0;default:return!1}})}get alertmanagerConfigDoneRouteName(){return`${s.KR}-c-cluster-resource-namespace-id`}getCreateReceiverRoute(){return{name:`${s.KR}-c-cluster-alertmanagerconfig-alertmanagerconfigid-receiver`,params:{cluster:this.$rootGetters["clusterId"],alertmanagerconfigid:this.id},query:{mode:i.YQ,currentView:i.au}}}getReceiverDetailLink(e){return{name:`${s.KR}-c-cluster-alertmanagerconfig-alertmanagerconfigid-receiver`,params:{cluster:this.$rootGetters["clusterId"],alertmanagerconfigid:this.id,receiverName:e},query:{mode:i.nW,receiverName:e,currentView:i.au}}}getEditReceiverYamlRoute(e,t){return{name:`${s.KR}-c-cluster-alertmanagerconfig-alertmanagerconfigid-receiver`,params:{cluster:this.$rootGetters["clusterId"],alertmanagerconfigid:this.id},query:{mode:t||i.nW,receiverName:e,currentView:i.zD}}}getEditReceiverConfigRoute(e,t){return{name:`${s.KR}-c-cluster-alertmanagerconfig-alertmanagerconfigid-receiver`,params:{cluster:this.$rootGetters["clusterId"],alertmanagerconfigid:this.id},query:{mode:t||i.nW,receiverName:e,currentView:i.au}}}}},62878:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return p}});var r=n(68851),i=n(67867),o=n(2841),a=n(71025),s=n(76978),l=n(35664),c=n(20652),u=n(66905),d=n(32766);const h=["c-","p-","user-","local"];class p extends i["default"]{get _availableActions(){let e=super._availableActions;const t=e.findIndex(e=>"promptRemove"===e.action),n={action:"promptRemove",altAction:"remove",label:this.t("action.remove"),icon:"icon icon-trash",bulkable:!0,enabled:this.canDelete,bulkAction:"promptRemove",weight:-10},i={action:"editNSQuota",label:this.t("harvester.modal.quota.editQuota"),icon:"icon icon-storage",enabled:!!this?.actions?.updateResourceQuota&&!!this?.actions?.deleteResourceQuota,weight:-11};t>-1&&e.splice(t,1),(0,r.PT)(e,e.length-1,n),(0,r.PT)(e,e.length-5,i);const o=!!this.linkFor("update");return e=e.map(e=>["move"].includes(e.action)?{...e,enabled:e.enabled&&o}:e),e}editNSQuota(e=this){this.$dispatch("promptModal",{resources:e,snapshotSizeQuota:this.snapshotSizeQuota,component:"HarvesterQuotaDialog"})}promptRemove(e=this){this.$dispatch("promptModal",{resources:e,component:"ConfirmRelatedToRemoveDialog"})}get nsResourceQuota(){const e=this.$rootGetters["currentProduct"].inStore,t=this.$rootGetters[`${e}/all`](d.rk.RESOURCE_QUOTA);return t.find(e=>e.metadata.namespace===this.id)}get snapshotSizeQuota(){return this.nsResourceQuota?.spec?.snapshotLimit?.namespaceTotalSnapshotSizeQuota}get isSystem(){if(this.metadata?.name===u.Ex)return!1;const e=["fleet-default"];if(e.includes(this.metadata.name))return!0;if("true"===this.metadata?.annotations?.[o.eG])return!0;if(a.A.includes(this.metadata.name))return!0;if(this.metadata.name.endsWith("-system"))return!0;if(this.project)return this.project.isSystem;if("true"===(0,s.Jt)(this,`metadata.labels."${o.Hs.MANAGED}"`))return!0;const t=this.$rootGetters["systemNamespaces"].includes(this.metadata.name),n=!!h.some(e=>this.metadata.name.startsWith(e));return t||n}get detailLocation(){const e=this.id?.replace(/.*\//,""),t={name:`${c.KR}-c-cluster-resource-id`,params:{product:this.$rootGetters["productId"],cluster:this.$rootGetters["clusterId"],resource:l.CU,namespace:this.metadata?.namespace,id:e}};return t}get hideDetailLocation(){return!!this.$rootGetters["currentProduct"].hideNamespaceLocation}}},55285:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return C}});var r=n(16735),i=n.n(r),o=n(35664),a=n(2841),s=n(2602),l=n(76978),c=n(24576),u=n.n(c),d=n(73883),h=n(95799),p=n(68851),f=n(92043),m=n(24222),g=n(20652),v=n(32766);const b=["topology.kubernetes.io/zone","topology.kubernetes.io/region"],y="healthy",w="warning",O="MaintenanceMode",S="Error",E=["Validating","Draining","Evacuating"],x="Completed",_="running",k="completed";class C extends m["default"]{get _availableActions(){const e={action:"cordon",enabled:this.hasAction("cordon")&&!this.isCordoned,icon:"icon icon-fw icon-pause",label:this.t("harvester.action.cordon"),total:1},t={action:"uncordon",enabled:this.hasAction("uncordon"),icon:"icon icon-fw icon-play",label:this.t("harvester.action.uncordon"),total:1},n={action:"enableMaintenanceMode",enabled:this.hasAction("enableMaintenanceMode"),icon:"icon icon-fw icon-unlock",label:this.t("harvester.action.enableMaintenance"),total:1},r={action:"disableMaintenanceMode",enabled:this.hasAction("disableMaintenanceMode"),icon:"icon icon-fw icon-lock",label:this.t("harvester.action.disableMaintenance"),total:1},i={action:"clearMaintenanceMode",enabled:this.hasAction("clearMaintenanceMode"),icon:"icon icon-fw icon-close",label:this.t("harvester.action.clearMaintenance"),total:1},o={action:"enableCPUManager",enabled:this.cpuPinningFeatureEnabled&&this.hasAction("enableCPUManager")&&!this.isCPUManagerEnableInProgress&&!this.isCPUManagerEnabled&&!this.isEtcd,icon:"icon icon-fw icon-os-management",label:this.t("harvester.action.enableCPUManager"),total:1},a={action:"disableCPUManager",enabled:this.cpuPinningFeatureEnabled&&this.hasAction("disableCPUManager")&&!this.isCPUManagerEnableInProgress&&this.isCPUManagerEnabled&&!this.isEtcd,icon:"icon icon-fw icon-os-management",label:this.t("harvester.action.disableCPUManager"),total:1},s={action:"shutDown",enabled:this.hasAction("powerActionPossible")&&this.hasAction("powerAction")&&!this.isStopped&&!!this.inventory,icon:"icon icon-fw icon-dot",label:this.t("harvester.action.shutdown"),total:1},l={action:"powerOn",enabled:this.hasAction("powerActionPossible")&&this.hasAction("powerAction")&&this.isStopped&&!!this.inventory,icon:"icon icon-fw icon-play",label:this.t("harvester.action.powerOn"),total:1},c={action:"reboot",enabled:this.hasAction("powerActionPossible")&&this.hasAction("powerAction")&&!this.isStopped&&!!this.inventory,icon:"icon icon-fw icon-refresh",label:this.t("harvester.action.reboot"),total:1};return[e,t,n,r,i,o,a,s,l,c,...super._availableActions]}promptRemove(e=this){this.$dispatch("promptModal",{resources:e,component:"ConfirmRelatedToRemoveDialog"})}remove(e=this){const t=Array.isArray(e)?e:[e];t.forEach(e=>{e.capiMachine?e.capiMachine.remove():e.remove()})}get capiMachine(){const e=this.annotations?.[a.qt.CLUSTER_NAMESPACE],t=this.annotations?.[a.qt.MACHINE_NAME];if(e&&t){const n=this.$rootGetters["currentProduct"].inStore;return this.$rootGetters[`${n}/byId`](o.Z7.MACHINE,`${e}/${t}`)}return null}get confirmRemove(){return!0}get consoleUrl(){const e=this.metadata?.annotations?.[s.r.HOST_CONSOLE_URL],t=/^[a-z]+:\/\//;return!!e?.match(t)&&e}get filteredSystemLabels(){const e=/(k3s|kubernetes|kubevirt|harvesterhci|k3os)+\.io/,t=i()(this.labels,(t,n)=>!e.test(n));return b.map(e=>{const n=this?.metadata?.labels?.[e];n&&(t[e]=n)}),t}get nameDisplay(){return this.metadata?.annotations?.[s.r.HOST_CUSTOM_NAME]||this.name}get isKVMDisable(){const e=this.metadata.labels?.[s.r.K8S_ARCH]?.includes("arm");if(e)return this.status.capacity["devices.kubevirt.io/kvm"]&&"0"===this.status.capacity["devices.kubevirt.io/kvm"];const t=!this.metadata?.labels?.[s.r.KVM_AMD_CPU]&&!this.metadata?.labels?.[s.r.KVM_INTEL_CPU];return t||"false"===this.metadata?.labels?.[s.r.KVM_AMD_CPU]||"false"===this.metadata?.labels?.[s.r.KVM_INTEL_CPU]}get stateDisplay(){return this.isMaintenanceModeError?super.stateDisplay:this.isEnteringMaintenance?"Entering maintenance mode":this.isStopping?(0,f.TF)(d.jv.STOPPING):this.isStarting?(0,f.TF)(d.jv.STARTING):this.isStopped?(0,f.TF)(d.jv.OFF):this.isRebooting?"Rebooting":this.isMaintenance?"Maintenance":this.isCordoned?"Cordoned":(0,d.ch)(this.state)}get stateBackground(){return this.isStopped||this.isStopping||this.isStarting||this.isRebooting?(0,d.uU)(this.stateDisplay,!1,this.stateObj?.transitioning).replace("text-","bg-"):(0,d.uU)(this.stateDisplay,this.stateObj?.error,this.stateObj?.transitioning).replace("text-","bg-")}get stateDescription(){if(this.isMaintenanceModeError)return super.stateDescription;const e=this.metadata?.annotations?.[s.r.CURRENT_IP],t=this.metadata?.annotations?.[s.r.INIT_IP];return t&&e&&e!==t?this.t("harvester.host.inconsistentIP",{currentIP:e,initIP:t}):super.stateDescription}get stateObj(){const e=this.metadata?.annotations?.[s.r.CURRENT_IP],t=this.metadata?.annotations?.[s.r.INIT_IP];return t&&e&&e!==t&&(this.metadata.state.error=!0),this.metadata?.state}get detailLocation(){const e=(0,l.o8)(this._detailLocation);return e.params.resource=v.rk.HOST,e}get doneOverride(){const e=(0,l.o8)(this._detailLocation);return delete e.params.namespace,delete e.params.id,e.params.resource=v.rk.HOST,e.name=`${g.KR}-c-cluster-resource`,e}get parentNameOverride(){return this.$rootGetters["i18n/t"](`typeLabel."${v.rk.HOST}"`,{count:1})?.trim()}get parentLocationOverride(){return this.doneOverride}get internalIp(){const e=this.status?.addresses||[];return u()(e,e=>"InternalIP"===e.type)?.address}get isMaster(){return void 0!==this.metadata?.labels?.[s.r.NODE_ROLE_MASTER]||void 0!==this.metadata?.labels?.[s.r.NODE_ROLE_CONTROL_PLANE]}cordon(){this.doActionGrowl("cordon",{})}uncordon(){this.doAction("uncordon",{})}enableMaintenanceMode(e=this){this.$dispatch("promptModal",{resources:e,component:"HarvesterMaintenanceDialog"})}disableMaintenanceMode(){this.doActionGrowl("disableMaintenanceMode",{})}clearMaintenanceMode(){this.doActionGrowl("clearMaintenanceMode",{})}enableCPUManager(){this.doActionGrowl("enableCPUManager",{})}disableCPUManager(){this.doActionGrowl("disableCPUManager",{})}get isUnSchedulable(){return"false"===this.metadata?.labels?.[s.r.NODE_SCHEDULABLE]||this.spec.unschedulable}get maintenanceModeCondition(){return(this.status?.conditions||[]).find(e=>e.type===O)}get maintenanceModeConditionsEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("maintenanceModeConditions")}get legacyMaintenanceStatus(){return this.metadata?.annotations?.[s.r.MAINTENANCE_STATUS]}get isMaintenanceModeError(){return this.maintenanceModeConditionsEnabled&&this.maintenanceModeCondition?.reason===S}get isMigratable(){const e=["in-progress","unavailable"],t=this.maintenanceModeConditionsEnabled?"True"===this.maintenanceModeCondition?.status:!!this.legacyMaintenanceStatus;return!t&&!this.isUnSchedulable&&!e.includes(this.state)}get isCordoned(){return this.hasAction("uncordon")}get isEtcd(){return this.metadata?.labels?.[s.r.NODE_ROLE_ETCD]}get isEnteringMaintenance(){if(!this.maintenanceModeConditionsEnabled)return this.legacyMaintenanceStatus===_;const e=this.maintenanceModeCondition;return"True"===e?.status&&E.includes(e?.reason)}get isMaintenance(){if(!this.maintenanceModeConditionsEnabled)return this.legacyMaintenanceStatus===k;const e=this.maintenanceModeCondition;return"True"===e?.status&&e?.reason===x}get cpuPinningFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("cpuPinning")}get isCPUManagerEnabled(){return"true"===this.metadata?.labels?.[s.r.CPU_MANAGER]}get isCPUManagerEnableInProgress(){return"requested"===this.cpuManagerUpdateStatus||"running"===this.cpuManagerUpdateStatus}get isCPUManagerEnableFailed(){return"failed"===this.cpuManagerUpdateStatus}get cpuManagerUpdateStatus(){try{const e=JSON.parse(this.metadata.annotations[s.r.NODE_CPU_MANAGER_UPDATE_STATUS]||"{}");return e.status||""}catch{return""}}get longhornDisks(){const e=this.$rootGetters["currentProduct"].inStore,t=this.$rootGetters[`${e}/byId`](o.oe.NODES,`longhorn-system/${this.id}`),n=t?.status?.diskStatus||{},r=t?.spec?.disks||{},i=Object.keys(n).map(e=>{const t=n[e]?.conditions||[];let i,o={},a={};return(0,p.cy)(t)?(o=(0,p.jq)(t,"type","Ready")||{},a=(0,p.jq)(t,"type","Schedulable")||{}):(o=t.Ready,a=t.Schedulable),i="True"!==o?.status||"True"!==a?.status?w:y,{...r[e],...n[e],name:e,storageReserved:r[e]?.storageReserved,storageAvailable:n[e]?.storageAvailable,storageMaximum:n[e]?.storageMaximum,storageScheduled:n[e]?.storageScheduled,readyCondition:o,schedulableCondition:a,state:i}});return i}get pods(){const e=this.$rootGetters["currentProduct"].inStore,t=this.$rootGetters[`${e}/all`](o.Sm)||[];return t.filter(e=>e?.spec?.nodeName===this.id&&"removing"!==e?.metadata?.name)}get reserved(){try{return JSON.parse(this.metadata.annotations[s.r.HOST_REQUEST]||"{}")}catch{return{}}}get cpuReserved(){return(0,h.ao)(this.reserved.cpu||"0")}get memoryReserved(){return(0,h.ao)(this.reserved.memory||"0")}get canDelete(){const e=this.$rootGetters["harvester/all"](o.NW)||[];return e.length>1&&super.canDelete}get vlanStatuses(){const e=this.$rootGetters["currentProduct"].inStore,t=this.id,n=this.$rootGetters[`${e}/all`](v.rk.VLAN_STATUS);return n.filter(e=>e?.status?.node===t)||[]}get blockDevices(){const e=this.$rootGetters["currentProduct"].inStore,t=this.id,n=this.$rootGetters[`${e}/all`](v.rk.BLOCK_DEVICE);return n.filter(e=>e?.spec?.nodeName===t)||[]}get unProvisionedDisks(){const e=this.blockDevices||[];return e.filter(e=>e?.isProvisioned&&"Provisioned"!==e?.status?.provisionPhase)}get diskStatusCount(){const e=this.unProvisionedDisks.filter(e=>e.metadata.state.error)||[];let t=0;this.longhornDisks.map(e=>{"warning"===e.state&&t++});const n=this.longhornDisks.length+e.length;return{total:n,errorCount:t+e.length,useful:n-t}}get manufacturer(){return this.metadata?.labels?.[s.r.NODE_MANUFACTURER]}get serialNumber(){return this.metadata?.labels?.[s.r.NODE_SERIAL_NUMBER]}get model(){return this.metadata?.labels?.[s.r.NODE_MODEL]}get isStopped(){const e=this.inventory||{};return"off"===e.status?.machinePowerState}get isStopping(){const e=this.inventory||{};return!Object.prototype.hasOwnProperty.call(e?.status?.powerAction||{},"actionStatus")&&"shutdown"===e.spec?.powerActionRequested}get isStarted(){const e=this.inventory||{};return"on"===e.status?.machinePowerState}get isStarting(){const e=this.inventory||{};return!Object.prototype.hasOwnProperty.call(e?.status?.powerAction||{},"actionStatus")&&"poweron"===e.spec?.powerActionRequested}get isRebooting(){const e=this.inventory||{};return!Object.prototype.hasOwnProperty.call(e?.status?.powerAction||{},"actionStatus")&&"reboot"===e.spec?.powerActionRequested}async shutDown(e=this){try{await this.doAction("powerActionPossible",{}),await this.doAction("powerAction",{operation:"shutdown"}),await this.$dispatch("growl/success",{title:this.t("generic.notification.title.succeed"),message:this.t("harvester.host.powerAction.message.success",{name:this.name,operation:"shut down"})},{root:!0})}catch(t){await this.$dispatch("growl/error",{title:this.t("generic.notification.title.error"),message:t},{root:!0})}}async powerOn(e=this){const t="poweron";try{await this.doAction("powerActionPossible",{}),await this.doAction("powerAction",{operation:t}),await this.$dispatch("growl/success",{title:this.t("generic.notification.title.succeed"),message:this.t("harvester.host.powerAction.message.success",{name:this.name,operation:t})},{root:!0})}catch(n){await this.$dispatch("growl/error",{title:this.t("generic.notification.title.error"),message:n},{root:!0})}}async reboot(e=this){const t="reboot";try{await this.doAction("powerActionPossible",{}),await this.doAction("powerAction",{operation:t}),await this.$dispatch("growl/success",{title:this.t("generic.notification.title.succeed"),message:this.t("harvester.host.powerAction.message.success",{name:this.name,operation:t})},{root:!0})}catch(n){await this.$dispatch("growl/error",{title:this.t("generic.notification.title.error"),message:n},{root:!0})}}get inventory(){const e=this.$rootGetters["currentProduct"].inStore,t=this.$rootGetters[`${e}/all`](v.rk.INVENTORY)||[];return t.find(e=>e.id===`harvester-system/${this.id}`)}get warningMessages(){let e=[];return e=e.concat(this.inventory?.warningMessages||[]),e}}},15908:function(e,t,n){"use strict";n.r(t),n.d(t,{DATA_ENGINE_V1:function(){return b},DATA_ENGINE_V2:function(){return y},default:function(){return w}});var r=n(14220),i=n(74874),o=n.n(i),a=n(35664),s=n(2841),l=n(2602),c=n(68851),u=n(76978),d=n(73883),h=n(32766),p=n(24222),f=n(20652),m=n(41837),g=n(82877);const v=["replica scheduling failed","precheck new replica failed"],b="v1",y="v2";class w extends p["default"]{applyDefaults(e,t){const n=t===r.dT?this.spec.accessModes:[],i=t===r.dT?this.spec.resources.requests.storage:null,o=t===r.dT?this.spec.storageClassName:"";this["spec"]={accessModes:n,storageClassName:o,volumeName:"",resources:{requests:{storage:i}}}}get availableActions(){let e=super._availableActions;const t=e.find(e=>"goToClone"===e.action);t&&(t.action="goToCloneVolume");const n={action:"exportImage",enabled:this.hasAction("export")&&!this.isEncrypted,icon:"icon icon-external-link",label:this.t("harvester.action.exportImage")},r={action:"snapshot",enabled:this.hasAction("snapshot"),icon:"icon icon-backup",label:this.t("harvester.action.snapshot")};return this.thirdPartyStorageFeatureEnabled?e=[n,r,...e]:this.isLonghorn&&this.isLonghornV2||(e=[n,r,...e]),[{action:"cancelExpand",enabled:this.hasAction("cancelExpand"),icon:"icon icon-backup",label:this.t("harvester.action.cancelExpand")},{action:"dataMigration",enabled:this.hasAction("dataMigration")&&this.createPVCWithDataVolumeFeatureEnabled,icon:"icon icon-copy",label:this.t("harvester.action.dataMigration")},...e]}dataMigration(e=this){this.$dispatch("promptModal",{resources:e,component:"HarvesterDataMigrationDialog"})}exportImage(e=this){this.$dispatch("promptModal",{resources:e,component:"HarvesterExportImageDialog"})}cancelExpand(e=this){this.doActionGrowl("cancelExpand",{})}snapshot(e=this){this.$dispatch("promptModal",{resources:e,component:"SnapshotDialog"})}goToCloneVolume(e=this){this.$dispatch("promptModal",{resources:e,component:"VolumeCloneDialog"})}cleanForNew(){this.$dispatch("cleanForNew",this),delete this.metadata.finalizers;const e=[l.r.IMAGE_ID,s.tC];this.metadata.annotations=o()(this.metadata.annotations,e)}get storageClass(){const e=this.$rootGetters["currentProduct"].inStore;return this.$rootGetters[`${e}/all`](a.fJ).find(e=>e.name===this.spec.storageClassName)}get canUpdate(){return this.hasLink("update")}get stateDisplay(){const e=this.relatedPV?.metadata?.annotations?.[l.r.VOLUME_ERROR],t=v.includes(e),n="Bound"===this?.status?.phase&&!e&&this.isLonghornVolumeReady?"Ready":"Not Ready",r=this?.status?.conditions||[];return"True"===(0,c.jq)(r,"type","Resizing")?.status?"Resizing":this.attachVM&&!e?"In-use":t?"Degraded":n}get state(){const e=this.relatedPV?.metadata?.annotations?.[l.r.VOLUME_ERROR],t=v.includes(e);let n="Bound"!==this?.status?.phase||e?"Not Ready":"Ready";const r=this?.status?.conditions||[];return t&&(n="Degraded"),"True"===(0,c.jq)(r,"type","Resizing")?.status&&(n="Resizing"),n}get stateColor(){const e=this.stateDisplay;return(0,d.uU)(e)}get stateDescription(){return super.stateDescription}get detailLocation(){const e=(0,u.o8)(this._detailLocation);return e.params.resource=h.rk.VOLUME,e}get doneOverride(){const e=(0,u.o8)(this._detailLocation);return delete e.params.namespace,delete e.params.id,e.params.resource=h.rk.VOLUME,e.name=`${f.KR}-c-cluster-resource`,e}get parentNameOverride(){return this.$rootGetters["i18n/t"](`typeLabel."${h.rk.VOLUME}"`,{count:1}).trim()}get parentLocationOverride(){return this.doneOverride}get phaseState(){return this.status?.phase||"N/A"}get attachVM(){const e=this.$rootGetters["harvester/all"](h.rk.VM)||[],t=e=>{const t=e.spec.template?.spec?.volumes||[];return e.namespace===this.namespace&&t.length>0?t.find(e=>e.persistentVolumeClaim?.claimName===this.name):null};return e.find(t)}get attachVMName(){return this.attachVM?.nameDisplay||this.attachVM?.metadata?.name||""}get isAvailable(){const e=["Resizing","Not Ready"];return!e.includes(this.stateDisplay)}get volumeSort(){const e=this.spec?.resources?.requests?.storage||0;return parseInt(e)}get isSystemResource(){const e=this.$rootGetters["systemNamespaces"];return!!e.includes(this.metadata?.namespace)}get isEncrypted(){return"true"===this.relatedPV?.spec?.csi?.volumeAttributes?.encrypted}get longhornVolume(){const e=this.$rootGetters["currentProduct"].inStore;return this.$rootGetters[`${e}/all`](a.oe.VOLUMES).find(e=>e.metadata?.name===this.spec?.volumeName)}get longhornEngine(){const e=this.$rootGetters["currentProduct"].inStore;return this.$rootGetters[`${e}/all`](a.oe.ENGINES).find(e=>e.spec?.volumeName===this.spec?.volumeName)}get isLonghornVolumeReady(){let e=!0;const t=this.longhornVolume||{},n=(t?.status?.conditions||[]).find(e=>"Scheduled"===e.type||"scheduled"===e.type)||{};return(""===t?.spec?.nodeID&&"detached"!==t?.status?.state||"detached"===t?.status?.state&&"True"!==n.status||"faulted"===t?.status?.robustness||t?.status?.restoreRequired||"failed"===t?.status?.cloneStatus?.state)&&(e=!1),e}get relatedVolumeSnapshotCounts(){const e=this.$rootGetters["harvester/all"](h.qY);return e.filter(e=>{const t=`${e.metadata?.namespace}/${e.spec?.source?.persistentVolumeClaimName}`,n=e.metadata?.ownerReferences?.[0]?.kind;return t===this.id&&"PersistentVolumeClaim"===n})}get originalSnapshot(){return this.spec?.dataSource?this.$rootGetters["harvester/all"](h.qY).find(e=>e.metadata?.name===this.spec.dataSource.name):null}get source(){const e=(0,u.Jt)(this,`metadata.annotations."${l.r.IMAGE_ID}"`);return e?"image":"data"}get warnDeletionMessage(){return this.t("harvester.volume.promptRemove.tips")}get relatedPV(){return this.$rootGetters["harvester/byId"](a.PV,this.spec?.volumeName)}get volumeProvider(){return this.relatedPV?.spec.csi?.driver}get dataEngine(){return this.relatedPV?.spec.csi?.volumeAttributes?.dataEngine}get isLvm(){return this.volumeProvider===g.LVM_DRIVER}get isLonghorn(){return this.volumeProvider===a.lI}get isLonghornV1(){return this.isLonghorn&&!this.isLonghornV2}get isLonghornV2(){return this.dataEngine===y}get isGoldenImageVolume(){return"true"===this?.metadata?.annotations?.[l.r.GOLDEN_IMAGE]}get isCDIPopulatorVolume(){const e=this?.metadata?.annotations?.[l.r.CDI_POPULATOR_KIND];return e===m.dt.VOLUME_IMPORT_SOURCE||e===m.dt.VOLUME_CLONE_SOURCE}get thirdPartyStorageFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("thirdPartyStorage")}get createPVCWithDataVolumeFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("createPVCWithDataVolume")}get resourceExternalLink(){const e=window.location.host,{params:t}=this.currentRoute(),n=this.spec?.volumeName;return this.isLonghorn&&n?{tipsKey:"harvester.volume.externalLink.tips",url:`https://${e}/k8s/clusters/${t.cluster}/api/v1/namespaces/longhorn-system/services/http:longhorn-frontend:80/proxy/#/volume/${n}`}:null}get customValidationRules(){return[{nullable:!1,path:"spec.resources.requests.storage",required:!0,validators:["volumeSize"]}]}}},14426:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return x}});var r=n(87526),i=n.n(r),o=n(68851),a=n(76978),s=n(35664),l=n(24222);const c="POD_NOT_SCHEDULABLE",u="POD_FAILED",d="POD_CRASHLOOP_BACKOFF",h="POD_STATUS_UNKNOWN",p="POD_CONTAINER_FAILING",f="POD_NOT_READY",m="POD_STATUS_PENDING",g="POD_STATUS_COMPLETED",v="POD_STATUS_SUCCEEDED",b="POD_STATUS_RUNNING",y=["ImagePullBackOff","ErrImagePull","CrashLoopBackOff"],w=["Error"],O={Failed:u,CrashLoopBackOff:d,Unknown:h},S={Pending:m,Running:b,Completed:g,Succeeded:v},E={terminated:({reason:e,exitCode:t})=>`Terminated with ${e}${t?` (exit code ${t}).`:"."}`,waiting:({reason:e})=>`Waiting (${e}).`};class x extends l["default"]{get inStore(){return this.$rootGetters["currentProduct"].inStore}get nodes(){return this.$rootGetters[`${this.inStore}/all`](s.NW)}get node(){const{nodeName:e}=this.spec;return this.nodes.filter(t=>t?.metadata?.name===e)[0]}get getPodStatus(){return this.isNotSchedulable||this.hasErrorStatus||this.isContainerFailing||this.isNotReady||this.hasOkStatus||{status:h}}get isNotSchedulable(){if(!this.isPodSchedulable){const e=(0,a.Jt)(this,"status.conditions"),t=(0,o.jq)(e,"type","PodScheduled");return{status:c,message:t.message||"Pod scheduling failed."}}return null}get hasErrorStatus(){const e=O[this?.status?.phase];return e?{status:e,message:this.getContainerStatusReason(this.findFailingContainerStatus)}:null}get isPodSchedulable(){const e=(0,a.Jt)(this,"status.conditions"),t=(0,o.jq)(e,"type","PodScheduled");return!(t&&"True"!==t.status&&"Unschedulable"===t.reason)}get findFailingContainerStatus(){return((0,a.Jt)(this,"status.containerStatuses"),[]).find(e=>!e.ready&&(i()(y,(0,a.Jt)(e,"state.waiting.reason"))||i()(w,(0,a.Jt)(e,"state.terminated.reason"))))}get getContainerStatusReason(){return e=>{if(e){const t=Object.getOwnPropertyNames(e.state).find(t=>!!e.state[t].reason);if(t){const n=e.state[t];return n.message||E[t]&&E[t](n)||t}}}}get isContainerFailing(){const e=this.findFailingContainerStatus;return e?{status:p,message:this.getContainerStatusReason(e)}:null}get isNotReady(){const e=this.findPodFalseStatusConditionMessage;return e?{status:f,message:e}:null}get hasOkStatus(){const e=S[this?.status?.phase];return e?{status:e}:null}get findPodFalseStatusConditionMessage(){const e=this.getPodFalseStatusConditions;if(e.length>0)return e[0].message||`Step: ${e[0].type}`}get getPodFalseStatusConditions(){const e=(0,a.Jt)(this,"status.conditions")||[];return e.filter(e=>"True"!==e.status)}}},60698:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(45858);class i extends r["default"]{}},36577:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return l}});var r=n(76978),i=n(32766),o=n(20652),a=n(1133),s=n(35664);class l extends a["default"]{get _availableActions(){let e=super._availableActions;return e=e.map(e=>["download"].includes(e.action)?{...e,enabled:!!this.linkFor("update")}:e),e}get fullDetailPageOverride(){return!1}get listLocation(){const e=(0,r.o8)(super.listLocation);return e.name=this.harvesterResourcesInExplorer?"c-cluster-product-resource":`${o.KR}-c-cluster-resource`,e.params.resource=i.rk.SECRET,e}get harvesterResourcesInExplorer(){return this.$rootGetters["productId"]!==o.KR}get _detailLocation(){const e=this.$getters["schemaFor"](this.type),t=this.id?.replace(/.*\//,"");return{name:`${o.KR}-c-cluster-resource${e?.attributes?.namespaced?"-namespace":""}-id`,params:{product:o.KR,cluster:this.$rootGetters["clusterId"],resource:this.type,id:t,namespace:this.metadata.namespace}}}get detailLocation(){const e=(0,r.o8)(this._detailLocation);return e.params.resource=i.rk.SECRET,e}get doneOverride(){const e=(0,r.o8)(this._detailLocation);return delete e.params.namespace,delete e.params.id,e.params.resource=i.rk.SECRET,e.name=`${o.KR}-c-cluster-resource`,e}get doneRoute(){return this.doneOverride.name}get parentNameOverride(){return this.$rootGetters["i18n/t"](`typeLabel."${i.rk.SECRET}"`,{count:1})?.trim()}get parentLocationOverride(){return this.doneOverride}get isSystem(){const e=this.$rootGetters["currentProduct"].inStore,t=this.$rootGetters[`${e}/all`](s.CU).filter(e=>!0===e.isSystem).map(e=>e.metadata.name);return t.includes(this.metadata.namespace)}get details(){const e=[{label:this.t("secret.type"),content:this.typeDisplay}];return this.cn&&e.push({label:this.t("secret.certificate.cn"),content:this.plusMoreNames?`${this.cn} ${this.t("secret.certificate.plusMore",{n:this.plusMoreNames})}`:this.cn}),this.issuer&&e.push({label:this.t("secret.certificate.issuer"),content:this.issuer}),this.notAfter&&e.push({label:"Expires",formatter:"Date",formatterOpts:{class:this.dateClass},content:this.notAfter}),e}}},87214:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return l}});var r=n(76978),i=n(35664),o=n(32766),a=n(24222),s=n(20652);class l extends a["default"]{get availableActions(){return[{action:"restoreSnapshot",enabled:this.hasAction("restore"),icon:"icon icon-refresh",label:this.t("harvester.action.restore")},...super._availableActions]}get canClone(){return!1}restoreSnapshot(e=this){this.$dispatch("promptModal",{resources:e,component:"RestoreSnapshotDialog"})}get detailLocation(){const e=(0,r.o8)(this._detailLocation);return e.params.resource=o.rk.SNAPSHOT,e}get doneOverride(){const e=(0,r.o8)(this._detailLocation);return delete e.params.namespace,delete e.params.id,e.params.resource=o.rk.SNAPSHOT,e.name=`${s.KR}-c-cluster-resource`,e}get parentNameOverride(){return this.$rootGetters["i18n/t"](`typeLabel."${o.rk.SNAPSHOT}"`,{count:1})?.trim()}get parentLocationOverride(){return this.doneOverride}get volume(){const e=this.$rootGetters["currentProduct"].inStore,t=this?.metadata?.namespace,n=this?.spec?.source?.persistentVolumeClaimName,r=this.$rootGetters[`${e}/byId`](i.YH,`${t}/${n}`);return r}}},82877:function(e,t,n){"use strict";n.r(t),n.d(t,{LVM_DRIVER:function(){return u},default:function(){return d}});var r=n(76978),i=n(63809),o=n(32766),a=n(20652),s=n(35664),l=n(15908),c=n(39407);const u="lvm.driver.harvesterhci.io";class d extends i["default"]{get listLocation(){const e=(0,r.o8)(super.listLocation);return e.name=this.harvesterResourcesInExplorer?"c-cluster-product-resource":`${a.KR}-c-cluster-resource`,e.params.resource=o.rk.STORAGE,e}get harvesterResourcesInExplorer(){return this.$rootGetters["productId"]!==a.KR}get detailLocation(){const e=(0,r.o8)(this._detailLocation);return e.params.resource=o.rk.STORAGE,e.name=`${a.KR}-c-cluster-resource-id`,e}get doneOverride(){const e=(0,r.o8)(this._detailLocation);return delete e.params.namespace,delete e.params.id,e.params.resource=o.rk.STORAGE,e.name=`${a.KR}-c-cluster-resource`,e}get parentLocationOverride(){return this.doneOverride}get parentNameOverride(){return this.$rootGetters["i18n/t"](`typeLabel."${o.rk.STORAGE}"`,{count:1})?.trim()}get longhornVersion(){return this.provisioner===s.lI?(this.parameters||{}).dataEngine||l.DATA_ENGINE_V1:null}get provisionerDisplay(){let e="";return this.provisioner===s.lI&&(e=`harvester.storage.storageClass.longhorn.${this.longhornVersion}.label`),this.provisioner===u&&(e="harvester.storage.storageClass.lvm.label"),e?this.$rootGetters["i18n/t"](e):this.provisioner}get isEncrypted(){return"true"===this.parameters?.encrypted}get isLonghorn(){return this.provisioner===s.lI}get isLonghornV1(){return this.provisioner===s.lI&&this.longhornVersion===l.DATA_ENGINE_V1}get isLonghornV2(){return this.provisioner===s.lI&&this.longhornVersion===l.DATA_ENGINE_V2}get longhornV2LVMSupport(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("longhornV2LVMSupport")}get volumeEncryptionFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("volumeEncryption")}get expandOnlineEncryptedVolumeFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("expandOnlineEncryptedVolume")}get thirdPartyStorageFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("thirdPartyStorage")}isInternalStorageClass(){return(0,c.N)(this.metadata?.name)}get availableActions(){let e=super.availableActions||[];const t=!!this.linkFor("update");return e=e.map(e=>["setDefault","setAsDefault","resetDefault"].includes(e.action)?{...e,enabled:t}:e),this.isInternalStorageClass()&&(e=e.filter(e=>!["setDefault","setAsDefault","promptRemove"].includes(e.action))),e[0]&&!0===e[0].divider&&(e=e.slice(1)),e}}},52528:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return p}});var r=n(20246),i=n.n(r),o=n(95479),a=n.n(o),s=n(2602),l=n(24222),c=n(32766);const u="harvester-system/nvidia-driver-toolkit",d="harvester-system/rancher-vcluster",h="rancher-k3k/rancher-k3k";class p extends l["default"]{get availableActions(){const e=super._availableActions;if(this.id===d||this.id===h){const t={action:"goToRancher",enabled:this.spec.enabled,icon:"icon icon-external-link",label:this.t("harvester.addons.rancherVcluster.accessRancher")};e.push(t)}const t=!!this.linkFor("update"),n={action:"toggleAddon",enabled:t,icon:this.spec.enabled?"icon icon-pause":"icon icon-play",label:this.spec.enabled?this.t("generic.disable"):this.t("generic.enable")};return e.unshift(n),e}async toggleAddon(){const e=this.spec.enabled;try{if(!this.spec.enabled&&"rancher-vcluster/rancher-vcluster"===this.id){const e=i().load(this.spec.valuesContent);if(!e.hostname||!e.bootstrapPassword)return void this.goToEdit()}if(!this.spec.enabled&&this.id===u)return void this.$dispatch("promptModal",{resources:[this],component:"HarvesterEnableNvidiaDriverToolkit"});if(!this.spec.enabled&&this.id===h)return void this.$dispatch("promptModal",{resources:[this],component:"HarvesterEnableK3k"});this.spec.enabled=!this.spec.enabled,await this.save()}catch(t){this.spec.enabled=e,this.$dispatch("growl/fromError",{title:this.t("harvester.addons.switchFailed",{action:e?this.t("generic.disable"):this.t("generic.enable"),name:this.metadata.name}),err:t},{root:!0})}}goToRancher(){window.open(this.rancherHostname,"_blank")}get rancherHostname(){const e=i().load(this.spec.valuesContent)||{},t=this.id===h?e.rancher?.hostname:e.hostname;return`https://${t}`}get stateColor(){const e=this.stateDisplay;return e?.toLowerCase().includes("enabled")||e?.toLowerCase().includes("success")?"text-success":"Disabled"===e?"text-darker":e?.toLowerCase().includes("ing")?"text-info":e?.toLowerCase().includes("failed")||e?.toLowerCase().includes("error")?"text-error":"text-info"}get stateDisplay(){const e=this?.status?.status;return e?e.startsWith("Addon")?a()(e.replace("Addon","")):e:"Disabled"}get stateDescription(){const e=(this.status?.conditions||[]).find(e=>"OperationFailed"===e.type);return e?.message||super.stateDescription}get parentNameOverride(){return this.$rootGetters["i18n/t"](`typeLabel."${c.rk.ADD_ONS}"`,{count:1})?.trim()}get displayName(){const e="true"===this.metadata?.labels?.[s.r.ADDON_EXPERIMENTAL],t=this.metadata?.labels?.[s.r.ADDON_DISPLAYNAME]||this.metadata.name;return e?`${t} (${this.t("generic.experimental")})`:t}get customValidationRules(){let e=[];return"rancher-monitoring"===this.metadata.name&&(e=[{nullable:!1,path:"spec.valuesContent",validators:["rancherMonitoring"]}]),"rancher-logging"===this.metadata.name&&(e=[{nullable:!1,path:"spec.valuesContent",validators:["rancherLogging"]}]),e}}},46933:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(32766),i=n(24222);class o extends i["default"]{get childParts(){const e=this.$rootGetters["currentProduct"].inStore,t=this.$rootGetters[`${e}/all`](r.rk.BLOCK_DEVICE),n=t.filter(e=>e.status?.deviceStatus?.parentDevice===this.spec?.devPath&&e.spec.nodeName===this.spec.nodeName);return n}get isChildPartProvisioned(){const e=this.childParts.filter(e=>e.isProvisioned)||[];return e.length>0}get provisionPhase(){const e=this?.status?.provisionPhase;let t="",n="";switch(e){case"Provisioned":t="bg-success",n="icon-checkmark";break;case"Unprovisioning":t="bg-warning",n="icon-warning";break;case"NotProvisioned":t="bg-error",n="icon-warning";break;default:break}return{label:e,color:t,icon:n}}get displayName(){return this.status?.deviceStatus?.devPath||this?.metadata?.name}get isFormatting(){const e=this?.status?.conditions||[],t=e.find(e=>"Formatting"===e.type)||{};return"True"===t.status}get isProvisioned(){return this.spec?.fileSystem?.provisioned||this.spec?.provision}cleanForSave(e){return e}}},72193:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return a}});var r=n(76978),i=n(68851),o=n(24222);class a extends o["default"]{get _availableActions(){let e=super._availableActions;return e=e.map(e=>["download"].includes(e.action)?{...e,enabled:!!this.linkFor("update")}:e),e}get stateDisplay(){const e=(0,r.Jt)(this,"status.conditions"),t=((0,i.jq)(e,"type","validated")||{}).status;return"True"===t?"Validated":"Not Validated"}}},26422:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return s}});var r=n(24222),i=n(73883),o=n(14220),a=n(92043);class s extends r["default"]{detailPageHeaderActionOverride(e){if(e===o.YQ)return this.t("harvester.schedule.createTitle")}get _availableActions(){const e=["goToClone"],t=super._availableActions.filter(t=>{if(!e.includes(t.action))return t}),n=!!this.linkFor("update");return[{action:"resumeSchedule",enabled:n&&(0,a.TF)(this.state)===i.xj.suspended.label,icon:"icons icon-play",label:this.t("harvester.action.resumeSchedule")},{action:"suspendSchedule",enabled:n&&(0,a.TF)(this.state)===i.xj.active.label,icon:"icons icon-pause",label:this.t("harvester.action.suspendSchedule")},...t]}async suspendSchedule(){try{this.spec.suspend=!0,await this.save()}catch(e){this.spec.suspend=!1,this.$dispatch("growl/fromError",{title:this.t("generic.notification.title.error",{name:(0,a.ZD)(this.metadata.name)}),err:e},{root:!0})}}async resumeSchedule(){try{this.spec.suspend=!1,await this.save()}catch(e){this.spec.suspend=!0,this.$dispatch("growl/fromError",{title:this.t("generic.notification.title.error",{name:(0,a.ZD)(this.metadata.name)}),err:e},{root:!0})}}get stateObj(){return this?.metadata?.state||{}}get state(){return!0===this.status?.suspended?i.xj.suspended.label:i.xj.active.label}get stateDescription(){const e=(this.status?.conditions||[]).find(e=>"BackupSuspend"===e.type);return(0,a.TF)(e?.message)||super.stateDescription}get stateBackground(){return(0,i.uU)(this.stateDisplay).replace("text-","bg-")}get stateColor(){return(0,i.uU)(this.state)}get stateDisplay(){return(0,i.ch)(this.state)}}},96214:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return c}});var r=n(68851),i=n(32766),o=n(50889),a=n(20652),s=n(24222),l=n(4364);class c extends s["default"]{get _availableActions(){const e=["cloneYaml","download","goToEditYaml","goToViewYaml","goToViewConfig","promptRemove"],t=o.gh[this.id];let n=super._availableActions;(t?.readOnly||this.fromEnv)&&e.push("goToEdit"),n=n.filter(t=>!e.includes(t.action));const r=n.find(e=>"goToEdit"===e.action);r&&(r.label=this.t("advancedSettings.edit.label"));const a=this.$getters["schemaFor"](i.rk.UPGRADE),s=!!a?.collectionMethods.find(e=>["post"].includes(e.toLowerCase()));return this.id===o.EP.SERVER_VERSION&&s&&n.unshift({action:"goToAirgapUpgrade",enabled:!0,icon:"icon icon-refresh",label:this.t("harvester.upgradePage.upgrade")}),n}goToAirgapUpgrade(){const e=this.currentRouter();e.push({name:`${a.KR}-c-cluster-airgapupgrade`,params:{cluster:this.$rootGetters["currentCluster"].id,product:"harvester"}})}get clusterRegistrationTLSVerifyFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("clusterRegistrationTLSVerify")}get customValue(){if(this.metadata.name===o.EP.STORAGE_NETWORK)try{return JSON.stringify(JSON.parse(this.value),null,2)}catch(e){}else if(this.metadata.name===o.EP.CLUSTER_REGISTRATION_URL)try{return this.clusterRegistrationTLSVerifyFeatureEnabled?JSON.stringify(JSON.parse(this.value),null,2):this.value}catch(e){}return!1}get customFormatter(){if(this.metadata.name===o.EP.STORAGE_NETWORK)try{return JSON.stringify(JSON.parse(this.value),null,2),"json"}catch(e){}return!1}get backupTargetIsEmpty(){return!this.value}get errMessage(){const e=(0,r.jq)(this?.status?.conditions||[],"type","configured")||{};return!0===this.metadata?.state?.error?this.metadata.state.message:"False"===e?.status&&e.message}get valueOrDefaultValue(){return this.value||this.default}get currentVersion(){return this.value||""}get displayValue(){return"backup-target"===this.id?this.parseValue?.endpoint||" ":null}get parseValue(){try{if(this.value)return JSON.parse(this.value);if(this.default)return JSON.parse(this.default)}catch(e){l.error("Failed to parse setting value or default:",e)}return{}}get isS3(){return"s3"===this.parseValue.type}get isNFS(){return"nfs"===this.parseValue.type}get customValidationRules(){const e=this.id,t=[];switch(e){case"backup-target":t.push({nullable:!1,path:"value",type:"string",validators:["backupTarget"]});break;case"ntp-servers":t.push({nullable:!0,path:"value",validators:["ntpServers"]});break}return t}get disableResourceDetailDrawer(){return!0}}},25661:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(24222);class i extends r["default"]{get bundleState(){const e=this?.status?.state;return e}get bundleMessage(){const e=this?.metadata?.state;return!!e.error&&e?.message}get precent(){return this?.status?.progress/100||0}get customValidationRules(){return[{nullable:!1,path:"spec.description",required:!0,translationKey:"harvester.modal.bundle.description"}]}}},39334:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return c}});var r=n(20246),i=n.n(r),o=n(35664),a=n(73883),s=n(2602),l=n(24222);class c extends l["default"]{get isLatestUpgrade(){return"true"===this?.metadata?.labels?.[s.r.LATEST_UPGRADE]}get isUpgradeFailed(){return"Failed"===this?.metadata?.labels?.[s.r.UPGRADE_STATE]}get isUpgradeSucceeded(){return"Succeeded"===this?.metadata?.labels?.[s.r.UPGRADE_STATE]}get hasReadMessage(){return"true"===this?.metadata?.labels?.[s.r.REAY_MESSAGE]}get repoInfo(){const e=this?.status?.repoInfo;if(e)try{return i().load(e)}catch(t){return!1}return!1}get stateDisplay(){const e=this?.status?.conditions||[],t=e.find(e=>"Completed"===e.type),n=t?.status;return"True"===n?"Success":"False"===n?"Fail":"on-going"}get stateColor(){return(0,a.uU)(this.stateDisplay)}get nodes(){return this.$rootGetters["harvester/all"](o.NW)}get upgradeImage(){return this?.status?.imageID}cleanForSave(e,t){return e}get upgradeMessage(){const e=[],t=this?.status?.nodeStatuses||{},n=this?.status?.conditions||[];for(const r in t){const n=t[r]?.state;t[r]&&"Succeeded"!==n&&"succeeded"!==n&&e.push({id:r,message:`The node ${r} is ${t[r]?.state}`})}for(let r=0;r<n.length;r++){const t=n[r].type;"systemServiceUpgraded"===t&&"True"!==n[r]?.status&&e.push({id:"systemService",message:"The systemService is upgrading"})}return this.metadata?.state?.message&&this.metadata?.state?.error&&e.push({id:"message",message:`${this.metadata.state.message}`}),e}get createRepo(){const e=this?.status?.conditions||[],t=e.find(e=>"RepoReady"===e.type),n="True"===t?.status;return{isReady:n,message:t?.message||t?.reason}}get overallMessage(){const e=this?.status?.conditions||[],t=e.find(e=>"Completed"===e.type),n="False"===t?.status,r=t?.message||t?.reason;return n?r:""}get upgradeImageMessage(){const e=this?.status?.conditions||[],t=e.find(e=>"ImageReady"===e.type),n="True"===t?.status,r=t?.message||t?.reason;return n?"":r}get nodeUpgradeMessage(){const e=[],t=this?.status?.nodeStatuses||{};for(const n in t){const r=t[n]?.state,i=t[n]?.message;let o=0;"Upgrading"===r?o=50:"Succeeded"!==r&&"succeeded"!==r||(o=100),e.push({name:n,state:r,percent:o,message:i})}for(const n of this.nodes){const t=e.find(e=>e.name===n.id);t||e.push({name:n.id,state:"Pending",percent:0})}return e}get nodeTotalPercent(){let e=0;for(let r=0;r<this.nodeUpgradeMessage.length;r++)e+=this.nodeUpgradeMessage[r].percent;e=Math.floor(e/this.nodeUpgradeMessage.length);const t=this?.status?.conditions||[],n=t.find(e=>"NodesUpgraded"===e.type);return 100!==e||n||(e=99),e}get sysServiceUpgradeMessage(){let e=0,t="Pending";const n=[],r=this?.status?.conditions||[];for(let i=0;i<r.length;i++){const o=r[i].type;"SystemServicesUpgraded"===o&&("True"===r[i].status?(e=100,t="Succeeded"):e=50,n.push({name:"system services",state:t,percent:e,message:r[i]?.message}))}return 0===n.length&&n.push({name:"system services",state:t,percent:e}),n}get totalPercent(){const e=this.nodeTotalPercent*this.nodeUpgradeMessage.length,t=this.sysServiceUpgradeMessage?.[0].percent;return Math.floor((e+t)/(this.nodeUpgradeMessage.length+1))}}},25418:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return c}});var r=n(76978),i=n(52225),o=n.n(i),a=n(68851),s=n(32766),l=n(24222);class c extends l["default"]{get canStartedDownload(){const e=(0,r.Jt)(this,"status.conditions"),t=((0,a.jq)(e,"type","DownloadReady")||{}).status;return"True"===t}downloadLog(e){const t=o()(window.history.href),n=this.$rootGetters["clusterId"],r=`/k8s/clusters/${n}`;this.$rootGetters["isMultiCluster"]?window.location.href=`${t.origin}${r}/v1/harvester/${s.rk.UPGRADE_LOG}s/${this.id}/download?archiveName=${e}`:window.location.href=`${t.origin}/v1/harvester/${s.rk.UPGRADE_LOG}s/${this.id}/download?archiveName=${e}`}fileIsReady(e){const t=(this.status?.archives||{})[e];return!0===t?.ready||t?.reason}downloadArchivesStatus(e){return(this.status?.archives||{})[e]?.reason}get latestArchivesFileName(){const e=this.status?.archives||{},t=`${this.metadata.name}-archive-`,n=Object.keys(e).map(e=>e.replace(t,"")),r=n.sort((e,t)=>{const n=e.replace(/(\d{2})-(\d{2})-(\d{2})T(\d{2})-(\d{2})-(\d{2})Z/,"$1-$2-$3T$4:$5:$6Z"),r=t.replace(/(\d{2})-(\d{2})-(\d{2})T(\d{2})-(\d{2})-(\d{2})Z/,"$1-$2-$3T$4:$5:$6Z");return Date.parse(r)-Date.parse(n)}).map(e=>`${t}${e}`);return r[0]}}},64778:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return h}});var r=n(76978),i=n(68851),o=n(73883),a=n(2602),s=n(14220),l=n(32766),c=n(20652),u=n(41837),d=n(24222);class h extends d["default"]{detailPageHeaderActionOverride(e){const t=this.currentRoute();if(e===s.YQ)return t.params.resource===l.rk.BACKUP?this.t("harvester.backup.title"):this.t("harvester.vmSnapshot.title")}get detailLocation(){const e=(0,r.o8)(this._detailLocation);return e.params.resource=l.rk.BACKUP,e}get disableResourceDetailDrawerConfigTab(){return!0}get doneOverride(){const e=this.currentRoute(),t=(0,r.o8)(this._detailLocation);return delete t.params.namespace,delete t.params.id,t.params.resource=e.params.resource,t.name=`${c.KR}-c-cluster-resource`,t}get parentNameOverride(){const e=this.currentRoute();return this.$rootGetters["i18n/t"](`typeLabel."${e.params.resource}"`,{count:1})?.trim()}get parentLocationOverride(){return this.doneOverride}get _availableActions(){const e=["goToEdit","cloneYaml","goToClone","download"],t=super._availableActions.filter(t=>{if(!e.includes(t.action))return t}),n=this.$getters["schemaFor"](l.rk.VM);let r=!0;return n&&!n?.collectionMethods.find(e=>["post"].includes(e.toLowerCase()))&&(r=!1),[{action:"restoreExistingVM",enabled:r&&this.attachVmExisting&&this?.status?.readyToUse,icon:"icons icon-refresh",label:this.t("harvester.action.restoreExistingVM")},{action:"restoreNewVM",enabled:r&&this?.status?.readyToUse,icon:"icons icon-backup",label:this.t("harvester.action.restoreNewVM")},...t]}restoreExistingVM(e=this){const t=this.currentRouter(),n=e.spec.type===u.aS.BACKUP?l.rk.BACKUP:l.rk.VM_SNAPSHOT;t.push({name:`${c.KR}-c-cluster-resource-create`,params:{resource:n},query:{restoreMode:"existing",resourceName:e.name}})}restoreNewVM(e=this){const t=this.currentRouter(),n=e.spec.type===u.aS.BACKUP?l.rk.BACKUP:l.rk.VM_SNAPSHOT;t.push({name:`${c.KR}-c-cluster-resource-create`,params:{resource:n},query:{restoreMode:"new",resourceName:e.name}})}get state(){let e="Pending";const t=(0,r.Jt)(this,"status.conditions"),n="True"===(0,i.jq)(t,"type","InProgress")?.status,o="True"===(0,i.jq)(t,"type","Ready")?.status;return this?.status?.readyToUse?e="Ready":n?e="Progressing":o||(e="error"),e}get stateColor(){const e=this.state;return(0,o.uU)(e)}get sourceSchedule(){return this.metadata?.annotations?.[a.r.SVM_BACKUP_ID]}get attachVM(){return this.spec.source.name}get backupContentName(){return this?.status?.virtualMachineBackupContentName||""}get backupProgress(){return{type:u.aS.BACKUP,percentage:void 0!==this.status?.progress||this.status?.readyToUse?this.status?.progress:0,details:{volumes:this.status?.volumeBackups}}}get backupTarget(){return this?.status?.backupTarget?.endpoint||""}get attachVmExisting(){const e=this.$rootGetters["harvester/all"](l.rk.VM);return!!e.find(e=>e.metadata.name===this.attachVM)}remove(){const e={...arguments};return e.params={propagationPolicy:"Foreground"},this._remove(e)}}},38287:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return b}});var r=n(2841),i=n(2602),o=n(76978),a=n(95799),s=n(92043),l=n(73883),c=n(14220),u=n(32766),d=n(20652),h=n(24222),p=n(66905),f=n(84757);const{CSI_PROVISIONER_SECRET_NAME:m,CSI_PROVISIONER_SECRET_NAMESPACE:g}=p.Et;function v(){function e(e,t=[]){const n=Array.isArray((0,o.Jt)(this,"status.conditions"))?this.status.conditions:t;return n.find(t=>t.type===e)}const t=e.call(this,"Initialized"),n=e.call(this,"Imported"),r=100===this.status?.progress;return![t?.status,n?.status].includes("False")&&(r&&!0)}class b extends h["default"]{get availableActions(){let e=super._availableActions;"download"!==this.imageSource&&(e=e.filter(({action:e})=>"goToClone"!==e));const t=this.$getters["schemaFor"](u.rk.VM);let n=!0;t&&!t?.collectionMethods.find(e=>["post"].includes(e.toLowerCase()))&&(n=!1);const r=!!this.$getters?.["schemaFor"]?.(u.rk.IMAGE)?.collectionMethods?.some(e=>"post"===e.toLowerCase()),i=this.isReady?[{action:"createFromImage",enabled:n,icon:"icon icon-circle-plus",label:this.t("harvester.action.createVM")},{action:"encryptImage",enabled:this.volumeEncryptionFeatureEnabled&&!this.isEncrypted&&r,icon:"icon icon-lock",label:this.t("harvester.action.encryptImage")},{action:"decryptImage",enabled:this.volumeEncryptionFeatureEnabled&&this.isEncrypted&&r,icon:"icon icon-unlock",label:this.t("harvester.action.decryptImage")},{action:"imageDownload",enabled:this.links?.download,icon:"icon icon-download",label:this.t("asyncButton.download.action")}]:[];if(this.isImportedImage){const t=i.find(e=>"imageDownload"===e.action),n=e.filter(({action:e})=>["download","promptRemove"].includes(e));return t?[t,{divider:!0},...n]:n}const o=i.length>0?e:e[0]?.divider?e.slice(1):e;return[...i,...o]}encryptImage(){const e=this.currentRouter();e.push({name:`${d.KR}-c-cluster-resource-create`,params:{resource:u.rk.IMAGE},query:{image:JSON.stringify({metadata:{name:this.metadata.name,namespace:this.metadata.namespace}}),fromPage:u.rk.IMAGE,sourceType:"clone",cryptoOperation:"encrypt"}})}decryptImage(){const e=this.currentRouter();e.push({name:`${d.KR}-c-cluster-resource-create`,params:{resource:u.rk.IMAGE},query:{image:JSON.stringify({metadata:{name:this.metadata.name,namespace:this.metadata.namespace}}),fromPage:u.rk.IMAGE,sourceType:"clone",cryptoOperation:"decrypt"}})}applyDefaults(e=this,t){t!==c.dT&&(this.metadata["labels"]={[i.r.OS_TYPE]:"",[i.r.IMAGE_SUFFIX]:""},this.metadata["annotations"]={[i.r.STORAGE_CLASS]:""})}createFromImage(){const e=this.currentRouter();e.push({name:`${d.KR}-c-cluster-resource-create`,params:{resource:u.rk.VM},query:{image:this.id,fromPage:u.rk.IMAGE}})}cleanForNew(){this.$dispatch("cleanForNew",this),delete this.spec.displayName}get nameDisplay(){return this.spec?.displayName}get isOSImage(){return"True"===this?.metadata?.annotations?.[i.r.OS_UPGRADE_IMAGE]}get isReady(){return v.call(this)}get stateDisplay(){const e=this.getStatusConditionOfType("Initialized"),t=this.getStatusConditionOfType("Imported");return"Unknown"===t?.status?"restore"===this.spec.sourceType?"Restoring":"download"===this.spec.sourceType?"Downloading":"upload"===this.spec.sourceType?this.uploadError?"Failed":"Uploading":"Exporting":e?.message||t?.message?"Failed":(0,l.ch)(this.metadata.state.name)}get encryptionSecret(){const e=this.spec.storageClassParameters[g],t=this.spec.storageClassParameters[m];return e&&t?`${e}/${t}`:""}get isEncrypted(){return"clone"===this.spec.sourceType&&"encrypt"===this.spec.securityParameters?.cryptoOperation&&!!this.spec.securityParameters?.sourceImageName&&!!this.spec.securityParameters?.sourceImageNamespace}get isImportedImage(){return"true"===this.metadata?.labels?.[i.r.IMPORTED_IMAGE]}get displayNameWithNamespace(){return`${this.metadata.namespace}/${this.spec.displayName}`}get imageStorageClass(){return this?.metadata?.annotations?.[i.r.STORAGE_CLASS]||""}get imageMessage(){if(this.uploadError)return(0,s.TF)(this.uploadError);const e=this?.status?.conditions||[],t=e.find(e=>"Initialized"===e.type),n=e.find(e=>"Imported"===e.type),r=e.find(e=>"RetryLimitExceeded"===e.type),i=t?.message||n?.message||r?.message;return(0,s.TF)(i)}get stateBackground(){return(0,l.uU)(this.stateDisplay).replace("text-","bg-")}get imageSource(){return(0,o.Jt)(this,"spec.sourceType")||"download"}get progress(){return this?.status?.progress||0}get annotationsToIgnoreRegexes(){return[r.tC].concat(r.S5)}get downSize(){const e=this.status?.size;return e?(0,a.Mo)(e,{increment:1024,maxPrecision:2,suffix:f.jx,firstSuffix:f.jx}):"-"}get virtualSize(){const e=this.status?.virtualSize;return e?(0,a.Mo)(e,{increment:1024,maxPrecision:2,suffix:f.jx,firstSuffix:f.jx}):"-"}getStatusConditionOfType(e,t=[]){const n=Array.isArray((0,o.Jt)(this,"status.conditions"))?this.status.conditions:t;return n.find(t=>t.type===e)}get stateObj(){const e=(0,o.o8)(this.metadata?.state),t=this.getStatusConditionOfType("Initialized"),n=this.getStatusConditionOfType("Imported");return([t?.status,n?.status].includes("False")||this.uploadError)&&(e.error=!0),e}get stateDescription(){return this.imageMessage}get displayName(){return this.spec?.displayName}get storageClassName(){return this.status?.storageClassName||""}get uploadImage(){return async(e,t={})=>{const n=new FormData,r=this.spec?.backend||"backingimage",i={cdi:"file",backingimage:"chunk"},o=i[r];if(!o){const e=this.t("harvester.image.errors.unsupportedBackend",{backend:r});throw this.$ctx.commit("harvester-common/uploadError",{name:this.name,message:e},{root:!0}),new Error(e)}n.append(o,e);try{this.$ctx.commit("harvester-common/uploadStart",this.metadata.name,{root:!0});const r=await this.doAction("upload",n,{headers:{"Content-Type":"multipart/form-data","File-Size":e.size},params:{size:e.size},signal:t.signal});return r}catch(a){throw this.$ctx.commit("harvester-common/uploadError",{name:this.name,message:a.message},{root:!0}),this.$ctx.commit("harvester-common/uploadEnd",this.metadata.name,{root:!0}),a}finally{this.$ctx.commit("harvester-common/uploadEnd",this.metadata.name,{root:!0})}}}get uploadError(){return this.$rootGetters["harvester-common/uploadingImageError"](this.name)}get imageSuffix(){return this.metadata?.labels?.[i.r.IMAGE_SUFFIX]}get imageOSType(){return this.metadata?.labels?.[i.r.OS_TYPE]}get customValidationRules(){const e=[];if("download"===this.imageSource){const t={nullable:!1,path:"spec.url",validators:["imageUrl"]},n={nullable:!1,path:"spec.url",required:!0,translationKey:"harvester.image.url"};e.push(t,n)}if("upload"===this.imageSource){const t={nullable:!1,path:"metadata.annotations",validators:["fileRequired"]};e.push(t)}if(this.spec?.checksum?.length){const t={path:"spec.checksum",validators:["hashSHA512"]};e.push(t)}return[{nullable:!1,path:"spec.displayName",required:!0,minLength:1,maxLength:63,translationKey:"generic.name"},...e]}get volumeEncryptionFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("volumeEncryption")}get thirdPartyStorageFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("thirdPartyStorage")}imageDownload(e=this){"cdi"===this.spec?.backend?this.$dispatch("promptModal",{resources:e,component:"HarvesterImageDownloader"}):this.downloadViaLink()}downloadViaLink(){window.location.href=this.links.download}}},82680:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(24222);class i extends r["default"]{get isComplete(){return this?.status?.complete||!1}get pvcNames(){const e=this?.status?.restores||[],t=e.map(e=>e?.persistentVolumeClaimSpec?.name);return t}get customValidationRules(){const e=this.spec?.newVM,t=[{nullable:!1,path:"spec.target.name",required:!0,minLength:1,maxLength:63,translationKey:"harvester.fields.virtualName"},{nullable:!1,path:"spec.virtualMachineBackupName",required:!0,translationKey:"harvester.backup.restore.backup"}];return e||t.push({path:"spec.deletionPolicy",required:!0,type:"string",translationKey:"harvester.backup.restore.deletePreviousVolumes"}),t}}},61746:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return l}});var r=n(14220),i=n(32766),o=n(20652),a=n(24222),s=n(76978);class l extends a["default"]{get availableActions(){const e=["goToEdit","cloneYaml","goToClone","goToEditYaml","download"],t=super._availableActions.filter(t=>{if("remove"===t.altAction&&(t.bulkable=!1),!e.includes(t.action))return t}),n=this.$getters["schemaFor"](i.rk.VM);let r=!0;return n&&!n?.collectionMethods.find(e=>["post"].includes(e.toLowerCase()))&&(r=!1),[{action:"createFromTemplate",enabled:r,icon:"icon icon-spinner",label:this.t("harvester.action.createVM")},{action:"addVersion",enabled:this.canCreate,icon:"icon icon-fw icon-circle-plus",label:this.t("harvester.action.addTemplateVersion")},...t]}createFromTemplate(){const e=this.currentRouter();e.push({name:`${o.KR}-c-cluster-resource-create`,params:{resource:i.rk.VM},query:{templateId:this.id,versionId:this.spec.defaultVersionId}})}get cpuPinningFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("cpuPinning")}addVersion(e={}){const t=this.currentRouter();t.push({name:`${o.KR}-c-cluster-resource-create`,params:{resource:i.rk.VM_VERSION},query:{[r.g]:r.YQ,templateId:this.id}})}get defaultVersion(){return this.status?.defaultVersion}get doneOverride(){const e=(0,s.o8)(this.listLocation);return e.params.resource=i.rk.VM_VERSION,e}}},96608:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return p}});var r=n(45250),i=n(14220),o=n(2602),a=n(68851),s=n(76978),l=n(73883),c=n(92043),u=n(20652),d=n(32766),h=n(24222);class p extends h["default"]{get availableActions(){let e=super._availableActions;const t=["goToClone","cloneYaml","goToViewConfig","goToEditYaml","goToViewYaml"];e=e.filter(e=>{if(!t.includes(e.action))return e});const n=this.$getters["schemaFor"](d.rk.VM);let r=!1;return n?.collectionMethods.find(e=>["post"].includes(e.toLowerCase()))&&(r=!0),[{action:"launchFromTemplate",icon:"icon icon-spinner",enabled:r&&this.isReady,label:this.t("harvester.action.launchFormTemplate")},{action:"cloneTemplate",enabled:this.currentTemplate?.canCreate,icon:"icon icon-fw icon-edit",label:this.t("harvester.action.modifyTemplate")},{action:"setDefaultVersion",enabled:this.currentTemplate?.canCreate,icon:"icon icon-fw icon-checkmark",label:this.t("harvester.action.setDefaultVersion")},{action:"goToViewConfig",label:this.t("action.view"),icon:"icon icon-edit"},...e]}applyDefaults(){const e={vm:{metadata:{annotations:{[o.r.VOLUME_CLAIM_TEMPLATE]:"[]"},labels:{}},spec:{runStrategy:"RerunOnFailure",template:{metadata:{annotations:{},labels:{}},spec:{domain:{machine:{type:""},cpu:{cores:null,sockets:1,threads:1},devices:{inputs:[{bus:"usb",name:"tablet",type:"tablet"}],interfaces:[{masquerade:{},model:"virtio",name:"default"}],disks:[]},resources:{limits:{memory:null,cpu:""}},features:{acpi:{enabled:!0}}},evictionStrategy:"LiveMigrateIfPossible",hostname:"",networks:[{name:"default",pod:{}}],volumes:[],affinity:{}}}}}};this["spec"]=e}get canDelete(){return this.hasLink("remove")&&this.$rootGetters["type-map/optionsFor"](this.type).isRemovable&&!this.isDefaultVersion}get template(){return this.$rootGetters["harvester/all"](d.rk.VM_TEMPLATE).find(e=>e.id===this.spec.templateId)}get isReady(){const e=(0,s.Jt)(this,"status.conditions"),t=(0,a.jq)(e,"type","ready");return!t||"True"===t?.status}get stateDisplay(){return this.isReady?"Active":"Not Ready"}get stateColor(){const e=this.stateDisplay;return(0,l.uU)(e)}get version(){return this?.status?.version}get templates(){return this.$rootGetters["harvester/all"](d.rk.VM_TEMPLATE)}get machineType(){return this.vm?.spec?.template?.spec?.domain?.machine?.type||""}get templateId(){return this.spec.templateId}launchFromTemplate(){const e=this.currentTemplate,t=e.id,n=this.id,r=this.currentRouter();r.push({name:`${u.KR}-c-cluster-resource-create`,params:{resource:d.rk.VM},query:{templateId:t,versionId:n}})}cloneTemplate(e={}){const t=this.detailLocation;t.query={...t.query,[i.g]:i.G5,[i.AS]:i.xz,...e},this.currentRouter().push(t)}goToViewConfig(e={}){const t=this.detailLocation;t.query={...t.query,[i.g]:i.nW,[i.AS]:i.au,templateId:this.templateId,...e},this.currentRouter().push(t)}get currentTemplate(){return(0,r.find)(this.templates,e=>e.id===this.templateId)}async setDefaultVersion(e={}){const t=this.currentTemplate;t.spec.defaultVersionId=this.id,await t.save()}get cpuPinningFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("cpuPinning")}get defaultVersion(){const e=this.$rootGetters["harvester/all"](d.rk.VM_TEMPLATE),t=e.find(e=>this.templateId===e.id);return t?.status?.defaultVersion}get isDefaultVersion(){return this.defaultVersion===this?.status?.version}get customValidationRules(){const e=[];return e}get instanceLabels(){const e=this.spec?.vm?.spec?.template?.metadata?.labels||{};return(0,r.omitBy)(e,(e,t)=>(0,c.HV)(t,o.l))}setInstanceLabels(e){this.spec?.vm?.spec?.template?.metadata?.labels||(0,s.hZ)(this,"spec.vm.spec.template.metadata.labels",{});const t=this.spec.vm.spec.template.metadata.labels||{},n=(0,r.pickBy)(t,(e,t)=>(0,c.HV)(t,o.l));this.spec.vm.spec.template.metadata["labels"]={...n,...e}}get tpmPersistentStateFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("tpmPersistentState")}get efiPersistentStateFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("efiPersistentState")}get systemAnnotations(){const e=this.annotations||{};return Object.keys(e).filter(e=>e.includes(o.r.TEMPLATE_VERSION_CUSTOM_NAME))}}},43842:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return c}});var r=n(39975),i=n(2841),o=n(41837);const{UNTAGGED:a,OVERLAY:s,L2TRUNK_VLAN:l}=o.AW;class c extends r.A{applyDefaults(){const e=this.spec||{config:JSON.stringify({cniVersion:"0.3.1",name:"",type:"bridge",bridge:"",promiscMode:!0,vlan:"",ipam:{}})};this.spec=e}get parseConfig(){try{return JSON.parse(this.spec.config)||{}}catch(e){return{}}}get isSystem(){const e=this.$rootGetters["systemNamespaces"];return!!e.includes(this.metadata?.namespace)}get isIpamStatic(){return"static"===this.parseConfig.ipam?.type}get clusterNetwork(){return this?.metadata?.labels?.[i.rk.CLUSTER_NETWORK]}get vlanType(){const e=this.metadata?.labels||{},t=e[i.rk.NETWORK_TYPE];return t}get vlanId(){return this.vlanType===a||this.vlanType===s||this.vlanType===l?"N/A":this.parseConfig.vlan}get customValidationRules(){const e=[{nullable:!1,path:"metadata.name",required:!0,minLength:1,maxLength:63,translationKey:"harvester.fields.name"}];return e}get connectivity(){const e=this.metadata?.annotations||{},t=e[i.rk.NETWORK_ROUTE];let n={};if(this.vlanType===a||this.vlanType===s||this.vlanType===l)return"N/A";try{n=JSON.parse(t||"{}")}catch{return"invalid"}const r=n.connectivity;return"false"===r?"inactive":"true"===r?"active":r}}},13459:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return a}});var r=n(76978),i=n(32766),o=n(24222);class a extends o["default"]{get groupByVpc(){return this.spec?.vpc||""}get doneOverride(){const e=(0,r.o8)(this.listLocation);return e.params.resource=i.rk.VPC,e}get parentLocationOverride(){return{...this.listLocation,params:{...this.listLocation.params,resource:i.rk.VPC}}}}},58899:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return a}});var r=n(76978),i=n(32766),o=n(24222);class a extends o["default"]{get parentNameOverride(){return this.$rootGetters["i18n/t"](`typeLabel."${i.rk.VPC}"`,{count:1})?.trim()}get doneOverride(){const e=(0,r.o8)(this.listLocation);return e.params.resource=i.rk.VPC,e}get parentLocationOverride(){return{...this.listLocation,params:{...this.listLocation.params,resource:i.rk.VPC}}}}},50784:function(e,t,n){"use strict";n.r(t),n.d(t,{OFF:function(){return O},default:function(){return W}});var r=n(20246),i=n(45250),o=n(20652),a=n(73883),s=n(35664),l=n(68851),c=n(95799),u=n(76978),d=n(2602),h=n(14220),p=n(92043),f=n(66490),m=n(41837),g=n(32766),v=n(24222),b=n(58434),y=n(88992),w=n(14127);const O="Off",S="The virtual machine is waiting for resources to become available.",E="VM error",x="Stopping",_="Unschedulable",k="Waiting",C="Not Ready",A="AgentConnected",T="Paused",R="This VM has been paused. If you wish to unpause it, please click the Unpause button below. For further details, please check with your system administrator.",N="POD_NOT_SCHEDULABLE",P="POD_CONTAINER_FAILING",I="POD_FAILED",M="POD_CRASHLOOP_BACKOFF",D="POD_STATUS_UNKNOWN",L=[N,P,I,M,D],B="POD_STATUS_COMPLETED",$="POD_STATUS_SUCCEEDED",V="POD_STATUS_RUNNING",F=[V,B,$],j={Always:"Always",RerunOnFailure:"RerunOnFailure",Halted:"Halted",Manual:"Manual"},U={Start:"Start",Stop:"Stop"},G="This virtual machine will start shortly. Preparing storage, networking, and compute resources.",H={Pending:"Pending",Scheduling:"Scheduling",Scheduled:"Scheduled",Running:"Running",Succeeded:"Succeeded",Failed:"Failed",Unknown:"Unknown"};function q(e){return(0,y.r)(e,"podOwnerIndex",e=>{const t=new Map;for(const n of e){const e=n.metadata?.ownerReferences?.[0]?.name;e&&t.set(`${n.metadata.namespace}/${e}`,n)}return t})}function Q(e,t,n){const r=e["all"](s.Sm);if(Array.isArray(r))return q(r).get(`${t}/${n}`)}function z(e,t,n){const r=[];for(const i of new Set(n)){const n=e["byId"](s.YH,`${t}/${i}`);n&&r.push(n)}return r}const K=["pod has unbound immediate PersistentVolumeClaims"];class W extends v["default"]{get availableActions(){let e=super._availableActions;(this.isCloneBackendStorageCloning||this.isCloneBackendStorageFailed)&&(e=e.filter(({action:e})=>"goToClone"!==e));const t=e.find(e=>"goToClone"===e.action);t&&(t.action="goToCloneVM");const n=this.$getters?.["schemaFor"]?.(g.rk.SCHEDULE_VM_BACKUP),r=!!n&&(0,y.r)(n,"canPost",e=>!!e.collectionMethods?.find(e=>["post"].includes(e.toLowerCase())));return[{action:"stopVM",altAction:"altStopVM",enabled:!!this.actions?.stop,icon:"icon icon-close",label:this.t("harvester.action.stop"),bulkable:!0,bulkAction:"stopVM"},{action:"forceStop",enabled:!!this.actions?.forceStop,icon:"icon icon-close",label:this.t("harvester.action.forceStop"),bulkable:!0},{action:"pauseVM",altAction:"altPauseVM",enabled:!!this.actions?.pause,icon:"icon icon-pause",label:this.t("harvester.action.pause")},{action:"unpauseVM",enabled:!!this.actions?.unpause,icon:"icon icon-spinner",label:this.t("harvester.action.unpause")},{action:"restartVM",altAction:"altRestartVM",enabled:!!this.actions?.restart,icon:"icon icon-refresh",label:this.t("harvester.action.restart"),bulkable:!0,bulkAction:"restartVM"},{action:"softrebootVM",altAction:"doSoftReboot",enabled:!!this.actions?.softreboot,icon:"icon icon-pipeline",label:this.t("harvester.action.softreboot")},{action:"startVM",enabled:!!this.actions?.start,icon:"icon icon-play",label:this.t("harvester.action.start"),bulkable:!0,bulkAction:"startVM"},{action:"backupVM",enabled:!!this.actions?.backup&&!this.isBackupTargetUnavailable,icon:"icon icon-backup",label:this.t("harvester.action.backup")},{action:"takeVMSnapshot",enabled:!!this.actions?.snapshot||!!this.actions?.backup,icon:"icon icon-snapshot",label:this.t("harvester.action.vmSnapshot")},{action:"editVMQuota",enabled:!!this.actions?.updateResourceQuota&&!!this.actions.deleteResourceQuota,icon:"icon icon-storage",label:this.t("harvester.action.editVMQuota")},{action:"cpuMemoryHotplug",enabled:!!this.actions?.cpuAndMemoryHotplug,icon:"icon icon-os-management",label:this.t("harvester.action.cpuAndMemoryHotplug")},{action:"createSchedule",enabled:r&&this.schedulingVMBackupFeatureEnabled,icon:"icon icon-history",label:this.t("harvester.action.createSchedule")},{action:"restoreVM",enabled:!!this.actions?.restore,icon:"icon icon-backup-restore",label:this.t("harvester.action.restore")},{action:"ejectCDROM",enabled:!this.hotplugCdRomEnabled&&!!this.actions?.ejectCdRom,icon:"icon icon-delete",label:this.t("harvester.action.ejectCDROM")},{action:"migrateVM",enabled:!!this.actions?.migrate,icon:"icon icon-copy",label:this.t("harvester.action.vmMigrate"),bulkable:!0,bulkAction:"migrateVM"},{action:"abortMigrationVM",enabled:!!this.actions?.abortMigration,icon:"icon icon-close",label:this.t("harvester.action.abortMigration")},{action:"storageMigration",enabled:!!this.actions?.storageMigration,icon:"icon icon-copy",label:this.t("harvester.action.storageMigration")},{action:"cancelStorageMigration",enabled:!!this.actions?.cancelStorageMigration,icon:"icon icon-close",label:this.t("harvester.action.cancelStorageMigration")},{action:"addHotplugVolume",enabled:!!this.actions?.addVolume,icon:"icon icon-plus",label:this.t("harvester.action.addHotplugVolume")},{action:"addHotplugNic",enabled:this.hotplugNicFeatureEnabled&&!!this.actions?.addNic,icon:"icon icon-plus",label:this.t("harvester.action.addHotplugNic")},{action:"createTemplate",enabled:!!this.actions?.createTemplate,icon:"icon icon-copy",label:this.t("harvester.action.createTemplate")},{action:"openLogs",enabled:!!this.podResource,icon:"icon icon-fw icon-chevron-right",label:this.t("harvester.action.viewlogs"),total:1},...e]}applyDefaults(e=this,t){const n={runStrategy:"RerunOnFailure",template:{metadata:{annotations:{},labels:{}},spec:{domain:{machine:{type:""},cpu:{cores:null,sockets:1,threads:1},devices:{inputs:[{bus:"usb",name:"tablet",type:"tablet"}],interfaces:[{masquerade:{},model:"virtio",name:"default"}],disks:[]},resources:{limits:{memory:null,cpu:""}},features:{acpi:{enabled:!0}}},evictionStrategy:"LiveMigrateIfPossible",hostname:"",networks:[{name:"default",pod:{}}],volumes:[],affinity:{}}}};t!==h.dT&&(this.metadata["annotations"]={[d.r.VOLUME_CLAIM_TEMPLATE]:"[]"},this.metadata["labels"]={},this["spec"]=n)}cleanForNew(){this.$dispatch("cleanForNew",this),this.spec.template.spec.hostname="";const e=this.spec.template.spec.domain.devices?.interfaces||[];for(let n=0;n<e.length;n++)e[n].macAddress&&(e[n].macAddress="");const t=this.volumeClaimTemplates.map(e=>(e?.spec?.dataSource&&delete e.spec.dataSource,e));this.metadata.annotations[d.r.VOLUME_CLAIM_TEMPLATE]=JSON.stringify(t)}restartVM(e=this){this.$dispatch("promptModal",{resources:e,action:"restart",warningMessageKey:"dialog.confirmExecution.restart.message",component:"ConfirmExecutionDialog"})}doSoftReboot(){this.doActionGrowl("softreboot",{})}softrebootVM(e=this){this.$dispatch("promptModal",{resources:e,action:"softreboot",warningMessageKey:"dialog.confirmExecution.softreboot.message",component:"ConfirmExecutionDialog"})}openLogs(){this.$dispatch("wm/open",{id:`${this.id}-logs`,label:this.nameDisplay,icon:"file",component:"ContainerLogs",attrs:{pod:this.podResource,initialContainer:this.podResource.metadata.annotations["kubectl.kubernetes.io/default-container"]}},{root:!0})}createSchedule(e=this){const t=this.currentRouter();t.push({name:`${o.KR}-c-cluster-resource-create`,params:{resource:g.rk.SCHEDULE_VM_BACKUP},query:{vmNamespace:this.metadata.namespace,vmName:this.metadata.name}})}storageMigration(e=this){this.$dispatch("promptModal",{resources:e,component:"HarvesterStorageMigrationDialog"})}backupVM(e=this){this.$dispatch("promptModal",{resources:e,component:"HarvesterBackupModal"})}takeVMSnapshot(e=this){this.$dispatch("promptModal",{resources:e,component:"HarvesterVMSnapshotDialog"})}editVMQuota(e=this){this.$dispatch("promptModal",{resources:e,snapshotSizeQuota:this.snapshotSizeQuota,component:"HarvesterQuotaDialog"})}unplugVolume(e){const t=this;this.$dispatch("promptModal",{resources:t,name:e,type:"volume",component:"HarvesterHotUnplug"})}ejectCdRomVolume(e){const t=this;this.$dispatch("promptModal",{resources:t,name:e,type:"cdrom",component:"HarvesterHotUnplug"})}unplugNIC(e){const t=this;this.$dispatch("promptModal",{resources:t,name:e,type:"network",component:"HarvesterHotUnplug"})}restoreVM(e=this){this.$dispatch("promptModal",{resources:e,component:"HarvesterRestoreDialog"})}get machineType(){return this.spec?.template?.spec?.domain?.machine?.type||""}get realAttachNodeName(){const e=this.$getters["byId"](g.rk.VMI,this.id),t=e?.status?.nodeName,n=this.$getters["byId"](s.NW,t);return n?.nameDisplay||""}get nodeName(){const e=this.$getters["byId"](g.rk.VMI,this.id),t=e?.status?.nodeName,n=this.$getters["byId"](s.NW,t);return n?.id}pauseVM(e=this){this.$dispatch("promptModal",{resources:e,action:"pause",warningMessageKey:"dialog.confirmExecution.pause.message",component:"ConfirmExecutionDialog"})}altPauseVM(){this.doActionGrowl("pause",{})}goToCloneVM(e=this){this.$dispatch("promptModal",{resources:e,component:"CloneVmDialog"})}unpauseVM(){this.doActionGrowl("unpause",{})}stopVM(e=this){this.$dispatch("promptModal",{resources:e,action:"stop",warningMessageKey:"dialog.confirmExecution.stop.message",component:"ConfirmExecutionDialog"})}async altRestartVM(){await this.doActionGrowl("restart",{}),this.$dispatch("promptModal",{performCallback:!0,clearTableSelection:!0})}async altStopVM(){await this.doActionGrowl("stop",{}),this.$dispatch("promptModal",{performCallback:!0,clearTableSelection:!0})}async forceStop(){await this.doActionGrowl("forceStop",{}),this.$dispatch("promptModal",{performCallback:!0,clearTableSelection:!0})}async startVM(e=this){const t=Array.isArray(e)?e:[e];for(const n of t)await n.doActionGrowl("start",{});this.$dispatch("promptModal",{performCallback:!0,clearTableSelection:!0})}async download(){await super.download(),this.$dispatch("promptModal",{performCallback:!0,clearTableSelection:!0})}async downloadBulk(e){await super.downloadBulk(e),this.$dispatch("promptModal",{performCallback:!0,clearTableSelection:!0})}migrateVM(e=this){this.$dispatch("promptModal",{resources:e,component:"HarvesterMigrationDialog"})}ejectCDROM(e=this){this.$dispatch("promptModal",{resources:e,component:"HarvesterEjectCDROMDialog"})}cpuMemoryHotplug(e=this){this.$dispatch("promptModal",{resources:e,component:"HarvesterCPUMemoryHotPlugDialog"})}abortMigrationVM(){this.doActionGrowl("abortMigration",{})}cancelStorageMigration(){this.doActionGrowl("cancelStorageMigration",{})}createTemplate(e=this){this.$dispatch("promptModal",{resources:e,component:"HarvesterCloneTemplate"})}addHotplugVolume(e=this){this.$dispatch("promptModal",{resources:e,component:"HarvesterAddHotplugVolumeModal"})}insertCdRomVolume(e){const t=this;this.$dispatch("promptModal",{resources:t,name:e,component:"HarvesterInsertCdRomVolume"})}addHotplugNic(e=this){this.$dispatch("promptModal",{resources:e,component:"HarvesterAddHotplugNic"})}get networksName(){const e=this.spec.template.spec.domain.devices?.interfaces||[];return e.map(e=>e.name)}get isOff(){return this.isVMExpectedRunning?null:{status:O}}get isWaitingForVMI(){return this&&this.isVMExpectedRunning&&!this.isVMCreated?{status:k,message:S}:null}get cpuPinningFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("cpuPinning")}get isCpuPinning(){return!0===this.spec?.template?.spec?.domain?.cpu?.dedicatedCpuPlacement}get isVMExpectedRunning(){if(!this?.spec)return!1;const{running:e=null,runStrategy:t=null}=this.spec,n=this?.status?.conditions||[];if(e)return!0;if(null!==t){let e;switch(t){case j.Halted:return!1;case j.Always:return!0;case j.RerunOnFailure:return!("ErrorUnschedulable"!==this.status?.printableStatus||!n.find(e=>e.message&&e.message.includes(K)))||["Starting","Running"].includes(this.status?.printableStatus);case j.Manual:default:return e=new Set((this.status?.stateChangeRequests||[]).map(e=>e?.action)),!e.has(U.Stop)&&(!!e.has(U.Start)||(0===e.size?["Starting","Running"].includes(this.status?.printableStatus):this.isVMCreated))}}return!1}get podResource(){const e=this.$getters["byId"](g.rk.VMI,this.id);if(e?.metadata?.name)return Q(this.$getters,e.metadata.namespace,e.metadata.name)}get isPaused(){const e=this.vmi?.status?.conditions||[],t=e.filter(e=>e.type===T).length>0;return t?{status:T,message:R}:null}get isVMError(){const e=(0,u.Jt)(this,"status.conditions"),t=(0,l.jq)(e,"type","Failure");return t?{status:E,detailedMessage:t.message}:null}get nsResourceQuota(){const e=this.$getters["all"](g.rk.RESOURCE_QUOTA);return e.find(e=>e.namespace===this.metadata.namespace)}get snapshotSizeQuota(){return this.nsResourceQuota?.spec?.snapshotLimit?.vmTotalSnapshotSizeQuota?.[this.metadata.name]}get vmi(){return this.$getters["byId"](g.rk.VMI,this.id)}get volumes(){const e=this.spec.template.spec.volumes?.map(e=>e.persistentVolumeClaim?.claimName).filter(e=>!!e)||[];return z(this.$getters,this.metadata.namespace,e)}get lvmVolumes(){return this.volumes.filter(e=>e?.isLvm)}get longhornV2Volumes(){return this.volumes.filter(e=>e?.isLonghornV2)}get cloneBackendStorageStatus(){return this.metadata?.annotations?.[d.r.CLONE_BACKEND_STORAGE_STATUS]?.toLowerCase()||""}get isCloneBackendStorageCloning(){return"cloning"===this.cloneBackendStorageStatus}get isCloneBackendStorageFailed(){return"failed"===this.cloneBackendStorageStatus}get encryptedVolumeType(){const e=this.volumes;return e&&0!==e.length?e.every(e=>e.isEncrypted)?"all":e.some(e=>e.isEncrypted)?"partial":"none":"none"}get isError(){const e=(0,u.Jt)(this.vmi,"status.conditions"),t=(0,l.jq)(e,"type","Failure");return t?{status:"VMI error",detailedMessage:t.message}:this?.vmi?.status?.phase}get isRunning(){const e=(0,u.Jt)(this.vmi,"status.conditions"),t="True"===(0,l.jq)(e,"type","Ready")?.status;return this.vmi?.status?.phase===H.Running&&t?{status:H.Running}:null}get isNotReady(){const e=(0,u.Jt)(this.vmi,"status.conditions"),t=(0,l.jq)(e,"type","Ready");return"False"===t?.status&&this.vmi?.status?.phase===H.Running?{status:C}:null}get isPending(){return this&&!this.isVMExpectedRunning&&this.isVMCreated&&this.vmi?.status?.phase===H.Pending||this.isCloneBackendStorageCloning?{status:H.Pending}:null}get isCloneFailed(){return this.isCloneBackendStorageFailed?{status:H.Failed}:null}get isStopping(){return this&&!this.isVMExpectedRunning&&this.isVMCreated&&void 0!==this.vmi?.status?.phase&&this.vmi?.status?.phase!==H.Succeeded&&this.vmi?.status?.phase!==H.Pending?{status:x}:null}get isStarting(){if(this.isVMExpectedRunning&&this.isVMCreated){if(this.podResource){const e=this.podResource.getPodStatus;if(!F.includes(e?.status))return{...e,status:"Starting",message:G,detailedMessage:e?.message,pod:this.podResource}}return{status:"Starting",message:G,pod:this.podResource}}return null}get isUnschedulable(){const e=this.status?.conditions?.find(e=>e.reason===_);return e&&(this.isStopping||this.isStarting)?{status:_,message:e.message||"VM is unschedulable"}:null}get isTerminating(){return!!this?.metadata?.deletionTimestamp}get otherState(){const e=this.vmi&&[H.Scheduling,H.Scheduled].includes(this.vmi?.status?.phase)&&{status:"Starting",message:G}||this.vmi&&this.vmi.status?.phase===H.Pending&&{status:"VMI_WAITING",message:S}||this.vmi&&this.vmi?.status?.phase===H.Failed&&{status:"VMI_ERROR"}||this.isVMExpectedRunning&&!this.isVMCreated&&{status:"Pending"}||{status:"UNKNOWN"};return e}get isVMCreated(){return!!this?.status?.created}get getDataVolumeTemplates(){return null===(0,u.Jt)(this,"spec.volumeClaimTemplates")?[]:this.spec.volumeClaimTemplates}get restoreResource(){const e=`${this.metadata.namespace}/${(0,u.Jt)(this,`metadata.annotations."${d.r.RESTORE_NAME}"`)}`,t=this.$getters["byId"](g.rk.RESTORE,e);if(t){const e=`${t.spec?.virtualMachineBackupNamespace}/${t.spec?.virtualMachineBackupName}`,n=this.$getters["byId"](g.rk.BACKUP,e);t.fromSnapshot=!!n&&n.spec?.type!==m.aS.BACKUP}return t}get restoreProgress(){if(this.isVMError||this.isTerminating)return{};const e=this.restoreResource?.status;return void 0!==e?{type:"restore",percentage:e?.progress||0,details:{volumes:e?.restores||[]}}:{}}get restoreState(){const e=this.restoreResource;return!e||e.isComplete}get actualState(){if(!this.restoreState)return"Restoring";if(this.isTerminating)return"Terminating";if(this?.vmi?.migrationState&&"Failed"!==this.vmi.migrationState.status)return this.vmi.migrationState.status;const e=this.isUnschedulable?.status||this.isPaused?.status||this.isVMError?.status||this.isCloneFailed?.status||this.isPending?.status||this.isStopping?.status||this.isOff?.status||this.isError?.status||this.isRunning?.status||this.isNotReady?.status||this.isStarting?.status||this.isWaitingForVMI?.status||this.otherState?.status;return e}get warningMessage(){if(this.metadata?.annotations[d.r.VM_INSUFFICIENT])return{message:this.metadata?.annotations[d.r.VM_INSUFFICIENT],canDismiss:!0};const e=(0,u.Jt)(this,"status.conditions"),t=(0,l.jq)(e,"type","Failure");if(t)return{status:E,message:t.message};const n=(0,u.Jt)(this.vmi,"status.conditions"),r=(0,l.jq)(n,"type","Failure");if(r)return{status:"VMI error",detailedMessage:r.message};if((this.vmi||this.isVMCreated)&&this.podResource){const e=this.podResource.getPodStatus;if(L.includes(e?.status))return{...e,status:"LAUNCHER_POD_ERROR",pod:this.podResource}}return null}get migrationMessage(){return this?.vmi?.migrationState&&"Failed"===this.vmi.migrationState.status?{...this.actualState,message:this.t("harvester.modal.migration.failedMessage")}:null}get stateDisplay(){return this.actualState}get stateColor(){const e=this.actualState;return(0,a.uU)(e)}get stateSort(){const e=this.actualState;return(0,a.gs)((0,a.uU)(e),e)}get networkIps(){let e="";const t=[],n=this.spec.template?.spec?.volumes||[];n.forEach(t=>{t.cloudInitNoCloud&&(e=t.cloudInitNoCloud.networkData)});try{const n=(0,r.load)(e);if(n?.config&&Array.isArray(n.config)){const e=n.config;e.forEach(e=>{if(e?.subnets&&Array.isArray(e.subnets)){const n=e.subnets;n.forEach(e=>{e.address&&t.push(e.address)})}})}}catch(i){}return t}get volumeClaimTemplates(){return(0,f.vN)(this)}get persistentVolumeClaimName(){const e=this.spec.template.spec.volumes||[];return e.map(e=>e?.persistentVolumeClaim?.claimName).filter(e=>!!e)}get rootImageId(){let e="";const t=this.spec.template.spec.volumes||[],n=t[0]?.persistentVolumeClaim?.claimName,r=this.volumeClaimTemplates.find(e=>n===e?.metadata?.name);if(!r){const e=this.$getters["byId"](s.YH,`${this.metadata.namespace}/${n}`);if(e)return e?.metadata?.annotations?.["harvesterhci.io/imageId"]}return this.volumeClaimTemplates.find(t=>(e=t?.metadata?.annotations?.["harvesterhci.io/imageId"],!!e)),e}get restoreName(){return(0,u.Jt)(this,`metadata.annotations."${d.r.RESTORE_NAME}"`)||""}get customValidationRules(){const e=[{nullable:!1,path:"metadata.name",required:!0,minLength:1,maxLength:63,translationKey:"harvester.fields.name"},{nullable:!1,path:"spec.template.spec",validators:["vmNetworks"]},{nullable:!1,path:"spec",validators:["vmDisks"]}];return e}get attachNetwork(){const e=this.spec?.template?.spec?.networks||[],t=e.find(e=>e.multus);return!!t}get memorySort(){const e=(0,b.J)(this).memory,t=(0,c.ao)(e);return parseInt(t,10)}get ingoreVMMessage(){const e=[{name:"unavailable",error:!1,vmState:this.actualState===T}],t=this.metadata?.state;return e.find(e=>e.name===t?.name&&e.error===t?.error&&e.vmState)||K.find(e=>super.stateDescription?.includes(e))||this.isOff}get isRestartRequired(){const e=(0,u.Jt)(this,"status.conditions"),t=(0,l.jq)(e,"type","RestartRequired");return t&&"True"===t.status}get stateDescription(){if(this.isRestartRequired)return this.t("harvester.virtualMachine.hotplug.restartVMMessage");const e=this.restoreResource?.status?.conditions||[],t=e.find(e=>!0===e.error&&"Error"===e.reason&&"Ready"===e.type);return t?.message?t.message:this.ingoreVMMessage?"":super.stateDescription}get displayCPU(){return(0,b.J)(this).cpu}get displayMemory(){return(0,b.J)(this).memory}get isQemuInstalled(){const e=this.vmi?.status?.conditions||[],t=e.find(e=>e.type===A);return"True"===t?.status}get instanceLabels(){const e=this.spec?.template?.metadata?.labels||{};return(0,i.omitBy)(e,(e,t)=>(0,p.HV)(t,d.l))}get hostDevices(){return this.spec?.template?.spec?.domain?.devices?.hostDevices||[]}get provisionedVGpus(){try{const e=JSON.parse(this.metadata?.annotations[d.r.VM_DEVICE_ALLOCATION_DETAILS]||"{}");return e?.gpus||{}}catch(e){return{}}}get provisionedHostDevices(){try{const e=JSON.parse(this.metadata?.annotations[d.r.VM_DEVICE_ALLOCATION_DETAILS]||"{}");return e?.hostdevices||{}}catch(e){return{}}}get schedulingVMBackupFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("schedulingVMBackup")}get nameDisplay(){return this.metadata?.annotations?.[d.r.VM_DISPLAY_NAME]||this.metadata?.name||this.id}get volumeEncryptionFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("volumeEncryption")}get tpmPersistentStateFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("tpmPersistentState")}get efiPersistentStateFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("efiPersistentState")}get thirdPartyStorageFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("thirdPartyStorage")}get vmMachineTypeAutoFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("vmMachineTypeAuto")}get hotplugNicFeatureEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("hotplugNic")}get hotplugCdRomEnabled(){return this.$rootGetters["harvester-common/getFeatureEnabled"]("hotplugCdRom")}get isBackupTargetUnavailable(){const e=this.$rootGetters["harvester/byId"](g.rk.SETTING,"backup-target");return e?(0,y.r)(e,"unavailable",w.S):(0,w.S)(e)}setInstanceLabels(e){this.spec?.template?.metadata?.labels||(0,u.hZ)(this,"spec.template.metadata.labels",{});const t=this.spec.template.metadata.labels||{},n=(0,i.pickBy)(t,(e,t)=>(0,p.HV)(t,d.l));this.spec.template.metadata["labels"]={...n,...e}}}},79095:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return h}});var r=n(73883),i=n(35664),o=n(2602),a=n(66490),s=n(32766),l=n(24222);const c="Paused",u="This VM has been paused. If you wish to unpause it, please click the Unpause button below. For further details, please check with your system administrator.",d={Pending:"Pending",Scheduling:"Scheduling",Scheduled:"Scheduled",Running:"Running",Succeeded:"Succeeded",Failed:"Failed",Unknown:"Unknown"};class h extends l["default"]{get _availableActions(){const e=super._availableActions,t=e.find(e=>"promptRemove"===e.action);return[t]}get stateDisplay(){return this?.metadata?.deletionTimestamp?"Terminating":this?.status?.phase}get stateBackground(){return(0,r.uU)(this.stateDisplay).replace("text-","bg-")}get stateColor(){const e=this.stateDisplay;return(0,r.uU)(e)}get vmimResource(){const e=this.$getters["all"](s.rk.VMIM)||[];return(0,a.OG)(e,this.metadata?.namespace,this.metadata?.name)||[]}get migrationState(){const e=this.metadata?.annotations?.[o.r.MIGRATION_STATE],t=this.vmimResource;return t?.status?.phase===d.Failed?{type:"migration",status:d.Failed}:t?.status?.phase&&e?{type:"migration",status:e}:null}get migrationStateBackground(){const e=this.migrationState.status;return(0,r.uU)(e).replace("text-","bg-")}get isPaused(){const e=this?.status?.conditions||[],t=e.filter(e=>e.type===c).length>0;return t?{status:c,message:u}:null}get isRunning(){return this?.status?.phase===d.Running?{status:d.Running}:null}get isTerminated(){const e=this?.status?.conditions||[];return"False"===e.find(e=>"Ready"===e.type)?.status}get getVMIApiPath(){const e=this.$rootGetters["clusterId"];if(this.$rootGetters["isMultiCluster"]){const t=`/k8s/clusters/${e}`;return`${t}/apis/subresources.kubevirt.io/v1/namespaces/${this.metadata.namespace}/virtualmachineinstances/${this.name}/vnc`}return`/apis/subresources.kubevirt.io/v1/namespaces/${this.metadata.namespace}/virtualmachineinstances/${this.name}/vnc`}get realAttachNodeName(){const e=this?.status?.nodeName,t=this.$getters["byId"](i.NW,e);return t?.nameDisplay||""}get getSerialConsolePath(){const e=this.$rootGetters["clusterId"];if(this.$rootGetters["isMultiCluster"]){const t=`/k8s/clusters/${e}`;return`${t}/apis/subresources.kubevirt.io/v1/namespaces/${this.metadata.namespace}/virtualmachineinstances/${this.name}/console`}return`/apis/subresources.kubevirt.io/v1/namespaces/${this.metadata.namespace}/virtualmachineinstances/${this.name}/console`}}},68917:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return s}});var r=n(76978),i=n(24222),o=n(32766);const a="Not Ready";class s extends i["default"]{applyDefaults(){const e=this.spec||{},t=this.metadata||{};e.ranges=e.ranges||[],e.selector=e.selector||{},e.selector.network=e.selector.network||"",this["spec"]=e,this["metadata"]=t}get customValidationRules(){return[{nullable:!1,path:"metadata.name",required:!0,translationKey:"generic.name",type:"dnsLabel"},{nullable:!1,path:"spec.ranges",type:"array",validators:["ranges"]}]}get subnetDisplay(){const e=this.spec?.ranges||[];return e.map(e=>e.subnet).join(", ")}get startIPDisplay(){const e=this.spec?.ranges||[];return e.filter(e=>e.startIP).map(e=>e.startIP).join(", ")}get endIPDisplay(){const e=this.spec?.ranges||[];return e.filter(e=>e.endIP).map(e=>e.endIP).join(", ")}get details(){const e=[{label:this.t("harvester.ipPool.availableIP.label"),content:this.status?.available}];return e}get doneOverride(){const e=(0,r.o8)(this.listLocation);return e.params.resource=o.rk.IP_POOL,e}get parentLocationOverride(){return{...this.listLocation,params:{...this.listLocation.params,resource:o.rk.IP_POOL}}}get isReady(){const e=(this?.status?.conditions||[]).find(e=>"Ready"===e.type)||{};return"True"===e?.status}get stateDisplay(){return this.isReady?super.stateDisplay:a}get stateBackground(){return this.isReady?super.stateBackground:"bg-warning"}}},61772:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return l}});var r=n(76978),i=n(24222),o=n(32766);const a="vm",s="Not Ready";class l extends i["default"]{applyDefaults(){const e=this.spec||{},t=this.metadata||{};e.workloadType=e.workloadType||a,e.ipam=e.ipam||"dhcp",e.healthCheck=e.healthCheck||{},e.backendServerSelector=e.backendServerSelector||{},(0,r.hZ)(this,"spec",e),(0,r.hZ)(this,"metadata",t)}get workloadTypeDisplay(){const e=this.spec?.workloadType||"cluster";return this.$rootGetters["i18n/t"](`harvester.loadBalancer.workloadType.options.${e}`)}get ipamDisplay(){const e=this.spec?.ipam;return this.$rootGetters["i18n/t"](`harvester.loadBalancer.ipam.options.${e}`)}get customValidationRules(){return[{nullable:!1,path:"metadata.name",required:!0,translationKey:"generic.name",type:"dnsLabel"}]}get canCustomEdit(){return this.$rootGetters["type-map/hasCustomEdit"](this.type,this.id)&&this.spec.workloadType===a}get canUpdate(){return this.hasLink("update")&&this.$rootGetters["type-map/optionsFor"](this.type).isEditable&&this.spec.workloadType===a}get canClone(){return this.spec.workloadType===a}get details(){const e=[{label:this.t("harvester.loadBalancer.ipam.label"),content:this.ipamDisplay},{label:this.t("harvester.loadBalancer.workloadType.label"),content:this.workloadTypeDisplay},{label:this.t("tableHeaders.address"),content:this.status.address}];return e}get doneOverride(){const e=(0,r.o8)(this.listLocation);return e.params.resource=o.rk.LB,e}get parentLocationOverride(){return{...this.listLocation,params:{...this.listLocation.params,resource:o.rk.LB}}}get isReady(){const e=(this?.status?.conditions||[]).find(e=>"Ready"===e.type)||{};return"True"===e?.status}get stateDisplay(){return this.isReady?super.stateDisplay:s}get stateBackground(){return this.isReady?super.stateBackground:"bg-warning"}}},28433:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return a}});var r=n(39975);const i="healthy",o="warning";class a extends r.A{get used(){let e=0;return this.disks.filter(e=>e.allowScheduling).map(t=>{t?.storageAvailable&&t?.storageMaximum&&(e+=t.storageMaximum-t.storageAvailable)}),e}get disks(){const e=this?.status?.diskStatus||{},t=this?.spec?.disks||{};return Object.keys(t).map(n=>{const r=e[n]?.conditions||[],a=r.find(e=>"Ready"===e.type)||{},s=r.find(e=>"Schedulable"===e.type)||{};let l;return l="True"!==a?.status||"True"!==s?.status?o:i,{...e[n],...t[n],id:n,state:l}})||[]}}},82607:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return i}});var r=n(24220);class i extends r["default"]{get _availableActions(){const e=!!this.linkFor("update");return super._availableActions.map(t=>"goToEdit"===t.action?{...t,enabled:e}:t)}}},12032:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(76061),i=n(50889);class o extends r["default"]{get _availableActions(){const e=super._availableActions;return this.$rootGetters["isStandaloneHarvester"]&&this.id===i.EP.UI_PL?e.filter(e=>!["goToClone","promptRemove"].includes(e.action)):e}}},11971:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(76978),i=n(24222);class o extends i["default"]{applyDefaults(){const e={baseboardSpec:{connection:{authSecretRef:{},insecureTLS:!1}},events:{enabled:!0,pollingInterval:"1h"},primaryDisk:"",managementInterfaceMacAddress:""};(0,r.hZ)(this,"metadata.annotations",{}),(0,r.hZ)(this,"spec",this.spec||e),(0,r.hZ)(this,"spec.baseboardSpec",this.spec?.baseboardSpec||e.baseboardSpec),(0,r.hZ)(this,"spec.baseboardSpec.connection",this.spec?.baseboardSpec?.connection||e.baseboardSpec.connection),(0,r.hZ)(this,"spec.baseboardSpec.connection.authSecretRef",this.spec?.baseboardSpec?.connection?.authSecretRef||{})}get warningMessages(){const e=[];return this.metadata?.state?.error&&e.push({text:this.metadata?.state.message}),e}get customValidationRules(){return[{path:"spec.events.pollingInterval",translationKey:"harvester.seeder.inventory.pollingInterval.label",validators:["interval"]}]}}},85696:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return s}});var r=n(76978),i=n(35664),o=n(32766),a=n(24222);class s extends a["default"]{get doneOverride(){const e=(0,r.o8)(this.listLocation);return e.params.resource=o.rk.CLUSTER_NETWORK,e}get parentLocationOverride(){return{...this.listLocation,params:{...this.listLocation.params,resource:o.rk.CLUSTER_NETWORK}}}get canDelete(){return this._canDelete&&"mgmt"!==this.id}get canUpdate(){return this.hasLink("update")&&this.$rootGetters["type-map/optionsFor"](this.type).isEditable&&"mgmt"!==this.id}get isReady(){const e=(this?.status?.conditions||[]).find(e=>"ready"===e.type)||{};return"True"===e?.status}get inStore(){return this.$rootGetters["currentProduct"].inStore}get nodes(){const e=this.$rootGetters[`${this.inStore}/all`](i.NW);return e.filter(e=>!e.isUnSchedulable&&"true"!==e.isEtcd)}get vlanStatuses(){const e=this.$rootGetters[`${this.inStore}/all`](o.rk.VLAN_STATUS),t=this.nodes.map(e=>e.id);return e.filter(e=>t.includes(e?.status?.node)&&this.id===e?.status?.clusterNetwork)||[]}get isReadyForStorageNetwork(){if("mgmt"===this.id)return!0;{const e=this.vlanStatuses.filter(e=>e.isReady)||[];return e.length===this.nodes.length&&this.isReady}}}},88272:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return s}});var r=n(68851),i=n(76978),o=n(32766),a=n(24222);class s extends a["default"]{get message(){const e=(0,i.Jt)(this,"status.conditions");return((0,r.jq)(e,"type","Ready")||{}).message}get isReady(){const e=(0,i.Jt)(this,"status.conditions");return"True"===((0,r.jq)(e,"type","Ready")||{})?.status}get nics(){return this?.status?.nics||[]}get attachNodeName(){return(0,i.Jt)(this,'metadata.labels."network.harvesterhci.io/nodename"')||""}get linkMessage(){return{name:this.attachNodeName,message:this.message,to:`${o.rk.HOST}/${this.attachNodeName}?mode=edit`}}}},70443:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return h}});var r=n(45250),i=n(76978),o=n(68851),a=n(2841),s=n(38823),l=n(35664),c=n(32766),u=n(24222);const d="Not Ready";class h extends u["default"]{applyDefaults(){const e={uplink:{nics:[],linkAttributes:{},bondOptions:{mode:"active-backup",miimon:-1}}};(0,i.hZ)(this,"spec",this.spec||e),(0,i.hZ)(this,"spec.uplink.linkAttributes",this.spec?.uplink?.linkAttributes||{}),(0,i.hZ)(this,"spec.uplink.bondOptions",this.spec?.uplink?.bondOptions||{})}get groupByClusterNetwork(){return this.spec?.clusterNetwork}get doneOverride(){const e=(0,i.o8)(this.listLocation);return e.params.resource=c.rk.CLUSTER_NETWORK,e}get parentLocationOverride(){return{...this.listLocation,params:{...this.listLocation.params,resource:c.rk.CLUSTER_NETWORK}}}get typeDisplay(){return"VLAN"}get _availableActions(){const e=super._availableActions,t=!!this.$getters?.["schemaFor"]?.(c.rk.VLAN_CONFIG)?.collectionMethods?.find(e=>["post"].includes(e.toLowerCase()));return t&&(0,o.PT)(e,0,this.migrateAction),e}get migrateAction(){return{action:"migrate",icon:"icon icon-copy",label:this.t("harvester.vlanConfig.action.migrate")}}migrate(e=this){this.$dispatch("promptModal",{resources:e,component:"HarvesterVlanConfigMigrateDialog"})}get inStore(){return this.$rootGetters["currentProduct"].inStore}get vlanStatuses(){const e=this.nodes.map(e=>e.id)||[],t=this.$rootGetters[`${this.inStore}/all`](c.rk.VLAN_STATUS);return t.filter(t=>e.includes(t?.status?.node)&&this.id===t?.status?.vlanConfig)||[]}get isReady(){if(0===this.nodes.length||this.vlanStatuses.length!==this.nodes.length)return!1;{const e=this.vlanStatuses.filter(e=>e.isReady);return e.length===this.vlanStatuses.length}}get selectedNodes(){const e=this.spec?.nodeSelector||{},t=this.$rootGetters[`${this.inStore}/all`](l.NW);if((0,r.isEmpty)(e))return t;if(e[a.yA]&&1===Object.keys(e).length)return t.filter(t=>t.id===e[a.yA])||[];{const n=(0,s.wC)(t||[],e).map(e=>e.id);return t.filter(e=>n.includes(e.id))}}get nodes(){return this.selectedNodes.filter(e=>!e.isUnSchedulable&&"true"!==e.isEtcd)}get stateDisplay(){return this.isReady?super.stateDisplay:d}get stateBackground(){return this.isReady?super.stateBackground:"bg-warning"}}},61715:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return o}});var r=n(68851),i=n(24222);class o extends i["default"]{get isReady(){const e=this.status?.conditions||[],t=(0,r.jq)(e,"type","ready")||{};return"True"===t.status}}},94741:function(e,t,n){"use strict";function r(e,t="admin"){const n=e?.["isSingleProduct"];if(n)return t;const r=i(e);return r?.username||r?.id||t}function i(e){return e?.["auth/user"]}n.d(t,{c:function(){return i},x:function(){return r}})},58434:function(e,t,n){"use strict";n.d(t,{J:function(){return i}});var r=n(2602);function i(e){if(!e)return{cpu:null,memory:null,isHotplugEnabled:!1};const t=o(e),{sockets:n=1,threads:r=1,cores:i=null}=e.spec.template.spec.domain.cpu||{},a=null===i?null:n*r*i;return t?{cpu:a,memory:e.spec.template.spec.domain?.memory?.guest||null,maxCpu:e.spec.template.spec.domain.cpu?.maxSockets||0,maxMemory:e.spec.template.spec.domain?.memory?.maxGuest||null,isHotplugEnabled:t}:{cpu:a,memory:e.spec.template.spec.domain.resources?.limits?.memory||null,isHotplugEnabled:t}}function o(e){return"true"===e?.metadata?.annotations[r.r.VM_CPU_MEMORY_HOTPLUG]||!!e?.spec?.template?.spec?.domain?.memory?.maxGuest||!1}},3791:function(e,t,n){"use strict";n.d(t,{nn:function(){return c},at:function(){return m},HF:function(){return u}});var r=n(2722),i=n.n(r);const o={"v1.3.0":["supportHarvesterClusterVersion"],"v1.3.1":["autoRotateRke2CertsSetting","supportBundleNodeCollectionTimeoutSetting"],"v1.3.2":["kubeconfigDefaultTokenTTLMinutesSetting","improveMaintenanceMode"],"v1.3.3":[],"v1.4.0":["cpuPinning","usbPassthrough","volumeEncryption","schedulingVMBackup","vmSnapshotQuota","longhornV2LVMSupport","improveMaintenanceMode","upgradeConfigSetting"],"v1.4.1":[],"v1.4.2":["refreshIntervalInSecond","allowEmptySnapshotClassName"],"v1.4.3":[],"v1.5.0":["tpmPersistentState","efiPersistentState","untaggedNetworkSetting","skipSingleReplicaDetachedVol","thirdPartyStorage","liveMigrationProgress"],"v1.5.1":[],"v1.6.0":["customSupportBundle","csiOnlineExpandValidation","vmNetworkMigration","kubeovnVpcSubnet","rancherClusterSetting","cpuMemoryHotplug","cdiSettings","vmCloneRunStrategy"],"v1.6.1":[],"v1.7.0":["vmMachineTypeAuto","lhV2VolExpansion","l2VlanTrunkMode","kubevirtMigration","hotplugNic","resumeUpgradePausedNode","vncPreserveSession"],"v1.7.1":[],"v1.8.0":["hotplugCdRom","supportBundleFileNameSetting","clusterRegistrationTLSVerify","vGPUAsPCIDevice","instanceManagerResourcesSetting","rwxNetworkSetting","createPVCWithDataVolume","clusterPodSecurityStandardSetting"],"v1.8.1":[],"v1.9.0":["supportFilesystem","disableResourcePooling","expandOnlineEncryptedVolume","longhornV2HugepageSettings","staticIPForVM","fsFreezeDeadline"],"v1.9.1":["lvmDmThinOnly","highPerformanceStorage"],"v1.10.0":["maintenanceModeConditions","maintenanceModeDrainTimeoutSetting","componentHealth"]},a=()=>{const e=[...Object.keys(o)].filter(e=>i().valid(e)).sort(i().compare),t={};return e.forEach((n,r)=>{const i=e[r-1];t[n]=i?[...t[i],...o[n]]:[...o[n]]}),t},s=a();var l=n(4364);const c=(e,t)=>{const n=`v${i().major(t)}.${i().minor(t)}`;return`https://docs.harvesterhci.io/${n}${e}`};function u(e){if({NODE_ENV:"production",BASE_URL:"/"}.VUE_APP_SERVER_VERSION)return{NODE_ENV:"production",BASE_URL:"/"}.VUE_APP_SERVER_VERSION;try{return`v${i().major(e)}.${i().minor(e)}.${i().patch(e)}`}catch(t){return d()}}function d(){const e=Object.keys(s).filter(i().valid).sort(i().rcompare);return e[0]||""}function h(e){const t=Object.keys(s).filter(i().valid),n=t.filter(t=>i().lte(t,e)).sort(i().rcompare);return n[0]||d()}function p(e,t){const n="1.3.0",r=u(t);if(i().lt(r.replace("v",""),n))return l.error(`Harvester UI extension only supports Harvester cluster version >= ${n}. Current version: ${r}`),!1;const o=h(r),a=s?.[o];return Array.isArray(a)?a.includes(e):(l.error(`Feature flags for version ${r} are not defined. Please upgrade Harvester UI extension and check the support matrix.`),!1)}const f=new Map,m=(e,t)=>{const n=`${e}|${t}`;return f.has(n)||f.set(n,p(e,t)),f.get(n)}},22827:function(e,t,n){"use strict";n.d(t,{Am:function(){return p},I0:function(){return d},M9:function(){return a},jF:function(){return h},ji:function(){return u}});var r=n(2722),i=n.n(r);const o="2.16.0",a="Harvester",s="SUSE Virtualization",l=/(\\?)\[\[([\w-]+)\]\]/g;let c=!1;function u(e){c=!!e}function d(){return c?s:a}function h(e){const t=i().coerce(e);return!!t&&i().gte(t,o)}function p(e,t={}){return Object.keys(e||{}).forEach(n=>{const r=e[n];"string"===typeof r?e[n]=r.replace(l,(e,n,r)=>n?`[[${r}]]`:t[r]??r):r&&"object"===typeof r&&p(r,t)}),e}},38223:function(e,t,n){"use strict";function r(e){return/^((25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9]?[0-9])\.){3}(25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9]?[0-9])\/(3[0-2]|[12]?[0-9])$/.test(e||"")}function i(e){return/^[A-Fa-f0-9]{2}(-[A-Fa-f0-9]{2}){5}$|^[A-Fa-f0-9]{2}(:[A-Fa-f0-9]{2}){5}$/.test(e)}function o(e){const t=/^[a-z0-9]([-a-z0-9]*[a-z0-9])?$/;return t.test(e)}n.d(t,{iw:function(){return i},z8:function(){return r},zv:function(){return o}})},14127:function(e,t,n){"use strict";n.d(t,{S:function(){return o},z:function(){return i}});var r=n(4364);function i(e={}){let t=!0;if(e?.value)try{const n=JSON.parse(e?.value);t=!n.type}catch(n){r.error("Failed to parse backup target value:",n)}return t}function o(e={}){const t=e.errorMessage,n=i(e),r=e.canUpdate;return(t||n)&&r}},88992:function(e,t,n){"use strict";n.d(t,{r:function(){return o}});var r=n(9274);const i=new WeakMap;function o(e,t,n){let o=i.get(e);return o||(o=new Map,i.set(e,o)),o.has(t)||o.set(t,(0,r.computed)(()=>n(e))),o.get(t).value}},39407:function(e,t,n){"use strict";n.d(t,{N:function(){return i}});var r=n(41837);function i(e){return e===r.Nu.VMSTATE_PERSISTENCE||e===r.Nu.LONGHORN_STATIC}},84757:function(e,t,n){"use strict";n.d(t,{Wl:function(){return i},gJ:function(){return o},jx:function(){return r}});const r="i",i="Gi",o="Mi"},66490:function(e,t,n){"use strict";n.d(t,{Gl:function(){return s},KE:function(){return a},OG:function(){return c},vN:function(){return o}});var r=n(88992),i=n(2602);function o(e){let t=[];try{t=JSON.parse(e?.metadata?.annotations?.[i.r.VOLUME_CLAIM_TEMPLATE])||[]}catch(n){}return t}const a="EMPTY_IMAGE";function s(e={}){return[...e.disks||[],...e.interfaces||[]].filter(e=>!!e.bootOrder).sort((e,t)=>e.bootOrder-t.bootOrder)}function l(e){return(0,r.r)(e,"latestMigrationIndex",e=>{const t=new Map;for(const n of e){const e=n.spec?.vmiName;if(!e)continue;const r=`${n.metadata?.namespace}/${e}`,i=t.get(r);(!i||n.metadata?.creationTimestamp>i.metadata?.creationTimestamp)&&t.set(r,n)}return t})}function c(e,t,n){if(n)return l(e).get(`${t}/${n}`)}},52880:function(e,t,n){"use strict";n.d(t,{Vi:function(){return i},_X:function(){return s},b8:function(){return a}});var r=n(2602);const i=["qcow","qcow2","raw","img","iso"];function o(e){try{const t=new URL(e),n=t.pathname;return n.split("/").filter(Boolean).pop()||""}catch(t){const n=e.split("?")[0].split("#")[0];return n.split("/").pop()||""}}function a(e,t,n,r,a){const s="file"===a?"harvester.validation.image.ruleFileTip":"harvester.validation.image.ruleTip",l=t["i18n/t"];if(!e||""===e)return n;const c=o(e);if(!c)return n.push(l(s)),n;const u=c.split(".").pop().toLowerCase();return i.includes(u)||n.push(l(s)),n}function s(e={},t,n,i,o){const a=t["i18n/t"];return e[r.r.IMAGE_NAME]||n.push(a("validation.required",{key:a("harvester.image.fileName")})),n}},52225:function(e,t,n){"use strict";var r=n(33062),i=n(1359),o=/^[\x00-\x20\u00a0\u1680\u2000-\u200a\u2028\u2029\u202f\u205f\u3000\ufeff]+/,a=/[\n\r\t]/g,s=/^[A-Za-z][A-Za-z0-9+-.]*:\/\//,l=/:\d+$/,c=/^([a-z][a-z0-9.+-]*:)?(\/\/)?([\\/]+)?([\S\s]*)/i,u=/^[a-zA-Z]:/;function d(e){return(e||"").toString().replace(o,"")}var h=[["#","hash"],["?","query"],function(e,t){return m(t.protocol)?e.replace(/\\/g,"/"):e},["/","pathname"],["@","auth",1],[NaN,"host",void 0,1,1],[/:(\d*)$/,"port",void 0,1],[NaN,"hostname",void 0,1,1]],p={hash:1,query:1};function f(e){var t;t="undefined"!==typeof window?window:"undefined"!==typeof n.g?n.g:"undefined"!==typeof self?self:{};var r=t.location||{};e=e||r;var i,o={},a=typeof e;if("blob:"===e.protocol)o=new b(unescape(e.pathname),{});else if("string"===a)for(i in o=new b(e,{}),p)delete o[i];else if("object"===a){for(i in e)i in p||(o[i]=e[i]);void 0===o.slashes&&(o.slashes=s.test(e.href))}return o}function m(e){return"file:"===e||"ftp:"===e||"http:"===e||"https:"===e||"ws:"===e||"wss:"===e}function g(e,t){e=d(e),e=e.replace(a,""),t=t||{};var n,r=c.exec(e),i=r[1]?r[1].toLowerCase():"",o=!!r[2],s=!!r[3],l=0;return o?s?(n=r[2]+r[3]+r[4],l=r[2].length+r[3].length):(n=r[2]+r[4],l=r[2].length):s?(n=r[3]+r[4],l=r[3].length):n=r[4],"file:"===i?l>=2&&(n=n.slice(2)):m(i)?n=r[4]:i?o&&(n=n.slice(2)):l>=2&&m(t.protocol)&&(n=r[4]),{protocol:i,slashes:o||m(i),slashesCount:l,rest:n}}function v(e,t){if(""===e)return t;var n=(t||"/").split("/").slice(0,-1).concat(e.split("/")),r=n.length,i=n[r-1],o=!1,a=0;while(r--)"."===n[r]?n.splice(r,1):".."===n[r]?(n.splice(r,1),a++):a&&(0===r&&(o=!0),n.splice(r,1),a--);return o&&n.unshift(""),"."!==i&&".."!==i||n.push(""),n.join("/")}function b(e,t,n){if(e=d(e),e=e.replace(a,""),!(this instanceof b))return new b(e,t,n);var o,s,l,c,p,y,w=h.slice(),O=typeof t,S=this,E=0;for("object"!==O&&"string"!==O&&(n=t,t=null),n&&"function"!==typeof n&&(n=i.parse),t=f(t),s=g(e||"",t),o=!s.protocol&&!s.slashes,S.slashes=s.slashes||o&&t.slashes,S.protocol=s.protocol||t.protocol||"",e=s.rest,("file:"===s.protocol&&(2!==s.slashesCount||u.test(e))||!s.slashes&&(s.protocol||s.slashesCount<2||!m(S.protocol)))&&(w[3]=[/(.*)/,"pathname"]);E<w.length;E++)c=w[E],"function"!==typeof c?(l=c[0],y=c[1],l!==l?S[y]=e:"string"===typeof l?(p="@"===l?e.lastIndexOf(l):e.indexOf(l),~p&&("number"===typeof c[2]?(S[y]=e.slice(0,p),e=e.slice(p+c[2])):(S[y]=e.slice(p),e=e.slice(0,p)))):(p=l.exec(e))&&(S[y]=p[1],e=e.slice(0,p.index)),S[y]=S[y]||o&&c[3]&&t[y]||"",c[4]&&(S[y]=S[y].toLowerCase())):e=c(e,S);n&&(S.query=n(S.query)),o&&t.slashes&&"/"!==S.pathname.charAt(0)&&(""!==S.pathname||""!==t.pathname)&&(S.pathname=v(S.pathname,t.pathname)),"/"!==S.pathname.charAt(0)&&m(S.protocol)&&(S.pathname="/"+S.pathname),r(S.port,S.protocol)||(S.host=S.hostname,S.port=""),S.username=S.password="",S.auth&&(p=S.auth.indexOf(":"),~p?(S.username=S.auth.slice(0,p),S.username=encodeURIComponent(decodeURIComponent(S.username)),S.password=S.auth.slice(p+1),S.password=encodeURIComponent(decodeURIComponent(S.password))):S.username=encodeURIComponent(decodeURIComponent(S.auth)),S.auth=S.password?S.username+":"+S.password:S.username),S.origin="file:"!==S.protocol&&m(S.protocol)&&S.host?S.protocol+"//"+S.host:"null",S.href=S.toString()}function y(e,t,n){var o=this;switch(e){case"query":"string"===typeof t&&t.length&&(t=(n||i.parse)(t)),o[e]=t;break;case"port":o[e]=t,r(t,o.protocol)?t&&(o.host=o.hostname+":"+t):(o.host=o.hostname,o[e]="");break;case"hostname":o[e]=t,o.port&&(t+=":"+o.port),o.host=t;break;case"host":o[e]=t,l.test(t)?(t=t.split(":"),o.port=t.pop(),o.hostname=t.join(":")):(o.hostname=t,o.port="");break;case"protocol":o.protocol=t.toLowerCase(),o.slashes=!n;break;case"pathname":case"hash":if(t){var a="pathname"===e?"/":"#";o[e]=t.charAt(0)!==a?a+t:t}else o[e]=t;break;case"username":case"password":o[e]=encodeURIComponent(t);break;case"auth":var s=t.indexOf(":");~s?(o.username=t.slice(0,s),o.username=encodeURIComponent(decodeURIComponent(o.username)),o.password=t.slice(s+1),o.password=encodeURIComponent(decodeURIComponent(o.password))):o.username=encodeURIComponent(decodeURIComponent(t))}for(var c=0;c<h.length;c++){var u=h[c];u[4]&&(o[u[1]]=o[u[1]].toLowerCase())}return o.auth=o.password?o.username+":"+o.password:o.username,o.origin="file:"!==o.protocol&&m(o.protocol)&&o.host?o.protocol+"//"+o.host:"null",o.href=o.toString(),o}function w(e){e&&"function"===typeof e||(e=i.stringify);var t,n=this,r=n.host,o=n.protocol;o&&":"!==o.charAt(o.length-1)&&(o+=":");var a=o+(n.protocol&&n.slashes||m(n.protocol)?"//":"");return n.username?(a+=n.username,n.password&&(a+=":"+n.password),a+="@"):n.password?(a+=":"+n.password,a+="@"):"file:"!==n.protocol&&m(n.protocol)&&!r&&"/"!==n.pathname&&(a+="@"),(":"===r[r.length-1]||l.test(n.hostname)&&!n.port)&&(r+=":"),a+=r+n.pathname,t="object"===typeof n.query?e(n.query):n.query,t&&(a+="?"!==t.charAt(0)?"?"+t:t),n.hash&&(a+=n.hash),a}b.prototype={set:y,toString:w},b.extractProtocol=g,b.location=f,b.trimLeft=d,b.qs=i,e.exports=b},62113:function(e,t,n){var r;/*! https://mths.be/punycode v1.4.1 by @mathias */e=n.nmd(e),function(){t&&t.nodeType,e&&e.nodeType;var i="object"==typeof n.g&&n.g;i.global!==i&&i.window!==i&&i.self;var o,a=2147483647,s=36,l=1,c=26,u=38,d=700,h=72,p=128,f="-",m=/^xn--/,g=/[^\x20-\x7E]/,v=/[\x2E\u3002\uFF0E\uFF61]/g,b={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},y=s-l,w=Math.floor,O=String.fromCharCode;function S(e){throw new RangeError(b[e])}function E(e,t){var n=e.length,r=[];while(n--)r[n]=t(e[n]);return r}function x(e,t){var n=e.split("@"),r="";n.length>1&&(r=n[0]+"@",e=n[1]),e=e.replace(v,".");var i=e.split("."),o=E(i,t).join(".");return r+o}function _(e){var t,n,r=[],i=0,o=e.length;while(i<o)t=e.charCodeAt(i++),t>=55296&&t<=56319&&i<o?(n=e.charCodeAt(i++),56320==(64512&n)?r.push(((1023&t)<<10)+(1023&n)+65536):(r.push(t),i--)):r.push(t);return r}function k(e){return E(e,function(e){var t="";return e>65535&&(e-=65536,t+=O(e>>>10&1023|55296),e=56320|1023&e),t+=O(e),t}).join("")}function C(e){return e-48<10?e-22:e-65<26?e-65:e-97<26?e-97:s}function A(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function T(e,t,n){var r=0;for(e=n?w(e/d):e>>1,e+=w(e/t);e>y*c>>1;r+=s)e=w(e/y);return w(r+(y+1)*e/(e+u))}function R(e){var t,n,r,i,o,u,d,m,g,v,b=[],y=e.length,O=0,E=p,x=h;for(n=e.lastIndexOf(f),n<0&&(n=0),r=0;r<n;++r)e.charCodeAt(r)>=128&&S("not-basic"),b.push(e.charCodeAt(r));for(i=n>0?n+1:0;i<y;){for(o=O,u=1,d=s;;d+=s){if(i>=y&&S("invalid-input"),m=C(e.charCodeAt(i++)),(m>=s||m>w((a-O)/u))&&S("overflow"),O+=m*u,g=d<=x?l:d>=x+c?c:d-x,m<g)break;v=s-g,u>w(a/v)&&S("overflow"),u*=v}t=b.length+1,x=T(O-o,t,0==o),w(O/t)>a-E&&S("overflow"),E+=w(O/t),O%=t,b.splice(O++,0,E)}return k(b)}function N(e){var t,n,r,i,o,u,d,m,g,v,b,y,E,x,k,C=[];for(e=_(e),y=e.length,t=p,n=0,o=h,u=0;u<y;++u)b=e[u],b<128&&C.push(O(b));r=i=C.length,i&&C.push(f);while(r<y){for(d=a,u=0;u<y;++u)b=e[u],b>=t&&b<d&&(d=b);for(E=r+1,d-t>w((a-n)/E)&&S("overflow"),n+=(d-t)*E,t=d,u=0;u<y;++u)if(b=e[u],b<t&&++n>a&&S("overflow"),b==t){for(m=n,g=s;;g+=s){if(v=g<=o?l:g>=o+c?c:g-o,m<v)break;k=m-v,x=s-v,C.push(O(A(v+k%x,0))),m=w(k/x)}C.push(O(A(m,0))),o=T(n,E,r==i),n=0,++r}++n,++t}return C.join("")}function P(e){return x(e,function(e){return m.test(e)?R(e.slice(4).toLowerCase()):e})}function I(e){return x(e,function(e){return g.test(e)?"xn--"+N(e):e})}o={version:"1.4.1",ucs2:{decode:_,encode:k},decode:R,encode:N,toASCII:I,toUnicode:P},r=function(){return o}.call(t,n,t,e),void 0===r||(e.exports=r)}()},75442:function(e,t,n){"use strict";var r=n(62113);function i(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}var o=/^([a-z0-9.+-]+:)/i,a=/:[0-9]*$/,s=/^(\/\/?(?!\/)[^?\s]*)(\?[^\s]*)?$/,l=["<",">",'"',"`"," ","\r","\n","\t"],c=["{","}","|","\\","^","`"].concat(l),u=["'"].concat(c),d=["%","/","?",";","#"].concat(u),h=["/","?","#"],p=255,f=/^[+a-z0-9A-Z_-]{0,63}$/,m=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,g={javascript:!0,"javascript:":!0},v={javascript:!0,"javascript:":!0},b={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},y=n(45810);function w(e,t,n){if(e&&"object"===typeof e&&e instanceof i)return e;var r=new i;return r.parse(e,t,n),r}function O(e){return"string"===typeof e&&(e=w(e)),e instanceof i?e.format():i.prototype.format.call(e)}function S(e,t){return w(e,!1,!0).resolve(t)}function E(e,t){return e?w(e,!1,!0).resolveObject(t):t}i.prototype.parse=function(e,t,n){if("string"!==typeof e)throw new TypeError("Parameter 'url' must be a string, not "+typeof e);var i=e.indexOf("?"),a=-1!==i&&i<e.indexOf("#")?"?":"#",l=e.split(a),c=/\\/g;l[0]=l[0].replace(c,"/"),e=l.join(a);var w=e;if(w=w.trim(),!n&&1===e.split("#").length){var O=s.exec(w);if(O)return this.path=w,this.href=w,this.pathname=O[1],O[2]?(this.search=O[2],this.query=t?y.parse(this.search.substr(1)):this.search.substr(1)):t&&(this.search="",this.query={}),this}var S=o.exec(w);if(S){S=S[0];var E=S.toLowerCase();this.protocol=E,w=w.substr(S.length)}if(n||S||w.match(/^\/\/[^@/]+@[^@/]+/)){var x="//"===w.substr(0,2);!x||S&&v[S]||(w=w.substr(2),this.slashes=!0)}if(!v[S]&&(x||S&&!b[S])){for(var _,k,C=-1,A=0;A<h.length;A++){var T=w.indexOf(h[A]);-1!==T&&(-1===C||T<C)&&(C=T)}k=-1===C?w.lastIndexOf("@"):w.lastIndexOf("@",C),-1!==k&&(_=w.slice(0,k),w=w.slice(k+1),this.auth=decodeURIComponent(_)),C=-1;for(A=0;A<d.length;A++){T=w.indexOf(d[A]);-1!==T&&(-1===C||T<C)&&(C=T)}-1===C&&(C=w.length),this.host=w.slice(0,C),w=w.slice(C),this.parseHost(),this.hostname=this.hostname||"";var R="["===this.hostname[0]&&"]"===this.hostname[this.hostname.length-1];if(!R)for(var N=this.hostname.split(/\./),P=(A=0,N.length);A<P;A++){var I=N[A];if(I&&!I.match(f)){for(var M="",D=0,L=I.length;D<L;D++)I.charCodeAt(D)>127?M+="x":M+=I[D];if(!M.match(f)){var B=N.slice(0,A),$=N.slice(A+1),V=I.match(m);V&&(B.push(V[1]),$.unshift(V[2])),$.length&&(w="/"+$.join(".")+w),this.hostname=B.join(".");break}}}this.hostname.length>p?this.hostname="":this.hostname=this.hostname.toLowerCase(),R||(this.hostname=r.toASCII(this.hostname));var F=this.port?":"+this.port:"",j=this.hostname||"";this.host=j+F,this.href+=this.host,R&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==w[0]&&(w="/"+w))}if(!g[E])for(A=0,P=u.length;A<P;A++){var U=u[A];if(-1!==w.indexOf(U)){var G=encodeURIComponent(U);G===U&&(G=escape(U)),w=w.split(U).join(G)}}var H=w.indexOf("#");-1!==H&&(this.hash=w.substr(H),w=w.slice(0,H));var q=w.indexOf("?");if(-1!==q?(this.search=w.substr(q),this.query=w.substr(q+1),t&&(this.query=y.parse(this.query)),w=w.slice(0,q)):t&&(this.search="",this.query={}),w&&(this.pathname=w),b[E]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){F=this.pathname||"";var Q=this.search||"";this.path=F+Q}return this.href=this.format(),this},i.prototype.format=function(){var e=this.auth||"";e&&(e=encodeURIComponent(e),e=e.replace(/%3A/i,":"),e+="@");var t=this.protocol||"",n=this.pathname||"",r=this.hash||"",i=!1,o="";this.host?i=e+this.host:this.hostname&&(i=e+(-1===this.hostname.indexOf(":")?this.hostname:"["+this.hostname+"]"),this.port&&(i+=":"+this.port)),this.query&&"object"===typeof this.query&&Object.keys(this.query).length&&(o=y.stringify(this.query,{arrayFormat:"repeat",addQueryPrefix:!1}));var a=this.search||o&&"?"+o||"";return t&&":"!==t.substr(-1)&&(t+=":"),this.slashes||(!t||b[t])&&!1!==i?(i="//"+(i||""),n&&"/"!==n.charAt(0)&&(n="/"+n)):i||(i=""),r&&"#"!==r.charAt(0)&&(r="#"+r),a&&"?"!==a.charAt(0)&&(a="?"+a),n=n.replace(/[?#]/g,function(e){return encodeURIComponent(e)}),a=a.replace("#","%23"),t+i+n+a+r},i.prototype.resolve=function(e){return this.resolveObject(w(e,!1,!0)).format()},i.prototype.resolveObject=function(e){if("string"===typeof e){var t=new i;t.parse(e,!1,!0),e=t}for(var n=new i,r=Object.keys(this),o=0;o<r.length;o++){var a=r[o];n[a]=this[a]}if(n.hash=e.hash,""===e.href)return n.href=n.format(),n;if(e.slashes&&!e.protocol){for(var s=Object.keys(e),l=0;l<s.length;l++){var c=s[l];"protocol"!==c&&(n[c]=e[c])}return b[n.protocol]&&n.hostname&&!n.pathname&&(n.pathname="/",n.path=n.pathname),n.href=n.format(),n}if(e.protocol&&e.protocol!==n.protocol){if(!b[e.protocol]){for(var u=Object.keys(e),d=0;d<u.length;d++){var h=u[d];n[h]=e[h]}return n.href=n.format(),n}if(n.protocol=e.protocol,e.host||v[e.protocol])n.pathname=e.pathname;else{var p=(e.pathname||"").split("/");while(p.length&&!(e.host=p.shift()));e.host||(e.host=""),e.hostname||(e.hostname=""),""!==p[0]&&p.unshift(""),p.length<2&&p.unshift(""),n.pathname=p.join("/")}if(n.search=e.search,n.query=e.query,n.host=e.host||"",n.auth=e.auth,n.hostname=e.hostname||e.host,n.port=e.port,n.pathname||n.search){var f=n.pathname||"",m=n.search||"";n.path=f+m}return n.slashes=n.slashes||e.slashes,n.href=n.format(),n}var g=n.pathname&&"/"===n.pathname.charAt(0),y=e.host||e.pathname&&"/"===e.pathname.charAt(0),w=y||g||n.host&&e.pathname,O=w,S=n.pathname&&n.pathname.split("/")||[],E=(p=e.pathname&&e.pathname.split("/")||[],n.protocol&&!b[n.protocol]);if(E&&(n.hostname="",n.port=null,n.host&&(""===S[0]?S[0]=n.host:S.unshift(n.host)),n.host="",e.protocol&&(e.hostname=null,e.port=null,e.host&&(""===p[0]?p[0]=e.host:p.unshift(e.host)),e.host=null),w=w&&(""===p[0]||""===S[0])),y)n.host=e.host||""===e.host?e.host:n.host,n.hostname=e.hostname||""===e.hostname?e.hostname:n.hostname,n.search=e.search,n.query=e.query,S=p;else if(p.length)S||(S=[]),S.pop(),S=S.concat(p),n.search=e.search,n.query=e.query;else if(null!=e.search){if(E){n.host=S.shift(),n.hostname=n.host;var x=!!(n.host&&n.host.indexOf("@")>0)&&n.host.split("@");x&&(n.auth=x.shift(),n.hostname=x.shift(),n.host=n.hostname)}return n.search=e.search,n.query=e.query,null===n.pathname&&null===n.search||(n.path=(n.pathname?n.pathname:"")+(n.search?n.search:"")),n.href=n.format(),n}if(!S.length)return n.pathname=null,n.search?n.path="/"+n.search:n.path=null,n.href=n.format(),n;for(var _=S.slice(-1)[0],k=(n.host||e.host||S.length>1)&&("."===_||".."===_)||""===_,C=0,A=S.length;A>=0;A--)_=S[A],"."===_?S.splice(A,1):".."===_?(S.splice(A,1),C++):C&&(S.splice(A,1),C--);if(!w&&!O)for(;C--;C)S.unshift("..");!w||""===S[0]||S[0]&&"/"===S[0].charAt(0)||S.unshift(""),k&&"/"!==S.join("/").substr(-1)&&S.push("");var T=""===S[0]||S[0]&&"/"===S[0].charAt(0);if(E){n.hostname=T?"":S.length?S.shift():"",n.host=n.hostname;x=!!(n.host&&n.host.indexOf("@")>0)&&n.host.split("@");x&&(n.auth=x.shift(),n.hostname=x.shift(),n.host=n.hostname)}return w=w||n.host&&S.length,w&&!T&&S.unshift(""),S.length>0?n.pathname=S.join("/"):(n.pathname=null,n.path=null),null===n.pathname&&null===n.search||(n.path=(n.pathname?n.pathname:"")+(n.search?n.search:"")),n.auth=e.auth||n.auth,n.slashes=n.slashes||e.slashes,n.href=n.format(),n},i.prototype.parseHost=function(){var e=this.host,t=a.exec(e);t&&(t=t[0],":"!==t&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)},t.parse=w,t.resolve=S,t.resolveObject=E,t.format=O,t.Url=i},66732:function(e,t,n){var r=n(4364);function i(e,t){if(o("noDeprecation"))return e;var n=!1;function i(){if(!n){if(o("throwDeprecation"))throw new Error(t);o("traceDeprecation")?r.trace(t):r.warn(t),n=!0}return e.apply(this,arguments)}return i}function o(e){try{if(!n.g.localStorage)return!1}catch(r){return!1}var t=n.g.localStorage[e];return null!=t&&"true"===String(t).toLowerCase()}e.exports=i},95272:function(e){e.exports=function(e){return e&&"object"===typeof e&&"function"===typeof e.copy&&"function"===typeof e.fill&&"function"===typeof e.readUInt8}},51531:function(e,t,n){"use strict";var r=n(55387),i=n(2625),o=n(52730),a=n(95943);function s(e){return e.call.bind(e)}var l="undefined"!==typeof BigInt,c="undefined"!==typeof Symbol,u=s(Object.prototype.toString),d=s(Number.prototype.valueOf),h=s(String.prototype.valueOf),p=s(Boolean.prototype.valueOf);if(l)var f=s(BigInt.prototype.valueOf);if(c)var m=s(Symbol.prototype.valueOf);function g(e,t){if("object"!==typeof e)return!1;try{return t(e),!0}catch(n){return!1}}function v(e){return"undefined"!==typeof Promise&&e instanceof Promise||null!==e&&"object"===typeof e&&"function"===typeof e.then&&"function"===typeof e.catch}function b(e){return"undefined"!==typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):a(e)||j(e)}function y(e){return"Uint8Array"===o(e)}function w(e){return"Uint8ClampedArray"===o(e)}function O(e){return"Uint16Array"===o(e)}function S(e){return"Uint32Array"===o(e)}function E(e){return"Int8Array"===o(e)}function x(e){return"Int16Array"===o(e)}function _(e){return"Int32Array"===o(e)}function k(e){return"Float32Array"===o(e)}function C(e){return"Float64Array"===o(e)}function A(e){return"BigInt64Array"===o(e)}function T(e){return"BigUint64Array"===o(e)}function R(e){return"[object Map]"===u(e)}function N(e){return"undefined"!==typeof Map&&(R.working?R(e):e instanceof Map)}function P(e){return"[object Set]"===u(e)}function I(e){return"undefined"!==typeof Set&&(P.working?P(e):e instanceof Set)}function M(e){return"[object WeakMap]"===u(e)}function D(e){return"undefined"!==typeof WeakMap&&(M.working?M(e):e instanceof WeakMap)}function L(e){return"[object WeakSet]"===u(e)}function B(e){return L(e)}function $(e){return"[object ArrayBuffer]"===u(e)}function V(e){return"undefined"!==typeof ArrayBuffer&&($.working?$(e):e instanceof ArrayBuffer)}function F(e){return"[object DataView]"===u(e)}function j(e){return"undefined"!==typeof DataView&&(F.working?F(e):e instanceof DataView)}t.isArgumentsObject=r,t.isGeneratorFunction=i,t.isTypedArray=a,t.isPromise=v,t.isArrayBufferView=b,t.isUint8Array=y,t.isUint8ClampedArray=w,t.isUint16Array=O,t.isUint32Array=S,t.isInt8Array=E,t.isInt16Array=x,t.isInt32Array=_,t.isFloat32Array=k,t.isFloat64Array=C,t.isBigInt64Array=A,t.isBigUint64Array=T,R.working="undefined"!==typeof Map&&R(new Map),t.isMap=N,P.working="undefined"!==typeof Set&&P(new Set),t.isSet=I,M.working="undefined"!==typeof WeakMap&&M(new WeakMap),t.isWeakMap=D,L.working="undefined"!==typeof WeakSet&&L(new WeakSet),t.isWeakSet=B,$.working="undefined"!==typeof ArrayBuffer&&$(new ArrayBuffer),t.isArrayBuffer=V,F.working="undefined"!==typeof ArrayBuffer&&"undefined"!==typeof DataView&&F(new DataView(new ArrayBuffer(1),0,1)),t.isDataView=j;var U="undefined"!==typeof SharedArrayBuffer?SharedArrayBuffer:void 0;function G(e){return"[object SharedArrayBuffer]"===u(e)}function H(e){return"undefined"!==typeof U&&("undefined"===typeof G.working&&(G.working=G(new U)),G.working?G(e):e instanceof U)}function q(e){return"[object AsyncFunction]"===u(e)}function Q(e){return"[object Map Iterator]"===u(e)}function z(e){return"[object Set Iterator]"===u(e)}function K(e){return"[object Generator]"===u(e)}function W(e){return"[object WebAssembly.Module]"===u(e)}function X(e){return g(e,d)}function Y(e){return g(e,h)}function Z(e){return g(e,p)}function J(e){return l&&g(e,f)}function ee(e){return c&&g(e,m)}function te(e){return X(e)||Y(e)||Z(e)||J(e)||ee(e)}function ne(e){return"undefined"!==typeof Uint8Array&&(V(e)||H(e))}t.isSharedArrayBuffer=H,t.isAsyncFunction=q,t.isMapIterator=Q,t.isSetIterator=z,t.isGeneratorObject=K,t.isWebAssemblyCompiledModule=W,t.isNumberObject=X,t.isStringObject=Y,t.isBooleanObject=Z,t.isBigIntObject=J,t.isSymbolObject=ee,t.isBoxedPrimitive=te,t.isAnyArrayBuffer=ne,["isProxy","isExternal","isModuleNamespaceObject"].forEach(function(e){Object.defineProperty(t,e,{enumerable:!1,value:function(){throw new Error(e+" is not supported in userland")}})})},49208:function(e,t,n){var r=n(39907),i=n(4364),o=Object.getOwnPropertyDescriptors||function(e){for(var t=Object.keys(e),n={},r=0;r<t.length;r++)n[t[r]]=Object.getOwnPropertyDescriptor(e,t[r]);return n},a=/%[sdj%]/g;t.format=function(e){if(!_(e)){for(var t=[],n=0;n<arguments.length;n++)t.push(u(arguments[n]));return t.join(" ")}n=1;for(var r=arguments,i=r.length,o=String(e).replace(a,function(e){if("%%"===e)return"%";if(n>=i)return e;switch(e){case"%s":return String(r[n++]);case"%d":return Number(r[n++]);case"%j":try{return JSON.stringify(r[n++])}catch(t){return"[Circular]"}default:return e}}),s=r[n];n<i;s=r[++n])S(s)||!T(s)?o+=" "+s:o+=" "+u(s);return o},t.deprecate=function(e,n){if("undefined"!==typeof r&&!0===r.noDeprecation)return e;if("undefined"===typeof r)return function(){return t.deprecate(e,n).apply(this,arguments)};var o=!1;function a(){if(!o){if(r.throwDeprecation)throw new Error(n);r.traceDeprecation?i.trace(n):i.error(n),o=!0}return e.apply(this,arguments)}return a};var s={},l=/^$/;if({NODE_ENV:"production",BASE_URL:"/"}.NODE_DEBUG){var c={NODE_ENV:"production",BASE_URL:"/"}.NODE_DEBUG;c=c.replace(/[|\\{}()[\]^$+?.]/g,"\\$&").replace(/\*/g,".*").replace(/,/g,"$|^").toUpperCase(),l=new RegExp("^"+c+"$","i")}function u(e,n){var r={seen:[],stylize:h};return arguments.length>=3&&(r.depth=arguments[2]),arguments.length>=4&&(r.colors=arguments[3]),O(n)?r.showHidden=n:n&&t._extend(r,n),C(r.showHidden)&&(r.showHidden=!1),C(r.depth)&&(r.depth=2),C(r.colors)&&(r.colors=!1),C(r.customInspect)&&(r.customInspect=!0),r.colors&&(r.stylize=d),f(r,e,r.depth)}function d(e,t){var n=u.styles[t];return n?"["+u.colors[n][0]+"m"+e+"["+u.colors[n][1]+"m":e}function h(e,t){return e}function p(e){var t={};return e.forEach(function(e,n){t[e]=!0}),t}function f(e,n,r){if(e.customInspect&&n&&P(n.inspect)&&n.inspect!==t.inspect&&(!n.constructor||n.constructor.prototype!==n)){var i=n.inspect(r,e);return _(i)||(i=f(e,i,r)),i}var o=m(e,n);if(o)return o;var a=Object.keys(n),s=p(a);if(e.showHidden&&(a=Object.getOwnPropertyNames(n)),N(n)&&(a.indexOf("message")>=0||a.indexOf("description")>=0))return g(n);if(0===a.length){if(P(n)){var l=n.name?": "+n.name:"";return e.stylize("[Function"+l+"]","special")}if(A(n))return e.stylize(RegExp.prototype.toString.call(n),"regexp");if(R(n))return e.stylize(Date.prototype.toString.call(n),"date");if(N(n))return g(n)}var c,u="",d=!1,h=["{","}"];if(w(n)&&(d=!0,h=["[","]"]),P(n)){var O=n.name?": "+n.name:"";u=" [Function"+O+"]"}return A(n)&&(u=" "+RegExp.prototype.toString.call(n)),R(n)&&(u=" "+Date.prototype.toUTCString.call(n)),N(n)&&(u=" "+g(n)),0!==a.length||d&&0!=n.length?r<0?A(n)?e.stylize(RegExp.prototype.toString.call(n),"regexp"):e.stylize("[Object]","special"):(e.seen.push(n),c=d?v(e,n,r,s,a):a.map(function(t){return b(e,n,r,s,t,d)}),e.seen.pop(),y(c,u,h)):h[0]+u+h[1]}function m(e,t){if(C(t))return e.stylize("undefined","undefined");if(_(t)){var n="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(n,"string")}return x(t)?e.stylize(""+t,"number"):O(t)?e.stylize(""+t,"boolean"):S(t)?e.stylize("null","null"):void 0}function g(e){return"["+Error.prototype.toString.call(e)+"]"}function v(e,t,n,r,i){for(var o=[],a=0,s=t.length;a<s;++a)$(t,String(a))?o.push(b(e,t,n,r,String(a),!0)):o.push("");return i.forEach(function(i){i.match(/^\d+$/)||o.push(b(e,t,n,r,i,!0))}),o}function b(e,t,n,r,i,o){var a,s,l;if(l=Object.getOwnPropertyDescriptor(t,i)||{value:t[i]},l.get?s=l.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):l.set&&(s=e.stylize("[Setter]","special")),$(r,i)||(a="["+i+"]"),s||(e.seen.indexOf(l.value)<0?(s=S(n)?f(e,l.value,null):f(e,l.value,n-1),s.indexOf("\n")>-1&&(s=o?s.split("\n").map(function(e){return" "+e}).join("\n").slice(2):"\n"+s.split("\n").map(function(e){return" "+e}).join("\n"))):s=e.stylize("[Circular]","special")),C(a)){if(o&&i.match(/^\d+$/))return s;a=JSON.stringify(""+i),a.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(a=a.slice(1,-1),a=e.stylize(a,"name")):(a=a.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),a=e.stylize(a,"string"))}return a+": "+s}function y(e,t,n){var r=e.reduce(function(e,t){return t.indexOf("\n")>=0&&0,e+t.replace(/\u001b\[\d\d?m/g,"").length+1},0);return r>60?n[0]+(""===t?"":t+"\n ")+" "+e.join(",\n ")+" "+n[1]:n[0]+t+" "+e.join(", ")+" "+n[1]}function w(e){return Array.isArray(e)}function O(e){return"boolean"===typeof e}function S(e){return null===e}function E(e){return null==e}function x(e){return"number"===typeof e}function _(e){return"string"===typeof e}function k(e){return"symbol"===typeof e}function C(e){return void 0===e}function A(e){return T(e)&&"[object RegExp]"===M(e)}function T(e){return"object"===typeof e&&null!==e}function R(e){return T(e)&&"[object Date]"===M(e)}function N(e){return T(e)&&("[object Error]"===M(e)||e instanceof Error)}function P(e){return"function"===typeof e}function I(e){return null===e||"boolean"===typeof e||"number"===typeof e||"string"===typeof e||"symbol"===typeof e||"undefined"===typeof e}function M(e){return Object.prototype.toString.call(e)}function D(e){return e<10?"0"+e.toString(10):e.toString(10)}t.debuglog=function(e){if(e=e.toUpperCase(),!s[e])if(l.test(e)){var n=r.pid;s[e]=function(){var r=t.format.apply(t,arguments);i.error("%s %d: %s",e,n,r)}}else s[e]=function(){};return s[e]},t.inspect=u,u.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},u.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},t.types=n(51531),t.isArray=w,t.isBoolean=O,t.isNull=S,t.isNullOrUndefined=E,t.isNumber=x,t.isString=_,t.isSymbol=k,t.isUndefined=C,t.isRegExp=A,t.types.isRegExp=A,t.isObject=T,t.isDate=R,t.types.isDate=R,t.isError=N,t.types.isNativeError=N,t.isFunction=P,t.isPrimitive=I,t.isBuffer=n(95272);var L=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function B(){var e=new Date,t=[D(e.getHours()),D(e.getMinutes()),D(e.getSeconds())].join(":");return[e.getDate(),L[e.getMonth()],t].join(" ")}function $(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.log=function(){i.log("%s - %s",B(),t.format.apply(t,arguments))},t.inherits=n(35615),t._extend=function(e,t){if(!t||!T(t))return e;var n=Object.keys(t),r=n.length;while(r--)e[n[r]]=t[n[r]];return e};var V="undefined"!==typeof Symbol?Symbol("util.promisify.custom"):void 0;function F(e,t){if(!e){var n=new Error("Promise was rejected with a falsy value");n.reason=e,e=n}return t(e)}function j(e){if("function"!==typeof e)throw new TypeError('The "original" argument must be of type Function');function t(){for(var t=[],n=0;n<arguments.length;n++)t.push(arguments[n]);var i=t.pop();if("function"!==typeof i)throw new TypeError("The last argument must be of type Function");var o=this,a=function(){return i.apply(o,arguments)};e.apply(this,t).then(function(e){r.nextTick(a.bind(null,null,e))},function(e){r.nextTick(F.bind(null,e,a))})}return Object.setPrototypeOf(t,Object.getPrototypeOf(e)),Object.defineProperties(t,o(e)),t}t.promisify=function(e){if("function"!==typeof e)throw new TypeError('The "original" argument must be of type Function');if(V&&e[V]){var t=e[V];if("function"!==typeof t)throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(t,V,{value:t,enumerable:!1,writable:!1,configurable:!0}),t}function t(){for(var t,n,r=new Promise(function(e,r){t=e,n=r}),i=[],o=0;o<arguments.length;o++)i.push(arguments[o]);i.push(function(e,r){e?n(e):t(r)});try{e.apply(this,i)}catch(a){n(a)}return r}return Object.setPrototypeOf(t,Object.getPrototypeOf(e)),V&&Object.defineProperty(t,V,{value:t,enumerable:!1,writable:!1,configurable:!0}),Object.defineProperties(t,o(e))},t.promisify.custom=V,t.callbackify=j},47433:function(e,t){"use strict";t.A=(e,t)=>{const n=e.__vccOpts||e;for(const[r,i]of t)n[r]=i;return n}},91460:function(e,t,n){var r=n(5845);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("46502dd4",r,!0,{sourceMap:!1,shadowMode:!1})},69025:function(e,t,n){var r=n(43112);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("73180d3c",r,!0,{sourceMap:!1,shadowMode:!1})},63864:function(e,t,n){var r=n(96696);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("695df0fd",r,!0,{sourceMap:!1,shadowMode:!1})},68814:function(e,t,n){var r=n(36942);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("3b3abb59",r,!0,{sourceMap:!1,shadowMode:!1})},27509:function(e,t,n){var r=n(97301);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("4e210e3f",r,!0,{sourceMap:!1,shadowMode:!1})},80818:function(e,t,n){var r=n(46962);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("f48db260",r,!0,{sourceMap:!1,shadowMode:!1})},84872:function(e,t,n){var r=n(31912);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("7df7eb40",r,!0,{sourceMap:!1,shadowMode:!1})},9722:function(e,t,n){var r=n(31354);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("e65ca0d2",r,!0,{sourceMap:!1,shadowMode:!1})},7499:function(e,t,n){var r=n(21483);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("1a3d1a3a",r,!0,{sourceMap:!1,shadowMode:!1})},83520:function(e,t,n){var r=n(53184);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("8f19f75e",r,!0,{sourceMap:!1,shadowMode:!1})},26042:function(e,t,n){var r=n(57178);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("35402922",r,!0,{sourceMap:!1,shadowMode:!1})},45801:function(e,t,n){var r=n(33289);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("6c712fba",r,!0,{sourceMap:!1,shadowMode:!1})},40617:function(e,t,n){var r=n(86249);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("2540d99d",r,!0,{sourceMap:!1,shadowMode:!1})},24039:function(e,t,n){var r=n(18983);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("1f049ebd",r,!0,{sourceMap:!1,shadowMode:!1})},55372:function(e,t,n){var r=n(18956);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("3b5e01e7",r,!0,{sourceMap:!1,shadowMode:!1})},70336:function(e,t,n){var r=n(80288);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("61430b72",r,!0,{sourceMap:!1,shadowMode:!1})},37474:function(e,t,n){var r=n(61250);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("03fbf244",r,!0,{sourceMap:!1,shadowMode:!1})},39066:function(e,t,n){var r=n(6618);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("58c7ad54",r,!0,{sourceMap:!1,shadowMode:!1})},64204:function(e,t,n){var r=n(83852);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("d896a876",r,!0,{sourceMap:!1,shadowMode:!1})},91532:function(e,t,n){var r=n(80172);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("af8bca74",r,!0,{sourceMap:!1,shadowMode:!1})},97387:function(e,t,n){var r=n(37899);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("6e743df0",r,!0,{sourceMap:!1,shadowMode:!1})},31806:function(e,t,n){var r=n(49630);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("634bc7e0",r,!0,{sourceMap:!1,shadowMode:!1})},59918:function(e,t,n){var r=n(51758);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("a7280aee",r,!0,{sourceMap:!1,shadowMode:!1})},61883:function(e,t,n){var r=n(98824);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("7b80c377",r,!0,{sourceMap:!1,shadowMode:!1})},10642:function(e,t,n){var r=n(91890);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("3e7afc3a",r,!0,{sourceMap:!1,shadowMode:!1})},20770:function(e,t,n){var r=n(4738);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("75208f56",r,!0,{sourceMap:!1,shadowMode:!1})},32435:function(e,t,n){var r=n(9299);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("3df338b8",r,!0,{sourceMap:!1,shadowMode:!1})},45978:function(e,t,n){var r=n(20602);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("0f55430e",r,!0,{sourceMap:!1,shadowMode:!1})},47668:function(e,t,n){var r=n(71124);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("017ed6a8",r,!0,{sourceMap:!1,shadowMode:!1})},76258:function(e,t,n){var r=n(9570);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("32f279f6",r,!0,{sourceMap:!1,shadowMode:!1})},72674:function(e,t,n){var r=n(83234);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("ec2b28d2",r,!0,{sourceMap:!1,shadowMode:!1})},9607:function(e,t,n){var r=n(98343);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("14d52d8a",r,!0,{sourceMap:!1,shadowMode:!1})},73597:function(e,t,n){var r=n(58749);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("1bafc86d",r,!0,{sourceMap:!1,shadowMode:!1})},70738:function(e,t,n){var r=n(56530);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("b37b1fae",r,!0,{sourceMap:!1,shadowMode:!1})},31782:function(e,t,n){var r=n(51558);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("4c7f143f",r,!0,{sourceMap:!1,shadowMode:!1})},24025:function(e,t,n){var r=n(4025);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("4a306ce8",r,!0,{sourceMap:!1,shadowMode:!1})},4241:function(e,t,n){var r=n(1777);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("c78059ee",r,!0,{sourceMap:!1,shadowMode:!1})},17299:function(e,t,n){var r=n(94739);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("79740018",r,!0,{sourceMap:!1,shadowMode:!1})},64454:function(e,t,n){var r=n(26374);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("3790cecf",r,!0,{sourceMap:!1,shadowMode:!1})},26550:function(e,t,n){var r=n(2582);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("23d3cfb4",r,!0,{sourceMap:!1,shadowMode:!1})},66324:function(e,t,n){var r=n(43431);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("7d9b5764",r,!0,{sourceMap:!1,shadowMode:!1})},52339:function(e,t,n){var r=n(97491);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("c6b19644",r,!0,{sourceMap:!1,shadowMode:!1})},87752:function(e,t,n){var r=n(28360);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("090b5b7f",r,!0,{sourceMap:!1,shadowMode:!1})},26603:function(e,t,n){var r=n(46571);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("14f1078c",r,!0,{sourceMap:!1,shadowMode:!1})},72023:function(e,t,n){var r=n(78359);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("b9925f8a",r,!0,{sourceMap:!1,shadowMode:!1})},19935:function(e,t,n){var r=n(9567);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("d802f440",r,!0,{sourceMap:!1,shadowMode:!1})},66592:function(e,t,n){var r=n(70624);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("6e7b4074",r,!0,{sourceMap:!1,shadowMode:!1})},94068:function(e,t,n){var r=n(6772);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("2c2cad9d",r,!0,{sourceMap:!1,shadowMode:!1})},85547:function(e,t,n){var r=n(97867);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("29fee1ed",r,!0,{sourceMap:!1,shadowMode:!1})},24511:function(e,t,n){var r=n(50399);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("42e5f2d8",r,!0,{sourceMap:!1,shadowMode:!1})},83375:function(e,t,n){var r=n(40143);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("c172b1f8",r,!0,{sourceMap:!1,shadowMode:!1})},53958:function(e,t,n){var r=n(61446);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("24ee7e78",r,!0,{sourceMap:!1,shadowMode:!1})},86476:function(e,t,n){var r=n(77612);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("1384f647",r,!0,{sourceMap:!1,shadowMode:!1})},60253:function(e,t,n){var r=n(25309);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("1594bc76",r,!0,{sourceMap:!1,shadowMode:!1})},32715:function(e,t,n){var r=n(68171);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("a9b38620",r,!0,{sourceMap:!1,shadowMode:!1})},54200:function(e,t,n){var r=n(8344);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("50b7820c",r,!0,{sourceMap:!1,shadowMode:!1})},97876:function(e,t,n){var r=n(50612);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("4cdee72e",r,!0,{sourceMap:!1,shadowMode:!1})},42677:function(e,t,n){var r=n(68085);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("3d675c54",r,!0,{sourceMap:!1,shadowMode:!1})},66397:function(e,t,n){var r=n(89565);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("3be52706",r,!0,{sourceMap:!1,shadowMode:!1})},56376:function(e,t,n){var r=n(20696);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("14d621b1",r,!0,{sourceMap:!1,shadowMode:!1})},52686:function(e,t,n){var r=n(16462);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("9efa83c6",r,!0,{sourceMap:!1,shadowMode:!1})},79086:function(e,t,n){var r=n(59182);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("41da24b9",r,!0,{sourceMap:!1,shadowMode:!1})},73076:function(e,t,n){var r=n(42676);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("a6c5bc66",r,!0,{sourceMap:!1,shadowMode:!1})},48773:function(e,t,n){var r=n(42693);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("11fbd782",r,!0,{sourceMap:!1,shadowMode:!1})},70803:function(e,t,n){var r=n(81280);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("78038316",r,!0,{sourceMap:!1,shadowMode:!1})},17639:function(e,t,n){var r=n(34087);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("01feb104",r,!0,{sourceMap:!1,shadowMode:!1})},53421:function(e,t,n){var r=n(83469);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("3e7fca98",r,!0,{sourceMap:!1,shadowMode:!1})},88743:function(e,t,n){var r=n(18727);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("091f495a",r,!0,{sourceMap:!1,shadowMode:!1})},45825:function(e,t,n){var r=n(24609);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("776c3224",r,!0,{sourceMap:!1,shadowMode:!1})},94210:function(e,t,n){var r=n(67042);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("cf5d7c26",r,!0,{sourceMap:!1,shadowMode:!1})},46863:function(e,t,n){var r=n(29007);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("79efb755",r,!0,{sourceMap:!1,shadowMode:!1})},3184:function(e,t,n){var r=n(72400);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("53124f1f",r,!0,{sourceMap:!1,shadowMode:!1})},41117:function(e,t,n){var r=n(83325);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("28da39b7",r,!0,{sourceMap:!1,shadowMode:!1})},78786:function(e,t,n){var r=n(3874);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("a3a7cd20",r,!0,{sourceMap:!1,shadowMode:!1})},22151:function(e,t,n){var r=n(6087);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("7f6f0bb9",r,!0,{sourceMap:!1,shadowMode:!1})},40533:function(e,t,n){var r=n(42453);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("03f83918",r,!0,{sourceMap:!1,shadowMode:!1})},49436:function(e,t,n){var r=n(14716);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("4f55e70c",r,!0,{sourceMap:!1,shadowMode:!1})},54394:function(e,t,n){var r=n(76858);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("944e8c34",r,!0,{sourceMap:!1,shadowMode:!1})},92421:function(e,t,n){var r=n(39685);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("0b607b79",r,!0,{sourceMap:!1,shadowMode:!1})},93386:function(e,t,n){var r=n(40138);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("6103951c",r,!0,{sourceMap:!1,shadowMode:!1})},4901:function(e,t,n){var r=n(32101);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("6a1f327e",r,!0,{sourceMap:!1,shadowMode:!1})},65084:function(e,t,n){var r=n(19036);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("564d79a7",r,!0,{sourceMap:!1,shadowMode:!1})},66586:function(e,t,n){var r=n(24794);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("2eb658e0",r,!0,{sourceMap:!1,shadowMode:!1})},42358:function(e,t,n){var r=n(81334);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("89ab958c",r,!0,{sourceMap:!1,shadowMode:!1})},53575:function(e,t,n){var r=n(67271);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("18b320ff",r,!0,{sourceMap:!1,shadowMode:!1})},2788:function(e,t,n){var r=n(47460);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("cdd8b4d4",r,!0,{sourceMap:!1,shadowMode:!1})},37945:function(e,t,n){var r=n(68985);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("64573a1e",r,!0,{sourceMap:!1,shadowMode:!1})},31072:function(e,t,n){var r=n(6496);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("6f8151a1",r,!0,{sourceMap:!1,shadowMode:!1})},41452:function(e,t,n){var r=n(27180);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("831cf668",r,!0,{sourceMap:!1,shadowMode:!1})},39828:function(e,t,n){var r=n(5012);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("0842f69e",r,!0,{sourceMap:!1,shadowMode:!1})},88178:function(e,t,n){var r=n(83858);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("6bf8e79c",r,!0,{sourceMap:!1,shadowMode:!1})},38241:function(e,t,n){var r=n(58625);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("8eec5a00",r,!0,{sourceMap:!1,shadowMode:!1})},63607:function(e,t,n){var r=n(38276);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("45c3d184",r,!0,{sourceMap:!1,shadowMode:!1})},54752:function(e,t,n){var r=n(22880);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("bcd5ae90",r,!0,{sourceMap:!1,shadowMode:!1})},97137:function(e,t,n){var r=n(84593);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("3a5f1ce2",r,!0,{sourceMap:!1,shadowMode:!1})},54932:function(e,t,n){var r=n(18388);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("265484b2",r,!0,{sourceMap:!1,shadowMode:!1})},68648:function(e,t,n){var r=n(28232);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("64fbc884",r,!0,{sourceMap:!1,shadowMode:!1})},7156:function(e,t,n){var r=n(42836);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("4eac63c4",r,!0,{sourceMap:!1,shadowMode:!1})},81133:function(e,t,n){var r=n(32397);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("9c2e1430",r,!0,{sourceMap:!1,shadowMode:!1})},99447:function(e,t,n){var r=n(95671);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("61b2cbac",r,!0,{sourceMap:!1,shadowMode:!1})},28022:function(e,t,n){var r=n(71286);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("4853f6b7",r,!0,{sourceMap:!1,shadowMode:!1})},12214:function(e,t,n){var r=n(59766);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("2e54c984",r,!0,{sourceMap:!1,shadowMode:!1})},25916:function(e,t,n){var r=n(78268);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("07667e63",r,!0,{sourceMap:!1,shadowMode:!1})},36261:function(e,t,n){var r=n(99365);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("30c04df4",r,!0,{sourceMap:!1,shadowMode:!1})},13643:function(e,t,n){var r=n(28811);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("096416cc",r,!0,{sourceMap:!1,shadowMode:!1})},97944:function(e,t,n){var r=n(55768);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("75e07b59",r,!0,{sourceMap:!1,shadowMode:!1})},30336:function(e,t,n){var r=n(98176);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("0fa96286",r,!0,{sourceMap:!1,shadowMode:!1})},23415:function(e,t,n){var r=n(43063);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("aa30ef44",r,!0,{sourceMap:!1,shadowMode:!1})},94532:function(e,t,n){var r=n(9284);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("9154b812",r,!0,{sourceMap:!1,shadowMode:!1})},54782:function(e,t,n){var r=n(90910);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("4a882541",r,!0,{sourceMap:!1,shadowMode:!1})},72214:function(e,t,n){var r=n(87689);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("3915e7ba",r,!0,{sourceMap:!1,shadowMode:!1})},41874:function(e,t,n){var r=n(97394);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("00db031c",r,!0,{sourceMap:!1,shadowMode:!1})},42137:function(e,t,n){var r=n(33177);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("3e9f4454",r,!0,{sourceMap:!1,shadowMode:!1})},4015:function(e,t,n){var r=n(48815);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("5d737020",r,!0,{sourceMap:!1,shadowMode:!1})},75148:function(e,t,n){var r=n(40236);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("85170dd8",r,!0,{sourceMap:!1,shadowMode:!1})},17492:function(e,t,n){var r=n(40628);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("28d71a46",r,!0,{sourceMap:!1,shadowMode:!1})},66511:function(e,t,n){var r=n(35087);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("0dfa98c8",r,!0,{sourceMap:!1,shadowMode:!1})},44738:function(e,t,n){var r=n(12066);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("680a8cc0",r,!0,{sourceMap:!1,shadowMode:!1})},68954:function(e,t,n){var r=n(48282);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("79f17776",r,!0,{sourceMap:!1,shadowMode:!1})},3857:function(e,t,n){var r=n(11121);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("09bb5f68",r,!0,{sourceMap:!1,shadowMode:!1})},74236:function(e,t,n){var r=n(76444);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("f7898946",r,!0,{sourceMap:!1,shadowMode:!1})},607:function(e,t,n){var r=n(51487);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("397cf7dd",r,!0,{sourceMap:!1,shadowMode:!1})},21197:function(e,t,n){var r=n(99853);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("4441f0ed",r,!0,{sourceMap:!1,shadowMode:!1})},91319:function(e,t,n){var r=n(43383);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("26e5d312",r,!0,{sourceMap:!1,shadowMode:!1})},47497:function(e,t,n){var r=n(78761);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("31859628",r,!0,{sourceMap:!1,shadowMode:!1})},54464:function(e,t,n){var r=n(33440);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("d36558c4",r,!0,{sourceMap:!1,shadowMode:!1})},89501:function(e,t,n){var r=n(10557);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("df59bb08",r,!0,{sourceMap:!1,shadowMode:!1})},15935:function(e,t,n){var r=n(7007);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("d6834714",r,!0,{sourceMap:!1,shadowMode:!1})},9888:function(e,t,n){var r=n(32128);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("7e21b9e9",r,!0,{sourceMap:!1,shadowMode:!1})},74322:function(e,t,n){var r=n(89906);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("d9b7e5e6",r,!0,{sourceMap:!1,shadowMode:!1})},22728:function(e,t,n){var r=n(79496);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("9f9b0372",r,!0,{sourceMap:!1,shadowMode:!1})},65267:function(e,t,n){var r=n(34579);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("b23e4d00",r,!0,{sourceMap:!1,shadowMode:!1})},53393:function(e,t,n){var r=n(76113);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("c2cbd7c2",r,!0,{sourceMap:!1,shadowMode:!1})},80279:function(e,t,n){var r=n(79415);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("2586278f",r,!0,{sourceMap:!1,shadowMode:!1})},9986:function(e,t,n){var r=n(82466);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("28f527ab",r,!0,{sourceMap:!1,shadowMode:!1})},58888:function(e,t,n){var r=n(68936);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("63ddb22b",r,!0,{sourceMap:!1,shadowMode:!1})},62127:function(e,t,n){var r=n(72559);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("b05642e8",r,!0,{sourceMap:!1,shadowMode:!1})},56169:function(e,t,n){var r=n(65897);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("1d95002a",r,!0,{sourceMap:!1,shadowMode:!1})},25737:function(e,t,n){var r=n(11881);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("50d7e800",r,!0,{sourceMap:!1,shadowMode:!1})},19524:function(e,t,n){var r=n(48964);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("7c0d26a9",r,!0,{sourceMap:!1,shadowMode:!1})},56554:function(e,t,n){var r=n(64970);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("6ce52309",r,!0,{sourceMap:!1,shadowMode:!1})},5044:function(e,t,n){var r=n(18164);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("4a6990ad",r,!0,{sourceMap:!1,shadowMode:!1})},30012:function(e,t,n){var r=n(70908);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("432e85fc",r,!0,{sourceMap:!1,shadowMode:!1})},41158:function(e,t,n){var r=n(81945);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("2715a0f6",r,!0,{sourceMap:!1,shadowMode:!1})},29056:function(e,t,n){var r=n(66208);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("7f55fbee",r,!0,{sourceMap:!1,shadowMode:!1})},15006:function(e,t,n){var r=n(78622);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("1b54a8be",r,!0,{sourceMap:!1,shadowMode:!1})},18955:function(e,t,n){var r=n(89009);r.__esModule&&(r=r.default),"string"===typeof r&&(r=[[e.id,r,""]]),r.locals&&(e.exports=r.locals);var i=n(74825).A;i("1a282717",r,!0,{sourceMap:!1,shadowMode:!1})},74825:function(e,t,n){"use strict";function r(e,t){for(var n=[],r={},i=0;i<t.length;i++){var o=t[i],a=o[0],s=o[1],l=o[2],c=o[3],u={id:e+":"+i,css:s,media:l,sourceMap:c};r[a]?r[a].parts.push(u):n.push(r[a]={id:a,parts:[u]})}return n}n.d(t,{A:function(){return f}});var i="undefined"!==typeof document;if("undefined"!==typeof DEBUG&&DEBUG&&!i)throw new Error("vue-style-loader cannot be used in a non-browser environment. Use { target: 'node' } in your Webpack config to indicate a server-rendering environment.");var o={},a=i&&(document.head||document.getElementsByTagName("head")[0]),s=null,l=0,c=!1,u=function(){},d=null,h="data-vue-ssr-id",p="undefined"!==typeof navigator&&/msie [6-9]\b/.test(navigator.userAgent.toLowerCase());function f(e,t,n,i){c=n,d=i||{};var a=r(e,t);return m(a),function(t){for(var n=[],i=0;i<a.length;i++){var s=a[i],l=o[s.id];l.refs--,n.push(l)}t?(a=r(e,t),m(a)):a=[];for(i=0;i<n.length;i++){l=n[i];if(0===l.refs){for(var c=0;c<l.parts.length;c++)l.parts[c]();delete o[l.id]}}}}function m(e){for(var t=0;t<e.length;t++){var n=e[t],r=o[n.id];if(r){r.refs++;for(var i=0;i<r.parts.length;i++)r.parts[i](n.parts[i]);for(;i<n.parts.length;i++)r.parts.push(v(n.parts[i]));r.parts.length>n.parts.length&&(r.parts.length=n.parts.length)}else{var a=[];for(i=0;i<n.parts.length;i++)a.push(v(n.parts[i]));o[n.id]={id:n.id,refs:1,parts:a}}}}function g(){var e=document.createElement("style");return e.type="text/css",a.appendChild(e),e}function v(e){var t,n,r=document.querySelector("style["+h+'~="'+e.id+'"]');if(r){if(c)return u;r.parentNode.removeChild(r)}if(p){var i=l++;r=s||(s=g()),t=y.bind(null,r,i,!1),n=y.bind(null,r,i,!0)}else r=g(),t=w.bind(null,r),n=function(){r.parentNode.removeChild(r)};return t(e),function(r){if(r){if(r.css===e.css&&r.media===e.media&&r.sourceMap===e.sourceMap)return;t(e=r)}else n()}}var b=function(){var e=[];return function(t,n){return e[t]=n,e.filter(Boolean).join("\n")}}();function y(e,t,n,r){var i=n?"":r.css;if(e.styleSheet)e.styleSheet.cssText=b(t,i);else{var o=document.createTextNode(i),a=e.childNodes;a[t]&&e.removeChild(a[t]),a.length?e.insertBefore(o,a[t]):e.appendChild(o)}}function w(e,t){var n=t.css,r=t.media,i=t.sourceMap;if(r&&e.setAttribute("media",r),d.ssrId&&e.setAttribute(h,t.id),i&&(n+="\n/*# sourceURL="+i.sources[0]+" */",n+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(i))))+" */"),e.styleSheet)e.styleSheet.cssText=n;else{while(e.firstChild)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(n))}}},65359:function(e,t,n){"use strict";n.d(t,{y$:function(){return ee},i0:function(){return oe},L8:function(){return ie},aH:function(){return re},Pj:function(){return g}});var r=n(9274);function i(){return o().__VUE_DEVTOOLS_GLOBAL_HOOK__}function o(){return"undefined"!==typeof navigator&&"undefined"!==typeof window?window:"undefined"!==typeof globalThis?globalThis:{}}const a="function"===typeof Proxy,s="devtools-plugin:setup",l="plugin:settings:set";let c,u;function d(){var e;return void 0!==c||("undefined"!==typeof window&&window.performance?(c=!0,u=window.performance):"undefined"!==typeof globalThis&&(null===(e=globalThis.perf_hooks)||void 0===e?void 0:e.performance)?(c=!0,u=globalThis.perf_hooks.performance):c=!1),c}function h(){return d()?u.now():Date.now()}class p{constructor(e,t){this.target=null,this.targetQueue=[],this.onQueue=[],this.plugin=e,this.hook=t;const n={};if(e.settings)for(const a in e.settings){const t=e.settings[a];n[a]=t.defaultValue}const r=`__vue-devtools-plugin-settings__${e.id}`;let i=Object.assign({},n);try{const e=localStorage.getItem(r),t=JSON.parse(e);Object.assign(i,t)}catch(o){}this.fallbacks={getSettings(){return i},setSettings(e){try{localStorage.setItem(r,JSON.stringify(e))}catch(o){}i=e},now(){return h()}},t&&t.on(l,(e,t)=>{e===this.plugin.id&&this.fallbacks.setSettings(t)}),this.proxiedOn=new Proxy({},{get:(e,t)=>this.target?this.target.on[t]:(...e)=>{this.onQueue.push({method:t,args:e})}}),this.proxiedTarget=new Proxy({},{get:(e,t)=>this.target?this.target[t]:"on"===t?this.proxiedOn:Object.keys(this.fallbacks).includes(t)?(...e)=>(this.targetQueue.push({method:t,args:e,resolve:()=>{}}),this.fallbacks[t](...e)):(...e)=>new Promise(n=>{this.targetQueue.push({method:t,args:e,resolve:n})})})}async setRealTarget(e){this.target=e;for(const t of this.onQueue)this.target.on[t.method](...t.args);for(const t of this.targetQueue)t.resolve(await this.target[t.method](...t.args))}}function f(e,t){const n=e,r=o(),l=i(),c=a&&n.enableEarlyProxy;if(!l||!r.__VUE_DEVTOOLS_PLUGIN_API_AVAILABLE__&&c){const e=c?new p(n,l):null,i=r.__VUE_DEVTOOLS_PLUGINS__=r.__VUE_DEVTOOLS_PLUGINS__||[];i.push({pluginDescriptor:n,setupFn:t,proxy:e}),e&&t(e.proxiedTarget)}else l.emit(s,e,t)}n(4364);
|
||
/*!
|
||
* vuex v4.1.0
|
||
* (c) 2022 Evan You
|
||
* @license MIT
|
||
*/var m="store";function g(e){return void 0===e&&(e=null),(0,r.inject)(null!==e?e:m)}function v(e,t){Object.keys(e).forEach(function(n){return t(e[n],n)})}function b(e){return null!==e&&"object"===typeof e}function y(e){return e&&"function"===typeof e.then}function w(e,t){return function(){return e(t)}}function O(e,t,n){return t.indexOf(e)<0&&(n&&n.prepend?t.unshift(e):t.push(e)),function(){var n=t.indexOf(e);n>-1&&t.splice(n,1)}}function S(e,t){e._actions=Object.create(null),e._mutations=Object.create(null),e._wrappedGetters=Object.create(null),e._modulesNamespaceMap=Object.create(null);var n=e.state;x(e,n,[],e._modules.root,!0),E(e,n,t)}function E(e,t,n){var i=e._state,o=e._scope;e.getters={},e._makeLocalGettersCache=Object.create(null);var a=e._wrappedGetters,s={},l={},c=(0,r.effectScope)(!0);c.run(function(){v(a,function(t,n){s[n]=w(t,e),l[n]=(0,r.computed)(function(){return s[n]()}),Object.defineProperty(e.getters,n,{get:function(){return l[n].value},enumerable:!0})})}),e._state=(0,r.reactive)({data:t}),e._scope=c,e.strict&&R(e),i&&n&&e._withCommit(function(){i.data=null}),o&&o.stop()}function x(e,t,n,r,i){var o=!n.length,a=e._modules.getNamespace(n);if(r.namespaced&&(e._modulesNamespaceMap[a],e._modulesNamespaceMap[a]=r),!o&&!i){var s=N(t,n.slice(0,-1)),l=n[n.length-1];e._withCommit(function(){s[l]=r.state})}var c=r.context=_(e,a,n);r.forEachMutation(function(t,n){var r=a+n;C(e,r,t,c)}),r.forEachAction(function(t,n){var r=t.root?n:a+n,i=t.handler||t;A(e,r,i,c)}),r.forEachGetter(function(t,n){var r=a+n;T(e,r,t,c)}),r.forEachChild(function(r,o){x(e,t,n.concat(o),r,i)})}function _(e,t,n){var r=""===t,i={dispatch:r?e.dispatch:function(n,r,i){var o=P(n,r,i),a=o.payload,s=o.options,l=o.type;return s&&s.root||(l=t+l),e.dispatch(l,a)},commit:r?e.commit:function(n,r,i){var o=P(n,r,i),a=o.payload,s=o.options,l=o.type;s&&s.root||(l=t+l),e.commit(l,a,s)}};return Object.defineProperties(i,{getters:{get:r?function(){return e.getters}:function(){return k(e,t)}},state:{get:function(){return N(e.state,n)}}}),i}function k(e,t){if(!e._makeLocalGettersCache[t]){var n={},r=t.length;Object.keys(e.getters).forEach(function(i){if(i.slice(0,r)===t){var o=i.slice(r);Object.defineProperty(n,o,{get:function(){return e.getters[i]},enumerable:!0})}}),e._makeLocalGettersCache[t]=n}return e._makeLocalGettersCache[t]}function C(e,t,n,r){var i=e._mutations[t]||(e._mutations[t]=[]);i.push(function(t){n.call(e,r.state,t)})}function A(e,t,n,r){var i=e._actions[t]||(e._actions[t]=[]);i.push(function(t){var i=n.call(e,{dispatch:r.dispatch,commit:r.commit,getters:r.getters,state:r.state,rootGetters:e.getters,rootState:e.state},t);return y(i)||(i=Promise.resolve(i)),e._devtoolHook?i.catch(function(t){throw e._devtoolHook.emit("vuex:error",t),t}):i})}function T(e,t,n,r){e._wrappedGetters[t]||(e._wrappedGetters[t]=function(e){return n(r.state,r.getters,e.state,e.getters)})}function R(e){(0,r.watch)(function(){return e._state.data},function(){0},{deep:!0,flush:"sync"})}function N(e,t){return t.reduce(function(e,t){return e[t]},e)}function P(e,t,n){return b(e)&&e.type&&(n=t,t=e,e=e.type),{type:e,payload:t,options:n}}var I="vuex bindings",M="vuex:mutations",D="vuex:actions",L="vuex",B=0;function $(e,t){f({id:"org.vuejs.vuex",app:e,label:"Vuex",homepage:"https://next.vuex.vuejs.org/",logo:"https://vuejs.org/images/icons/favicon-96x96.png",packageName:"vuex",componentStateTypes:[I]},function(n){n.addTimelineLayer({id:M,label:"Vuex Mutations",color:V}),n.addTimelineLayer({id:D,label:"Vuex Actions",color:V}),n.addInspector({id:L,label:"Vuex",icon:"storage",treeFilterPlaceholder:"Filter stores..."}),n.on.getInspectorTree(function(n){if(n.app===e&&n.inspectorId===L)if(n.filter){var r=[];q(r,t._modules.root,n.filter,""),n.rootNodes=r}else n.rootNodes=[H(t._modules.root,"")]}),n.on.getInspectorState(function(n){if(n.app===e&&n.inspectorId===L){var r=n.nodeId;k(t,r),n.state=Q(K(t._modules,r),"root"===r?t.getters:t._makeLocalGettersCache,r)}}),n.on.editInspectorState(function(n){if(n.app===e&&n.inspectorId===L){var r=n.nodeId,i=n.path;"root"!==r&&(i=r.split("/").filter(Boolean).concat(i)),t._withCommit(function(){n.set(t._state.data,i,n.state.value)})}}),t.subscribe(function(e,t){var r={};e.payload&&(r.payload=e.payload),r.state=t,n.notifyComponentUpdate(),n.sendInspectorTree(L),n.sendInspectorState(L),n.addTimelineEvent({layerId:M,event:{time:Date.now(),title:e.type,data:r}})}),t.subscribeAction({before:function(e,t){var r={};e.payload&&(r.payload=e.payload),e._id=B++,e._time=Date.now(),r.state=t,n.addTimelineEvent({layerId:D,event:{time:e._time,title:e.type,groupId:e._id,subtitle:"start",data:r}})},after:function(e,t){var r={},i=Date.now()-e._time;r.duration={_custom:{type:"duration",display:i+"ms",tooltip:"Action duration",value:i}},e.payload&&(r.payload=e.payload),r.state=t,n.addTimelineEvent({layerId:D,event:{time:Date.now(),title:e.type,groupId:e._id,subtitle:"end",data:r}})}})})}var V=8702998,F=6710886,j=16777215,U={label:"namespaced",textColor:j,backgroundColor:F};function G(e){return e&&"root"!==e?e.split("/").slice(-2,-1)[0]:"Root"}function H(e,t){return{id:t||"root",label:G(t),tags:e.namespaced?[U]:[],children:Object.keys(e._children).map(function(n){return H(e._children[n],t+n+"/")})}}function q(e,t,n,r){r.includes(n)&&e.push({id:r||"root",label:r.endsWith("/")?r.slice(0,r.length-1):r||"Root",tags:t.namespaced?[U]:[]}),Object.keys(t._children).forEach(function(i){q(e,t._children[i],n,r+i+"/")})}function Q(e,t,n){t="root"===n?t:t[n];var r=Object.keys(t),i={state:Object.keys(e.state).map(function(t){return{key:t,editable:!0,value:e.state[t]}})};if(r.length){var o=z(t);i.getters=Object.keys(o).map(function(e){return{key:e.endsWith("/")?G(e):e,editable:!1,value:W(function(){return o[e]})}})}return i}function z(e){var t={};return Object.keys(e).forEach(function(n){var r=n.split("/");if(r.length>1){var i=t,o=r.pop();r.forEach(function(e){i[e]||(i[e]={_custom:{value:{},display:e,tooltip:"Module",abstract:!0}}),i=i[e]._custom.value}),i[o]=W(function(){return e[n]})}else t[n]=W(function(){return e[n]})}),t}function K(e,t){var n=t.split("/").filter(function(e){return e});return n.reduce(function(e,r,i){var o=e[r];if(!o)throw new Error('Missing module "'+r+'" for path "'+t+'".');return i===n.length-1?o:o._children},"root"===t?e:e.root._children)}function W(e){try{return e()}catch(t){return t}}var X=function(e,t){this.runtime=t,this._children=Object.create(null),this._rawModule=e;var n=e.state;this.state=("function"===typeof n?n():n)||{}},Y={namespaced:{configurable:!0}};Y.namespaced.get=function(){return!!this._rawModule.namespaced},X.prototype.addChild=function(e,t){this._children[e]=t},X.prototype.removeChild=function(e){delete this._children[e]},X.prototype.getChild=function(e){return this._children[e]},X.prototype.hasChild=function(e){return e in this._children},X.prototype.update=function(e){this._rawModule.namespaced=e.namespaced,e.actions&&(this._rawModule.actions=e.actions),e.mutations&&(this._rawModule.mutations=e.mutations),e.getters&&(this._rawModule.getters=e.getters)},X.prototype.forEachChild=function(e){v(this._children,e)},X.prototype.forEachGetter=function(e){this._rawModule.getters&&v(this._rawModule.getters,e)},X.prototype.forEachAction=function(e){this._rawModule.actions&&v(this._rawModule.actions,e)},X.prototype.forEachMutation=function(e){this._rawModule.mutations&&v(this._rawModule.mutations,e)},Object.defineProperties(X.prototype,Y);var Z=function(e){this.register([],e,!1)};function J(e,t,n){if(t.update(n),n.modules)for(var r in n.modules){if(!t.getChild(r))return void 0;J(e.concat(r),t.getChild(r),n.modules[r])}}Z.prototype.get=function(e){return e.reduce(function(e,t){return e.getChild(t)},this.root)},Z.prototype.getNamespace=function(e){var t=this.root;return e.reduce(function(e,n){return t=t.getChild(n),e+(t.namespaced?n+"/":"")},"")},Z.prototype.update=function(e){J([],this.root,e)},Z.prototype.register=function(e,t,n){var r=this;void 0===n&&(n=!0);var i=new X(t,n);if(0===e.length)this.root=i;else{var o=this.get(e.slice(0,-1));o.addChild(e[e.length-1],i)}t.modules&&v(t.modules,function(t,i){r.register(e.concat(i),t,n)})},Z.prototype.unregister=function(e){var t=this.get(e.slice(0,-1)),n=e[e.length-1],r=t.getChild(n);r&&r.runtime&&t.removeChild(n)},Z.prototype.isRegistered=function(e){var t=this.get(e.slice(0,-1)),n=e[e.length-1];return!!t&&t.hasChild(n)};function ee(e){return new te(e)}var te=function(e){var t=this;void 0===e&&(e={});var n=e.plugins;void 0===n&&(n=[]);var r=e.strict;void 0===r&&(r=!1);var i=e.devtools;this._committing=!1,this._actions=Object.create(null),this._actionSubscribers=[],this._mutations=Object.create(null),this._wrappedGetters=Object.create(null),this._modules=new Z(e),this._modulesNamespaceMap=Object.create(null),this._subscribers=[],this._makeLocalGettersCache=Object.create(null),this._scope=null,this._devtools=i;var o=this,a=this,s=a.dispatch,l=a.commit;this.dispatch=function(e,t){return s.call(o,e,t)},this.commit=function(e,t,n){return l.call(o,e,t,n)},this.strict=r;var c=this._modules.root.state;x(this,c,[],this._modules.root),E(this,c),n.forEach(function(e){return e(t)})},ne={state:{configurable:!0}};te.prototype.install=function(e,t){e.provide(t||m,this),e.config.globalProperties.$store=this;var n=void 0!==this._devtools&&this._devtools;n&&$(e,this)},ne.state.get=function(){return this._state.data},ne.state.set=function(e){0},te.prototype.commit=function(e,t,n){var r=this,i=P(e,t,n),o=i.type,a=i.payload,s=(i.options,{type:o,payload:a}),l=this._mutations[o];l&&(this._withCommit(function(){l.forEach(function(e){e(a)})}),this._subscribers.slice().forEach(function(e){return e(s,r.state)}))},te.prototype.dispatch=function(e,t){var n=this,r=P(e,t),i=r.type,o=r.payload,a={type:i,payload:o},s=this._actions[i];if(s){try{this._actionSubscribers.slice().filter(function(e){return e.before}).forEach(function(e){return e.before(a,n.state)})}catch(c){0}var l=s.length>1?Promise.all(s.map(function(e){return e(o)})):s[0](o);return new Promise(function(e,t){l.then(function(t){try{n._actionSubscribers.filter(function(e){return e.after}).forEach(function(e){return e.after(a,n.state)})}catch(c){0}e(t)},function(e){try{n._actionSubscribers.filter(function(e){return e.error}).forEach(function(t){return t.error(a,n.state,e)})}catch(c){0}t(e)})})}},te.prototype.subscribe=function(e,t){return O(e,this._subscribers,t)},te.prototype.subscribeAction=function(e,t){var n="function"===typeof e?{before:e}:e;return O(n,this._actionSubscribers,t)},te.prototype.watch=function(e,t,n){var i=this;return(0,r.watch)(function(){return e(i.state,i.getters)},t,Object.assign({},n))},te.prototype.replaceState=function(e){var t=this;this._withCommit(function(){t._state.data=e})},te.prototype.registerModule=function(e,t,n){void 0===n&&(n={}),"string"===typeof e&&(e=[e]),this._modules.register(e,t),x(this,this.state,e,this._modules.get(e),n.preserveState),E(this,this.state)},te.prototype.unregisterModule=function(e){var t=this;"string"===typeof e&&(e=[e]),this._modules.unregister(e),this._withCommit(function(){var n=N(t.state,e.slice(0,-1));delete n[e[e.length-1]]}),S(this)},te.prototype.hasModule=function(e){return"string"===typeof e&&(e=[e]),this._modules.isRegistered(e)},te.prototype.hotUpdate=function(e){this._modules.update(e),S(this,!0)},te.prototype._withCommit=function(e){var t=this._committing;this._committing=!0,e(),this._committing=t},Object.defineProperties(te.prototype,ne);var re=le(function(e,t){var n={};return ae(t).forEach(function(t){var r=t.key,i=t.val;n[r]=function(){var t=this.$store.state,n=this.$store.getters;if(e){var r=ce(this.$store,"mapState",e);if(!r)return;t=r.context.state,n=r.context.getters}return"function"===typeof i?i.call(this,t,n):t[i]},n[r].vuex=!0}),n}),ie=(le(function(e,t){var n={};return ae(t).forEach(function(t){var r=t.key,i=t.val;n[r]=function(){var t=[],n=arguments.length;while(n--)t[n]=arguments[n];var r=this.$store.commit;if(e){var o=ce(this.$store,"mapMutations",e);if(!o)return;r=o.context.commit}return"function"===typeof i?i.apply(this,[r].concat(t)):r.apply(this.$store,[i].concat(t))}}),n}),le(function(e,t){var n={};return ae(t).forEach(function(t){var r=t.key,i=t.val;i=e+i,n[r]=function(){if(!e||ce(this.$store,"mapGetters",e))return this.$store.getters[i]},n[r].vuex=!0}),n})),oe=le(function(e,t){var n={};return ae(t).forEach(function(t){var r=t.key,i=t.val;n[r]=function(){var t=[],n=arguments.length;while(n--)t[n]=arguments[n];var r=this.$store.dispatch;if(e){var o=ce(this.$store,"mapActions",e);if(!o)return;r=o.context.dispatch}return"function"===typeof i?i.apply(this,[r].concat(t)):r.apply(this.$store,[i].concat(t))}}),n});function ae(e){return se(e)?Array.isArray(e)?e.map(function(e){return{key:e,val:e}}):Object.keys(e).map(function(t){return{key:t,val:e[t]}}):[]}function se(e){return Array.isArray(e)||b(e)}function le(e){return function(t,n){return"string"!==typeof t?(n=t,t=""):"/"!==t.charAt(t.length-1)&&(t+="/"),e(t,n)}}function ce(e,t,n){var r=e._modulesNamespaceMap[n];return r}},52730:function(e,t,n){"use strict";var r=n(80705),i=n(14834),o=n(28498),a=n(14607),s=n(69336),l=n(46369),c=a("Object.prototype.toString"),u=n(51913)(),d="undefined"===typeof globalThis?n.g:globalThis,h=i(),p=a("String.prototype.slice"),f=a("Array.prototype.indexOf",!0)||function(e,t){for(var n=0;n<e.length;n+=1)if(e[n]===t)return n;return-1},m={__proto__:null};r(h,u&&s&&l?function(e){var t=new d[e];if(Symbol.toStringTag in t&&l){var n=l(t),r=s(n,Symbol.toStringTag);if(!r&&n){var i=l(n);r=s(i,Symbol.toStringTag)}if(r&&r.get){var a=o(r.get);m["$"+e]=a}}}:function(e){var t=new d[e],n=t.slice||t.set;if(n){var r=o(n);m["$"+e]=r}});var g=function(e){var t=!1;return r(m,function(n,r){if(!t)try{"$"+n(e)===r&&(t=p(r,1))}catch(i){}}),t},v=function(e){var t=!1;return r(m,function(n,r){if(!t)try{n(e),t=p(r,1)}catch(i){}}),t};e.exports=function(e){if(!e||"object"!==typeof e)return!1;if(!u){var t=p(c(e),8,-1);return f(h,t)>-1?t:"Object"===t&&v(e)}return s?g(e):null}},93227:function(e){e.exports=n;var t=Object.prototype.hasOwnProperty;function n(){for(var e={},n=0;n<arguments.length;n++){var r=arguments[n];for(var i in r)t.call(r,i)&&(e[i]=r[i])}return e}},93197:function(e,t,n){var r={"./__tests__/apps.deployment.test":25192,"./__tests__/apps.deployment.test.ts":25192,"./__tests__/apps.replicaset.test":83805,"./__tests__/apps.replicaset.test.ts":83805,"./__tests__/auditlog.cattle.io.auditpolicy.test":34700,"./__tests__/auditlog.cattle.io.auditpolicy.test.ts":34700,"./__tests__/batch.cronjob.test":8432,"./__tests__/batch.cronjob.test.ts":8432,"./__tests__/catalog.cattle.io.app.test":94226,"./__tests__/catalog.cattle.io.app.test.ts":94226,"./__tests__/catalog.cattle.io.clusterrepo.test":42173,"./__tests__/catalog.cattle.io.clusterrepo.test.ts":42173,"./__tests__/chart.test":44775,"./__tests__/chart.test.ts":44775,"./__tests__/cloudcredential.test":62275,"./__tests__/cloudcredential.test.ts":62275,"./__tests__/cluster.test":13573,"./__tests__/cluster.test.ts":13573,"./__tests__/compliance.cattle.io.clusterscan.test":9258,"./__tests__/compliance.cattle.io.clusterscan.test.ts":9258,"./__tests__/compliance.cattle.io.clusterscanprofile.spec":98962,"./__tests__/compliance.cattle.io.clusterscanprofile.spec.js":98962,"./__tests__/ext.cattle.io.kubeconfig.test":90466,"./__tests__/ext.cattle.io.kubeconfig.test.ts":90466,"./__tests__/fleet-application.test":2054,"./__tests__/fleet-application.test.ts":2054,"./__tests__/fleet.cattle.io.bundle.test":6864,"./__tests__/fleet.cattle.io.bundle.test.ts":6864,"./__tests__/fleet.cattle.io.cluster.test":84264,"./__tests__/fleet.cattle.io.cluster.test.ts":84264,"./__tests__/fleet.cattle.io.gitrepo.test":44282,"./__tests__/fleet.cattle.io.gitrepo.test.ts":44282,"./__tests__/fleet.cattle.io.helmop.test":37069,"./__tests__/fleet.cattle.io.helmop.test.ts":37069,"./__tests__/fleet.cattle.io.policy.test":19454,"./__tests__/fleet.cattle.io.policy.test.ts":19454,"./__tests__/gateway.networking.k8s.io.httproute.test":49636,"./__tests__/gateway.networking.k8s.io.httproute.test.ts":49636,"./__tests__/logging.banzaicloud.io.flow.test":85166,"./__tests__/logging.banzaicloud.io.flow.test.ts":85166,"./__tests__/management.cattle.io.authconfig.test":48207,"./__tests__/management.cattle.io.authconfig.test.ts":48207,"./__tests__/management.cattle.io.cluster.test":58221,"./__tests__/management.cattle.io.cluster.test.ts":58221,"./__tests__/management.cattle.io.clusterroletemplatebinding.test":77316,"./__tests__/management.cattle.io.clusterroletemplatebinding.test.ts":77316,"./__tests__/management.cattle.io.feature.test":49833,"./__tests__/management.cattle.io.feature.test.ts":49833,"./__tests__/management.cattle.io.node":25529,"./__tests__/management.cattle.io.node.ts":25529,"./__tests__/management.cattle.io.nodepool":94479,"./__tests__/management.cattle.io.nodepool.ts":94479,"./__tests__/management.cattle.io.project.test":15460,"./__tests__/management.cattle.io.project.test.ts":15460,"./__tests__/management.cattle.io.projectroletemplatebinding.test":34375,"./__tests__/management.cattle.io.projectroletemplatebinding.test.ts":34375,"./__tests__/monitoring.coreos.com.alertmanagerconfig.test":4166,"./__tests__/monitoring.coreos.com.alertmanagerconfig.test.ts":4166,"./__tests__/namespace.test":68882,"./__tests__/namespace.test.ts":68882,"./__tests__/node.test":4915,"./__tests__/node.test.ts":4915,"./__tests__/pod.test":54566,"./__tests__/pod.test.ts":54566,"./__tests__/principal.test":54837,"./__tests__/principal.test.ts":54837,"./__tests__/provisioning.cattle.io.cluster.test":29759,"./__tests__/provisioning.cattle.io.cluster.test.ts":29759,"./__tests__/rke-machine.cattle.io.vmwarevspheremachinetemplate.test":22892,"./__tests__/rke-machine.cattle.io.vmwarevspheremachinetemplate.test.ts":22892,"./__tests__/schema.tests":81453,"./__tests__/schema.tests.ts":81453,"./__tests__/secret.projects.test":66131,"./__tests__/secret.projects.test.ts":66131,"./__tests__/secret.steve.test":28688,"./__tests__/secret.steve.test.ts":28688,"./__tests__/secret.test":19147,"./__tests__/secret.test.ts":19147,"./__tests__/steve-schema.test":66888,"./__tests__/steve-schema.test.ts":66888,"./__tests__/storage.k8s.io.storageclass.test":77107,"./__tests__/storage.k8s.io.storageclass.test.ts":77107,"./__tests__/workload.service.test":87819,"./__tests__/workload.service.test.ts":87819,"./__tests__/workload.test":91624,"./__tests__/workload.test.ts":91624,"./apiextensions.k8s.io.customresourcedefinition":68115,"./apiextensions.k8s.io.customresourcedefinition.js":68115,"./app":426,"./app.js":426,"./apps.controllerrevision":54686,"./apps.controllerrevision.js":54686,"./apps.daemonset":89395,"./apps.daemonset.js":89395,"./apps.deployment":41212,"./apps.deployment.js":41212,"./apps.replicaset":77763,"./apps.replicaset.js":77763,"./apps.statefulset":86791,"./apps.statefulset.js":86791,"./auditlog.cattle.io.auditpolicy":8488,"./auditlog.cattle.io.auditpolicy.js":8488,"./autoscaling.horizontalpodautoscaler":20763,"./autoscaling.horizontalpodautoscaler.js":20763,"./base-cluster.x-k8s.io":77684,"./base-cluster.x-k8s.io.js":77684,"./batch.cronjob":43020,"./batch.cronjob.js":43020,"./batch.job":66184,"./batch.job.js":66184,"./catalog.cattle.io.app":65502,"./catalog.cattle.io.app.js":65502,"./catalog.cattle.io.clusterrepo":75348,"./catalog.cattle.io.clusterrepo.js":75348,"./catalog.cattle.io.operation":67784,"./catalog.cattle.io.operation.js":67784,"./catalog.cattle.io.repo":71029,"./catalog.cattle.io.repo.js":71029,"./catalog.cattle.io.uiplugin":97960,"./catalog.cattle.io.uiplugin.js":97960,"./chart":92737,"./chart.js":92737,"./chartinstallaction":91380,"./chartinstallaction.js":91380,"./chartupgradeaction":4451,"./chartupgradeaction.js":4451,"./cloudcredential":45231,"./cloudcredential.js":45231,"./cluster":16787,"./cluster.js":16787,"./cluster.x-k8s.io.machine":61843,"./cluster.x-k8s.io.machine.js":61843,"./cluster.x-k8s.io.machinedeployment":22456,"./cluster.x-k8s.io.machinedeployment.js":22456,"./cluster.x-k8s.io.machineset":5555,"./cluster.x-k8s.io.machineset.js":5555,"./cluster/node":44458,"./cluster/node.js":44458,"./cluster/schema":62973,"./cluster/schema.js":62973,"./clusterroletemplatebinding":40408,"./clusterroletemplatebinding.js":40408,"./compliance.cattle.io.clusterscan":53622,"./compliance.cattle.io.clusterscan.js":53622,"./compliance.cattle.io.clusterscanbenchmark":87923,"./compliance.cattle.io.clusterscanbenchmark.js":87923,"./compliance.cattle.io.clusterscanprofile":22513,"./compliance.cattle.io.clusterscanprofile.js":22513,"./compliance.cattle.io.clusterscanreport":98728,"./compliance.cattle.io.clusterscanreport.js":98728,"./configmap":79925,"./configmap.js":79925,"./constraints.gatekeeper.sh.constraint":40172,"./constraints.gatekeeper.sh.constraint.js":40172,"./driver":81147,"./driver.js":81147,"./event":28473,"./event.js":28473,"./ext.cattle.io.groupmembershiprefreshrequest":42510,"./ext.cattle.io.groupmembershiprefreshrequest.js":42510,"./ext.cattle.io.kubeconfig":6856,"./ext.cattle.io.kubeconfig.ts":6856,"./ext.cattle.io.passwordchangerequest":61607,"./ext.cattle.io.passwordchangerequest.js":61607,"./ext.cattle.io.selfuser":76448,"./ext.cattle.io.selfuser.js":76448,"./fleet-application":91970,"./fleet-application.js":91970,"./fleet.cattle.io.bundle":5096,"./fleet.cattle.io.bundle.js":5096,"./fleet.cattle.io.cluster":5904,"./fleet.cattle.io.cluster.js":5904,"./fleet.cattle.io.clustergroup":11173,"./fleet.cattle.io.clustergroup.js":11173,"./fleet.cattle.io.clusterregistrationtoken":67424,"./fleet.cattle.io.clusterregistrationtoken.js":67424,"./fleet.cattle.io.gitrepo":84402,"./fleet.cattle.io.gitrepo.js":84402,"./fleet.cattle.io.helmop":80591,"./fleet.cattle.io.helmop.js":80591,"./fleet.cattle.io.policy":2036,"./fleet.cattle.io.policy.ts":2036,"./gateway.networking.k8s.io.gateway":99611,"./gateway.networking.k8s.io.gateway.js":99611,"./gateway.networking.k8s.io.httproute":87784,"./gateway.networking.k8s.io.httproute.js":87784,"./group.principal":97030,"./group.principal.js":97030,"./helm.cattle.io.projecthelmchart":7899,"./helm.cattle.io.projecthelmchart.js":7899,"./k8s.cni.cncf.io.networkattachmentdefinition":72183,"./k8s.cni.cncf.io.networkattachmentdefinition.js":72183,"./kontainerdriver":83448,"./kontainerdriver.js":83448,"./logging.banzaicloud.io.clusterflow":78694,"./logging.banzaicloud.io.clusterflow.js":78694,"./logging.banzaicloud.io.clusteroutput":63331,"./logging.banzaicloud.io.clusteroutput.js":63331,"./logging.banzaicloud.io.flow":21766,"./logging.banzaicloud.io.flow.js":21766,"./logging.banzaicloud.io.output":44931,"./logging.banzaicloud.io.output.js":44931,"./management.cattle.io.authconfig":78277,"./management.cattle.io.authconfig.js":78277,"./management.cattle.io.cluster":65230,"./management.cattle.io.cluster.js":65230,"./management.cattle.io.clusterroletemplatebinding":54820,"./management.cattle.io.clusterroletemplatebinding.js":54820,"./management.cattle.io.feature":58975,"./management.cattle.io.feature.js":58975,"./management.cattle.io.fleetworkspace":61504,"./management.cattle.io.fleetworkspace.js":61504,"./management.cattle.io.gitreporestriction":33707,"./management.cattle.io.gitreporestriction.js":33707,"./management.cattle.io.globalrole":14606,"./management.cattle.io.globalrole.js":14606,"./management.cattle.io.globalrolebinding":97621,"./management.cattle.io.globalrolebinding.js":97621,"./management.cattle.io.kontainerdriver":44660,"./management.cattle.io.kontainerdriver.js":44660,"./management.cattle.io.node":77917,"./management.cattle.io.node.js":77917,"./management.cattle.io.nodepool":68959,"./management.cattle.io.nodepool.js":68959,"./management.cattle.io.nodetemplate":57075,"./management.cattle.io.nodetemplate.js":57075,"./management.cattle.io.oidcclient":81831,"./management.cattle.io.oidcclient.js":81831,"./management.cattle.io.podsecurityadmissionconfigurationtemplate":10311,"./management.cattle.io.podsecurityadmissionconfigurationtemplate.js":10311,"./management.cattle.io.project":24220,"./management.cattle.io.project.js":24220,"./management.cattle.io.projectroletemplatebinding":91673,"./management.cattle.io.projectroletemplatebinding.js":91673,"./management.cattle.io.registration":4372,"./management.cattle.io.registration.js":4372,"./management.cattle.io.roletemplate":4799,"./management.cattle.io.roletemplate.js":4799,"./management.cattle.io.setting":76061,"./management.cattle.io.setting.js":76061,"./management.cattle.io.user":69754,"./management.cattle.io.user.js":69754,"./management/schema":95694,"./management/schema.js":95694,"./metrics.k8s.io.nodemetrics":86465,"./metrics.k8s.io.nodemetrics.js":86465,"./monitoring.coreos.com.alertmanagerconfig":34858,"./monitoring.coreos.com.alertmanagerconfig.js":34858,"./monitoring.coreos.com.podmonitor":67750,"./monitoring.coreos.com.podmonitor.js":67750,"./monitoring.coreos.com.prometheusrule":61403,"./monitoring.coreos.com.prometheusrule.js":61403,"./monitoring.coreos.com.receiver":57e3,"./monitoring.coreos.com.receiver.js":57e3,"./monitoring.coreos.com.route":55162,"./monitoring.coreos.com.route.js":55162,"./monitoring.coreos.com.servicemonitor":906,"./monitoring.coreos.com.servicemonitor.js":906,"./namespace":67867,"./namespace.js":67867,"./networking.istio.io.destinationrule":1835,"./networking.istio.io.destinationrule.js":1835,"./networking.k8s.io.ingress":67462,"./networking.k8s.io.ingress.js":67462,"./nodedriver":80903,"./nodedriver.js":80903,"./persistentvolume":13070,"./persistentvolume.js":13070,"./persistentvolumeclaim":17544,"./persistentvolumeclaim.js":17544,"./pod":76006,"./pod.js":76006,"./principal":97219,"./principal.js":97219,"./projectroletemplatebinding":99493,"./projectroletemplatebinding.js":99493,"./provisioning.cattle.io.cluster":47685,"./provisioning.cattle.io.cluster.js":47685,"./rbac.authorization.k8s.io.clusterrole":8324,"./rbac.authorization.k8s.io.clusterrole.js":8324,"./rbac.authorization.k8s.io.clusterrolebinding":69791,"./rbac.authorization.k8s.io.clusterrolebinding.js":69791,"./rbac.authorization.k8s.io.role":51700,"./rbac.authorization.k8s.io.role.js":51700,"./rbac.authorization.k8s.io.rolebinding":559,"./rbac.authorization.k8s.io.rolebinding.js":559,"./replicationcontroller":12299,"./replicationcontroller.js":12299,"./resources.cattle.io.backup":89713,"./resources.cattle.io.backup.js":89713,"./resources.cattle.io.restore":23741,"./resources.cattle.io.restore.js":23741,"./rke-machine-config.cattle.io.harvesterconfig":81689,"./rke-machine-config.cattle.io.harvesterconfig.js":81689,"./rke-machine.cattle.io.amazonec2machinetemplate":39651,"./rke-machine.cattle.io.amazonec2machinetemplate.js":39651,"./rke-machine.cattle.io.azuremachinetemplate":79144,"./rke-machine.cattle.io.azuremachinetemplate.js":79144,"./rke-machine.cattle.io.digitaloceanmachinetemplate":81593,"./rke-machine.cattle.io.digitaloceanmachinetemplate.js":81593,"./rke-machine.cattle.io.linodemachinetemplate":69770,"./rke-machine.cattle.io.linodemachinetemplate.js":69770,"./rke-machine.cattle.io.machinetemplate":38799,"./rke-machine.cattle.io.machinetemplate.js":38799,"./rke-machine.cattle.io.pnapmachinetemplate":82186,"./rke-machine.cattle.io.pnapmachinetemplate.js":82186,"./rke-machine.cattle.io.vmwarevspheremachinetemplate":38816,"./rke-machine.cattle.io.vmwarevspheremachinetemplate.js":38816,"./rke.cattle.io.etcdsnapshot":7100,"./rke.cattle.io.etcdsnapshot.js":7100,"./schema":2334,"./schema.js":2334,"./secret":1133,"./secret.js":1133,"./service":96258,"./service.js":96258,"./steve-schema":45858,"./steve-schema.ts":45858,"./storage.k8s.io.storageclass":63809,"./storage.k8s.io.storageclass.js":63809,"./templates.gatekeeper.sh.constrainttemplate":66491,"./templates.gatekeeper.sh.constrainttemplate.js":66491,"./token":24364,"./token.js":24364,"./ui.cattle.io.navlink":51225,"./ui.cattle.io.navlink.js":51225,"./workload":70775,"./workload.js":70775,"./workload.service":2505,"./workload.service.js":2505};function i(e){var t=o(e);return n(t)}function o(e){if(!n.o(r,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return r[e]}i.keys=function(){return Object.keys(r)},i.resolve=o,e.exports=i,i.id=93197},39989:function(e,t,n){var r={"./management.cattle.io.fleetworkspace":2572,"./management.cattle.io.fleetworkspace.vue":2572,"./management.cattle.io.globalrole":39126,"./management.cattle.io.globalrole.vue":39126,"./management.cattle.io.project":11193,"./management.cattle.io.project.vue":11193,"./management.cattle.io.roletemplate":24093,"./management.cattle.io.roletemplate.vue":24093,"./mixin/roleDeletionCheck":55105,"./mixin/roleDeletionCheck.js":55105,"./pod":4563,"./pod.vue":4563};function i(e){var t=o(e);return n(t)}function o(e){if(!n.o(r,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return r[e]}i.keys=function(){return Object.keys(r)},i.resolve=o,e.exports=i,i.id=39989},29097:function(e,t,n){var r="undefined"!==typeof window&&window.__codemirror&&window.__codemirror["@codemirror/autocomplete"];e.exports=r||n(49609)},37323:function(e,t,n){var r="undefined"!==typeof window&&window.__codemirror&&window.__codemirror["@codemirror/commands"];e.exports=r||n(47143)},23045:function(e,t,n){var r="undefined"!==typeof window&&window.__codemirror&&window.__codemirror["@codemirror/lang-javascript"];e.exports=r||n(42835)},55104:function(e,t,n){var r="undefined"!==typeof window&&window.__codemirror&&window.__codemirror["@codemirror/lang-json"];e.exports=r||n(94013)},26977:function(e,t,n){var r="undefined"!==typeof window&&window.__codemirror&&window.__codemirror["@codemirror/lang-yaml"];e.exports=r||n(18150)},61163:function(e,t,n){var r="undefined"!==typeof window&&window.__codemirror&&window.__codemirror["@codemirror/language"];e.exports=r||n(6871)},6516:function(e,t,n){var r="undefined"!==typeof window&&window.__codemirror&&window.__codemirror["@codemirror/lint"];e.exports=r||n(75982)},43865:function(e,t,n){var r="undefined"!==typeof window&&window.__codemirror&&window.__codemirror["@codemirror/search"];e.exports=r||n(59509)},76528:function(e,t,n){var r="undefined"!==typeof window&&window.__codemirror&&window.__codemirror["@codemirror/state"];e.exports=r||n(41735)},81068:function(e,t,n){var r="undefined"!==typeof window&&window.__codemirror&&window.__codemirror["@codemirror/view"];e.exports=r||n(71087)},43114:function(e,t,n){var r="undefined"!==typeof window&&window.__codemirror&&window.__codemirror["@lezer/common"];e.exports=r||n(79066)},88727:function(e,t,n){var r="undefined"!==typeof window&&window.__codemirror&&window.__codemirror["@lezer/highlight"];e.exports=r||n(7485)},59108:function(e,t,n){var r="undefined"!==typeof window&&window.__codemirror&&window.__codemirror["@replit/codemirror-vim"];e.exports=r||n(35348)},57784:function(e,t,n){"use strict";e.exports=n.p+"img/generic-plugin.f1ebdd74.svg"},53938:function(e,t,n){"use strict";e.exports=n.p+"img/harvester.0168283e.svg"},98283:function(e,t,n){"use strict";e.exports=n.p+"img/custom.6f45244d.svg"},41778:function(e,t,n){"use strict";e.exports=n.p+"img/email.b67ceff2.svg"},75495:function(e,t,n){"use strict";e.exports=n.p+"img/pagerduty.9871fbd3.svg"},69742:function(e,t,n){"use strict";e.exports=n.p+"img/slack.34dfd73f.svg"},94569:function(e,t,n){"use strict";e.exports=n.p+"img/webhook.f86c012b.svg"},49401:function(e,t,n){"use strict";e.exports=n.p+"img/suse-virtualization.a5ab2c15.svg"},96456:function(e,t,n){"use strict";e.exports=n.p+"img/suse-virtualization.997bbcc3.svg"},99086:function(e,t,n){"use strict";e.exports=n.p+"img/icon.42954c0f.svg"},20246:function(e){"use strict";e.exports=t},47008:function(e){"use strict";e.exports=n},9274:function(t){"use strict";t.exports=e},86973:function(){},62080:function(){},78314:function(){},14834:function(e,t,n){"use strict";var r=n(69501),i="undefined"===typeof globalThis?n.g:globalThis;e.exports=function(){for(var e=[],t=0;t<r.length;t++)"function"===typeof i[r[t]]&&(e[e.length]=r[t]);return e}},3973:function(e,t,n){var r=n(4364),i={exports:{}};function o(e){return e instanceof Map?e.clear=e.delete=e.set=function(){throw new Error("map is read-only")}:e instanceof Set&&(e.add=e.clear=e.delete=function(){throw new Error("set is read-only")}),Object.freeze(e),Object.getOwnPropertyNames(e).forEach(function(t){var n=e[t];"object"!=typeof n||Object.isFrozen(n)||o(n)}),e}i.exports=o,i.exports.default=o;class a{constructor(e){void 0===e.data&&(e.data={}),this.data=e.data,this.isMatchIgnored=!1}ignoreMatch(){this.isMatchIgnored=!0}}function s(e){return e.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")}function l(e,...t){const n=Object.create(null);for(const r in e)n[r]=e[r];return t.forEach(function(e){for(const t in e)n[t]=e[t]}),n}const c="</span>",u=e=>!!e.scope||e.sublanguage&&e.language,d=(e,{prefix:t})=>{if(e.includes(".")){const n=e.split(".");return[`${t}${n.shift()}`,...n.map((e,t)=>`${e}${"_".repeat(t+1)}`)].join(" ")}return`${t}${e}`};class h{constructor(e,t){this.buffer="",this.classPrefix=t.classPrefix,e.walk(this)}addText(e){this.buffer+=s(e)}openNode(e){if(!u(e))return;let t="";t=e.sublanguage?`language-${e.language}`:d(e.scope,{prefix:this.classPrefix}),this.span(t)}closeNode(e){u(e)&&(this.buffer+=c)}value(){return this.buffer}span(e){this.buffer+=`<span class="${e}">`}}const p=(e={})=>{const t={children:[]};return Object.assign(t,e),t};class f{constructor(){this.rootNode=p(),this.stack=[this.rootNode]}get top(){return this.stack[this.stack.length-1]}get root(){return this.rootNode}add(e){this.top.children.push(e)}openNode(e){const t=p({scope:e});this.add(t),this.stack.push(t)}closeNode(){if(this.stack.length>1)return this.stack.pop()}closeAllNodes(){while(this.closeNode());}toJSON(){return JSON.stringify(this.rootNode,null,4)}walk(e){return this.constructor._walk(e,this.rootNode)}static _walk(e,t){return"string"===typeof t?e.addText(t):t.children&&(e.openNode(t),t.children.forEach(t=>this._walk(e,t)),e.closeNode(t)),e}static _collapse(e){"string"!==typeof e&&e.children&&(e.children.every(e=>"string"===typeof e)?e.children=[e.children.join("")]:e.children.forEach(e=>{f._collapse(e)}))}}class m extends f{constructor(e){super(),this.options=e}addKeyword(e,t){""!==e&&(this.openNode(t),this.addText(e),this.closeNode())}addText(e){""!==e&&this.add(e)}addSublanguage(e,t){const n=e.root;n.sublanguage=!0,n.language=t,this.add(n)}toHTML(){const e=new h(this,this.options);return e.value()}finalize(){return!0}}function g(e){return e?"string"===typeof e?e:e.source:null}function v(e){return w("(?=",e,")")}function b(e){return w("(?:",e,")*")}function y(e){return w("(?:",e,")?")}function w(...e){const t=e.map(e=>g(e)).join("");return t}function O(e){const t=e[e.length-1];return"object"===typeof t&&t.constructor===Object?(e.splice(e.length-1,1),t):{}}function S(...e){const t=O(e),n="("+(t.capture?"":"?:")+e.map(e=>g(e)).join("|")+")";return n}function E(e){return new RegExp(e.toString()+"|").exec("").length-1}function x(e,t){const n=e&&e.exec(t);return n&&0===n.index}const _=/\[(?:[^\\\]]|\\.)*\]|\(\??|\\([1-9][0-9]*)|\\./;function k(e,{joinWith:t}){let n=0;return e.map(e=>{n+=1;const t=n;let r=g(e),i="";while(r.length>0){const e=_.exec(r);if(!e){i+=r;break}i+=r.substring(0,e.index),r=r.substring(e.index+e[0].length),"\\"===e[0][0]&&e[1]?i+="\\"+String(Number(e[1])+t):(i+=e[0],"("===e[0]&&n++)}return i}).map(e=>`(${e})`).join(t)}const C=/\b\B/,A="[a-zA-Z]\\w*",T="[a-zA-Z_]\\w*",R="\\b\\d+(\\.\\d+)?",N="(-?)(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)",P="\\b(0b[01]+)",I="!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~",M=(e={})=>{const t=/^#![ ]*\//;return e.binary&&(e.begin=w(t,/.*\b/,e.binary,/\b.*/)),l({scope:"meta",begin:t,end:/$/,relevance:0,"on:begin":(e,t)=>{0!==e.index&&t.ignoreMatch()}},e)},D={begin:"\\\\[\\s\\S]",relevance:0},L={scope:"string",begin:"'",end:"'",illegal:"\\n",contains:[D]},B={scope:"string",begin:'"',end:'"',illegal:"\\n",contains:[D]},$={begin:/\b(a|an|the|are|I'm|isn't|don't|doesn't|won't|but|just|should|pretty|simply|enough|gonna|going|wtf|so|such|will|you|your|they|like|more)\b/},V=function(e,t,n={}){const r=l({scope:"comment",begin:e,end:t,contains:[]},n);r.contains.push({scope:"doctag",begin:"[ ]*(?=(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):)",end:/(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):/,excludeBegin:!0,relevance:0});const i=S("I","a","is","so","us","to","at","if","in","it","on",/[A-Za-z]+['](d|ve|re|ll|t|s|n)/,/[A-Za-z]+[-][a-z]+/,/[A-Za-z][a-z]{2,}/);return r.contains.push({begin:w(/[ ]+/,"(",i,/[.]?[:]?([.][ ]|[ ])/,"){3}")}),r},F=V("//","$"),j=V("/\\*","\\*/"),U=V("#","$"),G={scope:"number",begin:R,relevance:0},H={scope:"number",begin:N,relevance:0},q={scope:"number",begin:P,relevance:0},Q={begin:/(?=\/[^/\n]*\/)/,contains:[{scope:"regexp",begin:/\//,end:/\/[gimuy]*/,illegal:/\n/,contains:[D,{begin:/\[/,end:/\]/,relevance:0,contains:[D]}]}]},z={scope:"title",begin:A,relevance:0},K={scope:"title",begin:T,relevance:0},W={begin:"\\.\\s*"+T,relevance:0},X=function(e){return Object.assign(e,{"on:begin":(e,t)=>{t.data._beginMatch=e[1]},"on:end":(e,t)=>{t.data._beginMatch!==e[1]&&t.ignoreMatch()}})};var Y=Object.freeze({__proto__:null,MATCH_NOTHING_RE:C,IDENT_RE:A,UNDERSCORE_IDENT_RE:T,NUMBER_RE:R,C_NUMBER_RE:N,BINARY_NUMBER_RE:P,RE_STARTERS_RE:I,SHEBANG:M,BACKSLASH_ESCAPE:D,APOS_STRING_MODE:L,QUOTE_STRING_MODE:B,PHRASAL_WORDS_MODE:$,COMMENT:V,C_LINE_COMMENT_MODE:F,C_BLOCK_COMMENT_MODE:j,HASH_COMMENT_MODE:U,NUMBER_MODE:G,C_NUMBER_MODE:H,BINARY_NUMBER_MODE:q,REGEXP_MODE:Q,TITLE_MODE:z,UNDERSCORE_TITLE_MODE:K,METHOD_GUARD:W,END_SAME_AS_BEGIN:X});function Z(e,t){const n=e.input[e.index-1];"."===n&&t.ignoreMatch()}function J(e,t){void 0!==e.className&&(e.scope=e.className,delete e.className)}function ee(e,t){t&&e.beginKeywords&&(e.begin="\\b("+e.beginKeywords.split(" ").join("|")+")(?!\\.)(?=\\b|\\s)",e.__beforeBegin=Z,e.keywords=e.keywords||e.beginKeywords,delete e.beginKeywords,void 0===e.relevance&&(e.relevance=0))}function te(e,t){Array.isArray(e.illegal)&&(e.illegal=S(...e.illegal))}function ne(e,t){if(e.match){if(e.begin||e.end)throw new Error("begin & end are not supported with match");e.begin=e.match,delete e.match}}function re(e,t){void 0===e.relevance&&(e.relevance=1)}const ie=(e,t)=>{if(!e.beforeMatch)return;if(e.starts)throw new Error("beforeMatch cannot be used with starts");const n=Object.assign({},e);Object.keys(e).forEach(t=>{delete e[t]}),e.keywords=n.keywords,e.begin=w(n.beforeMatch,v(n.begin)),e.starts={relevance:0,contains:[Object.assign(n,{endsParent:!0})]},e.relevance=0,delete n.beforeMatch},oe=["of","and","for","in","not","or","if","then","parent","list","value"],ae="keyword";function se(e,t,n=ae){const r=Object.create(null);return"string"===typeof e?i(n,e.split(" ")):Array.isArray(e)?i(n,e):Object.keys(e).forEach(function(n){Object.assign(r,se(e[n],t,n))}),r;function i(e,n){t&&(n=n.map(e=>e.toLowerCase())),n.forEach(function(t){const n=t.split("|");r[n[0]]=[e,le(n[0],n[1])]})}}function le(e,t){return t?Number(t):ce(e)?0:1}function ce(e){return oe.includes(e.toLowerCase())}const ue={},de=e=>{r.error(e)},he=(e,...t)=>{r.log(`WARN: ${e}`,...t)},pe=(e,t)=>{ue[`${e}/${t}`]||(r.log(`Deprecated as of ${e}. ${t}`),ue[`${e}/${t}`]=!0)},fe=new Error;function me(e,t,{key:n}){let r=0;const i=e[n],o={},a={};for(let s=1;s<=t.length;s++)a[s+r]=i[s],o[s+r]=!0,r+=E(t[s-1]);e[n]=a,e[n]._emit=o,e[n]._multi=!0}function ge(e){if(Array.isArray(e.begin)){if(e.skip||e.excludeBegin||e.returnBegin)throw de("skip, excludeBegin, returnBegin not compatible with beginScope: {}"),fe;if("object"!==typeof e.beginScope||null===e.beginScope)throw de("beginScope must be object"),fe;me(e,e.begin,{key:"beginScope"}),e.begin=k(e.begin,{joinWith:""})}}function ve(e){if(Array.isArray(e.end)){if(e.skip||e.excludeEnd||e.returnEnd)throw de("skip, excludeEnd, returnEnd not compatible with endScope: {}"),fe;if("object"!==typeof e.endScope||null===e.endScope)throw de("endScope must be object"),fe;me(e,e.end,{key:"endScope"}),e.end=k(e.end,{joinWith:""})}}function be(e){e.scope&&"object"===typeof e.scope&&null!==e.scope&&(e.beginScope=e.scope,delete e.scope)}function ye(e){be(e),"string"===typeof e.beginScope&&(e.beginScope={_wrap:e.beginScope}),"string"===typeof e.endScope&&(e.endScope={_wrap:e.endScope}),ge(e),ve(e)}function we(e){function t(t,n){return new RegExp(g(t),"m"+(e.case_insensitive?"i":"")+(e.unicodeRegex?"u":"")+(n?"g":""))}class n{constructor(){this.matchIndexes={},this.regexes=[],this.matchAt=1,this.position=0}addRule(e,t){t.position=this.position++,this.matchIndexes[this.matchAt]=t,this.regexes.push([t,e]),this.matchAt+=E(e)+1}compile(){0===this.regexes.length&&(this.exec=()=>null);const e=this.regexes.map(e=>e[1]);this.matcherRe=t(k(e,{joinWith:"|"}),!0),this.lastIndex=0}exec(e){this.matcherRe.lastIndex=this.lastIndex;const t=this.matcherRe.exec(e);if(!t)return null;const n=t.findIndex((e,t)=>t>0&&void 0!==e),r=this.matchIndexes[n];return t.splice(0,n),Object.assign(t,r)}}class r{constructor(){this.rules=[],this.multiRegexes=[],this.count=0,this.lastIndex=0,this.regexIndex=0}getMatcher(e){if(this.multiRegexes[e])return this.multiRegexes[e];const t=new n;return this.rules.slice(e).forEach(([e,n])=>t.addRule(e,n)),t.compile(),this.multiRegexes[e]=t,t}resumingScanAtSamePosition(){return 0!==this.regexIndex}considerAll(){this.regexIndex=0}addRule(e,t){this.rules.push([e,t]),"begin"===t.type&&this.count++}exec(e){const t=this.getMatcher(this.regexIndex);t.lastIndex=this.lastIndex;let n=t.exec(e);if(this.resumingScanAtSamePosition())if(n&&n.index===this.lastIndex);else{const t=this.getMatcher(0);t.lastIndex=this.lastIndex+1,n=t.exec(e)}return n&&(this.regexIndex+=n.position+1,this.regexIndex===this.count&&this.considerAll()),n}}function i(e){const t=new r;return e.contains.forEach(e=>t.addRule(e.begin,{rule:e,type:"begin"})),e.terminatorEnd&&t.addRule(e.terminatorEnd,{type:"end"}),e.illegal&&t.addRule(e.illegal,{type:"illegal"}),t}function o(n,r){const a=n;if(n.isCompiled)return a;[J,ne,ye,ie].forEach(e=>e(n,r)),e.compilerExtensions.forEach(e=>e(n,r)),n.__beforeBegin=null,[ee,te,re].forEach(e=>e(n,r)),n.isCompiled=!0;let s=null;return"object"===typeof n.keywords&&n.keywords.$pattern&&(n.keywords=Object.assign({},n.keywords),s=n.keywords.$pattern,delete n.keywords.$pattern),s=s||/\w+/,n.keywords&&(n.keywords=se(n.keywords,e.case_insensitive)),a.keywordPatternRe=t(s,!0),r&&(n.begin||(n.begin=/\B|\b/),a.beginRe=t(a.begin),n.end||n.endsWithParent||(n.end=/\B|\b/),n.end&&(a.endRe=t(a.end)),a.terminatorEnd=g(a.end)||"",n.endsWithParent&&r.terminatorEnd&&(a.terminatorEnd+=(n.end?"|":"")+r.terminatorEnd)),n.illegal&&(a.illegalRe=t(n.illegal)),n.contains||(n.contains=[]),n.contains=[].concat(...n.contains.map(function(e){return Se("self"===e?n:e)})),n.contains.forEach(function(e){o(e,a)}),n.starts&&o(n.starts,r),a.matcher=i(a),a}if(e.compilerExtensions||(e.compilerExtensions=[]),e.contains&&e.contains.includes("self"))throw new Error("ERR: contains `self` is not supported at the top-level of a language. See documentation.");return e.classNameAliases=l(e.classNameAliases||{}),o(e)}function Oe(e){return!!e&&(e.endsWithParent||Oe(e.starts))}function Se(e){return e.variants&&!e.cachedVariants&&(e.cachedVariants=e.variants.map(function(t){return l(e,{variants:null},t)})),e.cachedVariants?e.cachedVariants:Oe(e)?l(e,{starts:e.starts?l(e.starts):null}):Object.isFrozen(e)?l(e):e}var Ee="11.6.0";class xe extends Error{constructor(e,t){super(e),this.name="HTMLInjectionError",this.html=t}}const _e=s,ke=l,Ce=Symbol("nomatch"),Ae=7,Te=function(e){const t=Object.create(null),n=Object.create(null),o=[];let s=!0;const l="Could not find the language '{}', did you forget to load/include a language module?",c={disableAutodetect:!0,name:"Plain text",contains:[]};let u={ignoreUnescapedHTML:!1,throwUnescapedHTML:!1,noHighlightRe:/^(no-?highlight)$/i,languageDetectRe:/\blang(?:uage)?-([\w-]+)\b/i,classPrefix:"hljs-",cssSelector:"pre code",languages:null,__emitter:m};function d(e){return u.noHighlightRe.test(e)}function h(e){let t=e.className+" ";t+=e.parentNode?e.parentNode.className:"";const n=u.languageDetectRe.exec(t);if(n){const t=D(n[1]);return t||(he(l.replace("{}",n[1])),he("Falling back to no-highlight mode for this block.",e)),t?n[1]:"no-highlight"}return t.split(/\s+/).find(e=>d(e)||D(e))}function p(e,t,n){let r="",i="";"object"===typeof t?(r=e,n=t.ignoreIllegals,i=t.language):(pe("10.7.0","highlight(lang, code, ...args) has been deprecated."),pe("10.7.0","Please use highlight(code, options) instead.\nhttps://github.com/highlightjs/highlight.js/issues/2277"),i=e,r=t),void 0===n&&(n=!0);const o={code:r,language:i};F("before:highlight",o);const a=o.result?o.result:f(o.language,o.code,n);return a.code=o.code,F("after:highlight",a),a}function f(e,n,r,i){const o=Object.create(null);function c(e,t){return e.keywords[t]}function d(){if(!T.keywords)return void N.addText(P);let e=0;T.keywordPatternRe.lastIndex=0;let t=T.keywordPatternRe.exec(P),n="";while(t){n+=P.substring(e,t.index);const r=k.case_insensitive?t[0].toLowerCase():t[0],i=c(T,r);if(i){const[e,a]=i;if(N.addText(n),n="",o[r]=(o[r]||0)+1,o[r]<=Ae&&(I+=a),e.startsWith("_"))n+=t[0];else{const n=k.classNameAliases[e]||e;N.addKeyword(t[0],n)}}else n+=t[0];e=T.keywordPatternRe.lastIndex,t=T.keywordPatternRe.exec(P)}n+=P.substring(e),N.addText(n)}function h(){if(""===P)return;let e=null;if("string"===typeof T.subLanguage){if(!t[T.subLanguage])return void N.addText(P);e=f(T.subLanguage,P,!0,R[T.subLanguage]),R[T.subLanguage]=e._top}else e=O(P,T.subLanguage.length?T.subLanguage:null);T.relevance>0&&(I+=e.relevance),N.addSublanguage(e._emitter,e.language)}function p(){null!=T.subLanguage?h():d(),P=""}function m(e,t){let n=1;const r=t.length-1;while(n<=r){if(!e._emit[n]){n++;continue}const r=k.classNameAliases[e[n]]||e[n],i=t[n];r?N.addKeyword(i,r):(P=i,d(),P=""),n++}}function g(e,t){return e.scope&&"string"===typeof e.scope&&N.openNode(k.classNameAliases[e.scope]||e.scope),e.beginScope&&(e.beginScope._wrap?(N.addKeyword(P,k.classNameAliases[e.beginScope._wrap]||e.beginScope._wrap),P=""):e.beginScope._multi&&(m(e.beginScope,t),P="")),T=Object.create(e,{parent:{value:T}}),T}function v(e,t,n){let r=x(e.endRe,n);if(r){if(e["on:end"]){const n=new a(e);e["on:end"](t,n),n.isMatchIgnored&&(r=!1)}if(r){while(e.endsParent&&e.parent)e=e.parent;return e}}if(e.endsWithParent)return v(e.parent,t,n)}function b(e){return 0===T.matcher.regexIndex?(P+=e[0],1):(B=!0,0)}function y(e){const t=e[0],n=e.rule,r=new a(n),i=[n.__beforeBegin,n["on:begin"]];for(const o of i)if(o&&(o(e,r),r.isMatchIgnored))return b(t);return n.skip?P+=t:(n.excludeBegin&&(P+=t),p(),n.returnBegin||n.excludeBegin||(P=t)),g(n,e),n.returnBegin?0:t.length}function w(e){const t=e[0],r=n.substring(e.index),i=v(T,e,r);if(!i)return Ce;const o=T;T.endScope&&T.endScope._wrap?(p(),N.addKeyword(t,T.endScope._wrap)):T.endScope&&T.endScope._multi?(p(),m(T.endScope,e)):o.skip?P+=t:(o.returnEnd||o.excludeEnd||(P+=t),p(),o.excludeEnd&&(P=t));do{T.scope&&N.closeNode(),T.skip||T.subLanguage||(I+=T.relevance),T=T.parent}while(T!==i.parent);return i.starts&&g(i.starts,e),o.returnEnd?0:t.length}function S(){const e=[];for(let t=T;t!==k;t=t.parent)t.scope&&e.unshift(t.scope);e.forEach(e=>N.openNode(e))}let E={};function _(t,i){const o=i&&i[0];if(P+=t,null==o)return p(),0;if("begin"===E.type&&"end"===i.type&&E.index===i.index&&""===o){if(P+=n.slice(i.index,i.index+1),!s){const t=new Error(`0 width match regex (${e})`);throw t.languageName=e,t.badRule=E.rule,t}return 1}if(E=i,"begin"===i.type)return y(i);if("illegal"===i.type&&!r){const e=new Error('Illegal lexeme "'+o+'" for mode "'+(T.scope||"<unnamed>")+'"');throw e.mode=T,e}if("end"===i.type){const e=w(i);if(e!==Ce)return e}if("illegal"===i.type&&""===o)return 1;if(L>1e5&&L>3*i.index){const e=new Error("potential infinite loop, way more iterations than matches");throw e}return P+=o,o.length}const k=D(e);if(!k)throw de(l.replace("{}",e)),new Error('Unknown language: "'+e+'"');const C=we(k);let A="",T=i||C;const R={},N=new u.__emitter(u);S();let P="",I=0,M=0,L=0,B=!1;try{for(T.matcher.considerAll();;){L++,B?B=!1:T.matcher.considerAll(),T.matcher.lastIndex=M;const e=T.matcher.exec(n);if(!e)break;const t=n.substring(M,e.index),r=_(t,e);M=e.index+r}return _(n.substring(M)),N.closeAllNodes(),N.finalize(),A=N.toHTML(),{language:e,value:A,relevance:I,illegal:!1,_emitter:N,_top:T}}catch($){if($.message&&$.message.includes("Illegal"))return{language:e,value:_e(n),illegal:!0,relevance:0,_illegalBy:{message:$.message,index:M,context:n.slice(M-100,M+100),mode:$.mode,resultSoFar:A},_emitter:N};if(s)return{language:e,value:_e(n),illegal:!1,relevance:0,errorRaised:$,_emitter:N,_top:T};throw $}}function g(e){const t={value:_e(e),illegal:!1,relevance:0,_top:c,_emitter:new u.__emitter(u)};return t._emitter.addText(e),t}function O(e,n){n=n||u.languages||Object.keys(t);const r=g(e),i=n.filter(D).filter(B).map(t=>f(t,e,!1));i.unshift(r);const o=i.sort((e,t)=>{if(e.relevance!==t.relevance)return t.relevance-e.relevance;if(e.language&&t.language){if(D(e.language).supersetOf===t.language)return 1;if(D(t.language).supersetOf===e.language)return-1}return 0}),[a,s]=o,l=a;return l.secondBest=s,l}function E(e,t,r){const i=t&&n[t]||r;e.classList.add("hljs"),e.classList.add(`language-${i}`)}function _(e){let t=null;const n=h(e);if(d(n))return;if(F("before:highlightElement",{el:e,language:n}),e.children.length>0&&(u.ignoreUnescapedHTML||(r.warn("One of your code blocks includes unescaped HTML. This is a potentially serious security risk."),r.warn("https://github.com/highlightjs/highlight.js/wiki/security"),r.warn("The element with unescaped HTML:"),r.warn(e)),u.throwUnescapedHTML)){const t=new xe("One of your code blocks includes unescaped HTML.",e.innerHTML);throw t}t=e;const i=t.textContent,o=n?p(i,{language:n,ignoreIllegals:!0}):O(i);e.innerHTML=o.value,E(e,n,o.language),e.result={language:o.language,re:o.relevance,relevance:o.relevance},o.secondBest&&(e.secondBest={language:o.secondBest.language,relevance:o.secondBest.relevance}),F("after:highlightElement",{el:e,result:o,text:i})}function k(e){u=ke(u,e)}const C=()=>{R(),pe("10.6.0","initHighlighting() deprecated. Use highlightAll() now.")};function A(){R(),pe("10.6.0","initHighlightingOnLoad() deprecated. Use highlightAll() now.")}let T=!1;function R(){if("loading"===document.readyState)return void(T=!0);const e=document.querySelectorAll(u.cssSelector);e.forEach(_)}function N(){T&&R()}function P(n,r){let i=null;try{i=r(e)}catch(o){if(de("Language definition for '{}' could not be registered.".replace("{}",n)),!s)throw o;de(o),i=c}i.name||(i.name=n),t[n]=i,i.rawDefinition=r.bind(null,e),i.aliases&&L(i.aliases,{languageName:n})}function I(e){delete t[e];for(const t of Object.keys(n))n[t]===e&&delete n[t]}function M(){return Object.keys(t)}function D(e){return e=(e||"").toLowerCase(),t[e]||t[n[e]]}function L(e,{languageName:t}){"string"===typeof e&&(e=[e]),e.forEach(e=>{n[e.toLowerCase()]=t})}function B(e){const t=D(e);return t&&!t.disableAutodetect}function $(e){e["before:highlightBlock"]&&!e["before:highlightElement"]&&(e["before:highlightElement"]=t=>{e["before:highlightBlock"](Object.assign({block:t.el},t))}),e["after:highlightBlock"]&&!e["after:highlightElement"]&&(e["after:highlightElement"]=t=>{e["after:highlightBlock"](Object.assign({block:t.el},t))})}function V(e){$(e),o.push(e)}function F(e,t){const n=e;o.forEach(function(e){e[n]&&e[n](t)})}function j(e){return pe("10.7.0","highlightBlock will be removed entirely in v12.0"),pe("10.7.0","Please use highlightElement now."),_(e)}"undefined"!==typeof window&&window.addEventListener&&window.addEventListener("DOMContentLoaded",N,!1),Object.assign(e,{highlight:p,highlightAuto:O,highlightAll:R,highlightElement:_,highlightBlock:j,configure:k,initHighlighting:C,initHighlightingOnLoad:A,registerLanguage:P,unregisterLanguage:I,listLanguages:M,getLanguage:D,registerAliases:L,autoDetection:B,inherit:ke,addPlugin:V}),e.debugMode=function(){s=!1},e.safeMode=function(){s=!0},e.versionString=Ee,e.regex={concat:w,lookahead:v,either:S,optional:y,anyNumberOfTimes:b};for(const r in Y)"object"===typeof Y[r]&&i.exports(Y[r]);return Object.assign(e,Y),e};var Re=Te({});e.exports=Re,Re.HighlightJS=Re,Re.default=Re},69205:function(e){function t(e){const t={className:"variable",variants:[{begin:/\$[\w\d#@][\w\d_]*/},{begin:/\$\{(.*?)\}/}]},n="BEGIN END if else while do for in break continue delete next nextfile function func exit|10",r={className:"string",contains:[e.BACKSLASH_ESCAPE],variants:[{begin:/(u|b)?r?'''/,end:/'''/,relevance:10},{begin:/(u|b)?r?"""/,end:/"""/,relevance:10},{begin:/(u|r|ur)'/,end:/'/,relevance:10},{begin:/(u|r|ur)"/,end:/"/,relevance:10},{begin:/(b|br)'/,end:/'/},{begin:/(b|br)"/,end:/"/},e.APOS_STRING_MODE,e.QUOTE_STRING_MODE]};return{name:"Awk",keywords:{keyword:n},contains:[t,r,e.REGEXP_MODE,e.HASH_COMMENT_MODE,e.NUMBER_MODE]}}e.exports=t},46760:function(e){function t(e){const t=e.regex,n={},r={begin:/\$\{/,end:/\}/,contains:["self",{begin:/:-/,contains:[n]}]};Object.assign(n,{className:"variable",variants:[{begin:t.concat(/\$[\w\d#@][\w\d_]*/,"(?![\\w\\d])(?![$])")},r]});const i={className:"subst",begin:/\$\(/,end:/\)/,contains:[e.BACKSLASH_ESCAPE]},o={begin:/<<-?\s*(?=\w+)/,starts:{contains:[e.END_SAME_AS_BEGIN({begin:/(\w+)/,end:/(\w+)/,className:"string"})]}},a={className:"string",begin:/"/,end:/"/,contains:[e.BACKSLASH_ESCAPE,n,i]};i.contains.push(a);const s={className:"",begin:/\\"/},l={className:"string",begin:/'/,end:/'/},c={begin:/\$\(\(/,end:/\)\)/,contains:[{begin:/\d+#[0-9a-f]+/,className:"number"},e.NUMBER_MODE,n]},u=["fish","bash","zsh","sh","csh","ksh","tcsh","dash","scsh"],d=e.SHEBANG({binary:`(${u.join("|")})`,relevance:10}),h={className:"function",begin:/\w[\w\d_]*\s*\(\s*\)\s*\{/,returnBegin:!0,contains:[e.inherit(e.TITLE_MODE,{begin:/\w[\w\d_]*/})],relevance:0},p=["if","then","else","elif","fi","for","while","in","do","done","case","esac","function"],f=["true","false"],m={match:/(\/[a-z._-]+)+/},g=["break","cd","continue","eval","exec","exit","export","getopts","hash","pwd","readonly","return","shift","test","times","trap","umask","unset"],v=["alias","bind","builtin","caller","command","declare","echo","enable","help","let","local","logout","mapfile","printf","read","readarray","source","type","typeset","ulimit","unalias"],b=["autoload","bg","bindkey","bye","cap","chdir","clone","comparguments","compcall","compctl","compdescribe","compfiles","compgroups","compquote","comptags","comptry","compvalues","dirs","disable","disown","echotc","echoti","emulate","fc","fg","float","functions","getcap","getln","history","integer","jobs","kill","limit","log","noglob","popd","print","pushd","pushln","rehash","sched","setcap","setopt","stat","suspend","ttyctl","unfunction","unhash","unlimit","unsetopt","vared","wait","whence","where","which","zcompile","zformat","zftp","zle","zmodload","zparseopts","zprof","zpty","zregexparse","zsocket","zstyle","ztcp"],y=["chcon","chgrp","chown","chmod","cp","dd","df","dir","dircolors","ln","ls","mkdir","mkfifo","mknod","mktemp","mv","realpath","rm","rmdir","shred","sync","touch","truncate","vdir","b2sum","base32","base64","cat","cksum","comm","csplit","cut","expand","fmt","fold","head","join","md5sum","nl","numfmt","od","paste","ptx","pr","sha1sum","sha224sum","sha256sum","sha384sum","sha512sum","shuf","sort","split","sum","tac","tail","tr","tsort","unexpand","uniq","wc","arch","basename","chroot","date","dirname","du","echo","env","expr","factor","groups","hostid","id","link","logname","nice","nohup","nproc","pathchk","pinky","printenv","printf","pwd","readlink","runcon","seq","sleep","stat","stdbuf","stty","tee","test","timeout","tty","uname","unlink","uptime","users","who","whoami","yes"];return{name:"Bash",aliases:["sh"],keywords:{$pattern:/\b[a-z][a-z0-9._-]+\b/,keyword:p,literal:f,built_in:[...g,...v,"set","shopt",...b,...y]},contains:[d,e.SHEBANG(),h,c,e.HASH_COMMENT_MODE,o,m,a,s,l,n]}}e.exports=t},33089:function(e){function t(e){const t=e.regex,n=e.COMMENT("//","$",{contains:[{begin:/\\\n/}]}),r="decltype\\(auto\\)",i="[a-zA-Z_]\\w*::",o="<[^<>]+>",a="("+r+"|"+t.optional(i)+"[a-zA-Z_]\\w*"+t.optional(o)+")",s={className:"type",variants:[{begin:"\\b[a-z\\d_]*_t\\b"},{match:/\batomic_[a-z]{3,6}\b/}]},l="\\\\(x[0-9A-Fa-f]{2}|u[0-9A-Fa-f]{4,8}|[0-7]{3}|\\S)",c={className:"string",variants:[{begin:'(u8?|U|L)?"',end:'"',illegal:"\\n",contains:[e.BACKSLASH_ESCAPE]},{begin:"(u8?|U|L)?'("+l+"|.)",end:"'",illegal:"."},e.END_SAME_AS_BEGIN({begin:/(?:u8?|U|L)?R"([^()\\ ]{0,16})\(/,end:/\)([^()\\ ]{0,16})"/})]},u={className:"number",variants:[{begin:"\\b(0b[01']+)"},{begin:"(-?)\\b([\\d']+(\\.[\\d']*)?|\\.[\\d']+)((ll|LL|l|L)(u|U)?|(u|U)(ll|LL|l|L)?|f|F|b|B)"},{begin:"(-?)(\\b0[xX][a-fA-F0-9']+|(\\b[\\d']+(\\.[\\d']*)?|\\.[\\d']+)([eE][-+]?[\\d']+)?)"}],relevance:0},d={className:"meta",begin:/#\s*[a-z]+\b/,end:/$/,keywords:{keyword:"if else elif endif define undef warning error line pragma _Pragma ifdef ifndef include"},contains:[{begin:/\\\n/,relevance:0},e.inherit(c,{className:"string"}),{className:"string",begin:/<.*?>/},n,e.C_BLOCK_COMMENT_MODE]},h={className:"title",begin:t.optional(i)+e.IDENT_RE,relevance:0},p=t.optional(i)+e.IDENT_RE+"\\s*\\(",f=["asm","auto","break","case","continue","default","do","else","enum","extern","for","fortran","goto","if","inline","register","restrict","return","sizeof","struct","switch","typedef","union","volatile","while","_Alignas","_Alignof","_Atomic","_Generic","_Noreturn","_Static_assert","_Thread_local","alignas","alignof","noreturn","static_assert","thread_local","_Pragma"],m=["float","double","signed","unsigned","int","short","long","char","void","_Bool","_Complex","_Imaginary","_Decimal32","_Decimal64","_Decimal128","const","static","complex","bool","imaginary"],g={keyword:f,type:m,literal:"true false NULL",built_in:"std string wstring cin cout cerr clog stdin stdout stderr stringstream istringstream ostringstream auto_ptr deque list queue stack vector map set pair bitset multiset multimap unordered_set unordered_map unordered_multiset unordered_multimap priority_queue make_pair array shared_ptr abort terminate abs acos asin atan2 atan calloc ceil cosh cos exit exp fabs floor fmod fprintf fputs free frexp fscanf future isalnum isalpha iscntrl isdigit isgraph islower isprint ispunct isspace isupper isxdigit tolower toupper labs ldexp log10 log malloc realloc memchr memcmp memcpy memset modf pow printf putchar puts scanf sinh sin snprintf sprintf sqrt sscanf strcat strchr strcmp strcpy strcspn strlen strncat strncmp strncpy strpbrk strrchr strspn strstr tanh tan vfprintf vprintf vsprintf endl initializer_list unique_ptr"},v=[d,s,n,e.C_BLOCK_COMMENT_MODE,u,c],b={variants:[{begin:/=/,end:/;/},{begin:/\(/,end:/\)/},{beginKeywords:"new throw return else",end:/;/}],keywords:g,contains:v.concat([{begin:/\(/,end:/\)/,keywords:g,contains:v.concat(["self"]),relevance:0}]),relevance:0},y={begin:"("+a+"[\\*&\\s]+)+"+p,returnBegin:!0,end:/[{;=]/,excludeEnd:!0,keywords:g,illegal:/[^\w\s\*&:<>.]/,contains:[{begin:r,keywords:g,relevance:0},{begin:p,returnBegin:!0,contains:[e.inherit(h,{className:"title.function"})],relevance:0},{relevance:0,match:/,/},{className:"params",begin:/\(/,end:/\)/,keywords:g,relevance:0,contains:[n,e.C_BLOCK_COMMENT_MODE,c,u,s,{begin:/\(/,end:/\)/,keywords:g,relevance:0,contains:["self",n,e.C_BLOCK_COMMENT_MODE,c,u,s]}]},s,n,e.C_BLOCK_COMMENT_MODE,d]};return{name:"C",aliases:["h"],keywords:g,disableAutodetect:!0,illegal:"</",contains:[].concat(b,y,v,[d,{begin:e.IDENT_RE+"::",keywords:g},{className:"class",beginKeywords:"enum class struct union",end:/[{;:<>=]/,contains:[{beginKeywords:"final class struct"},e.TITLE_MODE]}]),exports:{preprocessor:d,strings:c,keywords:g}}}e.exports=t},37620:function(e){function t(e){const t="a-zA-Z_\\-!.?+*=<>&'",n="[#]?["+t+"]["+t+"0-9/;:$#]*",r="def defonce defprotocol defstruct defmulti defmethod defn- defn defmacro deftype defrecord",i={$pattern:n,built_in:r+" cond apply if-not if-let if not not= =|0 <|0 >|0 <=|0 >=|0 ==|0 +|0 /|0 *|0 -|0 rem quot neg? pos? delay? symbol? keyword? true? false? integer? empty? coll? list? set? ifn? fn? associative? sequential? sorted? counted? reversible? number? decimal? class? distinct? isa? float? rational? reduced? ratio? odd? even? char? seq? vector? string? map? nil? contains? zero? instance? not-every? not-any? libspec? -> ->> .. . inc compare do dotimes mapcat take remove take-while drop letfn drop-last take-last drop-while while intern condp case reduced cycle split-at split-with repeat replicate iterate range merge zipmap declare line-seq sort comparator sort-by dorun doall nthnext nthrest partition eval doseq await await-for let agent atom send send-off release-pending-sends add-watch mapv filterv remove-watch agent-error restart-agent set-error-handler error-handler set-error-mode! error-mode shutdown-agents quote var fn loop recur throw try monitor-enter monitor-exit macroexpand macroexpand-1 for dosync and or when when-not when-let comp juxt partial sequence memoize constantly complement identity assert peek pop doto proxy first rest cons cast coll last butlast sigs reify second ffirst fnext nfirst nnext meta with-meta ns in-ns create-ns import refer keys select-keys vals key val rseq name namespace promise into transient persistent! conj! assoc! dissoc! pop! disj! use class type num float double short byte boolean bigint biginteger bigdec print-method print-dup throw-if printf format load compile get-in update-in pr pr-on newline flush read slurp read-line subvec with-open memfn time re-find re-groups rand-int rand mod locking assert-valid-fdecl alias resolve ref deref refset swap! reset! set-validator! compare-and-set! alter-meta! reset-meta! commute get-validator alter ref-set ref-history-count ref-min-history ref-max-history ensure sync io! new next conj set! to-array future future-call into-array aset gen-class reduce map filter find empty hash-map hash-set sorted-map sorted-map-by sorted-set sorted-set-by vec vector seq flatten reverse assoc dissoc list disj get union difference intersection extend extend-type extend-protocol int nth delay count concat chunk chunk-buffer chunk-append chunk-first chunk-rest max min dec unchecked-inc-int unchecked-inc unchecked-dec-inc unchecked-dec unchecked-negate unchecked-add-int unchecked-add unchecked-subtract-int unchecked-subtract chunk-next chunk-cons chunked-seq? prn vary-meta lazy-seq spread list* str find-keyword keyword symbol gensym force rationalize"},o={begin:n,relevance:0},a={scope:"number",relevance:0,variants:[{match:/[-+]?0[xX][0-9a-fA-F]+N?/},{match:/[-+]?0[0-7]+N?/},{match:/[-+]?[1-9][0-9]?[rR][0-9a-zA-Z]+N?/},{match:/[-+]?[0-9]+\/[0-9]+N?/},{match:/[-+]?[0-9]+((\.[0-9]*([eE][+-]?[0-9]+)?M?)|([eE][+-]?[0-9]+M?|M))/},{match:/[-+]?([1-9][0-9]*|0)N?/}]},s={scope:"character",variants:[{match:/\\o[0-3]?[0-7]{1,2}/},{match:/\\u[0-9a-fA-F]{4}/},{match:/\\(newline|space|tab|formfeed|backspace|return)/},{match:/\\\S/,relevance:0}]},l={scope:"regex",begin:/#"/,end:/"/,contains:[e.BACKSLASH_ESCAPE]},c=e.inherit(e.QUOTE_STRING_MODE,{illegal:null}),u={scope:"punctuation",match:/,/,relevance:0},d=e.COMMENT(";","$",{relevance:0}),h={className:"literal",begin:/\b(true|false|nil)\b/},p={begin:"\\[|(#::?"+n+")?\\{",end:"[\\]\\}]",relevance:0},f={className:"symbol",begin:"[:]{1,2}"+n},m={begin:"\\(",end:"\\)"},g={endsWithParent:!0,relevance:0},v={keywords:i,className:"name",begin:n,relevance:0,starts:g},b=[u,m,s,l,c,d,f,p,a,h,o],y={beginKeywords:r,keywords:{$pattern:n,keyword:r},end:'(\\[|#|\\d|"|:|\\{|\\)|\\(|$)',contains:[{className:"title",begin:n,relevance:0,excludeEnd:!0,endsParent:!0}].concat(b)};return m.contains=[y,v,g],g.contains=b,p.contains=b,{name:"Clojure",aliases:["clj","edn"],illegal:/\S/,contains:[u,m,s,l,c,d,f,p,a,h]}}e.exports=t},68049:function(e){function t(e){const t=e.regex,n=e.COMMENT("//","$",{contains:[{begin:/\\\n/}]}),r="decltype\\(auto\\)",i="[a-zA-Z_]\\w*::",o="<[^<>]+>",a="(?!struct)("+r+"|"+t.optional(i)+"[a-zA-Z_]\\w*"+t.optional(o)+")",s={className:"type",begin:"\\b[a-z\\d_]*_t\\b"},l="\\\\(x[0-9A-Fa-f]{2}|u[0-9A-Fa-f]{4,8}|[0-7]{3}|\\S)",c={className:"string",variants:[{begin:'(u8?|U|L)?"',end:'"',illegal:"\\n",contains:[e.BACKSLASH_ESCAPE]},{begin:"(u8?|U|L)?'("+l+"|.)",end:"'",illegal:"."},e.END_SAME_AS_BEGIN({begin:/(?:u8?|U|L)?R"([^()\\ ]{0,16})\(/,end:/\)([^()\\ ]{0,16})"/})]},u={className:"number",variants:[{begin:"\\b(0b[01']+)"},{begin:"(-?)\\b([\\d']+(\\.[\\d']*)?|\\.[\\d']+)((ll|LL|l|L)(u|U)?|(u|U)(ll|LL|l|L)?|f|F|b|B)"},{begin:"(-?)(\\b0[xX][a-fA-F0-9']+|(\\b[\\d']+(\\.[\\d']*)?|\\.[\\d']+)([eE][-+]?[\\d']+)?)"}],relevance:0},d={className:"meta",begin:/#\s*[a-z]+\b/,end:/$/,keywords:{keyword:"if else elif endif define undef warning error line pragma _Pragma ifdef ifndef include"},contains:[{begin:/\\\n/,relevance:0},e.inherit(c,{className:"string"}),{className:"string",begin:/<.*?>/},n,e.C_BLOCK_COMMENT_MODE]},h={className:"title",begin:t.optional(i)+e.IDENT_RE,relevance:0},p=t.optional(i)+e.IDENT_RE+"\\s*\\(",f=["alignas","alignof","and","and_eq","asm","atomic_cancel","atomic_commit","atomic_noexcept","auto","bitand","bitor","break","case","catch","class","co_await","co_return","co_yield","compl","concept","const_cast|10","consteval","constexpr","constinit","continue","decltype","default","delete","do","dynamic_cast|10","else","enum","explicit","export","extern","false","final","for","friend","goto","if","import","inline","module","mutable","namespace","new","noexcept","not","not_eq","nullptr","operator","or","or_eq","override","private","protected","public","reflexpr","register","reinterpret_cast|10","requires","return","sizeof","static_assert","static_cast|10","struct","switch","synchronized","template","this","thread_local","throw","transaction_safe","transaction_safe_dynamic","true","try","typedef","typeid","typename","union","using","virtual","volatile","while","xor","xor_eq"],m=["bool","char","char16_t","char32_t","char8_t","double","float","int","long","short","void","wchar_t","unsigned","signed","const","static"],g=["any","auto_ptr","barrier","binary_semaphore","bitset","complex","condition_variable","condition_variable_any","counting_semaphore","deque","false_type","future","imaginary","initializer_list","istringstream","jthread","latch","lock_guard","multimap","multiset","mutex","optional","ostringstream","packaged_task","pair","promise","priority_queue","queue","recursive_mutex","recursive_timed_mutex","scoped_lock","set","shared_future","shared_lock","shared_mutex","shared_timed_mutex","shared_ptr","stack","string_view","stringstream","timed_mutex","thread","true_type","tuple","unique_lock","unique_ptr","unordered_map","unordered_multimap","unordered_multiset","unordered_set","variant","vector","weak_ptr","wstring","wstring_view"],v=["abort","abs","acos","apply","as_const","asin","atan","atan2","calloc","ceil","cerr","cin","clog","cos","cosh","cout","declval","endl","exchange","exit","exp","fabs","floor","fmod","forward","fprintf","fputs","free","frexp","fscanf","future","invoke","isalnum","isalpha","iscntrl","isdigit","isgraph","islower","isprint","ispunct","isspace","isupper","isxdigit","labs","launder","ldexp","log","log10","make_pair","make_shared","make_shared_for_overwrite","make_tuple","make_unique","malloc","memchr","memcmp","memcpy","memset","modf","move","pow","printf","putchar","puts","realloc","scanf","sin","sinh","snprintf","sprintf","sqrt","sscanf","std","stderr","stdin","stdout","strcat","strchr","strcmp","strcpy","strcspn","strlen","strncat","strncmp","strncpy","strpbrk","strrchr","strspn","strstr","swap","tan","tanh","terminate","to_underlying","tolower","toupper","vfprintf","visit","vprintf","vsprintf"],b=["NULL","false","nullopt","nullptr","true"],y=["_Pragma"],w={type:m,keyword:f,literal:b,built_in:y,_type_hints:g},O={className:"function.dispatch",relevance:0,keywords:{_hint:v},begin:t.concat(/\b/,/(?!decltype)/,/(?!if)/,/(?!for)/,/(?!switch)/,/(?!while)/,e.IDENT_RE,t.lookahead(/(<[^<>]+>|)\s*\(/))},S=[O,d,s,n,e.C_BLOCK_COMMENT_MODE,u,c],E={variants:[{begin:/=/,end:/;/},{begin:/\(/,end:/\)/},{beginKeywords:"new throw return else",end:/;/}],keywords:w,contains:S.concat([{begin:/\(/,end:/\)/,keywords:w,contains:S.concat(["self"]),relevance:0}]),relevance:0},x={className:"function",begin:"("+a+"[\\*&\\s]+)+"+p,returnBegin:!0,end:/[{;=]/,excludeEnd:!0,keywords:w,illegal:/[^\w\s\*&:<>.]/,contains:[{begin:r,keywords:w,relevance:0},{begin:p,returnBegin:!0,contains:[h],relevance:0},{begin:/::/,relevance:0},{begin:/:/,endsWithParent:!0,contains:[c,u]},{relevance:0,match:/,/},{className:"params",begin:/\(/,end:/\)/,keywords:w,relevance:0,contains:[n,e.C_BLOCK_COMMENT_MODE,c,u,s,{begin:/\(/,end:/\)/,keywords:w,relevance:0,contains:["self",n,e.C_BLOCK_COMMENT_MODE,c,u,s]}]},s,n,e.C_BLOCK_COMMENT_MODE,d]};return{name:"C++",aliases:["cc","c++","h++","hpp","hh","hxx","cxx"],keywords:w,illegal:"</",classNameAliases:{"function.dispatch":"built_in"},contains:[].concat(E,x,O,S,[d,{begin:"\\b(deque|list|queue|priority_queue|pair|stack|vector|map|set|bitset|multiset|multimap|unordered_map|unordered_set|unordered_multiset|unordered_multimap|array|tuple|optional|variant|function)\\s*<(?!<)",end:">",keywords:w,contains:["self",s]},{begin:e.IDENT_RE+"::",keywords:w},{match:[/\b(?:enum(?:\s+(?:class|struct))?|class|struct|union)/,/\s+/,/\w+/],className:{1:"keyword",3:"title.class"}}])}}e.exports=t},25326:function(e){function t(e){const t="(_?[ui](8|16|32|64|128))?",n="(_?f(32|64))?",r="[a-zA-Z_]\\w*[!?=]?",i="[a-zA-Z_]\\w*[!?=]?|[-+~]@|<<|>>|[=!]~|===?|<=>|[<>]=?|\\*\\*|[-/+%^&*~|]|//|//=|&[-+*]=?|&\\*\\*|\\[\\][=?]?",o="[A-Za-z_]\\w*(::\\w+)*(\\?|!)?",a={$pattern:r,keyword:"abstract alias annotation as as? asm begin break case class def do else elsif end ensure enum extend for fun if include instance_sizeof is_a? lib macro module next nil? of out pointerof private protected rescue responds_to? return require select self sizeof struct super then type typeof union uninitialized unless until verbatim when while with yield __DIR__ __END_LINE__ __FILE__ __LINE__",literal:"false nil true"},s={className:"subst",begin:/#\{/,end:/\}/,keywords:a},l={className:"variable",begin:"(\\$\\W)|((\\$|@@?)(\\w+))(?=[^@$?])(?![A-Za-z])(?![@$?'])"},c={className:"template-variable",variants:[{begin:"\\{\\{",end:"\\}\\}"},{begin:"\\{%",end:"%\\}"}],keywords:a};function u(e,t){const n=[{begin:e,end:t}];return n[0].contains=n,n}const d={className:"string",contains:[e.BACKSLASH_ESCAPE,s],variants:[{begin:/'/,end:/'/},{begin:/"/,end:/"/},{begin:/`/,end:/`/},{begin:"%[Qwi]?\\(",end:"\\)",contains:u("\\(","\\)")},{begin:"%[Qwi]?\\[",end:"\\]",contains:u("\\[","\\]")},{begin:"%[Qwi]?\\{",end:/\}/,contains:u(/\{/,/\}/)},{begin:"%[Qwi]?<",end:">",contains:u("<",">")},{begin:"%[Qwi]?\\|",end:"\\|"},{begin:/<<-\w+$/,end:/^\s*\w+$/}],relevance:0},h={className:"string",variants:[{begin:"%q\\(",end:"\\)",contains:u("\\(","\\)")},{begin:"%q\\[",end:"\\]",contains:u("\\[","\\]")},{begin:"%q\\{",end:/\}/,contains:u(/\{/,/\}/)},{begin:"%q<",end:">",contains:u("<",">")},{begin:"%q\\|",end:"\\|"},{begin:/<<-'\w+'$/,end:/^\s*\w+$/}],relevance:0},p={begin:"(?!%\\})("+e.RE_STARTERS_RE+"|\\n|\\b(case|if|select|unless|until|when|while)\\b)\\s*",keywords:"case if select unless until when while",contains:[{className:"regexp",contains:[e.BACKSLASH_ESCAPE,s],variants:[{begin:"//[a-z]*",relevance:0},{begin:"/(?!\\/)",end:"/[a-z]*"}]}],relevance:0},f={className:"regexp",contains:[e.BACKSLASH_ESCAPE,s],variants:[{begin:"%r\\(",end:"\\)",contains:u("\\(","\\)")},{begin:"%r\\[",end:"\\]",contains:u("\\[","\\]")},{begin:"%r\\{",end:/\}/,contains:u(/\{/,/\}/)},{begin:"%r<",end:">",contains:u("<",">")},{begin:"%r\\|",end:"\\|"}],relevance:0},m={className:"meta",begin:"@\\[",end:"\\]",contains:[e.inherit(e.QUOTE_STRING_MODE,{className:"string"})]},g=[c,d,h,f,p,m,l,e.HASH_COMMENT_MODE,{className:"class",beginKeywords:"class module struct",end:"$|;",illegal:/=/,contains:[e.HASH_COMMENT_MODE,e.inherit(e.TITLE_MODE,{begin:o}),{begin:"<"}]},{className:"class",beginKeywords:"lib enum union",end:"$|;",illegal:/=/,contains:[e.HASH_COMMENT_MODE,e.inherit(e.TITLE_MODE,{begin:o})]},{beginKeywords:"annotation",end:"$|;",illegal:/=/,contains:[e.HASH_COMMENT_MODE,e.inherit(e.TITLE_MODE,{begin:o})],relevance:2},{className:"function",beginKeywords:"def",end:/\B\b/,contains:[e.inherit(e.TITLE_MODE,{begin:i,endsParent:!0})]},{className:"function",beginKeywords:"fun macro",end:/\B\b/,contains:[e.inherit(e.TITLE_MODE,{begin:i,endsParent:!0})],relevance:2},{className:"symbol",begin:e.UNDERSCORE_IDENT_RE+"(!|\\?)?:",relevance:0},{className:"symbol",begin:":",contains:[d,{begin:i}],relevance:0},{className:"number",variants:[{begin:"\\b0b([01_]+)"+t},{begin:"\\b0o([0-7_]+)"+t},{begin:"\\b0x([A-Fa-f0-9_]+)"+t},{begin:"\\b([1-9][0-9_]*[0-9]|[0-9])(\\.[0-9][0-9_]*)?([eE]_?[-+]?[0-9_]*)?"+n+"(?!_)"},{begin:"\\b([1-9][0-9_]*|0)"+t}],relevance:0}];return s.contains=g,c.contains=g.slice(1),{name:"Crystal",aliases:["cr"],keywords:a,contains:g}}e.exports=t},17025:function(e){function t(e){const t=["bool","byte","char","decimal","delegate","double","dynamic","enum","float","int","long","nint","nuint","object","sbyte","short","string","ulong","uint","ushort"],n=["public","private","protected","static","internal","protected","abstract","async","extern","override","unsafe","virtual","new","sealed","partial"],r=["default","false","null","true"],i=["abstract","as","base","break","case","catch","class","const","continue","do","else","event","explicit","extern","finally","fixed","for","foreach","goto","if","implicit","in","interface","internal","is","lock","namespace","new","operator","out","override","params","private","protected","public","readonly","record","ref","return","scoped","sealed","sizeof","stackalloc","static","struct","switch","this","throw","try","typeof","unchecked","unsafe","using","virtual","void","volatile","while"],o=["add","alias","and","ascending","async","await","by","descending","equals","from","get","global","group","init","into","join","let","nameof","not","notnull","on","or","orderby","partial","remove","select","set","unmanaged","value|0","var","when","where","with","yield"],a={keyword:i.concat(o),built_in:t,literal:r},s=e.inherit(e.TITLE_MODE,{begin:"[a-zA-Z](\\.?\\w)*"}),l={className:"number",variants:[{begin:"\\b(0b[01']+)"},{begin:"(-?)\\b([\\d']+(\\.[\\d']*)?|\\.[\\d']+)(u|U|l|L|ul|UL|f|F|b|B)"},{begin:"(-?)(\\b0[xX][a-fA-F0-9']+|(\\b[\\d']+(\\.[\\d']*)?|\\.[\\d']+)([eE][-+]?[\\d']+)?)"}],relevance:0},c={className:"string",begin:'@"',end:'"',contains:[{begin:'""'}]},u=e.inherit(c,{illegal:/\n/}),d={className:"subst",begin:/\{/,end:/\}/,keywords:a},h=e.inherit(d,{illegal:/\n/}),p={className:"string",begin:/\$"/,end:'"',illegal:/\n/,contains:[{begin:/\{\{/},{begin:/\}\}/},e.BACKSLASH_ESCAPE,h]},f={className:"string",begin:/\$@"/,end:'"',contains:[{begin:/\{\{/},{begin:/\}\}/},{begin:'""'},d]},m=e.inherit(f,{illegal:/\n/,contains:[{begin:/\{\{/},{begin:/\}\}/},{begin:'""'},h]});d.contains=[f,p,c,e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,l,e.C_BLOCK_COMMENT_MODE],h.contains=[m,p,u,e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,l,e.inherit(e.C_BLOCK_COMMENT_MODE,{illegal:/\n/})];const g={variants:[f,p,c,e.APOS_STRING_MODE,e.QUOTE_STRING_MODE]},v={begin:"<",end:">",contains:[{beginKeywords:"in out"},s]},b=e.IDENT_RE+"(<"+e.IDENT_RE+"(\\s*,\\s*"+e.IDENT_RE+")*>)?(\\[\\])?",y={begin:"@"+e.IDENT_RE,relevance:0};return{name:"C#",aliases:["cs","c#"],keywords:a,illegal:/::/,contains:[e.COMMENT("///","$",{returnBegin:!0,contains:[{className:"doctag",variants:[{begin:"///",relevance:0},{begin:"\x3c!--|--\x3e"},{begin:"</?",end:">"}]}]}),e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,{className:"meta",begin:"#",end:"$",keywords:{keyword:"if else elif endif define undef warning error line region endregion pragma checksum"}},g,l,{beginKeywords:"class interface",relevance:0,end:/[{;=]/,illegal:/[^\s:,]/,contains:[{beginKeywords:"where class"},s,v,e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE]},{beginKeywords:"namespace",relevance:0,end:/[{;=]/,illegal:/[^\s:]/,contains:[s,e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE]},{beginKeywords:"record",relevance:0,end:/[{;=]/,illegal:/[^\s:]/,contains:[s,v,e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE]},{className:"meta",begin:"^\\s*\\[(?=[\\w])",excludeBegin:!0,end:"\\]",excludeEnd:!0,contains:[{className:"string",begin:/"/,end:/"/}]},{beginKeywords:"new return throw await else",relevance:0},{className:"function",begin:"("+b+"\\s+)+"+e.IDENT_RE+"\\s*(<[^=]+>\\s*)?\\(",returnBegin:!0,end:/\s*[{;=]/,excludeEnd:!0,keywords:a,contains:[{beginKeywords:n.join(" "),relevance:0},{begin:e.IDENT_RE+"\\s*(<[^=]+>\\s*)?\\(",returnBegin:!0,contains:[e.TITLE_MODE,v],relevance:0},{match:/\(\)/},{className:"params",begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:a,relevance:0,contains:[g,l,e.C_BLOCK_COMMENT_MODE]},e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE]},y]}}e.exports=t},35678:function(e){function t(e){const t=["base-uri","child-src","connect-src","default-src","font-src","form-action","frame-ancestors","frame-src","img-src","manifest-src","media-src","object-src","plugin-types","report-uri","sandbox","script-src","style-src","trusted-types","unsafe-hashes","worker-src"];return{name:"CSP",case_insensitive:!1,keywords:{$pattern:"[a-zA-Z][a-zA-Z0-9_-]*",keyword:t},contains:[{className:"string",begin:"'",end:"'"},{className:"attribute",begin:"^Content",end:":",excludeEnd:!0}]}}e.exports=t},63355:function(e){const t=e=>({IMPORTANT:{scope:"meta",begin:"!important"},BLOCK_COMMENT:e.C_BLOCK_COMMENT_MODE,HEXCOLOR:{scope:"number",begin:/#(([0-9a-fA-F]{3,4})|(([0-9a-fA-F]{2}){3,4}))\b/},FUNCTION_DISPATCH:{className:"built_in",begin:/[\w-]+(?=\()/},ATTRIBUTE_SELECTOR_MODE:{scope:"selector-attr",begin:/\[/,end:/\]/,illegal:"$",contains:[e.APOS_STRING_MODE,e.QUOTE_STRING_MODE]},CSS_NUMBER_MODE:{scope:"number",begin:e.NUMBER_RE+"(%|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc|px|deg|grad|rad|turn|s|ms|Hz|kHz|dpi|dpcm|dppx)?",relevance:0},CSS_VARIABLE:{className:"attr",begin:/--[A-Za-z][A-Za-z0-9_-]*/}}),n=["a","abbr","address","article","aside","audio","b","blockquote","body","button","canvas","caption","cite","code","dd","del","details","dfn","div","dl","dt","em","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hgroup","html","i","iframe","img","input","ins","kbd","label","legend","li","main","mark","menu","nav","object","ol","p","q","quote","samp","section","span","strong","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","tr","ul","var","video"],r=["any-hover","any-pointer","aspect-ratio","color","color-gamut","color-index","device-aspect-ratio","device-height","device-width","display-mode","forced-colors","grid","height","hover","inverted-colors","monochrome","orientation","overflow-block","overflow-inline","pointer","prefers-color-scheme","prefers-contrast","prefers-reduced-motion","prefers-reduced-transparency","resolution","scan","scripting","update","width","min-width","max-width","min-height","max-height"],i=["active","any-link","blank","checked","current","default","defined","dir","disabled","drop","empty","enabled","first","first-child","first-of-type","fullscreen","future","focus","focus-visible","focus-within","has","host","host-context","hover","indeterminate","in-range","invalid","is","lang","last-child","last-of-type","left","link","local-link","not","nth-child","nth-col","nth-last-child","nth-last-col","nth-last-of-type","nth-of-type","only-child","only-of-type","optional","out-of-range","past","placeholder-shown","read-only","read-write","required","right","root","scope","target","target-within","user-invalid","valid","visited","where"],o=["after","backdrop","before","cue","cue-region","first-letter","first-line","grammar-error","marker","part","placeholder","selection","slotted","spelling-error"],a=["align-content","align-items","align-self","all","animation","animation-delay","animation-direction","animation-duration","animation-fill-mode","animation-iteration-count","animation-name","animation-play-state","animation-timing-function","backface-visibility","background","background-attachment","background-blend-mode","background-clip","background-color","background-image","background-origin","background-position","background-repeat","background-size","block-size","border","border-block","border-block-color","border-block-end","border-block-end-color","border-block-end-style","border-block-end-width","border-block-start","border-block-start-color","border-block-start-style","border-block-start-width","border-block-style","border-block-width","border-bottom","border-bottom-color","border-bottom-left-radius","border-bottom-right-radius","border-bottom-style","border-bottom-width","border-collapse","border-color","border-image","border-image-outset","border-image-repeat","border-image-slice","border-image-source","border-image-width","border-inline","border-inline-color","border-inline-end","border-inline-end-color","border-inline-end-style","border-inline-end-width","border-inline-start","border-inline-start-color","border-inline-start-style","border-inline-start-width","border-inline-style","border-inline-width","border-left","border-left-color","border-left-style","border-left-width","border-radius","border-right","border-right-color","border-right-style","border-right-width","border-spacing","border-style","border-top","border-top-color","border-top-left-radius","border-top-right-radius","border-top-style","border-top-width","border-width","bottom","box-decoration-break","box-shadow","box-sizing","break-after","break-before","break-inside","caption-side","caret-color","clear","clip","clip-path","clip-rule","color","column-count","column-fill","column-gap","column-rule","column-rule-color","column-rule-style","column-rule-width","column-span","column-width","columns","contain","content","content-visibility","counter-increment","counter-reset","cue","cue-after","cue-before","cursor","direction","display","empty-cells","filter","flex","flex-basis","flex-direction","flex-flow","flex-grow","flex-shrink","flex-wrap","float","flow","font","font-display","font-family","font-feature-settings","font-kerning","font-language-override","font-size","font-size-adjust","font-smoothing","font-stretch","font-style","font-synthesis","font-variant","font-variant-caps","font-variant-east-asian","font-variant-ligatures","font-variant-numeric","font-variant-position","font-variation-settings","font-weight","gap","glyph-orientation-vertical","grid","grid-area","grid-auto-columns","grid-auto-flow","grid-auto-rows","grid-column","grid-column-end","grid-column-start","grid-gap","grid-row","grid-row-end","grid-row-start","grid-template","grid-template-areas","grid-template-columns","grid-template-rows","hanging-punctuation","height","hyphens","icon","image-orientation","image-rendering","image-resolution","ime-mode","inline-size","isolation","justify-content","left","letter-spacing","line-break","line-height","list-style","list-style-image","list-style-position","list-style-type","margin","margin-block","margin-block-end","margin-block-start","margin-bottom","margin-inline","margin-inline-end","margin-inline-start","margin-left","margin-right","margin-top","marks","mask","mask-border","mask-border-mode","mask-border-outset","mask-border-repeat","mask-border-slice","mask-border-source","mask-border-width","mask-clip","mask-composite","mask-image","mask-mode","mask-origin","mask-position","mask-repeat","mask-size","mask-type","max-block-size","max-height","max-inline-size","max-width","min-block-size","min-height","min-inline-size","min-width","mix-blend-mode","nav-down","nav-index","nav-left","nav-right","nav-up","none","normal","object-fit","object-position","opacity","order","orphans","outline","outline-color","outline-offset","outline-style","outline-width","overflow","overflow-wrap","overflow-x","overflow-y","padding","padding-block","padding-block-end","padding-block-start","padding-bottom","padding-inline","padding-inline-end","padding-inline-start","padding-left","padding-right","padding-top","page-break-after","page-break-before","page-break-inside","pause","pause-after","pause-before","perspective","perspective-origin","pointer-events","position","quotes","resize","rest","rest-after","rest-before","right","row-gap","scroll-margin","scroll-margin-block","scroll-margin-block-end","scroll-margin-block-start","scroll-margin-bottom","scroll-margin-inline","scroll-margin-inline-end","scroll-margin-inline-start","scroll-margin-left","scroll-margin-right","scroll-margin-top","scroll-padding","scroll-padding-block","scroll-padding-block-end","scroll-padding-block-start","scroll-padding-bottom","scroll-padding-inline","scroll-padding-inline-end","scroll-padding-inline-start","scroll-padding-left","scroll-padding-right","scroll-padding-top","scroll-snap-align","scroll-snap-stop","scroll-snap-type","scrollbar-color","scrollbar-gutter","scrollbar-width","shape-image-threshold","shape-margin","shape-outside","speak","speak-as","src","tab-size","table-layout","text-align","text-align-all","text-align-last","text-combine-upright","text-decoration","text-decoration-color","text-decoration-line","text-decoration-style","text-emphasis","text-emphasis-color","text-emphasis-position","text-emphasis-style","text-indent","text-justify","text-orientation","text-overflow","text-rendering","text-shadow","text-transform","text-underline-position","top","transform","transform-box","transform-origin","transform-style","transition","transition-delay","transition-duration","transition-property","transition-timing-function","unicode-bidi","vertical-align","visibility","voice-balance","voice-duration","voice-family","voice-pitch","voice-range","voice-rate","voice-stress","voice-volume","white-space","widows","width","will-change","word-break","word-spacing","word-wrap","writing-mode","z-index"].reverse();function s(e){const s=e.regex,l=t(e),c={begin:/-(webkit|moz|ms|o)-(?=[a-z])/},u="and or not only",d=/@-?\w[\w]*(-\w+)*/,h="[a-zA-Z-][a-zA-Z0-9_-]*",p=[e.APOS_STRING_MODE,e.QUOTE_STRING_MODE];return{name:"CSS",case_insensitive:!0,illegal:/[=|'\$]/,keywords:{keyframePosition:"from to"},classNameAliases:{keyframePosition:"selector-tag"},contains:[l.BLOCK_COMMENT,c,l.CSS_NUMBER_MODE,{className:"selector-id",begin:/#[A-Za-z0-9_-]+/,relevance:0},{className:"selector-class",begin:"\\."+h,relevance:0},l.ATTRIBUTE_SELECTOR_MODE,{className:"selector-pseudo",variants:[{begin:":("+i.join("|")+")"},{begin:":(:)?("+o.join("|")+")"}]},l.CSS_VARIABLE,{className:"attribute",begin:"\\b("+a.join("|")+")\\b"},{begin:/:/,end:/[;}{]/,contains:[l.BLOCK_COMMENT,l.HEXCOLOR,l.IMPORTANT,l.CSS_NUMBER_MODE,...p,{begin:/(url|data-uri)\(/,end:/\)/,relevance:0,keywords:{built_in:"url data-uri"},contains:[...p,{className:"string",begin:/[^)]/,endsWithParent:!0,excludeEnd:!0}]},l.FUNCTION_DISPATCH]},{begin:s.lookahead(/@/),end:"[{;]",relevance:0,illegal:/:/,contains:[{className:"keyword",begin:d},{begin:/\s/,endsWithParent:!0,excludeEnd:!0,relevance:0,keywords:{$pattern:/[a-z-]+/,keyword:u,attribute:r.join(" ")},contains:[{begin:/[a-z-]+(?=:)/,className:"attribute"},...p,l.CSS_NUMBER_MODE]}]},{className:"selector-tag",begin:"\\b("+n.join("|")+")\\b"}]}}e.exports=s},92835:function(e){function t(e){const t={className:"subst",variants:[{begin:"\\$[A-Za-z0-9_]+"}]},n={className:"subst",variants:[{begin:/\$\{/,end:/\}/}],keywords:"true false null this is new super"},r={className:"string",variants:[{begin:"r'''",end:"'''"},{begin:'r"""',end:'"""'},{begin:"r'",end:"'",illegal:"\\n"},{begin:'r"',end:'"',illegal:"\\n"},{begin:"'''",end:"'''",contains:[e.BACKSLASH_ESCAPE,t,n]},{begin:'"""',end:'"""',contains:[e.BACKSLASH_ESCAPE,t,n]},{begin:"'",end:"'",illegal:"\\n",contains:[e.BACKSLASH_ESCAPE,t,n]},{begin:'"',end:'"',illegal:"\\n",contains:[e.BACKSLASH_ESCAPE,t,n]}]};n.contains=[e.C_NUMBER_MODE,r];const i=["Comparable","DateTime","Duration","Function","Iterable","Iterator","List","Map","Match","Object","Pattern","RegExp","Set","Stopwatch","String","StringBuffer","StringSink","Symbol","Type","Uri","bool","double","int","num","Element","ElementList"],o=i.map(e=>`${e}?`),a=["abstract","as","assert","async","await","break","case","catch","class","const","continue","covariant","default","deferred","do","dynamic","else","enum","export","extends","extension","external","factory","false","final","finally","for","Function","get","hide","if","implements","import","in","inferface","is","late","library","mixin","new","null","on","operator","part","required","rethrow","return","set","show","static","super","switch","sync","this","throw","true","try","typedef","var","void","while","with","yield"],s={keyword:a,built_in:i.concat(o).concat(["Never","Null","dynamic","print","document","querySelector","querySelectorAll","window"]),$pattern:/[A-Za-z][A-Za-z0-9_]*\??/};return{name:"Dart",keywords:s,contains:[r,e.COMMENT(/\/\*\*(?!\/)/,/\*\//,{subLanguage:"markdown",relevance:0}),e.COMMENT(/\/{3,} ?/,/$/,{contains:[{subLanguage:"markdown",begin:".",end:"$",relevance:0}]}),e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,{className:"class",beginKeywords:"class interface",end:/\{/,excludeEnd:!0,contains:[{beginKeywords:"extends implements"},e.UNDERSCORE_TITLE_MODE]},e.C_NUMBER_MODE,{className:"meta",begin:"@[A-Za-z]+"},{begin:"=>"}]}}e.exports=t},16361:function(e){function t(e){const t=e.regex;return{name:"Diff",aliases:["patch"],contains:[{className:"meta",relevance:10,match:t.either(/^@@ +-\d+,\d+ +\+\d+,\d+ +@@/,/^\*\*\* +\d+,\d+ +\*\*\*\*$/,/^--- +\d+,\d+ +----$/)},{className:"comment",variants:[{begin:t.either(/Index: /,/^index/,/={3,}/,/^-{3}/,/^\*{3} /,/^\+{3}/,/^diff --git/),end:/$/},{match:/^\*{15}$/}]},{className:"addition",begin:/^\+/,end:/$/},{className:"deletion",begin:/^-/,end:/$/},{className:"addition",begin:/^!/,end:/$/}]}}e.exports=t},82476:function(e){function t(e){const t=["from","maintainer","expose","env","arg","user","onbuild","stopsignal"];return{name:"Dockerfile",aliases:["docker"],case_insensitive:!0,keywords:t,contains:[e.HASH_COMMENT_MODE,e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,e.NUMBER_MODE,{beginKeywords:"run cmd entrypoint volume add copy workdir label healthcheck shell",starts:{end:/[^\\]$/,subLanguage:"bash"}}],illegal:"</"}}e.exports=t},74809:function(e){function t(e){const t=e.regex,n="[a-zA-Z_][a-zA-Z0-9_.]*(!|\\?)?",r="[a-zA-Z_]\\w*[!?=]?|[-+~]@|<<|>>|=~|===?|<=>|[<>]=?|\\*\\*|[-/+%^&*~`|]|\\[\\]=?",i=["after","alias","and","case","catch","cond","defstruct","defguard","do","else","end","fn","for","if","import","in","not","or","quote","raise","receive","require","reraise","rescue","try","unless","unquote","unquote_splicing","use","when","with|0"],o=["false","nil","true"],a={$pattern:n,keyword:i,literal:o},s={className:"subst",begin:/#\{/,end:/\}/,keywords:a},l={className:"number",begin:"(\\b0o[0-7_]+)|(\\b0b[01_]+)|(\\b0x[0-9a-fA-F_]+)|(-?\\b[0-9][0-9_]*(\\.[0-9_]+([eE][-+]?[0-9]+)?)?)",relevance:0},c=/\\[\s\S]/,u={match:c,scope:"char.escape",relevance:0},d="[/|([{<\"']",h=[{begin:/"/,end:/"/},{begin:/'/,end:/'/},{begin:/\//,end:/\//},{begin:/\|/,end:/\|/},{begin:/\(/,end:/\)/},{begin:/\[/,end:/\]/},{begin:/\{/,end:/\}/},{begin:/</,end:/>/}],p=e=>({scope:"char.escape",begin:t.concat(/\\/,e),relevance:0}),f={className:"string",begin:"~[a-z](?="+d+")",contains:h.map(t=>e.inherit(t,{contains:[p(t.end),u,s]}))},m={className:"string",begin:"~[A-Z](?="+d+")",contains:h.map(t=>e.inherit(t,{contains:[p(t.end)]}))},g={className:"regex",variants:[{begin:"~r(?="+d+")",contains:h.map(n=>e.inherit(n,{end:t.concat(n.end,/[uismxfU]{0,7}/),contains:[p(n.end),u,s]}))},{begin:"~R(?="+d+")",contains:h.map(n=>e.inherit(n,{end:t.concat(n.end,/[uismxfU]{0,7}/),contains:[p(n.end)]}))}]},v={className:"string",contains:[e.BACKSLASH_ESCAPE,s],variants:[{begin:/"""/,end:/"""/},{begin:/'''/,end:/'''/},{begin:/~S"""/,end:/"""/,contains:[]},{begin:/~S"/,end:/"/,contains:[]},{begin:/~S'''/,end:/'''/,contains:[]},{begin:/~S'/,end:/'/,contains:[]},{begin:/'/,end:/'/},{begin:/"/,end:/"/}]},b={className:"function",beginKeywords:"def defp defmacro defmacrop",end:/\B\b/,contains:[e.inherit(e.TITLE_MODE,{begin:n,endsParent:!0})]},y=e.inherit(b,{className:"class",beginKeywords:"defimpl defmodule defprotocol defrecord",end:/\bdo\b|$|;/}),w=[v,g,m,f,e.HASH_COMMENT_MODE,y,b,{begin:"::"},{className:"symbol",begin:":(?![\\s:])",contains:[v,{begin:r}],relevance:0},{className:"symbol",begin:n+":(?!:)",relevance:0},{className:"title.class",begin:/(\b[A-Z][a-zA-Z0-9_]+)/,relevance:0},l,{className:"variable",begin:"(\\$\\W)|((\\$|@@?)(\\w+))"}];return s.contains=w,{name:"Elixir",aliases:["ex","exs"],keywords:a,contains:w}}e.exports=t},42892:function(e){function t(e){const t={variants:[e.COMMENT("--","$"),e.COMMENT(/\{-/,/-\}/,{contains:["self"]})]},n={className:"type",begin:"\\b[A-Z][\\w']*",relevance:0},r={begin:"\\(",end:"\\)",illegal:'"',contains:[{className:"type",begin:"\\b[A-Z][\\w]*(\\((\\.\\.|,|\\w+)\\))?"},t]},i={begin:/\{/,end:/\}/,contains:r.contains},o={className:"string",begin:"'\\\\?.",end:"'",illegal:"."},a=["let","in","if","then","else","case","of","where","module","import","exposing","type","alias","as","infix","infixl","infixr","port","effect","command","subscription"];return{name:"Elm",keywords:a,contains:[{beginKeywords:"port effect module",end:"exposing",keywords:"port effect module where command subscription exposing",contains:[r,t],illegal:"\\W\\.|;"},{begin:"import",end:"$",keywords:"import as exposing",contains:[r,t],illegal:"\\W\\.|;"},{begin:"type",end:"$",keywords:"type alias",contains:[n,r,i,t]},{beginKeywords:"infix infixl infixr",end:"$",contains:[e.C_NUMBER_MODE,t]},{begin:"port",end:"$",keywords:"port",contains:[t]},o,e.QUOTE_STRING_MODE,e.C_NUMBER_MODE,n,e.inherit(e.TITLE_MODE,{begin:"^[_a-z][\\w']*"}),t,{begin:"->|<-"}],illegal:/;/}}e.exports=t},84441:function(e){function t(e){const t="[a-z'][a-zA-Z0-9_']*",n="("+t+":"+t+"|"+t+")",r={keyword:"after and andalso|10 band begin bnot bor bsl bzr bxor case catch cond div end fun if let not of orelse|10 query receive rem try when xor",literal:"false true"},i=e.COMMENT("%","$"),o={className:"number",begin:"\\b(\\d+(_\\d+)*#[a-fA-F0-9]+(_[a-fA-F0-9]+)*|\\d+(_\\d+)*(\\.\\d+(_\\d+)*)?([eE][-+]?\\d+)?)",relevance:0},a={begin:"fun\\s+"+t+"/\\d+"},s={begin:n+"\\(",end:"\\)",returnBegin:!0,relevance:0,contains:[{begin:n,relevance:0},{begin:"\\(",end:"\\)",endsWithParent:!0,returnEnd:!0,relevance:0}]},l={begin:/\{/,end:/\}/,relevance:0},c={begin:"\\b_([A-Z][A-Za-z0-9_]*)?",relevance:0},u={begin:"[A-Z][a-zA-Z0-9_]*",relevance:0},d={begin:"#"+e.UNDERSCORE_IDENT_RE,relevance:0,returnBegin:!0,contains:[{begin:"#"+e.UNDERSCORE_IDENT_RE,relevance:0},{begin:/\{/,end:/\}/,relevance:0}]},h={beginKeywords:"fun receive if try case",end:"end",keywords:r};h.contains=[i,a,e.inherit(e.APOS_STRING_MODE,{className:""}),h,s,e.QUOTE_STRING_MODE,o,l,c,u,d];const p=[i,a,h,s,e.QUOTE_STRING_MODE,o,l,c,u,d];s.contains[1].contains=p,l.contains=p,d.contains[1].contains=p;const f=["-module","-record","-undef","-export","-ifdef","-ifndef","-author","-copyright","-doc","-vsn","-import","-include","-include_lib","-compile","-define","-else","-endif","-file","-behaviour","-behavior","-spec"],m={className:"params",begin:"\\(",end:"\\)",contains:p};return{name:"Erlang",aliases:["erl"],keywords:r,illegal:"(</|\\*=|\\+=|-=|/\\*|\\*/|\\(\\*|\\*\\))",contains:[{className:"function",begin:"^"+t+"\\s*\\(",end:"->",returnBegin:!0,illegal:"\\(|#|//|/\\*|\\\\|:|;",contains:[m,e.inherit(e.TITLE_MODE,{begin:t})],starts:{end:";|\\.",keywords:r,contains:p}},i,{begin:"^-",end:"\\.",relevance:0,excludeEnd:!0,returnBegin:!0,keywords:{$pattern:"-"+e.IDENT_RE,keyword:f.map(e=>`${e}|1.5`).join(" ")},contains:[m]},o,e.QUOTE_STRING_MODE,d,c,u,l,{begin:/\.$/}]}}e.exports=t},25236:function(e){function t(e){return new RegExp(e.replace(/[-/\\^$*+?.()|[\]{}]/g,"\\$&"),"m")}function n(e){return e?"string"===typeof e?e:e.source:null}function r(e){return i("(?=",e,")")}function i(...e){const t=e.map(e=>n(e)).join("");return t}function o(e){const t=e[e.length-1];return"object"===typeof t&&t.constructor===Object?(e.splice(e.length-1,1),t):{}}function a(...e){const t=o(e),r="("+(t.capture?"":"?:")+e.map(e=>n(e)).join("|")+")";return r}function s(e){const n=["abstract","and","as","assert","base","begin","class","default","delegate","do","done","downcast","downto","elif","else","end","exception","extern","finally","fixed","for","fun","function","global","if","in","inherit","inline","interface","internal","lazy","let","match","member","module","mutable","namespace","new","of","open","or","override","private","public","rec","return","static","struct","then","to","try","type","upcast","use","val","void","when","while","with","yield"],o={scope:"keyword",match:/\b(yield|return|let|do|match|use)!/},s=["if","else","endif","line","nowarn","light","r","i","I","load","time","help","quit"],l=["true","false","null","Some","None","Ok","Error","infinity","infinityf","nan","nanf"],c=["__LINE__","__SOURCE_DIRECTORY__","__SOURCE_FILE__"],u=["bool","byte","sbyte","int8","int16","int32","uint8","uint16","uint32","int","uint","int64","uint64","nativeint","unativeint","decimal","float","double","float32","single","char","string","unit","bigint","option","voption","list","array","seq","byref","exn","inref","nativeptr","obj","outref","voidptr","Result"],d=["not","ref","raise","reraise","dict","readOnlyDict","set","get","enum","sizeof","typeof","typedefof","nameof","nullArg","invalidArg","invalidOp","id","fst","snd","ignore","lock","using","box","unbox","tryUnbox","printf","printfn","sprintf","eprintf","eprintfn","fprintf","fprintfn","failwith","failwithf"],h={keyword:n,literal:l,built_in:d,"variable.constant":c},p=e.COMMENT(/\(\*(?!\))/,/\*\)/,{contains:["self"]}),f={variants:[p,e.C_LINE_COMMENT_MODE]},m=/[a-zA-Z_](\w|')*/,g={scope:"variable",begin:/``/,end:/``/},v=/\B('|\^)/,b={scope:"symbol",variants:[{match:i(v,/``.*?``/)},{match:i(v,e.UNDERSCORE_IDENT_RE)}],relevance:0},y=function({includeEqual:e}){let n;n=e?"!%&*+-/<=>@^|~?":"!%&*+-/<>@^|~?";const o=Array.from(n),s=i("[",...o.map(t),"]"),l=a(s,/\./),c=i(l,r(l)),u=a(i(c,l,"*"),i(s,"+"));return{scope:"operator",match:a(u,/:\?>/,/:\?/,/:>/,/:=/,/::?/,/\$/),relevance:0}},w=y({includeEqual:!0}),O=y({includeEqual:!1}),S=function(t,n){return{begin:i(t,r(i(/\s*/,a(/\w/,/'/,/\^/,/#/,/``/,/\(/,/{\|/)))),beginScope:n,end:r(a(/\n/,/=/)),relevance:0,keywords:e.inherit(h,{type:u}),contains:[f,b,e.inherit(g,{scope:null}),O]}},E=S(/:/,"operator"),x=S(/\bof\b/,"keyword"),_={begin:[/(^|\s+)/,/type/,/\s+/,m],beginScope:{2:"keyword",4:"title.class"},end:r(/\(|=|$/),keywords:h,contains:[f,e.inherit(g,{scope:null}),b,{scope:"operator",match:/<|>/},E]},k={scope:"computation-expression",match:/\b[_a-z]\w*(?=\s*\{)/},C={begin:[/^\s*/,i(/#/,a(...s)),/\b/],beginScope:{2:"meta"},end:r(/\s|$/)},A={variants:[e.BINARY_NUMBER_MODE,e.C_NUMBER_MODE]},T={scope:"string",begin:/"/,end:/"/,contains:[e.BACKSLASH_ESCAPE]},R={scope:"string",begin:/@"/,end:/"/,contains:[{match:/""/},e.BACKSLASH_ESCAPE]},N={scope:"string",begin:/"""/,end:/"""/,relevance:2},P={scope:"subst",begin:/\{/,end:/\}/,keywords:h},I={scope:"string",begin:/\$"/,end:/"/,contains:[{match:/\{\{/},{match:/\}\}/},e.BACKSLASH_ESCAPE,P]},M={scope:"string",begin:/(\$@|@\$)"/,end:/"/,contains:[{match:/\{\{/},{match:/\}\}/},{match:/""/},e.BACKSLASH_ESCAPE,P]},D={scope:"string",begin:/\$"""/,end:/"""/,contains:[{match:/\{\{/},{match:/\}\}/},P],relevance:2},L={scope:"string",match:i(/'/,a(/[^\\']/,/\\(?:.|\d{3}|x[a-fA-F\d]{2}|u[a-fA-F\d]{4}|U[a-fA-F\d]{8})/),/'/)};P.contains=[M,I,R,T,L,o,f,g,E,k,C,A,b,w];const B={variants:[D,M,I,N,R,T,L]};return{name:"F#",aliases:["fs","f#"],keywords:h,illegal:/\/\*/,classNameAliases:{"computation-expression":"keyword"},contains:[o,B,f,g,_,{scope:"meta",begin:/\[</,end:/>\]/,relevance:2,contains:[g,N,R,T,L,A]},x,E,k,C,A,b,w]}}e.exports=s},51468:function(e){function t(e){const t=["true","false","iota","nil"],n=["append","cap","close","complex","copy","imag","len","make","new","panic","print","println","real","recover","delete"],r=["bool","byte","complex64","complex128","error","float32","float64","int8","int16","int32","int64","string","uint8","uint16","uint32","uint64","int","uint","uintptr","rune"],i=["break","case","chan","const","continue","default","defer","else","fallthrough","for","func","go","goto","if","import","interface","map","package","range","return","select","struct","switch","type","var"],o={keyword:i,type:r,literal:t,built_in:n};return{name:"Go",aliases:["golang"],keywords:o,illegal:"</",contains:[e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,{className:"string",variants:[e.QUOTE_STRING_MODE,e.APOS_STRING_MODE,{begin:"`",end:"`"}]},{className:"number",variants:[{begin:e.C_NUMBER_RE+"[i]",relevance:1},e.C_NUMBER_MODE]},{begin:/:=/},{className:"function",beginKeywords:"func",end:"\\s*(\\{|$)",excludeEnd:!0,contains:[e.TITLE_MODE,{className:"params",begin:/\(/,end:/\)/,endsParent:!0,keywords:o,illegal:/["']/}]}]}}e.exports=t},95541:function(e){function t(e){const t=["task","project","allprojects","subprojects","artifacts","buildscript","configurations","dependencies","repositories","sourceSets","description","delete","from","into","include","exclude","source","classpath","destinationDir","includes","options","sourceCompatibility","targetCompatibility","group","flatDir","doLast","doFirst","flatten","todir","fromdir","ant","def","abstract","break","case","catch","continue","default","do","else","extends","final","finally","for","if","implements","instanceof","native","new","private","protected","public","return","static","switch","synchronized","throw","throws","transient","try","volatile","while","strictfp","package","import","false","null","super","this","true","antlrtask","checkstyle","codenarc","copy","boolean","byte","char","class","double","float","int","interface","long","short","void","compile","runTime","file","fileTree","abs","any","append","asList","asWritable","call","collect","compareTo","count","div","dump","each","eachByte","eachFile","eachLine","every","find","findAll","flatten","getAt","getErr","getIn","getOut","getText","grep","immutable","inject","inspect","intersect","invokeMethods","isCase","join","leftShift","minus","multiply","newInputStream","newOutputStream","newPrintWriter","newReader","newWriter","next","plus","pop","power","previous","print","println","push","putAt","read","readBytes","readLines","reverse","reverseEach","round","size","sort","splitEachLine","step","subMap","times","toInteger","toList","tokenize","upto","waitForOrKill","withPrintWriter","withReader","withStream","withWriter","withWriterAppend","write","writeLine"];return{name:"Gradle",case_insensitive:!0,keywords:t,contains:[e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,e.NUMBER_MODE,e.REGEXP_MODE]}}e.exports=t},53528:function(e){function t(e,t={}){return t.variants=e,t}function n(e){const n=e.regex,r="[A-Za-z0-9_$]+",i=t([e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,e.COMMENT("/\\*\\*","\\*/",{relevance:0,contains:[{begin:/\w+@/,relevance:0},{className:"doctag",begin:"@[A-Za-z]+"}]})]),o={className:"regexp",begin:/~?\/[^\/\n]+\//,contains:[e.BACKSLASH_ESCAPE]},a=t([e.BINARY_NUMBER_MODE,e.C_NUMBER_MODE]),s=t([{begin:/"""/,end:/"""/},{begin:/'''/,end:/'''/},{begin:"\\$/",end:"/\\$",relevance:10},e.APOS_STRING_MODE,e.QUOTE_STRING_MODE],{className:"string"}),l={match:[/(class|interface|trait|enum|extends|implements)/,/\s+/,e.UNDERSCORE_IDENT_RE],scope:{1:"keyword",3:"title.class"}},c=["byte","short","char","int","long","boolean","float","double","void"],u=["def","as","in","assert","trait","abstract","static","volatile","transient","public","private","protected","synchronized","final","class","interface","enum","if","else","for","while","switch","case","break","default","continue","throw","throws","try","catch","finally","implements","extends","new","import","package","return","instanceof"];return{name:"Groovy",keywords:{"variable.language":"this super",literal:"true false null",type:c,keyword:u},contains:[e.SHEBANG({binary:"groovy",relevance:10}),i,s,o,a,l,{className:"meta",begin:"@[A-Za-z]+",relevance:0},{className:"attr",begin:r+"[ \t]*:",relevance:0},{begin:/\?/,end:/:/,relevance:0,contains:[i,s,o,a,"self"]},{className:"symbol",begin:"^[ \t]*"+n.lookahead(r+":"),excludeBegin:!0,end:r+":",relevance:0}],illegal:/#|<\//}}e.exports=n},88842:function(e){function t(e){const t=e.regex,n={$pattern:/[\w.\/]+/,built_in:["action","bindattr","collection","component","concat","debugger","each","each-in","get","hash","if","in","input","link-to","loc","log","lookup","mut","outlet","partial","query-params","render","template","textarea","unbound","unless","view","with","yield"]},r={$pattern:/[\w.\/]+/,literal:["true","false","undefined","null"]},i=/""|"[^"]+"/,o=/''|'[^']+'/,a=/\[\]|\[[^\]]+\]/,s=/[^\s!"#%&'()*+,.\/;<=>@\[\\\]^`{|}~]+/,l=/(\.|\/)/,c=t.either(i,o,a,s),u=t.concat(t.optional(/\.|\.\/|\//),c,t.anyNumberOfTimes(t.concat(l,c))),d=t.concat("(",a,"|",s,")(?==)"),h={begin:u},p=e.inherit(h,{keywords:r}),f={begin:/\(/,end:/\)/},m={className:"attr",begin:d,relevance:0,starts:{begin:/=/,end:/=/,starts:{contains:[e.NUMBER_MODE,e.QUOTE_STRING_MODE,e.APOS_STRING_MODE,p,f]}}},g={begin:/as\s+\|/,keywords:{keyword:"as"},end:/\|/,contains:[{begin:/\w+/}]},v={contains:[e.NUMBER_MODE,e.QUOTE_STRING_MODE,e.APOS_STRING_MODE,g,m,p,f],returnEnd:!0},b=e.inherit(h,{className:"name",keywords:n,starts:e.inherit(v,{end:/\)/})});f.contains=[b];const y=e.inherit(h,{keywords:n,className:"name",starts:e.inherit(v,{end:/\}\}/})}),w=e.inherit(h,{keywords:n,className:"name"}),O=e.inherit(h,{className:"name",keywords:n,starts:e.inherit(v,{end:/\}\}/})}),S={begin:/\\\{\{/,skip:!0},E={begin:/\\\\(?=\{\{)/,skip:!0};return{name:"Handlebars",aliases:["hbs","html.hbs","html.handlebars","htmlbars"],case_insensitive:!0,subLanguage:"xml",contains:[S,E,e.COMMENT(/\{\{!--/,/--\}\}/),e.COMMENT(/\{\{!/,/\}\}/),{className:"template-tag",begin:/\{\{\{\{(?!\/)/,end:/\}\}\}\}/,contains:[y],starts:{end:/\{\{\{\{\//,returnEnd:!0,subLanguage:"xml"}},{className:"template-tag",begin:/\{\{\{\{\//,end:/\}\}\}\}/,contains:[w]},{className:"template-tag",begin:/\{\{#/,end:/\}\}/,contains:[y]},{className:"template-tag",begin:/\{\{(?=else\}\})/,end:/\}\}/,keywords:"else"},{className:"template-tag",begin:/\{\{(?=else if)/,end:/\}\}/,keywords:"else if"},{className:"template-tag",begin:/\{\{\//,end:/\}\}/,contains:[w]},{className:"template-variable",begin:/\{\{\{/,end:/\}\}\}/,contains:[O]},{className:"template-variable",begin:/\{\{/,end:/\}\}/,contains:[O]}]}}e.exports=t},74192:function(e){function t(e){const t={variants:[e.COMMENT("--","$"),e.COMMENT(/\{-/,/-\}/,{contains:["self"]})]},n={className:"meta",begin:/\{-#/,end:/#-\}/},r={className:"meta",begin:"^#",end:"$"},i={className:"type",begin:"\\b[A-Z][\\w']*",relevance:0},o={begin:"\\(",end:"\\)",illegal:'"',contains:[n,r,{className:"type",begin:"\\b[A-Z][\\w]*(\\((\\.\\.|,|\\w+)\\))?"},e.inherit(e.TITLE_MODE,{begin:"[_a-z][\\w']*"}),t]},a={begin:/\{/,end:/\}/,contains:o.contains},s="([0-9]_*)+",l="([0-9a-fA-F]_*)+",c="([01]_*)+",u="([0-7]_*)+",d={className:"number",relevance:0,variants:[{match:`\\b(${s})(\\.(${s}))?([eE][+-]?(${s}))?\\b`},{match:`\\b0[xX]_*(${l})(\\.(${l}))?([pP][+-]?(${s}))?\\b`},{match:`\\b0[oO](${u})\\b`},{match:`\\b0[bB](${c})\\b`}]};return{name:"Haskell",aliases:["hs"],keywords:"let in if then else case of where do module import hiding qualified type data newtype deriving class instance as default infix infixl infixr foreign export ccall stdcall cplusplus jvm dotnet safe unsafe family forall mdo proc rec",contains:[{beginKeywords:"module",end:"where",keywords:"module where",contains:[o,t],illegal:"\\W\\.|;"},{begin:"\\bimport\\b",end:"$",keywords:"import qualified as hiding",contains:[o,t],illegal:"\\W\\.|;"},{className:"class",begin:"^(\\s*)?(class|instance)\\b",end:"where",keywords:"class family instance where",contains:[i,o,t]},{className:"class",begin:"\\b(data|(new)?type)\\b",end:"$",keywords:"data family type newtype deriving",contains:[n,i,o,a,t]},{beginKeywords:"default",end:"$",contains:[i,o,t]},{beginKeywords:"infix infixl infixr",end:"$",contains:[e.C_NUMBER_MODE,t]},{begin:"\\bforeign\\b",end:"$",keywords:"foreign import export ccall stdcall cplusplus jvm dotnet safe unsafe",contains:[i,e.QUOTE_STRING_MODE,t]},{className:"meta",begin:"#!\\/usr\\/bin\\/env runhaskell",end:"$"},n,r,e.QUOTE_STRING_MODE,d,i,e.inherit(e.TITLE_MODE,{begin:"^[_a-z][\\w']*"}),t,{begin:"->|<-"}]}}e.exports=t},99682:function(e){function t(e){const t=e.regex,n={className:"number",relevance:0,variants:[{begin:/([+-]+)?[\d]+_[\d_]+/},{begin:e.NUMBER_RE}]},r=e.COMMENT();r.variants=[{begin:/;/,end:/$/},{begin:/#/,end:/$/}];const i={className:"variable",variants:[{begin:/\$[\w\d"][\w\d_]*/},{begin:/\$\{(.*?)\}/}]},o={className:"literal",begin:/\bon|off|true|false|yes|no\b/},a={className:"string",contains:[e.BACKSLASH_ESCAPE],variants:[{begin:"'''",end:"'''",relevance:10},{begin:'"""',end:'"""',relevance:10},{begin:'"',end:'"'},{begin:"'",end:"'"}]},s={begin:/\[/,end:/\]/,contains:[r,o,i,a,n,"self"],relevance:0},l=/[A-Za-z0-9_-]+/,c=/"(\\"|[^"])*"/,u=/'[^']*'/,d=t.either(l,c,u),h=t.concat(d,"(\\s*\\.\\s*",d,")*",t.lookahead(/\s*=\s*[^#\s]/));return{name:"TOML, also INI",aliases:["toml"],case_insensitive:!0,illegal:/\S/,contains:[r,{className:"section",begin:/\[+/,end:/\]+/},{begin:h,className:"attr",starts:{end:/$/,contains:[r,s,o,i,a,n]}}]}}e.exports=t},26418:function(e){var t="[0-9](_*[0-9])*",n=`\\.(${t})`,r="[0-9a-fA-F](_*[0-9a-fA-F])*",i={className:"number",variants:[{begin:`(\\b(${t})((${n})|\\.)?|(${n}))[eE][+-]?(${t})[fFdD]?\\b`},{begin:`\\b(${t})((${n})[fFdD]?\\b|\\.([fFdD]\\b)?)`},{begin:`(${n})[fFdD]?\\b`},{begin:`\\b(${t})[fFdD]\\b`},{begin:`\\b0[xX]((${r})\\.?|(${r})?\\.(${r}))[pP][+-]?(${t})[fFdD]?\\b`},{begin:"\\b(0|[1-9](_*[0-9])*)[lL]?\\b"},{begin:`\\b0[xX](${r})[lL]?\\b`},{begin:"\\b0(_*[0-7])*[lL]?\\b"},{begin:"\\b0[bB][01](_*[01])*[lL]?\\b"}],relevance:0};function o(e,t,n){return-1===n?"":e.replace(t,r=>o(e,t,n-1))}function a(e){const t=e.regex,n="[À-ʸa-zA-Z_$][À-ʸa-zA-Z_$0-9]*",r=n+o("(?:<"+n+"~~~(?:\\s*,\\s*"+n+"~~~)*>)?",/~~~/g,2),a=["synchronized","abstract","private","var","static","if","const ","for","while","strictfp","finally","protected","import","native","final","void","enum","else","break","transient","catch","instanceof","volatile","case","assert","package","default","public","try","switch","continue","throws","protected","public","private","module","requires","exports","do","sealed"],s=["super","this"],l=["false","true","null"],c=["char","boolean","long","float","int","byte","short","double"],u={keyword:a,literal:l,type:c,built_in:s},d={className:"meta",begin:"@"+n,contains:[{begin:/\(/,end:/\)/,contains:["self"]}]},h={className:"params",begin:/\(/,end:/\)/,keywords:u,relevance:0,contains:[e.C_BLOCK_COMMENT_MODE],endsParent:!0};return{name:"Java",aliases:["jsp"],keywords:u,illegal:/<\/|#/,contains:[e.COMMENT("/\\*\\*","\\*/",{relevance:0,contains:[{begin:/\w+@/,relevance:0},{className:"doctag",begin:"@[A-Za-z]+"}]}),{begin:/import java\.[a-z]+\./,keywords:"import",relevance:2},e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,{begin:/"""/,end:/"""/,className:"string",contains:[e.BACKSLASH_ESCAPE]},e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,{match:[/\b(?:class|interface|enum|extends|implements|new)/,/\s+/,n],className:{1:"keyword",3:"title.class"}},{match:/non-sealed/,scope:"keyword"},{begin:[t.concat(/(?!else)/,n),/\s+/,n,/\s+/,/=(?!=)/],className:{1:"type",3:"variable",5:"operator"}},{begin:[/record/,/\s+/,n],className:{1:"keyword",3:"title.class"},contains:[h,e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE]},{beginKeywords:"new throw return else",relevance:0},{begin:["(?:"+r+"\\s+)",e.UNDERSCORE_IDENT_RE,/\s*(?=\()/],className:{2:"title.function"},keywords:u,contains:[{className:"params",begin:/\(/,end:/\)/,keywords:u,relevance:0,contains:[d,e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,i,e.C_BLOCK_COMMENT_MODE]},e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE]},i,d]}}e.exports=a},73113:function(e){const t="[A-Za-z$_][0-9A-Za-z$_]*",n=["as","in","of","if","for","while","finally","var","new","function","do","return","void","else","break","catch","instanceof","with","throw","case","default","try","switch","continue","typeof","delete","let","yield","const","class","debugger","async","await","static","import","from","export","extends"],r=["true","false","null","undefined","NaN","Infinity"],i=["Object","Function","Boolean","Symbol","Math","Date","Number","BigInt","String","RegExp","Array","Float32Array","Float64Array","Int8Array","Uint8Array","Uint8ClampedArray","Int16Array","Int32Array","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array","Set","Map","WeakSet","WeakMap","ArrayBuffer","SharedArrayBuffer","Atomics","DataView","JSON","Promise","Generator","GeneratorFunction","AsyncFunction","Reflect","Proxy","Intl","WebAssembly"],o=["Error","EvalError","InternalError","RangeError","ReferenceError","SyntaxError","TypeError","URIError"],a=["setInterval","setTimeout","clearInterval","clearTimeout","require","exports","eval","isFinite","isNaN","parseFloat","parseInt","decodeURI","decodeURIComponent","encodeURI","encodeURIComponent","escape","unescape"],s=["arguments","this","super","console","window","document","localStorage","module","global"],l=[].concat(a,i,o);function c(e){const c=e.regex,u=(e,{after:t})=>{const n="</"+e[0].slice(1),r=e.input.indexOf(n,t);return-1!==r},d=t,h={begin:"<>",end:"</>"},p=/<[A-Za-z0-9\\._:-]+\s*\/>/,f={begin:/<[A-Za-z0-9\\._:-]+/,end:/\/[A-Za-z0-9\\._:-]+>|\/>/,isTrulyOpeningTag:(e,t)=>{const n=e[0].length+e.index,r=e.input[n];if("<"===r||","===r)return void t.ignoreMatch();let i;">"===r&&(u(e,{after:n})||t.ignoreMatch());const o=e.input.substring(n);(i=o.match(/^\s+extends\s+/))&&0===i.index&&t.ignoreMatch()}},m={$pattern:t,keyword:n,literal:r,built_in:l,"variable.language":s},g="[0-9](_?[0-9])*",v=`\\.(${g})`,b="0|[1-9](_?[0-9])*|0[0-7]*[89][0-9]*",y={className:"number",variants:[{begin:`(\\b(${b})((${v})|\\.)?|(${v}))[eE][+-]?(${g})\\b`},{begin:`\\b(${b})\\b((${v})\\b|\\.)?|(${v})\\b`},{begin:"\\b(0|[1-9](_?[0-9])*)n\\b"},{begin:"\\b0[xX][0-9a-fA-F](_?[0-9a-fA-F])*n?\\b"},{begin:"\\b0[bB][0-1](_?[0-1])*n?\\b"},{begin:"\\b0[oO][0-7](_?[0-7])*n?\\b"},{begin:"\\b0[0-7]+n?\\b"}],relevance:0},w={className:"subst",begin:"\\$\\{",end:"\\}",keywords:m,contains:[]},O={begin:"html`",end:"",starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,w],subLanguage:"xml"}},S={begin:"css`",end:"",starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,w],subLanguage:"css"}},E={className:"string",begin:"`",end:"`",contains:[e.BACKSLASH_ESCAPE,w]},x=e.COMMENT(/\/\*\*(?!\/)/,"\\*/",{relevance:0,contains:[{begin:"(?=@[A-Za-z]+)",relevance:0,contains:[{className:"doctag",begin:"@[A-Za-z]+"},{className:"type",begin:"\\{",end:"\\}",excludeEnd:!0,excludeBegin:!0,relevance:0},{className:"variable",begin:d+"(?=\\s*(-)|$)",endsParent:!0,relevance:0},{begin:/(?=[^\n])\s/,relevance:0}]}]}),_={className:"comment",variants:[x,e.C_BLOCK_COMMENT_MODE,e.C_LINE_COMMENT_MODE]},k=[e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,O,S,E,y];w.contains=k.concat({begin:/\{/,end:/\}/,keywords:m,contains:["self"].concat(k)});const C=[].concat(_,w.contains),A=C.concat([{begin:/\(/,end:/\)/,keywords:m,contains:["self"].concat(C)}]),T={className:"params",begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:m,contains:A},R={variants:[{match:[/class/,/\s+/,d,/\s+/,/extends/,/\s+/,c.concat(d,"(",c.concat(/\./,d),")*")],scope:{1:"keyword",3:"title.class",5:"keyword",7:"title.class.inherited"}},{match:[/class/,/\s+/,d],scope:{1:"keyword",3:"title.class"}}]},N={relevance:0,match:c.either(/\bJSON/,/\b[A-Z][a-z]+([A-Z][a-z]*|\d)*/,/\b[A-Z]{2,}([A-Z][a-z]+|\d)+([A-Z][a-z]*)*/,/\b[A-Z]{2,}[a-z]+([A-Z][a-z]+|\d)*([A-Z][a-z]*)*/),className:"title.class",keywords:{_:[...i,...o]}},P={label:"use_strict",className:"meta",relevance:10,begin:/^\s*['"]use (strict|asm)['"]/},I={variants:[{match:[/function/,/\s+/,d,/(?=\s*\()/]},{match:[/function/,/\s*(?=\()/]}],className:{1:"keyword",3:"title.function"},label:"func.def",contains:[T],illegal:/%/},M={relevance:0,match:/\b[A-Z][A-Z_0-9]+\b/,className:"variable.constant"};function D(e){return c.concat("(?!",e.join("|"),")")}const L={match:c.concat(/\b/,D([...a,"super"]),d,c.lookahead(/\(/)),className:"title.function",relevance:0},B={begin:c.concat(/\./,c.lookahead(c.concat(d,/(?![0-9A-Za-z$_(])/))),end:d,excludeBegin:!0,keywords:"prototype",className:"property",relevance:0},$={match:[/get|set/,/\s+/,d,/(?=\()/],className:{1:"keyword",3:"title.function"},contains:[{begin:/\(\)/},T]},V="(\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)|"+e.UNDERSCORE_IDENT_RE+")\\s*=>",F={match:[/const|var|let/,/\s+/,d,/\s*/,/=\s*/,/(async\s*)?/,c.lookahead(V)],keywords:"async",className:{1:"keyword",3:"title.function"},contains:[T]};return{name:"Javascript",aliases:["js","jsx","mjs","cjs"],keywords:m,exports:{PARAMS_CONTAINS:A,CLASS_REFERENCE:N},illegal:/#(?![$_A-z])/,contains:[e.SHEBANG({label:"shebang",binary:"node",relevance:5}),P,e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,O,S,E,_,y,N,{className:"attr",begin:d+c.lookahead(":"),relevance:0},F,{begin:"("+e.RE_STARTERS_RE+"|\\b(case|return|throw)\\b)\\s*",keywords:"return throw case",relevance:0,contains:[_,e.REGEXP_MODE,{className:"function",begin:V,returnBegin:!0,end:"\\s*=>",contains:[{className:"params",variants:[{begin:e.UNDERSCORE_IDENT_RE,relevance:0},{className:null,begin:/\(\s*\)/,skip:!0},{begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:m,contains:A}]}]},{begin:/,/,relevance:0},{match:/\s+/,relevance:0},{variants:[{begin:h.begin,end:h.end},{match:p},{begin:f.begin,"on:begin":f.isTrulyOpeningTag,end:f.end}],subLanguage:"xml",contains:[{begin:f.begin,end:f.end,skip:!0,contains:["self"]}]}]},I,{beginKeywords:"while if switch catch for"},{begin:"\\b(?!function)"+e.UNDERSCORE_IDENT_RE+"\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)\\s*\\{",returnBegin:!0,label:"func.def",contains:[T,e.inherit(e.TITLE_MODE,{begin:d,className:"title.function"})]},{match:/\.\.\./,relevance:0},B,{match:"\\$"+d,relevance:0},{match:[/\bconstructor(?=\s*\()/],className:{1:"title.function"},contains:[T]},L,M,R,$,{match:/\$[(.]/}]}}e.exports=c},90020:function(e){function t(e){const t={className:"attr",begin:/"(\\.|[^\\"\r\n])*"(?=\s*:)/,relevance:1.01},n={match:/[{}[\],:]/,className:"punctuation",relevance:0},r=["true","false","null"],i={scope:"literal",beginKeywords:r.join(" ")};return{name:"JSON",keywords:{literal:r},contains:[t,n,e.QUOTE_STRING_MODE,i,e.C_NUMBER_MODE,e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE],illegal:"\\S"}}e.exports=t},44063:function(e){var t="[0-9](_*[0-9])*",n=`\\.(${t})`,r="[0-9a-fA-F](_*[0-9a-fA-F])*",i={className:"number",variants:[{begin:`(\\b(${t})((${n})|\\.)?|(${n}))[eE][+-]?(${t})[fFdD]?\\b`},{begin:`\\b(${t})((${n})[fFdD]?\\b|\\.([fFdD]\\b)?)`},{begin:`(${n})[fFdD]?\\b`},{begin:`\\b(${t})[fFdD]\\b`},{begin:`\\b0[xX]((${r})\\.?|(${r})?\\.(${r}))[pP][+-]?(${t})[fFdD]?\\b`},{begin:"\\b(0|[1-9](_*[0-9])*)[lL]?\\b"},{begin:`\\b0[xX](${r})[lL]?\\b`},{begin:"\\b0(_*[0-7])*[lL]?\\b"},{begin:"\\b0[bB][01](_*[01])*[lL]?\\b"}],relevance:0};function o(e){const t={keyword:"abstract as val var vararg get set class object open private protected public noinline crossinline dynamic final enum if else do while for when throw try catch finally import package is in fun override companion reified inline lateinit init interface annotation data sealed internal infix operator out by constructor super tailrec where const inner suspend typealias external expect actual",built_in:"Byte Short Char Int Long Boolean Float Double Void Unit Nothing",literal:"true false null"},n={className:"keyword",begin:/\b(break|continue|return|this)\b/,starts:{contains:[{className:"symbol",begin:/@\w+/}]}},r={className:"symbol",begin:e.UNDERSCORE_IDENT_RE+"@"},o={className:"subst",begin:/\$\{/,end:/\}/,contains:[e.C_NUMBER_MODE]},a={className:"variable",begin:"\\$"+e.UNDERSCORE_IDENT_RE},s={className:"string",variants:[{begin:'"""',end:'"""(?=[^"])',contains:[a,o]},{begin:"'",end:"'",illegal:/\n/,contains:[e.BACKSLASH_ESCAPE]},{begin:'"',end:'"',illegal:/\n/,contains:[e.BACKSLASH_ESCAPE,a,o]}]};o.contains.push(s);const l={className:"meta",begin:"@(?:file|property|field|get|set|receiver|param|setparam|delegate)\\s*:(?:\\s*"+e.UNDERSCORE_IDENT_RE+")?"},c={className:"meta",begin:"@"+e.UNDERSCORE_IDENT_RE,contains:[{begin:/\(/,end:/\)/,contains:[e.inherit(s,{className:"string"}),"self"]}]},u=i,d=e.COMMENT("/\\*","\\*/",{contains:[e.C_BLOCK_COMMENT_MODE]}),h={variants:[{className:"type",begin:e.UNDERSCORE_IDENT_RE},{begin:/\(/,end:/\)/,contains:[]}]},p=h;return p.variants[1].contains=[h],h.variants[1].contains=[p],{name:"Kotlin",aliases:["kt","kts"],keywords:t,contains:[e.COMMENT("/\\*\\*","\\*/",{relevance:0,contains:[{className:"doctag",begin:"@[A-Za-z]+"}]}),e.C_LINE_COMMENT_MODE,d,n,r,l,c,{className:"function",beginKeywords:"fun",end:"[(]|$",returnBegin:!0,excludeEnd:!0,keywords:t,relevance:5,contains:[{begin:e.UNDERSCORE_IDENT_RE+"\\s*\\(",returnBegin:!0,relevance:0,contains:[e.UNDERSCORE_TITLE_MODE]},{className:"type",begin:/</,end:/>/,keywords:"reified",relevance:0},{className:"params",begin:/\(/,end:/\)/,endsParent:!0,keywords:t,relevance:0,contains:[{begin:/:/,end:/[=,\/]/,endsWithParent:!0,contains:[h,e.C_LINE_COMMENT_MODE,d],relevance:0},e.C_LINE_COMMENT_MODE,d,l,c,s,e.C_NUMBER_MODE]},d]},{begin:[/class|interface|trait/,/\s+/,e.UNDERSCORE_IDENT_RE],beginScope:{3:"title.class"},keywords:"class interface trait",end:/[:\{(]|$/,excludeEnd:!0,illegal:"extends implements",contains:[{beginKeywords:"public protected internal private constructor"},e.UNDERSCORE_TITLE_MODE,{className:"type",begin:/</,end:/>/,excludeBegin:!0,excludeEnd:!0,relevance:0},{className:"type",begin:/[,:]\s*/,end:/[<\(,){\s]|$/,excludeBegin:!0,returnEnd:!0},l,c]},s,{className:"meta",begin:"^#!/usr/bin/env",end:"$",illegal:"\n"},u]}}e.exports=o},1075:function(e){const t=e=>({IMPORTANT:{scope:"meta",begin:"!important"},BLOCK_COMMENT:e.C_BLOCK_COMMENT_MODE,HEXCOLOR:{scope:"number",begin:/#(([0-9a-fA-F]{3,4})|(([0-9a-fA-F]{2}){3,4}))\b/},FUNCTION_DISPATCH:{className:"built_in",begin:/[\w-]+(?=\()/},ATTRIBUTE_SELECTOR_MODE:{scope:"selector-attr",begin:/\[/,end:/\]/,illegal:"$",contains:[e.APOS_STRING_MODE,e.QUOTE_STRING_MODE]},CSS_NUMBER_MODE:{scope:"number",begin:e.NUMBER_RE+"(%|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc|px|deg|grad|rad|turn|s|ms|Hz|kHz|dpi|dpcm|dppx)?",relevance:0},CSS_VARIABLE:{className:"attr",begin:/--[A-Za-z][A-Za-z0-9_-]*/}}),n=["a","abbr","address","article","aside","audio","b","blockquote","body","button","canvas","caption","cite","code","dd","del","details","dfn","div","dl","dt","em","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hgroup","html","i","iframe","img","input","ins","kbd","label","legend","li","main","mark","menu","nav","object","ol","p","q","quote","samp","section","span","strong","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","tr","ul","var","video"],r=["any-hover","any-pointer","aspect-ratio","color","color-gamut","color-index","device-aspect-ratio","device-height","device-width","display-mode","forced-colors","grid","height","hover","inverted-colors","monochrome","orientation","overflow-block","overflow-inline","pointer","prefers-color-scheme","prefers-contrast","prefers-reduced-motion","prefers-reduced-transparency","resolution","scan","scripting","update","width","min-width","max-width","min-height","max-height"],i=["active","any-link","blank","checked","current","default","defined","dir","disabled","drop","empty","enabled","first","first-child","first-of-type","fullscreen","future","focus","focus-visible","focus-within","has","host","host-context","hover","indeterminate","in-range","invalid","is","lang","last-child","last-of-type","left","link","local-link","not","nth-child","nth-col","nth-last-child","nth-last-col","nth-last-of-type","nth-of-type","only-child","only-of-type","optional","out-of-range","past","placeholder-shown","read-only","read-write","required","right","root","scope","target","target-within","user-invalid","valid","visited","where"],o=["after","backdrop","before","cue","cue-region","first-letter","first-line","grammar-error","marker","part","placeholder","selection","slotted","spelling-error"],a=["align-content","align-items","align-self","all","animation","animation-delay","animation-direction","animation-duration","animation-fill-mode","animation-iteration-count","animation-name","animation-play-state","animation-timing-function","backface-visibility","background","background-attachment","background-blend-mode","background-clip","background-color","background-image","background-origin","background-position","background-repeat","background-size","block-size","border","border-block","border-block-color","border-block-end","border-block-end-color","border-block-end-style","border-block-end-width","border-block-start","border-block-start-color","border-block-start-style","border-block-start-width","border-block-style","border-block-width","border-bottom","border-bottom-color","border-bottom-left-radius","border-bottom-right-radius","border-bottom-style","border-bottom-width","border-collapse","border-color","border-image","border-image-outset","border-image-repeat","border-image-slice","border-image-source","border-image-width","border-inline","border-inline-color","border-inline-end","border-inline-end-color","border-inline-end-style","border-inline-end-width","border-inline-start","border-inline-start-color","border-inline-start-style","border-inline-start-width","border-inline-style","border-inline-width","border-left","border-left-color","border-left-style","border-left-width","border-radius","border-right","border-right-color","border-right-style","border-right-width","border-spacing","border-style","border-top","border-top-color","border-top-left-radius","border-top-right-radius","border-top-style","border-top-width","border-width","bottom","box-decoration-break","box-shadow","box-sizing","break-after","break-before","break-inside","caption-side","caret-color","clear","clip","clip-path","clip-rule","color","column-count","column-fill","column-gap","column-rule","column-rule-color","column-rule-style","column-rule-width","column-span","column-width","columns","contain","content","content-visibility","counter-increment","counter-reset","cue","cue-after","cue-before","cursor","direction","display","empty-cells","filter","flex","flex-basis","flex-direction","flex-flow","flex-grow","flex-shrink","flex-wrap","float","flow","font","font-display","font-family","font-feature-settings","font-kerning","font-language-override","font-size","font-size-adjust","font-smoothing","font-stretch","font-style","font-synthesis","font-variant","font-variant-caps","font-variant-east-asian","font-variant-ligatures","font-variant-numeric","font-variant-position","font-variation-settings","font-weight","gap","glyph-orientation-vertical","grid","grid-area","grid-auto-columns","grid-auto-flow","grid-auto-rows","grid-column","grid-column-end","grid-column-start","grid-gap","grid-row","grid-row-end","grid-row-start","grid-template","grid-template-areas","grid-template-columns","grid-template-rows","hanging-punctuation","height","hyphens","icon","image-orientation","image-rendering","image-resolution","ime-mode","inline-size","isolation","justify-content","left","letter-spacing","line-break","line-height","list-style","list-style-image","list-style-position","list-style-type","margin","margin-block","margin-block-end","margin-block-start","margin-bottom","margin-inline","margin-inline-end","margin-inline-start","margin-left","margin-right","margin-top","marks","mask","mask-border","mask-border-mode","mask-border-outset","mask-border-repeat","mask-border-slice","mask-border-source","mask-border-width","mask-clip","mask-composite","mask-image","mask-mode","mask-origin","mask-position","mask-repeat","mask-size","mask-type","max-block-size","max-height","max-inline-size","max-width","min-block-size","min-height","min-inline-size","min-width","mix-blend-mode","nav-down","nav-index","nav-left","nav-right","nav-up","none","normal","object-fit","object-position","opacity","order","orphans","outline","outline-color","outline-offset","outline-style","outline-width","overflow","overflow-wrap","overflow-x","overflow-y","padding","padding-block","padding-block-end","padding-block-start","padding-bottom","padding-inline","padding-inline-end","padding-inline-start","padding-left","padding-right","padding-top","page-break-after","page-break-before","page-break-inside","pause","pause-after","pause-before","perspective","perspective-origin","pointer-events","position","quotes","resize","rest","rest-after","rest-before","right","row-gap","scroll-margin","scroll-margin-block","scroll-margin-block-end","scroll-margin-block-start","scroll-margin-bottom","scroll-margin-inline","scroll-margin-inline-end","scroll-margin-inline-start","scroll-margin-left","scroll-margin-right","scroll-margin-top","scroll-padding","scroll-padding-block","scroll-padding-block-end","scroll-padding-block-start","scroll-padding-bottom","scroll-padding-inline","scroll-padding-inline-end","scroll-padding-inline-start","scroll-padding-left","scroll-padding-right","scroll-padding-top","scroll-snap-align","scroll-snap-stop","scroll-snap-type","scrollbar-color","scrollbar-gutter","scrollbar-width","shape-image-threshold","shape-margin","shape-outside","speak","speak-as","src","tab-size","table-layout","text-align","text-align-all","text-align-last","text-combine-upright","text-decoration","text-decoration-color","text-decoration-line","text-decoration-style","text-emphasis","text-emphasis-color","text-emphasis-position","text-emphasis-style","text-indent","text-justify","text-orientation","text-overflow","text-rendering","text-shadow","text-transform","text-underline-position","top","transform","transform-box","transform-origin","transform-style","transition","transition-delay","transition-duration","transition-property","transition-timing-function","unicode-bidi","vertical-align","visibility","voice-balance","voice-duration","voice-family","voice-pitch","voice-range","voice-rate","voice-stress","voice-volume","white-space","widows","width","will-change","word-break","word-spacing","word-wrap","writing-mode","z-index"].reverse(),s=i.concat(o);function l(e){const l=t(e),c=s,u="and or not only",d="[\\w-]+",h="("+d+"|@\\{"+d+"\\})",p=[],f=[],m=function(e){return{className:"string",begin:"~?"+e+".*?"+e}},g=function(e,t,n){return{className:e,begin:t,relevance:n}},v={$pattern:/[a-z-]+/,keyword:u,attribute:r.join(" ")},b={begin:"\\(",end:"\\)",contains:f,keywords:v,relevance:0};f.push(e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,m("'"),m('"'),l.CSS_NUMBER_MODE,{begin:"(url|data-uri)\\(",starts:{className:"string",end:"[\\)\\n]",excludeEnd:!0}},l.HEXCOLOR,b,g("variable","@@?"+d,10),g("variable","@\\{"+d+"\\}"),g("built_in","~?`[^`]*?`"),{className:"attribute",begin:d+"\\s*:",end:":",returnBegin:!0,excludeEnd:!0},l.IMPORTANT,{beginKeywords:"and not"},l.FUNCTION_DISPATCH);const y=f.concat({begin:/\{/,end:/\}/,contains:p}),w={beginKeywords:"when",endsWithParent:!0,contains:[{beginKeywords:"and not"}].concat(f)},O={begin:h+"\\s*:",returnBegin:!0,end:/[;}]/,relevance:0,contains:[{begin:/-(webkit|moz|ms|o)-/},l.CSS_VARIABLE,{className:"attribute",begin:"\\b("+a.join("|")+")\\b",end:/(?=:)/,starts:{endsWithParent:!0,illegal:"[<=$]",relevance:0,contains:f}}]},S={className:"keyword",begin:"@(import|media|charset|font-face|(-[a-z]+-)?keyframes|supports|document|namespace|page|viewport|host)\\b",starts:{end:"[;{}]",keywords:v,returnEnd:!0,contains:f,relevance:0}},E={className:"variable",variants:[{begin:"@"+d+"\\s*:",relevance:15},{begin:"@"+d}],starts:{end:"[;}]",returnEnd:!0,contains:y}},x={variants:[{begin:"[\\.#:&\\[>]",end:"[;{}]"},{begin:h,end:/\{/}],returnBegin:!0,returnEnd:!0,illegal:"[<='$\"]",relevance:0,contains:[e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,w,g("keyword","all\\b"),g("variable","@\\{"+d+"\\}"),{begin:"\\b("+n.join("|")+")\\b",className:"selector-tag"},l.CSS_NUMBER_MODE,g("selector-tag",h,0),g("selector-id","#"+h),g("selector-class","\\."+h,0),g("selector-tag","&",0),l.ATTRIBUTE_SELECTOR_MODE,{className:"selector-pseudo",begin:":("+i.join("|")+")"},{className:"selector-pseudo",begin:":(:)?("+o.join("|")+")"},{begin:/\(/,end:/\)/,relevance:0,contains:y},{begin:"!important"},l.FUNCTION_DISPATCH]},_={begin:d+":(:)?"+`(${c.join("|")})`,returnBegin:!0,contains:[x]};return p.push(e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,S,E,_,O,x,w,l.FUNCTION_DISPATCH),{name:"Less",case_insensitive:!0,illegal:"[=>'/<($\"]",contains:p}}e.exports=l},8090:function(e){function t(e){const t="[a-zA-Z_\\-+\\*\\/<=>&#][a-zA-Z0-9_\\-+*\\/<=>&#!]*",n="\\|[^]*?\\|",r="(-|\\+)?\\d+(\\.\\d+|\\/\\d+)?((d|e|f|l|s|D|E|F|L|S)(\\+|-)?\\d+)?",i={className:"literal",begin:"\\b(t{1}|nil)\\b"},o={className:"number",variants:[{begin:r,relevance:0},{begin:"#(b|B)[0-1]+(/[0-1]+)?"},{begin:"#(o|O)[0-7]+(/[0-7]+)?"},{begin:"#(x|X)[0-9a-fA-F]+(/[0-9a-fA-F]+)?"},{begin:"#(c|C)\\("+r+" +"+r,end:"\\)"}]},a=e.inherit(e.QUOTE_STRING_MODE,{illegal:null}),s=e.COMMENT(";","$",{relevance:0}),l={begin:"\\*",end:"\\*"},c={className:"symbol",begin:"[:&]"+t},u={begin:t,relevance:0},d={begin:n},h={begin:"\\(",end:"\\)",contains:["self",i,a,o,u]},p={contains:[o,a,l,c,h,u],variants:[{begin:"['`]\\(",end:"\\)"},{begin:"\\(quote ",end:"\\)",keywords:{name:"quote"}},{begin:"'"+n}]},f={variants:[{begin:"'"+t},{begin:"#'"+t+"(::"+t+")*"}]},m={begin:"\\(\\s*",end:"\\)"},g={endsWithParent:!0,relevance:0};return m.contains=[{className:"name",variants:[{begin:t,relevance:0},{begin:n}]},g],g.contains=[p,f,m,i,o,a,s,l,c,d,u],{name:"Lisp",illegal:/\S/,contains:[o,e.SHEBANG(),i,a,s,p,f,m,u]}}e.exports=t},77190:function(e){function t(e){const t="\\[=*\\[",n="\\]=*\\]",r={begin:t,end:n,contains:["self"]},i=[e.COMMENT("--(?!"+t+")","$"),e.COMMENT("--"+t,n,{contains:[r],relevance:10})];return{name:"Lua",keywords:{$pattern:e.UNDERSCORE_IDENT_RE,literal:"true false nil",keyword:"and break do else elseif end for goto if in local not or repeat return then until while",built_in:"_G _ENV _VERSION __index __newindex __mode __call __metatable __tostring __len __gc __add __sub __mul __div __mod __pow __concat __unm __eq __lt __le assert collectgarbage dofile error getfenv getmetatable ipairs load loadfile loadstring module next pairs pcall print rawequal rawget rawset require select setfenv setmetatable tonumber tostring type unpack xpcall arg self coroutine resume yield status wrap create running debug getupvalue debug sethook getmetatable gethook setmetatable setlocal traceback setfenv getinfo setupvalue getlocal getregistry getfenv io lines write close flush open output type read stderr stdin input stdout popen tmpfile math log max acos huge ldexp pi cos tanh pow deg tan cosh sinh random randomseed frexp ceil floor rad abs sqrt modf asin min mod fmod log10 atan2 exp sin atan os exit setlocale date getenv difftime remove time clock tmpname rename execute package preload loadlib loaded loaders cpath config path seeall string sub upper len gfind rep find match char dump gmatch reverse byte format gsub lower table setn insert getn foreachi maxn foreach concat sort remove"},contains:i.concat([{className:"function",beginKeywords:"function",end:"\\)",contains:[e.inherit(e.TITLE_MODE,{begin:"([_a-zA-Z]\\w*\\.)*([_a-zA-Z]\\w*:)?[_a-zA-Z]\\w*"}),{className:"params",begin:"\\(",endsWithParent:!0,contains:i}].concat(i)},e.C_NUMBER_MODE,e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,{className:"string",begin:t,end:n,contains:[r],relevance:5}])}}e.exports=t},30374:function(e){function t(e){const t={className:"variable",variants:[{begin:"\\$\\("+e.UNDERSCORE_IDENT_RE+"\\)",contains:[e.BACKSLASH_ESCAPE]},{begin:/\$[@%<?\^\+\*]/}]},n={className:"string",begin:/"/,end:/"/,contains:[e.BACKSLASH_ESCAPE,t]},r={className:"variable",begin:/\$\([\w-]+\s/,end:/\)/,keywords:{built_in:"subst patsubst strip findstring filter filter-out sort word wordlist firstword lastword dir notdir suffix basename addsuffix addprefix join wildcard realpath abspath error warning shell origin flavor foreach if or and call eval file value"},contains:[t]},i={begin:"^"+e.UNDERSCORE_IDENT_RE+"\\s*(?=[:+?]?=)"},o={className:"meta",begin:/^\.PHONY:/,end:/$/,keywords:{$pattern:/[\.\w]+/,keyword:".PHONY"}},a={className:"section",begin:/^[^\s]+:/,end:/$/,contains:[t]};return{name:"Makefile",aliases:["mk","mak","make"],keywords:{$pattern:/[\w-]+/,keyword:"define endef undefine ifdef ifndef ifeq ifneq else endif include -include sinclude override export unexport private vpath"},contains:[e.HASH_COMMENT_MODE,t,n,r,i,o,a]}}e.exports=t},50687:function(e){function t(e){const t=e.regex,n={begin:/<\/?[A-Za-z_]/,end:">",subLanguage:"xml",relevance:0},r={begin:"^[-\\*]{3,}",end:"$"},i={className:"code",variants:[{begin:"(`{3,})[^`](.|\\n)*?\\1`*[ ]*"},{begin:"(~{3,})[^~](.|\\n)*?\\1~*[ ]*"},{begin:"```",end:"```+[ ]*$"},{begin:"~~~",end:"~~~+[ ]*$"},{begin:"`.+?`"},{begin:"(?=^( {4}|\\t))",contains:[{begin:"^( {4}|\\t)",end:"(\\n)$"}],relevance:0}]},o={className:"bullet",begin:"^[ \t]*([*+-]|(\\d+\\.))(?=\\s+)",end:"\\s+",excludeEnd:!0},a={begin:/^\[[^\n]+\]:/,returnBegin:!0,contains:[{className:"symbol",begin:/\[/,end:/\]/,excludeBegin:!0,excludeEnd:!0},{className:"link",begin:/:\s*/,end:/$/,excludeBegin:!0}]},s=/[A-Za-z][A-Za-z0-9+.-]*/,l={variants:[{begin:/\[.+?\]\[.*?\]/,relevance:0},{begin:/\[.+?\]\(((data|javascript|mailto):|(?:http|ftp)s?:\/\/).*?\)/,relevance:2},{begin:t.concat(/\[.+?\]\(/,s,/:\/\/.*?\)/),relevance:2},{begin:/\[.+?\]\([./?&#].*?\)/,relevance:1},{begin:/\[.*?\]\(.*?\)/,relevance:0}],returnBegin:!0,contains:[{match:/\[(?=\])/},{className:"string",relevance:0,begin:"\\[",end:"\\]",excludeBegin:!0,returnEnd:!0},{className:"link",relevance:0,begin:"\\]\\(",end:"\\)",excludeBegin:!0,excludeEnd:!0},{className:"symbol",relevance:0,begin:"\\]\\[",end:"\\]",excludeBegin:!0,excludeEnd:!0}]},c={className:"strong",contains:[],variants:[{begin:/_{2}/,end:/_{2}/},{begin:/\*{2}/,end:/\*{2}/}]},u={className:"emphasis",contains:[],variants:[{begin:/\*(?!\*)/,end:/\*/},{begin:/_(?!_)/,end:/_/,relevance:0}]},d=e.inherit(c,{contains:[]}),h=e.inherit(u,{contains:[]});c.contains.push(h),u.contains.push(d);let p=[n,l];[c,u,d,h].forEach(e=>{e.contains=e.contains.concat(p)}),p=p.concat(c,u);const f={className:"section",variants:[{begin:"^#{1,6}",end:"$",contains:p},{begin:"(?=^.+?\\n[=-]{2,}$)",contains:[{begin:"^[=-]*$"},{begin:"^",end:"\\n",contains:p}]}]},m={className:"quote",begin:"^>\\s+",contains:p,end:"$"};return{name:"Markdown",aliases:["md","mkdown","mkd"],contains:[f,n,o,c,u,m,i,r,l,a]}}e.exports=t},86072:function(e){function t(e){const t=e.regex,n={className:"variable",variants:[{begin:/\$\d+/},{begin:/\$\{\w+\}/},{begin:t.concat(/[$@]/,e.UNDERSCORE_IDENT_RE)}]},r=["on","off","yes","no","true","false","none","blocked","debug","info","notice","warn","error","crit","select","break","last","permanent","redirect","kqueue","rtsig","epoll","poll","/dev/poll"],i={endsWithParent:!0,keywords:{$pattern:/[a-z_]{2,}|\/dev\/poll/,literal:r},relevance:0,illegal:"=>",contains:[e.HASH_COMMENT_MODE,{className:"string",contains:[e.BACKSLASH_ESCAPE,n],variants:[{begin:/"/,end:/"/},{begin:/'/,end:/'/}]},{begin:"([a-z]+):/",end:"\\s",endsWithParent:!0,excludeEnd:!0,contains:[n]},{className:"regexp",contains:[e.BACKSLASH_ESCAPE,n],variants:[{begin:"\\s\\^",end:"\\s|\\{|;",returnEnd:!0},{begin:"~\\*?\\s+",end:"\\s|\\{|;",returnEnd:!0},{begin:"\\*(\\.[a-z\\-]+)+"},{begin:"([a-z\\-]+\\.)+\\*"}]},{className:"number",begin:"\\b\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}(:\\d{1,5})?\\b"},{className:"number",begin:"\\b\\d+[kKmMgGdshdwy]?\\b",relevance:0},n]};return{name:"Nginx config",aliases:["nginxconf"],contains:[e.HASH_COMMENT_MODE,{beginKeywords:"upstream location",end:/;|\{/,contains:i.contains,keywords:{section:"upstream location"}},{className:"section",begin:t.concat(e.UNDERSCORE_IDENT_RE+t.lookahead(/\s+\{/)),relevance:0},{begin:t.lookahead(e.UNDERSCORE_IDENT_RE+"\\s"),end:";|\\{",contains:[{className:"attribute",begin:e.UNDERSCORE_IDENT_RE,starts:i}],relevance:0}],illegal:"[^\\s\\}\\{]"}}e.exports=t},69318:function(e){function t(e){const t={className:"built_in",begin:"\\b(AV|CA|CF|CG|CI|CL|CM|CN|CT|MK|MP|MTK|MTL|NS|SCN|SK|UI|WK|XC)\\w+"},n=/[a-zA-Z@][a-zA-Z0-9_]*/,r=["int","float","char","unsigned","signed","short","long","double","wchar_t","unichar","void","bool","BOOL","id|0","_Bool"],i=["while","export","sizeof","typedef","const","struct","for","union","volatile","static","mutable","if","do","return","goto","enum","else","break","extern","asm","case","default","register","explicit","typename","switch","continue","inline","readonly","assign","readwrite","self","@synchronized","id","typeof","nonatomic","IBOutlet","IBAction","strong","weak","copy","in","out","inout","bycopy","byref","oneway","__strong","__weak","__block","__autoreleasing","@private","@protected","@public","@try","@property","@end","@throw","@catch","@finally","@autoreleasepool","@synthesize","@dynamic","@selector","@optional","@required","@encode","@package","@import","@defs","@compatibility_alias","__bridge","__bridge_transfer","__bridge_retained","__bridge_retain","__covariant","__contravariant","__kindof","_Nonnull","_Nullable","_Null_unspecified","__FUNCTION__","__PRETTY_FUNCTION__","__attribute__","getter","setter","retain","unsafe_unretained","nonnull","nullable","null_unspecified","null_resettable","class","instancetype","NS_DESIGNATED_INITIALIZER","NS_UNAVAILABLE","NS_REQUIRES_SUPER","NS_RETURNS_INNER_POINTER","NS_INLINE","NS_AVAILABLE","NS_DEPRECATED","NS_ENUM","NS_OPTIONS","NS_SWIFT_UNAVAILABLE","NS_ASSUME_NONNULL_BEGIN","NS_ASSUME_NONNULL_END","NS_REFINED_FOR_SWIFT","NS_SWIFT_NAME","NS_SWIFT_NOTHROW","NS_DURING","NS_HANDLER","NS_ENDHANDLER","NS_VALUERETURN","NS_VOIDRETURN"],o=["false","true","FALSE","TRUE","nil","YES","NO","NULL"],a=["dispatch_once_t","dispatch_queue_t","dispatch_sync","dispatch_async","dispatch_once"],s={"variable.language":["this","super"],$pattern:n,keyword:i,literal:o,built_in:a,type:r},l={$pattern:n,keyword:["@interface","@class","@protocol","@implementation"]};return{name:"Objective-C",aliases:["mm","objc","obj-c","obj-c++","objective-c++"],keywords:s,illegal:"</",contains:[t,e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,e.C_NUMBER_MODE,e.QUOTE_STRING_MODE,e.APOS_STRING_MODE,{className:"string",variants:[{begin:'@"',end:'"',illegal:"\\n",contains:[e.BACKSLASH_ESCAPE]}]},{className:"meta",begin:/#\s*[a-z]+\b/,end:/$/,keywords:{keyword:"if else elif endif define undef warning error line pragma ifdef ifndef include"},contains:[{begin:/\\\n/,relevance:0},e.inherit(e.QUOTE_STRING_MODE,{className:"string"}),{className:"string",begin:/<.*?>/,end:/$/,illegal:"\\n"},e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE]},{className:"class",begin:"("+l.keyword.join("|")+")\\b",end:/(\{|$)/,excludeEnd:!0,keywords:l,contains:[e.UNDERSCORE_TITLE_MODE]},{begin:"\\."+e.UNDERSCORE_IDENT_RE,relevance:0}]}}e.exports=t},3315:function(e){function t(e){const t=e.regex,n=["abs","accept","alarm","and","atan2","bind","binmode","bless","break","caller","chdir","chmod","chomp","chop","chown","chr","chroot","close","closedir","connect","continue","cos","crypt","dbmclose","dbmopen","defined","delete","die","do","dump","each","else","elsif","endgrent","endhostent","endnetent","endprotoent","endpwent","endservent","eof","eval","exec","exists","exit","exp","fcntl","fileno","flock","for","foreach","fork","format","formline","getc","getgrent","getgrgid","getgrnam","gethostbyaddr","gethostbyname","gethostent","getlogin","getnetbyaddr","getnetbyname","getnetent","getpeername","getpgrp","getpriority","getprotobyname","getprotobynumber","getprotoent","getpwent","getpwnam","getpwuid","getservbyname","getservbyport","getservent","getsockname","getsockopt","given","glob","gmtime","goto","grep","gt","hex","if","index","int","ioctl","join","keys","kill","last","lc","lcfirst","length","link","listen","local","localtime","log","lstat","lt","ma","map","mkdir","msgctl","msgget","msgrcv","msgsnd","my","ne","next","no","not","oct","open","opendir","or","ord","our","pack","package","pipe","pop","pos","print","printf","prototype","push","q|0","qq","quotemeta","qw","qx","rand","read","readdir","readline","readlink","readpipe","recv","redo","ref","rename","require","reset","return","reverse","rewinddir","rindex","rmdir","say","scalar","seek","seekdir","select","semctl","semget","semop","send","setgrent","sethostent","setnetent","setpgrp","setpriority","setprotoent","setpwent","setservent","setsockopt","shift","shmctl","shmget","shmread","shmwrite","shutdown","sin","sleep","socket","socketpair","sort","splice","split","sprintf","sqrt","srand","stat","state","study","sub","substr","symlink","syscall","sysopen","sysread","sysseek","system","syswrite","tell","telldir","tie","tied","time","times","tr","truncate","uc","ucfirst","umask","undef","unless","unlink","unpack","unshift","untie","until","use","utime","values","vec","wait","waitpid","wantarray","warn","when","while","write","x|0","xor","y|0"],r=/[dualxmsipngr]{0,12}/,i={$pattern:/[\w.]+/,keyword:n.join(" ")},o={className:"subst",begin:"[$@]\\{",end:"\\}",keywords:i},a={begin:/->\{/,end:/\}/},s={variants:[{begin:/\$\d/},{begin:t.concat(/[$%@](\^\w\b|#\w+(::\w+)*|\{\w+\}|\w+(::\w*)*)/,"(?![A-Za-z])(?![@$%])")},{begin:/[$%@][^\s\w{]/,relevance:0}]},l=[e.BACKSLASH_ESCAPE,o,s],c=[/!/,/\//,/\|/,/\?/,/'/,/"/,/#/],u=(e,n,i="\\1")=>{const o="\\1"===i?i:t.concat(i,n);return t.concat(t.concat("(?:",e,")"),n,/(?:\\.|[^\\\/])*?/,o,/(?:\\.|[^\\\/])*?/,i,r)},d=(e,n,i)=>t.concat(t.concat("(?:",e,")"),n,/(?:\\.|[^\\\/])*?/,i,r),h=[s,e.HASH_COMMENT_MODE,e.COMMENT(/^=\w/,/=cut/,{endsWithParent:!0}),a,{className:"string",contains:l,variants:[{begin:"q[qwxr]?\\s*\\(",end:"\\)",relevance:5},{begin:"q[qwxr]?\\s*\\[",end:"\\]",relevance:5},{begin:"q[qwxr]?\\s*\\{",end:"\\}",relevance:5},{begin:"q[qwxr]?\\s*\\|",end:"\\|",relevance:5},{begin:"q[qwxr]?\\s*<",end:">",relevance:5},{begin:"qw\\s+q",end:"q",relevance:5},{begin:"'",end:"'",contains:[e.BACKSLASH_ESCAPE]},{begin:'"',end:'"'},{begin:"`",end:"`",contains:[e.BACKSLASH_ESCAPE]},{begin:/\{\w+\}/,relevance:0},{begin:"-?\\w+\\s*=>",relevance:0}]},{className:"number",begin:"(\\b0[0-7_]+)|(\\b0x[0-9a-fA-F_]+)|(\\b[1-9][0-9_]*(\\.[0-9_]+)?)|[0_]\\b",relevance:0},{begin:"(\\/\\/|"+e.RE_STARTERS_RE+"|\\b(split|return|print|reverse|grep)\\b)\\s*",keywords:"split return print reverse grep",relevance:0,contains:[e.HASH_COMMENT_MODE,{className:"regexp",variants:[{begin:u("s|tr|y",t.either(...c,{capture:!0}))},{begin:u("s|tr|y","\\(","\\)")},{begin:u("s|tr|y","\\[","\\]")},{begin:u("s|tr|y","\\{","\\}")}],relevance:2},{className:"regexp",variants:[{begin:/(m|qr)\/\//,relevance:0},{begin:d("(?:m|qr)?",/\//,/\//)},{begin:d("m|qr",t.either(...c,{capture:!0}),/\1/)},{begin:d("m|qr",/\(/,/\)/)},{begin:d("m|qr",/\[/,/\]/)},{begin:d("m|qr",/\{/,/\}/)}]}]},{className:"function",beginKeywords:"sub",end:"(\\s*\\(.*?\\))?[;{]",excludeEnd:!0,relevance:5,contains:[e.TITLE_MODE]},{begin:"-\\w\\b",relevance:0},{begin:"^__DATA__$",end:"^__END__$",subLanguage:"mojolicious",contains:[{begin:"^@@.*",end:"$",className:"comment"}]}];return o.contains=h,a.contains=h,{name:"Perl",aliases:["pl","pm"],keywords:i,contains:h}}e.exports=t},74071:function(e){function t(e){const t=e.COMMENT("--","$"),n="[a-zA-Z_][a-zA-Z_0-9$]*",r="\\$([a-zA-Z_]?|[a-zA-Z_][a-zA-Z_0-9]*)\\$",i="<<\\s*"+n+"\\s*>>",o="ABORT ALTER ANALYZE BEGIN CALL CHECKPOINT|10 CLOSE CLUSTER COMMENT COMMIT COPY CREATE DEALLOCATE DECLARE DELETE DISCARD DO DROP END EXECUTE EXPLAIN FETCH GRANT IMPORT INSERT LISTEN LOAD LOCK MOVE NOTIFY PREPARE REASSIGN|10 REFRESH REINDEX RELEASE RESET REVOKE ROLLBACK SAVEPOINT SECURITY SELECT SET SHOW START TRUNCATE UNLISTEN|10 UPDATE VACUUM|10 VALUES AGGREGATE COLLATION CONVERSION|10 DATABASE DEFAULT PRIVILEGES DOMAIN TRIGGER EXTENSION FOREIGN WRAPPER|10 TABLE FUNCTION GROUP LANGUAGE LARGE OBJECT MATERIALIZED VIEW OPERATOR CLASS FAMILY POLICY PUBLICATION|10 ROLE RULE SCHEMA SEQUENCE SERVER STATISTICS SUBSCRIPTION SYSTEM TABLESPACE CONFIGURATION DICTIONARY PARSER TEMPLATE TYPE USER MAPPING PREPARED ACCESS METHOD CAST AS TRANSFORM TRANSACTION OWNED TO INTO SESSION AUTHORIZATION INDEX PROCEDURE ASSERTION ALL ANALYSE AND ANY ARRAY ASC ASYMMETRIC|10 BOTH CASE CHECK COLLATE COLUMN CONCURRENTLY|10 CONSTRAINT CROSS DEFERRABLE RANGE DESC DISTINCT ELSE EXCEPT FOR FREEZE|10 FROM FULL HAVING ILIKE IN INITIALLY INNER INTERSECT IS ISNULL JOIN LATERAL LEADING LIKE LIMIT NATURAL NOT NOTNULL NULL OFFSET ON ONLY OR ORDER OUTER OVERLAPS PLACING PRIMARY REFERENCES RETURNING SIMILAR SOME SYMMETRIC TABLESAMPLE THEN TRAILING UNION UNIQUE USING VARIADIC|10 VERBOSE WHEN WHERE WINDOW WITH BY RETURNS INOUT OUT SETOF|10 IF STRICT CURRENT CONTINUE OWNER LOCATION OVER PARTITION WITHIN BETWEEN ESCAPE EXTERNAL INVOKER DEFINER WORK RENAME VERSION CONNECTION CONNECT TABLES TEMP TEMPORARY FUNCTIONS SEQUENCES TYPES SCHEMAS OPTION CASCADE RESTRICT ADD ADMIN EXISTS VALID VALIDATE ENABLE DISABLE REPLICA|10 ALWAYS PASSING COLUMNS PATH REF VALUE OVERRIDING IMMUTABLE STABLE VOLATILE BEFORE AFTER EACH ROW PROCEDURAL ROUTINE NO HANDLER VALIDATOR OPTIONS STORAGE OIDS|10 WITHOUT INHERIT DEPENDS CALLED INPUT LEAKPROOF|10 COST ROWS NOWAIT SEARCH UNTIL ENCRYPTED|10 PASSWORD CONFLICT|10 INSTEAD INHERITS CHARACTERISTICS WRITE CURSOR ALSO STATEMENT SHARE EXCLUSIVE INLINE ISOLATION REPEATABLE READ COMMITTED SERIALIZABLE UNCOMMITTED LOCAL GLOBAL SQL PROCEDURES RECURSIVE SNAPSHOT ROLLUP CUBE TRUSTED|10 INCLUDE FOLLOWING PRECEDING UNBOUNDED RANGE GROUPS UNENCRYPTED|10 SYSID FORMAT DELIMITER HEADER QUOTE ENCODING FILTER OFF FORCE_QUOTE FORCE_NOT_NULL FORCE_NULL COSTS BUFFERS TIMING SUMMARY DISABLE_PAGE_SKIPPING RESTART CYCLE GENERATED IDENTITY DEFERRED IMMEDIATE LEVEL LOGGED UNLOGGED OF NOTHING NONE EXCLUDE ATTRIBUTE USAGE ROUTINES TRUE FALSE NAN INFINITY ",a="SUPERUSER NOSUPERUSER CREATEDB NOCREATEDB CREATEROLE NOCREATEROLE INHERIT NOINHERIT LOGIN NOLOGIN REPLICATION NOREPLICATION BYPASSRLS NOBYPASSRLS ",s="ALIAS BEGIN CONSTANT DECLARE END EXCEPTION RETURN PERFORM|10 RAISE GET DIAGNOSTICS STACKED|10 FOREACH LOOP ELSIF EXIT WHILE REVERSE SLICE DEBUG LOG INFO NOTICE WARNING ASSERT OPEN ",l="BIGINT INT8 BIGSERIAL SERIAL8 BIT VARYING VARBIT BOOLEAN BOOL BOX BYTEA CHARACTER CHAR VARCHAR CIDR CIRCLE DATE DOUBLE PRECISION FLOAT8 FLOAT INET INTEGER INT INT4 INTERVAL JSON JSONB LINE LSEG|10 MACADDR MACADDR8 MONEY NUMERIC DEC DECIMAL PATH POINT POLYGON REAL FLOAT4 SMALLINT INT2 SMALLSERIAL|10 SERIAL2|10 SERIAL|10 SERIAL4|10 TEXT TIME ZONE TIMETZ|10 TIMESTAMP TIMESTAMPTZ|10 TSQUERY|10 TSVECTOR|10 TXID_SNAPSHOT|10 UUID XML NATIONAL NCHAR INT4RANGE|10 INT8RANGE|10 NUMRANGE|10 TSRANGE|10 TSTZRANGE|10 DATERANGE|10 ANYELEMENT ANYARRAY ANYNONARRAY ANYENUM ANYRANGE CSTRING INTERNAL RECORD PG_DDL_COMMAND VOID UNKNOWN OPAQUE REFCURSOR NAME OID REGPROC|10 REGPROCEDURE|10 REGOPER|10 REGOPERATOR|10 REGCLASS|10 REGTYPE|10 REGROLE|10 REGNAMESPACE|10 REGCONFIG|10 REGDICTIONARY|10 ",c=l.trim().split(" ").map(function(e){return e.split("|")[0]}).join("|"),u="CURRENT_TIME CURRENT_TIMESTAMP CURRENT_USER CURRENT_CATALOG|10 CURRENT_DATE LOCALTIME LOCALTIMESTAMP CURRENT_ROLE|10 CURRENT_SCHEMA|10 SESSION_USER PUBLIC ",d="FOUND NEW OLD TG_NAME|10 TG_WHEN|10 TG_LEVEL|10 TG_OP|10 TG_RELID|10 TG_RELNAME|10 TG_TABLE_NAME|10 TG_TABLE_SCHEMA|10 TG_NARGS|10 TG_ARGV|10 TG_EVENT|10 TG_TAG|10 ROW_COUNT RESULT_OID|10 PG_CONTEXT|10 RETURNED_SQLSTATE COLUMN_NAME CONSTRAINT_NAME PG_DATATYPE_NAME|10 MESSAGE_TEXT TABLE_NAME SCHEMA_NAME PG_EXCEPTION_DETAIL|10 PG_EXCEPTION_HINT|10 PG_EXCEPTION_CONTEXT|10 ",h="SQLSTATE SQLERRM|10 SUCCESSFUL_COMPLETION WARNING DYNAMIC_RESULT_SETS_RETURNED IMPLICIT_ZERO_BIT_PADDING NULL_VALUE_ELIMINATED_IN_SET_FUNCTION PRIVILEGE_NOT_GRANTED PRIVILEGE_NOT_REVOKED STRING_DATA_RIGHT_TRUNCATION DEPRECATED_FEATURE NO_DATA NO_ADDITIONAL_DYNAMIC_RESULT_SETS_RETURNED SQL_STATEMENT_NOT_YET_COMPLETE CONNECTION_EXCEPTION CONNECTION_DOES_NOT_EXIST CONNECTION_FAILURE SQLCLIENT_UNABLE_TO_ESTABLISH_SQLCONNECTION SQLSERVER_REJECTED_ESTABLISHMENT_OF_SQLCONNECTION TRANSACTION_RESOLUTION_UNKNOWN PROTOCOL_VIOLATION TRIGGERED_ACTION_EXCEPTION FEATURE_NOT_SUPPORTED INVALID_TRANSACTION_INITIATION LOCATOR_EXCEPTION INVALID_LOCATOR_SPECIFICATION INVALID_GRANTOR INVALID_GRANT_OPERATION INVALID_ROLE_SPECIFICATION DIAGNOSTICS_EXCEPTION STACKED_DIAGNOSTICS_ACCESSED_WITHOUT_ACTIVE_HANDLER CASE_NOT_FOUND CARDINALITY_VIOLATION DATA_EXCEPTION ARRAY_SUBSCRIPT_ERROR CHARACTER_NOT_IN_REPERTOIRE DATETIME_FIELD_OVERFLOW DIVISION_BY_ZERO ERROR_IN_ASSIGNMENT ESCAPE_CHARACTER_CONFLICT INDICATOR_OVERFLOW INTERVAL_FIELD_OVERFLOW INVALID_ARGUMENT_FOR_LOGARITHM INVALID_ARGUMENT_FOR_NTILE_FUNCTION INVALID_ARGUMENT_FOR_NTH_VALUE_FUNCTION INVALID_ARGUMENT_FOR_POWER_FUNCTION INVALID_ARGUMENT_FOR_WIDTH_BUCKET_FUNCTION INVALID_CHARACTER_VALUE_FOR_CAST INVALID_DATETIME_FORMAT INVALID_ESCAPE_CHARACTER INVALID_ESCAPE_OCTET INVALID_ESCAPE_SEQUENCE NONSTANDARD_USE_OF_ESCAPE_CHARACTER INVALID_INDICATOR_PARAMETER_VALUE INVALID_PARAMETER_VALUE INVALID_REGULAR_EXPRESSION INVALID_ROW_COUNT_IN_LIMIT_CLAUSE INVALID_ROW_COUNT_IN_RESULT_OFFSET_CLAUSE INVALID_TABLESAMPLE_ARGUMENT INVALID_TABLESAMPLE_REPEAT INVALID_TIME_ZONE_DISPLACEMENT_VALUE INVALID_USE_OF_ESCAPE_CHARACTER MOST_SPECIFIC_TYPE_MISMATCH NULL_VALUE_NOT_ALLOWED NULL_VALUE_NO_INDICATOR_PARAMETER NUMERIC_VALUE_OUT_OF_RANGE SEQUENCE_GENERATOR_LIMIT_EXCEEDED STRING_DATA_LENGTH_MISMATCH STRING_DATA_RIGHT_TRUNCATION SUBSTRING_ERROR TRIM_ERROR UNTERMINATED_C_STRING ZERO_LENGTH_CHARACTER_STRING FLOATING_POINT_EXCEPTION INVALID_TEXT_REPRESENTATION INVALID_BINARY_REPRESENTATION BAD_COPY_FILE_FORMAT UNTRANSLATABLE_CHARACTER NOT_AN_XML_DOCUMENT INVALID_XML_DOCUMENT INVALID_XML_CONTENT INVALID_XML_COMMENT INVALID_XML_PROCESSING_INSTRUCTION INTEGRITY_CONSTRAINT_VIOLATION RESTRICT_VIOLATION NOT_NULL_VIOLATION FOREIGN_KEY_VIOLATION UNIQUE_VIOLATION CHECK_VIOLATION EXCLUSION_VIOLATION INVALID_CURSOR_STATE INVALID_TRANSACTION_STATE ACTIVE_SQL_TRANSACTION BRANCH_TRANSACTION_ALREADY_ACTIVE HELD_CURSOR_REQUIRES_SAME_ISOLATION_LEVEL INAPPROPRIATE_ACCESS_MODE_FOR_BRANCH_TRANSACTION INAPPROPRIATE_ISOLATION_LEVEL_FOR_BRANCH_TRANSACTION NO_ACTIVE_SQL_TRANSACTION_FOR_BRANCH_TRANSACTION READ_ONLY_SQL_TRANSACTION SCHEMA_AND_DATA_STATEMENT_MIXING_NOT_SUPPORTED NO_ACTIVE_SQL_TRANSACTION IN_FAILED_SQL_TRANSACTION IDLE_IN_TRANSACTION_SESSION_TIMEOUT INVALID_SQL_STATEMENT_NAME TRIGGERED_DATA_CHANGE_VIOLATION INVALID_AUTHORIZATION_SPECIFICATION INVALID_PASSWORD DEPENDENT_PRIVILEGE_DESCRIPTORS_STILL_EXIST DEPENDENT_OBJECTS_STILL_EXIST INVALID_TRANSACTION_TERMINATION SQL_ROUTINE_EXCEPTION FUNCTION_EXECUTED_NO_RETURN_STATEMENT MODIFYING_SQL_DATA_NOT_PERMITTED PROHIBITED_SQL_STATEMENT_ATTEMPTED READING_SQL_DATA_NOT_PERMITTED INVALID_CURSOR_NAME EXTERNAL_ROUTINE_EXCEPTION CONTAINING_SQL_NOT_PERMITTED MODIFYING_SQL_DATA_NOT_PERMITTED PROHIBITED_SQL_STATEMENT_ATTEMPTED READING_SQL_DATA_NOT_PERMITTED EXTERNAL_ROUTINE_INVOCATION_EXCEPTION INVALID_SQLSTATE_RETURNED NULL_VALUE_NOT_ALLOWED TRIGGER_PROTOCOL_VIOLATED SRF_PROTOCOL_VIOLATED EVENT_TRIGGER_PROTOCOL_VIOLATED SAVEPOINT_EXCEPTION INVALID_SAVEPOINT_SPECIFICATION INVALID_CATALOG_NAME INVALID_SCHEMA_NAME TRANSACTION_ROLLBACK TRANSACTION_INTEGRITY_CONSTRAINT_VIOLATION SERIALIZATION_FAILURE STATEMENT_COMPLETION_UNKNOWN DEADLOCK_DETECTED SYNTAX_ERROR_OR_ACCESS_RULE_VIOLATION SYNTAX_ERROR INSUFFICIENT_PRIVILEGE CANNOT_COERCE GROUPING_ERROR WINDOWING_ERROR INVALID_RECURSION INVALID_FOREIGN_KEY INVALID_NAME NAME_TOO_LONG RESERVED_NAME DATATYPE_MISMATCH INDETERMINATE_DATATYPE COLLATION_MISMATCH INDETERMINATE_COLLATION WRONG_OBJECT_TYPE GENERATED_ALWAYS UNDEFINED_COLUMN UNDEFINED_FUNCTION UNDEFINED_TABLE UNDEFINED_PARAMETER UNDEFINED_OBJECT DUPLICATE_COLUMN DUPLICATE_CURSOR DUPLICATE_DATABASE DUPLICATE_FUNCTION DUPLICATE_PREPARED_STATEMENT DUPLICATE_SCHEMA DUPLICATE_TABLE DUPLICATE_ALIAS DUPLICATE_OBJECT AMBIGUOUS_COLUMN AMBIGUOUS_FUNCTION AMBIGUOUS_PARAMETER AMBIGUOUS_ALIAS INVALID_COLUMN_REFERENCE INVALID_COLUMN_DEFINITION INVALID_CURSOR_DEFINITION INVALID_DATABASE_DEFINITION INVALID_FUNCTION_DEFINITION INVALID_PREPARED_STATEMENT_DEFINITION INVALID_SCHEMA_DEFINITION INVALID_TABLE_DEFINITION INVALID_OBJECT_DEFINITION WITH_CHECK_OPTION_VIOLATION INSUFFICIENT_RESOURCES DISK_FULL OUT_OF_MEMORY TOO_MANY_CONNECTIONS CONFIGURATION_LIMIT_EXCEEDED PROGRAM_LIMIT_EXCEEDED STATEMENT_TOO_COMPLEX TOO_MANY_COLUMNS TOO_MANY_ARGUMENTS OBJECT_NOT_IN_PREREQUISITE_STATE OBJECT_IN_USE CANT_CHANGE_RUNTIME_PARAM LOCK_NOT_AVAILABLE OPERATOR_INTERVENTION QUERY_CANCELED ADMIN_SHUTDOWN CRASH_SHUTDOWN CANNOT_CONNECT_NOW DATABASE_DROPPED SYSTEM_ERROR IO_ERROR UNDEFINED_FILE DUPLICATE_FILE SNAPSHOT_TOO_OLD CONFIG_FILE_ERROR LOCK_FILE_EXISTS FDW_ERROR FDW_COLUMN_NAME_NOT_FOUND FDW_DYNAMIC_PARAMETER_VALUE_NEEDED FDW_FUNCTION_SEQUENCE_ERROR FDW_INCONSISTENT_DESCRIPTOR_INFORMATION FDW_INVALID_ATTRIBUTE_VALUE FDW_INVALID_COLUMN_NAME FDW_INVALID_COLUMN_NUMBER FDW_INVALID_DATA_TYPE FDW_INVALID_DATA_TYPE_DESCRIPTORS FDW_INVALID_DESCRIPTOR_FIELD_IDENTIFIER FDW_INVALID_HANDLE FDW_INVALID_OPTION_INDEX FDW_INVALID_OPTION_NAME FDW_INVALID_STRING_LENGTH_OR_BUFFER_LENGTH FDW_INVALID_STRING_FORMAT FDW_INVALID_USE_OF_NULL_POINTER FDW_TOO_MANY_HANDLES FDW_OUT_OF_MEMORY FDW_NO_SCHEMAS FDW_OPTION_NAME_NOT_FOUND FDW_REPLY_HANDLE FDW_SCHEMA_NOT_FOUND FDW_TABLE_NOT_FOUND FDW_UNABLE_TO_CREATE_EXECUTION FDW_UNABLE_TO_CREATE_REPLY FDW_UNABLE_TO_ESTABLISH_CONNECTION PLPGSQL_ERROR RAISE_EXCEPTION NO_DATA_FOUND TOO_MANY_ROWS ASSERT_FAILURE INTERNAL_ERROR DATA_CORRUPTED INDEX_CORRUPTED ",p="ARRAY_AGG AVG BIT_AND BIT_OR BOOL_AND BOOL_OR COUNT EVERY JSON_AGG JSONB_AGG JSON_OBJECT_AGG JSONB_OBJECT_AGG MAX MIN MODE STRING_AGG SUM XMLAGG CORR COVAR_POP COVAR_SAMP REGR_AVGX REGR_AVGY REGR_COUNT REGR_INTERCEPT REGR_R2 REGR_SLOPE REGR_SXX REGR_SXY REGR_SYY STDDEV STDDEV_POP STDDEV_SAMP VARIANCE VAR_POP VAR_SAMP PERCENTILE_CONT PERCENTILE_DISC ROW_NUMBER RANK DENSE_RANK PERCENT_RANK CUME_DIST NTILE LAG LEAD FIRST_VALUE LAST_VALUE NTH_VALUE NUM_NONNULLS NUM_NULLS ABS CBRT CEIL CEILING DEGREES DIV EXP FLOOR LN LOG MOD PI POWER RADIANS ROUND SCALE SIGN SQRT TRUNC WIDTH_BUCKET RANDOM SETSEED ACOS ACOSD ASIN ASIND ATAN ATAND ATAN2 ATAN2D COS COSD COT COTD SIN SIND TAN TAND BIT_LENGTH CHAR_LENGTH CHARACTER_LENGTH LOWER OCTET_LENGTH OVERLAY POSITION SUBSTRING TREAT TRIM UPPER ASCII BTRIM CHR CONCAT CONCAT_WS CONVERT CONVERT_FROM CONVERT_TO DECODE ENCODE INITCAP LEFT LENGTH LPAD LTRIM MD5 PARSE_IDENT PG_CLIENT_ENCODING QUOTE_IDENT|10 QUOTE_LITERAL|10 QUOTE_NULLABLE|10 REGEXP_MATCH REGEXP_MATCHES REGEXP_REPLACE REGEXP_SPLIT_TO_ARRAY REGEXP_SPLIT_TO_TABLE REPEAT REPLACE REVERSE RIGHT RPAD RTRIM SPLIT_PART STRPOS SUBSTR TO_ASCII TO_HEX TRANSLATE OCTET_LENGTH GET_BIT GET_BYTE SET_BIT SET_BYTE TO_CHAR TO_DATE TO_NUMBER TO_TIMESTAMP AGE CLOCK_TIMESTAMP|10 DATE_PART DATE_TRUNC ISFINITE JUSTIFY_DAYS JUSTIFY_HOURS JUSTIFY_INTERVAL MAKE_DATE MAKE_INTERVAL|10 MAKE_TIME MAKE_TIMESTAMP|10 MAKE_TIMESTAMPTZ|10 NOW STATEMENT_TIMESTAMP|10 TIMEOFDAY TRANSACTION_TIMESTAMP|10 ENUM_FIRST ENUM_LAST ENUM_RANGE AREA CENTER DIAMETER HEIGHT ISCLOSED ISOPEN NPOINTS PCLOSE POPEN RADIUS WIDTH BOX BOUND_BOX CIRCLE LINE LSEG PATH POLYGON ABBREV BROADCAST HOST HOSTMASK MASKLEN NETMASK NETWORK SET_MASKLEN TEXT INET_SAME_FAMILY INET_MERGE MACADDR8_SET7BIT ARRAY_TO_TSVECTOR GET_CURRENT_TS_CONFIG NUMNODE PLAINTO_TSQUERY PHRASETO_TSQUERY WEBSEARCH_TO_TSQUERY QUERYTREE SETWEIGHT STRIP TO_TSQUERY TO_TSVECTOR JSON_TO_TSVECTOR JSONB_TO_TSVECTOR TS_DELETE TS_FILTER TS_HEADLINE TS_RANK TS_RANK_CD TS_REWRITE TSQUERY_PHRASE TSVECTOR_TO_ARRAY TSVECTOR_UPDATE_TRIGGER TSVECTOR_UPDATE_TRIGGER_COLUMN XMLCOMMENT XMLCONCAT XMLELEMENT XMLFOREST XMLPI XMLROOT XMLEXISTS XML_IS_WELL_FORMED XML_IS_WELL_FORMED_DOCUMENT XML_IS_WELL_FORMED_CONTENT XPATH XPATH_EXISTS XMLTABLE XMLNAMESPACES TABLE_TO_XML TABLE_TO_XMLSCHEMA TABLE_TO_XML_AND_XMLSCHEMA QUERY_TO_XML QUERY_TO_XMLSCHEMA QUERY_TO_XML_AND_XMLSCHEMA CURSOR_TO_XML CURSOR_TO_XMLSCHEMA SCHEMA_TO_XML SCHEMA_TO_XMLSCHEMA SCHEMA_TO_XML_AND_XMLSCHEMA DATABASE_TO_XML DATABASE_TO_XMLSCHEMA DATABASE_TO_XML_AND_XMLSCHEMA XMLATTRIBUTES TO_JSON TO_JSONB ARRAY_TO_JSON ROW_TO_JSON JSON_BUILD_ARRAY JSONB_BUILD_ARRAY JSON_BUILD_OBJECT JSONB_BUILD_OBJECT JSON_OBJECT JSONB_OBJECT JSON_ARRAY_LENGTH JSONB_ARRAY_LENGTH JSON_EACH JSONB_EACH JSON_EACH_TEXT JSONB_EACH_TEXT JSON_EXTRACT_PATH JSONB_EXTRACT_PATH JSON_OBJECT_KEYS JSONB_OBJECT_KEYS JSON_POPULATE_RECORD JSONB_POPULATE_RECORD JSON_POPULATE_RECORDSET JSONB_POPULATE_RECORDSET JSON_ARRAY_ELEMENTS JSONB_ARRAY_ELEMENTS JSON_ARRAY_ELEMENTS_TEXT JSONB_ARRAY_ELEMENTS_TEXT JSON_TYPEOF JSONB_TYPEOF JSON_TO_RECORD JSONB_TO_RECORD JSON_TO_RECORDSET JSONB_TO_RECORDSET JSON_STRIP_NULLS JSONB_STRIP_NULLS JSONB_SET JSONB_INSERT JSONB_PRETTY CURRVAL LASTVAL NEXTVAL SETVAL COALESCE NULLIF GREATEST LEAST ARRAY_APPEND ARRAY_CAT ARRAY_NDIMS ARRAY_DIMS ARRAY_FILL ARRAY_LENGTH ARRAY_LOWER ARRAY_POSITION ARRAY_POSITIONS ARRAY_PREPEND ARRAY_REMOVE ARRAY_REPLACE ARRAY_TO_STRING ARRAY_UPPER CARDINALITY STRING_TO_ARRAY UNNEST ISEMPTY LOWER_INC UPPER_INC LOWER_INF UPPER_INF RANGE_MERGE GENERATE_SERIES GENERATE_SUBSCRIPTS CURRENT_DATABASE CURRENT_QUERY CURRENT_SCHEMA|10 CURRENT_SCHEMAS|10 INET_CLIENT_ADDR INET_CLIENT_PORT INET_SERVER_ADDR INET_SERVER_PORT ROW_SECURITY_ACTIVE FORMAT_TYPE TO_REGCLASS TO_REGPROC TO_REGPROCEDURE TO_REGOPER TO_REGOPERATOR TO_REGTYPE TO_REGNAMESPACE TO_REGROLE COL_DESCRIPTION OBJ_DESCRIPTION SHOBJ_DESCRIPTION TXID_CURRENT TXID_CURRENT_IF_ASSIGNED TXID_CURRENT_SNAPSHOT TXID_SNAPSHOT_XIP TXID_SNAPSHOT_XMAX TXID_SNAPSHOT_XMIN TXID_VISIBLE_IN_SNAPSHOT TXID_STATUS CURRENT_SETTING SET_CONFIG BRIN_SUMMARIZE_NEW_VALUES BRIN_SUMMARIZE_RANGE BRIN_DESUMMARIZE_RANGE GIN_CLEAN_PENDING_LIST SUPPRESS_REDUNDANT_UPDATES_TRIGGER LO_FROM_BYTEA LO_PUT LO_GET LO_CREAT LO_CREATE LO_UNLINK LO_IMPORT LO_EXPORT LOREAD LOWRITE GROUPING CAST ",f=p.trim().split(" ").map(function(e){return e.split("|")[0]}).join("|");return{name:"PostgreSQL",aliases:["postgres","postgresql"],supersetOf:"sql",case_insensitive:!0,keywords:{keyword:o+s+a,built_in:u+d+h},illegal:/:==|\W\s*\(\*|(^|\s)\$[a-z]|\{\{|[a-z]:\s*$|\.\.\.|TO:|DO:/,contains:[{className:"keyword",variants:[{begin:/\bTEXT\s*SEARCH\b/},{begin:/\b(PRIMARY|FOREIGN|FOR(\s+NO)?)\s+KEY\b/},{begin:/\bPARALLEL\s+(UNSAFE|RESTRICTED|SAFE)\b/},{begin:/\bSTORAGE\s+(PLAIN|EXTERNAL|EXTENDED|MAIN)\b/},{begin:/\bMATCH\s+(FULL|PARTIAL|SIMPLE)\b/},{begin:/\bNULLS\s+(FIRST|LAST)\b/},{begin:/\bEVENT\s+TRIGGER\b/},{begin:/\b(MAPPING|OR)\s+REPLACE\b/},{begin:/\b(FROM|TO)\s+(PROGRAM|STDIN|STDOUT)\b/},{begin:/\b(SHARE|EXCLUSIVE)\s+MODE\b/},{begin:/\b(LEFT|RIGHT)\s+(OUTER\s+)?JOIN\b/},{begin:/\b(FETCH|MOVE)\s+(NEXT|PRIOR|FIRST|LAST|ABSOLUTE|RELATIVE|FORWARD|BACKWARD)\b/},{begin:/\bPRESERVE\s+ROWS\b/},{begin:/\bDISCARD\s+PLANS\b/},{begin:/\bREFERENCING\s+(OLD|NEW)\b/},{begin:/\bSKIP\s+LOCKED\b/},{begin:/\bGROUPING\s+SETS\b/},{begin:/\b(BINARY|INSENSITIVE|SCROLL|NO\s+SCROLL)\s+(CURSOR|FOR)\b/},{begin:/\b(WITH|WITHOUT)\s+HOLD\b/},{begin:/\bWITH\s+(CASCADED|LOCAL)\s+CHECK\s+OPTION\b/},{begin:/\bEXCLUDE\s+(TIES|NO\s+OTHERS)\b/},{begin:/\bFORMAT\s+(TEXT|XML|JSON|YAML)\b/},{begin:/\bSET\s+((SESSION|LOCAL)\s+)?NAMES\b/},{begin:/\bIS\s+(NOT\s+)?UNKNOWN\b/},{begin:/\bSECURITY\s+LABEL\b/},{begin:/\bSTANDALONE\s+(YES|NO|NO\s+VALUE)\b/},{begin:/\bWITH\s+(NO\s+)?DATA\b/},{begin:/\b(FOREIGN|SET)\s+DATA\b/},{begin:/\bSET\s+(CATALOG|CONSTRAINTS)\b/},{begin:/\b(WITH|FOR)\s+ORDINALITY\b/},{begin:/\bIS\s+(NOT\s+)?DOCUMENT\b/},{begin:/\bXML\s+OPTION\s+(DOCUMENT|CONTENT)\b/},{begin:/\b(STRIP|PRESERVE)\s+WHITESPACE\b/},{begin:/\bNO\s+(ACTION|MAXVALUE|MINVALUE)\b/},{begin:/\bPARTITION\s+BY\s+(RANGE|LIST|HASH)\b/},{begin:/\bAT\s+TIME\s+ZONE\b/},{begin:/\bGRANTED\s+BY\b/},{begin:/\bRETURN\s+(QUERY|NEXT)\b/},{begin:/\b(ATTACH|DETACH)\s+PARTITION\b/},{begin:/\bFORCE\s+ROW\s+LEVEL\s+SECURITY\b/},{begin:/\b(INCLUDING|EXCLUDING)\s+(COMMENTS|CONSTRAINTS|DEFAULTS|IDENTITY|INDEXES|STATISTICS|STORAGE|ALL)\b/},{begin:/\bAS\s+(ASSIGNMENT|IMPLICIT|PERMISSIVE|RESTRICTIVE|ENUM|RANGE)\b/}]},{begin:/\b(FORMAT|FAMILY|VERSION)\s*\(/},{begin:/\bINCLUDE\s*\(/,keywords:"INCLUDE"},{begin:/\bRANGE(?!\s*(BETWEEN|UNBOUNDED|CURRENT|[-0-9]+))/},{begin:/\b(VERSION|OWNER|TEMPLATE|TABLESPACE|CONNECTION\s+LIMIT|PROCEDURE|RESTRICT|JOIN|PARSER|COPY|START|END|COLLATION|INPUT|ANALYZE|STORAGE|LIKE|DEFAULT|DELIMITER|ENCODING|COLUMN|CONSTRAINT|TABLE|SCHEMA)\s*=/},{begin:/\b(PG_\w+?|HAS_[A-Z_]+_PRIVILEGE)\b/,relevance:10},{begin:/\bEXTRACT\s*\(/,end:/\bFROM\b/,returnEnd:!0,keywords:{type:"CENTURY DAY DECADE DOW DOY EPOCH HOUR ISODOW ISOYEAR MICROSECONDS MILLENNIUM MILLISECONDS MINUTE MONTH QUARTER SECOND TIMEZONE TIMEZONE_HOUR TIMEZONE_MINUTE WEEK YEAR"}},{begin:/\b(XMLELEMENT|XMLPI)\s*\(\s*NAME/,keywords:{keyword:"NAME"}},{begin:/\b(XMLPARSE|XMLSERIALIZE)\s*\(\s*(DOCUMENT|CONTENT)/,keywords:{keyword:"DOCUMENT CONTENT"}},{beginKeywords:"CACHE INCREMENT MAXVALUE MINVALUE",end:e.C_NUMBER_RE,returnEnd:!0,keywords:"BY CACHE INCREMENT MAXVALUE MINVALUE"},{className:"type",begin:/\b(WITH|WITHOUT)\s+TIME\s+ZONE\b/},{className:"type",begin:/\bINTERVAL\s+(YEAR|MONTH|DAY|HOUR|MINUTE|SECOND)(\s+TO\s+(MONTH|HOUR|MINUTE|SECOND))?\b/},{begin:/\bRETURNS\s+(LANGUAGE_HANDLER|TRIGGER|EVENT_TRIGGER|FDW_HANDLER|INDEX_AM_HANDLER|TSM_HANDLER)\b/,keywords:{keyword:"RETURNS",type:"LANGUAGE_HANDLER TRIGGER EVENT_TRIGGER FDW_HANDLER INDEX_AM_HANDLER TSM_HANDLER"}},{begin:"\\b("+f+")\\s*\\("},{begin:"\\.("+c+")\\b"},{begin:"\\b("+c+")\\s+PATH\\b",keywords:{keyword:"PATH",type:l.replace("PATH ","")}},{className:"type",begin:"\\b("+c+")\\b"},{className:"string",begin:"'",end:"'",contains:[{begin:"''"}]},{className:"string",begin:"(e|E|u&|U&)'",end:"'",contains:[{begin:"\\\\."}],relevance:10},e.END_SAME_AS_BEGIN({begin:r,end:r,contains:[{subLanguage:["pgsql","perl","python","tcl","r","lua","java","php","ruby","bash","scheme","xml","json"],endsWithParent:!0}]}),{begin:'"',end:'"',contains:[{begin:'""'}]},e.C_NUMBER_MODE,e.C_BLOCK_COMMENT_MODE,t,{className:"meta",variants:[{begin:"%(ROW)?TYPE",relevance:10},{begin:"\\$\\d+"},{begin:"^#\\w",end:"$"}]},{className:"symbol",begin:i,relevance:10}]}}e.exports=t},37592:function(e){function t(e){const t=e.regex,n=/(?![A-Za-z0-9])(?![$])/,r=t.concat(/[a-zA-Z_\x7f-\xff][a-zA-Z0-9_\x7f-\xff]*/,n),i=t.concat(/(\\?[A-Z][a-z0-9_\x7f-\xff]+|\\?[A-Z]+(?=[A-Z][a-z0-9_\x7f-\xff])){1,}/,n),o={scope:"variable",match:"\\$+"+r},a={scope:"meta",variants:[{begin:/<\?php/,relevance:10},{begin:/<\?=/},{begin:/<\?/,relevance:.1},{begin:/\?>/}]},s={scope:"subst",variants:[{begin:/\$\w+/},{begin:/\{\$/,end:/\}/}]},l=e.inherit(e.APOS_STRING_MODE,{illegal:null}),c=e.inherit(e.QUOTE_STRING_MODE,{illegal:null,contains:e.QUOTE_STRING_MODE.contains.concat(s)}),u=e.END_SAME_AS_BEGIN({begin:/<<<[ \t]*(\w+)\n/,end:/[ \t]*(\w+)\b/,contains:e.QUOTE_STRING_MODE.contains.concat(s)}),d="[ \t\n]",h={scope:"string",variants:[c,l,u]},p={scope:"number",variants:[{begin:"\\b0[bB][01]+(?:_[01]+)*\\b"},{begin:"\\b0[oO][0-7]+(?:_[0-7]+)*\\b"},{begin:"\\b0[xX][\\da-fA-F]+(?:_[\\da-fA-F]+)*\\b"},{begin:"(?:\\b\\d+(?:_\\d+)*(\\.(?:\\d+(?:_\\d+)*))?|\\B\\.\\d+)(?:[eE][+-]?\\d+)?"}],relevance:0},f=["false","null","true"],m=["__CLASS__","__DIR__","__FILE__","__FUNCTION__","__COMPILER_HALT_OFFSET__","__LINE__","__METHOD__","__NAMESPACE__","__TRAIT__","die","echo","exit","include","include_once","print","require","require_once","array","abstract","and","as","binary","bool","boolean","break","callable","case","catch","class","clone","const","continue","declare","default","do","double","else","elseif","empty","enddeclare","endfor","endforeach","endif","endswitch","endwhile","enum","eval","extends","final","finally","float","for","foreach","from","global","goto","if","implements","instanceof","insteadof","int","integer","interface","isset","iterable","list","match|0","mixed","new","never","object","or","private","protected","public","readonly","real","return","string","switch","throw","trait","try","unset","use","var","void","while","xor","yield"],g=["Error|0","AppendIterator","ArgumentCountError","ArithmeticError","ArrayIterator","ArrayObject","AssertionError","BadFunctionCallException","BadMethodCallException","CachingIterator","CallbackFilterIterator","CompileError","Countable","DirectoryIterator","DivisionByZeroError","DomainException","EmptyIterator","ErrorException","Exception","FilesystemIterator","FilterIterator","GlobIterator","InfiniteIterator","InvalidArgumentException","IteratorIterator","LengthException","LimitIterator","LogicException","MultipleIterator","NoRewindIterator","OutOfBoundsException","OutOfRangeException","OuterIterator","OverflowException","ParentIterator","ParseError","RangeException","RecursiveArrayIterator","RecursiveCachingIterator","RecursiveCallbackFilterIterator","RecursiveDirectoryIterator","RecursiveFilterIterator","RecursiveIterator","RecursiveIteratorIterator","RecursiveRegexIterator","RecursiveTreeIterator","RegexIterator","RuntimeException","SeekableIterator","SplDoublyLinkedList","SplFileInfo","SplFileObject","SplFixedArray","SplHeap","SplMaxHeap","SplMinHeap","SplObjectStorage","SplObserver","SplPriorityQueue","SplQueue","SplStack","SplSubject","SplTempFileObject","TypeError","UnderflowException","UnexpectedValueException","UnhandledMatchError","ArrayAccess","BackedEnum","Closure","Fiber","Generator","Iterator","IteratorAggregate","Serializable","Stringable","Throwable","Traversable","UnitEnum","WeakReference","WeakMap","Directory","__PHP_Incomplete_Class","parent","php_user_filter","self","static","stdClass"],v=e=>{const t=[];return e.forEach(e=>{t.push(e),e.toLowerCase()===e?t.push(e.toUpperCase()):t.push(e.toLowerCase())}),t},b={keyword:m,literal:v(f),built_in:g},y=e=>e.map(e=>e.replace(/\|\d+$/,"")),w={variants:[{match:[/new/,t.concat(d,"+"),t.concat("(?!",y(g).join("\\b|"),"\\b)"),i],scope:{1:"keyword",4:"title.class"}}]},O=t.concat(r,"\\b(?!\\()"),S={variants:[{match:[t.concat(/::/,t.lookahead(/(?!class\b)/)),O],scope:{2:"variable.constant"}},{match:[/::/,/class/],scope:{2:"variable.language"}},{match:[i,t.concat(/::/,t.lookahead(/(?!class\b)/)),O],scope:{1:"title.class",3:"variable.constant"}},{match:[i,t.concat("::",t.lookahead(/(?!class\b)/))],scope:{1:"title.class"}},{match:[i,/::/,/class/],scope:{1:"title.class",3:"variable.language"}}]},E={scope:"attr",match:t.concat(r,t.lookahead(":"),t.lookahead(/(?!::)/))},x={relevance:0,begin:/\(/,end:/\)/,keywords:b,contains:[E,o,S,e.C_BLOCK_COMMENT_MODE,h,p,w]},_={relevance:0,match:[/\b/,t.concat("(?!fn\\b|function\\b|",y(m).join("\\b|"),"|",y(g).join("\\b|"),"\\b)"),r,t.concat(d,"*"),t.lookahead(/(?=\()/)],scope:{3:"title.function.invoke"},contains:[x]};x.contains.push(_);const k=[E,S,e.C_BLOCK_COMMENT_MODE,h,p,w],C={begin:t.concat(/#\[\s*/,i),beginScope:"meta",end:/]/,endScope:"meta",keywords:{literal:f,keyword:["new","array"]},contains:[{begin:/\[/,end:/]/,keywords:{literal:f,keyword:["new","array"]},contains:["self",...k]},...k,{scope:"meta",match:i}]};return{case_insensitive:!1,keywords:b,contains:[C,e.HASH_COMMENT_MODE,e.COMMENT("//","$"),e.COMMENT("/\\*","\\*/",{contains:[{scope:"doctag",match:"@[A-Za-z]+"}]}),{match:/__halt_compiler\(\);/,keywords:"__halt_compiler",starts:{scope:"comment",end:e.MATCH_NOTHING_RE,contains:[{match:/\?>/,scope:"meta",endsParent:!0}]}},a,{scope:"variable.language",match:/\$this\b/},o,_,S,{match:[/const/,/\s/,r],scope:{1:"keyword",3:"variable.constant"}},w,{scope:"function",relevance:0,beginKeywords:"fn function",end:/[;{]/,excludeEnd:!0,illegal:"[$%\\[]",contains:[{beginKeywords:"use"},e.UNDERSCORE_TITLE_MODE,{begin:"=>",endsParent:!0},{scope:"params",begin:"\\(",end:"\\)",excludeBegin:!0,excludeEnd:!0,keywords:b,contains:["self",o,S,e.C_BLOCK_COMMENT_MODE,h,p]}]},{scope:"class",variants:[{beginKeywords:"enum",illegal:/[($"]/},{beginKeywords:"class interface trait",illegal:/[:($"]/}],relevance:0,end:/\{/,excludeEnd:!0,contains:[{beginKeywords:"extends implements"},e.UNDERSCORE_TITLE_MODE]},{beginKeywords:"namespace",relevance:0,end:";",illegal:/[.']/,contains:[e.inherit(e.UNDERSCORE_TITLE_MODE,{scope:"title.class"})]},{beginKeywords:"use",relevance:0,end:";",contains:[{match:/\b(as|const|function)\b/,scope:"keyword"},e.UNDERSCORE_TITLE_MODE]},h,p]}}e.exports=t},50619:function(e){function t(e){return{name:"Plain text",aliases:["text","txt"],disableAutodetect:!0}}e.exports=t},45107:function(e){function t(e){const t=["string","char","byte","int","long","bool","decimal","single","double","DateTime","xml","array","hashtable","void"],n="Add|Clear|Close|Copy|Enter|Exit|Find|Format|Get|Hide|Join|Lock|Move|New|Open|Optimize|Pop|Push|Redo|Remove|Rename|Reset|Resize|Search|Select|Set|Show|Skip|Split|Step|Switch|Undo|Unlock|Watch|Backup|Checkpoint|Compare|Compress|Convert|ConvertFrom|ConvertTo|Dismount|Edit|Expand|Export|Group|Import|Initialize|Limit|Merge|Mount|Out|Publish|Restore|Save|Sync|Unpublish|Update|Approve|Assert|Build|Complete|Confirm|Deny|Deploy|Disable|Enable|Install|Invoke|Register|Request|Restart|Resume|Start|Stop|Submit|Suspend|Uninstall|Unregister|Wait|Debug|Measure|Ping|Repair|Resolve|Test|Trace|Connect|Disconnect|Read|Receive|Send|Write|Block|Grant|Protect|Revoke|Unblock|Unprotect|Use|ForEach|Sort|Tee|Where",r="-and|-as|-band|-bnot|-bor|-bxor|-casesensitive|-ccontains|-ceq|-cge|-cgt|-cle|-clike|-clt|-cmatch|-cne|-cnotcontains|-cnotlike|-cnotmatch|-contains|-creplace|-csplit|-eq|-exact|-f|-file|-ge|-gt|-icontains|-ieq|-ige|-igt|-ile|-ilike|-ilt|-imatch|-in|-ine|-inotcontains|-inotlike|-inotmatch|-ireplace|-is|-isnot|-isplit|-join|-le|-like|-lt|-match|-ne|-not|-notcontains|-notin|-notlike|-notmatch|-or|-regex|-replace|-shl|-shr|-split|-wildcard|-xor",i={$pattern:/-?[A-z\.\-]+\b/,keyword:"if else foreach return do while until elseif begin for trap data dynamicparam end break throw param continue finally in switch exit filter try process catch hidden static parameter",built_in:"ac asnp cat cd CFS chdir clc clear clhy cli clp cls clv cnsn compare copy cp cpi cpp curl cvpa dbp del diff dir dnsn ebp echo|0 epal epcsv epsn erase etsn exsn fc fhx fl ft fw gal gbp gc gcb gci gcm gcs gdr gerr ghy gi gin gjb gl gm gmo gp gps gpv group gsn gsnp gsv gtz gu gv gwmi h history icm iex ihy ii ipal ipcsv ipmo ipsn irm ise iwmi iwr kill lp ls man md measure mi mount move mp mv nal ndr ni nmo npssc nsn nv ogv oh popd ps pushd pwd r rbp rcjb rcsn rd rdr ren ri rjb rm rmdir rmo rni rnp rp rsn rsnp rujb rv rvpa rwmi sajb sal saps sasv sbp sc scb select set shcm si sl sleep sls sort sp spjb spps spsv start stz sujb sv swmi tee trcm type wget where wjb write"},o=/\w[\w\d]*((-)[\w\d]+)*/,a={begin:"`[\\s\\S]",relevance:0},s={className:"variable",variants:[{begin:/\$\B/},{className:"keyword",begin:/\$this/},{begin:/\$[\w\d][\w\d_:]*/}]},l={className:"literal",begin:/\$(null|true|false)\b/},c={className:"string",variants:[{begin:/"/,end:/"/},{begin:/@"/,end:/^"@/}],contains:[a,s,{className:"variable",begin:/\$[A-z]/,end:/[^A-z]/}]},u={className:"string",variants:[{begin:/'/,end:/'/},{begin:/@'/,end:/^'@/}]},d={className:"doctag",variants:[{begin:/\.(synopsis|description|example|inputs|outputs|notes|link|component|role|functionality)/},{begin:/\.(parameter|forwardhelptargetname|forwardhelpcategory|remotehelprunspace|externalhelp)\s+\S+/}]},h=e.inherit(e.COMMENT(null,null),{variants:[{begin:/#/,end:/$/},{begin:/<#/,end:/#>/}],contains:[d]}),p={className:"built_in",variants:[{begin:"(".concat(n,")+(-)[\\w\\d]+")}]},f={className:"class",beginKeywords:"class enum",end:/\s*[{]/,excludeEnd:!0,relevance:0,contains:[e.TITLE_MODE]},m={className:"function",begin:/function\s+/,end:/\s*\{|$/,excludeEnd:!0,returnBegin:!0,relevance:0,contains:[{begin:"function",relevance:0,className:"keyword"},{className:"title",begin:o,relevance:0},{begin:/\(/,end:/\)/,className:"params",relevance:0,contains:[s]}]},g={begin:/using\s/,end:/$/,returnBegin:!0,contains:[c,u,{className:"keyword",begin:/(using|assembly|command|module|namespace|type)/}]},v={variants:[{className:"operator",begin:"(".concat(r,")\\b")},{className:"literal",begin:/(-){1,2}[\w\d-]+/,relevance:0}]},b={className:"selector-tag",begin:/@\B/,relevance:0},y={className:"function",begin:/\[.*\]\s*[\w]+[ ]??\(/,end:/$/,returnBegin:!0,relevance:0,contains:[{className:"keyword",begin:"(".concat(i.keyword.toString().replace(/\s/g,"|"),")\\b"),endsParent:!0,relevance:0},e.inherit(e.TITLE_MODE,{endsParent:!0})]},w=[y,h,a,e.NUMBER_MODE,c,u,p,s,l,b],O={begin:/\[/,end:/\]/,excludeBegin:!0,excludeEnd:!0,relevance:0,contains:[].concat("self",w,{begin:"("+t.join("|")+")",className:"built_in",relevance:0},{className:"type",begin:/[\.\w\d]+/,relevance:0})};return y.contains.unshift(O),{name:"PowerShell",aliases:["pwsh","ps","ps1"],case_insensitive:!0,keywords:i,contains:w.concat(f,m,g,v,O)}}e.exports=t},76015:function(e){function t(e){const t="[ \\t\\f]*",n="[ \\t\\f]+",r=t+"[:=]"+t,i=n,o="("+r+"|"+i+")",a="([^\\\\:= \\t\\f\\n]|\\\\.)+",s={end:o,relevance:0,starts:{className:"string",end:/$/,relevance:0,contains:[{begin:"\\\\\\\\"},{begin:"\\\\\\n"}]}};return{name:".properties",disableAutodetect:!0,case_insensitive:!0,illegal:/\S/,contains:[e.COMMENT("^\\s*[!#]","$"),{returnBegin:!0,variants:[{begin:a+r},{begin:a+i}],contains:[{className:"attr",begin:a,endsParent:!0}],starts:s},{className:"attr",begin:a+t+"$"}]}}e.exports=t},2061:function(e){function t(e){const t=["package","import","option","optional","required","repeated","group","oneof"],n=["double","float","int32","int64","uint32","uint64","sint32","sint64","fixed32","fixed64","sfixed32","sfixed64","bool","string","bytes"],r={match:[/(message|enum|service)\s+/,e.IDENT_RE],scope:{1:"keyword",2:"title.class"}};return{name:"Protocol Buffers",keywords:{keyword:t,type:n,literal:["true","false"]},contains:[e.QUOTE_STRING_MODE,e.NUMBER_MODE,e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,r,{className:"function",beginKeywords:"rpc",end:/[{;]/,excludeEnd:!0,keywords:"rpc returns"},{begin:/^\s*[A-Z_]+(?=\s*=[^\n]+;$)/}]}}e.exports=t},90944:function(e){function t(e){const t=e.regex,n=/[\p{XID_Start}_]\p{XID_Continue}*/u,r=["and","as","assert","async","await","break","case","class","continue","def","del","elif","else","except","finally","for","from","global","if","import","in","is","lambda","match","nonlocal|10","not","or","pass","raise","return","try","while","with","yield"],i=["__import__","abs","all","any","ascii","bin","bool","breakpoint","bytearray","bytes","callable","chr","classmethod","compile","complex","delattr","dict","dir","divmod","enumerate","eval","exec","filter","float","format","frozenset","getattr","globals","hasattr","hash","help","hex","id","input","int","isinstance","issubclass","iter","len","list","locals","map","max","memoryview","min","next","object","oct","open","ord","pow","print","property","range","repr","reversed","round","set","setattr","slice","sorted","staticmethod","str","sum","super","tuple","type","vars","zip"],o=["__debug__","Ellipsis","False","None","NotImplemented","True"],a=["Any","Callable","Coroutine","Dict","List","Literal","Generic","Optional","Sequence","Set","Tuple","Type","Union"],s={$pattern:/[A-Za-z]\w+|__\w+__/,keyword:r,built_in:i,literal:o,type:a},l={className:"meta",begin:/^(>>>|\.\.\.) /},c={className:"subst",begin:/\{/,end:/\}/,keywords:s,illegal:/#/},u={begin:/\{\{/,relevance:0},d={className:"string",contains:[e.BACKSLASH_ESCAPE],variants:[{begin:/([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?'''/,end:/'''/,contains:[e.BACKSLASH_ESCAPE,l],relevance:10},{begin:/([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?"""/,end:/"""/,contains:[e.BACKSLASH_ESCAPE,l],relevance:10},{begin:/([fF][rR]|[rR][fF]|[fF])'''/,end:/'''/,contains:[e.BACKSLASH_ESCAPE,l,u,c]},{begin:/([fF][rR]|[rR][fF]|[fF])"""/,end:/"""/,contains:[e.BACKSLASH_ESCAPE,l,u,c]},{begin:/([uU]|[rR])'/,end:/'/,relevance:10},{begin:/([uU]|[rR])"/,end:/"/,relevance:10},{begin:/([bB]|[bB][rR]|[rR][bB])'/,end:/'/},{begin:/([bB]|[bB][rR]|[rR][bB])"/,end:/"/},{begin:/([fF][rR]|[rR][fF]|[fF])'/,end:/'/,contains:[e.BACKSLASH_ESCAPE,u,c]},{begin:/([fF][rR]|[rR][fF]|[fF])"/,end:/"/,contains:[e.BACKSLASH_ESCAPE,u,c]},e.APOS_STRING_MODE,e.QUOTE_STRING_MODE]},h="[0-9](_?[0-9])*",p=`(\\b(${h}))?\\.(${h})|\\b(${h})\\.`,f=`\\b|${r.join("|")}`,m={className:"number",relevance:0,variants:[{begin:`(\\b(${h})|(${p}))[eE][+-]?(${h})[jJ]?(?=${f})`},{begin:`(${p})[jJ]?`},{begin:`\\b([1-9](_?[0-9])*|0+(_?0)*)[lLjJ]?(?=${f})`},{begin:`\\b0[bB](_?[01])+[lL]?(?=${f})`},{begin:`\\b0[oO](_?[0-7])+[lL]?(?=${f})`},{begin:`\\b0[xX](_?[0-9a-fA-F])+[lL]?(?=${f})`},{begin:`\\b(${h})[jJ](?=${f})`}]},g={className:"comment",begin:t.lookahead(/# type:/),end:/$/,keywords:s,contains:[{begin:/# type:/},{begin:/#/,end:/\b\B/,endsWithParent:!0}]},v={className:"params",variants:[{className:"",begin:/\(\s*\)/,skip:!0},{begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:s,contains:["self",l,m,d,e.HASH_COMMENT_MODE]}]};return c.contains=[d,m,l],{name:"Python",aliases:["py","gyp","ipython"],unicodeRegex:!0,keywords:s,illegal:/(<\/|->|\?)|=>/,contains:[l,m,{begin:/\bself\b/},{beginKeywords:"if",relevance:0},d,g,e.HASH_COMMENT_MODE,{match:[/\bdef/,/\s+/,n],scope:{1:"keyword",3:"title.function"},contains:[v]},{variants:[{match:[/\bclass/,/\s+/,n,/\s*/,/\(\s*/,n,/\s*\)/]},{match:[/\bclass/,/\s+/,n]}],scope:{1:"keyword",3:"title.class",6:"title.class.inherited"}},{className:"meta",begin:/^[\t ]*@/,end:/(?=#)|$/,contains:[m,v,d]}]}}e.exports=t},79386:function(e){function t(e){const t=e.regex,n="([a-zA-Z_]\\w*[!?=]?|[-+~]@|<<|>>|=~|===?|<=>|[<>]=?|\\*\\*|[-/+%^&*~`|]|\\[\\]=?)",r=t.either(/\b([A-Z]+[a-z0-9]+)+/,/\b([A-Z]+[a-z0-9]+)+[A-Z]+/),i=t.concat(r,/(::\w+)*/),o={"variable.constant":["__FILE__","__LINE__"],"variable.language":["self","super"],keyword:["alias","and","attr_accessor","attr_reader","attr_writer","begin","BEGIN","break","case","class","defined","do","else","elsif","end","END","ensure","for","if","in","include","module","next","not","or","redo","require","rescue","retry","return","then","undef","unless","until","when","while","yield"],built_in:["proc","lambda"],literal:["true","false","nil"]},a={className:"doctag",begin:"@[A-Za-z]+"},s={begin:"#<",end:">"},l=[e.COMMENT("#","$",{contains:[a]}),e.COMMENT("^=begin","^=end",{contains:[a],relevance:10}),e.COMMENT("^__END__",e.MATCH_NOTHING_RE)],c={className:"subst",begin:/#\{/,end:/\}/,keywords:o},u={className:"string",contains:[e.BACKSLASH_ESCAPE,c],variants:[{begin:/'/,end:/'/},{begin:/"/,end:/"/},{begin:/`/,end:/`/},{begin:/%[qQwWx]?\(/,end:/\)/},{begin:/%[qQwWx]?\[/,end:/\]/},{begin:/%[qQwWx]?\{/,end:/\}/},{begin:/%[qQwWx]?</,end:/>/},{begin:/%[qQwWx]?\//,end:/\//},{begin:/%[qQwWx]?%/,end:/%/},{begin:/%[qQwWx]?-/,end:/-/},{begin:/%[qQwWx]?\|/,end:/\|/},{begin:/\B\?(\\\d{1,3})/},{begin:/\B\?(\\x[A-Fa-f0-9]{1,2})/},{begin:/\B\?(\\u\{?[A-Fa-f0-9]{1,6}\}?)/},{begin:/\B\?(\\M-\\C-|\\M-\\c|\\c\\M-|\\M-|\\C-\\M-)[\x20-\x7e]/},{begin:/\B\?\\(c|C-)[\x20-\x7e]/},{begin:/\B\?\\?\S/},{begin:t.concat(/<<[-~]?'?/,t.lookahead(/(\w+)(?=\W)[^\n]*\n(?:[^\n]*\n)*?\s*\1\b/)),contains:[e.END_SAME_AS_BEGIN({begin:/(\w+)/,end:/(\w+)/,contains:[e.BACKSLASH_ESCAPE,c]})]}]},d="[1-9](_?[0-9])*|0",h="[0-9](_?[0-9])*",p={className:"number",relevance:0,variants:[{begin:`\\b(${d})(\\.(${h}))?([eE][+-]?(${h})|r)?i?\\b`},{begin:"\\b0[dD][0-9](_?[0-9])*r?i?\\b"},{begin:"\\b0[bB][0-1](_?[0-1])*r?i?\\b"},{begin:"\\b0[oO][0-7](_?[0-7])*r?i?\\b"},{begin:"\\b0[xX][0-9a-fA-F](_?[0-9a-fA-F])*r?i?\\b"},{begin:"\\b0(_?[0-7])+r?i?\\b"}]},f={variants:[{match:/\(\)/},{className:"params",begin:/\(/,end:/(?=\))/,excludeBegin:!0,endsParent:!0,keywords:o}]},m={variants:[{match:[/class\s+/,i,/\s+<\s+/,i]},{match:[/class\s+/,i]}],scope:{2:"title.class",4:"title.class.inherited"},keywords:o},g={relevance:0,match:/\b[A-Z][A-Z_0-9]+\b/,className:"variable.constant"},v={match:[/def/,/\s+/,n],scope:{1:"keyword",3:"title.function"},contains:[f]},b={relevance:0,match:[i,/\.new[ (]/],scope:{1:"title.class"}},y=[u,m,b,g,v,{begin:e.IDENT_RE+"::"},{className:"symbol",begin:e.UNDERSCORE_IDENT_RE+"(!|\\?)?:",relevance:0},{className:"symbol",begin:":(?!\\s)",contains:[u,{begin:n}],relevance:0},p,{className:"variable",begin:"(\\$\\W)|((\\$|@@?)(\\w+))(?=[^@$?])(?![A-Za-z])(?![@$?'])"},{className:"params",begin:/\|/,end:/\|/,excludeBegin:!0,excludeEnd:!0,relevance:0,keywords:o},{begin:"("+e.RE_STARTERS_RE+"|unless)\\s*",keywords:"unless",contains:[{className:"regexp",contains:[e.BACKSLASH_ESCAPE,c],illegal:/\n/,variants:[{begin:"/",end:"/[a-z]*"},{begin:/%r\{/,end:/\}[a-z]*/},{begin:"%r\\(",end:"\\)[a-z]*"},{begin:"%r!",end:"![a-z]*"},{begin:"%r\\[",end:"\\][a-z]*"}]}].concat(s,l),relevance:0}].concat(s,l);c.contains=y,f.contains=y;const w="[>?]>",O="[\\w#]+\\(\\w+\\):\\d+:\\d+[>*]",S="(\\w+-)?\\d+\\.\\d+\\.\\d+(p\\d+)?[^\\d][^>]+>",E=[{begin:/^\s*=>/,starts:{end:"$",contains:y}},{className:"meta.prompt",begin:"^("+w+"|"+O+"|"+S+")(?=[ ])",starts:{end:"$",keywords:o,contains:y}}];return l.unshift(s),{name:"Ruby",aliases:["rb","gemspec","podspec","thor","irb"],keywords:o,illegal:/\/\*/,contains:[e.SHEBANG({binary:"ruby"})].concat(E).concat(l).concat(y)}}e.exports=t},8368:function(e){function t(e){const t=e.regex,n={className:"title.function.invoke",relevance:0,begin:t.concat(/\b/,/(?!let\b)/,e.IDENT_RE,t.lookahead(/\s*\(/))},r="([ui](8|16|32|64|128|size)|f(32|64))?",i=["abstract","as","async","await","become","box","break","const","continue","crate","do","dyn","else","enum","extern","false","final","fn","for","if","impl","in","let","loop","macro","match","mod","move","mut","override","priv","pub","ref","return","self","Self","static","struct","super","trait","true","try","type","typeof","unsafe","unsized","use","virtual","where","while","yield"],o=["true","false","Some","None","Ok","Err"],a=["drop ","Copy","Send","Sized","Sync","Drop","Fn","FnMut","FnOnce","ToOwned","Clone","Debug","PartialEq","PartialOrd","Eq","Ord","AsRef","AsMut","Into","From","Default","Iterator","Extend","IntoIterator","DoubleEndedIterator","ExactSizeIterator","SliceConcatExt","ToString","assert!","assert_eq!","bitflags!","bytes!","cfg!","col!","concat!","concat_idents!","debug_assert!","debug_assert_eq!","env!","panic!","file!","format!","format_args!","include_bytes!","include_str!","line!","local_data_key!","module_path!","option_env!","print!","println!","select!","stringify!","try!","unimplemented!","unreachable!","vec!","write!","writeln!","macro_rules!","assert_ne!","debug_assert_ne!"],s=["i8","i16","i32","i64","i128","isize","u8","u16","u32","u64","u128","usize","f32","f64","str","char","bool","Box","Option","Result","String","Vec"];return{name:"Rust",aliases:["rs"],keywords:{$pattern:e.IDENT_RE+"!?",type:s,keyword:i,literal:o,built_in:a},illegal:"</",contains:[e.C_LINE_COMMENT_MODE,e.COMMENT("/\\*","\\*/",{contains:["self"]}),e.inherit(e.QUOTE_STRING_MODE,{begin:/b?"/,illegal:null}),{className:"string",variants:[{begin:/b?r(#*)"(.|\n)*?"\1(?!#)/},{begin:/b?'\\?(x\w{2}|u\w{4}|U\w{8}|.)'/}]},{className:"symbol",begin:/'[a-zA-Z_][a-zA-Z0-9_]*/},{className:"number",variants:[{begin:"\\b0b([01_]+)"+r},{begin:"\\b0o([0-7_]+)"+r},{begin:"\\b0x([A-Fa-f0-9_]+)"+r},{begin:"\\b(\\d[\\d_]*(\\.[0-9_]+)?([eE][+-]?[0-9_]+)?)"+r}],relevance:0},{begin:[/fn/,/\s+/,e.UNDERSCORE_IDENT_RE],className:{1:"keyword",3:"title.function"}},{className:"meta",begin:"#!?\\[",end:"\\]",contains:[{className:"string",begin:/"/,end:/"/}]},{begin:[/let/,/\s+/,/(?:mut\s+)?/,e.UNDERSCORE_IDENT_RE],className:{1:"keyword",3:"keyword",4:"variable"}},{begin:[/for/,/\s+/,e.UNDERSCORE_IDENT_RE,/\s+/,/in/],className:{1:"keyword",3:"variable",5:"keyword"}},{begin:[/type/,/\s+/,e.UNDERSCORE_IDENT_RE],className:{1:"keyword",3:"title.class"}},{begin:[/(?:trait|enum|struct|union|impl|for)/,/\s+/,e.UNDERSCORE_IDENT_RE],className:{1:"keyword",3:"title.class"}},{begin:e.IDENT_RE+"::",keywords:{keyword:"Self",built_in:a,type:s}},{className:"punctuation",begin:"->"},n]}}e.exports=t},31914:function(e){function t(e){const t=e.regex,n={className:"meta",begin:"@[A-Za-z]+"},r={className:"subst",variants:[{begin:"\\$[A-Za-z0-9_]+"},{begin:/\$\{/,end:/\}/}]},i={className:"string",variants:[{begin:'"""',end:'"""'},{begin:'"',end:'"',illegal:"\\n",contains:[e.BACKSLASH_ESCAPE]},{begin:'[a-z]+"',end:'"',illegal:"\\n",contains:[e.BACKSLASH_ESCAPE,r]},{className:"string",begin:'[a-z]+"""',end:'"""',contains:[r],relevance:10}]},o={className:"type",begin:"\\b[A-Z][A-Za-z0-9_]*",relevance:0},a={className:"title",begin:/[^0-9\n\t "'(),.`{}\[\]:;][^\n\t "'(),.`{}\[\]:;]+|[^0-9\n\t "'(),.`{}\[\]:;=]/,relevance:0},s={className:"class",beginKeywords:"class object trait type",end:/[:={\[\n;]/,excludeEnd:!0,contains:[e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,{beginKeywords:"extends with",relevance:10},{begin:/\[/,end:/\]/,excludeBegin:!0,excludeEnd:!0,relevance:0,contains:[o]},{className:"params",begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,relevance:0,contains:[o]},a]},l={className:"function",beginKeywords:"def",end:t.lookahead(/[:={\[(\n;]/),contains:[a]},c={begin:[/^\s*/,"extension",/\s+(?=[[(])/],beginScope:{2:"keyword"}},u={begin:[/^\s*/,/end/,/\s+/,/(extension\b)?/],beginScope:{2:"keyword",4:"keyword"}},d=[{match:/\.inline\b/},{begin:/\binline(?=\s)/,keywords:"inline"}],h={begin:[/\(\s*/,/using/,/\s+(?!\))/],beginScope:{2:"keyword"}};return{name:"Scala",keywords:{literal:"true false null",keyword:"type yield lazy override def with val var sealed abstract private trait object if then forSome for while do throw finally protected extends import final return else break new catch super class case package default try this match continue throws implicit export enum given transparent"},contains:[e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,i,o,l,s,e.C_NUMBER_MODE,c,u,...d,h,n]}}e.exports=t},74222:function(e){const t=e=>({IMPORTANT:{scope:"meta",begin:"!important"},BLOCK_COMMENT:e.C_BLOCK_COMMENT_MODE,HEXCOLOR:{scope:"number",begin:/#(([0-9a-fA-F]{3,4})|(([0-9a-fA-F]{2}){3,4}))\b/},FUNCTION_DISPATCH:{className:"built_in",begin:/[\w-]+(?=\()/},ATTRIBUTE_SELECTOR_MODE:{scope:"selector-attr",begin:/\[/,end:/\]/,illegal:"$",contains:[e.APOS_STRING_MODE,e.QUOTE_STRING_MODE]},CSS_NUMBER_MODE:{scope:"number",begin:e.NUMBER_RE+"(%|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc|px|deg|grad|rad|turn|s|ms|Hz|kHz|dpi|dpcm|dppx)?",relevance:0},CSS_VARIABLE:{className:"attr",begin:/--[A-Za-z][A-Za-z0-9_-]*/}}),n=["a","abbr","address","article","aside","audio","b","blockquote","body","button","canvas","caption","cite","code","dd","del","details","dfn","div","dl","dt","em","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hgroup","html","i","iframe","img","input","ins","kbd","label","legend","li","main","mark","menu","nav","object","ol","p","q","quote","samp","section","span","strong","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","tr","ul","var","video"],r=["any-hover","any-pointer","aspect-ratio","color","color-gamut","color-index","device-aspect-ratio","device-height","device-width","display-mode","forced-colors","grid","height","hover","inverted-colors","monochrome","orientation","overflow-block","overflow-inline","pointer","prefers-color-scheme","prefers-contrast","prefers-reduced-motion","prefers-reduced-transparency","resolution","scan","scripting","update","width","min-width","max-width","min-height","max-height"],i=["active","any-link","blank","checked","current","default","defined","dir","disabled","drop","empty","enabled","first","first-child","first-of-type","fullscreen","future","focus","focus-visible","focus-within","has","host","host-context","hover","indeterminate","in-range","invalid","is","lang","last-child","last-of-type","left","link","local-link","not","nth-child","nth-col","nth-last-child","nth-last-col","nth-last-of-type","nth-of-type","only-child","only-of-type","optional","out-of-range","past","placeholder-shown","read-only","read-write","required","right","root","scope","target","target-within","user-invalid","valid","visited","where"],o=["after","backdrop","before","cue","cue-region","first-letter","first-line","grammar-error","marker","part","placeholder","selection","slotted","spelling-error"],a=["align-content","align-items","align-self","all","animation","animation-delay","animation-direction","animation-duration","animation-fill-mode","animation-iteration-count","animation-name","animation-play-state","animation-timing-function","backface-visibility","background","background-attachment","background-blend-mode","background-clip","background-color","background-image","background-origin","background-position","background-repeat","background-size","block-size","border","border-block","border-block-color","border-block-end","border-block-end-color","border-block-end-style","border-block-end-width","border-block-start","border-block-start-color","border-block-start-style","border-block-start-width","border-block-style","border-block-width","border-bottom","border-bottom-color","border-bottom-left-radius","border-bottom-right-radius","border-bottom-style","border-bottom-width","border-collapse","border-color","border-image","border-image-outset","border-image-repeat","border-image-slice","border-image-source","border-image-width","border-inline","border-inline-color","border-inline-end","border-inline-end-color","border-inline-end-style","border-inline-end-width","border-inline-start","border-inline-start-color","border-inline-start-style","border-inline-start-width","border-inline-style","border-inline-width","border-left","border-left-color","border-left-style","border-left-width","border-radius","border-right","border-right-color","border-right-style","border-right-width","border-spacing","border-style","border-top","border-top-color","border-top-left-radius","border-top-right-radius","border-top-style","border-top-width","border-width","bottom","box-decoration-break","box-shadow","box-sizing","break-after","break-before","break-inside","caption-side","caret-color","clear","clip","clip-path","clip-rule","color","column-count","column-fill","column-gap","column-rule","column-rule-color","column-rule-style","column-rule-width","column-span","column-width","columns","contain","content","content-visibility","counter-increment","counter-reset","cue","cue-after","cue-before","cursor","direction","display","empty-cells","filter","flex","flex-basis","flex-direction","flex-flow","flex-grow","flex-shrink","flex-wrap","float","flow","font","font-display","font-family","font-feature-settings","font-kerning","font-language-override","font-size","font-size-adjust","font-smoothing","font-stretch","font-style","font-synthesis","font-variant","font-variant-caps","font-variant-east-asian","font-variant-ligatures","font-variant-numeric","font-variant-position","font-variation-settings","font-weight","gap","glyph-orientation-vertical","grid","grid-area","grid-auto-columns","grid-auto-flow","grid-auto-rows","grid-column","grid-column-end","grid-column-start","grid-gap","grid-row","grid-row-end","grid-row-start","grid-template","grid-template-areas","grid-template-columns","grid-template-rows","hanging-punctuation","height","hyphens","icon","image-orientation","image-rendering","image-resolution","ime-mode","inline-size","isolation","justify-content","left","letter-spacing","line-break","line-height","list-style","list-style-image","list-style-position","list-style-type","margin","margin-block","margin-block-end","margin-block-start","margin-bottom","margin-inline","margin-inline-end","margin-inline-start","margin-left","margin-right","margin-top","marks","mask","mask-border","mask-border-mode","mask-border-outset","mask-border-repeat","mask-border-slice","mask-border-source","mask-border-width","mask-clip","mask-composite","mask-image","mask-mode","mask-origin","mask-position","mask-repeat","mask-size","mask-type","max-block-size","max-height","max-inline-size","max-width","min-block-size","min-height","min-inline-size","min-width","mix-blend-mode","nav-down","nav-index","nav-left","nav-right","nav-up","none","normal","object-fit","object-position","opacity","order","orphans","outline","outline-color","outline-offset","outline-style","outline-width","overflow","overflow-wrap","overflow-x","overflow-y","padding","padding-block","padding-block-end","padding-block-start","padding-bottom","padding-inline","padding-inline-end","padding-inline-start","padding-left","padding-right","padding-top","page-break-after","page-break-before","page-break-inside","pause","pause-after","pause-before","perspective","perspective-origin","pointer-events","position","quotes","resize","rest","rest-after","rest-before","right","row-gap","scroll-margin","scroll-margin-block","scroll-margin-block-end","scroll-margin-block-start","scroll-margin-bottom","scroll-margin-inline","scroll-margin-inline-end","scroll-margin-inline-start","scroll-margin-left","scroll-margin-right","scroll-margin-top","scroll-padding","scroll-padding-block","scroll-padding-block-end","scroll-padding-block-start","scroll-padding-bottom","scroll-padding-inline","scroll-padding-inline-end","scroll-padding-inline-start","scroll-padding-left","scroll-padding-right","scroll-padding-top","scroll-snap-align","scroll-snap-stop","scroll-snap-type","scrollbar-color","scrollbar-gutter","scrollbar-width","shape-image-threshold","shape-margin","shape-outside","speak","speak-as","src","tab-size","table-layout","text-align","text-align-all","text-align-last","text-combine-upright","text-decoration","text-decoration-color","text-decoration-line","text-decoration-style","text-emphasis","text-emphasis-color","text-emphasis-position","text-emphasis-style","text-indent","text-justify","text-orientation","text-overflow","text-rendering","text-shadow","text-transform","text-underline-position","top","transform","transform-box","transform-origin","transform-style","transition","transition-delay","transition-duration","transition-property","transition-timing-function","unicode-bidi","vertical-align","visibility","voice-balance","voice-duration","voice-family","voice-pitch","voice-range","voice-rate","voice-stress","voice-volume","white-space","widows","width","will-change","word-break","word-spacing","word-wrap","writing-mode","z-index"].reverse();function s(e){const s=t(e),l=o,c=i,u="@[a-z-]+",d="and or not only",h="[a-zA-Z-][a-zA-Z0-9_-]*",p={className:"variable",begin:"(\\$"+h+")\\b",relevance:0};return{name:"SCSS",case_insensitive:!0,illegal:"[=/|']",contains:[e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE,s.CSS_NUMBER_MODE,{className:"selector-id",begin:"#[A-Za-z0-9_-]+",relevance:0},{className:"selector-class",begin:"\\.[A-Za-z0-9_-]+",relevance:0},s.ATTRIBUTE_SELECTOR_MODE,{className:"selector-tag",begin:"\\b("+n.join("|")+")\\b",relevance:0},{className:"selector-pseudo",begin:":("+c.join("|")+")"},{className:"selector-pseudo",begin:":(:)?("+l.join("|")+")"},p,{begin:/\(/,end:/\)/,contains:[s.CSS_NUMBER_MODE]},s.CSS_VARIABLE,{className:"attribute",begin:"\\b("+a.join("|")+")\\b"},{begin:"\\b(whitespace|wait|w-resize|visible|vertical-text|vertical-ideographic|uppercase|upper-roman|upper-alpha|underline|transparent|top|thin|thick|text|text-top|text-bottom|tb-rl|table-header-group|table-footer-group|sw-resize|super|strict|static|square|solid|small-caps|separate|se-resize|scroll|s-resize|rtl|row-resize|ridge|right|repeat|repeat-y|repeat-x|relative|progress|pointer|overline|outside|outset|oblique|nowrap|not-allowed|normal|none|nw-resize|no-repeat|no-drop|newspaper|ne-resize|n-resize|move|middle|medium|ltr|lr-tb|lowercase|lower-roman|lower-alpha|loose|list-item|line|line-through|line-edge|lighter|left|keep-all|justify|italic|inter-word|inter-ideograph|inside|inset|inline|inline-block|inherit|inactive|ideograph-space|ideograph-parenthesis|ideograph-numeric|ideograph-alpha|horizontal|hidden|help|hand|groove|fixed|ellipsis|e-resize|double|dotted|distribute|distribute-space|distribute-letter|distribute-all-lines|disc|disabled|default|decimal|dashed|crosshair|collapse|col-resize|circle|char|center|capitalize|break-word|break-all|bottom|both|bolder|bold|block|bidi-override|below|baseline|auto|always|all-scroll|absolute|table|table-cell)\\b"},{begin:/:/,end:/[;}{]/,relevance:0,contains:[s.BLOCK_COMMENT,p,s.HEXCOLOR,s.CSS_NUMBER_MODE,e.QUOTE_STRING_MODE,e.APOS_STRING_MODE,s.IMPORTANT,s.FUNCTION_DISPATCH]},{begin:"@(page|font-face)",keywords:{$pattern:u,keyword:"@page @font-face"}},{begin:"@",end:"[{;]",returnBegin:!0,keywords:{$pattern:/[a-z-]+/,keyword:d,attribute:r.join(" ")},contains:[{begin:u,className:"keyword"},{begin:/[a-z-]+(?=:)/,className:"attribute"},p,e.QUOTE_STRING_MODE,e.APOS_STRING_MODE,s.HEXCOLOR,s.CSS_NUMBER_MODE]},s.FUNCTION_DISPATCH]}}e.exports=s},7846:function(e){function t(e){return{name:"Shell Session",aliases:["console","shellsession"],contains:[{className:"meta.prompt",begin:/^\s{0,3}[/~\w\d[\]()@-]*[>%$#][ ]?/,starts:{end:/[^\\](?=\s*$)/,subLanguage:"bash"}}]}}e.exports=t},90984:function(e){function t(e){const t=e.regex,n=e.COMMENT("--","$"),r={className:"string",variants:[{begin:/'/,end:/'/,contains:[{begin:/''/}]}]},i={begin:/"/,end:/"/,contains:[{begin:/""/}]},o=["true","false","unknown"],a=["double precision","large object","with timezone","without timezone"],s=["bigint","binary","blob","boolean","char","character","clob","date","dec","decfloat","decimal","float","int","integer","interval","nchar","nclob","national","numeric","real","row","smallint","time","timestamp","varchar","varying","varbinary"],l=["add","asc","collation","desc","final","first","last","view"],c=["abs","acos","all","allocate","alter","and","any","are","array","array_agg","array_max_cardinality","as","asensitive","asin","asymmetric","at","atan","atomic","authorization","avg","begin","begin_frame","begin_partition","between","bigint","binary","blob","boolean","both","by","call","called","cardinality","cascaded","case","cast","ceil","ceiling","char","char_length","character","character_length","check","classifier","clob","close","coalesce","collate","collect","column","commit","condition","connect","constraint","contains","convert","copy","corr","corresponding","cos","cosh","count","covar_pop","covar_samp","create","cross","cube","cume_dist","current","current_catalog","current_date","current_default_transform_group","current_path","current_role","current_row","current_schema","current_time","current_timestamp","current_path","current_role","current_transform_group_for_type","current_user","cursor","cycle","date","day","deallocate","dec","decimal","decfloat","declare","default","define","delete","dense_rank","deref","describe","deterministic","disconnect","distinct","double","drop","dynamic","each","element","else","empty","end","end_frame","end_partition","end-exec","equals","escape","every","except","exec","execute","exists","exp","external","extract","false","fetch","filter","first_value","float","floor","for","foreign","frame_row","free","from","full","function","fusion","get","global","grant","group","grouping","groups","having","hold","hour","identity","in","indicator","initial","inner","inout","insensitive","insert","int","integer","intersect","intersection","interval","into","is","join","json_array","json_arrayagg","json_exists","json_object","json_objectagg","json_query","json_table","json_table_primitive","json_value","lag","language","large","last_value","lateral","lead","leading","left","like","like_regex","listagg","ln","local","localtime","localtimestamp","log","log10","lower","match","match_number","match_recognize","matches","max","member","merge","method","min","minute","mod","modifies","module","month","multiset","national","natural","nchar","nclob","new","no","none","normalize","not","nth_value","ntile","null","nullif","numeric","octet_length","occurrences_regex","of","offset","old","omit","on","one","only","open","or","order","out","outer","over","overlaps","overlay","parameter","partition","pattern","per","percent","percent_rank","percentile_cont","percentile_disc","period","portion","position","position_regex","power","precedes","precision","prepare","primary","procedure","ptf","range","rank","reads","real","recursive","ref","references","referencing","regr_avgx","regr_avgy","regr_count","regr_intercept","regr_r2","regr_slope","regr_sxx","regr_sxy","regr_syy","release","result","return","returns","revoke","right","rollback","rollup","row","row_number","rows","running","savepoint","scope","scroll","search","second","seek","select","sensitive","session_user","set","show","similar","sin","sinh","skip","smallint","some","specific","specifictype","sql","sqlexception","sqlstate","sqlwarning","sqrt","start","static","stddev_pop","stddev_samp","submultiset","subset","substring","substring_regex","succeeds","sum","symmetric","system","system_time","system_user","table","tablesample","tan","tanh","then","time","timestamp","timezone_hour","timezone_minute","to","trailing","translate","translate_regex","translation","treat","trigger","trim","trim_array","true","truncate","uescape","union","unique","unknown","unnest","update","upper","user","using","value","values","value_of","var_pop","var_samp","varbinary","varchar","varying","versioning","when","whenever","where","width_bucket","window","with","within","without","year"],u=["abs","acos","array_agg","asin","atan","avg","cast","ceil","ceiling","coalesce","corr","cos","cosh","count","covar_pop","covar_samp","cume_dist","dense_rank","deref","element","exp","extract","first_value","floor","json_array","json_arrayagg","json_exists","json_object","json_objectagg","json_query","json_table","json_table_primitive","json_value","lag","last_value","lead","listagg","ln","log","log10","lower","max","min","mod","nth_value","ntile","nullif","percent_rank","percentile_cont","percentile_disc","position","position_regex","power","rank","regr_avgx","regr_avgy","regr_count","regr_intercept","regr_r2","regr_slope","regr_sxx","regr_sxy","regr_syy","row_number","sin","sinh","sqrt","stddev_pop","stddev_samp","substring","substring_regex","sum","tan","tanh","translate","translate_regex","treat","trim","trim_array","unnest","upper","value_of","var_pop","var_samp","width_bucket"],d=["current_catalog","current_date","current_default_transform_group","current_path","current_role","current_schema","current_transform_group_for_type","current_user","session_user","system_time","system_user","current_time","localtime","current_timestamp","localtimestamp"],h=["create table","insert into","primary key","foreign key","not null","alter table","add constraint","grouping sets","on overflow","character set","respect nulls","ignore nulls","nulls first","nulls last","depth first","breadth first"],p=u,f=[...c,...l].filter(e=>!u.includes(e)),m={className:"variable",begin:/@[a-z0-9]+/},g={className:"operator",begin:/[-+*/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?/,relevance:0},v={begin:t.concat(/\b/,t.either(...p),/\s*\(/),relevance:0,keywords:{built_in:p}};function b(e,{exceptions:t,when:n}={}){const r=n;return t=t||[],e.map(e=>e.match(/\|\d+$/)||t.includes(e)?e:r(e)?`${e}|0`:e)}return{name:"SQL",case_insensitive:!0,illegal:/[{}]|<\//,keywords:{$pattern:/\b[\w\.]+/,keyword:b(f,{when:e=>e.length<3}),literal:o,type:s,built_in:d},contains:[{begin:t.either(...h),relevance:0,keywords:{$pattern:/[\w\.]+/,keyword:f.concat(h),literal:o,type:s}},{className:"type",begin:t.either(...a)},v,m,r,i,e.C_NUMBER_MODE,e.C_BLOCK_COMMENT_MODE,n,g]}}e.exports=t},72723:function(e){function t(e){return e?"string"===typeof e?e:e.source:null}function n(e){return r("(?=",e,")")}function r(...e){const n=e.map(e=>t(e)).join("");return n}function i(e){const t=e[e.length-1];return"object"===typeof t&&t.constructor===Object?(e.splice(e.length-1,1),t):{}}function o(...e){const n=i(e),r="("+(n.capture?"":"?:")+e.map(e=>t(e)).join("|")+")";return r}const a=e=>r(/\b/,e,/\w$/.test(e)?/\b/:/\B/),s=["Protocol","Type"].map(a),l=["init","self"].map(a),c=["Any","Self"],u=["actor","any","associatedtype","async","await",/as\?/,/as!/,"as","break","case","catch","class","continue","convenience","default","defer","deinit","didSet","distributed","do","dynamic","else","enum","extension","fallthrough",/fileprivate\(set\)/,"fileprivate","final","for","func","get","guard","if","import","indirect","infix",/init\?/,/init!/,"inout",/internal\(set\)/,"internal","in","is","isolated","nonisolated","lazy","let","mutating","nonmutating",/open\(set\)/,"open","operator","optional","override","postfix","precedencegroup","prefix",/private\(set\)/,"private","protocol",/public\(set\)/,"public","repeat","required","rethrows","return","set","some","static","struct","subscript","super","switch","throws","throw",/try\?/,/try!/,"try","typealias",/unowned\(safe\)/,/unowned\(unsafe\)/,"unowned","var","weak","where","while","willSet"],d=["false","nil","true"],h=["assignment","associativity","higherThan","left","lowerThan","none","right"],p=["#colorLiteral","#column","#dsohandle","#else","#elseif","#endif","#error","#file","#fileID","#fileLiteral","#filePath","#function","#if","#imageLiteral","#keyPath","#line","#selector","#sourceLocation","#warn_unqualified_access","#warning"],f=["abs","all","any","assert","assertionFailure","debugPrint","dump","fatalError","getVaList","isKnownUniquelyReferenced","max","min","numericCast","pointwiseMax","pointwiseMin","precondition","preconditionFailure","print","readLine","repeatElement","sequence","stride","swap","swift_unboxFromSwiftValueWithType","transcode","type","unsafeBitCast","unsafeDowncast","withExtendedLifetime","withUnsafeMutablePointer","withUnsafePointer","withVaList","withoutActuallyEscaping","zip"],m=o(/[/=\-+!*%<>&|^~?]/,/[\u00A1-\u00A7]/,/[\u00A9\u00AB]/,/[\u00AC\u00AE]/,/[\u00B0\u00B1]/,/[\u00B6\u00BB\u00BF\u00D7\u00F7]/,/[\u2016-\u2017]/,/[\u2020-\u2027]/,/[\u2030-\u203E]/,/[\u2041-\u2053]/,/[\u2055-\u205E]/,/[\u2190-\u23FF]/,/[\u2500-\u2775]/,/[\u2794-\u2BFF]/,/[\u2E00-\u2E7F]/,/[\u3001-\u3003]/,/[\u3008-\u3020]/,/[\u3030]/),g=o(m,/[\u0300-\u036F]/,/[\u1DC0-\u1DFF]/,/[\u20D0-\u20FF]/,/[\uFE00-\uFE0F]/,/[\uFE20-\uFE2F]/),v=r(m,g,"*"),b=o(/[a-zA-Z_]/,/[\u00A8\u00AA\u00AD\u00AF\u00B2-\u00B5\u00B7-\u00BA]/,/[\u00BC-\u00BE\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u00FF]/,/[\u0100-\u02FF\u0370-\u167F\u1681-\u180D\u180F-\u1DBF]/,/[\u1E00-\u1FFF]/,/[\u200B-\u200D\u202A-\u202E\u203F-\u2040\u2054\u2060-\u206F]/,/[\u2070-\u20CF\u2100-\u218F\u2460-\u24FF\u2776-\u2793]/,/[\u2C00-\u2DFF\u2E80-\u2FFF]/,/[\u3004-\u3007\u3021-\u302F\u3031-\u303F\u3040-\uD7FF]/,/[\uF900-\uFD3D\uFD40-\uFDCF\uFDF0-\uFE1F\uFE30-\uFE44]/,/[\uFE47-\uFEFE\uFF00-\uFFFD]/),y=o(b,/\d/,/[\u0300-\u036F\u1DC0-\u1DFF\u20D0-\u20FF\uFE20-\uFE2F]/),w=r(b,y,"*"),O=r(/[A-Z]/,y,"*"),S=["autoclosure",r(/convention\(/,o("swift","block","c"),/\)/),"discardableResult","dynamicCallable","dynamicMemberLookup","escaping","frozen","GKInspectable","IBAction","IBDesignable","IBInspectable","IBOutlet","IBSegueAction","inlinable","main","nonobjc","NSApplicationMain","NSCopying","NSManaged",r(/objc\(/,w,/\)/),"objc","objcMembers","propertyWrapper","requires_stored_property_inits","resultBuilder","testable","UIApplicationMain","unknown","usableFromInline"],E=["iOS","iOSApplicationExtension","macOS","macOSApplicationExtension","macCatalyst","macCatalystApplicationExtension","watchOS","watchOSApplicationExtension","tvOS","tvOSApplicationExtension","swift"];function x(e){const t={match:/\s+/,relevance:0},i=e.COMMENT("/\\*","\\*/",{contains:["self"]}),m=[e.C_LINE_COMMENT_MODE,i],b={match:[/\./,o(...s,...l)],className:{2:"keyword"}},x={match:r(/\./,o(...u)),relevance:0},_=u.filter(e=>"string"===typeof e).concat(["_|0"]),k=u.filter(e=>"string"!==typeof e).concat(c).map(a),C={variants:[{className:"keyword",match:o(...k,...l)}]},A={$pattern:o(/\b\w+/,/#\w+/),keyword:_.concat(p),literal:d},T=[b,x,C],R={match:r(/\./,o(...f)),relevance:0},N={className:"built_in",match:r(/\b/,o(...f),/(?=\()/)},P=[R,N],I={match:/->/,relevance:0},M={className:"operator",relevance:0,variants:[{match:v},{match:`\\.(\\.|${g})+`}]},D=[I,M],L="([0-9]_*)+",B="([0-9a-fA-F]_*)+",$={className:"number",relevance:0,variants:[{match:`\\b(${L})(\\.(${L}))?([eE][+-]?(${L}))?\\b`},{match:`\\b0x(${B})(\\.(${B}))?([pP][+-]?(${L}))?\\b`},{match:/\b0o([0-7]_*)+\b/},{match:/\b0b([01]_*)+\b/}]},V=(e="")=>({className:"subst",variants:[{match:r(/\\/,e,/[0\\tnr"']/)},{match:r(/\\/,e,/u\{[0-9a-fA-F]{1,8}\}/)}]}),F=(e="")=>({className:"subst",match:r(/\\/,e,/[\t ]*(?:[\r\n]|\r\n)/)}),j=(e="")=>({className:"subst",label:"interpol",begin:r(/\\/,e,/\(/),end:/\)/}),U=(e="")=>({begin:r(e,/"""/),end:r(/"""/,e),contains:[V(e),F(e),j(e)]}),G=(e="")=>({begin:r(e,/"/),end:r(/"/,e),contains:[V(e),j(e)]}),H={className:"string",variants:[U(),U("#"),U("##"),U("###"),G(),G("#"),G("##"),G("###")]},q={match:r(/`/,w,/`/)},Q={className:"variable",match:/\$\d+/},z={className:"variable",match:`\\$${y}+`},K=[q,Q,z],W={match:/(@|#(un)?)available/,className:"keyword",starts:{contains:[{begin:/\(/,end:/\)/,keywords:E,contains:[...D,$,H]}]}},X={className:"keyword",match:r(/@/,o(...S))},Y={className:"meta",match:r(/@/,w)},Z=[W,X,Y],J={match:n(/\b[A-Z]/),relevance:0,contains:[{className:"type",match:r(/(AV|CA|CF|CG|CI|CL|CM|CN|CT|MK|MP|MTK|MTL|NS|SCN|SK|UI|WK|XC)/,y,"+")},{className:"type",match:O,relevance:0},{match:/[?!]+/,relevance:0},{match:/\.\.\./,relevance:0},{match:r(/\s+&\s+/,n(O)),relevance:0}]},ee={begin:/</,end:/>/,keywords:A,contains:[...m,...T,...Z,I,J]};J.contains.push(ee);const te={match:r(w,/\s*:/),keywords:"_|0",relevance:0},ne={begin:/\(/,end:/\)/,relevance:0,keywords:A,contains:["self",te,...m,...T,...P,...D,$,H,...K,...Z,J]},re={begin:/</,end:/>/,contains:[...m,J]},ie={begin:o(n(r(w,/\s*:/)),n(r(w,/\s+/,w,/\s*:/))),end:/:/,relevance:0,contains:[{className:"keyword",match:/\b_\b/},{className:"params",match:w}]},oe={begin:/\(/,end:/\)/,keywords:A,contains:[ie,...m,...T,...D,$,H,...Z,J,ne],endsParent:!0,illegal:/["']/},ae={match:[/func/,/\s+/,o(q.match,w,v)],className:{1:"keyword",3:"title.function"},contains:[re,oe,t],illegal:[/\[/,/%/]},se={match:[/\b(?:subscript|init[?!]?)/,/\s*(?=[<(])/],className:{1:"keyword"},contains:[re,oe,t],illegal:/\[|%/},le={match:[/operator/,/\s+/,v],className:{1:"keyword",3:"title"}},ce={begin:[/precedencegroup/,/\s+/,O],className:{1:"keyword",3:"title"},contains:[J],keywords:[...h,...d],end:/}/};for(const n of H.variants){const e=n.contains.find(e=>"interpol"===e.label);e.keywords=A;const t=[...T,...P,...D,$,H,...K];e.contains=[...t,{begin:/\(/,end:/\)/,contains:["self",...t]}]}return{name:"Swift",keywords:A,contains:[...m,ae,se,{beginKeywords:"struct protocol class extension enum actor",end:"\\{",excludeEnd:!0,keywords:A,contains:[e.inherit(e.TITLE_MODE,{className:"title.class",begin:/[A-Za-z$_][\u00C0-\u02B80-9A-Za-z$_]*/}),...T]},le,ce,{beginKeywords:"import",end:/$/,contains:[...m],relevance:0},...T,...P,...D,$,H,...K,...Z,J,ne]}}e.exports=x},45745:function(e){const t="[A-Za-z$_][0-9A-Za-z$_]*",n=["as","in","of","if","for","while","finally","var","new","function","do","return","void","else","break","catch","instanceof","with","throw","case","default","try","switch","continue","typeof","delete","let","yield","const","class","debugger","async","await","static","import","from","export","extends"],r=["true","false","null","undefined","NaN","Infinity"],i=["Object","Function","Boolean","Symbol","Math","Date","Number","BigInt","String","RegExp","Array","Float32Array","Float64Array","Int8Array","Uint8Array","Uint8ClampedArray","Int16Array","Int32Array","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array","Set","Map","WeakSet","WeakMap","ArrayBuffer","SharedArrayBuffer","Atomics","DataView","JSON","Promise","Generator","GeneratorFunction","AsyncFunction","Reflect","Proxy","Intl","WebAssembly"],o=["Error","EvalError","InternalError","RangeError","ReferenceError","SyntaxError","TypeError","URIError"],a=["setInterval","setTimeout","clearInterval","clearTimeout","require","exports","eval","isFinite","isNaN","parseFloat","parseInt","decodeURI","decodeURIComponent","encodeURI","encodeURIComponent","escape","unescape"],s=["arguments","this","super","console","window","document","localStorage","module","global"],l=[].concat(a,i,o);function c(e){const c=e.regex,u=(e,{after:t})=>{const n="</"+e[0].slice(1),r=e.input.indexOf(n,t);return-1!==r},d=t,h={begin:"<>",end:"</>"},p=/<[A-Za-z0-9\\._:-]+\s*\/>/,f={begin:/<[A-Za-z0-9\\._:-]+/,end:/\/[A-Za-z0-9\\._:-]+>|\/>/,isTrulyOpeningTag:(e,t)=>{const n=e[0].length+e.index,r=e.input[n];if("<"===r||","===r)return void t.ignoreMatch();let i;">"===r&&(u(e,{after:n})||t.ignoreMatch());const o=e.input.substring(n);(i=o.match(/^\s+extends\s+/))&&0===i.index&&t.ignoreMatch()}},m={$pattern:t,keyword:n,literal:r,built_in:l,"variable.language":s},g="[0-9](_?[0-9])*",v=`\\.(${g})`,b="0|[1-9](_?[0-9])*|0[0-7]*[89][0-9]*",y={className:"number",variants:[{begin:`(\\b(${b})((${v})|\\.)?|(${v}))[eE][+-]?(${g})\\b`},{begin:`\\b(${b})\\b((${v})\\b|\\.)?|(${v})\\b`},{begin:"\\b(0|[1-9](_?[0-9])*)n\\b"},{begin:"\\b0[xX][0-9a-fA-F](_?[0-9a-fA-F])*n?\\b"},{begin:"\\b0[bB][0-1](_?[0-1])*n?\\b"},{begin:"\\b0[oO][0-7](_?[0-7])*n?\\b"},{begin:"\\b0[0-7]+n?\\b"}],relevance:0},w={className:"subst",begin:"\\$\\{",end:"\\}",keywords:m,contains:[]},O={begin:"html`",end:"",starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,w],subLanguage:"xml"}},S={begin:"css`",end:"",starts:{end:"`",returnEnd:!1,contains:[e.BACKSLASH_ESCAPE,w],subLanguage:"css"}},E={className:"string",begin:"`",end:"`",contains:[e.BACKSLASH_ESCAPE,w]},x=e.COMMENT(/\/\*\*(?!\/)/,"\\*/",{relevance:0,contains:[{begin:"(?=@[A-Za-z]+)",relevance:0,contains:[{className:"doctag",begin:"@[A-Za-z]+"},{className:"type",begin:"\\{",end:"\\}",excludeEnd:!0,excludeBegin:!0,relevance:0},{className:"variable",begin:d+"(?=\\s*(-)|$)",endsParent:!0,relevance:0},{begin:/(?=[^\n])\s/,relevance:0}]}]}),_={className:"comment",variants:[x,e.C_BLOCK_COMMENT_MODE,e.C_LINE_COMMENT_MODE]},k=[e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,O,S,E,y];w.contains=k.concat({begin:/\{/,end:/\}/,keywords:m,contains:["self"].concat(k)});const C=[].concat(_,w.contains),A=C.concat([{begin:/\(/,end:/\)/,keywords:m,contains:["self"].concat(C)}]),T={className:"params",begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:m,contains:A},R={variants:[{match:[/class/,/\s+/,d,/\s+/,/extends/,/\s+/,c.concat(d,"(",c.concat(/\./,d),")*")],scope:{1:"keyword",3:"title.class",5:"keyword",7:"title.class.inherited"}},{match:[/class/,/\s+/,d],scope:{1:"keyword",3:"title.class"}}]},N={relevance:0,match:c.either(/\bJSON/,/\b[A-Z][a-z]+([A-Z][a-z]*|\d)*/,/\b[A-Z]{2,}([A-Z][a-z]+|\d)+([A-Z][a-z]*)*/,/\b[A-Z]{2,}[a-z]+([A-Z][a-z]+|\d)*([A-Z][a-z]*)*/),className:"title.class",keywords:{_:[...i,...o]}},P={label:"use_strict",className:"meta",relevance:10,begin:/^\s*['"]use (strict|asm)['"]/},I={variants:[{match:[/function/,/\s+/,d,/(?=\s*\()/]},{match:[/function/,/\s*(?=\()/]}],className:{1:"keyword",3:"title.function"},label:"func.def",contains:[T],illegal:/%/},M={relevance:0,match:/\b[A-Z][A-Z_0-9]+\b/,className:"variable.constant"};function D(e){return c.concat("(?!",e.join("|"),")")}const L={match:c.concat(/\b/,D([...a,"super"]),d,c.lookahead(/\(/)),className:"title.function",relevance:0},B={begin:c.concat(/\./,c.lookahead(c.concat(d,/(?![0-9A-Za-z$_(])/))),end:d,excludeBegin:!0,keywords:"prototype",className:"property",relevance:0},$={match:[/get|set/,/\s+/,d,/(?=\()/],className:{1:"keyword",3:"title.function"},contains:[{begin:/\(\)/},T]},V="(\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)|"+e.UNDERSCORE_IDENT_RE+")\\s*=>",F={match:[/const|var|let/,/\s+/,d,/\s*/,/=\s*/,/(async\s*)?/,c.lookahead(V)],keywords:"async",className:{1:"keyword",3:"title.function"},contains:[T]};return{name:"Javascript",aliases:["js","jsx","mjs","cjs"],keywords:m,exports:{PARAMS_CONTAINS:A,CLASS_REFERENCE:N},illegal:/#(?![$_A-z])/,contains:[e.SHEBANG({label:"shebang",binary:"node",relevance:5}),P,e.APOS_STRING_MODE,e.QUOTE_STRING_MODE,O,S,E,_,y,N,{className:"attr",begin:d+c.lookahead(":"),relevance:0},F,{begin:"("+e.RE_STARTERS_RE+"|\\b(case|return|throw)\\b)\\s*",keywords:"return throw case",relevance:0,contains:[_,e.REGEXP_MODE,{className:"function",begin:V,returnBegin:!0,end:"\\s*=>",contains:[{className:"params",variants:[{begin:e.UNDERSCORE_IDENT_RE,relevance:0},{className:null,begin:/\(\s*\)/,skip:!0},{begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:m,contains:A}]}]},{begin:/,/,relevance:0},{match:/\s+/,relevance:0},{variants:[{begin:h.begin,end:h.end},{match:p},{begin:f.begin,"on:begin":f.isTrulyOpeningTag,end:f.end}],subLanguage:"xml",contains:[{begin:f.begin,end:f.end,skip:!0,contains:["self"]}]}]},I,{beginKeywords:"while if switch catch for"},{begin:"\\b(?!function)"+e.UNDERSCORE_IDENT_RE+"\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)\\s*\\{",returnBegin:!0,label:"func.def",contains:[T,e.inherit(e.TITLE_MODE,{begin:d,className:"title.function"})]},{match:/\.\.\./,relevance:0},B,{match:"\\$"+d,relevance:0},{match:[/\bconstructor(?=\s*\()/],className:{1:"title.function"},contains:[T]},L,M,R,$,{match:/\$[(.]/}]}}function u(e){const i=c(e),o=t,a=["any","void","number","boolean","string","object","never","symbol","bigint","unknown"],u={beginKeywords:"namespace",end:/\{/,excludeEnd:!0,contains:[i.exports.CLASS_REFERENCE]},d={beginKeywords:"interface",end:/\{/,excludeEnd:!0,keywords:{keyword:"interface extends",built_in:a},contains:[i.exports.CLASS_REFERENCE]},h={className:"meta",relevance:10,begin:/^\s*['"]use strict['"]/},p=["type","namespace","interface","public","private","protected","implements","declare","abstract","readonly","enum","override"],f={$pattern:t,keyword:n.concat(p),literal:r,built_in:l.concat(a),"variable.language":s},m={className:"meta",begin:"@"+o},g=(e,t,n)=>{const r=e.contains.findIndex(e=>e.label===t);if(-1===r)throw new Error("can not find mode to replace");e.contains.splice(r,1,n)};Object.assign(i.keywords,f),i.exports.PARAMS_CONTAINS.push(m),i.contains=i.contains.concat([m,u,d]),g(i,"shebang",e.SHEBANG()),g(i,"use_strict",h);const v=i.contains.find(e=>"func.def"===e.label);return v.relevance=0,Object.assign(i,{name:"TypeScript",aliases:["ts","tsx"]}),i}e.exports=u},21869:function(e){function t(e){const t=e.regex,n=t.concat(/[\p{L}_]/u,t.optional(/[\p{L}0-9_.-]*:/u),/[\p{L}0-9_.-]*/u),r=/[\p{L}0-9._:-]+/u,i={className:"symbol",begin:/&[a-z]+;|&#[0-9]+;|&#x[a-f0-9]+;/},o={begin:/\s/,contains:[{className:"keyword",begin:/#?[a-z_][a-z1-9_-]+/,illegal:/\n/}]},a=e.inherit(o,{begin:/\(/,end:/\)/}),s=e.inherit(e.APOS_STRING_MODE,{className:"string"}),l=e.inherit(e.QUOTE_STRING_MODE,{className:"string"}),c={endsWithParent:!0,illegal:/</,relevance:0,contains:[{className:"attr",begin:r,relevance:0},{begin:/=\s*/,relevance:0,contains:[{className:"string",endsParent:!0,variants:[{begin:/"/,end:/"/,contains:[i]},{begin:/'/,end:/'/,contains:[i]},{begin:/[^\s"'=<>`]+/}]}]}]};return{name:"HTML, XML",aliases:["html","xhtml","rss","atom","xjb","xsd","xsl","plist","wsf","svg"],case_insensitive:!0,unicodeRegex:!0,contains:[{className:"meta",begin:/<![a-z]/,end:/>/,relevance:10,contains:[o,l,s,a,{begin:/\[/,end:/\]/,contains:[{className:"meta",begin:/<![a-z]/,end:/>/,contains:[o,a,l,s]}]}]},e.COMMENT(/<!--/,/-->/,{relevance:10}),{begin:/<!\[CDATA\[/,end:/\]\]>/,relevance:10},i,{className:"meta",end:/\?>/,variants:[{begin:/<\?xml/,relevance:10,contains:[l]},{begin:/<\?[a-z][a-z0-9]+/}]},{className:"tag",begin:/<style(?=\s|>)/,end:/>/,keywords:{name:"style"},contains:[c],starts:{end:/<\/style>/,returnEnd:!0,subLanguage:["css","xml"]}},{className:"tag",begin:/<script(?=\s|>)/,end:/>/,keywords:{name:"script"},contains:[c],starts:{end:/<\/script>/,returnEnd:!0,subLanguage:["javascript","handlebars","xml"]}},{className:"tag",begin:/<>|<\/>/},{className:"tag",begin:t.concat(/</,t.lookahead(t.concat(n,t.either(/\/>/,/>/,/\s/)))),end:/\/?>/,contains:[{className:"name",begin:n,relevance:0,starts:c}]},{className:"tag",begin:t.concat(/<\//,t.lookahead(t.concat(n,/>/))),contains:[{className:"name",begin:n,relevance:0},{begin:/>/,relevance:0,endsParent:!0}]}]}}e.exports=t},98005:function(e){function t(e){const t="true false yes no null",n="[\\w#;/?:@&=+$,.~*'()[\\]]+",r={className:"attr",variants:[{begin:"\\w[\\w :\\/.-]*:(?=[ \t]|$)"},{begin:'"\\w[\\w :\\/.-]*":(?=[ \t]|$)'},{begin:"'\\w[\\w :\\/.-]*':(?=[ \t]|$)"}]},i={className:"template-variable",variants:[{begin:/\{\{/,end:/\}\}/},{begin:/%\{/,end:/\}/}]},o={className:"string",relevance:0,variants:[{begin:/'/,end:/'/},{begin:/"/,end:/"/},{begin:/\S+/}],contains:[e.BACKSLASH_ESCAPE,i]},a=e.inherit(o,{variants:[{begin:/'/,end:/'/},{begin:/"/,end:/"/},{begin:/[^\s,{}[\]]+/}]}),s="[0-9]{4}(-[0-9][0-9]){0,2}",l="([Tt \\t][0-9][0-9]?(:[0-9][0-9]){2})?",c="(\\.[0-9]*)?",u="([ \\t])*(Z|[-+][0-9][0-9]?(:[0-9][0-9])?)?",d={className:"number",begin:"\\b"+s+l+c+u+"\\b"},h={end:",",endsWithParent:!0,excludeEnd:!0,keywords:t,relevance:0},p={begin:/\{/,end:/\}/,contains:[h],illegal:"\\n",relevance:0},f={begin:"\\[",end:"\\]",contains:[h],illegal:"\\n",relevance:0},m=[r,{className:"meta",begin:"^---\\s*$",relevance:10},{className:"string",begin:"[\\|>]([1-9]?[+-])?[ ]*\\n( +)[^ ][^\\n]*\\n(\\2[^\\n]+\\n?)*"},{begin:"<%[%=-]?",end:"[%-]?%>",subLanguage:"ruby",excludeBegin:!0,excludeEnd:!0,relevance:0},{className:"type",begin:"!\\w+!"+n},{className:"type",begin:"!<"+n+">"},{className:"type",begin:"!"+n},{className:"type",begin:"!!"+n},{className:"meta",begin:"&"+e.UNDERSCORE_IDENT_RE+"$"},{className:"meta",begin:"\\*"+e.UNDERSCORE_IDENT_RE+"$"},{className:"bullet",begin:"-(?=[ ]|$)",relevance:0},e.HASH_COMMENT_MODE,{beginKeywords:t,keywords:{literal:t}},d,{className:"number",begin:e.C_NUMBER_RE+"\\b",relevance:0},p,f,o],g=[...m];return g.pop(),g.push(a),h.contains=g,{name:"YAML",case_insensitive:!0,aliases:["yml"],contains:m}}e.exports=t},47143:function(e,t,n){"use strict";n.r(t),n.d(t,{addCursorAbove:function(){return Pt},addCursorBelow:function(){return It},blockComment:function(){return p},blockUncomment:function(){return f},canRedoSelection:function(){return V},canUndoSelection:function(){return $},copyLineDown:function(){return on},copyLineUp:function(){return rn},cursorCharBackward:function(){return ce},cursorCharBackwardLogical:function(){return pe},cursorCharForward:function(){return le},cursorCharForwardLogical:function(){return he},cursorCharLeft:function(){return ae},cursorCharRight:function(){return se},cursorDocEnd:function(){return _t},cursorDocStart:function(){return xt},cursorGroupBackward:function(){return be},cursorGroupForward:function(){return ve},cursorGroupForwardWin:function(){return we},cursorGroupLeft:function(){return me},cursorGroupRight:function(){return ge},cursorLineBoundaryBackward:function(){return Ve},cursorLineBoundaryForward:function(){return $e},cursorLineBoundaryLeft:function(){return Fe},cursorLineBoundaryRight:function(){return je},cursorLineDown:function(){return Pe},cursorLineEnd:function(){return Ge},cursorLineStart:function(){return Ue},cursorLineUp:function(){return Ne},cursorMatchingBracket:function(){return qe},cursorPageDown:function(){return Le},cursorPageUp:function(){return De},cursorSubwordBackward:function(){return _e},cursorSubwordForward:function(){return xe},cursorSyntaxLeft:function(){return Ae},cursorSyntaxRight:function(){return Te},defaultKeymap:function(){return Sn},deleteCharBackward:function(){return $t},deleteCharBackwardStrict:function(){return Vt},deleteCharForward:function(){return Ft},deleteGroupBackward:function(){return Ut},deleteGroupForward:function(){return Gt},deleteGroupForwardWin:function(){return Ht},deleteLine:function(){return an},deleteLineBoundaryBackward:function(){return zt},deleteLineBoundaryForward:function(){return Kt},deleteToLineEnd:function(){return qt},deleteToLineStart:function(){return Qt},deleteTrailingWhitespace:function(){return Wt},emacsStyleKeymap:function(){return wn},history:function(){return C},historyField:function(){return A},historyKeymap:function(){return J},indentLess:function(){return gn},indentMore:function(){return mn},indentSelection:function(){return fn},indentWithTab:function(){return En},insertBlankLine:function(){return dn},insertNewline:function(){return sn},insertNewlineAndIndent:function(){return un},insertNewlineKeepIndent:function(){return ln},insertTab:function(){return yn},invertedEffects:function(){return x},isolateHistory:function(){return E},lineComment:function(){return u},lineUncomment:function(){return d},moveLineDown:function(){return tn},moveLineUp:function(){return en},redo:function(){return N},redoDepth:function(){return L},redoSelection:function(){return I},selectAll:function(){return At},selectCharBackward:function(){return Ze},selectCharBackwardLogical:function(){return et},selectCharForward:function(){return Ye},selectCharForwardLogical:function(){return Je},selectCharLeft:function(){return We},selectCharRight:function(){return Xe},selectDocEnd:function(){return Ct},selectDocStart:function(){return kt},selectGroupBackward:function(){return ot},selectGroupForward:function(){return it},selectGroupForwardWin:function(){return at},selectGroupLeft:function(){return nt},selectGroupRight:function(){return rt},selectLine:function(){return Tt},selectLineBoundaryBackward:function(){return yt},selectLineBoundaryForward:function(){return bt},selectLineBoundaryLeft:function(){return wt},selectLineBoundaryRight:function(){return Ot},selectLineDown:function(){return ft},selectLineEnd:function(){return Et},selectLineStart:function(){return St},selectLineUp:function(){return pt},selectMatchingBracket:function(){return Qe},selectPageDown:function(){return vt},selectPageUp:function(){return gt},selectParentSyntax:function(){return Rt},selectSubwordBackward:function(){return ct},selectSubwordForward:function(){return lt},selectSyntaxLeft:function(){return ut},selectSyntaxRight:function(){return dt},simplifySelection:function(){return Mt},splitLine:function(){return Xt},standardKeymap:function(){return On},temporarilySetTabFocusMode:function(){return bn},toggleBlockComment:function(){return h},toggleBlockCommentByLine:function(){return m},toggleComment:function(){return s},toggleLineComment:function(){return c},toggleTabFocusMode:function(){return vn},transposeChars:function(){return Yt},undo:function(){return R},undoDepth:function(){return D},undoSelection:function(){return P}});var r=n(76528),i=n(81068),o=n(61163),a=n(43114);const s=e=>{let{state:t}=e,n=t.doc.lineAt(t.selection.main.from),r=g(e.state,n.from);return r.line?c(e):!!r.block&&m(e)};function l(e,t){return({state:n,dispatch:r})=>{if(n.readOnly)return!1;let i=e(t,n);return!!i&&(r(n.update(i)),!0)}}const c=l(O,0),u=l(O,1),d=l(O,2),h=l(w,0),p=l(w,1),f=l(w,2),m=l((e,t)=>w(e,t,y(t)),0);function g(e,t){let n=e.languageDataAt("commentTokens",t,1);return n.length?n[0]:{}}const v=50;function b(e,{open:t,close:n},r,i){let o,a,s=e.sliceDoc(r-v,r),l=e.sliceDoc(i,i+v),c=/\s*$/.exec(s)[0].length,u=/^\s*/.exec(l)[0].length,d=s.length-c;if(s.slice(d-t.length,d)==t&&l.slice(u,u+n.length)==n)return{open:{pos:r-c,margin:c&&1},close:{pos:i+u,margin:u&&1}};i-r<=2*v?o=a=e.sliceDoc(r,i):(o=e.sliceDoc(r,r+v),a=e.sliceDoc(i-v,i));let h=/^\s*/.exec(o)[0].length,p=/\s*$/.exec(a)[0].length,f=a.length-p-n.length;return o.slice(h,h+t.length)==t&&a.slice(f,f+n.length)==n?{open:{pos:r+h+t.length,margin:/\s/.test(o.charAt(h+t.length))?1:0},close:{pos:i-p-n.length,margin:/\s/.test(a.charAt(f-1))?1:0}}:null}function y(e){let t=[];for(let n of e.selection.ranges){let r=e.doc.lineAt(n.from),i=n.to<=r.to?r:e.doc.lineAt(n.to);i.from>r.from&&i.from==n.to&&(i=n.to==r.to+1?r:e.doc.lineAt(n.to-1));let o=t.length-1;o>=0&&t[o].to>r.from?t[o].to=i.to:t.push({from:r.from+/^\s*/.exec(r.text)[0].length,to:i.to})}return t}function w(e,t,n=t.selection.ranges){let r=n.map(e=>g(t,e.from).block);if(!r.every(e=>e))return null;let i=n.map((e,n)=>b(t,r[n],e.from,e.to));if(2!=e&&!i.every(e=>e))return{changes:t.changes(n.map((e,t)=>i[t]?[]:[{from:e.from,insert:r[t].open+" "},{from:e.to,insert:" "+r[t].close}]))};if(1!=e&&i.some(e=>e)){let e=[];for(let t,n=0;n<i.length;n++)if(t=i[n]){let i=r[n],{open:o,close:a}=t;e.push({from:o.pos-i.open.length,to:o.pos+o.margin},{from:a.pos-a.margin,to:a.pos+i.close.length})}return{changes:e}}return null}function O(e,t,n=t.selection.ranges){let r=[],i=-1;e:for(let{from:o,to:a}of n){let e,n=r.length,s=1e9;for(let l=o;l<=a;){let n=t.doc.lineAt(l);if(void 0==e&&(e=g(t,n.from).line,!e))continue e;if(n.from>i&&(o==a||a>n.from)){i=n.from;let t=/^\s*/.exec(n.text)[0].length,o=t==n.length,a=n.text.slice(t,t+e.length)==e?t:-1;t<n.text.length&&t<s&&(s=t),r.push({line:n,comment:a,token:e,indent:t,empty:o,single:!1})}l=n.to+1}if(s<1e9)for(let t=n;t<r.length;t++)r[t].indent<r[t].line.text.length&&(r[t].indent=s);r.length==n+1&&(r[n].single=!0)}if(2!=e&&r.some(e=>e.comment<0&&(!e.empty||e.single))){let e=[];for(let{line:t,token:i,indent:o,empty:a,single:s}of r)!s&&a||e.push({from:t.from+o,insert:i+" "});let n=t.changes(e);return{changes:n,selection:t.selection.map(n,1)}}if(1!=e&&r.some(e=>e.comment>=0)){let e=[];for(let{line:t,comment:n,token:i}of r)if(n>=0){let r=t.from+n,o=r+i.length;" "==t.text[o-t.from]&&o++,e.push({from:r,to:o})}return{changes:e}}return null}const S=r.Annotation.define(),E=r.Annotation.define(),x=r.Facet.define(),_=r.Facet.define({combine(e){return(0,r.combineConfig)(e,{minDepth:100,newGroupDelay:500,joinToEvent:(e,t)=>t},{minDepth:Math.max,newGroupDelay:Math.min,joinToEvent:(e,t)=>(n,r)=>e(n,r)||t(n,r)})}}),k=r.StateField.define({create(){return Z.empty},update(e,t){let n=t.state.facet(_),i=t.annotation(S);if(i){let r=F.fromTransaction(t,i.selection),o=i.side,a=0==o?e.undone:e.done;return a=r?j(a,a.length,n.minDepth,r):z(a,t.startState.selection),new Z(0==o?i.rest:a,0==o?a:i.rest)}let o=t.annotation(E);if("full"!=o&&"before"!=o||(e=e.isolate()),!1===t.annotation(r.Transaction.addToHistory))return t.changes.empty?e:e.addMapping(t.changes.desc);let a=F.fromTransaction(t),s=t.annotation(r.Transaction.time),l=t.annotation(r.Transaction.userEvent);return a?e=e.addChanges(a,s,l,n,t):t.selection&&(e=e.addSelection(t.startState.selection,s,l,n.newGroupDelay)),"full"!=o&&"after"!=o||(e=e.isolate()),e},toJSON(e){return{done:e.done.map(e=>e.toJSON()),undone:e.undone.map(e=>e.toJSON())}},fromJSON(e){return new Z(e.done.map(F.fromJSON),e.undone.map(F.fromJSON))}});function C(e={}){return[k,_.of(e),i.EditorView.domEventHandlers({beforeinput(e,t){let n="historyUndo"==e.inputType?R:"historyRedo"==e.inputType?N:null;return!!n&&(e.preventDefault(),n(t))}})]}const A=k;function T(e,t){return function({state:n,dispatch:r}){if(!t&&n.readOnly)return!1;let i=n.field(k,!1);if(!i)return!1;let o=i.pop(e,n,t);return!!o&&(r(o),!0)}}const R=T(0,!1),N=T(1,!1),P=T(0,!0),I=T(1,!0);function M(e){return function(t){let n=t.field(k,!1);if(!n)return 0;let r=0==e?n.done:n.undone;return r.length-(r.length&&!r[0].changes?1:0)}}const D=M(0),L=M(1);function B(e){return function(t){let n=t.field(k,!1);if(!n)return!1;let r=0==e?n.done:n.undone;return r.length>0&&r[0].selectionsAfter.length>0}}const $=B(0),V=B(0);class F{constructor(e,t,n,r,i){this.changes=e,this.effects=t,this.mapped=n,this.startSelection=r,this.selectionsAfter=i}setSelAfter(e){return new F(this.changes,this.effects,this.mapped,this.startSelection,e)}toJSON(){var e,t,n;return{changes:null===(e=this.changes)||void 0===e?void 0:e.toJSON(),mapped:null===(t=this.mapped)||void 0===t?void 0:t.toJSON(),startSelection:null===(n=this.startSelection)||void 0===n?void 0:n.toJSON(),selectionsAfter:this.selectionsAfter.map(e=>e.toJSON())}}static fromJSON(e){return new F(e.changes&&r.ChangeSet.fromJSON(e.changes),[],e.mapped&&r.ChangeDesc.fromJSON(e.mapped),e.startSelection&&r.EditorSelection.fromJSON(e.startSelection),e.selectionsAfter.map(r.EditorSelection.fromJSON))}static fromTransaction(e,t){let n=q;for(let r of e.startState.facet(x)){let t=r(e);t.length&&(n=n.concat(t))}return!n.length&&e.changes.empty?null:new F(e.changes.invert(e.startState.doc),n,void 0,t||e.startState.selection,q)}static selection(e){return new F(void 0,q,void 0,void 0,e)}}function j(e,t,n,r){let i=t+1>n+20?t-n-1:0,o=e.slice(i,t);return o.push(r),o}function U(e,t){let n=[],r=!1;return e.iterChangedRanges((e,t)=>n.push(e,t)),t.iterChangedRanges((e,t,i,o)=>{for(let a=0;a<n.length;){let e=n[a++],t=n[a++];o>=e&&i<=t&&(r=!0)}}),r}function G(e,t){return e.ranges.length==t.ranges.length&&0===e.ranges.filter((e,n)=>e.empty!=t.ranges[n].empty).length}function H(e,t){return e.length?t.length?e.concat(t):e:t}const q=[],Q=200;function z(e,t){if(e.length){let n=e[e.length-1],r=n.selectionsAfter.slice(Math.max(0,n.selectionsAfter.length-Q));return r.length&&r[r.length-1].eq(t)?e:(r.push(t),j(e,e.length-1,1e9,n.setSelAfter(r)))}return[F.selection([t])]}function K(e){let t=e[e.length-1],n=e.slice();return n[e.length-1]=t.setSelAfter(t.selectionsAfter.slice(0,t.selectionsAfter.length-1)),n}function W(e,t){if(!e.length)return e;let n=e.length,r=q;while(n){let i=X(e[n-1],t,r);if(i.changes&&!i.changes.empty||i.effects.length){let t=e.slice(0,n);return t[n-1]=i,t}t=i.mapped,n--,r=i.selectionsAfter}return r.length?[F.selection(r)]:q}function X(e,t,n){let i=H(e.selectionsAfter.length?e.selectionsAfter.map(e=>e.map(t)):q,n);if(!e.changes)return F.selection(i);let o=e.changes.map(t),a=t.mapDesc(e.changes,!0),s=e.mapped?e.mapped.composeDesc(a):a;return new F(o,r.StateEffect.mapEffects(e.effects,t),s,e.startSelection.map(a),i)}const Y=/^(input\.type|delete)($|\.)/;class Z{constructor(e,t,n=0,r=void 0){this.done=e,this.undone=t,this.prevTime=n,this.prevUserEvent=r}isolate(){return this.prevTime?new Z(this.done,this.undone):this}addChanges(e,t,n,i,o){let a=this.done,s=a[a.length-1];return a=s&&s.changes&&!s.changes.empty&&e.changes&&(!n||Y.test(n))&&(!s.selectionsAfter.length&&t-this.prevTime<i.newGroupDelay&&i.joinToEvent(o,U(s.changes,e.changes))||"input.type.compose"==n)?j(a,a.length-1,i.minDepth,new F(e.changes.compose(s.changes),H(r.StateEffect.mapEffects(e.effects,s.changes),s.effects),s.mapped,s.startSelection,q)):j(a,a.length,i.minDepth,e),new Z(a,q,t,n)}addSelection(e,t,n,r){let i=this.done.length?this.done[this.done.length-1].selectionsAfter:q;return i.length>0&&t-this.prevTime<r&&n==this.prevUserEvent&&n&&/^select($|\.)/.test(n)&&G(i[i.length-1],e)?this:new Z(z(this.done,e),this.undone,t,n)}addMapping(e){return new Z(W(this.done,e),W(this.undone,e),this.prevTime,this.prevUserEvent)}pop(e,t,n){let r=0==e?this.done:this.undone;if(0==r.length)return null;let i=r[r.length-1],o=i.selectionsAfter[0]||(i.startSelection?i.startSelection.map(i.changes.invertedDesc,1):t.selection);if(n&&i.selectionsAfter.length)return t.update({selection:i.selectionsAfter[i.selectionsAfter.length-1],annotations:S.of({side:e,rest:K(r),selection:o}),userEvent:0==e?"select.undo":"select.redo",scrollIntoView:!0});if(i.changes){let n=1==r.length?q:r.slice(0,r.length-1);return i.mapped&&(n=W(n,i.mapped)),t.update({changes:i.changes,selection:i.startSelection,effects:i.effects,annotations:S.of({side:e,rest:n,selection:o}),filter:!1,userEvent:0==e?"undo":"redo",scrollIntoView:!0})}return null}}Z.empty=new Z(q,q);const J=[{key:"Mod-z",run:R,preventDefault:!0},{key:"Mod-y",mac:"Mod-Shift-z",run:N,preventDefault:!0},{linux:"Ctrl-Shift-z",run:N,preventDefault:!0},{key:"Mod-u",run:P,preventDefault:!0},{key:"Alt-u",mac:"Mod-Shift-u",run:I,preventDefault:!0}];function ee(e,t){return r.EditorSelection.create(e.ranges.map(t),e.mainIndex)}function te(e,t){return e.update({selection:t,scrollIntoView:!0,userEvent:"select"})}function ne({state:e,dispatch:t},n){let r=ee(e.selection,n);return!r.eq(e.selection,!0)&&(t(te(e,r)),!0)}function re(e,t){return r.EditorSelection.cursor(t?e.to:e.from)}function ie(e,t){return ne(e,n=>n.empty?e.moveByChar(n,t):re(n,t))}function oe(e){return e.textDirectionAt(e.state.selection.main.head)==i.Direction.LTR}const ae=e=>ie(e,!oe(e)),se=e=>ie(e,oe(e)),le=e=>ie(e,!0),ce=e=>ie(e,!1);function ue(e,t,n){let i=t.head,o=e.doc.lineAt(i);return i=i==(n?o.to:o.from)?n?Math.min(e.doc.length,o.to+1):Math.max(0,o.from-1):o.from+(0,r.findClusterBreak)(o.text,i-o.from,n),r.EditorSelection.cursor(i,n?-1:1)}function de(e,t){return ne(e,n=>n.empty?ue(e.state,n,t):re(n,t))}const he=e=>de(e,!0),pe=e=>de(e,!1);function fe(e,t){return ne(e,n=>n.empty?e.moveByGroup(n,t):re(n,t))}const me=e=>fe(e,!oe(e)),ge=e=>fe(e,oe(e)),ve=e=>fe(e,!0),be=e=>fe(e,!1);function ye(e,t,n){let i=e.state.charCategorizer(t),o=i(n),a=o!=r.CharCategory.Space;return e=>{let t=i(e);return t!=r.CharCategory.Space?a&&t==o:(a=!1,!0)}}const we=e=>ne(e,t=>t.empty?e.moveByChar(t,!0,n=>ye(e,t.head,n)):re(t,!0)),Oe="undefined"!=typeof Intl&&Intl.Segmenter?new Intl.Segmenter(void 0,{granularity:"word"}):null;function Se(e,t,n){let i=e.state.charCategorizer(t.from),o=r.CharCategory.Space,a=t.from,s=0,l=!1,c=!1,u=!1,d=t=>{if(l)return!1;a+=n?t.length:-t.length;let d,h=i(t);if(h==r.CharCategory.Word&&t.charCodeAt(0)<128&&/[\W_]/.test(t)&&(h=-1),o==r.CharCategory.Space&&(o=h),o!=h)return!1;if(o==r.CharCategory.Word)if(t.toLowerCase()==t){if(!n&&c)return!1;u=!0}else if(u){if(n)return!1;l=!0}else{if(c&&n&&i(d=e.state.sliceDoc(a,a+1))==r.CharCategory.Word&&d.toLowerCase()==d)return!1;c=!0}return s++,!0},h=e.moveByChar(t,n,e=>(d(e),d));if(Oe&&o==r.CharCategory.Word&&h.from==t.from+s*(n?1:-1)){let i=Math.min(t.head,h.head),o=Math.max(t.head,h.head),a=e.state.sliceDoc(i,o);if(a.length>1&&/[\u4E00-\uffff]/.test(a)){let e=Array.from(Oe.segment(a));if(e.length>1)return n?r.EditorSelection.cursor(t.head+e[1].index,-1):r.EditorSelection.cursor(h.head+e[e.length-1].index,1)}}return h}function Ee(e,t){return ne(e,n=>n.empty?Se(e,n,t):re(n,t))}const xe=e=>Ee(e,!0),_e=e=>Ee(e,!1);function ke(e,t,n){if(t.type.prop(n))return!0;let r=t.to-t.from;return r&&(r>2||/[^\s,.;:]/.test(e.sliceDoc(t.from,t.to)))||t.firstChild}function Ce(e,t,n){let i=(0,o.syntaxTree)(e).resolveInner(t.head),s=n?a.NodeProp.closedBy:a.NodeProp.openedBy;for(let r=t.head;;){let t=n?i.childAfter(r):i.childBefore(r);if(!t)break;ke(e,t,s)?i=t:r=n?t.to:t.from}let l,c,u=i.type.prop(s);return c=u&&(l=n?(0,o.matchBrackets)(e,i.from,1):(0,o.matchBrackets)(e,i.to,-1))&&l.matched?n?l.end.to:l.end.from:n?i.to:i.from,r.EditorSelection.cursor(c,n?-1:1)}const Ae=e=>ne(e,t=>Ce(e.state,t,!oe(e))),Te=e=>ne(e,t=>Ce(e.state,t,oe(e)));function Re(e,t){return ne(e,n=>{if(!n.empty)return re(n,t);let r=e.moveVertically(n,t);return r.head!=n.head?r:e.moveToLineBoundary(n,t)})}const Ne=e=>Re(e,!1),Pe=e=>Re(e,!0);function Ie(e){let t,n=e.scrollDOM.clientHeight<e.scrollDOM.scrollHeight-2,r=0,o=0;if(n){for(let t of e.state.facet(i.EditorView.scrollMargins)){let n=t(e);(null===n||void 0===n?void 0:n.top)&&(r=Math.max(null===n||void 0===n?void 0:n.top,r)),(null===n||void 0===n?void 0:n.bottom)&&(o=Math.max(null===n||void 0===n?void 0:n.bottom,o))}t=e.scrollDOM.clientHeight-r-o}else t=(e.dom.ownerDocument.defaultView||window).innerHeight;return{marginTop:r,marginBottom:o,selfScroll:n,height:Math.max(e.defaultLineHeight,t-5)}}function Me(e,t){let n,r=Ie(e),{state:o}=e,a=ee(o.selection,n=>n.empty?e.moveVertically(n,t,r.height):re(n,t));if(a.eq(o.selection))return!1;if(r.selfScroll){let t=e.coordsAtPos(o.selection.main.head),s=e.scrollDOM.getBoundingClientRect(),l=s.top+r.marginTop,c=s.bottom-r.marginBottom;t&&t.top>l&&t.bottom<c&&(n=i.EditorView.scrollIntoView(a.main.head,{y:"start",yMargin:t.top-l}))}return e.dispatch(te(o,a),{effects:n}),!0}const De=e=>Me(e,!1),Le=e=>Me(e,!0);function Be(e,t,n){let i=e.lineBlockAt(t.head),o=e.moveToLineBoundary(t,n);if(o.head==t.head&&o.head!=(n?i.to:i.from)&&(o=e.moveToLineBoundary(t,n,!1)),!n&&o.head==i.from&&i.length){let n=/^\s*/.exec(e.state.sliceDoc(i.from,Math.min(i.from+100,i.to)))[0].length;n&&t.head!=i.from+n&&(o=r.EditorSelection.cursor(i.from+n))}return o}const $e=e=>ne(e,t=>Be(e,t,!0)),Ve=e=>ne(e,t=>Be(e,t,!1)),Fe=e=>ne(e,t=>Be(e,t,!oe(e))),je=e=>ne(e,t=>Be(e,t,oe(e))),Ue=e=>ne(e,t=>e.moveToLineBoundary(t,!1,!1)),Ge=e=>ne(e,t=>e.moveToLineBoundary(t,!0,!1));function He(e,t,n){let i=!1,a=ee(e.selection,t=>{let a=(0,o.matchBrackets)(e,t.head,-1)||(0,o.matchBrackets)(e,t.head,1)||t.head>0&&(0,o.matchBrackets)(e,t.head-1,1)||t.head<e.doc.length&&(0,o.matchBrackets)(e,t.head+1,-1);if(!a||!a.end)return t;i=!0;let s=a.start.from==t.head?a.end.to:a.end.from;return n?r.EditorSelection.range(t.anchor,s):r.EditorSelection.cursor(s)});return!!i&&(t(te(e,a)),!0)}const qe=({state:e,dispatch:t})=>He(e,t,!1),Qe=({state:e,dispatch:t})=>He(e,t,!0);function ze(e,t,n){let i=ee(e.state.selection,e=>{e.undirectional&&e.head>=e.anchor!=t&&(e=r.EditorSelection.range(e.head,e.anchor));let i=n(e);return r.EditorSelection.range(e.anchor,i.head,i.goalColumn,i.bidiLevel||void 0,i.assoc)});return!i.eq(e.state.selection)&&(e.dispatch(te(e.state,i)),!0)}function Ke(e,t){return ze(e,t,n=>e.moveByChar(n,t))}const We=e=>Ke(e,!oe(e)),Xe=e=>Ke(e,oe(e)),Ye=e=>Ke(e,!0),Ze=e=>Ke(e,!1),Je=e=>ze(e,!0,t=>ue(e.state,t,!0)),et=e=>ze(e,!1,t=>ue(e.state,t,!1));function tt(e,t){return ze(e,t,n=>e.moveByGroup(n,t))}const nt=e=>tt(e,!oe(e)),rt=e=>tt(e,oe(e)),it=e=>tt(e,!0),ot=e=>tt(e,!1),at=e=>ze(e,!0,t=>e.moveByChar(t,!0,n=>ye(e,t.head,n)));function st(e,t){return ze(e,t,n=>Se(e,n,t))}const lt=e=>st(e,!0),ct=e=>st(e,!1),ut=e=>{let t=!oe(e);return ze(e,t,n=>Ce(e.state,n,t))},dt=e=>{let t=oe(e);return ze(e,t,n=>Ce(e.state,n,t))};function ht(e,t){return ze(e,t,n=>e.moveVertically(n,t))}const pt=e=>ht(e,!1),ft=e=>ht(e,!0);function mt(e,t){return ze(e,t,n=>e.moveVertically(n,t,Ie(e).height))}const gt=e=>mt(e,!1),vt=e=>mt(e,!0),bt=e=>ze(e,!0,t=>Be(e,t,!0)),yt=e=>ze(e,!1,t=>Be(e,t,!1)),wt=e=>{let t=!oe(e);return ze(e,t,n=>Be(e,n,t))},Ot=e=>{let t=oe(e);return ze(e,t,n=>Be(e,n,t))},St=e=>ze(e,!1,t=>r.EditorSelection.cursor(e.lineBlockAt(t.head).from)),Et=e=>ze(e,!0,t=>r.EditorSelection.cursor(e.lineBlockAt(t.head).to)),xt=({state:e,dispatch:t})=>(t(te(e,{anchor:0})),!0),_t=({state:e,dispatch:t})=>(t(te(e,{anchor:e.doc.length})),!0),kt=({state:e,dispatch:t})=>(t(te(e,{anchor:e.selection.main.anchor,head:0})),!0),Ct=({state:e,dispatch:t})=>(t(te(e,{anchor:e.selection.main.anchor,head:e.doc.length})),!0),At=({state:e,dispatch:t})=>(t(e.update({selection:{anchor:0,head:e.doc.length},userEvent:"select"})),!0),Tt=({state:e,dispatch:t})=>{let n=Zt(e).map(({from:t,to:n})=>r.EditorSelection.undirectionalRange(t,Math.min(n+1,e.doc.length)));return t(e.update({selection:r.EditorSelection.create(n),userEvent:"select"})),!0},Rt=({state:e,dispatch:t})=>{let n=ee(e.selection,t=>{let n=(0,o.syntaxTree)(e),i=n.resolveStack(t.from,1);if(t.empty){let e=n.resolveStack(t.from,-1);e.node.from>=i.node.from&&e.node.to<=i.node.to&&(i=e)}for(let e=i;e;e=e.next){let{node:n}=e;if((n.from<t.from&&n.to>=t.to||n.to>t.to&&n.from<=t.from)&&e.next)return r.EditorSelection.undirectionalRange(n.from,n.to)}return t});return!n.eq(e.selection)&&(t(te(e,n)),!0)};function Nt(e,t){let{state:n}=e,i=n.selection,o=n.selection.ranges.slice();for(let r of n.selection.ranges){let i=n.doc.lineAt(r.head);if(t?i.to<e.state.doc.length:i.from>0)for(let n=r;;){let r=e.moveVertically(n,t);if(r.head<i.from||r.head>i.to){o.some(e=>e.head==r.head)||o.push(r);break}if(r.head==n.head)break;n=r}}return o.length!=i.ranges.length&&(e.dispatch(te(n,r.EditorSelection.create(o,o.length-1))),!0)}const Pt=e=>Nt(e,!1),It=e=>Nt(e,!0),Mt=({state:e,dispatch:t})=>{let n=e.selection,i=null;return n.ranges.length>1?i=r.EditorSelection.create([n.main]):n.main.empty||(i=r.EditorSelection.create([r.EditorSelection.cursor(n.main.head)])),!!i&&(t(te(e,i)),!0)};function Dt(e,t){if(e.state.readOnly)return!1;let n="delete.selection",{state:o}=e,a=o.changeByRange(i=>{let{from:o,to:a}=i;if(o==a){let r=t(i);r<o?(n="delete.backward",r=Lt(e,r,!1)):r>o&&(n="delete.forward",r=Lt(e,r,!0)),o=Math.min(o,r),a=Math.max(a,r)}else o=Lt(e,o,!1),a=Lt(e,a,!0);return o==a?{range:i}:{changes:{from:o,to:a},range:r.EditorSelection.cursor(o,o<i.head?-1:1)}});return!a.changes.empty&&(e.dispatch(o.update(a,{scrollIntoView:!0,userEvent:n,effects:"delete.selection"==n?i.EditorView.announce.of(o.phrase("Selection deleted")):void 0})),!0)}function Lt(e,t,n){if(e instanceof i.EditorView)for(let r of e.state.facet(i.EditorView.atomicRanges).map(t=>t(e)))r.between(t,t,(e,r)=>{e<t&&r>t&&(t=n?r:e)});return t}const Bt=(e,t,n)=>Dt(e,i=>{let a,s,l=i.from,{state:c}=e,u=c.doc.lineAt(l);if(n&&!t&&l>u.from&&l<u.from+200&&!/[^ \t]/.test(a=u.text.slice(0,l-u.from))){if("\t"==a[a.length-1])return l-1;let e=(0,r.countColumn)(a,c.tabSize),t=e%(0,o.getIndentUnit)(c)||(0,o.getIndentUnit)(c);for(let n=0;n<t&&" "==a[a.length-1-n];n++)l--;s=l}else s=(0,r.findClusterBreak)(u.text,l-u.from,t,t)+u.from,s==l&&u.number!=(t?c.doc.lines:1)?s+=t?1:-1:!t&&/[\ufe00-\ufe0f]/.test(u.text.slice(s-u.from,l-u.from))&&(s=(0,r.findClusterBreak)(u.text,s-u.from,!1,!1)+u.from);return s}),$t=e=>Bt(e,!1,!0),Vt=e=>Bt(e,!1,!1),Ft=e=>Bt(e,!0,!1),jt=(e,t)=>Dt(e,n=>{let i=n.head,{state:o}=e,a=o.doc.lineAt(i),s=o.charCategorizer(i);for(let e=null;;){if(i==(t?a.to:a.from)){i==n.head&&a.number!=(t?o.doc.lines:1)&&(i+=t?1:-1);break}let l=(0,r.findClusterBreak)(a.text,i-a.from,t)+a.from,c=a.text.slice(Math.min(i,l)-a.from,Math.max(i,l)-a.from),u=s(c);if(null!=e&&u!=e)break;" "==c&&i==n.head||(e=u),i=l}return i}),Ut=e=>jt(e,!1),Gt=e=>jt(e,!0),Ht=e=>Dt(e,t=>e.moveByChar(t,!0,n=>ye(e,t.head,n)).head),qt=e=>Dt(e,t=>{let n=e.lineBlockAt(t.head).to;return t.head<n?n:Math.min(e.state.doc.length,t.head+1)}),Qt=e=>Dt(e,t=>{let n=e.lineBlockAt(t.head).from;return t.head>n?n:Math.max(0,t.head-1)}),zt=e=>Dt(e,t=>{let n=e.moveToLineBoundary(t,!1).head;return t.head>n?n:Math.max(0,t.head-1)}),Kt=e=>Dt(e,t=>{let n=e.moveToLineBoundary(t,!0).head;return t.head<n?n:Math.min(e.state.doc.length,t.head+1)}),Wt=({state:e,dispatch:t})=>{if(e.readOnly)return!1;let n=[];for(let r=0,i="",o=e.doc.iter();;){if(o.next(),o.lineBreak||o.done){let e=i.search(/\s+$/);if(e>-1&&n.push({from:r-(i.length-e),to:r}),o.done)break;i=""}else i=o.value;r+=o.value.length}return!!n.length&&(t(e.update({changes:n,userEvent:"delete"})),!0)},Xt=({state:e,dispatch:t})=>{if(e.readOnly)return!1;let n=e.changeByRange(e=>({changes:{from:e.from,to:e.to,insert:r.Text.of(["",""])},range:r.EditorSelection.cursor(e.from)}));return t(e.update(n,{scrollIntoView:!0,userEvent:"input"})),!0},Yt=({state:e,dispatch:t})=>{if(e.readOnly)return!1;let n=e.changeByRange(t=>{if(!t.empty||0==t.from||t.from==e.doc.length)return{range:t};let n=t.from,i=e.doc.lineAt(n),o=n==i.from?n-1:(0,r.findClusterBreak)(i.text,n-i.from,!1)+i.from,a=n==i.to?n+1:(0,r.findClusterBreak)(i.text,n-i.from,!0)+i.from;return{changes:{from:o,to:a,insert:e.doc.slice(n,a).append(e.doc.slice(o,n))},range:r.EditorSelection.cursor(a)}});return!n.changes.empty&&(t(e.update(n,{scrollIntoView:!0,userEvent:"move.character"})),!0)};function Zt(e){let t=[],n=-1;for(let r of e.selection.ranges){let i=e.doc.lineAt(r.from),o=e.doc.lineAt(r.to);if(r.empty||r.to!=o.from||(o=e.doc.lineAt(r.to-1)),n>=i.number){let e=t[t.length-1];e.to=o.to,e.ranges.push(r)}else t.push({from:i.from,to:o.to,ranges:[r]});n=o.number+1}return t}function Jt(e,t,n){if(e.readOnly)return!1;let i=[],o=[];for(let a of Zt(e)){if(n?a.to==e.doc.length:0==a.from)continue;let t=e.doc.lineAt(n?a.to+1:a.from-1),s=t.length+1;if(n){i.push({from:a.to,to:t.to},{from:a.from,insert:t.text+e.lineBreak});for(let t of a.ranges)o.push(r.EditorSelection.range(Math.min(e.doc.length,t.anchor+s),Math.min(e.doc.length,t.head+s)))}else{i.push({from:t.from,to:a.from},{from:a.to,insert:e.lineBreak+t.text});for(let e of a.ranges)o.push(r.EditorSelection.range(e.anchor-s,e.head-s))}}return!!i.length&&(t(e.update({changes:i,scrollIntoView:!0,selection:r.EditorSelection.create(o,e.selection.mainIndex),userEvent:"move.line"})),!0)}const en=({state:e,dispatch:t})=>Jt(e,t,!1),tn=({state:e,dispatch:t})=>Jt(e,t,!0);function nn(e,t,n){if(e.readOnly)return!1;let r=[];for(let o of Zt(e))n?r.push({from:o.from,insert:e.doc.slice(o.from,o.to)+e.lineBreak}):r.push({from:o.to,insert:e.lineBreak+e.doc.slice(o.from,o.to)});let i=e.changes(r);return t(e.update({changes:i,selection:e.selection.map(i,n?1:-1),scrollIntoView:!0,userEvent:"input.copyline"})),!0}const rn=({state:e,dispatch:t})=>nn(e,t,!1),on=({state:e,dispatch:t})=>nn(e,t,!0),an=e=>{if(e.state.readOnly)return!1;let{state:t}=e,n=t.changes(Zt(t).map(({from:e,to:n})=>(e>0?e--:n<t.doc.length&&n++,{from:e,to:n}))),r=ee(t.selection,t=>{let n;if(e.lineWrapping){let r=e.lineBlockAt(t.head),i=e.coordsAtPos(t.head,t.assoc||1);i&&(n=r.bottom+e.documentTop-i.bottom+e.defaultLineHeight/2)}return e.moveVertically(t,!0,n)}).map(n);return e.dispatch({changes:n,selection:r,scrollIntoView:!0,userEvent:"delete.line"}),!0},sn=({state:e,dispatch:t})=>(t(e.update(e.replaceSelection(e.lineBreak),{scrollIntoView:!0,userEvent:"input"})),!0),ln=({state:e,dispatch:t})=>(t(e.update(e.changeByRange(t=>{let n=/^\s*/.exec(e.doc.lineAt(t.from).text)[0];return{changes:{from:t.from,to:t.to,insert:e.lineBreak+n},range:r.EditorSelection.cursor(t.from+n.length+1)}}),{scrollIntoView:!0,userEvent:"input"})),!0);function cn(e,t){if(/\(\)|\[\]|\{\}/.test(e.sliceDoc(t-1,t+1)))return{from:t,to:t};let n,r=(0,o.syntaxTree)(e).resolveInner(t),i=r.childBefore(t),s=r.childAfter(t);return i&&s&&i.to<=t&&s.from>=t&&(n=i.type.prop(a.NodeProp.closedBy))&&n.indexOf(s.name)>-1&&e.doc.lineAt(i.to).from==e.doc.lineAt(s.from).from&&!/\S/.test(e.sliceDoc(i.to,s.from))?{from:i.to,to:s.from}:null}const un=hn(!1),dn=hn(!0);function hn(e){return({state:t,dispatch:n})=>{if(t.readOnly)return!1;let i=t.changeByRange(n=>{let{from:i,to:a}=n,s=t.doc.lineAt(i),l=!e&&i==a&&cn(t,i);e&&(i=a=(a<=s.to?s:t.doc.lineAt(a)).to);let c=new o.IndentContext(t,{simulateBreak:i,simulateDoubleBreak:!!l}),u=(0,o.getIndentation)(c,i);null==u&&(u=(0,r.countColumn)(/^\s*/.exec(t.doc.lineAt(i).text)[0],t.tabSize));while(a<s.to&&/\s/.test(s.text[a-s.from]))a++;l?({from:i,to:a}=l):i>s.from&&i<s.from+100&&!/\S/.test(s.text.slice(0,i))&&(i=s.from);let d=["",(0,o.indentString)(t,u)];return l&&d.push((0,o.indentString)(t,c.lineIndent(s.from,-1))),{changes:{from:i,to:a,insert:r.Text.of(d)},range:r.EditorSelection.cursor(i+1+d[1].length)}});return n(t.update(i,{scrollIntoView:!0,userEvent:"input"})),!0}}function pn(e,t){let n=-1;return e.changeByRange(i=>{let o=[];for(let r=i.from;r<=i.to;){let a=e.doc.lineAt(r);a.number>n&&(i.empty||i.to>a.from)&&(t(a,o,i),n=a.number),r=a.to+1}let a=e.changes(o);return{changes:o,range:r.EditorSelection.range(a.mapPos(i.anchor,1),a.mapPos(i.head,1))}})}const fn=({state:e,dispatch:t})=>{if(e.readOnly)return!1;let n=Object.create(null),r=new o.IndentContext(e,{overrideIndentation:e=>{let t=n[e];return null==t?-1:t}}),i=pn(e,(t,i,a)=>{let s=(0,o.getIndentation)(r,t.from);if(null==s)return;/\S/.test(t.text)||(s=0);let l=/^\s*/.exec(t.text)[0],c=(0,o.indentString)(e,s);(l!=c||a.from<t.from+l.length)&&(n[t.from]=s,i.push({from:t.from,to:t.from+l.length,insert:c}))});return i.changes.empty||t(e.update(i,{userEvent:"indent"})),!0},mn=({state:e,dispatch:t})=>!e.readOnly&&(t(e.update(pn(e,(t,n)=>{n.push({from:t.from,insert:e.facet(o.indentUnit)})}),{userEvent:"input.indent"})),!0),gn=({state:e,dispatch:t})=>!e.readOnly&&(t(e.update(pn(e,(t,n)=>{let i=/^\s*/.exec(t.text)[0];if(!i)return;let a=(0,r.countColumn)(i,e.tabSize),s=0,l=(0,o.indentString)(e,Math.max(0,a-(0,o.getIndentUnit)(e)));while(s<i.length&&s<l.length&&i.charCodeAt(s)==l.charCodeAt(s))s++;n.push({from:t.from+s,to:t.from+i.length,insert:l.slice(s)})}),{userEvent:"delete.dedent"})),!0),vn=e=>(e.setTabFocusMode(),!0),bn=e=>(e.setTabFocusMode(2e3),!0),yn=({state:e,dispatch:t})=>e.selection.ranges.some(e=>!e.empty)?mn({state:e,dispatch:t}):(t(e.update(e.replaceSelection("\t"),{scrollIntoView:!0,userEvent:"input"})),!0),wn=[{key:"Ctrl-b",run:ae,shift:We,preventDefault:!0},{key:"Ctrl-f",run:se,shift:Xe},{key:"Ctrl-p",run:Ne,shift:pt},{key:"Ctrl-n",run:Pe,shift:ft},{key:"Ctrl-a",run:Ue,shift:St},{key:"Ctrl-e",run:Ge,shift:Et},{key:"Ctrl-d",run:Ft},{key:"Ctrl-h",run:$t},{key:"Ctrl-k",run:qt},{key:"Ctrl-Alt-h",run:Ut},{key:"Ctrl-o",run:Xt},{key:"Ctrl-t",run:Yt},{key:"Ctrl-v",run:Le}],On=[{key:"ArrowLeft",run:ae,shift:We,preventDefault:!0},{key:"Mod-ArrowLeft",mac:"Alt-ArrowLeft",run:me,shift:nt,preventDefault:!0},{mac:"Cmd-ArrowLeft",run:Fe,shift:wt,preventDefault:!0},{key:"ArrowRight",run:se,shift:Xe,preventDefault:!0},{key:"Mod-ArrowRight",mac:"Alt-ArrowRight",run:ge,shift:rt,preventDefault:!0},{mac:"Cmd-ArrowRight",run:je,shift:Ot,preventDefault:!0},{key:"ArrowUp",run:Ne,shift:pt,preventDefault:!0},{mac:"Cmd-ArrowUp",run:xt,shift:kt},{mac:"Ctrl-ArrowUp",run:De,shift:gt},{key:"ArrowDown",run:Pe,shift:ft,preventDefault:!0},{mac:"Cmd-ArrowDown",run:_t,shift:Ct},{mac:"Ctrl-ArrowDown",run:Le,shift:vt},{key:"PageUp",run:De,shift:gt},{key:"PageDown",run:Le,shift:vt},{key:"Home",run:Ve,shift:yt,preventDefault:!0},{key:"Mod-Home",run:xt,shift:kt},{key:"End",run:$e,shift:bt,preventDefault:!0},{key:"Mod-End",run:_t,shift:Ct},{key:"Enter",run:un,shift:un},{key:"Mod-a",run:At},{key:"Backspace",run:$t,shift:$t,preventDefault:!0},{key:"Delete",run:Ft,preventDefault:!0},{key:"Mod-Backspace",mac:"Alt-Backspace",run:Ut,preventDefault:!0},{key:"Mod-Delete",mac:"Alt-Delete",run:Gt,preventDefault:!0},{mac:"Mod-Backspace",run:zt,preventDefault:!0},{mac:"Mod-Delete",run:Kt,preventDefault:!0}].concat(wn.map(e=>({mac:e.key,run:e.run,shift:e.shift}))),Sn=[{key:"Alt-ArrowLeft",mac:"Ctrl-ArrowLeft",run:Ae,shift:ut},{key:"Alt-ArrowRight",mac:"Ctrl-ArrowRight",run:Te,shift:dt},{key:"Alt-ArrowUp",run:en},{key:"Shift-Alt-ArrowUp",run:rn},{key:"Alt-ArrowDown",run:tn},{key:"Shift-Alt-ArrowDown",run:on},{key:"Mod-Alt-ArrowUp",run:Pt},{key:"Mod-Alt-ArrowDown",run:It},{key:"Escape",run:Mt},{key:"Mod-Enter",run:dn},{key:"Alt-l",mac:"Ctrl-l",run:Tt},{key:"Mod-i",run:Rt,preventDefault:!0},{key:"Mod-[",run:gn},{key:"Mod-]",run:mn},{key:"Mod-Alt-\\",run:fn},{key:"Shift-Mod-k",run:an},{key:"Shift-Mod-\\",run:qe},{key:"Mod-/",run:s},{key:"Alt-A",mac:"Ctrl-A",run:h},{key:"Ctrl-m",mac:"Shift-Alt-m",run:vn}].concat(On),En={key:"Tab",run:mn,shift:gn}},42835:function(e,t,n){"use strict";n.r(t),n.d(t,{autoCloseTags:function(){return ye},completionPath:function(){return ie},esLint:function(){return we},javascript:function(){return me},javascriptLanguage:function(){return se},jsxLanguage:function(){return ue},localCompletionSource:function(){return ne},scopeCompletionSource:function(){return ae},snippets:function(){return Q},tsxLanguage:function(){return de},typescriptLanguage:function(){return ce},typescriptSnippets:function(){return z}});var r=n(73643),i=n(88727);const o=317,a=318,s=1,l=2,c=3,u=4,d=319,h=321,p=322,f=5,m=6,g=0,v=[9,10,11,12,13,32,133,160,5760,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8232,8233,8239,8287,12288],b=125,y=59,w=47,O=42,S=43,E=45,x=60,_=44,k=63,C=46,A=91,T=new r.Aj({start:!1,shift(e,t){return t==f||t==m||t==h?e:t==p},strict:!1}),R=new r.Lu((e,t)=>{let{next:n}=e;(n==b||-1==n||t.context)&&e.acceptToken(d)},{contextual:!0,fallback:!0}),N=new r.Lu((e,t)=>{let n,{next:r}=e;v.indexOf(r)>-1||(r!=w||(n=e.peek(1))!=w&&n!=O)&&(r==b||r==y||-1==r||t.context||e.acceptToken(o))},{contextual:!0}),P=new r.Lu((e,t)=>{e.next!=A||t.context||e.acceptToken(a)},{contextual:!0}),I=new r.Lu((e,t)=>{let{next:n}=e;if(n==S||n==E){if(e.advance(),n==e.next){e.advance();let n=!t.context&&t.canShift(s);e.acceptToken(n?s:l)}}else n==k&&e.peek(1)==C&&(e.advance(),e.advance(),(e.next<48||e.next>57)&&e.acceptToken(c))},{contextual:!0});function M(e,t){return e>=65&&e<=90||e>=97&&e<=122||95==e||e>=192||!t&&e>=48&&e<=57}const D=new r.Lu((e,t)=>{if(e.next!=x||!t.dialectEnabled(g))return;if(e.advance(),e.next==w)return;let n=0;while(v.indexOf(e.next)>-1)e.advance(),n++;if(M(e.next,!0)){e.advance(),n++;while(M(e.next,!1))e.advance(),n++;while(v.indexOf(e.next)>-1)e.advance(),n++;if(e.next==_)return;for(let t=0;;t++){if(7==t){if(!M(e.next,!0))return;break}if(e.next!="extends".charCodeAt(t))break;e.advance(),n++}}e.acceptToken(u,-n)}),L=(0,i.styleTags)({"get set async static":i.tags.modifier,"for while do if else switch try catch finally return throw break continue default case defer":i.tags.controlKeyword,"in of await yield void typeof delete instanceof as satisfies":i.tags.operatorKeyword,"let var const using function class extends":i.tags.definitionKeyword,"import export from":i.tags.moduleKeyword,"with debugger new":i.tags.keyword,TemplateString:i.tags.special(i.tags.string),super:i.tags.atom,BooleanLiteral:i.tags.bool,this:i.tags.self,null:i.tags.null,Star:i.tags.modifier,VariableName:i.tags.variableName,"CallExpression/VariableName TaggedTemplateExpression/VariableName":i.tags.function(i.tags.variableName),VariableDefinition:i.tags.definition(i.tags.variableName),Label:i.tags.labelName,PropertyName:i.tags.propertyName,PrivatePropertyName:i.tags.special(i.tags.propertyName),"CallExpression/MemberExpression/PropertyName":i.tags.function(i.tags.propertyName),"FunctionDeclaration/VariableDefinition":i.tags.function(i.tags.definition(i.tags.variableName)),"ClassDeclaration/VariableDefinition":i.tags.definition(i.tags.className),"NewExpression/VariableName":i.tags.className,PropertyDefinition:i.tags.definition(i.tags.propertyName),PrivatePropertyDefinition:i.tags.definition(i.tags.special(i.tags.propertyName)),UpdateOp:i.tags.updateOperator,"LineComment Hashbang":i.tags.lineComment,BlockComment:i.tags.blockComment,Number:i.tags.number,String:i.tags.string,Escape:i.tags.escape,ArithOp:i.tags.arithmeticOperator,LogicOp:i.tags.logicOperator,BitOp:i.tags.bitwiseOperator,CompareOp:i.tags.compareOperator,RegExp:i.tags.regexp,Equals:i.tags.definitionOperator,Arrow:i.tags.function(i.tags.punctuation),": Spread":i.tags.punctuation,"( )":i.tags.paren,"[ ]":i.tags.squareBracket,"{ }":i.tags.brace,"InterpolationStart InterpolationEnd":i.tags.special(i.tags.brace),".":i.tags.derefOperator,", ;":i.tags.separator,"@":i.tags.meta,TypeName:i.tags.typeName,TypeDefinition:i.tags.definition(i.tags.typeName),"type enum interface implements namespace module declare":i.tags.definitionKeyword,"abstract global Privacy readonly override":i.tags.modifier,"is keyof unique infer asserts":i.tags.operatorKeyword,JSXAttributeValue:i.tags.attributeValue,JSXText:i.tags.content,"JSXStartTag JSXStartCloseTag JSXSelfCloseEndTag JSXEndTag":i.tags.angleBracket,"JSXIdentifier JSXNameSpacedName":i.tags.tagName,"JSXAttribute/JSXIdentifier JSXAttribute/JSXNameSpacedName":i.tags.attributeName,"JSXBuiltin/JSXIdentifier":i.tags.standard(i.tags.tagName)}),B={__proto__:null,export:20,as:25,from:33,default:36,async:41,function:42,in:52,out:55,const:56,extends:60,this:64,true:72,false:72,null:84,void:88,typeof:92,super:108,new:142,delete:154,yield:163,await:167,class:172,public:237,private:237,protected:237,readonly:239,instanceof:258,satisfies:261,import:294,keyof:351,unique:355,infer:361,asserts:397,is:399,abstract:419,implements:421,type:423,let:426,var:428,using:431,interface:437,enum:441,namespace:447,module:449,declare:453,global:457,defer:473,for:478,of:487,while:490,with:494,do:498,if:502,else:504,switch:508,case:514,try:520,catch:524,finally:528,return:532,throw:536,break:540,continue:544,debugger:548},$={__proto__:null,async:129,get:131,set:133,declare:195,public:197,private:197,protected:197,static:199,abstract:201,override:203,readonly:209,accessor:211,new:403},V={__proto__:null,"<":193},F=r.U1.deserialize({version:14,states:"$GSQ%TQlOOO%[QlOOO'_QpOOP(lO`OOO*zQ!0MxO'#CiO+RO#tO'#CjO+aO&jO'#CjO+oO#@ItO'#DaO.QQlO'#DgO.bQlO'#DrO%[QlO'#DzO0fQlO'#ESOOQ!0Lf'#E['#E[O1PQ`O'#EXOOQO'#Ep'#EpOOQO'#Im'#ImO1XQ`O'#GtO1dQ`O'#EoO1iQ`O'#EoO3hQ!0MxO'#JsO6[Q!0MxO'#JtO6uQ`O'#F^O6zQ,UO'#FuOOQ!0Lf'#Fg'#FgO7VO7dO'#FgO9XQMhO'#F}O9`Q`O'#F|OOQ!0Lf'#Jt'#JtOOQ!0Lb'#Js'#JsO9eQ`O'#GxOOQ['#K`'#K`O9pQ`O'#IZO9uQ!0LrO'#I[OOQ['#Ja'#JaOOQ['#I`'#I`Q`QlOOQ`QlOOO9}Q!L^O'#DvO:UQlO'#EOO:]QlO'#EQO9kQ`O'#GtO:dQMhO'#CoO:rQ`O'#EnO:}Q`O'#EzO;hQMhO'#FfO;xQ`O'#GtOOQO'#Ka'#KaO;}Q`O'#KaO<]Q`O'#G|O<]Q`O'#G}O<]Q`O'#HPO9kQ`O'#HSO=SQ`O'#HVO>kQ`O'#CeO>{Q`O'#HdO?TQ`O'#HjO?TQ`O'#HlO`QlO'#HnO?TQ`O'#HpO?TQ`O'#HsO?YQ`O'#HyO?_Q!0LsO'#IPO%[QlO'#IRO?jQ!0LsO'#ITO?uQ!0LsO'#IVO9uQ!0LrO'#IXO@QQ!0MxO'#CiOASQpO'#DlQOQ`OOO%[QlO'#EQOAjQ`O'#ETO:dQMhO'#EnOAuQ`O'#EnOBQQ!bO'#FfOOQ['#Cg'#CgOOQ!0Lb'#Dq'#DqOOQ!0Lb'#Jw'#JwO%[QlO'#JwOOQO'#Jz'#JzOOQO'#Ii'#IiOCQQpO'#EgOOQ!0Lb'#Ef'#EfOOQ!0Lb'#KO'#KOOC|Q!0MSO'#EgODWQpO'#EWOOQO'#Jy'#JyODlQpO'#JzOEyQpO'#EWODWQpO'#EgPFWO&2DjO'#CbPOOO)CEO)CEOOOOO'#Ia'#IaOFcO#tO,59UOOQ!0Lh,59U,59UOOOO'#Ib'#IbOFqO&jO,59UOGPQ!L^O'#DcOOOO'#Id'#IdOGWO#@ItO,59{OOQ!0Lf,59{,59{OGfQlO'#IeOGyQ`O'#JuOIxQ!fO'#JuO+}QlO'#JuOJPQ`O,5:ROJgQ`O'#EpOJtQ`O'#KUOKPQ`O'#KTOKPQ`O'#KTOKXQ`O,5;^OK^Q`O'#KSOOQ!0Ln,5:^,5:^OKeQlO,5:^OMcQ!0MxO,5:fONSQ`O,5:nONmQ!0LrO'#KRONtQ`O'#KQO9eQ`O'#KQO! YQ`O'#KQO! bQ`O,5;]O! gQ`O'#KQO!#lQ!fO'#JtOOQ!0Lh'#Ci'#CiO%[QlO'#ESO!$[Q!fO,5:sOOQS'#J{'#J{OOQO-E<k-E<kO9kQ`O,5=`O!$rQ`O,5=`O!$wQlO,5;ZO!&zQMhO'#EkO!(eQ`O,5;ZO!(jQlO'#DyO!(tQpO,5;eO!(|QpO,5;eO%[QlO,5;eOOQ['#FU'#FUOOQ['#FW'#FWO%[QlO,5;fO%[QlO,5;fO%[QlO,5;fO%[QlO,5;fO%[QlO,5;fO%[QlO,5;fO%[QlO,5;fO%[QlO,5;fO%[QlO,5;fO%[QlO,5;fOOQ['#F['#F[O!)[QlO,5;uOOQ!0Lf,5;z,5;zOOQ!0Lf,5;{,5;{OOQ!0Lf,5;},5;}O%[QlO'#IqO!+_Q!0LrO,5<jO%[QlO,5;fO!&zQMhO,5;fO!+|QMhO,5;fO!-nQMhO'#E^O%[QlO,5;xOOQ!0Lf,5;|,5;|O!-uQ,UO'#FkO!.rQ,UO'#KYO!.^Q,UO'#KYO!.yQ,UO'#KYOOQO'#KY'#KYO!/_Q,UO,5<TOOOW,5<a,5<aO!/pQlO'#FwOOOW'#Ip'#IpO7VO7dO,5<RO!/wQ,UO'#FyOOQ!0Lf,5<R,5<RO!0hQ$IUO'#CyOOQ!0Lh'#C}'#C}O!0{O#@ItO'#DRO!1iQMjO,5<fO!1pQ`O,5<iO!3YQ(CWO'#GYO!3jQ`O'#GZO!3oQ`O'#GZO!5_Q(CWO'#G_O!6dQpO'#GcOOQO'#Go'#GoO!,TQMhO'#GnOOQO'#Gq'#GqO!,TQMhO'#GpO!7VQ$IUO'#JmOOQ!0Lh'#Jm'#JmO!7aQ`O'#JlO!7oQ`O'#JkO!7wQ`O'#CuOOQ!0Lh'#C{'#C{O!8YQ`O'#C}OOQ!0Lh'#DV'#DVOOQ!0Lh'#DX'#DXO!8_Q`O,5<fO1SQ`O'#DZO!,TQMhO'#GQO!,TQMhO'#GSO!8gQ`O'#GUO!8lQ`O'#GVO!3oQ`O'#G]O!,TQMhO'#GbO<]Q`O'#JlO!8qQ`O'#EqO!9`Q`O,5<hOOQ!0Lb'#Cr'#CrO!9hQ`O'#ErO!:bQpO'#EsOOQ!0Lb'#KS'#KSO!:iQ!0LrO'#KbO9uQ!0LrO,5=dO`QlO,5>uOOQ['#Ji'#JiOOQ[,5>v,5>vOOQ[-E<^-E<^O!<hQ!0MxO,5:bO!=[QpO,5:`O!?WQ!0MxO,5:jO%[QlO,5:jO!AnQ!0MxO,5:lOOQO,5@{,5@{O!B_QMhO,5=`O!BmQ!0LrO'#JjO9`Q`O'#JjO!COQ!0LrO,59ZO!CZQpO,59ZO!CcQMhO,59ZO:dQMhO,59ZO!CnQ`O,5;ZO!CvQ`O'#HcO!D[Q`O'#KeO%[QlO,5<OO!=[QpO,5<QO!DdQ`O,5={O!DiQ`O,5={O!DnQ`O,5={O!D|Q`O,5={O9uQ!0LrO,5={O<]Q`O,5=kOOQO'#Cy'#CyO!ETQpO,5=hO!E]QMhO,5=iO!EhQ`O,5=kO!EmQ!bO,5=nO!EuQ`O'#KaO?YQ`O'#HXO9kQ`O'#HZO!EzQ`O'#HZO:dQMhO'#H]O!FPQ`O'#H]OOQ[,5=q,5=qO!FUQ`O'#H^O!FgQ`O'#CoO!FlQ`O,59PO!FvQ`O,59PO!H{QlO,59POOQ[,59P,59PO!I]Q!0LrO,59PO%[QlO,59PO!KhQlO'#HfOOQ['#Hg'#HgOOQ['#Hh'#HhO`QlO,5>OO!LOQ`O,5>OO`QlO,5>UO`QlO,5>WO!LTQ`O,5>YO`QlO,5>[O!LYQ`O,5>_O!L_QlO,5>eOOQ[,5>k,5>kO%[QlO,5>kO9uQ!0LrO,5>mOOQ[,5>o,5>oO#!iQ`O,5>oOOQ[,5>q,5>qO#!iQ`O,5>qOOQ[,5>s,5>sO##VQpO'#D_O%[QlO'#JwO##aQpO'#JwO##{QpO'#DmO#$^QpO'#DmO#&oQlO'#DmO#&vQ`O'#JvO#'OQ`O,5:WO#'TQ`O'#EtO#'`Q`O'#EtO#'eQ`O'#KVO#'mQ`O,5;_O#'rQpO'#DmO#(PQpO'#EVOOQ!0Lf,5:o,5:oO%[QlO,5:oO#(WQ`O,5:oO?YQ`O,5;YO!CZQpO,5;YO!CcQMhO,5;YO:dQMhO,5;YO#(`Q`O,5@cO#(eQ07dO,5:sOOQO-E<g-E<gO#)kQ!0MSO,5;RODWQpO,5:rO#)uQpO,5:rODWQpO,5;RO!COQ!0LrO,5:rOOQ!0Lb'#Ej'#EjOOQO,5;R,5;RO%[QlO,5;RO#*SQ!0LrO,5;RO#*_Q!0LrO,5;RO!CZQpO,5:rOOQO,5;X,5;XO#*mQ!0LrO,5;RPOOO'#I_'#I_P#+RO&2DjO,58|POOO,58|,58|OOOO-E<_-E<_OOQ!0Lh1G.p1G.pOOOO-E<`-E<`OOOO,59},59}O#+^Q!bO,59}OOOO-E<b-E<bOOQ!0Lf1G/g1G/gO#+cQ!fO,5?PO+}QlO,5?POOQO,5?V,5?VO#+mQlO'#IeOOQO-E<c-E<cO#+zQ`O,5@aO#,SQ!fO,5@aO#,ZQ`O,5@oOOQ!0Lf1G/m1G/mO%[QlO,5@pO#,cQ`O'#IkOOQO-E<i-E<iO#,ZQ`O,5@oOOQ!0Lb1G0x1G0xOOQ!0Ln1G/x1G/xOOQ!0Ln1G0Y1G0YO%[QlO,5@mO#,wQ!0LrO,5@mO#-YQ!0LrO,5@mO#-aQ`O,5@lO9eQ`O,5@lO#-iQ`O,5@lO#-wQ`O'#InO#-aQ`O,5@lOOQ!0Lb1G0w1G0wO!(tQpO,5:uO!)PQpO,5:uOOQS,5:w,5:wO#.iQdO,5:wO#.qQMhO1G2zO9kQ`O1G2zOOQ!0Lf1G0u1G0uO#/PQ!0MxO1G0uO#0UQ!0MvO,5;VOOQ!0Lh'#GX'#GXO#0rQ!0MzO'#JmO!$wQlO1G0uO#2}Q!fO'#JxO%[QlO'#JxO#3XQ`O,5:eOOQ!0Lh'#D_'#D_OOQ!0Lf1G1P1G1PO%[QlO1G1POOQ!0Lf1G1g1G1gO#3^Q`O1G1PO#5rQ!0MxO1G1QO#5yQ!0MxO1G1QO#8aQ!0MxO1G1QO#8hQ!0MxO1G1QO#;OQ!0MxO1G1QO#=fQ!0MxO1G1QO#=mQ!0MxO1G1QO#=tQ!0MxO1G1QO#@[Q!0MxO1G1QO#@cQ!0MxO1G1QO#BpQ?MtO'#CiO#DkQ?MtO1G1aO#DrQ?MtO'#JtO#EVQ!0MxO,5?]OOQ!0Lb-E<o-E<oO#GdQ!0MxO1G1QO#HaQ!0MzO1G1QOOQ!0Lf1G1Q1G1QO#IdQMjO'#J}O#InQ`O,5:xO#IsQ!0MxO1G1dO#JgQ,UO,5<XO#JoQ,UO,5<YO#JwQ,UO'#FpO#K`Q`O'#FoOOQO'#KZ'#KZOOQO'#Io'#IoO#KeQ,UO1G1oOOQ!0Lf1G1o1G1oOOOW1G1z1G1zO#KvQ?MtO'#JsO#LQQ`O,5<cO!)[QlO,5<cOOOW-E<n-E<nOOQ!0Lf1G1m1G1mO#LVQpO'#KYOOQ!0Lf,5<e,5<eO#L_QpO,5<eO#LdQMhO'#DTOOOO'#Ic'#IcO#LkO#@ItO,59mOOQ!0Lh,59m,59mO%[QlO1G2QO!8lQ`O'#IsO#LvQ`O,5<{OOQ!0Lh,5<x,5<xO!,TQMhO'#IvO#MdQMjO,5=YO!,TQMhO'#IxO#NVQMjO,5=[O!&zQMhO,5=^OOQO1G2T1G2TO#NaQ!dO'#CrO#NtQ(CWO'#ErO$ |QpO'#GcO$!dQ!dO,5<tO$!kQ`O'#K]O9eQ`O'#K]O$!yQ`O,5<vO$#aQ!dO'#C{O!,TQMhO,5<uO$#kQ`O'#G[O$$PQ`O,5<uO$$UQ!dO'#GXO$$cQ!dO'#K^O$$mQ`O'#K^O!&zQMhO'#K^O$$rQ`O,5<yO$$wQlO'#JwO$%RQpO'#GdO#$^QpO'#GdO$%dQ`O'#GhO!3oQ`O'#GlO$%iQ!0LrO'#IuO$%tQpO,5<}OOQ!0Lp,5<},5<}O$%{QpO'#GdO$&YQpO'#GeO$&kQpO'#GeO$&pQMjO,5=YO$'QQMjO,5=[OOQ!0Lh,5=_,5=_O!,TQMhO,5@WO!,TQMhO,5@WO$'bQ`O'#IzO$'vQ`O,5@VO$(OQ`O,59aOOQ!0Lh,59i,59iO$(TQ`O,5@WO$)TQ$IYO,59uOOQ!0Lh'#Jq'#JqO$)vQMjO,5<lO$*iQMjO,5<nO@zQ`O,5<pOOQ!0Lh,5<q,5<qO$*sQ`O,5<wO$*xQMjO,5<|O$+YQ`O'#KQO!$wQlO1G2SO$+_Q`O1G2SO9eQ`O'#KTO$+dQ`O'#D_O9eQ`O'#EtO%[QlO'#EtO9eQ`O'#I|O$+rQ!0LrO,5@|OOQ[1G3O1G3OOOQ[1G4a1G4aOOQ!0Lf1G/|1G/|OOQ!0Lf1G/z1G/zO$-tQ!0MxO1G0UOOQ[1G2z1G2zO!&zQMhO1G2zO%[QlO1G2zO#.tQ`O1G2zO$/xQMhO'#EkOOQ!0Lb,5@U,5@UO$0VQ!0LrO,5@UOOQ[1G.u1G.uO!COQ!0LrO1G.uO!CZQpO1G.uO!CcQMhO1G.uO$0hQ`O1G0uO$0mQ`O'#CiO$0xQ`O'#KfO$1QQ`O,5=}O$1VQ`O'#KfO$1[Q`O'#KfO$1jQ`O'#JSO$1xQ`O,5APO$2QQ!fO1G1jOOQ!0Lf1G1l1G1lO9kQ`O1G3gO@zQ`O1G3gO$2XQ`O1G3gO$2^Q`O1G3gO!DnQ`O1G3gO9uQ!0LrO1G3gOOQ[1G3g1G3gO!EhQ`O1G3VO!&zQMhO1G3SO$2cQ`O1G3SOOQ[1G3T1G3TO!&zQMhO1G3TO$2hQ`O1G3TO$2pQpO'#HROOQ[1G3V1G3VO!6_QpO'#JOO!EmQ!bO1G3YOOQ[1G3Y1G3YOOQ[,5=s,5=sO$2xQMhO,5=uO9kQ`O,5=uO$%dQ`O,5=wO9`Q`O,5=wO!CZQpO,5=wO!CcQMhO,5=wO:dQMhO,5=wO$3WQ`O'#KdO$3cQ`O,5=xOOQ[1G.k1G.kO$3hQ!0LrO1G.kO@zQ`O1G.kO$3sQ`O1G.kO9uQ!0LrO1G.kO$5{Q!fO,5ARO$6YQ`O,5ARO9eQ`O,5ARO$6eQlO,5>QO$6lQ`O,5>QOOQ[1G3j1G3jO`QlO1G3jOOQ[1G3p1G3pOOQ[1G3r1G3rO?TQ`O1G3tO$6qQlO1G3vO$:uQlO'#HuOOQ[1G3y1G3yO$;SQ`O'#H{O?YQ`O'#H}OOQ[1G4P1G4PO$;[QlO1G4PO9uQ!0LrO1G4VOOQ[1G4X1G4XOOQ!0Lb'#G`'#G`O9uQ!0LrO1G4ZO9uQ!0LrO1G4]O$?cQ`O,5@cO9eQ`O,5;`O?YQ`O,5:XO!)[QlO,5:XO!CZQpO,5:XO$?hQ?MtO,5:XOOQO,5;`,5;`O$?rQpO'#IfO$@YQ`O,5@bOOQ!0Lf1G/r1G/rO!)[QlO,5;`O$@bQpO'#IlO$@lQ`O,5@qOOQ!0Lb1G0y1G0yO#$^QpO,5:XOOQO'#Ih'#IhO$@tQpO,5:qOOQ!0Ln,5:q,5:qO#(ZQ`O1G0ZOOQ!0Lf1G0Z1G0ZO%[QlO1G0ZOOQ!0Lf1G0t1G0tO?YQ`O1G0tO!CZQpO1G0tO!CcQMhO1G0tOOQ!0Lb1G5}1G5}O!COQ!0LrO1G0^OOQO1G0m1G0mO%[QlO1G0mO$@{Q!0LrO1G0mO$AWQ!0LrO1G0mO!CZQpO1G0^ODWQpO1G0^O$AfQ!0LrO1G0mOOQO1G0^1G0^O$AzQ!0MxO1G0mPOOO-E<]-E<]POOO1G.h1G.hOOOO1G/i1G/iO$BUQ!bO,5<jO$B^Q!fO1G4kOOQO1G4q1G4qO%[QlO,5?PO$BhQ`O1G5{O$BpQ`O1G6ZO$BxQ!fO1G6[O9eQ`O,5?VO$CSQ!0MxO1G6XO%[QlO1G6XO$CdQ!0LrO1G6XO$CuQ`O1G6WO$CuQ`O1G6WO9eQ`O1G6WO$C}Q`O,5?YO9eQ`O,5?YOOQO,5?Y,5?YO$DcQ`O,5?YO$+YQ`O,5?YOOQO-E<l-E<lOOQS1G0a1G0aOOQS1G0c1G0cO#.lQ`O1G0cOOQ[7+(f7+(fO!&zQMhO7+(fO%[QlO7+(fO$DqQ`O7+(fO$D|QMhO7+(fO$E[Q!0MzO,5=YO$GgQ!0MzO,5=[O$IrQ!0MzO,5=YO$LTQ!0MzO,5=[O$NfQ!0MzO,59uO%!kQ!0MzO,5<lO%$vQ!0MzO,5<nO%'RQ!0MzO,5<|OOQ!0Lf7+&a7+&aO%)dQ!0MxO7+&aO%*WQlO'#IgO%*eQ`O,5@dO%*mQ!fO,5@dOOQ!0Lf1G0P1G0PO%*wQ`O7+&kOOQ!0Lf7+&k7+&kO%*|Q?MtO,5:fO%[QlO7+&{O%+WQ?MtO,5:bO%+eQ?MtO,5:jO%+oQ?MtO,5:lO%+yQMhO'#IjO%,TQ`O,5@iOOQ!0Lh1G0d1G0dOOQO1G1s1G1sOOQO1G1t1G1tO%,]Q!jO,5<[O!)[QlO,5<ZOOQO-E<m-E<mOOQ!0Lf7+'Z7+'ZOOOW7+'f7+'fOOOW1G1}1G1}O%,hQ`O1G1}OOQ!0Lf1G2P1G2POOOO,59o,59oO%,mQ!dO,59oOOOO-E<a-E<aOOQ!0Lh1G/X1G/XO%,tQ!0MxO7+'lOOQ!0Lh,5?_,5?_O%-hQMhO1G2gP%-oQ`O'#IsPOQ!0Lh-E<q-E<qO%.]QMjO,5?bOOQ!0Lh-E<t-E<tO%/OQMjO,5?dOOQ!0Lh-E<v-E<vO%/YQ!dO1G2xO%/aQ!dO'#CrO%/wQMhO'#KTO$$wQlO'#JwOOQ!0Lh1G2`1G2`O%0RQ`O'#IrO%0jQ`O,5@wO%0jQ`O,5@wO%0rQ`O,5@wO%0}Q`O,5@wOOQO1G2b1G2bO%1]QMjO1G2aO$+YQ`O'#K]O!,TQMhO1G2aO%1mQ(CWO'#ItO%1zQ`O,5@xO!&zQMhO,5@xO%2SQ!dO,5@xOOQ!0Lh1G2e1G2eO%4dQ!fO'#CiO%4nQ`O,5=QOOQ!0Lb,5=O,5=OO%4vQpO,5=OOOQ!0Lb,5=P,5=POCwQ`O,5=OO%5RQpO,5=OOOQ!0Lb,5=S,5=SO$+YQ`O,5=WOOQO,5?a,5?aOOQO-E<s-E<sOOQ!0Lp1G2i1G2iO#$^QpO,5=OO$$wQlO,5=QO%5aQ`O,5=PO%5lQpO,5=PO!,TQMhO'#IvO%6fQMjO1G2tO!,TQMhO'#IxO%7XQMjO1G2vO%7cQMjO1G5rO%7mQMjO1G5rOOQO,5?f,5?fOOQO-E<x-E<xOOQO1G.{1G.{O!,TQMhO1G5rO!,TQMhO1G5rO!=[QpO,59wO%[QlO,59wOOQ!0Lh,5<k,5<kO%7zQ`O1G2[O!,TQMhO1G2cO%8PQ!0MxO7+'nOOQ!0Lf7+'n7+'nO!$wQlO7+'nO%8sQ`O,5;`OOQ!0Lb,5?h,5?hOOQ!0Lb-E<z-E<zO%8xQ!dO'#K_O#(ZQ`O7+(fO4UQ!fO7+(fO$DtQ`O7+(fO%9SQ!0MvO'#CiO%9gQ!0MvO,5=TO%9zQ`O,5=TO%:SQ`O,5=TOOQ!0Lb1G5p1G5pOOQ[7+$a7+$aO!COQ!0LrO7+$aO!CZQpO7+$aO!$wQlO7+&aO%:XQ`O'#JRO%:pQ`O,5AQOOQO1G3i1G3iO9kQ`O,5AQO%:pQ`O,5AQO%:xQ`O,5AQOOQO,5?n,5?nOOQO-E=Q-E=QOOQ!0Lf7+'U7+'UO%:}Q`O7+)RO9uQ!0LrO7+)RO9kQ`O7+)RO@zQ`O7+)RO%;SQ`O7+)ROOQ[7+)R7+)ROOQ[7+(q7+(qO%;XQ!0MvO7+(nO!&zQMhO7+(nO!EcQ`O7+(oOOQ[7+(o7+(oO!&zQMhO7+(oO%;cQ`O'#KcO%;nQ`O,5=mOOQO,5?j,5?jOOQO-E<|-E<|OOQ[7+(t7+(tO%=QQpO'#H[OOQ[1G3a1G3aO!&zQMhO1G3aO%[QlO1G3aO%=XQ`O1G3aO%=dQMhO1G3aO9uQ!0LrO1G3cO$%dQ`O1G3cO9`Q`O1G3cO!CZQpO1G3cO!CcQMhO1G3cO%=rQ`O'#JQO%>WQ`O,5AOO%>`QpO,5AOOOQ!0Lb1G3d1G3dOOQ[7+$V7+$VO@zQ`O7+$VO9uQ!0LrO7+$VO%>kQ`O7+$VO%[QlO1G6mO%[QlO1G6nO%>pQ!0LrO1G6mO%>zQlO1G3lO%?RQ`O1G3lO%?WQlO1G3lOOQ[7+)U7+)UO9uQ!0LrO7+)`O`QlO7+)bOOQ['#Ki'#KiOOQ['#JT'#JTO%?_QlO,5>aOOQ[,5>a,5>aO%[QlO'#HvO%?lQ`O'#HxOOQ[,5>g,5>gO9eQ`O,5>gOOQ[,5>i,5>iOOQ[7+)k7+)kOOQ[7+)q7+)qOOQ[7+)u7+)uOOQ[7+)w7+)wO%?qQpO1G5}O%@]Q`O1G0zOOQO1G/s1G/sO%@hQ?MtO1G/sO?YQ`O1G/sO!)[QlO'#DmOOQO,5?Q,5?QOOQO-E<d-E<dO%@rQ?MtO1G0zOOQO,5?W,5?WOOQO-E<j-E<jO!CZQpO1G/sOOQO-E<f-E<fOOQ!0Ln1G0]1G0]OOQ!0Lf7+%u7+%uO#(ZQ`O7+%uOOQ!0Lf7+&`7+&`O?YQ`O7+&`O!CZQpO7+&`OOQO7+%x7+%xO$AzQ!0MxO7+&XOOQO7+&X7+&XO%[QlO7+&XO%@|Q!0LrO7+&XO!COQ!0LrO7+%xO!CZQpO7+%xO%AXQ!0LrO7+&XO%AgQ!0MxO7++sO%[QlO7++sO%AwQ`O7++rO%AwQ`O7++rOOQO1G4t1G4tO9eQ`O1G4tO%BPQ`O1G4tOOQS7+%}7+%}O#(ZQ`O<<LQO4UQ!fO<<LQO%B_Q`O<<LQOOQ[<<LQ<<LQO!&zQMhO<<LQO%[QlO<<LQO%BgQ`O<<LQO%BrQ!0MzO,5?bO%D}Q!0MzO,5?dO%GYQ!0MzO1G2aO%IkQ!0MzO1G2tO%KvQ!0MzO1G2vO%NRQ!fO,5?RO%[QlO,5?ROOQO-E<e-E<eO%N]Q`O1G6OOOQ!0Lf<<JV<<JVO%NeQ?MtO1G0uO&!lQ?MtO1G1QO&!sQ?MtO1G1QO&$tQ?MtO1G1QO&${Q?MtO1G1QO&&|Q?MtO1G1QO&(}Q?MtO1G1QO&)UQ?MtO1G1QO&)]Q?MtO1G1QO&+^Q?MtO1G1QO&+eQ?MtO1G1QO&+lQ!0MxO<<JgO&-dQ?MtO1G1QO&.aQ?MvO1G1QO&/dQ?MvO'#JmO&1jQ?MtO1G1dO&1wQ?MtO1G0UO&2RQMjO,5?UOOQO-E<h-E<hO!)[QlO'#FrOOQO'#K['#K[OOQO1G1v1G1vO&2]Q`O1G1uO&2bQ?MtO,5?]OOOW7+'i7+'iOOOO1G/Z1G/ZO&2lQ!dO1G4yOOQ!0Lh7+(R7+(RP!&zQMhO,5?_O!,TQMhO7+(dO&2sQ`O,5?^O9eQ`O,5?^O$+YQ`O,5?^OOQO-E<p-E<pO&3RQ`O1G6cO&3RQ`O1G6cO&3ZQ`O1G6cO&3fQMjO7+'{O&3vQ!dO,5?`O&4QQ`O,5?`O!&zQMhO,5?`OOQO-E<r-E<rO&4VQ!dO1G6dO&4aQ`O1G6dO&4iQ`O1G2lO!&zQMhO1G2lOOQ!0Lb1G2j1G2jOOQ!0Lb1G2k1G2kO%4vQpO1G2jO!CZQpO1G2jOCwQ`O1G2jOOQ!0Lb1G2r1G2rO&4nQpO1G2jO&4|Q`O1G2lO$+YQ`O1G2kOCwQ`O1G2kO$$wQlO1G2lO&5UQ`O1G2kO&5xQMjO,5?bOOQ!0Lh-E<u-E<uO&6kQMjO,5?dOOQ!0Lh-E<w-E<wO!,TQMhO7++^O&6uQMjO7++^O&7PQMjO7++^OOQ!0Lh1G/c1G/cO&7^Q`O1G/cOOQ!0Lh7+'v7+'vO&7cQMjO7+'}O&7sQ!0MxO<<KYOOQ!0Lf<<KY<<KYO&8gQ`O1G0zO!&zQMhO'#I{O&8lQ`O,5@yO&:nQ!fO<<LQO!&zQMhO1G2oO&:uQ!0LrO1G2oOOQ[<<G{<<G{O!COQ!0LrO<<G{O&;WQ!0MxO<<I{OOQ!0Lf<<I{<<I{OOQO,5?m,5?mO&;zQ`O,5?mO&<PQ`O,5?mOOQO-E=P-E=PO&<_Q`O1G6lO&<_Q`O1G6lO9kQ`O1G6lO@zQ`O<<LmOOQ[<<Lm<<LmO&<gQ`O<<LmO9uQ!0LrO<<LmO9kQ`O<<LmOOQ[<<LY<<LYO%;XQ!0MvO<<LYOOQ[<<LZ<<LZO!EcQ`O<<LZO&<lQpO'#I}O&<wQ`O,5@}O!)[QlO,5@}OOQ[1G3X1G3XOOQO'#JP'#JPO9uQ!0LrO'#JPO&=PQpO,5=vOOQ[,5=v,5=vO&=WQpO'#EgO&=_QpO'#GfO&=dQ`O7+({O&=iQ`O7+({OOQ[7+({7+({O!&zQMhO7+({O%[QlO7+({O&=qQ`O7+({OOQ[7+(}7+(}O9uQ!0LrO7+(}O$%dQ`O7+(}O9`Q`O7+(}O!CZQpO7+(}O&=|Q`O,5?lOOQO-E=O-E=OOOQO'#H_'#H_O&>XQ`O1G6jO9uQ!0LrO<<GqOOQ[<<Gq<<GqO@zQ`O<<GqO&>aQ`O7+,XO&>fQ`O7+,YO%[QlO7+,XO%[QlO7+,YOOQ[7+)W7+)WO&>kQ`O7+)WO&>pQlO7+)WO&>wQ`O7+)WOOQ[<<Lz<<LzOOQ[<<L|<<L|OOQ[-E=R-E=ROOQ[1G3{1G3{O&>|Q`O,5>bOOQ[,5>d,5>dO&?RQ`O1G4RO9eQ`O7+&fO!)[QlO7+&fOOQO7+%_7+%_O&?WQ?MtO1G6[O?YQ`O7+%_OOQ!0Lf<<Ia<<IaOOQ!0Lf<<Iz<<IzO?YQ`O<<IzOOQO<<Is<<IsO$AzQ!0MxO<<IsO%[QlO<<IsOOQO<<Id<<IdO!COQ!0LrO<<IdO&?bQ!0LrO<<IsO&?mQ!0MxO<= _O&?}Q`O<= ^OOQO7+*`7+*`O9eQ`O7+*`OOQ[ANAlANAlO&@VQ!fOANAlO!&zQMhOANAlO#(ZQ`OANAlO4UQ!fOANAlO&@^Q`OANAlO%[QlOANAlO&@fQ!0MzO7+'{O&BwQ!0MzO,5?bO&ESQ!0MzO,5?dO&G_Q!0MzO7+'}O&IpQ!fO1G4mO&IzQ?MtO7+&aO&LOQ?MvO,5=YO&NVQ?MvO,5=[O&NgQ?MvO,5=YO&NwQ?MvO,5=[O' XQ?MvO,59uO'#_Q?MvO,5<lO'%bQ?MvO,5<nO''vQ?MvO,5<|O')lQ?MtO7+'lO')yQ?MtO7+'nO'*WQ`O,5<^OOQO7+'a7+'aOOQ!0Lh7+*e7+*eO'*]QMjO<<LOOOQO1G4x1G4xO'*dQ`O1G4xO'*oQ`O1G4xO'*}Q`O7++}O'*}Q`O7++}O!&zQMhO1G4zO'+VQ!dO1G4zO'+aQ`O7+,OO'+iQ`O7+(WO'+tQ!dO7+(WOOQ!0Lb7+(U7+(UOOQ!0Lb7+(V7+(VO!CZQpO7+(UOCwQ`O7+(UO',OQ`O7+(WO!&zQMhO7+(WO$+YQ`O7+(VO',TQ`O7+(WOCwQ`O7+(VO',]QMjO<<NxO!,TQMhO<<NxOOQ!0Lh7+$}7+$}O',gQ!dO,5?gOOQO-E<y-E<yO',qQ!0MvO7+(ZO!&zQMhO7+(ZOOQ[AN=gAN=gO9kQ`O1G5XOOQO1G5X1G5XO'-RQ`O1G5XO'-WQ`O7+,WO'-WQ`O7+,WO9uQ!0LrOANBXO@zQ`OANBXOOQ[ANBXANBXO'-`Q`OANBXOOQ[ANAtANAtOOQ[ANAuANAuO'-eQ`O,5?iOOQO-E<{-E<{O'-pQ?MtO1G6iOOQO,5?k,5?kOOQO-E<}-E<}OOQ[1G3b1G3bO'-zQ`O,5=QOOQ[<<Lg<<LgO!&zQMhO<<LgO&=dQ`O<<LgO'.PQ`O<<LgO%[QlO<<LgOOQ[<<Li<<LiO9uQ!0LrO<<LiO$%dQ`O<<LiO9`Q`O<<LiO'.XQpO1G5WO'.dQ`O7+,UOOQ[AN=]AN=]O9uQ!0LrOAN=]OOQ[<= s<= sOOQ[<= t<= tO'.lQ`O<= sO'.qQ`O<= tOOQ[<<Lr<<LrO'.vQ`O<<LrO'.{QlO<<LrOOQ[1G3|1G3|O?YQ`O7+)mO'/SQ`O<<JQO'/_Q?MtO<<JQOOQO<<Hy<<HyOOQ!0LfAN?fAN?fOOQOAN?_AN?_O$AzQ!0MxOAN?_OOQOAN?OAN?OO%[QlOAN?_OOQO<<Mz<<MzOOQ[G27WG27WO!&zQMhOG27WO#(ZQ`OG27WO'/iQ!fOG27WO4UQ!fOG27WO'/pQ`OG27WO'/xQ?MtO<<JgO'0VQ?MvO1G2aO'1{Q?MvO,5?bO'4OQ?MvO,5?dO'6RQ?MvO1G2tO'8UQ?MvO1G2vO':XQ?MtO<<KYO':fQ?MtO<<I{OOQO1G1x1G1xO!,TQMhOANAjOOQO7+*d7+*dO':sQ`O7+*dO';OQ`O<= iO';WQ!dO7+*fOOQ!0Lb<<Kr<<KrO$+YQ`O<<KrOCwQ`O<<KrO';bQ`O<<KrO!&zQMhO<<KrOOQ!0Lb<<Kp<<KpO!CZQpO<<KpO';mQ!dO<<KrOOQ!0Lb<<Kq<<KqO';wQ`O<<KrO!&zQMhO<<KrO$+YQ`O<<KqO';|QMjOANDdO'<WQ!0MvO<<KuOOQO7+*s7+*sO9kQ`O7+*sO'<hQ`O<= rOOQ[G27sG27sO9uQ!0LrOG27sO@zQ`OG27sO!)[QlO1G5TO'<pQ`O7+,TO'<xQ`O1G2lO&=dQ`OANBROOQ[ANBRANBRO!&zQMhOANBRO'<}Q`OANBROOQ[ANBTANBTO9uQ!0LrOANBTO$%dQ`OANBTOOQO'#H`'#H`OOQO7+*r7+*rOOQ[G22wG22wOOQ[ANE_ANE_OOQ[ANE`ANE`OOQ[ANB^ANB^O'=VQ`OANB^OOQ[<<MX<<MXO!)[QlOAN?lOOQOG24yG24yO$AzQ!0MxOG24yO#(ZQ`OLD,rOOQ[LD,rLD,rO!&zQMhOLD,rO'=[Q!fOLD,rO'=cQ?MvO7+'{O'?XQ?MvO,5?bO'A[Q?MvO,5?dO'C_Q?MvO7+'}O'ETQMjOG27UOOQO<<NO<<NOOOQ!0LbANA^ANA^O$+YQ`OANA^OCwQ`OANA^O'EeQ!dOANA^OOQ!0LbANA[ANA[O'ElQ`OANA^O!&zQMhOANA^O'EwQ!dOANA^OOQ!0LbANA]ANA]OOQO<<N_<<N_OOQ[LD-_LD-_O9uQ!0LrOLD-_O'FRQ?MtO7+*oOOQO'#Gg'#GgOOQ[G27mG27mO&=dQ`OG27mO!&zQMhOG27mOOQ[G27oG27oO9uQ!0LrOG27oOOQ[G27xG27xO'F]Q?MtOG25WOOQOLD*eLD*eOOQ[!$(!^!$(!^O#(ZQ`O!$(!^O!&zQMhO!$(!^O'FgQ!0MzOG27UOOQ!0LbG26xG26xO$+YQ`OG26xO'HxQ`OG26xOCwQ`OG26xO'ITQ!dOG26xO!&zQMhOG26xOOQ[!$(!y!$(!yOOQ[LD-XLD-XO&=dQ`OLD-XOOQ[LD-ZLD-ZOOQ[!)9Ex!)9ExO#(ZQ`O!)9ExOOQ!0LbLD,dLD,dO$+YQ`OLD,dOCwQ`OLD,dO'I[Q`OLD,dO'IgQ!dOLD,dOOQ[!$(!s!$(!sOOQ[!.K;d!.K;dO'InQ?MvOG27UOOQ!0Lb!$(!O!$(!OO$+YQ`O!$(!OOCwQ`O!$(!OO'KdQ`O!$(!OOOQ!0Lb!)9Ej!)9EjO$+YQ`O!)9EjOCwQ`O!)9EjOOQ!0Lb!.K;U!.K;UO$+YQ`O!.K;UOOQ!0Lb!4/0p!4/0pO!)[QlO'#DzO1PQ`O'#EXO'KoQ!fO'#JsO'KvQ!L^O'#DvO'K}QlO'#EOO'LUQ!fO'#CiO'NlQ!fO'#CiO!)[QlO'#EQO'N|QlO,5;ZO!)[QlO,5;fO!)[QlO,5;fO!)[QlO,5;fO!)[QlO,5;fO!)[QlO,5;fO!)[QlO,5;fO!)[QlO,5;fO!)[QlO,5;fO!)[QlO,5;fO!)[QlO,5;fO!)[QlO'#IqO(#PQ`O,5<jO!)[QlO,5;fO(#XQMhO,5;fO($rQMhO,5;fO!)[QlO,5;xO!&zQMhO'#GnO(#XQMhO'#GnO!&zQMhO'#GpO(#XQMhO'#GpO1SQ`O'#DZO1SQ`O'#DZO!&zQMhO'#GQO(#XQMhO'#GQO!&zQMhO'#GSO(#XQMhO'#GSO!&zQMhO'#GbO(#XQMhO'#GbO!)[QlO,5:jO($yQpO'#D_O!)[QlO,5@pO'N|QlO1G0uO(%TQ?MtO'#CiO!)[QlO1G2QO!&zQMhO'#IvO(#XQMhO'#IvO!&zQMhO'#IxO(#XQMhO'#IxO(%_Q!dO'#CrO!&zQMhO,5<uO(#XQMhO,5<uO'N|QlO1G2SO!)[QlO7+&{O!&zQMhO1G2aO(#XQMhO1G2aO!&zQMhO'#IvO(#XQMhO'#IvO!&zQMhO'#IxO(#XQMhO'#IxO!&zQMhO1G2cO(#XQMhO1G2cO'N|QlO7+'nO'N|QlO7+&aO!&zQMhOANAjO(#XQMhOANAjO(%rQ`O'#EoO(%wQ`O'#EoO(&PQ`O'#F^O(&UQ`O'#EzO(&ZQ`O'#KUO(&fQ`O'#KSO(&qQ`O,5;ZO(&vQMjO,5<fO(&}Q`O'#GZO('SQ`O'#GZO('XQ`O,5<fO('aQ`O,5<hO('iQ`O,5;ZO('qQ?MtO1G1aO('xQ`O,5<uO('}Q`O,5<uO((SQ`O,5<wO((XQ`O,5<wO((^Q`O1G2SO((cQ`O1G0uO((hQMjO<<LOO((oQMjO<<LOO((vQMhO'#F}O9`Q`O'#F|OAuQ`O'#EnO!)[QlO,5;uO!3oQ`O'#GZO!3oQ`O'#GZO!3oQ`O'#G]O!3oQ`O'#G]O!,TQMhO7+(dO!,TQMhO7+(dO%/YQ!dO1G2xO%/YQ!dO1G2xO!&zQMhO,5=^O!&zQMhO,5=^",stateData:"(){~O'}OS(OOSTOS(PRQ~OPYOQYOSfOY!VOaqOdzOeyOl!POpkOrYOskOtkOzkO|YO!OYO!SWO!WkO!XkO!_XO!iuO!lZO!oYO!pYO!qYO!svO!uwO!xxO!|]O$X|O$oiO%i}O%k!QO%m!OO%n!OO%o!OO%r!RO%t!SO%w!TO%x!TO%z!UO&X!WO&_!XO&a!YO&c!ZO&e![O&h!]O&n!^O&t!_O&v!`O&x!aO&z!bO&|!cO(USO(WTO(ZUO(bVO(p[O~OWtO~P`OPYOQYOSfOd!jOe!iOpkOrYOskOtkOzkO|YO!OYO!SWO!WkO!XkO!_!eO!iuO!lZO!oYO!pYO!qYO!svO!u!gO!x!hO$X!kO$oiO(U!dO(WTO(ZUO(bVO(p[O~Oa!wOs!nO!S!oO!b!yO!c!vO!d!vO!|<XO#T!pO#U!pO#V!xO#W!pO#X!pO#[!zO#]!zO(V!lO(WTO(ZUO(f!mO(p!sO~O(P!{O~OP]XR]X[]Xa]Xj]Xr]X!Q]X!S]X!]]X!l]X!p]X#R]X#S]X#`]X#lfX#o]X#p]X#q]X#r]X#s]X#t]X#u]X#v]X#w]X#y]X#{]X#|]X$R]X'{]X(b]X(s]X(z]X({]X~O!g%SX~P(qO_!}O(W#PO(X!}O(Y#PO~O_#QO(Y#PO(Z#PO([#QO~Ox#SO!U#TO(c#TO(d#VO~OPYOQYOSfOd!jOe!iOpkOrYOskOtkOzkO|YO!OYO!SWO!WkO!XkO!_!eO!iuO!lZO!oYO!pYO!qYO!svO!u!gO!x!hO$X!kO$oiO(U<]O(WTO(ZUO(bVO(p[O~O![#ZO!]#WO!Y(iP!Y(wP~P+}O!^#cO~P`OPYOQYOSfOd!jOe!iOrYOskOtkOzkO|YO!OYO!SWO!WkO!XkO!_!eO!iuO!lZO!oYO!pYO!qYO!svO!u!gO!x!hO$X!kO$oiO(WTO(ZUO(bVO(p[O~Op#mO![#iO!|]O#j#lO#k#iO(U<^O!k(tP~P.iO!l#oO(U#nO~O!x#sO!|]O%i#tO~O#l#uO~O!g#vO#l#uO~OP$[OR#zO[$cOj$ROr$aO!Q#yO!S#{O!]$_O!l#xO!p$[O#R$RO#o$OO#p$PO#q$PO#r$PO#s$QO#t$RO#u$RO#v$bO#w$SO#y$UO#{$WO#|$XO(bVO(s$YO(z#|O({#}O~Oa(gX'{(gX'x(gX!k(gX!Y(gX!_(gX%j(gX!g(gX~P1qO#S$dO#`$eO$R$eOP(hXR(hX[(hXj(hXr(hX!Q(hX!S(hX!](hX!l(hX!p(hX#R(hX#o(hX#p(hX#q(hX#r(hX#s(hX#t(hX#u(hX#v(hX#w(hX#y(hX#{(hX#|(hX(b(hX(s(hX(z(hX({(hX!_(hX%j(hX~Oa(hX'{(hX'x(hX!Y(hX!k(hXv(hX!g(hX~P4UO#`$eO~O$^$hO$`$gO$g$mO~OSfO!_$nO$j$oO$l$qO~Oh%VOj%dOk%dOp%WOr%XOs$tOt$tOz%YO|%ZO!O%]O!S${O!_$|O!i%bO!l$xO#k%cO$X%`O$u%^O$w%_O$z%aO(U$sO(WTO(ZUO(b$uO(z$}O({%POg(_P~Ol%[O~P7eO!l%eO~O!S%hO!_%iO(U%gO~O!g%mO~Oa%nO'{%nO~O!Q%rO~P%[O(V!lO~P%[O%o%vO~P%[Oh%VO!l%eO(U%gO(V!lO~Oe%}O!l%eO(U%gO~Oj$RO~O!_&PO(U%gO(V!lO(WTO(ZUO`)XP~O!Q&SO!l&RO%k&VO&U&WO~P;SO!x#sO~O%t&YO!S)TX!_)TX(U)TX~O(U&ZO~Ol!PO!u&`O%k!QO%m!OO%n!OO%o!OO%r!RO%t!SO%w!TO%x!TO~Od&eOe&dO!x&bO%i&cO%|&aO~P<bOd&hOeyOl!PO!_&gO!u&`O!xxO!|]O%i}O%m!OO%n!OO%o!OO%r!RO%t!SO%w!TO%x!TO%z!UO~Ob&kO#`&nO%k&iO(V!lO~P=gO!l&oO!u&sO~O!l#oO~O!_XO~Oa%nO'y&{O'{%nO~Oa%nO'y'OO'{%nO~Oa%nO'y'QO'{%nO~O'x]X!Y]Xv]X!k]X&]]X!_]X%j]X!g]X~P(qO!b'`O!c'WO!d'WO(V!lO(WTO(ZUO~Os'UO!S'TO!['XO(f'SO!^(jP!^(yP~P@nOn'cO!_'aO(U%gO~Oe'hO!l%eO(U%gO~O!Q&SO!l&RO~Os!nO!S!oO!|<XO#T!pO#U!pO#W!pO#X!pO(V!lO(WTO(ZUO(f!mO(p!sO~O!b'nO!c'mO!d'mO#V!pO#['oO#]'oO~PBYOa%nOh%VO!g#vO!l%eO'{%nO(s'qO~O!p'uO#`'sO~PChOs!nO!S!oO(WTO(ZUO(f!mO(p!sO~O!_XOs(nX!S(nX!b(nX!c(nX!d(nX!|(nX#T(nX#U(nX#V(nX#W(nX#X(nX#[(nX#](nX(V(nX(W(nX(Z(nX(f(nX(p(nX~O!c'mO!d'mO(V!lO~PDWO(Q'yO(R'yO(S'{O~O_!}O(W'}O(X!}O(Y'}O~O_#QO(Y'}O(Z'}O([#QO~Ov(PO~P%[Ox#SO!U#TO(c#TO(d(SO~O![(UO!Y'XX!Y'_X!]'XX!]'_X~P+}O!](WO!Y(iX~OP$[OR#zO[$cOj$ROr$aO!Q#yO!S#{O!](WO!l#xO!p$[O#R$RO#o$OO#p$PO#q$PO#r$PO#s$QO#t$RO#u$RO#v$bO#w$SO#y$UO#{$WO#|$XO(bVO(s$YO(z#|O({#}O~O!Y(iX~PHRO!Y(]O~O!Y(vX!](vX!g(vX!k(vX(s(vX~O#`(vX#l#dX!^(vX~PJUO#`(^O!Y(xX!](xX~O!](_O!Y(wX~O!Y(bO~O#`$eO~PJUO!^(cO~P`OR#zO!Q#yO!S#{O!l#xO(bVOP!na[!naj!nar!na!]!na!p!na#R!na#o!na#p!na#q!na#r!na#s!na#t!na#u!na#v!na#w!na#y!na#{!na#|!na(s!na(z!na({!na~Oa!na'{!na'x!na!Y!na!k!nav!na!_!na%j!na!g!na~PKlO!k(dO~O!g#vO#`(eO(s'qO!](uXa(uX'{(uX~O!k(uX~PNXO!S%hO!_%iO!|]O#j(jO#k(iO(U%gO~O!](kO!k(tX~O!k(mO~O!S%hO!_%iO#k(iO(U%gO~OP(hXR(hX[(hXj(hXr(hX!Q(hX!S(hX!](hX!l(hX!p(hX#R(hX#o(hX#p(hX#q(hX#r(hX#s(hX#t(hX#u(hX#v(hX#w(hX#y(hX#{(hX#|(hX(b(hX(s(hX(z(hX({(hX~O!g#vO!k(hX~P! uOR(oO!Q(nO!l#xO#S$dO!|!{a!S!{a~O!x!{a%i!{a!_!{a#j!{a#k!{a(U!{a~P!#vO!x(sO~OPYOQYOSfOd!jOe!iOpkOrYOskOtkOzkO|YO!OYO!SWO!WkO!XkO!_XO!iuO!lZO!oYO!pYO!qYO!svO!u!gO!x!hO$X!kO$oiO(U!dO(WTO(ZUO(bVO(p[O~Oh%VOp%WOr%XOs$tOt$tOz%YO|%ZO!O<uO!S${O!_$|O!i>WO!l$xO#k<{O$X%`O$u<wO$w<yO$z%aO(U(wO(WTO(ZUO(b$uO(z$}O({%PO~O#l(yO~O![({O!k(lP~P%[O(f(}O(p[O~O!S)PO!l#xO(f(}O(p[O~OP<WOQ<WOSfOd>SOe!iOpkOr<WOskOtkOzkO|<WO!O<WO!SWO!WkO!XkO!_!eO!i<ZO!lZO!o<WO!p<WO!q<WO!s<[O!u<_O!x!hO$X!kO$o>QO(U)^O(WTO(ZUO(bVO(p[O~O!]$_Oa$ra'{$ra'x$ra!k$ra!Y$ra!_$ra%j$ra!g$ra~Ol)eO~P!&zOh%VOp%WOr%XOs$tOt$tOz%YO|%ZO!O%]O!S${O!_$|O!i%bO!l$xO#k%cO$X%`O$u%^O$w%_O$z%aO(U(wO(WTO(ZUO(b$uO(z$}O({%PO~Og(qP~P!,TO!Q)jO!g)iO!_$_X$[$_X$^$_X$`$_X$g$_X~O!g)iO!_(|X$[(|X$^(|X$`(|X$g(|X~O!Q)jO~P!.^O!Q)jO!_(|X$[(|X$^(|X$`(|X$g(|X~O!_)lO$[)pO$^)kO$`)kO$g)qO~O![)tO~P!)[O$^$hO$`$gO$g)xO~On${X!Q${X#S${X'z${X(z${X({${X~OgmXg${XnmX!]mX#`mX~P!0SOx)zO(c){O(d)}O~On*WO!Q*PO'z*QO(z$}O({%PO~Og*OO~P!1WOg*XO~Oh%VOr%XOs$tOt$tOz%YO|%ZO!O<uO!S*ZO!_*[O!i>WO!l$xO#k<{O$X%`O$u<wO$w<yO$z%aO(WTO(ZUO(b$uO(z$}O({%PO~Op*aOUX'{)UX~OP$[OR#zO[$cOj$ROr$aO!Q#yO!S#{O!l#xO!p$[O#R$RO#o$OO#p$PO#q$PO#r$PO#s$QO#t$RO#u$RO#v$bO#w$SO#y$UO#{$WO#|$XO(bVO(s$YO(z#|O({#}O~Oa!ja!]!ja'{!ja'x!ja!Y!ja!k!jav!ja!_!ja%j!ja!g!ja~P!:tO(f(}O~OR#zO!Q#yO!S#{O!l#xO(bVOP!ra[!raj!rar!ra!]!ra!p!ra#R!ra#o!ra#p!ra#q!ra#r!ra#s!ra#t!ra#u!ra#v!ra#w!ra#y!ra#{!ra#|!ra(s!ra(z!ra({!ra~Oa!ra'{!ra'x!ra!Y!ra!k!rav!ra!_!ra%j!ra!g!ra~P!=aOR#zO!Q#yO!S#{O!l#xO(bVOP!ta[!taj!tar!ta!]!ta!p!ta#R!ta#o!ta#p!ta#q!ta#r!ta#s!ta#t!ta#u!ta#v!ta#w!ta#y!ta#{!ta#|!ta(s!ta(z!ta({!ta~Oa!ta'{!ta'x!ta!Y!ta!k!tav!ta!_!ta%j!ta!g!ta~P!?wOh%VOn+iO!_'aO%j+hO~O!g+kOa(^X!_(^X'{(^X!](^X~Oa%nO!_XO'{%nO~Oh%VO!l%eO~Oh%VO!l%eO(U%gO~O!g#vO#l(yO~Ob+vO%k+wO(U+sO(WTO(ZUO!^)YP~O!]+xO`)XX~O[+|O~O`+}O~O!_&PO(U%gO(V!lO`)XP~O%k,QO~P;SOh%VO#`,UO~Oh%VOn,XO!_$|O~O!_,ZO~O!Q,]O!_XO~O%o%vO~O!x,bO~Oe,gO~Ob,hO(U#nO(WTO(ZUO!^)WP~Oe%}O~O%k!QO(U&ZO~P=gO[,mO`,lO~OPYOQYOSfOdzOeyOpkOrYOskOtkOzkO|YO!OYO!SWO!WkO!XkO!iuO!lZO!oYO!pYO!qYO!svO!xxO!|]O$oiO%i}O(WTO(ZUO(bVO(p[O~O!_!eO!u!gO$X!kO(U!dO~P!GOO`,lOa%nO'{%nO~OPYOQYOSfOd!jOe!iOpkOrYOskOtkOzkO|YO!OYO!SWO!WkO!XkO!_!eO!iuO!lZO!oYO!pYO!qYO!svO!x!hO$X!kO$oiO(U!dO(WTO(ZUO(bVO(p[O~Oa,rOl!OO!uwO%m!OO%n!OO%o!OO~P!IhO!l&oO~O&_,xO~O!_,zO~O&p,|O&r,}OP&maQ&maS&maY&maa&mad&mae&mal&map&mar&mas&mat&maz&ma|&ma!O&ma!S&ma!W&ma!X&ma!_&ma!i&ma!l&ma!o&ma!p&ma!q&ma!s&ma!u&ma!x&ma!|&ma$X&ma$o&ma%i&ma%k&ma%m&ma%n&ma%o&ma%r&ma%t&ma%w&ma%x&ma%z&ma&X&ma&_&ma&a&ma&c&ma&e&ma&h&ma&n&ma&t&ma&v&ma&x&ma&z&ma&|&ma'x&ma(U&ma(W&ma(Z&ma(b&ma(p&ma!^&ma&f&mab&ma&k&ma~O(U-SO~Oh!eX!]#iX!^#iX!g!RX!g!eX!l!eX#`#iX~O!]!eX!^!eX~P#!nO!g-WOh(kX!](kX!^(kX!g(kX!l(kXr(kX(s(kX~Oh%VO!g-YO!l%eO!]!aX!^!aX~Os!nO!S!oO(WTO(ZUO(f!mO~OP<WOQ<WOSfOd>SOe!iOpkOr<WOskOtkOzkO|<WO!O<WO!SWO!WkO!XkO!_!eO!i<ZO!lZO!o<WO!p<WO!q<WO!s<[O!u<_O!x!hO$X!kO$o>QO(WTO(ZUO(bVO(p[O~O(U=RO~P#$oO!]-^O!^(jX~O!^-`O~O#`-aO!]#hX!^#hX~O!g-WO~O!]-bO!^(yX~O!^-dO~O!c-eO!d-eO(V!lO~P#$^O!^-hO~P'_On-kO!_'aO~O!Y-pO~Os!{a!b!{a!c!{a!d!{a#T!{a#U!{a#V!{a#W!{a#X!{a#[!{a#]!{a(V!{a(W!{a(Z!{a(f!{a(p!{a~P!#vO!p-uO#`-sO~PChO!c-wO!d-wO(V!lO~PDWOa%nO#`-sO'{%nO~Oa%nO!g#vO#`-sO'{%nO~Oa%nO!g#vO!p-uO#`-sO'{%nO(s'qO~O(Q'yO(R'yO(S-|O~Ov-}O~O!Y'Xa!]'Xa~P!:tO![.RO!Y'XX!]'XX~P%[O!](WO!Y(ia~O!Y(ia~PHRO!](_O!Y(wa~O!S%hO![.VO!_%iO(U%gO!Y'_X!]'_X~O#`.XO!](ua!k(uaa(ua'{(ua~O!g#vO~P#,wO!](kO!k(ta~O!S%hO!_%iO#k.]O(U%gO~Op.bO!S%hO![._O!_%iO!|]O#j.aO#k._O(U%gO!]'bX!k'bX~OR.fO!l#xO~Oh%VOn.iO!_'aO%j.hO~Oa#ci!]#ci'{#ci'x#ci!Y#ci!k#civ#ci!_#ci%j#ci!g#ci~P!:tOn>^O!Q*PO'z*QO(z$}O({%PO~O#l#_aa#_a#`#_a'{#_a!]#_a!k#_a!_#_a!Y#_a~P#/sO#l(aXP(aXR(aX[(aXa(aXj(aXr(aX!S(aX!l(aX!p(aX#R(aX#o(aX#p(aX#q(aX#r(aX#s(aX#t(aX#u(aX#v(aX#w(aX#y(aX#{(aX#|(aX'{(aX(b(aX(s(aX!k(aX!Y(aX'x(aXv(aX!_(aX%j(aX!g(aX~P!6kO!].vO!k(lX~P!:tO!k.yO~O!Y.{O~OP$[OR#zO!Q#yO!S#{O!l#xO!p$[O(bVO[#nia#nij#nir#ni!]#ni#R#ni#p#ni#q#ni#r#ni#s#ni#t#ni#u#ni#v#ni#w#ni#y#ni#{#ni#|#ni'{#ni(s#ni(z#ni({#ni'x#ni!Y#ni!k#niv#ni!_#ni%j#ni!g#ni~O#o#ni~P#3cO#o$OO~P#3cOP$[OR#zOr$aO!Q#yO!S#{O!l#xO!p$[O#o$OO#p$PO#q$PO#r$PO(bVO[#nia#nij#ni!]#ni#R#ni#t#ni#u#ni#v#ni#w#ni#y#ni#{#ni#|#ni'{#ni(s#ni(z#ni({#ni'x#ni!Y#ni!k#niv#ni!_#ni%j#ni!g#ni~O#s#ni~P#6QO#s$QO~P#6QOP$[OR#zO[$cOj$ROr$aO!Q#yO!S#{O!l#xO!p$[O#R$RO#o$OO#p$PO#q$PO#r$PO#s$QO#t$RO#u$RO#v$bO(bVOa#ni!]#ni#y#ni#{#ni#|#ni'{#ni(s#ni(z#ni({#ni'x#ni!Y#ni!k#niv#ni!_#ni%j#ni!g#ni~O#w#ni~P#8oOP$[OR#zO[$cOj$ROr$aO!Q#yO!S#{O!l#xO!p$[O#R$RO#o$OO#p$PO#q$PO#r$PO#s$QO#t$RO#u$RO#v$bO#w$SO(bVO({#}Oa#ni!]#ni#{#ni#|#ni'{#ni(s#ni(z#ni'x#ni!Y#ni!k#niv#ni!_#ni%j#ni!g#ni~O#y$UO~P#;VO#y#ni~P#;VO#w$SO~P#8oOP$[OR#zO[$cOj$ROr$aO!Q#yO!S#{O!l#xO!p$[O#R$RO#o$OO#p$PO#q$PO#r$PO#s$QO#t$RO#u$RO#v$bO#w$SO#y$UO(bVO(z#|O({#}Oa#ni!]#ni#|#ni'{#ni(s#ni'x#ni!Y#ni!k#niv#ni!_#ni%j#ni!g#ni~O#{#ni~P#={O#{$WO~P#={OP]XR]X[]Xj]Xr]X!Q]X!S]X!l]X!p]X#R]X#S]X#`]X#lfX#o]X#p]X#q]X#r]X#s]X#t]X#u]X#v]X#w]X#y]X#{]X#|]X$R]X(b]X(s]X(z]X({]X!]]X!^]X~O$P]X~P#@jOP$[OR#zO[<oOj<dOr<mO!Q#yO!S#{O!l#xO!p$[O#R<dO#o<aO#p<bO#q<bO#r<bO#s<cO#t<dO#u<dO#v<nO#w<eO#y<gO#{<iO#|<jO(bVO(s$YO(z#|O({#}O~O$P.}O~P#BwO#S$dO#`<pO$R<pO$P(hX!^(hX~P! uOa'ea!]'ea'{'ea'x'ea!k'ea!Y'eav'ea!_'ea%j'ea!g'ea~P!:tO[#nia#nij#nir#ni!]#ni#R#ni#s#ni#t#ni#u#ni#v#ni#w#ni#y#ni#{#ni#|#ni'{#ni(s#ni'x#ni!Y#ni!k#niv#ni!_#ni%j#ni!g#ni~OP$[OR#zO!Q#yO!S#{O!l#xO!p$[O#o$OO#p$PO#q$PO#r$PO(bVO(z#ni({#ni~P#EyOn>^O!Q*PO'z*QO(z$}O({%POP#niR#ni!S#ni!l#ni!p#ni#o#ni#p#ni#q#ni#r#ni(b#ni~P#EyO!]/ROg(qX~P!1WOg/TO~Oa$Qi!]$Qi'{$Qi'x$Qi!Y$Qi!k$Qiv$Qi!_$Qi%j$Qi!g$Qi~P!:tO$^/UO$`/UO~O$^/VO$`/VO~O!g)iO#`/WO!_$dX$[$dX$^$dX$`$dX$g$dX~O![/XO~O!_)lO$[/ZO$^)kO$`)kO$g/[O~O!]<kO!^(gX~P#BwO!^/]O~O!g)iO$g(|X~O$g/_O~Ov/`O~P!&zOx)zO(c){O(d/cO~O!S/fO~O(z$}On%ba!Q%ba'z%ba({%ba!]%ba#`%ba~Og%ba$P%ba~P#L{O({%POn%da!Q%da'z%da(z%da!]%da#`%da~Og%da$P%da~P#MnO!]fX!gfX!kfX!k${X(sfX~P!0SOp%WOQP~P!1uOr*tO!b*rO!c*lO!d*lO!l*cO#[*sO%a*nO(V!lO(WTO(ZUO~Os'UO!S/pO![+^O!^*qO(f=OO!^(yP~P$ [O!k/qO~P#/sO!]/rO!g#vO(s'qO!k)PX~O!k/wO~OnoX!QoX'zoX(zoX({oX~O!g#vO!koX~P$#OOp/yO!S%hO![*_O!_%iO(U%gO!k)PP~O#l/zO~O!Y${X!]${X!g%SX~P!0SO!]/{O!Y)QX~P#/sO!g/}O~O!Y0PO~OpkO(U0QO~P.iOh%VOr0VO!g#vO!l%eO(s'qO~O!g+kO~Oa%nO!]0ZO'{%nO~O!^0]O~P!5iO!c0^O!d0^O(V!lO~P#$^Os!nO!S0_O(WTO(ZUO(f!mO~O#[0aO~Og%ba!]%ba#`%ba$P%ba~P!1WOg%da!]%da#`%da$P%da~P!1WOj%dOk%dOl%dO(U&ZOg'nX!]'nX~O!]*zOg(_a~Og0jO~On0lO#`0kOg(`a!](`a~OR0mO!Q0mO!S0nO#S$dOn}a'z}a(z}a({}a!]}a#`}a~Og}a$P}a~P$(cO!Q*PO'z*QOn$ta(z$ta({$ta!]$ta#`$ta~Og$ta$P$ta~P$)_O!Q*PO'z*QOn$va(z$va({$va!]$va#`$va~Og$va$P$va~P$*QO#l0qO~Og%Ua!]%Ua#`%Ua$P%Ua~P!1WO!g#vO~O#l0tO~O!]#iX!^#iX!g!RX#`#iX~O!]+`Oa)Ua'{)Ua~OR#zO!Q#yO!S#{O!l#xO(bVOP!ri[!rij!rir!ri!]!ri!p!ri#R!ri#o!ri#p!ri#q!ri#r!ri#s!ri#t!ri#u!ri#v!ri#w!ri#y!ri#{!ri#|!ri(s!ri(z!ri({!ri~Oa!ri'{!ri'x!ri!Y!ri!k!riv!ri!_!ri%j!ri!g!ri~P$+}Oh%VOr%XOs$tOt$tOz%YO|%ZO!O<uO!S${O!_$|O!i>WO!l$xO#k<{O$X%`O$u<wO$w<yO$z%aO(WTO(ZUO(b$uO(z$}O({%PO~Op0}O%^1OO(U0|O~P$.eO!g+kOa(^a!_(^a'{(^a!](^a~O#l1UO~O[]X!]fX!^fX~O!]1VO!^)YX~O!^1XO~O[1YO~Ob1[O(U+sO(WTO(ZUO~O!_&PO(U%gO`'vX!]'vX~O!]+xO`)Xa~O!k1_O~P!:tO[1bO~O`1cO~O#`1hO~On1kO!_$|O~O(f(}O!^)VP~Oh%VOn1tO!_1qO%j1sO~O[2OO!]1|O!^)WX~O!^2PO~O`2ROa%nO'{%nO~O(U#nO(WTO(ZUO~O#S$dO#`$eO$R$eOP(hXR(hX[(hXr(hX!Q(hX!S(hX!](hX!l(hX!p(hX#R(hX#o(hX#p(hX#q(hX#r(hX#s(hX#t(hX#u(hX#v(hX#w(hX#y(hX#{(hX#|(hX(b(hX(s(hX(z(hX({(hX~Oj2UO&]2VOa(hX~P$4OOj2UO#`$eO&]2VO~Oa2XO~P%[Oa2ZO~O&f2^OP&diQ&diS&diY&dia&did&die&dil&dip&dir&dis&dit&diz&di|&di!O&di!S&di!W&di!X&di!_&di!i&di!l&di!o&di!p&di!q&di!s&di!u&di!x&di!|&di$X&di$o&di%i&di%k&di%m&di%n&di%o&di%r&di%t&di%w&di%x&di%z&di&X&di&_&di&a&di&c&di&e&di&h&di&n&di&t&di&v&di&x&di&z&di&|&di'x&di(U&di(W&di(Z&di(b&di(p&di!^&dib&di&k&di~Ob2dO!^2bO&k2cO~P`O!_XO!l2fO~O&r,}OP&miQ&miS&miY&mia&mid&mie&mil&mip&mir&mis&mit&miz&mi|&mi!O&mi!S&mi!W&mi!X&mi!_&mi!i&mi!l&mi!o&mi!p&mi!q&mi!s&mi!u&mi!x&mi!|&mi$X&mi$o&mi%i&mi%k&mi%m&mi%n&mi%o&mi%r&mi%t&mi%w&mi%x&mi%z&mi&X&mi&_&mi&a&mi&c&mi&e&mi&h&mi&n&mi&t&mi&v&mi&x&mi&z&mi&|&mi'x&mi(U&mi(W&mi(Z&mi(b&mi(p&mi!^&mi&f&mib&mi&k&mi~O!Y2lO~O!]!aa!^!aa~P#BwOs!nO!S!oO![2qO(f!mO!]'YX!^'YX~P@nO!]-^O!^(ja~O!]'`X!^'`X~P!9|O!]-bO!^(ya~O!^2yO~P'_Oa%nO#`3SO'{%nO~Oa%nO!g#vO#`3SO'{%nO~Oa%nO!g#vO!p3WO#`3SO'{%nO(s'qO~Oa%nO'{%nO~P!:tO!]$_Ov$ra~O!Y'Xi!]'Xi~P!:tO!](WO!Y(ii~O!](_O!Y(wi~O!Y(xi!](xi~P!:tO!](ui!k(uia(ui'{(ui~P!:tO#`3YO!](ui!k(uia(ui'{(ui~O!](kO!k(ti~O!S%hO!_%iO!|]O#j3_O#k3^O(U%gO~O!S%hO!_%iO#k3^O(U%gO~On3fO!_'aO%j3eO~Oh%VOn3fO!_'aO%j3eO~O#l%baP%baR%ba[%baa%baj%bar%ba!S%ba!l%ba!p%ba#R%ba#o%ba#p%ba#q%ba#r%ba#s%ba#t%ba#u%ba#v%ba#w%ba#y%ba#{%ba#|%ba'{%ba(b%ba(s%ba!k%ba!Y%ba'x%bav%ba!_%ba%j%ba!g%ba~P#L{O#l%daP%daR%da[%daa%daj%dar%da!S%da!l%da!p%da#R%da#o%da#p%da#q%da#r%da#s%da#t%da#u%da#v%da#w%da#y%da#{%da#|%da'{%da(b%da(s%da!k%da!Y%da'x%dav%da!_%da%j%da!g%da~P#MnO#l%baP%baR%ba[%baa%baj%bar%ba!S%ba!]%ba!l%ba!p%ba#R%ba#o%ba#p%ba#q%ba#r%ba#s%ba#t%ba#u%ba#v%ba#w%ba#y%ba#{%ba#|%ba'{%ba(b%ba(s%ba!k%ba!Y%ba'x%ba#`%bav%ba!_%ba%j%ba!g%ba~P#/sO#l%daP%daR%da[%daa%daj%dar%da!S%da!]%da!l%da!p%da#R%da#o%da#p%da#q%da#r%da#s%da#t%da#u%da#v%da#w%da#y%da#{%da#|%da'{%da(b%da(s%da!k%da!Y%da'x%da#`%dav%da!_%da%j%da!g%da~P#/sO#l}aP}a[}aa}aj}ar}a!l}a!p}a#R}a#o}a#p}a#q}a#r}a#s}a#t}a#u}a#v}a#w}a#y}a#{}a#|}a'{}a(b}a(s}a!k}a!Y}a'x}av}a!_}a%j}a!g}a~P$(cO#l$taP$taR$ta[$taa$taj$tar$ta!S$ta!l$ta!p$ta#R$ta#o$ta#p$ta#q$ta#r$ta#s$ta#t$ta#u$ta#v$ta#w$ta#y$ta#{$ta#|$ta'{$ta(b$ta(s$ta!k$ta!Y$ta'x$tav$ta!_$ta%j$ta!g$ta~P$)_O#l$vaP$vaR$va[$vaa$vaj$var$va!S$va!l$va!p$va#R$va#o$va#p$va#q$va#r$va#s$va#t$va#u$va#v$va#w$va#y$va#{$va#|$va'{$va(b$va(s$va!k$va!Y$va'x$vav$va!_$va%j$va!g$va~P$*QO#l%UaP%UaR%Ua[%Uaa%Uaj%Uar%Ua!S%Ua!]%Ua!l%Ua!p%Ua#R%Ua#o%Ua#p%Ua#q%Ua#r%Ua#s%Ua#t%Ua#u%Ua#v%Ua#w%Ua#y%Ua#{%Ua#|%Ua'{%Ua(b%Ua(s%Ua!k%Ua!Y%Ua'x%Ua#`%Uav%Ua!_%Ua%j%Ua!g%Ua~P#/sOa#cq!]#cq'{#cq'x#cq!Y#cq!k#cqv#cq!_#cq%j#cq!g#cq~P!:tO![3nO!]'ZX!k'ZX~P%[O!].vO!k(la~O!].vO!k(la~P!:tO!Y3qO~O$P!na!^!na~PKlO$P!ja!]!ja!^!ja~P#BwO$P!ra!^!ra~P!=aO$P!ta!^!ta~P!?wOg'^X!]'^X~P!,TO!]/ROg(qa~OSfO!_4VO$e4WO~O!^4[O~Ov4]O~P#/sOa$nq!]$nq'{$nq'x$nq!Y$nq!k$nqv$nq!_$nq%j$nq!g$nq~P!:tO!Y4_O~P!&zO!S4`O~O!Q*PO'z*QO({%POn'ja(z'ja!]'ja#`'ja~Og'ja$P'ja~P%-tO!Q*PO'z*QOn'la(z'la({'la!]'la#`'la~Og'la$P'la~P%.gO(s$YO~P#/sO!YfX!Y${X!]fX!]${X!g%SX#`fX~P!0SOp%WO(U=XO~P!1uOp4dO!S%hO![4cO!_%iO(U%gO!]'fX!k'fX~O!]/rO!k)Pa~O!]/rO!g#vO!k)Pa~O!]/rO!g#vO(s'qO!k)Pa~Og$}i!]$}i#`$}i$P$}i~P!1WO![4lO!Y'hX!]'hX~P!3tO!]/{O!Y)Qa~O!]/{O!Y)Qa~P#/sOP]XR]X[]Xj]Xr]X!Q]X!S]X!Y]X!]]X!l]X!p]X#R]X#S]X#`]X#lfX#o]X#p]X#q]X#r]X#s]X#t]X#u]X#v]X#w]X#y]X#{]X#|]X$R]X(b]X(s]X(z]X({]X~Oj%ZX!g%ZX~P%2^Oj4qO!g#vO~Oh%VO!g#vO!l%eO~Oh%VOr4vO!l%eO(s'qO~Or4{O!g#vO(s'qO~Os!nO!S4|O(WTO(ZUO(f!mO~O(z$}On%bi!Q%bi'z%bi({%bi!]%bi#`%bi~Og%bi$P%bi~P%5}O({%POn%di!Q%di'z%di(z%di!]%di#`%di~Og%di$P%di~P%6pOg(`i!](`i~P!1WO#`5SOg(`i!](`i~P!1WO!k5XO~Oa$pq!]$pq'{$pq'x$pq!Y$pq!k$pqv$pq!_$pq%j$pq!g$pq~P!:tO!Y5]O~O!]5^O!_)RX~P#/sOa${X!_${X%_]X'{${X!]${X~P!0SO%_5aOaoX!_oX'{oX!]oX~P$#OOp5bO(U#nO~O%_5aO~Ob5hO%k5iO(U+sO(WTO(ZUO!]'uX!^'uX~O!]1VO!^)Ya~O[5mO~O`5nO~O[5rO~Oa%nO'{%nO~P#/sO!]5wO#`5yO!^)VX~O!^5zO~Or6QOs!nO!S*jO!b!yO!c!vO!d!vO!|<XO#T!pO#U!pO#V!pO#W!pO#X!pO#[6PO#]!zO(V!lO(WTO(ZUO(f!mO(p!sO~O!^6OO~P%;sOn6VO!_1qO%j6UO~Oh%VOn6VO!_1qO%j6UO~Ob6^O(U#nO(WTO(ZUO!]'tX!^'tX~O!]1|O!^)Wa~O(WTO(ZUO(f6`O~O`6dO~Oj6gO&]6hO~PNXO!k6iO~P%[Oa6kO~Oa6kO~P%[Ob2dO!^6pO&k2cO~P`O!g6rO~O!g6tOh(ki!](ki!^(ki!g(ki!l(kir(ki(s(ki~O#`6uO!]#hi!^#hi~O!]!ai!^!ai~P#BwO!]#hi!^#hi~P#BwOa%nO#`7OO'{%nO~Oa%nO!g#vO#`7OO'{%nO~O!](uq!k(uqa(uq'{(uq~P!:tO!](kO!k(tq~O!S%hO!_%iO#k7VO(U%gO~O!_'aO%j7YO~On7^O!_'aO%j7YO~O#l'jaP'jaR'ja['jaa'jaj'jar'ja!S'ja!l'ja!p'ja#R'ja#o'ja#p'ja#q'ja#r'ja#s'ja#t'ja#u'ja#v'ja#w'ja#y'ja#{'ja#|'ja'{'ja(b'ja(s'ja!k'ja!Y'ja'x'jav'ja!_'ja%j'ja!g'ja~P%-tO#l'laP'laR'la['laa'laj'lar'la!S'la!l'la!p'la#R'la#o'la#p'la#q'la#r'la#s'la#t'la#u'la#v'la#w'la#y'la#{'la#|'la'{'la(b'la(s'la!k'la!Y'la'x'lav'la!_'la%j'la!g'la~P%.gO#l$}iP$}iR$}i[$}ia$}ij$}ir$}i!S$}i!]$}i!l$}i!p$}i#R$}i#o$}i#p$}i#q$}i#r$}i#s$}i#t$}i#u$}i#v$}i#w$}i#y$}i#{$}i#|$}i'{$}i(b$}i(s$}i!k$}i!Y$}i'x$}i#`$}iv$}i!_$}i%j$}i!g$}i~P#/sO#l%biP%biR%bi[%bia%bij%bir%bi!S%bi!l%bi!p%bi#R%bi#o%bi#p%bi#q%bi#r%bi#s%bi#t%bi#u%bi#v%bi#w%bi#y%bi#{%bi#|%bi'{%bi(b%bi(s%bi!k%bi!Y%bi'x%biv%bi!_%bi%j%bi!g%bi~P%5}O#l%diP%diR%di[%dia%dij%dir%di!S%di!l%di!p%di#R%di#o%di#p%di#q%di#r%di#s%di#t%di#u%di#v%di#w%di#y%di#{%di#|%di'{%di(b%di(s%di!k%di!Y%di'x%div%di!_%di%j%di!g%di~P%6pO!]'Za!k'Za~P!:tO!].vO!k(li~O$P#ci!]#ci!^#ci~P#BwOP$[OR#zO!Q#yO!S#{O!l#xO!p$[O(bVO[#nij#nir#ni#R#ni#p#ni#q#ni#r#ni#s#ni#t#ni#u#ni#v#ni#w#ni#y#ni#{#ni#|#ni$P#ni(s#ni(z#ni({#ni!]#ni!^#ni~O#o#ni~P%NrO#o<aO~P%NrOP$[OR#zOr<mO!Q#yO!S#{O!l#xO!p$[O#o<aO#p<bO#q<bO#r<bO(bVO[#nij#ni#R#ni#t#ni#u#ni#v#ni#w#ni#y#ni#{#ni#|#ni$P#ni(s#ni(z#ni({#ni!]#ni!^#ni~O#s#ni~P&!zO#s<cO~P&!zOP$[OR#zO[<oOj<dOr<mO!Q#yO!S#{O!l#xO!p$[O#R<dO#o<aO#p<bO#q<bO#r<bO#s<cO#t<dO#u<dO#v<nO(bVO#y#ni#{#ni#|#ni$P#ni(s#ni(z#ni({#ni!]#ni!^#ni~O#w#ni~P&%SOP$[OR#zO[<oOj<dOr<mO!Q#yO!S#{O!l#xO!p$[O#R<dO#o<aO#p<bO#q<bO#r<bO#s<cO#t<dO#u<dO#v<nO#w<eO(bVO({#}O#{#ni#|#ni$P#ni(s#ni(z#ni!]#ni!^#ni~O#y<gO~P&'TO#y#ni~P&'TO#w<eO~P&%SOP$[OR#zO[<oOj<dOr<mO!Q#yO!S#{O!l#xO!p$[O#R<dO#o<aO#p<bO#q<bO#r<bO#s<cO#t<dO#u<dO#v<nO#w<eO#y<gO(bVO(z#|O({#}O#|#ni$P#ni(s#ni!]#ni!^#ni~O#{#ni~P&)dO#{<iO~P&)dOa#}y!]#}y'{#}y'x#}y!Y#}y!k#}yv#}y!_#}y%j#}y!g#}y~P!:tO[#nij#nir#ni#R#ni#s#ni#t#ni#u#ni#v#ni#w#ni#y#ni#{#ni#|#ni$P#ni(s#ni!]#ni!^#ni~OP$[OR#zO!Q#yO!S#{O!l#xO!p$[O#o<aO#p<bO#q<bO#r<bO(bVO(z#ni({#ni~P&,`On>_O!Q*PO'z*QO(z$}O({%POP#niR#ni!S#ni!l#ni!p#ni#o#ni#p#ni#q#ni#r#ni(b#ni~P&,`O#S$dOP(aXR(aX[(aXj(aXn(aXr(aX!Q(aX!S(aX!l(aX!p(aX#R(aX#o(aX#p(aX#q(aX#r(aX#s(aX#t(aX#u(aX#v(aX#w(aX#y(aX#{(aX#|(aX$P(aX'z(aX(b(aX(s(aX(z(aX({(aX!](aX!^(aX~O$P$Qi!]$Qi!^$Qi~P#BwO$P!ri!^!ri~P$+}Og'^a!]'^a~P!1WO!^7pO~O!]'ea!^'ea~P#BwO!Y7qO~P#/sO!g#vO(s'qO!]'fa!k'fa~O!]/rO!k)Pi~O!]/rO!g#vO!k)Pi~Og$}q!]$}q#`$}q$P$}q~P!1WO!Y'ha!]'ha~P#/sO!g7xO~O!]/{O!Y)Qi~P#/sO!]/{O!Y)Qi~O!Y7{O~Oh%VOr8QO!l%eO(s'qO~Oj8SO!g#vO~Or8VO!g#vO(s'qO~O!Q*PO'z*QO({%POn'ka(z'ka!]'ka#`'ka~Og'ka$P'ka~P&5aO!Q*PO'z*QOn'ma(z'ma({'ma!]'ma#`'ma~Og'ma$P'ma~P&6SOg(`q!](`q~P!1WO#`8XOg(`q!](`q~P!1WO!Y8YO~Og%Pq!]%Pq#`%Pq$P%Pq~P!1WOa$py!]$py'{$py'x$py!Y$py!k$pyv$py!_$py%j$py!g$py~P!:tO!g6tO~O!]5^O!_)Ra~O!_'aOP$UaR$Ua[$Uaj$Uar$Ua!Q$Ua!S$Ua!]$Ua!l$Ua!p$Ua#R$Ua#o$Ua#p$Ua#q$Ua#r$Ua#s$Ua#t$Ua#u$Ua#v$Ua#w$Ua#y$Ua#{$Ua#|$Ua(b$Ua(s$Ua(z$Ua({$Ua~O%j7YO~P&8tO%_8^Oa%]i!_%]i'{%]i!]%]i~Oa#cy!]#cy'{#cy'x#cy!Y#cy!k#cyv#cy!_#cy%j#cy!g#cy~P!:tO[8`O~Ob8bO(U+sO(WTO(ZUO~O!]1VO!^)Yi~O`8fO~O(f(}O!]'qX!^'qX~O!]5wO!^)Va~O!^8pO~P%;sO(p!sO~P$&YO#[8qO~O!_1qO~O!_1qO%j8sO~On8vO!_1qO%j8sO~O[8{O!]'ta!^'ta~O!]1|O!^)Wi~O!k9PO~O!k9QO~O!k9TO~O!k9TO~P%[Oa9VO~O!g9WO~O!k9XO~O!](xi!^(xi~P#BwOa%nO#`9aO'{%nO~O!](uy!k(uya(uy'{(uy~P!:tO!](kO!k(ty~O%j9dO~P&8tO!_'aO%j9dO~O#l$}qP$}qR$}q[$}qa$}qj$}qr$}q!S$}q!]$}q!l$}q!p$}q#R$}q#o$}q#p$}q#q$}q#r$}q#s$}q#t$}q#u$}q#v$}q#w$}q#y$}q#{$}q#|$}q'{$}q(b$}q(s$}q!k$}q!Y$}q'x$}q#`$}qv$}q!_$}q%j$}q!g$}q~P#/sO#l'kaP'kaR'ka['kaa'kaj'kar'ka!S'ka!l'ka!p'ka#R'ka#o'ka#p'ka#q'ka#r'ka#s'ka#t'ka#u'ka#v'ka#w'ka#y'ka#{'ka#|'ka'{'ka(b'ka(s'ka!k'ka!Y'ka'x'kav'ka!_'ka%j'ka!g'ka~P&5aO#l'maP'maR'ma['maa'maj'mar'ma!S'ma!l'ma!p'ma#R'ma#o'ma#p'ma#q'ma#r'ma#s'ma#t'ma#u'ma#v'ma#w'ma#y'ma#{'ma#|'ma'{'ma(b'ma(s'ma!k'ma!Y'ma'x'mav'ma!_'ma%j'ma!g'ma~P&6SO#l%PqP%PqR%Pq[%Pqa%Pqj%Pqr%Pq!S%Pq!]%Pq!l%Pq!p%Pq#R%Pq#o%Pq#p%Pq#q%Pq#r%Pq#s%Pq#t%Pq#u%Pq#v%Pq#w%Pq#y%Pq#{%Pq#|%Pq'{%Pq(b%Pq(s%Pq!k%Pq!Y%Pq'x%Pq#`%Pqv%Pq!_%Pq%j%Pq!g%Pq~P#/sO!]'Zi!k'Zi~P!:tO$P#cq!]#cq!^#cq~P#BwO(z$}OP%baR%ba[%baj%bar%ba!S%ba!l%ba!p%ba#R%ba#o%ba#p%ba#q%ba#r%ba#s%ba#t%ba#u%ba#v%ba#w%ba#y%ba#{%ba#|%ba$P%ba(b%ba(s%ba!]%ba!^%ba~On%ba!Q%ba'z%ba({%ba~P&JXO({%POP%daR%da[%daj%dar%da!S%da!l%da!p%da#R%da#o%da#p%da#q%da#r%da#s%da#t%da#u%da#v%da#w%da#y%da#{%da#|%da$P%da(b%da(s%da!]%da!^%da~On%da!Q%da'z%da(z%da~P&L`On>_O!Q*PO'z*QO({%PO~P&JXOn>_O!Q*PO'z*QO(z$}O~P&L`OR0mO!Q0mO!S0nO#S$dOP}a[}aj}an}ar}a!l}a!p}a#R}a#o}a#p}a#q}a#r}a#s}a#t}a#u}a#v}a#w}a#y}a#{}a#|}a$P}a'z}a(b}a(s}a(z}a({}a!]}a!^}a~O!Q*PO'z*QOP$taR$ta[$taj$tan$tar$ta!S$ta!l$ta!p$ta#R$ta#o$ta#p$ta#q$ta#r$ta#s$ta#t$ta#u$ta#v$ta#w$ta#y$ta#{$ta#|$ta$P$ta(b$ta(s$ta(z$ta({$ta!]$ta!^$ta~O!Q*PO'z*QOP$vaR$va[$vaj$van$var$va!S$va!l$va!p$va#R$va#o$va#p$va#q$va#r$va#s$va#t$va#u$va#v$va#w$va#y$va#{$va#|$va$P$va(b$va(s$va(z$va({$va!]$va!^$va~On>_O!Q*PO'z*QO(z$}O({%PO~OP%UaR%Ua[%Uaj%Uar%Ua!S%Ua!l%Ua!p%Ua#R%Ua#o%Ua#p%Ua#q%Ua#r%Ua#s%Ua#t%Ua#u%Ua#v%Ua#w%Ua#y%Ua#{%Ua#|%Ua$P%Ua(b%Ua(s%Ua!]%Ua!^%Ua~P''eO$P$nq!]$nq!^$nq~P#BwO$P$pq!]$pq!^$pq~P#BwO!^9qO~O$P9rO~P!1WO!g#vO!]'fi!k'fi~O!g#vO(s'qO!]'fi!k'fi~O!]/rO!k)Pq~O!Y'hi!]'hi~P#/sO!]/{O!Y)Qq~Or9yO!g#vO(s'qO~O[9{O!Y9zO~P#/sO!Y9zO~Oj:RO!g#vO~Og(`y!](`y~P!1WO!]'oa!_'oa~P#/sOa%]q!_%]q'{%]q!]%]q~P#/sO[:WO~O!]1VO!^)Yq~O`:[O~O#`:]O!]'qa!^'qa~O!]5wO!^)Vi~P#BwO!S:_O~O!_1qO%j:bO~O(WTO(ZUO(f:gO~O!]1|O!^)Wq~O!k:jO~O!k:kO~O!k:lO~O!k:lO~P%[O#`:oO!]#hy!^#hy~O!]#hy!^#hy~P#BwO%j:tO~P&8tO!_'aO%j:tO~O$P#}y!]#}y!^#}y~P#BwOP$}iR$}i[$}ij$}ir$}i!S$}i!l$}i!p$}i#R$}i#o$}i#p$}i#q$}i#r$}i#s$}i#t$}i#u$}i#v$}i#w$}i#y$}i#{$}i#|$}i$P$}i(b$}i(s$}i!]$}i!^$}i~P''eO!Q*PO'z*QO({%POP'jaR'ja['jaj'jan'jar'ja!S'ja!l'ja!p'ja#R'ja#o'ja#p'ja#q'ja#r'ja#s'ja#t'ja#u'ja#v'ja#w'ja#y'ja#{'ja#|'ja$P'ja(b'ja(s'ja(z'ja!]'ja!^'ja~O!Q*PO'z*QOP'laR'la['laj'lan'lar'la!S'la!l'la!p'la#R'la#o'la#p'la#q'la#r'la#s'la#t'la#u'la#v'la#w'la#y'la#{'la#|'la$P'la(b'la(s'la(z'la({'la!]'la!^'la~O(z$}OP%biR%bi[%bij%bin%bir%bi!Q%bi!S%bi!l%bi!p%bi#R%bi#o%bi#p%bi#q%bi#r%bi#s%bi#t%bi#u%bi#v%bi#w%bi#y%bi#{%bi#|%bi$P%bi'z%bi(b%bi(s%bi({%bi!]%bi!^%bi~O({%POP%diR%di[%dij%din%dir%di!Q%di!S%di!l%di!p%di#R%di#o%di#p%di#q%di#r%di#s%di#t%di#u%di#v%di#w%di#y%di#{%di#|%di$P%di'z%di(b%di(s%di(z%di!]%di!^%di~O$P$py!]$py!^$py~P#BwO$P#cy!]#cy!^#cy~P#BwO!g#vO!]'fq!k'fq~O!]/rO!k)Py~O!Y'hq!]'hq~P#/sOr;OO!g#vO(s'qO~O[;SO!Y;RO~P#/sO!Y;RO~Og(`!R!](`!R~P!1WOa%]y!_%]y'{%]y!]%]y~P#/sO!]1VO!^)Yy~O!]5wO!^)Vq~O(U;ZO~O!_1qO%j;^O~O!k;aO~O%j;fO~P&8tOP$}qR$}q[$}qj$}qr$}q!S$}q!l$}q!p$}q#R$}q#o$}q#p$}q#q$}q#r$}q#s$}q#t$}q#u$}q#v$}q#w$}q#y$}q#{$}q#|$}q$P$}q(b$}q(s$}q!]$}q!^$}q~P''eO!Q*PO'z*QO({%POP'kaR'ka['kaj'kan'kar'ka!S'ka!l'ka!p'ka#R'ka#o'ka#p'ka#q'ka#r'ka#s'ka#t'ka#u'ka#v'ka#w'ka#y'ka#{'ka#|'ka$P'ka(b'ka(s'ka(z'ka!]'ka!^'ka~O!Q*PO'z*QOP'maR'ma['maj'man'mar'ma!S'ma!l'ma!p'ma#R'ma#o'ma#p'ma#q'ma#r'ma#s'ma#t'ma#u'ma#v'ma#w'ma#y'ma#{'ma#|'ma$P'ma(b'ma(s'ma(z'ma({'ma!]'ma!^'ma~OP%PqR%Pq[%Pqj%Pqr%Pq!S%Pq!l%Pq!p%Pq#R%Pq#o%Pq#p%Pq#q%Pq#r%Pq#s%Pq#t%Pq#u%Pq#v%Pq#w%Pq#y%Pq#{%Pq#|%Pq$P%Pq(b%Pq(s%Pq!]%Pq!^%Pq~P''eOg%f!Z!]%f!Z#`%f!Z$P%f!Z~P!1WO!Y;jO~P#/sOr;kO!g#vO(s'qO~O[;mO!Y;jO~P#/sO!]'qq!^'qq~P#BwO!]#h!Z!^#h!Z~P#BwO#l%f!ZP%f!ZR%f!Z[%f!Za%f!Zj%f!Zr%f!Z!S%f!Z!]%f!Z!l%f!Z!p%f!Z#R%f!Z#o%f!Z#p%f!Z#q%f!Z#r%f!Z#s%f!Z#t%f!Z#u%f!Z#v%f!Z#w%f!Z#y%f!Z#{%f!Z#|%f!Z'{%f!Z(b%f!Z(s%f!Z!k%f!Z!Y%f!Z'x%f!Z#`%f!Zv%f!Z!_%f!Z%j%f!Z!g%f!Z~P#/sOr;vO!g#vO(s'qO~O!Y;wO~P#/sOr<OO!g#vO(s'qO~O!Y<PO~P#/sOP%f!ZR%f!Z[%f!Zj%f!Zr%f!Z!S%f!Z!l%f!Z!p%f!Z#R%f!Z#o%f!Z#p%f!Z#q%f!Z#r%f!Z#s%f!Z#t%f!Z#u%f!Z#v%f!Z#w%f!Z#y%f!Z#{%f!Z#|%f!Z$P%f!Z(b%f!Z(s%f!Z!]%f!Z!^%f!Z~P''eOr<SO!g#vO(s'qO~Ov(gX~P1qO!Q%rO~P!)[O(V!lO~P!)[O!YfX!]fX#`fX~P%2^OP]XR]X[]Xj]Xr]X!Q]X!S]X!]]X!]fX!l]X!p]X#R]X#S]X#`]X#`fX#lfX#o]X#p]X#q]X#r]X#s]X#t]X#u]X#v]X#w]X#y]X#{]X#|]X$R]X(b]X(s]X(z]X({]X~O!gfX!k]X!kfX(sfX~P'LcOP<WOQ<WOSfOd>SOe!iOpkOr<WOskOtkOzkO|<WO!O<WO!SWO!WkO!XkO!_XO!i<ZO!lZO!o<WO!p<WO!q<WO!s<[O!u<_O!x!hO$X!kO$o>QO(U)^O(WTO(ZUO(bVO(p[O~O!]<kO!^$ra~Oh%VOp%WOr%XOs$tOt$tOz%YO|%ZO!O<vO!S${O!_$|O!i>XO!l$xO#k<|O$X%`O$u<xO$w<zO$z%aO(U(wO(WTO(ZUO(b$uO(z$}O({%PO~Ol)eO~P(#XOr!eX(s!eX~P#!nO!^]X!^fX~P'LcO!YfX!Y${X!]fX!]${X#`fX~P!0SO#l<`O~O!g#vO#l<`O~O#`<pO~Oj<dO~O#`=PO!](xX!^(xX~O#`<pO!](vX!^(vX~O#l=QO~Og=SO~P!1WO#l=YO~O#l=ZO~Og=SO(U&ZO~O!g#vO#l=[O~O!g#vO#l=QO~O$P=]O~P#BwO#l=^O~O#l=_O~O#l=dO~O#l=eO~O#l=fO~O#l=gO~O$P=hO~P!1WO$P=iO~P!1WOl=tO~P7eOk#S#T#U#W#X#[#j#k#v$o$u$w$z%^%_%i%j%k%r%t%w%x%z%|~(PT#p!X'}(V#qs#o#rr!Q(O$^(U$`(f~",goto:"$9_)^PPPPPP)_PP)bP)sP+X/^PPPP6lPP7SPP=PPPP@sPA]PA]PPPA]PCePA]PA]PA]PCiPCnPD]PIVPPPIZPPPPIZL^PPPLdMUPIZPIZPP! dIZPPPIZPIZP!#kIZP!'R!(W!(aP!)T!)X!)T!,fPPPPPPP!-V!(WPP!-g!/XP!2hIZIZ!2m!5y!:g!:g!>f!>nPPP!>tIZPPPPPPPPP!BTP!CbPPIZ!DsPIZPIZIZIZIZIZPIZ!FVP!IaP!LgP!Lk!Lu!Ly!LyP!I^P!L}!L}P#!TP#!XIZPIZ#!_#%dCiA]PA]PA]A]P#&qA]A]#)TA]#+{A]#.XA]A]#.w#1]#1]#1b#1k#1]#1vPP#1]PA]#2`A]#6_A]A]6lPPP#:dPPP#:}#:}P#:}P#;e#:}PP#;kP#;bP#;b#<O#;b#<j#<p#<s)bP#<v)bP#=P#=P#=PP)bP)bP)bP)bPP)bP#=V#=YP#=Y)bP#=^P#=aP)bP)bP)bP)bP)bP)b)bPP#=g#=m#=x#>O#>U#>[#>b#>p#>v#?Q#?W#?b#?h#?x#@O#@p#AS#AY#A`#An#BT#Cx#DW#D_#Ey#FX#Gy#HX#H_#He#Hk#Hu#H{#IR#I]#Io#IuPPPPPPPPPPP#I{PPPPPPP#Jp#M}$ g$ n$ vPPP$'bP$'k$*d$0}$1Q$1T$2S$2V$2^$2fP$2l$2oP$3]$3a$4X$5g$5l$6SPP$6X$6_$6c$6f$6j$6n$7j$8R$8j$8n$8q$8t$9O$9R$9V$9ZR!|RoqOXst!Z#d%m&r&t&u&w,u,z2^2aY!vQ'a-g1q5}Q%tvQ%|yQ&T|Q&j!VS'W!e-^Q'g!iS'm!r!yU*l$|*[*pQ+q%}S,O&V&WQ,f&dQ-e'`Q-o'hQ-w'nQ0^*rQ1d,QQ1{,gR<}<[%SdOPWXYZstuvw!Z!`!g!o#S#W#Z#d#o#u#x#{$O$P$Q$R$S$T$U$V$W$X$_$a$e%m%t&R&k&n&r&t&u&w&{'T'c's(U(W(^(e(y({)P*O*j+Y+_,r,u,z-k-s.R.X.v.}/p0_0n0t1U1t2U2V2X2Z2^2a2c3S3Y3n4|6V6g6h6k7O8v9V9aS#q]<X!r)`$Z$n'X)t-Y-a/X2q4V5y6u:]:o<W<Z<[<_<`<a<b<c<d<e<f<g<h<i<j<k<m<p<}=P=Q=S=[=]=f=g>TU+Q%]<u<vQ+v&PQ,h&gQ,o&oQ0z+iQ1P+kQ1[+wQ2T,mQ3b.iQ5b1OQ5h1VQ6^1|Q7[3fQ8b5iR9g7^'QkOPWXYZstuvw!Z!`!g!o#S#W#Z#d#o#u#x#{$O$P$Q$R$S$T$U$V$W$X$Z$_$a$e$n%m%t&R&k&n&o&r&t&u&w&{'T'X'c's(U(W(^(e(y({)P)t*O*j+Y+_+i,r,u,z-Y-a-k-s.R.X.i.v.}/X/p0_0n0t1U1t2U2V2X2Z2^2a2c2q3S3Y3f3n4V4|5y6V6g6h6k6u7O7^8v9V9a:]:o<W<Z<[<_<`<a<b<c<d<e<f<g<h<i<j<k<m<p<}=P=Q=S=[=]=f=g>T!S!nQ!r!v!y!z$|'W'`'a'm'n'o*l*p*r*s-^-e-g-w0^0a1q5}6P%[$ti#v$b$c$d$x${%O%Q%^%_%c)z*S*U*W*Z*b*h*x*y+h+k,U,X.h/R/f/o/z/{/}0b0d0k0l0q1h1k1s3e4`4a4l4q5S5^5a6U7Y7x8S8X8^8s9d9r9{:R:b:t;S;^;f;m<n<o<q<r<s<t<w<x<y<z<{<|=T=U=V=W=Y=Z=^=_=`=a=b=c=d=e=h=i>Q>Y>Z>^>_Q&X|S'U!e*[S']%i-bQ+v&PQ,R&WQ,h&gQ0p+TQ1[+wQ1a+}Q2S,lQ2T,mQ5h1VQ5q1cQ6^1|Q6a2OQ6b2RQ8b5iQ8e5nQ9O6dQ:Z8fQ:h8{R;X:[rnOXst!V!Z#d%m&i&r&t&u&w,u,z2^2aR,j&k&z^OPXYstuvwz!Z!`!g!j!o#S#d#o#u#x#{$O$P$Q$R$S$T$U$V$W$X$Z$_$a$e$n%m%t&R&k&n&o&r&t&u&w&{'T'c's(W(^(e(y({)P)t*O*j+Y+_+i,r,u,z-Y-a-k-s.R.X.i.v.}/X/p0_0n0t1U1t2U2V2X2Z2^2a2c2q3S3Y3f3n4V4|5y6V6g6h6k6u7O7^8v9V9a:]:o<W<Z<[<_<`<a<b<c<d<e<f<g<h<i<j<k<m<p<}=P=Q=S=[=]=f=g>S>T[#]WZ#W#Z'X(U!b%jm#h#i#l$x%e%h(_(i(j(k*Z*_*c+[+^+`,q-W.V.].^._.a/o/r2f3^3_4c6t7VQ%wxQ%{yW&Q|&V&W,QQ&_!TQ'd!hQ'f!iQ(r#sS+p%|%}Q+t&PQ,a&bQ,e&dS-n'g'hQ.k(sQ1T+qQ1Z+wQ1]+xQ1`+|Q1v,bS1z,f,gQ3O-oQ5g1VQ5k1YQ5p1bQ6]1{Q8a5iQ8d5mQ8h5rQ:V8`R;V:W!U$zi$d%O%Q%^%_%c*S*U*b*x*y/R/z0b0d0k0l0q4a5S8X9r>Q>Y>Z!^%yy!i!u%{%|%}'V'f'g'h'l'v*k+p+q-Z-n-o-v0T0W1T2w3O3V4t4u4x8P9}Q+j%wQ,V&[Q,Y&]Q,d&dQ.j(rQ1u,aU1y,e,f,gQ3g.kQ6W1vS6[1z1{Q8z6]#f>U#v$b$c$x${)z*W*Z*h+h+k,U,X.h/f/o/{/}1h1k1s3e4`4l4q5^5a6U7Y7x8S8^8s9d9{:R:b:t;S;^;f;m<q<s<w<y<{=T=V=Y=^=`=b=d=h>^>_o>V<n<o<r<t<x<z<|=U=W=Z=_=a=c=e=iW%Ti%V*z>QS&[!Q&iQ&]!RQ&^!SU+O%[%d=tR,T&Y%]%Si#v$b$c$d$x${%O%Q%^%_%c)z*S*U*W*Z*b*h*x*y+h+k,U,X.h/R/f/o/z/{/}0b0d0k0l0q1h1k1s3e4`4a4l4q5S5^5a6U7Y7x8S8X8^8s9d9r9{:R:b:t;S;^;f;m<n<o<q<r<s<t<w<x<y<z<{<|=T=U=V=W=Y=Z=^=_=`=a=b=c=d=e=h=i>Q>Y>Z>^>_T){$u)|V+Q%]<u<vW']!e%i*[-bS)O#y#zQ+e%rQ+{&SS.d(n(oQ1l,ZQ5V0mR8k5w'QkOPWXYZstuvw!Z!`!g!o#S#W#Z#d#o#u#x#{$O$P$Q$R$S$T$U$V$W$X$Z$_$a$e$n%m%t&R&k&n&o&r&t&u&w&{'T'X'c's(U(W(^(e(y({)P)t*O*j+Y+_+i,r,u,z-Y-a-k-s.R.X.i.v.}/X/p0_0n0t1U1t2U2V2X2Z2^2a2c2q3S3Y3f3n4V4|5y6V6g6h6k6u7O7^8v9V9a:]:o<W<Z<[<_<`<a<b<c<d<e<f<g<h<i<j<k<m<p<}=P=Q=S=[=]=f=g>T$i$^c#Y#e%q%s%u(T(Z(u(z)S)T)U)V)W)X)Y)Z)[)])_)a)c)h)r+f+z-[-z.P.U.W.u.x.|/O/P/Q/d0r2o2t3Q3X3m3r3s3t3u3v3w3x3y3z3{3|3}4O4R4S4Z5Z5e6w6}7S7c7d7m7n8m9Z9_9i9o9p:q;Y;b<Y=wT#TV#U'RkOPWXYZstuvw!Z!`!g!o#S#W#Z#d#o#u#x#{$O$P$Q$R$S$T$U$V$W$X$Z$_$a$e$n%m%t&R&k&n&o&r&t&u&w&{'T'X'c's(U(W(^(e(y({)P)t*O*j+Y+_+i,r,u,z-Y-a-k-s.R.X.i.v.}/X/p0_0n0t1U1t2U2V2X2Z2^2a2c2q3S3Y3f3n4V4|5y6V6g6h6k6u7O7^8v9V9a:]:o<W<Z<[<_<`<a<b<c<d<e<f<g<h<i<j<k<m<p<}=P=Q=S=[=]=f=g>TQ'Y!eR2r-^!W!nQ!e!r!v!y!z$|'W'`'a'm'n'o*[*l*p*r*s-^-e-g-w0^0a1q5}6PR1n,]nqOXst!Z#d%m&r&t&u&w,u,z2^2aQ&y!^Q'w!xS(t#u<`Q+n%zQ,_&_Q,`&aQ-l'eQ-y'pS.t(y=QS0s+Y=[Q1R+oQ1p,^Q2e,|Q2g,}Q2n-XQ2|-mQ3P-qS5[0t=fQ5c1SS5f1U=gQ6v2pQ6z2}Q7P3UQ8_5dQ9[6xQ9]6{Q9`7QR:n9X$d$]c#Y#e%s%u(T(Z(u(z)S)T)U)V)W)X)Y)Z)[)])_)a)c)h)r+f+z-[-z.P.U.W.u.x.|/P/Q/d0r2o2t3Q3X3m3r3s3t3u3v3w3x3y3z3{3|3}4O4R4S4Z5Z5e6w6}7S7c7d7m7n8m9Z9_9i9o9p:q;Y;b<Y=wS(p#p'jQ)Q#zS+d%q/OS.e(o(qR3`.f'QkOPWXYZstuvw!Z!`!g!o#S#W#Z#d#o#u#x#{$O$P$Q$R$S$T$U$V$W$X$Z$_$a$e$n%m%t&R&k&n&o&r&t&u&w&{'T'X'c's(U(W(^(e(y({)P)t*O*j+Y+_+i,r,u,z-Y-a-k-s.R.X.i.v.}/X/p0_0n0t1U1t2U2V2X2Z2^2a2c2q3S3Y3f3n4V4|5y6V6g6h6k6u7O7^8v9V9a:]:o<W<Z<[<_<`<a<b<c<d<e<f<g<h<i<j<k<m<p<}=P=Q=S=[=]=f=g>TS#q]<XQ&t!XQ&u!YQ&w![Q&x!]R2],xQ'b!hQ+g%wQ-j'dS.g(r+jQ2z-iW3d.j.k0y0{Q6y2{W7W3a3c3g5`U9c7X7Z7]U:s9e9f9hS;d:r:uQ;r;eR;z;sU!wQ'a-gT5{1q5}!Q_OXZ`st!V!Z#d#h%e%m&i&k&r&t&u&w(k,u,z.^2^2a]!pQ!r'a-g1q5}T#q]<X%^{OPWXYZstuvw!Z!`!g!o#S#W#Z#d#o#u#x#{$O$P$Q$R$S$T$U$V$W$X$_$a$e%m%t&R&k&n&o&r&t&u&w&{'T'c's(U(W(^(e(y({)P*O*j+Y+_+i,r,u,z-k-s.R.X.i.v.}/p0_0n0t1U1t2U2V2X2Z2^2a2c3S3Y3f3n4|6V6g6h6k7O7^8v9V9aS)O#y#zS.d(n(o!s=m$Z$n'X)t-Y-a/X2q4V5y6u:]:o<W<Z<[<_<`<a<b<c<d<e<f<g<h<i<j<k<m<p<}=P=Q=S=[=]=f=g>TU$fd)`,oS(q#p'jU*w%R(x4QU0o+P.p7iQ5`0zQ7X3bQ9f7[R:u9gm!tQ!r!v!y!z'a'm'n'o-g-w1q5}6PQ'u!uS(g#g2WS-u'l'xQ/u*^Q0T*kQ3W-xQ4h/vQ4t0VQ4u0WQ4z0`Q7t4bS8P4v4xS8T4{4}Q9t7uQ9x7{Q9}8QQ:S8VS:}9y9zS;i;O;RS;u;j;kS;};v;wS<R<O<PR<U<SQ#wbQ't!uS(f#g2WS(h#m+XQ+Z%fQ+l%xQ+r&OU-t'l'u'xQ.Y(gU/t*^*a/yQ0U*kQ0X*mQ1Q+mQ1w,cS3T-u-xQ3].bS4g/u/vQ4p0RS4s0T0`Q4w0YQ6Y1xQ7R3WS7s4b4dQ7w4hU8O4t4z4}Q8R4yQ8x6ZS9s7t7uQ9w7{Q:P8TQ:Q8UQ:e8yQ:{9tS:|9x9zQ;U:SQ;`:fS;h:};RS;t;i;jS;|;u;wS<Q;}<PQ<T<RQ<V<UQ=p=kQ=|=uR=}=vV!wQ'a-g%^aOPWXYZstuvw!Z!`!g!o#S#W#Z#d#o#u#x#{$O$P$Q$R$S$T$U$V$W$X$_$a$e%m%t&R&k&n&o&r&t&u&w&{'T'c's(U(W(^(e(y({)P*O*j+Y+_+i,r,u,z-k-s.R.X.i.v.}/p0_0n0t1U1t2U2V2X2Z2^2a2c3S3Y3f3n4|6V6g6h6k7O7^8v9V9aS#wz!j!r=j$Z$n'X)t-Y-a/X2q4V5y6u:]:o<W<Z<[<_<`<a<b<c<d<e<f<g<h<i<j<k<m<p<}=P=Q=S=[=]=f=g>TR=p>S%^bOPWXYZstuvw!Z!`!g!o#S#W#Z#d#o#u#x#{$O$P$Q$R$S$T$U$V$W$X$_$a$e%m%t&R&k&n&o&r&t&u&w&{'T'c's(U(W(^(e(y({)P*O*j+Y+_+i,r,u,z-k-s.R.X.i.v.}/p0_0n0t1U1t2U2V2X2Z2^2a2c3S3Y3f3n4|6V6g6h6k7O7^8v9V9aQ%fj!^%xy!i!u%{%|%}'V'f'g'h'l'v*k+p+q-Z-n-o-v0T0W1T2w3O3V4t4u4x8P9}S&Oz!jQ+m%yQ,c&dW1x,d,e,f,gU6Z1y1z1{S8y6[6]Q:f8z!r=k$Z$n'X)t-Y-a/X2q4V5y6u:]:o<W<Z<[<_<`<a<b<c<d<e<f<g<h<i<j<k<m<p<}=P=Q=S=[=]=f=g>TQ=u>RR=v>S%QeOPXYstuvw!Z!`!g!o#S#d#o#u#x#{$O$P$Q$R$S$T$U$V$W$X$_$a$e%m%t&R&k&n&r&t&u&w&{'T'c's(W(^(e(y({)P*O*j+Y+_+i,r,u,z-k-s.R.X.i.v.}/p0_0n0t1U1t2U2V2X2Z2^2a2c3S3Y3f3n4|6V6g6h6k7O7^8v9V9aY#bWZ#W#Z(U!b%jm#h#i#l$x%e%h(_(i(j(k*Z*_*c+[+^+`,q-W.V.].^._.a/o/r2f3^3_4c6t7VQ,p&o!p=l$Z$n)t-Y-a/X2q4V5y6u:]:o<W<Z<[<_<`<a<b<c<d<e<f<g<h<i<j<k<m<p<}=P=Q=S=[=]=f=g>TR=o'XU'^!e%i*[R2u-bX'[!e%i*[-b%SdOPWXYZstuvw!Z!`!g!o#S#W#Z#d#o#u#x#{$O$P$Q$R$S$T$U$V$W$X$_$a$e%m%t&R&k&n&r&t&u&w&{'T'c's(U(W(^(e(y({)P*O*j+Y+_,r,u,z-k-s.R.X.v.}/p0_0n0t1U1t2U2V2X2Z2^2a2c3S3Y3n4|6V6g6h6k7O8v9V9a!r)`$Z$n'X)t-Y-a/X2q4V5y6u:]:o<W<Z<[<_<`<a<b<c<d<e<f<g<h<i<j<k<m<p<}=P=Q=S=[=]=f=g>TQ,o&oQ0z+iQ3b.iQ7[3fR9g7^!b$Tc#Y%q(T(Z(u(z)[)])a)h+z-z.P.U.W.u.x/d0r3Q3X3m3}5Z5e6}7S7c9_:q<Y!P<f)_)r-[/O2o2t3r3{3|4R4Z6w7d7m7n8m9Z9i9o9p;Y;b=w!f$Vc#Y%q(T(Z(u(z)X)Y)[)])a)h+z-z.P.U.W.u.x/d0r3Q3X3m3}5Z5e6}7S7c9_:q<Y!T<h)_)r-[/O2o2t3r3x3y3{3|4R4Z6w7d7m7n8m9Z9i9o9p;Y;b=w!^$Zc#Y%q(T(Z(u(z)a)h+z-z.P.U.W.u.x/d0r3Q3X3m3}5Z5e6}7S7c9_:q<YQ4a/mz>T)_)r-[/O2o2t3r4R4Z6w7d7m7n8m9Z9i9o9p;Y;b=wQ>Y>[R>Z>]'QkOPWXYZstuvw!Z!`!g!o#S#W#Z#d#o#u#x#{$O$P$Q$R$S$T$U$V$W$X$Z$_$a$e$n%m%t&R&k&n&o&r&t&u&w&{'T'X'c's(U(W(^(e(y({)P)t*O*j+Y+_+i,r,u,z-Y-a-k-s.R.X.i.v.}/X/p0_0n0t1U1t2U2V2X2Z2^2a2c2q3S3Y3f3n4V4|5y6V6g6h6k6u7O7^8v9V9a:]:o<W<Z<[<_<`<a<b<c<d<e<f<g<h<i<j<k<m<p<}=P=Q=S=[=]=f=g>TS$oh$pR4W/W'XgOPWXYZhstuvw!Z!`!g!o#S#W#Z#d#o#u#x#{$O$P$Q$R$S$T$U$V$W$X$Z$_$a$e$n$p%m%t&R&k&n&o&r&t&u&w&{'T'X'c's(U(W(^(e(y({)P)t*O*j+Y+_+i,r,u,z-Y-a-k-s.R.X.i.v.}/W/X/p0_0n0t1U1t2U2V2X2Z2^2a2c2q3S3Y3f3n4V4|5y6V6g6h6k6u7O7^8v9V9a:]:o<W<Z<[<_<`<a<b<c<d<e<f<g<h<i<j<k<m<p<}=P=Q=S=[=]=f=g>TT$kf$qQ$ifS)k$l)oR)w$qT$jf$qT)m$l)o'XhOPWXYZhstuvw!Z!`!g!o#S#W#Z#d#o#u#x#{$O$P$Q$R$S$T$U$V$W$X$Z$_$a$e$n$p%m%t&R&k&n&o&r&t&u&w&{'T'X'c's(U(W(^(e(y({)P)t*O*j+Y+_+i,r,u,z-Y-a-k-s.R.X.i.v.}/W/X/p0_0n0t1U1t2U2V2X2Z2^2a2c2q3S3Y3f3n4V4|5y6V6g6h6k6u7O7^8v9V9a:]:o<W<Z<[<_<`<a<b<c<d<e<f<g<h<i<j<k<m<p<}=P=Q=S=[=]=f=g>TT$oh$pQ$rhR)v$p%^jOPWXYZstuvw!Z!`!g!o#S#W#Z#d#o#u#x#{$O$P$Q$R$S$T$U$V$W$X$_$a$e%m%t&R&k&n&o&r&t&u&w&{'T'c's(U(W(^(e(y({)P*O*j+Y+_+i,r,u,z-k-s.R.X.i.v.}/p0_0n0t1U1t2U2V2X2Z2^2a2c3S3Y3f3n4|6V6g6h6k7O7^8v9V9a!s>R$Z$n'X)t-Y-a/X2q4V5y6u:]:o<W<Z<[<_<`<a<b<c<d<e<f<g<h<i<j<k<m<p<}=P=Q=S=[=]=f=g>T#glOPXZst!Z!`!o#S#d#o#{$n%m&k&n&o&r&t&u&w&{'T'c)P)t*j+_+i,r,u,z-k.i/X/p0_0n1t2U2V2X2Z2^2a2c3f4V4|6V6g6h6k7^8v9V!U%Ri$d%O%Q%^%_%c*S*U*b*x*y/R/z0b0d0k0l0q4a5S8X9r>Q>Y>Z#f(x#v$b$c$x${)z*W*Z*h+h+k,U,X.h/f/o/{/}1h1k1s3e4`4l4q5^5a6U7Y7x8S8^8s9d9{:R:b:t;S;^;f;m<q<s<w<y<{=T=V=Y=^=`=b=d=h>^>_Q+U%aQ/e*Po4Q<n<o<r<t<x<z<|=U=W=Z=_=a=c=e=i!U$yi$d%O%Q%^%_%c*S*U*b*x*y/R/z0b0d0k0l0q4a5S8X9r>Q>Y>ZQ*d$zU*m$|*[*pQ+V%bQ0Y*n#f=r#v$b$c$x${)z*W*Z*h+h+k,U,X.h/f/o/{/}1h1k1s3e4`4l4q5^5a6U7Y7x8S8^8s9d9{:R:b:t;S;^;f;m<q<s<w<y<{=T=V=Y=^=`=b=d=h>^>_n=s<n<o<r<t<x<z<|=U=W=Z=_=a=c=e=iQ=x>UQ=y>VQ=z>WR={>X!U%Ri$d%O%Q%^%_%c*S*U*b*x*y/R/z0b0d0k0l0q4a5S8X9r>Q>Y>Z#f(x#v$b$c$x${)z*W*Z*h+h+k,U,X.h/f/o/{/}1h1k1s3e4`4l4q5^5a6U7Y7x8S8^8s9d9{:R:b:t;S;^;f;m<q<s<w<y<{=T=V=Y=^=`=b=d=h>^>_o4Q<n<o<r<t<x<z<|=U=W=Z=_=a=c=e=inoOXst!Z#d%m&r&t&u&w,u,z2^2aS*g${*ZQ-T'OQ-U'QR4k/{%[%Si#v$b$c$d$x${%O%Q%^%_%c)z*S*U*W*Z*b*h*x*y+h+k,U,X.h/R/f/o/z/{/}0b0d0k0l0q1h1k1s3e4`4a4l4q5S5^5a6U7Y7x8S8X8^8s9d9r9{:R:b:t;S;^;f;m<n<o<q<r<s<t<w<x<y<z<{<|=T=U=V=W=Y=Z=^=_=`=a=b=c=d=e=h=i>Q>Y>Z>^>_Q,W&]Q1j,YQ5u1iR8j5vV*o$|*[*pU*o$|*[*pT5|1q5}S0R*j/pQ4y0_T8U4|:_Q+l%xQ0X*mQ1Q+mQ1w,cQ6Y1xQ8x6ZQ:e8yR;`:f!U%Oi$d%O%Q%^%_%c*S*U*b*x*y/R/z0b0d0k0l0q4a5S8X9r>Q>Y>Zx*S$v)f*T*v+W/x0f0g4T4i5T5U5Y7r8W:T:z=q>O>PS0b*u0c#f<q#v$b$c$x${)z*W*Z*h+h+k,U,X.h/f/o/{/}1h1k1s3e4`4l4q5^5a6U7Y7x8S8^8s9d9{:R:b:t;S;^;f;m<q<s<w<y<{=T=V=Y=^=`=b=d=h>^>_n<r<n<o<r<t<x<z<|=U=W=Z=_=a=c=e=i!d=T(v)d*]*f.l.o.s/a/m0O0x1g3j4^4j4n5t7_7b7y7|8Z8]9v:O:U;P;T;g;l;x>[>]`=U4P7e7h7l9j:v:y;{S=`.n3kT=a7g9m!U%Qi$d%O%Q%^%_%c*S*U*b*x*y/R/z0b0d0k0l0q4a5S8X9r>Q>Y>Z|*U$v)f*V*u+W/i/x0f0g4T4i5O5T5U5Y7r8W:T:z=q>O>PS0d*v0e#f<s#v$b$c$x${)z*W*Z*h+h+k,U,X.h/f/o/{/}1h1k1s3e4`4l4q5^5a6U7Y7x8S8^8s9d9{:R:b:t;S;^;f;m<q<s<w<y<{=T=V=Y=^=`=b=d=h>^>_n<t<n<o<r<t<x<z<|=U=W=Z=_=a=c=e=i!h=V(v)d*]*f.m.n.s/a/m0O0x1g3h3j4^4j4n5t7_7`7b7y7|8Z8]9v:O:U;P;T;g;l;x>[>]d=W4P7f7g7l9j9k:v:w:y;{S=b.o3lT=c7h9nrnOXst!V!Z#d%m&i&r&t&u&w,u,z2^2aQ&f!UR,r&ornOXst!V!Z#d%m&i&r&t&u&w,u,z2^2aR&f!UQ,[&^R1f,TsnOXst!V!Z#d%m&i&r&t&u&w,u,z2^2aQ1r,aS6T1u1vU8r6R6S6WS:a8t8uS;[:`:cQ;o;]R;y;pQ&m!VR,k&iR6a2OR:h8{W&Q|&V&W,QR1]+xQ&r!WR,u&sR,{&xT2_,z2aR-P&yQ-O&yR2h-PQ'z!{R-{'zSsOtQ#dXT%ps#dQ#OTR'|#OQ#RUR(O#RQ)|$uR/b)|Q#UVR(R#UQ#XWU(X#X(Y.SQ(Y#YR.S(ZQ-_'YR2s-_Q.w(zS3o.w3pR3p.xQ-g'aR2x-gY!rQ'a-g1q5}R'k!rQ/S)fR4U/SU#_W%h*ZU(`#_(a.TQ(a#`R.T([Q-c'^R2v-ct`OXst!V!Z#d%m&i&k&r&t&u&w,u,z2^2aS#hZ%eU#r`#h.^R.^(kQ(l#jQ.Z(hW.c(l.Z3Z7TQ3Z.[R7T3[Q)o$lR/Y)oQ$phR)u$pQ$`cU)b$`.O<lQ.O<YR<l)rQ/s*^W4e/s4f7v9uU4f/t/u/vS7v4g4hR9u7w$e*R$v(v)d)f*]*f*u*v+R+S+W.n.o.q.r.s/a/i/k/m/x0O0f0g0x1g3h3i3j4P4T4^4i4j4n5O5Q5T5U5Y5t7_7`7a7b7g7h7j7k7l7r7y7|8W8Z8]9j9k9l9v:O:T:U:v:w:x:y:z;P;T;g;l;x;{=q>O>P>[>]Q/|*fU4m/|4o7zQ4o0OR7z4nS*p$|*[R0[*px*T$v)f*u*v+W/x0f0g4T4i5T5U5Y7r8W:T:z=q>O>P!d.l(v)d*]*f.n.o.s/a/m0O0x1g3j4^4j4n5t7_7b7y7|8Z8]9v:O:U;P;T;g;l;x>[>]U/j*T.l7ea7e4P7g7h7l9j:v:y;{Q0c*uQ3k.nU5P0c3k9mR9m7g|*V$v)f*u*v+W/i/x0f0g4T4i5O5T5U5Y7r8W:T:z=q>O>P!h.m(v)d*]*f.n.o.s/a/m0O0x1g3h3j4^4j4n5t7_7`7b7y7|8Z8]9v:O:U;P;T;g;l;x>[>]U/l*V.m7fe7f4P7g7h7l9j9k:v:w:y;{Q0e*vQ3l.oU5R0e3l9nR9n7hQ*{%UR0i*{Q5_0xR8[5_Q+a%kR0w+aQ5x1lS8l5x:^R:^8mQ,^&_R1o,^Q5}1qR8o5}Q1},hS6_1}8|R8|6aQ1W+tW5j1W5l8c:XQ5l1ZQ8c5kR:X8dQ+y&QR1^+yQ2a,zR6o2aYrOXst#dQ&v!ZQ+c%mQ,t&rQ,v&tQ,w&uQ,y&wQ2[,uS2_,z2aR6n2^Q%opQ&z!_Q&}!aQ'P!bQ'R!cQ'r!uQ+b%lQ+n%zQ,S&XQ,j&mQ-R&|W-r'l't'u'xQ-y'pQ0Z*oQ1R+oQ1e,RS2Q,k,nQ2i-QQ2j-TQ2k-UQ3P-qW3R-t-u-x-zQ5c1SQ5o1aQ5s1gQ6X1wQ6c2SQ6m2]U6|3Q3T3WQ7P3UQ8_5dQ8g5qQ8i5tQ8n5|Q8w6YQ8}6bS9^6}7RQ9`7QQ:Y8eQ:d8xQ:i9OQ:p9_Q;W:ZQ;_:eQ;c:qQ;n;XR;q;`Q%zyQ'e!iQ'p!uU+o%{%|%}Q-X'VU-m'f'g'hS-q'l'vQ0S*kS1S+p+qQ2p-ZS2}-n-oQ3U-vS4r0T0WQ5d1TQ6x2wQ6{3OQ7Q3VU7}4t4u4xQ9|8PR;Q9}S$wi>QR*|%VU%Ui%V>QR0h*zQ$viS(v#v+kS)d$b$cQ)f$dQ*]$xS*f${*ZQ*u%OQ*v%QQ+R%^Q+S%_Q+W%cQ.n<qQ.o<sQ.q<wQ.r<yQ.s<{Q/a)zQ/i*SQ/k*UQ/m*WQ/x*bS0O*h/oQ0f*xQ0g*yl0x+h,X.h1k1s3e6U7Y8s9d:b:t;^;fQ1g,UQ3h=TQ3i=VQ3j=YS4P<n<oQ4T/RS4^/f4`Q4i/zQ4j/{Q4n/}Q5O0bQ5Q0dQ5T0kQ5U0lQ5Y0qQ5t1hQ7_=^Q7`=`Q7a=bQ7b=dQ7g<rQ7h<tQ7j<xQ7k<zQ7l<|Q7r4aQ7y4lQ7|4qQ8W5SQ8Z5^Q8]5aQ9j=ZQ9k=UQ9l=WQ9v7xQ:O8SQ:T8XQ:U8^Q:v=_Q:w=aQ:x=cQ:y=eQ:z9rQ;P9{Q;T:RQ;g=hQ;l;SQ;x;mQ;{=iQ=q>QQ>O>YQ>P>ZQ>[>^R>]>_Q+P%]Q.p<uR7i<vnpOXst!Z#d%m&r&t&u&w,u,z2^2aQ!fPS#fZ#oQ&|!`W'i!o*j0_4|Q(Q#SQ)R#{Q)s$nS,n&k&nQ,s&oQ-Q&{S-V'T/pQ-i'cQ.z)PQ/^)tQ0u+_Q0{+iQ2Y,rQ2{-kQ3c.iQ4Y/XQ5W0nQ6S1tQ6e2UQ6f2VQ6j2XQ6l2ZQ6q2cQ7]3fQ7o4VQ8u6VQ9R6gQ9S6hQ9U6kQ9h7^Q:c8vR:m9V#[cOPXZst!Z!`!o#d#o#{%m&k&n&o&r&t&u&w&{'T'c)P*j+_+i,r,u,z-k.i/p0_0n1t2U2V2X2Z2^2a2c3f4|6V6g6h6k7^8v9VQ#YWQ#eYQ%quQ%svS%uw!gS(T#W(WQ(Z#ZQ(u#uQ(z#xQ)S$OQ)T$PQ)U$QQ)V$RQ)W$SQ)X$TQ)Y$UQ)Z$VQ)[$WQ)]$XQ)_$ZQ)a$_Q)c$aQ)h$eW)r$n)t/X4VQ+f%tQ+z&RS-['X2qQ-z'sS.P(U.RQ.U(^Q.W(eQ.u(yQ.x({Q.|<WQ/O<ZQ/P<[Q/Q<_Q/d*OQ0r+YQ2o-YQ2t-aQ3Q-sQ3X.XQ3m.vQ3r<`Q3s<aQ3t<bQ3u<cQ3v<dQ3w<eQ3x<fQ3y<gQ3z<hQ3{<iQ3|<jQ3}.}Q4O<mQ4R<pQ4S<}Q4Z<kQ5Z0tQ5e1UQ6w=PQ6}3SQ7S3YQ7c3nQ7d=QQ7m=SQ7n=[Q8m5yQ9Z6uQ9_7OQ9i=]Q9o=fQ9p=gQ:q9aQ;Y:]Q;b:oQ<Y#SR=w>TR#[WR'Z!el!tQ!r!v!y!z'a'm'n'o-g-w1q5}6PS'V!e-^U*k$|*[*pS-Z'W'`S0W*l*rQ0`*sQ2w-eQ4x0^R4}0aR(|#xQ!fQT-f'a-g]!qQ!r'a-g1q5}Q#p]R'j<XR)g$dY!uQ'a-g1q5}Q'l!rS'v!v!yS'x!z6PS-v'm'nQ-x'oR3V-wT#kZ%eS#jZ%eS%km,qU(h#h#i#lS.[(i(jQ.`(kQ0v+`Q3[.]U3].^._.aS7U3^3_R9b7Vd#^W#W#Z%h(U(_*Z+[.V/or#gZm#h#i#l%e(i(j(k+`.].^._.a3^3_7VS*^$x*cQ/v*_Q2W,qQ2m-WQ4b/rQ6s2fQ7u4cQ9Y6tT=n'X+^V#aW%h*ZU#`W%h*ZS(V#W(_U([#Z+[/oS-]'X+^T.Q(U.VV'_!e%i*[Q$lfR)y$qT)n$l)oR4X/WT*`$x*cT*i${*ZQ0y+hQ1i,XQ3a.hQ5v1kQ6R1sQ7Z3eQ8t6UQ9e7YQ:`8sQ:r9dQ;]:bQ;e:tQ;p;^R;s;fnqOXst!Z#d%m&r&t&u&w,u,z2^2aQ&l!VR,j&itmOXst!U!V!Z#d%m&i&r&t&u&w,u,z2^2aR,q&oT%lm,qR1m,ZR,i&gQ&U|S,P&V&WR1`,QR+u&PT&p!W&sT&q!W&sT2`,z2a",nodeNames:"⚠ ArithOp ArithOp ?. JSXStartTag LineComment BlockComment Script Hashbang ExportDeclaration export Star as VariableName String Escape from ; default FunctionDeclaration async function VariableDefinition > < TypeParamList in out const TypeDefinition extends ThisType this LiteralType ArithOp Number BooleanLiteral TemplateType InterpolationEnd Interpolation InterpolationStart NullType null VoidType void TypeofType typeof MemberExpression . PropertyName [ TemplateString Escape Interpolation super RegExp ] ArrayExpression Spread , } { ObjectExpression Property async get set PropertyDefinition Block : NewTarget new NewExpression ) ( ArgList UnaryExpression delete LogicOp BitOp YieldExpression yield AwaitExpression await ParenthesizedExpression ClassExpression class ClassBody MethodDeclaration Decorator @ MemberExpression PrivatePropertyName CallExpression TypeArgList CompareOp < declare Privacy static abstract override PrivatePropertyDefinition PropertyDeclaration readonly accessor Optional TypeAnnotation Equals StaticBlock FunctionExpression ArrowFunction ParamList ParamList ArrayPattern ObjectPattern PatternProperty VariableDefinition Privacy readonly Arrow MemberExpression BinaryExpression ArithOp ArithOp ArithOp ArithOp BitOp CompareOp instanceof satisfies CompareOp BitOp BitOp BitOp LogicOp LogicOp ConditionalExpression LogicOp LogicOp AssignmentExpression UpdateOp PostfixExpression CallExpression InstantiationExpression TaggedTemplateExpression DynamicImport import ImportMeta JSXElement JSXSelfCloseEndTag JSXSelfClosingTag JSXIdentifier JSXBuiltin JSXIdentifier JSXNamespacedName JSXMemberExpression JSXSpreadAttribute JSXAttribute JSXAttributeValue JSXEscape JSXEndTag JSXOpenTag JSXFragmentTag JSXText JSXEscape JSXStartCloseTag JSXCloseTag PrefixCast < ArrowFunction TypeParamList SequenceExpression InstantiationExpression KeyofType keyof UniqueType unique ImportType InferredType infer TypeName ParenthesizedType FunctionSignature ParamList NewSignature IndexedType TupleType Label ArrayType ReadonlyType ObjectType MethodType PropertyType IndexSignature PropertyDefinition CallSignature TypePredicate asserts is NewSignature new UnionType LogicOp IntersectionType LogicOp ConditionalType ParameterizedType ClassDeclaration abstract implements type VariableDeclaration let var using TypeAliasDeclaration InterfaceDeclaration interface EnumDeclaration enum EnumBody NamespaceDeclaration namespace module AmbientDeclaration declare GlobalDeclaration global ClassDeclaration ClassBody AmbientFunctionDeclaration ExportGroup VariableName VariableName ImportDeclaration defer ImportGroup ForStatement for ForSpec ForInSpec ForOfSpec of WhileStatement while WithStatement with DoStatement do IfStatement if else SwitchStatement switch SwitchBody CaseLabel case DefaultLabel TryStatement try CatchClause catch FinallyClause finally ReturnStatement return ThrowStatement throw BreakStatement break ContinueStatement continue DebuggerStatement debugger LabeledStatement ExpressionStatement SingleExpression SingleClassItem",maxTerm:381,context:T,nodeProps:[["isolate",-8,5,6,14,37,39,51,53,55,""],["group",-26,9,17,19,68,208,212,216,217,219,222,225,235,238,244,246,248,250,253,259,265,267,269,271,273,275,276,"Statement",-34,13,14,32,35,36,42,51,54,55,57,62,70,72,76,80,82,84,85,110,111,121,122,137,140,142,143,144,145,146,148,149,168,170,172,"Expression",-23,31,33,37,41,43,45,174,176,178,179,181,182,183,185,186,187,189,190,191,202,204,206,207,"Type",-3,88,103,109,"ClassItem"],["openedBy",23,"<",38,"InterpolationStart",56,"[",60,"{",73,"(",161,"JSXStartCloseTag"],["closedBy",-2,24,169,">",40,"InterpolationEnd",50,"]",61,"}",74,")",166,"JSXEndTag"]],propSources:[L],skippedNodes:[0,5,6,279],repeatNodeCount:37,tokenData:"$Fq07[R!bOX%ZXY+gYZ-yZ[+g[]%Z]^.c^p%Zpq+gqr/mrs3cst:_tuEruvJSvwLkwx! Yxy!'iyz!(sz{!)}{|!,q|}!.O}!O!,q!O!P!/Y!P!Q!9j!Q!R#:O!R![#<_![!]#I_!]!^#Jk!^!_#Ku!_!`$![!`!a$$v!a!b$*T!b!c$,r!c!}Er!}#O$-|#O#P$/W#P#Q$4o#Q#R$5y#R#SEr#S#T$7W#T#o$8b#o#p$<r#p#q$=h#q#r$>x#r#s$@U#s$f%Z$f$g+g$g#BYEr#BY#BZ$A`#BZ$ISEr$IS$I_$A`$I_$I|Er$I|$I}$Dk$I}$JO$Dk$JO$JTEr$JT$JU$A`$JU$KVEr$KV$KW$A`$KW&FUEr&FU&FV$A`&FV;'SEr;'S;=`I|<%l?HTEr?HT?HU$A`?HUOEr(n%d_$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z&j&hT$j&jO!^&c!_#o&c#p;'S&c;'S;=`&w<%lO&c&j&zP;=`<%l&c'|'U]$j&j([!bOY&}YZ&cZw&}wx&cx!^&}!^!_'}!_#O&}#O#P&c#P#o&}#o#p'}#p;'S&};'S;=`(l<%lO&}!b(SU([!bOY'}Zw'}x#O'}#P;'S'};'S;=`(f<%lO'}!b(iP;=`<%l'}'|(oP;=`<%l&}'[(y]$j&j(XpOY(rYZ&cZr(rrs&cs!^(r!^!_)r!_#O(r#O#P&c#P#o(r#o#p)r#p;'S(r;'S;=`*a<%lO(rp)wU(XpOY)rZr)rs#O)r#P;'S)r;'S;=`*Z<%lO)rp*^P;=`<%l)r'[*dP;=`<%l(r#S*nX(Xp([!bOY*gZr*grs'}sw*gwx)rx#O*g#P;'S*g;'S;=`+Z<%lO*g#S+^P;=`<%l*g(n+dP;=`<%l%Z07[+rq$j&j(Xp([!b'}0/lOX%ZXY+gYZ&cZ[+g[p%Zpq+gqr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p$f%Z$f$g+g$g#BY%Z#BY#BZ+g#BZ$IS%Z$IS$I_+g$I_$JT%Z$JT$JU+g$JU$KV%Z$KV$KW+g$KW&FU%Z&FU&FV+g&FV;'S%Z;'S;=`+a<%l?HT%Z?HT?HU+g?HUO%Z07[.ST(Y#S$j&j(O0/lO!^&c!_#o&c#p;'S&c;'S;=`&w<%lO&c07[.n_$j&j(Xp([!b(O0/lOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z)3p/x`$j&j!p),Q(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_!`0z!`#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z(KW1V`#w(Ch$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_!`2X!`#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z(KW2d_#w(Ch$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z'At3l_(W':f$j&j([!bOY4kYZ5qZr4krs7nsw4kwx5qx!^4k!^!_8p!_#O4k#O#P5q#P#o4k#o#p8p#p;'S4k;'S;=`:X<%lO4k(^4r_$j&j([!bOY4kYZ5qZr4krs7nsw4kwx5qx!^4k!^!_8p!_#O4k#O#P5q#P#o4k#o#p8p#p;'S4k;'S;=`:X<%lO4k&z5vX$j&jOr5qrs6cs!^5q!^!_6y!_#o5q#o#p6y#p;'S5q;'S;=`7h<%lO5q&z6jT$e`$j&jO!^&c!_#o&c#p;'S&c;'S;=`&w<%lO&c`6|TOr6yrs7]s;'S6y;'S;=`7b<%lO6y`7bO$e``7eP;=`<%l6y&z7kP;=`<%l5q(^7w]$e`$j&j([!bOY&}YZ&cZw&}wx&cx!^&}!^!_'}!_#O&}#O#P&c#P#o&}#o#p'}#p;'S&};'S;=`(l<%lO&}!r8uZ([!bOY8pYZ6yZr8prs9hsw8pwx6yx#O8p#O#P6y#P;'S8p;'S;=`:R<%lO8p!r9oU$e`([!bOY'}Zw'}x#O'}#P;'S'};'S;=`(f<%lO'}!r:UP;=`<%l8p(^:[P;=`<%l4k%9[:hh$j&j(Xp([!bOY%ZYZ&cZq%Zqr<Srs&}st%ZtuCruw%Zwx(rx!^%Z!^!_*g!_!c%Z!c!}Cr!}#O%Z#O#P&c#P#R%Z#R#SCr#S#T%Z#T#oCr#o#p*g#p$g%Z$g;'SCr;'S;=`El<%lOCr(r<__WS$j&j(Xp([!bOY<SYZ&cZr<Srs=^sw<Swx@nx!^<S!^!_Bm!_#O<S#O#P>`#P#o<S#o#pBm#p;'S<S;'S;=`Cl<%lO<S(Q=g]WS$j&j([!bOY=^YZ&cZw=^wx>`x!^=^!^!_?q!_#O=^#O#P>`#P#o=^#o#p?q#p;'S=^;'S;=`@h<%lO=^&n>gXWS$j&jOY>`YZ&cZ!^>`!^!_?S!_#o>`#o#p?S#p;'S>`;'S;=`?k<%lO>`S?XSWSOY?SZ;'S?S;'S;=`?e<%lO?SS?hP;=`<%l?S&n?nP;=`<%l>`!f?xWWS([!bOY?qZw?qwx?Sx#O?q#O#P?S#P;'S?q;'S;=`@b<%lO?q!f@eP;=`<%l?q(Q@kP;=`<%l=^'`@w]WS$j&j(XpOY@nYZ&cZr@nrs>`s!^@n!^!_Ap!_#O@n#O#P>`#P#o@n#o#pAp#p;'S@n;'S;=`Bg<%lO@ntAwWWS(XpOYApZrAprs?Ss#OAp#O#P?S#P;'SAp;'S;=`Ba<%lOAptBdP;=`<%lAp'`BjP;=`<%l@n#WBvYWS(Xp([!bOYBmZrBmrs?qswBmwxApx#OBm#O#P?S#P;'SBm;'S;=`Cf<%lOBm#WCiP;=`<%lBm(rCoP;=`<%l<S%9[C}i$j&j(p%1l(Xp([!bOY%ZYZ&cZr%Zrs&}st%ZtuCruw%Zwx(rx!Q%Z!Q![Cr![!^%Z!^!_*g!_!c%Z!c!}Cr!}#O%Z#O#P&c#P#R%Z#R#SCr#S#T%Z#T#oCr#o#p*g#p$g%Z$g;'SCr;'S;=`El<%lOCr%9[EoP;=`<%lCr07[FRk$j&j(Xp([!b$^#t(U,2j(f$I[OY%ZYZ&cZr%Zrs&}st%ZtuEruw%Zwx(rx}%Z}!OGv!O!Q%Z!Q![Er![!^%Z!^!_*g!_!c%Z!c!}Er!}#O%Z#O#P&c#P#R%Z#R#SEr#S#T%Z#T#oEr#o#p*g#p$g%Z$g;'SEr;'S;=`I|<%lOEr+dHRk$j&j(Xp([!b$^#tOY%ZYZ&cZr%Zrs&}st%ZtuGvuw%Zwx(rx}%Z}!OGv!O!Q%Z!Q![Gv![!^%Z!^!_*g!_!c%Z!c!}Gv!}#O%Z#O#P&c#P#R%Z#R#SGv#S#T%Z#T#oGv#o#p*g#p$g%Z$g;'SGv;'S;=`Iv<%lOGv+dIyP;=`<%lGv07[JPP;=`<%lEr(KWJ_`$j&j(Xp([!b#q(ChOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_!`Ka!`#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z(KWKl_$j&j$R(Ch(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z,#xLva({+JY$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sv%ZvwM{wx(rx!^%Z!^!_*g!_!`Ka!`#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z(KWNW`$j&j#{(Ch(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_!`Ka!`#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z'At! c_(Z';W$j&j(XpOY!!bYZ!#hZr!!brs!#hsw!!bwx!$xx!^!!b!^!_!%z!_#O!!b#O#P!#h#P#o!!b#o#p!%z#p;'S!!b;'S;=`!'c<%lO!!b'l!!i_$j&j(XpOY!!bYZ!#hZr!!brs!#hsw!!bwx!$xx!^!!b!^!_!%z!_#O!!b#O#P!#h#P#o!!b#o#p!%z#p;'S!!b;'S;=`!'c<%lO!!b&z!#mX$j&jOw!#hwx6cx!^!#h!^!_!$Y!_#o!#h#o#p!$Y#p;'S!#h;'S;=`!$r<%lO!#h`!$]TOw!$Ywx7]x;'S!$Y;'S;=`!$l<%lO!$Y`!$oP;=`<%l!$Y&z!$uP;=`<%l!#h'l!%R]$e`$j&j(XpOY(rYZ&cZr(rrs&cs!^(r!^!_)r!_#O(r#O#P&c#P#o(r#o#p)r#p;'S(r;'S;=`*a<%lO(r!Q!&PZ(XpOY!%zYZ!$YZr!%zrs!$Ysw!%zwx!&rx#O!%z#O#P!$Y#P;'S!%z;'S;=`!']<%lO!%z!Q!&yU$e`(XpOY)rZr)rs#O)r#P;'S)r;'S;=`*Z<%lO)r!Q!'`P;=`<%l!%z'l!'fP;=`<%l!!b/5|!'t_!l/.^$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z#&U!)O_!k!Lf$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z-!n!*[b$j&j(Xp([!b(V%&f#r(ChOY%ZYZ&cZr%Zrs&}sw%Zwx(rxz%Zz{!+d{!^%Z!^!_*g!_!`Ka!`#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z(KW!+o`$j&j(Xp([!b#o(ChOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_!`Ka!`#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z+;x!,|`$j&j(Xp([!br+4YOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_!`Ka!`#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z,$U!.Z_!]+Jf$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z07[!/ec$j&j(Xp([!b!Q.2^OY%ZYZ&cZr%Zrs&}sw%Zwx(rx!O%Z!O!P!0p!P!Q%Z!Q![!3Y![!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z#%|!0ya$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!O%Z!O!P!2O!P!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z#%|!2Z_![!L^$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z'Ad!3eg$j&j(Xp([!bs'9tOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!Q%Z!Q![!3Y![!^%Z!^!_*g!_!g%Z!g!h!4|!h#O%Z#O#P&c#P#R%Z#R#S!3Y#S#X%Z#X#Y!4|#Y#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z'Ad!5Vg$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx{%Z{|!6n|}%Z}!O!6n!O!Q%Z!Q![!8S![!^%Z!^!_*g!_#O%Z#O#P&c#P#R%Z#R#S!8S#S#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z'Ad!6wc$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!Q%Z!Q![!8S![!^%Z!^!_*g!_#O%Z#O#P&c#P#R%Z#R#S!8S#S#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z'Ad!8_c$j&j(Xp([!bs'9tOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!Q%Z!Q![!8S![!^%Z!^!_*g!_#O%Z#O#P&c#P#R%Z#R#S!8S#S#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z07[!9uf$j&j(Xp([!b#p(ChOY!;ZYZ&cZr!;Zrs!<nsw!;Zwx!Lcxz!;Zz{#-}{!P!;Z!P!Q#/d!Q!^!;Z!^!_#(i!_!`#7S!`!a#8i!a!}!;Z!}#O#,f#O#P!Dy#P#o!;Z#o#p#(i#p;'S!;Z;'S;=`#-w<%lO!;Z?O!;fb$j&j(Xp([!b!X7`OY!;ZYZ&cZr!;Zrs!<nsw!;Zwx!Lcx!P!;Z!P!Q#&`!Q!^!;Z!^!_#(i!_!}!;Z!}#O#,f#O#P!Dy#P#o!;Z#o#p#(i#p;'S!;Z;'S;=`#-w<%lO!;Z>^!<w`$j&j([!b!X7`OY!<nYZ&cZw!<nwx!=yx!P!<n!P!Q!Eq!Q!^!<n!^!_!Gr!_!}!<n!}#O!KS#O#P!Dy#P#o!<n#o#p!Gr#p;'S!<n;'S;=`!L]<%lO!<n<z!>Q^$j&j!X7`OY!=yYZ&cZ!P!=y!P!Q!>|!Q!^!=y!^!_!@c!_!}!=y!}#O!CW#O#P!Dy#P#o!=y#o#p!@c#p;'S!=y;'S;=`!Ek<%lO!=y<z!?Td$j&j!X7`O!^&c!_#W&c#W#X!>|#X#Z&c#Z#[!>|#[#]&c#]#^!>|#^#a&c#a#b!>|#b#g&c#g#h!>|#h#i&c#i#j!>|#j#k!>|#k#m&c#m#n!>|#n#o&c#p;'S&c;'S;=`&w<%lO&c7`!@hX!X7`OY!@cZ!P!@c!P!Q!AT!Q!}!@c!}#O!Ar#O#P!Bq#P;'S!@c;'S;=`!CQ<%lO!@c7`!AYW!X7`#W#X!AT#Z#[!AT#]#^!AT#a#b!AT#g#h!AT#i#j!AT#j#k!AT#m#n!AT7`!AuVOY!ArZ#O!Ar#O#P!B[#P#Q!@c#Q;'S!Ar;'S;=`!Bk<%lO!Ar7`!B_SOY!ArZ;'S!Ar;'S;=`!Bk<%lO!Ar7`!BnP;=`<%l!Ar7`!BtSOY!@cZ;'S!@c;'S;=`!CQ<%lO!@c7`!CTP;=`<%l!@c<z!C][$j&jOY!CWYZ&cZ!^!CW!^!_!Ar!_#O!CW#O#P!DR#P#Q!=y#Q#o!CW#o#p!Ar#p;'S!CW;'S;=`!Ds<%lO!CW<z!DWX$j&jOY!CWYZ&cZ!^!CW!^!_!Ar!_#o!CW#o#p!Ar#p;'S!CW;'S;=`!Ds<%lO!CW<z!DvP;=`<%l!CW<z!EOX$j&jOY!=yYZ&cZ!^!=y!^!_!@c!_#o!=y#o#p!@c#p;'S!=y;'S;=`!Ek<%lO!=y<z!EnP;=`<%l!=y>^!Ezl$j&j([!b!X7`OY&}YZ&cZw&}wx&cx!^&}!^!_'}!_#O&}#O#P&c#P#W&}#W#X!Eq#X#Z&}#Z#[!Eq#[#]&}#]#^!Eq#^#a&}#a#b!Eq#b#g&}#g#h!Eq#h#i&}#i#j!Eq#j#k!Eq#k#m&}#m#n!Eq#n#o&}#o#p'}#p;'S&};'S;=`(l<%lO&}8r!GyZ([!b!X7`OY!GrZw!Grwx!@cx!P!Gr!P!Q!Hl!Q!}!Gr!}#O!JU#O#P!Bq#P;'S!Gr;'S;=`!J|<%lO!Gr8r!Hse([!b!X7`OY'}Zw'}x#O'}#P#W'}#W#X!Hl#X#Z'}#Z#[!Hl#[#]'}#]#^!Hl#^#a'}#a#b!Hl#b#g'}#g#h!Hl#h#i'}#i#j!Hl#j#k!Hl#k#m'}#m#n!Hl#n;'S'};'S;=`(f<%lO'}8r!JZX([!bOY!JUZw!JUwx!Arx#O!JU#O#P!B[#P#Q!Gr#Q;'S!JU;'S;=`!Jv<%lO!JU8r!JyP;=`<%l!JU8r!KPP;=`<%l!Gr>^!KZ^$j&j([!bOY!KSYZ&cZw!KSwx!CWx!^!KS!^!_!JU!_#O!KS#O#P!DR#P#Q!<n#Q#o!KS#o#p!JU#p;'S!KS;'S;=`!LV<%lO!KS>^!LYP;=`<%l!KS>^!L`P;=`<%l!<n=l!Ll`$j&j(Xp!X7`OY!LcYZ&cZr!Lcrs!=ys!P!Lc!P!Q!Mn!Q!^!Lc!^!_# o!_!}!Lc!}#O#%P#O#P!Dy#P#o!Lc#o#p# o#p;'S!Lc;'S;=`#&Y<%lO!Lc=l!Mwl$j&j(Xp!X7`OY(rYZ&cZr(rrs&cs!^(r!^!_)r!_#O(r#O#P&c#P#W(r#W#X!Mn#X#Z(r#Z#[!Mn#[#](r#]#^!Mn#^#a(r#a#b!Mn#b#g(r#g#h!Mn#h#i(r#i#j!Mn#j#k!Mn#k#m(r#m#n!Mn#n#o(r#o#p)r#p;'S(r;'S;=`*a<%lO(r8Q# vZ(Xp!X7`OY# oZr# ors!@cs!P# o!P!Q#!i!Q!}# o!}#O#$R#O#P!Bq#P;'S# o;'S;=`#$y<%lO# o8Q#!pe(Xp!X7`OY)rZr)rs#O)r#P#W)r#W#X#!i#X#Z)r#Z#[#!i#[#])r#]#^#!i#^#a)r#a#b#!i#b#g)r#g#h#!i#h#i)r#i#j#!i#j#k#!i#k#m)r#m#n#!i#n;'S)r;'S;=`*Z<%lO)r8Q#$WX(XpOY#$RZr#$Rrs!Ars#O#$R#O#P!B[#P#Q# o#Q;'S#$R;'S;=`#$s<%lO#$R8Q#$vP;=`<%l#$R8Q#$|P;=`<%l# o=l#%W^$j&j(XpOY#%PYZ&cZr#%Prs!CWs!^#%P!^!_#$R!_#O#%P#O#P!DR#P#Q!Lc#Q#o#%P#o#p#$R#p;'S#%P;'S;=`#&S<%lO#%P=l#&VP;=`<%l#%P=l#&]P;=`<%l!Lc?O#&kn$j&j(Xp([!b!X7`OY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_#O%Z#O#P&c#P#W%Z#W#X#&`#X#Z%Z#Z#[#&`#[#]%Z#]#^#&`#^#a%Z#a#b#&`#b#g%Z#g#h#&`#h#i%Z#i#j#&`#j#k#&`#k#m%Z#m#n#&`#n#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z9d#(r](Xp([!b!X7`OY#(iZr#(irs!Grsw#(iwx# ox!P#(i!P!Q#)k!Q!}#(i!}#O#+`#O#P!Bq#P;'S#(i;'S;=`#,`<%lO#(i9d#)th(Xp([!b!X7`OY*gZr*grs'}sw*gwx)rx#O*g#P#W*g#W#X#)k#X#Z*g#Z#[#)k#[#]*g#]#^#)k#^#a*g#a#b#)k#b#g*g#g#h#)k#h#i*g#i#j#)k#j#k#)k#k#m*g#m#n#)k#n;'S*g;'S;=`+Z<%lO*g9d#+gZ(Xp([!bOY#+`Zr#+`rs!JUsw#+`wx#$Rx#O#+`#O#P!B[#P#Q#(i#Q;'S#+`;'S;=`#,Y<%lO#+`9d#,]P;=`<%l#+`9d#,cP;=`<%l#(i?O#,o`$j&j(Xp([!bOY#,fYZ&cZr#,frs!KSsw#,fwx#%Px!^#,f!^!_#+`!_#O#,f#O#P!DR#P#Q!;Z#Q#o#,f#o#p#+`#p;'S#,f;'S;=`#-q<%lO#,f?O#-tP;=`<%l#,f?O#-zP;=`<%l!;Z07[#.[b$j&j(Xp([!b(P0/l!X7`OY!;ZYZ&cZr!;Zrs!<nsw!;Zwx!Lcx!P!;Z!P!Q#&`!Q!^!;Z!^!_#(i!_!}!;Z!}#O#,f#O#P!Dy#P#o!;Z#o#p#(i#p;'S!;Z;'S;=`#-w<%lO!;Z07[#/o_$j&j(Xp([!bT0/lOY#/dYZ&cZr#/drs#0nsw#/dwx#4Ox!^#/d!^!_#5}!_#O#/d#O#P#1p#P#o#/d#o#p#5}#p;'S#/d;'S;=`#6|<%lO#/d06j#0w]$j&j([!bT0/lOY#0nYZ&cZw#0nwx#1px!^#0n!^!_#3R!_#O#0n#O#P#1p#P#o#0n#o#p#3R#p;'S#0n;'S;=`#3x<%lO#0n05W#1wX$j&jT0/lOY#1pYZ&cZ!^#1p!^!_#2d!_#o#1p#o#p#2d#p;'S#1p;'S;=`#2{<%lO#1p0/l#2iST0/lOY#2dZ;'S#2d;'S;=`#2u<%lO#2d0/l#2xP;=`<%l#2d05W#3OP;=`<%l#1p01O#3YW([!bT0/lOY#3RZw#3Rwx#2dx#O#3R#O#P#2d#P;'S#3R;'S;=`#3r<%lO#3R01O#3uP;=`<%l#3R06j#3{P;=`<%l#0n05x#4X]$j&j(XpT0/lOY#4OYZ&cZr#4Ors#1ps!^#4O!^!_#5Q!_#O#4O#O#P#1p#P#o#4O#o#p#5Q#p;'S#4O;'S;=`#5w<%lO#4O00^#5XW(XpT0/lOY#5QZr#5Qrs#2ds#O#5Q#O#P#2d#P;'S#5Q;'S;=`#5q<%lO#5Q00^#5tP;=`<%l#5Q05x#5zP;=`<%l#4O01p#6WY(Xp([!bT0/lOY#5}Zr#5}rs#3Rsw#5}wx#5Qx#O#5}#O#P#2d#P;'S#5};'S;=`#6v<%lO#5}01p#6yP;=`<%l#5}07[#7PP;=`<%l#/d)3h#7ab$j&j$R(Ch(Xp([!b!X7`OY!;ZYZ&cZr!;Zrs!<nsw!;Zwx!Lcx!P!;Z!P!Q#&`!Q!^!;Z!^!_#(i!_!}!;Z!}#O#,f#O#P!Dy#P#o!;Z#o#p#(i#p;'S!;Z;'S;=`#-w<%lO!;ZAt#8vb$[#t$j&j(Xp([!b!X7`OY!;ZYZ&cZr!;Zrs!<nsw!;Zwx!Lcx!P!;Z!P!Q#&`!Q!^!;Z!^!_#(i!_!}!;Z!}#O#,f#O#P!Dy#P#o!;Z#o#p#(i#p;'S!;Z;'S;=`#-w<%lO!;Z'Ad#:Zp$j&j(Xp([!bs'9tOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!O%Z!O!P!3Y!P!Q%Z!Q![#<_![!^%Z!^!_*g!_!g%Z!g!h!4|!h#O%Z#O#P&c#P#R%Z#R#S#<_#S#U%Z#U#V#?i#V#X%Z#X#Y!4|#Y#b%Z#b#c#>_#c#d#Bq#d#l%Z#l#m#Es#m#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z'Ad#<jk$j&j(Xp([!bs'9tOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!O%Z!O!P!3Y!P!Q%Z!Q![#<_![!^%Z!^!_*g!_!g%Z!g!h!4|!h#O%Z#O#P&c#P#R%Z#R#S#<_#S#X%Z#X#Y!4|#Y#b%Z#b#c#>_#c#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z'Ad#>j_$j&j(Xp([!bs'9tOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z'Ad#?rd$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!Q%Z!Q!R#AQ!R!S#AQ!S!^%Z!^!_*g!_#O%Z#O#P&c#P#R%Z#R#S#AQ#S#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z'Ad#A]f$j&j(Xp([!bs'9tOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!Q%Z!Q!R#AQ!R!S#AQ!S!^%Z!^!_*g!_#O%Z#O#P&c#P#R%Z#R#S#AQ#S#b%Z#b#c#>_#c#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z'Ad#Bzc$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!Q%Z!Q!Y#DV!Y!^%Z!^!_*g!_#O%Z#O#P&c#P#R%Z#R#S#DV#S#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z'Ad#Dbe$j&j(Xp([!bs'9tOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!Q%Z!Q!Y#DV!Y!^%Z!^!_*g!_#O%Z#O#P&c#P#R%Z#R#S#DV#S#b%Z#b#c#>_#c#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z'Ad#E|g$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!Q%Z!Q![#Ge![!^%Z!^!_*g!_!c%Z!c!i#Ge!i#O%Z#O#P&c#P#R%Z#R#S#Ge#S#T%Z#T#Z#Ge#Z#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z'Ad#Gpi$j&j(Xp([!bs'9tOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!Q%Z!Q![#Ge![!^%Z!^!_*g!_!c%Z!c!i#Ge!i#O%Z#O#P&c#P#R%Z#R#S#Ge#S#T%Z#T#Z#Ge#Z#b%Z#b#c#>_#c#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z*)x#Il_!g$b$j&j$P)Lv(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z)[#Jv_al$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z04f#LS^h#)`#R-<U(Xp([!b$o7`OY*gZr*grs'}sw*gwx)rx!P*g!P!Q#MO!Q!^*g!^!_#Mt!_!`$ f!`#O*g#P;'S*g;'S;=`+Z<%lO*g(n#MXX$l&j(Xp([!bOY*gZr*grs'}sw*gwx)rx#O*g#P;'S*g;'S;=`+Z<%lO*g(El#M}Z#s(Ch(Xp([!bOY*gZr*grs'}sw*gwx)rx!_*g!_!`#Np!`#O*g#P;'S*g;'S;=`+Z<%lO*g(El#NyX$R(Ch(Xp([!bOY*gZr*grs'}sw*gwx)rx#O*g#P;'S*g;'S;=`+Z<%lO*g(El$ oX#t(Ch(Xp([!bOY*gZr*grs'}sw*gwx)rx#O*g#P;'S*g;'S;=`+Z<%lO*g*)x$!ga#`*!Y$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_!`0z!`!a$#l!a#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z(K[$#w_#l(Cl$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z*)x$%Vag!*r#t(Ch$g#|$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_!`$&[!`!a$'f!a#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z(KW$&g_#t(Ch$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z(KW$'qa#s(Ch$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_!`Ka!`!a$(v!a#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z(KW$)R`#s(Ch$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_!`Ka!`#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z(Kd$*`a(s(Ct$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_!a%Z!a!b$+e!b#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z(KW$+p`$j&j#|(Ch(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_!`Ka!`#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z%#`$,}_!|$Ip$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z04f$.X_!S0,v$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z(n$/]Z$j&jO!^$0O!^!_$0f!_#i$0O#i#j$0k#j#l$0O#l#m$2^#m#o$0O#o#p$0f#p;'S$0O;'S;=`$4i<%lO$0O(n$0VT_#S$j&jO!^&c!_#o&c#p;'S&c;'S;=`&w<%lO&c#S$0kO_#S(n$0p[$j&jO!Q&c!Q![$1f![!^&c!_!c&c!c!i$1f!i#T&c#T#Z$1f#Z#o&c#o#p$3|#p;'S&c;'S;=`&w<%lO&c(n$1kZ$j&jO!Q&c!Q![$2^![!^&c!_!c&c!c!i$2^!i#T&c#T#Z$2^#Z#o&c#p;'S&c;'S;=`&w<%lO&c(n$2cZ$j&jO!Q&c!Q![$3U![!^&c!_!c&c!c!i$3U!i#T&c#T#Z$3U#Z#o&c#p;'S&c;'S;=`&w<%lO&c(n$3ZZ$j&jO!Q&c!Q![$0O![!^&c!_!c&c!c!i$0O!i#T&c#T#Z$0O#Z#o&c#p;'S&c;'S;=`&w<%lO&c#S$4PR!Q![$4Y!c!i$4Y#T#Z$4Y#S$4]S!Q![$4Y!c!i$4Y#T#Z$4Y#q#r$0f(n$4lP;=`<%l$0O#1[$4z_!Y#)l$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z(KW$6U`#y(Ch$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_!`Ka!`#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z+;p$7c_$j&j(Xp([!b(b+4QOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z07[$8qk$j&j(Xp([!b(U,2j$`#t(f$I[OY%ZYZ&cZr%Zrs&}st%Ztu$8buw%Zwx(rx}%Z}!O$:f!O!Q%Z!Q![$8b![!^%Z!^!_*g!_!c%Z!c!}$8b!}#O%Z#O#P&c#P#R%Z#R#S$8b#S#T%Z#T#o$8b#o#p*g#p$g%Z$g;'S$8b;'S;=`$<l<%lO$8b+d$:qk$j&j(Xp([!b$`#tOY%ZYZ&cZr%Zrs&}st%Ztu$:fuw%Zwx(rx}%Z}!O$:f!O!Q%Z!Q![$:f![!^%Z!^!_*g!_!c%Z!c!}$:f!}#O%Z#O#P&c#P#R%Z#R#S$:f#S#T%Z#T#o$:f#o#p*g#p$g%Z$g;'S$:f;'S;=`$<f<%lO$:f+d$<iP;=`<%l$:f07[$<oP;=`<%l$8b#Jf$<{X!_#Hb(Xp([!bOY*gZr*grs'}sw*gwx)rx#O*g#P;'S*g;'S;=`+Z<%lO*g,#x$=sa(z+JY$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_!`Ka!`#O%Z#O#P&c#P#o%Z#o#p*g#p#q$+e#q;'S%Z;'S;=`+a<%lO%Z)>v$?V_!^(CdvBr$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z?O$@a_!q7`$j&j(Xp([!bOY%ZYZ&cZr%Zrs&}sw%Zwx(rx!^%Z!^!_*g!_#O%Z#O#P&c#P#o%Z#o#p*g#p;'S%Z;'S;=`+a<%lO%Z07[$Aq|$j&j(Xp([!b'}0/l$^#t(U,2j(f$I[OX%ZXY+gYZ&cZ[+g[p%Zpq+gqr%Zrs&}st%ZtuEruw%Zwx(rx}%Z}!OGv!O!Q%Z!Q![Er![!^%Z!^!_*g!_!c%Z!c!}Er!}#O%Z#O#P&c#P#R%Z#R#SEr#S#T%Z#T#oEr#o#p*g#p$f%Z$f$g+g$g#BYEr#BY#BZ$A`#BZ$ISEr$IS$I_$A`$I_$JTEr$JT$JU$A`$JU$KVEr$KV$KW$A`$KW&FUEr&FU&FV$A`&FV;'SEr;'S;=`I|<%l?HTEr?HT?HU$A`?HUOEr07[$D|k$j&j(Xp([!b(O0/l$^#t(U,2j(f$I[OY%ZYZ&cZr%Zrs&}st%ZtuEruw%Zwx(rx}%Z}!OGv!O!Q%Z!Q![Er![!^%Z!^!_*g!_!c%Z!c!}Er!}#O%Z#O#P&c#P#R%Z#R#SEr#S#T%Z#T#oEr#o#p*g#p$g%Z$g;'SEr;'S;=`I|<%lOEr",tokenizers:[N,P,I,D,2,3,4,5,6,7,8,9,10,11,12,13,14,R,new r.uC("$S~RRtu[#O#Pg#S#T#|~_P#o#pb~gOx~~jVO#i!P#i#j!U#j#l!P#l#m!q#m;'S!P;'S;=`#v<%lO!P~!UO!U~~!XS!Q![!e!c!i!e#T#Z!e#o#p#Z~!hR!Q![!q!c!i!q#T#Z!q~!tR!Q![!}!c!i!}#T#Z!}~#QR!Q![!P!c!i!P#T#Z!P~#^R!Q![#g!c!i#g#T#Z#g~#jS!Q![#g!c!i#g#T#Z#g#q#r!P~#yP;=`<%l!P~$RO(d~~",141,341),new r.uC("j~RQYZXz{^~^O(R~~aP!P!Qd~iO(S~~",25,324)],topRules:{Script:[0,7],SingleExpression:[1,277],SingleClassItem:[2,278]},dialects:{jsx:0,ts:15179},dynamicPrecedences:{80:1,82:1,94:1,170:1,200:1},specialized:[{term:328,get:e=>B[e]||-1},{term:344,get:e=>$[e]||-1},{term:95,get:e=>V[e]||-1}],tokenPrec:15205});var j=n(61163),U=n(76528),G=n(81068),H=n(29097),q=n(43114);const Q=[(0,H.snippetCompletion)("function ${name}(${params}) {\n\t${}\n}",{label:"function",detail:"definition",type:"keyword"}),(0,H.snippetCompletion)("for (let ${index} = 0; ${index} < ${bound}; ${index}++) {\n\t${}\n}",{label:"for",detail:"loop",type:"keyword"}),(0,H.snippetCompletion)("for (let ${name} of ${collection}) {\n\t${}\n}",{label:"for",detail:"of loop",type:"keyword"}),(0,H.snippetCompletion)("do {\n\t${}\n} while (${})",{label:"do",detail:"loop",type:"keyword"}),(0,H.snippetCompletion)("while (${}) {\n\t${}\n}",{label:"while",detail:"loop",type:"keyword"}),(0,H.snippetCompletion)("try {\n\t${}\n} catch (${error}) {\n\t${}\n}",{label:"try",detail:"/ catch block",type:"keyword"}),(0,H.snippetCompletion)("if (${}) {\n\t${}\n}",{label:"if",detail:"block",type:"keyword"}),(0,H.snippetCompletion)("if (${}) {\n\t${}\n} else {\n\t${}\n}",{label:"if",detail:"/ else block",type:"keyword"}),(0,H.snippetCompletion)("class ${name} {\n\tconstructor(${params}) {\n\t\t${}\n\t}\n}",{label:"class",detail:"definition",type:"keyword"}),(0,H.snippetCompletion)('import {${names}} from "${module}"\n${}',{label:"import",detail:"named",type:"keyword"}),(0,H.snippetCompletion)('import ${name} from "${module}"\n${}',{label:"import",detail:"default",type:"keyword"})],z=Q.concat([(0,H.snippetCompletion)("interface ${name} {\n\t${}\n}",{label:"interface",detail:"definition",type:"keyword"}),(0,H.snippetCompletion)("type ${name} = ${type}",{label:"type",detail:"definition",type:"keyword"}),(0,H.snippetCompletion)("enum ${name} {\n\t${}\n}",{label:"enum",detail:"definition",type:"keyword"})]),K=new q.NodeWeakMap,W=new Set(["Script","Block","FunctionExpression","FunctionDeclaration","ArrowFunction","MethodDeclaration","ForStatement"]);function X(e){return(t,n)=>{let r=t.node.getChild("VariableDefinition");return r&&n(r,e),!0}}const Y=["FunctionDeclaration"],Z={FunctionDeclaration:X("function"),ClassDeclaration:X("class"),ClassExpression:()=>!0,EnumDeclaration:X("constant"),TypeAliasDeclaration:X("type"),NamespaceDeclaration:X("namespace"),VariableDefinition(e,t){e.matchContext(Y)||t(e,"variable")},TypeDefinition(e,t){t(e,"type")},__proto__:null};function J(e,t){let n=K.get(t);if(n)return n;let r=[],i=!0;function o(t,n){let i=e.sliceString(t.from,t.to);r.push({label:i,type:n})}return t.cursor(q.IterMode.IncludeAnonymous).iterate(t=>{if(i)i=!1;else if(t.name){let e=Z[t.name];if(e&&e(t,o)||W.has(t.name))return!1}else if(t.to-t.from>8192){for(let n of J(e,t.node))r.push(n);return!1}}),K.set(t,r),r}const ee=/^[\w$\xa1-\uffff][\w$\d\xa1-\uffff]*$/,te=["TemplateString","String","RegExp","LineComment","BlockComment","VariableDefinition","TypeDefinition","Label","PropertyDefinition","PropertyName","PrivatePropertyDefinition","PrivatePropertyName","JSXText","JSXAttributeValue","JSXOpenTag","JSXCloseTag","JSXSelfClosingTag",".","?."];function ne(e){let t=(0,j.syntaxTree)(e.state).resolveInner(e.pos,-1);if(te.indexOf(t.name)>-1)return null;let n="VariableName"==t.name||t.to-t.from<20&&ee.test(e.state.sliceDoc(t.from,t.to));if(!n&&!e.explicit)return null;let r=[];for(let i=t;i;i=i.parent)W.has(i.name)&&(r=r.concat(J(e.state.doc,i)));return{options:r,from:n?t.from:e.pos,validFor:ee}}function re(e,t,n){var r;let i=[];for(;;){let o,a=t.firstChild;if("VariableName"==(null===a||void 0===a?void 0:a.name))return i.push(e(a)),{path:i.reverse(),name:n};if("MemberExpression"!=(null===a||void 0===a?void 0:a.name)||"PropertyName"!=(null===(r=o=a.lastChild)||void 0===r?void 0:r.name))return null;i.push(e(o)),t=a}}function ie(e){let t=t=>e.state.doc.sliceString(t.from,t.to),n=(0,j.syntaxTree)(e.state).resolveInner(e.pos,-1);return"PropertyName"==n.name?re(t,n.parent,t(n)):"."!=n.name&&"?."!=n.name||"MemberExpression"!=n.parent.name?te.indexOf(n.name)>-1?null:"VariableName"==n.name||n.to-n.from<20&&ee.test(t(n))?{path:[],name:t(n)}:"MemberExpression"==n.name?re(t,n,""):e.explicit?{path:[],name:""}:null:re(t,n.parent,"")}function oe(e,t){let n=e,r=[],i=new Set;for(let a=0;;a++){for(let l of(Object.getOwnPropertyNames||Object.keys)(e)){if(!/^[a-zA-Z_$\xaa-\uffdc][\w$\xaa-\uffdc]*$/.test(l)||i.has(l))continue;let e;i.add(l);try{e=n[l]}catch(o){continue}r.push({label:l,type:"function"==typeof e?/^[A-Z]/.test(l)?"class":t?"function":"method":t?"variable":"property",boost:-a})}let s=Object.getPrototypeOf(e);if(!s)return r;e=s}}function ae(e){let t=new Map;return n=>{let r=ie(n);if(!r)return null;let i=e;for(let e of r.path)if(i=i[e],!i)return null;let o=t.get(i);return o||t.set(i,o=oe(i,!r.path.length)),{from:n.pos-r.name.length,options:o,validFor:ee}}}const se=j.LRLanguage.define({name:"javascript",parser:F.configure({props:[j.indentNodeProp.add({IfStatement:(0,j.continuedIndent)({except:/^\s*({|else\b)/}),TryStatement:(0,j.continuedIndent)({except:/^\s*({|catch\b|finally\b)/}),LabeledStatement:j.flatIndent,SwitchBody:e=>{let t=e.textAfter,n=/^\s*\}/.test(t),r=/^\s*(case|default)\b/.test(t);return e.baseIndent+(n?0:r?1:2)*e.unit},Block:(0,j.delimitedIndent)({closing:"}"}),ArrowFunction:e=>e.baseIndent+e.unit,"TemplateString BlockComment":()=>null,"Statement Property":(0,j.continuedIndent)({except:/^\s*{/}),JSXElement(e){let t=/^\s*<\//.test(e.textAfter);return e.lineIndent(e.node.from)+(t?0:e.unit)},JSXEscape(e){let t=/\s*\}/.test(e.textAfter);return e.lineIndent(e.node.from)+(t?0:e.unit)},"JSXOpenTag JSXSelfClosingTag"(e){return e.column(e.node.from)+e.unit}}),j.foldNodeProp.add({"Block ClassBody SwitchBody EnumBody ObjectExpression ArrayExpression ObjectType":j.foldInside,BlockComment(e){return{from:e.from+2,to:e.to-2}},JSXElement(e){let t=e.firstChild;if(!t||"JSXSelfClosingTag"==t.name)return null;let n=e.lastChild;return{from:t.to,to:n.type.isError?e.to:n.from}},"JSXSelfClosingTag JSXOpenTag"(e){var t;let n=null===(t=e.firstChild)||void 0===t?void 0:t.nextSibling,r=e.lastChild;return!n||n.type.isError?null:{from:n.to,to:r.type.isError?e.to:r.from}}})]}),languageData:{closeBrackets:{brackets:["(","[","{","'",'"',"`"]},commentTokens:{line:"//",block:{open:"/*",close:"*/"}},indentOnInput:/^\s*(?:case |default:|\{|\}|<\/)$/,wordChars:"$"}}),le={test:e=>/^JSX/.test(e.name),facet:(0,j.defineLanguageFacet)({commentTokens:{block:{open:"{/*",close:"*/}"}}})},ce=se.configure({dialect:"ts"},"typescript"),ue=se.configure({dialect:"jsx",props:[j.sublanguageProp.add(e=>e.isTop?[le]:void 0)]}),de=se.configure({dialect:"jsx ts",props:[j.sublanguageProp.add(e=>e.isTop?[le]:void 0)]},"typescript");let he=e=>({label:e,type:"keyword"});const pe="break case const continue default delete export extends false finally in instanceof let new return static super switch this throw true typeof var yield".split(" ").map(he),fe=pe.concat(["declare","implements","private","protected","public"].map(he));function me(e={}){let t=e.jsx?e.typescript?de:ue:e.typescript?ce:se,n=e.typescript?z.concat(fe):Q.concat(pe);return new j.LanguageSupport(t,[se.data.of({autocomplete:(0,H.ifNotIn)(te,(0,H.completeFromList)(n))}),se.data.of({autocomplete:ne}),e.jsx?ye:[]])}function ge(e){for(;;){if("JSXOpenTag"==e.name||"JSXSelfClosingTag"==e.name||"JSXFragmentTag"==e.name)return e;if("JSXEscape"==e.name||!e.parent)return null;e=e.parent}}function ve(e,t,n=e.length){for(let r=null===t||void 0===t?void 0:t.firstChild;r;r=r.nextSibling)if("JSXIdentifier"==r.name||"JSXBuiltin"==r.name||"JSXNamespacedName"==r.name||"JSXMemberExpression"==r.name)return e.sliceString(r.from,Math.min(r.to,n));return""}const be="object"==typeof navigator&&/Android\b/.test(navigator.userAgent),ye=G.EditorView.inputHandler.of((e,t,n,r,i)=>{if((be?e.composing:e.compositionStarted)||e.state.readOnly||t!=n||">"!=r&&"/"!=r||!se.isActiveAt(e.state,t,-1))return!1;let o=i(),{state:a}=o,s=a.changeByRange(e=>{var t;let n,{head:i}=e,o=(0,j.syntaxTree)(a).resolveInner(i-1,-1);if("JSXStartTag"==o.name&&(o=o.parent),a.doc.sliceString(i-1,i)!=r||"JSXAttributeValue"==o.name&&o.to>i);else{if(">"==r&&"JSXFragmentTag"==o.name)return{range:e,changes:{from:i,insert:"</>"}};if("/"==r&&"JSXStartCloseTag"==o.name){let e=o.parent,r=e.parent;if(r&&e.from==i-2&&((n=ve(a.doc,r.firstChild,i))||"JSXFragmentTag"==(null===(t=r.firstChild)||void 0===t?void 0:t.name))){let e=`${n}>`;return{range:U.EditorSelection.cursor(i+e.length,-1),changes:{from:i,insert:e}}}}else if(">"==r){let t=ge(o);if(t&&"JSXOpenTag"==t.name&&!/^\/?>|^<\//.test(a.doc.sliceString(i,i+2))&&(n=ve(a.doc,t,i)))return{range:e,changes:{from:i,insert:`</${n}>`}}}}return{range:e}});return!s.changes.empty&&(e.dispatch([o,a.update(s,{userEvent:"input.complete",scrollIntoView:!0})]),!0)});function we(e,t){return t||(t={parserOptions:{ecmaVersion:2019,sourceType:"module"},env:{browser:!0,node:!0,es6:!0,es2015:!0,es2017:!0,es2020:!0},rules:{}},e.getRules().forEach((e,n)=>{var r;(null===(r=e.meta.docs)||void 0===r?void 0:r.recommended)&&(t.rules[n]=2)})),n=>{let{state:r}=n,i=[];for(let{from:o,to:a}of se.findRegions(r)){let n=r.doc.lineAt(o),s={line:n.number-1,col:o-n.from,pos:o};for(let l of e.verify(r.sliceDoc(o,a),t))i.push(Se(l,r.doc,s))}return i}}function Oe(e,t,n,r){return n.line(e+r.line).from+t+(1==e?r.col-1:-1)}function Se(e,t,n){let r=Oe(e.line,e.column,t,n),i={from:r,to:null!=e.endLine&&1!=e.endColumn?Oe(e.endLine,e.endColumn,t,n):r,message:e.message,source:e.ruleId?"eslint:"+e.ruleId:"eslint",severity:1==e.severity?"warning":"error"};if(e.fix){let{range:t,text:o}=e.fix,a=t[0]+n.pos-r,s=t[1]+n.pos-r;i.actions=[{name:"fix",apply(e,t){e.dispatch({changes:{from:t+a,to:t+s,insert:o},scrollIntoView:!0})}}]}return i}},94013:function(e,t,n){"use strict";n.r(t),n.d(t,{json:function(){return d},jsonLanguage:function(){return u},jsonParseLinter:function(){return l}});var r=n(73643),i=n(88727);const o=(0,i.styleTags)({String:i.tags.string,Number:i.tags.number,"True False":i.tags.bool,PropertyName:i.tags.propertyName,Null:i.tags.null,", :":i.tags.separator,"[ ]":i.tags.squareBracket,"{ }":i.tags.brace}),a=r.U1.deserialize({version:14,states:"$bOVQPOOOOQO'#Cb'#CbOnQPO'#CeOvQPO'#ClOOQO'#Cr'#CrQOQPOOOOQO'#Cg'#CgO}QPO'#CfO!SQPO'#CtOOQO,59P,59PO![QPO,59PO!aQPO'#CuOOQO,59W,59WO!iQPO,59WOVQPO,59QOqQPO'#CmO!nQPO,59`OOQO1G.k1G.kOVQPO'#CnO!vQPO,59aOOQO1G.r1G.rOOQO1G.l1G.lOOQO,59X,59XOOQO-E6k-E6kOOQO,59Y,59YOOQO-E6l-E6l",stateData:"#O~OeOS~OQSORSOSSOTSOWQO_ROgPO~OVXOgUO~O^[O~PVO[^O~O]_OVhX~OVaO~O]bO^iX~O^dO~O]_OVha~O]bO^ia~O",goto:"!kjPPPPPPkPPkqwPPPPk{!RPPP!XP!e!hXSOR^bQWQRf_TVQ_Q`WRg`QcZRicQTOQZRQe^RhbRYQR]R",nodeNames:"⚠ JsonText True False Null Number String } { Object Property PropertyName : , ] [ Array",maxTerm:25,nodeProps:[["isolate",-2,6,11,""],["openedBy",7,"{",14,"["],["closedBy",8,"}",15,"]"]],propSources:[o],skippedNodes:[0],repeatNodeCount:2,tokenData:"(|~RaXY!WYZ!W]^!Wpq!Wrs!]|}$u}!O$z!Q!R%T!R![&c![!]&t!}#O&y#P#Q'O#Y#Z'T#b#c'r#h#i(Z#o#p(r#q#r(w~!]Oe~~!`Wpq!]qr!]rs!xs#O!]#O#P!}#P;'S!];'S;=`$o<%lO!]~!}Og~~#QXrs!]!P!Q!]#O#P!]#U#V!]#Y#Z!]#b#c!]#f#g!]#h#i!]#i#j#m~#pR!Q![#y!c!i#y#T#Z#y~#|R!Q![$V!c!i$V#T#Z$V~$YR!Q![$c!c!i$c#T#Z$c~$fR!Q![!]!c!i!]#T#Z!]~$rP;=`<%l!]~$zO]~~$}Q!Q!R%T!R![&c~%YRT~!O!P%c!g!h%w#X#Y%w~%fP!Q![%i~%nRT~!Q![%i!g!h%w#X#Y%w~%zR{|&T}!O&T!Q![&Z~&WP!Q![&Z~&`PT~!Q![&Z~&hST~!O!P%c!Q![&c!g!h%w#X#Y%w~&yO[~~'OO_~~'TO^~~'WP#T#U'Z~'^P#`#a'a~'dP#g#h'g~'jP#X#Y'm~'rOR~~'uP#i#j'x~'{P#`#a(O~(RP#`#a(U~(ZOS~~(^P#f#g(a~(dP#i#j(g~(jP#X#Y(m~(rOQ~~(wOW~~(|OV~",tokenizers:[0],topRules:{JsonText:[0,1]},tokenPrec:0});var s=n(61163);const l=()=>e=>{try{JSON.parse(e.state.doc.toString())}catch(t){if(!(t instanceof SyntaxError))throw t;const n=c(t,e.state.doc);return[{from:n,message:t.message,severity:"error",to:n}]}return[]};function c(e,t){let n;return(n=e.message.match(/at position (\d+)/))?Math.min(+n[1],t.length):(n=e.message.match(/at line (\d+) column (\d+)/))?Math.min(t.line(+n[1]).from+ +n[2]-1,t.length):0}const u=s.LRLanguage.define({name:"json",parser:a.configure({props:[s.indentNodeProp.add({Object:(0,s.continuedIndent)({except:/^\s*\}/}),Array:(0,s.continuedIndent)({except:/^\s*\]/})}),s.foldNodeProp.add({"Object Array":s.foldInside})]}),languageData:{closeBrackets:{brackets:["[","{",'"']},indentOnInput:/^\s*[\}\]]$/}});function d(){return new s.LanguageSupport(u)}},18150:function(e,t,n){"use strict";n.r(t),n.d(t,{yaml:function(){return le},yamlFrontmatter:function(){return ue},yamlLanguage:function(){return se}});var r=n(73643),i=n(88727);const o=63,a=64,s=1,l=2,c=3,u=4,d=5,h=6,p=7,f=65,m=66,g=8,v=9,b=10,y=11,w=12,O=13,S=19,E=20,x=29,_=33,k=34,C=47,A=0,T=1,R=2,N=3,P=4;class I{constructor(e,t,n){this.parent=e,this.depth=t,this.type=n,this.hash=(e?e.hash+e.hash<<8:0)+t+(t<<4)+n}}function M(e,t){for(let n=0,r=t-e.pos-1;;r--,n++){let t=e.peek(r);if(L(t)||-1==t)return n}}function D(e){return 32==e||9==e}function L(e){return 10==e||13==e}function B(e){return D(e)||L(e)}function $(e){return e<0||B(e)}I.top=new I(null,-1,A);const V=new r.Aj({start:I.top,reduce(e,t){return e.type!=N||t!=E&&t!=k?e:e.parent},shift(e,t,n,r){if(t==c)return new I(e,M(r,r.pos),T);if(t==f||t==d)return new I(e,M(r,r.pos),R);if(t==o)return e.parent;if(t==S||t==_)return new I(e,0,N);if(t==O&&e.type==P)return e.parent;if(t==C){let t=/[1-9]/.exec(r.read(r.pos,n.pos));if(t)return new I(e,e.depth+ +t[0],P)}return e},hash(e){return e.hash}});function F(e,t,n=0){return e.peek(n)==t&&e.peek(n+1)==t&&e.peek(n+2)==t&&$(e.peek(n+3))}const j=new r.Lu((e,t)=>{if(-1==e.next&&t.canShift(a))return e.acceptToken(a);let n=e.peek(-1);if((L(n)||n<0)&&t.context.type!=N){if(F(e,45)){if(!t.canShift(o))return e.acceptToken(s,3);e.acceptToken(o)}if(F(e,46)){if(!t.canShift(o))return e.acceptToken(l,3);e.acceptToken(o)}let n=0;while(32==e.next)n++,e.advance();!(n<t.context.depth)&&(n!=t.context.depth||t.context.type!=T||45==e.next&&$(e.peek(1)))||-1==e.next||L(e.next)||35==e.next||e.acceptToken(o,-n)}},{contextual:!0}),U=new r.Lu((e,t)=>{if(t.context.type!=N)if(45==e.next)e.advance(),$(e.next)&&e.acceptToken(t.context.type==T&&t.context.depth==M(e,e.pos-1)?u:c);else if(63==e.next)e.advance(),$(e.next)&&e.acceptToken(t.context.type==R&&t.context.depth==M(e,e.pos-1)?h:d);else{let n=e.pos;for(;;)if(D(e.next)){if(e.pos==n)return;e.advance()}else if(33==e.next)Q(e);else{if(38!=e.next){if(42==e.next){z(e);break}if(39==e.next||34==e.next){if(K(e,!0))break;return}if(91==e.next||123==e.next){if(!W(e))return;break}J(e,!0,!1,0);break}z(e)}while(D(e.next))e.advance();if(58==e.next){if(e.pos==n&&t.canShift(x))return;let r=e.peek(1);$(r)&&e.acceptTokenTo(t.context.type==R&&t.context.depth==M(e,n)?m:f,n)}}else 63==e.next&&(e.advance(),$(e.next)&&e.acceptToken(p))},{contextual:!0});function G(e){return e>32&&e<127&&34!=e&&37!=e&&44!=e&&60!=e&&62!=e&&92!=e&&94!=e&&96!=e&&123!=e&&124!=e&&125!=e}function H(e){return e>=48&&e<=57||e>=97&&e<=102||e>=65&&e<=70}function q(e,t){return 37==e.next?(e.advance(),H(e.next)&&e.advance(),H(e.next)&&e.advance(),!0):!!(G(e.next)||t&&44==e.next)&&(e.advance(),!0)}function Q(e){if(e.advance(),60==e.next){for(e.advance();;)if(!q(e,!0)){62==e.next&&e.advance();break}}else while(q(e,!1));}function z(e){e.advance();while(!$(e.next)&&"f"!=Y(e.next))e.advance()}function K(e,t){let n=e.next,r=!1,i=e.pos;for(e.advance();;){let o=e.next;if(o<0)break;if(e.advance(),o==n){if(39!=o)break;if(39!=e.next)break;e.advance()}else if(92==o&&34==n)e.next>=0&&e.advance();else if(L(o)){if(t)return!1;r=!0}else if(t&&e.pos>=i+1024)return!1}return!r}function W(e){for(let t=[],n=e.pos+1024;;)if(91==e.next||123==e.next)t.push(e.next),e.advance();else if(39==e.next||34==e.next){if(!K(e,!0))return!1}else if(93==e.next||125==e.next){if(t[t.length-1]!=e.next-2)return!1;if(t.pop(),e.advance(),!t.length)return!0}else{if(e.next<0||e.pos>n||L(e.next))return!1;e.advance()}}const X="iiisiiissisfissssssssssssisssiiissssssssssssssssssssssssssfsfssissssssssssssssssssssssssssfif";function Y(e){return e<33?"u":e>125?"s":X[e-33]}function Z(e,t){let n=Y(e);return"u"!=n&&!(t&&"f"==n)}function J(e,t,n,r){if("s"!=Y(e.next)&&(63!=e.next&&58!=e.next&&45!=e.next||!Z(e.peek(1),n)))return!1;e.advance();let i=e.pos;for(;;){let o=e.next,a=0,s=r+1;while(B(o)){if(L(o)){if(t)return!1;s=0}else s++;o=e.peek(++a)}let l=o>=0&&(58==o?Z(e.peek(a+1),n):35==o?32!=e.peek(a-1):Z(o,n));if(!l||!n&&s<=r||0==s&&!n&&(F(e,45,a)||F(e,46,a)))break;if(t&&"f"==Y(o))return!1;for(let t=a;t>=0;t--)e.advance();if(t&&e.pos>i+1024)return!1}return!0}const ee=new r.Lu((e,t)=>{if(33==e.next)Q(e),e.acceptToken(w);else if(38==e.next||42==e.next){let t=38==e.next?b:y;z(e),e.acceptToken(t)}else 39==e.next||34==e.next?(K(e,!1),e.acceptToken(v)):J(e,!1,t.context.type==N,t.context.depth)&&e.acceptToken(g)}),te=new r.Lu((e,t)=>{let n=t.context.type==P?t.context.depth:-1,r=e.pos;e:for(;;){let i=0,o=e.next;while(32==o)o=e.peek(++i);if(!i&&(F(e,45,i)||F(e,46,i)))break;if(!L(o)&&(n<0&&(n=Math.max(t.context.depth+1,i)),i<n))break;for(;;){if(e.next<0)break e;let t=L(e.next);if(e.advance(),t)continue e;r=e.pos}}e.acceptTokenTo(O,r)}),ne=(0,i.styleTags)({DirectiveName:i.tags.keyword,DirectiveContent:i.tags.attributeValue,"DirectiveEnd DocEnd":i.tags.meta,QuotedLiteral:i.tags.string,BlockLiteralHeader:i.tags.special(i.tags.string),BlockLiteralContent:i.tags.content,Literal:i.tags.content,"Key/Literal Key/QuotedLiteral":i.tags.definition(i.tags.propertyName),"Anchor Alias":i.tags.labelName,Tag:i.tags.typeName,Comment:i.tags.lineComment,": , -":i.tags.separator,"?":i.tags.punctuation,"[ ]":i.tags.squareBracket,"{ }":i.tags.brace}),re=r.U1.deserialize({version:14,states:"5lQ!ZQgOOO#PQfO'#CpO#uQfO'#DOOOQR'#Dv'#DvO$qQgO'#DRO%gQdO'#DUO%nQgO'#DUO&ROaO'#D[OOQR'#Du'#DuO&{QgO'#D^O'rQgO'#D`OOQR'#Dt'#DtO(iOqO'#DbOOQP'#Dj'#DjO(zQaO'#CmO)YQgO'#CmOOQP'#Cm'#CmQ)jQaOOQ)uQgOOQ]QgOOO*PQdO'#CrO*nQdO'#CtOOQO'#Dw'#DwO+]Q`O'#CxO+hQdO'#CwO+rQ`O'#CwOOQO'#Cv'#CvO+wQdO'#CvOOQO'#Cq'#CqO,UQ`O,59[O,^QfO,59[OOQR,59[,59[OOQO'#Cx'#CxO,eQ`O'#DPO,pQdO'#DPOOQO'#Dx'#DxO,zQdO'#DxO-XQ`O,59jO-aQfO,59jOOQR,59j,59jOOQR'#DS'#DSO-hQcO,59mO-sQgO'#DVO.TQ`O'#DVO.YQcO,59pOOQR'#DX'#DXO#|QfO'#DWO.hQcO'#DWOOQR,59v,59vO.yOWO,59vO/OOaO,59vO/WOaO,59vO/cQgO'#D_OOQR,59x,59xO0VQgO'#DaOOQR,59z,59zOOQP,59|,59|O0yOaO,59|O1ROaO,59|O1aOqO,59|OOQP-E7h-E7hO1oQgO,59XOOQP,59X,59XO2PQaO'#DeO2_QgO'#DeO2oQgO'#DkOOQP'#Dk'#DkQ)jQaOOO3PQdO'#CsOOQO,59^,59^O3kQdO'#CuOOQO,59`,59`OOQO,59c,59cO4VQdO,59cO4aQdO'#CzO4kQ`O'#CzOOQO,59b,59bOOQU,5:Q,5:QOOQR1G.v1G.vO4pQ`O1G.vOOQU-E7d-E7dO4xQdO,59kOOQO,59k,59kO5SQdO'#DQO5^Q`O'#DQOOQO,5:d,5:dOOQU,5:R,5:ROOQR1G/U1G/UO5cQ`O1G/UOOQU-E7e-E7eO5kQgO'#DhO5xQcO1G/XOOQR1G/X1G/XOOQR,59q,59qO6TQgO,59qO6eQdO'#DiO6lQgO'#DiO7PQcO1G/[OOQR1G/[1G/[OOQR,59r,59rO#|QfO,59rOOQR1G/b1G/bO7_OWO1G/bO7dOaO1G/bOOQR,59y,59yOOQR,59{,59{OOQP1G/h1G/hO7lOaO1G/hO7tOaO1G/hO8POaO1G/hOOQP1G.s1G.sO8_QgO,5:POOQP,5:P,5:POOQP,5:V,5:VOOQP-E7i-E7iOOQO,59_,59_OOQO,59a,59aOOQO1G.}1G.}OOQO,59f,59fO8oQdO,59fOOQR7+$b7+$bP,XQ`O'#DfOOQO1G/V1G/VOOQO,59l,59lO8yQdO,59lOOQR7+$p7+$pP9TQ`O'#DgOOQR'#DT'#DTOOQR,5:S,5:SOOQR-E7f-E7fOOQR7+$s7+$sOOQR1G/]1G/]O9YQgO'#DYO9jQ`O'#DYOOQR,5:T,5:TO#|QfO'#DZO9oQcO'#DZOOQR-E7g-E7gOOQR7+$v7+$vOOQR1G/^1G/^OOQR7+$|7+$|O:QOWO7+$|OOQP7+%S7+%SO:VOaO7+%SO:_OaO7+%SOOQP1G/k1G/kOOQO1G/Q1G/QOOQO1G/W1G/WOOQR,59t,59tO:jQgO,59tOOQR,59u,59uO#|QfO,59uOOQR<<Hh<<HhOOQP<<Hn<<HnO:zOaO<<HnOOQR1G/`1G/`OOQR1G/a1G/aOOQPAN>YAN>Y",stateData:";S~O!fOS!gOS^OS~OP_OQbORSOTUOWROXROYYOZZO[XOcPOqQO!PVO!V[O!cTO~O`cO~P]OVkOWROXROYeOZfO[dOcPOmhOqQO~OboO~P!bOVtOWROXROYeOZfO[dOcPOmrOqQO~OpwO~P#WORSOTUOWROXROYYOZZO[XOcPOqQO!PVO!cTO~OSvP!avP!bvP~P#|OWROXROYeOZfO[dOcPOqQO~OmzO~P%OOm!OOUzP!azP!bzP!dzP~P#|O^!SO!b!QO!f!TO!g!RO~ORSOTUOWROXROcPOqQO!PVO!cTO~OY!UOP!QXQ!QX!V!QX!`!QXS!QX!a!QX!b!QXU!QXm!QX!d!QX~P&aO[!WOP!SXQ!SX!V!SX!`!SXS!SX!a!SX!b!SXU!SXm!SX!d!SX~P&aO^!ZO!W![O!b!YO!f!]O!g!YO~OP!_O!V[OQaX!`aX~OPaXQaX!VaX!`aX~P#|OP!bOQ!cO!V[O~OP_O!V[O~P#|OWROXROY!fOcPOqQObfXmfXofXpfX~OWROXRO[!hOcPOqQObhXmhXohXphX~ObeXmlXoeX~ObkXokX~P%OOm!kO~Om!lObnPonP~P%OOb!pOo!oO~Ob!pO~P!bOm!sOosXpsX~OosXpsX~P%OOm!uOotPptP~P%OOo!xOp!yO~Op!yO~P#WOS!|O!a#OO!b#OO~OUyX!ayX!byX!dyX~P#|Om#QO~OU#SO!a#UO!b#UO!d#RO~Om#WOUzX!azX!bzX!dzX~O]#XO~O!b#XO!g#YO~O^#ZO!b#XO!g#YO~OP!RXQ!RX!V!RX!`!RXS!RX!a!RX!b!RXU!RXm!RX!d!RX~P&aOP!TXQ!TX!V!TX!`!TXS!TX!a!TX!b!TXU!TXm!TX!d!TX~P&aO!b#^O!g#^O~O^#_O!b#^O!f#`O!g#^O~O^#_O!W#aO!b#^O!g#^O~OPaaQaa!Vaa!`aa~P#|OP#cO!V[OQ!XX!`!XX~OP!XXQ!XX!V!XX!`!XX~P#|OP_O!V[OQ!_X!`!_X~P#|OWROXROcPOqQObgXmgXogXpgX~OWROXROcPOqQObiXmiXoiXpiX~Obkaoka~P%OObnXonX~P%OOm#kO~Ob#lOo!oO~Oosapsa~P%OOotXptX~P%OOm#pO~Oo!xOp#qO~OSwP!awP!bwP~P#|OS!|O!a#vO!b#vO~OUya!aya!bya!dya~P#|Om#xO~P%OOm#{OU}P!a}P!b}P!d}P~P#|OU#SO!a$OO!b$OO!d#RO~O]$QO~O!b$QO!g$RO~O!b$SO!g$SO~O^$TO!b$SO!g$SO~O^$TO!b$SO!f$UO!g$SO~OP!XaQ!Xa!V!Xa!`!Xa~P#|Obnaona~P%OOotapta~P%OOo!xO~OU|X!a|X!b|X!d|X~P#|Om$ZO~Om$]OU}X!a}X!b}X!d}X~O]$^O~O!b$_O!g$_O~O^$`O!b$_O!g$_O~OU|a!a|a!b|a!d|a~P#|O!b$cO!g$cO~O",goto:",]!mPPPPPPPPPPPPPPPPP!nPP!v#v#|$`#|$c$f$j$nP%VPPP!v%Y%^%a%{&O%a&R&U&X&_&b%aP&e&{&e'O'RPP']'a'g'm's'y(XPPPPPPPP(_)e*X+c,VUaObcR#e!c!{ROPQSTUXY_bcdehknrtvz!O!U!W!_!b!c!f!h!k!l!s!u!|#Q#R#S#W#c#k#p#x#{$Z$]QmPR!qnqfPQThknrtv!k!l!s!u#R#k#pR!gdR!ieTlPnTjPnSiPnSqQvQ{TQ!mkQ!trQ!vtR#y#RR!nkTsQvR!wt!RWOSUXY_bcz!O!U!W!_!b!c!|#Q#S#W#c#x#{$Z$]RySR#t!|R|TR|UQ!PUR#|#SR#z#RR#z#SyZOSU_bcz!O!_!b!c!|#Q#S#W#c#x#{$Z$]R!VXR!XYa]O^abc!a!c!eT!da!eQnPR!rnQvQR!{vQ!}yR#u!}Q#T|R#}#TW^Obc!cS!^^!aT!aa!eQ!eaR#f!eW`Obc!cQxSS}U#SQ!`_Q#PzQ#V!OQ#b!_Q#d!bQ#s!|Q#w#QQ$P#WQ$V#cQ$Y#xQ$[#{Q$a$ZR$b$]xZOSU_bcz!O!_!b!c!|#Q#S#W#c#x#{$Z$]Q!VXQ!XYQ#[!UR#]!W!QWOSUXY_bcz!O!U!W!_!b!c!|#Q#S#W#c#x#{$Z$]pfPQThknrtv!k!l!s!u#R#k#pQ!gdQ!ieQ#g!fR#h!hSgPn^pQTkrtv#RQ!jhQ#i!kQ#j!lQ#n!sQ#o!uQ$W#kR$X#pQuQR!zv",nodeNames:"⚠ DirectiveEnd DocEnd - - ? ? ? Literal QuotedLiteral Anchor Alias Tag BlockLiteralContent Comment Stream BOM Document ] [ FlowSequence Item Tagged Anchored Anchored Tagged FlowMapping Pair Key : Pair , } { FlowMapping Pair Pair BlockSequence Item Item BlockMapping Pair Pair Key Pair Pair BlockLiteral BlockLiteralHeader Tagged Anchored Anchored Tagged Directive DirectiveName DirectiveContent Document",maxTerm:74,context:V,nodeProps:[["isolate",-3,8,9,14,""],["openedBy",18,"[",32,"{"],["closedBy",19,"]",33,"}"]],propSources:[ne],skippedNodes:[0],repeatNodeCount:6,tokenData:"-Y~RnOX#PXY$QYZ$]Z]#P]^$]^p#Ppq$Qqs#Pst$btu#Puv$yv|#P|}&e}![#P![!]'O!]!`#P!`!a'i!a!}#P!}#O*g#O#P#P#P#Q+Q#Q#o#P#o#p+k#p#q'i#q#r,U#r;'S#P;'S;=`#z<%l?HT#P?HT?HU,o?HUO#PQ#UU!WQOY#PZp#Ppq#hq;'S#P;'S;=`#z<%lO#PQ#kTOY#PZs#Pt;'S#P;'S;=`#z<%lO#PQ#}P;=`<%l#P~$VQ!f~XY$Qpq$Q~$bO!g~~$gS^~OY$bZ;'S$b;'S;=`$s<%lO$b~$vP;=`<%l$bR%OX!WQOX%kXY#PZ]%k]^#P^p%kpq#hq;'S%k;'S;=`&_<%lO%kR%rX!WQ!VPOX%kXY#PZ]%k]^#P^p%kpq#hq;'S%k;'S;=`&_<%lO%kR&bP;=`<%l%kR&lUoP!WQOY#PZp#Ppq#hq;'S#P;'S;=`#z<%lO#PR'VUmP!WQOY#PZp#Ppq#hq;'S#P;'S;=`#z<%lO#PR'p[!PP!WQOY#PZp#Ppq#hq{#P{|(f|}#P}!O(f!O!R#P!R![)p![;'S#P;'S;=`#z<%lO#PR(mW!PP!WQOY#PZp#Ppq#hq!R#P!R![)V![;'S#P;'S;=`#z<%lO#PR)^U!PP!WQOY#PZp#Ppq#hq;'S#P;'S;=`#z<%lO#PR)wY!PP!WQOY#PZp#Ppq#hq{#P{|)V|}#P}!O)V!O;'S#P;'S;=`#z<%lO#PR*nUcP!WQOY#PZp#Ppq#hq;'S#P;'S;=`#z<%lO#PR+XUbP!WQOY#PZp#Ppq#hq;'S#P;'S;=`#z<%lO#PR+rUqP!WQOY#PZp#Ppq#hq;'S#P;'S;=`#z<%lO#PR,]UpP!WQOY#PZp#Ppq#hq;'S#P;'S;=`#z<%lO#PR,vU`P!WQOY#PZp#Ppq#hq;'S#P;'S;=`#z<%lO#P",tokenizers:[j,U,ee,te,0,1],topRules:{Stream:[0,15]},tokenPrec:0});var ie=n(61163),oe=n(43114);const ae=r.U1.deserialize({version:14,states:"!vOQOPOOO]OPO'#C_OhOPO'#C^OOOO'#Cc'#CcOpOPO'#CaQOOOOOO{OPOOOOOO'#Cb'#CbO!WOPO'#C`O!`OPO,58xOOOO-E6a-E6aOOOO-E6`-E6`OOOO'#C_'#C_OOOO1G.d1G.d",stateData:"!h~OXPOYROWTP~OWVXXRXYRX~OYVOXSP~OXROYROWTX~OXROYROWTP~OYVOXSX~OX[O~OXY~",goto:"vWPPX[beioRUOQQOR]XRXQTTOUQWQRZWSSOURYS",nodeNames:"⚠ Document Frontmatter DashLine FrontmatterContent Body",maxTerm:10,skippedNodes:[0],repeatNodeCount:2,tokenData:"$z~RXOYnYZ!^Z]n]^!^^}n}!O!i!O;'Sn;'S;=`!c<%lOn~qXOYnYZ!^Z]n]^!^^;'Sn;'S;=`!c<%l~n~On~~!^~!cOY~~!fP;=`<%ln~!lZOYnYZ!^Z]n]^!^^}n}!O#_!O;'Sn;'S;=`!c<%l~n~On~~!^~#bZOYnYZ!^Z]n]^!^^}n}!O$T!O;'Sn;'S;=`!c<%l~n~On~~!^~$WXOYnYZ$sZ]n]^$s^;'Sn;'S;=`!c<%l~n~On~~$s~$zOX~Y~",tokenizers:[0],topRules:{Document:[0,1]},tokenPrec:67}),se=ie.LRLanguage.define({name:"yaml",parser:re.configure({props:[ie.indentNodeProp.add({Stream:e=>{for(let t=e.node.resolve(e.pos,-1);t&&t.to>=e.pos;t=t.parent){if("BlockLiteralContent"==t.name&&t.from<t.to)return e.baseIndentFor(t);if("BlockLiteral"==t.name)return e.baseIndentFor(t)+e.unit;if("BlockSequence"==t.name||"BlockMapping"==t.name)return e.column(t.firstChild.from,1);if("QuotedLiteral"==t.name)return null;if("Literal"==t.name){let n=e.column(t.from,1);if(n==e.lineIndent(t.from,1))return n;if(t.to>e.pos)return null}}return null},FlowMapping:(0,ie.delimitedIndent)({closing:"}"}),FlowSequence:(0,ie.delimitedIndent)({closing:"]"})}),ie.foldNodeProp.add({"FlowMapping FlowSequence":ie.foldInside,"Item Pair BlockLiteral":(e,t)=>({from:t.doc.lineAt(e.from).to,to:e.to})})]}),languageData:{commentTokens:{line:"#"},indentOnInput:/^\s*[\]\}]$/}});function le(){return new ie.LanguageSupport(se)}const ce=ie.LRLanguage.define({name:"yaml-frontmatter",parser:ae.configure({props:[(0,i.styleTags)({DashLine:i.tags.meta})]})});function ue(e){let{language:t,support:n}=e.content instanceof ie.LanguageSupport?e.content:{language:e.content,support:[]};return new ie.LanguageSupport(ce.configure({wrap:(0,oe.parseMixed)(e=>"FrontmatterContent"==e.name?{parser:se.parser}:"Body"==e.name?{parser:t.parser}:null)}),n)}},75982:function(e,t,n){"use strict";n.r(t),n.d(t,{closeLintPanel:function(){return O},diagnosticCount:function(){return g},forEachDiagnostic:function(){return ee},forceLinting:function(){return R},lintGutter:function(){return J},lintKeymap:function(){return x},linter:function(){return T},nextDiagnostic:function(){return S},openLintPanel:function(){return w},previousDiagnostic:function(){return E},setDiagnostics:function(){return d},setDiagnosticsEffect:function(){return h}});var r=n(81068),i=n(76528),o=n(20941);class a{constructor(e,t,n){this.from=e,this.to=t,this.diagnostic=n}}class s{constructor(e,t,n){this.diagnostics=e,this.panel=t,this.selected=n}static init(e,t,n){let o=n.facet(C).markerFilter;o&&(e=o(e,n));let a=e.slice().sort((e,t)=>e.from-t.from||e.to-t.to),c=new i.RangeSetBuilder,u=[],d=0,h=n.doc.iter(),p=0,f=n.doc.length;for(let i=0;;){let e,t,n=i==a.length?null:a[i];if(!n&&!u.length)break;if(u.length)e=d,t=u.reduce((e,t)=>Math.min(e,t.to),n&&n.from>e?n.from:1e8);else{if(e=n.from,e>f)break;t=n.to,u.push(n),i++}while(i<a.length){let n=a[i];if(n.from!=e||!(n.to>n.from||n.to==e)){t=Math.min(n.from,t);break}u.push(n),i++,t=Math.min(n.to,t)}t=Math.min(t,f);let o=!1;if(u.some(n=>n.from==e&&(n.to==t||t==f))&&(o=e==t,!o&&t-e<10)){let n=e-(p+h.value.length);n>0&&(h.next(n),p=e);for(let r=e;;){if(r>=t){o=!0;break}if(!h.lineBreak&&p+h.value.length>r)break;r=p+h.value.length,p+=h.value.length,h.next()}}let s=F(u);if(o)c.add(e,e,r.Decoration.widget({widget:new I(s),diagnostics:u.slice()}));else{let n=u.reduce((e,t)=>t.markClass?e+" "+t.markClass:e,"");c.add(e,t,r.Decoration.mark({class:"cm-lintRange cm-lintRange-"+s+n,diagnostics:u.slice(),inclusiveEnd:u.some(e=>e.to>t)}))}if(d=t,d==f)break;for(let r=0;r<u.length;r++)u[r].to<=d&&u.splice(r--,1)}let m=c.finish();return new s(m,t,l(m))}}function l(e,t=null,n=0){let r=null;return e.between(n,1e9,(e,n,{spec:i})=>{if(!(t&&i.diagnostics.indexOf(t)<0))if(r){if(i.diagnostics.indexOf(r.diagnostic)<0)return!1;r=new a(r.from,n,r.diagnostic)}else r=new a(e,n,t||i.diagnostics[0])}),r}function c(e,t){let n=t.pos,r=t.end||n,i=e.state.facet(C).hideOn(e,n,r);if(null!=i)return i;let o=e.startState.doc.lineAt(t.pos);return!(!e.effects.some(e=>e.is(h))&&!e.changes.touchesRange(o.from,Math.max(o.to,r)))}function u(e,t){return e.field(m,!1)?t:t.concat(i.StateEffect.appendConfig.of(Y))}function d(e,t){return{effects:u(e,[h.of(t)])}}const h=i.StateEffect.define(),p=i.StateEffect.define(),f=i.StateEffect.define(),m=i.StateField.define({create(){return new s(r.Decoration.none,null,null)},update(e,t){if(t.docChanged&&e.diagnostics.size){let n=e.diagnostics.map(t.changes),r=null,i=e.panel;if(e.selected){let i=t.changes.mapPos(e.selected.from,1);r=l(n,e.selected.diagnostic,i)||l(n,null,i)}!n.size&&i&&t.state.facet(C).autoPanel&&(i=null),e=new s(n,i,r)}for(let n of t.effects)if(n.is(h)){let r=t.state.facet(C).autoPanel?n.value.length?D.open:null:e.panel;e=s.init(n.value,r,t.state)}else n.is(p)?e=new s(e.diagnostics,n.value?D.open:null,e.selected):n.is(f)&&(e=new s(e.diagnostics,e.panel,n.value));return e},provide:e=>[r.showPanel.from(e,e=>e.panel),r.EditorView.decorations.from(e,e=>e.diagnostics)]});function g(e){let t=e.field(m,!1);return t?t.diagnostics.size:0}const v=r.Decoration.mark({class:"cm-lintRange cm-lintRange-active"});function b(e,t,n){let r,{diagnostics:i}=e.state.field(m),o=-1,a=-1;i.between(t-(n<0?1:0),t+(n>0?1:0),(e,i,{spec:s})=>{if(t>=e&&t<=i&&(e==i||(t>e||n>0)&&(t<i||n<0)))return r=s.diagnostics,o=e,a=i,!1});let s=e.state.facet(C).tooltipFilter;return r&&s&&(r=s(r,e.state)),r?{pos:o,end:a,above:!0,create(){return{dom:y(e,r)}}}:null}function y(e,t){return(0,o.A)("ul",{class:"cm-tooltip-lint"},t.map(t=>P(e,t,!1)))}const w=e=>{let t=e.state.field(m,!1);t&&t.panel||e.dispatch({effects:u(e.state,[p.of(!0)])});let n=(0,r.getPanel)(e,D.open);return n&&n.dom.querySelector(".cm-panel-lint ul").focus(),!0},O=e=>{let t=e.state.field(m,!1);return!(!t||!t.panel)&&(e.dispatch({effects:p.of(!1)}),!0)},S=e=>{let t=e.state.field(m,!1);if(!t)return!1;let n=e.state.selection.main,i=l(t.diagnostics,null,n.to+1);return!(!i&&(i=l(t.diagnostics,null,0),!i||i.from==n.from&&i.to==n.to))&&(e.dispatch({selection:{anchor:i.from,head:i.to},scrollIntoView:!0}),(0,r.activateHover)(e,i.from,1,{tooltip:X,until:e=>e.docChanged||e.newSelection.main.head<i.from||e.newSelection.main.head>i.to}),!0)},E=e=>{var t;let{state:n}=e,i=n.field(m,!1);if(!i)return!1;let o,a,s,l,c=n.selection.main;if(i.diagnostics.between(0,n.doc.length,(e,t)=>{t<c.to&&(null==o||o<e)&&(o=e,a=t),(null==s||e>s)&&(s=e,l=t)}),null==s||null==o&&s==c.from)return!1;let u=null!==o&&void 0!==o?o:s,d=null!==(t=null!==a&&void 0!==a?a:l)&&void 0!==t?t:u;return e.dispatch({selection:{anchor:u,head:d},scrollIntoView:!0}),(0,r.activateHover)(e,u,1,{tooltip:X,until:e=>e.docChanged||e.newSelection.main.head<u||e.newSelection.main.head>d}),!0},x=[{key:"Mod-Shift-m",run:w,preventDefault:!0},{key:"F8",run:S}],_=r.ViewPlugin.fromClass(class{constructor(e){this.view=e,this.timeout=-1,this.set=!0;let{delay:t}=e.state.facet(C);this.lintTime=Date.now()+t,this.run=this.run.bind(this),this.timeout=setTimeout(this.run,t)}run(){clearTimeout(this.timeout);let e=Date.now();if(e<this.lintTime-10)this.timeout=setTimeout(this.run,this.lintTime-e);else{this.set=!1;let{state:e}=this.view,{sources:t}=e.facet(C);t.length&&k(t.map(e=>Promise.resolve(e(this.view))),t=>{this.view.state.doc==e.doc&&this.view.dispatch(d(this.view.state,t.reduce((e,t)=>e.concat(t))))},e=>{(0,r.logException)(this.view.state,e)})}}update(e){let t=e.state.facet(C);(e.docChanged||t!=e.startState.facet(C)||t.needsRefresh&&t.needsRefresh(e))&&(this.lintTime=Date.now()+t.delay,this.set||(this.set=!0,this.timeout=setTimeout(this.run,t.delay)))}force(){this.set&&(this.lintTime=Date.now(),this.run())}destroy(){clearTimeout(this.timeout)}});function k(e,t,n){let r=[],i=-1;for(let o of e)o.then(n=>{r.push(n),clearTimeout(i),r.length==e.length?t(r):i=setTimeout(()=>t(r),200)},n)}const C=i.Facet.define({combine(e){return{sources:e.map(e=>e.source).filter(e=>null!=e),...(0,i.combineConfig)(e.map(e=>e.config),{delay:750,markerFilter:null,tooltipFilter:null,needsRefresh:null,hideOn:()=>null},{delay:Math.max,markerFilter:A,tooltipFilter:A,needsRefresh:(e,t)=>e?t?n=>e(n)||t(n):e:t,hideOn:(e,t)=>e?t?(n,r,i)=>e(n,r,i)||t(n,r,i):e:t,autoPanel:(e,t)=>e||t})}}});function A(e,t){return e?t?(n,r)=>t(e(n,r),r):e:t}function T(e,t={}){return[C.of({source:e,config:t}),_,Y]}function R(e){let t=e.plugin(_);t&&t.force()}function N(e){let t=[];if(e)e:for(let{name:n}of e){for(let e=0;e<n.length;e++){let r=n[e];if(/[a-zA-Z]/.test(r)&&!t.some(e=>e.toLowerCase()==r.toLowerCase())){t.push(r);continue e}}t.push("")}return t}function P(e,t,n){var r;let i=n?N(t.actions):[];return(0,o.A)("li",{class:"cm-diagnostic cm-diagnostic-"+t.severity},(0,o.A)("span",{class:"cm-diagnosticText"},t.renderMessage?t.renderMessage(e):t.message),null===(r=t.actions)||void 0===r?void 0:r.map((n,r)=>{let a=!1,s=r=>{if(r.preventDefault(),a)return;a=!0;let i=l(e.state.field(m).diagnostics,t);i&&n.apply(e,i.from,i.to)},{name:c}=n,u=i[r]?c.indexOf(i[r]):-1,d=u<0?c:[c.slice(0,u),(0,o.A)("u",c.slice(u,u+1)),c.slice(u+1)],h=n.markClass?" "+n.markClass:"";return(0,o.A)("button",{type:"button",class:"cm-diagnosticAction"+h,onclick:s,onmousedown:s,"aria-label":` Action: ${c}${u<0?"":` (access key "${i[r]})"`}.`},d)}),t.source&&(0,o.A)("div",{class:"cm-diagnosticSource"},t.source))}class I extends r.WidgetType{constructor(e){super(),this.sev=e}eq(e){return e.sev==this.sev}toDOM(){return(0,o.A)("span",{class:"cm-lintPoint cm-lintPoint-"+this.sev})}}class M{constructor(e,t){this.diagnostic=t,this.id="item_"+Math.floor(4294967295*Math.random()).toString(16),this.dom=P(e,t,!0),this.dom.id=this.id,this.dom.setAttribute("role","option")}}class D{constructor(e){this.view=e,this.items=[];let t=t=>{if(!(t.ctrlKey||t.altKey||t.metaKey)){if(27==t.keyCode)O(this.view),this.view.focus();else if(38==t.keyCode||33==t.keyCode)this.moveSelection((this.selectedIndex-1+this.items.length)%this.items.length);else if(40==t.keyCode||34==t.keyCode)this.moveSelection((this.selectedIndex+1)%this.items.length);else if(36==t.keyCode)this.moveSelection(0);else if(35==t.keyCode)this.moveSelection(this.items.length-1);else if(13==t.keyCode)this.view.focus();else{if(!(t.keyCode>=65&&t.keyCode<=90&&this.selectedIndex>=0))return;{let{diagnostic:n}=this.items[this.selectedIndex],r=N(n.actions);for(let i=0;i<r.length;i++)if(r[i].toUpperCase().charCodeAt(0)==t.keyCode){let t=l(this.view.state.field(m).diagnostics,n);t&&n.actions[i].apply(e,t.from,t.to)}}}t.preventDefault()}},n=e=>{for(let t=0;t<this.items.length;t++)this.items[t].dom.contains(e.target)&&this.moveSelection(t)};this.list=(0,o.A)("ul",{tabIndex:0,role:"listbox","aria-label":this.view.state.phrase("Diagnostics"),onkeydown:t,onclick:n}),this.dom=(0,o.A)("div",{class:"cm-panel-lint"},this.list,(0,o.A)("button",{type:"button",name:"close","aria-label":this.view.state.phrase("close"),onclick:()=>O(this.view)},"×")),this.update()}get selectedIndex(){let e=this.view.state.field(m).selected;if(!e)return-1;for(let t=0;t<this.items.length;t++)if(this.items[t].diagnostic==e.diagnostic)return t;return-1}update(){let{diagnostics:e,selected:t}=this.view.state.field(m),n=0,r=!1,i=null,o=new Set;e.between(0,this.view.state.doc.length,(e,a,{spec:s})=>{for(let l of s.diagnostics){if(o.has(l))continue;o.add(l);let e,a=-1;for(let t=n;t<this.items.length;t++)if(this.items[t].diagnostic==l){a=t;break}a<0?(e=new M(this.view,l),this.items.splice(n,0,e),r=!0):(e=this.items[a],a>n&&(this.items.splice(n,a-n),r=!0)),t&&e.diagnostic==t.diagnostic?e.dom.hasAttribute("aria-selected")||(e.dom.setAttribute("aria-selected","true"),i=e):e.dom.hasAttribute("aria-selected")&&e.dom.removeAttribute("aria-selected"),n++}});while(n<this.items.length&&!(1==this.items.length&&this.items[0].diagnostic.from<0))r=!0,this.items.pop();0==this.items.length&&(this.items.push(new M(this.view,{from:-1,to:-1,severity:"info",message:this.view.state.phrase("No diagnostics")})),r=!0),i?(this.list.setAttribute("aria-activedescendant",i.id),this.view.requestMeasure({key:this,read:()=>({sel:i.dom.getBoundingClientRect(),panel:this.list.getBoundingClientRect()}),write:({sel:e,panel:t})=>{let n=t.height/this.list.offsetHeight;e.top<t.top?this.list.scrollTop-=(t.top-e.top)/n:e.bottom>t.bottom&&(this.list.scrollTop+=(e.bottom-t.bottom)/n)}})):this.selectedIndex<0&&this.list.removeAttribute("aria-activedescendant"),r&&this.sync()}sync(){let e=this.list.firstChild;function t(){let t=e;e=t.nextSibling,t.remove()}for(let n of this.items)if(n.dom.parentNode==this.list){while(e!=n.dom)t();e=n.dom.nextSibling}else this.list.insertBefore(n.dom,e);while(e)t()}moveSelection(e){if(this.selectedIndex<0)return;let t=this.view.state.field(m),n=l(t.diagnostics,this.items[e].diagnostic);n&&this.view.dispatch({selection:{anchor:n.from,head:n.to},scrollIntoView:!0,effects:f.of(n)})}static open(e){return new D(e)}}function L(e,t='viewBox="0 0 40 40"'){return`url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" ${t}>${encodeURIComponent(e)}</svg>')`}function B(e){return L(`<path d="m0 2.5 l2 -1.5 l1 0 l2 1.5 l1 0" stroke="${e}" fill="none" stroke-width=".7"/>`,'width="6" height="3"')}const $=r.EditorView.baseTheme({".cm-diagnostic":{padding:"3px 6px 3px 8px",marginLeft:"-1px",display:"block",whiteSpace:"pre-wrap"},".cm-diagnostic-error":{borderLeft:"5px solid #d11"},".cm-diagnostic-warning":{borderLeft:"5px solid orange"},".cm-diagnostic-info":{borderLeft:"5px solid #999"},".cm-diagnostic-hint":{borderLeft:"5px solid #66d"},".cm-diagnosticAction":{font:"inherit",border:"none",padding:"2px 4px",backgroundColor:"#444",color:"white",borderRadius:"3px",marginLeft:"8px",cursor:"pointer"},".cm-diagnosticSource":{fontSize:"70%",opacity:.7},".cm-lintRange":{backgroundPosition:"left bottom",backgroundRepeat:"repeat-x",paddingBottom:"0.7px"},".cm-lintRange-error":{backgroundImage:B("#f11")},".cm-lintRange-warning":{backgroundImage:B("orange")},".cm-lintRange-info":{backgroundImage:B("#999")},".cm-lintRange-hint":{backgroundImage:B("#66d")},".cm-lintRange-active":{backgroundColor:"#ffdd9980"},".cm-tooltip-lint":{padding:0,margin:0},".cm-lintPoint":{position:"relative","&:after":{content:'""',position:"absolute",bottom:0,left:"-2px",borderLeft:"3px solid transparent",borderRight:"3px solid transparent",borderBottom:"4px solid #d11"}},".cm-lintPoint-warning":{"&:after":{borderBottomColor:"orange"}},".cm-lintPoint-info":{"&:after":{borderBottomColor:"#999"}},".cm-lintPoint-hint":{"&:after":{borderBottomColor:"#66d"}},".cm-panel.cm-panel-lint":{position:"relative","& ul":{maxHeight:"100px",overflowY:"auto","& [aria-selected]":{backgroundColor:"#ddd","& u":{textDecoration:"underline"}},"&:focus [aria-selected]":{background_fallback:"#bdf",backgroundColor:"Highlight",color_fallback:"white",color:"HighlightText"},"& u":{textDecoration:"none"},padding:0,margin:0},"& [name=close]":{position:"absolute",top:"0",right:"2px",background:"inherit",border:"none",font:"inherit",padding:0,margin:0}},"&dark .cm-lintRange-active":{backgroundColor:"#86714a80"},"&dark .cm-panel.cm-panel-lint ul":{"& [aria-selected]":{backgroundColor:"#2e343e"}}});function V(e){return"error"==e?4:"warning"==e?3:"info"==e?2:1}function F(e){let t="hint",n=1;for(let r of e){let e=V(r.severity);e>n&&(n=e,t=r.severity)}return t}class j extends r.GutterMarker{constructor(e){super(),this.diagnostics=e,this.severity=F(e)}toDOM(e){let t=document.createElement("div");t.className="cm-lint-marker cm-lint-marker-"+this.severity;let n=this.diagnostics,r=e.state.facet(Z).tooltipFilter;return r&&(n=r(n,e.state)),n.length&&(t.onmouseover=()=>G(e,t,n)),t}}function U(e,t){let n=r=>{let i=t.getBoundingClientRect();if(!(r.clientX>i.left-10&&r.clientX<i.right+10&&r.clientY>i.top-10&&r.clientY<i.bottom+10)){for(let e=r.target;e;e=e.parentNode)if(1==e.nodeType&&e.classList.contains("cm-tooltip-lint"))return;window.removeEventListener("mousemove",n),e.state.field(K)&&e.dispatch({effects:z.of(null)})}};window.addEventListener("mousemove",n)}function G(e,t,n){function r(){let r=e.elementAtHeight(t.getBoundingClientRect().top+5-e.documentTop);const i=e.coordsAtPos(r.from);i&&e.dispatch({effects:z.of({pos:r.from,above:!1,clip:!1,create(){return{dom:y(e,n),getCoords:()=>t.getBoundingClientRect()}}})}),t.onmouseout=t.onmousemove=null,U(e,t)}let{hoverTime:i}=e.state.facet(Z),o=setTimeout(r,i);t.onmouseout=()=>{clearTimeout(o),t.onmouseout=t.onmousemove=null},t.onmousemove=()=>{clearTimeout(o),o=setTimeout(r,i)}}function H(e,t){let n=Object.create(null);for(let i of t){let t=e.lineAt(i.from);(n[t.from]||(n[t.from]=[])).push(i)}let r=[];for(let i in n)r.push(new j(n[i]).range(+i));return i.RangeSet.of(r,!0)}const q=(0,r.gutter)({class:"cm-gutter-lint",markers:e=>e.state.field(Q),widgetMarker:(e,t,n)=>{let r=[];return e.state.field(Q).between(n.from,n.to,(e,t,i)=>{e>n.from&&e<n.to&&r.push(...i.diagnostics)}),r.length?new j(r):null}}),Q=i.StateField.define({create(){return i.RangeSet.empty},update(e,t){e=e.map(t.changes);let n=t.state.facet(Z).markerFilter;for(let r of t.effects)if(r.is(h)){let i=r.value;n&&(i=n(i||[],t.state)),e=H(t.state.doc,i.slice(0))}return e}}),z=i.StateEffect.define(),K=i.StateField.define({create(){return null},update(e,t){return e&&t.docChanged&&(e=c(t,e)?null:{...e,pos:t.changes.mapPos(e.pos)}),t.effects.reduce((e,t)=>t.is(z)?t.value:e,e)},provide:e=>r.showTooltip.from(e)}),W=r.EditorView.baseTheme({".cm-gutter-lint":{width:"1.4em","& .cm-gutterElement":{padding:".2em"}},".cm-lint-marker":{width:"1em",height:"1em"},".cm-lint-marker-info":{content:L('<path fill="#aaf" stroke="#77e" stroke-width="6" stroke-linejoin="round" d="M5 5L35 5L35 35L5 35Z"/>')},".cm-lint-marker-warning":{content:L('<path fill="#fe8" stroke="#fd7" stroke-width="6" stroke-linejoin="round" d="M20 6L37 35L3 35Z"/>')},".cm-lint-marker-error":{content:L('<circle cx="20" cy="20" r="15" fill="#f87" stroke="#f43" stroke-width="6"/>')}}),X=(0,r.hoverTooltip)(b,{hideOn:c}),Y=[m,r.EditorView.decorations.compute([m],e=>{let{selected:t,panel:n}=e.field(m);return t&&n&&t.from!=t.to?r.Decoration.set([v.range(t.from,t.to)]):r.Decoration.none}),X,$],Z=i.Facet.define({combine(e){return(0,i.combineConfig)(e,{hoverTime:300,markerFilter:null,tooltipFilter:null})}});function J(e={}){return[Z.of(e),Q,q,W,K]}function ee(e,t){let n=e.field(m,!1);if(n&&n.diagnostics.size){let e=[],r=[],o=-1;for(let a=i.RangeSet.iter([n.diagnostics]);;a.next()){for(let n=0;n<e.length;n++)(!a.value||a.value.spec.diagnostics.indexOf(e[n])<0)&&(t(e[n],r[n],o),e.splice(n,1),r.splice(n--,1));if(!a.value)break;for(let t of a.value.spec.diagnostics)e.indexOf(t)<0&&(e.push(t),r.push(a.from));o=a.to}}}},59509:function(e,t,n){"use strict";n.r(t),n.d(t,{RegExpCursor:function(){return u},SearchCursor:function(){return s},SearchQuery:function(){return N},closeSearchPanel:function(){return ue},findNext:function(){return J},findPrevious:function(){return ee},getSearchQuery:function(){return Q},gotoLine:function(){return g},highlightSelectionMatches:function(){return y},openSearchPanel:function(){return ce},replaceAll:function(){return ie},replaceNext:function(){return re},search:function(){return R},searchKeymap:function(){return de},searchPanelOpen:function(){return z},selectMatches:function(){return te},selectNextOccurrence:function(){return A},selectSelectionMatches:function(){return ne},setSearchQuery:function(){return G}});var r=n(81068),i=n(76528),o=n(20941);const a="function"==typeof String.prototype.normalize?e=>e.normalize("NFKD"):e=>e;class s{constructor(e,t,n=0,r=e.length,i,o){this.test=o,this.value={from:0,to:0,precise:!1},this.done=!1,this.matches=[],this.buffer="",this.bufferPos=0,this.iter=e.iterRange(n,r),this.bufferStart=n,this.normalize=i?e=>i(a(e)):a,this.query=this.normalize(t)}peek(){if(this.bufferPos==this.buffer.length){if(this.bufferStart+=this.buffer.length,this.iter.next(),this.iter.done)return-1;this.bufferPos=0,this.buffer=this.iter.value}return(0,i.codePointAt)(this.buffer,this.bufferPos)}next(){while(this.matches.length)this.matches.pop();return this.nextOverlapping()}nextOverlapping(){for(;;){let e=this.peek();if(e<0)return this.done=!0,this;let t=(0,i.fromCodePoint)(e),n=this.bufferStart+this.bufferPos;this.bufferPos+=(0,i.codePointSize)(e);let r=this.normalize(t);if(r.length)for(let i=0,o=n,a=!0;;i++){let e=r.charCodeAt(i),n=this.match(e,o,a,this.bufferPos+this.bufferStart,i==r.length-1);if(n)return this.value=n,this;if(i==r.length-1)break;a&&i<t.length&&t.charCodeAt(i)==e?o++:a=!1}}}match(e,t,n,r,i){let o=null;for(let a=0;a<this.matches.length;){let t=this.matches[a],n=!1;this.query.charCodeAt(t.index)==e&&(t.index==this.query.length-1?o={from:t.from,to:r,precise:i&&t.precise}:(t.index++,n=!0)),n?a++:this.matches.splice(a,1)}return this.query.charCodeAt(0)==e&&(1==this.query.length?o={from:t,to:r,precise:n&&i}:this.matches.push({from:t,index:1,precise:n})),o&&this.test&&!this.test(o.from,o.to,this.buffer,this.bufferStart)&&(o=null),o}}"undefined"!=typeof Symbol&&(s.prototype[Symbol.iterator]=function(){return this});const l={from:-1,to:-1,match:/.*/.exec(""),precise:!0},c="gm"+(null==/x/.unicode?"":"u");class u{constructor(e,t,n,r=0,i=e.length){if(this.text=e,this.to=i,this.curLine="",this.done=!1,this.value=l,/\\[sWDnr]|\n|\r|\[\^/.test(t))return new p(e,t,n,r,i);this.re=new RegExp(t,c+((null===n||void 0===n?void 0:n.ignoreCase)?"i":"")),this.test=null===n||void 0===n?void 0:n.test,this.iter=e.iter();let o=e.lineAt(r);this.curLineStart=o.from,this.matchPos=m(e,r),this.getLine(this.curLineStart)}getLine(e){this.iter.next(e),this.iter.lineBreak?this.curLine="":(this.curLine=this.iter.value,this.curLineStart+this.curLine.length>this.to&&(this.curLine=this.curLine.slice(0,this.to-this.curLineStart)),this.iter.next())}nextLine(){this.curLineStart=this.curLineStart+this.curLine.length+1,this.curLineStart>this.to?this.curLine="":this.getLine(0)}next(){for(let e=this.matchPos-this.curLineStart;;){this.re.lastIndex=e;let t=this.matchPos<=this.to&&this.re.exec(this.curLine);if(t){let n=this.curLineStart+t.index,r=n+t[0].length;if(this.matchPos=m(this.text,r+(n==r?1:0)),n==this.curLineStart+this.curLine.length&&this.nextLine(),(n<r||n>this.value.to)&&(!this.test||this.test(n,r,t)))return this.value={from:n,to:r,precise:!0,match:t},this;e=this.matchPos-this.curLineStart}else{if(!(this.curLineStart+this.curLine.length<this.to))return this.done=!0,this;this.nextLine(),e=0}}}}const d=new WeakMap;class h{constructor(e,t){this.from=e,this.text=t}get to(){return this.from+this.text.length}static get(e,t,n){let r=d.get(e);if(!r||r.from>=n||r.to<=t){let r=new h(t,e.sliceString(t,n));return d.set(e,r),r}if(r.from==t&&r.to==n)return r;let{text:i,from:o}=r;return o>t&&(i=e.sliceString(t,o)+i,o=t),r.to<n&&(i+=e.sliceString(r.to,n)),d.set(e,new h(o,i)),new h(t,i.slice(t-o,n-o))}}class p{constructor(e,t,n,r,i){this.text=e,this.to=i,this.done=!1,this.value=l,this.matchPos=m(e,r),this.re=new RegExp(t,c+((null===n||void 0===n?void 0:n.ignoreCase)?"i":"")),this.test=null===n||void 0===n?void 0:n.test,this.flat=h.get(e,r,this.chunkEnd(r+5e3))}chunkEnd(e){return e>=this.to?this.to:this.text.lineAt(e).to}next(){for(;;){let e=this.re.lastIndex=this.matchPos-this.flat.from,t=this.re.exec(this.flat.text);if(t&&!t[0]&&t.index==e&&(this.re.lastIndex=e+1,t=this.re.exec(this.flat.text)),t){let e=this.flat.from+t.index,n=e+t[0].length;if((this.flat.to>=this.to||t.index+t[0].length<=this.flat.text.length-10)&&(!this.test||this.test(e,n,t)))return this.value={from:e,to:n,precise:!0,match:t},this.matchPos=m(this.text,n+(e==n?1:0)),this}if(this.flat.to==this.to)return this.done=!0,this;this.flat=h.get(this.text,this.flat.from,this.chunkEnd(this.flat.from+2*this.flat.text.length))}}}function f(e){try{return new RegExp(e,c),!0}catch(t){return!1}}function m(e,t){if(t>=e.length)return t;let n,r=e.lineAt(t);while(t<r.to&&(n=r.text.charCodeAt(t-r.from))>=56320&&n<57344)t++;return t}"undefined"!=typeof Symbol&&(u.prototype[Symbol.iterator]=p.prototype[Symbol.iterator]=function(){return this});const g=e=>{let t=(0,r.getDialog)(e,"cm-goto-line");if(t){let e=t.dom.querySelector("input[type=text]");return e&&e.select(),!0}let{state:n}=e,o=String(n.doc.lineAt(e.state.selection.main.head).number),{close:a,result:s}=(0,r.showDialog)(e,{class:"cm-goto-line",label:n.phrase("Go to line"),input:{type:"text",name:"line",value:o},focus:!0,submitLabel:n.phrase("go")});return s.then(t=>{let o=t&&/^([+-])?(\d+)?(:\d+)?(%)?$/.exec(t.elements["line"].value);if(!o)return void e.dispatch({effects:a});let s=n.doc.lineAt(n.selection.main.head),[,l,c,u,d]=o,h=u?+u.slice(1):0,p=c?+c:s.number;if(c&&d){let e=p/100;l&&(e=e*("-"==l?-1:1)+s.number/n.doc.lines),p=Math.round(n.doc.lines*e)}else c&&l&&(p=p*("-"==l?-1:1)+s.number);let f=n.doc.line(Math.max(1,Math.min(n.doc.lines,p))),m=i.EditorSelection.cursor(f.from+Math.max(0,Math.min(h,f.length)));e.dispatch({effects:[a,r.EditorView.scrollIntoView(m.from,{y:"center"})],selection:m})}),!0},v={highlightWordAroundCursor:!1,minSelectionLength:1,maxMatches:100,wholeWords:!1},b=i.Facet.define({combine(e){return(0,i.combineConfig)(e,v,{highlightWordAroundCursor:(e,t)=>e||t,minSelectionLength:Math.min,maxMatches:Math.min})}});function y(e){let t=[_,x];return e&&t.push(b.of(e)),t}const w=r.Decoration.mark({class:"cm-selectionMatch"}),O=r.Decoration.mark({class:"cm-selectionMatch cm-selectionMatch-main"});function S(e,t,n,r){return(0==n||e(t.sliceDoc(n-1,n))!=i.CharCategory.Word)&&(r==t.doc.length||e(t.sliceDoc(r,r+1))!=i.CharCategory.Word)}function E(e,t,n,r){return e(t.sliceDoc(n,n+1))==i.CharCategory.Word&&e(t.sliceDoc(r-1,r))==i.CharCategory.Word}const x=r.ViewPlugin.fromClass(class{constructor(e){this.decorations=this.getDeco(e)}update(e){(e.selectionSet||e.docChanged||e.viewportChanged)&&(this.decorations=this.getDeco(e.view))}getDeco(e){let t=e.state.facet(b),{state:n}=e,i=n.selection;if(i.ranges.length>1)return r.Decoration.none;let o,a=i.main,l=null;if(a.empty){if(!t.highlightWordAroundCursor)return r.Decoration.none;let e=n.wordAt(a.head);if(!e)return r.Decoration.none;l=n.charCategorizer(a.head),o=n.sliceDoc(e.from,e.to)}else{let e=a.to-a.from;if(e<t.minSelectionLength||e>200)return r.Decoration.none;if(t.wholeWords){if(o=n.sliceDoc(a.from,a.to),l=n.charCategorizer(a.head),!S(l,n,a.from,a.to)||!E(l,n,a.from,a.to))return r.Decoration.none}else if(o=n.sliceDoc(a.from,a.to),!o)return r.Decoration.none}let c=[];for(let u of e.visibleRanges){let e=new s(n.doc,o,u.from,u.to);while(!e.next().done){let{from:i,to:o}=e.value;if((!l||S(l,n,i,o))&&(a.empty&&i<=a.from&&o>=a.to?c.push(O.range(i,o)):(i>=a.to||o<=a.from)&&c.push(w.range(i,o)),c.length>t.maxMatches))return r.Decoration.none}}return r.Decoration.set(c)}},{decorations:e=>e.decorations}),_=r.EditorView.baseTheme({".cm-selectionMatch":{backgroundColor:"#99ff7780"},".cm-searchMatch .cm-selectionMatch":{backgroundColor:"transparent"}}),k=({state:e,dispatch:t})=>{let{selection:n}=e,r=i.EditorSelection.create(n.ranges.map(t=>e.wordAt(t.head)||i.EditorSelection.cursor(t.head)),n.mainIndex);return!r.eq(n)&&(t(e.update({selection:r})),!0)};function C(e,t){let{main:n,ranges:r}=e.selection,i=e.wordAt(n.head),o=i&&i.from==n.from&&i.to==n.to;for(let a=!1,l=new s(e.doc,t,r[r.length-1].to);;){if(l.next(),!l.done){if(a&&r.some(e=>e.from==l.value.from))continue;if(o){let t=e.wordAt(l.value.from);if(!t||t.from!=l.value.from||t.to!=l.value.to)continue}return l.value}if(a)return null;l=new s(e.doc,t,0,Math.max(0,r[r.length-1].from-1)),a=!0}}const A=({state:e,dispatch:t})=>{let{ranges:n}=e.selection;if(n.some(e=>e.from===e.to))return k({state:e,dispatch:t});let o=e.sliceDoc(n[0].from,n[0].to);if(e.selection.ranges.some(t=>e.sliceDoc(t.from,t.to)!=o))return!1;let a=C(e,o);return!!a&&(t(e.update({selection:e.selection.addRange(i.EditorSelection.range(a.from,a.to),!1),effects:r.EditorView.scrollIntoView(a.to)})),!0)},T=i.Facet.define({combine(e){return(0,i.combineConfig)(e,{top:!1,caseSensitive:!1,literal:!1,regexp:!1,wholeWord:!1,createPanel:e=>new he(e),scrollToMatch:e=>r.EditorView.scrollIntoView(e)})}});function R(e){return e?[T.of(e),be]:be}class N{constructor(e){this.search=e.search,this.caseSensitive=!!e.caseSensitive,this.literal=!!e.literal,this.regexp=!!e.regexp,this.replace=e.replace||"",this.valid=!!this.search&&(!this.regexp||f(this.search)),this.unquoted=this.unquote(this.search),this.wholeWord=!!e.wholeWord,this.test=e.test}unquote(e){return this.literal?e:e.replace(/\\([nrt\\])/g,(e,t)=>"n"==t?"\n":"r"==t?"\r":"t"==t?"\t":"\\")}eq(e){return this.search==e.search&&this.replace==e.replace&&this.caseSensitive==e.caseSensitive&&this.regexp==e.regexp&&this.wholeWord==e.wholeWord&&this.test==e.test}create(){return this.regexp?new U(this):new L(this)}getCursor(e,t=0,n){let r=e.doc?e:i.EditorState.create({doc:e});return null==n&&(n=r.doc.length),this.regexp?$(this,r,t,n):M(this,r,t,n)}}class P{constructor(e){this.spec=e}}function I(e,t,n){return(r,i,o,a)=>{if(n&&!n(r,i,o,a))return!1;let s=r>=a&&i<=a+o.length?o.slice(r-a,i-a):t.doc.sliceString(r,i);return e(s,t,r,i)}}function M(e,t,n,r){let i;return e.wholeWord&&(i=D(t.doc,t.charCategorizer(t.selection.main.head))),e.test&&(i=I(e.test,t,i)),new s(t.doc,e.unquoted,n,r,e.caseSensitive?void 0:e=>e.toLowerCase(),i)}function D(e,t){return(n,r,o,a)=>((a>n||a+o.length<r)&&(a=Math.max(0,n-2),o=e.sliceString(a,Math.min(e.length,r+2))),(t(V(o,n-a))!=i.CharCategory.Word||t(F(o,n-a))!=i.CharCategory.Word)&&(t(F(o,r-a))!=i.CharCategory.Word||t(V(o,r-a))!=i.CharCategory.Word))}class L extends P{constructor(e){super(e)}nextMatch(e,t,n){let r=M(this.spec,e,n,e.doc.length).nextOverlapping();if(r.done){let n=Math.min(e.doc.length,t+this.spec.unquoted.length);r=M(this.spec,e,0,n).nextOverlapping()}return r.done||r.value.from==t&&r.value.to==n?null:r.value}prevMatchInRange(e,t,n){for(let r=n;;){let n=Math.max(t,r-1e4-this.spec.unquoted.length),i=M(this.spec,e,n,r),o=null;while(!i.nextOverlapping().done)o=i.value;if(o)return o;if(n==t)return null;r-=1e4}}prevMatch(e,t,n){let r=this.prevMatchInRange(e,0,t);return r||(r=this.prevMatchInRange(e,Math.max(0,n-this.spec.unquoted.length),e.doc.length)),!r||r.from==t&&r.to==n?null:r}getReplacement(e){return this.spec.unquote(this.spec.replace)}matchAll(e,t){let n=M(this.spec,e,0,e.doc.length),r=[];while(!n.next().done){if(r.length>=t)return null;r.push(n.value)}return r}highlight(e,t,n,r){let i=M(this.spec,e,Math.max(0,t-this.spec.unquoted.length),Math.min(n+this.spec.unquoted.length,e.doc.length));while(!i.next().done)r(i.value.from,i.value.to)}}function B(e,t,n){return(r,i,o)=>(!n||n(r,i,o))&&e(o[0],t,r,i)}function $(e,t,n,r){let i;return e.wholeWord&&(i=j(t.charCategorizer(t.selection.main.head))),e.test&&(i=B(e.test,t,i)),new u(t.doc,e.search,{ignoreCase:!e.caseSensitive,test:i},n,r)}function V(e,t){return e.slice((0,i.findClusterBreak)(e,t,!1),t)}function F(e,t){return e.slice(t,(0,i.findClusterBreak)(e,t))}function j(e){return(t,n,r)=>!r[0].length||(e(V(r.input,r.index))!=i.CharCategory.Word||e(F(r.input,r.index))!=i.CharCategory.Word)&&(e(F(r.input,r.index+r[0].length))!=i.CharCategory.Word||e(V(r.input,r.index+r[0].length))!=i.CharCategory.Word)}class U extends P{nextMatch(e,t,n){let r=$(this.spec,e,n,e.doc.length).next();return r.done&&(r=$(this.spec,e,0,t).next()),r.done?null:r.value}prevMatchInRange(e,t,n){for(let r=1;;r++){let i=Math.max(t,n-1e4*r),o=$(this.spec,e,i,n),a=null;while(!o.next().done)a=o.value;if(a&&(i==t||a.from>i+10))return a;if(i==t)return null}}prevMatch(e,t,n){return this.prevMatchInRange(e,0,t)||this.prevMatchInRange(e,n,e.doc.length)}getReplacement(e){return this.spec.unquote(this.spec.replace).replace(/\$([$&]|\d+)/g,(t,n)=>{if("&"==n)return e.match[0];if("$"==n)return"$";for(let r=n.length;r>0;r--){let t=+n.slice(0,r);if(t>0&&t<e.match.length)return e.match[t]+n.slice(r)}return t})}matchAll(e,t){let n=$(this.spec,e,0,e.doc.length),r=[];while(!n.next().done){if(r.length>=t)return null;r.push(n.value)}return r}highlight(e,t,n,r){let i=$(this.spec,e,Math.max(0,t-250),Math.min(n+250,e.doc.length));while(!i.next().done)r(i.value.from,i.value.to)}}const G=i.StateEffect.define(),H=i.StateEffect.define(),q=i.StateField.define({create(e){return new K(ae(e).create(),null)},update(e,t){for(let n of t.effects)n.is(G)?e=new K(n.value.create(),e.panel):n.is(H)&&(e=new K(e.query,n.value?oe:null));return e},provide:e=>r.showPanel.from(e,e=>e.panel)});function Q(e){let t=e.field(q,!1);return t?t.query.spec:ae(e)}function z(e){var t;return null!=(null===(t=e.field(q,!1))||void 0===t?void 0:t.panel)}class K{constructor(e,t){this.query=e,this.panel=t}}const W=r.Decoration.mark({class:"cm-searchMatch"}),X=r.Decoration.mark({class:"cm-searchMatch cm-searchMatch-selected"}),Y=r.ViewPlugin.fromClass(class{constructor(e){this.view=e,this.decorations=this.highlight(e.state.field(q))}update(e){let t=e.state.field(q);(t!=e.startState.field(q)||e.docChanged||e.selectionSet||e.viewportChanged)&&(this.decorations=this.highlight(t))}highlight({query:e,panel:t}){if(!t||!e.spec.valid)return r.Decoration.none;let{view:n}=this,o=new i.RangeSetBuilder;for(let r=0,i=n.visibleRanges,a=i.length;r<a;r++){let{from:t,to:s}=i[r];while(r<a-1&&s>i[r+1].from-500)s=i[++r].to;e.highlight(n.state,t,s,(e,t)=>{let r=n.state.selection.ranges.some(n=>n.from==e&&n.to==t);o.add(e,t,r?X:W)})}return o.finish()}},{decorations:e=>e.decorations});function Z(e){return t=>{let n=t.state.field(q,!1);return n&&n.query.spec.valid?e(t,n):ce(t)}}const J=Z((e,{query:t})=>{let{to:n}=e.state.selection.main,r=t.nextMatch(e.state,n,n);if(!r)return!1;let o=i.EditorSelection.single(r.from,r.to),a=e.state.facet(T);return e.dispatch({selection:o,effects:[ge(e,r),a.scrollToMatch(o.main,e)],userEvent:"select.search"}),le(e),!0}),ee=Z((e,{query:t})=>{let{state:n}=e,{from:r}=n.selection.main,o=t.prevMatch(n,r,r);if(!o)return!1;let a=i.EditorSelection.single(o.from,o.to),s=e.state.facet(T);return e.dispatch({selection:a,effects:[ge(e,o),s.scrollToMatch(a.main,e)],userEvent:"select.search"}),le(e),!0}),te=Z((e,{query:t})=>{let n=t.matchAll(e.state,1e3);return!(!n||!n.length)&&(e.dispatch({selection:i.EditorSelection.create(n.map(e=>i.EditorSelection.range(e.from,e.to))),userEvent:"select.search.matches"}),!0)}),ne=({state:e,dispatch:t})=>{let n=e.selection;if(n.ranges.length>1||n.main.empty)return!1;let{from:r,to:o}=n.main,a=[],l=0;for(let c=new s(e.doc,e.sliceDoc(r,o));!c.next().done;){if(a.length>1e3)return!1;c.value.from==r&&(l=a.length),a.push(i.EditorSelection.range(c.value.from,c.value.to))}return t(e.update({selection:i.EditorSelection.create(a,l),userEvent:"select.search.matches"})),!0},re=Z((e,{query:t})=>{let{state:n}=e,{from:o,to:a}=n.selection.main;if(n.readOnly)return!1;let s=t.nextMatch(n,o,o);if(!s)return!1;let l,c,u=s,d=[],h=[];u.precise?u.from==o&&u.to==a&&(c=n.toText(t.getReplacement(u)),d.push({from:u.from,to:u.to,insert:c}),u=t.nextMatch(n,u.from,u.to),h.push(r.EditorView.announce.of(n.phrase("replaced match on line $",n.doc.lineAt(o).number)+"."))):u=t.nextMatch(n,u.from,u.to);let p=e.state.changes(d);return u&&(l=i.EditorSelection.single(u.from,u.to).map(p),h.push(ge(e,u)),h.push(n.facet(T).scrollToMatch(l.main,e))),e.dispatch({changes:p,selection:l,effects:h,userEvent:"input.replace"}),!0}),ie=Z((e,{query:t})=>{if(e.state.readOnly)return!1;let n=[];for(let r of t.matchAll(e.state,1e9)){let{from:e,to:i,precise:o}=r;o&&n.push({from:e,to:i,insert:t.getReplacement(r)})}if(!n.length)return!1;let i=e.state.phrase("replaced $ matches",n.length)+".";return e.dispatch({changes:n,effects:r.EditorView.announce.of(i),userEvent:"input.replace.all"}),!0});function oe(e){return e.state.facet(T).createPanel(e)}function ae(e,t){var n,r,i,o,a;let s=e.selection.main,l=s.empty||s.to>s.from+100?"":e.sliceDoc(s.from,s.to);if(t&&!l)return t;let c=e.facet(T);return new N({search:(null!==(n=null===t||void 0===t?void 0:t.literal)&&void 0!==n?n:c.literal)?l:l.replace(/\n/g,"\\n"),caseSensitive:null!==(r=null===t||void 0===t?void 0:t.caseSensitive)&&void 0!==r?r:c.caseSensitive,literal:null!==(i=null===t||void 0===t?void 0:t.literal)&&void 0!==i?i:c.literal,regexp:null!==(o=null===t||void 0===t?void 0:t.regexp)&&void 0!==o?o:c.regexp,wholeWord:null!==(a=null===t||void 0===t?void 0:t.wholeWord)&&void 0!==a?a:c.wholeWord})}function se(e){let t=(0,r.getPanel)(e,oe);return t&&t.dom.querySelector("[main-field]")}function le(e){let t=se(e);t&&t==e.root.activeElement&&t.select()}const ce=e=>{let t=e.state.field(q,!1);if(t&&t.panel){let n=se(e);if(n&&n!=e.root.activeElement){let r=ae(e.state,t.query.spec);r.valid&&e.dispatch({effects:G.of(r)}),n.focus(),n.select()}}else e.dispatch({effects:[H.of(!0),t?G.of(ae(e.state,t.query.spec)):i.StateEffect.appendConfig.of(be)]});return!0},ue=e=>{let t=e.state.field(q,!1);if(!t||!t.panel)return!1;let n=(0,r.getPanel)(e,oe);return n&&n.dom.contains(e.root.activeElement)&&e.focus(),e.dispatch({effects:H.of(!1)}),!0},de=[{key:"Mod-f",run:ce,scope:"editor search-panel"},{key:"F3",run:J,shift:ee,scope:"editor search-panel",preventDefault:!0},{key:"Mod-g",run:J,shift:ee,scope:"editor search-panel",preventDefault:!0},{key:"Escape",run:ue,scope:"editor search-panel"},{key:"Mod-Shift-l",run:ne},{key:"Mod-Alt-g",run:g},{key:"Mod-d",run:A,preventDefault:!0}];class he{constructor(e){this.view=e;let t=this.query=e.state.field(q).query.spec;function n(e,t,n){return(0,o.A)("button",{class:"cm-button",name:e,onclick:t,type:"button"},n)}this.commit=this.commit.bind(this),this.searchField=(0,o.A)("input",{value:t.search,placeholder:pe(e,"Find"),"aria-label":pe(e,"Find"),class:"cm-textfield",name:"search",form:"","main-field":"true",onchange:this.commit,onkeyup:this.commit}),this.replaceField=(0,o.A)("input",{value:t.replace,placeholder:pe(e,"Replace"),"aria-label":pe(e,"Replace"),class:"cm-textfield",name:"replace",form:"",onchange:this.commit,onkeyup:this.commit}),this.caseField=(0,o.A)("input",{type:"checkbox",name:"case",form:"",checked:t.caseSensitive,onchange:this.commit}),this.reField=(0,o.A)("input",{type:"checkbox",name:"re",form:"",checked:t.regexp,onchange:this.commit}),this.wordField=(0,o.A)("input",{type:"checkbox",name:"word",form:"",checked:t.wholeWord,onchange:this.commit}),this.dom=(0,o.A)("div",{onkeydown:e=>this.keydown(e),class:"cm-search"},[this.searchField,n("next",()=>J(e),[pe(e,"next")]),n("prev",()=>ee(e),[pe(e,"previous")]),n("select",()=>te(e),[pe(e,"all")]),(0,o.A)("label",null,[this.caseField,pe(e,"match case")]),(0,o.A)("label",null,[this.reField,pe(e,"regexp")]),(0,o.A)("label",null,[this.wordField,pe(e,"by word")]),...e.state.readOnly?[]:[(0,o.A)("br"),this.replaceField,n("replace",()=>re(e),[pe(e,"replace")]),n("replaceAll",()=>ie(e),[pe(e,"replace all")])],(0,o.A)("button",{name:"close",onclick:()=>ue(e),"aria-label":pe(e,"close"),type:"button"},["×"])])}commit(){let e=new N({search:this.searchField.value,caseSensitive:this.caseField.checked,regexp:this.reField.checked,wholeWord:this.wordField.checked,replace:this.replaceField.value});e.eq(this.query)||(this.query=e,this.view.dispatch({effects:G.of(e)}))}keydown(e){(0,r.runScopeHandlers)(this.view,e,"search-panel")?e.preventDefault():13==e.keyCode&&e.target==this.searchField?(e.preventDefault(),(e.shiftKey?ee:J)(this.view)):13==e.keyCode&&e.target==this.replaceField&&(e.preventDefault(),re(this.view))}update(e){for(let t of e.transactions)for(let e of t.effects)e.is(G)&&!e.value.eq(this.query)&&this.setQuery(e.value)}setQuery(e){this.query=e,this.searchField.value=e.search,this.replaceField.value=e.replace,this.caseField.checked=e.caseSensitive,this.reField.checked=e.regexp,this.wordField.checked=e.wholeWord}mount(){this.searchField.select()}get pos(){return 80}get top(){return this.view.state.facet(T).top}}function pe(e,t){return e.state.phrase(t)}const fe=30,me=/[\s\.,:;?!]/;function ge(e,{from:t,to:n}){let i=e.state.doc.lineAt(t),o=e.state.doc.lineAt(n).to,a=Math.max(i.from,t-fe),s=Math.min(o,n+fe),l=e.state.sliceDoc(a,s);if(a!=i.from)for(let r=0;r<fe;r++)if(!me.test(l[r+1])&&me.test(l[r])){l=l.slice(r);break}if(s!=o)for(let r=l.length-1;r>l.length-fe;r--)if(!me.test(l[r-1])&&me.test(l[r])){l=l.slice(0,r);break}return r.EditorView.announce.of(`${e.state.phrase("current match")}. ${l} ${e.state.phrase("on line")} ${i.number}.`)}const ve=r.EditorView.baseTheme({".cm-panel.cm-search":{padding:"2px 6px 4px",position:"relative","& [name=close]":{position:"absolute",top:"0",right:"4px",backgroundColor:"inherit",border:"none",font:"inherit",padding:0,margin:0},"& input, & button, & label":{margin:".2em .6em .2em 0"},"& input[type=checkbox]":{marginRight:".2em"},"& label":{fontSize:"80%",whiteSpace:"pre"}},"&light .cm-searchMatch":{backgroundColor:"#ffff0054"},"&dark .cm-searchMatch":{backgroundColor:"#00ffff8a"},"&light .cm-searchMatch-selected":{backgroundColor:"#ff6a0054"},"&dark .cm-searchMatch-selected":{backgroundColor:"#ff00ff8a"}}),be=[q,i.Prec.low(Y),ve]},41735:function(e,t,n){"use strict";n.r(t),n.d(t,{Annotation:function(){return ve},AnnotationType:function(){return be},ChangeDesc:function(){return M},ChangeSet:function(){return D},CharCategory:function(){return Re},Compartment:function(){return ie},EditorSelection:function(){return G},EditorState:function(){return De},Facet:function(){return Q},Line:function(){return x},MapMode:function(){return I},Prec:function(){return ne},Range:function(){return Ve},RangeSet:function(){return Ue},RangeSetBuilder:function(){return qe},RangeValue:function(){return Be},SelectionRange:function(){return U},StateEffect:function(){return we},StateEffectType:function(){return ye},StateField:function(){return J},Text:function(){return m},Transaction:function(){return Oe},codePointAt:function(){return T},codePointSize:function(){return N},combineConfig:function(){return Le},countColumn:function(){return nt},findClusterBreak:function(){return k},findColumn:function(){return rt},fromCodePoint:function(){return R}});let r=[],i=[];function o(e){if(e<768)return!1;for(let t=0,n=r.length;;){let o=t+n>>1;if(e<r[o])n=o;else{if(!(e>=i[o]))return!0;t=o+1}if(t==n)return!1}}function a(e){return e>=127462&&e<=127487}(()=>{let e="lc,34,7n,7,7b,19,,,,2,,2,,,20,b,1c,l,g,,2t,7,2,6,2,2,,4,z,,u,r,2j,b,1m,9,9,,o,4,,9,,3,,5,17,3,1n,9,16,o,,x,1i,3,,i,,7,a,2,t,3,1k,,,7,2,2,2,3,9,,a,2,q,,2,3,1k,,,5,4,2,2,3,3,,u,2,3,,b,3,1k,,,8,,3,,3,k,2,m,6,,3,1k,,,7,2,2,2,3,7,3,a,2,u,,1n,5,3,3,,4,9,,14,5,1j,,,7,,3,,4,7,2,b,2,t,3,1k,,,7,,3,,4,7,2,b,2,f,,c,4,1j,2,,7,,3,,4,9,,a,2,t,3,1y,,4,6,,,,8,i,2,1p,,,8,c,8,2q,,,a,b,7,21,2,r,,,,,,4,2,1d,k,,2,5,b,,10,9,,2u,b,,6,n,4,4,3,g,4,d,,,3,6,,f,,jj,3,qa,4,s,3,t,2,u,2,1s,w,9,,19,3,,,39,2,y,,3a,c,4,c,63,5,1l,a,,,,,2,o,2,,1c,1a,2,c,k,5,1b,h,12,9,c,3,u,d,1k,e,1c,k,48,3,,l,4,,6,,2,3,5i,1s,ek,,5f,x,2da,3,3x,,2o,w,fe,6,2x,2,n9w,4,,a,w,2,28,2,7k,,3,,4,,n,5,4,,2b,2,1e,i,q,i,d,,12,8,p,d,18,4,1b,e,10,,1v,e,c,,8,2,1a,,1f,,,3,2,2,5,2,,,15,5,5,2,6k,8,,2,fn4,,kh,g,g,g,a6,2,gt,,6a,,45,5,1ae,3,,2,5,4,14,3,4,,4l,2,fx,4,1t,5,8t,2,25,6,1y,b,1d,4,3e,3,1h,f,15,,2,2,a,4,19,b,7,,1p,3,10,e,g,2,18,,c,3,1c,e,8,4,,2,2k,c,6,,2,,4d,c,l,4,1j,2,,7,2,2,2,3,9,,a,2,2,7,3,5,1v,9,,,2,,,4,,5,,,e,2,2a,i,n,,29,k,6j,7,2,9,r,2,2a,h,2y,d,2t,3,2,a,74,f,6t,6,,2,2,4,,,,2,3x,7,2,7,3,,s,a,14,7,,4,8,,9,b,1a,g,5i,8,5j,8,,8,2a,m,,e,3e,6,3,,,2,,7,,,1u,5,,2,,5,9n,4,9,2,,,1c,7,3,5,n,,44l,,6,f,8ug,i,1xc,5,1n,7,t4,,,1j,7,4,29,,b,2,f57,2,3mp,1a,2,n,f2,5,3,6,8,8,2,7,u,4,44,3,1iz,1j,4,1e,8,,e,,m,5,,f,11s,7,,h,2,7,,2,,5,2s,,4g,7,af,,1p,4,e4,4,72,2,6r,,2,,7,2,5,,d6,7,31,7,240,5".split(",").map(e=>e?parseInt(e,36):1);for(let t=0,n=0;t<e.length;t++)(t%2?i:r).push(n+=e[t])})();const s=8205;function l(e,t,n=!0,r=!0){return(n?c:u)(e,t,r)}function c(e,t,n){if(t==e.length)return t;t&&h(e.charCodeAt(t))&&p(e.charCodeAt(t-1))&&t--;let r=d(e,t);t+=f(r);while(t<e.length){let i=d(e,t);if(r==s||i==s||n&&o(i))t+=f(i),r=i;else{if(!a(i))break;{let n=0,r=t-2;while(r>=0&&a(d(e,r)))n++,r-=2;if(n%2==0)break;t+=2}}}return t}function u(e,t,n){while(t>1){let r=c(e,t-2,n);if(r<t)return r;t--}return 0}function d(e,t){let n=e.charCodeAt(t);if(!p(n)||t+1==e.length)return n;let r=e.charCodeAt(t+1);return h(r)?r-56320+(n-55296<<10)+65536:n}function h(e){return e>=56320&&e<57344}function p(e){return e>=55296&&e<56320}function f(e){return e<65536?1:2}class m{lineAt(e){if(e<0||e>this.length)throw new RangeError(`Invalid position ${e} in document of length ${this.length}`);return this.lineInner(e,!1,1,0)}line(e){if(e<1||e>this.lines)throw new RangeError(`Invalid line number ${e} in ${this.lines}-line document`);return this.lineInner(e,!0,1,0)}replace(e,t,n){[e,t]=_(this,e,t);let r=[];return this.decompose(0,e,r,2),n.length&&n.decompose(0,n.length,r,3),this.decompose(t,this.length,r,1),v.from(r,this.length-(t-e)+n.length)}append(e){return this.replace(this.length,this.length,e)}slice(e,t=this.length){[e,t]=_(this,e,t);let n=[];return this.decompose(e,t,n,0),v.from(n,t-e)}eq(e){if(e==this)return!0;if(e.length!=this.length||e.lines!=this.lines)return!1;let t=this.scanIdentical(e,1),n=this.length-this.scanIdentical(e,-1),r=new O(this),i=new O(e);for(let o=t,a=t;;){if(r.next(o),i.next(o),o=0,r.lineBreak!=i.lineBreak||r.done!=i.done||r.value!=i.value)return!1;if(a+=r.value.length,r.done||a>=n)return!0}}iter(e=1){return new O(this,e)}iterRange(e,t=this.length){return new S(this,e,t)}iterLines(e,t){let n;if(null==e)n=this.iter();else{null==t&&(t=this.lines+1);let r=this.line(e).from;n=this.iterRange(r,Math.max(r,t==this.lines+1?this.length:t<=1?0:this.line(t-1).to))}return new E(n)}toString(){return this.sliceString(0)}toJSON(){let e=[];return this.flatten(e),e}constructor(){}static of(e){if(0==e.length)throw new RangeError("A document must have at least one line");return 1!=e.length||e[0]?e.length<=32?new g(e):v.from(g.split(e,[])):m.empty}}class g extends m{constructor(e,t=b(e)){super(),this.text=e,this.length=t}get lines(){return this.text.length}get children(){return null}lineInner(e,t,n,r){for(let i=0;;i++){let o=this.text[i],a=r+o.length;if((t?n:a)>=e)return new x(r,a,n,o);r=a+1,n++}}decompose(e,t,n,r){let i=e<=0&&t>=this.length?this:new g(w(this.text,e,t),Math.min(t,this.length)-Math.max(0,e));if(1&r){let e=n.pop(),t=y(i.text,e.text.slice(),0,i.length);if(t.length<=32)n.push(new g(t,e.length+i.length));else{let e=t.length>>1;n.push(new g(t.slice(0,e)),new g(t.slice(e)))}}else n.push(i)}replace(e,t,n){if(!(n instanceof g))return super.replace(e,t,n);[e,t]=_(this,e,t);let r=y(this.text,y(n.text,w(this.text,0,e)),t),i=this.length+n.length-(t-e);return r.length<=32?new g(r,i):v.from(g.split(r,[]),i)}sliceString(e,t=this.length,n="\n"){[e,t]=_(this,e,t);let r="";for(let i=0,o=0;i<=t&&o<this.text.length;o++){let a=this.text[o],s=i+a.length;i>e&&o&&(r+=n),e<s&&t>i&&(r+=a.slice(Math.max(0,e-i),t-i)),i=s+1}return r}flatten(e){for(let t of this.text)e.push(t)}scanIdentical(){return 0}static split(e,t){let n=[],r=-1;for(let i of e)n.push(i),r+=i.length+1,32==n.length&&(t.push(new g(n,r)),n=[],r=-1);return r>-1&&t.push(new g(n,r)),t}}class v extends m{constructor(e,t){super(),this.children=e,this.length=t,this.lines=0;for(let n of e)this.lines+=n.lines}lineInner(e,t,n,r){for(let i=0;;i++){let o=this.children[i],a=r+o.length,s=n+o.lines-1;if((t?s:a)>=e)return o.lineInner(e,t,n,r);r=a+1,n=s+1}}decompose(e,t,n,r){for(let i=0,o=0;o<=t&&i<this.children.length;i++){let a=this.children[i],s=o+a.length;if(e<=s&&t>=o){let i=r&((o<=e?1:0)|(s>=t?2:0));o>=e&&s<=t&&!i?n.push(a):a.decompose(e-o,t-o,n,i)}o=s+1}}replace(e,t,n){if([e,t]=_(this,e,t),n.lines<this.lines)for(let r=0,i=0;r<this.children.length;r++){let o=this.children[r],a=i+o.length;if(e>=i&&t<=a){let s=o.replace(e-i,t-i,n),l=this.lines-o.lines+s.lines;if(s.lines<l>>4&&s.lines>l>>6){let i=this.children.slice();return i[r]=s,new v(i,this.length-(t-e)+n.length)}return super.replace(i,a,s)}i=a+1}return super.replace(e,t,n)}sliceString(e,t=this.length,n="\n"){[e,t]=_(this,e,t);let r="";for(let i=0,o=0;i<this.children.length&&o<=t;i++){let a=this.children[i],s=o+a.length;o>e&&i&&(r+=n),e<s&&t>o&&(r+=a.sliceString(e-o,t-o,n)),o=s+1}return r}flatten(e){for(let t of this.children)t.flatten(e)}scanIdentical(e,t){if(!(e instanceof v))return 0;let n=0,[r,i,o,a]=t>0?[0,0,this.children.length,e.children.length]:[this.children.length-1,e.children.length-1,-1,-1];for(;;r+=t,i+=t){if(r==o||i==a)return n;let s=this.children[r],l=e.children[i];if(s!=l)return n+s.scanIdentical(l,t);n+=s.length+1}}static from(e,t=e.reduce((e,t)=>e+t.length+1,-1)){let n=0;for(let h of e)n+=h.lines;if(n<32){let n=[];for(let t of e)t.flatten(n);return new g(n,t)}let r=Math.max(32,n>>5),i=r<<1,o=r>>1,a=[],s=0,l=-1,c=[];function u(e){let t;if(e.lines>i&&e instanceof v)for(let n of e.children)u(n);else e.lines>o&&(s>o||!s)?(d(),a.push(e)):e instanceof g&&s&&(t=c[c.length-1])instanceof g&&e.lines+t.lines<=32?(s+=e.lines,l+=e.length+1,c[c.length-1]=new g(t.text.concat(e.text),t.length+1+e.length)):(s+e.lines>r&&d(),s+=e.lines,l+=e.length+1,c.push(e))}function d(){0!=s&&(a.push(1==c.length?c[0]:v.from(c,l)),l=-1,s=c.length=0)}for(let h of e)u(h);return d(),1==a.length?a[0]:new v(a,t)}}function b(e){let t=-1;for(let n of e)t+=n.length+1;return t}function y(e,t,n=0,r=1e9){for(let i=0,o=0,a=!0;o<e.length&&i<=r;o++){let s=e[o],l=i+s.length;l>=n&&(l>r&&(s=s.slice(0,r-i)),i<n&&(s=s.slice(n-i)),a?(t[t.length-1]+=s,a=!1):t.push(s)),i=l+1}return t}function w(e,t,n){return y(e,[""],t,n)}m.empty=new g([""],0);class O{constructor(e,t=1){this.dir=t,this.done=!1,this.lineBreak=!1,this.value="",this.nodes=[e],this.offsets=[t>0?1:(e instanceof g?e.text.length:e.children.length)<<1]}nextInner(e,t){for(this.done=this.lineBreak=!1;;){let n=this.nodes.length-1,r=this.nodes[n],i=this.offsets[n],o=i>>1,a=r instanceof g?r.text.length:r.children.length;if(o==(t>0?a:0)){if(0==n)return this.done=!0,this.value="",this;t>0&&this.offsets[n-1]++,this.nodes.pop(),this.offsets.pop()}else if((1&i)==(t>0?0:1)){if(this.offsets[n]+=t,0==e)return this.lineBreak=!0,this.value="\n",this;e--}else if(r instanceof g){let i=r.text[o+(t<0?-1:0)];if(this.offsets[n]+=t,i.length>Math.max(0,e))return this.value=0==e?i:t>0?i.slice(e):i.slice(0,i.length-e),this;e-=i.length}else{let i=r.children[o+(t<0?-1:0)];e>i.length?(e-=i.length,this.offsets[n]+=t):(t<0&&this.offsets[n]--,this.nodes.push(i),this.offsets.push(t>0?1:(i instanceof g?i.text.length:i.children.length)<<1))}}}next(e=0){return e<0&&(this.nextInner(-e,-this.dir),e=this.value.length),this.nextInner(e,this.dir)}}class S{constructor(e,t,n){this.value="",this.done=!1,this.cursor=new O(e,t>n?-1:1),this.pos=t>n?e.length:0,this.from=Math.min(t,n),this.to=Math.max(t,n)}nextInner(e,t){if(t<0?this.pos<=this.from:this.pos>=this.to)return this.value="",this.done=!0,this;e+=Math.max(0,t<0?this.pos-this.to:this.from-this.pos);let n=t<0?this.pos-this.from:this.to-this.pos;e>n&&(e=n),n-=e;let{value:r}=this.cursor.next(e);return this.pos+=(r.length+e)*t,this.value=r.length<=n?r:t<0?r.slice(r.length-n):r.slice(0,n),this.done=!this.value,this}next(e=0){return e<0?e=Math.max(e,this.from-this.pos):e>0&&(e=Math.min(e,this.to-this.pos)),this.nextInner(e,this.cursor.dir)}get lineBreak(){return this.cursor.lineBreak&&""!=this.value}}class E{constructor(e){this.inner=e,this.afterBreak=!0,this.value="",this.done=!1}next(e=0){let{done:t,lineBreak:n,value:r}=this.inner.next(e);return t&&this.afterBreak?(this.value="",this.afterBreak=!1):t?(this.done=!0,this.value=""):n?this.afterBreak?this.value="":(this.afterBreak=!0,this.next()):(this.value=r,this.afterBreak=!1),this}get lineBreak(){return!1}}"undefined"!=typeof Symbol&&(m.prototype[Symbol.iterator]=function(){return this.iter()},O.prototype[Symbol.iterator]=S.prototype[Symbol.iterator]=E.prototype[Symbol.iterator]=function(){return this});class x{constructor(e,t,n,r){this.from=e,this.to=t,this.number=n,this.text=r}get length(){return this.to-this.from}}function _(e,t,n){return t=Math.max(0,Math.min(e.length,t)),[t,Math.max(t,Math.min(e.length,n))]}function k(e,t,n=!0,r=!0){return l(e,t,n,r)}function C(e){return e>=56320&&e<57344}function A(e){return e>=55296&&e<56320}function T(e,t){let n=e.charCodeAt(t);if(!A(n)||t+1==e.length)return n;let r=e.charCodeAt(t+1);return C(r)?r-56320+(n-55296<<10)+65536:n}function R(e){return e<=65535?String.fromCharCode(e):(e-=65536,String.fromCharCode(55296+(e>>10),56320+(1023&e)))}function N(e){return e<65536?1:2}const P=/\r\n?|\n/;var I=function(e){return e[e["Simple"]=0]="Simple",e[e["TrackDel"]=1]="TrackDel",e[e["TrackBefore"]=2]="TrackBefore",e[e["TrackAfter"]=3]="TrackAfter",e}(I||(I={}));class M{constructor(e){this.sections=e}get length(){let e=0;for(let t=0;t<this.sections.length;t+=2)e+=this.sections[t];return e}get newLength(){let e=0;for(let t=0;t<this.sections.length;t+=2){let n=this.sections[t+1];e+=n<0?this.sections[t]:n}return e}get empty(){return 0==this.sections.length||2==this.sections.length&&this.sections[1]<0}iterGaps(e){for(let t=0,n=0,r=0;t<this.sections.length;){let i=this.sections[t++],o=this.sections[t++];o<0?(e(n,r,i),r+=i):r+=o,n+=i}}iterChangedRanges(e,t=!1){$(this,e,t)}get invertedDesc(){let e=[];for(let t=0;t<this.sections.length;){let n=this.sections[t++],r=this.sections[t++];r<0?e.push(n,r):e.push(r,n)}return new M(e)}composeDesc(e){return this.empty?e:e.empty?this:F(this,e)}mapDesc(e,t=!1){return e.empty?this:V(this,e,t)}mapPos(e,t=-1,n=I.Simple){let r=0,i=0;for(let o=0;o<this.sections.length;){let a=this.sections[o++],s=this.sections[o++],l=r+a;if(s<0){if(l>e)return i+(e-r);i+=a}else{if(n!=I.Simple&&l>=e&&(n==I.TrackDel&&r<e&&l>e||n==I.TrackBefore&&r<e||n==I.TrackAfter&&l>e))return null;if(l>e||l==e&&t<0&&!a)return e==r||t<0?i:i+s;i+=s}r=l}if(e>r)throw new RangeError(`Position ${e} is out of range for changeset of length ${r}`);return i}touchesRange(e,t=e){for(let n=0,r=0;n<this.sections.length&&r<=t;){let i=this.sections[n++],o=this.sections[n++],a=r+i;if(o>=0&&r<=t&&a>=e)return!(r<e&&a>t)||"cover";r=a}return!1}toString(){let e="";for(let t=0;t<this.sections.length;){let n=this.sections[t++],r=this.sections[t++];e+=(e?" ":"")+n+(r>=0?":"+r:"")}return e}toJSON(){return this.sections}static fromJSON(e){if(!Array.isArray(e)||e.length%2||e.some(e=>"number"!=typeof e))throw new RangeError("Invalid JSON representation of ChangeDesc");return new M(e)}static create(e){return new M(e)}}class D extends M{constructor(e,t){super(e),this.inserted=t}apply(e){if(this.length!=e.length)throw new RangeError("Applying change set to a document with the wrong length");return $(this,(t,n,r,i,o)=>e=e.replace(r,r+(n-t),o),!1),e}mapDesc(e,t=!1){return V(this,e,t,!0)}invert(e){let t=this.sections.slice(),n=[];for(let r=0,i=0;r<t.length;r+=2){let o=t[r],a=t[r+1];if(a>=0){t[r]=a,t[r+1]=o;let s=r>>1;while(n.length<s)n.push(m.empty);n.push(o?e.slice(i,i+o):m.empty)}i+=o}return new D(t,n)}compose(e){return this.empty?e:e.empty?this:F(this,e,!0)}map(e,t=!1){return e.empty?this:V(this,e,t,!0)}iterChanges(e,t=!1){$(this,e,t)}get desc(){return M.create(this.sections)}filter(e){let t=[],n=[],r=[],i=new j(this);e:for(let o=0,a=0;;){let s=o==e.length?1e9:e[o++];while(a<s||a==s&&0==i.len){if(i.done)break e;let e=Math.min(i.len,s-a);L(r,e,-1);let o=-1==i.ins?-1:0==i.off?i.ins:0;L(t,e,o),o>0&&B(n,t,i.text),i.forward(e),a+=e}let l=e[o++];while(a<l){if(i.done)break e;let e=Math.min(i.len,l-a);L(t,e,-1),L(r,e,-1==i.ins?-1:0==i.off?i.ins:0),i.forward(e),a+=e}}return{changes:new D(t,n),filtered:M.create(r)}}toJSON(){let e=[];for(let t=0;t<this.sections.length;t+=2){let n=this.sections[t],r=this.sections[t+1];r<0?e.push(n):0==r?e.push([n]):e.push([n].concat(this.inserted[t>>1].toJSON()))}return e}static of(e,t,n){let r=[],i=[],o=0,a=null;function s(e=!1){if(!e&&!r.length)return;o<t&&L(r,t-o,-1);let n=new D(r,i);a=a?a.compose(n.map(a)):n,r=[],i=[],o=0}function l(e){if(Array.isArray(e))for(let t of e)l(t);else if(e instanceof D){if(e.length!=t)throw new RangeError(`Mismatched change set length (got ${e.length}, expected ${t})`);s(),a=a?a.compose(e.map(a)):e}else{let{from:a,to:l=a,insert:c}=e;if(a>l||a<0||l>t)throw new RangeError(`Invalid change range ${a} to ${l} (in doc of length ${t})`);let u=c?"string"==typeof c?m.of(c.split(n||P)):c:m.empty,d=u.length;if(a==l&&0==d)return;a<o&&s(),a>o&&L(r,a-o,-1),L(r,l-a,d),B(i,r,u),o=l}}return l(e),s(!a),a}static empty(e){return new D(e?[e,-1]:[],[])}static fromJSON(e){if(!Array.isArray(e))throw new RangeError("Invalid JSON representation of ChangeSet");let t=[],n=[];for(let r=0;r<e.length;r++){let i=e[r];if("number"==typeof i)t.push(i,-1);else{if(!Array.isArray(i)||"number"!=typeof i[0]||i.some((e,t)=>t&&"string"!=typeof e))throw new RangeError("Invalid JSON representation of ChangeSet");if(1==i.length)t.push(i[0],0);else{while(n.length<r)n.push(m.empty);n[r]=m.of(i.slice(1)),t.push(i[0],n[r].length)}}}return new D(t,n)}static createSet(e,t){return new D(e,t)}}function L(e,t,n,r=!1){if(0==t&&n<=0)return;let i=e.length-2;i>=0&&n<=0&&n==e[i+1]?e[i]+=t:i>=0&&0==t&&0==e[i]?e[i+1]+=n:r?(e[i]+=t,e[i+1]+=n):e.push(t,n)}function B(e,t,n){if(0==n.length)return;let r=t.length-2>>1;if(r<e.length)e[e.length-1]=e[e.length-1].append(n);else{while(e.length<r)e.push(m.empty);e.push(n)}}function $(e,t,n){let r=e.inserted;for(let i=0,o=0,a=0;a<e.sections.length;){let s=e.sections[a++],l=e.sections[a++];if(l<0)i+=s,o+=s;else{let c=i,u=o,d=m.empty;for(;;){if(c+=s,u+=l,l&&r&&(d=d.append(r[a-2>>1])),n||a==e.sections.length||e.sections[a+1]<0)break;s=e.sections[a++],l=e.sections[a++]}t(i,c,o,u,d),i=c,o=u}}}function V(e,t,n,r=!1){let i=[],o=r?[]:null,a=new j(e),s=new j(t);for(let l=-1;;){if(a.done&&s.len||s.done&&a.len)throw new Error("Mismatched change set lengths");if(-1==a.ins&&-1==s.ins){let e=Math.min(a.len,s.len);L(i,e,-1),a.forward(e),s.forward(e)}else if(s.ins>=0&&(a.ins<0||l==a.i||0==a.off&&(s.len<a.len||s.len==a.len&&!n))){let e=s.len;L(i,s.ins,-1);while(e){let t=Math.min(a.len,e);a.ins>=0&&l<a.i&&a.len<=t&&(L(i,0,a.ins),o&&B(o,i,a.text),l=a.i),a.forward(t),e-=t}s.next()}else{if(!(a.ins>=0)){if(a.done&&s.done)return o?D.createSet(i,o):M.create(i);throw new Error("Mismatched change set lengths")}{let e=0,t=a.len;while(t)if(-1==s.ins){let n=Math.min(t,s.len);e+=n,t-=n,s.forward(n)}else{if(!(0==s.ins&&s.len<t))break;t-=s.len,s.next()}L(i,e,l<a.i?a.ins:0),o&&l<a.i&&B(o,i,a.text),l=a.i,a.forward(a.len-t)}}}}function F(e,t,n=!1){let r=[],i=n?[]:null,o=new j(e),a=new j(t);for(let s=!1;;){if(o.done&&a.done)return i?D.createSet(r,i):M.create(r);if(0==o.ins)L(r,o.len,0,s),o.next();else if(0!=a.len||a.done){if(o.done||a.done)throw new Error("Mismatched change set lengths");{let e=Math.min(o.len2,a.len),t=r.length;if(-1==o.ins){let t=-1==a.ins?-1:a.off?0:a.ins;L(r,e,t,s),i&&t&&B(i,r,a.text)}else-1==a.ins?(L(r,o.off?0:o.len,e,s),i&&B(i,r,o.textBit(e))):(L(r,o.off?0:o.len,a.off?0:a.ins,s),i&&!a.off&&B(i,r,a.text));s=(o.ins>e||a.ins>=0&&a.len>e)&&(s||r.length>t),o.forward2(e),a.forward(e)}}else L(r,0,a.ins,s),i&&B(i,r,a.text),a.next()}}class j{constructor(e){this.set=e,this.i=0,this.next()}next(){let{sections:e}=this.set;this.i<e.length?(this.len=e[this.i++],this.ins=e[this.i++]):(this.len=0,this.ins=-2),this.off=0}get done(){return-2==this.ins}get len2(){return this.ins<0?this.len:this.ins}get text(){let{inserted:e}=this.set,t=this.i-2>>1;return t>=e.length?m.empty:e[t]}textBit(e){let{inserted:t}=this.set,n=this.i-2>>1;return n>=t.length&&!e?m.empty:t[n].slice(this.off,null==e?void 0:this.off+e)}forward(e){e==this.len?this.next():(this.len-=e,this.off+=e)}forward2(e){-1==this.ins?this.forward(e):e==this.ins?this.next():(this.ins-=e,this.off+=e)}}class U{constructor(e,t,n,r){this.from=e,this.to=t,this.flags=n,this.goalColumn=r}get anchor(){return 32&this.flags?this.to:this.from}get head(){return 32&this.flags?this.from:this.to}get empty(){return this.from==this.to}get assoc(){return 8&this.flags?-1:16&this.flags?1:0}get undirectional(){return(64&this.flags)>0}get bidiLevel(){let e=7&this.flags;return 7==e?null:e}map(e,t=-1){let n,r;return this.empty?n=r=e.mapPos(this.from,t):(n=e.mapPos(this.from,1),r=e.mapPos(this.to,-1)),n==this.from&&r==this.to?this:new U(n,r,this.flags,this.goalColumn)}extend(e,t=e,n=0){if(e<=this.anchor&&t>=this.anchor)return G.range(e,t,void 0,void 0,n);let r=Math.abs(e-this.anchor)>Math.abs(t-this.anchor)?e:t;return G.range(this.anchor,r,void 0,void 0,n)}eq(e,t=!1){return this.anchor==e.anchor&&this.head==e.head&&this.goalColumn==e.goalColumn&&(!t||!this.empty||this.assoc==e.assoc)}toJSON(){return{anchor:this.anchor,head:this.head}}static fromJSON(e){if(!e||"number"!=typeof e.anchor||"number"!=typeof e.head)throw new RangeError("Invalid JSON representation for SelectionRange");return G.range(e.anchor,e.head)}static create(e,t,n,r){return new U(e,t,n,r)}}class G{constructor(e,t){this.ranges=e,this.mainIndex=t}map(e,t=-1){return e.empty?this:G.create(this.ranges.map(n=>n.map(e,t)),this.mainIndex)}eq(e,t=!1){if(this.ranges.length!=e.ranges.length||this.mainIndex!=e.mainIndex)return!1;for(let n=0;n<this.ranges.length;n++)if(!this.ranges[n].eq(e.ranges[n],t))return!1;return!0}get main(){return this.ranges[this.mainIndex]}asSingle(){return 1==this.ranges.length?this:new G([this.main],0)}addRange(e,t=!0){return G.create([e].concat(this.ranges),t?0:this.mainIndex+1)}replaceRange(e,t=this.mainIndex){let n=this.ranges.slice();return n[t]=e,G.create(n,this.mainIndex)}toJSON(){return{ranges:this.ranges.map(e=>e.toJSON()),main:this.mainIndex}}static fromJSON(e){if(!e||!Array.isArray(e.ranges)||"number"!=typeof e.main||e.main>=e.ranges.length)throw new RangeError("Invalid JSON representation for EditorSelection");return new G(e.ranges.map(e=>U.fromJSON(e)),e.main)}static single(e,t=e){return new G([G.range(e,t)],0)}static create(e,t=0){if(0==e.length)throw new RangeError("A selection needs at least one range");for(let n=0,r=0;r<e.length;r++){let i=e[r];if(i.empty?i.from<=n:i.from<n)return G.normalized(e.slice(),t);n=i.to}return new G(e,t)}static cursor(e,t=0,n,r){return U.create(e,e,(0==t?0:t<0?8:16)|(null==n?7:Math.min(6,n)),r)}static range(e,t,n,r,i){let o=null==r?7:Math.min(6,r);return i||e==t||(i=t<e?1:-1),i&&(o|=i<0?8:16),t<e?U.create(t,e,32|o,n):U.create(e,t,o,n)}static undirectionalRange(e,t){return U.create(e,t,64,void 0)}static normalized(e,t=0){let n=e[t];e.sort((e,t)=>e.from-t.from),t=e.indexOf(n);for(let r=1;r<e.length;r++){let n=e[r],i=e[r-1];if(n.empty?n.from<=i.to:n.from<i.to){let o=i.from,a=Math.max(n.to,i.to);r<=t&&t--,e.splice(--r,2,n.anchor>n.head?G.range(a,o):G.range(o,a))}}return new G(e,t)}}function H(e,t){for(let n of e.ranges)if(n.to>t)throw new RangeError("Selection points outside of document")}let q=0;class Q{constructor(e,t,n,r,i){this.combine=e,this.compareInput=t,this.compare=n,this.isStatic=r,this.id=q++,this.default=e([]),this.extensions="function"==typeof i?i(this):i}get reader(){return this}static define(e={}){return new Q(e.combine||(e=>e),e.compareInput||((e,t)=>e===t),e.compare||(e.combine?(e,t)=>e===t:z),!!e.static,e.enables)}of(e){return new K([],this,0,e)}compute(e,t){if(this.isStatic)throw new Error("Can't compute a static facet");return new K(e,this,1,t)}computeN(e,t){if(this.isStatic)throw new Error("Can't compute a static facet");return new K(e,this,2,t)}from(e,t){return t||(t=e=>e),this.compute([e],n=>t(n.field(e)))}}function z(e,t){return e==t||e.length==t.length&&e.every((e,n)=>e===t[n])}class K{constructor(e,t,n,r){this.dependencies=e,this.facet=t,this.type=n,this.value=r,this.id=q++}dynamicSlot(e){var t;let n=this.value,r=this.facet.compareInput,i=this.id,o=e[i]>>1,a=2==this.type,s=!1,l=!1,c=[];for(let u of this.dependencies)"doc"==u?s=!0:"selection"==u?l=!0:0==(1&(null!==(t=e[u.id])&&void 0!==t?t:1))&&c.push(e[u.id]);return{create(e){return e.values[o]=n(e),1},update(e,t){if(s&&t.docChanged||l&&(t.docChanged||t.selection)||X(e,c)){let t=n(e);if(a?!W(t,e.values[o],r):!r(t,e.values[o]))return e.values[o]=t,1}return 0},reconfigure:(e,t)=>{let s,l=t.config.address[i];if(null!=l){let i=ce(t,l);if(this.dependencies.every(n=>n instanceof Q?t.facet(n)===e.facet(n):!(n instanceof J)||t.field(n,!1)==e.field(n,!1))||(a?W(s=n(e),i,r):r(s=n(e),i)))return e.values[o]=i,0}else s=n(e);return e.values[o]=s,1}}}get extension(){return this}}function W(e,t,n){if(e.length!=t.length)return!1;for(let r=0;r<e.length;r++)if(!n(e[r],t[r]))return!1;return!0}function X(e,t){let n=!1;for(let r of t)1&le(e,r)&&(n=!0);return n}function Y(e,t,n){let r=n.map(t=>e[t.id]),i=n.map(e=>e.type),o=r.filter(e=>!(1&e)),a=e[t.id]>>1;function s(e){let n=[];for(let t=0;t<r.length;t++){let o=ce(e,r[t]);if(2==i[t])for(let e of o)n.push(e);else n.push(o)}return t.combine(n)}return{create(e){for(let t of r)le(e,t);return e.values[a]=s(e),1},update(e,n){if(!X(e,o))return 0;let r=s(e);return t.compare(r,e.values[a])?0:(e.values[a]=r,1)},reconfigure(e,i){let o=X(e,r),l=i.config.facets[t.id],c=i.facet(t);if(l&&!o&&z(n,l))return e.values[a]=c,0;let u=s(e);return t.compare(u,c)?(e.values[a]=c,0):(e.values[a]=u,1)}}}const Z=Q.define({static:!0});class J{constructor(e,t,n,r,i){this.id=e,this.createF=t,this.updateF=n,this.compareF=r,this.spec=i,this.provides=void 0}static define(e){let t=new J(q++,e.create,e.update,e.compare||((e,t)=>e===t),e);return e.provide&&(t.provides=e.provide(t)),t}create(e){let t=e.facet(Z).find(e=>e.field==this);return((null===t||void 0===t?void 0:t.create)||this.createF)(e)}slot(e){let t=e[this.id]>>1;return{create:e=>(e.values[t]=this.create(e),1),update:(e,n)=>{let r=e.values[t],i=this.updateF(r,n);return this.compareF(r,i)?0:(e.values[t]=i,1)},reconfigure:(e,n)=>{let r,i=e.facet(Z),o=n.facet(Z);return(r=i.find(e=>e.field==this))&&r!=o.find(e=>e.field==this)?(e.values[t]=r.create(e),1):null!=n.config.address[this.id]?(e.values[t]=n.field(this),0):(e.values[t]=this.create(e),1)}}}init(e){return[this,Z.of({field:this,create:e})]}get extension(){return this}}const ee={lowest:4,low:3,default:2,high:1,highest:0};function te(e){return t=>new re(t,e)}const ne={highest:te(ee.highest),high:te(ee.high),default:te(ee.default),low:te(ee.low),lowest:te(ee.lowest)};class re{constructor(e,t){this.inner=e,this.prec=t}get extension(){return this}}class ie{of(e){return new oe(this,e)}reconfigure(e){return ie.reconfigure.of({compartment:this,extension:e})}get(e){return e.config.compartments.get(this)}}class oe{constructor(e,t){this.compartment=e,this.inner=t}get extension(){return this}}class ae{constructor(e,t,n,r,i,o){this.base=e,this.compartments=t,this.dynamicSlots=n,this.address=r,this.staticValues=i,this.facets=o,this.statusTemplate=[];while(this.statusTemplate.length<n.length)this.statusTemplate.push(0)}staticFacet(e){let t=this.address[e.id];return null==t?e.default:this.staticValues[t>>1]}static resolve(e,t,n){let r=[],i=Object.create(null),o=new Map;for(let d of se(e,t,o))d instanceof J?r.push(d):(i[d.facet.id]||(i[d.facet.id]=[])).push(d);let a=Object.create(null),s=[],l=[];for(let d of r)a[d.id]=l.length<<1,l.push(e=>d.slot(e));let c=null===n||void 0===n?void 0:n.config.facets;for(let d in i){let e=i[d],t=e[0].facet,r=c&&c[d]||[];if(e.every(e=>0==e.type))if(a[t.id]=s.length<<1|1,z(r,e))s.push(n.facet(t));else{let r=t.combine(e.map(e=>e.value));s.push(n&&t.compare(r,n.facet(t))?n.facet(t):r)}else{for(let t of e)0==t.type?(a[t.id]=s.length<<1|1,s.push(t.value)):(a[t.id]=l.length<<1,l.push(e=>t.dynamicSlot(e)));a[t.id]=l.length<<1,l.push(n=>Y(n,t,e))}}let u=l.map(e=>e(a));return new ae(e,o,u,a,s,i)}}function se(e,t,n){let r=[[],[],[],[],[]],i=new Map;function o(e,a){let s=i.get(e);if(null!=s){if(s<=a)return;let t=r[s].indexOf(e);t>-1&&r[s].splice(t,1),e instanceof oe&&n.delete(e.compartment)}if(i.set(e,a),Array.isArray(e))for(let t of e)o(t,a);else if(e instanceof oe){if(n.has(e.compartment))throw new RangeError("Duplicate use of compartment in extensions");let r=t.get(e.compartment)||e.inner;n.set(e.compartment,r),o(r,a)}else if(e instanceof re)o(e.inner,e.prec);else if(e instanceof J)r[a].push(e),e.provides&&o(e.provides,a);else if(e instanceof K)r[a].push(e),e.facet.extensions&&o(e.facet.extensions,ee.default);else{let t=e.extension;if(!t)throw new Error(`Unrecognized extension value in extension set (${e}).`);if(t==e)throw new Error(`Unrecognized extension value in extension set (${e}). This sometimes happens because multiple instances of @codemirror/state are loaded, breaking instanceof checks.`);o(t,a)}}return o(e,ee.default),r.reduce((e,t)=>e.concat(t))}function le(e,t){if(1&t)return 2;let n=t>>1,r=e.status[n];if(4==r)throw new Error("Cyclic dependency between fields and/or facets");if(2&r)return r;e.status[n]=4;let i=e.computeSlot(e,e.config.dynamicSlots[n]);return e.status[n]=2|i}function ce(e,t){return 1&t?e.config.staticValues[t>>1]:e.values[t>>1]}const ue=Q.define(),de=Q.define({combine:e=>e.some(e=>e),static:!0}),he=Q.define({combine:e=>e.length?e[0]:void 0,static:!0}),pe=Q.define(),fe=Q.define(),me=Q.define(),ge=Q.define({combine:e=>!!e.length&&e[0]});class ve{constructor(e,t){this.type=e,this.value=t}static define(){return new be}}class be{of(e){return new ve(this,e)}}class ye{constructor(e){this.map=e}of(e){return new we(this,e)}}class we{constructor(e,t){this.type=e,this.value=t}map(e){let t=this.type.map(this.value,e);return void 0===t?void 0:t==this.value?this:new we(this.type,t)}is(e){return this.type==e}static define(e={}){return new ye(e.map||(e=>e))}static mapEffects(e,t){if(!e.length)return e;let n=[];for(let r of e){let e=r.map(t);e&&n.push(e)}return n}}we.reconfigure=we.define(),we.appendConfig=we.define();class Oe{constructor(e,t,n,r,i,o){this.startState=e,this.changes=t,this.selection=n,this.effects=r,this.annotations=i,this.scrollIntoView=o,this._doc=null,this._state=null,n&&H(n,t.newLength),i.some(e=>e.type==Oe.time)||(this.annotations=i.concat(Oe.time.of(Date.now())))}static create(e,t,n,r,i,o){return new Oe(e,t,n,r,i,o)}get newDoc(){return this._doc||(this._doc=this.changes.apply(this.startState.doc))}get newSelection(){return this.selection||this.startState.selection.map(this.changes)}get state(){return this._state||this.startState.applyTransaction(this),this._state}annotation(e){for(let t of this.annotations)if(t.type==e)return t.value}get docChanged(){return!this.changes.empty}get reconfigured(){return this.startState.config!=this.state.config}isUserEvent(e){let t=this.annotation(Oe.userEvent);return!(!t||!(t==e||t.length>e.length&&t.slice(0,e.length)==e&&"."==t[e.length]))}}function Se(e,t){let n=[];for(let r=0,i=0;;){let o,a;if(r<e.length&&(i==t.length||t[i]>=e[r]))o=e[r++],a=e[r++];else{if(!(i<t.length))return n;o=t[i++],a=t[i++]}!n.length||n[n.length-1]<o?n.push(o,a):n[n.length-1]<a&&(n[n.length-1]=a)}}function Ee(e,t,n){var r;let i,o,a;return n?(i=t.changes,o=D.empty(t.changes.length),a=e.changes.compose(t.changes)):(i=t.changes.map(e.changes),o=e.changes.mapDesc(t.changes,!0),a=e.changes.compose(i)),{changes:a,selection:t.selection?t.selection.map(o):null===(r=e.selection)||void 0===r?void 0:r.map(i),effects:we.mapEffects(e.effects,i).concat(we.mapEffects(t.effects,o)),annotations:e.annotations.length?e.annotations.concat(t.annotations):t.annotations,scrollIntoView:e.scrollIntoView||t.scrollIntoView}}function xe(e,t,n){let r=t.selection,i=Te(t.annotations);return t.userEvent&&(i=i.concat(Oe.userEvent.of(t.userEvent))),{changes:t.changes instanceof D?t.changes:D.of(t.changes||[],n,e.facet(he)),selection:r&&(r instanceof G?r:G.single(r.anchor,r.head)),effects:Te(t.effects),annotations:i,scrollIntoView:!!t.scrollIntoView}}function _e(e,t,n){let r=xe(e,t.length?t[0]:{},e.doc.length);t.length&&!1===t[0].filter&&(n=!1);for(let o=1;o<t.length;o++){!1===t[o].filter&&(n=!1);let i=!!t[o].sequential;r=Ee(r,xe(e,t[o],i?r.changes.newLength:e.doc.length),i)}let i=Oe.create(e,r.changes,r.selection,r.effects,r.annotations,r.scrollIntoView);return Ce(n?ke(i):i)}function ke(e){let t=e.startState,n=!0;for(let i of t.facet(pe)){let t=i(e);if(!1===t){n=!1;break}Array.isArray(t)&&(n=!0===n?t:Se(n,t))}if(!0!==n){let r,i;if(!1===n)i=e.changes.invertedDesc,r=D.empty(t.doc.length);else{let t=e.changes.filter(n);r=t.changes,i=t.filtered.mapDesc(t.changes).invertedDesc}e=Oe.create(t,r,e.selection&&e.selection.map(i),we.mapEffects(e.effects,i),e.annotations,e.scrollIntoView)}let r=t.facet(fe);for(let i=r.length-1;i>=0;i--){let n=r[i](e);e=n instanceof Oe?n:Array.isArray(n)&&1==n.length&&n[0]instanceof Oe?n[0]:_e(t,Te(n),!1)}return e}function Ce(e){let t=e.startState,n=t.facet(me),r=e;for(let i=n.length-1;i>=0;i--){let o=n[i](e);o&&Object.keys(o).length&&(r=Ee(r,xe(t,o,e.changes.newLength),!0))}return r==e?e:Oe.create(t,e.changes,e.selection,r.effects,r.annotations,r.scrollIntoView)}Oe.time=ve.define(),Oe.userEvent=ve.define(),Oe.addToHistory=ve.define(),Oe.remote=ve.define();const Ae=[];function Te(e){return null==e?Ae:Array.isArray(e)?e:[e]}var Re=function(e){return e[e["Word"]=0]="Word",e[e["Space"]=1]="Space",e[e["Other"]=2]="Other",e}(Re||(Re={}));const Ne=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/;let Pe;try{Pe=new RegExp("[\\p{Alphabetic}\\p{Number}_]","u")}catch(it){}function Ie(e){if(Pe)return Pe.test(e);for(let t=0;t<e.length;t++){let n=e[t];if(/\w/.test(n)||n>""&&(n.toUpperCase()!=n.toLowerCase()||Ne.test(n)))return!0}return!1}function Me(e){return t=>{if(!/\S/.test(t))return Re.Space;if(Ie(t))return Re.Word;for(let n=0;n<e.length;n++)if(t.indexOf(e[n])>-1)return Re.Word;return Re.Other}}class De{constructor(e,t,n,r,i,o){this.config=e,this.doc=t,this.selection=n,this.values=r,this.status=e.statusTemplate.slice(),this.computeSlot=i,o&&(o._state=this);for(let a=0;a<this.config.dynamicSlots.length;a++)le(this,a<<1);this.computeSlot=null}field(e,t=!0){let n=this.config.address[e.id];if(null!=n)return le(this,n),ce(this,n);if(t)throw new RangeError("Field is not present in this state")}update(...e){return _e(this,e,!0)}applyTransaction(e){let t,n=this.config,{base:r,compartments:i}=n;for(let a of e.effects)a.is(ie.reconfigure)?(n&&(i=new Map,n.compartments.forEach((e,t)=>i.set(t,e)),n=null),i.set(a.value.compartment,a.value.extension)):a.is(we.reconfigure)?(n=null,r=a.value):a.is(we.appendConfig)&&(n=null,r=Te(r).concat(a.value));if(n)t=e.startState.values.slice();else{n=ae.resolve(r,i,this);let e=new De(n,this.doc,this.selection,n.dynamicSlots.map(()=>null),(e,t)=>t.reconfigure(e,this),null);t=e.values}let o=e.startState.facet(de)?e.newSelection:e.newSelection.asSingle();new De(n,e.newDoc,o,t,(t,n)=>n.update(t,e),e)}replaceSelection(e){return"string"==typeof e&&(e=this.toText(e)),this.changeByRange(t=>({changes:{from:t.from,to:t.to,insert:e},range:G.cursor(t.from+e.length,-1)}))}changeByRange(e){let t=this.selection,n=e(t.ranges[0]),r=this.changes(n.changes),i=[n.range],o=Te(n.effects);for(let a=1;a<t.ranges.length;a++){let n=e(t.ranges[a]),s=this.changes(n.changes),l=s.map(r);for(let e=0;e<a;e++)i[e]=i[e].map(l);let c=r.mapDesc(s,!0);i.push(n.range.map(c)),r=r.compose(l),o=we.mapEffects(o,l).concat(we.mapEffects(Te(n.effects),c))}return{changes:r,selection:G.create(i,t.mainIndex),effects:o}}changes(e=[]){return e instanceof D?e:D.of(e,this.doc.length,this.facet(De.lineSeparator))}toText(e){return m.of(e.split(this.facet(De.lineSeparator)||P))}sliceDoc(e=0,t=this.doc.length){return this.doc.sliceString(e,t,this.lineBreak)}facet(e){let t=this.config.address[e.id];return null==t?e.default:(le(this,t),ce(this,t))}toJSON(e){let t={doc:this.sliceDoc(),selection:this.selection.toJSON()};if(e)for(let n in e){let r=e[n];r instanceof J&&null!=this.config.address[r.id]&&(t[n]=r.spec.toJSON(this.field(e[n]),this))}return t}static fromJSON(e,t={},n){if(!e||"string"!=typeof e.doc)throw new RangeError("Invalid JSON representation for EditorState");let r=[];if(n)for(let i in n)if(Object.prototype.hasOwnProperty.call(e,i)){let t=n[i],o=e[i];r.push(t.init(e=>t.spec.fromJSON(o,e)))}return De.create({doc:e.doc,selection:G.fromJSON(e.selection),extensions:t.extensions?r.concat([t.extensions]):r})}static create(e={}){let t=ae.resolve(e.extensions||[],new Map),n=e.doc instanceof m?e.doc:m.of((e.doc||"").split(t.staticFacet(De.lineSeparator)||P)),r=e.selection?e.selection instanceof G?e.selection:G.single(e.selection.anchor,e.selection.head):G.single(0);return H(r,n.length),t.staticFacet(de)||(r=r.asSingle()),new De(t,n,r,t.dynamicSlots.map(()=>null),(e,t)=>t.create(e),null)}get tabSize(){return this.facet(De.tabSize)}get lineBreak(){return this.facet(De.lineSeparator)||"\n"}get readOnly(){return this.facet(ge)}phrase(e,...t){for(let n of this.facet(De.phrases))if(Object.prototype.hasOwnProperty.call(n,e)){e=n[e];break}return t.length&&(e=e.replace(/\$(\$|\d*)/g,(e,n)=>{if("$"==n)return"$";let r=+(n||1);return!r||r>t.length?e:t[r-1]})),e}languageDataAt(e,t,n=-1){let r=[];for(let i of this.facet(ue))for(let o of i(this,t,n))Object.prototype.hasOwnProperty.call(o,e)&&r.push(o[e]);return r}charCategorizer(e){let t=this.languageDataAt("wordChars",e);return Me(t.length?t[0]:"")}wordAt(e){let{text:t,from:n,length:r}=this.doc.lineAt(e),i=this.charCategorizer(e),o=e-n,a=e-n;while(o>0){let e=k(t,o,!1);if(i(t.slice(e,o))!=Re.Word)break;o=e}while(a<r){let e=k(t,a);if(i(t.slice(a,e))!=Re.Word)break;a=e}return o==a?null:G.range(o+n,a+n)}}function Le(e,t,n={}){let r={};for(let i of e)for(let e of Object.keys(i)){let t=i[e],o=r[e];if(void 0===o)r[e]=t;else if(o===t||void 0===t);else{if(!Object.hasOwnProperty.call(n,e))throw new Error("Config merge conflict for field "+e);r[e]=n[e](o,t)}}for(let i in t)void 0===r[i]&&(r[i]=t[i]);return r}De.allowMultipleSelections=de,De.tabSize=Q.define({combine:e=>e.length?e[0]:4}),De.lineSeparator=he,De.readOnly=ge,De.phrases=Q.define({compare(e,t){let n=Object.keys(e),r=Object.keys(t);return n.length==r.length&&n.every(n=>e[n]==t[n])}}),De.languageData=ue,De.changeFilter=pe,De.transactionFilter=fe,De.transactionExtender=me,ie.reconfigure=we.define();class Be{eq(e){return this==e}range(e,t=e){return Ve.create(e,t,this)}}function $e(e,t){return e==t||e.constructor==t.constructor&&e.eq(t)}Be.prototype.startSide=Be.prototype.endSide=0,Be.prototype.point=!1,Be.prototype.mapMode=I.TrackDel;class Ve{constructor(e,t,n){this.from=e,this.to=t,this.value=n}static create(e,t,n){return new Ve(e,t,n)}}function Fe(e,t){return e.from-t.from||e.value.startSide-t.value.startSide}class je{constructor(e,t,n,r){this.from=e,this.to=t,this.value=n,this.maxPoint=r}get length(){return Ge(this.to)}findIndex(e,t,n,r=0){let i=n?this.to:this.from;for(let o=r,a=i.length;;){if(o==a)return o;let r=o+a>>1,s=i[r]-e||(n?this.value[r].endSide:this.value[r].startSide)-t;if(r==o)return s>=0?o:a;s>=0?a=r:o=r+1}}between(e,t,n,r){for(let i=this.findIndex(t,-1e9,!0),o=this.findIndex(n,1e9,!1,i);i<o;i++)if(!1===r(this.from[i]+e,this.to[i]+e,this.value[i]))return!1}map(e,t,n,r,i){let o=[],a=[],s=[],l=-1,c=-1;e:for(let u=0;u<this.value.length;u++){let d,h,p=this.value[u],f=this.from[u]+e,m=this.to[u]+e;if(f==m){let e=t.mapPos(f,p.startSide,p.mapMode);if(null==e)continue;if(d=h=e,p.startSide!=p.endSide&&(h=t.mapPos(f,p.endSide),h<d))continue}else if(d=t.mapPos(f,p.startSide),h=t.mapPos(m,p.endSide),d>h||d==h&&p.startSide>0&&p.endSide<=0)continue;if(!((h-d||p.endSide-p.startSide)<0))if(l<0&&(l=d),p.point&&(c=Math.max(c,h-d)),(d-n||p.startSide-r)>=0)o.push(p),a.push(d-l),s.push(h-l),n=h,r=p.endSide;else{if(d==h)for(let e=o.length;e>0;e--){if((d-(s[e-1]+l)||p.startSide-o[e-1].endSide)>=0){o.splice(e,0,p),a.splice(e,0,d-l),s.splice(e,0,h-l);continue e}if((d-(a[e-1]+l)||p.endSide-o[e-1].startSide)>0)break}i(d,h,p)}}return{mapped:o.length?new je(a,s,o,c):null,pos:l}}}class Ue{constructor(e,t,n,r){this.chunkPos=e,this.chunk=t,this.nextLayer=n,this.maxPoint=r}static create(e,t,n,r){return new Ue(e,t,n,r)}get length(){let e=this.chunk.length-1;return e<0?0:Math.max(this.chunkEnd(e),this.nextLayer.length)}get size(){if(this.isEmpty)return 0;let e=this.nextLayer.size;for(let t of this.chunk)e+=t.value.length;return e}chunkEnd(e){return this.chunkPos[e]+this.chunk[e].length}update(e){let{add:t=[],sort:n=!1,filterFrom:r=0,filterTo:i=this.length}=e,o=e.filter;if(0==t.length&&!o)return this;if(n&&(t=t.slice().sort(Fe)),this.isEmpty)return t.length?Ue.of(t):this;let a=new ze(this,null,-1).goto(0),s=0,l=[],c=new qe;while(a.value||s<t.length)if(s<t.length&&(a.from-t[s].from||a.startSide-t[s].value.startSide)>=0){let e=t[s++];c.addInner(e.from,e.to,e.value,!1)||l.push(e)}else 1==a.rangeIndex&&a.chunkIndex<this.chunk.length&&(s==t.length||this.chunkEnd(a.chunkIndex)<t[s].from)&&(!o||r>this.chunkEnd(a.chunkIndex)||i<this.chunkPos[a.chunkIndex])&&c.addChunk(this.chunkPos[a.chunkIndex],this.chunk[a.chunkIndex])?a.nextChunk():((!o||r>a.to||i<a.from||o(a.from,a.to,a.value))&&(c.addInner(a.from,a.to,a.value,!1)||l.push(Ve.create(a.from,a.to,a.value))),a.next());return c.finishInner(this.nextLayer.isEmpty&&!l.length?Ue.empty:this.nextLayer.update({add:l,filter:o,filterFrom:r,filterTo:i}))}map(e){if(e.empty||this.isEmpty)return this;let t,n=[],r=[],i=-1,o=(e,n,r)=>{t||(t=new qe),t.addRange(e,n,r,!1)};for(let s=0;s<this.chunk.length;s++){let t=this.chunkPos[s],a=this.chunk[s],l=e.touchesRange(t,t+a.length);if(!1===l)i=Math.max(i,a.maxPoint),n.push(a),r.push(e.mapPos(t));else if(!0===l){let[s,l]=n.length?[Ge(r)+Ge(n).length,Ge(Ge(n).value).endSide]:[-1,-1],{mapped:c,pos:u}=a.map(t,e,s,l,o);c&&(i=Math.max(i,c.maxPoint),n.push(c),r.push(u))}}let a=this.nextLayer.map(e);return t&&(a=t.finishInner(a)),0==n.length?a:new Ue(r,n,a||Ue.empty,i)}between(e,t,n){if(!this.isEmpty){for(let r=0;r<this.chunk.length;r++){let i=this.chunkPos[r],o=this.chunk[r];if(t>=i&&e<=i+o.length&&!1===o.between(i,e-i,t-i,n))return}this.nextLayer.between(e,t,n)}}iter(e=0){return Ke.from([this]).goto(e)}get isEmpty(){return this.nextLayer==this}static iter(e,t=0){return Ke.from(e).goto(t)}static compare(e,t,n,r,i=-1){let o=e.filter(e=>e.maxPoint>0||!e.isEmpty&&e.maxPoint>=i),a=t.filter(e=>e.maxPoint>0||!e.isEmpty&&e.maxPoint>=i),s=Qe(o,a,n),l=new Xe(o,s,i),c=new Xe(a,s,i);n.iterGaps((e,t,n)=>Ye(l,e,c,t,n,r)),n.empty&&0==n.length&&Ye(l,0,c,0,0,r)}static eq(e,t,n=0,r){null==r&&(r=999999999);let i=e.filter(e=>!e.isEmpty&&t.indexOf(e)<0),o=t.filter(t=>!t.isEmpty&&e.indexOf(t)<0);if(i.length!=o.length)return!1;if(!i.length)return!0;let a=Qe(i,o),s=new Xe(i,a,0).goto(n),l=new Xe(o,a,0).goto(n);for(;;){if(s.to!=l.to||!Ze(s.active,l.active)||s.point&&(!l.point||!$e(s.point,l.point)))return!1;if(s.to>r)return!0;s.next(),l.next()}}static spans(e,t,n,r,i=-1){let o=new Xe(e,null,i).goto(t),a=t,s=o.openStart;for(;;){let e=Math.min(o.to,n);if(o.point){let n=o.activeForPoint(o.to),i=o.pointFrom<t?n.length+1:o.point.startSide<0?n.length:Math.min(n.length,s);r.point(a,e,o.point,n,i,o.pointRank),s=Math.min(o.openEnd(e),n.length)}else e>a&&(r.span(a,e,o.active,s),s=o.openEnd(e));if(o.to>n)return s+(o.point&&o.to>n?1:0);a=o.to,o.next()}}static of(e,t=!1){let n=new qe;for(let r of e instanceof Ve?[e]:t?He(e):e)n.add(r.from,r.to,r.value);return n.finish()}static join(e){if(!e.length)return Ue.empty;let t=Ge(e);for(let n=e.length-2;n>=0;n--)for(let r=e[n];r!=Ue.empty;r=r.nextLayer)t=new Ue(r.chunkPos,r.chunk,t,Math.max(r.maxPoint,t.maxPoint));return t}}function Ge(e){return e[e.length-1]}function He(e){if(e.length>1)for(let t=e[0],n=1;n<e.length;n++){let r=e[n];if(Fe(t,r)>0)return e.slice().sort(Fe);t=r}return e}Ue.empty=new Ue([],[],null,-1),Ue.empty.nextLayer=Ue.empty;class qe{finishChunk(e){this.chunks.push(new je(this.from,this.to,this.value,this.maxPoint)),this.chunkPos.push(this.chunkStart),this.chunkStart=-1,this.setMaxPoint=Math.max(this.setMaxPoint,this.maxPoint),this.maxPoint=-1,e&&(this.from=[],this.to=[],this.value=[])}constructor(){this.chunks=[],this.chunkPos=[],this.chunkStart=-1,this.last=null,this.lastFrom=-1e9,this.lastTo=-1e9,this.from=[],this.to=[],this.value=[],this.maxPoint=-1,this.setMaxPoint=-1,this.nextLayer=null}add(e,t,n){this.addRange(e,t,n,!0)}addRange(e,t,n,r){this.addInner(e,t,n,r)||(this.nextLayer||(this.nextLayer=new qe)).addRange(e,t,n,r)}addInner(e,t,n,r){let i=e-this.lastTo||n.startSide-this.last.endSide;if(r&&i<=0&&(e-this.lastFrom||n.startSide-this.last.startSide)<0)throw new Error("Ranges must be added sorted by `from` position and `startSide`");return!(i<0)&&(250==this.from.length&&this.finishChunk(!0),this.chunkStart<0&&(this.chunkStart=e),this.from.push(e-this.chunkStart),this.to.push(t-this.chunkStart),this.last=n,this.lastFrom=e,this.lastTo=t,this.value.push(n),n.point&&(this.maxPoint=Math.max(this.maxPoint,t-e)),!0)}addChunk(e,t){if((e-this.lastTo||t.value[0].startSide-this.last.endSide)<0)return!1;this.from.length&&this.finishChunk(!0),this.setMaxPoint=Math.max(this.setMaxPoint,t.maxPoint),this.chunks.push(t),this.chunkPos.push(e);let n=t.value.length-1;return this.last=t.value[n],this.lastFrom=t.from[n]+e,this.lastTo=t.to[n]+e,!0}finish(){return this.finishInner(Ue.empty)}finishInner(e){if(this.from.length&&this.finishChunk(!1),0==this.chunks.length)return e;let t=Ue.create(this.chunkPos,this.chunks,this.nextLayer?this.nextLayer.finishInner(e):e,this.setMaxPoint);return this.from=null,t}}function Qe(e,t,n){let r=new Map;for(let o of e)for(let e=0;e<o.chunk.length;e++)o.chunk[e].maxPoint<=0&&r.set(o.chunk[e],o.chunkPos[e]);let i=new Set;for(let o of t)for(let e=0;e<o.chunk.length;e++){let t=r.get(o.chunk[e]);null==t||(n?n.mapPos(t):t)!=o.chunkPos[e]||(null===n||void 0===n?void 0:n.touchesRange(t,t+o.chunk[e].length))||i.add(o.chunk[e])}return i}class ze{constructor(e,t,n,r=0){this.layer=e,this.skip=t,this.minPoint=n,this.rank=r}get startSide(){return this.value?this.value.startSide:0}get endSide(){return this.value?this.value.endSide:0}goto(e,t=-1e9){return this.chunkIndex=this.rangeIndex=0,this.gotoInner(e,t,!1),this}gotoInner(e,t,n){while(this.chunkIndex<this.layer.chunk.length){let t=this.layer.chunk[this.chunkIndex];if(!(this.skip&&this.skip.has(t)||this.layer.chunkEnd(this.chunkIndex)<e||t.maxPoint<this.minPoint))break;this.chunkIndex++,n=!1}if(this.chunkIndex<this.layer.chunk.length){let r=this.layer.chunk[this.chunkIndex].findIndex(e-this.layer.chunkPos[this.chunkIndex],t,!0);(!n||this.rangeIndex<r)&&this.setRangeIndex(r)}this.next()}forward(e,t){(this.to-e||this.endSide-t)<0&&this.gotoInner(e,t,!0)}next(){for(;;){if(this.chunkIndex==this.layer.chunk.length){this.from=this.to=1e9,this.value=null;break}{let e=this.layer.chunkPos[this.chunkIndex],t=this.layer.chunk[this.chunkIndex],n=e+t.from[this.rangeIndex];if(this.from=n,this.to=e+t.to[this.rangeIndex],this.value=t.value[this.rangeIndex],this.setRangeIndex(this.rangeIndex+1),this.minPoint<0||this.value.point&&this.to-this.from>=this.minPoint)break}}}setRangeIndex(e){if(e==this.layer.chunk[this.chunkIndex].value.length){if(this.chunkIndex++,this.skip)while(this.chunkIndex<this.layer.chunk.length&&this.skip.has(this.layer.chunk[this.chunkIndex]))this.chunkIndex++;this.rangeIndex=0}else this.rangeIndex=e}nextChunk(){this.chunkIndex++,this.rangeIndex=0,this.next()}compare(e){return this.from-e.from||this.startSide-e.startSide||this.rank-e.rank||this.to-e.to||this.endSide-e.endSide}}class Ke{constructor(e){this.heap=e}static from(e,t=null,n=-1){let r=[];for(let i=0;i<e.length;i++)for(let o=e[i];!o.isEmpty;o=o.nextLayer)o.maxPoint>=n&&r.push(new ze(o,t,n,i));return 1==r.length?r[0]:new Ke(r)}get startSide(){return this.value?this.value.startSide:0}goto(e,t=-1e9){for(let n of this.heap)n.goto(e,t);for(let n=this.heap.length>>1;n>=0;n--)We(this.heap,n);return this.next(),this}forward(e,t){for(let n of this.heap)n.forward(e,t);for(let n=this.heap.length>>1;n>=0;n--)We(this.heap,n);(this.to-e||this.value.endSide-t)<0&&this.next()}next(){if(0==this.heap.length)this.from=this.to=1e9,this.value=null,this.rank=-1;else{let e=this.heap[0];this.from=e.from,this.to=e.to,this.value=e.value,this.rank=e.rank,e.value&&e.next(),We(this.heap,0)}}}function We(e,t){for(let n=e[t];;){let r=1+(t<<1);if(r>=e.length)break;let i=e[r];if(r+1<e.length&&i.compare(e[r+1])>=0&&(i=e[r+1],r++),n.compare(i)<0)break;e[r]=n,e[t]=i,t=r}}class Xe{constructor(e,t,n){this.minPoint=n,this.active=[],this.activeTo=[],this.activeRank=[],this.minActive=-1,this.point=null,this.pointFrom=0,this.pointRank=0,this.to=-1e9,this.endSide=0,this.openStart=-1,this.cursor=Ke.from(e,t,n)}goto(e,t=-1e9){return this.cursor.goto(e,t),this.active.length=this.activeTo.length=this.activeRank.length=0,this.minActive=-1,this.to=e,this.endSide=t,this.openStart=-1,this.next(),this}forward(e,t){while(this.minActive>-1&&(this.activeTo[this.minActive]-e||this.active[this.minActive].endSide-t)<0)this.removeActive(this.minActive);this.cursor.forward(e,t)}removeActive(e){Je(this.active,e),Je(this.activeTo,e),Je(this.activeRank,e),this.minActive=tt(this.active,this.activeTo)}addActive(e){let t=0,{value:n,to:r,rank:i}=this.cursor;while(t<this.activeRank.length&&(i-this.activeRank[t]||r-this.activeTo[t])>0)t++;et(this.active,t,n),et(this.activeTo,t,r),et(this.activeRank,t,i),e&&et(e,t,this.cursor.from),this.minActive=tt(this.active,this.activeTo)}next(){let e=this.to,t=this.point;this.point=null;let n=this.openStart<0?[]:null;for(;;){let r=this.minActive;if(r>-1&&(this.activeTo[r]-this.cursor.from||this.active[r].endSide-this.cursor.startSide)<0){if(this.activeTo[r]>e){this.to=this.activeTo[r],this.endSide=this.active[r].endSide;break}this.removeActive(r),n&&Je(n,r)}else{if(!this.cursor.value){this.to=this.endSide=1e9;break}if(this.cursor.from>e){this.to=this.cursor.from,this.endSide=this.cursor.startSide;break}{let e=this.cursor.value;if(e.point){if(!(t&&this.cursor.to==this.to&&this.cursor.from<this.cursor.to)){this.point=e,this.pointFrom=this.cursor.from,this.pointRank=this.cursor.rank,this.to=this.cursor.to,this.endSide=e.endSide,this.cursor.next(),this.forward(this.to,this.endSide);break}this.cursor.next()}else this.addActive(n),this.cursor.next()}}}if(n){this.openStart=0;for(let t=n.length-1;t>=0&&n[t]<e;t--)this.openStart++}}activeForPoint(e){if(!this.active.length)return this.active;let t=[];for(let n=this.active.length-1;n>=0;n--){if(this.activeRank[n]<this.pointRank)break;(this.activeTo[n]>e||this.activeTo[n]==e&&this.active[n].endSide>=this.point.endSide)&&t.push(this.active[n])}return t.reverse()}openEnd(e){let t=0;for(let n=this.activeTo.length-1;n>=0&&this.activeTo[n]>e;n--)t++;return t}}function Ye(e,t,n,r,i,o){e.goto(t),n.goto(r);let a=r+i,s=r,l=r-t,c=!!o.boundChange;for(let u=!1;;){let t=e.to+l-n.to,r=t||e.endSide-n.endSide,i=r<0?e.to+l:n.to,d=Math.min(i,a),h=e.point||n.point;if(h?(e.point&&n.point&&$e(e.point,n.point)&&Ze(e.activeForPoint(e.to),n.activeForPoint(n.to))||o.comparePoint(s,d,e.point,n.point),u=!1):(u&&(o.boundChange(s),u=!1),d>s&&!Ze(e.active,n.active)&&o.compareRange(s,d,e.active,n.active),c&&d<a&&(t||e.openEnd(i)!=n.openEnd(i))&&(u=!0)),i>a)break;s=i,r<=0&&e.next(),r>=0&&n.next()}}function Ze(e,t){if(e.length!=t.length)return!1;for(let n=0;n<e.length;n++)if(e[n]!=t[n]&&!$e(e[n],t[n]))return!1;return!0}function Je(e,t){for(let n=t,r=e.length-1;n<r;n++)e[n]=e[n+1];e.pop()}function et(e,t,n){for(let r=e.length-1;r>=t;r--)e[r+1]=e[r];e[t]=n}function tt(e,t){let n=-1,r=1e9;for(let i=0;i<t.length;i++)(t[i]-r||e[i].endSide-e[n].endSide)<0&&(n=i,r=t[i]);return n}function nt(e,t,n=e.length){let r=0;for(let i=0;i<n&&i<e.length;)9==e.charCodeAt(i)?(r+=t-r%t,i++):(r++,i=k(e,i));return r}function rt(e,t,n,r){for(let i=0,o=0;;){if(o>=t)return i;if(i==e.length)break;o+=9==e.charCodeAt(i)?n-o%n:1,i=k(e,i)}return!0===r?-1:e.length}},79066:function(e,t,n){"use strict";n.r(t),n.d(t,{DefaultBufferLength:function(){return r},IterMode:function(){return p},MountedTree:function(){return s},NodeProp:function(){return a},NodeSet:function(){return u},NodeType:function(){return c},NodeWeakMap:function(){return M},Parser:function(){return L},Tree:function(){return f},TreeBuffer:function(){return g},TreeCursor:function(){return A},TreeFragment:function(){return D},parseMixed:function(){return $}});const r=1024;let i=0;class o{constructor(e,t){this.from=e,this.to=t}}class a{constructor(e={}){this.id=i++,this.perNode=!!e.perNode,this.deserialize=e.deserialize||(()=>{throw new Error("This node type doesn't define a deserialize function")}),this.combine=e.combine||null}add(e){if(this.perNode)throw new RangeError("Can't add per-node props to node types");return"function"!=typeof e&&(e=c.match(e)),t=>{let n=e(t);return void 0===n?null:[this,n]}}}a.closedBy=new a({deserialize:e=>e.split(" ")}),a.openedBy=new a({deserialize:e=>e.split(" ")}),a.group=new a({deserialize:e=>e.split(" ")}),a.isolate=new a({deserialize:e=>{if(e&&"rtl"!=e&&"ltr"!=e&&"auto"!=e)throw new RangeError("Invalid value for isolate: "+e);return e||"auto"}}),a.contextHash=new a({perNode:!0}),a.lookAhead=new a({perNode:!0}),a.mounted=new a({perNode:!0});class s{constructor(e,t,n,r=!1){this.tree=e,this.overlay=t,this.parser=n,this.bracketed=r}static get(e){return e&&e.props&&e.props[a.mounted.id]}}const l=Object.create(null);class c{constructor(e,t,n,r=0){this.name=e,this.props=t,this.id=n,this.flags=r}static define(e){let t=e.props&&e.props.length?Object.create(null):l,n=(e.top?1:0)|(e.skipped?2:0)|(e.error?4:0)|(null==e.name?8:0),r=new c(e.name||"",t,e.id,n);if(e.props)for(let i of e.props)if(Array.isArray(i)||(i=i(r)),i){if(i[0].perNode)throw new RangeError("Can't store a per-node prop on a node type");t[i[0].id]=i[1]}return r}prop(e){return this.props[e.id]}get isTop(){return(1&this.flags)>0}get isSkipped(){return(2&this.flags)>0}get isError(){return(4&this.flags)>0}get isAnonymous(){return(8&this.flags)>0}is(e){if("string"==typeof e){if(this.name==e)return!0;let t=this.prop(a.group);return!!t&&t.indexOf(e)>-1}return this.id==e}static match(e){let t=Object.create(null);for(let n in e)for(let r of n.split(" "))t[r]=e[n];return e=>{for(let n=e.prop(a.group),r=-1;r<(n?n.length:0);r++){let i=t[r<0?e.name:n[r]];if(i)return i}}}}c.none=new c("",Object.create(null),0,8);class u{constructor(e){this.types=e;for(let t=0;t<e.length;t++)if(e[t].id!=t)throw new RangeError("Node type ids should correspond to array positions when creating a node set")}extend(...e){let t=[];for(let n of this.types){let r=null;for(let t of e){let e=t(n);if(e){r||(r=Object.assign({},n.props));let t=e[1],i=e[0];i.combine&&i.id in r&&(t=i.combine(r[i.id],t)),r[i.id]=t}}t.push(r?new c(n.name,r,n.id,n.flags):n)}return new u(t)}}const d=new WeakMap,h=new WeakMap;var p;(function(e){e[e["ExcludeBuffers"]=1]="ExcludeBuffers",e[e["IncludeAnonymous"]=2]="IncludeAnonymous",e[e["IgnoreMounts"]=4]="IgnoreMounts",e[e["IgnoreOverlays"]=8]="IgnoreOverlays",e[e["EnterBracketed"]=16]="EnterBracketed"})(p||(p={}));class f{constructor(e,t,n,r,i){if(this.type=e,this.children=t,this.positions=n,this.length=r,this.props=null,i&&i.length){this.props=Object.create(null);for(let[e,t]of i)this.props["number"==typeof e?e:e.id]=t}}toString(){let e=s.get(this);if(e&&!e.overlay)return e.tree.toString();let t="";for(let n of this.children){let e=n.toString();e&&(t&&(t+=","),t+=e)}return this.type.name?(/\W/.test(this.type.name)&&!this.type.isError?JSON.stringify(this.type.name):this.type.name)+(t.length?"("+t+")":""):t}cursor(e=0){return new A(this.topNode,e)}cursorAt(e,t=0,n=0){let r=d.get(this)||this.topNode,i=new A(r);return i.moveTo(e,t),d.set(this,i._tree),i}get topNode(){return new w(this,0,0,null)}resolve(e,t=0){let n=b(d.get(this)||this.topNode,e,t,!1);return d.set(this,n),n}resolveInner(e,t=0){let n=b(h.get(this)||this.topNode,e,t,!0);return h.set(this,n),n}resolveStack(e,t=0){return C(this,e,t)}iterate(e){let{enter:t,leave:n,from:r=0,to:i=this.length}=e,o=e.mode||0,a=(o&p.IncludeAnonymous)>0;for(let s=this.cursor(o|p.IncludeAnonymous);;){let e=!1;if(s.from<=i&&s.to>=r&&(!a&&s.type.isAnonymous||!1!==t(s))){if(s.firstChild())continue;e=!0}for(;;){if(e&&n&&(a||!s.type.isAnonymous)&&n(s),s.nextSibling())break;if(!s.parent())return;e=!0}}}prop(e){return e.perNode?this.props?this.props[e.id]:void 0:this.type.prop(e)}get propValues(){let e=[];if(this.props)for(let t in this.props)e.push([+t,this.props[t]]);return e}balance(e={}){return this.children.length<=8?this:I(c.none,this.children,this.positions,0,this.children.length,0,this.length,(e,t,n)=>new f(this.type,e,t,n,this.propValues),e.makeTree||((e,t,n)=>new f(c.none,e,t,n)))}static build(e){return R(e)}}f.empty=new f(c.none,[],[],0);class m{constructor(e,t){this.buffer=e,this.index=t}get id(){return this.buffer[this.index-4]}get start(){return this.buffer[this.index-3]}get end(){return this.buffer[this.index-2]}get size(){return this.buffer[this.index-1]}get pos(){return this.index}next(){this.index-=4}fork(){return new m(this.buffer,this.index)}}class g{constructor(e,t,n){this.buffer=e,this.length=t,this.set=n}get type(){return c.none}toString(){let e=[];for(let t=0;t<this.buffer.length;)e.push(this.childString(t)),t=this.buffer[t+3];return e.join(",")}childString(e){let t=this.buffer[e],n=this.buffer[e+3],r=this.set.types[t],i=r.name;if(/\W/.test(i)&&!r.isError&&(i=JSON.stringify(i)),e+=4,n==e)return i;let o=[];while(e<n)o.push(this.childString(e)),e=this.buffer[e+3];return i+"("+o.join(",")+")"}findChild(e,t,n,r,i){let{buffer:o}=this,a=-1;for(let s=e;s!=t;s=o[s+3])if(v(i,r,o[s+1],o[s+2])&&(a=s,n>0))break;return a}slice(e,t,n){let r=this.buffer,i=new Uint16Array(t-e),o=0;for(let a=e,s=0;a<t;){i[s++]=r[a++],i[s++]=r[a++]-n;let t=i[s++]=r[a++]-n;i[s++]=r[a++]-e,o=Math.max(o,t)}return new g(i,o,this.set)}}function v(e,t,n,r){switch(e){case-2:return n<t;case-1:return r>=t&&n<t;case 0:return n<t&&r>t;case 1:return n<=t&&r>t;case 2:return r>t;case 4:return!0}}function b(e,t,n,r){var i;while(e.from==e.to||(n<1?e.from>=t:e.from>t)||(n>-1?e.to<=t:e.to<t)){let t=!r&&e instanceof w&&e.index<0?null:e.parent;if(!t)return e;e=t}let o=r?0:p.IgnoreOverlays;if(r)for(let a=e,s=a.parent;s;a=s,s=a.parent)a instanceof w&&a.index<0&&(null===(i=s.enter(t,n,o))||void 0===i?void 0:i.from)!=a.from&&(e=s);for(;;){let r=e.enter(t,n,o);if(!r)return e;e=r}}class y{cursor(e=0){return new A(this,e)}getChild(e,t=null,n=null){let r=O(this,e,t,n);return r.length?r[0]:null}getChildren(e,t=null,n=null){return O(this,e,t,n)}resolve(e,t=0){return b(this,e,t,!1)}resolveInner(e,t=0){return b(this,e,t,!0)}matchContext(e){return S(this.parent,e)}enterUnfinishedNodesBefore(e){let t=this.childBefore(e),n=this;while(t){let e=t.lastChild;if(!e||e.to!=t.to)break;e.type.isError&&e.from==e.to?(n=t,t=e.prevSibling):t=e}return n}get node(){return this}get next(){return this.parent}}class w extends y{constructor(e,t,n,r){super(),this._tree=e,this.from=t,this.index=n,this._parent=r}get type(){return this._tree.type}get name(){return this._tree.type.name}get to(){return this.from+this._tree.length}nextChild(e,t,n,r,i=0){for(let o=this;;){for(let{children:a,positions:l}=o._tree,c=t>0?a.length:-1;e!=c;e+=t){let c,u=a[e],d=l[e]+o.from;if(i&p.EnterBracketed&&u instanceof f&&(c=s.get(u))&&!c.overlay&&c.bracketed&&n>=d&&n<=d+u.length||v(r,n,d,d+u.length))if(u instanceof g){if(i&p.ExcludeBuffers)continue;let a=u.findChild(0,u.buffer.length,t,n-d,r);if(a>-1)return new x(new E(o,u,e,d),null,a)}else if(i&p.IncludeAnonymous||!u.type.isAnonymous||T(u)){let a;if(!(i&p.IgnoreMounts)&&(a=s.get(u))&&!a.overlay)return new w(a.tree,d,e,o);let l=new w(u,d,e,o);return i&p.IncludeAnonymous||!l.type.isAnonymous?l:l.nextChild(t<0?u.children.length-1:0,t,n,r,i)}}if(i&p.IncludeAnonymous||!o.type.isAnonymous)return null;if(e=o.index>=0?o.index+t:t<0?-1:o._parent._tree.children.length,o=o._parent,!o)return null}}get firstChild(){return this.nextChild(0,1,0,4)}get lastChild(){return this.nextChild(this._tree.children.length-1,-1,0,4)}childAfter(e){return this.nextChild(0,1,e,2)}childBefore(e){return this.nextChild(this._tree.children.length-1,-1,e,-2)}prop(e){return this._tree.prop(e)}enter(e,t,n=0){let r;if(!(n&p.IgnoreOverlays)&&(r=s.get(this._tree))&&r.overlay){let i=e-this.from,o=n&p.EnterBracketed&&r.bracketed;for(let{from:e,to:n}of r.overlay)if((t>0||o?e<=i:e<i)&&(t<0||o?n>=i:n>i))return new w(r.tree,r.overlay[0].from+this.from,-1,this)}return this.nextChild(0,1,e,t,n)}nextSignificantParent(){let e=this;while(e.type.isAnonymous&&e._parent)e=e._parent;return e}get parent(){return this._parent?this._parent.nextSignificantParent():null}get nextSibling(){return this._parent&&this.index>=0?this._parent.nextChild(this.index+1,1,0,4):null}get prevSibling(){return this._parent&&this.index>=0?this._parent.nextChild(this.index-1,-1,0,4):null}get tree(){return this._tree}toTree(){return this._tree}toString(){return this._tree.toString()}}function O(e,t,n,r){let i=e.cursor(),o=[];if(!i.firstChild())return o;if(null!=n)for(let a=!1;!a;)if(a=i.type.is(n),!i.nextSibling())return o;for(;;){if(null!=r&&i.type.is(r))return o;if(i.type.is(t)&&o.push(i.node),!i.nextSibling())return null==r?o:[]}}function S(e,t,n=t.length-1){for(let r=e;n>=0;r=r.parent){if(!r)return!1;if(!r.type.isAnonymous){if(t[n]&&t[n]!=r.name)return!1;n--}}return!0}class E{constructor(e,t,n,r){this.parent=e,this.buffer=t,this.index=n,this.start=r}}class x extends y{get name(){return this.type.name}get from(){return this.context.start+this.context.buffer.buffer[this.index+1]}get to(){return this.context.start+this.context.buffer.buffer[this.index+2]}constructor(e,t,n){super(),this.context=e,this._parent=t,this.index=n,this.type=e.buffer.set.types[e.buffer.buffer[n]]}child(e,t,n){let{buffer:r}=this.context,i=r.findChild(this.index+4,r.buffer[this.index+3],e,t-this.context.start,n);return i<0?null:new x(this.context,this,i)}get firstChild(){return this.child(1,0,4)}get lastChild(){return this.child(-1,0,4)}childAfter(e){return this.child(1,e,2)}childBefore(e){return this.child(-1,e,-2)}prop(e){return this.type.prop(e)}enter(e,t,n=0){if(n&p.ExcludeBuffers)return null;let{buffer:r}=this.context,i=r.findChild(this.index+4,r.buffer[this.index+3],t>0?1:-1,e-this.context.start,t);return i<0?null:new x(this.context,this,i)}get parent(){return this._parent||this.context.parent.nextSignificantParent()}externalSibling(e){return this._parent?null:this.context.parent.nextChild(this.context.index+e,e,0,4)}get nextSibling(){let{buffer:e}=this.context,t=e.buffer[this.index+3];return t<(this._parent?e.buffer[this._parent.index+3]:e.buffer.length)?new x(this.context,this._parent,t):this.externalSibling(1)}get prevSibling(){let{buffer:e}=this.context,t=this._parent?this._parent.index+4:0;return this.index==t?this.externalSibling(-1):new x(this.context,this._parent,e.findChild(t,this.index,-1,0,4))}get tree(){return null}toTree(){let e=[],t=[],{buffer:n}=this.context,r=this.index+4,i=n.buffer[this.index+3];if(i>r){let o=n.buffer[this.index+1];e.push(n.slice(r,i,o)),t.push(0)}return new f(this.type,e,t,this.to-this.from)}toString(){return this.context.buffer.childString(this.index)}}function _(e){if(!e.length)return null;let t=0,n=e[0];for(let o=1;o<e.length;o++){let r=e[o];(r.from>n.from||r.to<n.to)&&(n=r,t=o)}let r=n instanceof w&&n.index<0?null:n.parent,i=e.slice();return r?i[t]=r:i.splice(t,1),new k(i,n)}class k{constructor(e,t){this.heads=e,this.node=t}get next(){return _(this.heads)}}function C(e,t,n){let r=e.resolveInner(t,n),i=null;for(let o=r instanceof w?r:r.context.parent;o;o=o.parent)if(o.index<0){let e=o.parent;(i||(i=[r])).push(e.resolve(t,n)),o=e}else{let e=s.get(o.tree);if(e&&e.overlay&&e.overlay[0].from<=t&&e.overlay[e.overlay.length-1].to>=t){let a=new w(e.tree,e.overlay[0].from+o.from,-1,o);(i||(i=[r])).push(b(a,t,n,!1))}}return i?_(i):r}class A{get name(){return this.type.name}constructor(e,t=0){if(this.buffer=null,this.stack=[],this.index=0,this.bufferNode=null,this.mode=t&~p.EnterBracketed,e instanceof w)this.yieldNode(e);else{this._tree=e.context.parent,this.buffer=e.context;for(let t=e._parent;t;t=t._parent)this.stack.unshift(t.index);this.bufferNode=e,this.yieldBuf(e.index)}}yieldNode(e){return!!e&&(this._tree=e,this.type=e.type,this.from=e.from,this.to=e.to,!0)}yieldBuf(e,t){this.index=e;let{start:n,buffer:r}=this.buffer;return this.type=t||r.set.types[r.buffer[e]],this.from=n+r.buffer[e+1],this.to=n+r.buffer[e+2],!0}yield(e){return!!e&&(e instanceof w?(this.buffer=null,this.yieldNode(e)):(this.buffer=e.context,this.yieldBuf(e.index,e.type)))}toString(){return this.buffer?this.buffer.buffer.childString(this.index):this._tree.toString()}enterChild(e,t,n){if(!this.buffer)return this.yield(this._tree.nextChild(e<0?this._tree._tree.children.length-1:0,e,t,n,this.mode));let{buffer:r}=this.buffer,i=r.findChild(this.index+4,r.buffer[this.index+3],e,t-this.buffer.start,n);return!(i<0)&&(this.stack.push(this.index),this.yieldBuf(i))}firstChild(){return this.enterChild(1,0,4)}lastChild(){return this.enterChild(-1,0,4)}childAfter(e){return this.enterChild(1,e,2)}childBefore(e){return this.enterChild(-1,e,-2)}enter(e,t,n=this.mode){return this.buffer?!(n&p.ExcludeBuffers)&&this.enterChild(1,e,t):this.yield(this._tree.enter(e,t,n))}parent(){if(!this.buffer)return this.yieldNode(this.mode&p.IncludeAnonymous?this._tree._parent:this._tree.parent);if(this.stack.length)return this.yieldBuf(this.stack.pop());let e=this.mode&p.IncludeAnonymous?this.buffer.parent:this.buffer.parent.nextSignificantParent();return this.buffer=null,this.yieldNode(e)}sibling(e){if(!this.buffer)return!!this._tree._parent&&this.yield(this._tree.index<0?null:this._tree._parent.nextChild(this._tree.index+e,e,0,4,this.mode));let{buffer:t}=this.buffer,n=this.stack.length-1;if(e<0){let e=n<0?0:this.stack[n]+4;if(this.index!=e)return this.yieldBuf(t.findChild(e,this.index,-1,0,4))}else{let e=t.buffer[this.index+3];if(e<(n<0?t.buffer.length:t.buffer[this.stack[n]+3]))return this.yieldBuf(e)}return n<0&&this.yield(this.buffer.parent.nextChild(this.buffer.index+e,e,0,4,this.mode))}nextSibling(){return this.sibling(1)}prevSibling(){return this.sibling(-1)}atLastNode(e){let t,n,{buffer:r}=this;if(r){if(e>0){if(this.index<r.buffer.buffer.length)return!1}else for(let e=0;e<this.index;e++)if(r.buffer.buffer[e+3]<this.index)return!1;({index:t,parent:n}=r)}else({index:t,_parent:n}=this._tree);for(;n;({index:t,_parent:n}=n))if(t>-1)for(let r=t+e,i=e<0?-1:n._tree.children.length;r!=i;r+=e){let e=n._tree.children[r];if(this.mode&p.IncludeAnonymous||e instanceof g||!e.type.isAnonymous||T(e))return!1}return!0}move(e,t){if(t&&this.enterChild(e,0,4))return!0;for(;;){if(this.sibling(e))return!0;if(this.atLastNode(e)||!this.parent())return!1}}next(e=!0){return this.move(1,e)}prev(e=!0){return this.move(-1,e)}moveTo(e,t=0){while(this.from==this.to||(t<1?this.from>=e:this.from>e)||(t>-1?this.to<=e:this.to<e))if(!this.parent())break;while(this.enterChild(1,e,t));return this}get node(){if(!this.buffer)return this._tree;let e=this.bufferNode,t=null,n=0;if(e&&e.context==this.buffer)e:for(let r=this.index,i=this.stack.length;i>=0;){for(let o=e;o;o=o._parent)if(o.index==r){if(r==this.index)return o;t=o,n=i+1;break e}r=this.stack[--i]}for(let r=n;r<this.stack.length;r++)t=new x(this.buffer,t,this.stack[r]);return this.bufferNode=new x(this.buffer,t,this.index)}get tree(){return this.buffer?null:this._tree._tree}iterate(e,t){for(let n=0;;){let r=!1;if(this.type.isAnonymous||!1!==e(this)){if(this.firstChild()){n++;continue}this.type.isAnonymous||(r=!0)}for(;;){if(r&&t&&t(this),r=this.type.isAnonymous,!n)return;if(this.nextSibling())break;this.parent(),n--,r=!0}}}matchContext(e){if(!this.buffer)return S(this.node.parent,e);let{buffer:t}=this.buffer,{types:n}=t.set;for(let r=e.length-1,i=this.stack.length-1;r>=0;i--){if(i<0)return S(this._tree,e,r);let o=n[t.buffer[this.stack[i]]];if(!o.isAnonymous){if(e[r]&&e[r]!=o.name)return!1;r--}}return!0}}function T(e){return e.children.some(e=>e instanceof g||!e.type.isAnonymous||T(e))}function R(e){var t;let{buffer:n,nodeSet:i,maxBufferLength:o=r,reused:s=[],minRepeatType:l=i.types.length}=e,c=Array.isArray(n)?new m(n,n.length):n,u=i.types,d=0,h=0;function p(e,t,n,r,a,f){let{id:m,start:E,end:x,size:_}=c,k=h,C=d;if(_<0){if(c.next(),-1==_){let t=s[m];return n.push(t),void r.push(E-e)}if(-3==_)return void(d=m);if(-4==_)return void(h=m);throw new RangeError(`Unrecognized record size: ${_}`)}let A,T,R=u[m],N=E-e;if(x-E<=o&&(T=O(c.pos-t,a))){let t=new Uint16Array(T.size-T.skip),n=c.pos-T.size,r=t.length;while(c.pos>n)r=S(T.start,t,r);A=new g(t,x-T.start,i),N=T.start-e}else{let e=c.pos-_;c.next();let t=[],n=[],r=m>=l?m:-1,i=0,a=x;while(c.pos>e)r>=0&&c.id==r&&c.size>=0?(c.end<=a-o&&(y(t,n,E,i,c.end,a,r,k,C),i=t.length,a=c.end),c.next()):f>2500?v(E,e,t,n):p(E,e,t,n,r,f+1);if(r>=0&&i>0&&i<t.length&&y(t,n,E,i,E,a,r,k,C),t.reverse(),n.reverse(),r>-1&&i>0){let e=b(R,C);A=I(R,t,n,0,t.length,0,x-E,e,e)}else A=w(R,t,n,x-E,k-x,C)}n.push(A),r.push(N)}function v(e,t,n,r){let a=[],s=0,l=-1;while(c.pos>t){let{id:e,start:t,end:n,size:r}=c;if(r>4)c.next();else{if(l>-1&&t<l)break;l<0&&(l=n-o),a.push(e,t,n),s++,c.next()}}if(s){let t=new Uint16Array(4*s),o=a[a.length-2];for(let e=a.length-3,n=0;e>=0;e-=3)t[n++]=a[e],t[n++]=a[e+1]-o,t[n++]=a[e+2]-o,t[n++]=n;n.push(new g(t,a[2]-o,i)),r.push(o-e)}}function b(e,t){return(n,r,i)=>{let o,s,l=0,c=n.length-1;if(c>=0&&(o=n[c])instanceof f){if(!c&&o.type==e&&o.length==i)return o;(s=o.prop(a.lookAhead))&&(l=r[c]+o.length+s)}return w(e,n,r,i,l,t)}}function y(e,t,n,r,o,a,s,l,c){let u=[],d=[];while(e.length>r)u.push(e.pop()),d.push(t.pop()+n-o);e.push(w(i.types[s],u,d,a-o,l-a,c)),t.push(o-n)}function w(e,t,n,r,i,o,s){if(o){let e=[a.contextHash,o];s=s?[e].concat(s):[e]}if(i>25){let e=[a.lookAhead,i];s=s?[e].concat(s):[e]}return new f(e,t,n,r,s)}function O(e,t){let n=c.fork(),r=0,i=0,a=0,s=n.end-o,u={size:0,start:0,skip:0};e:for(let o=n.pos-e;n.pos>o;){let e=n.size;if(n.id==t&&e>=0){u.size=r,u.start=i,u.skip=a,a+=4,r+=4,n.next();continue}let c=n.pos-e;if(e<0||c<o||n.start<s)break;let d=n.id>=l?4:0,h=n.start;n.next();while(n.pos>c){if(n.size<0){if(-3!=n.size&&-4!=n.size)break e;d+=4}else n.id>=l&&(d+=4);n.next()}i=h,r+=e,a+=d}return(t<0||r==e)&&(u.size=r,u.start=i,u.skip=a),u.size>4?u:void 0}function S(e,t,n){let{id:r,start:i,end:o,size:a}=c;if(c.next(),a>=0&&r<l){let s=n;if(a>4){let r=c.pos-(a-4);while(c.pos>r)n=S(e,t,n)}t[--n]=s,t[--n]=o-e,t[--n]=i-e,t[--n]=r}else-3==a?d=r:-4==a&&(h=r);return n}let E=[],x=[];while(c.pos>0)p(e.start||0,e.bufferStart||0,E,x,-1,0);let _=null!==(t=e.length)&&void 0!==t?t:E.length?x[0]+E[0].length:0;return new f(u[e.topID],E.reverse(),x.reverse(),_)}const N=new WeakMap;function P(e,t){if(!e.isAnonymous||t instanceof g||t.type!=e)return 1;let n=N.get(t);if(null==n){n=1;for(let r of t.children){if(r.type!=e||!(r instanceof f)){n=1;break}n+=P(e,r)}N.set(t,n)}return n}function I(e,t,n,r,i,o,a,s,l){let c=0;for(let f=r;f<i;f++)c+=P(e,t[f]);let u=Math.ceil(1.5*c/8),d=[],h=[];function p(t,n,r,i,a){for(let s=r;s<i;){let r=s,c=n[s],f=P(e,t[s]);for(s++;s<i;s++){let n=P(e,t[s]);if(f+n>=u)break;f+=n}if(s==r+1){if(f>u){let e=t[r];p(e.children,e.positions,0,e.children.length,n[r]+a);continue}d.push(t[r])}else{let i=n[s-1]+t[s-1].length-c;d.push(I(e,t,n,r,s,c,i,null,l))}h.push(c+a-o)}}return p(t,n,r,i,0),(s||l)(d,h,a)}class M{constructor(){this.map=new WeakMap}setBuffer(e,t,n){let r=this.map.get(e);r||this.map.set(e,r=new Map),r.set(t,n)}getBuffer(e,t){let n=this.map.get(e);return n&&n.get(t)}set(e,t){e instanceof x?this.setBuffer(e.context.buffer,e.index,t):e instanceof w&&this.map.set(e.tree,t)}get(e){return e instanceof x?this.getBuffer(e.context.buffer,e.index):e instanceof w?this.map.get(e.tree):void 0}cursorSet(e,t){e.buffer?this.setBuffer(e.buffer.buffer,e.index,t):this.map.set(e.tree,t)}cursorGet(e){return e.buffer?this.getBuffer(e.buffer.buffer,e.index):this.map.get(e.tree)}}class D{constructor(e,t,n,r,i=!1,o=!1){this.from=e,this.to=t,this.tree=n,this.offset=r,this.open=(i?1:0)|(o?2:0)}get openStart(){return(1&this.open)>0}get openEnd(){return(2&this.open)>0}static addTree(e,t=[],n=!1){let r=[new D(0,e.length,e,0,!1,n)];for(let i of t)i.to>e.length&&r.push(i);return r}static applyChanges(e,t,n=128){if(!t.length)return e;let r=[],i=1,o=e.length?e[0]:null;for(let a=0,s=0,l=0;;a++){let c=a<t.length?t[a]:null,u=c?c.fromA:1e9;if(u-s>=n)while(o&&o.from<u){let t=o;if(s>=t.from||u<=t.to||l){let e=Math.max(t.from,s)-l,n=Math.min(t.to,u)-l;t=e>=n?null:new D(e,n,t.tree,t.offset+l,a>0,!!c)}if(t&&r.push(t),o.to>u)break;o=i<e.length?e[i++]:null}if(!c)break;s=c.toA,l=c.toA-c.toB}return r}}class L{startParse(e,t,n){return"string"==typeof e&&(e=new B(e)),n=n?n.length?n.map(e=>new o(e.from,e.to)):[new o(0,0)]:[new o(0,e.length)],this.createParse(e,t||[],n)}parse(e,t,n){let r=this.startParse(e,t,n);for(;;){let e=r.advance();if(e)return e}}}class B{constructor(e){this.string=e}get length(){return this.string.length}chunk(e){return this.string.slice(e)}get lineChunks(){return!1}read(e,t){return this.string.slice(e,t)}}function $(e){return(t,n,r,i)=>new G(t,e,n,r,i)}class V{constructor(e,t,n,r,i,o){this.parser=e,this.parse=t,this.overlay=n,this.bracketed=r,this.target=i,this.from=o}}function F(e){if(!e.length||e.some(e=>e.from>=e.to))throw new RangeError("Invalid inner parse ranges given: "+JSON.stringify(e))}class j{constructor(e,t,n,r,i,o,a,s){this.parser=e,this.predicate=t,this.mounts=n,this.index=r,this.start=i,this.bracketed=o,this.target=a,this.prev=s,this.depth=0,this.ranges=[]}}const U=new a({perNode:!0});class G{constructor(e,t,n,r,i){this.nest=t,this.input=n,this.fragments=r,this.ranges=i,this.inner=[],this.innerDone=0,this.baseTree=null,this.stoppedAt=null,this.baseParse=e}advance(){if(this.baseParse){let e=this.baseParse.advance();if(!e)return null;if(this.baseParse=null,this.baseTree=e,this.startInner(),null!=this.stoppedAt)for(let t of this.inner)t.parse.stopAt(this.stoppedAt)}if(this.innerDone==this.inner.length){let e=this.baseTree;return null!=this.stoppedAt&&(e=new f(e.type,e.children,e.positions,e.length,e.propValues.concat([[U,this.stoppedAt]]))),e}let e=this.inner[this.innerDone],t=e.parse.advance();if(t){this.innerDone++;let n=Object.assign(Object.create(null),e.target.props);n[a.mounted.id]=new s(t,e.overlay,e.parser,e.bracketed),e.target.props=n}return null}get parsedPos(){if(this.baseParse)return 0;let e=this.input.length;for(let t=this.innerDone;t<this.inner.length;t++)this.inner[t].from<e&&(e=Math.min(e,this.inner[t].parse.parsedPos));return e}stopAt(e){if(this.stoppedAt=e,this.baseParse)this.baseParse.stopAt(e);else for(let t=this.innerDone;t<this.inner.length;t++)this.inner[t].parse.stopAt(e)}startInner(){let e=new K(this.fragments),t=null,n=null,r=new A(new w(this.baseTree,this.ranges[0].from,0,null),p.IncludeAnonymous|p.IgnoreMounts);e:for(let i,a;;){let s,l=!0;if(null!=this.stoppedAt&&r.from>=this.stoppedAt)l=!1;else if(e.hasNode(r)){if(t){let e=t.mounts.find(e=>e.frag.from<=r.from&&e.frag.to>=r.to&&e.mount.overlay);if(e)for(let n of e.mount.overlay){let i=n.from+e.pos,o=n.to+e.pos;i>=r.from&&o<=r.to&&!t.ranges.some(e=>e.from<o&&e.to>i)&&t.ranges.push({from:i,to:o})}}l=!1}else if(n&&(a=H(n.ranges,r.from,r.to)))l=2!=a;else if(!r.type.isAnonymous&&(i=this.nest(r,this.input))&&(r.from<r.to||!i.overlay)){r.tree||(Q(r),t&&t.depth++,n&&n.depth++);let a=e.findMounts(r.from,i.parser);if("function"==typeof i.overlay)t=new j(i.parser,i.overlay,a,this.inner.length,r.from,!!i.bracketed,r.tree,t);else{let e=W(this.ranges,i.overlay||(r.from<r.to?[new o(r.from,r.to)]:[]));e.length&&F(e),!e.length&&i.overlay||this.inner.push(new V(i.parser,e.length?i.parser.startParse(this.input,Y(a,e),e):i.parser.startParse(""),i.overlay?i.overlay.map(e=>new o(e.from-r.from,e.to-r.from)):null,!!i.bracketed,r.tree,e.length?e[0].from:r.from)),i.overlay?e.length&&(n={ranges:e,depth:0,prev:n}):l=!1}}else if(t&&(s=t.predicate(r))&&(!0===s&&(s=new o(r.from,r.to)),s.from<s.to)){let e=t.ranges.length-1;e>=0&&t.ranges[e].to==s.from?t.ranges[e]={from:t.ranges[e].from,to:s.to}:t.ranges.push(s)}if(l&&r.firstChild())t&&t.depth++,n&&n.depth++;else for(;;){if(r.nextSibling())break;if(!r.parent())break e;if(t&&! --t.depth){let e=W(this.ranges,t.ranges);e.length&&(F(e),this.inner.splice(t.index,0,new V(t.parser,t.parser.startParse(this.input,Y(t.mounts,e),e),t.ranges.map(e=>new o(e.from-t.start,e.to-t.start)),t.bracketed,t.target,e[0].from))),t=t.prev}n&&! --n.depth&&(n=n.prev)}}}}function H(e,t,n){for(let r of e){if(r.from>=n)break;if(r.to>t)return r.from<=t&&r.to>=n?2:1}return 0}function q(e,t,n,r,i,o){if(t<n){let a=e.buffer[t+1];r.push(e.slice(t,n,a)),i.push(a-o)}}function Q(e){let{node:t}=e,n=[],r=t.context.buffer;do{n.push(e.index),e.parent()}while(!e.tree);let i=e.tree,o=i.children.indexOf(r),a=i.children[o],s=a.buffer,l=[o];function u(e,r,i,o,c,d){let h=n[d],p=[],m=[];q(a,e,h,p,m,o);let g=s[h+1],v=s[h+2];l.push(p.length);let b=d?u(h+4,s[h+3],a.set.types[s[h]],g,v-g,d-1):t.toTree();return p.push(b),m.push(g-o),q(a,s[h+3],r,p,m,o),new f(i,p,m,c)}i.children[o]=u(0,s.length,c.none,0,a.length,n.length-1);for(let c of l){let t=e.tree.children[c],n=e.tree.positions[c];e.yield(new w(t,n+e.from,c,e._tree))}}class z{constructor(e,t){this.offset=t,this.done=!1,this.cursor=e.cursor(p.IncludeAnonymous|p.IgnoreMounts|p.ExcludeBuffers)}moveTo(e){let{cursor:t}=this,n=e-this.offset;while(!this.done&&t.from<n)if(t.to>=n&&t.enter(n,1,p.IncludeAnonymous|p.IgnoreOverlays|p.ExcludeBuffers));else{if(!(t.to<=n))break;t.next(!1)||(this.done=!0)}}hasNode(e){if(this.moveTo(e.from),!this.done&&this.cursor.from+this.offset==e.from&&this.cursor.tree)for(let t=this.cursor.tree;;){if(t==e.tree)return!0;if(!(t.children.length&&0==t.positions[0]&&t.children[0]instanceof f))break;t=t.children[0]}return!1}}class K{constructor(e){var t;if(this.fragments=e,this.curTo=0,this.fragI=0,e.length){let n=this.curFrag=e[0];this.curTo=null!==(t=n.tree.prop(U))&&void 0!==t?t:n.to,this.inner=new z(n.tree,-n.offset)}else this.curFrag=this.inner=null}hasNode(e){while(this.curFrag&&e.from>=this.curTo)this.nextFrag();return this.curFrag&&this.curFrag.from<=e.from&&this.curTo>=e.to&&this.inner.hasNode(e)}nextFrag(){var e;if(this.fragI++,this.fragI==this.fragments.length)this.curFrag=this.inner=null;else{let t=this.curFrag=this.fragments[this.fragI];this.curTo=null!==(e=t.tree.prop(U))&&void 0!==e?e:t.to,this.inner=new z(t.tree,-t.offset)}}findMounts(e,t){var n;let r=[];if(this.inner){this.inner.cursor.moveTo(e,1);for(let e=this.inner.cursor.node;e;e=e.parent){let i=null===(n=e.tree)||void 0===n?void 0:n.prop(a.mounted);if(i&&i.parser==t)for(let t=this.fragI;t<this.fragments.length;t++){let n=this.fragments[t];if(n.from>=e.to)break;n.tree==this.curFrag.tree&&r.push({frag:n,pos:e.from-n.offset,mount:i})}}}return r}}function W(e,t){let n=null,r=t;for(let i=1,a=0;i<e.length;i++){let s=e[i-1].to,l=e[i].from;for(;a<r.length;a++){let e=r[a];if(e.from>=l)break;e.to<=s||(n||(r=n=t.slice()),e.from<s?(n[a]=new o(e.from,s),e.to>l&&n.splice(a+1,0,new o(l,e.to))):e.to>l?n[a--]=new o(l,e.to):n.splice(a--,1))}}return r}function X(e,t,n,r){let i=0,a=0,s=!1,l=!1,c=-1e9,u=[];for(;;){let d=i==e.length?1e9:s?e[i].to:e[i].from,h=a==t.length?1e9:l?t[a].to:t[a].from;if(s!=l){let e=Math.max(c,n),t=Math.min(d,h,r);e<t&&u.push(new o(e,t))}if(c=Math.min(d,h),1e9==c)break;d==c&&(s?(s=!1,i++):s=!0),h==c&&(l?(l=!1,a++):l=!0)}return u}function Y(e,t){let n=[];for(let{pos:r,mount:i,frag:a}of e){let e=r+(i.overlay?i.overlay[0].from:0),s=e+i.tree.length,l=Math.max(a.from,e),c=Math.min(a.to,s);if(i.overlay){let s=i.overlay.map(e=>new o(e.from+r,e.to+r)),u=X(t,s,l,c);for(let t=0,r=l;;t++){let o=t==u.length,s=o?c:u[t].from;if(s>r&&n.push(new D(r,s,i.tree,-e,a.from>=r||a.openStart,a.to<=s||a.openEnd)),o)break;r=u[t].to}}else n.push(new D(l,c,i.tree,-e,a.from>=e||a.openStart,a.to<=s||a.openEnd))}return n}},73643:function(e,t,n){"use strict";n.d(t,{Aj:function(){return T},Lu:function(){return g},U1:function(){return R},uC:function(){return m}});var r=n(43114),i=n(39907),o=n(4364);class a{constructor(e,t,n,r,i,o,a,s,l,c=0,u){this.p=e,this.stack=t,this.state=n,this.reducePos=r,this.pos=i,this.score=o,this.buffer=a,this.bufferBase=s,this.curContext=l,this.lookAhead=c,this.parent=u}toString(){return`[${this.stack.filter((e,t)=>t%3==0).concat(this.state)}]@${this.pos}${this.score?"!"+this.score:""}`}static start(e,t,n=0){let r=e.parser.context;return new a(e,[],t,n,n,0,[],0,r?new s(r,r.start):null,0,null)}get context(){return this.curContext?this.curContext.context:null}pushState(e,t){this.stack.push(this.state,t,this.bufferBase+this.buffer.length),this.state=e}reduce(e){var t;let n=e>>19,r=65535&e,{parser:i}=this.p,o=this.reducePos<this.pos-25&&this.setLookAhead(this.pos),a=i.dynamicPrecedence(r);if(a&&(this.score+=a),0==n)return r<i.minRepeatTerm&&this.reducePos<this.pos&&(this.reducePos=this.pos),this.pushState(i.getGoto(this.state,r,!0),this.reducePos),r<i.minRepeatTerm&&this.storeNode(r,this.reducePos,this.reducePos,o?8:4,!0),void this.reduceContext(r,this.reducePos);let s=this.stack.length-3*(n-1)-(262144&e?6:0),l=s?this.stack[s-2]:this.p.ranges[0].from;r<i.minRepeatTerm&&l==this.reducePos&&this.reducePos<this.pos&&(this.reducePos=this.pos);let c=this.reducePos-l;c>=2e3&&!(null===(t=this.p.parser.nodeSet.types[r])||void 0===t?void 0:t.isAnonymous)&&(l==this.p.lastBigReductionStart?(this.p.bigReductionCount++,this.p.lastBigReductionSize=c):this.p.lastBigReductionSize<c&&(this.p.bigReductionCount=1,this.p.lastBigReductionStart=l,this.p.lastBigReductionSize=c));let u=s?this.stack[s-1]:0,d=this.bufferBase+this.buffer.length-u;if(r<i.minRepeatTerm||131072&e){let e=i.stateFlag(this.state,1)?this.pos:this.reducePos;this.storeNode(r,l,e,d+4,!0)}if(262144&e)this.state=this.stack[s];else{let e=this.stack[s-3];this.state=i.getGoto(e,r,!0)}while(this.stack.length>s)this.stack.pop();this.reduceContext(r,l)}storeNode(e,t,n,r=4,i=!1){if(0==e&&(!this.stack.length||this.stack[this.stack.length-1]<this.buffer.length+this.bufferBase)){let e=this.buffer.length;if(e>0&&0==this.buffer[e-4]&&this.buffer[e-1]>-1){if(t==n)return;if(this.buffer[e-2]>=t)return void(this.buffer[e-2]=n)}}if(i&&this.pos!=n){let i=this.buffer.length;if(i>0&&(0!=this.buffer[i-4]||this.buffer[i-1]<0)){let e=!1;for(let t=i;t>0&&this.buffer[t-2]>n;t-=4)if(this.buffer[t-1]>=0){e=!0;break}if(e)while(i>0&&this.buffer[i-2]>n)this.buffer[i]=this.buffer[i-4],this.buffer[i+1]=this.buffer[i-3],this.buffer[i+2]=this.buffer[i-2],this.buffer[i+3]=this.buffer[i-1],i-=4,r>4&&(r-=4)}this.buffer[i]=e,this.buffer[i+1]=t,this.buffer[i+2]=n,this.buffer[i+3]=r}else this.buffer.push(e,t,n,r)}shift(e,t,n,r){if(131072&e)this.pushState(65535&e,this.pos);else if(0==(262144&e)){let i=e,{parser:o}=this.p;this.pos=r;let a=o.stateFlag(i,1);!a&&(r>n||t<=o.maxNode)&&(this.reducePos=r),this.pushState(i,a?n:Math.min(n,this.reducePos)),this.shiftContext(t,n),t<=o.maxNode&&this.buffer.push(t,n,r,4)}else this.pos=r,this.shiftContext(t,n),t<=this.p.parser.maxNode&&this.buffer.push(t,n,r,4)}apply(e,t,n,r){65536&e?this.reduce(e):this.shift(e,t,n,r)}useNode(e,t,n){let r=this.p.reused.length-1;(r<0||this.p.reused[r]!=e)&&(this.p.reused.push(e),r++);let i=this.reducePos=this.pos=n+e.length;this.pushState(t,n),this.buffer.push(r,n,i,-1),this.curContext&&this.updateContext(this.curContext.tracker.reuse(this.curContext.context,e,this,this.p.stream.reset(this.pos-e.length)))}split(){let e=this,t=e.buffer.length;t&&0==e.buffer[t-4]&&(t-=4);while(t>0&&e.buffer[t-2]>e.reducePos)t-=4;let n=e.buffer.slice(t),r=e.bufferBase+t;while(e&&r==e.bufferBase)e=e.parent;return new a(this.p,this.stack.slice(),this.state,this.reducePos,this.pos,this.score,n,r,this.curContext,this.lookAhead,e)}recoverByDelete(e,t){let n=e<=this.p.parser.maxNode;n&&this.storeNode(e,this.pos,t,4),this.storeNode(0,this.pos,t,n?8:4),this.pos=this.reducePos=t,this.score-=190}canShift(e){for(let t=new l(this);;){let n=this.p.parser.stateSlot(t.state,4)||this.p.parser.hasAction(t.state,e);if(0==n)return!1;if(0==(65536&n))return!0;t.reduce(n)}}recoverByInsert(e){if(this.stack.length>=300)return[];let t=this.p.parser.nextStates(this.state);if(t.length>8||this.stack.length>=120){let n=[];for(let r,i=0;i<t.length;i+=2)(r=t[i+1])!=this.state&&this.p.parser.hasAction(r,e)&&n.push(t[i],r);if(this.stack.length<120)for(let e=0;n.length<8&&e<t.length;e+=2){let r=t[e+1];n.some((e,t)=>1&t&&e==r)||n.push(t[e],r)}t=n}let n=[];for(let r=0;r<t.length&&n.length<4;r+=2){let e=t[r+1];if(e==this.state)continue;let i=this.split();i.pushState(e,this.pos),i.storeNode(0,i.pos,i.pos,4,!0),i.shiftContext(t[r],this.pos),i.reducePos=this.pos,i.score-=200,n.push(i)}return n}forceReduce(){let{parser:e}=this.p,t=e.stateSlot(this.state,5);if(0==(65536&t))return!1;if(!e.validAction(this.state,t)){let n=t>>19,r=65535&t,i=this.stack.length-3*n;if(i<0||e.getGoto(this.stack[i],r,!1)<0){let e=this.findForcedReduction();if(null==e)return!1;t=e}this.storeNode(0,this.pos,this.pos,4,!0),this.score-=100}return this.reducePos=this.pos,this.reduce(t),!0}findForcedReduction(){let{parser:e}=this.p,t=[],n=(r,i)=>{if(!t.includes(r))return t.push(r),e.allActions(r,t=>{if(393216&t);else if(65536&t){let n=(t>>19)-i;if(n>1){let r=65535&t,i=this.stack.length-3*n;if(i>=0&&e.getGoto(this.stack[i],r,!1)>=0)return n<<19|65536|r}}else{let e=n(t,i+1);if(null!=e)return e}})};return n(this.state,0)}forceAll(){while(!this.p.parser.stateFlag(this.state,2))if(!this.forceReduce()){this.storeNode(0,this.pos,this.pos,4,!0);break}return this}get deadEnd(){if(3!=this.stack.length)return!1;let{parser:e}=this.p;return 65535==e.data[e.stateSlot(this.state,1)]&&!e.stateSlot(this.state,4)}restart(){this.storeNode(0,this.pos,this.pos,4,!0),this.state=this.stack[0],this.stack.length=0}sameState(e){if(this.state!=e.state||this.stack.length!=e.stack.length)return!1;for(let t=0;t<this.stack.length;t+=3)if(this.stack[t]!=e.stack[t])return!1;return!0}get parser(){return this.p.parser}dialectEnabled(e){return this.p.parser.dialect.flags[e]}shiftContext(e,t){this.curContext&&this.updateContext(this.curContext.tracker.shift(this.curContext.context,e,this,this.p.stream.reset(t)))}reduceContext(e,t){this.curContext&&this.updateContext(this.curContext.tracker.reduce(this.curContext.context,e,this,this.p.stream.reset(t)))}emitContext(){let e=this.buffer.length-1;(e<0||-3!=this.buffer[e])&&this.storeNode(this.curContext.hash,this.reducePos,this.reducePos,-3,!0)}emitLookAhead(){let e=this.buffer.length-1;(e<0||-4!=this.buffer[e])&&this.buffer.push(this.lookAhead,this.pos,this.pos,-4)}updateContext(e){if(e!=this.curContext.context){let t=new s(this.curContext.tracker,e);t.hash!=this.curContext.hash&&this.emitContext(),this.curContext=t}}setLookAhead(e){return!(e<=this.lookAhead)&&(this.emitLookAhead(),this.lookAhead=e,!0)}close(){this.curContext&&this.curContext.tracker.strict&&this.emitContext(),this.lookAhead>0&&this.emitLookAhead()}}class s{constructor(e,t){this.tracker=e,this.context=t,this.hash=e.strict?e.hash(t):0}}class l{constructor(e){this.start=e,this.state=e.state,this.stack=e.stack,this.base=this.stack.length}reduce(e){let t=65535&e,n=e>>19;0==n?(this.stack==this.start.stack&&(this.stack=this.stack.slice()),this.stack.push(this.state,0,0),this.base+=3):this.base-=3*(n-1);let r=this.start.p.parser.getGoto(this.stack[this.base-3],t,!0);this.state=r}}class c{constructor(e,t,n){this.stack=e,this.pos=t,this.index=n,this.buffer=e.buffer,0==this.index&&this.maybeNext()}static create(e,t=e.bufferBase+e.buffer.length){return new c(e,t,t-e.bufferBase)}maybeNext(){let e=this.stack.parent;null!=e&&(this.index=this.stack.bufferBase-e.bufferBase,this.stack=e,this.buffer=e.buffer)}get id(){return this.buffer[this.index-4]}get start(){return this.buffer[this.index-3]}get end(){return this.buffer[this.index-2]}get size(){return this.buffer[this.index-1]}next(){this.index-=4,this.pos-=4,0==this.index&&this.maybeNext()}fork(){return new c(this.stack,this.pos,this.index)}}function u(e,t=Uint16Array){if("string"!=typeof e)return e;let n=null;for(let r=0,i=0;r<e.length;){let o=0;for(;;){let t=e.charCodeAt(r++),n=!1;if(126==t){o=65535;break}t>=92&&t--,t>=34&&t--;let i=t-32;if(i>=46&&(i-=46,n=!0),o+=i,n)break;o*=46}n?n[i++]=o:n=new t(o)}return n}class d{constructor(){this.start=-1,this.value=-1,this.end=-1,this.extended=-1,this.lookAhead=0,this.mask=0,this.context=0}}const h=new d;class p{constructor(e,t){this.input=e,this.ranges=t,this.chunk="",this.chunkOff=0,this.chunk2="",this.chunk2Pos=0,this.next=-1,this.token=h,this.rangeIndex=0,this.pos=this.chunkPos=t[0].from,this.range=t[0],this.end=t[t.length-1].to,this.readNext()}resolveOffset(e,t){let n=this.range,r=this.rangeIndex,i=this.pos+e;while(i<n.from){if(!r)return null;let e=this.ranges[--r];i-=n.from-e.to,n=e}while(t<0?i>n.to:i>=n.to){if(r==this.ranges.length-1)return null;let e=this.ranges[++r];i+=e.from-n.to,n=e}return i}clipPos(e){if(e>=this.range.from&&e<this.range.to)return e;for(let t of this.ranges)if(t.to>e)return Math.max(e,t.from);return this.end}peek(e){let t,n,r=this.chunkOff+e;if(r>=0&&r<this.chunk.length)t=this.pos+e,n=this.chunk.charCodeAt(r);else{let r=this.resolveOffset(e,1);if(null==r)return-1;if(t=r,t>=this.chunk2Pos&&t<this.chunk2Pos+this.chunk2.length)n=this.chunk2.charCodeAt(t-this.chunk2Pos);else{let e=this.rangeIndex,r=this.range;while(r.to<=t)r=this.ranges[++e];this.chunk2=this.input.chunk(this.chunk2Pos=t),t+this.chunk2.length>r.to&&(this.chunk2=this.chunk2.slice(0,r.to-t)),n=this.chunk2.charCodeAt(0)}}return t>=this.token.lookAhead&&(this.token.lookAhead=t+1),n}acceptToken(e,t=0){let n=t?this.resolveOffset(t,-1):this.pos;if(null==n||n<this.token.start)throw new RangeError("Token end out of bounds");this.token.value=e,this.token.end=n}acceptTokenTo(e,t){this.token.value=e,this.token.end=t}getChunk(){if(this.pos>=this.chunk2Pos&&this.pos<this.chunk2Pos+this.chunk2.length){let{chunk:e,chunkPos:t}=this;this.chunk=this.chunk2,this.chunkPos=this.chunk2Pos,this.chunk2=e,this.chunk2Pos=t,this.chunkOff=this.pos-this.chunkPos}else{this.chunk2=this.chunk,this.chunk2Pos=this.chunkPos;let e=this.input.chunk(this.pos),t=this.pos+e.length;this.chunk=t>this.range.to?e.slice(0,this.range.to-this.pos):e,this.chunkPos=this.pos,this.chunkOff=0}}readNext(){return this.chunkOff>=this.chunk.length&&(this.getChunk(),this.chunkOff==this.chunk.length)?this.next=-1:this.next=this.chunk.charCodeAt(this.chunkOff)}advance(e=1){this.chunkOff+=e;while(this.pos+e>=this.range.to){if(this.rangeIndex==this.ranges.length-1)return this.setDone();e-=this.range.to-this.pos,this.range=this.ranges[++this.rangeIndex],this.pos=this.range.from}return this.pos+=e,this.pos>=this.token.lookAhead&&(this.token.lookAhead=this.pos+1),this.readNext()}setDone(){return this.pos=this.chunkPos=this.end,this.range=this.ranges[this.rangeIndex=this.ranges.length-1],this.chunk="",this.next=-1}reset(e,t){if(t?(this.token=t,t.start=e,t.lookAhead=e+1,t.value=t.extended=-1):this.token=h,this.pos!=e){if(this.pos=e,e==this.end)return this.setDone(),this;while(e<this.range.from)this.range=this.ranges[--this.rangeIndex];while(e>=this.range.to)this.range=this.ranges[++this.rangeIndex];e>=this.chunkPos&&e<this.chunkPos+this.chunk.length?this.chunkOff=e-this.chunkPos:(this.chunk="",this.chunkOff=0),this.readNext()}return this}read(e,t){if(e>=this.chunkPos&&t<=this.chunkPos+this.chunk.length)return this.chunk.slice(e-this.chunkPos,t-this.chunkPos);if(e>=this.chunk2Pos&&t<=this.chunk2Pos+this.chunk2.length)return this.chunk2.slice(e-this.chunk2Pos,t-this.chunk2Pos);if(e>=this.range.from&&t<=this.range.to)return this.input.read(e,t);let n="";for(let r of this.ranges){if(r.from>=t)break;r.to>e&&(n+=this.input.read(Math.max(r.from,e),Math.min(r.to,t)))}return n}}class f{constructor(e,t){this.data=e,this.id=t}token(e,t){let{parser:n}=t.p;v(this.data,e,t,this.id,n.data,n.tokenPrecTable)}}f.prototype.contextual=f.prototype.fallback=f.prototype.extend=!1;class m{constructor(e,t,n){this.precTable=t,this.elseToken=n,this.data="string"==typeof e?u(e):e}token(e,t){let n=e.pos,r=0;for(;;){let n=e.next<0,i=e.resolveOffset(1,1);if(v(this.data,e,t,0,this.data,this.precTable),e.token.value>-1)break;if(null==this.elseToken)return;if(n||r++,null==i)break;e.reset(i,e.token)}r&&(e.reset(n,e.token),e.acceptToken(this.elseToken,r))}}m.prototype.contextual=f.prototype.fallback=f.prototype.extend=!1;class g{constructor(e,t={}){this.token=e,this.contextual=!!t.contextual,this.fallback=!!t.fallback,this.extend=!!t.extend}}function v(e,t,n,r,i,o){let a=0,s=1<<r,{dialect:l}=n.p.parser;e:for(;;){if(0==(s&e[a]))break;let n=e[a+1];for(let d=a+3;d<n;d+=2)if((e[d+1]&s)>0){let n=e[d];if(l.allows(n)&&(-1==t.token.value||t.token.value==n||y(n,t.token.value,i,o))){t.acceptToken(n);break}}let r=t.next,c=0,u=e[a+2];if(!(t.next<0&&u>c&&65535==e[n+3*u-3])){for(;c<u;){let i=c+u>>1,o=n+i+(i<<1),s=e[o],l=e[o+1]||65536;if(r<s)u=i;else{if(!(r>=l)){a=e[o+2],t.advance();continue e}c=i+1}}break}a=e[n+3*u-1]}}function b(e,t,n){for(let r,i=t;65535!=(r=e[i]);i++)if(r==n)return i-t;return-1}function y(e,t,n,r){let i=b(n,r,t);return i<0||b(n,r,e)<i}const w="undefined"!=typeof i&&{NODE_ENV:"production",BASE_URL:"/"}&&/\bparse\b/.test({NODE_ENV:"production",BASE_URL:"/"}.LOG);let O=null;function S(e,t,n){let i=e.cursor(r.IterMode.IncludeAnonymous);for(i.moveTo(t);;)if(!(n<0?i.childBefore(t):i.childAfter(t)))for(;;){if((n<0?i.to<t:i.from>t)&&!i.type.isError)return n<0?Math.max(0,Math.min(i.to-1,t-25)):Math.min(e.length,Math.max(i.from+1,t+25));if(n<0?i.prevSibling():i.nextSibling())break;if(!i.parent())return n<0?0:e.length}}class E{constructor(e,t){this.fragments=e,this.minRepeat=t,this.i=0,this.fragment=null,this.safeFrom=-1,this.safeTo=-1,this.trees=[],this.start=[],this.index=[],this.lastRepeat=null,this.lastRepeatPos=-1,this.nextFragment()}nextFragment(){let e=this.fragment=this.i==this.fragments.length?null:this.fragments[this.i++];if(e){this.safeFrom=e.openStart?S(e.tree,e.from+e.offset,1)-e.offset:e.from,this.safeTo=e.openEnd?S(e.tree,e.to+e.offset,-1)-e.offset:e.to;while(this.trees.length)this.trees.pop(),this.start.pop(),this.index.pop();this.trees.push(e.tree),this.start.push(-e.offset),this.index.push(0),this.nextStart=this.safeFrom}else this.nextStart=1e9}nodeAt(e){if(e<this.nextStart)return null;while(this.fragment&&this.safeTo<=e)this.nextFragment();if(!this.fragment)return null;for(;;){let t=this.trees.length-1;if(t<0)return this.nextFragment(),null;let n=this.trees[t],i=this.index[t];if(i==n.children.length){this.trees.pop(),this.start.pop(),this.index.pop();continue}let o=n.children[i],a=this.start[t]+n.positions[i];if(a>e)return this.nextStart=a,null;if(o instanceof r.Tree){let n=a>this.lastRepeatPos&&o.type.id>=this.minRepeat;if(a==e||n){let t,i=a+o.length;if(a>=this.safeFrom&&i<=this.safeTo&&(!(t=o.prop(r.NodeProp.lookAhead))||i+t<this.fragment.to)){if(n&&(this.lastRepeat=o,this.lastRepeatPos=a),a==e)return o}else if(a==e)return null}this.index[t]++,a+o.length>=Math.max(this.safeFrom,e)&&(this.trees.push(o),this.start.push(a),this.index.push(0))}else this.index[t]++,this.nextStart=a+o.length}}}class x{constructor(e,t){this.stream=t,this.tokens=[],this.mainToken=null,this.actions=[],this.tokens=e.tokenizers.map(e=>new d)}getActions(e){let t=0,n=null,{parser:r}=e.p,{tokenizers:i}=r,o=r.stateSlot(e.state,3),a=e.curContext?e.curContext.hash:0,s=0;for(let l=0;l<i.length;l++){if(0==(1<<l&o))continue;let r=i[l],c=this.tokens[l];if((!n||r.fallback)&&((r.contextual||c.start!=e.pos||c.mask!=o||c.context!=a)&&(this.updateCachedToken(c,r,e),c.mask=o,c.context=a),c.lookAhead>c.end+25&&(s=Math.max(c.lookAhead,s)),0!=c.value)){let i=t;if(c.extended>-1&&(t=this.addActions(e,c.extended,c.end,t)),t=this.addActions(e,c.value,c.end,t),!r.extend&&(n=c,t>i))break}}while(this.actions.length>t)this.actions.pop();return s&&e.setLookAhead(s),n||e.pos!=this.stream.end||(n=new d,n.value=e.p.parser.eofTerm,n.start=n.end=e.pos,t=this.addActions(e,n.value,n.end,t)),this.mainToken=n,this.actions}getMainToken(e){if(this.mainToken)return this.mainToken;let t=new d,{pos:n,p:r}=e;return t.start=n,t.end=Math.min(n+1,r.stream.end),t.value=n==r.stream.end?r.parser.eofTerm:0,t}updateCachedToken(e,t,n){let r=this.stream.clipPos(n.pos);if(t.token(this.stream.reset(r,e),n),e.value>-1){let{parser:t}=n.p;for(let r=0;r<t.specialized.length;r++)if(t.specialized[r]==e.value){let i=t.specializers[r](this.stream.read(e.start,e.end),n);if(i>=0&&n.p.parser.dialect.allows(i>>1)){0==(1&i)?e.value=i>>1:e.extended=i>>1;break}}}else e.value=0,e.end=this.stream.clipPos(r+1)}putAction(e,t,n,r){for(let i=0;i<r;i+=3)if(this.actions[i]==e)return r;return this.actions[r++]=e,this.actions[r++]=t,this.actions[r++]=n,r}addActions(e,t,n,r){let{state:i}=e,{parser:o}=e.p,{data:a}=o;for(let s=0;s<2;s++)for(let e=o.stateSlot(i,s?2:1);;e+=3){if(65535==a[e]){if(1!=a[e+1]){0==r&&2==a[e+1]&&(r=this.putAction(N(a,e+2),t,n,r));break}e=N(a,e+2)}a[e]==t&&(r=this.putAction(N(a,e+1),t,n,r))}return r}}class _{constructor(e,t,n,r){this.parser=e,this.input=t,this.ranges=r,this.recovering=0,this.nextStackID=9812,this.minStackPos=0,this.reused=[],this.stoppedAt=null,this.lastBigReductionStart=-1,this.lastBigReductionSize=0,this.bigReductionCount=0,this.stream=new p(t,r),this.tokens=new x(e,this.stream),this.topTerm=e.top[1];let{from:i}=r[0];this.stacks=[a.start(this,e.top[0],i)],this.fragments=n.length&&this.stream.end-i>4*e.bufferLength?new E(n,e.minRepeatTerm):null}get parsedPos(){return this.minStackPos}advance(){let e,t,n=this.stacks,r=this.minStackPos,i=this.stacks=[];if(this.bigReductionCount>300&&1==n.length){let[e]=n;while(e.forceReduce()&&e.stack.length&&e.stack[e.stack.length-2]>=this.lastBigReductionStart);this.bigReductionCount=this.lastBigReductionSize=0}for(let o=0;o<n.length;o++){let a=n[o];for(;;){if(this.tokens.mainToken=null,a.pos>r)i.push(a);else{if(this.advanceStack(a,i,n))continue;{e||(e=[],t=[]),e.push(a);let n=this.tokens.getMainToken(a);t.push(n.value,n.end)}}break}}if(!i.length){let t=e&&P(e);if(t)return w&&o.log("Finish with "+this.stackID(t)),this.stackToTree(t);if(this.parser.strict)throw w&&e&&o.log("Stuck with token "+(this.tokens.mainToken?this.parser.getName(this.tokens.mainToken.value):"none")),new SyntaxError("No parse at "+r);this.recovering||(this.recovering=5)}if(this.recovering&&e){let n=null!=this.stoppedAt&&e[0].pos>this.stoppedAt?e[0]:this.runRecovery(e,t,i);if(n)return w&&o.log("Force-finish "+this.stackID(n)),this.stackToTree(n.forceAll())}if(this.recovering){let e=1==this.recovering?1:3*this.recovering;if(i.length>e){i.sort((e,t)=>t.score-e.score);while(i.length>e)i.pop()}i.some(e=>e.reducePos>r)&&this.recovering--}else if(i.length>1){e:for(let e=0;e<i.length-1;e++){let t=i[e];for(let n=e+1;n<i.length;n++){let r=i[n];if(t.sameState(r)||t.buffer.length>500&&r.buffer.length>500){if(!((t.score-r.score||t.buffer.length-r.buffer.length)>0)){i.splice(e--,1);continue e}i.splice(n--,1)}}}i.length>12&&(i.sort((e,t)=>t.score-e.score),i.splice(12,i.length-12))}this.minStackPos=i[0].pos;for(let o=1;o<i.length;o++)i[o].pos<this.minStackPos&&(this.minStackPos=i[o].pos);return null}stopAt(e){if(null!=this.stoppedAt&&this.stoppedAt<e)throw new RangeError("Can't move stoppedAt forward");this.stoppedAt=e}tryReuse(e,t,n,i){if(!n)return null;let o=e.curContext&&e.curContext.tracker.strict,a=o?e.curContext.hash:0;for(;n;){let s=this.parser.nodeSet.types[n.type.id]!=n.type?-1:this.parser.getGoto(e.state,n.type.id);if(s>-1&&n.length&&(!o||(n.prop(r.NodeProp.contextHash)||0)==a))return e.useNode(n,s,t),n;if(0==n.children.length||n.positions[0]>0)break;let l=n.children[0];if(!(l instanceof r.Tree&&(!i||l.type.id>=this.parser.minRepeatTerm)))break;n=l}return null}advanceStack(e,t,n){let r=e.pos,{parser:i}=this,a=w?this.stackID(e)+" -> ":"";if(null!=this.stoppedAt&&r>this.stoppedAt)return e.forceReduce()?e:null;if(this.fragments){let t=e.reducePos<r&&e.buffer.length&&e.buffer[e.buffer.length-2]<=e.reducePos&&this.fragments.lastRepeatPos==e.reducePos&&this.tryReuse(e,e.reducePos,this.fragments.lastRepeat,!0)||this.tryReuse(e,r,this.fragments.nodeAt(r),!1);if(t)return w&&o.log(a+this.stackID(e)+` (via reuse of ${i.getName(t.type.id)})`),!0}let s=i.stateSlot(e.state,4);if(s>0)return e.reduce(s),w&&o.log(a+this.stackID(e)+` (via always-reduce ${i.getName(65535&s)})`),!0;if(e.stack.length>=8400)while(e.stack.length>6e3&&e.forceReduce());let l=this.tokens.getActions(e);for(let c=0;c<l.length;){let s=l[c++],u=l[c++],d=l[c++],h=c==l.length||!n,p=h?e:e.split(),f=this.tokens.mainToken;if(p.apply(s,u,f?f.start:p.pos,d),w&&o.log(a+this.stackID(p)+` (via ${0==(65536&s)?"shift":`reduce of ${i.getName(65535&s)}`} for ${i.getName(u)} @ ${r}${p==e?"":", split"})`),h)return!0;p.pos>r?t.push(p):n.push(p)}return!1}advanceFully(e,t){let n=e.pos;for(;;){if(!this.advanceStack(e,null,null))return!1;if(e.pos>n)return k(e,t),!0}}runRecovery(e,t,n){let r=null,i=!1;for(let a=0;a<e.length;a++){let s=e[a],l=t[a<<1],c=t[1+(a<<1)],u=w?this.stackID(s)+" -> ":"";if(s.deadEnd){if(i)continue;i=!0,s.restart(),w&&o.log(u+this.stackID(s)+" (restarted)");let e=this.advanceFully(s,n);if(e)continue}let d=s.split(),h=u;for(let e=0;e<10&&d.forceReduce();e++){w&&o.log(h+this.stackID(d)+" (via force-reduce)");let e=this.advanceFully(d,n);if(e)break;w&&(h=this.stackID(d)+" -> ")}for(let e of s.recoverByInsert(l))w&&o.log(u+this.stackID(e)+" (via recover-insert)"),this.advanceFully(e,n);this.stream.end>s.pos?(c==s.pos&&(c++,l=0),s.recoverByDelete(l,c),w&&o.log(u+this.stackID(s)+` (via recover-delete ${this.parser.getName(l)})`),k(s,n)):(!r||r.score<d.score)&&(r=d)}return r}stackToTree(e){return e.close(),r.Tree.build({buffer:c.create(e),nodeSet:this.parser.nodeSet,topID:this.topTerm,maxBufferLength:this.parser.bufferLength,reused:this.reused,start:this.ranges[0].from,length:e.pos-this.ranges[0].from,minRepeatType:this.parser.minRepeatTerm})}stackID(e){let t=(O||(O=new WeakMap)).get(e);return t||O.set(e,t=String.fromCodePoint(this.nextStackID++)),t+e}}function k(e,t){for(let n=0;n<t.length;n++){let r=t[n];if(r.pos==e.pos&&r.sameState(e))return void(t[n].score<e.score&&(t[n]=e))}t.push(e)}class C{constructor(e,t,n){this.source=e,this.flags=t,this.disabled=n}allows(e){return!this.disabled||0==this.disabled[e]}}const A=e=>e;class T{constructor(e){this.start=e.start,this.shift=e.shift||A,this.reduce=e.reduce||A,this.reuse=e.reuse||A,this.hash=e.hash||(()=>0),this.strict=!1!==e.strict}}class R extends r.Parser{constructor(e){if(super(),this.wrappers=[],14!=e.version)throw new RangeError(`Parser version (${e.version}) doesn't match runtime version (14)`);let t=e.nodeNames.split(" ");this.minRepeatTerm=t.length;for(let r=0;r<e.repeatNodeCount;r++)t.push("");let n=Object.keys(e.topRules).map(t=>e.topRules[t][1]),i=[];for(let r=0;r<t.length;r++)i.push([]);function o(e,t,n){i[e].push([t,t.deserialize(String(n))])}if(e.nodeProps)for(let s of e.nodeProps){let e=s[0];"string"==typeof e&&(e=r.NodeProp[e]);for(let t=1;t<s.length;){let n=s[t++];if(n>=0)o(n,e,s[t++]);else{let r=s[t+-n];for(let i=-n;i>0;i--)o(s[t++],e,r);t++}}}this.nodeSet=new r.NodeSet(t.map((t,o)=>r.NodeType.define({name:o>=this.minRepeatTerm?void 0:t,id:o,props:i[o],top:n.indexOf(o)>-1,error:0==o,skipped:e.skippedNodes&&e.skippedNodes.indexOf(o)>-1}))),e.propSources&&(this.nodeSet=this.nodeSet.extend(...e.propSources)),this.strict=!1,this.bufferLength=r.DefaultBufferLength;let a=u(e.tokenData);this.context=e.context,this.specializerSpecs=e.specialized||[],this.specialized=new Uint16Array(this.specializerSpecs.length);for(let r=0;r<this.specializerSpecs.length;r++)this.specialized[r]=this.specializerSpecs[r].term;this.specializers=this.specializerSpecs.map(I),this.states=u(e.states,Uint32Array),this.data=u(e.stateData),this.goto=u(e.goto),this.maxTerm=e.maxTerm,this.tokenizers=e.tokenizers.map(e=>"number"==typeof e?new f(a,e):e),this.topRules=e.topRules,this.dialects=e.dialects||{},this.dynamicPrecedences=e.dynamicPrecedences||null,this.tokenPrecTable=e.tokenPrec,this.termNames=e.termNames||null,this.maxNode=this.nodeSet.types.length-1,this.dialect=this.parseDialect(),this.top=this.topRules[Object.keys(this.topRules)[0]]}createParse(e,t,n){let r=new _(this,e,t,n);for(let i of this.wrappers)r=i(r,e,t,n);return r}getGoto(e,t,n=!1){let r=this.goto;if(t>=r[0])return-1;for(let i=r[t+1];;){let t=r[i++],o=1&t,a=r[i++];if(o&&n)return a;for(let n=i+(t>>1);i<n;i++)if(r[i]==e)return a;if(o)return-1}}hasAction(e,t){let n=this.data;for(let r=0;r<2;r++)for(let i,o=this.stateSlot(e,r?2:1);;o+=3){if(65535==(i=n[o])){if(1!=n[o+1]){if(2==n[o+1])return N(n,o+2);break}i=n[o=N(n,o+2)]}if(i==t||0==i)return N(n,o+1)}return 0}stateSlot(e,t){return this.states[6*e+t]}stateFlag(e,t){return(this.stateSlot(e,0)&t)>0}validAction(e,t){return!!this.allActions(e,e=>e==t||null)}allActions(e,t){let n=this.stateSlot(e,4),r=n?t(n):void 0;for(let i=this.stateSlot(e,1);null==r;i+=3){if(65535==this.data[i]){if(1!=this.data[i+1])break;i=N(this.data,i+2)}r=t(N(this.data,i+1))}return r}nextStates(e){let t=[];for(let n=this.stateSlot(e,1);;n+=3){if(65535==this.data[n]){if(1!=this.data[n+1])break;n=N(this.data,n+2)}if(0==(1&this.data[n+2])){let e=this.data[n+1];t.some((t,n)=>1&n&&t==e)||t.push(this.data[n],e)}}return t}configure(e){let t=Object.assign(Object.create(R.prototype),this);if(e.props&&(t.nodeSet=this.nodeSet.extend(...e.props)),e.top){let n=this.topRules[e.top];if(!n)throw new RangeError(`Invalid top rule name ${e.top}`);t.top=n}return e.tokenizers&&(t.tokenizers=this.tokenizers.map(t=>{let n=e.tokenizers.find(e=>e.from==t);return n?n.to:t})),e.specializers&&(t.specializers=this.specializers.slice(),t.specializerSpecs=this.specializerSpecs.map((n,r)=>{let i=e.specializers.find(e=>e.from==n.external);if(!i)return n;let o=Object.assign(Object.assign({},n),{external:i.to});return t.specializers[r]=I(o),o})),e.contextTracker&&(t.context=e.contextTracker),e.dialect&&(t.dialect=this.parseDialect(e.dialect)),null!=e.strict&&(t.strict=e.strict),e.wrap&&(t.wrappers=t.wrappers.concat(e.wrap)),null!=e.bufferLength&&(t.bufferLength=e.bufferLength),t}hasWrappers(){return this.wrappers.length>0}getName(e){return this.termNames?this.termNames[e]:String(e<=this.maxNode&&this.nodeSet.types[e].name||e)}get eofTerm(){return this.maxNode+1}get topNode(){return this.nodeSet.types[this.top[1]]}dynamicPrecedence(e){let t=this.dynamicPrecedences;return null==t?0:t[e]||0}parseDialect(e){let t=Object.keys(this.dialects),n=t.map(()=>!1);if(e)for(let i of e.split(" ")){let e=t.indexOf(i);e>=0&&(n[e]=!0)}let r=null;for(let i=0;i<t.length;i++)if(!n[i])for(let e,n=this.dialects[t[i]];65535!=(e=this.data[n++]);)(r||(r=new Uint8Array(this.maxTerm+1)))[e]=1;return new C(e,n,r)}static deserialize(e){return new R(e)}}function N(e,t){return e[t]|e[t+1]<<16}function P(e){let t=null;for(let n of e){let e=n.p.stoppedAt;(n.pos==n.p.stream.end||null!=e&&n.pos>e)&&n.p.parser.stateFlag(n.state,2)&&(!t||t.score<n.score)&&(t=n)}return t}function I(e){if(e.external){let t=e.extend?1:0;return(n,r)=>e.external(n,r)<<1|t}return e.get}},49609:function(e,t,n){"use strict";n.r(t),n.d(t,{CompletionContext:function(){return a},acceptCompletion:function(){return X},autocompletion:function(){return rt},clearSnippet:function(){return be},closeBrackets:function(){return Ve},closeBracketsKeymap:function(){return Qe},closeCompletion:function(){return Z},completeAnyWord:function(){return Me},completeFromList:function(){return c},completionKeymap:function(){return it},completionStatus:function(){return at},currentCompletions:function(){return lt},deleteBracketPair:function(){return qe},hasNextSnippetField:function(){return Oe},hasPrevSnippetField:function(){return Se},ifIn:function(){return u},ifNotIn:function(){return d},insertBracket:function(){return ze},insertCompletionText:function(){return g},moveCompletionSelection:function(){return W},nextSnippetField:function(){return ye},pickedCompletion:function(){return m},prevSnippetField:function(){return we},selectedCompletion:function(){return ct},selectedCompletionIndex:function(){return ut},setSelectedCompletion:function(){return dt},snippet:function(){return ge},snippetCompletion:function(){return ke},snippetKeymap:function(){return xe},startCompletion:function(){return Y}});var r=n(76528),i=n(81068),o=n(61163);class a{constructor(e,t,n,r){this.state=e,this.pos=t,this.explicit=n,this.view=r,this.abortListeners=[],this.abortOnDocChange=!1}tokenBefore(e){let t=(0,o.syntaxTree)(this.state).resolveInner(this.pos,-1);while(t&&e.indexOf(t.name)<0)t=t.parent;return t?{from:t.from,to:this.pos,text:this.state.sliceDoc(t.from,this.pos),type:t.type}:null}matchBefore(e){let t=this.state.doc.lineAt(this.pos),n=Math.max(t.from,this.pos-250),r=t.text.slice(n-t.from,this.pos-t.from),i=r.search(f(e,!1));return i<0?null:{from:n+i,to:this.pos,text:r.slice(i)}}get aborted(){return null==this.abortListeners}addEventListener(e,t,n){"abort"==e&&this.abortListeners&&(this.abortListeners.push(t),n&&n.onDocChange&&(this.abortOnDocChange=!0))}}function s(e){let t=Object.keys(e).join(""),n=/\w/.test(t);return n&&(t=t.replace(/\w/g,"")),`[${n?"\\w":""}${t.replace(/[^\w\s]/g,"\\$&")}]`}function l(e){let t=Object.create(null),n=Object.create(null);for(let{label:i}of e){t[i[0]]=!0;for(let e=1;e<i.length;e++)n[i[e]]=!0}let r=s(t)+s(n)+"*$";return[new RegExp("^"+r),new RegExp(r)]}function c(e){let t=e.map(e=>"string"==typeof e?{label:e}:e),[n,r]=t.every(e=>/^\w+$/.test(e.label))?[/\w*$/,/\w+$/]:l(t);return e=>{let i=e.matchBefore(r);return i||e.explicit?{from:i?i.from:e.pos,options:t,validFor:n}:null}}function u(e,t){return n=>{for(let r=(0,o.syntaxTree)(n.state).resolveInner(n.pos,-1);r;r=r.parent){if(e.indexOf(r.name)>-1)return t(n);if(r.type.isTop)break}return null}}function d(e,t){return n=>{for(let t=(0,o.syntaxTree)(n.state).resolveInner(n.pos,-1);t;t=t.parent){if(e.indexOf(t.name)>-1)return null;if(t.type.isTop)break}return t(n)}}class h{constructor(e,t,n,r){this.completion=e,this.source=t,this.match=n,this.score=r}}function p(e){return e.selection.main.from}function f(e,t){var n;let{source:r}=e,i=t&&"^"!=r[0],o="$"!=r[r.length-1];return i||o?new RegExp(`${i?"^":""}(?:${r})${o?"$":""}`,null!==(n=e.flags)&&void 0!==n?n:e.ignoreCase?"i":""):e}const m=r.Annotation.define();function g(e,t,n,i){let{main:o}=e.selection,a=n-o.from,s=i-o.from;return{...e.changeByRange(l=>{if(l!=o&&n!=i&&e.sliceDoc(l.from+a,l.from+s)!=e.sliceDoc(n,i))return{range:l};let c=e.toText(t);return{changes:{from:l.from+a,to:i==o.from?l.to:l.from+s,insert:c},range:r.EditorSelection.cursor(l.from+a+c.length)}}),scrollIntoView:!0,userEvent:"input.complete"}}const v=new WeakMap;function b(e){if(!Array.isArray(e))return e;let t=v.get(e);return t||v.set(e,t=c(e)),t}const y=r.StateEffect.define(),w=r.StateEffect.define();class O{constructor(e){this.pattern=e,this.chars=[],this.folded=[],this.any=[],this.precise=[],this.byWord=[],this.score=0,this.matched=[];for(let t=0;t<e.length;){let n=(0,r.codePointAt)(e,t),i=(0,r.codePointSize)(n);this.chars.push(n);let o=e.slice(t,t+i),a=o.toUpperCase();this.folded.push((0,r.codePointAt)(a==o?o.toLowerCase():a,0)),t+=i}this.astral=e.length!=this.chars.length}ret(e,t){return this.score=e,this.matched=t,this}match(e){if(0==this.pattern.length)return this.ret(-100,[]);if(e.length<this.pattern.length)return null;let{chars:t,folded:n,any:i,precise:o,byWord:a}=this;if(1==t.length){let i=(0,r.codePointAt)(e,0),o=(0,r.codePointSize)(i),a=o==e.length?0:-100;if(i==t[0]);else{if(i!=n[0])return null;a+=-200}return this.ret(a,[0,o])}let s=e.indexOf(this.pattern);if(0==s)return this.ret(e.length==this.pattern.length?0:-100,[0,this.pattern.length]);let l=t.length,c=0;if(s<0){for(let o=0,a=Math.min(e.length,200);o<a&&c<l;){let a=(0,r.codePointAt)(e,o);a!=t[c]&&a!=n[c]||(i[c++]=o),o+=(0,r.codePointSize)(a)}if(c<l)return null}let u=0,d=0,h=!1,p=0,f=-1,m=-1,g=/[a-z]/.test(e),v=!0;for(let b=0,y=Math.min(e.length,200),w=0;b<y&&d<l;){let i=(0,r.codePointAt)(e,b);s<0&&(u<l&&i==t[u]&&(o[u++]=b),p<l&&(i==t[p]||i==n[p]?(0==p&&(f=b),m=b+1,p++):p=0));let c,y=i<255?i>=48&&i<=57||i>=97&&i<=122?2:i>=65&&i<=90?1:0:(c=(0,r.fromCodePoint)(i))!=c.toLowerCase()?1:c!=c.toUpperCase()?2:0;(!b||1==y&&g||0==w&&0!=y)&&(t[d]==i||n[d]==i&&(h=!0)?a[d++]=b:a.length&&(v=!1)),w=y,b+=(0,r.codePointSize)(i)}return d==l&&0==a[0]&&v?this.result((h?-200:0)-100,a,e):p==l&&0==f?this.ret(-200-e.length+(m==e.length?0:-100),[0,m]):s>-1?this.ret(-700-e.length,[s,s+this.pattern.length]):p==l?this.ret(-900-e.length,[f,m]):d==l?this.result((h?-200:0)-100-700+(v?0:-1100),a,e):2==t.length?null:this.result((i[0]?-700:0)-200-1100,i,e)}result(e,t,n){let i=[],o=0;for(let a of t){let e=a+(this.astral?(0,r.codePointSize)((0,r.codePointAt)(n,a)):1);o&&i[o-1]==a?i[o-1]=e:(i[o++]=a,i[o++]=e)}return this.ret(e-n.length,i)}}class S{constructor(e){this.pattern=e,this.matched=[],this.score=0,this.folded=e.toLowerCase()}match(e){if(e.length<this.pattern.length)return null;let t=e.slice(0,this.pattern.length),n=t==this.pattern?0:t.toLowerCase()==this.folded?-200:null;return null==n?null:(this.matched=[0,t.length],this.score=n+(e.length==this.pattern.length?0:-100),this)}}const E=r.Facet.define({combine(e){return(0,r.combineConfig)(e,{activateOnTyping:!0,activateOnCompletion:()=>!1,activateOnTypingDelay:100,selectOnOpen:!0,override:null,closeOnBlur:!0,maxRenderedOptions:100,defaultKeymap:!0,tooltipClass:()=>"",optionClass:()=>"",aboveCursor:!1,icons:!0,addToOptions:[],positionInfo:_,filterStrict:!1,compareCompletions:(e,t)=>(e.sortText||e.label).localeCompare(t.sortText||t.label),interactionDelay:75,updateSyncTime:100},{defaultKeymap:(e,t)=>e&&t,closeOnBlur:(e,t)=>e&&t,icons:(e,t)=>e&&t,tooltipClass:(e,t)=>n=>x(e(n),t(n)),optionClass:(e,t)=>n=>x(e(n),t(n)),addToOptions:(e,t)=>e.concat(t),filterStrict:(e,t)=>e||t})}});function x(e,t){return e?t?e+" "+t:e:t}function _(e,t,n,r,o,a){let s,l,c=e.textDirection==i.Direction.RTL,u=c,d=!1,h="top",p=t.left-o.left,f=o.right-t.right,m=r.right-r.left,g=r.bottom-r.top;if(u&&p<Math.min(m,f)?u=!1:!u&&f<Math.min(m,p)&&(u=!0),m<=(u?p:f))s=Math.max(o.top,Math.min(n.top,o.bottom-g))-t.top,l=Math.min(400,u?p:f);else{d=!0,l=Math.min(400,(c?t.right:o.right-t.left)-30);let e=o.bottom-t.bottom;e>=g||e>t.top?s=n.bottom-t.top:(h="bottom",s=t.bottom-n.top)}let v=(t.bottom-t.top)/a.offsetHeight,b=(t.right-t.left)/a.offsetWidth;return{style:`${h}: ${s/v}px; max-width: ${l/b}px`,class:"cm-completionInfo-"+(d?c?"left-narrow":"right-narrow":u?"left":"right")}}const k=r.StateEffect.define();function C(e){let t=e.addToOptions.slice();return e.icons&&t.push({render(e){let t=document.createElement("div");return t.classList.add("cm-completionIcon"),e.type&&t.classList.add(...e.type.split(/\s+/g).map(e=>"cm-completionIcon-"+e)),t.setAttribute("aria-hidden","true"),t},position:20}),t.push({render(e,t,n,r){let i=document.createElement("span");i.className="cm-completionLabel";let o=e.displayLabel||e.label,a=0;for(let s=0;s<r.length;){let e=r[s++],t=r[s++];e>a&&i.appendChild(document.createTextNode(o.slice(a,e)));let n=i.appendChild(document.createElement("span"));n.appendChild(document.createTextNode(o.slice(e,t))),n.className="cm-completionMatchedText",a=t}return a<o.length&&i.appendChild(document.createTextNode(o.slice(a))),i},position:50},{render(e){if(!e.detail)return null;let t=document.createElement("span");return t.className="cm-completionDetail",t.textContent=e.detail,t},position:80}),t.sort((e,t)=>e.position-t.position).map(e=>e.render)}function A(e,t,n){if(e<=n)return{from:0,to:e};if(t<0&&(t=0),t<=e>>1){let e=Math.floor(t/n);return{from:e*n,to:(e+1)*n}}let r=Math.ceil((e-t)/n);return{from:e-r*n,to:e-(r-1)*n}}class T{constructor(e,t,n){this.view=e,this.stateField=t,this.applyCompletion=n,this.info=null,this.infoDestroy=null,this.placeInfoReq={read:()=>this.measureInfo(),write:e=>this.placeInfo(e),key:this},this.space=null,this.currentClass="";let r=e.state.field(t),{options:i,selected:o}=r.open,a=e.state.facet(E);this.optionContent=C(a),this.optionClass=a.optionClass,this.tooltipClass=a.tooltipClass,this.range=A(i.length,o,a.maxRenderedOptions),this.dom=document.createElement("div"),this.dom.className="cm-tooltip-autocomplete",this.updateTooltipClass(e.state),this.dom.addEventListener("mousedown",n=>{let{options:r}=e.state.field(t).open;for(let t,i=n.target;i&&i!=this.dom;i=i.parentNode)if("LI"==i.nodeName&&(t=/-(\d+)$/.exec(i.id))&&+t[1]<r.length)return this.applyCompletion(e,r[+t[1]]),void n.preventDefault();if(n.target==this.list){let t=this.list.classList.contains("cm-completionListIncompleteTop")&&n.clientY<this.list.firstChild.getBoundingClientRect().top?this.range.from-1:this.list.classList.contains("cm-completionListIncompleteBottom")&&n.clientY>this.list.lastChild.getBoundingClientRect().bottom?this.range.to:null;null!=t&&(e.dispatch({effects:k.of(t)}),n.preventDefault())}}),this.dom.addEventListener("focusout",t=>{let n=e.state.field(this.stateField,!1);n&&n.tooltip&&e.state.facet(E).closeOnBlur&&t.relatedTarget!=e.contentDOM&&e.dispatch({effects:w.of(null)})}),this.showOptions(i,r.id)}mount(){this.updateSel()}showOptions(e,t){this.list&&this.list.remove(),this.list=this.dom.appendChild(this.createListBox(e,t,this.range)),this.list.addEventListener("scroll",()=>{this.info&&this.view.requestMeasure(this.placeInfoReq)})}update(e){var t;let n=e.state.field(this.stateField),r=e.startState.field(this.stateField);if(this.updateTooltipClass(e.state),n!=r){let{options:i,selected:o,disabled:a}=n.open;r.open&&r.open.options==i||(this.range=A(i.length,o,e.state.facet(E).maxRenderedOptions),this.showOptions(i,n.id)),this.updateSel(),a!=(null===(t=r.open)||void 0===t?void 0:t.disabled)&&this.dom.classList.toggle("cm-tooltip-autocomplete-disabled",!!a)}}updateTooltipClass(e){let t=this.tooltipClass(e);if(t!=this.currentClass){for(let e of this.currentClass.split(" "))e&&this.dom.classList.remove(e);for(let e of t.split(" "))e&&this.dom.classList.add(e);this.currentClass=t}}positioned(e){this.space=e,this.info&&this.view.requestMeasure(this.placeInfoReq)}updateSel(){let e=this.view.state.field(this.stateField),t=e.open;(t.selected>-1&&t.selected<this.range.from||t.selected>=this.range.to)&&(this.range=A(t.options.length,t.selected,this.view.state.facet(E).maxRenderedOptions),this.showOptions(t.options,e.id));let n=this.updateSelectedOption(t.selected);if(n){this.destroyInfo();let{completion:r}=t.options[t.selected],{info:o}=r;if(!o)return;let a="string"===typeof o?document.createTextNode(o):o(r);if(!a)return;"then"in a?a.then(t=>{t&&this.view.state.field(this.stateField,!1)==e&&this.addInfoPane(t,r)}).catch(e=>(0,i.logException)(this.view.state,e,"completion info")):(this.addInfoPane(a,r),n.setAttribute("aria-describedby",this.info.id))}}addInfoPane(e,t){this.destroyInfo();let n=this.info=document.createElement("div");if(n.className="cm-tooltip cm-completionInfo",n.id="cm-completionInfo-"+Math.floor(65535*Math.random()).toString(16),null!=e.nodeType)n.appendChild(e),this.infoDestroy=null;else{let{dom:t,destroy:r}=e;n.appendChild(t),this.infoDestroy=r||null}this.dom.appendChild(n),this.view.requestMeasure(this.placeInfoReq)}updateSelectedOption(e){let t=null;for(let n=this.list.firstChild,r=this.range.from;n;n=n.nextSibling,r++)"LI"==n.nodeName&&n.id?r==e?n.hasAttribute("aria-selected")||(n.setAttribute("aria-selected","true"),t=n):n.hasAttribute("aria-selected")&&(n.removeAttribute("aria-selected"),n.removeAttribute("aria-describedby")):r--;return t&&N(this.list,t),t}measureInfo(){let e=this.dom.querySelector("[aria-selected]");if(!e||!this.info)return null;let t=this.dom.getBoundingClientRect(),n=this.info.getBoundingClientRect(),r=e.getBoundingClientRect(),i=this.space;if(!i){let e=this.dom.ownerDocument.documentElement;i={left:0,top:0,right:e.clientWidth,bottom:e.clientHeight}}return r.top>Math.min(i.bottom,t.bottom)-10||r.bottom<Math.max(i.top,t.top)+10?null:this.view.state.facet(E).positionInfo(this.view,t,r,n,i,this.dom)}placeInfo(e){this.info&&(e?(e.style&&(this.info.style.cssText=e.style),this.info.className="cm-tooltip cm-completionInfo "+(e.class||"")):this.info.style.cssText="top: -1e6px")}createListBox(e,t,n){const r=document.createElement("ul");r.id=t,r.setAttribute("role","listbox"),r.setAttribute("aria-expanded","true"),r.setAttribute("aria-label",this.view.state.phrase("Completions")),r.addEventListener("mousedown",e=>{e.target==r&&e.preventDefault()});let i=null;for(let o=n.from;o<n.to;o++){let{completion:a,match:s}=e[o],{section:l}=a;if(l){let e="string"==typeof l?l:l.name;if(e!=i&&(o>n.from||0==n.from))if(i=e,"string"!=typeof l&&l.header)r.appendChild(l.header(l));else{let t=r.appendChild(document.createElement("completion-section"));t.textContent=e}}const c=r.appendChild(document.createElement("li"));c.id=t+"-"+o,c.setAttribute("role","option");let u=this.optionClass(a);u&&(c.className=u);for(let e of this.optionContent){let t=e(a,this.view.state,this.view,s);t&&c.appendChild(t)}}return n.from&&r.classList.add("cm-completionListIncompleteTop"),n.to<e.length&&r.classList.add("cm-completionListIncompleteBottom"),r}destroyInfo(){this.info&&(this.infoDestroy&&this.infoDestroy(),this.info.remove(),this.info=null)}destroy(){this.destroyInfo()}}function R(e,t){return n=>new T(n,e,t)}function N(e,t){let n=e.getBoundingClientRect(),r=t.getBoundingClientRect(),i=n.height/e.offsetHeight;r.top<n.top?e.scrollTop-=(n.top-r.top)/i:r.bottom>n.bottom&&(e.scrollTop+=(r.bottom-n.bottom)/i)}function P(e){return 100*(e.boost||0)+(e.apply?10:0)+(e.info?5:0)+(e.type?1:0)}function I(e,t){let n=[],r=null,i=null,o=e=>{n.push(e);let{section:t}=e.completion;if(t){r||(r=[]);let e="string"==typeof t?t:t.name;r.some(t=>t.name==e)||r.push("string"==typeof t?{name:e}:t)}},a=t.facet(E);for(let u of e)if(u.hasResult()){let e=u.result.getMatch;if(!1===u.result.filter)for(let t of u.result.options)o(new h(t,u.source,e?e(t):[],1e9-n.length));else{let n,r=t.sliceDoc(u.from,u.to),s=a.filterStrict?new S(r):new O(r);for(let t of u.result.options)if(n=s.match(t.label)){let r=t.displayLabel?e?e(t,n.matched):[]:n.matched,a=n.score+(t.boost||0);if(o(new h(t,u.source,r,a)),"object"==typeof t.section&&"dynamic"===t.section.rank){let{name:e}=t.section;i||(i=Object.create(null)),i[e]=Math.max(a,i[e]||-1e9)}}}}if(r){let e=Object.create(null),t=0,o=(e,t)=>("dynamic"===e.rank&&"dynamic"===t.rank?i[t.name]-i[e.name]:0)||("number"==typeof e.rank?e.rank:1e9)-("number"==typeof t.rank?t.rank:1e9)||(e.name<t.name?-1:1);for(let n of r.sort(o))t-=1e5,e[n.name]=t;for(let r of n){let{section:t}=r.completion;t&&(r.score+=e["string"==typeof t?t:t.name])}}let s=[],l=null,c=a.compareCompletions;for(let u of n.sort((e,t)=>t.score-e.score||c(e.completion,t.completion))){let e=u.completion;!l||l.label!=e.label||l.detail!=e.detail||null!=l.type&&null!=e.type&&l.type!=e.type||l.apply!=e.apply||l.boost!=e.boost?s.push(u):P(u.completion)>P(l)&&(s[s.length-1]=u),l=u.completion}return s}class M{constructor(e,t,n,r,i,o){this.options=e,this.attrs=t,this.tooltip=n,this.timestamp=r,this.selected=i,this.disabled=o}setSelected(e,t){return e==this.selected||e>=this.options.length?this:new M(this.options,V(t,e),this.tooltip,this.timestamp,e,this.disabled)}static build(e,t,n,r,i,o){if(r&&!o&&e.some(e=>e.isPending))return r.setDisabled();let a=I(e,t);if(!a.length)return r&&e.some(e=>e.isPending)?r.setDisabled():null;let s=t.facet(E).selectOnOpen?0:-1;if(r&&r.selected!=s&&-1!=r.selected){let e=r.options[r.selected].completion;for(let t=0;t<a.length;t++)if(a[t].completion==e){s=t;break}}return new M(a,V(n,s),{pos:e.reduce((e,t)=>t.hasResult()?Math.min(e,t.from):e,1e8),create:K,above:i.aboveCursor},r?r.timestamp:Date.now(),s,!1)}map(e){return new M(this.options,this.attrs,{...this.tooltip,pos:e.mapPos(this.tooltip.pos)},this.timestamp,this.selected,this.disabled)}setDisabled(){return new M(this.options,this.attrs,this.tooltip,this.timestamp,this.selected,!0)}}class D{constructor(e,t,n){this.active=e,this.id=t,this.open=n}static start(){return new D(F,"cm-ac-"+Math.floor(2e6*Math.random()).toString(36),null)}update(e){let{state:t}=e,n=t.facet(E),r=n.override||t.languageDataAt("autocomplete",p(t)).map(b),i=r.map(t=>{let r=this.active.find(e=>e.source==t)||new U(t,this.active.some(e=>0!=e.state)?1:0);return r.update(e,n)});i.length==this.active.length&&i.every((e,t)=>e==this.active[t])&&(i=this.active);let o=this.open,a=e.effects.some(e=>e.is(q));o&&e.docChanged&&(o=o.map(e.changes)),e.selection||i.some(t=>t.hasResult()&&e.changes.touchesRange(t.from,t.to))||!L(i,this.active)||a?o=M.build(i,t,this.id,o,n,a):o&&o.disabled&&!i.some(e=>e.isPending)&&(o=null),!o&&i.every(e=>!e.isPending)&&i.some(e=>e.hasResult())&&(i=i.map(e=>e.hasResult()?new U(e.source,0):e));for(let s of e.effects)s.is(k)&&(o=o&&o.setSelected(s.value,this.id));return i==this.active&&o==this.open?this:new D(i,this.id,o)}get tooltip(){return this.open?this.open.tooltip:null}get attrs(){return this.open?this.open.attrs:this.active.length?B:$}}function L(e,t){if(e==t)return!0;for(let n=0,r=0;;){while(n<e.length&&!e[n].hasResult())n++;while(r<t.length&&!t[r].hasResult())r++;let i=n==e.length,o=r==t.length;if(i||o)return i==o;if(e[n++].result!=t[r++].result)return!1}}const B={"aria-autocomplete":"list"},$={};function V(e,t){let n={"aria-autocomplete":"list","aria-haspopup":"listbox","aria-controls":e};return t>-1&&(n["aria-activedescendant"]=e+"-"+t),n}const F=[];function j(e,t){if(e.isUserEvent("input.complete")){let n=e.annotation(m);if(n&&t.activateOnCompletion(n))return 12}let n=e.isUserEvent("input.type");return n&&t.activateOnTyping?5:n?1:e.isUserEvent("delete.backward")?2:e.selection?8:e.docChanged?16:0}class U{constructor(e,t,n=!1){this.source=e,this.state=t,this.explicit=n}hasResult(){return!1}get isPending(){return 1==this.state}update(e,t){let n=j(e,t),r=this;(8&n||16&n&&this.touches(e))&&(r=new U(r.source,0)),4&n&&0==r.state&&(r=new U(this.source,1)),r=r.updateFor(e,n);for(let i of e.effects)if(i.is(y))r=new U(r.source,1,i.value);else if(i.is(w))r=new U(r.source,0);else if(i.is(q))for(let e of i.value)e.source==r.source&&(r=e);return r}updateFor(e,t){return this.map(e.changes)}map(e){return this}touches(e){return e.changes.touchesRange(p(e.state))}}class G extends U{constructor(e,t,n,r,i,o){super(e,3,t),this.limit=n,this.result=r,this.from=i,this.to=o}hasResult(){return!0}updateFor(e,t){var n;if(!(3&t))return this.map(e.changes);let r=this.result;r.map&&!e.changes.empty&&(r=r.map(r,e.changes));let i=e.changes.mapPos(this.from),o=e.changes.mapPos(this.to,1),s=p(e.state);if(s>o||!r||2&t&&(p(e.startState)==this.from||s<this.limit))return new U(this.source,4&t?1:0);let l=e.changes.mapPos(this.limit);return H(r.validFor,e.state,i,o)?new G(this.source,this.explicit,l,r,i,o):r.update&&(r=r.update(r,i,o,new a(e.state,s,!1)))?new G(this.source,this.explicit,l,r,r.from,null!==(n=r.to)&&void 0!==n?n:p(e.state)):new U(this.source,1,this.explicit)}map(e){if(e.empty)return this;let t=this.result.map?this.result.map(this.result,e):this.result;return t?new G(this.source,this.explicit,e.mapPos(this.limit),t,e.mapPos(this.from),e.mapPos(this.to,1)):new U(this.source,0)}touches(e){return e.changes.touchesRange(this.from,this.to)}}function H(e,t,n,r){if(!e)return!1;let i=t.sliceDoc(n,r);return"function"==typeof e?e(i,n,r,t):f(e,!0).test(i)}const q=r.StateEffect.define({map(e,t){return e.map(e=>e.map(t))}}),Q=r.StateField.define({create(){return D.start()},update(e,t){return e.update(t)},provide:e=>[i.showTooltip.from(e,e=>e.tooltip),i.EditorView.contentAttributes.from(e,e=>e.attrs)]});function z(e,t){const n=t.completion.apply||t.completion.label;let r=e.state.field(Q).active.find(e=>e.source==t.source);return r instanceof G&&("string"==typeof n?e.dispatch({...g(e.state,n,r.from,r.to),annotations:m.of(t.completion)}):n(e,t.completion,r.from,r.to),!0)}const K=R(Q,z);function W(e,t="option"){return n=>{let r=n.state.field(Q,!1);if(!r||!r.open||r.open.disabled||Date.now()-r.open.timestamp<n.state.facet(E).interactionDelay)return!1;let o,a=1;"page"==t&&(o=(0,i.getTooltip)(n,r.open.tooltip))&&(a=Math.max(2,Math.floor(o.dom.offsetHeight/o.dom.querySelector("li").offsetHeight)-1));let{length:s}=r.open.options,l=r.open.selected>-1?r.open.selected+a*(e?1:-1):e?0:s-1;return l<0?l="page"==t?0:s-1:l>=s&&(l="page"==t?s-1:0),n.dispatch({effects:k.of(l)}),!0}}const X=e=>{let t=e.state.field(Q,!1);return!(e.state.readOnly||!t||!t.open||t.open.selected<0||t.open.disabled||Date.now()-t.open.timestamp<e.state.facet(E).interactionDelay)&&z(e,t.open.options[t.open.selected])},Y=e=>{let t=e.state.field(Q,!1);return!!t&&(e.dispatch({effects:y.of(!0)}),!0)},Z=e=>{let t=e.state.field(Q,!1);return!(!t||!t.active.some(e=>0!=e.state))&&(e.dispatch({effects:w.of(null)}),!0)};class J{constructor(e,t){this.active=e,this.context=t,this.time=Date.now(),this.updates=[],this.done=void 0}}const ee=50,te=1e3,ne=i.ViewPlugin.fromClass(class{constructor(e){this.view=e,this.debounceUpdate=-1,this.running=[],this.debounceAccept=-1,this.pendingStart=!1,this.composing=0;for(let t of e.state.field(Q).active)t.isPending&&this.startQuery(t)}update(e){let t=e.state.field(Q),n=e.state.facet(E);if(!e.selectionSet&&!e.docChanged&&e.startState.field(Q)==t)return;let r=e.transactions.some(e=>{let t=j(e,n);return 8&t||(e.selection||e.docChanged)&&!(3&t)});for(let s=0;s<this.running.length;s++){let t=this.running[s];if(r||t.context.abortOnDocChange&&e.docChanged||t.updates.length+e.transactions.length>ee&&Date.now()-t.time>te){for(let e of t.context.abortListeners)try{e()}catch(a){(0,i.logException)(this.view.state,a)}t.context.abortListeners=null,this.running.splice(s--,1)}else t.updates.push(...e.transactions)}this.debounceUpdate>-1&&clearTimeout(this.debounceUpdate),e.transactions.some(e=>e.effects.some(e=>e.is(y)))&&(this.pendingStart=!0);let o=this.pendingStart?50:n.activateOnTypingDelay;if(this.debounceUpdate=t.active.some(e=>e.isPending&&!this.running.some(t=>t.active.source==e.source))?setTimeout(()=>this.startUpdate(),o):-1,0!=this.composing)for(let i of e.transactions)i.isUserEvent("input.type")?this.composing=2:2==this.composing&&i.selection&&(this.composing=3)}startUpdate(){this.debounceUpdate=-1,this.pendingStart=!1;let{state:e}=this.view,t=e.field(Q);for(let n of t.active)n.isPending&&!this.running.some(e=>e.active.source==n.source)&&this.startQuery(n);this.running.length&&t.open&&t.open.disabled&&(this.debounceAccept=setTimeout(()=>this.accept(),this.view.state.facet(E).updateSyncTime))}startQuery(e){let{state:t}=this.view,n=p(t),r=new a(t,n,e.explicit,this.view),o=new J(e,r);this.running.push(o),Promise.resolve(e.source(r)).then(e=>{o.context.aborted||(o.done=e||null,this.scheduleAccept())},e=>{this.view.dispatch({effects:w.of(null)}),(0,i.logException)(this.view.state,e)})}scheduleAccept(){this.running.every(e=>void 0!==e.done)?this.accept():this.debounceAccept<0&&(this.debounceAccept=setTimeout(()=>this.accept(),this.view.state.facet(E).updateSyncTime))}accept(){var e;this.debounceAccept>-1&&clearTimeout(this.debounceAccept),this.debounceAccept=-1;let t=[],n=this.view.state.facet(E),r=this.view.state.field(Q);for(let i=0;i<this.running.length;i++){let o=this.running[i];if(void 0===o.done)continue;if(this.running.splice(i--,1),o.done){let r=p(o.updates.length?o.updates[0].startState:this.view.state),i=Math.min(r,o.done.from+(o.active.explicit?0:1)),a=new G(o.active.source,o.active.explicit,i,o.done,o.done.from,null!==(e=o.done.to)&&void 0!==e?e:r);for(let e of o.updates)a=a.update(e,n);if(a.hasResult()){t.push(a);continue}}let a=r.active.find(e=>e.source==o.active.source);if(a&&a.isPending)if(null==o.done){let e=new U(o.active.source,0);for(let t of o.updates)e=e.update(t,n);e.isPending||t.push(e)}else this.startQuery(a)}(t.length||r.open&&r.open.disabled)&&this.view.dispatch({effects:q.of(t)})}},{eventHandlers:{blur(e){let t=this.view.state.field(Q,!1);if(t&&t.tooltip&&this.view.state.facet(E).closeOnBlur){let n=t.open&&(0,i.getTooltip)(this.view,t.open.tooltip);n&&n.dom.contains(e.relatedTarget)||setTimeout(()=>this.view.dispatch({effects:w.of(null)}),10)}},compositionstart(){this.composing=1},compositionend(){3==this.composing&&setTimeout(()=>this.view.dispatch({effects:y.of(!1)}),20),this.composing=0}}}),re="object"==typeof navigator&&/Win/.test(navigator.platform),ie=r.Prec.highest(i.EditorView.domEventHandlers({keydown(e,t){let n=t.state.field(Q,!1);if(!n||!n.open||n.open.disabled||n.open.selected<0||e.key.length>1||e.ctrlKey&&(!re||!e.altKey)||e.metaKey)return!1;let r=n.open.options[n.open.selected],i=n.active.find(e=>e.source==r.source),o=r.completion.commitCharacters||i.result.commitCharacters;return o&&o.indexOf(e.key)>-1&&z(t,r),!1}})),oe=i.EditorView.baseTheme({".cm-tooltip.cm-tooltip-autocomplete":{"& > ul":{fontFamily:"monospace",whiteSpace:"nowrap",overflow:"hidden auto",maxWidth_fallback:"700px",maxWidth:"min(700px, 95vw)",minWidth:"250px",maxHeight:"10em",height:"100%",listStyle:"none",margin:0,padding:0,"& > li, & > completion-section":{padding:"1px 3px",lineHeight:1.2},"& > li":{overflowX:"hidden",textOverflow:"ellipsis",cursor:"pointer"},"& > completion-section":{display:"list-item",borderBottom:"1px solid silver",paddingLeft:"0.5em",opacity:.7}}},"&light .cm-tooltip-autocomplete ul li[aria-selected]":{background:"#17c",color:"white"},"&light .cm-tooltip-autocomplete-disabled ul li[aria-selected]":{background:"#777"},"&dark .cm-tooltip-autocomplete ul li[aria-selected]":{background:"#347",color:"white"},"&dark .cm-tooltip-autocomplete-disabled ul li[aria-selected]":{background:"#444"},".cm-completionListIncompleteTop:before, .cm-completionListIncompleteBottom:after":{content:'"···"',opacity:.5,display:"block",textAlign:"center",cursor:"pointer"},".cm-tooltip.cm-completionInfo":{position:"absolute",padding:"3px 9px",width:"max-content",maxWidth:"400px",boxSizing:"border-box",whiteSpace:"pre-line"},".cm-completionInfo.cm-completionInfo-left":{right:"100%"},".cm-completionInfo.cm-completionInfo-right":{left:"100%"},".cm-completionInfo.cm-completionInfo-left-narrow":{right:"30px"},".cm-completionInfo.cm-completionInfo-right-narrow":{left:"30px"},"&light .cm-snippetField":{backgroundColor:"#00000022"},"&dark .cm-snippetField":{backgroundColor:"#ffffff22"},".cm-snippetFieldPosition":{verticalAlign:"text-top",width:0,height:"1.15em",display:"inline-block",margin:"0 -0.7px -.7em",borderLeft:"1.4px dotted #888"},".cm-completionMatchedText":{textDecoration:"underline"},".cm-completionDetail":{marginLeft:"0.5em",fontStyle:"italic"},".cm-completionIcon":{fontSize:"90%",width:".8em",display:"inline-block",textAlign:"center",paddingRight:".6em",opacity:"0.6",boxSizing:"content-box"},".cm-completionIcon-function, .cm-completionIcon-method":{"&:after":{content:"'ƒ'"}},".cm-completionIcon-class":{"&:after":{content:"'○'"}},".cm-completionIcon-interface":{"&:after":{content:"'◌'"}},".cm-completionIcon-variable":{"&:after":{content:"'𝑥'"}},".cm-completionIcon-constant":{"&:after":{content:"'𝐶'"}},".cm-completionIcon-type":{"&:after":{content:"'𝑡'"}},".cm-completionIcon-enum":{"&:after":{content:"'∪'"}},".cm-completionIcon-property":{"&:after":{content:"'□'"}},".cm-completionIcon-keyword":{"&:after":{content:"'🔑︎'"}},".cm-completionIcon-namespace":{"&:after":{content:"'▢'"}},".cm-completionIcon-text":{"&:after":{content:"'abc'",fontSize:"50%",verticalAlign:"middle"}}});class ae{constructor(e,t,n,r){this.field=e,this.line=t,this.from=n,this.to=r}}class se{constructor(e,t,n){this.field=e,this.from=t,this.to=n}map(e){let t=e.mapPos(this.from,-1,r.MapMode.TrackDel),n=e.mapPos(this.to,1,r.MapMode.TrackDel);return null==t||null==n?null:new se(this.field,t,n)}}class le{constructor(e,t){this.lines=e,this.fieldPositions=t}instantiate(e,t){let n=[],r=[t],i=e.doc.lineAt(t),a=/^\s*/.exec(i.text)[0];for(let l of this.lines){if(n.length){let n=a,i=/^\t*/.exec(l)[0].length;for(let t=0;t<i;t++)n+=e.facet(o.indentUnit);r.push(t+n.length-i),l=n+l.slice(i)}n.push(l),t+=l.length+1}let s=this.fieldPositions.map(e=>new se(e.field,r[e.line]+e.from,r[e.line]+e.to));return{text:n,ranges:s}}static parse(e){let t,n=[],r=[],i=[];for(let o of e.split(/\r\n?|\n/)){while(t=/[#$]\{(?:(\d+)(?::([^{}]*))?|((?:\\[{}]|[^{}])*))\}/.exec(o)){let e=t[1]?+t[1]:null,a=t[2]||t[3]||"",s=-1;0===e&&(e=1e9);let l=a.replace(/\\[{}]/g,e=>e[1]);for(let t=0;t<n.length;t++)(null!=e?n[t].seq==e:l&&n[t].name==l)&&(s=t);if(s<0){let t=0;while(t<n.length&&(null==e||null!=n[t].seq&&n[t].seq<e))t++;n.splice(t,0,{seq:e,name:l}),s=t;for(let e of i)e.field>=s&&e.field++}for(let n of i)if(n.line==r.length&&n.from>t.index){let e=t[2]?3+(t[1]||"").length:2;n.from-=e,n.to-=e}i.push(new ae(s,r.length,t.index,t.index+l.length)),o=o.slice(0,t.index)+a+o.slice(t.index+t[0].length)}o=o.replace(/\\([{}])/g,(e,t,n)=>{for(let o of i)o.line==r.length&&o.from>n&&(o.from--,o.to--);return t}),r.push(o)}return new le(r,i)}}let ce=i.Decoration.widget({widget:new class extends i.WidgetType{toDOM(){let e=document.createElement("span");return e.className="cm-snippetFieldPosition",e}ignoreEvent(){return!1}}}),ue=i.Decoration.mark({class:"cm-snippetField"});class de{constructor(e,t){this.ranges=e,this.active=t,this.deco=i.Decoration.set(e.map(e=>(e.from==e.to?ce:ue).range(e.from,e.to)),!0)}map(e){let t=[];for(let n of this.ranges){let r=n.map(e);if(!r)return null;t.push(r)}return new de(t,this.active)}selectionInsideField(e){return e.ranges.every(e=>this.ranges.some(t=>t.field==this.active&&t.from<=e.from&&t.to>=e.to))}}const he=r.StateEffect.define({map(e,t){return e&&e.map(t)}}),pe=r.StateEffect.define(),fe=r.StateField.define({create(){return null},update(e,t){for(let n of t.effects){if(n.is(he))return n.value;if(n.is(pe)&&e)return new de(e.ranges,n.value)}return e&&t.docChanged&&(e=e.map(t.changes)),e&&t.selection&&!e.selectionInsideField(t.selection)&&(e=null),e},provide:e=>i.EditorView.decorations.from(e,e=>e?e.deco:i.Decoration.none)});function me(e,t){return r.EditorSelection.create(e.filter(e=>e.field==t).map(e=>r.EditorSelection.range(e.from,e.to)))}function ge(e){let t=le.parse(e);return(e,n,i,o)=>{let{text:a,ranges:s}=t.instantiate(e.state,i),{main:l}=e.state.selection,c={changes:{from:i,to:o==l.from?l.to:o,insert:r.Text.of(a)},scrollIntoView:!0,annotations:n?[m.of(n),r.Transaction.userEvent.of("input.complete")]:void 0};if(s.length&&(c.selection=me(s,0)),s.some(e=>e.field>0)){let t=new de(s,0),n=c.effects=[he.of(t)];void 0===e.state.field(fe,!1)&&n.push(r.StateEffect.appendConfig.of([fe,_e,Ce,oe]))}e.dispatch(e.state.update(c))}}function ve(e){return({state:t,dispatch:n})=>{let r=t.field(fe,!1);if(!r||e<0&&0==r.active)return!1;let i=r.active+e,o=e>0&&!r.ranges.some(t=>t.field==i+e);return n(t.update({selection:me(r.ranges,i),effects:he.of(o?null:new de(r.ranges,i)),scrollIntoView:!0})),!0}}const be=({state:e,dispatch:t})=>{let n=e.field(fe,!1);return!!n&&(t(e.update({effects:he.of(null)})),!0)},ye=ve(1),we=ve(-1);function Oe(e){let t=e.field(fe,!1);return!(!t||!t.ranges.some(e=>e.field==t.active+1))}function Se(e){let t=e.field(fe,!1);return!!(t&&t.active>0)}const Ee=[{key:"Tab",run:ye,shift:we},{key:"Escape",run:be}],xe=r.Facet.define({combine(e){return e.length?e[0]:Ee}}),_e=r.Prec.highest(i.keymap.compute([xe],e=>e.facet(xe)));function ke(e,t){return{...t,apply:ge(e)}}const Ce=i.EditorView.domEventHandlers({mousedown(e,t){let n,r=t.state.field(fe,!1);if(!r||null==(n=t.posAtCoords({x:e.clientX,y:e.clientY})))return!1;let i=r.ranges.find(e=>e.from<=n&&e.to>=n);return!(!i||i.field==r.active)&&(t.dispatch({selection:me(r.ranges,i.field),effects:he.of(r.ranges.some(e=>e.field>i.field)?new de(r.ranges,i.field):null),scrollIntoView:!0}),!0)}});function Ae(e){let t=e.replace(/[\]\-\\]/g,"\\$&");try{return new RegExp(`[\\p{Alphabetic}\\p{Number}_${t}]+`,"ug")}catch(n){return new RegExp(`[w${t}]`,"g")}}function Te(e,t){return new RegExp(t(e.source),e.unicode?"u":"")}const Re=Object.create(null);function Ne(e){return Re[e]||(Re[e]=new WeakMap)}function Pe(e,t,n,r,i){for(let o=e.iterLines(),a=0;!o.next().done;){let e,{value:s}=o;t.lastIndex=0;while(e=t.exec(s))if(!r[e[0]]&&a+e.index!=i&&(n.push({type:"text",label:e[0]}),r[e[0]]=!0,n.length>=2e3))return;a+=s.length+1}}function Ie(e,t,n,r,i){let o=e.length>=1e3,a=o&&t.get(e);if(a)return a;let s=[],l=Object.create(null);if(e.children){let o=0;for(let a of e.children){if(a.length>=1e3)for(let e of Ie(a,t,n,r-o,i-o))l[e.label]||(l[e.label]=!0,s.push(e));else Pe(a,n,s,l,i-o);o+=a.length+1}}else Pe(e,n,s,l,i);return o&&s.length<2e3&&t.set(e,s),s}const Me=e=>{var t;let n=null!==(t=e.state.languageDataAt("wordChars",e.pos)[0])&&void 0!==t?t:"",r=Ae(n),i=e.matchBefore(Te(r,e=>e+"$"));if(!i&&!e.explicit)return null;let o=i?i.from:e.pos,a=Ie(e.state.doc,Ne(n),r,5e4,o);return{from:o,options:a,validFor:Te(r,e=>"^"+e)}},De={brackets:["(","[","{","'",'"'],before:")]}:;>",stringPrefixes:[]},Le=r.StateEffect.define({map(e,t){let n=t.mapPos(e,-1,r.MapMode.TrackAfter);return null==n?void 0:n}}),Be=new class extends r.RangeValue{};Be.startSide=1,Be.endSide=-1;const $e=r.StateField.define({create(){return r.RangeSet.empty},update(e,t){if(e=e.map(t.changes),t.selection){let n=t.state.doc.lineAt(t.selection.main.head);e=e.update({filter:e=>e>=n.from&&e<=n.to})}for(let n of t.effects)n.is(Le)&&(e=e.update({add:[Be.range(n.value,n.value+1)]}));return e}});function Ve(){return[He,$e]}const Fe="()[]{}<>«»»«[]{}";function je(e){for(let t=0;t<Fe.length;t+=2)if(Fe.charCodeAt(t)==e)return Fe.charAt(t+1);return(0,r.fromCodePoint)(e<128?e:e+1)}function Ue(e,t){return e.languageDataAt("closeBrackets",t)[0]||De}const Ge="object"==typeof navigator&&/Android\b/.test(navigator.userAgent),He=i.EditorView.inputHandler.of((e,t,n,i)=>{if((Ge?e.composing:e.compositionStarted)||e.state.readOnly)return!1;let o=e.state.selection.main;if(i.length>2||2==i.length&&1==(0,r.codePointSize)((0,r.codePointAt)(i,0))||t!=o.from||n!=o.to)return!1;let a=ze(e.state,i);return!!a&&(e.dispatch(a),!0)}),qe=({state:e,dispatch:t})=>{if(e.readOnly)return!1;let n=Ue(e,e.selection.main.head),i=n.brackets||De.brackets,o=null,a=e.changeByRange(t=>{if(t.empty){let n=Xe(e.doc,t.head);for(let o of i)if(o==n&&We(e.doc,t.head)==je((0,r.codePointAt)(o,0)))return{changes:{from:t.head-o.length,to:t.head+o.length},range:r.EditorSelection.cursor(t.head-o.length)}}return{range:o=t}});return o||t(e.update(a,{scrollIntoView:!0,userEvent:"delete.backward"})),!o},Qe=[{key:"Backspace",run:qe}];function ze(e,t){let n=Ue(e,e.selection.main.head),i=n.brackets||De.brackets;for(let o of i){let a=je((0,r.codePointAt)(o,0));if(t==o)return a==o?Je(e,o,i.indexOf(o+o+o)>-1,n):Ye(e,o,a,n.before||De.before);if(t==a&&Ke(e,e.selection.main.from))return Ze(e,o,a)}return null}function Ke(e,t){let n=!1;return e.field($e).between(0,e.doc.length,e=>{e==t&&(n=!0)}),n}function We(e,t){let n=e.sliceString(t,t+2);return n.slice(0,(0,r.codePointSize)((0,r.codePointAt)(n,0)))}function Xe(e,t){let n=e.sliceString(t-2,t);return(0,r.codePointSize)((0,r.codePointAt)(n,0))==n.length?n:n.slice(1)}function Ye(e,t,n,i){let o=null,a=e.changeByRange(a=>{if(!a.empty)return{changes:[{insert:t,from:a.from},{insert:n,from:a.to}],effects:Le.of(a.to+t.length),range:r.EditorSelection.range(a.anchor+t.length,a.head+t.length)};let s=We(e.doc,a.head);return!s||/\s/.test(s)||i.indexOf(s)>-1?{changes:{insert:t+n,from:a.head},effects:Le.of(a.head+t.length),range:r.EditorSelection.cursor(a.head+t.length)}:{range:o=a}});return o?null:e.update(a,{scrollIntoView:!0,userEvent:"input.type"})}function Ze(e,t,n){let i=null,o=e.changeByRange(t=>t.empty&&We(e.doc,t.head)==n?{changes:{from:t.head,to:t.head+n.length,insert:n},range:r.EditorSelection.cursor(t.head+n.length)}:i={range:t});return i?null:e.update(o,{scrollIntoView:!0,userEvent:"input.type"})}function Je(e,t,n,i){let o=i.stringPrefixes||De.stringPrefixes,a=null,s=e.changeByRange(i=>{if(!i.empty)return{changes:[{insert:t,from:i.from},{insert:t,from:i.to}],effects:Le.of(i.to+t.length),range:r.EditorSelection.range(i.anchor+t.length,i.head+t.length)};let s,l=i.head,c=We(e.doc,l);if(c==t){if(et(e,l))return{changes:{insert:t+t,from:l},effects:Le.of(l+t.length),range:r.EditorSelection.cursor(l+t.length)};if(Ke(e,l)){let i=n&&e.sliceDoc(l,l+3*t.length)==t+t+t,o=i?t+t+t:t;return{changes:{from:l,to:l+o.length,insert:o},range:r.EditorSelection.cursor(l+o.length)}}}else{if(n&&e.sliceDoc(l-2*t.length,l)==t+t&&(s=nt(e,l-2*t.length,o))>-1&&et(e,s))return{changes:{insert:t+t+t+t,from:l},effects:Le.of(l+t.length),range:r.EditorSelection.cursor(l+t.length)};if(e.charCategorizer(l)(c)!=r.CharCategory.Word&&nt(e,l,o)>-1&&!tt(e,l,t,o))return{changes:{insert:t+t,from:l},effects:Le.of(l+t.length),range:r.EditorSelection.cursor(l+t.length)}}return{range:a=i}});return a?null:e.update(s,{scrollIntoView:!0,userEvent:"input.type"})}function et(e,t){let n=(0,o.syntaxTree)(e).resolveInner(t+1);return n.parent&&n.from==t}function tt(e,t,n,r){let i=(0,o.syntaxTree)(e).resolveInner(t,-1),a=r.reduce((e,t)=>Math.max(e,t.length),0);for(let o=0;o<5;o++){let o=e.sliceDoc(i.from,Math.min(i.to,i.from+n.length+a)),s=o.indexOf(n);if(!s||s>-1&&r.indexOf(o.slice(0,s))>-1){let t=i.firstChild;while(t&&t.from==i.from&&t.to-t.from>n.length+s){if(e.sliceDoc(t.to-n.length,t.to)==n)return!1;t=t.firstChild}return!0}let l=i.to==t&&i.parent;if(!l)break;i=l}return!1}function nt(e,t,n){let i=e.charCategorizer(t);if(i(e.sliceDoc(t-1,t))!=r.CharCategory.Word)return t;for(let o of n){let n=t-o.length;if(e.sliceDoc(n,t)==o&&i(e.sliceDoc(n-1,n))!=r.CharCategory.Word)return n}return-1}function rt(e={}){return[ie,Q,E.of(e),ne,ot,oe]}const it=[{key:"Ctrl-Space",run:Y},{mac:"Alt-`",run:Y},{mac:"Alt-i",run:Y},{key:"Escape",run:Z},{key:"ArrowDown",run:W(!0)},{key:"ArrowUp",run:W(!1)},{key:"PageDown",run:W(!0,"page")},{key:"PageUp",run:W(!1,"page")},{key:"Enter",run:X}],ot=r.Prec.highest(i.keymap.computeN([E],e=>e.facet(E).defaultKeymap?[it]:[]));function at(e){let t=e.field(Q,!1);return t&&t.active.some(e=>e.isPending)?"pending":t&&t.active.some(e=>0!=e.state)?"active":null}const st=new WeakMap;function lt(e){var t;let n=null===(t=e.field(Q,!1))||void 0===t?void 0:t.open;if(!n||n.disabled)return[];let r=st.get(n.options);return r||st.set(n.options,r=n.options.map(e=>e.completion)),r}function ct(e){var t;let n=null===(t=e.field(Q,!1))||void 0===t?void 0:t.open;return n&&!n.disabled&&n.selected>=0?n.options[n.selected].completion:null}function ut(e){var t;let n=null===(t=e.field(Q,!1))||void 0===t?void 0:t.open;return n&&!n.disabled&&n.selected>=0?n.selected:null}function dt(e){return k.of(e)}},6871:function(e,t,n){"use strict";n.r(t),n.d(t,{DocInput:function(){return O},HighlightStyle:function(){return Me},IndentContext:function(){return $},LRLanguage:function(){return m},Language:function(){return p},LanguageDescription:function(){return N},LanguageSupport:function(){return R},ParseContext:function(){return E},StreamLanguage:function(){return dt},StringStream:function(){return st},TreeIndentContext:function(){return q},bidiIsolates:function(){return Pt},bracketMatching:function(){return Je},bracketMatchingHandle:function(){return et},codeFolding:function(){return ke},continuedIndent:function(){return Y},defaultHighlightStyle:function(){return Ue},defineLanguageFacet:function(){return d},delimitedIndent:function(){return K},ensureSyntaxTree:function(){return v},flatIndent:function(){return X},foldAll:function(){return ye},foldCode:function(){return ge},foldEffect:function(){return se},foldGutter:function(){return Pe},foldInside:function(){return ne},foldKeymap:function(){return Ee},foldNodeProp:function(){return te},foldService:function(){return ee},foldState:function(){return ue},foldable:function(){return oe},foldedRanges:function(){return he},forceParsing:function(){return y},getIndentUnit:function(){return M},getIndentation:function(){return L},highlightingFor:function(){return Ve},indentNodeProp:function(){return V},indentOnInput:function(){return J},indentRange:function(){return B},indentService:function(){return P},indentString:function(){return D},indentUnit:function(){return I},language:function(){return T},languageDataProp:function(){return u},matchBrackets:function(){return rt},sublanguageProp:function(){return h},syntaxHighlighting:function(){return $e},syntaxParserRunning:function(){return w},syntaxTree:function(){return g},syntaxTreeAvailable:function(){return b},toggleFold:function(){return Se},unfoldAll:function(){return we},unfoldCode:function(){return ve},unfoldEffect:function(){return le}});var r,i=n(43114),o=n(76528),a=n(81068),s=n(88727),l=n(98104),c=n(4364);const u=new i.NodeProp;function d(e){return o.Facet.define({combine:e?t=>t.concat(e):void 0})}const h=new i.NodeProp;class p{constructor(e,t,n=[],r=""){this.data=e,this.name=r,o.EditorState.prototype.hasOwnProperty("tree")||Object.defineProperty(o.EditorState.prototype,"tree",{get(){return g(this)}}),this.parser=t,this.extension=[T.of(this),o.EditorState.languageData.of((e,t,n)=>{let r=f(e,t,n),i=r.type.prop(u);if(!i)return[];let o=e.facet(i),a=r.type.prop(h);if(a){let i=r.resolve(t-r.from,n);for(let t of a)if(t.test(i,e)){let n=e.facet(t.facet);return"replace"==t.type?n:n.concat(o)}}return o})].concat(n)}isActiveAt(e,t,n=-1){return f(e,t,n).type.prop(u)==this.data}findRegions(e){let t=e.facet(T);if((null===t||void 0===t?void 0:t.data)==this.data)return[{from:0,to:e.doc.length}];if(!t||!t.allowsNesting)return[];let n=[],r=(e,t)=>{if(e.prop(u)==this.data)return void n.push({from:t,to:t+e.length});let o=e.prop(i.NodeProp.mounted);if(o){if(o.tree.prop(u)==this.data){if(o.overlay)for(let e of o.overlay)n.push({from:e.from+t,to:e.to+t});else n.push({from:t,to:t+e.length});return}if(o.overlay){let e=n.length;if(r(o.tree,o.overlay[0].from+t),n.length>e)return}}for(let n=0;n<e.children.length;n++){let o=e.children[n];o instanceof i.Tree&&r(o,e.positions[n]+t)}};return r(g(e),0),n}get allowsNesting(){return!0}}function f(e,t,n){let r=e.facet(T),o=g(e).topNode;if(!r||r.allowsNesting)for(let a=o;a;a=a.enter(t,n,i.IterMode.ExcludeBuffers|i.IterMode.EnterBracketed))a.type.isTop&&(o=a);return o}p.setState=o.StateEffect.define();class m extends p{constructor(e,t,n){super(e,t,[],n),this.parser=t}static define(e){let t=d(e.languageData);return new m(t,e.parser.configure({props:[u.add(e=>e.isTop?t:void 0)]}),e.name)}configure(e,t){return new m(this.data,this.parser.configure(e),t||this.name)}get allowsNesting(){return this.parser.hasWrappers()}}function g(e){let t=e.field(p.state,!1);return t?t.tree:i.Tree.empty}function v(e,t,n=50){var r;let i=null===(r=e.field(p.state,!1))||void 0===r?void 0:r.context;if(!i)return null;let o=i.viewport;i.updateViewport({from:0,to:t});let a=i.isDone(t)||i.work(n,t)?i.tree:null;return i.updateViewport(o),a}function b(e,t=e.doc.length){var n;return(null===(n=e.field(p.state,!1))||void 0===n?void 0:n.context.isDone(t))||!1}function y(e,t=e.viewport.to,n=100){let r=v(e.state,t,n);return r!=g(e.state)&&e.dispatch({}),!!r}function w(e){var t;return(null===(t=e.plugin(A))||void 0===t?void 0:t.isWorking())||!1}class O{constructor(e){this.doc=e,this.cursorPos=0,this.string="",this.cursor=e.iter()}get length(){return this.doc.length}syncTo(e){return this.string=this.cursor.next(e-this.cursorPos).value,this.cursorPos=e+this.string.length,this.cursorPos-this.string.length}chunk(e){return this.syncTo(e),this.string}get lineChunks(){return!0}read(e,t){let n=this.cursorPos-this.string.length;return e<n||t>=this.cursorPos?this.doc.sliceString(e,t):this.string.slice(e-n,t-n)}}let S=null;class E{constructor(e,t,n=[],r,i,o,a,s){this.parser=e,this.state=t,this.fragments=n,this.tree=r,this.treeLen=i,this.viewport=o,this.skipped=a,this.scheduleOn=s,this.parse=null,this.tempSkipped=[]}static create(e,t,n){return new E(e,t,[],i.Tree.empty,0,n,[],null)}startParse(){return this.parser.startParse(new O(this.state.doc),this.fragments)}work(e,t){return null!=t&&t>=this.state.doc.length&&(t=void 0),this.tree!=i.Tree.empty&&this.isDone(null!==t&&void 0!==t?t:this.state.doc.length)?(this.takeTree(),!0):this.withContext(()=>{var n;if("number"==typeof e){let t=Date.now()+e;e=()=>Date.now()>t}for(this.parse||(this.parse=this.startParse()),null!=t&&(null==this.parse.stoppedAt||this.parse.stoppedAt>t)&&t<this.state.doc.length&&this.parse.stopAt(t);;){let r=this.parse.advance();if(r){if(this.fragments=this.withoutTempSkipped(i.TreeFragment.addTree(r,this.fragments,null!=this.parse.stoppedAt)),this.treeLen=null!==(n=this.parse.stoppedAt)&&void 0!==n?n:this.state.doc.length,this.tree=r,this.parse=null,!(this.treeLen<(null!==t&&void 0!==t?t:this.state.doc.length)))return!0;this.parse=this.startParse()}if(e())return!1}})}takeTree(){let e,t;this.parse&&(e=this.parse.parsedPos)>=this.treeLen&&((null==this.parse.stoppedAt||this.parse.stoppedAt>e)&&this.parse.stopAt(e),this.withContext(()=>{while(!(t=this.parse.advance()));}),this.treeLen=e,this.tree=t,this.fragments=this.withoutTempSkipped(i.TreeFragment.addTree(this.tree,this.fragments,!0)),this.parse=null)}withContext(e){let t=S;S=this;try{return e()}finally{S=t}}withoutTempSkipped(e){for(let t;t=this.tempSkipped.pop();)e=x(e,t.from,t.to);return e}changes(e,t){let{fragments:n,tree:r,treeLen:o,viewport:a,skipped:s}=this;if(this.takeTree(),!e.empty){let t=[];if(e.iterChangedRanges((e,n,r,i)=>t.push({fromA:e,toA:n,fromB:r,toB:i})),n=i.TreeFragment.applyChanges(n,t),r=i.Tree.empty,o=0,a={from:e.mapPos(a.from,-1),to:e.mapPos(a.to,1)},this.skipped.length){s=[];for(let t of this.skipped){let n=e.mapPos(t.from,1),r=e.mapPos(t.to,-1);n<r&&s.push({from:n,to:r})}}}return new E(this.parser,t,n,r,o,a,s,this.scheduleOn)}updateViewport(e){if(this.viewport.from==e.from&&this.viewport.to==e.to)return!1;this.viewport=e;let t=this.skipped.length;for(let n=0;n<this.skipped.length;n++){let{from:t,to:r}=this.skipped[n];t<e.to&&r>e.from&&(this.fragments=x(this.fragments,t,r),this.skipped.splice(n--,1))}return!(this.skipped.length>=t)&&(this.reset(),!0)}reset(){this.parse&&(this.takeTree(),this.parse=null)}skipUntilInView(e,t){this.skipped.push({from:e,to:t})}static getSkippingParser(e){return new class extends i.Parser{createParse(t,n,r){let o=r[0].from,a=r[r.length-1].to,s={parsedPos:o,advance(){let t=S;if(t){for(let e of r)t.tempSkipped.push(e);e&&(t.scheduleOn=t.scheduleOn?Promise.all([t.scheduleOn,e]):e)}return this.parsedPos=a,new i.Tree(i.NodeType.none,[],[],a-o)},stoppedAt:null,stopAt(){}};return s}}}isDone(e){e=Math.min(e,this.state.doc.length);let t=this.fragments;return this.treeLen>=e&&t.length&&0==t[0].from&&t[0].to>=e}static get(){return S}}function x(e,t,n){return i.TreeFragment.applyChanges(e,[{fromA:t,toA:n,fromB:t,toB:n}])}class _{constructor(e){this.context=e,this.tree=e.tree}apply(e){if(!e.docChanged&&this.tree==this.context.tree)return this;let t=this.context.changes(e.changes,e.state),n=this.context.treeLen==e.startState.doc.length?void 0:Math.max(e.changes.mapPos(this.context.treeLen),t.viewport.to);return t.work(20,n)||t.takeTree(),new _(t)}static init(e){let t=Math.min(3e3,e.doc.length),n=E.create(e.facet(T).parser,e,{from:0,to:t});return n.work(20,t)||n.takeTree(),new _(n)}}p.state=o.StateField.define({create:_.init,update(e,t){for(let n of t.effects)if(n.is(p.setState))return n.value;return t.startState.facet(T)!=t.state.facet(T)?_.init(t.state):e.apply(t)}});let k=e=>{let t=setTimeout(()=>e(),500);return()=>clearTimeout(t)};"undefined"!=typeof requestIdleCallback&&(k=e=>{let t=-1,n=setTimeout(()=>{t=requestIdleCallback(e,{timeout:400})},100);return()=>t<0?clearTimeout(n):cancelIdleCallback(t)});const C="undefined"!=typeof navigator&&(null===(r=navigator.scheduling)||void 0===r?void 0:r.isInputPending)?()=>navigator.scheduling.isInputPending():null,A=a.ViewPlugin.fromClass(class{constructor(e){this.view=e,this.working=null,this.workScheduled=0,this.chunkEnd=-1,this.chunkBudget=-1,this.work=this.work.bind(this),this.scheduleWork()}update(e){let t=this.view.state.field(p.state).context;(t.updateViewport(e.view.viewport)||this.view.viewport.to>t.treeLen)&&this.scheduleWork(),(e.docChanged||e.selectionSet)&&(this.view.hasFocus&&(this.chunkBudget+=50),this.scheduleWork()),this.checkAsyncSchedule(t)}scheduleWork(){if(this.working)return;let{state:e}=this.view,t=e.field(p.state);t.tree==t.context.tree&&t.context.isDone(e.doc.length)||(this.working=k(this.work))}work(e){this.working=null;let t=Date.now();if(this.chunkEnd<t&&(this.chunkEnd<0||this.view.hasFocus)&&(this.chunkEnd=t+3e4,this.chunkBudget=3e3),this.chunkBudget<=0)return;let{state:n,viewport:{to:r}}=this.view,i=n.field(p.state);if(i.tree==i.context.tree&&i.context.isDone(r+1e5))return;let o=Date.now()+Math.min(this.chunkBudget,100,e&&!C?Math.max(25,e.timeRemaining()-5):1e9),a=i.context.treeLen<r&&n.doc.length>r+1e3,s=i.context.work(()=>C&&C()||Date.now()>o,r+(a?0:1e5));this.chunkBudget-=Date.now()-t,(s||this.chunkBudget<=0)&&(i.context.takeTree(),this.view.dispatch({effects:p.setState.of(new _(i.context))})),this.chunkBudget>0&&(!s||a)&&this.scheduleWork(),this.checkAsyncSchedule(i.context)}checkAsyncSchedule(e){e.scheduleOn&&(this.workScheduled++,e.scheduleOn.then(()=>this.scheduleWork()).catch(e=>(0,a.logException)(this.view.state,e)).then(()=>this.workScheduled--),e.scheduleOn=null)}destroy(){this.working&&this.working()}isWorking(){return!!(this.working||this.workScheduled>0)}},{eventHandlers:{focus(){this.scheduleWork()}}}),T=o.Facet.define({combine(e){return e.length?e[0]:null},enables:e=>[p.state,A,a.EditorView.contentAttributes.compute([e],t=>{let n=t.facet(e);return n&&n.name?{"data-language":n.name}:{}})]});class R{constructor(e,t=[]){this.language=e,this.support=t,this.extension=[e,t]}}class N{constructor(e,t,n,r,i,o=void 0){this.name=e,this.alias=t,this.extensions=n,this.filename=r,this.loadFunc=i,this.support=o,this.loading=null}load(){return this.loading||(this.loading=this.loadFunc().then(e=>this.support=e,e=>{throw this.loading=null,e}))}static of(e){let{load:t,support:n}=e;if(!t){if(!n)throw new RangeError("Must pass either 'load' or 'support' to LanguageDescription.of");t=()=>Promise.resolve(n)}return new N(e.name,(e.alias||[]).concat(e.name).map(e=>e.toLowerCase()),e.extensions||[],e.filename,t,n)}static matchFilename(e,t){for(let r of e)if(r.filename&&r.filename.test(t))return r;let n=/\.([^.]+)$/.exec(t);if(n)for(let r of e)if(r.extensions.indexOf(n[1])>-1)return r;return null}static matchLanguageName(e,t,n=!0){t=t.toLowerCase();for(let r of e)if(r.alias.some(e=>e==t))return r;if(n)for(let r of e)for(let e of r.alias){let n=t.indexOf(e);if(n>-1&&(e.length>2||!/\w/.test(t[n-1])&&!/\w/.test(t[n+e.length])))return r}return null}}const P=o.Facet.define(),I=o.Facet.define({combine:e=>{if(!e.length)return" ";let t=e[0];if(!t||/\S/.test(t)||Array.from(t).some(e=>e!=t[0]))throw new Error("Invalid indent unit: "+JSON.stringify(e[0]));return t}});function M(e){let t=e.facet(I);return 9==t.charCodeAt(0)?e.tabSize*t.length:t.length}function D(e,t){let n="",r=e.tabSize,i=e.facet(I)[0];if("\t"==i){while(t>=r)n+="\t",t-=r;i=" "}for(let o=0;o<t;o++)n+=i;return n}function L(e,t){e instanceof o.EditorState&&(e=new $(e));for(let r of e.state.facet(P)){let n=r(e,t);if(void 0!==n)return n}let n=g(e.state);return n.length>=t?F(e,n,t):null}function B(e,t,n){let r=Object.create(null),i=new $(e,{overrideIndentation:e=>{var t;return null!==(t=r[e])&&void 0!==t?t:-1}}),o=[];for(let a=t;a<=n;){let t=e.doc.lineAt(a);a=t.to+1;let n=L(i,t.from);if(null==n)continue;/\S/.test(t.text)||(n=0);let s=/^\s*/.exec(t.text)[0],l=D(e,n);s!=l&&(r[t.from]=n,o.push({from:t.from,to:t.from+s.length,insert:l}))}return e.changes(o)}class ${constructor(e,t={}){this.state=e,this.options=t,this.unit=M(e)}lineAt(e,t=1){let n=this.state.doc.lineAt(e),{simulateBreak:r,simulateDoubleBreak:i}=this.options;return null!=r&&r>=n.from&&r<=n.to?i&&r==e?{text:"",from:e}:(t<0?r<e:r<=e)?{text:n.text.slice(r-n.from),from:r}:{text:n.text.slice(0,r-n.from),from:n.from}:n}textAfterPos(e,t=1){if(this.options.simulateDoubleBreak&&e==this.options.simulateBreak)return"";let{text:n,from:r}=this.lineAt(e,t);return n.slice(e-r,Math.min(n.length,e+100-r))}column(e,t=1){let{text:n,from:r}=this.lineAt(e,t),i=this.countColumn(n,e-r),o=this.options.overrideIndentation?this.options.overrideIndentation(r):-1;return o>-1&&(i+=o-this.countColumn(n,n.search(/\S|$/))),i}countColumn(e,t=e.length){return(0,o.countColumn)(e,this.state.tabSize,t)}lineIndent(e,t=1){let{text:n,from:r}=this.lineAt(e,t),i=this.options.overrideIndentation;if(i){let e=i(r);if(e>-1)return e}return this.countColumn(n,n.search(/\S|$/))}get simulatedBreak(){return this.options.simulateBreak||null}}const V=new i.NodeProp;function F(e,t,n){let r=t.resolveStack(n),i=t.resolveInner(n,-1).resolve(n,0).enterUnfinishedNodesBefore(n);if(i!=r.node){let e=[];for(let t=i;t&&!(t.from<r.node.from||t.to>r.node.to||t.from==r.node.from&&t.type==r.node.type);t=t.parent)e.push(t);for(let t=e.length-1;t>=0;t--)r={node:e[t],next:r}}return j(r,e,n)}function j(e,t,n){for(let r=e;r;r=r.next){let e=G(r.node);if(e)return e(q.create(t,n,r))}return 0}function U(e){return e.pos==e.options.simulateBreak&&e.options.simulateDoubleBreak}function G(e){let t=e.type.prop(V);if(t)return t;let n,r=e.firstChild;if(r&&(n=r.type.prop(i.NodeProp.closedBy))){let t=e.lastChild,r=t&&n.indexOf(t.name)>-1;return e=>W(e,!0,1,void 0,r&&!U(e)?t.from:void 0)}return null==e.parent?H:null}function H(){return 0}class q extends ${constructor(e,t,n){super(e.state,e.options),this.base=e,this.pos=t,this.context=n}get node(){return this.context.node}static create(e,t,n){return new q(e,t,n)}get textAfter(){return this.textAfterPos(this.pos)}get baseIndent(){return this.baseIndentFor(this.node)}baseIndentFor(e){let t=this.state.doc.lineAt(e.from);for(;;){let n=e.resolve(t.from);while(n.parent&&n.parent.from==n.from)n=n.parent;if(Q(n,e))break;t=this.state.doc.lineAt(n.from)}return this.lineIndent(t.from)}continue(){return j(this.context.next,this.base,this.pos)}}function Q(e,t){for(let n=t;n;n=n.parent)if(e==n)return!0;return!1}function z(e){let t=e.node,n=t.childAfter(t.from),r=t.lastChild;if(!n)return null;let i=e.options.simulateBreak,o=e.state.doc.lineAt(n.from),a=null==i||i<=o.from?o.to:Math.min(o.to,i);for(let s=n.to;;){let e=t.childAfter(s);if(!e||e==r)return null;if(!e.type.isSkipped){if(e.from>=a)return null;let t=/^ */.exec(o.text.slice(n.to-o.from))[0].length;return{from:n.from,to:n.to+t}}s=e.to}}function K({closing:e,align:t=!0,units:n=1}){return r=>W(r,t,n,e)}function W(e,t,n,r,i){let o=e.textAfter,a=o.match(/^\s*/)[0].length,s=r&&o.slice(a,a+r.length)==r||i==e.pos+a,l=t?z(e):null;return l?s?e.column(l.from):e.column(l.to):e.baseIndent+(s?0:e.unit*n)}const X=e=>e.baseIndent;function Y({except:e,units:t=1}={}){return n=>{let r=e&&e.test(n.textAfter);return n.baseIndent+(r?0:t*n.unit)}}const Z=200;function J(){return o.EditorState.transactionFilter.of(e=>{if(!e.docChanged||!e.isUserEvent("input.type")&&!e.isUserEvent("input.complete"))return e;let t=e.startState.languageDataAt("indentOnInput",e.startState.selection.main.head);if(!t.length)return e;let n=e.newDoc,{head:r}=e.newSelection.main,i=n.lineAt(r);if(r>i.from+Z)return e;let o=n.sliceString(i.from,r);if(!t.some(e=>e.test(o)))return e;let{state:a}=e,s=-1,l=[];for(let{head:c}of a.selection.ranges){let e=a.doc.lineAt(c);if(e.from==s)continue;s=e.from;let t=L(a,e.from);if(null==t)continue;let n=/^\s*/.exec(e.text)[0],r=D(a,t);n!=r&&l.push({from:e.from,to:e.from+n.length,insert:r})}return l.length?[e,{changes:l,sequential:!0}]:e})}const ee=o.Facet.define(),te=new i.NodeProp;function ne(e){let t=e.firstChild,n=e.lastChild;return t&&t.to<n.from?{from:t.to,to:n.type.isError?e.to:n.from}:null}function re(e,t,n){let r=g(e);if(r.length<n)return null;let i=r.resolveStack(n,1),o=null;for(let a=i;a;a=a.next){let i=a.node;if(i.to<=n||i.from>n)continue;if(o&&i.from<t)break;let s=i.type.prop(te);if(s&&(i.to<r.length-50||r.length==e.doc.length||!ie(i))){let r=s(i,e);r&&r.from<=n&&r.from>=t&&r.to>n&&(o=r)}}return o}function ie(e){let t=e.lastChild;return t&&t.to==e.to&&t.type.isError}function oe(e,t,n){for(let r of e.facet(ee)){let i=r(e,t,n);if(i)return i}return re(e,t,n)}function ae(e,t){let n=t.mapPos(e.from,1),r=t.mapPos(e.to,-1);return n>=r?void 0:{from:n,to:r}}const se=o.StateEffect.define({map:ae}),le=o.StateEffect.define({map:ae});function ce(e){let t=[];for(let{head:n}of e.state.selection.ranges)t.some(e=>e.from<=n&&e.to>=n)||t.push(e.lineBlockAt(n));return t}const ue=o.StateField.define({create(){return a.Decoration.none},update(e,t){t.isUserEvent("delete")&&t.changes.iterChangedRanges((t,n)=>e=de(e,t,n)),e=e.map(t.changes);let n=[];for(let r of t.effects)r.is(se)&&!fe(e,r.value.from,r.value.to)?n.push(r.value):r.is(le)&&(e=e.update({filter:(e,t)=>r.value.from!=e||r.value.to!=t,filterFrom:r.value.from,filterTo:r.value.to}));if(n.length){let{preparePlaceholder:r}=t.state.facet(_e),i=n.map(e=>{let n=r?a.Decoration.replace({widget:new Te(r(t.state,e))}):Ae;return n.range(e.from,e.to)});e=e.update({add:i})}return t.selection&&(e=de(e,t.selection.main.head)),e},provide:e=>a.EditorView.decorations.from(e),toJSON(e,t){let n=[];return e.between(0,t.doc.length,(e,t)=>{n.push(e,t)}),n},fromJSON(e){if(!Array.isArray(e)||e.length%2)throw new RangeError("Invalid JSON for fold state");let t=[];for(let n=0;n<e.length;){let r=e[n++],i=e[n++];if("number"!=typeof r||"number"!=typeof i)throw new RangeError("Invalid JSON for fold state");t.push(Ae.range(r,i))}return a.Decoration.set(t,!0)}});function de(e,t,n=t){let r=!1;return e.between(t,n,(e,i)=>{e<n&&i>t&&(r=!0)}),r?e.update({filterFrom:t,filterTo:n,filter:(e,r)=>e>=n||r<=t}):e}function he(e){return e.field(ue,!1)||o.RangeSet.empty}function pe(e,t,n){var r;let i=null;return null===(r=e.field(ue,!1))||void 0===r||r.between(t,n,(e,t)=>{(!i||i.from>e)&&(i={from:e,to:t})}),i}function fe(e,t,n){let r=!1;return e.between(t,t,(e,i)=>{e==t&&i==n&&(r=!0)}),r}function me(e,t){return e.field(ue,!1)?t:t.concat(o.StateEffect.appendConfig.of(ke()))}const ge=e=>{for(let t of ce(e)){let n=oe(e.state,t.from,t.to);if(n)return e.dispatch({effects:me(e.state,[se.of(n),be(e,n)])}),!0}return!1},ve=e=>{if(!e.state.field(ue,!1))return!1;let t=[];for(let n of ce(e)){let r=pe(e.state,n.from,n.to);r&&t.push(le.of(r),be(e,r,!1))}return t.length&&e.dispatch({effects:t}),t.length>0};function be(e,t,n=!0){let r=e.state.doc.lineAt(t.from).number,i=e.state.doc.lineAt(t.to).number;return a.EditorView.announce.of(`${e.state.phrase(n?"Folded lines":"Unfolded lines")} ${r} ${e.state.phrase("to")} ${i}.`)}const ye=e=>{let{state:t}=e,n=[];for(let r=0;r<t.doc.length;){let i=e.lineBlockAt(r),o=oe(t,i.from,i.to);o&&n.push(se.of(o)),r=(o?e.lineBlockAt(o.to):i).to+1}return n.length&&e.dispatch({effects:me(e.state,n)}),!!n.length},we=e=>{let t=e.state.field(ue,!1);if(!t||!t.size)return!1;let n=[];return t.between(0,e.state.doc.length,(e,t)=>{n.push(le.of({from:e,to:t}))}),e.dispatch({effects:n}),!0};function Oe(e,t){for(let n=t;;){let r=oe(e.state,n.from,n.to);if(r&&r.to>t.from)return r;if(!n.from)return null;n=e.lineBlockAt(n.from-1)}}const Se=e=>{let t=[];for(let n of ce(e)){let r=pe(e.state,n.from,n.to);if(r)t.push(le.of(r),be(e,r,!1));else{let r=Oe(e,n);r&&t.push(se.of(r),be(e,r))}}return t.length>0&&e.dispatch({effects:me(e.state,t)}),!!t.length},Ee=[{key:"Ctrl-Shift-[",mac:"Cmd-Alt-[",run:ge},{key:"Ctrl-Shift-]",mac:"Cmd-Alt-]",run:ve},{key:"Ctrl-Alt-[",run:ye},{key:"Ctrl-Alt-]",run:we}],xe={placeholderDOM:null,preparePlaceholder:null,placeholderText:"…"},_e=o.Facet.define({combine(e){return(0,o.combineConfig)(e,xe)}});function ke(e){let t=[ue,Ie];return e&&t.push(_e.of(e)),t}function Ce(e,t){let{state:n}=e,r=n.facet(_e),i=t=>{let n=e.lineBlockAt(e.posAtDOM(t.target)),r=pe(e.state,n.from,n.to);r&&e.dispatch({effects:le.of(r)}),t.preventDefault()};if(r.placeholderDOM)return r.placeholderDOM(e,i,t);let o=document.createElement("span");return o.textContent=r.placeholderText,o.setAttribute("aria-label",n.phrase("folded code")),o.title=n.phrase("unfold"),o.className="cm-foldPlaceholder",o.onclick=i,o}const Ae=a.Decoration.replace({widget:new class extends a.WidgetType{toDOM(e){return Ce(e,null)}}});class Te extends a.WidgetType{constructor(e){super(),this.value=e}eq(e){return this.value==e.value}toDOM(e){return Ce(e,this.value)}}const Re={openText:"⌄",closedText:"›",markerDOM:null,domEventHandlers:{},foldingChanged:()=>!1};class Ne extends a.GutterMarker{constructor(e,t){super(),this.config=e,this.open=t}eq(e){return this.config==e.config&&this.open==e.open}toDOM(e){if(this.config.markerDOM)return this.config.markerDOM(this.open);let t=document.createElement("span");return t.textContent=this.open?this.config.openText:this.config.closedText,t.title=e.state.phrase(this.open?"Fold line":"Unfold line"),t}}function Pe(e={}){let t={...Re,...e},n=new Ne(t,!0),r=new Ne(t,!1),i=a.ViewPlugin.fromClass(class{constructor(e){this.from=e.viewport.from,this.markers=this.buildMarkers(e)}update(e){(e.docChanged||e.viewportChanged||e.startState.facet(T)!=e.state.facet(T)||e.startState.field(ue,!1)!=e.state.field(ue,!1)||g(e.startState)!=g(e.state)||t.foldingChanged(e))&&(this.markers=this.buildMarkers(e.view))}buildMarkers(e){let t=new o.RangeSetBuilder;for(let i of e.viewportLineBlocks){let o=pe(e.state,i.from,i.to)?r:oe(e.state,i.from,i.to)?n:null;o&&t.add(i.from,i.from,o)}return t.finish()}}),{domEventHandlers:s}=t;return[i,(0,a.gutter)({class:"cm-foldGutter",markers(e){var t;return(null===(t=e.plugin(i))||void 0===t?void 0:t.markers)||o.RangeSet.empty},initialSpacer(){return new Ne(t,!1)},domEventHandlers:{...s,click:(e,t,n)=>{if(s.click&&s.click(e,t,n))return!0;let r=pe(e.state,t.from,t.to);if(r)return e.dispatch({effects:le.of(r)}),!0;let i=oe(e.state,t.from,t.to);return!!i&&(e.dispatch({effects:se.of(i)}),!0)}}}),ke()]}const Ie=a.EditorView.baseTheme({".cm-foldPlaceholder":{backgroundColor:"#eee",border:"1px solid #ddd",color:"#888",borderRadius:".2em",margin:"0 1px",padding:"0 1px",cursor:"pointer"},".cm-foldGutter span":{padding:"0 1px",cursor:"pointer"}});class Me{constructor(e,t){let n;function r(e){let t=l.G.newName();return(n||(n=Object.create(null)))["."+t]=e,t}this.specs=e;const i="string"==typeof t.all?t.all:t.all?r(t.all):void 0,o=t.scope;this.scope=o instanceof p?e=>e.prop(u)==o.data:o?e=>e==o:void 0,this.style=(0,s.tagHighlighter)(e.map(e=>({tag:e.tag,class:e.class||r(Object.assign({},e,{tag:null}))})),{all:i}).style,this.module=n?new l.G(n):null,this.themeType=t.themeType}static define(e,t){return new Me(e,t||{})}}const De=o.Facet.define(),Le=o.Facet.define({combine(e){return e.length?[e[0]]:null}});function Be(e){let t=e.facet(De);return t.length?t:e.facet(Le)}function $e(e,t){let n,r=[je];return e instanceof Me&&(e.module&&r.push(a.EditorView.styleModule.of(e.module)),n=e.themeType),(null===t||void 0===t?void 0:t.fallback)?r.push(Le.of(e)):n?r.push(De.computeN([a.EditorView.darkTheme],t=>t.facet(a.EditorView.darkTheme)==("dark"==n)?[e]:[])):r.push(De.of(e)),r}function Ve(e,t,n){let r=Be(e),i=null;if(r)for(let o of r)if(!o.scope||n&&o.scope(n)){let e=o.style(t);e&&(i=i?i+" "+e:e)}return i}class Fe{constructor(e){this.markCache=Object.create(null),this.tree=g(e.state),this.decorations=this.buildDeco(e,Be(e.state)),this.decoratedTo=e.viewport.to}update(e){let t=g(e.state),n=Be(e.state),r=n!=Be(e.startState),{viewport:i}=e.view,o=e.changes.mapPos(this.decoratedTo,1);t.length<i.to&&!r&&t.type==this.tree.type&&o>=i.to?(this.decorations=this.decorations.map(e.changes),this.decoratedTo=o):(t!=this.tree||e.viewportChanged||r)&&(this.tree=t,this.decorations=this.buildDeco(e.view,n),this.decoratedTo=i.to)}buildDeco(e,t){if(!t||!this.tree.length)return a.Decoration.none;let n=new o.RangeSetBuilder;for(let{from:r,to:i}of e.visibleRanges)(0,s.highlightTree)(this.tree,t,(e,t,r)=>{n.add(e,t,this.markCache[r]||(this.markCache[r]=a.Decoration.mark({class:r})))},r,i);return n.finish()}}const je=o.Prec.high(a.ViewPlugin.fromClass(Fe,{decorations:e=>e.decorations})),Ue=Me.define([{tag:s.tags.meta,color:"#404740"},{tag:s.tags.link,textDecoration:"underline"},{tag:s.tags.heading,textDecoration:"underline",fontWeight:"bold"},{tag:s.tags.emphasis,fontStyle:"italic"},{tag:s.tags.strong,fontWeight:"bold"},{tag:s.tags.strikethrough,textDecoration:"line-through"},{tag:s.tags.keyword,color:"#708"},{tag:[s.tags.atom,s.tags.bool,s.tags.url,s.tags.contentSeparator,s.tags.labelName],color:"#219"},{tag:[s.tags.literal,s.tags.inserted],color:"#164"},{tag:[s.tags.string,s.tags.deleted],color:"#a11"},{tag:[s.tags.regexp,s.tags.escape,s.tags.special(s.tags.string)],color:"#e40"},{tag:s.tags.definition(s.tags.variableName),color:"#00f"},{tag:s.tags.local(s.tags.variableName),color:"#30a"},{tag:[s.tags.typeName,s.tags.namespace],color:"#085"},{tag:s.tags.className,color:"#167"},{tag:[s.tags.special(s.tags.variableName),s.tags.macroName],color:"#256"},{tag:s.tags.definition(s.tags.propertyName),color:"#00c"},{tag:s.tags.comment,color:"#940"},{tag:s.tags.invalid,color:"#f00"}]),Ge=a.EditorView.baseTheme({"&.cm-focused .cm-matchingBracket":{backgroundColor:"#328c8252"},"&.cm-focused .cm-nonmatchingBracket":{backgroundColor:"#bb555544"}}),He=1e4,qe="()[]{}",Qe=o.Facet.define({combine(e){return(0,o.combineConfig)(e,{afterCursor:!0,brackets:qe,maxScanDistance:He,renderMatch:We})}}),ze=a.Decoration.mark({class:"cm-matchingBracket"}),Ke=a.Decoration.mark({class:"cm-nonmatchingBracket"});function We(e){let t=[],n=e.matched?ze:Ke;return t.push(n.range(e.start.from,e.start.to)),e.end&&t.push(n.range(e.end.from,e.end.to)),t}function Xe(e){let t=[],n=e.facet(Qe);for(let r of e.selection.ranges){if(!r.empty)continue;let i=rt(e,r.head,-1,n)||r.head>0&&rt(e,r.head-1,1,n)||n.afterCursor&&(rt(e,r.head,1,n)||r.head<e.doc.length&&rt(e,r.head+1,-1,n));i&&(t=t.concat(n.renderMatch(i,e)))}return a.Decoration.set(t,!0)}const Ye=a.ViewPlugin.fromClass(class{constructor(e){this.paused=!1,this.decorations=Xe(e.state)}update(e){(e.docChanged||e.selectionSet||this.paused)&&(e.view.composing?(this.decorations=this.decorations.map(e.changes),this.paused=!0):(this.decorations=Xe(e.state),this.paused=!1))}},{decorations:e=>e.decorations}),Ze=[Ye,Ge];function Je(e={}){return[Qe.of(e),Ze]}const et=new i.NodeProp;function tt(e,t,n){let r=e.prop(t<0?i.NodeProp.openedBy:i.NodeProp.closedBy);if(r)return r;if(1==e.name.length){let r=n.indexOf(e.name);if(r>-1&&r%2==(t<0?1:0))return[n[r+t]]}return null}function nt(e){let t=e.type.prop(et);return t?t(e.node):e}function rt(e,t,n,r={}){let i=r.maxScanDistance||He,o=r.brackets||qe,a=g(e),s=a.resolveInner(t,n);for(let l=s;l;l=l.parent){let r=tt(l.type,n,o);if(r&&l.from<l.to){let i=nt(l);if(i&&(n>0?t>=i.from&&t<i.to:t>i.from&&t<=i.to))return it(e,t,n,l,i,r,o)}}return ot(e,t,n,a,s.type,i,o)}function it(e,t,n,r,i,o,a){let s=r.parent,l={from:i.from,to:i.to},c=0,u=null===s||void 0===s?void 0:s.cursor();if(u&&(n<0?u.childBefore(r.from):u.childAfter(r.to)))do{if(n<0?u.to<=r.from:u.from>=r.to){if(0==c&&o.indexOf(u.type.name)>-1&&u.from<u.to){let e=nt(u);return{start:l,end:e?{from:e.from,to:e.to}:void 0,matched:!0}}if(tt(u.type,n,a))c++;else if(tt(u.type,-n,a)){if(0==c){let e=nt(u);return{start:l,end:e&&e.from<e.to?{from:e.from,to:e.to}:void 0,matched:!1}}c--}}}while(n<0?u.prevSibling():u.nextSibling());return{start:l,matched:!1}}function ot(e,t,n,r,i,o,a){if(n<0?!t:t==e.doc.length)return null;let s=n<0?e.sliceDoc(t-1,t):e.sliceDoc(t,t+1),l=a.indexOf(s);if(l<0||l%2==0!=n>0)return null;let c={from:n<0?t-1:t,to:n>0?t+1:t},u=e.doc.iterRange(t,n>0?e.doc.length:0),d=0;for(let h=0;!u.next().done&&h<=o;){let e=u.value;n<0&&(h+=e.length);let o=t+h*n;for(let t=n>0?0:e.length-1,s=n>0?e.length:-1;t!=s;t+=n){let s=a.indexOf(e[t]);if(!(s<0||r.resolveInner(o+t,1).type!=i))if(s%2==0==n>0)d++;else{if(1==d)return{start:c,end:{from:o+t,to:o+t+1},matched:s>>1==l>>1};d--}}n>0&&(h+=e.length)}return u.done?{start:c,matched:!1}:null}function at(e,t,n,r=0,i=0){null==t&&(t=e.search(/[^\s\u00a0]/),-1==t&&(t=e.length));let o=i;for(let a=r;a<t;a++)9==e.charCodeAt(a)?o+=n-o%n:o++;return o}class st{constructor(e,t,n,r){this.string=e,this.tabSize=t,this.indentUnit=n,this.overrideIndent=r,this.pos=0,this.start=0,this.lastColumnPos=0,this.lastColumnValue=0}eol(){return this.pos>=this.string.length}sol(){return 0==this.pos}peek(){return this.string.charAt(this.pos)||void 0}next(){if(this.pos<this.string.length)return this.string.charAt(this.pos++)}eat(e){let t,n=this.string.charAt(this.pos);if(t="string"==typeof e?n==e:n&&(e instanceof RegExp?e.test(n):e(n)),t)return++this.pos,n}eatWhile(e){let t=this.pos;while(this.eat(e));return this.pos>t}eatSpace(){let e=this.pos;while(/[\s\u00a0]/.test(this.string.charAt(this.pos)))++this.pos;return this.pos>e}skipToEnd(){this.pos=this.string.length}skipTo(e){let t=this.string.indexOf(e,this.pos);if(t>-1)return this.pos=t,!0}backUp(e){this.pos-=e}column(){return this.lastColumnPos<this.start&&(this.lastColumnValue=at(this.string,this.start,this.tabSize,this.lastColumnPos,this.lastColumnValue),this.lastColumnPos=this.start),this.lastColumnValue}indentation(){var e;return null!==(e=this.overrideIndent)&&void 0!==e?e:at(this.string,null,this.tabSize)}match(e,t,n){if("string"==typeof e){let r=e=>n?e.toLowerCase():e,i=this.string.substr(this.pos,e.length);return r(i)==r(e)?(!1!==t&&(this.pos+=e.length),!0):null}{let n=this.string.slice(this.pos).match(e);return n&&n.index>0?null:(n&&!1!==t&&(this.pos+=n[0].length),n)}}current(){return this.string.slice(this.start,this.pos)}}function lt(e){return{name:e.name||"",token:e.token,blankLine:e.blankLine||(()=>{}),startState:e.startState||(()=>!0),copyState:e.copyState||ct,indent:e.indent||(()=>null),languageData:e.languageData||{},tokenTable:e.tokenTable||vt,mergeTokens:!1!==e.mergeTokens}}function ct(e){if("object"!=typeof e)return e;let t={};for(let n in e){let r=e[n];t[n]=r instanceof Array?r.slice():r}return t}const ut=new WeakMap;class dt extends p{constructor(e){let t,n=d(e.languageData),r=lt(e),o=new class extends i.Parser{createParse(e,n,r){return new mt(t,e,n,r)}};super(n,o,[],e.name),this.topNode=Ct(n,this),t=this,this.streamParser=r,this.stateAfter=new i.NodeProp({perNode:!0}),this.tokenTable=e.tokenTable?new Et(r.tokenTable):xt}static define(e){return new dt(e)}getIndent(e){let t,{overrideIndentation:n}=e.options;n&&(t=ut.get(e.state),null!=t&&t<e.pos-1e4&&(t=void 0));let r,i,o=ht(this,e.node.tree,e.node.from,e.node.from,null!==t&&void 0!==t?t:e.pos);if(o?(i=o.state,r=o.pos+1):(i=this.streamParser.startState(e.unit),r=e.node.from),e.pos-r>1e4)return null;while(r<e.pos){let t=e.state.doc.lineAt(r),o=Math.min(e.pos,t.to);if(t.length){let r=n?n(t.from):-1,a=new st(t.text,e.state.tabSize,e.unit,r<0?void 0:r);while(a.pos<o-t.from)gt(this.streamParser.token,a,i)}else this.streamParser.blankLine(i,e.unit);if(o==e.pos)break;r=t.to+1}let a=e.lineAt(e.pos);return n&&null==t&&ut.set(e.state,a.from),this.streamParser.indent(i,/^\s*(.*)/.exec(a.text)[1],e)}get allowsNesting(){return!1}}function ht(e,t,n,r,o){let a=n>=r&&n+t.length<=o&&t.prop(e.stateAfter);if(a)return{state:e.streamParser.copyState(a),pos:n+t.length};for(let s=t.children.length-1;s>=0;s--){let a=t.children[s],l=n+t.positions[s],c=a instanceof i.Tree&&l<o&&ht(e,a,l,r,o);if(c)return c}return null}function pt(e,t,n,r,o){if(o&&n<=0&&r>=t.length)return t;o||0!=n||t.type!=e.topNode||(o=!0);for(let a=t.children.length-1;a>=0;a--){let s,l=t.positions[a],c=t.children[a];if(l<r&&c instanceof i.Tree){if(!(s=pt(e,c,n-l,r-l,o)))break;return o?new i.Tree(t.type,t.children.slice(0,a).concat(s),t.positions.slice(0,a+1),l+s.length):s}}return null}function ft(e,t,n,r,o){for(let i of t){let t,o=i.from+(i.openStart?25:0),a=i.to-(i.openEnd?25:0),s=o<=n&&a>n&&ht(e,i.tree,0-i.offset,n,a);if(s&&s.pos<=r&&(t=pt(e,i.tree,n+i.offset,s.pos+i.offset,!1)))return{state:s.state,tree:t}}return{state:e.streamParser.startState(o?M(o):4),tree:i.Tree.empty}}class mt{constructor(e,t,n,r){this.lang=e,this.input=t,this.fragments=n,this.ranges=r,this.stoppedAt=null,this.chunks=[],this.chunkPos=[],this.chunk=[],this.chunkReused=void 0,this.rangeIndex=0,this.to=r[r.length-1].to;let i=E.get(),o=r[0].from,{state:a,tree:s}=ft(e,n,o,this.to,null===i||void 0===i?void 0:i.state);this.state=a,this.parsedPos=this.chunkStart=o+s.length;for(let l=0;l<s.children.length;l++)this.chunks.push(s.children[l]),this.chunkPos.push(s.positions[l]);i&&this.parsedPos<i.viewport.from-1e5&&r.some(e=>e.from<=i.viewport.from&&e.to>=i.viewport.from)&&(this.state=this.lang.streamParser.startState(M(i.state)),i.skipUntilInView(this.parsedPos,i.viewport.from),this.parsedPos=i.viewport.from),this.moveRangeIndex()}advance(){let e=E.get(),t=null==this.stoppedAt?this.to:Math.min(this.to,this.stoppedAt),n=Math.min(t,this.chunkStart+512);e&&(n=Math.min(n,e.viewport.to));while(this.parsedPos<n)this.parseLine(e);return this.chunkStart<this.parsedPos&&this.finishChunk(),this.parsedPos>=t?this.finish():e&&this.parsedPos>=e.viewport.to?(e.skipUntilInView(this.parsedPos,t),this.finish()):null}stopAt(e){this.stoppedAt=e}lineAfter(e){let t=this.input.chunk(e);if(this.input.lineChunks)"\n"==t&&(t="");else{let e=t.indexOf("\n");e>-1&&(t=t.slice(0,e))}return e+t.length<=this.to?t:t.slice(0,this.to-e)}nextLine(){let e=this.parsedPos,t=this.lineAfter(e),n=e+t.length;for(let r=this.rangeIndex;;){let e=this.ranges[r].to;if(e>=n)break;if(t=t.slice(0,e-(n-t.length)),r++,r==this.ranges.length)break;let i=this.ranges[r].from,o=this.lineAfter(i);t+=o,n=i+o.length}return{line:t,end:n}}skipGapsTo(e,t,n){for(;;){let r=this.ranges[this.rangeIndex].to,i=e+t;if(n>0?r>i:r>=i)break;let o=this.ranges[++this.rangeIndex].from;t+=o-r}return t}moveRangeIndex(){while(this.ranges[this.rangeIndex].to<this.parsedPos)this.rangeIndex++}emitToken(e,t,n,r){let i=4;if(this.ranges.length>1){r=this.skipGapsTo(t,r,1),t+=r;let e=this.chunk.length;r=this.skipGapsTo(n,r,-1),n+=r,i+=this.chunk.length-e}let o=this.chunk.length-4;return this.lang.streamParser.mergeTokens&&4==i&&o>=0&&this.chunk[o]==e&&this.chunk[o+2]==t?this.chunk[o+2]=n:this.chunk.push(e,t,n,i),r}parseLine(e){let{line:t,end:n}=this.nextLine(),r=0,{streamParser:i}=this.lang,o=new st(t,e?e.state.tabSize:4,e?M(e.state):2);if(o.eol())i.blankLine(this.state,o.indentUnit);else while(!o.eol()){let e=gt(i.token,o,this.state);if(e&&(r=this.emitToken(this.lang.tokenTable.resolve(e),this.parsedPos+o.start,this.parsedPos+o.pos,r)),o.start>1e4)break}this.parsedPos=n,this.moveRangeIndex(),this.parsedPos<this.to&&this.parsedPos++}finishChunk(){let e=i.Tree.build({buffer:this.chunk,start:this.chunkStart,length:this.parsedPos-this.chunkStart,nodeSet:yt,topID:0,maxBufferLength:512,reused:this.chunkReused});e=new i.Tree(e.type,e.children,e.positions,e.length,[[this.lang.stateAfter,this.lang.streamParser.copyState(this.state)]]),this.chunks.push(e),this.chunkPos.push(this.chunkStart-this.ranges[0].from),this.chunk=[],this.chunkReused=void 0,this.chunkStart=this.parsedPos}finish(){return new i.Tree(this.lang.topNode,this.chunks,this.chunkPos,this.parsedPos-this.ranges[0].from).balance()}}function gt(e,t,n){t.start=t.pos;for(let r=0;r<10;r++){let r=e(t,n);if(t.pos>t.start)return r}throw new Error("Stream parser failed to advance stream.")}const vt=Object.create(null),bt=[i.NodeType.none],yt=new i.NodeSet(bt),wt=[],Ot=Object.create(null),St=Object.create(null);for(let[Bt,$t]of[["variable","variableName"],["variable-2","variableName.special"],["string-2","string.special"],["def","variableName.definition"],["tag","tagName"],["attribute","attributeName"],["type","typeName"],["builtin","variableName.standard"],["qualifier","modifier"],["error","invalid"],["header","heading"],["property","propertyName"]])St[Bt]=kt(vt,$t);class Et{constructor(e){this.extra=e,this.table=Object.assign(Object.create(null),St)}resolve(e){return e?this.table[e]||(this.table[e]=kt(this.extra,e)):0}}const xt=new Et(vt);function _t(e,t){wt.indexOf(e)>-1||(wt.push(e),c.warn(t))}function kt(e,t){let n=[];for(let i of t.split(" ")){let t=[];for(let n of i.split(".")){let r=e[n]||s.tags[n];r?"function"==typeof r?t.length?t=t.map(r):_t(n,`Modifier ${n} used at start of tag`):t.length?_t(n,`Tag ${n} used as modifier`):t=Array.isArray(r)?r:[r]:_t(n,`Unknown highlighting tag ${n}`)}for(let e of t)n.push(e)}if(!n.length)return 0;let r=t.replace(/ /g,"_"),o=r+" "+n.map(e=>e.id),a=Ot[o];if(a)return a.id;let l=Ot[o]=i.NodeType.define({id:bt.length,name:r,props:[(0,s.styleTags)({[r]:n})]});return bt.push(l),l.id}function Ct(e,t){let n=i.NodeType.define({id:bt.length,name:"Document",props:[u.add(()=>e),V.add(()=>e=>t.getIndent(e))],top:!0});return bt.push(n),n}function At(e){return e.length<=4096&&/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac\ufb50-\ufdff]/.test(e)}function Tt(e){for(let t=e.iter();!t.next().done;)if(At(t.value))return!0;return!1}function Rt(e){let t=!1;return e.iterChanges((e,n,r,i,o)=>{!t&&Tt(o)&&(t=!0)}),t}const Nt=o.Facet.define({combine:e=>e.some(e=>e)});function Pt(e={}){let t=[It];return e.alwaysIsolate&&t.push(Nt.of(!0)),t}const It=a.ViewPlugin.fromClass(class{constructor(e){this.always=e.state.facet(Nt)||e.textDirection!=a.Direction.LTR||e.state.facet(a.EditorView.perLineTextDirection),this.hasRTL=!this.always&&Tt(e.state.doc),this.tree=g(e.state),this.decorations=this.always||this.hasRTL?Mt(e,this.tree,this.always):a.Decoration.none}update(e){let t=e.state.facet(Nt)||e.view.textDirection!=a.Direction.LTR||e.state.facet(a.EditorView.perLineTextDirection);if(t||this.hasRTL||!Rt(e.changes)||(this.hasRTL=!0),!t&&!this.hasRTL)return;let n=g(e.state);(t!=this.always||n!=this.tree||e.docChanged||e.viewportChanged)&&(this.tree=n,this.always=t,this.decorations=Mt(e.view,n,t))}},{provide:e=>{function t(t){var n,r;return null!==(r=null===(n=t.plugin(e))||void 0===n?void 0:n.decorations)&&void 0!==r?r:a.Decoration.none}return[a.EditorView.outerDecorations.of(t),o.Prec.lowest(a.EditorView.bidiIsolatedRanges.of(t))]}});function Mt(e,t,n){let r=new o.RangeSetBuilder,a=e.visibleRanges;n||(a=Dt(a,e.state.doc));for(let{from:o,to:s}of a)t.iterate({enter:e=>{let t=e.type.prop(i.NodeProp.isolate);t&&r.add(e.from,e.to,Lt[t])},from:o,to:s});return r.finish()}function Dt(e,t){let n=t.iter(),r=0,i=[],o=null;for(let{from:a,to:s}of e)if(!(o&&o.to>a&&(a=o.to,a>=s)))for(r+n.value.length<a&&(n.next(a-(r+n.value.length)),r=a);;){let e=r,t=r+n.value.length;if(!n.lineBreak&&At(n.value)&&(o&&o.to>e-10?o.to=Math.min(s,t):i.push(o={from:e,to:Math.min(s,t)})),t>=s)break;r=t,n.next()}return i}const Lt={rtl:a.Decoration.mark({class:"cm-iso",inclusive:!0,attributes:{dir:"rtl"},bidiIsolate:a.Direction.RTL}),ltr:a.Decoration.mark({class:"cm-iso",inclusive:!0,attributes:{dir:"ltr"},bidiIsolate:a.Direction.LTR}),auto:a.Decoration.mark({class:"cm-iso",inclusive:!0,attributes:{dir:"auto"},bidiIsolate:null})}},71087:function(e,t,n){"use strict";n.r(t),n.d(t,{BidiSpan:function(){return ke},BlockInfo:function(){return Er},BlockType:function(){return I},BlockWrapper:function(){return j},Decoration:function(){return M},Direction:function(){return ge},EditorView:function(){return fi},GutterMarker:function(){return ba},MatchDecorator:function(){return to},RectangleMarker:function(){return Pi},ViewPlugin:function(){return it},ViewUpdate:function(){return bt},WidgetType:function(){return P},__test:function(){return Ya},activateHover:function(){return Zo},closeHoverTooltip:function(){return ra},closeHoverTooltips:function(){return na},crosshairCursor:function(){return No},drawSelection:function(){return ji},dropCursor:function(){return Zi},getDialog:function(){return pa},getDrawSelectionConfig:function(){return Ui},getPanel:function(){return sa},getTooltip:function(){return Jo},gutter:function(){return Ea},gutterLineClass:function(){return ya},gutterWidgetClass:function(){return wa},gutters:function(){return _a},hasHoverTooltips:function(){return ea},highlightActiveLine:function(){return bo},highlightActiveLineGutter:function(){return Ga},highlightSpecialChars:function(){return lo},highlightTrailingWhitespace:function(){return Xa},highlightWhitespace:function(){return Ka},hoverTooltip:function(){return Yo},keymap:function(){return Ei},layer:function(){return Vi},lineNumberMarkers:function(){return Ia},lineNumberWidgetMarker:function(){return Ma},lineNumbers:function(){return Va},logException:function(){return et},panels:function(){return aa},placeholder:function(){return So},rectangularSelection:function(){return Ao},repositionTooltips:function(){return ia},runScopeHandlers:function(){return ki},scrollPastEnd:function(){return vo},showDialog:function(){return ha},showPanel:function(){return da},showTooltip:function(){return Uo},tooltips:function(){return Mo}});for(var r=n(76528),i=n(98104),o={8:"Backspace",9:"Tab",10:"Enter",12:"NumLock",13:"Enter",16:"Shift",17:"Control",18:"Alt",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",44:"PrintScreen",45:"Insert",46:"Delete",59:";",61:"=",91:"Meta",92:"Meta",106:"*",107:"+",108:",",109:"-",110:".",111:"/",144:"NumLock",145:"ScrollLock",160:"Shift",161:"Shift",162:"Control",163:"Control",164:"Alt",165:"Alt",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'"},a={48:")",49:"!",50:"@",51:"#",52:"$",53:"%",54:"^",55:"&",56:"*",57:"(",59:":",61:"+",173:"_",186:":",187:"+",188:"<",189:"_",190:">",191:"?",192:"~",219:"{",220:"|",221:"}",222:'"'},s="undefined"!=typeof navigator&&/Mac/.test(navigator.platform),l="undefined"!=typeof navigator&&/MSIE \d|Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(navigator.userAgent),c=0;c<10;c++)o[48+c]=o[96+c]=String(c);for(c=1;c<=24;c++)o[c+111]="F"+c;for(c=65;c<=90;c++)o[c]=String.fromCharCode(c+32),a[c]=String.fromCharCode(c);for(var u in o)a.hasOwnProperty(u)||(a[u]=o[u]);function d(e){var t=s&&e.metaKey&&e.shiftKey&&!e.ctrlKey&&!e.altKey||l&&e.shiftKey&&e.key&&1==e.key.length||"Unidentified"==e.key,n=!t&&e.key||(e.shiftKey?a:o)[e.keyCode]||e.key||"Unidentified";return"Esc"==n&&(n="Escape"),"Del"==n&&(n="Delete"),"Left"==n&&(n="ArrowLeft"),"Up"==n&&(n="ArrowUp"),"Right"==n&&(n="ArrowRight"),"Down"==n&&(n="ArrowDown"),n}var h=n(20941),p=n(4364);let f="undefined"!=typeof navigator?navigator:{userAgent:"",vendor:"",platform:""},m="undefined"!=typeof document?document:{documentElement:{style:{}}};const g=/Edge\/(\d+)/.exec(f.userAgent),v=/MSIE \d/.test(f.userAgent),b=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(f.userAgent),y=!!(v||b||g),w=!y&&/gecko\/(\d+)/i.test(f.userAgent),O=!y&&/Chrome\/(\d+)/.exec(f.userAgent),S="webkitFontSmoothing"in m.documentElement.style,E=!y&&/Apple Computer/.test(f.vendor),x=E&&(/Mobile\/\w+/.test(f.userAgent)||f.maxTouchPoints>2);var _={mac:x||/Mac/.test(f.platform),windows:/Win/.test(f.platform),linux:/Linux|X11/.test(f.platform),ie:y,ie_version:v?m.documentMode||6:b?+b[1]:g?+g[1]:0,gecko:w,gecko_version:w?+(/Firefox\/(\d+)/.exec(f.userAgent)||[0,0])[1]:0,chrome:!!O,chrome_version:O?+O[1]:0,ios:x,android:/Android\b/.test(f.userAgent),webkit:S,webkit_version:S?+(/\bAppleWebKit\/(\d+)/.exec(f.userAgent)||[0,0])[1]:0,safari:E,safari_version:E?+(/\bVersion\/(\d+(\.\d+)?)/.exec(f.userAgent)||[0,0])[1]:0,tabSize:null!=m.documentElement.style.tabSize?"tab-size":"-moz-tab-size"};function k(e,t){for(let n in e)"class"==n&&t.class?t.class+=" "+e.class:"style"==n&&t.style?t.style+=";"+e.style:t[n]=e[n];return t}const C=Object.create(null);function A(e,t,n){if(e==t)return!0;e||(e=C),t||(t=C);let r=Object.keys(e),i=Object.keys(t);if(r.length-(n&&r.indexOf(n)>-1?1:0)!=i.length-(n&&i.indexOf(n)>-1?1:0))return!1;for(let o of r)if(o!=n&&(-1==i.indexOf(o)||e[o]!==t[o]))return!1;return!0}function T(e,t){for(let n=e.attributes.length-1;n>=0;n--){let r=e.attributes[n].name;null==t[r]&&e.removeAttribute(r)}for(let n in t){let r=t[n];"style"==n?e.style.cssText=r:e.getAttribute(n)!=r&&e.setAttribute(n,r)}}function R(e,t,n){let r=!1;if(t)for(let i in t)n&&i in n||(r=!0,"style"==i?e.style.cssText="":e.removeAttribute(i));if(n)for(let i in n)t&&t[i]==n[i]||(r=!0,"style"==i?e.style.cssText=n[i]:e.setAttribute(i,n[i]));return r}function N(e){let t=Object.create(null);for(let n=0;n<e.attributes.length;n++){let r=e.attributes[n];t[r.name]=r.value}return t}class P{eq(e){return!1}updateDOM(e,t,n){return!1}compare(e){return this==e||this.constructor==e.constructor&&this.eq(e)}get estimatedHeight(){return-1}get lineBreaks(){return 0}ignoreEvent(e){return!0}coordsAt(e,t,n){return null}get isHidden(){return!1}get editable(){return!1}destroy(e){}}var I=function(e){return e[e["Text"]=0]="Text",e[e["WidgetBefore"]=1]="WidgetBefore",e[e["WidgetAfter"]=2]="WidgetAfter",e[e["WidgetRange"]=3]="WidgetRange",e}(I||(I={}));class M extends r.RangeValue{constructor(e,t,n,r){super(),this.startSide=e,this.endSide=t,this.widget=n,this.spec=r}get heightRelevant(){return!1}static mark(e){return new D(e)}static widget(e){let t=Math.max(-1e4,Math.min(1e4,e.side||0)),n=!!e.block;return t+=n&&!e.inlineOrder?t>0?3e8:-4e8:t>0?1e8:-1e8,new B(e,t,t,n,e.widget||null,!1)}static replace(e){let t,n,r=!!e.block;if(e.isBlockGap)t=-5e8,n=4e8;else{let{start:i,end:o}=$(e,r);t=(i?r?-3e8:-1:5e8)-1,n=1+(o?r?2e8:1:-6e8)}return new B(e,t,n,r,e.widget||null,!0)}static line(e){return new L(e)}static set(e,t=!1){return r.RangeSet.of(e,t)}hasHeight(){return!!this.widget&&this.widget.estimatedHeight>-1}}M.none=r.RangeSet.empty;class D extends M{constructor(e){let{start:t,end:n}=$(e);super(t?-1:5e8,n?1:-6e8,null,e),this.tagName=e.tagName||"span",this.attrs=e.class&&e.attributes?k(e.attributes,{class:e.class}):e.class?{class:e.class}:e.attributes||C}eq(e){return this==e||e instanceof D&&this.tagName==e.tagName&&A(this.attrs,e.attrs)}range(e,t=e){if(e>=t)throw new RangeError("Mark decorations may not be empty");return super.range(e,t)}}D.prototype.point=!1;class L extends M{constructor(e){super(-2e8,-2e8,null,e)}eq(e){return e instanceof L&&this.spec.class==e.spec.class&&A(this.spec.attributes,e.spec.attributes)}range(e,t=e){if(t!=e)throw new RangeError("Line decoration ranges must be zero-length");return super.range(e,t)}}L.prototype.mapMode=r.MapMode.TrackBefore,L.prototype.point=!0;class B extends M{constructor(e,t,n,i,o,a){super(t,n,o,e),this.block=i,this.isReplace=a,this.mapMode=i?t<=0?r.MapMode.TrackBefore:r.MapMode.TrackAfter:r.MapMode.TrackDel}get type(){return this.startSide!=this.endSide?I.WidgetRange:this.startSide<=0?I.WidgetBefore:I.WidgetAfter}get heightRelevant(){return this.block||!!this.widget&&(this.widget.estimatedHeight>=5||this.widget.lineBreaks>0)}eq(e){return e instanceof B&&V(this.widget,e.widget)&&this.block==e.block&&this.startSide==e.startSide&&this.endSide==e.endSide}range(e,t=e){if(this.isReplace&&(e>t||e==t&&this.startSide>0&&this.endSide<=0))throw new RangeError("Invalid range for replacement decoration");if(!this.isReplace&&t!=e)throw new RangeError("Widget decorations can only have zero-length ranges");return super.range(e,t)}}function $(e,t=!1){let{inclusiveStart:n,inclusiveEnd:r}=e;return null==n&&(n=e.inclusive),null==r&&(r=e.inclusive),{start:null!==n&&void 0!==n?n:t,end:null!==r&&void 0!==r?r:t}}function V(e,t){return e==t||!!(e&&t&&e.compare(t))}function F(e,t,n,r=0){let i=n.length-1;i>=0&&n[i]+r>=e?n[i]=Math.max(n[i],t):n.push(e,t)}B.prototype.point=!0;class j extends r.RangeValue{constructor(e,t,n){super(),this.tagName=e,this.attributes=t,this.rank=n}eq(e){return e==this||e instanceof j&&this.tagName==e.tagName&&A(this.attributes,e.attributes)}static create(e){return new j(e.tagName,e.attributes||C,null==e.rank?50:Math.max(0,Math.min(e.rank,100)))}static set(e,t=!1){return r.RangeSet.of(e,t)}}function U(e){let t;return t=11==e.nodeType?e.getSelection?e:e.ownerDocument:e,t.getSelection()}function G(e,t){return!!t&&(e==t||e.contains(1!=t.nodeType?t.parentNode:t))}function H(e,t){if(!t.anchorNode)return!1;try{return G(e,t.anchorNode)}catch(n){return!1}}function q(e){return 3==e.nodeType?le(e,0,e.nodeValue.length).getClientRects():1==e.nodeType?e.getClientRects():[]}function Q(e,t,n,r){return!!n&&(W(e,t,n,r,-1)||W(e,t,n,r,1))}function z(e){for(var t=0;;t++)if(e=e.previousSibling,!e)return t}function K(e){return 1==e.nodeType&&/^(DIV|P|LI|UL|OL|BLOCKQUOTE|DD|DT|H\d|SECTION|PRE)$/.test(e.nodeName)}function W(e,t,n,r,i){for(;;){if(e==n&&t==r)return!0;if(t==(i<0?0:X(e))){if("DIV"==e.nodeName)return!1;let n=e.parentNode;if(!n||1!=n.nodeType)return!1;t=z(e)+(i<0?0:1),e=n}else{if(1!=e.nodeType)return!1;if(e=e.childNodes[t+(i<0?-1:0)],1==e.nodeType&&"false"==e.contentEditable)return!1;t=i<0?X(e):0}}}function X(e){return 3==e.nodeType?e.nodeValue.length:e.childNodes.length}function Y(e,t){let{left:n,right:r}=e;if(n==r)return e;let i=t?n:r;return{left:i,right:i,top:e.top,bottom:e.bottom}}function Z(e){let t=e.visualViewport;return t?{left:0,right:t.width,top:0,bottom:t.height}:{left:0,right:e.innerWidth,top:0,bottom:e.innerHeight}}function J(e,t){let n=t.width/e.offsetWidth,r=t.height/e.offsetHeight;return(n>.995&&n<1.005||!isFinite(n)||Math.abs(t.width-e.offsetWidth)<1)&&(n=1),(r>.995&&r<1.005||!isFinite(r)||Math.abs(t.height-e.offsetHeight)<1)&&(r=1),{scaleX:n,scaleY:r}}function ee(e,t,n,r,i,o,a,s){let l=e.ownerDocument,c=l.defaultView||window;for(let u=e,d=!1;u&&!d;)if(1==u.nodeType){let e,h=u==l.body,p=1,f=1;if(h)e=Z(c);else{if(/^(fixed|sticky)$/.test(getComputedStyle(u).position)&&(d=!0),u.scrollHeight<=u.clientHeight&&u.scrollWidth<=u.clientWidth){u=u.assignedSlot||u.parentNode;continue}let t=u.getBoundingClientRect();({scaleX:p,scaleY:f}=J(u,t)),e={left:t.left,right:t.left+u.clientWidth*p,top:t.top,bottom:t.top+u.clientHeight*f}}let m=0,g=0;if("nearest"==i)t.top<e.top+a?(g=t.top-(e.top+a),n>0&&t.bottom>e.bottom+g&&(g=t.bottom-e.bottom+a)):t.bottom>e.bottom-a&&(g=t.bottom-e.bottom+a,n<0&&t.top-g<e.top&&(g=t.top-(e.top+a)));else{let r=t.bottom-t.top,o=e.bottom-e.top,s="center"==i&&r<=o?t.top+r/2-o/2:"start"==i||"center"==i&&n<0?t.top-a:t.bottom-o+a;g=s-e.top}if("nearest"==r)t.left<e.left+o?(m=t.left-(e.left+o),n>0&&t.right>e.right+m&&(m=t.right-e.right+o)):t.right>e.right-o&&(m=t.right-e.right+o,n<0&&t.left<e.left+m&&(m=t.left-(e.left+o)));else{let n="center"==r?t.left+(t.right-t.left)/2-(e.right-e.left)/2:"start"==r==s?t.left-o:t.right-(e.right-e.left)+o;m=n-e.left}if(m||g)if(h)c.scrollBy(m,g);else{let e=0,n=0;if(g){let e=u.scrollTop;u.scrollTop+=g/f,n=(u.scrollTop-e)*f}if(m){let t=u.scrollLeft;u.scrollLeft+=m/p,e=(u.scrollLeft-t)*p}t={left:t.left-e,top:t.top-n,right:t.right-e,bottom:t.bottom-n},e&&Math.abs(e-m)<1&&(r="nearest"),n&&Math.abs(n-g)<1&&(i="nearest")}if(h)break;(t.top<e.top||t.bottom>e.bottom||t.left<e.left||t.right>e.right)&&(t={left:Math.max(t.left,e.left),right:Math.min(t.right,e.right),top:Math.max(t.top,e.top),bottom:Math.min(t.bottom,e.bottom)}),u=u.assignedSlot||u.parentNode}else{if(11!=u.nodeType)break;u=u.host}}function te(e,t=!0){let n=e.ownerDocument,r=null,i=null;for(let o=e.parentNode;o;){if(o==n.body||(!t||r)&&i)break;if(1==o.nodeType)!i&&o.scrollHeight>o.clientHeight&&(i=o),t&&!r&&o.scrollWidth>o.clientWidth&&(r=o),o=o.assignedSlot||o.parentNode;else{if(11!=o.nodeType)break;o=o.host}}return{x:r,y:i}}j.prototype.startSide=j.prototype.endSide=-1;class ne{constructor(){this.anchorNode=null,this.anchorOffset=0,this.focusNode=null,this.focusOffset=0}eq(e){return this.anchorNode==e.anchorNode&&this.anchorOffset==e.anchorOffset&&this.focusNode==e.focusNode&&this.focusOffset==e.focusOffset}setRange(e){let{anchorNode:t,focusNode:n}=e;this.set(t,Math.min(e.anchorOffset,t?X(t):0),n,Math.min(e.focusOffset,n?X(n):0))}set(e,t,n,r){this.anchorNode=e,this.anchorOffset=t,this.focusNode=n,this.focusOffset=r}}function re(e){let t=[];for(let n=e;n;n=11==n.nodeType?n.host:n.parentNode)1==n.nodeType&&t.push({node:n,left:n.scrollLeft,top:n.scrollTop});return t}function ie(e,t=!0){for(let{node:n,left:r,top:i}of e)t&&n.scrollTop!=i&&(n.scrollTop=i),n.scrollLeft!=r&&(n.scrollLeft=r)}let oe,ae=null;function se(e){if(e.setActive)return e.setActive();if(ae)return e.focus(ae);let t=re(e);e.focus(null==ae?{get preventScroll(){return ae={preventScroll:!0},!0}}:void 0),ae||(ae=!1,ie(t))}function le(e,t,n=t){let r=oe||(oe=document.createRange());return r.setEnd(e,n),r.setStart(e,t),r}function ce(e,t,n,r){let i={key:t,code:t,keyCode:n,which:n,cancelable:!0};r&&({altKey:i.altKey,ctrlKey:i.ctrlKey,shiftKey:i.shiftKey,metaKey:i.metaKey}=r);let o=new KeyboardEvent("keydown",i);o.synthetic=!0,e.dispatchEvent(o);let a=new KeyboardEvent("keyup",i);return a.synthetic=!0,e.dispatchEvent(a),o.defaultPrevented||a.defaultPrevented}function ue(e){while(e){if(e&&(9==e.nodeType||11==e.nodeType&&e.host))return e;e=e.assignedSlot||e.parentNode}return null}function de(e,t){let n=t.focusNode,r=t.focusOffset;if(!n||t.anchorNode!=n||t.anchorOffset!=r)return!1;for(r=Math.min(r,X(n));;)if(r){if(1!=n.nodeType)return!1;let e=n.childNodes[r-1];"false"==e.contentEditable?r--:(n=e,r=X(n))}else{if(n==e)return!0;r=z(n),n=n.parentNode}}function he(e){return e instanceof Window?e.pageYOffset>Math.max(0,e.document.documentElement.scrollHeight-e.innerHeight-4):e.scrollTop>Math.max(1,e.scrollHeight-e.clientHeight-4)}function pe(e,t){for(let n=e,r=t;;){if(3==n.nodeType&&r>0)return{node:n,offset:r};if(1==n.nodeType&&r>0){if("false"==n.contentEditable)return null;n=n.childNodes[r-1],r=X(n)}else{if(!n.parentNode||K(n))return null;r=z(n),n=n.parentNode}}}function fe(e,t){for(let n=e,r=t;;){if(3==n.nodeType&&r<n.nodeValue.length)return{node:n,offset:r};if(1==n.nodeType&&r<n.childNodes.length){if("false"==n.contentEditable)return null;n=n.childNodes[r],r=0}else{if(!n.parentNode||K(n))return null;r=z(n)+1,n=n.parentNode}}}_.safari&&_.safari_version>=26&&(ae=!1);class me{constructor(e,t,n=!0){this.node=e,this.offset=t,this.precise=n}static before(e,t){return new me(e.parentNode,z(e),t)}static after(e,t){return new me(e.parentNode,z(e)+1,t)}}var ge=function(e){return e[e["LTR"]=0]="LTR",e[e["RTL"]=1]="RTL",e}(ge||(ge={}));const ve=ge.LTR,be=ge.RTL;function ye(e){let t=[];for(let n=0;n<e.length;n++)t.push(1<<+e[n]);return t}const we=ye("88888888888888888888888888888888888666888888787833333333337888888000000000000000000000000008888880000000000000000000000000088888888888888888888888888888888888887866668888088888663380888308888800000000000000000000000800000000000000000000000000000008"),Oe=ye("4444448826627288999999999992222222222222222222222222222222222222222222222229999999999999999999994444444444644222822222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222999999949999999229989999223333333333"),Se=Object.create(null),Ee=[];for(let Za of["()","[]","{}"]){let e=Za.charCodeAt(0),t=Za.charCodeAt(1);Se[e]=t,Se[t]=-e}function xe(e){return e<=247?we[e]:1424<=e&&e<=1524?2:1536<=e&&e<=1785?Oe[e-1536]:1774<=e&&e<=2220?4:8192<=e&&e<=8204?256:64336<=e&&e<=65023?4:1}const _e=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac\ufb50-\ufdff]/;class ke{get dir(){return this.level%2?be:ve}constructor(e,t,n){this.from=e,this.to=t,this.level=n}side(e,t){return this.dir==t==e?this.to:this.from}forward(e,t){return e==(this.dir==t)}static find(e,t,n,r){let i=-1;for(let o=0;o<e.length;o++){let a=e[o];if(a.from<=t&&a.to>=t){if(a.level==n)return o;(i<0||(0!=r?r<0?a.from<t:a.to>t:e[i].level>a.level))&&(i=o)}}if(i<0)throw new RangeError("Index out of range");return i}}function Ce(e,t){if(e.length!=t.length)return!1;for(let n=0;n<e.length;n++){let r=e[n],i=t[n];if(r.from!=i.from||r.to!=i.to||r.direction!=i.direction||!Ce(r.inner,i.inner))return!1}return!0}const Ae=[];function Te(e,t,n,r,i){for(let o=0;o<=r.length;o++){let a=o?r[o-1].to:t,s=o<r.length?r[o].from:n,l=o?256:i;for(let t=a,n=l,r=l;t<s;t++){let i=xe(e.charCodeAt(t));512==i?i=n:8==i&&4==r&&(i=16),Ae[t]=4==i?2:i,7&i&&(r=i),n=i}for(let e=a,t=l,r=l;e<s;e++){let i=Ae[e];if(128==i)e<s-1&&t==Ae[e+1]&&24&t?i=Ae[e]=t:Ae[e]=256;else if(64==i){let i=e+1;while(i<s&&64==Ae[i])i++;let o=e&&8==t||i<n&&8==Ae[i]?1==r?1:8:256;for(let t=e;t<i;t++)Ae[t]=o;e=i-1}else 8==i&&1==r&&(Ae[e]=1);t=i,7&i&&(r=i)}}}function Re(e,t,n,r,i){let o=1==i?2:1;for(let a=0,s=0,l=0;a<=r.length;a++){let c=a?r[a-1].to:t,u=a<r.length?r[a].from:n;for(let t,n,r,a=c;a<u;a++)if(n=Se[t=e.charCodeAt(a)])if(n<0){for(let e=s-3;e>=0;e-=3)if(Ee[e+1]==-n){let t=Ee[e+2],n=2&t?i:4&t?1&t?o:i:0;n&&(Ae[a]=Ae[Ee[e]]=n),s=e;break}}else{if(189==Ee.length)break;Ee[s++]=a,Ee[s++]=t,Ee[s++]=l}else if(2==(r=Ae[a])||1==r){let e=r==i;l=e?0:1;for(let t=s-3;t>=0;t-=3){let n=Ee[t+2];if(2&n)break;if(e)Ee[t+2]|=2;else{if(4&n)break;Ee[t+2]|=4}}}}}function Ne(e,t,n,r){for(let i=0,o=r;i<=n.length;i++){let a=i?n[i-1].to:e,s=i<n.length?n[i].from:t;for(let l=a;l<s;){let a=Ae[l];if(256==a){let a=l+1;for(;;)if(a==s){if(i==n.length)break;a=n[i++].to,s=i<n.length?n[i].from:t}else{if(256!=Ae[a])break;a++}let c=1==o,u=1==(a<t?Ae[a]:r),d=c==u?c?1:2:r;for(let t=a,r=i,o=r?n[r-1].to:e;t>l;)t==o&&(t=n[--r].from,o=r?n[r-1].to:e),Ae[--t]=d;l=a}else o=a,l++}}}function Pe(e,t,n,r,i,o,a){let s=r%2?2:1;if(r%2==i%2)for(let l=t,c=0;l<n;){let t=!0,u=!1;if(c==o.length||l<o[c].from){let e=Ae[l];e!=s&&(t=!1,u=16==e)}let d=t||1!=s?null:[],h=t?r:r+1,p=l;e:for(;;)if(c<o.length&&p==o[c].from){if(u)break e;let f=o[c];if(!t)for(let e=f.to,t=c+1;;){if(e==n)break e;if(!(t<o.length&&o[t].from==e)){if(Ae[e]==s)break e;break}e=o[t++].to}if(c++,d)d.push(f);else{f.from>l&&a.push(new ke(l,f.from,h));let t=f.direction==ve!=!(h%2);Ie(e,t?r+1:r,i,f.inner,f.from,f.to,a),l=f.to}p=f.to}else{if(p==n||(t?Ae[p]!=s:Ae[p]==s))break;p++}d?Pe(e,l,p,r+1,i,d,a):l<p&&a.push(new ke(l,p,h)),l=p}else for(let l=n,c=o.length;l>t;){let n=!0,u=!1;if(!c||l>o[c-1].to){let e=Ae[l-1];e!=s&&(n=!1,u=16==e)}let d=n||1!=s?null:[],h=n?r:r+1,p=l;e:for(;;)if(c&&p==o[c-1].to){if(u)break e;let f=o[--c];if(!n)for(let e=f.from,n=c;;){if(e==t)break e;if(!n||o[n-1].to!=e){if(Ae[e-1]==s)break e;break}e=o[--n].from}if(d)d.push(f);else{f.to<l&&a.push(new ke(f.to,l,h));let t=f.direction==ve!=!(h%2);Ie(e,t?r+1:r,i,f.inner,f.from,f.to,a),l=f.from}p=f.from}else{if(p==t||(n?Ae[p-1]!=s:Ae[p-1]==s))break;p--}d?Pe(e,p,l,r+1,i,d,a):p<l&&a.push(new ke(p,l,h)),l=p}}function Ie(e,t,n,r,i,o,a){let s=t%2?2:1;Te(e,i,o,r,s),Re(e,i,o,r,s),Ne(i,o,r,s),Pe(e,i,o,t,n,r,a)}function Me(e,t,n){if(!e)return[new ke(0,0,t==be?1:0)];if(t==ve&&!n.length&&!_e.test(e))return De(e.length);if(n.length)while(e.length>Ae.length)Ae[Ae.length]=256;let r=[],i=t==ve?0:1;return Ie(e,i,i,n,0,e.length,r),r}function De(e){return[new ke(0,e,0)]}let Le="";function Be(e,t,n,i,o){var a;if(!e.length)return null;let s,l=i.head-e.from;if(i.head==e.from&&i.assoc<0){if(!o)return null;l=t[s=0].side(!1,n)}else if(i.head==e.to&&i.assoc>0){if(o)return null;l=t[s=t.length-1].side(!0,n)}else s=ke.find(t,l,null!==(a=i.bidiLevel)&&void 0!==a?a:-1,i.assoc);let c=t[s],u=c.side(o,n);if(l==u){let e=s+=o?1:-1;if(e<0||e>=t.length)return null;c=t[s=e],l=c.side(!o,n),u=c.side(o,n)}let d=(0,r.findClusterBreak)(e.text,l,c.forward(o,n));(d<c.from||d>c.to)&&(d=u),Le=e.text.slice(Math.min(l,d),Math.max(l,d));let h=s==(o?t.length-1:0)?null:t[s+(o?1:-1)];if(d==u){if(!h)return o?r.EditorSelection.cursor(e.to,1):r.EditorSelection.cursor(e.from,-1);if(h.level+(o?0:1)<c.level)return r.EditorSelection.cursor(h.side(!o,n)+e.from,h.forward(o,n)?1:-1,h.level)}return r.EditorSelection.cursor(d+e.from,c.forward(o,n)?-1:1,c.level)}function $e(e,t,n){for(let r=t;r<n;r++){let t=xe(e.charCodeAt(r));if(1==t)return ve;if(2==t||4==t)return be}return ve}const Ve=r.Facet.define(),Fe=r.Facet.define(),je=r.Facet.define(),Ue=r.Facet.define(),Ge=r.Facet.define(),He=r.Facet.define(),qe=r.Facet.define(),Qe=r.Facet.define(),ze=r.Facet.define(),Ke=r.Facet.define({combine:e=>e.some(e=>e)}),We=r.Facet.define({combine:e=>e.some(e=>e)}),Xe=r.Facet.define();class Ye{constructor(e,t,n,r,i,o=!1){this.range=e,this.y=t,this.x=n,this.yMargin=r,this.xMargin=i,this.isSnapshot=o}map(e){return e.empty?this:new Ye(this.range.map(e),this.y,this.x,this.yMargin,this.xMargin,this.isSnapshot)}clip(e){return this.range.to<=e.doc.length?this:new Ye(r.EditorSelection.cursor(e.doc.length),this.y,this.x,this.yMargin,this.xMargin,this.isSnapshot)}}const Ze=r.StateEffect.define({map:(e,t)=>e.map(t)}),Je=r.StateEffect.define();function et(e,t,n){let r=e.facet(Ue);r.length?r[0](t):window.onerror&&window.onerror(String(t),n,void 0,void 0,t)||(n?p.error(n+":",t):p.error(t))}const tt=r.Facet.define({combine:e=>!e.length||e[0]});let nt=0;const rt=r.Facet.define({combine(e){return e.filter((t,n)=>{for(let r=0;r<n;r++)if(e[r].plugin==t.plugin)return!1;return!0})}});class it{constructor(e,t,n,r,i){this.id=e,this.create=t,this.domEventHandlers=n,this.domEventObservers=r,this.baseExtensions=i(this),this.extension=this.baseExtensions.concat(rt.of({plugin:this,arg:void 0}))}of(e){return this.baseExtensions.concat(rt.of({plugin:this,arg:e}))}static define(e,t){const{eventHandlers:n,eventObservers:r,provide:i,decorations:o}=t||{};return new it(nt++,e,n,r,e=>{let t=[];return o&&t.push(lt.of(t=>{let n=t.plugin(e);return n?o(n):M.none})),i&&t.push(i(e)),t})}static fromClass(e,t){return it.define((t,n)=>new e(t,n),t)}}class ot{constructor(e){this.spec=e,this.mustUpdate=null,this.value=null}get plugin(){return this.spec&&this.spec.plugin}update(e){if(this.value){if(this.mustUpdate){let e=this.mustUpdate;if(this.mustUpdate=null,this.value.update)try{this.value.update(e)}catch(t){if(et(e.state,t,"CodeMirror plugin crashed"),this.value.destroy)try{this.value.destroy()}catch(n){}this.deactivate()}}}else if(this.spec)try{this.value=this.spec.plugin.create(e,this.spec.arg)}catch(t){et(e.state,t,"CodeMirror plugin crashed"),this.deactivate()}return this}destroy(e){var t;if(null===(t=this.value)||void 0===t?void 0:t.destroy)try{this.value.destroy()}catch(n){et(e.state,n,"CodeMirror plugin crashed")}}deactivate(){this.spec=this.value=null}}const at=r.Facet.define(),st=r.Facet.define(),lt=r.Facet.define(),ct=r.Facet.define(),ut=r.Facet.define(),dt=r.Facet.define(),ht=r.Facet.define();function pt(e,t){let n=e.state.facet(ht);if(!n.length)return n;let i=n.map(t=>t instanceof Function?t(e):t),o=[];return r.RangeSet.spans(i,t.from,t.to,{point(){},span(e,n,r,i){let a=e-t.from,s=n-t.from,l=o;for(let o=r.length-1;o>=0;o--,i--){let e,n=r[o].spec.bidiIsolate;if(null==n&&(n=$e(t.text,a,s)),i>0&&l.length&&(e=l[l.length-1]).to==a&&e.direction==n)e.to=s,l=e.inner;else{let e={from:a,to:s,direction:n,inner:[]};l.push(e),l=e.inner}}}}),o}const ft=r.Facet.define();function mt(e){let t=0,n=0,r=0,i=0;for(let o of e.state.facet(ft)){let a=o(e);a&&(null!=a.left&&(t=Math.max(t,a.left)),null!=a.right&&(n=Math.max(n,a.right)),null!=a.top&&(r=Math.max(r,a.top)),null!=a.bottom&&(i=Math.max(i,a.bottom)))}return{left:t,right:n,top:r,bottom:i}}const gt=r.Facet.define();class vt{constructor(e,t,n,r){this.fromA=e,this.toA=t,this.fromB=n,this.toB=r}join(e){return new vt(Math.min(this.fromA,e.fromA),Math.max(this.toA,e.toA),Math.min(this.fromB,e.fromB),Math.max(this.toB,e.toB))}addToSet(e){let t=e.length,n=this;for(;t>0;t--){let r=e[t-1];if(!(r.fromA>n.toA)){if(r.toA<n.fromA)break;n=n.join(r),e.splice(t-1,1)}}return e.splice(t,0,n),e}static extendWithRanges(e,t){if(0==t.length)return e;let n=[];for(let r=0,i=0,o=0;;){let a=r<e.length?e[r].fromB:1e9,s=i<t.length?t[i]:1e9,l=Math.min(a,s);if(1e9==l)break;let c=l+o,u=l,d=c;for(;;)if(i<t.length&&t[i]<=u){let n=t[i+1];i+=2,u=Math.max(u,n);for(let t=r;t<e.length&&e[t].fromB<=u;t++)o=e[t].toA-e[t].toB;d=Math.max(d,n+o)}else{if(!(r<e.length&&e[r].fromB<=u))break;{let t=e[r++];u=Math.max(u,t.toB),d=Math.max(d,t.toA),o=t.toA-t.toB}}n.push(new vt(c,d,l,u))}return n}}class bt{constructor(e,t,n){this.view=e,this.state=t,this.transactions=n,this.flags=0,this.startState=e.state,this.changes=r.ChangeSet.empty(this.startState.doc.length);for(let r of n)this.changes=this.changes.compose(r.changes);let i=[];this.changes.iterChangedRanges((e,t,n,r)=>i.push(new vt(e,t,n,r))),this.changedRanges=i}static create(e,t,n){return new bt(e,t,n)}get viewportChanged(){return(4&this.flags)>0}get viewportMoved(){return(8&this.flags)>0}get heightChanged(){return(2&this.flags)>0}get geometryChanged(){return this.docChanged||(18&this.flags)>0}get focusChanged(){return(1&this.flags)>0}get docChanged(){return!this.changes.empty}get selectionSet(){return this.transactions.some(e=>e.selection)}get empty(){return 0==this.flags&&0==this.transactions.length}}const yt=[];class wt{constructor(e,t,n=0){this.dom=e,this.length=t,this.flags=n,this.parent=null,e.cmTile=this}get breakAfter(){return 1&this.flags}get children(){return yt}isWidget(){return!1}get isHidden(){return!1}isComposite(){return!1}isLine(){return!1}isText(){return!1}isBlock(){return!1}get domAttrs(){return null}sync(e){if(this.flags|=2,4&this.flags){this.flags&=-5;let e=this.domAttrs;e&&T(this.dom,e)}}toString(){return this.constructor.name+(this.children.length?`(${this.children})`:"")+(this.breakAfter?"#":"")}destroy(){this.parent=null}setDOM(e){this.dom=e,e.cmTile=this}get posAtStart(){return this.parent?this.parent.posBefore(this):0}get posAtEnd(){return this.posAtStart+this.length}posBefore(e,t=this.posAtStart){let n=t;for(let r of this.children){if(r==e)return n;n+=r.length+r.breakAfter}throw new RangeError("Invalid child in posBefore")}posAfter(e){return this.posBefore(e)+e.length}covers(e){return!0}coordsIn(e,t,n){return null}domPosFor(e,t){let n=z(this.dom),r=this.length?e>0:t>0;return new me(this.parent.dom,n+(r?1:0),0==e||e==this.length)}markDirty(e){this.flags&=-3,e&&(this.flags|=4),this.parent&&2&this.parent.flags&&this.parent.markDirty(!1)}get overrideDOMText(){return null}get root(){for(let e=this;e;e=e.parent)if(e instanceof Et)return e;return null}static get(e){return e.cmTile}}class Ot extends wt{constructor(e){super(e,0),this._children=[]}isComposite(){return!0}get children(){return this._children}get lastChild(){return this.children.length?this.children[this.children.length-1]:null}append(e){this.children.push(e),e.parent=this}sync(e){if(2&this.flags)return;super.sync(e);let t,n=this.dom,r=null,i=(null===e||void 0===e?void 0:e.node)==n?e:null,o=0;for(let a of this.children){if(a.sync(e),o+=a.length+a.breakAfter,t=r?r.nextSibling:n.firstChild,i&&t!=a.dom&&(i.written=!0),a.dom.parentNode==n)while(t&&t!=a.dom)t=St(t);else n.insertBefore(a.dom,t);r=a.dom}t=r?r.nextSibling:n.firstChild,i&&t&&(i.written=!0);while(t)t=St(t);this.length=o}}function St(e){let t=e.nextSibling;return e.parentNode.removeChild(e),t}class Et extends Ot{constructor(e,t){super(t),this.view=e}owns(e){for(;e;e=e.parent)if(e==this)return!0;return!1}isBlock(){return!0}nearest(e){for(;;){if(!e)return null;let t=wt.get(e);if(t&&this.owns(t))return t;e=e.parentNode}}blockTiles(e){for(let t=[],n=this,r=0,i=0;;)if(r==n.children.length){if(!t.length)return;n=n.parent,n.breakAfter&&i++,r=t.pop()}else{let o=n.children[r++];if(o instanceof xt)t.push(r),n=o,r=0;else{let t=i+o.length,n=e(o,i);if(void 0!==n)return n;i=t+o.breakAfter}}}resolveBlock(e,t){let n,r,i=-1,o=-1;if(this.blockTiles((a,s)=>{let l=s+a.length;if(e>=s&&e<=l){if(a.isWidget()&&t>=-1&&t<=1){if(32&a.flags)return!0;16&a.flags&&(n=void 0)}(s<e||e==l&&(t<-1?a.length:a.covers(1)))&&(!n||!a.isWidget()&&n.isWidget())&&(n=a,i=e-s),(l>e||e==s&&(t>1?a.length:a.covers(-1)))&&(!r||!a.isWidget()&&r.isWidget())&&(r=a,o=e-s)}}),!n&&!r)throw new Error("No tile at position "+e);return n&&t<0||!r?{tile:n,offset:i}:{tile:r,offset:o}}}class xt extends Ot{constructor(e,t){super(e),this.wrapper=t}isBlock(){return!0}covers(e){return!!this.children.length&&(e<0?this.children[0].covers(-1):this.lastChild.covers(1))}get domAttrs(){return this.wrapper.attributes}static of(e,t){let n=new xt(t||document.createElement(e.tagName),e);return t||(n.flags|=4),n}}class _t extends Ot{constructor(e,t){super(e),this.attrs=t}isLine(){return!0}static start(e,t,n){let r=new _t(t||document.createElement("div"),e);return t&&n||(r.flags|=4),r}get domAttrs(){return this.attrs}resolveInline(e,t,n){let r=null,i=-1,o=null,a=-1;function s(e,l){for(let c=0,u=0;c<e.children.length&&u<=l;c++){let d=e.children[c],h=u+d.length;h>=l&&(d.isComposite()?s(d,l-u):(!o||o.isHidden&&(t>0&&!(32&o.flags)||n&&Ct(o,d)))&&(h>l||32&d.flags&&t<=1)?(o=d,a=l-u):(u<l||16&d.flags&&!d.isHidden&&t>=-1)&&(r=d,i=l-u)),u=h}}s(this,e);let l=(t<0?r:o)||r||o;return l?{tile:l,offset:l==r?i:a}:null}coordsIn(e,t,n){let r=this.resolveInline(e,t,!0);return r?r.tile.coordsIn(Math.max(0,r.offset),t,n):kt(this)}domIn(e,t){let n=this.resolveInline(e,t);if(n){let{tile:e,offset:r}=n;if(this.dom.contains(e.dom))return e.isText()?new me(e.dom,Math.min(e.dom.nodeValue.length,r)):e.domPosFor(r,16&e.flags?1:32&e.flags?-1:t);let i=n.tile.parent,o=!1;for(let t of i.children){if(o)return new me(t.dom,0);t==n.tile&&(o=!0)}}return new me(this.dom,0)}}function kt(e){let t=e.dom.lastChild;if(!t)return e.dom.getBoundingClientRect();let n=q(t);return n[n.length-1]||null}function Ct(e,t){let n=e.coordsIn(0,1),r=t.coordsIn(0,1);return n&&r&&r.top<n.bottom}class At extends Ot{constructor(e,t){super(e),this.mark=t}get domAttrs(){return this.mark.attrs}static of(e,t){let n=new At(t||document.createElement(e.tagName),e);return t||(n.flags|=4),n}}class Tt extends wt{constructor(e,t){super(e,t.length),this.text=t}sync(e){2&this.flags||(super.sync(e),this.dom.nodeValue!=this.text&&(e&&e.node==this.dom&&(e.written=!0),this.dom.nodeValue=this.text))}isText(){return!0}toString(){return JSON.stringify(this.text)}coordsIn(e,t,n){let r=this.dom.nodeValue.length;e>r&&(e=r);let i=e,o=e,a=0;0==e&&t<0||e==r&&t>=0?_.chrome||_.gecko||(e?(i--,a=1):o<r&&(o++,a=-1)):t<0?i--:o<r&&o++;let s=le(this.dom,i,o).getClientRects();if(!s.length)return null;let l=s[(a?a<0:t>=0)?0:s.length-1];return _.safari&&!a&&0==l.width&&(l=Array.prototype.find.call(s,e=>e.width)||l),null==n?l:Y(l,(a?a>0:t<0)==n)}static of(e,t){let n=new Tt(t||document.createTextNode(e),e);return t||(n.flags|=2),n}}class Rt extends wt{constructor(e,t,n,r){super(e,t,r),this.widget=n}isWidget(){return!0}get isHidden(){return this.widget.isHidden}covers(e){return!(48&this.flags)&&(this.flags&(e<0?64:128))>0}coordsIn(e,t){return this.coordsInWidget(e,t,!1)}coordsInWidget(e,t,n){let r=this.widget.coordsAt(this.dom,e,t);if(r)return r;if(n)return Y(this.dom.getBoundingClientRect(),this.length?0==e:t<=0);{let t=this.dom.getClientRects(),n=null;if(!t.length)return null;let r=!!(16&this.flags)||!(32&this.flags)&&e>0;for(let i=r?t.length-1:0;;i+=r?-1:1)if(n=t[i],e>0?0==i:i==t.length-1||n.top<n.bottom)break;return Y(n,!r)}}get overrideDOMText(){if(!this.length)return r.Text.empty;let{root:e}=this;if(!e)return r.Text.empty;let t=this.posAtStart;return e.view.state.doc.slice(t,t+this.length)}destroy(){super.destroy(),this.widget.destroy(this.dom)}static of(e,t,n,r,i){return i||(i=e.toDOM(t),e.editable||(i.contentEditable="false")),new Rt(i,n,e,r)}}class Nt extends wt{constructor(e){let t=document.createElement("img");t.className="cm-widgetBuffer",t.setAttribute("aria-hidden","true"),super(t,0,e)}get isHidden(){return!0}get overrideDOMText(){return r.Text.empty}coordsIn(e,t,n){let r=this.dom.getBoundingClientRect();return null==n?r:Y(r,t>0==n)}}class Pt{constructor(e){this.index=0,this.beforeBreak=!1,this.parents=[],this.tile=e}advance(e,t,n){let{tile:r,index:i,beforeBreak:o,parents:a}=this;while(e||t>0)if(r.isComposite())if(o){if(!e)break;n&&n.break(),e--,o=!1}else if(i==r.children.length){if(!e&&!a.length)break;n&&n.leave(r),o=!!r.breakAfter,({tile:r,index:i}=a.pop()),i++}else{let s=r.children[i],l=s.breakAfter;!(t>0?s.length<=e:s.length<e)||n&&!1===n.skip(s,0,s.length)&&s.isComposite?(a.push({tile:r,index:i}),r=s,i=0,n&&s.isComposite()&&n.enter(s)):(o=!!l,i++,e-=s.length)}else{let t=r.length;if(i<t&&e){let o=Math.min(e,t-i);n&&n.skip(r,i,i+o),e-=o,i+=o}if(i==t)o=!!r.breakAfter,({tile:r,index:i}=a.pop()),i++;else if(!e)break}return this.tile=r,this.index=i,this.beforeBreak=o,this}get root(){return this.parents.length?this.parents[0].tile:this.tile}}class It{constructor(e,t,n,r){this.from=e,this.to=t,this.wrapper=n,this.rank=r}}class Mt{constructor(e,t,n){this.cache=e,this.root=t,this.blockWrappers=n,this.curLine=null,this.lastBlock=null,this.afterWidget=null,this.pos=0,this.wrappers=[],this.wrapperPos=0}addText(e,t,n,r){var i;this.flushBuffer();let o=this.ensureMarks(t,n),a=o.lastChild;if(a&&a.isText()&&!(8&a.flags)&&a.length+e.length<512){this.cache.reused.set(a,2);let t=o.children[o.children.length-1]=new Tt(a.dom,a.text+e);t.parent=o}else o.append(r||Tt.of(e,null===(i=this.cache.find(Tt))||void 0===i?void 0:i.dom));this.pos+=e.length,this.afterWidget=null}addComposition(e,t){let n=this.curLine;n.dom!=t.line.dom&&(n.setDOM(this.cache.reused.has(t.line)?Ht(t.line.dom):t.line.dom),this.cache.reused.set(t.line,2));let r=n;for(let a=t.marks.length-1;a>=0;a--){let e=t.marks[a],n=r.lastChild;if(n instanceof At&&n.mark.eq(e.mark))n.dom!=e.dom&&n.setDOM(Ht(e.dom)),r=n;else{let{dom:t}=e;if(this.cache.reused.get(e)){let n=wt.get(e.dom);n&&(t=Ht(e.dom))}let n=At.of(e.mark,t);r.append(n),r=n}this.cache.reused.set(e,2)}let i=wt.get(e.text);i&&this.cache.reused.set(i,2);let o=new Tt(e.text,e.text.nodeValue);o.flags|=8,this.pos=e.range.toB,r.append(o)}addInlineWidget(e,t,n){let r=this.afterWidget&&48&e.flags&&(48&this.afterWidget.flags)==(48&e.flags);r||this.flushBuffer();let i=this.ensureMarks(t,n);r||16&e.flags||i.append(this.getBuffer(1)),i.append(e),this.pos+=e.length,this.afterWidget=e}addMark(e,t,n){this.flushBuffer();let r=this.ensureMarks(t,n);r.append(e),this.pos+=e.length,this.afterWidget=null}addBlockWidget(e){this.getBlockPos().append(e),this.pos+=e.length,this.lastBlock=e,this.endLine()}continueWidget(e){let t=this.afterWidget||this.lastBlock;t.length+=e,this.pos+=e}addLineStart(e,t){var n;e||(e=jt);let r=_t.start(e,t||(null===(n=this.cache.find(_t))||void 0===n?void 0:n.dom),!!t);this.getBlockPos().append(this.lastBlock=this.curLine=r)}addLine(e){this.getBlockPos().append(e),this.pos+=e.length,this.lastBlock=e,this.endLine()}addBreak(){this.lastBlock.flags|=1,this.endLine(),this.pos++}addLineStartIfNotCovered(e){this.blockPosCovered()||this.addLineStart(e)}ensureLine(e){this.curLine||this.addLineStart(e)}ensureMarks(e,t){var n;let r=this.curLine;for(let i=e.length-1;i>=0;i--){let o,a=e[i];if(t>0&&(o=r.lastChild)&&o instanceof At&&o.mark.eq(a))r=o,t--;else{let e=At.of(a,null===(n=this.cache.find(At,e=>e.mark.eq(a)))||void 0===n?void 0:n.dom);r.append(e),r=e,t=0}}return r}endLine(){if(this.curLine){this.flushBuffer();let e=this.curLine.lastChild;e&&Vt(this.curLine,!1)&&("BR"==e.dom.nodeName||!e.isWidget()||_.ios&&Vt(this.curLine,!0))||this.curLine.append(this.cache.findWidget(Qt,0,32)||new Rt(Qt.toDOM(),0,Qt,32)),this.curLine=this.afterWidget=null}}updateBlockWrappers(){this.wrapperPos>this.pos+1e4&&(this.blockWrappers.goto(this.pos),this.wrappers.length=0);for(let e=this.wrappers.length-1;e>=0;e--)this.wrappers[e].to<this.pos&&this.wrappers.splice(e,1);for(let e=this.blockWrappers;e.value&&e.from<=this.pos;e.next())if(e.to>=this.pos){let t=102*e.rank+e.value.rank,n=new It(e.from,e.to,e.value,t),r=this.wrappers.length;while(r>0&&(this.wrappers[r-1].rank-n.rank||this.wrappers[r-1].to-n.to)<0)r--;this.wrappers.splice(r,0,n)}this.wrapperPos=this.pos}getBlockPos(){var e;this.updateBlockWrappers();let t=this.root;for(let n of this.wrappers){let r=t.lastChild;if(n.from<this.pos&&r instanceof xt&&r.wrapper.eq(n.wrapper))t=r;else{let r=xt.of(n.wrapper,null===(e=this.cache.find(xt,e=>e.wrapper.eq(n.wrapper)))||void 0===e?void 0:e.dom);t.append(r),t=r}}return t}blockPosCovered(){let e=this.lastBlock;return null!=e&&!e.breakAfter&&(!e.isWidget()||(160&e.flags)>0)}getBuffer(e){let t=2|(e<0?16:32),n=this.cache.find(Nt,void 0,1);return n&&(n.flags=t),n||new Nt(t)}flushBuffer(){!this.afterWidget||32&this.afterWidget.flags||(this.afterWidget.parent.append(this.getBuffer(-1)),this.afterWidget=null)}}class Dt{constructor(e){this.skipCount=0,this.text="",this.textOff=0,this.cursor=e.iter()}skip(e){this.textOff+e<=this.text.length?this.textOff+=e:(this.skipCount+=e-(this.text.length-this.textOff),this.text="",this.textOff=0)}next(e){if(this.textOff==this.text.length){let{value:t,lineBreak:n,done:r}=this.cursor.next(this.skipCount);if(this.skipCount=0,r)throw new Error("Ran out of text content when drawing inline views");this.text=t;let i=this.textOff=Math.min(e,t.length);return n?null:t.slice(0,i)}let t=Math.min(this.text.length,this.textOff+e),n=this.text.slice(this.textOff,t);return this.textOff=t,n}}const Lt=[Rt,_t,Tt,At,Nt,xt,Et];for(let Za=0;Za<Lt.length;Za++)Lt[Za].bucket=Za;class Bt{constructor(e){this.view=e,this.buckets=Lt.map(()=>[]),this.index=Lt.map(()=>0),this.reused=new Map}add(e){let t=e.constructor.bucket,n=this.buckets[t];n.length<6?n.push(e):n[this.index[t]=(this.index[t]+1)%6]=e}find(e,t,n=2){let r=e.bucket,i=this.buckets[r],o=this.index[r];for(let a=0;a<i.length;a++){let e=(a+o)%i.length,s=i[e];if((!t||t(s))&&!this.reused.has(s))return i.splice(e,1),e<o&&this.index[r]--,this.reused.set(s,n),s}return null}findWidget(e,t,n){let r=this.buckets[0];if(r.length)for(let i=0,o=0;;i++){if(i==r.length){if(o)return null;o=1,i=0}let a=r[i];if(!this.reused.has(a)&&(0==o?a.widget.compare(e):a.widget.constructor==e.constructor&&e.updateDOM(a.dom,this.view,a.widget)))return r.splice(i,1),i<this.index[0]&&this.index[0]--,a.widget==e&&a.length==t&&(497&a.flags)==n?(this.reused.set(a,1),a):(this.reused.set(a,2),new Rt(a.dom,t,e,-498&a.flags|n))}}reuse(e){return this.reused.set(e,1),e}maybeReuse(e,t=2){if(!this.reused.has(e))return this.reused.set(e,t),e.dom}clear(){for(let e=0;e<this.buckets.length;e++)this.buckets[e].length=this.index[e]=0}}class $t{constructor(e,t,n,i,o){this.view=e,this.decorations=i,this.disallowBlockEffectsFor=o,this.openWidget=!1,this.openMarks=0,this.cache=new Bt(e),this.text=new Dt(e.state.doc),this.builder=new Mt(this.cache,new Et(e,e.contentDOM),r.RangeSet.iter(n)),this.cache.reused.set(t,2),this.old=new Pt(t),this.reuseWalker={skip:(e,t,n)=>{if(this.cache.add(e),e.isComposite())return!1},enter:e=>this.cache.add(e),leave:()=>{},break:()=>{}}}run(e,t){let n=t&&this.getCompositionContext(t.text);for(let r=0,i=0,o=0;;){let a=o<e.length?e[o++]:null,s=a?a.fromA:this.old.root.length;if(s>r){let e=s-r;this.preserve(e,!o,!a),r=s,i+=e}if(!a)break;t&&a.fromA<=t.range.fromA&&a.toA>=t.range.toA?(this.forward(a.fromA,t.range.fromA,t.range.fromA<t.range.toA?1:-1),this.emit(i,t.range.fromB),this.builder.flushBuffer(),this.cache.clear(),this.builder.addComposition(t,n),this.text.skip(t.range.toB-t.range.fromB),this.forward(t.range.fromA,a.toA),this.emit(t.range.toB,a.toB)):(this.forward(a.fromA,a.toA),this.emit(i,a.toB)),i=a.toB,r=a.toA}return this.builder.curLine&&this.builder.endLine(),this.builder.root}preserve(e,t,n){let r=Gt(this.old),i=this.openMarks;this.old.advance(e,n?1:-1,{skip:(e,t,n)=>{if(e.isWidget())if(this.openWidget)this.builder.continueWidget(n-t);else{let o=n>0||t<e.length?Rt.of(e.widget,this.view,n-t,496&e.flags,this.cache.maybeReuse(e)):this.cache.reuse(e);256&o.flags?(o.flags&=-2,this.builder.addBlockWidget(o)):(this.builder.ensureLine(null),this.builder.addInlineWidget(o,r,i),i=r.length)}else if(e.isText())this.builder.ensureLine(null),t||n!=e.length||this.cache.reused.has(e)?(this.cache.add(e),this.builder.addText(e.text.slice(t,n),r,i)):this.builder.addText(e.text,r,i,this.cache.reuse(e)),i=r.length;else if(e.isLine())e.flags&=-2,this.cache.reused.set(e,1),this.builder.addLine(e);else if(e instanceof Nt)this.cache.add(e);else{if(!(e instanceof At))return!1;this.builder.ensureLine(null),this.builder.addMark(e,r,i),this.cache.reused.set(e,1),i=r.length}this.openWidget=!1},enter:e=>{e.isLine()?this.builder.addLineStart(e.attrs,this.cache.maybeReuse(e)):(this.cache.add(e),e instanceof At&&r.unshift(e.mark)),this.openWidget=!1},leave:e=>{e.isLine()?r.length&&(r.length=i=0):e instanceof At&&(r.shift(),i=Math.min(i,r.length))},break:()=>{this.builder.addBreak(),this.openWidget=!1}}),this.text.skip(e)}emit(e,t){let n=null,i=this.builder,o=-1,a=r.RangeSet.spans(this.decorations,e,t,{point:(e,t,r,a,s,l)=>{if(r instanceof B){if(this.disallowBlockEffectsFor[l]){if(r.block)throw new RangeError("Block decorations may not be specified via plugins");if(t>this.view.state.doc.lineAt(e).to)throw new RangeError("Decorations that replace line breaks may not be specified via plugins")}if(o=a.length,s>a.length)i.continueWidget(t-e);else{let o=r.widget||(r.block?qt.block:qt.inline),l=Ft(r),c=this.cache.findWidget(o,t-e,l)||Rt.of(o,this.view,t-e,l);r.block?(r.startSide>0&&i.addLineStartIfNotCovered(n),i.addBlockWidget(c)):(i.ensureLine(n),i.addInlineWidget(c,a,s))}n=null}else n=Ut(n,r);t>e&&this.text.skip(t-e)},span:(e,t,r,a)=>{for(let o=e;o<t;){let s=this.text.next(Math.min(512,t-o));null==s?(i.addLineStartIfNotCovered(n),i.addBreak(),o++):(i.ensureLine(n),i.addText(s,r,o==e?a:r.length),o+=s.length),n=null}o=r.length}});o>-1&&(this.openWidget=a>o),this.openWidget||i.addLineStartIfNotCovered(n),this.openMarks=a}forward(e,t,n=1){t-e<=10?this.old.advance(t-e,n,this.reuseWalker):(this.old.advance(5,-1,this.reuseWalker),this.old.advance(t-e-10,-1),this.old.advance(5,n,this.reuseWalker))}getCompositionContext(e){let t=[],n=null;for(let r=e.parentNode;;r=r.parentNode){let e=wt.get(r);if(r==this.view.contentDOM)break;e instanceof At?t.push(e):(null===e||void 0===e?void 0:e.isLine())?n=e:e instanceof xt||("DIV"!=r.nodeName||n?n||t.push(At.of(new D({tagName:r.nodeName.toLowerCase(),attributes:N(r)}),r)):n=new _t(r,jt))}return n?{line:n,marks:t}:null}}function Vt(e,t){let n=e=>{for(let r of e.children)if((t?r.isText():r.length)||n(r))return!0;return!1};return n(e)}function Ft(e){let t=e.isReplace?(e.startSide<0?64:0)|(e.endSide>0?128:0):e.startSide>0?32:16;return e.block&&(t|=256),t}const jt={class:"cm-line"};function Ut(e,t){let n=t.spec.attributes,r=t.spec.class;return n||r?(e||(e={class:"cm-line"}),n&&k(n,e),r&&(e.class+=" "+r),e):e}function Gt(e){let t=[];for(let n=e.parents.length;n>1;n--){let r=n==e.parents.length?e.tile:e.parents[n].tile;r instanceof At&&t.push(r.mark)}return t}function Ht(e){let t=wt.get(e);return t&&t.setDOM(e.cloneNode()),e}class qt extends P{constructor(e){super(),this.tag=e}eq(e){return e.tag==this.tag}toDOM(){return document.createElement(this.tag)}updateDOM(e){return e.nodeName.toLowerCase()==this.tag}get isHidden(){return!0}}qt.inline=new qt("span"),qt.block=new qt("div");const Qt=new class extends P{toDOM(){return document.createElement("br")}get isHidden(){return!0}get editable(){return!0}};class zt{constructor(e){this.view=e,this.decorations=[],this.blockWrappers=[],this.dynamicDecorationMap=[!1],this.domChanged=null,this.hasComposition=null,this.editContextFormatting=M.none,this.lastCompositionAfterCursor=!1,this.minWidth=0,this.minWidthFrom=0,this.minWidthTo=0,this.impreciseAnchor=null,this.impreciseHead=null,this.forceSelection=!1,this.lastUpdate=Date.now(),this.updateDeco(),this.tile=new Et(e,e.contentDOM),this.updateInner([new vt(0,0,0,e.state.doc.length)],null)}update(e){var t;let n=e.changedRanges;this.minWidth>0&&n.length&&(n.every(({fromA:e,toA:t})=>t<this.minWidthFrom||e>this.minWidthTo)?(this.minWidthFrom=e.changes.mapPos(this.minWidthFrom,1),this.minWidthTo=e.changes.mapPos(this.minWidthTo,1)):this.minWidth=this.minWidthFrom=this.minWidthTo=0),this.updateEditContextFormatting(e);let r=-1;this.view.inputState.composing>=0&&!this.view.observer.editContext&&((null===(t=this.domChanged)||void 0===t?void 0:t.newSel)?r=this.domChanged.newSel.head:on(e.changes,this.hasComposition)||e.selectionSet||(r=e.state.selection.main.head));let i=r>-1?Yt(this.view,e.changes,r):null;if(this.domChanged=null,this.hasComposition){let{from:t,to:r}=this.hasComposition;n=new vt(t,r,e.changes.mapPos(t,-1),e.changes.mapPos(r,1)).addToSet(n.slice())}this.hasComposition=i?{from:i.range.fromB,to:i.range.toB}:null,(_.ie||_.chrome)&&!i&&e&&e.state.doc.lines!=e.startState.doc.lines&&(this.forceSelection=!0);let o=this.decorations,a=this.blockWrappers;this.updateDeco();let s=en(o,this.decorations,e.changes);s.length&&(n=vt.extendWithRanges(n,s));let l=nn(a,this.blockWrappers,e.changes);return l.length&&(n=vt.extendWithRanges(n,l)),i&&!n.some(e=>e.fromA<=i.range.fromA&&e.toA>=i.range.toA)&&(n=i.range.addToSet(n.slice())),!(2&this.tile.flags&&0==n.length)&&(this.updateInner(n,i),e.transactions.length&&(this.lastUpdate=Date.now()),!0)}updateInner(e,t){this.view.viewState.mustMeasureContent=!0;let{observer:n}=this.view;n.ignore(()=>{if(t||e.length){let n=this.tile,r=new $t(this.view,n,this.blockWrappers,this.decorations,this.dynamicDecorationMap);t&&wt.get(t.text)&&r.cache.reused.set(wt.get(t.text),2),this.tile=r.run(e,t),Kt(n,r.cache.reused)}this.tile.dom.style.height=this.view.viewState.contentHeight/this.view.scaleY+"px",this.tile.dom.style.flexBasis=this.minWidth?this.minWidth+"px":"";let r=_.chrome||_.ios?{node:n.selectionRange.focusNode,written:!1}:void 0;this.tile.sync(r),!r||!r.written&&n.selectionRange.focusNode==r.node&&this.tile.dom.contains(r.node)||(this.forceSelection=!0),this.tile.dom.style.height=""});let r=[];if(this.view.viewport.from||this.view.viewport.to<this.view.state.doc.length)for(let i of this.tile.children)i.isWidget()&&i.widget instanceof an&&r.push(i.dom);n.updateGaps(r)}updateEditContextFormatting(e){this.editContextFormatting=this.editContextFormatting.map(e.changes);for(let t of e.transactions)for(let e of t.effects)e.is(Je)&&(this.editContextFormatting=e.value)}updateSelection(e=!1,t=!1){!e&&this.view.observer.selectionRange.focusNode||this.view.observer.readSelectionRange();let{dom:n}=this.tile,r=this.view.root.activeElement,i=r==n,o=!i&&!(this.view.state.facet(tt)||n.tabIndex>-1)&&H(n,this.view.observer.selectionRange)&&!(r&&n.contains(r));if(!(i||t||o))return;let a=this.forceSelection;this.forceSelection=!1;let s,l,c=this.view.state.selection.main;if(c.empty?l=s=this.inlineDOMNearPos(c.anchor,c.assoc||1):(l=this.inlineDOMNearPos(c.head,c.head==c.from?1:-1),s=this.inlineDOMNearPos(c.anchor,c.anchor==c.from?1:-1)),_.gecko&&c.empty&&!this.hasComposition&&Wt(s)){let e=document.createTextNode("");this.view.observer.ignore(()=>s.node.insertBefore(e,s.node.childNodes[s.offset]||null)),s=l=new me(e,0),a=!0}let u=this.view.observer.selectionRange;!a&&u.focusNode&&(Q(s.node,s.offset,u.anchorNode,u.anchorOffset)&&Q(l.node,l.offset,u.focusNode,u.focusOffset)||this.suppressWidgetCursorChange(u,c))||(this.view.observer.ignore(()=>{_.android&&_.chrome&&n.contains(u.focusNode)&&rn(u.focusNode,n)&&(n.blur(),n.focus({preventScroll:!0}));let e=U(this.view.root);if(e)if(c.empty){if(_.gecko){let e=Zt(s.node,s.offset);if(e&&3!=e){let t=(1==e?pe:fe)(s.node,s.offset);t&&(s=new me(t.node,t.offset))}}e.collapse(s.node,s.offset),null!=c.bidiLevel&&void 0!==e.caretBidiLevel&&(e.caretBidiLevel=c.bidiLevel)}else if(e.extend){e.collapse(s.node,s.offset);try{e.extend(l.node,l.offset)}catch(t){}}else{let t=document.createRange();c.anchor>c.head&&([s,l]=[l,s]),t.setEnd(l.node,l.offset),t.setStart(s.node,s.offset),e.removeAllRanges(),e.addRange(t)}else;o&&this.view.root.activeElement==n&&(n.blur(),r&&r.focus())}),this.view.observer.setSelectionRange(s,l)),this.impreciseAnchor=s.precise?null:new me(u.anchorNode,u.anchorOffset),this.impreciseHead=l.precise?null:new me(u.focusNode,u.focusOffset)}suppressWidgetCursorChange(e,t){return this.hasComposition&&t.empty&&Q(e.focusNode,e.focusOffset,e.anchorNode,e.anchorOffset)&&this.posFromDOM(e.focusNode,e.focusOffset)==t.head}enforceCursorAssoc(){if(this.hasComposition)return;let{view:e}=this,t=e.state.selection.main,n=U(e.root),{anchorNode:r,anchorOffset:i}=e.observer.selectionRange;if(!n||!t.empty||!t.assoc||!n.modify)return;let o=this.lineAt(t.head,t.assoc);if(!o)return;let a=o.posAtStart;if(t.head==a||t.head==a+o.length)return;let s=this.coordsAt(t.head,-1),l=this.coordsAt(t.head,1);if(!s||!l||s.bottom>l.top)return;let c=this.domAtPos(t.head+t.assoc,t.assoc);n.collapse(c.node,c.offset),n.modify("move",t.assoc<0?"forward":"backward","lineboundary"),e.observer.readSelectionRange();let u=e.observer.selectionRange;e.docView.posFromDOM(u.anchorNode,u.anchorOffset)!=t.from&&n.collapse(r,i)}posFromDOM(e,t){let n=this.tile.nearest(e);if(!n)return 2&this.tile.dom.compareDocumentPosition(e)?0:this.view.state.doc.length;let r=n.posAtStart;if(!n.isComposite())return n.isText()?e==n.dom?r+t:r+(t?n.length:0):r;{let i;if(e==n.dom)i=n.dom.childNodes[t];else{let r=0==X(e)?0:0==t?-1:1;for(;;){let t=e.parentNode;if(t==n.dom)break;0==r&&t.firstChild!=t.lastChild&&(r=e==t.firstChild?-1:1),e=t}i=r<0?e:e.nextSibling}if(i==n.dom.firstChild)return r;while(i&&!wt.get(i))i=i.nextSibling;if(!i)return r+n.length;for(let e=0,t=r;;e++){let r=n.children[e];if(r.dom==i)return t;t+=r.length+r.breakAfter}}}domAtPos(e,t){let{tile:n,offset:r}=this.tile.resolveBlock(e,t);return n.isWidget()?n.domPosFor(r,t):n.domIn(r,t)}inlineDOMNearPos(e,t){let n,r,i=-1,o=!1,a=-1,s=!1;return this.tile.blockTiles((t,l)=>{if(t.isWidget()){if(32&t.flags&&l>=e)return!0;16&t.flags&&(o=!0)}else{let c=l+t.length;if(l<=e&&(n=t,i=e-l,o=c<e),c>=e&&!r&&(r=t,a=e-l,s=l>e),l>e&&r)return!0}}),n||r?(o&&r?n=null:s&&n&&(r=null),n&&t<0||!r?n.domIn(i,t):r.domIn(a,t)):this.domAtPos(e,t)}coordsAt(e,t,n){let{tile:r,offset:i}=this.tile.resolveBlock(e,t);return r.isWidget()?r.widget instanceof an?null:r.coordsInWidget(i,t,!0):r.coordsIn(i,t,n)}lineAt(e,t){let{tile:n}=this.tile.resolveBlock(e,t);return n.isLine()?n:null}coordsForChar(e){let{tile:t,offset:n}=this.tile.resolveBlock(e,1);if(!t.isLine())return null;function i(e,t){if(e.isComposite())for(let n of e.children){if(n.length>=t){let e=i(n,t);if(e)return e}if(t-=n.length,t<0)break}else if(e.isText()&&t<e.length){let n=(0,r.findClusterBreak)(e.text,t);if(n==t)return null;let i=le(e.dom,t,n).getClientRects();for(let e=0;e<i.length;e++){let t=i[e];if(e==i.length-1||t.top<t.bottom&&t.left<t.right)return t}}return null}return i(t,n)}measureVisibleLineHeights(e){let t=[],{from:n,to:r}=e,i=this.view.contentDOM.clientWidth,o=i>Math.max(this.view.scrollDOM.clientWidth,this.minWidth)+1,a=-1,s=this.view.textDirection==ge.LTR,l=0,c=(e,u,d)=>{for(let h=0;h<e.children.length;h++){if(u>r)break;let p=e.children[h],f=u+p.length,m=p.dom.getBoundingClientRect(),{height:g}=m;if(d&&!h&&(l+=m.top-d.top),p instanceof xt)f>n&&c(p,u,m);else if(u>=n&&(l>0&&t.push(-l),t.push(g+l),l=0,o)){let e=p.dom.lastChild,t=e?q(e):[];if(t.length){let e=t[t.length-1],n=s?e.right-m.left:m.right-e.left;n>a&&(a=n,this.minWidth=i,this.minWidthFrom=u,this.minWidthTo=f)}}d&&h==e.children.length-1&&(l+=d.bottom-m.bottom),u=f+p.breakAfter}};return c(this.tile,0,null),t}textDirectionAt(e){let{tile:t}=this.tile.resolveBlock(e,1);return"rtl"==getComputedStyle(t.dom).direction?ge.RTL:ge.LTR}measureTextSize(){let e=this.tile.blockTiles(e=>{if(e.isLine()&&e.children.length&&e.length<=20){let t,n=0;for(let r of e.children){if(!r.isText()||/[^ -~]/.test(r.text))return;let e=q(r.dom);if(1!=e.length)return;n+=e[0].width,t=e[0].height}if(n)return{lineHeight:e.dom.getBoundingClientRect().height,charWidth:n/e.length,textHeight:t}}});if(e)return e;let t,n,r,i=document.createElement("div");return i.className="cm-line",i.style.width="99999px",i.style.position="absolute",i.textContent="abc def ghi jkl mno pqr stu",this.view.observer.ignore(()=>{this.tile.dom.appendChild(i);let e=q(i.firstChild)[0];t=i.getBoundingClientRect().height,n=e&&e.width?e.width/27:7,r=e&&e.height?e.height:t,i.remove()}),{lineHeight:t,charWidth:n,textHeight:r}}computeBlockGapDeco(){let e=[],t=this.view.viewState;for(let n=0,r=0;;r++){let i=r==t.viewports.length?null:t.viewports[r],o=i?i.from-1:this.view.state.doc.length;if(o>n){let r=(t.lineBlockAt(o).bottom-t.lineBlockAt(n).top)/this.view.scaleY;e.push(M.replace({widget:new an(r),block:!0,inclusive:!0,isBlockGap:!0}).range(n,o))}if(!i)break;n=i.to+1}return M.set(e)}updateDeco(){let e=1,t=this.view.state.facet(lt).map(t=>{let n=this.dynamicDecorationMap[e++]="function"==typeof t;return n?t(this.view):t}),n=!1,i=this.view.state.facet(ut).map((e,t)=>{let r="function"==typeof e;return r&&(n=!0),r?e(this.view):e});i.length&&(this.dynamicDecorationMap[e++]=n,t.push(r.RangeSet.join(i))),this.decorations=[this.editContextFormatting,...t,this.computeBlockGapDeco(),this.view.viewState.lineGapDeco];while(e<this.decorations.length)this.dynamicDecorationMap[e++]=!1;this.blockWrappers=this.view.state.facet(ct).map(e=>"function"==typeof e?e(this.view):e)}scrollIntoView(e){if(e.isSnapshot){let t=this.view.viewState.lineBlockAt(e.range.head);return this.view.scrollDOM.scrollTop=t.top-e.yMargin,void(this.view.scrollDOM.scrollLeft=e.xMargin)}for(let c of this.view.state.facet(Xe))try{if(c(this.view,e.range,e))return!0}catch(l){et(this.view.state,l,"scroll handler")}let t,{range:n}=e,r=this.coordsAt(n.head,n.assoc||(n.head>n.anchor?-1:1));if(!r)return;!n.empty&&(t=this.coordsAt(n.anchor,n.anchor>n.head?-1:1))&&(r={left:Math.min(r.left,t.left),top:Math.min(r.top,t.top),right:Math.max(r.right,t.right),bottom:Math.max(r.bottom,t.bottom)});let i=mt(this.view),o={left:r.left-i.left,top:r.top-i.top,right:r.right+i.right,bottom:r.bottom+i.bottom},{offsetWidth:a,offsetHeight:s}=this.view.scrollDOM;if(ee(this.view.scrollDOM,o,n.head<n.anchor?-1:1,e.x,e.y,Math.max(Math.min(e.xMargin,a),-a),Math.max(Math.min(e.yMargin,s),-s),this.view.textDirection==ge.LTR),window.visualViewport&&window.innerHeight-window.visualViewport.height>1&&(r.top>window.visualViewport.offsetTop+window.visualViewport.height||r.bottom<window.visualViewport.offsetTop)){let e=this.view.docView.lineAt(n.head,1);if(e){let t=re(e.dom);e.dom.scrollIntoView({block:"nearest"}),ie(t,!1)}}}lineHasWidget(e){let t=e=>e.isWidget()||e.children.some(t);return t(this.tile.resolveBlock(e,1).tile)}destroy(){Kt(this.tile)}}function Kt(e,t){let n=null===t||void 0===t?void 0:t.get(e);if(1!=n){null==n&&e.destroy();for(let n of e.children)Kt(n,t)}}function Wt(e){return 1==e.node.nodeType&&e.node.firstChild&&(0==e.offset||"false"==e.node.childNodes[e.offset-1].contentEditable)&&(e.offset==e.node.childNodes.length||"false"==e.node.childNodes[e.offset].contentEditable)}function Xt(e,t){let n=e.observer.selectionRange;if(!n.focusNode)return null;let r=pe(n.focusNode,n.focusOffset),i=fe(n.focusNode,n.focusOffset),o=r||i;if(i&&r&&i.node!=r.node){let t=wt.get(i.node);if(!t||t.isText()&&t.text!=i.node.nodeValue)o=i;else if(e.docView.lastCompositionAfterCursor){let e=wt.get(r.node);!e||e.isText()&&e.text!=r.node.nodeValue||(o=i)}}if(e.docView.lastCompositionAfterCursor=o!=r,!o)return null;let a=t-o.offset;return{from:a,to:a+o.node.nodeValue.length,node:o.node}}function Yt(e,t,n){let r=Xt(e,n);if(!r)return null;let{node:i,from:o,to:a}=r,s=i.nodeValue;if(/[\n\r]/.test(s))return null;if(e.state.doc.sliceString(r.from,r.to)!=s)return null;let l=t.invertedDesc;return{range:new vt(l.mapPos(o),l.mapPos(a),o,a),text:i}}function Zt(e,t){return 1!=e.nodeType?0:(t&&"false"==e.childNodes[t-1].contentEditable?1:0)|(t<e.childNodes.length&&"false"==e.childNodes[t].contentEditable?2:0)}let Jt=class{constructor(){this.changes=[]}compareRange(e,t){F(e,t,this.changes)}comparePoint(e,t){F(e,t,this.changes)}boundChange(e){F(e,e,this.changes)}};function en(e,t,n){let i=new Jt;return r.RangeSet.compare(e,t,n,i),i.changes}class tn{constructor(){this.changes=[]}compareRange(e,t){F(e,t,this.changes)}comparePoint(){}boundChange(e){F(e,e,this.changes)}}function nn(e,t,n){let i=new tn;return r.RangeSet.compare(e,t,n,i),i.changes}function rn(e,t){for(let n=e;n&&n!=t;n=n.assignedSlot||n.parentNode)if(1==n.nodeType&&"false"==n.contentEditable)return!0;return!1}function on(e,t){let n=!1;return t&&e.iterChangedRanges((e,r)=>{e<t.to&&r>t.from&&(n=!0)}),n}class an extends P{constructor(e){super(),this.height=e}toDOM(){let e=document.createElement("div");return e.className="cm-gap",this.updateDOM(e),e}eq(e){return e.height==this.height}updateDOM(e){return e.style.height=this.height+"px",!0}get editable(){return!0}get estimatedHeight(){return this.height}ignoreEvent(){return!1}}function sn(e,t,n=1){let i=e.charCategorizer(t),o=e.doc.lineAt(t),a=t-o.from;if(0==o.length)return r.EditorSelection.cursor(t);0==a?n=1:a==o.length&&(n=-1);let s=a,l=a;n<0?s=(0,r.findClusterBreak)(o.text,a,!1):l=(0,r.findClusterBreak)(o.text,a);let c=i(o.text.slice(s,l));while(s>0){let e=(0,r.findClusterBreak)(o.text,s,!1);if(i(o.text.slice(e,s))!=c)break;s=e}while(l<o.length){let e=(0,r.findClusterBreak)(o.text,l);if(i(o.text.slice(l,e))!=c)break;l=e}return r.EditorSelection.undirectionalRange(s+o.from,l+o.from)}function ln(e,t,n,i,o){let a=Math.round((i-t.left)*e.defaultCharacterWidth);if(e.lineWrapping&&n.height>1.5*e.defaultLineHeight){let t=e.viewState.heightOracle.textHeight,r=Math.floor((o-n.top-.5*(e.defaultLineHeight-t))/t);a+=r*e.viewState.heightOracle.lineLength}let s=e.state.sliceDoc(n.from,n.to);return n.from+(0,r.findColumn)(s,a,e.state.tabSize)}function cn(e,t,n){let r=e.lineBlockAt(t);if(Array.isArray(r.type)){let e;for(let i of r.type){if(i.from>t)break;if(!(i.to<t)){if(i.from<t&&i.to>t)return i;e&&(i.type!=I.Text||e.type==i.type&&!(n<0?i.from<t:i.to>t))||(e=i)}}return e||r}return r}function un(e,t,n,i){let o=cn(e,t.head,t.assoc||-1),a=i&&o.type==I.Text&&(e.lineWrapping||o.widgetLineBreaks)?e.coordsAtPos(t.assoc<0&&t.head>o.from?t.head-1:t.head):null;if(a){let t=e.dom.getBoundingClientRect(),i=e.textDirectionAt(o.from),s=e.posAtCoords({x:n==(i==ge.LTR)?t.right-1:t.left+1,y:(a.top+a.bottom)/2});if(null!=s)return r.EditorSelection.cursor(s,n?-1:1)}return r.EditorSelection.cursor(n?o.to:o.from,n?-1:1)}function dn(e,t,n,i){let o=e.state.doc.lineAt(t.head),a=e.bidiSpans(o),s=e.textDirectionAt(o.from);for(let l=t,c=null;;){let t=Be(o,a,s,l,n),u=Le;if(!t){if(o.number==(n?e.state.doc.lines:1))return l;u="\n",o=e.state.doc.line(o.number+(n?1:-1)),a=e.bidiSpans(o),t=n?r.EditorSelection.cursor(o.from,-1):r.EditorSelection.cursor(o.to,1)}if(c){if(!c(u))return l}else{if(!i)return t;c=i(u)}l=t}}function hn(e,t,n){let i=e.state.charCategorizer(t),o=i(n);return e=>{let t=i(e);return o==r.CharCategory.Space&&(o=t),o==t}}function pn(e,t,n,i){let o=t.head,a=n?1:-1;if(o==(n?e.state.doc.length:0))return r.EditorSelection.cursor(o,t.assoc);let s,l=t.goalColumn,c=e.contentDOM.getBoundingClientRect(),u=e.coordsAtPos(o,t.assoc||((t.empty?n:t.head==t.from)?1:-1)),d=e.documentTop;if(u)null==l&&(l=u.left-c.left),s=a<0?u.top:u.bottom;else{let t=e.viewState.lineBlockAt(o);null==l&&(l=Math.min(c.right-c.left,e.defaultCharacterWidth*(o-t.from))),s=(a<0?t.top:t.bottom)+d}let h=c.left+l,p=e.viewState.heightOracle.textHeight>>1,f=null!==i&&void 0!==i?i:p;for(let m=0;;m+=p){let t=s+(f+m)*a,i=bn(e,{x:h,y:t},!1,a);if(n?t>c.bottom:t<c.top)return r.EditorSelection.cursor(i.pos,i.assoc);let o=e.coordsAtPos(i.pos,i.assoc),u=o?(o.top+o.bottom)/2:0;if(!o||(n?u>s:u<s))return r.EditorSelection.cursor(i.pos,i.assoc,void 0,l)}}function fn(e,t,n){for(;;){let r=0;for(let i of e)i.between(t-1,t+1,(e,i,o)=>{if(t>e&&t<i){let o=r||n||(t-e<i-t?-1:1);t=o<0?e:i,r=o}});if(!r)return t}}function mn(e,t){let n=null;for(let i=0;i<t.ranges.length;i++){let o=t.ranges[i],a=null;if(o.empty){let t=fn(e,o.from,0);t!=o.from&&(a=r.EditorSelection.cursor(t,-1))}else{let t=fn(e,o.from,-1),n=fn(e,o.to,1);t==o.from&&n==o.to||(a=o.undirectional?r.EditorSelection.undirectionalRange(o.from,o.to):r.EditorSelection.range(o.from==o.anchor?t:n,o.from==o.head?t:n))}a&&(n||(n=t.ranges.slice()),n[i]=a)}return n?r.EditorSelection.create(n,t.mainIndex):t}function gn(e,t,n){let i=fn(e.state.facet(dt).map(t=>t(e)),n.from,t.head>n.from?-1:1);return i==n.from?n:r.EditorSelection.cursor(i,i<n.from?1:-1)}class vn{constructor(e,t){this.pos=e,this.assoc=t}}function bn(e,t,n,r){let i,o=e.contentDOM.getBoundingClientRect(),a=o.top+e.viewState.paddingTop,{x:s,y:l}=t,c=l-a;for(;;){if(c<0)return new vn(0,1);if(c>e.viewState.docHeight)return new vn(e.state.doc.length,-1);if(i=e.elementAtHeight(c),null==r)break;if(i.type==I.Text){if(r<0?i.to<e.viewport.from:i.from>e.viewport.to)break;let t=e.docView.coordsAt(r<0?i.from:i.to,r>0?-1:1);if(t&&(r<0?t.top<=c+a:t.bottom>=c+a))break}let t=e.viewState.heightOracle.textHeight/2;c=r>0?i.bottom+t:i.top-t}if(e.viewport.from>=i.to||e.viewport.to<=i.from){if(n)return null;if(i.type==I.Text){let t=ln(e,o,i,s,l);return new vn(t,t==i.from?1:-1)}}if(i.type!=I.Text)return c<(i.top+i.bottom)/2?new vn(i.from,1):new vn(i.to,-1);let u=e.docView.lineAt(i.from,2);return u&&u.length==i.length||(u=e.docView.lineAt(i.from,-2)),new yn(e,s,l,e.textDirectionAt(i.from)).scanTile(u,i.from)}class yn{constructor(e,t,n,r){this.view=e,this.x=t,this.y=n,this.baseDir=r,this.line=null,this.spans=null}bidiSpansAt(e){return(!this.line||this.line.from>e||this.line.to<e)&&(this.line=this.view.state.doc.lineAt(e),this.spans=this.view.bidiSpans(this.line)),this}baseDirAt(e,t){let{line:n,spans:r}=this.bidiSpansAt(e),i=r[ke.find(r,e-n.from,-1,t)].level;return i==this.baseDir}dirAt(e,t){let{line:n,spans:r}=this.bidiSpansAt(e);return r[ke.find(r,e-n.from,-1,t)].dir}bidiIn(e,t){let{spans:n,line:r}=this.bidiSpansAt(e);return n.length>1||n.length&&(n[0].level!=this.baseDir||n[0].to+r.from<t)}scan(e,t,n=!1){let r,i,o,a=0,s=e.length-1,l=new Set,c=this.bidiIn(e[0],e[s]),u=-1,d=1e9;e:while(a<s){let n=s-a,h=a+s>>1;t:if(l.has(h)){for(let e=1;e<n;e++){let t=h+e;if(t>=s&&(t-=n),!l.has(t)){h=t;break t}}break e}l.add(h);let p=t(h),f=0;if(p)for(let e=0;e<p.length;e++){let t=p[e];if(!(0==t.width&&p.length>1))if(t.bottom<this.y)(!r||r.bottom<t.bottom)&&(r=t),f=1;else if(t.top>this.y)(!i||i.top>t.top)&&(i=t),f=-1;else{let e=t.left>this.x?this.x-t.left:t.right<this.x?this.x-t.right:0,n=Math.abs(e);n<d&&(u=h,d=n,o=t),e&&(f=e<0==(this.baseDir==ge.LTR)?-1:1)}}-1!=f||c&&!this.baseDirAt(e[h],1)?1!=f||c&&!this.baseDirAt(e[h+1],-1)||(a=h+1):s=h}if(!o){if(!i&&!r)return{i:0,after:!1};let n=r&&(!i||this.y-r.bottom<i.top-this.y)?r:i;return this.y=(n.top+n.bottom)/2,this.scan(e,t,!0)}if(d&&!n){let{top:n,bottom:a}=o;if(r&&r.bottom>(n+n+a)/3)return this.y=r.bottom-1,this.scan(e,t,!0);if(i&&i.top<(n+a+a)/3)return this.y=i.top+1,this.scan(e,t,!0)}let h=(c?this.dirAt(e[u],1):this.baseDir)==ge.LTR;return{i:u,after:this.x>(o.left+o.right)/2==h}}scanText(e,t){let n=[];for(let o=0;o<e.length;o=(0,r.findClusterBreak)(e.text,o))n.push(t+o);n.push(t+e.length);let i=this.scan(n,r=>{let i=n[r]-t,o=n[r+1]-t;return le(e.dom,i,o).getClientRects()});return i.after?new vn(n[i.i+1],-1):new vn(n[i.i],1)}scanTile(e,t){if(!e.length)return new vn(t,1);if(1==e.children.length){let n=e.children[0];if(n.isText())return this.scanText(n,t);if(n.isComposite())return this.scanTile(n,t)}let n=[t];for(let a=0,s=t;a<e.children.length;a++)n.push(s+=e.children[a].length);let r=this.scan(n,t=>{let n=e.children[t];return 48&n.flags?null:(1==n.dom.nodeType?n.dom:le(n.dom,0,n.length)).getClientRects()}),i=e.children[r.i],o=n[r.i];return i.isText()?this.scanText(i,o):i.isComposite()?this.scanTile(i,o):r.after?new vn(n[r.i+1],-1):new vn(o,1)}}const wn="";class On{constructor(e,t){this.points=e,this.view=t,this.text="",this.lineSeparator=t.state.facet(r.EditorState.lineSeparator)}append(e){this.text+=e}lineBreak(){this.text+=wn}readRange(e,t){if(!e)return this;let n=e.parentNode;for(let r=e;;){this.findPointBefore(n,r);let e=this.text.length;this.readNode(r);let i=wt.get(r),o=r.nextSibling;if(o==t){(null===i||void 0===i?void 0:i.breakAfter)&&!o&&n!=this.view.contentDOM&&this.lineBreak();break}let a=wt.get(o);(i&&a?i.breakAfter:(i?i.breakAfter:K(r))||K(o)&&("BR"!=r.nodeName||(null===i||void 0===i?void 0:i.isWidget()))&&this.text.length>e)&&!En(o,t)&&this.lineBreak(),r=o}return this.findPointBefore(n,t),this}readTextNode(e){let t=e.nodeValue;for(let n of this.points)n.node==e&&(n.pos=this.text.length+Math.min(n.offset,t.length));for(let n=0,r=this.lineSeparator?null:/\r\n?|\n/g;;){let i,o=-1,a=1;if(this.lineSeparator?(o=t.indexOf(this.lineSeparator,n),a=this.lineSeparator.length):(i=r.exec(t))&&(o=i.index,a=i[0].length),this.append(t.slice(n,o<0?t.length:o)),o<0)break;if(this.lineBreak(),a>1)for(let t of this.points)t.node==e&&t.pos>this.text.length&&(t.pos-=a-1);n=o+a}}readNode(e){let t=wt.get(e),n=t&&t.overrideDOMText;if(null!=n){this.findPointInside(e,n.length);for(let e=n.iter();!e.next().done;)e.lineBreak?this.lineBreak():this.append(e.value)}else 3==e.nodeType?this.readTextNode(e):"BR"==e.nodeName?e.nextSibling&&this.lineBreak():1==e.nodeType&&this.readRange(e.firstChild,null)}findPointBefore(e,t){for(let n of this.points)n.node==e&&e.childNodes[n.offset]==t&&(n.pos=this.text.length)}findPointInside(e,t){for(let n of this.points)(3==e.nodeType?n.node==e:e.contains(n.node))&&(n.pos=this.text.length+(Sn(e,n.node,n.offset)?t:0))}}function Sn(e,t,n){for(;;){if(!t||n<X(t))return!1;if(t==e)return!0;n=z(t)+1,t=t.parentNode}}function En(e,t){let n;for(;;e=e.nextSibling){if(e==t||!e)break;let r=wt.get(e);if(!(null===r||void 0===r?void 0:r.isWidget()))return!1;r&&(n||(n=[])).push(r)}if(n)for(let r of n){let e=r.overrideDOMText;if(null===e||void 0===e?void 0:e.length)return!1}return!0}class xn{constructor(e,t){this.node=e,this.offset=t,this.pos=-1}}class _n{constructor(e,t,n,i){this.typeOver=i,this.bounds=null,this.text="",this.domChanged=t>-1;let{impreciseHead:o,impreciseAnchor:a}=e.docView,s=e.state.selection;if(e.state.readOnly&&t>-1)this.newSel=null;else if(t>-1&&(this.bounds=kn(e.docView.tile,t,n,0))){let t=o||a?[]:Nn(e),n=new On(t,e);n.readRange(this.bounds.startDOM,this.bounds.endDOM),this.text=n.text,this.newSel=Pn(t,this.bounds.from)}else{let t=e.observer.selectionRange,n=o&&o.node==t.focusNode&&o.offset==t.focusOffset||!G(e.contentDOM,t.focusNode)?s.main.head:e.docView.posFromDOM(t.focusNode,t.focusOffset),i=a&&a.node==t.anchorNode&&a.offset==t.anchorOffset||!G(e.contentDOM,t.anchorNode)?s.main.anchor:e.docView.posFromDOM(t.anchorNode,t.anchorOffset),l=e.viewport;if((_.ios||_.chrome)&&n!=i&&Math.min(n,i)<=s.main.from&&Math.max(n,i)>=s.main.to&&(l.from>0||l.to<e.state.doc.length)){let t=Math.min(n,i),r=Math.max(n,i),o=l.from-t,a=l.to-r;0!=o&&1!=o&&0!=t||0!=a&&-1!=a&&r!=e.state.doc.length||(n=0,i=e.state.doc.length)}if(e.inputState.composing>-1&&s.ranges.length>1)this.newSel=s.replaceRange(r.EditorSelection.range(i,n));else if(e.lineWrapping&&i==n&&(!s.main.empty||s.main.head!=n)&&e.inputState.lastTouchTime>Date.now()-100){let t=e.coordsAtPos(n,-1),i=0;t&&(i=e.inputState.lastTouchY<=t.bottom?-1:1),this.newSel=r.EditorSelection.create([r.EditorSelection.cursor(n,i)])}else this.newSel=r.EditorSelection.single(i,n)}}}function kn(e,t,n,r){if(e.isComposite()){let i=-1,o=-1,a=-1,s=-1;for(let l=0,c=r,u=r;l<e.children.length;l++){let r=e.children[l],d=c+r.length;if(c<t&&d>n)return kn(r,t,n,c);if(d>=t&&-1==i&&(i=l,o=c),c>n&&r.dom.parentNode==e.dom){a=l,s=u;break}u=d,c=d+r.breakAfter}return{from:o,to:s<0?r+e.length:s,startDOM:(i?e.children[i-1].dom.nextSibling:null)||e.dom.firstChild,endDOM:a<e.children.length&&a>=0?e.children[a].dom:null}}return e.isText()?{from:r,to:r+e.length,startDOM:e.dom,endDOM:e.dom.nextSibling}:null}function Cn(e,t){let n,{newSel:i}=t,{state:o}=e,a=o.selection.main,s=e.inputState.lastKeyTime>Date.now()-100?e.inputState.lastKeyCode:-1;if(t.bounds){let{from:e,to:i}=t.bounds,l=a.from,c=null;(8===s||_.android&&t.text.length<i-e)&&(l=a.to,c="end");let u,d,h=o.doc.sliceString(e,i,wn);!a.empty&&a.from>=e&&a.to<=i&&(t.typeOver||h!=t.text)&&h.slice(0,a.from-e)==t.text.slice(0,a.from-e)&&h.slice(a.to-e)==t.text.slice(u=t.text.length-(h.length-(a.to-e)))?n={from:a.from,to:a.to,insert:r.Text.of(t.text.slice(a.from-e,u).split(wn))}:(d=Rn(h,t.text,l-e,c))&&(_.chrome&&13==s&&d.toB==d.from+2&&t.text.slice(d.from,d.toB)==wn+wn&&d.toB--,n={from:e+d.from,to:e+d.toA,insert:r.Text.of(t.text.slice(d.from,d.toB).split(wn))})}else i&&(!e.hasFocus&&o.facet(tt)||In(i,a))&&(i=null);if(!n&&!i)return!1;if((_.mac||_.android)&&n&&n.from==n.to&&n.from==a.head-1&&/^\. ?$/.test(n.insert.toString())&&"off"==e.contentDOM.getAttribute("autocorrect")?(i&&2==n.insert.length&&(i=r.EditorSelection.single(i.main.anchor-1,i.main.head-1)),n={from:n.from,to:n.to,insert:r.Text.of([n.insert.toString().replace("."," ")])}):o.doc.lineAt(a.from).to<a.to&&e.docView.lineHasWidget(a.to)&&e.inputState.insertingTextAt>Date.now()-50?n={from:a.from,to:a.to,insert:o.toText(e.inputState.insertingText)}:_.chrome&&n&&n.from==n.to&&n.from==a.head&&"\n "==n.insert.toString()&&e.lineWrapping&&(i&&(i=r.EditorSelection.single(i.main.anchor-1,i.main.head-1)),n={from:a.from,to:a.to,insert:r.Text.of([" "])}),n)return An(e,n,i,s);if(i&&!In(i,a)){let t=!1,n="select";return e.inputState.lastSelectionTime>Date.now()-50&&("select"==e.inputState.lastSelectionOrigin&&(t=!0),n=e.inputState.lastSelectionOrigin,"select.pointer"==n&&(i=mn(o.facet(dt).map(t=>t(e)),i))),e.dispatch({selection:i,scrollIntoView:t,userEvent:n}),!0}return!1}function An(e,t,n,r=-1){if(_.ios&&e.inputState.flushIOSKey(t))return!0;let i=e.state.selection.main;if(_.android&&(t.to==i.to&&(t.from==i.from||t.from==i.from-1&&" "==e.state.sliceDoc(t.from,i.from))&&1==t.insert.length&&2==t.insert.lines&&ce(e.contentDOM,"Enter",13)||(t.from==i.from-1&&t.to==i.to&&0==t.insert.length||8==r&&t.insert.length<t.to-t.from&&t.to>i.head)&&ce(e.contentDOM,"Backspace",8)||t.from==i.from&&t.to==i.to+1&&0==t.insert.length&&ce(e.contentDOM,"Delete",46)))return!0;let o,a=t.insert.toString();e.inputState.composing>=0&&e.inputState.composing++;let s=()=>o||(o=Tn(e,t,n));return e.state.facet(He).some(n=>n(e,t.from,t.to,a,s))||e.dispatch(s()),!0}function Tn(e,t,n){let i,o=e.state,a=o.selection.main,s=-1;if(t.from==t.to&&t.from<a.from||t.from>a.to){let n=t.from<a.from?-1:1,r=n<0?a.from:a.to,i=fn(o.facet(dt).map(t=>t(e)),r,n);t.from==i&&(s=i)}if(s>-1)i={changes:t,selection:r.EditorSelection.cursor(t.from+t.insert.length,-1)};else if(t.from>=a.from&&t.to<=a.to&&t.to-t.from>=(a.to-a.from)/3&&(!n||n.main.empty&&n.main.from==t.from+t.insert.length)&&e.inputState.composing<0){let n=a.from<t.from?o.sliceDoc(a.from,t.from):"",r=a.to>t.to?o.sliceDoc(t.to,a.to):"";i=o.replaceSelection(e.state.toText(n+t.insert.sliceString(0,void 0,e.state.lineBreak)+r))}else{let s=o.changes(t),l=n&&n.main.to<=s.newLength?n.main:void 0;if(o.selection.ranges.length>1&&(e.inputState.composing>=0||e.inputState.compositionPendingChange)&&t.to<=a.to+10&&t.to>=a.to-10){let c,u=e.state.sliceDoc(t.from,t.to),d=n&&Xt(e,n.main.head);if(d){let e=t.insert.length-(t.to-t.from);c={from:d.from,to:d.to-e}}else c=e.state.doc.lineAt(a.head);let h=a.to-t.to;i=o.changeByRange(n=>{if(n.from==a.from&&n.to==a.to)return{changes:s,range:l||n.map(s)};let i=n.to-h,d=i-u.length;if(e.state.sliceDoc(d,i)!=u||i>=c.from&&d<=c.to)return{range:n};let p=o.changes({from:d,to:i,insert:t.insert}),f=n.to-a.to;return{changes:p,range:l?r.EditorSelection.range(Math.max(0,l.anchor+f),Math.max(0,l.head+f)):n.map(p)}})}else i={changes:s,selection:l&&o.selection.replaceRange(l)}}let l="input.type";return(e.composing||e.inputState.compositionPendingChange&&e.inputState.compositionEndedAt>Date.now()-50)&&(e.inputState.compositionPendingChange=!1,l+=".compose",e.inputState.compositionFirstChange&&(l+=".start",e.inputState.compositionFirstChange=!1)),o.update(i,{userEvent:l,scrollIntoView:!0})}function Rn(e,t,n,r){let i=Math.min(e.length,t.length),o=0;while(o<i&&e.charCodeAt(o)==t.charCodeAt(o))o++;if(o==i&&e.length==t.length)return null;let a=e.length,s=t.length;while(a>0&&s>0&&e.charCodeAt(a-1)==t.charCodeAt(s-1))a--,s--;if("end"==r){let e=Math.max(0,o-Math.min(a,s));n-=a+e-o}if(a<o&&e.length<t.length){let e=n<=o&&n>=a?o-n:0;o-=e,s=o+(s-a),a=o}else if(s<o){let e=n<=o&&n>=s?o-n:0;o-=e,a=o+(a-s),s=o}return{from:o,toA:a,toB:s}}function Nn(e){let t=[];if(e.root.activeElement!=e.contentDOM)return t;let{anchorNode:n,anchorOffset:r,focusNode:i,focusOffset:o}=e.observer.selectionRange;return n&&(t.push(new xn(n,r)),i==n&&o==r||t.push(new xn(i,o))),t}function Pn(e,t){if(0==e.length)return null;let n=e[0].pos,i=2==e.length?e[1].pos:n;return n<0||i<0?null:n==i?r.EditorSelection.create([r.EditorSelection.cursor(i+t,-1)]):r.EditorSelection.single(n+t,i+t)}function In(e,t){return t.head==e.main.head&&t.anchor==e.main.anchor}class Mn{setSelectionOrigin(e){this.lastSelectionOrigin=e,this.lastSelectionTime=Date.now()}constructor(e){this.view=e,this.lastKeyCode=0,this.lastKeyTime=0,this.touchActive=!1,this.lastTouchTime=0,this.lastTouchX=0,this.lastTouchY=0,this.lastFocusTime=0,this.lastScrollTop=0,this.lastScrollLeft=0,this.lastWheelEvent=0,this.pendingIOSKey=void 0,this.lastIOSMomentumScroll=0,this.tabFocusMode=-1,this.lastSelectionOrigin=null,this.lastSelectionTime=0,this.lastContextMenu=0,this.scrollHandlers=[],this.handlers=Object.create(null),this.composing=-1,this.compositionFirstChange=null,this.compositionEndedAt=0,this.compositionPendingKey=!1,this.compositionPendingChange=!1,this.insertingText="",this.insertingTextAt=0,this.mouseSelection=null,this.draggedContent=null,this.handleEvent=this.handleEvent.bind(this),this.notifiedFocused=e.hasFocus,_.safari&&e.contentDOM.addEventListener("input",()=>null),_.gecko&&vr(e.contentDOM.ownerDocument)}handleEvent(e){Kn(this.view,e)&&!this.ignoreDuringComposition(e)&&("keydown"==e.type&&this.keydown(e)||(0!=this.view.updateState?Promise.resolve().then(()=>this.runHandlers(e.type,e)):this.runHandlers(e.type,e)))}runHandlers(e,t){let n=this.handlers[e];if(n){for(let e of n.observers)e(this.view,t);for(let e of n.handlers){if(t.defaultPrevented)break;if(e(this.view,t)){t.preventDefault();break}}}}ensureHandlers(e){let t=Bn(e),n=this.handlers,r=this.view.contentDOM;for(let i in t)if("scroll"!=i){let e=!t[i].handlers.length,o=n[i];o&&e!=!o.handlers.length&&(r.removeEventListener(i,this.handleEvent),o=null),o||r.addEventListener(i,this.handleEvent,{passive:e})}for(let i in n)"scroll"==i||t[i]||r.removeEventListener(i,this.handleEvent);this.handlers=t}keydown(e){if(this.lastKeyCode=e.keyCode,this.lastKeyTime=Date.now(),9==e.keyCode&&this.tabFocusMode>-1&&(!this.tabFocusMode||Date.now()<=this.tabFocusMode))return!0;if(this.tabFocusMode>0&&27!=e.keyCode&&Fn.indexOf(e.keyCode)<0&&(this.tabFocusMode=-1),_.android&&_.chrome&&!e.synthetic&&(13==e.keyCode||8==e.keyCode))return this.view.observer.delayAndroidKey(e.key,e.keyCode),!0;if(_.ios&&!e.synthetic&&!e.altKey&&!e.metaKey&&($n.some(t=>t.keyCode==e.keyCode)&&!e.ctrlKey||Vn.indexOf(e.key)>-1&&e.ctrlKey)){let t={ctrlKey:e.ctrlKey,altKey:e.altKey,metaKey:e.metaKey,shiftKey:e.shiftKey};t.shiftKey&&_.ios&&!/^(off|none)$/.test(this.view.contentDOM.autocapitalize)&&Dn(this.view.win)&&(t.shiftKey=!1);let n=this.pendingIOSKey={key:e.key,keyCode:e.keyCode,mods:t};return setTimeout(()=>{this.pendingIOSKey==n&&this.flushIOSKey()},50),!0}return 229!=e.keyCode&&this.view.observer.forceFlush(),!1}flushIOSKey(e){let t=this.pendingIOSKey;return!(!t||this.view.observer.pendingRecords().length)&&(!("Enter"==t.key&&e&&e.from<e.to&&/^\S+$/.test(e.insert.toString()))&&(this.pendingIOSKey=void 0,ce(this.view.contentDOM,t.key,t.keyCode,t.mods)))}ignoreDuringComposition(e){return!(!/^key/.test(e.type)||e.synthetic)&&(this.composing>0||!!(_.safari&&!_.ios&&this.compositionPendingKey&&Date.now()-this.compositionEndedAt<100)&&(this.compositionPendingKey=!1,!0))}startMouseSelection(e){this.mouseSelection&&this.mouseSelection.destroy(),this.mouseSelection=e}update(e){this.view.observer.update(e),this.mouseSelection&&this.mouseSelection.update(e),this.draggedContent&&e.docChanged&&(this.draggedContent=this.draggedContent.map(e.changes)),e.transactions.length&&(this.lastKeyCode=this.lastSelectionTime=0)}destroy(){this.mouseSelection&&this.mouseSelection.destroy()}}function Dn(e){return!!e.visualViewport&&e.visualViewport.height*e.visualViewport.scale/e.document.documentElement.clientHeight<.85}function Ln(e,t){return(n,r)=>{try{return t.call(e,r,n)}catch(i){et(n.state,i)}}}function Bn(e){let t=Object.create(null);function n(e){return t[e]||(t[e]={observers:[],handlers:[]})}for(let r of e){let e=r.spec,t=e&&e.plugin.domEventHandlers,i=e&&e.plugin.domEventObservers;if(t)for(let o in t){let e=t[o];e&&n(o).handlers.push(Ln(r.value,e))}if(i)for(let o in i){let e=i[o];e&&n(o).observers.push(Ln(r.value,e))}}for(let r in Wn)n(r).handlers.push(Wn[r]);for(let r in Xn)n(r).observers.push(Xn[r]);return t}const $n=[{key:"Backspace",keyCode:8,inputType:"deleteContentBackward"},{key:"Enter",keyCode:13,inputType:"insertParagraph"},{key:"Enter",keyCode:13,inputType:"insertLineBreak"},{key:"Delete",keyCode:46,inputType:"deleteContentForward"}],Vn="dthko",Fn=[16,17,18,20,91,92,224,225],jn=6;function Un(e){return.7*Math.max(0,e)+8}function Gn(e,t){return Math.max(Math.abs(e.clientX-t.clientX),Math.abs(e.clientY-t.clientY))}class Hn{constructor(e,t,n,i){this.view=e,this.startEvent=t,this.style=n,this.mustSelect=i,this.scrollSpeed={x:0,y:0},this.scrolling=-1,this.lastEvent=t,this.scrollParents=te(e.contentDOM),this.atoms=e.state.facet(dt).map(t=>t(e));let o=e.contentDOM.ownerDocument;o.addEventListener("mousemove",this.move=this.move.bind(this)),o.addEventListener("mouseup",this.up=this.up.bind(this)),this.extend=t.shiftKey,this.multiple=e.state.facet(r.EditorState.allowMultipleSelections)&&qn(e,t),this.dragging=!(!zn(e,t)||1!=ar(t))&&null}start(e){!1===this.dragging&&this.select(e)}move(e){if(0==e.buttons)return this.destroy();if(this.dragging||null==this.dragging&&Gn(this.startEvent,e)<10)return;this.select(this.lastEvent=e);let t=0,n=0,r=0,i=0,o=this.view.win.innerWidth,a=this.view.win.innerHeight;this.scrollParents.x&&({left:r,right:o}=this.scrollParents.x.getBoundingClientRect()),this.scrollParents.y&&({top:i,bottom:a}=this.scrollParents.y.getBoundingClientRect());let s=mt(this.view);e.clientX-s.left<=r+jn?t=-Un(r-e.clientX):e.clientX+s.right>=o-jn&&(t=Un(e.clientX-o)),e.clientY-s.top<=i+jn?n=-Un(i-e.clientY):e.clientY+s.bottom>=a-jn&&(n=Un(e.clientY-a)),this.setScrollSpeed(t,n)}up(e){null==this.dragging&&this.select(this.lastEvent),this.dragging||e.preventDefault(),this.destroy()}destroy(){this.setScrollSpeed(0,0);let e=this.view.contentDOM.ownerDocument;e.removeEventListener("mousemove",this.move),e.removeEventListener("mouseup",this.up),this.view.inputState.mouseSelection=this.view.inputState.draggedContent=null}setScrollSpeed(e,t){this.scrollSpeed={x:e,y:t},e||t?this.scrolling<0&&(this.scrolling=setInterval(()=>this.scroll(),50)):this.scrolling>-1&&(clearInterval(this.scrolling),this.scrolling=-1)}scroll(){let{x:e,y:t}=this.scrollSpeed;e&&this.scrollParents.x&&(this.scrollParents.x.scrollLeft+=e,e=0),t&&this.scrollParents.y&&(this.scrollParents.y.scrollTop+=t,t=0),(e||t)&&this.view.win.scrollBy(e,t),!1===this.dragging&&this.select(this.lastEvent)}select(e){let{view:t}=this,n=mn(this.atoms,this.style.get(e,this.extend,this.multiple));!this.mustSelect&&n.eq(t.state.selection,!1===this.dragging)||this.view.dispatch({selection:n,userEvent:"select.pointer"}),this.mustSelect=!1}update(e){e.transactions.some(e=>e.isUserEvent("input.type"))?this.destroy():this.style.update(e)&&setTimeout(()=>this.select(this.lastEvent),20)}}function qn(e,t){let n=e.state.facet(Ve);return n.length?n[0](t):_.mac?t.metaKey:t.ctrlKey}function Qn(e,t){let n=e.state.facet(Fe);return n.length?n[0](t):_.mac?!t.altKey:!t.ctrlKey}function zn(e,t){let{main:n}=e.state.selection;if(n.empty)return!1;let r=U(e.root);if(!r||0==r.rangeCount)return!0;let i=r.getRangeAt(0).getClientRects();for(let o=0;o<i.length;o++){let e=i[o];if(e.left<=t.clientX&&e.right>=t.clientX&&e.top<=t.clientY&&e.bottom>=t.clientY)return!0}return!1}function Kn(e,t){if(!t.bubbles)return!0;if(t.defaultPrevented)return!1;for(let n,r=t.target;r!=e.contentDOM;r=r.parentNode)if(!r||11==r.nodeType||(n=wt.get(r))&&n.isWidget()&&!n.isHidden&&n.widget.ignoreEvent(t))return!1;return!0}const Wn=Object.create(null),Xn=Object.create(null),Yn=_.ie&&_.ie_version<15||_.ios&&_.webkit_version<604;function Zn(e){let t=e.dom.parentNode;if(!t)return;let n=t.appendChild(document.createElement("textarea"));n.style.cssText="position: fixed; left: -10000px; top: 10px",n.focus(),setTimeout(()=>{e.focus(),n.remove(),er(e,n.value)},50)}function Jn(e,t,n){for(let r of e.facet(t))n=r(n,e);return n}function er(e,t){t=Jn(e.state,Qe,t);let n,{state:i}=e,o=1,a=i.toText(t),s=a.lines==i.selection.ranges.length,l=null!=hr&&i.selection.ranges.every(e=>e.empty)&&hr==a.toString();if(l){let e=-1;n=i.changeByRange(n=>{let l=i.doc.lineAt(n.from);if(l.from==e)return{range:n};e=l.from;let c=i.toText((s?a.line(o++).text:t)+i.lineBreak);return{changes:{from:l.from,insert:c},range:r.EditorSelection.cursor(n.from+c.length,-1)}})}else n=s?i.changeByRange(e=>{let t=a.line(o++);return{changes:{from:e.from,to:e.to,insert:t.text},range:r.EditorSelection.cursor(e.from+t.length,-1)}}):i.replaceSelection(a);e.dispatch(n,{userEvent:"input.paste",scrollIntoView:!0})}function tr(e,t,n,i){if(1==i)return r.EditorSelection.cursor(t,n);if(2==i)return sn(e.state,t,n);{let i=e.docView.lineAt(t,n),o=e.state.doc.lineAt(i?i.posAtEnd:t),a=i?i.posAtStart:o.from,s=i?i.posAtEnd:o.to;return s<e.state.doc.length&&s==o.to&&s++,r.EditorSelection.undirectionalRange(a,s)}}Xn.scroll=e=>{let t=e.inputState;t.lastScrollTop=e.scrollDOM.scrollTop,t.lastScrollLeft=e.scrollDOM.scrollLeft,_.ios&&!t.touchActive&&(t.lastIOSMomentumScroll=Date.now())},Xn.wheel=Xn.mousewheel=e=>{e.inputState.lastWheelEvent=Date.now()},Wn.keydown=(e,t)=>(e.inputState.setSelectionOrigin("select"),27==t.keyCode&&0!=e.inputState.tabFocusMode&&(e.inputState.tabFocusMode=Date.now()+2e3),!1),Xn.touchstart=(e,t)=>{let n=e.inputState,r=t.targetTouches[0];n.touchActive=!0,n.lastTouchTime=Date.now(),r&&(n.lastTouchX=r.clientX,n.lastTouchY=r.clientY),n.setSelectionOrigin("select.pointer")},Xn.touchmove=e=>{e.inputState.setSelectionOrigin("select.pointer")},Xn.touchend=(e,t)=>{e.inputState.touchActive=!1},Wn.mousedown=(e,t)=>{if(e.observer.flush(),e.inputState.lastTouchTime>Date.now()-2e3)return!1;let n=null;for(let r of e.state.facet(je))if(n=r(e,t),n)break;if(n||0!=t.button||(n=sr(e,t)),n){let r=!e.hasFocus;e.inputState.startMouseSelection(new Hn(e,t,n,r)),r&&e.observer.ignore(()=>{se(e.contentDOM);let t=e.root.activeElement;t&&!t.contains(e.contentDOM)&&t.blur()});let i=e.inputState.mouseSelection;if(i)return i.start(t),!1===i.dragging}else e.inputState.setSelectionOrigin("select.pointer");return!1};const nr=_.ie&&_.ie_version<=11;let rr=null,ir=0,or=0;function ar(e){if(!nr)return e.detail;let t=rr,n=or;return rr=e,or=Date.now(),ir=!t||n>Date.now()-400&&Math.abs(t.clientX-e.clientX)<2&&Math.abs(t.clientY-e.clientY)<2?(ir+1)%3:1}function sr(e,t){let n=e.posAndSideAtCoords({x:t.clientX,y:t.clientY},!1),i=ar(t),o=e.state.selection;return{update(e){e.docChanged&&(n.pos=e.changes.mapPos(n.pos),o=o.map(e.changes))},get(t,a,s){let l,c=e.posAndSideAtCoords({x:t.clientX,y:t.clientY},!1),u=tr(e,c.pos,c.assoc,i);if(n.pos!=c.pos&&!a){let t=tr(e,n.pos,n.assoc,i),o=Math.min(t.from,u.from),a=Math.max(t.to,u.to);u=o<u.from?r.EditorSelection.range(o,a,u.assoc):r.EditorSelection.range(a,o,u.assoc)}return a?o.replaceRange(o.main.extend(u.from,u.to,u.assoc)):s&&1==i&&o.ranges.length>1&&(l=lr(o,c.pos))?l:s?o.addRange(u):r.EditorSelection.create([u])}}}function lr(e,t){for(let n=0;n<e.ranges.length;n++){let{from:i,to:o}=e.ranges[n];if(i<=t&&o>=t)return r.EditorSelection.create(e.ranges.slice(0,n).concat(e.ranges.slice(n+1)),e.mainIndex==n?0:e.mainIndex-(e.mainIndex>n?1:0))}return null}function cr(e,t,n,r){if(n=Jn(e.state,Qe,n),!n)return;let i=e.posAtCoords({x:t.clientX,y:t.clientY},!1),{draggedContent:o}=e.inputState,a=r&&o&&Qn(e,t)?{from:o.from,to:o.to}:null,s={from:i,insert:n},l=e.state.changes(a?[a,s]:s);e.focus(),e.dispatch({changes:l,selection:{anchor:l.mapPos(i,-1),head:l.mapPos(i,1)},userEvent:a?"move.drop":"input.drop"}),e.inputState.draggedContent=null}function ur(e,t){let n=e.dom.parentNode;if(!n)return;let r=n.appendChild(document.createElement("textarea"));r.style.cssText="position: fixed; left: -10000px; top: 10px",r.value=t,r.focus(),r.selectionEnd=t.length,r.selectionStart=0,setTimeout(()=>{r.remove(),e.focus()},50)}function dr(e){let t=[],n=[],r=!1;for(let i of e.selection.ranges)i.empty||(t.push(e.sliceDoc(i.from,i.to)),n.push(i));if(!t.length){let i=-1;for(let{from:r}of e.selection.ranges){let o=e.doc.lineAt(r);o.number>i&&(t.push(o.text),n.push({from:o.from,to:Math.min(e.doc.length,o.to+1)})),i=o.number}r=!0}return{text:Jn(e,ze,t.join(e.lineBreak)),ranges:n,linewise:r}}Wn.dragstart=(e,t)=>{let{selection:{main:n}}=e.state;if(t.target.draggable){let i=e.docView.tile.nearest(t.target);if(i&&i.isWidget()){let e=i.posAtStart,t=e+i.length;(e>=n.to||t<=n.from)&&(n=r.EditorSelection.undirectionalRange(e,t))}}let{inputState:i}=e;return i.mouseSelection&&(i.mouseSelection.dragging=!0),i.draggedContent=n,t.dataTransfer&&(t.dataTransfer.setData("Text",Jn(e.state,ze,e.state.sliceDoc(n.from,n.to))),t.dataTransfer.effectAllowed="copyMove"),!1},Wn.dragend=e=>(e.inputState.draggedContent=null,!1),Wn.drop=(e,t)=>{if(!t.dataTransfer)return!1;if(e.state.readOnly)return!0;let n=t.dataTransfer.files;if(n&&n.length){let r=Array(n.length),i=0,o=()=>{++i==n.length&&cr(e,t,r.filter(e=>null!=e).join(e.state.lineBreak),!1)};for(let e=0;e<n.length;e++){let t=new FileReader;t.onerror=o,t.onload=()=>{/[\x00-\x08\x0e-\x1f]{2}/.test(t.result)||(r[e]=t.result),o()},t.readAsText(n[e])}return!0}{let n=t.dataTransfer.getData("Text");if(n)return cr(e,t,n,!0),!0}return!1},Wn.paste=(e,t)=>{if(e.state.readOnly)return!0;e.observer.flush();let n=Yn?null:t.clipboardData;return n?(er(e,n.getData("text/plain")||n.getData("text/uri-list")),!0):(Zn(e),!1)};let hr=null;Wn.copy=Wn.cut=(e,t)=>{if(!H(e.contentDOM,e.observer.selectionRange))return!1;let{text:n,ranges:r,linewise:i}=dr(e.state);if(!n&&!i)return!1;hr=i?n:null,"cut"!=t.type||e.state.readOnly||e.dispatch({changes:r,scrollIntoView:!0,userEvent:"delete.cut"});let o=Yn?null:t.clipboardData;return o?(o.clearData(),o.setData("text/plain",n),!0):(ur(e,n),!1)};const pr=r.Annotation.define();function fr(e,t){let n=[];for(let r of e.facet(qe)){let i=r(e,t);i&&n.push(i)}return n.length?e.update({effects:n,annotations:pr.of(!0)}):null}function mr(e){setTimeout(()=>{let t=e.hasFocus;if(t!=e.inputState.notifiedFocused){let n=fr(e.state,t);n?e.dispatch(n):e.update([])}},10)}Xn.focus=e=>{e.inputState.lastFocusTime=Date.now(),e.scrollDOM.scrollTop||!e.inputState.lastScrollTop&&!e.inputState.lastScrollLeft||(e.scrollDOM.scrollTop=e.inputState.lastScrollTop,e.scrollDOM.scrollLeft=e.inputState.lastScrollLeft),mr(e)},Xn.blur=e=>{e.observer.clearSelectionRange(),mr(e)},Xn.compositionstart=Xn.compositionupdate=e=>{if(!e.observer.editContext&&(null==e.inputState.compositionFirstChange&&(e.inputState.compositionFirstChange=!0),e.inputState.composing<0)){let{main:t}=e.state.selection;t.empty||e.lineBlockAt(t.from).from==e.lineBlockAt(t.to).from||e.dispatch({changes:e.state.selection.ranges.filter(e=>!e.empty).map(e=>({from:e.from,to:e.to})),userEvent:"input"}),e.inputState.composing=0}},Xn.compositionend=e=>{e.observer.editContext||(e.inputState.composing=-1,e.inputState.compositionEndedAt=Date.now(),e.inputState.compositionPendingKey=!0,e.inputState.compositionPendingChange=e.observer.pendingRecords().length>0,e.inputState.compositionFirstChange=null,_.chrome&&_.android?e.observer.flushSoon():e.inputState.compositionPendingChange?Promise.resolve().then(()=>e.observer.flush()):setTimeout(()=>{e.inputState.composing<0&&e.docView.hasComposition&&e.update([])},50))},Xn.contextmenu=e=>{e.inputState.lastContextMenu=Date.now()},Wn.beforeinput=(e,t)=>{var n,r;if("insertText"!=t.inputType&&"insertCompositionText"!=t.inputType||(e.inputState.insertingText=t.data,e.inputState.insertingTextAt=Date.now()),"insertReplacementText"==t.inputType&&e.observer.editContext){let r=null===(n=t.dataTransfer)||void 0===n?void 0:n.getData("text/plain"),i=t.getTargetRanges();if(r&&i.length){let t=i[0],n=e.posAtDOM(t.startContainer,t.startOffset),o=e.posAtDOM(t.endContainer,t.endOffset);return An(e,{from:n,to:o,insert:e.state.toText(r)},null),!0}}let i;if(_.chrome&&_.android&&(i=$n.find(e=>e.inputType==t.inputType))&&(e.observer.delayAndroidKey(i.key,i.keyCode),"Backspace"==i.key||"Delete"==i.key)){let t=(null===(r=window.visualViewport)||void 0===r?void 0:r.height)||0;setTimeout(()=>{var n;((null===(n=window.visualViewport)||void 0===n?void 0:n.height)||0)>t+10&&e.hasFocus&&(e.contentDOM.blur(),e.focus())},100)}return _.ios&&"deleteContentForward"==t.inputType&&e.observer.flushSoon(),_.safari&&"insertText"==t.inputType&&e.inputState.composing>=0&&setTimeout(()=>Xn.compositionend(e,t),20),!1};const gr=new Set;function vr(e){gr.has(e)||(gr.add(e),e.addEventListener("copy",()=>{}),e.addEventListener("cut",()=>{}))}const br=["pre-wrap","normal","pre-line","break-spaces"];let yr=!1;function wr(){yr=!1}class Or{constructor(e){this.lineWrapping=e,this.doc=r.Text.empty,this.heightSamples={},this.lineHeight=14,this.charWidth=7,this.textHeight=14,this.lineLength=30}heightForGap(e,t){let n=this.doc.lineAt(t).number-this.doc.lineAt(e).number+1;return this.lineWrapping&&(n+=Math.max(0,Math.ceil((t-e-n*this.lineLength*.5)/this.lineLength))),this.lineHeight*n}heightForLine(e){if(!this.lineWrapping)return this.lineHeight;let t=1+Math.max(0,Math.ceil((e-this.lineLength)/Math.max(1,this.lineLength-5)));return t*this.lineHeight}setDoc(e){return this.doc=e,this}mustRefreshForWrapping(e){return br.indexOf(e)>-1!=this.lineWrapping}mustRefreshForHeights(e){let t=!1;for(let n=0;n<e.length;n++){let r=e[n];r<0?n++:this.heightSamples[Math.floor(10*r)]||(t=!0,this.heightSamples[Math.floor(10*r)]=!0)}return t}refresh(e,t,n,r,i,o){let a=br.indexOf(e)>-1,s=Math.abs(t-this.lineHeight)>.3||this.lineWrapping!=a;if(this.lineWrapping=a,this.lineHeight=t,this.charWidth=n,this.textHeight=r,this.lineLength=i,s){this.heightSamples={};for(let e=0;e<o.length;e++){let t=o[e];t<0?e++:this.heightSamples[Math.floor(10*t)]=!0}}return s}}class Sr{constructor(e,t){this.from=e,this.heights=t,this.index=0}get more(){return this.index<this.heights.length}}class Er{constructor(e,t,n,r,i){this.from=e,this.length=t,this.top=n,this.height=r,this._content=i}get type(){return"number"==typeof this._content?I.Text:Array.isArray(this._content)?this._content:this._content.type}get to(){return this.from+this.length}get bottom(){return this.top+this.height}get widget(){return this._content instanceof B?this._content.widget:null}get widgetLineBreaks(){return"number"==typeof this._content?this._content:0}join(e){let t=(Array.isArray(this._content)?this._content:[this]).concat(Array.isArray(e._content)?e._content:[e]);return new Er(this.from,this.length+e.length,this.top,this.height+e.height,t)}}var xr=function(e){return e[e["ByPos"]=0]="ByPos",e[e["ByHeight"]=1]="ByHeight",e[e["ByPosNoHeight"]=2]="ByPosNoHeight",e}(xr||(xr={}));const _r=.001;class kr{constructor(e,t,n=2){this.length=e,this.height=t,this.flags=n}get outdated(){return(2&this.flags)>0}set outdated(e){this.flags=(e?2:0)|-3&this.flags}setHeight(e){this.height!=e&&(Math.abs(this.height-e)>_r&&(yr=!0),this.height=e)}replace(e,t,n){return kr.of(n)}decomposeLeft(e,t){t.push(this)}decomposeRight(e,t){t.push(this)}applyChanges(e,t,n,r){let i=this,o=n.doc;for(let a=r.length-1;a>=0;a--){let{fromA:s,toA:l,fromB:c,toB:u}=r[a],d=i.lineAt(s,xr.ByPosNoHeight,n.setDoc(t),0,0),h=d.to>=l?d:i.lineAt(l,xr.ByPosNoHeight,n,0,0);u+=h.to-l,l=h.to;while(a>0&&d.from<=r[a-1].toA)s=r[a-1].fromA,c=r[a-1].fromB,a--,s<d.from&&(d=i.lineAt(s,xr.ByPosNoHeight,n,0,0));c+=d.from-s,s=d.from;let p=Dr.build(n.setDoc(o),e,c,u);i=Cr(i,i.replace(s,l,p))}return i.updateHeight(n,0)}static empty(){return new Rr(0,0,0)}static of(e){if(1==e.length)return e[0];let t=0,n=e.length,r=0,i=0;for(;;)if(t==n)if(r>2*i){let i=e[t-1];i.break?e.splice(--t,1,i.left,null,i.right):e.splice(--t,1,i.left,i.right),n+=1+i.break,r-=i.size}else{if(!(i>2*r))break;{let t=e[n];t.break?e.splice(n,1,t.left,null,t.right):e.splice(n,1,t.left,t.right),n+=2+t.break,i-=t.size}}else if(r<i){let n=e[t++];n&&(r+=n.size)}else{let t=e[--n];t&&(i+=t.size)}let o=!1;return null==e[t-1]?(o=!0,t--):null==e[t]&&(o=!0,n++),new Pr(kr.of(e.slice(0,t)),o,kr.of(e.slice(n)))}}function Cr(e,t){return e==t?e:(e.constructor!=t.constructor&&(yr=!0),t)}kr.prototype.size=1;const Ar=M.replace({});class Tr extends kr{constructor(e,t,n){super(e,t),this.deco=n,this.spaceAbove=0}mainBlock(e,t){return new Er(t,this.length,e+this.spaceAbove,this.height-this.spaceAbove,this.deco||0)}blockAt(e,t,n,r){return this.spaceAbove&&e<n+this.spaceAbove?new Er(r,0,n,this.spaceAbove,Ar):this.mainBlock(n,r)}lineAt(e,t,n,r,i){let o=this.mainBlock(r,i);return this.spaceAbove?this.blockAt(0,n,r,i).join(o):o}forEachLine(e,t,n,r,i,o){e<=i+this.length&&t>=i&&o(this.lineAt(0,xr.ByPos,n,r,i))}setMeasuredHeight(e){let t=e.heights[e.index++];t<0?(this.spaceAbove=-t,t=e.heights[e.index++]):this.spaceAbove=0,this.setHeight(t)}updateHeight(e,t=0,n=!1,r){return r&&r.from<=t&&r.more&&this.setMeasuredHeight(r),this.outdated=!1,this}toString(){return`block(${this.length})`}}class Rr extends Tr{constructor(e,t,n){super(e,t,null),this.collapsed=0,this.widgetHeight=0,this.breaks=0,this.spaceAbove=n}mainBlock(e,t){return new Er(t,this.length,e+this.spaceAbove,this.height-this.spaceAbove,this.breaks)}replace(e,t,n){let r=n[0];return 1==n.length&&(r instanceof Rr||r instanceof Nr&&4&r.flags)&&Math.abs(this.length-r.length)<10?(r instanceof Nr?r=new Rr(r.length,this.height,this.spaceAbove):r.height=this.height,this.outdated||(r.outdated=!1),r):kr.of(n)}updateHeight(e,t=0,n=!1,r){return r&&r.from<=t&&r.more?this.setMeasuredHeight(r):(n||this.outdated)&&(this.spaceAbove=0,this.setHeight(Math.max(this.widgetHeight,e.heightForLine(this.length-this.collapsed))+this.breaks*e.lineHeight)),this.outdated=!1,this}toString(){return`line(${this.length}${this.collapsed?-this.collapsed:""}${this.widgetHeight?":"+this.widgetHeight:""})`}}class Nr extends kr{constructor(e){super(e,0)}heightMetrics(e,t){let n,r=e.doc.lineAt(t).number,i=e.doc.lineAt(t+this.length).number,o=i-r+1,a=0;if(e.lineWrapping){let t=Math.min(this.height,e.lineHeight*o);n=t/o,this.length>o+1&&(a=(this.height-t)/(this.length-o-1))}else n=this.height/o;return{firstLine:r,lastLine:i,perLine:n,perChar:a}}blockAt(e,t,n,r){let{firstLine:i,lastLine:o,perLine:a,perChar:s}=this.heightMetrics(t,r);if(t.lineWrapping){let i=r+(e<t.lineHeight?0:Math.round(Math.max(0,Math.min(1,(e-n)/this.height))*this.length)),o=t.doc.lineAt(i),l=a+o.length*s,c=Math.max(n,e-l/2);return new Er(o.from,o.length,c,l,0)}{let r=Math.max(0,Math.min(o-i,Math.floor((e-n)/a))),{from:s,length:l}=t.doc.line(i+r);return new Er(s,l,n+a*r,a,0)}}lineAt(e,t,n,r,i){if(t==xr.ByHeight)return this.blockAt(e,n,r,i);if(t==xr.ByPosNoHeight){let{from:t,to:r}=n.doc.lineAt(e);return new Er(t,r-t,0,0,0)}let{firstLine:o,perLine:a,perChar:s}=this.heightMetrics(n,i),l=n.doc.lineAt(e),c=a+l.length*s,u=l.number-o,d=r+a*u+s*(l.from-i-u);return new Er(l.from,l.length,Math.max(r,Math.min(d,r+this.height-c)),c,0)}forEachLine(e,t,n,r,i,o){e=Math.max(e,i),t=Math.min(t,i+this.length);let{firstLine:a,perLine:s,perChar:l}=this.heightMetrics(n,i);for(let c=e,u=r;c<=t;){let t=n.doc.lineAt(c);if(c==e){let n=t.number-a;u+=s*n+l*(e-i-n)}let r=s+l*t.length;o(new Er(t.from,t.length,u,r,0)),u+=r,c=t.to+1}}replace(e,t,n){let r=this.length-t;if(r>0){let e=n[n.length-1];e instanceof Nr?n[n.length-1]=new Nr(e.length+r):n.push(null,new Nr(r-1))}if(e>0){let t=n[0];t instanceof Nr?n[0]=new Nr(e+t.length):n.unshift(new Nr(e-1),null)}return kr.of(n)}decomposeLeft(e,t){t.push(new Nr(e-1),null)}decomposeRight(e,t){t.push(null,new Nr(this.length-e-1))}updateHeight(e,t=0,n=!1,r){let i=t+this.length;if(r&&r.from<=t+this.length&&r.more){let n=[],o=Math.max(t,r.from),a=-1;r.from>t&&n.push(new Nr(r.from-t-1).updateHeight(e,t));while(o<=i&&r.more){let t=e.doc.lineAt(o).length;n.length&&n.push(null);let i=r.heights[r.index++],s=0;i<0&&(s=-i,i=r.heights[r.index++]),-1==a?a=i:Math.abs(i-a)>=_r&&(a=-2);let l=new Rr(t,i,s);l.outdated=!1,n.push(l),o+=t+1}o<=i&&n.push(null,new Nr(i-o).updateHeight(e,o));let s=kr.of(n);return(a<0||Math.abs(s.height-this.height)>=_r||Math.abs(a-this.heightMetrics(e,t).perLine)>=_r)&&(yr=!0),Cr(this,s)}return(n||this.outdated)&&(this.setHeight(e.heightForGap(t,t+this.length)),this.outdated=!1),this}toString(){return`gap(${this.length})`}}class Pr extends kr{constructor(e,t,n){super(e.length+(t?1:0)+n.length,e.height+n.height,(t?1:0)|(e.outdated||n.outdated?2:0)),this.left=e,this.right=n,this.size=e.size+n.size}get break(){return 1&this.flags}blockAt(e,t,n,r){let i=n+this.left.height;return e<i?this.left.blockAt(e,t,n,r):this.right.blockAt(e,t,i,r+this.left.length+this.break)}lineAt(e,t,n,r,i){let o=r+this.left.height,a=i+this.left.length+this.break,s=t==xr.ByHeight?e<o:e<a,l=s?this.left.lineAt(e,t,n,r,i):this.right.lineAt(e,t,n,o,a);if(this.break||(s?l.to<a:l.from>a))return l;let c=t==xr.ByPosNoHeight?xr.ByPosNoHeight:xr.ByPos;return s?l.join(this.right.lineAt(a,c,n,o,a)):this.left.lineAt(a,c,n,r,i).join(l)}forEachLine(e,t,n,r,i,o){let a=r+this.left.height,s=i+this.left.length+this.break;if(this.break)e<s&&this.left.forEachLine(e,t,n,r,i,o),t>=s&&this.right.forEachLine(e,t,n,a,s,o);else{let l=this.lineAt(s,xr.ByPos,n,r,i);e<l.from&&this.left.forEachLine(e,Math.min(t,l.from-1),n,r,i,o),l.to>=e&&l.from<=t&&o(l),t>l.to&&this.right.forEachLine(Math.max(e,l.to+1),t,n,a,s,o)}}replace(e,t,n){let r=this.left.length+this.break;if(t<r)return this.balanced(this.left.replace(e,t,n),this.right);if(e>this.left.length)return this.balanced(this.left,this.right.replace(e-r,t-r,n));let i=[];e>0&&this.decomposeLeft(e,i);let o=i.length;for(let a of n)i.push(a);if(e>0&&Ir(i,o-1),t<this.length){let e=i.length;this.decomposeRight(t,i),Ir(i,e)}return kr.of(i)}decomposeLeft(e,t){let n=this.left.length;if(e<=n)return this.left.decomposeLeft(e,t);t.push(this.left),this.break&&(n++,e>=n&&t.push(null)),e>n&&this.right.decomposeLeft(e-n,t)}decomposeRight(e,t){let n=this.left.length,r=n+this.break;if(e>=r)return this.right.decomposeRight(e-r,t);e<n&&this.left.decomposeRight(e,t),this.break&&e<r&&t.push(null),t.push(this.right)}balanced(e,t){return e.size>2*t.size||t.size>2*e.size?kr.of(this.break?[e,null,t]:[e,t]):(this.left=Cr(this.left,e),this.right=Cr(this.right,t),this.setHeight(e.height+t.height),this.outdated=e.outdated||t.outdated,this.size=e.size+t.size,this.length=e.length+this.break+t.length,this)}updateHeight(e,t=0,n=!1,r){let{left:i,right:o}=this,a=t+i.length+this.break,s=null;return r&&r.from<=t+i.length&&r.more?s=i=i.updateHeight(e,t,n,r):i.updateHeight(e,t,n),r&&r.from<=a+o.length&&r.more?s=o=o.updateHeight(e,a,n,r):o.updateHeight(e,a,n),s?this.balanced(i,o):(this.height=this.left.height+this.right.height,this.outdated=!1,this)}toString(){return this.left+(this.break?" ":"-")+this.right}}function Ir(e,t){let n,r;null==e[t]&&(n=e[t-1])instanceof Nr&&(r=e[t+1])instanceof Nr&&e.splice(t-1,3,new Nr(n.length+1+r.length))}const Mr=5;class Dr{constructor(e,t){this.pos=e,this.oracle=t,this.nodes=[],this.lineStart=-1,this.lineEnd=-1,this.covering=null,this.writtenTo=e}get isCovered(){return this.covering&&this.nodes[this.nodes.length-1]==this.covering}span(e,t){if(this.lineStart>-1){let e=Math.min(t,this.lineEnd),n=this.nodes[this.nodes.length-1];n instanceof Rr?n.length+=e-this.pos:(e>this.pos||!this.isCovered)&&this.nodes.push(new Rr(e-this.pos,-1,0)),this.writtenTo=e,t>e&&(this.nodes.push(null),this.writtenTo++,this.lineStart=-1)}this.pos=t}point(e,t,n){if(e<t||n.heightRelevant){let r=n.widget?n.widget.estimatedHeight:0,i=n.widget?n.widget.lineBreaks:0;r<0&&(r=this.oracle.lineHeight);let o=t-e;n.block?this.addBlock(new Tr(o,r,n)):(o||i||r>=Mr)&&this.addLineDeco(r,i,o)}else t>e&&this.span(e,t);this.lineEnd>-1&&this.lineEnd<this.pos&&(this.lineEnd=this.oracle.doc.lineAt(this.pos).to)}enterLine(){if(this.lineStart>-1)return;let{from:e,to:t}=this.oracle.doc.lineAt(this.pos);this.lineStart=e,this.lineEnd=t,this.writtenTo<e&&((this.writtenTo<e-1||null==this.nodes[this.nodes.length-1])&&this.nodes.push(this.blankContent(this.writtenTo,e-1)),this.nodes.push(null)),this.pos>e&&this.nodes.push(new Rr(this.pos-e,-1,0)),this.writtenTo=this.pos}blankContent(e,t){let n=new Nr(t-e);return this.oracle.doc.lineAt(e).to==t&&(n.flags|=4),n}ensureLine(){this.enterLine();let e=this.nodes.length?this.nodes[this.nodes.length-1]:null;if(e instanceof Rr)return e;let t=new Rr(0,-1,0);return this.nodes.push(t),t}addBlock(e){this.enterLine();let t=e.deco;t&&t.startSide>0&&!this.isCovered&&this.ensureLine(),this.nodes.push(e),this.writtenTo=this.pos=this.pos+e.length,t&&t.endSide>0&&(this.covering=e)}addLineDeco(e,t,n){let r=this.ensureLine();r.length+=n,r.collapsed+=n,r.widgetHeight=Math.max(r.widgetHeight,e),r.breaks+=t,this.writtenTo=this.pos=this.pos+n}finish(e){let t=0==this.nodes.length?null:this.nodes[this.nodes.length-1];!(this.lineStart>-1)||t instanceof Rr||this.isCovered?(this.writtenTo<this.pos||null==t)&&this.nodes.push(this.blankContent(this.writtenTo,this.pos)):this.nodes.push(new Rr(0,-1,0));let n=e;for(let r of this.nodes)r instanceof Rr&&r.updateHeight(this.oracle,n),n+=r?r.length:1;return this.nodes}static build(e,t,n,i){let o=new Dr(n,e);return r.RangeSet.spans(t,n,i,o,0),o.finish(n)}}function Lr(e,t,n){let i=new Br;return r.RangeSet.compare(e,t,n,i,0),i.changes}class Br{constructor(){this.changes=[]}compareRange(){}comparePoint(e,t,n,r){(e<t||n&&n.heightRelevant||r&&r.heightRelevant)&&F(e,t,this.changes,5)}}function $r(e,t){let n=e.getBoundingClientRect(),r=e.ownerDocument,i=r.defaultView||window,o=Math.max(0,n.left),a=Math.min(i.innerWidth,n.right),s=Math.max(0,n.top),l=Math.min(i.innerHeight,n.bottom);for(let c=e.parentNode;c&&c!=r.body;)if(1==c.nodeType){let t=c,n=window.getComputedStyle(t);if((t.scrollHeight>t.clientHeight||t.scrollWidth>t.clientWidth)&&"visible"!=n.overflow){let n=t.getBoundingClientRect();o=Math.max(o,n.left),a=Math.min(a,n.right),s=Math.max(s,n.top),l=Math.min(c==e.parentNode?i.innerHeight:l,n.bottom)}c="absolute"==n.position||"fixed"==n.position?t.offsetParent:t.parentNode}else{if(11!=c.nodeType)break;c=c.host}return{left:o-n.left,right:Math.max(o,a)-n.left,top:s-(n.top+t),bottom:Math.max(s,l)-(n.top+t)}}function Vr(e){let t=e.getBoundingClientRect(),n=e.ownerDocument.defaultView||window;return t.left<n.innerWidth&&t.right>0&&t.top<n.innerHeight&&t.bottom>0}function Fr(e,t){let n=e.getBoundingClientRect();return{left:0,right:n.right-n.left,top:t,bottom:n.bottom-(n.top+t)}}class jr{constructor(e,t,n,r){this.from=e,this.to=t,this.size=n,this.displaySize=r}static same(e,t){if(e.length!=t.length)return!1;for(let n=0;n<e.length;n++){let r=e[n],i=t[n];if(r.from!=i.from||r.to!=i.to||r.size!=i.size)return!1}return!0}draw(e,t){return M.replace({widget:new Ur(this.displaySize*(t?e.scaleY:e.scaleX),t)}).range(this.from,this.to)}}class Ur extends P{constructor(e,t){super(),this.size=e,this.vertical=t}eq(e){return e.size==this.size&&e.vertical==this.vertical}toDOM(){let e=document.createElement("div");return this.vertical?e.style.height=this.size+"px":(e.style.width=this.size+"px",e.style.height="2px",e.style.display="inline-block"),e}get estimatedHeight(){return this.vertical?this.size:-1}}class Gr{constructor(e,t){this.view=e,this.state=t,this.pixelViewport={left:0,right:window.innerWidth,top:0,bottom:0},this.inView=!0,this.paddingTop=0,this.paddingBottom=0,this.contentDOMWidth=0,this.contentDOMHeight=0,this.editorHeight=0,this.editorWidth=0,this.scaleX=1,this.scaleY=1,this.scrollOffset=0,this.scrolledToBottom=!1,this.scrollAnchorPos=0,this.scrollAnchorHeight=-1,this.scaler=Wr,this.scrollTarget=null,this.printing=!1,this.mustMeasureContent=!0,this.defaultTextDirection=ge.LTR,this.visibleRanges=[],this.mustEnforceCursorAssoc=!1;let n=t.facet(st).some(e=>"function"!=typeof e&&"cm-lineWrapping"==e.class);this.heightOracle=new Or(n),this.stateDeco=Xr(t),this.heightMap=kr.empty().applyChanges(this.stateDeco,r.Text.empty,this.heightOracle.setDoc(t.doc),[new vt(0,0,0,t.doc.length)]);for(let r=0;r<2;r++)if(this.viewport=this.getViewport(0,null),!this.updateForViewport())break;this.updateViewportLines(),this.lineGaps=this.ensureLineGaps([]),this.lineGapDeco=M.set(this.lineGaps.map(e=>e.draw(this,!1))),this.scrollParent=e.scrollDOM,this.computeVisibleRanges()}updateForViewport(){let e=[this.viewport],{main:t}=this.state.selection;for(let n=0;n<=1;n++){let r=n?t.head:t.anchor;if(!e.some(({from:e,to:t})=>r>=e&&r<=t)){let{from:t,to:n}=this.lineBlockAt(r);e.push(new Hr(t,n))}}return this.viewports=e.sort((e,t)=>e.from-t.from),this.updateScaler()}updateScaler(){let e=this.scaler;return this.scaler=this.heightMap.height<=7e6?Wr:new Yr(this.heightOracle,this.heightMap,this.viewports),e.eq(this.scaler)?0:2}updateViewportLines(){this.viewportLines=[],this.heightMap.forEachLine(this.viewport.from,this.viewport.to,this.heightOracle.setDoc(this.state.doc),0,0,e=>{this.viewportLines.push(Zr(e,this.scaler))})}update(e,t=null){this.state=e.state;let n=this.stateDeco;this.stateDeco=Xr(this.state);let i=e.changedRanges,o=vt.extendWithRanges(i,Lr(n,this.stateDeco,e?e.changes:r.ChangeSet.empty(this.state.doc.length))),a=this.heightMap.height,s=this.scrolledToBottom?null:this.scrollAnchorAt(this.scrollOffset);wr(),this.heightMap=this.heightMap.applyChanges(this.stateDeco,e.startState.doc,this.heightOracle.setDoc(this.state.doc),o),(this.heightMap.height!=a||yr)&&(e.flags|=2),s?(this.scrollAnchorPos=e.changes.mapPos(s.from,-1),this.scrollAnchorHeight=s.top):(this.scrollAnchorPos=-1,this.scrollAnchorHeight=a);let l=o.length?this.mapViewport(this.viewport,e.changes):this.viewport;(t&&(t.range.head<l.from||t.range.head>l.to)||!this.viewportIsAppropriate(l))&&(l=this.getViewport(0,t));let c=l.from!=this.viewport.from||l.to!=this.viewport.to;this.viewport=l,e.flags|=this.updateForViewport(),(c||!e.changes.empty||2&e.flags)&&this.updateViewportLines(),(this.lineGaps.length||this.viewport.to-this.viewport.from>4e3)&&this.updateLineGaps(this.ensureLineGaps(this.mapLineGaps(this.lineGaps,e.changes))),e.flags|=this.computeVisibleRanges(e.changes),t&&(this.scrollTarget=t),!this.mustEnforceCursorAssoc&&(e.selectionSet||e.focusChanged)&&e.view.lineWrapping&&e.state.selection.main.empty&&e.state.selection.main.assoc&&!e.state.facet(We)&&(this.mustEnforceCursorAssoc=!0)}measure(){let{view:e}=this,t=e.contentDOM,n=window.getComputedStyle(t),i=this.heightOracle,o=n.whiteSpace;this.defaultTextDirection="rtl"==n.direction?ge.RTL:ge.LTR;let a=this.heightOracle.mustRefreshForWrapping(o)||"refresh"===this.mustMeasureContent,s=t.getBoundingClientRect(),l=a||this.mustMeasureContent||this.contentDOMHeight!=s.height;this.contentDOMHeight=s.height,this.mustMeasureContent=!1;let c=0,u=0;if(s.width&&s.height){let{scaleX:e,scaleY:n}=J(t,s);(e>.005&&Math.abs(this.scaleX-e)>.005||n>.005&&Math.abs(this.scaleY-n)>.005)&&(this.scaleX=e,this.scaleY=n,c|=16,a=l=!0)}let d=(parseInt(n.paddingTop)||0)*this.scaleY,h=(parseInt(n.paddingBottom)||0)*this.scaleY;this.paddingTop==d&&this.paddingBottom==h||(this.paddingTop=d,this.paddingBottom=h,c|=18),this.editorWidth!=e.scrollDOM.clientWidth&&(i.lineWrapping&&(l=!0),this.editorWidth=e.scrollDOM.clientWidth,c|=16);let p=te(this.view.contentDOM,!1).y;p!=this.scrollParent&&(this.scrollParent=p,this.scrollAnchorHeight=-1,this.scrollOffset=0);let f=this.getScrollOffset();this.scrollOffset!=f&&(this.scrollAnchorHeight=-1,this.scrollOffset=f),this.scrolledToBottom=he(this.scrollParent||e.win);let m=(this.printing?Fr:$r)(t,this.paddingTop),g=m.top-this.pixelViewport.top,v=m.bottom-this.pixelViewport.bottom;this.pixelViewport=m;let b=this.pixelViewport.bottom>this.pixelViewport.top&&this.pixelViewport.right>this.pixelViewport.left;if(b!=this.inView&&(this.inView=b,b&&(l=!0)),!this.inView&&!this.scrollTarget&&!Vr(e.dom))return 0;let y=s.width;if(this.contentDOMWidth==y&&this.editorHeight==e.scrollDOM.clientHeight||(this.contentDOMWidth=s.width,this.editorHeight=e.scrollDOM.clientHeight,c|=16),l){let t=e.docView.measureVisibleLineHeights(this.viewport);if(i.mustRefreshForHeights(t)&&(a=!0),a||i.lineWrapping&&Math.abs(y-this.contentDOMWidth)>i.charWidth){let{lineHeight:n,charWidth:r,textHeight:s}=e.docView.measureTextSize();a=n>0&&i.refresh(o,n,r,s,Math.max(5,y/r),t),a&&(e.docView.minWidth=0,c|=16)}g>0&&v>0?u=Math.max(g,v):g<0&&v<0&&(u=Math.min(g,v)),wr();for(let n of this.viewports){let o=n.from==this.viewport.from?t:e.docView.measureVisibleLineHeights(n);this.heightMap=(a?kr.empty().applyChanges(this.stateDeco,r.Text.empty,this.heightOracle,[new vt(0,0,0,e.state.doc.length)]):this.heightMap).updateHeight(i,0,a,new Sr(n.from,o))}yr&&(c|=2)}let w=!this.viewportIsAppropriate(this.viewport,u)||this.scrollTarget&&(this.scrollTarget.range.head<this.viewport.from||this.scrollTarget.range.head>this.viewport.to);return w&&(2&c&&(c|=this.updateScaler()),this.viewport=this.getViewport(u,this.scrollTarget),c|=this.updateForViewport()),(2&c||w)&&this.updateViewportLines(),(this.lineGaps.length||this.viewport.to-this.viewport.from>4e3)&&this.updateLineGaps(this.ensureLineGaps(a?[]:this.lineGaps,e)),c|=this.computeVisibleRanges(),this.mustEnforceCursorAssoc&&(this.mustEnforceCursorAssoc=!1,e.docView.enforceCursorAssoc()),c}get visibleTop(){return this.scaler.fromDOM(this.pixelViewport.top)}get visibleBottom(){return this.scaler.fromDOM(this.pixelViewport.bottom)}getViewport(e,t){let n=.5-Math.max(-.5,Math.min(.5,e/1e3/2)),r=this.heightMap,i=this.heightOracle,{visibleTop:o,visibleBottom:a}=this,s=new Hr(r.lineAt(o-1e3*n,xr.ByHeight,i,0,0).from,r.lineAt(a+1e3*(1-n),xr.ByHeight,i,0,0).to);if(t){let{head:e}=t.range;if(e<s.from||e>s.to){let n,o=Math.min(this.editorHeight,this.pixelViewport.bottom-this.pixelViewport.top),a=r.lineAt(e,xr.ByPos,i,0,0);n="center"==t.y?(a.top+a.bottom)/2-o/2:"start"==t.y||"nearest"==t.y&&e<s.from?a.top:a.bottom-o,s=new Hr(r.lineAt(n-500,xr.ByHeight,i,0,0).from,r.lineAt(n+o+500,xr.ByHeight,i,0,0).to)}}return s}mapViewport(e,t){let n=t.mapPos(e.from,-1),r=t.mapPos(e.to,1);return new Hr(this.heightMap.lineAt(n,xr.ByPos,this.heightOracle,0,0).from,this.heightMap.lineAt(r,xr.ByPos,this.heightOracle,0,0).to)}viewportIsAppropriate({from:e,to:t},n=0){if(!this.inView)return!0;let{top:r}=this.heightMap.lineAt(e,xr.ByPos,this.heightOracle,0,0),{bottom:i}=this.heightMap.lineAt(t,xr.ByPos,this.heightOracle,0,0),{visibleTop:o,visibleBottom:a}=this;return(0==e||r<=o-Math.max(10,Math.min(-n,250)))&&(t==this.state.doc.length||i>=a+Math.max(10,Math.min(n,250)))&&r>o-2e3&&i<a+2e3}mapLineGaps(e,t){if(!e.length||t.empty)return e;let n=[];for(let r of e)t.touchesRange(r.from,r.to)||n.push(new jr(t.mapPos(r.from),t.mapPos(r.to),r.size,r.displaySize));return n}ensureLineGaps(e,t){let n=this.heightOracle.lineWrapping,i=n?1e4:2e3,o=i>>1,a=i<<1;if(this.defaultTextDirection!=ge.LTR&&!n)return[];let s=[],l=(i,a,c,u)=>{if(a-i<o)return;let d=this.state.selection.main,h=[d.from];d.empty||h.push(d.to);for(let e of h)if(e>i&&e<a)return l(i,e-10,c,u),void l(e+10,a,c,u);let p=Kr(e,e=>e.from>=c.from&&e.to<=c.to&&Math.abs(e.from-i)<o&&Math.abs(e.to-a)<o&&!h.some(t=>e.from<t&&e.to>t));if(!p){if(a<c.to&&t&&n&&t.visibleRanges.some(e=>e.from<=a&&e.to>=a)){let e=t.moveToLineBoundary(r.EditorSelection.cursor(a),!1,!0).head;e>i&&(a=e)}let e=this.gapSize(c,i,a,u),o=n||e<2e6?e:2e6;p=new jr(i,a,e,o)}s.push(p)},c=t=>{if(t.length<a||t.type!=I.Text)return;let r=qr(t.from,t.to,this.stateDeco);if(r.total<a)return;let o,s,c=this.scrollTarget?this.scrollTarget.range.head:null;if(n){let e,n,a=i/this.heightOracle.lineLength*this.heightOracle.lineHeight;if(null!=c){let i=zr(r,c),o=((this.visibleBottom-this.visibleTop)/2+a)/t.height;e=i-o,n=i+o}else e=(this.visibleTop-t.top-a)/t.height,n=(this.visibleBottom-t.top+a)/t.height;o=Qr(r,e),s=Qr(r,n)}else{let n=r.total*this.heightOracle.charWidth,a=i*this.heightOracle.charWidth,l=0;if(n>2e6)for(let r of e)r.from>=t.from&&r.from<t.to&&r.size!=r.displaySize&&r.from*this.heightOracle.charWidth+l<this.pixelViewport.left&&(l=r.size-r.displaySize);let u,d,h=this.pixelViewport.left+l,p=this.pixelViewport.right+l;if(null!=c){let e=zr(r,c),t=((p-h)/2+a)/n;u=e-t,d=e+t}else u=(h-a)/n,d=(p+a)/n;o=Qr(r,u),s=Qr(r,d)}o>t.from&&l(t.from,o,t,r),s<t.to&&l(s,t.to,t,r)};for(let r of this.viewportLines)Array.isArray(r.type)?r.type.forEach(c):c(r);return s}gapSize(e,t,n,r){let i=zr(r,n)-zr(r,t);return this.heightOracle.lineWrapping?e.height*i:r.total*this.heightOracle.charWidth*i}updateLineGaps(e){jr.same(e,this.lineGaps)||(this.lineGaps=e,this.lineGapDeco=M.set(e.map(e=>e.draw(this,this.heightOracle.lineWrapping))))}computeVisibleRanges(e){let t=this.stateDeco;this.lineGaps.length&&(t=t.concat(this.lineGapDeco));let n=[];r.RangeSet.spans(t,this.viewport.from,this.viewport.to,{span(e,t){n.push({from:e,to:t})},point(){}},20);let i=0;if(n.length!=this.visibleRanges.length)i=12;else for(let r=0;r<n.length&&!(8&i);r++){let t=this.visibleRanges[r],o=n[r];t.from==o.from&&t.to==o.to||(i|=4,e&&e.mapPos(t.from,-1)==o.from&&e.mapPos(t.to,1)==o.to||(i|=8))}return this.visibleRanges=n,i}lineBlockAt(e){return e>=this.viewport.from&&e<=this.viewport.to&&this.viewportLines.find(t=>t.from<=e&&t.to>=e)||Zr(this.heightMap.lineAt(e,xr.ByPos,this.heightOracle,0,0),this.scaler)}lineBlockAtHeight(e){return e>=this.viewportLines[0].top&&e<=this.viewportLines[this.viewportLines.length-1].bottom&&this.viewportLines.find(t=>t.top<=e&&t.bottom>=e)||Zr(this.heightMap.lineAt(this.scaler.fromDOM(e),xr.ByHeight,this.heightOracle,0,0),this.scaler)}getScrollOffset(){return this.scrollParent==this.view.scrollDOM?this.scrollParent.scrollTop*this.scaleY:(this.scrollParent?this.scrollParent.getBoundingClientRect().top:0)-this.view.contentDOM.getBoundingClientRect().top}scrollAnchorAt(e){let t=this.lineBlockAtHeight(e+8);return t.from>=this.viewport.from||this.viewportLines[0].top-e>200?t:this.viewportLines[0]}elementAtHeight(e){return Zr(this.heightMap.blockAt(this.scaler.fromDOM(e),this.heightOracle,0,0),this.scaler)}get docHeight(){return this.scaler.toDOM(this.heightMap.height)}get contentHeight(){return this.docHeight+this.paddingTop+this.paddingBottom}}class Hr{constructor(e,t){this.from=e,this.to=t}}function qr(e,t,n){let i=[],o=e,a=0;return r.RangeSet.spans(n,e,t,{span(){},point(e,t){e>o&&(i.push({from:o,to:e}),a+=e-o),o=t}},20),o<t&&(i.push({from:o,to:t}),a+=t-o),{total:a,ranges:i}}function Qr({total:e,ranges:t},n){if(n<=0)return t[0].from;if(n>=1)return t[t.length-1].to;let r=Math.floor(e*n);for(let i=0;;i++){let{from:e,to:n}=t[i],o=n-e;if(r<=o)return e+r;r-=o}}function zr(e,t){let n=0;for(let{from:r,to:i}of e.ranges){if(t<=i){n+=t-r;break}n+=i-r}return n/e.total}function Kr(e,t){for(let n of e)if(t(n))return n}const Wr={toDOM(e){return e},fromDOM(e){return e},scale:1,eq(e){return e==this}};function Xr(e){let t=e.facet(lt).filter(e=>"function"!=typeof e),n=e.facet(ut).filter(e=>"function"!=typeof e);return n.length&&t.push(r.RangeSet.join(n)),t}class Yr{constructor(e,t,n){let r=0,i=0,o=0;this.viewports=n.map(({from:n,to:i})=>{let o=t.lineAt(n,xr.ByPos,e,0,0).top,a=t.lineAt(i,xr.ByPos,e,0,0).bottom;return r+=a-o,{from:n,to:i,top:o,bottom:a,domTop:0,domBottom:0}}),this.scale=(7e6-r)/(t.height-r);for(let a of this.viewports)a.domTop=o+(a.top-i)*this.scale,o=a.domBottom=a.domTop+(a.bottom-a.top),i=a.bottom}toDOM(e){for(let t=0,n=0,r=0;;t++){let i=t<this.viewports.length?this.viewports[t]:null;if(!i||e<i.top)return r+(e-n)*this.scale;if(e<=i.bottom)return i.domTop+(e-i.top);n=i.bottom,r=i.domBottom}}fromDOM(e){for(let t=0,n=0,r=0;;t++){let i=t<this.viewports.length?this.viewports[t]:null;if(!i||e<i.domTop)return n+(e-r)/this.scale;if(e<=i.domBottom)return i.top+(e-i.domTop);n=i.bottom,r=i.domBottom}}eq(e){return e instanceof Yr&&(this.scale==e.scale&&this.viewports.length==e.viewports.length&&this.viewports.every((t,n)=>t.from==e.viewports[n].from&&t.to==e.viewports[n].to))}}function Zr(e,t){if(1==t.scale)return e;let n=t.toDOM(e.top),r=t.toDOM(e.bottom);return new Er(e.from,e.length,n,r-n,Array.isArray(e._content)?e._content.map(e=>Zr(e,t)):e._content)}const Jr=r.Facet.define({combine:e=>e.join(" ")}),ei=r.Facet.define({combine:e=>e.indexOf(!0)>-1}),ti=i.G.newName(),ni=i.G.newName(),ri=i.G.newName(),ii={"&light":"."+ni,"&dark":"."+ri};function oi(e,t,n){return new i.G(t,{finish(t){return/&/.test(t)?t.replace(/&\w*/,t=>{if("&"==t)return e;if(!n||!n[t])throw new RangeError(`Unsupported selector: ${t}`);return n[t]}):e+" "+t}})}const ai=oi("."+ti,{"&":{position:"relative !important",boxSizing:"border-box","&.cm-focused":{outline:"1px dotted #212121"},display:"flex !important",flexDirection:"column"},".cm-scroller":{display:"flex !important",alignItems:"flex-start !important",fontFamily:"monospace",lineHeight:1.4,height:"100%",overflowX:"auto",position:"relative",zIndex:0,overflowAnchor:"none"},".cm-content":{margin:0,flexGrow:2,flexShrink:0,display:"block",whiteSpace:"pre",wordWrap:"normal",boxSizing:"border-box",minHeight:"100%",padding:"4px 0",outline:"none","&[contenteditable=true]":{WebkitUserModify:"read-write-plaintext-only"}},".cm-lineWrapping":{whiteSpace_fallback:"pre-wrap",whiteSpace:"break-spaces",wordBreak:"break-word",overflowWrap:"anywhere",flexShrink:1},"&light .cm-content":{caretColor:"black"},"&dark .cm-content":{caretColor:"white"},".cm-line":{display:"block",padding:"0 2px 0 6px"},".cm-layer":{userSelect:"none",position:"absolute",left:0,top:0,contain:"size style","& > *":{position:"absolute"}},"&light .cm-selectionBackground":{background:"#d9d9d9"},"&dark .cm-selectionBackground":{background:"#222"},"&light.cm-focused > .cm-scroller > .cm-selectionLayer .cm-selectionBackground":{background:"#d7d4f0"},"&dark.cm-focused > .cm-scroller > .cm-selectionLayer .cm-selectionBackground":{background:"#233"},".cm-cursorLayer":{pointerEvents:"none"},"&.cm-focused > .cm-scroller > .cm-cursorLayer":{animation:"steps(1) cm-blink 1.2s infinite"},"@keyframes cm-blink":{"0%":{},"50%":{opacity:0},"100%":{}},"@keyframes cm-blink2":{"0%":{},"50%":{opacity:0},"100%":{}},".cm-cursor, .cm-dropCursor":{borderLeft:"1.2px solid black",marginLeft:"-0.6px",pointerEvents:"none"},".cm-cursor":{display:"none"},"&dark .cm-cursor":{borderLeftColor:"#ddd"},".cm-selectionHandle":{backgroundColor:"currentColor",width:"1.5px"},".cm-selectionHandle-start::before, .cm-selectionHandle-end::before":{content:'""',backgroundColor:"inherit",borderRadius:"50%",width:"8px",height:"8px",position:"absolute",left:"-3.25px"},".cm-selectionHandle-start::before":{top:"-8px"},".cm-selectionHandle-end::before":{bottom:"-8px"},".cm-dropCursor":{position:"absolute"},"&.cm-focused > .cm-scroller > .cm-cursorLayer .cm-cursor":{display:"block"},".cm-iso":{unicodeBidi:"isolate"},".cm-announced":{position:"fixed",top:"-10000px"},"@media print":{".cm-announced":{display:"none"}},"&light .cm-activeLine":{backgroundColor:"#cceeff44"},"&dark .cm-activeLine":{backgroundColor:"#99eeff33"},"&light .cm-specialChar":{color:"red"},"&dark .cm-specialChar":{color:"#f78"},".cm-gutters":{flexShrink:0,display:"flex",height:"100%",boxSizing:"border-box",zIndex:200},".cm-gutters-before":{insetInlineStart:0},".cm-gutters-after":{insetInlineEnd:0},"&light .cm-gutters":{backgroundColor:"#f5f5f5",color:"#6c6c6c",border:"0px solid #ddd","&.cm-gutters-before":{borderRightWidth:"1px"},"&.cm-gutters-after":{borderLeftWidth:"1px"}},"&dark .cm-gutters":{backgroundColor:"#333338",color:"#ccc"},".cm-gutter":{display:"flex !important",flexDirection:"column",flexShrink:0,boxSizing:"border-box",minHeight:"100%",overflow:"hidden"},".cm-gutterElement":{boxSizing:"border-box"},".cm-lineNumbers .cm-gutterElement":{padding:"0 3px 0 5px",minWidth:"20px",textAlign:"right",whiteSpace:"nowrap"},"&light .cm-activeLineGutter":{backgroundColor:"#e2f2ff"},"&dark .cm-activeLineGutter":{backgroundColor:"#222227"},".cm-panels":{boxSizing:"border-box",position:"sticky",left:0,right:0,zIndex:300},"&light .cm-panels":{backgroundColor:"#f5f5f5",color:"black"},".cm-panels-top":{top:"0"},".cm-panels-bottom":{bottom:"0"},"&light .cm-panels-top":{borderBottom:"1px solid #ddd"},"&light .cm-panels-bottom":{borderTop:"1px solid #ddd"},"&dark .cm-panels":{backgroundColor:"#333338",color:"white"},".cm-dialog":{padding:"2px 19px 4px 6px",position:"relative","& label":{fontSize:"80%"}},".cm-dialog-close":{position:"absolute",top:"3px",right:"4px",backgroundColor:"inherit",border:"none",font:"inherit",fontSize:"14px",padding:"0"},".cm-tab":{display:"inline-block",overflow:"hidden",verticalAlign:"bottom"},".cm-widgetBuffer":{verticalAlign:"text-top",height:"1em",width:0,display:"inline"},".cm-placeholder":{color:"#888",display:"inline-block",verticalAlign:"top",userSelect:"none"},".cm-highlightSpace":{background:"radial-gradient(circle at 50% 55%, #aaa 20%, transparent 0) no-repeat",backgroundSize:".4em",backgroundPosition:"calc(min(50%, 0px)) center"},".cm-highlightTab":{backgroundImage:'url(\'data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="200" height="20"><path stroke="%23888" stroke-width="1" fill="none" d="M1 10H196L190 5M190 15L196 10M197 4L197 16"/></svg>\')',backgroundSize:"auto 100%",backgroundPosition:"right 90%",backgroundRepeat:"no-repeat"},".cm-trailingSpace":{backgroundColor:"#ff332255"},".cm-button":{verticalAlign:"middle",color:"inherit",fontSize:"70%",padding:".2em 1em",borderRadius:"1px"},"&light .cm-button":{backgroundImage:"linear-gradient(#eff1f5, #d9d9df)",border:"1px solid #888","&:active":{backgroundImage:"linear-gradient(#b4b4b4, #d0d3d6)"}},"&dark .cm-button":{backgroundImage:"linear-gradient(#393939, #111)",border:"1px solid #888","&:active":{backgroundImage:"linear-gradient(#111, #333)"}},".cm-textfield":{verticalAlign:"middle",color:"inherit",fontSize:"70%",border:"1px solid silver",padding:".2em .5em"},"&light .cm-textfield":{backgroundColor:"white"},"&dark .cm-textfield":{border:"1px solid #555",backgroundColor:"inherit"}},ii),si={childList:!0,characterData:!0,subtree:!0,attributes:!0,characterDataOldValue:!0},li=_.ie&&_.ie_version<=11;class ci{constructor(e){this.view=e,this.active=!1,this.editContext=null,this.selectionRange=new ne,this.selectionChanged=!1,this.delayedFlush=-1,this.resizeTimeout=-1,this.queue=[],this.delayedAndroidKey=null,this.flushingAndroidKey=-1,this.lastChange=0,this.scrollTargets=[],this.intersection=null,this.resizeScroll=null,this.intersecting=!1,this.gapIntersection=null,this.gaps=[],this.printQuery=null,this.parentCheck=-1,this.dom=e.contentDOM,this.observer=new MutationObserver(t=>{for(let e of t)this.queue.push(e);(_.ie&&_.ie_version<=11||_.ios&&e.composing)&&t.some(e=>"childList"==e.type&&e.removedNodes.length||"characterData"==e.type&&e.oldValue.length>e.target.nodeValue.length)?this.flushSoon():this.flush()}),!window.EditContext||!_.android||!1===e.constructor.EDIT_CONTEXT||_.chrome&&_.chrome_version<126||(this.editContext=new pi(e),e.state.facet(tt)&&(e.contentDOM.editContext=this.editContext.editContext)),li&&(this.onCharData=e=>{this.queue.push({target:e.target,type:"characterData",oldValue:e.prevValue}),this.flushSoon()}),this.onSelectionChange=this.onSelectionChange.bind(this),this.onResize=this.onResize.bind(this),this.onPrint=this.onPrint.bind(this),this.onScroll=this.onScroll.bind(this),window.matchMedia&&(this.printQuery=window.matchMedia("print")),"function"==typeof ResizeObserver&&(this.resizeScroll=new ResizeObserver(()=>{var e;(null===(e=this.view.docView)||void 0===e?void 0:e.lastUpdate)<Date.now()-75&&this.onResize()}),this.resizeScroll.observe(e.scrollDOM)),this.addWindowListeners(this.win=e.win),this.start(),"function"==typeof IntersectionObserver&&(this.intersection=new IntersectionObserver(e=>{this.parentCheck<0&&(this.parentCheck=setTimeout(this.listenForScroll.bind(this),1e3)),e.length>0&&e[e.length-1].intersectionRatio>0!=this.intersecting&&(this.intersecting=!this.intersecting,this.intersecting!=this.view.inView&&this.onScrollChanged(document.createEvent("Event")))},{threshold:[0,.001]}),this.intersection.observe(this.dom),this.gapIntersection=new IntersectionObserver(e=>{e.length>0&&e[e.length-1].intersectionRatio>0&&this.onScrollChanged(document.createEvent("Event"))},{})),this.listenForScroll(),this.readSelectionRange()}onScrollChanged(e){this.view.inputState.runHandlers("scroll",e),this.intersecting&&this.view.measure()}onScroll(e){this.intersecting&&this.flush(!1),this.editContext&&this.view.requestMeasure(this.editContext.measureReq),this.onScrollChanged(e)}onResize(){this.resizeTimeout<0&&(this.resizeTimeout=setTimeout(()=>{this.resizeTimeout=-1,this.view.requestMeasure()},50))}onPrint(e){("change"!=e.type&&e.type||e.matches)&&(this.view.viewState.printing=!0,this.view.measure(),setTimeout(()=>{this.view.viewState.printing=!1,this.view.requestMeasure()},500))}updateGaps(e){if(this.gapIntersection&&(e.length!=this.gaps.length||this.gaps.some((t,n)=>t!=e[n]))){this.gapIntersection.disconnect();for(let t of e)this.gapIntersection.observe(t);this.gaps=e}}onSelectionChange(e){let t=this.selectionChanged;if(!this.readSelectionRange()||this.delayedAndroidKey)return;let{view:n}=this,r=this.selectionRange;if(n.state.facet(tt)?n.root.activeElement!=this.dom:!H(this.dom,r))return;let i=r.anchorNode&&n.docView.tile.nearest(r.anchorNode);i&&i.isWidget()&&i.widget.ignoreEvent(e)?t||(this.selectionChanged=!1):(_.ie&&_.ie_version<=11||_.android&&_.chrome)&&!n.state.selection.main.empty&&r.focusNode&&Q(r.focusNode,r.focusOffset,r.anchorNode,r.anchorOffset)?this.flushSoon():this.flush(!1)}readSelectionRange(){let{view:e}=this,t=U(e.root);if(!t)return!1;let n=_.safari&&11==e.root.nodeType&&e.root.activeElement==this.dom&&hi(this.view,t)||t;if(!n||this.selectionRange.eq(n))return!1;let r=H(this.dom,n);return r&&!this.selectionChanged&&e.inputState.lastFocusTime>Date.now()-200&&e.inputState.lastTouchTime<Date.now()-300&&de(this.dom,n)?(this.view.inputState.lastFocusTime=0,e.docView.updateSelection(),!1):(this.selectionRange.setRange(n),r&&(this.selectionChanged=!0),!0)}setSelectionRange(e,t){this.selectionRange.set(e.node,e.offset,t.node,t.offset),this.selectionChanged=!1}clearSelectionRange(){this.selectionRange.set(null,0,null,0)}listenForScroll(){this.parentCheck=-1;let e=0,t=null;for(let n=this.dom;n;)if(1==n.nodeType)!t&&e<this.scrollTargets.length&&this.scrollTargets[e]==n?e++:t||(t=this.scrollTargets.slice(0,e)),t&&t.push(n),n=n.assignedSlot||n.parentNode;else{if(11!=n.nodeType)break;n=n.host}if(e<this.scrollTargets.length&&!t&&(t=this.scrollTargets.slice(0,e)),t){for(let e of this.scrollTargets)e.removeEventListener("scroll",this.onScroll);for(let e of this.scrollTargets=t)e.addEventListener("scroll",this.onScroll)}}ignore(e){if(!this.active)return e();try{return this.stop(),e()}finally{this.start(),this.clear()}}start(){this.active||(this.observer.observe(this.dom,si),li&&this.dom.addEventListener("DOMCharacterDataModified",this.onCharData),this.active=!0)}stop(){this.active&&(this.active=!1,this.observer.disconnect(),li&&this.dom.removeEventListener("DOMCharacterDataModified",this.onCharData))}clear(){this.processRecords(),this.queue.length=0,this.selectionChanged=!1}delayAndroidKey(e,t){var n;if(!this.delayedAndroidKey){let e=()=>{let e=this.delayedAndroidKey;if(e){this.clearDelayedAndroidKey(),this.view.inputState.lastKeyCode=e.keyCode,this.view.inputState.lastKeyTime=Date.now();let t=this.flush();!t&&e.force&&ce(this.dom,e.key,e.keyCode)}};this.flushingAndroidKey=this.view.win.requestAnimationFrame(e)}this.delayedAndroidKey&&"Enter"!=e||(this.delayedAndroidKey={key:e,keyCode:t,force:this.lastChange<Date.now()-50||!!(null===(n=this.delayedAndroidKey)||void 0===n?void 0:n.force)})}clearDelayedAndroidKey(){this.win.cancelAnimationFrame(this.flushingAndroidKey),this.delayedAndroidKey=null,this.flushingAndroidKey=-1}flushSoon(){this.delayedFlush<0&&(this.delayedFlush=this.view.win.requestAnimationFrame(()=>{this.delayedFlush=-1,this.flush()}))}forceFlush(){this.delayedFlush>=0&&(this.view.win.cancelAnimationFrame(this.delayedFlush),this.delayedFlush=-1),this.flush()}pendingRecords(){for(let e of this.observer.takeRecords())this.queue.push(e);return this.queue}processRecords(){let e=this.pendingRecords();e.length&&(this.queue=[]);let t=-1,n=-1,r=!1;for(let i of e){let e=this.readMutation(i);e&&(e.typeOver&&(r=!0),-1==t?({from:t,to:n}=e):(t=Math.min(e.from,t),n=Math.max(e.to,n)))}return{from:t,to:n,typeOver:r}}readChange(){let{from:e,to:t,typeOver:n}=this.processRecords(),r=this.selectionChanged&&H(this.dom,this.selectionRange);if(e<0&&!r)return null;e>-1&&(this.lastChange=Date.now()),this.view.inputState.lastFocusTime=0,this.selectionChanged=!1;let i=new _n(this.view,e,t,n);return this.view.docView.domChanged={newSel:i.newSel?i.newSel.main:null},i}flush(e=!0){if(this.delayedFlush>=0||this.delayedAndroidKey)return!1;e&&this.readSelectionRange();let t=this.readChange();if(!t)return this.view.requestMeasure(),!1;let n=this.view.state,r=Cn(this.view,t);return this.view.state==n&&(t.domChanged||t.newSel&&!In(this.view.state.selection,t.newSel.main))&&this.view.update([]),r}readMutation(e){let t=this.view.docView.tile.nearest(e.target);if(!t||t.isWidget())return null;if(t.markDirty("attributes"==e.type),"childList"==e.type){let n=ui(t,e.previousSibling||e.target.previousSibling,-1),r=ui(t,e.nextSibling||e.target.nextSibling,1);return{from:n?t.posAfter(n):t.posAtStart,to:r?t.posBefore(r):t.posAtEnd,typeOver:!1}}return"characterData"==e.type?{from:t.posAtStart,to:t.posAtEnd,typeOver:e.target.nodeValue==e.oldValue}:null}setWindow(e){e!=this.win&&(this.removeWindowListeners(this.win),this.win=e,this.addWindowListeners(this.win))}addWindowListeners(e){e.addEventListener("resize",this.onResize),this.printQuery?this.printQuery.addEventListener?this.printQuery.addEventListener("change",this.onPrint):this.printQuery.addListener(this.onPrint):e.addEventListener("beforeprint",this.onPrint),e.addEventListener("scroll",this.onScroll),e.document.addEventListener("selectionchange",this.onSelectionChange)}removeWindowListeners(e){e.removeEventListener("scroll",this.onScroll),e.removeEventListener("resize",this.onResize),this.printQuery?this.printQuery.removeEventListener?this.printQuery.removeEventListener("change",this.onPrint):this.printQuery.removeListener(this.onPrint):e.removeEventListener("beforeprint",this.onPrint),e.document.removeEventListener("selectionchange",this.onSelectionChange)}update(e){this.editContext&&(this.editContext.update(e),e.startState.facet(tt)!=e.state.facet(tt)&&(e.view.contentDOM.editContext=e.state.facet(tt)?this.editContext.editContext:null))}destroy(){var e,t,n;this.stop(),null===(e=this.intersection)||void 0===e||e.disconnect(),null===(t=this.gapIntersection)||void 0===t||t.disconnect(),null===(n=this.resizeScroll)||void 0===n||n.disconnect();for(let r of this.scrollTargets)r.removeEventListener("scroll",this.onScroll);this.removeWindowListeners(this.win),clearTimeout(this.parentCheck),clearTimeout(this.resizeTimeout),this.win.cancelAnimationFrame(this.delayedFlush),this.win.cancelAnimationFrame(this.flushingAndroidKey),this.editContext&&(this.view.contentDOM.editContext=null,this.editContext.destroy())}}function ui(e,t,n){while(t){let r=wt.get(t);if(r&&r.parent==e)return r;let i=t.parentNode;t=i!=e.dom?i:n>0?t.nextSibling:t.previousSibling}return null}function di(e,t){let n=t.startContainer,r=t.startOffset,i=t.endContainer,o=t.endOffset,a=e.docView.domAtPos(e.state.selection.main.anchor,1);return Q(a.node,a.offset,i,o)&&([n,r,i,o]=[i,o,n,r]),{anchorNode:n,anchorOffset:r,focusNode:i,focusOffset:o}}function hi(e,t){if(t.getComposedRanges){let n=t.getComposedRanges(e.root)[0];if(n)return di(e,n)}let n=null;function r(e){e.preventDefault(),e.stopImmediatePropagation(),n=e.getTargetRanges()[0]}return e.contentDOM.addEventListener("beforeinput",r,!0),e.dom.ownerDocument.execCommand("indent"),e.contentDOM.removeEventListener("beforeinput",r,!0),n?di(e,n):null}class pi{constructor(e){this.from=0,this.to=0,this.pendingContextChange=null,this.handlers=Object.create(null),this.composing=null,this.resetRange(e.state);let t=this.editContext=new window.EditContext({text:e.state.doc.sliceString(this.from,this.to),selectionStart:this.toContextPos(Math.max(this.from,Math.min(this.to,e.state.selection.main.anchor))),selectionEnd:this.toContextPos(e.state.selection.main.head)});this.handlers.textupdate=n=>{let i=e.state.selection.main,{anchor:o,head:a}=i,s=this.toEditorPos(n.updateRangeStart),l=this.toEditorPos(n.updateRangeEnd);e.inputState.composing>=0&&!this.composing&&(this.composing={contextBase:n.updateRangeStart,editorBase:s,drifted:!1});let c=l-s>n.text.length;s==this.from&&o<this.from?s=o:l==this.to&&o>this.to&&(l=o);let u=Rn(e.state.sliceDoc(s,l),n.text,(c?i.from:i.to)-s,c?"end":null);if(!u){let t=r.EditorSelection.single(this.toEditorPos(n.selectionStart),this.toEditorPos(n.selectionEnd));return void(In(t,i)||e.dispatch({selection:t,userEvent:"select"}))}let d={from:u.from+s,to:u.toA+s,insert:r.Text.of(n.text.slice(u.from,u.toB).split("\n"))};if((_.mac||_.android)&&d.from==a-1&&/^\. ?$/.test(n.text)&&"off"==e.contentDOM.getAttribute("autocorrect")&&(d={from:s,to:l,insert:r.Text.of([n.text.replace("."," ")])}),this.pendingContextChange=d,!e.state.readOnly){let t=this.to-this.from+(d.to-d.from+d.insert.length);An(e,d,r.EditorSelection.single(this.toEditorPos(n.selectionStart,t),this.toEditorPos(n.selectionEnd,t)))}this.pendingContextChange&&(this.revertPending(e.state),this.setSelection(e.state)),d.from<d.to&&!d.insert.length&&e.inputState.composing>=0&&!/[\\p{Alphabetic}\\p{Number}_]/.test(t.text.slice(Math.max(0,n.updateRangeStart-1),Math.min(t.text.length,n.updateRangeStart+1)))&&this.handlers.compositionend(n)},this.handlers.characterboundsupdate=n=>{let r=[],i=null;for(let t=this.toEditorPos(n.rangeStart),o=this.toEditorPos(n.rangeEnd);t<o;t++){let n=e.coordsForChar(t);i=n&&new DOMRect(n.left,n.top,n.right-n.left,n.bottom-n.top)||i||new DOMRect,r.push(i)}t.updateCharacterBounds(n.rangeStart,r)},this.handlers.textformatupdate=t=>{let n=[];for(let e of t.getTextFormats()){let t=e.underlineStyle,r=e.underlineThickness;if(!/none/i.test(t)&&!/none/i.test(r)){let i=this.toEditorPos(e.rangeStart),o=this.toEditorPos(e.rangeEnd);if(i<o){let e=`text-decoration: underline ${/^[a-z]/.test(t)?t+" ":"Dashed"==t?"dashed ":"Squiggle"==t?"wavy ":""}${/thin/i.test(r)?1:2}px`;n.push(M.mark({attributes:{style:e}}).range(i,o))}}}e.dispatch({effects:Je.of(M.set(n))})},this.handlers.compositionstart=()=>{e.inputState.composing<0&&(e.inputState.composing=0,e.inputState.compositionFirstChange=!0)},this.handlers.compositionend=()=>{if(e.inputState.composing=-1,e.inputState.compositionFirstChange=null,this.composing){let{drifted:t}=this.composing;this.composing=null,t&&this.reset(e.state)}};for(let n in this.handlers)t.addEventListener(n,this.handlers[n]);this.measureReq={read:e=>{let t=U(e.root);t&&t.rangeCount&&this.editContext.updateSelectionBounds(t.getRangeAt(0).getBoundingClientRect())}}}applyEdits(e){let t=0,n=!1,r=this.pendingContextChange;return e.changes.iterChanges((i,o,a,s,l)=>{if(n)return;let c=l.length-(o-i);if(r&&o>=r.to){if(r.from==i&&r.to==o&&r.insert.eq(l))return r=this.pendingContextChange=null,t+=c,void(this.to+=c);r=null,this.revertPending(e.state)}if(i+=t,o+=t,o<=this.from)this.from+=c,this.to+=c;else if(i<this.to){if(i<this.from||o>this.to||this.to-this.from+l.length>3e4)return void(n=!0);this.editContext.updateText(this.toContextPos(i),this.toContextPos(o),l.toString()),this.to+=c}t+=c}),r&&!n&&this.revertPending(e.state),!n}update(e){let t=this.pendingContextChange,n=e.startState.selection.main;this.composing&&(this.composing.drifted||!e.changes.touchesRange(n.from,n.to)&&e.transactions.some(e=>!e.isUserEvent("input.type")&&e.changes.touchesRange(this.from,this.to)))?(this.composing.drifted=!0,this.composing.editorBase=e.changes.mapPos(this.composing.editorBase)):this.applyEdits(e)&&this.rangeIsValid(e.state)?(e.docChanged||e.selectionSet||t)&&this.setSelection(e.state):(this.pendingContextChange=null,this.reset(e.state)),(e.geometryChanged||e.docChanged||e.selectionSet)&&e.view.requestMeasure(this.measureReq)}resetRange(e){let{head:t}=e.selection.main;this.from=Math.max(0,t-1e4),this.to=Math.min(e.doc.length,t+1e4)}reset(e){this.resetRange(e),this.editContext.updateText(0,this.editContext.text.length,e.doc.sliceString(this.from,this.to)),this.setSelection(e)}revertPending(e){let t=this.pendingContextChange;this.pendingContextChange=null,this.editContext.updateText(this.toContextPos(t.from),this.toContextPos(t.from+t.insert.length),e.doc.sliceString(t.from,t.to))}setSelection(e){let{main:t}=e.selection,n=this.toContextPos(Math.max(this.from,Math.min(this.to,t.anchor))),r=this.toContextPos(t.head);this.editContext.selectionStart==n&&this.editContext.selectionEnd==r||this.editContext.updateSelection(n,r)}rangeIsValid(e){let{head:t}=e.selection.main;return!(this.from>0&&t-this.from<500||this.to<e.doc.length&&this.to-t<500||this.to-this.from>3e4)}toEditorPos(e,t=this.to-this.from){e=Math.min(e,t);let n=this.composing;return n&&n.drifted?n.editorBase+(e-n.contextBase):e+this.from}toContextPos(e){let t=this.composing;return t&&t.drifted?t.contextBase+(e-t.editorBase):e-this.from}destroy(){for(let e in this.handlers)this.editContext.removeEventListener(e,this.handlers[e])}}class fi{get state(){return this.viewState.state}get viewport(){return this.viewState.viewport}get visibleRanges(){return this.viewState.visibleRanges}get inView(){return this.viewState.inView}get composing(){return!!this.inputState&&this.inputState.composing>0}get compositionStarted(){return!!this.inputState&&this.inputState.composing>=0}get root(){return this._root}get win(){return this.dom.ownerDocument.defaultView||window}constructor(e={}){var t;this.plugins=[],this.pluginMap=new Map,this.editorAttrs={},this.contentAttrs={},this.bidiCache=[],this.destroyed=!1,this.updateState=2,this.measureScheduled=-1,this.measureRequests=[],this.clearAnnouncement=-1,this.contentDOM=document.createElement("div"),this.scrollDOM=document.createElement("div"),this.scrollDOM.tabIndex=-1,this.scrollDOM.className="cm-scroller",this.scrollDOM.appendChild(this.contentDOM),this.announceDOM=document.createElement("div"),this.announceDOM.className="cm-announced",this.announceDOM.setAttribute("aria-live","polite"),this.dom=document.createElement("div"),this.dom.appendChild(this.announceDOM),this.dom.appendChild(this.scrollDOM),e.parent&&e.parent.appendChild(this.dom);let{dispatch:n}=e;this.dispatchTransactions=e.dispatchTransactions||n&&(e=>e.forEach(e=>n(e,this)))||(e=>this.update(e)),this.dispatch=this.dispatch.bind(this),this._root=e.root||ue(e.parent)||document,this.viewState=new Gr(this,e.state||r.EditorState.create(e)),e.scrollTo&&e.scrollTo.is(Ze)&&(this.viewState.scrollTarget=e.scrollTo.value.clip(this.viewState.state)),this.plugins=this.state.facet(rt).map(e=>new ot(e));for(let r of this.plugins)r.update(this);this.observer=new ci(this),this.inputState=new Mn(this),this.inputState.ensureHandlers(this.plugins),this.docView=new zt(this),this.mountStyles(),this.updateAttrs(),this.updateState=0,this.requestMeasure(),(null===(t=document.fonts)||void 0===t?void 0:t.ready)&&document.fonts.ready.then(()=>{this.viewState.mustMeasureContent="refresh",this.requestMeasure()})}dispatch(...e){let t=1==e.length&&e[0]instanceof r.Transaction?e:1==e.length&&Array.isArray(e[0])?e[0]:[this.state.update(...e)];this.dispatchTransactions(t,this)}update(e){if(0!=this.updateState)throw new Error("Calls to EditorView.update are not allowed while an update is in progress");let t,n=!1,i=!1,o=this.state;for(let r of e){if(r.startState!=o)throw new RangeError("Trying to update state with a transaction that doesn't start from the previous state.");o=r.state}if(this.destroyed)return void(this.viewState.state=o);let a=this.hasFocus,s=0,l=null;e.some(e=>e.annotation(pr))?(this.inputState.notifiedFocused=a,s=1):a!=this.inputState.notifiedFocused&&(this.inputState.notifiedFocused=a,l=fr(o,a),l||(s=1));let c=this.observer.delayedAndroidKey,u=null;if(c?(this.observer.clearDelayedAndroidKey(),u=this.observer.readChange(),(u&&!this.state.doc.eq(o.doc)||!this.state.selection.eq(o.selection))&&(u=null)):this.observer.clear(),o.facet(r.EditorState.phrases)!=this.state.facet(r.EditorState.phrases))return this.setState(o);t=bt.create(this,o,e),t.flags|=s;let d=this.viewState.scrollTarget;try{this.updateState=2;for(let t of e){if(d&&(d=d.map(t.changes)),t.scrollIntoView){let{main:e}=t.state.selection,{x:n,y:i}=this.state.facet(fi.cursorScrollMargin);d=new Ye(e.empty?e:r.EditorSelection.cursor(e.head,e.head>e.anchor?-1:1),"nearest","nearest",i,n)}for(let e of t.effects)e.is(Ze)&&(d=e.value.clip(this.state))}this.viewState.update(t,d),this.bidiCache=vi.update(this.bidiCache,t.changes),t.empty||(this.updatePlugins(t),this.inputState.update(t)),n=this.docView.update(t),this.state.facet(gt)!=this.styleModules&&this.mountStyles(),i=this.updateAttrs(),this.showAnnouncements(e),this.docView.updateSelection(n,e.some(e=>e.isUserEvent("select.pointer")))}finally{this.updateState=0}if(t.startState.facet(Jr)!=t.state.facet(Jr)&&(this.viewState.mustMeasureContent=!0),(n||i||d||this.viewState.mustEnforceCursorAssoc||this.viewState.mustMeasureContent)&&this.requestMeasure(),n&&this.docViewUpdate(),!t.empty)for(let r of this.state.facet(Ge))try{r(t)}catch(h){et(this.state,h,"update listener")}(l||u)&&Promise.resolve().then(()=>{l&&this.state==l.startState&&this.dispatch(l),u&&!Cn(this,u)&&c.force&&ce(this.contentDOM,c.key,c.keyCode)})}setState(e){if(0!=this.updateState)throw new Error("Calls to EditorView.setState are not allowed while an update is in progress");if(this.destroyed)return void(this.viewState.state=e);this.updateState=2;let t=this.hasFocus;try{for(let e of this.plugins)e.destroy(this);this.viewState=new Gr(this,e),this.plugins=e.facet(rt).map(e=>new ot(e)),this.pluginMap.clear();for(let e of this.plugins)e.update(this);this.docView.destroy(),this.docView=new zt(this),this.inputState.ensureHandlers(this.plugins),this.mountStyles(),this.updateAttrs(),this.bidiCache=[]}finally{this.updateState=0}t&&this.focus(),this.requestMeasure()}updatePlugins(e){let t=e.startState.facet(rt),n=e.state.facet(rt);if(t!=n){let r=[];for(let i of n){let n=t.indexOf(i);if(n<0)r.push(new ot(i));else{let t=this.plugins[n];t.mustUpdate=e,r.push(t)}}for(let t of this.plugins)t.mustUpdate!=e&&t.destroy(this);this.plugins=r,this.pluginMap.clear()}else for(let r of this.plugins)r.mustUpdate=e;for(let r=0;r<this.plugins.length;r++)this.plugins[r].update(this);t!=n&&this.inputState.ensureHandlers(this.plugins)}docViewUpdate(){for(let t of this.plugins){let n=t.value;if(n&&n.docViewUpdate)try{n.docViewUpdate(this)}catch(e){et(this.state,e,"doc view update listener")}}}measure(e=!0){if(this.destroyed)return;if(this.measureScheduled>-1&&this.win.cancelAnimationFrame(this.measureScheduled),this.observer.delayedAndroidKey)return this.measureScheduled=-1,void this.requestMeasure();this.measureScheduled=0,e&&this.observer.forceFlush();let t=null,n=this.viewState.scrollParent,r=this.viewState.getScrollOffset(),{scrollAnchorPos:i,scrollAnchorHeight:o,scaleY:a}=this.viewState;Math.abs(r-this.viewState.scrollOffset)>1&&(o=-1),this.viewState.scrollAnchorHeight=-1;try{for(let e=0;;e++){if(o<0){if(he(n||this.win))i=-1,o=this.viewState.heightMap.height/this.viewState.scaleY;else{let e=this.viewState.scrollAnchorAt(r);i=e.from,o=e.top}a=this.viewState.scaleY}this.updateState=1;let l=this.viewState.measure();if(!l&&!this.measureRequests.length&&null==this.viewState.scrollTarget)break;if(e>5){p.warn(this.measureRequests.length?"Measure loop restarted more than 5 times":"Viewport failed to stabilize");break}let c=[];4&l||([this.measureRequests,c]=[c,this.measureRequests]);let u=c.map(e=>{try{return e.read(this)}catch(t){return et(this.state,t),gi}}),d=bt.create(this,this.state,[]),h=!1;d.flags|=l,t?t.flags|=l:t=d,this.updateState=2,d.empty||(this.updatePlugins(d),this.inputState.update(d),this.updateAttrs(),h=this.docView.update(d),h&&this.docViewUpdate());for(let e=0;e<c.length;e++)if(u[e]!=gi)try{let t=c[e];t.write&&t.write(u[e],this)}catch(s){et(this.state,s)}if(h&&this.docView.updateSelection(!0),!d.viewportChanged&&0==this.measureRequests.length){if(this.viewState.editorHeight){if(this.viewState.scrollTarget){this.docView.scrollIntoView(this.viewState.scrollTarget),this.viewState.scrollTarget=null,o=-1;continue}{let e=i<0?this.viewState.heightMap.height:this.viewState.lineBlockAt(i).top,t=e/this.viewState.scaleY-o/a;if((t>1||t<-1)&&!(_.ios&&this.inputState.lastIOSMomentumScroll>Date.now()-100)&&(n==this.scrollDOM||this.hasFocus||Math.max(this.inputState.lastWheelEvent,this.inputState.lastTouchTime)>Date.now()-100)){r+=t,n?i<0?n.scrollTop=n.scrollHeight:n.scrollTop+=t:this.win.scrollBy(0,t),o=-1;continue}}}break}}}finally{this.updateState=0,this.measureScheduled=-1}if(t&&!t.empty)for(let l of this.state.facet(Ge))l(t)}get themeClasses(){return ti+" "+(this.state.facet(ei)?ri:ni)+" "+this.state.facet(Jr)}updateAttrs(){let e=bi(this,at,{class:"cm-editor"+(this.hasFocus?" cm-focused ":" ")+this.themeClasses}),t={spellcheck:"false",autocorrect:"off",autocapitalize:"off",writingsuggestions:"false",translate:"no",contenteditable:this.state.facet(tt)?"true":"false",class:"cm-content",style:`${_.tabSize}: ${this.state.tabSize}`,role:"textbox","aria-multiline":"true"};this.state.readOnly&&(t["aria-readonly"]="true"),bi(this,st,t);let n=this.observer.ignore(()=>{let n=R(this.contentDOM,this.contentAttrs,t),r=R(this.dom,this.editorAttrs,e);return n||r});return this.editorAttrs=e,this.contentAttrs=t,n}showAnnouncements(e){let t=!0;for(let n of e)for(let e of n.effects)if(e.is(fi.announce)){t&&(this.announceDOM.textContent="",this.win.clearTimeout(this.clearAnnouncement),this.clearAnnouncement=this.win.setTimeout(()=>{this.announceDOM.textContent=" "},200),t=!1);let n=this.announceDOM.appendChild(document.createElement("div"));n.textContent=e.value}}mountStyles(){this.styleModules=this.state.facet(gt);let e=this.state.facet(fi.cspNonce);i.G.mount(this.root,this.styleModules.concat(ai).reverse(),e?{nonce:e}:void 0)}readMeasured(){if(2==this.updateState)throw new Error("Reading the editor layout isn't allowed during an update");0==this.updateState&&this.measureScheduled>-1&&this.measure(!1)}requestMeasure(e){if(this.measureScheduled<0&&(this.measureScheduled=this.win.requestAnimationFrame(()=>this.measure())),e){if(this.measureRequests.indexOf(e)>-1)return;if(null!=e.key)for(let t=0;t<this.measureRequests.length;t++)if(this.measureRequests[t].key===e.key)return void(this.measureRequests[t]=e);this.measureRequests.push(e)}}plugin(e){let t=this.pluginMap.get(e);return(void 0===t||t&&t.plugin!=e)&&this.pluginMap.set(e,t=this.plugins.find(t=>t.plugin==e)||null),t&&t.update(this).value}get documentTop(){return this.contentDOM.getBoundingClientRect().top+this.viewState.paddingTop}get documentPadding(){return{top:this.viewState.paddingTop,bottom:this.viewState.paddingBottom}}get scaleX(){return this.viewState.scaleX}get scaleY(){return this.viewState.scaleY}elementAtHeight(e){return this.readMeasured(),this.viewState.elementAtHeight(e)}lineBlockAtHeight(e){return this.readMeasured(),this.viewState.lineBlockAtHeight(e)}get viewportLineBlocks(){return this.viewState.viewportLines}lineBlockAt(e){return this.viewState.lineBlockAt(e)}get contentHeight(){return this.viewState.contentHeight}moveByChar(e,t,n){return gn(this,e,dn(this,e,t,n))}moveByGroup(e,t){return gn(this,e,dn(this,e,t,t=>hn(this,e.head,t)))}visualLineSide(e,t){return t?r.EditorSelection.cursor(e.to,1):r.EditorSelection.cursor(e.from,-1)}moveToLineBoundary(e,t,n=!0){return un(this,e,t,n)}moveVertically(e,t,n){return gn(this,e,pn(this,e,t,n))}domAtPos(e,t=1){return this.docView.domAtPos(e,t)}posAtDOM(e,t=0){return this.docView.posFromDOM(e,t)}posAtCoords(e,t=!0){this.readMeasured();let n=bn(this,e,t);return n&&n.pos}posAndSideAtCoords(e,t=!0){return this.readMeasured(),bn(this,e,t)}coordsAtPos(e,t=1){this.readMeasured();let n=this.state.doc.lineAt(e),r=this.bidiSpans(n),i=r[ke.find(r,e-n.from,-1,t)];return n.length&&(e==n.from&&t<0||e==n.to&&t>0)&&i.dir!=this.textDirectionAt(n.from)&&(e==n.to?(e=n.from+i.from,t=1):(e=n.from+i.to,t=-1)),this.docView.coordsAt(e,t,i.dir==ge.RTL)}coordsForChar(e){return this.readMeasured(),this.docView.coordsForChar(e)}get defaultCharacterWidth(){return this.viewState.heightOracle.charWidth}get defaultLineHeight(){return this.viewState.heightOracle.lineHeight}get textDirection(){return this.viewState.defaultTextDirection}textDirectionAt(e){let t=this.state.facet(Ke);return!t||e<this.viewport.from||e>this.viewport.to?this.textDirection:(this.readMeasured(),this.docView.textDirectionAt(e))}get lineWrapping(){return this.viewState.heightOracle.lineWrapping}bidiSpans(e){if(e.length>mi)return De(e.length);let t,n=this.textDirectionAt(e.from);for(let i of this.bidiCache)if(i.from==e.from&&i.dir==n&&(i.fresh||Ce(i.isolates,t=pt(this,e))))return i.order;t||(t=pt(this,e));let r=Me(e.text,n,t);return this.bidiCache.push(new vi(e.from,e.to,n,t,!0,r)),r}get hasFocus(){var e;return(this.dom.ownerDocument.hasFocus()||_.safari&&(null===(e=this.inputState)||void 0===e?void 0:e.lastContextMenu)>Date.now()-3e4)&&this.root.activeElement==this.contentDOM}focus(){this.observer.ignore(()=>{se(this.contentDOM),this.docView.updateSelection()})}setRoot(e){this._root!=e&&(this._root=e,this.observer.setWindow((9==e.nodeType?e:e.ownerDocument).defaultView||window),this.mountStyles())}destroy(){this.root.activeElement==this.contentDOM&&this.contentDOM.blur();for(let e of this.plugins)e.destroy(this);this.plugins=[],this.inputState.destroy(),this.docView.destroy(),this.dom.remove(),this.observer.destroy(),this.win.clearTimeout(this.clearAnnouncement),this.measureScheduled>-1&&this.win.cancelAnimationFrame(this.measureScheduled),this.destroyed=!0}static scrollIntoView(e,t={}){var n,i,o,a;return Ze.of(new Ye("number"==typeof e?r.EditorSelection.cursor(e):e,null!==(n=t.y)&&void 0!==n?n:"nearest",null!==(i=t.x)&&void 0!==i?i:"nearest",null!==(o=t.yMargin)&&void 0!==o?o:5,null!==(a=t.xMargin)&&void 0!==a?a:5))}scrollSnapshot(){let{scrollTop:e,scrollLeft:t}=this.scrollDOM,n=this.viewState.scrollAnchorAt(e);return Ze.of(new Ye(r.EditorSelection.cursor(n.from),"start","start",n.top-e,t,!0))}setTabFocusMode(e){null==e?this.inputState.tabFocusMode=this.inputState.tabFocusMode<0?0:-1:"boolean"==typeof e?this.inputState.tabFocusMode=e?0:-1:0!=this.inputState.tabFocusMode&&(this.inputState.tabFocusMode=Date.now()+e)}static domEventHandlers(e){return it.define(()=>({}),{eventHandlers:e})}static domEventObservers(e){return it.define(()=>({}),{eventObservers:e})}static theme(e,t){let n=i.G.newName(),r=[Jr.of(n),gt.of(oi(`.${n}`,e))];return t&&t.dark&&r.push(ei.of(!0)),r}static baseTheme(e){return r.Prec.lowest(gt.of(oi("."+ti,e,ii)))}static findFromDOM(e){var t;let n=e.querySelector(".cm-content"),r=n&&wt.get(n)||wt.get(e);return(null===(t=null===r||void 0===r?void 0:r.root)||void 0===t?void 0:t.view)||null}}fi.styleModule=gt,fi.inputHandler=He,fi.clipboardInputFilter=Qe,fi.clipboardOutputFilter=ze,fi.scrollHandler=Xe,fi.focusChangeEffect=qe,fi.perLineTextDirection=Ke,fi.exceptionSink=Ue,fi.updateListener=Ge,fi.editable=tt,fi.mouseSelectionStyle=je,fi.dragMovesSelection=Fe,fi.clickAddsSelectionRange=Ve,fi.decorations=lt,fi.blockWrappers=ct,fi.outerDecorations=ut,fi.atomicRanges=dt,fi.bidiIsolatedRanges=ht,fi.cursorScrollMargin=r.Facet.define({combine:e=>{let t=5,n=5;for(let r of e)"number"==typeof r?t=n=r:({x:t,y:n}=r);return{x:t,y:n}}}),fi.scrollMargins=ft,fi.darkTheme=ei,fi.cspNonce=r.Facet.define({combine:e=>e.length?e[0]:""}),fi.contentAttributes=st,fi.editorAttributes=at,fi.lineWrapping=fi.contentAttributes.of({class:"cm-lineWrapping"}),fi.announce=r.StateEffect.define();const mi=4096,gi={};class vi{constructor(e,t,n,r,i,o){this.from=e,this.to=t,this.dir=n,this.isolates=r,this.fresh=i,this.order=o}static update(e,t){if(t.empty&&!e.some(e=>e.fresh))return e;let n=[],r=e.length?e[e.length-1].dir:ge.LTR;for(let i=Math.max(0,e.length-10);i<e.length;i++){let o=e[i];o.dir!=r||t.touchesRange(o.from,o.to)||n.push(new vi(t.mapPos(o.from,1),t.mapPos(o.to,-1),o.dir,o.isolates,!1,o.order))}return n}}function bi(e,t,n){for(let r=e.state.facet(t),i=r.length-1;i>=0;i--){let t=r[i],o="function"==typeof t?t(e):t;o&&k(o,n)}return n}const yi=_.mac?"mac":_.windows?"win":_.linux?"linux":"key";function wi(e,t){const n=e.split(/-(?!$)/);let r,i,o,a,s=n[n.length-1];"Space"==s&&(s=" ");for(let l=0;l<n.length-1;++l){const e=n[l];if(/^(cmd|meta|m)$/i.test(e))a=!0;else if(/^a(lt)?$/i.test(e))r=!0;else if(/^(c|ctrl|control)$/i.test(e))i=!0;else if(/^s(hift)?$/i.test(e))o=!0;else{if(!/^mod$/i.test(e))throw new Error("Unrecognized modifier name: "+e);"mac"==t?a=!0:i=!0}}return r&&(s="Alt-"+s),i&&(s="Ctrl-"+s),a&&(s="Meta-"+s),o&&(s="Shift-"+s),s}function Oi(e,t,n){return t.altKey&&(e="Alt-"+e),t.ctrlKey&&(e="Ctrl-"+e),t.metaKey&&(e="Meta-"+e),!1!==n&&t.shiftKey&&(e="Shift-"+e),e}const Si=r.Prec.default(fi.domEventHandlers({keydown(e,t){return Ni(_i(t.state),e,t,"editor")}})),Ei=r.Facet.define({enables:Si}),xi=new WeakMap;function _i(e){let t=e.facet(Ei),n=xi.get(t);return n||xi.set(t,n=Ti(t.reduce((e,t)=>e.concat(t),[]))),n}function ki(e,t,n){return Ni(_i(e.state),t,e,n)}let Ci=null;const Ai=4e3;function Ti(e,t=yi){let n=Object.create(null),r=Object.create(null),i=(e,t)=>{let n=r[e];if(null==n)r[e]=t;else if(n!=t)throw new Error("Key binding "+e+" is used both as a regular binding and as a multi-stroke prefix")},o=(e,r,o,a,s)=>{var l,c;let u=n[e]||(n[e]=Object.create(null)),d=r.split(/ (?!$)/).map(e=>wi(e,t));for(let t=1;t<d.length;t++){let n=d.slice(0,t).join(" ");i(n,!0),u[n]||(u[n]={preventDefault:!0,stopPropagation:!1,run:[t=>{let r=Ci={view:t,prefix:n,scope:e};return setTimeout(()=>{Ci==r&&(Ci=null)},Ai),!0}]})}let h=d.join(" ");i(h,!1);let p=u[h]||(u[h]={preventDefault:!1,stopPropagation:!1,run:(null===(c=null===(l=u._any)||void 0===l?void 0:l.run)||void 0===c?void 0:c.slice())||[]});o&&p.run.push(o),a&&(p.preventDefault=!0),s&&(p.stopPropagation=!0)};for(let a of e){let e=a.scope?a.scope.split(" "):["editor"];if(a.any)for(let t of e){let e=n[t]||(n[t]=Object.create(null));e._any||(e._any={preventDefault:!1,stopPropagation:!1,run:[]});let{any:r}=a;for(let t in e)e[t].run.push(e=>r(e,Ri))}let r=a[t]||a.key;if(r)for(let t of e)o(t,r,a.run,a.preventDefault,a.stopPropagation),a.shift&&o(t,"Shift-"+r,a.shift,a.preventDefault,a.stopPropagation)}return n}let Ri=null;function Ni(e,t,n,i){Ri=t;let s=d(t),l=(0,r.codePointAt)(s,0),c=(0,r.codePointSize)(l)==s.length&&" "!=s,u="",h=!1,p=!1,f=!1;Ci&&Ci.view==n&&Ci.scope==i&&(u=Ci.prefix+" ",Fn.indexOf(t.keyCode)<0&&(p=!0,Ci=null));let m,g,v=new Set,b=e=>{if(e){for(let t of e.run)if(!v.has(t)&&(v.add(t),t(n)))return e.stopPropagation&&(f=!0),!0;e.preventDefault&&(e.stopPropagation&&(f=!0),p=!0)}return!1},y=e[i];return y&&(b(y[u+Oi(s,t,!c)])?h=!0:!c||!(t.altKey||t.metaKey||t.ctrlKey)||_.windows&&t.ctrlKey&&t.altKey||_.mac&&t.altKey&&!t.ctrlKey&&!t.metaKey||!(m=o[t.keyCode])||m==s?c&&t.shiftKey&&b(y[u+Oi(s,t,!0)])&&(h=!0):(b(y[u+Oi(m,t,!0)])||t.shiftKey&&(g=a[t.keyCode])!=s&&g!=m&&b(y[u+Oi(g,t,!1)]))&&(h=!0),!h&&b(y._any)&&(h=!0)),p&&(h=!0),h&&f&&t.stopPropagation(),Ri=null,h}class Pi{constructor(e,t,n,r,i){this.className=e,this.left=t,this.top=n,this.width=r,this.height=i}draw(){let e=document.createElement("div");return e.className=this.className,this.adjust(e),e}update(e,t){return t.className==this.className&&(this.adjust(e),!0)}adjust(e){e.style.left=this.left+"px",e.style.top=this.top+"px",null!=this.width&&(e.style.width=this.width+"px"),e.style.height=this.height+"px"}eq(e){return this.left==e.left&&this.top==e.top&&this.width==e.width&&this.height==e.height&&this.className==e.className}static forRange(e,t,n){if(n.empty){let r=e.coordsAtPos(n.head,n.assoc||1);if(!r)return[];let i=Ii(e);return[new Pi(t,r.left-i.left,r.top-i.top,null,r.bottom-r.top)]}return Di(e,t,n)}}function Ii(e){let t=e.scrollDOM.getBoundingClientRect(),n=e.textDirection==ge.LTR?t.left:t.right-e.scrollDOM.clientWidth*e.scaleX;return{left:n-e.scrollDOM.scrollLeft*e.scaleX,top:t.top-e.scrollDOM.scrollTop*e.scaleY}}function Mi(e,t,n,r){let i=e.coordsAtPos(t,2*n);if(!i)return r;let o=e.dom.getBoundingClientRect(),a=(i.top+i.bottom)/2,s=e.posAtCoords({x:o.left+1,y:a}),l=e.posAtCoords({x:o.right-1,y:a});return null==s||null==l?r:{from:Math.max(r.from,Math.min(s,l)),to:Math.min(r.to,Math.max(s,l))}}function Di(e,t,n){if(n.to<=e.viewport.from||n.from>=e.viewport.to)return[];let r=Math.max(n.from,e.viewport.from),i=Math.min(n.to,e.viewport.to),o=e.textDirection==ge.LTR,a=e.contentDOM,s=a.getBoundingClientRect(),l=Ii(e),c=a.querySelector(".cm-line"),u=c&&window.getComputedStyle(c),d=s.left+(u?parseInt(u.paddingLeft)+Math.min(0,parseInt(u.textIndent)):0),h=s.right-(u?parseInt(u.paddingRight):0),p=cn(e,r,1),f=cn(e,i,-1),m=p.type==I.Text?p:null,g=f.type==I.Text?f:null;if(m&&(e.lineWrapping||p.widgetLineBreaks)&&(m=Mi(e,r,1,m)),g&&(e.lineWrapping||f.widgetLineBreaks)&&(g=Mi(e,i,-1,g)),m&&g&&m.from==g.from&&m.to==g.to)return b(y(n.from,n.to,m));{let t=m?y(n.from,null,m):w(p,!1),r=g?y(null,n.to,g):w(f,!0),i=[];return(m||p).to<(g||f).from-(m&&g?1:0)||p.widgetLineBreaks>1&&t.bottom+e.defaultLineHeight/2<r.top?i.push(v(d,t.bottom,h,r.top)):t.bottom<r.top&&e.elementAtHeight((t.bottom+r.top)/2).type==I.Text&&(t.bottom=r.top=(t.bottom+r.top)/2),b(t).concat(i).concat(b(r))}function v(e,n,r,i){return new Pi(t,e-l.left,n-l.top,Math.max(0,r-e),i-n)}function b({top:e,bottom:t,horizontal:n}){let r=[];for(let i=0;i<n.length;i+=2)r.push(v(n[i],e,n[i+1],t));return r}function y(t,n,r){let i=1e9,a=-1e9,s=[];function l(t,n,l,c,u){let p=e.coordsAtPos(t,t==r.to?-2:2),f=e.coordsAtPos(l,l==r.from?2:-2);p&&f&&(i=Math.min(p.top,f.top,i),a=Math.max(p.bottom,f.bottom,a),u==ge.LTR?s.push(o&&n?d:p.left,o&&c?h:f.right):s.push(!o&&c?d:f.left,!o&&n?h:p.right))}let c=null!==t&&void 0!==t?t:r.from,u=null!==n&&void 0!==n?n:r.to;for(let o of e.visibleRanges)if(o.to>c&&o.from<u)for(let r=Math.max(o.from,c),i=Math.min(o.to,u);;){let o=e.state.doc.lineAt(r);for(let a of e.bidiSpans(o)){let e=a.from+o.from,s=a.to+o.from;if(e>=i)break;s>r&&l(Math.max(e,r),null==t&&e<=c,Math.min(s,i),null==n&&s>=u,a.dir)}if(r=o.to+1,r>=i)break}return 0==s.length&&l(c,null==t,u,null==n,e.textDirection),{top:i,bottom:a,horizontal:s}}function w(e,t){let n=s.top+(t?e.top:e.bottom);return{top:n,bottom:n,horizontal:[]}}}function Li(e,t){return e.constructor==t.constructor&&e.eq(t)}class Bi{constructor(e,t){this.view=e,this.layer=t,this.drawn=[],this.scaleX=1,this.scaleY=1,this.measureReq={read:this.measure.bind(this),write:this.draw.bind(this)},this.dom=e.scrollDOM.appendChild(document.createElement("div")),this.dom.classList.add("cm-layer"),t.above&&this.dom.classList.add("cm-layer-above"),t.class&&this.dom.classList.add(t.class),this.scale(),this.dom.setAttribute("aria-hidden","true"),this.setOrder(e.state),e.requestMeasure(this.measureReq),t.mount&&t.mount(this.dom,e)}update(e){e.startState.facet($i)!=e.state.facet($i)&&this.setOrder(e.state),(this.layer.update(e,this.dom)||e.geometryChanged)&&(this.scale(),e.view.requestMeasure(this.measureReq))}docViewUpdate(e){!1!==this.layer.updateOnDocViewUpdate&&e.requestMeasure(this.measureReq)}setOrder(e){let t=0,n=e.facet($i);while(t<n.length&&n[t]!=this.layer)t++;this.dom.style.zIndex=String((this.layer.above?150:-1)-t)}measure(){return this.layer.markers(this.view)}scale(){let{scaleX:e,scaleY:t}=this.view;e==this.scaleX&&t==this.scaleY||(this.scaleX=e,this.scaleY=t,this.dom.style.transform=`scale(${1/e}, ${1/t})`)}draw(e){if(e.length!=this.drawn.length||e.some((e,t)=>!Li(e,this.drawn[t]))){let t=this.dom.firstChild,n=0;for(let r of e)r.update&&t&&r.constructor&&this.drawn[n].constructor&&r.update(t,this.drawn[n])?(t=t.nextSibling,n++):this.dom.insertBefore(r.draw(),t);while(t){let e=t.nextSibling;t.remove(),t=e}this.drawn=e,_.webkit&&(this.dom.style.display=this.dom.firstChild?"":"none")}}destroy(){this.layer.destroy&&this.layer.destroy(this.dom,this.view),this.dom.remove()}}const $i=r.Facet.define();function Vi(e){return[it.define(t=>new Bi(t,e)),$i.of(e)]}const Fi=r.Facet.define({combine(e){return(0,r.combineConfig)(e,{cursorBlinkRate:1200,drawRangeCursor:!0,iosSelectionHandles:!0},{cursorBlinkRate:(e,t)=>Math.min(e,t),drawRangeCursor:(e,t)=>e||t})}});function ji(e={}){return[Fi.of(e),Hi,Qi,Ki,We.of(!0)]}function Ui(e){return e.facet(Fi)}function Gi(e){return e.startState.facet(Fi)!=e.state.facet(Fi)}const Hi=Vi({above:!0,markers(e){let{state:t}=e,n=t.facet(Fi),i=[];for(let o of t.selection.ranges){let a=o==t.selection.main;if(o.empty||n.drawRangeCursor&&!(a&&_.ios&&n.iosSelectionHandles)){let t=a?"cm-cursor cm-cursor-primary":"cm-cursor cm-cursor-secondary",n=o.empty?o:r.EditorSelection.cursor(o.head,o.assoc);for(let r of Pi.forRange(e,t,n))i.push(r)}}return i},update(e,t){e.transactions.some(e=>e.selection)&&(t.style.animationName="cm-blink"==t.style.animationName?"cm-blink2":"cm-blink");let n=Gi(e);return n&&qi(e.state,t),e.docChanged||e.selectionSet||n},mount(e,t){qi(t.state,e)},class:"cm-cursorLayer"});function qi(e,t){t.style.animationDuration=e.facet(Fi).cursorBlinkRate+"ms"}const Qi=Vi({above:!1,markers(e){let t=[],{main:n,ranges:i}=e.state.selection;for(let r of i)if(!r.empty)for(let n of Pi.forRange(e,"cm-selectionBackground",r))t.push(n);if(_.ios&&!n.empty&&e.state.facet(Fi).iosSelectionHandles){for(let i of Pi.forRange(e,"cm-selectionHandle cm-selectionHandle-start",r.EditorSelection.cursor(n.from,1)))t.push(i);for(let i of Pi.forRange(e,"cm-selectionHandle cm-selectionHandle-end",r.EditorSelection.cursor(n.to,1)))t.push(i)}return t},update(e,t){return e.docChanged||e.selectionSet||e.viewportChanged||Gi(e)},class:"cm-selectionLayer"}),zi=_.gecko&&153==_.gecko_version?"#ffffff01":"transparent",Ki=r.Prec.highest(fi.theme({".cm-line":{"& ::selection, &::selection":{backgroundColor:`${zi} !important`},caretColor:"transparent !important"},".cm-content":{caretColor:"transparent !important","& :focus":{caretColor:"initial !important","&::selection, & ::selection":{backgroundColor:"Highlight !important"}}}})),Wi=r.StateEffect.define({map(e,t){return null==e?null:t.mapPos(e)}}),Xi=r.StateField.define({create(){return null},update(e,t){return null!=e&&(e=t.changes.mapPos(e)),t.effects.reduce((e,t)=>t.is(Wi)?t.value:e,e)}}),Yi=it.fromClass(class{constructor(e){this.view=e,this.cursor=null,this.measureReq={read:this.readPos.bind(this),write:this.drawCursor.bind(this)}}update(e){var t;let n=e.state.field(Xi);null==n?null!=this.cursor&&(null===(t=this.cursor)||void 0===t||t.remove(),this.cursor=null):(this.cursor||(this.cursor=this.view.scrollDOM.appendChild(document.createElement("div")),this.cursor.className="cm-dropCursor"),(e.startState.field(Xi)!=n||e.docChanged||e.geometryChanged)&&this.view.requestMeasure(this.measureReq))}readPos(){let{view:e}=this,t=e.state.field(Xi),n=null!=t&&e.coordsAtPos(t);if(!n)return null;let r=e.scrollDOM.getBoundingClientRect();return{left:n.left-r.left+e.scrollDOM.scrollLeft*e.scaleX,top:n.top-r.top+e.scrollDOM.scrollTop*e.scaleY,height:n.bottom-n.top}}drawCursor(e){if(this.cursor){let{scaleX:t,scaleY:n}=this.view;e?(this.cursor.style.left=e.left/t+"px",this.cursor.style.top=e.top/n+"px",this.cursor.style.height=e.height/n+"px"):this.cursor.style.left="-100000px"}}destroy(){this.cursor&&this.cursor.remove()}setDropPos(e){this.view.state.field(Xi)!=e&&this.view.dispatch({effects:Wi.of(e)})}},{eventObservers:{dragover(e){this.setDropPos(this.view.posAtCoords({x:e.clientX,y:e.clientY}))},dragleave(e){e.target!=this.view.contentDOM&&this.view.contentDOM.contains(e.relatedTarget)||this.setDropPos(null)},dragend(){this.setDropPos(null)},drop(){this.setDropPos(null)}}});function Zi(){return[Xi,Yi]}function Ji(e,t,n,r,i){t.lastIndex=0;for(let o,a=e.iterRange(n,r),s=n;!a.next().done;s+=a.value.length)if(!a.lineBreak)while(o=t.exec(a.value))i(s+o.index,o)}function eo(e,t){let n=e.visibleRanges;if(1==n.length&&n[0].from==e.viewport.from&&n[0].to==e.viewport.to)return n;let r=[];for(let{from:i,to:o}of n)i=Math.max(e.state.doc.lineAt(i).from,i-t),o=Math.min(e.state.doc.lineAt(o).to,o+t),r.length&&r[r.length-1].to>=i?r[r.length-1].to=o:r.push({from:i,to:o});return r}class to{constructor(e){const{regexp:t,decoration:n,decorate:r,boundary:i,maxLength:o=1e3}=e;if(!t.global)throw new RangeError("The regular expression given to MatchDecorator should have its 'g' flag set");if(this.regexp=t,r)this.addMatch=(e,t,n,i)=>r(i,n,n+e[0].length,e,t);else if("function"==typeof n)this.addMatch=(e,t,r,i)=>{let o=n(e,t,r);o&&i(r,r+e[0].length,o)};else{if(!n)throw new RangeError("Either 'decorate' or 'decoration' should be provided to MatchDecorator");this.addMatch=(e,t,r,i)=>i(r,r+e[0].length,n)}this.boundary=i,this.maxLength=o}createDeco(e){let t=new r.RangeSetBuilder,n=t.add.bind(t);for(let{from:r,to:i}of eo(e,this.maxLength))Ji(e.state.doc,this.regexp,r,i,(t,r)=>this.addMatch(r,e,t,n));return t.finish()}updateDeco(e,t){let n=1e9,r=-1;return e.docChanged&&e.changes.iterChanges((t,i,o,a)=>{a>=e.view.viewport.from&&o<=e.view.viewport.to&&(n=Math.min(o,n),r=Math.max(a,r))}),e.viewportMoved||r-n>1e3?this.createDeco(e.view):r>-1?this.updateRange(e.view,t.map(e.changes),n,r):t}updateRange(e,t,n,r){for(let i of e.visibleRanges){let o=Math.max(i.from,n),a=Math.min(i.to,r);if(a>=o){let n=e.state.doc.lineAt(o),r=n.to<a?e.state.doc.lineAt(a):n,s=Math.max(i.from,n.from),l=Math.min(i.to,r.to);if(this.boundary){for(;o>n.from;o--)if(this.boundary.test(n.text[o-1-n.from])){s=o;break}for(;a<r.to;a++)if(this.boundary.test(r.text[a-r.from])){l=a;break}}let c,u=[],d=(e,t,n)=>u.push(n.range(e,t));if(n==r){this.regexp.lastIndex=s-n.from;while((c=this.regexp.exec(n.text))&&c.index<l-n.from)this.addMatch(c,e,c.index+n.from,d)}else Ji(e.state.doc,this.regexp,s,l,(t,n)=>this.addMatch(n,e,t,d));t=t.update({filterFrom:s,filterTo:l,filter:(e,t)=>e<s||t>l,add:u})}}return t}}const no=null!=/x/.unicode?"gu":"g",ro=new RegExp("[\0-\b\n--\u2028\u2029\ufeff-]",no),io={0:"null",7:"bell",8:"backspace",10:"newline",11:"vertical tab",13:"carriage return",27:"escape",8203:"zero width space",8204:"zero width non-joiner",8205:"zero width joiner",8206:"left-to-right mark",8207:"right-to-left mark",8232:"line separator",8237:"left-to-right override",8238:"right-to-left override",8294:"left-to-right isolate",8295:"right-to-left isolate",8297:"pop directional isolate",8233:"paragraph separator",65279:"zero width no-break space",65532:"object replacement"};let oo=null;function ao(){var e;if(null==oo&&"undefined"!=typeof document&&document.body){let t=document.body.style;oo=null!=(null!==(e=t.tabSize)&&void 0!==e?e:t.MozTabSize)}return oo||!1}const so=r.Facet.define({combine(e){let t=(0,r.combineConfig)(e,{render:null,specialChars:ro,addSpecialChars:null});return(t.replaceTabs=!ao())&&(t.specialChars=new RegExp("\t|"+t.specialChars.source,no)),t.addSpecialChars&&(t.specialChars=new RegExp(t.specialChars.source+"|"+t.addSpecialChars.source,no)),t}});function lo(e={}){return[so.of(e),uo()]}let co=null;function uo(){return co||(co=it.fromClass(class{constructor(e){this.view=e,this.decorations=M.none,this.decorationCache=Object.create(null),this.decorator=this.makeDecorator(e.state.facet(so)),this.decorations=this.decorator.createDeco(e)}makeDecorator(e){return new to({regexp:e.specialChars,decoration:(t,n,i)=>{let{doc:o}=n.state,a=(0,r.codePointAt)(t[0],0);if(9==a){let e=o.lineAt(i),t=n.state.tabSize,a=(0,r.countColumn)(e.text,t,i-e.from);return M.replace({widget:new mo((t-a%t)*this.view.defaultCharacterWidth/this.view.scaleX)})}return this.decorationCache[a]||(this.decorationCache[a]=M.replace({widget:new fo(e,a)}))},boundary:e.replaceTabs?void 0:/[^]/})}update(e){let t=e.state.facet(so);e.startState.facet(so)!=t?(this.decorator=this.makeDecorator(t),this.decorations=this.decorator.createDeco(e.view)):this.decorations=this.decorator.updateDeco(e,this.decorations)}},{decorations:e=>e.decorations}))}const ho="•";function po(e){return e>=32?ho:10==e?"":String.fromCharCode(9216+e)}class fo extends P{constructor(e,t){super(),this.options=e,this.code=t}eq(e){return e.code==this.code}toDOM(e){let t=po(this.code),n=e.state.phrase("Control character")+" "+(io[this.code]||"0x"+this.code.toString(16)),r=this.options.render&&this.options.render(this.code,n,t);if(r)return r;let i=document.createElement("span");return i.textContent=t,i.title=n,i.setAttribute("aria-label",n),i.className="cm-specialChar",i}ignoreEvent(){return!1}}class mo extends P{constructor(e){super(),this.width=e}eq(e){return e.width==this.width}toDOM(){let e=document.createElement("span");return e.textContent="\t",e.className="cm-tab",e.style.width=this.width+"px",e}ignoreEvent(){return!1}}const go=it.fromClass(class{constructor(){this.height=1e3,this.attrs={style:"padding-bottom: 1000px"}}update(e){let{view:t}=e,n=t.viewState.editorHeight-t.defaultLineHeight-t.documentPadding.top-.5;n>=0&&n!=this.height&&(this.height=n,this.attrs={style:`padding-bottom: ${n}px`})}});function vo(){return[go,st.of(e=>{var t;return(null===(t=e.plugin(go))||void 0===t?void 0:t.attrs)||null})]}function bo(){return wo}const yo=M.line({class:"cm-activeLine"}),wo=it.fromClass(class{constructor(e){this.decorations=this.getDeco(e)}update(e){(e.docChanged||e.selectionSet)&&(this.decorations=this.getDeco(e.view))}getDeco(e){let t=-1,n=[];for(let r of e.state.selection.ranges){let i=e.lineBlockAt(r.head);i.from>t&&(n.push(yo.range(i.from)),t=i.from)}return M.set(n)}},{decorations:e=>e.decorations});class Oo extends P{constructor(e){super(),this.content=e}toDOM(e){let t=document.createElement("span");return t.className="cm-placeholder",t.style.pointerEvents="none",t.appendChild("string"==typeof this.content?document.createTextNode(this.content):"function"==typeof this.content?this.content(e):this.content.cloneNode(!0)),t.setAttribute("aria-hidden","true"),t}coordsAt(e){let t=e.firstChild?q(e.firstChild):[];if(!t.length)return null;let n=window.getComputedStyle(e.parentNode),r=Y(t[0],"rtl"!=n.direction),i=parseInt(n.lineHeight);return r.bottom-r.top>1.5*i?{left:r.left,right:r.right,top:r.top,bottom:r.top+i}:r}ignoreEvent(){return!1}}function So(e){let t=it.fromClass(class{constructor(t){this.view=t,this.placeholder=e?M.set([M.widget({widget:new Oo(e),side:1}).range(0)]):M.none}get decorations(){return this.view.state.doc.length?M.none:this.placeholder}},{decorations:e=>e.decorations});return"string"==typeof e?[t,fi.contentAttributes.of({"aria-placeholder":e})]:t}const Eo=2e3;function xo(e,t,n){let i=Math.min(t.line,n.line),o=Math.max(t.line,n.line),a=[];if(t.off>Eo||n.off>Eo||t.col<0||n.col<0){let s=Math.min(t.off,n.off),l=Math.max(t.off,n.off);for(let t=i;t<=o;t++){let n=e.doc.line(t);n.length<=l&&a.push(r.EditorSelection.range(n.from+s,n.to+l))}}else{let s=Math.min(t.col,n.col),l=Math.max(t.col,n.col);for(let t=i;t<=o;t++){let n=e.doc.line(t),i=(0,r.findColumn)(n.text,s,e.tabSize,!0);if(i<0)a.push(r.EditorSelection.cursor(n.to));else{let t=(0,r.findColumn)(n.text,l,e.tabSize);a.push(r.EditorSelection.range(n.from+i,n.from+t))}}}return a}function _o(e,t){let n=e.coordsAtPos(e.viewport.from);return n?Math.round(Math.abs((n.left-t)/e.defaultCharacterWidth)):-1}function ko(e,t){let n=e.posAtCoords({x:t.clientX,y:t.clientY},!1),i=e.state.doc.lineAt(n),o=n-i.from,a=o>Eo?-1:o==i.length?_o(e,t.clientX):(0,r.countColumn)(i.text,e.state.tabSize,n-i.from);return{line:i.number,col:a,off:o}}function Co(e,t){let n=ko(e,t),i=e.state.selection;return n?{update(e){if(e.docChanged){let t=e.changes.mapPos(e.startState.doc.line(n.line).from),r=e.state.doc.lineAt(t);n={line:r.number,col:n.col,off:Math.min(n.off,r.length)},i=i.map(e.changes)}},get(t,o,a){let s=ko(e,t);if(!s)return i;let l=xo(e.state,n,s);return l.length?a?r.EditorSelection.create(l.concat(i.ranges)):r.EditorSelection.create(l):i}}:null}function Ao(e){let t=(null===e||void 0===e?void 0:e.eventFilter)||(e=>e.altKey&&0==e.button);return fi.mouseSelectionStyle.of((e,n)=>t(n)?Co(e,n):null)}const To={Alt:[18,e=>!!e.altKey],Control:[17,e=>!!e.ctrlKey],Shift:[16,e=>!!e.shiftKey],Meta:[91,e=>!!e.metaKey]},Ro={style:"cursor: crosshair"};function No(e={}){let[t,n]=To[e.key||"Alt"],r=it.fromClass(class{constructor(e){this.view=e,this.isDown=!1}set(e){this.isDown!=e&&(this.isDown=e,this.view.update([]))}},{eventObservers:{keydown(e){this.set(e.keyCode==t||n(e))},keyup(e){e.keyCode!=t&&n(e)||this.set(!1)},mousemove(e){this.set(n(e))}}});return[r,fi.contentAttributes.of(e=>{var t;return(null===(t=e.plugin(r))||void 0===t?void 0:t.isDown)?Ro:null})]}const Po="-10000px";class Io{constructor(e,t,n,r){this.facet=t,this.createTooltipView=n,this.removeTooltipView=r,this.input=e.state.facet(t),this.tooltips=this.input.filter(e=>e);let i=null;this.tooltipViews=this.tooltips.map(e=>i=n(e,i))}update(e,t){var n;let r=e.state.facet(this.facet),i=r.filter(e=>e);if(r===this.input){for(let t of this.tooltipViews)t.update&&t.update(e);return!1}let o=[],a=t?[]:null;for(let s=0;s<i.length;s++){let n=i[s],r=-1;if(n){for(let e=0;e<this.tooltips.length;e++){let t=this.tooltips[e];t&&t.create==n.create&&(r=e)}if(r<0)o[s]=this.createTooltipView(n,s?o[s-1]:null),a&&(a[s]=!!n.above);else{let n=o[s]=this.tooltipViews[r];a&&(a[s]=t[r]),n.update&&n.update(e)}}}for(let s of this.tooltipViews)o.indexOf(s)<0&&(this.removeTooltipView(s),null===(n=s.destroy)||void 0===n||n.call(s));return t&&(a.forEach((e,n)=>t[n]=e),t.length=a.length),this.input=r,this.tooltips=i,this.tooltipViews=o,!0}}function Mo(e={}){return Lo.of(e)}function Do(e){let t=e.dom.ownerDocument.documentElement;return{top:0,left:0,bottom:t.clientHeight,right:t.clientWidth}}const Lo=r.Facet.define({combine:e=>{var t,n,r;return{position:_.ios?"absolute":(null===(t=e.find(e=>e.position))||void 0===t?void 0:t.position)||"fixed",parent:(null===(n=e.find(e=>e.parent))||void 0===n?void 0:n.parent)||null,tooltipSpace:(null===(r=e.find(e=>e.tooltipSpace))||void 0===r?void 0:r.tooltipSpace)||Do}}}),Bo=new WeakMap,$o=it.fromClass(class{constructor(e){this.view=e,this.above=[],this.inView=!0,this.madeAbsolute=!1,this.lastTransaction=0,this.measureTimeout=-1;let t=e.state.facet(Lo);this.position=t.position,this.parent=t.parent,this.classes=e.themeClasses,this.createContainer(),this.measureReq={read:this.readMeasure.bind(this),write:this.writeMeasure.bind(this),key:this},this.resizeObserver="function"==typeof ResizeObserver?new ResizeObserver(()=>this.measureSoon()):null,this.manager=new Io(e,Uo,(e,t)=>this.createTooltip(e,t),e=>{this.resizeObserver&&this.resizeObserver.unobserve(e.dom),e.dom.remove()}),this.above=this.manager.tooltips.map(e=>!!e.above),this.intersectionObserver="function"==typeof IntersectionObserver?new IntersectionObserver(e=>{Date.now()>this.lastTransaction-50&&e.length>0&&e[e.length-1].intersectionRatio<1&&this.measureSoon()},{threshold:[1]}):null,this.observeIntersection(),e.win.addEventListener("resize",this.measureSoon=this.measureSoon.bind(this)),this.maybeMeasure()}createContainer(){this.parent?(this.container=document.createElement("div"),this.container.style.position="relative",this.container.className=this.view.themeClasses,this.parent.appendChild(this.container)):this.container=this.view.dom}observeIntersection(){if(this.intersectionObserver){this.intersectionObserver.disconnect();for(let e of this.manager.tooltipViews)this.intersectionObserver.observe(e.dom)}}measureSoon(){this.measureTimeout<0&&(this.measureTimeout=setTimeout(()=>{this.measureTimeout=-1,this.maybeMeasure()},50))}update(e){e.transactions.length&&(this.lastTransaction=Date.now());let t=this.manager.update(e,this.above);t&&this.observeIntersection();let n=t||e.geometryChanged,r=e.state.facet(Lo);if(r.position!=this.position&&!this.madeAbsolute){this.position=r.position;for(let e of this.manager.tooltipViews)e.dom.style.position=this.position;n=!0}if(r.parent!=this.parent){this.parent&&this.container.remove(),this.parent=r.parent,this.createContainer();for(let e of this.manager.tooltipViews)this.container.appendChild(e.dom);n=!0}else this.parent&&this.view.themeClasses!=this.classes&&(this.classes=this.container.className=this.view.themeClasses);n&&this.maybeMeasure()}createTooltip(e,t){let n=e.create(this.view),r=t?t.dom:null;if(n.dom.classList.add("cm-tooltip"),e.arrow&&!n.dom.querySelector(".cm-tooltip > .cm-tooltip-arrow")){let e=document.createElement("div");e.className="cm-tooltip-arrow",n.dom.appendChild(e)}return n.dom.style.position=this.position,n.dom.style.top=Po,n.dom.style.left="0px",this.container.insertBefore(n.dom,r),n.mount&&n.mount(this.view),this.resizeObserver&&this.resizeObserver.observe(n.dom),n}destroy(){var e,t,n;this.view.win.removeEventListener("resize",this.measureSoon);for(let r of this.manager.tooltipViews)r.dom.remove(),null===(e=r.destroy)||void 0===e||e.call(r);this.parent&&this.container.remove(),null===(t=this.resizeObserver)||void 0===t||t.disconnect(),null===(n=this.intersectionObserver)||void 0===n||n.disconnect(),clearTimeout(this.measureTimeout)}readMeasure(){let e=1,t=1,n=!1;if("fixed"==this.position&&this.manager.tooltipViews.length){let{dom:e}=this.manager.tooltipViews[0];if(_.safari){let t=e.getBoundingClientRect();n=Math.abs(t.top+1e4)>1||Math.abs(t.left)>1}else n=!!e.offsetParent&&e.offsetParent!=this.container.ownerDocument.body}if(n||"absolute"==this.position)if(this.parent){let n=this.parent.getBoundingClientRect();n.width&&n.height&&(e=n.width/this.parent.offsetWidth,t=n.height/this.parent.offsetHeight)}else({scaleX:e,scaleY:t}=this.view.viewState);let r=this.view.scrollDOM.getBoundingClientRect(),i=mt(this.view);return{visible:{left:r.left+i.left,top:r.top+i.top,right:r.right-i.right,bottom:r.bottom-i.bottom},parent:this.parent?this.container.getBoundingClientRect():this.view.dom.getBoundingClientRect(),pos:this.manager.tooltips.map((e,t)=>{let n=this.manager.tooltipViews[t];return n.getCoords?n.getCoords(e.pos):this.view.coordsAtPos(e.pos)}),size:this.manager.tooltipViews.map(({dom:e})=>e.getBoundingClientRect()),space:this.view.state.facet(Lo).tooltipSpace(this.view),scaleX:e,scaleY:t,makeAbsolute:n}}writeMeasure(e){var t;if(e.makeAbsolute){this.madeAbsolute=!0,this.position="absolute";for(let e of this.manager.tooltipViews)e.dom.style.position="absolute"}let{visible:n,space:r,scaleX:i,scaleY:o}=e,a=[];for(let s=0;s<this.manager.tooltips.length;s++){let l=this.manager.tooltips[s],c=this.manager.tooltipViews[s],{dom:u}=c,d=e.pos[s],h=e.size[s];if(!d||!1!==l.clip&&(d.bottom<=Math.max(n.top,r.top)||d.top>=Math.min(n.bottom,r.bottom)||d.right<Math.max(n.left,r.left)-.1||d.left>Math.min(n.right,r.right)+.1)){u.style.top=Po;continue}let p=l.arrow?c.dom.querySelector(".cm-tooltip-arrow"):null,f=p?7:0,m=h.right-h.left,g=null!==(t=Bo.get(c))&&void 0!==t?t:h.bottom-h.top,v=c.offset||jo,b=this.view.textDirection==ge.LTR,y=h.width>r.right-r.left?b?r.left:r.right-h.width:b?Math.max(r.left,Math.min(d.left-(p?14:0)+v.x,r.right-m)):Math.min(Math.max(r.left,d.left-m+(p?14:0)-v.x),r.right-m),w=this.above[s];!l.strictSide&&(w?d.top-g-f-v.y<r.top:d.bottom+g+f+v.y>r.bottom)&&w==r.bottom-d.bottom>d.top-r.top&&(w=this.above[s]=!w);let O=(w?d.top-r.top:r.bottom-d.bottom)-f;if(O<g&&!1!==c.resize){if(O<this.view.defaultLineHeight){u.style.top=Po;continue}Bo.set(c,g),u.style.height=(g=O)/o+"px"}else u.style.height&&(u.style.height="");let S=w?d.top-g-f-v.y:d.bottom+f+v.y,E=y+m;if(!0!==c.overlap)for(let e of a)e.left<E&&e.right>y&&e.top<S+g&&e.bottom>S&&(S=w?e.top-g-2-f:e.bottom+f+2);if("absolute"==this.position?(u.style.top=(S-e.parent.top)/o+"px",Vo(u,(y-e.parent.left)/i)):(u.style.top=S/o+"px",Vo(u,y/i)),p){let e=d.left+(b?v.x:-v.x)-(y+14-7);p.style.left=e/i+"px"}!0!==c.overlap&&a.push({left:y,top:S,right:E,bottom:S+g}),u.classList.toggle("cm-tooltip-above",w),u.classList.toggle("cm-tooltip-below",!w),c.positioned&&c.positioned(e.space)}}maybeMeasure(){if(this.manager.tooltips.length&&(this.view.inView&&this.view.requestMeasure(this.measureReq),this.inView!=this.view.inView&&(this.inView=this.view.inView,!this.inView)))for(let e of this.manager.tooltipViews)e.dom.style.top=Po}},{eventObservers:{scroll(){this.maybeMeasure()}}});function Vo(e,t){let n=parseInt(e.style.left,10);(isNaN(n)||Math.abs(t-n)>1)&&(e.style.left=t+"px")}const Fo=fi.baseTheme({".cm-tooltip":{zIndex:500,boxSizing:"border-box"},"&light .cm-tooltip":{border:"1px solid #bbb",backgroundColor:"#f5f5f5"},"&light .cm-tooltip-section:not(:first-child)":{borderTop:"1px solid #bbb"},"&dark .cm-tooltip":{backgroundColor:"#333338",color:"white"},".cm-tooltip-arrow":{height:"7px",width:"14px",position:"absolute",zIndex:-1,overflow:"hidden","&:before, &:after":{content:"''",position:"absolute",width:0,height:0,borderLeft:"7px solid transparent",borderRight:"7px solid transparent"},".cm-tooltip-above &":{bottom:"-7px","&:before":{borderTop:"7px solid #bbb"},"&:after":{borderTop:"7px solid #f5f5f5",bottom:"1px"}},".cm-tooltip-below &":{top:"-7px","&:before":{borderBottom:"7px solid #bbb"},"&:after":{borderBottom:"7px solid #f5f5f5",top:"1px"}}},"&dark .cm-tooltip .cm-tooltip-arrow":{"&:before":{borderTopColor:"#333338",borderBottomColor:"#333338"},"&:after":{borderTopColor:"transparent",borderBottomColor:"transparent"}}}),jo={x:0,y:0},Uo=r.Facet.define({enables:[$o,Fo]}),Go=r.Facet.define({combine:e=>e.reduce((e,t)=>e.concat(t),[])});class Ho{static create(e){return new Ho(e)}constructor(e){this.view=e,this.mounted=!1,this.dom=document.createElement("div"),this.dom.classList.add("cm-tooltip-hover"),this.manager=new Io(e,Go,(e,t)=>this.createHostedView(e,t),e=>e.dom.remove())}createHostedView(e,t){let n=e.create(this.view);return n.dom.classList.add("cm-tooltip-section"),this.dom.insertBefore(n.dom,t?t.dom.nextSibling:this.dom.firstChild),this.mounted&&n.mount&&n.mount(this.view),n}mount(e){for(let t of this.manager.tooltipViews)t.mount&&t.mount(e);this.mounted=!0}positioned(e){for(let t of this.manager.tooltipViews)t.positioned&&t.positioned(e)}update(e){this.manager.update(e)}destroy(){var e;for(let t of this.manager.tooltipViews)null===(e=t.destroy)||void 0===e||e.call(t)}passProp(e){let t;for(let n of this.manager.tooltipViews){let r=n[e];if(void 0!==r)if(void 0===t)t=r;else if(t!==r)return}return t}get offset(){return this.passProp("offset")}get getCoords(){return this.passProp("getCoords")}get overlap(){return this.passProp("overlap")}get resize(){return this.passProp("resize")}}const qo=Uo.compute([Go],e=>{let t=e.facet(Go);return 0===t.length?null:{pos:Math.min(...t.map(e=>e.pos)),end:Math.max(...t.map(e=>{var t;return null!==(t=e.end)&&void 0!==t?t:e.pos})),create:Ho.create,above:t[0].above,arrow:t.some(e=>e.arrow)}}),Qo=r.Facet.define();class zo{constructor(e,t,n,r,i,o){this.view=e,this.source=t,this.field=n,this.locked=r,this.setHover=i,this.hoverTime=o,this.hoverTimeout=-1,this.restartTimeout=-1,this.pending=null,this.lastMove={x:0,y:0,target:e.dom,time:0},this.checkHover=this.checkHover.bind(this),e.dom.addEventListener("mouseleave",this.mouseleave=this.mouseleave.bind(this)),e.dom.addEventListener("mousemove",this.mousemove=this.mousemove.bind(this))}update(e){this.pending&&(this.pending=null,clearTimeout(this.restartTimeout),this.restartTimeout=setTimeout(()=>this.startHover(),20))}get active(){return this.view.state.field(this.field)}checkHover(){if(this.hoverTimeout=-1,this.active.length)return;let e=Date.now()-this.lastMove.time;e<this.hoverTime?this.hoverTimeout=setTimeout(this.checkHover,this.hoverTime-e):this.startHover()}startHover(){clearTimeout(this.restartTimeout);let{view:e,lastMove:t}=this,n=e.docView.tile.nearest(t.target);if(!n)return;let r,i=1;if(n.isWidget())r=n.posAtStart;else{if(r=e.posAtCoords(t),null==r)return;let n=e.coordsAtPos(r);if(!n||t.y<n.top||t.y>n.bottom||t.x<n.left-e.defaultCharacterWidth||t.x>n.right+e.defaultCharacterWidth)return;let o=e.bidiSpans(e.state.doc.lineAt(r)).find(e=>e.from<=r&&e.to>=r),a=o&&o.dir==ge.RTL?-1:1;i=t.x<n.left?-a:a}this.activateHover(e,r,i)}activateHover(e,t,n,r){let i=this.source(e,t,n),o=t=>{if(t&&(!Array.isArray(t)||t.length)){let n=Array.isArray(t)?t:[t];r&&this.locked.set(n,r),e.dispatch({effects:this.setHover.of(n)})}};if(i&&"then"in i){let n=this.pending={pos:t};i.then(e=>{this.pending==n&&(this.pending=null,o(e))},t=>et(e.state,t,"hover tooltip"))}else o(i)}get tooltip(){let e=this.view.plugin($o),t=e?e.manager.tooltips.findIndex(e=>e.create==Ho.create):-1;return t>-1?e.manager.tooltipViews[t]:null}mousemove(e){var t,n;this.lastMove={x:e.clientX,y:e.clientY,target:e.target,time:Date.now()},this.hoverTimeout<0&&(this.hoverTimeout=setTimeout(this.checkHover,this.hoverTime));let{active:r,tooltip:i}=this;if(r.length&&!this.locked.has(r)&&i&&!Wo(i.dom,e)||this.pending){let{pos:i}=r[0]||this.pending,o=null!==(n=null===(t=r[0])||void 0===t?void 0:t.end)&&void 0!==n?n:i;(i==o?this.view.posAtCoords(this.lastMove)==i:Xo(this.view,i,o,e.clientX,e.clientY))||(this.view.dispatch({effects:this.setHover.of([])}),this.pending=null)}}mouseleave(e){clearTimeout(this.hoverTimeout),this.hoverTimeout=-1;let{active:t}=this;if(t.length&&!this.locked.has(t)){let{tooltip:t}=this,n=t&&t.dom.contains(e.relatedTarget);n?this.watchTooltipLeave(t.dom):this.view.dispatch({effects:this.setHover.of([])})}}watchTooltipLeave(e){let t=n=>{e.removeEventListener("mouseleave",t);let{active:r}=this;!r.length||this.locked.has(r)||this.view.dom.contains(n.relatedTarget)||this.view.dispatch({effects:this.setHover.of([])})};e.addEventListener("mouseleave",t)}destroy(){clearTimeout(this.hoverTimeout),clearTimeout(this.restartTimeout),this.view.dom.removeEventListener("mouseleave",this.mouseleave),this.view.dom.removeEventListener("mousemove",this.mousemove)}}const Ko=4;function Wo(e,t){let n,{left:r,right:i,top:o,bottom:a}=e.getBoundingClientRect();if(n=e.querySelector(".cm-tooltip-arrow")){let e=n.getBoundingClientRect();o=Math.min(e.top,o),a=Math.max(e.bottom,a)}return t.clientX>=r-Ko&&t.clientX<=i+Ko&&t.clientY>=o-Ko&&t.clientY<=a+Ko}function Xo(e,t,n,r,i,o){let a=e.scrollDOM.getBoundingClientRect(),s=e.documentTop+e.documentPadding.top+e.contentHeight;if(a.left>r||a.right<r||a.top>i||Math.min(a.bottom,s)<i)return!1;let l=e.posAtCoords({x:r,y:i},!1);return l>=t&&l<=n}function Yo(e,t={}){let n=r.StateEffect.define(),i=new WeakMap,o=r.StateField.define({create(){return[]},update(e,a){let s=i.get(e);if(e.length&&(t.hideOnChange&&(a.docChanged||a.selection)||s&&s(a)?e=[]:t.hideOn&&(e=e.filter(e=>!t.hideOn(a,e)))),a.docChanged&&e.length){let t=[];for(let n of e){let e=a.changes.mapPos(n.pos,-1,r.MapMode.TrackDel);if(null!=e){let r=Object.assign(Object.create(null),n);r.pos=e,null!=r.end&&(r.end=a.changes.mapPos(r.end)),t.push(r)}}e=t}for(let t of a.effects)t.is(n)&&(e=t.value,s=void 0),(t.is(ta)&&!t.value||t.value==o)&&(e=[]);return e.length&&s&&i.set(e,s),e},provide:e=>Go.from(e)});const a=it.define(r=>new zo(r,e,o,i,n,t.hoverTime||300));return{active:o,extension:[o,a,Qo.of(a),qo]}}function Zo(e,t,n,r={}){var i;let o=e.state.facet(Qo).map(t=>e.plugin(t)).filter(e=>!!e);if(r.tooltip&&r.tooltip.active){let e=o.find(e=>e.field==r.tooltip.active);e&&(o=[e])}for(let a of o)a.activateHover(e,t,n,null!==(i=r.until)&&void 0!==i?i:()=>!1)}function Jo(e,t){let n=e.plugin($o);if(!n)return null;let r=n.manager.tooltips.indexOf(t);return r<0?null:n.manager.tooltipViews[r]}function ea(e){return e.facet(Go).some(e=>e)}const ta=r.StateEffect.define(),na=ta.of(null);function ra(e){return ta.of(e.active)}function ia(e){let t=e.plugin($o);t&&t.maybeMeasure()}const oa=r.Facet.define({combine(e){let t,n;for(let r of e)t=t||r.topContainer,n=n||r.bottomContainer;return{topContainer:t,bottomContainer:n}}});function aa(e){return e?[oa.of(e)]:[]}function sa(e,t){let n=e.plugin(la),r=n?n.specs.indexOf(t):-1;return r>-1?n.panels[r]:null}const la=it.fromClass(class{constructor(e){this.input=e.state.facet(da),this.specs=this.input.filter(e=>e),this.panels=this.specs.map(t=>t(e));let t=e.state.facet(oa);this.top=new ca(e,!0,t.topContainer),this.bottom=new ca(e,!1,t.bottomContainer),this.top.sync(this.panels.filter(e=>e.top)),this.bottom.sync(this.panels.filter(e=>!e.top));for(let n of this.panels)n.dom.classList.add("cm-panel"),n.mount&&n.mount()}update(e){let t=e.state.facet(oa);this.top.container!=t.topContainer&&(this.top.sync([]),this.top=new ca(e.view,!0,t.topContainer)),this.bottom.container!=t.bottomContainer&&(this.bottom.sync([]),this.bottom=new ca(e.view,!1,t.bottomContainer)),this.top.syncClasses(),this.bottom.syncClasses();let n=e.state.facet(da);if(n!=this.input){let t=n.filter(e=>e),r=[],i=[],o=[],a=[];for(let n of t){let t,s=this.specs.indexOf(n);s<0?(t=n(e.view),a.push(t)):(t=this.panels[s],t.update&&t.update(e)),r.push(t),(t.top?i:o).push(t)}this.specs=t,this.panels=r,this.top.sync(i),this.bottom.sync(o);for(let e of a)e.dom.classList.add("cm-panel"),e.mount&&e.mount()}else for(let r of this.panels)r.update&&r.update(e)}destroy(){this.top.sync([]),this.bottom.sync([])}},{provide:e=>fi.scrollMargins.of(t=>{let n=t.plugin(e);return n&&{top:n.top.scrollMargin(),bottom:n.bottom.scrollMargin()}})});class ca{constructor(e,t,n){this.view=e,this.top=t,this.container=n,this.dom=void 0,this.classes="",this.panels=[],this.syncClasses()}sync(e){for(let t of this.panels)t.destroy&&e.indexOf(t)<0&&t.destroy();this.panels=e,this.syncDOM()}syncDOM(){if(0==this.panels.length)return void(this.dom&&(this.dom.remove(),this.dom=void 0));if(!this.dom){this.dom=document.createElement("div"),this.dom.className=this.top?"cm-panels cm-panels-top":"cm-panels cm-panels-bottom";let e=this.container||this.view.dom;e.insertBefore(this.dom,this.top?e.firstChild:null)}let e=this.dom.firstChild;for(let t of this.panels)if(t.dom.parentNode==this.dom){while(e!=t.dom)e=ua(e);e=e.nextSibling}else this.dom.insertBefore(t.dom,e);while(e)e=ua(e)}scrollMargin(){return!this.dom||this.container?0:Math.max(0,this.top?this.dom.getBoundingClientRect().bottom-Math.max(0,this.view.scrollDOM.getBoundingClientRect().top):Math.min(innerHeight,this.view.scrollDOM.getBoundingClientRect().bottom)-this.dom.getBoundingClientRect().top)}syncClasses(){if(this.container&&this.classes!=this.view.themeClasses){for(let e of this.classes.split(" "))e&&this.container.classList.remove(e);for(let e of(this.classes=this.view.themeClasses).split(" "))e&&this.container.classList.add(e)}}}function ua(e){let t=e.nextSibling;return e.remove(),t}const da=r.Facet.define({enables:la});function ha(e,t){let n,i=new Promise(e=>n=e),o=e=>va(e,t,n);e.state.field(fa,!1)?e.dispatch({effects:ma.of(o)}):e.dispatch({effects:r.StateEffect.appendConfig.of(fa.init(()=>[o]))});let a=ga.of(o);return{close:a,result:i.then(t=>{let n=e.win.queueMicrotask||(t=>e.win.setTimeout(t,10));return n(()=>{e.state.field(fa).indexOf(o)>-1&&e.dispatch({effects:a})}),t})}}function pa(e,t){let n=e.state.field(fa,!1)||[];for(let r of n){let n=sa(e,r);if(n&&n.dom.classList.contains(t))return n}return null}const fa=r.StateField.define({create(){return[]},update(e,t){for(let n of t.effects)n.is(ma)?e=[n.value].concat(e):n.is(ga)&&(e=e.filter(e=>e!=n.value));return e},provide:e=>da.computeN([e],t=>t.field(e))}),ma=r.StateEffect.define(),ga=r.StateEffect.define();function va(e,t,n){let r=t.content?t.content(e,()=>a(null)):null;if(!r){if(r=(0,h.A)("form"),t.input){let e=(0,h.A)("input",t.input);/^(text|password|number|email|tel|url)$/.test(e.type)&&e.classList.add("cm-textfield"),e.name||(e.name="input"),r.appendChild((0,h.A)("label",(t.label||"")+": ",e))}else r.appendChild(document.createTextNode(t.label||""));r.appendChild(document.createTextNode(" ")),r.appendChild((0,h.A)("button",{class:"cm-button",type:"submit"},t.submitLabel||"OK"))}let i="FORM"==r.nodeName?[r]:r.querySelectorAll("form");for(let s=0;s<i.length;s++){let e=i[s];e.addEventListener("keydown",t=>{27==t.keyCode?(t.preventDefault(),a(null)):13==t.keyCode&&(t.preventDefault(),a(e))}),e.addEventListener("submit",t=>{t.preventDefault(),a(e)})}let o=(0,h.A)("div",r,(0,h.A)("button",{onclick:()=>a(null),"aria-label":e.state.phrase("close"),class:"cm-dialog-close",type:"button"},["×"]));function a(t){o.contains(o.ownerDocument.activeElement)&&e.focus(),n(t)}return t.class&&(o.className=t.class),o.classList.add("cm-dialog"),{dom:o,top:t.top,mount:()=>{if(t.focus){let e;e="string"==typeof t.focus?r.querySelector(t.focus):r.querySelector("input")||r.querySelector("button"),e&&"select"in e?e.select():e&&"focus"in e&&e.focus()}}}}class ba extends r.RangeValue{compare(e){return this==e||this.constructor==e.constructor&&this.eq(e)}eq(e){return!1}destroy(e){}}ba.prototype.elementClass="",ba.prototype.toDOM=void 0,ba.prototype.mapMode=r.MapMode.TrackBefore,ba.prototype.startSide=ba.prototype.endSide=-1,ba.prototype.point=!0;const ya=r.Facet.define(),wa=r.Facet.define(),Oa={class:"",renderEmptyElements:!1,elementStyle:"",markers:()=>r.RangeSet.empty,lineMarker:()=>null,widgetMarker:()=>null,lineMarkerChange:null,initialSpacer:null,updateSpacer:null,domEventHandlers:{},side:"before"},Sa=r.Facet.define();function Ea(e){return[_a(),Sa.of({...Oa,...e})]}const xa=r.Facet.define({combine:e=>e.some(e=>e)});function _a(e){let t=[ka];return e&&!1===e.fixed&&t.push(xa.of(!0)),t}const ka=it.fromClass(class{constructor(e){this.view=e,this.domAfter=null,this.prevViewport=e.viewport,this.dom=document.createElement("div"),this.dom.className="cm-gutters cm-gutters-before",this.dom.setAttribute("aria-hidden","true"),this.dom.style.minHeight=this.view.contentHeight/this.view.scaleY+"px",this.gutters=e.state.facet(Sa).map(t=>new Ra(e,t)),this.fixed=!e.state.facet(xa);for(let t of this.gutters)"after"==t.config.side?this.getDOMAfter().appendChild(t.dom):this.dom.appendChild(t.dom);this.fixed&&(this.dom.style.position="sticky"),this.syncGutters(!1),e.scrollDOM.insertBefore(this.dom,e.contentDOM)}getDOMAfter(){return this.domAfter||(this.domAfter=document.createElement("div"),this.domAfter.className="cm-gutters cm-gutters-after",this.domAfter.setAttribute("aria-hidden","true"),this.domAfter.style.minHeight=this.view.contentHeight/this.view.scaleY+"px",this.domAfter.style.position=this.fixed?"sticky":"",this.view.scrollDOM.appendChild(this.domAfter)),this.domAfter}update(e){if(this.updateGutters(e)){let t=this.prevViewport,n=e.view.viewport,r=Math.min(t.to,n.to)-Math.max(t.from,n.from);this.syncGutters(r<.8*(n.to-n.from))}if(e.geometryChanged){let e=this.view.contentHeight/this.view.scaleY+"px";this.dom.style.minHeight=e,this.domAfter&&(this.domAfter.style.minHeight=e)}this.view.state.facet(xa)!=!this.fixed&&(this.fixed=!this.fixed,this.dom.style.position=this.fixed?"sticky":"",this.domAfter&&(this.domAfter.style.position=this.fixed?"sticky":"")),this.prevViewport=e.view.viewport}syncGutters(e){let t=this.dom.nextSibling;e&&(this.dom.remove(),this.domAfter&&this.domAfter.remove());let n=r.RangeSet.iter(this.view.state.facet(ya),this.view.viewport.from),i=[],o=this.gutters.map(e=>new Ta(e,this.view.viewport,-this.view.documentPadding.top));for(let r of this.view.viewportLineBlocks)if(i.length&&(i=[]),Array.isArray(r.type)){let e=!0;for(let t of r.type)if(t.type==I.Text&&e){Aa(n,i,t.from);for(let e of o)e.line(this.view,t,i);e=!1}else if(t.widget)for(let e of o)e.widget(this.view,t)}else if(r.type==I.Text){Aa(n,i,r.from);for(let e of o)e.line(this.view,r,i)}else if(r.widget)for(let e of o)e.widget(this.view,r);for(let r of o)r.finish();e&&(this.view.scrollDOM.insertBefore(this.dom,t),this.domAfter&&this.view.scrollDOM.appendChild(this.domAfter))}updateGutters(e){let t=e.startState.facet(Sa),n=e.state.facet(Sa),i=e.docChanged||e.heightChanged||e.viewportChanged||!r.RangeSet.eq(e.startState.facet(ya),e.state.facet(ya),e.view.viewport.from,e.view.viewport.to);if(t==n)for(let r of this.gutters)r.update(e)&&(i=!0);else{i=!0;let r=[];for(let i of n){let n=t.indexOf(i);n<0?r.push(new Ra(this.view,i)):(this.gutters[n].update(e),r.push(this.gutters[n]))}for(let e of this.gutters)e.dom.remove(),r.indexOf(e)<0&&e.destroy();for(let e of r)"after"==e.config.side?this.getDOMAfter().appendChild(e.dom):this.dom.appendChild(e.dom);this.gutters=r}return i}destroy(){for(let e of this.gutters)e.destroy();this.dom.remove(),this.domAfter&&this.domAfter.remove()}},{provide:e=>fi.scrollMargins.of(t=>{let n=t.plugin(e);if(!n||0==n.gutters.length||!n.fixed)return null;let r=n.dom.offsetWidth*t.scaleX,i=n.domAfter?n.domAfter.offsetWidth*t.scaleX:0;return t.textDirection==ge.LTR?{left:r,right:i}:{right:r,left:i}})});function Ca(e){return Array.isArray(e)?e:[e]}function Aa(e,t,n){while(e.value&&e.from<=n)e.from==n&&t.push(e.value),e.next()}class Ta{constructor(e,t,n){this.gutter=e,this.height=n,this.i=0,this.cursor=r.RangeSet.iter(e.markers,t.from)}addElement(e,t,n){let{gutter:r}=this,i=(t.top-this.height)/e.scaleY,o=t.height/e.scaleY;if(this.i==r.elements.length){let t=new Na(e,o,i,n);r.elements.push(t),r.dom.appendChild(t.dom)}else r.elements[this.i].update(e,o,i,n);this.height=t.bottom,this.i++}line(e,t,n){let r=[];Aa(this.cursor,r,t.from),n.length&&(r=r.concat(n));let i=this.gutter.config.lineMarker(e,t,r);i&&r.unshift(i);let o=this.gutter;(0!=r.length||o.config.renderEmptyElements)&&this.addElement(e,t,r)}widget(e,t){let n=this.gutter.config.widgetMarker(e,t.widget,t),r=n?[n]:null;for(let i of e.state.facet(wa)){let n=i(e,t.widget,t);n&&(r||(r=[])).push(n)}r&&this.addElement(e,t,r)}finish(){let e=this.gutter;while(e.elements.length>this.i){let t=e.elements.pop();e.dom.removeChild(t.dom),t.destroy()}}}class Ra{constructor(e,t){this.view=e,this.config=t,this.elements=[],this.spacer=null,this.dom=document.createElement("div"),this.dom.className="cm-gutter"+(this.config.class?" "+this.config.class:"");for(let n in t.domEventHandlers)this.dom.addEventListener(n,r=>{let i,o=r.target;if(o!=this.dom&&this.dom.contains(o)){while(o.parentNode!=this.dom)o=o.parentNode;let e=o.getBoundingClientRect();i=(e.top+e.bottom)/2}else i=r.clientY;let a=e.lineBlockAtHeight(i-e.documentTop);t.domEventHandlers[n](e,a,r)&&r.preventDefault()});this.markers=Ca(t.markers(e)),t.initialSpacer&&(this.spacer=new Na(e,0,0,[t.initialSpacer(e)]),this.dom.appendChild(this.spacer.dom),this.spacer.dom.style.cssText+="visibility: hidden; pointer-events: none")}update(e){let t=this.markers;if(this.markers=Ca(this.config.markers(e.view)),this.spacer&&this.config.updateSpacer){let t=this.config.updateSpacer(this.spacer.markers[0],e);t!=this.spacer.markers[0]&&this.spacer.update(e.view,0,0,[t])}let n=e.view.viewport;return!r.RangeSet.eq(this.markers,t,n.from,n.to)||!!this.config.lineMarkerChange&&this.config.lineMarkerChange(e)}destroy(){for(let e of this.elements)e.destroy()}}class Na{constructor(e,t,n,r){this.height=-1,this.above=0,this.markers=[],this.dom=document.createElement("div"),this.dom.className="cm-gutterElement",this.update(e,t,n,r)}update(e,t,n,r){this.height!=t&&(this.height=t,this.dom.style.height=t+"px"),this.above!=n&&(this.dom.style.marginTop=(this.above=n)?n+"px":""),Pa(this.markers,r)||this.setMarkers(e,r)}setMarkers(e,t){let n="cm-gutterElement",r=this.dom.firstChild;for(let i=0,o=0;;){let a=o,s=i<t.length?t[i++]:null,l=!1;if(s){let e=s.elementClass;e&&(n+=" "+e);for(let t=o;t<this.markers.length;t++)if(this.markers[t].compare(s)){a=t,l=!0;break}}else a=this.markers.length;while(o<a){let e=this.markers[o++];if(e.toDOM){e.destroy(r);let t=r.nextSibling;r.remove(),r=t}}if(!s)break;s.toDOM&&(l?r=r.nextSibling:this.dom.insertBefore(s.toDOM(e),r)),l&&o++}this.dom.className=n,this.markers=t}destroy(){this.setMarkers(null,[])}}function Pa(e,t){if(e.length!=t.length)return!1;for(let n=0;n<e.length;n++)if(!e[n].compare(t[n]))return!1;return!0}const Ia=r.Facet.define(),Ma=r.Facet.define(),Da=r.Facet.define({combine(e){return(0,r.combineConfig)(e,{formatNumber:String,domEventHandlers:{}},{domEventHandlers(e,t){let n=Object.assign({},e);for(let r in t){let e=n[r],i=t[r];n[r]=e?(t,n,r)=>e(t,n,r)||i(t,n,r):i}return n}})}});class La extends ba{constructor(e){super(),this.number=e}eq(e){return this.number==e.number}toDOM(){return document.createTextNode(this.number)}}function Ba(e,t){return e.state.facet(Da).formatNumber(t,e.state)}const $a=Sa.compute([Da],e=>({class:"cm-lineNumbers",renderEmptyElements:!1,markers(e){return e.state.facet(Ia)},lineMarker(e,t,n){return n.some(e=>e.toDOM)?null:new La(Ba(e,e.state.doc.lineAt(t.from).number))},widgetMarker:(e,t,n)=>{for(let r of e.state.facet(Ma)){let i=r(e,t,n);if(i)return i}return null},lineMarkerChange:e=>e.startState.facet(Da)!=e.state.facet(Da),initialSpacer(e){return new La(Ba(e,Fa(e.state.doc.lines)))},updateSpacer(e,t){let n=Ba(t.view,Fa(t.view.state.doc.lines));return n==e.number?e:new La(n)},domEventHandlers:e.facet(Da).domEventHandlers,side:"before"}));function Va(e={}){return[Da.of(e),_a(),$a]}function Fa(e){let t=9;while(t<e)t=10*t+9;return t}const ja=new class extends ba{constructor(){super(...arguments),this.elementClass="cm-activeLineGutter"}},Ua=ya.compute(["selection"],e=>{let t=[],n=-1;for(let r of e.selection.ranges){let i=e.doc.lineAt(r.head).from;i>n&&(n=i,t.push(ja.range(i)))}return r.RangeSet.of(t)});function Ga(){return Ua}function Ha(e){return it.define(t=>({decorations:e.createDeco(t),update(t){this.decorations=e.updateDeco(t,this.decorations)}}),{decorations:e=>e.decorations})}const qa=M.mark({class:"cm-highlightTab"}),Qa=M.mark({class:"cm-highlightSpace"}),za=Ha(new to({regexp:/\t| /g,decoration:e=>"\t"==e[0]?qa:Qa,boundary:/\S/}));function Ka(){return za}const Wa=Ha(new to({regexp:/\s+$/g,decoration:M.mark({class:"cm-trailingSpace"})}));function Xa(){return Wa}const Ya={HeightMap:kr,HeightOracle:Or,MeasuredHeights:Sr,QueryType:xr,ChangedRange:vt,computeOrder:Me,moveVisually:Be,clearHeightChangeFlag:wr,getHeightChangeFlag:()=>yr}},7485:function(e,t,n){"use strict";n.r(t),n.d(t,{Tag:function(){return o},classHighlighter:function(){return D},getStyleTags:function(){return b},highlightCode:function(){return g},highlightTree:function(){return m},styleTags:function(){return u},tagHighlighter:function(){return p},tags:function(){return M}});var r=n(43114);let i=0;class o{constructor(e,t,n,r){this.name=e,this.set=t,this.base=n,this.modified=r,this.id=i++}toString(){let{name:e}=this;for(let t of this.modified)t.name&&(e=`${t.name}(${e})`);return e}static define(e,t){let n="string"==typeof e?e:"?";if(e instanceof o&&(t=e),null===t||void 0===t?void 0:t.base)throw new Error("Can not derive from a modified tag");let r=new o(n,[],null,[]);if(r.set.push(r),t)for(let i of t.set)r.set.push(i);return r}static defineModifier(e){let t=new s(e);return e=>e.modified.indexOf(t)>-1?e:s.get(e.base||e,e.modified.concat(t).sort((e,t)=>e.id-t.id))}}let a=0;class s{constructor(e){this.name=e,this.instances=[],this.id=a++}static get(e,t){if(!t.length)return e;let n=t[0].instances.find(n=>n.base==e&&l(t,n.modified));if(n)return n;let r=[],i=new o(e.name,r,e,t);for(let o of t)o.instances.push(i);let a=c(t);for(let o of e.set)if(!o.modified.length)for(let e of a)r.push(s.get(o,e));return i}}function l(e,t){return e.length==t.length&&e.every((e,n)=>e==t[n])}function c(e){let t=[[]];for(let n=0;n<e.length;n++)for(let r=0,i=t.length;r<i;r++)t.push(t[r].concat(e[n]));return t.sort((e,t)=>t.length-e.length)}function u(e){let t=Object.create(null);for(let n in e){let r=e[n];Array.isArray(r)||(r=[r]);for(let e of n.split(" "))if(e){let n=[],i=2,o=e;for(let t=0;;){if("..."==o&&t>0&&t+3==e.length){i=1;break}let r=/^"(?:[^"\\]|\\.)*?"|[^\/!]+/.exec(o);if(!r)throw new RangeError("Invalid path: "+e);if(n.push("*"==r[0]?"":'"'==r[0][0]?JSON.parse(r[0]):r[0]),t+=r[0].length,t==e.length)break;let a=e[t++];if(t==e.length&&"!"==a){i=0;break}if("/"!=a)throw new RangeError("Invalid path: "+e);o=e.slice(t)}let a=n.length-1,s=n[a];if(!s)throw new RangeError("Invalid path: "+e);let l=new h(r,i,a>0?n.slice(0,a):null);t[s]=l.sort(t[s])}}return d.add(t)}const d=new r.NodeProp({combine(e,t){let n,r,i;while(e||t){if(!e||t&&e.depth<t.depth?(i=t,t=t.next):(i=e,e=e.next),n&&n.mode==i.mode&&!i.context&&!n.context)continue;let o=new h(i.tags,i.mode,i.context);n?n.next=o:r=o,n=o}return r}});class h{constructor(e,t,n,r){this.tags=e,this.mode=t,this.context=n,this.next=r}get opaque(){return 0==this.mode}get inherit(){return 1==this.mode}sort(e){return!e||e.depth<this.depth?(this.next=e,this):(e.next=this.sort(e.next),e)}get depth(){return this.context?this.context.length:0}}function p(e,t){let n=Object.create(null);for(let o of e)if(Array.isArray(o.tag))for(let e of o.tag)n[e.id]=o.class;else n[o.tag.id]=o.class;let{scope:r,all:i=null}=t||{};return{style:e=>{let t=i;for(let r of e)for(let e of r.set){let r=n[e.id];if(r){t=t?t+" "+r:r;break}}return t},scope:r}}function f(e,t){let n=null;for(let r of e){let e=r.style(t);e&&(n=n?n+" "+e:e)}return n}function m(e,t,n,r=0,i=e.length){let o=new v(r,Array.isArray(t)?t:[t],n);o.highlightRange(e.cursor(),r,i,"",o.highlighters),o.flush(i)}function g(e,t,n,r,i,o=0,a=e.length){let s=o;function l(t,n){if(!(t<=s)){for(let o=e.slice(s,t),a=0;;){let e=o.indexOf("\n",a),t=e<0?o.length:e;if(t>a&&r(o.slice(a,t),n),e<0)break;i(),a=e+1}s=t}}m(t,n,(e,t,n)=>{l(e,""),l(t,n)},o,a),l(a,"")}h.empty=new h([],2,null);class v{constructor(e,t,n){this.at=e,this.highlighters=t,this.span=n,this.class=""}startSpan(e,t){t!=this.class&&(this.flush(e),e>this.at&&(this.at=e),this.class=t)}flush(e){e>this.at&&this.class&&this.span(this.at,e,this.class)}highlightRange(e,t,n,i,o){let{type:a,from:s,to:l}=e;if(s>=n||l<=t)return;a.isTop&&(o=this.highlighters.filter(e=>!e.scope||e.scope(a)));let c=i,u=b(e)||h.empty,d=f(o,u.tags);if(d&&(c&&(c+=" "),c+=d,1==u.mode&&(i+=(i?" ":"")+d)),this.startSpan(Math.max(t,s),c),u.opaque)return;let p=e.tree&&e.tree.prop(r.NodeProp.mounted);if(p&&p.overlay){let r=e.node.enter(p.overlay[0].from+s,1),a=this.highlighters.filter(e=>!e.scope||e.scope(p.tree.type)),u=e.firstChild();for(let d=0,h=s;;d++){let f=d<p.overlay.length?p.overlay[d]:null,m=f?f.from+s:l,g=Math.max(t,h),v=Math.min(n,m);if(g<v&&u)while(e.from<v)if(this.highlightRange(e,g,v,i,o),this.startSpan(Math.min(v,e.to),c),e.to>=m||!e.nextSibling())break;if(!f||m>n)break;h=f.to+s,h>t&&(this.highlightRange(r.cursor(),Math.max(t,f.from+s),Math.min(n,h),"",a),this.startSpan(Math.min(n,h),c))}u&&e.parent()}else if(e.firstChild()){p&&(i="");do{if(!(e.to<=t)){if(e.from>=n)break;this.highlightRange(e,t,n,i,o),this.startSpan(Math.min(n,e.to),c)}}while(e.nextSibling());e.parent()}}}function b(e){let t=e.type.prop(d);while(t&&t.context&&!e.matchContext(t.context))t=t.next;return t||null}const y=o.define,w=y(),O=y(),S=y(O),E=y(O),x=y(),_=y(x),k=y(x),C=y(),A=y(C),T=y(),R=y(),N=y(),P=y(N),I=y(),M={comment:w,lineComment:y(w),blockComment:y(w),docComment:y(w),name:O,variableName:y(O),typeName:S,tagName:y(S),propertyName:E,attributeName:y(E),className:y(O),labelName:y(O),namespace:y(O),macroName:y(O),literal:x,string:_,docString:y(_),character:y(_),attributeValue:y(_),number:k,integer:y(k),float:y(k),bool:y(x),regexp:y(x),escape:y(x),color:y(x),url:y(x),keyword:T,self:y(T),null:y(T),atom:y(T),unit:y(T),modifier:y(T),operatorKeyword:y(T),controlKeyword:y(T),definitionKeyword:y(T),moduleKeyword:y(T),operator:R,derefOperator:y(R),arithmeticOperator:y(R),logicOperator:y(R),bitwiseOperator:y(R),compareOperator:y(R),updateOperator:y(R),definitionOperator:y(R),typeOperator:y(R),controlOperator:y(R),punctuation:N,separator:y(N),bracket:P,angleBracket:y(P),squareBracket:y(P),paren:y(P),brace:y(P),content:C,heading:A,heading1:y(A),heading2:y(A),heading3:y(A),heading4:y(A),heading5:y(A),heading6:y(A),contentSeparator:y(C),list:y(C),quote:y(C),emphasis:y(C),strong:y(C),link:y(C),monospace:y(C),strikethrough:y(C),inserted:y(),deleted:y(),changed:y(),invalid:y(),meta:I,documentMeta:y(I),annotation:y(I),processingInstruction:y(I),definition:o.defineModifier("definition"),constant:o.defineModifier("constant"),function:o.defineModifier("function"),standard:o.defineModifier("standard"),local:o.defineModifier("local"),special:o.defineModifier("special")};for(let L in M){let e=M[L];e instanceof o&&(e.name=L)}const D=p([{tag:M.link,class:"tok-link"},{tag:M.heading,class:"tok-heading"},{tag:M.emphasis,class:"tok-emphasis"},{tag:M.strong,class:"tok-strong"},{tag:M.keyword,class:"tok-keyword"},{tag:M.atom,class:"tok-atom"},{tag:M.bool,class:"tok-bool"},{tag:M.url,class:"tok-url"},{tag:M.labelName,class:"tok-labelName"},{tag:M.inserted,class:"tok-inserted"},{tag:M.deleted,class:"tok-deleted"},{tag:M.literal,class:"tok-literal"},{tag:M.string,class:"tok-string"},{tag:M.number,class:"tok-number"},{tag:[M.regexp,M.escape,M.special(M.string)],class:"tok-string2"},{tag:M.variableName,class:"tok-variableName"},{tag:M.local(M.variableName),class:"tok-variableName tok-local"},{tag:M.definition(M.variableName),class:"tok-variableName tok-definition"},{tag:M.special(M.variableName),class:"tok-variableName2"},{tag:M.definition(M.propertyName),class:"tok-propertyName tok-definition"},{tag:M.typeName,class:"tok-typeName"},{tag:M.namespace,class:"tok-namespace"},{tag:M.className,class:"tok-className"},{tag:M.macroName,class:"tok-macroName"},{tag:M.propertyName,class:"tok-propertyName"},{tag:M.operator,class:"tok-operator"},{tag:M.comment,class:"tok-comment"},{tag:M.meta,class:"tok-meta"},{tag:M.invalid,class:"tok-invalid"},{tag:M.punctuation,class:"tok-punctuation"}])},35348:function(e,t,n){"use strict";n.r(t),n.d(t,{CodeMirror:function(){return S},Vim:function(){return Q},getCM:function(){return re},vim:function(){return ne}});var r=n(4364);function i(e){var t=e.Pos;function n(e,t,n){if(t.line===n.line&&t.ch>=n.ch-1){var r=e.getLine(t.line),i=r.charCodeAt(t.ch);55296<=i&&i<=55551&&(n.ch+=1)}return{start:t,end:n}}var i=[{keys:"<Left>",type:"keyToKey",toKeys:"h"},{keys:"<Right>",type:"keyToKey",toKeys:"l"},{keys:"<Up>",type:"keyToKey",toKeys:"k"},{keys:"<Down>",type:"keyToKey",toKeys:"j"},{keys:"g<Up>",type:"keyToKey",toKeys:"gk"},{keys:"g<Down>",type:"keyToKey",toKeys:"gj"},{keys:"<Space>",type:"keyToKey",toKeys:"l"},{keys:"<BS>",type:"keyToKey",toKeys:"h"},{keys:"<Del>",type:"keyToKey",toKeys:"x"},{keys:"<C-Space>",type:"keyToKey",toKeys:"W"},{keys:"<C-BS>",type:"keyToKey",toKeys:"B"},{keys:"<S-Space>",type:"keyToKey",toKeys:"w"},{keys:"<S-BS>",type:"keyToKey",toKeys:"b"},{keys:"<C-n>",type:"keyToKey",toKeys:"j"},{keys:"<C-p>",type:"keyToKey",toKeys:"k"},{keys:"<C-[>",type:"keyToKey",toKeys:"<Esc>"},{keys:"<C-c>",type:"keyToKey",toKeys:"<Esc>"},{keys:"<C-[>",type:"keyToKey",toKeys:"<Esc>",context:"insert"},{keys:"<C-c>",type:"keyToKey",toKeys:"<Esc>",context:"insert"},{keys:"<C-Esc>",type:"keyToKey",toKeys:"<Esc>"},{keys:"<C-Esc>",type:"keyToKey",toKeys:"<Esc>",context:"insert"},{keys:"s",type:"keyToKey",toKeys:"cl",context:"normal"},{keys:"s",type:"keyToKey",toKeys:"c",context:"visual"},{keys:"S",type:"keyToKey",toKeys:"cc",context:"normal"},{keys:"S",type:"keyToKey",toKeys:"VdO",context:"visual"},{keys:"<Home>",type:"keyToKey",toKeys:"0"},{keys:"<End>",type:"keyToKey",toKeys:"$"},{keys:"<PageUp>",type:"keyToKey",toKeys:"<C-b>"},{keys:"<PageDown>",type:"keyToKey",toKeys:"<C-f>"},{keys:"<CR>",type:"keyToKey",toKeys:"j^",context:"normal"},{keys:"<Ins>",type:"keyToKey",toKeys:"i",context:"normal"},{keys:"<Ins>",type:"action",action:"toggleOverwrite",context:"insert"},{keys:"H",type:"motion",motion:"moveToTopLine",motionArgs:{linewise:!0,toJumplist:!0}},{keys:"M",type:"motion",motion:"moveToMiddleLine",motionArgs:{linewise:!0,toJumplist:!0}},{keys:"L",type:"motion",motion:"moveToBottomLine",motionArgs:{linewise:!0,toJumplist:!0}},{keys:"h",type:"motion",motion:"moveByCharacters",motionArgs:{forward:!1}},{keys:"l",type:"motion",motion:"moveByCharacters",motionArgs:{forward:!0}},{keys:"j",type:"motion",motion:"moveByLines",motionArgs:{forward:!0,linewise:!0}},{keys:"k",type:"motion",motion:"moveByLines",motionArgs:{forward:!1,linewise:!0}},{keys:"gj",type:"motion",motion:"moveByDisplayLines",motionArgs:{forward:!0}},{keys:"gk",type:"motion",motion:"moveByDisplayLines",motionArgs:{forward:!1}},{keys:"w",type:"motion",motion:"moveByWords",motionArgs:{forward:!0,wordEnd:!1}},{keys:"W",type:"motion",motion:"moveByWords",motionArgs:{forward:!0,wordEnd:!1,bigWord:!0}},{keys:"e",type:"motion",motion:"moveByWords",motionArgs:{forward:!0,wordEnd:!0,inclusive:!0}},{keys:"E",type:"motion",motion:"moveByWords",motionArgs:{forward:!0,wordEnd:!0,bigWord:!0,inclusive:!0}},{keys:"b",type:"motion",motion:"moveByWords",motionArgs:{forward:!1,wordEnd:!1}},{keys:"B",type:"motion",motion:"moveByWords",motionArgs:{forward:!1,wordEnd:!1,bigWord:!0}},{keys:"ge",type:"motion",motion:"moveByWords",motionArgs:{forward:!1,wordEnd:!0,inclusive:!0}},{keys:"gE",type:"motion",motion:"moveByWords",motionArgs:{forward:!1,wordEnd:!0,bigWord:!0,inclusive:!0}},{keys:"{",type:"motion",motion:"moveByParagraph",motionArgs:{forward:!1,toJumplist:!0}},{keys:"}",type:"motion",motion:"moveByParagraph",motionArgs:{forward:!0,toJumplist:!0}},{keys:"(",type:"motion",motion:"moveBySentence",motionArgs:{forward:!1}},{keys:")",type:"motion",motion:"moveBySentence",motionArgs:{forward:!0}},{keys:"<C-f>",type:"motion",motion:"moveByPage",motionArgs:{forward:!0}},{keys:"<C-b>",type:"motion",motion:"moveByPage",motionArgs:{forward:!1}},{keys:"<C-d>",type:"motion",motion:"moveByScroll",motionArgs:{forward:!0,explicitRepeat:!0}},{keys:"<C-u>",type:"motion",motion:"moveByScroll",motionArgs:{forward:!1,explicitRepeat:!0}},{keys:"gg",type:"motion",motion:"moveToLineOrEdgeOfDocument",motionArgs:{forward:!1,explicitRepeat:!0,linewise:!0,toJumplist:!0}},{keys:"G",type:"motion",motion:"moveToLineOrEdgeOfDocument",motionArgs:{forward:!0,explicitRepeat:!0,linewise:!0,toJumplist:!0}},{keys:"g$",type:"motion",motion:"moveToEndOfDisplayLine"},{keys:"g^",type:"motion",motion:"moveToStartOfDisplayLine"},{keys:"g0",type:"motion",motion:"moveToStartOfDisplayLine"},{keys:"0",type:"motion",motion:"moveToStartOfLine"},{keys:"^",type:"motion",motion:"moveToFirstNonWhiteSpaceCharacter"},{keys:"+",type:"motion",motion:"moveByLines",motionArgs:{forward:!0,toFirstChar:!0}},{keys:"-",type:"motion",motion:"moveByLines",motionArgs:{forward:!1,toFirstChar:!0}},{keys:"_",type:"motion",motion:"moveByLines",motionArgs:{forward:!0,toFirstChar:!0,repeatOffset:-1}},{keys:"$",type:"motion",motion:"moveToEol",motionArgs:{inclusive:!0}},{keys:"%",type:"motion",motion:"moveToMatchedSymbol",motionArgs:{inclusive:!0,toJumplist:!0}},{keys:"f<character>",type:"motion",motion:"moveToCharacter",motionArgs:{forward:!0,inclusive:!0}},{keys:"F<character>",type:"motion",motion:"moveToCharacter",motionArgs:{forward:!1}},{keys:"t<character>",type:"motion",motion:"moveTillCharacter",motionArgs:{forward:!0,inclusive:!0}},{keys:"T<character>",type:"motion",motion:"moveTillCharacter",motionArgs:{forward:!1}},{keys:";",type:"motion",motion:"repeatLastCharacterSearch",motionArgs:{forward:!0}},{keys:",",type:"motion",motion:"repeatLastCharacterSearch",motionArgs:{forward:!1}},{keys:"'<register>",type:"motion",motion:"goToMark",motionArgs:{toJumplist:!0,linewise:!0}},{keys:"`<register>",type:"motion",motion:"goToMark",motionArgs:{toJumplist:!0}},{keys:"]`",type:"motion",motion:"jumpToMark",motionArgs:{forward:!0}},{keys:"[`",type:"motion",motion:"jumpToMark",motionArgs:{forward:!1}},{keys:"]'",type:"motion",motion:"jumpToMark",motionArgs:{forward:!0,linewise:!0}},{keys:"['",type:"motion",motion:"jumpToMark",motionArgs:{forward:!1,linewise:!0}},{keys:"]p",type:"action",action:"paste",isEdit:!0,actionArgs:{after:!0,isEdit:!0,matchIndent:!0}},{keys:"[p",type:"action",action:"paste",isEdit:!0,actionArgs:{after:!1,isEdit:!0,matchIndent:!0}},{keys:"]<character>",type:"motion",motion:"moveToSymbol",motionArgs:{forward:!0,toJumplist:!0}},{keys:"[<character>",type:"motion",motion:"moveToSymbol",motionArgs:{forward:!1,toJumplist:!0}},{keys:"|",type:"motion",motion:"moveToColumn"},{keys:"o",type:"motion",motion:"moveToOtherHighlightedEnd",context:"visual"},{keys:"O",type:"motion",motion:"moveToOtherHighlightedEnd",motionArgs:{sameLine:!0},context:"visual"},{keys:"d",type:"operator",operator:"delete"},{keys:"y",type:"operator",operator:"yank"},{keys:"c",type:"operator",operator:"change"},{keys:"=",type:"operator",operator:"indentAuto"},{keys:">",type:"operator",operator:"indent",operatorArgs:{indentRight:!0}},{keys:"<",type:"operator",operator:"indent",operatorArgs:{indentRight:!1}},{keys:"g~",type:"operator",operator:"changeCase"},{keys:"gu",type:"operator",operator:"changeCase",operatorArgs:{toLower:!0},isEdit:!0},{keys:"gU",type:"operator",operator:"changeCase",operatorArgs:{toLower:!1},isEdit:!0},{keys:"gc",type:"operator",operator:"toggleComment",isEdit:!0},{keys:"n",type:"motion",motion:"findNext",motionArgs:{forward:!0,toJumplist:!0}},{keys:"N",type:"motion",motion:"findNext",motionArgs:{forward:!1,toJumplist:!0}},{keys:"gn",type:"motion",motion:"findAndSelectNextInclusive",motionArgs:{forward:!0}},{keys:"gN",type:"motion",motion:"findAndSelectNextInclusive",motionArgs:{forward:!1}},{keys:"gq",type:"operator",operator:"hardWrap"},{keys:"gw",type:"operator",operator:"hardWrap",operatorArgs:{keepCursor:!0}},{keys:"g?",type:"operator",operator:"rot13"},{keys:"x",type:"operatorMotion",operator:"delete",motion:"moveByCharacters",motionArgs:{forward:!0},operatorMotionArgs:{visualLine:!1}},{keys:"X",type:"operatorMotion",operator:"delete",motion:"moveByCharacters",motionArgs:{forward:!1},operatorMotionArgs:{visualLine:!0}},{keys:"D",type:"operatorMotion",operator:"delete",motion:"moveToEol",motionArgs:{inclusive:!0},context:"normal"},{keys:"D",type:"operator",operator:"delete",operatorArgs:{linewise:!0},context:"visual"},{keys:"Y",type:"operatorMotion",operator:"yank",motion:"expandToLine",motionArgs:{linewise:!0},context:"normal"},{keys:"Y",type:"operator",operator:"yank",operatorArgs:{linewise:!0},context:"visual"},{keys:"C",type:"operatorMotion",operator:"change",motion:"moveToEol",motionArgs:{inclusive:!0},context:"normal"},{keys:"C",type:"operator",operator:"change",operatorArgs:{linewise:!0},context:"visual"},{keys:"~",type:"operatorMotion",operator:"changeCase",motion:"moveByCharacters",motionArgs:{forward:!0},operatorArgs:{shouldMoveCursor:!0},context:"normal"},{keys:"~",type:"operator",operator:"changeCase",context:"visual"},{keys:"<C-u>",type:"operatorMotion",operator:"delete",motion:"moveToStartOfLine",context:"insert"},{keys:"<C-w>",type:"operatorMotion",operator:"delete",motion:"moveByWords",motionArgs:{forward:!1,wordEnd:!1},context:"insert"},{keys:"<C-w>",type:"idle",context:"normal"},{keys:"<C-i>",type:"action",action:"jumpListWalk",actionArgs:{forward:!0}},{keys:"<C-o>",type:"action",action:"jumpListWalk",actionArgs:{forward:!1}},{keys:"<C-e>",type:"action",action:"scroll",actionArgs:{forward:!0,linewise:!0}},{keys:"<C-y>",type:"action",action:"scroll",actionArgs:{forward:!1,linewise:!0}},{keys:"a",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"charAfter"},context:"normal"},{keys:"A",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"eol"},context:"normal"},{keys:"A",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"endOfSelectedArea"},context:"visual"},{keys:"i",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"inplace"},context:"normal"},{keys:"gi",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"lastEdit"},context:"normal"},{keys:"I",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"firstNonBlank"},context:"normal"},{keys:"gI",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"bol"},context:"normal"},{keys:"I",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{insertAt:"startOfSelectedArea"},context:"visual"},{keys:"o",type:"action",action:"newLineAndEnterInsertMode",isEdit:!0,interlaceInsertRepeat:!0,actionArgs:{after:!0},context:"normal"},{keys:"O",type:"action",action:"newLineAndEnterInsertMode",isEdit:!0,interlaceInsertRepeat:!0,actionArgs:{after:!1},context:"normal"},{keys:"v",type:"action",action:"toggleVisualMode"},{keys:"V",type:"action",action:"toggleVisualMode",actionArgs:{linewise:!0}},{keys:"<C-v>",type:"action",action:"toggleVisualMode",actionArgs:{blockwise:!0}},{keys:"<C-q>",type:"action",action:"toggleVisualMode",actionArgs:{blockwise:!0}},{keys:"gv",type:"action",action:"reselectLastSelection"},{keys:"J",type:"action",action:"joinLines",isEdit:!0},{keys:"gJ",type:"action",action:"joinLines",actionArgs:{keepSpaces:!0},isEdit:!0},{keys:"p",type:"action",action:"paste",isEdit:!0,actionArgs:{after:!0,isEdit:!0}},{keys:"P",type:"action",action:"paste",isEdit:!0,actionArgs:{after:!1,isEdit:!0}},{keys:"r<character>",type:"action",action:"replace",isEdit:!0},{keys:"@<register>",type:"action",action:"replayMacro"},{keys:"q<register>",type:"action",action:"enterMacroRecordMode"},{keys:"R",type:"action",action:"enterInsertMode",isEdit:!0,actionArgs:{replace:!0},context:"normal"},{keys:"R",type:"operator",operator:"change",operatorArgs:{linewise:!0,fullLine:!0},context:"visual",exitVisualBlock:!0},{keys:"u",type:"action",action:"undo",context:"normal"},{keys:"u",type:"operator",operator:"changeCase",operatorArgs:{toLower:!0},context:"visual",isEdit:!0},{keys:"U",type:"operator",operator:"changeCase",operatorArgs:{toLower:!1},context:"visual",isEdit:!0},{keys:"<C-r>",type:"action",action:"redo"},{keys:"m<register>",type:"action",action:"setMark"},{keys:'"<register>',type:"action",action:"setRegister"},{keys:"<C-r><register>",type:"action",action:"insertRegister",context:"insert",isEdit:!0},{keys:"<C-o>",type:"action",action:"oneNormalCommand",context:"insert"},{keys:"zz",type:"action",action:"scrollToCursor",actionArgs:{position:"center"}},{keys:"z.",type:"action",action:"scrollToCursor",actionArgs:{position:"center"},motion:"moveToFirstNonWhiteSpaceCharacter"},{keys:"zt",type:"action",action:"scrollToCursor",actionArgs:{position:"top"}},{keys:"z<CR>",type:"action",action:"scrollToCursor",actionArgs:{position:"top"},motion:"moveToFirstNonWhiteSpaceCharacter"},{keys:"zb",type:"action",action:"scrollToCursor",actionArgs:{position:"bottom"}},{keys:"z-",type:"action",action:"scrollToCursor",actionArgs:{position:"bottom"},motion:"moveToFirstNonWhiteSpaceCharacter"},{keys:".",type:"action",action:"repeatLastEdit"},{keys:"<C-a>",type:"action",action:"incrementNumberToken",isEdit:!0,actionArgs:{increase:!0,backtrack:!1}},{keys:"<C-x>",type:"action",action:"incrementNumberToken",isEdit:!0,actionArgs:{increase:!1,backtrack:!1}},{keys:"<C-t>",type:"action",action:"indent",actionArgs:{indentRight:!0},context:"insert"},{keys:"<C-d>",type:"action",action:"indent",actionArgs:{indentRight:!1},context:"insert"},{keys:"a<register>",type:"motion",motion:"textObjectManipulation"},{keys:"i<register>",type:"motion",motion:"textObjectManipulation",motionArgs:{textObjectInner:!0}},{keys:"/",type:"search",searchArgs:{forward:!0,querySrc:"prompt",toJumplist:!0}},{keys:"?",type:"search",searchArgs:{forward:!1,querySrc:"prompt",toJumplist:!0}},{keys:"*",type:"search",searchArgs:{forward:!0,querySrc:"wordUnderCursor",wholeWordOnly:!0,toJumplist:!0}},{keys:"#",type:"search",searchArgs:{forward:!1,querySrc:"wordUnderCursor",wholeWordOnly:!0,toJumplist:!0}},{keys:"g*",type:"search",searchArgs:{forward:!0,querySrc:"wordUnderCursor",toJumplist:!0}},{keys:"g#",type:"search",searchArgs:{forward:!1,querySrc:"wordUnderCursor",toJumplist:!0}},{keys:":",type:"ex"}],o=Object.create(null),a=i.length,s=[{name:"colorscheme",shortName:"colo"},{name:"map"},{name:"imap",shortName:"im"},{name:"nmap",shortName:"nm"},{name:"vmap",shortName:"vm"},{name:"omap",shortName:"om"},{name:"noremap",shortName:"no"},{name:"nnoremap",shortName:"nn"},{name:"vnoremap",shortName:"vn"},{name:"inoremap",shortName:"ino"},{name:"onoremap",shortName:"ono"},{name:"unmap"},{name:"mapclear",shortName:"mapc"},{name:"nmapclear",shortName:"nmapc"},{name:"vmapclear",shortName:"vmapc"},{name:"imapclear",shortName:"imapc"},{name:"omapclear",shortName:"omapc"},{name:"write",shortName:"w"},{name:"undo",shortName:"u"},{name:"redo",shortName:"red"},{name:"set",shortName:"se"},{name:"setlocal",shortName:"setl"},{name:"setglobal",shortName:"setg"},{name:"sort",shortName:"sor"},{name:"substitute",shortName:"s",possiblyAsync:!0},{name:"startinsert",shortName:"start"},{name:"nohlsearch",shortName:"noh"},{name:"yank",shortName:"y"},{name:"put",shortName:"pu"},{name:"delmarks",shortName:"delm"},{name:"marks",excludeFromCommandHistory:!0},{name:"registers",shortName:"reg",excludeFromCommandHistory:!0},{name:"vglobal",shortName:"v"},{name:"delete",shortName:"d"},{name:"join",shortName:"j"},{name:"normal",shortName:"norm"},{name:"global",shortName:"g"}],l=X("");function c(t){t.setOption("disableInput",!0),t.setOption("showCursorWhenSelecting",!1),e.signal(t,"vim-mode-change",{mode:"normal"}),t.on("cursorActivity",Wt),L(t),e.on(t.getInputField(),"paste",d(t))}function u(t){t.setOption("disableInput",!1),t.off("cursorActivity",Wt),e.off(t.getInputField(),"paste",d(t)),t.state.vim=null,kt&&clearTimeout(kt)}function d(e){var t=e.state.vim;return t.onPasteFn||(t.onPasteFn=function(){t.insertMode||(e.setCursor(fe(e.getCursor(),0,1)),ue.enterInsertMode(e,{},t))}),t.onPasteFn}var h=/[\d]/,p=[e.isWordChar,function(t){return t&&!e.isWordChar(t)&&!/\s/.test(t)}],f=[function(e){return/\S/.test(e)}],m=["<",">"],g=["-",'"',".",":","_","/","+"],v=/^\w$/,b=/^[A-Z]$/;try{b=new RegExp("^[\\p{Lu}]$","u")}catch(rn){}function y(e,t){return t>=e.firstLine()&&t<=e.lastLine()}function w(e){return/^[a-z]$/.test(e)}function O(e){return-1!="()[]{}".indexOf(e)}function S(e){return h.test(e)}function E(e){return b.test(e)}function x(e){return/^\s*$/.test(e)}function _(e){return-1!=".?!".indexOf(e)}function k(e,t){for(var n=0;n<t.length;n++)if(t[n]==e)return!0;return!1}var C={};function A(e,t,n,r,i){if(void 0===t&&!i)throw Error("defaultValue is required unless callback is provided");if(n||(n="string"),C[e]={type:n,defaultValue:t,callback:i},r)for(var o=0;o<r.length;o++)C[r[o]]=C[e];t&&T(e,t)}function T(e,t,n,r){var i=C[e];r=r||{};var o=r.scope;if(!i)return new Error("Unknown option: "+e);if("boolean"==i.type){if(t&&!0!==t)return new Error("Invalid argument: "+e+"="+t);!1!==t&&(t=!0)}i.callback?("local"!==o&&i.callback(t,void 0),"global"!==o&&n&&i.callback(t,n)):("local"!==o&&(i.value="boolean"==i.type?!!t:t),"global"!==o&&n&&(n.state.vim.options[e]={value:t}))}function R(e,t,n){var r=C[e];n=n||{};var i=n.scope;if(!r)return new Error("Unknown option: "+e);if(r.callback){let e=t&&r.callback(void 0,t);return"global"!==i&&void 0!==e?e:"local"!==i?r.callback():void 0}{let n="global"!==i&&t&&t.state.vim.options[e];return(n||"local"!==i&&r||{}).value}}A("filetype",void 0,"string",["ft"],function(e,t){if(void 0!==t){if(void 0===e){let e=t.getOption("mode");return"null"==e?"":e}{let n=""==e?"null":e;t.setOption("mode",n)}}}),A("textwidth",80,"number",["tw"],function(e,t){if(void 0!==t){if(void 0===e){var n=t.getOption("textwidth");return n}var r=Math.round(e);r>1&&t.setOption("textwidth",r)}});var N,P,I=function(){var e=100,t=-1,n=0,r=0,i=new Array(e);function o(o,a,s){var l=t%e,c=i[l];function u(n){var r=++t%e,a=i[r];a&&a.clear(),i[r]=o.setBookmark(n)}if(c){var d=c.find();d&&!we(d,a)&&u(a)}else u(a);u(s),n=t,r=t-e+1,r<0&&(r=0)}function a(o,a){t+=a,t>n?t=n:t<r&&(t=r);var s=i[(e+t)%e];if(s&&!s.find()){var l,c=a>0?1:-1,u=o.getCursor();do{if(t+=c,s=i[(e+t)%e],s&&(l=s.find())&&!we(u,l))break}while(t<n&&t>r)}return s}function s(e,n){var r=t,i=a(e,n);return t=r,i&&i.find()}return{cachedCursor:void 0,add:o,find:s,move:a}},M=function(e){return e?{changes:e.changes,expectCursorActivityForChange:e.expectCursorActivityForChange}:{changes:[],expectCursorActivityForChange:!1}};class D{constructor(){this.latestRegister=void 0,this.isPlaying=!1,this.isRecording=!1,this.replaySearchQueries=[],this.onRecordingDone=void 0,this.lastInsertModeChanges=M()}exitMacroRecordMode(){var e=N.macroModeState;e.onRecordingDone&&e.onRecordingDone(),e.onRecordingDone=void 0,e.isRecording=!1}enterMacroRecordMode(e,t){var n=N.registerController.getRegister(t);if(n){if(n.clear(),this.latestRegister=t,e.openDialog){var r=yt("span",{class:"cm-vim-message"},"recording @"+t);this.onRecordingDone=e.openDialog(r,function(){},{bottom:!0})}this.isRecording=!0}}}function L(e){return e.state.vim||(e.state.vim={inputState:new Y,lastEditInputState:void 0,lastEditActionCommand:void 0,lastHPos:-1,lastHSPos:-1,lastMotion:null,marks:{},insertMode:!1,insertModeReturn:!1,insertModeRepeat:void 0,visualMode:!1,visualLine:!1,visualBlock:!1,lastSelection:null,lastPastedText:void 0,sel:{anchor:new t(0,0),head:new t(0,0)},options:{},expectLiteralNext:!1,status:""}),e.state.vim}function B(){for(var e in N={searchQuery:null,searchIsReversed:!1,lastSubstituteReplacePart:void 0,jumpList:I(),macroModeState:new D,lastCharacterSearch:{increment:0,forward:!0,selectedCharacter:""},registerController:new ne({}),searchHistoryController:new re,exCommandHistoryController:new re},C){var t=C[e];t.value=t.defaultValue}}class ${constructor(e,t){this.keyName=e,this.key=t.key,this.ctrlKey=t.ctrlKey,this.altKey=t.altKey,this.metaKey=t.metaKey,this.shiftKey=t.shiftKey}}var V,F={enterVimMode:c,leaveVimMode:u,buildKeyMap:function(){},getRegisterController:function(){return N.registerController},resetVimGlobalState_:B,getVimGlobalState_:function(){return N},maybeInitVimState_:L,suppressErrorLogging:!1,InsertModeKey:$,map:function(e,t,n){Bt.map(e,t,n)},unmap:function(e,t){return Bt.unmap(e,t)},noremap:function(e,t,n){Bt.map(e,t,n,!0)},mapclear:function(e){var t=i.length,n=a,r=i.slice(0,t-n);if(i=i.slice(t-n),e)for(var o=r.length-1;o>=0;o--){var s=r[o];if(e!==s.context)if(s.context)this._mapCommand(s);else{var l=["normal","insert","visual"];for(var c in l)if(l[c]!==e){var u=Object.assign({},s);u.context=l[c],this._mapCommand(u)}}}},langmap:W,vimKeyFromEvent:K,setOption:T,getOption:R,defineOption:A,defineEx:function(e,t,n){if(t){if(0!==e.indexOf(t))throw new Error('(Vim.defineEx) "'+t+'" is not a prefix of "'+e+'", command not registered')}else t=e;Lt[e]=n,Bt.commandMap_[t]={name:e,shortName:t,type:"api"}},handleKey:function(e,t,n){var r=this.findKey(e,t,n);if("function"===typeof r)return r()},multiSelectHandleKey:nn,findKey:function(t,n,o){var a=L(t),s=t;function l(){var e=N.macroModeState;if(e.isRecording){if("q"==n)return e.exitMacroRecordMode(),Z(s),!0;"mapping"!=o&&qt(e,n)}}function c(){if("<Esc>"==n){if(a.visualMode)$e(s);else{if(!a.insertMode)return;Vt(s)}return Z(s),!0}}function u(){if(c())return!0;a.inputState.keyBuffer.push(n);var e=a.inputState.keyBuffer.join(""),t=1==n.length,r=ie.matchCommand(e,i,a.inputState,"insert"),o=a.inputState.changeQueue;if("none"==r.type)return Z(s),!1;if("partial"==r.type){if(r.expectLiteralNext&&(a.expectLiteralNext=!0),P&&window.clearTimeout(P),P=t&&window.setTimeout(function(){a.insertMode&&a.inputState.keyBuffer.length&&Z(s)},R("insertModeEscKeysTimeout")),t){var l=s.listSelections();o&&o.removed.length==l.length||(o=a.inputState.changeQueue=new J),o.inserted+=n;for(var u=0;u<l.length;u++){var d=Se(l[u].anchor,l[u].head),h=Ee(l[u].anchor,l[u].head),p=s.getRange(d,s.state.overwrite?fe(h,0,1):h);o.removed[u]=(o.removed[u]||"")+p}}return!t}if("full"==r.type&&(a.inputState.keyBuffer.length=0),a.expectLiteralNext=!1,P&&window.clearTimeout(P),r.command&&o){for(l=s.listSelections(),u=0;u<l.length;u++){var f=l[u].head;s.replaceRange(o.removed[u]||"",fe(f,0,-o.inserted.length),f,"+input")}N.macroModeState.lastInsertModeChanges.changes.pop()}return r.command||Z(s),r.command}function d(){if(l()||c())return!0;a.inputState.keyBuffer.push(n);var e=a.inputState.keyBuffer.join("");if(/^[1-9]\d*$/.test(e))return!0;var t=/^(\d*)(.*)$/.exec(e);if(!t)return Z(s),!1;var r=a.visualMode?"visual":"normal",o=t[2]||t[1];a.inputState.operatorShortcut&&a.inputState.operatorShortcut.slice(-1)==o&&(o=a.inputState.operatorShortcut);var u=ie.matchCommand(o,i,a.inputState,r);return"none"==u.type?(Z(s),!1):"partial"==u.type?(u.expectLiteralNext&&(a.expectLiteralNext=!0),!0):"clear"==u.type?(Z(s),!0):(a.expectLiteralNext=!1,a.inputState.keyBuffer.length=0,t=/^(\d*)(.*)$/.exec(e),t&&t[1]&&"0"!=t[1]&&a.inputState.pushRepeatDigit(t[1]),u.command)}var h=a.insertMode?u():d();return!1===h?!a.insertMode&&(1===n.length||e.isMac&&/<A-.>/.test(n))?function(){return!0}:void 0:!0===h?function(){return!0}:h?function(){return s.operation(function(){s.curOp.isVimOp=!0;try{if("object"!=typeof h)return;"keyToKey"==h.type?H(s,h.toKeys,h):ie.processCommand(s,a,h)}catch(e){throw s.state.vim=void 0,L(s),F.suppressErrorLogging||r["log"](e),e}return!0})}:void 0},handleEx:function(e,t){Bt.processCommand(e,t)},defineMotion:ae,defineAction:de,defineOperator:ce,mapCommand:Gt,_mapCommand:Ft,defineRegister:te,exitVisualMode:$e,exitInsertMode:Vt},j=[],U=!1;function G(e){if(!V)throw new Error("No prompt to send key to");if("<"==e[0]){var t=e.toLowerCase().slice(1,-1),n=t.split("-");if(t=n.pop()||"","lt"==t)e="<";else if("space"==t)e=" ";else if("cr"==t)e="\n";else if(z[t]){var r=V.value||"",i={key:z[t],target:{value:r,selectionEnd:r.length,selectionStart:r.length}};return V.onKeyDown&&V.onKeyDown(i,V.value,a),void(V&&V.onKeyUp&&V.onKeyUp(i,V.value,a))}}if("\n"==e){var o=V;V=null,o.onClose&&o.onClose(o.value)}else V.value=(V.value||"")+e;function a(e){V&&("string"==typeof e?V.value=e:V=null)}}function H(e,t,n){var r=U;if(n){if(-1!=j.indexOf(n))return;j.push(n),U=0!=n.noremap}try{var i,o=L(e),a=/<(?:[CSMA]-)*\w+>|./gi;while(i=a.exec(t)){var s=i[0],l=o.insertMode;if(V)G(s);else{var c=F.handleKey(e,s,"mapping");if(!c&&l&&o.insertMode){if("<"==s[0]){var u=s.toLowerCase().slice(1,-1),d=u.split("-");if(u=d.pop()||"","lt"==u)s="<";else if("space"==u)s=" ";else if("cr"==u)s="\n";else{if(z.hasOwnProperty(u)){s=z[u],Jt(e,s);continue}s=s[0],a.lastIndex=i.index+1}}e.replaceSelection(s)}}}}finally{if(j.pop(),U=!!j.length&&r,!j.length&&V){var h=V;V=null,St(e,h)}}}var q={Return:"CR",Backspace:"BS",Delete:"Del",Escape:"Esc",Insert:"Ins",ArrowLeft:"Left",ArrowRight:"Right",ArrowUp:"Up",ArrowDown:"Down",Enter:"CR"," ":"Space"},Q={Shift:1,Alt:1,Command:1,Control:1,CapsLock:1,AltGraph:1,Dead:1,Unidentified:1},z={};function K(t,n){var r=t.key;if(!Q[r]){r.length>1&&"n"==r[0]&&(r=r.replace("Numpad","")),r=q[r]||r;var i="";if(t.ctrlKey&&(i+="C-"),t.altKey&&(i+="A-"),t.metaKey&&(i+="M-"),e.isMac&&"A-"==i&&1==r.length&&(i=i.slice(2)),(i||r.length>1)&&t.shiftKey&&(i+="S-"),n&&!n.expectLiteralNext&&1==r.length)if(l.keymap&&r in l.keymap)0==l.remapCtrl&&i||(r=l.keymap[r]);else if(r.charCodeAt(0)>128&&!o[r]){var a=t.code?.slice(-1)||"";t.shiftKey||(a=a.toLowerCase()),a&&(r=a,!i&&t.altKey&&(i="A-"))}return i+=r,i.length>1&&(i="<"+i+">"),i}}function W(e,t){l.string!==e&&(l=X(e)),l.remapCtrl=t}function X(e){let t={};if(!e)return{keymap:t,string:""};function n(e){return e.split(/\\?(.)/).filter(Boolean)}return e.split(/((?:[^\\,]|\\.)+),/).map(e=>{if(!e)return;const r=e.split(/((?:[^\\;]|\\.)+);/);if(3==r.length){const e=n(r[1]),i=n(r[2]);if(e.length!==i.length)return;for(let n=0;n<e.length;++n)t[e[n]]=i[n]}else if(1==r.length){const r=n(e);if(r.length%2!==0)return;for(let e=0;e<r.length;e+=2)t[r[e]]=r[e+1]}}),{keymap:t,string:e}}"Left|Right|Up|Down|End|Home".split("|").concat(Object.keys(q)).forEach(function(e){z[(q[e]||"").toLowerCase()]=z[e.toLowerCase()]=e}),A("langmap",void 0,"string",["lmap"],function(e,t){if(void 0===e)return l.string;W(e)});class Y{constructor(){this.prefixRepeat=[],this.motionRepeat=[],this.operator=null,this.operatorArgs=null,this.motion=null,this.motionArgs=null,this.keyBuffer=[],this.registerName=void 0,this.changeQueue=null}pushRepeatDigit(e){this.operator?this.motionRepeat=this.motionRepeat.concat(e):this.prefixRepeat=this.prefixRepeat.concat(e)}getRepeat(){var e=0;return(this.prefixRepeat.length>0||this.motionRepeat.length>0)&&(e=1,this.prefixRepeat.length>0&&(e*=parseInt(this.prefixRepeat.join(""),10)),this.motionRepeat.length>0&&(e*=parseInt(this.motionRepeat.join(""),10))),e}}function Z(t,n){t.state.vim.inputState=new Y,t.state.vim.expectLiteralNext=!1,e.signal(t,"vim-command-done",n)}function J(){this.removed=[],this.inserted=""}class ee{constructor(e,t,n){this.clear(),this.keyBuffer=[e||""],this.insertModeChanges=[],this.searchQueries=[],this.linewise=!!t,this.blockwise=!!n}setText(e,t,n){this.keyBuffer=[e||""],this.linewise=!!t,this.blockwise=!!n}pushText(e,t){t&&(this.linewise||this.keyBuffer.push("\n"),this.linewise=!0),this.keyBuffer.push(e)}pushInsertModeChanges(e){this.insertModeChanges.push(M(e))}pushSearchQuery(e){this.searchQueries.push(e)}clear(){this.keyBuffer=[],this.insertModeChanges=[],this.searchQueries=[],this.linewise=!1}toString(){return this.keyBuffer.join("")}}function te(e,t){var n=N.registerController.registers;if(!e||1!=e.length)throw Error("Register name must be 1 character");if(n[e])throw Error("Register already defined "+e);n[e]=t,g.push(e)}class ne{constructor(e){this.registers=e,this.unnamedRegister=e['"']=new ee,e["."]=new ee,e[":"]=new ee,e["/"]=new ee,e["+"]=new ee}pushText(e,t,n,r,i){if("_"!==e){r&&"\n"!==n.charAt(n.length-1)&&(n+="\n");var o=this.isValidRegister(e)?this.getRegister(e):null;if(o&&e){var a=E(e);a?o.pushText(n,r):o.setText(n,r,i),"+"===e&&navigator.clipboard.writeText(n),this.unnamedRegister.setText(o.toString(),r)}else{switch(t){case"yank":this.registers["0"]=new ee(n,r,i);break;case"delete":case"change":-1==n.indexOf("\n")?this.registers["-"]=new ee(n,r):(this.shiftNumericRegisters_(),this.registers["1"]=new ee(n,r));break}this.unnamedRegister.setText(n,r,i)}}}getRegister(e){return this.isValidRegister(e)?(e=e.toLowerCase(),this.registers[e]||(this.registers[e]=new ee),this.registers[e]):this.unnamedRegister}isValidRegister(e){return e&&(k(e,g)||v.test(e))}shiftNumericRegisters_(){for(var e=9;e>=2;e--)this.registers[e]=this.getRegister(""+(e-1))}}class re{constructor(){this.historyBuffer=[],this.iterator=0,this.initialPrefix=null}nextMatch(e,t){var n=this.historyBuffer,r=t?-1:1;null===this.initialPrefix&&(this.initialPrefix=e);for(var i=this.iterator+r;t?i>=0:i<n.length;i+=r)for(var o=n[i],a=0;a<=o.length;a++)if(this.initialPrefix==o.substring(0,a))return this.iterator=i,o;return i>=n.length?(this.iterator=n.length,this.initialPrefix):i<0?e:void 0}pushInput(e){var t=this.historyBuffer.indexOf(e);t>-1&&this.historyBuffer.splice(t,1),e.length&&this.historyBuffer.push(e)}reset(){this.initialPrefix=null,this.iterator=this.historyBuffer.length}}var ie={matchCommand:function(e,t,n,r){var i=me(e,t,r,n),o=i.full[0];if(!o)return i.partial.length?{type:"partial",expectLiteralNext:1==i.partial.length&&"<character>"==i.partial[0].keys.slice(-11)}:{type:"none"};if("<character>"==o.keys.slice(-11)||"<register>"==o.keys.slice(-10)){var a=ve(e);if(!a||a.length>1)return{type:"clear"};n.selectedCharacter=a}return{type:"full",command:o}},processCommand:function(e,t,n){switch(t.inputState.repeatOverride=n.repeatOverride,n.type){case"motion":this.processMotion(e,t,n);break;case"operator":this.processOperator(e,t,n);break;case"operatorMotion":this.processOperatorMotion(e,t,n);break;case"action":this.processAction(e,t,n);break;case"search":this.processSearch(e,t,n);break;case"ex":case"keyToEx":this.processEx(e,t,n);break;default:break}},processMotion:function(e,t,n){t.inputState.motion=n.motion,t.inputState.motionArgs=pe(n.motionArgs),this.evalInput(e,t)},processOperator:function(e,t,n){var r=t.inputState;if(r.operator){if(r.operator==n.operator)return r.motion="expandToLine",r.motionArgs={linewise:!0,repeat:1},void this.evalInput(e,t);Z(e)}r.operator=n.operator,r.operatorArgs=pe(n.operatorArgs),n.keys.length>1&&(r.operatorShortcut=n.keys),n.exitVisualBlock&&(t.visualBlock=!1,De(e)),t.visualMode&&this.evalInput(e,t)},processOperatorMotion:function(e,t,n){var r=t.visualMode,i=pe(n.operatorMotionArgs);i&&r&&i.visualLine&&(t.visualLine=!0),this.processOperator(e,t,n),r||this.processMotion(e,t,n)},processAction:function(e,t,n){var r=t.inputState,i=r.getRepeat(),o=!!i,a=pe(n.actionArgs)||{repeat:1};r.selectedCharacter&&(a.selectedCharacter=r.selectedCharacter),n.operator&&this.processOperator(e,t,n),n.motion&&this.processMotion(e,t,n),(n.motion||n.operator)&&this.evalInput(e,t),a.repeat=i||1,a.repeatIsExplicit=o,a.registerName=r.registerName,Z(e),t.lastMotion=null,n.isEdit&&this.recordLastEdit(t,r,n),ue[n.action](e,a,t)},processSearch:function(t,n,r){if(t.getSearchCursor){var i=r.searchArgs.forward,o=r.searchArgs.wholeWordOnly;lt(t).setReversed(!i);var a=i?"/":"?",s=lt(t).getQuery(),l=t.getScrollInfo(),c="";switch(r.searchArgs.querySrc){case"prompt":var u=N.macroModeState;if(u.isPlaying){let e=u.replaySearchQueries.shift();p(e||"",!0,!1)}else St(t,{onClose:f,prefix:a,desc:yt("span",{$cursor:"pointer",onmousedown:function(e){e.preventDefault(),T("pcre",!R("pcre")),this.textContent=m(),v()}},m()),onKeyUp:g,onKeyDown:b});break;case"wordUnderCursor":var d=Ue(t,{noSymbol:!0}),h=!0;if(d||(d=Ue(t,{noSymbol:!1}),h=!1),!d)return wt(t,"No word under cursor"),void Z(t);let e=t.getLine(d.start.line).substring(d.start.ch,d.end.ch);e=h&&o?"\\b"+e+"\\b":Ce(e),N.jumpList.cachedCursor=t.getCursor(),t.setCursor(d.start),p(e,!0,!1);break}}function p(e,i,o){N.searchHistoryController.pushInput(e),N.searchHistoryController.reset();try{xt(t,e,i,o)}catch(a){return wt(t,"Invalid regex: "+e),void Z(t)}ie.processMotion(t,n,{keys:"",type:"motion",motion:"findNext",motionArgs:{forward:!0,toJumplist:r.searchArgs.toJumplist}})}function f(e){t.scrollTo(l.left,l.top),p(e,!0,!0);var n=N.macroModeState;n.isRecording&&zt(n,e)}function m(){return R("pcre")?"(JavaScript regexp: set pcre)":"(Vim regexp: set nopcre)"}function g(e,t,n){var r,i,o=K(e);"<Up>"==o||"<Down>"==o?(r="<Up>"==o,i=e.target?e.target.selectionEnd:0,t=N.searchHistoryController.nextMatch(t,r)||"",n(t),i&&e.target&&(e.target.selectionEnd=e.target.selectionStart=Math.min(i,e.target.value.length))):o&&"<Left>"!=o&&"<Right>"!=o&&N.searchHistoryController.reset(),c=t,v()}function v(){var e;try{e=xt(t,c,!0,!0)}catch(n){}e?t.scrollIntoView(At(t,!i,e),30):(Rt(t),t.scrollTo(l.left,l.top))}function b(n,r,i){var o=K(n);"<Esc>"==o||"<C-c>"==o||"<C-[>"==o||"<BS>"==o&&""==r?(N.searchHistoryController.pushInput(r),N.searchHistoryController.reset(),xt(t,s?.source||""),Rt(t),t.scrollTo(l.left,l.top),e.e_stop(n),Z(t),i(),t.focus()):"<Up>"==o||"<Down>"==o?e.e_stop(n):"<C-u>"==o&&(e.e_stop(n),i(""))}},processEx:function(t,n,r){function i(e){N.exCommandHistoryController.pushInput(e),N.exCommandHistoryController.reset(),Bt.processCommand(t,e),t.state.vim&&Z(t),Rt(t)}function o(n,r,i){var o,a,s=K(n);("<Esc>"==s||"<C-c>"==s||"<C-[>"==s||"<BS>"==s&&""==r)&&(N.exCommandHistoryController.pushInput(r),N.exCommandHistoryController.reset(),e.e_stop(n),Z(t),Rt(t),i(),t.focus()),"<Up>"==s||"<Down>"==s?(e.e_stop(n),o="<Up>"==s,a=n.target?n.target.selectionEnd:0,r=N.exCommandHistoryController.nextMatch(r,o)||"",i(r),a&&n.target&&(n.target.selectionEnd=n.target.selectionStart=Math.min(a,n.target.value.length))):"<C-u>"==s?(e.e_stop(n),i("")):s&&"<Left>"!=s&&"<Right>"!=s&&N.exCommandHistoryController.reset()}function a(n,r){var i=new e.StringStream(r),o={};try{if(Bt.parseInput_(t,i,o),"s"!=o.commandName)return void Rt(t);var a=Bt.matchCommand_(o.commandName);if(!a)return;if(Bt.parseCommandArgs_(i,o,a),!o.argString)return;var s=bt(o.argString.slice(1),!0,!0);s&&Ct(t,s)}catch(n){}}if("keyToEx"==r.type)Bt.processCommand(t,r.exArgs.input);else{var s={onClose:i,onKeyDown:o,onKeyUp:a,prefix:":"};if(n.visualMode)s.value="'<,'>",s.selectValueOnOpen=!1;else{var l=n.inputState.getRepeat();l>1&&(s.value=".,.+"+(l-1),s.selectValueOnOpen=!1)}St(t,s)}},evalInput:function(e,r){var i,o,a,s=r.inputState,l=s.motion,c=s.motionArgs||{repeat:1},u=s.operator,d=s.operatorArgs||{},h=s.registerName,p=r.sel,f=ye(r.visualMode?he(e,p.head):e.getCursor("head")),m=ye(r.visualMode?he(e,p.anchor):e.getCursor("anchor")),g=ye(f),v=ye(m);if(u&&this.recordLastEdit(r,s),a=void 0!==s.repeatOverride?s.repeatOverride:s.getRepeat(),a>0&&c.explicitRepeat?c.repeatIsExplicit=!0:(c.noRepeat||!c.explicitRepeat&&0===a)&&(a=1,c.repeatIsExplicit=!1),s.selectedCharacter&&(c.selectedCharacter=d.selectedCharacter=s.selectedCharacter),c.repeat=a,Z(e),l){var b=oe[l](e,f,c,r,s);if(r.lastMotion=oe[l],!b)return;if(c.toJumplist){var y=N.jumpList,w=y.cachedCursor;w?(He(e,w,b),delete y.cachedCursor):He(e,f,b)}b instanceof Array?(o=b[0],i=b[1]):i=b,i||(i=ye(f)),r.visualMode?(r.visualBlock&&i.ch===1/0||(i=he(e,i,g)),o&&(o=he(e,o)),o=o||v,p.anchor=o,p.head=i,De(e),et(e,r,"<",Oe(o,i)?o:i),et(e,r,">",Oe(o,i)?i:o)):u||(i=he(e,i,g),e.setCursor(i.line,i.ch))}if(u){if(d.lastSel){o=v;var O=d.lastSel,S=Math.abs(O.head.line-O.anchor.line),E=Math.abs(O.head.ch-O.anchor.ch);i=O.visualLine?new t(v.line+S,v.ch):O.visualBlock?new t(v.line+S,v.ch+E):O.head.line==O.anchor.line?new t(v.line,v.ch+E):new t(v.line+S,v.ch),r.visualMode=!0,r.visualLine=O.visualLine,r.visualBlock=O.visualBlock,p=r.sel={anchor:o,head:i},De(e)}else r.visualMode&&(d.lastSel={anchor:ye(p.anchor),head:ye(p.head),visualBlock:r.visualBlock,visualLine:r.visualLine});var x,_,k,C,A;if(r.visualMode){x=Se(p.head,p.anchor),_=Ee(p.head,p.anchor),k=r.visualLine||d.linewise,C=r.visualBlock?"block":k?"line":"char";var T=n(e,x,_);if(A=Le(e,{anchor:T.start,head:T.end},C),k){var R=A.ranges;if("block"==C)for(var P=0;P<R.length;P++)R[P].head.ch=_e(e,R[P].head.line);else"line"==C&&(R[0].head=new t(R[0].head.line+1,0))}}else{if(x=ye(o||v),_=ye(i||g),Oe(_,x)){var I=x;x=_,_=I}k=c.linewise||d.linewise,k?Fe(e,x,_):c.forward&&Ve(e,x,_),C="char";var M=!c.inclusive||k;T=n(e,x,_);A=Le(e,{anchor:T.start,head:T.end},C,M)}e.setSelections(A.ranges,A.primary),r.lastMotion=null,d.repeat=a,d.registerName=h,d.linewise=k;var D=le[u](e,d,A.ranges,v,i);r.visualMode&&$e(e,null!=D),D&&e.setCursor(D)}},recordLastEdit:function(e,t,n){var r=N.macroModeState;r.isPlaying||(e.lastEditInputState=t,e.lastEditActionCommand=n,r.lastInsertModeChanges.changes=[],r.lastInsertModeChanges.expectCursorActivityForChange=!1,r.lastInsertModeChanges.visualBlock=e.visualBlock?e.sel.head.line-e.sel.anchor.line:0)}},oe={moveToTopLine:function(e,n,r){var i=Pt(e).top+r.repeat-1;return new t(i,je(e.getLine(i)))},moveToMiddleLine:function(e){var n=Pt(e),r=Math.floor(.5*(n.top+n.bottom));return new t(r,je(e.getLine(r)))},moveToBottomLine:function(e,n,r){var i=Pt(e).bottom-r.repeat+1;return new t(i,je(e.getLine(i)))},expandToLine:function(e,n,r){var i=n;return new t(i.line+r.repeat-1,1/0)},findNext:function(e,t,n){var r=lt(e),i=r.getQuery();if(i){var o=!n.forward;o=r.isReversed()?!o:o,Ct(e,i);var a=At(e,o,i,n.repeat);return a||wt(e,"No match found "+i+(R("pcre")?" (set nopcre to use Vim regexps)":"")),a}},findAndSelectNextInclusive:function(n,r,i,o,a){var s=lt(n),l=s.getQuery();if(l){var c=!i.forward;c=s.isReversed()?!c:c;var u=Tt(n,c,l,i.repeat,o);if(u){if(a.operator)return u;var d=u[0],h=new t(u[1].line,u[1].ch-1);if(o.visualMode){(o.visualLine||o.visualBlock)&&(o.visualLine=!1,o.visualBlock=!1,e.signal(n,"vim-mode-change",{mode:"visual",subMode:""}));var p=o.sel.anchor;if(p)return s.isReversed()?i.forward?[p,d]:[p,h]:i.forward?[p,h]:[p,d]}else o.visualMode=!0,o.visualLine=!1,o.visualBlock=!1,e.signal(n,"vim-mode-change",{mode:"visual",subMode:""});return c?[h,d]:[d,h]}}},goToMark:function(e,t,n,r){var i=It(e,r,n.selectedCharacter||"");return i?n.linewise?{line:i.line,ch:je(e.getLine(i.line))}:i:null},moveToOtherHighlightedEnd:function(e,n,r,i){var o=i.sel;return i.visualBlock&&r.sameLine?[he(e,new t(o.anchor.line,o.head.ch)),he(e,new t(o.head.line,o.anchor.ch))]:[o.head,o.anchor]},jumpToMark:function(e,n,r,i){for(var o=n,a=0;a<r.repeat;a++){var s=o;for(var l in i.marks)if(w(l)){var c=i.marks[l].find(),u=r.forward?Oe(c,s):Oe(s,c);if(!u&&(!r.linewise||c.line!=s.line)){var d=we(s,o),h=r.forward?xe(s,c,o):xe(o,c,s);(d||h)&&(o=c)}}}return r.linewise&&(o=new t(o.line,je(e.getLine(o.line)))),o},moveByCharacters:function(e,n,r){var i=n,o=r.repeat,a=r.forward?i.ch+o:i.ch-o;return new t(i.line,a)},moveByLines:function(e,n,r,i){var o=n,a=o.ch;switch(i.lastMotion){case this.moveByLines:case this.moveByDisplayLines:case this.moveByScroll:case this.moveToColumn:case this.moveToEol:a=i.lastHPos;break;default:i.lastHPos=a}var s=r.repeat+(r.repeatOffset||0),l=r.forward?o.line+s:o.line-s,c=e.firstLine(),u=e.lastLine(),d=e.findPosV(o,r.forward?s:-s,"line",i.lastHSPos),h=r.forward?d.line>l:d.line<l;return h&&(l=d.line,a=d.ch),l<c&&o.line==c?this.moveToStartOfLine(e,n,r,i):l>u&&o.line==u?Ye(e,n,r,i,!0):(r.toFirstChar&&(a=je(e.getLine(l)),i.lastHPos=a),i.lastHSPos=e.charCoords(new t(l,a),"div").left,new t(l,a))},moveByDisplayLines:function(e,t,n,r){var i=t;switch(r.lastMotion){case this.moveByDisplayLines:case this.moveByScroll:case this.moveByLines:case this.moveToColumn:case this.moveToEol:break;default:r.lastHSPos=e.charCoords(i,"div").left}for(var o=Math.round(n.repeat),a=0;a<o;a++){var s=e.findPosV(i,n.forward?1:-1,"line",r.lastHSPos);if(s.hitSide)break;i=s}return i!=t&&(r.lastHPos=i.ch),i},moveByPage:function(e,t,n){var r=t,i=n.repeat;return e.findPosV(r,n.forward?i:-i,"page")},moveByParagraph:function(e,t,n){var r=n.forward?1:-1;return nt(e,t,n.repeat,r).start},moveBySentence:function(e,t,n){var r=n.forward?1:-1;return it(e,t,n.repeat,r)},moveByScroll:function(e,t,n,r){var i=e.getScrollInfo(),o=null,a=n.repeat;a||(a=i.clientHeight/(2*e.defaultTextHeight()));var s=e.charCoords(t,"local");if(n.repeat=a,o=oe.moveByDisplayLines(e,t,n,r),!o)return null;var l=e.charCoords(o,"local");return e.scrollTo(null,i.top+l.top-s.top),o},moveByWords:function(e,t,n){return Xe(e,t,n.repeat,!!n.forward,!!n.wordEnd,!!n.bigWord)},moveTillCharacter:function(e,t,n){var r=n.repeat,i=Ze(e,r,n.forward,n.selectedCharacter,t),o=n.forward?-1:1;return qe(o,n),i?(i.ch+=o,i):null},moveToCharacter:function(e,t,n){var r=n.repeat;return qe(0,n),Ze(e,r,n.forward,n.selectedCharacter,t)||t},moveToSymbol:function(e,t,n){var r=n.repeat;return n.selectedCharacter&&Ke(e,r,n.forward,n.selectedCharacter)||t},moveToColumn:function(e,t,n,r){var i=n.repeat;return r.lastHPos=i-1,r.lastHSPos=e.charCoords(t,"div").left,Je(e,i)},moveToEol:function(e,t,n,r){return Ye(e,t,n,r,!1)},moveToFirstNonWhiteSpaceCharacter:function(e,n){var r=n;return new t(r.line,je(e.getLine(r.line)))},moveToMatchedSymbol:function(e,n){for(var r,i=n,o=i.line,a=i.ch,s=e.getLine(o);a<s.length;a++)if(r=s.charAt(a),r&&O(r)){var l=e.getTokenTypeAt(new t(o,a+1));if("string"!==l&&"comment"!==l)break}if(a<s.length){var c="<"===r||">"===r?/[(){}[\]<>]/:/[(){}[\]]/,u=e.findMatchingBracket(new t(o,a),{bracketRegex:c});return u.to}return i},moveToStartOfLine:function(e,n){return new t(n.line,0)},moveToLineOrEdgeOfDocument:function(e,n,r){var i=r.forward?e.lastLine():e.firstLine();return r.repeatIsExplicit&&(i=r.repeat-e.getOption("firstLineNumber")),new t(i,je(e.getLine(i)))},moveToStartOfDisplayLine:function(e){return e.execCommand("goLineLeft"),e.getCursor()},moveToEndOfDisplayLine:function(e){e.execCommand("goLineRight");var t=e.getCursor();return"before"==t.sticky&&t.ch--,t},textObjectManipulation:function(e,t,n,r){var i={"(":")",")":"(","{":"}","}":"{","[":"]","]":"[","<":">",">":"<"},o={"'":!0,'"':!0,"`":!0},a=n.selectedCharacter||"";"b"==a?a="(":"B"==a&&(a="{");var s,l,c=!n.textObjectInner;if(i[a]){if(l=!0,s=ot(e,t,a,c),!s){var u=e.getSearchCursor(new RegExp("\\"+a,"g"),t);u.find()&&(s=ot(e,u.from(),a,c))}}else if(o[a])l=!0,s=at(e,t,a,c);else if("W"===a||"w"===a){var d=n.repeat||1;while(d-- >0){var h=Ue(e,{inclusive:c,innerWord:!c,bigWord:"W"===a,noSymbol:"W"===a,multiline:!0},s&&s.end);h&&(s||(s=h),s.end=h.end)}}else if("p"===a)if(s=nt(e,t,n.repeat,0,c),n.linewise=!0,r.visualMode)r.visualLine||(r.visualLine=!0);else{var p=r.inputState.operatorArgs;p&&(p.linewise=!0),s.end.line--}else if("t"===a)s=Ge(e,t,c);else if("s"===a){var f=e.getLine(t.line);t.ch>0&&_(f[t.ch])&&(t.ch-=1);var m=rt(e,t,n.repeat,1,c),g=rt(e,t,n.repeat,-1,c);x(e.getLine(g.line)[g.ch])&&x(e.getLine(m.line)[m.ch-1])&&(g={line:g.line,ch:g.ch+1}),s={start:g,end:m}}return s?e.state.vim.visualMode?Me(e,s.start,s.end,l):[s.start,s.end]:null},repeatLastCharacterSearch:function(e,t,n){var r=N.lastCharacterSearch,i=n.repeat,o=n.forward===r.forward,a=(r.increment?1:0)*(o?-1:1);n.inclusive=!!o;var s=Ze(e,i,o,r.selectedCharacter,fe(t,0,-a));return s?(s.ch+=a,s):t}};function ae(e,t){oe[e]=t}function se(e,t){for(var n=[],r=0;r<t;r++)n.push(e);return n}var le={change:function(e,n,r){var i,o,a=e.state.vim,s=r[0].anchor,l=r[0].head;if(a.visualMode)if(n.fullLine)l.ch=Number.MAX_VALUE,l.line--,e.setSelection(s,l),o=e.getSelection(),e.replaceSelection(""),i=s;else{o=e.getSelection();var c=se("",r.length);e.replaceSelections(c),i=Se(r[0].head,r[0].anchor)}else{o=e.getRange(s,l);var u=a.lastEditInputState;if("moveByWords"==u?.motion&&!x(o)){var d=/\s+$/.exec(o);d&&u.motionArgs&&u.motionArgs.forward&&(l=fe(l,0,-d[0].length),o=o.slice(0,-d[0].length))}n.linewise&&(s=new t(s.line,je(e.getLine(s.line))),l.line>s.line&&(l=new t(l.line-1,Number.MAX_VALUE))),e.replaceRange("",s,l),i=s}N.registerController.pushText(n.registerName,"change",o,n.linewise,r.length>1),ue.enterInsertMode(e,{head:i},e.state.vim)},delete:function(e,n,r){var i,o,a=e.state.vim;if(a.visualBlock){o=e.getSelection();var s=se("",r.length);e.replaceSelections(s),i=Se(r[0].head,r[0].anchor)}else{var l=r[0].anchor,c=r[0].head;n.linewise&&c.line!=e.firstLine()&&l.line==e.lastLine()&&l.line==c.line-1&&(l.line==e.firstLine()?l.ch=0:l=new t(l.line-1,_e(e,l.line-1))),o=e.getRange(l,c),e.replaceRange("",l,c),i=l,n.linewise&&(i=oe.moveToFirstNonWhiteSpaceCharacter(e,l))}return N.registerController.pushText(n.registerName,"delete",o,n.linewise,a.visualBlock),he(e,i)},indent:function(e,t,n){var r=e.state.vim,i=r.visualMode&&t.repeat||1;if(r.visualBlock){for(var o,a=e.getOption("tabSize"),s=e.getOption("indentWithTabs")?"\t":" ".repeat(a),l=n.length-1;l>=0;l--)if(o=Se(n[l].anchor,n[l].head),t.indentRight)e.replaceRange(s.repeat(i),o,o);else{for(var c=e.getLine(o.line),u=0,d=0;d<i;d++){var h=c[o.ch+u];if("\t"==h)u++;else{if(" "!=h)break;u++;for(var p=1;p<s.length;p++){if(h=c[o.ch+u]," "!==h)break;u++}}}e.replaceRange("",o,fe(o,0,u))}return o}if(e.indentMore)for(d=0;d<i;d++)t.indentRight?e.indentMore():e.indentLess();else{var f=n[0].anchor.line,m=r.visualBlock?n[n.length-1].anchor.line:n[0].head.line;t.linewise&&m--;for(l=f;l<=m;l++)for(d=0;d<i;d++)e.indentLine(l,t.indentRight)}return oe.moveToFirstNonWhiteSpaceCharacter(e,n[0].anchor)},indentAuto:function(e,t,n){return e.execCommand("indentAuto"),oe.moveToFirstNonWhiteSpaceCharacter(e,n[0].anchor)},hardWrap:function(e,n,r,i){if(e.hardWrap){var o=r[0].anchor.line,a=r[0].head.line;n.linewise&&a--;var s=e.hardWrap({from:o,to:a});return s>o&&n.linewise&&s--,n.keepCursor?i:new t(s,0)}},toggleComment:function(e,t,n,r,i){return e.execCommand("toggleLineComment"),i},changeCase:function(e,t,n,r,i){for(var o=e.getSelections(),a=[],s=t.toLower,l=0;l<o.length;l++){var c=o[l],u="";if(!0===s)u=c.toLowerCase();else if(!1===s)u=c.toUpperCase();else for(var d=0;d<c.length;d++){var h=c.charAt(d);u+=E(h)?h.toLowerCase():h.toUpperCase()}a.push(u)}return e.replaceSelections(a),t.shouldMoveCursor?i:!e.state.vim.visualMode&&t.linewise&&n[0].anchor.line+1==n[0].head.line?oe.moveToFirstNonWhiteSpaceCharacter(e,r):t.linewise?r:Se(n[0].anchor,n[0].head)},yank:function(e,t,n,r){var i=e.state.vim,o=e.getSelection(),a=i.visualMode?Se(i.sel.anchor,i.sel.head,n[0].head,n[0].anchor):r;N.registerController.pushText(t.registerName,"yank",o,t.linewise,i.visualBlock);var s=Math.abs(e.getCursor("end").line-e.getCursor("start").line)||1;return wt(e,s+" lines yanked"+(t.registerName?' into "'+t.registerName:""),!1,1500),a},rot13:function(e,t,n,r,i){for(var o=e.getSelections(),a=[],s=0;s<o.length;s++){const e=o[s].split("").map(e=>{const t=e.charCodeAt(0);return t>=65&&t<=90?String.fromCharCode(65+(t-65+13)%26):t>=97&&t<=122?String.fromCharCode(97+(t-97+13)%26):e}).join("");a.push(e)}return e.replaceSelections(a),t.shouldMoveCursor?i:!e.state.vim.visualMode&&t.linewise&&n[0].anchor.line+1==n[0].head.line?oe.moveToFirstNonWhiteSpaceCharacter(e,r):t.linewise?r:Se(n[0].anchor,n[0].head)}};function ce(e,t){le[e]=t}var ue={jumpListWalk:function(e,t,n){if(!n.visualMode){var r=t.repeat||1,i=t.forward,o=N.jumpList,a=o.move(e,i?r:-r),s=a?a.find():void 0;s=s||e.getCursor(),e.setCursor(s)}},scroll:function(e,t,n){if(!n.visualMode){var r=t.repeat||1,i=e.defaultTextHeight(),o=e.getScrollInfo().top,a=i*r,s=t.forward?o+a:o-a,l=ye(e.getCursor()),c=e.charCoords(l,"local");if(t.forward)s>c.top?(l.line+=(s-c.top)/i,l.line=Math.ceil(l.line),e.setCursor(l),c=e.charCoords(l,"local"),e.scrollTo(null,c.top)):e.scrollTo(null,s);else{var u=s+e.getScrollInfo().clientHeight;u<c.bottom?(l.line-=(c.bottom-u)/i,l.line=Math.floor(l.line),e.setCursor(l),c=e.charCoords(l,"local"),e.scrollTo(null,c.bottom-e.getScrollInfo().clientHeight)):e.scrollTo(null,s)}}},scrollToCursor:function(e,n){var r=e.getCursor().line,i=e.charCoords(new t(r,0),"local"),o=e.getScrollInfo().clientHeight,a=i.top;switch(n.position){case"center":a=i.bottom-o/2;break;case"bottom":var s=new t(r,e.getLine(r).length-1),l=e.charCoords(s,"local"),c=l.bottom-a;a=a-o+c;break}e.scrollTo(null,a)},replayMacro:function(e,t,n){var r=t.selectedCharacter||"",i=t.repeat||1,o=N.macroModeState;"@"==r?r=o.latestRegister||"":o.latestRegister=r;while(i--)Ht(e,n,o,r)},enterMacroRecordMode:function(e,t){var n=N.macroModeState,r=t.selectedCharacter;N.registerController.isValidRegister(r)&&n.enterMacroRecordMode(e,r)},toggleOverwrite:function(t){t.state.overwrite?(t.toggleOverwrite(!1),t.setOption("keyMap","vim-insert"),e.signal(t,"vim-mode-change",{mode:"insert"})):(t.toggleOverwrite(!0),t.setOption("keyMap","vim-replace"),e.signal(t,"vim-mode-change",{mode:"replace"}))},enterInsertMode:function(r,i,o){if(!r.getOption("readOnly")){o.insertMode=!0,o.insertModeRepeat=i&&i.repeat||1;var a=i?i.insertAt:null,s=o.sel,l=i.head||r.getCursor("head"),c=r.listSelections().length;if("eol"==a)l=new t(l.line,_e(r,l.line));else if("bol"==a)l=new t(l.line,0);else if("charAfter"==a){var u=n(r,l,fe(l,0,1));l=u.end}else if("firstNonBlank"==a){u=n(r,l,oe.moveToFirstNonWhiteSpaceCharacter(r,l));l=u.end}else if("startOfSelectedArea"==a){if(!o.visualMode)return;o.visualBlock?(l=new t(Math.min(s.head.line,s.anchor.line),Math.min(s.head.ch,s.anchor.ch)),c=Math.abs(s.head.line-s.anchor.line)+1):l=s.head.line<s.anchor.line?s.head:new t(s.anchor.line,0)}else if("endOfSelectedArea"==a){if(!o.visualMode)return;o.visualBlock?(l=new t(Math.min(s.head.line,s.anchor.line),Math.max(s.head.ch,s.anchor.ch)+1),c=Math.abs(s.head.line-s.anchor.line)+1):l=s.head.line>=s.anchor.line?fe(s.head,0,1):new t(s.anchor.line,0)}else if("inplace"==a){if(o.visualMode)return}else"lastEdit"==a&&(l=Mt(r)||l);r.setOption("disableInput",!1),i&&i.replace?(r.toggleOverwrite(!0),r.setOption("keyMap","vim-replace"),e.signal(r,"vim-mode-change",{mode:"replace"})):(r.toggleOverwrite(!1),r.setOption("keyMap","vim-insert"),e.signal(r,"vim-mode-change",{mode:"insert"})),N.macroModeState.isPlaying||(r.on("change",Kt),o.insertEnd&&o.insertEnd.clear(),o.insertEnd=r.setBookmark(l,{insertLeft:!0}),e.on(r.getInputField(),"keydown",Yt)),o.visualMode&&$e(r),Re(r,l,c)}},toggleVisualMode:function(r,i,o){var a,s=i.repeat,l=r.getCursor();if(o.visualMode)o.visualLine!=!!i.linewise||o.visualBlock!=!!i.blockwise?(o.visualLine=!!i.linewise,o.visualBlock=!!i.blockwise,e.signal(r,"vim-mode-change",{mode:"visual",subMode:o.visualLine?"linewise":o.visualBlock?"blockwise":""}),De(r)):$e(r);else{o.visualMode=!0,o.visualLine=!!i.linewise,o.visualBlock=!!i.blockwise,a=he(r,new t(l.line,l.ch+s-1));var c=n(r,l,a);o.sel={anchor:c.start,head:c.end},e.signal(r,"vim-mode-change",{mode:"visual",subMode:o.visualLine?"linewise":o.visualBlock?"blockwise":""}),De(r),et(r,o,"<",Se(l,a)),et(r,o,">",Ee(l,a))}},reselectLastSelection:function(t,n,r){var i=r.lastSelection;if(r.visualMode&&Ie(t,r),i){var o=i.anchorMark.find(),a=i.headMark.find();if(!o||!a)return;r.sel={anchor:o,head:a},r.visualMode=!0,r.visualLine=i.visualLine,r.visualBlock=i.visualBlock,De(t),et(t,r,"<",Se(o,a)),et(t,r,">",Ee(o,a)),e.signal(t,"vim-mode-change",{mode:"visual",subMode:r.visualLine?"linewise":r.visualBlock?"blockwise":""})}},joinLines:function(e,n,r){var i,o;if(r.visualMode){if(i=e.getCursor("anchor"),o=e.getCursor("head"),Oe(o,i)){var a=o;o=i,i=a}o.ch=_e(e,o.line)-1}else{var s=Math.max(n.repeat,2);i=e.getCursor(),o=he(e,new t(i.line+s-1,1/0))}for(var l=0,c=i.line;c<o.line;c++){l=_e(e,i.line);var u="",d=0;if(!n.keepSpaces){var h=e.getLine(i.line+1);d=h.search(/\S/),-1==d?d=h.length:u=" "}e.replaceRange(u,new t(i.line,l),new t(i.line+1,d))}var p=he(e,new t(i.line,l));r.visualMode&&$e(e,!1),e.setCursor(p)},newLineAndEnterInsertMode:function(n,r,i){i.insertMode=!0;var o=ye(n.getCursor());if(o.line!==n.firstLine()||r.after){o.line=r.after?o.line:o.line-1,o.ch=_e(n,o.line),n.setCursor(o);var a=e.commands.newlineAndIndentContinueComment||e.commands.newlineAndIndent;a(n)}else n.replaceRange("\n",new t(n.firstLine(),0)),n.setCursor(n.firstLine(),0);this.enterInsertMode(n,{repeat:r.repeat},i)},paste:function(e,t,n){var r=N.registerController.getRegister(t.registerName);if("+"===t.registerName)navigator.clipboard.readText().then(i=>{this.continuePaste(e,t,n,i,r)});else{var i=r.toString();this.continuePaste(e,t,n,i,r)}},continuePaste:function(e,n,r,i,o){var a=ye(e.getCursor());if(i){if(n.matchIndent){var s=e.getOption("tabSize"),l=function(e){var t=e.split("\t").length-1,n=e.split(" ").length-1;return t*s+1*n},c=e.getLine(e.getCursor().line),u=l(c.match(/^\s*/)[0]),d=i.replace(/\n$/,""),h=i!==d,p=l(i.match(/^\s*/)[0]);i=d.replace(/^\s*/gm,function(t){var n=u+(l(t)-p);if(n<0)return"";if(e.getOption("indentWithTabs")){var r=Math.floor(n/s);return Array(r+1).join("\t")}return Array(n+1).join(" ")});i+=h?"\n":""}n.repeat>1&&(i=Array(n.repeat+1).join(i));var f,m=void 0==n.linewise?o.linewise:n.linewise,g=o.blockwise,v=g?i.split("\n"):void 0;if(v){m&&v.pop();for(var b=0;b<v.length;b++)v[b]=""==v[b]?" ":v[b];a.ch+=n.after?1:0,a.ch=Math.min(_e(e,a.line),a.ch)}else m?r.visualMode?i=r.visualLine?i.slice(0,-1):"\n"+i.slice(0,i.length-1)+"\n":n.after?(i="\n"+i.slice(0,i.length-1),a.ch=_e(e,a.line)):a.ch=0:a.ch+=n.after?1:0;if(r.visualMode){var y;r.lastPastedText=i;var w=Pe(e,r),O=w[0],S=w[1],E=e.getSelection(),x=e.listSelections(),_=new Array(x.length).join("1").split("1");r.lastSelection&&(y=r.lastSelection.headMark.find()),N.registerController.unnamedRegister.setText(E),g?(e.replaceSelections(_),S=new t(O.line+i.length-1,O.ch),e.setCursor(O),Te(e,S),e.replaceSelections(i),f=O):r.visualBlock?(e.replaceSelections(_),e.setCursor(O),e.replaceRange(i,O,O),f=O):(e.replaceRange(i,O,S),f=e.posFromIndex(e.indexFromPos(O)+i.length-1)),y&&(r.lastSelection.headMark=e.setBookmark(y)),m&&(f.ch=0)}else if(g&&v){e.setCursor(a);for(b=0;b<v.length;b++){var k=a.line+b;k>e.lastLine()&&e.replaceRange("\n",new t(k,0));var C=_e(e,k);C<a.ch&&Ae(e,k,a.ch)}e.setCursor(a),Te(e,new t(a.line+v.length-1,a.ch)),e.replaceSelections(v),f=a}else if(e.replaceRange(i,a),m){k=n.after?a.line+1:a.line;f=new t(k,je(e.getLine(k)))}else f=ye(a),/\n/.test(i)||(f.ch+=i.length-(n.after?1:0));r.visualMode&&$e(e,!1),e.setCursor(f)}},undo:function(t,n){t.operation(function(){be(t,e.commands.undo,n.repeat)(),t.setCursor(he(t,t.getCursor("start")))})},redo:function(t,n){be(t,e.commands.redo,n.repeat)()},setRegister:function(e,t,n){n.inputState.registerName=t.selectedCharacter},insertRegister:function(e,t,n){var r=t.selectedCharacter,i=N.registerController.getRegister(r),o=i&&i.toString();o&&e.replaceSelection(o)},oneNormalCommand:function(t,n,r){Vt(t,!0),r.insertModeReturn=!0,e.on(t,"vim-command-done",function n(){r.visualMode||(r.insertModeReturn&&(r.insertModeReturn=!1,r.insertMode||ue.enterInsertMode(t,{},r)),e.off(t,"vim-command-done",n))})},setMark:function(e,t,n){var r=t.selectedCharacter;r&&et(e,n,r,e.getCursor())},replace:function(r,i,o){var a,s,l=i.selectedCharacter||"",c=r.getCursor(),u=r.listSelections();if(o.visualMode)c=r.getCursor("start"),s=r.getCursor("end");else{var d=r.getLine(c.line);a=c.ch+i.repeat,a>d.length&&(a=d.length),s=new t(c.line,a)}var h=n(r,c,s);if(c=h.start,s=h.end,"\n"==l)o.visualMode||r.replaceRange("",c,s),(e.commands.newlineAndIndentContinueComment||e.commands.newlineAndIndent)(r);else{var p=r.getRange(c,s);if(p=p.replace(/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,l),p=p.replace(/[^\n]/g,l),o.visualBlock){var f=new Array(r.getOption("tabSize")+1).join(" ");p=r.getSelection(),p=p.replace(/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,l);var m=p.replace(/\t/g,f).replace(/[^\n]/g,l).split("\n");r.replaceSelections(m)}else r.replaceRange(p,c,s);o.visualMode?(c=Oe(u[0].anchor,u[0].head)?u[0].anchor:u[0].head,r.setCursor(c),$e(r,!1)):r.setCursor(fe(s,0,-1))}},incrementNumberToken:function(e,n){var r,i,o,a,s=e.getCursor(),l=e.getLine(s.line),c=/(-?)(?:(0x)([\da-f]+)|(0b|0|)(\d+))/gi;while(null!==(r=c.exec(l)))if(i=r.index,o=i+r[0].length,s.ch<o)break;if((n.backtrack||!(o<=s.ch))&&r){var u=r[2]||r[4],d=r[3]||r[5],h=n.increase?1:-1,p={"0b":2,0:8,"":10,"0x":16}[u.toLowerCase()],f=parseInt(r[1]+d,p)+h*n.repeat;a=f.toString(p);var m=u?new Array(d.length-a.length+1+r[1].length).join("0"):"";a="-"===a.charAt(0)?"-"+u+m+a.substr(1):u+m+a;var g=new t(s.line,i),v=new t(s.line,o);e.replaceRange(a,g,v),e.setCursor(new t(s.line,i+a.length-1))}},repeatLastEdit:function(e,t,n){var r=n.lastEditInputState;if(r){var i=t.repeat;i&&t.repeatIsExplicit?r.repeatOverride=i:i=r.repeatOverride||i,Zt(e,n,i,!1)}},indent:function(e,t){e.indentLine(e.getCursor().line,t.indentRight)},exitInsertMode:function(e,t){Vt(e)}};function de(e,t){ue[e]=t}function he(e,n,r){var i=e.state.vim,o=i.insertMode||i.visualMode,a=Math.min(Math.max(e.firstLine(),n.line),e.lastLine()),s=e.getLine(a),l=s.length-1+Number(!!o),c=Math.min(Math.max(0,n.ch),l),u=s.charCodeAt(c);if(56320<=u&&u<=57343){var d=1;r&&r.line==a&&r.ch>c&&(d=-1),c+=d,c>l&&(c-=2)}return new t(a,c)}function pe(e){var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t}function fe(e,n,r){return"object"===typeof n&&(r=n.ch,n=n.line),new t(e.line+n,e.ch+r)}function me(e,t,n,r){r.operator&&(n="operatorPending");for(var i,o=[],s=[],l=U?t.length-a:0,c=l;c<t.length;c++){var u=t[c];"insert"==n&&"insert"!=u.context||u.context&&u.context!=n||r.operator&&"action"==u.type||!(i=ge(e,u.keys))||("partial"==i&&o.push(u),"full"==i&&s.push(u))}return{partial:o,full:s}}function ge(e,t){const n="<character>"==t.slice(-11),r="<register>"==t.slice(-10);if(n||r){var i=t.length-(n?11:10),o=e.slice(0,i),a=t.slice(0,i);return o==a&&e.length>i?"full":0==a.indexOf(o)&&"partial"}return e==t?"full":0==t.indexOf(e)&&"partial"}function ve(e){var t=/^.*(<[^>]+>)$/.exec(e),n=t?t[1]:e.slice(-1);if(n.length>1)switch(n){case"<CR>":case"<S-CR>":n="\n";break;case"<Space>":case"<S-Space>":n=" ";break;default:n="";break}return n}function be(e,t,n){return function(){for(var r=0;r<n;r++)t(e)}}function ye(e){return new t(e.line,e.ch)}function we(e,t){return e.ch==t.ch&&e.line==t.line}function Oe(e,t){return e.line<t.line||e.line==t.line&&e.ch<t.ch}function Se(e,t){return arguments.length>2&&(t=Se.apply(void 0,Array.prototype.slice.call(arguments,1))),Oe(e,t)?e:t}function Ee(e,t){return arguments.length>2&&(t=Ee.apply(void 0,Array.prototype.slice.call(arguments,1))),Oe(e,t)?t:e}function xe(e,t,n){var r=Oe(e,t),i=Oe(t,n);return r&&i}function _e(e,t){return e.getLine(t).length}function ke(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}function Ce(e){return e.replace(/([.?*+$\[\]\/\\(){}|\-])/g,"\\$1")}function Ae(e,n,r){var i=_e(e,n),o=new Array(r-i+1).join(" ");e.setCursor(new t(n,i)),e.replaceRange(o,e.getCursor())}function Te(e,n){var r=[],i=e.listSelections(),o=ye(e.clipPos(n)),a=!we(n,o),s=e.getCursor("head"),l=Ne(i,s),c=we(i[l].head,i[l].anchor),u=i.length-1,d=u-l>l?u:0,h=i[d].anchor,p=Math.min(h.line,o.line),f=Math.max(h.line,o.line),m=h.ch,g=o.ch,v=i[d].head.ch-m,b=g-m;v>0&&b<=0?(m++,a||g--):v<0&&b>=0?(m--,c||g++):v<0&&-1==b&&(m--,g++);for(var y=p;y<=f;y++){var w={anchor:new t(y,m),head:new t(y,g)};r.push(w)}return e.setSelections(r),n.ch=g,h.ch=m,h}function Re(e,t,n){for(var r=[],i=0;i<n;i++){var o=fe(t,i,0);r.push({anchor:o,head:o})}e.setSelections(r,0)}function Ne(e,t,n){for(var r=0;r<e.length;r++){var i="head"!=n&&we(e[r].anchor,t),o="anchor"!=n&&we(e[r].head,t);if(i||o)return r}return-1}function Pe(e,t){var n=e.listSelections(),r=n[0],i=n[n.length-1],o=Oe(r.anchor,r.head)?r.anchor:r.head,a=Oe(i.anchor,i.head)?i.head:i.anchor;return[o,a]}function Ie(e,t){var n=t.sel.anchor,r=t.sel.head;t.lastPastedText&&(r=e.posFromIndex(e.indexFromPos(n)+t.lastPastedText.length),t.lastPastedText=void 0),t.lastSelection={anchorMark:e.setBookmark(n),headMark:e.setBookmark(r),anchor:ye(n),head:ye(r),visualMode:t.visualMode,visualLine:t.visualLine,visualBlock:t.visualBlock}}function Me(e,n,r,i){var o,a=e.state.vim.sel,s=i?n:a.head,l=i?n:a.anchor;return Oe(r,n)&&(o=r,r=n,n=o),Oe(s,l)?(s=Se(n,s),l=Ee(l,r)):(l=Se(n,l),s=Ee(s,r),s=fe(s,0,-1),-1==s.ch&&s.line!=e.firstLine()&&(s=new t(s.line-1,_e(e,s.line-1)))),[l,s]}function De(e,t,n){var r=e.state.vim;t=t||r.sel,n||(n=r.visualLine?"line":r.visualBlock?"block":"char");var i=Le(e,t,n);e.setSelections(i.ranges,i.primary)}function Le(e,n,r,i){var o=ye(n.head),a=ye(n.anchor);if("char"==r){var s=i||Oe(n.head,n.anchor)?0:1,l=Oe(n.head,n.anchor)?1:0;return o=fe(n.head,0,s),a=fe(n.anchor,0,l),{ranges:[{anchor:a,head:o}],primary:0}}if("line"==r){if(Oe(n.head,n.anchor))o.ch=0,a.ch=_e(e,a.line);else{a.ch=0;var c=e.lastLine();o.line>c&&(o.line=c),o.ch=_e(e,o.line)}return{ranges:[{anchor:a,head:o}],primary:0}}if("block"==r){var u=Math.min(a.line,o.line),d=a.ch,h=Math.max(a.line,o.line),p=o.ch;d<p?p+=1:d+=1;for(var f=h-u+1,m=o.line==u?0:f-1,g=[],v=0;v<f;v++)g.push({anchor:new t(u+v,d),head:new t(u+v,p)});return{ranges:g,primary:m}}throw"never happens"}function Be(e){var t=e.getCursor("head");return 1==e.getSelection().length&&(t=Se(t,e.getCursor("anchor"))),t}function $e(t,n){var r=t.state.vim;!1!==n&&t.setCursor(he(t,r.sel.head)),Ie(t,r),r.visualMode=!1,r.visualLine=!1,r.visualBlock=!1,r.insertMode||e.signal(t,"vim-mode-change",{mode:"normal"})}function Ve(e,t,n){var r=e.getRange(t,n);if(/\n\s*$/.test(r)){var i=r.split("\n");i.pop();for(var o=i.pop();i.length>0&&o&&x(o);o=i.pop())n.line--,n.ch=0;o?(n.line--,n.ch=_e(e,n.line)):n.ch=0}}function Fe(e,t,n){t.ch=0,n.ch=0,n.line++}function je(e){if(!e)return 0;var t=e.search(/\S/);return-1==t?e.length:t}function Ue(e,{inclusive:n,innerWord:r,bigWord:i,noSymbol:o,multiline:a},s){var l,c=s||Be(e),u=e.getLine(c.line),d=u,h=c.line,m=h,g=c.ch,v=o?p[0]:f[0];if(r&&/\s/.test(u.charAt(g)))v=function(e){return/\s/.test(e)};else{while(!v(u.charAt(g)))if(g++,g>=u.length){if(!a)return null;g--,l=We(e,c,!0,i,!0);break}i?v=f[0]:(v=p[0],v(u.charAt(g))||(v=p[1]))}var b=g,y=g;while(v(u.charAt(y))&&y>=0)y--;if(y++,l)b=l.to,m=l.line,d=e.getLine(m),d||0!=b||b++;else while(v(u.charAt(b))&&b<u.length)b++;if(n){var w=b,O=c.ch<=y&&/\s/.test(u.charAt(c.ch));if(!O)while(/\s/.test(d.charAt(b))&&b<d.length)b++;if(w==b||O){var S=y;while(/\s/.test(u.charAt(y-1))&&y>0)y--;y||O||(y=S)}}return{start:new t(h,y),end:new t(m,b)}}function Ge(t,n,r){var i=n;if(!e.findMatchingTag||!e.findEnclosingTag)return{start:i,end:i};var o=e.findMatchingTag(t,n)||e.findEnclosingTag(t,n);return o&&o.open&&o.close?r?{start:o.open.from,end:o.close.to}:{start:o.open.to,end:o.close.from}:{start:i,end:i}}function He(e,t,n){we(t,n)||N.jumpList.add(e,t,n)}function qe(e,t){N.lastCharacterSearch.increment=e,N.lastCharacterSearch.forward=t.forward,N.lastCharacterSearch.selectedCharacter=t.selectedCharacter}var Qe={"(":"bracket",")":"bracket","{":"bracket","}":"bracket","[":"section","]":"section","*":"comment","/":"comment",m:"method",M:"method","#":"preprocess"},ze={bracket:{isComplete:function(e){if(e.nextCh===e.symb){if(e.depth++,e.depth>=1)return!0}else e.nextCh===e.reverseSymb&&e.depth--;return!1}},section:{init:function(e){e.curMoveThrough=!0,e.symb=(e.forward?"]":"[")===e.symb?"{":"}"},isComplete:function(e){return 0===e.index&&e.nextCh===e.symb}},comment:{isComplete:function(e){var t="*"===e.lastCh&&"/"===e.nextCh;return e.lastCh=e.nextCh,t}},method:{init:function(e){e.symb="m"===e.symb?"{":"}",e.reverseSymb="{"===e.symb?"}":"{"},isComplete:function(e){return e.nextCh===e.symb}},preprocess:{init:function(e){e.index=0},isComplete:function(e){if("#"===e.nextCh){var t=e.lineText.match(/^#(\w+)/)?.[1];if("endif"===t){if(e.forward&&0===e.depth)return!0;e.depth++}else if("if"===t){if(!e.forward&&0===e.depth)return!0;e.depth--}if("else"===t&&0===e.depth)return!0}return!1}}};function Ke(e,n,r,i){var o=ye(e.getCursor()),a=r?1:-1,s=r?e.lineCount():-1,l=o.ch,c=o.line,u=e.getLine(c),d={lineText:u,nextCh:u.charAt(l),lastCh:null,index:l,symb:i,reverseSymb:(r?{")":"(","}":"{"}:{"(":")","{":"}"})[i],forward:r,depth:0,curMoveThrough:!1},h=Qe[i];if(!h)return o;var p=ze[h].init,f=ze[h].isComplete;p&&p(d);while(c!==s&&n){if(d.index+=a,d.nextCh=d.lineText.charAt(d.index),!d.nextCh){if(c+=a,d.lineText=e.getLine(c)||"",a>0)d.index=0;else{var m=d.lineText.length;d.index=m>0?m-1:0}d.nextCh=d.lineText.charAt(d.index)}f(d)&&(o.line=c,o.ch=d.index,n--)}return d.nextCh||d.curMoveThrough?new t(c,d.index):o}function We(e,t,n,r,i){var o=t.line,a=t.ch,s=e.getLine(o),l=n?1:-1,c=r?f:p;if(i&&""==s){if(o+=l,s=e.getLine(o),!y(e,o))return null;a=n?0:s.length}while(1){if(i&&""==s)return{from:0,to:0,line:o};var u=l>0?s.length:-1,d=u,h=u;while(a!=u){for(var m=!1,g=0;g<c.length&&!m;++g)if(c[g](s.charAt(a))){d=a;while(a!=u&&c[g](s.charAt(a)))a+=l;if(h=a,m=d!=h,d==t.ch&&o==t.line&&h==d+l)continue;return{from:Math.min(d,h+1),to:Math.max(d,h),line:o}}m||(a+=l)}if(o+=l,!y(e,o))return null;s=e.getLine(o),a=l>0?0:s.length}}function Xe(e,n,r,i,o,a){var s=ye(n),l=[];(i&&!o||!i&&o)&&r++;for(var c=!(i&&o),u=0;u<r;u++){var d=We(e,n,i,a,c);if(!d){var h=_e(e,e.lastLine());l.push(i?{line:e.lastLine(),from:h,to:h}:{line:0,from:0,to:0});break}l.push(d),n=new t(d.line,i?d.to-1:d.from)}var p=l.length!=r,f=l[0],m=l.pop();return i&&!o?(p||f.from==s.ch&&f.line==s.line||(m=l.pop()),m&&new t(m.line,m.from)):i&&o?m&&new t(m.line,m.to-1):!i&&o?(p||f.to==s.ch&&f.line==s.line||(m=l.pop()),m&&new t(m.line,m.to)):m&&new t(m.line,m.from)}function Ye(e,n,r,i,o){var a=n,s=new t(a.line+r.repeat-1,1/0),l=e.clipPos(s);return l.ch--,o||(i.lastHPos=1/0,i.lastHSPos=e.charCoords(l,"div").left),s}function Ze(e,n,r,i,o){if(i){for(var a,s=o||e.getCursor(),l=s.ch,c=0;c<n;c++){var u=e.getLine(s.line);if(a=tt(l,u,i,r,!0),-1==a)return;l=a}return void 0!=a?new t(e.getCursor().line,a):void 0}}function Je(e,n){var r=e.getCursor().line;return he(e,new t(r,n-1))}function et(e,t,n,r){(k(n,m)||v.test(n))&&(t.marks[n]&&t.marks[n].clear(),t.marks[n]=e.setBookmark(r))}function tt(e,t,n,r,i){var o;return r?(o=t.indexOf(n,e+1),-1==o||i||(o-=1)):(o=t.lastIndexOf(n,e-1),-1==o||i||(o+=1)),o}function nt(e,n,r,i,o){var a,s,l=n.line,c=e.firstLine(),u=e.lastLine(),d=l;function h(t){return!e.getLine(t)}function p(e,t,n){return n?h(e)!=h(e+t):!h(e)&&h(e+t)}if(i){while(c<=d&&d<=u&&r>0)p(d,i)&&r--,d+=i;return{start:new t(d,0),end:n}}var f=e.state.vim;if(f.visualLine&&p(l,1,!0)){var m=f.sel.anchor;p(m.line,-1,!0)&&(o&&m.line==l||(l+=1))}var g=h(l);for(d=l;d<=u&&r;d++)p(d,1,!0)&&(o&&h(d)==g||r--);for(s=new t(d,0),d>u&&!g?g=!0:o=!1,d=l;d>c;d--)if((!o||h(d)==g||d==l)&&p(d,-1,!0))break;return a=new t(d,0),{start:a,end:s}}function rt(e,n,r,i,o){function a(e){null!==e.line&&(e.pos+e.dir<0||e.pos+e.dir>=e.line.length?e.line=null:e.pos+=e.dir)}function s(e,t,n,r){var i=e.getLine(t),s={line:i,ln:t,pos:n,dir:r};if(""===s.line)return{ln:s.ln,pos:s.pos};var l=s.pos;a(s);while(null!==s.line){if(l=s.pos,_(s.line[s.pos])){if(o){a(s);while(null!==s.line){if(!x(s.line[s.pos]))break;l=s.pos,a(s)}return{ln:s.ln,pos:l+1}}return{ln:s.ln,pos:s.pos+1}}a(s)}return{ln:s.ln,pos:l+1}}function l(e,t,n,r){var i=e.getLine(t),s={line:i,ln:t,pos:n,dir:r};if(""===s.line)return{ln:s.ln,pos:s.pos};var l=s.pos;a(s);while(null!==s.line){if(x(s.line[s.pos])||_(s.line[s.pos])){if(_(s.line[s.pos]))return o&&x(s.line[s.pos+1])?{ln:s.ln,pos:s.pos+1}:{ln:s.ln,pos:l}}else l=s.pos;a(s)}return s.line=i,o&&x(s.line[s.pos])?{ln:s.ln,pos:s.pos}:{ln:s.ln,pos:l}}var c={ln:n.line,pos:n.ch};while(r>0)c=i<0?l(e,c.ln,c.pos,i):s(e,c.ln,c.pos,i),r--;return new t(c.ln,c.pos)}function it(e,n,r,i){function o(e,t){if(null!==t.line)if(t.pos+t.dir<0||t.pos+t.dir>=t.line.length){if(t.ln+=t.dir,!y(e,t.ln))return void(t.line=null);t.line=e.getLine(t.ln),t.pos=t.dir>0?0:t.line.length-1}else t.pos+=t.dir}function a(e,t,n,r){var i=e.getLine(t),a=""===i,s={line:i,ln:t,pos:n,dir:r},l={ln:s.ln,pos:s.pos},c=""===s.line;o(e,s);while(null!==s.line){if(l.ln=s.ln,l.pos=s.pos,""===s.line&&!c)return{ln:s.ln,pos:s.pos};if(a&&""!==s.line&&!x(s.line[s.pos]))return{ln:s.ln,pos:s.pos};!_(s.line[s.pos])||a||s.pos!==s.line.length-1&&!x(s.line[s.pos+1])||(a=!0),o(e,s)}i=e.getLine(l.ln);l.pos=0;for(var u=i.length-1;u>=0;--u)if(!x(i[u])){l.pos=u;break}return l}function s(e,t,n,r){var i=e.getLine(t),a={line:i,ln:t,pos:n,dir:r},s=a.ln,l=null,c=""===a.line;o(e,a);while(null!==a.line){if(""===a.line&&!c)return null!==l?{ln:s,pos:l}:{ln:a.ln,pos:a.pos};if(_(a.line[a.pos])&&null!==l&&(a.ln!==s||a.pos+1!==l))return{ln:s,pos:l};""===a.line||x(a.line[a.pos])||(c=!1,s=a.ln,l=a.pos),o(e,a)}i=e.getLine(s);l=0;for(var u=0;u<i.length;++u)if(!x(i[u])){l=u;break}return{ln:s,pos:l}}var l={ln:n.line,pos:n.ch};while(r>0)l=i<0?s(e,l.ln,l.pos,i):a(e,l.ln,l.pos,i),r--;return new t(l.ln,l.pos)}function ot(e,n,r,i){var o=n,a={"(":/[()]/,")":/[()]/,"[":/[[\]]/,"]":/[[\]]/,"{":/[{}]/,"}":/[{}]/,"<":/[<>]/,">":/[<>]/}[r],s={"(":"(",")":"(","[":"[","]":"[","{":"{","}":"{","<":"<",">":"<"}[r],l=e.getLine(o.line).charAt(o.ch),c=l===s?1:0,u=e.scanForBracket(new t(o.line,o.ch+c),-1,void 0,{bracketRegex:a}),d=e.scanForBracket(new t(o.line,o.ch+c),1,void 0,{bracketRegex:a});if(!u||!d)return null;var h=u.pos,p=d.pos;if(h.line==p.line&&h.ch>p.ch||h.line>p.line){var f=h;h=p,p=f}return i?p.ch+=1:h.ch+=1,{start:h,end:p}}function at(e,n,r,i){var o,a,s,l,c=ye(n),u=e.getLine(c.line),d=u.split(""),h=d.indexOf(r);if(c.ch<h)c.ch=h;else if(h<c.ch&&d[c.ch]==r){var p=/string/.test(e.getTokenTypeAt(fe(n,0,1))),f=/string/.test(e.getTokenTypeAt(n)),m=p&&!f;m||(a=c.ch,--c.ch)}if(d[c.ch]!=r||a)for(s=c.ch;s>-1&&!o;s--)d[s]==r&&(o=s+1);else o=c.ch+1;if(o&&!a)for(s=o,l=d.length;s<l&&!a;s++)d[s]==r&&(a=s);return o&&a?(i&&(--o,++a),{start:new t(c.line,o),end:new t(c.line,a)}):{start:c,end:c}}A("pcre",!0,"boolean");class st{constructor(){this.highlightTimeout}getQuery(){return N.query}setQuery(e){N.query=e}getOverlay(){return this.searchOverlay}setOverlay(e){this.searchOverlay=e}isReversed(){return N.isReversed}setReversed(e){N.isReversed=e}getScrollbarAnnotate(){return this.annotate}setScrollbarAnnotate(e){this.annotate=e}}function lt(e){var t=e.state.vim;return t.searchState_||(t.searchState_=new st)}function ct(e){return dt(e,"/")}function ut(e){return ht(e,"/")}function dt(e,t){var n=ht(e,t)||[];if(!n.length)return[];var r=[];if(0===n[0]){for(var i=0;i<n.length;i++)"number"==typeof n[i]&&r.push(e.substring(n[i]+1,n[i+1]));return r}}function ht(e,t){t||(t="/");for(var n=!1,r=[],i=0;i<e.length;i++){var o=e.charAt(i);n||o!=t||r.push(i),n=!n&&"\\"==o}return r}function pt(e){var t={V:"|(){+?*.[$^",M:"|(){+?*.[",m:"|(){+?",v:"<>"},n={">":"(?<=[\\w])(?=[^\\w]|$)","<":"(?<=[^\\w]|^)(?=[\\w])"},r=t.m,i=e.replace(/\\.|[\[|(){+*?.$^<>]/g,function(e){if("\\"===e[0]){var i=e[1];return"}"===i||-1!=r.indexOf(i)?i:i in t?(r=t[i],""):i in n?n[i]:e}return-1!=r.indexOf(e)?n[e]||"\\"+e:e}),o=i.indexOf("\\zs");return-1!=o&&(i="(?<="+i.slice(0,o)+")"+i.slice(o+3)),o=i.indexOf("\\ze"),-1!=o&&(i=i.slice(0,o)+"(?="+i.slice(o+3)+")"),i}var ft={"\\n":"\n","\\r":"\r","\\t":"\t"};function mt(e){for(var t=!1,n=[],r=-1;r<e.length;r++){var i=e.charAt(r)||"",o=e.charAt(r+1)||"";ft[i+o]?(n.push(ft[i+o]),r++):t?(n.push(i),t=!1):"\\"===i?(t=!0,S(o)||"$"===o?n.push("$"):"/"!==o&&"\\"!==o&&n.push("\\")):("$"===i&&n.push("$"),n.push(i),"/"===o&&n.push("\\"))}return n.join("")}var gt={"\\/":"/","\\\\":"\\","\\n":"\n","\\r":"\r","\\t":"\t","\\&":"&"};function vt(t){var n=new e.StringStream(t),r=[];while(!n.eol()){while(n.peek()&&"\\"!=n.peek())r.push(n.next());var i=!1;for(var o in gt)if(n.match(o,!0)){i=!0,r.push(gt[o]);break}i||r.push(n.next())}return r.join("")}function bt(e,t,n){var r=N.registerController.getRegister("/");r.setText(e);var i,o,a=ut(e);if(a.length){i=e.substring(0,a[0]);var s=e.substring(a[0]);o=-1!=s.indexOf("i")}else i=e;if(!i)return null;R("pcre")||(i=pt(i)),n&&(t=/^[^A-Z]*$/.test(i));var l=new RegExp(i,t||o?"im":"m");return l}function yt(e){"string"===typeof e&&(e=document.createElement(e));for(var t=1;t<arguments.length;t++){var n=arguments[t];if(n)if("object"!==typeof n&&(n=document.createTextNode(n)),n.nodeType)e.appendChild(n);else for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&("$"===r[0]?e.style[r.slice(1)]=n[r]:"function"==typeof n[r]?e[r]=n[r]:e.setAttribute(r,n[r]))}return e}function wt(e,t,n,r){var i=yt("div",{$color:"red",$whiteSpace:"pre",class:"cm-vim-message"},t);e.openNotification?n?(i=yt("div",{},i,yt("div",{},"Press ENTER or type command to continue")),e.state.closeVimNotification&&e.state.closeVimNotification(),e.state.closeVimNotification=e.openNotification(i,{bottom:!0,duration:0})):e.openNotification(i,{bottom:!0,duration:r||15e3}):r||alert(i.innerText)}function Ot(e,t){return yt("div",{$display:"flex",$flex:1},yt("span",{$fontFamily:"monospace",$whiteSpace:"pre",$flex:1,$display:"flex"},e,yt("input",{type:"text",autocorrect:"off",autocapitalize:"off",spellcheck:"false",$flex:1})),t&&yt("span",{$color:"#888"},t))}function St(e,t){if(j.length)return t.value||(t.value=""),void(V=t);var n=Ot(t.prefix,t.desc);if(e.openDialog)e.openDialog(n,t.onClose,{onKeyDown:t.onKeyDown,onKeyUp:t.onKeyUp,bottom:!0,selectValueOnOpen:!1,value:t.value});else{var r="";"string"!=typeof t.prefix&&t.prefix&&(r+=t.prefix.textContent),t.desc&&(r+=" "+t.desc),t.onClose?.(prompt(r,""))}}function Et(e,t){return e instanceof RegExp&&t instanceof RegExp&&(e.flags==t.flags&&e.source==t.source)}function xt(e,t,n,r){if(t){var i=lt(e),o=bt(t,!!n,!!r);if(o)return Ct(e,o),Et(o,i.getQuery())||i.setQuery(o),o}}function _t(e){if("^"==e.source.charAt(0))var t=!0;return{token:function(n){if(!t||n.sol()){var r=n.match(e,!1);if(r)return 0==r[0].length?(n.next(),"searching"):n.sol()||(n.backUp(1),e.exec(n.next()+r[0]))?(n.match(e),"searching"):(n.next(),null);while(!n.eol())if(n.next(),n.match(e,!1))break}else n.skipToEnd()},query:e}}var kt=0;function Ct(e,t){clearTimeout(kt);var n=lt(e);n.highlightTimeout=kt,kt=setTimeout(function(){if(e.state.vim){var n=lt(e);n.highlightTimeout=void 0;var r=n.getOverlay();r&&t==r.query||(r&&e.removeOverlay(r),r=_t(t),e.addOverlay(r),e.showMatchesOnScrollbar&&(n.getScrollbarAnnotate()&&n.getScrollbarAnnotate().clear(),n.setScrollbarAnnotate(e.showMatchesOnScrollbar(t))),n.setOverlay(r))}},50)}function At(e,n,r,i){return e.operation(function(){void 0===i&&(i=1);for(var o=e.getCursor(),a=e.getSearchCursor(r,o),s=0;s<i;s++){var l=a.find(n);if(0==s&&l&&we(a.from(),o)){var c=n?a.from():a.to();l=a.find(n),l&&!l[0]&&we(a.from(),c)&&e.getLine(c.line).length==c.ch&&(l=a.find(n))}if(!l&&(a=e.getSearchCursor(r,n?new t(e.lastLine()):new t(e.firstLine(),0)),!a.find(n)))return}return a.from()})}function Tt(e,n,r,i,o){return e.operation(function(){void 0===i&&(i=1);var a=e.getCursor(),s=e.getSearchCursor(r,a),l=s.find(!n);!o.visualMode&&l&&we(s.from(),a)&&s.find(!n);for(var c=0;c<i;c++)if(l=s.find(n),!l&&(s=e.getSearchCursor(r,n?new t(e.lastLine()):new t(e.firstLine(),0)),!s.find(n)))return;var u=s.from(),d=s.to();return u&&d&&[u,d]})}function Rt(e){var t=lt(e);t.highlightTimeout&&(clearTimeout(t.highlightTimeout),t.highlightTimeout=void 0),e.removeOverlay(lt(e).getOverlay()),t.setOverlay(null),t.getScrollbarAnnotate()&&(t.getScrollbarAnnotate().clear(),t.setScrollbarAnnotate(null))}function Nt(e,t,n){return"number"!=typeof e&&(e=e.line),t instanceof Array?k(e,t):"number"==typeof n?e>=t&&e<=n:e==t}function Pt(e){var t=e.getScrollInfo(),n=6,r=10,i=e.coordsChar({left:0,top:n+t.top},"local"),o=t.clientHeight-r+t.top,a=e.coordsChar({left:0,top:o},"local");return{top:i.line,bottom:a.line}}function It(e,n,r){if("'"==r||"`"==r)return N.jumpList.find(e,-1)||new t(0,0);if("."==r)return Mt(e);var i=n.marks[r];return i&&i.find()}function Mt(e){if(e.getLastEditEnd)return e.getLastEditEnd();for(var t=e.doc.history.done,n=t.length;n--;)if(t[n].changes)return ye(t[n].changes[0].to)}class Dt{constructor(){this.commandMap_,this.buildCommandMap_()}processCommand(e,t,n){var r=this;e.operation(function(){e.curOp&&(e.curOp.isVimOp=!0),r._processCommand(e,t,n)})}_processCommand(t,n,r){var i=t.state.vim,o=N.registerController.getRegister(":"),a=o.toString(),s=new e.StringStream(n);o.setText(n);var l,c,u=r||{};u.input=n;try{this.parseInput_(t,s,u)}catch(d){return void wt(t,d+"")}if(i.visualMode&&$e(t),u.commandName){if(l=this.matchCommand_(u.commandName),l){if(c=l.name,l.excludeFromCommandHistory&&o.setText(a),this.parseCommandArgs_(s,u,l),"exToKey"==l.type)return void H(t,l.toKeys||"",l);if("exToEx"==l.type)return void this.processCommand(t,l.toInput||"")}}else void 0!==u.line&&(c="move");if(c)try{Lt[c](t,u),l&&l.possiblyAsync||!u.callback||u.callback()}catch(d){throw wt(t,d+""),d}else wt(t,'Not an editor command ":'+n+'"')}parseInput_(e,t,n){if(t.eatWhile(":"),t.eat("%"))n.line=e.firstLine(),n.lineEnd=e.lastLine();else if(t.eat("*")){var r=e.state.vim.lastSelection,i=r?.anchorMark.find()?.line||0,o=r?.headMark.find()?.line||0;n.line=Math.max(i,o),n.lineEnd=Math.min(i,o)}else n.line=this.parseLineSpec_(e,t),void 0!==n.line&&t.eat(",")&&(n.lineEnd=this.parseLineSpec_(e,t));void 0==n.line?e.state.vim.visualMode?(n.selectionLine=It(e,e.state.vim,"<")?.line,n.selectionLineEnd=It(e,e.state.vim,">")?.line):n.selectionLine=e.getCursor().line:(n.selectionLine=n.line,n.selectionLineEnd=n.lineEnd),t.eatSpace();var a=t.match(/^(\w+|!!|@@|[!#&*<=>@~])/);return n.commandName=a?a[1]:(t.match(/.*/)||[""])[0],n}parseLineSpec_(e,t){var n=t.match(/^([\d]+)/);if(n)return this.parseLineSpecOffset_(e,t,parseInt(n[1],10)-1);switch(t.next()){case".":return this.parseLineSpecOffset_(e,t,e.getCursor().line);case"$":return this.parseLineSpecOffset_(e,t,e.lastLine());case"'":var r=t.next()||"",i=It(e,e.state.vim,r);if(!i)throw new Error("Mark not set");return this.parseLineSpecOffset_(e,t,i.line);case"-":case"+":case"/":case"?":return t.backUp(1),this.parseLineSpecOffset_(e,t,e.getCursor().line);default:return void t.backUp(1)}}parseLineSpecOffset_(e,n,r){while(1){var i=n.match(/^([\/\?]|\\[\?\/])|([+-]?)(\d*)/);if(!i||!i[0])break;if(i[1]){var o="",a=!i[1].endsWith("?");if(1==i[1].length){var s=n.match(a?/^([^\/\\]|\\\/)*/:/^([^\/\?]|\\\?)*/);n.match(a?/^\/?/:/^\??/),o=s&&s[0]}o||(o=N.registerController.getRegister("/")?.toString()||"");var l=new RegExp(o),c=e.getSearchCursor(l,new t(r+(a?1:0),0));a?c.findNext():c.findPrevious();var u=c.from();if(!u)throw new Error("Pattern not found"+l);r=u.line}else{var d=parseInt(i[2]+(i[3]||"1"),10);r+=d}}return r}parseCommandArgs_(e,t,n){if(!e.eol()){t.argString=e.match(/.*/)?.[0];var r=n.argDelimiter||/\s+/,i=ke(t.argString||"").split(r);i.length&&i[0]&&(t.args=i)}}matchCommand_(e){for(var t=e.length;t>0;t--){var n=e.substring(0,t);if(this.commandMap_[n]){var r=this.commandMap_[n];if(0===r.name.indexOf(e))return r}}}buildCommandMap_(){this.commandMap_={};for(var e=0;e<s.length;e++){var t=s[e],n=t.shortName||t.name;this.commandMap_[n]=t}}map(e,t,n,r){if(":"!=e&&":"==e.charAt(0)){if(n)throw Error("Mode not supported for ex mappings");var i=e.substring(1);":"!=t&&":"==t.charAt(0)?this.commandMap_[i]={name:i,type:"exToEx",toInput:t.substring(1),user:!0}:this.commandMap_[i]={name:i,type:"exToKey",toKeys:t,user:!0}}else{var o={keys:e,type:"keyToKey",toKeys:t,noremap:!!r};n&&(o.context=n),Ft(o)}}unmap(e,t){if(":"!=e&&":"==e.charAt(0)){if(t)throw Error("Mode not supported for ex mappings");var n=e.substring(1);if(this.commandMap_[n]&&this.commandMap_[n].user)return delete this.commandMap_[n],!0}else for(var r=e,o=0;o<i.length;o++)if(r==i[o].keys&&i[o].context===t)return i.splice(o,1),Ut(r),!0}}var Lt={colorscheme:function(e,t){!t.args||t.args.length<1?wt(e,e.getOption("theme")):e.setOption("theme",t.args[0])},map:function(e,t,n,r){var i=t.args;!i||i.length<2?e&&wt(e,"Invalid mapping: "+t.input):Bt.map(i[0],i[1],n,r)},imap:function(e,t){this.map(e,t,"insert")},nmap:function(e,t){this.map(e,t,"normal")},vmap:function(e,t){this.map(e,t,"visual")},omap:function(e,t){this.map(e,t,"operatorPending")},noremap:function(e,t){this.map(e,t,void 0,!0)},inoremap:function(e,t){this.map(e,t,"insert",!0)},nnoremap:function(e,t){this.map(e,t,"normal",!0)},vnoremap:function(e,t){this.map(e,t,"visual",!0)},onoremap:function(e,t){this.map(e,t,"operatorPending",!0)},unmap:function(e,t,n){var r=t.args;(!r||r.length<1||!Bt.unmap(r[0],n))&&e&&wt(e,"No such mapping: "+t.input)},mapclear:function(e,t){F.mapclear()},imapclear:function(e,t){F.mapclear("insert")},nmapclear:function(e,t){F.mapclear("normal")},vmapclear:function(e,t){F.mapclear("visual")},omapclear:function(e,t){F.mapclear("operatorPending")},move:function(e,t){ie.processCommand(e,e.state.vim,{keys:"",type:"motion",motion:"moveToLineOrEdgeOfDocument",motionArgs:{forward:!1,explicitRepeat:!0,linewise:!0},repeatOverride:t.line+1})},set:function(e,t){var n=t.args,r=t.setCfg||{};if(!n||n.length<1)e&&wt(e,"Invalid mapping: "+t.input);else{var i=n[0].split("="),o=i.shift()||"",a=i.length>0?i.join("="):void 0,s=!1,l=!1;if("?"==o.charAt(o.length-1)){if(a)throw Error("Trailing characters: "+t.argString);o=o.substring(0,o.length-1),s=!0}else"!"==o.charAt(o.length-1)&&(o=o.substring(0,o.length-1),l=!0);void 0===a&&"no"==o.substring(0,2)&&(o=o.substring(2),a=!1);var c=C[o]&&"boolean"==C[o].type;if(c&&(l?a=!R(o,e,r):void 0==a&&(a=!0)),!c&&void 0===a||s){var u=R(o,e,r);u instanceof Error?wt(e,u.message):wt(e,!0===u||!1===u?" "+(u?"":"no")+o:" "+o+"="+u)}else{var d=T(o,a,e,r);d instanceof Error&&wt(e,d.message)}}},setlocal:function(e,t){t.setCfg={scope:"local"},this.set(e,t)},setglobal:function(e,t){t.setCfg={scope:"global"},this.set(e,t)},registers:function(e,t){var n=t.args,r=N.registerController.registers,i="----------Registers----------\n\n";if(n)for(var o=n.join(""),a=0;a<o.length;a++){l=o.charAt(a);if(N.registerController.isValidRegister(l)){var s=r[l]||new ee;i+='"'+l+" "+s.toString()+"\n"}}else for(var l in r){var c=r[l].toString();c.length&&(i+='"'+l+" "+c+"\n")}wt(e,i,!0)},marks:function(e,t){var n=t.args,r=e.state.vim.marks,i="-----------Marks-----------\nmark\tline\tcol\n\n";if(n)for(var o=n.join(""),a=0;a<o.length;a++){s=o.charAt(a),l=r[s]&&r[s].find();l&&(i+=s+"\t"+l.line+"\t"+l.ch+"\n")}else for(var s in r){var l=r[s]&&r[s].find();l&&(i+=s+"\t"+l.line+"\t"+l.ch+"\n")}wt(e,i,!0)},sort:function(n,r){var i,o,a,s,l,c;function u(){if(r.argString){var t=new e.StringStream(r.argString);if(t.eat("!")&&(i=!0),t.eol())return;if(!t.eatSpace())return"Invalid arguments";var n=t.match(/([dinuoxr]+)?\s*(\/.+\/)?\s*/);if(!n||!t.eol())return"Invalid arguments";if(n[1]){c=-1!=n[1].indexOf("r"),o=-1!=n[1].indexOf("i"),a=-1!=n[1].indexOf("u");var u=-1!=n[1].indexOf("d")||-1!=n[1].indexOf("n"),d=-1!=n[1].indexOf("x"),h=-1!=n[1].indexOf("o");if(Number(u)+Number(d)+Number(h)>1)return"Invalid arguments";s=(u?"decimal":d&&"hex")||h&&"octal"}n[2]&&(l=new RegExp(n[2].substr(1,n[2].length-2),o?"i":""))}}var d=u();if(d)wt(n,d+": "+r.argString);else{var h=r.line||n.firstLine(),p=r.lineEnd||r.line||n.lastLine();if(h!=p){var f=new t(h,0),m=new t(p,_e(n,p)),g=n.getRange(f,m).split("\n"),v="decimal"==s?/(-?)([\d]+)/:"hex"==s?/(-?)(?:0x)?([0-9a-f]+)/i:"octal"==s?/([0-7]+)/:null,b="decimal"==s?10:"hex"==s?16:"octal"==s?8:void 0,y=[],w=[];if(s||l)for(var O=0;O<g.length;O++){var S=l?g[O].match(l):null;S&&null!=S.index&&!c&&(S[0]=g[O].slice(S.index+S[0].length)),S&&""!=S[0]?y.push(S):v&&v.exec(g[O])?y.push(g[O]):w.push(g[O])}else w=g;if(y.sort(l?k:_),l)for(O=0;O<y.length;O++)y[O]=y[O].input;else s||w.sort(_);if(g=i?y.concat(w):w.concat(y),a){var E,x=g;g=[];for(O=0;O<x.length;O++)x[O]!=E&&g.push(x[O]),E=x[O]}n.replaceRange(g.join("\n"),f,m)}}function _(e,t){var n;i&&(n=e,e=t,t=n);o&&(e=e.toLowerCase(),t=t.toLowerCase());var r=v&&v.exec(e),a=v&&v.exec(t);if(!r||!a)return e<t?-1:1;var s=parseInt((r[1]+r[2]).toLowerCase(),b),l=parseInt((a[1]+a[2]).toLowerCase(),b);return s-l}function k(e,t){var n;i&&(n=e,e=t,t=n);return o&&(e[0]=e[0].toLowerCase(),t[0]=t[0].toLowerCase()),e[0]<t[0]?-1:1}},vglobal:function(e,t){this.global(e,t)},normal:function(e,t){var n=!1,r=t.argString;if(r&&"!"==r[0]&&(r=r.slice(1),n=!0),r=r.trimStart(),r){var i=t.line;if("number"==typeof i)for(var o=isNaN(t.lineEnd)?i:t.lineEnd,a=i;a<=o;a++)e.setCursor(a,0),H(e,t.argString.trimStart(),{noremap:n}),e.state.vim.insertMode&&Vt(e,!0);else H(e,t.argString.trimStart(),{noremap:n}),e.state.vim.insertMode&&Vt(e,!0)}else wt(e,"Argument is required.")},global:function(e,t){var n=t.argString;if(n){var r="v"===t.commandName[0];"!"===n[0]&&"g"===t.commandName[0]&&(r=!0,n=n.slice(1));var i=void 0!==t.line?t.line:e.firstLine(),o=t.lineEnd||t.line||e.lastLine(),a=ct(n),s=n,l="";if(a&&a.length&&(s=a[0],l=a.slice(1,a.length).join("/")),s)try{xt(e,s,!0,!0)}catch(g){return void wt(e,"Invalid regex: "+s)}for(var c=lt(e).getQuery(),u=[],d=i;d<=o;d++){var h=e.getLine(d),p=c.test(h);p!==r&&u.push(l?e.getLineHandle(d):h)}if(l){var f=0,m=function(){if(f<u.length){var t=u[f++],n=e.getLineNumber(t);if(null==n)return void m();var r=n+1+l;Bt.processCommand(e,r,{callback:m})}else e.releaseLineHandles&&e.releaseLineHandles()};m()}else wt(e,u.join("\n"))}else wt(e,"Regular Expression missing from global")},substitute:function(e,n){if(!e.getSearchCursor)throw new Error("Search feature not available. Requires searchcursor.js or any other getSearchCursor implementation.");var r,i,o,a=n.argString,s=a?dt(a,a[0]):[],l="",c="",u=!1,d=!1;if(s&&s.length)l=s[0],R("pcre")&&""!==l&&(l=new RegExp(l).source),c=s[1],void 0!==c&&(c=R("pcre")?vt(c.replace(/([^\\])&/g,"$1$$&")):mt(c),N.lastSubstituteReplacePart=c),r=s[2]?s[2].split(" "):[];else if(a&&a.length)return void wt(e,"Substitutions should be of the form :s/pattern/replace/");if(r&&(i=r[0],o=parseInt(r[1]),i&&(-1!=i.indexOf("c")&&(u=!0),-1!=i.indexOf("g")&&(d=!0),l=R("pcre")?l+"/"+i:l.replace(/\//g,"\\/")+"/"+i)),l)try{xt(e,l,!0,!0)}catch(b){return void wt(e,"Invalid regex: "+l)}if(c=c||N.lastSubstituteReplacePart,void 0!==c){var h=lt(e),p=h.getQuery(),f=void 0!==n.line?n.line:e.getCursor().line,m=n.lineEnd||f;f==e.firstLine()&&m==e.lastLine()&&(m=1/0),o&&(f=m,m=f+o-1);var g=he(e,new t(f,0)),v=e.getSearchCursor(p,g);$t(e,u,d,f,m,v,p,c,n.callback)}else wt(e,"No previous substitute regular expression")},startinsert:function(e,t){H(e,"!"==t.argString?"A":"i",{})},redo:e.commands.redo,undo:e.commands.undo,write:function(t){e.commands.save?e.commands.save(t):t.save&&t.save()},nohlsearch:function(e){Rt(e)},yank:function(e,n){var r=n.selectionLine,i=isNaN(n.selectionLineEnd)?r:n.selectionLineEnd;if(i<r){var o=i;i=r,r=o}var a=e.getRange(new t(r,0),new t(i+1,0)),s=n.args&&n.args[0]?n.args[0]:"0";N.registerController.pushText(s,"yank",a,!0,!1),wt(e,i+1-r+" lines yanked"+(s?' into "'+s:""),!1,1500)},put:function(e,n,r){var i={after:!0,isEdit:!0,matchIndent:!!r,repeat:1,lineWise:!0,registerName:""},o=n.args||[];"!"==o[0]&&(i.after=!1,o.shift()),o[0]&&(i.registerName=o[0]);var a=n.selectionLine;void 0!=a&&e.setCursor(new t(a,0)),ue.paste(e,i,e.state.vim)},iput:function(e,t){this.put(e,t,!0)},delete:function(e,n){var r=n.selectionLine,i=isNaN(n.selectionLineEnd)?r:n.selectionLineEnd;le.delete(e,{linewise:!0},[{anchor:new t(r,0),head:new t(i+1,0)}])},join:function(e,n){var r=n.selectionLine,i=isNaN(n.selectionLineEnd)?r:n.selectionLineEnd;e.setCursor(new t(r,0)),ue.joinLines(e,{repeat:i-r},e.state.vim)},delmarks:function(t,n){if(n.argString&&ke(n.argString)){var r=t.state.vim,i=new e.StringStream(ke(n.argString));while(!i.eol()){i.eatSpace();var o=i.pos;if(!i.match(/[a-zA-Z]/,!1))return void wt(t,"Invalid argument: "+n.argString.substring(o));var a=i.next();if(i.match("-",!0)){if(!i.match(/[a-zA-Z]/,!1))return void wt(t,"Invalid argument: "+n.argString.substring(o));var s=a,l=i.next();if(!s||!l||w(s)!=w(l))return void wt(t,"Invalid argument: "+s+"-");var c=s.charCodeAt(0),u=l.charCodeAt(0);if(c>=u)return void wt(t,"Invalid argument: "+n.argString.substring(o));for(var d=0;d<=u-c;d++){var h=String.fromCharCode(c+d);delete r.marks[h]}}else a&&delete r.marks[a]}}else wt(t,"Argument required")}},Bt=new Dt;function $t(t,n,r,i,o,a,s,l,c){t.state.vim.exMode=!0;var u,d,h,p=!1,f=0;function m(){t.operation(function(){while(!p)g(),b();y()})}function g(){var e="",n=a.match||a.pos&&a.pos.match;if(n)e=l.replace(/\$(\d{1,3}|[$&])/g,function(e,t){if("$"==t)return"$";if("&"==t)return n[0];var r=t;while(parseInt(r)>=n.length&&r.length>0)r=r.slice(0,r.length-1);return r?n[r]+t.slice(r.length,t.length):e});else{var r=t.getRange(a.from(),a.to());e=r.replace(s,l)}var i=a.to().line;a.replace(e),d=a.to().line,o+=d-i,h=d<i}function v(){var e=u&&ye(a.to()),t=a.findNext();return t&&!t[0]&&e&&we(a.from(),e)&&(t=a.findNext()),t&&f++,t}function b(){while(v()&&Nt(a.from(),i,o))if(r||a.from().line!=d||h)return t.scrollIntoView(a.from(),30),t.setSelection(a.from(),a.to()),u=a.from(),void(p=!1);p=!0}function y(e){if(e&&e(),t.focus(),u){t.setCursor(u);var n=t.state.vim;n.exMode=!1,n.lastHPos=n.lastHSPos=u.ch}c?c():p&&wt(t,(f?"Found "+f+" matches":"No matches found")+" for pattern: "+s+(R("pcre")?" (set nopcre to use Vim regexps)":""))}function w(n,r,i){e.e_stop(n);var o=K(n);switch(o){case"y":g(),b();break;case"n":b();break;case"a":var a=c;c=void 0,t.operation(m),c=a;break;case"l":g();case"q":case"<Esc>":case"<C-c>":case"<C-[>":y(i);break}return p&&y(i),!0}if(b(),!p)return n?void St(t,{prefix:yt("span","replace with ",yt("strong",l)," (y/n/a/q/l)"),onKeyDown:w}):(m(),void(c&&c()));wt(t,"No matches for "+s+(R("pcre")?" (set nopcre to use vim regexps)":""))}function Vt(t,n){var r=t.state.vim,i=N.macroModeState,o=N.registerController.getRegister("."),a=i.isPlaying,s=i.lastInsertModeChanges;a||(t.off("change",Kt),r.insertEnd&&r.insertEnd.clear(),r.insertEnd=void 0,e.off(t.getInputField(),"keydown",Yt)),!a&&r.insertModeRepeat&&r.insertModeRepeat>1&&(Zt(t,r,r.insertModeRepeat-1,!0),r.lastEditInputState.repeatOverride=r.insertModeRepeat),delete r.insertModeRepeat,r.insertMode=!1,n||t.setCursor(t.getCursor().line,t.getCursor().ch-1),t.setOption("keyMap","vim"),t.setOption("disableInput",!0),t.toggleOverwrite(!1),o.setText(s.changes.join("")),e.signal(t,"vim-mode-change",{mode:"normal"}),i.isRecording&&Qt(i)}function Ft(e){i.unshift(e),e.keys&&jt(e.keys)}function jt(e){e.split(/(<(?:[CSMA]-)*\w+>|.)/i).forEach(function(e){e&&(o[e]||(o[e]=0),o[e]++)})}function Ut(e){e.split(/(<(?:[CSMA]-)*\w+>|.)/i).forEach(function(e){o[e]&&o[e]--})}function Gt(e,t,n,r,i){var o={keys:e,type:t};for(var a in o[t]=n,o[t+"Args"]=r,i)o[a]=i[a];Ft(o)}function Ht(e,t,n,r){var i=N.registerController.getRegister(r);if(":"==r)return i.keyBuffer[0]&&Bt.processCommand(e,i.keyBuffer[0]),void(n.isPlaying=!1);var o=i.keyBuffer,a=0;n.isPlaying=!0,n.replaySearchQueries=i.searchQueries.slice(0);for(var s=0;s<o.length;s++){var l,c,u=o[s],d=/<(?:[CSMA]-)*\w+>|./gi;while(l=d.exec(u))if(c=l[0],F.handleKey(e,c,"macro"),t.insertMode){var h=i.insertModeChanges[a++].changes;N.macroModeState.lastInsertModeChanges.changes=h,en(e,h,1),Vt(e)}}n.isPlaying=!1}function qt(e,t){if(!e.isPlaying){var n=e.latestRegister,r=N.registerController.getRegister(n);r&&r.pushText(t)}}function Qt(e){if(!e.isPlaying){var t=e.latestRegister,n=N.registerController.getRegister(t);n&&n.pushInsertModeChanges&&n.pushInsertModeChanges(e.lastInsertModeChanges)}}function zt(e,t){if(!e.isPlaying){var n=e.latestRegister,r=N.registerController.getRegister(n);r&&r.pushSearchQuery&&r.pushSearchQuery(t)}}function Kt(e,t){var n=N.macroModeState,r=n.lastInsertModeChanges;if(!n.isPlaying){var i=e.state.vim;while(t){if(r.expectCursorActivityForChange=!0,r.ignoreCount>1)r.ignoreCount--;else if("+input"==t.origin||"paste"==t.origin||void 0===t.origin){var o=e.listSelections().length;o>1&&(r.ignoreCount=o);var a=t.text.join("\n");if(r.maybeReset&&(r.changes=[],r.maybeReset=!1),a)if(e.state.overwrite&&!/\n/.test(a))r.changes.push([a]);else{if(a.length>1){var s=i&&i.insertEnd&&i.insertEnd.find(),l=e.getCursor();if(s&&s.line==l.line){var c=s.ch-l.ch;c>0&&c<a.length&&(r.changes.push([a,c]),a="")}}a&&r.changes.push(a)}}t=t.next}}}function Wt(e){var t=e.state.vim;if(t.insertMode){var n=N.macroModeState;if(n.isPlaying)return;var r=n.lastInsertModeChanges;r.expectCursorActivityForChange?r.expectCursorActivityForChange=!1:(r.maybeReset=!0,t.insertEnd&&t.insertEnd.clear(),t.insertEnd=e.setBookmark(e.getCursor(),{insertLeft:!0}))}else e.curOp?.isVimOp||Xt(e,t)}function Xt(t,n){var r=t.getCursor("anchor"),i=t.getCursor("head");if(n.visualMode&&!t.somethingSelected()?$e(t,!1):n.visualMode||n.insertMode||!t.somethingSelected()||(n.visualMode=!0,n.visualLine=!1,e.signal(t,"vim-mode-change",{mode:"visual"})),n.visualMode){var o=Oe(i,r)?0:-1,a=Oe(i,r)?-1:0;i=fe(i,0,o),r=fe(r,0,a),n.sel={anchor:r,head:i},et(t,n,"<",Se(i,r)),et(t,n,">",Ee(i,r))}else n.insertMode||(n.lastHPos=t.getCursor().ch)}function Yt(t){var n=N.macroModeState,r=n.lastInsertModeChanges,i=e.keyName?e.keyName(t):t.key;i&&(-1==i.indexOf("Delete")&&-1==i.indexOf("Backspace")||(r.maybeReset&&(r.changes=[],r.maybeReset=!1),r.changes.push(new $(i,t))))}function Zt(e,t,n,r){var i=N.macroModeState;i.isPlaying=!0;var o=t.lastEditActionCommand,a=t.inputState;function s(){o?ie.processAction(e,t,o):ie.evalInput(e,t)}function l(n){if(i.lastInsertModeChanges.changes.length>0){n=t.lastEditActionCommand?n:1;var r=i.lastInsertModeChanges;en(e,r.changes,n)}}if(t.inputState=t.lastEditInputState,o&&o.interlaceInsertRepeat)for(var c=0;c<n;c++)s(),l(1);else r||s(),l(n);t.inputState=a,t.insertMode&&!r&&Vt(e),i.isPlaying=!1}function Jt(t,n){e.lookupKey(n,"vim-insert",function(n){return"string"==typeof n?e.commands[n](t):n(t),!0})}function en(e,t,n){var r=e.getCursor("head"),i=N.macroModeState.lastInsertModeChanges.visualBlock;i&&(Re(e,r,i+1),n=e.listSelections().length,e.setCursor(r));for(var o=0;o<n;o++){i&&e.setCursor(fe(r,o,0));for(var a=0;a<t.length;a++){var s=t[a];if(s instanceof $)Jt(e,s.keyName);else if("string"==typeof s)e.replaceSelection(s);else{var l=e.getCursor(),c=fe(l,0,s[0].length-(s[1]||0));e.replaceRange(s[0],l,s[1]?l:c),e.setCursor(c)}}}i&&e.setCursor(fe(r,0,1))}function tn(e){var t=new e.constructor;return Object.keys(e).forEach(function(n){if("insertEnd"!=n){var r=e[n];Array.isArray(r)?r=r.slice():r&&"object"==typeof r&&r.constructor!=Object&&(r=tn(r)),t[n]=r}}),e.sel&&(t.sel={head:e.sel.head&&ye(e.sel.head),anchor:e.sel.anchor&&ye(e.sel.anchor)}),t}function nn(e,t,n){var r=L(e),i=e,o=!1,a=(r=F.maybeInitVimState_(i),r.visualBlock||r.wasInVisualBlock);if(i.state.closeVimNotification){var s=i.state.closeVimNotification;if(i.state.closeVimNotification=null,s(),"<CR>"==t)return Z(i),!0}var l=i.isInMultiSelectMode();if(r.wasInVisualBlock&&!l?r.wasInVisualBlock=!1:l&&r.visualBlock&&(r.wasInVisualBlock=!0),"<Esc>"!=t||r.insertMode||r.visualMode||!l||"<Esc>"!=r.status)if(a||!l||i.inVirtualSelectionMode)o=F.handleKey(i,t,n);else{var c=tn(r),u=r.inputState.changeQueueList||[];i.operation(function(){i.curOp&&(i.curOp.isVimOp=!0);var e=0;i.forEachSelection(function(){i.state.vim.inputState.changeQueue=u[e];var r=i.getCursor("head"),a=i.getCursor("anchor"),s=Oe(r,a)?0:-1,l=Oe(r,a)?-1:0;r=fe(r,0,s),a=fe(a,0,l),i.state.vim.sel.head=r,i.state.vim.sel.anchor=a,o=F.handleKey(i,t,n),i.virtualSelection&&(u[e]=i.state.vim.inputState.changeQueue,i.state.vim=tn(c)),e++}),i.curOp?.cursorActivity&&!o&&(i.curOp.cursorActivity=!1),i.state.vim=r,r.inputState.changeQueueList=u,r.inputState.changeQueue=null},!0)}else Z(i);return!o||r.visualMode||r.insertMode||r.visualMode==i.somethingSelected()||Xt(i,r),o}return F.defineEx("version","ve",e=>{wt(e,"Codemirror-vim version: <DEV>")}),A("insertModeEscKeysTimeout",200,"number"),B(),F}var o=n(76528),a=n(61163),s=n(81068),l=n(43865),c=n(37323),u=n(4364);function d(e,t){var n=t.ch,r=t.line+1;r<1&&(r=1,n=0),r>e.lines&&(r=e.lines,n=Number.MAX_VALUE);var i=e.line(r);return Math.min(i.from+Math.max(0,n),i.to)}function h(e,t){let n=e.lineAt(t);return{line:n.number-1,ch:t-n.from}}class p{constructor(e,t){this.line=e,this.ch=t}}function f(e,t,n){if(e.addEventListener)e.addEventListener(t,n,!1);else{var r=e._handlers||(e._handlers={});r[t]=(r[t]||[]).concat(n)}}function m(e,t,n){if(e.removeEventListener)e.removeEventListener(t,n,!1);else{var r=e._handlers,i=r&&r[t];if(i){var o=i.indexOf(n);o>-1&&(r[t]=i.slice(0,o).concat(i.slice(o+1)))}}}function g(e,t,...n){var r,i=null===(r=e._handlers)||void 0===r?void 0:r[t];if(i)for(var o=0;o<i.length;++o)i[o](...n)}function v(e,...t){if(e)for(var n=0;n<e.length;++n)e[n](...t)}let b;try{b=new RegExp("[\\w\\p{Alphabetic}\\p{Number}_]","u")}catch(ie){b=/[\w]/}function y(e,t){var n=e.cm6;if(!n.state.readOnly){var r="input.type.compose";if(e.curOp&&(e.curOp.lastChange||(r="input.type.compose.start")),t.annotations)try{t.annotations.some(function(e){"input"==e.value&&(e.value=r)})}catch(i){u.error(i)}else t.userEvent=r;return n.dispatch(t)}}function w(e,t){var n;e.curOp&&(e.curOp.$changeStart=void 0),(t?c.undo:c.redo)(e.cm6);let r=null===(n=e.curOp)||void 0===n?void 0:n.$changeStart;null!=r&&e.cm6.dispatch({selection:{anchor:r}})}var O={Left:e=>(0,s.runScopeHandlers)(e.cm6,{key:"Left"},"editor"),Right:e=>(0,s.runScopeHandlers)(e.cm6,{key:"Right"},"editor"),Up:e=>(0,s.runScopeHandlers)(e.cm6,{key:"Up"},"editor"),Down:e=>(0,s.runScopeHandlers)(e.cm6,{key:"Down"},"editor"),Backspace:e=>(0,s.runScopeHandlers)(e.cm6,{key:"Backspace"},"editor"),Delete:e=>(0,s.runScopeHandlers)(e.cm6,{key:"Delete"},"editor")};class S{openDialog(e,t,n){return A(this,e,t,n)}openNotification(e,t){return _(this,e,t)}constructor(e){this.state={},this.marks=Object.create(null),this.$mid=0,this.options={},this._handlers={},this.$lastChangeEndOffset=0,this.virtualSelection=null,this.cm6=e,this.onChange=this.onChange.bind(this),this.onSelectionChange=this.onSelectionChange.bind(this)}on(e,t){f(this,e,t)}off(e,t){m(this,e,t)}signal(e,t,n){g(this,e,t,n)}indexFromPos(e){return d(this.cm6.state.doc,e)}posFromIndex(e){return h(this.cm6.state.doc,e)}foldCode(e){let t=this.cm6,n=t.state.selection.ranges,r=this.cm6.state.doc,i=d(r,e),s=o.EditorSelection.create([o.EditorSelection.range(i,i)],0).ranges;t.state.selection.ranges=s,(0,a.foldCode)(t),t.state.selection.ranges=n}firstLine(){return 0}lastLine(){return this.cm6.state.doc.lines-1}lineCount(){return this.cm6.state.doc.lines}setCursor(e,t){"object"===typeof e&&(t=e.ch,e=e.line);var n=d(this.cm6.state.doc,{line:e,ch:t||0});this.cm6.dispatch({selection:{anchor:n}},{scrollIntoView:!this.curOp}),this.curOp&&!this.curOp.isVimOp&&this.onBeforeEndOperation()}getCursor(e){var t=this.cm6.state.selection.main,n="head"!=e&&e?"anchor"==e?t.anchor:"start"==e?t.from:"end"==e?t.to:null:t.head;if(null==n)throw new Error("Invalid cursor type");return this.posFromIndex(n)}listSelections(){var e=this.cm6.state.doc;return this.cm6.state.selection.ranges.map(t=>({anchor:h(e,t.anchor),head:h(e,t.head)}))}setSelections(e,t){var n=this.cm6.state.doc,r=e.map(e=>{var t=d(n,e.head),r=d(n,e.anchor);return t==r?o.EditorSelection.cursor(t,1):o.EditorSelection.range(r,t)});this.cm6.dispatch({selection:o.EditorSelection.create(r,t)})}setSelection(e,t,n){this.setSelections([{anchor:e,head:t}],0),n&&"*mouse"==n.origin&&this.onBeforeEndOperation()}getLine(e){var t=this.cm6.state.doc;return e<0||e>=t.lines?"":this.cm6.state.doc.line(e+1).text}getLineHandle(e){return this.$lineHandleChanges||(this.$lineHandleChanges=[]),{row:e,index:this.indexFromPos(new p(e,0))}}getLineNumber(e){var t=this.$lineHandleChanges;if(!t)return null;for(var n=e.index,r=0;r<t.length;r++)if(n=t[r].changes.mapPos(n,1,o.MapMode.TrackAfter),null==n)return null;var i=this.posFromIndex(n);return 0==i.ch?i.line:null}releaseLineHandles(){this.$lineHandleChanges=void 0}getRange(e,t){var n=this.cm6.state.doc;return this.cm6.state.sliceDoc(d(n,e),d(n,t))}replaceRange(e,t,n,r){n||(n=t);var i=this.cm6.state.doc,o=d(i,t),a=d(i,n);y(this,{changes:{from:o,to:a,insert:e}})}replaceSelection(e){y(this,this.cm6.state.replaceSelection(e))}replaceSelections(e){var t=this.cm6.state.selection.ranges,n=t.map((t,n)=>({from:t.from,to:t.to,insert:e[n]||""}));y(this,{changes:n})}getSelection(){return this.getSelections().join("\n")}getSelections(){var e=this.cm6;return e.state.selection.ranges.map(t=>e.state.sliceDoc(t.from,t.to))}somethingSelected(){return this.cm6.state.selection.ranges.some(e=>!e.empty)}getInputField(){return this.cm6.contentDOM}clipPos(e){var t=this.cm6.state.doc,n=e.ch,r=e.line+1;r<1&&(r=1,n=0),r>t.lines&&(r=t.lines,n=Number.MAX_VALUE);var i=t.line(r);return n=Math.min(Math.max(0,n),i.to-i.from),new p(r-1,n)}getValue(){return this.cm6.state.doc.toString()}setValue(e){var t=this.cm6;return t.dispatch({changes:{from:0,to:t.state.doc.length,insert:e},selection:o.EditorSelection.range(0,0)})}focus(){return this.cm6.focus()}blur(){return this.cm6.contentDOM.blur()}defaultTextHeight(){return this.cm6.defaultLineHeight}findMatchingBracket(e,t){var n=this.cm6.state,r=d(n.doc,e),i=(0,a.matchBrackets)(n,r+1,-1);return i&&i.end?{to:h(n.doc,i.end.from)}:(i=(0,a.matchBrackets)(n,r,1),i&&i.end?{to:h(n.doc,i.end.from)}:{to:void 0})}scanForBracket(e,t,n,r){return N(this,e,t,n,r)}indentLine(e,t){t?this.indentMore():this.indentLess()}indentMore(){(0,c.indentMore)(this.cm6)}indentLess(){(0,c.indentLess)(this.cm6)}execCommand(e){if(S.commands.hasOwnProperty(e))S.commands[e](this);else if("goLineLeft"==e)(0,c.cursorLineBoundaryBackward)(this.cm6);else if("goLineRight"==e){(0,c.cursorLineBoundaryForward)(this.cm6);let e=this.cm6.state,t=e.selection.main.head;t<e.doc.length&&"\n"!==e.sliceDoc(t,t+1)&&(0,c.cursorCharBackward)(this.cm6)}else u.log(e+" is not implemented")}setBookmark(e,t){var n=(null===t||void 0===t?void 0:t.insertLeft)?1:-1,r=this.indexFromPos(e),i=new D(this,r,n);return i}addOverlay({query:e}){let t=new l.SearchQuery({regexp:!0,search:e.source,caseSensitive:!/i/.test(e.flags)});if(t.valid){t.forVim=!0,this.cm6Query=t;let e=l.setSearchQuery.of(t);return this.cm6.dispatch({effects:e}),t}}removeOverlay(e){if(!this.cm6Query)return;this.cm6Query.forVim=!1;let t=l.setSearchQuery.of(this.cm6Query);this.cm6.dispatch({effects:t})}getSearchCursor(e,t){var n=this,r=null,i=null,o=!1;void 0==t.ch&&(t.ch=Number.MAX_VALUE);var a=d(n.cm6.state.doc,t),s=e.source.replace(/(\\.|{(?:\d+(?:,\d*)?|,\d+)})|[{}]/g,function(e,t){return t||"\\"+e});function c(t,n=0,r=t.length){return new l.RegExpCursor(t,s,{ignoreCase:e.ignoreCase},n,r)}function u(e){var t=n.cm6.state.doc;if(e>t.length)return null;let r=c(t,e).next();return r.done?null:r.value}var p=1e4;function f(e,t){var r=n.cm6.state.doc;for(let n=1;;n++){let i=Math.max(e,t-n*p),o=c(r,i,t),a=null;while(!o.next().done)a=o.value;if(a&&(i==e||a.from>i+10))return a;if(i==e)return null}}return{findNext:function(){return this.find(!1)},findPrevious:function(){return this.find(!0)},find:function(e){var t=n.cm6.state.doc;if(e){let e=r?o?r.to-1:r.from:a;r=f(0,e)}else{let e=r?o?r.to+1:r.to:a;r=u(e)}return i=r&&{from:h(t,r.from),to:h(t,r.to),match:r.match},o=!!r&&r.from==r.to,r&&r.match},from:function(){return null===i||void 0===i?void 0:i.from},to:function(){return null===i||void 0===i?void 0:i.to},replace:function(e){r&&(y(n,{changes:{from:r.from,to:r.to,insert:e}}),r.to=r.from+e.length,i&&(i.to=h(n.cm6.state.doc,r.to)))},get match(){return i&&i.match}}}findPosV(e,t,n,r){let{cm6:i}=this;const a=i.state.doc;let s="page"==n?i.dom.clientHeight:0;const l=d(a,e);let c=o.EditorSelection.cursor(l,1,void 0,r),u=Math.round(Math.abs(t));for(let o=0;o<u;o++)"page"==n?c=i.moveVertically(c,t>0,s):"line"==n&&(c=i.moveVertically(c,t>0));let p=h(a,c.head);return(t<0&&0==c.head&&0!=r&&0==e.line&&0!=e.ch||t>0&&c.head==a.length&&p.ch!=r&&e.line==p.line)&&(p.hitSide=!0),p}charCoords(e,t){var n=this.cm6.contentDOM.getBoundingClientRect(),r=d(this.cm6.state.doc,e),i=this.cm6.coordsAtPos(r),o=-n.top;return{left:((null===i||void 0===i?void 0:i.left)||0)-n.left,top:((null===i||void 0===i?void 0:i.top)||0)+o,bottom:((null===i||void 0===i?void 0:i.bottom)||0)+o}}coordsChar(e,t){var n=this.cm6.contentDOM.getBoundingClientRect(),r=this.cm6.posAtCoords({x:e.left+n.left,y:e.top+n.top})||0;return h(this.cm6.state.doc,r)}getScrollInfo(){var e=this.cm6.scrollDOM;return{left:e.scrollLeft,top:e.scrollTop,height:e.scrollHeight,width:e.scrollWidth,clientHeight:e.clientHeight,clientWidth:e.clientWidth}}scrollTo(e,t){null!=e&&(this.cm6.scrollDOM.scrollLeft=e),null!=t&&(this.cm6.scrollDOM.scrollTop=t)}scrollIntoView(e,t){if(e){var n=this.indexFromPos(e);this.cm6.dispatch({effects:s.EditorView.scrollIntoView(n)})}else this.cm6.dispatch({scrollIntoView:!0,userEvent:"scroll"})}getWrapperElement(){return this.cm6.dom}getMode(){return{name:this.getOption("mode")}}setSize(e,t){this.cm6.dom.style.width=e+4+"px",this.cm6.dom.style.height=t+"px",this.refresh()}refresh(){this.cm6.measure()}destroy(){this.removeOverlay()}getLastEditEnd(){return this.posFromIndex(this.$lastChangeEndOffset)}onChange(e){this.$lineHandleChanges&&this.$lineHandleChanges.push(e);for(let n in this.marks){let t=this.marks[n];t.update(e.changes)}this.virtualSelection&&(this.virtualSelection.ranges=this.virtualSelection.ranges.map(t=>t.map(e.changes)));var t=this.curOp=this.curOp||{};e.changes.iterChanges((e,n,r,i,o)=>{(null==t.$changeStart||t.$changeStart>r)&&(t.$changeStart=r),this.$lastChangeEndOffset=i;var a={text:o.toJSON()};t.lastChange?t.lastChange.next=t.lastChange=a:t.lastChange=t.change=a},!0),t.changeHandlers||(t.changeHandlers=this._handlers["change"]&&this._handlers["change"].slice())}onSelectionChange(){var e=this.curOp=this.curOp||{};e.cursorActivityHandlers||(e.cursorActivityHandlers=this._handlers["cursorActivity"]&&this._handlers["cursorActivity"].slice()),this.curOp.cursorActivity=!0}operation(e,t){this.curOp||(this.curOp={$d:0}),this.curOp.$d++;try{var n=e()}finally{this.curOp&&(this.curOp.$d--,this.curOp.$d||this.onBeforeEndOperation())}return n}onBeforeEndOperation(){var e=this.curOp,t=!1;e&&(e.change&&v(e.changeHandlers,this,e.change),e&&e.cursorActivity&&(v(e.cursorActivityHandlers,this,null),e.isVimOp&&(t=!0)),this.curOp=null),t&&this.scrollIntoView()}moveH(e,t){if("char"==t){var n=this.getCursor();this.setCursor(n.line,n.ch+e)}}setOption(e,t){switch(e){case"keyMap":this.state.keyMap=t;break;case"textwidth":this.state.textwidth=t;break}}getOption(e){switch(e){case"firstLineNumber":return 1;case"tabSize":return this.cm6.state.tabSize||4;case"readOnly":return this.cm6.state.readOnly;case"indentWithTabs":return"\t"==this.cm6.state.facet(a.indentUnit);case"indentUnit":return this.cm6.state.facet(a.indentUnit).length||2;case"textwidth":return this.state.textwidth;case"keyMap":return this.state.keyMap||"vim"}}toggleOverwrite(e){this.state.overwrite=e}getTokenTypeAt(e){var t,n=this.indexFromPos(e),r=(0,a.ensureSyntaxTree)(this.cm6.state,n),i=null===r||void 0===r?void 0:r.resolve(n),o=(null===(t=null===i||void 0===i?void 0:i.type)||void 0===t?void 0:t.name)||"";return/comment/i.test(o)?"comment":/string/i.test(o)?"string":""}overWriteSelection(e){var t=this.cm6.state.doc,n=this.cm6.state.selection,r=n.ranges.map(e=>{if(e.empty){var n=e.to<t.length?t.sliceString(e.from,e.to+1):"";if(n&&!/\n/.test(n))return o.EditorSelection.range(e.from,e.to+1)}return e});this.cm6.dispatch({selection:o.EditorSelection.create(r,n.mainIndex)}),this.replaceSelection(e)}isInMultiSelectMode(){return this.cm6.state.selection.ranges.length>1}virtualSelectionMode(){return!!this.virtualSelection}forEachSelection(e){var t=this.cm6.state.selection;this.virtualSelection=o.EditorSelection.create(t.ranges,t.mainIndex);for(var n=0;n<this.virtualSelection.ranges.length;n++){var r=this.virtualSelection.ranges[n];r&&(this.cm6.dispatch({selection:o.EditorSelection.create([r])}),e(),this.virtualSelection.ranges[n]=this.cm6.state.selection.ranges[0])}this.cm6.dispatch({selection:this.virtualSelection}),this.virtualSelection=null}hardWrap(e){return L(this,e)}}function E(e,t,n){var r=document.createElement("div");return r.appendChild(t),r}function x(e,t){e.state.currentNotificationClose&&e.state.currentNotificationClose(),e.state.currentNotificationClose=t}function _(e,t,n){x(e,s);var r,i=E(e,t,n&&n.bottom),o=!1,a=n&&"undefined"!==typeof n.duration?n.duration:5e3;function s(){o||(o=!0,clearTimeout(r),i.remove(),C(e,i))}return i.onclick=function(e){e.preventDefault(),s()},k(e,i),a&&(r=setTimeout(s,a)),s}function k(e,t){var n=e.state.dialog;e.state.dialog=t,t.style.flex="1",t&&n!==t&&(n&&n.contains(document.activeElement)&&e.focus(),n&&n.parentElement?n.parentElement.replaceChild(t,n):n&&n.remove(),S.signal(e,"dialog"))}function C(e,t){e.state.dialog==t&&(e.state.dialog=null,S.signal(e,"dialog"))}function A(e,t,n,r){r||(r={}),x(e,void 0);var i=E(e,t,r.bottom),o=!1;function a(t){if("string"==typeof t)s.value=t;else{if(o)return;o=!0,C(e,i),e.state.dialog||e.focus(),r.onClose&&r.onClose(i)}}k(e,i);var s=i.getElementsByTagName("input")[0];return s&&(r.value&&(s.value=r.value,!1!==r.selectValueOnOpen&&s.select()),r.onInput&&S.on(s,"input",function(e){r.onInput(e,s.value,a)}),r.onKeyUp&&S.on(s,"keyup",function(e){r.onKeyUp(e,s.value,a)}),S.on(s,"keydown",function(e){r&&r.onKeyDown&&r.onKeyDown(e,s.value,a)||(13==e.keyCode&&n&&n(s.value),(27==e.keyCode||!1!==r.closeOnEnter&&13==e.keyCode)&&(s.blur(),S.e_stop(e),a()))}),!1!==r.closeOnBlur&&S.on(s,"blur",function(){setTimeout(function(){document.activeElement!==s&&a()})}),s.focus()),a}S.isMac="undefined"!=typeof navigator&&/Mac/.test(navigator.platform),S.Pos=p,S.StringStream=a.StringStream,S.commands={toggleLineComment:function(e){(0,c.toggleLineComment)(e.cm6)},cursorCharLeft:function(e){(0,c.cursorCharLeft)(e.cm6)},redo:function(e){w(e,!1)},undo:function(e){w(e,!0)},newlineAndIndent:function(e){(0,c.insertNewlineAndIndent)({state:e.cm6.state,dispatch:t=>y(e,t)})},indentAuto:function(e){(0,c.indentSelection)(e.cm6)},newlineAndIndentContinueComment:void 0,save:void 0},S.isWordChar=function(e){return b.test(e)},S.keys=O,S.addClass=function(e,t){},S.rmClass=function(e,t){},S.e_preventDefault=function(e){e.preventDefault()},S.e_stop=function(e){var t,n;null===(t=null===e||void 0===e?void 0:e.stopPropagation)||void 0===t||t.call(e),null===(n=null===e||void 0===e?void 0:e.preventDefault)||void 0===n||n.call(e)},S.lookupKey=function(e,t,n){var r=S.keys[e];!r&&/^Arrow/.test(e)&&(r=S.keys[e.slice(5)]),r&&n(r)},S.on=f,S.off=m,S.signal=g,S.findMatchingTag=P,S.findEnclosingTag=I,S.keyName=void 0;var T={"(":")>",")":"(<","[":"]>","]":"[<","{":"}>","}":"{<","<":">>",">":"<<"};function R(e){return e&&e.bracketRegex||/[(){}[\]]/}function N(e,t,n,r,i){for(var o=i&&i.maxScanLineLength||1e4,a=i&&i.maxScanLines||1e3,s=[],l=R(i),c=n>0?Math.min(t.line+a,e.lastLine()+1):Math.max(e.firstLine()-1,t.line-a),u=t.line;u!=c;u+=n){var d=e.getLine(u);if(d){var h=n>0?0:d.length-1,f=n>0?d.length:-1;if(!(d.length>o))for(u==t.line&&(h=t.ch-(n<0?1:0));h!=f;h+=n){var m=d.charAt(h);if(l.test(m)){var g=T[m];if(g&&">"==g.charAt(1)==n>0)s.push(m);else{if(!s.length)return{pos:new p(u,h),ch:m};s.pop()}}}}}return u-n!=(n>0?e.lastLine():e.firstLine())&&null}function P(e,t){return null}function I(e,t){var n,r,i=e.cm6.state,o=e.indexFromPos(t);if(o<i.doc.length){var s=i.sliceDoc(o,o+1);"<"==s&&o++}var l=(0,a.ensureSyntaxTree)(i,o),c=(null===l||void 0===l?void 0:l.resolve(o))||null;while(c){if("OpenTag"==(null===(n=c.firstChild)||void 0===n?void 0:n.type.name)&&"CloseTag"==(null===(r=c.lastChild)||void 0===r?void 0:r.type.name))return{open:M(i.doc,c.firstChild),close:M(i.doc,c.lastChild)};c=c.parent}}function M(e,t){return{from:h(e,t.from),to:h(e,t.to)}}class D{constructor(e,t,n){this.cm=e,this.id=e.$mid++,this.offset=t,this.assoc=n,e.marks[this.id]=this}clear(){delete this.cm.marks[this.id]}find(){return null==this.offset?null:this.cm.posFromIndex(this.offset)}update(e){null!=this.offset&&(this.offset=e.mapPos(this.offset,this.assoc,o.MapMode.TrackDel))}}function L(e,t){var n,r=t.column||e.getOption("textwidth")||80,i=0!=t.allowMerge,o=Math.min(t.from,t.to),a=Math.max(t.from,t.to);while(o<=a){var s=e.getLine(o);if(s.length>r){var l=m(s,r,5);if(l){var c=null===(n=/^\s*/.exec(s))||void 0===n?void 0:n[0];e.replaceRange("\n"+c,new p(o,l.start),new p(o,l.end))}a++}else if(i&&/\S/.test(s)&&o!=a){var u=e.getLine(o+1);if(u&&/\S/.test(u)){var d=s.replace(/\s+$/,""),h=u.replace(/^\s+/,""),f=d+" "+h;l=m(f,r,5);l&&l.start>d.length||f.length<r?(e.replaceRange(" ",new p(o,d.length),new p(o+1,u.length-h.length)),o--,a--):d.length<s.length&&e.replaceRange("",new p(o,d.length),new p(o,s.length))}}o++}return o;function m(e,t,n){if(!(e.length<t)){var r=e.slice(0,t),i=e.slice(t),o=/^(?:(\s+)|(\S+)(\s+))/.exec(i),a=/(?:(\s+)|(\s+)(\S+))$/.exec(r),s=0,l=0;return a&&!a[2]&&(s=t-a[1].length,l=t),o&&!o[2]&&(s||(s=t),l=t+o[1].length),s?{start:s,end:l}:a&&a[2]&&a.index>n?{start:a.index,end:a.index+a[2].length}:o&&o[2]?(s=t+o[2].length,{start:s,end:s+o[3].length}):void 0}}}let B=s.getDrawSelectionConfig||function(){let e={cursorBlinkRate:1200};return function(){return e}}();class ${constructor(e,t,n,r,i,o,a,s,l,c){this.left=e,this.top=t,this.height=n,this.fontFamily=r,this.fontSize=i,this.fontWeight=o,this.color=a,this.className=s,this.letter=l,this.partial=c}draw(){let e=document.createElement("div");return e.className=this.className,this.adjust(e),e}adjust(e){e.style.left=this.left+"px",e.style.top=this.top+"px",e.style.height=this.height+"px",e.style.lineHeight=this.height+"px",e.style.fontFamily=this.fontFamily,e.style.fontSize=this.fontSize,e.style.fontWeight=this.fontWeight,e.style.color=this.partial?"transparent":this.color,e.className=this.className,e.textContent=this.letter}eq(e){return this.left==e.left&&this.top==e.top&&this.height==e.height&&this.fontFamily==e.fontFamily&&this.fontSize==e.fontSize&&this.fontWeight==e.fontWeight&&this.color==e.color&&this.className==e.className&&this.letter==e.letter}}class V{constructor(e,t){this.view=e,this.rangePieces=[],this.cursors=[],this.cm=t,this.measureReq={read:this.readPos.bind(this),write:this.drawSel.bind(this)},this.cursorLayer=e.scrollDOM.appendChild(document.createElement("div")),this.cursorLayer.className="cm-cursorLayer cm-vimCursorLayer",this.cursorLayer.setAttribute("aria-hidden","true"),e.requestMeasure(this.measureReq),this.setBlinkRate()}setBlinkRate(){let e=B(this.cm.cm6.state),t=e.cursorBlinkRate;this.cursorLayer.style.animationDuration=t+"ms"}update(e){(e.selectionSet||e.geometryChanged||e.viewportChanged)&&(this.view.requestMeasure(this.measureReq),this.cursorLayer.style.animationName="cm-blink"==this.cursorLayer.style.animationName?"cm-blink2":"cm-blink"),F(e)&&this.setBlinkRate()}scheduleRedraw(){this.view.requestMeasure(this.measureReq)}readPos(){let{state:e}=this.view,t=[];for(let n of e.selection.ranges){let r=n==e.selection.main,i=H(this.cm,this.view,n,r);i&&t.push(i)}return{cursors:t}}drawSel({cursors:e}){if(e.length!=this.cursors.length||e.some((e,t)=>!e.eq(this.cursors[t]))){let t=this.cursorLayer.children;if(t.length!==e.length){this.cursorLayer.textContent="";for(const t of e)this.cursorLayer.appendChild(t.draw())}else e.forEach((e,n)=>e.adjust(t[n]));this.cursors=e}}destroy(){this.cursorLayer.remove()}}function F(e){return B(e.startState)!=B(e.state)}const j={".cm-vimMode .cm-line":{"& ::selection":{backgroundColor:"transparent !important"},"&::selection":{backgroundColor:"transparent !important"},caretColor:"transparent !important"},".cm-fat-cursor":{position:"absolute",background:"#ff9696",border:"none",whiteSpace:"pre"},"&:not(.cm-focused) .cm-fat-cursor":{background:"none",outline:"solid 1px #ff9696",color:"transparent !important"}},U=o.Prec.highest(s.EditorView.theme(j));function G(e){let t=e.scrollDOM.getBoundingClientRect(),n=e.textDirection==s.Direction.LTR?t.left:t.right-e.scrollDOM.clientWidth;return{left:n-e.scrollDOM.scrollLeft*e.scaleX,top:t.top-e.scrollDOM.scrollTop*e.scaleY}}function H(e,t,n,r){var i,o,a,s;let l=n.head,c=!1,u=1,d=e.state.vim;if(d&&(!d.insertMode||e.state.overwrite)){if(c=!0,d.visualBlock&&!r)return null;if(n.anchor<n.head){let e=l<t.state.doc.length&&t.state.sliceDoc(l,l+1);"\n"!=e&&l--}e.state.overwrite?u=.2:d.status&&(u=.5)}if(c){let e=l<t.state.doc.length&&t.state.sliceDoc(l,l+1);e&&/[\uDC00-\uDFFF]/.test(e)&&l>1&&(l--,e=t.state.sliceDoc(l,l+1));let n=t.coordsAtPos(l,1);if(!n)return null;let c=G(t),d=t.domAtPos(l),p=d?d.node:t.contentDOM;p instanceof Text&&d.offset>=p.data.length&&(null===(i=p.parentElement)||void 0===i?void 0:i.nextSibling)&&(p=null===(o=p.parentElement)||void 0===o?void 0:o.nextSibling,d={node:p,offset:0});while(d&&d.node instanceof HTMLElement)p=d.node,d={node:d.node.childNodes[d.offset],offset:0};if(!(p instanceof HTMLElement)){if(!p.parentNode)return null;p=p.parentNode}let f=getComputedStyle(p),m=n.left,g=null===(s=(a=t).coordsForChar)||void 0===s?void 0:s.call(a,l);if(g&&(m=g.left),e&&"\n"!=e&&"\r"!=e)if("\t"==e){e=" ";var h=t.coordsAtPos(l+1,-1);h&&(m=h.left-(h.left-n.left)/parseInt(f.tabSize))}else/[\uD800-\uDBFF]/.test(e)&&l<t.state.doc.length-1&&(e+=t.state.sliceDoc(l+1,l+2));else e=" ";let v=n.bottom-n.top;return new $((m-c.left)/t.scaleX,(n.top-c.top+v*(1-u))/t.scaleY,v*u/t.scaleY,f.fontFamily,f.fontSize,f.fontWeight,f.color,r?"cm-fat-cursor cm-cursor-primary":"cm-fat-cursor cm-cursor-secondary",e,1!=u)}return null}var q="undefined"!=typeof navigator&&/linux/i.test(navigator.platform)&&/ Gecko\/\d+/.exec(navigator.userAgent);const Q=i(S),z=250,K=s.EditorView.baseTheme({".cm-vimMode .cm-cursorLayer:not(.cm-vimCursorLayer)":{display:"none"},".cm-vim-panel":{padding:"0px 10px",fontFamily:"monospace",minHeight:"1.3em",display:"flex"},".cm-vim-panel input":{border:"none",outline:"none",backgroundColor:"inherit"},"&light .cm-searchMatch":{backgroundColor:"#ffff0054"},"&dark .cm-searchMatch":{backgroundColor:"#00ffff8a"}}),W=s.ViewPlugin.fromClass(class{constructor(e){this.status="",this.query=null,this.decorations=s.Decoration.none,this.waitForCopy=!1,this.lastKeydown="",this.useNextTextInput=!1,this.compositionText="",this.view=e;const t=this.cm=new S(e);Q.enterVimMode(this.cm),this.view.cm=this.cm,this.cm.state.vimPlugin=this,this.blockCursor=new V(e,t),this.updateClass(),this.cm.on("vim-command-done",()=>{t.state.vim&&(t.state.vim.status=""),this.blockCursor.scheduleRedraw(),this.updateStatus()}),this.cm.on("vim-mode-change",e=>{t.state.vim&&(t.state.vim.mode=e.mode,e.subMode&&(t.state.vim.mode+="linewise"===e.subMode?" line":" block"),t.state.vim.status="",this.blockCursor.scheduleRedraw(),this.updateClass(),this.updateStatus())}),this.cm.on("dialog",()=>{this.cm.state.statusbar?this.updateStatus():e.dispatch({effects:Z.of(!!this.cm.state.dialog)})}),this.dom=document.createElement("span"),this.spacer=document.createElement("span"),this.spacer.style.flex="1",this.statusButton=document.createElement("span"),this.statusButton.onclick=e=>{Q.handleKey(this.cm,"<Esc>","user"),this.cm.focus()},this.statusButton.style.cssText="cursor: pointer"}update(e){var t;if((e.viewportChanged||e.docChanged)&&this.query&&this.highlight(this.query),e.docChanged&&this.cm.onChange(e),e.selectionSet&&this.cm.onSelectionChange(),e.viewportChanged,this.cm.curOp&&!this.cm.curOp.isVimOp&&this.cm.onBeforeEndOperation(),e.transactions)for(let n of e.transactions)for(let e of n.effects)if(e.is(l.setSearchQuery)){let n=null===(t=e.value)||void 0===t?void 0:t.forVim;if(n){let t=e.value.create();this.highlight(t)}else this.highlight(null)}this.blockCursor.update(e)}updateClass(){const e=this.cm.state;!e.vim||e.vim.insertMode&&!e.overwrite?this.view.scrollDOM.classList.remove("cm-vimMode"):this.view.scrollDOM.classList.add("cm-vimMode")}updateStatus(){let e=this.cm.state.statusbar,t=this.cm.state.vim;if(!e||!t)return;let n=this.cm.state.dialog;if(n)n.parentElement!=e&&(e.textContent="",e.appendChild(n));else{e.textContent="";var r=(t.mode||"normal").toUpperCase();t.insertModeReturn&&(r+="(C-O)"),this.statusButton.textContent=`--${r}--`,e.appendChild(this.statusButton),e.appendChild(this.spacer)}this.dom.textContent=t.status,e.appendChild(this.dom)}destroy(){Q.leaveVimMode(this.cm),this.updateClass(),this.blockCursor.destroy(),delete this.view.cm}highlight(e){if(this.query=e,!e)return this.decorations=s.Decoration.none;let{view:t}=this,n=new o.RangeSetBuilder;for(let r=0,i=t.visibleRanges,o=i.length;r<o;r++){let{from:a,to:s}=i[r];while(r<o-1&&s>i[r+1].from-2*z)s=i[++r].to;e.highlight(t.state,a,s,(e,t)=>{n.add(e,t,Y)})}return this.decorations=n.finish()}handleKey(e,t){const n=this.cm;let r=n.state.vim;if(!r)return;const i=Q.vimKeyFromEvent(e,r);if(S.signal(this.cm,"inputEvent",{type:"handleKey",key:i}),!i)return;if("<Esc>"==i&&!r.insertMode&&!r.visualMode&&this.query){const e=r.searchState_;e&&(n.removeOverlay(e.getOverlay()),e.setOverlay(null))}let o="<C-c>"===i&&!S.isMac;if(o&&n.somethingSelected())return this.waitForCopy=!0,!0;r.status=(r.status||"")+i;let a=Q.multiSelectHandleKey(n,i,"user");return r=Q.maybeInitVimState_(n),!a&&r.insertMode&&n.state.overwrite&&(e.key&&1==e.key.length&&!/\n/.test(e.key)?(a=!0,n.overWriteSelection(e.key)):"Backspace"==e.key&&(a=!0,S.commands.cursorCharLeft(n))),a&&(S.signal(this.cm,"vim-keypress",i),e.preventDefault(),e.stopPropagation(),this.blockCursor.scheduleRedraw()),this.updateStatus(),!!a}},{eventHandlers:{copy:function(e,t){this.waitForCopy&&(this.waitForCopy=!1,Promise.resolve().then(()=>{var e=this.cm,t=e.state.vim;t&&(t.insertMode?e.setSelection(e.getCursor(),e.getCursor()):e.operation(()=>{e.curOp&&(e.curOp.isVimOp=!0),Q.handleKey(e,"<Esc>","user")}))}))},compositionstart:function(e,t){this.useNextTextInput=!0,S.signal(this.cm,"inputEvent",e)},compositionupdate:function(e,t){S.signal(this.cm,"inputEvent",e)},compositionend:function(e,t){S.signal(this.cm,"inputEvent",e)},keypress:function(e,t){S.signal(this.cm,"inputEvent",e),"Dead"==this.lastKeydown&&this.handleKey(e,t)},keydown:function(e,t){S.signal(this.cm,"inputEvent",e),this.lastKeydown=e.key,"Unidentified"==this.lastKeydown||"Process"==this.lastKeydown||"Dead"==this.lastKeydown?this.useNextTextInput=!0:(this.useNextTextInput=!1,this.handleKey(e,t))}},provide:()=>[s.EditorView.inputHandler.of((e,t,n,r)=>{var i,o,a=re(e);if(!a)return!1;var s=null===(i=a.state)||void 0===i?void 0:i.vim,l=a.state.vimPlugin;if(s&&!s.insertMode&&!(null===(o=a.curOp)||void 0===o?void 0:o.isVimOp)){if("\0\0"===r)return!0;if(S.signal(a,"inputEvent",{type:"text",text:r,from:t,to:n}),1==r.length&&l.useNextTextInput){if(s.expectLiteralNext&&e.composing)return l.compositionText=r,!1;if(l.compositionText){var c=l.compositionText;l.compositionText="";var u=e.state.selection.main.head,d=e.state.sliceDoc(u-c.length,u);if(c===d){var h=a.getCursor();a.replaceRange("",a.posFromIndex(u-c.length),h)}}return l.handleKey({key:r,preventDefault:()=>{},stopPropagation:()=>{}}),X(e),!0}}return!1})],decorations:e=>e.decorations});function X(e){var t=e.scrollDOM.parentElement;if(t){if(q)return e.contentDOM.textContent="\0\0",void e.contentDOM.dispatchEvent(new CustomEvent("compositionend"));var n=e.scrollDOM.nextSibling,r=window.getSelection(),i=r&&{anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset};e.scrollDOM.remove(),t.insertBefore(e.scrollDOM,n);try{i&&r&&(r.setPosition(i.anchorNode,i.anchorOffset),i.focusNode&&r.extend(i.focusNode,i.focusOffset))}catch(o){u.error(o)}e.focus(),e.contentDOM.dispatchEvent(new CustomEvent("compositionend"))}}const Y=s.Decoration.mark({class:"cm-searchMatch"}),Z=o.StateEffect.define(),J=o.StateField.define({create:()=>!1,update(e,t){for(let n of t.effects)n.is(Z)&&(e=n.value);return e},provide:e=>s.showPanel.from(e,e=>e?ee:null)});function ee(e){let t=document.createElement("div");t.className="cm-vim-panel";let n=e.cm;return n.state.dialog&&t.appendChild(n.state.dialog),{top:!1,dom:t}}function te(e){let t=document.createElement("div");t.className="cm-vim-panel";let n=e.cm;return n.state.statusbar=t,n.state.vimPlugin.updateStatus(),{dom:t}}function ne(e={}){return[K,W,U,e.status?s.showPanel.of(te):J]}function re(e){return e.cm||null}},81073:function(e,t,n){"use strict";n.d(t,{Or:function(){return Up},Ky:function(){return Gp}});var r=n(9274),i=n.t(r,2);n(4364);
|
||
/**
|
||
* @vue/shared v3.5.42
|
||
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
||
* @license MIT
|
||
**/
|
||
function o(e){const t=Object.create(null);for(const n of e.split(","))t[n]=1;return e=>e in t}const a={},s=[],l=()=>{},c=()=>!1,u=e=>111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),d=e=>e.startsWith("onUpdate:"),h=Object.assign,p=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},f=Object.prototype.hasOwnProperty,m=(e,t)=>f.call(e,t),g=Array.isArray,v=e=>"[object Map]"===C(e),b=e=>"[object Set]"===C(e),y=e=>"[object Date]"===C(e),w=e=>"[object RegExp]"===C(e),O=e=>"function"===typeof e,S=e=>"string"===typeof e,E=e=>"symbol"===typeof e,x=e=>null!==e&&"object"===typeof e,_=e=>(x(e)||O(e))&&O(e.then)&&O(e.catch),k=Object.prototype.toString,C=e=>k.call(e),A=e=>C(e).slice(8,-1),T=e=>"[object Object]"===C(e),R=e=>S(e)&&"NaN"!==e&&"-"!==e[0]&&""+parseInt(e,10)===e,N=o(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),P=o("bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo"),I=e=>{const t=Object.create(null);return n=>{const r=t[n];return r||(t[n]=e(n))}},M=/-\w/g,D=I(e=>e.replace(M,e=>e.slice(1).toUpperCase())),L=/\B([A-Z])/g,B=I(e=>e.replace(L,"-$1").toLowerCase()),$=I(e=>e.charAt(0).toUpperCase()+e.slice(1)),V=I(e=>{const t=e?`on${$(e)}`:"";return t}),F=(e,t)=>!Object.is(e,t),j=(e,...t)=>{for(let n=0;n<e.length;n++)e[n](...t)},U=(e,t,n,r=!1)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:r,value:n})},G=e=>{const t=parseFloat(e);return isNaN(t)?e:t};let H;const q=()=>H||(H="undefined"!==typeof globalThis?globalThis:"undefined"!==typeof self?self:"undefined"!==typeof window?window:"undefined"!==typeof n.g?n.g:{});function Q(e){if(g(e)){const t={};for(let n=0;n<e.length;n++){const r=e[n],i=S(r)?X(r):Q(r);if(i)for(const e in i)t[e]=i[e]}return t}if(S(e)||x(e))return e}const z=/;(?![^(]*\))/g,K=/:([^]+)/,W=/\/\*[^]*?\*\//g;function X(e){const t={};return e.replace(W,"").split(z).forEach(e=>{if(e){const n=e.split(K);n.length>1&&(t[n[0].trim()]=n[1].trim())}}),t}function Y(e){let t="";if(S(e))t=e;else if(g(e))for(let n=0;n<e.length;n++){const r=Y(e[n]);r&&(t+=r+" ")}else if(x(e))for(const n in e)e[n]&&(t+=n+" ");return t.trim()}const Z="html,body,base,head,link,meta,style,title,address,article,aside,footer,header,hgroup,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,output,progress,select,textarea,details,dialog,menu,summary,template,blockquote,iframe,tfoot",J="svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,defs,desc,discard,ellipse,feBlend,feColorMatrix,feComponentTransfer,feComposite,feConvolveMatrix,feDiffuseLighting,feDisplacementMap,feDistantLight,feDropShadow,feFlood,feFuncA,feFuncB,feFuncG,feFuncR,feGaussianBlur,feImage,feMerge,feMergeNode,feMorphology,feOffset,fePointLight,feSpecularLighting,feSpotLight,feTile,feTurbulence,filter,foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,polygon,polyline,radialGradient,rect,set,solidcolor,stop,switch,symbol,text,textPath,title,tspan,unknown,use,view",ee="annotation,annotation-xml,maction,maligngroup,malignmark,math,menclose,merror,mfenced,mfrac,mfraction,mglyph,mi,mlabeledtr,mlongdiv,mmultiscripts,mn,mo,mover,mpadded,mphantom,mprescripts,mroot,mrow,ms,mscarries,mscarry,msgroup,msline,mspace,msqrt,msrow,mstack,mstyle,msub,msubsup,msup,mtable,mtd,mtext,mtr,munder,munderover,none,semantics",te="area,base,br,col,embed,hr,img,input,link,meta,param,source,track,wbr",ne=o(Z),re=o(J),ie=o(ee),oe=o(te);function ae(e,t){if(e.length!==t.length)return!1;let n=!0;for(let r=0;n&&r<e.length;r++)n=le(e[r],t[r]);return n}function se(e,t){if(e.size!==t.size)return!1;const n=Array.from(t),r=new Uint8Array(n.length);for(const i of e){let e=-1;for(let t=0;t<n.length;t++)if(!r[t]&&le(i,n[t])){e=t;break}if(e<0)return!1;r[e]=1}return!0}function le(e,t){if(e===t)return!0;let n=y(e),r=y(t);if(n||r)return!(!n||!r)&&e.getTime()===t.getTime();if(n=E(e),r=E(t),n||r)return e===t;if(n=g(e),r=g(t),n||r)return!(!n||!r)&&ae(e,t);if(n=x(e),r=x(t),n||r){if(!n||!r)return!1;if(n=v(e),r=v(t),n||r)return!(!n||!r)&&se(e,t);if(n=b(e),r=b(t),n||r)return!(!n||!r)&&se(e,t);const i=Object.keys(e).length,o=Object.keys(t).length;if(i!==o)return!1;for(const n in e){const r=e.hasOwnProperty(n),i=t.hasOwnProperty(n);if(r&&!i||!r&&i||!le(e[n],t[n]))return!1}}return String(e)===String(t)}function ce(e,t){return e.findIndex(e=>le(e,t))}
|
||
/**
|
||
* @vue/compiler-core v3.5.42
|
||
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
||
* @license MIT
|
||
**/
|
||
const ue=Symbol(""),de=Symbol(""),he=Symbol(""),pe=Symbol(""),fe=Symbol(""),me=Symbol(""),ge=Symbol(""),ve=Symbol(""),be=Symbol(""),ye=Symbol(""),we=Symbol(""),Oe=Symbol(""),Se=Symbol(""),Ee=Symbol(""),xe=Symbol(""),_e=Symbol(""),ke=Symbol(""),Ce=Symbol(""),Ae=Symbol(""),Te=Symbol(""),Re=Symbol(""),Ne=Symbol(""),Pe=Symbol(""),Ie=Symbol(""),Me=Symbol(""),De=Symbol(""),Le=Symbol(""),Be=Symbol(""),$e=Symbol(""),Ve=Symbol(""),Fe=Symbol(""),je=Symbol(""),Ue=Symbol(""),Ge=Symbol(""),He=Symbol(""),qe=Symbol(""),Qe=Symbol(""),ze=Symbol(""),Ke=Symbol(""),We={[ue]:"Fragment",[de]:"Teleport",[he]:"Suspense",[pe]:"KeepAlive",[fe]:"BaseTransition",[me]:"openBlock",[ge]:"createBlock",[ve]:"createElementBlock",[be]:"createVNode",[ye]:"createElementVNode",[we]:"createCommentVNode",[Oe]:"createTextVNode",[Se]:"createStaticVNode",[Ee]:"resolveComponent",[xe]:"resolveDynamicComponent",[_e]:"resolveDirective",[ke]:"resolveFilter",[Ce]:"withDirectives",[Ae]:"renderList",[Te]:"renderSlot",[Re]:"createSlots",[Ne]:"toDisplayString",[Pe]:"mergeProps",[Ie]:"normalizeClass",[Me]:"normalizeStyle",[De]:"normalizeProps",[Le]:"guardReactiveProps",[Be]:"toHandlers",[$e]:"camelize",[Ve]:"capitalize",[Fe]:"toHandlerKey",[je]:"setBlockTracking",[Ue]:"pushScopeId",[Ge]:"popScopeId",[He]:"withCtx",[qe]:"unref",[Qe]:"isRef",[ze]:"withMemo",[Ke]:"isMemoSame"};function Xe(e){Object.getOwnPropertySymbols(e).forEach(t=>{We[t]=e[t]})}const Ye={start:{line:1,column:1,offset:0},end:{line:1,column:1,offset:0},source:""};function Ze(e,t=""){return{type:0,source:t,children:e,helpers:new Set,components:[],directives:[],hoists:[],imports:[],cached:[],temps:0,codegenNode:void 0,loc:Ye}}function Je(e,t,n,r,i,o,a,s=!1,l=!1,c=!1,u=Ye){return e&&(s?(e.helper(me),e.helper(dt(e.inSSR,c))):e.helper(ut(e.inSSR,c)),a&&e.helper(Ce)),{type:13,tag:t,props:n,children:r,patchFlag:i,dynamicProps:o,directives:a,isBlock:s,disableTracking:l,isComponent:c,loc:u}}function et(e,t=Ye){return{type:17,loc:t,elements:e}}function tt(e,t=Ye){return{type:15,loc:t,properties:e}}function nt(e,t){return{type:16,loc:Ye,key:S(e)?rt(e,!0):e,value:t}}function rt(e,t=!1,n=Ye,r=0){return{type:4,loc:n,content:e,isStatic:t,constType:t?3:r}}function it(e,t=Ye){return{type:8,loc:t,children:e}}function ot(e,t=[],n=Ye){return{type:14,loc:n,callee:e,arguments:t}}function at(e,t=void 0,n=!1,r=!1,i=Ye){return{type:18,params:e,returns:t,newline:n,isSlot:r,loc:i}}function st(e,t,n,r=!0){return{type:19,test:e,consequent:t,alternate:n,newline:r,loc:Ye}}function lt(e,t,n=!1,r=!1){return{type:20,index:e,value:t,needPauseTracking:n,inVOnce:r,needArraySpread:!1,loc:Ye}}function ct(e){return{type:21,body:e,loc:Ye}}function ut(e,t){return e||t?be:ye}function dt(e,t){return e||t?ge:ve}function ht(e,{helper:t,removeHelper:n,inSSR:r}){e.isBlock||(e.isBlock=!0,n(ut(r,e.isComponent)),t(me),t(dt(r,e.isComponent)))}const pt=new Uint8Array([123,123]),ft=new Uint8Array([125,125]);function mt(e){return e>=97&&e<=122||e>=65&&e<=90}function gt(e){return 32===e||10===e||9===e||12===e||13===e}function vt(e){return 47===e||62===e||gt(e)}function bt(e){const t=new Uint8Array(e.length);for(let n=0;n<e.length;n++)t[n]=e.charCodeAt(n);return t}const yt={Cdata:new Uint8Array([67,68,65,84,65,91]),CdataEnd:new Uint8Array([93,93,62]),CommentEnd:new Uint8Array([45,45,62]),ScriptEnd:new Uint8Array([60,47,115,99,114,105,112,116]),StyleEnd:new Uint8Array([60,47,115,116,121,108,101]),TitleEnd:new Uint8Array([60,47,116,105,116,108,101]),TextareaEnd:new Uint8Array([60,47,116,101,120,116,97,114,101,97])};class wt{constructor(e,t){this.stack=e,this.cbs=t,this.state=1,this.buffer="",this.sectionStart=0,this.index=0,this.entityStart=0,this.baseState=1,this.inRCDATA=!1,this.inXML=!1,this.inVPre=!1,this.newlines=[],this.mode=0,this.delimiterOpen=pt,this.delimiterClose=ft,this.delimiterIndex=-1,this.currentSequence=void 0,this.sequenceIndex=0}get inSFCRoot(){return 2===this.mode&&0===this.stack.length}reset(){this.state=1,this.mode=0,this.buffer="",this.sectionStart=0,this.index=0,this.baseState=1,this.inRCDATA=!1,this.currentSequence=void 0,this.newlines.length=0,this.delimiterOpen=pt,this.delimiterClose=ft}getPos(e){let t=1,n=e+1;const r=this.newlines.length;let i=-1;if(r>100){let t=-1,n=r;while(t+1<n){const r=t+n>>>1;this.newlines[r]<e?t=r:n=r}i=t}else for(let o=r-1;o>=0;o--)if(e>this.newlines[o]){i=o;break}return i>=0&&(t=i+2,n=e-this.newlines[i]),{column:n,line:t,offset:e}}peek(){return this.buffer.charCodeAt(this.index+1)}stateText(e){60===e?(this.index>this.sectionStart&&this.cbs.ontext(this.sectionStart,this.index),this.state=5,this.sectionStart=this.index):this.inVPre||e!==this.delimiterOpen[0]||(this.state=2,this.delimiterIndex=0,this.stateInterpolationOpen(e))}stateInterpolationOpen(e){if(e===this.delimiterOpen[this.delimiterIndex])if(this.delimiterIndex===this.delimiterOpen.length-1){const e=this.index+1-this.delimiterOpen.length;e>this.sectionStart&&this.cbs.ontext(this.sectionStart,e),this.state=3,this.sectionStart=e}else this.delimiterIndex++;else this.inRCDATA?(this.state=32,this.stateInRCDATA(e)):(this.state=1,this.stateText(e))}stateInterpolation(e){e===this.delimiterClose[0]&&(this.state=4,this.delimiterIndex=0,this.stateInterpolationClose(e))}stateInterpolationClose(e){e===this.delimiterClose[this.delimiterIndex]?this.delimiterIndex===this.delimiterClose.length-1?(this.cbs.oninterpolation(this.sectionStart,this.index+1),this.inRCDATA?this.state=32:this.state=1,this.sectionStart=this.index+1):this.delimiterIndex++:(this.state=3,this.stateInterpolation(e))}stateSpecialStartSequence(e){const t=this.sequenceIndex===this.currentSequence.length,n=t?vt(e):(32|e)===this.currentSequence[this.sequenceIndex];if(n){if(!t)return void this.sequenceIndex++}else this.inRCDATA=!1;this.sequenceIndex=0,this.state=6,this.stateInTagName(e)}stateInRCDATA(e){if(this.sequenceIndex===this.currentSequence.length){if(62===e||gt(e)){const t=this.index-this.currentSequence.length;if(this.sectionStart<t){const e=this.index;this.index=t,this.cbs.ontext(this.sectionStart,t),this.index=e}return this.sectionStart=t+2,this.stateInClosingTagName(e),void(this.inRCDATA=!1)}this.sequenceIndex=0}(32|e)===this.currentSequence[this.sequenceIndex]?this.sequenceIndex+=1:0===this.sequenceIndex?this.currentSequence===yt.TitleEnd||this.currentSequence===yt.TextareaEnd&&!this.inSFCRoot?this.inVPre||e!==this.delimiterOpen[0]||(this.state=2,this.delimiterIndex=0,this.stateInterpolationOpen(e)):this.fastForwardTo(60)&&(this.sequenceIndex=1):this.sequenceIndex=Number(60===e)}stateCDATASequence(e){e===yt.Cdata[this.sequenceIndex]?++this.sequenceIndex===yt.Cdata.length&&(this.state=28,this.currentSequence=yt.CdataEnd,this.sequenceIndex=0,this.sectionStart=this.index+1):(this.sequenceIndex=0,this.state=23,this.stateInDeclaration(e))}fastForwardTo(e){while(++this.index<this.buffer.length){const t=this.buffer.charCodeAt(this.index);if(10===t&&this.newlines.push(this.index),t===e)return!0}return this.index=this.buffer.length-1,!1}stateInCommentLike(e){e===this.currentSequence[this.sequenceIndex]?++this.sequenceIndex===this.currentSequence.length&&(this.currentSequence===yt.CdataEnd?this.cbs.oncdata(this.sectionStart,this.index-2):this.cbs.oncomment(this.sectionStart,this.index-2),this.sequenceIndex=0,this.sectionStart=this.index+1,this.state=1):0===this.sequenceIndex?this.fastForwardTo(this.currentSequence[0])&&(this.sequenceIndex=1):e!==this.currentSequence[this.sequenceIndex-1]&&(this.sequenceIndex=0)}startSpecial(e,t){this.enterRCDATA(e,t),this.state=31}enterRCDATA(e,t){this.inRCDATA=!0,this.currentSequence=e,this.sequenceIndex=t}stateBeforeTagName(e){33===e?(this.state=22,this.sectionStart=this.index+1):63===e?(this.state=24,this.sectionStart=this.index+1):mt(e)?(this.sectionStart=this.index,0===this.mode?this.state=6:this.inSFCRoot?this.state=34:this.inXML?this.state=6:this.state=116===e?30:115===e?29:6):47===e?this.state=8:(this.state=1,this.stateText(e))}stateInTagName(e){vt(e)&&this.handleTagName(e)}stateInSFCRootTagName(e){if(vt(e)){const t=this.buffer.slice(this.sectionStart,this.index);"template"!==t&&this.enterRCDATA(bt("</"+t),0),this.handleTagName(e)}}handleTagName(e){this.cbs.onopentagname(this.sectionStart,this.index),this.sectionStart=-1,this.state=11,this.stateBeforeAttrName(e)}stateBeforeClosingTagName(e){gt(e)||(62===e?(this.state=1,this.sectionStart=this.index+1):(this.state=mt(e)?9:27,this.sectionStart=this.index))}stateInClosingTagName(e){(62===e||gt(e))&&(this.cbs.onclosetag(this.sectionStart,this.index),this.sectionStart=-1,this.state=10,this.stateAfterClosingTagName(e))}stateAfterClosingTagName(e){62===e&&(this.state=1,this.sectionStart=this.index+1)}stateBeforeAttrName(e){62===e?(this.cbs.onopentagend(this.index),this.inRCDATA?this.state=32:this.state=1,this.sectionStart=this.index+1):47===e?this.state=7:60===e&&47===this.peek()?(this.cbs.onopentagend(this.index),this.state=5,this.sectionStart=this.index):gt(e)||this.handleAttrStart(e)}handleAttrStart(e){118===e&&45===this.peek()?(this.state=13,this.sectionStart=this.index):46===e||58===e||64===e||35===e?(this.cbs.ondirname(this.index,this.index+1),this.state=14,this.sectionStart=this.index+1):(this.state=12,this.sectionStart=this.index)}stateInSelfClosingTag(e){62===e?(this.cbs.onselfclosingtag(this.index),this.state=1,this.sectionStart=this.index+1,this.inRCDATA=!1):gt(e)||(this.state=11,this.stateBeforeAttrName(e))}stateInAttrName(e){(61===e||vt(e))&&(this.cbs.onattribname(this.sectionStart,this.index),this.handleAttrNameEnd(e))}stateInDirName(e){61===e||vt(e)?(this.cbs.ondirname(this.sectionStart,this.index),this.handleAttrNameEnd(e)):58===e?(this.cbs.ondirname(this.sectionStart,this.index),this.state=14,this.sectionStart=this.index+1):46===e&&(this.cbs.ondirname(this.sectionStart,this.index),this.state=16,this.sectionStart=this.index+1)}stateInDirArg(e){61===e||vt(e)?(this.cbs.ondirarg(this.sectionStart,this.index),this.handleAttrNameEnd(e)):91===e?this.state=15:46===e&&(this.cbs.ondirarg(this.sectionStart,this.index),this.state=16,this.sectionStart=this.index+1)}stateInDynamicDirArg(e){93===e?this.state=14:(61===e||vt(e))&&(this.cbs.ondirarg(this.sectionStart,this.index+1),this.handleAttrNameEnd(e))}stateInDirModifier(e){61===e||vt(e)?(this.cbs.ondirmodifier(this.sectionStart,this.index),this.handleAttrNameEnd(e)):46===e&&(this.cbs.ondirmodifier(this.sectionStart,this.index),this.sectionStart=this.index+1)}handleAttrNameEnd(e){this.sectionStart=this.index,this.state=17,this.cbs.onattribnameend(this.index),this.stateAfterAttrName(e)}stateAfterAttrName(e){61===e?this.state=18:47===e||62===e?(this.cbs.onattribend(0,this.sectionStart),this.sectionStart=-1,this.state=11,this.stateBeforeAttrName(e)):gt(e)||(this.cbs.onattribend(0,this.sectionStart),this.handleAttrStart(e))}stateBeforeAttrValue(e){34===e?(this.state=19,this.sectionStart=this.index+1):39===e?(this.state=20,this.sectionStart=this.index+1):gt(e)||(this.sectionStart=this.index,this.state=21,this.stateInAttrValueNoQuotes(e))}handleInAttrValue(e,t){(e===t||this.fastForwardTo(t))&&(this.cbs.onattribdata(this.sectionStart,this.index),this.sectionStart=-1,this.cbs.onattribend(34===t?3:2,this.index+1),this.state=11)}stateInAttrValueDoubleQuotes(e){this.handleInAttrValue(e,34)}stateInAttrValueSingleQuotes(e){this.handleInAttrValue(e,39)}stateInAttrValueNoQuotes(e){gt(e)||62===e?(this.cbs.onattribdata(this.sectionStart,this.index),this.sectionStart=-1,this.cbs.onattribend(1,this.index),this.state=11,this.stateBeforeAttrName(e)):39!==e&&60!==e&&61!==e&&96!==e||this.cbs.onerr(18,this.index)}stateBeforeDeclaration(e){91===e?(this.state=26,this.sequenceIndex=0):this.state=45===e?25:23}stateInDeclaration(e){(62===e||this.fastForwardTo(62))&&(this.state=1,this.sectionStart=this.index+1)}stateInProcessingInstruction(e){(62===e||this.fastForwardTo(62))&&(this.cbs.onprocessinginstruction(this.sectionStart,this.index),this.state=1,this.sectionStart=this.index+1)}stateBeforeComment(e){45===e?(this.state=28,this.currentSequence=yt.CommentEnd,this.sequenceIndex=2,this.sectionStart=this.index+1):this.state=23}stateInSpecialComment(e){(62===e||this.fastForwardTo(62))&&(this.cbs.oncomment(this.sectionStart,this.index),this.state=1,this.sectionStart=this.index+1)}stateBeforeSpecialS(e){e===yt.ScriptEnd[3]?this.startSpecial(yt.ScriptEnd,4):e===yt.StyleEnd[3]?this.startSpecial(yt.StyleEnd,4):(this.state=6,this.stateInTagName(e))}stateBeforeSpecialT(e){e===yt.TitleEnd[3]?this.startSpecial(yt.TitleEnd,4):e===yt.TextareaEnd[3]?this.startSpecial(yt.TextareaEnd,4):(this.state=6,this.stateInTagName(e))}startEntity(){}stateInEntity(){}parse(e){this.buffer=e;while(this.index<this.buffer.length){const e=this.buffer.charCodeAt(this.index);switch(10===e&&33!==this.state&&this.newlines.push(this.index),this.state){case 1:this.stateText(e);break;case 2:this.stateInterpolationOpen(e);break;case 3:this.stateInterpolation(e);break;case 4:this.stateInterpolationClose(e);break;case 31:this.stateSpecialStartSequence(e);break;case 32:this.stateInRCDATA(e);break;case 26:this.stateCDATASequence(e);break;case 19:this.stateInAttrValueDoubleQuotes(e);break;case 12:this.stateInAttrName(e);break;case 13:this.stateInDirName(e);break;case 14:this.stateInDirArg(e);break;case 15:this.stateInDynamicDirArg(e);break;case 16:this.stateInDirModifier(e);break;case 28:this.stateInCommentLike(e);break;case 27:this.stateInSpecialComment(e);break;case 11:this.stateBeforeAttrName(e);break;case 6:this.stateInTagName(e);break;case 34:this.stateInSFCRootTagName(e);break;case 9:this.stateInClosingTagName(e);break;case 5:this.stateBeforeTagName(e);break;case 17:this.stateAfterAttrName(e);break;case 20:this.stateInAttrValueSingleQuotes(e);break;case 18:this.stateBeforeAttrValue(e);break;case 8:this.stateBeforeClosingTagName(e);break;case 10:this.stateAfterClosingTagName(e);break;case 29:this.stateBeforeSpecialS(e);break;case 30:this.stateBeforeSpecialT(e);break;case 21:this.stateInAttrValueNoQuotes(e);break;case 7:this.stateInSelfClosingTag(e);break;case 23:this.stateInDeclaration(e);break;case 22:this.stateBeforeDeclaration(e);break;case 25:this.stateBeforeComment(e);break;case 24:this.stateInProcessingInstruction(e);break;case 33:this.stateInEntity();break}this.index++}this.cleanup(),this.finish()}cleanup(){this.sectionStart!==this.index&&(1===this.state||32===this.state&&0===this.sequenceIndex?(this.cbs.ontext(this.sectionStart,this.index),this.sectionStart=this.index):19!==this.state&&20!==this.state&&21!==this.state||(this.cbs.onattribdata(this.sectionStart,this.index),this.sectionStart=this.index))}finish(){this.handleTrailingData(),this.cbs.onend()}handleTrailingData(){const e=this.buffer.length;this.sectionStart>=e||(28===this.state?this.currentSequence===yt.CdataEnd?this.cbs.oncdata(this.sectionStart,e):this.cbs.oncomment(this.sectionStart,e):6===this.state||11===this.state||18===this.state||17===this.state||12===this.state||13===this.state||14===this.state||15===this.state||16===this.state||20===this.state||19===this.state||21===this.state||9===this.state||this.cbs.ontext(this.sectionStart,e))}emitCodePoint(e,t){}}function Ot(e,{compatConfig:t}){const n=t&&t[e];return"MODE"===e?n||3:n}function St(e,t){const n=Ot("MODE",t),r=Ot(e,t);return 3===n?!0===r:!1!==r}function Et(e,t,n,...r){const i=St(e,t);return i}function xt(e){throw e}function _t(e){}function kt(e,t,n,r){const i=`https://vuejs.org/error-reference/#compiler-${e}`,o=new SyntaxError(String(i));return o.code=e,o.loc=t,o}const Ct=e=>4===e.type&&e.isStatic;function At(e){switch(e){case"Teleport":case"teleport":return de;case"Suspense":case"suspense":return he;case"KeepAlive":case"keep-alive":return pe;case"BaseTransition":case"base-transition":return fe}}const Tt=/^$|^\d|[^\$\w\xA0-\uFFFF]/,Rt=e=>!Tt.test(e),Nt=/[A-Za-z_$\xA0-\uFFFF]/,Pt=/[\.\?\w$\xA0-\uFFFF]/,It=/\s+[.[]\s*|\s*[.[]\s+/g,Mt=e=>4===e.type?e.content:e.loc.source,Dt=e=>{const t=Mt(e).trim().replace(It,e=>e.trim());let n=0,r=[],i=0,o=0,a=null;for(let s=0;s<t.length;s++){const e=t.charAt(s);switch(n){case 0:if("["===e)r.push(n),n=1,i++;else if("("===e)r.push(n),n=2,o++;else if(!(0===s?Nt:Pt).test(e))return!1;break;case 1:"'"===e||'"'===e||"`"===e?(r.push(n),n=3,a=e):"["===e?i++:"]"===e&&(--i||(n=r.pop()));break;case 2:if("'"===e||'"'===e||"`"===e)r.push(n),n=3,a=e;else if("("===e)o++;else if(")"===e){if(s===t.length-1)return!1;--o||(n=r.pop())}break;case 3:e===a&&(n=r.pop(),a=null);break}}return!i&&!o},Lt=Dt,Bt=/^\s*(?:async\s*)?(?:\([^)]*?\)|[\w$_]+)\s*(?::[^=]+)?=>|^\s*(?:async\s+)?function(?:\s+[\w$]+)?\s*\(/,$t=e=>Bt.test(Mt(e)),Vt=$t;function Ft(e,t,n=!1){for(let r=0;r<e.props.length;r++){const i=e.props[r];if(7===i.type&&(n||i.exp)&&(S(t)?i.name===t:t.test(i.name)))return i}}function jt(e,t,n=!1,r=!1){for(let i=0;i<e.props.length;i++){const o=e.props[i];if(6===o.type){if(n)continue;if(o.name===t&&(o.value||r))return o}else if("bind"===o.name&&(o.exp||r)&&Ut(o.arg,t))return o}}function Ut(e,t){return!(!e||!Ct(e)||e.content!==t)}function Gt(e){return e.props.some(e=>7===e.type&&"bind"===e.name&&(!e.arg||4!==e.arg.type||!e.arg.isStatic))}function Ht(e){return 5===e.type||2===e.type}function qt(e){return 7===e.type&&"pre"===e.name}function Qt(e){return 7===e.type&&"slot"===e.name}function zt(e){return 1===e.type&&3===e.tagType}function Kt(e){return 1===e.type&&2===e.tagType}const Wt=new Set([De,Le]);function Xt(e,t=[]){if(e&&!S(e)&&14===e.type){const n=e.callee;if(!S(n)&&Wt.has(n))return Xt(e.arguments[0],t.concat(e))}return[e,t]}function Yt(e,t,n){if(13!==e.type&&Zt(e,t))return;let r,i,o=13===e.type?e.props:e.arguments[2],a=[];if(o&&!S(o)&&14===o.type){const e=Xt(o);o=e[0],a=e[1],i=a[a.length-1]}if(null==o||S(o))r=tt([t]);else if(14===o.type){const e=o.arguments[0];S(e)||15!==e.type?o.callee===Be?r=ot(n.helper(Pe),[tt([t]),o]):o.arguments.unshift(tt([t])):Jt(t,e)||e.properties.unshift(t),!r&&(r=o)}else 15===o.type?(Jt(t,o)||o.properties.unshift(t),r=o):(r=ot(n.helper(Pe),[tt([t]),o]),i&&i.callee===Le&&(i=a[a.length-2]));13===e.type?i?i.arguments[0]=r:e.props=r:i?i.arguments[0]=r:e.arguments[2]=r}function Zt(e,t){var n,r,i;if(4!==t.key.type||"key"!==t.key.content)return!1;const o=e.arguments[2];if(o&&!S(o)){const[e]=Xt(o);if(e&&!S(e)&&15===e.type&&Jt(t,e))return!0}return(n=e.arguments)[2]||(n[2]="{}"),(r=e.arguments)[3]||(r[3]="undefined"),(i=e.arguments)[4]||(i[4]="undefined"),e.arguments[5]=t.value,!0}function Jt(e,t){let n=!1;if(4===e.key.type){const r=e.key.content;n=t.properties.some(e=>4===e.key.type&&e.key.content===r)}return n}function en(e,t){return`_${t}_${e.replace(/[^\w]/g,(t,n)=>"-"===t?"_":e.charCodeAt(n).toString())}`}function tn(e){return 14===e.type&&e.callee===ze?e.arguments[1].returns:e}const nn=/([\s\S]*?)\s+(?:in|of)\s+(\S[\s\S]*)/;function rn(e){for(let t=0;t<e.length;t++)if(!gt(e.charCodeAt(t)))return!1;return!0}function on(e){return 2===e.type&&rn(e.content)||12===e.type&&on(e.content)}function an(e){return 3===e.type||on(e)}const sn={parseMode:"base",ns:0,delimiters:["{{","}}"],getNamespace:()=>0,isVoidTag:c,isPreTag:c,isIgnoreNewlineTag:c,isCustomElement:c,onError:xt,onWarn:_t,comments:!1,prefixIdentifiers:!1};let ln=sn,cn=null,un="",dn=null,hn=null,pn="",fn=-1,mn=-1,gn=0,vn=!1,bn=null;const yn=[],wn=new wt(yn,{onerr:Hn,ontext(e,t){kn(xn(e,t),e,t)},ontextentity(e,t,n){kn(e,t,n)},oninterpolation(e,t){if(vn)return kn(xn(e,t),e,t);let n=e+wn.delimiterOpen.length,r=t-wn.delimiterClose.length;while(gt(un.charCodeAt(n)))n++;while(gt(un.charCodeAt(r-1)))r--;let i=xn(n,r);i.includes("&")&&(i=ln.decodeEntities(i,!1)),$n({type:5,content:Gn(i,!1,Vn(n,r)),loc:Vn(e,t)})},onopentagname(e,t){const n=xn(e,t);dn={type:1,tag:n,ns:ln.getNamespace(n,yn[0],ln.ns),tagType:0,props:[],children:[],loc:Vn(e-1,t),codegenNode:void 0}},onopentagend(e){_n(e)},onclosetag(e,t){const n=xn(e,t);if(!ln.isVoidTag(n)){let r=!1;for(let e=0;e<yn.length;e++){const i=yn[e];if(i.tag.toLowerCase()===n.toLowerCase()){r=!0,e>0&&Hn(24,yn[0].loc.start.offset);for(let n=0;n<=e;n++){const r=yn.shift();Cn(r,t,n<e)}break}}r||Hn(23,Tn(e,60))}},onselfclosingtag(e){const t=dn.tag;dn.isSelfClosing=!0,_n(e),yn[0]&&yn[0].tag===t&&Cn(yn.shift(),e)},onattribname(e,t){hn={type:6,name:xn(e,t),nameLoc:Vn(e,t),value:void 0,loc:Vn(e)}},ondirname(e,t){const n=xn(e,t),r="."===n||":"===n?"bind":"@"===n?"on":"#"===n?"slot":n.slice(2);if(vn||""!==r||Hn(26,e),vn||""===r)hn={type:6,name:n,nameLoc:Vn(e,t),value:void 0,loc:Vn(e)};else if(hn={type:7,name:r,rawName:n,exp:void 0,arg:void 0,modifiers:"."===n?[rt("prop")]:[],loc:Vn(e)},"pre"===r){vn=wn.inVPre=!0,bn=dn;const e=dn.props;for(let t=0;t<e.length;t++)7===e[t].type&&(e[t]=Un(e[t]))}},ondirarg(e,t){if(e===t)return;const n=xn(e,t);if(vn&&!qt(hn))hn.name+=n,jn(hn.nameLoc,t);else{const r="["!==n[0];hn.arg=Gn(r?n:n.slice(1,-1),r,Vn(e,t),r?3:0)}},ondirmodifier(e,t){const n=xn(e,t);if(vn&&!qt(hn))hn.name+="."+n,jn(hn.nameLoc,t);else if("slot"===hn.name){const e=hn.arg;e&&(e.content+="."+n,jn(e.loc,t))}else{const r=rt(n,!0,Vn(e,t));hn.modifiers.push(r)}},onattribdata(e,t){pn+=xn(e,t),fn<0&&(fn=e),mn=t},onattribentity(e,t,n){pn+=e,fn<0&&(fn=t),mn=n},onattribnameend(e){const t=hn.loc.start.offset,n=xn(t,e);7===hn.type&&(hn.rawName=n),dn.props.some(e=>(7===e.type?e.rawName:e.name)===n)&&Hn(2,t)},onattribend(e,t){if(dn&&hn){if(jn(hn.loc,t),0!==e)if(pn.includes("&")&&(pn=ln.decodeEntities(pn,!0)),6===hn.type)"class"===hn.name&&(pn=Bn(pn).trim()),1!==e||pn||Hn(13,t),hn.value={type:2,content:pn,loc:1===e?Vn(fn,mn):Vn(fn-1,mn+1)},wn.inSFCRoot&&"template"===dn.tag&&"lang"===hn.name&&pn&&"html"!==pn&&wn.enterRCDATA(bt("</template"),0);else{let e=0;hn.exp=Gn(pn,!1,Vn(fn,mn),0,e),"for"===hn.name&&(hn.forParseResult=En(hn.exp));let t=-1;"bind"===hn.name&&(t=hn.modifiers.findIndex(e=>"sync"===e.content))>-1&&Et("COMPILER_V_BIND_SYNC",ln,hn.loc,hn.arg.loc.source)&&(hn.name="model",hn.modifiers.splice(t,1))}7===hn.type&&"pre"===hn.name||dn.props.push(hn)}pn="",fn=mn=-1},oncomment(e,t){ln.comments&&$n({type:3,content:xn(e,t),loc:Vn(e-4,t+3)})},onend(){const e=un.length;for(let t=0;t<yn.length;t++)Cn(yn[t],e-1),Hn(24,yn[t].loc.start.offset)},oncdata(e,t){0!==(yn[0]?yn[0].ns:ln.ns)?kn(xn(e,t),e,t):Hn(1,e-9)},onprocessinginstruction(e){0===(yn[0]?yn[0].ns:ln.ns)&&Hn(21,e-1)}}),On=/,([^,\}\]]*)(?:,([^,\}\]]*))?$/,Sn=/^\(|\)$/g;function En(e){const t=e.loc,n=e.content,r=n.match(nn);if(!r)return;const[,i,o]=r,a=(e,n,r=!1)=>{const i=t.start.offset+n,o=i+e.length;return Gn(e,!1,Vn(i,o),0,r?1:0)},s={source:a(o.trim(),n.indexOf(o,i.length)),value:void 0,key:void 0,index:void 0,finalized:!1};let l=i.trim().replace(Sn,"").trim();const c=i.indexOf(l),u=l.match(On);if(u){l=l.replace(On,"").trim();const e=u[1].trim();let t;if(e&&(t=n.indexOf(e,c+l.length),s.key=a(e,t,!0)),u[2]){const r=u[2].trim();r&&(s.index=a(r,n.indexOf(r,s.key?t+e.length:c+l.length),!0))}}return l&&(s.value=a(l,c,!0)),s}function xn(e,t){return un.slice(e,t)}function _n(e){wn.inSFCRoot&&(dn.innerLoc=Vn(e+1,e+1)),$n(dn);const{tag:t,ns:n}=dn;0===n&&ln.isPreTag(t)&&gn++,ln.isVoidTag(t)?Cn(dn,e):(yn.unshift(dn),1!==n&&2!==n||(wn.inXML=!0)),dn=null}function kn(e,t,n){{const t=yn[0]&&yn[0].tag;"script"!==t&&"style"!==t&&e.includes("&")&&(e=ln.decodeEntities(e,!1))}const r=yn[0]||cn,i=r.children[r.children.length-1];i&&2===i.type?(i.content+=e,jn(i.loc,n)):r.children.push({type:2,content:e,loc:Vn(t,n)})}function Cn(e,t,n=!1){jn(e.loc,n?Tn(t,60):An(t,62)+1),wn.inSFCRoot&&(e.children.length?e.innerLoc.end=h({},e.children[e.children.length-1].loc.end):e.innerLoc.end=h({},e.innerLoc.start),e.innerLoc.source=xn(e.innerLoc.start.offset,e.innerLoc.end.offset));const{tag:r,ns:i,children:o}=e;if(vn||("slot"===r?e.tagType=2:Nn(e)?e.tagType=3:Pn(e)&&(e.tagType=1)),wn.inRCDATA||(e.children=Dn(o)),0===i&&ln.isIgnoreNewlineTag(r)){const e=o[0];e&&2===e.type&&(e.content=e.content.replace(/^\r?\n/,""))}0===i&&ln.isPreTag(r)&&gn--,bn===e&&(vn=wn.inVPre=!1,bn=null),wn.inXML&&0===(yn[0]?yn[0].ns:ln.ns)&&(wn.inXML=!1);{const t=e.props;if(!wn.inSFCRoot&&St("COMPILER_NATIVE_TEMPLATE",ln)&&"template"===e.tag&&!Nn(e)){const t=yn[0]||cn,n=t.children.indexOf(e);t.children.splice(n,1,...e.children)}const n=t.find(e=>6===e.type&&"inline-template"===e.name);n&&Et("COMPILER_INLINE_TEMPLATE",ln,n.loc)&&e.children.length&&(n.value={type:2,content:xn(e.children[0].loc.start.offset,e.children[e.children.length-1].loc.end.offset),loc:n.loc})}}function An(e,t){let n=e;while(un.charCodeAt(n)!==t&&n<un.length-1)n++;return n}function Tn(e,t){let n=e;while(un.charCodeAt(n)!==t&&n>=0)n--;return n}const Rn=new Set(["if","else","else-if","for","slot"]);function Nn({tag:e,props:t}){if("template"===e)for(let n=0;n<t.length;n++)if(7===t[n].type&&Rn.has(t[n].name))return!0;return!1}function Pn({tag:e,props:t}){if(ln.isCustomElement(e))return!1;if("component"===e||In(e.charCodeAt(0))||At(e)||ln.isBuiltInComponent&&ln.isBuiltInComponent(e)||ln.isNativeTag&&!ln.isNativeTag(e))return!0;for(let n=0;n<t.length;n++){const e=t[n];if(6===e.type){if("is"===e.name&&e.value){if(e.value.content.startsWith("vue:"))return!0;if(Et("COMPILER_IS_ON_ELEMENT",ln,e.loc))return!0}}else if("bind"===e.name&&Ut(e.arg,"is")&&Et("COMPILER_IS_ON_ELEMENT",ln,e.loc))return!0}return!1}function In(e){return e>64&&e<91}const Mn=/\r\n/g;function Dn(e){const t="preserve"!==ln.whitespace;let n=!1;for(let r=0;r<e.length;r++){const i=e[r];if(2===i.type)if(gn)i.content=i.content.replace(Mn,"\n");else if(rn(i.content)){const o=e[r-1]&&e[r-1].type,a=e[r+1]&&e[r+1].type;!o||!a||t&&(3===o&&(3===a||1===a)||1===o&&(3===a||1===a&&Ln(i.content)))?(n=!0,e[r]=null):i.content=" "}else t&&(i.content=Bn(i.content))}return n?e.filter(Boolean):e}function Ln(e){for(let t=0;t<e.length;t++){const n=e.charCodeAt(t);if(10===n||13===n)return!0}return!1}function Bn(e){let t="",n=!1;for(let r=0;r<e.length;r++)gt(e.charCodeAt(r))?n||(t+=" ",n=!0):(t+=e[r],n=!1);return t}function $n(e){(yn[0]||cn).children.push(e)}function Vn(e,t){return{start:wn.getPos(e),end:null==t?t:wn.getPos(t),source:null==t?t:xn(e,t)}}function Fn(e){return Vn(e.start.offset,e.end.offset)}function jn(e,t){e.end=wn.getPos(t),e.source=xn(e.start.offset,t)}function Un(e){const t={type:6,name:e.rawName,nameLoc:Vn(e.loc.start.offset,e.loc.start.offset+e.rawName.length),value:void 0,loc:e.loc};if(e.exp){const n=e.exp.loc;n.end.offset<e.loc.end.offset&&(n.start.offset--,n.start.column--,n.end.offset++,n.end.column++),t.value={type:2,content:e.exp.content,loc:n}}return t}function Gn(e,t=!1,n,r=0,i=0){const o=rt(e,t,n,r);return o}function Hn(e,t,n){ln.onError(kt(e,Vn(t,t),void 0,n))}function qn(){wn.reset(),dn=null,hn=null,pn="",fn=-1,mn=-1,yn.length=0}function Qn(e,t){if(qn(),un=e,ln=h({},sn),t){let e;for(e in t)null!=t[e]&&(ln[e]=t[e])}wn.mode="html"===ln.parseMode?1:"sfc"===ln.parseMode?2:0,wn.inXML=1===ln.ns||2===ln.ns;const n=t&&t.delimiters;n&&(wn.delimiterOpen=bt(n[0]),wn.delimiterClose=bt(n[1]));const r=cn=Ze([],e);return wn.parse(un),r.loc=Vn(0,e.length),r.children=Dn(r.children),cn=null,r}function zn(e,t){Wn(e,void 0,t,!!Kn(e))}function Kn(e){const t=e.children.filter(e=>3!==e.type);return 1!==t.length||1!==t[0].type||Kt(t[0])?null:t[0]}function Wn(e,t,n,r=!1,i=!1){const{children:o}=e,a=[];for(let u=0;u<o.length;u++){const t=o[u];if(1===t.type&&0===t.tagType){const e=r?0:Xn(t,n);if(e>0){if(e>=2){t.codegenNode.patchFlag=-1,a.push(t);continue}}else{const e=t.codegenNode;if(13===e.type){const r=e.patchFlag;if((void 0===r||512===r||1===r)&&Jn(t,n)>=2){const r=er(t);r&&(e.props=n.hoist(r))}e.dynamicProps&&(e.dynamicProps=n.hoist(e.dynamicProps))}}}else if(12===t.type){const e=r?0:Xn(t,n);if(e>=2){14===t.codegenNode.type&&t.codegenNode.arguments.length>0&&t.codegenNode.arguments.push("-1"),a.push(t);continue}}if(1===t.type){const r=1===t.tagType;r&&n.scopes.vSlot++,Wn(t,e,n,!1,i),r&&n.scopes.vSlot--}else if(11===t.type)Wn(t,e,n,1===t.children.length,!0);else if(9===t.type)for(let r=0;r<t.branches.length;r++)Wn(t.branches[r],e,n,1===t.branches[r].children.length,i)}let s=!1;if(a.length===o.length&&1===e.type)if(0===e.tagType&&e.codegenNode&&13===e.codegenNode.type&&g(e.codegenNode.children))e.codegenNode.children=l(et(e.codegenNode.children)),s=!0;else if(1===e.tagType&&e.codegenNode&&13===e.codegenNode.type&&e.codegenNode.children&&!g(e.codegenNode.children)&&15===e.codegenNode.children.type){const t=c(e.codegenNode,"default");t&&(t.returns=l(et(t.returns)),s=!0)}else if(3===e.tagType&&t&&1===t.type&&1===t.tagType&&t.codegenNode&&13===t.codegenNode.type&&t.codegenNode.children&&!g(t.codegenNode.children)&&15===t.codegenNode.children.type){const n=Ft(e,"slot",!0),r=n&&n.arg&&c(t.codegenNode,n.arg);r&&(r.returns=l(et(r.returns)),s=!0)}if(!s)for(const u of a)u.codegenNode=n.cache(u.codegenNode);function l(e){const t=n.cache(e);return t.needArraySpread=!0,t}function c(e,t){if(e.children&&!g(e.children)&&15===e.children.type){const n=e.children.properties.find(e=>e.key===t||e.key.content===t);return n&&n.value}}a.length&&n.transformHoist&&n.transformHoist(o,n,e)}function Xn(e,t){const{constantCache:n}=t;switch(e.type){case 1:if(0!==e.tagType)return 0;const r=n.get(e);if(void 0!==r)return r;const i=e.codegenNode;if(13!==i.type)return 0;if(i.isBlock&&"svg"!==e.tag&&"foreignObject"!==e.tag&&"math"!==e.tag)return 0;if(void 0===i.patchFlag){let r=3;const o=Jn(e,t);if(0===o)return n.set(e,0),0;o<r&&(r=o);for(let i=0;i<e.children.length;i++){const o=Xn(e.children[i],t);if(0===o)return n.set(e,0),0;o<r&&(r=o)}if(r>1)for(let i=0;i<e.props.length;i++){const o=e.props[i];if(7===o.type&&"bind"===o.name&&o.exp){const i=Xn(o.exp,t);if(0===i)return n.set(e,0),0;i<r&&(r=i)}}if(i.isBlock){for(let t=0;t<e.props.length;t++){const r=e.props[t];if(7===r.type)return n.set(e,0),0}t.removeHelper(me),t.removeHelper(dt(t.inSSR,i.isComponent)),i.isBlock=!1,t.helper(ut(t.inSSR,i.isComponent))}return n.set(e,r),r}return n.set(e,0),0;case 2:case 3:return 3;case 9:case 11:case 10:return 0;case 5:case 12:return Xn(e.content,t);case 4:return e.constType;case 8:let o=3;for(let n=0;n<e.children.length;n++){const r=e.children[n];if(S(r)||E(r))continue;const i=Xn(r,t);if(0===i)return 0;i<o&&(o=i)}return o;case 20:return 2;default:return 0}}const Yn=new Set([Ie,Me,De,Le]);function Zn(e,t){if(14===e.type&&!S(e.callee)&&Yn.has(e.callee)){const n=e.arguments[0];if(4===n.type)return Xn(n,t);if(14===n.type)return Zn(n,t)}return 0}function Jn(e,t){let n=3;const r=er(e);if(r&&15===r.type){const{properties:e}=r;for(let r=0;r<e.length;r++){const{key:i,value:o}=e[r],a=Xn(i,t);if(0===a)return a;let s;if(a<n&&(n=a),s=4===o.type?Xn(o,t):14===o.type?Zn(o,t):0,0===s)return s;s<n&&(n=s)}}return n}function er(e){const t=e.codegenNode;if(13===t.type)return t.props}function tr(e,{filename:t="",prefixIdentifiers:n=!1,hoistStatic:r=!1,hmr:i=!1,cacheHandlers:o=!1,nodeTransforms:s=[],directiveTransforms:c={},transformHoist:u=null,isBuiltInComponent:d=l,isCustomElement:h=l,expressionPlugins:p=[],scopeId:f=null,slotted:m=!0,ssr:g=!1,inSSR:v=!1,ssrCssVars:b="",bindingMetadata:y=a,inline:w=!1,isTS:O=!1,onError:E=xt,onWarn:x=_t,compatConfig:_}){const k=t.replace(/\?.*$/,"").match(/([^/\\]+)\.\w+$/),C={filename:t,selfName:k&&$(D(k[1])),prefixIdentifiers:n,hoistStatic:r,hmr:i,cacheHandlers:o,nodeTransforms:s,directiveTransforms:c,transformHoist:u,isBuiltInComponent:d,isCustomElement:h,expressionPlugins:p,scopeId:f,slotted:m,ssr:g,inSSR:v,ssrCssVars:b,bindingMetadata:y,inline:w,isTS:O,onError:E,onWarn:x,compatConfig:_,root:e,helpers:new Map,components:new Set,directives:new Set,hoists:[],imports:[],cached:[],constantCache:new WeakMap,vForMemoKeyedNodes:new WeakSet,temps:0,identifiers:Object.create(null),scopes:{vFor:0,vSlot:0,vPre:0,vOnce:0},parent:null,grandParent:null,currentNode:e,childIndex:0,inVOnce:!1,helper(e){const t=C.helpers.get(e)||0;return C.helpers.set(e,t+1),e},removeHelper(e){const t=C.helpers.get(e);if(t){const n=t-1;n?C.helpers.set(e,n):C.helpers.delete(e)}},helperString(e){return`_${We[C.helper(e)]}`},replaceNode(e){C.parent.children[C.childIndex]=C.currentNode=e},removeNode(e){const t=C.parent.children,n=e?t.indexOf(e):C.currentNode?C.childIndex:-1;e&&e!==C.currentNode?C.childIndex>n&&(C.childIndex--,C.onNodeRemoved()):(C.currentNode=null,C.onNodeRemoved()),C.parent.children.splice(n,1)},onNodeRemoved:l,addIdentifiers(e){},removeIdentifiers(e){},hoist(e){S(e)&&(e=rt(e)),C.hoists.push(e);const t=rt(`_hoisted_${C.hoists.length}`,!1,e.loc,2);return t.hoisted=e,t},cache(e,t=!1,n=!1){const r=lt(C.cached.length,e,t,n);return C.cached.push(r),r}};return C.filters=new Set,C}function nr(e,t){const n=tr(e,t);or(e,n),t.hoistStatic&&zn(e,n),t.ssr||rr(e,n),e.helpers=new Set([...n.helpers.keys()]),e.components=[...n.components],e.directives=[...n.directives],e.imports=n.imports,e.hoists=n.hoists,e.temps=n.temps,e.cached=n.cached,e.transformed=!0,e.filters=[...n.filters]}function rr(e,t){const{helper:n}=t,{children:r}=e;if(1===r.length){const n=Kn(e);if(n&&n.codegenNode){const r=n.codegenNode;13===r.type&&ht(r,t),e.codegenNode=r}else e.codegenNode=r[0]}else if(r.length>1){let r=64;0,e.codegenNode=Je(t,n(ue),void 0,e.children,r,void 0,void 0,!0,void 0,!1)}}function ir(e,t){let n=0;const r=()=>{n--};for(;n<e.children.length;n++){const i=e.children[n];S(i)||(t.grandParent=t.parent,t.parent=e,t.childIndex=n,t.onNodeRemoved=r,or(i,t))}}function or(e,t){t.currentNode=e;const{nodeTransforms:n}=t,r=[];for(let o=0;o<n.length;o++){const i=n[o](e,t);if(i&&(g(i)?r.push(...i):r.push(i)),!t.currentNode)return;e=t.currentNode}switch(e.type){case 3:t.ssr||t.helper(we);break;case 5:t.ssr||t.helper(Ne);break;case 9:for(let n=0;n<e.branches.length;n++)or(e.branches[n],t);break;case 10:case 11:case 1:case 0:ir(e,t);break}t.currentNode=e;let i=r.length;while(i--)r[i]()}function ar(e,t){const n=S(e)?t=>t===e:t=>e.test(t);return(e,r)=>{if(1===e.type){const{props:i}=e;if(3===e.tagType&&i.some(Qt))return;const o=[];for(let a=0;a<i.length;a++){const s=i[a];if(7===s.type&&n(s.name)){i.splice(a,1),a--;const n=t(e,s,r);n&&o.push(n)}}return o}}}const sr="/*@__PURE__*/",lr=e=>`${We[e]}: _${We[e]}`;function cr(e,{mode:t="function",prefixIdentifiers:n="module"===t,sourceMap:r=!1,filename:i="template.vue.html",scopeId:o=null,optimizeImports:a=!1,runtimeGlobalName:s="Vue",runtimeModuleName:l="vue",ssrRuntimeModuleName:c="vue/server-renderer",ssr:u=!1,isTS:d=!1,inSSR:h=!1}){const p={mode:t,prefixIdentifiers:n,sourceMap:r,filename:i,scopeId:o,optimizeImports:a,runtimeGlobalName:s,runtimeModuleName:l,ssrRuntimeModuleName:c,ssr:u,isTS:d,inSSR:h,source:e.source,code:"",column:1,line:1,offset:0,indentLevel:0,pure:!1,map:void 0,helper(e){return`_${We[e]}`},push(e,t=-2,n){p.code+=e},indent(){f(++p.indentLevel)},deindent(e=!1){e?--p.indentLevel:f(--p.indentLevel)},newline(){f(p.indentLevel)}};function f(e){p.push("\n"+" ".repeat(e),0)}return p}function ur(e,t={}){const n=cr(e,t);t.onContextCreated&&t.onContextCreated(n);const{mode:r,push:i,prefixIdentifiers:o,indent:a,deindent:s,newline:l,scopeId:c,ssr:u}=n,d=Array.from(e.helpers),h=d.length>0,p=!o&&"module"!==r,f=n;dr(e,f);const m=u?"ssrRender":"render",g=u?["_ctx","_push","_parent","_attrs"]:["_ctx","_cache"],v=g.join(", ");if(i(`function ${m}(${v}) {`),a(),p&&(i("with (_ctx) {"),a(),h&&(i(`const { ${d.map(lr).join(", ")} } = _Vue\n`,-1),l())),e.components.length&&(hr(e.components,"component",n),(e.directives.length||e.temps>0)&&l()),e.directives.length&&(hr(e.directives,"directive",n),e.temps>0&&l()),e.filters&&e.filters.length&&(l(),hr(e.filters,"filter",n),l()),e.temps>0){i("let ");for(let t=0;t<e.temps;t++)i(`${t>0?", ":""}_temp${t}`)}return(e.components.length||e.directives.length||e.temps)&&(i("\n",0),l()),u||i("return "),e.codegenNode?gr(e.codegenNode,n):i("null"),p&&(s(),i("}")),s(),i("}"),{ast:e,code:n.code,preamble:"",map:n.map?n.map.toJSON():void 0}}function dr(e,t){const{ssr:n,prefixIdentifiers:r,push:i,newline:o,runtimeModuleName:a,runtimeGlobalName:s,ssrRuntimeModuleName:l}=t,c=s,u=Array.from(e.helpers);if(u.length>0&&(i(`const _Vue = ${c}\n`,-1),e.hoists.length)){const e=[be,ye,we,Oe,Se].filter(e=>u.includes(e)).map(lr).join(", ");i(`const { ${e} } = _Vue\n`,-1)}pr(e.hoists,t),o(),i("return ")}function hr(e,t,{helper:n,push:r,newline:i,isTS:o}){const a=n("filter"===t?ke:"component"===t?Ee:_e);for(let s=0;s<e.length;s++){let n=e[s];const l=n.endsWith("__self");l&&(n=n.slice(0,-6)),r(`const ${en(n,t)} = ${a}(${JSON.stringify(n)}${l?", true":""})${o?"!":""}`),s<e.length-1&&i()}}function pr(e,t){if(!e.length)return;t.pure=!0;const{push:n,newline:r}=t;r();for(let i=0;i<e.length;i++){const o=e[i];o&&(n(`const _hoisted_${i+1} = `),gr(o,t),r())}t.pure=!1}function fr(e,t){const n=e.length>3||!1;t.push("["),n&&t.indent(),mr(e,t,n),n&&t.deindent(),t.push("]")}function mr(e,t,n=!1,r=!0){const{push:i,newline:o}=t;for(let a=0;a<e.length;a++){const s=e[a];S(s)?i(s,-3):g(s)?fr(s,t):gr(s,t),a<e.length-1&&(n?(r&&i(","),o()):r&&i(", "))}}function gr(e,t){if(S(e))t.push(e,-3);else if(E(e))t.push(t.helper(e));else switch(e.type){case 1:case 9:case 11:gr(e.codegenNode,t);break;case 2:vr(e,t);break;case 4:br(e,t);break;case 5:yr(e,t);break;case 12:gr(e.codegenNode,t);break;case 8:wr(e,t);break;case 3:Sr(e,t);break;case 13:Er(e,t);break;case 14:_r(e,t);break;case 15:kr(e,t);break;case 17:Cr(e,t);break;case 18:Ar(e,t);break;case 19:Tr(e,t);break;case 20:Rr(e,t);break;case 21:mr(e.body,t,!0,!1);break;case 22:break;case 23:break;case 24:break;case 25:break;case 26:break;case 10:break;default:0}}function vr(e,t){t.push(JSON.stringify(e.content),-3,e)}function br(e,t){const{content:n,isStatic:r}=e;t.push(r?JSON.stringify(n):n,-3,e)}function yr(e,t){const{push:n,helper:r,pure:i}=t;i&&n(sr),n(`${r(Ne)}(`),gr(e.content,t),n(")")}function wr(e,t){for(let n=0;n<e.children.length;n++){const r=e.children[n];S(r)?t.push(r,-3):gr(r,t)}}function Or(e,t){const{push:n}=t;if(8===e.type)n("["),wr(e,t),n("]");else if(e.isStatic){const t=Rt(e.content)?e.content:JSON.stringify(e.content);n(t,-2,e)}else n(`[${e.content}]`,-3,e)}function Sr(e,t){const{push:n,helper:r,pure:i}=t;i&&n(sr),n(`${r(we)}(${JSON.stringify(e.content)})`,-3,e)}function Er(e,t){const{push:n,helper:r,pure:i}=t,{tag:o,props:a,children:s,patchFlag:l,dynamicProps:c,directives:u,isBlock:d,disableTracking:h,isComponent:p}=e;let f;l&&(f=String(l)),u&&n(r(Ce)+"("),d&&n(`(${r(me)}(${h?"true":""}), `),i&&n(sr);const m=d?dt(t.inSSR,p):ut(t.inSSR,p);n(r(m)+"(",-2,e),mr(xr([o,a,s,f,c]),t),n(")"),d&&n(")"),u&&(n(", "),gr(u,t),n(")"))}function xr(e){let t=e.length;while(t--)if(null!=e[t])break;return e.slice(0,t+1).map(e=>e||"null")}function _r(e,t){const{push:n,helper:r,pure:i}=t,o=S(e.callee)?e.callee:r(e.callee);i&&n(sr),n(o+"(",-2,e),mr(e.arguments,t),n(")")}function kr(e,t){const{push:n,indent:r,deindent:i,newline:o}=t,{properties:a}=e;if(!a.length)return void n("{}",-2,e);const s=a.length>1||!1;n(s?"{":"{ "),s&&r();for(let l=0;l<a.length;l++){const{key:e,value:r}=a[l];Or(e,t),n(": "),gr(r,t),l<a.length-1&&(n(","),o())}s&&i(),n(s?"}":" }")}function Cr(e,t){fr(e.elements,t)}function Ar(e,t){const{push:n,indent:r,deindent:i}=t,{params:o,returns:a,body:s,newline:l,isSlot:c}=e;c&&n(`_${We[He]}(`),n("(",-2,e),g(o)?mr(o,t):o&&gr(o,t),n(") => "),(l||s)&&(n("{"),r()),a?(l&&n("return "),g(a)?fr(a,t):gr(a,t)):s&&gr(s,t),(l||s)&&(i(),n("}")),c&&(e.isNonScopedSlot&&n(", undefined, true"),n(")"))}function Tr(e,t){const{test:n,consequent:r,alternate:i,newline:o}=e,{push:a,indent:s,deindent:l,newline:c}=t;if(4===n.type){const e=!Rt(n.content);e&&a("("),br(n,t),e&&a(")")}else a("("),gr(n,t),a(")");o&&s(),t.indentLevel++,o||a(" "),a("? "),gr(r,t),t.indentLevel--,o&&c(),o||a(" "),a(": ");const u=19===i.type;u||t.indentLevel++,gr(i,t),u||t.indentLevel--,o&&l(!0)}function Rr(e,t){const{push:n,helper:r,indent:i,deindent:o,newline:a}=t,{needPauseTracking:s,needArraySpread:l}=e;l&&n("[...("),n(`_cache[${e.index}] || (`),s&&(i(),n(`${r(je)}(-1`),e.inVOnce&&n(", true"),n("),"),a(),n("(")),n(`_cache[${e.index}] = `),gr(e.value,t),s&&(n(`).cacheIndex = ${e.index},`),a(),n(`${r(je)}(1),`),a(),n(`_cache[${e.index}]`),o()),n(")"),l&&n(")]")}new RegExp("\\b"+"arguments,await,break,case,catch,class,const,continue,debugger,default,delete,do,else,export,extends,finally,for,function,if,import,let,new,return,super,switch,throw,try,var,void,while,with,yield".split(",").join("\\b|\\b")+"\\b");const Nr=ar(/^(?:if|else|else-if)$/,(e,t,n)=>Pr(e,t,n,(e,t,r)=>{const i=n.parent.children;let o=i.indexOf(e),a=0;while(o-- >=0){const e=i[o];e&&9===e.type&&(a+=e.branches.length)}return()=>{if(r)e.codegenNode=Mr(t,a,n);else{const r=Lr(e.codegenNode);r.alternate=Mr(t,a+e.branches.length-1,n)}}}));function Pr(e,t,n,r){if("else"!==t.name&&(!t.exp||!t.exp.content.trim())){const r=t.exp?t.exp.loc:e.loc;n.onError(kt(28,t.loc)),t.exp=rt("true",!1,r)}if("if"===t.name){const i=Ir(e,t),o={type:9,loc:Fn(e.loc),branches:[i]};if(n.replaceNode(o),r)return r(o,i,!0)}else{const i=n.parent.children;let o=i.indexOf(e);while(o-- >=-1){const a=i[o];if(!a||!an(a)){if(a&&9===a.type){"else-if"!==t.name&&"else"!==t.name||void 0!==a.branches[a.branches.length-1].condition||n.onError(kt(30,e.loc)),n.removeNode();const i=Ir(e,t);0,a.branches.push(i);const o=r&&r(a,i,!1);or(i,n),o&&o(),n.currentNode=null}else n.onError(kt(30,e.loc));break}n.removeNode(a)}}}function Ir(e,t){const n=3===e.tagType;return{type:10,loc:e.loc,condition:"else"===t.name?void 0:t.exp,children:n&&!Ft(e,"for")?e.children:[e],userKey:jt(e,"key"),isTemplateIf:n}}function Mr(e,t,n){return e.condition?st(e.condition,Dr(e,t,n),ot(n.helper(we),['""',"true"])):Dr(e,t,n)}function Dr(e,t,n){const{helper:r}=n,i=nt("key",rt(`${t}`,!1,Ye,2)),{children:o}=e,a=o[0],s=1!==o.length||1!==a.type;if(s){if(1===o.length&&11===a.type){const e=a.codegenNode;return Yt(e,i,n),e}{let t=64;return Je(n,r(ue),tt([i]),o,t,void 0,void 0,!0,!1,!1,e.loc)}}{const e=a.codegenNode,t=tn(e);return 13===t.type&&ht(t,n),Yt(t,i,n),e}}function Lr(e){while(1)if(19===e.type){if(19!==e.alternate.type)return e;e=e.alternate}else 20===e.type&&(e=e.value)}const Br=ar("for",(e,t,n)=>{const{helper:r,removeHelper:i}=n;return $r(e,t,n,t=>{const o=ot(r(Ae),[t.source]),a=zt(e),s=Ft(e,"memo"),l=jt(e,"key",!1,!0);l&&l.type;let c=l&&(6===l.type?l.value?rt(l.value.content,!0):void 0:l.exp);const u=c?nt("key",c):null,d=4===t.source.type&&t.source.constType>0,h=d?64:l?128:256;return t.codegenNode=Je(n,r(ue),void 0,o,h,void 0,void 0,!0,!d,!1,e.loc),()=>{var l;let h;const{children:p}=t;const f=1!==p.length||1!==p[0].type,m=Kt(e)?e:a&&1===e.children.length&&Kt(e.children[0])?e.children[0]:null;if(m)h=m.codegenNode,a&&u&&Yt(h,u,n);else if(f)h=Je(n,r(ue),u?tt([u]):void 0,e.children,64,void 0,void 0,!0,void 0,!1);else{h=p[0].codegenNode,a&&u&&Yt(h,u,n);const e=!d||!0===h.isBlockRequired;h.isBlock!==e&&(h.isBlock?(i(me),i(dt(n.inSSR,h.isComponent))):i(ut(n.inSSR,h.isComponent))),h.isBlock=e,h.isBlock?(r(me),r(dt(n.inSSR,h.isComponent))):(r(ut(n.inSSR,h.isComponent)),h.needsPatch&&(h.patchFlag=512|(null!=(l=h.patchFlag)?l:0)))}if(s){const e=at(Fr(t.parseResult,[rt("_cached")]));e.body=ct([it(["const _memo = (",s.exp,")"]),it(["if (_cached && _cached.el",...c?[" && _cached.key === ",c]:[],` && ${n.helperString(Ke)}(_cached, _memo)) return _cached`]),it(["const _item = ",h]),rt("_item.memo = _memo"),rt("return _item")]),o.arguments.push(e,rt("_cache"),rt(String(n.cached.length))),n.cached.push(null)}else o.arguments.push(at(Fr(t.parseResult),h,!0))}})});function $r(e,t,n,r){if(!t.exp)return void n.onError(kt(31,t.loc));const i=t.forParseResult;if(!i)return void n.onError(kt(32,t.loc));Vr(i,n);const{addIdentifiers:o,removeIdentifiers:a,scopes:s}=n,{source:l,value:c,key:u,index:d}=i,h={type:11,loc:t.loc,source:l,valueAlias:c,keyAlias:u,objectIndexAlias:d,parseResult:i,children:zt(e)?e.children:[e]};n.replaceNode(h),s.vFor++;const p=r&&r(h);return()=>{s.vFor--,p&&p()}}function Vr(e,t){e.finalized||(e.finalized=!0)}function Fr({value:e,key:t,index:n},r=[]){return jr([e,t,n,...r])}function jr(e){let t=e.length;while(t--)if(e[t])break;return e.slice(0,t+1).map((e,t)=>e||rt("_".repeat(t+1),!1))}const Ur=rt("undefined",!1),Gr=(e,t)=>{if(1===e.type&&(1===e.tagType||3===e.tagType)){const n=Ft(e,"slot");if(n)return n.exp,t.scopes.vSlot++,()=>{t.scopes.vSlot--}}},Hr=(e,t,n,r)=>at(e,n,!1,!0,n.length?n[0].loc:r);function qr(e,t,n=Hr){t.helper(He);const{children:r,loc:i}=e,o=[],a=[];let s=t.scopes.vSlot>0||t.scopes.vFor>0;const l=Ft(e,"slot",!0);if(l){const{arg:e,exp:t}=l;e&&!Ct(e)&&(s=!0),o.push(nt(e||rt("default",!0),n(t,void 0,r,i)))}let c=!1,u=!1;const d=[],h=new Set;let p=0;for(let g=0;g<r.length;g++){const e=r[g];let i;if(!zt(e)||!(i=Ft(e,"slot",!0))){3!==e.type&&d.push(e);continue}if(l){t.onError(kt(37,i.loc));break}c=!0;const{children:f,loc:m}=e,{arg:v=rt("default",!0),exp:b,loc:y}=i;let w;Ct(v)?w=v?v.content:"default":s=!0;const O=Ft(e,"for"),S=n(b,O,f,m);let E,x;if(E=Ft(e,"if"))s=!0,a.push(st(E.exp,Qr(v,S,p++),Ur));else if(x=Ft(e,/^else(?:-if)?$/,!0)){let e,n=g;while(n--)if(e=r[n],!an(e))break;if(e&&zt(e)&&Ft(e,/^(?:else-)?if$/)){let e=a[a.length-1];while(19===e.alternate.type)e=e.alternate;e.alternate=x.exp?st(x.exp,Qr(v,S,p++),Ur):Qr(v,S,p++)}else t.onError(kt(30,x.loc))}else if(O){s=!0;const e=O.forParseResult;e?(Vr(e,t),a.push(ot(t.helper(Ae),[e.source,at(Fr(e),Qr(v,S),!0)]))):t.onError(kt(32,O.loc))}else{if(w){if(h.has(w)){t.onError(kt(38,y));continue}h.add(w),"default"===w&&(u=!0)}o.push(nt(v,S))}}if(!l){const e=(e,r)=>{const o=n(e,void 0,r,i);return t.compatConfig&&(o.isNonScopedSlot=!0),nt("default",o)};c?d.length&&!d.every(on)&&(u?t.onError(kt(39,d[0].loc)):o.push(e(void 0,d))):o.push(e(void 0,r))}const f=s?2:zr(e.children)?3:1;let m=tt(o.concat(nt("_",rt(f+"",!1))),i);return a.length&&(m=ot(t.helper(Re),[m,et(a)])),{slots:m,hasDynamicSlots:s}}function Qr(e,t,n){const r=[nt("name",e),nt("fn",t)];return null!=n&&r.push(nt("key",rt(String(n),!0))),tt(r)}function zr(e){for(let t=0;t<e.length;t++){const n=e[t];switch(n.type){case 1:if(2===n.tagType||zr(n.children))return!0;break;case 9:if(zr(n.branches))return!0;break;case 10:case 11:if(zr(n.children))return!0;break}}return!1}const Kr=new WeakMap,Wr=(e,t)=>function(){if(e=t.currentNode,1!==e.type||0!==e.tagType&&1!==e.tagType)return;const{tag:n,props:r}=e,i=1===e.tagType;let o=i?Xr(e,t):`"${n}"`;const a=x(o)&&o.callee===xe;let s,l,c,u,d,h=0,p=!1,f=!1,m=a||o===de||o===he||!i&&("svg"===n||"foreignObject"===n||"math"===n);if(r.length>0){const n=Yr(e,t,void 0,i,a);s=n.props,h=n.patchFlag,u=n.dynamicPropNames,p=n.needsPatch,f=n.isBlockRequired;const r=n.directives;d=r&&r.length?et(r.map(e=>ei(e,t))):void 0,n.shouldUseBlock&&(m=!0)}if(e.children.length>0){o===pe&&(m=!0,h|=1024);const n=i&&o!==de&&o!==pe;if(n){const{slots:n,hasDynamicSlots:r}=qr(e,t);l=n,r&&(h|=1024)}else if(1===e.children.length&&o!==de){const n=e.children[0],r=n.type,i=5===r||8===r;i&&0===Xn(n,t)&&(h|=1),l=i||2===r?n:e.children}else l=e.children}u&&u.length&&(c=ti(u));const g=e.codegenNode=Je(t,o,s,l,0===h?void 0:h,c,d,!!m,!1,i,e.loc);p=p&&(0===h||32===h),p&&(g.needsPatch=!0),f&&(g.isBlockRequired=!0)};function Xr(e,t,n=!1){let{tag:r}=e;const i=ni(r),o=jt(e,"is",!1,!0);if(o)if(i||St("COMPILER_IS_ON_ELEMENT",t)){let e;if(6===o.type?e=o.value&&rt(o.value.content,!0):(e=o.exp,e||(e=rt("is",!1,o.arg.loc))),e)return ot(t.helper(xe),[e])}else 6===o.type&&o.value.content.startsWith("vue:")&&(r=o.value.content.slice(4));const a=At(r)||t.isBuiltInComponent(r);return a?(n||t.helper(a),a):(t.helper(Ee),t.components.add(r),en(r,"component"))}function Yr(e,t,n=e.props,r,i,o=!1){const{tag:a,loc:s,children:l}=e;let c=[];const d=[],h=[],p=l.length>0;let f=!1,m=!1,g=0,v=!1,b=!1,y=!1,w=!1,O=!1,S=!1;const x=[],_=e=>{c.length&&(d.push(tt(Zr(c),s)),c=[]),e&&d.push(e)},k=()=>{t.scopes.vFor>0&&c.push(nt(rt("ref_for",!0),rt("true")))},C=({key:e,value:n})=>{if(Ct(e)){const o=e.content,a=u(o);if(!a||r&&!i||"onclick"===o.toLowerCase()||"onUpdate:modelValue"===o||N(o)||(w=!0),a&&N(o)&&(S=!0),"ref"===o&&(v=!0),a&&14===n.type&&(n=n.arguments[0]),20===n.type||(4===n.type||8===n.type)&&Xn(n,t)>0)return;"class"===o?b=!0:"style"===o?y=!0:"ref"===o||"key"===o||x.includes(o)||x.push(o),!r||"class"!==o&&"style"!==o||x.includes(o)||x.push(o)}else O=!0};for(let u=0;u<n.length;u++){const i=n[u];if(6===i.type){const{loc:e,name:n,nameLoc:r,value:o}=i;let s=!0;if("ref"===n&&(v=!0,k()),"is"===n&&(ni(a)||o&&o.content.startsWith("vue:")||St("COMPILER_IS_ON_ELEMENT",t)))continue;c.push(nt(rt(n,!0,r),rt(o?o.content:"",s,o?o.loc:e)))}else{const{name:n,arg:l,exp:u,loc:v,modifiers:b}=i,y="bind"===n,w="on"===n;if("slot"===n){r||t.onError(kt(40,v));continue}if("once"===n||"memo"===n)continue;if("is"===n||y&&Ut(l,"is")&&(ni(a)||St("COMPILER_IS_ON_ELEMENT",t)))continue;if(w&&o)continue;if(y&&Ut(l,"key")&&(f=!0),w&&p&&l&&Ct(l)&&"vue:beforeUpdate"===D(l.content)&&(f=!0,m=!0),y&&Ut(l,"ref")&&k(),!l&&(y||w)){if(O=!0,u)if(y){if(_(),St("COMPILER_V_BIND_OBJECT_ORDER",t)){d.unshift(u);continue}k(),_(),d.push(u)}else _({type:14,loc:v,callee:t.helper(Be),arguments:r?[u]:[u,"true"]});else t.onError(kt(y?34:35,v));continue}y&&b.some(e=>"prop"===e.content)&&(g|=32);const S=t.directiveTransforms[n];if(S){const{props:n,needRuntime:r}=S(i,e,t);!o&&n.forEach(C),w&&l&&!Ct(l)?_(tt(n,s)):c.push(...n),r&&(h.push(i),E(r)&&Kr.set(i,r))}else P(n)||(h.push(i),p&&(f=!0,m=!0))}}let A;d.length?(_(),A=d.length>1?ot(t.helper(Pe),d,s):d[0]):c.length&&(A=tt(Zr(c),s)),O?g|=16:(b&&!r&&(g|=2),y&&!r&&(g|=4),x.length&&(g|=8),w&&(g|=32));const T=(0===g||32===g)&&(v||S||h.length>0);if(!f&&T&&(g|=512),!t.inSSR&&A)switch(A.type){case 15:let e=-1,n=-1,r=!1;for(let t=0;t<A.properties.length;t++){const i=A.properties[t].key;Ct(i)?"class"===i.content?e=t:"style"===i.content&&(n=t):i.isHandlerKey||(r=!0)}const i=A.properties[e],o=A.properties[n];r?A=ot(t.helper(De),[A]):(i&&!Ct(i.value)&&(i.value=ot(t.helper(Ie),[i.value])),o&&(y||4===o.value.type&&"["===o.value.content.trim()[0]||17===o.value.type)&&(o.value=ot(t.helper(Me),[o.value])));break;case 14:break;default:A=ot(t.helper(De),[ot(t.helper(Le),[A])]);break}return{props:A,directives:h,patchFlag:g,dynamicPropNames:x,shouldUseBlock:f,needsPatch:T,isBlockRequired:m}}function Zr(e){const t=new Map,n=[];for(let r=0;r<e.length;r++){const i=e[r];if(8===i.key.type||!i.key.isStatic){n.push(i);continue}const o=i.key.content,a=t.get(o);a?("style"===o||"class"===o||u(o))&&Jr(a,i):(t.set(o,i),n.push(i))}return n}function Jr(e,t){17===e.value.type?e.value.elements.push(t.value):e.value=et([e.value,t.value],e.loc)}function ei(e,t){const n=[],r=Kr.get(e);r?n.push(t.helperString(r)):(t.helper(_e),t.directives.add(e.name),n.push(en(e.name,"directive")));const{loc:i}=e;if(e.exp&&n.push(e.exp),e.arg&&(e.exp||n.push("void 0"),n.push(e.arg)),Object.keys(e.modifiers).length){e.arg||(e.exp||n.push("void 0"),n.push("void 0"));const t=rt("true",!1,i);n.push(tt(e.modifiers.map(e=>nt(e,t)),i))}return et(n,e.loc)}function ti(e){let t="[";for(let n=0,r=e.length;n<r;n++)t+=JSON.stringify(e[n]),n<r-1&&(t+=", ");return t+"]"}function ni(e){return"component"===e||"Component"===e}const ri=(e,t)=>{if(Kt(e)){const{children:n,loc:r}=e,{slotName:i,slotProps:o}=ii(e,t),a=[t.prefixIdentifiers?"_ctx.$slots":"$slots",i,"{}","undefined","true"];let s=2;o&&(a[2]=o,s=3),n.length&&(a[3]=at([],n,!1,!1,r),s=4),t.scopeId&&!t.slotted&&(s=5),a.splice(s),e.codegenNode=ot(t.helper(Te),a,r)}};function ii(e,t){let n,r='"default"';const i=[];for(let o=0;o<e.props.length;o++){const t=e.props[o];if(6===t.type)t.value&&("name"===t.name?r=JSON.stringify(t.value.content):(t.name=D(t.name),i.push(t)));else if("bind"===t.name&&Ut(t.arg,"name")){if(t.exp)r=t.exp;else if(t.arg&&4===t.arg.type){const e=D(t.arg.content);r=t.exp=rt(e,!1,t.arg.loc)}}else"bind"===t.name&&t.arg&&Ct(t.arg)&&(t.arg.content=D(t.arg.content)),i.push(t)}if(i.length>0){const{props:r,directives:o}=Yr(e,t,i,!1,!1);n=r,o.length&&t.onError(kt(36,o[0].loc))}return{slotName:r,slotProps:n}}const oi=(e,t,n,r)=>{const{loc:i,modifiers:o,arg:a}=e;let s;if(e.exp||o.length||n.onError(kt(35,i)),4===a.type)if(a.isStatic){let e=a.content;0,e.startsWith("vue:")&&(e=`vnode-${e.slice(4)}`);const n=0!==t.tagType||e.startsWith("vnode")||!/[A-Z]/.test(e)?V(D(e)):`on:${e}`;s=rt(n,!0,a.loc)}else s=it([`${n.helperString(Fe)}(`,a,")"]);else s=a,s.children.unshift(`${n.helperString(Fe)}(`),s.children.push(")");let l=e.exp;l&&!l.content.trim()&&(l=void 0);let c=n.cacheHandlers&&!l&&!n.inVOnce;if(l){const e=Lt(l),t=!(e||Vt(l)),n=l.content.includes(";");0,(t||c&&e)&&(l=it([`${t?"$event":"(...args)"} => ${n?"{":"("}`,l,n?"}":")"]))}let u={props:[nt(s,l||rt("() => {}",!1,i))]};return r&&(u=r(u)),c&&(u.props[0].value=n.cache(u.props[0].value)),u.props.forEach(e=>e.key.isHandlerKey=!0),u},ai=(e,t,n)=>{const{modifiers:r,loc:i}=e,o=e.arg;let{exp:a}=e;return a&&4===a.type&&!a.content.trim()&&(a=void 0),4!==o.type?(o.children.unshift("("),o.children.push(') || ""')):o.isStatic||(o.content=o.content?`${o.content} || ""`:'""'),r.some(e=>"camel"===e.content)&&(4===o.type?o.isStatic?o.content=D(o.content):o.content=`${n.helperString($e)}(${o.content})`:(o.children.unshift(`${n.helperString($e)}(`),o.children.push(")"))),n.inSSR||(r.some(e=>"prop"===e.content)&&si(o,"."),r.some(e=>"attr"===e.content)&&si(o,"^")),{props:[nt(o,a)]}},si=(e,t)=>{4===e.type?e.isStatic?e.content=t+e.content:e.content=`\`${t}\${${e.content}}\``:(e.children.unshift(`'${t}' + (`),e.children.push(")"))},li=(e,t)=>{if(0===e.type||1===e.type||11===e.type||10===e.type)return()=>{const n=e.children;let r,i=!1;for(let e=0;e<n.length;e++){const t=n[e];if(Ht(t)){i=!0;for(let i=e+1;i<n.length;i++){const o=n[i];if(!Ht(o)){r=void 0;break}r||(r=n[e]=it([t],t.loc)),r.children.push(" + ",o),n.splice(i,1),i--}}}if(i&&(1!==n.length||0!==e.type&&(1!==e.type||0!==e.tagType||e.props.find(e=>7===e.type&&!t.directiveTransforms[e.name])||"template"===e.tag)))for(let e=0;e<n.length;e++){const r=n[e];if(Ht(r)||8===r.type){const i=[];2===r.type&&" "===r.content||i.push(r),t.ssr||0!==Xn(r,t)||i.push("1"),n[e]={type:12,content:r,loc:r.loc,codegenNode:ot(t.helper(Oe),i)}}}}},ci=new WeakSet,ui=(e,t)=>{if(1===e.type&&Ft(e,"once",!0)){if(ci.has(e)||t.inVOnce||t.inSSR)return;return ci.add(e),t.inVOnce=!0,t.helper(je),()=>{t.inVOnce=!1;const e=t.currentNode;e.codegenNode&&(e.codegenNode=t.cache(e.codegenNode,!0,!0))}}},di=(e,t,n)=>{const{exp:r,arg:i}=e;if(!r)return n.onError(kt(41,e.loc)),hi();const o=r.loc.source.trim(),a=4===r.type?r.content:o,s=n.bindingMetadata[o];if("props"===s||"props-aliased"===s)return n.onError(kt(44,r.loc)),hi();if("literal-const"===s||"setup-const"===s)return n.onError(kt(45,r.loc)),hi();if(!a.trim()||!Lt(r))return n.onError(kt(42,r.loc)),hi();const l=i||rt("modelValue",!0),c=i?Ct(i)?`onUpdate:${D(i.content)}`:it(['"onUpdate:" + ',i]):"onUpdate:modelValue";let u;const d=n.isTS?"($event: any)":"$event";u=it([`${d} => ((`,r,") = $event)"]);const h=[nt(l,e.exp),nt(c,u)];if(e.modifiers.length&&1===t.tagType){const t=e.modifiers.map(e=>e.content).map(e=>(Rt(e)?e:JSON.stringify(e))+": true").join(", "),n=i?Ct(i)?`${i.content}Modifiers`:it([i,' + "Modifiers"']):"modelModifiers";h.push(nt(n,rt(`{ ${t} }`,!1,e.loc,2)))}return hi(h)};function hi(e=[]){return{props:e}}const pi=/[\w).+\-_$\]]/,fi=(e,t)=>{St("COMPILER_FILTERS",t)&&(5===e.type?mi(e.content,t):1===e.type&&e.props.forEach(e=>{7===e.type&&"for"!==e.name&&e.exp&&mi(e.exp,t)}))};function mi(e,t){if(4===e.type)gi(e,t);else for(let n=0;n<e.children.length;n++){const r=e.children[n];"object"===typeof r&&(4===r.type?gi(r,t):8===r.type?mi(r,t):5===r.type&&mi(r.content,t))}}function gi(e,t){const n=e.content;let r,i,o,a,s=!1,l=!1,c=!1,u=!1,d=0,h=0,p=0,f=0,m=[];for(o=0;o<n.length;o++)if(i=r,r=n.charCodeAt(o),s)39===r&&92!==i&&(s=!1);else if(l)34===r&&92!==i&&(l=!1);else if(c)96===r&&92!==i&&(c=!1);else if(u)47===r&&92!==i&&(u=!1);else if(124!==r||124===n.charCodeAt(o+1)||124===n.charCodeAt(o-1)||d||h||p){switch(r){case 34:l=!0;break;case 39:s=!0;break;case 96:c=!0;break;case 40:p++;break;case 41:p--;break;case 91:h++;break;case 93:h--;break;case 123:d++;break;case 125:d--;break}if(47===r){let e,t=o-1;for(;t>=0;t--)if(e=n.charAt(t)," "!==e)break;e&&pi.test(e)||(u=!0)}}else void 0===a?(f=o+1,a=n.slice(0,o).trim()):g();function g(){m.push(n.slice(f,o).trim()),f=o+1}if(void 0===a?a=n.slice(0,o).trim():0!==f&&g(),m.length){for(o=0;o<m.length;o++)a=vi(a,m[o],t);e.content=a,e.ast=void 0}}function vi(e,t,n){n.helper(ke);const r=t.indexOf("(");if(r<0)return n.filters.add(t),`${en(t,"filter")}(${e})`;{const i=t.slice(0,r),o=t.slice(r+1);return n.filters.add(i),`${en(i,"filter")}(${e}${")"!==o?","+o:o}`}}const bi=new WeakSet,yi=(e,t)=>{if(1===e.type){const n=Ft(e,"memo");if(!n||bi.has(e)||t.inSSR)return;return bi.add(e),()=>{const r=e.codegenNode||t.currentNode.codegenNode;r&&13===r.type&&(1!==e.tagType&&ht(r,t),e.codegenNode=ot(t.helper(ze),[n.exp,at(void 0,r),"_cache",String(t.cached.length)]),t.cached.push(null))}}},wi=(e,t)=>{if(1===e.type)for(const n of e.props)if(7===n.type&&"bind"===n.name&&(!n.exp||4===n.exp.type&&!n.exp.content.trim())&&n.arg){const e=n.arg;if(4===e.type&&e.isStatic){const t=D(e.content);(Nt.test(t[0])||"-"===t[0])&&(n.exp=rt(t,!1,e.loc))}else t.onError(kt(53,e.loc)),n.exp=rt("",!0,e.loc)}};function Oi(e){return[[wi,ui,Nr,yi,Br,fi,ri,Wr,Gr,li],{on:oi,bind:ai,model:di}]}function Si(e,t={}){const n=t.onError||xt,r="module"===t.mode;!0===t.prefixIdentifiers?n(kt(48)):r&&n(kt(49));const i=!1;t.cacheHandlers&&n(kt(50)),t.scopeId&&!r&&n(kt(51));const o=h({},t,{prefixIdentifiers:i}),a=S(e)?Qn(e,o):e,[s,l]=Oi();return nr(a,h({},o,{nodeTransforms:[...s,...t.nodeTransforms||[]],directiveTransforms:h({},l,t.directiveTransforms||{})})),ur(a,o)}const Ei=()=>({props:[]});
|
||
/**
|
||
* @vue/compiler-dom v3.5.42
|
||
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
||
* @license MIT
|
||
**/
|
||
const xi=Symbol(""),_i=Symbol(""),ki=Symbol(""),Ci=Symbol(""),Ai=Symbol(""),Ti=Symbol(""),Ri=Symbol(""),Ni=Symbol(""),Pi=Symbol(""),Ii=Symbol("");let Mi;function Di(e,t=!1){return Mi||(Mi=document.createElement("div")),t?(Mi.innerHTML=`<div foo="${e.replace(/"/g,""")}">`,Mi.children[0].getAttribute("foo")):(Mi.innerHTML=e,Mi.textContent)}Xe({[xi]:"vModelRadio",[_i]:"vModelCheckbox",[ki]:"vModelText",[Ci]:"vModelSelect",[Ai]:"vModelDynamic",[Ti]:"withModifiers",[Ri]:"withKeys",[Ni]:"vShow",[Pi]:"Transition",[Ii]:"TransitionGroup"});const Li={parseMode:"html",isVoidTag:oe,isNativeTag:e=>ne(e)||re(e)||ie(e),isPreTag:e=>"pre"===e,isIgnoreNewlineTag:e=>"pre"===e||"textarea"===e,decodeEntities:Di,isBuiltInComponent:e=>"Transition"===e||"transition"===e?Pi:"TransitionGroup"===e||"transition-group"===e?Ii:void 0,getNamespace(e,t,n){let r=t?t.ns:n;if(t&&2===r)if("annotation-xml"===t.tag){if("svg"===e)return 1;t.props.some(e=>6===e.type&&"encoding"===e.name&&null!=e.value&&("text/html"===e.value.content||"application/xhtml+xml"===e.value.content))&&(r=0)}else/^m(?:[ions]|text)$/.test(t.tag)&&"mglyph"!==e&&"malignmark"!==e&&(r=0);else t&&1===r&&("foreignObject"!==t.tag&&"desc"!==t.tag&&"title"!==t.tag||(r=0));if(0===r){if("svg"===e)return 1;if("math"===e)return 2}return r}},Bi=e=>{1===e.type&&e.props.forEach((t,n)=>{6===t.type&&"style"===t.name&&t.value&&(e.props[n]={type:7,name:"bind",arg:rt("style",!0,t.loc),exp:$i(t.value.content,t.loc),modifiers:[],loc:t.loc})})},$i=(e,t)=>{const n=X(e);return rt(JSON.stringify(n),!1,t,3)};function Vi(e,t){return kt(e,t,void 0)}const Fi=(e,t,n)=>{const{exp:r,loc:i}=e;return r||n.onError(Vi(54,i)),t.children.length&&(n.onError(Vi(55,i)),t.children.length=0),{props:[nt(rt("innerHTML",!0,i),r||rt("",!0))]}},ji=(e,t,n)=>{const{exp:r,loc:i}=e;return r||n.onError(Vi(56,i)),t.children.length&&(n.onError(Vi(57,i)),t.children.length=0),{props:[nt(rt("textContent",!0),r?Xn(r,n)>0?r:ot(n.helperString(Ne),[r],i):rt("",!0))]}},Ui=(e,t,n)=>{const r=di(e,t,n);if(!r.props.length||1===t.tagType)return r;e.arg&&n.onError(Vi(59,e.arg.loc));const{tag:i}=t,o=n.isCustomElement(i);if("input"===i||"textarea"===i||"select"===i||o){let a=ki,s=!1;if("input"===i||o){const r=jt(t,"type");if(r){if(7===r.type)a=Ai;else if(r.value)switch(r.value.content){case"radio":a=xi;break;case"checkbox":a=_i;break;case"file":s=!0,n.onError(Vi(60,e.loc));break;default:break}}else Gt(t)&&(a=Ai)}else"select"===i&&(a=Ci);s||(r.needRuntime=n.helper(a))}else n.onError(Vi(58,e.loc));return r.props=r.props.filter(e=>!(4===e.key.type&&"modelValue"===e.key.content)),r},Gi=o("passive,once,capture"),Hi=o("stop,prevent,self,ctrl,shift,alt,meta,exact,middle"),qi=o("left,right"),Qi=o("onkeyup,onkeydown,onkeypress"),zi=(e,t,n,r)=>{const i=[],o=[],a=[];for(let s=0;s<t.length;s++){const l=t[s].content;"native"===l&&Et("COMPILER_V_ON_NATIVE",n,r)||Gi(l)?a.push(l):qi(l)?Ct(e)?Qi(e.content.toLowerCase())?i.push(l):o.push(l):(i.push(l),o.push(l)):Hi(l)?o.push(l):i.push(l)}return{keyModifiers:i,nonKeyModifiers:o,eventOptionModifiers:a}},Ki=(e,t)=>{const n=Ct(e)&&"onclick"===e.content.toLowerCase();return n?rt(t,!0):4!==e.type?it(["(",e,`) === "onClick" ? "${t}" : (`,e,")"]):e},Wi=(e,t,n)=>oi(e,t,n,t=>{const{modifiers:r}=e;if(!r.length)return t;let{key:i,value:o}=t.props[0];const{keyModifiers:a,nonKeyModifiers:s,eventOptionModifiers:l}=zi(i,r,n,e.loc);if(s.includes("right")&&(i=Ki(i,"onContextmenu")),s.includes("middle")&&(i=Ki(i,"onMouseup")),s.length&&(o=ot(n.helper(Ti),[o,JSON.stringify(s)])),!a.length||Ct(i)&&!Qi(i.content.toLowerCase())||(o=ot(n.helper(Ri),[o,JSON.stringify(a)])),l.length){const e=l.map($).join("");i=Ct(i)?rt(`${i.content}${e}`,!0):it(["(",i,`) + "${e}"`])}return{props:[nt(i,o)]}}),Xi=(e,t,n)=>{const{exp:r,loc:i}=e;return r||n.onError(Vi(62,i)),{props:[],needRuntime:n.helper(Ni)}};const Yi=(e,t)=>{1!==e.type||0!==e.tagType||"script"!==e.tag&&"style"!==e.tag||t.removeNode()};const Zi=[Bi],Ji={cloak:Ei,html:Fi,text:ji,model:Ui,on:Wi,show:Xi};function eo(e,t={}){return Si(e,h({},Li,t,{nodeTransforms:[Yi,...Zi,...t.nodeTransforms||[]],directiveTransforms:h({},Ji,t.directiveTransforms||{}),transformHoist:null}))}n(4364);let to,no;class ro{constructor(e=!1){this.detached=e,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this._warnOnRun=!0,this.__v_skip=!0,!e&&to&&(to.active?(this.parent=to,this.index=(to.scopes||(to.scopes=[])).push(this)-1):(this._active=!1,this._warnOnRun=!1))}get active(){return this._active}pause(){if(this._active){let e,t;if(this._isPaused=!0,this.scopes){const n=this.scopes.slice();for(e=0,t=n.length;e<t;e++)n[e].pause()}for(e=0,t=this.effects.length;e<t;e++)this.effects[e].pause()}}resume(){if(this._active&&this._isPaused){let e,t;if(this._isPaused=!1,this.scopes){const n=this.scopes.slice();for(e=0,t=n.length;e<t;e++)n[e].resume()}const n=this.effects.slice();for(e=0,t=n.length;e<t;e++)n[e].resume()}}run(e){if(this._active){const t=to;try{return to=this,e()}finally{to=t}}else 0}on(){1===++this._on&&(this.prevScope=to,to=this)}off(){if(this._on>0&&0===--this._on){if(to===this)to=this.prevScope;else{let e=to;while(e){if(e.prevScope===this){e.prevScope=this.prevScope;break}e=e.prevScope}}this.prevScope=void 0}}stop(e){if(this._active){let t,n;for(this._active=!1,t=0,n=this.effects.length;t<n;t++)this.effects[t].stop();for(this.effects.length=0,t=0,n=this.cleanups.length;t<n;t++)this.cleanups[t]();if(this.cleanups.length=0,this.scopes){const e=this.scopes.slice();for(t=0,n=e.length;t<n;t++)e[t].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!e){const e=this.parent.scopes.pop();e&&e!==this&&(this.parent.scopes[this.index]=e,e.index=this.index)}this.parent=void 0}}}function io(){return to}const oo=new WeakSet;class ao{constructor(e){this.fn=e,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.next=void 0,this.cleanup=void 0,this.scheduler=void 0,to&&(to.active?to.effects.push(this):this.flags&=-2)}pause(){this.flags|=64}resume(){64&this.flags&&(this.flags&=-65,oo.has(this)&&(oo.delete(this),this.trigger()))}notify(){2&this.flags&&!(32&this.flags)||8&this.flags||uo(this)}run(){if(!(1&this.flags))return this.fn();this.flags|=2,xo(this),fo(this);const e=no,t=wo;no=this,wo=!0;try{return this.fn()}finally{0,mo(this),no=e,wo=t,this.flags&=-3}}stop(){if(1&this.flags){for(let e=this.deps;e;e=e.nextDep)bo(e);this.deps=this.depsTail=void 0,xo(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){64&this.flags?oo.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){go(this)&&this.run()}get dirty(){return go(this)}}let so,lo,co=0;function uo(e,t=!1){if(e.flags|=8,t)return e.next=lo,void(lo=e);e.next=so,so=e}function ho(){co++}function po(){if(--co>0)return;if(lo){let e=lo;lo=void 0;while(e){const t=e.next;e.next=void 0,e.flags&=-9,e=t}}let e;while(so){let n=so;so=void 0;while(n){const r=n.next;if(n.next=void 0,n.flags&=-9,1&n.flags)try{n.trigger()}catch(t){e||(e=t)}n=r}}if(e)throw e}function fo(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function mo(e){let t,n=e.depsTail,r=n;while(r){const e=r.prevDep;-1===r.version?(r===n&&(n=e),bo(r),yo(r)):t=r,r.dep.activeLink=r.prevActiveLink,r.prevActiveLink=void 0,r=e}e.deps=t,e.depsTail=n}function go(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(vo(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function vo(e){if(4&e.flags&&!(16&e.flags))return;if(e.flags&=-17,e.globalVersion===_o)return;if(e.globalVersion=_o,!e.isSSR&&128&e.flags&&(!e.deps&&!e._dirty||!go(e)))return;e.flags|=2;const t=e.dep,n=no,r=wo;no=e,wo=!0;try{fo(e);const n=e.fn(e._value);(0===t.version||F(n,e._value))&&(e.flags|=128,e._value=n,t.version++)}catch(i){throw t.version++,i}finally{no=n,wo=r,mo(e),e.flags&=-3}}function bo(e,t=!1){const{dep:n,prevSub:r,nextSub:i}=e;if(r&&(r.nextSub=i,e.prevSub=void 0),i&&(i.prevSub=r,e.nextSub=void 0),n.subs===e&&(n.subs=r,!r&&n.computed)){n.computed.flags&=-5;for(let e=n.computed.deps;e;e=e.nextDep)bo(e,!0)}t||--n.sc||!n.map||n.map.delete(n.key)}function yo(e){const{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}let wo=!0;const Oo=[];function So(){Oo.push(wo),wo=!1}function Eo(){const e=Oo.pop();wo=void 0===e||e}function xo(e){const{cleanup:t}=e;if(e.cleanup=void 0,t){const e=no;no=void 0;try{t()}finally{no=e}}}let _o=0;class ko{constructor(e,t){this.sub=e,this.dep=t,this.version=t.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}}class Co{constructor(e){this.computed=e,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0,this.__v_skip=!0}track(e){if(!no||!wo||no===this.computed)return;let t=this.activeLink;if(void 0===t||t.sub!==no)t=this.activeLink=new ko(no,this),no.deps?(t.prevDep=no.depsTail,no.depsTail.nextDep=t,no.depsTail=t):no.deps=no.depsTail=t,Ao(t);else if(-1===t.version&&(t.version=this.version,t.nextDep)){const e=t.nextDep;e.prevDep=t.prevDep,t.prevDep&&(t.prevDep.nextDep=e),t.prevDep=no.depsTail,t.nextDep=void 0,no.depsTail.nextDep=t,no.depsTail=t,no.deps===t&&(no.deps=e)}return t}trigger(e){this.version++,_o++,this.notify(e)}notify(e){ho();try{0;for(let e=this.subs;e;e=e.prevSub)e.sub.notify()&&e.sub.dep.notify()}finally{po()}}}function Ao(e){if(e.dep.sc++,4&e.sub.flags){const t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let e=t.deps;e;e=e.nextDep)Ao(e)}const n=e.dep.subs;n!==e&&(e.prevSub=n,n&&(n.nextSub=e)),e.dep.subs=e}}const To=new WeakMap,Ro=Symbol(""),No=Symbol(""),Po=Symbol("");function Io(e,t,n){if(wo&&no){let t=To.get(e);t||To.set(e,t=new Map);let r=t.get(n);r||(t.set(n,r=new Co),r.map=t,r.key=n),r.track()}}function Mo(e,t,n,r,i,o){const a=To.get(e);if(!a)return void _o++;const s=e=>{e&&e.trigger()};if(ho(),"clear"===t)a.forEach(s);else{const i=g(e),o=i&&R(n);if(i&&"length"===n){const e=Number(r);a.forEach((t,n)=>{("length"===n||n===Po||!E(n)&&n>=e)&&s(t)})}else switch((void 0!==n||a.has(void 0))&&s(a.get(n)),o&&s(a.get(Po)),t){case"add":i?o&&s(a.get("length")):(s(a.get(Ro)),v(e)&&s(a.get(No)));break;case"delete":i||(s(a.get(Ro)),v(e)&&s(a.get(No)));break;case"set":v(e)&&s(a.get(Ro));break}}po()}function Do(e){const t=Sa(e);return t===e?t:(Io(t,"iterate",Po),wa(e)?t:t.map(xa))}function Lo(e){return Io(e=Sa(e),"iterate",Po),e}function Bo(e,t){return ya(e)?ba(e)?_a(xa(t)):_a(t):xa(t)}const $o={__proto__:null,[Symbol.iterator](){return Vo(this,Symbol.iterator,e=>Bo(this,e))},concat(...e){return Do(this).concat(...e.map(e=>g(e)?Do(e):e))},entries(){return Vo(this,"entries",e=>(e[1]=Bo(this,e[1]),e))},every(e,t){return jo(this,"every",e,t,void 0,arguments)},filter(e,t){return jo(this,"filter",e,t,e=>e.map(e=>Bo(this,e)),arguments)},find(e,t){return jo(this,"find",e,t,e=>Bo(this,e),arguments)},findIndex(e,t){return jo(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return jo(this,"findLast",e,t,e=>Bo(this,e),arguments)},findLastIndex(e,t){return jo(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return jo(this,"forEach",e,t,void 0,arguments)},includes(...e){return Go(this,"includes",e)},indexOf(...e){return Go(this,"indexOf",e)},join(e){return Do(this).join(e)},lastIndexOf(...e){return Go(this,"lastIndexOf",e)},map(e,t){return jo(this,"map",e,t,void 0,arguments)},pop(){return Ho(this,"pop")},push(...e){return Ho(this,"push",e)},reduce(e,...t){return Uo(this,"reduce",e,t)},reduceRight(e,...t){return Uo(this,"reduceRight",e,t)},shift(){return Ho(this,"shift")},some(e,t){return jo(this,"some",e,t,void 0,arguments)},splice(...e){return Ho(this,"splice",e)},toReversed(){return Do(this).toReversed()},toSorted(e){return Do(this).toSorted(e)},toSpliced(...e){return Do(this).toSpliced(...e)},unshift(...e){return Ho(this,"unshift",e)},values(){return Vo(this,"values",e=>Bo(this,e))}};function Vo(e,t,n){const r=Lo(e),i=r[t]();return r===e||wa(e)||(i._next=i.next,i.next=()=>{const e=i._next();return e.done||(e.value=n(e.value)),e}),i}const Fo=Array.prototype;function jo(e,t,n,r,i,o){const a=Lo(e),s=a!==e&&!wa(e),l=a[t];if(l!==Fo[t]){const t=l.apply(e,o);return s?xa(t):t}let c=n;a!==e&&(s?c=function(t,r){return n.call(this,Bo(e,t),r,e)}:n.length>2&&(c=function(t,r){return n.call(this,t,r,e)}));const u=l.call(a,c,r);return s&&i?i(u):u}function Uo(e,t,n,r){const i=Lo(e),o=i!==e&&!wa(e);let a=n,s=!1;i!==e&&(o?(s=0===r.length,a=function(t,r,i){return s&&(s=!1,t=Bo(e,t)),n.call(this,t,Bo(e,r),i,e)}):n.length>3&&(a=function(t,r,i){return n.call(this,t,r,i,e)}));const l=i[t](a,...r);return s?Bo(e,l):l}function Go(e,t,n){const r=Sa(e);Io(r,"iterate",Po);const i=r[t](...n);return-1!==i&&!1!==i||!Oa(n[0])?i:(n[0]=Sa(n[0]),r[t](...n))}function Ho(e,t,n=[]){So(),ho();const r=Sa(e)[t].apply(e,n);return po(),Eo(),r}const qo=o("__proto__,__v_isRef,__isVue"),Qo=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>"arguments"!==e&&"caller"!==e).map(e=>Symbol[e]).filter(E));function zo(e){E(e)||(e=String(e));const t=Sa(this);return Io(t,"has",e),t.hasOwnProperty(e)}class Ko{constructor(e=!1,t=!1){this._isReadonly=e,this._isShallow=t}get(e,t,n){if("__v_skip"===t)return e["__v_skip"];const r=this._isReadonly,i=this._isShallow;if("__v_isReactive"===t)return!r;if("__v_isReadonly"===t)return r;if("__v_isShallow"===t)return i;if("__v_raw"===t)return n===(r?i?ha:da:i?ua:ca).get(e)||Object.getPrototypeOf(e)===Object.getPrototypeOf(n)?e:void 0;const o=g(e);if(!r){let e;if(o&&(e=$o[t]))return e;if("hasOwnProperty"===t)return zo}const a=Reflect.get(e,t,ka(e)?e:n);if(E(t)?Qo.has(t):qo(t))return a;if(r||Io(e,"get",t),i)return a;if(ka(a)){const e=o&&R(t)?a:a.value;return r&&x(e)?ga(e):e}return x(a)?r?ga(a):fa(a):a}}class Wo extends Ko{constructor(e=!1){super(!1,e)}set(e,t,n,r){let i=e[t];const o=g(e)&&R(t);if(!this._isShallow){const e=ya(i);if(wa(n)||ya(n)||(i=Sa(i),n=Sa(n)),!o&&ka(i)&&!ka(n))return e||(i.value=n),!0}const a=o?Number(t)<e.length:m(e,t),s=Reflect.set(e,t,n,ka(e)?e:r);return e===Sa(r)&&s&&(a?F(n,i)&&Mo(e,"set",t,n,i):Mo(e,"add",t,n)),s}deleteProperty(e,t){const n=m(e,t),r=e[t],i=Reflect.deleteProperty(e,t);return i&&n&&Mo(e,"delete",t,void 0,r),i}has(e,t){const n=Reflect.has(e,t);return E(t)&&Qo.has(t)||Io(e,"has",t),n}ownKeys(e){return Io(e,"iterate",g(e)?"length":Ro),Reflect.ownKeys(e)}}class Xo extends Ko{constructor(e=!1){super(!0,e)}set(e,t){return!0}deleteProperty(e,t){return!0}}const Yo=new Wo,Zo=new Xo,Jo=new Wo(!0),ea=e=>e,ta=e=>Reflect.getPrototypeOf(e);function na(e,t,n){return function(...r){const i=this["__v_raw"],o=Sa(i),a=v(o),s="entries"===e||e===Symbol.iterator&&a,l="keys"===e&&a,c=i[e](...r),u=n?ea:t?_a:xa;return!t&&Io(o,"iterate",l?No:Ro),h(Object.create(c),{next(){const{value:e,done:t}=c.next();return t?{value:e,done:t}:{value:s?[u(e[0]),u(e[1])]:u(e),done:t}}})}}function ra(e){return function(...t){return"delete"!==e&&("clear"===e?void 0:this)}}function ia(e,t){const n={get(n){const r=this["__v_raw"],i=Sa(r),o=Sa(n);e||(F(n,o)&&Io(i,"get",n),Io(i,"get",o));const{has:a}=ta(i),s=t?ea:e?_a:xa;return a.call(i,n)?s(r.get(n)):a.call(i,o)?s(r.get(o)):void(r!==i&&r.get(n))},get size(){const t=this["__v_raw"];return!e&&Io(Sa(t),"iterate",Ro),t.size},has(t){const n=this["__v_raw"],r=Sa(n),i=Sa(t);return e||(F(t,i)&&Io(r,"has",t),Io(r,"has",i)),t===i?n.has(t):n.has(t)||n.has(i)},forEach(n,r){const i=this,o=i["__v_raw"],a=Sa(o),s=t?ea:e?_a:xa;return!e&&Io(a,"iterate",Ro),o.forEach((e,t)=>n.call(r,s(e),s(t),i))}};h(n,e?{add:ra("add"),set:ra("set"),delete:ra("delete"),clear:ra("clear")}:{add(e){const n=Sa(this),r=ta(n),i=Sa(e),o=t||wa(e)||ya(e)?e:i,a=r.has.call(n,o)||F(e,o)&&r.has.call(n,e)||F(i,o)&&r.has.call(n,i);return a||(n.add(o),Mo(n,"add",o,o)),this},set(e,n){t||wa(n)||ya(n)||(n=Sa(n));const r=Sa(this),{has:i,get:o}=ta(r);let a=i.call(r,e);a||(e=Sa(e),a=i.call(r,e));const s=o.call(r,e);return r.set(e,n),a?F(n,s)&&Mo(r,"set",e,n,s):Mo(r,"add",e,n),this},delete(e){const t=Sa(this),{has:n,get:r}=ta(t);let i=n.call(t,e);i||(e=Sa(e),i=n.call(t,e));const o=r?r.call(t,e):void 0,a=t.delete(e);return i&&Mo(t,"delete",e,void 0,o),a},clear(){const e=Sa(this),t=0!==e.size,n=void 0,r=e.clear();return t&&Mo(e,"clear",void 0,void 0,n),r}});const r=["keys","values","entries",Symbol.iterator];return r.forEach(r=>{n[r]=na(r,e,t)}),n}function oa(e,t){const n=ia(e,t);return(t,r,i)=>"__v_isReactive"===r?!e:"__v_isReadonly"===r?e:"__v_raw"===r?t:Reflect.get(m(n,r)&&r in t?n:t,r,i)}const aa={get:oa(!1,!1)},sa={get:oa(!1,!0)},la={get:oa(!0,!1)};const ca=new WeakMap,ua=new WeakMap,da=new WeakMap,ha=new WeakMap;function pa(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function fa(e){return ya(e)?e:va(e,!1,Yo,aa,ca)}function ma(e){return va(e,!1,Jo,sa,ua)}function ga(e){return va(e,!0,Zo,la,da)}function va(e,t,n,r,i){if(!x(e))return e;if(e["__v_raw"]&&(!t||!e["__v_isReactive"]))return e;if(e["__v_skip"]||!Object.isExtensible(e))return e;const o=i.get(e);if(o)return o;const a=pa(A(e));if(0===a)return e;const s=new Proxy(e,2===a?r:n);return i.set(e,s),s}function ba(e){return ya(e)?ba(e["__v_raw"]):!(!e||!e["__v_isReactive"])}function ya(e){return!(!e||!e["__v_isReadonly"])}function wa(e){return!(!e||!e["__v_isShallow"])}function Oa(e){return!!e&&!!e["__v_raw"]}function Sa(e){const t=e&&e["__v_raw"];return t?Sa(t):e}function Ea(e){return!m(e,"__v_skip")&&Object.isExtensible(e)&&U(e,"__v_skip",!0),e}const xa=e=>x(e)?fa(e):e,_a=e=>x(e)?ga(e):e;function ka(e){return!!e&&!0===e["__v_isRef"]}function Ca(e){return ka(e)?e.value:e}const Aa={get:(e,t,n)=>"__v_raw"===t?e:Ca(Reflect.get(e,t,n)),set:(e,t,n,r)=>{const i=e[t];return ka(i)&&!ka(n)?(i.value=n,!0):Reflect.set(e,t,n,r)}};function Ta(e){return ba(e)?e:new Proxy(e,Aa)}class Ra{constructor(e,t,n){this.fn=e,this.setter=t,this._value=void 0,this.dep=new Co(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=_o-1,this.next=void 0,this.effect=this,this["__v_isReadonly"]=!t,this.isSSR=n}notify(){if(this.flags|=16,!(8&this.flags||no===this))return uo(this,!0),!0}get value(){const e=this.dep.track();return vo(this),e&&(e.version=this.dep.version),this._value}set value(e){this.setter&&this.setter(e)}}function Na(e,t,n=!1){let r,i;O(e)?r=e:(r=e.get,i=e.set);const o=new Ra(r,i,n);return o}const Pa={},Ia=new WeakMap;let Ma;function Da(e,t=!1,n=Ma){if(n){let t=Ia.get(n);t||Ia.set(n,t=[]),t.push(e)}else 0}function La(e,t,n=a){const{immediate:r,deep:i,once:o,scheduler:s,augmentJob:c,call:u}=n,d=e=>i?e:wa(e)||!1===i||0===i?Ba(e,1):Ba(e);let h,f,m,v,b=!1,y=!1;if(ka(e)?(f=()=>e.value,b=wa(e)):ba(e)?(f=()=>d(e),b=!0):g(e)?(y=!0,b=e.some(e=>ba(e)||wa(e)),f=()=>e.map(e=>ka(e)?e.value:ba(e)?d(e):O(e)?u?u(e,2):e():void 0)):f=O(e)?t?u?()=>u(e,2):e:()=>{if(m){So();try{m()}finally{Eo()}}const t=Ma;Ma=h;try{return u?u(e,3,[v]):e(v)}finally{Ma=t}}:l,t&&i){const e=f,t=!0===i?1/0:i;f=()=>Ba(e(),t)}const w=io(),S=()=>{h.stop(),w&&w.active&&p(w.effects,h)};if(o&&t){const e=t;t=(...t)=>{const n=e(...t);return S(),n}}let E=y?new Array(e.length).fill(Pa):Pa;const x=e=>{if(1&h.flags&&(h.dirty||e))if(t){const n=h.run();if(e||i||b||(y?n.some((e,t)=>F(e,E[t])):F(n,E))){m&&m();const e=Ma;Ma=h;try{const e=[n,E===Pa?void 0:y&&E[0]===Pa?[]:E,v];E=n,u?u(t,3,e):t(...e)}finally{Ma=e}}}else h.run()};return c&&c(x),h=new ao(f),h.scheduler=s?()=>s(x,!1):x,v=e=>Da(e,!1,h),m=h.onStop=()=>{const e=Ia.get(h);if(e){if(u)u(e,4);else for(const t of e)t();Ia.delete(h)}},t?r?x(!0):E=h.run():s?s(x.bind(null,!0),!0):h.run(),S.pause=h.pause.bind(h),S.resume=h.resume.bind(h),S.stop=S,S}function Ba(e,t=1/0,n){if(t<=0||!x(e)||e["__v_skip"])return e;if(n=n||new Map,(n.get(e)||0)>=t)return e;if(n.set(e,t),t--,ka(e))Ba(e.value,t,n);else if(g(e))for(let r=0;r<e.length;r++)Ba(e[r],t,n);else if(b(e)||v(e))e.forEach(e=>{Ba(e,t,n)});else if(T(e)){for(const r in e)Ba(e[r],t,n);for(const r of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,r)&&Ba(e[r],t,n)}return e}var $a=n(4364);
|
||
/**
|
||
* @vue/runtime-core v3.5.42
|
||
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
||
* @license MIT
|
||
**/
|
||
const Va=[];function Fa(e){Va.push(e)}function ja(){Va.pop()}function Ua(e,t,n,r){try{return r?e(...r):e()}catch(i){Ha(i,t,n)}}function Ga(e,t,n,r){if(O(e)){const i=Ua(e,t,n,r);return i&&_(i)&&i.catch(e=>{Ha(e,t,n)}),i}if(g(e)){const i=[];for(let o=0;o<e.length;o++)i.push(Ga(e[o],t,n,r));return i}}function Ha(e,t,n,r=!0){const i=t?t.vnode:null,{errorHandler:o,throwUnhandledErrorInProduction:s}=t&&t.appContext.config||a;if(t){let r=t.parent;const i=t.proxy,a=`https://vuejs.org/error-reference/#runtime-${n}`;while(r){const t=r.ec;if(t)for(let n=0;n<t.length;n++)if(!1===t[n](e,i,a))return;r=r.parent}if(o)return So(),Ua(o,null,10,[e,i,a]),void Eo()}qa(e,n,i,r,s)}function qa(e,t,n,r=!0,i=!1){if(i)throw e;$a.error(e)}const Qa=[];let za=-1;const Ka=[];let Wa=null,Xa=0;const Ya=Promise.resolve();let Za=null;function Ja(e){const t=Za||Ya;return e?t.then(this?e.bind(this):e):t}function es(e){let t=za+1,n=Qa.length;while(t<n){const r=t+n>>>1,i=Qa[r],o=os(i);o<e||o===e&&2&i.flags?t=r+1:n=r}return t}function ts(e){if(!(1&e.flags)){const t=os(e),n=Qa[Qa.length-1];!n||!(2&e.flags)&&t>=os(n)?Qa.push(e):Qa.splice(es(t),0,e),e.flags|=1,ns()}}function ns(){Za||(Za=Ya.then(as))}function rs(e){if(g(e))for(let t=0;t<e.length;t++)Ka.push(e[t]);else Wa&&-1===e.id?Wa.splice(Xa+1,0,e):1&e.flags||(Ka.push(e),e.flags|=1);ns()}function is(e){if(Ka.length){const e=[...new Set(Ka)].sort((e,t)=>os(e)-os(t));if(Ka.length=0,Wa){for(let t=0;t<e.length;t++)Wa.push(e[t]);return}for(Wa=e,Xa=0;Xa<Wa.length;Xa++){const e=Wa[Xa];0,4&e.flags&&(e.flags&=-2),8&e.flags||e(),e.flags&=-2}Wa=null,Xa=0}}const os=e=>null==e.id?2&e.flags?-1:1/0:e.id;function as(e){try{for(za=0;za<Qa.length;za++){const e=Qa[za];!e||8&e.flags||(4&e.flags&&(e.flags&=-2),Ua(e,e.i,e.i?15:14),4&e.flags||(e.flags&=-2))}}finally{for(;za<Qa.length;za++){const e=Qa[za];e&&(e.flags&=-2)}za=-1,Qa.length=0,is(e),Za=null,(Qa.length||Ka.length)&&as(e)}}let ss=null,ls=null;function cs(e){const t=ss;return ss=e,ls=e&&e.type.__scopeId||null,t}function us(e,t=ss,n){if(!t)return e;if(e._n)return e;const r=(...n)=>{r._d&&Yl(-1);const i=cs(t),o=zl.length;let a;try{a=e(...n)}finally{for(let e=zl.length;e>o;e--)Wl();cs(i),r._d&&Yl(1)}return a};return r._n=!0,r._c=!0,r._d=!0,r}function ds(e,t){if(gc){let n=gc.provides;const r=gc.parent&&gc.parent.provides;r===n&&(n=gc.provides=Object.create(r)),n[e]=t}}function hs(e,t,n=!1){const r=vc();if(r||ml){let i=ml?ml._context.provides:r?null==r.parent||r.ce?r.vnode.appContext&&r.vnode.appContext.provides:r.parent.provides:void 0;if(i&&e in i)return i[e];if(arguments.length>1)return n&&O(t)?t.call(r&&r.proxy):t}else 0}const ps=Symbol.for("v-scx"),fs=()=>{{const e=hs(ps);return e}};function ms(e,t,n){return gs(e,t,n)}function gs(e,t,n=a){const{immediate:r,deep:i,flush:o,once:s}=n;const c=h({},n);const u=t&&r||!t&&"post"!==o;let d;if(_c)if("sync"===o){const e=fs();d=e.__watcherHandles||(e.__watcherHandles=[])}else if(!u){const e=()=>{};return e.stop=l,e.resume=l,e.pause=l,e}const p=gc;c.call=(e,t,n)=>Ga(e,p,t,n);let f=!1;"post"===o?c.scheduler=e=>{Fl(e,p&&p.suspense)}:"sync"!==o&&(f=!0,c.scheduler=(e,t)=>{t?e():ts(e)}),c.augmentJob=e=>{t&&(e.flags|=4),f&&(e.flags|=2,p&&(e.id=p.uid,e.i=p))};const m=La(e,t,c);return _c&&(d?d.push(m):u&&m()),m}function vs(e,t,n){const r=this.proxy,i=S(e)?e.includes(".")?bs(r,e):()=>r[e]:e.bind(r,r);let o;O(t)?o=t:(o=t.handler,n=t);const a=wc(this),s=gs(i,o.bind(r),n);return a(),s}function bs(e,t){const n=t.split(".");return()=>{let t=e;for(let e=0;e<n.length&&t;e++)t=t[n[e]];return t}}const ys=e=>e.__isTeleport;const ws=[Function,Array];Boolean,Boolean;function Os(e){let t=e[0];if(e.length>1){let n=!1;for(const r of e)if(r.type!==Ql){0,t=r,n=!0;break}}return t}function Ss(e){if(!ks(e))return ys(e.type)&&e.children?Os(e.children):e;if(e.component)return e.component.subTree;const{shapeFlag:t,children:n}=e;if(n){if(16&t)return n[0];if(32&t&&O(n.default))return n.default()}}function Es(e,t){if(6&e.shapeFlag&&e.component){e.transition=t;const n=e.component.subTree;Es(ys(n.type)&&Ss(n)||n,t)}else 128&e.shapeFlag?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function xs(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}q().requestIdleCallback,q().cancelIdleCallback;const _s=e=>!!e.type.__asyncLoader;const ks=e=>e.type.__isKeepAlive;RegExp,RegExp;function Cs(e,t){return g(e)?e.some(e=>Cs(e,t)):S(e)?e.split(",").includes(t):!!w(e)&&(e.lastIndex=0,e.test(t))}function As(e,t){Rs(e,"a",t)}function Ts(e,t){Rs(e,"da",t)}function Rs(e,t,n=gc){const r=e.__wdc||(e.__wdc=()=>{let t=n;while(t){if(t.isDeactivated)return;t=t.parent}return e()});if(Ms(t,r,n),n){let e=n.parent;while(e&&e.parent)ks(e.parent.vnode)&&Ns(r,t,n,e),e=e.parent}}function Ns(e,t,n,r){const i=Ms(t,e,r,!0);js(()=>{p(r[t],i)},n)}function Ps(e){e.shapeFlag&=-257,e.shapeFlag&=-513}function Is(e){return 128&e.shapeFlag?e.ssContent:e}function Ms(e,t,n=gc,r=!1){if(n){const i=n[e]||(n[e]=[]),o=t.__weh||(t.__weh=(...r)=>{So();const i=wc(n),o=Ga(t,n,e,r);return i(),Eo(),o});return r?i.unshift(o):i.push(o),o}}const Ds=e=>(t,n=gc)=>{_c&&"sp"!==e||Ms(e,(...e)=>t(...e),n)},Ls=Ds("bm"),Bs=Ds("m"),$s=Ds("bu"),Vs=Ds("u"),Fs=Ds("bum"),js=Ds("um"),Us=Ds("sp"),Gs=Ds("rtg"),Hs=Ds("rtc");function qs(e,t=gc){Ms("ec",e,t)}const Qs=Symbol.for("v-ndc");function zs(e){return e.some(e=>!Zl(e)||e.type!==Ql&&!(e.type===Hl&&!zs(e.children)))?e:null}const Ks=e=>e?Sc(e)?Pc(e):Ks(e.parent):null,Ws=h(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>Ks(e.parent),$root:e=>Ks(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>il(e),$forceUpdate:e=>e.f||(e.f=()=>{ts(e.update)}),$nextTick:e=>e.n||(e.n=Ja.bind(e.proxy)),$watch:e=>vs.bind(e)}),Xs=(e,t)=>e!==a&&!e.__isScriptSetup&&m(e,t),Ys={get({_:e},t){if("__v_skip"===t)return!0;const{ctx:n,setupState:r,data:i,props:o,accessCache:s,type:l,appContext:c}=e;if("$"!==t[0]){const e=s[t];if(void 0!==e)switch(e){case 1:return r[t];case 2:return i[t];case 4:return n[t];case 3:return o[t]}else{if(Xs(r,t))return s[t]=1,r[t];if(i!==a&&m(i,t))return s[t]=2,i[t];if(m(o,t))return s[t]=3,o[t];if(n!==a&&m(n,t))return s[t]=4,n[t];Js&&(s[t]=0)}}const u=Ws[t];let d,h;return u?("$attrs"===t&&Io(e.attrs,"get",""),u(e)):(d=l.__cssModules)&&(d=d[t])?d:n!==a&&m(n,t)?(s[t]=4,n[t]):(h=c.config.globalProperties,m(h,t)?h[t]:void 0)},set({_:e},t,n){const{data:r,setupState:i,ctx:o}=e;return Xs(i,t)?(i[t]=n,!0):r!==a&&m(r,t)?(r[t]=n,!0):!m(e.props,t)&&(("$"!==t[0]||!(t.slice(1)in e))&&(o[t]=n,!0))},has({_:{data:e,setupState:t,accessCache:n,ctx:r,appContext:i,props:o,type:s}},l){let c;return!!(n[l]||e!==a&&"$"!==l[0]&&m(e,l)||Xs(t,l)||m(o,l)||m(r,l)||m(Ws,l)||m(i.config.globalProperties,l)||(c=s.__cssModules)&&c[l])},defineProperty(e,t,n){return null!=n.get?e._.accessCache[t]=0:m(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};function Zs(e){return g(e)?e.reduce((e,t)=>(e[t]=null,e),{}):e}let Js=!0;function el(e){const t=il(e),n=e.proxy,r=e.ctx;Js=!1,t.beforeCreate&&nl(t.beforeCreate,e,"bc");const{data:i,computed:o,methods:a,watch:s,provide:c,inject:u,created:d,beforeMount:h,mounted:p,beforeUpdate:f,updated:m,activated:v,deactivated:b,beforeDestroy:y,beforeUnmount:w,destroyed:S,unmounted:E,render:_,renderTracked:k,renderTriggered:C,errorCaptured:A,serverPrefetch:T,expose:R,inheritAttrs:N,components:P,directives:I,filters:M}=t,D=null;if(u&&tl(u,r,D),a)for(const l in a){const e=a[l];O(e)&&(r[l]=e.bind(n))}if(i){0;const t=i.call(n,n);0,x(t)&&(e.data=fa(t))}if(Js=!0,o)for(const g in o){const e=o[g],t=O(e)?e.bind(n,n):O(e.get)?e.get.bind(n,n):l;0;const i=!O(e)&&O(e.set)?e.set.bind(n):l,a=Dc({get:t,set:i});Object.defineProperty(r,g,{enumerable:!0,configurable:!0,get:()=>a.value,set:e=>a.value=e})}if(s)for(const l in s)rl(s[l],r,n,l);if(c){const e=O(c)?c.call(n):c;Reflect.ownKeys(e).forEach(t=>{ds(t,e[t])})}function L(e,t){g(t)?t.forEach(t=>e(t.bind(n))):t&&e(t.bind(n))}if(d&&nl(d,e,"c"),L(Ls,h),L(Bs,p),L($s,f),L(Vs,m),L(As,v),L(Ts,b),L(qs,A),L(Hs,k),L(Gs,C),L(Fs,w),L(js,E),L(Us,T),g(R))if(R.length){const t=e.exposed||(e.exposed={});R.forEach(e=>{Object.defineProperty(t,e,{get:()=>n[e],set:t=>n[e]=t,enumerable:!0})})}else e.exposed||(e.exposed={});_&&e.render===l&&(e.render=_),null!=N&&(e.inheritAttrs=N),P&&(e.components=P),I&&(e.directives=I),T&&xs(e)}function tl(e,t,n=l){g(e)&&(e=cl(e));for(const r in e){const n=e[r];let i;i=x(n)?"default"in n?hs(n.from||r,n.default,!0):hs(n.from||r):hs(n),ka(i)?Object.defineProperty(t,r,{enumerable:!0,configurable:!0,get:()=>i.value,set:e=>i.value=e}):t[r]=i}}function nl(e,t,n){Ga(g(e)?e.map(e=>e.bind(t.proxy)):e.bind(t.proxy),t,n)}function rl(e,t,n,r){let i=r.includes(".")?bs(n,r):()=>n[r];if(S(e)){const n=t[e];O(n)&&ms(i,n)}else if(O(e))ms(i,e.bind(n));else if(x(e))if(g(e))e.forEach(e=>rl(e,t,n,r));else{const r=O(e.handler)?e.handler.bind(n):t[e.handler];O(r)&&ms(i,r,e)}else 0}function il(e){const t=e.type,{mixins:n,extends:r}=t,{mixins:i,optionsCache:o,config:{optionMergeStrategies:a}}=e.appContext,s=o.get(t);let l;return s?l=s:i.length||n||r?(l={},i.length&&i.forEach(e=>ol(l,e,a,!0)),ol(l,t,a)):l=t,x(t)&&o.set(t,l),l}function ol(e,t,n,r=!1){const{mixins:i,extends:o}=t;o&&ol(e,o,n,!0),i&&i.forEach(t=>ol(e,t,n,!0));for(const a in t)if(r&&"expose"===a);else{const r=al[a]||n&&n[a];e[a]=r?r(e[a],t[a]):t[a]}return e}const al={data:sl,props:hl,emits:hl,methods:dl,computed:dl,beforeCreate:ul,created:ul,beforeMount:ul,mounted:ul,beforeUpdate:ul,updated:ul,beforeDestroy:ul,beforeUnmount:ul,destroyed:ul,unmounted:ul,activated:ul,deactivated:ul,errorCaptured:ul,serverPrefetch:ul,components:dl,directives:dl,watch:pl,provide:sl,inject:ll};function sl(e,t){return t?e?function(){return h(O(e)?e.call(this,this):e,O(t)?t.call(this,this):t)}:t:e}function ll(e,t){return dl(cl(e),cl(t))}function cl(e){if(g(e)){const t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function ul(e,t){return e?[...new Set([].concat(e,t))]:t}function dl(e,t){return e?h(Object.create(null),e,t):t}function hl(e,t){return e?g(e)&&g(t)?[...new Set([...e,...t])]:h(Object.create(null),Zs(e),Zs(null!=t?t:{})):t}function pl(e,t){if(!e)return t;if(!t)return e;const n=h(Object.create(null),e);for(const r in t)n[r]=ul(e[r],t[r]);return n}function fl(){return{app:null,config:{isNativeTag:c,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}let ml=null;const gl=(e,t)=>"modelValue"===t||"model-value"===t?e.modelModifiers:e[`${t}Modifiers`]||e[`${D(t)}Modifiers`]||e[`${B(t)}Modifiers`];function vl(e,t,...n){if(e.isUnmounted)return;const r=e.vnode.props||a;let i=n;const o=t.startsWith("update:"),s=o&&gl(r,t.slice(7));let l;s&&(s.trim&&(i=n.map(e=>S(e)?e.trim():e)),s.number&&(i=i.map(G)));let c=r[l=V(t)]||r[l=V(D(t))];!c&&o&&(c=r[l=V(B(t))]),c&&Ga(c,e,6,i);const u=r[l+"Once"];if(u){if(e.emitted){if(e.emitted[l])return}else e.emitted={};e.emitted[l]=!0,Ga(u,e,6,i)}}const bl=new WeakMap;function yl(e,t,n=!1){const r=n?bl:t.emitsCache,i=r.get(e);if(void 0!==i)return i;const o=e.emits;let a={},s=!1;if(!O(e)){const r=e=>{const n=yl(e,t,!0);n&&(s=!0,h(a,n))};!n&&t.mixins.length&&t.mixins.forEach(r),e.extends&&r(e.extends),e.mixins&&e.mixins.forEach(r)}return o||s?(g(o)?o.forEach(e=>a[e]=null):h(a,o),x(e)&&r.set(e,a),a):(x(e)&&r.set(e,null),null)}function wl(e,t){return!(!e||!u(t))&&(t=t.slice(2),t="Once"===t?t:t.replace(/Once$/,""),m(e,t[0].toLowerCase()+t.slice(1))||m(e,B(t))||m(e,t))}function Ol(e){const{type:t,vnode:n,proxy:r,withProxy:i,propsOptions:[o],slots:a,attrs:s,emit:l,render:c,renderCache:u,props:h,data:p,setupState:f,ctx:m,inheritAttrs:g}=e,v=cs(e);let b,y;try{if(4&n.shapeFlag){const e=i||r,t=e;b=lc(c.call(t,e,u,h,f,p,m)),y=s}else{const e=t;0,b=lc(e.length>1?e(h,{attrs:s,slots:a,emit:l}):e(h,null)),y=t.props?s:Sl(s)}}catch(O){zl.length=0,Ha(O,e,1),b=rc(Ql)}let w=b;if(y&&!1!==g){const e=Object.keys(y),{shapeFlag:t}=w;e.length&&7&t&&(o&&e.some(d)&&(y=El(y,o)),w=ac(w,y,!1,!0))}if(n.dirs&&(w=ac(w,null,!1,!0),w.dirs=w.dirs?w.dirs.concat(n.dirs):n.dirs),n.transition){const e=ys(w.type)&&Ss(w)||w;0,Es(e,n.transition)}return b=w,cs(v),b}const Sl=e=>{let t;for(const n in e)("class"===n||"style"===n||u(n))&&((t||(t={}))[n]=e[n]);return t},El=(e,t)=>{const n={};for(const r in e)d(r)&&r.slice(9)in t||(n[r]=e[r]);return n};const xl={},_l=()=>Object.create(xl),kl=e=>Object.getPrototypeOf(e)===xl;function Cl(e,t,n,r=!1){const i={},o=_l();e.propsDefaults=Object.create(null),Al(e,t,i,o);for(const a in e.propsOptions[0])a in i||(i[a]=void 0);n?e.props=r?i:ma(i):e.type.props?e.props=i:e.props=o,e.attrs=o}function Al(e,t,n,r){const[i,o]=e.propsOptions;let s,l=!1;if(t)for(let a in t){if(N(a))continue;const c=t[a];let u;i&&m(i,u=D(a))?o&&o.includes(u)?(s||(s={}))[u]=c:n[u]=c:wl(e.emitsOptions,a)||a in r&&c===r[a]||(r[a]=c,l=!0)}if(o){const t=Sa(n),r=s||a;for(let a=0;a<o.length;a++){const s=o[a];n[s]=Tl(i,t,s,r[s],e,!m(r,s))}}return l}function Tl(e,t,n,r,i,o){const a=e[n];if(null!=a){const e=m(a,"default");if(e&&void 0===r){const e=a.default;if(a.type!==Function&&!a.skipFactory&&O(e)){const{propsDefaults:o}=i;if(n in o)r=o[n];else{const a=wc(i);r=o[n]=e.call(null,t),a()}}else r=e;i.ce&&i.ce._setProp(n,r)}a[0]&&(o&&!e?r=!1:!a[1]||""!==r&&r!==B(n)||(r=!0))}return r}const Rl=new WeakMap;function Nl(e,t,n=!1){const r=n?Rl:t.propsCache,i=r.get(e);if(i)return i;const o=e.props,l={},c=[];let u=!1;if(!O(e)){const r=e=>{u=!0;const[n,r]=Nl(e,t,!0);h(l,n),r&&c.push(...r)};!n&&t.mixins.length&&t.mixins.forEach(r),e.extends&&r(e.extends),e.mixins&&e.mixins.forEach(r)}if(!o&&!u)return x(e)&&r.set(e,s),s;if(g(o))for(let s=0;s<o.length;s++){0;const e=D(o[s]);Pl(e)&&(l[e]=a)}else if(o){0;for(const e in o){const t=D(e);if(Pl(t)){const n=o[e],r=l[t]=g(n)||O(n)?{type:n}:h({},n),i=r.type;let a=!1,s=!0;if(g(i))for(let e=0;e<i.length;++e){const t=i[e],n=O(t)&&t.name;if("Boolean"===n){a=!0;break}"String"===n&&(s=!1)}else a=O(i)&&"Boolean"===i.name;r[0]=a,r[1]=s,(a||m(r,"default"))&&c.push(t)}}}const d=[l,c];return x(e)&&r.set(e,d),d}function Pl(e){return"$"!==e[0]&&!N(e)}const Il=e=>"_"===e||"_ctx"===e||"$stable"===e,Ml=e=>g(e)?e.map(lc):[lc(e)],Dl=(e,t,n)=>{if(t._n)return t;const r=us((...e)=>Ml(t(...e)),n);return r._c=!1,r},Ll=(e,t,n)=>{const r=e._ctx;for(const i in e){if(Il(i))continue;const n=e[i];if(O(n))t[i]=Dl(i,n,r);else if(null!=n){0;const e=Ml(n);t[i]=()=>e}}},Bl=(e,t)=>{const n=Ml(t);e.slots.default=()=>n},$l=(e,t,n)=>{for(const r in t)!n&&Il(r)||(e[r]=t[r])},Vl=(e,t,n)=>{const r=e.slots=_l();if(32&e.vnode.shapeFlag){const e=t._;e?($l(r,t,n),n&&U(r,"_",e,!0)):Ll(t,r)}else t&&Bl(e,t)};const Fl=Gl;function jl(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}const Ul=e=>e.__isSuspense;function Gl(e,t){t&&t.pendingBranch?g(e)?t.effects.push(...e):t.effects.push(e):rs(e)}const Hl=Symbol.for("v-fgt"),ql=Symbol.for("v-txt"),Ql=Symbol.for("v-cmt"),zl=[];let Kl=null;function Wl(){zl.pop(),Kl=zl[zl.length-1]||null}let Xl=1;function Yl(e,t=!1){Xl+=e,e<0&&Kl&&t&&(Kl.hasOnce=!0)}function Zl(e){return!!e&&!0===e.__v_isVNode}function Jl(e,t){return e.type===t.type&&e.key===t.key}const ec=({key:e})=>null!=e?e:null,tc=({ref:e,ref_key:t,ref_for:n})=>("number"===typeof e&&(e=""+e),null!=e?S(e)||ka(e)||O(e)?{i:ss,r:e,k:t,f:!!n}:e:null);function nc(e,t=null,n=null,r=0,i=null,o=(e===Hl?0:1),a=!1,s=!1){const l={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&ec(t),ref:t&&tc(t),scopeId:ls,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:o,patchFlag:r,dynamicProps:i,dynamicChildren:null,appContext:null,ctx:ss};return s?(uc(l,n),128&o&&e.normalize(l)):n&&(l.shapeFlag|=S(n)?8:16),Xl>0&&!a&&Kl&&(l.patchFlag>0||6&o)&&32!==l.patchFlag&&Kl.push(l),l}const rc=ic;function ic(e,t=null,n=null,r=0,i=null,o=!1){if(e&&e!==Qs||(e=Ql),Zl(e)){const r=ac(e,t,!0);return n&&uc(r,n),Xl>0&&!o&&Kl&&(6&r.shapeFlag?Kl[Kl.indexOf(e)]=r:Kl.push(r)),r.patchFlag=-2,r}if(Mc(e)&&(e=e.__vccOpts),t){t=oc(t);let{class:e,style:n}=t;e&&!S(e)&&(t.class=Y(e)),x(n)&&(Oa(n)&&!g(n)&&(n=h({},n)),t.style=Q(n))}const a=S(e)?1:Ul(e)?128:ys(e)?64:x(e)?4:O(e)?2:0;return nc(e,t,n,r,i,a,o,!0)}function oc(e){return e?Oa(e)||kl(e)?h({},e):e:null}function ac(e,t,n=!1,r=!1){const{props:i,ref:o,patchFlag:a,children:s,transition:l}=e,c=t?dc(i||{},t):i,u={__v_isVNode:!0,__v_skip:!0,type:e.type,props:c,key:c&&ec(c),ref:t&&t.ref?n&&o?g(o)?o.concat(tc(t)):[o,tc(t)]:tc(t):o,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:s,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==Hl?-1===a?16:16|a:a,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:l,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&ac(e.ssContent),ssFallback:e.ssFallback&&ac(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return l&&r&&Es(u,l.clone(u)),u}function sc(e=" ",t=0){return rc(ql,null,e,t)}function lc(e){return null==e||"boolean"===typeof e?rc(Ql):g(e)?rc(Hl,null,e.slice()):Zl(e)?cc(e):rc(ql,null,String(e))}function cc(e){return null===e.el&&-1!==e.patchFlag||e.memo?e:ac(e)}function uc(e,t){let n=0;const{shapeFlag:r}=e;if(null==t)t=null;else if(g(t))n=16;else if("object"===typeof t){if(65&r){const n=t.default;return void(n&&(n._c&&(n._d=!1),uc(e,n()),n._c&&(n._d=!0)))}{n=32;const r=t._;r||kl(t)?3===r&&ss&&(1===ss.slots._?t._=1:(t._=2,e.patchFlag|=1024)):t._ctx=ss}}else if(O(t)){if(65&r)return void uc(e,{default:t});t={default:t,_ctx:ss},n=32}else t=String(t),64&r?(n=16,t=[sc(t)]):n=8;e.children=t,e.shapeFlag|=n}function dc(...e){const t={};for(let n=0;n<e.length;n++){const r=e[n];for(const e in r)if("class"===e)t.class!==r.class&&(t.class=Y([t.class,r.class]));else if("style"===e)t.style=Q([t.style,r.style]);else if(u(e)){const n=t[e],i=r[e];!i||n===i||g(n)&&n.includes(i)?null!=i||null!=n||d(e)||(t[e]=i):t[e]=n?[].concat(n,i):i}else""!==e&&(t[e]=r[e])}return t}function hc(e,t,n,r=null){Ga(e,t,7,[n,r])}const pc=fl();let fc=0;function mc(e,t,n){const r=e.type,i=(t?t.appContext:e.appContext)||pc,o={uid:fc++,vnode:e,type:r,parent:t,appContext:i,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new ro(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(i.provides),ids:t?t.ids:["",0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:Nl(r,i),emitsOptions:yl(r,i),emit:null,emitted:null,propsDefaults:a,inheritAttrs:r.inheritAttrs,ctx:a,data:a,props:a,attrs:a,slots:a,refs:a,setupState:a,setupContext:null,suspense:n,suspenseId:n?n.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return o.ctx={_:o},o.root=t?t.root:o,o.emit=vl.bind(null,o),e.ce&&e.ce(o),o}let gc=null;const vc=()=>gc||ss;let bc,yc;{const e=q(),t=(t,n)=>{let r;return(r=e[t])||(r=e[t]=[]),r.push(n),e=>{r.length>1?r.forEach(t=>t(e)):r[0](e)}};bc=t("__VUE_INSTANCE_SETTERS__",e=>gc=e),yc=t("__VUE_SSR_SETTERS__",e=>_c=e)}const wc=e=>{const t=gc;return bc(e),e.scope.on(),()=>{e.scope.off(),bc(t)}},Oc=()=>{gc&&gc.scope.off(),bc(null)};function Sc(e){return 4&e.vnode.shapeFlag}let Ec,xc,_c=!1;function kc(e,t=!1,n=!1){t&&yc(t);const{props:r,children:i}=e.vnode,o=Sc(e);Cl(e,r,o,t),Vl(e,i,n||t);const a=o?Cc(e,t):void 0;return t&&yc(!1),a}function Cc(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,Ys);const{setup:r}=n;if(r){So();const n=e.setupContext=r.length>1?Nc(e):null,i=wc(e),o=Ua(r,e,0,[e.props,n]),a=_(o);if(Eo(),i(),!a&&!e.sp||_s(e)||xs(e),a){if(o.then(Oc,Oc),t)return o.then(n=>{yc(!0);try{Ac(e,n,t)}finally{yc(!1)}}).catch(t=>{Ha(t,e,0)});e.asyncDep=o}else Ac(e,o,t)}else Tc(e,t)}function Ac(e,t,n){O(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:x(t)&&(e.setupState=Ta(t)),Tc(e,n)}function Tc(e,t,n){const r=e.type;if(!e.render){if(!t&&Ec&&!r.render){const t=r.template||il(e).template;if(t){0;const{isCustomElement:n,compilerOptions:i}=e.appContext.config,{delimiters:o,compilerOptions:a}=r,s=h(h({isCustomElement:n,delimiters:o},i),a);r.render=Ec(t,s)}}e.render=r.render||l,xc&&xc(e)}{const t=wc(e);So();try{el(e)}finally{Eo(),t()}}}const Rc={get(e,t){return Io(e,"get",""),e[t]}};function Nc(e){const t=t=>{e.exposed=t||{}};return{attrs:new Proxy(e.attrs,Rc),slots:e.slots,emit:e.emit,expose:t}}function Pc(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(Ta(Ea(e.exposed)),{get(t,n){return n in t?t[n]:n in Ws?Ws[n](e):void 0},has(e,t){return t in e||t in Ws}})):e.proxy}function Ic(e,t=!0){return O(e)?e.displayName||e.name:e.name||t&&e.__name}function Mc(e){return O(e)&&"__vccOpts"in e}const Dc=(e,t)=>{const n=Na(e,t,_c);return n};const Lc={createComponentInstance:mc,setupComponent:kc,renderComponentRoot:Ol,setCurrentRenderingInstance:cs,isVNode:Zl,normalizeVNode:lc,getComponentPublicInstance:Pc,ensureValidVNode:zs,pushWarningContext:Fa,popWarningContext:ja},Bc=Lc;
|
||
/**
|
||
* @vue/runtime-dom v3.5.42
|
||
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
||
* @license MIT
|
||
**/
|
||
let $c;const Vc="undefined"!==typeof window&&window.trustedTypes;if(Vc)try{$c=Vc.createPolicy("vue",{createHTML:e=>e})}catch(qp){}"undefined"!==typeof document&&document,Boolean;const Fc=Symbol("_vod"),jc=Symbol("_vsh"),Uc={name:"show",beforeMount(e,{value:t},{transition:n}){e[Fc]="none"===e.style.display?"":e.style.display,n&&t?n.beforeEnter(e):Gc(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:r}){!t!==!n&&(r?t?(r.beforeEnter(e),Gc(e,!0),r.enter(e)):r.leave(e,()=>{Gc(e,!1)}):Gc(e,t))},beforeUnmount(e,{value:t}){Gc(e,t)}};function Gc(e,t){e.style.display=t?e[Fc]:"none",e[jc]=!t}function Hc(){Uc.getSSRProps=({value:e})=>{if(!e)return{style:{display:"none"}}}}function qc(e,t,n,r){e.addEventListener(t,n,r)}"undefined"!==typeof HTMLElement&&HTMLElement;const Qc=e=>{const t=e.props["onUpdate:modelValue"]||!1;return g(t)?e=>j(t,e):t};function zc(e){e.target.composing=!0}function Kc(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const Wc=Symbol("_assign"),Xc=Symbol("_initialValue");function Yc(e,t,n){return t&&(e=e.trim()),n&&(e=G(e)),e}const Zc={created(e,{modifiers:{lazy:t,trim:n,number:r}},i){e.parentNode&&("text"===e.type?e[Xc]=e.defaultValue.replace(/[\r\n]/g,""):"textarea"===e.type&&(e[Xc]=e.defaultValue.replace(/\r\n?/g,"\n"))),e[Wc]=Qc(i);const o=r||i.props&&"number"===i.props.type;qc(e,t?"change":"input",t=>{t.target.composing||e[Wc](Yc(e.value,n,o))}),(n||o)&&qc(e,"change",()=>{e.value=Yc(e.value,n,o)}),t||(qc(e,"compositionstart",zc),qc(e,"compositionend",Kc),qc(e,"change",Kc))},mounted(e,{value:t,modifiers:{trim:n,number:r}}){const i=null==t?"":t,o=e[Xc];delete e[Xc],void 0===o||"text"!==e.type&&"textarea"!==e.type||e.value===o?e.value=i:e[Wc](Yc(e.value,n,r))},beforeUpdate(e,{value:t,oldValue:n,modifiers:{lazy:r,trim:i,number:o}},a){if(e[Wc]=Qc(a),e.composing)return;const s=!o&&"number"!==e.type||/^0\d/.test(e.value)?e.value:G(e.value),l=null==t?"":t;if(s===l)return;const c=e.getRootNode();if((c instanceof Document||c instanceof ShadowRoot)&&c.activeElement===e&&"range"!==e.type){if(r&&t===n)return;if(i&&e.value.trim()===l)return}e.value=l}},Jc={deep:!0,created(e,t,n){e[Wc]=Qc(n),qc(e,"change",()=>{const t=e._modelValue,n=ou(e),r=e.checked,i=e[Wc];if(g(t)){const e=ce(t,n),o=-1!==e;if(r&&!o)i(t.concat(n));else if(!r&&o){const n=[...t];n.splice(e,1),i(n)}}else if(b(t)){const e=new Set(t);r?e.add(n):e.delete(n),i(e)}else i(au(e,r))})},mounted:eu,beforeUpdate(e,t,n){e[Wc]=Qc(n),eu(e,t,n)}};function eu(e,{value:t,oldValue:n},r){let i;if(e._modelValue=t,g(t))i=ce(t,r.props.value)>-1;else if(b(t))i=t.has(r.props.value);else{if(t===n)return;i=le(t,au(e,!0))}e.checked!==i&&(e.checked=i)}const tu={created(e,{value:t},n){e.checked=le(t,n.props.value),e[Wc]=Qc(n),qc(e,"change",()=>{e[Wc](ou(e))})},beforeUpdate(e,{value:t,oldValue:n},r){e[Wc]=Qc(r),t!==n&&(e.checked=le(t,r.props.value))}},nu={deep:!0,created(e,{value:t,modifiers:{number:n}},r){e._modelValue=t,qc(e,"change",()=>{const t=Array.prototype.filter.call(e.options,e=>e.selected).map(e=>n?G(ou(e)):ou(e)),r=e.multiple,i=r?b(e._modelValue)?new Set(t):t:t[0],o=e._pendingValue=[r,r?g(i)?t.slice():t:i];try{e[Wc](i)}finally{Ja(()=>{e._pendingValue===o&&(e._pendingValue=void 0)})}}),e[Wc]=Qc(r)},mounted(e,{value:t}){iu(e,t)},beforeUpdate(e,{value:t},n){e._modelValue=t,e[Wc]=Qc(n)},updated(e,{value:t}){const n=e._pendingValue;e._pendingValue=void 0,n&&n[0]===e.multiple&&ru(t,n[1],n[0])||iu(e,t)}};function ru(e,t,n){if(!n)return le(e,t);if(g(e))return le(e,t);if(b(e)){if(e.size!==t.length)return!1;for(const n of t)if(!e.has(n))return!1;return!0}return!1}function iu(e,t){const n=e.multiple,r=g(t);if(!n||r||b(t)){for(let i=0,o=e.options.length;i<o;i++){const o=e.options[i],a=ou(o);if(n)if(r){const e=typeof a;o.selected="string"===e||"number"===e?t.some(e=>String(e)===String(a)):ce(t,a)>-1}else o.selected=t.has(a);else if(le(ou(o),t))return void(e.selectedIndex!==i&&(e.selectedIndex=i))}n||-1===e.selectedIndex||(e.selectedIndex=-1)}}function ou(e){return"_value"in e?e._value:e.value}function au(e,t){const n=t?"_trueValue":"_falseValue";return n in e?e[n]:t}const su={created(e,t,n){cu(e,t,n,null,"created")},mounted(e,t,n){cu(e,t,n,null,"mounted")},beforeUpdate(e,t,n,r){cu(e,t,n,r,"beforeUpdate")},updated(e,t,n,r){cu(e,t,n,r,"updated")}};function lu(e,t){switch(e){case"SELECT":return nu;case"TEXTAREA":return Zc;default:switch(t){case"checkbox":return Jc;case"radio":return tu;default:return Zc}}}function cu(e,t,n,r,i){const o=lu(e.tagName,n.props&&n.props.type),a=o[i];a&&a(e,t,n,r)}function uu(){Zc.getSSRProps=({value:e})=>({value:e}),tu.getSSRProps=({value:e},t)=>{if(t.props&&le(t.props.value,e))return{checked:!0}},Jc.getSSRProps=({value:e},t)=>{if(g(e)){if(t.props&&ce(e,t.props.value)>-1)return{checked:!0}}else if(b(e)){if(t.props&&e.has(t.props.value))return{checked:!0}}else if(e)return{checked:!0}},su.getSSRProps=(e,t)=>{if("string"!==typeof t.type)return;const n=lu(t.type.toUpperCase(),t.props&&t.props.type);return n.getSSRProps?n.getSSRProps(e,t):void 0}}let du=!1;const hu=()=>{du||(du=!0,uu(),Hc())};n(4364);const{ensureValidVNode:pu}=Bc;const{createComponentInstance:fu,setCurrentRenderingInstance:mu,setupComponent:gu,renderComponentRoot:vu,normalizeVNode:bu,pushWarningContext:yu,popWarningContext:wu}=Bc;const{isVNode:Ou}=Bc;const{isVNode:Su}=Bc;hu();var Eu=n(4364),xu=function(e,t){return xu=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},xu(e,t)};function _u(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}xu(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var ku=function(){return ku=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n],t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},ku.apply(this,arguments)};function Cu(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||(n=Promise))(function(n,o){function a(e){try{l(r.next(e))}catch(qp){o(qp)}}function s(e){try{l(r["throw"](e))}catch(qp){o(qp)}}function l(e){e.done?n(e.value):i(e.value).then(a,s)}l((r=r.apply(e,t||[])).next())})}function Au(e,t){var n,r,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"===typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(e){return function(t){return l([e,t])}}function l(s){if(n)throw new TypeError("Generator is already executing.");while(o&&(o=0,s[0]&&(a=0)),a)try{if(n=1,r&&(i=2&s[0]?r["return"]:s[0]?r["throw"]||((i=r["return"])&&i.call(r),0):r.next)&&!(i=i.call(r,s[1])).done)return i;switch(r=0,i&&(s=[2&s[0],i.value]),s[0]){case 0:case 1:i=s;break;case 4:return a.label++,{value:s[1],done:!1};case 5:a.label++,r=s[1],s=[0];continue;case 7:s=a.ops.pop(),a.trys.pop();continue;default:if(i=a.trys,!(i=i.length>0&&i[i.length-1])&&(6===s[0]||2===s[0])){a=0;continue}if(3===s[0]&&(!i||s[1]>i[0]&&s[1]<i[3])){a.label=s[1];break}if(6===s[0]&&a.label<i[1]){a.label=i[1],i=s;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(s);break}i[2]&&a.ops.pop(),a.trys.pop();continue}s=t.call(e,a)}catch(qp){s=[6,qp],r=0}finally{n=i=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}}function Tu(e,t,n){if(n||2===arguments.length)for(var r,i=0,o=t.length;i<o;i++)!r&&i in t||(r||(r=Array.prototype.slice.call(t,0,i)),r[i]=t[i]);return e.concat(r||Array.prototype.slice.call(t))}"function"===typeof SuppressedError&&SuppressedError;var Ru=function(){function e(){this.installedPlugins=[]}return e.prototype.install=function(e,t){"function"!==typeof e&&(Eu.error("plugin.install must receive a function"),e=function(){return{}}),this.installedPlugins.push({handler:e,options:t})},e.prototype.extend=function(e){var t=function(t){var n=t.handler,r=t.options;return n(e,r)},n=function(t){var n=t[0],r=t[1];e[n]="function"===typeof r?r.bind(e):r},r=function(e){e="object"===typeof e?e:{},Object.entries(e).forEach(n)};this.installedPlugins.map(t).forEach(r)},e.prototype.reset=function(){this.installedPlugins=[]},e}(),Nu={global:{stubs:{transition:!0,"transition-group":!0},provide:{},components:{},config:{},directives:{},mixins:[],mocks:{},plugins:[],renderStubDefaultSlot:!1},plugins:{VueWrapper:new Ru,DOMWrapper:new Ru}};function Pu(e,t){if(t.stubs)if(Array.isArray(t.stubs))t.stubs.forEach(function(t){return e[t]=!0});else for(var n=0,r=Object.entries(t.stubs);n<r.length;n++){var i=r[n],o=i[0],a=i[1];e[o]=a}}function Iu(e,t){return ku(ku(ku({},e),t),{globalProperties:ku(ku({},null===e||void 0===e?void 0:e.globalProperties),null===t||void 0===t?void 0:t.globalProperties)})}function Mu(e){var t,n,r;void 0===e&&(e={});var i={},o=null!==(t=null===Nu||void 0===Nu?void 0:Nu.global)&&void 0!==t?t:{};Pu(i,o),Pu(i,e);var a=null!==(r=null!==(n=e.renderStubDefaultSlot)&&void 0!==n?n:o.renderStubDefaultSlot||(null===Nu||void 0===Nu?void 0:Nu.renderStubDefaultSlot))&&void 0!==r&&r;return!0===Nu.renderStubDefaultSlot&&Eu.warn("config.renderStubDefaultSlot is deprecated, use config.global.renderStubDefaultSlot instead"),{mixins:Tu(Tu([],o.mixins||[],!0),e.mixins||[],!0),plugins:Tu(Tu([],o.plugins||[],!0),e.plugins||[],!0),stubs:i,components:ku(ku({},o.components),e.components),provide:ku(ku({},o.provide),e.provide),mocks:ku(ku({},o.mocks),e.mocks),config:Iu(o.config,e.config),directives:ku(ku({},o.directives),e.directives),renderStubDefaultSlot:a}}var Du=function(e){return!!e&&"object"===typeof e};function Lu(e){if(e instanceof Object){var t=e.constructor&&"class"===e.constructor.toString().substring(0,5);if(!("prototype"in e))return t;var n=e.prototype,r=n.constructor&&n.constructor.toString&&"class"===n.constructor.toString().substring(0,5);return t||r}}var Bu=function(e,t){var n;return Du(e)&&Du(t)?(Object.keys(t).concat(Lu(t)?Object.getOwnPropertyNames(null!==(n=Object.getPrototypeOf(t))&&void 0!==n?n:{}):Object.getOwnPropertyNames(t)).forEach(function(n){var r=e[n],i=t[n];Array.isArray(r)&&Array.isArray(i)||i instanceof Date?e[n]=i:Du(r)&&Du(i)?e[n]=Bu(Object.assign({},r),i):e[n]=i}),e):t};function $u(e){return"function"===typeof e&&"__vccOpts"in e}function Vu(e){return Boolean(e&&("object"===typeof e||"function"===typeof e))}function Fu(e){return"function"===typeof e&&!$u(e)}function ju(e){return Boolean(e&&"object"===typeof e)}function Uu(e){var t,n;return e.nodeType!==Node.COMMENT_NODE&&null!==(n=null===(t=e.textContent)||void 0===t?void 0:t.trim())&&void 0!==n?n:""}function Gu(e,t){return e.hasOwnProperty(t)}function Hu(e){return Boolean(e)}function qu(e){return"object"===typeof e&&"ref"in e}function Qu(e){return Array.isArray(e)?e.reduce(function(e,t){return e[t]=!0,e},{}):e}var zu,Ku=function(e){return e.match(/^v[A-Z].*/)};function Wu(e){var t=Qu(e);return Object.fromEntries(Object.entries(t).filter(function(e){var t=e[0];return!Ku(t)}))}function Xu(e){var t=Qu(e);return Object.fromEntries(Object.entries(t).filter(function(e){var t=e[0],n=e[1];return Ku(t)&&!1!==n}).map(function(e){var t=e[0],n=e[1];return[t.substring(1),n]}))}function Yu(e){return e&&e.$.devtoolsRawSetupState}function Zu(e){return e&&e.$.setupState.__isScriptSetup}var Ju=function(){return zu||(zu="undefined"!==typeof globalThis?globalThis:"undefined"!==typeof self?self:"undefined"!==typeof window?window:"undefined"!==typeof n.g?n.g:{})},ed=["stop","prevent","self","exact","prevent","capture"],td=["ctrl","shift","alt","meta"],nd=["left","middle","right"],rd={backspace:8,tab:9,enter:13,esc:27,space:32,pageup:33,pagedown:34,end:35,home:36,left:37,up:38,right:39,down:40,insert:45,delete:46},id={abort:{eventInterface:"Event",bubbles:!1,cancelable:!1},afterprint:{eventInterface:"Event",bubbles:!1,cancelable:!1},animationend:{eventInterface:"AnimationEvent",bubbles:!0,cancelable:!1},animationiteration:{eventInterface:"AnimationEvent",bubbles:!0,cancelable:!1},animationstart:{eventInterface:"AnimationEvent",bubbles:!0,cancelable:!1},appinstalled:{eventInterface:"Event",bubbles:!1,cancelable:!1},audioprocess:{eventInterface:"AudioProcessingEvent",bubbles:!1,cancelable:!1},audioend:{eventInterface:"Event",bubbles:!1,cancelable:!1},audiostart:{eventInterface:"Event",bubbles:!1,cancelable:!1},beforeprint:{eventInterface:"Event",bubbles:!1,cancelable:!1},beforeunload:{eventInterface:"BeforeUnloadEvent",bubbles:!1,cancelable:!0},beginEvent:{eventInterface:"TimeEvent",bubbles:!1,cancelable:!1},blur:{eventInterface:"FocusEvent",bubbles:!1,cancelable:!1},boundary:{eventInterface:"SpeechSynthesisEvent",bubbles:!1,cancelable:!1},cached:{eventInterface:"Event",bubbles:!1,cancelable:!1},canplay:{eventInterface:"Event",bubbles:!1,cancelable:!1},canplaythrough:{eventInterface:"Event",bubbles:!1,cancelable:!1},change:{eventInterface:"Event",bubbles:!0,cancelable:!1},chargingchange:{eventInterface:"Event",bubbles:!1,cancelable:!1},chargingtimechange:{eventInterface:"Event",bubbles:!1,cancelable:!1},checking:{eventInterface:"Event",bubbles:!1,cancelable:!1},click:{eventInterface:"MouseEvent",bubbles:!0,cancelable:!0},close:{eventInterface:"Event",bubbles:!1,cancelable:!1},complete:{eventInterface:"OfflineAudioCompletionEvent",bubbles:!1,cancelable:!1},compositionend:{eventInterface:"CompositionEvent",bubbles:!0,cancelable:!0},compositionstart:{eventInterface:"CompositionEvent",bubbles:!0,cancelable:!0},compositionupdate:{eventInterface:"CompositionEvent",bubbles:!0,cancelable:!1},contextmenu:{eventInterface:"MouseEvent",bubbles:!0,cancelable:!0},copy:{eventInterface:"ClipboardEvent",bubbles:!0,cancelable:!0},cut:{eventInterface:"ClipboardEvent",bubbles:!0,cancelable:!0},dblclick:{eventInterface:"MouseEvent",bubbles:!0,cancelable:!0},devicechange:{eventInterface:"Event",bubbles:!1,cancelable:!1},devicelight:{eventInterface:"DeviceLightEvent",bubbles:!1,cancelable:!1},devicemotion:{eventInterface:"DeviceMotionEvent",bubbles:!1,cancelable:!1},deviceorientation:{eventInterface:"DeviceOrientationEvent",bubbles:!1,cancelable:!1},deviceproximity:{eventInterface:"DeviceProximityEvent",bubbles:!1,cancelable:!1},dischargingtimechange:{eventInterface:"Event",bubbles:!1,cancelable:!1},DOMActivate:{eventInterface:"UIEvent",bubbles:!0,cancelable:!0},DOMAttributeNameChanged:{eventInterface:"MutationNameEvent",bubbles:!0,cancelable:!0},DOMAttrModified:{eventInterface:"MutationEvent",bubbles:!0,cancelable:!0},DOMCharacterDataModified:{eventInterface:"MutationEvent",bubbles:!0,cancelable:!0},DOMContentLoaded:{eventInterface:"Event",bubbles:!0,cancelable:!0},DOMElementNameChanged:{eventInterface:"MutationNameEvent",bubbles:!0,cancelable:!0},DOMFocusIn:{eventInterface:"FocusEvent",bubbles:!0,cancelable:!0},DOMFocusOut:{eventInterface:"FocusEvent",bubbles:!0,cancelable:!0},DOMNodeInserted:{eventInterface:"MutationEvent",bubbles:!0,cancelable:!0},DOMNodeInsertedIntoDocument:{eventInterface:"MutationEvent",bubbles:!0,cancelable:!0},DOMNodeRemoved:{eventInterface:"MutationEvent",bubbles:!0,cancelable:!0},DOMNodeRemovedFromDocument:{eventInterface:"MutationEvent",bubbles:!0,cancelable:!0},DOMSubtreeModified:{eventInterface:"MutationEvent",bubbles:!0,cancelable:!1},downloading:{eventInterface:"Event",bubbles:!1,cancelable:!1},drag:{eventInterface:"DragEvent",bubbles:!0,cancelable:!0},dragend:{eventInterface:"DragEvent",bubbles:!0,cancelable:!1},dragenter:{eventInterface:"DragEvent",bubbles:!0,cancelable:!0},dragleave:{eventInterface:"DragEvent",bubbles:!0,cancelable:!1},dragover:{eventInterface:"DragEvent",bubbles:!0,cancelable:!0},dragstart:{eventInterface:"DragEvent",bubbles:!0,cancelable:!0},drop:{eventInterface:"DragEvent",bubbles:!0,cancelable:!0},durationchange:{eventInterface:"Event",bubbles:!1,cancelable:!1},emptied:{eventInterface:"Event",bubbles:!1,cancelable:!1},end:{eventInterface:"Event",bubbles:!1,cancelable:!1},ended:{eventInterface:"Event",bubbles:!1,cancelable:!1},endEvent:{eventInterface:"TimeEvent",bubbles:!1,cancelable:!1},error:{eventInterface:"Event",bubbles:!1,cancelable:!1},focus:{eventInterface:"FocusEvent",bubbles:!1,cancelable:!1},focusin:{eventInterface:"FocusEvent",bubbles:!0,cancelable:!1},focusout:{eventInterface:"FocusEvent",bubbles:!0,cancelable:!1},fullscreenchange:{eventInterface:"Event",bubbles:!0,cancelable:!1},fullscreenerror:{eventInterface:"Event",bubbles:!0,cancelable:!1},gamepadconnected:{eventInterface:"GamepadEvent",bubbles:!1,cancelable:!1},gamepaddisconnected:{eventInterface:"GamepadEvent",bubbles:!1,cancelable:!1},gotpointercapture:{eventInterface:"PointerEvent",bubbles:!1,cancelable:!1},hashchange:{eventInterface:"HashChangeEvent",bubbles:!0,cancelable:!1},lostpointercapture:{eventInterface:"PointerEvent",bubbles:!1,cancelable:!1},input:{eventInterface:"Event",bubbles:!0,cancelable:!1},invalid:{eventInterface:"Event",cancelable:!0,bubbles:!1},keydown:{eventInterface:"KeyboardEvent",bubbles:!0,cancelable:!0},keypress:{eventInterface:"KeyboardEvent",bubbles:!0,cancelable:!0},keyup:{eventInterface:"KeyboardEvent",bubbles:!0,cancelable:!0},languagechange:{eventInterface:"Event",bubbles:!1,cancelable:!1},levelchange:{eventInterface:"Event",bubbles:!1,cancelable:!1},load:{eventInterface:"UIEvent",bubbles:!1,cancelable:!1},loadeddata:{eventInterface:"Event",bubbles:!1,cancelable:!1},loadedmetadata:{eventInterface:"Event",bubbles:!1,cancelable:!1},loadend:{eventInterface:"ProgressEvent",bubbles:!1,cancelable:!1},loadstart:{eventInterface:"ProgressEvent",bubbles:!1,cancelable:!1},mark:{eventInterface:"SpeechSynthesisEvent",bubbles:!1,cancelable:!1},message:{eventInterface:"MessageEvent",bubbles:!1,cancelable:!1},messageerror:{eventInterface:"MessageEvent",bubbles:!1,cancelable:!1},mousedown:{eventInterface:"MouseEvent",bubbles:!0,cancelable:!0},mouseenter:{eventInterface:"MouseEvent",bubbles:!1,cancelable:!1},mouseleave:{eventInterface:"MouseEvent",bubbles:!1,cancelable:!1},mousemove:{eventInterface:"MouseEvent",bubbles:!0,cancelable:!0},mouseout:{eventInterface:"MouseEvent",bubbles:!0,cancelable:!0},mouseover:{eventInterface:"MouseEvent",bubbles:!0,cancelable:!0},mouseup:{eventInterface:"MouseEvent",bubbles:!0,cancelable:!0},nomatch:{eventInterface:"SpeechRecognitionEvent",bubbles:!1,cancelable:!1},notificationclick:{eventInterface:"NotificationEvent",bubbles:!1,cancelable:!1},noupdate:{eventInterface:"Event",bubbles:!1,cancelable:!1},obsolete:{eventInterface:"Event",bubbles:!1,cancelable:!1},offline:{eventInterface:"Event",bubbles:!1,cancelable:!1},online:{eventInterface:"Event",bubbles:!1,cancelable:!1},open:{eventInterface:"Event",bubbles:!1,cancelable:!1},orientationchange:{eventInterface:"Event",bubbles:!1,cancelable:!1},pagehide:{eventInterface:"PageTransitionEvent",bubbles:!1,cancelable:!1},pageshow:{eventInterface:"PageTransitionEvent",bubbles:!1,cancelable:!1},paste:{eventInterface:"ClipboardEvent",bubbles:!0,cancelable:!0},pause:{eventInterface:"SpeechSynthesisEvent",bubbles:!1,cancelable:!1},pointercancel:{eventInterface:"PointerEvent",bubbles:!0,cancelable:!1},pointerdown:{eventInterface:"PointerEvent",bubbles:!0,cancelable:!0},pointerenter:{eventInterface:"PointerEvent",bubbles:!1,cancelable:!1},pointerleave:{eventInterface:"PointerEvent",bubbles:!1,cancelable:!1},pointerlockchange:{eventInterface:"Event",bubbles:!0,cancelable:!1},pointerlockerror:{eventInterface:"Event",bubbles:!0,cancelable:!1},pointermove:{eventInterface:"PointerEvent",bubbles:!0,cancelable:!0},pointerout:{eventInterface:"PointerEvent",bubbles:!0,cancelable:!0},pointerover:{eventInterface:"PointerEvent",bubbles:!0,cancelable:!0},pointerup:{eventInterface:"PointerEvent",bubbles:!0,cancelable:!0},play:{eventInterface:"Event",bubbles:!1,cancelable:!1},playing:{eventInterface:"Event",bubbles:!1,cancelable:!1},popstate:{eventInterface:"PopStateEvent",bubbles:!0,cancelable:!1},progress:{eventInterface:"ProgressEvent",bubbles:!1,cancelable:!1},push:{eventInterface:"PushEvent",bubbles:!1,cancelable:!1},pushsubscriptionchange:{eventInterface:"PushEvent",bubbles:!1,cancelable:!1},ratechange:{eventInterface:"Event",bubbles:!1,cancelable:!1},readystatechange:{eventInterface:"Event",bubbles:!1,cancelable:!1},repeatEvent:{eventInterface:"TimeEvent",bubbles:!1,cancelable:!1},reset:{eventInterface:"Event",bubbles:!0,cancelable:!0},resize:{eventInterface:"UIEvent",bubbles:!1,cancelable:!1},resourcetimingbufferfull:{eventInterface:"Performance",bubbles:!0,cancelable:!0},result:{eventInterface:"SpeechRecognitionEvent",bubbles:!1,cancelable:!1},resume:{eventInterface:"SpeechSynthesisEvent",bubbles:!1,cancelable:!1},scroll:{eventInterface:"UIEvent",bubbles:!1,cancelable:!1},seeked:{eventInterface:"Event",bubbles:!1,cancelable:!1},seeking:{eventInterface:"Event",bubbles:!1,cancelable:!1},select:{eventInterface:"UIEvent",bubbles:!0,cancelable:!1},selectstart:{eventInterface:"Event",bubbles:!0,cancelable:!0},selectionchange:{eventInterface:"Event",bubbles:!1,cancelable:!1},show:{eventInterface:"MouseEvent",bubbles:!1,cancelable:!1},slotchange:{eventInterface:"Event",bubbles:!0,cancelable:!1},soundend:{eventInterface:"Event",bubbles:!1,cancelable:!1},soundstart:{eventInterface:"Event",bubbles:!1,cancelable:!1},speechend:{eventInterface:"Event",bubbles:!1,cancelable:!1},speechstart:{eventInterface:"Event",bubbles:!1,cancelable:!1},stalled:{eventInterface:"Event",bubbles:!1,cancelable:!1},start:{eventInterface:"SpeechSynthesisEvent",bubbles:!1,cancelable:!1},storage:{eventInterface:"StorageEvent",bubbles:!1,cancelable:!1},submit:{eventInterface:"Event",bubbles:!0,cancelable:!0},success:{eventInterface:"Event",bubbles:!1,cancelable:!1},suspend:{eventInterface:"Event",bubbles:!1,cancelable:!1},SVGAbort:{eventInterface:"SVGEvent",bubbles:!0,cancelable:!1},SVGError:{eventInterface:"SVGEvent",bubbles:!0,cancelable:!1},SVGLoad:{eventInterface:"SVGEvent",bubbles:!1,cancelable:!1},SVGResize:{eventInterface:"SVGEvent",bubbles:!0,cancelable:!1},SVGScroll:{eventInterface:"SVGEvent",bubbles:!0,cancelable:!1},SVGUnload:{eventInterface:"SVGEvent",bubbles:!1,cancelable:!1},SVGZoom:{eventInterface:"SVGZoomEvent",bubbles:!0,cancelable:!1},timeout:{eventInterface:"ProgressEvent",bubbles:!1,cancelable:!1},timeupdate:{eventInterface:"Event",bubbles:!1,cancelable:!1},touchcancel:{eventInterface:"TouchEvent",bubbles:!0,cancelable:!1},touchend:{eventInterface:"TouchEvent",bubbles:!0,cancelable:!0},touchmove:{eventInterface:"TouchEvent",bubbles:!0,cancelable:!0},touchstart:{eventInterface:"TouchEvent",bubbles:!0,cancelable:!0},transitionend:{eventInterface:"TransitionEvent",bubbles:!0,cancelable:!0},unload:{eventInterface:"UIEvent",bubbles:!1,cancelable:!1},updateready:{eventInterface:"Event",bubbles:!1,cancelable:!1},userproximity:{eventInterface:"UserProximityEvent",bubbles:!1,cancelable:!1},voiceschanged:{eventInterface:"Event",bubbles:!1,cancelable:!1},visibilitychange:{eventInterface:"Event",bubbles:!0,cancelable:!1},volumechange:{eventInterface:"Event",bubbles:!1,cancelable:!1},waiting:{eventInterface:"Event",bubbles:!1,cancelable:!1},wheel:{eventInterface:"WheelEvent",bubbles:!0,cancelable:!0}};function od(e,t){for(var n=[],r=[],i=0;i<e.length;i++){var o=e[i];ed.includes(o)||(td.includes(o)||nd.includes(o)&&t?r.push(o):n.push(o))}return{keyModifiers:n,systemModifiers:r}}function ad(e){var t=e.modifiers,n=e.options,r=void 0===n?{}:n,i=e.eventType,o="click"===i,a=od(t,o),s=a.keyModifiers,l=a.systemModifiers;o&&(l.includes("right")?(i="contextmenu",r.button=2):l.includes("middle")&&(i="mouseup",r.button=1));var c=id[i]||{eventInterface:"Event",cancelable:!0,bubbles:!0},u=l.reduce(function(e,t){return e["".concat(t,"Key")]=!0,e},{}),d=rd[s[0]]||r&&(r.keyCode||r.code),h=ku(ku(ku(ku({},u),r),{bubbles:c.bubbles,cancelable:c.cancelable,keyCode:d,code:d}),s[0]?{key:s[0]}:{});return{eventProperties:h,meta:c,eventType:i}}function sd(e){var t=ad(e),n=t.eventProperties,r=t.meta,i=t.eventType,o=r.eventInterface,a=window[o],s="function"===typeof a?a:window.Event;return new s(i,n)}function ld(e,t){var n=e.split("."),r=n[0],i=n.slice(1),o={eventType:r,modifiers:i,options:t},a=sd(o),s=Object.getPrototypeOf(a);return t&&Object.keys(t).forEach(function(e){var n=Object.getOwnPropertyDescriptor(s,e),r=!(n&&void 0===n.set);r&&(a[e]=t[e])}),a}var cd=new WeakMap;function ud(e){var t=e.source,n=e.stub;cd.set(n,t)}function dd(e){return cd.get(e)}var hd=function(e){var t=Object.create(null);return function(n){var r=t[n];return r||(t[n]=e(n))}},pd=/-(\w)/g,fd=hd(function(e){return e.replace(pd,function(e,t){return t?t.toUpperCase():""})}),md=hd(function(e){return e.charAt(0).toUpperCase()+e.slice(1)}),gd=/\B([A-Z])/g,vd=hd(function(e){return e.replace(gd,"-$1").toLowerCase()});function bd(e,t){var n=fd(e),r=md(n);return!!t&&(t===e||t===n||t===r||md(fd(t))===r)}function yd(e){var t,n;return null!==(n=null===(t=r.compatUtils)||void 0===t?void 0:t.isCompatEnabled(e))&&void 0!==n&&n}function wd(e){return!(!yd("GLOBAL_EXTEND")||"function"!==typeof e)&&(Gu(e,"super")&&e.super.extend({}).super===e.super)}function Od(e){return wd(e)?e.options:e}function Sd(e){return Boolean(e&&"object"===typeof e&&Gu(e,"functional")&&e.functional)}var Ed,xd=function(e,t){return Object.keys((null===e||void 0===e?void 0:e.setupState)||{}).find(function(n){var r;return(null===(r=Object.getOwnPropertyDescriptor(e.setupState,n))||void 0===r?void 0:r.value)===t})},_d=function(e,t){if(!e||!e.parent)return null;var n=e.type.components;for(var r in n)if(n[r]===t)return r;return xd(e.parent,t)||null},kd=function(e,t){return ju(t)?xd(e,t)||t.name||t.__name||"":wd(t)?Od(t).name||"":Fu(t)?t.displayName||t.name:""};function Cd(e,t){var n,r,i,o=Od(t);if(!e.component)return!1;var a=e.type;if(!Vu(a))return!1;if("string"===typeof o)return null===(r=null===(n=e.el)||void 0===n?void 0:n.matches)||void 0===r?void 0:r.call(n,o);var s,l=[a,dd(a)].filter(Boolean),c=null!==(i=dd(o))&&void 0!==i?i:o;if(l.includes(c))return!0;s=kd(e.component,a);var u=o.name;if(s&&u)return bd(u,s);if(s=_d(e.component,a)||void 0,e.component.parent){var d=e.component.parent.type.components;for(var h in d)u||d[h]!==o||(u=h),s||d[h]!==a||(s=h)}return!(!u||!s)&&bd(u,s)}function Ad(e){return!!e&&"object"===typeof e}function Td(e,t){if(t&&Array.isArray(t)){var n=Tu([],t,!0).reverse().filter(Ad);n.forEach(function(t){Array.isArray(t)?Td(e,t):e.unshift(t)})}}function Rd(e,t){var n=[],r=[e];while(r.length){var i=r.shift();if(Td(r,i.children),i.component&&Td(r,[i.component.subTree]),i.suspense){var o=i.suspense.activeBranch;Td(r,[o])}Cd(i,t)&&!n.includes(i)&&n.push(i)}return n}function Nd(e,t){var n=Rd(e,t);return"string"===typeof t&&(n=n.filter(function(e){var t;return(null===(t=e.component.parent)||void 0===t?void 0:t.vnode.el)!==e.el})),n.map(function(e){return e.component})}function Pd(e){return new Proxy(Object.create(null),{get:function(t,n){switch(n){case"then":return;case"exists":return function(){return!1};default:throw new Error("Cannot call ".concat(String(n)," on an empty ").concat(e,"."))}}})}
|
||
/*!
|
||
* isElementVisible
|
||
* Adapted from https://github.com/testing-library/jest-dom
|
||
* Licensed under the MIT License.
|
||
*/function Id(e){if(!(e instanceof HTMLElement)&&!(e instanceof SVGElement))return!1;var t=getComputedStyle(e),n=t.display,r=t.visibility,i=t.opacity;return"none"!==n&&"hidden"!==r&&"collapse"!==r&&"0"!==i}function Md(e){return!e.hasAttribute("hidden")&&("DETAILS"!==e.nodeName||e.hasAttribute("open"))}function Dd(e){return"#comment"!==e.nodeName&&Id(e)&&Md(e)&&(!e.parentElement||Dd(e.parentElement))}function Ld(e){return e instanceof Element}(function(e){e[e["DOMWrapper"]=0]="DOMWrapper",e[e["VueWrapper"]=1]="VueWrapper"})(Ed||(Ed={}));var Bd={};function $d(e,t){Bd[e]=t}var Vd=function(e){return Bd[Ed.DOMWrapper](e)},Fd=function(e,t,n){return Bd[Ed.VueWrapper](e,t,n)};function jd(e){return e instanceof Element?e.outerHTML:(new XMLSerializer).serializeToString(e)}function Ud(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e["default"]:e}var Gd,Hd={exports:{}},qd={},Qd={exports:{}},zd={},Kd={};function Wd(){if(Gd)return Kd;function e(e){this.__parent=e,this.__character_count=0,this.__indent_count=-1,this.__alignment_count=0,this.__wrap_point_index=0,this.__wrap_point_character_count=0,this.__wrap_point_indent_count=-1,this.__wrap_point_alignment_count=0,this.__items=[]}function t(e,t){this.__cache=[""],this.__indent_size=e.indent_size,this.__indent_string=e.indent_char,e.indent_with_tabs||(this.__indent_string=new Array(e.indent_size+1).join(e.indent_char)),t=t||"",e.indent_level>0&&(t=new Array(e.indent_level+1).join(this.__indent_string)),this.__base_string=t,this.__base_string_length=t.length}function n(n,r){this.__indent_cache=new t(n,r),this.raw=!1,this._end_with_newline=n.end_with_newline,this.indent_size=n.indent_size,this.wrap_line_length=n.wrap_line_length,this.indent_empty_lines=n.indent_empty_lines,this.__lines=[],this.previous_line=null,this.current_line=null,this.next_line=new e(this),this.space_before_token=!1,this.non_breaking_space=!1,this.previous_token_wrapped=!1,this.__add_outputline()}return Gd=1,e.prototype.clone_empty=function(){var t=new e(this.__parent);return t.set_indent(this.__indent_count,this.__alignment_count),t},e.prototype.item=function(e){return e<0?this.__items[this.__items.length+e]:this.__items[e]},e.prototype.has_match=function(e){for(var t=this.__items.length-1;t>=0;t--)if(this.__items[t].match(e))return!0;return!1},e.prototype.set_indent=function(e,t){this.is_empty()&&(this.__indent_count=e||0,this.__alignment_count=t||0,this.__character_count=this.__parent.get_indent_size(this.__indent_count,this.__alignment_count))},e.prototype._set_wrap_point=function(){this.__parent.wrap_line_length&&(this.__wrap_point_index=this.__items.length,this.__wrap_point_character_count=this.__character_count,this.__wrap_point_indent_count=this.__parent.next_line.__indent_count,this.__wrap_point_alignment_count=this.__parent.next_line.__alignment_count)},e.prototype._should_wrap=function(){return this.__wrap_point_index&&this.__character_count>this.__parent.wrap_line_length&&this.__wrap_point_character_count>this.__parent.next_line.__character_count},e.prototype._allow_wrap=function(){if(this._should_wrap()){this.__parent.add_new_line();var e=this.__parent.current_line;return e.set_indent(this.__wrap_point_indent_count,this.__wrap_point_alignment_count),e.__items=this.__items.slice(this.__wrap_point_index),this.__items=this.__items.slice(0,this.__wrap_point_index),e.__character_count+=this.__character_count-this.__wrap_point_character_count,this.__character_count=this.__wrap_point_character_count," "===e.__items[0]&&(e.__items.splice(0,1),e.__character_count-=1),!0}return!1},e.prototype.is_empty=function(){return 0===this.__items.length},e.prototype.last=function(){return this.is_empty()?null:this.__items[this.__items.length-1]},e.prototype.push=function(e){this.__items.push(e);var t=e.lastIndexOf("\n");-1!==t?this.__character_count=e.length-t:this.__character_count+=e.length},e.prototype.pop=function(){var e=null;return this.is_empty()||(e=this.__items.pop(),this.__character_count-=e.length),e},e.prototype._remove_indent=function(){this.__indent_count>0&&(this.__indent_count-=1,this.__character_count-=this.__parent.indent_size)},e.prototype._remove_wrap_indent=function(){this.__wrap_point_indent_count>0&&(this.__wrap_point_indent_count-=1)},e.prototype.trim=function(){while(" "===this.last())this.__items.pop(),this.__character_count-=1},e.prototype.toString=function(){var e="";return this.is_empty()?this.__parent.indent_empty_lines&&(e=this.__parent.get_indent_string(this.__indent_count)):(e=this.__parent.get_indent_string(this.__indent_count,this.__alignment_count),e+=this.__items.join("")),e},t.prototype.get_indent_size=function(e,t){var n=this.__base_string_length;return t=t||0,e<0&&(n=0),n+=e*this.__indent_size,n+=t,n},t.prototype.get_indent_string=function(e,t){var n=this.__base_string;return t=t||0,e<0&&(e=0,n=""),t+=e*this.__indent_size,this.__ensure_cache(t),n+=this.__cache[t],n},t.prototype.__ensure_cache=function(e){while(e>=this.__cache.length)this.__add_column()},t.prototype.__add_column=function(){var e=this.__cache.length,t=0,n="";this.__indent_size&&e>=this.__indent_size&&(t=Math.floor(e/this.__indent_size),e-=t*this.__indent_size,n=new Array(t+1).join(this.__indent_string)),e&&(n+=new Array(e+1).join(" ")),this.__cache.push(n)},n.prototype.__add_outputline=function(){this.previous_line=this.current_line,this.current_line=this.next_line.clone_empty(),this.__lines.push(this.current_line)},n.prototype.get_line_number=function(){return this.__lines.length},n.prototype.get_indent_string=function(e,t){return this.__indent_cache.get_indent_string(e,t)},n.prototype.get_indent_size=function(e,t){return this.__indent_cache.get_indent_size(e,t)},n.prototype.is_empty=function(){return!this.previous_line&&this.current_line.is_empty()},n.prototype.add_new_line=function(e){return!(this.is_empty()||!e&&this.just_added_newline())&&(this.raw||this.__add_outputline(),!0)},n.prototype.get_code=function(e){this.trim(!0);var t=this.current_line.pop();t&&("\n"===t[t.length-1]&&(t=t.replace(/\n+$/g,"")),this.current_line.push(t)),this._end_with_newline&&this.__add_outputline();var n=this.__lines.join("\n");return"\n"!==e&&(n=n.replace(/[\n]/g,e)),n},n.prototype.set_wrap_point=function(){this.current_line._set_wrap_point()},n.prototype.set_indent=function(e,t){return e=e||0,t=t||0,this.next_line.set_indent(e,t),this.__lines.length>1?(this.current_line.set_indent(e,t),!0):(this.current_line.set_indent(),!1)},n.prototype.add_raw_token=function(e){for(var t=0;t<e.newlines;t++)this.__add_outputline();this.current_line.set_indent(-1),this.current_line.push(e.whitespace_before),this.current_line.push(e.text),this.space_before_token=!1,this.non_breaking_space=!1,this.previous_token_wrapped=!1},n.prototype.add_token=function(e){this.__add_space_before_token(),this.current_line.push(e),this.space_before_token=!1,this.non_breaking_space=!1,this.previous_token_wrapped=this.current_line._allow_wrap()},n.prototype.__add_space_before_token=function(){this.space_before_token&&!this.just_added_newline()&&(this.non_breaking_space||this.set_wrap_point(),this.current_line.push(" "))},n.prototype.remove_indent=function(e){var t=this.__lines.length;while(e<t)this.__lines[e]._remove_indent(),e++;this.current_line._remove_wrap_indent()},n.prototype.trim=function(e){e=void 0!==e&&e,this.current_line.trim();while(e&&this.__lines.length>1&&this.current_line.is_empty())this.__lines.pop(),this.current_line=this.__lines[this.__lines.length-1],this.current_line.trim();this.previous_line=this.__lines.length>1?this.__lines[this.__lines.length-2]:null},n.prototype.just_added_newline=function(){return this.current_line.is_empty()},n.prototype.just_added_blankline=function(){return this.is_empty()||this.current_line.is_empty()&&this.previous_line.is_empty()},n.prototype.ensure_empty_line_above=function(t,n){var r=this.__lines.length-2;while(r>=0){var i=this.__lines[r];if(i.is_empty())break;if(0!==i.item(0).indexOf(t)&&i.item(-1)!==n){this.__lines.splice(r+1,0,new e(this)),this.previous_line=this.__lines[this.__lines.length-2];break}r--}},Kd.Output=n,Kd}var Xd,Yd={};function Zd(){if(Xd)return Yd;function e(e,t,n,r){this.type=e,this.text=t,this.comments_before=null,this.newlines=n||0,this.whitespace_before=r||"",this.parent=null,this.next=null,this.previous=null,this.opened=null,this.closed=null,this.directives=null}return Xd=1,Yd.Token=e,Yd}var Jd,eh={};function th(){return Jd||(Jd=1,function(e){var t="\\x23\\x24\\x40\\x41-\\x5a\\x5f\\x61-\\x7a",n="\\x24\\x30-\\x39\\x41-\\x5a\\x5f\\x61-\\x7a",r="\\xaa\\xb5\\xba\\xc0-\\xd6\\xd8-\\xf6\\xf8-\\u02c1\\u02c6-\\u02d1\\u02e0-\\u02e4\\u02ec\\u02ee\\u0370-\\u0374\\u0376\\u0377\\u037a-\\u037d\\u0386\\u0388-\\u038a\\u038c\\u038e-\\u03a1\\u03a3-\\u03f5\\u03f7-\\u0481\\u048a-\\u0527\\u0531-\\u0556\\u0559\\u0561-\\u0587\\u05d0-\\u05ea\\u05f0-\\u05f2\\u0620-\\u064a\\u066e\\u066f\\u0671-\\u06d3\\u06d5\\u06e5\\u06e6\\u06ee\\u06ef\\u06fa-\\u06fc\\u06ff\\u0710\\u0712-\\u072f\\u074d-\\u07a5\\u07b1\\u07ca-\\u07ea\\u07f4\\u07f5\\u07fa\\u0800-\\u0815\\u081a\\u0824\\u0828\\u0840-\\u0858\\u08a0\\u08a2-\\u08ac\\u0904-\\u0939\\u093d\\u0950\\u0958-\\u0961\\u0971-\\u0977\\u0979-\\u097f\\u0985-\\u098c\\u098f\\u0990\\u0993-\\u09a8\\u09aa-\\u09b0\\u09b2\\u09b6-\\u09b9\\u09bd\\u09ce\\u09dc\\u09dd\\u09df-\\u09e1\\u09f0\\u09f1\\u0a05-\\u0a0a\\u0a0f\\u0a10\\u0a13-\\u0a28\\u0a2a-\\u0a30\\u0a32\\u0a33\\u0a35\\u0a36\\u0a38\\u0a39\\u0a59-\\u0a5c\\u0a5e\\u0a72-\\u0a74\\u0a85-\\u0a8d\\u0a8f-\\u0a91\\u0a93-\\u0aa8\\u0aaa-\\u0ab0\\u0ab2\\u0ab3\\u0ab5-\\u0ab9\\u0abd\\u0ad0\\u0ae0\\u0ae1\\u0b05-\\u0b0c\\u0b0f\\u0b10\\u0b13-\\u0b28\\u0b2a-\\u0b30\\u0b32\\u0b33\\u0b35-\\u0b39\\u0b3d\\u0b5c\\u0b5d\\u0b5f-\\u0b61\\u0b71\\u0b83\\u0b85-\\u0b8a\\u0b8e-\\u0b90\\u0b92-\\u0b95\\u0b99\\u0b9a\\u0b9c\\u0b9e\\u0b9f\\u0ba3\\u0ba4\\u0ba8-\\u0baa\\u0bae-\\u0bb9\\u0bd0\\u0c05-\\u0c0c\\u0c0e-\\u0c10\\u0c12-\\u0c28\\u0c2a-\\u0c33\\u0c35-\\u0c39\\u0c3d\\u0c58\\u0c59\\u0c60\\u0c61\\u0c85-\\u0c8c\\u0c8e-\\u0c90\\u0c92-\\u0ca8\\u0caa-\\u0cb3\\u0cb5-\\u0cb9\\u0cbd\\u0cde\\u0ce0\\u0ce1\\u0cf1\\u0cf2\\u0d05-\\u0d0c\\u0d0e-\\u0d10\\u0d12-\\u0d3a\\u0d3d\\u0d4e\\u0d60\\u0d61\\u0d7a-\\u0d7f\\u0d85-\\u0d96\\u0d9a-\\u0db1\\u0db3-\\u0dbb\\u0dbd\\u0dc0-\\u0dc6\\u0e01-\\u0e30\\u0e32\\u0e33\\u0e40-\\u0e46\\u0e81\\u0e82\\u0e84\\u0e87\\u0e88\\u0e8a\\u0e8d\\u0e94-\\u0e97\\u0e99-\\u0e9f\\u0ea1-\\u0ea3\\u0ea5\\u0ea7\\u0eaa\\u0eab\\u0ead-\\u0eb0\\u0eb2\\u0eb3\\u0ebd\\u0ec0-\\u0ec4\\u0ec6\\u0edc-\\u0edf\\u0f00\\u0f40-\\u0f47\\u0f49-\\u0f6c\\u0f88-\\u0f8c\\u1000-\\u102a\\u103f\\u1050-\\u1055\\u105a-\\u105d\\u1061\\u1065\\u1066\\u106e-\\u1070\\u1075-\\u1081\\u108e\\u10a0-\\u10c5\\u10c7\\u10cd\\u10d0-\\u10fa\\u10fc-\\u1248\\u124a-\\u124d\\u1250-\\u1256\\u1258\\u125a-\\u125d\\u1260-\\u1288\\u128a-\\u128d\\u1290-\\u12b0\\u12b2-\\u12b5\\u12b8-\\u12be\\u12c0\\u12c2-\\u12c5\\u12c8-\\u12d6\\u12d8-\\u1310\\u1312-\\u1315\\u1318-\\u135a\\u1380-\\u138f\\u13a0-\\u13f4\\u1401-\\u166c\\u166f-\\u167f\\u1681-\\u169a\\u16a0-\\u16ea\\u16ee-\\u16f0\\u1700-\\u170c\\u170e-\\u1711\\u1720-\\u1731\\u1740-\\u1751\\u1760-\\u176c\\u176e-\\u1770\\u1780-\\u17b3\\u17d7\\u17dc\\u1820-\\u1877\\u1880-\\u18a8\\u18aa\\u18b0-\\u18f5\\u1900-\\u191c\\u1950-\\u196d\\u1970-\\u1974\\u1980-\\u19ab\\u19c1-\\u19c7\\u1a00-\\u1a16\\u1a20-\\u1a54\\u1aa7\\u1b05-\\u1b33\\u1b45-\\u1b4b\\u1b83-\\u1ba0\\u1bae\\u1baf\\u1bba-\\u1be5\\u1c00-\\u1c23\\u1c4d-\\u1c4f\\u1c5a-\\u1c7d\\u1ce9-\\u1cec\\u1cee-\\u1cf1\\u1cf5\\u1cf6\\u1d00-\\u1dbf\\u1e00-\\u1f15\\u1f18-\\u1f1d\\u1f20-\\u1f45\\u1f48-\\u1f4d\\u1f50-\\u1f57\\u1f59\\u1f5b\\u1f5d\\u1f5f-\\u1f7d\\u1f80-\\u1fb4\\u1fb6-\\u1fbc\\u1fbe\\u1fc2-\\u1fc4\\u1fc6-\\u1fcc\\u1fd0-\\u1fd3\\u1fd6-\\u1fdb\\u1fe0-\\u1fec\\u1ff2-\\u1ff4\\u1ff6-\\u1ffc\\u2071\\u207f\\u2090-\\u209c\\u2102\\u2107\\u210a-\\u2113\\u2115\\u2119-\\u211d\\u2124\\u2126\\u2128\\u212a-\\u212d\\u212f-\\u2139\\u213c-\\u213f\\u2145-\\u2149\\u214e\\u2160-\\u2188\\u2c00-\\u2c2e\\u2c30-\\u2c5e\\u2c60-\\u2ce4\\u2ceb-\\u2cee\\u2cf2\\u2cf3\\u2d00-\\u2d25\\u2d27\\u2d2d\\u2d30-\\u2d67\\u2d6f\\u2d80-\\u2d96\\u2da0-\\u2da6\\u2da8-\\u2dae\\u2db0-\\u2db6\\u2db8-\\u2dbe\\u2dc0-\\u2dc6\\u2dc8-\\u2dce\\u2dd0-\\u2dd6\\u2dd8-\\u2dde\\u2e2f\\u3005-\\u3007\\u3021-\\u3029\\u3031-\\u3035\\u3038-\\u303c\\u3041-\\u3096\\u309d-\\u309f\\u30a1-\\u30fa\\u30fc-\\u30ff\\u3105-\\u312d\\u3131-\\u318e\\u31a0-\\u31ba\\u31f0-\\u31ff\\u3400-\\u4db5\\u4e00-\\u9fcc\\ua000-\\ua48c\\ua4d0-\\ua4fd\\ua500-\\ua60c\\ua610-\\ua61f\\ua62a\\ua62b\\ua640-\\ua66e\\ua67f-\\ua697\\ua6a0-\\ua6ef\\ua717-\\ua71f\\ua722-\\ua788\\ua78b-\\ua78e\\ua790-\\ua793\\ua7a0-\\ua7aa\\ua7f8-\\ua801\\ua803-\\ua805\\ua807-\\ua80a\\ua80c-\\ua822\\ua840-\\ua873\\ua882-\\ua8b3\\ua8f2-\\ua8f7\\ua8fb\\ua90a-\\ua925\\ua930-\\ua946\\ua960-\\ua97c\\ua984-\\ua9b2\\ua9cf\\uaa00-\\uaa28\\uaa40-\\uaa42\\uaa44-\\uaa4b\\uaa60-\\uaa76\\uaa7a\\uaa80-\\uaaaf\\uaab1\\uaab5\\uaab6\\uaab9-\\uaabd\\uaac0\\uaac2\\uaadb-\\uaadd\\uaae0-\\uaaea\\uaaf2-\\uaaf4\\uab01-\\uab06\\uab09-\\uab0e\\uab11-\\uab16\\uab20-\\uab26\\uab28-\\uab2e\\uabc0-\\uabe2\\uac00-\\ud7a3\\ud7b0-\\ud7c6\\ud7cb-\\ud7fb\\uf900-\\ufa6d\\ufa70-\\ufad9\\ufb00-\\ufb06\\ufb13-\\ufb17\\ufb1d\\ufb1f-\\ufb28\\ufb2a-\\ufb36\\ufb38-\\ufb3c\\ufb3e\\ufb40\\ufb41\\ufb43\\ufb44\\ufb46-\\ufbb1\\ufbd3-\\ufd3d\\ufd50-\\ufd8f\\ufd92-\\ufdc7\\ufdf0-\\ufdfb\\ufe70-\\ufe74\\ufe76-\\ufefc\\uff21-\\uff3a\\uff41-\\uff5a\\uff66-\\uffbe\\uffc2-\\uffc7\\uffca-\\uffcf\\uffd2-\\uffd7\\uffda-\\uffdc",i="\\u0300-\\u036f\\u0483-\\u0487\\u0591-\\u05bd\\u05bf\\u05c1\\u05c2\\u05c4\\u05c5\\u05c7\\u0610-\\u061a\\u0620-\\u0649\\u0672-\\u06d3\\u06e7-\\u06e8\\u06fb-\\u06fc\\u0730-\\u074a\\u0800-\\u0814\\u081b-\\u0823\\u0825-\\u0827\\u0829-\\u082d\\u0840-\\u0857\\u08e4-\\u08fe\\u0900-\\u0903\\u093a-\\u093c\\u093e-\\u094f\\u0951-\\u0957\\u0962-\\u0963\\u0966-\\u096f\\u0981-\\u0983\\u09bc\\u09be-\\u09c4\\u09c7\\u09c8\\u09d7\\u09df-\\u09e0\\u0a01-\\u0a03\\u0a3c\\u0a3e-\\u0a42\\u0a47\\u0a48\\u0a4b-\\u0a4d\\u0a51\\u0a66-\\u0a71\\u0a75\\u0a81-\\u0a83\\u0abc\\u0abe-\\u0ac5\\u0ac7-\\u0ac9\\u0acb-\\u0acd\\u0ae2-\\u0ae3\\u0ae6-\\u0aef\\u0b01-\\u0b03\\u0b3c\\u0b3e-\\u0b44\\u0b47\\u0b48\\u0b4b-\\u0b4d\\u0b56\\u0b57\\u0b5f-\\u0b60\\u0b66-\\u0b6f\\u0b82\\u0bbe-\\u0bc2\\u0bc6-\\u0bc8\\u0bca-\\u0bcd\\u0bd7\\u0be6-\\u0bef\\u0c01-\\u0c03\\u0c46-\\u0c48\\u0c4a-\\u0c4d\\u0c55\\u0c56\\u0c62-\\u0c63\\u0c66-\\u0c6f\\u0c82\\u0c83\\u0cbc\\u0cbe-\\u0cc4\\u0cc6-\\u0cc8\\u0cca-\\u0ccd\\u0cd5\\u0cd6\\u0ce2-\\u0ce3\\u0ce6-\\u0cef\\u0d02\\u0d03\\u0d46-\\u0d48\\u0d57\\u0d62-\\u0d63\\u0d66-\\u0d6f\\u0d82\\u0d83\\u0dca\\u0dcf-\\u0dd4\\u0dd6\\u0dd8-\\u0ddf\\u0df2\\u0df3\\u0e34-\\u0e3a\\u0e40-\\u0e45\\u0e50-\\u0e59\\u0eb4-\\u0eb9\\u0ec8-\\u0ecd\\u0ed0-\\u0ed9\\u0f18\\u0f19\\u0f20-\\u0f29\\u0f35\\u0f37\\u0f39\\u0f41-\\u0f47\\u0f71-\\u0f84\\u0f86-\\u0f87\\u0f8d-\\u0f97\\u0f99-\\u0fbc\\u0fc6\\u1000-\\u1029\\u1040-\\u1049\\u1067-\\u106d\\u1071-\\u1074\\u1082-\\u108d\\u108f-\\u109d\\u135d-\\u135f\\u170e-\\u1710\\u1720-\\u1730\\u1740-\\u1750\\u1772\\u1773\\u1780-\\u17b2\\u17dd\\u17e0-\\u17e9\\u180b-\\u180d\\u1810-\\u1819\\u1920-\\u192b\\u1930-\\u193b\\u1951-\\u196d\\u19b0-\\u19c0\\u19c8-\\u19c9\\u19d0-\\u19d9\\u1a00-\\u1a15\\u1a20-\\u1a53\\u1a60-\\u1a7c\\u1a7f-\\u1a89\\u1a90-\\u1a99\\u1b46-\\u1b4b\\u1b50-\\u1b59\\u1b6b-\\u1b73\\u1bb0-\\u1bb9\\u1be6-\\u1bf3\\u1c00-\\u1c22\\u1c40-\\u1c49\\u1c5b-\\u1c7d\\u1cd0-\\u1cd2\\u1d00-\\u1dbe\\u1e01-\\u1f15\\u200c\\u200d\\u203f\\u2040\\u2054\\u20d0-\\u20dc\\u20e1\\u20e5-\\u20f0\\u2d81-\\u2d96\\u2de0-\\u2dff\\u3021-\\u3028\\u3099\\u309a\\ua640-\\ua66d\\ua674-\\ua67d\\ua69f\\ua6f0-\\ua6f1\\ua7f8-\\ua800\\ua806\\ua80b\\ua823-\\ua827\\ua880-\\ua881\\ua8b4-\\ua8c4\\ua8d0-\\ua8d9\\ua8f3-\\ua8f7\\ua900-\\ua909\\ua926-\\ua92d\\ua930-\\ua945\\ua980-\\ua983\\ua9b3-\\ua9c0\\uaa00-\\uaa27\\uaa40-\\uaa41\\uaa4c-\\uaa4d\\uaa50-\\uaa59\\uaa7b\\uaae0-\\uaae9\\uaaf2-\\uaaf3\\uabc0-\\uabe1\\uabec\\uabed\\uabf0-\\uabf9\\ufb20-\\ufb28\\ufe00-\\ufe0f\\ufe20-\\ufe26\\ufe33\\ufe34\\ufe4d-\\ufe4f\\uff10-\\uff19\\uff3f",o="(?:\\\\u[0-9a-fA-F]{4}|["+t+r+"])",a="(?:\\\\u[0-9a-fA-F]{4}|["+n+r+i+"])*";e.identifier=new RegExp(o+a,"g"),e.identifierStart=new RegExp(o),e.identifierMatch=new RegExp("(?:\\\\u[0-9a-fA-F]{4}|["+n+r+i+"])+"),e.newline=/[\n\r\u2028\u2029]/,e.lineBreak=new RegExp("\r\n|"+e.newline.source),e.allLineBreaks=new RegExp(e.lineBreak.source,"g")}(eh)),eh}var nh,rh,ih={},oh={};function ah(){if(nh)return oh;function e(e,n){this.raw_options=t(e,n),this.disabled=this._get_boolean("disabled"),this.eol=this._get_characters("eol","auto"),this.end_with_newline=this._get_boolean("end_with_newline"),this.indent_size=this._get_number("indent_size",4),this.indent_char=this._get_characters("indent_char"," "),this.indent_level=this._get_number("indent_level"),this.preserve_newlines=this._get_boolean("preserve_newlines",!0),this.max_preserve_newlines=this._get_number("max_preserve_newlines",32786),this.preserve_newlines||(this.max_preserve_newlines=0),this.indent_with_tabs=this._get_boolean("indent_with_tabs","\t"===this.indent_char),this.indent_with_tabs&&(this.indent_char="\t",1===this.indent_size&&(this.indent_size=4)),this.wrap_line_length=this._get_number("wrap_line_length",this._get_number("max_char")),this.indent_empty_lines=this._get_boolean("indent_empty_lines"),this.templating=this._get_selection_list("templating",["auto","none","django","erb","handlebars","php","smarty"],["auto"])}function t(e,t){var r,i={};for(r in e=n(e),e)r!==t&&(i[r]=e[r]);if(t&&e[t])for(r in e[t])i[r]=e[t][r];return i}function n(e){var t,n={};for(t in e){var r=t.replace(/-/g,"_");n[r]=e[t]}return n}return nh=1,e.prototype._get_array=function(e,t){var n=this.raw_options[e],r=t||[];return"object"===typeof n?null!==n&&"function"===typeof n.concat&&(r=n.concat()):"string"===typeof n&&(r=n.split(/[^a-zA-Z0-9_\/\-]+/)),r},e.prototype._get_boolean=function(e,t){var n=this.raw_options[e],r=void 0===n?!!t:!!n;return r},e.prototype._get_characters=function(e,t){var n=this.raw_options[e],r=t||"";return"string"===typeof n&&(r=n.replace(/\\r/,"\r").replace(/\\n/,"\n").replace(/\\t/,"\t")),r},e.prototype._get_number=function(e,t){var n=this.raw_options[e];t=parseInt(t,10),isNaN(t)&&(t=0);var r=parseInt(n,10);return isNaN(r)&&(r=t),r},e.prototype._get_selection=function(e,t,n){var r=this._get_selection_list(e,t,n);if(1!==r.length)throw new Error("Invalid Option Value: The option '"+e+"' can only be one of the following values:\n"+t+"\nYou passed in: '"+this.raw_options[e]+"'");return r[0]},e.prototype._get_selection_list=function(e,t,n){if(!t||0===t.length)throw new Error("Selection list cannot be empty.");if(n=n||[t[0]],!this._is_valid_selection(n,t))throw new Error("Invalid Default Value!");var r=this._get_array(e,n);if(!this._is_valid_selection(r,t))throw new Error("Invalid Option Value: The option '"+e+"' can contain only the following values:\n"+t+"\nYou passed in: '"+this.raw_options[e]+"'");return r},e.prototype._is_valid_selection=function(e,t){return e.length&&t.length&&!e.some(function(e){return-1===t.indexOf(e)})},oh.Options=e,oh.normalizeOpts=n,oh.mergeOpts=t,oh}function sh(){if(rh)return ih;rh=1;var e=ah().Options,t=["before-newline","after-newline","preserve-newline"];function n(n){e.call(this,n,"js");var r=this.raw_options.brace_style||null;"expand-strict"===r?this.raw_options.brace_style="expand":"collapse-preserve-inline"===r?this.raw_options.brace_style="collapse,preserve-inline":void 0!==this.raw_options.braces_on_own_line&&(this.raw_options.brace_style=this.raw_options.braces_on_own_line?"expand":"collapse");var i=this._get_selection_list("brace_style",["collapse","expand","end-expand","none","preserve-inline"]);this.brace_preserve_inline=!1,this.brace_style="collapse";for(var o=0;o<i.length;o++)"preserve-inline"===i[o]?this.brace_preserve_inline=!0:this.brace_style=i[o];this.unindent_chained_methods=this._get_boolean("unindent_chained_methods"),this.break_chained_methods=this._get_boolean("break_chained_methods"),this.space_in_paren=this._get_boolean("space_in_paren"),this.space_in_empty_paren=this._get_boolean("space_in_empty_paren"),this.jslint_happy=this._get_boolean("jslint_happy"),this.space_after_anon_function=this._get_boolean("space_after_anon_function"),this.space_after_named_function=this._get_boolean("space_after_named_function"),this.keep_array_indentation=this._get_boolean("keep_array_indentation"),this.space_before_conditional=this._get_boolean("space_before_conditional",!0),this.unescape_strings=this._get_boolean("unescape_strings"),this.e4x=this._get_boolean("e4x"),this.comma_first=this._get_boolean("comma_first"),this.operator_position=this._get_selection("operator_position",t),this.test_output_raw=this._get_boolean("test_output_raw"),this.jslint_happy&&(this.space_after_anon_function=!0)}return n.prototype=new e,ih.Options=n,ih}var lh,ch={},uh={};function dh(){if(lh)return uh;lh=1;var e=RegExp.prototype.hasOwnProperty("sticky");function t(e){this.__input=e||"",this.__input_length=this.__input.length,this.__position=0}return t.prototype.restart=function(){this.__position=0},t.prototype.back=function(){this.__position>0&&(this.__position-=1)},t.prototype.hasNext=function(){return this.__position<this.__input_length},t.prototype.next=function(){var e=null;return this.hasNext()&&(e=this.__input.charAt(this.__position),this.__position+=1),e},t.prototype.peek=function(e){var t=null;return e=e||0,e+=this.__position,e>=0&&e<this.__input_length&&(t=this.__input.charAt(e)),t},t.prototype.__match=function(t,n){t.lastIndex=n;var r=t.exec(this.__input);return!r||e&&t.sticky||r.index!==n&&(r=null),r},t.prototype.test=function(e,t){return t=t||0,t+=this.__position,t>=0&&t<this.__input_length&&!!this.__match(e,t)},t.prototype.testChar=function(e,t){var n=this.peek(t);return e.lastIndex=0,null!==n&&e.test(n)},t.prototype.match=function(e){var t=this.__match(e,this.__position);return t?this.__position+=t[0].length:t=null,t},t.prototype.read=function(e,t,n){var r,i="";return e&&(r=this.match(e),r&&(i+=r[0])),!t||!r&&e||(i+=this.readUntil(t,n)),i},t.prototype.readUntil=function(e,t){var n="",r=this.__position;e.lastIndex=this.__position;var i=e.exec(this.__input);return i?(r=i.index,t&&(r+=i[0].length)):r=this.__input_length,n=this.__input.substring(this.__position,r),this.__position=r,n},t.prototype.readUntilAfter=function(e){return this.readUntil(e,!0)},t.prototype.get_regexp=function(t,n){var r=null,i="g";return n&&e&&(i="y"),"string"===typeof t&&""!==t?r=new RegExp(t,i):t&&(r=new RegExp(t.source,i)),r},t.prototype.get_literal_regexp=function(e){return RegExp(e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&"))},t.prototype.peekUntilAfter=function(e){var t=this.__position,n=this.readUntilAfter(e);return this.__position=t,n},t.prototype.lookBack=function(e){var t=this.__position-1;return t>=e.length&&this.__input.substring(t-e.length,t).toLowerCase()===e},uh.InputScanner=t,uh}var hh,ph={},fh={};function mh(){if(hh)return fh;function e(e){this.__tokens=[],this.__tokens_length=this.__tokens.length,this.__position=0,this.__parent_token=e}return hh=1,e.prototype.restart=function(){this.__position=0},e.prototype.isEmpty=function(){return 0===this.__tokens_length},e.prototype.hasNext=function(){return this.__position<this.__tokens_length},e.prototype.next=function(){var e=null;return this.hasNext()&&(e=this.__tokens[this.__position],this.__position+=1),e},e.prototype.peek=function(e){var t=null;return e=e||0,e+=this.__position,e>=0&&e<this.__tokens_length&&(t=this.__tokens[e]),t},e.prototype.add=function(e){this.__parent_token&&(e.parent=this.__parent_token),this.__tokens.push(e),this.__tokens_length+=1},fh.TokenStream=e,fh}var gh,vh,bh,yh={},wh={};function Oh(){if(gh)return wh;function e(e,t){this._input=e,this._starting_pattern=null,this._match_pattern=null,this._until_pattern=null,this._until_after=!1,t&&(this._starting_pattern=this._input.get_regexp(t._starting_pattern,!0),this._match_pattern=this._input.get_regexp(t._match_pattern,!0),this._until_pattern=this._input.get_regexp(t._until_pattern),this._until_after=t._until_after)}return gh=1,e.prototype.read=function(){var e=this._input.read(this._starting_pattern);return this._starting_pattern&&!e||(e+=this._input.read(this._match_pattern,this._until_pattern,this._until_after)),e},e.prototype.read_match=function(){return this._input.match(this._match_pattern)},e.prototype.until_after=function(e){var t=this._create();return t._until_after=!0,t._until_pattern=this._input.get_regexp(e),t._update(),t},e.prototype.until=function(e){var t=this._create();return t._until_after=!1,t._until_pattern=this._input.get_regexp(e),t._update(),t},e.prototype.starting_with=function(e){var t=this._create();return t._starting_pattern=this._input.get_regexp(e,!0),t._update(),t},e.prototype.matching=function(e){var t=this._create();return t._match_pattern=this._input.get_regexp(e,!0),t._update(),t},e.prototype._create=function(){return new e(this._input,this)},e.prototype._update=function(){},wh.Pattern=e,wh}function Sh(){if(vh)return yh;vh=1;var e=Oh().Pattern;function t(t,n){e.call(this,t,n),n?this._line_regexp=this._input.get_regexp(n._line_regexp):this.__set_whitespace_patterns("",""),this.newline_count=0,this.whitespace_before_token=""}return t.prototype=new e,t.prototype.__set_whitespace_patterns=function(e,t){e+="\\t ",t+="\\n\\r",this._match_pattern=this._input.get_regexp("["+e+t+"]+",!0),this._newline_regexp=this._input.get_regexp("\\r\\n|["+t+"]")},t.prototype.read=function(){this.newline_count=0,this.whitespace_before_token="";var e=this._input.read(this._match_pattern);if(" "===e)this.whitespace_before_token=" ";else if(e){var t=this.__split(this._newline_regexp,e);this.newline_count=t.length-1,this.whitespace_before_token=t[this.newline_count]}return e},t.prototype.matching=function(e,t){var n=this._create();return n.__set_whitespace_patterns(e,t),n._update(),n},t.prototype._create=function(){return new t(this._input,this)},t.prototype.__split=function(e,t){e.lastIndex=0;var n=0,r=[],i=e.exec(t);while(i)r.push(t.substring(n,i.index)),n=i.index+i[0].length,i=e.exec(t);return n<t.length?r.push(t.substring(n,t.length)):r.push(""),r},yh.WhitespacePattern=t,yh}function Eh(){if(bh)return ph;bh=1;var e=dh().InputScanner,t=Zd().Token,n=mh().TokenStream,r=Sh().WhitespacePattern,i={START:"TK_START",RAW:"TK_RAW",EOF:"TK_EOF"},o=function(t,n){this._input=new e(t),this._options=n||{},this.__tokens=null,this._patterns={},this._patterns.whitespace=new r(this._input)};return o.prototype.tokenize=function(){var e;this._input.restart(),this.__tokens=new n,this._reset();var r=new t(i.START,""),o=null,a=[],s=new n;while(r.type!==i.EOF){e=this._get_next_token(r,o);while(this._is_comment(e))s.add(e),e=this._get_next_token(r,o);s.isEmpty()||(e.comments_before=s,s=new n),e.parent=o,this._is_opening(e)?(a.push(o),o=e):o&&this._is_closing(e,o)&&(e.opened=o,o.closed=e,o=a.pop(),e.parent=o),e.previous=r,r.next=e,this.__tokens.add(e),r=e}return this.__tokens},o.prototype._is_first_token=function(){return this.__tokens.isEmpty()},o.prototype._reset=function(){},o.prototype._get_next_token=function(e,t){this._readWhitespace();var n=this._input.read(/.+/g);return n?this._create_token(i.RAW,n):this._create_token(i.EOF,"")},o.prototype._is_comment=function(e){return!1},o.prototype._is_opening=function(e){return!1},o.prototype._is_closing=function(e,t){return!1},o.prototype._create_token=function(e,n){var r=new t(e,n,this._patterns.whitespace.newline_count,this._patterns.whitespace.whitespace_before_token);return r},o.prototype._readWhitespace=function(){return this._patterns.whitespace.read()},ph.Tokenizer=o,ph.TOKEN=i,ph}var xh,_h={};function kh(){if(xh)return _h;function e(e,t){e="string"===typeof e?e:e.source,t="string"===typeof t?t:t.source,this.__directives_block_pattern=new RegExp(e+/ beautify( \w+[:]\w+)+ /.source+t,"g"),this.__directive_pattern=/ (\w+)[:](\w+)/g,this.__directives_end_ignore_pattern=new RegExp(e+/\sbeautify\signore:end\s/.source+t,"g")}return xh=1,e.prototype.get_directives=function(e){if(!e.match(this.__directives_block_pattern))return null;var t={};this.__directive_pattern.lastIndex=0;var n=this.__directive_pattern.exec(e);while(n)t[n[1]]=n[2],n=this.__directive_pattern.exec(e);return t},e.prototype.readIgnored=function(e){return e.readUntilAfter(this.__directives_end_ignore_pattern)},_h.Directives=e,_h}var Ch,Ah,Th,Rh,Nh={};function Ph(){if(Ch)return Nh;Ch=1;var e=Oh().Pattern,t={django:!1,erb:!1,handlebars:!1,php:!1,smarty:!1};function n(n,r){e.call(this,n,r),this.__template_pattern=null,this._disabled=Object.assign({},t),this._excluded=Object.assign({},t),r&&(this.__template_pattern=this._input.get_regexp(r.__template_pattern),this._excluded=Object.assign(this._excluded,r._excluded),this._disabled=Object.assign(this._disabled,r._disabled));var i=new e(n);this.__patterns={handlebars_comment:i.starting_with(/{{!--/).until_after(/--}}/),handlebars_unescaped:i.starting_with(/{{{/).until_after(/}}}/),handlebars:i.starting_with(/{{/).until_after(/}}/),php:i.starting_with(/<\?(?:[= ]|php)/).until_after(/\?>/),erb:i.starting_with(/<%[^%]/).until_after(/[^%]%>/),django:i.starting_with(/{%/).until_after(/%}/),django_value:i.starting_with(/{{/).until_after(/}}/),django_comment:i.starting_with(/{#/).until_after(/#}/),smarty:i.starting_with(/{(?=[^}{\s\n])/).until_after(/[^\s\n]}/),smarty_comment:i.starting_with(/{\*/).until_after(/\*}/),smarty_literal:i.starting_with(/{literal}/).until_after(/{\/literal}/)}}return n.prototype=new e,n.prototype._create=function(){return new n(this._input,this)},n.prototype._update=function(){this.__set_templated_pattern()},n.prototype.disable=function(e){var t=this._create();return t._disabled[e]=!0,t._update(),t},n.prototype.read_options=function(e){var n=this._create();for(var r in t)n._disabled[r]=-1===e.templating.indexOf(r);return n._update(),n},n.prototype.exclude=function(e){var t=this._create();return t._excluded[e]=!0,t._update(),t},n.prototype.read=function(){var e="";e=this._match_pattern?this._input.read(this._starting_pattern):this._input.read(this._starting_pattern,this.__template_pattern);var t=this._read_template();while(t)this._match_pattern?t+=this._input.read(this._match_pattern):t+=this._input.readUntil(this.__template_pattern),e+=t,t=this._read_template();return this._until_after&&(e+=this._input.readUntilAfter(this._until_pattern)),e},n.prototype.__set_templated_pattern=function(){var e=[];this._disabled.php||e.push(this.__patterns.php._starting_pattern.source),this._disabled.handlebars||e.push(this.__patterns.handlebars._starting_pattern.source),this._disabled.erb||e.push(this.__patterns.erb._starting_pattern.source),this._disabled.django||(e.push(this.__patterns.django._starting_pattern.source),e.push(this.__patterns.django_value._starting_pattern.source),e.push(this.__patterns.django_comment._starting_pattern.source)),this._disabled.smarty||e.push(this.__patterns.smarty._starting_pattern.source),this._until_pattern&&e.push(this._until_pattern.source),this.__template_pattern=this._input.get_regexp("(?:"+e.join("|")+")")},n.prototype._read_template=function(){var e="",t=this._input.peek();if("<"===t){var n=this._input.peek(1);this._disabled.php||this._excluded.php||"?"!==n||(e=e||this.__patterns.php.read()),this._disabled.erb||this._excluded.erb||"%"!==n||(e=e||this.__patterns.erb.read())}else"{"===t&&(this._disabled.handlebars||this._excluded.handlebars||(e=e||this.__patterns.handlebars_comment.read(),e=e||this.__patterns.handlebars_unescaped.read(),e=e||this.__patterns.handlebars.read()),this._disabled.django||(this._excluded.django||this._excluded.handlebars||(e=e||this.__patterns.django_value.read()),this._excluded.django||(e=e||this.__patterns.django_comment.read(),e=e||this.__patterns.django.read())),this._disabled.smarty||this._disabled.django&&this._disabled.handlebars&&(e=e||this.__patterns.smarty_comment.read(),e=e||this.__patterns.smarty_literal.read(),e=e||this.__patterns.smarty.read()));return e},Nh.TemplatablePattern=n,Nh}function Ih(){if(Ah)return ch;Ah=1;var e=dh().InputScanner,t=Eh().Tokenizer,n=Eh().TOKEN,r=kh().Directives,i=th(),o=Oh().Pattern,a=Ph().TemplatablePattern;function s(e,t){return-1!==t.indexOf(e)}var l={START_EXPR:"TK_START_EXPR",END_EXPR:"TK_END_EXPR",START_BLOCK:"TK_START_BLOCK",END_BLOCK:"TK_END_BLOCK",WORD:"TK_WORD",RESERVED:"TK_RESERVED",SEMICOLON:"TK_SEMICOLON",STRING:"TK_STRING",EQUALS:"TK_EQUALS",OPERATOR:"TK_OPERATOR",COMMA:"TK_COMMA",BLOCK_COMMENT:"TK_BLOCK_COMMENT",COMMENT:"TK_COMMENT",DOT:"TK_DOT",UNKNOWN:"TK_UNKNOWN",START:n.START,RAW:n.RAW,EOF:n.EOF},c=new r(/\/\*/,/\*\//),u=/0[xX][0123456789abcdefABCDEF_]*n?|0[oO][01234567_]*n?|0[bB][01_]*n?|\d[\d_]*n|(?:\.\d[\d_]*|\d[\d_]*\.?[\d_]*)(?:[eE][+-]?[\d_]+)?/,d=/[0-9]/,h=/[^\d\.]/,p=">>> === !== &&= ??= ||= << && >= ** != == <= >> || ?? |> < / - + > : & % ? ^ | *".split(" "),f=">>>= ... >>= <<= === >>> !== **= &&= ??= ||= => ^= :: /= << <= == && -= >= >> != -- += ** || ?? ++ %= &= *= |= |> = ! ? > < : / ^ - + * & % ~ |";f=f.replace(/[-[\]{}()*+?.,\\^$|#]/g,"\\$&"),f="\\?\\.(?!\\d) "+f,f=f.replace(/ /g,"|");var m,g=new RegExp(f),v="continue,try,throw,return,var,let,const,if,switch,case,default,for,while,break,function,import,export".split(","),b=v.concat(["do","in","of","else","get","set","new","catch","finally","typeof","yield","async","await","from","as","class","extends"]),y=new RegExp("^(?:"+b.join("|")+")$"),w=function(e,n){t.call(this,e,n),this._patterns.whitespace=this._patterns.whitespace.matching(/\u00A0\u1680\u180e\u2000-\u200a\u202f\u205f\u3000\ufeff/.source,/\u2028\u2029/.source);var r=new o(this._input),s=new a(this._input).read_options(this._options);this.__patterns={template:s,identifier:s.starting_with(i.identifier).matching(i.identifierMatch),number:r.matching(u),punct:r.matching(g),comment:r.starting_with(/\/\//).until(/[\n\r\u2028\u2029]/),block_comment:r.starting_with(/\/\*/).until_after(/\*\//),html_comment_start:r.matching(/<!--/),html_comment_end:r.matching(/-->/),include:r.starting_with(/#include/).until_after(i.lineBreak),shebang:r.starting_with(/#!/).until_after(i.lineBreak),xml:r.matching(/[\s\S]*?<(\/?)([-a-zA-Z:0-9_.]+|{[^}]+?}|!\[CDATA\[[^\]]*?\]\]|)(\s*{[^}]+?}|\s+[-a-zA-Z:0-9_.]+|\s+[-a-zA-Z:0-9_.]+\s*=\s*('[^']*'|"[^"]*"|{([^{}]|{[^}]+?})+?}))*\s*(\/?)\s*>/),single_quote:s.until(/['\\\n\r\u2028\u2029]/),double_quote:s.until(/["\\\n\r\u2028\u2029]/),template_text:s.until(/[`\\$]/),template_expression:s.until(/[`}\\]/)}};function O(t){var n="",r=0,i=new e(t),o=null;while(i.hasNext())if(o=i.match(/([\s]|[^\\]|\\\\)+/g),o&&(n+=o[0]),"\\"===i.peek()){if(i.next(),"x"===i.peek())o=i.match(/x([0-9A-Fa-f]{2})/g);else{if("u"!==i.peek()){n+="\\",i.hasNext()&&(n+=i.next());continue}o=i.match(/u([0-9A-Fa-f]{4})/g)}if(!o)return t;if(r=parseInt(o[1],16),r>126&&r<=255&&0===o[0].indexOf("x"))return t;if(r>=0&&r<32){n+="\\"+o[0];continue}n+=34===r||39===r||92===r?"\\"+String.fromCharCode(r):String.fromCharCode(r)}return n}return w.prototype=new t,w.prototype._is_comment=function(e){return e.type===l.COMMENT||e.type===l.BLOCK_COMMENT||e.type===l.UNKNOWN},w.prototype._is_opening=function(e){return e.type===l.START_BLOCK||e.type===l.START_EXPR},w.prototype._is_closing=function(e,t){return(e.type===l.END_BLOCK||e.type===l.END_EXPR)&&t&&("]"===e.text&&"["===t.text||")"===e.text&&"("===t.text||"}"===e.text&&"{"===t.text)},w.prototype._reset=function(){m=!1},w.prototype._get_next_token=function(e,t){var n=null;this._readWhitespace();var r=this._input.peek();return null===r?this._create_token(l.EOF,""):(n=n||this._read_non_javascript(r),n=n||this._read_string(r),n=n||this._read_pair(r,this._input.peek(1)),n=n||this._read_word(e),n=n||this._read_singles(r),n=n||this._read_comment(r),n=n||this._read_regexp(r,e),n=n||this._read_xml(r,e),n=n||this._read_punctuation(),n=n||this._create_token(l.UNKNOWN,this._input.next()),n)},w.prototype._read_word=function(e){var t;return t=this.__patterns.identifier.read(),""!==t?(t=t.replace(i.allLineBreaks,"\n"),e.type!==l.DOT&&(e.type!==l.RESERVED||"set"!==e.text&&"get"!==e.text)&&y.test(t)?"in"!==t&&"of"!==t||e.type!==l.WORD&&e.type!==l.STRING?this._create_token(l.RESERVED,t):this._create_token(l.OPERATOR,t):this._create_token(l.WORD,t)):(t=this.__patterns.number.read(),""!==t?this._create_token(l.WORD,t):void 0)},w.prototype._read_singles=function(e){var t=null;return"("===e||"["===e?t=this._create_token(l.START_EXPR,e):")"===e||"]"===e?t=this._create_token(l.END_EXPR,e):"{"===e?t=this._create_token(l.START_BLOCK,e):"}"===e?t=this._create_token(l.END_BLOCK,e):";"===e?t=this._create_token(l.SEMICOLON,e):"."===e&&h.test(this._input.peek(1))?t=this._create_token(l.DOT,e):","===e&&(t=this._create_token(l.COMMA,e)),t&&this._input.next(),t},w.prototype._read_pair=function(e,t){var n=null;return"#"===e&&"{"===t&&(n=this._create_token(l.START_BLOCK,e+t)),n&&(this._input.next(),this._input.next()),n},w.prototype._read_punctuation=function(){var e=this.__patterns.punct.read();if(""!==e)return"="===e?this._create_token(l.EQUALS,e):"?."===e?this._create_token(l.DOT,e):this._create_token(l.OPERATOR,e)},w.prototype._read_non_javascript=function(e){var t="";if("#"===e){if(this._is_first_token()&&(t=this.__patterns.shebang.read(),t))return this._create_token(l.UNKNOWN,t.trim()+"\n");if(t=this.__patterns.include.read(),t)return this._create_token(l.UNKNOWN,t.trim()+"\n");e=this._input.next();var n="#";if(this._input.hasNext()&&this._input.testChar(d)){do{e=this._input.next(),n+=e}while(this._input.hasNext()&&"#"!==e&&"="!==e);return"#"===e||("["===this._input.peek()&&"]"===this._input.peek(1)?(n+="[]",this._input.next(),this._input.next()):"{"===this._input.peek()&&"}"===this._input.peek(1)&&(n+="{}",this._input.next(),this._input.next())),this._create_token(l.WORD,n)}this._input.back()}else if("<"===e&&this._is_first_token()){if(t=this.__patterns.html_comment_start.read(),t){while(this._input.hasNext()&&!this._input.testChar(i.newline))t+=this._input.next();return m=!0,this._create_token(l.COMMENT,t)}}else if(m&&"-"===e&&(t=this.__patterns.html_comment_end.read(),t))return m=!1,this._create_token(l.COMMENT,t);return null},w.prototype._read_comment=function(e){var t=null;if("/"===e){var n="";if("*"===this._input.peek(1)){n=this.__patterns.block_comment.read();var r=c.get_directives(n);r&&"start"===r.ignore&&(n+=c.readIgnored(this._input)),n=n.replace(i.allLineBreaks,"\n"),t=this._create_token(l.BLOCK_COMMENT,n),t.directives=r}else"/"===this._input.peek(1)&&(n=this.__patterns.comment.read(),t=this._create_token(l.COMMENT,n))}return t},w.prototype._read_string=function(e){if("`"===e||"'"===e||'"'===e){var t=this._input.next();return this.has_char_escapes=!1,t+="`"===e?this._read_string_recursive("`",!0,"${"):this._read_string_recursive(e),this.has_char_escapes&&this._options.unescape_strings&&(t=O(t)),this._input.peek()===e&&(t+=this._input.next()),t=t.replace(i.allLineBreaks,"\n"),this._create_token(l.STRING,t)}return null},w.prototype._allow_regexp_or_xml=function(e){return e.type===l.RESERVED&&s(e.text,["return","case","throw","else","do","typeof","yield"])||e.type===l.END_EXPR&&")"===e.text&&e.opened.previous.type===l.RESERVED&&s(e.opened.previous.text,["if","while","for"])||s(e.type,[l.COMMENT,l.START_EXPR,l.START_BLOCK,l.START,l.END_BLOCK,l.OPERATOR,l.EQUALS,l.EOF,l.SEMICOLON,l.COMMA])},w.prototype._read_regexp=function(e,t){if("/"===e&&this._allow_regexp_or_xml(t)){var n=this._input.next(),r=!1,o=!1;while(this._input.hasNext()&&(r||o||this._input.peek()!==e)&&!this._input.testChar(i.newline))n+=this._input.peek(),r?r=!1:(r="\\"===this._input.peek(),"["===this._input.peek()?o=!0:"]"===this._input.peek()&&(o=!1)),this._input.next();return this._input.peek()===e&&(n+=this._input.next(),n+=this._input.read(i.identifier)),this._create_token(l.STRING,n)}return null},w.prototype._read_xml=function(e,t){if(this._options.e4x&&"<"===e&&this._allow_regexp_or_xml(t)){var n="",r=this.__patterns.xml.read_match();if(r){var o=r[2].replace(/^{\s+/,"{").replace(/\s+}$/,"}"),a=0===o.indexOf("{"),s=0;while(r){var c=!!r[1],u=r[2],d=!!r[r.length-1]||"![CDATA["===u.slice(0,8);if(!d&&(u===o||a&&u.replace(/^{\s+/,"{").replace(/\s+}$/,"}"))&&(c?--s:++s),n+=r[0],s<=0)break;r=this.__patterns.xml.read_match()}return r||(n+=this._input.match(/[\s\S]*/g)[0]),n=n.replace(i.allLineBreaks,"\n"),this._create_token(l.STRING,n)}}return null},w.prototype._read_string_recursive=function(e,t,n){var r,o;"'"===e?o=this.__patterns.single_quote:'"'===e?o=this.__patterns.double_quote:"`"===e?o=this.__patterns.template_text:"}"===e&&(o=this.__patterns.template_expression);var a=o.read(),s="";while(this._input.hasNext()){if(s=this._input.next(),s===e||!t&&i.newline.test(s)){this._input.back();break}"\\"===s&&this._input.hasNext()?(r=this._input.peek(),"x"===r||"u"===r?this.has_char_escapes=!0:"\r"===r&&"\n"===this._input.peek(1)&&this._input.next(),s+=this._input.next()):n&&("${"===n&&"$"===s&&"{"===this._input.peek()&&(s+=this._input.next()),n===s&&(s+="`"===e?this._read_string_recursive("}",t,"`"):this._read_string_recursive("`",t,"${"),this._input.hasNext()&&(s+=this._input.next()))),s+=o.read(),a+=s}return a},ch.Tokenizer=w,ch.TOKEN=l,ch.positionable_operators=p.slice(),ch.line_starters=v.slice(),ch}function Mh(){if(Th)return zd;Th=1;var e=Wd().Output,t=Zd().Token,n=th(),r=sh().Options,i=Ih().Tokenizer,o=Ih().line_starters,a=Ih().positionable_operators,s=Ih().TOKEN;function l(e,t){return-1!==t.indexOf(e)}function c(e){return e.replace(/^\s+/g,"")}function u(e){for(var t={},n=0;n<e.length;n++)t[e[n].replace(/-/g,"_")]=e[n];return t}function d(e,t){return e&&e.type===s.RESERVED&&e.text===t}function h(e,t){return e&&e.type===s.RESERVED&&l(e.text,t)}var p=["case","return","do","if","throw","else","await","break","continue","async"],f=["before-newline","after-newline","preserve-newline"],m=u(f),g=[m.before_newline,m.preserve_newline],v={BlockStatement:"BlockStatement",Statement:"Statement",ObjectLiteral:"ObjectLiteral",ArrayLiteral:"ArrayLiteral",ForInitializer:"ForInitializer",Conditional:"Conditional",Expression:"Expression"};function b(e,t){t.multiline_frame||t.mode===v.ForInitializer||t.mode===v.Conditional||e.remove_indent(t.start_line_index)}function y(e){e=e.replace(n.allLineBreaks,"\n");var t=[],r=e.indexOf("\n");while(-1!==r)t.push(e.substring(0,r)),e=e.substring(r+1),r=e.indexOf("\n");return e.length&&t.push(e),t}function w(e){return e===v.ArrayLiteral}function O(e){return l(e,[v.Expression,v.ForInitializer,v.Conditional])}function S(e,t){for(var n=0;n<e.length;n++){var r=e[n].trim();if(r.charAt(0)!==t)return!1}return!0}function E(e,t){for(var n,r=0,i=e.length;r<i;r++)if(n=e[r],n&&0!==n.indexOf(t))return!1;return!0}function x(e,t){t=t||{},this._source_text=e||"",this._output=null,this._tokens=null,this._last_last_text=null,this._flags=null,this._previous_flags=null,this._flag_store=null,this._options=new r(t)}x.prototype.create_flags=function(e,n){var r=0;e&&(r=e.indentation_level,!this._output.just_added_newline()&&e.line_indent_level>r&&(r=e.line_indent_level));var i={mode:n,parent:e,last_token:e?e.last_token:new t(s.START_BLOCK,""),last_word:e?e.last_word:"",declaration_statement:!1,declaration_assignment:!1,multiline_frame:!1,inline_frame:!1,if_block:!1,else_block:!1,class_start_block:!1,do_block:!1,do_while:!1,import_block:!1,in_case_statement:!1,in_case:!1,case_body:!1,case_block:!1,indentation_level:r,alignment:0,line_indent_level:e?e.line_indent_level:r,start_line_index:this._output.get_line_number(),ternary_depth:0};return i},x.prototype._reset=function(t){var n=t.match(/^[\t ]*/)[0];this._last_last_text="",this._output=new e(this._options,n),this._output.raw=this._options.test_output_raw,this._flag_store=[],this.set_mode(v.BlockStatement);var r=new i(t,this._options);return this._tokens=r.tokenize(),t},x.prototype.beautify=function(){if(this._options.disabled)return this._source_text;var e,t=this._reset(this._source_text),r=this._options.eol;"auto"===this._options.eol&&(r="\n",t&&n.lineBreak.test(t||"")&&(r=t.match(n.lineBreak)[0]));var i=this._tokens.next();while(i)this.handle_token(i),this._last_last_text=this._flags.last_token.text,this._flags.last_token=i,i=this._tokens.next();return e=this._output.get_code(r),e},x.prototype.handle_token=function(e,t){e.type===s.START_EXPR?this.handle_start_expr(e):e.type===s.END_EXPR?this.handle_end_expr(e):e.type===s.START_BLOCK?this.handle_start_block(e):e.type===s.END_BLOCK?this.handle_end_block(e):e.type===s.WORD||e.type===s.RESERVED?this.handle_word(e):e.type===s.SEMICOLON?this.handle_semicolon(e):e.type===s.STRING?this.handle_string(e):e.type===s.EQUALS?this.handle_equals(e):e.type===s.OPERATOR?this.handle_operator(e):e.type===s.COMMA?this.handle_comma(e):e.type===s.BLOCK_COMMENT?this.handle_block_comment(e,t):e.type===s.COMMENT?this.handle_comment(e,t):e.type===s.DOT?this.handle_dot(e):e.type===s.EOF?this.handle_eof(e):(e.type,s.UNKNOWN,this.handle_unknown(e,t))},x.prototype.handle_whitespace_and_comments=function(e,t){var n=e.newlines,r=this._options.keep_array_indentation&&w(this._flags.mode);if(e.comments_before){var i=e.comments_before.next();while(i)this.handle_whitespace_and_comments(i,t),this.handle_token(i,t),i=e.comments_before.next()}if(r)for(var o=0;o<n;o+=1)this.print_newline(o>0,t);else if(this._options.max_preserve_newlines&&n>this._options.max_preserve_newlines&&(n=this._options.max_preserve_newlines),this._options.preserve_newlines&&n>1){this.print_newline(!1,t);for(var a=1;a<n;a+=1)this.print_newline(!0,t)}};var _=["async","break","continue","return","throw","yield"];return x.prototype.allow_wrap_or_preserved_newline=function(e,t){if(t=void 0!==t&&t,!this._output.just_added_newline()){var n=this._options.preserve_newlines&&e.newlines||t,r=l(this._flags.last_token.text,a)||l(e.text,a);if(r){var i=l(this._flags.last_token.text,a)&&l(this._options.operator_position,g)||l(e.text,a);n=n&&i}if(n)this.print_newline(!1,!0);else if(this._options.wrap_line_length){if(h(this._flags.last_token,_))return;this._output.set_wrap_point()}}},x.prototype.print_newline=function(e,t){if(!t&&";"!==this._flags.last_token.text&&","!==this._flags.last_token.text&&"="!==this._flags.last_token.text&&(this._flags.last_token.type!==s.OPERATOR||"--"===this._flags.last_token.text||"++"===this._flags.last_token.text)){var n=this._tokens.peek();while(this._flags.mode===v.Statement&&(!this._flags.if_block||!d(n,"else"))&&!this._flags.do_block)this.restore_mode()}this._output.add_new_line(e)&&(this._flags.multiline_frame=!0)},x.prototype.print_token_line_indentation=function(e){this._output.just_added_newline()&&(this._options.keep_array_indentation&&e.newlines&&("["===e.text||w(this._flags.mode))?(this._output.current_line.set_indent(-1),this._output.current_line.push(e.whitespace_before),this._output.space_before_token=!1):this._output.set_indent(this._flags.indentation_level,this._flags.alignment)&&(this._flags.line_indent_level=this._flags.indentation_level))},x.prototype.print_token=function(e){if(this._output.raw)this._output.add_raw_token(e);else{if(this._options.comma_first&&e.previous&&e.previous.type===s.COMMA&&this._output.just_added_newline()&&","===this._output.previous_line.last()){var t=this._output.previous_line.pop();this._output.previous_line.is_empty()&&(this._output.previous_line.push(t),this._output.trim(!0),this._output.current_line.pop(),this._output.trim()),this.print_token_line_indentation(e),this._output.add_token(","),this._output.space_before_token=!0}this.print_token_line_indentation(e),this._output.non_breaking_space=!0,this._output.add_token(e.text),this._output.previous_token_wrapped&&(this._flags.multiline_frame=!0)}},x.prototype.indent=function(){this._flags.indentation_level+=1,this._output.set_indent(this._flags.indentation_level,this._flags.alignment)},x.prototype.deindent=function(){this._flags.indentation_level>0&&(!this._flags.parent||this._flags.indentation_level>this._flags.parent.indentation_level)&&(this._flags.indentation_level-=1,this._output.set_indent(this._flags.indentation_level,this._flags.alignment))},x.prototype.set_mode=function(e){this._flags?(this._flag_store.push(this._flags),this._previous_flags=this._flags):this._previous_flags=this.create_flags(null,e),this._flags=this.create_flags(this._previous_flags,e),this._output.set_indent(this._flags.indentation_level,this._flags.alignment)},x.prototype.restore_mode=function(){this._flag_store.length>0&&(this._previous_flags=this._flags,this._flags=this._flag_store.pop(),this._previous_flags.mode===v.Statement&&b(this._output,this._previous_flags),this._output.set_indent(this._flags.indentation_level,this._flags.alignment))},x.prototype.start_of_object_property=function(){return this._flags.parent.mode===v.ObjectLiteral&&this._flags.mode===v.Statement&&(":"===this._flags.last_token.text&&0===this._flags.ternary_depth||h(this._flags.last_token,["get","set"]))},x.prototype.start_of_statement=function(e){var t=!1;return t=t||h(this._flags.last_token,["var","let","const"])&&e.type===s.WORD,t=t||d(this._flags.last_token,"do"),t=t||!(this._flags.parent.mode===v.ObjectLiteral&&this._flags.mode===v.Statement)&&h(this._flags.last_token,_)&&!e.newlines,t=t||d(this._flags.last_token,"else")&&!(d(e,"if")&&!e.comments_before),t=t||this._flags.last_token.type===s.END_EXPR&&(this._previous_flags.mode===v.ForInitializer||this._previous_flags.mode===v.Conditional),t=t||this._flags.last_token.type===s.WORD&&this._flags.mode===v.BlockStatement&&!this._flags.in_case&&!("--"===e.text||"++"===e.text)&&"function"!==this._last_last_text&&e.type!==s.WORD&&e.type!==s.RESERVED,t=t||this._flags.mode===v.ObjectLiteral&&(":"===this._flags.last_token.text&&0===this._flags.ternary_depth||h(this._flags.last_token,["get","set"])),!!t&&(this.set_mode(v.Statement),this.indent(),this.handle_whitespace_and_comments(e,!0),this.start_of_object_property()||this.allow_wrap_or_preserved_newline(e,h(e,["do","for","if","while"])),!0)},x.prototype.handle_start_expr=function(e){this.start_of_statement(e)||this.handle_whitespace_and_comments(e);var t=v.Expression;if("["===e.text){if(this._flags.last_token.type===s.WORD||")"===this._flags.last_token.text)return h(this._flags.last_token,o)&&(this._output.space_before_token=!0),this.print_token(e),this.set_mode(t),this.indent(),void(this._options.space_in_paren&&(this._output.space_before_token=!0));t=v.ArrayLiteral,w(this._flags.mode)&&("["!==this._flags.last_token.text&&(","!==this._flags.last_token.text||"]"!==this._last_last_text&&"}"!==this._last_last_text)||this._options.keep_array_indentation||this.print_newline()),l(this._flags.last_token.type,[s.START_EXPR,s.END_EXPR,s.WORD,s.OPERATOR,s.DOT])||(this._output.space_before_token=!0)}else{if(this._flags.last_token.type===s.RESERVED)"for"===this._flags.last_token.text?(this._output.space_before_token=this._options.space_before_conditional,t=v.ForInitializer):l(this._flags.last_token.text,["if","while","switch"])?(this._output.space_before_token=this._options.space_before_conditional,t=v.Conditional):l(this._flags.last_word,["await","async"])?this._output.space_before_token=!0:"import"===this._flags.last_token.text&&""===e.whitespace_before?this._output.space_before_token=!1:(l(this._flags.last_token.text,o)||"catch"===this._flags.last_token.text)&&(this._output.space_before_token=!0);else if(this._flags.last_token.type===s.EQUALS||this._flags.last_token.type===s.OPERATOR)this.start_of_object_property()||this.allow_wrap_or_preserved_newline(e);else if(this._flags.last_token.type===s.WORD){this._output.space_before_token=!1;var n=this._tokens.peek(-3);if(this._options.space_after_named_function&&n){var r=this._tokens.peek(-4);h(n,["async","function"])||"*"===n.text&&h(r,["async","function"])?this._output.space_before_token=!0:this._flags.mode===v.ObjectLiteral?"{"!==n.text&&","!==n.text&&("*"!==n.text||"{"!==r.text&&","!==r.text)||(this._output.space_before_token=!0):this._flags.parent&&this._flags.parent.class_start_block&&(this._output.space_before_token=!0)}}else this.allow_wrap_or_preserved_newline(e);(this._flags.last_token.type===s.RESERVED&&("function"===this._flags.last_word||"typeof"===this._flags.last_word)||"*"===this._flags.last_token.text&&(l(this._last_last_text,["function","yield"])||this._flags.mode===v.ObjectLiteral&&l(this._last_last_text,["{",","])))&&(this._output.space_before_token=this._options.space_after_anon_function)}";"===this._flags.last_token.text||this._flags.last_token.type===s.START_BLOCK?this.print_newline():this._flags.last_token.type!==s.END_EXPR&&this._flags.last_token.type!==s.START_EXPR&&this._flags.last_token.type!==s.END_BLOCK&&"."!==this._flags.last_token.text&&this._flags.last_token.type!==s.COMMA||this.allow_wrap_or_preserved_newline(e,e.newlines),this.print_token(e),this.set_mode(t),this._options.space_in_paren&&(this._output.space_before_token=!0),this.indent()},x.prototype.handle_end_expr=function(e){while(this._flags.mode===v.Statement)this.restore_mode();this.handle_whitespace_and_comments(e),this._flags.multiline_frame&&this.allow_wrap_or_preserved_newline(e,"]"===e.text&&w(this._flags.mode)&&!this._options.keep_array_indentation),this._options.space_in_paren&&(this._flags.last_token.type!==s.START_EXPR||this._options.space_in_empty_paren?this._output.space_before_token=!0:(this._output.trim(),this._output.space_before_token=!1)),this.deindent(),this.print_token(e),this.restore_mode(),b(this._output,this._previous_flags),this._flags.do_while&&this._previous_flags.mode===v.Conditional&&(this._previous_flags.mode=v.Expression,this._flags.do_block=!1,this._flags.do_while=!1)},x.prototype.handle_start_block=function(e){this.handle_whitespace_and_comments(e);var t=this._tokens.peek(),n=this._tokens.peek(1);"switch"===this._flags.last_word&&this._flags.last_token.type===s.END_EXPR?(this.set_mode(v.BlockStatement),this._flags.in_case_statement=!0):this._flags.case_body?this.set_mode(v.BlockStatement):n&&(l(n.text,[":",","])&&l(t.type,[s.STRING,s.WORD,s.RESERVED])||l(t.text,["get","set","..."])&&l(n.type,[s.WORD,s.RESERVED]))?l(this._last_last_text,["class","interface"])&&!l(n.text,[":",","])?this.set_mode(v.BlockStatement):this.set_mode(v.ObjectLiteral):this._flags.last_token.type===s.OPERATOR&&"=>"===this._flags.last_token.text?this.set_mode(v.BlockStatement):l(this._flags.last_token.type,[s.EQUALS,s.START_EXPR,s.COMMA,s.OPERATOR])||h(this._flags.last_token,["return","throw","import","default"])?this.set_mode(v.ObjectLiteral):this.set_mode(v.BlockStatement),this._flags.last_token&&h(this._flags.last_token.previous,["class","extends"])&&(this._flags.class_start_block=!0);var r=!t.comments_before&&"}"===t.text,i=r&&"function"===this._flags.last_word&&this._flags.last_token.type===s.END_EXPR;if(this._options.brace_preserve_inline){var o=0,a=null;this._flags.inline_frame=!0;do{if(o+=1,a=this._tokens.peek(o-1),a.newlines){this._flags.inline_frame=!1;break}}while(a.type!==s.EOF&&(a.type!==s.END_BLOCK||a.opened!==e))}("expand"===this._options.brace_style||"none"===this._options.brace_style&&e.newlines)&&!this._flags.inline_frame?this._flags.last_token.type!==s.OPERATOR&&(i||this._flags.last_token.type===s.EQUALS||h(this._flags.last_token,p)&&"else"!==this._flags.last_token.text)?this._output.space_before_token=!0:this.print_newline(!1,!0):(!w(this._previous_flags.mode)||this._flags.last_token.type!==s.START_EXPR&&this._flags.last_token.type!==s.COMMA||((this._flags.last_token.type===s.COMMA||this._options.space_in_paren)&&(this._output.space_before_token=!0),(this._flags.last_token.type===s.COMMA||this._flags.last_token.type===s.START_EXPR&&this._flags.inline_frame)&&(this.allow_wrap_or_preserved_newline(e),this._previous_flags.multiline_frame=this._previous_flags.multiline_frame||this._flags.multiline_frame,this._flags.multiline_frame=!1)),this._flags.last_token.type!==s.OPERATOR&&this._flags.last_token.type!==s.START_EXPR&&(l(this._flags.last_token.type,[s.START_BLOCK,s.SEMICOLON])&&!this._flags.inline_frame?this.print_newline():this._output.space_before_token=!0)),this.print_token(e),this.indent(),r||this._options.brace_preserve_inline&&this._flags.inline_frame||this.print_newline()},x.prototype.handle_end_block=function(e){this.handle_whitespace_and_comments(e);while(this._flags.mode===v.Statement)this.restore_mode();var t=this._flags.last_token.type===s.START_BLOCK;this._flags.inline_frame&&!t?this._output.space_before_token=!0:"expand"===this._options.brace_style?t||this.print_newline():t||(w(this._flags.mode)&&this._options.keep_array_indentation?(this._options.keep_array_indentation=!1,this.print_newline(),this._options.keep_array_indentation=!0):this.print_newline()),this.restore_mode(),this.print_token(e)},x.prototype.handle_word=function(e){if(e.type===s.RESERVED)if(l(e.text,["set","get"])&&this._flags.mode!==v.ObjectLiteral)e.type=s.WORD;else if("import"===e.text&&l(this._tokens.peek().text,["(","."]))e.type=s.WORD;else if(l(e.text,["as","from"])&&!this._flags.import_block)e.type=s.WORD;else if(this._flags.mode===v.ObjectLiteral){var t=this._tokens.peek();":"===t.text&&(e.type=s.WORD)}if(this.start_of_statement(e)?h(this._flags.last_token,["var","let","const"])&&e.type===s.WORD&&(this._flags.declaration_statement=!0):!e.newlines||O(this._flags.mode)||this._flags.last_token.type===s.OPERATOR&&"--"!==this._flags.last_token.text&&"++"!==this._flags.last_token.text||this._flags.last_token.type===s.EQUALS||!this._options.preserve_newlines&&h(this._flags.last_token,["var","let","const","set","get"])?this.handle_whitespace_and_comments(e):(this.handle_whitespace_and_comments(e),this.print_newline()),this._flags.do_block&&!this._flags.do_while){if(d(e,"while"))return this._output.space_before_token=!0,this.print_token(e),this._output.space_before_token=!0,void(this._flags.do_while=!0);this.print_newline(),this._flags.do_block=!1}if(this._flags.if_block)if(!this._flags.else_block&&d(e,"else"))this._flags.else_block=!0;else{while(this._flags.mode===v.Statement)this.restore_mode();this._flags.if_block=!1,this._flags.else_block=!1}if(this._flags.in_case_statement&&h(e,["case","default"]))return this.print_newline(),this._flags.case_block||!this._flags.case_body&&!this._options.jslint_happy||this.deindent(),this._flags.case_body=!1,this.print_token(e),void(this._flags.in_case=!0);if(this._flags.last_token.type!==s.COMMA&&this._flags.last_token.type!==s.START_EXPR&&this._flags.last_token.type!==s.EQUALS&&this._flags.last_token.type!==s.OPERATOR||this.start_of_object_property()||this.allow_wrap_or_preserved_newline(e),d(e,"function"))return(l(this._flags.last_token.text,["}",";"])||this._output.just_added_newline()&&!l(this._flags.last_token.text,["(","[","{",":","=",","])&&this._flags.last_token.type!==s.OPERATOR)&&(this._output.just_added_blankline()||e.comments_before||(this.print_newline(),this.print_newline(!0))),this._flags.last_token.type===s.RESERVED||this._flags.last_token.type===s.WORD?h(this._flags.last_token,["get","set","new","export"])||h(this._flags.last_token,_)||d(this._flags.last_token,"default")&&"export"===this._last_last_text||"declare"===this._flags.last_token.text?this._output.space_before_token=!0:this.print_newline():this._flags.last_token.type===s.OPERATOR||"="===this._flags.last_token.text?this._output.space_before_token=!0:(this._flags.multiline_frame||!O(this._flags.mode)&&!w(this._flags.mode))&&this.print_newline(),this.print_token(e),void(this._flags.last_word=e.text);var n="NONE";if(this._flags.last_token.type===s.END_BLOCK?this._previous_flags.inline_frame?n="SPACE":h(e,["else","catch","finally","from"])?"expand"===this._options.brace_style||"end-expand"===this._options.brace_style||"none"===this._options.brace_style&&e.newlines?n="NEWLINE":(n="SPACE",this._output.space_before_token=!0):n="NEWLINE":this._flags.last_token.type===s.SEMICOLON&&this._flags.mode===v.BlockStatement?n="NEWLINE":this._flags.last_token.type===s.SEMICOLON&&O(this._flags.mode)?n="SPACE":this._flags.last_token.type===s.STRING?n="NEWLINE":this._flags.last_token.type===s.RESERVED||this._flags.last_token.type===s.WORD||"*"===this._flags.last_token.text&&(l(this._last_last_text,["function","yield"])||this._flags.mode===v.ObjectLiteral&&l(this._last_last_text,["{",","]))?n="SPACE":this._flags.last_token.type===s.START_BLOCK?n=this._flags.inline_frame?"SPACE":"NEWLINE":this._flags.last_token.type===s.END_EXPR&&(this._output.space_before_token=!0,n="NEWLINE"),h(e,o)&&")"!==this._flags.last_token.text&&(n=this._flags.inline_frame||"else"===this._flags.last_token.text||"export"===this._flags.last_token.text?"SPACE":"NEWLINE"),h(e,["else","catch","finally"]))if((this._flags.last_token.type!==s.END_BLOCK||this._previous_flags.mode!==v.BlockStatement||"expand"===this._options.brace_style||"end-expand"===this._options.brace_style||"none"===this._options.brace_style&&e.newlines)&&!this._flags.inline_frame)this.print_newline();else{this._output.trim(!0);var r=this._output.current_line;"}"!==r.last()&&this.print_newline(),this._output.space_before_token=!0}else"NEWLINE"===n?h(this._flags.last_token,p)||"declare"===this._flags.last_token.text&&h(e,["var","let","const"])?this._output.space_before_token=!0:this._flags.last_token.type!==s.END_EXPR?this._flags.last_token.type===s.START_EXPR&&h(e,["var","let","const"])||":"===this._flags.last_token.text||(d(e,"if")&&d(e.previous,"else")?this._output.space_before_token=!0:this.print_newline()):h(e,o)&&")"!==this._flags.last_token.text&&this.print_newline():this._flags.multiline_frame&&w(this._flags.mode)&&","===this._flags.last_token.text&&"}"===this._last_last_text?this.print_newline():"SPACE"===n&&(this._output.space_before_token=!0);!e.previous||e.previous.type!==s.WORD&&e.previous.type!==s.RESERVED||(this._output.space_before_token=!0),this.print_token(e),this._flags.last_word=e.text,e.type===s.RESERVED&&("do"===e.text?this._flags.do_block=!0:"if"===e.text?this._flags.if_block=!0:"import"===e.text?this._flags.import_block=!0:this._flags.import_block&&d(e,"from")&&(this._flags.import_block=!1))},x.prototype.handle_semicolon=function(e){this.start_of_statement(e)?this._output.space_before_token=!1:this.handle_whitespace_and_comments(e);var t=this._tokens.peek();while(this._flags.mode===v.Statement&&(!this._flags.if_block||!d(t,"else"))&&!this._flags.do_block)this.restore_mode();this._flags.import_block&&(this._flags.import_block=!1),this.print_token(e)},x.prototype.handle_string=function(e){(!e.text.startsWith("`")||0!==e.newlines||""!==e.whitespace_before||")"!==e.previous.text&&this._flags.last_token.type!==s.WORD)&&(this.start_of_statement(e)?this._output.space_before_token=!0:(this.handle_whitespace_and_comments(e),this._flags.last_token.type===s.RESERVED||this._flags.last_token.type===s.WORD||this._flags.inline_frame?this._output.space_before_token=!0:this._flags.last_token.type===s.COMMA||this._flags.last_token.type===s.START_EXPR||this._flags.last_token.type===s.EQUALS||this._flags.last_token.type===s.OPERATOR?this.start_of_object_property()||this.allow_wrap_or_preserved_newline(e):!e.text.startsWith("`")||this._flags.last_token.type!==s.END_EXPR||"]"!==e.previous.text&&")"!==e.previous.text||0!==e.newlines?this.print_newline():this._output.space_before_token=!0)),this.print_token(e)},x.prototype.handle_equals=function(e){this.start_of_statement(e)||this.handle_whitespace_and_comments(e),this._flags.declaration_statement&&(this._flags.declaration_assignment=!0),this._output.space_before_token=!0,this.print_token(e),this._output.space_before_token=!0},x.prototype.handle_comma=function(e){this.handle_whitespace_and_comments(e,!0),this.print_token(e),this._output.space_before_token=!0,this._flags.declaration_statement?(O(this._flags.parent.mode)&&(this._flags.declaration_assignment=!1),this._flags.declaration_assignment?(this._flags.declaration_assignment=!1,this.print_newline(!1,!0)):this._options.comma_first&&this.allow_wrap_or_preserved_newline(e)):this._flags.mode===v.ObjectLiteral||this._flags.mode===v.Statement&&this._flags.parent.mode===v.ObjectLiteral?(this._flags.mode===v.Statement&&this.restore_mode(),this._flags.inline_frame||this.print_newline()):this._options.comma_first&&this.allow_wrap_or_preserved_newline(e)},x.prototype.handle_operator=function(e){var t="*"===e.text&&(h(this._flags.last_token,["function","yield"])||l(this._flags.last_token.type,[s.START_BLOCK,s.COMMA,s.END_BLOCK,s.SEMICOLON])),n=l(e.text,["-","+"])&&(l(this._flags.last_token.type,[s.START_BLOCK,s.START_EXPR,s.EQUALS,s.OPERATOR])||l(this._flags.last_token.text,o)||","===this._flags.last_token.text);if(this.start_of_statement(e));else{var r=!t;this.handle_whitespace_and_comments(e,r)}if("*"!==e.text||this._flags.last_token.type!==s.DOT)if("::"!==e.text){if(this._flags.last_token.type===s.OPERATOR&&l(this._options.operator_position,g)&&this.allow_wrap_or_preserved_newline(e),":"===e.text&&this._flags.in_case)return this.print_token(e),this._flags.in_case=!1,this._flags.case_body=!0,void(this._tokens.peek().type!==s.START_BLOCK?(this.indent(),this.print_newline(),this._flags.case_block=!1):(this._flags.case_block=!0,this._output.space_before_token=!0));var i=!0,c=!0,u=!1;if(":"===e.text?0===this._flags.ternary_depth?i=!1:(this._flags.ternary_depth-=1,u=!0):"?"===e.text&&(this._flags.ternary_depth+=1),!n&&!t&&this._options.preserve_newlines&&l(e.text,a)){var d=":"===e.text,f=d&&u,b=d&&!u;switch(this._options.operator_position){case m.before_newline:return this._output.space_before_token=!b,this.print_token(e),d&&!f||this.allow_wrap_or_preserved_newline(e),void(this._output.space_before_token=!0);case m.after_newline:return this._output.space_before_token=!0,!d||f?this._tokens.peek().newlines?this.print_newline(!1,!0):this.allow_wrap_or_preserved_newline(e):this._output.space_before_token=!1,this.print_token(e),void(this._output.space_before_token=!0);case m.preserve_newline:return b||this.allow_wrap_or_preserved_newline(e),i=!(this._output.just_added_newline()||b),this._output.space_before_token=i,this.print_token(e),void(this._output.space_before_token=!0)}}if(t){this.allow_wrap_or_preserved_newline(e),i=!1;var y=this._tokens.peek();c=y&&l(y.type,[s.WORD,s.RESERVED])}else if("..."===e.text)this.allow_wrap_or_preserved_newline(e),i=this._flags.last_token.type===s.START_BLOCK,c=!1;else if(l(e.text,["--","++","!","~"])||n){if(this._flags.last_token.type!==s.COMMA&&this._flags.last_token.type!==s.START_EXPR||this.allow_wrap_or_preserved_newline(e),i=!1,c=!1,e.newlines&&("--"===e.text||"++"===e.text||"~"===e.text)){var w=h(this._flags.last_token,p)&&e.newlines;w&&(this._previous_flags.if_block||this._previous_flags.else_block)&&this.restore_mode(),this.print_newline(w,!0)}";"===this._flags.last_token.text&&O(this._flags.mode)&&(i=!0),this._flags.last_token.type===s.RESERVED?i=!0:this._flags.last_token.type===s.END_EXPR?i=!("]"===this._flags.last_token.text&&("--"===e.text||"++"===e.text)):this._flags.last_token.type===s.OPERATOR&&(i=l(e.text,["--","-","++","+"])&&l(this._flags.last_token.text,["--","-","++","+"]),l(e.text,["+","-"])&&l(this._flags.last_token.text,["--","++"])&&(c=!0)),(this._flags.mode!==v.BlockStatement||this._flags.inline_frame)&&this._flags.mode!==v.Statement||"{"!==this._flags.last_token.text&&";"!==this._flags.last_token.text||this.print_newline()}this._output.space_before_token=this._output.space_before_token||i,this.print_token(e),this._output.space_before_token=c}else this.print_token(e);else this.print_token(e)},x.prototype.handle_block_comment=function(e,t){return this._output.raw?(this._output.add_raw_token(e),void(e.directives&&"end"===e.directives.preserve&&(this._output.raw=this._options.test_output_raw))):e.directives?(this.print_newline(!1,t),this.print_token(e),"start"===e.directives.preserve&&(this._output.raw=!0),void this.print_newline(!1,!0)):n.newline.test(e.text)||e.newlines?void this.print_block_commment(e,t):(this._output.space_before_token=!0,this.print_token(e),void(this._output.space_before_token=!0))},x.prototype.print_block_commment=function(e,t){var n,r=y(e.text),i=!1,o=!1,a=e.whitespace_before,s=a.length;if(this.print_newline(!1,t),this.print_token_line_indentation(e),this._output.add_token(r[0]),this.print_newline(!1,t),r.length>1){for(r=r.slice(1),i=S(r,"*"),o=E(r,a),i&&(this._flags.alignment=1),n=0;n<r.length;n++)i?(this.print_token_line_indentation(e),this._output.add_token(c(r[n]))):o&&r[n]?(this.print_token_line_indentation(e),this._output.add_token(r[n].substring(s))):(this._output.current_line.set_indent(-1),this._output.add_token(r[n])),this.print_newline(!1,t);this._flags.alignment=0}},x.prototype.handle_comment=function(e,t){e.newlines?this.print_newline(!1,t):this._output.trim(!0),this._output.space_before_token=!0,this.print_token(e),this.print_newline(!1,t)},x.prototype.handle_dot=function(e){this.start_of_statement(e)||this.handle_whitespace_and_comments(e,!0),this._flags.last_token.text.match("^[0-9]+$")&&(this._output.space_before_token=!0),h(this._flags.last_token,p)?this._output.space_before_token=!1:this.allow_wrap_or_preserved_newline(e,")"===this._flags.last_token.text&&this._options.break_chained_methods),this._options.unindent_chained_methods&&this._output.just_added_newline()&&this.deindent(),this.print_token(e)},x.prototype.handle_unknown=function(e,t){this.print_token(e),"\n"===e.text[e.text.length-1]&&this.print_newline(!1,t)},x.prototype.handle_eof=function(e){while(this._flags.mode===v.Statement)this.restore_mode();this.handle_whitespace_and_comments(e)},zd.Beautifier=x,zd}function Dh(){if(Rh)return Qd.exports;Rh=1;var e=Mh().Beautifier,t=sh().Options;function n(t,n){var r=new e(t,n);return r.beautify()}return Qd.exports=n,Qd.exports.defaultOptions=function(){return new t},Qd.exports}var Lh,Bh,$h,Vh={exports:{}},Fh={},jh={};function Uh(){if(Lh)return jh;Lh=1;var e=ah().Options;function t(t){e.call(this,t,"css"),this.selector_separator_newline=this._get_boolean("selector_separator_newline",!0),this.newline_between_rules=this._get_boolean("newline_between_rules",!0);var n=this._get_boolean("space_around_selector_separator");this.space_around_combinator=this._get_boolean("space_around_combinator")||n;var r=this._get_selection_list("brace_style",["collapse","expand","end-expand","none","preserve-inline"]);this.brace_style="collapse";for(var i=0;i<r.length;i++)"expand"!==r[i]?this.brace_style="collapse":this.brace_style=r[i]}return t.prototype=new e,jh.Options=t,jh}function Gh(){if(Bh)return Fh;Bh=1;var e=Uh().Options,t=Wd().Output,n=dh().InputScanner,r=kh().Directives,i=new r(/\/\*/,/\*\//),o=/\r\n|[\r\n]/,a=/\r\n|[\r\n]/g,s=/\s/,l=/(?:\s|\n)+/g,c=/\/\*(?:[\s\S]*?)((?:\*\/)|$)/g,u=/\/\/(?:[^\n\r\u2028\u2029]*)/g;function d(t,n){this._source_text=t||"",this._options=new e(n),this._ch=null,this._input=null,this.NESTED_AT_RULE={page:!0,"font-face":!0,keyframes:!0,media:!0,supports:!0,document:!0},this.CONDITIONAL_GROUP_RULE={media:!0,supports:!0,document:!0},this.NON_SEMICOLON_NEWLINE_PROPERTY=["grid-template-areas","grid-template"]}return d.prototype.eatString=function(e){var t="";this._ch=this._input.next();while(this._ch){if(t+=this._ch,"\\"===this._ch)t+=this._input.next();else if(-1!==e.indexOf(this._ch)||"\n"===this._ch)break;this._ch=this._input.next()}return t},d.prototype.eatWhitespace=function(e){var t=s.test(this._input.peek()),n=0;while(s.test(this._input.peek()))this._ch=this._input.next(),e&&"\n"===this._ch&&(0===n||n<this._options.max_preserve_newlines)&&(n++,this._output.add_new_line(!0));return t},d.prototype.foundNestedPseudoClass=function(){var e=0,t=1,n=this._input.peek(t);while(n){if("{"===n)return!0;if("("===n)e+=1;else if(")"===n){if(0===e)return!1;e-=1}else if(";"===n||"}"===n)return!1;t++,n=this._input.peek(t)}return!1},d.prototype.print_string=function(e){this._output.set_indent(this._indentLevel),this._output.non_breaking_space=!0,this._output.add_token(e)},d.prototype.preserveSingleSpace=function(e){e&&(this._output.space_before_token=!0)},d.prototype.indent=function(){this._indentLevel++},d.prototype.outdent=function(){this._indentLevel>0&&this._indentLevel--},d.prototype.beautify=function(){if(this._options.disabled)return this._source_text;var e=this._source_text,r=this._options.eol;"auto"===r&&(r="\n",e&&o.test(e||"")&&(r=e.match(o)[0])),e=e.replace(a,"\n");var d=e.match(/^[\t ]*/)[0];this._output=new t(this._options,d),this._input=new n(e),this._indentLevel=0,this._nestedLevel=0,this._ch=null;var h,p,f,m=0,g=!1,v=!1,b=!1,y=!1,w=!1,O=this._ch,S=!1;while(1){if(h=this._input.read(l),p=""!==h,f=O,this._ch=this._input.next(),"\\"===this._ch&&this._input.hasNext()&&(this._ch+=this._input.next()),O=this._ch,!this._ch)break;if("/"===this._ch&&"*"===this._input.peek()){this._output.add_new_line(),this._input.back();var E=this._input.read(c),x=i.get_directives(E);x&&"start"===x.ignore&&(E+=i.readIgnored(this._input)),this.print_string(E),this.eatWhitespace(!0),this._output.add_new_line()}else if("/"===this._ch&&"/"===this._input.peek())this._output.space_before_token=!0,this._input.back(),this.print_string(this._input.read(u)),this.eatWhitespace(!0);else if("$"===this._ch){this.preserveSingleSpace(p),this.print_string(this._ch);var _=this._input.peekUntilAfter(/[: ,;{}()[\]\/='"]/g);_.match(/[ :]$/)&&(_=this.eatString(": ").replace(/\s$/,""),this.print_string(_),this._output.space_before_token=!0),_=_.replace(/\s$/,""),0===m&&-1!==_.indexOf(":")&&(v=!0,this.indent())}else if("@"===this._ch)if(this.preserveSingleSpace(p),"{"===this._input.peek())this.print_string(this._ch+this.eatString("}"));else{this.print_string(this._ch);var k=this._input.peekUntilAfter(/[: ,;{}()[\]\/='"]/g);k.match(/[ :]$/)&&(k=this.eatString(": ").replace(/\s$/,""),this.print_string(k),this._output.space_before_token=!0),k=k.replace(/\s$/,""),0===m&&-1!==k.indexOf(":")?(v=!0,this.indent()):k in this.NESTED_AT_RULE?(this._nestedLevel+=1,k in this.CONDITIONAL_GROUP_RULE&&(b=!0)):0!==m||v||(y=!0)}else if("#"===this._ch&&"{"===this._input.peek())this.preserveSingleSpace(p),this.print_string(this._ch+this.eatString("}"));else if("{"===this._ch)v&&(v=!1,this.outdent()),y=!1,b?(b=!1,g=this._indentLevel>=this._nestedLevel):g=this._indentLevel>=this._nestedLevel-1,this._options.newline_between_rules&&g&&this._output.previous_line&&"{"!==this._output.previous_line.item(-1)&&this._output.ensure_empty_line_above("/",","),this._output.space_before_token=!0,"expand"===this._options.brace_style?(this._output.add_new_line(),this.print_string(this._ch),this.indent(),this._output.set_indent(this._indentLevel)):("("===f?this._output.space_before_token=!1:","!==f&&this.indent(),this.print_string(this._ch)),this.eatWhitespace(!0),this._output.add_new_line();else if("}"===this._ch)this.outdent(),this._output.add_new_line(),"{"===f&&this._output.trim(!0),v&&(this.outdent(),v=!1),this.print_string(this._ch),g=!1,this._nestedLevel&&this._nestedLevel--,this.eatWhitespace(!0),this._output.add_new_line(),this._options.newline_between_rules&&!this._output.just_added_blankline()&&"}"!==this._input.peek()&&this._output.add_new_line(!0),")"===this._input.peek()&&(this._output.trim(!0),"expand"===this._options.brace_style&&this._output.add_new_line(!0));else if(":"===this._ch){for(var C=0;C<this.NON_SEMICOLON_NEWLINE_PROPERTY.length;C++)if(this._input.lookBack(this.NON_SEMICOLON_NEWLINE_PROPERTY[C])){S=!0;break}!g&&!b||this._input.lookBack("&")||this.foundNestedPseudoClass()||this._input.lookBack("(")||y||0!==m?(this._input.lookBack(" ")&&(this._output.space_before_token=!0),":"===this._input.peek()?(this._ch=this._input.next(),this.print_string("::")):this.print_string(":")):(this.print_string(":"),v||(v=!0,this._output.space_before_token=!0,this.eatWhitespace(!0),this.indent()))}else if('"'===this._ch||"'"===this._ch){var A='"'===f||"'"===f;this.preserveSingleSpace(A||p),this.print_string(this._ch+this.eatString(this._ch)),this.eatWhitespace(!0)}else if(";"===this._ch)S=!1,0===m?(v&&(this.outdent(),v=!1),y=!1,this.print_string(this._ch),this.eatWhitespace(!0),"/"!==this._input.peek()&&this._output.add_new_line()):(this.print_string(this._ch),this.eatWhitespace(!0),this._output.space_before_token=!0);else if("("===this._ch)if(this._input.lookBack("url"))this.print_string(this._ch),this.eatWhitespace(),m++,this.indent(),this._ch=this._input.next(),")"===this._ch||'"'===this._ch||"'"===this._ch?this._input.back():this._ch&&(this.print_string(this._ch+this.eatString(")")),m&&(m--,this.outdent()));else{var T=!1;this._input.lookBack("with")&&(T=!0),this.preserveSingleSpace(p||T),this.print_string(this._ch),v&&"$"===f&&this._options.selector_separator_newline?(this._output.add_new_line(),w=!0):(this.eatWhitespace(),m++,this.indent())}else if(")"===this._ch)m&&(m--,this.outdent()),w&&";"===this._input.peek()&&this._options.selector_separator_newline&&(w=!1,this.outdent(),this._output.add_new_line()),this.print_string(this._ch);else if(","===this._ch)this.print_string(this._ch),this.eatWhitespace(!0),!this._options.selector_separator_newline||v&&!w||0!==m||y?this._output.space_before_token=!0:this._output.add_new_line();else if(">"!==this._ch&&"+"!==this._ch&&"~"!==this._ch||v||0!==m)if("]"===this._ch)this.print_string(this._ch);else if("["===this._ch)this.preserveSingleSpace(p),this.print_string(this._ch);else if("="===this._ch)this.eatWhitespace(),this.print_string("="),s.test(this._ch)&&(this._ch="");else if("!"!==this._ch||this._input.lookBack("\\")){var R='"'===f||"'"===f;this.preserveSingleSpace(R||p),this.print_string(this._ch),!this._output.just_added_newline()&&"\n"===this._input.peek()&&S&&this._output.add_new_line()}else this._output.space_before_token=!0,this.print_string(this._ch);else this._options.space_around_combinator?(this._output.space_before_token=!0,this.print_string(this._ch),this._output.space_before_token=!0):(this.print_string(this._ch),this.eatWhitespace(),this._ch&&s.test(this._ch)&&(this._ch=""))}var N=this._output.get_code(r);return N},Fh.Beautifier=d,Fh}function Hh(){if($h)return Vh.exports;$h=1;var e=Gh().Beautifier,t=Uh().Options;function n(t,n){var r=new e(t,n);return r.beautify()}return Vh.exports=n,Vh.exports.defaultOptions=function(){return new t},Vh.exports}var qh,Qh={exports:{}},zh={},Kh={};function Wh(){if(qh)return Kh;qh=1;var e=ah().Options;function t(t){e.call(this,t,"html"),1===this.templating.length&&"auto"===this.templating[0]&&(this.templating=["django","erb","handlebars","php"]),this.indent_inner_html=this._get_boolean("indent_inner_html"),this.indent_body_inner_html=this._get_boolean("indent_body_inner_html",!0),this.indent_head_inner_html=this._get_boolean("indent_head_inner_html",!0),this.indent_handlebars=this._get_boolean("indent_handlebars",!0),this.wrap_attributes=this._get_selection("wrap_attributes",["auto","force","force-aligned","force-expand-multiline","aligned-multiple","preserve","preserve-aligned"]),this.wrap_attributes_min_attrs=this._get_number("wrap_attributes_min_attrs",2),this.wrap_attributes_indent_size=this._get_number("wrap_attributes_indent_size",this.indent_size),this.extra_liners=this._get_array("extra_liners",["head","body","/html"]),this.inline=this._get_array("inline",["a","abbr","area","audio","b","bdi","bdo","br","button","canvas","cite","code","data","datalist","del","dfn","em","embed","i","iframe","img","input","ins","kbd","keygen","label","map","mark","math","meter","noscript","object","output","progress","q","ruby","s","samp","select","small","span","strong","sub","sup","svg","template","textarea","time","u","var","video","wbr","text","acronym","big","strike","tt"]),this.inline_custom_elements=this._get_boolean("inline_custom_elements",!0),this.void_elements=this._get_array("void_elements",["area","base","br","col","embed","hr","img","input","keygen","link","menuitem","meta","param","source","track","wbr","!doctype","?xml","basefont","isindex"]),this.unformatted=this._get_array("unformatted",[]),this.content_unformatted=this._get_array("content_unformatted",["pre","textarea"]),this.unformatted_content_delimiter=this._get_characters("unformatted_content_delimiter"),this.indent_scripts=this._get_selection("indent_scripts",["normal","keep","separate"])}return t.prototype=new e,Kh.Options=t,Kh}var Xh,Yh,Zh,Jh,ep={};function tp(){if(Xh)return ep;Xh=1;var e=Eh().Tokenizer,t=Eh().TOKEN,n=kh().Directives,r=Ph().TemplatablePattern,i=Oh().Pattern,o={TAG_OPEN:"TK_TAG_OPEN",TAG_CLOSE:"TK_TAG_CLOSE",ATTRIBUTE:"TK_ATTRIBUTE",EQUALS:"TK_EQUALS",VALUE:"TK_VALUE",COMMENT:"TK_COMMENT",TEXT:"TK_TEXT",UNKNOWN:"TK_UNKNOWN",START:t.START,RAW:t.RAW,EOF:t.EOF},a=new n(/<\!--/,/-->/),s=function(t,n){e.call(this,t,n),this._current_tag_name="";var o=new r(this._input).read_options(this._options),a=new i(this._input);if(this.__patterns={word:o.until(/[\n\r\t <]/),single_quote:o.until_after(/'/),double_quote:o.until_after(/"/),attribute:o.until(/[\n\r\t =>]|\/>/),element_name:o.until(/[\n\r\t >\/]/),handlebars_comment:a.starting_with(/{{!--/).until_after(/--}}/),handlebars:a.starting_with(/{{/).until_after(/}}/),handlebars_open:a.until(/[\n\r\t }]/),handlebars_raw_close:a.until(/}}/),comment:a.starting_with(/<!--/).until_after(/-->/),cdata:a.starting_with(/<!\[CDATA\[/).until_after(/]]>/),conditional_comment:a.starting_with(/<!\[/).until_after(/]>/),processing:a.starting_with(/<\?/).until_after(/\?>/)},this._options.indent_handlebars&&(this.__patterns.word=this.__patterns.word.exclude("handlebars")),this._unformatted_content_delimiter=null,this._options.unformatted_content_delimiter){var s=this._input.get_literal_regexp(this._options.unformatted_content_delimiter);this.__patterns.unformatted_content_delimiter=a.matching(s).until_after(s)}};return s.prototype=new e,s.prototype._is_comment=function(e){return!1},s.prototype._is_opening=function(e){return e.type===o.TAG_OPEN},s.prototype._is_closing=function(e,t){return e.type===o.TAG_CLOSE&&t&&((">"===e.text||"/>"===e.text)&&"<"===t.text[0]||"}}"===e.text&&"{"===t.text[0]&&"{"===t.text[1])},s.prototype._reset=function(){this._current_tag_name=""},s.prototype._get_next_token=function(e,t){var n=null;this._readWhitespace();var r=this._input.peek();return null===r?this._create_token(o.EOF,""):(n=n||this._read_open_handlebars(r,t),n=n||this._read_attribute(r,e,t),n=n||this._read_close(r,t),n=n||this._read_raw_content(r,e,t),n=n||this._read_content_word(r),n=n||this._read_comment_or_cdata(r),n=n||this._read_processing(r),n=n||this._read_open(r,t),n=n||this._create_token(o.UNKNOWN,this._input.next()),n)},s.prototype._read_comment_or_cdata=function(e){var t=null,n=null,r=null;if("<"===e){var i=this._input.peek(1);"!"===i&&(n=this.__patterns.comment.read(),n?(r=a.get_directives(n),r&&"start"===r.ignore&&(n+=a.readIgnored(this._input))):n=this.__patterns.cdata.read()),n&&(t=this._create_token(o.COMMENT,n),t.directives=r)}return t},s.prototype._read_processing=function(e){var t=null,n=null,r=null;if("<"===e){var i=this._input.peek(1);"!"!==i&&"?"!==i||(n=this.__patterns.conditional_comment.read(),n=n||this.__patterns.processing.read()),n&&(t=this._create_token(o.COMMENT,n),t.directives=r)}return t},s.prototype._read_open=function(e,t){var n=null,r=null;return t||"<"===e&&(n=this._input.next(),"/"===this._input.peek()&&(n+=this._input.next()),n+=this.__patterns.element_name.read(),r=this._create_token(o.TAG_OPEN,n)),r},s.prototype._read_open_handlebars=function(e,t){var n=null,r=null;return t||this._options.indent_handlebars&&"{"===e&&"{"===this._input.peek(1)&&("!"===this._input.peek(2)?(n=this.__patterns.handlebars_comment.read(),n=n||this.__patterns.handlebars.read(),r=this._create_token(o.COMMENT,n)):(n=this.__patterns.handlebars_open.read(),r=this._create_token(o.TAG_OPEN,n))),r},s.prototype._read_close=function(e,t){var n=null,r=null;return t&&("<"===t.text[0]&&(">"===e||"/"===e&&">"===this._input.peek(1))?(n=this._input.next(),"/"===e&&(n+=this._input.next()),r=this._create_token(o.TAG_CLOSE,n)):"{"===t.text[0]&&"}"===e&&"}"===this._input.peek(1)&&(this._input.next(),this._input.next(),r=this._create_token(o.TAG_CLOSE,"}}"))),r},s.prototype._read_attribute=function(e,t,n){var r=null,i="";if(n&&"<"===n.text[0])if("="===e)r=this._create_token(o.EQUALS,this._input.next());else if('"'===e||"'"===e){var a=this._input.next();a+='"'===e?this.__patterns.double_quote.read():this.__patterns.single_quote.read(),r=this._create_token(o.VALUE,a)}else i=this.__patterns.attribute.read(),i&&(r=t.type===o.EQUALS?this._create_token(o.VALUE,i):this._create_token(o.ATTRIBUTE,i));return r},s.prototype._is_content_unformatted=function(e){return-1===this._options.void_elements.indexOf(e)&&(-1!==this._options.content_unformatted.indexOf(e)||-1!==this._options.unformatted.indexOf(e))},s.prototype._read_raw_content=function(e,t,n){var r="";if(n&&"{"===n.text[0])r=this.__patterns.handlebars_raw_close.read();else if(t.type===o.TAG_CLOSE&&"<"===t.opened.text[0]&&"/"!==t.text[0]){var i=t.opened.text.substr(1).toLowerCase();if("script"===i||"style"===i){var a=this._read_comment_or_cdata(e);if(a)return a.type=o.TEXT,a;r=this._input.readUntil(new RegExp("</"+i+"[\\n\\r\\t ]*?>","ig"))}else this._is_content_unformatted(i)&&(r=this._input.readUntil(new RegExp("</"+i+"[\\n\\r\\t ]*?>","ig")))}return r?this._create_token(o.TEXT,r):null},s.prototype._read_content_word=function(e){var t="";if(this._options.unformatted_content_delimiter&&e===this._options.unformatted_content_delimiter[0]&&(t=this.__patterns.unformatted_content_delimiter.read()),t||(t=this.__patterns.word.read()),t)return this._create_token(o.TEXT,t)},ep.Tokenizer=s,ep.TOKEN=o,ep}function np(){if(Yh)return zh;Yh=1;var e=Wh().Options,t=Wd().Output,n=tp().Tokenizer,r=tp().TOKEN,i=/\r\n|[\r\n]/,o=/\r\n|[\r\n]/g,a=function(e,n){this.indent_level=0,this.alignment_size=0,this.max_preserve_newlines=e.max_preserve_newlines,this.preserve_newlines=e.preserve_newlines,this._output=new t(e,n)};a.prototype.current_line_has_match=function(e){return this._output.current_line.has_match(e)},a.prototype.set_space_before_token=function(e,t){this._output.space_before_token=e,this._output.non_breaking_space=t},a.prototype.set_wrap_point=function(){this._output.set_indent(this.indent_level,this.alignment_size),this._output.set_wrap_point()},a.prototype.add_raw_token=function(e){this._output.add_raw_token(e)},a.prototype.print_preserved_newlines=function(e){var t=0;e.type!==r.TEXT&&e.previous.type!==r.TEXT&&(t=e.newlines?1:0),this.preserve_newlines&&(t=e.newlines<this.max_preserve_newlines+1?e.newlines:this.max_preserve_newlines+1);for(var n=0;n<t;n++)this.print_newline(n>0);return 0!==t},a.prototype.traverse_whitespace=function(e){return!(!e.whitespace_before&&!e.newlines)&&(this.print_preserved_newlines(e)||(this._output.space_before_token=!0),!0)},a.prototype.previous_token_wrapped=function(){return this._output.previous_token_wrapped},a.prototype.print_newline=function(e){this._output.add_new_line(e)},a.prototype.print_token=function(e){e.text&&(this._output.set_indent(this.indent_level,this.alignment_size),this._output.add_token(e.text))},a.prototype.indent=function(){this.indent_level++},a.prototype.get_full_indent=function(e){return e=this.indent_level+(e||0),e<1?"":this._output.get_indent_string(e)};var s=function(e){var t=null,n=e.next;while(n.type!==r.EOF&&e.closed!==n){if(n.type===r.ATTRIBUTE&&"type"===n.text){n.next&&n.next.type===r.EQUALS&&n.next.next&&n.next.next.type===r.VALUE&&(t=n.next.next.text);break}n=n.next}return t},l=function(e,t){var n=null,r=null;return t.closed?("script"===e?n="text/javascript":"style"===e&&(n="text/css"),n=s(t)||n,n.search("text/css")>-1?r="css":n.search(/module|((text|application|dojo)\/(x-)?(javascript|ecmascript|jscript|livescript|(ld\+)?json|method|aspect))/)>-1?r="javascript":n.search(/(text|application|dojo)\/(x-)?(html)/)>-1?r="html":n.search(/test\/null/)>-1&&(r="null"),r):null};function c(e,t){return-1!==t.indexOf(e)}function u(e,t,n){this.parent=e||null,this.tag=t?t.tag_name:"",this.indent_level=n||0,this.parser_token=t||null}function d(e){this._printer=e,this._current_frame=null}function h(t,n,r,i){this._source_text=t||"",n=n||{},this._js_beautify=r,this._css_beautify=i,this._tag_stack=null;var o=new e(n,"html");this._options=o,this._is_wrap_attributes_force="force"===this._options.wrap_attributes.substr(0,5),this._is_wrap_attributes_force_expand_multiline="force-expand-multiline"===this._options.wrap_attributes,this._is_wrap_attributes_force_aligned="force-aligned"===this._options.wrap_attributes,this._is_wrap_attributes_aligned_multiple="aligned-multiple"===this._options.wrap_attributes,this._is_wrap_attributes_preserve="preserve"===this._options.wrap_attributes.substr(0,8),this._is_wrap_attributes_preserve_aligned="preserve-aligned"===this._options.wrap_attributes}d.prototype.get_parser_token=function(){return this._current_frame?this._current_frame.parser_token:null},d.prototype.record_tag=function(e){var t=new u(this._current_frame,e,this._printer.indent_level);this._current_frame=t},d.prototype._try_pop_frame=function(e){var t=null;return e&&(t=e.parser_token,this._printer.indent_level=e.indent_level,this._current_frame=e.parent),t},d.prototype._get_frame=function(e,t){var n=this._current_frame;while(n){if(-1!==e.indexOf(n.tag))break;if(t&&-1!==t.indexOf(n.tag)){n=null;break}n=n.parent}return n},d.prototype.try_pop=function(e,t){var n=this._get_frame([e],t);return this._try_pop_frame(n)},d.prototype.indent_to_tag=function(e){var t=this._get_frame(e);t&&(this._printer.indent_level=t.indent_level)},h.prototype.beautify=function(){if(this._options.disabled)return this._source_text;var e=this._source_text,t=this._options.eol;"auto"===this._options.eol&&(t="\n",e&&i.test(e)&&(t=e.match(i)[0])),e=e.replace(o,"\n");var s=e.match(/^[\t ]*/)[0],l={text:"",type:""},c=new p,u=new a(this._options,s),h=new n(e,this._options).tokenize();this._tag_stack=new d(u);var f=null,m=h.next();while(m.type!==r.EOF)m.type===r.TAG_OPEN||m.type===r.COMMENT?(f=this._handle_tag_open(u,m,c,l,h),c=f):m.type===r.ATTRIBUTE||m.type===r.EQUALS||m.type===r.VALUE||m.type===r.TEXT&&!c.tag_complete?f=this._handle_inside_tag(u,m,c,l):m.type===r.TAG_CLOSE?f=this._handle_tag_close(u,m,c):m.type===r.TEXT?f=this._handle_text(u,m,c):u.add_raw_token(m),l=f,m=h.next();var g=u._output.get_code(t);return g},h.prototype._handle_tag_close=function(e,t,n){var r={text:t.text,type:t.type};return e.alignment_size=0,n.tag_complete=!0,e.set_space_before_token(t.newlines||""!==t.whitespace_before,!0),n.is_unformatted?e.add_raw_token(t):("<"===n.tag_start_char&&(e.set_space_before_token("/"===t.text[0],!0),this._is_wrap_attributes_force_expand_multiline&&n.has_wrapped_attrs&&e.print_newline(!1)),e.print_token(t)),!n.indent_content||n.is_unformatted||n.is_content_unformatted||(e.indent(),n.indent_content=!1),n.is_inline_element||n.is_unformatted||n.is_content_unformatted||e.set_wrap_point(),r},h.prototype._handle_inside_tag=function(e,t,n,i){var o=n.has_wrapped_attrs,a={text:t.text,type:t.type};return e.set_space_before_token(t.newlines||""!==t.whitespace_before,!0),n.is_unformatted?e.add_raw_token(t):"{"===n.tag_start_char&&t.type===r.TEXT?e.print_preserved_newlines(t)?(t.newlines=0,e.add_raw_token(t)):e.print_token(t):(t.type===r.ATTRIBUTE?e.set_space_before_token(!0):(t.type===r.EQUALS||t.type===r.VALUE&&t.previous.type===r.EQUALS)&&e.set_space_before_token(!1),t.type===r.ATTRIBUTE&&"<"===n.tag_start_char&&((this._is_wrap_attributes_preserve||this._is_wrap_attributes_preserve_aligned)&&(e.traverse_whitespace(t),o=o||0!==t.newlines),this._is_wrap_attributes_force&&n.attr_count>=this._options.wrap_attributes_min_attrs&&(i.type!==r.TAG_OPEN||this._is_wrap_attributes_force_expand_multiline)&&(e.print_newline(!1),o=!0)),e.print_token(t),o=o||e.previous_token_wrapped(),n.has_wrapped_attrs=o),a},h.prototype._handle_text=function(e,t,n){var r={text:t.text,type:"TK_CONTENT"};return n.custom_beautifier_name?this._print_custom_beatifier_text(e,t,n):n.is_unformatted||n.is_content_unformatted?e.add_raw_token(t):(e.traverse_whitespace(t),e.print_token(t)),r},h.prototype._print_custom_beatifier_text=function(e,t,n){var r=this;if(""!==t.text){var i,o=t.text,a=1,s="",l="";"javascript"===n.custom_beautifier_name&&"function"===typeof this._js_beautify?i=this._js_beautify:"css"===n.custom_beautifier_name&&"function"===typeof this._css_beautify?i=this._css_beautify:"html"===n.custom_beautifier_name&&(i=function(e,t){var n=new h(e,t,r._js_beautify,r._css_beautify);return n.beautify()}),"keep"===this._options.indent_scripts?a=0:"separate"===this._options.indent_scripts&&(a=-e.indent_level);var c=e.get_full_indent(a);if(o=o.replace(/\n[ \t]*$/,""),"html"!==n.custom_beautifier_name&&"<"===o[0]&&o.match(/^(<!--|<!\[CDATA\[)/)){var u=/^(<!--[^\n]*|<!\[CDATA\[)(\n?)([ \t\n]*)([\s\S]*)(-->|]]>)$/.exec(o);if(!u)return void e.add_raw_token(t);s=c+u[1]+"\n",o=u[4],u[5]&&(l=c+u[5]),o=o.replace(/\n[ \t]*$/,""),(u[2]||-1!==u[3].indexOf("\n"))&&(u=u[3].match(/[ \t]+$/),u&&(t.whitespace_before=u[0]))}if(o)if(i){var d=function(){this.eol="\n"};d.prototype=this._options.raw_options;var p=new d;o=i(c+o,p)}else{var f=t.whitespace_before;f&&(o=o.replace(new RegExp("\n("+f+")?","g"),"\n")),o=c+o.replace(/\n/g,"\n"+c)}s&&(o=o?s+o+"\n"+l:s+l),e.print_newline(!1),o&&(t.text=o,t.whitespace_before="",t.newlines=0,e.add_raw_token(t),e.print_newline(!0))}},h.prototype._handle_tag_open=function(e,t,n,i,o){var a=this._get_tag_open_token(t);if(!n.is_unformatted&&!n.is_content_unformatted||n.is_empty_element||t.type!==r.TAG_OPEN||a.is_start_tag?(e.traverse_whitespace(t),this._set_tag_position(e,t,a,n,i),a.is_inline_element||e.set_wrap_point(),e.print_token(t)):(e.add_raw_token(t),a.start_tag_token=this._tag_stack.try_pop(a.tag_name)),a.is_start_tag&&this._is_wrap_attributes_force){var s,l=0;do{s=o.peek(l),s.type===r.ATTRIBUTE&&(a.attr_count+=1),l+=1}while(s.type!==r.EOF&&s.type!==r.TAG_CLOSE)}return(this._is_wrap_attributes_force_aligned||this._is_wrap_attributes_aligned_multiple||this._is_wrap_attributes_preserve_aligned)&&(a.alignment_size=t.text.length+1),a.tag_complete||a.is_unformatted||(e.alignment_size=a.alignment_size),a};var p=function(e,t){if(this.parent=e||null,this.text="",this.type="TK_TAG_OPEN",this.tag_name="",this.is_inline_element=!1,this.is_unformatted=!1,this.is_content_unformatted=!1,this.is_empty_element=!1,this.is_start_tag=!1,this.is_end_tag=!1,this.indent_content=!1,this.multiline_content=!1,this.custom_beautifier_name=null,this.start_tag_token=null,this.attr_count=0,this.has_wrapped_attrs=!1,this.alignment_size=0,this.tag_complete=!1,this.tag_start_char="",this.tag_check="",t){var n;this.tag_start_char=t.text[0],this.text=t.text,"<"===this.tag_start_char?(n=t.text.match(/^<([^\s>]*)/),this.tag_check=n?n[1]:""):(n=t.text.match(/^{{~?(?:[\^]|#\*?)?([^\s}]+)/),this.tag_check=n?n[1]:"",(t.text.startsWith("{{#>")||t.text.startsWith("{{~#>"))&&">"===this.tag_check[0]&&(">"===this.tag_check&&null!==t.next?this.tag_check=t.next.text.split(" ")[0]:this.tag_check=t.text.split(">")[1])),this.tag_check=this.tag_check.toLowerCase(),t.type===r.COMMENT&&(this.tag_complete=!0),this.is_start_tag="/"!==this.tag_check.charAt(0),this.tag_name=this.is_start_tag?this.tag_check:this.tag_check.substr(1),this.is_end_tag=!this.is_start_tag||t.closed&&"/>"===t.closed.text;var i=2;"{"===this.tag_start_char&&this.text.length>=3&&"~"===this.text.charAt(2)&&(i=3),this.is_end_tag=this.is_end_tag||"{"===this.tag_start_char&&(this.text.length<3||/[^#\^]/.test(this.text.charAt(i)))}else this.tag_complete=!0};h.prototype._get_tag_open_token=function(e){var t=new p(this._tag_stack.get_parser_token(),e);return t.alignment_size=this._options.wrap_attributes_indent_size,t.is_end_tag=t.is_end_tag||c(t.tag_check,this._options.void_elements),t.is_empty_element=t.tag_complete||t.is_start_tag&&t.is_end_tag,t.is_unformatted=!t.tag_complete&&c(t.tag_check,this._options.unformatted),t.is_content_unformatted=!t.is_empty_element&&c(t.tag_check,this._options.content_unformatted),t.is_inline_element=c(t.tag_name,this._options.inline)||this._options.inline_custom_elements&&t.tag_name.includes("-")||"{"===t.tag_start_char,t},h.prototype._set_tag_position=function(e,t,n,i,o){if(n.is_empty_element||(n.is_end_tag?n.start_tag_token=this._tag_stack.try_pop(n.tag_name):(this._do_optional_end_element(n)&&(n.is_inline_element||e.print_newline(!1)),this._tag_stack.record_tag(n),"script"!==n.tag_name&&"style"!==n.tag_name||n.is_unformatted||n.is_content_unformatted||(n.custom_beautifier_name=l(n.tag_check,t)))),c(n.tag_check,this._options.extra_liners)&&(e.print_newline(!1),e._output.just_added_blankline()||e.print_newline(!0)),n.is_empty_element){if("{"===n.tag_start_char&&"else"===n.tag_check){this._tag_stack.indent_to_tag(["if","unless","each"]),n.indent_content=!0;var a=e.current_line_has_match(/{{#if/);a||e.print_newline(!1)}"!--"===n.tag_name&&o.type===r.TAG_CLOSE&&i.is_end_tag&&-1===n.text.indexOf("\n")||(n.is_inline_element||n.is_unformatted||e.print_newline(!1),this._calcluate_parent_multiline(e,n))}else if(n.is_end_tag){var s=!1;s=n.start_tag_token&&n.start_tag_token.multiline_content,s=s||!n.is_inline_element&&!(i.is_inline_element||i.is_unformatted)&&!(o.type===r.TAG_CLOSE&&n.start_tag_token===i)&&"TK_CONTENT"!==o.type,(n.is_content_unformatted||n.is_unformatted)&&(s=!1),s&&e.print_newline(!1)}else n.indent_content=!n.custom_beautifier_name,"<"===n.tag_start_char&&("html"===n.tag_name?n.indent_content=this._options.indent_inner_html:"head"===n.tag_name?n.indent_content=this._options.indent_head_inner_html:"body"===n.tag_name&&(n.indent_content=this._options.indent_body_inner_html)),n.is_inline_element||n.is_unformatted||"TK_CONTENT"===o.type&&!n.is_content_unformatted||e.print_newline(!1),this._calcluate_parent_multiline(e,n)},h.prototype._calcluate_parent_multiline=function(e,t){!t.parent||!e._output.just_added_newline()||(t.is_inline_element||t.is_unformatted)&&t.parent.is_inline_element||(t.parent.multiline_content=!0)};var f=["address","article","aside","blockquote","details","div","dl","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hr","main","menu","nav","ol","p","pre","section","table","ul"],m=["a","audio","del","ins","map","noscript","video"];return h.prototype._do_optional_end_element=function(e){var t=null;if(!e.is_empty_element&&e.is_start_tag&&e.parent){if("body"===e.tag_name)t=t||this._tag_stack.try_pop("head");else if("li"===e.tag_name)t=t||this._tag_stack.try_pop("li",["ol","ul","menu"]);else if("dd"===e.tag_name||"dt"===e.tag_name)t=t||this._tag_stack.try_pop("dt",["dl"]),t=t||this._tag_stack.try_pop("dd",["dl"]);else if("p"===e.parent.tag_name&&-1!==f.indexOf(e.tag_name)){var n=e.parent.parent;n&&-1!==m.indexOf(n.tag_name)||(t=t||this._tag_stack.try_pop("p"))}else"rp"===e.tag_name||"rt"===e.tag_name?(t=t||this._tag_stack.try_pop("rt",["ruby","rtc"]),t=t||this._tag_stack.try_pop("rp",["ruby","rtc"])):"optgroup"===e.tag_name?t=t||this._tag_stack.try_pop("optgroup",["select"]):"option"===e.tag_name?t=t||this._tag_stack.try_pop("option",["select","datalist","optgroup"]):"colgroup"===e.tag_name?t=t||this._tag_stack.try_pop("caption",["table"]):"thead"===e.tag_name?(t=t||this._tag_stack.try_pop("caption",["table"]),t=t||this._tag_stack.try_pop("colgroup",["table"])):"tbody"===e.tag_name||"tfoot"===e.tag_name?(t=t||this._tag_stack.try_pop("caption",["table"]),t=t||this._tag_stack.try_pop("colgroup",["table"]),t=t||this._tag_stack.try_pop("thead",["table"]),t=t||this._tag_stack.try_pop("tbody",["table"])):"tr"===e.tag_name?(t=t||this._tag_stack.try_pop("caption",["table"]),t=t||this._tag_stack.try_pop("colgroup",["table"]),t=t||this._tag_stack.try_pop("tr",["table","thead","tbody","tfoot"])):"th"!==e.tag_name&&"td"!==e.tag_name||(t=t||this._tag_stack.try_pop("td",["table","thead","tbody","tfoot","tr"]),t=t||this._tag_stack.try_pop("th",["table","thead","tbody","tfoot","tr"]));return e.parent=this._tag_stack.get_parser_token(),t}},zh.Beautifier=h,zh}function rp(){if(Zh)return Qh.exports;Zh=1;var e=np().Beautifier,t=Wh().Options;function n(t,n,r,i){var o=new e(t,n,r,i);return o.beautify()}return Qh.exports=n,Qh.exports.defaultOptions=function(){return new t},Qh.exports}function ip(){if(Jh)return qd;Jh=1;var e=Dh(),t=Hh(),n=rp();function r(r,i,o,a){return o=o||e,a=a||t,n(r,i,o,a)}return r.defaultOptions=n.defaultOptions,qd.js=e,qd.css=t,qd.html=r,qd}(function(e){function t(e,t,n){var r=function(t,n){return e.js_beautify(t,n)};return r.js=e.js_beautify,r.css=t.css_beautify,r.html=n.html_beautify,r.js_beautify=e.js_beautify,r.css_beautify=t.css_beautify,r.html_beautify=n.html_beautify,r}(function(e){var n=ip();n.js_beautify=n.js,n.css_beautify=n.css,n.html_beautify=n.html,e.exports=t(n,n,n)})(e)})(Hd);var op=Hd.exports,ap=Ud(op),sp=function(){function e(e){var t=this;this.isDisabled=function(){var e=["BUTTON","COMMAND","FIELDSET","KEYGEN","OPTGROUP","OPTION","SELECT","TEXTAREA","INPUT"],n=void 0!==t.attributes().disabled,r=Ld(t.element)&&e.includes(t.element.tagName);return n&&r},this.wrapperElement=e}return Object.defineProperty(e.prototype,"element",{get:function(){return this.wrapperElement},enumerable:!1,configurable:!0}),e.prototype.findAllDOMElements=function(e){var t=this.getRootNodes().filter(Ld);if(0===t.length)return[];var n=Tu([],t.filter(function(t){return t.matches(e)}),!0);return t.forEach(function(t){n.push.apply(n,Array.from(t.querySelectorAll(e)))}),n},e.prototype.find=function(e){if("object"===typeof e&&"ref"in e){var t=this.getCurrentComponent();if(!t)return Pd("DOMWrapper");var n=t.refs[e.ref];return Array.isArray(n)&&(n=n.length?n[0]:void 0),n instanceof Node?Vd(n):Pd("DOMWrapper")}var r=this.findAll(e);return r.length>0?r[0]:Pd("DOMWrapper")},e.prototype.findComponent=function(e){var t=this.getCurrentComponent();if(!t)return Pd("VueWrapper");if("object"===typeof e&&"ref"in e){var n=t.refs[e.ref];return Array.isArray(n)&&(n=n.length?n[0]:void 0),!n||n instanceof HTMLElement?Pd("VueWrapper"):Fd(null,n)}if(Cd(t.vnode,e)&&this.element.contains(t.vnode.el))return Fd(null,t.subTree.component?t.subTree.component.proxy:t.proxy);var r=this.findAllComponents(e)[0];return null!==r&&void 0!==r?r:Pd("VueWrapper")},e.prototype.findAllComponents=function(e){var t=this.getCurrentComponent();if(!t)return[];var n=Nd(t.subTree,e);return n.map(function(e){return e.proxy?Fd(null,e.proxy):Vd(e.vnode.el)})},e.prototype.html=function(e){var t=this.getRootNodes().map(function(e){return jd(e)});return(null===e||void 0===e?void 0:e.raw)?t.join(""):t.map(function(e){return ap.html(e,{unformatted:["code","pre","em","strong","span"],indent_inner_html:!0,indent_size:2,inline_custom_elements:!1})}).join("\n")},e.prototype.classes=function(e){var t=Ld(this.element)?Array.from(this.element.classList):[];return e?t.includes(e):t},e.prototype.attributes=function(e){var t={};if(Ld(this.element))for(var n=Array.from(this.element.attributes),r=0,i=n;r<i.length;r++){var o=i[r];t[o.localName]=o.value}return e?t[e]:t},e.prototype.text=function(){return this.getRootNodes().map(Uu).join("")},e.prototype.exists=function(){return!0},e.prototype.get=function(e){var t=this.find(e);if(t.exists())return t;throw new Error("Unable to get ".concat(e," within: ").concat(this.html()))},e.prototype.getComponent=function(e){var t=this.findComponent(e);if(t.exists())return t;var n="Unable to get ";throw n+="string"===typeof e?"component with selector ".concat(e):"name"in e?"component with name ".concat(e.name):"ref"in e?"component with ref ".concat(e.ref):"specified component",n+=" within: ".concat(this.html()),new Error(n)},e.prototype.isVisible=function(){return Ld(this.element)&&Dd(this.element)},e.prototype.trigger=function(e,t){return Cu(this,void 0,void 0,function(){var n;return Au(this,function(i){if(t&&t["target"])throw Error("[vue-test-utils]: you cannot set the target value of an event. See the notes section of the docs for more details—https://vue-test-utils.vuejs.org/api/wrapper/trigger.html");return this.element&&!this.isDisabled()&&(n=ld(e,t),n._vts=Date.now()+1,this.element.dispatchEvent(n)),[2,(0,r.nextTick)()]})})},e}(),lp=function(e){function t(t){var n=this;return t?(n=e.call(this,t)||this,Nu.plugins.DOMWrapper.extend(n),n):Pd("DOMWrapper")}return _u(t,e),t.prototype.getRootNodes=function(){return[this.wrapperElement]},t.prototype.getCurrentComponent=function(){var e,t=this.element.__vueParentComponent;while((null===(e=null===t||void 0===t?void 0:t.parent)||void 0===e?void 0:e.vnode.el)===this.element)t=t.parent;return t},t.prototype.find=function(t){var n=e.prototype.find.call(this,t);return n.exists()&&qu(t)?this.element.contains(n.element)?n:Pd("DOMWrapper"):n},t.prototype.findAll=function(e){return this.wrapperElement instanceof Element?Array.from(this.wrapperElement.querySelectorAll(e),Vd):[]},t.prototype.findAllComponents=function(t){var n=this,r=e.prototype.findAllComponents.call(this,t);return r.filter(function(e){return n.element.contains(e.element)})},t.prototype.setChecked=function(){return Cu(this,arguments,void 0,function(e){var t,n;return void 0===e&&(e=!0),Au(this,function(r){if(t=this.element,n=this.attributes().type,"radio"===n&&!e)throw Error('wrapper.setChecked() cannot be called with parameter false on a \'<input type="radio" /> element.');return e===t.checked?[2]:(t.checked=e,this.trigger("input"),[2,this.trigger("change")])})})},t.prototype.setValue=function(e){var t=this.element,n=t.tagName,r=this.attributes().type;if("OPTION"===n)return this.setSelected(),Promise.resolve();if("INPUT"===n&&"checkbox"===r)return this.setChecked(e);if("INPUT"===n&&"radio"===r)return this.setChecked(e);if("SELECT"===n){if(Array.isArray(e))for(var i=t,o=0;o<i.options.length;o++){var a=i.options[o];a.selected=e.includes(a.value)}else t.value=e;return this.trigger("input"),this.trigger("change")}if("INPUT"===n||"TEXTAREA"===n)return t.value=e,this.trigger("input"),this.trigger("change");throw Error("wrapper.setValue() cannot be called on ".concat(n))},t.prototype.setSelected=function(){var e=this.element;if(!e.selected){e.selected=!0;var n=e.parentElement;"OPTGROUP"===n.tagName&&(n=n.parentElement);var r=new t(n);return r.trigger("input"),r.trigger("change")}},t}(sp);function cp(e){if(1&e.shapeFlag)return[e.el];if(6&e.shapeFlag){var t=e.component.subTree;return cp(t)}if(128&e.shapeFlag)return cp(e.suspense.activeBranch);if(72&e.shapeFlag){var n=[e.el];if(e.anchor){var r=n[0].nextSibling;while(r&&r.previousSibling!==e.anchor)n.push(r),r=r.nextSibling}return n}if(16&e.shapeFlag){var i=e.children.flat();return i.flatMap(function(e){return cp(e)}).filter(Hu)}return[]}$d(Ed.DOMWrapper,function(e){return new lp(e)});var up={};function dp(e,t){var n=e.$.uid,r=up[n]||{};return t?r?r[t]:void 0:r}var hp=function(){var e=Ju();if(e.__VUE_DEVTOOLS_GLOBAL_HOOK__){var t=e.__VUE_DEVTOOLS_GLOBAL_HOOK__.emit;e.__VUE_DEVTOOLS_GLOBAL_HOOK__.emit=function(n){for(var r=[],i=1;i<arguments.length;i++)r[i-1]=arguments[i];t.call.apply(t,Tu([e.__VUE_DEVTOOLS_GLOBAL_HOOK__,n],r,!1)),pp(n,r)}}else(0,r.setDevtoolsHook)(fp(),{})};function pp(e,t){if("component:emit"===e){t[0];var n=t[1],r=t[2],i=t[3];mp(n,r,i)}}function fp(){return{emit:function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];pp(e,t)}}}var mp=function(e,t,n){var r=e;while("function"===typeof(null===r||void 0===r?void 0:r.type))r=r.parent;var i=r.uid;i in up||(up[i]={}),t in up[i]||(up[i][t]=[]),up[i][t].push(n)},gp=function(e){var t=e.$.uid;delete up[t]};function vp(e,t){return new Proxy(e,{get:function(e,n,r){return e.$.exposed&&e.$.exposeProxy&&n in e.$.exposeProxy?Reflect.get(e.$.exposeProxy,n,r):n in t?Reflect.get(t,n,r):n in e.$.appContext.config.globalProperties?Reflect.get(e.$.appContext.config.globalProperties,n,r):e.$.ctx[n]},set:function(e,n,r,i){return n in t?Reflect.set(t,n,r,i):Reflect.set(e,n,r,i)},has:function(e,n){return Reflect.has(t,n)||Reflect.has(e,n)},defineProperty:function(e,n,r){return n in t?Reflect.defineProperty(t,n,r):Reflect.defineProperty(e,n,r)},getOwnPropertyDescriptor:function(e,n){return n in t?Reflect.getOwnPropertyDescriptor(t,n):Reflect.getOwnPropertyDescriptor(e,n)},deleteProperty:function(e,n){return n in t?Reflect.deleteProperty(t,n):Reflect.deleteProperty(e,n)}})}var bp=function(e){function t(t,n,r){var i=e.call(this,null===n||void 0===n?void 0:n.$el)||this;return i.cleanUpCallbacks=[],i.__app=t,i.rootVM=null===n||void 0===n?void 0:n.$root,Yu(n)?i.componentVM=vp(n,n.$.setupState):i.componentVM=n,i.__setProps=r,i.attachNativeEventListener(),Nu.plugins.VueWrapper.extend(i),i}return _u(t,e),Object.defineProperty(t.prototype,"hasMultipleRoots",{get:function(){var e=function(t){var n;if(16===t.shapeFlag)return!0;if(4&t.shapeFlag||2&t.shapeFlag){if(null===(n=t.component)||void 0===n?void 0:n.subTree)return e(t.component.subTree);if(16&t.shapeFlag)return!0}return!1};return e(this.vm.$.subTree)},enumerable:!1,configurable:!0}),t.prototype.getRootNodes=function(){return cp(this.vm.$.vnode)},Object.defineProperty(t.prototype,"parentElement",{get:function(){return this.vm.$el.parentElement},enumerable:!1,configurable:!0}),t.prototype.getCurrentComponent=function(){return this.vm.$},t.prototype.exists=function(){return!this.getCurrentComponent().isUnmounted},t.prototype.findAll=function(e){return this.findAllDOMElements(e).map(Vd)},t.prototype.attachNativeEventListener=function(){var e=this.vm;if(e){var t=e.$options.emits?Array.isArray(e.$options.emits)?e.$options.emits:Object.keys(e.$options.emits):[],n=this.getRootNodes().filter(function(e){return e instanceof Element});if(1===n.length)for(var r=n[0],i=function(n){if(t.includes(n))return"continue";var i=function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];mp(e.$,n,t)};r.addEventListener(n,i),o.cleanUpCallbacks.push(function(){r.removeEventListener(n,i)})},o=this,a=0,s=Object.keys(id);a<s.length;a++){var l=s[a];i(l)}}},Object.defineProperty(t.prototype,"element",{get:function(){return this.hasMultipleRoots?this.parentElement:this.vm.$el},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"vm",{get:function(){return this.componentVM},enumerable:!1,configurable:!0}),t.prototype.props=function(e){var t=this.componentVM.$props;return e?t[e]:t},t.prototype.emitted=function(e){return dp(this.vm,e)},t.prototype.isVisible=function(){var e=Vd(this.element);return e.isVisible()},t.prototype.setData=function(e){return Bu(this.componentVM.$data,e),(0,r.nextTick)()},t.prototype.setProps=function(e){if(this.vm.$parent!==this.rootVM||!this.__setProps)throw Error("You can only use setProps on your mounted component");return this.__setProps(e),(0,r.nextTick)()},t.prototype.setValue=function(e,t){var n=t||"modelValue";return this.vm.$emit("update:".concat(n),e),this.vm.$nextTick()},t.prototype.unmount=function(){if(!this.__app)throw new Error("wrapper.unmount() can only be called by the root wrapper");gp(this.vm),this.cleanUpCallbacks.forEach(function(e){return e()}),this.cleanUpCallbacks=[],this.__app.unmount()},t}(sp);function yp(e,t){void 0===e&&(e=""),void 0===t&&(t=i);var n=e.trim(),r=n&&n.startsWith("<template");r||(n='<template #default="params">'.concat(n,"</template>"));var o=eo("<transition>".concat(n,"</transition>"),{mode:"function",prefixIdentifiers:!1}).code,a=new Function("Vue",o),s=a(t);return function(e){void 0===e&&(e={});var t=s(e),n=Object.keys(t.children)[0];return t.children[n](e)}}$d(Ed.VueWrapper,function(e,t,n){return new bp(e,t,n)});var wp=function(e){return e.__isTeleport},Op=function(e){return e.__isKeepAlive},Sp=function(e,t,n){return!!(!n||e.component===t&&!(null===n||void 0===n?void 0:n.parent)||e.functional&&e.functional===t)},Ep=function(e){var t=e.rootComponents,n=e.transformers,r=new WeakMap;return function(e,i){var o=e[0],a=e[1],s=e[2],l=e.slice(3);if(!Vu(o))return Tu([o,a,s],l,!0);var c=o,u=r.get(o);if(u&&!Sp(t,c,i)&&!wp(o)&&!Op(o))return Tu([u,a,s],l,!0);var d=n.reduce(function(e,t){return t(e,i)},c);return o!==d&&(r.set(o,d),ud({source:o,stub:d}),wp(o)||Op(o))?Tu([d,a,function(){return s}],l,!0):Tu([d,a,s],l,!0)}},xp=function(e){var t=e;return Object.keys(t).reduce(function(e,n){var r,i,o,a;return"symbol"===typeof t[n]?ku(ku({},e),(r={},r[n]=[null===(a=t[n])||void 0===a?void 0:a.toString()],r)):"function"===typeof t[n]?ku(ku({},e),(i={},i[n]=["[Function]"],i)):ku(ku({},e),(o={},o[n]=t[n],o))},{})},_p=function(e){return e.replace(/-/,"").toUpperCase()},kp=function(e){return e.replace(/(^\w|-\w)/g,_p)},Cp={teleport:wp,"keep-alive":Op,transition:function(e){return e===r.Transition||e===r.BaseTransition},"transition-group":function(e){return e===r.TransitionGroup}},Ap=function(e,t,n,r){var i=kp(e);if(t(n)&&(i in r||e in r)){if(e in r&&!1===r[e])return n;if(i in r&&!1===r[i])return n;if(!0===r[e]||!0===r[i])return Tp({name:e,type:n,renderStubDefaultSlot:!0})}},Tp=function(e){var t=e.name,n=e.type,i=e.renderStubDefaultSlot,o="anonymous-stub",a=t?"".concat(vd(t),"-stub"):o,s=n&&Od(n)||{},l=(0,r.defineComponent)({name:t||o,props:s.props||{},model:s.model,setup:function(e,t){var n=t.slots;return function(){var t=xp(e);return i&&n.default?(0,r.h)(a,t,n.default({})):(0,r.h)(a,t)}}}),c=n.__asyncLoader;return c&&c().then(function(){ud({source:n.__asyncResolved,stub:l})}),l},Rp=function(e,t){for(var n=0,r=Object.entries(t);n<r.length;n++){var i=r[n],o=i[0],a=i[1];if(bd(e,o))return a}};function Np(e){var t=e.rootComponents,n=e.stubs,r=void 0===n?{}:n,i=e.shallow,o=void 0!==i&&i,a=e.renderStubDefaultSlot,s=void 0!==a&&a;return function(e,n){var i,a,l;for(var c in Cp){var u=Cp[c],d=Ap(c,u,e,r);if(d)return d}if(Sp(t,e,n))return e;var h=_d(n,e),p=kd(n,e),f=null,m=null;if(h&&(f=Rp(h,r),f&&(m=h)),!f&&p&&(f=Rp(p,r),f&&(m=p)),Vu(f)){var g=Od(f),v=Fu(g)?g:null;ud({source:e,stub:f});var b=v?function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return v.apply(void 0,e)}:ku({},g);return b.props=g.props,b}if(!1===f)return e;if(!0===f||o){var y=m||h||p;return null!==(l=null===(a=(i=Nu.plugins).createStubs)||void 0===a?void 0:a.call(i,{name:y,component:e,registerStub:ud}))&&void 0!==l?l:Tp({name:y,type:e,renderStubDefaultSlot:s})}return e}}var Pp=function(){};function Ip(e){var t=e.directives,n=void 0===t?{}:t;return 0===Object.keys(n).length?function(e){return e}:function(e){if(ju(e)&&e.directives){var t=Object.keys(e.directives).filter(function(e){return e in n});if(!t.length)return e;var r=Object.fromEntries(t.map(function(e){var t=n[e];return[e,"boolean"===typeof t?Pp:t]}));return ku(ku({},e),{directives:ku(ku({},e.directives),r)})}return e}}var Mp=function(e,t){return!!(0,r.isRef)(e)||!!Du(e)&&(!t.has(e)&&(t.set(e,!0),Object.values(e).some(function(e){return Mp(e,t)})))},Dp=function(e){var t=new WeakMap;return Mp(e,t)},Lp=["attachTo","attrs","data","props","slots","global","shallow"];function Bp(e){e.methods&&(Eu.warn("Passing a `methods` option to mount was deprecated on Vue Test Utils v1, and it won't have any effect on v2. For additional info: https://vue-test-utils.vuejs.org/upgrading-to-v1/#setmethods-and-mountingoptions-methods"),delete e.methods);for(var t=ku({},e),n=0,r=Object.keys(e);n<r.length;n++){var i=r[n];Lp.includes(i)&&delete t[i]}return t}function $p(e,t){var n,i=Od(e),o=Bp(null!==t&&void 0!==t?t:{}),a={};function s(e){switch(typeof e){case"function":return e;case"object":return function(){return(0,r.h)(e)};case"string":return yp(e);default:throw Error("Invalid slot received.")}}Fu(i)||Sd(i)?(n=(0,r.defineComponent)(ku({compatConfig:{MODE:3,INSTANCE_LISTENERS:!1,INSTANCE_ATTRS_CLASS_STYLE:!1,COMPONENT_FUNCTIONAL:!!Sd(i)&&"suppress-warning"},props:i.props||{},setup:function(e,t){var n=t.attrs,o=t.slots;return function(){return(0,r.h)(i,ku(ku({},e),n),o)}}},o)),a.functional=i):n=ju(i)?ku(ku({},i),o):i,a.component=n,ud({source:i,stub:n});var l=(null===t||void 0===t?void 0:t.slots)&&Object.entries(t.slots).reduce(function(e,t){var n=t[0],r=t[1];if(Array.isArray(r)){var i=r.map(s);return e[n]=function(e){return i.map(function(t){return t(e)})},e}return e[n]=s(r),e},{});if(null===t||void 0===t?void 0:t.data){var c=t.data();if(!ju(i))throw new Error("data() option is not supported on functional and class components");var u=n,d=i.data||function(){return{}};u.data=function(e){return ku(ku({},d.call(e,e)),c)}}var h="VTU_COMPONENT",p=(0,r.shallowReactive)({}),f=(0,r.reactive)({});Object.entries(ku(ku(ku(ku({},null===t||void 0===t?void 0:t.attrs),null===t||void 0===t?void 0:t.propsData),null===t||void 0===t?void 0:t.props),{ref:h})).forEach(function(e){var t=e[0],n=e[1];Dp(n)?p[t]=n:f[t]=n});var m=Mu(null===t||void 0===t?void 0:t.global);ju(n)&&(n.components=ku(ku({},n.components),m.components));var g=(0,r.ref)(null),v=(0,r.defineComponent)({name:"VTU_ROOT",setup:function(){var e;return e={},e[h]=g,e},render:function(){return(0,r.h)(n,ku(ku({},f),p),l)}}),b=(0,r.createApp)(v);if(hp(),null===m||void 0===m?void 0:m.mocks){var y={beforeCreate:function(){if(Zu(this)){for(var e=0,t=Object.entries(m.mocks);e<t.length;e++){var n=t[e],r=n[0],i=n[1];try{this.$.setupState[r]=i}catch(qp){}}this.$.proxy=new Proxy(this.$.proxy,{get:function(e,t){return t in m.mocks?m.mocks[t]:e[t]}})}else for(var o=0,a=Object.entries(m.mocks);o<a.length;o++){var s=a[o];r=s[0],i=s[1];this[r]=i}}};b.mixin(y)}if(m.config)for(var w=0,O=Object.entries(m.config);w<O.length;w++){var S=O[w],E=S[0],x=S[1];b.config[E]=Du(b.config[E])?Object.assign(b.config[E],x):x}if(m.provide)for(var _=0,k=Reflect.ownKeys(m.provide);_<k.length;_++){var C=k[_];b.provide(C,m.provide[C])}if(m.plugins)for(var A=0,T=m.plugins;A<T.length;A++){var R=T[A];Array.isArray(R)?b.use.apply(b,Tu([R[0]],R.slice(1),!1)):b.use(R)}if(m.mixins)for(var N=0,P=m.mixins;N<P.length;N++){y=P[N];b.mixin(y)}if(m.components)for(var I=0,M=Object.keys(m.components);I<M.length;I++){C=M[I];C in m.stubs||b.component(C,m.components[C])}if(m.directives)for(var D=0,L=Object.keys(m.directives);D<L.length;D++){C=L[D];b.directive(C,m.directives[C])}if((0,r.transformVNodeArgs)(Ep({rootComponents:a,transformers:[Np({rootComponents:a,stubs:Wu(m.stubs),shallow:null===t||void 0===t?void 0:t.shallow,renderStubDefaultSlot:m.renderStubDefaultSlot}),Ip({directives:Xu(m.stubs)})]})),null===m||void 0===m?void 0:m.stubs)for(var B=0,$=Object.keys(Wu(m.stubs));B<$.length;B++){var V=$[B];b.component(V)||b.component(V,{name:V})}return{app:b,props:f,componentRef:g}}var Vp=!1,Fp=[];function jp(e){Vp&&Fp.push(e)}function Up(e,t){var n=$p(e,t),r=n.app,i=n.props,o=n.componentRef,a=function(e){for(var t=0,n=Object.entries(e);t<n.length;t++){var r=n[t],o=r[0],a=r[1];i[o]=a}return d.$nextTick()},s=r.config.errorHandler,l=[];r.config.errorHandler=function(e,t,n){return l.push(e),null===s||void 0===s?void 0:s(e,t,n)};var c=document.createElement("div");if(null===t||void 0===t?void 0:t.attachTo){var u=void 0;if("string"===typeof t.attachTo){if(u=document.querySelector(t.attachTo),!u)throw new Error("Unable to find the element matching the selector ".concat(t.attachTo," given as the `attachTo` option"))}else u=t.attachTo;u.appendChild(c)}var d=r.mount(c);if(l.length)throw l[0];r.config.errorHandler=s;var h=o.value;r.hasOwnProperty||(h.hasOwnProperty=function(e){return Reflect.has(h,e)});var p=Fd(r,h,a);return jp(p),p}var Gp=function(e,t){return Up(e,ku(ku({},t),{shallow:!0}))};var Hp={path:"/",name:void 0,redirectedFrom:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},href:"/"};(0,r.defineComponent)({name:"RouterLinkStub",compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},custom:{type:Boolean,default:!1}},render:function(){var e,t,n=this,i=(0,r.computed)(function(){return Hp}),o=null===(t=null===(e=this.$slots)||void 0===e?void 0:e.default)||void 0===t?void 0:t.call(e,{route:i,href:(0,r.computed)(function(){return i.value.href}),isActive:(0,r.computed)(function(){return!1}),isExactActive:(0,r.computed)(function(){return!1}),navigate:function(){return Cu(n,void 0,void 0,function(){return Au(this,function(e){return[2]})})}});return this.custom?o:(0,r.h)("a",void 0,o)}}),"function"===typeof setImmediate?setImmediate:setTimeout},20941:function(e,t,n){"use strict";function r(){var e=arguments[0];"string"==typeof e&&(e=document.createElement(e));var t=1,n=arguments[1];if(n&&"object"==typeof n&&null==n.nodeType&&!Array.isArray(n)){for(var r in n)if(Object.prototype.hasOwnProperty.call(n,r)){var o=n[r];"string"==typeof o?e.setAttribute(r,o):null!=o&&(e[r]=o)}t++}for(;t<arguments.length;t++)i(e,arguments[t]);return e}function i(e,t){if("string"==typeof t)e.appendChild(document.createTextNode(t));else if(null==t);else if(null!=t.nodeType)e.appendChild(t);else{if(!Array.isArray(t))throw new RangeError("Unsupported child node: "+t);for(var n=0;n<t.length;n++)i(e,t[n])}}n.d(t,{A:function(){return r}})},97519:function(e,t,n){"use strict";n.d(t,{A:function(){return Pe}});var r=n(4364);
|
||
/*! @license DOMPurify 3.4.16 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.4.16/LICENSE */function i(e,t){this.v=e,this.k=t}function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function a(e){if(Array.isArray(e))return e}function s(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,i,o,a,s=[],l=!0,c=!1;try{if(o=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=o.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(e){c=!0,i=e}finally{try{if(!l&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw i}}return s}}function l(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}
|
||
/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */function c(e,t){return a(e)||s(e,t)||u(e,t)||l()}function u(e,t){if(e){if("string"==typeof e)return o(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o(e,t):void 0}}function d(e){var t,n;function r(t,n){try{var a=e[t](n),s=a.value,l=s instanceof i;Promise.resolve(l?s.v:s).then(function(n){if(l){var i="return"===t&&s.k?t:"next";if(!s.k||n.done)return r(i,n);n=e[i](n).value}o(!!a.done,n)},function(e){r("throw",e)})}catch(e){o(2,e)}}function o(e,i){2===e?t.reject(i):t.resolve({value:i,done:e}),(t=t.next)?r(t.key,t.arg):n=null}this._invoke=function(e,i){return new Promise(function(o,a){var s={key:e,arg:i,resolve:o,reject:a,next:null};n?n=n.next=s:(t=n=s,r(e,i))})},"function"!=typeof e.return&&(this.return=void 0)}d.prototype["function"==typeof Symbol&&Symbol.asyncIterator||"@@asyncIterator"]=function(){return this},d.prototype.next=function(e){return this._invoke("next",e)},d.prototype.throw=function(e){return this._invoke("throw",e)},d.prototype.return=function(e){return this._invoke("return",e)};const h=Object.entries,p=Object.setPrototypeOf,f=Object.isFrozen,m=Object.getPrototypeOf,g=Object.getOwnPropertyDescriptor;let v=Object.freeze,b=Object.seal,y=Object.create,w="undefined"!==typeof Reflect&&Reflect,O=w.apply,S=w.construct;v||(v=function(e){return e}),b||(b=function(e){return e}),O||(O=function(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];return e.apply(t,r)}),S||(S=function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return new e(...n)});const E=G(Array.prototype.forEach);Array.prototype.indexOf;const x=G(Array.prototype.lastIndexOf),_=G(Array.prototype.pop),k=G(Array.prototype.push);Array.prototype.slice;const C=G(Array.prototype.splice),A=Array.isArray,T=G(String.prototype.toLowerCase),R=G(String.prototype.toString),N=G(String.prototype.match),P=G(String.prototype.replace),I=G(String.prototype.indexOf),M=G(String.prototype.trim),D=G(Number.prototype.toString),L=G(Boolean.prototype.toString),B="undefined"===typeof BigInt?null:G(BigInt.prototype.toString),$="undefined"===typeof Symbol?null:G(Symbol.prototype.toString),V=G(Object.prototype.hasOwnProperty),F=G(Object.prototype.toString),j=G(RegExp.prototype.test),U=H(TypeError);function G(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);for(var n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];return O(e,t,r)}}function H(e){return function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return S(e,n)}}function q(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:T;if(p&&p(e,null),!A(t))return e;let r=t.length;while(r--){let i=t[r];if("string"===typeof i){const e=n(i);e!==i&&(f(t)||(t[r]=e),i=e)}e[i]=!0}return e}function Q(e){for(let t=0;t<e.length;t++)V(e,t)||(e[t]=null);return e}function z(e){const t=y(null);for(const r of h(e)){var n=c(r,2);const i=n[0],o=n[1];V(e,i)&&(A(o)?t[i]=Q(o):o&&"object"===typeof o&&o.constructor===Object?t[i]=z(o):t[i]=o)}return t}function K(e){switch(typeof e){case"string":return e;case"number":return D(e);case"boolean":return L(e);case"bigint":return B?B(e):"0";case"symbol":return $?$(e):"Symbol()";case"undefined":return F(e);case"function":case"object":{if(null===e)return F(e);const t=e,n=W(t,"toString");if("function"===typeof n){const e=n(t);return"string"===typeof e?e:F(e)}return F(e)}default:return F(e)}}function W(e,t){while(null!==e){const n=g(e,t);if(n){if(n.get)return G(n.get);if("function"===typeof n.value)return G(n.value)}e=m(e)}function n(){return null}return n}function X(e){try{return j(e,""),!0}catch(t){return!1}}const Y=v(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","search","section","select","shadow","slot","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),Z=v(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","enterkeyhint","exportparts","filter","font","g","glyph","glyphref","hkern","image","inputmode","line","lineargradient","marker","mask","metadata","mpath","part","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),J=v(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),ee=v(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),te=v(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),ne=v(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),re=v(["#text"]),ie=v(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","command","commandfor","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","exportparts","face","for","headers","height","hidden","high","href","hreflang","id","inert","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","part","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","slot","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns"]),oe=v(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dominant-baseline","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","mask-type","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","pointer-events","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-orientation","text-rendering","textlength","type","u1","u2","unicode","values","vector-effect","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),ae=v(["accent","accentunder","align","bevelled","close","columnalign","columnlines","columnspacing","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lquote","lspace","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),se=v(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),le=b(/{{[\w\W]*|^[\w\W]*}}/g),ce=b(/<%[\w\W]*|^[\w\W]*%>/g),ue=b(/\${[\w\W]*/g),de=b(/^data-[\-\w.\u00B7-\uFFFF]+$/),he=b(/^aria-[\-\w]+$/),pe=b(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),fe=b(/^(?:\w+script|data):/i),me=b(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),ge=b(/^html$/i),ve=b(/^[a-z][.\w]*(-[.\w]+)+$/i),be=b(/<[/\w!]/g),ye=b(/<[/\w]/g),we=b(/<\/no(script|embed|frames)/i),Oe=b(/\/>/i),Se={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,processingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},Ee=["style","script","xmp","iframe","noembed","noframes","plaintext","noscript"],xe=v(q({},Ee)),_e=function(){const e={};return E(Ee,t=>{e[t]=b(new RegExp("</"+t+"(?=[\\t\\n\\f\\r />])","i"))}),v(e)}(),ke=function(){return"undefined"===typeof window?null:window},Ce=function(e,t){if("object"!==typeof e||"function"!==typeof e.createPolicy)return null;let n=null;const i="data-tt-policy-suffix";t&&t.hasAttribute(i)&&(n=t.getAttribute(i));const o="dompurify"+(n?"#"+n:"");try{return e.createPolicy(o,{createHTML(e){return e},createScriptURL(e){return e}})}catch(a){return r.warn("TrustedTypes policy "+o+" could not be created."),null}},Ae=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},Te=function(e,t,n,r){return V(e,t)&&A(e[t])?q(r.base?z(r.base):{},e[t],r.transform):n},Re=function(e,t,n){const r=V(e,t)?e[t]:void 0;return r&&"object"===typeof r?z(r):n()};function Ne(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:ke();const t=e=>Ne(e);if(t.version="3.4.16",t.removed=[],!e||!e.document||e.document.nodeType!==Se.document||!e.Element)return t.isSupported=!1,t;let n=e.document;const r=n,i=r.currentScript;e.DocumentFragment;const o=e.HTMLTemplateElement,a=e.Node,s=e.Element,l=e.NodeFilter;void 0===e.NamedNodeMap&&(e.NamedNodeMap||e.MozNamedAttrMap),e.HTMLFormElement;const c=e.DOMParser,u=e.trustedTypes,d=s.prototype,p=W(d,"cloneNode"),f=W(d,"remove"),m=W(d,"removeAttributeNode"),g=W(d,"nextSibling"),w=W(d,"childNodes"),O=W(d,"parentNode"),S=W(d,"shadowRoot"),D=W(d,"attributes"),L=a&&a.prototype?W(a.prototype,"nodeType"):null,B=a&&a.prototype?W(a.prototype,"nodeName"):null,$=a&&a.prototype?W(a.prototype,"ownerDocument"):null,F=function(e){return L?L(e):e.nodeType},G=function(e){return B?B(e):e.nodeName};if("function"===typeof o){const e=n.createElement("template");e.content&&e.content.ownerDocument&&(n=e.content.ownerDocument)}let H,Q,Ee="",Pe=!1,Ie=0;const Me=function(){if(Ie>0)throw U('A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the "DOMPurify and Trusted Types" section of the README.')},De=function(e){Me(),Ie++;try{return H.createHTML(e)}finally{Ie--}},Le=function(e){Me(),Ie++;try{return H.createScriptURL(e)}finally{Ie--}},Be=function(){return Pe||(Q=Ce(u,i),Pe=!0),Q},$e=n,Ve=$e.implementation,Fe=$e.createNodeIterator,je=$e.createDocumentFragment,Ue=$e.getElementsByTagName,Ge=r.importNode;let He=Ae();t.isSupported="function"===typeof h&&"function"===typeof O&&Ve&&void 0!==Ve.createHTMLDocument;const qe=le,Qe=ce,ze=ue,Ke=de,We=he,Xe=fe,Ye=me,Ze=ve;let Je=pe,et=null;const tt=q({},[...Y,...Z,...J,...te,...re]);let nt=null;const rt=q({},[...ie,...oe,...ae,...se]);let it=Object.seal(y(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),ot=null,at=null;const st=Object.seal(y(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}}));let lt=!0,ct=!0,ut=!1,dt=!0,ht=!1,pt=!0,ft=!1,mt=!1,gt=null,vt=null,bt=!1,yt=!1,wt=!1,Ot=!1,St=!0,Et=!1;const xt="user-content-";let _t=!0,kt=!1,Ct={},At=null;const Tt=q({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","selectedcontent","style","svg","template","thead","title","video","xmp"]);let Rt=null;const Nt=q({},["audio","video","img","source","image","track"]);let Pt=null;const It=q({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),Mt="http://www.w3.org/1998/Math/MathML",Dt="http://www.w3.org/2000/svg",Lt="http://www.w3.org/1999/xhtml";let Bt=Lt,$t=!1,Vt=null;const Ft=q({},[Mt,Dt,Lt],R),jt=v(["mi","mo","mn","ms","mtext"]);let Ut=q({},jt);const Gt=v(["annotation-xml"]);let Ht=q({},Gt);const qt=q({},["title","style","font","a","script"]);let Qt=null;const zt=["application/xhtml+xml","text/html"],Kt="text/html";let Wt=null,Xt=null;const Yt=n.createElement("form"),Zt=function(e){return e instanceof RegExp||e instanceof Function},Jt=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(Xt&&Xt===e)return;e&&"object"===typeof e||(e={}),e=z(e),Qt=-1===zt.indexOf(e.PARSER_MEDIA_TYPE)?Kt:e.PARSER_MEDIA_TYPE,Wt="application/xhtml+xml"===Qt?R:T,et=Te(e,"ALLOWED_TAGS",tt,{transform:Wt}),nt=Te(e,"ALLOWED_ATTR",rt,{transform:Wt}),Vt=Te(e,"ALLOWED_NAMESPACES",Ft,{transform:R}),Pt=Te(e,"ADD_URI_SAFE_ATTR",It,{transform:Wt,base:It}),Rt=Te(e,"ADD_DATA_URI_TAGS",Nt,{transform:Wt,base:Nt}),At=Te(e,"FORBID_CONTENTS",Tt,{transform:Wt}),ot=Te(e,"FORBID_TAGS",z({}),{transform:Wt}),at=Te(e,"FORBID_ATTR",z({}),{transform:Wt}),Ct=!!V(e,"USE_PROFILES")&&(e.USE_PROFILES&&"object"===typeof e.USE_PROFILES?z(e.USE_PROFILES):e.USE_PROFILES),lt=!1!==e.ALLOW_ARIA_ATTR,ct=!1!==e.ALLOW_DATA_ATTR,ut=e.ALLOW_UNKNOWN_PROTOCOLS||!1,dt=!1!==e.ALLOW_SELF_CLOSE_IN_ATTR,ht=e.SAFE_FOR_TEMPLATES||!1,pt=!1!==e.SAFE_FOR_XML,ft=e.WHOLE_DOCUMENT||!1,yt=e.RETURN_DOM||!1,wt=e.RETURN_DOM_FRAGMENT||!1,Ot=e.RETURN_TRUSTED_TYPE||!1,bt=e.FORCE_BODY||!1,St=!1!==e.SANITIZE_DOM,Et=e.SANITIZE_NAMED_PROPS||!1,_t=!1!==e.KEEP_CONTENT,kt=e.IN_PLACE||!1,Je=X(e.ALLOWED_URI_REGEXP)?e.ALLOWED_URI_REGEXP:pe,Bt="string"===typeof e.NAMESPACE?e.NAMESPACE:Lt,Ut=Re(e,"MATHML_TEXT_INTEGRATION_POINTS",()=>q({},jt)),Ht=Re(e,"HTML_INTEGRATION_POINTS",()=>q({},Gt));const t=Re(e,"CUSTOM_ELEMENT_HANDLING",()=>y(null));if(it=y(null),V(t,"tagNameCheck")&&Zt(t.tagNameCheck)&&(it.tagNameCheck=t.tagNameCheck),V(t,"attributeNameCheck")&&Zt(t.attributeNameCheck)&&(it.attributeNameCheck=t.attributeNameCheck),V(t,"allowCustomizedBuiltInElements")&&"boolean"===typeof t.allowCustomizedBuiltInElements&&(it.allowCustomizedBuiltInElements=t.allowCustomizedBuiltInElements),b(it),ht&&(ct=!1),wt&&(yt=!0),Ct&&(et=q({},re),nt=y(null),!0===Ct.html&&(q(et,Y),q(nt,ie)),!0===Ct.svg&&(q(et,Z),q(nt,oe),q(nt,se)),!0===Ct.svgFilters&&(q(et,J),q(nt,oe),q(nt,se)),!0===Ct.mathMl&&(q(et,te),q(nt,ae),q(nt,se))),st.tagCheck=null,st.attributeCheck=null,V(e,"ADD_TAGS")&&("function"===typeof e.ADD_TAGS?st.tagCheck=e.ADD_TAGS:A(e.ADD_TAGS)&&(et===tt&&(et=z(et)),q(et,e.ADD_TAGS,Wt))),V(e,"ADD_ATTR")&&("function"===typeof e.ADD_ATTR?st.attributeCheck=e.ADD_ATTR:A(e.ADD_ATTR)&&(nt===rt&&(nt=z(nt)),q(nt,e.ADD_ATTR,Wt))),V(e,"ADD_FORBID_CONTENTS")&&A(e.ADD_FORBID_CONTENTS)&&(At===Tt&&(At=z(At)),q(At,e.ADD_FORBID_CONTENTS,Wt)),_t&&(et["#text"]=!0),ft&&q(et,["html","head","body"]),et.table&&(q(et,["tbody"]),delete ot.tbody),e.TRUSTED_TYPES_POLICY){if("function"!==typeof e.TRUSTED_TYPES_POLICY.createHTML)throw U('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if("function"!==typeof e.TRUSTED_TYPES_POLICY.createScriptURL)throw U('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');const t=H;H=e.TRUSTED_TYPES_POLICY;try{Ee=De("")}catch(n){throw H=t,n}}else null===e.TRUSTED_TYPES_POLICY?(H=void 0,Ee=""):(void 0===H&&(H=Be()),H&&"string"===typeof Ee&&(Ee=De("")));v&&v(e),Xt=e},en=q({},[...Z,...J,...ee]),tn=q({},[...te,...ne]),nn=function(e,t,n){return t.namespaceURI===Lt?"svg"===e:t.namespaceURI===Mt?"svg"===e&&("annotation-xml"===n||Ut[n]):Boolean(en[e])},rn=function(e,t,n){return t.namespaceURI===Lt?"math"===e:t.namespaceURI===Dt?"math"===e&&Ht[n]:Boolean(tn[e])},on=function(e,t,n){return!(t.namespaceURI===Dt&&!Ht[n])&&(!(t.namespaceURI===Mt&&!Ut[n])&&(!tn[e]&&(qt[e]||!en[e])))},an=function(e){let t=O(e);t&&t.tagName||(t={namespaceURI:Bt,tagName:"template"});const n=T(e.tagName),r=T(t.tagName);return!!Vt[e.namespaceURI]&&(e.namespaceURI===Dt?nn(n,t,r):e.namespaceURI===Mt?rn(n,t,r):e.namespaceURI===Lt?on(n,t,r):!("application/xhtml+xml"!==Qt||!Vt[e.namespaceURI]))},sn=function(e){k(t.removed,{element:e});try{O(e).removeChild(e)}catch(n){if(f(e),!O(e))throw U("a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place")}},ln=function(e,t,n){try{m(e,t)}catch(r){try{e.removeAttribute(n)}catch(r){}}},cn=function(e){hn(e);const t=w(e);if(t){const e=[];E(t,t=>{k(e,t)}),E(e,e=>{try{f(e)}catch(t){}})}const n=D(e);if(n)for(let r=n.length-1;r>=0;--r){const t=n[r],i=t&&t.name;"string"===typeof i&&ln(e,t,i)}},un=function(e,n,r){if(!r)try{r=n.getAttributeNode(e)}catch(i){r=null}k(t.removed,{attribute:r||null,from:n});try{r?m(n,r):n.removeAttribute(e)}catch(i){try{n.removeAttribute(e)}catch(i){}}if("is"===e)if(yt||wt)try{sn(n)}catch(i){}else try{n.setAttribute(e,"")}catch(i){}},dn=function(e){const t=D(e);if(t)for(let n=t.length-1;n>=0;--n){const r=t[n],i=r&&r.name;"string"!==typeof i||nt[Wt(i)]||ln(e,r,i)}},hn=function(e){const t=[e];while(t.length>0){const e=t.pop();F(e)===Se.element&&dn(e);const n=w(e);if(n)for(let r=n.length-1;r>=0;--r)t.push(n[r])}},pn=function(e,t){return!!pt&&("patchsrc"===e||"for"===e&&"label"!==t&&"output"!==t)},fn=function(e){if(!pt)return;const t=[e];while(t.length>0){const e=t.pop(),r=F(e);if(r===Se.processingInstruction||r===Se.comment&&j(ye,e.data)){try{f(e)}catch(n){}continue}if(r===Se.element){const t=e,r=Wt(G(e));try{t.hasAttribute&&t.hasAttribute("patchsrc")&&t.removeAttribute("patchsrc"),t.hasAttribute&&t.hasAttribute("for")&&pn("for",r)&&t.removeAttribute("for")}catch(n){}}const i=w(e);if(i)for(let n=i.length-1;n>=0;--n)t.push(i[n])}},mn=function(e){let t=null,r=null;if(bt)e="<remove></remove>"+e;else{const t=N(e,/^[\r\n\t ]+/);r=t&&t[0]}"application/xhtml+xml"===Qt&&Bt===Lt&&(e='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+e+"</body></html>");const i=H?De(e):e;if(Bt===Lt)try{t=(new c).parseFromString(i,Qt)}catch(a){}if(!t||!t.documentElement){t=Ve.createDocument(Bt,"template",null);try{t.documentElement.innerHTML=$t?Ee:i}catch(a){}}const o=t.body||t.documentElement;return e&&r&&o.insertBefore(n.createTextNode(r),o.childNodes[0]||null),Bt===Lt?Ue.call(t,ft?"html":"body")[0]:ft?t.documentElement:o},gn=function(e){const t=$?$(e):e.ownerDocument;return Fe.call(t||e,e,l.SHOW_ELEMENT|l.SHOW_COMMENT|l.SHOW_TEXT|l.SHOW_PROCESSING_INSTRUCTION|l.SHOW_CDATA_SECTION,null)},vn=function(e){return e=P(e,qe," "),e=P(e,Qe," "),e=P(e,ze," "),e},bn=function(e){var t;e.normalize();const n=$?$(e):e.ownerDocument,r=Fe.call(n||e,e,l.SHOW_TEXT|l.SHOW_COMMENT|l.SHOW_CDATA_SECTION|l.SHOW_PROCESSING_INSTRUCTION,null);let i=r.nextNode();while(i)i.data=vn(i.data),i=r.nextNode();const o=null===(t=e.querySelectorAll)||void 0===t?void 0:t.call(e,"template");o&&E(o,e=>{wn(e.content)&&bn(e.content)})},yn=function(e){const t=B?B(e):null;return"string"===typeof t&&("form"===Wt(t)&&("string"!==typeof e.nodeName||"string"!==typeof e.textContent||"function"!==typeof e.removeChild||e.attributes!==D(e)||"function"!==typeof e.removeAttribute||"function"!==typeof e.removeAttributeNode||"function"!==typeof e.getAttributeNode||"function"!==typeof e.setAttribute||"string"!==typeof e.namespaceURI||"function"!==typeof e.insertBefore||"function"!==typeof e.hasChildNodes||e.nodeType!==L(e)||e.childNodes!==w(e)))},wn=function(e){if(!L||"object"!==typeof e||null===e)return!1;try{return L(e)===Se.documentFragment}catch(t){return!1}},On=function(e){if(!L||"object"!==typeof e||null===e)return!1;try{return"number"===typeof L(e)}catch(t){return!1}};function Sn(e,n,r){0!==e.length&&E(e,e=>{e.call(t,n,r,Xt)})}const En=function(e,t){return!!(pt&&e.hasChildNodes()&&!On(e.firstElementChild)&&j(be,e.textContent)&&j(be,e.innerHTML))||(!!(pt&&e.namespaceURI===Lt&&xe[t]&&(On(e.firstElementChild)||"string"===typeof e.textContent&&j(_e[t],e.textContent)))||(e.nodeType===Se.processingInstruction||!(!pt||e.nodeType!==Se.comment||!j(ye,e.data))))},xn=function(e,t){if(e instanceof RegExp)return j(e,t);if(e instanceof Function){for(var n=arguments.length,r=new Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];return Boolean(e(t,...r))}return!1},_n=function(e,t,n){if(!ot[t]&&Nn(t)&&xn(it.tagNameCheck,t))return!1;if(_t&&!At[t]){const t=O(e),r=w(e);if(r&&t){const i=r.length;for(let o=i-1;o>=0;--o){const i=e===n?p(r[o],!0):r[o];t.insertBefore(i,g(e))}}}return sn(e),!0},kn=function(e,t,n,r){return 0===e.length?t:t===n||t===r?z(t):t},Cn=function(e,t){return e!==t&&null===O(e)&&(kt&&hn(e),!0)},An=function(e,n){if(Sn(He.beforeSanitizeElements,e,null),Cn(e,n))return!0;if(yn(e))return sn(e),!0;const r=Wt(G(e));if(et=kn(He.uponSanitizeElement,et,tt,gt),Sn(He.uponSanitizeElement,e,{tagName:r,allowedTags:et}),Cn(e,n))return!0;if(En(e,r))return sn(e),!0;if(ot[r]||!(st.tagCheck instanceof Function&&st.tagCheck(r))&&!et[r]){const t=_n(e,r,n);return!(!1!==t||(Sn(He.afterSanitizeElements,e,null),!Cn(e,n)))||t}if(F(e)===Se.element&&!an(e))return sn(e),!0;if(("noscript"===r||"noembed"===r||"noframes"===r)&&j(we,e.innerHTML))return sn(e),!0;if(ht&&e.nodeType===Se.text){const n=vn(e.textContent);e.textContent!==n&&(k(t.removed,{element:e.cloneNode()}),e.textContent=n)}return Sn(He.afterSanitizeElements,e,null),Cn(e,n)},Tn=function(e,t,r){if(at[t])return!1;if(pn(t,e))return!1;if(St&&("id"===t||"name"===t)&&(r in n||r in Yt))return!1;const i=nt[t]||st.attributeCheck instanceof Function&&st.attributeCheck(t,e);return!(!ct||!j(Ke,t))||(!(!lt||!j(We,t))||(i?!!Pt[t]||(!!j(Je,P(r,Ye,""))||(!("src"!==t&&"xlink:href"!==t&&"href"!==t||"script"===e||0!==I(r,"data:")||!Rt[e])||(!(!ut||j(Xe,P(r,Ye,"")))||!r))):Nn(e)&&xn(it.tagNameCheck,e)&&xn(it.attributeNameCheck,t,e)||"is"===t&&it.allowCustomizedBuiltInElements&&xn(it.tagNameCheck,r)))},Rn=q({},["annotation-xml","color-profile","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","missing-glyph"]),Nn=function(e){return!Rn[T(e)]&&j(Ze,e)},Pn=function(e,t,n,r){if(H&&"object"===typeof u&&"function"===typeof u.getAttributeType&&!n)switch(u.getAttributeType(e,t)){case"TrustedHTML":return De(r);case"TrustedScriptURL":return Le(r)}return r},In=function(e,t,n,r){try{return n?e.setAttributeNS(n,t,r):e.setAttribute(t,r),!yn(e)||(sn(e),!1)}catch(i){return un(t,e),!1}},Mn=function(e,n){if(Sn(He.beforeSanitizeAttributes,e,null),Cn(e,n))return;const r=e.attributes;if(!r||yn(e))return;nt=kn(He.uponSanitizeAttribute,nt,rt,vt);const i={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:nt,forceKeepAttr:void 0};let o=r.length;const a=Wt(e.nodeName);while(o--){const n=r[o],s=n.name,l=n.namespaceURI,c=n.value,u=Wt(s),d=c;let h="value"===s?d:M(d),p=!1;i.attrName=u,i.attrValue=h,i.keepAttr=!0,i.forceKeepAttr=void 0,Sn(He.uponSanitizeAttribute,e,i),h=i.attrValue,!Et||"id"!==u&&"name"!==u||0===I(h,xt)||(un(s,e,n),h=xt+h,p=!0),pt&&j(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,h)?un(s,e,n):"attributename"===u&&N(h,"href")?un(s,e,n):i.forceKeepAttr||(i.keepAttr&&(dt||!j(Oe,h))?(ht&&(h=vn(h)),Tn(a,u,h)?(h=Pn(a,u,l,h),h!==d&&In(e,s,l,h)&&p&&_(t.removed)):un(s,e,n)):un(s,e,n))}Sn(He.afterSanitizeAttributes,e,null),Cn(e,n)},Dn=function(e){let t=null;const n=gn(e);Sn(He.beforeSanitizeShadowDOM,e,null);while(t=n.nextNode())if(Sn(He.uponSanitizeShadowNode,t,null),An(t,e),Mn(t,e),wn(t.content)&&Dn(t.content),F(t)===Se.element){const e=S(t);wn(e)&&(Ln(e),Dn(e))}Sn(He.afterSanitizeShadowDOM,e,null)},Ln=function(e){const t=[{node:e,shadow:null}];while(t.length>0){const e=t.pop();if(e.shadow){Dn(e.shadow);continue}const n=e.node,r=F(n)===Se.element,i=w(n);if(i)for(let o=i.length-1;o>=0;--o)t.push({node:i[o],shadow:null});if(r){const e=B?B(n):null;if("string"===typeof e&&"template"===Wt(e)){const e=n.content;wn(e)&&t.push({node:e,shadow:null})}}if(r){const e=S(n);wn(e)&&t.push({node:null,shadow:e},{node:e,shadow:null})}}};return t.sanitize=function(e){let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=null,o=null,a=null,s=null;if($t=!e,$t&&(e="\x3c!--\x3e"),"string"!==typeof e&&!On(e)&&(e=K(e),"string"!==typeof e))throw U("dirty is not a string, aborting");if(!t.isSupported)return e;mt?(et=gt,nt=vt):Jt(n),(He.uponSanitizeElement.length>0||He.uponSanitizeAttribute.length>0)&&(et=z(et)),He.uponSanitizeAttribute.length>0&&(nt=z(nt)),t.removed=[];const l=kt&&"string"!==typeof e&&On(e);if(l){fn(e);const t=G(e);if("string"===typeof t){const n=Wt(t);if(!et[n]||ot[n])throw cn(e),U("root node is forbidden and cannot be sanitized in-place")}if(yn(e))throw cn(e),U("root node is clobbered and cannot be sanitized in-place");try{Ln(e)}catch(d){throw cn(e),d}}else if(On(e))i=mn("\x3c!----\x3e"),o=i.ownerDocument.importNode(e,!0),o.nodeType===Se.element&&"BODY"===o.nodeName||"HTML"===o.nodeName?i=o:i.appendChild(o),Ln(i);else{if(!yt&&!ht&&!ft&&-1===e.indexOf("<"))return H&&Ot?De(e):e;if(i=mn(e),!i)return yt?null:Ot?Ee:""}i&&bt&&sn(i.firstChild);const c=l?e:i;try{const e=gn(c);while(a=e.nextNode())An(a,c),Mn(a,c),wn(a.content)&&Dn(a.content)}catch(d){throw l&&(cn(e),E(t.removed,e=>{e.element&&hn(e.element)})),d}if(l){let n=!1;if(E(t.removed,t=>{t.element&&(t.element===e&&(n=!0),hn(t.element))}),n)throw U("a node selected for removal could not be safely returned; refusing to sanitize in place");return ht&&bn(e),e}if(yt){if(ht&&bn(i),wt){s=je.call(i.ownerDocument);while(i.firstChild)s.appendChild(i.firstChild)}else s=i;return(nt.shadowroot||nt.shadowrootmode)&&(s=Ge.call(r,s,!0)),s}let u=ft?i.outerHTML:i.innerHTML;return ft&&et["!doctype"]&&i.ownerDocument&&i.ownerDocument.doctype&&i.ownerDocument.doctype.name&&j(ge,i.ownerDocument.doctype.name)&&(u="<!DOCTYPE "+i.ownerDocument.doctype.name+">\n"+u),ht&&(u=vn(u)),H&&Ot?De(u):u},t.setConfig=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};Jt(e),mt=!0,gt=et,vt=nt},t.clearConfig=function(){Xt=null,mt=!1,gt=null,vt=null,H=Q,Ee=""},t.isValidAttribute=function(e,t,n){Xt||Jt({});const r=Wt(e),i=Wt(t);return Tn(r,i,n)},t.addHook=function(e,t){"function"===typeof t&&V(He,e)&&k(He[e],t)},t.removeHook=function(e,t){if(V(He,e)){if(void 0!==t){const n=x(He[e],t);return-1===n?void 0:C(He[e],n,1)[0]}return _(He[e])}},t.removeHooks=function(e){V(He,e)&&(He[e]=[])},t.removeAllHooks=function(){He=Ae()},t}var Pe=Ne()},98104:function(e,t,n){"use strict";n.d(t,{G:function(){return s}});const r="ͼ",i="undefined"==typeof Symbol?"__"+r:Symbol.for(r),o="undefined"==typeof Symbol?"__styleSet"+Math.floor(1e8*Math.random()):Symbol("styleSet"),a="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:{};class s{constructor(e,t){this.rules=[];let{finish:n}=t||{};function r(e){return/^@/.test(e)?[e]:e.split(/,\s*/)}function i(e,t,o,a){let s=[],l=/^@(\w+)\b/.exec(e[0]),c=l&&"keyframes"==l[1];if(l&&null==t)return o.push(e[0]+";");for(let n in t){let a=t[n];if(/&/.test(n))i(n.split(/,\s*/).map(t=>e.map(e=>t.replace(/&/,e))).reduce((e,t)=>e.concat(t)),a,o);else if(a&&"object"==typeof a){if(!l)throw new RangeError("The value of a property ("+n+") should be a primitive value.");i(r(n),a,s,c)}else null!=a&&s.push(n.replace(/_.*/,"").replace(/[A-Z]/g,e=>"-"+e.toLowerCase())+": "+a+";")}(s.length||c)&&o.push((!n||l||a?e:e.map(n)).join(", ")+" {"+s.join(" ")+"}")}for(let o in e)i(r(o),e[o],this.rules)}getRules(){return this.rules.join("\n")}static newName(){let e=a[i]||1;return a[i]=e+1,r+e.toString(36)}static mount(e,t,n){let r=e[o],i=n&&n.nonce;r?i&&r.setNonce(i):r=new c(e,i),r.mount(Array.isArray(t)?t:[t],e)}}let l=new Map;class c{constructor(e,t){let n=e.ownerDocument||e,r=n.defaultView;if(!e.head&&e.adoptedStyleSheets&&r.CSSStyleSheet){let t=l.get(n);if(t)return e[o]=t;this.sheet=new r.CSSStyleSheet,l.set(n,this)}else this.styleTag=n.createElement("style"),t&&this.styleTag.setAttribute("nonce",t);this.modules=[],e[o]=this}mount(e,t){let n=this.sheet,r=0,i=0,o=!1;for(let a=0;a<e.length;a++){let t=e[a],s=this.modules.indexOf(t);if(s<i&&s>-1&&(this.modules.splice(s,1),o=!0,i--,s=-1),-1==s){if(this.modules.splice(i++,0,t),o=!0,n)for(let e=0;e<t.rules.length;e++)n.insertRule(t.rules[e],r++)}else{while(i<s)r+=this.modules[i++].rules.length;r+=t.rules.length,i++}}if(n)t.adoptedStyleSheets.indexOf(this.sheet)<0&&(t.adoptedStyleSheets=[this.sheet,...t.adoptedStyleSheets]);else{if(o){let e="";for(let t=0;t<this.modules.length;t++)e+=this.modules[t].getRules()+"\n";this.styleTag.textContent=e}let e=t.head||t;this.styleTag.parentNode!=e&&e.insertBefore(this.styleTag,e.firstChild)}}setNonce(e){this.styleTag&&this.styleTag.getAttribute("nonce")!=e&&this.styleTag.setAttribute("nonce",e)}}},53197:function(e,t,n){"use strict";n.d(t,{Mt:function(){return Ie},mN:function(){return qe}});var r=n(9274);
|
||
/**
|
||
* vee-validate v4.15.1
|
||
* (c) 2025 Abdelrahman Awad
|
||
* @license MIT
|
||
*/function i(e){return"function"===typeof e}function o(e){return null===e||void 0===e}const a=e=>null!==e&&!!e&&"object"===typeof e&&!Array.isArray(e);function s(e){return Number(e)>=0}function l(e){const t=parseFloat(e);return isNaN(t)?e:t}function c(e){return"object"===typeof e&&null!==e}function u(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":Object.prototype.toString.call(e)}function d(e){if(!c(e)||"[object Object]"!==u(e))return!1;if(null===Object.getPrototypeOf(e))return!0;let t=e;while(null!==Object.getPrototypeOf(t))t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}function h(e,t){return Object.keys(t).forEach(n=>{if(d(t[n])&&d(e[n]))return e[n]||(e[n]={}),void h(e[n],t[n]);e[n]=t[n]}),e}function p(e){const t=e.split(".");if(!t.length)return"";let n=String(t[0]);for(let r=1;r<t.length;r++)s(t[r])?n+=`[${t[r]}]`:n+=`.${t[r]}`;return n}const f={};function m(e){return f[e]}function g(e,t,n){"object"===typeof n.value&&(n.value=v(n.value)),n.enumerable&&!n.get&&!n.set&&n.configurable&&n.writable&&"__proto__"!==t?e[t]=n.value:Object.defineProperty(e,t,n)}function v(e){if("object"!==typeof e)return e;var t,n,r,i=0,o=Object.prototype.toString.call(e);if("[object Object]"===o?r=Object.create(e.__proto__||null):"[object Array]"===o?r=Array(e.length):"[object Set]"===o?(r=new Set,e.forEach(function(e){r.add(v(e))})):"[object Map]"===o?(r=new Map,e.forEach(function(e,t){r.set(v(t),v(e))})):"[object Date]"===o?r=new Date(+e):"[object RegExp]"===o?r=new RegExp(e.source,e.flags):"[object DataView]"===o?r=new e.constructor(v(e.buffer)):"[object ArrayBuffer]"===o?r=e.slice(0):"Array]"===o.slice(-6)&&(r=new e.constructor(e)),r){for(n=Object.getOwnPropertySymbols(e);i<n.length;i++)g(r,n[i],Object.getOwnPropertyDescriptor(e,n[i]));for(i=0,n=Object.getOwnPropertyNames(e);i<n.length;i++)Object.hasOwnProperty.call(r,t=n[i])&&r[t]===e[t]||g(r,t,Object.getOwnPropertyDescriptor(e,t))}return r||e}const b=Symbol("vee-validate-form"),y=Symbol("vee-validate-form-context"),w=Symbol("vee-validate-field-instance"),O=Symbol("Default empty value"),S="undefined"!==typeof window;function E(e){return i(e)&&!!e.__locatorRef}function x(e){return!!e&&i(e.parse)&&"VVTypedSchema"===e.__type}function _(e){return!!e&&i(e.validate)}function k(e){return"checkbox"===e||"radio"===e}function C(e){return a(e)||Array.isArray(e)}function A(e){return Array.isArray(e)?0===e.length:a(e)&&0===Object.keys(e).length}function T(e){return/^\[.+\]$/i.test(e)}function R(e){return N(e)&&e.multiple}function N(e){return"SELECT"===e.tagName}function P(e,t){const n=![!1,null,void 0,0].includes(t.multiple)&&!Number.isNaN(t.multiple);return"select"===e&&"multiple"in t&&n}function I(e,t){return!P(e,t)&&"file"!==t.type&&!k(t.type)}function M(e){return D(e)&&e.target&&"submit"in e.target}function D(e){return!!e&&(!!("undefined"!==typeof Event&&i(Event)&&e instanceof Event)||!(!e||!e.srcElement))}function L(e,t){return t in e&&e[t]!==O}function B(e,t){if(e===t)return!0;if(e&&t&&"object"===typeof e&&"object"===typeof t){if(e.constructor!==t.constructor)return!1;var n,r,i;if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(r=n;0!==r--;)if(!B(e[r],t[r]))return!1;return!0}if(e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(r of e.entries())if(!t.has(r[0]))return!1;for(r of e.entries())if(!B(r[1],t.get(r[0])))return!1;return!0}if(V(e)&&V(t))return e.size===t.size&&(e.name===t.name&&(e.lastModified===t.lastModified&&e.type===t.type));if(e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(r of e.entries())if(!t.has(r[0]))return!1;return!0}if(ArrayBuffer.isView(e)&&ArrayBuffer.isView(t)){if(n=e.length,n!=t.length)return!1;for(r=n;0!==r--;)if(e[r]!==t[r])return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===t.toString();if(e=$(e),t=$(t),i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;0!==r--;)if(!Object.prototype.hasOwnProperty.call(t,i[r]))return!1;for(r=n;0!==r--;){var o=i[r];if(!B(e[o],t[o]))return!1}return!0}return e!==e&&t!==t}function $(e){return Object.fromEntries(Object.entries(e).filter(([,e])=>void 0!==e))}function V(e){return!!S&&e instanceof File}function F(e){return T(e)?e.replace(/\[|\]/gi,""):e}function j(e,t,n){if(!e)return n;if(T(t))return e[F(t)];const r=(t||"").split(/\.|\[(\d+)\]/).filter(Boolean).reduce((e,t)=>C(e)&&t in e?e[t]:n,e);return r}function U(e,t,n){if(T(t))return void(e[F(t)]=n);const r=t.split(/\.|\[(\d+)\]/).filter(Boolean);let i=e;for(let a=0;a<r.length;a++){if(a===r.length-1)return void(i[r[a]]=n);r[a]in i&&!o(i[r[a]])||(i[r[a]]=s(r[a+1])?[]:{}),i=i[r[a]]}}function G(e,t){Array.isArray(e)&&s(t)?e.splice(Number(t),1):a(e)&&delete e[t]}function H(e,t){if(T(t))return void delete e[F(t)];const n=t.split(/\.|\[(\d+)\]/).filter(Boolean);let r=e;for(let a=0;a<n.length;a++){if(a===n.length-1){G(r,n[a]);break}if(!(n[a]in r)||o(r[n[a]]))break;r=r[n[a]]}const i=n.map((t,r)=>j(e,n.slice(0,r).join(".")));for(let o=i.length-1;o>=0;o--)A(i[o])&&(0!==o?G(i[o-1],n[o-1]):G(e,n[0]))}function q(e){return Object.keys(e)}function Q(e,t=void 0){const n=(0,r.getCurrentInstance)();return(null===n||void 0===n?void 0:n.provides[e])||(0,r.inject)(e,t)}function z(e,t,n){if(Array.isArray(e)){const n=[...e],r=n.findIndex(e=>B(e,t));return r>=0?n.splice(r,1):n.push(t),n}return B(e,t)?n:t}function K(e,t){let n,r;return function(...i){const o=this;return n||(n=!0,setTimeout(()=>n=!1,t),r=e.apply(o,i)),r}}function W(e,t=0){let n=null,r=[];return function(...i){return n&&clearTimeout(n),n=setTimeout(()=>{const t=e(...i);r.forEach(e=>e(t)),r=[]},t),new Promise(e=>r.push(e))}}function X(e,t){return a(t)&&t.number?l(e):e}function Y(e,t){let n;return async function(...r){const i=e(...r);n=i;const o=await i;return i!==n?o:(n=void 0,t(o,r))}}function Z(e){return Array.isArray(e)?e:e?[e]:[]}function J(e,t){const n={};for(const r in e)t.includes(r)||(n[r]=e[r]);return n}function ee(e){let t=null,n=[];return function(...i){const o=(0,r.nextTick)(()=>{if(t!==o)return;const r=e(...i);n.forEach(e=>e(r)),n=[],t=null});return t=o,new Promise(e=>n.push(e))}}function te(e,t,n){return t.slots.default?"string"!==typeof e&&e?{default:()=>{var e,r;return null===t.slots.default||void 0===r?void 0:r.call(e,n())}}:t.slots.default(n()):t.slots.default}function ne(e){if(re(e))return e._value}function re(e){return"_value"in e}function ie(e){return"number"===e.type||"range"===e.type?Number.isNaN(e.valueAsNumber)?e.value:e.valueAsNumber:e.value}function oe(e){if(!D(e))return e;const t=e.target;if(k(t.type)&&re(t))return ne(t);if("file"===t.type&&t.files){const e=Array.from(t.files);return t.multiple?e:e[0]}if(R(t))return Array.from(t.options).filter(e=>e.selected&&!e.disabled).map(ne);if(N(t)){const e=Array.from(t.options).find(e=>e.selected);return e?ne(e):t.value}return ie(t)}function ae(e){const t={};return Object.defineProperty(t,"_$$isNormalized",{value:!0,writable:!1,enumerable:!1,configurable:!1}),e?a(e)&&e._$$isNormalized?e:a(e)?Object.keys(e).reduce((t,n)=>{const r=se(e[n]);return!1!==e[n]&&(t[n]=le(r)),t},t):"string"!==typeof e?t:e.split("|").reduce((e,t)=>{const n=ce(t);return n.name?(e[n.name]=le(n.params),e):e},t):t}function se(e){return!0===e?[]:Array.isArray(e)||a(e)?e:[e]}function le(e){const t=e=>"string"===typeof e&&"@"===e[0]?ue(e.slice(1)):e;return Array.isArray(e)?e.map(t):e instanceof RegExp?[e]:Object.keys(e).reduce((n,r)=>(n[r]=t(e[r]),n),{})}const ce=e=>{let t=[];const n=e.split(":")[0];return e.includes(":")&&(t=e.split(":").slice(1).join(":").split(",")),{name:n,params:t}};function ue(e){const t=t=>{var n;const r=null!==(n=j(t,e))&&void 0!==n?n:t[e];return r};return t.__locatorRef=e,t}function de(e){return Array.isArray(e)?e.filter(E):q(e).filter(t=>E(e[t])).map(t=>e[t])}const he={generateMessage:({field:e})=>`${e} is not valid.`,bails:!0,validateOnBlur:!0,validateOnChange:!0,validateOnInput:!1,validateOnModelUpdate:!0};let pe=Object.assign({},he);const fe=()=>pe;async function me(e,t,n={}){const r=null===n||void 0===n?void 0:n.bails,i={name:(null===n||void 0===n?void 0:n.name)||"{field}",rules:t,label:null===n||void 0===n?void 0:n.label,bails:null===r||void 0===r||r,formData:(null===n||void 0===n?void 0:n.values)||{}},o=await ge(i,e);return Object.assign(Object.assign({},o),{valid:!o.errors.length})}async function ge(e,t){const n=e.rules;if(x(n)||_(n))return ye(t,Object.assign(Object.assign({},e),{rules:n}));if(i(n)||Array.isArray(n)){const r={field:e.label||e.name,name:e.name,label:e.label,form:e.formData,value:t},i=Array.isArray(n)?n:[n],o=i.length,a=[];for(let n=0;n<o;n++){const o=i[n],s=await o(t,r),l="string"!==typeof s&&!Array.isArray(s)&&s;if(!l){if(Array.isArray(s))a.push(...s);else{const e="string"===typeof s?s:Oe(r);a.push(e)}if(e.bails)return{errors:a}}}return{errors:a}}const r=Object.assign(Object.assign({},e),{rules:ae(n)}),o=[],a=Object.keys(r.rules),s=a.length;for(let i=0;i<s;i++){const n=a[i],s=await we(r,t,{name:n,params:r.rules[n]});if(s.error&&(o.push(s.error),e.bails))return{errors:o}}return{errors:o}}function ve(e){return!!e&&"ValidationError"===e.name}function be(e){const t={__type:"VVTypedSchema",async parse(t,n){var r;try{const r=await e.validate(t,{abortEarly:!1,context:(null===n||void 0===n?void 0:n.formData)||{}});return{output:r,errors:[]}}catch(i){if(!ve(i))throw i;if(!(null===(r=i.inner)||void 0===r?void 0:r.length)&&i.errors.length)return{errors:[{path:i.path,errors:i.errors}]};const e=i.inner.reduce((e,t)=>{const n=t.path||"";return e[n]||(e[n]={errors:[],path:n}),e[n].errors.push(...t.errors),e},{});return{errors:Object.values(e)}}}};return t}async function ye(e,t){const n=x(t.rules)?t.rules:be(t.rules),r=await n.parse(e,{formData:t.formData}),i=[];for(const o of r.errors)o.errors.length&&i.push(...o.errors);return{value:r.value,errors:i}}async function we(e,t,n){const r=m(n.name);if(!r)throw new Error(`No such validator '${n.name}' exists.`);const i=Se(n.params,e.formData),o={field:e.label||e.name,name:e.name,label:e.label,value:t,form:e.formData,rule:Object.assign(Object.assign({},n),{params:i})},a=await r(t,i,o);return"string"===typeof a?{error:a}:{error:a?void 0:Oe(o)}}function Oe(e){const t=fe().generateMessage;return t?t(e):"Field is invalid"}function Se(e,t){const n=e=>E(e)?e(t):e;return Array.isArray(e)?e.map(n):Object.keys(e).reduce((t,r)=>(t[r]=n(e[r]),t),{})}async function Ee(e,t){const n=x(e)?e:be(e),r=await n.parse(v(t),{formData:v(t)}),i={},o={};for(const a of r.errors){const e=a.errors,t=(a.path||"").replace(/\["(\d+)"\]/g,(e,t)=>`[${t}]`);i[t]={valid:!e.length,errors:e},e.length&&(o[t]=e[0])}return{valid:!r.errors.length,results:i,errors:o,values:r.value,source:"schema"}}async function xe(e,t,n){const r=q(e),i=r.map(async r=>{var i,o,a;const s=null===(i=null===n||void 0===n?void 0:n.names)||void 0===i?void 0:i[r],l=await me(j(t,r),e[r],{name:(null===s||void 0===s?void 0:s.name)||r,label:null===s||void 0===s?void 0:s.label,values:t,bails:null===(a=null===(o=null===n||void 0===n?void 0:n.bailsMap)||void 0===o?void 0:o[r])||void 0===a||a});return Object.assign(Object.assign({},l),{path:r})});let o=!0;const a=await Promise.all(i),s={},l={};for(const c of a)s[c.path]={valid:c.valid,errors:c.errors},c.valid||(o=!1,l[c.path]=c.errors[0]);return{valid:o,results:s,errors:l,source:"schema"}}let _e=0;function ke(e,t){const{value:n,initialValue:i,setInitialValue:o}=Ce(e,t.modelValue,t.form);if(!t.form){const{errors:c,setErrors:u}=Re(),d=_e>=Number.MAX_SAFE_INTEGER?0:++_e,h=Te(n,i,c,t.schema);function p(e){var t;"value"in e&&(n.value=e.value),"errors"in e&&u(e.errors),"touched"in e&&(h.touched=null!==(t=e.touched)&&void 0!==t?t:h.touched),"initialValue"in e&&o(e.initialValue)}return{id:d,path:e,value:n,initialValue:i,meta:h,flags:{pendingUnmount:{[d]:!1},pendingReset:!1},errors:c,setState:p}}const a=t.form.createPathState(e,{bails:t.bails,label:t.label,type:t.type,validate:t.validate,schema:t.schema}),s=(0,r.computed)(()=>a.errors);function l(i){var a,s,l;"value"in i&&(n.value=i.value),"errors"in i&&(null===(a=t.form)||void 0===a||a.setFieldError((0,r.unref)(e),i.errors)),"touched"in i&&(null===(s=t.form)||void 0===s||s.setFieldTouched((0,r.unref)(e),null!==(l=i.touched)&&void 0!==l&&l)),"initialValue"in i&&o(i.initialValue)}return{id:Array.isArray(a.id)?a.id[a.id.length-1]:a.id,path:e,value:n,errors:s,meta:a,initialValue:i,flags:a.__flags,setState:l}}function Ce(e,t,n){const i=(0,r.ref)((0,r.unref)(t));function o(){return n?j(n.initialValues.value,(0,r.unref)(e),(0,r.unref)(i)):(0,r.unref)(i)}function a(t){n?n.setFieldInitialValue((0,r.unref)(e),t,!0):i.value=t}const s=(0,r.computed)(o);if(!n){const e=(0,r.ref)(o());return{value:e,initialValue:s,setInitialValue:a}}const l=Ae(t,n,s,e);n.stageInitialValue((0,r.unref)(e),l,!0);const c=(0,r.computed)({get(){return j(n.values,(0,r.unref)(e))},set(t){n.setFieldValue((0,r.unref)(e),t,!1)}});return{value:c,initialValue:s,setInitialValue:a}}function Ae(e,t,n,i){return(0,r.isRef)(e)?(0,r.unref)(e):void 0!==e?e:j(t.values,(0,r.unref)(i),(0,r.unref)(n))}function Te(e,t,n,i){const o=(0,r.computed)(()=>{var e,t,n;return null!==(n=null===(t=null===(e=(0,r.toValue)(i))||void 0===e?void 0:e.describe)||void 0===t?void 0:t.call(e).required)&&void 0!==n&&n}),a=(0,r.reactive)({touched:!1,pending:!1,valid:!0,required:o,validated:!!(0,r.unref)(n).length,initialValue:(0,r.computed)(()=>(0,r.unref)(t)),dirty:(0,r.computed)(()=>!B((0,r.unref)(e),(0,r.unref)(t)))});return(0,r.watch)(n,e=>{a.valid=!e.length},{immediate:!0,flush:"sync"}),a}function Re(){const e=(0,r.ref)([]);return{errors:e,setErrors:t=>{e.value=Z(t)}}}const Ne="vee-validate-inspector";let Pe;K(()=>{setTimeout(async()=>{await(0,r.nextTick)(),null===Pe||void 0===Pe||Pe.sendInspectorState(Ne),null===Pe||void 0===Pe||Pe.sendInspectorTree(Ne)},100)},100);function Ie(e,t,n){return k(null===n||void 0===n?void 0:n.type)?Le(e,t,n):Me(e,t,n)}function Me(e,t,n){const{initialValue:o,validateOnMount:a,bails:s,type:l,checkedValue:c,label:u,validateOnValueUpdate:d,uncheckedValue:h,controlled:f,keepValueOnUnmount:m,syncVModel:g,form:y}=De(n),O=f?Q(b):void 0,S=y||O,E=(0,r.computed)(()=>p((0,r.toValue)(e))),k=(0,r.computed)(()=>{const e=(0,r.toValue)(null===S||void 0===S?void 0:S.schema);if(e)return;const n=(0,r.unref)(t);return _(n)||x(n)||i(n)||Array.isArray(n)?n:ae(n)}),C=!i(k.value)&&x((0,r.toValue)(t)),{id:A,value:T,initialValue:R,meta:N,setState:P,errors:I,flags:M}=ke(E,{modelValue:o,form:S,bails:s,label:u,type:l,validate:k.value?U:void 0,schema:C?t:void 0}),D=(0,r.computed)(()=>I.value[0]);g&&Be({value:T,prop:g,handleChange:G,shouldValidate:()=>d&&!M.pendingReset});const L=(e,t=!1)=>{N.touched=!0,t&&V()};async function $(e){var t,n;if(null===S||void 0===S?void 0:S.validateSchema){const{results:n}=await S.validateSchema(e);return null!==(t=n[(0,r.toValue)(E)])&&void 0!==t?t:{valid:!0,errors:[]}}return k.value?me(T.value,k.value,{name:(0,r.toValue)(E),label:(0,r.toValue)(u),values:null!==(n=null===S||void 0===S?void 0:S.values)&&void 0!==n?n:{},bails:s}):{valid:!0,errors:[]}}const V=Y(async()=>(N.pending=!0,N.validated=!0,$("validated-only")),e=>(M.pendingUnmount[J.id]||(P({errors:e.errors}),N.pending=!1,N.valid=e.valid),e)),F=Y(async()=>$("silent"),e=>(N.valid=e.valid,e));function U(e){return"silent"===(null===e||void 0===e?void 0:e.mode)?F():V()}function G(e,t=!0){const n=oe(e);K(n,t)}function H(e){N.touched=e}function q(e){var t;const n=e&&"value"in e?e.value:R.value;P({value:v(n),initialValue:v(n),touched:null!==(t=null===e||void 0===e?void 0:e.touched)&&void 0!==t&&t,errors:(null===e||void 0===e?void 0:e.errors)||[]}),N.pending=!1,N.validated=!1,F()}(0,r.onMounted)(()=>{if(a)return V();S&&S.validateSchema||F()});const z=(0,r.getCurrentInstance)();function K(e,t=!0){T.value=z&&g?X(e,z.props.modelModifiers):e;const n=t?V:F;n()}function W(e){P({errors:Array.isArray(e)?e:[e]})}const Z=(0,r.computed)({get(){return T.value},set(e){K(e,d)}}),J={id:A,name:E,label:u,value:Z,meta:N,errors:I,errorMessage:D,type:l,checkedValue:c,uncheckedValue:h,bails:s,keepValueOnUnmount:m,resetField:q,handleReset:()=>q(),validate:U,handleChange:G,handleBlur:L,setState:P,setTouched:H,setErrors:W,setValue:K};if((0,r.provide)(w,J),(0,r.isRef)(t)&&"function"!==typeof(0,r.unref)(t)&&(0,r.watch)(t,(e,t)=>{B(e,t)||(N.validated?V():F())},{deep:!0}),!S)return J;const ee=(0,r.computed)(()=>{const e=k.value;return!e||i(e)||_(e)||x(e)||Array.isArray(e)?{}:Object.keys(e).reduce((t,n)=>{const r=de(e[n]).map(e=>e.__locatorRef).reduce((e,t)=>{const n=j(S.values,t)||S.values[t];return void 0!==n&&(e[t]=n),e},{});return Object.assign(t,r),t},{})});return(0,r.watch)(ee,(e,t)=>{if(!Object.keys(e).length)return;const n=!B(e,t);n&&(N.validated?V():F())}),(0,r.onBeforeUnmount)(()=>{var e;const t=null!==(e=(0,r.toValue)(J.keepValueOnUnmount))&&void 0!==e?e:(0,r.toValue)(S.keepValuesOnUnmount),n=(0,r.toValue)(E);if(t||!S||M.pendingUnmount[J.id])return void(null===S||void 0===S||S.removePathState(n,A));M.pendingUnmount[J.id]=!0;const i=S.getPathState(n),o=Array.isArray(null===i||void 0===i?void 0:i.id)&&(null===i||void 0===i?void 0:i.multiple)?null===i||void 0===i?void 0:i.id.includes(J.id):(null===i||void 0===i?void 0:i.id)===J.id;if(o){if((null===i||void 0===i?void 0:i.multiple)&&Array.isArray(i.value)){const e=i.value.findIndex(e=>B(e,(0,r.toValue)(J.checkedValue)));if(e>-1){const t=[...i.value];t.splice(e,1),S.setFieldValue(n,t)}Array.isArray(i.id)&&i.id.splice(i.id.indexOf(J.id),1)}else S.unsetPathValue((0,r.toValue)(E));S.removePathState(n,A)}}),J}function De(e){const t=()=>({initialValue:void 0,validateOnMount:!1,bails:!0,label:void 0,validateOnValueUpdate:!0,keepValueOnUnmount:void 0,syncVModel:!1,controlled:!0}),n=!!(null===e||void 0===e?void 0:e.syncVModel),i="string"===typeof(null===e||void 0===e?void 0:e.syncVModel)?e.syncVModel:(null===e||void 0===e?void 0:e.modelPropName)||"modelValue",o=n&&!("initialValue"in(e||{}))?$e((0,r.getCurrentInstance)(),i):null===e||void 0===e?void 0:e.initialValue;if(!e)return Object.assign(Object.assign({},t()),{initialValue:o});const a="valueProp"in e?e.valueProp:e.checkedValue,s="standalone"in e?!e.standalone:e.controlled,l=(null===e||void 0===e?void 0:e.modelPropName)||(null===e||void 0===e?void 0:e.syncVModel)||!1;return Object.assign(Object.assign(Object.assign({},t()),e||{}),{initialValue:o,controlled:null===s||void 0===s||s,checkedValue:a,syncVModel:l})}function Le(e,t,n){const i=(null===n||void 0===n?void 0:n.standalone)?void 0:Q(b),o=null===n||void 0===n?void 0:n.checkedValue,a=null===n||void 0===n?void 0:n.uncheckedValue;function s(t){const s=t.handleChange,l=(0,r.computed)(()=>{const e=(0,r.toValue)(t.value),n=(0,r.toValue)(o);return Array.isArray(e)?e.findIndex(e=>B(e,n))>=0:B(n,e)});function c(c,u=!0){var d,h;if(l.value===(null===(d=null===c||void 0===c?void 0:c.target)||void 0===d?void 0:d.checked))return void(u&&t.validate());const p=(0,r.toValue)(e),f=null===i||void 0===i?void 0:i.getPathState(p),m=oe(c);let g=null!==(h=(0,r.toValue)(o))&&void 0!==h?h:m;i&&(null===f||void 0===f?void 0:f.multiple)&&"checkbox"===f.type?g=z(j(i.values,p)||[],g,void 0):"checkbox"===(null===n||void 0===n?void 0:n.type)&&(g=z((0,r.toValue)(t.value),g,(0,r.toValue)(a))),s(g,u)}return Object.assign(Object.assign({},t),{checked:l,checkedValue:o,uncheckedValue:a,handleChange:c})}return s(Me(e,t,n))}function Be({prop:e,value:t,handleChange:n,shouldValidate:i}){const o=(0,r.getCurrentInstance)();if(!o||!e)return void 0;const a="string"===typeof e?e:"modelValue",s=`update:${a}`;a in o.props&&((0,r.watch)(t,e=>{B(e,$e(o,a))||o.emit(s,e)}),(0,r.watch)(()=>$e(o,a),e=>{if(e===O&&void 0===t.value)return;const r=e===O?void 0:e;B(r,t.value)||n(r,i())}))}function $e(e,t){if(e)return e.props[t]}Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean,Boolean;function Ve(e,t){let n=e.as||"";return e.as||t.slots.default||"input",n}function Fe(e){var t,n,r,i;const{validateOnInput:o,validateOnChange:a,validateOnBlur:s,validateOnModelUpdate:l}=fe();return{validateOnInput:null!==e.validateOnInput&&void 0!==t?t:o,validateOnChange:null!==e.validateOnChange&&void 0!==n?n:a,validateOnBlur:null!==e.validateOnBlur&&void 0!==r?r:s,validateOnModelUpdate:null!==e.validateOnModelUpdate&&void 0!==i?i:l}}function je(e,t){return k(t.attrs.type)?L(e,"modelValue")?e.modelValue:void 0:L(e,"modelValue")?e.modelValue:t.attrs.value}let Ue=0;const Ge=["bails","fieldsCount","id","multiple","type","validate"];function He(e){const t=(null===e||void 0===e?void 0:e.initialValues)||{},n=Object.assign({},(0,r.toValue)(t)),o=(0,r.unref)(null===e||void 0===e?void 0:e.validationSchema);return o&&x(o)&&i(o.cast)?v(o.cast(n)||{}):v(n)}function qe(e){var t;const n=Ue++,o=(null===e||void 0===e?void 0:e.name)||"Form";let a=0;const s=(0,r.ref)(!1),l=(0,r.ref)(!1),c=(0,r.ref)(0),u=[],d=(0,r.reactive)(He(e)),f=(0,r.ref)([]),m=(0,r.ref)({}),g=(0,r.ref)({}),w=ee(()=>{g.value=f.value.reduce((e,t)=>(e[p((0,r.toValue)(t.path))]=t,e),{})});function O(e,t){const n=K(e);if(n){if("string"===typeof e){const t=p(e);m.value[t]&&delete m.value[t]}n.errors=Z(t),n.valid=!n.errors.length}else"string"===typeof e&&(m.value[p(e)]=Z(t))}function S(e){q(e).forEach(t=>{O(t,e[t])})}(null===e||void 0===e?void 0:e.initialErrors)&&S(e.initialErrors);const E=(0,r.computed)(()=>{const e=f.value.reduce((e,t)=>(t.errors.length&&(e[(0,r.toValue)(t.path)]=t.errors),e),{});return Object.assign(Object.assign({},m.value),e)}),k=(0,r.computed)(()=>q(E.value).reduce((e,t)=>{const n=E.value[t];return(null===n||void 0===n?void 0:n.length)&&(e[t]=n[0]),e},{})),C=(0,r.computed)(()=>f.value.reduce((e,t)=>(e[(0,r.toValue)(t.path)]={name:(0,r.toValue)(t.path)||"",label:t.label||""},e),{})),A=(0,r.computed)(()=>f.value.reduce((e,t)=>{var n;return e[(0,r.toValue)(t.path)]=null===(n=t.bails)||void 0===n||n,e},{})),T=Object.assign({},(null===e||void 0===e?void 0:e.initialErrors)||{}),R=null!==(t=null===e||void 0===e?void 0:e.keepValuesOnUnmount)&&void 0!==t&&t,{initialValues:N,originalInitialValues:P,setInitialValues:I}=ze(f,d,e),D=Qe(f,d,P,k),L=(0,r.computed)(()=>f.value.reduce((e,t)=>{const n=j(d,(0,r.toValue)(t.path));return U(e,(0,r.toValue)(t.path),n),e},{})),$=null===e||void 0===e?void 0:e.validationSchema;function V(e,t){var n,i;const o=(0,r.computed)(()=>j(N.value,(0,r.toValue)(e))),s=g.value[(0,r.toValue)(e)],l="checkbox"===(null===t||void 0===t?void 0:t.type)||"radio"===(null===t||void 0===t?void 0:t.type);if(s&&l){s.multiple=!0;const e=a++;return Array.isArray(s.id)?s.id.push(e):s.id=[s.id,e],s.fieldsCount++,s.__flags.pendingUnmount[e]=!1,s}const c=(0,r.computed)(()=>j(d,(0,r.toValue)(e))),u=(0,r.toValue)(e),h=ne.findIndex(e=>e===u);-1!==h&&ne.splice(h,1);const p=(0,r.computed)(()=>{var n,i,o,a;const s=(0,r.toValue)($);if(x(s))return null!==(i=null===(n=s.describe)||void 0===n?void 0:n.call(s,(0,r.toValue)(e)).required)&&void 0!==i&&i;const l=(0,r.toValue)(null===t||void 0===t?void 0:t.schema);return!!x(l)&&(null!==(a=null===(o=l.describe)||void 0===o?void 0:o.call(l).required)&&void 0!==a&&a)}),m=a++,b=(0,r.reactive)({id:m,path:e,touched:!1,pending:!1,valid:!0,validated:!!(null===(n=T[u])||void 0===n?void 0:n.length),required:p,initialValue:o,errors:(0,r.shallowRef)([]),bails:null!==(i=null===t||void 0===t?void 0:t.bails)&&void 0!==i&&i,label:null===t||void 0===t?void 0:t.label,type:(null===t||void 0===t?void 0:t.type)||"default",value:c,multiple:!1,__flags:{pendingUnmount:{[m]:!1},pendingReset:!1},fieldsCount:1,validate:null===t||void 0===t?void 0:t.validate,dirty:(0,r.computed)(()=>!B((0,r.unref)(c),(0,r.unref)(o)))});return f.value.push(b),g.value[u]=b,w(),k.value[u]&&!T[u]&&(0,r.nextTick)(()=>{ke(u,{mode:"silent"})}),(0,r.isRef)(e)&&(0,r.watch)(e,e=>{w();const t=v(c.value);g.value[e]=b,(0,r.nextTick)(()=>{U(d,e,t)})}),b}const F=W(Re,5),G=W(Re,5),Q=Y(async e=>await("silent"===e?F():G()),(e,[t])=>{const n=q(ue.errorBag.value),i=[...new Set([...q(e.results),...f.value.map(e=>e.path),...n])].sort(),o=i.reduce((n,i)=>{var o;const a=i,s=K(a)||X(a),l=(null===(o=e.results[a])||void 0===o?void 0:o.errors)||[],c=(0,r.toValue)(null===s||void 0===s?void 0:s.path)||a,u=Ke({errors:l,valid:!l.length},n.results[c]);return n.results[c]=u,u.valid||(n.errors[c]=u.errors[0]),s&&m.value[c]&&delete m.value[c],s?(s.valid=u.valid,"silent"===t?n:"validated-only"!==t||s.validated?(O(s,u.errors),n):n):(O(c,l),n)},{valid:e.valid,results:{},errors:{},source:e.source});return e.values&&(o.values=e.values,o.source=e.source),q(o.results).forEach(e=>{var n;const r=K(e);r&&"silent"!==t&&("validated-only"!==t||r.validated)&&O(r,null===(n=o.results[e])||void 0===n?void 0:n.errors)}),o});function z(e){f.value.forEach(e)}function K(e){const t="string"===typeof e?p(e):e,n="string"===typeof t?g.value[t]:t;return n}function X(e){const t=f.value.filter(t=>e.startsWith((0,r.toValue)(t.path)));return t.reduce((e,t)=>e?t.path.length>e.path.length?t:e:t,void 0)}let te,ne=[];function re(e){return ne.push(e),te||(te=(0,r.nextTick)(()=>{const e=[...ne].sort().reverse();e.forEach(e=>{H(d,e)}),ne=[],te=null})),te}function ie(e){return function(t,n){return function(r){return r instanceof Event&&(r.preventDefault(),r.stopPropagation()),z(e=>e.touched=!0),s.value=!0,c.value++,_e().then(i=>{const o=v(d);if(i.valid&&"function"===typeof t){const n=v(L.value);let a=e?n:o;return i.values&&(a="schema"===i.source?i.values:Object.assign({},a,i.values)),t(a,{evt:r,controlledValues:n,setErrors:S,setFieldError:O,setTouched:we,setFieldTouched:ge,setValues:pe,setFieldValue:de,resetForm:Se,resetField:Oe})}i.valid||"function"!==typeof n||n({values:o,evt:r,errors:i.errors,results:i.results})}).then(e=>(s.value=!1,e),e=>{throw s.value=!1,e})}}}const ae=ie(!1),se=ae;function le(e,t){const n=f.value.findIndex(n=>n.path===e&&(Array.isArray(n.id)?n.id.includes(t):n.id===t)),i=f.value[n];if(-1!==n&&i){if((0,r.nextTick)(()=>{ke(e,{mode:"silent",warn:!1})}),i.multiple&&i.fieldsCount&&i.fieldsCount--,Array.isArray(i.id)){const e=i.id.indexOf(t);e>=0&&i.id.splice(e,1),delete i.__flags.pendingUnmount[t]}(!i.multiple||i.fieldsCount<=0)&&(f.value.splice(n,1),Ce(e),w(),delete g.value[e])}}function ce(e){q(g.value).forEach(t=>{t.startsWith(e)&&delete g.value[t]}),f.value=f.value.filter(t=>!t.path.startsWith(e)),(0,r.nextTick)(()=>{w()})}se.withControlled=ie(!0);const ue={name:o,formId:n,values:d,controlledValues:L,errorBag:E,errors:k,schema:$,submitCount:c,meta:D,isSubmitting:s,isValidating:l,fieldArrays:u,keepValuesOnUnmount:R,validateSchema:(0,r.unref)($)?Q:void 0,validate:_e,setFieldError:O,validateField:ke,setFieldValue:de,setValues:pe,setErrors:S,setFieldTouched:ge,setTouched:we,resetForm:Se,resetField:Oe,handleSubmit:se,useFieldModel:Ie,defineInputBinds:Me,defineComponentBinds:De,defineField:Pe,stageInitialValue:Ae,unsetInitialValue:Ce,setFieldInitialValue:Te,createPathState:V,getPathState:K,unsetPathValue:re,removePathState:le,initialValues:N,getAllPathStates:()=>f.value,destroyPath:ce,isFieldTouched:ve,isFieldDirty:be,isFieldValid:ye};function de(e,t,n=!0){const r=v(t),i="string"===typeof e?e:e.path,o=K(i);o||V(i),U(d,i,r),n&&ke(i)}function he(e,t=!0){q(d).forEach(e=>{delete d[e]}),q(e).forEach(t=>{de(t,e[t],!1)}),t&&_e()}function pe(e,t=!0){h(d,e),u.forEach(e=>e&&e.reset()),t&&_e()}function me(e,t){const n=K((0,r.toValue)(e))||V(e);return(0,r.computed)({get(){return n.value},set(n){var i;const o=(0,r.toValue)(e);de(o,n,null!==(i=(0,r.toValue)(t))&&void 0!==i&&i)}})}function ge(e,t){const n=K(e);n&&(n.touched=t)}function ve(e){const t=K(e);return t?t.touched:f.value.filter(t=>t.path.startsWith(e)).some(e=>e.touched)}function be(e){const t=K(e);return t?t.dirty:f.value.filter(t=>t.path.startsWith(e)).some(e=>e.dirty)}function ye(e){const t=K(e);return t?t.valid:f.value.filter(t=>t.path.startsWith(e)).every(e=>e.valid)}function we(e){"boolean"!==typeof e?q(e).forEach(t=>{ge(t,!!e[t])}):z(t=>{t.touched=e})}function Oe(e,t){var n;const i=t&&"value"in t?t.value:j(N.value,e),o=K(e);o&&(o.__flags.pendingReset=!0),Te(e,v(i),!0),de(e,i,!1),ge(e,null!==(n=null===t||void 0===t?void 0:t.touched)&&void 0!==n&&n),O(e,(null===t||void 0===t?void 0:t.errors)||[]),(0,r.nextTick)(()=>{o&&(o.__flags.pendingReset=!1)})}function Se(e,t){let n=v((null===e||void 0===e?void 0:e.values)?e.values:P.value);n=(null===t||void 0===t?void 0:t.force)?n:h(P.value,n),n=x($)&&i($.cast)?$.cast(n):n,I(n,{force:null===t||void 0===t?void 0:t.force}),z(t=>{var i;t.__flags.pendingReset=!0,t.validated=!1,t.touched=(null===(i=null===e||void 0===e?void 0:e.touched)||void 0===i?void 0:i[(0,r.toValue)(t.path)])||!1,de((0,r.toValue)(t.path),j(n,(0,r.toValue)(t.path)),!1),O((0,r.toValue)(t.path),void 0)}),(null===t||void 0===t?void 0:t.force)?he(n,!1):pe(n,!1),S((null===e||void 0===e?void 0:e.errors)||{}),c.value=(null===e||void 0===e?void 0:e.submitCount)||0,(0,r.nextTick)(()=>{_e({mode:"silent"}),z(e=>{e.__flags.pendingReset=!1})})}async function _e(e){const t=(null===e||void 0===e?void 0:e.mode)||"force";if("force"===t&&z(e=>e.validated=!0),ue.validateSchema)return ue.validateSchema(t);l.value=!0;const n=await Promise.all(f.value.map(t=>t.validate?t.validate(e).then(e=>({key:(0,r.toValue)(t.path),valid:e.valid,errors:e.errors,value:e.value})):Promise.resolve({key:(0,r.toValue)(t.path),valid:!0,errors:[],value:void 0})));l.value=!1;const i={},o={},a={};for(const r of n)i[r.key]={valid:r.valid,errors:r.errors},r.value&&U(a,r.key,r.value),r.errors.length&&(o[r.key]=r.errors[0]);return{valid:n.every(e=>e.valid),results:i,errors:o,values:a,source:"fields"}}async function ke(e,t){var n;const r=K(e);if(r&&"silent"!==(null===t||void 0===t?void 0:t.mode)&&(r.validated=!0),$){const{results:n}=await Q((null===t||void 0===t?void 0:t.mode)||"validated-only");return n[e]||{errors:[],valid:!0}}if(null===r||void 0===r?void 0:r.validate)return r.validate(t);!r&&(n=null===t||void 0===t?void 0:t.warn);return Promise.resolve({errors:[],valid:!0})}function Ce(e){H(N.value,e)}function Ae(t,n,r=!1){Te(t,n),U(d,t,n),r&&!(null===e||void 0===e?void 0:e.initialValues)&&U(P.value,t,v(n))}function Te(e,t,n=!1){U(N.value,e,v(t)),n&&U(P.value,e,v(t))}async function Re(){const e=(0,r.unref)($);if(!e)return{valid:!0,results:{},errors:{},source:"none"};l.value=!0;const t=_(e)||x(e)?await Ee(e,d):await xe(e,d,{names:C.value,bailsMap:A.value});return l.value=!1,t}const Ne=se((e,{evt:t})=>{M(t)&&t.target.submit()});function Pe(e,t){const n=i(t)||null===t||void 0===t?void 0:t.label,o=K((0,r.toValue)(e))||V(e,{label:n}),a=()=>i(t)?t(J(o,Ge)):t||{};function s(){var e;o.touched=!0;const t=null!==(e=a().validateOnBlur)&&void 0!==e?e:fe().validateOnBlur;t&&ke((0,r.toValue)(o.path))}function l(){var e;const t=null!==(e=a().validateOnInput)&&void 0!==e?e:fe().validateOnInput;t&&(0,r.nextTick)(()=>{ke((0,r.toValue)(o.path))})}function c(){var e;const t=null!==(e=a().validateOnChange)&&void 0!==e?e:fe().validateOnChange;t&&(0,r.nextTick)(()=>{ke((0,r.toValue)(o.path))})}const u=(0,r.computed)(()=>{const e={onChange:c,onInput:l,onBlur:s};return i(t)?Object.assign(Object.assign({},e),t(J(o,Ge)).props||{}):(null===t||void 0===t?void 0:t.props)?Object.assign(Object.assign({},e),t.props(J(o,Ge))):e}),d=me(e,()=>{var e,t,n;return null===(n=null!==(e=a().validateOnModelUpdate)&&void 0!==e?e:null===(t=fe())||void 0===t?void 0:t.validateOnModelUpdate)||void 0===n||n});return[d,u]}function Ie(e){return Array.isArray(e)?e.map(e=>me(e,!0)):me(e)}function Me(e,t){const[n,i]=Pe(e,t);function o(){i.value.onBlur()}function a(t){const n=oe(t);de((0,r.toValue)(e),n,!1),i.value.onInput()}function s(t){const n=oe(t);de((0,r.toValue)(e),n,!1),i.value.onChange()}return(0,r.computed)(()=>Object.assign(Object.assign({},i.value),{onBlur:o,onInput:a,onChange:s,value:n.value}))}function De(e,t){const[n,o]=Pe(e,t),a=K((0,r.toValue)(e));function s(e){n.value=e}return(0,r.computed)(()=>{const e=i(t)?t(J(a,Ge)):t||{};return Object.assign({[e.model||"modelValue"]:n.value,[`onUpdate:${e.model||"modelValue"}`]:s},o.value)})}(0,r.onMounted)(()=>{(null===e||void 0===e?void 0:e.initialErrors)&&S(e.initialErrors),(null===e||void 0===e?void 0:e.initialTouched)&&we(e.initialTouched),(null===e||void 0===e?void 0:e.validateOnMount)?_e():ue.validateSchema&&ue.validateSchema("silent")}),(0,r.isRef)($)&&(0,r.watch)($,()=>{var e;null===(e=ue.validateSchema)||void 0===e||e.call(ue,"validated-only")}),(0,r.provide)(b,ue);const Le=Object.assign(Object.assign({},ue),{values:(0,r.readonly)(d),handleReset:()=>Se(),submitForm:Ne});return(0,r.provide)(y,Le),Le}function Qe(e,t,n,i){const o={touched:"some",pending:"some",valid:"every"},a=(0,r.computed)(()=>!B(t,(0,r.unref)(n)));function s(){const t=e.value;return q(o).reduce((e,n)=>{const r=o[n];return e[n]=t[r](e=>e[n]),e},{})}const l=(0,r.reactive)(s());return(0,r.watchEffect)(()=>{const e=s();l.touched=e.touched,l.valid=e.valid,l.pending=e.pending}),(0,r.computed)(()=>Object.assign(Object.assign({initialValues:(0,r.unref)(n)},l),{valid:l.valid&&!q(i.value).length,dirty:a.value}))}function ze(e,t,n){const i=He(n),o=(0,r.ref)(i),a=(0,r.ref)(v(i));function s(n,i){(null===i||void 0===i?void 0:i.force)?(o.value=v(n),a.value=v(n)):(o.value=h(v(o.value)||{},v(n)),a.value=h(v(a.value)||{},v(n))),(null===i||void 0===i?void 0:i.updateFields)&&e.value.forEach(e=>{const n=e.touched;if(n)return;const i=j(o.value,(0,r.toValue)(e.path));U(t,(0,r.toValue)(e.path),v(i))})}return{initialValues:o,originalInitialValues:a,setInitialValues:s}}function Ke(e,t){return t?{valid:e.valid&&t.valid,errors:[...e.errors,...t.errors]}:e}Boolean,Boolean},8330:function(e){"use strict";e.exports=JSON.parse('{"name":"harvester","description":"Rancher UI Extension for Harvester","version":"1.10.0-dev","private":false,"rancher":{"annotations":{"catalog.cattle.io/display-name":"Harvester","catalog.cattle.io/kube-version":">= 1.16.0-0","catalog.cattle.io/rancher-version":">= 2.15.0-0","catalog.cattle.io/ui-extensions-version":">= 3.0.0 < 4.0.0"}},"icon":"https://raw.githubusercontent.com/harvester/harvester-ui-extension/main/pkg/harvester/icon.svg","scripts":{"dev":"./node_modules/.bin/nuxt dev","nuxt":"./node_modules/.bin/nuxt"},"engines":{"node":">=24.0.0"},"devDependencies":{"@vue/cli-plugin-babel":"~5.0.9","@vue/cli-service":"~5.0.9","@vue/cli-plugin-typescript":"~5.0.9"},"browserslist":["> 1%","last 2 versions","not dead"]}')}},i={};function o(e){var t=i[e];if(void 0!==t)return t.exports;var n=i[e]={id:e,loaded:!1,exports:{}};return r[e].call(n.exports,n,n.exports,o),n.loaded=!0,n.exports}o.m=r,function(){var e="function"===typeof Symbol,t=e?Symbol("webpack queues"):"__webpack_queues__",n=e?Symbol("webpack exports"):"__webpack_exports__",r=e?Symbol("webpack error"):"__webpack_error__",i=function(e){e&&e.d<1&&(e.d=1,e.forEach(function(e){e.r--}),e.forEach(function(e){e.r--?e.r++:e()}))},a=function(e){return e.map(function(e){if(null!==e&&"object"===typeof e){if(e[t])return e;if(e.then){var o=[];o.d=0,e.then(function(e){a[n]=e,i(o)},function(e){a[r]=e,i(o)});var a={};return a[t]=function(e){e(o)},a}}var s={};return s[t]=function(){},s[n]=e,s})};o.a=function(e,o,s){var l;s&&((l=[]).d=-1);var c,u,d,h=new Set,p=e.exports,f=new Promise(function(e,t){d=t,u=e});f[n]=p,f[t]=function(e){l&&e(l),h.forEach(e),f["catch"](function(){})},e.exports=f;var m=function(e){var i;c=a(e);var o=function(){return c.map(function(e){if(e[r])throw e[r];return e[n]})},s=new Promise(function(e){i=function(){e(o)},i.r=0;var n=function(e){e!==l&&!h.has(e)&&(h.add(e),e&&!e.d&&(i.r++,e.push(i)))};c.map(function(e){e[t](n)})});return i.r?s:o()},g=function(e){e?d(f[r]=e):u(p),i(l)};o(m,g),l&&l.d<0&&(l.d=0)}}(),function(){o.n=function(e){var t=e&&e.__esModule?function(){return e["default"]}:function(){return e};return o.d(t,{a:t}),t}}(),function(){var e,t=Object.getPrototypeOf?function(e){return Object.getPrototypeOf(e)}:function(e){return e.__proto__};o.t=function(n,r){if(1&r&&(n=this(n)),8&r)return n;if("object"===typeof n&&n){if(4&r&&n.__esModule)return n;if(16&r&&"function"===typeof n.then)return n}var i=Object.create(null);o.r(i);var a={};e=e||[null,t({}),t([]),t(t)];for(var s=2&r&&n;("object"==typeof s||"function"==typeof s)&&!~e.indexOf(s);s=t(s))Object.getOwnPropertyNames(s).forEach(function(e){a[e]=function(){return n[e]}});return a["default"]=function(){return n},o.d(i,a),i}}(),function(){o.d=function(e,t){for(var n in t)o.o(t,n)&&!o.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})}}(),function(){o.f={},o.e=function(e){return Promise.all(Object.keys(o.f).reduce(function(t,n){return o.f[n](e,t),t},[]))}}(),function(){o.u=function(e){return"harvester-1.10.0-dev.umd.min."+({332:"detail",461:"xccdf",715:"list",739:"edit",829:"csv",902:"formatters",907:"dialog",935:"xterm",973:"promptRemove"}[e]||e)+".js"}}(),function(){o.g=function(){if("object"===typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"===typeof window)return window}}()}(),function(){o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)}}(),function(){var e={},t="harvester-1.10.0-dev:";o.l=function(n,r,i,a){if(e[n])e[n].push(r);else{var s,l;if(void 0!==i)for(var c=document.getElementsByTagName("script"),u=0;u<c.length;u++){var d=c[u];if(d.getAttribute("src")==n||d.getAttribute("data-webpack")==t+i){s=d;break}}s||(l=!0,s=document.createElement("script"),s.charset="utf-8",o.nc&&s.setAttribute("nonce",o.nc),s.setAttribute("data-webpack",t+i),s.src=n),e[n]=[r];var h=function(t,r){s.onerror=s.onload=null,clearTimeout(p);var i=e[n];if(delete e[n],s.parentNode&&s.parentNode.removeChild(s),i&&i.forEach(function(e){return e(r)}),t)return t(r)},p=setTimeout(h.bind(null,void 0,{type:"timeout",target:s}),12e4);s.onerror=h.bind(null,s.onerror),s.onload=h.bind(null,s.onload),l&&document.head.appendChild(s)}}}(),function(){o.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}}(),function(){o.nmd=function(e){return e.paths=[],e.children||(e.children=[]),e}}(),function(){o.p=""}(),function(){var e={316:0};o.f.j=function(t,n){var r=o.o(e,t)?e[t]:void 0;if(0!==r)if(r)n.push(r[2]);else{var i=new Promise(function(n,i){r=e[t]=[n,i]});n.push(r[2]=i);var a=o.p+o.u(t),s=new Error,l=function(n){if(o.o(e,t)&&(r=e[t],0!==r&&(e[t]=void 0),r)){var i=n&&("load"===n.type?"missing":n.type),a=n&&n.target&&n.target.src;s.message="Loading chunk "+t+" failed.\n("+i+": "+a+")",s.name="ChunkLoadError",s.type=i,s.request=a,r[1](s)}};o.l(a,l,"chunk-"+t,t)}};var t=function(t,n){var r,i,a=n[0],s=n[1],l=n[2],c=0;if(a.some(function(t){return 0!==e[t]})){for(r in s)o.o(s,r)&&(o.m[r]=s[r]);if(l)l(o)}for(t&&t(n);c<a.length;c++)i=a[c],o.o(e,i)&&e[i]&&e[i][0](),e[i]=0},n=("undefined"!==typeof self?self:this)["webpackChunkharvester_1_10_0_dev"]=("undefined"!==typeof self?self:this)["webpackChunkharvester_1_10_0_dev"]||[];n.forEach(t.bind(null,0)),n.push=t.bind(null,n.push.bind(n))}();var a={};return function(){"use strict";if(o.r(a),o.d(a,{default:function(){return jh}}),"undefined"!==typeof window){var e=window.document.currentScript,t=e&&e.src.match(/(.+\/)[^/]+\.js(\?.*)?$/);t&&(o.p=t[1])}function n(e){if("undefined"!==typeof document){var t=function(){var e=document.getElementById("app"),t=e&&e.__vue_app__;if(!t||!t.config||!t.config.globalProperties)return!1;var n=t.config.globalProperties;!n.$extension&&n.$plugin?n.$extension=n.$plugin:!n.$plugin&&n.$extension&&(n.$plugin=n.$extension);var r=n.$store&&n.$store.state;if(!r)return!1;var i=null;return r.$extension&&r.$extension.getPlugins?i=r.$extension:r.$plugin&&r.$plugin.getPlugins&&(i=r.$plugin),!!i&&(r.$extension=i,r.$plugin=i,!0)};if(!t()){var n=setInterval(function(){t()&&clearInterval(n)},100);setTimeout(function(){clearInterval(n)},1e4)}}e.register("detail","devices.harvesterhci.io.migconfiguration",()=>Promise.all([o.e(123),o.e(654),o.e(895),o.e(625),o.e(431),o.e(6),o.e(483),o.e(341),o.e(332)]).then(o.bind(o,33094))),e.register("detail","harvesterhci.io.host",()=>Promise.all([o.e(123),o.e(654),o.e(895),o.e(625),o.e(431),o.e(6),o.e(483),o.e(341),o.e(332)]).then(o.bind(o,44472))),e.register("detail","harvesterhci.io.management.cluster",()=>Promise.all([o.e(123),o.e(654),o.e(895),o.e(625),o.e(431),o.e(6),o.e(483),o.e(341),o.e(332)]).then(o.bind(o,45713))),e.register("detail","harvesterhci.io.schedulevmbackup",()=>Promise.all([o.e(123),o.e(654),o.e(895),o.e(625),o.e(431),o.e(6),o.e(483),o.e(341),o.e(332)]).then(o.bind(o,49096))),e.register("detail","harvesterhci.io.secret",()=>Promise.all([o.e(123),o.e(654),o.e(895),o.e(625),o.e(431),o.e(6),o.e(483),o.e(341),o.e(332)]).then(o.bind(o,84735))),e.register("detail","harvesterhci.io.virtualmachinebackup",()=>Promise.all([o.e(123),o.e(654),o.e(895),o.e(625),o.e(431),o.e(6),o.e(483),o.e(341),o.e(332)]).then(o.bind(o,98075))),e.register("detail","harvesterhci.io.virtualmachineimage",()=>Promise.all([o.e(123),o.e(654),o.e(895),o.e(625),o.e(431),o.e(6),o.e(483),o.e(341),o.e(332)]).then(o.bind(o,94411))),e.register("detail","harvesterhci.io.vmsnapshot",()=>Promise.all([o.e(123),o.e(654),o.e(895),o.e(625),o.e(431),o.e(6),o.e(483),o.e(341),o.e(332)]).then(o.bind(o,19115))),e.register("detail","kubeovn.io.vpc",()=>Promise.all([o.e(123),o.e(654),o.e(895),o.e(625),o.e(431),o.e(6),o.e(483),o.e(341),o.e(332)]).then(o.bind(o,49574))),e.register("detail","kubevirt.io.virtualmachine",()=>Promise.all([o.e(123),o.e(654),o.e(895),o.e(625),o.e(431),o.e(6),o.e(483),o.e(341),o.e(332)]).then(o.bind(o,36545))),e.register("detail","loadbalancer.harvesterhci.io.ippool",()=>Promise.all([o.e(123),o.e(654),o.e(895),o.e(625),o.e(431),o.e(6),o.e(483),o.e(341),o.e(332)]).then(o.bind(o,67973))),e.register("detail","loadbalancer.harvesterhci.io.loadbalancer",()=>Promise.all([o.e(123),o.e(654),o.e(895),o.e(625),o.e(431),o.e(6),o.e(483),o.e(341),o.e(332)]).then(o.bind(o,55224))),e.register("detail","network.harvesterhci.io.vlanconfig",()=>Promise.all([o.e(123),o.e(654),o.e(895),o.e(625),o.e(431),o.e(6),o.e(483),o.e(341),o.e(332)]).then(o.bind(o,27626))),e.register("edit","devices.harvesterhci.io.migconfiguration",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,18324))),e.register("edit","forklift.konveyor.io.provider",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,43945))),e.register("edit","harvesterhci.io.addon",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,20668))),e.register("edit","harvesterhci.io.cloudtemplate",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,91416))),e.register("edit","harvesterhci.io.host",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,33857))),e.register("edit","harvesterhci.io.keypair",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,2138))),e.register("edit","harvesterhci.io.logging.clusterflow",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,70675))),e.register("edit","harvesterhci.io.logging.clusteroutput",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,17733))),e.register("edit","harvesterhci.io.logging.flow",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,65647))),e.register("edit","harvesterhci.io.logging.output",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,49216))),e.register("edit","harvesterhci.io.monitoring.alertmanagerconfig",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,36605))),e.register("edit","harvesterhci.io.networkattachmentdefinition",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,46548))),e.register("edit","harvesterhci.io.schedulevmbackup",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,4335))),e.register("edit","harvesterhci.io.secret",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,74583))),e.register("edit","harvesterhci.io.setting",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,78407))),e.register("edit","harvesterhci.io.storage",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,14787))),e.register("edit","harvesterhci.io.virtualmachinebackup",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,22384))),e.register("edit","harvesterhci.io.virtualmachineimage",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,77953))),e.register("edit","harvesterhci.io.virtualmachinetemplateversion",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,85023))),e.register("edit","harvesterhci.io.vmsnapshot",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,10473))),e.register("edit","harvesterhci.io.volume",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,57209))),e.register("edit","harvesterhci.io.volumesnapshot",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,33514))),e.register("edit","kubeovn.io.iptablesdnatrule",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,91639))),e.register("edit","kubeovn.io.iptableseip",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,13041))),e.register("edit","kubeovn.io.iptablessnatrule",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,56253))),e.register("edit","kubeovn.io.providernetwork",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,62846))),e.register("edit","kubeovn.io.subnet",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,46244))),e.register("edit","kubeovn.io.vlan",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,68797))),e.register("edit","kubeovn.io.vpc",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,18411))),e.register("edit","kubeovn.io.vpcnatgateway",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,64203))),e.register("edit","kubevirt.io.virtualmachine",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,18717))),e.register("edit","loadbalancer.harvesterhci.io.ippool",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,27494))),e.register("edit","loadbalancer.harvesterhci.io.loadbalancer",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,21132))),e.register("edit","management.cattle.io.project",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,84129))),e.register("edit","migration.harvesterhci.io.openstacksource",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,16998))),e.register("edit","migration.harvesterhci.io.ovasource",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,47974))),e.register("edit","migration.harvesterhci.io.virtualmachineimport",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,13029))),e.register("edit","migration.harvesterhci.io.vmwaresource",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,9913))),e.register("edit","network.harvesterhci.io.clusternetwork",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,40041))),e.register("edit","network.harvesterhci.io.hostnetworkconfig",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,70466))),e.register("edit","network.harvesterhci.io.vlanconfig",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,55191))),e.register("edit","networking.k8s.io.networkpolicy",()=>Promise.all([o.e(123),o.e(654),o.e(374),o.e(431),o.e(6),o.e(134),o.e(739)]).then(o.bind(o,25058))),e.register("list","devices.harvesterhci.io.migconfiguration",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,93308))),e.register("list","devices.harvesterhci.io.pcidevice",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,73774))),e.register("list","devices.harvesterhci.io.sriovgpudevice",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,7962))),e.register("list","devices.harvesterhci.io.sriovnetworkdevice",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,88426))),e.register("list","devices.harvesterhci.io.usbdevice",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,13711))),e.register("list","devices.harvesterhci.io.vgpudevice",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,86869))),e.register("list","harvesterhci.io.addon",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,54844))),e.register("list","harvesterhci.io.cloudtemplate",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,34317))),e.register("list","harvesterhci.io.dashboard",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,25366))),e.register("list","harvesterhci.io.host",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,49440))),e.register("list","harvesterhci.io.logging.clusterflow",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,78646))),e.register("list","harvesterhci.io.logging.clusteroutput",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,56497))),e.register("list","harvesterhci.io.logging.flow",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,81342))),e.register("list","harvesterhci.io.logging.output",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,65391))),e.register("list","harvesterhci.io.monitoring.alertmanagerconfig",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,49610))),e.register("list","harvesterhci.io.networkattachmentdefinition",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,84773))),e.register("list","harvesterhci.io.schedulevmbackup",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,42148))),e.register("list","harvesterhci.io.secret",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,60633))),e.register("list","harvesterhci.io.setting",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,63970))),e.register("list","harvesterhci.io.storage",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,48490))),e.register("list","harvesterhci.io.virtualmachinebackup",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,17451))),e.register("list","harvesterhci.io.virtualmachineimage",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,99462))),e.register("list","harvesterhci.io.virtualmachinetemplateversion",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,81959))),e.register("list","harvesterhci.io.vmsnapshot",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,61117))),e.register("list","harvesterhci.io.volume",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,84311))),e.register("list","harvesterhci.io.volumesnapshot",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,32776))),e.register("list","kubeovn.io.vpc",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,36703))),e.register("list","kubevirt.io.virtualmachine",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,98692))),e.register("list","migration.harvesterhci.io.openstacksource",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,87875))),e.register("list","migration.harvesterhci.io.ovasource",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,53373))),e.register("list","migration.harvesterhci.io.virtualmachineimport",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,19767))),e.register("list","migration.harvesterhci.io.vmwaresource",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,25765))),e.register("list","network.harvesterhci.io.clusternetwork",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,43134))),e.register("list","network.harvesterhci.io.hostnetworkconfig",()=>Promise.all([o.e(895),o.e(250),o.e(483),o.e(134),o.e(715)]).then(o.bind(o,79090))),e.register("models","__tests__/kubevirt.io.virtualmachine.test",()=>o(7054)),e.register("models","__tests__/kubevirt.io.virtualmachineinstance.test",()=>o(7915)),e.register("models","clusterroletemplatebinding",()=>o(83727)),e.register("models","devices.harvesterhci.io.migconfiguration",()=>o(17976)),e.register("models","devices.harvesterhci.io.pcidevice",()=>o(66529)),e.register("models","devices.harvesterhci.io.pcideviceclaim",()=>o(66325)),e.register("models","devices.harvesterhci.io.sriovgpudevice",()=>o(13520)),e.register("models","devices.harvesterhci.io.sriovnetworkdevice",()=>o(75128)),e.register("models","devices.harvesterhci.io.usbdevice",()=>o(95311)),e.register("models","devices.harvesterhci.io.usbdeviceclaim",()=>o(17467)),e.register("models","devices.harvesterhci.io.vgpudevice",()=>o(46505)),e.register("models","forklift.konveyor.io.plan",()=>o(94175)),e.register("models","forklift.konveyor.io.provider",()=>o(89553)),e.register("models","harvester/configmap",()=>o(24481)),e.register("models","harvester/k8s.cni.cncf.io.networkattachmentdefinition",()=>o(4987)),e.register("models","harvester/logging.banzaicloud.io.clusterflow",()=>o(50826)),e.register("models","harvester/logging.banzaicloud.io.clusteroutput",()=>o(49039)),e.register("models","harvester/logging.banzaicloud.io.flow",()=>o(40322)),e.register("models","harvester/logging.banzaicloud.io.output",()=>o(15895)),e.register("models","harvester/management.cattle.io.setting",()=>o(65073)),e.register("models","harvester/monitoring.coreos.com.alertmanagerconfig",()=>o(53942)),e.register("models","harvester/namespace",()=>o(62878)),e.register("models","harvester/node",()=>o(55285)),e.register("models","harvester/persistentvolumeclaim",()=>o(15908)),e.register("models","harvester/pod",()=>o(14426)),e.register("models","harvester/schema",()=>o(60698)),e.register("models","harvester/secret",()=>o(36577)),e.register("models","harvester/snapshot.storage.k8s.io.volumesnapshot",()=>o(87214)),e.register("models","harvester/storage.k8s.io.storageclass",()=>o(82877)),e.register("models","harvester",()=>o(24222)),e.register("models","harvesterhci.io.addon",()=>o(52528)),e.register("models","harvesterhci.io.blockdevice",()=>o(46933)),e.register("models","harvesterhci.io.keypair",()=>o(72193)),e.register("models","harvesterhci.io.schedulevmbackup",()=>o(26422)),e.register("models","harvesterhci.io.setting",()=>o(96214)),e.register("models","harvesterhci.io.supportbundle",()=>o(25661)),e.register("models","harvesterhci.io.upgrade",()=>o(39334)),e.register("models","harvesterhci.io.upgradelog",()=>o(25418)),e.register("models","harvesterhci.io.virtualmachinebackup",()=>o(64778)),e.register("models","harvesterhci.io.virtualmachineimage",()=>o(38287)),e.register("models","harvesterhci.io.virtualmachinerestore",()=>o(82680)),e.register("models","harvesterhci.io.virtualmachinetemplate",()=>o(61746)),e.register("models","harvesterhci.io.virtualmachinetemplateversion",()=>o(96608)),e.register("models","k8s.cni.cncf.io.networkattachmentdefinition",()=>o(43842)),e.register("models","kubeovn.io.subnet",()=>o(13459)),e.register("models","kubeovn.io.vpc",()=>o(58899)),e.register("models","kubevirt.io.virtualmachine",()=>o(50784)),e.register("models","kubevirt.io.virtualmachineinstance",()=>o(79095)),e.register("models","loadbalancer.harvesterhci.io.ippool",()=>o(68917)),e.register("models","loadbalancer.harvesterhci.io.loadbalancer",()=>o(61772)),e.register("models","longhorn.io.node",()=>o(28433)),e.register("models","management/management.cattle.io.setting",()=>o(12032)),e.register("models","management.cattle.io.project",()=>o(82607)),e.register("models","metal.harvesterhci.io.inventory",()=>o(11971)),e.register("models","network.harvesterhci.io.clusternetwork",()=>o(85696)),e.register("models","network.harvesterhci.io.nodenetwork",()=>o(88272)),e.register("models","network.harvesterhci.io.vlanconfig",()=>o(70443)),e.register("models","network.harvesterhci.io.vlanstatus",()=>o(61715)),e.register("promptRemove","forklift.konveyor.io.plan",()=>o.e(973).then(o.bind(o,38074))),e.register("promptRemove","harvesterhci.io.virtualmachinebackup",()=>o.e(973).then(o.bind(o,88891))),e.register("promptRemove","health.harvesterhci.io.healthignorerule",()=>o.e(973).then(o.bind(o,40758))),e.register("promptRemove","kubevirt.io.virtualmachine",()=>o.e(973).then(o.bind(o,85265))),e.register("l10n","en-us",()=>Promise.resolve().then(o.t.bind(o,49037,23))),e.register("dialog","CloneVmDialog",()=>o.e(907).then(o.bind(o,89434))),e.register("dialog","ConfirmExecutionDialog",()=>o.e(907).then(o.bind(o,69956))),e.register("dialog","ConfirmRelatedToRemoveDialog",()=>o.e(907).then(o.bind(o,66402))),e.register("dialog","EnablePciPassthrough",()=>o.e(907).then(o.bind(o,61010))),e.register("dialog","EnableSriovDevice",()=>o.e(907).then(o.bind(o,67038))),e.register("dialog","EnableSriovGpuDevice",()=>o.e(907).then(o.bind(o,74994))),e.register("dialog","EnableUSBPassthrough",()=>o.e(907).then(o.bind(o,83636))),e.register("dialog","EnableVGpuDevice",()=>o.e(907).then(o.bind(o,71524))),e.register("dialog","HarvesterAddHotplugNic",()=>o.e(907).then(o.bind(o,75867))),e.register("dialog","HarvesterAddHotplugVolumeModal",()=>o.e(907).then(o.bind(o,57089))),e.register("dialog","HarvesterBackupModal",()=>o.e(907).then(o.bind(o,79819))),e.register("dialog","HarvesterCPUMemoryHotPlugDialog",()=>o.e(907).then(o.bind(o,49232))),e.register("dialog","HarvesterCloneTemplate",()=>o.e(907).then(o.bind(o,53604))),e.register("dialog","HarvesterDataMigrationDialog",()=>o.e(907).then(o.bind(o,37485))),e.register("dialog","HarvesterEjectCDROMDialog",()=>o.e(907).then(o.bind(o,3352))),e.register("dialog","HarvesterEnableK3k",()=>o.e(907).then(o.bind(o,97180))),e.register("dialog","HarvesterEnableNvidiaDriverToolkit",()=>o.e(907).then(o.bind(o,98420))),e.register("dialog","HarvesterExportImageDialog",()=>o.e(907).then(o.bind(o,22807))),e.register("dialog","HarvesterHotUnplug",()=>o.e(907).then(o.bind(o,68399))),e.register("dialog","HarvesterImageDownloader",()=>o.e(907).then(o.bind(o,51665))),e.register("dialog","HarvesterInsertCdRomVolume",()=>o.e(907).then(o.bind(o,5855))),e.register("dialog","HarvesterMaintenanceDialog",()=>o.e(907).then(o.bind(o,24384))),e.register("dialog","HarvesterMigrationDialog",()=>o.e(907).then(o.bind(o,40741))),e.register("dialog","HarvesterQuotaDialog",()=>o.e(907).then(o.bind(o,31624))),e.register("dialog","HarvesterRestoreDialog",()=>o.e(907).then(o.bind(o,289))),e.register("dialog","HarvesterStorageMigrationDialog",()=>o.e(907).then(o.bind(o,15048))),e.register("dialog","HarvesterSupportBundle",()=>o.e(907).then(o.bind(o,7042))),e.register("dialog","HarvesterVMSnapshotDialog",()=>o.e(907).then(o.bind(o,17968))),e.register("dialog","HarvesterVlanConfigMigrateDialog",()=>o.e(907).then(o.bind(o,83874))),e.register("dialog","MessageBox",()=>o.e(907).then(o.bind(o,89257))),e.register("dialog","RestartVMDialog",()=>o.e(907).then(o.bind(o,48387))),e.register("dialog","RestoreSnapshotDialog",()=>o.e(907).then(o.bind(o,39058))),e.register("dialog","SnapshotDialog",()=>o.e(907).then(o.bind(o,95931))),e.register("dialog","VolumeCloneDialog",()=>o.e(907).then(o.bind(o,55780))),e.register("formatters","AttachVMWithName",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,16684))),e.register("formatters","BackupCreatedFrom",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,22234))),e.register("formatters","CloudInitType",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,32012))),e.register("formatters","HarvesterBackupProgressBar",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,13396))),e.register("formatters","HarvesterBackupTargetValidation",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,98235))),e.register("formatters","HarvesterBoolean",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,52708))),e.register("formatters","HarvesterCPUPinning",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,46e3))),e.register("formatters","HarvesterCPUUsed",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,9590))),e.register("formatters","HarvesterCronExpression",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,79211))),e.register("formatters","HarvesterDiskState",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,8579))),e.register("formatters","HarvesterHost",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,18290))),e.register("formatters","HarvesterHostNetworkConfigMode",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,62639))),e.register("formatters","HarvesterIpAddress",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,97602))),e.register("formatters","HarvesterListener",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,52279))),e.register("formatters","HarvesterMemoryUsed",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,96247))),e.register("formatters","HarvesterMigrationState",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,10644))),e.register("formatters","HarvesterStorageUsed",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,58681))),e.register("formatters","HarvesterVFAddress",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,93922))),e.register("formatters","HarvesterVFsNum",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,22011))),e.register("formatters","HarvesterVGpuDevices",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,66810))),e.register("formatters","HarvesterVlan",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,36814))),e.register("formatters","HarvesterVmState",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,53686))),e.register("formatters","HarvesterVolumeState",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,5538))),e.register("formatters","NetworkRouteConnectivity",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,47385))),e.register("formatters","RelatedVolumeSnapshotCounts",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,40179))),e.register("formatters","SnapshotTargetVolume",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,67359))),e.register("formatters","StateWithPopover",()=>Promise.all([o.e(123),o.e(431),o.e(341),o.e(902)]).then(o.bind(o,12521)))}var r=o(20652),i=o(9274);function s(e,t,n,r,o,a){return(0,i.openBlock)(),(0,i.createElementBlock)("div",null," This is harvester Dashboard. ")}var l=o(32766),c={beforeCreate(){this.$router.replace({name:`${r.KR}-c-cluster-resource`,params:{...this.$router.currentRoute.params,product:r.KR,resource:l.rk.DASHBOARD}})}},u=o(47433);const d=(0,u.A)(c,[["render",s]]);var h=d;const p={class:"content mt-20"},f={class:"promo"},m={key:0,class:"box mb-20 box-primary"},g={class:"pb-10"},v={class:"pb-10"},b={key:1,class:"row"},y={class:"col span-6 box box-primary"},w=["href"],O={class:"warning"},S={class:"col span-6 box box-primary"},E=["href"],x={class:"warning"},_={class:"community"},k={class:"external"},C={href:"https://www.suse.com/suse-harvester/support-matrix/all-supported-versions",target:"_blank",rel:"noopener noreferrer nofollow"},A={href:"https://www.suse.com/products/harvester/",target:"_blank",rel:"noopener noreferrer nofollow"};function T(e,t,n,r,o,a){const s=(0,i.resolveComponent)("BannerGraphic"),l=(0,i.resolveComponent)("t"),c=(0,i.resolveComponent)("CommunityLinks"),u=(0,i.resolveComponent)("IndentedPanel"),d=(0,i.resolveComponent)("HarvesterSupportBundle");return(0,i.openBlock)(),(0,i.createElementBlock)("div",null,[(0,i.createVNode)(s,{title:e.t(a.title,{},!0)},null,8,["title"]),(0,i.createVNode)(u,null,{default:(0,i.withCtx)(()=>[(0,i.createElementVNode)("div",p,[(0,i.createElementVNode)("div",f,[a.showSupportBundle?((0,i.openBlock)(),(0,i.createElementBlock)("div",m,[(0,i.createElementVNode)("h2",null,(0,i.toDisplayString)(e.t("harvester.modal.bundle.title")),1),(0,i.createElementVNode)("div",null,[(0,i.createElementVNode)("p",g,(0,i.toDisplayString)(e.t("harvester.modal.bundle.titleDescription")),1),(0,i.createElementVNode)("button",{class:"btn role-secondary btn-sm",type:"button",onClick:t[0]||(t[0]=(...e)=>a.open&&a.open(...e))},(0,i.toDisplayString)(e.t("harvester.modal.bundle.title")),1)])])):(0,i.createCommentVNode)("",!0),(0,i.createElementVNode)("div",{class:(0,i.normalizeClass)(["box box-primary",{"mb-20":a.dev}])},[(0,i.createElementVNode)("h2",null,(0,i.toDisplayString)(e.t("harvester.support.kubeconfig.title")),1),(0,i.createElementVNode)("div",null,[(0,i.createElementVNode)("p",v,(0,i.toDisplayString)(e.t("harvester.support.kubeconfig.titleDescription")),1),(0,i.createElementVNode)("button",{class:"btn role-secondary btn-sm",type:"button",onClick:t[1]||(t[1]=t=>e.currentCluster.downloadKubeConfig())},(0,i.toDisplayString)(e.t("harvester.support.kubeconfig.title")),1)])],2),a.dev?((0,i.openBlock)(),(0,i.createElementBlock)("div",b,[(0,i.createElementVNode)("div",y,[(0,i.createElementVNode)("h2",null,[(0,i.createElementVNode)("a",{rel:"nofollow noopener noreferrer",target:"_blank",href:a.rancherLink},[(0,i.createTextVNode)((0,i.toDisplayString)(e.t("harvester.support.internal.rancher.title"))+" ",1),t[2]||(t[2]=(0,i.createElementVNode)("i",{class:"icon icon-external-link"},null,-1))],8,w)]),(0,i.createElementVNode)("div",null,[(0,i.createElementVNode)("p",O,[(0,i.createVNode)(l,{k:"harvester.support.internal.rancher.titleDescription",raw:!0,url:a.rancherIntegrationLink},null,8,["url"])])])]),(0,i.createElementVNode)("div",S,[(0,i.createElementVNode)("h2",null,[(0,i.createElementVNode)("a",{rel:"nofollow noopener noreferrer",target:"_blank",href:a.longhornLink},[(0,i.createTextVNode)((0,i.toDisplayString)(e.t("harvester.support.internal.longhorn.title"))+" ",1),t[3]||(t[3]=(0,i.createElementVNode)("i",{class:"icon icon-external-link"},null,-1))],8,E)]),(0,i.createElementVNode)("div",null,[(0,i.createElementVNode)("p",x,[(0,i.createVNode)(l,{k:"harvester.support.internal.longhorn.titleDescription",raw:!0})])])])])):(0,i.createCommentVNode)("",!0)]),(0,i.createElementVNode)("div",_,[(0,i.createVNode)(c,{"link-options":o.options},null,8,["link-options"])]),(0,i.createElementVNode)("div",k,[(0,i.createElementVNode)("a",C,[(0,i.createTextVNode)((0,i.toDisplayString)(e.t("harvester.support.community.learnMore"))+" ",1),t[4]||(t[4]=(0,i.createElementVNode)("i",{class:"icon icon-external-link"},null,-1))]),t[6]||(t[6]=(0,i.createTextVNode)(" or ",-1)),(0,i.createElementVNode)("a",A,[(0,i.createTextVNode)((0,i.toDisplayString)(e.t("harvester.support.community.pricing"))+" ",1),t[5]||(t[5]=(0,i.createElementVNode)("i",{class:"icon icon-external-link"},null,-1))])])])]),_:1}),a.showSupportBundle?((0,i.openBlock)(),(0,i.createBlock)(d,{key:0})):(0,i.createCommentVNode)("",!0)])}var R=o(65359),N=o(41476);const P={key:0,"data-testid":"banner-title-key",class:"title"},I={key:1,"data-testid":"banner-title",class:"title"};function M(e,t,n,r,o,a){const s=(0,i.resolveComponent)("BrandImage"),l=(0,i.resolveComponent)("t"),c=(0,i.resolveDirective)("clean-html");return e.shown?((0,i.openBlock)(),(0,i.createElementBlock)("div",{key:0,class:(0,i.normalizeClass)(["banner-graphic-area",{[o.alignClass]:!0}])},[(0,i.createElementVNode)("div",{class:(0,i.normalizeClass)([o.bannerClass,"graphic banner-graphic-height"])},[(0,i.createVNode)(s,{class:"banner","data-testid":"banner-brand__img","file-name":"banner.svg",draggable:!1,alt:e.t("landing.bannerImage")},null,8,["alt"])],2),n.titleKey?((0,i.openBlock)(),(0,i.createElementBlock)("div",P,[(0,i.createVNode)(l,{k:n.titleKey},null,8,["k"])])):n.title?(0,i.withDirectives)(((0,i.openBlock)(),(0,i.createElementBlock)("h1",I,null,512)),[[c,n.title]]):(0,i.createCommentVNode)("",!0)],2)):(0,i.createCommentVNode)("",!0)}var D=o(55277),L=o(23776),B=o(38275),$={components:{BrandImage:L.A},mixins:[D.A],props:{title:{type:String,default:null},titleKey:{type:String,default:null}},data(){const e=(0,B.V)(this.$store.getters["management/brand"]),t=e?.banner||{},n=t.textAlign||"center",r=t.bannerClass||"";return{alignClass:`banner-text-${n}`,bannerClass:r}}};o(84872);const V=(0,u.A)($,[["render",M],["__scopeId","data-v-2692661e"]]);var F=V;const j={class:"indented-panel"};function U(e,t,n,r,o,a){return(0,i.openBlock)(),(0,i.createElementBlock)("div",j,[(0,i.renderSlot)(e.$slots,"default")])}var G={};o(72674);const H=(0,u.A)(G,[["render",U]]);var q=H;const Q={key:0},z=["href","aria-label"],K={key:0,class:"support-link"},W=["aria-label"];function X(e,t,n,r,o,a){const s=(0,i.resolveComponent)("router-link"),l=(0,i.resolveComponent)("SimpleBox");return a.hasOptions?((0,i.openBlock)(),(0,i.createElementBlock)("div",Q,[(0,i.createVNode)(l,{pref:e.pref,"pref-key":e.prefKey},{title:(0,i.withCtx)(()=>[(0,i.createElementVNode)("h2",null,(0,i.toDisplayString)(e.t("customLinks.displayTitle")),1)]),default:(0,i.withCtx)(()=>[((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,null,(0,i.renderList)(a.options,(e,t)=>((0,i.openBlock)(),(0,i.createElementBlock)("div",{key:t,class:"support-link"},[e.value.startsWith("/")?((0,i.openBlock)(),(0,i.createBlock)(s,{key:0,to:e.value,role:"link","aria-label":e.label},{default:(0,i.withCtx)(()=>[(0,i.createTextVNode)((0,i.toDisplayString)(e.label),1)]),_:2},1032,["to","aria-label"])):((0,i.openBlock)(),(0,i.createElementBlock)("a",{key:1,href:e.value,rel:"noopener noreferrer nofollow",target:"_blank",role:"link","aria-label":e.label},(0,i.toDisplayString)(e.label),9,z))]))),128)),(0,i.renderSlot)(e.$slots,"default",{},void 0,!0),e.selectedLocaleLabel===e.t("locale.zh-hans")?((0,i.openBlock)(),(0,i.createElementBlock)("div",K,[(0,i.createElementVNode)("a",{class:"link",tabindex:"0","aria-label":e.t("footer.wechat.title"),role:"link",onClick:t[0]||(t[0]=(...e)=>a.show&&a.show(...e)),onKeydown:t[1]||(t[1]=(0,i.withKeys)((...e)=>a.show&&a.show(...e),["enter"]))},(0,i.toDisplayString)(e.t("footer.wechat.title")),41,W)])):(0,i.createCommentVNode)("",!0)]),_:3},8,["pref","pref-key"])])):(0,i.createCommentVNode)("",!0)}var Y=o(76750),Z=o(35664),J=o(9262),ee=o(83297),te=o(49845),ne=o(88339),re=o(97519),ie=o(4364);const oe=[{key:"docs",value:te.M0,enabled:!0},{key:"forums",value:"https://forums.suse.com/",enabled:!0},{key:"slack",value:"https://slack.rancher.io/",enabled:!0},{key:"issues",value:"https://github.com/rancher/dashboard/issues/new/choose",enabled:!0},{key:"getStarted",value:`${te.M0}/getting-started/overview`,enabled:!0}],ae="suseCollective",se={key:"appCo",value:"https://apps.rancher.io/",enabled:!0},le={key:"commercialSupport",value:"https://www.suse.com/products/rancher/",enabled:!0,readonly:!0},ce={key:"cnforums",value:"https://forums.rancher.cn/",enabled:!0},ue="v1",de="v1.1",he="v1.2";async function pe(e,t,n,r){let i={};try{const t=await e.dispatch("management/find",{type:Z.Mc.SETTING,id:J.HG.UI_CUSTOM_LINKS});t.value&&(i=JSON.parse(t.value))}catch(a){ie.warn("Could not parse custom link settings",a)}if(i?.version?.startsWith(ue)){if(i?.version!==ue&&i?.version!==de||(i.version=he,i.defaults.includes(se.key)||i.defaults.push(se.key),i.defaults=i.defaults.filter(e=>e!==ae)),i.defaults){const e=[...oe];(0,ee.f$)()&&e.push(se),e.forEach(e=>{const t=i.defaults.find(t=>t===e.key);e.enabled=!!t}),i.defaults=e}return i.custom.forEach(e=>{const t=`<a href="${e.value}"></a>`,n=re.A.sanitize(t);n!==t&&(ie.error(`Custom link value "${e.value}" is not valid for link "${e.label}"`),e.value="/#")}),fe(i,t,n,r,e)}const o={version:ue,defaults:[...oe],custom:[]};(0,ee.f$)()&&o.defaults.push(se);try{const{uiIssuesSetting:t,uiCommunitySetting:n}=await(0,ne.kR)({uiIssuesSetting:e.dispatch("management/find",{type:Z.Mc.SETTING,id:J.HG.ISSUES}),uiCommunitySetting:e.dispatch("management/find",{type:Z.Mc.SETTING,id:J.HG.COMMUNITY_LINKS})});if("false"===n?.value&&o.defaults.forEach(e=>e.enabled=!1),t?.value){o.custom.push({label:r?r("customLinks.defaults.issues"):"Issues",value:t.value});const e=o.defaults?.find(e=>"issues"===e.key);e&&(e.enabled=!1,e.readOnly=!0)}}catch(a){ie.warn("Could not parse legacy link settings",a)}return fe(o,t,n,r,e)}function fe(e,t,n,r,i){if(!t&&!n){const t=e.defaults?.find(e=>"commercialSupport"===e.key);t||e.defaults.push(le)}const o=i.getters["i18n/selectedLocaleLabel"];o===r("locale.zh-hans")&&e.defaults.push(ce),e.defaults=e.defaults.map(e=>({...e,label:r(`'customLinks.defaults.${e.key}`)}));const a=e.custom.reduce((e,t)=>(e[t.label]=t,e),{});return e.defaults.forEach(e=>{a[e.label]&&(e.enabled=!1,e.readonly=!0)}),e}var me=o(70176),ge={name:"CommunityLinks",components:{SimpleBox:Y.A},props:{linkOptions:{type:Object,default:()=>({})},isSupportPage:{type:Boolean,default:!1}},mixins:[D.A],async fetch(){this.links=await pe(this.$store,this.hasSupport,this.isSupportPage,e=>this.t(e))},data(){return{links:{},showWeChatModal:!1}},computed:{...(0,R.L8)("i18n",["selectedLocaleLabel"]),hasOptions(){return!!Object.keys(this.options).length||!!Object.keys(this.$slots).length},hasSupport(){return(0,ee.f$)()||"true"===this.$store.getters["management/byId"](Z.Mc.SETTING,J.HG.SUPPORTED)?.value},options(){if(this.linkOptions&&Object.keys(this.linkOptions).length){const e=[];return Object.keys(this.linkOptions).forEach(t=>{e.push({key:t,label:this.t(t),value:this.linkOptions[t]})}),e}const e=[];return this.links.custom&&e.push(...this.links.custom),this.links.defaults&&e.push(...this.links.defaults.filter(e=>e.enabled)),e.map(e=>({...e,value:(0,me.OD)(e.value)}))}},methods:{show(){this.$store.dispatch("management/promptModal",{component:"WechatDialog"})}}};o(45801);const ve=(0,u.A)(ge,[["render",X],["__scopeId","data-v-50534f1b"]]);var be=ve,ye=o(7042),we=o(66242),Oe=o(3791),Se={components:{BannerGraphic:F,IndentedPanel:q,CommunityLinks:be,HarvesterSupportBundle:ye["default"]},data(){return{options:{"footer.docs":"https://docs.harvesterhci.io","footer.forums":"https://forums.rancher.com/c/harvester/","footer.slack":"https://slack.rancher.io","footer.issue":"https://github.com/harvester/harvester/issues/new/choose"}}},computed:{...(0,R.L8)(["currentCluster"]),dev(){try{return this.$store.getters["prefs/get"](N.bc)}catch{return this.$store.getters["prefs/get"](N.IJ)}},title(){return"harvester.support.title"},showSupportBundle(){const e=this.$store.getters["currentProduct"].inStore;return!!this.$store.getters[`${e}/byId`](Z.yx,l.rk.SUPPORT_BUNDLE)},internalPrefix(){const e=window.location.host,t=window.location.pathname.replace(this.$route.path,""),n=this.$route?.params;return{host:e,prefix:t,params:n}},rancherLink(){const{host:e,prefix:t,params:n}=this.internalPrefix;return`https://${e}${t}/c/${n.cluster}/explorer`},longhornLink(){const{host:e,params:t}=this.internalPrefix;return`https://${e}/k8s/clusters/${t.cluster}/api/v1/namespaces/longhorn-system/services/http:longhorn-frontend:80/proxy/#/dashboard`},rancherIntegrationLink(){const e=this.$store.getters["harvester-common/getServerVersion"]();return(0,Oe.nn)(we.d.RANCHER_INTEGRATION_URL,e)}},methods:{open(){this.$store.commit("harvester-common/toggleBundleModal",!0)}}};o(41158);const Ee=(0,u.A)(Se,[["render",T],["__scopeId","data-v-74e3f663"]]);var xe=Ee;const _e={class:"serial-console-page"};function ke(e,t,n,r,o,a){const s=(0,i.resolveComponent)("SerialConsole");return(0,i.openBlock)(),(0,i.createElementBlock)("div",_e,[(0,i.createVNode)(s,{ref:"serialConsole",value:a.vmi||{}},null,8,["value"])])}const Ce={class:"harvester-shell-container"},Ae={key:0,class:"shell-search"},Te={ref:"xterm",class:"shell-body"};function Re(e,t,n,r,o,a){const s=(0,i.resolveComponent)("resize-observer");return(0,i.openBlock)(),(0,i.createElementBlock)("div",Ce,[o.showSearch?((0,i.openBlock)(),(0,i.createElementBlock)("div",Ae,[(0,i.withDirectives)((0,i.createElementVNode)("input",{ref:"searchInput","onUpdate:modelValue":t[0]||(t[0]=e=>o.searchQuery=e),type:"text",class:"shell-search-input",placeholder:"Search in terminal",onInput:t[1]||(t[1]=(...e)=>a.onSearchInput&&a.onSearchInput(...e)),onKeydown:t[2]||(t[2]=(...e)=>a.onSearchKeydown&&a.onSearchKeydown(...e))},null,544),[[i.vModelText,o.searchQuery]]),(0,i.createElementVNode)("button",{class:"btn role-secondary btn-sm shell-search-btn",type:"button",title:"Shift+Enter",onClick:t[3]||(t[3]=(...e)=>a.findPrevious&&a.findPrevious(...e))}," Prev "),(0,i.createElementVNode)("button",{class:"btn role-secondary btn-sm shell-search-btn",type:"button",title:"Enter",onClick:t[4]||(t[4]=(...e)=>a.findNext&&a.findNext(...e))}," Next "),(0,i.createElementVNode)("button",{class:"btn role-secondary btn-sm shell-search-btn",type:"button",title:"Esc",onClick:t[5]||(t[5]=(...e)=>a.closeSearch&&a.closeSearch(...e))}," Close ")])):(0,i.createCommentVNode)("",!0),(0,i.createElementVNode)("div",Te,null,512),(0,i.createVNode)(s,{onNotify:a.fit},null,8,["onNotify"])])}var Ne=o(12784),Pe=o.n(Ne),Ie=o(4364);const Me=new WeakMap,De=new WeakMap;function Le(e){const t=Me.get(e);return Ie.assert(null!=t,"'this' is expected an Event object, but got",e),t}function Be(e){null==e.passiveListener?e.event.cancelable&&(e.canceled=!0,"function"===typeof e.event.preventDefault&&e.event.preventDefault()):"undefined"!==typeof Ie&&"function"===typeof Ie.error&&Ie.error("Unable to preventDefault inside passive event listener invocation.",e.passiveListener)}function $e(e,t){Me.set(this,{eventTarget:e,event:t,eventPhase:2,currentTarget:e,canceled:!1,stopped:!1,immediateStopped:!1,passiveListener:null,timeStamp:t.timeStamp||Date.now()}),Object.defineProperty(this,"isTrusted",{value:!1,enumerable:!0});const n=Object.keys(t);for(let r=0;r<n.length;++r){const e=n[r];e in this||Object.defineProperty(this,e,Ve(e))}}function Ve(e){return{get(){return Le(this).event[e]},set(t){Le(this).event[e]=t},configurable:!0,enumerable:!0}}function Fe(e){return{value(){const t=Le(this).event;return t[e].apply(t,arguments)},configurable:!0,enumerable:!0}}function je(e,t){const n=Object.keys(t);if(0===n.length)return e;function r(t,n){e.call(this,t,n)}r.prototype=Object.create(e.prototype,{constructor:{value:r,configurable:!0,writable:!0}});for(let i=0;i<n.length;++i){const o=n[i];if(!(o in e.prototype)){const e=Object.getOwnPropertyDescriptor(t,o),n="function"===typeof e.value;Object.defineProperty(r.prototype,o,n?Fe(o):Ve(o))}}return r}function Ue(e){if(null==e||e===Object.prototype)return $e;let t=De.get(e);return null==t&&(t=je(Ue(Object.getPrototypeOf(e)),e),De.set(e,t)),t}function Ge(e,t){const n=Ue(Object.getPrototypeOf(t));return new n(e,t)}function He(e){return Le(e).immediateStopped}function qe(e,t){Le(e).eventPhase=t}function Qe(e,t){Le(e).currentTarget=t}function ze(e,t){Le(e).passiveListener=t}$e.prototype={get type(){return Le(this).event.type},get target(){return Le(this).eventTarget},get currentTarget(){return Le(this).currentTarget},composedPath(){const e=Le(this).currentTarget;return null==e?[]:[e]},get NONE(){return 0},get CAPTURING_PHASE(){return 1},get AT_TARGET(){return 2},get BUBBLING_PHASE(){return 3},get eventPhase(){return Le(this).eventPhase},stopPropagation(){const e=Le(this);e.stopped=!0,"function"===typeof e.event.stopPropagation&&e.event.stopPropagation()},stopImmediatePropagation(){const e=Le(this);e.stopped=!0,e.immediateStopped=!0,"function"===typeof e.event.stopImmediatePropagation&&e.event.stopImmediatePropagation()},get bubbles(){return Boolean(Le(this).event.bubbles)},get cancelable(){return Boolean(Le(this).event.cancelable)},preventDefault(){Be(Le(this))},get defaultPrevented(){return Le(this).canceled},get composed(){return Boolean(Le(this).event.composed)},get timeStamp(){return Le(this).timeStamp},get srcElement(){return Le(this).eventTarget},get cancelBubble(){return Le(this).stopped},set cancelBubble(e){if(!e)return;const t=Le(this);t.stopped=!0,"boolean"===typeof t.event.cancelBubble&&(t.event.cancelBubble=!0)},get returnValue(){return!Le(this).canceled},set returnValue(e){e||Be(Le(this))},initEvent(){}},Object.defineProperty($e.prototype,"constructor",{value:$e,configurable:!0,writable:!0}),"undefined"!==typeof window&&"undefined"!==typeof window.Event&&(Object.setPrototypeOf($e.prototype,window.Event.prototype),De.set(window.Event.prototype,$e));const Ke=new WeakMap,We=1,Xe=2,Ye=3;function Ze(e){return null!==e&&"object"===typeof e}function Je(e){const t=Ke.get(e);if(null==t)throw new TypeError("'this' is expected an EventTarget object, but got another value.");return t}function et(e){return{get(){const t=Je(this);let n=t.get(e);while(null!=n){if(n.listenerType===Ye)return n.listener;n=n.next}return null},set(t){"function"===typeof t||Ze(t)||(t=null);const n=Je(this);let r=null,i=n.get(e);while(null!=i)i.listenerType===Ye?null!==r?r.next=i.next:null!==i.next?n.set(e,i.next):n.delete(e):r=i,i=i.next;if(null!==t){const i={listener:t,listenerType:Ye,passive:!1,once:!1,next:null};null===r?n.set(e,i):r.next=i}},configurable:!0,enumerable:!0}}function tt(e,t){Object.defineProperty(e,`on${t}`,et(t))}function nt(e){function t(){rt.call(this)}t.prototype=Object.create(rt.prototype,{constructor:{value:t,configurable:!0,writable:!0}});for(let n=0;n<e.length;++n)tt(t.prototype,e[n]);return t}function rt(){if(!(this instanceof rt)){if(1===arguments.length&&Array.isArray(arguments[0]))return nt(arguments[0]);if(arguments.length>0){const e=new Array(arguments.length);for(let t=0;t<arguments.length;++t)e[t]=arguments[t];return nt(e)}throw new TypeError("Cannot call a class as a function")}Ke.set(this,new Map)}rt.prototype={addEventListener(e,t,n){if(null==t)return;if("function"!==typeof t&&!Ze(t))throw new TypeError("'listener' should be a function or an object.");const r=Je(this),i=Ze(n),o=i?Boolean(n.capture):Boolean(n),a=o?We:Xe,s={listener:t,listenerType:a,passive:i&&Boolean(n.passive),once:i&&Boolean(n.once),next:null};let l=r.get(e);if(void 0===l)return void r.set(e,s);let c=null;while(null!=l){if(l.listener===t&&l.listenerType===a)return;c=l,l=l.next}c.next=s},removeEventListener(e,t,n){if(null==t)return;const r=Je(this),i=Ze(n)?Boolean(n.capture):Boolean(n),o=i?We:Xe;let a=null,s=r.get(e);while(null!=s){if(s.listener===t&&s.listenerType===o)return void(null!==a?a.next=s.next:null!==s.next?r.set(e,s.next):r.delete(e));a=s,s=s.next}},dispatchEvent(e){if(null==e||"string"!==typeof e.type)throw new TypeError('"event.type" should be a string.');const t=Je(this),n=e.type;let r=t.get(n);if(null==r)return!0;const i=Ge(this,e);let o=null;while(null!=r){if(r.once?null!==o?o.next=r.next:null!==r.next?t.set(n,r.next):t.delete(n):o=r,ze(i,r.passive?r.listener:null),"function"===typeof r.listener)try{r.listener.call(this,i)}catch(a){"undefined"!==typeof Ie&&"function"===typeof Ie.error&&Ie.error(a)}else r.listenerType!==Ye&&"function"===typeof r.listener.handleEvent&&r.listener.handleEvent(i);if(He(i))break;r=r.next}return ze(i,null),qe(i,0),Qe(i,null),!i.defaultPrevented}},Object.defineProperty(rt.prototype,"constructor",{value:rt,configurable:!0,writable:!0}),"undefined"!==typeof window&&"undefined"!==typeof window.EventTarget&&Object.setPrototypeOf(rt.prototype,window.EventTarget.prototype);var it=o(35881),ot=o(50667),at=o(4364);function st(e,t,n){return(t=lt(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function lt(e){var t=ct(e,"string");return"symbol"==typeof t?t:t+""}function ct(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}let ut=1,dt=!1,ht=!1;const pt="ws://",ft="wss://",mt="disconnected",gt=(rt.addEventListener,"connecting"),vt="connected",bt="closing",yt="reconnecting",wt=gt,Ot=vt,St=mt,Et="message",xt="frame_timeout",_t="connect_error",kt="disconnect_error",Ct="NO_WATCH",At="NO_SCHEMA",Tt="NO_PERMS",Rt="TOO_OLD";class Nt extends rt{constructor(e,t=!0,n=null,r=null,i=null,o=!1){super(),st(this,"url",void 0),st(this,"autoReconnect",!0),st(this,"frameTimeout",35e3),st(this,"metadata",{}),st(this,"hasBeenOpen",!1),st(this,"hasReconnected",!1),st(this,"protocol",null),st(this,"maxTries",null),st(this,"tries",0),st(this,"idAsTimestamp",!1),st(this,"socket",null),st(this,"state",mt),st(this,"framesReceived",0),st(this,"frameTimer",void 0),st(this,"reconnectTimer",void 0),st(this,"disconnectCallBacks",[]),st(this,"disconnectedAt",0),st(this,"closingId",0),st(this,"autoReconnectUrl",null),this.setUrl(e),this.autoReconnect=t,this.protocol=r,this.maxTries=i,this.idAsTimestamp=o,null!==n&&(this.frameTimeout=n)}setUrl(e){e.match(/wss?:\/\//)||(e=self.location.origin.replace(/^http/,"ws")+e),"https:"===self.location.protocol&&e.startsWith(pt)&&(e=ft+e.substr(pt.length)),this.url=e}connect(e={}){if(this.socket)return void at.error("Socket refusing to connect while another socket exists");this.state!==yt&&(this.state=gt),Object.assign(this.metadata,e);const t=this.idAsTimestamp?(new Date).getTime():ut++,n=(0,ot.R_)(this.url,"sockId",t);let r;this._baseLog("connecting",{id:t,url:n.replace(/\?.*/,"")}),this.tries++,r=this.protocol?new WebSocket(n,this.protocol):new WebSocket(n),r.sockId=t,r.metadata=this.metadata,r.onmessage=this._onmessage.bind(this),r.onopen=this._opened.bind(this),r.onerror=this._error.bind(this),r.onclose=this._closed.bind(this),this.socket=r,this.state=gt,this.dispatchEvent(new CustomEvent(wt))}send(e){return!(!this.socket||this.state!==vt)&&(this.socket.send(e),!0)}disconnect(e){e&&this.disconnectCallBacks.push(e);const t=this,n=new Promise((e,n)=>{function r(e){n(e),t.removeEventListener(_t,r)}this.state===mt&&e(),this.addEventListener(_t,r),this.disconnectCallBacks.push(()=>{this.removeEventListener(_t,r),e()})});return this.autoReconnect=!1,this._close(),n}reconnect(e={}){Object.assign(this.metadata,e),this.state!==gt?this.socket?this._close():this.connect(e):this._log("Ignoring reconnect for socket in connecting")}getMetadata(){return this.socket?this.socket.metadata:{}}getId(){return this.socket?this.socket.sockId:0}isConnected(){return this.state===vt}setAutoReconnect(e){this.autoReconnect=e}setAutoReconnectUrl(e){this.autoReconnectUrl=e}_close(){const e=this.socket;if(e){try{this._log("closing"),this.closingId=e.sockId,e.onopen=null,e.onerror=null,e.onmessage=null,e.close()}catch(t){this._log("exception",{e:t.toString()})}this.state=bt}}_opened(){this._log("opened");const e=(new Date).getTime(),t=this.disconnectedAt;let n=0;t&&(n=e-t),this.hasBeenOpen&&(this.hasReconnected=!0),this.hasBeenOpen=!0,this.state=vt,this.framesReceived=0,this.disconnectedAt=0,this.dispatchEvent(new CustomEvent(Ot,{detail:{tries:this.tries,afterMilliseconds:n}})),this.tries=0,this._resetWatchdog(),clearTimeout(this.reconnectTimer)}_onmessage(e){this._resetWatchdog(),this.tries=0,this.framesReceived++,this.dispatchEvent(new CustomEvent(Et,{detail:e}))}_resetWatchdog(){clearTimeout(this.frameTimer);const e=this.frameTimeout;e&&this.state===vt&&(this.frameTimer=setTimeout(()=>{this._log(`watchdog expired after${e}. Closing`),this._close(),this.dispatchEvent(new CustomEvent(xt))},e))}_error(){this.closingId=this.socket?this.socket.sockId:0,this._log("error")}_closed(e){const{code:t,reason:n,wasClean:r}=e;this._baseLog("closed",{id:this.closingId||this.socket?.sockId||"unknown",code:t,reason:n,clean:r}),this.closingId=0,this.socket=null,clearTimeout(this.reconnectTimer),clearTimeout(this.frameTimer);const i=this.disconnectCallBacks;while(i.length){const e=i.pop();e&&e.apply(this)}if([vt,bt].includes(this.state)&&(ht=!0),this.disconnectedAt||(this.disconnectedAt=(new Date).getTime()),dt||ht)if(this.autoReconnect){if(this.state=yt,this.maxTries&&this.tries>1&&this.tries<=this.maxTries){const e=new CustomEvent(_t);this.dispatchEvent(e)}if(this.maxTries&&this.tries>this.maxTries)this._log("closed. Will not reconnect (hit max attempts)"),this.state=mt,this.dispatchEvent(new CustomEvent(kt));else{const e=()=>{this._log("closed. Attempting to reconnect");const e=Math.max(1e3,Math.min(1e3*this.tries,3e4));this.reconnectTimer=setTimeout(()=>{this.connect()},e)};this.autoReconnectUrl?this.autoReconnectUrl().then(t=>{this.setUrl(t),e()}).catch(e=>{at.error("Failed to fetch socket auto reconnect url",e)}):e()}}else this.state=mt;else{this.autoReconnect=!1,this.state=mt;const e=new CustomEvent(_t,{detail:{isSafari:it.nr}});this.dispatchEvent(e),dt=!0}this.state===mt?this.dispatchEvent(new CustomEvent(St)):this.state===yt&&this.dispatchEvent(new CustomEvent(wt))}_log(e,t){this._baseLog(e,{state:this.state,id:this.socket?.sockId||0,...t})}_baseLog(e,t){const n=[e],r=Object.entries(t||{});n.unshift("Socket "),r.length&&(n.push(" ("),r.forEach(([e,t],r)=>{0!==r&&n.push(", "),n.push(`${e}=${t}`)}),n.push(")")),at.log(n.join(""))}}var Pt=o(4364),It={emits:["close"],props:{value:{type:Object,required:!0}},data(){return{socket:null,terminal:null,textDecoder:null,fitAddon:null,searchAddon:null,webglAddon:null,onResize:null,isOpen:!1,isOpening:!1,backlog:[],firstTime:!0,queue:[],isDraining:!1,drainScheduled:!1,drainTimer:null,showSearch:!1,searchQuery:"",searchOptions:{caseSensitive:!1,regex:!1,wholeWord:!1,incremental:!0,decorations:{matchBackground:"#B45309",matchBorder:"#FDBA74",matchOverviewRuler:"#FDBA74",activeMatchBackground:"#EA580C",activeMatchBorder:"#FED7AA",activeMatchColorOverviewRuler:"#FED7AA"}}}},computed:{serialConsoleUrl(){return this.value?.getSerialConsolePath||""},xtermConfig(){return{allowProposedApi:!0,cursorBlink:!0,cursorStyle:"bar",cursorWidth:2,scrollback:5e3,useStyle:!0,fontFamily:'JetBrains Mono, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace',fontSize:16,lineHeight:1.3}}},beforeUnmount(){this.close()},watch:{serialConsoleUrl(){this.terminal&&this.connect()}},async mounted(){this.textDecoder=new TextDecoder("utf-8"),await this.setupTerminal(),await this.connect(),this.onResize=Pe()(()=>this.fit(),100),window.addEventListener("resize",this.onResize),this.scheduleFit()},methods:{async setupTerminal(){const e=getComputedStyle(document.querySelector("body")),t=await o.e(935).then(o.bind(o,8817)),n=await(0,ne.kR)({fit:o.e(935).then(o.bind(o,58465)),webgl:o.e(935).then(o.bind(o,26733)),weblinks:o.e(935).then(o.bind(o,57585)),search:o.e(935).then(o.bind(o,28829)),canvas:o.e(935).then(o.t.bind(o,89740,23))}),r=new t.Terminal({theme:{background:e.getPropertyValue("--terminal-bg").trim(),cursor:e.getPropertyValue("--terminal-text").trim(),foreground:e.getPropertyValue("--terminal-text").trim()},...this.xtermConfig});this.fitAddon=new n.fit.FitAddon,this.searchAddon=new n.search.SearchAddon,r.loadAddon(this.fitAddon),r.loadAddon(this.searchAddon),r.loadAddon(new n.weblinks.WebLinksAddon),r.open(this.$refs.xterm);try{this.webglAddon=new n.webgl.WebglAddon,this.webglAddon.onContextLoss(()=>{!this.isUnmounted&&this.terminal&&this.fallbackToCanvas(r,n)}),r.loadAddon(this.webglAddon),requestAnimationFrame(()=>{if(this.isUnmounted||!this.terminal)return;const e=this.$refs.xterm?.querySelector(".xterm-helper-textarea"),t=e&&e.getBoundingClientRect().height>0;this.webglAddon&&!t&&(this.fallbackToCanvas(r,n),this.fit())})}catch(i){this.fallbackToCanvas(r,n)}this.fit(),this.flush(),this.scheduleDrainQueue(),r.onData(e=>{const t=this.str2ab(e);this.write(t)}),r.attachCustomKeyEventHandler(e=>{const t=e.key?.toLowerCase();return(e.ctrlKey||e.metaKey)&&"f"===t?(e.preventDefault(),this.openSearch(),!1):"escape"!==t||!this.showSearch||(e.preventDefault(),this.closeSearch(),!1)}),this.terminal=r},openSearch(){this.showSearch=!0,this.$nextTick(()=>{const e=this.$refs.searchInput;e&&(e.focus(),e.select())})},closeSearch(){this.showSearch=!1,this.searchQuery="",this.clearSearchHighlights(),this.terminal?.focus()},clearSearchHighlights(){this.searchAddon?.clearActiveDecoration(),this.searchAddon?.clearDecorations(),this.terminal?.clearSelection(),this.terminal&&this.terminal.refresh(0,this.terminal.rows-1)},findNext(){this.searchAddon&&this.searchQuery&&this.searchAddon.findNext(this.searchQuery,this.searchOptions)},findPrevious(){this.searchAddon&&this.searchQuery&&this.searchAddon.findPrevious(this.searchQuery,this.searchOptions)},onSearchInput(){this.searchQuery?this.findNext():this.clearSearchHighlights()},onSearchKeydown(e){"Enter"===e.key&&(e.preventDefault(),e.shiftKey?this.findPrevious():this.findNext()),"Escape"===e.key&&(e.preventDefault(),this.closeSearch())},scheduleFit(){this.$nextTick(()=>{requestAnimationFrame(()=>{this.fit(),setTimeout(()=>this.fit(),120)})})},fallbackToCanvas(e,t){this.isUnmounted||(this.webglAddon?.dispose(),this.webglAddon=null,this.canvasAddon||(this.canvasAddon=new t.canvas.CanvasAddon,e.loadAddon(this.canvasAddon)),this.fit())},str2ab(e){const t=new TextEncoder;return t.encode(e)},write(e){this.isOpen?this.socket.send(e):this.backlog.push(e)},enqueueMessage(e){this.queue.push(e),this.scheduleDrainQueue()},scheduleDrainQueue(){if(this.drainScheduled||this.isDraining||!this.terminal)return;this.drainScheduled=!0;const e=this.queue.length<=3,t=()=>{this.drainScheduled=!1,this.drainTimer=null,this.drainQueue()};e?t():this.drainTimer=requestAnimationFrame(t)},async decodeMessageData(e){if("string"===typeof e)return e;if(this.textDecoder||(this.textDecoder=new TextDecoder("utf-8")),e instanceof Blob){const t=await e.arrayBuffer();return this.textDecoder.decode(new Uint8Array(t),{stream:!0})}if(e instanceof ArrayBuffer)return this.textDecoder.decode(new Uint8Array(e),{stream:!0});if(ArrayBuffer.isView(e)){const t=e,n=new Uint8Array(t.buffer,t.byteOffset,t.byteLength);return this.textDecoder.decode(n,{stream:!0})}return String(e||"")},async drainQueue(){if(!this.isDraining&&this.terminal){this.isDraining=!0;try{while(this.queue.length>0){const e=this.queue.splice(0,this.queue.length),t=await Promise.allSettled(e),n=t.filter(e=>"fulfilled"===e.status).map(e=>e.value),r=n.filter(Boolean).join("");r&&await this.writeOutputInChunks(r),this.queue.length>0&&await this.nextFrame()}}finally{this.isDraining=!1,this.queue.length>0&&this.terminal&&this.scheduleDrainQueue()}}},async writeOutputInChunks(e){if(!e)return;const t=e.length>2e4?16e3:e.length>8e3?8e3:e.length;if(t!==e.length)for(let n=0;n<e.length;n+=t)this.terminal.write(e.slice(n,n+t)),n+t<e.length&&await this.nextFrame();else this.terminal.write(e)},nextFrame(){return new Promise(e=>requestAnimationFrame(e))},clear(){this.terminal.clear()},getSocketUrl(){return this.serialConsoleUrl},async connect(){this.socket&&(await this.socket.disconnect(),this.socket=null,this.terminal.reset());const e=this.getSocketUrl();e&&(this.socket=new Nt(e),this.socket.addEventListener(wt,e=>{this.isOpen=!1,this.isOpening=!0}),this.socket.addEventListener(_t,e=>{this.isOpen=!1,this.isOpening=!1,Pt.error("Connect Error",e)}),this.socket.addEventListener(Ot,e=>{this.isOpen=!0,this.isOpening=!1,this.show&&(this.fit(),this.flush()),this.scheduleFit(),this.firstTime&&(this.socket.send(this.str2ab("\n")),this.firstTime=!1)}),this.socket.addEventListener(St,e=>{this.isOpen=!1,this.isOpening=!1,this.$emit("close")}),this.socket.addEventListener(Et,e=>{this.enqueueMessage(this.decodeMessageData(e.detail.data))}),this.socket.connect(),this.terminal.focus())},flush(){const e=this.backlog.slice();this.backlog=[];for(const t of e)this.socket.send(t)},fit(e){this.fitAddon&&this.fitAddon.fit()},close(){this.onResize&&(window.removeEventListener("resize",this.onResize),this.onResize=null),this.drainTimer&&(cancelAnimationFrame(this.drainTimer),this.drainTimer=null),this.socket&&this.socket.disconnect(),this.terminal&&this.terminal.dispose()}}};o(65267);const Mt=(0,u.A)(It,[["render",Re]]);var Dt=Mt,Lt={components:{SerialConsole:Dt},async fetch(){this.rows=await this.$store.dispatch("harvester/findAll",{type:l.rk.VMI})},data(){return{uid:this.$route.params.uid}},computed:{vmi(){const e=this.$store.getters["harvester/all"](l.rk.VMI)||[],t=e.find(e=>e?.metadata?.ownerReferences?.[0]?.uid===this.uid);return t}},mounted(){window.addEventListener("beforeunload",()=>{this.$refs.serialConsole.close()})},head(){return{title:this.vmi?.metadata?.name}}};o(30012);const Bt=(0,u.A)(Lt,[["render",ke]]);var $t=Bt;function Vt(e,t,n,r,o,a){const s=(0,i.resolveComponent)("TabTitle"),l=(0,i.resolveComponent)("Loading"),c=(0,i.resolveComponent)("NovncConsoleWrapper");return(0,i.openBlock)(),(0,i.createElementBlock)(i.Fragment,null,[a.vmi?.metadata?.name?((0,i.openBlock)(),(0,i.createBlock)(s,{key:0,breadcrumb:!1,"show-child":!1},{default:(0,i.withCtx)(()=>[(0,i.createTextVNode)((0,i.toDisplayString)(a.vmi.metadata.name),1)]),_:1})):(0,i.createCommentVNode)("",!0),e.$fetchState.pending?((0,i.openBlock)(),(0,i.createBlock)(l,{key:1})):((0,i.openBlock)(),(0,i.createBlock)(c,{key:2,ref:"console",value:a.vmi,"onUpdate:value":t[0]||(t[0]=e=>a.vmi=e),class:"novnc-wrapper"},null,8,["value"]))],64)}var Ft=o(58972),jt=o(22896),Ut={components:{NovncConsoleWrapper:(0,i.defineAsyncComponent)({loader:()=>Promise.all([o.e(158),o.e(989)]).then(o.bind(o,12989)),loadingComponent:Ft.A}),Loading:Ft.A,TabTitle:jt.A},async fetch(){this.rows=await this.$store.dispatch("harvester/findAll",{type:l.rk.VMI})},data(){return{uid:this.$route.params.uid}},computed:{vmi(){const e=this.$store.getters["harvester/all"](l.rk.VMI)||[],t=e.find(e=>e?.metadata?.ownerReferences?.[0]?.uid===this.uid);return t}},mounted(){window.addEventListener("beforeunload",()=>{this.$refs.console?.close()})}};o(69025);const Gt=(0,u.A)(Ut,[["render",Vt]]);var Ht=Gt;function qt(e,t,n,r,o,a){const s=(0,i.resolveComponent)("ResourceList");return(0,i.openBlock)(),(0,i.createBlock)(s)}var Qt=o(83927),zt={name:"HarvesterResourcedList",components:{ResourceList:Qt.A}};const Kt=(0,u.A)(zt,[["render",qt]]);var Wt=Kt;const Xt={key:1},Yt={class:"mb-20"},Zt={class:"row mb-20"},Jt={class:"col span-6"},en={class:"mt-20 mb-5 pb-5"},tn={class:"text-label"},nn={class:"row mt-10 mb-20"},rn={key:0,class:"row mb-20"},on={class:"col logo-container span-6"},an={class:"mb-10"},sn={class:"text-muted"},ln=["src"],cn={class:"col logo-container span-6"},un={class:"mb-10"},dn={class:"text-muted"},hn=["src"],pn={class:"mt-20 mb-5 pb-5"},fn={class:"text-label"},mn={class:"row mt-10 mb-20"},gn={key:1,class:"row mb-20"},vn={class:"col logo-container span-12"},bn={class:"mb-10"},yn={class:"text-muted"},wn=["src"],On={class:"mt-40 mb-5 pb-0"},Sn={class:"text-label"},En={class:"row mt-20"},xn={key:2,class:"row mt-20 mb-20"},_n={class:"mt-40 mb-5 pb-0"},kn={class:"text-label"},Cn={class:"row mt-20"},An={key:3,class:"row mt-20 mb-20"},Tn={class:"col link-example"},Rn={key:0};function Nn(e,t,n,r,o,a){const s=(0,i.resolveComponent)("Loading"),l=(0,i.resolveComponent)("TypeDescription"),c=(0,i.resolveComponent)("LabeledInput"),u=(0,i.resolveComponent)("Checkbox"),d=(0,i.resolveComponent)("FileSelector"),h=(0,i.resolveComponent)("SimpleBox"),p=(0,i.resolveComponent)("ColorInput"),f=(0,i.resolveComponent)("Banner"),m=(0,i.resolveComponent)("AsyncButton");return e.$fetchState.pending?((0,i.openBlock)(),(0,i.createBlock)(s,{key:0})):((0,i.openBlock)(),(0,i.createElementBlock)("div",Xt,[(0,i.createElementVNode)("h1",Yt,(0,i.toDisplayString)(e.t("branding.label")),1),(0,i.createVNode)(l,{resource:"harvester"}),(0,i.createElementVNode)("div",null,[(0,i.createElementVNode)("div",Zt,[(0,i.createElementVNode)("div",Jt,[(0,i.createVNode)(c,{value:a.privateLabel,"onUpdate:value":t[0]||(t[0]=e=>a.privateLabel=e),label:e.t("branding.uiPL.label"),mode:a.mode,maxlength:100},null,8,["value","label","mode"])])]),(0,i.createElementVNode)("h3",en,(0,i.toDisplayString)(e.t("branding.logos.label")),1),(0,i.createElementVNode)("label",tn,(0,i.toDisplayString)(e.t("harvester.branding.logos.tip",{},!0)),1),(0,i.createElementVNode)("div",nn,[(0,i.createVNode)(u,{value:o.customizeLogo,"onUpdate:value":t[1]||(t[1]=e=>o.customizeLogo=e),label:e.t("branding.logos.useCustom"),mode:a.mode},null,8,["value","label","mode"])]),o.customizeLogo?((0,i.openBlock)(),(0,i.createElementBlock)("div",rn,[(0,i.createElementVNode)("div",on,[(0,i.createElementVNode)("div",an,[(0,i.createVNode)(d,{"byte-limit":2e4,"read-as-data-url":!0,variant:"secondary",size:"large",label:e.t("branding.logos.uploadLight"),mode:a.mode,onError:a.setError,onSelected:t[2]||(t[2]=e=>a.updateLogo(e,"uiLogoLight"))},null,8,["label","mode","onError"])]),o.uiLogoLight||o.uiLogoDark?((0,i.openBlock)(),(0,i.createBlock)(h,{key:0,class:"theme-light mb-10"},{default:(0,i.withCtx)(()=>[(0,i.createElementVNode)("label",sn,(0,i.toDisplayString)(e.t("branding.logos.lightPreview")),1),(0,i.createElementVNode)("img",{class:"logo-preview",src:o.uiLogoLight?o.uiLogoLight:o.uiLogoDark},null,8,ln)]),_:1})):(0,i.createCommentVNode)("",!0)]),(0,i.createElementVNode)("div",cn,[(0,i.createElementVNode)("div",un,[(0,i.createVNode)(d,{"byte-limit":2e4,"read-as-data-url":!0,variant:"secondary",size:"large",label:e.t("branding.logos.uploadDark"),mode:a.mode,onError:a.setError,onSelected:t[3]||(t[3]=e=>a.updateLogo(e,"uiLogoDark"))},null,8,["label","mode","onError"])]),o.uiLogoDark||o.uiLogoLight?((0,i.openBlock)(),(0,i.createBlock)(h,{key:0,class:"theme-dark mb-10"},{default:(0,i.withCtx)(()=>[(0,i.createElementVNode)("label",dn,(0,i.toDisplayString)(e.t("branding.logos.darkPreview")),1),(0,i.createElementVNode)("img",{class:"logo-preview",src:o.uiLogoDark?o.uiLogoDark:o.uiLogoLight},null,8,hn)]),_:1})):(0,i.createCommentVNode)("",!0)])])):(0,i.createCommentVNode)("",!0),(0,i.createElementVNode)("h3",pn,(0,i.toDisplayString)(e.t("branding.favicon.label")),1),(0,i.createElementVNode)("label",fn,(0,i.toDisplayString)(e.t("harvester.branding.favicon.tip",{},!0)),1),(0,i.createElementVNode)("div",mn,[(0,i.createVNode)(u,{value:o.customizeFavicon,"onUpdate:value":t[4]||(t[4]=e=>o.customizeFavicon=e),label:e.t("branding.favicon.useCustom"),mode:a.mode},null,8,["value","label","mode"])]),o.customizeFavicon?((0,i.openBlock)(),(0,i.createElementBlock)("div",gn,[(0,i.createElementVNode)("div",vn,[(0,i.createElementVNode)("div",bn,[(0,i.createVNode)(d,{"byte-limit":2e4,"read-as-data-url":!0,variant:"secondary",size:"large",label:e.t("branding.favicon.upload"),mode:a.mode,onError:a.setError,onSelected:t[5]||(t[5]=e=>a.updateLogo(e,"uiFavicon"))},null,8,["label","mode","onError"])]),o.uiFavicon?((0,i.openBlock)(),(0,i.createBlock)(h,{key:0},{default:(0,i.withCtx)(()=>[(0,i.createElementVNode)("label",yn,(0,i.toDisplayString)(e.t("branding.favicon.preview")),1),(0,i.createElementVNode)("img",{class:"logo-preview",src:o.uiFavicon},null,8,wn)]),_:1})):(0,i.createCommentVNode)("",!0)])])):(0,i.createCommentVNode)("",!0),(0,i.createElementVNode)("h3",On,(0,i.toDisplayString)(e.t("branding.color.label")),1),(0,i.createElementVNode)("label",Sn,(0,i.toDisplayString)(e.t("branding.color.tip",{},!0)),1),(0,i.createElementVNode)("div",En,[(0,i.createVNode)(u,{value:o.customizeColor,"onUpdate:value":t[6]||(t[6]=e=>o.customizeColor=e),label:e.t("branding.color.useCustom"),mode:a.mode},null,8,["value","label","mode"])]),o.customizeColor?((0,i.openBlock)(),(0,i.createElementBlock)("div",xn,[(0,i.createVNode)(p,{value:o.uiColor,"onUpdate:value":t[7]||(t[7]=e=>o.uiColor=e),"component-testid":"primary"},null,8,["value"])])):(0,i.createCommentVNode)("",!0),(0,i.createElementVNode)("h3",_n,(0,i.toDisplayString)(e.t("branding.linkColor.label")),1),(0,i.createElementVNode)("label",kn,(0,i.toDisplayString)(e.t("branding.linkColor.tip",{},!0)),1),(0,i.createElementVNode)("div",Cn,[(0,i.createVNode)(u,{value:o.customizeLinkColor,"onUpdate:value":t[8]||(t[8]=e=>o.customizeLinkColor=e),label:e.t("branding.linkColor.useCustom"),mode:a.mode},null,8,["value","label","mode"])]),o.customizeLinkColor?((0,i.openBlock)(),(0,i.createElementBlock)("div",An,[(0,i.createVNode)(p,{value:o.uiLinkColor,"onUpdate:value":t[9]||(t[9]=e=>o.uiLinkColor=e),class:"col","component-testid":"link"},null,8,["value"]),(0,i.createElementVNode)("span",Tn,[(0,i.createElementVNode)("a",{style:(0,i.normalizeStyle)(a.customLinkColor)},(0,i.toDisplayString)(e.t("branding.linkColor.example")),5)])])):(0,i.createCommentVNode)("",!0)]),((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,null,(0,i.renderList)(o.errors,(e,t)=>((0,i.openBlock)(),(0,i.createBlock)(f,{key:t,color:"error",label:e},null,8,["label"]))),128)),"edit"===a.mode?((0,i.openBlock)(),(0,i.createElementBlock)("div",Rn,[(0,i.createVNode)(m,{"component-testid":"branding-apply",class:"pull-right mt-20",mode:"apply",onClick:a.save},null,8,["onClick"])])):(0,i.createCommentVNode)("",!0)]))}var Pn=o(79380);const In=["data-testid","tabindex"],Mn={key:0,class:"text-label","aria-hidden":"true"},Dn=["data-testid"],Ln=["aria-disabled","aria-label","aria-describedby","disabled","value"],Bn={class:"text-muted color-value"};function $n(e,t,n,r,o,a){const s=(0,i.resolveComponent)("t");return(0,i.openBlock)(),(0,i.createElementBlock)("div",{class:(0,i.normalizeClass)(["color-input",{[n.mode]:n.mode,disabled:a.isDisabled}]),"data-testid":n.componentTestid+"-color-input",tabindex:a.isDisabled?-1:0,onKeydown:t[2]||(t[2]=(0,i.withKeys)((0,i.withModifiers)(()=>{},["prevent"]),["space"])),onKeyup:t[3]||(t[3]=(0,i.withKeys)((0,i.withModifiers)(e=>a.handleKeyup(e),["stop"]),["enter","space"]))},[n.labelKey||n.label?((0,i.openBlock)(),(0,i.createElementBlock)("label",Mn,[n.labelKey?((0,i.openBlock)(),(0,i.createBlock)(s,{key:0,k:n.labelKey,raw:!0},null,8,["k"])):n.label?((0,i.openBlock)(),(0,i.createElementBlock)(i.Fragment,{key:1},[(0,i.createTextVNode)((0,i.toDisplayString)(n.label),1)],64)):(0,i.createCommentVNode)("",!0)])):(0,i.createCommentVNode)("",!0),(0,i.createElementVNode)("div",{"data-testid":n.componentTestid+"-color-input_preview-container",class:"preview-container",onClick:t[1]||(t[1]=(0,i.withModifiers)(t=>e.$refs.input.click(t),["stop"]))},[(0,i.createElementVNode)("span",{style:(0,i.normalizeStyle)({"background-color":a.inputValue}),class:"color-display"},[(0,i.createElementVNode)("input",{ref:"input","aria-disabled":a.isDisabled?"true":"false","aria-label":a.ariaLabel,"aria-describedby":a.ariaDescribedBy,type:"color",disabled:a.isDisabled,tabindex:"-1",value:a.inputValue,onInput:t[0]||(t[0]=t=>e.$emit("update:value",t.target.value))},null,40,Ln)],4),(0,i.createElementVNode)("span",Bn,(0,i.toDisplayString)(a.inputValue),1)],8,Dn)],42,In)}var Vn=o(14220),Fn={emits:["update:value"],inheritAttrs:!1,props:{value:{type:String,default:""},defaultValue:{type:String,default:""},label:{type:String,default:null},labelKey:{type:String,default:null},mode:{type:String,validator(e){return[Vn.G5,Vn.nW].includes(e)},default:Vn.G5},componentTestid:{type:String,default:"color-input"},disabled:{type:Boolean,default:!1}},data(){return{viewMode:Vn.nW,editMode:Vn.G5}},computed:{inputValue(){return this.value?this.value:this.defaultValue},isDisabled(){const e=this.disabled;return this.mode!==this.editMode||e},ariaLabel(){return this.$attrs["aria-label"]?this.$attrs["aria-label"]:this.labelKey?this.t(this.labelKey):this.label?this.label:this.t("generic.colorPicker")},ariaDescribedBy(){return this.$attrs["aria-describedby"]||void 0}},mounted(){this.$emit("update:value",this.inputValue)},methods:{handleKeyup(e){return this.isDisabled?"":this.$refs.input.click(e)}}};o(2788);const jn=(0,u.A)(Fn,[["render",$n],["__scopeId","data-v-66bade12"]]);var Un=jn,Gn=o(89559),Hn=o(42200),qn=o(57388),Qn=o(30699),zn=o(9980),Kn=o(34765),Wn=o(52148);let Xn=!1;function Yn(e){const t=e.getters["management/byId"](Z.Mc.SETTING,J.HG.FAVICON),n=e.getters["management/brand"],r=Jn(document.head.getElementsByTagName("link"));if(r){let e;"suse"===n?e=(0,Wn.mS)("~shell/assets/brand/suse/favicon.png"):"harvester"===n&&(e=(0,Wn.mS)("~shell/assets/brand/harvester/favicon.png")),r.href=t?.value||e||er,Xn=!0}}function Zn(){const e=Jn(document.head.getElementsByTagName("link"));return e?e.href:""}function Jn(e){for(let t=0;t<e.length;t++){const n=e[t];if(n.rel?.includes("icon"))return n}}const er=Zn(),tr=o(70465);var nr={components:{LabeledInput:Pn.o,Checkbox:Hn.S,FileSelector:qn.Ay,Loading:Ft.A,SimpleBox:Y.A,AsyncButton:Qn.A,Banner:zn.l,ColorInput:Un,TypeDescription:Gn.A},async fetch(){const e=await(0,ne.kR)({uiPLSetting:this.$store.dispatch("management/find",{type:Z.Mc.SETTING,id:J.HG.PL}),uiLogoDarkSetting:(0,Kn.eB)(this.$store,J.HG.LOGO_DARK,""),uiLogoLightSetting:(0,Kn.eB)(this.$store,J.HG.LOGO_LIGHT,""),uiColorSetting:(0,Kn.eB)(this.$store,J.HG.PRIMARY_COLOR,""),uiLinkColorSetting:(0,Kn.eB)(this.$store,J.HG.LINK_COLOR,""),uiFaviconSetting:(0,Kn.eB)(this.$store,J.HG.FAVICON,"")});if(Object.assign(this,e),e.uiLogoDarkSetting.value)try{this.uiLogoDark=e.uiLogoDarkSetting.value,this.customizeLogo=!0}catch{}if(e.uiLogoLightSetting.value)try{this.uiLogoLight=e.uiLogoLightSetting.value,this.customizeLogo=!0}catch{}if(e.uiFaviconSetting.value)try{this.uiFavicon=e.uiFaviconSetting.value,this.customizeFavicon=!0}catch{}e.uiColorSetting.value&&(this.uiColor=tr(e.uiColorSetting.value).hex(),this.customizeColor=!0),e.uiLinkColorSetting.value&&(this.uiLinkColor=tr(e.uiLinkColorSetting.value).hex(),this.customizeLinkColor=!0)},data(){return{vendor:(0,te.f7)(),uiPLSetting:{},privateLabelDraft:null,uiLogoDarkSetting:{},uiLogoDark:"",uiLogoLightSetting:{},uiLogoLight:"",customizeLogo:!1,uiFaviconSetting:{},uiFavicon:"",customizeFavicon:!1,uiColorSetting:{},uiColor:null,customizeColor:!1,uiLinkColorSetting:{},uiLinkColor:null,customizeLinkColor:!1,errors:[]}},computed:{isHarvesterPrime(){return!!this.$store.getters["harvester-common/isHarvesterPrime"]},privateLabel:{get(){return this.privateLabelDraft??(this.isHarvesterPrime?this.$store.getters["harvester-common/privateLabel"]:this.uiPLSetting.value)},set(e){this.privateLabelDraft=e}},mode(){const e=this.$store.getters["management/schemaFor"](Z.Mc.SETTING);return e?.resourceMethods?.includes("PUT")?Vn.G5:Vn.nW},customLinkColor(){return{color:this.uiLinkColor}}},mounted(){let e=getComputedStyle(document.body).getPropertyValue("--primary"),t=getComputedStyle(document.body).getPropertyValue("--link");const n=document.querySelector(".suse");n&&(e=getComputedStyle(n).getPropertyValue("--primary"),t=getComputedStyle(n).getPropertyValue("--link")),this.uiColor=this.uiColor||e.trim(),this.uiLinkColor=this.uiLinkColor||t.trim()},methods:{updateLogo(e,t){this[t]=e},setError(e){this.errors=[],this.errors.push(e)},async save(e){this.uiPLSetting.value=(this.privateLabel||"").replaceAll(/[\<>&=#()"]/gm,""),this.customizeLogo?(this.uiLogoLightSetting.value=this.uiLogoLight,this.uiLogoDarkSetting.value=this.uiLogoDark):(this.uiLogoLightSetting.value="",this.uiLogoDarkSetting.value=""),this.customizeFavicon?this.uiFaviconSetting.value=this.uiFavicon:this.uiFaviconSetting.value="",this.customizeColor?this.uiColorSetting.value=tr(this.uiColor).rgb().string():this.uiColorSetting.value=null,this.customizeLinkColor?this.uiLinkColorSetting.value=tr(this.uiLinkColor).rgb().string():this.uiLinkColorSetting.value=null,this.errors=[];try{await Promise.all([this.uiPLSetting.save(),this.uiLogoDarkSetting.save(),this.uiLogoLightSetting.save(),this.uiColorSetting.save(),this.uiLinkColorSetting.save(),this.uiFaviconSetting.save()]),this.uiPLSetting.value!==this.vendor&&(0,te.xc)(this.uiPLSetting.value),Yn(this.$store),e(!0)}catch(t){this.errors.push(t),e(!1)}}}};o(5044);const rr=(0,u.A)(nr,[["render",Nn],["__scopeId","data-v-07e5f612"]]);var ir=rr;function or(e,t,n,r,o,a){const s=(0,i.resolveComponent)("ResourceDetail");return(0,i.openBlock)(),(0,i.createBlock)(s)}var ar=o(3049),sr={name:"HarvesterResourceCreate",components:{ResourceDetail:ar.A}};const lr=(0,u.A)(sr,[["render",or]]);var cr=lr;function ur(e,t,n,r,o,a){const s=(0,i.resolveComponent)("ResourceDetail");return(0,i.openBlock)(),(0,i.createBlock)(s)}var dr={name:"HarvesterResourcedId",components:{ResourceDetail:ar.A}};const hr=(0,u.A)(dr,[["render",ur]]);var pr=hr;function fr(e,t,n,r,o,a){const s=(0,i.resolveComponent)("ResourceDetail");return(0,i.openBlock)(),(0,i.createBlock)(s)}var mr={name:"HarvesterResourcedNamespaceId",components:{ResourceDetail:ar.A}};const gr=(0,u.A)(mr,[["render",fr]]);var vr=gr;const br={key:0,id:"air-gap"},yr={class:"mb-20"},wr={key:3,class:"mt-10 mb-10"},Or={key:1,class:"mb-20"},Sr={key:4},Er={key:1,class:"chooseFile"},xr=["disabled"],_r={key:6,class:"mt-20"};function kr(e,t,n,r,o,a){const s=(0,i.resolveComponent)("RadioGroup"),l=(0,i.resolveComponent)("UpgradeInfo"),c=(0,i.resolveComponent)("Banner"),u=(0,i.resolveComponent)("Checkbox"),d=(0,i.resolveComponent)("LabeledInput"),h=(0,i.resolveComponent)("ImagePercentageBar"),p=(0,i.resolveComponent)("LabeledSelect"),f=(0,i.resolveComponent)("CruResource");return o.value?((0,i.openBlock)(),(0,i.createElementBlock)("div",br,[(0,i.createElementVNode)("h3",yr,(0,i.toDisplayString)(e.t("harvester.upgradePage.osUpgrade")),1),(0,i.createVNode)(f,{"done-route":a.doneRoute,resource:o.value,mode:"create",errors:o.errors,"can-yaml":!1,"finish-button-mode":"upgrade","validation-passed":a.enableUpgrade,"cancel-event":!0,onFinish:a.save,onCancel:a.done,onError:t[11]||(t[11]=e=>o.errors=e)},{default:(0,i.withCtx)(()=>[(0,i.createVNode)(s,{value:o.imageSource,"onUpdate:value":t[0]||(t[0]=e=>o.imageSource=e),class:"image-group",name:"image",options:[o.IMAGE_METHOD.NEW,o.IMAGE_METHOD.EXIST,o.IMAGE_METHOD.DELETE],labels:[e.t("harvester.upgradePage.uploadNew"),e.t("harvester.upgradePage.selectExisting"),e.t("harvester.upgradePage.deleteExisting")]},null,8,["value","options","labels"]),a.createNewImage||a.selectExistImage?((0,i.openBlock)(),(0,i.createBlock)(l,{key:0})):(0,i.createCommentVNode)("",!0),a.showUploadSuccessBanner?((0,i.openBlock)(),(0,i.createBlock)(c,{key:1,color:"success",class:"mt-0 mb-30",label:e.t("harvester.setting.upgrade.uploadSuccess",{name:a.fileName})},null,8,["label"])):(0,i.createCommentVNode)("",!0),a.showUploadingWarningBanner?((0,i.openBlock)(),(0,i.createBlock)(c,{key:2,color:"warning",class:"mt-0 mb-30",label:e.t("harvester.image.warning.osUpgrade.uploading",{name:a.fileName})},null,8,["label"])):(0,i.createCommentVNode)("",!0),a.showUpgradeOptions?((0,i.openBlock)(),(0,i.createElementBlock)("div",wr,[a.canEnableLogging?((0,i.openBlock)(),(0,i.createBlock)(u,{key:0,value:o.enableLogging,"onUpdate:value":t[1]||(t[1]=e=>o.enableLogging=e),class:"check mb-20",type:"checkbox",label:e.t("harvester.upgradePage.enableLogging")},null,8,["value","label"])):(0,i.createCommentVNode)("",!0),a.skipSingleReplicaDetachedVolFeatureEnabled?((0,i.openBlock)(),(0,i.createElementBlock)("div",Or,[(0,i.createVNode)(u,{value:o.skipSingleReplicaDetachedVol,"onUpdate:value":t[2]||(t[2]=e=>o.skipSingleReplicaDetachedVol=e),class:"check",type:"checkbox",label:e.t("harvester.upgradePage.skipSingleReplicaDetachedVol")},null,8,["value","label"])])):(0,i.createCommentVNode)("",!0)])):(0,i.createCommentVNode)("",!0),a.createNewImage?((0,i.openBlock)(),(0,i.createElementBlock)("div",Sr,[(0,i.createVNode)(d,{value:o.imageValue.spec.displayName,"onUpdate:value":t[3]||(t[3]=e=>o.imageValue.spec.displayName=e),valueModifiers:{trim:!0},class:"mb-20","label-key":"harvester.fields.name",required:""},null,8,["value"]),(0,i.createVNode)(d,{value:o.imageValue.spec.checksum,"onUpdate:value":t[4]||(t[4]=e=>o.imageValue.spec.checksum=e),class:"mb-10","label-key":"harvester.setting.upgrade.checksum"},null,8,["value"]),(0,i.createVNode)(s,{value:o.sourceType,"onUpdate:value":t[5]||(t[5]=e=>o.sourceType=e),class:"mb-20 image-group",name:"sourceType",options:["upload","download"],labels:[e.t("harvester.image.sourceType.upload"),e.t("harvester.image.sourceType.download")]},null,8,["value","labels"]),"download"===o.sourceType?((0,i.openBlock)(),(0,i.createBlock)(d,{key:0,value:o.imageValue.spec.url,"onUpdate:value":t[6]||(t[6]=e=>o.imageValue.spec.url=e),valueModifiers:{trim:!0},class:"labeled-input--tooltip",required:"","label-key":"harvester.image.url"},null,8,["value"])):((0,i.openBlock)(),(0,i.createElementBlock)("div",Er,[(0,i.createElementVNode)("button",{type:"button",class:"btn role-primary",disabled:a.disableUploadButton,onClick:t[8]||(t[8]=(...e)=>a.selectFile&&a.selectFile(...e))},[(0,i.createTextVNode)((0,i.toDisplayString)(e.t("harvester.image.uploadFile"))+" ",1),(0,i.withDirectives)((0,i.createElementVNode)("input",{id:"file",ref:"file",type:"file",accept:".iso",onChange:t[7]||(t[7]=e=>a.handleFileUpload())},null,544),[[i.vShow,!1]])],8,xr),(0,i.createElementVNode)("span",{class:(0,i.normalizeClass)([{"text-muted":!a.fileName},"ml-20"])},(0,i.toDisplayString)(a.fileName?a.fileName:e.t("harvester.generic.noFileChosen")),3)])),a.showProgressBar?((0,i.openBlock)(),(0,i.createBlock)(h,{key:2,class:"mt-20",value:a.uploadProgress},null,8,["value"])):(0,i.createCommentVNode)("",!0)])):(0,i.createCommentVNode)("",!0),a.selectExistImage?((0,i.openBlock)(),(0,i.createBlock)(p,{key:5,value:o.imageId,"onUpdate:value":t[9]||(t[9]=e=>o.imageId=e),options:a.osImageOptions,required:"",class:"mb-20","label-key":"harvester.fields.image"},null,8,["value","options"])):(0,i.createCommentVNode)("",!0),a.deleteExistImage?((0,i.openBlock)(),(0,i.createElementBlock)("div",_r,[(0,i.createVNode)(c,{color:"info",class:"mt-10 mb-30",label:e.t("harvester.upgradePage.deleteHeader")},null,8,["label"]),(0,i.createVNode)(p,{value:o.deleteImageId,"onUpdate:value":[t[10]||(t[10]=e=>o.deleteImageId=e),a.handleImageDelete],options:a.deleteOSImageOptions,required:"",class:"mb-20","label-key":"harvester.fields.image"},null,8,["value","options","onUpdate:value"])])):(0,i.createCommentVNode)("",!0)]),_:1},8,["done-route","resource","errors","validation-passed","onFinish","onCancel"])])):(0,i.createCommentVNode)("",!0)}var Cr=o(2922),Ar=o(10196),Tr=o(49452),Rr=o(99726),Nr=o(2602),Pr=o(17252);const Ir={key:0,class:"parent"},Mr={class:"progress-box"},Dr={class:"text"},Lr={key:1};function Br(e,t,n,r,o,a){const s=(0,i.resolveComponent)("ProgressBarMulti");return a.completed?((0,i.openBlock)(),(0,i.createElementBlock)("div",Lr,(0,i.toDisplayString)(e.t("generic.completed")),1)):((0,i.openBlock)(),(0,i.createElementBlock)("div",Ir,[(0,i.createElementVNode)("div",Mr,[(0,i.createVNode)(s,{values:a.percentage,min:0,max:100},null,8,["values"])]),(0,i.createElementVNode)("div",Dr,(0,i.toDisplayString)(n.value||0)+"% ",1)]))}var $r=o(74315),Vr={components:{ProgressBarMulti:$r.A},props:{value:{type:[String,Number],default:0},row:{type:Object,default:()=>{}},col:{type:Object,default:()=>{}}},computed:{percentage(){const e=Number.parseFloat(this.value);let t="bg-success";return 0===e?t="bg-secondary":e<30?t="bg-darker":e<70&&(t="bg-warning"),[{value:e,color:t}]},completed(){return 100===Number.parseFloat(this.value)}}};o(63607);const Fr=(0,u.A)(Vr,[["render",Br],["__scopeId","data-v-5ad5aa7a"]]);var jr=Fr,Ur=o(3514),Gr=o.n(Ur),Hr=o(4364);const qr={NEW:"new",EXIST:"exist",DELETE:"delete"},Qr="download",zr="upload";var Kr={name:"HarvesterAirgapUpgrade",components:{Checkbox:Hn.S,CruResource:Cr.A,LabeledSelect:Tr.A,LabeledInput:Pn.o,RadioGroup:Ar.z,UpgradeInfo:Pr.A,ImagePercentageBar:jr,Banner:zn.l},inheritAttrs:!1,async fetch(){await this.$store.dispatch("harvester/findAll",{type:l.rk.IMAGE});const e=await this.$store.dispatch("harvester/create",{type:l.rk.UPGRADE,metadata:{generateName:"hvst-upgrade-",namespace:"harvester-system"},spec:{image:""}});await this.initImageValue(),this.value=e},beforeUnmount(){this.uploadController&&this.uploadController.abort()},data(){return{value:null,file:{},uploadImageId:"",imageId:"",deleteImageId:"",imageSource:qr.NEW,sourceType:zr,uploadController:null,uploadResult:null,imageValue:null,enableLogging:!0,IMAGE_METHOD:qr,skipSingleReplicaDetachedVol:!1,errors:[]}},computed:{doneRoute(){return`${r.KR}-c-cluster-resource`},skipSingleReplicaDetachedVolFeatureEnabled(){return this.$store.getters["harvester-common/getFeatureEnabled"]("skipSingleReplicaDetachedVol")},allOSImages(){return this.$store.getters["harvester/all"](l.rk.IMAGE).filter(e=>e.isOSImage)||[]},deleteOSImageOptions(){return this.allOSImages.map(e=>({label:e.spec.displayName,value:e.id}))},osImageOptions(){return this.allOSImages.map(e=>({label:e.spec.displayName,value:e.id,disabled:!e.isReady}))},createNewImage(){return this.imageSource===qr.NEW},selectExistImage(){return this.imageSource===qr.EXIST},deleteExistImage(){return this.imageSource===qr.DELETE},fileName(){return this.preprocessImageName(this.file?.name||"")},canEnableLogging(){return this.$store.getters["harvester/schemaFor"](l.rk.UPGRADE_LOG)},uploadProgress(){const e=this.$store.getters["harvester/byId"](l.rk.IMAGE,this.imageValue.id);return e?.status?.progress},enableUpgrade(){return!this.deleteExistImage&&(this.sourceType===Qr||(this.sourceType!==zr||(""===this.fileName||100===this.uploadProgress)))},isUploading(){return""!==this.fileName&&100!==this.uploadProgress},showProgressBar(){return this.createNewImage&&this.sourceType===zr&&this.isUploading},showUploadSuccessBanner(){return this.createNewImage&&""!==this.fileName&&Gr()(this.errors)&&!this.showUploadingWarningBanner&&200===this.uploadResult?._status},showUploadingWarningBanner(){return this.createNewImage&&this.isUploading},showUpgradeOptions(){return this.createNewImage||this.selectExistImage},disableUploadButton(){return this.sourceType===zr&&this.isUploading}},methods:{done(){this.uploadController&&this.uploadController.abort(),this.$router.push({name:this.doneRoute,params:{resource:l.rk.SETTING,product:"harvester"}})},async initImageValue(){this.imageValue=await this.$store.dispatch("harvester/create",{type:l.rk.IMAGE,metadata:{name:"",namespace:"harvester-system",generateName:"image-",annotations:{}},spec:{backend:"cdi",sourceType:zr,displayName:"",checksum:this.imageValue?.spec?.checksum||""}})},async save(e){let t=null;this.file={},this.errors=[];const n=this.imageValue?.spec?.displayName||"";if(!n&&this.createNewImage)return this.errors.push(this.$store.getters["i18n/t"]("validation.required",{key:this.t("generic.name")})),void e(!1);try{if(this.imageSource===qr.NEW){if(this.imageValue.metadata.annotations[Nr.r.OS_UPGRADE_IMAGE]="True",this.sourceType===zr&&""!==this.uploadImageId)this.value.spec.image=this.uploadImageId;else if(this.sourceType===Qr){if(!this.imageValue.spec.url)return this.errors.push(this.$store.getters["i18n/t"]("harvester.setting.upgrade.imageUrl")),void e(!1);this.imageValue.spec.sourceType=Qr,this.imageValue.spec.targetStorageClassName="longhorn-static",t=await this.imageValue.save(),t.notifyGeneratedName?.(),this.value.spec.image=t.id}}else if(this.imageSource===qr.EXIST){if(!this.imageId)return this.errors.push(this.$store.getters["i18n/t"]("harvester.setting.upgrade.chooseFile")),void e(!1);this.value.spec.image=this.imageId}this.canEnableLogging&&(this.value.spec.logEnabled=this.enableLogging),this.skipSingleReplicaDetachedVolFeatureEnabled&&(this.value.metadata.annotations={[Nr.r.SKIP_SINGLE_REPLICA_DETACHED_VOL]:JSON.stringify(this.skipSingleReplicaDetachedVol)}),await this.value.save(),this.value.notifyGeneratedName?.(),this.done(),e(!0)}catch(r){this.errors=[r?.message]||0,e(!1)}},async uploadFile(e){const t=this.preprocessImageName(e.name);if(!t)return void this.errors.push(this.$store.getters["i18n/t"]("harvester.setting.upgrade.unknownImageName"));const n=this.allOSImages.some(e=>e.spec.displayName===t);if(n)return this.errors.push(this.$store.getters["i18n/t"]("harvester.upgradePage.upload.duplicatedFile")),void(this.file={});this.errors=[],this.imageValue.spec.sourceType=zr,this.imageValue.spec.displayName=t,this.imageValue.metadata.annotations[Nr.r.OS_UPGRADE_IMAGE]="True",this.imageValue.metadata.annotations[Nr.r.IMAGE_NAME]=t,this.imageValue.spec.url="";try{this.imageValue.spec.targetStorageClassName="longhorn-static";const t=await this.imageValue.save();t.notifyGeneratedName?.(),this.uploadImageId=t.id,this.uploadController=new AbortController;const n=this.uploadController.signal;this.uploadResult=await t.uploadImage(e,{signal:n})}catch(r){"ERR_NETWORK"===r?.code?this.errors.push(this.$store.getters["i18n/t"]("harvester.setting.upgrade.networkError")):"ERR_CANCELED"===r?.code?this.errors.push(this.$store.getters["i18n/t"]("harvester.setting.upgrade.cancelUpload")):this.errors=(0,Rr.rz)(r),this.file={},this.uploadImageId=""}},preprocessImageName(e){return e?e.toLowerCase().replace(/[_]/g,"-"):""},handleImageDelete(e){const t=this.allOSImages.find(t=>t.id===e),n=t?.spec?.displayName||"";t&&n&&(this.$store.dispatch("harvester/promptModal",{resources:[t],component:"ConfirmRelatedToRemoveDialog",needConfirmation:!1,warningMessage:this.$store.getters["i18n/t"]("harvester.modal.osImage.message",{name:n})}),this.deleteImageId="")},async handleFileUpload(){this.uploadImageId="",this.errors=[],this.file=this.$refs.file?.files[0],this.file&&(await this.initImageValue(),await this.uploadFile(this.file))},selectFile(){this.$refs.file.value=null,this.$refs.file.click()}},watch:{async sourceType(e){if(e===Qr&&this.imageValue&&this.uploadController){this.uploadController&&this.uploadController.abort();try{await this.imageValue.remove(),await this.initImageValue()}catch(Rr){Hr.error("Error occurred while removing imageValue:",Rr)}}},imageSource(e){e!==qr.DELETE&&(this.deleteImageId="")},"imageValue.spec.url":{handler(e){const t=e?.split("/")?.pop(),n=t?.split(".")||[],r=n?.pop()?.toLowerCase();n.length>1&&"iso"===r&&t!==this.imageValue.spec.displayName&&(this.imageValue.spec.displayName=t)},deep:!0},file(e){e.name&&e.name!==this.imageValue.spec.displayName&&(this.imageValue.spec.displayName=e.name)}}};o(19524);const Wr=(0,u.A)(Kr,[["render",kr],["__scopeId","data-v-cb2a8aec"]]);var Xr=Wr;function Yr(e,t,n,r,o,a){const s=(0,i.resolveComponent)("Members");return(0,i.openBlock)(),(0,i.createBlock)(s,(0,i.mergeProps)({"create-location-override":a.createLocationOverride},e.$attrs),null,16,["create-location-override"])}const Zr={class:"project-members"},Jr={key:0,class:"row mb-10 cluster-add"};function ei(e,t,n,r,o,a){const s=(0,i.resolveComponent)("Masthead"),l=(0,i.resolveComponent)("Banner"),c=(0,i.resolveComponent)("router-link"),u=(0,i.resolveComponent)("ResourceTable"),d=(0,i.resolveComponent)("Tab"),h=(0,i.resolveComponent)("Tabbed");return(0,i.openBlock)(),(0,i.createElementBlock)("div",Zr,[(0,i.createVNode)(s,{schema:o.schema,resource:o.resource,"favorite-resource":o.VIRTUAL_TYPES.CLUSTER_MEMBERS,"create-location":o.createLocation,"create-button-label":e.t("members.createActionLabel"),"is-creatable":!1,"type-display":e.t("members.clusterAndProject")},null,8,["schema","resource","favorite-resource","create-location","create-button-label","type-display"]),a.isLocal?((0,i.openBlock)(),(0,i.createBlock)(l,{key:0,color:"error",label:e.t("members.localClusterWarning")},null,8,["label"])):(0,i.createCommentVNode)("",!0),(0,i.createVNode)(h,null,{default:(0,i.withCtx)(()=>[(0,i.createVNode)(d,{name:"cluster-membership",label:e.t("members.clusterMembership")},{default:(0,i.withCtx)(()=>[a.canEditClusterMembers?((0,i.openBlock)(),(0,i.createElementBlock)("div",Jr,[(0,i.createVNode)(c,{to:o.createLocation,class:"btn role-primary pull-right"},{default:(0,i.withCtx)(()=>[(0,i.createTextVNode)((0,i.toDisplayString)(e.t("members.createActionLabel")),1)]),_:1},8,["to"])])):(0,i.createCommentVNode)("",!0),(0,i.createVNode)(u,{schema:o.schema,headers:o.headers,rows:a.filteredClusterRoleTemplateBindings,groupable:!0,"show-grouping":!0,namespaced:!1,loading:e.$fetchState.pending||!e.currentCluster||o.loadingClusterBindings,"sub-search":"subSearch","sub-fields":["nameDisplay"]},null,8,["schema","headers","rows","loading"])]),_:1},8,["label"])]),_:1})])}var ti=o(31085),ni=o(74887),ri=o(68774),ii=o(15554),oi=o(94681),ai=o(97955),si={name:"Members",components:{Banner:ii.A,Masthead:ni.A,ResourceTable:ti.A,Tabbed:oi.A,Tab:ai.A},props:{createLocationOverride:{type:Object,default:()=>({name:"c-cluster-product-resource-create",params:{resource:Z.Mc.CLUSTER_ROLE_TEMPLATE_BINDING}})}},async fetch(){const e=this.$store.getters["rancher/schemaFor"](Z.k$.CLUSTER_ROLE_TEMPLATE_BINDING),t=this.$store.getters["rancher/schemaFor"](Z.k$.PROJECT_ROLE_TEMPLATE_BINDING);this["normanClusterRTBSchema"]=e,this["normanProjectRTBSchema"]=t,e&&Promise.all([this.$store.dispatch("rancher/findAll",{type:Z.k$.CLUSTER_ROLE_TEMPLATE_BINDING},{root:!0}),this.$store.dispatch("management/findAll",{type:Z.Mc.CLUSTER_ROLE_TEMPLATE_BINDING})]).then(([e])=>{this["normanClusterRoleTemplateBindings"]=e,this.loadingClusterBindings=!1}),t&&this.$store.dispatch("rancher/findAll",{type:Z.k$.PROJECT_ROLE_TEMPLATE_BINDING},{root:!0}).then(e=>{this["projectRoleTemplateBindings"]=e,this.loadingProjectBindings=!1});const n={normanPrincipals:this.$store.dispatch("rancher/findAll",{type:Z.k$.PRINCIPAL}),mgmt:this.$store.dispatch("management/findAll",{type:Z.Mc.USER}),mgmtRoleTemplates:this.$store.dispatch("management/findAll",{type:Z.Mc.ROLE_TEMPLATE})};await(0,ne.kR)(n)},data(){return{schema:this.$store.getters["management/schemaFor"](Z.Mc.CLUSTER_ROLE_TEMPLATE_BINDING),headers:[ri.c4,ri.nv,ri.z7,ri.K],createLocation:{...this.createLocationOverride,params:{...this.createLocationOverride.params,cluster:this.$store.getters["currentCluster"].id}},resource:Z.Mc.CLUSTER_ROLE_TEMPLATE_BINDING,normanClusterRTBSchema:null,normanProjectRTBSchema:null,normanClusterRoleTemplateBindings:[],projectRoleTemplateBindings:[],VIRTUAL_TYPES:Z.cG,projectRoleTemplateColumns:[ri.c4,{name:"member",labeKey:"generic.name",value:"principalId",formatter:"Principal"},{name:"role",labelKey:"tableHeaders.role",value:"roleTemplate.nameDisplay"}],loadingProjectBindings:!0,loadingClusterBindings:!0}},computed:{...(0,R.L8)(["currentCluster"]),clusterRoleTemplateBindings(){return this.normanClusterRoleTemplateBindings.map(e=>e.clusterroletemplatebinding)},filteredClusterRoleTemplateBindings(){return this.clusterRoleTemplateBindings.filter(e=>e?.clusterName===this.$store.getters["currentCluster"].id)},isLocal(){return this.$store.getters["currentCluster"].isLocal},canEditClusterMembers(){return this.schema?.collectionMethods.find(e=>"post"===e.toLowerCase())}}};o(22728);const li=(0,u.A)(si,[["render",ei],["__scopeId","data-v-54d15ef1"]]);var ci=li,ui={components:{Members:ci},inheritAttrs:!1,computed:{createLocationOverride(){return{name:`${r.KR}-c-cluster-resource-create`,params:{product:r.KR,cluster:this.$store.getters["currentCluster"]?.id,resource:Z.Mc.CLUSTER_ROLE_TEMPLATE_BINDING}}}}};const di=(0,u.A)(ui,[["render",Yr]]);var hi=di;function pi(e,t,n,r,o,a){const s=(0,i.resolveComponent)("ExplorerProjectsNamespaces");return(0,i.openBlock)(),(0,i.createBlock)(s,(0,i.mergeProps)(e.$attrs,{"create-project-location-override":o.createProjectLocation,"create-namespace-location-override":o.createNamespaceLocation}),null,16,["create-project-location-override","create-namespace-location-override"])}const fi={class:"project-namespaces outlet"},mi={class:"group-tab"},gi={class:"project-name"},vi={key:0,class:"description text-muted text-small"},bi={class:"right mr-10"},yi={key:1,class:"invisible"},wi={key:0},Oi={key:1,class:"text-muted"},Si={class:"namespace-name"},Ei={key:1},xi={key:2,class:"icon icon-istio ml-5"},_i={key:3,class:"icon icon-lock ml-5"},ki={class:"main-row"},Ci=["colspan"],Ai={class:"main-row"},Ti=["colspan"];function Ri(e,t,n,r,o,a){const s=(0,i.resolveComponent)("rc-button"),l=(0,i.resolveComponent)("Masthead"),c=(0,i.resolveComponent)("ExtensionPanel"),u=(0,i.resolveComponent)("ActionMenu"),d=(0,i.resolveComponent)("ButtonMultiAction"),h=(0,i.resolveComponent)("router-link"),p=(0,i.resolveComponent)("ResourceTable"),f=(0,i.resolveDirective)("clean-html"),m=(0,i.resolveDirective)("trim-whitespace"),g=(0,i.resolveDirective)("clean-tooltip");return(0,i.openBlock)(),(0,i.createElementBlock)("div",fi,[(0,i.createVNode)(l,{schema:o.projectSchema,"type-display":e.t("projectNamespaces.label"),resource:o.MANAGEMENT.PROJECT,"favorite-resource":o.VIRTUAL_TYPES.PROJECT_NAMESPACES,"create-location":a.createProjectLocation,"create-button-label":e.t("projectNamespaces.createProject"),"show-incremental-loading-indicator":a.showIncrementalLoadingIndicator,"load-resources":o.loadResources,"load-indeterminate":o.loadIndeterminate},(0,i.createSlots)({_:2},[a.showCreateNsButton?{name:"extraActions",fn:(0,i.withCtx)(()=>[(0,i.createVNode)(s,{size:"large",class:"mr-10",to:a.createNamespaceLocationFlatList(),"data-testid":"create_project_namespaces"},{default:(0,i.withCtx)(()=>[(0,i.createTextVNode)((0,i.toDisplayString)(e.t("projectNamespaces.createNamespace")),1)]),_:1},8,["to"])]),key:"0"}:void 0]),1032,["schema","type-display","resource","favorite-resource","create-location","create-button-label","show-incremental-loading-indicator","load-resources","load-indeterminate"]),(0,i.createVNode)(c,{resource:{},type:o.extensionType,location:o.extensionLocation},null,8,["type","location"]),(0,i.createVNode)(p,(0,i.mergeProps)({ref:"table"},{...e.$attrs,class:null},{class:"table project-namespaces-table",schema:o.schema,headers:a.headers,rows:a.filteredRows,"group-by":a.projectGroupBy,"group-options":o.groupOptions,groupable:!0,"sort-generation-fn":a.sortGenerationFn,loading:a.loading,"group-tooltip":"resourceTable.groupBy.project","key-field":"_key",onGroupChange:t[0]||(t[0]=e=>o.tableGroup=e)}),(0,i.createSlots)({"group-by":(0,i.withCtx)(t=>[(0,i.createElementVNode)("div",{class:(0,i.normalizeClass)(["project-bar",{"has-description":a.projectDescription(t.group)}])},[(0,i.withDirectives)(((0,i.openBlock)(),(0,i.createElementBlock)("div",mi,[(0,i.withDirectives)((0,i.createElementVNode)("div",gi,null,512),[[f,a.projectLabel(t.group)]]),a.projectDescription(t.group)?((0,i.openBlock)(),(0,i.createElementBlock)("div",vi,(0,i.toDisplayString)(a.projectDescription(t.group)),1)):(0,i.createCommentVNode)("",!0)])),[[m]]),(0,i.createElementVNode)("div",bi,[a.isNamespaceCreatable&&(a.canSeeProjectlessNamespaces||t.group.key!==a.notInProjectKey)?((0,i.openBlock)(),(0,i.createBlock)(s,{key:0,variant:"secondary",class:"mr-5",to:a.createNamespaceLocation(t.group)},{default:(0,i.withCtx)(()=>[(0,i.createTextVNode)((0,i.toDisplayString)(e.t("projectNamespaces.createNamespace")),1)]),_:1},8,["to"])):(0,i.createCommentVNode)("",!0),r.featureDropdownMenu?((0,i.openBlock)(),(0,i.createElementBlock)(i.Fragment,{key:1},[a.showProjectActionButton(t.group)?((0,i.openBlock)(),(0,i.createBlock)(u,{key:0,resource:a.getProjectActions(t.group),"data-testid":"action-button","button-aria-label":e.t("projectNamespaces.tableActionsLabel",{resource:a.projectResource(t.group)})},null,8,["resource","button-aria-label"])):((0,i.openBlock)(),(0,i.createElementBlock)("div",yi))],64)):((0,i.openBlock)(),(0,i.createBlock)(d,{key:2,class:"project-action",borderless:!0,"aria-label":e.t("projectNamespaces.tableActionsLabel",{resource:a.projectResource(t.group)}),invisible:!a.showProjectActionButton(t.group),onClick:e=>a.showProjectAction(e,t.group)},null,8,["aria-label","invisible","onClick"]))])],2)]),"cell:project":(0,i.withCtx)(({row:e})=>[e.project?((0,i.openBlock)(),(0,i.createElementBlock)("span",wi,(0,i.toDisplayString)(e.project.nameDisplay),1)):((0,i.openBlock)(),(0,i.createElementBlock)("span",Oi,"–"))]),"cell:name":(0,i.withCtx)(({row:t})=>[(0,i.createElementVNode)("div",Si,[t.detailLocation&&!t.hideDetailLocation?((0,i.openBlock)(),(0,i.createBlock)(h,{key:0,to:t.detailLocation},{default:(0,i.withCtx)(()=>[(0,i.createTextVNode)((0,i.toDisplayString)(t.name),1)]),_:2},1032,["to"])):((0,i.openBlock)(),(0,i.createElementBlock)("span",Ei,(0,i.toDisplayString)(t.name),1)),t.injectionEnabled?(0,i.withDirectives)(((0,i.openBlock)(),(0,i.createElementBlock)("i",xi,null,512)),[[g,e.t("projectNamespaces.isIstioInjectionEnabled")]]):(0,i.createCommentVNode)("",!0),t.hasSystemLabels?(0,i.withDirectives)(((0,i.openBlock)(),(0,i.createElementBlock)("i",_i,null,512)),[[g,a.getPsaTooltip(t)]]):(0,i.createCommentVNode)("",!0)])]),"main-row:fake-empty":(0,i.withCtx)(({fullColspan:t})=>[(0,i.createElementVNode)("tr",Ai,[(0,i.createElementVNode)("td",{class:"empty text-center",colspan:t},(0,i.toDisplayString)(e.t("projectNamespaces.noProjectNoNamespaces")),9,Ti)])]),_:2},[(0,i.renderList)(a.projectsWithoutNamespaces,(t,n)=>({name:a.slotName(t),fn:(0,i.withCtx)(({fullColspan:t})=>[(0,i.createElementVNode)("tr",ki,[(0,i.createElementVNode)("td",{class:"empty text-center",colspan:t},(0,i.toDisplayString)(e.t("projectNamespaces.noNamespaces")),9,Ci)])])}))]),1040,["schema","headers","rows","group-by","group-options","sort-generation-fn","loading"])])}var Ni=o(68851),Pi=o(31915),Ii=o(10312),Mi=o(56601),Di=o(92043),Li=o(18110),Bi=o(23667),$i=o(11518),Vi=o(81268),Fi=o(10257),ji=o(76204),Ui=o(75886),Gi=o(51433),Hi={name:"ListProjectNamespace",components:{ExtensionPanel:Ii.A,Masthead:ni.A,ResourceTable:ti.A,ButtonMultiAction:Mi.A,ActionMenu:ji.A,RcButton:Gi.a},mixins:[Bi.A],props:{createProjectLocationOverride:{type:Object,default:()=>null},createNamespaceLocationOverride:{type:Object,default:()=>null}},async fetch(){const e=this.$store.getters["currentStore"](Z.CU);this.harvesterResourceQuotaSchema=this.$store.getters[`${e}/schemaFor`](Z.rk.RESOURCE_QUOTA),this.schema=this.$store.getters[`${e}/schemaFor`](Z.CU),this.projectSchema=this.$store.getters["management/schemaFor"](Z.Mc.PROJECT),this.schema&&(await this.$fetchType(Z.CU),this.projects=await this.$store.dispatch("management/findAll",{type:Z.Mc.PROJECT,opt:{force:!0}}))},setup(){const e=(0,R.Pj)(),{featureDropdownMenu:t}=(0,Ui.K)(e);return{featureDropdownMenu:t}},data(){return{loadResources:[Z.CU],loadIndeterminate:!0,harvesterResourceQuotaSchema:null,schema:null,projects:[],projectSchema:null,extensionType:Pi.c7.PANEL,tableGroup:null,groupOptions:[{tooltipKey:"resourceTable.groupBy.none",icon:"icon-list-flat",value:"none"},{tooltipKey:"resourceTable.groupBy.project",icon:"icon-folder",value:"namespace",field:"groupById",hideColumn:"project"}],extensionLocation:Pi.W7.RESOURCE_LIST,MANAGEMENT:Z.Mc,VIRTUAL_TYPES:Z.cG,defaultCreateProjectLocation:{name:"c-cluster-product-resource-create",params:{product:this.$store.getters["currentProduct"].name,resource:Z.Mc.PROJECT}}}},watch:{actionCb:{handler(e){e?.moveNamespaceCb&&(this.clearSelection(),this.$store.dispatch("action-menu/clearCallbackData"))},immediate:!0}},computed:{...(0,R.L8)(["currentCluster","currentProduct"]),...(0,R.L8)({actionCb:"action-menu/performCallbackData"}),namespaces(){const e=this.$store.getters["currentStore"](Z.CU);return this.$store.getters[`${e}/all`](Z.CU)},loading(){return!(!this.currentCluster||this.namespaces.length)&&this.$fetchState.pending},showIncrementalLoadingIndicator(){return Fi.A.incrementalLoadingUtils.isEnabled(this.calcCanPaginate(),this.perfConfig)},isNamespaceCreatable(){return(this.schema?.collectionMethods||[]).includes("POST")},isHarvester(){return this.$store.getters["currentProduct"].inStore===$i.T3},headers(){let e;if("none"===this.groupMode||(0,Vi.Q_)(this.$store)){e=[ri.c4,ri.o_,ri.tC];const t={name:"project",label:this.t("tableHeaders.project"),value:"project.nameDisplay",sort:["projectNameSort","nameSort"]};e.push(t)}else e=[ri.c4,ri.RP,ri.tC];return this.isHarvester&&this.harvesterResourceQuotaSchema&&e.push(ri.Si),e.push(ri.K),e},projectIdsWithNamespaces(){const e=this.rows.map(e=>e.projectId).filter(e=>e);return(0,Ni.sb)(e)},clusterProjects(){const e=this.currentCluster?.id,t=this.$store.getters["management/all"](Z.Mc.PROJECT);if(this.currentProduct?.customNamespaceFilter&&this.currentProduct?.inStore&&this.$store.getters[`${this.currentProduct.inStore}/filterProject`])return this.$store.getters[`${this.currentProduct.inStore}/filterProject`];const n=t.filter(t=>t.spec.clusterName===e);return n},projectsWithoutNamespaces(){return this.activeProjects.filter(e=>!this.projectIdsWithNamespaces.find(t=>e?.id?.endsWith(`/${t}`)))},rowsWithFakeNamespaces(){const e=this.projectsWithoutNamespaces.map(e=>({groupById:`resourceTable.groupLabel.notInAProject-${e.id}`,isFake:!0,mainRowKey:e.id,projectNameDisplay:e.spec?.displayName,project:e,availableActions:[]}));return this.showMockNotInProjectGroup&&e.push({groupById:this.t("resourceTable.groupLabel.notInAProject"),mainRowKey:"fake-empty"}),[...this.rows,...e]},createProjectLocation(){return this.createProjectLocationOverride||this.defaultCreateProjectLocation},groupPreference:(0,N.AN)(N.EI),groupMode(){return(0,Vi.Q_)(this.$store)?this.tableGroup||"none":this.groupPreference},activeNamespaceFilters(){return this.$store.getters["activeNamespaceFilters"]},activeProjectFilters(){const e={};for(const t of this.activeNamespaceFilters){const[n,r]=t.split("://",2);"project"===n&&(e[r]=!0)}return e},activeProjects(){const e=this.$store.getters["activeNamespaceFilters"];return e.includes(Li.pF)&&0===Object.keys(this.activeProjectFilters).length?[]:this.userIsFilteringForSpecificNamespaceOrProject()?this.clusterProjects.filter(e=>{const t=e.id.split("/")[1];return!!this.activeProjectFilters[t]}):this.clusterProjects},activeNamespaces(){const e=this.$store.getters["namespaces"]();return this.namespaces.filter(t=>!!e[t.metadata.name])},filteredRows(){return"none"===this.groupMode?this.rows:this.rowsWithFakeNamespaces},rows(){let e;try{e=this.$store.getters["prefs/get"](N.Pz)}catch{e=this.$store.getters["prefs/get"](N.IJ)}return e?this.activeNamespaces:this.activeNamespaces.filter(e=>{const t=this.$store.getters["systemNamespaces"].includes(e.metadata.name),n=e.isSystem||e.isFleetManaged||t;return!this.currentProduct?.hideSystemResources||!n})},canSeeProjectlessNamespaces(){return this.currentCluster?.canUpdate},showMockNotInProjectGroup(){if(!this.canSeeProjectlessNamespaces)return!1;const e=!this.rows.some(e=>!e.project),t=this.userIsFilteringForSpecificNamespaceOrProject();return!t&&e},notInProjectKey(){return this.$store.getters["i18n/t"]("resourceTable.groupLabel.notInAProject")},showCreateNsButton(){return"namespace"!==this.groupMode&&this.isNamespaceCreatable},projectGroupBy(){return"none"===this.groupMode?null:"groupById"}},methods:{getPsaTooltip(e){const t=e.psaTooltipsDescription,n=Object.values(t).sort().map(e=>`<li>${e}</li>`).join(""),r=`<p>${this.t("podSecurityAdmission.name")}: </p>`;return`${r}<ul class="psa-tooltip">${n}</ul>`},userIsFilteringForSpecificNamespaceOrProject(){const e=this.$store.getters["namespaceFilters"];for(let t=0;t<e.length;t++){const n=e[t],r=n.split("://")[0];if("ns"===r||"project"===r)return!0}return!1},slotName(e){return`main-row:${e.id}`},createNamespaceLocation(e){const t=e.rows[0].project,n=this.createNamespaceLocationOverride?{...this.createNamespaceLocationOverride}:{name:"c-cluster-product-resource-create",params:{product:this.$store.getters["currentProduct"].name,resource:Z.CU}};return n.query={[Vn.iJ]:t?.metadata.name},n},createNamespaceLocationFlatList(){const e=this.createNamespaceLocationOverride?{...this.createNamespaceLocationOverride}:{name:"c-cluster-product-resource-create",params:{product:this.$store.getters["currentProduct"]?.name,resource:Z.CU}};return e.query={[Vn._N]:!0},e},getProjectActions(e){return e.rows[0].project},showProjectAction(e,t){const n=t.rows[0].project;this.$store.commit("action-menu/show",{resources:[n],elem:e.target})},showProjectActionButton(e){const t=e.rows[0].project;return!!t},projectLabel(e){const t=e.rows[0];if(t.isFake)return re.A.sanitize(this.t("resourceTable.groupLabel.project",{name:t.project?.nameDisplay},!0),{ALLOWED_TAGS:["span"]});if(t.groupById===this.notInProjectKey)return this.t("resourceTable.groupLabel.notInAProject");const n=t.project?.nameDisplay||t.project?.id||"";return this.t("resourceTable.groupLabel.project",{name:(0,Di.ZD)(n)},!0)},projectDescription(e){const t=e.rows[0].project;return t?.description},projectResource(e){const t=e.rows[0];return t.nameDisplay||t.id||""},clearSelection(){this.$refs.table.clearSelection()},sortGenerationFn(){const e=(0,ti.S)(this.schema,this.$store);return e+(this.showMockNotInProjectGroup?"-mock":"")}}};o(61883),o(10642);const qi=(0,u.A)(Hi,[["render",Ri],["__scopeId","data-v-d8cca17c"]]);var Qi=qi,zi={components:{ExplorerProjectsNamespaces:Qi},data(){return{createProjectLocation:{name:`${r.KR}-c-cluster-resource-create`,params:{product:r.KR,cluster:this.$store.getters["currentCluster"]?.id,resource:Z.Mc.PROJECT}},createNamespaceLocation:{name:`${r.KR}-c-cluster-resource-create`,params:{product:r.KR,resource:Z.CU}}}}};const Ki=(0,u.A)(zi,[["render",pi]]);var Wi=Ki;const Xi={class:"header"},Yi={class:"title"},Zi={class:"primaryheader"},Ji={class:"actions-container"},eo={class:"actions"};function to(e,t,n,r,o,a){const s=(0,i.resolveComponent)("ButtonGroup"),l=(0,i.resolveComponent)("ResourceYaml"),c=(0,i.resolveComponent)("ReceiverConfig"),u=(0,i.resolveComponent)("ActionMenu");return(0,i.openBlock)(),(0,i.createElementBlock)("div",null,[(0,i.createElementVNode)("header",Xi,[(0,i.createElementVNode)("div",Yi,[(0,i.createElementVNode)("div",Zi,[(0,i.createElementVNode)("h1",null,(0,i.toDisplayString)(a.heading),1)])]),(0,i.createElementVNode)("div",Ji,[(0,i.createElementVNode)("div",eo,[o.viewOptions&&a.mode===o.view?((0,i.openBlock)(),(0,i.createBlock)(s,{key:0,value:a.currentView,options:o.viewOptions,"onUpdate:value":a.handleButtonGroupClick},null,8,["value","options","onUpdate:value"])):(0,i.createCommentVNode)("",!0),a.mode===o.view?((0,i.openBlock)(),(0,i.createElementBlock)("button",{key:1,ref:"actions","aria-haspopup":"true",type:"button",class:"btn role-multi-action actions",onClick:t[0]||(t[0]=(...e)=>a.handleReceiverActionMenuClick&&a.handleReceiverActionMenuClick(...e))},[...t[3]||(t[3]=[(0,i.createElementVNode)("i",{class:"icon icon-actions"},null,-1)])],512)):(0,i.createCommentVNode)("",!0)])])]),a.currentView===o.yaml&&o.alertmanagerConfigResource?((0,i.openBlock)(),(0,i.createBlock)(l,{key:0,ref:"resourceyaml",value:o.alertmanagerConfigResource,mode:a.mode,"initial-yaml-for-diff":null,yaml:a.resourceYaml,"offer-preview":a.mode===o.edit,"done-route":JSON.stringify(a.redirectToReceiverDetail(o.receiverName)),"done-override":o.alertmanagerConfigDetailRoute,"apply-hooks":o.alertmanagerConfigResource.applyHooks,onError:t[1]||(t[1]=t=>e.$emit("error",t))},null,8,["value","mode","yaml","offer-preview","done-route","done-override","apply-hooks"])):(0,i.createCommentVNode)("",!0),a.currentView!==o.config&&a.currentView!==o.detail||!o.alertmanagerConfigResource?(0,i.createCommentVNode)("",!0):((0,i.openBlock)(),(0,i.createBlock)(c,{key:1,value:o.receiverValue,mode:a.mode,"alertmanager-config-id":o.alertmanagerConfigId,"alertmanager-config-resource":o.alertmanagerConfigResource,"save-override":a.saveOverride},null,8,["value","mode","alertmanager-config-id","alertmanager-config-resource","save-override"])),(0,i.createVNode)(u,{"custom-actions":a.receiverActions,open:o.receiverActionMenuIsOpen,"use-custom-target-element":!0,"custom-target-element":o.actionMenuTargetElement,"custom-target-event":o.actionMenuTargetEvent,onClose:t[2]||(t[2]=e=>o.receiverActionMenuIsOpen=!1),onGoToEdit:a.goToEdit,onGoToEditYaml:a.goToEditYaml,onPromptRemove:a.promptRemove},null,8,["custom-actions","open","custom-target-element","custom-target-event","onGoToEdit","onGoToEditYaml","onPromptRemove"])])}var no=o(69091);const ro={class:"row mb-10"},io={class:"col span-6"},oo={class:"box-container create-resource-container"},ao=["onClick"],so={class:"left"},lo={class:"logo"},co=["src"],uo={class:"name ml-10"},ho={key:0,class:"right"},po={key:1};function fo(e,t,n,r,o,a){const s=(0,i.resolveComponent)("LabeledInput"),l=(0,i.resolveComponent)("t"),c=(0,i.resolveComponent)("Tab"),u=(0,i.resolveComponent)("YamlEditor"),d=(0,i.resolveComponent)("ArrayListGrouped"),h=(0,i.resolveComponent)("Tabbed"),p=(0,i.resolveComponent)("CruResource");return(0,i.openBlock)(),(0,i.createBlock)(p,{class:"receiver","done-route":n.alertmanagerConfigResource._detailLocation,mode:n.mode,resource:n.alertmanagerConfigResource,subtypes:[],"can-yaml":!0,errors:e.errors,"cancel-event":!0,"validation-passed":e.fvFormIsValid,onError:t[2]||(t[2]=t=>e.errors=t),onFinish:n.saveOverride,onCancel:a.redirectAfterCancel},{default:(0,i.withCtx)(()=>[(0,i.createElementVNode)("div",ro,[(0,i.createElementVNode)("div",io,[(0,i.createVNode)(s,{value:n.value.name,"onUpdate:value":t[0]||(t[0]=e=>n.value.name=e),"is-disabled":a.receiverNameDisabled,label:e.t("generic.name"),required:!0,mode:n.mode,rules:e.fvGetAndReportPathRules("name"),"data-testid":"v2-monitoring-receiver-name"},null,8,["value","is-disabled","label","mode","rules"])])]),(0,i.createVNode)(h,{ref:"tabbed","side-tabs":!0,"default-tab":e.defaultTab||"overview","use-hash":n.useTabbedHash,onChanged:a.tabChanged},{default:(0,i.withCtx)(()=>[(0,i.createVNode)(c,{label:e.t("generic.overview"),weight:o.receiverTypes.length,name:"overview"},{default:(0,i.withCtx)(()=>[(0,i.createElementVNode)("div",oo,[((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,null,(0,i.renderList)(o.receiverTypes,(e,t)=>((0,i.openBlock)(),(0,i.createElementBlock)("div",{key:t,class:"mb-10 subtype-banner","primary-color-var":"--primary-color",onClick:t=>a.navigateTo(e)},[(0,i.createElementVNode)("div",so,[(0,i.createElementVNode)("div",lo,[(0,i.createElementVNode)("img",{src:e.logo},null,8,co)]),(0,i.createElementVNode)("h4",uo,[(0,i.createVNode)(l,{k:e.label},null,8,["k"])])]),"custom"!==e.name?((0,i.openBlock)(),(0,i.createElementBlock)("div",ho,(0,i.toDisplayString)(a.getCount(e)),1)):(0,i.createCommentVNode)("",!0)],8,ao))),128))])]),_:1},8,["label","weight"]),((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,null,(0,i.renderList)(o.receiverTypes,(r,s)=>((0,i.openBlock)(),(0,i.createBlock)(c,{key:s,label:e.t(r.label),name:r.name,weight:o.receiverTypes.length-s},{default:(0,i.withCtx)(()=>["custom"===r.name?((0,i.openBlock)(),(0,i.createBlock)(u,{key:0,ref_for:!0,ref:"customEditor",value:e.suffixYaml,"onUpdate:value":t[1]||(t[1]=t=>e.suffixYaml=t),scrolling:!1,"editor-mode":a.editorMode},null,8,["value","editor-mode"])):((0,i.openBlock)(),(0,i.createElementBlock)("div",po,[(0,i.createVNode)(d,{value:n.value[r.key],"onUpdate:value":e=>n.value[r.key]=e,class:"namespace-list",mode:n.mode,"default-add-value":{},"add-label":e.t("monitoringReceiver.addButton",{type:e.t(r.label)})},{default:(0,i.withCtx)(e=>[((0,i.openBlock)(),(0,i.createBlock)((0,i.resolveDynamicComponent)(a.getComponent(r.name)),{value:e.row.value,mode:n.mode,namespace:a.alertmanagerConfigNamespace},null,8,["value","mode","namespace"]))]),_:2},1032,["value","onUpdate:value","mode","add-label"])]))]),_:2},1032,["label","name","weight"]))),128))]),_:1},8,["default-tab","use-hash","onChanged"])]),_:1},8,["done-route","mode","resource","errors","validation-passed","onFinish","onCancel"])}var mo=o(31097),go=o(22247),vo=o(91825),bo=o(20246),yo=o.n(bo),wo=o(89958),Oo=o(77651),So=o(39589),Eo=o(69742),xo=o(41778),_o=o(75495),ko=o(94569),Co=o(98283);const Ao=[{name:"slack",label:"monitoringReceiver.slack.label",title:"monitoringReceiver.slack.title",info:"monitoringReceiver.slack.info",key:"slackConfigs",logo:Eo},{name:"email",label:"monitoringReceiver.email.label",title:"monitoringReceiver.email.title",key:"emailConfigs",logo:xo},{name:"pagerduty",label:"monitoringReceiver.pagerduty.label",title:"monitoringReceiver.pagerduty.title",info:"monitoringReceiver.pagerduty.info",key:"pagerdutyConfigs",logo:_o},{name:"opsgenie",label:"monitoringReceiver.opsgenie.label",title:"monitoringReceiver.opsgenie.title",key:"opsgenieConfigs",logo:xo},{name:"webhook",label:"monitoringReceiver.webhook.label",title:"monitoringReceiver.webhook.title",key:"webhookConfigs",logo:ko},{name:"custom",label:"monitoringReceiver.custom.label",title:"monitoringReceiver.custom.title",info:"monitoringReceiver.custom.info",key:"webhookConfigs",logo:Co}];var To={components:{ArrayListGrouped:mo.A,Banner:zn.l,ButtonDropdown:wo.A,CruResource:Cr.A,LabeledInput:Pn.o,Loading:Ft.A,Tabbed:oi.A,Tab:ai.A,YamlEditor:go.A},props:{value:{type:Object,default:()=>({})},mode:{type:String,default:""},alertmanagerConfigResource:{type:Object,required:!0},alertmanagerConfigId:{type:String,required:!0},saveOverride:{type:Function,required:!0},useTabbedHash:{type:Boolean,default:void 0}},mixins:[vo.A,Oo.A],inheritAttrs:!1,async fetch(){const{receiverSchema:e}=await(0,So.ER)(this.$store);if(!e)throw new Error("Can't render the form because the AlertmanagerConfig schema, or it's definitions, is not loaded yet.");const t=Object.keys(e.resourceFields),n={};Object.keys(this.value).forEach(e=>{t.includes(e)||(n[e]=this.value[e])});let r=yo().dump(n);"{}"===r.trim()&&(r=""),this.expectedFields=t,this.suffixYaml=r},data(e){const t={},n=this.$route.query.mode;return n===Vn.YQ&&Ao.forEach(e=>{t[e.key]=t[e.key]||[]}),{create:Vn.YQ,EDITOR_MODES:go.j,fileFound:!1,receiverTypes:Ao,view:Vn.nW,yamlError:"",fvFormRuleSets:[{path:"name",rules:["required","duplicateName"]}],fvReportedValidationPaths:["value"]}},mounted(){this.mode===this.create&&(this.alertmanagerConfigResource.spec.receivers||(this.alertmanagerConfigResource.spec.receivers=[]),this.alertmanagerConfigResource.spec.receivers.push(this.value))},computed:{editorMode(){return this.$route.query.mode===Vn.nW?go.j.VIEW_CODE:go.j.EDIT_CODE},alertmanagerConfigNamespace(){return this.alertmanagerConfigResource?.metadata?.namespace||""},receiverNameDisabled(){return this.$route.query.mode===Vn.nW},fvExtraRules(){return{duplicateName:()=>{const e=this.alertmanagerConfigResource.spec.receivers,t=e?.map(e=>e.name)||[],n=new Set(t);if(e.length!==n.size)return this.$store.getters["i18n/t"]("monitoring.alerting.validation.duplicatedReceiverName",{name:this.value.name})}}}},watch:{suffixYaml(e){try{Object.keys(this.value).forEach(e=>{this.expectedFields.includes(e)||delete this.value[e]});const t=yo().load(e);Object.assign(this.value,t),this.yamlError=""}catch(t){this.yamlError=`There was a problem parsing the Custom Config: ${t}`}}},methods:{getComponent(e){return o(19469)(`./${e}`).default},navigateTo(e){this.$refs.tabbed.select(e.name)},getCount(e){const t=this.value?.[e.key]||[];return t.length},tabChanged({tab:e}){window.scrollTop=0,"custom"===e.name&&this.$nextTick(()=>{this.$refs.customEditor&&(this.$refs.customEditor[0].refresh(),this.$refs.customEditor[0].focus())})},redirectAfterCancel(){this.$router.push(this.alertmanagerConfigResource._detailLocation)},createAddOptions(e){return e.addOptions.map()},setError(e){this.errors=e?[e]:[]}}};o(68648);const Ro=(0,u.A)(To,[["render",fo]]);var No=Ro,Po=o(25375),Io=o(67100),Mo=o(37648),Do=o(76978),Lo={name:"AlertmanagerConfigReceiverCreateEdit",components:{ActionMenu:no.A,ButtonGroup:Po.A,ReceiverConfig:No,ResourceYaml:Io.A},async fetch(){const e=this.$store.getters["currentProduct"].inStore;this.receiverName=this.$route.query.receiverName;const t=this.$route.params.alertmanagerconfigid,n=await this.$store.dispatch(`${e}/find`,{type:Z.Rp.ALERTMANAGERCONFIG,id:t}),r=await this.$store.dispatch(`${e}/clone`,{resource:n}),i=this.$route.query.mode;if(i!==Vn.YQ){const e=(r.spec.receivers||[]).find(e=>e.name===this.receiverName);e&&(this.receiverValue=e)}this.alertmanagerConfigId=r.id,this.alertmanagerConfigResource=r,this.alertmanagerConfigDetailRoute=r._detailLocation},data(){return{actionMenuTargetElement:null,actionMenuTargetEvent:null,alertmanagerConfigId:"",alertmanagerConfigResource:null,alertmanagerConfigDetailRoute:null,config:Vn.au,create:Vn.YQ,detail:Vn.fS,edit:Vn.G5,receiverActionMenuIsOpen:!1,receiverName:"",receiverValue:{},showPreview:!1,view:Vn.nW,viewOptions:[{labelKey:"resourceDetail.masthead.config",value:"config"},{labelKey:"resourceDetail.masthead.yaml",value:Vn.zD}],yaml:Vn.zD}},computed:{currentView(){return this.$route.query.currentView},receiverActions(){const e=this.alertmanagerConfigResource?.availableActions;return e?this.alertmanagerConfigResource.getReceiverActions(e):[]},resourceYaml(){const e=this.alertmanagerConfigResource,t=this.$store.getters["currentStore"](e),n=this.$store.getters[`${t}/all`](Z.yx),r=(0,Do.o8)(e),i=(0,Mo.mH)(n,Z.Rp.ALERTMANAGERCONFIG,r);return i},mode(){return this.$route.query.mode},editorMode(){return this.mode===this.view?go.j.VIEW_CODE:this.showPreview?go.j.DIFF_CODE:go.j.EDIT_CODE},heading(){switch(this.$route.query.mode){case this.create:return this.t("monitoring.alertmanagerConfig.receiverFormNames.create");case this.edit:return this.currentView===this.yaml||this.$route.query.as===this.yaml?this.t("monitoring.alertmanagerConfig.receiverFormNames.editYaml"):this.t("monitoring.alertmanagerConfig.receiverFormNames.edit");default:return this.t("monitoring.alertmanagerConfig.receiverFormNames.detail")}}},methods:{saveOverride(e){if(this.alertmanagerConfigResource.yamlError)return this.alertmanagerConfigResource.errors=this.alertmanagerConfigResource.errors||[],this.alertmanagerConfigResource.errors.push(this.alertmanagerConfigResource.yamlError),void e(!1);this.alertmanagerConfigResource.save(...arguments),this.redirectToAlertmanagerConfigDetail()},handleButtonGroupClick(e){e===this.yaml&&this.goToEditYaml(this.view),e===this.config&&this.goToEdit(this.view)},toggleReceiverActionMenu(){this.receiverActionMenuIsOpen=!this.receiverActionMenuIsOpen},handleReceiverActionMenuClick(e){this.actionMenuTargetElement=this.$refs.actions,this.actionMenuTargetEvent=e,this.toggleReceiverActionMenu()},goToEdit(){this.$router.push(this.alertmanagerConfigResource.getEditReceiverConfigRoute(this.receiverValue.name,Vn.G5))},goToEditYaml(){this.$router.push(this.alertmanagerConfigResource.getEditReceiverYamlRoute(this.receiverValue.name,Vn.G5))},promptRemove(e){const t=e.route.query.receiverName,n=this.alertmanagerConfigResource.spec.receivers||[],r=n.filter(e=>e.name!==t);this.alertmanagerConfigResource.spec.receivers=r,this.alertmanagerConfigResource.save(...arguments),this.$router.push(this.alertmanagerConfigResource._detailLocation)},redirectToReceiverDetail(e){return this.alertmanagerConfigResource.getReceiverDetailLink(e)},redirectToAlertmanagerConfigDetail(){const e=this.alertmanagerConfigResource._detailLocation;this.$router.push(e)}}};o(56554);const Bo=(0,u.A)(Lo,[["render",to],["__scopeId","data-v-a0fecebc"]]);var $o=Bo;const Vo={class:"dashboard-root"},Fo={class:"dashboard-content"},jo={class:"main-layout"},Uo={class:"logo"},Go={class:"tagline"},Ho={class:"description"},qo={class:"tagline"},Qo={class:"tagline"};function zo(e,t,n,r,o,a){const s=(0,i.resolveComponent)("BrandImage"),l=(0,i.resolveDirective)("clean-html");return(0,i.openBlock)(),(0,i.createElementBlock)("div",Vo,[(0,i.createElementVNode)("div",Fo,[(0,i.createElementVNode)("main",jo,[(0,i.createElementVNode)("div",Uo,[(0,i.createVNode)(s,{"file-name":"harvester.png",height:"64"})]),(0,i.createElementVNode)("div",Go,[(0,i.createElementVNode)("div",Ho,(0,i.toDisplayString)(e.t("unsupported.description")),1)]),(0,i.createElementVNode)("div",qo,[(0,i.withDirectives)((0,i.createElementVNode)("div",null,null,512),[[l,e.t("unsupported.serverVersion",{serverVersion:a.serverVersion},!0)]])]),(0,i.createElementVNode)("div",Qo,[(0,i.withDirectives)((0,i.createElementVNode)("div",null,null,512),[[l,e.t("unsupported.learnMore",{},!0)]])])])])])}var Ko={components:{BrandImage:L.A},computed:{serverVersion(){const e=this.$store.getters["harvester-common/getServerVersion"]()||"";return e.replace("v","")}}};o(29056);const Wo=(0,u.A)(Ko,[["render",zo],["__scopeId","data-v-140c2578"]]);var Xo=Wo,Yo=o(12243);const Zo={class:"mappings-cell"};var Jo={__name:"MappingsCell",props:{networkEntries:{type:Array,default:()=>[]},storageEntries:{type:Array,default:()=>[]}},setup(e){return(t,n)=>((0,i.openBlock)(),(0,i.createElementBlock)("div",Zo,[((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,null,(0,i.renderList)(e.networkEntries,(e,t)=>((0,i.openBlock)(),(0,i.createElementBlock)("div",{key:"net-"+t,class:"mapping-entry"},[n[0]||(n[0]=(0,i.createElementVNode)("i",{class:"icon icon-network","aria-hidden":"true"},null,-1)),(0,i.createElementVNode)("span",null,(0,i.toDisplayString)(e),1)]))),128)),((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,null,(0,i.renderList)(e.storageEntries,(e,t)=>((0,i.openBlock)(),(0,i.createElementBlock)("div",{key:"stor-"+t,class:"mapping-entry"},[n[1]||(n[1]=(0,i.createElementVNode)("i",{class:"icon icon-datastore","aria-hidden":"true"},null,-1)),(0,i.createElementVNode)("span",null,(0,i.toDisplayString)(e),1)]))),128))]))}};o(74322);const ea=(0,u.A)(Jo,[["__scopeId","data-v-5bd9a608"]]);var ta=ea,na=o(95457),ra=o(66905);function ia(){return window.$globalApp.$router}function oa(){return window.$globalApp.$route}var aa=o(1371);const sa={key:1},la={class:"mmt-5"},ca={class:"text-muted"},ua={class:"plan-name-cell"},da={key:1,class:"plan-name"},ha={key:0,class:"progress-cells"},pa={class:"vm-progress-header"},fa={class:"vm-name-block"},ma={class:"vm-name"},ga={class:"text-muted vm-id"},va={class:"vm-pct-block"},ba={class:"vm-bar"},ya={class:"vm-pct text-muted mr-10"},wa={key:0,class:"step-label text-muted"},Oa={key:1,class:"step-label text-error"},Sa={key:2,class:"step-label text-muted"},Ea={key:3,class:"step-label text-muted"},xa={key:1},_a={key:0},ka={key:1,class:"text-muted"};var Ca={__name:"index",setup(e){const t={id:l.rk.FORKLIFT_PLAN,type:Z.yx,attributes:{kind:l.rk.FORKLIFT_PLAN,namespaced:!0},metadata:{name:l.rk.FORKLIFT_PLAN}},n=(0,R.Pj)(),{t:o}=(0,na.s)(n),a=(0,i.ref)(!0),s=(0,i.ref)([]),c=(0,i.computed)(()=>n.getters["currentProduct"].inStore),u=(0,i.computed)(()=>n.getters[`${c.value}/all`](l.rk.FORKLIFT_PLAN)),d=(0,i.computed)(()=>n.getters[`${c.value}/all`](l.rk.FORKLIFT_NETWORK_MAP)),h=(0,i.computed)(()=>n.getters[`${c.value}/all`](l.rk.FORKLIFT_STORAGE_MAP)),p=(0,i.computed)(()=>n.getters[`${c.value}/all`](l.rk.VM)),f=(e="")=>String(e).replaceAll("&","&").replaceAll("<","<").replaceAll(">",">").replaceAll('"',""").replaceAll("'","'"),m=(e={})=>{const t=String(e.phase||"").toLowerCase(),n="number"===typeof e.progress?.completed&&"number"===typeof e.progress?.total&&e.progress.total>0,r=n?Math.round(e.progress.completed/e.progress.total*1e3)/10:null;return"completed"===t||"succeeded"===t?{icon:"✓",color:"var(--success)",text:""}:"running"===t||"inprogress"===t||"progressing"===t||"started"===t||n&&r>0?{icon:"↻",color:"var(--primary)",text:null!==r?`${e.phase||o("generic.inProgress")} (${r}%)`:e.phase||o("generic.inProgress")}:"failed"===t||"error"===t?{icon:"✕",color:"var(--error)",text:e.phase||o("harvester.addons.vmMigration.dashboard.progress.failed")}:{icon:"○",color:"var(--muted)",text:""}},g=(e=[])=>e.length?e.map((e,t)=>{const n=e.name||o("harvester.addons.vmMigration.dashboard.progress.step",{index:t+1}),r=m(e),i=r.text?`${f(n)} : ${f(r.text)}`:f(n);return`<div style="display:flex;align-items:center;gap:8px;"><span style="color:${r.color};font-weight:700;">${r.icon}</span><span>${i}</span></div>`}).join(""):`<div style="display:flex;align-items:center;gap:8px;"><span style="color:var(--muted);font-weight:700;">○</span><span>${f(o("harvester.addons.vmMigration.dashboard.progress.initializingMigration"))}</span></div>`,v=(e,t)=>{if(!e)return{display:null,seconds:-1};const n=new Date(e).getTime(),r=t?new Date(t).getTime():Date.now();if(isNaN(n)||isNaN(r)||r<n)return{display:null,seconds:-1};const i=Math.floor((r-n)/1e3),o=Math.floor(i/3600),a=Math.floor(i%3600/60),s=i%60,l=o>0?`${o}h ${a}m`:`${a}m ${s}s`;return{display:l,seconds:i}},b=(0,i.computed)(()=>u.value.map(e=>{const t=e.spec?.map?.network?.name,i=e.spec?.map?.network?.namespace||e.metadata.namespace,a=e.spec?.map?.storage?.name,s=e.spec?.map?.storage?.namespace||e.metadata.namespace,c=d.value.find(e=>e.metadata.name===t&&e.metadata.namespace===i),u=h.value.find(e=>e.metadata.name===a&&e.metadata.namespace===s);e.networkEntries=(c?.spec?.map||[]).map(e=>`${e.source?.id||"Ignored"} → ${"pod"===e.destination?.type?o("harvester.addons.vmMigration.configureMappings.networkMapping.options.podNetworking"):e.destination?.name||"Ignored"}`),e.storageEntries=(u?.spec?.map||[]).map(e=>`${e.source?.id||"Ignored"} → ${e.destination?.storageClass||"Ignored"}`),e.vmIdsDisplay=(e.spec?.vms||[]).map(e=>e.id||e.name||"").filter(Boolean).join(", ")||"-";const f=e.status?.migration?.vms||[];e.vmProgress=f.map(t=>{const i=t.pipeline||[],a=i.length||1;let s=0,c="",u="";if(i.forEach((e,t)=>{const n=100/a;if("Completed"===e.phase)s+=n;else{const r=e.progress?.completed&&e.progress?.total?e.progress.completed/e.progress.total*100:0;if(s+=r/100*n,c||(c=e.name||o("harvester.addons.vmMigration.dashboard.progress.step",{index:t+1})),e.error&&!u){const n=(e.error.reasons||[]).join("; ")||o("harvester.addons.vmMigration.plan.states.error");u=`${e.name||o("harvester.addons.vmMigration.dashboard.progress.step",{index:t+1})}: ${n}`}"Failed"!==e.phase||u||(u=`${e.name||o("harvester.addons.vmMigration.dashboard.progress.step",{index:t+1})}: ${o("harvester.addons.vmMigration.dashboard.progress.failed")}`)}}),!u&&t.error){const e=(t.error.reasons||[]).join("; ")||o("harvester.addons.vmMigration.dashboard.progress.failed");u=`${c||t.error.phase||o("harvester.addons.vmMigration.dashboard.progress.migration")}: ${e}`}s=Math.round(10*s)/10,!u&&e.planFailed&&s<100&&(u=`${c||o("harvester.addons.vmMigration.dashboard.progress.migration")}: ${o("harvester.addons.vmMigration.dashboard.progress.failed")}`);const d=t.namespace||e.spec?.targetNamespace||e.metadata?.namespace,h=ia().currentRoute?.value?.params||{},f=h.product||n.getters["productId"],m=h.cluster||n.getters["clusterId"],v=[t.targetName,t.name,t.id].filter(Boolean),b=p.value.find(e=>v.includes(e.metadata?.name)&&(!d||e.metadata?.namespace===d)),y=s>=100&&!u&&!e.planCanceled&&!!b&&!!f&&!!m,w=y?{name:`${r.KR}-c-cluster-resource-namespace-id`,params:{product:f,cluster:m,resource:l.rk.VM,namespace:b.metadata.namespace,id:b.metadata.name}}:null;return{vmName:t.name||t.id||o("harvester.addons.vmMigration.generic.unknown"),vmId:t.id||"",progress:s,currentStep:c,pipelineTooltip:g(i),errorMsg:u,canceled:e.planCanceled,vmDetailLocation:w}}),0===e.vmProgress.length&&e.spec?.vms?.length>0&&(e.vmProgress=e.spec.vms.map(e=>({vmName:e.name||e.id||o("harvester.addons.vmMigration.generic.unknown"),vmId:e.id||"",progress:0,currentStep:o("harvester.addons.vmMigration.dashboard.progress.initializingMigration"),pipelineTooltip:g([]),errorMsg:"",canceled:!1}))),e.progress=e.vmProgress.length>0?Math.round(e.vmProgress.reduce((e,t)=>e+t.progress,0)/e.vmProgress.length*10)/10:0;const m=v(e.status?.migration?.started,e.status?.migration?.completed);return e.duration=m.display,e.durationSeconds=m.seconds,e})),y=(0,i.computed)(()=>({name:`${r.KR}-c-cluster-vm-migration-wizard`,params:{product:n.getters["productId"],cluster:n.getters["clusterId"]}})),w=[{...ri.c4,labelKey:"harvester.addons.vmMigration.dashboard.columns.status"},{...ri.o_,labelKey:"harvester.addons.vmMigration.dashboard.columns.plan"},{...aa.WF,width:105},{name:"progress",labelKey:"harvester.addons.vmMigration.dashboard.columns.progress",value:"progress",width:450},{name:"mappings",labelKey:"harvester.addons.vmMigration.dashboard.columns.mappings"},{name:"duration",labelKey:"harvester.addons.vmMigration.dashboard.columns.duration",value:"duration",sort:"durationSeconds",width:90},{...ri.K}],O=async()=>{try{let t=!1;if(n.getters[`${c.value}/schemaFor`](l.rk.ADD_ONS)){const e=await n.dispatch(`${c.value}/findAll`,{type:l.rk.ADD_ONS});t=!0===e.find(e=>e.metadata?.name===ra.Jo.FORKLIFT_OPERATOR)?.spec?.enabled}if(!t)return void await ia().replace({name:`${r.KR}-c-cluster-resource`,params:{product:n.getters["productId"],cluster:n.getters["clusterId"],resource:l.rk.DASHBOARD}});await Promise.all([n.dispatch(`${c.value}/findAll`,{type:l.rk.FORKLIFT_PLAN}),n.dispatch(`${c.value}/findAll`,{type:l.rk.FORKLIFT_NETWORK_MAP}),n.dispatch(`${c.value}/findAll`,{type:l.rk.FORKLIFT_STORAGE_MAP})]);try{await n.dispatch(`${c.value}/findAll`,{type:l.rk.VM})}catch(e){}}catch(e){s.value=[e?.message||o("harvester.addons.vmMigration.errors.failedLoadPlans")]}finally{a.value=!1}};return O(),(e,n)=>{const r=(0,i.resolveComponent)("router-link"),l=(0,i.resolveDirective)("clean-html"),c=(0,i.resolveDirective)("clean-tooltip");return a.value?((0,i.openBlock)(),(0,i.createBlock)((0,i.unref)(Ft.A),{key:0})):((0,i.openBlock)(),(0,i.createElementBlock)("div",sa,[((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,null,(0,i.renderList)(s.value,(e,t)=>((0,i.openBlock)(),(0,i.createBlock)((0,i.unref)(zn.l),{key:t,color:"error",label:e},null,8,["label"]))),128)),(0,i.createVNode)((0,i.unref)(ni.A),{schema:t,resource:t.id,"type-display":(0,i.unref)(o)("harvester.addons.vmMigration.dashboard.title")},{subHeader:(0,i.withCtx)(()=>[(0,i.createElementVNode)("div",la,[(0,i.withDirectives)((0,i.createElementVNode)("p",ca,null,512),[[l,(0,i.unref)(o)("harvester.addons.vmMigration.dashboard.description")]])])]),createButton:(0,i.withCtx)(()=>[(0,i.createVNode)(r,{to:y.value,class:"btn role-primary"},{default:(0,i.withCtx)(()=>[(0,i.createTextVNode)((0,i.toDisplayString)((0,i.unref)(o)("harvester.addons.vmMigration.dashboard.createPlan")),1)]),_:1},8,["to"])]),_:1},8,["resource","type-display"]),(0,i.createVNode)((0,i.unref)(ti.A),{schema:t,rows:b.value,headers:w,groupable:!1,"table-actions":!1,search:!1,"key-field":"_key"},{"cell:name":(0,i.withCtx)(({row:e})=>[(0,i.createElementVNode)("div",ua,[e.detailLocation?((0,i.openBlock)(),(0,i.createBlock)(r,{key:0,to:e.detailLocation,class:"plan-name"},{default:(0,i.withCtx)(()=>[(0,i.createTextVNode)((0,i.toDisplayString)(e.metadata.name),1)]),_:2},1032,["to"])):((0,i.openBlock)(),(0,i.createElementBlock)("div",da,(0,i.toDisplayString)(e.metadata.name),1))])]),"cell:vmCount":(0,i.withCtx)(({row:e})=>[(0,i.createTextVNode)((0,i.toDisplayString)((0,i.unref)(o)("harvester.addons.vmMigration.dashboard.progress.vmCount",{count:(e.spec.vms||[]).length})),1)]),"cell:progress":(0,i.withCtx)(({row:e})=>[e.vmProgress&&e.vmProgress.length?((0,i.openBlock)(),(0,i.createElementBlock)("div",ha,[((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,null,(0,i.renderList)(e.vmProgress,e=>((0,i.openBlock)(),(0,i.createElementBlock)("div",{key:e.vmId,class:"vm-progress"},[(0,i.createElementVNode)("div",pa,[(0,i.createElementVNode)("div",fa,[(0,i.createElementVNode)("span",ma,[(0,i.createTextVNode)((0,i.toDisplayString)(e.vmName)+" ",1),e.vmDetailLocation?(0,i.withDirectives)(((0,i.openBlock)(),(0,i.createBlock)(r,{key:0,to:e.vmDetailLocation,class:"vm-detail-link"},{default:(0,i.withCtx)(()=>[...n[0]||(n[0]=[(0,i.createElementVNode)("i",{class:"icon icon-external-link"},null,-1)])]),_:1},8,["to"])),[[c,(0,i.unref)(o)("harvester.addons.vmMigration.dashboard.progress.checkMigratedVm")]]):(0,i.createCommentVNode)("",!0)]),(0,i.createElementVNode)("span",ga,(0,i.toDisplayString)((0,i.unref)(o)("harvester.addons.vmMigration.dashboard.progress.vmId",{id:e.vmId})),1)])]),(0,i.createElementVNode)("div",va,[(0,i.withDirectives)(((0,i.openBlock)(),(0,i.createElementBlock)("div",ba,[(0,i.createVNode)((0,i.unref)(Yo.A),{"model-value":e.progress,"color-stops":e.errorMsg?{100:"--error"}:e.canceled?{100:"--darker"}:e.progress>=100?{100:"--success"}:{100:"--primary"},"preferred-direction":"MORE"},null,8,["model-value","color-stops"])])),[[c,{content:e.pipelineTooltip,html:!0}]]),(0,i.createElementVNode)("span",ya,(0,i.toDisplayString)(e.progress)+"%",1)]),e.progress>=100?((0,i.openBlock)(),(0,i.createElementBlock)("div",wa,(0,i.toDisplayString)((0,i.unref)(o)("harvester.addons.vmMigration.dashboard.progress.finishedSuccessfully")),1)):e.errorMsg?((0,i.openBlock)(),(0,i.createElementBlock)("div",Oa,(0,i.toDisplayString)(e.errorMsg),1)):e.canceled?((0,i.openBlock)(),(0,i.createElementBlock)("div",Sa,(0,i.toDisplayString)((0,i.unref)(o)("harvester.addons.vmMigration.plan.states.canceled")),1)):e.currentStep?((0,i.openBlock)(),(0,i.createElementBlock)("div",Ea,(0,i.toDisplayString)(e.currentStep),1)):(0,i.createCommentVNode)("",!0)]))),128))])):(0,i.createCommentVNode)("",!0),e.vmProgress.length?(0,i.createCommentVNode)("",!0):((0,i.openBlock)(),(0,i.createElementBlock)("span",xa,"-"))]),"cell:mappings":(0,i.withCtx)(({row:e})=>[(0,i.createVNode)((0,i.unref)(ta),{"network-entries":e.networkEntries,"storage-entries":e.storageEntries},null,8,["network-entries","storage-entries"])]),"cell:duration":(0,i.withCtx)(({row:e})=>[e.duration?((0,i.openBlock)(),(0,i.createElementBlock)("span",_a,(0,i.toDisplayString)(e.duration),1)):((0,i.openBlock)(),(0,i.createElementBlock)("span",ka,"—"))]),_:1},8,["rows"])]))}}};o(15006);const Aa=(0,u.A)(Ca,[["__scopeId","data-v-3ddd027e"]]);var Ta=Aa;const Ra="forklift.konveyor.io/v1beta1";function Na(e){try{return atob(e||"")}catch(t){return""}}function Pa(e){return Math.round((e||0)/1073741824)}function Ia(e){return Math.round((e||0)/1024)}function Ma(e=[],t){return e.filter(e=>!!e.target).map(e=>{const n={name:e.name,id:e.id};if("pod"===e.target)return{source:n,destination:{type:"pod"}};if("ignored"===e.target)return{source:n,destination:{type:"ignored"}};const r=e.target.split("/"),i=r.length>1?r[1]:r[0],o=r.length>1?r[0]:t;return{source:n,destination:{type:"multus",name:i,namespace:o}}})}function Da(e=[]){return e.filter(e=>!!e.target).map(e=>{const t={storageClass:e.target};return e.volumeMode&&(t.volumeMode=e.volumeMode),Array.isArray(e.accessModes)&&e.accessModes.length&&(t.accessMode=e.accessModes[0]),{source:{name:e.name,id:e.id},destination:t}})}const La={key:1,class:"configure-provider-step"},Ba={class:"text-deemphasized line-height-20"},$a={class:"configure-provider-step-content"},Va={class:"table-title m-0"},Fa={class:"requirements-banner-content"},ja={class:"requirements-banner-title"},Ua={class:"configure-provider-step-form"},Ga={key:0},Ha={key:1},qa={class:"row"},Qa={class:"col span-6"},za={class:"text-deemphasized mt-5"},Ka={class:"col span-6"},Wa={class:"row"},Xa={class:"col span-6"},Ya={class:"col span-6"},Za={class:"text-deemphasized ml-20"},Ja="__create_new__";var es={__name:"ConfigureProviderStep",props:{stepData:{type:Object,required:!0},createOnly:{type:Boolean,default:!1},editMode:{type:Boolean,default:!1}},emits:["complete","ready","form-valid","testing"],setup(e,{expose:t,emit:n}){const r=e,o=n,a=(0,R.Pj)(),{t:s}=(0,na.s)(a),c=(0,i.ref)([]),u=(0,i.ref)([]),d=(0,i.ref)([]),h=(0,i.ref)(null),p=(0,i.ref)(!0),f=(0,i.ref)(!1),{selectedProvider:m,providerName:g,url:v,username:b,password:y,skipTlsVerify:w,vddkInitImage:O,testPassed:S,testResult:E,testError:x,createdProvider:_,createdSecret:k}=(0,i.toRefs)(r.stepData),C=(0,i.computed)(()=>m.value!==Ja),A=(0,i.computed)(()=>!!g.value&&!!v.value&&!!b.value&&!!y.value),T=(0,i.computed)(()=>{const e=[{label:s("harvester.addons.vmMigration.configureProvider.createNew"),value:Ja}];return c.value.forEach(t=>{if(!t.spec?.url)return;const n=t.spec?.secret;if(n){{const e=u.value.find(e=>e.metadata.name===n.name&&e.metadata.namespace===n.namespace);if(!e?.data?.user||!e?.data?.password)return}e.push({label:t.metadata.name,value:t.metadata.name})}}),e});(0,i.watch)(m,e=>{if(S.value=!1,E.value=null,x.value=null,e===Ja)g.value="",v.value="",b.value="",y.value="",w.value=!1,O.value="",_.value=null,k.value=null;else{const t=c.value.find(t=>t.metadata.name===e&&t.metadata.namespace===ra.Ex);if(t){g.value=t.metadata.name,v.value=t.spec?.url||"",O.value=t.spec?.settings?.vddkInitImage||"";const e=t.spec?.secret;if(e){const t=u.value.find(t=>t.metadata.name===e.name&&t.metadata.namespace===e.namespace);t?.data&&(b.value=Na(t.data.user),y.value=Na(t.data.password),w.value="true"===Na(t.data.insecureSkipVerify))}_.value=t}}}),(0,i.watch)([g,v,b,y],()=>{C.value||(S.value=!1,E.value=null)}),(0,i.watch)(S,e=>{o("ready",e),e&&o("complete",{providerName:g.value,provider:_.value})},{immediate:!0}),(0,i.watch)(A,e=>{o("form-valid",e)},{immediate:!0}),(0,i.watch)(f,e=>{o("testing",e)},{immediate:!0});const N=async e=>{const t=a.getters["currentProduct"].inStore,n=ra.Ex,r=15;let i=0;while(i<r){await new Promise(e=>setTimeout(e,2e3)),i++;const r=await a.dispatch(`${t}/find`,{type:l.rk.FORKLIFT_PROVIDER,id:`${n}/${e}`,opt:{force:!0}}),o=r?.status?.conditions||[],c=o.find(e=>"ConnectionTestSucceeded"===e.type),u=o.find(e=>"Ready"===e.type);if(c)return"True"===c.status?{connected:!0}:{connected:!1,errorMsg:c.message||s("harvester.addons.vmMigration.errors.connectionFailed")};if(u){if("True"===u.status)return{connected:!0};if("False"===u.status)return{connected:!1,errorMsg:u.message||s("harvester.addons.vmMigration.errors.providerNotReady")}}}return{connected:!1,errorMsg:""}},P=({connected:e,errorMsg:t},n)=>{e?(S.value=!0,E.value=s("harvester.addons.vmMigration.configureProvider.testSuccess"),f.value=!1,n(!0)):(x.value=t||s("harvester.addons.vmMigration.configureProvider.testTimeout"),f.value=!1,n(!1))},I=async()=>{if(_.value){try{await _.value.remove()}catch(e){}_.value=null,k.value=null}else if(k.value){try{await k.value.remove()}catch(e){}k.value=null}},M=async e=>{if(E.value=null,x.value=null,f.value=!0,!g.value||!v.value||!b.value||!y.value)return x.value=s("harvester.addons.vmMigration.configureProvider.testMissingFields"),f.value=!1,void e(!1);const t=a.getters["currentProduct"].inStore;if(r.editMode&&_.value)try{_.value.spec.url=v.value;const t=O.value?.trim();t?_.value.spec.settings={..._.value.spec.settings||{},vddkInitImage:t}:_.value.spec.settings&&delete _.value.spec.settings.vddkInitImage,await _.value.save();const n=_.value.spec?.secret;n&&k.value&&(k.value.data={user:btoa(b.value),password:btoa(y.value),insecureSkipVerify:btoa(String(w.value)),url:btoa(v.value)},await k.value.save()),P(await N(g.value),e)}catch(n){x.value=n.message||s("harvester.addons.vmMigration.configureProvider.testFailed"),f.value=!1,e(!1)}else if(C.value)try{P(await N(g.value),e)}catch(n){x.value=n.message||s("harvester.addons.vmMigration.configureProvider.testFailed"),f.value=!1,e(!1)}else try{await I();const n=ra.Ex,r=`${g.value}-creds-${(0,Di.vx)(4).toLowerCase()}`,i={type:"vsphere",url:v.value,secret:{name:r,namespace:n}},o=O.value?.trim();o&&(i.settings={vddkInitImage:o});const s=await a.dispatch(`${t}/create`,{type:l.rk.FORKLIFT_PROVIDER,metadata:{name:g.value,namespace:n},spec:i});await s.save(),_.value=s;const c=await a.dispatch(`${t}/create`,{type:Z.bB,metadata:{name:r,namespace:n,labels:{"ui.forklift/created-for-resource-type":"forklift.konveyor.io.provider"},ownerReferences:[{apiVersion:"forklift.konveyor.io/v1beta1",kind:"Provider",name:s.metadata.name,uid:s.metadata.uid,blockOwnerDeletion:!0}]}});c["_type"]="Opaque",c["data"]={user:btoa(b.value),password:btoa(y.value),insecureSkipVerify:btoa(String(w.value)),url:btoa(v.value)},await c.save(),k.value=c;const u=await N(g.value);u.connected||await I(),P(u,e)}catch(n){await I(),x.value=n.message||s("harvester.addons.vmMigration.configureProvider.testFailed"),f.value=!1,e(!1)}},D=async()=>{const e=a.getters["currentProduct"].inStore;try{c.value=await a.dispatch(`${e}/findAll`,{type:l.rk.FORKLIFT_PROVIDER}),u.value=await a.dispatch(`${e}/findAll`,{type:Z.bB,opt:{labelSelector:`ui.forklift/created-for-resource-type=${l.rk.FORKLIFT_PROVIDER}`}})}catch(t){d.value=[t?.message||s("harvester.addons.vmMigration.errors.failedLoadProviders")]}p.value=!1};D();const L=()=>{h.value?.$el?.click()};return t({testConnection:M,clickTestButton:L}),(t,n)=>p.value?((0,i.openBlock)(),(0,i.createBlock)((0,i.unref)(Ft.A),{key:0})):((0,i.openBlock)(),(0,i.createElementBlock)("div",La,[(0,i.createElementVNode)("p",Ba,(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.configureProvider.description")),1),(0,i.createElementVNode)("div",$a,[(0,i.createElementVNode)("h3",Va,[(0,i.createElementVNode)("b",null,(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.configureProvider.connectionDetails")),1)]),(0,i.createVNode)((0,i.unref)(zn.l),{class:"requirements-banner m-0",color:"info"},{default:(0,i.withCtx)(()=>[(0,i.createElementVNode)("div",Fa,[(0,i.createElementVNode)("span",ja,(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.configureProvider.requirementsTitle")),1),n[7]||(n[7]=(0,i.createElementVNode)("br",null,null,-1)),(0,i.createElementVNode)("span",null,(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.configureProvider.requirementsText")),1)])]),_:1}),(0,i.createElementVNode)("div",Ua,[e.createOnly||e.editMode?(0,i.createCommentVNode)("",!0):((0,i.openBlock)(),(0,i.createElementBlock)("div",Ga,[(0,i.createVNode)((0,i.unref)(Tr.A),{value:(0,i.unref)(m),"onUpdate:value":n[0]||(n[0]=e=>(0,i.isRef)(m)?m.value=e:null),required:"",label:(0,i.unref)(s)("harvester.addons.vmMigration.configureProvider.providerSelect"),options:T.value,reduce:e=>e.value},null,8,["value","label","options","reduce"])])),!C.value||e.editMode?((0,i.openBlock)(),(0,i.createElementBlock)("div",Ha,[(0,i.createVNode)((0,i.unref)(Pn.o),{value:(0,i.unref)(g),"onUpdate:value":n[1]||(n[1]=e=>(0,i.isRef)(g)?g.value=e:null),label:(0,i.unref)(s)("harvester.addons.vmMigration.configureProvider.name"),disabled:e.editMode,required:""},null,8,["value","label","disabled"])])):(0,i.createCommentVNode)("",!0),(0,i.createElementVNode)("div",qa,[(0,i.createElementVNode)("div",Qa,[(0,i.createVNode)((0,i.unref)(Pn.o),{value:(0,i.unref)(v),"onUpdate:value":n[2]||(n[2]=e=>(0,i.isRef)(v)?v.value=e:null),label:(0,i.unref)(s)("harvester.addons.vmMigration.configureProvider.urlLabel"),placeholder:(0,i.unref)(s)("harvester.addons.vmMigration.configureProvider.urlPlaceholder"),disabled:C.value&&!e.editMode,required:""},null,8,["value","label","placeholder","disabled"]),(0,i.createElementVNode)("p",za,(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.configureProvider.urlHint")),1)]),(0,i.createElementVNode)("div",Ka,[(0,i.createVNode)((0,i.unref)(Pn.o),{value:(0,i.unref)(O),"onUpdate:value":n[3]||(n[3]=e=>(0,i.isRef)(O)?O.value=e:null),label:(0,i.unref)(s)("harvester.addons.vmMigration.configureProvider.vddkImageLabel"),placeholder:(0,i.unref)(s)("harvester.addons.vmMigration.configureProvider.vddkImagePlaceholder"),tooltip:(0,i.unref)(s)("harvester.addons.vmMigration.configureProvider.vddkImageTooltip"),disabled:C.value&&!e.editMode},null,8,["value","label","placeholder","tooltip","disabled"])])]),(0,i.createElementVNode)("div",Wa,[(0,i.createElementVNode)("div",Xa,[(0,i.createVNode)((0,i.unref)(Pn.o),{value:(0,i.unref)(b),"onUpdate:value":n[4]||(n[4]=e=>(0,i.isRef)(b)?b.value=e:null),label:(0,i.unref)(s)("harvester.addons.vmMigration.fields.username"),disabled:C.value&&!e.editMode,required:""},null,8,["value","label","disabled"])]),(0,i.createElementVNode)("div",Ya,[(0,i.createVNode)((0,i.unref)(Pn.o),{value:(0,i.unref)(y),"onUpdate:value":n[5]||(n[5]=e=>(0,i.isRef)(y)?y.value=e:null),type:"password",label:(0,i.unref)(s)("harvester.addons.vmMigration.fields.password"),disabled:C.value&&!e.editMode,required:""},null,8,["value","label","disabled"])])]),(0,i.createElementVNode)("div",null,[(0,i.createVNode)((0,i.unref)(Hn.S),{value:(0,i.unref)(w),"onUpdate:value":n[6]||(n[6]=e=>(0,i.isRef)(w)?w.value=e:null),label:(0,i.unref)(s)("harvester.addons.vmMigration.configureProvider.skipSsl"),disabled:C.value&&!e.editMode},null,8,["value","label","disabled"]),(0,i.createElementVNode)("p",Za,(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.configureProvider.skipSslHint")),1)]),(0,i.createElementVNode)("div",null,[(0,i.createVNode)((0,i.unref)(Qn.A),{ref_key:"testBtnRef",ref:h,mode:"test",disabled:!A.value,"action-label":(0,i.unref)(s)("harvester.addons.vmMigration.configureProvider.testConnection.action"),"waiting-label":(0,i.unref)(s)("harvester.addons.vmMigration.configureProvider.testConnection.waiting"),"success-label":(0,i.unref)(s)("harvester.addons.vmMigration.configureProvider.testConnection.success"),"error-label":(0,i.unref)(s)("harvester.addons.vmMigration.configureProvider.testConnection.error"),"action-color":"role-secondary","waiting-color":"role-disabled",onClick:M},null,8,["disabled","action-label","waiting-label","success-label","error-label"])]),(0,i.unref)(E)?((0,i.openBlock)(),(0,i.createBlock)((0,i.unref)(zn.l),{key:2,color:"success"},{default:(0,i.withCtx)(()=>[(0,i.createTextVNode)((0,i.toDisplayString)((0,i.unref)(E)),1)]),_:1})):(0,i.createCommentVNode)("",!0),(0,i.unref)(x)?((0,i.openBlock)(),(0,i.createBlock)((0,i.unref)(zn.l),{key:3,color:"error"},{default:(0,i.withCtx)(()=>[(0,i.createTextVNode)((0,i.toDisplayString)((0,i.unref)(x)),1)]),_:1})):(0,i.createCommentVNode)("",!0),((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,null,(0,i.renderList)(d.value,(e,t)=>((0,i.openBlock)(),(0,i.createBlock)((0,i.unref)(zn.l),{key:t,color:"error"},{default:(0,i.withCtx)(()=>[(0,i.createTextVNode)((0,i.toDisplayString)(e),1)]),_:2},1024))),128))])])]))}};o(80279);const ts=(0,u.A)(es,[["__scopeId","data-v-4846def2"]]);var ns=ts,rs=o(33246),is=o(41418);const os={key:1,class:"select-vms-step"},as={class:"text-deemphasized line-height-20"},ss={key:1},ls={class:"vm-table-title"},cs={class:"m-0"},us={class:"selected-actions"},ds={class:"text-deemphasized"},hs={class:"vm-name-cell"},ps={class:"vm-name"},fs={class:"vm-id text-deemphasized"},ms={class:"text-deemphasized"},gs={class:"text-deemphasized"},vs={class:"text-deemphasized"},bs={class:"select-all-banner-row"},ys=["colspan"];var ws={__name:"SelectVmsStep",props:{providerName:{type:String,default:""},provider:{type:Object,default:null},stepData:{type:Object,required:!0}},emits:["complete","loading"],setup(e,{emit:t}){const n=e,r=t,o=(0,R.Pj)(),{t:a}=(0,na.s)(o),{discoveredVMs:s,selectedVMIds:l,tableRows:c}=(0,i.toRefs)(n.stepData),u=(0,i.ref)([]),d=(0,i.ref)(!0),h=(0,i.ref)(n.stepData.networkMap||{}),p=(0,i.ref)(n.stepData.datastoreMap||{}),f=(0,i.ref)(null),m=(0,i.ref)(!1),g=(0,i.ref)([]);let v=!1;const b=(0,i.ref)(null),y=(0,i.ref)(Date.now()),w=e=>{const t=Math.floor(e/6e4),n=Math.floor(t/60),r=t%60;return n>0&&r>0?a("harvester.addons.vmMigration.generic.elapsed.hoursAndMinutes",{hours:n,minutes:r}):n>0?a("harvester.addons.vmMigration.generic.elapsed.hours",{hours:n}):a("harvester.addons.vmMigration.generic.elapsed.minutes",{minutes:Math.max(1,r)})},O=(0,i.computed)(()=>b.value?w(y.value-b.value):""),S=setInterval(()=>{y.value=Date.now()},3e4);(0,i.onBeforeUnmount)(()=>{clearInterval(S)}),l.value.size>0&&(u.value=s.value.filter(e=>l.value.has(e.id)),m.value=l.value.size===s.value.length);const E=(0,i.computed)(()=>s.value.length),x=(0,i.computed)(()=>u.value.length),_=(0,i.computed)(()=>{if(m.value)return!0;const e=f.value?.pagedRows||[];if(0===e.length)return!1;const t=e.every(e=>l.value.has(e._original?.id));return t&&c.value.length>e.length}),k=(0,i.computed)(()=>f.value?.$el?.querySelector("thead")),C=(0,i.ref)([{name:"vmName",labelKey:"harvester.addons.vmMigration.selectVms.columns.vmName",value:"vmName",sort:["vmName"],subLabel:a("harvester.addons.vmMigration.generic.identifier")},{name:"os",labelKey:"harvester.addons.vmMigration.selectVms.columns.os",value:"os",sort:["os"],width:180},{name:"resources",labelKey:"harvester.addons.vmMigration.selectVms.columns.resources",value:"resources",sort:!1,width:140},{name:"powerState",labelKey:"harvester.addons.vmMigration.selectVms.columns.powerState",value:"powerState",sort:["powerState"],width:130},{name:"network",labelKey:"harvester.addons.vmMigration.selectVms.columns.network",value:"network",sort:["network"],subLabel:a("harvester.addons.vmMigration.generic.identifier"),width:200},{name:"datastore",labelKey:"harvester.addons.vmMigration.selectVms.columns.datastore",value:"datastore",sort:["datastore"],subLabel:a("harvester.addons.vmMigration.generic.identifier"),width:200}]),A=()=>s.value.map(e=>{const t=e.cpuCount||e.numCPU||"-",n=e.memoryMB||e.memory||0,r=n?a("harvester.addons.vmMigration.generic.memoryGb",{value:Ia(n)}):"-";let i=0;e.disks&&e.disks.length>0&&(i=e.disks.reduce((e,t)=>e+(t.capacity||0),0));const o=i?a("harvester.addons.vmMigration.generic.memoryGb",{value:Pa(i)}):"-",s=e.powerState||e.status?.phase||"-",c=s.replace(/([a-z])([A-Z])/g,"$1 $2").replace(/^./,e=>e.toUpperCase());let u=[];e.networks&&e.networks.length>0&&(u=e.networks.map(e=>({name:e.name||h.value[e.id]||e.id||e,id:e.id||"",vlanId:e.vlanId||""})));const d=[];if(e.disks&&e.disks.length>0){const t=new Set;e.disks.forEach(e=>{const n=e.datastore?.id||e.datastore?.name;n&&!t.has(n)&&(t.add(n),d.push({name:e.datastore?.name||p.value[n]||n,id:e.datastore?.id||"",type:e.datastore?.type||"",capacity:e.capacity||0}))})}return{_original:e,_key:e.id||e.vmId||e.metadata?.name,selectedSort:l.value.has(e.id)?0:1,vmName:e.name||e.metadata?.name||"-",vmId:e.id||e.vmId||e.metadata?.name||"-",os:e.guestName||e.guestOS||e.os||"-",resourcesDisplay:a("harvester.addons.vmMigration.generic.vCpu",{count:t}),resourcesSub:`${r} • ${o}`,powerState:c,powerStateClass:c.toLowerCase().includes("on")||c.toLowerCase().includes("running")?"power-on":"power-off",networks:u,network:u.map(e=>e.name).join(", ")||"-",datastores:d,datastore:d.map(e=>e.name).join(", ")||"-"}}),T=e=>{if(v)return;const t=f.value?.pagedRows||[],n=new Set(e.map(e=>e._key));t.forEach(e=>{const t=e._original?.id;n.has(e._key)?l.value.add(t):l.value.delete(t)}),m.value=l.value.size===s.value.length,u.value=s.value.filter(e=>l.value.has(e.id)),r("complete",{selectedVMs:u.value})},N=()=>{m.value=!1,l.value=new Set,u.value=[],(0,i.nextTick)(()=>{const e=f.value;e&&(e.clearSelection(),"function"===typeof e.setPage&&e.setPage(1))})},P=()=>{m.value=!0,l.value=new Set(s.value.map(e=>e.id)),u.value=s.value.slice()},I=()=>{0!==l.value.size&&(c.value.forEach(e=>{e.selectedSort=l.value.has(e._original?.id)?0:1}),C.value=C.value.map(e=>"vmName"===e.name?{...e,sort:["selectedSort","vmName"]}:e),v=!0,(0,i.nextTick)(()=>{const e=f.value;e?("function"===typeof e.changeSort?e.changeSort("vmName",!1):"function"===typeof e.setPage&&e.setPage(1),(0,i.nextTick)(()=>{const t=(e.pagedRows||[]).filter(e=>l.value.has(e._original?.id));t.length>0&&e.update(t,[]),v=!1})):v=!1}))};(0,i.watch)(()=>f.value?.page,()=>{v=!0,(0,i.nextTick)(()=>{const e=f.value;if(!e)return;const t=(e.pagedRows||[]).filter(e=>l.value.has(e._original?.id));t.length>0&&e.update(t,[]),v=!1})});const M=(0,i.ref)(!1),D=(0,i.computed)(()=>d.value||M.value);(0,i.watch)(D,e=>{r("loading",e)},{immediate:!0});const L=async()=>{if(!n.provider)return;const e=o.getters["currentProduct"].inStore,t=n.provider.metadata.uid,r=n.provider.spec?.type||"vsphere",i=o.getters["harvester-common/getHarvesterClusterUrl"](`v1/harvester/providers/${r}/${t}`),[a,l,u]=await Promise.all([o.dispatch(`${e}/request`,{url:`${i}/vms`}),o.dispatch(`${e}/request`,{url:`${i}/networks`}).catch(()=>[]),o.dispatch(`${e}/request`,{url:`${i}/datastores`}).catch(()=>[])]);Array.isArray(a)?s.value=a:a?.data&&Array.isArray(a.data)&&(s.value=a.data);const d=Array.isArray(l)?l:l?.data||[],f=Array.isArray(u)?u:u?.data||[];h.value=d.reduce((e,t)=>(e[t.id]=t.name,e),{}),p.value=f.reduce((e,t)=>(e[t.id]=t.name,e),{}),n.stepData.networkMap=h.value,n.stepData.datastoreMap=p.value,b.value=Date.now(),c.value=A()},B=async()=>{M.value=!0,v=!0;const e=new Set(l.value);try{g.value=[],await L()}catch(o){s.value=[],c.value=[],g.value=[o?.message||a("harvester.addons.vmMigration.errors.failedRefreshVms")]}l.value=new Set(s.value.filter(t=>e.has(t.id)).map(e=>e.id)),u.value=s.value.filter(e=>l.value.has(e.id)),m.value=l.value.size>0&&l.value.size===s.value.length,n.stepData.discoveredVMs=s.value,n.stepData.selectedVMIds=l.value,n.stepData.tableRows=c.value,r("complete",{selectedVMs:u.value}),M.value=!1,await(0,i.nextTick)();const t=f.value;if(t){const e=(t.pagedRows||[]).filter(e=>l.value.has(e._original?.id));e.length>0&&t.update(e,[])}v=!1},$=async()=>{if(s.value.length>0)return b.value||(b.value=Date.now()),c.value=A(),d.value=!1,await(0,i.nextTick)(),void I();try{await L()}catch(e){s.value=[],g.value=[e?.message||a("harvester.addons.vmMigration.errors.failedLoadVms")]}d.value=!1};return u.value.length>0&&r("complete",{selectedVMs:u.value}),$(),(t,n)=>{const r=(0,i.resolveComponent)("router-link");return d.value||M.value?((0,i.openBlock)(),(0,i.createBlock)((0,i.unref)(Ft.A),{key:0})):((0,i.openBlock)(),(0,i.createElementBlock)("div",os,[((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,null,(0,i.renderList)(g.value,(e,t)=>((0,i.openBlock)(),(0,i.createBlock)((0,i.unref)(zn.l),{key:t,color:"error",label:e},null,8,["label"]))),128)),(0,i.createElementVNode)("p",as,[(0,i.createTextVNode)((0,i.toDisplayString)((0,i.unref)(a)("harvester.addons.vmMigration.selectVms.discovered",{count:E.value}))+" ",1),e.provider?((0,i.openBlock)(),(0,i.createBlock)(r,{key:0,class:"provider-link",to:e.provider._detailLocation},{default:(0,i.withCtx)(()=>[(0,i.createTextVNode)((0,i.toDisplayString)(e.providerName),1)]),_:1},8,["to"])):(0,i.createCommentVNode)("",!0),n[0]||(n[0]=(0,i.createElementVNode)("br",null,null,-1)),O.value?((0,i.openBlock)(),(0,i.createElementBlock)("span",ss,[(0,i.createTextVNode)((0,i.toDisplayString)((0,i.unref)(a)("harvester.addons.vmMigration.selectVms.lastSynced",{time:O.value}))+" ",1),(0,i.createElementVNode)("a",{role:"button",class:(0,i.normalizeClass)(["text-bold",{disabled:M.value}]),onClick:(0,i.withModifiers)(B,["prevent"])},(0,i.toDisplayString)((0,i.unref)(a)("harvester.addons.vmMigration.selectVms.refreshNow")),3)])):(0,i.createCommentVNode)("",!0)]),(0,i.createVNode)((0,i.unref)(rs.A),{ref_key:"sortableTableRef",ref:f,rows:(0,i.unref)(c),headers:C.value,search:!0,"table-actions":!0,"row-actions":!1,groupable:!1,paging:!0,"key-field":"_key",onSelection:T},{"header-left":(0,i.withCtx)(()=>[(0,i.createElementVNode)("div",ls,[(0,i.createElementVNode)("h3",cs,(0,i.toDisplayString)((0,i.unref)(a)("harvester.addons.vmMigration.selectVms.availableVms")),1),(0,i.createElementVNode)("span",us,[(0,i.createElementVNode)("span",ds,(0,i.toDisplayString)(x.value)+" "+(0,i.toDisplayString)((0,i.unref)(a)("harvester.addons.vmMigration.selectVms.selected")),1),x.value>0?((0,i.openBlock)(),(0,i.createElementBlock)(i.Fragment,{key:0},[n[1]||(n[1]=(0,i.createElementVNode)("span",{class:"text-deemphasized"},"|",-1)),(0,i.createElementVNode)("a",{role:"button",onClick:(0,i.withModifiers)(N,["prevent"])},(0,i.toDisplayString)((0,i.unref)(a)("harvester.addons.vmMigration.selectVms.clearAll")),1)],64)):(0,i.createCommentVNode)("",!0)])])]),"cell:vmName":(0,i.withCtx)(({row:e})=>[(0,i.createElementVNode)("div",hs,[(0,i.createElementVNode)("span",ps,(0,i.toDisplayString)(e.vmName),1),(0,i.createElementVNode)("span",fs,(0,i.toDisplayString)(e.vmId),1)])]),"cell:resources":(0,i.withCtx)(({row:e})=>[(0,i.createElementVNode)("span",null,(0,i.toDisplayString)(e.resourcesDisplay),1),n[2]||(n[2]=(0,i.createElementVNode)("br",null,null,-1)),(0,i.createElementVNode)("span",ms,(0,i.toDisplayString)(e.resourcesSub),1)]),"cell:powerState":(0,i.withCtx)(({row:e})=>[(0,i.createVNode)((0,i.unref)(is.j),{label:e.powerState,color:"power-on"===e.powerStateClass?"bg-success":"bg-darker"},null,8,["label","color"])]),"cell:network":(0,i.withCtx)(({row:e})=>[(0,i.createElementVNode)("div",null,[((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,null,(0,i.renderList)(e.networks,(e,t)=>((0,i.openBlock)(),(0,i.createElementBlock)("div",{key:t,class:(0,i.normalizeClass)({"mt-4":t>0})},[(0,i.createElementVNode)("span",null,(0,i.toDisplayString)(e.name),1),n[3]||(n[3]=(0,i.createElementVNode)("br",null,null,-1)),(0,i.createElementVNode)("span",gs,(0,i.toDisplayString)(e.id),1)],2))),128))])]),"cell:datastore":(0,i.withCtx)(({row:e})=>[(0,i.createElementVNode)("div",null,[((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,null,(0,i.renderList)(e.datastores,(e,t)=>((0,i.openBlock)(),(0,i.createElementBlock)("div",{key:t,class:(0,i.normalizeClass)({"mt-4":t>0})},[(0,i.createElementVNode)("span",null,(0,i.toDisplayString)(e.name),1),n[4]||(n[4]=(0,i.createElementVNode)("br",null,null,-1)),(0,i.createElementVNode)("span",vs,(0,i.toDisplayString)(e.id),1)],2))),128))])]),_:1},8,["rows","headers"]),_.value&&k.value?((0,i.openBlock)(),(0,i.createBlock)(i.Teleport,{key:0,to:k.value},[(0,i.createElementVNode)("tr",bs,[(0,i.createElementVNode)("td",{colspan:C.value.length+1,class:"select-all-banner-cell"},[m.value?((0,i.openBlock)(),(0,i.createElementBlock)(i.Fragment,{key:0},[(0,i.createElementVNode)("span",null,(0,i.toDisplayString)((0,i.unref)(a)("harvester.addons.vmMigration.selectVms.selectAllBanner.allSelected")),1),(0,i.createElementVNode)("a",{role:"button",onClick:(0,i.withModifiers)(N,["prevent"])},(0,i.toDisplayString)((0,i.unref)(a)("harvester.addons.vmMigration.selectVms.selectAllBanner.clearSelection")),1)],64)):((0,i.openBlock)(),(0,i.createElementBlock)(i.Fragment,{key:1},[(0,i.createElementVNode)("span",null,(0,i.toDisplayString)((0,i.unref)(a)("harvester.addons.vmMigration.selectVms.selectAllBanner.pageOnly")),1),(0,i.createElementVNode)("a",{role:"button",onClick:(0,i.withModifiers)(P,["prevent"])},(0,i.toDisplayString)((0,i.unref)(a)("harvester.addons.vmMigration.selectVms.selectAllBanner.selectAll",{count:E.value})),1)],64))],8,ys)])],8,["to"])):(0,i.createCommentVNode)("",!0)]))}}};o(62127);const Os=(0,u.A)(ws,[["__scopeId","data-v-010bc59d"]]);var Ss=Os,Es=o(41837),xs=o(39407),_s=o(40960);const ks={"item-card-action":"",class:"rc-item-card-action","data-testid":"rc-item-card-action"};var Cs=(0,i.defineComponent)({__name:"RcItemCardAction",setup(e){return(e,t)=>((0,i.openBlock)(),(0,i.createElementBlock)("div",ks,[(0,i.renderSlot)(e.$slots,"default")]))}});o(15935);const As=Cs;var Ts=As,Rs=o(47799),Ns=o(48989);const Ps=["data-testid"],Is={key:0},Ms={key:0,class:"item-card-pill","data-testid":"item-card-pill"},Ds=["role","tabindex","aria-label","onKeydown"],Ls={class:"item-card-header-right"},Bs={key:0,class:"item-card-header-statuses"},$s=["data-testid"],Vs={key:1,class:"item-card-header-action-menu"},Fs={key:1,class:"item-card-content","data-testid":"item-card-content"};var js=(0,i.defineComponent)({__name:"RcItemCard",props:{id:{},value:{},header:{},image:{},actions:{},content:{},variant:{},pill:{},clickable:{type:Boolean},selected:{type:Boolean},disabled:{type:Boolean},role:{}},emits:["card-click","action-invoked"],setup(e,{emit:t}){(0,i.useCssVars)(e=>({v4111c564:v.value}));const n=(0,R.Pj)(),{t:r}=(0,na.s)(n),o=e,a=t;function s(e){if(o.disabled)return;const t="[item-card-action]";e.target.closest(t)||a("card-click",o.value)}function l(e){var t;return(null===e||void 0===e?void 0:e.key)?r(e.key):null!==(t=null===e||void 0===e?void 0:e.text)&&void 0!==t?t:""}const c=(0,i.ref)(null),u=(0,i.computed)(()=>l(o.header.title)),d=(0,i.computed)(()=>{var e;return l(null===(e=o.image)||void 0===e?void 0:e.alt)}),h=(0,i.computed)(()=>{var e;return l(null===(e=o.pill)||void 0===e?void 0:e.label)}),p=(0,i.computed)(()=>{var e;return l(null===(e=o.pill)||void 0===e?void 0:e.tooltip)}),f=(0,i.computed)(()=>l(o.content)),m=(0,i.computed)(()=>{var e;return(null===(e=o.header.statuses)||void 0===e?void 0:e.map(e=>l(e.tooltip)))||[]}),g=(0,i.computed)(()=>{var e;return{ariaLabel:o.clickable?r("itemCard.ariaLabel.clickable",{cardTitle:l(o.header.title)}):void 0,tabIndex:o.clickable&&!o.disabled?"0":void 0,role:null!==(e=o.role)&&void 0!==e?e:o.clickable&&!o.disabled?"button":void 0,actionMenuLabel:o.actions&&r("itemCard.actionMenu.label",{cardTitle:l(o.header.title)})}}),v=(0,i.computed)(()=>o.clickable?"pointer":"auto");return(t,n)=>{var r;const o=(0,i.resolveDirective)("clean-tooltip");return(0,i.openBlock)(),(0,i.createElementBlock)("div",{ref_key:"cardEl",ref:c,class:(0,i.normalizeClass)(["item-card",{clickable:e.clickable&&!e.disabled,selected:e.selected,disabled:e.disabled}]),"data-testid":`item-card-${e.id}`,onClick:s},[(0,i.createElementVNode)("div",{class:(0,i.normalizeClass)(["item-card-body",e.variant])},["small"!==e.variant?((0,i.openBlock)(),(0,i.createElementBlock)("div",Is,[(0,i.renderSlot)(t.$slots,"item-card-image",{},()=>[e.image?((0,i.openBlock)(),(0,i.createElementBlock)("div",{key:0,class:(0,i.normalizeClass)(["item-card-image",e.variant]),"data-testid":"item-card-image"},[e.image.icon?((0,i.openBlock)(),(0,i.createBlock)(Rs.A,{key:0,type:e.image.icon,size:"xxlarge"},null,8,["type"])):((0,i.openBlock)(),(0,i.createBlock)(_s.A,{key:1,src:e.image.src,alt:d.value,style:{width:"40px",height:"40px","object-fit":"contain"}},null,8,["src","alt"]))],2)):(0,i.createCommentVNode)("",!0)]),(0,i.renderSlot)(t.$slots,"item-card-pill",{},()=>[e.pill?(0,i.withDirectives)(((0,i.openBlock)(),(0,i.createElementBlock)("div",Ms,[(0,i.createTextVNode)((0,i.toDisplayString)(h.value),1)])),[[o,p.value]]):(0,i.createCommentVNode)("",!0)])])):(0,i.createCommentVNode)("",!0),(0,i.createElementVNode)("div",{class:(0,i.normalizeClass)(["item-card-body-details",e.variant])},[(0,i.createElementVNode)("div",{class:(0,i.normalizeClass)(["item-card-header",e.variant])},[(0,i.createElementVNode)("div",{class:"item-card-header-left","data-testid":"card-header-left",role:g.value.role,tabindex:g.value.tabIndex,"aria-label":g.value.ariaLabel,onClick:(0,i.withModifiers)(s,["self"]),onKeydown:[(0,i.withKeys)(s,["enter"]),(0,i.withKeys)((0,i.withModifiers)(s,["prevent"]),["space"])]},["small"===e.variant?(0,i.renderSlot)(t.$slots,"item-card-image",{},()=>[e.image?((0,i.openBlock)(),(0,i.createElementBlock)("div",{key:0,class:(0,i.normalizeClass)(["item-card-image",e.variant]),"data-testid":"item-card-image"},[e.image.icon?((0,i.openBlock)(),(0,i.createBlock)(Rs.A,{key:0,type:e.image.icon,size:"xlarge"},null,8,["type"])):((0,i.openBlock)(),(0,i.createBlock)(_s.A,{key:1,src:e.image.src,alt:d.value,style:{width:"32px",height:"32px","object-fit":"contain"}},null,8,["src","alt"]))],2)):(0,i.createCommentVNode)("",!0)],void 0,0):(0,i.createCommentVNode)("",!0),(0,i.renderSlot)(t.$slots,"item-card-header-title",{},()=>[e.header.title?(0,i.withDirectives)(((0,i.openBlock)(),(0,i.createBlock)(Ns.A,{key:0,size:3,class:(0,i.normalizeClass)(["item-card-header-title",e.variant]),"data-testid":"item-card-header-title"},{default:(0,i.withCtx)(()=>[(0,i.createTextVNode)((0,i.toDisplayString)(u.value),1)]),_:1},8,["class"])),[[o,u.value]]):(0,i.createCommentVNode)("",!0)])],40,Ds),(0,i.createElementVNode)("div",Ls,[(null===(r=e.header.statuses)||void 0===r?void 0:r.length)?((0,i.openBlock)(),(0,i.createElementBlock)("div",Bs,[((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,null,(0,i.renderList)(e.header.statuses,(e,t)=>((0,i.openBlock)(),(0,i.createElementBlock)("div",{key:t,class:"item-card-header-statuses-status","data-testid":"item-card-header-statuses-status"},[(0,i.withDirectives)((0,i.createElementVNode)("i",{class:(0,i.normalizeClass)(["icon",e.icon,e.color]),style:(0,i.normalizeStyle)({color:e.customColor}),"data-testid":`item-card-header-status-${t}`},null,14,$s),[[o,m.value[t]]])]))),128))])):(0,i.createCommentVNode)("",!0),t.$slots["item-card-actions"]?((0,i.openBlock)(),(0,i.createElementBlock)("div",Vs,[(0,i.renderSlot)(t.$slots,"item-card-actions")])):e.actions?((0,i.openBlock)(),(0,i.createBlock)((0,i.unref)(Ts),{key:2,class:"item-card-header-action-menu"},{default:(0,i.withCtx)(()=>[(0,i.createVNode)(ji.A,{"data-testid":"item-card-header-action-menu","button-aria-label":g.value.actionMenuLabel,"custom-actions":e.actions,onActionInvoked:n[0]||(n[0]=e=>a("action-invoked",e))},null,8,["button-aria-label","custom-actions"])]),_:1})):(0,i.createCommentVNode)("",!0)])],2),(0,i.renderSlot)(t.$slots,"item-card-sub-header",{},()=>[n[1]||(n[1]=(0,i.createElementVNode)("div",null,null,-1))]),t.$slots["item-card-content"]?(0,i.renderSlot)(t.$slots,"item-card-content",{},()=>[n[2]||(n[2]=(0,i.createElementVNode)("div",{class:"item-card-content","data-testid":"item-card-content"},null,-1))],void 0,0):e.content?((0,i.openBlock)(),(0,i.createElementBlock)("div",Fs,[(0,i.createElementVNode)("p",null,(0,i.toDisplayString)(f.value),1)])):(0,i.createCommentVNode)("",!0),(0,i.renderSlot)(t.$slots,"item-card-footer")],2)],2)],10,Ps)}}});o(89501);const Us=(0,u.A)(js,[["__scopeId","data-v-280664a8"]]);var Gs=Us;const Hs={class:"mapping-column"},qs={class:"mapping-section-title"},Qs={key:0,class:"text-deemphasized line-height-20"},zs={class:"card-content-column"},Ks={class:"card-content-row"},Ws={class:"mapping-source"},Xs={class:"source-name"},Ys={class:"mapping-target"},Zs={key:0,class:"storage-defaults-row"},Js={class:"storage-defaults"},el={class:"storage-defaults-info"},tl={class:"storage-defaults-summary"},nl={key:0,class:"text-deemphasized storage-defaults-inherited"},rl=["onClick"],il={key:1},ol={class:"used-by"};var al={__name:"MappingColumn",props:{title:{type:String,required:!0},description:{type:String,default:""},entries:{type:Array,default:()=>[]},options:{type:Array,default:()=>[]},placeholder:{type:String,default:""},showUsedBy:{type:Boolean,default:!1},clearable:{type:Boolean,default:!1},showVolumeSettings:{type:Boolean,default:!1},inheritedProviderName:{type:String,default:""}},emits:["edit-defaults"],setup(e,{emit:t}){const n=(0,R.Pj)(),{t:r}=(0,na.s)(n),o=e,a=t,s=e=>o.clearable&&e.target?[{label:r("harvester.addons.vmMigration.configureMappings.removeMap"),value:null,kind:"highlighted"},{label:"divider",disabled:!0,kind:"divider"},...o.options]:o.options,l=e=>{const t=e.volumeMode||Es.vU.FILE_SYSTEM,n=(e.accessModes||[]).join(", ");return r("harvester.addons.vmMigration.storageDefaults.summary",{volumeMode:t,accessModes:n})};return(t,n)=>((0,i.openBlock)(),(0,i.createElementBlock)("div",Hs,[(0,i.createElementVNode)("div",null,[(0,i.createElementVNode)("h3",qs,(0,i.toDisplayString)(e.title),1),e.description?((0,i.openBlock)(),(0,i.createElementBlock)("p",Qs,(0,i.toDisplayString)(e.description),1)):(0,i.createCommentVNode)("",!0)]),((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,null,(0,i.renderList)(e.entries,o=>((0,i.openBlock)(),(0,i.createBlock)((0,i.unref)(Gs),{id:o._key,key:o._key,variant:"small",header:{},class:"bg-light-gray"},{"item-card-content":(0,i.withCtx)(()=>[(0,i.createElementVNode)("div",zs,[(0,i.createElementVNode)("div",Ks,[(0,i.createElementVNode)("div",Ws,[(0,i.createElementVNode)("span",Xs,(0,i.toDisplayString)(o.name),1),(0,i.renderSlot)(t.$slots,"source-detail",{entry:o})]),(0,i.createElementVNode)("div",{class:(0,i.normalizeClass)(["mapping-arrow",o.target?"text-success":"text-deemphasized"])},[...n[0]||(n[0]=[(0,i.createElementVNode)("i",{class:"icon icon-right-arrow-alt","aria-hidden":"true"},null,-1)])],2),(0,i.createElementVNode)("div",Ys,[(0,i.createVNode)((0,i.unref)(Tr.A),{value:o.target,"onUpdate:value":e=>o.target=e,options:s(o),placeholder:e.placeholder+"...",searchable:!0},null,8,["value","onUpdate:value","options","placeholder"])])]),e.showVolumeSettings&&o.target?((0,i.openBlock)(),(0,i.createElementBlock)("div",Zs,[(0,i.createElementVNode)("div",Js,[(0,i.createElementVNode)("div",el,[(0,i.createElementVNode)("span",tl,(0,i.toDisplayString)(l(o)),1),e.inheritedProviderName&&o.inheritedFromProvider&&!o.overridden?((0,i.openBlock)(),(0,i.createElementBlock)("span",nl,(0,i.toDisplayString)((0,i.unref)(r)("harvester.addons.vmMigration.storageDefaults.inherited",{provider:e.inheritedProviderName})),1)):(0,i.createCommentVNode)("",!0)]),(0,i.createElementVNode)("a",{role:"button",class:"storage-defaults-edit",onClick:(0,i.withModifiers)(e=>a("edit-defaults",o),["prevent"])},(0,i.toDisplayString)((0,i.unref)(r)("harvester.addons.vmMigration.storageDefaults.edit")),9,rl)])])):(0,i.createCommentVNode)("",!0),e.showUsedBy&&o.usedBy&&o.usedBy.length?((0,i.openBlock)(),(0,i.createElementBlock)("div",il,[(0,i.createElementVNode)("span",ol,[(0,i.createTextVNode)((0,i.toDisplayString)((0,i.unref)(r)("harvester.addons.vmMigration.generic.usedBy"))+" ",1),(0,i.createElementVNode)("b",null,(0,i.toDisplayString)(o.usedBy.join(", ")),1)])])):(0,i.createCommentVNode)("",!0)])]),_:2},1032,["id"]))),128))]))}};o(9986);const sl=(0,u.A)(al,[["__scopeId","data-v-2e6ca264"]]);var ll=sl,cl=o(31019),ul=o(79535);const dl={class:"text-default-text"},hl={class:"text-deemphasized description"},pl={class:"settings-box"},fl={class:"buttons"},ml={class:"right-buttons"},gl=["disabled"];var vl={__name:"StorageDefaultsModal",props:{storageClassName:{type:String,default:""},providerName:{type:String,default:""},showInherited:{type:Boolean,default:!1},volumeMode:{type:String,default:Es.vU.FILE_SYSTEM},accessModes:{type:Array,default:()=>["ReadWriteMany"]},inheritedVolumeMode:{type:String,default:Es.vU.FILE_SYSTEM},inheritedAccessModes:{type:Array,default:()=>["ReadWriteMany"]}},emits:["apply","close"],setup(e,{emit:t}){const n=[Es.vU.FILE_SYSTEM,Es.vU.BLOCK],{READ_WRITE_ONCE:r="ReadWriteOnce",READ_ONLY_MANY:o="ReadOnlyMany",READ_WRITE_MANY:a="ReadWriteMany",READ_WRITE_ONCE_POD:s="ReadWriteOncePod"}=Es.Nb||{},l=[r,a,o,s],c=e,u=t,d=(0,R.Pj)(),{t:h}=(0,na.s)(d),p=(0,i.ref)(c.volumeMode||Es.vU.FILE_SYSTEM),f=(0,i.ref)(c.accessModes?.[0]||a),m=n.map(e=>({label:e,value:e})),g=l.map(e=>({label:e,value:e})),v=()=>{u("apply",{volumeMode:p.value,accessModes:[f.value]}),u("close")},b=()=>{p.value=c.inheritedVolumeMode||Es.vU.FILE_SYSTEM,f.value=c.inheritedAccessModes?.[0]||a},y=()=>{u("close")};return(t,n)=>((0,i.openBlock)(),(0,i.createBlock)((0,i.unref)(ul.h),{class:"storage-defaults-modal",name:"storageDefaultsDialog",width:620,height:"auto","click-to-close":!1,onClose:y},{default:(0,i.withCtx)(()=>[(0,i.createVNode)((0,i.unref)(cl.Z),{class:"storage-defaults-card","show-highlight-border":!1},{title:(0,i.withCtx)(()=>[(0,i.createElementVNode)("h4",dl,(0,i.toDisplayString)((0,i.unref)(h)("harvester.addons.vmMigration.storageDefaults.title",{name:e.storageClassName})),1)]),body:(0,i.withCtx)(()=>[(0,i.createElementVNode)("p",hl,[e.showInherited?((0,i.openBlock)(),(0,i.createElementBlock)(i.Fragment,{key:0},[(0,i.createTextVNode)((0,i.toDisplayString)((0,i.unref)(h)("harvester.addons.vmMigration.storageDefaults.descriptionInherited",{name:e.storageClassName,provider:e.providerName})),1)],64)):((0,i.openBlock)(),(0,i.createElementBlock)(i.Fragment,{key:1},[(0,i.createTextVNode)((0,i.toDisplayString)((0,i.unref)(h)("harvester.addons.vmMigration.storageDefaults.description",{name:e.storageClassName})),1)],64))]),(0,i.createElementVNode)("div",pl,[(0,i.createVNode)((0,i.unref)(Tr.A),{value:p.value,"onUpdate:value":n[0]||(n[0]=e=>p.value=e),class:"volume-mode",label:(0,i.unref)(h)("harvester.addons.vmMigration.storageDefaults.volumeMode"),options:(0,i.unref)(m),searchable:!1,clearable:!1},null,8,["value","label","options"]),(0,i.createVNode)((0,i.unref)(Tr.A),{value:f.value,"onUpdate:value":n[1]||(n[1]=e=>f.value=e),class:"access-mode",label:(0,i.unref)(h)("harvester.addons.vmMigration.storageDefaults.accessMode"),options:(0,i.unref)(g),searchable:!1,clearable:!1},null,8,["value","label","options"])])]),actions:(0,i.withCtx)(()=>[(0,i.createElementVNode)("div",fl,[(0,i.createElementVNode)("button",{class:"btn role-secondary",onClick:y},(0,i.toDisplayString)((0,i.unref)(h)("harvester.addons.vmMigration.storageDefaults.cancel")),1),(0,i.createElementVNode)("div",ml,[e.showInherited?((0,i.openBlock)(),(0,i.createElementBlock)("button",{key:0,class:"btn role-secondary mr-10",onClick:b},(0,i.toDisplayString)((0,i.unref)(h)("harvester.addons.vmMigration.storageDefaults.resetToProviderDefault")),1)):(0,i.createCommentVNode)("",!0),(0,i.createElementVNode)("button",{class:"btn role-primary",disabled:!f.value,onClick:v},(0,i.toDisplayString)(e.showInherited?(0,i.unref)(h)("harvester.addons.vmMigration.storageDefaults.applyOverride"):(0,i.unref)(h)("harvester.addons.vmMigration.storageDefaults.apply")),9,gl)])])]),_:1})]),_:1}))}};o(56169);const bl=(0,u.A)(vl,[["__scopeId","data-v-b0278fe2"]]);var yl=bl;const wl={key:1,class:"configure-mappings"},Ol={class:"text-deemphasized line-height-20"},Sl={class:"mappings-columns"},El={class:"source-detail text-deemphasized"},xl={key:0,class:"source-detail text-deemphasized"};var _l={__name:"ConfigureMappingsStep",props:{providerName:{type:String,default:""},provider:{type:Object,default:null},selectedVms:{type:Array,default:()=>[]},stepData:{type:Object,required:!0},useAllProviderData:{type:Boolean,default:!1},existingNetworkMap:{type:Object,default:null},existingStorageMap:{type:Object,default:null}},emits:["ready"],setup(e,{expose:t,emit:n}){const r=Es.vU.FILE_SYSTEM,o=Es.Nb?.READ_WRITE_MANY??"ReadWriteMany",a=e,s=n,c=(0,R.Pj)(),{t:u}=(0,na.s)(c),d=(0,i.ref)([]),h=(0,i.ref)([]),p=(0,i.ref)([]),f=(0,i.ref)([]),m=(0,i.ref)([]),g=(0,i.ref)([]),v=(0,i.ref)(!0),b=(0,i.ref)(!1),y=(0,i.ref)(null),{networkEntries:w,storageEntries:O}=(0,i.toRefs)(a.stepData),S=ra.Ex,E=(0,i.computed)(()=>{const e=[{label:u("harvester.addons.vmMigration.configureMappings.networkMapping.options.podNetworking"),value:"pod"},{label:u("harvester.addons.vmMigration.configureMappings.networkMapping.options.ignored"),value:"ignored"}];return h.value.forEach(t=>{const n=t.metadata?.namespace||"",r=t.metadata?.name||t.id,i=n?`${n}/${r}`:r;e.push({label:i,value:i})}),e}),x=(0,i.computed)(()=>{const e=p.value.filter(e=>!e.parameters?.backingImage).map(e=>{const t=e.name;let n=e.isDefault?`${t} (${u("generic.default")})`:t,r=!1;return(0,xs.N)(t)&&(n+=` (${u("harvester.storage.internal.label")})`,r=!0),{label:n,value:t,disabled:r}});return e.find(e=>"harvester-longhorn"===e.value)||e.unshift({label:"harvester-longhorn",value:"harvester-longhorn"}),e}),_=e=>{e&&w.value.forEach(t=>{const n=e.find(e=>e.source?.id===t.id||e.source?.name===t.name);if(n?.destination){const e=n.destination;"pod"===e.type?t.target="pod":"ignored"===e.type?t.target="ignored":"multus"===e.type&&e.name&&(t.target=e.namespace?`${e.namespace}/${e.name}`:e.name)}})},k=(e,{markOverridden:t=!1,captureInherited:n=!1}={})=>{e&&O.value.forEach(r=>{const i=e.find(e=>e.source?.id===r.id||e.source?.name===r.name);i?.destination?.storageClass&&(r.target=i.destination.storageClass,n&&(r.inheritedFromProvider=!0),i.destination.volumeMode&&(r.volumeMode=i.destination.volumeMode,n&&(r.inheritedVolumeMode=i.destination.volumeMode)),i.destination.accessMode&&(r.accessModes=[i.destination.accessMode],n&&(r.inheritedAccessModes=[i.destination.accessMode])),t&&(r.overridden=!0))})},C=()=>{const e=f.value.find(e=>e.metadata.name===`${a.providerName}-network-map-default`);_(e?.spec?.map)},A=()=>{const e=m.value.find(e=>e.metadata.name===`${a.providerName}-storage-map-default`);k(e?.spec?.map,{captureInherited:!0})},T=(0,i.computed)(()=>w.value.length>0&&w.value.every(e=>!!e.target)),N=(0,i.computed)(()=>O.value.length>0&&O.value.every(e=>!!e.target)),P=(0,i.computed)(()=>a.useAllProviderData?"":a.providerName),I=e=>{y.value=e,b.value=!0},M=()=>{b.value=!1,y.value=null},D=({volumeMode:e,accessModes:t})=>{if(y.value){y.value.volumeMode=e,y.value.accessModes=t;const n=y.value.inheritedVolumeMode,r=y.value.inheritedAccessModes?.[0],i=t?.[0];y.value.overridden=e!==n||i!==r}},L=(0,i.computed)(()=>!!a.useAllProviderData||w.value.length>0&&O.value.length>0&&T.value&&N.value);(0,i.watch)(L,e=>{s("ready",e)}),L.value&&s("ready",!0);const B=()=>{const e={};d.value.forEach(t=>{const n=t.name||t.id;t.networks&&t.networks.length>0&&t.networks.forEach(t=>{const r=t.id||t.name||"default";e[r]||(e[r]={name:t.name||u("harvester.addons.vmMigration.generic.unknown"),id:t.id||"",vlanId:t.vlanId||"",target:"",usedBy:[],_key:`net-${r}`}),e[r].usedBy.includes(n)||e[r].usedBy.push(n)})}),w.value=Object.values(e)},$=()=>{const e={};d.value.forEach(t=>{const n=t.name||t.id;t.disks&&t.disks.length>0&&t.disks.forEach(t=>{const i=t.datastore;i&&i.id&&(e[i.id]||(e[i.id]={name:i.name||u("harvester.addons.vmMigration.generic.unknown"),id:i.id,type:i.type||"",capacity:0,target:"",volumeMode:r,accessModes:[o],inheritedVolumeMode:r,inheritedAccessModes:[o],inheritedFromProvider:!1,overridden:!1,usedBy:[],_key:`stor-${i.id}`}),e[i.id].capacity+=t.capacity||0,e[i.id].usedBy.includes(n)||e[i.id].usedBy.push(n))})}),O.value=Object.values(e)},V=e=>{w.value=(Array.isArray(e)?e:[]).map(e=>({name:e.name||e.id,id:e.id||"",vlanId:e.vlanId||"",target:"",usedBy:[],_key:`net-${e.id||e.name}`}))},F=e=>{O.value=(Array.isArray(e)?e:[]).map(e=>({name:e.name||e.id,id:e.id||"",type:e.type||"",capacity:e.capacity||0,target:"",volumeMode:r,accessModes:[o],inheritedVolumeMode:r,inheritedAccessModes:[o],inheritedFromProvider:!1,overridden:!1,usedBy:[],_key:`stor-${e.id||e.name}`}))},j=e=>{const t=[];if(e.type&&t.push(e.type),e.capacity){const n=e.capacity/1073741824;n>=1024?t.push(u("harvester.addons.vmMigration.generic.memoryTb",{value:(n/1024).toFixed(1)})):t.push(u("harvester.addons.vmMigration.generic.memoryGb",{value:Math.round(n)}))}return t.join(" • ")},U=e=>({map:Ma(w.value,S),provider:e}),G=e=>({map:Da(O.value),provider:e}),H=async()=>{const e=c.getters["currentProduct"].inStore,t={source:{apiVersion:"forklift.konveyor.io/v1beta1",kind:"Provider",name:a.providerName,namespace:S},destination:{apiVersion:"forklift.konveyor.io/v1beta1",kind:"Provider",name:"host",namespace:S}};if(a.existingNetworkMap&&a.existingStorageMap)return a.existingNetworkMap.spec=U(t),await a.existingNetworkMap.save(),a.existingStorageMap.spec=G(t),await a.existingStorageMap.save(),{networkMapName:a.existingNetworkMap.metadata.name,storageMapName:a.existingStorageMap.metadata.name};const n=a.provider?[{apiVersion:"forklift.konveyor.io/v1beta1",kind:"Provider",name:a.provider.metadata.name,uid:a.provider.metadata.uid,blockOwnerDeletion:!0}]:[],r=await c.dispatch(`${e}/create`,{type:l.rk.FORKLIFT_NETWORK_MAP,metadata:{name:`${a.providerName}-network-map-${a.useAllProviderData?"default":(0,Di.vx)(5).toLowerCase()}`,namespace:S,ownerReferences:n},spec:U(t)});await r.save();const i=await c.dispatch(`${e}/create`,{type:l.rk.FORKLIFT_STORAGE_MAP,metadata:{name:`${a.providerName}-storage-map-${a.useAllProviderData?"default":(0,Di.vx)(5).toLowerCase()}`,namespace:S,ownerReferences:n},spec:G(t)});return await i.save(),{networkMapName:r.metadata.name,storageMapName:i.metadata.name}};t({saveMappings:H});const q=async()=>{const e=c.getters["currentProduct"].inStore;try{h.value=await c.dispatch(`${e}/findAll`,{type:Z.XG})}catch(r){h.value=[]}try{p.value=await c.dispatch(`${e}/findAll`,{type:Z.fJ})}catch(r){p.value=[]}try{f.value=await c.dispatch(`${e}/findAll`,{type:l.rk.FORKLIFT_NETWORK_MAP})}catch(r){f.value=[]}try{m.value=await c.dispatch(`${e}/findAll`,{type:l.rk.FORKLIFT_STORAGE_MAP})}catch(r){m.value=[]}if(0===w.value.length||0===O.value.length)try{const t=a.provider?.metadata?.uid,n=a.provider?.spec?.type||"vsphere",r=c.getters["harvester-common/getHarvesterClusterUrl"](`v1/harvester/providers/${n}/${t}`),[i,o]=await Promise.all([c.dispatch(`${e}/request`,{url:`${r}/networks`}).catch(()=>[]),c.dispatch(`${e}/request`,{url:`${r}/datastores?detail=1`}).catch(()=>[])]);if(a.useAllProviderData)0===w.value.length&&V(i),0===O.value.length&&F(o);else{d.value=a.selectedVms;const e=(Array.isArray(i)?i:[]).reduce((e,t)=>(e[t.id]=t.name,e),{}),t=(Array.isArray(o)?o:[]).reduce((e,t)=>(e[t.id]={name:t.name,type:t.type||""},e),{});d.value=d.value.map(n=>{const r={...n};return r.networks&&(r.networks=r.networks.map(t=>({...t,name:t.name||e[t.id]||t.id}))),r.disks&&(r.disks=r.disks.map(e=>{const n=e.datastore?t[e.datastore.id]:null;return{...e,datastore:e.datastore?{...e.datastore,name:e.datastore.name||n?.name||e.datastore.id,type:n?.type||""}:e.datastore}})),r}),0===w.value.length&&B(),0===O.value.length&&$()}}catch(r){g.value=[r?.message||u("harvester.addons.vmMigration.errors.failedResolveDetails")]}const t=w.value.some(e=>!!e.target),n=O.value.some(e=>!!e.target);t||(a.existingNetworkMap?.spec?.map?_(a.existingNetworkMap.spec.map):C()),n||(a.existingStorageMap?.spec?.map?k(a.existingStorageMap.spec.map,{markOverridden:!0}):A()),v.value=!1};return q(),(t,n)=>v.value?((0,i.openBlock)(),(0,i.createBlock)((0,i.unref)(Ft.A),{key:0})):((0,i.openBlock)(),(0,i.createElementBlock)("div",wl,[((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,null,(0,i.renderList)(g.value,(e,t)=>((0,i.openBlock)(),(0,i.createBlock)((0,i.unref)(zn.l),{key:t,color:"error",label:e},null,8,["label"]))),128)),(0,i.createElementVNode)("p",Ol,(0,i.toDisplayString)((0,i.unref)(u)("harvester.addons.vmMigration.configureMappings.description")),1),(0,i.createElementVNode)("div",Sl,[(0,i.createVNode)(ll,{title:(0,i.unref)(u)("harvester.addons.vmMigration.configureMappings.networkMapping.title"),description:(0,i.unref)(u)("harvester.addons.vmMigration.configureMappings.networkMapping.description"),entries:(0,i.unref)(w),options:E.value,placeholder:(0,i.unref)(u)("harvester.addons.vmMigration.configureMappings.networkMapping.placeholder"),"show-used-by":!e.useAllProviderData,clearable:e.useAllProviderData},{"source-detail":(0,i.withCtx)(({entry:e})=>[(0,i.createElementVNode)("span",El,(0,i.toDisplayString)((0,i.unref)(u)("harvester.addons.vmMigration.generic.vlan",{id:e.vlanId||"0"})),1)]),_:1},8,["title","description","entries","options","placeholder","show-used-by","clearable"]),(0,i.createVNode)(ll,{title:(0,i.unref)(u)("harvester.addons.vmMigration.configureMappings.storageMapping.title"),description:(0,i.unref)(u)("harvester.addons.vmMigration.configureMappings.storageMapping.description"),entries:(0,i.unref)(O),options:x.value,placeholder:(0,i.unref)(u)("harvester.addons.vmMigration.configureMappings.storageMapping.placeholder"),"show-used-by":!e.useAllProviderData,clearable:e.useAllProviderData,"show-volume-settings":!0,"inherited-provider-name":P.value,onEditDefaults:I},{"source-detail":(0,i.withCtx)(({entry:e})=>[e.type||e.capacity?((0,i.openBlock)(),(0,i.createElementBlock)("span",xl,(0,i.toDisplayString)(j(e)),1)):(0,i.createCommentVNode)("",!0)]),_:1},8,["title","description","entries","options","placeholder","show-used-by","clearable","inherited-provider-name"])]),b.value&&y.value?((0,i.openBlock)(),(0,i.createBlock)(yl,{key:0,"storage-class-name":y.value.target,"provider-name":e.providerName,"show-inherited":!!P.value,"volume-mode":y.value.volumeMode,"access-modes":y.value.accessModes,"inherited-volume-mode":y.value.inheritedVolumeMode,"inherited-access-modes":y.value.inheritedAccessModes,onApply:D,onClose:M},null,8,["storage-class-name","provider-name","show-inherited","volume-mode","access-modes","inherited-volume-mode","inherited-access-modes"])):(0,i.createCommentVNode)("",!0)]))}};o(53393);const kl=(0,u.A)(_l,[["__scopeId","data-v-fb484656"]]);var Cl=kl,Al=o(30588);const Tl={key:1,class:"review-migration"},Rl={class:"review-migration-content"},Nl={class:"migration-details"},Pl={class:"section-header"},Il={class:"section-title m-0"},Ml={class:"section-description text-deemphasized"},Dl={class:"name-row"},Ll={class:"summary-row"},Bl={class:"migration-mode-column"},$l={class:"detail-label"},Vl={class:"cold-migration-badge"},Fl={class:"text-deemphasized"},jl={class:"text-deemphasized"},Ul={class:"stats-column"},Gl={class:"detail-label"},Hl={class:"detail-value"},ql={class:"detail-label"},Ql={class:"detail-value"},zl={class:"detail-label"},Kl={class:"detail-value"},Wl={class:"detail-label"},Xl={class:"detail-value"},Yl={class:"detail-label"},Zl={class:"detail-value"},Jl={class:"vm-section"},ec={class:"section-title m-0"},tc={class:"vm-name-cell"},nc={class:"vm-name"},rc={class:"vm-id text-deemphasized"},ic={class:"text-deemphasized"},oc={class:"mapping-source"},ac={class:"mapping-target text-deemphasized"},sc={key:1,class:"text-deemphasized"},lc={class:"mapping-source"},cc={class:"mapping-target text-deemphasized"},uc={key:1,class:"text-deemphasized"},dc={class:"no-rows"},hc=["colspan"];var pc={__name:"ReviewMigrationStep",props:{providerName:{type:String,default:""},provider:{type:Object,default:null},selectedVms:{type:Array,default:()=>[]},mappingEntries:{type:Object,default:null},stepData:{type:Object,required:!0}},emits:["ready","edit-selection","edit-mappings","remove-vm"],setup(e,{expose:t,emit:n}){const r=e,o=n,a=(0,R.Pj)(),{t:s}=(0,na.s)(a),c=(0,i.computed)(()=>r.selectedVms),u=(0,i.ref)([]),d=(0,i.ref)([]),h=(0,i.ref)(""),p=(0,i.ref)(""),f=(0,i.ref)([]),m=(0,i.ref)([]),g=(0,i.ref)([]),v=(0,i.ref)([]),b=(0,i.ref)(!0);h.value=r.stepData.planName,p.value=r.stepData.targetNamespace||"";const y=ra.Ex,w=(0,i.computed)(()=>{const e=(h.value||"").trim();return e?m.value.includes(e)?s("harvester.addons.vmMigration.reviewMigration.planNameProviderConflict",{name:e}):g.value.includes(e)?s("harvester.addons.vmMigration.reviewMigration.planNamePlanConflict",{name:e}):"":""});(0,i.watch)(h,e=>{r.stepData.planName=e},{immediate:!0}),(0,i.watch)(p,e=>{r.stepData.targetNamespace=e}),(0,i.watch)([h,p,w],()=>{o("ready",!!h.value&&!!p.value&&!w.value)},{immediate:!0});const O=(e="")=>"pod"===e?s("harvester.addons.vmMigration.configureMappings.networkMapping.options.podNetworking"):"ignored"===e?s("harvester.addons.vmMigration.generic.ignored"):e,S=(0,i.computed)(()=>c.value.reduce((e,t)=>e+(t.cpuCount||t.numCPU||0),0)),E=(0,i.computed)(()=>{const e=c.value.reduce((e,t)=>e+(t.memoryMB||t.memory||0),0);return Ia(e)}),x=(0,i.computed)(()=>{let e=0;return c.value.forEach(t=>{t.disks&&t.disks.length>0&&(e+=t.disks.reduce((e,t)=>e+(t.capacity||0),0))}),Pa(e)}),_=(0,i.computed)(()=>c.value.map(e=>{const t=e.cpuCount||e.numCPU||0,n=e.memoryMB||e.memory||0,r=n?s("harvester.addons.vmMigration.generic.memoryGb",{value:Ia(n)}):"-";let i=0;e.disks&&e.disks.length>0&&(i=e.disks.reduce((e,t)=>e+(t.capacity||0),0));const o=i?s("harvester.addons.vmMigration.generic.memoryGb",{value:Pa(i)}):"-",a=e.guestName||e.guestOS||e.os||"-",l=e.powerState||e.status?.phase||"-",c=l.replace(/([a-z])([A-Z])/g,"$1 $2").replace(/^./,e=>e.toUpperCase()),h=c.toLowerCase().includes("on")||c.toLowerCase().includes("running")?"power-on":"power-off",p=u.value.filter(t=>t.usedBy&&t.usedBy.includes(e.name||e.id)),f=d.value.filter(t=>t.usedBy&&t.usedBy.includes(e.name||e.id)),m=p.map(e=>`${e.source} ${O(e.target)}`).join(", "),g=f.map(e=>`${e.source} ${e.target}`).join(", ");return{_key:e.id||e.vmId||e.metadata?.name,id:e.id,name:e.name||e.id,identifier:e.id||e.vmId||e.metadata?.name||"-",os:a,resources:s("harvester.addons.vmMigration.generic.vCpu",{count:t}),resourcesSub:`${r} • ${o}`,powerState:c,powerStateClass:h,networkMappings:p,storageMappings:f,networkMapping:m,storageMapping:g}})),k=[{name:"vmName",labelKey:"harvester.addons.vmMigration.reviewMigration.columns.vmName",value:"name",sort:["name"],subLabel:s("harvester.addons.vmMigration.generic.identifier"),width:200},{name:"os",labelKey:"harvester.addons.vmMigration.reviewMigration.columns.os",value:"os",sort:["os"],width:140},{name:"resources",labelKey:"harvester.addons.vmMigration.reviewMigration.columns.resources",value:"resources",sort:!1,width:120},{name:"powerState",labelKey:"harvester.addons.vmMigration.reviewMigration.columns.powerState",value:"powerState",sort:["powerState"],width:100},{name:"networkMapping",labelKey:"harvester.addons.vmMigration.reviewMigration.columns.networkMapping",value:"networkMapping",sort:["networkMapping"],subLabel:s("harvester.addons.vmMigration.reviewMigration.columns.sourceTarget"),width:220},{name:"storageMapping",labelKey:"harvester.addons.vmMigration.reviewMigration.columns.storageMapping",value:"storageMapping",sort:["storageMapping"],subLabel:s("harvester.addons.vmMigration.reviewMigration.columns.sourceTarget"),width:220},{name:"actions",label:" ",align:"right",sort:!1,width:40}],C=()=>o("edit-selection"),A=()=>o("edit-mappings"),T=e=>o("remove-vm",e),N=async()=>{const e=a.getters["currentProduct"].inStore,t={source:{apiVersion:Ra,kind:"Provider",name:r.providerName,namespace:y},destination:{apiVersion:Ra,kind:"Provider",name:"host",namespace:y}},n=`${h.value}-network-map`,i=`${h.value}-storage-map`,o=await a.dispatch(`${e}/create`,{type:l.rk.FORKLIFT_NETWORK_MAP,metadata:{name:n,namespace:y},spec:{map:Ma(r.mappingEntries?.networkEntries||[],y),provider:t}});await o.save();const s=await a.dispatch(`${e}/create`,{type:l.rk.FORKLIFT_STORAGE_MAP,metadata:{name:i,namespace:y},spec:{map:Da(r.mappingEntries?.storageEntries||[]),provider:t}});await s.save();const u=await a.dispatch(`${e}/create`,{type:l.rk.FORKLIFT_PLAN,metadata:{name:h.value,namespace:y},spec:{provider:t,map:{network:{apiVersion:Ra,kind:"NetworkMap",name:n,namespace:y},storage:{apiVersion:Ra,kind:"StorageMap",name:i,namespace:y}},targetNamespace:p.value,vms:c.value.map(e=>({id:e.id,name:e.name||e.id})),warm:!1}});await u.save(),await u.startMigration()},P=async()=>{const e=a.getters["currentProduct"].inStore;try{const t=await a.dispatch(`${e}/findAll`,{type:Z.CU});f.value=t.filter(e=>!e.isSystem).map(e=>e.metadata.name).sort().map(e=>({label:e,value:e}))}catch(t){f.value=[]}try{await a.dispatch(`${e}/findAll`,{type:l.rk.FORKLIFT_PROVIDER})}catch(t){}m.value=(a.getters[`${e}/all`](l.rk.FORKLIFT_PROVIDER)||[]).map(e=>e.metadata?.name).filter(Boolean);try{await a.dispatch(`${e}/findAll`,{type:l.rk.FORKLIFT_PLAN})}catch(t){}g.value=(a.getters[`${e}/all`](l.rk.FORKLIFT_PLAN)||[]).map(e=>e.metadata?.name).filter(Boolean),r.mappingEntries&&(u.value=(r.mappingEntries.networkEntries||[]).map(e=>({source:e.name||e.id,target:e.target||"",usedBy:e.usedBy||[]})),d.value=(r.mappingEntries.storageEntries||[]).map(e=>({source:e.name||e.id,target:e.target||"",usedBy:e.usedBy||[]}))),b.value=!1};return P(),t({startMigration:N}),(t,n)=>b.value?((0,i.openBlock)(),(0,i.createBlock)((0,i.unref)(Ft.A),{key:0})):((0,i.openBlock)(),(0,i.createElementBlock)("div",Tl,[(0,i.createElementVNode)("div",Rl,[w.value?((0,i.openBlock)(),(0,i.createBlock)((0,i.unref)(zn.l),{key:0,color:"error",label:w.value},null,8,["label"])):(0,i.createCommentVNode)("",!0),(0,i.createElementVNode)("div",Nl,[(0,i.createElementVNode)("div",Pl,[(0,i.createElementVNode)("h3",Il,(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.migrationDetails")),1),(0,i.createElementVNode)("span",Ml,(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.migrationDetailsDescription")),1)]),(0,i.createElementVNode)("div",Dl,[(0,i.createVNode)((0,i.unref)(Pn.o),{value:h.value,"onUpdate:value":n[0]||(n[0]=e=>h.value=e),class:"name-input",label:(0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.planName"),placeholder:(0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.planNamePlaceholder"),required:""},null,8,["value","label","placeholder"]),(0,i.createVNode)((0,i.unref)(Tr.A),{value:p.value,"onUpdate:value":n[1]||(n[1]=e=>p.value=e),class:"namespace-select",label:(0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.targetNamespace"),placeholder:(0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.targetNamespacePlaceholder"),options:f.value,required:""},null,8,["value","label","placeholder","options"])]),(0,i.createElementVNode)("div",Ll,[(0,i.createElementVNode)("div",Bl,[(0,i.createElementVNode)("span",$l,(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.migrationMode")),1),(0,i.createElementVNode)("span",Vl,(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.coldMigration")),1),(0,i.createElementVNode)("span",Fl,(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.coldMigrationDescription")),1),(0,i.createElementVNode)("span",jl,(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.coldMigrationHint")),1)]),(0,i.createElementVNode)("div",Ul,[(0,i.createElementVNode)("span",Gl,(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.provider")),1),(0,i.createElementVNode)("span",Hl,(0,i.toDisplayString)(e.providerName),1),(0,i.createElementVNode)("span",ql,(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.totalVms")),1),(0,i.createElementVNode)("span",Ql,(0,i.toDisplayString)(c.value.length),1),(0,i.createElementVNode)("span",zl,(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.vcpu")),1),(0,i.createElementVNode)("span",Kl,(0,i.toDisplayString)(S.value),1),(0,i.createElementVNode)("span",Wl,(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.memory")),1),(0,i.createElementVNode)("span",Xl,(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.generic.memoryGb",{value:E.value})),1),(0,i.createElementVNode)("span",Yl,(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.storage")),1),(0,i.createElementVNode)("span",Zl,(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.generic.memoryGb",{value:x.value})),1)])])]),(0,i.createElementVNode)("div",Jl,[(0,i.createVNode)((0,i.unref)(rs.A),{class:"vm-sortable-table",rows:_.value,headers:k,search:!1,"table-actions":!1,"row-actions":!1,groupable:!1,paging:!0,"key-field":"_key"},{"header-left":(0,i.withCtx)(()=>[(0,i.createElementVNode)("h4",ec,(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.virtualMachines"))+" ("+(0,i.toDisplayString)(c.value.length)+") ",1)]),"header-right":(0,i.withCtx)(()=>[(0,i.createElementVNode)("a",{href:"#",class:"edit-selection-link",onClick:(0,i.withModifiers)(C,["prevent"])},(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.editSelection")),1)]),"cell:vmName":(0,i.withCtx)(({row:e})=>[(0,i.createElementVNode)("div",tc,[(0,i.createElementVNode)("span",nc,(0,i.toDisplayString)(e.name),1),(0,i.createElementVNode)("span",rc,(0,i.toDisplayString)(e.identifier),1)])]),"cell:resources":(0,i.withCtx)(({row:e})=>[(0,i.createElementVNode)("span",null,(0,i.toDisplayString)(e.resources),1),n[2]||(n[2]=(0,i.createElementVNode)("br",null,null,-1)),(0,i.createElementVNode)("span",ic,(0,i.toDisplayString)(e.resourcesSub),1)]),"cell:powerState":(0,i.withCtx)(({row:e})=>[(0,i.createVNode)((0,i.unref)(is.j),{label:e.powerState,color:"power-on"===e.powerStateClass?"bg-warning":"bg-darker"},null,8,["label","color"])]),"cell:networkMapping":(0,i.withCtx)(({row:e})=>[e.networkMappings.length?((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,{key:0},(0,i.renderList)(e.networkMappings,(e,t)=>((0,i.openBlock)(),(0,i.createElementBlock)("div",{key:"net-"+t,class:"mapping-cell"},[(0,i.createElementVNode)("span",oc,(0,i.toDisplayString)(e.source),1),(0,i.createElementVNode)("span",ac,"→ "+(0,i.toDisplayString)(O(e.target)),1)]))),128)):((0,i.openBlock)(),(0,i.createElementBlock)("span",sc,"-"))]),"cell:storageMapping":(0,i.withCtx)(({row:e})=>[e.storageMappings.length?((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,{key:0},(0,i.renderList)(e.storageMappings,(e,t)=>((0,i.openBlock)(),(0,i.createElementBlock)("div",{key:"stor-"+t,class:"mapping-cell"},[(0,i.createElementVNode)("span",lc,(0,i.toDisplayString)(e.source),1),(0,i.createElementVNode)("span",cc,"→ "+(0,i.toDisplayString)(e.target),1)]))),128)):((0,i.openBlock)(),(0,i.createElementBlock)("span",uc,"-"))]),"cell:actions":(0,i.withCtx)(({row:e})=>[(0,i.createVNode)((0,i.unref)(Al.Jj),{"aria-label":(0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.actions.menuLabel")},{dropdownCollection:(0,i.withCtx)(()=>[(0,i.createVNode)((0,i.unref)(Al.s$),{onClick:A},{default:(0,i.withCtx)(()=>[(0,i.createTextVNode)((0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.actions.editMappings")),1)]),_:1}),(0,i.createVNode)((0,i.unref)(Al.s$),{class:"text-error",onClick:t=>T(e.id)},{default:(0,i.withCtx)(()=>[(0,i.createTextVNode)((0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.actions.removeFromPlan")),1)]),_:1},8,["onClick"])]),default:(0,i.withCtx)(()=>[(0,i.createVNode)((0,i.unref)(Al.Nq),{variant:"ghost","aria-label":(0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.actions.menuLabel")},{default:(0,i.withCtx)(()=>[...n[3]||(n[3]=[(0,i.createElementVNode)("i",{class:"icon icon-actions"},null,-1)])]),_:1},8,["aria-label"])]),_:2},1032,["aria-label"])]),"no-rows":(0,i.withCtx)(()=>[(0,i.createElementVNode)("tr",dc,[(0,i.createElementVNode)("td",{colspan:k.length,class:"text-center"},[(0,i.createTextVNode)((0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.noVmSelected"))+" ",1),(0,i.createElementVNode)("a",{href:"#",class:"edit-selection-link",onClick:(0,i.withModifiers)(C,["prevent"])},(0,i.toDisplayString)((0,i.unref)(s)("harvester.addons.vmMigration.reviewMigration.noVmSelectedLink")),1)],8,hc)])]),_:1},8,["rows"])]),((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,null,(0,i.renderList)(v.value,(e,t)=>((0,i.openBlock)(),(0,i.createBlock)((0,i.unref)(zn.l),{key:t,color:"error",label:e},null,8,["label"]))),128))])]))}};o(58888);const fc=(0,u.A)(pc,[["__scopeId","data-v-2a853fb2"]]);var mc=fc;function gc(e){const t=e?.target;"INPUT"!==t?.tagName||t.closest(".v-select")||e.preventDefault()}var vc={__name:"vm-migration-wizard",setup(e){const t=(0,R.Pj)(),{t:n}=(0,na.s)(t),o=(0,i.ref)(null),a=(0,i.ref)(null),s=(0,i.ref)(null),l=(0,i.ref)(""),c=(0,i.ref)(null),u=(0,i.ref)([]),d=(0,i.ref)([]),h=(0,i.ref)(!1),p=(0,i.ref)(!1),f=(0,i.ref)(!1),m=(0,i.ref)(!1),g=(0,i.ref)(!0),v=(0,i.ref)(!1),b=(0,i.ref)(!1),y=(0,i.ref)({save:()=>Promise.resolve()}),w=(0,i.reactive)({provider:{selectedProvider:"__create_new__",providerName:"",url:"",username:"",password:"",skipTlsVerify:!1,vddkInitImage:"",testPassed:!1,testResult:null,testError:null,createdProvider:null,createdSecret:null},vms:{discoveredVMs:[],selectedVMIds:new Set,tableRows:[]},mappings:{networkEntries:[],storageEntries:[]},review:{planName:"",targetNamespace:""}}),O=(0,i.reactive)([{name:"configure-provider",label:n("harvester.addons.vmMigration.wizard.steps.configureProvider.label"),subtext:n("harvester.addons.vmMigration.wizard.steps.configureProvider.description"),ready:!1},{name:"select-vms",label:n("harvester.addons.vmMigration.wizard.steps.selectVms.label"),subtext:n("harvester.addons.vmMigration.wizard.steps.selectVms.description"),ready:!1},{name:"configure-mappings",label:n("harvester.addons.vmMigration.wizard.steps.configureMappings.label"),subtext:n("harvester.addons.vmMigration.wizard.steps.configureMappings.description"),ready:!1},{name:"review-migration",label:n("harvester.addons.vmMigration.wizard.steps.reviewMigration.label"),subtext:n("harvester.addons.vmMigration.wizard.steps.reviewMigration.description"),ready:!1}]);(0,i.watch)([p,f],()=>{O[0].ready=p.value&&!f.value},{immediate:!0}),(0,i.watch)([m,g],()=>{O[1].ready=m.value&&!g.value}),(0,i.watch)(v,e=>{O[2].ready=e}),(0,i.watch)(b,e=>{O[3].ready=e});const S=(0,i.computed)(()=>o.value?.$refs?.Wizard),E=(0,i.ref)(!1);(0,i.watch)(()=>S.value?.activeStepIndex,(e,t)=>{0!==t||1!==e||h.value||(S.value.goToStep(1),E.value=!0,a.value.clickTestButton())}),(0,i.watch)(h,e=>{e&&E.value&&(E.value=!1,O[0].ready=!0,S.value.goToStep(2))}),(0,i.watch)(f,e=>{e||!E.value||h.value||(E.value=!1)});const x=e=>{l.value=e.providerName,c.value=e.provider,h.value=!0},_=e=>{p.value=e},k=e=>{f.value=e},C=e=>{h.value=e},A=e=>{u.value=e.selectedVMs,m.value=e.selectedVMs.length>0},T=e=>{g.value=e},N=e=>{v.value=e},P=e=>{b.value=e},I=()=>{S.value?.goToStep(2)},M=()=>{S.value?.goToStep(3)},D=e=>{u.value=u.value.filter(t=>t.id!==e),w.vms.selectedVMIds.delete(e),m.value=u.value.length>0,m.value||(b.value=!1)};(0,i.watch)(()=>w.provider.providerName,(e,t)=>{t&&e!==t&&(w.vms.discoveredVMs=[],w.vms.selectedVMIds=new Set,w.vms.tableRows=[],u.value=[],m.value=!1,w.mappings.networkEntries=[],w.mappings.storageEntries=[],v.value=!1,w.review.planName="",b.value=!1)}),(0,i.watch)(u,(e,t)=>{const n=new Set(t.map(e=>e.id)),r=e.some(e=>!n.has(e.id));t.length>0&&r&&(w.mappings.networkEntries=[],w.mappings.storageEntries=[],v.value=!1,w.review.planName="",b.value=!1)});const L={name:`${r.KR}-c-cluster-vm-migration`,params:{product:t.getters["productId"],cluster:t.getters["clusterId"]}},B=async e=>{try{await s.value.startMigration(),e(!0),ia().push(L)}catch(t){d.value=(0,Rr.rz)(t).map(e=>"string"===typeof e?e:(0,Rr.As)(e)),e(!1)}},$=()=>{ia().push(L)};return(e,t)=>((0,i.openBlock)(),(0,i.createBlock)((0,i.unref)(Cr.A),{ref_key:"cruRef",ref:o,resource:y.value,mode:"create",steps:O,errors:d.value,"validation-passed":!0,"can-yaml":!1,"cancel-event":!0,"finish-mode":"finish","finish-button-mode":"createAndStart",class:"wizard",onKeydownCapture:(0,i.withKeys)((0,i.unref)(gc),["enter"]),onCancel:$,onFinish:B},{"configure-provider":(0,i.withCtx)(()=>[(0,i.createVNode)(ns,{ref_key:"providerStepRef",ref:a,"step-data":w.provider,onComplete:x,onReady:C,onFormValid:_,onTesting:k},null,8,["step-data"])]),"select-vms":(0,i.withCtx)(()=>[(0,i.createVNode)(Ss,{"provider-name":l.value,provider:c.value,"step-data":w.vms,onComplete:A,onLoading:T},null,8,["provider-name","provider","step-data"])]),"configure-mappings":(0,i.withCtx)(()=>[(0,i.createVNode)(Cl,{"provider-name":l.value,provider:c.value,"selected-vms":u.value,"step-data":w.mappings,onReady:N},null,8,["provider-name","provider","selected-vms","step-data"])]),"review-migration":(0,i.withCtx)(()=>[(0,i.createVNode)(mc,{ref_key:"reviewStepRef",ref:s,"provider-name":l.value,provider:c.value,"selected-vms":u.value,"mapping-entries":w.mappings,"step-data":w.review,onReady:P,onEditSelection:I,onEditMappings:M,onRemoveVm:D},null,8,["provider-name","provider","selected-vms","mapping-entries","step-data"])]),_:1},8,["resource","steps","errors","onKeydownCapture"]))}};const bc=vc;var yc=bc,wc={__name:"provider-wizard",setup(e){const t=(0,R.Pj)(),n=oa(),{t:o}=(0,na.s)(t),a=(0,i.ref)(null),s=(0,i.ref)(null),c=(0,i.ref)(null),u=(0,i.ref)(""),d=(0,i.ref)(null),h=(0,i.ref)([]),p=(0,i.ref)(!1),f=(0,i.ref)(!1),m=(0,i.ref)(!1),g=(0,i.ref)(!1),v=(0,i.ref)(null),b=(0,i.ref)(null),y=(0,i.ref)(!0),w=(0,i.ref)({save:()=>Promise.resolve()}),O=n.query?.providerId||null,S=!!O,E=(0,i.reactive)({provider:{selectedProvider:S?"":"__create_new__",providerName:"",url:"",username:"",password:"",skipTlsVerify:!1,vddkInitImage:"",testPassed:!1,testResult:null,testError:null,createdProvider:null,createdSecret:null},mappings:{networkEntries:[],storageEntries:[]}}),x=(0,i.reactive)([{name:"configure-provider",label:o("harvester.addons.vmMigration.wizard.steps.configureProvider.label"),subtext:o("harvester.addons.vmMigration.wizard.steps.configureProvider.description"),ready:!1},{name:"configure-mappings",label:o("harvester.addons.vmMigration.wizard.steps.configureMappings.label"),subtext:o("harvester.addons.vmMigration.wizard.steps.configureMappings.description"),ready:!1}]);(0,i.watch)([f,m],()=>{x[0].ready=f.value&&!m.value},{immediate:!0}),(0,i.watch)(g,e=>{x[1].ready=e});const _=(0,i.computed)(()=>a.value?.$refs?.Wizard),k=(0,i.ref)(!1);(0,i.watch)(()=>_.value?.activeStepIndex,(e,t)=>{0!==t||1!==e||p.value||(_.value.goToStep(1),k.value=!0,s.value.clickTestButton())}),(0,i.watch)(p,e=>{e&&k.value&&(k.value=!1,x[0].ready=!0,_.value.goToStep(2))});const C=(0,i.computed)(()=>o(S?"harvester.addons.vmMigration.providerWizard.editTitle":"harvester.addons.vmMigration.providerWizard.title")),A=e=>{u.value=e.providerName,d.value=e.provider,p.value=!0},T=e=>{f.value=e},N=e=>{m.value=e},P=e=>{p.value=e},I=e=>{g.value=e};(0,i.watch)(()=>E.provider.providerName,(e,t)=>{t&&e!==t&&(E.mappings.networkEntries=[],E.mappings.storageEntries=[],g.value=!1)});const M={name:`${r.KR}-c-cluster-resource`,params:{product:t.getters["productId"],cluster:t.getters["clusterId"],resource:l.rk.FORKLIFT_PROVIDER}},D=async e=>{try{await c.value.saveMappings(),e(!0),ia().push(M)}catch(t){h.value=(0,Rr.rz)(t).map(e=>"string"===typeof e?e:(0,Rr.As)(e)),e(!1)}},L=()=>{ia().push(M)},B=async()=>{if(!S)return void(y.value=!1);const e=t.getters["currentProduct"].inStore;try{const r=await t.dispatch(`${e}/find`,{type:l.rk.FORKLIFT_PROVIDER,id:O,opt:{force:!0}});d.value=r,u.value=r.metadata.name,E.provider.selectedProvider=r.metadata.name,E.provider.providerName=r.metadata.name,E.provider.url=r.spec?.url||"",E.provider.vddkInitImage=r.spec?.settings?.vddkInitImage||"",E.provider.createdProvider=r;const i=r.spec?.secret;if(i){const n=await t.dispatch(`${e}/findAll`,{type:Z.bB,opt:{labelSelector:`ui.forklift/created-for-resource-type=${l.rk.FORKLIFT_PROVIDER}`}}),r=n.find(e=>e.metadata.name===i.name&&e.metadata.namespace===i.namespace);r?.data&&(E.provider.username=Na(r.data.user),E.provider.password=Na(r.data.password),E.provider.skipTlsVerify="true"===Na(r.data.insecureSkipVerify),E.provider.createdSecret=r)}try{const n=await t.dispatch(`${e}/findAll`,{type:l.rk.FORKLIFT_NETWORK_MAP}),i=await t.dispatch(`${e}/findAll`,{type:l.rk.FORKLIFT_STORAGE_MAP});v.value=n.find(e=>e.metadata.name===`${r.metadata.name}-network-map-default`)||null,b.value=i.find(e=>e.metadata.name===`${r.metadata.name}-storage-map-default`)||null}catch(n){}}catch(r){h.value=[o("harvester.addons.vmMigration.errors.failedLoadProvider",{error:r.message||(0,Rr.As)(r)})]}y.value=!1};return B(),(e,t)=>y.value?((0,i.openBlock)(),(0,i.createBlock)((0,i.unref)(Ft.A),{key:0})):((0,i.openBlock)(),(0,i.createBlock)((0,i.unref)(Cr.A),{key:1,ref_key:"cruRef",ref:a,resource:w.value,mode:S?"edit":"create",steps:x,errors:h.value,"validation-passed":!0,"can-yaml":!1,"cancel-event":!0,title:C.value,"finish-mode":"finish",class:"wizard",onKeydownCapture:(0,i.withKeys)((0,i.unref)(gc),["enter"]),onCancel:L,onFinish:D},{"configure-provider":(0,i.withCtx)(()=>[(0,i.createVNode)(ns,{ref_key:"providerStepRef",ref:s,"step-data":E.provider,"create-only":!0,"edit-mode":S,onComplete:A,onReady:P,onFormValid:T,onTesting:N},null,8,["step-data"])]),"configure-mappings":(0,i.withCtx)(()=>[(0,i.createVNode)(Cl,{ref_key:"mappingsStepRef",ref:c,"provider-name":u.value,provider:d.value,"step-data":E.mappings,"use-all-provider-data":!0,"existing-network-map":v.value,"existing-storage-map":b.value,onReady:I},null,8,["provider-name","provider","step-data","existing-network-map","existing-storage-map"])]),_:1},8,["resource","mode","steps","errors","title","onKeydownCapture"]))}};const Oc=wc;var Sc=Oc;const Ec=[{route:{name:`${r.KR}-c-cluster-unsupported-standalone`,path:"/:product",component:Xo},parent:"blank"},{route:{name:`${r.KR}-c-cluster-unsupported`,path:"/:product",component:Xo},parent:"plain"},{name:`${r.KR}-c-cluster-support`,path:"/:product/c/:cluster/support",component:xe},{route:{name:`${r.KR}-c-cluster-console-uid-serial`,path:"/:product/c/:cluster/console/:uid/serial",component:$t},parent:"blank"},{route:{name:`${r.KR}-c-cluster-console-uid-vnc`,path:"/:product/c/:cluster/console/:uid/vnc",component:Ht},parent:"blank"},{name:`${r.KR}-c-cluster-airgapupgrade`,path:"/:product/c/:cluster/airgapupgrade",component:Xr},{name:`${r.KR}-c-cluster-brand`,path:"/:product/c/:cluster/brand",component:ir},{name:`${r.KR}-c-cluster-alertmanagerconfig-alertmanagerconfigid-receiver`,path:"/:product/c/:cluster/alertmanagerconfig/:alertmanagerconfigid/receiver",component:$o},{name:`${r.KR}-c-cluster-members`,path:"/:product/c/:cluster/members",component:hi},{name:`${r.KR}-c-cluster`,path:"/:product/c/:cluster",component:h},{name:`${r.KR}-c-cluster-projectsnamespaces`,path:"/:product/c/:cluster/projectsnamespaces",component:Wi},{name:`${r.KR}-c-cluster-vm-migration`,path:"/:product/c/:cluster/vm-migration",component:Ta},{name:`${r.KR}-c-cluster-vm-migration-wizard`,path:"/:product/c/:cluster/vm-migration/wizard",component:yc},{name:`${r.KR}-c-cluster-vm-migration-provider-wizard`,path:"/:product/c/:cluster/vm-migration/provider-wizard",component:Sc},{name:`${r.KR}-c-cluster-resource`,path:"/:product/c/:cluster/:resource",component:Wt},{name:`${r.KR}-c-cluster-resource-create`,path:"/:product/c/:cluster/:resource/create",component:cr},{name:`${r.KR}-c-cluster-resource-id`,path:"/:product/c/:cluster/:resource/:id",component:pr},{name:`${r.KR}-c-cluster-resource-namespace-id`,path:"/:product/c/:cluster/:resource/:namespace/:id",component:vr}];var xc=Ec,_c=o(52225),kc=o.n(_c);const Cc=function(){return{latestBundleId:"",bundlePending:!1,showBundleModal:!1,bundlePercentage:0,uploadingImages:[],uploadingImageError:{},downloadImageId:"",downloadImageInProgress:!1,isDownloadImageCancel:!1}},Ac={setDownloadImageId(e,t){e.downloadImageId=t},setDownloadImageCancel(e,t){e.isDownloadImageCancel=t},setDownloadImageInProgress(e,t){e.downloadImageInProgress=t},setLatestBundleId(e,t){e.latestBundleId=t},setBundlePending(e,t){e.bundlePending=t},toggleBundleModal(e,t){e.showBundleModal=t},setBundlePercentage(e,t){e.bundlePercentage=t},uploadStart(e,t){e.uploadingImages.push(t)},uploadError(e,{name:t,message:n}){e.uploadingImageError[t]=n},uploadEnd(e,t){const n=e.uploadingImages.filter(e=>e!==t);e["uploadingImages"]=n}},Tc={isHarvesterPrime:(e,t,n,r)=>{const i=r["harvester/byId"]?.(l.rk.SETTING,"server-flavor");return"prime"===(i?.value||i?.default)},privateLabel:(e,t,n,r)=>{const i=r["management/byId"]?.(Z.Mc.SETTING,J.HG.PL),o=i?.value||"";return t.isHarvesterPrime&&o===(i?.default||"Harvester")?"":o},getBundleId(e){return e.latestBundleId},isDownloadImageCancel(e){return e.isDownloadImageCancel},isDownloadImageInProgress(e){return e.downloadImageInProgress},isBundlePending(e){return e.bundlePending},isShowBundleModal(e){return e.showBundleModal},getBundlePercentage(e){return e.bundlePercentage},uploadingImages(e){return e.uploadingImages},uploadingImageError(e){return t=>e.uploadingImageError[t]},getServerVersion:(e,t,n,r)=>()=>{const e=r["harvester/byId"](l.rk.SETTING,"server-version")?.value;return(0,Oe.HF)(e)},getFeatureEnabled:(e,t,n,r)=>(e,t)=>{const n=t||r["harvester/byId"](l.rk.SETTING,"server-version")?.value;return(0,Oe.at)(e,n)},getHarvesterClusterUrl:(e,t,n,r)=>e=>{if(r["isMultiCluster"]){const t=r["clusterId"],n=`/k8s/clusters/${t}/${e}`;return`${n}`}return e}},Rc={async downloadImageProgress({state:e,dispatch:t,commit:n,rootGetters:r}){const i=kc()(window.history.href),o=e.downloadImageId;let a=await t("harvester/find",{type:l.rk.VM_IMAGE_DOWNLOADER,id:o},{root:!0});await n("setDownloadImageInProgress",!0);let s=0;const c=setInterval(async()=>{if(s+=1,s%3===0&&(a=await t("harvester/find",{type:l.rk.VM_IMAGE_DOWNLOADER,id:o,opt:{force:!0}},{root:!0})),!0!==e.isDownloadImageCancel){if("Ready"===a?.status?.status){if(a=r["harvester/byId"](l.rk.VM_IMAGE_DOWNLOADER,o),setTimeout(()=>{n("setDownloadImageInProgress",!1),t("promptModal")},600),r["isMultiCluster"]){const e=r["clusterId"],t=`/k8s/clusters/${e}`;window.location.href=`${i.origin}${t}/v1/harvester/${l.rk.IMAGE}/${o}/download`}else{const e=`${i.origin}/v1/harvester/${l.rk.IMAGE}/${o}/download`;window.location.href=e}clearInterval(c)}}else clearInterval(c)},1e3)},async bundleProgress({state:e,dispatch:t,commit:n,rootGetters:r}){const i=kc()(window.history.href),o=e.latestBundleId;let a=await t("harvester/find",{type:l.rk.SUPPORT_BUNDLE,id:o},{root:!0});const s=r["i18n/t"];let c=0;await n("setBundlePending",!0);const u=setInterval(async()=>{if(c+=1,c%3===0&&(a=await t("harvester/find",{type:l.rk.SUPPORT_BUNDLE,id:o,opt:{force:!0}},{root:!0})),"ready"!==a.bundleState){a=r["harvester/byId"](l.rk.SUPPORT_BUNDLE,o);const e=a.precent;if(n("setBundlePercentage",e),a?.bundleMessage){const e=a?.bundleMessage;t("growl/fromError",{title:s("generic.notification.title.error"),err:e},{root:!0}),clearInterval(u),n("setBundlePending",!1),n("toggleBundleModal",!1)}}else{const e=o.split("/")[1];if(n("setBundlePercentage",1),setTimeout(()=>{n("toggleBundleModal",!1),n("setBundlePending",!1),n("setBundlePercentage",0)},600),r["isMultiCluster"]){const t=r["clusterId"],n=`/k8s/clusters/${t}`;window.location.href=`${i.origin}${n}/v1/harvester/supportbundles/${e}/download`}else window.location.href=`${i.origin}/v1/harvester/supportbundles/${e}/download`;clearInterval(u)}},1e3)}},Nc=()=>({state:Cc,getters:{...Tc},mutations:{...Ac},actions:{...Rc}}),Pc={namespace:`${r.KR}-common`,isClusterStore:!1};var Ic={specifics:Nc(),config:Pc},Mc=o(25314);const Dc="CSRF";var Lc=o(79401),Bc=o(23464),$c=o.n(Bc),Vc=o(4364);function Fc(e,t,n){return(t=jc(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function jc(e){var t=Uc(e,"string");return"symbol"==typeof t?t:t+""}function Uc(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}const Gc={WATCH_PENDING:"pending",WATCH_REQUESTED:"requested",WATCHING:"watching",STOPPED:"stopped",REMOVE_PENDING:"removed_pending",REMOVE_REQUESTED:"removed_requested"},Hc=({resourceType:e,type:t,namespace:n,id:r,selector:i,mode:o}={})=>{const a={type:e||t,namespace:n,id:r,selector:i,mode:o};return Object.entries(a).map(([e,t])=>`${e}=${t||""}`).join(",")},qc=e=>{const{resourceType:t,namespace:n,id:r,selector:i}=e,o={resourceType:t,id:r,namespace:n,selector:i};return Hc(o)},{WATCH_PENDING:Qc,WATCH_REQUESTED:zc,WATCHING:Kc,REMOVE_PENDING:Wc,REQUESTED_REMOVE:Xc}=Gc;class Yc extends Nt{constructor(e,t=!0,n=null,r=null,i=null,o){super(e,t,n,r,i,!0),Fc(this,"watches",{}),Fc(this,"status",""),Fc(this,"debugWatcher",!1),Fc(this,"csrf",void 0),this.baseUrl=self.location.origin+e.replace("subscribe",""),this.csrf=o,this.addEventListener(Ot,e=>{this.trace(Ot,": processing previously requested or watched resources"),Object.values(this.watches).forEach(e=>{const{status:t,error:n}=e,r=Hc(e);[Qc,zc,Kc].includes(t)&&!n?(this.trace(Ot,": re-watching previously required resource",r,t),this.watches[r].status=Qc,this.watch(r)):[Wc].includes(t)&&(this.trace(Ot,": un-watching previously watched resource",r,t),this.watches[r].status=Wc,this.unwatch(r))})})}trace(...e){this.debugWatcher&&Vc.info("Resource Watcher:",...e)}setDebug(e){this.debugWatcher=!!e}watchExists(e){return!!this.watches?.[e]}watch(e,t,n,r={},i){const{resourceType:o,id:a,namespace:s,selector:l,force:c}=r;if(this.trace("watch:","requested",e),[zc,Kc].includes(this.watches?.[e]?.status))return void this.trace("watch:","already requested or watching, aborting",e);if(!c&&this.watches?.[e]?.error)return void(this.watches?.[e]?.error.reason!==Rt&&this.trace("watch:","in error, aborting",e));const u=o||this.watches?.[e]?.resourceType,d=a||this.watches?.[e]?.id,h=s||this.watches?.[e]?.namespace,p=l||this.watches?.[e]?.selector,f=this.watches?.[e]?.skipResourceVersion||i,m={resourceType:u,id:d,namespace:h,selector:p},g=n||this.watches?.[e]?.resourceVersionTime,v=t||this.watches?.[e]?.resourceVersion,b=this.send(JSON.stringify({...m,resourceVersion:f?void 0:v}));this.watches[e]={...m,status:b?Gc.WATCH_REQUESTED:Gc.WATCH_PENDING,resourceVersion:v,resourceVersionTime:g,skipResourceVersion:f}}unwatch(e){const t=this.watches?.[e]||{},{resourceType:n,id:r,namespace:i,selector:o}=t,a={resourceType:n,id:r,namespace:i,selector:o};if(n&&this.watches[e].status!==Xc){const t=this.send(JSON.stringify({...a,stop:!0}));this.watches[e].status=t?Xc:Wc}}_onmessage(e){const{name:t,resourceType:n,data:{type:r},id:i,namespace:o,selector:a,data:s}=JSON.parse(e.data),l=Hc({resourceType:n,type:r,id:i,namespace:o,selector:a});if("resource.start"===t&&this.watches?.[l]?.status===zc)this.watches[l].status=Kc,delete this.watches[l].error;else if("resource.stop"===t&&this.watches?.[l])this.watches[l]={error:this.watches[l]?.error};else if("resource.error"===t){const e=s?.error?.toLowerCase();this.watches[l]&&e.includes("watch not allowed")?this.watches[l].error={type:n,reason:Ct}:this.watches[l]&&e.includes("failed to find schema")?this.watches[l].error={type:n,reason:At}:e.includes("too old")&&(delete this.watches[l].resourceVersion,delete this.watches[l].resourceVersionTime,delete this.watches[l].skipResourceVersion,this.watches[l].error={type:n,reason:Rt},this.dispatchEvent(new CustomEvent("resync",{detail:{data:{resourceType:n,id:i,namespace:o,selector:a}}}))),this.trace("_onmessage:","new error",this.watches[l].error)}super._onmessage(e)}}var Zc=o(23330),Jc=o(8755),eu=o(37417),tu=o(4364);const nu=2500,ru={store:"",flushTimer:void 0,queue:[],schemas:{}};function iu(){ru.queue.forEach(e=>{const t=(0,Jc.en)(e),n=ru.schemas[e.id];if(!n||n&&n!==t){ru.schemas[e.id]=t;const n={data:e,resourceType:Z.yx,type:"resource.change"};ou(n)}}),ru.queue=[],ru.flushTimer=setTimeout(iu,nu)}function ou(e){self.postMessage({load:e})}function au(e){self.postMessage({redispatch:e})}ru.flushTimer=setTimeout(iu,nu);const su={watch:e=>{au({send:e})},createWatcher:e=>{au({subscribe:e})}},lu={onmessage:e=>{const t=Object.keys(e?.data);t.forEach(t=>{lu[t]?lu[t](e?.data[t]):tu.warn("no associated action for:",t)})},initWorker:({storeName:e})=>{ru.store=e},destroyWorker:()=>{clearTimeout(ru.flushTimer),self.postMessage({destroyWorker:!0})},loadSchemas:e=>{e.forEach(e=>{(0,eu.P)(e),ru.schemas[e.id]=(0,Jc.en)(e)})},updateSchema:e=>{ru.queue.push(e)},removeSchema:e=>{ru.queue=ru.queue.filter(t=>t.id!==e),delete ru.schemas[e]},...su};function cu(e,t,n){return(t=uu(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function uu(e){var t=du(e,"string");return"symbol"==typeof t?t:t+""}function du(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}self.onmessage=lu.onmessage;class hu{constructor(e){cu(this,"resources",{}),cu(this,"type",void 0),cu(this,"keyField",void 0),this.type=(0,Lc.AZ)("counts"===e?Z.i2:e),this.keyField=(0,Lc.BZ)(this.type)}load(e=[]){for(let t=0;t<e.length;t++){const n=e[t];this.type===Z.yx&&(0,eu.w)(n);const r=n[this.keyField];this.resources[r]=(0,Jc.en)(n)}return this}change(e,t){this.type===Z.yx&&(0,eu.w)(e);const n=this.resources[e[this.keyField]]||{},r=(0,Jc.en)(e);n!==r&&(this.resources[e[this.keyField]]=e,t())}create(e,t){this.change(e,t)}remove(e,t){this.resources[e]&&(delete this.resources[e],t())}}var pu=o(4364);const fu={},mu={watcher:void 0,store:"",workerQueue:[],batchChanges:{},debugWorker:!1},gu=(...e)=>{mu.debugWorker&&pu.info("Advanced Worker:",...e)};gu("created");const vu=setInterval(()=>{Object.keys(mu.batchChanges).length&&(self.postMessage({batchChanges:mu.batchChanges}),mu.batchChanges={})},5e3),bu=e=>{const{resourceType:t,data:{type:n},data:r}=e,i=t||n,o=(0,Lc.AZ)("counts"===i?Z.i2:i),a=(0,Lc.BZ)(o);return o===Z.yx&&(0,eu.w)(r),{type:o,id:r[a],data:r}},yu=(e,t,n)=>{gu("createWatcher",e,t),self.postMessage({[e]:{type:t.type,detail:t.detail,srcElement:{disconnectedAt:n.disconnectedAt,url:n.url}}})},wu=e=>{mu.workerQueue=mu.workerQueue.filter(t=>{const[,n]=Object.entries(t)[0],r=qc(n);return e!==r})},Ou={loadSchemas:e=>{fu[Z.yx]||(fu[Z.yx]=new hu(Z.yx)),fu[Z.yx].load(e)},createWatcher:e=>{gu("createWatcher",e);const{metadata:t,maxTries:n,url:r,csrf:i}=e;if(!mu.watcher){mu.watcher=new Yc(r,!0,null,null,n,i),mu.watcher.addEventListener(Et,e=>{const t=e.detail;if(t.data){const e=JSON.parse(t.data);e.name&&(Su[e.name]?Su[e.name](e):Su.dispatch(e))}}),mu.watcher.addEventListener("resync",e=>{self.postMessage({redispatch:{resyncWatch:e.detail.data}})}),mu.watcher.addEventListener(_t,e=>{yu(_t,e,mu.watcher)}),mu.watcher.addEventListener(kt,e=>{yu(kt,e,mu.watcher)}),mu.watcher.setDebug(mu.debugWorker),mu.watcher.connect(t);while(mu.workerQueue.length>0){gu("createWatcher","flushing workerQueue",mu.workerQueue);const e=mu.workerQueue.shift(),[t,n]=Object.entries(e)[0];Ou[t]?Ou[t](n):pu.warn("no associated action for:",t)}}},watch:e=>{gu("watch",e);const t=qc(e);if(e.stop)return void Ou.unwatch(t);if(!e.force&&mu.watcher?.watches[t]?.error)return;if(!mu.watcher)return void mu.workerQueue.push({watch:e});const{resourceType:n,namespace:r,id:i,selector:o,resourceVersion:a}=e,s=a?Date.now():void 0,l=[Z.yx,Z.i2].includes(n),c={resourceType:n,id:i,namespace:r,selector:o,force:e.force};mu.watcher.watch(t,a,s,c,l)},unwatch:e=>{gu("unwatch",e),wu(e),mu.watcher&&mu.watcher.unwatch(e)},initWorker:({storeName:e})=>{gu("initWorker",e),mu.store=e},destroyWorker:()=>{function e(){delete self.onmessage,self.postMessage({destroyWorker:!0})}gu("destroyWorker"),clearInterval(vu),mu.watcher?mu.watcher?.disconnect().then(e):e()},toggleDebug:({on:e})=>{mu.debugWorker=!!e,mu.watcher.setDebug(!!e)},updateBatch(e,t,n){mu.batchChanges[e]||(mu.batchChanges[e]={}),mu.batchChanges[e][t]=n}},Su={"resource.change":e=>{const{type:t,id:n,data:r}=bu(e);fu[t]?fu[t].change(r,()=>Ou.updateBatch(t,n,r)):Ou.updateBatch(t,n,r)},"resource.create":e=>{const{type:t,id:n,data:r}=bu(e);fu[t]?fu[t].create(r,()=>Ou.updateBatch(t,n,r)):Ou.updateBatch(t,n,r)},"resource.start":e=>{},"resource.remove":e=>{const{type:t,id:n}=bu(e);fu[t]?fu[t].remove(n,()=>Ou.updateBatch(t,n,{})):Ou.updateBatch(t,n,{})},"resource.stop":e=>{gu("resource.stop",e);const t=qc(e);wu(t),mu.watcher?.watches[t]?.error||Su.dispatch({...e,advancedWorker:!0})},"resource.error":e=>{pu.warn(`Resource error [${mu.store}]`,e.resourceType,":",e.data.error)},dispatch:e=>{self.postMessage({dispatch:e})}};self.onmessage=e=>{const t=Object.keys(e?.data);t.forEach(t=>{Ou[t]?Ou[t](e?.data[t]):pu.debug("no associated action for:",t)})};const Eu={WAITING:"waiting",DESTROY_MOCK:"destroy",BASIC:"basic",ADVANCED:"advanced"};var xu=o(81565);class _u{typeIsNamespaced({getters:e},t){var n;return(null===(n=e.haveNamespace(t))||void 0===n?void 0:n.length)>0}typeIsPaginated({getters:e},t){return!!e.havePage(t)}filteredNamespaces({rootGetters:e}){return e.activeNamespaceCache}subscribeNamespace(e){if(!xu.A.isApplicable({namespaced:e,type:"n/a"})||!e.length)return e}validChange({getters:e,rootGetters:t},n,r){if(this.typeIsNamespaced({getters:e},n)){const e=this.filteredNamespaces({rootGetters:t});if(!e[r.metadata.namespace])return!1}if(this.typeIsPaginated({getters:e},n)){const t=e["all"](n);return!!t.find(e=>e.id===r.id)}return!0}validateBatchChange({getters:e,rootGetters:t},n){const r=this.filteredNamespaces({rootGetters:t}),i={namespaced:{},paginated:{}};return Object.entries(n).forEach(([t,n])=>{var o;if(void 0===i.namespaced[t]&&(i.namespaced[t]=this.typeIsNamespaced({getters:e},t)),i.namespaced[t]){const i=e.schemaFor(t);if(!(null===(o=null===i||void 0===i?void 0:i.attributes)||void 0===o?void 0:o.namespaced))return;Object.keys(n).forEach(e=>{const t=e.split("/")[0];t&&r[t]||delete n[e]})}if(void 0===i.paginated[t]&&(i.paginated[t]=this.typeIsPaginated({getters:e},t)),i.paginated[t]){const r=e["all"](t);Object.keys(n).forEach(e=>{r.find(t=>t.id===e)||delete n[e]})}}),n}}var ku=new _u,Cu=o(10213),Au=o(63905),Tu=o(88343),Ru=o(15092),Nu=o(12663);class Pu{constructor(){this.watches={},this.supportedEventTypes=[Tu.r.CHANGES]}keyForSubscribe({params:e}){return Hc(e)}isSupportedEventType(e){return!!this.supportedEventTypes.includes(e)}getWatch({params:e}){const t=this.keyForSubscribe({params:e});return this.watches[t]}initialiseWatch({params:e}){const t=this.keyForSubscribe({params:e});return this.watches[t]={hasStandardWatch:!1,listeners:[]},this.watches[t]}deleteWatch({params:e}){const t=this.keyForSubscribe({params:e});delete this.watches[t]}hasStandardWatch({params:e}){const t=this.keyForSubscribe({params:e});return this.watches[t]?.hasStandardWatch}setStandardWatch({standardWatch:e,args:t}){const{params:n}=t;let r=this.getWatch({params:n});if(!r){if(!e)return;r=this.initialiseWatch({params:n})}r.hasStandardWatch=e,r.hasStandardWatch||0!==r.listeners.length||this.deleteWatch({params:n})}hasEventListeners({params:e}){const t=this.keyForSubscribe({params:e}),n=this.watches[t],r=n?.listeners.find(e=>Object.values(e.callbacks).length>0);return!!r}getEventListener({entryOnly:e,args:t}){const{params:n,event:r}=t,i=this.keyForSubscribe({params:n}),o=this.watches[i];if(o){const t=o.listeners.find(e=>e.event===r);if(t&&(e||Object.keys(t?.callbacks||{}).length))return t}return null}addEventListener({event:e,params:t}){if(!e)throw new Error("Cannot add a socket watch event listener if there's no event to listen to");let n=this.getWatch({params:t});n||(n=this.initialiseWatch({params:t}));let r=this.getEventListener({entryOnly:!0,args:{event:e,params:t}});return r||(r={event:e,callbacks:{}},n.listeners.push(r)),r}triggerEventListener({event:e,params:t}){const n=this.getEventListener({entryOnly:!1,args:{event:e,params:t}});n&&Object.values(n.callbacks).forEach(e=>{e({forceWatch:t.forceWatch,revision:t.revision})})}triggerAllEventListeners({params:e}){const t=this.getWatch({params:e});t.listeners.forEach(t=>{Object.values(t.callbacks||{}).forEach(t=>{t({forceWatch:e.forceWatch,revision:e.revision})})})}addEventListenerCallback({callback:e,args:t}){const{params:n,event:r,id:i}=t,o=this.addEventListener({event:r,params:n});return o.callbacks[i]||(o.callbacks[i]=e),o}removeEventListenerCallback({event:e,params:t,id:n}){const r=this.getEventListener({args:{event:e,params:t}});r&&delete r.callbacks[n]}}var Iu=o(20926),Mu=o(75689),Du=o(4364);const Lu=3e3,Bu={},$u=[Cu.e.CLUSTER,Cu.e.RANCHER,Cu.e.MANAGEMENT],Vu=(e,t)=>t.$workers[e]?.waitingForDestroy&&t.$workers[e].waitingForDestroy(),Fu=(e,t)=>(0,Zc.f)(()=>Vu(e,t)||!!t.getters["management/byId"](Z.yx,Z.Mc.SETTING),"management settings schema to be available"),ju=(e,t)=>(0,Zc.f)(()=>Vu(e,t)||!!t.getters["management/byId"](Z.Mc.SETTING,J.HG.UI_PERFORMANCE),"UI performance settings to be available"),Uu=e=>{const{rootGetters:t,getters:n}=e,r=n.storeName,i=t.clusterId;if(!$u.includes(r)||i===Cu.w&&r===Cu.e.CLUSTER)return!1;const o=(0,Kn.fD)(t);return o?.advancedWorker.enabled};async function Gu(e,t){const{getters:n,dispatch:r}=t,i=n.storeName;if(e.$workers=e.$workers||{},!$u.includes(i))return;e.$workers[i]||(e.$workers[i]={postMessage:t=>{"destroyWorker"!==Object.keys(t)?.[0]?Bu[i]?Bu[i].push(t):Bu[i]=[t]:e.$workers[i].mode=Eu.DESTROY_MOCK},mode:Eu.WAITING,waitingForDestroy:()=>e.$workers[i]?.mode===Eu.DESTROY_MOCK,destroy:()=>{delete e.$workers[i]}});try{await Fu(i,e),await ju(i,e)}catch(s){return void(e.$workers[i]?.destroy?e.$workers[i].destroy():delete e.$workers[i])}if(e.$workers[i].waitingForDestroy())return void e.$workers[i].destroy();const o=Uu(t),a={load:e=>{qu(t,e,!0,"Change")},destroyWorker:()=>{e.$workers&&(e.$workers[i].terminate(),delete e.$workers[i])},batchChanges:e=>{r("batchChanges",ku.validateBatchChange(t,e))},dispatch:e=>{r(`ws.${e.name}`,e)},redispatch:e=>{Object.entries(e).forEach(([e,t])=>{r(e,t)})},[_t]:e=>{r("error",e)},[kt]:e=>{r("error",e)}};if(!e.$workers[i]||e.$workers[i].mode===Eu.WAITING){const t=o?Eu.ADVANCED:Eu.BASIC,n=e.steveCreateWorker(t);e.$workers[i]=n,n.postMessage({initWorker:{storeName:i}}),e.$workers[i].onmessage=e=>{const t=Object.keys(e?.data);t.forEach(t=>{a[t](e?.data[t])})}}while(Bu[i]?.length){const t=Bu[i].shift(),n=(0,Do.yo)(t);e.$workers[i].postMessage(n)}}function Hu(e,t){const n=e.resourceType||e.type,r=t.resourceType||t.type;return n===r&&((e.mode===t.mode||!e.mode&&!t.mode)&&((e.id===t.id||!e.id&&!t.id)&&((e.namespace===t.namespace||!e.namespace&&!t.namespace)&&(e.selector===t.selector||!e.selector&&!t.selector))))}function qu({getters:e,state:t,rootGetters:n},{data:r,revision:i},o,a){const s=e.normalizeType(r.type),l=e.typeEntry(s);if(l&&(l.revision=Math.max(l.revision,parseInt(i,10)),ku.validChange({getters:e,rootGetters:n},s,r)))if(o)t.queue.push({action:"dispatch",event:"load",body:r});else{const n=e.byId(r.type,r.id);n&&t.queue.push({action:"commit",event:"remove",body:n}),s===Z.yx&&t.queue.push({action:"commit",event:"forgetType",body:r.id})}}function Qu(e){return(0,Kn.fD)(e)?.disableWebsocketNotification}const zu=({getters:e,commit:t},n)=>{Nu.A.resetPrefix(e.backOffId(n.obj,"")),t("clearInError",n.obj)},Ku={async subscribe(e,t){const{state:n,commit:r,dispatch:i,getters:o,rootGetters:a}=e;if(a["isSingleProduct"]?.disableSteveSockets)return;let s=n.socket;r("setWantSocket",!0),n.debugSocket&&Du.info(`Subscribe [${o.storeName}]`);const l=`${n.config.baseUrl}/subscribe`,c=Qu(a)?null:3,u=(0,Do.Jt)(t,"metadata");if(Uu(e)){if(this.$workers[o.storeName]||await Gu(this,e),!this.$workers[o.storeName])return;const t={parseJSON:!1},r=a["cookies/get"]({key:Dc,options:t});this.$workers[o.storeName].postMessage({createWatcher:{metadata:u,url:`${n.config.baseUrl}/subscribe`,csrf:r,maxTries:c}})}else s?(s.setAutoReconnect(!0),s.setUrl(l),s.connect(u)):(s=new Nt(`${n.config.baseUrl}/subscribe`,!0,null,null,c),r("setSocket",s),s.addEventListener(Ot,e=>{i("opened",e)}),s.addEventListener(St,e=>{i("closed",e)}),s.addEventListener(_t,e=>{i("error",e)}),s.addEventListener(kt,e=>{i("error",e)}),s.addEventListener(Et,e=>{const t=e.detail;if(t.data){const e=JSON.parse(t.data);e.name&&i(`ws.${e.name}`,e)}}),s.connect(u))},async unsubscribe({commit:e,getters:t,state:n,dispatch:r}){const i=n.socket;e("setWantSocket",!1);const o=[],a=(this.$workers||{})[t.storeName];if(a){const e=t.storeName;a.postMessage({destroyWorker:!0}),o.push((0,Zc.f)(()=>!this.$workers?.[e],"Worker to be destroyed",3e4,10,!0))}return i&&o.push(i.disconnect()),await r("resetWatchBackOff"),Promise.all(o)},watchEvent(e,{event:t=Tu.r.CHANGES,id:n,callback:r,params:i}){if(!e.getters.listenerManager.isSupportedEventType(t))return void Du.error(`Unknown event type "${t}", only ${Object.keys(e.getters.listenerManager.supportedEventTypes).join(",")} are supported`);e.getters.listenerManager.addEventListenerCallback({callback:r,args:{event:t,params:i,id:n}});const o=e.getters.listenerManager.hasStandardWatch({params:i});o||e.dispatch("watch",{...i,standardWatch:!1})},unwatchEvent(e,{event:t=Tu.r.CHANGES,id:n,params:r}){e.getters.listenerManager.isSupportedEventType(t)?(e.getters.listenerManager.removeEventListenerCallback({event:t,params:r,id:n}),e.dispatch("unwatch",r)):Du.info(`Attempted to unwatch for an event "${t}" but it had no watchers`)},watch({state:e,dispatch:t,getters:n,rootGetters:r,commit:i},o){e.debugSocket&&Du.info(`Watch Request [${n.storeName}]`,JSON.stringify(o));let{type:a,selector:s,id:l,revision:c,namespace:u,stop:d,force:h,mode:p,standardWatch:f=!0,registerType:m=!1}=o;if(u=ku.subscribeNamespace(u),a=n.normalizeType(a),!n.typeRegistered(a))if(m)i("registerType",a);else if(p!==Tu.g.RESOURCE_CHANGES)return void(e.debugSocket&&Du.info("Will not Watch (type is not registered)",JSON.stringify(o)));if(r["type-map/isSpoofed"](a))return void(e.debugSocket&&Du.info("Will not Watch (type is spoofed)",JSON.stringify(o)));const g=n.schemaFor(a,!1,!1);if(g?.attributes?.verbs?.includes&&!g.attributes.verbs.includes("watch"))return void(e.debugSocket&&Du.info("Will not Watch (type does not have watch verb)",JSON.stringify(o)));const v=n.inError(o);if(!d&&!h&&v)return void(v!==Rt&&Du.error(`Aborting Watch Request [${n.storeName}]. Watcher in error (${v})`,JSON.stringify(o)));const b={type:a,id:l,selector:s,namespace:u,mode:p};if(!d&&n.watchStarted(b))return void(e.debugSocket&&Du.debug(`Already Watching [${n.storeName}]`,{type:a,id:l,selector:s,namespace:u,mode:p}));"undefined"===typeof c&&(c=n.nextResourceVersion(a,l));const y={resourceType:a};if(p&&(y.mode=p,p===Tu.g.RESOURCE_CHANGES)){const e=Ru.A.resourceChangesDebounceMs({rootGetters:r});e&&(y.debounceMs=e),i("clearFromQueue",{type:a,log:!0})}c&&(y.resourceVersion=`${c}`),u&&(y.namespace=u),d&&(y.stop=!0),l&&(y.id=l),s&&(y.selector=s);const w=this.$workers?.[n.storeName]||{};return w.mode===Eu.ADVANCED||w.mode===Eu.WAITING?(h&&(y.force=!0),void w.postMessage({watch:y})):(!d&&f&&n.listenerManager.setStandardWatch({standardWatch:!0,args:{event:y.mode,params:y}}),t("send",y))},unwatch(e,{type:t,id:n,namespace:r,selector:i,all:o,mode:a}){const{commit:s,getters:l,dispatch:c}=e;if(l["schemaFor"](t)){r=ku.subscribeNamespace(r);const u={type:t,id:n,namespace:r,selector:i,mode:a,stop:!0},d=n=>{const r=e.getters.listenerManager.hasStandardWatch({params:n}),i=e.getters.listenerManager.hasEventListeners({params:n});r&&e.getters.listenerManager.setStandardWatch({standardWatch:!1,args:{params:n}}),i||l["watchStarted"](n)&&(s("setWatchStopped",n),c("watch",{...n,stop:!0}),s("clearFromQueue",t))},h=Hc(u),p=[];Uu(e)?c("watch",u):o?p.push(...l["watchesOfType"](t)):l["watchStarted"](u)&&p.push(u),p.forEach(e=>{d(e),c("resetWatchBackOff",{type:t,compareWatches:e=>h===Hc(e)})})}},resetWatchBackOff({state:e,getters:t,commit:n},{type:r,compareWatches:i,resetInError:o=!0,resetStarted:a=!0}={resetInError:!0,resetStarted:!0}){if(a&&e.started?.length){let n=e.started;(r||i)&&(n=n.filter(e=>i?i(e):e.type===r)),n.forEach(e=>Nu.A.resetPrefix(t.backOffId(e,"")))}if(o&&e.inError){let o=Object.values(e.inError||{});(r||i)&&(o=o.filter(e=>i?i(e.obj):e.obj.type===r)),o.filter(e=>e.reason===Rt).forEach(e=>zu({getters:t,commit:n},e))}},"ws.ping"({getters:e,dispatch:t},n){if("management"===e.storeName){const r=n?.data?.version||null;t("updateServerVersion",r,{root:!0}),Du.info(`Ping [${e.storeName}] from ${r||"unknown version"}`)}}},Wu={debug(e,t,n){e.debugSocket=!1!==t,n&&this.$workers[n]&&this.$workers[n].postMessage({toggleDebug:!1!==t})}},Xu={async flush({state:e,commit:t,dispatch:n,getters:r}){const i=e.queue;let o=[];if(!i.length)return;const a=(new Date).getTime();e.queue=[],e.debugSocket&&Du.debug(`Subscribe Flush [${r.storeName}]`,i.length,"items");for(const{action:s,event:l,body:c}of i){const e=r["havePage"](c?.type);if(e)Du.warn(`Prevented watch \`flush\` data from polluting the cache for type "${c?.type}" (currently represents a page)`,{action:s,event:l,body:c});else if("dispatch"===s&&"load"===l)o.push(c);else if(o.length&&(await n("loadMulti",o),o=[]),"dispatch"===s)await n(l,c);else{if("commit"!==s)throw new Error("Invalid queued action");t(l,c)}}o.length&&await n("loadMulti",o),e.debugSocket&&Du.debug(`Subscribe Flush [${r.storeName}] finished`,(new Date).getTime()-a,"ms")},rehydrateSubscribe({state:e,dispatch:t}){e.wantSocket&&!e.socket&&t("subscribe")},reconnectWatches({state:e,getters:t,commit:n,dispatch:r}){const i=[];for(const o of e.started.slice())Du.info(`Reconnect [${t.storeName}]`,JSON.stringify(o)),t.schemaFor(o.type)&&(n("setWatchStopped",o),delete o.revision,i.push(r("watch",o)));return Promise.all(i)},async resyncWatch({getters:e,dispatch:t},n){Du.info(`Resync [${e.storeName}]`,n);const{backOffId:r,...i}=n;await t("fetchResources",{params:i,backOffId:r,opt:{force:!0,forceWatch:!0}})},async fetchPageResources({getters:e,dispatch:t},{opt:n,storePagination:r,params:i,backOffId:o}){const{resourceType:a,namespace:s,revision:l}=i,c=a||i.type,u=o||e.backOffId(i,"fetchPageResources"),d=Nu.A.getBackOff(u)?.metadata?.revision,h=e["typeEntry"](a||c)?.revision,p=new Iu.J(l),f=new Iu.J(d),m=new Iu.J(h),g=new Iu.J(d||h);if(g.isNewerThan(p))Du.warn(`Ignoring subscribe request to update '${c}' with revision '${p.revision}' (active revision '${g.revision} & cached revision '${m.revision}''). This probably means the replica that provided the web socket message has not yet correctly synced it's cache with other fresher replicas.`);else{p.isNewerThan(f)&&(Du.info(`Dropping previous subscribe request to update '${c}' with revision '${g.revision}' (new target revision '${p.revision}'). `),Nu.A.reset(u));try{await Nu.A.recurse({id:u,metadata:{revision:l},description:`Fetching resources for ${c}. Triggered by web socket`,canFn:()=>{if(!e.canBackoff(this.$socket))return Du.info(`Aborting subscribe request to update '${c}' with revision '${g.revision}' (socket closed). `),!1;if(!e["watchStarted"](i)){const t=e.inError(i);if(t!==Rt)return Du.info(`Aborting subscribe request to update '${c}' with revision '${g.revision}' (resource not watched). `),!1}return!0},continueOnError:async e=>400===e?.status&&e?.code===Mu.s.UNKNOWN_REVISION,delayedFn:async()=>await t("findPage",{type:c,opt:{...n,namespaced:s,revision:l,...r.request}})})}catch(v){Du.info(`Failed subscribe request to update '${c}' with revision '${g.revision}' (error). `,v)}}},async fetchResources({state:e,getters:t,dispatch:n,commit:r},{opt:i,params:o,backOffId:a}){const{resourceType:s,namespace:l,id:c,selector:u,mode:d,revision:h}=o;if(!s)return void Du.error("A socket message has prompted a request to fetch a resource but no resource type was supplied");if(c)return void await n("find",{type:s,id:c,opt:{...i,namespaced:l,revision:null}});let p=[],f=[];if(u)p=t["matching"](s,u).slice(),f=await n("findMatching",{type:s,selector:u,opt:i});else if(d===Tu.g.RESOURCE_CHANGES){const e=t["havePage"](s);e&&(await n("fetchPageResources",{params:o,storePagination:e,opt:i,backOffId:a}),p=[],f=[]),t.listenerManager.triggerEventListener({event:Tu.g.RESOURCE_CHANGES,params:{...o,revision:h,forceWatch:i.forceWatch}})}else p=t["all"](s).slice(),l&&(p=p.filter(e=>e.metadata?.namespace===l)),f=await n("findAll",{type:s,watchNamespace:l,opt:i});const m={};for(const g of f)m[g.id]=!0;for(const g of p)m[g.id]||(e.debugSocket&&Du.info(`Remove stale [${t.storeName}]`,s,g.id),r("remove",g))},async opened({commit:e,dispatch:t,state:n,getters:r,rootGetters:i},o){n.debugSocket&&Du.info(`WebSocket Opened [${r.storeName}]`);const a=o.currentTarget,s=o?.detail?.tries,l=i["i18n/t"],c=Qu(i);if(this.$socket=a,n.queue||(n.queue=[]),n.queueTimer||(n.flushQueue=async()=>{n.queue.length&&await t("flush"),n.queueTimer=setTimeout(n.flushQueue,1e3)},n.flushQueue()),a.hasReconnected){await t("reconnectWatches");const e=i["growl/find"]({key:"url",val:a.url});e&&t("growl/remove",e.id,{root:!0}),s>1&&!c&&t("growl/success",{title:l("growl.reconnected.title"),message:l("growl.reconnected.message",{url:this.$socket.url,tries:s})},{root:!0})}for(const u of n.pendingFrames.slice())e("dequeuePendingFrame",u),t("sendImmediate",u)},async closed({state:e,getters:t,dispatch:n}){e.debugSocket&&Du.info(`WebSocket Closed [${t.storeName}]`),await n("resetWatchBackOff"),clearTimeout(e.queueTimer),e.queueTimer=null},async error({getters:e,state:t,dispatch:n,rootGetters:r},i){t.debugSocket&&Du.info(`WebSocket Error [${e.storeName}]`),await n("resetWatchBackOff"),clearTimeout(t.queueTimer),t.queueTimer=null;const o=Qu(r);if(!o){const o=(0,Di.ZD)(r["prefs/get"](N.DX)),a=(0,Di.ZD)(r["prefs/get"](N.G$)),s=i?.srcElement?.disconnectedAt||Date.now(),l=`${$c()(s).format(`${o} ${a}`)}`,c=i?.srcElement?.url,u=t?.socket?.tries,d=r["i18n/t"],h=r["growl/find"]({key:"url",val:c});i.type===_t?(h&&n("growl/remove",h.id,{root:!0}),n("growl/error",{title:d("growl.connectError.title"),message:d("growl.connectError.message",{url:c,time:l,tries:u},{raw:!0}),icon:"error",earliestClose:s+Lu,url:c},{root:!0})):i.type===kt?(h&&n("growl/remove",h.id,{root:!0}),n("growl/error",{title:d("growl.disconnectError.title"),message:d("growl.disconnectError.message",{url:c,time:l,tries:u},{raw:!0}),icon:"error",earliestClose:s+Lu,url:c},{root:!0})):Du.error(`WebSocket Connection Error [${e.storeName}]`,i.detail)}},send({state:e,commit:t},n){if(e.socket){const t=e.socket.send(JSON.stringify(n));if(t)return}t("enqueuePendingFrame",n)},sendImmediate({state:e},t){if(e.socket)return e.socket.send(JSON.stringify(t))},"ws.resource.start"({state:e,getters:t,commit:n,dispatch:r},i){e.debugSocket&&Du.info(`Resource start: [${t.storeName}]`,i);const o={type:i.resourceType,namespace:i.namespace,id:i.id,selector:i.selector,mode:i.mode};e.started.filter(e=>{if(e.type===o.type&&e.namespace!==o.namespace&&!e.mode&&!o.mode)return!0}).forEach(e=>{r("unwatch",e)}),n("setWatchStarted",o)},"ws.resource.error"({getters:e,commit:t,dispatch:n},r){Du.warn(`Resource error [${e.storeName}]`,r.resourceType,":",r.data.error);const i=r.data?.error?.toLowerCase();if(i.includes("watch not allowed"))t("setInError",{msg:r,reason:Ct});else if(i.includes("failed to find schema"))t("setInError",{msg:r,reason:At});else if(i.includes("too old")){t("setInError",{msg:r,reason:Rt});const i=e.backOffId(r,Rt);Nu.A.execute({id:i,description:"Invalid watch revision, re-syncing",canFn:()=>e.canBackoff(this.$socket),delayedFn:()=>n("resyncWatch",{...r,backOffId:void 0})})}else i.includes("the server does not allow this method on the requested resource")&&t("setInError",{msg:r,reason:Tt})},"ws.resource.stop"({state:e,getters:t,commit:n,dispatch:r},i){const o=i.resourceType,a={type:o,id:i.id,namespace:i.namespace,selector:i.selector,mode:i.mode};if(e.debugSocket&&Du.info(`Resource Stop [${t.storeName}]`,o,i),!o)return void Du.error(`Resource Stop [${t.storeName}]. Received resource.stop with an empty resourceType, aborting`,i);const s=i.advancedWorker,l=!s,c=l?t["watchStarted"](a):s;if(t["schemaFor"](o)&&c){l&&n("setWatchStopped",a);const e=t.listenerManager.hasEventListeners({params:a}),i=t.listenerManager.hasStandardWatch({params:a});if(r("watch",{...a,standardWatch:!(e&&!i)}),e){const e=t.inError(a);e||t.listenerManager.triggerEventListener({event:Tu.r.CHANGES,params:a})}}},"ws.resource.create"(e,t){const n=t.data,r=n?.type;if(r===Z.yx){const t=(this.$workers||{})[e.getters.storeName];t&&t.postMessage({updateSchema:n})}const i=e.getters["havePage"](r);if(i)return Du.warn(`Prevented watch \`resource.create\` data from polluting the cache for type "${r}" (currently represents a page). To prevent any further issues the watch has been stopped.`,t),void e.dispatch("unwatch",{...t,type:r});e.state.debugSocket&&Du.info(`Resource Create [${e.getters.storeName}]`,t.resourceType,t),qu(e,t,!0,"Create")},"ws.resource.change"(e,t){const n=t.data,r=n.type;if(n.message&&!n.id)return;if(r===Z.yx){const t=(this.$workers||{})[e.getters.storeName];if(t)return void t.postMessage({updateSchema:n})}const i=e.getters["havePage"](r);if(i)return Du.warn(`Prevented watch \`resource.change\` data from polluting the cache for type "${r}" (currently represents a page). To prevent any further issues the watch has been stopped.`,t),void e.dispatch("unwatch",{...t,type:r});qu(e,t,!0,"Change");const o=e.rootGetters["type-map/optionsFor"](r);if(o?.alias?.length>0){const t=o?.alias||[];t.map(t=>{e.state.queue.push({action:"dispatch",event:"load",body:{...n,type:t}})})}},async"ws.resource.changes"({dispatch:e},t){await e("fetchResources",{params:t,opt:{force:!0,load:Au.m9}})},"ws.resource.remove"(e,t){const n=t.data,r=n.type;if(e.state.debugSocket&&Du.info(`Resource Remove [${e.getters.storeName}]`,r,t),r===Z.yx){const t=(this.$workers||{})[e.getters.storeName];t&&t.postMessage({removeSchema:n.id})}const i=e.getters["havePage"](r);if(i)return Du.warn(`Prevented watch \`resource.remove\` data from polluting the cache for type "${r}" (currently represents a page). To prevent any further issues the watch has been stopped.`,t),void e.dispatch("unwatch",{...t,type:r});qu(e,t,!1,"Remove");const o=e.rootGetters["type-map/optionsFor"](r);if(o?.alias?.length>0){const t=o?.alias||[];t.map(t=>{const r=e.getters.byId(t,n.id);e.state.queue.push({action:"commit",event:"remove",body:r})})}}},Yu={setSocket(e,t){e.socket=t},setWantSocket(e,t){e.wantSocket=t},enqueuePendingFrame(e,t){e.pendingFrames.push(t)},dequeuePendingFrame(e,t){(0,Ni.Gj)(e.pendingFrames,t)},setWatchStarted(e,t){const n=e.started.find(e=>Hu(t,e));n||(0,Ni.PG)(e.started,t),delete e.inError[Hc(t)]},setWatchStopped(e,t){const n=e.started.find(e=>Hu(t,e));n?(0,Ni.Gj)(e.started,n):Du.warn("Tried to remove a watch that doesn't exist",t)},setInError(e,{msg:t,reason:n}){const r=Hc(t),{data:i,resourceType:o,...a}=t;a.type=t.resourceType||t.type,e.inError[r]={obj:a,reason:n}},clearInError(e,t){const n=Hc(t);delete e.inError[n]},resetSubscriptions(e){(0,Ni.IU)(e.started),(0,Ni.IU)(e.pendingFrames),(0,Ni.IU)(e.queue),clearTimeout(e.queueTimer),e.deferredRequests={},e.queueTimer=null,e.socketListenerManager=new Pu(e.config.namespace)},clearFromQueue(e,t){const n="object"===typeof t?t:{type:t},{type:r,log:i}=n;e.queue=e.queue.filter(e=>{const t=e.body?.type!==r;return!t&&i&&Du.info(`Clearing queued item of type \`${r}\` from queue`,e),t})}},Zu={backOffId:()=>(e,t)=>`${Hc(e)}${t?`:detail=${t}`:""}`,canBackoff:()=>e=>e.state===Ot,inError:e=>t=>e.inError[Hc(t)]?.reason,watchesOfType:e=>t=>e.started.filter(e=>t===(e.resourceType||e.type)),watchStarted:e=>t=>{const n=e.started.find(e=>Hu(t,e));return!!n},nextResourceVersion:(e,t)=>(n,r)=>{n=(0,Lc.AZ)(n);let i=0;if(r){const e=t["byId"](n,r);i=e?.metadata?.resourceVersion}if(!i){const t=e.types[n];if(!t)return null;const r=new Iu.J(t.revision);if(!r.isNumber)return t.revision||null;i=r;for(const e of t.list||[])if(e&&e.metadata){const t=new Iu.J(e.metadata.resourceVersion);t.isNewerThan(i)&&(i=t)}i=i.asNumber}return i||null},listenerManager:e=>e.socketListenerManager},Ju={...Ku,...Xu},ed={...Wu,...Yu},td={...Zu};var nd=o(50382),rd=o(48074),id=o(39975),od=o(82614),ad=o(89865),sd=o(86794),ld=o(82637),cd=o(2334),ud=o(57699),dd=o(46392),hd=o(4364);const pd={NORMAN:"norman",STEVE:"steve",BY_TYPE:"byType"},fd={[Z.i2]:!0,[Z.CU]:!0,[Z.yx]:!0,[Z.UI.NAV_LINK]:!0},md=new RegExp("(/v1)|(/k8s/clusters/[a-z0-9-]+/v1)");var gd={isSteveUrl:()=>e=>md.test(e),urlOptions:(e,t)=>(e,n,r)=>{n=n||{};const i=(0,ot.qg)(e||""),o=t.isSteveUrl(i.path),a=ld.A.createParamsForPagination({schema:r,opt:n});if(a)e+=""+((e.includes("?")?"&":"?")+a);else{const r=t.isSteveUrl(i.path);if(n.labelSelector&&(e+=`${e.includes("?")?"&":"?"}labelSelector=${n.labelSelector}`),n.filter){e+=""+(e.includes("?")?"&":"?");const t=Object.keys(n.filter);t.forEach(t=>{let i=n.filter[t];(0,Ni.cy)(i)||(i=[i]),r&&(e+=""+(e.includes("filter=")?"&":"filter="));const o=i.map(e=>`${encodeURI(t)}${r?"~":"="}${encodeURI(e)}`),a=e.charAt(e.length-1),s=["&","?","="].includes(a)?"":"&";e+=`${s}${o.join("&")}`})}const o=xu.A.checkAndCreateParam(n);o&&(e+=""+((e.includes("?")?"&":"?")+o));const a=n.limit;a&&(e+=`${e.includes("?")?"&":"?"}limit=${a}`),r&&n.isCollection&&(e+=`${e.includes("?")?"&":"?"}pagesize=${Ru.A.defaultPageSize}`);const s=n.sortBy,l=n.sortOrder;s&&(r?e+=`${e.includes("?")?"&":"?"}sort=${("desc"===l?"-":"")+encodeURI(s)}`:(e+=`${e.includes("?")?"&":"?"}sort=${encodeURI(s)}`,l&&(e+=`${e.includes("?")?"&":"?"}order=${encodeURI(l)}`)))}if(o){if(!Array.isArray(n?.excludeFields)){const e=["metadata.managedFields"];n.excludeFields=Array.isArray(n?.omitExcludeFields)?e.filter(e=>!e.includes(n.omitExcludeFields)):e}if(n.excludeFields.length){const t=n.excludeFields.map(e=>`exclude=${e}`).join("&");e+=`${e.includes("?")?"&":"?"}${t}`}n.revision&&(e+=`${e.includes("?")?"&":"?"}revision=${n.revision}`)}return e},urlFor:(e,t)=>(n,r,i)=>{let o=(0,sd.d)(e,t)(n,r,i);if(!i?.url&&i?.namespaced&&!xu.A.isApplicable(i)){const e=new URL(o),t=e.pathname;t?.length&&"/"===t[t.length-1]&&(e.pathname=t.substring(0,t.length-1));const n=e.pathname.split("/");r?(n.splice(n.length-1,0,i.namespaced),e.pathname=n.join("/")):e.pathname=`${e.pathname.split("/").join("/")}/${i.namespaced}`,o=e.toString()}return o},defaultModel:e=>t=>{const n=e.config.modelBaseClass||pd.BY_TYPE.STEVE;return n===pd.BY_TYPE?t?.type?.startsWith("management.cattle.io.")||t?.type?.startsWith("project.cattle.io.")?od.A:id.A:n===pd.NORMAN?ad.A:id.A},classify:(e,t,n)=>t=>{const r=(0,rd.$)(e.config.namespace,t?.type,t?.metadata?.name,n);if(r)return r;const i=e.config.modelBaseClass||nd.vX;return i===nd.vX?t?.type?.startsWith("management.cattle.io.")||t?.type?.startsWith("project.cattle.io.")?od.A:id.A:i===pd.NORMAN?ad.A:id.A},cleanResource:()=>(e,t)=>{if(t?.type===Z.i2&&e)return t.counts={...e.counts,...t.counts},t;if(e?.cleanResource&&"function"===typeof e.cleanResource)return e.cleanResource(t);const n=Object.getPrototypeOf(Object.getPrototypeOf(e))?.constructor;return n===od.A?(0,od.T)(t):t},podsByNamespace:e=>t=>{const n=e.podsByNamespace[t];return n?.list||[]},gcIgnoreTypes:()=>fd,currentGeneration:e=>t=>{t=(0,Lc.AZ)(t);const n=e.types[t];return n?n.generation:null},pathExistsInSchema:(e,t)=>(e,n)=>{const r=t.schemaFor(e);if(r.requiresResourceFields&&!r.hasResourceFields)return hd.warn(`pathExistsInSchema requires schema ${r.id} to have resources fields via schema definition but none were found. has the schema 'fetchResourceFields' been called?`),!1;const i=r.requiresResourceFields?r.schemaDefinitions:null,o=(0,Di.jg)(n);let a=r;while(o.length){const n=o.shift(),s=a.resourceFields?.[n];if(e=s?.type,!e)return!1;if(o.length&&(e=(0,cd.parseType)(e,s).pop(),a=i?i?.[e]:t.schemaFor(e),!r))return!1}return!0},headersFor:(e,t,n,r)=>({getters:e,state:t},{schema:n,pagination:i})=>{if(i)return(0,dd.Bm)({state:t,getters:e,rootGetters:r},{headers:t.paginationHeaders,typeOptions:e["optionsFor"](n,!0),schema:n,columns:{name:ud.l3,state:ud.Xc,namespace:ud.r1,age:ud.tm,id:ud.nl}})},optionsFor:()=>(e,{schema:t,pagination:n,opts:r})=>{if(n){const e={listMandatorySort:[]};return!r.listGroupsWillOverride&&t.attributes.namespaced&&(e.listGroups=ud.ce,e.listGroupsWillOverride=!0),e}}},vd=o(96730),bd=o(4364);const yd={node:{count:800,statusRow:2},"apps.deployment":{count:4e3,statusRow:5},pod:{count:4e3,statusRow:10}};({NODE_ENV:"production",BASE_URL:"/"}).perfTest&&{NODE_ENV:"production",BASE_URL:"/"}.dev&&bd.warn("Performance Testing data enabled",yd);const wd={count:1,statusRow:0,custom:null};function Od(e,t){if(0===t.length)return t;const n=t[0];if(!n.apiVersion)return t;let r=yd[e];return r?("number"===typeof r&&(r={count:r}),r={...wd,...r},Ed(t,r)):t}function Sd(e){return Math.floor(Math.random()*e)}function Ed(e,t){if(0===e.length)return e;if(0===t.count)return[];if(t.count<=e.length)return e.slice(0,t.count);const n=[];let r=0;e.forEach(e=>n.push(JSON.stringify(e)));const i=[...e],o=t.count-e.length;for(let a=0;a<o;a++){const e=JSON.parse(n[r]);if(e.id=`${e.id}_${a}`,e.metadata.uid=`uid_${a}_${1e3*Math.random()}`,e.metadata.name=`${e.metadata?.name}_${a}`,e.metadata.creationTimestamp=$c()().format(),i.push(e),t.statusRow>0){const n=1===t.statusRow||0===Sd(t.statusRow);if(n){e.metadata.state=e.metadata.state||{};const t=0===Sd(2);t?e.metadata.state.error=!0:e.metadata.state.transitioning=!0,e.metadata.state.message=`Test state description for ${e.metadata.name}`}}t.custom&&t.custom(e,a),r++,r===n.length&&(r=0)}return i}var xd=o(45858),_d=o(4364);function kd(e,t){let n=e.podsByNamespace[t];return n||(n={list:[],map:new Map},e.podsByNamespace[t]=n),n}function Cd(e,t,n,r){r&&Object.keys(e.podsByNamespace).forEach(t=>{delete e.podsByNamespace[t]}),n.forEach(n=>{const r=e.types[Z.Sm].map.get(n.id)||(0,nd.L8)(t,n),i=kd(e,r.namespace),o=i.map.get(n.id);o?(0,vd.HC)(o,n):((0,Ni.PG)(i.list,r),i.map.set(n.id,r))})}function Ad(e,t){if(t&&t.type===Z.Sm){const n=e.podsByNamespace[t.namespace];if(n){const e=n.list.findIndex(e=>e.id===t.id);e>=0&&n.list.splice(e,1),n.map.delete(t.id)}}else t&&t.type===Z.CU&&delete e.podsByNamespace[t.id]}var Td={batchChanges(e,{ctx:t,batch:n}){if((0,vd.AJ)(e,{ctx:t,batch:n}),n[Z.Sm]){const r=Object.entries(n[Z.Sm]).reduce((t,[n,r])=>(r.id?t.push(r):Ad(e,{id:n,type:Z.Sm,namespace:n.substring(0,n.indexOf("/"))}),t),[]);Cd(e,t,r,!1)}n[Z.CU]&&Object.entries(n[Z.CU]).forEach(([t,n])=>{n.id||Ad(e,{id:t,type:Z.CU})})},loadAll(e,{type:t,data:n,ctx:r,skipHaveAll:i,namespace:o,revision:a,pagination:s}){({NODE_ENV:"production",BASE_URL:"/"}).dev&&{NODE_ENV:"production",BASE_URL:"/"}.perfTest&&(n=Od(t,n));const l=(0,vd.gh)(e,{type:t,data:n,ctx:r,skipHaveAll:i,namespace:o,revision:a,pagination:s});if(t===Z.Sm&&Cd(e,r,l,!0),t===Z.yx){const e=(this.$workers||{})[r.getters.storeName];if(e){const t=(0,Do.yo)(n);e.postMessage({loadSchemas:t})}}},forgetType(e,t){(0,vd.WI)(e,t)&&Object.keys(e.inError).forEach(n=>{n.startsWith(t)&&delete e.inError[n]})},reset(e){(0,vd.zp)(e,this.commit),this.commit(`${e.config.namespace}/resetSubscriptions`),e.podsByNamespace={},xd["default"].reset(e.config.namespace)},loadMulti(e,{data:t,ctx:n}){const r=t[0]?.type,i=e.types[r];if(i?.havePage)_d.warn(`Prevented \`loadMulti\` mutation from polluting the cache for type "${r}" (currently represents a page).`);else for(const o of t){const t=(0,vd.Hh)(e,{data:o,ctx:n});if(t.type===Z.Sm&&t.metadata){const n=kd(e,t.namespace);(0,Ni.PG)(n.list,t),n.map.set(t.id,t)}}},loadAdd(e,{type:t,data:n,ctx:r}){(0,vd.aW)(e,{type:t,data:n,ctx:r}),n.length&&n[0].type===Z.Sm&&Cd(e,r,n,!1)},remove(e,t){(0,vd.TF)(e,t,this.getters),Ad(e,t)}},Rd=o(27500),Nd=o.n(Rd),Pd=o(4364);function Id(e,t,n){t=t||{},t.method=t.method||"get",t.headers=t.headers||{},t.headers.accept="application/jsonl";const r=new TextDecoder;let i="";return fetch(e,t).then(e=>{if(e.status>=400){Pd.error("Error Streaming",e);const t={message:"Error Streaming"};return t.response=e,Promise.reject(t)}return e.body.getReader()}).then(e=>e.read().then(function t({value:o,done:a}){if(a)return void n(JSON.parse(i));i+=r.decode(o,{stream:!0});const s=i.split(/[\r\n](?=.)/);return i=s.pop(),s.map(JSON.parse).forEach(n),e.read().then(t)}))}function Md(){const e="undefined"!==typeof TextDecoder;return e}var Dd=o(41580),Ld=o.n(Dd),Bd=o(4364);let $d;function Vd(e){const t=e.split($d.separator)||[];return t.reduce((e,t)=>{const n=t.trim();if(!n)return e;const r=n.endsWith(",")?n.slice(0,-1):n;return e.push($d.separator+r),e},[])}function Fd(e,t,n,r,i=!1){var o,a,s,l;const c=null===r||void 0===r?void 0:r.toLowerCase();if("post"!==c&&"put"!==c||!(null===(o=e.headers)||void 0===o?void 0:o.warning))return;if(!$d||i){const e=(0,Kn.fD)(n);$d=null===e||void 0===e?void 0:e.kubeAPI.warningHeader}const u=Vd(null===(a=e.headers)||void 0===a?void 0:a.warning);if(!u.length)return;const d=u.filter(e=>!$d.notificationBlockList.find(t=>e.startsWith(t)));if(d.length){const i=(null===(s=e.data)||void 0===s?void 0:s.type)||(null===(l=e.data)||void 0===l?void 0:l.kind)||n["i18n/t"]("generic.resource",{count:1});t("growl/warning",{title:"put"===r?n["i18n/t"]("growl.kubeApiHeaderWarning.titleUpdate",{resourceType:i}):n["i18n/t"]("growl.kubeApiHeaderWarning.titleCreate",{resourceType:i}),message:d.join(", "),timeout:0},{root:!0})}const h=`Validation Warnings for ${e.config.url}\n\n${u.join("\n")}`;!{NODE_ENV:"production",BASE_URL:"/"}.dev?Bd.debug(h):Bd.warn(`${h}\n\n`,e.data)}var jd=o(22915),Ud=o(4364),Gd={async loadSchemas(e,t=!0){return await(0,Au.BH)(e,t)},async request({state:e,dispatch:t,rootGetters:n,getters:r},i){const o=i.opt||i,a=await(0,Au.wA)(n,"cluster",o);if(a)return a;o.url=o.url.replace(/\/*$/g,"");const s="epinio"===this.$config.rancherEnv?"/pp/v1/epinio/rancher":"";if(s)if(o.url.startsWith("/"))o.url=s+o.url;else{const e=(0,ot.qg)(o.url);e.path.startsWith(s)||(e.path=s+e.path,o.url=(0,ot.As)(e))}o.httpsAgent=new(Nd().Agent)({rejectUnauthorized:!1});const l=(o.method||"get").toLowerCase(),c=o.headers||{},u=JSON.stringify(c)+l+o.url;let d,h;if("get"===l){if(d=e.deferredRequests[u],d){const e=(0,ne.yX)();return d.push(e),e.promise}d=[],e.deferredRequests[u]=d}if(o.stream&&e.allowStreaming&&e.config.supportsStream&&Md())return Id(o.url,o,o.onData).then(()=>({finishDeferred:m.bind(null,u,"resolve")})).catch(e=>v(e));const p=r.isSteveUrl(o.url);while(1)try{const e=await f(this,o,n);if(!o.depaginate)return e;if(h)h.out.data=h.out.data.concat(e.data);else{const t=p&&o.url.includes(`pagesize=${Ru.A.defaultPageSize}`)?{total:e.count,page:1,url:o.url}:null,n=t?null:{};h={pageByLimit:n,pageByNumber:t,out:e}}const{total:t,page:r,url:i}=h.pageByNumber||{};if(h.pageByLimit&&e?.pagination?.next)o.url=e?.pagination?.next;else{if(!(h.pageByNumber&&t>Ru.A.defaultPageSize*r))return delete h.out.pagination?.first,delete h.out.pagination?.last,delete h.out.pagination?.next,delete h.out.pagination?.partial,delete h.out.continue,h.out;h.pageByNumber.page+=1,o.url=(0,ot.R_)(i,"page",`${h.pageByNumber.page}`)}}catch(b){return v(b)}function f(e,n,r){return e.$axios(n).then(e=>{let i;return i=n.responseType?e:g(e),m(u,"resolve",i),Fd(e,t,r,n.method),i})}function m(t,n="resolve",r){const i=e.deferredRequests[t]||[];while(i.length)i.pop()[n](r);delete e.deferredRequests[t]}function g(e){let r=e.data;const i=e.headers["x-api-cattle-auth"];return i&&i!==n["auth/fromHeader"]&&t("auth/gotHeader",i,{root:!0}),204!==e.status&&null!==r||(r={}),"object"!==typeof r&&(r={data:r}),Object.defineProperties(r,{_status:{value:e.status},_statusText:{value:e.statusText},_headers:{value:e.headers},_req:{value:e.request},_url:{value:o.url}}),r}function v(e){let n=e;if(e?.response){const r=e.response;!1!==o.redirectUnauthorized&&401===r.status&&t("auth/logout",o.logoutOnError,{root:!0}),"undefined"!==typeof r.data&&(n=g(r))}return m(u,"reject",n),Promise.reject(n)}},async fetchResourceSummary({getters:e,dispatch:t},{type:n,opt:r={}}){n=e.normalizeType(n);const i=e.schemaFor(n);if(i)if(r.summaryField)try{const e=new URL(i.links.collection,window.location.origin);if(i.attributes?.namespaced&&r.namespace&&(e.pathname+=`/${r.namespace}`),e.searchParams.set("summary",r.summaryField),!1!==r.summaryOnly&&e.searchParams.set("summaryonly",""),r.namespaceCounts&&e.searchParams.set("summarynamespaced",""),r.filters?.length){const t=new URLSearchParams(ld.A.convertPaginationParams({schema:i,filters:r.filters}));t.forEach((t,n)=>e.searchParams.append(n,t))}if(r.labelSelector){const t=new URLSearchParams(ld.A.convertLabelSelectorPaginationParams({labelSelector:r.labelSelector}));t.forEach((t,n)=>e.searchParams.append(n,t))}const n=await t("request",{opt:{url:e.pathname+e.search}});return{count:n.count??0,summary:n.summary||null}}catch(o){return void Ud.warn(`fetchResourceSummary: summary API request failed for type "${n}"`,o)}else Ud.warn(`fetchResourceSummary: summaryField is required and must be a string for type "${n}"`);else Ud.warn(`fetchResourceSummary: no schema found for type "${n}"`)},promptRestore({commit:e,state:t},n){e("action-menu/togglePromptRestore",n,{root:!0})},async resourceAction({getters:e,dispatch:t},{resource:n,actionName:r,body:i,opt:o}){o=o||{},o.url||(o.url=n.actionLinkFor(r)),o.method="post",o.data=i;const a=await t("request",{opt:o});return!1!==o.load&&"collection"===a.type?(await t("loadMulti",a.data),a.data.map(t=>e.byId(t.type,t.id)||t)):!1!==o.load&&a.type&&a.id?t("load",{data:a}):a},async collectionAction({getters:e,dispatch:t},{type:n,actionName:r,body:i,opt:o}){if(o=o||{},!o.url){const t=e["schemaFor"](n);o.url=(0,ot.R_)(t.links.collection,"action",r)}o.method="post",o.data=i;const a=await t("request",{opt:o});return!1!==o.load&&"collection"===a.type?(await t("loadMulti",a.data),a.data.map(t=>e.byId(t.type,t.id)||t)):!1!==o.load&&a.type&&a.id?t("load",{data:a}):a},createNamespace(e,t){return(0,nd.L8)(e,{type:Z.CU,metadata:{name:t.name}})},cleanForNew(e,t){const n=t.metadata||{};return(0,Do.cX)(t,Qd),(0,Do.cX)(n,zd),Wd(n.annotations),Wd(n.labels),n.name="",t?.spec?.crd?.spec?.names?.kind&&(t.spec.crd.spec.names.kind=""),t},cleanForDiff(e,t){const n=t.metadata||{};return n.labels||(n.labels={}),n.annotations||(n.annotations={}),Kd(t),(0,Do.cX)(t,Hd),(0,Do.cX)(n,qd),Wd(n.annotations),Wd(n.labels),t},cleanForDetail(e,t){return t.metadata||(0,Do.hZ)(t,"metadata",{}),t.metadata.annotations||(0,Do.hZ)(t,"metadata.annotations",{}),t.metadata.labels||(0,Do.hZ)(t,"metadata.labels",{}),t},cleanForDownload(e,t){const{yaml:n,opt:r}="string"===typeof t?{yaml:t}:t||{};return(0,jd.C)(n,r)}};const Hd=["actions","links","status","__rehydrate","__clone"],qd=["ownerReferences","selfLink","creationTimestamp","deletionTimestamp","state","fields","relationships","generation","managedFields","resourceVersion"],Qd=["actions","links","status","id"],zd=[...qd,"uid"];function Kd(e){for(const t in e)if(t.startsWith("__"))delete e[t];else{const n=e[t];Ld()(n)&&Kd(n)}}function Wd(e){e&&Object.keys(e).forEach(t=>{t.match(/(^|field\.)cattle\.io(\/.*|$)/)&&delete e[t]})}var Xd,Yd;function Zd(e,t){return{...Mc.fs,state(){return{...(0,Mc.Ut)(e,t),socket:null,queue:[],wantSocket:!1,debugSocket:!1,allowStreaming:!0,pendingFrames:[],deferredRequests:{},started:[],inError:{},socketListenerManager:(0,i.markRaw)(new Pu),podsByNamespace:{}}},getters:{...Mc.fs.getters,...gd,...td},mutations:{...Mc.fs.mutations,...Td,...ed},actions:{...Mc.fs.actions,...Gd,...Ju}}}const Jd=(e,t)=>{Gu(e,t)};var eh=e=>{switch(e.namespace=e.namespace||"",e.baseUrl=e.baseUrl||`/${e.namespace}`,e.namespace){case"management":e.modelBaseClass=Yd.BY_TYPE;break;case"rancher":e.modelBaseClass=Yd.NORMAN;break}return Xd(Zd(e.namespace,e.baseUrl),e,Jd)};(Object.getOwnPropertyDescriptor(eh,"name")||{}).writable||Object.defineProperty(eh,"name",{value:"default",configurable:!0});var th=o(74302),nh=o(50889);const rh={[l.rk.BACKUP]:{filter:`spec.type!=${Es.aS.SNAPSHOT}`},[l.rk.VM_SNAPSHOT]:{filter:`spec.type=${Es.aS.SNAPSHOT}`},[l.rk.SNAPSHOT]:{filter:"metadata.ownerReferences.kind=PersistentVolumeClaim"},[l.rk.STORAGE]:{filter:"parameters.backingImage!="},[l.rk.CLOUD_TEMPLATE]:{labelSelector:Nr.r.CLOUD_INIT},[l.rk.NETWORK_ATTACHMENT]:{filter:"metadata.generateName!=storagenetwork-"},[l.rk.VOLUME]:{filter:"metadata.ownerReferences.kind!=PersistentVolumeClaim"},[l.us]:{filter:"metadata.ownerReferences.kind=VirtualMachineImage"}},ih=new Set([l.rk.NETWORK_ATTACHMENT,l.rk.CLUSTER_FLOW,l.rk.CLUSTER_OUTPUT,l.rk.FLOW,l.rk.OUTPUT,l.rk.ADD_ONS]);function oh(e){return e.isAllNamespaces&&!e.currentProduct?.hideSystemResources?null:Object.keys(e.namespaces())}function ah(e,t){return!!t?.attributes?.namespaced&&!ih.has(e)}function sh(e,t,n){const r=e.schemaFor(n);if(!r?.links?.collection)return null;const i={...rh[n],pagesize:"1"};if(ah(n,r)){const e=oh(t);if(0===e?.length)return{count:0};e&&(i.projectsornamespaces=e.join(","))}return{url:(0,ot.g)(e.urlFor(r.id),i)}}function lh(e,t,n){const r=e.all(Z.i2)?.[0]?.counts?.[t];return r?n?n.reduce((e,t)=>e+(r.namespaces?.[t]?.count||0),0):r.summary?.count||0:null}function ch(e){return e.haveAll(Z.CU)?e.all(Z.CU).filter(e=>!e.isSystem&&!e.isFleetManaged).length:null}function uh(e){const t=e.filteredCounts?.[l.rk.VOLUME]??null,n=e.filteredCounts?.[l.us]??null;return null===t||null===n?null:Math.max(t-n,0)}function dh(e){return e.haveAll(l.rk.SETTING)?e.visibleSettings.length:null}function hh(e,t,n,r){const i=r?.name;if(!i)throw new Error(`Resource type required to calc count: ${JSON.stringify(r)}`);if(i===l.rk.VOLUME)return uh(e);if(rh[i])return e.filteredCounts?.[i]??null;if(i===Z.CU&&t.currentProduct?.hideSystemResources)return ch(n);if(i===l.rk.SETTING)return dh(n);const o=n.schemaFor(i),a=o?.id||i,s=ah(i,o)?oh(t):null;return lh(n,a,s)}var ph={namespaceFilterOptions:(e,t,n,r)=>({addNamespace:e,divider:n,notFilterNamespaces:i})=>{const o=[{id:Li.tj,kind:Li.T6.SPECIAL,label:r["i18n/t"]("nav.ns.all")}];n(o);const a=t.filterNamespace(i);if(!r["isStandaloneHarvester"]&&r["currentCluster"]&&"_"!==r["currentCluster"]?.id){const t=r["currentCluster"];let i=r["management/all"](Z.Mc.PROJECT);i=(0,th.Ul)((0,Ni.WP)(i,"spec.clusterName",t.id),["nameDisplay"]).filter(e=>"System"!==e.nameDisplay);const s={},l={};let c=!0;l["null"]=[];for(const e of i)s[e.metadata.name]=e;for(const e of a){let t=e.projectId;t&&s[t]||(t="null");let n=l[t];n||(n=[],l[e.projectId]=n),n.push(e)}for(const r of i){const t=r.metadata.name;c?c=!1:n(o),o.push({id:`project://${t}`,kind:"project",label:r.nameDisplay});const i=l[t]||[];e(o,i)}const u=l["null"];u.length&&(c||n(o),o.push({id:Li.pF,kind:"project",label:r["i18n/t"]("nav.ns.orphan")}),e(o,u))}else e(o,a);return o},filterNamespace(e,t,n,r,i){const o=t.all("namespace");return(e=[])=>o.filter(t=>!t.isSystem||e.includes(t.id))},filterProject(e,t,n,r){const i=r["management/all"](Z.Mc.PROJECT),o=r["currentCluster"],a=o.id;return i.filter(e=>e.spec.clusterName===a&&"System"!==e.nameDisplay)},visibleSettings(e,t,n,r){const i=[...r.isSingleProduct?r["management/all"](Z.Mc.SETTING):[],...t.all(l.rk.SETTING)],o=Object.fromEntries(i.map(e=>[e.id,e])),a=r.isStandaloneHarvester?{...nh.gh,...nh.LP}:nh.gh;return Object.entries(a).filter(([e,t])=>o[e]&&(!t.featureFlag||r["harvester-common/getFeatureEnabled"](t.featureFlag))).map(([e,t])=>({id:e,config:t,data:o[e]}))},schemaFor:(e,t,n,r)=>(n,i=!1,o=!0)=>{const a=t.normalizeType(n),s=e.types["schema"],l=s?.map?.get(a);if(l)return l;const c=r["type-map/optionsFor"](n)?.resource;if(c&&c!==n){const e=t.normalizeType(c);return s?.map?.get(e)||null}return null},count:(e,t,n,r)=>n=>{const i=r["type-map/optionsFor"]?.(n?.name)?.subTypes||[];return i.length?i.reduce((n,i)=>n+hh(e,r,t,{name:i}),0):hh(e,r,t,n)}},fh={filteredCountRequested(e,t){e.filteredCountRequests[t]=(e.filteredCountRequests[t]||0)+1},setFilteredCount(e,{name:t,count:n}){e.filteredCounts={...e.filteredCounts,[t]:n}},resetFilteredCounts(e){e.filteredCounts={}},setFilteredCountWatchers(e,t){e.filteredCountWatchers=(0,i.markRaw)(t)}},mh={async loadCluster({state:e,commit:t,dispatch:n,getters:r,rootGetters:i,rootState:o},{id:a}){await n("management/waitForSchema",{type:Z.Mc.CLUSTER},{root:!0});const s=await n("management/find",{type:Z.Mc.CLUSTER,id:a,opt:{url:`${Z.Mc.CLUSTER}s/${escape(a)}`}},{root:!0});let c=`/k8s/clusters/${escape(a)}/v1/harvester`;if("local"===a&&(c="/v1/harvester"),!s)throw t("clusterId",null,{root:!0}),t("applyConfig",{baseUrl:null}),new Rr.oV(a);t("applyConfig",{baseUrl:c}),await Promise.all([n("loadSchemas",!0)]),n("subscribe");const u={type:Z.Mc.PROJECT,opt:{url:`${Z.Mc.PROJECT}/${escape(a)}`,watchNamespace:a}},d=async()=>{let e=3e4;const t=100;while(e>0&&!o.managementReady)await setTimeout(()=>{},t),e-=t;if(i["management/schemaFor"](Z.Mc.PROJECT))return n("management/findAll",u,{root:!0})};if("local"!==a&&r["schemaFor"](Z.Mc.SETTING)){const e=await n("findAll",{type:Z.Mc.SETTING,id:J.HG.SYSTEM_NAMESPACES,opt:{url:`${c}/${Z.Mc.SETTING}s/`,force:!0}}),r=e?.find(e=>e.id===J.HG.SYSTEM_NAMESPACES);if(r){const e=(r.value||r.default)?.split(",");t("setSystemNamespaces",e,{root:!0})}}const h={projects:d(),virtualCount:n("findAll",{type:Z.i2}),virtualNamespaces:n("findAll",{type:Z.CU}),settings:n("findAll",{type:l.rk.SETTING}),clusters:n("management/findAll",{type:Z.Mc.CLUSTER,opt:{force:!0}},{root:!0})};r["schemaFor"](l.rk.RESOURCE_QUOTA)&&(h.resourceQuota=n("findAll",{type:l.rk.RESOURCE_QUOTA})),r["schemaFor"](l.rk.UPGRADE)&&(h.upgrades=n("findAll",{type:l.rk.UPGRADE})),r["schemaFor"](l.rk.UPGRADE_LOG)&&(h.upgradeLogs=n("findAll",{type:l.rk.UPGRADE_LOG}));const p=await(0,ne.kR)(h),f=i["harvester-common/getFeatureEnabled"]("supportHarvesterClusterVersion");if(!f){const e=i["productId"];return void this.$router?.push({name:`${e}-c-cluster-unsupported${"local"===a?"-standalone":""}`,params:{product:e}})}await n("cleanNamespaces",null,{root:!0});const m=(0,Li.yK)(a,"harvester"),g=i["prefs/get"](N.cx)?.[m];t("updateNamespaces",{filters:g||[],all:r.filterNamespace(),getters:r},{root:!0}),n("watchFilteredCounts",{clusterId:a});const v={def:!1,parseJSON:!0,inheritFrom:N.IJ,asUserPreference:!0};t("prefs/setDefinition",{name:"view-in-api",definition:v},{root:!0}),t("prefs/setDefinition",{name:"all-namespaces",definition:v},{root:!0}),t("prefs/setDefinition",{name:"theme-shortcut",definition:v},{root:!0}),t("prefs/setDefinition",{name:"plugin-developer",definition:v},{root:!0});const b=!(1===p.clusters.length&&"local"===p.clusters[0].metadata?.name);b&&t("managementChanged",{ready:!0,isMultiCluster:!0,isRancher:!0},{root:!0})},async fetchFilteredCounts({state:e,commit:t,dispatch:n,getters:r,rootGetters:i},o=Object.keys(rh)){await Promise.all(o.map(async o=>{t("filteredCountRequested",o);const a=e.filteredCountRequests[o],s=sh(r,i,o);let l=s?.count??null;if(s?.url)try{const e=await n("request",{url:s.url});l=e?.count??(e?.data?.length?null:0)}catch(c){l=null}e.filteredCountRequests[o]===a&&t("setFilteredCount",{name:o,count:l})}))},watchFilteredCounts({state:e,commit:t,dispatch:n,getters:i,rootGetters:o},{clusterId:a}){if(o.clusterId!==a)return;e.filteredCountWatchers.forEach(e=>e()),t("resetFilteredCounts");const s=e=>{o.clusterId===a&&o.currentProduct?.inStore===r.KR&&n("fetchFilteredCounts",e)},l=Object.keys(rh),c={};l.forEach(e=>{const t=i.schemaFor(e)?.id;t&&(c[t]=[...c[t]||[],e])});const u=Object.entries(c).map(([e,t])=>{const n=Pe()(()=>s(t),1e3),r=this.watch(()=>JSON.stringify(i.all?.(Z.i2)?.[0]?.counts?.[e]||null),n);return()=>{r(),n.cancel()}});return u.push(this.watch(()=>JSON.stringify(oh(o)),()=>s(l.filter(e=>ah(e,i.schemaFor(e)))))),t("setFilteredCountWatchers",u),n("fetchFilteredCounts")}};const gh=()=>{const e=Zd(null,null),t=e.state;return e.state=()=>({...t(),filteredCounts:{},filteredCountRequests:{},filteredCountWatchers:[]}),e.getters={...e.getters,...ph},e.mutations={...e.mutations,...fh},e.actions={...e.actions,...mh},e},vh={namespace:r.KR,isClusterStore:!0};var bh={specifics:gh(),config:vh,init:Jd},yh=o(52880),wh=o(38223),Oh=o(66490),Sh=o(84757);const Eh=63;function xh(e,t,n,r){const{domain:{devices:{interfaces:i}},networks:o}=e,a=[];return i.map((e,r)=>{const i=o.find(t=>e.name===t.name),s=e.name||i.name||`Network ${r+1}`,l=t["i18n/t"]("harvester.fields.network"),c=t["i18n/t"]("harvester.validation.vm.network.lowerType"),u=t["i18n/t"]("harvester.validation.vm.network.upperType");if(Ch(t,n,e.name,a,s,l,c,u),i.multus&&!i.multus.networkName){const e=t["i18n/t"]("harvester.fields.network"),r=t["i18n/t"]("validation.required",{key:e});n.push(t["i18n/t"]("harvester.validation.generic.tabError",{prefix:s,message:r}))}if(e.macAddress&&!(0,wh.iw)(e.macAddress)&&!i.pod){const e=t["i18n/t"]("harvester.validation.vm.network.macFormat");n.push(t["i18n/t"]("harvester.validation.generic.tabError",{prefix:s,message:e}))}}),n}function _h(e,t,n,r,i,o){const a=r.includes("isVMTemplate"),s=a?this.value.spec.vm:o,l=(0,Oh.vN)(s),c=e.template.spec.volumes||[],u=e.template.spec.domain.devices.disks||[],d=[];return u.forEach((e,r)=>{const i=e.name||c[r]?.name||`Volume ${r+1}`;if(!e.disk&&!e.cdrom){const e=t["i18n/t"]("harvester.fields.type"),r=t["i18n/t"]("validation.required",{key:e});n.push(t["i18n/t"]("harvester.validation.generic.tabError",{prefix:i,message:r}))}const o=t["i18n/t"]("harvester.fields.volume"),a=t["i18n/t"]("harvester.validation.vm.volume.lowerType"),s=t["i18n/t"]("harvester.validation.vm.volume.upperType");Ch(t,n,e.name,d,i,o,a,s)}),c.forEach((e,r)=>{const{type:i,typeValue:s}=kh(t,e,l,o),c=e.name||r+1;if(i===ra.xO.NEW||i===ra.xO.IMAGE){if(!/([1-9]|[1-9][0-9]+)[a-zA-Z]+/.test(s?.spec?.resources?.requests?.storage)){const e=t["i18n/t"]("harvester.fields.size"),r=t["i18n/t"]("validation.required",{key:e});n.push(t["i18n/t"]("harvester.validation.generic.tabError",{prefix:c,message:r}))}if(s?.spec?.resources?.requests?.storage&&!/^([0-9][0-9]{0,8})[a-zA-Z]+$/.test(s?.spec?.resources?.requests?.storage)){const e=t["i18n/t"]("harvester.validation.generic.maximumSize",{max:`999999999 ${Sh.Wl}`});n.push(t["i18n/t"]("harvester.validation.generic.tabError",{prefix:c,message:e}))}if(i===ra.xO.IMAGE&&!s?.spec?.storageClassName&&!a){const e=t["i18n/t"]("harvester.fields.image"),r=t["i18n/t"]("validation.required",{key:e});n.push(t["i18n/t"]("harvester.validation.generic.tabError",{prefix:c,message:r}))}if(!s?.spec?.storageClassName&&e?.persistentVolumeClaim?.claimName&&i!==ra.xO.IMAGE){const e=t["i18n/t"]("harvester.fields.storageClass"),r=t["i18n/t"]("validation.required",{key:e});n.push(t["i18n/t"]("harvester.validation.generic.tabError",{prefix:c,message:r}))}}if(i===ra.xO.ATTACH_VOLUME){const r=t["harvester/all"](Z.YH),i=e?.persistentVolumeClaim?.claimName,a=r.find(e=>e.id===`${o.metadata.namespace}/${i}`);if(!a&&i){const e=t["i18n/t"]("harvester.fields.volume");n.push(t["i18n/t"]("harvester.validation.generic.hasDelete",{type:e,name:i}))}if(!i){const e=t["i18n/t"]("harvester.virtualMachine.volume.volume");n.push(t["i18n/t"]("validation.required",{key:e}))}}if(i===ra.xO.CONTAINER&&!e.containerDisk.image){const e=t["i18n/t"]("harvester.fields.dockerImage"),r=t["i18n/t"]("validation.required",{key:e});n.push(t["i18n/t"]("harvester.validation.generic.tabError",{prefix:c,message:r}))}}),n}function kh(e,t,n,r){let i=null;const o=e["harvester/all"](Z.YH);if(t.persistentVolumeClaim){const e=t?.persistentVolumeClaim?.claimName,a=o.find(t=>t.id===`${r.metadata.namespace}/${e}`);if(a)return{type:ra.xO.ATTACH_VOLUME,typeValue:null};if(i=n.find(e=>t.persistentVolumeClaim.claimName===e.metadata.name&&e.metadata?.annotations&&Object.prototype.hasOwnProperty.call(e.metadata.annotations,"harvesterhci.io/imageId")),i)return{type:ra.xO.IMAGE,typeValue:i};if(i=n.find(e=>t.persistentVolumeClaim.claimName===e.metadata.name),i)return{type:ra.xO.NEW,typeValue:i}}return t.containerDisk?{type:ra.xO.CONTAINER,typeValue:null}:{}}function Ch(e,t,n,r=[],i,o,a,s){if(-1!==r.findIndex(e=>n===e)&&t.push(e["i18n/t"]("harvester.validation.vm.duplicatedName",{type:o,name:n})),r.push(n),n&&n?.length>Eh){const n=e["i18n/t"]("harvester.fields.name"),r=e["i18n/t"]("harvester.validation.generic.maxLength",{key:n,max:Eh});t.push(e["i18n/t"]("harvester.validation.generic.tabError",{prefix:i,message:r}))}if(!n){const n=e["i18n/t"]("harvester.fields.name"),r=e["i18n/t"]("validation.required",{key:n});t.push(e["i18n/t"]("harvester.validation.generic.tabError",{prefix:i,message:r}))}if(!(0,wh.zv)(n)){const r="^[a-z0-9]([-a-z0-9]*[a-z0-9])?$";t.push(e["i18n/t"]("harvester.validation.generic.regex",{lowerType:a,name:n,regex:r,upperType:s}))}}var Ah=o(95799);function Th(e,t,n,r){const i=t["i18n/t"];if(!e||""===e){const e=i("harvester.volume.size");return n.push(i("validation.required",{key:e})),n}const o=Rh(e),a=999999,s=/^[1-9]\d*$/;return(!s.test(o)||o>a)&&n.push(i("harvester.validation.volume.sizeRange")),n}function Rh(e){if(!e)return null;const t=(0,Ah.ao)(e);return(0,Ah.Mo)(t,{addSuffix:!1,increment:1024,minExponent:3,maxExponent:3})}function Nh(e,t,n,r){const i=t["i18n/t"];if(!e)return n;const o=JSON.parse(e),a=o.type;return a?("s3"===a&&(o.accessKeyId||n.push(i("validation.required",{key:"accessKeyId"})),o.secretAccessKey||n.push(i("validation.required",{key:"secretAccessKey"})),o.bucketRegion||n.push(i("validation.required",{key:"bucketRegion"})),o.bucketName||n.push(i("validation.required",{key:"bucketName"}))),o.endpoint||"s3"===a||n.push(i("validation.required",{key:"endpoint"})),n):n}function Ph(e,t,n,r){const{ntpServers:i}=JSON.parse(e),o=t["i18n/t"],a=/^(?:[0-9]{1,3}\.){3}[0-9]{1,3}$/,s=/^(?!:\/\/)(?:[a-zA-Z0-9-]{1,63}\.)+[a-zA-Z]{2,63}$/;if(!i)return n;const l=new Set(i);return i.length!==l.size&&n.push(o("harvester.setting.ntpServers.isDuplicate")),i.find(e=>!a.test(e)&&!s.test(e))&&n.push(o("harvester.setting.ntpServers.isNotIPV4")),n}function Ih(e,t,n,r,i,o){if(!e){const e=t["i18n/t"]("harvester.volume.size");n.push(t["i18n/t"]("validation.required",{key:e}))}if(e&&!/^([0-9][0-9]{0,8})[a-zA-Z]+$/.test(e)){const e=t["i18n/t"]("harvester.validation.generic.maximumSize",{max:`999999999 ${Sh.Wl}`});n.push(e)}return n}function Mh(e,t,n,r){const i=yo().load(e),o=[{path:"prometheus.prometheusSpec.scrapeInterval",translationKey:"monitoring.prometheus.config.scrape"},{path:"prometheus.prometheusSpec.evaluationInterval",translationKey:"monitoring.prometheus.config.evaluation"},{path:"prometheus.prometheusSpec.retention",translationKey:"monitoring.prometheus.config.retention"},{path:"prometheus.prometheusSpec.retentionSize",translationKey:"monitoring.prometheus.config.retentionSize"},{path:"prometheus.prometheusSpec.resources.requests.cpu",translationKey:"monitoring.prometheus.config.requests.cpu"},{path:"prometheus.prometheusSpec.resources.requests.memory",translationKey:"monitoring.prometheus.config.requests.memory"},{path:"prometheus.prometheusSpec.resources.limits.cpu",translationKey:"monitoring.prometheus.config.limits.cpu"},{path:"prometheus.prometheusSpec.resources.limits.memory",translationKey:"monitoring.prometheus.config.limits.memory"},{path:"prometheus-node-exporter.resources.requests.cpu",translationKey:"monitoring.prometheus.config.requests.cpu"},{path:"prometheus-node-exporter.resources.requests.memory",translationKey:"monitoring.prometheus.config.requests.memory"},{path:"prometheus-node-exporter.resources.limits.cpu",translationKey:"monitoring.prometheus.config.limits.cpu"},{path:"prometheus-node-exporter.resources.limits.memory",translationKey:"monitoring.prometheus.config.limits.memory"},{path:"grafana.resources.requests.cpu",translationKey:"monitoring.prometheus.config.requests.cpu"},{path:"grafana.resources.requests.memory",translationKey:"monitoring.prometheus.config.requests.memory"},{path:"grafana.resources.limits.cpu",translationKey:"monitoring.prometheus.config.limits.cpu"},{path:"grafana.resources.limits.memory",translationKey:"monitoring.prometheus.config.limits.memory"},{path:"alertmanager.alertmanagerSpec.retention",translationKey:"monitoring.prometheus.config.retention"},{path:"alertmanager.alertmanagerSpec.resources.requests.cpu",translationKey:"monitoring.prometheus.config.requests.cpu"},{path:"alertmanager.alertmanagerSpec.resources.requests.memory",translationKey:"monitoring.prometheus.config.requests.memory"},{path:"alertmanager.alertmanagerSpec.resources.limits.cpu",translationKey:"monitoring.prometheus.config.limits.cpu"},{path:"alertmanager.alertmanagerSpec.resources.limits.memory",translationKey:"monitoring.prometheus.config.limits.memory"}];return o.forEach(e=>{(0,Do.Jt)(i,e.path)||n.push(t["i18n/t"]("validation.required",{key:t["i18n/t"](e.translationKey)}))}),n}function Dh(e,t,n,r){const i=yo().load(e),o=[{path:"fluentbit.resources.requests.cpu",translationKey:"monitoring.prometheus.config.requests.cpu"},{path:"fluentbit.resources.requests.memory",translationKey:"monitoring.prometheus.config.requests.memory"},{path:"fluentbit.resources.limits.cpu",translationKey:"monitoring.prometheus.config.limits.cpu"},{path:"fluentbit.resources.limits.memory",translationKey:"monitoring.prometheus.config.limits.memory"},{path:"fluentd.resources.requests.cpu",translationKey:"monitoring.prometheus.config.requests.cpu"},{path:"fluentd.resources.requests.memory",translationKey:"monitoring.prometheus.config.requests.memory"},{path:"fluentd.resources.limits.cpu",translationKey:"monitoring.prometheus.config.limits.cpu"},{path:"fluentd.resources.limits.memory",translationKey:"monitoring.prometheus.config.limits.memory"}];return o.forEach(e=>{(0,Do.Jt)(i,e.path)||n.push(t["i18n/t"]("validation.required",{key:t["i18n/t"](e.translationKey)}))}),n}function Lh(e=[],t,n,r){const i=t["i18n/t"];return 0===e.length&&n.push(i("validation.required",{key:i("harvester.ipPool.tabs.range")},!0)),e.map(e=>{e.subnet||n.push(i("validation.required",{key:i("harvester.ipPool.subnet.label")},!0))}),n}function Bh(e,t,n,r,i){return/^[a-f0-9]{128}$/i.test(e)||n.push(t["i18n/t"]("harvester.validation.hash.sha512")),n}var $h={imageUrl:yh.b8,dataVolumeSize:Th,vmNetworks:xh,vmDisks:_h,fileRequired:yh._X,backupTarget:Nh,ntpServers:Ph,volumeSize:Ih,rancherMonitoring:Mh,rancherLogging:Dh,ranges:Lh,hashSHA512:Bh},Vh=o(22827);o(18955);function Fh(e){const t={NODE_ENV:"production",BASE_URL:"/"}.rancherEnv===r.KR;n(e),t?e.register("l10n-global",Vh.M9,Vh.I0):(0,Vh.jF)(e.environment?.version)||(0,Vh.Am)(o(49037)),e.metadata=o(8330),e.metadata.icon=o(99086),e.addProduct(o(48050)),e.addDashboardStore(Ic.config.namespace,Ic.specifics,Ic.config),e.addDashboardStore(bh.config.namespace,bh.specifics,bh.config,bh.init),e.validators=$h,e.addRoutes(xc),e.register("component","NavHeaderRight",(0,i.defineAsyncComponent)(()=>o.e(489).then(o.bind(o,75489))))}Object.defineProperty(Fh,"name",{value:"default",configurable:!0});var jh=Fh}(),a}()});
|
||
//# sourceMappingURL=harvester-1.10.0-dev.umd.min.js.map |