@kylincloud/flamegraph 0.36.1 → 0.36.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +8 -0
- package/dist/flamegraphRenderWorker.js +1 -1
- package/dist/flamegraphRenderWorker.js.map +1 -1
- package/dist/index.cjs.js +4 -4
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +4 -4
- package/dist/index.esm.js.map +1 -1
- package/dist/index.node.cjs.js +4 -4
- package/dist/index.node.cjs.js.map +1 -1
- package/dist/index.node.esm.js +4 -4
- package/dist/index.node.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/ProfilerTable.tsx +2 -2
- package/src/sass/flamegraph.scss +7 -0
package/dist/index.node.esm.js
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import{jsx as e,jsxs as t,Fragment as n}from"react/jsx-runtime";import
|
|
1
|
+
import{jsx as e,jsxs as t,Fragment as n}from"react/jsx-runtime";import r,{useId as a,useMemo as o,createContext as i,forwardRef as l,useState as s,useRef as c,useCallback as u,useLayoutEffect as f,useEffect as d,useReducer as h,useContext as m,useImperativeHandle as p,Fragment as g,cloneElement as v,version as b,memo as y,createElement as w,isValidElement as x,Component as k}from"react";import{z as _}from"zod";import{unstable_batchedUpdates as N,flushSync as S,createPortal as M}from"react-dom";import T from"./logo-v3-small.svg";var C="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function j(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var O,R={exports:{}};
|
|
2
2
|
/*!
|
|
3
3
|
Copyright (c) 2018 Jed Watson.
|
|
4
4
|
Licensed under the MIT License (MIT), see
|
|
5
5
|
http://jedwatson.github.io/classnames
|
|
6
|
-
*/var
|
|
6
|
+
*/var P,E=(O||(O=1,P=R,function(){var e={}.hasOwnProperty;function t(){for(var e="",t=0;t<arguments.length;t++){var a=arguments[t];a&&(e=r(e,n.call(this,a)))}return e}function n(n){if("string"==typeof n||"number"==typeof n)return this&&this[n]||n;if("object"!=typeof n)return"";if(Array.isArray(n))return t.apply(this,n);if(n.toString!==Object.prototype.toString&&!n.toString.toString().includes("[native code]"))return n.toString();var a="";for(var o in n)e.call(n,o)&&n[o]&&(a=r(a,this&&this[o]||o));return a}function r(e,t){return t?e?e+" "+t:e+t:e}P.exports?(t.default=t,P.exports=t):window.classNames=t}()),R.exports),F=j(E);
|
|
7
7
|
/*!
|
|
8
8
|
* Font Awesome Free 7.1.0 by @fontawesome - https://fontawesome.com
|
|
9
9
|
* License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License)
|
|
10
10
|
* Copyright 2025 Fonticons, Inc.
|
|
11
11
|
*/
|
|
12
|
-
function V(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,a=Array(t);n<t;n++)a[n]=e[n];return a}function H(e,t,n){return t&&function(e,t){for(var n=0;n<t.length;n++){var a=t[n];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,Z(a.key),a)}}(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function W(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=G(e))||t){n&&(e=n);var a=0,r=function(){};return{s:r,n:function(){return a>=e.length?{done:!0}:{done:!1,value:e[a++]}},e:function(e){throw e},f:r}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,i=!0,l=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return i=e.done,e},e:function(e){l=!0,o=e},f:function(){try{i||null==n.return||n.return()}finally{if(l)throw o}}}}function U(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,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,a)}return n}function Q(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?J(Object(n),!0).forEach(function(t){U(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):J(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function X(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a,r,o,i,l=[],s=!0,c=!1;try{if(o=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(a=o.call(n)).done)&&(l.push(a.value),l.length!==t);s=!0);}catch(e){c=!0,r=e}finally{try{if(!s&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw r}}return l}}(e,t)||G(e,t)||function(){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 Y(e){return function(e){if(Array.isArray(e))return V(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||G(e)||function(){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 Z(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var a=n.call(e,t);if("object"!=typeof a)return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}function q(e){return q="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},q(e)}function G(e,t){if(e){if("string"==typeof e)return V(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)?V(e,t):void 0}}var K=function(){},ee={},te={},ne=null,ae={mark:K,measure:K};try{"undefined"!=typeof window&&(ee=window),"undefined"!=typeof document&&(te=document),"undefined"!=typeof MutationObserver&&(ne=MutationObserver),"undefined"!=typeof performance&&(ae=performance)}catch(Me){}var re=(ee.navigator||{}).userAgent,oe=void 0===re?"":re,ie=ee,le=te,se=ne,ce=ae;ie.document;var fe,ue=!!le.documentElement&&!!le.head&&"function"==typeof le.addEventListener&&"function"==typeof le.createElement,de=~oe.indexOf("MSIE")||~oe.indexOf("Trident/"),he={classic:{fa:"solid",fas:"solid","fa-solid":"solid",far:"regular","fa-regular":"regular",fal:"light","fa-light":"light",fat:"thin","fa-thin":"thin",fab:"brands","fa-brands":"brands"},duotone:{fa:"solid",fad:"solid","fa-solid":"solid","fa-duotone":"solid",fadr:"regular","fa-regular":"regular",fadl:"light","fa-light":"light",fadt:"thin","fa-thin":"thin"},sharp:{fa:"solid",fass:"solid","fa-solid":"solid",fasr:"regular","fa-regular":"regular",fasl:"light","fa-light":"light",fast:"thin","fa-thin":"thin"},"sharp-duotone":{fa:"solid",fasds:"solid","fa-solid":"solid",fasdr:"regular","fa-regular":"regular",fasdl:"light","fa-light":"light",fasdt:"thin","fa-thin":"thin"},slab:{"fa-regular":"regular",faslr:"regular"},"slab-press":{"fa-regular":"regular",faslpr:"regular"},thumbprint:{"fa-light":"light",fatl:"light"},whiteboard:{"fa-semibold":"semibold",fawsb:"semibold"},notdog:{"fa-solid":"solid",fans:"solid"},"notdog-duo":{"fa-solid":"solid",fands:"solid"},etch:{"fa-solid":"solid",faes:"solid"},jelly:{"fa-regular":"regular",fajr:"regular"},"jelly-fill":{"fa-regular":"regular",fajfr:"regular"},"jelly-duo":{"fa-regular":"regular",fajdr:"regular"},chisel:{"fa-regular":"regular",facr:"regular"},utility:{"fa-semibold":"semibold",fausb:"semibold"},"utility-duo":{"fa-semibold":"semibold",faudsb:"semibold"},"utility-fill":{"fa-semibold":"semibold",faufsb:"semibold"}},me=["fa-classic","fa-duotone","fa-sharp","fa-sharp-duotone","fa-thumbprint","fa-whiteboard","fa-notdog","fa-notdog-duo","fa-chisel","fa-etch","fa-jelly","fa-jelly-fill","fa-jelly-duo","fa-slab","fa-slab-press","fa-utility","fa-utility-duo","fa-utility-fill"],pe="classic",ge="duotone",ve="sharp",be="sharp-duotone",ye="chisel",we="etch",xe="jelly",ke="jelly-duo",Ne="jelly-fill",Se="notdog",Te="notdog-duo",Ce="slab",_e="slab-press",Me="thumbprint",Re="utility",Pe="utility-duo",Fe="utility-fill",Ie="whiteboard",je=[pe,ge,ve,be,ye,we,xe,ke,Ne,Se,Te,Ce,_e,Me,Re,Pe,Fe,Ie];U(U(U(U(U(U(U(U(U(U(fe={},pe,"Classic"),ge,"Duotone"),ve,"Sharp"),be,"Sharp Duotone"),ye,"Chisel"),we,"Etch"),xe,"Jelly"),ke,"Jelly Duo"),Ne,"Jelly Fill"),Se,"Notdog"),U(U(U(U(U(U(U(U(fe,Te,"Notdog Duo"),Ce,"Slab"),_e,"Slab Press"),Me,"Thumbprint"),Re,"Utility"),Pe,"Utility Duo"),Fe,"Utility Fill"),Ie,"Whiteboard");var Ee=new Map([["classic",{defaultShortPrefixId:"fas",defaultStyleId:"solid",styleIds:["solid","regular","light","thin","brands"],futureStyleIds:[],defaultFontWeight:900}],["duotone",{defaultShortPrefixId:"fad",defaultStyleId:"solid",styleIds:["solid","regular","light","thin"],futureStyleIds:[],defaultFontWeight:900}],["sharp",{defaultShortPrefixId:"fass",defaultStyleId:"solid",styleIds:["solid","regular","light","thin"],futureStyleIds:[],defaultFontWeight:900}],["sharp-duotone",{defaultShortPrefixId:"fasds",defaultStyleId:"solid",styleIds:["solid","regular","light","thin"],futureStyleIds:[],defaultFontWeight:900}],["chisel",{defaultShortPrefixId:"facr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["etch",{defaultShortPrefixId:"faes",defaultStyleId:"solid",styleIds:["solid"],futureStyleIds:[],defaultFontWeight:900}],["jelly",{defaultShortPrefixId:"fajr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["jelly-duo",{defaultShortPrefixId:"fajdr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["jelly-fill",{defaultShortPrefixId:"fajfr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["notdog",{defaultShortPrefixId:"fans",defaultStyleId:"solid",styleIds:["solid"],futureStyleIds:[],defaultFontWeight:900}],["notdog-duo",{defaultShortPrefixId:"fands",defaultStyleId:"solid",styleIds:["solid"],futureStyleIds:[],defaultFontWeight:900}],["slab",{defaultShortPrefixId:"faslr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["slab-press",{defaultShortPrefixId:"faslpr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["thumbprint",{defaultShortPrefixId:"fatl",defaultStyleId:"light",styleIds:["light"],futureStyleIds:[],defaultFontWeight:300}],["utility",{defaultShortPrefixId:"fausb",defaultStyleId:"semibold",styleIds:["semibold"],futureStyleIds:[],defaultFontWeight:600}],["utility-duo",{defaultShortPrefixId:"faudsb",defaultStyleId:"semibold",styleIds:["semibold"],futureStyleIds:[],defaultFontWeight:600}],["utility-fill",{defaultShortPrefixId:"faufsb",defaultStyleId:"semibold",styleIds:["semibold"],futureStyleIds:[],defaultFontWeight:600}],["whiteboard",{defaultShortPrefixId:"fawsb",defaultStyleId:"semibold",styleIds:["semibold"],futureStyleIds:[],defaultFontWeight:600}]]),De=["fak","fa-kit","fakd","fa-kit-duotone"],Be={fak:"kit","fa-kit":"kit"},Le={fakd:"kit-duotone","fa-kit-duotone":"kit-duotone"};U(U({},"kit","Kit"),"kit-duotone","Kit Duotone");var Ae,Oe={kit:"fak"},ze={"kit-duotone":"fakd"},$e="duotone-group",Ve="swap-opacity",He="primary",We="secondary";U(U(U(U(U(U(U(U(U(U(Ae={},"classic","Classic"),"duotone","Duotone"),"sharp","Sharp"),"sharp-duotone","Sharp Duotone"),"chisel","Chisel"),"etch","Etch"),"jelly","Jelly"),"jelly-duo","Jelly Duo"),"jelly-fill","Jelly Fill"),"notdog","Notdog"),U(U(U(U(U(U(U(U(Ae,"notdog-duo","Notdog Duo"),"slab","Slab"),"slab-press","Slab Press"),"thumbprint","Thumbprint"),"utility","Utility"),"utility-duo","Utility Duo"),"utility-fill","Utility Fill"),"whiteboard","Whiteboard");U(U({},"kit","Kit"),"kit-duotone","Kit Duotone");var Ue={classic:{fab:"fa-brands",fad:"fa-duotone",fal:"fa-light",far:"fa-regular",fas:"fa-solid",fat:"fa-thin"},duotone:{fadr:"fa-regular",fadl:"fa-light",fadt:"fa-thin"},sharp:{fass:"fa-solid",fasr:"fa-regular",fasl:"fa-light",fast:"fa-thin"},"sharp-duotone":{fasds:"fa-solid",fasdr:"fa-regular",fasdl:"fa-light",fasdt:"fa-thin"},slab:{faslr:"fa-regular"},"slab-press":{faslpr:"fa-regular"},whiteboard:{fawsb:"fa-semibold"},thumbprint:{fatl:"fa-light"},notdog:{fans:"fa-solid"},"notdog-duo":{fands:"fa-solid"},etch:{faes:"fa-solid"},jelly:{fajr:"fa-regular"},"jelly-fill":{fajfr:"fa-regular"},"jelly-duo":{fajdr:"fa-regular"},chisel:{facr:"fa-regular"},utility:{fausb:"fa-semibold"},"utility-duo":{faudsb:"fa-semibold"},"utility-fill":{faufsb:"fa-semibold"}},Je=["fa","fas","far","fal","fat","fad","fadr","fadl","fadt","fab","fass","fasr","fasl","fast","fasds","fasdr","fasdl","fasdt","faslr","faslpr","fawsb","fatl","fans","fands","faes","fajr","fajfr","fajdr","facr","fausb","faudsb","faufsb"].concat(["fa-classic","fa-duotone","fa-sharp","fa-sharp-duotone","fa-thumbprint","fa-whiteboard","fa-notdog","fa-notdog-duo","fa-chisel","fa-etch","fa-jelly","fa-jelly-fill","fa-jelly-duo","fa-slab","fa-slab-press","fa-utility","fa-utility-duo","fa-utility-fill"],["fa-solid","fa-regular","fa-light","fa-thin","fa-duotone","fa-brands","fa-semibold"]),Qe=[1,2,3,4,5,6,7,8,9,10],Xe=Qe.concat([11,12,13,14,15,16,17,18,19,20]),Ye=[].concat(Y(Object.keys({classic:["fas","far","fal","fat","fad"],duotone:["fadr","fadl","fadt"],sharp:["fass","fasr","fasl","fast"],"sharp-duotone":["fasds","fasdr","fasdl","fasdt"],slab:["faslr"],"slab-press":["faslpr"],whiteboard:["fawsb"],thumbprint:["fatl"],notdog:["fans"],"notdog-duo":["fands"],etch:["faes"],jelly:["fajr"],"jelly-fill":["fajfr"],"jelly-duo":["fajdr"],chisel:["facr"],utility:["fausb"],"utility-duo":["faudsb"],"utility-fill":["faufsb"]})),["solid","regular","light","thin","duotone","brands","semibold"],["aw","fw","pull-left","pull-right"],["2xs","xs","sm","lg","xl","2xl","beat","border","fade","beat-fade","bounce","flip-both","flip-horizontal","flip-vertical","flip","inverse","layers","layers-bottom-left","layers-bottom-right","layers-counter","layers-text","layers-top-left","layers-top-right","li","pull-end","pull-start","pulse","rotate-180","rotate-270","rotate-90","rotate-by","shake","spin-pulse","spin-reverse","spin","stack-1x","stack-2x","stack","ul","width-auto","width-fixed",$e,Ve,He,We]).concat(Qe.map(function(e){return"".concat(e,"x")})).concat(Xe.map(function(e){return"w-".concat(e)})),Ze="___FONT_AWESOME___",qe="svg-inline--fa",Ge="data-fa-i2svg",Ke="data-fa-pseudo-element",et="data-prefix",tt="data-icon",nt="fontawesome-i2svg",at=["HTML","HEAD","STYLE","SCRIPT"],rt=["::before","::after",":before",":after"],ot=function(){try{return"production"===process.env.NODE_ENV}catch(e){return!1}}();function it(e){return new Proxy(e,{get:function(e,t){return t in e?e[t]:e[pe]}})}var lt=Q({},he);lt[pe]=Q(Q(Q(Q({},{"fa-duotone":"duotone"}),he[pe]),Be),Le);var st=it(lt),ct=Q({},{chisel:{regular:"facr"},classic:{brands:"fab",light:"fal",regular:"far",solid:"fas",thin:"fat"},duotone:{light:"fadl",regular:"fadr",solid:"fad",thin:"fadt"},etch:{solid:"faes"},jelly:{regular:"fajr"},"jelly-duo":{regular:"fajdr"},"jelly-fill":{regular:"fajfr"},notdog:{solid:"fans"},"notdog-duo":{solid:"fands"},sharp:{light:"fasl",regular:"fasr",solid:"fass",thin:"fast"},"sharp-duotone":{light:"fasdl",regular:"fasdr",solid:"fasds",thin:"fasdt"},slab:{regular:"faslr"},"slab-press":{regular:"faslpr"},thumbprint:{light:"fatl"},utility:{semibold:"fausb"},"utility-duo":{semibold:"faudsb"},"utility-fill":{semibold:"faufsb"},whiteboard:{semibold:"fawsb"}});ct[pe]=Q(Q(Q(Q({},{duotone:"fad"}),ct[pe]),Oe),ze);var ft=it(ct),ut=Q({},Ue);ut[pe]=Q(Q({},ut[pe]),{fak:"fa-kit"});var dt=it(ut),ht=Q({},{classic:{"fa-brands":"fab","fa-duotone":"fad","fa-light":"fal","fa-regular":"far","fa-solid":"fas","fa-thin":"fat"},duotone:{"fa-regular":"fadr","fa-light":"fadl","fa-thin":"fadt"},sharp:{"fa-solid":"fass","fa-regular":"fasr","fa-light":"fasl","fa-thin":"fast"},"sharp-duotone":{"fa-solid":"fasds","fa-regular":"fasdr","fa-light":"fasdl","fa-thin":"fasdt"},slab:{"fa-regular":"faslr"},"slab-press":{"fa-regular":"faslpr"},whiteboard:{"fa-semibold":"fawsb"},thumbprint:{"fa-light":"fatl"},notdog:{"fa-solid":"fans"},"notdog-duo":{"fa-solid":"fands"},etch:{"fa-solid":"faes"},jelly:{"fa-regular":"fajr"},"jelly-fill":{"fa-regular":"fajfr"},"jelly-duo":{"fa-regular":"fajdr"},chisel:{"fa-regular":"facr"},utility:{"fa-semibold":"fausb"},"utility-duo":{"fa-semibold":"faudsb"},"utility-fill":{"fa-semibold":"faufsb"}});ht[pe]=Q(Q({},ht[pe]),{"fa-kit":"fak"}),it(ht);var mt=/fa(k|kd|s|r|l|t|d|dr|dl|dt|b|slr|slpr|wsb|tl|ns|nds|es|jr|jfr|jdr|usb|ufsb|udsb|cr|ss|sr|sl|st|sds|sdr|sdl|sdt)?[\-\ ]/,pt="fa-layers-text",gt=/Font ?Awesome ?([567 ]*)(Solid|Regular|Light|Thin|Duotone|Brands|Free|Pro|Sharp Duotone|Sharp|Kit|Notdog Duo|Notdog|Chisel|Etch|Thumbprint|Jelly Fill|Jelly Duo|Jelly|Utility|Utility Fill|Utility Duo|Slab Press|Slab|Whiteboard)?.*/i;it(Q({},{classic:{900:"fas",400:"far",normal:"far",300:"fal",100:"fat"},duotone:{900:"fad",400:"fadr",300:"fadl",100:"fadt"},sharp:{900:"fass",400:"fasr",300:"fasl",100:"fast"},"sharp-duotone":{900:"fasds",400:"fasdr",300:"fasdl",100:"fasdt"},slab:{400:"faslr"},"slab-press":{400:"faslpr"},whiteboard:{600:"fawsb"},thumbprint:{300:"fatl"},notdog:{900:"fans"},"notdog-duo":{900:"fands"},etch:{900:"faes"},chisel:{400:"facr"},jelly:{400:"fajr"},"jelly-fill":{400:"fajfr"},"jelly-duo":{400:"fajdr"},utility:{600:"fausb"},"utility-duo":{600:"faudsb"},"utility-fill":{600:"faufsb"}}));var vt=["class","data-prefix","data-icon","data-fa-transform","data-fa-mask"],bt={GROUP:"duotone-group",PRIMARY:"primary",SECONDARY:"secondary"},yt=[].concat(Y(["kit"]),Y(Ye)),wt=ie.FontAwesomeConfig||{};if(le&&"function"==typeof le.querySelector){[["data-family-prefix","familyPrefix"],["data-css-prefix","cssPrefix"],["data-family-default","familyDefault"],["data-style-default","styleDefault"],["data-replacement-class","replacementClass"],["data-auto-replace-svg","autoReplaceSvg"],["data-auto-add-css","autoAddCss"],["data-search-pseudo-elements","searchPseudoElements"],["data-search-pseudo-elements-warnings","searchPseudoElementsWarnings"],["data-search-pseudo-elements-full-scan","searchPseudoElementsFullScan"],["data-observe-mutations","observeMutations"],["data-mutate-approach","mutateApproach"],["data-keep-original-source","keepOriginalSource"],["data-measure-performance","measurePerformance"],["data-show-missing-icons","showMissingIcons"]].forEach(function(e){var t=X(e,2),n=t[0],a=t[1],r=function(e){return""===e||"false"!==e&&("true"===e||e)}(function(e){var t=le.querySelector("script["+e+"]");if(t)return t.getAttribute(e)}(n));null!=r&&(wt[a]=r)})}var xt={styleDefault:"solid",familyDefault:pe,cssPrefix:"fa",replacementClass:qe,autoReplaceSvg:!0,autoAddCss:!0,searchPseudoElements:!1,searchPseudoElementsWarnings:!0,searchPseudoElementsFullScan:!1,observeMutations:!0,mutateApproach:"async",keepOriginalSource:!0,measurePerformance:!1,showMissingIcons:!0};wt.familyPrefix&&(wt.cssPrefix=wt.familyPrefix);var kt=Q(Q({},xt),wt);kt.autoReplaceSvg||(kt.observeMutations=!1);var Nt={};Object.keys(xt).forEach(function(e){Object.defineProperty(Nt,e,{enumerable:!0,set:function(t){kt[e]=t,St.forEach(function(e){return e(Nt)})},get:function(){return kt[e]}})}),Object.defineProperty(Nt,"familyPrefix",{enumerable:!0,set:function(e){kt.cssPrefix=e,St.forEach(function(e){return e(Nt)})},get:function(){return kt.cssPrefix}}),ie.FontAwesomeConfig=Nt;var St=[];var Tt=16,Ct={size:16,x:0,y:0,rotate:0,flipX:!1,flipY:!1};function _t(){for(var e=12,t="";e-- >0;)t+="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"[62*Math.random()|0];return t}function Mt(e){for(var t=[],n=(e||[]).length>>>0;n--;)t[n]=e[n];return t}function Rt(e){return e.classList?Mt(e.classList):(e.getAttribute("class")||"").split(" ").filter(function(e){return e})}function Pt(e){return"".concat(e).replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(/</g,"<").replace(/>/g,">")}function Ft(e){return Object.keys(e||{}).reduce(function(t,n){return t+"".concat(n,": ").concat(e[n].trim(),";")},"")}function It(e){return e.size!==Ct.size||e.x!==Ct.x||e.y!==Ct.y||e.rotate!==Ct.rotate||e.flipX||e.flipY}function jt(){var e="fa",t=qe,n=Nt.cssPrefix,a=Nt.replacementClass,r=':root, :host {\n --fa-font-solid: normal 900 1em/1 "Font Awesome 7 Free";\n --fa-font-regular: normal 400 1em/1 "Font Awesome 7 Free";\n --fa-font-light: normal 300 1em/1 "Font Awesome 7 Pro";\n --fa-font-thin: normal 100 1em/1 "Font Awesome 7 Pro";\n --fa-font-duotone: normal 900 1em/1 "Font Awesome 7 Duotone";\n --fa-font-duotone-regular: normal 400 1em/1 "Font Awesome 7 Duotone";\n --fa-font-duotone-light: normal 300 1em/1 "Font Awesome 7 Duotone";\n --fa-font-duotone-thin: normal 100 1em/1 "Font Awesome 7 Duotone";\n --fa-font-brands: normal 400 1em/1 "Font Awesome 7 Brands";\n --fa-font-sharp-solid: normal 900 1em/1 "Font Awesome 7 Sharp";\n --fa-font-sharp-regular: normal 400 1em/1 "Font Awesome 7 Sharp";\n --fa-font-sharp-light: normal 300 1em/1 "Font Awesome 7 Sharp";\n --fa-font-sharp-thin: normal 100 1em/1 "Font Awesome 7 Sharp";\n --fa-font-sharp-duotone-solid: normal 900 1em/1 "Font Awesome 7 Sharp Duotone";\n --fa-font-sharp-duotone-regular: normal 400 1em/1 "Font Awesome 7 Sharp Duotone";\n --fa-font-sharp-duotone-light: normal 300 1em/1 "Font Awesome 7 Sharp Duotone";\n --fa-font-sharp-duotone-thin: normal 100 1em/1 "Font Awesome 7 Sharp Duotone";\n --fa-font-slab-regular: normal 400 1em/1 "Font Awesome 7 Slab";\n --fa-font-slab-press-regular: normal 400 1em/1 "Font Awesome 7 Slab Press";\n --fa-font-whiteboard-semibold: normal 600 1em/1 "Font Awesome 7 Whiteboard";\n --fa-font-thumbprint-light: normal 300 1em/1 "Font Awesome 7 Thumbprint";\n --fa-font-notdog-solid: normal 900 1em/1 "Font Awesome 7 Notdog";\n --fa-font-notdog-duo-solid: normal 900 1em/1 "Font Awesome 7 Notdog Duo";\n --fa-font-etch-solid: normal 900 1em/1 "Font Awesome 7 Etch";\n --fa-font-jelly-regular: normal 400 1em/1 "Font Awesome 7 Jelly";\n --fa-font-jelly-fill-regular: normal 400 1em/1 "Font Awesome 7 Jelly Fill";\n --fa-font-jelly-duo-regular: normal 400 1em/1 "Font Awesome 7 Jelly Duo";\n --fa-font-chisel-regular: normal 400 1em/1 "Font Awesome 7 Chisel";\n --fa-font-utility-semibold: normal 600 1em/1 "Font Awesome 7 Utility";\n --fa-font-utility-duo-semibold: normal 600 1em/1 "Font Awesome 7 Utility Duo";\n --fa-font-utility-fill-semibold: normal 600 1em/1 "Font Awesome 7 Utility Fill";\n}\n\n.svg-inline--fa {\n box-sizing: content-box;\n display: var(--fa-display, inline-block);\n height: 1em;\n overflow: visible;\n vertical-align: -0.125em;\n width: var(--fa-width, 1.25em);\n}\n.svg-inline--fa.fa-2xs {\n vertical-align: 0.1em;\n}\n.svg-inline--fa.fa-xs {\n vertical-align: 0em;\n}\n.svg-inline--fa.fa-sm {\n vertical-align: -0.0714285714em;\n}\n.svg-inline--fa.fa-lg {\n vertical-align: -0.2em;\n}\n.svg-inline--fa.fa-xl {\n vertical-align: -0.25em;\n}\n.svg-inline--fa.fa-2xl {\n vertical-align: -0.3125em;\n}\n.svg-inline--fa.fa-pull-left,\n.svg-inline--fa .fa-pull-start {\n float: inline-start;\n margin-inline-end: var(--fa-pull-margin, 0.3em);\n}\n.svg-inline--fa.fa-pull-right,\n.svg-inline--fa .fa-pull-end {\n float: inline-end;\n margin-inline-start: var(--fa-pull-margin, 0.3em);\n}\n.svg-inline--fa.fa-li {\n width: var(--fa-li-width, 2em);\n inset-inline-start: calc(-1 * var(--fa-li-width, 2em));\n inset-block-start: 0.25em; /* syncing vertical alignment with Web Font rendering */\n}\n\n.fa-layers-counter, .fa-layers-text {\n display: inline-block;\n position: absolute;\n text-align: center;\n}\n\n.fa-layers {\n display: inline-block;\n height: 1em;\n position: relative;\n text-align: center;\n vertical-align: -0.125em;\n width: var(--fa-width, 1.25em);\n}\n.fa-layers .svg-inline--fa {\n inset: 0;\n margin: auto;\n position: absolute;\n transform-origin: center center;\n}\n\n.fa-layers-text {\n left: 50%;\n top: 50%;\n transform: translate(-50%, -50%);\n transform-origin: center center;\n}\n\n.fa-layers-counter {\n background-color: var(--fa-counter-background-color, #ff253a);\n border-radius: var(--fa-counter-border-radius, 1em);\n box-sizing: border-box;\n color: var(--fa-inverse, #fff);\n line-height: var(--fa-counter-line-height, 1);\n max-width: var(--fa-counter-max-width, 5em);\n min-width: var(--fa-counter-min-width, 1.5em);\n overflow: hidden;\n padding: var(--fa-counter-padding, 0.25em 0.5em);\n right: var(--fa-right, 0);\n text-overflow: ellipsis;\n top: var(--fa-top, 0);\n transform: scale(var(--fa-counter-scale, 0.25));\n transform-origin: top right;\n}\n\n.fa-layers-bottom-right {\n bottom: var(--fa-bottom, 0);\n right: var(--fa-right, 0);\n top: auto;\n transform: scale(var(--fa-layers-scale, 0.25));\n transform-origin: bottom right;\n}\n\n.fa-layers-bottom-left {\n bottom: var(--fa-bottom, 0);\n left: var(--fa-left, 0);\n right: auto;\n top: auto;\n transform: scale(var(--fa-layers-scale, 0.25));\n transform-origin: bottom left;\n}\n\n.fa-layers-top-right {\n top: var(--fa-top, 0);\n right: var(--fa-right, 0);\n transform: scale(var(--fa-layers-scale, 0.25));\n transform-origin: top right;\n}\n\n.fa-layers-top-left {\n left: var(--fa-left, 0);\n right: auto;\n top: var(--fa-top, 0);\n transform: scale(var(--fa-layers-scale, 0.25));\n transform-origin: top left;\n}\n\n.fa-1x {\n font-size: 1em;\n}\n\n.fa-2x {\n font-size: 2em;\n}\n\n.fa-3x {\n font-size: 3em;\n}\n\n.fa-4x {\n font-size: 4em;\n}\n\n.fa-5x {\n font-size: 5em;\n}\n\n.fa-6x {\n font-size: 6em;\n}\n\n.fa-7x {\n font-size: 7em;\n}\n\n.fa-8x {\n font-size: 8em;\n}\n\n.fa-9x {\n font-size: 9em;\n}\n\n.fa-10x {\n font-size: 10em;\n}\n\n.fa-2xs {\n font-size: calc(10 / 16 * 1em); /* converts a 10px size into an em-based value that\'s relative to the scale\'s 16px base */\n line-height: calc(1 / 10 * 1em); /* sets the line-height of the icon back to that of it\'s parent */\n vertical-align: calc((6 / 10 - 0.375) * 1em); /* vertically centers the icon taking into account the surrounding text\'s descender */\n}\n\n.fa-xs {\n font-size: calc(12 / 16 * 1em); /* converts a 12px size into an em-based value that\'s relative to the scale\'s 16px base */\n line-height: calc(1 / 12 * 1em); /* sets the line-height of the icon back to that of it\'s parent */\n vertical-align: calc((6 / 12 - 0.375) * 1em); /* vertically centers the icon taking into account the surrounding text\'s descender */\n}\n\n.fa-sm {\n font-size: calc(14 / 16 * 1em); /* converts a 14px size into an em-based value that\'s relative to the scale\'s 16px base */\n line-height: calc(1 / 14 * 1em); /* sets the line-height of the icon back to that of it\'s parent */\n vertical-align: calc((6 / 14 - 0.375) * 1em); /* vertically centers the icon taking into account the surrounding text\'s descender */\n}\n\n.fa-lg {\n font-size: calc(20 / 16 * 1em); /* converts a 20px size into an em-based value that\'s relative to the scale\'s 16px base */\n line-height: calc(1 / 20 * 1em); /* sets the line-height of the icon back to that of it\'s parent */\n vertical-align: calc((6 / 20 - 0.375) * 1em); /* vertically centers the icon taking into account the surrounding text\'s descender */\n}\n\n.fa-xl {\n font-size: calc(24 / 16 * 1em); /* converts a 24px size into an em-based value that\'s relative to the scale\'s 16px base */\n line-height: calc(1 / 24 * 1em); /* sets the line-height of the icon back to that of it\'s parent */\n vertical-align: calc((6 / 24 - 0.375) * 1em); /* vertically centers the icon taking into account the surrounding text\'s descender */\n}\n\n.fa-2xl {\n font-size: calc(32 / 16 * 1em); /* converts a 32px size into an em-based value that\'s relative to the scale\'s 16px base */\n line-height: calc(1 / 32 * 1em); /* sets the line-height of the icon back to that of it\'s parent */\n vertical-align: calc((6 / 32 - 0.375) * 1em); /* vertically centers the icon taking into account the surrounding text\'s descender */\n}\n\n.fa-width-auto {\n --fa-width: auto;\n}\n\n.fa-fw,\n.fa-width-fixed {\n --fa-width: 1.25em;\n}\n\n.fa-ul {\n list-style-type: none;\n margin-inline-start: var(--fa-li-margin, 2.5em);\n padding-inline-start: 0;\n}\n.fa-ul > li {\n position: relative;\n}\n\n.fa-li {\n inset-inline-start: calc(-1 * var(--fa-li-width, 2em));\n position: absolute;\n text-align: center;\n width: var(--fa-li-width, 2em);\n line-height: inherit;\n}\n\n/* Heads Up: Bordered Icons will not be supported in the future!\n - This feature will be deprecated in the next major release of Font Awesome (v8)!\n - You may continue to use it in this version *v7), but it will not be supported in Font Awesome v8.\n*/\n/* Notes:\n* --@{v.$css-prefix}-border-width = 1/16 by default (to render as ~1px based on a 16px default font-size)\n* --@{v.$css-prefix}-border-padding =\n ** 3/16 for vertical padding (to give ~2px of vertical whitespace around an icon considering it\'s vertical alignment)\n ** 4/16 for horizontal padding (to give ~4px of horizontal whitespace around an icon)\n*/\n.fa-border {\n border-color: var(--fa-border-color, #eee);\n border-radius: var(--fa-border-radius, 0.1em);\n border-style: var(--fa-border-style, solid);\n border-width: var(--fa-border-width, 0.0625em);\n box-sizing: var(--fa-border-box-sizing, content-box);\n padding: var(--fa-border-padding, 0.1875em 0.25em);\n}\n\n.fa-pull-left,\n.fa-pull-start {\n float: inline-start;\n margin-inline-end: var(--fa-pull-margin, 0.3em);\n}\n\n.fa-pull-right,\n.fa-pull-end {\n float: inline-end;\n margin-inline-start: var(--fa-pull-margin, 0.3em);\n}\n\n.fa-beat {\n animation-name: fa-beat;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, ease-in-out);\n}\n\n.fa-bounce {\n animation-name: fa-bounce;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.28, 0.84, 0.42, 1));\n}\n\n.fa-fade {\n animation-name: fa-fade;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1));\n}\n\n.fa-beat-fade {\n animation-name: fa-beat-fade;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1));\n}\n\n.fa-flip {\n animation-name: fa-flip;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, ease-in-out);\n}\n\n.fa-shake {\n animation-name: fa-shake;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, linear);\n}\n\n.fa-spin {\n animation-name: fa-spin;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 2s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, linear);\n}\n\n.fa-spin-reverse {\n --fa-animation-direction: reverse;\n}\n\n.fa-pulse,\n.fa-spin-pulse {\n animation-name: fa-spin;\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, steps(8));\n}\n\n@media (prefers-reduced-motion: reduce) {\n .fa-beat,\n .fa-bounce,\n .fa-fade,\n .fa-beat-fade,\n .fa-flip,\n .fa-pulse,\n .fa-shake,\n .fa-spin,\n .fa-spin-pulse {\n animation: none !important;\n transition: none !important;\n }\n}\n@keyframes fa-beat {\n 0%, 90% {\n transform: scale(1);\n }\n 45% {\n transform: scale(var(--fa-beat-scale, 1.25));\n }\n}\n@keyframes fa-bounce {\n 0% {\n transform: scale(1, 1) translateY(0);\n }\n 10% {\n transform: scale(var(--fa-bounce-start-scale-x, 1.1), var(--fa-bounce-start-scale-y, 0.9)) translateY(0);\n }\n 30% {\n transform: scale(var(--fa-bounce-jump-scale-x, 0.9), var(--fa-bounce-jump-scale-y, 1.1)) translateY(var(--fa-bounce-height, -0.5em));\n }\n 50% {\n transform: scale(var(--fa-bounce-land-scale-x, 1.05), var(--fa-bounce-land-scale-y, 0.95)) translateY(0);\n }\n 57% {\n transform: scale(1, 1) translateY(var(--fa-bounce-rebound, -0.125em));\n }\n 64% {\n transform: scale(1, 1) translateY(0);\n }\n 100% {\n transform: scale(1, 1) translateY(0);\n }\n}\n@keyframes fa-fade {\n 50% {\n opacity: var(--fa-fade-opacity, 0.4);\n }\n}\n@keyframes fa-beat-fade {\n 0%, 100% {\n opacity: var(--fa-beat-fade-opacity, 0.4);\n transform: scale(1);\n }\n 50% {\n opacity: 1;\n transform: scale(var(--fa-beat-fade-scale, 1.125));\n }\n}\n@keyframes fa-flip {\n 50% {\n transform: rotate3d(var(--fa-flip-x, 0), var(--fa-flip-y, 1), var(--fa-flip-z, 0), var(--fa-flip-angle, -180deg));\n }\n}\n@keyframes fa-shake {\n 0% {\n transform: rotate(-15deg);\n }\n 4% {\n transform: rotate(15deg);\n }\n 8%, 24% {\n transform: rotate(-18deg);\n }\n 12%, 28% {\n transform: rotate(18deg);\n }\n 16% {\n transform: rotate(-22deg);\n }\n 20% {\n transform: rotate(22deg);\n }\n 32% {\n transform: rotate(-12deg);\n }\n 36% {\n transform: rotate(12deg);\n }\n 40%, 100% {\n transform: rotate(0deg);\n }\n}\n@keyframes fa-spin {\n 0% {\n transform: rotate(0deg);\n }\n 100% {\n transform: rotate(360deg);\n }\n}\n.fa-rotate-90 {\n transform: rotate(90deg);\n}\n\n.fa-rotate-180 {\n transform: rotate(180deg);\n}\n\n.fa-rotate-270 {\n transform: rotate(270deg);\n}\n\n.fa-flip-horizontal {\n transform: scale(-1, 1);\n}\n\n.fa-flip-vertical {\n transform: scale(1, -1);\n}\n\n.fa-flip-both,\n.fa-flip-horizontal.fa-flip-vertical {\n transform: scale(-1, -1);\n}\n\n.fa-rotate-by {\n transform: rotate(var(--fa-rotate-angle, 0));\n}\n\n.svg-inline--fa .fa-primary {\n fill: var(--fa-primary-color, currentColor);\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa .fa-secondary {\n fill: var(--fa-secondary-color, currentColor);\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-primary {\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-secondary {\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa mask .fa-primary,\n.svg-inline--fa mask .fa-secondary {\n fill: black;\n}\n\n.svg-inline--fa.fa-inverse {\n fill: var(--fa-inverse, #fff);\n}\n\n.fa-stack {\n display: inline-block;\n height: 2em;\n line-height: 2em;\n position: relative;\n vertical-align: middle;\n width: 2.5em;\n}\n\n.fa-inverse {\n color: var(--fa-inverse, #fff);\n}\n\n.svg-inline--fa.fa-stack-1x {\n --fa-width: 1.25em;\n height: 1em;\n width: var(--fa-width);\n}\n.svg-inline--fa.fa-stack-2x {\n --fa-width: 2.5em;\n height: 2em;\n width: var(--fa-width);\n}\n\n.fa-stack-1x,\n.fa-stack-2x {\n inset: 0;\n margin: auto;\n position: absolute;\n z-index: var(--fa-stack-z-index, auto);\n}';if(n!==e||a!==t){var o=new RegExp("\\.".concat(e,"\\-"),"g"),i=new RegExp("\\--".concat(e,"\\-"),"g"),l=new RegExp("\\.".concat(t),"g");r=r.replace(o,".".concat(n,"-")).replace(i,"--".concat(n,"-")).replace(l,".".concat(a))}return r}var Et=!1;function Dt(){Nt.autoAddCss&&!Et&&(!function(e){if(e&&ue){var t=le.createElement("style");t.setAttribute("type","text/css"),t.innerHTML=e;for(var n=le.head.childNodes,a=null,r=n.length-1;r>-1;r--){var o=n[r],i=(o.tagName||"").toUpperCase();["STYLE","LINK"].indexOf(i)>-1&&(a=o)}le.head.insertBefore(t,a)}}(jt()),Et=!0)}var Bt={mixout:function(){return{dom:{css:jt,insertCss:Dt}}},hooks:function(){return{beforeDOMElementCreation:function(){Dt()},beforeI2svg:function(){Dt()}}}},Lt=ie||{};Lt[Ze]||(Lt[Ze]={}),Lt[Ze].styles||(Lt[Ze].styles={}),Lt[Ze].hooks||(Lt[Ze].hooks={}),Lt[Ze].shims||(Lt[Ze].shims=[]);var At=Lt[Ze],Ot=[],zt=function(){le.removeEventListener("DOMContentLoaded",zt),$t=1,Ot.map(function(e){return e()})},$t=!1;function Vt(e){var t=e.tag,n=e.attributes,a=void 0===n?{}:n,r=e.children,o=void 0===r?[]:r;return"string"==typeof e?Pt(e):"<".concat(t," ").concat(function(e){return Object.keys(e||{}).reduce(function(t,n){return t+"".concat(n,'="').concat(Pt(e[n]),'" ')},"").trim()}(a),">").concat(o.map(Vt).join(""),"</").concat(t,">")}function Ht(e,t,n){if(e&&e[t]&&e[t][n])return{prefix:t,iconName:n,icon:e[t][n]}}ue&&(($t=(le.documentElement.doScroll?/^loaded|^c/:/^loaded|^i|^c/).test(le.readyState))||le.addEventListener("DOMContentLoaded",zt));var Wt=function(e,t,n,a){var r,o,i,l=Object.keys(e),s=l.length,c=t;for(void 0===n?(r=1,i=e[l[0]]):(r=0,i=n);r<s;r++)i=c(i,e[o=l[r]],o,e);return i};function Ut(e){return 1!==Y(e).length?null:e.codePointAt(0).toString(16)}function Jt(e){return Object.keys(e).reduce(function(t,n){var a=e[n];return!!a.icon?t[a.iconName]=a.icon:t[n]=a,t},{})}function Qt(e,t){var n=(arguments.length>2&&void 0!==arguments[2]?arguments[2]:{}).skipHooks,a=void 0!==n&&n,r=Jt(t);"function"!=typeof At.hooks.addPack||a?At.styles[e]=Q(Q({},At.styles[e]||{}),r):At.hooks.addPack(e,Jt(t)),"fas"===e&&Qt("fa",t)}var Xt=At.styles,Yt=At.shims,Zt=Object.keys(dt),qt=Zt.reduce(function(e,t){return e[t]=Object.keys(dt[t]),e},{}),Gt=null,Kt={},en={},tn={},nn={},an={};function rn(e,t){var n,a=t.split("-"),r=a[0],o=a.slice(1).join("-");return r!==e||""===o||(n=o,~yt.indexOf(n))?null:o}var on,ln=function(){var e=function(e){return Wt(Xt,function(t,n,a){return t[a]=Wt(n,e,{}),t},{})};Kt=e(function(e,t,n){(t[3]&&(e[t[3]]=n),t[2])&&t[2].filter(function(e){return"number"==typeof e}).forEach(function(t){e[t.toString(16)]=n});return e}),en=e(function(e,t,n){(e[n]=n,t[2])&&t[2].filter(function(e){return"string"==typeof e}).forEach(function(t){e[t]=n});return e}),an=e(function(e,t,n){var a=t[2];return e[n]=n,a.forEach(function(t){e[t]=n}),e});var t="far"in Xt||Nt.autoFetchSvg,n=Wt(Yt,function(e,n){var a=n[0],r=n[1],o=n[2];return"far"!==r||t||(r="fas"),"string"==typeof a&&(e.names[a]={prefix:r,iconName:o}),"number"==typeof a&&(e.unicodes[a.toString(16)]={prefix:r,iconName:o}),e},{names:{},unicodes:{}});tn=n.names,nn=n.unicodes,Gt=dn(Nt.styleDefault,{family:Nt.familyDefault})};function sn(e,t){return(Kt[e]||{})[t]}function cn(e,t){return(an[e]||{})[t]}function fn(e){return tn[e]||{prefix:null,iconName:null}}function un(){return Gt}on=function(e){Gt=dn(e.styleDefault,{family:Nt.familyDefault})},St.push(on),ln();function dn(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).family,n=void 0===t?pe:t,a=st[n][e];if(n===ge&&!e)return"fad";var r=ft[n][e]||ft[n][a],o=e in At.styles?e:null;return r||o||null}function hn(e){return e.sort().filter(function(e,t,n){return n.indexOf(e)===t})}var mn=Je.concat(De);function pn(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).skipLookups,n=void 0!==t&&t,a=null,r=hn(e.filter(function(e){return mn.includes(e)})),o=hn(e.filter(function(e){return!mn.includes(e)})),i=X(r.filter(function(e){return a=e,!me.includes(e)}),1)[0],l=void 0===i?null:i,s=function(e){var t=pe,n=Zt.reduce(function(e,t){return e[t]="".concat(Nt.cssPrefix,"-").concat(t),e},{});return je.forEach(function(a){(e.includes(n[a])||e.some(function(e){return qt[a].includes(e)}))&&(t=a)}),t}(r),c=Q(Q({},function(e){var t=[],n=null;return e.forEach(function(e){var a=rn(Nt.cssPrefix,e);a?n=a:e&&t.push(e)}),{iconName:n,rest:t}}(o)),{},{prefix:dn(l,{family:s})});return Q(Q(Q({},c),function(e){var t=e.values,n=e.family,a=e.canonical,r=e.givenPrefix,o=void 0===r?"":r,i=e.styles,l=void 0===i?{}:i,s=e.config,c=void 0===s?{}:s,f=n===ge,u=t.includes("fa-duotone")||t.includes("fad"),d="duotone"===c.familyDefault,h="fad"===a.prefix||"fa-duotone"===a.prefix;!f&&(u||d||h)&&(a.prefix="fad");(t.includes("fa-brands")||t.includes("fab"))&&(a.prefix="fab");if(!a.prefix&&gn.includes(n)){if(Object.keys(l).find(function(e){return vn.includes(e)})||c.autoFetchSvg){var m=Ee.get(n).defaultShortPrefixId;a.prefix=m,a.iconName=cn(a.prefix,a.iconName)||a.iconName}}"fa"!==a.prefix&&"fa"!==o||(a.prefix=un()||"fas");return a}({values:e,family:s,styles:Xt,config:Nt,canonical:c,givenPrefix:a})),function(e,t,n){var a=n.prefix,r=n.iconName;if(e||!a||!r)return{prefix:a,iconName:r};var o="fa"===t?fn(r):{},i=cn(a,r);r=o.iconName||i||r,"far"!==(a=o.prefix||a)||Xt.far||!Xt.fas||Nt.autoFetchSvg||(a="fas");return{prefix:a,iconName:r}}(n,a,c))}var gn=je.filter(function(e){return e!==pe||e!==ge}),vn=Object.keys(Ue).filter(function(e){return e!==pe}).map(function(e){return Object.keys(Ue[e])}).flat();var bn=function(){return H(function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.definitions={}},[{key:"add",value:function(){for(var e=this,t=arguments.length,n=new Array(t),a=0;a<t;a++)n[a]=arguments[a];var r=n.reduce(this._pullDefinitions,{});Object.keys(r).forEach(function(t){e.definitions[t]=Q(Q({},e.definitions[t]||{}),r[t]),Qt(t,r[t]);var n=dt[pe][t];n&&Qt(n,r[t]),ln()})}},{key:"reset",value:function(){this.definitions={}}},{key:"_pullDefinitions",value:function(e,t){var n=t.prefix&&t.iconName&&t.icon?{0:t}:t;return Object.keys(n).map(function(t){var a=n[t],r=a.prefix,o=a.iconName,i=a.icon,l=i[2];e[r]||(e[r]={}),l.length>0&&l.forEach(function(t){"string"==typeof t&&(e[r][t]=i)}),e[r][o]=i}),e}}])}(),yn=[],wn={},xn={},kn=Object.keys(xn);function Nn(e,t){for(var n=arguments.length,a=new Array(n>2?n-2:0),r=2;r<n;r++)a[r-2]=arguments[r];return(wn[e]||[]).forEach(function(e){t=e.apply(null,[t].concat(a))}),t}function Sn(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),a=1;a<t;a++)n[a-1]=arguments[a];(wn[e]||[]).forEach(function(e){e.apply(null,n)})}function Tn(){var e=arguments[0],t=Array.prototype.slice.call(arguments,1);return xn[e]?xn[e].apply(null,t):void 0}function Cn(e){"fa"===e.prefix&&(e.prefix="fas");var t=e.iconName,n=e.prefix||un();if(t)return t=cn(n,t)||t,Ht(_n.definitions,n,t)||Ht(At.styles,n,t)}var _n=new bn,Mn={i2svg:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return ue?(Sn("beforeI2svg",e),Tn("pseudoElements2svg",e),Tn("i2svg",e)):Promise.reject(new Error("Operation requires a DOM of some kind."))},watch:function(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=t.autoReplaceSvgRoot;!1===Nt.autoReplaceSvg&&(Nt.autoReplaceSvg=!0),Nt.observeMutations=!0,e=function(){Pn({autoReplaceSvgRoot:n}),Sn("watch",t)},ue&&($t?setTimeout(e,0):Ot.push(e))}},Rn={noAuto:function(){Nt.autoReplaceSvg=!1,Nt.observeMutations=!1,Sn("noAuto")},config:Nt,dom:Mn,parse:{icon:function(e){if(null===e)return null;if("object"===q(e)&&e.prefix&&e.iconName)return{prefix:e.prefix,iconName:cn(e.prefix,e.iconName)||e.iconName};if(Array.isArray(e)&&2===e.length){var t=0===e[1].indexOf("fa-")?e[1].slice(3):e[1],n=dn(e[0]);return{prefix:n,iconName:cn(n,t)||t}}if("string"==typeof e&&(e.indexOf("".concat(Nt.cssPrefix,"-"))>-1||e.match(mt))){var a=pn(e.split(" "),{skipLookups:!0});return{prefix:a.prefix||un(),iconName:cn(a.prefix,a.iconName)||a.iconName}}if("string"==typeof e){var r=un();return{prefix:r,iconName:cn(r,e)||e}}}},library:_n,findIconDefinition:Cn,toHtml:Vt},Pn=function(){var e=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}).autoReplaceSvgRoot,t=void 0===e?le:e;(Object.keys(At.styles).length>0||Nt.autoFetchSvg)&&ue&&Nt.autoReplaceSvg&&Rn.dom.i2svg({node:t})};function Fn(e,t){return Object.defineProperty(e,"abstract",{get:t}),Object.defineProperty(e,"html",{get:function(){return e.abstract.map(function(e){return Vt(e)})}}),Object.defineProperty(e,"node",{get:function(){if(ue){var t=le.createElement("div");return t.innerHTML=e.html,t.children}}}),e}function In(e){var t=e.icons,n=t.main,a=t.mask,r=e.prefix,o=e.iconName,i=e.transform,l=e.symbol,s=e.maskId,c=e.extra,f=e.watchable,u=void 0!==f&&f,d=a.found?a:n,h=d.width,m=d.height,p=[Nt.replacementClass,o?"".concat(Nt.cssPrefix,"-").concat(o):""].filter(function(e){return-1===c.classes.indexOf(e)}).filter(function(e){return""!==e||!!e}).concat(c.classes).join(" "),g={children:[],attributes:Q(Q({},c.attributes),{},{"data-prefix":r,"data-icon":o,class:p,role:c.attributes.role||"img",viewBox:"0 0 ".concat(h," ").concat(m)})};(function(e){return["aria-label","aria-labelledby","title","role"].some(function(t){return t in e})})(c.attributes)||c.attributes["aria-hidden"]||(g.attributes["aria-hidden"]="true"),u&&(g.attributes[Ge]="");var v=Q(Q({},g),{},{prefix:r,iconName:o,main:n,mask:a,maskId:s,transform:i,symbol:l,styles:Q({},c.styles)}),b=a.found&&n.found?Tn("generateAbstractMask",v)||{children:[],attributes:{}}:Tn("generateAbstractIcon",v)||{children:[],attributes:{}},y=b.children,w=b.attributes;return v.children=y,v.attributes=w,l?function(e){var t=e.prefix,n=e.iconName,a=e.children,r=e.attributes,o=e.symbol,i=!0===o?"".concat(t,"-").concat(Nt.cssPrefix,"-").concat(n):o;return[{tag:"svg",attributes:{style:"display: none;"},children:[{tag:"symbol",attributes:Q(Q({},r),{},{id:i}),children:a}]}]}(v):function(e){var t=e.children,n=e.main,a=e.mask,r=e.attributes,o=e.styles,i=e.transform;if(It(i)&&n.found&&!a.found){var l={x:n.width/n.height/2,y:.5};r.style=Ft(Q(Q({},o),{},{"transform-origin":"".concat(l.x+i.x/16,"em ").concat(l.y+i.y/16,"em")}))}return[{tag:"svg",attributes:r,children:t}]}(v)}function jn(e){var t=e.content,n=e.width,a=e.height,r=e.transform,o=e.extra,i=e.watchable,l=void 0!==i&&i,s=Q(Q({},o.attributes),{},{class:o.classes.join(" ")});l&&(s[Ge]="");var c=Q({},o.styles);It(r)&&(c.transform=function(e){var t=e.transform,n=e.width,a=void 0===n?16:n,r=e.height,o=void 0===r?16:r,i="";return i+=de?"translate(".concat(t.x/Tt-a/2,"em, ").concat(t.y/Tt-o/2,"em) "):"translate(calc(-50% + ".concat(t.x/Tt,"em), calc(-50% + ").concat(t.y/Tt,"em)) "),i+="scale(".concat(t.size/Tt*(t.flipX?-1:1),", ").concat(t.size/Tt*(t.flipY?-1:1),") "),i+"rotate(".concat(t.rotate,"deg) ")}({transform:r,width:n,height:a}),c["-webkit-transform"]=c.transform);var f=Ft(c);f.length>0&&(s.style=f);var u=[];return u.push({tag:"span",attributes:s,children:[t]}),u}var En=At.styles;function Dn(e){var t=e[0],n=e[1],a=X(e.slice(4),1)[0];return{found:!0,width:t,height:n,icon:Array.isArray(a)?{tag:"g",attributes:{class:"".concat(Nt.cssPrefix,"-").concat(bt.GROUP)},children:[{tag:"path",attributes:{class:"".concat(Nt.cssPrefix,"-").concat(bt.SECONDARY),fill:"currentColor",d:a[0]}},{tag:"path",attributes:{class:"".concat(Nt.cssPrefix,"-").concat(bt.PRIMARY),fill:"currentColor",d:a[1]}}]}:{tag:"path",attributes:{fill:"currentColor",d:a}}}}var Bn={found:!1,width:512,height:512};function Ln(e,t){var n=t;return"fa"===t&&null!==Nt.styleDefault&&(t=un()),new Promise(function(a,r){if("fa"===n){var o=fn(e)||{};e=o.iconName||e,t=o.prefix||t}if(e&&t&&En[t]&&En[t][e])return a(Dn(En[t][e]));!function(e,t){ot||Nt.showMissingIcons||!e||console.error('Icon with name "'.concat(e,'" and prefix "').concat(t,'" is missing.'))}(e,t),a(Q(Q({},Bn),{},{icon:Nt.showMissingIcons&&e&&Tn("missingIconAbstract")||{}}))})}var An=function(){},On=Nt.measurePerformance&&ce&&ce.mark&&ce.measure?ce:{mark:An,measure:An},zn='FA "7.1.0"',$n=function(e){On.mark("".concat(zn," ").concat(e," ends")),On.measure("".concat(zn," ").concat(e),"".concat(zn," ").concat(e," begins"),"".concat(zn," ").concat(e," ends"))},Vn=function(e){return On.mark("".concat(zn," ").concat(e," begins")),function(){return $n(e)}},Hn=function(){};function Wn(e){return"string"==typeof(e.getAttribute?e.getAttribute(Ge):null)}function Un(e){return le.createElementNS("http://www.w3.org/2000/svg",e)}function Jn(e){return le.createElement(e)}function Qn(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).ceFn,n=void 0===t?"svg"===e.tag?Un:Jn:t;if("string"==typeof e)return le.createTextNode(e);var a=n(e.tag);return Object.keys(e.attributes||[]).forEach(function(t){a.setAttribute(t,e.attributes[t])}),(e.children||[]).forEach(function(e){a.appendChild(Qn(e,{ceFn:n}))}),a}var Xn={replace:function(e){var t=e[0];if(t.parentNode)if(e[1].forEach(function(e){t.parentNode.insertBefore(Qn(e),t)}),null===t.getAttribute(Ge)&&Nt.keepOriginalSource){var n=le.createComment(function(e){var t=" ".concat(e.outerHTML," ");return"".concat(t,"Font Awesome fontawesome.com ")}(t));t.parentNode.replaceChild(n,t)}else t.remove()},nest:function(e){var t=e[0],n=e[1];if(~Rt(t).indexOf(Nt.replacementClass))return Xn.replace(e);var a=new RegExp("".concat(Nt.cssPrefix,"-.*"));if(delete n[0].attributes.id,n[0].attributes.class){var r=n[0].attributes.class.split(" ").reduce(function(e,t){return t===Nt.replacementClass||t.match(a)?e.toSvg.push(t):e.toNode.push(t),e},{toNode:[],toSvg:[]});n[0].attributes.class=r.toSvg.join(" "),0===r.toNode.length?t.removeAttribute("class"):t.setAttribute("class",r.toNode.join(" "))}var o=n.map(function(e){return Vt(e)}).join("\n");t.setAttribute(Ge,""),t.innerHTML=o}};function Yn(e){e()}function Zn(e,t){var n="function"==typeof t?t:Hn;if(0===e.length)n();else{var a=Yn;"async"===Nt.mutateApproach&&(a=ie.requestAnimationFrame||Yn),a(function(){var t=!0===Nt.autoReplaceSvg?Xn.replace:Xn[Nt.autoReplaceSvg]||Xn.replace,a=Vn("mutate");e.map(t),a(),n()})}}var qn=!1;function Gn(){qn=!0}function Kn(){qn=!1}var ea=null;function ta(e){if(se&&Nt.observeMutations){var t=e.treeCallback,n=void 0===t?Hn:t,a=e.nodeCallback,r=void 0===a?Hn:a,o=e.pseudoElementsCallback,i=void 0===o?Hn:o,l=e.observeMutationsRoot,s=void 0===l?le:l;ea=new se(function(e){if(!qn){var t=un();Mt(e).forEach(function(e){if("childList"===e.type&&e.addedNodes.length>0&&!Wn(e.addedNodes[0])&&(Nt.searchPseudoElements&&i(e.target),n(e.target)),"attributes"===e.type&&e.target.parentNode&&Nt.searchPseudoElements&&i([e.target],!0),"attributes"===e.type&&Wn(e.target)&&~vt.indexOf(e.attributeName))if("class"===e.attributeName&&function(e){var t=e.getAttribute?e.getAttribute(et):null,n=e.getAttribute?e.getAttribute(tt):null;return t&&n}(e.target)){var a=pn(Rt(e.target)),o=a.prefix,l=a.iconName;e.target.setAttribute(et,o||t),l&&e.target.setAttribute(tt,l)}else(s=e.target)&&s.classList&&s.classList.contains&&s.classList.contains(Nt.replacementClass)&&r(e.target);var s})}}),ue&&ea.observe(s,{childList:!0,attributes:!0,characterData:!0,subtree:!0})}}function na(e){var t,n,a=e.getAttribute("data-prefix"),r=e.getAttribute("data-icon"),o=void 0!==e.innerText?e.innerText.trim():"",i=pn(Rt(e));return i.prefix||(i.prefix=un()),a&&r&&(i.prefix=a,i.iconName=r),i.iconName&&i.prefix||(i.prefix&&o.length>0&&(i.iconName=(t=i.prefix,n=e.innerText,(en[t]||{})[n]||sn(i.prefix,Ut(e.innerText)))),!i.iconName&&Nt.autoFetchSvg&&e.firstChild&&e.firstChild.nodeType===Node.TEXT_NODE&&(i.iconName=e.firstChild.data)),i}function aa(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{styleParser:!0},n=na(e),a=n.iconName,r=n.prefix,o=n.rest,i=function(e){return Mt(e.attributes).reduce(function(e,t){return"class"!==e.name&&"style"!==e.name&&(e[t.name]=t.value),e},{})}(e),l=Nn("parseNodeAttributes",{},e),s=t.styleParser?function(e){var t=e.getAttribute("style"),n=[];return t&&(n=t.split(";").reduce(function(e,t){var n=t.split(":"),a=n[0],r=n.slice(1);return a&&r.length>0&&(e[a]=r.join(":").trim()),e},{})),n}(e):[];return Q({iconName:a,prefix:r,transform:Ct,mask:{iconName:null,prefix:null,rest:[]},maskId:null,symbol:!1,extra:{classes:o,styles:s,attributes:i}},l)}var ra=At.styles;function oa(e){var t="nest"===Nt.autoReplaceSvg?aa(e,{styleParser:!1}):aa(e);return~t.extra.classes.indexOf(pt)?Tn("generateLayersText",e,t):Tn("generateSvgReplacementMutation",e,t)}function ia(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if(!ue)return Promise.resolve();var n=le.documentElement.classList,a=function(e){return n.add("".concat(nt,"-").concat(e))},r=function(e){return n.remove("".concat(nt,"-").concat(e))},o=Nt.autoFetchSvg?[].concat(Y(De),Y(Je)):me.concat(Object.keys(ra));o.includes("fa")||o.push("fa");var i=[".".concat(pt,":not([").concat(Ge,"])")].concat(o.map(function(e){return".".concat(e,":not([").concat(Ge,"])")})).join(", ");if(0===i.length)return Promise.resolve();var l=[];try{l=Mt(e.querySelectorAll(i))}catch(e){}if(!(l.length>0))return Promise.resolve();a("pending"),r("complete");var s=Vn("onTree"),c=l.reduce(function(e,t){try{var n=oa(t);n&&e.push(n)}catch(e){ot||"MissingIcon"===e.name&&console.error(e)}return e},[]);return new Promise(function(e,n){Promise.all(c).then(function(n){Zn(n,function(){a("active"),a("complete"),r("pending"),"function"==typeof t&&t(),s(),e()})}).catch(function(e){s(),n(e)})})}function la(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;oa(e).then(function(e){e&&Zn([e],t)})}var sa=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.transform,a=void 0===n?Ct:n,r=t.symbol,o=void 0!==r&&r,i=t.mask,l=void 0===i?null:i,s=t.maskId,c=void 0===s?null:s,f=t.classes,u=void 0===f?[]:f,d=t.attributes,h=void 0===d?{}:d,m=t.styles,p=void 0===m?{}:m;if(e){var g=e.prefix,v=e.iconName,b=e.icon;return Fn(Q({type:"icon"},e),function(){return Sn("beforeDOMElementCreation",{iconDefinition:e,params:t}),In({icons:{main:Dn(b),mask:l?Dn(l.icon):{found:!1,width:null,height:null,icon:{}}},prefix:g,iconName:v,transform:Q(Q({},Ct),a),symbol:o,maskId:c,extra:{attributes:h,styles:p,classes:u}})})}},ca={mixout:function(){return{icon:(e=sa,function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=(t||{}).icon?t:Cn(t||{}),r=n.mask;return r&&(r=(r||{}).icon?r:Cn(r||{})),e(a,Q(Q({},n),{},{mask:r}))})};var e},hooks:function(){return{mutationObserverCallbacks:function(e){return e.treeCallback=ia,e.nodeCallback=la,e}}},provides:function(e){e.i2svg=function(e){var t=e.node,n=void 0===t?le:t,a=e.callback;return ia(n,void 0===a?function(){}:a)},e.generateSvgReplacementMutation=function(e,t){var n=t.iconName,a=t.prefix,r=t.transform,o=t.symbol,i=t.mask,l=t.maskId,s=t.extra;return new Promise(function(t,c){Promise.all([Ln(n,a),i.iconName?Ln(i.iconName,i.prefix):Promise.resolve({found:!1,width:512,height:512,icon:{}})]).then(function(i){var c=X(i,2),f=c[0],u=c[1];t([e,In({icons:{main:f,mask:u},prefix:a,iconName:n,transform:r,symbol:o,maskId:l,extra:s,watchable:!0})])}).catch(c)})},e.generateAbstractIcon=function(e){var t,n=e.children,a=e.attributes,r=e.main,o=e.transform,i=Ft(e.styles);return i.length>0&&(a.style=i),It(o)&&(t=Tn("generateAbstractTransformGrouping",{main:r,transform:o,containerWidth:r.width,iconWidth:r.width})),n.push(t||r.icon),{children:n,attributes:a}}}},fa={mixout:function(){return{layer:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.classes,a=void 0===n?[]:n;return Fn({type:"layer"},function(){Sn("beforeDOMElementCreation",{assembler:e,params:t});var n=[];return e(function(e){Array.isArray(e)?e.map(function(e){n=n.concat(e.abstract)}):n=n.concat(e.abstract)}),[{tag:"span",attributes:{class:["".concat(Nt.cssPrefix,"-layers")].concat(Y(a)).join(" ")},children:n}]})}}}},ua={mixout:function(){return{counter:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};t.title;var n=t.classes,a=void 0===n?[]:n,r=t.attributes,o=void 0===r?{}:r,i=t.styles,l=void 0===i?{}:i;return Fn({type:"counter",content:e},function(){return Sn("beforeDOMElementCreation",{content:e,params:t}),function(e){var t=e.content,n=e.extra,a=Q(Q({},n.attributes),{},{class:n.classes.join(" ")}),r=Ft(n.styles);r.length>0&&(a.style=r);var o=[];return o.push({tag:"span",attributes:a,children:[t]}),o}({content:e.toString(),extra:{attributes:o,styles:l,classes:["".concat(Nt.cssPrefix,"-layers-counter")].concat(Y(a))}})})}}}},da={mixout:function(){return{text:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.transform,a=void 0===n?Ct:n,r=t.classes,o=void 0===r?[]:r,i=t.attributes,l=void 0===i?{}:i,s=t.styles,c=void 0===s?{}:s;return Fn({type:"text",content:e},function(){return Sn("beforeDOMElementCreation",{content:e,params:t}),jn({content:e,transform:Q(Q({},Ct),a),extra:{attributes:l,styles:c,classes:["".concat(Nt.cssPrefix,"-layers-text")].concat(Y(o))}})})}}},provides:function(e){e.generateLayersText=function(e,t){var n=t.transform,a=t.extra,r=null,o=null;if(de){var i=parseInt(getComputedStyle(e).fontSize,10),l=e.getBoundingClientRect();r=l.width/i,o=l.height/i}return Promise.resolve([e,jn({content:e.innerHTML,width:r,height:o,transform:n,extra:a,watchable:!0})])}}},ha=new RegExp('"',"ug"),ma=[1105920,1112319],pa=Q(Q(Q(Q({},{FontAwesome:{normal:"fas",400:"fas"}}),{"Font Awesome 7 Free":{900:"fas",400:"far"},"Font Awesome 7 Pro":{900:"fas",400:"far",normal:"far",300:"fal",100:"fat"},"Font Awesome 7 Brands":{400:"fab",normal:"fab"},"Font Awesome 7 Duotone":{900:"fad",400:"fadr",normal:"fadr",300:"fadl",100:"fadt"},"Font Awesome 7 Sharp":{900:"fass",400:"fasr",normal:"fasr",300:"fasl",100:"fast"},"Font Awesome 7 Sharp Duotone":{900:"fasds",400:"fasdr",normal:"fasdr",300:"fasdl",100:"fasdt"},"Font Awesome 7 Jelly":{400:"fajr",normal:"fajr"},"Font Awesome 7 Jelly Fill":{400:"fajfr",normal:"fajfr"},"Font Awesome 7 Jelly Duo":{400:"fajdr",normal:"fajdr"},"Font Awesome 7 Slab":{400:"faslr",normal:"faslr"},"Font Awesome 7 Slab Press":{400:"faslpr",normal:"faslpr"},"Font Awesome 7 Thumbprint":{300:"fatl",normal:"fatl"},"Font Awesome 7 Notdog":{900:"fans",normal:"fans"},"Font Awesome 7 Notdog Duo":{900:"fands",normal:"fands"},"Font Awesome 7 Etch":{900:"faes",normal:"faes"},"Font Awesome 7 Chisel":{400:"facr",normal:"facr"},"Font Awesome 7 Whiteboard":{600:"fawsb",normal:"fawsb"},"Font Awesome 7 Utility":{600:"fausb",normal:"fausb"},"Font Awesome 7 Utility Duo":{600:"faudsb",normal:"faudsb"},"Font Awesome 7 Utility Fill":{600:"faufsb",normal:"faufsb"}}),{"Font Awesome 5 Free":{900:"fas",400:"far"},"Font Awesome 5 Pro":{900:"fas",400:"far",normal:"far",300:"fal"},"Font Awesome 5 Brands":{400:"fab",normal:"fab"},"Font Awesome 5 Duotone":{900:"fad"}}),{"Font Awesome Kit":{400:"fak",normal:"fak"},"Font Awesome Kit Duotone":{400:"fakd",normal:"fakd"}}),ga=Object.keys(pa).reduce(function(e,t){return e[t.toLowerCase()]=pa[t],e},{}),va=Object.keys(ga).reduce(function(e,t){var n=ga[t];return e[t]=n[900]||Y(Object.entries(n))[0][1],e},{});function ba(e,t){var n="".concat("data-fa-pseudo-element-pending").concat(t.replace(":","-"));return new Promise(function(a,r){if(null!==e.getAttribute(n))return a();var o,i,l,s=Mt(e.children).filter(function(e){return e.getAttribute(Ke)===t})[0],c=ie.getComputedStyle(e,t),f=c.getPropertyValue("font-family"),u=f.match(gt),d=c.getPropertyValue("font-weight"),h=c.getPropertyValue("content");if(s&&!u)return e.removeChild(s),a();if(u&&"none"!==h&&""!==h){var m=c.getPropertyValue("content"),p=function(e,t){var n=e.replace(/^['"]|['"]$/g,"").toLowerCase(),a=parseInt(t),r=isNaN(a)?"normal":a;return(ga[n]||{})[r]||va[n]}(f,d),g=function(e){return Ut(Y(e.replace(ha,""))[0]||"")}(m),v=u[0].startsWith("FontAwesome"),b=function(e){var t=e.getPropertyValue("font-feature-settings").includes("ss01"),n=e.getPropertyValue("content").replace(ha,""),a=n.codePointAt(0),r=a>=ma[0]&&a<=ma[1],o=2===n.length&&n[0]===n[1];return r||o||t}(c),y=sn(p,g),w=y;if(v){var x=(i=nn[o=g],l=sn("fas",o),i||(l?{prefix:"fas",iconName:l}:null)||{prefix:null,iconName:null});x.iconName&&x.prefix&&(y=x.iconName,p=x.prefix)}if(!y||b||s&&s.getAttribute(et)===p&&s.getAttribute(tt)===w)a();else{e.setAttribute(n,w),s&&e.removeChild(s);var k={iconName:null,prefix:null,transform:Ct,symbol:!1,mask:{iconName:null,prefix:null,rest:[]},maskId:null,extra:{classes:[],styles:{},attributes:{}}},N=k.extra;N.attributes[Ke]=t,Ln(y,p).then(function(r){var o=In(Q(Q({},k),{},{icons:{main:r,mask:{prefix:null,iconName:null,rest:[]}},prefix:p,iconName:w,extra:N,watchable:!0})),i=le.createElementNS("http://www.w3.org/2000/svg","svg");"::before"===t?e.insertBefore(i,e.firstChild):e.appendChild(i),i.outerHTML=o.map(function(e){return Vt(e)}).join("\n"),e.removeAttribute(n),a()}).catch(r)}}else a()})}function ya(e){return Promise.all([ba(e,"::before"),ba(e,"::after")])}function wa(e){return!(e.parentNode===document.head||~at.indexOf(e.tagName.toUpperCase())||e.getAttribute(Ke)||e.parentNode&&"svg"===e.parentNode.tagName)}var xa=function(e){return!!e&&rt.some(function(t){return e.includes(t)})},ka=function(e){if(!e)return[];var t=new Set,n=e.split(/,(?![^()]*\))/).map(function(e){return e.trim()});n=n.flatMap(function(e){return e.includes("(")?e:e.split(",").map(function(e){return e.trim()})});var a,r=W(n);try{for(r.s();!(a=r.n()).done;){var o=a.value;if(xa(o)){var i=rt.reduce(function(e,t){return e.replace(t,"")},o);""!==i&&"*"!==i&&t.add(i)}}}catch(e){r.e(e)}finally{r.f()}return t};function Na(e){if(ue){var t;if(arguments.length>1&&void 0!==arguments[1]&&arguments[1])t=e;else if(Nt.searchPseudoElementsFullScan)t=e.querySelectorAll("*");else{var n,a=new Set,r=W(document.styleSheets);try{for(r.s();!(n=r.n()).done;){var o=n.value;try{var i,l=W(o.cssRules);try{for(l.s();!(i=l.n()).done;){var s,c=i.value,f=W(ka(c.selectorText));try{for(f.s();!(s=f.n()).done;){var u=s.value;a.add(u)}}catch(e){f.e(e)}finally{f.f()}}}catch(e){l.e(e)}finally{l.f()}}catch(e){Nt.searchPseudoElementsWarnings&&console.warn("Font Awesome: cannot parse stylesheet: ".concat(o.href," (").concat(e.message,')\nIf it declares any Font Awesome CSS pseudo-elements, they will not be rendered as SVG icons. Add crossorigin="anonymous" to the <link>, enable searchPseudoElementsFullScan for slower but more thorough DOM parsing, or suppress this warning by setting searchPseudoElementsWarnings to false.'))}}}catch(e){r.e(e)}finally{r.f()}if(!a.size)return;var d=Array.from(a).join(", ");try{t=e.querySelectorAll(d)}catch(e){}}return new Promise(function(e,n){var a=Mt(t).filter(wa).map(ya),r=Vn("searchPseudoElements");Gn(),Promise.all(a).then(function(){r(),Kn(),e()}).catch(function(){r(),Kn(),n()})})}}var Sa={hooks:function(){return{mutationObserverCallbacks:function(e){return e.pseudoElementsCallback=Na,e}}},provides:function(e){e.pseudoElements2svg=function(e){var t=e.node,n=void 0===t?le:t;Nt.searchPseudoElements&&Na(n)}}},Ta=!1,Ca=function(e){return e.toLowerCase().split(" ").reduce(function(e,t){var n=t.toLowerCase().split("-"),a=n[0],r=n.slice(1).join("-");if(a&&"h"===r)return e.flipX=!0,e;if(a&&"v"===r)return e.flipY=!0,e;if(r=parseFloat(r),isNaN(r))return e;switch(a){case"grow":e.size=e.size+r;break;case"shrink":e.size=e.size-r;break;case"left":e.x=e.x-r;break;case"right":e.x=e.x+r;break;case"up":e.y=e.y-r;break;case"down":e.y=e.y+r;break;case"rotate":e.rotate=e.rotate+r}return e},{size:16,x:0,y:0,flipX:!1,flipY:!1,rotate:0})},_a={mixout:function(){return{parse:{transform:function(e){return Ca(e)}}}},hooks:function(){return{parseNodeAttributes:function(e,t){var n=t.getAttribute("data-fa-transform");return n&&(e.transform=Ca(n)),e}}},provides:function(e){e.generateAbstractTransformGrouping=function(e){var t=e.main,n=e.transform,a=e.containerWidth,r=e.iconWidth,o={transform:"translate(".concat(a/2," 256)")},i="translate(".concat(32*n.x,", ").concat(32*n.y,") "),l="scale(".concat(n.size/16*(n.flipX?-1:1),", ").concat(n.size/16*(n.flipY?-1:1),") "),s="rotate(".concat(n.rotate," 0 0)"),c={outer:o,inner:{transform:"".concat(i," ").concat(l," ").concat(s)},path:{transform:"translate(".concat(r/2*-1," -256)")}};return{tag:"g",attributes:Q({},c.outer),children:[{tag:"g",attributes:Q({},c.inner),children:[{tag:t.icon.tag,children:t.icon.children,attributes:Q(Q({},t.icon.attributes),c.path)}]}]}}}},Ma={x:0,y:0,width:"100%",height:"100%"};function Ra(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return e.attributes&&(e.attributes.fill||t)&&(e.attributes.fill="black"),e}var Pa={hooks:function(){return{parseNodeAttributes:function(e,t){var n=t.getAttribute("data-fa-mask"),a=n?pn(n.split(" ").map(function(e){return e.trim()})):{prefix:null,iconName:null,rest:[]};return a.prefix||(a.prefix=un()),e.mask=a,e.maskId=t.getAttribute("data-fa-mask-id"),e}}},provides:function(e){e.generateAbstractMask=function(e){var t,n=e.children,a=e.attributes,r=e.main,o=e.mask,i=e.maskId,l=e.transform,s=r.width,c=r.icon,f=o.width,u=o.icon,d=function(e){var t=e.transform,n=e.containerWidth,a=e.iconWidth,r={transform:"translate(".concat(n/2," 256)")},o="translate(".concat(32*t.x,", ").concat(32*t.y,") "),i="scale(".concat(t.size/16*(t.flipX?-1:1),", ").concat(t.size/16*(t.flipY?-1:1),") "),l="rotate(".concat(t.rotate," 0 0)");return{outer:r,inner:{transform:"".concat(o," ").concat(i," ").concat(l)},path:{transform:"translate(".concat(a/2*-1," -256)")}}}({transform:l,containerWidth:f,iconWidth:s}),h={tag:"rect",attributes:Q(Q({},Ma),{},{fill:"white"})},m=c.children?{children:c.children.map(Ra)}:{},p={tag:"g",attributes:Q({},d.inner),children:[Ra(Q({tag:c.tag,attributes:Q(Q({},c.attributes),d.path)},m))]},g={tag:"g",attributes:Q({},d.outer),children:[p]},v="mask-".concat(i||_t()),b="clip-".concat(i||_t()),y={tag:"mask",attributes:Q(Q({},Ma),{},{id:v,maskUnits:"userSpaceOnUse",maskContentUnits:"userSpaceOnUse"}),children:[h,g]},w={tag:"defs",children:[{tag:"clipPath",attributes:{id:b},children:(t=u,"g"===t.tag?t.children:[t])},y]};return n.push(w,{tag:"rect",attributes:Q({fill:"currentColor","clip-path":"url(#".concat(b,")"),mask:"url(#".concat(v,")")},Ma)}),{children:n,attributes:a}}}},Fa={provides:function(e){var t=!1;ie.matchMedia&&(t=ie.matchMedia("(prefers-reduced-motion: reduce)").matches),e.missingIconAbstract=function(){var e=[],n={fill:"currentColor"},a={attributeType:"XML",repeatCount:"indefinite",dur:"2s"};e.push({tag:"path",attributes:Q(Q({},n),{},{d:"M156.5,447.7l-12.6,29.5c-18.7-9.5-35.9-21.2-51.5-34.9l22.7-22.7C127.6,430.5,141.5,440,156.5,447.7z M40.6,272H8.5 c1.4,21.2,5.4,41.7,11.7,61.1L50,321.2C45.1,305.5,41.8,289,40.6,272z M40.6,240c1.4-18.8,5.2-37,11.1-54.1l-29.5-12.6 C14.7,194.3,10,216.7,8.5,240H40.6z M64.3,156.5c7.8-14.9,17.2-28.8,28.1-41.5L69.7,92.3c-13.7,15.6-25.5,32.8-34.9,51.5 L64.3,156.5z M397,419.6c-13.9,12-29.4,22.3-46.1,30.4l11.9,29.8c20.7-9.9,39.8-22.6,56.9-37.6L397,419.6z M115,92.4 c13.9-12,29.4-22.3,46.1-30.4l-11.9-29.8c-20.7,9.9-39.8,22.6-56.8,37.6L115,92.4z M447.7,355.5c-7.8,14.9-17.2,28.8-28.1,41.5 l22.7,22.7c13.7-15.6,25.5-32.9,34.9-51.5L447.7,355.5z M471.4,272c-1.4,18.8-5.2,37-11.1,54.1l29.5,12.6 c7.5-21.1,12.2-43.5,13.6-66.8H471.4z M321.2,462c-15.7,5-32.2,8.2-49.2,9.4v32.1c21.2-1.4,41.7-5.4,61.1-11.7L321.2,462z M240,471.4c-18.8-1.4-37-5.2-54.1-11.1l-12.6,29.5c21.1,7.5,43.5,12.2,66.8,13.6V471.4z M462,190.8c5,15.7,8.2,32.2,9.4,49.2h32.1 c-1.4-21.2-5.4-41.7-11.7-61.1L462,190.8z M92.4,397c-12-13.9-22.3-29.4-30.4-46.1l-29.8,11.9c9.9,20.7,22.6,39.8,37.6,56.9 L92.4,397z M272,40.6c18.8,1.4,36.9,5.2,54.1,11.1l12.6-29.5C317.7,14.7,295.3,10,272,8.5V40.6z M190.8,50 c15.7-5,32.2-8.2,49.2-9.4V8.5c-21.2,1.4-41.7,5.4-61.1,11.7L190.8,50z M442.3,92.3L419.6,115c12,13.9,22.3,29.4,30.5,46.1 l29.8-11.9C470,128.5,457.3,109.4,442.3,92.3z M397,92.4l22.7-22.7c-15.6-13.7-32.8-25.5-51.5-34.9l-12.6,29.5 C370.4,72.1,384.4,81.5,397,92.4z"})});var r=Q(Q({},a),{},{attributeName:"opacity"}),o={tag:"circle",attributes:Q(Q({},n),{},{cx:"256",cy:"364",r:"28"}),children:[]};return t||o.children.push({tag:"animate",attributes:Q(Q({},a),{},{attributeName:"r",values:"28;14;28;28;14;28;"})},{tag:"animate",attributes:Q(Q({},r),{},{values:"1;0;1;1;0;1;"})}),e.push(o),e.push({tag:"path",attributes:Q(Q({},n),{},{opacity:"1",d:"M263.7,312h-16c-6.6,0-12-5.4-12-12c0-71,77.4-63.9,77.4-107.8c0-20-17.8-40.2-57.4-40.2c-29.1,0-44.3,9.6-59.2,28.7 c-3.9,5-11.1,6-16.2,2.4l-13.1-9.2c-5.6-3.9-6.9-11.8-2.6-17.2c21.2-27.2,46.4-44.7,91.2-44.7c52.3,0,97.4,29.8,97.4,80.2 c0,67.6-77.4,63.5-77.4,107.8C275.7,306.6,270.3,312,263.7,312z"}),children:t?[]:[{tag:"animate",attributes:Q(Q({},r),{},{values:"1;0;0;0;0;1;"})}]}),t||e.push({tag:"path",attributes:Q(Q({},n),{},{opacity:"0",d:"M232.5,134.5l7,168c0.3,6.4,5.6,11.5,12,11.5h9c6.4,0,11.7-5.1,12-11.5l7-168c0.3-6.8-5.2-12.5-12-12.5h-23 C237.7,122,232.2,127.7,232.5,134.5z"}),children:[{tag:"animate",attributes:Q(Q({},r),{},{values:"0;0;1;1;0;0;"})}]}),{tag:"g",attributes:{class:"missing"},children:e}}}};!function(e,t){var n=t.mixoutsTo;yn=e,wn={},Object.keys(xn).forEach(function(e){-1===kn.indexOf(e)&&delete xn[e]}),yn.forEach(function(e){var t=e.mixout?e.mixout():{};if(Object.keys(t).forEach(function(e){"function"==typeof t[e]&&(n[e]=t[e]),"object"===q(t[e])&&Object.keys(t[e]).forEach(function(a){n[e]||(n[e]={}),n[e][a]=t[e][a]})}),e.hooks){var a=e.hooks();Object.keys(a).forEach(function(e){wn[e]||(wn[e]=[]),wn[e].push(a[e])})}e.provides&&e.provides(xn)})}([Bt,ca,fa,ua,da,Sa,{mixout:function(){return{dom:{unwatch:function(){Gn(),Ta=!0}}}},hooks:function(){return{bootstrap:function(){ta(Nn("mutationObserverCallbacks",{}))},noAuto:function(){ea&&ea.disconnect()},watch:function(e){var t=e.observeMutationsRoot;Ta?Kn():ta(Nn("mutationObserverCallbacks",{observeMutationsRoot:t}))}}}},_a,Pa,Fa,{hooks:function(){return{parseNodeAttributes:function(e,t){var n=t.getAttribute("data-fa-symbol"),a=null!==n&&(""===n||n);return e.symbol=a,e}}}}],{mixoutsTo:Rn});var Ia=Rn.config,ja=Rn.parse,Ea=Rn.icon;function Da(e){return t=e,(t-=0)==t?e:(e=e.replace(/[_-]+(.)?/g,(e,t)=>t?t.toUpperCase():"")).charAt(0).toLowerCase()+e.slice(1);var t}function Ba(e){return e.charAt(0).toUpperCase()+e.slice(1)}var La=new Map;function Aa(e){if(La.has(e))return La.get(e);const t={};let n=0;const a=e.length;for(;n<a;){const r=e.indexOf(";",n),o=-1===r?a:r,i=e.slice(n,o).trim();if(i){const e=i.indexOf(":");if(e>0){const n=i.slice(0,e).trim(),a=i.slice(e+1).trim();if(n&&a){const e=Da(n);t[e.startsWith("webkit")?Ba(e):e]=a}}}n=o+1}if(1e3===La.size){const e=La.keys().next().value;e&&La.delete(e)}return La.set(e,t),t}var Oa=function e(t,n,a={}){if("string"==typeof n)return n;const r=(n.children||[]).map(n=>e(t,n)),o=n.attributes||{},i={};for(const[e,t]of Object.entries(o))switch(!0){case"class"===e:i.className=t;break;case"style"===e:i.style=Aa(String(t));break;case e.startsWith("aria-"):case e.startsWith("data-"):i[e.toLowerCase()]=t;break;default:i[Da(e)]=t}const{style:l,role:s,"aria-label":c,...f}=a;return l&&(i.style=i.style?{...i.style,...l}:l),s&&(i.role=s),c&&(i["aria-label"]=c,i["aria-hidden"]="false"),t(n.tag,{...f,...i},...r)}.bind(null,a.createElement),za=(e,t)=>{const n=r();return e||(t?n:void 0)};"undefined"!=typeof process&&process.env.FA_VERSION;var $a="searchPseudoElementsFullScan"in Ia?"7.0.0":"6.0.0",Va=Number.parseInt($a)>=7,Ha="fa",Wa="fa-beat",Ua="fa-fade",Ja="fa-beat-fade",Qa="fa-bounce",Xa="fa-shake",Ya="fa-spin",Za="fa-spin-pulse",qa="fa-spin-reverse",Ga="fa-pulse",Ka={left:"fa-pull-left",right:"fa-pull-right"},er={90:"fa-rotate-90",180:"fa-rotate-180",270:"fa-rotate-270"},tr={"2xs":"fa-2xs",xs:"fa-xs",sm:"fa-sm",lg:"fa-lg",xl:"fa-xl","2xl":"fa-2xl","1x":"fa-1x","2x":"fa-2x","3x":"fa-3x","4x":"fa-4x","5x":"fa-5x","6x":"fa-6x","7x":"fa-7x","8x":"fa-8x","9x":"fa-9x","10x":"fa-10x"},nr="fa-border",ar="fa-fw",rr="fa-flip",or="fa-flip-horizontal",ir="fa-flip-vertical",lr="fa-inverse",sr="fa-rotate-by",cr="fa-swap-opacity",fr="fa-width-auto";function ur(e){const t=Ia.cssPrefix||Ia.familyPrefix||Ha;return t===Ha?e:e.replace(new RegExp(String.raw`(?<=^|\s)${Ha}-`,"g"),`${t}-`)}function dr(e){if(e)return(e=>"object"==typeof e&&"icon"in e&&!!e.icon)(e)?e:ja.icon(e)}var hr=new class{constructor(e="react-fontawesome"){this.enabled=!1;let t=!1;try{t="undefined"!=typeof process&&"development"===process.env.NODE_ENV}catch{}this.scope=e,this.enabled=t}log(...e){this.enabled&&console.log(`[${this.scope}]`,...e)}warn(...e){this.enabled&&console.warn(`[${this.scope}]`,...e)}error(...e){this.enabled&&console.error(`[${this.scope}]`,...e)}}("FontAwesomeIcon"),mr={border:!1,className:"",mask:void 0,maskId:void 0,fixedWidth:!1,inverse:!1,flip:!1,icon:void 0,listItem:!1,pull:void 0,pulse:!1,rotation:void 0,rotateBy:!1,size:void 0,spin:!1,spinPulse:!1,spinReverse:!1,beat:!1,fade:!1,beatFade:!1,bounce:!1,shake:!1,symbol:!1,title:"",titleId:void 0,transform:void 0,swapOpacity:!1,widthAuto:!1},pr=new Set(Object.keys(mr)),gr=a.forwardRef((e,t)=>{const n={...mr,...e},{icon:a,mask:r,symbol:o,title:i,titleId:l,maskId:s,transform:c}=n,f=za(s,Boolean(r)),u=za(l,Boolean(i)),d=dr(a);if(!d)return hr.error("Icon lookup is undefined",a),null;const h=function(e){const{beat:t,fade:n,beatFade:a,bounce:r,shake:o,spin:i,spinPulse:l,spinReverse:s,pulse:c,fixedWidth:f,inverse:u,border:d,flip:h,size:m,rotation:p,pull:g,swapOpacity:v,rotateBy:b,widthAuto:y,className:w}=e,x=[];return w&&x.push(...w.split(" ")),t&&x.push(Wa),n&&x.push(Ua),a&&x.push(Ja),r&&x.push(Qa),o&&x.push(Xa),i&&x.push(Ya),s&&x.push(qa),l&&x.push(Za),c&&x.push(Ga),f&&x.push(ar),u&&x.push(lr),d&&x.push(nr),!0===h&&x.push(rr),"horizontal"!==h&&"both"!==h||x.push(or),"vertical"!==h&&"both"!==h||x.push(ir),null!=m&&x.push(tr[m]),null!=p&&0!==p&&x.push(er[p]),null!=g&&x.push(Ka[g]),v&&x.push(cr),Va?(b&&x.push(sr),y&&x.push(fr),(Ia.cssPrefix||Ia.familyPrefix||Ha)===Ha?x:x.map(ur)):x}(n),m="string"==typeof c?ja.transform(c):c,p=dr(r),g=Ea(d,{...h.length>0&&{classes:h},...m&&{transform:m},...p&&{mask:p},symbol:o,title:i,titleId:u,maskId:f});if(!g)return hr.error("Could not find icon",d),null;const{abstract:v}=g,b={ref:t};for(const e of(y=n,Object.keys(y)))pr.has(e)||(b[e]=n[e]);var y;return Oa(v[0],b)});gr.displayName="FontAwesomeIcon";var vr={box:"Box-module_box__SQLj3",collapseBox:"Box-module_collapseBox__5A5Fc",padding:"Box-module_padding__dIJ-L",collapsedContent:"Box-module_collapsedContent__yn-0g",collapseTitle:"Box-module_collapseTitle__-R0ge",collapseIcon:"Box-module_collapseIcon__OAiTO",collapsed:"Box-module_collapsed__nf76f"};function br(t){const{children:n,noPadding:a,className:r="",theme:o="dark"}=t;return e("div",{className:`${vr.box} ${a?"":vr.padding} ${r}`,"data-theme":o,children:n})}$.bind(vr);const yr=["dotnetspy","ebpfspy","gospy","phpspy","pyspy","rbspy","nodespy","javaspy","pyroscope-rs","scrape","tracing","unknown"],wr=S.preprocess(e=>e&&yr.includes(e)?e:"unknown",S.enum(yr).default("unknown")),xr=["samples","objects","goroutines","bytes","lock_samples","lock_nanoseconds","trace_samples","exceptions"],kr=S.preprocess(e=>"string"==typeof e&&xr.includes(e)?e:"unknown",S.enum(["samples","objects","goroutines","bytes","lock_samples","lock_nanoseconds","trace_samples","exceptions","unknown"])),Nr=S.object({names:S.array(S.preprocess(e=>e||"unknown",S.string().min(1))),levels:S.array(S.array(S.number())),numTicks:S.number(),maxSelf:S.number()}),Sr=S.object({appName:S.string().optional(),name:S.string().optional(),startTime:S.number().optional(),endTime:S.number().optional(),query:S.string().optional(),maxNodes:S.number().optional(),format:S.enum(["single","double"]),sampleRate:S.number(),spyName:wr,units:kr});S.object({version:S.number().min(1).max(1).default(1),flamebearer:Nr,metadata:Sr,leftTicks:S.number().optional(),rightTicks:S.number().optional()});const Tr={format:"single",jStep:4,jName:3,getBarOffset:(e,t)=>e[t],getBarTotal:(e,t)=>e[t+1],getBarTotalDiff:(e,t)=>0,getBarSelf:(e,t)=>e[t+2],getBarSelfDiff:(e,t)=>0,getBarName:(e,t)=>e[t+3]},Cr={format:"double",jStep:7,jName:6,getBarOffset:(e,t)=>e[t]+e[t+3],getBarTotal:(e,t)=>e[t+4]+e[t+1],getBarTotalLeft:(e,t)=>e[t+1],getBarTotalRght:(e,t)=>e[t+4],getBarTotalDiff:(e,t)=>e[t+4]-e[t+1],getBarSelf:(e,t)=>e[t+5]+e[t+2],getBarSelfLeft:(e,t)=>e[t+2],getBarSelfRght:(e,t)=>e[t+5],getBarSelfDiff:(e,t)=>e[t+5]-e[t+2],getBarName:(e,t)=>e[t+6]};function _r(e){switch(e){case"single":return Tr;case"double":return Cr;default:throw new Error(`Unsupported type: '${e}'`)}}const Mr=S.object({refType:S.string(),traceID:S.string(),spanID:S.string()}),Rr=S.object({key:S.string(),type:S.string(),value:S.union([S.boolean(),S.number(),S.string()])}),Pr=S.object({traceID:S.string(),spanID:S.string(),flags:S.string(),operationName:S.string(),references:S.array(Mr),startTime:S.number(),duration:S.number(),tags:S.array(Rr),logs:S.object({timestamp:S.number(),fields:S.array(Rr)}),processID:S.string(),warnings:S.any()}),Fr=S.object({serviceName:S.string(),tags:S.array(Rr)});S.object({traceID:S.string(),spans:S.array(Pr),processes:S.record(Fr),warnings:S.any()});const Ir=S.object({watermark:S.object({}).optional(),startTime:S.number(),samples:S.array(S.number()),durationDelta:S.number()});S.record(S.string(),Ir);const jr=22,Er=21.5;function Dr(e){return e.toString().replace(/\B(?=(\d{3})+(?!\d))/g,",")}function Br(e){if(null==e)return null;if("number"==typeof e)return{value:e,unit:"",hasLessThan:!1,sign:""};let t=String(e).trim().replace(/\u2212/g,"-");if(!t)return null;let n=!1;t.startsWith("<")&&(n=!0,t=t.slice(1).trim());const a=t.match(/^([+\-]?)(\d*\.?\d+)\s*(.*)$/);if(!a)return null;const r=a[1]||"",o=a[2],i=(a[3]||"").trim(),l=parseFloat(o);return Number.isFinite(l)?{value:l,unit:i,hasLessThan:n,sign:r}:null}function Lr(e,t=!1){if(!e||!t)return e;const n=Br(e);if(!n)return e;const{unit:a}=n;let r=a;const o=a.toLowerCase();"ms"===o?r="毫秒":"μs"===o||"µs"===o||"us"===o?r="微秒":"second"===o||"seconds"===o?r="秒":"minute"===o||"minutes"===o||"min"===o||"mins"===o?r="分钟":"hour"===o||"hours"===o?r="小时":"day"===o||"days"===o?r="天":"month"===o||"months"===o?r="月":"year"!==o&&"years"!==o||(r="年");const i=String(e).match(/^([<\s]*)([+\-]?\d*\.?\d+)(.*)$/);if(!i)return e;return`${i[1]||""}${i[2]||""} ${r}`.trim()}const Ar=[{value:1e15,label:"Quad"},{value:1e12,label:"Tri"},{value:1e9,label:"B"},{value:1e6,label:"M"},{value:1e3,label:"K"}];function Or(e){return Math.round(1e4*e)/100}function zr(e,t){return(t-e)/e*100}function $r(e,t,n){switch(n){case"samples":return new Vr(e/t);case"objects":case"goroutines":case"lock_samples":case"exceptions":return new Wr(e);case"bytes":return new Ur(e);case"lock_nanoseconds":return new Hr(e);case"trace_samples":return new Vr(e/t,"",!0);default:return console.warn(`Unsupported unit: '${n}'. Defaulting to ''`),new Vr(e/t," ")}}class Vr{constructor(e,t,n){this.divider=1,this.enableSubsecondPrecision=!1,this.suffix="second",this.durations=[[60,"minute"],[60,"hour"],[24,"day"],[30,"month"],[12,"year"]],this.units="",n&&(this.enableSubsecondPrecision=n,this.durations=[[1e3,"ms"],[1e3,"second"],...this.durations],this.suffix="μs",e*=1e6),this.units=t||"";for(let t=0;t<this.durations.length;t++){const n=this.durations[t];if(!n){console.warn("Could not calculate level");break}if(!(e>=n[0]))break;this.divider*=n[0],e/=n[0],this.suffix=n[1]}}format(e,t,n=!0){this.enableSubsecondPrecision&&(t/=1e6);const a=e/t/this.divider;let r=a.toFixed(2);return 0===a?r="0.00":(a>=0&&a<.01||a<=0&&a>-.01)&&(r="< 0.01"),n?`${r} ${this.units||`${this.suffix}${1===a||2===this.suffix.length?"":"s"}`}`:r}formatPrecise(e,t){this.enableSubsecondPrecision&&(t/=1e6);const n=e/t/this.divider;return`${parseFloat(n.toFixed(5))} ${this.units||`${this.suffix}${1===n||2===this.suffix.length?"":"s"}`}`}}class Hr{constructor(e){this.divider=1,this.multiplier=1,this.suffix="second",this.durations=[[60,"minute"],[60,"hour"],[24,"day"],[30,"month"],[12,"year"]],e/=1e9;for(let t=0;t<this.durations.length;t++){const n=this.durations[t];if(!n){console.warn("Could not calculate level");break}if(!(e>=n[0]))break;this.divider*=n[0],e/=n[0],this.suffix=n[1]}}format(e){const t=e/1e9/this.divider;let n=t.toFixed(2);return(t>=0&&t<.01||t<=0&&t>-.01)&&(n="< 0.01"),`${n} ${this.suffix}${1===t?"":"s"}`}formatPrecise(e){const t=e/1e9/this.divider;return`${parseFloat(t.toFixed(5))} ${this.suffix}${1===t?"":"s"}`}}class Wr{constructor(e){this.divider=1,this.suffix="",this.objects=[[1e3,"K"],[1e3,"M"],[1e3,"G"],[1e3,"T"],[1e3,"P"]];for(let t=0;t<this.objects.length;t++){const n=this.objects[t];if(!n){console.warn("Could not calculate level");break}if(!(e>=n[0]))break;this.divider*=n[0],e/=n[0],this.suffix=n[1]}}format(e){const t=e/this.divider;let n=t.toFixed(2);return(t>=0&&t<.01||t<=0&&t>-.01)&&(n="< 0.01"),`${n} ${this.suffix}`}formatPrecise(e){const t=e/this.divider;return`${parseFloat(t.toFixed(5))} ${this.suffix}`}}class Ur{constructor(e){this.divider=1,this.suffix="bytes",this.bytes=[[1024,"KB"],[1024,"MB"],[1024,"GB"],[1024,"TB"],[1024,"PB"]];for(let t=0;t<this.bytes.length;t++){const n=this.bytes[t];if(!n){console.warn("Could not calculate level");break}if(!(e>=n[0]))break;{this.divider*=n[0],e/=n[0];const t=n[1];t?this.suffix=t:(console.warn("Could not calculate suffix"),this.suffix="")}}}format(e){const t=e/this.divider;let n=t.toFixed(2);return(t>=0&&t<.01||t<=0&&t>-.01)&&(n="< 0.01"),`${n} ${this.suffix}`}formatPrecise(e){const t=e/this.divider;return`${parseFloat(t.toFixed(5))} ${this.suffix}`}}const Jr="TAIL",Qr="HEAD";function Xr({mode:e,charSize:t,rectWidth:n,fullText:a,shortText:r}){if(e===Jr){if(t*a.length<=n)return{mode:e,text:a,marginLeft:3};const o=t*r.length;return o<=n?{mode:e,text:r,marginLeft:3}:{mode:e,text:r,marginLeft:-(o-n+3)}}return{mode:e,text:a,marginLeft:3}}function Yr(e){return e===Jr?{direction:"rtl",overflow:"hidden",textOverflow:"ellipsis"}:{overflow:"hidden",textOverflow:"ellipsis"}}function Zr(e,t){if(e===t)return 0;if(0===e)return 100;const n=(t-e)/e*100;return n>100?100:n<-100?-100:n}function qr(e,t){return T.rgb(e,e,e).alpha(t)}function Gr(e,t){if(0===t.length)return t;const n=function(e){switch(e){case"dotnetspy":return/^(?<packageName>.+)\.(.+)\.(.+)\(.*\)$/;case"ebpfspy":case"unknown":return/^(?<packageName>.+)$/;case"gospy":case"scrape":return/^(?<packageName>.*?\/.*?\.|.*?\.|.+)(?<functionName>.*)$/;case"phpspy":return/^(?<packageName>(.*\/)*)(?<filename>.*\.php+)(?<line_info>.*)$/;case"pyspy":return/^(?<packageName>(.*\/)*)(?<filename>.*\.py+)(?<line_info>.*)$/;case"rbspy":return/^(?<packageName>(.*\/)*)(?<filename>.*\.rb+)(?<line_info>.*)$/;case"nodespy":return/^(\.\/node_modules\/)?(?<packageName>[^/]*)(?<filename>.*\.?(jsx?|tsx?)?):(?<functionName>.*):(?<line_info>.*)$/;case"tracing":return/^(?<packageName>.+?):.*$/;case"javaspy":return/^(?<packageName>.+\/)(?<filename>.+\.)(?<functionName>.+)$/;case"pyroscope-rs":return/^(?<packageName>[^::]+)/}return/^(?<packageName>.+)$/}(e),a=t.match(n);return a&&a.groups?a.groups.packageName||"":t}function Kr(e,t){const n=function(e,t=0){let n,a,r,o,i,l,s,c;for(n=3&e.length,a=e.length-n,r=t,i=3432918353,l=461845907,c=0;c<a;)s=255&e.charCodeAt(c)|(255&e.charCodeAt(++c))<<8|(255&e.charCodeAt(++c))<<16|(255&e.charCodeAt(++c))<<24,++c,s=(65535&s)*i+(((s>>>16)*i&65535)<<16)&4294967295,s=s<<15|s>>>17,s=(65535&s)*l+(((s>>>16)*l&65535)<<16)&4294967295,r^=s,r=r<<13|r>>>19,o=5*(65535&r)+((5*(r>>>16)&65535)<<16)&4294967295,r=27492+(65535&o)+(((o>>>16)+58964&65535)<<16);switch(s=0,n){case 3:s^=(255&e.charCodeAt(c+2))<<16;case 2:s^=(255&e.charCodeAt(c+1))<<8;case 1:s^=255&e.charCodeAt(c);default:s=(65535&s)*i+(((s>>>16)*i&65535)<<16)&4294967295,s=s<<15|s>>>17,s=(65535&s)*l+(((s>>>16)*l&65535)<<16)&4294967295,r^=s}return r^=e.length,r^=r>>>16,r=2246822507*(65535&r)+((2246822507*(r>>>16)&65535)<<16)&4294967295,r^=r>>>13,r=3266489909*(65535&r)+((3266489909*(r>>>16)&65535)<<16)&4294967295,r^=r>>>16,r>>>0}(t,0),a=n%e.colors.length,r=e.colors[a];return r||(console.warn("Could not calculate color. Defaulting to the first one"),e.colors[0])}function eo(e){const{goodColor:t,neutralColor:n,badColor:a}=e,r=C().domain([-100,0,100]).range([t.rgb().toString(),n.rgb().toString(),a.rgb().toString()]);return e=>T(r(e).toString())}T.rgb(148,142,142),T.rgb(200,0,0),T.rgb(0,170,0),T("#48CE73");const to=new WeakMap,no=new WeakMap,ao=new WeakMap,ro=new WeakMap;const oo={collapsedLevelsSingular:"total (1 level collapsed)",collapsedLevelsPlural:"total ({n} levels collapsed)",isZh:!1};function io(e){var t,n,a,r,o,i,l,s;const c=performance.now(),f=!1!==e.renderRects,u=!1!==e.renderText,d=null!==(t=e.renderMode)&&void 0!==t?t:"normal",h=e.timeBudgetMs,{canvas:m,fitMode:p,units:g,tickToX:v,levels:b,palette:y}=e,{numTicks:w,sampleRate:x,pxPerTick:k}=e,{rangeMin:N,rangeMax:S}=e,{focusedNode:T,zoom:C}=e,_=e.messages||oo,M=e.skipCanvasResize?m.width:function(e){if("clientWidth"in e&&"number"==typeof e.clientWidth)return e.clientWidth;return e.width}(m);if(e.skipCanvasResize||(m.width=M),N>=S)throw new Error("'rangeMin' should be strictly smaller than 'rangeMax'");const{format:R}=e,P=_r(R),F=m.getContext("2d");if(!F)throw new Error("Could not get ctx");const I=C.mapOrElse(()=>0,e=>e.i),j=$r(w,x,g),E=T.isJust,D=T.mapOrElse(()=>0,e=>e.i),B=E?Er:0,L=!!e.highlightQuery&&e.highlightQuery.length>0,A=jr*(b.length-D)+(E?Er:0);e.skipCanvasResize||(m.height=A);const O="number"==typeof e.devicePixelRatio?e.devicePixelRatio:"undefined"!=typeof devicePixelRatio?devicePixelRatio:1;!e.skipDprScale&&O>1&&(m.width*=O,m.height*=O,F.scale(O,O)),F.textBaseline="middle",F.font="400 11.5px SFMono-Regular, Consolas, Liberation Mono, Menlo, monospace";const z=F.measureText("a").width,{names:$}=e,V=function(e){const t=to.get(e);if(t)return t;const n=new Map;return to.set(e,n),n}(m),H=L?function(e,t){const n=no.get(e);if(n){const e=n.get(t);if(e)return e}const a=t.toLowerCase(),r=new Uint8Array(e.length);for(let t=1;t<e.length;t+=1){const n=e[t];n&&n.toLowerCase().includes(a)&&(r[t]=1)}const o=null!=n?n:new Map;return o.set(t,r),no.set(e,o),r}($,e.highlightQuery):null,W="single"===e.format?function(e,t,n){const a=`${t}|${n.name}`,r=ao.get(e);if(r){const e=r.get(a);if(e)return e}const o=new Array(e.length);for(let a=0;a<e.length;a+=1){const r=Gr(t,e[a]||"")||"";o[a]=Kr(n,r)}const i=null!=r?r:new Map;return i.set(a,o),ao.set(e,i),o}($,e.spyName,y):null,U="double"===e.format?eo({name:y.name,goodColor:y.goodColor,neutralColor:y.neutralColor,badColor:y.badColor}):null,J=(e,t)=>{const n=e[t+P.jName];return!(!n||n<0||!H)&&1===H[n]},Q=null!==(n=e.startI)&&void 0!==n?n:0,X=null!==(a=e.startJ)&&void 0!==a?a:0;if(E&&"highlightOnly"!==d&&0===(null!==(r=e.levelStart)&&void 0!==r?r:0)&&0===Q&&0===X){const e=w*k;f&&(F.beginPath(),F.rect(0,0,w*k,Er),F.fillStyle=qr(200,1).rgb().string(),F.fill());const t=T.mapOrElse(()=>"total",e=>function(e,t){return 1===e?t.collapsedLevelsSingular:t.collapsedLevelsPlural.replace("{n}",String(e))}(e.i-1,_)),n=Xr({mode:p,charSize:z,rectWidth:e,fullText:t,shortText:t}),a=0,r=0,o=Er;if(u){F.beginPath(),F.rect(0,0,e,Er),F.save(),F.clip(),F.fillStyle="black";const t=Math.round(Math.max(a,0));F.fillText(n.text,t+n.marginLeft,r+o/2+1),F.restore()}}const Y=Math.max(0,null!==(o=e.levelStart)&&void 0!==o?o:0),Z=b.length-D,q=Math.min(Z,null!==(i=e.levelEnd)&&void 0!==i?i:Z),G=Math.max(Y,null!==(l=e.startI)&&void 0!==l?l:Y),K=Math.max(0,null!==(s=e.startJ)&&void 0!==s?s:0),{spyName:ee}=e,te=(t,n,a,r,o)=>{const i={level:t,j:n,i:a+T.mapOrElse(()=>0,e=>e.i),names:$,collapsed:r,selectedLevel:I,highlightModeOn:L,isHighlighted:o,spyName:ee,palette:y,colorByNameIndex:W,diffColorFn:U};switch(R){case"single":return function(e){const t=co(e);if(t)return t;const n=_r("single"),a=e.selectedLevel>e.i?.33:1;let r=e.level[e.j+n.jName];void 0===r&&(console.warn("Could nto find level",{l:e.j,jName:n.jName,level:e.level}),r=-1);if(e.colorByNameIndex&&r>=0&&e.colorByNameIndex[r])return e.colorByNameIndex[r].alpha(a);const o=e.names[r]||"",i=Gr(e.spyName,o)||"";return Kr(e.palette,i).alpha(a)}({...i});case"double":return function(e){const t=co(e);if(t)return t;const n=e.selectedLevel>e.i?.33:1,{leftRatio:a,rightRatio:r}=function(e,t,n,a){const r=Cr;return n&&a?{leftRatio:r.getBarTotalLeft(e,t)/n,rightRatio:r.getBarTotalRght(e,t)/a}:(console.error("Properties 'rightTicks' and 'leftTicks' are required. Can't calculate ratio."),{leftRatio:0,rightRatio:0})}(e.level,e.j,e.leftTicks,e.rightTicks),o=Or(a),i=Or(r);if(e.diffColorFn)return e.diffColorFn(Zr(o,i)).alpha(n);return function(e,t,n){const a=Zr(t,n);return eo(e)(a)}(e.palette,o,i).alpha(n)}({...i,leftTicks:e.leftTicks,rightTicks:e.rightTicks});default:throw new Error(`Unsupported format: ${R}`)}};if("highlightOnly"===d&&L&&f){const e=function(e,t){const n=ro.get(e);if(n)return n;const a=_r(t),r=new Map;for(let t=0;t<e.length;t+=1){const n=e[t];for(let e=0;e<n.length;e+=a.jStep){const o=a.getBarName(n,e);if(void 0===o||o<0)continue;const i=r.get(o);i?i.push({i:t,j:e}):r.set(o,[{i:t,j:e}])}}return ro.set(e,r),r}(b,R),t=[];for(let e=1;e<$.length;e+=1)H&&1===H[e]&&t.push(e);for(let n=0;n<t.length;n+=1){const a=t[n],r=e.get(a);if(r)for(let e=0;e<r.length;e+=1){const t=r[e],n=t.i-D;if(t.i<D||n<Y||n>=q)continue;const a=b[t.i],o=v(P.getBarOffset(a,t.j)),i=n*jr+B,l=Er,s=P.getBarTotal(a,t.j),c=s*k<=5,f=s*k-(c?0:.5);if(f<=0)continue;F.beginPath(),F.rect(o,i,f,l);const u=te(a,t.j,n,c,!0);F.fillStyle=u.string(),F.fill()}}return{done:!0,nextI:q,nextJ:0}}for(let e=G;e<q;e+=1){const t=b[D+e];if(!t)throw new Error(`Could not find level: ${D+e}`);let n=e===G?K:0;for(;n<t.length;n+=P.jStep){const a=P.getBarOffset(t,n),r=v(a),o=e*jr+B,i=Er,l=L&&J(t,n);let s=P.getBarTotal(t,n);const m=s*k<=5;if(m)for(;n<t.length-P.jStep&&a+s===P.getBarOffset(t,n+P.jStep)&&P.getBarTotal(t,n+P.jStep)*k<=5&&l===(L&&J(t,n+P.jStep));)n+=P.jStep,s+=P.getBarTotal(t,n);const g=s*k-(m?0:.5);if(F.beginPath(),F.rect(r,o,g,i),f){if("forceGrey"===d)F.fillStyle=qr(200,.66).rgb().string();else{const a=te(t,n,e,m,l);F.fillStyle=a.string()}F.fill()}if(!u||m||"forceGrey"===d){if(h&&performance.now()-c>h)return{done:!1,nextI:e,nextJ:n+P.jStep};continue}if(g<20)continue;const b=lo($,n,R,t),y=Xr({mode:p,charSize:z,rectWidth:g,fullText:so(b,s,x,j,_,V),shortText:b});F.save(),F.clip(),F.fillStyle="black";const w=Math.round(Math.max(r,0));if(F.fillText(y.text,w+y.marginLeft,o+i/2+1),F.restore(),h&&performance.now()-c>h)return{done:!1,nextI:e,nextJ:n+P.jStep}}if(h&&performance.now()-c>h)return{done:!1,nextI:e+1,nextJ:0}}return{done:!0,nextI:q,nextJ:0}}function lo(e,t,n,a){let r=a[t+_r(n).jName];void 0===r&&(r=-1);const o=e[r];return o||(console.warn("Could not find function name for",{j:t,format:n,level:a,names:e}),"")}function so(e,t,n,a,r,o){let i=null==o?void 0:o.get(t);if(!i){const e=a.format(t,n);i=Lr(e,!!r.isZh)||e,null==o||o.set(t,i)}return`${e} (${i})`}function co({collapsed:e,highlightModeOn:t,isHighlighted:n}){return e||t&&!n?qr(200,.66):null}class fo{constructor(e,t,n,a,r,o,i,l){if(this.flamebearer=e,this.canvas=t,this.focusedNode=n,this.fitMode=a,this.highlightQuery=r,this.zoom=o,this.palette=i,this.messages=l,this.cachedRange=null,this.cachedPxPerTick=null,this.tickToX=e=>{var t;const n=this.cachedRange?this.cachedRange.rangeMin:this.getRange().rangeMin,a=null!==(t=this.cachedPxPerTick)&&void 0!==t?t:this.pxPerTick();return(e-this.flamebearer.numTicks*n)*a},this.xyToBarPosition=e=>{const{ff:t}=this,{i:n,j:a}=this.xyToBarIndex(e.x,e.y),r=this.focusedNode.mapOrElse(()=>0,e=>e.i<0?0:e.i-1),o=this.flamebearer.levels[n];if(!o)throw new Error(`Could not find level: '${n}'`);const i=Math.max(this.tickToX(t.getBarOffset(o,a)),0);return{x:i,y:Math.max((n-r)*jr,0),width:Math.min(this.tickToX(t.getBarOffset(o,a)+t.getBarTotal(o,a))-i,this.getCanvasWidth())}},this.xyToBarData=e=>{const{i:t,j:n}=this.xyToBarIndex(e.x,e.y),a=this.flamebearer.levels[t];if(!a)throw new Error(`Could not find level: '${t}'`);switch(this.flamebearer.format){case"single":{const e=Tr;return{format:"single",name:this.flamebearer.names[e.getBarName(a,n)],self:e.getBarSelf(a,n),offset:e.getBarOffset(a,n),total:e.getBarTotal(a,n)}}case"double":{const e=Cr;return{format:"double",barTotal:e.getBarTotal(a,n),totalLeft:e.getBarTotalLeft(a,n),totalRight:e.getBarTotalRght(a,n),totalDiff:e.getBarTotalDiff(a,n),name:this.flamebearer.names[e.getBarName(a,n)]}}default:throw new Error("Unsupported type")}},this.isWithinBounds=(e,t)=>{if(e<0||e>this.getCanvasWidth())return!1;try{const{i:n,j:a}=this.xyToBarIndex(e,t);if(-1===a||-1===n)return!1}catch(e){return!1}return!0},this.zoom=o,this.focusedNode=n,this.flamebearer=e,this.canvas=t,this.highlightQuery=r,this.ff=_r(e.format),this.palette=i,this.messages=l,n.isJust&&o.isJust&&o.value.i<n.value.i)throw new Error("Zoom i level should be bigger than Focus")}render(e){var t;const{rangeMin:n,rangeMax:a,pxPerTick:r}=this.updateCachedMetrics(),o=null!==(t=null==e?void 0:e.highlightQueryOverride)&&void 0!==t?t:this.highlightQuery,i={canvas:this.canvas,format:this.flamebearer.format,numTicks:this.flamebearer.numTicks,sampleRate:this.flamebearer.sampleRate,names:this.flamebearer.names,levels:this.flamebearer.levels,spyName:this.flamebearer.spyName,units:this.flamebearer.units,maxSelf:this.flamebearer.maxSelf,rangeMin:n,rangeMax:a,fitMode:this.fitMode,highlightQuery:o,zoom:this.zoom,focusedNode:this.focusedNode,pxPerTick:r,tickToX:e=>(e-this.flamebearer.numTicks*n)*r,palette:this.palette,messages:this.messages,renderRects:null==e?void 0:e.renderRects,renderText:null==e?void 0:e.renderText,renderMode:null==e?void 0:e.renderMode,levelStart:null==e?void 0:e.levelStart,levelEnd:null==e?void 0:e.levelEnd,startI:null==e?void 0:e.startI,startJ:null==e?void 0:e.startJ,timeBudgetMs:null==e?void 0:e.timeBudgetMs,skipCanvasResize:null==e?void 0:e.skipCanvasResize,skipDprScale:null==e?void 0:e.skipDprScale,devicePixelRatio:null==e?void 0:e.devicePixelRatio},{format:l}=this.flamebearer;switch(l){case"single":return io({...i,format:"single"});case"double":return io({...i,leftTicks:this.flamebearer.leftTicks,rightTicks:this.flamebearer.rightTicks});default:throw new Error(`Invalid format: '${l}'`)}}pxPerTick(){if(null!==this.cachedPxPerTick)return this.cachedPxPerTick;const{rangeMin:e,rangeMax:t}=this.getRange(),n=this.getCanvasWidth()/this.flamebearer.numTicks/(t-e);return this.cachedRange={rangeMin:e,rangeMax:t},this.cachedPxPerTick=n,n}updateCachedMetrics(){const{rangeMin:e,rangeMax:t}=this.getRange(),n=this.getCanvasWidth()/this.flamebearer.numTicks/(t-e);return this.cachedRange={rangeMin:e,rangeMax:t},this.cachedPxPerTick=n,{rangeMin:e,rangeMax:t,pxPerTick:n}}getRange(){const{ff:e}=this,t=t=>{const n=this.flamebearer.levels[t.i];if(!n)throw new Error(`Could not find level: '${t.i}'`);return{rangeMin:e.getBarOffset(n,t.j)/this.flamebearer.numTicks,rangeMax:(e.getBarOffset(n,t.j)+e.getBarTotal(n,t.j))/this.flamebearer.numTicks}},n=t=>{const n=this.flamebearer.levels[t.i];if(!n)throw new Error(`Could not find level: '${t.i}'`);return{rangeMin:e.getBarOffset(n,t.j)/this.flamebearer.numTicks,rangeMax:(e.getBarOffset(n,t.j)+e.getBarTotal(n,t.j))/this.flamebearer.numTicks}},{zoom:a,focusedNode:r}=this;return a.match({Just:e=>r.match({Just:a=>{const r=n(a),o=t(e);return r.rangeMax-r.rangeMin<o.rangeMax-o.rangeMin?(console.warn("Focus is smaller than range, this shouldnt happen. Verify that the zoom is always bigger than the focus."),n(a)):t(e)},Nothing:()=>t(e)}),Nothing:()=>r.match({Just:e=>n(e),Nothing:()=>({rangeMin:0,rangeMax:1})})})}getCanvasWidth(){return"clientWidth"in this.canvas&&"number"==typeof this.canvas.clientWidth?this.canvas.clientWidth:this.canvas.width}isFocused(){return this.focusedNode.isJust}binarySearchLevel(e,t){const{ff:n}=this;let a=0,r=t.length-n.jStep;for(;a<=r;){const o=n.jStep*(a/n.jStep+r/n.jStep>>1),i=this.tickToX(n.getBarOffset(t,o)),l=this.tickToX(n.getBarOffset(t,o)+n.getBarTotal(t,o));if(i<=e&&l>=e)return l-i>5?o:-1;i>e?r=o-n.jStep:a=o+n.jStep}return-1}xyToBarIndex(e,t){if(e<0||t<0)throw new Error(`x and y must be bigger than 0. x = ${e}, y = ${t}`);if(this.isFocused()&&t<=Er)return{i:0,j:0};const n=this.isFocused()?t-Er:t,a=this.focusedNode.mapOrElse(()=>0,e=>e.i<=0?0:e.i),r=this.zoom.match({Just:()=>this.focusedNode.match({Just:()=>a,Nothing:()=>0}),Nothing:()=>this.focusedNode.match({Just:()=>a,Nothing:()=>0})}),o=Math.floor(n/jr)+r;if(o>=0&&o<this.flamebearer.levels.length){const t=this.flamebearer.levels[o];if(!t)throw new Error(`Could not find level: '${o}'`);return{i:o,j:this.binarySearchLevel(e,t)}}return{i:0,j:0}}parseXY(e,t){const n={x:e,y:t};return this.isWithinBounds(e,t)?N.of(n):N.nothing()}xyToBar(e,t){return this.parseXY(e,t).map(n=>{const{i:a,j:r}=this.xyToBarIndex(e,t);return{i:a,j:r,...this.xyToBarPosition(n),...this.xyToBarData(n)}})}}function uo(e){var t,n,a="";if("string"==typeof e||"number"==typeof e)a+=e;else if("object"==typeof e)if(Array.isArray(e)){var r=e.length;for(t=0;t<r;t++)e[t]&&(n=uo(e[t]))&&(a&&(a+=" "),a+=n)}else for(n in e)e[n]&&(a&&(a+=" "),a+=n);return a}function ho(){for(var e,t,n=0,a="",r=arguments.length;n<r;n++)(e=arguments[n])&&(t=uo(e))&&(a&&(a+=" "),a+=t);return a}var mo="NoData-module_noData__WuuID";function po(){return e("div",{"data-testid":"no-data",className:mo,children:e("span",{children:"No data available"})})}var go,vo,bo={},yo={};function wo(){return go||(go=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="arrow-rotate-right",n=[8635,"arrow-right-rotate","arrow-rotate-forward","redo"],a="f01e",r="M436.7 74.7L448 85.4 448 32c0-17.7 14.3-32 32-32s32 14.3 32 32l0 128c0 17.7-14.3 32-32 32l-128 0c-17.7 0-32-14.3-32-32s14.3-32 32-32l47.9 0-7.6-7.2c-.2-.2-.4-.4-.6-.6-75-75-196.5-75-271.5 0s-75 196.5 0 271.5 196.5 75 271.5 0c8.2-8.2 15.5-16.9 21.9-26.1 10.1-14.5 30.1-18 44.6-7.9s18 30.1 7.9 44.6c-8.5 12.2-18.2 23.8-29.1 34.7-100 100-262.1 100-362 0S-25 175 75 75c99.9-99.9 261.7-100 361.7-.3z";e.definition={prefix:"fas",iconName:t,icon:[512,512,n,a,r]},e.faArrowRotateRight=e.definition,e.prefix="fas",e.iconName=t,e.width=512,e.height=512,e.ligatures=n,e.unicode=a,e.svgPathData=r,e.aliases=n}(yo)),yo}function xo(){return vo||(vo=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t=wo();e.definition={prefix:t.prefix,iconName:t.iconName,icon:[t.width,t.height,t.aliases,t.unicode,t.svgPathData]},e.faRedo=e.definition,e.prefix=t.prefix,e.iconName=t.iconName,e.width=t.width,e.height=t.height,e.ligatures=t.aliases,e.unicode=t.unicode,e.svgPathData=t.svgPathData,e.aliases=t.aliases}(bo)),bo}var ko,No=xo(),So={};function To(){return ko||(ko=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="copy",n=[],a="f0c5",r="M192 0c-35.3 0-64 28.7-64 64l0 256c0 35.3 28.7 64 64 64l192 0c35.3 0 64-28.7 64-64l0-200.6c0-17.4-7.1-34.1-19.7-46.2L370.6 17.8C358.7 6.4 342.8 0 326.3 0L192 0zM64 128c-35.3 0-64 28.7-64 64L0 448c0 35.3 28.7 64 64 64l192 0c35.3 0 64-28.7 64-64l0-16-64 0 0 16-192 0 0-256 16 0 0-64-16 0z";e.definition={prefix:"fas",iconName:t,icon:[448,512,n,a,r]},e.faCopy=e.definition,e.prefix="fas",e.iconName=t,e.width=448,e.height=512,e.ligatures=n,e.unicode=a,e.svgPathData=r,e.aliases=n}(So)),So}var Co,_o=To(),Mo={};function Ro(){return Co||(Co=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="highlighter",n=[],a="f591",r="M315 315L473.4 99.9 444.1 70.6 229 229 315 315zm-187 5l0 0 0-71.7c0-15.3 7.2-29.6 19.5-38.6L420.6 8.4C428 2.9 437 0 446.2 0 457.6 0 468.5 4.5 476.6 12.6l54.8 54.8c8.1 8.1 12.6 19 12.6 30.5 0 9.2-2.9 18.2-8.4 25.6L334.4 396.5c-9 12.3-23.4 19.5-38.6 19.5l-71.7 0-25.4 25.4c-12.5 12.5-32.8 12.5-45.3 0l-50.7-50.7c-12.5-12.5-12.5-32.8 0-45.3L128 320zM7 466.3l51.7-51.7 70.6 70.6-19.7 19.7c-4.5 4.5-10.6 7-17 7L24 512c-13.3 0-24-10.7-24-24l0-4.7c0-6.4 2.5-12.5 7-17z";e.definition={prefix:"fas",iconName:t,icon:[576,512,n,a,r]},e.faHighlighter=e.definition,e.prefix="fas",e.iconName=t,e.width=576,e.height=512,e.ligatures=n,e.unicode=a,e.svgPathData=r,e.aliases=n}(Mo)),Mo}var Po,Fo,Io=Ro(),jo={},Eo={};function Do(){return Po||(Po=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="down-left-and-up-right-to-center",n=["compress-alt"],a="f422",r="M439.5 7c9.4-9.4 24.6-9.4 33.9 0l32 32c9.4 9.4 9.4 24.6 0 33.9l-87 87 39 39c6.9 6.9 8.9 17.2 5.2 26.2S450.2 240 440.5 240l-144 0c-13.3 0-24-10.7-24-24l0-144c0-9.7 5.8-18.5 14.8-22.2s19.3-1.7 26.2 5.2l39 39 87-87zM72.5 272l144 0c13.3 0 24 10.7 24 24l0 144c0 9.7-5.8 18.5-14.8 22.2s-19.3 1.7-26.2-5.2l-39-39-87 87c-9.4 9.4-24.6 9.4-33.9 0l-32-32c-9.4-9.4-9.4-24.6 0-33.9l87-87-39-39c-6.9-6.9-8.9-17.2-5.2-26.2S62.8 272 72.5 272z";e.definition={prefix:"fas",iconName:t,icon:[512,512,n,a,r]},e.faDownLeftAndUpRightToCenter=e.definition,e.prefix="fas",e.iconName=t,e.width=512,e.height=512,e.ligatures=n,e.unicode=a,e.svgPathData=r,e.aliases=n}(Eo)),Eo}function Bo(){return Fo||(Fo=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t=Do();e.definition={prefix:t.prefix,iconName:t.iconName,icon:[t.width,t.height,t.aliases,t.unicode,t.svgPathData]},e.faCompressAlt=e.definition,e.prefix=t.prefix,e.iconName=t.iconName,e.width=t.width,e.height=t.height,e.ligatures=t.aliases,e.unicode=t.unicode,e.svgPathData=t.svgPathData,e.aliases=t.aliases}(jo)),jo}var Lo=Bo();const Ao=e=>!!e&&"o"===e[0],Oo=R,zo=(e,t)=>!0===e||!(!e||!e[t]),$o=(e,t)=>"function"==typeof e?e(t):e,Vo="_szhsinMenu",Ho=(e,t)=>Object.defineProperty(t,Vo,{value:e}),Wo=(e,t)=>(t&&Object.keys(t).forEach(n=>{const a=e[n],r=t[n];e[n]="function"==typeof r&&a?(...e)=>{r(...e),a(...e)}:r}),e),Uo=e=>{for(;e;){if(!(e=e.parentNode)||e===document.body||!e.parentNode)return;const{overflow:t,overflowX:n,overflowY:a}=getComputedStyle(e);if(/auto|scroll|overlay|hidden/.test(t+a+n))return e}};function Jo(e,t){return{"aria-disabled":e||void 0,tabIndex:t?0:-1}}function Qo(e,t){for(let n=0;n<e.length;n++)if(e[n]===t)return n;return-1}const Xo=({block:e,element:t,modifiers:n,className:a})=>o(()=>{const r=t?`${e}__${t}`:e;let o=r;n&&Object.keys(n).forEach(e=>{const t=n[e];t&&(o+=` ${r}--${!0===t?e:`${e}-${t}`}`)});let i="function"==typeof a?a(n):a;return"string"==typeof i&&(i=i.trim(),i&&(o+=` ${i}`)),o},[e,t,n,a]),Yo="szh-menu",Zo=i(),qo=i({}),Go=i({}),Ko=i({}),ei=i({}),ti=i({}),ni=Object.freeze({ENTER:"Enter",ESC:"Escape",SPACE:" ",HOME:"Home",END:"End",LEFT:"ArrowLeft",RIGHT:"ArrowRight",UP:"ArrowUp",DOWN:"ArrowDown"}),ai=Object.freeze({RESET:0,SET:1,UNSET:2,INCREASE:3,DECREASE:4,FIRST:5,LAST:6,SET_INDEX:7}),ri=Object.freeze({CLICK:"click",CANCEL:"cancel",BLUR:"blur",SCROLL:"scroll"}),oi=Object.freeze({FIRST:"first",LAST:"last"}),ii=Object.freeze({entering:"opening",entered:"open",exiting:"closing",exited:"closed"}),li="absolute",si="none",ci={preventScroll:!0},fi=Ho("MenuButton",l(function({className:t,isOpen:n,disabled:a,children:r,...i},l){const s=o(()=>({open:n}),[n]);return e("button",{"aria-haspopup":!0,"aria-expanded":n,"aria-disabled":a||void 0,type:"button",disabled:a,...i,ref:l,className:Xo({block:"szh-menu-button",modifiers:s,className:t}),children:r})})),ui=({className:t,containerRef:n,containerProps:a,children:r,isOpen:i,theming:l,transition:s,onClose:c})=>{const f=zo(s,"item");return e("div",{...Wo({onKeyDown:({key:e})=>{if(e===ni.ESC)$o(c,{key:e,reason:ri.CANCEL})},onBlur:e=>{i&&!e.currentTarget.contains(e.relatedTarget)&&$o(c,{reason:ri.BLUR})}},a),className:Xo({block:"szh-menu-container",modifiers:o(()=>({theme:l,itemTransition:f}),[l,f]),className:t}),style:{position:"absolute",...a?.style},ref:n,children:r})},di=()=>{let e,t=0;return{toggle:e=>{e?t++:t--,t=Math.max(t,0)},on:(n,a,r)=>{t?e||(e=setTimeout(()=>{e=0,a()},n)):r?.()},off:()=>{e&&(clearTimeout(e),e=0)}}},hi=(e,t)=>Math.round(e)===t?e:t,mi=(e,t,n,a)=>{const r=(e=>{const t=e.getBoundingClientRect();return t.width=hi(t.width,e.offsetWidth),t.height=hi(t.height,e.offsetHeight),t})(t),o=e.getBoundingClientRect(),i=n===window?{left:0,top:0,right:document.documentElement.clientWidth,bottom:window.innerHeight}:n.getBoundingClientRect(),l=(e=>{if("string"!=typeof e)return{top:0,right:0,bottom:0,left:0};const t=e.trim().split(/\s+/,4).map(parseFloat),n=isNaN(t[0])?0:t[0],a=isNaN(t[1])?n:t[1];return{top:n,right:a,bottom:isNaN(t[2])?n:t[2],left:isNaN(t[3])?a:t[3]}})(a),s=e=>e+o.left-i.left-l.left,c=e=>e+o.left+r.width-i.right+l.right,f=e=>e+o.top-i.top-l.top,u=e=>e+o.top+r.height-i.bottom+l.bottom;return{menuRect:r,containerRect:o,getLeftOverflow:s,getRightOverflow:c,getTopOverflow:f,getBottomOverflow:u,confineHorizontally:e=>{let t=s(e);if(t<0)e-=t;else{const n=c(e);n>0&&(t=s(e-=n),t<0&&(e-=t))}return e},confineVertically:e=>{let t=f(e);if(t<0)e-=t;else{const n=u(e);n>0&&(t=f(e-=n),t<0&&(e-=t))}return e}}},pi=({anchorRect:e,containerRect:t,menuRect:n,placeLeftorRightY:a,placeLeftX:r,placeRightX:o,getLeftOverflow:i,getRightOverflow:l,confineHorizontally:s,confineVertically:c,arrowRef:f,arrow:u,direction:d,position:h})=>{let m,p,g,v=d,b=a;"initial"!==h&&(b=c(b),"anchor"===h&&(b=Math.min(b,e.bottom-t.top),b=Math.max(b,e.top-t.top-n.height))),"left"===v?(m=r,"initial"!==h&&(p=i(m),p<0&&(g=l(o),(g<=0||-p>g)&&(m=o,v="right")))):(m=o,"initial"!==h&&(g=l(m),g>0&&(p=i(r),(p>=0||-p<g)&&(m=r,v="left")))),"auto"===h&&(m=s(m));const y=u?(({arrowRef:e,menuY:t,anchorRect:n,containerRect:a,menuRect:r})=>{let o=n.top-a.top-t+n.height/2;const i=1.25*e.current.offsetHeight;return o=Math.max(i,o),o=Math.min(o,r.height-i),o})({menuY:b,arrowRef:f,anchorRect:e,containerRect:t,menuRect:n}):void 0;return{arrowY:y,x:m,y:b,computedDirection:v}},gi=({anchorRect:e,containerRect:t,menuRect:n,placeToporBottomX:a,placeTopY:r,placeBottomY:o,getTopOverflow:i,getBottomOverflow:l,confineHorizontally:s,confineVertically:c,arrowRef:f,arrow:u,direction:d,position:h})=>{let m,p,g,v="top"===d?"top":"bottom",b=a;"initial"!==h&&(b=s(b),"anchor"===h&&(b=Math.min(b,e.right-t.left),b=Math.max(b,e.left-t.left-n.width))),"top"===v?(m=r,"initial"!==h&&(p=i(m),p<0&&(g=l(o),(g<=0||-p>g)&&(m=o,v="bottom")))):(m=o,"initial"!==h&&(g=l(m),g>0&&(p=i(r),(p>=0||-p<g)&&(m=r,v="top")))),"auto"===h&&(m=c(m));const y=u?(({arrowRef:e,menuX:t,anchorRect:n,containerRect:a,menuRect:r})=>{let o=n.left-a.left-t+n.width/2;const i=1.25*e.current.offsetWidth;return o=Math.max(i,o),o=Math.min(o,r.width-i),o})({menuX:b,arrowRef:f,anchorRect:e,containerRect:t,menuRect:n}):void 0;return{arrowX:y,x:b,y:m,computedDirection:v}},vi="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement?u:d;function bi(e,t){"function"==typeof e?e(t):e.current=t}const yi=(e,t)=>o(()=>e?t?n=>{bi(e,n),bi(t,n)}:e:t,[e,t]),wi=({ariaLabel:n,menuClassName:a,menuStyle:r,arrow:i,arrowProps:l={},anchorPoint:u,anchorRef:p,containerRef:g,containerProps:v,externalRef:b,parentScrollingRef:y,align:w="start",direction:x="bottom",position:k="auto",overflow:N="visible",setDownOverflow:S,repositionFlag:T,captureFocus:C=!0,state:_,endTransition:M,isDisabled:R,menuItemFocus:F,gap:I=0,shift:j=0,children:E,onClose:D,focusProps:B,...L})=>{const[A,O]=s({x:-9999,y:-9999}),[z,$]=s({}),[V,H]=s(),[W,U]=s(x),[J]=s(di),[Q,X]=h(e=>e+1,1),{transition:Y,boundingBoxRef:Z,boundingBoxPadding:q,rootMenuRef:G,rootAnchorRef:K,scrollNodesRef:ee,reposition:te,viewScroll:ne,submenuCloseDelay:ae}=m(ti),{submenuCtx:re,reposSubmenu:oe=T}=m(Go),ie=c(),le=c(),se=c(!1),{hoverItem:ce,dispatch:fe,updateItems:ue}=(e=>{const[t,n]=s(),a=c({items:[],hoverIndex:-1,sorted:!1}).current,r=f((t,r)=>{const{items:o}=a;if(t)if(r)o.push(t);else{const a=o.indexOf(t);a>-1&&(o.splice(a,1),t.contains(document.activeElement)&&(e.current.focus(ci),n()))}else a.items=[];a.hoverIndex=-1,a.sorted=!1},[a,e]),o=f((t,r,o)=>{const{items:i,hoverIndex:l}=a,s=()=>{if(a.sorted)return;const t=e.current.querySelectorAll(".szh-menu__item");i.sort((e,n)=>Qo(t,e)-Qo(t,n)),a.sorted=!0};let c,f=-1;switch(t){case ai.RESET:break;case ai.SET:c=r;break;case ai.UNSET:c=e=>e===r?void 0:e;break;case ai.FIRST:s(),f=0,c=i[f];break;case ai.LAST:s(),f=i.length-1,c=i[f];break;case ai.SET_INDEX:s(),f=o,c=i[f];break;case ai.INCREASE:s(),f=l,f<0&&(f=i.indexOf(r)),f++,f>=i.length&&(f=0),c=i[f];break;case ai.DECREASE:s(),f=l,f<0&&(f=i.indexOf(r)),f--,f<0&&(f=i.length-1),c=i[f];break;default:if("production"!==process.env.NODE_ENV)throw new Error(`[React-Menu] Unknown hover action type: ${t}`)}c||(f=-1),n(c),a.hoverIndex=f},[e,a]);return{hoverItem:t,dispatch:o,updateItems:r}})(ie),de=Ao(_),he=zo(Y,"open"),me=zo(Y,"close"),pe=ee.current,ge=f(e=>{const t=ie.current,n=g.current;if(!t||!n)return;const a=p?p.current?.getBoundingClientRect():u?{left:u.x,right:u.x,top:u.y,bottom:u.y,width:0,height:0}:null;if(!a)return void("production"!==process.env.NODE_ENV&&console.warn("[React-Menu] Menu might not be positioned properly as one of the anchorRef or anchorPoint prop should be provided. If `anchorRef` is provided, the anchor must be mounted before menu is open."));pe.menu||(pe.menu=(Z?Z.current:Uo(G.current))||window);const r=mi(n,t,pe.menu,q);let{arrowX:o,arrowY:l,x:s,y:c,computedDirection:f}=(({arrow:e,align:t,direction:n,gap:a,shift:r,position:o,anchorRect:i,arrowRef:l,positionHelpers:s})=>{const{menuRect:c,containerRect:f}=s,u="left"===n||"right"===n;let d=u?a:r,h=u?r:a;if(e){const e=l.current;u?d+=e.offsetWidth:h+=e.offsetHeight}const m=i.left-f.left-c.width-d,p=i.right-f.left+d,g=i.top-f.top-c.height-h,v=i.bottom-f.top+h;let b,y;"end"===t?(b=i.right-f.left-c.width,y=i.bottom-f.top-c.height):"center"===t?(b=i.left-f.left-(c.width-i.width)/2,y=i.top-f.top-(c.height-i.height)/2):(b=i.left-f.left,y=i.top-f.top),b+=d,y+=h;const w={...s,anchorRect:i,placeLeftX:m,placeRightX:p,placeLeftorRightY:y,placeTopY:g,placeBottomY:v,placeToporBottomX:b,arrowRef:l,arrow:e,direction:n,position:o};switch(n){case"left":case"right":return pi(w);default:return gi(w)}})({arrow:i,align:w,direction:x,gap:I,shift:j,position:k,anchorRect:a,arrowRef:le,positionHelpers:r});const{menuRect:d}=r,h=d.height;if(!e&&"visible"!==N){const{getTopOverflow:e,getBottomOverflow:t}=r;let n,a;const o=t(c);if(o>0)n=h-o,a=o;else{const t=e(c);t<0&&(n=h+t,a=0-t,n>=0&&(c-=t))}n>=0&&H({height:n,overflowAmt:a})}i&&$({x:o,y:l}),O({x:s,y:c}),U(f)},[i,w,q,x,I,j,k,N,u,p,g,Z,G,pe]);vi(()=>{de&&(ge(),se.current&&X()),se.current=de},[de,ge,oe]),vi(()=>{V&&!S&&(ie.current.scrollTop=0)},[V,S]),vi(()=>ue,[ue]),d(()=>{let{menu:e}=pe;if(!de||!e)return;if(e=e.addEventListener?e:window,!pe.anchors){pe.anchors=[];let t=Uo(K&&K.current);for(;t&&t!==e;)pe.anchors.push(t),t=Uo(t)}let t=ne;if(pe.anchors.length&&"initial"===t&&(t="auto"),"initial"===t)return;const n=()=>{"auto"===t?Oo(()=>ge(!0)):$o(D,{reason:ri.SCROLL})},a=pe.anchors.concat("initial"!==ne?e:[]);return a.forEach(e=>e.addEventListener("scroll",n)),()=>a.forEach(e=>e.removeEventListener("scroll",n))},[K,pe,de,D,ne,ge]);const ve=!!V&&V.overflowAmt>0;d(()=>{if(ve||!de||!y)return;const e=()=>Oo(ge),t=y.current;return t.addEventListener("scroll",e),()=>t.removeEventListener("scroll",e)},[de,ve,y,ge]),d(()=>{if(!de||"function"!=typeof ResizeObserver||"initial"===te)return;const e=[],t=new ResizeObserver(t=>t.forEach(({target:t})=>{e.indexOf(t)<0?e.push(t):P(()=>{ge(),X()})})),n={box:"border-box"};t.observe(ie.current,n);const a=p?.current;return a&&t.observe(a,n),()=>t.disconnect()},[de,te,p,ge]),d(()=>{if(!de)return fe(ai.RESET),void(me||H());const{position:e,alwaysUpdate:t}=F||{},n=()=>{e===oi.FIRST?fe(ai.FIRST):e===oi.LAST?fe(ai.LAST):e>=-1&&fe(ai.SET_INDEX,void 0,e)};if(t)n();else if(C){const e=setTimeout(()=>{const e=ie.current;e&&!e.contains(document.activeElement)&&(e.focus(ci),n())},he?170:100);return()=>clearTimeout(e)}},[de,he,me,C,F,fe]);const be=o(()=>({isParentOpen:de,submenuCtx:J,dispatch:fe,updateItems:ue}),[de,J,fe,ue]);let ye,we;V&&(S?we=V.overflowAmt:ye=V.height);const xe=o(()=>({reposSubmenu:Q,submenuCtx:J,overflow:N,overflowAmt:we,parentMenuRef:ie,parentDir:W}),[Q,J,N,we,W]),ke=ye>=0?{maxHeight:ye,overflow:N}:void 0,Ne=o(()=>({state:_,align:w,dir:W}),[_,w,W]),Se=o(()=>({dir:W}),[W]),Te=Xo({block:Yo,element:"arrow",modifiers:Se,className:l.className}),Ce=t("ul",{role:"menu","aria-label":n,...Jo(R),...Wo({onPointerEnter:re?.off,onPointerMove:e=>{e.stopPropagation(),J.on(ae,()=>{fe(ai.RESET),ie.current.focus(ci)})},onPointerLeave:e=>{e.target===e.currentTarget&&J.off()},onKeyDown:e=>{switch(e.key){case ni.HOME:fe(ai.FIRST);break;case ni.END:fe(ai.LAST);break;case ni.UP:fe(ai.DECREASE,ce);break;case ni.DOWN:fe(ai.INCREASE,ce);break;case ni.SPACE:return void(e.target&&-1!==e.target.className.indexOf(Yo)&&e.preventDefault());default:return}e.preventDefault(),e.stopPropagation()},onAnimationEnd:()=>{"closing"===_&&H(),$o(M)}},L),ref:yi(b,ie),className:Xo({block:Yo,modifiers:Ne,className:a}),style:{...r,...ke,margin:0,display:"closed"===_?"none":void 0,position:li,left:A.x,top:A.y},children:[i&&e("li",{"aria-hidden":!0,...l,className:Te,style:{display:"block",position:li,left:z.x,top:z.y,...l.style},ref:le}),e(Go.Provider,{value:xe,children:e(qo.Provider,{value:be,children:e(Zo.Provider,{value:ce,children:$o(E,Ne)})})})]});return v?e(ui,{...v,isOpen:de,children:Ce}):Ce},xi=l(function({"aria-label":t,className:n,containerProps:a,initialMounted:r,unmountOnClose:i,transition:l,transitionTimeout:s,boundingBoxRef:f,boundingBoxPadding:u,reposition:d="auto",submenuOpenDelay:h=300,submenuCloseDelay:m=150,viewScroll:p="initial",portal:g,theming:v,onItemClick:b,...y},w){const x=c(null),k=c({}),{anchorRef:N,state:S,onClose:T}=y,C=o(()=>({initialMounted:r,unmountOnClose:i,transition:l,transitionTimeout:s,boundingBoxRef:f,boundingBoxPadding:u,rootMenuRef:x,rootAnchorRef:N,scrollNodesRef:k,reposition:d,viewScroll:p,submenuOpenDelay:h,submenuCloseDelay:m}),[r,i,l,s,N,f,u,d,p,h,m]),_=o(()=>({handleClick(e,t){e.stopPropagation||$o(b,e);let n=e.keepOpen;void 0===n&&(n=t&&e.key===ni.SPACE),n||$o(T,{value:e.value,key:e.key,reason:ri.CLICK})},handleClose(e){$o(T,{key:e,reason:ri.CLICK})}}),[b,T]);if(!S)return null;const M=e(ti.Provider,{value:C,children:e(Ko.Provider,{value:_,children:e(wi,{...y,ariaLabel:t||"Menu",externalRef:w,containerRef:x,containerProps:{className:n,containerRef:x,containerProps:a,theming:v,transition:l,onClose:T}})})});return!0===g&&"undefined"!=typeof document?F(M,document.body):g?g.target?F(M,g.target):g.stablePosition?null:M:M}),ki=["preEnter","entering","entered","preExit","exiting","exited","unmounted"],Ni=e=>({_s:e,status:ki[e],isEnter:e<3,isMounted:6!==e,isResolved:2===e||e>4}),Si=e=>e?6:5,Ti=(e,t,n,a,r)=>{clearTimeout(a.current);const o=Ni(e);t(o),n.current=o,r&&r({current:o})},Ci=({enter:e=!0,exit:t=!0,preEnter:n,preExit:a,timeout:r,initialEntered:o,mountOnEnter:i,unmountOnExit:l,onStateChange:u}={})=>{const[d,h]=s(()=>Ni(o?2:Si(i))),m=c(d),p=c(),[g,v]=(e=>"object"==typeof e?[e.enter,e.exit]:[e,e])(r),b=f(()=>{const e=((e,t)=>{switch(e){case 1:case 0:return 2;case 4:case 3:return Si(t)}})(m.current._s,l);e&&Ti(e,h,m,p,u)},[u,l]);return[d,f(r=>{const o=e=>{switch(Ti(e,h,m,p,u),e){case 1:g>=0&&(p.current=setTimeout(b,g));break;case 4:v>=0&&(p.current=setTimeout(b,v));break;case 0:case 3:p.current=((e,t)=>setTimeout(()=>{isNaN(document.body.offsetTop)||e(t+1)},0))(o,e)}},i=m.current.isEnter;"boolean"!=typeof r&&(r=!i),r?!i&&o(e?n?0:1:2):i&&o(t?a?3:4:Si(l))},[b,u,e,t,n,a,g,v,l]),b]},_i=({initialOpen:e,initialMounted:t,unmountOnClose:n,transition:a,transitionTimeout:r=500,onMenuChange:o}={})=>{const i=zo(a,"open"),l=zo(a,"close"),[{status:s},c,u]=Ci({initialEntered:e,mountOnEnter:!t,unmountOnExit:n,timeout:r,enter:i,exit:l,onStateChange:f(({current:{isEnter:e,isResolved:t}})=>{!o||e&&i&&t||!e&&l&&t||o({open:e})},[o,i,l])});return[{state:ii[s],endTransition:u},c]},Mi=parseInt(b)<19,Ri=l(function({"aria-label":n,captureFocus:a,initialOpen:r,menuButton:o,instanceRef:i,onMenuChange:l,...u},d){const[h,m,b]=(e=>{const[t,n]=_i(e),[a,r]=s();return[{menuItemFocus:a,...t},n,(e,t)=>{r({position:e,alwaysUpdate:t}),n(!0)}]})({...u,onMenuChange:l}),{state:y}=h,w=Ao(y),x=c(null),k=((e,t)=>{if("production"!==process.env.NODE_ENV&&"function"!=typeof t)throw new Error("[React-Menu] useClick/useHover requires a function in the second parameter.");const[n]=s({});return{onMouseDown:()=>{n.v=e&&"closed"!==e},onClick:e=>n.v?n.v=!1:t(!0,e)}})(y,(e,t)=>b(t.detail?void 0:oi.FIRST)),N=f(e=>{m(!1),e.key&&x.current.focus()},[m]),S=$o(o,{open:w});if(!S||!S.type)throw new Error("Menu requires a menuButton prop.");const T={...Wo({onKeyDown:e=>{switch(e.key){case ni.UP:b(oi.LAST);break;case ni.DOWN:b(oi.FIRST);break;default:return}e.preventDefault()},...k},S.props),ref:yi(Mi?S.ref:S.props.ref,x)};"MenuButton"===S.type[Vo]&&(T.isOpen=w);const C=v(S,T);return p(i,()=>({openMenu:b,closeMenu:()=>m(!1)})),t(g,{children:[C,e(xi,{...u,...h,"aria-label":n||("string"==typeof S.props.children?S.props.children:"Menu"),anchorRef:x,ref:d,onClose:N})]})}),Pi=(t,n)=>{const a=y(n),r=l((t,n)=>{const r=c(null);return e(a,{...t,itemRef:r,externalRef:n,isHovering:m(Zo)===r.current})});return r.displayName=`WithHovering(${t})`,r},Fi=(e,t,n,a)=>{const[r,o,i]=(e=>{const[t,n]=s(!1);return d(()=>{!e&&n(!1)},[e]),[t,()=>!t&&n(!0),()=>n(!1)]})(n),{submenuCloseDelay:l}=m(ti),{isParentOpen:c,submenuCtx:f,dispatch:u,updateItems:h}=m(qo),p=()=>{!n&&!a&&u(ai.SET,e.current)},g=()=>{!a&&u(ai.UNSET,e.current)};return((e,t,n)=>{vi(()=>{if("production"!==process.env.NODE_ENV&&!n)throw new Error(`[React-Menu] This menu item or submenu should be rendered under a menu: ${t.current.outerHTML}`);if(e)return;const a=t.current;return n(a,!0),()=>{n(a)}},[e,t,n])})(a,e,h),d(()=>{n&&c&&t.current&&t.current.focus()},[t,n,c]),{mouseOver:r,setHover:p,onBlur:e=>{n&&!e.currentTarget.contains(e.relatedTarget)&&g()},onPointerMove:e=>{a||(e.stopPropagation(),o(),f.on(l,p,p))},onPointerLeave:(e,t)=>{i(),f.off(),!t&&g()}}},Ii=Pi("MenuItem",function({className:t,value:n,href:a,type:r,checked:i,disabled:l,children:s,onClick:c,isHovering:f,itemRef:u,externalRef:d,...h}){const p=!!l,{mouseOver:g,setHover:v,...b}=Fi(u,u,f,p),y=m(Ko),w=m(ei),x="radio"===r,k="checkbox"===r,N=!(!a||p||x||k),S=x?w.value===n:!!k&&!!i,T=e=>{if(p)return e.stopPropagation(),void e.preventDefault();const t={value:n,syntheticEvent:e};void 0!==e.key&&(t.key=e.key),k&&(t.checked=!S),x&&(t.name=w.name),$o(c,t),x&&$o(w.onRadioChange,t),y.handleClick(t,k||x)},C=o(()=>({type:r,disabled:p,hover:g||f,checked:S,anchor:N}),[r,p,g,f,S,N]),_=Wo({...b,onPointerDown:v,onKeyDown:e=>{if(f)switch(e.key){case ni.ENTER:e.preventDefault();case ni.SPACE:N?u.current.click():T(e)}},onClick:T},h),M={role:x?"menuitemradio":k?"menuitemcheckbox":"menuitem","aria-checked":x||k?S:void 0,...Jo(p,f),..._,ref:yi(d,u),className:Xo({block:Yo,element:"item",modifiers:C,className:t}),children:o(()=>$o(s,C),[s,C])};return e("li",N?{role:si,children:e("a",{href:a,...M})}:{...M})}),ji=y(l(function({className:t,...n},a){return e("li",{role:si,...n,ref:a,className:Xo({block:Yo,element:"header",className:t})})}));var Ei="canvas-module_canvas__Iiaz4",Di="canvas-module_textCanvas__eFxM4",Bi="Highlight-module_highlight__1VV-X";function Li(t){const{canvasRef:n,barHeight:r,xyToHighlightData:o,zoom:i}=t,[l,s]=a.useState({height:"0px",visibility:"hidden"}),c=a.useRef(null),f=a.useRef(null),u=a.useRef(null);a.useEffect(()=>{s({height:"0px",visibility:"hidden"})},[i]);const d=e=>{const t=c.current;if(!t)return void s(e);const n=u.current;n&&n.left===e.left&&n.top===e.top&&n.width===e.width&&n.visibility===e.visibility||(u.current=e,t.style.visibility=String(e.visibility||""),void 0!==e.left&&(t.style.left=String(e.left)),void 0!==e.top&&(t.style.top=String(e.top)),void 0!==e.width&&(t.style.width=String(e.width)),void 0!==e.height&&(t.style.height=String(e.height)))},h=e=>{f.current&&cancelAnimationFrame(f.current);const t=e.offsetX,n=e.offsetY;f.current=requestAnimationFrame(()=>{const e=o(t,n);if(e.isJust){const t=e.value;d({visibility:"visible",height:`${r}px`,...t})}else m()})},m=()=>{d({...u.current||{},visibility:"hidden"})};return a.useEffect(()=>{const e=n.current;return e?(e.addEventListener("mousemove",h),e.addEventListener("mouseout",m),()=>{e.removeEventListener("mousemove",h),e.removeEventListener("mouseout",m),f.current&&cancelAnimationFrame(f.current)}):()=>{}},[n.current,h,m]),e("div",{ref:c,className:Bi,style:l,"data-testid":"flamegraph-highlight"})}var Ai="ContextMenuHighlight-module_highlightContextMenu__WI1nK";const Oi={height:"0px",visibility:"hidden"};function zi(t){const{node:n,barHeight:r}=t,[o,i]=a.useState(Oi);return a.useEffect(()=>{n.match({Nothing:()=>i(Oi),Just:e=>i({visibility:"visible",height:`${r}px`,...e})})},[n]),e("div",{className:Ai,style:o,"data-testid":"flamegraph-highlight-contextmenu"})}const $i={name:"Default",goodColor:T.rgb(0,170,0),neutralColor:T.rgb(148,142,142),badColor:T.rgb(200,0,0),colors:[T.hsl(24,69,60),T.hsl(34,65,65),T.hsl(194,52,61),T.hsl(163,45,55),T.hsl(211,48,60),T.hsl(246,40,65),T.hsl(305,63,79),T.hsl(47,100,73),T.rgb(183,219,171),T.rgb(244,213,152),T.rgb(78,146,249),T.rgb(249,186,143),T.rgb(242,145,145),T.rgb(130,181,216),T.rgb(229,168,226),T.rgb(174,162,224),T.rgb(154,196,138),T.rgb(242,201,109),T.rgb(101,197,219),T.rgb(249,147,78),T.rgb(234,100,96),T.rgb(81,149,206),T.rgb(214,131,206),T.rgb(128,110,183)]},Vi={...$i,name:"Color Blind",goodColor:T.rgb(26,133,255),neutralColor:T.rgb(148,142,142),badColor:T.rgb(220,50,32)};function Hi(){return t("svg",{id:"Layer_1",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 30 30",children:[e("defs",{}),e("path",{style:{fill:"#7d7d7f"},d:"M5,19.56c0,5.22,3.54,9.44,7.92,9.44h3.17c4.37,0,7.92-4.23,7.92-9.44v-7.56H5v7.56Z"}),e("path",{style:{fill:"#7d7d7f"},d:"M14,1h-.82c-4.52,0-8.18,3.73-8.18,8.33v1.67H14V1Z"}),e("path",{d:"M15.82,1h-.82V11h9v-1.67c0-4.6-3.66-8.33-8.18-8.33Z"})]})}function Wi(){return t("svg",{id:"Layer_1",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 30 30",children:[e("defs",{}),e("path",{style:{fill:"#7d7d7f"},d:"M24,19.56c0,5.22-3.54,9.44-7.92,9.44h-3.17c-4.37,0-7.92-4.23-7.92-9.44v-7.56H24v7.56Z"}),e("path",{style:{fill:"#7d7d7f"},d:"M15,1h.82c4.52,0,8.18,3.73,8.18,8.33v1.67H15V1Z"}),e("path",{d:"M13.18,1h.82V11H5v-1.67c0-4.6,3.66-8.33,8.18-8.33Z"})]})}var Ui={tooltip:"Tooltip-module_tooltip__NMZ65",flamegraphDiffTooltip:"Tooltip-module_flamegraphDiffTooltip__Z983o",tooltipName:"Tooltip-module_tooltipName__y4Qs3",functionName:"Tooltip-module_functionName__z9LHO",tooltipTable:"Tooltip-module_tooltipTable__ct3pq",clickInfo:"Tooltip-module_clickInfo__Utux5"};const Ji={location:"Location",self:"Self",total:"Total",baseline:"Baseline",comparison:"Comparison",diff:"Diff",noItemsFound:"No items found",diffNew:"new",diffRemoved:"removed",tooltipSamples:"Samples:",tooltipUnitTitles:{objects:{percent:"% of objects in RAM",formattedValue:"Objects in RAM",total:"% of total RAM"},goroutines:{percent:"% of goroutines",formattedValue:"Goroutines",total:"% of total goroutines"},bytes:{percent:"% of RAM",formattedValue:"RAM",total:"% of total bytes"},samples:{percent:"Share of CPU",formattedValue:"CPU Time",total:"% of total CPU"},lock_nanoseconds:{percent:"% of Time spent",formattedValue:"Time",total:"% of total seconds"},lock_samples:{percent:"% of contended locks",formattedValue:"Contended locks",total:"% of total locks"},trace_samples:{percent:"% of time",formattedValue:"Samples",total:"% of total samples"},exceptions:{percent:"% of thrown exceptions",formattedValue:"Thrown exceptions",total:"% of total thrown exceptions"},unknown:{percent:"Percentage",formattedValue:"Units",total:"% of total units"}},resetView:"Reset View",collapseNodesAbove:"Collapse nodes above",copyFunctionName:"Copy function name",highlightSimilarNodes:"Highlight similar nodes",clearHighlight:"Clear highlight",openInSandwichView:"Open in sandwich view",showTextTailFirst:"Show text tail first",showTextHeadFirst:"Show text head first",headFirst:"Head first",tailFirst:"Tail first",clickToHighlightNode:"Click to highlight node in flamegraph",rightClickForMoreNodeOptions:"Right click for more node viewing options",viewTable:"Table",viewTableAndFlamegraph:"Table and Flamegraph",viewFlamegraph:"Flamegraph",viewSandwich:"Sandwich",viewGraphviz:"GraphViz",more:"More",diffLegendRemovedLabel:"(-) Removed",diffLegendAddedLabel:"Added (+)",diffLegendSelectPalette:"Select a palette",paletteDefaultName:"Default",paletteColorBlindName:"Color Blind",paletteDefaultDesc:"(green to red)",paletteColorBlindDesc:"(blue to red)",searchPlaceholder:"Search...",syncSearchBars:"Sync Search Bars",unsyncSearchBars:"Unsync Search Bars",focusOnThisFunction:"Focus on this function",tableDoubleClickToFocus:"Double-click to focus in flamegraph",tableRightClickForOptions:"Right-click for more options",collapsedLevelsSingular:"total (1 level collapsed)",collapsedLevelsPlural:"total ({n} levels collapsed)",ofTotal:"of total",clearFocus:"Clear focus",sampleCountFormat:[{value:1e15,label:"Quad"},{value:1e12,label:"Tri"},{value:1e9,label:"B"},{value:1e6,label:"M"},{value:1e3,label:"K"}]},Qi={...Ji,location:"位置",self:"自身",total:"总计",baseline:"基线",comparison:"对比",diff:"差异",noItemsFound:"没有找到任何条目",diffNew:"新增",diffRemoved:"移除",tooltipSamples:"样本数:",tooltipUnitTitles:{objects:{percent:"RAM 中对象占比",formattedValue:"RAM 中对象数",total:"占总 RAM 的百分比"},goroutines:{percent:"协程占比",formattedValue:"协程数量",total:"占协程总数的百分比"},bytes:{percent:"RAM 占比",formattedValue:"RAM",total:"占总字节数的百分比"},samples:{percent:"CPU 占比",formattedValue:"CPU 时间",total:"占总 CPU 的百分比"},lock_nanoseconds:{percent:"耗时占比",formattedValue:"时间",total:"占总秒数的百分比"},lock_samples:{percent:"锁竞争事件占比",formattedValue:"锁竞争事件数",total:"占锁竞争总数的百分比"},trace_samples:{percent:"时间占比",formattedValue:"样本数",total:"占样本总数的百分比"},exceptions:{percent:"异常抛出占比",formattedValue:"异常数",total:"占异常总数的百分比"},unknown:{percent:"百分比",formattedValue:"单位",total:"占单位总量的百分比"}},resetView:"重置视图",collapseNodesAbove:"收起上方节点",copyFunctionName:"复制函数名",highlightSimilarNodes:"高亮相似节点",clearHighlight:"清除高亮",openInSandwichView:"在 sandwich 视图中查看",showTextTailFirst:"显示文本尾部优先",showTextHeadFirst:"显示文本头部优先",headFirst:"从头部开始显示",tailFirst:"从尾部开始显示",clickToHighlightNode:"点击火焰图节点高亮",rightClickForMoreNodeOptions:"右键查看更多节点选项",viewTable:"表格",viewTableAndFlamegraph:"表格 + 火焰图",viewFlamegraph:"火焰图",viewSandwich:"三明治视图",viewGraphviz:"调用图 (GraphViz)",more:"更多",diffLegendRemovedLabel:"(-) 减少",diffLegendAddedLabel:"增加 (+)",diffLegendSelectPalette:"选择颜色方案",paletteDefaultName:"默认",paletteColorBlindName:"色盲",paletteDefaultDesc:"(绿色 → 红色)",paletteColorBlindDesc:"(蓝色 → 红色)",searchPlaceholder:"搜索...",syncSearchBars:"同步搜索栏",unsyncSearchBars:"取消同步搜索栏",focusOnThisFunction:"聚焦到此函数",tableDoubleClickToFocus:"双击可聚焦到火焰图",tableRightClickForOptions:"右键查看更多选项",collapsedLevelsSingular:"总计(已折叠 1 层)",collapsedLevelsPlural:"总计(已折叠 {n} 层)",ofTotal:"占总量",clearFocus:"清除聚焦",sampleCountFormat:[{value:1e12,label:"兆"},{value:1e8,label:"亿"},{value:1e4,label:"万"},{value:1e3,label:"千"}]},Xi=i(Ji),Yi=Xi,Zi=({messages:t,children:n})=>{const r=a.useMemo(()=>{var e;return{...Ji,...t,tooltipUnitTitles:{...Ji.tooltipUnitTitles,...null!==(e=null==t?void 0:t.tooltipUnitTitles)&&void 0!==e?e:{}}}},[t]);return e(Xi.Provider,{value:r,children:n})},qi=()=>m(Xi);function Gi(e){if(!e)return null;const t=e.replace(/,/g,"").trim();if(!t)return null;const n=Number(t);return Number.isFinite(n)?n:null}function Ki(e,t){if(!e||!t)return;const n=e.trim().replace(/\u2212/g,"-");return n&&"0"!==n?n.startsWith("+")?t.badColor.rgb().string():n.startsWith("-")?t.goodColor.rgb().string():void 0:void 0}function el(e,t,n){return n<t?t:Math.max(t,Math.min(n,e))}function tl(e,t,n,a){const r=window.innerWidth,o=window.innerHeight,i=Math.max(0,n||0),l=Math.max(0,a||0);let s=e+12,c=t+20;return s+i+8>r&&(s=e-i-12),c+l+8>o&&(c=t-l-20),s=el(s,8,r-i-8),c=el(c,8,o-l-8),{left:s,top:c}}function nl({shouldShowFooter:r=!0,shouldShowTitle:o=!0,dataSourceRef:i,clickInfoSide:l,setTooltipContent:h,palette:m}){const p=c(null),g=c(null),v=c(null),b=c(null),[y,w]=a.useState({title:{text:"",diff:{text:"",color:""}},tooltipData:[]}),[x,k]=s(),N=()=>{k({visibility:"hidden"}),w({title:{text:"",diff:{text:"",color:""}},tooltipData:[]})},S=f(e=>{v.current&&cancelAnimationFrame(v.current);const t=e.clientX,n=e.clientY;v.current=requestAnimationFrame(()=>{if(!p.current)throw new Error("Missing tooltipElement");g.current={x:t,y:n},h(w,N,e);const a=p.current.clientWidth||0,r=p.current.clientHeight||0,{left:o,top:i}=tl(t,n,a,r);k({top:i,left:o,visibility:"visible"})})},[h]);return d(()=>{const e=i.current;if(!e)return()=>{};const t=()=>{N()},n=t=>{e.contains(t.target)||N()};return e.addEventListener("mousemove",S),e.addEventListener("mouseout",N),e.addEventListener("mouseleave",t),window.addEventListener("mousemove",n,{passive:!0}),window.addEventListener("blur",t),()=>{e.removeEventListener("mousemove",S),e.removeEventListener("mouseout",N),e.removeEventListener("mouseleave",t),window.removeEventListener("mousemove",n),window.removeEventListener("blur",t),v.current&&cancelAnimationFrame(v.current)}},[i.current,S]),u(()=>{if(!p.current)return;if(!g.current)return;if(0===y.tooltipData.length)return;const{x:e,y:t}=g.current,n=p.current.getBoundingClientRect(),a=n.width,r=n.height,o=b.current;if(o&&Math.abs(o.w-a)<1&&Math.abs(o.h-r)<1)return;b.current={w:a,h:r};const{left:i,top:l}=tl(e,t,a,r);k(e=>e&&e.left===i&&e.top===l&&"visible"===e.visibility?e:{...e||{},left:i,top:l,visibility:"visible"})},[y.tooltipData.length,y.title.text]),e("div",{"data-testid":"tooltip",className:ho(Ui.tooltip,{[Ui.flamegraphDiffTooltip]:y.tooltipData.length>1}),style:{...x,textAlign:"center"},ref:p,children:y.tooltipData.length>0&&t(n,{children:[o&&e("div",{className:Ui.tooltipName,"data-testid":"tooltip-title",children:y.title.text}),e("div",{className:Ui.functionName,"data-testid":"tooltip-function-name",children:y.title.text}),y.title.diff.text.length>0?e(al,{data:y.tooltipData,diff:y.title.diff,palette:m}):e(al,{data:y.tooltipData,palette:m}),r&&e(rl,{clickInfoSide:l})]})})}function al({data:a,diff:r,palette:o}){const i=qi(),[l,s]=a,c="Location"!==i.location;if(!l)return null;let f;switch(l.tooltipType){case"flamegraph":f=()=>{const a=s&&function(e,t){const n=Br(e),a=Br(t);if(!n||!a)return"";const r=a.value-n.value;if(0===r)return"0";const o=r>0?"+":"-",i=Math.abs(r);let l;l=i>=100?i.toFixed(0):i>=10?i.toFixed(1):i.toFixed(2);const s=n.unit||a.unit;return s?`${o}${l} ${s}`:`${o}${l}`}(l.formattedValue,s.formattedValue),f=Lr(a,c),u=s&&function(e,t){const n=Gi(e),a=Gi(t);if(null==n||null==a)return"";const r=a-n;return 0===r?"0":`${r>0?"+":"-"}${Math.abs(r).toLocaleString()}`}(l.samples,s.samples),d=Lr(l.formattedValue,c),h=Lr(null==s?void 0:s.formattedValue,c),m=null==r?void 0:r.color,p=Ki(a,o),g=Ki(u,o);return t(n,{children:[s&&e("thead",{children:t("tr",{children:[e("th",{}),e("th",{children:i.baseline}),e("th",{children:i.comparison}),e("th",{children:i.diff})]})}),t("tbody",{children:[t("tr",{children:[t("td",{children:[i.tooltipUnitTitles[l.units].percent,":"]}),e("td",{children:l.percent}),s&&t(n,{children:[e("td",{children:s.percent}),e("td",{style:{textAlign:"center"},children:r&&e("span",{"data-testid":"tooltip-diff",style:{color:m},children:r.text})})]})]}),t("tr",{children:[t("td",{children:[i.tooltipUnitTitles[l.units].formattedValue,":"]}),e("td",{children:d}),s&&t(n,{children:[e("td",{children:h}),e("td",{style:{textAlign:"center"},children:f&&e("span",{"data-testid":"tooltip-time-diff",style:p?{color:p}:void 0,children:f})})]})]}),t("tr",{children:[e("td",{children:i.tooltipSamples}),e("td",{children:l.samples}),s&&t(n,{children:[e("td",{children:s.samples}),e("td",{style:{textAlign:"center"},children:u&&e("span",{"data-testid":"tooltip-samples-diff",style:g?{color:g}:void 0,children:u})})]})]})]})]})};break;case"table":f=()=>t(n,{children:[e("thead",{children:t("tr",{children:[e("td",{}),t("td",{children:[i.self," (",i.tooltipUnitTitles[l.units].total,")"]}),t("td",{children:[i.total," (",i.tooltipUnitTitles[l.units].total,")"]})]})}),e("tbody",{children:t("tr",{children:[t("td",{children:[i.tooltipUnitTitles[l.units].formattedValue,":"]}),e("td",{children:l.self}),e("td",{children:l.total})]})})]});break;default:f=()=>null}return e("table",{"data-testid":"tooltip-table",className:ho(Ui.tooltipTable,{[Ui[`${l.tooltipType}${s?"Diff":""}`]]:l.tooltipType}),style:{textAlign:"center",margin:"0 auto"},children:f()})}function rl({clickInfoSide:a}){const r=qi();let o;switch(a){case"right":o=t(n,{children:[e(Hi,{}),e("span",{children:r.rightClickForMoreNodeOptions})]});break;case"left":o=t(n,{children:[e(Wi,{}),e("span",{children:r.clickToHighlightNode})]});break;default:o=e(n,{})}return e("div",{"data-testid":"tooltip-footer",className:Ui.clickInfo,children:o})}function ol(t){const{format:n,canvasRef:a,xyToData:r,numTicks:o,sampleRate:i,units:l,leftTicks:s,rightTicks:c,palette:u}=t,d=qi(),h=f((e,t,a)=>{const f=$r(o,i,l),h=r(a.offsetX,a.offsetY);let m;var p;if(h.isJust)switch(m=h.value,m.format){case"single":{const t={percent:(p=m.total/o,`${Or(p)}%`),samples:"trace_samples"===l?"":Dr(m.total),units:l,formattedValue:f.format(m.total,i),tooltipType:"flamegraph"};e({title:{text:m.name,diff:{text:"",color:""}},tooltipData:[t]});break}case"double":{if("single"===n)throw new Error("props format is 'single' but it has been mapped to 'double'");const t=il({formatter:f,sampleRate:i,totalLeft:m.totalLeft,leftTicks:s,totalRight:m.totalRight,rightTicks:c,title:m.name,units:l},u,d);e({title:t.title,tooltipData:t.tooltipData});break}default:throw new Error(`Unsupported format: '${m.format}'`)}else t()},[o,i,l,s,c,u,r,n,d]);return e(nl,{dataSourceRef:a,clickInfoSide:"right",setTooltipContent:h,palette:u})}function il({formatter:e,sampleRate:t,totalLeft:n,leftTicks:a,totalRight:r,rightTicks:o,title:i,units:l},s=$i,c){var f,u;const d=o>0?r/o:0,h=Or(a>0?n/a:0),m=Or(d),p={percent:`${h}%`,samples:Dr(n),units:l,formattedValue:e.format(n,t),tooltipType:"flamegraph"},g={percent:`${m}%`,samples:Dr(r),units:l,formattedValue:e.format(r,t),tooltipType:"flamegraph"};let v=zr(h,m);Number.isFinite(v)||(v=0);let b="";v>0?b=s.badColor.rgb().string():v<0&&(b=s.goodColor.rgb().string());let y="";return 0===n&&r>0?y=null!==(f=null==c?void 0:c.diffNew)&&void 0!==f?f:"新增":0===r&&n>0?y=null!==(u=null==c?void 0:c.diffRemoved)&&void 0!==u?u:"移除":0===v?y="0%":v>0?y=`+${v.toFixed(2)}%`:v<0&&(y=`${v.toFixed(2)}%`),{title:{text:i,diff:{text:y,color:b}},tooltipData:[p,g]}}var ll="ContextMenu-module_menu__x-AtY";function sl(t){const[n,r]=_i({transition:!0}),[o,i]=a.useState({x:0,y:0}),{canvasRef:l}=t,[s,c]=a.useState([]),{xyToMenuItems:f,onClose:u,onOpen:d}=t;return a.useEffect(()=>{r(!1);const e=l.current;if(!e)return()=>{};const t=e=>{e.preventDefault();const t=f(e.offsetX,e.offsetY);c(t);const n=e.clientX,a=e.clientY+20;i({x:n,y:a}),r(!0),d(e.offsetX,e.offsetY)};return e.addEventListener("contextmenu",t),()=>{e.removeEventListener("contextmenu",t)}},[f]),e(xi,{...n,className:ll,anchorPoint:o,onClose:()=>{r(!1),u()},children:s})}var cl="LogoLink-module_logoLink__oWRri";function fl(){return t("a",{className:cl,href:"https://github.com/pyroscope-io/pyroscope/",target:"_blank",rel:"noreferrer",children:[t("svg",{width:"22px",height:"22px",viewBox:"0 0 1024 1024",version:"1.1",xmlns:"http://www.w3.org/2000/svg",children:[e("defs",{children:t("radialGradient",{cx:"49.4236252%",cy:"92.6627823%",fx:"49.4236252%",fy:"92.6627823%",r:"195.066755%",gradientTransform:"translate(0.494236,0.926628),scale(1.000000,0.735610),rotate(-90.000000),translate(-0.494236,-0.926628)",id:"radialGradient-1",children:[e("stop",{stopColor:"#FFB90C",offset:"0%"}),e("stop",{stopColor:"#F9243A",offset:"38.390924%"}),e("stop",{stopColor:"#F9243A",offset:"50.5405%"}),e("stop",{stopColor:"#B51424",offset:"73.98091%"}),e("stop",{stopColor:"#B51424",offset:"100%"})]})}),e("g",{id:"Artboard",stroke:"none",strokeWidth:"1",fill:"none",fillRule:"evenodd",children:e("g",{id:"fire-part",transform:"translate(148.516736, 0.000000)",fillRule:"nonzero",children:t("g",{id:"whole-thing",transform:"translate(363.983264, 495.000000) scale(-1, 1) rotate(-180.000000) translate(-363.983264, -495.000000) translate(0.483264, 0.000000)",children:[e("g",{id:"g70",transform:"translate(-0.000091, 0.685815)",fill:"url(#radialGradient-1)",children:e("path",{d:"M65.3646667,571.739321 L65.4492471,571.698868 C19.5139147,505.999969 -5.32464048,424.477859 1.04305801,336.877516 L1.04305801,336.877516 C14.0321963,158.179446 159.192462,13.7596653 338.059844,1.5917266 L338.059844,1.5917266 C419.418369,-3.93888015 495.500283,17.3823334 558.456522,57.4611191 L558.456522,57.4611191 L481.301947,162.097965 C437.516468,136.521928 399.367671,129.590556 363.486536,130.155994 L363.486536,130.155994 C234.497143,130.155994 129.556988,235.032238 129.556988,363.946998 L129.556988,363.946998 C129.556988,492.865683 234.497143,597.738003 363.486536,597.738003 L363.486536,597.738003 C492.483783,597.738003 597.427864,492.865683 597.427864,363.946998 L597.427864,363.946998 C597.41276,304.634864 581.39383,255.677522 530.630465,199.668053 L607.770843,95.1329436 C680.936847,161.576603 726.932594,257.364176 726.932594,363.946998 L726.932594,363.946998 C726.932594,458.031616 691.13483,543.75602 632.416071,608.271816 L632.416071,608.271816 L632.416071,608.275741 L533.597728,748.122808 L428.601388,617.203806 L434.703262,646.563419 C459.453008,765.59222 433.664131,889.543925 363.49439,988.853335 L363.49439,988.853335 L65.3646667,571.723019 L65.3646667,571.739321 Z",id:"path84"})}),e("g",{id:"blue",transform:"translate(191.447039, 191.331780)",children:t("g",{id:"g88",transform:"translate(-0.000063, 0.685930)",children:[e("g",{id:"g94",transform:"translate(0.177296, 0.699054)",fill:"#3EC1D3",children:e("path",{d:"M171.862466,343.697728 C77.0961324,343.697728 -0.00497405932,266.647602 -0.00497405932,171.934957 C-0.00497405932,77.2182874 77.0961324,0.168162396 171.862466,0.168162396 C266.632828,0.168162396 343.741988,77.2182874 343.741988,171.934957 C343.741988,266.647602 266.632828,343.697728 171.862466,343.697728",id:"path96"})}),e("g",{id:"g98",transform:"translate(29.362379, 172.629585)",fill:"#FFFFFF",children:e("path",{d:"M22.8397982,0 L0.671669409,0 C0.671669409,78.2496309 64.380874,141.920035 142.678189,141.920035 L142.678189,119.765407 C76.6007327,119.765407 22.8397982,66.0372141 22.8397982,0",id:"path100"})})]})})]})})})]}),e("span",{children:"Pyroscope"})]})}const ul=()=>e("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"64 64 896 896",fill:"currentColor",children:e("path",{d:"M928 160H96c-17.7 0-32 14.3-32 32v640c0 17.7 14.3 32 32 32h832c17.7 0 32-14.3 32-32V192c0-17.7-14.3-32-32-32zm-40 208H676V232h212v136zm0 224H676V432h212v160zM412 432h200v160H412V432zm200-64H412V232h200v136zm-476 64h212v160H136V432zm0-200h212v136H136V232zm0 424h212v136H136V656zm276 0h200v136H412V656zm476 136H676V656h212v136z"})}),dl=()=>e("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"64 64 896 896",fill:"currentColor",children:e("path",{d:"M464 144H160c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V160c0-8.8-7.2-16-16-16zm-52 268H212V212h200v200zm452-268H560c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V160c0-8.8-7.2-16-16-16zm-52 268H612V212h200v200zM464 544H160c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V560c0-8.8-7.2-16-16-16zm-52 268H212V612h200v200zm452-268H560c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V560c0-8.8-7.2-16-16-16zm-52 268H612V612h200v200z"})}),hl=()=>e("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"64 64 896 896",fill:"currentColor",children:e("path",{d:"M834.1 469.2A347.49 347.49 0 00751.2 354l-29.1-26.7a8.09 8.09 0 00-13 3.3l-13 37.3c-8.1 23.4-23 47.3-44.1 70.8-1.4 1.5-3 1.9-4.1 2-1.1.1-2.8-.1-4.3-1.5-1.4-1.2-2.1-3-2-4.8 3.7-60.2-14.3-128.1-53.7-202C555.3 171 510 123.1 453.4 89.7l-41.3-24.3c-5.4-3.2-12.3 1-12 7.3l2.2 48c1.5 32.8-2.3 61.8-11.3 85.9-11 29.5-26.8 56.9-47 81.5a295.64 295.64 0 01-47.5 46.1 352.6 352.6 0 00-100.3 121.5A347.75 347.75 0 00160 610c0 47.2 9.3 92.9 27.7 136a349.4 349.4 0 0075.5 110.9c32.4 32 70 57.2 111.9 74.7C418.5 949.8 464.5 959 512 959s93.5-9.2 136.9-27.3A348.6 348.6 0 00760.8 857c32.4-32 57.8-69.4 75.5-110.9a344.2 344.2 0 0027.7-136c0-48.8-10-96.2-29.9-140.9zM713 808.5c-53.7 53.2-125 82.4-201 82.4s-147.3-29.2-201-82.4c-53.5-53.1-83-123.5-83-198.4 0-43.5 9.8-85.2 29.1-124 18.8-37.9 46.8-71.8 80.8-97.9a349.6 349.6 0 0058.6-56.8c25-30.5 44.6-64.5 58.2-101a240 240 0 0012.1-46.5c24.1 22.2 44.3 49 61.2 80.4 33.4 62.6 48.8 118.3 45.8 165.7a74.01 74.01 0 0024.4 59.8 73.36 73.36 0 0053.4 18.8c19.7-1 37.8-9.7 51-24.4 13.3-14.9 24.8-30.1 34.4-45.6 14 17.9 25.7 37.4 35 58.4 15.9 35.8 24 73.9 24 113.1 0 74.9-29.5 145.4-83 198.4z"})}),ml=({fill:n})=>t("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 64 64",fill:n,children:[e("g",{id:"shape_squiggle",children:e("path",{d:"M60,38.42c-4.62,0-6.97-2.64-8.86-4.75-1.81-2.03-2.86-3.08-5.13-3.08s-3.32,1.06-5.13,3.08c-1.89,2.12-4.24,4.75-8.86,4.75s-6.97-2.64-8.87-4.75c-1.81-2.03-2.86-3.08-5.14-3.08s-3.33,1.06-5.14,3.08c-1.89,2.12-4.25,4.75-8.87,4.75-1.38,0-2.5-1.12-2.5-2.5s1.12-2.5,2.5-2.5c2.28,0,3.33-1.06,5.14-3.09,1.89-2.12,4.25-4.75,8.87-4.75s6.97,2.64,8.87,4.75c1.81,2.03,2.86,3.09,5.14,3.09s3.32-1.06,5.13-3.08c1.89-2.12,4.24-4.75,8.86-4.75s6.97,2.64,8.86,4.75c1.81,2.03,2.86,3.08,5.13,3.08,1.38,0,2.5,1.12,2.5,2.5s-1.12,2.5-2.5,2.5Z"})}),t("g",{id:"Layer_4",children:[e("rect",{x:"2",y:"8",width:"60",height:"14",rx:"3.94",ry:"3.94"}),e("path",{d:"M58.06,41h-18.64c-1.58,0-3.14,.42-4.5,1.22l-6.88,4.02c-1.87,1.09-4.19,1.09-6.06,0l-6.88-4.02c-1.37-.8-2.92-1.22-4.5-1.22H5.94c-2.18,0-3.94,1.76-3.94,3.94v7.12c0,2.18,1.76,3.94,3.94,3.94H58.06c2.18,0,3.94-1.76,3.94-3.94v-7.12c0-2.18-1.76-3.94-3.94-3.94Z"})]})]}),pl=()=>t("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 64 64",children:[e("g",{id:"ab_shape",children:t("g",{children:[e("path",{d:"M16.71,41l-.42-2.45h-.16c-1.63,1.95-4.06,2.95-6.91,2.95-4.8,0-7.86-3.45-7.86-7.45,0-6.4,6.01-9.3,14.13-9.3v-.4c0-1.5-.84-3.2-4.38-3.2-2.48,0-4.9,.75-6.54,1.7l-1.42-4.75c1.69-.9,5.01-2.1,9.44-2.1,8.33,0,10.65,4.95,10.65,10.45v8.7c0,2.25,.11,4.4,.37,5.85h-6.91Zm-.95-11.7c-3.64,0-6.91,.9-6.91,4,0,2.1,1.37,3,3,3s3.22-1.05,3.74-2.6c.11-.35,.16-.8,.16-1.2v-3.2Z"}),e("path",{d:"M29.36,41c.11-1.79,.21-4.62,.21-7.25V6h7.7v13.46h.11c1.42-1.99,3.8-3.28,7.06-3.28,5.85,0,9.7,5.01,9.65,12.16,0,8.69-5.22,13.16-10.81,13.16-2.74,0-5.22-.99-6.91-3.72h-.11l-.37,3.23h-6.54Zm7.91-9.83c0,.55,.05,.99,.16,1.39,.58,1.94,2.16,3.18,4.01,3.18,3.11,0,4.9-2.53,4.9-7,0-3.92-1.58-6.8-4.9-6.8-1.85,0-3.53,1.39-3.95,3.28-.16,.4-.21,.94-.21,1.44v4.52Z"})]})}),e("g",{id:"arrows",children:e("polygon",{points:"62 54 52 45 52 51 35 51 35 57 52 57 52 63 62 54"})})]}),gl=()=>t("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 64 64",children:[e("g",{id:"yz_shape",children:t("g",{children:[e("path",{d:"M22.75,13l3.43,12.39c.42,1.47,.84,3.2,1.16,4.52h.11c.32-1.32,.69-3.05,1-4.47l2.9-12.44h8.01l-5.8,17.16c-2.95,8.33-5.17,12.54-8.07,15.23-2.58,2.39-5.43,3.3-7.17,3.55l-1.85-6.3c1.11-.25,2.32-.76,3.48-1.52,1.16-.71,2.32-1.88,2.95-3.05,.26-.41,.42-.76,.42-1.12,0-.31-.05-.66-.26-1.17L14.32,13h8.43Z"}),e("path",{d:"M41.62,33.46l7.59-10.16c1.27-1.57,2.37-2.95,3.58-4.27v-.15h-10.33v-5.89h19.45l-.05,4.57-7.28,9.8c-1.21,1.57-2.48,3.15-3.69,4.42v.1h11.33v5.94h-20.61v-4.37Z"})]})}),e("g",{id:"arrows",children:e("polygon",{points:"12 51 12 45 2 54 12 63 12 57 29 57 29 51 12 51"})})]});var vl="Header-module_flamegraphHeader__nIrXP",bl="Header-module_row__P7-2L",yl="Header-module_flamegraphTitle__sjsvB";function wl(a){const{format:r,units:o,toolbarVisible:i}=a,l={objects:"number of objects in RAM per function",goroutines:"number of goroutines",bytes:"amount of RAM per function",samples:"CPU time per function",lock_nanoseconds:"time spent waiting on locks per function",lock_samples:"number of contended locks per function",trace_samples:"aggregated span duration",exceptions:"number of exceptions thrown",unknown:""},s=i&&"single"===r?e("div",{className:`${bl} ${yl}`,role:"heading","aria-level":2,children:l[o]&&t(n,{children:["Frame width represents ",l[o]]})}):null;return s?e("div",{className:vl,children:e("div",{children:s})}):null}var xl="FlamegraphBreadcrumb-module_bar__v8uhn",kl="FlamegraphBreadcrumb-module_chip__pdv1k",Nl="FlamegraphBreadcrumb-module_focusTooltip__nX30y",Sl="FlamegraphBreadcrumb-module_separator__Zj-rC",Tl="FlamegraphBreadcrumb-module_chipSeparator__S-Gld",Cl="FlamegraphBreadcrumb-module_unitLabel__bjHEA",_l="FlamegraphBreadcrumb-module_focusIcon__aJBb6",Ml="FlamegraphBreadcrumb-module_ofTotal__kk4dt",Rl="FlamegraphBreadcrumb-module_clearBtn__spimK";function Pl(a){const{totalValueText:r,totalSamplesText:o,samplesLabel:i,unitLabel:l,hasFocus:s,focusPercent:c,focusLabel:f,ofTotalPlacement:u="after",ofTotalLabel:d,clearFocusLabel:h,onClearFocus:m}=a,p=f&&f.trim().length>0?f:void 0;return t("div",{className:xl,"aria-live":"polite",children:[t("span",{className:kl,children:[e("span",{children:r}),e("span",{className:Sl,children:"|"}),t("span",{children:[o," ",i]}),t("span",{className:Cl,children:["(",l,")"]})]}),s&&void 0!==c&&t(n,{children:[e("span",{className:Tl,children:">"}),t("span",{className:`${kl} ${Nl}`,"data-tooltip":p,children:[e("span",{className:_l,"aria-hidden":"true",children:t("svg",{viewBox:"0 0 24 24",width:"14",height:"14",fill:"none",stroke:"currentColor",strokeWidth:"1.6",strokeLinecap:"round",strokeLinejoin:"round",children:[e("path",{d:"M2 12s3.5-6 10-6 10 6 10 6-3.5 6-10 6-10-6-10-6Z"}),e("circle",{cx:"12",cy:"12",r:"3.2"})]})}),t(n,"before"===u?{children:[e("span",{className:Ml,children:d}),t("span",{children:[c.toFixed(2),"%"]})]}:{children:[t("span",{children:[c.toFixed(2),"%"]}),e("span",{className:Ml,children:d})]}),e("button",{type:"button",className:Rl,"aria-label":h,onClick:e=>{e.preventDefault(),e.stopPropagation(),m()},children:"×"})]})]})]})}var Fl="styles-module_flamegraphPane__ejguD",Il="styles-module_fitModeItem__0UBwN",jl="styles-module_sandwichItem__WYvnd",El="styles-module_flamegraphFrame__9ZW-z";function Dl(n){const r=a.useRef(null),i=a.useRef(null),l=c(),s=c(),u=c(null),h=c(null),m=c(null),p=c({rect:!1,text:!1}),g=qi(),v=c({lastWidth:0,lastHeight:0}),b="undefined"!=typeof window&&"undefined"!=typeof OffscreenCanvas&&"transferControlToOffscreen"in HTMLCanvasElement.prototype,y=o(()=>({collapsedLevelsSingular:g.collapsedLevelsSingular,collapsedLevelsPlural:g.collapsedLevelsPlural,isZh:"Location"!==g.location}),[g.collapsedLevelsSingular,g.collapsedLevelsPlural,g.location]),w=f(e=>({name:e.name,goodColor:e.goodColor.rgb().array(),neutralColor:e.neutralColor.rgb().array(),badColor:e.badColor.rgb().array(),colors:e.colors.map(e=>e.rgb().array())}),[]),[x,k]=a.useState(N.nothing()),{flamebearer:S,focusedNode:T,fitMode:C,updateFitMode:R,highlightQuery:P,zoom:F,toolbarVisible:I,headerVisible:j=!0,disableClick:E=!1,showSingleLevel:D=!1,showCredit:B,setActiveItem:L,selectedItem:A,updateView:O,enableSandwichView:z=!0,breadcrumb:$}=n,{onZoom:V,onReset:H,isDirty:W,onFocusOnNode:U}=n,{"data-testid":J}=n,{palette:Q,setPalette:X}=n,Y=f(M(()=>{te(),ne()},50),[]);d(()=>{if(!b)return()=>{};const e=function(){const e=new URL(import.meta.url),t=e.pathname,n=t.includes("/src/");if(t.includes("/dist/"),t.includes("/node_modules/.vite/deps/")){const t=new URL("../../@kylincloud/flamegraph/dist/flamegraphRenderWorker.js",e);return new Worker(t,{type:"module"})}const a=n?new URL("./flamegraphRenderWorker.ts",e):new URL("./flamegraphRenderWorker.js",e);return new Worker(a,{type:"module"})}();return u.current=e,setTimeout(()=>{te(),ne()},0),()=>{e.terminate(),u.current=null,h.current=null,m.current=null,p.current={rect:!1,text:!1}}},[b]),_(r,()=>{if(l){if(r.current){const e=r.current.clientWidth,t=r.current.clientHeight,n=v.current;if(!(Math.abs(e-n.lastWidth)>=2))return;n.lastWidth=e,n.lastHeight=t}Y()}});const Z=(e,t)=>oe().xyToBar(e,t).map(e=>({left:re().offsetLeft+e.x,top:re().offsetTop+e.y,width:e.width})),q=f((n,a)=>{const r=W(),o=oe().xyToBar(n,a),i=o.isJust?o.value.name:"";return[t(Ii,{disabled:!r,onClick:H,children:[e(gr,{icon:No.faRedo}),g.resetView]},"reset"),(()=>{const n=o.mapOrElse(()=>!1,()=>!0),a=o.mapOrElse(()=>()=>{},e=>U.bind(null,e.i,e.j));return t(Ii,{disabled:!n,onClick:a,children:[e(gr,{icon:Lo.faCompressAlt}),g.collapseNodesAbove]},"focus")})(),t(Ii,{onClick:()=>{navigator.clipboard&&navigator.clipboard.writeText(i)},children:[e(gr,{icon:_o.faCopy}),g.copyFunctionName]},"copy"),(()=>{const n=A.isJust&&A.value===i?g.clearHighlight:g.highlightSimilarNodes;return t(Ii,{onClick:()=>{L({name:i})},children:[e(gr,{icon:Io.faHighlighter}),n]},"highlight-similar-nodes")})(),(()=>{if(!O||!z)return null;return t(Ii,{className:jl,onClick:()=>{O("sandwich"),L({name:i})},children:[e(ml,{fill:"black"}),g.openInSandwichView]},"open-in-sandwich-view")})(),(()=>{const n=C===Qr;return t(Ii,{className:Il,onClick:()=>{R(n?Jr:Qr)},children:[e(n?gl:pl,{}),n?g.showTextTailFirst:g.showTextHeadFirst]},"fit-mode")})()].filter(Boolean)},[l,A,C,W,H,U,L,O,g,z]),G=()=>{if(r.current){const e=new fo(S,r.current,T,C,P,F,Q,y);l.current=e}if(i.current){const e=new fo(S,i.current,T,C,P,F,Q,y);s.current=e}},K=f(()=>{if(!b||!u.current)return!1;const e=u.current;if(r.current&&!h.current)try{const t=r.current.transferControlToOffscreen();h.current=t,e.postMessage({type:"init",payload:{kind:"rect",canvas:t}},[t]),p.current.rect=!0}catch(e){}if(i.current&&!m.current)try{const t=i.current.transferControlToOffscreen();m.current=t,e.postMessage({type:"init",payload:{kind:"text",canvas:t}},[t]),p.current.text=!0}catch(e){}return!0},[b]);a.useEffect(()=>{G(),te(),ne()},[Q,y]),a.useEffect(()=>{G(),te(),ne()},[r.current,S,T,C,F]),a.useEffect(()=>{G(),te(),ne()},[P]);const ee=(e,t)=>{if(!b)return!1;if(!u.current)return!0;if(!K())return!0;const n="rect"===e?r.current:i.current,a=(null==n?void 0:n.clientWidth)||(null==n?void 0:n.width)||0,o={kind:e,flamebearer:S,focusedNode:T.isJust?T.value:null,fitMode:C,highlightQuery:P,zoom:F.isJust?F.value:null,palette:w(Q),messages:y,renderRects:t.renderRects,renderText:t.renderText,width:a,devicePixelRatio:"undefined"!=typeof window&&window.devicePixelRatio||1};return u.current.postMessage({type:"render",payload:o}),!0},te=()=>{var e,t,n;ee("rect",{renderText:!1})||(null===(e=null==r?void 0:r.current)||void 0===e||e.setAttribute("data-state","rendering"),null===(t=null==l?void 0:l.current)||void 0===t||t.render({renderText:!1}),null===(n=null==r?void 0:r.current)||void 0===n||n.setAttribute("data-state","rendered"))},ne=()=>{var e,t,n;ee("text",{renderRects:!1})||(null===(e=null==i?void 0:i.current)||void 0===e||e.setAttribute("data-state","rendering"),null===(t=null==s?void 0:s.current)||void 0===t||t.render({renderRects:!1}),null===(n=null==i?void 0:i.current)||void 0===n||n.setAttribute("data-state","rendered"))},ae=!S||S&&S.names.length<=1,re=()=>{if(!r.current)throw new Error("Missing canvas");return r.current},oe=()=>{if(!l.current)throw new Error("Missing canvas");return l.current};return t("div",{"data-testid":"flamegraph-view",className:ho(Fl,{"vertical-orientation":"double"===S.format}),children:[t("div",{className:El,children:[$&&e(Pl,{totalValueText:$.totalValueText,totalSamplesText:$.totalSamplesText,samplesLabel:$.samplesLabel,unitLabel:$.unitLabel,hasFocus:$.hasFocus,focusPercent:$.focusPercent,focusLabel:$.focusLabel,ofTotalPlacement:$.ofTotalPlacement,ofTotalLabel:$.ofTotalLabel,clearFocusLabel:$.clearFocusLabel,onClearFocus:$.onClearFocus}),j&&e(wl,{format:S.format,units:S.units,toolbarVisible:I}),t("div",{"data-testid":J,style:{position:"relative",opacity:ae&&!D?0:1},children:[e("canvas",{height:"0","data-testid":"flamegraph-canvas","data-highlightquery":P,className:ho("flamegraph-canvas",Ei),ref:r,onClick:E?void 0:e=>{const t=oe().xyToBar(e.nativeEvent.offsetX,e.nativeEvent.offsetY);t.match({Nothing:()=>{},Just:e=>{F.match({Nothing:()=>{V(t)},Just:n=>{e.i===n.i&&e.j===n.j?V(N.nothing()):V(t)}})}})}}),e("canvas",{height:"0","data-testid":"flamegraph-text-canvas",className:ho("flamegraph-text-canvas",Di),ref:i}),l&&r&&e(Li,{barHeight:jr,canvasRef:r,zoom:F,xyToHighlightData:Z}),l&&e(zi,{barHeight:jr,node:x})]}),B?e(fl,{}):""]}),l&&e(ol,{format:S.format,canvasRef:r,xyToData:(e,t)=>oe().xyToBar(e,t),numTicks:S.numTicks,sampleRate:S.sampleRate,leftTicks:"double"===S.format?S.leftTicks:0,rightTicks:"double"===S.format?S.rightTicks:0,units:S.units,palette:Q}),!E&&l&&r&&e(sl,{canvasRef:r,xyToMenuItems:q,onClose:()=>{k(N.nothing())},onOpen:(e,t)=>{k(Z(e,t))}})]})}var Bl,Ll={exports:{}};
|
|
12
|
+
function A(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 I(e,t,n){return t&&function(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,H(r.key),r)}}(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function D(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=U(e))||t){n&&(e=n);var r=0,a=function(){};return{s:a,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,i=!0,l=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return i=e.done,e},e:function(e){l=!0,o=e},f:function(){try{i||null==n.return||n.return()}finally{if(l)throw o}}}}function B(e,t,n){return(t=H(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function L(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 $(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?L(Object(n),!0).forEach(function(t){B(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):L(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function z(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,a,o,i,l=[],s=!0,c=!1;try{if(o=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=o.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,a=e}finally{try{if(!s&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw a}}return l}}(e,t)||U(e,t)||function(){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 V(e){return function(e){if(Array.isArray(e))return A(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||U(e)||function(){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 H(e){var t=function(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)}(e,"string");return"symbol"==typeof t?t:t+""}function W(e){return W="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},W(e)}function U(e,t){if(e){if("string"==typeof e)return A(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)?A(e,t):void 0}}var J=function(){},Q={},q={},X=null,Y={mark:J,measure:J};try{"undefined"!=typeof window&&(Q=window),"undefined"!=typeof document&&(q=document),"undefined"!=typeof MutationObserver&&(X=MutationObserver),"undefined"!=typeof performance&&(Y=performance)}catch(nc){}var K=(Q.navigator||{}).userAgent,Z=void 0===K?"":K,G=Q,ee=q,te=X,ne=Y;G.document;var re,ae=!!ee.documentElement&&!!ee.head&&"function"==typeof ee.addEventListener&&"function"==typeof ee.createElement,oe=~Z.indexOf("MSIE")||~Z.indexOf("Trident/"),ie={classic:{fa:"solid",fas:"solid","fa-solid":"solid",far:"regular","fa-regular":"regular",fal:"light","fa-light":"light",fat:"thin","fa-thin":"thin",fab:"brands","fa-brands":"brands"},duotone:{fa:"solid",fad:"solid","fa-solid":"solid","fa-duotone":"solid",fadr:"regular","fa-regular":"regular",fadl:"light","fa-light":"light",fadt:"thin","fa-thin":"thin"},sharp:{fa:"solid",fass:"solid","fa-solid":"solid",fasr:"regular","fa-regular":"regular",fasl:"light","fa-light":"light",fast:"thin","fa-thin":"thin"},"sharp-duotone":{fa:"solid",fasds:"solid","fa-solid":"solid",fasdr:"regular","fa-regular":"regular",fasdl:"light","fa-light":"light",fasdt:"thin","fa-thin":"thin"},slab:{"fa-regular":"regular",faslr:"regular"},"slab-press":{"fa-regular":"regular",faslpr:"regular"},thumbprint:{"fa-light":"light",fatl:"light"},whiteboard:{"fa-semibold":"semibold",fawsb:"semibold"},notdog:{"fa-solid":"solid",fans:"solid"},"notdog-duo":{"fa-solid":"solid",fands:"solid"},etch:{"fa-solid":"solid",faes:"solid"},jelly:{"fa-regular":"regular",fajr:"regular"},"jelly-fill":{"fa-regular":"regular",fajfr:"regular"},"jelly-duo":{"fa-regular":"regular",fajdr:"regular"},chisel:{"fa-regular":"regular",facr:"regular"},utility:{"fa-semibold":"semibold",fausb:"semibold"},"utility-duo":{"fa-semibold":"semibold",faudsb:"semibold"},"utility-fill":{"fa-semibold":"semibold",faufsb:"semibold"}},le=["fa-classic","fa-duotone","fa-sharp","fa-sharp-duotone","fa-thumbprint","fa-whiteboard","fa-notdog","fa-notdog-duo","fa-chisel","fa-etch","fa-jelly","fa-jelly-fill","fa-jelly-duo","fa-slab","fa-slab-press","fa-utility","fa-utility-duo","fa-utility-fill"],se="classic",ce="duotone",ue="sharp",fe="sharp-duotone",de="chisel",he="etch",me="jelly",pe="jelly-duo",ge="jelly-fill",ve="notdog",be="notdog-duo",ye="slab",we="slab-press",xe="thumbprint",ke="utility",_e="utility-duo",Ne="utility-fill",Se="whiteboard",Me=[se,ce,ue,fe,de,he,me,pe,ge,ve,be,ye,we,xe,ke,_e,Ne,Se];B(B(B(B(B(B(B(B(B(B(re={},se,"Classic"),ce,"Duotone"),ue,"Sharp"),fe,"Sharp Duotone"),de,"Chisel"),he,"Etch"),me,"Jelly"),pe,"Jelly Duo"),ge,"Jelly Fill"),ve,"Notdog"),B(B(B(B(B(B(B(B(re,be,"Notdog Duo"),ye,"Slab"),we,"Slab Press"),xe,"Thumbprint"),ke,"Utility"),_e,"Utility Duo"),Ne,"Utility Fill"),Se,"Whiteboard");var Te=new Map([["classic",{defaultShortPrefixId:"fas",defaultStyleId:"solid",styleIds:["solid","regular","light","thin","brands"],futureStyleIds:[],defaultFontWeight:900}],["duotone",{defaultShortPrefixId:"fad",defaultStyleId:"solid",styleIds:["solid","regular","light","thin"],futureStyleIds:[],defaultFontWeight:900}],["sharp",{defaultShortPrefixId:"fass",defaultStyleId:"solid",styleIds:["solid","regular","light","thin"],futureStyleIds:[],defaultFontWeight:900}],["sharp-duotone",{defaultShortPrefixId:"fasds",defaultStyleId:"solid",styleIds:["solid","regular","light","thin"],futureStyleIds:[],defaultFontWeight:900}],["chisel",{defaultShortPrefixId:"facr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["etch",{defaultShortPrefixId:"faes",defaultStyleId:"solid",styleIds:["solid"],futureStyleIds:[],defaultFontWeight:900}],["jelly",{defaultShortPrefixId:"fajr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["jelly-duo",{defaultShortPrefixId:"fajdr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["jelly-fill",{defaultShortPrefixId:"fajfr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["notdog",{defaultShortPrefixId:"fans",defaultStyleId:"solid",styleIds:["solid"],futureStyleIds:[],defaultFontWeight:900}],["notdog-duo",{defaultShortPrefixId:"fands",defaultStyleId:"solid",styleIds:["solid"],futureStyleIds:[],defaultFontWeight:900}],["slab",{defaultShortPrefixId:"faslr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["slab-press",{defaultShortPrefixId:"faslpr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["thumbprint",{defaultShortPrefixId:"fatl",defaultStyleId:"light",styleIds:["light"],futureStyleIds:[],defaultFontWeight:300}],["utility",{defaultShortPrefixId:"fausb",defaultStyleId:"semibold",styleIds:["semibold"],futureStyleIds:[],defaultFontWeight:600}],["utility-duo",{defaultShortPrefixId:"faudsb",defaultStyleId:"semibold",styleIds:["semibold"],futureStyleIds:[],defaultFontWeight:600}],["utility-fill",{defaultShortPrefixId:"faufsb",defaultStyleId:"semibold",styleIds:["semibold"],futureStyleIds:[],defaultFontWeight:600}],["whiteboard",{defaultShortPrefixId:"fawsb",defaultStyleId:"semibold",styleIds:["semibold"],futureStyleIds:[],defaultFontWeight:600}]]),Ce=["fak","fa-kit","fakd","fa-kit-duotone"],je={fak:"kit","fa-kit":"kit"},Oe={fakd:"kit-duotone","fa-kit-duotone":"kit-duotone"};B(B({},"kit","Kit"),"kit-duotone","Kit Duotone");var Re,Pe={kit:"fak"},Ee={"kit-duotone":"fakd"},Fe="duotone-group",Ae="swap-opacity",Ie="primary",De="secondary";B(B(B(B(B(B(B(B(B(B(Re={},"classic","Classic"),"duotone","Duotone"),"sharp","Sharp"),"sharp-duotone","Sharp Duotone"),"chisel","Chisel"),"etch","Etch"),"jelly","Jelly"),"jelly-duo","Jelly Duo"),"jelly-fill","Jelly Fill"),"notdog","Notdog"),B(B(B(B(B(B(B(B(Re,"notdog-duo","Notdog Duo"),"slab","Slab"),"slab-press","Slab Press"),"thumbprint","Thumbprint"),"utility","Utility"),"utility-duo","Utility Duo"),"utility-fill","Utility Fill"),"whiteboard","Whiteboard");B(B({},"kit","Kit"),"kit-duotone","Kit Duotone");var Be={classic:{fab:"fa-brands",fad:"fa-duotone",fal:"fa-light",far:"fa-regular",fas:"fa-solid",fat:"fa-thin"},duotone:{fadr:"fa-regular",fadl:"fa-light",fadt:"fa-thin"},sharp:{fass:"fa-solid",fasr:"fa-regular",fasl:"fa-light",fast:"fa-thin"},"sharp-duotone":{fasds:"fa-solid",fasdr:"fa-regular",fasdl:"fa-light",fasdt:"fa-thin"},slab:{faslr:"fa-regular"},"slab-press":{faslpr:"fa-regular"},whiteboard:{fawsb:"fa-semibold"},thumbprint:{fatl:"fa-light"},notdog:{fans:"fa-solid"},"notdog-duo":{fands:"fa-solid"},etch:{faes:"fa-solid"},jelly:{fajr:"fa-regular"},"jelly-fill":{fajfr:"fa-regular"},"jelly-duo":{fajdr:"fa-regular"},chisel:{facr:"fa-regular"},utility:{fausb:"fa-semibold"},"utility-duo":{faudsb:"fa-semibold"},"utility-fill":{faufsb:"fa-semibold"}},Le=["fa","fas","far","fal","fat","fad","fadr","fadl","fadt","fab","fass","fasr","fasl","fast","fasds","fasdr","fasdl","fasdt","faslr","faslpr","fawsb","fatl","fans","fands","faes","fajr","fajfr","fajdr","facr","fausb","faudsb","faufsb"].concat(["fa-classic","fa-duotone","fa-sharp","fa-sharp-duotone","fa-thumbprint","fa-whiteboard","fa-notdog","fa-notdog-duo","fa-chisel","fa-etch","fa-jelly","fa-jelly-fill","fa-jelly-duo","fa-slab","fa-slab-press","fa-utility","fa-utility-duo","fa-utility-fill"],["fa-solid","fa-regular","fa-light","fa-thin","fa-duotone","fa-brands","fa-semibold"]),$e=[1,2,3,4,5,6,7,8,9,10],ze=$e.concat([11,12,13,14,15,16,17,18,19,20]),Ve=[].concat(V(Object.keys({classic:["fas","far","fal","fat","fad"],duotone:["fadr","fadl","fadt"],sharp:["fass","fasr","fasl","fast"],"sharp-duotone":["fasds","fasdr","fasdl","fasdt"],slab:["faslr"],"slab-press":["faslpr"],whiteboard:["fawsb"],thumbprint:["fatl"],notdog:["fans"],"notdog-duo":["fands"],etch:["faes"],jelly:["fajr"],"jelly-fill":["fajfr"],"jelly-duo":["fajdr"],chisel:["facr"],utility:["fausb"],"utility-duo":["faudsb"],"utility-fill":["faufsb"]})),["solid","regular","light","thin","duotone","brands","semibold"],["aw","fw","pull-left","pull-right"],["2xs","xs","sm","lg","xl","2xl","beat","border","fade","beat-fade","bounce","flip-both","flip-horizontal","flip-vertical","flip","inverse","layers","layers-bottom-left","layers-bottom-right","layers-counter","layers-text","layers-top-left","layers-top-right","li","pull-end","pull-start","pulse","rotate-180","rotate-270","rotate-90","rotate-by","shake","spin-pulse","spin-reverse","spin","stack-1x","stack-2x","stack","ul","width-auto","width-fixed",Fe,Ae,Ie,De]).concat($e.map(function(e){return"".concat(e,"x")})).concat(ze.map(function(e){return"w-".concat(e)})),He="___FONT_AWESOME___",We="svg-inline--fa",Ue="data-fa-i2svg",Je="data-fa-pseudo-element",Qe="data-prefix",qe="data-icon",Xe="fontawesome-i2svg",Ye=["HTML","HEAD","STYLE","SCRIPT"],Ke=["::before","::after",":before",":after"],Ze=function(){try{return"production"===process.env.NODE_ENV}catch(e){return!1}}();function Ge(e){return new Proxy(e,{get:function(e,t){return t in e?e[t]:e[se]}})}var et=$({},ie);et[se]=$($($($({},{"fa-duotone":"duotone"}),ie[se]),je),Oe);var tt=Ge(et),nt=$({},{chisel:{regular:"facr"},classic:{brands:"fab",light:"fal",regular:"far",solid:"fas",thin:"fat"},duotone:{light:"fadl",regular:"fadr",solid:"fad",thin:"fadt"},etch:{solid:"faes"},jelly:{regular:"fajr"},"jelly-duo":{regular:"fajdr"},"jelly-fill":{regular:"fajfr"},notdog:{solid:"fans"},"notdog-duo":{solid:"fands"},sharp:{light:"fasl",regular:"fasr",solid:"fass",thin:"fast"},"sharp-duotone":{light:"fasdl",regular:"fasdr",solid:"fasds",thin:"fasdt"},slab:{regular:"faslr"},"slab-press":{regular:"faslpr"},thumbprint:{light:"fatl"},utility:{semibold:"fausb"},"utility-duo":{semibold:"faudsb"},"utility-fill":{semibold:"faufsb"},whiteboard:{semibold:"fawsb"}});nt[se]=$($($($({},{duotone:"fad"}),nt[se]),Pe),Ee);var rt=Ge(nt),at=$({},Be);at[se]=$($({},at[se]),{fak:"fa-kit"});var ot=Ge(at),it=$({},{classic:{"fa-brands":"fab","fa-duotone":"fad","fa-light":"fal","fa-regular":"far","fa-solid":"fas","fa-thin":"fat"},duotone:{"fa-regular":"fadr","fa-light":"fadl","fa-thin":"fadt"},sharp:{"fa-solid":"fass","fa-regular":"fasr","fa-light":"fasl","fa-thin":"fast"},"sharp-duotone":{"fa-solid":"fasds","fa-regular":"fasdr","fa-light":"fasdl","fa-thin":"fasdt"},slab:{"fa-regular":"faslr"},"slab-press":{"fa-regular":"faslpr"},whiteboard:{"fa-semibold":"fawsb"},thumbprint:{"fa-light":"fatl"},notdog:{"fa-solid":"fans"},"notdog-duo":{"fa-solid":"fands"},etch:{"fa-solid":"faes"},jelly:{"fa-regular":"fajr"},"jelly-fill":{"fa-regular":"fajfr"},"jelly-duo":{"fa-regular":"fajdr"},chisel:{"fa-regular":"facr"},utility:{"fa-semibold":"fausb"},"utility-duo":{"fa-semibold":"faudsb"},"utility-fill":{"fa-semibold":"faufsb"}});it[se]=$($({},it[se]),{"fa-kit":"fak"}),Ge(it);var lt=/fa(k|kd|s|r|l|t|d|dr|dl|dt|b|slr|slpr|wsb|tl|ns|nds|es|jr|jfr|jdr|usb|ufsb|udsb|cr|ss|sr|sl|st|sds|sdr|sdl|sdt)?[\-\ ]/,st="fa-layers-text",ct=/Font ?Awesome ?([567 ]*)(Solid|Regular|Light|Thin|Duotone|Brands|Free|Pro|Sharp Duotone|Sharp|Kit|Notdog Duo|Notdog|Chisel|Etch|Thumbprint|Jelly Fill|Jelly Duo|Jelly|Utility|Utility Fill|Utility Duo|Slab Press|Slab|Whiteboard)?.*/i;Ge($({},{classic:{900:"fas",400:"far",normal:"far",300:"fal",100:"fat"},duotone:{900:"fad",400:"fadr",300:"fadl",100:"fadt"},sharp:{900:"fass",400:"fasr",300:"fasl",100:"fast"},"sharp-duotone":{900:"fasds",400:"fasdr",300:"fasdl",100:"fasdt"},slab:{400:"faslr"},"slab-press":{400:"faslpr"},whiteboard:{600:"fawsb"},thumbprint:{300:"fatl"},notdog:{900:"fans"},"notdog-duo":{900:"fands"},etch:{900:"faes"},chisel:{400:"facr"},jelly:{400:"fajr"},"jelly-fill":{400:"fajfr"},"jelly-duo":{400:"fajdr"},utility:{600:"fausb"},"utility-duo":{600:"faudsb"},"utility-fill":{600:"faufsb"}}));var ut=["class","data-prefix","data-icon","data-fa-transform","data-fa-mask"],ft={GROUP:"duotone-group",PRIMARY:"primary",SECONDARY:"secondary"},dt=[].concat(V(["kit"]),V(Ve)),ht=G.FontAwesomeConfig||{};if(ee&&"function"==typeof ee.querySelector){[["data-family-prefix","familyPrefix"],["data-css-prefix","cssPrefix"],["data-family-default","familyDefault"],["data-style-default","styleDefault"],["data-replacement-class","replacementClass"],["data-auto-replace-svg","autoReplaceSvg"],["data-auto-add-css","autoAddCss"],["data-search-pseudo-elements","searchPseudoElements"],["data-search-pseudo-elements-warnings","searchPseudoElementsWarnings"],["data-search-pseudo-elements-full-scan","searchPseudoElementsFullScan"],["data-observe-mutations","observeMutations"],["data-mutate-approach","mutateApproach"],["data-keep-original-source","keepOriginalSource"],["data-measure-performance","measurePerformance"],["data-show-missing-icons","showMissingIcons"]].forEach(function(e){var t=z(e,2),n=t[0],r=t[1],a=function(e){return""===e||"false"!==e&&("true"===e||e)}(function(e){var t=ee.querySelector("script["+e+"]");if(t)return t.getAttribute(e)}(n));null!=a&&(ht[r]=a)})}var mt={styleDefault:"solid",familyDefault:se,cssPrefix:"fa",replacementClass:We,autoReplaceSvg:!0,autoAddCss:!0,searchPseudoElements:!1,searchPseudoElementsWarnings:!0,searchPseudoElementsFullScan:!1,observeMutations:!0,mutateApproach:"async",keepOriginalSource:!0,measurePerformance:!1,showMissingIcons:!0};ht.familyPrefix&&(ht.cssPrefix=ht.familyPrefix);var pt=$($({},mt),ht);pt.autoReplaceSvg||(pt.observeMutations=!1);var gt={};Object.keys(mt).forEach(function(e){Object.defineProperty(gt,e,{enumerable:!0,set:function(t){pt[e]=t,vt.forEach(function(e){return e(gt)})},get:function(){return pt[e]}})}),Object.defineProperty(gt,"familyPrefix",{enumerable:!0,set:function(e){pt.cssPrefix=e,vt.forEach(function(e){return e(gt)})},get:function(){return pt.cssPrefix}}),G.FontAwesomeConfig=gt;var vt=[];var bt=16,yt={size:16,x:0,y:0,rotate:0,flipX:!1,flipY:!1};function wt(){for(var e=12,t="";e-- >0;)t+="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"[62*Math.random()|0];return t}function xt(e){for(var t=[],n=(e||[]).length>>>0;n--;)t[n]=e[n];return t}function kt(e){return e.classList?xt(e.classList):(e.getAttribute("class")||"").split(" ").filter(function(e){return e})}function _t(e){return"".concat(e).replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(/</g,"<").replace(/>/g,">")}function Nt(e){return Object.keys(e||{}).reduce(function(t,n){return t+"".concat(n,": ").concat(e[n].trim(),";")},"")}function St(e){return e.size!==yt.size||e.x!==yt.x||e.y!==yt.y||e.rotate!==yt.rotate||e.flipX||e.flipY}function Mt(){var e="fa",t=We,n=gt.cssPrefix,r=gt.replacementClass,a=':root, :host {\n --fa-font-solid: normal 900 1em/1 "Font Awesome 7 Free";\n --fa-font-regular: normal 400 1em/1 "Font Awesome 7 Free";\n --fa-font-light: normal 300 1em/1 "Font Awesome 7 Pro";\n --fa-font-thin: normal 100 1em/1 "Font Awesome 7 Pro";\n --fa-font-duotone: normal 900 1em/1 "Font Awesome 7 Duotone";\n --fa-font-duotone-regular: normal 400 1em/1 "Font Awesome 7 Duotone";\n --fa-font-duotone-light: normal 300 1em/1 "Font Awesome 7 Duotone";\n --fa-font-duotone-thin: normal 100 1em/1 "Font Awesome 7 Duotone";\n --fa-font-brands: normal 400 1em/1 "Font Awesome 7 Brands";\n --fa-font-sharp-solid: normal 900 1em/1 "Font Awesome 7 Sharp";\n --fa-font-sharp-regular: normal 400 1em/1 "Font Awesome 7 Sharp";\n --fa-font-sharp-light: normal 300 1em/1 "Font Awesome 7 Sharp";\n --fa-font-sharp-thin: normal 100 1em/1 "Font Awesome 7 Sharp";\n --fa-font-sharp-duotone-solid: normal 900 1em/1 "Font Awesome 7 Sharp Duotone";\n --fa-font-sharp-duotone-regular: normal 400 1em/1 "Font Awesome 7 Sharp Duotone";\n --fa-font-sharp-duotone-light: normal 300 1em/1 "Font Awesome 7 Sharp Duotone";\n --fa-font-sharp-duotone-thin: normal 100 1em/1 "Font Awesome 7 Sharp Duotone";\n --fa-font-slab-regular: normal 400 1em/1 "Font Awesome 7 Slab";\n --fa-font-slab-press-regular: normal 400 1em/1 "Font Awesome 7 Slab Press";\n --fa-font-whiteboard-semibold: normal 600 1em/1 "Font Awesome 7 Whiteboard";\n --fa-font-thumbprint-light: normal 300 1em/1 "Font Awesome 7 Thumbprint";\n --fa-font-notdog-solid: normal 900 1em/1 "Font Awesome 7 Notdog";\n --fa-font-notdog-duo-solid: normal 900 1em/1 "Font Awesome 7 Notdog Duo";\n --fa-font-etch-solid: normal 900 1em/1 "Font Awesome 7 Etch";\n --fa-font-jelly-regular: normal 400 1em/1 "Font Awesome 7 Jelly";\n --fa-font-jelly-fill-regular: normal 400 1em/1 "Font Awesome 7 Jelly Fill";\n --fa-font-jelly-duo-regular: normal 400 1em/1 "Font Awesome 7 Jelly Duo";\n --fa-font-chisel-regular: normal 400 1em/1 "Font Awesome 7 Chisel";\n --fa-font-utility-semibold: normal 600 1em/1 "Font Awesome 7 Utility";\n --fa-font-utility-duo-semibold: normal 600 1em/1 "Font Awesome 7 Utility Duo";\n --fa-font-utility-fill-semibold: normal 600 1em/1 "Font Awesome 7 Utility Fill";\n}\n\n.svg-inline--fa {\n box-sizing: content-box;\n display: var(--fa-display, inline-block);\n height: 1em;\n overflow: visible;\n vertical-align: -0.125em;\n width: var(--fa-width, 1.25em);\n}\n.svg-inline--fa.fa-2xs {\n vertical-align: 0.1em;\n}\n.svg-inline--fa.fa-xs {\n vertical-align: 0em;\n}\n.svg-inline--fa.fa-sm {\n vertical-align: -0.0714285714em;\n}\n.svg-inline--fa.fa-lg {\n vertical-align: -0.2em;\n}\n.svg-inline--fa.fa-xl {\n vertical-align: -0.25em;\n}\n.svg-inline--fa.fa-2xl {\n vertical-align: -0.3125em;\n}\n.svg-inline--fa.fa-pull-left,\n.svg-inline--fa .fa-pull-start {\n float: inline-start;\n margin-inline-end: var(--fa-pull-margin, 0.3em);\n}\n.svg-inline--fa.fa-pull-right,\n.svg-inline--fa .fa-pull-end {\n float: inline-end;\n margin-inline-start: var(--fa-pull-margin, 0.3em);\n}\n.svg-inline--fa.fa-li {\n width: var(--fa-li-width, 2em);\n inset-inline-start: calc(-1 * var(--fa-li-width, 2em));\n inset-block-start: 0.25em; /* syncing vertical alignment with Web Font rendering */\n}\n\n.fa-layers-counter, .fa-layers-text {\n display: inline-block;\n position: absolute;\n text-align: center;\n}\n\n.fa-layers {\n display: inline-block;\n height: 1em;\n position: relative;\n text-align: center;\n vertical-align: -0.125em;\n width: var(--fa-width, 1.25em);\n}\n.fa-layers .svg-inline--fa {\n inset: 0;\n margin: auto;\n position: absolute;\n transform-origin: center center;\n}\n\n.fa-layers-text {\n left: 50%;\n top: 50%;\n transform: translate(-50%, -50%);\n transform-origin: center center;\n}\n\n.fa-layers-counter {\n background-color: var(--fa-counter-background-color, #ff253a);\n border-radius: var(--fa-counter-border-radius, 1em);\n box-sizing: border-box;\n color: var(--fa-inverse, #fff);\n line-height: var(--fa-counter-line-height, 1);\n max-width: var(--fa-counter-max-width, 5em);\n min-width: var(--fa-counter-min-width, 1.5em);\n overflow: hidden;\n padding: var(--fa-counter-padding, 0.25em 0.5em);\n right: var(--fa-right, 0);\n text-overflow: ellipsis;\n top: var(--fa-top, 0);\n transform: scale(var(--fa-counter-scale, 0.25));\n transform-origin: top right;\n}\n\n.fa-layers-bottom-right {\n bottom: var(--fa-bottom, 0);\n right: var(--fa-right, 0);\n top: auto;\n transform: scale(var(--fa-layers-scale, 0.25));\n transform-origin: bottom right;\n}\n\n.fa-layers-bottom-left {\n bottom: var(--fa-bottom, 0);\n left: var(--fa-left, 0);\n right: auto;\n top: auto;\n transform: scale(var(--fa-layers-scale, 0.25));\n transform-origin: bottom left;\n}\n\n.fa-layers-top-right {\n top: var(--fa-top, 0);\n right: var(--fa-right, 0);\n transform: scale(var(--fa-layers-scale, 0.25));\n transform-origin: top right;\n}\n\n.fa-layers-top-left {\n left: var(--fa-left, 0);\n right: auto;\n top: var(--fa-top, 0);\n transform: scale(var(--fa-layers-scale, 0.25));\n transform-origin: top left;\n}\n\n.fa-1x {\n font-size: 1em;\n}\n\n.fa-2x {\n font-size: 2em;\n}\n\n.fa-3x {\n font-size: 3em;\n}\n\n.fa-4x {\n font-size: 4em;\n}\n\n.fa-5x {\n font-size: 5em;\n}\n\n.fa-6x {\n font-size: 6em;\n}\n\n.fa-7x {\n font-size: 7em;\n}\n\n.fa-8x {\n font-size: 8em;\n}\n\n.fa-9x {\n font-size: 9em;\n}\n\n.fa-10x {\n font-size: 10em;\n}\n\n.fa-2xs {\n font-size: calc(10 / 16 * 1em); /* converts a 10px size into an em-based value that\'s relative to the scale\'s 16px base */\n line-height: calc(1 / 10 * 1em); /* sets the line-height of the icon back to that of it\'s parent */\n vertical-align: calc((6 / 10 - 0.375) * 1em); /* vertically centers the icon taking into account the surrounding text\'s descender */\n}\n\n.fa-xs {\n font-size: calc(12 / 16 * 1em); /* converts a 12px size into an em-based value that\'s relative to the scale\'s 16px base */\n line-height: calc(1 / 12 * 1em); /* sets the line-height of the icon back to that of it\'s parent */\n vertical-align: calc((6 / 12 - 0.375) * 1em); /* vertically centers the icon taking into account the surrounding text\'s descender */\n}\n\n.fa-sm {\n font-size: calc(14 / 16 * 1em); /* converts a 14px size into an em-based value that\'s relative to the scale\'s 16px base */\n line-height: calc(1 / 14 * 1em); /* sets the line-height of the icon back to that of it\'s parent */\n vertical-align: calc((6 / 14 - 0.375) * 1em); /* vertically centers the icon taking into account the surrounding text\'s descender */\n}\n\n.fa-lg {\n font-size: calc(20 / 16 * 1em); /* converts a 20px size into an em-based value that\'s relative to the scale\'s 16px base */\n line-height: calc(1 / 20 * 1em); /* sets the line-height of the icon back to that of it\'s parent */\n vertical-align: calc((6 / 20 - 0.375) * 1em); /* vertically centers the icon taking into account the surrounding text\'s descender */\n}\n\n.fa-xl {\n font-size: calc(24 / 16 * 1em); /* converts a 24px size into an em-based value that\'s relative to the scale\'s 16px base */\n line-height: calc(1 / 24 * 1em); /* sets the line-height of the icon back to that of it\'s parent */\n vertical-align: calc((6 / 24 - 0.375) * 1em); /* vertically centers the icon taking into account the surrounding text\'s descender */\n}\n\n.fa-2xl {\n font-size: calc(32 / 16 * 1em); /* converts a 32px size into an em-based value that\'s relative to the scale\'s 16px base */\n line-height: calc(1 / 32 * 1em); /* sets the line-height of the icon back to that of it\'s parent */\n vertical-align: calc((6 / 32 - 0.375) * 1em); /* vertically centers the icon taking into account the surrounding text\'s descender */\n}\n\n.fa-width-auto {\n --fa-width: auto;\n}\n\n.fa-fw,\n.fa-width-fixed {\n --fa-width: 1.25em;\n}\n\n.fa-ul {\n list-style-type: none;\n margin-inline-start: var(--fa-li-margin, 2.5em);\n padding-inline-start: 0;\n}\n.fa-ul > li {\n position: relative;\n}\n\n.fa-li {\n inset-inline-start: calc(-1 * var(--fa-li-width, 2em));\n position: absolute;\n text-align: center;\n width: var(--fa-li-width, 2em);\n line-height: inherit;\n}\n\n/* Heads Up: Bordered Icons will not be supported in the future!\n - This feature will be deprecated in the next major release of Font Awesome (v8)!\n - You may continue to use it in this version *v7), but it will not be supported in Font Awesome v8.\n*/\n/* Notes:\n* --@{v.$css-prefix}-border-width = 1/16 by default (to render as ~1px based on a 16px default font-size)\n* --@{v.$css-prefix}-border-padding =\n ** 3/16 for vertical padding (to give ~2px of vertical whitespace around an icon considering it\'s vertical alignment)\n ** 4/16 for horizontal padding (to give ~4px of horizontal whitespace around an icon)\n*/\n.fa-border {\n border-color: var(--fa-border-color, #eee);\n border-radius: var(--fa-border-radius, 0.1em);\n border-style: var(--fa-border-style, solid);\n border-width: var(--fa-border-width, 0.0625em);\n box-sizing: var(--fa-border-box-sizing, content-box);\n padding: var(--fa-border-padding, 0.1875em 0.25em);\n}\n\n.fa-pull-left,\n.fa-pull-start {\n float: inline-start;\n margin-inline-end: var(--fa-pull-margin, 0.3em);\n}\n\n.fa-pull-right,\n.fa-pull-end {\n float: inline-end;\n margin-inline-start: var(--fa-pull-margin, 0.3em);\n}\n\n.fa-beat {\n animation-name: fa-beat;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, ease-in-out);\n}\n\n.fa-bounce {\n animation-name: fa-bounce;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.28, 0.84, 0.42, 1));\n}\n\n.fa-fade {\n animation-name: fa-fade;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1));\n}\n\n.fa-beat-fade {\n animation-name: fa-beat-fade;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1));\n}\n\n.fa-flip {\n animation-name: fa-flip;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, ease-in-out);\n}\n\n.fa-shake {\n animation-name: fa-shake;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, linear);\n}\n\n.fa-spin {\n animation-name: fa-spin;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 2s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, linear);\n}\n\n.fa-spin-reverse {\n --fa-animation-direction: reverse;\n}\n\n.fa-pulse,\n.fa-spin-pulse {\n animation-name: fa-spin;\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, steps(8));\n}\n\n@media (prefers-reduced-motion: reduce) {\n .fa-beat,\n .fa-bounce,\n .fa-fade,\n .fa-beat-fade,\n .fa-flip,\n .fa-pulse,\n .fa-shake,\n .fa-spin,\n .fa-spin-pulse {\n animation: none !important;\n transition: none !important;\n }\n}\n@keyframes fa-beat {\n 0%, 90% {\n transform: scale(1);\n }\n 45% {\n transform: scale(var(--fa-beat-scale, 1.25));\n }\n}\n@keyframes fa-bounce {\n 0% {\n transform: scale(1, 1) translateY(0);\n }\n 10% {\n transform: scale(var(--fa-bounce-start-scale-x, 1.1), var(--fa-bounce-start-scale-y, 0.9)) translateY(0);\n }\n 30% {\n transform: scale(var(--fa-bounce-jump-scale-x, 0.9), var(--fa-bounce-jump-scale-y, 1.1)) translateY(var(--fa-bounce-height, -0.5em));\n }\n 50% {\n transform: scale(var(--fa-bounce-land-scale-x, 1.05), var(--fa-bounce-land-scale-y, 0.95)) translateY(0);\n }\n 57% {\n transform: scale(1, 1) translateY(var(--fa-bounce-rebound, -0.125em));\n }\n 64% {\n transform: scale(1, 1) translateY(0);\n }\n 100% {\n transform: scale(1, 1) translateY(0);\n }\n}\n@keyframes fa-fade {\n 50% {\n opacity: var(--fa-fade-opacity, 0.4);\n }\n}\n@keyframes fa-beat-fade {\n 0%, 100% {\n opacity: var(--fa-beat-fade-opacity, 0.4);\n transform: scale(1);\n }\n 50% {\n opacity: 1;\n transform: scale(var(--fa-beat-fade-scale, 1.125));\n }\n}\n@keyframes fa-flip {\n 50% {\n transform: rotate3d(var(--fa-flip-x, 0), var(--fa-flip-y, 1), var(--fa-flip-z, 0), var(--fa-flip-angle, -180deg));\n }\n}\n@keyframes fa-shake {\n 0% {\n transform: rotate(-15deg);\n }\n 4% {\n transform: rotate(15deg);\n }\n 8%, 24% {\n transform: rotate(-18deg);\n }\n 12%, 28% {\n transform: rotate(18deg);\n }\n 16% {\n transform: rotate(-22deg);\n }\n 20% {\n transform: rotate(22deg);\n }\n 32% {\n transform: rotate(-12deg);\n }\n 36% {\n transform: rotate(12deg);\n }\n 40%, 100% {\n transform: rotate(0deg);\n }\n}\n@keyframes fa-spin {\n 0% {\n transform: rotate(0deg);\n }\n 100% {\n transform: rotate(360deg);\n }\n}\n.fa-rotate-90 {\n transform: rotate(90deg);\n}\n\n.fa-rotate-180 {\n transform: rotate(180deg);\n}\n\n.fa-rotate-270 {\n transform: rotate(270deg);\n}\n\n.fa-flip-horizontal {\n transform: scale(-1, 1);\n}\n\n.fa-flip-vertical {\n transform: scale(1, -1);\n}\n\n.fa-flip-both,\n.fa-flip-horizontal.fa-flip-vertical {\n transform: scale(-1, -1);\n}\n\n.fa-rotate-by {\n transform: rotate(var(--fa-rotate-angle, 0));\n}\n\n.svg-inline--fa .fa-primary {\n fill: var(--fa-primary-color, currentColor);\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa .fa-secondary {\n fill: var(--fa-secondary-color, currentColor);\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-primary {\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-secondary {\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa mask .fa-primary,\n.svg-inline--fa mask .fa-secondary {\n fill: black;\n}\n\n.svg-inline--fa.fa-inverse {\n fill: var(--fa-inverse, #fff);\n}\n\n.fa-stack {\n display: inline-block;\n height: 2em;\n line-height: 2em;\n position: relative;\n vertical-align: middle;\n width: 2.5em;\n}\n\n.fa-inverse {\n color: var(--fa-inverse, #fff);\n}\n\n.svg-inline--fa.fa-stack-1x {\n --fa-width: 1.25em;\n height: 1em;\n width: var(--fa-width);\n}\n.svg-inline--fa.fa-stack-2x {\n --fa-width: 2.5em;\n height: 2em;\n width: var(--fa-width);\n}\n\n.fa-stack-1x,\n.fa-stack-2x {\n inset: 0;\n margin: auto;\n position: absolute;\n z-index: var(--fa-stack-z-index, auto);\n}';if(n!==e||r!==t){var o=new RegExp("\\.".concat(e,"\\-"),"g"),i=new RegExp("\\--".concat(e,"\\-"),"g"),l=new RegExp("\\.".concat(t),"g");a=a.replace(o,".".concat(n,"-")).replace(i,"--".concat(n,"-")).replace(l,".".concat(r))}return a}var Tt=!1;function Ct(){gt.autoAddCss&&!Tt&&(!function(e){if(e&&ae){var t=ee.createElement("style");t.setAttribute("type","text/css"),t.innerHTML=e;for(var n=ee.head.childNodes,r=null,a=n.length-1;a>-1;a--){var o=n[a],i=(o.tagName||"").toUpperCase();["STYLE","LINK"].indexOf(i)>-1&&(r=o)}ee.head.insertBefore(t,r)}}(Mt()),Tt=!0)}var jt={mixout:function(){return{dom:{css:Mt,insertCss:Ct}}},hooks:function(){return{beforeDOMElementCreation:function(){Ct()},beforeI2svg:function(){Ct()}}}},Ot=G||{};Ot[He]||(Ot[He]={}),Ot[He].styles||(Ot[He].styles={}),Ot[He].hooks||(Ot[He].hooks={}),Ot[He].shims||(Ot[He].shims=[]);var Rt=Ot[He],Pt=[],Et=function(){ee.removeEventListener("DOMContentLoaded",Et),Ft=1,Pt.map(function(e){return e()})},Ft=!1;function At(e){var t=e.tag,n=e.attributes,r=void 0===n?{}:n,a=e.children,o=void 0===a?[]:a;return"string"==typeof e?_t(e):"<".concat(t," ").concat(function(e){return Object.keys(e||{}).reduce(function(t,n){return t+"".concat(n,'="').concat(_t(e[n]),'" ')},"").trim()}(r),">").concat(o.map(At).join(""),"</").concat(t,">")}function It(e,t,n){if(e&&e[t]&&e[t][n])return{prefix:t,iconName:n,icon:e[t][n]}}ae&&((Ft=(ee.documentElement.doScroll?/^loaded|^c/:/^loaded|^i|^c/).test(ee.readyState))||ee.addEventListener("DOMContentLoaded",Et));var Dt=function(e,t,n,r){var a,o,i,l=Object.keys(e),s=l.length,c=t;for(void 0===n?(a=1,i=e[l[0]]):(a=0,i=n);a<s;a++)i=c(i,e[o=l[a]],o,e);return i};function Bt(e){return 1!==V(e).length?null:e.codePointAt(0).toString(16)}function Lt(e){return Object.keys(e).reduce(function(t,n){var r=e[n];return!!r.icon?t[r.iconName]=r.icon:t[n]=r,t},{})}function $t(e,t){var n=(arguments.length>2&&void 0!==arguments[2]?arguments[2]:{}).skipHooks,r=void 0!==n&&n,a=Lt(t);"function"!=typeof Rt.hooks.addPack||r?Rt.styles[e]=$($({},Rt.styles[e]||{}),a):Rt.hooks.addPack(e,Lt(t)),"fas"===e&&$t("fa",t)}var zt=Rt.styles,Vt=Rt.shims,Ht=Object.keys(ot),Wt=Ht.reduce(function(e,t){return e[t]=Object.keys(ot[t]),e},{}),Ut=null,Jt={},Qt={},qt={},Xt={},Yt={};function Kt(e,t){var n,r=t.split("-"),a=r[0],o=r.slice(1).join("-");return a!==e||""===o||(n=o,~dt.indexOf(n))?null:o}var Zt,Gt=function(){var e=function(e){return Dt(zt,function(t,n,r){return t[r]=Dt(n,e,{}),t},{})};Jt=e(function(e,t,n){(t[3]&&(e[t[3]]=n),t[2])&&t[2].filter(function(e){return"number"==typeof e}).forEach(function(t){e[t.toString(16)]=n});return e}),Qt=e(function(e,t,n){(e[n]=n,t[2])&&t[2].filter(function(e){return"string"==typeof e}).forEach(function(t){e[t]=n});return e}),Yt=e(function(e,t,n){var r=t[2];return e[n]=n,r.forEach(function(t){e[t]=n}),e});var t="far"in zt||gt.autoFetchSvg,n=Dt(Vt,function(e,n){var r=n[0],a=n[1],o=n[2];return"far"!==a||t||(a="fas"),"string"==typeof r&&(e.names[r]={prefix:a,iconName:o}),"number"==typeof r&&(e.unicodes[r.toString(16)]={prefix:a,iconName:o}),e},{names:{},unicodes:{}});qt=n.names,Xt=n.unicodes,Ut=an(gt.styleDefault,{family:gt.familyDefault})};function en(e,t){return(Jt[e]||{})[t]}function tn(e,t){return(Yt[e]||{})[t]}function nn(e){return qt[e]||{prefix:null,iconName:null}}function rn(){return Ut}Zt=function(e){Ut=an(e.styleDefault,{family:gt.familyDefault})},vt.push(Zt),Gt();function an(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).family,n=void 0===t?se:t,r=tt[n][e];if(n===ce&&!e)return"fad";var a=rt[n][e]||rt[n][r],o=e in Rt.styles?e:null;return a||o||null}function on(e){return e.sort().filter(function(e,t,n){return n.indexOf(e)===t})}var ln=Le.concat(Ce);function sn(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).skipLookups,n=void 0!==t&&t,r=null,a=on(e.filter(function(e){return ln.includes(e)})),o=on(e.filter(function(e){return!ln.includes(e)})),i=z(a.filter(function(e){return r=e,!le.includes(e)}),1)[0],l=void 0===i?null:i,s=function(e){var t=se,n=Ht.reduce(function(e,t){return e[t]="".concat(gt.cssPrefix,"-").concat(t),e},{});return Me.forEach(function(r){(e.includes(n[r])||e.some(function(e){return Wt[r].includes(e)}))&&(t=r)}),t}(a),c=$($({},function(e){var t=[],n=null;return e.forEach(function(e){var r=Kt(gt.cssPrefix,e);r?n=r:e&&t.push(e)}),{iconName:n,rest:t}}(o)),{},{prefix:an(l,{family:s})});return $($($({},c),function(e){var t=e.values,n=e.family,r=e.canonical,a=e.givenPrefix,o=void 0===a?"":a,i=e.styles,l=void 0===i?{}:i,s=e.config,c=void 0===s?{}:s,u=n===ce,f=t.includes("fa-duotone")||t.includes("fad"),d="duotone"===c.familyDefault,h="fad"===r.prefix||"fa-duotone"===r.prefix;!u&&(f||d||h)&&(r.prefix="fad");(t.includes("fa-brands")||t.includes("fab"))&&(r.prefix="fab");if(!r.prefix&&cn.includes(n)){if(Object.keys(l).find(function(e){return un.includes(e)})||c.autoFetchSvg){var m=Te.get(n).defaultShortPrefixId;r.prefix=m,r.iconName=tn(r.prefix,r.iconName)||r.iconName}}"fa"!==r.prefix&&"fa"!==o||(r.prefix=rn()||"fas");return r}({values:e,family:s,styles:zt,config:gt,canonical:c,givenPrefix:r})),function(e,t,n){var r=n.prefix,a=n.iconName;if(e||!r||!a)return{prefix:r,iconName:a};var o="fa"===t?nn(a):{},i=tn(r,a);a=o.iconName||i||a,"far"!==(r=o.prefix||r)||zt.far||!zt.fas||gt.autoFetchSvg||(r="fas");return{prefix:r,iconName:a}}(n,r,c))}var cn=Me.filter(function(e){return e!==se||e!==ce}),un=Object.keys(Be).filter(function(e){return e!==se}).map(function(e){return Object.keys(Be[e])}).flat();var fn=function(){return I(function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.definitions={}},[{key:"add",value:function(){for(var e=this,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var a=n.reduce(this._pullDefinitions,{});Object.keys(a).forEach(function(t){e.definitions[t]=$($({},e.definitions[t]||{}),a[t]),$t(t,a[t]);var n=ot[se][t];n&&$t(n,a[t]),Gt()})}},{key:"reset",value:function(){this.definitions={}}},{key:"_pullDefinitions",value:function(e,t){var n=t.prefix&&t.iconName&&t.icon?{0:t}:t;return Object.keys(n).map(function(t){var r=n[t],a=r.prefix,o=r.iconName,i=r.icon,l=i[2];e[a]||(e[a]={}),l.length>0&&l.forEach(function(t){"string"==typeof t&&(e[a][t]=i)}),e[a][o]=i}),e}}])}(),dn=[],hn={},mn={},pn=Object.keys(mn);function gn(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),a=2;a<n;a++)r[a-2]=arguments[a];return(hn[e]||[]).forEach(function(e){t=e.apply(null,[t].concat(r))}),t}function vn(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];(hn[e]||[]).forEach(function(e){e.apply(null,n)})}function bn(){var e=arguments[0],t=Array.prototype.slice.call(arguments,1);return mn[e]?mn[e].apply(null,t):void 0}function yn(e){"fa"===e.prefix&&(e.prefix="fas");var t=e.iconName,n=e.prefix||rn();if(t)return t=tn(n,t)||t,It(wn.definitions,n,t)||It(Rt.styles,n,t)}var wn=new fn,xn={i2svg:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return ae?(vn("beforeI2svg",e),bn("pseudoElements2svg",e),bn("i2svg",e)):Promise.reject(new Error("Operation requires a DOM of some kind."))},watch:function(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=t.autoReplaceSvgRoot;!1===gt.autoReplaceSvg&&(gt.autoReplaceSvg=!0),gt.observeMutations=!0,e=function(){_n({autoReplaceSvgRoot:n}),vn("watch",t)},ae&&(Ft?setTimeout(e,0):Pt.push(e))}},kn={noAuto:function(){gt.autoReplaceSvg=!1,gt.observeMutations=!1,vn("noAuto")},config:gt,dom:xn,parse:{icon:function(e){if(null===e)return null;if("object"===W(e)&&e.prefix&&e.iconName)return{prefix:e.prefix,iconName:tn(e.prefix,e.iconName)||e.iconName};if(Array.isArray(e)&&2===e.length){var t=0===e[1].indexOf("fa-")?e[1].slice(3):e[1],n=an(e[0]);return{prefix:n,iconName:tn(n,t)||t}}if("string"==typeof e&&(e.indexOf("".concat(gt.cssPrefix,"-"))>-1||e.match(lt))){var r=sn(e.split(" "),{skipLookups:!0});return{prefix:r.prefix||rn(),iconName:tn(r.prefix,r.iconName)||r.iconName}}if("string"==typeof e){var a=rn();return{prefix:a,iconName:tn(a,e)||e}}}},library:wn,findIconDefinition:yn,toHtml:At},_n=function(){var e=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}).autoReplaceSvgRoot,t=void 0===e?ee:e;(Object.keys(Rt.styles).length>0||gt.autoFetchSvg)&&ae&>.autoReplaceSvg&&kn.dom.i2svg({node:t})};function Nn(e,t){return Object.defineProperty(e,"abstract",{get:t}),Object.defineProperty(e,"html",{get:function(){return e.abstract.map(function(e){return At(e)})}}),Object.defineProperty(e,"node",{get:function(){if(ae){var t=ee.createElement("div");return t.innerHTML=e.html,t.children}}}),e}function Sn(e){var t=e.icons,n=t.main,r=t.mask,a=e.prefix,o=e.iconName,i=e.transform,l=e.symbol,s=e.maskId,c=e.extra,u=e.watchable,f=void 0!==u&&u,d=r.found?r:n,h=d.width,m=d.height,p=[gt.replacementClass,o?"".concat(gt.cssPrefix,"-").concat(o):""].filter(function(e){return-1===c.classes.indexOf(e)}).filter(function(e){return""!==e||!!e}).concat(c.classes).join(" "),g={children:[],attributes:$($({},c.attributes),{},{"data-prefix":a,"data-icon":o,class:p,role:c.attributes.role||"img",viewBox:"0 0 ".concat(h," ").concat(m)})};(function(e){return["aria-label","aria-labelledby","title","role"].some(function(t){return t in e})})(c.attributes)||c.attributes["aria-hidden"]||(g.attributes["aria-hidden"]="true"),f&&(g.attributes[Ue]="");var v=$($({},g),{},{prefix:a,iconName:o,main:n,mask:r,maskId:s,transform:i,symbol:l,styles:$({},c.styles)}),b=r.found&&n.found?bn("generateAbstractMask",v)||{children:[],attributes:{}}:bn("generateAbstractIcon",v)||{children:[],attributes:{}},y=b.children,w=b.attributes;return v.children=y,v.attributes=w,l?function(e){var t=e.prefix,n=e.iconName,r=e.children,a=e.attributes,o=e.symbol,i=!0===o?"".concat(t,"-").concat(gt.cssPrefix,"-").concat(n):o;return[{tag:"svg",attributes:{style:"display: none;"},children:[{tag:"symbol",attributes:$($({},a),{},{id:i}),children:r}]}]}(v):function(e){var t=e.children,n=e.main,r=e.mask,a=e.attributes,o=e.styles,i=e.transform;if(St(i)&&n.found&&!r.found){var l={x:n.width/n.height/2,y:.5};a.style=Nt($($({},o),{},{"transform-origin":"".concat(l.x+i.x/16,"em ").concat(l.y+i.y/16,"em")}))}return[{tag:"svg",attributes:a,children:t}]}(v)}function Mn(e){var t=e.content,n=e.width,r=e.height,a=e.transform,o=e.extra,i=e.watchable,l=void 0!==i&&i,s=$($({},o.attributes),{},{class:o.classes.join(" ")});l&&(s[Ue]="");var c=$({},o.styles);St(a)&&(c.transform=function(e){var t=e.transform,n=e.width,r=void 0===n?16:n,a=e.height,o=void 0===a?16:a,i="";return i+=oe?"translate(".concat(t.x/bt-r/2,"em, ").concat(t.y/bt-o/2,"em) "):"translate(calc(-50% + ".concat(t.x/bt,"em), calc(-50% + ").concat(t.y/bt,"em)) "),i+="scale(".concat(t.size/bt*(t.flipX?-1:1),", ").concat(t.size/bt*(t.flipY?-1:1),") "),i+"rotate(".concat(t.rotate,"deg) ")}({transform:a,width:n,height:r}),c["-webkit-transform"]=c.transform);var u=Nt(c);u.length>0&&(s.style=u);var f=[];return f.push({tag:"span",attributes:s,children:[t]}),f}var Tn=Rt.styles;function Cn(e){var t=e[0],n=e[1],r=z(e.slice(4),1)[0];return{found:!0,width:t,height:n,icon:Array.isArray(r)?{tag:"g",attributes:{class:"".concat(gt.cssPrefix,"-").concat(ft.GROUP)},children:[{tag:"path",attributes:{class:"".concat(gt.cssPrefix,"-").concat(ft.SECONDARY),fill:"currentColor",d:r[0]}},{tag:"path",attributes:{class:"".concat(gt.cssPrefix,"-").concat(ft.PRIMARY),fill:"currentColor",d:r[1]}}]}:{tag:"path",attributes:{fill:"currentColor",d:r}}}}var jn={found:!1,width:512,height:512};function On(e,t){var n=t;return"fa"===t&&null!==gt.styleDefault&&(t=rn()),new Promise(function(r,a){if("fa"===n){var o=nn(e)||{};e=o.iconName||e,t=o.prefix||t}if(e&&t&&Tn[t]&&Tn[t][e])return r(Cn(Tn[t][e]));!function(e,t){Ze||gt.showMissingIcons||!e||console.error('Icon with name "'.concat(e,'" and prefix "').concat(t,'" is missing.'))}(e,t),r($($({},jn),{},{icon:gt.showMissingIcons&&e&&bn("missingIconAbstract")||{}}))})}var Rn=function(){},Pn=gt.measurePerformance&&ne&&ne.mark&&ne.measure?ne:{mark:Rn,measure:Rn},En='FA "7.1.0"',Fn=function(e){Pn.mark("".concat(En," ").concat(e," ends")),Pn.measure("".concat(En," ").concat(e),"".concat(En," ").concat(e," begins"),"".concat(En," ").concat(e," ends"))},An=function(e){return Pn.mark("".concat(En," ").concat(e," begins")),function(){return Fn(e)}},In=function(){};function Dn(e){return"string"==typeof(e.getAttribute?e.getAttribute(Ue):null)}function Bn(e){return ee.createElementNS("http://www.w3.org/2000/svg",e)}function Ln(e){return ee.createElement(e)}function $n(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).ceFn,n=void 0===t?"svg"===e.tag?Bn:Ln:t;if("string"==typeof e)return ee.createTextNode(e);var r=n(e.tag);return Object.keys(e.attributes||[]).forEach(function(t){r.setAttribute(t,e.attributes[t])}),(e.children||[]).forEach(function(e){r.appendChild($n(e,{ceFn:n}))}),r}var zn={replace:function(e){var t=e[0];if(t.parentNode)if(e[1].forEach(function(e){t.parentNode.insertBefore($n(e),t)}),null===t.getAttribute(Ue)&>.keepOriginalSource){var n=ee.createComment(function(e){var t=" ".concat(e.outerHTML," ");return"".concat(t,"Font Awesome fontawesome.com ")}(t));t.parentNode.replaceChild(n,t)}else t.remove()},nest:function(e){var t=e[0],n=e[1];if(~kt(t).indexOf(gt.replacementClass))return zn.replace(e);var r=new RegExp("".concat(gt.cssPrefix,"-.*"));if(delete n[0].attributes.id,n[0].attributes.class){var a=n[0].attributes.class.split(" ").reduce(function(e,t){return t===gt.replacementClass||t.match(r)?e.toSvg.push(t):e.toNode.push(t),e},{toNode:[],toSvg:[]});n[0].attributes.class=a.toSvg.join(" "),0===a.toNode.length?t.removeAttribute("class"):t.setAttribute("class",a.toNode.join(" "))}var o=n.map(function(e){return At(e)}).join("\n");t.setAttribute(Ue,""),t.innerHTML=o}};function Vn(e){e()}function Hn(e,t){var n="function"==typeof t?t:In;if(0===e.length)n();else{var r=Vn;"async"===gt.mutateApproach&&(r=G.requestAnimationFrame||Vn),r(function(){var t=!0===gt.autoReplaceSvg?zn.replace:zn[gt.autoReplaceSvg]||zn.replace,r=An("mutate");e.map(t),r(),n()})}}var Wn=!1;function Un(){Wn=!0}function Jn(){Wn=!1}var Qn=null;function qn(e){if(te&>.observeMutations){var t=e.treeCallback,n=void 0===t?In:t,r=e.nodeCallback,a=void 0===r?In:r,o=e.pseudoElementsCallback,i=void 0===o?In:o,l=e.observeMutationsRoot,s=void 0===l?ee:l;Qn=new te(function(e){if(!Wn){var t=rn();xt(e).forEach(function(e){if("childList"===e.type&&e.addedNodes.length>0&&!Dn(e.addedNodes[0])&&(gt.searchPseudoElements&&i(e.target),n(e.target)),"attributes"===e.type&&e.target.parentNode&>.searchPseudoElements&&i([e.target],!0),"attributes"===e.type&&Dn(e.target)&&~ut.indexOf(e.attributeName))if("class"===e.attributeName&&function(e){var t=e.getAttribute?e.getAttribute(Qe):null,n=e.getAttribute?e.getAttribute(qe):null;return t&&n}(e.target)){var r=sn(kt(e.target)),o=r.prefix,l=r.iconName;e.target.setAttribute(Qe,o||t),l&&e.target.setAttribute(qe,l)}else(s=e.target)&&s.classList&&s.classList.contains&&s.classList.contains(gt.replacementClass)&&a(e.target);var s})}}),ae&&Qn.observe(s,{childList:!0,attributes:!0,characterData:!0,subtree:!0})}}function Xn(e){var t,n,r=e.getAttribute("data-prefix"),a=e.getAttribute("data-icon"),o=void 0!==e.innerText?e.innerText.trim():"",i=sn(kt(e));return i.prefix||(i.prefix=rn()),r&&a&&(i.prefix=r,i.iconName=a),i.iconName&&i.prefix||(i.prefix&&o.length>0&&(i.iconName=(t=i.prefix,n=e.innerText,(Qt[t]||{})[n]||en(i.prefix,Bt(e.innerText)))),!i.iconName&>.autoFetchSvg&&e.firstChild&&e.firstChild.nodeType===Node.TEXT_NODE&&(i.iconName=e.firstChild.data)),i}function Yn(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{styleParser:!0},n=Xn(e),r=n.iconName,a=n.prefix,o=n.rest,i=function(e){return xt(e.attributes).reduce(function(e,t){return"class"!==e.name&&"style"!==e.name&&(e[t.name]=t.value),e},{})}(e),l=gn("parseNodeAttributes",{},e),s=t.styleParser?function(e){var t=e.getAttribute("style"),n=[];return t&&(n=t.split(";").reduce(function(e,t){var n=t.split(":"),r=n[0],a=n.slice(1);return r&&a.length>0&&(e[r]=a.join(":").trim()),e},{})),n}(e):[];return $({iconName:r,prefix:a,transform:yt,mask:{iconName:null,prefix:null,rest:[]},maskId:null,symbol:!1,extra:{classes:o,styles:s,attributes:i}},l)}var Kn=Rt.styles;function Zn(e){var t="nest"===gt.autoReplaceSvg?Yn(e,{styleParser:!1}):Yn(e);return~t.extra.classes.indexOf(st)?bn("generateLayersText",e,t):bn("generateSvgReplacementMutation",e,t)}function Gn(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if(!ae)return Promise.resolve();var n=ee.documentElement.classList,r=function(e){return n.add("".concat(Xe,"-").concat(e))},a=function(e){return n.remove("".concat(Xe,"-").concat(e))},o=gt.autoFetchSvg?[].concat(V(Ce),V(Le)):le.concat(Object.keys(Kn));o.includes("fa")||o.push("fa");var i=[".".concat(st,":not([").concat(Ue,"])")].concat(o.map(function(e){return".".concat(e,":not([").concat(Ue,"])")})).join(", ");if(0===i.length)return Promise.resolve();var l=[];try{l=xt(e.querySelectorAll(i))}catch(e){}if(!(l.length>0))return Promise.resolve();r("pending"),a("complete");var s=An("onTree"),c=l.reduce(function(e,t){try{var n=Zn(t);n&&e.push(n)}catch(e){Ze||"MissingIcon"===e.name&&console.error(e)}return e},[]);return new Promise(function(e,n){Promise.all(c).then(function(n){Hn(n,function(){r("active"),r("complete"),a("pending"),"function"==typeof t&&t(),s(),e()})}).catch(function(e){s(),n(e)})})}function er(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;Zn(e).then(function(e){e&&Hn([e],t)})}var tr=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.transform,r=void 0===n?yt:n,a=t.symbol,o=void 0!==a&&a,i=t.mask,l=void 0===i?null:i,s=t.maskId,c=void 0===s?null:s,u=t.classes,f=void 0===u?[]:u,d=t.attributes,h=void 0===d?{}:d,m=t.styles,p=void 0===m?{}:m;if(e){var g=e.prefix,v=e.iconName,b=e.icon;return Nn($({type:"icon"},e),function(){return vn("beforeDOMElementCreation",{iconDefinition:e,params:t}),Sn({icons:{main:Cn(b),mask:l?Cn(l.icon):{found:!1,width:null,height:null,icon:{}}},prefix:g,iconName:v,transform:$($({},yt),r),symbol:o,maskId:c,extra:{attributes:h,styles:p,classes:f}})})}},nr={mixout:function(){return{icon:(e=tr,function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=(t||{}).icon?t:yn(t||{}),a=n.mask;return a&&(a=(a||{}).icon?a:yn(a||{})),e(r,$($({},n),{},{mask:a}))})};var e},hooks:function(){return{mutationObserverCallbacks:function(e){return e.treeCallback=Gn,e.nodeCallback=er,e}}},provides:function(e){e.i2svg=function(e){var t=e.node,n=void 0===t?ee:t,r=e.callback;return Gn(n,void 0===r?function(){}:r)},e.generateSvgReplacementMutation=function(e,t){var n=t.iconName,r=t.prefix,a=t.transform,o=t.symbol,i=t.mask,l=t.maskId,s=t.extra;return new Promise(function(t,c){Promise.all([On(n,r),i.iconName?On(i.iconName,i.prefix):Promise.resolve({found:!1,width:512,height:512,icon:{}})]).then(function(i){var c=z(i,2),u=c[0],f=c[1];t([e,Sn({icons:{main:u,mask:f},prefix:r,iconName:n,transform:a,symbol:o,maskId:l,extra:s,watchable:!0})])}).catch(c)})},e.generateAbstractIcon=function(e){var t,n=e.children,r=e.attributes,a=e.main,o=e.transform,i=Nt(e.styles);return i.length>0&&(r.style=i),St(o)&&(t=bn("generateAbstractTransformGrouping",{main:a,transform:o,containerWidth:a.width,iconWidth:a.width})),n.push(t||a.icon),{children:n,attributes:r}}}},rr={mixout:function(){return{layer:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.classes,r=void 0===n?[]:n;return Nn({type:"layer"},function(){vn("beforeDOMElementCreation",{assembler:e,params:t});var n=[];return e(function(e){Array.isArray(e)?e.map(function(e){n=n.concat(e.abstract)}):n=n.concat(e.abstract)}),[{tag:"span",attributes:{class:["".concat(gt.cssPrefix,"-layers")].concat(V(r)).join(" ")},children:n}]})}}}},ar={mixout:function(){return{counter:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};t.title;var n=t.classes,r=void 0===n?[]:n,a=t.attributes,o=void 0===a?{}:a,i=t.styles,l=void 0===i?{}:i;return Nn({type:"counter",content:e},function(){return vn("beforeDOMElementCreation",{content:e,params:t}),function(e){var t=e.content,n=e.extra,r=$($({},n.attributes),{},{class:n.classes.join(" ")}),a=Nt(n.styles);a.length>0&&(r.style=a);var o=[];return o.push({tag:"span",attributes:r,children:[t]}),o}({content:e.toString(),extra:{attributes:o,styles:l,classes:["".concat(gt.cssPrefix,"-layers-counter")].concat(V(r))}})})}}}},or={mixout:function(){return{text:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.transform,r=void 0===n?yt:n,a=t.classes,o=void 0===a?[]:a,i=t.attributes,l=void 0===i?{}:i,s=t.styles,c=void 0===s?{}:s;return Nn({type:"text",content:e},function(){return vn("beforeDOMElementCreation",{content:e,params:t}),Mn({content:e,transform:$($({},yt),r),extra:{attributes:l,styles:c,classes:["".concat(gt.cssPrefix,"-layers-text")].concat(V(o))}})})}}},provides:function(e){e.generateLayersText=function(e,t){var n=t.transform,r=t.extra,a=null,o=null;if(oe){var i=parseInt(getComputedStyle(e).fontSize,10),l=e.getBoundingClientRect();a=l.width/i,o=l.height/i}return Promise.resolve([e,Mn({content:e.innerHTML,width:a,height:o,transform:n,extra:r,watchable:!0})])}}},ir=new RegExp('"',"ug"),lr=[1105920,1112319],sr=$($($($({},{FontAwesome:{normal:"fas",400:"fas"}}),{"Font Awesome 7 Free":{900:"fas",400:"far"},"Font Awesome 7 Pro":{900:"fas",400:"far",normal:"far",300:"fal",100:"fat"},"Font Awesome 7 Brands":{400:"fab",normal:"fab"},"Font Awesome 7 Duotone":{900:"fad",400:"fadr",normal:"fadr",300:"fadl",100:"fadt"},"Font Awesome 7 Sharp":{900:"fass",400:"fasr",normal:"fasr",300:"fasl",100:"fast"},"Font Awesome 7 Sharp Duotone":{900:"fasds",400:"fasdr",normal:"fasdr",300:"fasdl",100:"fasdt"},"Font Awesome 7 Jelly":{400:"fajr",normal:"fajr"},"Font Awesome 7 Jelly Fill":{400:"fajfr",normal:"fajfr"},"Font Awesome 7 Jelly Duo":{400:"fajdr",normal:"fajdr"},"Font Awesome 7 Slab":{400:"faslr",normal:"faslr"},"Font Awesome 7 Slab Press":{400:"faslpr",normal:"faslpr"},"Font Awesome 7 Thumbprint":{300:"fatl",normal:"fatl"},"Font Awesome 7 Notdog":{900:"fans",normal:"fans"},"Font Awesome 7 Notdog Duo":{900:"fands",normal:"fands"},"Font Awesome 7 Etch":{900:"faes",normal:"faes"},"Font Awesome 7 Chisel":{400:"facr",normal:"facr"},"Font Awesome 7 Whiteboard":{600:"fawsb",normal:"fawsb"},"Font Awesome 7 Utility":{600:"fausb",normal:"fausb"},"Font Awesome 7 Utility Duo":{600:"faudsb",normal:"faudsb"},"Font Awesome 7 Utility Fill":{600:"faufsb",normal:"faufsb"}}),{"Font Awesome 5 Free":{900:"fas",400:"far"},"Font Awesome 5 Pro":{900:"fas",400:"far",normal:"far",300:"fal"},"Font Awesome 5 Brands":{400:"fab",normal:"fab"},"Font Awesome 5 Duotone":{900:"fad"}}),{"Font Awesome Kit":{400:"fak",normal:"fak"},"Font Awesome Kit Duotone":{400:"fakd",normal:"fakd"}}),cr=Object.keys(sr).reduce(function(e,t){return e[t.toLowerCase()]=sr[t],e},{}),ur=Object.keys(cr).reduce(function(e,t){var n=cr[t];return e[t]=n[900]||V(Object.entries(n))[0][1],e},{});function fr(e,t){var n="".concat("data-fa-pseudo-element-pending").concat(t.replace(":","-"));return new Promise(function(r,a){if(null!==e.getAttribute(n))return r();var o,i,l,s=xt(e.children).filter(function(e){return e.getAttribute(Je)===t})[0],c=G.getComputedStyle(e,t),u=c.getPropertyValue("font-family"),f=u.match(ct),d=c.getPropertyValue("font-weight"),h=c.getPropertyValue("content");if(s&&!f)return e.removeChild(s),r();if(f&&"none"!==h&&""!==h){var m=c.getPropertyValue("content"),p=function(e,t){var n=e.replace(/^['"]|['"]$/g,"").toLowerCase(),r=parseInt(t),a=isNaN(r)?"normal":r;return(cr[n]||{})[a]||ur[n]}(u,d),g=function(e){return Bt(V(e.replace(ir,""))[0]||"")}(m),v=f[0].startsWith("FontAwesome"),b=function(e){var t=e.getPropertyValue("font-feature-settings").includes("ss01"),n=e.getPropertyValue("content").replace(ir,""),r=n.codePointAt(0),a=r>=lr[0]&&r<=lr[1],o=2===n.length&&n[0]===n[1];return a||o||t}(c),y=en(p,g),w=y;if(v){var x=(i=Xt[o=g],l=en("fas",o),i||(l?{prefix:"fas",iconName:l}:null)||{prefix:null,iconName:null});x.iconName&&x.prefix&&(y=x.iconName,p=x.prefix)}if(!y||b||s&&s.getAttribute(Qe)===p&&s.getAttribute(qe)===w)r();else{e.setAttribute(n,w),s&&e.removeChild(s);var k={iconName:null,prefix:null,transform:yt,symbol:!1,mask:{iconName:null,prefix:null,rest:[]},maskId:null,extra:{classes:[],styles:{},attributes:{}}},_=k.extra;_.attributes[Je]=t,On(y,p).then(function(a){var o=Sn($($({},k),{},{icons:{main:a,mask:{prefix:null,iconName:null,rest:[]}},prefix:p,iconName:w,extra:_,watchable:!0})),i=ee.createElementNS("http://www.w3.org/2000/svg","svg");"::before"===t?e.insertBefore(i,e.firstChild):e.appendChild(i),i.outerHTML=o.map(function(e){return At(e)}).join("\n"),e.removeAttribute(n),r()}).catch(a)}}else r()})}function dr(e){return Promise.all([fr(e,"::before"),fr(e,"::after")])}function hr(e){return!(e.parentNode===document.head||~Ye.indexOf(e.tagName.toUpperCase())||e.getAttribute(Je)||e.parentNode&&"svg"===e.parentNode.tagName)}var mr=function(e){return!!e&&Ke.some(function(t){return e.includes(t)})},pr=function(e){if(!e)return[];var t=new Set,n=e.split(/,(?![^()]*\))/).map(function(e){return e.trim()});n=n.flatMap(function(e){return e.includes("(")?e:e.split(",").map(function(e){return e.trim()})});var r,a=D(n);try{for(a.s();!(r=a.n()).done;){var o=r.value;if(mr(o)){var i=Ke.reduce(function(e,t){return e.replace(t,"")},o);""!==i&&"*"!==i&&t.add(i)}}}catch(e){a.e(e)}finally{a.f()}return t};function gr(e){if(ae){var t;if(arguments.length>1&&void 0!==arguments[1]&&arguments[1])t=e;else if(gt.searchPseudoElementsFullScan)t=e.querySelectorAll("*");else{var n,r=new Set,a=D(document.styleSheets);try{for(a.s();!(n=a.n()).done;){var o=n.value;try{var i,l=D(o.cssRules);try{for(l.s();!(i=l.n()).done;){var s,c=i.value,u=D(pr(c.selectorText));try{for(u.s();!(s=u.n()).done;){var f=s.value;r.add(f)}}catch(e){u.e(e)}finally{u.f()}}}catch(e){l.e(e)}finally{l.f()}}catch(e){gt.searchPseudoElementsWarnings&&console.warn("Font Awesome: cannot parse stylesheet: ".concat(o.href," (").concat(e.message,')\nIf it declares any Font Awesome CSS pseudo-elements, they will not be rendered as SVG icons. Add crossorigin="anonymous" to the <link>, enable searchPseudoElementsFullScan for slower but more thorough DOM parsing, or suppress this warning by setting searchPseudoElementsWarnings to false.'))}}}catch(e){a.e(e)}finally{a.f()}if(!r.size)return;var d=Array.from(r).join(", ");try{t=e.querySelectorAll(d)}catch(e){}}return new Promise(function(e,n){var r=xt(t).filter(hr).map(dr),a=An("searchPseudoElements");Un(),Promise.all(r).then(function(){a(),Jn(),e()}).catch(function(){a(),Jn(),n()})})}}var vr={hooks:function(){return{mutationObserverCallbacks:function(e){return e.pseudoElementsCallback=gr,e}}},provides:function(e){e.pseudoElements2svg=function(e){var t=e.node,n=void 0===t?ee:t;gt.searchPseudoElements&&gr(n)}}},br=!1,yr=function(e){return e.toLowerCase().split(" ").reduce(function(e,t){var n=t.toLowerCase().split("-"),r=n[0],a=n.slice(1).join("-");if(r&&"h"===a)return e.flipX=!0,e;if(r&&"v"===a)return e.flipY=!0,e;if(a=parseFloat(a),isNaN(a))return e;switch(r){case"grow":e.size=e.size+a;break;case"shrink":e.size=e.size-a;break;case"left":e.x=e.x-a;break;case"right":e.x=e.x+a;break;case"up":e.y=e.y-a;break;case"down":e.y=e.y+a;break;case"rotate":e.rotate=e.rotate+a}return e},{size:16,x:0,y:0,flipX:!1,flipY:!1,rotate:0})},wr={mixout:function(){return{parse:{transform:function(e){return yr(e)}}}},hooks:function(){return{parseNodeAttributes:function(e,t){var n=t.getAttribute("data-fa-transform");return n&&(e.transform=yr(n)),e}}},provides:function(e){e.generateAbstractTransformGrouping=function(e){var t=e.main,n=e.transform,r=e.containerWidth,a=e.iconWidth,o={transform:"translate(".concat(r/2," 256)")},i="translate(".concat(32*n.x,", ").concat(32*n.y,") "),l="scale(".concat(n.size/16*(n.flipX?-1:1),", ").concat(n.size/16*(n.flipY?-1:1),") "),s="rotate(".concat(n.rotate," 0 0)"),c={outer:o,inner:{transform:"".concat(i," ").concat(l," ").concat(s)},path:{transform:"translate(".concat(a/2*-1," -256)")}};return{tag:"g",attributes:$({},c.outer),children:[{tag:"g",attributes:$({},c.inner),children:[{tag:t.icon.tag,children:t.icon.children,attributes:$($({},t.icon.attributes),c.path)}]}]}}}},xr={x:0,y:0,width:"100%",height:"100%"};function kr(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return e.attributes&&(e.attributes.fill||t)&&(e.attributes.fill="black"),e}var _r={hooks:function(){return{parseNodeAttributes:function(e,t){var n=t.getAttribute("data-fa-mask"),r=n?sn(n.split(" ").map(function(e){return e.trim()})):{prefix:null,iconName:null,rest:[]};return r.prefix||(r.prefix=rn()),e.mask=r,e.maskId=t.getAttribute("data-fa-mask-id"),e}}},provides:function(e){e.generateAbstractMask=function(e){var t,n=e.children,r=e.attributes,a=e.main,o=e.mask,i=e.maskId,l=e.transform,s=a.width,c=a.icon,u=o.width,f=o.icon,d=function(e){var t=e.transform,n=e.containerWidth,r=e.iconWidth,a={transform:"translate(".concat(n/2," 256)")},o="translate(".concat(32*t.x,", ").concat(32*t.y,") "),i="scale(".concat(t.size/16*(t.flipX?-1:1),", ").concat(t.size/16*(t.flipY?-1:1),") "),l="rotate(".concat(t.rotate," 0 0)");return{outer:a,inner:{transform:"".concat(o," ").concat(i," ").concat(l)},path:{transform:"translate(".concat(r/2*-1," -256)")}}}({transform:l,containerWidth:u,iconWidth:s}),h={tag:"rect",attributes:$($({},xr),{},{fill:"white"})},m=c.children?{children:c.children.map(kr)}:{},p={tag:"g",attributes:$({},d.inner),children:[kr($({tag:c.tag,attributes:$($({},c.attributes),d.path)},m))]},g={tag:"g",attributes:$({},d.outer),children:[p]},v="mask-".concat(i||wt()),b="clip-".concat(i||wt()),y={tag:"mask",attributes:$($({},xr),{},{id:v,maskUnits:"userSpaceOnUse",maskContentUnits:"userSpaceOnUse"}),children:[h,g]},w={tag:"defs",children:[{tag:"clipPath",attributes:{id:b},children:(t=f,"g"===t.tag?t.children:[t])},y]};return n.push(w,{tag:"rect",attributes:$({fill:"currentColor","clip-path":"url(#".concat(b,")"),mask:"url(#".concat(v,")")},xr)}),{children:n,attributes:r}}}},Nr={provides:function(e){var t=!1;G.matchMedia&&(t=G.matchMedia("(prefers-reduced-motion: reduce)").matches),e.missingIconAbstract=function(){var e=[],n={fill:"currentColor"},r={attributeType:"XML",repeatCount:"indefinite",dur:"2s"};e.push({tag:"path",attributes:$($({},n),{},{d:"M156.5,447.7l-12.6,29.5c-18.7-9.5-35.9-21.2-51.5-34.9l22.7-22.7C127.6,430.5,141.5,440,156.5,447.7z M40.6,272H8.5 c1.4,21.2,5.4,41.7,11.7,61.1L50,321.2C45.1,305.5,41.8,289,40.6,272z M40.6,240c1.4-18.8,5.2-37,11.1-54.1l-29.5-12.6 C14.7,194.3,10,216.7,8.5,240H40.6z M64.3,156.5c7.8-14.9,17.2-28.8,28.1-41.5L69.7,92.3c-13.7,15.6-25.5,32.8-34.9,51.5 L64.3,156.5z M397,419.6c-13.9,12-29.4,22.3-46.1,30.4l11.9,29.8c20.7-9.9,39.8-22.6,56.9-37.6L397,419.6z M115,92.4 c13.9-12,29.4-22.3,46.1-30.4l-11.9-29.8c-20.7,9.9-39.8,22.6-56.8,37.6L115,92.4z M447.7,355.5c-7.8,14.9-17.2,28.8-28.1,41.5 l22.7,22.7c13.7-15.6,25.5-32.9,34.9-51.5L447.7,355.5z M471.4,272c-1.4,18.8-5.2,37-11.1,54.1l29.5,12.6 c7.5-21.1,12.2-43.5,13.6-66.8H471.4z M321.2,462c-15.7,5-32.2,8.2-49.2,9.4v32.1c21.2-1.4,41.7-5.4,61.1-11.7L321.2,462z M240,471.4c-18.8-1.4-37-5.2-54.1-11.1l-12.6,29.5c21.1,7.5,43.5,12.2,66.8,13.6V471.4z M462,190.8c5,15.7,8.2,32.2,9.4,49.2h32.1 c-1.4-21.2-5.4-41.7-11.7-61.1L462,190.8z M92.4,397c-12-13.9-22.3-29.4-30.4-46.1l-29.8,11.9c9.9,20.7,22.6,39.8,37.6,56.9 L92.4,397z M272,40.6c18.8,1.4,36.9,5.2,54.1,11.1l12.6-29.5C317.7,14.7,295.3,10,272,8.5V40.6z M190.8,50 c15.7-5,32.2-8.2,49.2-9.4V8.5c-21.2,1.4-41.7,5.4-61.1,11.7L190.8,50z M442.3,92.3L419.6,115c12,13.9,22.3,29.4,30.5,46.1 l29.8-11.9C470,128.5,457.3,109.4,442.3,92.3z M397,92.4l22.7-22.7c-15.6-13.7-32.8-25.5-51.5-34.9l-12.6,29.5 C370.4,72.1,384.4,81.5,397,92.4z"})});var a=$($({},r),{},{attributeName:"opacity"}),o={tag:"circle",attributes:$($({},n),{},{cx:"256",cy:"364",r:"28"}),children:[]};return t||o.children.push({tag:"animate",attributes:$($({},r),{},{attributeName:"r",values:"28;14;28;28;14;28;"})},{tag:"animate",attributes:$($({},a),{},{values:"1;0;1;1;0;1;"})}),e.push(o),e.push({tag:"path",attributes:$($({},n),{},{opacity:"1",d:"M263.7,312h-16c-6.6,0-12-5.4-12-12c0-71,77.4-63.9,77.4-107.8c0-20-17.8-40.2-57.4-40.2c-29.1,0-44.3,9.6-59.2,28.7 c-3.9,5-11.1,6-16.2,2.4l-13.1-9.2c-5.6-3.9-6.9-11.8-2.6-17.2c21.2-27.2,46.4-44.7,91.2-44.7c52.3,0,97.4,29.8,97.4,80.2 c0,67.6-77.4,63.5-77.4,107.8C275.7,306.6,270.3,312,263.7,312z"}),children:t?[]:[{tag:"animate",attributes:$($({},a),{},{values:"1;0;0;0;0;1;"})}]}),t||e.push({tag:"path",attributes:$($({},n),{},{opacity:"0",d:"M232.5,134.5l7,168c0.3,6.4,5.6,11.5,12,11.5h9c6.4,0,11.7-5.1,12-11.5l7-168c0.3-6.8-5.2-12.5-12-12.5h-23 C237.7,122,232.2,127.7,232.5,134.5z"}),children:[{tag:"animate",attributes:$($({},a),{},{values:"0;0;1;1;0;0;"})}]}),{tag:"g",attributes:{class:"missing"},children:e}}}};!function(e,t){var n=t.mixoutsTo;dn=e,hn={},Object.keys(mn).forEach(function(e){-1===pn.indexOf(e)&&delete mn[e]}),dn.forEach(function(e){var t=e.mixout?e.mixout():{};if(Object.keys(t).forEach(function(e){"function"==typeof t[e]&&(n[e]=t[e]),"object"===W(t[e])&&Object.keys(t[e]).forEach(function(r){n[e]||(n[e]={}),n[e][r]=t[e][r]})}),e.hooks){var r=e.hooks();Object.keys(r).forEach(function(e){hn[e]||(hn[e]=[]),hn[e].push(r[e])})}e.provides&&e.provides(mn)})}([jt,nr,rr,ar,or,vr,{mixout:function(){return{dom:{unwatch:function(){Un(),br=!0}}}},hooks:function(){return{bootstrap:function(){qn(gn("mutationObserverCallbacks",{}))},noAuto:function(){Qn&&Qn.disconnect()},watch:function(e){var t=e.observeMutationsRoot;br?Jn():qn(gn("mutationObserverCallbacks",{observeMutationsRoot:t}))}}}},wr,_r,Nr,{hooks:function(){return{parseNodeAttributes:function(e,t){var n=t.getAttribute("data-fa-symbol"),r=null!==n&&(""===n||n);return e.symbol=r,e}}}}],{mixoutsTo:kn});var Sr=kn.config,Mr=kn.parse,Tr=kn.icon;function Cr(e){return function(e){return(e-=0)==e}(e)?e:(e=e.replace(/[_-]+(.)?/g,(e,t)=>t?t.toUpperCase():"")).charAt(0).toLowerCase()+e.slice(1)}function jr(e){return e.charAt(0).toUpperCase()+e.slice(1)}var Or=new Map;function Rr(e){if(Or.has(e))return Or.get(e);const t={};let n=0;const r=e.length;for(;n<r;){const a=e.indexOf(";",n),o=-1===a?r:a,i=e.slice(n,o).trim();if(i){const e=i.indexOf(":");if(e>0){const n=i.slice(0,e).trim(),r=i.slice(e+1).trim();if(n&&r){const e=Cr(n);t[e.startsWith("webkit")?jr(e):e]=r}}}n=o+1}if(1e3===Or.size){const e=Or.keys().next().value;e&&Or.delete(e)}return Or.set(e,t),t}var Pr=function e(t,n,r={}){if("string"==typeof n)return n;const a=(n.children||[]).map(n=>e(t,n)),o=n.attributes||{},i={};for(const[e,t]of Object.entries(o))switch(!0){case"class"===e:i.className=t;break;case"style"===e:i.style=Rr(String(t));break;case e.startsWith("aria-"):case e.startsWith("data-"):i[e.toLowerCase()]=t;break;default:i[Cr(e)]=t}const{style:l,role:s,"aria-label":c,...u}=r;return l&&(i.style=i.style?{...i.style,...l}:l),s&&(i.role=s),c&&(i["aria-label"]=c,i["aria-hidden"]="false"),t(n.tag,{...u,...i},...a)}.bind(null,r.createElement),Er=(e,t)=>{const n=a();return e||(t?n:void 0)};"undefined"!=typeof process&&process.env.FA_VERSION;var Fr="searchPseudoElementsFullScan"in Sr?"7.0.0":"6.0.0",Ar=Number.parseInt(Fr)>=7,Ir="fa",Dr="fa-beat",Br="fa-fade",Lr="fa-beat-fade",$r="fa-bounce",zr="fa-shake",Vr="fa-spin",Hr="fa-spin-pulse",Wr="fa-spin-reverse",Ur="fa-pulse",Jr={left:"fa-pull-left",right:"fa-pull-right"},Qr={90:"fa-rotate-90",180:"fa-rotate-180",270:"fa-rotate-270"},qr={"2xs":"fa-2xs",xs:"fa-xs",sm:"fa-sm",lg:"fa-lg",xl:"fa-xl","2xl":"fa-2xl","1x":"fa-1x","2x":"fa-2x","3x":"fa-3x","4x":"fa-4x","5x":"fa-5x","6x":"fa-6x","7x":"fa-7x","8x":"fa-8x","9x":"fa-9x","10x":"fa-10x"},Xr="fa-border",Yr="fa-fw",Kr="fa-flip",Zr="fa-flip-horizontal",Gr="fa-flip-vertical",ea="fa-inverse",ta="fa-rotate-by",na="fa-swap-opacity",ra="fa-width-auto";function aa(e){const t=Sr.cssPrefix||Sr.familyPrefix||Ir;return t===Ir?e:e.replace(new RegExp(String.raw`(?<=^|\s)${Ir}-`,"g"),`${t}-`)}function oa(e){if(e)return(e=>"object"==typeof e&&"icon"in e&&!!e.icon)(e)?e:Mr.icon(e)}var ia=new class{constructor(e="react-fontawesome"){this.enabled=!1;let t=!1;try{t="undefined"!=typeof process&&"development"===process.env.NODE_ENV}catch{}this.scope=e,this.enabled=t}log(...e){this.enabled&&console.log(`[${this.scope}]`,...e)}warn(...e){this.enabled&&console.warn(`[${this.scope}]`,...e)}error(...e){this.enabled&&console.error(`[${this.scope}]`,...e)}}("FontAwesomeIcon"),la={border:!1,className:"",mask:void 0,maskId:void 0,fixedWidth:!1,inverse:!1,flip:!1,icon:void 0,listItem:!1,pull:void 0,pulse:!1,rotation:void 0,rotateBy:!1,size:void 0,spin:!1,spinPulse:!1,spinReverse:!1,beat:!1,fade:!1,beatFade:!1,bounce:!1,shake:!1,symbol:!1,title:"",titleId:void 0,transform:void 0,swapOpacity:!1,widthAuto:!1},sa=new Set(Object.keys(la)),ca=r.forwardRef((e,t)=>{const n={...la,...e},{icon:r,mask:a,symbol:o,title:i,titleId:l,maskId:s,transform:c}=n,u=Er(s,Boolean(a)),f=Er(l,Boolean(i)),d=oa(r);if(!d)return ia.error("Icon lookup is undefined",r),null;const h=function(e){const{beat:t,fade:n,beatFade:r,bounce:a,shake:o,spin:i,spinPulse:l,spinReverse:s,pulse:c,fixedWidth:u,inverse:f,border:d,flip:h,size:m,rotation:p,pull:g,swapOpacity:v,rotateBy:b,widthAuto:y,className:w}=e,x=[];return w&&x.push(...w.split(" ")),t&&x.push(Dr),n&&x.push(Br),r&&x.push(Lr),a&&x.push($r),o&&x.push(zr),i&&x.push(Vr),s&&x.push(Wr),l&&x.push(Hr),c&&x.push(Ur),u&&x.push(Yr),f&&x.push(ea),d&&x.push(Xr),!0===h&&x.push(Kr),"horizontal"!==h&&"both"!==h||x.push(Zr),"vertical"!==h&&"both"!==h||x.push(Gr),null!=m&&x.push(qr[m]),null!=p&&0!==p&&x.push(Qr[p]),null!=g&&x.push(Jr[g]),v&&x.push(na),Ar?(b&&x.push(ta),y&&x.push(ra),(Sr.cssPrefix||Sr.familyPrefix||Ir)===Ir?x:x.map(aa)):x}(n),m="string"==typeof c?Mr.transform(c):c,p=oa(a),g=Tr(d,{...h.length>0&&{classes:h},...m&&{transform:m},...p&&{mask:p},symbol:o,title:i,titleId:f,maskId:u});if(!g)return ia.error("Could not find icon",d),null;const{abstract:v}=g,b={ref:t};for(const e of(y=n,Object.keys(y)))sa.has(e)||(b[e]=n[e]);var y;return Pr(v[0],b)});ca.displayName="FontAwesomeIcon";var ua={box:"Box-module_box__SQLj3",collapseBox:"Box-module_collapseBox__5A5Fc",padding:"Box-module_padding__dIJ-L",collapsedContent:"Box-module_collapsedContent__yn-0g",collapseTitle:"Box-module_collapseTitle__-R0ge",collapseIcon:"Box-module_collapseIcon__OAiTO",collapsed:"Box-module_collapsed__nf76f"};function fa(t){const{children:n,noPadding:r,className:a="",theme:o="dark"}=t;return e("div",{className:`${ua.box} ${r?"":ua.padding} ${a}`,"data-theme":o,children:n})}F.bind(ua);const da=Symbol("BrandTag");const ha=new class{constructor(e){this[da]=e}}("unit"),ma=e=>null==e;function pa(e,t){return void 0!==t?e(t):e}function ga(e){if(function(e,t){return"object"==typeof e&&null!==e&&t in e}(e,"toString")&&"function"==typeof e.toString){const t=e.toString();return"string"==typeof t?t:JSON.stringify(e)}return JSON.stringify(e)}const va="Ok",ba="Err";class ya{constructor(e){this.repr=e}static ok(e){return ma(e)?new ya(["Ok",ha]):new ya(["Ok",e])}static err(e){return ma(e)?new ya(["Err",ha]):new ya(["Err",e])}get variant(){return this.repr[0]}get value(){if(this.repr[0]===ba)throw new Error("Cannot get the value of Err");return this.repr[1]}get error(){if(this.repr[0]===va)throw new Error("Cannot get the error of Ok");return this.repr[1]}get isOk(){return this.repr[0]===va}get isErr(){return this.repr[0]===ba}map(e){return function(e,t){const n=t=>t.isOk?wa(e(t.value)):t;return pa(n,t)}(e,this)}mapOr(e,t){return function(e,t,n){function r(t,n){return n.isOk?t(n.value):e}function a(e,t){return void 0!==t?r(e,t):t=>r(e,t)}return void 0===t?a:void 0===n?a(t):a(t,n)}(e,t,this)}mapOrElse(e,t){return ka(e,t,this)}match(e){return function(e,t){const n=t=>ka(e.Err,e.Ok,t);return pa(n,t)}(e,this)}mapErr(e){return function(e,t){const n=t=>t.isOk?t:xa(e(t.error));return pa(n,t)}(e,this)}or(e){return function(e,t){const n=t=>t.isOk?wa(t.value):e;return pa(n,t)}(e,this)}orElse(e){return function(e,t){const n=t=>t.isOk?wa(t.value):e(t.error);return pa(n,t)}(e,this)}and(e){return function(e,t){const n=t=>t.isOk?e:xa(t.error);return pa(n,t)}(e,this)}andThen(e){return function(e,t){const n=t=>t.isOk?e(t.value):xa(t.error);return pa(n,t)}(e,this)}unwrapOr(e){return function(e,t){const n=t=>t.isOk?t.value:e;return pa(n,t)}(e,this)}unwrapOrElse(e){return function(e,t){const n=t=>t.isOk?t.value:e(t.error);return pa(n,t)}(e,this)}toMaybe(){return(e=this).isOk?Aa.just(e.value):Aa.nothing();var e}toString(){return _a(this)}toJSON(){return Na(this)}equals(e){return t=e,void 0!==(n=this)?n.match({Err:()=>t.isErr,Ok:e=>t.isOk&&t.value===e}):e=>e.match({Err:()=>t.isErr,Ok:e=>t.isOk&&t.value===e});var t,n}ap(e){return function(e,t){const n=t=>t.andThen(t=>e.map(e=>e(t)));return pa(n,t)}(this,e)}}const wa=ya.ok,xa=ya.err;function ka(e,t,n){function r(t,n){return n.isOk?t(n.value):e(n.error)}function a(e,t){return void 0!==t?r(e,t):t=>r(e,t)}return void 0===t?a:void 0===n?a(t):a(t,n)}const _a=e=>{const t=e.match({Ok:ga,Err:ga});return`${e.variant.toString()}(${t})`},Na=e=>e.isOk?{variant:e.variant,value:e.value}:{variant:e.variant,error:e.error};const Sa=ya,Ma="Just",Ta="Nothing";let Ca;class ja{constructor(e){if(ma(e))return this.repr=[Ta],Ca||(Ca=this),Ca;this.repr=[Ma,e]}static of(e){return new ja(e)}static just(e){if(ma(e))throw new Error(`attempted to call "just" with ${e}`);return new ja(e)}static nothing(e){return new ja}get variant(){return this.repr[0]}get value(){if(this.repr[0]===Ta)throw new Error("Cannot get the value of `Nothing`");return this.repr[1]}get isJust(){return this.repr[0]===Ma}get isNothing(){return this.repr[0]===Ta}map(e){return function(e,t){const n=t=>t.isJust?Oa(e(t.value)):Ra();return pa(n,t)}(e,this)}mapOr(e,t){return function(e,t,n){function r(t,n){return n.isJust?t(n.value):e}function a(e,t){return void 0!==t?r(e,t):t=>r(e,t)}return void 0===t?a:void 0===n?a(t):a(t,n)}(e,t,this)}mapOrElse(e,t){return Pa(e,t,this)}match(e){return function(e,t){const n=t=>Pa(e.Nothing,e.Just,t);return pa(n,t)}(e,this)}or(e){return function(e,t){const n=t=>t.isJust?t:e;return void 0!==t?n(t):n}(e,this)}orElse(e){return function(e,t){const n=t=>t.isJust?t:e();return pa(n,t)}(e,this)}and(e){return function(e,t){const n=t=>t.isJust?e:Ra();return pa(n,t)}(e,this)}andThen(e){return Ea(e,this)}unwrapOr(e){return function(e,t){const n=t=>t.isJust?t.value:e;return pa(n,t)}(e,this)}unwrapOrElse(e){return function(e,t){const n=t=>t.isJust?t.value:e();return pa(n,t)}(e,this)}toOkOrErr(e){return function(e,t){const n=t=>t.isJust?Sa.ok(t.value):Sa.err(e);return void 0!==t?n(t):n}(e,this)}toOkOrElseErr(e){return function(e,t){return pa(t=>t.isJust?Sa.ok(t.value):Sa.err(e()),t)}(e,this)}toString(){return function(e){const t=e.map(e=>`(${ga(e)})`).unwrapOr("");return`${e.variant}${t}`}(this)}toJSON(){return(e=this).isJust?{variant:e.variant,value:Fa(e.value)?e.value.toJSON():e.value}:{variant:e.variant};var e}equals(e){return t=e,pa(e=>e.match({Just:e=>t.isJust&&t.value===e,Nothing:()=>t.isNothing}),this);var t}ap(e){return function(e,t){const n=t=>t.andThen(t=>e.map(e=>e(t)));return pa(n,t)}(this,e)}get(e){return function(e,t){return pa(Ea(function(e,t){const n=t=>Aa.of(t[e]);return pa(n,t)}(e)),t)}(e,this)}}const Oa=ja.just,Ra=ja.nothing;function Pa(e,t,n){function r(t,n){return n.isJust?t(n.value):e()}function a(e,t){return void 0!==t?r(e,t):t=>r(e,t)}return void 0===t?a:void 0===n?a(t):a(t,n)}function Ea(e,t){const n=t=>t.isJust?e(t.value):Ra();return void 0!==t?n(t):n}function Fa(e){return e instanceof Aa}const Aa=ja,Ia=["dotnetspy","ebpfspy","gospy","phpspy","pyspy","rbspy","nodespy","javaspy","pyroscope-rs","scrape","tracing","unknown"],Da=_.preprocess(e=>e&&Ia.includes(e)?e:"unknown",_.enum(Ia).default("unknown")),Ba=["samples","objects","goroutines","bytes","lock_samples","lock_nanoseconds","trace_samples","exceptions"],La=_.preprocess(e=>"string"==typeof e&&Ba.includes(e)?e:"unknown",_.enum(["samples","objects","goroutines","bytes","lock_samples","lock_nanoseconds","trace_samples","exceptions","unknown"])),$a=_.object({names:_.array(_.preprocess(e=>e||"unknown",_.string().min(1))),levels:_.array(_.array(_.number())),numTicks:_.number(),maxSelf:_.number()}),za=_.object({appName:_.string().optional(),name:_.string().optional(),startTime:_.number().optional(),endTime:_.number().optional(),query:_.string().optional(),maxNodes:_.number().optional(),format:_.enum(["single","double"]),sampleRate:_.number(),spyName:Da,units:La});_.object({version:_.number().min(1).max(1).default(1),flamebearer:$a,metadata:za,leftTicks:_.number().optional(),rightTicks:_.number().optional()});const Va={format:"single",jStep:4,jName:3,getBarOffset:(e,t)=>e[t],getBarTotal:(e,t)=>e[t+1],getBarTotalDiff:(e,t)=>0,getBarSelf:(e,t)=>e[t+2],getBarSelfDiff:(e,t)=>0,getBarName:(e,t)=>e[t+3]},Ha={format:"double",jStep:7,jName:6,getBarOffset:(e,t)=>e[t]+e[t+3],getBarTotal:(e,t)=>e[t+4]+e[t+1],getBarTotalLeft:(e,t)=>e[t+1],getBarTotalRght:(e,t)=>e[t+4],getBarTotalDiff:(e,t)=>e[t+4]-e[t+1],getBarSelf:(e,t)=>e[t+5]+e[t+2],getBarSelfLeft:(e,t)=>e[t+2],getBarSelfRght:(e,t)=>e[t+5],getBarSelfDiff:(e,t)=>e[t+5]-e[t+2],getBarName:(e,t)=>e[t+6]};function Wa(e){switch(e){case"single":return Va;case"double":return Ha;default:throw new Error(`Unsupported type: '${e}'`)}}const Ua=_.object({refType:_.string(),traceID:_.string(),spanID:_.string()}),Ja=_.object({key:_.string(),type:_.string(),value:_.union([_.boolean(),_.number(),_.string()])}),Qa=_.object({traceID:_.string(),spanID:_.string(),flags:_.string(),operationName:_.string(),references:_.array(Ua),startTime:_.number(),duration:_.number(),tags:_.array(Ja),logs:_.object({timestamp:_.number(),fields:_.array(Ja)}),processID:_.string(),warnings:_.any()}),qa=_.object({serviceName:_.string(),tags:_.array(Ja)});_.object({traceID:_.string(),spans:_.array(Qa),processes:_.record(qa),warnings:_.any()});const Xa=_.object({watermark:_.object({}).optional(),startTime:_.number(),samples:_.array(_.number()),durationDelta:_.number()});_.record(_.string(),Xa);const Ya=22,Ka=21.5;function Za(e){return e.toString().replace(/\B(?=(\d{3})+(?!\d))/g,",")}function Ga(e){if(null==e)return null;if("number"==typeof e)return{value:e,unit:"",hasLessThan:!1,sign:""};let t=String(e).trim().replace(/\u2212/g,"-");if(!t)return null;let n=!1;t.startsWith("<")&&(n=!0,t=t.slice(1).trim());const r=t.match(/^([+\-]?)(\d*\.?\d+)\s*(.*)$/);if(!r)return null;const a=r[1]||"",o=r[2],i=(r[3]||"").trim(),l=parseFloat(o);return Number.isFinite(l)?{value:l,unit:i,hasLessThan:n,sign:a}:null}function eo(e,t=!1){if(!e||!t)return e;const n=Ga(e);if(!n)return e;const{unit:r}=n;let a=r;const o=r.toLowerCase();"ms"===o?a="毫秒":"μs"===o||"µs"===o||"us"===o?a="微秒":"second"===o||"seconds"===o?a="秒":"minute"===o||"minutes"===o||"min"===o||"mins"===o?a="分钟":"hour"===o||"hours"===o?a="小时":"day"===o||"days"===o?a="天":"month"===o||"months"===o?a="月":"year"!==o&&"years"!==o||(a="年");const i=String(e).match(/^([<\s]*)([+\-]?\d*\.?\d+)(.*)$/);if(!i)return e;return`${i[1]||""}${i[2]||""} ${a}`.trim()}const to=[{value:1e15,label:"Quad"},{value:1e12,label:"Tri"},{value:1e9,label:"B"},{value:1e6,label:"M"},{value:1e3,label:"K"}];function no(e){return Math.round(1e4*e)/100}function ro(e,t){return(t-e)/e*100}function ao(e,t,n){switch(n){case"samples":return new oo(e/t);case"objects":case"goroutines":case"lock_samples":case"exceptions":return new lo(e);case"bytes":return new so(e);case"lock_nanoseconds":return new io(e);case"trace_samples":return new oo(e/t,"",!0);default:return console.warn(`Unsupported unit: '${n}'. Defaulting to ''`),new oo(e/t," ")}}class oo{constructor(e,t,n){this.divider=1,this.enableSubsecondPrecision=!1,this.suffix="second",this.durations=[[60,"minute"],[60,"hour"],[24,"day"],[30,"month"],[12,"year"]],this.units="",n&&(this.enableSubsecondPrecision=n,this.durations=[[1e3,"ms"],[1e3,"second"],...this.durations],this.suffix="μs",e*=1e6),this.units=t||"";for(let t=0;t<this.durations.length;t++){const n=this.durations[t];if(!n){console.warn("Could not calculate level");break}if(!(e>=n[0]))break;this.divider*=n[0],e/=n[0],this.suffix=n[1]}}format(e,t,n=!0){this.enableSubsecondPrecision&&(t/=1e6);const r=e/t/this.divider;let a=r.toFixed(2);return 0===r?a="0.00":(r>=0&&r<.01||r<=0&&r>-.01)&&(a="< 0.01"),n?`${a} ${this.units||`${this.suffix}${1===r||2===this.suffix.length?"":"s"}`}`:a}formatPrecise(e,t){this.enableSubsecondPrecision&&(t/=1e6);const n=e/t/this.divider;return`${parseFloat(n.toFixed(5))} ${this.units||`${this.suffix}${1===n||2===this.suffix.length?"":"s"}`}`}}class io{constructor(e){this.divider=1,this.multiplier=1,this.suffix="second",this.durations=[[60,"minute"],[60,"hour"],[24,"day"],[30,"month"],[12,"year"]],e/=1e9;for(let t=0;t<this.durations.length;t++){const n=this.durations[t];if(!n){console.warn("Could not calculate level");break}if(!(e>=n[0]))break;this.divider*=n[0],e/=n[0],this.suffix=n[1]}}format(e){const t=e/1e9/this.divider;let n=t.toFixed(2);return(t>=0&&t<.01||t<=0&&t>-.01)&&(n="< 0.01"),`${n} ${this.suffix}${1===t?"":"s"}`}formatPrecise(e){const t=e/1e9/this.divider;return`${parseFloat(t.toFixed(5))} ${this.suffix}${1===t?"":"s"}`}}class lo{constructor(e){this.divider=1,this.suffix="",this.objects=[[1e3,"K"],[1e3,"M"],[1e3,"G"],[1e3,"T"],[1e3,"P"]];for(let t=0;t<this.objects.length;t++){const n=this.objects[t];if(!n){console.warn("Could not calculate level");break}if(!(e>=n[0]))break;this.divider*=n[0],e/=n[0],this.suffix=n[1]}}format(e){const t=e/this.divider;let n=t.toFixed(2);return(t>=0&&t<.01||t<=0&&t>-.01)&&(n="< 0.01"),`${n} ${this.suffix}`}formatPrecise(e){const t=e/this.divider;return`${parseFloat(t.toFixed(5))} ${this.suffix}`}}class so{constructor(e){this.divider=1,this.suffix="bytes",this.bytes=[[1024,"KB"],[1024,"MB"],[1024,"GB"],[1024,"TB"],[1024,"PB"]];for(let t=0;t<this.bytes.length;t++){const n=this.bytes[t];if(!n){console.warn("Could not calculate level");break}if(!(e>=n[0]))break;{this.divider*=n[0],e/=n[0];const t=n[1];t?this.suffix=t:(console.warn("Could not calculate suffix"),this.suffix="")}}}format(e){const t=e/this.divider;let n=t.toFixed(2);return(t>=0&&t<.01||t<=0&&t>-.01)&&(n="< 0.01"),`${n} ${this.suffix}`}formatPrecise(e){const t=e/this.divider;return`${parseFloat(t.toFixed(5))} ${this.suffix}`}}const co="TAIL",uo="HEAD";function fo({mode:e,charSize:t,rectWidth:n,fullText:r,shortText:a}){if(e===co){if(t*r.length<=n)return{mode:e,text:r,marginLeft:3};const o=t*a.length;return o<=n?{mode:e,text:a,marginLeft:3}:{mode:e,text:a,marginLeft:-(o-n+3)}}return{mode:e,text:r,marginLeft:3}}function ho(e){return e===co?{direction:"rtl",overflow:"hidden",textOverflow:"ellipsis"}:{overflow:"hidden",textOverflow:"ellipsis"}}const mo={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 e in mo)Object.freeze(mo[e]);var po=Object.freeze(mo);const go=Object.create(null);for(const e in po)Object.hasOwn(po,e)&&(go[po[e]]=e);const vo={to:{},get:{}};function bo(e,t,n){return Math.min(Math.max(t,e),n)}function yo(e){const t=Math.round(e).toString(16).toUpperCase();return t.length<2?"0"+t:t}vo.get=function(e){let t,n;switch(e.slice(0,3).toLowerCase()){case"hsl":t=vo.get.hsl(e),n="hsl";break;case"hwb":t=vo.get.hwb(e),n="hwb";break;default:t=vo.get.rgb(e),n="rgb"}return t?{model:n,value:t}:null},vo.get.rgb=function(e){if(!e)return null;let t,n,r,a=[0,0,0,1];if(t=e.match(/^#([a-f\d]{6})([a-f\d]{2})?$/i)){for(r=t[2],t=t[1],n=0;n<3;n++){const e=2*n;a[n]=Number.parseInt(t.slice(e,e+2),16)}r&&(a[3]=Number.parseInt(r,16)/255)}else if(t=e.match(/^#([a-f\d]{3,4})$/i)){for(t=t[1],r=t[3],n=0;n<3;n++)a[n]=Number.parseInt(t[n]+t[n],16);r&&(a[3]=Number.parseInt(r+r,16)/255)}else if(t=e.match(/^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)){for(n=0;n<3;n++)a[n]=Number.parseFloat(t[n+1]);t[4]&&(a[3]=t[5]?.01*Number.parseFloat(t[4]):Number.parseFloat(t[4]))}else{if(!(t=e.match(/^rgba?\(\s*([+-]?[\d.]+)%\s*,?\s*([+-]?[\d.]+)%\s*,?\s*([+-]?[\d.]+)%\s*(?:[\s,|/]\s*([+-]?[\d.]+)(%?)\s*)?\)$/i)))return(t=e.toLowerCase().match(/^(\w+)$/))?"transparent"===t[1]?[0,0,0,0]:Object.hasOwn(po,t[1])?(a=po[t[1]].slice(),a[3]=1,a):null:null;for(n=0;n<3;n++)a[n]=Math.round(2.55*Number.parseFloat(t[n+1]));t[4]&&(a[3]=t[5]?.01*Number.parseFloat(t[4]):Number.parseFloat(t[4]))}for(n=0;n<3;n++)a[n]=bo(a[n],0,255);return a[3]=bo(a[3],0,1),a},vo.get.hsl=function(e){if(!e)return null;const t=e.match(/^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);if(t){const e=Number.parseFloat(t[4]);return[(Number.parseFloat(t[1])%360+360)%360,bo(Number.parseFloat(t[2]),0,100),bo(Number.parseFloat(t[3]),0,100),bo(Number.isNaN(e)?1:e,0,1)]}return null},vo.get.hwb=function(e){if(!e)return null;const t=e.match(/^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);if(t){const e=Number.parseFloat(t[4]);return[(Number.parseFloat(t[1])%360+360)%360,bo(Number.parseFloat(t[2]),0,100),bo(Number.parseFloat(t[3]),0,100),bo(Number.isNaN(e)?1:e,0,1)]}return null},vo.to.hex=function(...e){return"#"+yo(e[0])+yo(e[1])+yo(e[2])+(e[3]<1?yo(Math.round(255*e[3])):"")},vo.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]+")"},vo.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]+")"},vo.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]+")"},vo.to.hwb=function(...e){let t="";return e.length>=4&&1!==e[3]&&(t=", "+e[3]),"hwb("+e[0]+", "+e[1]+"%, "+e[2]+"%"+t+")"},vo.to.keyword=function(...e){return go[e.slice(0,3)]};const wo={};for(const e of Object.keys(po))wo[po[e]]=e;const xo={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"]}},ko=(6/29)**3;function _o(e){const t=e>.0031308?1.055*e**(1/2.4)-.055:12.92*e;return Math.min(Math.max(0,t),1)}function No(e){return e>.04045?((e+.055)/1.055)**2.4:e/12.92}for(const e of Object.keys(xo)){if(!("channels"in xo[e]))throw new Error("missing channels property: "+e);if(!("labels"in xo[e]))throw new Error("missing channel labels property: "+e);if(xo[e].labels.length!==xo[e].channels)throw new Error("channel and label counts mismatch: "+e);const{channels:t,labels:n}=xo[e];delete xo[e].channels,delete xo[e].labels,Object.defineProperty(xo[e],"channels",{value:t}),Object.defineProperty(xo[e],"labels",{value:n})}function So(e,t){return(e[0]-t[0])**2+(e[1]-t[1])**2+(e[2]-t[2])**2}function Mo(e){const t=function(){const e={},t=Object.keys(xo);for(let{length:n}=t,r=0;r<n;r++)e[t[r]]={distance:-1,parent:null};return e}(),n=[e];for(t[e].distance=0;n.length>0;){const e=n.pop(),r=Object.keys(xo[e]);for(let{length:a}=r,o=0;o<a;o++){const a=r[o],i=t[a];-1===i.distance&&(i.distance=t[e].distance+1,i.parent=e,n.unshift(a))}}return t}function To(e,t){return function(n){return t(e(n))}}function Co(e,t){const n=[t[e].parent,e];let r=xo[t[e].parent][e],a=t[e].parent;for(;t[a].parent;)n.unshift(t[a].parent),r=To(xo[t[a].parent][a],r),a=t[a].parent;return r.conversion=n,r}function jo(e){const t=Mo(e),n={},r=Object.keys(t);for(let{length:e}=r,a=0;a<e;a++){const e=r[a];null!==t[e].parent&&(n[e]=Co(e,t))}return n}xo.rgb.hsl=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,a=Math.min(t,n,r),o=Math.max(t,n,r),i=o-a;let l,s;switch(o){case a:l=0;break;case t:l=(n-r)/i;break;case n:l=2+(r-t)/i;break;case r:l=4+(t-n)/i}l=Math.min(60*l,360),l<0&&(l+=360);const c=(a+o)/2;return s=o===a?0:c<=.5?i/(o+a):i/(2-o-a),[l,100*s,100*c]},xo.rgb.hsv=function(e){let t,n,r,a,o;const i=e[0]/255,l=e[1]/255,s=e[2]/255,c=Math.max(i,l,s),u=c-Math.min(i,l,s),f=function(e){return(c-e)/6/u+.5};if(0===u)a=0,o=0;else{switch(o=u/c,t=f(i),n=f(l),r=f(s),c){case i:a=r-n;break;case l:a=1/3+t-r;break;case s:a=2/3+n-t}a<0?a+=1:a>1&&(a-=1)}return[360*a,100*o,100*c]},xo.rgb.hwb=function(e){const t=e[0],n=e[1];let r=e[2];const a=xo.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)),[a,100*o,100*r]},xo.rgb.oklab=function(e){const t=No(e[0]/255),n=No(e[1]/255),r=No(e[2]/255),a=Math.cbrt(.4122214708*t+.5363325363*n+.0514459929*r),o=Math.cbrt(.2119034982*t+.6806995451*n+.1073969566*r),i=Math.cbrt(.0883024619*t+.2817188376*n+.6299787005*r);return[100*(.2104542553*a+.793617785*o-.0040720468*i),100*(1.9779984951*a-2.428592205*o+.4505937099*i),100*(.0259040371*a+.7827717662*o-.808675766*i)]},xo.rgb.cmyk=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,a=Math.min(1-t,1-n,1-r);return[100*((1-t-a)/(1-a)||0),100*((1-n-a)/(1-a)||0),100*((1-r-a)/(1-a)||0),100*a]},xo.rgb.keyword=function(e){const t=wo[e];if(t)return t;let n,r=Number.POSITIVE_INFINITY;for(const t of Object.keys(po)){const a=So(e,po[t]);a<r&&(r=a,n=t)}return n},xo.keyword.rgb=function(e){return[...po[e]]},xo.rgb.xyz=function(e){const t=No(e[0]/255),n=No(e[1]/255),r=No(e[2]/255);return[100*(.4124564*t+.3575761*n+.1804375*r),100*(.2126729*t+.7151522*n+.072175*r),100*(.0193339*t+.119192*n+.9503041*r)]},xo.rgb.lab=function(e){const t=xo.rgb.xyz(e);let n=t[0],r=t[1],a=t[2];n/=95.047,r/=100,a/=108.883,n=n>ko?n**(1/3):7.787*n+16/116,r=r>ko?r**(1/3):7.787*r+16/116,a=a>ko?a**(1/3):7.787*a+16/116;return[116*r-16,500*(n-r),200*(r-a)]},xo.hsl.rgb=function(e){const t=e[0]/360,n=e[1]/100,r=e[2]/100;let a,o;if(0===n)return o=255*r,[o,o,o];const i=r<.5?r*(1+n):r+n-r*n,l=2*r-i,s=[0,0,0];for(let e=0;e<3;e++)a=t+1/3*-(e-1),a<0&&a++,a>1&&a--,o=6*a<1?l+6*(i-l)*a:2*a<1?i:3*a<2?l+(i-l)*(2/3-a)*6:l,s[e]=255*o;return s},xo.hsl.hsv=function(e){const t=e[0];let n=e[1]/100,r=e[2]/100,a=n;const o=Math.max(r,.01);r*=2,n*=r<=1?r:2-r,a*=o<=1?o:2-o;return[t,100*(0===r?2*a/(o+a):2*n/(r+n)),100*((r+n)/2)]},xo.hsv.rgb=function(e){const t=e[0]/60,n=e[1]/100;let r=e[2]/100;const a=Math.floor(t)%6,o=t-Math.floor(t),i=255*r*(1-n),l=255*r*(1-n*o),s=255*r*(1-n*(1-o));switch(r*=255,a){case 0:return[r,s,i];case 1:return[l,r,i];case 2:return[i,r,s];case 3:return[i,l,r];case 4:return[s,i,r];case 5:return[r,i,l]}},xo.hsv.hsl=function(e){const t=e[0],n=e[1]/100,r=e[2]/100,a=Math.max(r,.01);let o,i;i=(2-n)*r;const l=(2-n)*a;return o=n*a,o/=l<=1?l:2-l,o=o||0,i/=2,[t,100*o,100*i]},xo.hwb.rgb=function(e){const t=e[0]/360;let n=e[1]/100,r=e[2]/100;const a=n+r;let o;a>1&&(n/=a,r/=a);const i=Math.floor(6*t),l=1-r;o=6*t-i,1&i&&(o=1-o);const s=n+o*(l-n);let c,u,f;switch(i){default:case 6:case 0:c=l,u=s,f=n;break;case 1:c=s,u=l,f=n;break;case 2:c=n,u=l,f=s;break;case 3:c=n,u=s,f=l;break;case 4:c=s,u=n,f=l;break;case 5:c=l,u=n,f=s}return[255*c,255*u,255*f]},xo.cmyk.rgb=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100,a=e[3]/100;return[255*(1-Math.min(1,t*(1-a)+a)),255*(1-Math.min(1,n*(1-a)+a)),255*(1-Math.min(1,r*(1-a)+a))]},xo.xyz.rgb=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100;let a,o,i;return a=3.2404542*t+-1.5371385*n+-.4985314*r,o=-.969266*t+1.8760108*n+.041556*r,i=.0556434*t+-.2040259*n+1.0572252*r,a=_o(a),o=_o(o),i=_o(i),[255*a,255*o,255*i]},xo.xyz.lab=function(e){let t=e[0],n=e[1],r=e[2];t/=95.047,n/=100,r/=108.883,t=t>ko?t**(1/3):7.787*t+16/116,n=n>ko?n**(1/3):7.787*n+16/116,r=r>ko?r**(1/3):7.787*r+16/116;return[116*n-16,500*(t-n),200*(n-r)]},xo.xyz.oklab=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100,a=Math.cbrt(.8189330101*t+.3618667424*n-.1288597137*r),o=Math.cbrt(.0329845436*t+.9293118715*n+.0361456387*r),i=Math.cbrt(.0482003018*t+.2643662691*n+.633851707*r);return[100*(.2104542553*a+.793617785*o-.0040720468*i),100*(1.9779984951*a-2.428592205*o+.4505937099*i),100*(.0259040371*a+.7827717662*o-.808675766*i)]},xo.oklab.oklch=function(e){return xo.lab.lch(e)},xo.oklab.xyz=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100,a=(.999999998*t+.396337792*n+.215803758*r)**3,o=(1.000000008*t-.105561342*n-.063854175*r)**3,i=(1.000000055*t-.089484182*n-1.291485538*r)**3;return[100*(1.227013851*a-.55779998*o+.281256149*i),100*(-.040580178*a+1.11225687*o-.071676679*i),100*(-.076381285*a-.421481978*o+1.58616322*i)]},xo.oklab.rgb=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100,a=(t+.3963377774*n+.2158037573*r)**3,o=(t-.1055613458*n-.0638541728*r)**3,i=(t-.0894841775*n-1.291485548*r)**3;return[255*_o(4.0767416621*a-3.3077115913*o+.2309699292*i),255*_o(-1.2684380046*a+2.6097574011*o-.3413193965*i),255*_o(-.0041960863*a-.7034186147*o+1.707614701*i)]},xo.oklch.oklab=function(e){return xo.lch.lab(e)},xo.lab.xyz=function(e){let t,n,r;n=(e[0]+16)/116,t=e[1]/500+n,r=n-e[2]/200;const a=n**3,o=t**3,i=r**3;return n=a>ko?a:(n-16/116)/7.787,t=o>ko?o:(t-16/116)/7.787,r=i>ko?i:(r-16/116)/7.787,t*=95.047,n*=100,r*=108.883,[t,n,r]},xo.lab.lch=function(e){const t=e[0],n=e[1],r=e[2];let a;a=360*Math.atan2(r,n)/2/Math.PI,a<0&&(a+=360);return[t,Math.sqrt(n*n+r*r),a]},xo.lch.lab=function(e){const t=e[0],n=e[1],r=e[2]/360*2*Math.PI;return[t,n*Math.cos(r),n*Math.sin(r)]},xo.rgb.ansi16=function(e,t=null){const[n,r,a]=e;let o=null===t?xo.rgb.hsv(e)[2]:t;if(o=Math.round(o/50),0===o)return 30;let i=30+(Math.round(a/255)<<2|Math.round(r/255)<<1|Math.round(n/255));return 2===o&&(i+=60),i},xo.hsv.ansi16=function(e){return xo.rgb.ansi16(xo.hsv.rgb(e),e[2])},xo.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;return 16+36*Math.round(t/255*5)+6*Math.round(n/255*5)+Math.round(r/255*5)},xo.ansi16.rgb=function(e){let t=(e=e[0])%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);return[(1&t)*n*255,(t>>1&1)*n*255,(t>>2&1)*n*255]},xo.ansi256.rgb=function(e){if((e=e[0])>=232){const t=10*(e-232)+8;return[t,t,t]}let t;e-=16;return[Math.floor(e/36)/5*255,Math.floor((t=e%36)/6)/5*255,t%6/5*255]},xo.rgb.hex=function(e){const t=(((255&Math.round(e[0]))<<16)+((255&Math.round(e[1]))<<8)+(255&Math.round(e[2]))).toString(16).toUpperCase();return"000000".slice(t.length)+t},xo.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);return[r>>16&255,r>>8&255,255&r]},xo.rgb.hcg=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,a=Math.max(Math.max(t,n),r),o=Math.min(Math.min(t,n),r),i=a-o;let l;return l=i<=0?0:a===t?(n-r)/i%6:a===n?2+(r-t)/i:4+(t-n)/i,l/=6,l%=1,[360*l,100*i,100*(i<1?o/(1-i):0)]},xo.hsl.hcg=function(e){const t=e[1]/100,n=e[2]/100,r=n<.5?2*t*n:2*t*(1-n);let a=0;return r<1&&(a=(n-.5*r)/(1-r)),[e[0],100*r,100*a]},xo.hsv.hcg=function(e){const t=e[1]/100,n=e[2]/100,r=t*n;let a=0;return r<1&&(a=(n-r)/(1-r)),[e[0],100*r,100*a]},xo.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 a=[0,0,0],o=t%1*6,i=o%1,l=1-i;let s=0;switch(Math.floor(o)){case 0:a[0]=1,a[1]=i,a[2]=0;break;case 1:a[0]=l,a[1]=1,a[2]=0;break;case 2:a[0]=0,a[1]=1,a[2]=i;break;case 3:a[0]=0,a[1]=l,a[2]=1;break;case 4:a[0]=i,a[1]=0,a[2]=1;break;default:a[0]=1,a[1]=0,a[2]=l}return s=(1-n)*r,[255*(n*a[0]+s),255*(n*a[1]+s),255*(n*a[2]+s)]},xo.hcg.hsv=function(e){const t=e[1]/100,n=t+e[2]/100*(1-t);let r=0;return n>0&&(r=t/n),[e[0],100*r,100*n]},xo.hcg.hsl=function(e){const t=e[1]/100,n=e[2]/100*(1-t)+.5*t;let r=0;return n>0&&n<.5?r=t/(2*n):n>=.5&&n<1&&(r=t/(2*(1-n))),[e[0],100*r,100*n]},xo.hcg.hwb=function(e){const t=e[1]/100,n=t+e[2]/100*(1-t);return[e[0],100*(n-t),100*(1-n)]},xo.hwb.hcg=function(e){const t=e[1]/100,n=1-e[2]/100,r=n-t;let a=0;return r<1&&(a=(n-r)/(1-r)),[e[0],100*r,100*a]},xo.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]},xo.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]},xo.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]},xo.gray.hsl=function(e){return[0,0,e[0]]},xo.gray.hsv=xo.gray.hsl,xo.gray.hwb=function(e){return[0,100,e[0]]},xo.gray.cmyk=function(e){return[0,0,0,e[0]]},xo.gray.lab=function(e){return[e[0],0,0]},xo.gray.hex=function(e){const t=255&Math.round(e[0]/100*255),n=((t<<16)+(t<<8)+t).toString(16).toUpperCase();return"000000".slice(n.length)+n},xo.rgb.gray=function(e){return[(e[0]+e[1]+e[2])/3/255*100]};const Oo={},Ro=Object.keys(xo);function Po(e){const t=function(...t){const n=t[0];return null==n?n:(n.length>1&&(t=n),e(t))};return"conversion"in e&&(t.conversion=e.conversion),t}function Eo(e){const t=function(...t){const n=t[0];if(null==n)return n;n.length>1&&(t=n);const r=e(t);if("object"==typeof r)for(let{length:e}=r,t=0;t<e;t++)r[t]=Math.round(r[t]);return r};return"conversion"in e&&(t.conversion=e.conversion),t}for(const e of Ro){Oo[e]={},Object.defineProperty(Oo[e],"channels",{value:xo[e].channels}),Object.defineProperty(Oo[e],"labels",{value:xo[e].labels});const t=jo(e),n=Object.keys(t);for(const r of n){const n=t[r];Oo[e][r]=Eo(n),Oo[e][r].raw=Po(n)}}const Fo=["keyword","gray","hex"],Ao={};for(const e of Object.keys(Oo))Ao[[...Oo[e].labels].sort().join("")]=e;const Io={};function Do(e,t){if(!(this instanceof Do))return new Do(e,t);if(t&&t in Fo&&(t=null),t&&!(t in Oo))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 Do)this.model=e.model,this.color=[...e.color],this.valpha=e.valpha;else if("string"==typeof e){const t=vo.get(e);if(null===t)throw new Error("Unable to parse color from string: "+e);this.model=t.model,r=Oo[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=Oo[this.model].channels;const n=Array.prototype.slice.call(e,0,r);this.color=zo(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 Ao))throw new Error("Unable to parse color from object: "+JSON.stringify(e));this.model=Ao[r];const{labels:a}=Oo[this.model],o=[];for(n=0;n<a.length;n++)o.push(e[a[n]]);this.color=zo(o)}if(Io[this.model])for(r=Oo[this.model].channels,n=0;n<r;n++){const e=Io[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)}Do.prototype={toString(){return this.string()},toJSON(){return this[this.model]()},string(e){let t=this.model in vo.to?this:this.rgb();t=t.round("number"==typeof e?e:1);const n=1===t.valpha?t.color:[...t.color,this.valpha];return vo.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 vo.to.rgb.percent(...n)},array(){return 1===this.valpha?[...this.color]:[...this.color,this.valpha]},object(){const e={},{channels:t}=Oo[this.model],{labels:n}=Oo[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 Do([...this.color.map(Bo(e)),this.valpha],this.model)},alpha(e){return void 0!==e?new Do([...this.color,Math.max(0,Math.min(1,e))],this.model):this.valpha},red:Lo("rgb",0,$o(255)),green:Lo("rgb",1,$o(255)),blue:Lo("rgb",2,$o(255)),hue:Lo(["hsl","hsv","hsl","hwb","hcg"],0,e=>(e%360+360)%360),saturationl:Lo("hsl",1,$o(100)),lightness:Lo("hsl",2,$o(100)),saturationv:Lo("hsv",1,$o(100)),value:Lo("hsv",2,$o(100)),chroma:Lo("hcg",1,$o(100)),gray:Lo("hcg",2,$o(100)),white:Lo("hwb",1,$o(100)),wblack:Lo("hwb",2,$o(100)),cyan:Lo("cmyk",0,$o(100)),magenta:Lo("cmyk",1,$o(100)),yellow:Lo("cmyk",2,$o(100)),black:Lo("cmyk",3,$o(100)),x:Lo("xyz",0,$o(95.047)),y:Lo("xyz",1,$o(100)),z:Lo("xyz",2,$o(108.833)),l:Lo("lab",0,$o(100)),a:Lo("lab",1),b:Lo("lab",2),keyword(e){return void 0!==e?new Do(e):Oo[this.model].keyword(this.color)},hex(e){return void 0!==e?new Do(e):vo.to.hex(...this.rgb().round().color)},hexa(e){if(void 0!==e)return new Do(e);const t=this.rgb().round().color;let n=Math.round(255*this.valpha).toString(16).toUpperCase();return 1===n.length&&(n="0"+n),vo.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;return(2126*e[0]+7152*e[1]+722*e[2])/1e4<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 Do.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(),a=void 0===t?.5:t,o=2*a-1,i=n.alpha()-r.alpha(),l=((o*i===-1?o:(o+i)/(1+o*i))+1)/2,s=1-l;return Do.rgb(l*n.red()+s*r.red(),l*n.green()+s*r.green(),l*n.blue()+s*r.blue(),n.alpha()*a+r.alpha()*(1-a))}};for(const e of Object.keys(Oo)){if(Fo.includes(e))continue;const{channels:t}=Oo[e];Do.prototype[e]=function(...t){return this.model===e?new Do(this):t.length>0?new Do(t,e):new Do([...(n=Oo[this.model][e].raw(this.color),Array.isArray(n)?n:[n]),this.valpha],e);var n},Do[e]=function(...n){let r=n[0];return"number"==typeof r&&(r=zo(n,t)),new Do(r,e)}}function Bo(e){return function(t){return function(e,t){return Number(e.toFixed(t))}(t,e)}}function Lo(e,t,n){e=Array.isArray(e)?e:[e];for(const r of e)(Io[r]||=[])[t]=n;return e=e[0],function(r){let a;return void 0!==r?(n&&(r=n(r)),a=this[e](),a.color[t]=r,a):(a=this[e]().color[t],n&&(a=n(a)),a)}}function $o(e){return function(t){return Math.max(0,Math.min(e,t))}}function zo(e,t){for(let n=0;n<t;n++)"number"!=typeof e[n]&&(e[n]=0);return e}function Vo(e,t){return null==e||null==t?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function Ho(e,t){return null==e||null==t?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function Wo(e){let t,n,r;function a(e,r,a=0,o=e.length){if(a<o){if(0!==t(r,r))return o;do{const t=a+o>>>1;n(e[t],r)<0?a=t+1:o=t}while(a<o)}return a}return 2!==e.length?(t=Vo,n=(t,n)=>Vo(e(t),n),r=(t,n)=>e(t)-n):(t=e===Vo||e===Ho?e:Uo,n=e,r=e),{left:a,center:function(e,t,n=0,o=e.length){const i=a(e,t,n,o-1);return i>n&&r(e[i-1],t)>-r(e[i],t)?i-1:i},right:function(e,r,a=0,o=e.length){if(a<o){if(0!==t(r,r))return o;do{const t=a+o>>>1;n(e[t],r)<=0?a=t+1:o=t}while(a<o)}return a}}}function Uo(){return 0}const Jo=Wo(Vo).right;Wo(function(e){return null===e?NaN:+e}).center;const Qo=Math.sqrt(50),qo=Math.sqrt(10),Xo=Math.sqrt(2);function Yo(e,t,n){const r=(t-e)/Math.max(0,n),a=Math.floor(Math.log10(r)),o=r/Math.pow(10,a),i=o>=Qo?10:o>=qo?5:o>=Xo?2:1;let l,s,c;return a<0?(c=Math.pow(10,-a)/i,l=Math.round(e*c),s=Math.round(t*c),l/c<e&&++l,s/c>t&&--s,c=-c):(c=Math.pow(10,a)*i,l=Math.round(e/c),s=Math.round(t/c),l*c<e&&++l,s*c>t&&--s),s<l&&.5<=n&&n<2?Yo(e,t,2*n):[l,s,c]}function Ko(e,t,n){return Yo(e=+e,t=+t,n=+n)[2]}function Zo(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e)}return this}function Go(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function ei(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function ti(){}var ni=.7,ri=1/ni,ai="\\s*([+-]?\\d+)\\s*",oi="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",ii="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",li=/^#([0-9a-f]{3,8})$/,si=new RegExp(`^rgb\\(${ai},${ai},${ai}\\)$`),ci=new RegExp(`^rgb\\(${ii},${ii},${ii}\\)$`),ui=new RegExp(`^rgba\\(${ai},${ai},${ai},${oi}\\)$`),fi=new RegExp(`^rgba\\(${ii},${ii},${ii},${oi}\\)$`),di=new RegExp(`^hsl\\(${oi},${ii},${ii}\\)$`),hi=new RegExp(`^hsla\\(${oi},${ii},${ii},${oi}\\)$`),mi={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function pi(){return this.rgb().formatHex()}function gi(){return this.rgb().formatRgb()}function vi(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=li.exec(e))?(n=t[1].length,t=parseInt(t[1],16),6===n?bi(t):3===n?new xi(t>>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===n?yi(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===n?yi(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|240&t,((15&t)<<4|15&t)/255):null):(t=si.exec(e))?new xi(t[1],t[2],t[3],1):(t=ci.exec(e))?new xi(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=ui.exec(e))?yi(t[1],t[2],t[3],t[4]):(t=fi.exec(e))?yi(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=di.exec(e))?Ti(t[1],t[2]/100,t[3]/100,1):(t=hi.exec(e))?Ti(t[1],t[2]/100,t[3]/100,t[4]):mi.hasOwnProperty(e)?bi(mi[e]):"transparent"===e?new xi(NaN,NaN,NaN,0):null}function bi(e){return new xi(e>>16&255,e>>8&255,255&e,1)}function yi(e,t,n,r){return r<=0&&(e=t=n=NaN),new xi(e,t,n,r)}function wi(e,t,n,r){return 1===arguments.length?function(e){return e instanceof ti||(e=vi(e)),e?new xi((e=e.rgb()).r,e.g,e.b,e.opacity):new xi}(e):new xi(e,t,n,null==r?1:r)}function xi(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}function ki(){return`#${Mi(this.r)}${Mi(this.g)}${Mi(this.b)}`}function _i(){const e=Ni(this.opacity);return`${1===e?"rgb(":"rgba("}${Si(this.r)}, ${Si(this.g)}, ${Si(this.b)}${1===e?")":`, ${e})`}`}function Ni(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Si(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Mi(e){return((e=Si(e))<16?"0":"")+e.toString(16)}function Ti(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new ji(e,t,n,r)}function Ci(e){if(e instanceof ji)return new ji(e.h,e.s,e.l,e.opacity);if(e instanceof ti||(e=vi(e)),!e)return new ji;if(e instanceof ji)return e;var t=(e=e.rgb()).r/255,n=e.g/255,r=e.b/255,a=Math.min(t,n,r),o=Math.max(t,n,r),i=NaN,l=o-a,s=(o+a)/2;return l?(i=t===o?(n-r)/l+6*(n<r):n===o?(r-t)/l+2:(t-n)/l+4,l/=s<.5?o+a:2-o-a,i*=60):l=s>0&&s<1?0:i,new ji(i,l,s,e.opacity)}function ji(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function Oi(e){return(e=(e||0)%360)<0?e+360:e}function Ri(e){return Math.max(0,Math.min(1,e||0))}function Pi(e,t,n){return 255*(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)}Go(ti,vi,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:pi,formatHex:pi,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return Ci(this).formatHsl()},formatRgb:gi,toString:gi}),Go(xi,wi,ei(ti,{brighter(e){return e=null==e?ri:Math.pow(ri,e),new xi(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=null==e?ni:Math.pow(ni,e),new xi(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new xi(Si(this.r),Si(this.g),Si(this.b),Ni(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:ki,formatHex:ki,formatHex8:function(){return`#${Mi(this.r)}${Mi(this.g)}${Mi(this.b)}${Mi(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:_i,toString:_i})),Go(ji,function(e,t,n,r){return 1===arguments.length?Ci(e):new ji(e,t,n,null==r?1:r)},ei(ti,{brighter(e){return e=null==e?ri:Math.pow(ri,e),new ji(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=null==e?ni:Math.pow(ni,e),new ji(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+360*(this.h<0),t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,a=2*n-r;return new xi(Pi(e>=240?e-240:e+120,a,r),Pi(e,a,r),Pi(e<120?e+240:e-120,a,r),this.opacity)},clamp(){return new ji(Oi(this.h),Ri(this.s),Ri(this.l),Ni(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=Ni(this.opacity);return`${1===e?"hsl(":"hsla("}${Oi(this.h)}, ${100*Ri(this.s)}%, ${100*Ri(this.l)}%${1===e?")":`, ${e})`}`}}));var Ei=e=>()=>e;function Fi(e){return 1===(e=+e)?Ai:function(t,n){return n-t?function(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}(t,n,e):Ei(isNaN(t)?n:t)}}function Ai(e,t){var n=t-e;return n?function(e,t){return function(n){return e+n*t}}(e,n):Ei(isNaN(e)?t:e)}var Ii=function e(t){var n=Fi(t);function r(e,t){var r=n((e=wi(e)).r,(t=wi(t)).r),a=n(e.g,t.g),o=n(e.b,t.b),i=Ai(e.opacity,t.opacity);return function(t){return e.r=r(t),e.g=a(t),e.b=o(t),e.opacity=i(t),e+""}}return r.gamma=e,r}(1);function Di(e,t){t||(t=[]);var n,r=e?Math.min(t.length,e.length):0,a=t.slice();return function(o){for(n=0;n<r;++n)a[n]=e[n]*(1-o)+t[n]*o;return a}}function Bi(e,t){var n,r=t?t.length:0,a=e?Math.min(r,e.length):0,o=new Array(a),i=new Array(r);for(n=0;n<a;++n)o[n]=Ui(e[n],t[n]);for(;n<r;++n)i[n]=t[n];return function(e){for(n=0;n<a;++n)i[n]=o[n](e);return i}}function Li(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function $i(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function zi(e,t){var n,r={},a={};for(n in null!==e&&"object"==typeof e||(e={}),null!==t&&"object"==typeof t||(t={}),t)n in e?r[n]=Ui(e[n],t[n]):a[n]=t[n];return function(e){for(n in r)a[n]=r[n](e);return a}}var Vi=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Hi=new RegExp(Vi.source,"g");function Wi(e,t){var n,r,a,o=Vi.lastIndex=Hi.lastIndex=0,i=-1,l=[],s=[];for(e+="",t+="";(n=Vi.exec(e))&&(r=Hi.exec(t));)(a=r.index)>o&&(a=t.slice(o,a),l[i]?l[i]+=a:l[++i]=a),(n=n[0])===(r=r[0])?l[i]?l[i]+=r:l[++i]=r:(l[++i]=null,s.push({i:i,x:$i(n,r)})),o=Hi.lastIndex;return o<t.length&&(a=t.slice(o),l[i]?l[i]+=a:l[++i]=a),l.length<2?s[0]?function(e){return function(t){return e(t)+""}}(s[0].x):function(e){return function(){return e}}(t):(t=s.length,function(e){for(var n,r=0;r<t;++r)l[(n=s[r]).i]=n.x(e);return l.join("")})}function Ui(e,t){var n,r=typeof t;return null==t||"boolean"===r?Ei(t):("number"===r?$i:"string"===r?(n=vi(t))?(t=n,Ii):Wi:t instanceof vi?Ii:t instanceof Date?Li:function(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}(t)?Di:Array.isArray(t)?Bi:"function"!=typeof t.valueOf&&"function"!=typeof t.toString||isNaN(t)?zi:$i)(e,t)}function Ji(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}function Qi(e){return+e}var qi=[0,1];function Xi(e){return e}function Yi(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:function(e){return function(){return e}}(isNaN(t)?NaN:.5)}function Ki(e,t,n){var r=e[0],a=e[1],o=t[0],i=t[1];return a<r?(r=Yi(a,r),o=n(i,o)):(r=Yi(r,a),o=n(o,i)),function(e){return o(r(e))}}function Zi(e,t,n){var r=Math.min(e.length,t.length)-1,a=new Array(r),o=new Array(r),i=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++i<r;)a[i]=Yi(e[i],e[i+1]),o[i]=n(t[i],t[i+1]);return function(t){var n=Jo(e,t,1,r)-1;return o[n](a[n](t))}}function Gi(){var e,t,n,r,a,o,i=qi,l=qi,s=Ui,c=Xi;function u(){var e=Math.min(i.length,l.length);return c!==Xi&&(c=function(e,t){var n;return e>t&&(n=e,e=t,t=n),function(n){return Math.max(e,Math.min(t,n))}}(i[0],i[e-1])),r=e>2?Zi:Ki,a=o=null,f}function f(t){return null==t||isNaN(t=+t)?n:(a||(a=r(i.map(e),l,s)))(e(c(t)))}return f.invert=function(n){return c(t((o||(o=r(l,i.map(e),$i)))(n)))},f.domain=function(e){return arguments.length?(i=Array.from(e,Qi),u()):i.slice()},f.range=function(e){return arguments.length?(l=Array.from(e),u()):l.slice()},f.rangeRound=function(e){return l=Array.from(e),s=Ji,u()},f.clamp=function(e){return arguments.length?(c=!!e||Xi,u()):c!==Xi},f.interpolate=function(e){return arguments.length?(s=e,u()):s},f.unknown=function(e){return arguments.length?(n=e,f):n},function(n,r){return e=n,t=r,u()}}function el(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function tl(e){return(e=el(Math.abs(e)))?e[1]:NaN}var nl,rl=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function al(e){if(!(t=rl.exec(e)))throw new Error("invalid format: "+e);var t;return new ol({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}function ol(e){this.fill=void 0===e.fill?" ":e.fill+"",this.align=void 0===e.align?">":e.align+"",this.sign=void 0===e.sign?"-":e.sign+"",this.symbol=void 0===e.symbol?"":e.symbol+"",this.zero=!!e.zero,this.width=void 0===e.width?void 0:+e.width,this.comma=!!e.comma,this.precision=void 0===e.precision?void 0:+e.precision,this.trim=!!e.trim,this.type=void 0===e.type?"":e.type+""}function il(e,t){var n=el(e,t);if(!n)return e+"";var r=n[0],a=n[1];return a<0?"0."+new Array(-a).join("0")+r:r.length>a+1?r.slice(0,a+1)+"."+r.slice(a+1):r+new Array(a-r.length+2).join("0")}al.prototype=ol.prototype,ol.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};var ll={"%":(e,t)=>(100*e).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:function(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)},e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>il(100*e,t),r:il,s:function(e,t){var n=el(e,t);if(!n)return e+"";var r=n[0],a=n[1],o=a-(nl=3*Math.max(-8,Math.min(8,Math.floor(a/3))))+1,i=r.length;return o===i?r:o>i?r+new Array(o-i+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+el(e,Math.max(0,t+o-1))[0]},X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function sl(e){return e}var cl,ul,fl,dl=Array.prototype.map,hl=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function ml(e){var t,n,r=void 0===e.grouping||void 0===e.thousands?sl:(t=dl.call(e.grouping,Number),n=e.thousands+"",function(e,r){for(var a=e.length,o=[],i=0,l=t[0],s=0;a>0&&l>0&&(s+l+1>r&&(l=Math.max(1,r-s)),o.push(e.substring(a-=l,a+l)),!((s+=l+1)>r));)l=t[i=(i+1)%t.length];return o.reverse().join(n)}),a=void 0===e.currency?"":e.currency[0]+"",o=void 0===e.currency?"":e.currency[1]+"",i=void 0===e.decimal?".":e.decimal+"",l=void 0===e.numerals?sl:function(e){return function(t){return t.replace(/[0-9]/g,function(t){return e[+t]})}}(dl.call(e.numerals,String)),s=void 0===e.percent?"%":e.percent+"",c=void 0===e.minus?"−":e.minus+"",u=void 0===e.nan?"NaN":e.nan+"";function f(e){var t=(e=al(e)).fill,n=e.align,f=e.sign,d=e.symbol,h=e.zero,m=e.width,p=e.comma,g=e.precision,v=e.trim,b=e.type;"n"===b?(p=!0,b="g"):ll[b]||(void 0===g&&(g=12),v=!0,b="g"),(h||"0"===t&&"="===n)&&(h=!0,t="0",n="=");var y="$"===d?a:"#"===d&&/[boxX]/.test(b)?"0"+b.toLowerCase():"",w="$"===d?o:/[%p]/.test(b)?s:"",x=ll[b],k=/[defgprs%]/.test(b);function _(e){var a,o,s,d=y,_=w;if("c"===b)_=x(e)+_,e="";else{var N=(e=+e)<0||1/e<0;if(e=isNaN(e)?u:x(Math.abs(e),g),v&&(e=function(e){e:for(var t,n=e.length,r=1,a=-1;r<n;++r)switch(e[r]){case".":a=t=r;break;case"0":0===a&&(a=r),t=r;break;default:if(!+e[r])break e;a>0&&(a=0)}return a>0?e.slice(0,a)+e.slice(t+1):e}(e)),N&&0===+e&&"+"!==f&&(N=!1),d=(N?"("===f?f:c:"-"===f||"("===f?"":f)+d,_=("s"===b?hl[8+nl/3]:"")+_+(N&&"("===f?")":""),k)for(a=-1,o=e.length;++a<o;)if(48>(s=e.charCodeAt(a))||s>57){_=(46===s?i+e.slice(a+1):e.slice(a))+_,e=e.slice(0,a);break}}p&&!h&&(e=r(e,1/0));var S=d.length+e.length+_.length,M=S<m?new Array(m-S+1).join(t):"";switch(p&&h&&(e=r(M+e,M.length?m-_.length:1/0),M=""),n){case"<":e=d+e+_+M;break;case"=":e=d+M+e+_;break;case"^":e=M.slice(0,S=M.length>>1)+d+e+_+M.slice(S);break;default:e=M+d+e+_}return l(e)}return g=void 0===g?6:/[gprs]/.test(b)?Math.max(1,Math.min(21,g)):Math.max(0,Math.min(20,g)),_.toString=function(){return e+""},_}return{format:f,formatPrefix:function(e,t){var n=f(((e=al(e)).type="f",e)),r=3*Math.max(-8,Math.min(8,Math.floor(tl(t)/3))),a=Math.pow(10,-r),o=hl[8+r/3];return function(e){return n(a*e)+o}}}}function pl(e,t,n,r){var a,o=function(e,t,n){n=+n;const r=(t=+t)<(e=+e),a=r?Ko(t,e,n):Ko(e,t,n);return(r?-1:1)*(a<0?1/-a:a)}(e,t,n);switch((r=al(null==r?",f":r)).type){case"s":var i=Math.max(Math.abs(e),Math.abs(t));return null!=r.precision||isNaN(a=function(e,t){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(tl(t)/3)))-tl(Math.abs(e)))}(o,i))||(r.precision=a),fl(r,i);case"":case"e":case"g":case"p":case"r":null!=r.precision||isNaN(a=function(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,tl(t)-tl(e))+1}(o,Math.max(Math.abs(e),Math.abs(t))))||(r.precision=a-("e"===r.type));break;case"f":case"%":null!=r.precision||isNaN(a=function(e){return Math.max(0,-tl(Math.abs(e)))}(o))||(r.precision=a-2*("%"===r.type))}return ul(r)}function gl(e){var t=e.domain;return e.ticks=function(e){var n=t();return function(e,t,n){if(!((n=+n)>0))return[];if((e=+e)===(t=+t))return[e];const r=t<e,[a,o,i]=r?Yo(t,e,n):Yo(e,t,n);if(!(o>=a))return[];const l=o-a+1,s=new Array(l);if(r)if(i<0)for(let e=0;e<l;++e)s[e]=(o-e)/-i;else for(let e=0;e<l;++e)s[e]=(o-e)*i;else if(i<0)for(let e=0;e<l;++e)s[e]=(a+e)/-i;else for(let e=0;e<l;++e)s[e]=(a+e)*i;return s}(n[0],n[n.length-1],null==e?10:e)},e.tickFormat=function(e,n){var r=t();return pl(r[0],r[r.length-1],null==e?10:e,n)},e.nice=function(n){null==n&&(n=10);var r,a,o=t(),i=0,l=o.length-1,s=o[i],c=o[l],u=10;for(c<s&&(a=s,s=c,c=a,a=i,i=l,l=a);u-- >0;){if((a=Ko(s,c,n))===r)return o[i]=s,o[l]=c,t(o);if(a>0)s=Math.floor(s/a)*a,c=Math.ceil(c/a)*a;else{if(!(a<0))break;s=Math.ceil(s*a)/a,c=Math.floor(c*a)/a}r=a}return e},e}function vl(){var e=Gi()(Xi,Xi);return e.copy=function(){return t=e,vl().domain(t.domain()).range(t.range()).interpolate(t.interpolate()).clamp(t.clamp()).unknown(t.unknown());var t},Zo.apply(e,arguments),gl(e)}function bl(e,t){if(e===t)return 0;if(0===e)return 100;const n=(t-e)/e*100;return n>100?100:n<-100?-100:n}function yl(e,t){return Do.rgb(e,e,e).alpha(t)}function wl(e,t){if(0===t.length)return t;const n=function(e){switch(e){case"dotnetspy":return/^(?<packageName>.+)\.(.+)\.(.+)\(.*\)$/;case"ebpfspy":case"unknown":return/^(?<packageName>.+)$/;case"gospy":case"scrape":return/^(?<packageName>.*?\/.*?\.|.*?\.|.+)(?<functionName>.*)$/;case"phpspy":return/^(?<packageName>(.*\/)*)(?<filename>.*\.php+)(?<line_info>.*)$/;case"pyspy":return/^(?<packageName>(.*\/)*)(?<filename>.*\.py+)(?<line_info>.*)$/;case"rbspy":return/^(?<packageName>(.*\/)*)(?<filename>.*\.rb+)(?<line_info>.*)$/;case"nodespy":return/^(\.\/node_modules\/)?(?<packageName>[^/]*)(?<filename>.*\.?(jsx?|tsx?)?):(?<functionName>.*):(?<line_info>.*)$/;case"tracing":return/^(?<packageName>.+?):.*$/;case"javaspy":return/^(?<packageName>.+\/)(?<filename>.+\.)(?<functionName>.+)$/;case"pyroscope-rs":return/^(?<packageName>[^::]+)/}return/^(?<packageName>.+)$/}(e),r=t.match(n);return r&&r.groups?r.groups.packageName||"":t}function xl(e,t){const n=function(e,t=0){let n,r,a,o,i,l,s,c;for(n=3&e.length,r=e.length-n,a=t,i=3432918353,l=461845907,c=0;c<r;)s=255&e.charCodeAt(c)|(255&e.charCodeAt(++c))<<8|(255&e.charCodeAt(++c))<<16|(255&e.charCodeAt(++c))<<24,++c,s=(65535&s)*i+(((s>>>16)*i&65535)<<16)&4294967295,s=s<<15|s>>>17,s=(65535&s)*l+(((s>>>16)*l&65535)<<16)&4294967295,a^=s,a=a<<13|a>>>19,o=5*(65535&a)+((5*(a>>>16)&65535)<<16)&4294967295,a=27492+(65535&o)+(((o>>>16)+58964&65535)<<16);switch(s=0,n){case 3:s^=(255&e.charCodeAt(c+2))<<16;case 2:s^=(255&e.charCodeAt(c+1))<<8;case 1:s^=255&e.charCodeAt(c);default:s=(65535&s)*i+(((s>>>16)*i&65535)<<16)&4294967295,s=s<<15|s>>>17,s=(65535&s)*l+(((s>>>16)*l&65535)<<16)&4294967295,a^=s}return a^=e.length,a^=a>>>16,a=2246822507*(65535&a)+((2246822507*(a>>>16)&65535)<<16)&4294967295,a^=a>>>13,a=3266489909*(65535&a)+((3266489909*(a>>>16)&65535)<<16)&4294967295,a^=a>>>16,a>>>0}(t,0),r=n%e.colors.length,a=e.colors[r];return a||(console.warn("Could not calculate color. Defaulting to the first one"),e.colors[0])}function kl(e){const{goodColor:t,neutralColor:n,badColor:r}=e,a=vl().domain([-100,0,100]).range([t.rgb().toString(),n.rgb().toString(),r.rgb().toString()]);return e=>Do(a(e).toString())}cl=ml({thousands:",",grouping:[3],currency:["$",""]}),ul=cl.format,fl=cl.formatPrefix,Do.rgb(148,142,142),Do.rgb(200,0,0),Do.rgb(0,170,0),Do("#48CE73");const _l=new WeakMap,Nl=new WeakMap,Sl=new WeakMap,Ml=new WeakMap;const Tl={collapsedLevelsSingular:"total (1 level collapsed)",collapsedLevelsPlural:"total ({n} levels collapsed)",isZh:!1};function Cl(e){var t,n,r,a,o,i,l,s;const c=performance.now(),u=!1!==e.renderRects,f=!1!==e.renderText,d=null!==(t=e.renderMode)&&void 0!==t?t:"normal",h=e.timeBudgetMs,{canvas:m,fitMode:p,units:g,tickToX:v,levels:b,palette:y}=e,{numTicks:w,sampleRate:x,pxPerTick:k}=e,{rangeMin:_,rangeMax:N}=e,{focusedNode:S,zoom:M}=e,T=e.messages||Tl,C=e.skipCanvasResize?m.width:function(e){if("clientWidth"in e&&"number"==typeof e.clientWidth)return e.clientWidth;return e.width}(m);if(e.skipCanvasResize||(m.width=C),_>=N)throw new Error("'rangeMin' should be strictly smaller than 'rangeMax'");const{format:j}=e,O=Wa(j),R=m.getContext("2d");if(!R)throw new Error("Could not get ctx");const P=M.mapOrElse(()=>0,e=>e.i),E=ao(w,x,g),F=S.isJust,A=S.mapOrElse(()=>0,e=>e.i),I=F?Ka:0,D=!!e.highlightQuery&&e.highlightQuery.length>0,B=Ya*(b.length-A)+(F?Ka:0);e.skipCanvasResize||(m.height=B);const L="number"==typeof e.devicePixelRatio?e.devicePixelRatio:"undefined"!=typeof devicePixelRatio?devicePixelRatio:1;!e.skipDprScale&&L>1&&(m.width*=L,m.height*=L,R.scale(L,L)),R.textBaseline="middle",R.font="400 11.5px SFMono-Regular, Consolas, Liberation Mono, Menlo, monospace";const $=R.measureText("a").width,{names:z}=e,V=function(e){const t=_l.get(e);if(t)return t;const n=new Map;return _l.set(e,n),n}(m),H=D?function(e,t){const n=Nl.get(e);if(n){const e=n.get(t);if(e)return e}const r=t.toLowerCase(),a=new Uint8Array(e.length);for(let t=1;t<e.length;t+=1){const n=e[t];n&&n.toLowerCase().includes(r)&&(a[t]=1)}const o=null!=n?n:new Map;return o.set(t,a),Nl.set(e,o),a}(z,e.highlightQuery):null,W="single"===e.format?function(e,t,n){const r=`${t}|${n.name}`,a=Sl.get(e);if(a){const e=a.get(r);if(e)return e}const o=new Array(e.length);for(let r=0;r<e.length;r+=1){const a=wl(t,e[r]||"")||"";o[r]=xl(n,a)}const i=null!=a?a:new Map;return i.set(r,o),Sl.set(e,i),o}(z,e.spyName,y):null,U="double"===e.format?kl({name:y.name,goodColor:y.goodColor,neutralColor:y.neutralColor,badColor:y.badColor}):null,J=(e,t)=>{const n=e[t+O.jName];return!(!n||n<0||!H)&&1===H[n]},Q=null!==(n=e.startI)&&void 0!==n?n:0,q=null!==(r=e.startJ)&&void 0!==r?r:0;if(F&&"highlightOnly"!==d&&0===(null!==(a=e.levelStart)&&void 0!==a?a:0)&&0===Q&&0===q){const e=w*k;u&&(R.beginPath(),R.rect(0,0,w*k,Ka),R.fillStyle=yl(200,1).rgb().string(),R.fill());const t=S.mapOrElse(()=>"total",e=>function(e,t){return 1===e?t.collapsedLevelsSingular:t.collapsedLevelsPlural.replace("{n}",String(e))}(e.i-1,T)),n=fo({mode:p,charSize:$,rectWidth:e,fullText:t,shortText:t}),r=0,a=0,o=Ka;if(f){R.beginPath(),R.rect(0,0,e,Ka),R.save(),R.clip(),R.fillStyle="black";const t=Math.round(Math.max(r,0));R.fillText(n.text,t+n.marginLeft,a+o/2+1),R.restore()}}const X=Math.max(0,null!==(o=e.levelStart)&&void 0!==o?o:0),Y=b.length-A,K=Math.min(Y,null!==(i=e.levelEnd)&&void 0!==i?i:Y),Z=Math.max(X,null!==(l=e.startI)&&void 0!==l?l:X),G=Math.max(0,null!==(s=e.startJ)&&void 0!==s?s:0),{spyName:ee}=e,te=(t,n,r,a,o)=>{const i={level:t,j:n,i:r+S.mapOrElse(()=>0,e=>e.i),names:z,collapsed:a,selectedLevel:P,highlightModeOn:D,isHighlighted:o,spyName:ee,palette:y,colorByNameIndex:W,diffColorFn:U};switch(j){case"single":return function(e){const t=Rl(e);if(t)return t;const n=Wa("single"),r=e.selectedLevel>e.i?.33:1;let a=e.level[e.j+n.jName];void 0===a&&(console.warn("Could nto find level",{l:e.j,jName:n.jName,level:e.level}),a=-1);if(e.colorByNameIndex&&a>=0&&e.colorByNameIndex[a])return e.colorByNameIndex[a].alpha(r);const o=e.names[a]||"",i=wl(e.spyName,o)||"";return xl(e.palette,i).alpha(r)}({...i});case"double":return function(e){const t=Rl(e);if(t)return t;const n=e.selectedLevel>e.i?.33:1,{leftRatio:r,rightRatio:a}=function(e,t,n,r){const a=Ha;return n&&r?{leftRatio:a.getBarTotalLeft(e,t)/n,rightRatio:a.getBarTotalRght(e,t)/r}:(console.error("Properties 'rightTicks' and 'leftTicks' are required. Can't calculate ratio."),{leftRatio:0,rightRatio:0})}(e.level,e.j,e.leftTicks,e.rightTicks),o=no(r),i=no(a);if(e.diffColorFn)return e.diffColorFn(bl(o,i)).alpha(n);return function(e,t,n){const r=bl(t,n);return kl(e)(r)}(e.palette,o,i).alpha(n)}({...i,leftTicks:e.leftTicks,rightTicks:e.rightTicks});default:throw new Error(`Unsupported format: ${j}`)}};if("highlightOnly"===d&&D&&u){const e=function(e,t){const n=Ml.get(e);if(n)return n;const r=Wa(t),a=new Map;for(let t=0;t<e.length;t+=1){const n=e[t];for(let e=0;e<n.length;e+=r.jStep){const o=r.getBarName(n,e);if(void 0===o||o<0)continue;const i=a.get(o);i?i.push({i:t,j:e}):a.set(o,[{i:t,j:e}])}}return Ml.set(e,a),a}(b,j),t=[];for(let e=1;e<z.length;e+=1)H&&1===H[e]&&t.push(e);for(let n=0;n<t.length;n+=1){const r=t[n],a=e.get(r);if(a)for(let e=0;e<a.length;e+=1){const t=a[e],n=t.i-A;if(t.i<A||n<X||n>=K)continue;const r=b[t.i],o=v(O.getBarOffset(r,t.j)),i=n*Ya+I,l=Ka,s=O.getBarTotal(r,t.j),c=s*k<=5,u=s*k-(c?0:.5);if(u<=0)continue;R.beginPath(),R.rect(o,i,u,l);const f=te(r,t.j,n,c,!0);R.fillStyle=f.string(),R.fill()}}return{done:!0,nextI:K,nextJ:0}}for(let e=Z;e<K;e+=1){const t=b[A+e];if(!t)throw new Error(`Could not find level: ${A+e}`);let n=e===Z?G:0;for(;n<t.length;n+=O.jStep){const r=O.getBarOffset(t,n),a=v(r),o=e*Ya+I,i=Ka,l=D&&J(t,n);let s=O.getBarTotal(t,n);const m=s*k<=5;if(m)for(;n<t.length-O.jStep&&r+s===O.getBarOffset(t,n+O.jStep)&&O.getBarTotal(t,n+O.jStep)*k<=5&&l===(D&&J(t,n+O.jStep));)n+=O.jStep,s+=O.getBarTotal(t,n);const g=s*k-(m?0:.5);if(R.beginPath(),R.rect(a,o,g,i),u){if("forceGrey"===d)R.fillStyle=yl(200,.66).rgb().string();else{const r=te(t,n,e,m,l);R.fillStyle=r.string()}R.fill()}if(!f||m||"forceGrey"===d){if(h&&performance.now()-c>h)return{done:!1,nextI:e,nextJ:n+O.jStep};continue}if(g<20)continue;const b=jl(z,n,j,t),y=fo({mode:p,charSize:$,rectWidth:g,fullText:Ol(b,s,x,E,T,V),shortText:b});R.save(),R.clip(),R.fillStyle="black";const w=Math.round(Math.max(a,0));if(R.fillText(y.text,w+y.marginLeft,o+i/2+1),R.restore(),h&&performance.now()-c>h)return{done:!1,nextI:e,nextJ:n+O.jStep}}if(h&&performance.now()-c>h)return{done:!1,nextI:e+1,nextJ:0}}return{done:!0,nextI:K,nextJ:0}}function jl(e,t,n,r){let a=r[t+Wa(n).jName];void 0===a&&(a=-1);const o=e[a];return o||(console.warn("Could not find function name for",{j:t,format:n,level:r,names:e}),"")}function Ol(e,t,n,r,a,o){let i=null==o?void 0:o.get(t);if(!i){const e=r.format(t,n);i=eo(e,!!a.isZh)||e,null==o||o.set(t,i)}return`${e} (${i})`}function Rl({collapsed:e,highlightModeOn:t,isHighlighted:n}){return e||t&&!n?yl(200,.66):null}class Pl{constructor(e,t,n,r,a,o,i,l){if(this.flamebearer=e,this.canvas=t,this.focusedNode=n,this.fitMode=r,this.highlightQuery=a,this.zoom=o,this.palette=i,this.messages=l,this.cachedRange=null,this.cachedPxPerTick=null,this.tickToX=e=>{var t;const n=this.cachedRange?this.cachedRange.rangeMin:this.getRange().rangeMin,r=null!==(t=this.cachedPxPerTick)&&void 0!==t?t:this.pxPerTick();return(e-this.flamebearer.numTicks*n)*r},this.xyToBarPosition=e=>{const{ff:t}=this,{i:n,j:r}=this.xyToBarIndex(e.x,e.y),a=this.focusedNode.mapOrElse(()=>0,e=>e.i<0?0:e.i-1),o=this.flamebearer.levels[n];if(!o)throw new Error(`Could not find level: '${n}'`);const i=Math.max(this.tickToX(t.getBarOffset(o,r)),0);return{x:i,y:Math.max((n-a)*Ya,0),width:Math.min(this.tickToX(t.getBarOffset(o,r)+t.getBarTotal(o,r))-i,this.getCanvasWidth())}},this.xyToBarData=e=>{const{i:t,j:n}=this.xyToBarIndex(e.x,e.y),r=this.flamebearer.levels[t];if(!r)throw new Error(`Could not find level: '${t}'`);switch(this.flamebearer.format){case"single":{const e=Va;return{format:"single",name:this.flamebearer.names[e.getBarName(r,n)],self:e.getBarSelf(r,n),offset:e.getBarOffset(r,n),total:e.getBarTotal(r,n)}}case"double":{const e=Ha;return{format:"double",barTotal:e.getBarTotal(r,n),totalLeft:e.getBarTotalLeft(r,n),totalRight:e.getBarTotalRght(r,n),totalDiff:e.getBarTotalDiff(r,n),name:this.flamebearer.names[e.getBarName(r,n)]}}default:throw new Error("Unsupported type")}},this.isWithinBounds=(e,t)=>{if(e<0||e>this.getCanvasWidth())return!1;try{const{i:n,j:r}=this.xyToBarIndex(e,t);if(-1===r||-1===n)return!1}catch(e){return!1}return!0},this.zoom=o,this.focusedNode=n,this.flamebearer=e,this.canvas=t,this.highlightQuery=a,this.ff=Wa(e.format),this.palette=i,this.messages=l,n.isJust&&o.isJust&&o.value.i<n.value.i)throw new Error("Zoom i level should be bigger than Focus")}render(e){var t;const{rangeMin:n,rangeMax:r,pxPerTick:a}=this.updateCachedMetrics(),o=null!==(t=null==e?void 0:e.highlightQueryOverride)&&void 0!==t?t:this.highlightQuery,i={canvas:this.canvas,format:this.flamebearer.format,numTicks:this.flamebearer.numTicks,sampleRate:this.flamebearer.sampleRate,names:this.flamebearer.names,levels:this.flamebearer.levels,spyName:this.flamebearer.spyName,units:this.flamebearer.units,maxSelf:this.flamebearer.maxSelf,rangeMin:n,rangeMax:r,fitMode:this.fitMode,highlightQuery:o,zoom:this.zoom,focusedNode:this.focusedNode,pxPerTick:a,tickToX:e=>(e-this.flamebearer.numTicks*n)*a,palette:this.palette,messages:this.messages,renderRects:null==e?void 0:e.renderRects,renderText:null==e?void 0:e.renderText,renderMode:null==e?void 0:e.renderMode,levelStart:null==e?void 0:e.levelStart,levelEnd:null==e?void 0:e.levelEnd,startI:null==e?void 0:e.startI,startJ:null==e?void 0:e.startJ,timeBudgetMs:null==e?void 0:e.timeBudgetMs,skipCanvasResize:null==e?void 0:e.skipCanvasResize,skipDprScale:null==e?void 0:e.skipDprScale,devicePixelRatio:null==e?void 0:e.devicePixelRatio},{format:l}=this.flamebearer;switch(l){case"single":return Cl({...i,format:"single"});case"double":return Cl({...i,leftTicks:this.flamebearer.leftTicks,rightTicks:this.flamebearer.rightTicks});default:throw new Error(`Invalid format: '${l}'`)}}pxPerTick(){if(null!==this.cachedPxPerTick)return this.cachedPxPerTick;const{rangeMin:e,rangeMax:t}=this.getRange(),n=this.getCanvasWidth()/this.flamebearer.numTicks/(t-e);return this.cachedRange={rangeMin:e,rangeMax:t},this.cachedPxPerTick=n,n}updateCachedMetrics(){const{rangeMin:e,rangeMax:t}=this.getRange(),n=this.getCanvasWidth()/this.flamebearer.numTicks/(t-e);return this.cachedRange={rangeMin:e,rangeMax:t},this.cachedPxPerTick=n,{rangeMin:e,rangeMax:t,pxPerTick:n}}getRange(){const{ff:e}=this,t=t=>{const n=this.flamebearer.levels[t.i];if(!n)throw new Error(`Could not find level: '${t.i}'`);return{rangeMin:e.getBarOffset(n,t.j)/this.flamebearer.numTicks,rangeMax:(e.getBarOffset(n,t.j)+e.getBarTotal(n,t.j))/this.flamebearer.numTicks}},n=t=>{const n=this.flamebearer.levels[t.i];if(!n)throw new Error(`Could not find level: '${t.i}'`);return{rangeMin:e.getBarOffset(n,t.j)/this.flamebearer.numTicks,rangeMax:(e.getBarOffset(n,t.j)+e.getBarTotal(n,t.j))/this.flamebearer.numTicks}},{zoom:r,focusedNode:a}=this;return r.match({Just:e=>a.match({Just:r=>{const a=n(r),o=t(e);return a.rangeMax-a.rangeMin<o.rangeMax-o.rangeMin?(console.warn("Focus is smaller than range, this shouldnt happen. Verify that the zoom is always bigger than the focus."),n(r)):t(e)},Nothing:()=>t(e)}),Nothing:()=>a.match({Just:e=>n(e),Nothing:()=>({rangeMin:0,rangeMax:1})})})}getCanvasWidth(){return"clientWidth"in this.canvas&&"number"==typeof this.canvas.clientWidth?this.canvas.clientWidth:this.canvas.width}isFocused(){return this.focusedNode.isJust}binarySearchLevel(e,t){const{ff:n}=this;let r=0,a=t.length-n.jStep;for(;r<=a;){const o=n.jStep*(r/n.jStep+a/n.jStep>>1),i=this.tickToX(n.getBarOffset(t,o)),l=this.tickToX(n.getBarOffset(t,o)+n.getBarTotal(t,o));if(i<=e&&l>=e)return l-i>5?o:-1;i>e?a=o-n.jStep:r=o+n.jStep}return-1}xyToBarIndex(e,t){if(e<0||t<0)throw new Error(`x and y must be bigger than 0. x = ${e}, y = ${t}`);if(this.isFocused()&&t<=Ka)return{i:0,j:0};const n=this.isFocused()?t-Ka:t,r=this.focusedNode.mapOrElse(()=>0,e=>e.i<=0?0:e.i),a=this.zoom.match({Just:()=>this.focusedNode.match({Just:()=>r,Nothing:()=>0}),Nothing:()=>this.focusedNode.match({Just:()=>r,Nothing:()=>0})}),o=Math.floor(n/Ya)+a;if(o>=0&&o<this.flamebearer.levels.length){const t=this.flamebearer.levels[o];if(!t)throw new Error(`Could not find level: '${o}'`);return{i:o,j:this.binarySearchLevel(e,t)}}return{i:0,j:0}}parseXY(e,t){const n={x:e,y:t};return this.isWithinBounds(e,t)?Aa.of(n):Aa.nothing()}xyToBar(e,t){return this.parseXY(e,t).map(n=>{const{i:r,j:a}=this.xyToBarIndex(e,t);return{i:r,j:a,...this.xyToBarPosition(n),...this.xyToBarData(n)}})}}function El(e){var t,n,r="";if("string"==typeof e||"number"==typeof e)r+=e;else if("object"==typeof e)if(Array.isArray(e)){var a=e.length;for(t=0;t<a;t++)e[t]&&(n=El(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function Fl(){for(var e,t,n=0,r="",a=arguments.length;n<a;n++)(e=arguments[n])&&(t=El(e))&&(r&&(r+=" "),r+=t);return r}var Al="NoData-module_noData__WuuID";function Il(){return e("div",{"data-testid":"no-data",className:Al,children:e("span",{children:"No data available"})})}var Dl,Bl,Ll={},$l={};function zl(){return Dl||(Dl=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="arrow-rotate-right",n=[8635,"arrow-right-rotate","arrow-rotate-forward","redo"],r="f01e",a="M436.7 74.7L448 85.4 448 32c0-17.7 14.3-32 32-32s32 14.3 32 32l0 128c0 17.7-14.3 32-32 32l-128 0c-17.7 0-32-14.3-32-32s14.3-32 32-32l47.9 0-7.6-7.2c-.2-.2-.4-.4-.6-.6-75-75-196.5-75-271.5 0s-75 196.5 0 271.5 196.5 75 271.5 0c8.2-8.2 15.5-16.9 21.9-26.1 10.1-14.5 30.1-18 44.6-7.9s18 30.1 7.9 44.6c-8.5 12.2-18.2 23.8-29.1 34.7-100 100-262.1 100-362 0S-25 175 75 75c99.9-99.9 261.7-100 361.7-.3z";e.definition={prefix:"fas",iconName:t,icon:[512,512,n,r,a]},e.faArrowRotateRight=e.definition,e.prefix="fas",e.iconName=t,e.width=512,e.height=512,e.ligatures=n,e.unicode=r,e.svgPathData=a,e.aliases=n}($l)),$l}function Vl(){return Bl||(Bl=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t=zl();e.definition={prefix:t.prefix,iconName:t.iconName,icon:[t.width,t.height,t.aliases,t.unicode,t.svgPathData]},e.faRedo=e.definition,e.prefix=t.prefix,e.iconName=t.iconName,e.width=t.width,e.height=t.height,e.ligatures=t.aliases,e.unicode=t.unicode,e.svgPathData=t.svgPathData,e.aliases=t.aliases}(Ll)),Ll}var Hl,Wl=Vl(),Ul={};function Jl(){return Hl||(Hl=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="copy",n=[],r="f0c5",a="M192 0c-35.3 0-64 28.7-64 64l0 256c0 35.3 28.7 64 64 64l192 0c35.3 0 64-28.7 64-64l0-200.6c0-17.4-7.1-34.1-19.7-46.2L370.6 17.8C358.7 6.4 342.8 0 326.3 0L192 0zM64 128c-35.3 0-64 28.7-64 64L0 448c0 35.3 28.7 64 64 64l192 0c35.3 0 64-28.7 64-64l0-16-64 0 0 16-192 0 0-256 16 0 0-64-16 0z";e.definition={prefix:"fas",iconName:t,icon:[448,512,n,r,a]},e.faCopy=e.definition,e.prefix="fas",e.iconName=t,e.width=448,e.height=512,e.ligatures=n,e.unicode=r,e.svgPathData=a,e.aliases=n}(Ul)),Ul}var Ql,ql=Jl(),Xl={};function Yl(){return Ql||(Ql=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="highlighter",n=[],r="f591",a="M315 315L473.4 99.9 444.1 70.6 229 229 315 315zm-187 5l0 0 0-71.7c0-15.3 7.2-29.6 19.5-38.6L420.6 8.4C428 2.9 437 0 446.2 0 457.6 0 468.5 4.5 476.6 12.6l54.8 54.8c8.1 8.1 12.6 19 12.6 30.5 0 9.2-2.9 18.2-8.4 25.6L334.4 396.5c-9 12.3-23.4 19.5-38.6 19.5l-71.7 0-25.4 25.4c-12.5 12.5-32.8 12.5-45.3 0l-50.7-50.7c-12.5-12.5-12.5-32.8 0-45.3L128 320zM7 466.3l51.7-51.7 70.6 70.6-19.7 19.7c-4.5 4.5-10.6 7-17 7L24 512c-13.3 0-24-10.7-24-24l0-4.7c0-6.4 2.5-12.5 7-17z";e.definition={prefix:"fas",iconName:t,icon:[576,512,n,r,a]},e.faHighlighter=e.definition,e.prefix="fas",e.iconName=t,e.width=576,e.height=512,e.ligatures=n,e.unicode=r,e.svgPathData=a,e.aliases=n}(Xl)),Xl}var Kl,Zl,Gl=Yl(),es={},ts={};function ns(){return Kl||(Kl=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="down-left-and-up-right-to-center",n=["compress-alt"],r="f422",a="M439.5 7c9.4-9.4 24.6-9.4 33.9 0l32 32c9.4 9.4 9.4 24.6 0 33.9l-87 87 39 39c6.9 6.9 8.9 17.2 5.2 26.2S450.2 240 440.5 240l-144 0c-13.3 0-24-10.7-24-24l0-144c0-9.7 5.8-18.5 14.8-22.2s19.3-1.7 26.2 5.2l39 39 87-87zM72.5 272l144 0c13.3 0 24 10.7 24 24l0 144c0 9.7-5.8 18.5-14.8 22.2s-19.3 1.7-26.2-5.2l-39-39-87 87c-9.4 9.4-24.6 9.4-33.9 0l-32-32c-9.4-9.4-9.4-24.6 0-33.9l87-87-39-39c-6.9-6.9-8.9-17.2-5.2-26.2S62.8 272 72.5 272z";e.definition={prefix:"fas",iconName:t,icon:[512,512,n,r,a]},e.faDownLeftAndUpRightToCenter=e.definition,e.prefix="fas",e.iconName=t,e.width=512,e.height=512,e.ligatures=n,e.unicode=r,e.svgPathData=a,e.aliases=n}(ts)),ts}function rs(){return Zl||(Zl=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t=ns();e.definition={prefix:t.prefix,iconName:t.iconName,icon:[t.width,t.height,t.aliases,t.unicode,t.svgPathData]},e.faCompressAlt=e.definition,e.prefix=t.prefix,e.iconName=t.iconName,e.width=t.width,e.height=t.height,e.ligatures=t.aliases,e.unicode=t.unicode,e.svgPathData=t.svgPathData,e.aliases=t.aliases}(es)),es}var as=rs();const os=e=>!!e&&"o"===e[0],is=N,ls=(e,t)=>!0===e||!(!e||!e[t]),ss=(e,t)=>"function"==typeof e?e(t):e,cs="_szhsinMenu",us=(e,t)=>Object.defineProperty(t,cs,{value:e}),fs=(e,t)=>(t&&Object.keys(t).forEach(n=>{const r=e[n],a=t[n];e[n]="function"==typeof a&&r?(...e)=>{a(...e),r(...e)}:a}),e),ds=e=>{for(;e;){if(!(e=e.parentNode)||e===document.body||!e.parentNode)return;const{overflow:t,overflowX:n,overflowY:r}=getComputedStyle(e);if(/auto|scroll|overlay|hidden/.test(t+r+n))return e}};function hs(e,t){return{"aria-disabled":e||void 0,tabIndex:t?0:-1}}function ms(e,t){for(let n=0;n<e.length;n++)if(e[n]===t)return n;return-1}const ps=({block:e,element:t,modifiers:n,className:r})=>o(()=>{const a=t?`${e}__${t}`:e;let o=a;n&&Object.keys(n).forEach(e=>{const t=n[e];t&&(o+=` ${a}--${!0===t?e:`${e}-${t}`}`)});let i="function"==typeof r?r(n):r;return"string"==typeof i&&(i=i.trim(),i&&(o+=` ${i}`)),o},[e,t,n,r]),gs="szh-menu",vs=i(),bs=i({}),ys=i({}),ws=i({}),xs=i({}),ks=i({}),_s=Object.freeze({ENTER:"Enter",ESC:"Escape",SPACE:" ",HOME:"Home",END:"End",LEFT:"ArrowLeft",RIGHT:"ArrowRight",UP:"ArrowUp",DOWN:"ArrowDown"}),Ns=Object.freeze({RESET:0,SET:1,UNSET:2,INCREASE:3,DECREASE:4,FIRST:5,LAST:6,SET_INDEX:7}),Ss=Object.freeze({CLICK:"click",CANCEL:"cancel",BLUR:"blur",SCROLL:"scroll"}),Ms=Object.freeze({FIRST:"first",LAST:"last"}),Ts=Object.freeze({entering:"opening",entered:"open",exiting:"closing",exited:"closed"}),Cs="absolute",js="none",Os={preventScroll:!0},Rs=us("MenuButton",l(function({className:t,isOpen:n,disabled:r,children:a,...i},l){const s=o(()=>({open:n}),[n]);return e("button",{"aria-haspopup":!0,"aria-expanded":n,"aria-disabled":r||void 0,type:"button",disabled:r,...i,ref:l,className:ps({block:"szh-menu-button",modifiers:s,className:t}),children:a})})),Ps=({className:t,containerRef:n,containerProps:r,children:a,isOpen:i,theming:l,transition:s,onClose:c})=>{const u=ls(s,"item");return e("div",{...fs({onKeyDown:({key:e})=>{if(e===_s.ESC)ss(c,{key:e,reason:Ss.CANCEL})},onBlur:e=>{i&&!e.currentTarget.contains(e.relatedTarget)&&ss(c,{reason:Ss.BLUR})}},r),className:ps({block:"szh-menu-container",modifiers:o(()=>({theme:l,itemTransition:u}),[l,u]),className:t}),style:{position:"absolute",...r?.style},ref:n,children:a})},Es=()=>{let e,t=0;return{toggle:e=>{e?t++:t--,t=Math.max(t,0)},on:(n,r,a)=>{t?e||(e=setTimeout(()=>{e=0,r()},n)):a?.()},off:()=>{e&&(clearTimeout(e),e=0)}}},Fs=(e,t)=>Math.round(e)===t?e:t,As=(e,t,n,r)=>{const a=(e=>{const t=e.getBoundingClientRect();return t.width=Fs(t.width,e.offsetWidth),t.height=Fs(t.height,e.offsetHeight),t})(t),o=e.getBoundingClientRect(),i=n===window?{left:0,top:0,right:document.documentElement.clientWidth,bottom:window.innerHeight}:n.getBoundingClientRect(),l=(e=>{if("string"!=typeof e)return{top:0,right:0,bottom:0,left:0};const t=e.trim().split(/\s+/,4).map(parseFloat),n=isNaN(t[0])?0:t[0],r=isNaN(t[1])?n:t[1];return{top:n,right:r,bottom:isNaN(t[2])?n:t[2],left:isNaN(t[3])?r:t[3]}})(r),s=e=>e+o.left-i.left-l.left,c=e=>e+o.left+a.width-i.right+l.right,u=e=>e+o.top-i.top-l.top,f=e=>e+o.top+a.height-i.bottom+l.bottom;return{menuRect:a,containerRect:o,getLeftOverflow:s,getRightOverflow:c,getTopOverflow:u,getBottomOverflow:f,confineHorizontally:e=>{let t=s(e);if(t<0)e-=t;else{const n=c(e);n>0&&(t=s(e-=n),t<0&&(e-=t))}return e},confineVertically:e=>{let t=u(e);if(t<0)e-=t;else{const n=f(e);n>0&&(t=u(e-=n),t<0&&(e-=t))}return e}}},Is=({anchorRect:e,containerRect:t,menuRect:n,placeLeftorRightY:r,placeLeftX:a,placeRightX:o,getLeftOverflow:i,getRightOverflow:l,confineHorizontally:s,confineVertically:c,arrowRef:u,arrow:f,direction:d,position:h})=>{let m,p,g,v=d,b=r;"initial"!==h&&(b=c(b),"anchor"===h&&(b=Math.min(b,e.bottom-t.top),b=Math.max(b,e.top-t.top-n.height))),"left"===v?(m=a,"initial"!==h&&(p=i(m),p<0&&(g=l(o),(g<=0||-p>g)&&(m=o,v="right")))):(m=o,"initial"!==h&&(g=l(m),g>0&&(p=i(a),(p>=0||-p<g)&&(m=a,v="left")))),"auto"===h&&(m=s(m));const y=f?(({arrowRef:e,menuY:t,anchorRect:n,containerRect:r,menuRect:a})=>{let o=n.top-r.top-t+n.height/2;const i=1.25*e.current.offsetHeight;return o=Math.max(i,o),o=Math.min(o,a.height-i),o})({menuY:b,arrowRef:u,anchorRect:e,containerRect:t,menuRect:n}):void 0;return{arrowY:y,x:m,y:b,computedDirection:v}},Ds=({anchorRect:e,containerRect:t,menuRect:n,placeToporBottomX:r,placeTopY:a,placeBottomY:o,getTopOverflow:i,getBottomOverflow:l,confineHorizontally:s,confineVertically:c,arrowRef:u,arrow:f,direction:d,position:h})=>{let m,p,g,v="top"===d?"top":"bottom",b=r;"initial"!==h&&(b=s(b),"anchor"===h&&(b=Math.min(b,e.right-t.left),b=Math.max(b,e.left-t.left-n.width))),"top"===v?(m=a,"initial"!==h&&(p=i(m),p<0&&(g=l(o),(g<=0||-p>g)&&(m=o,v="bottom")))):(m=o,"initial"!==h&&(g=l(m),g>0&&(p=i(a),(p>=0||-p<g)&&(m=a,v="top")))),"auto"===h&&(m=c(m));const y=f?(({arrowRef:e,menuX:t,anchorRect:n,containerRect:r,menuRect:a})=>{let o=n.left-r.left-t+n.width/2;const i=1.25*e.current.offsetWidth;return o=Math.max(i,o),o=Math.min(o,a.width-i),o})({menuX:b,arrowRef:u,anchorRect:e,containerRect:t,menuRect:n}):void 0;return{arrowX:y,x:b,y:m,computedDirection:v}},Bs="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement?f:d;function Ls(e,t){"function"==typeof e?e(t):e.current=t}const $s=(e,t)=>o(()=>e?t?n=>{Ls(e,n),Ls(t,n)}:e:t,[e,t]),zs=({ariaLabel:n,menuClassName:r,menuStyle:a,arrow:i,arrowProps:l={},anchorPoint:f,anchorRef:p,containerRef:g,containerProps:v,externalRef:b,parentScrollingRef:y,align:w="start",direction:x="bottom",position:k="auto",overflow:_="visible",setDownOverflow:N,repositionFlag:M,captureFocus:T=!0,state:C,endTransition:j,isDisabled:O,menuItemFocus:R,gap:P=0,shift:E=0,children:F,onClose:A,focusProps:I,...D})=>{const[B,L]=s({x:-9999,y:-9999}),[$,z]=s({}),[V,H]=s(),[W,U]=s(x),[J]=s(Es),[Q,q]=h(e=>e+1,1),{transition:X,boundingBoxRef:Y,boundingBoxPadding:K,rootMenuRef:Z,rootAnchorRef:G,scrollNodesRef:ee,reposition:te,viewScroll:ne,submenuCloseDelay:re}=m(ks),{submenuCtx:ae,reposSubmenu:oe=M}=m(ys),ie=c(),le=c(),se=c(!1),{hoverItem:ce,dispatch:ue,updateItems:fe}=(e=>{const[t,n]=s(),r=c({items:[],hoverIndex:-1,sorted:!1}).current,a=u((t,a)=>{const{items:o}=r;if(t)if(a)o.push(t);else{const r=o.indexOf(t);r>-1&&(o.splice(r,1),t.contains(document.activeElement)&&(e.current.focus(Os),n()))}else r.items=[];r.hoverIndex=-1,r.sorted=!1},[r,e]),o=u((t,a,o)=>{const{items:i,hoverIndex:l}=r,s=()=>{if(r.sorted)return;const t=e.current.querySelectorAll(".szh-menu__item");i.sort((e,n)=>ms(t,e)-ms(t,n)),r.sorted=!0};let c,u=-1;switch(t){case Ns.RESET:break;case Ns.SET:c=a;break;case Ns.UNSET:c=e=>e===a?void 0:e;break;case Ns.FIRST:s(),u=0,c=i[u];break;case Ns.LAST:s(),u=i.length-1,c=i[u];break;case Ns.SET_INDEX:s(),u=o,c=i[u];break;case Ns.INCREASE:s(),u=l,u<0&&(u=i.indexOf(a)),u++,u>=i.length&&(u=0),c=i[u];break;case Ns.DECREASE:s(),u=l,u<0&&(u=i.indexOf(a)),u--,u<0&&(u=i.length-1),c=i[u];break;default:if("production"!==process.env.NODE_ENV)throw new Error(`[React-Menu] Unknown hover action type: ${t}`)}c||(u=-1),n(c),r.hoverIndex=u},[e,r]);return{hoverItem:t,dispatch:o,updateItems:a}})(ie),de=os(C),he=ls(X,"open"),me=ls(X,"close"),pe=ee.current,ge=u(e=>{const t=ie.current,n=g.current;if(!t||!n)return;const r=p?p.current?.getBoundingClientRect():f?{left:f.x,right:f.x,top:f.y,bottom:f.y,width:0,height:0}:null;if(!r)return void("production"!==process.env.NODE_ENV&&console.warn("[React-Menu] Menu might not be positioned properly as one of the anchorRef or anchorPoint prop should be provided. If `anchorRef` is provided, the anchor must be mounted before menu is open."));pe.menu||(pe.menu=(Y?Y.current:ds(Z.current))||window);const a=As(n,t,pe.menu,K);let{arrowX:o,arrowY:l,x:s,y:c,computedDirection:u}=(({arrow:e,align:t,direction:n,gap:r,shift:a,position:o,anchorRect:i,arrowRef:l,positionHelpers:s})=>{const{menuRect:c,containerRect:u}=s,f="left"===n||"right"===n;let d=f?r:a,h=f?a:r;if(e){const e=l.current;f?d+=e.offsetWidth:h+=e.offsetHeight}const m=i.left-u.left-c.width-d,p=i.right-u.left+d,g=i.top-u.top-c.height-h,v=i.bottom-u.top+h;let b,y;"end"===t?(b=i.right-u.left-c.width,y=i.bottom-u.top-c.height):"center"===t?(b=i.left-u.left-(c.width-i.width)/2,y=i.top-u.top-(c.height-i.height)/2):(b=i.left-u.left,y=i.top-u.top),b+=d,y+=h;const w={...s,anchorRect:i,placeLeftX:m,placeRightX:p,placeLeftorRightY:y,placeTopY:g,placeBottomY:v,placeToporBottomX:b,arrowRef:l,arrow:e,direction:n,position:o};switch(n){case"left":case"right":return Is(w);default:return Ds(w)}})({arrow:i,align:w,direction:x,gap:P,shift:E,position:k,anchorRect:r,arrowRef:le,positionHelpers:a});const{menuRect:d}=a,h=d.height;if(!e&&"visible"!==_){const{getTopOverflow:e,getBottomOverflow:t}=a;let n,r;const o=t(c);if(o>0)n=h-o,r=o;else{const t=e(c);t<0&&(n=h+t,r=0-t,n>=0&&(c-=t))}n>=0&&H({height:n,overflowAmt:r})}i&&z({x:o,y:l}),L({x:s,y:c}),U(u)},[i,w,K,x,P,E,k,_,f,p,g,Y,Z,pe]);Bs(()=>{de&&(ge(),se.current&&q()),se.current=de},[de,ge,oe]),Bs(()=>{V&&!N&&(ie.current.scrollTop=0)},[V,N]),Bs(()=>fe,[fe]),d(()=>{let{menu:e}=pe;if(!de||!e)return;if(e=e.addEventListener?e:window,!pe.anchors){pe.anchors=[];let t=ds(G&&G.current);for(;t&&t!==e;)pe.anchors.push(t),t=ds(t)}let t=ne;if(pe.anchors.length&&"initial"===t&&(t="auto"),"initial"===t)return;const n=()=>{"auto"===t?is(()=>ge(!0)):ss(A,{reason:Ss.SCROLL})},r=pe.anchors.concat("initial"!==ne?e:[]);return r.forEach(e=>e.addEventListener("scroll",n)),()=>r.forEach(e=>e.removeEventListener("scroll",n))},[G,pe,de,A,ne,ge]);const ve=!!V&&V.overflowAmt>0;d(()=>{if(ve||!de||!y)return;const e=()=>is(ge),t=y.current;return t.addEventListener("scroll",e),()=>t.removeEventListener("scroll",e)},[de,ve,y,ge]),d(()=>{if(!de||"function"!=typeof ResizeObserver||"initial"===te)return;const e=[],t=new ResizeObserver(t=>t.forEach(({target:t})=>{e.indexOf(t)<0?e.push(t):S(()=>{ge(),q()})})),n={box:"border-box"};t.observe(ie.current,n);const r=p?.current;return r&&t.observe(r,n),()=>t.disconnect()},[de,te,p,ge]),d(()=>{if(!de)return ue(Ns.RESET),void(me||H());const{position:e,alwaysUpdate:t}=R||{},n=()=>{e===Ms.FIRST?ue(Ns.FIRST):e===Ms.LAST?ue(Ns.LAST):e>=-1&&ue(Ns.SET_INDEX,void 0,e)};if(t)n();else if(T){const e=setTimeout(()=>{const e=ie.current;e&&!e.contains(document.activeElement)&&(e.focus(Os),n())},he?170:100);return()=>clearTimeout(e)}},[de,he,me,T,R,ue]);const be=o(()=>({isParentOpen:de,submenuCtx:J,dispatch:ue,updateItems:fe}),[de,J,ue,fe]);let ye,we;V&&(N?we=V.overflowAmt:ye=V.height);const xe=o(()=>({reposSubmenu:Q,submenuCtx:J,overflow:_,overflowAmt:we,parentMenuRef:ie,parentDir:W}),[Q,J,_,we,W]),ke=ye>=0?{maxHeight:ye,overflow:_}:void 0,_e=o(()=>({state:C,align:w,dir:W}),[C,w,W]),Ne=o(()=>({dir:W}),[W]),Se=ps({block:gs,element:"arrow",modifiers:Ne,className:l.className}),Me=t("ul",{role:"menu","aria-label":n,...hs(O),...fs({onPointerEnter:ae?.off,onPointerMove:e=>{e.stopPropagation(),J.on(re,()=>{ue(Ns.RESET),ie.current.focus(Os)})},onPointerLeave:e=>{e.target===e.currentTarget&&J.off()},onKeyDown:e=>{switch(e.key){case _s.HOME:ue(Ns.FIRST);break;case _s.END:ue(Ns.LAST);break;case _s.UP:ue(Ns.DECREASE,ce);break;case _s.DOWN:ue(Ns.INCREASE,ce);break;case _s.SPACE:return void(e.target&&-1!==e.target.className.indexOf(gs)&&e.preventDefault());default:return}e.preventDefault(),e.stopPropagation()},onAnimationEnd:()=>{"closing"===C&&H(),ss(j)}},D),ref:$s(b,ie),className:ps({block:gs,modifiers:_e,className:r}),style:{...a,...ke,margin:0,display:"closed"===C?"none":void 0,position:Cs,left:B.x,top:B.y},children:[i&&e("li",{"aria-hidden":!0,...l,className:Se,style:{display:"block",position:Cs,left:$.x,top:$.y,...l.style},ref:le}),e(ys.Provider,{value:xe,children:e(bs.Provider,{value:be,children:e(vs.Provider,{value:ce,children:ss(F,_e)})})})]});return v?e(Ps,{...v,isOpen:de,children:Me}):Me},Vs=l(function({"aria-label":t,className:n,containerProps:r,initialMounted:a,unmountOnClose:i,transition:l,transitionTimeout:s,boundingBoxRef:u,boundingBoxPadding:f,reposition:d="auto",submenuOpenDelay:h=300,submenuCloseDelay:m=150,viewScroll:p="initial",portal:g,theming:v,onItemClick:b,...y},w){const x=c(null),k=c({}),{anchorRef:_,state:N,onClose:S}=y,T=o(()=>({initialMounted:a,unmountOnClose:i,transition:l,transitionTimeout:s,boundingBoxRef:u,boundingBoxPadding:f,rootMenuRef:x,rootAnchorRef:_,scrollNodesRef:k,reposition:d,viewScroll:p,submenuOpenDelay:h,submenuCloseDelay:m}),[a,i,l,s,_,u,f,d,p,h,m]),C=o(()=>({handleClick(e,t){e.stopPropagation||ss(b,e);let n=e.keepOpen;void 0===n&&(n=t&&e.key===_s.SPACE),n||ss(S,{value:e.value,key:e.key,reason:Ss.CLICK})},handleClose(e){ss(S,{key:e,reason:Ss.CLICK})}}),[b,S]);if(!N)return null;const j=e(ks.Provider,{value:T,children:e(ws.Provider,{value:C,children:e(zs,{...y,ariaLabel:t||"Menu",externalRef:w,containerRef:x,containerProps:{className:n,containerRef:x,containerProps:r,theming:v,transition:l,onClose:S}})})});return!0===g&&"undefined"!=typeof document?M(j,document.body):g?g.target?M(j,g.target):g.stablePosition?null:j:j}),Hs=["preEnter","entering","entered","preExit","exiting","exited","unmounted"],Ws=e=>({_s:e,status:Hs[e],isEnter:e<3,isMounted:6!==e,isResolved:2===e||e>4}),Us=e=>e?6:5,Js=(e,t,n,r,a)=>{clearTimeout(r.current);const o=Ws(e);t(o),n.current=o,a&&a({current:o})},Qs=({enter:e=!0,exit:t=!0,preEnter:n,preExit:r,timeout:a,initialEntered:o,mountOnEnter:i,unmountOnExit:l,onStateChange:f}={})=>{const[d,h]=s(()=>Ws(o?2:Us(i))),m=c(d),p=c(),[g,v]=(e=>"object"==typeof e?[e.enter,e.exit]:[e,e])(a),b=u(()=>{const e=((e,t)=>{switch(e){case 1:case 0:return 2;case 4:case 3:return Us(t)}})(m.current._s,l);e&&Js(e,h,m,p,f)},[f,l]);return[d,u(a=>{const o=e=>{switch(Js(e,h,m,p,f),e){case 1:g>=0&&(p.current=setTimeout(b,g));break;case 4:v>=0&&(p.current=setTimeout(b,v));break;case 0:case 3:p.current=((e,t)=>setTimeout(()=>{isNaN(document.body.offsetTop)||e(t+1)},0))(o,e)}},i=m.current.isEnter;"boolean"!=typeof a&&(a=!i),a?!i&&o(e?n?0:1:2):i&&o(t?r?3:4:Us(l))},[b,f,e,t,n,r,g,v,l]),b]},qs=({initialOpen:e,initialMounted:t,unmountOnClose:n,transition:r,transitionTimeout:a=500,onMenuChange:o}={})=>{const i=ls(r,"open"),l=ls(r,"close"),[{status:s},c,f]=Qs({initialEntered:e,mountOnEnter:!t,unmountOnExit:n,timeout:a,enter:i,exit:l,onStateChange:u(({current:{isEnter:e,isResolved:t}})=>{!o||e&&i&&t||!e&&l&&t||o({open:e})},[o,i,l])});return[{state:Ts[s],endTransition:f},c]},Xs=parseInt(b)<19,Ys=l(function({"aria-label":n,captureFocus:r,initialOpen:a,menuButton:o,instanceRef:i,onMenuChange:l,...f},d){const[h,m,b]=(e=>{const[t,n]=qs(e),[r,a]=s();return[{menuItemFocus:r,...t},n,(e,t)=>{a({position:e,alwaysUpdate:t}),n(!0)}]})({...f,onMenuChange:l}),{state:y}=h,w=os(y),x=c(null),k=((e,t)=>{if("production"!==process.env.NODE_ENV&&"function"!=typeof t)throw new Error("[React-Menu] useClick/useHover requires a function in the second parameter.");const[n]=s({});return{onMouseDown:()=>{n.v=e&&"closed"!==e},onClick:e=>n.v?n.v=!1:t(!0,e)}})(y,(e,t)=>b(t.detail?void 0:Ms.FIRST)),_=u(e=>{m(!1),e.key&&x.current.focus()},[m]),N=ss(o,{open:w});if(!N||!N.type)throw new Error("Menu requires a menuButton prop.");const S={...fs({onKeyDown:e=>{switch(e.key){case _s.UP:b(Ms.LAST);break;case _s.DOWN:b(Ms.FIRST);break;default:return}e.preventDefault()},...k},N.props),ref:$s(Xs?N.ref:N.props.ref,x)};"MenuButton"===N.type[cs]&&(S.isOpen=w);const M=v(N,S);return p(i,()=>({openMenu:b,closeMenu:()=>m(!1)})),t(g,{children:[M,e(Vs,{...f,...h,"aria-label":n||("string"==typeof N.props.children?N.props.children:"Menu"),anchorRef:x,ref:d,onClose:_})]})}),Ks=(t,n)=>{const r=y(n),a=l((t,n)=>{const a=c(null);return e(r,{...t,itemRef:a,externalRef:n,isHovering:m(vs)===a.current})});return a.displayName=`WithHovering(${t})`,a},Zs=(e,t,n,r)=>{const[a,o,i]=(e=>{const[t,n]=s(!1);return d(()=>{!e&&n(!1)},[e]),[t,()=>!t&&n(!0),()=>n(!1)]})(n),{submenuCloseDelay:l}=m(ks),{isParentOpen:c,submenuCtx:u,dispatch:f,updateItems:h}=m(bs),p=()=>{!n&&!r&&f(Ns.SET,e.current)},g=()=>{!r&&f(Ns.UNSET,e.current)};return((e,t,n)=>{Bs(()=>{if("production"!==process.env.NODE_ENV&&!n)throw new Error(`[React-Menu] This menu item or submenu should be rendered under a menu: ${t.current.outerHTML}`);if(e)return;const r=t.current;return n(r,!0),()=>{n(r)}},[e,t,n])})(r,e,h),d(()=>{n&&c&&t.current&&t.current.focus()},[t,n,c]),{mouseOver:a,setHover:p,onBlur:e=>{n&&!e.currentTarget.contains(e.relatedTarget)&&g()},onPointerMove:e=>{r||(e.stopPropagation(),o(),u.on(l,p,p))},onPointerLeave:(e,t)=>{i(),u.off(),!t&&g()}}},Gs=Ks("MenuItem",function({className:t,value:n,href:r,type:a,checked:i,disabled:l,children:s,onClick:c,isHovering:u,itemRef:f,externalRef:d,...h}){const p=!!l,{mouseOver:g,setHover:v,...b}=Zs(f,f,u,p),y=m(ws),w=m(xs),x="radio"===a,k="checkbox"===a,_=!(!r||p||x||k),N=x?w.value===n:!!k&&!!i,S=e=>{if(p)return e.stopPropagation(),void e.preventDefault();const t={value:n,syntheticEvent:e};void 0!==e.key&&(t.key=e.key),k&&(t.checked=!N),x&&(t.name=w.name),ss(c,t),x&&ss(w.onRadioChange,t),y.handleClick(t,k||x)},M=o(()=>({type:a,disabled:p,hover:g||u,checked:N,anchor:_}),[a,p,g,u,N,_]),T=fs({...b,onPointerDown:v,onKeyDown:e=>{if(u)switch(e.key){case _s.ENTER:e.preventDefault();case _s.SPACE:_?f.current.click():S(e)}},onClick:S},h),C={role:x?"menuitemradio":k?"menuitemcheckbox":"menuitem","aria-checked":x||k?N:void 0,...hs(p,u),...T,ref:$s(d,f),className:ps({block:gs,element:"item",modifiers:M,className:t}),children:o(()=>ss(s,M),[s,M])};return e("li",_?{role:js,children:e("a",{href:r,...C})}:{...C})}),ec=y(l(function({className:t,...n},r){return e("li",{role:js,...n,ref:r,className:ps({block:gs,element:"header",className:t})})}));var tc=r["undefined"!=typeof document&&void 0!==document.createElement?"useLayoutEffect":"useEffect"];function nc(){}function rc(e,t,n){void 0===n&&(n={});var r=lc(n.polyfill),a=(e=>{var t=c(e);return d(()=>{t.current=e}),t})(t);return tc(()=>{function t(e,t){n||a.current(e,t)}var n=0,o=e&&"current"in e?e.current:e;return o?(r.subscribe(o,t),()=>{n=1,r.unsubscribe(o,t)}):nc},[e,r,a]),r.observer}var ac,oc,ic,lc=e=>ac||(ac=function(e){var t=0,n=[],r=new Map,a=new(e||window.ResizeObserver)((e,a)=>{n=n.concat(e),t||window.requestAnimationFrame(function(){for(var e=new Set,o=function(t){if(e.has(n[t].target))return"continue";e.add(n[t].target);var o=r.get(n[t].target);null==o||o.forEach(e=>e(n[t],a))},i=0;i<n.length;i++)o(i);n=[],t=0}),t=1});return{observer:a,subscribe(e,t){var n;a.observe(e);var o=null!==(n=r.get(e))&&void 0!==n?n:[];o.push(t),r.set(e,o)},unsubscribe(e,t){var n,o=null!==(n=r.get(e))&&void 0!==n?n:[];if(1===o.length)return a.unobserve(e),void r.delete(e);var i=o.indexOf(t);-1!==i&&o.splice(i,1),r.set(e,o)}}}(e));function sc(){if(ic)return oc;ic=1;var e=/^\s+|\s+$/g,t=/^[-+]0x[0-9a-f]+$/i,n=/^0b[01]+$/i,r=/^0o[0-7]+$/i,a=parseInt,o="object"==typeof C&&C&&C.Object===Object&&C,i="object"==typeof self&&self&&self.Object===Object&&self,l=o||i||Function("return this")(),s=Object.prototype.toString,c=Math.max,u=Math.min,f=function(){return l.Date.now()};function d(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function h(o){if("number"==typeof o)return o;if(function(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&"[object Symbol]"==s.call(e)}(o))return NaN;if(d(o)){var i="function"==typeof o.valueOf?o.valueOf():o;o=d(i)?i+"":i}if("string"!=typeof o)return 0===o?o:+o;o=o.replace(e,"");var l=n.test(o);return l||r.test(o)?a(o.slice(2),l?2:8):t.test(o)?NaN:+o}return oc=function(e,t,n){var r,a,o,i,l,s,m=0,p=!1,g=!1,v=!0;if("function"!=typeof e)throw new TypeError("Expected a function");function b(t){var n=r,o=a;return r=a=void 0,m=t,i=e.apply(o,n)}function y(e){var n=e-s;return void 0===s||n>=t||n<0||g&&e-m>=o}function w(){var e=f();if(y(e))return x(e);l=setTimeout(w,function(e){var n=t-(e-s);return g?u(n,o-(e-m)):n}(e))}function x(e){return l=void 0,v&&r?b(e):(r=a=void 0,i)}function k(){var e=f(),n=y(e);if(r=arguments,a=this,s=e,n){if(void 0===l)return function(e){return m=e,l=setTimeout(w,t),p?b(e):i}(s);if(g)return l=setTimeout(w,t),b(s)}return void 0===l&&(l=setTimeout(w,t)),i}return t=h(t)||0,d(n)&&(p=!!n.leading,o=(g="maxWait"in n)?c(h(n.maxWait)||0,t):o,v="trailing"in n?!!n.trailing:v),k.cancel=function(){void 0!==l&&clearTimeout(l),m=0,r=s=a=l=void 0},k.flush=function(){return void 0===l?i:x(f())},k},oc}var cc=j(sc()),uc="canvas-module_canvas__Iiaz4",fc="canvas-module_textCanvas__eFxM4",dc="Highlight-module_highlight__1VV-X";function hc(t){const{canvasRef:n,barHeight:a,xyToHighlightData:o,zoom:i}=t,[l,s]=r.useState({height:"0px",visibility:"hidden"}),c=r.useRef(null),u=r.useRef(null),f=r.useRef(null);r.useEffect(()=>{s({height:"0px",visibility:"hidden"})},[i]);const d=e=>{const t=c.current;if(!t)return void s(e);const n=f.current;n&&n.left===e.left&&n.top===e.top&&n.width===e.width&&n.visibility===e.visibility||(f.current=e,t.style.visibility=String(e.visibility||""),void 0!==e.left&&(t.style.left=String(e.left)),void 0!==e.top&&(t.style.top=String(e.top)),void 0!==e.width&&(t.style.width=String(e.width)),void 0!==e.height&&(t.style.height=String(e.height)))},h=e=>{u.current&&cancelAnimationFrame(u.current);const t=e.offsetX,n=e.offsetY;u.current=requestAnimationFrame(()=>{const e=o(t,n);if(e.isJust){const t=e.value;d({visibility:"visible",height:`${a}px`,...t})}else m()})},m=()=>{d({...f.current||{},visibility:"hidden"})};return r.useEffect(()=>{const e=n.current;return e?(e.addEventListener("mousemove",h),e.addEventListener("mouseout",m),()=>{e.removeEventListener("mousemove",h),e.removeEventListener("mouseout",m),u.current&&cancelAnimationFrame(u.current)}):()=>{}},[n.current,h,m]),e("div",{ref:c,className:dc,style:l,"data-testid":"flamegraph-highlight"})}var mc="ContextMenuHighlight-module_highlightContextMenu__WI1nK";const pc={height:"0px",visibility:"hidden"};function gc(t){const{node:n,barHeight:a}=t,[o,i]=r.useState(pc);return r.useEffect(()=>{n.match({Nothing:()=>i(pc),Just:e=>i({visibility:"visible",height:`${a}px`,...e})})},[n]),e("div",{className:mc,style:o,"data-testid":"flamegraph-highlight-contextmenu"})}const vc={name:"Default",goodColor:Do.rgb(0,170,0),neutralColor:Do.rgb(148,142,142),badColor:Do.rgb(200,0,0),colors:[Do.hsl(24,69,60),Do.hsl(34,65,65),Do.hsl(194,52,61),Do.hsl(163,45,55),Do.hsl(211,48,60),Do.hsl(246,40,65),Do.hsl(305,63,79),Do.hsl(47,100,73),Do.rgb(183,219,171),Do.rgb(244,213,152),Do.rgb(78,146,249),Do.rgb(249,186,143),Do.rgb(242,145,145),Do.rgb(130,181,216),Do.rgb(229,168,226),Do.rgb(174,162,224),Do.rgb(154,196,138),Do.rgb(242,201,109),Do.rgb(101,197,219),Do.rgb(249,147,78),Do.rgb(234,100,96),Do.rgb(81,149,206),Do.rgb(214,131,206),Do.rgb(128,110,183)]},bc={...vc,name:"Color Blind",goodColor:Do.rgb(26,133,255),neutralColor:Do.rgb(148,142,142),badColor:Do.rgb(220,50,32)};function yc(){return t("svg",{id:"Layer_1",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 30 30",children:[e("defs",{}),e("path",{style:{fill:"#7d7d7f"},d:"M5,19.56c0,5.22,3.54,9.44,7.92,9.44h3.17c4.37,0,7.92-4.23,7.92-9.44v-7.56H5v7.56Z"}),e("path",{style:{fill:"#7d7d7f"},d:"M14,1h-.82c-4.52,0-8.18,3.73-8.18,8.33v1.67H14V1Z"}),e("path",{d:"M15.82,1h-.82V11h9v-1.67c0-4.6-3.66-8.33-8.18-8.33Z"})]})}function wc(){return t("svg",{id:"Layer_1",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 30 30",children:[e("defs",{}),e("path",{style:{fill:"#7d7d7f"},d:"M24,19.56c0,5.22-3.54,9.44-7.92,9.44h-3.17c-4.37,0-7.92-4.23-7.92-9.44v-7.56H24v7.56Z"}),e("path",{style:{fill:"#7d7d7f"},d:"M15,1h.82c4.52,0,8.18,3.73,8.18,8.33v1.67H15V1Z"}),e("path",{d:"M13.18,1h.82V11H5v-1.67c0-4.6,3.66-8.33,8.18-8.33Z"})]})}var xc={tooltip:"Tooltip-module_tooltip__NMZ65",flamegraphDiffTooltip:"Tooltip-module_flamegraphDiffTooltip__Z983o",tooltipName:"Tooltip-module_tooltipName__y4Qs3",functionName:"Tooltip-module_functionName__z9LHO",tooltipTable:"Tooltip-module_tooltipTable__ct3pq",clickInfo:"Tooltip-module_clickInfo__Utux5"};const kc={location:"Location",self:"Self",total:"Total",baseline:"Baseline",comparison:"Comparison",diff:"Diff",noItemsFound:"No items found",diffNew:"new",diffRemoved:"removed",tooltipSamples:"Samples:",tooltipUnitTitles:{objects:{percent:"% of objects in RAM",formattedValue:"Objects in RAM",total:"% of total RAM"},goroutines:{percent:"% of goroutines",formattedValue:"Goroutines",total:"% of total goroutines"},bytes:{percent:"% of RAM",formattedValue:"RAM",total:"% of total bytes"},samples:{percent:"Share of CPU",formattedValue:"CPU Time",total:"% of total CPU"},lock_nanoseconds:{percent:"% of Time spent",formattedValue:"Time",total:"% of total seconds"},lock_samples:{percent:"% of contended locks",formattedValue:"Contended locks",total:"% of total locks"},trace_samples:{percent:"% of time",formattedValue:"Samples",total:"% of total samples"},exceptions:{percent:"% of thrown exceptions",formattedValue:"Thrown exceptions",total:"% of total thrown exceptions"},unknown:{percent:"Percentage",formattedValue:"Units",total:"% of total units"}},resetView:"Reset View",collapseNodesAbove:"Collapse nodes above",copyFunctionName:"Copy function name",highlightSimilarNodes:"Highlight similar nodes",clearHighlight:"Clear highlight",openInSandwichView:"Open in sandwich view",showTextTailFirst:"Show text tail first",showTextHeadFirst:"Show text head first",headFirst:"Head first",tailFirst:"Tail first",clickToHighlightNode:"Click to highlight node in flamegraph",rightClickForMoreNodeOptions:"Right click for more node viewing options",viewTable:"Table",viewTableAndFlamegraph:"Table and Flamegraph",viewFlamegraph:"Flamegraph",viewSandwich:"Sandwich",viewGraphviz:"GraphViz",more:"More",diffLegendRemovedLabel:"(-) Removed",diffLegendAddedLabel:"Added (+)",diffLegendSelectPalette:"Select a palette",paletteDefaultName:"Default",paletteColorBlindName:"Color Blind",paletteDefaultDesc:"(green to red)",paletteColorBlindDesc:"(blue to red)",searchPlaceholder:"Search...",syncSearchBars:"Sync Search Bars",unsyncSearchBars:"Unsync Search Bars",focusOnThisFunction:"Focus on this function",tableDoubleClickToFocus:"Double-click to focus in flamegraph",tableRightClickForOptions:"Right-click for more options",collapsedLevelsSingular:"total (1 level collapsed)",collapsedLevelsPlural:"total ({n} levels collapsed)",ofTotal:"of total",clearFocus:"Clear focus",sampleCountFormat:[{value:1e15,label:"Quad"},{value:1e12,label:"Tri"},{value:1e9,label:"B"},{value:1e6,label:"M"},{value:1e3,label:"K"}]},_c={...kc,location:"位置",self:"自身",total:"总计",baseline:"基线",comparison:"对比",diff:"差异",noItemsFound:"没有找到任何条目",diffNew:"新增",diffRemoved:"移除",tooltipSamples:"样本数:",tooltipUnitTitles:{objects:{percent:"RAM 中对象占比",formattedValue:"RAM 中对象数",total:"占总 RAM 的百分比"},goroutines:{percent:"协程占比",formattedValue:"协程数量",total:"占协程总数的百分比"},bytes:{percent:"RAM 占比",formattedValue:"RAM",total:"占总字节数的百分比"},samples:{percent:"CPU 占比",formattedValue:"CPU 时间",total:"占总 CPU 的百分比"},lock_nanoseconds:{percent:"耗时占比",formattedValue:"时间",total:"占总秒数的百分比"},lock_samples:{percent:"锁竞争事件占比",formattedValue:"锁竞争事件数",total:"占锁竞争总数的百分比"},trace_samples:{percent:"时间占比",formattedValue:"样本数",total:"占样本总数的百分比"},exceptions:{percent:"异常抛出占比",formattedValue:"异常数",total:"占异常总数的百分比"},unknown:{percent:"百分比",formattedValue:"单位",total:"占单位总量的百分比"}},resetView:"重置视图",collapseNodesAbove:"收起上方节点",copyFunctionName:"复制函数名",highlightSimilarNodes:"高亮相似节点",clearHighlight:"清除高亮",openInSandwichView:"在 sandwich 视图中查看",showTextTailFirst:"显示文本尾部优先",showTextHeadFirst:"显示文本头部优先",headFirst:"从头部开始显示",tailFirst:"从尾部开始显示",clickToHighlightNode:"点击火焰图节点高亮",rightClickForMoreNodeOptions:"右键查看更多节点选项",viewTable:"表格",viewTableAndFlamegraph:"表格 + 火焰图",viewFlamegraph:"火焰图",viewSandwich:"三明治视图",viewGraphviz:"调用图 (GraphViz)",more:"更多",diffLegendRemovedLabel:"(-) 减少",diffLegendAddedLabel:"增加 (+)",diffLegendSelectPalette:"选择颜色方案",paletteDefaultName:"默认",paletteColorBlindName:"色盲",paletteDefaultDesc:"(绿色 → 红色)",paletteColorBlindDesc:"(蓝色 → 红色)",searchPlaceholder:"搜索...",syncSearchBars:"同步搜索栏",unsyncSearchBars:"取消同步搜索栏",focusOnThisFunction:"聚焦到此函数",tableDoubleClickToFocus:"双击可聚焦到火焰图",tableRightClickForOptions:"右键查看更多选项",collapsedLevelsSingular:"总计(已折叠 1 层)",collapsedLevelsPlural:"总计(已折叠 {n} 层)",ofTotal:"占总量",clearFocus:"清除聚焦",sampleCountFormat:[{value:1e12,label:"兆"},{value:1e8,label:"亿"},{value:1e4,label:"万"},{value:1e3,label:"千"}]},Nc=i(kc),Sc=Nc,Mc=({messages:t,children:n})=>{const a=r.useMemo(()=>{var e;return{...kc,...t,tooltipUnitTitles:{...kc.tooltipUnitTitles,...null!==(e=null==t?void 0:t.tooltipUnitTitles)&&void 0!==e?e:{}}}},[t]);return e(Nc.Provider,{value:a,children:n})},Tc=()=>m(Nc);function Cc(e){if(!e)return null;const t=e.replace(/,/g,"").trim();if(!t)return null;const n=Number(t);return Number.isFinite(n)?n:null}function jc(e,t){if(!e||!t)return;const n=e.trim().replace(/\u2212/g,"-");return n&&"0"!==n?n.startsWith("+")?t.badColor.rgb().string():n.startsWith("-")?t.goodColor.rgb().string():void 0:void 0}function Oc(e,t,n){return n<t?t:Math.max(t,Math.min(n,e))}function Rc(e,t,n,r){const a=window.innerWidth,o=window.innerHeight,i=Math.max(0,n||0),l=Math.max(0,r||0);let s=e+12,c=t+20;return s+i+8>a&&(s=e-i-12),c+l+8>o&&(c=t-l-20),s=Oc(s,8,a-i-8),c=Oc(c,8,o-l-8),{left:s,top:c}}function Pc({shouldShowFooter:a=!0,shouldShowTitle:o=!0,dataSourceRef:i,clickInfoSide:l,setTooltipContent:h,palette:m}){const p=c(null),g=c(null),v=c(null),b=c(null),[y,w]=r.useState({title:{text:"",diff:{text:"",color:""}},tooltipData:[]}),[x,k]=s(),_=()=>{k({visibility:"hidden"}),w({title:{text:"",diff:{text:"",color:""}},tooltipData:[]})},N=u(e=>{v.current&&cancelAnimationFrame(v.current);const t=e.clientX,n=e.clientY;v.current=requestAnimationFrame(()=>{if(!p.current)throw new Error("Missing tooltipElement");g.current={x:t,y:n},h(w,_,e);const r=p.current.clientWidth||0,a=p.current.clientHeight||0,{left:o,top:i}=Rc(t,n,r,a);k({top:i,left:o,visibility:"visible"})})},[h]);return d(()=>{const e=i.current;if(!e)return()=>{};const t=()=>{_()},n=t=>{e.contains(t.target)||_()};return e.addEventListener("mousemove",N),e.addEventListener("mouseout",_),e.addEventListener("mouseleave",t),window.addEventListener("mousemove",n,{passive:!0}),window.addEventListener("blur",t),()=>{e.removeEventListener("mousemove",N),e.removeEventListener("mouseout",_),e.removeEventListener("mouseleave",t),window.removeEventListener("mousemove",n),window.removeEventListener("blur",t),v.current&&cancelAnimationFrame(v.current)}},[i.current,N]),f(()=>{if(!p.current)return;if(!g.current)return;if(0===y.tooltipData.length)return;const{x:e,y:t}=g.current,n=p.current.getBoundingClientRect(),r=n.width,a=n.height,o=b.current;if(o&&Math.abs(o.w-r)<1&&Math.abs(o.h-a)<1)return;b.current={w:r,h:a};const{left:i,top:l}=Rc(e,t,r,a);k(e=>e&&e.left===i&&e.top===l&&"visible"===e.visibility?e:{...e||{},left:i,top:l,visibility:"visible"})},[y.tooltipData.length,y.title.text]),e("div",{"data-testid":"tooltip",className:Fl(xc.tooltip,{[xc.flamegraphDiffTooltip]:y.tooltipData.length>1}),style:{...x,textAlign:"center"},ref:p,children:y.tooltipData.length>0&&t(n,{children:[o&&e("div",{className:xc.tooltipName,"data-testid":"tooltip-title",children:y.title.text}),e("div",{className:xc.functionName,"data-testid":"tooltip-function-name",children:y.title.text}),y.title.diff.text.length>0?e(Ec,{data:y.tooltipData,diff:y.title.diff,palette:m}):e(Ec,{data:y.tooltipData,palette:m}),a&&e(Fc,{clickInfoSide:l})]})})}function Ec({data:r,diff:a,palette:o}){const i=Tc(),[l,s]=r,c="Location"!==i.location;if(!l)return null;let u;switch(l.tooltipType){case"flamegraph":u=()=>{const r=s&&function(e,t){const n=Ga(e),r=Ga(t);if(!n||!r)return"";const a=r.value-n.value;if(0===a)return"0";const o=a>0?"+":"-",i=Math.abs(a);let l;l=i>=100?i.toFixed(0):i>=10?i.toFixed(1):i.toFixed(2);const s=n.unit||r.unit;return s?`${o}${l} ${s}`:`${o}${l}`}(l.formattedValue,s.formattedValue),u=eo(r,c),f=s&&function(e,t){const n=Cc(e),r=Cc(t);if(null==n||null==r)return"";const a=r-n;return 0===a?"0":`${a>0?"+":"-"}${Math.abs(a).toLocaleString()}`}(l.samples,s.samples),d=eo(l.formattedValue,c),h=eo(null==s?void 0:s.formattedValue,c),m=null==a?void 0:a.color,p=jc(r,o),g=jc(f,o);return t(n,{children:[s&&e("thead",{children:t("tr",{children:[e("th",{}),e("th",{children:i.baseline}),e("th",{children:i.comparison}),e("th",{children:i.diff})]})}),t("tbody",{children:[t("tr",{children:[t("td",{children:[i.tooltipUnitTitles[l.units].percent,":"]}),e("td",{children:l.percent}),s&&t(n,{children:[e("td",{children:s.percent}),e("td",{style:{textAlign:"center"},children:a&&e("span",{"data-testid":"tooltip-diff",style:{color:m},children:a.text})})]})]}),t("tr",{children:[t("td",{children:[i.tooltipUnitTitles[l.units].formattedValue,":"]}),e("td",{children:d}),s&&t(n,{children:[e("td",{children:h}),e("td",{style:{textAlign:"center"},children:u&&e("span",{"data-testid":"tooltip-time-diff",style:p?{color:p}:void 0,children:u})})]})]}),t("tr",{children:[e("td",{children:i.tooltipSamples}),e("td",{children:l.samples}),s&&t(n,{children:[e("td",{children:s.samples}),e("td",{style:{textAlign:"center"},children:f&&e("span",{"data-testid":"tooltip-samples-diff",style:g?{color:g}:void 0,children:f})})]})]})]})]})};break;case"table":u=()=>t(n,{children:[e("thead",{children:t("tr",{children:[e("td",{}),t("td",{children:[i.self," (",i.tooltipUnitTitles[l.units].total,")"]}),t("td",{children:[i.total," (",i.tooltipUnitTitles[l.units].total,")"]})]})}),e("tbody",{children:t("tr",{children:[t("td",{children:[i.tooltipUnitTitles[l.units].formattedValue,":"]}),e("td",{children:l.self}),e("td",{children:l.total})]})})]});break;default:u=()=>null}return e("table",{"data-testid":"tooltip-table",className:Fl(xc.tooltipTable,{[xc[`${l.tooltipType}${s?"Diff":""}`]]:l.tooltipType}),style:{textAlign:"center",margin:"0 auto"},children:u()})}function Fc({clickInfoSide:r}){const a=Tc();let o;switch(r){case"right":o=t(n,{children:[e(yc,{}),e("span",{children:a.rightClickForMoreNodeOptions})]});break;case"left":o=t(n,{children:[e(wc,{}),e("span",{children:a.clickToHighlightNode})]});break;default:o=e(n,{})}return e("div",{"data-testid":"tooltip-footer",className:xc.clickInfo,children:o})}function Ac(t){const{format:n,canvasRef:r,xyToData:a,numTicks:o,sampleRate:i,units:l,leftTicks:s,rightTicks:c,palette:f}=t,d=Tc(),h=u((e,t,r)=>{const u=ao(o,i,l),h=a(r.offsetX,r.offsetY);let m;var p;if(h.isJust)switch(m=h.value,m.format){case"single":{const t={percent:(p=m.total/o,`${no(p)}%`),samples:"trace_samples"===l?"":Za(m.total),units:l,formattedValue:u.format(m.total,i),tooltipType:"flamegraph"};e({title:{text:m.name,diff:{text:"",color:""}},tooltipData:[t]});break}case"double":{if("single"===n)throw new Error("props format is 'single' but it has been mapped to 'double'");const t=Ic({formatter:u,sampleRate:i,totalLeft:m.totalLeft,leftTicks:s,totalRight:m.totalRight,rightTicks:c,title:m.name,units:l},f,d);e({title:t.title,tooltipData:t.tooltipData});break}default:throw new Error(`Unsupported format: '${m.format}'`)}else t()},[o,i,l,s,c,f,a,n,d]);return e(Pc,{dataSourceRef:r,clickInfoSide:"right",setTooltipContent:h,palette:f})}function Ic({formatter:e,sampleRate:t,totalLeft:n,leftTicks:r,totalRight:a,rightTicks:o,title:i,units:l},s=vc,c){var u,f;const d=o>0?a/o:0,h=no(r>0?n/r:0),m=no(d),p={percent:`${h}%`,samples:Za(n),units:l,formattedValue:e.format(n,t),tooltipType:"flamegraph"},g={percent:`${m}%`,samples:Za(a),units:l,formattedValue:e.format(a,t),tooltipType:"flamegraph"};let v=ro(h,m);Number.isFinite(v)||(v=0);let b="";v>0?b=s.badColor.rgb().string():v<0&&(b=s.goodColor.rgb().string());let y="";return 0===n&&a>0?y=null!==(u=null==c?void 0:c.diffNew)&&void 0!==u?u:"新增":0===a&&n>0?y=null!==(f=null==c?void 0:c.diffRemoved)&&void 0!==f?f:"移除":0===v?y="0%":v>0?y=`+${v.toFixed(2)}%`:v<0&&(y=`${v.toFixed(2)}%`),{title:{text:i,diff:{text:y,color:b}},tooltipData:[p,g]}}var Dc="ContextMenu-module_menu__x-AtY";function Bc(t){const[n,a]=qs({transition:!0}),[o,i]=r.useState({x:0,y:0}),{canvasRef:l}=t,[s,c]=r.useState([]),{xyToMenuItems:u,onClose:f,onOpen:d}=t;return r.useEffect(()=>{a(!1);const e=l.current;if(!e)return()=>{};const t=e=>{e.preventDefault();const t=u(e.offsetX,e.offsetY);c(t);const n=e.clientX,r=e.clientY+20;i({x:n,y:r}),a(!0),d(e.offsetX,e.offsetY)};return e.addEventListener("contextmenu",t),()=>{e.removeEventListener("contextmenu",t)}},[u]),e(Vs,{...n,className:Dc,anchorPoint:o,onClose:()=>{a(!1),f()},children:s})}var Lc="LogoLink-module_logoLink__oWRri";function $c(){return t("a",{className:Lc,href:"https://github.com/pyroscope-io/pyroscope/",target:"_blank",rel:"noreferrer",children:[t("svg",{width:"22px",height:"22px",viewBox:"0 0 1024 1024",version:"1.1",xmlns:"http://www.w3.org/2000/svg",children:[e("defs",{children:t("radialGradient",{cx:"49.4236252%",cy:"92.6627823%",fx:"49.4236252%",fy:"92.6627823%",r:"195.066755%",gradientTransform:"translate(0.494236,0.926628),scale(1.000000,0.735610),rotate(-90.000000),translate(-0.494236,-0.926628)",id:"radialGradient-1",children:[e("stop",{stopColor:"#FFB90C",offset:"0%"}),e("stop",{stopColor:"#F9243A",offset:"38.390924%"}),e("stop",{stopColor:"#F9243A",offset:"50.5405%"}),e("stop",{stopColor:"#B51424",offset:"73.98091%"}),e("stop",{stopColor:"#B51424",offset:"100%"})]})}),e("g",{id:"Artboard",stroke:"none",strokeWidth:"1",fill:"none",fillRule:"evenodd",children:e("g",{id:"fire-part",transform:"translate(148.516736, 0.000000)",fillRule:"nonzero",children:t("g",{id:"whole-thing",transform:"translate(363.983264, 495.000000) scale(-1, 1) rotate(-180.000000) translate(-363.983264, -495.000000) translate(0.483264, 0.000000)",children:[e("g",{id:"g70",transform:"translate(-0.000091, 0.685815)",fill:"url(#radialGradient-1)",children:e("path",{d:"M65.3646667,571.739321 L65.4492471,571.698868 C19.5139147,505.999969 -5.32464048,424.477859 1.04305801,336.877516 L1.04305801,336.877516 C14.0321963,158.179446 159.192462,13.7596653 338.059844,1.5917266 L338.059844,1.5917266 C419.418369,-3.93888015 495.500283,17.3823334 558.456522,57.4611191 L558.456522,57.4611191 L481.301947,162.097965 C437.516468,136.521928 399.367671,129.590556 363.486536,130.155994 L363.486536,130.155994 C234.497143,130.155994 129.556988,235.032238 129.556988,363.946998 L129.556988,363.946998 C129.556988,492.865683 234.497143,597.738003 363.486536,597.738003 L363.486536,597.738003 C492.483783,597.738003 597.427864,492.865683 597.427864,363.946998 L597.427864,363.946998 C597.41276,304.634864 581.39383,255.677522 530.630465,199.668053 L607.770843,95.1329436 C680.936847,161.576603 726.932594,257.364176 726.932594,363.946998 L726.932594,363.946998 C726.932594,458.031616 691.13483,543.75602 632.416071,608.271816 L632.416071,608.271816 L632.416071,608.275741 L533.597728,748.122808 L428.601388,617.203806 L434.703262,646.563419 C459.453008,765.59222 433.664131,889.543925 363.49439,988.853335 L363.49439,988.853335 L65.3646667,571.723019 L65.3646667,571.739321 Z",id:"path84"})}),e("g",{id:"blue",transform:"translate(191.447039, 191.331780)",children:t("g",{id:"g88",transform:"translate(-0.000063, 0.685930)",children:[e("g",{id:"g94",transform:"translate(0.177296, 0.699054)",fill:"#3EC1D3",children:e("path",{d:"M171.862466,343.697728 C77.0961324,343.697728 -0.00497405932,266.647602 -0.00497405932,171.934957 C-0.00497405932,77.2182874 77.0961324,0.168162396 171.862466,0.168162396 C266.632828,0.168162396 343.741988,77.2182874 343.741988,171.934957 C343.741988,266.647602 266.632828,343.697728 171.862466,343.697728",id:"path96"})}),e("g",{id:"g98",transform:"translate(29.362379, 172.629585)",fill:"#FFFFFF",children:e("path",{d:"M22.8397982,0 L0.671669409,0 C0.671669409,78.2496309 64.380874,141.920035 142.678189,141.920035 L142.678189,119.765407 C76.6007327,119.765407 22.8397982,66.0372141 22.8397982,0",id:"path100"})})]})})]})})})]}),e("span",{children:"Pyroscope"})]})}const zc=()=>e("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"64 64 896 896",fill:"currentColor",children:e("path",{d:"M928 160H96c-17.7 0-32 14.3-32 32v640c0 17.7 14.3 32 32 32h832c17.7 0 32-14.3 32-32V192c0-17.7-14.3-32-32-32zm-40 208H676V232h212v136zm0 224H676V432h212v160zM412 432h200v160H412V432zm200-64H412V232h200v136zm-476 64h212v160H136V432zm0-200h212v136H136V232zm0 424h212v136H136V656zm276 0h200v136H412V656zm476 136H676V656h212v136z"})}),Vc=()=>e("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"64 64 896 896",fill:"currentColor",children:e("path",{d:"M464 144H160c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V160c0-8.8-7.2-16-16-16zm-52 268H212V212h200v200zm452-268H560c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V160c0-8.8-7.2-16-16-16zm-52 268H612V212h200v200zM464 544H160c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V560c0-8.8-7.2-16-16-16zm-52 268H212V612h200v200zm452-268H560c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V560c0-8.8-7.2-16-16-16zm-52 268H612V612h200v200z"})}),Hc=()=>e("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"64 64 896 896",fill:"currentColor",children:e("path",{d:"M834.1 469.2A347.49 347.49 0 00751.2 354l-29.1-26.7a8.09 8.09 0 00-13 3.3l-13 37.3c-8.1 23.4-23 47.3-44.1 70.8-1.4 1.5-3 1.9-4.1 2-1.1.1-2.8-.1-4.3-1.5-1.4-1.2-2.1-3-2-4.8 3.7-60.2-14.3-128.1-53.7-202C555.3 171 510 123.1 453.4 89.7l-41.3-24.3c-5.4-3.2-12.3 1-12 7.3l2.2 48c1.5 32.8-2.3 61.8-11.3 85.9-11 29.5-26.8 56.9-47 81.5a295.64 295.64 0 01-47.5 46.1 352.6 352.6 0 00-100.3 121.5A347.75 347.75 0 00160 610c0 47.2 9.3 92.9 27.7 136a349.4 349.4 0 0075.5 110.9c32.4 32 70 57.2 111.9 74.7C418.5 949.8 464.5 959 512 959s93.5-9.2 136.9-27.3A348.6 348.6 0 00760.8 857c32.4-32 57.8-69.4 75.5-110.9a344.2 344.2 0 0027.7-136c0-48.8-10-96.2-29.9-140.9zM713 808.5c-53.7 53.2-125 82.4-201 82.4s-147.3-29.2-201-82.4c-53.5-53.1-83-123.5-83-198.4 0-43.5 9.8-85.2 29.1-124 18.8-37.9 46.8-71.8 80.8-97.9a349.6 349.6 0 0058.6-56.8c25-30.5 44.6-64.5 58.2-101a240 240 0 0012.1-46.5c24.1 22.2 44.3 49 61.2 80.4 33.4 62.6 48.8 118.3 45.8 165.7a74.01 74.01 0 0024.4 59.8 73.36 73.36 0 0053.4 18.8c19.7-1 37.8-9.7 51-24.4 13.3-14.9 24.8-30.1 34.4-45.6 14 17.9 25.7 37.4 35 58.4 15.9 35.8 24 73.9 24 113.1 0 74.9-29.5 145.4-83 198.4z"})}),Wc=({fill:n})=>t("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 64 64",fill:n,children:[e("g",{id:"shape_squiggle",children:e("path",{d:"M60,38.42c-4.62,0-6.97-2.64-8.86-4.75-1.81-2.03-2.86-3.08-5.13-3.08s-3.32,1.06-5.13,3.08c-1.89,2.12-4.24,4.75-8.86,4.75s-6.97-2.64-8.87-4.75c-1.81-2.03-2.86-3.08-5.14-3.08s-3.33,1.06-5.14,3.08c-1.89,2.12-4.25,4.75-8.87,4.75-1.38,0-2.5-1.12-2.5-2.5s1.12-2.5,2.5-2.5c2.28,0,3.33-1.06,5.14-3.09,1.89-2.12,4.25-4.75,8.87-4.75s6.97,2.64,8.87,4.75c1.81,2.03,2.86,3.09,5.14,3.09s3.32-1.06,5.13-3.08c1.89-2.12,4.24-4.75,8.86-4.75s6.97,2.64,8.86,4.75c1.81,2.03,2.86,3.08,5.13,3.08,1.38,0,2.5,1.12,2.5,2.5s-1.12,2.5-2.5,2.5Z"})}),t("g",{id:"Layer_4",children:[e("rect",{x:"2",y:"8",width:"60",height:"14",rx:"3.94",ry:"3.94"}),e("path",{d:"M58.06,41h-18.64c-1.58,0-3.14,.42-4.5,1.22l-6.88,4.02c-1.87,1.09-4.19,1.09-6.06,0l-6.88-4.02c-1.37-.8-2.92-1.22-4.5-1.22H5.94c-2.18,0-3.94,1.76-3.94,3.94v7.12c0,2.18,1.76,3.94,3.94,3.94H58.06c2.18,0,3.94-1.76,3.94-3.94v-7.12c0-2.18-1.76-3.94-3.94-3.94Z"})]})]}),Uc=()=>t("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 64 64",children:[e("g",{id:"ab_shape",children:t("g",{children:[e("path",{d:"M16.71,41l-.42-2.45h-.16c-1.63,1.95-4.06,2.95-6.91,2.95-4.8,0-7.86-3.45-7.86-7.45,0-6.4,6.01-9.3,14.13-9.3v-.4c0-1.5-.84-3.2-4.38-3.2-2.48,0-4.9,.75-6.54,1.7l-1.42-4.75c1.69-.9,5.01-2.1,9.44-2.1,8.33,0,10.65,4.95,10.65,10.45v8.7c0,2.25,.11,4.4,.37,5.85h-6.91Zm-.95-11.7c-3.64,0-6.91,.9-6.91,4,0,2.1,1.37,3,3,3s3.22-1.05,3.74-2.6c.11-.35,.16-.8,.16-1.2v-3.2Z"}),e("path",{d:"M29.36,41c.11-1.79,.21-4.62,.21-7.25V6h7.7v13.46h.11c1.42-1.99,3.8-3.28,7.06-3.28,5.85,0,9.7,5.01,9.65,12.16,0,8.69-5.22,13.16-10.81,13.16-2.74,0-5.22-.99-6.91-3.72h-.11l-.37,3.23h-6.54Zm7.91-9.83c0,.55,.05,.99,.16,1.39,.58,1.94,2.16,3.18,4.01,3.18,3.11,0,4.9-2.53,4.9-7,0-3.92-1.58-6.8-4.9-6.8-1.85,0-3.53,1.39-3.95,3.28-.16,.4-.21,.94-.21,1.44v4.52Z"})]})}),e("g",{id:"arrows",children:e("polygon",{points:"62 54 52 45 52 51 35 51 35 57 52 57 52 63 62 54"})})]}),Jc=()=>t("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 64 64",children:[e("g",{id:"yz_shape",children:t("g",{children:[e("path",{d:"M22.75,13l3.43,12.39c.42,1.47,.84,3.2,1.16,4.52h.11c.32-1.32,.69-3.05,1-4.47l2.9-12.44h8.01l-5.8,17.16c-2.95,8.33-5.17,12.54-8.07,15.23-2.58,2.39-5.43,3.3-7.17,3.55l-1.85-6.3c1.11-.25,2.32-.76,3.48-1.52,1.16-.71,2.32-1.88,2.95-3.05,.26-.41,.42-.76,.42-1.12,0-.31-.05-.66-.26-1.17L14.32,13h8.43Z"}),e("path",{d:"M41.62,33.46l7.59-10.16c1.27-1.57,2.37-2.95,3.58-4.27v-.15h-10.33v-5.89h19.45l-.05,4.57-7.28,9.8c-1.21,1.57-2.48,3.15-3.69,4.42v.1h11.33v5.94h-20.61v-4.37Z"})]})}),e("g",{id:"arrows",children:e("polygon",{points:"12 51 12 45 2 54 12 63 12 57 29 57 29 51 12 51"})})]});var Qc="Header-module_flamegraphHeader__nIrXP",qc="Header-module_row__P7-2L",Xc="Header-module_flamegraphTitle__sjsvB";function Yc(r){const{format:a,units:o,toolbarVisible:i}=r,l={objects:"number of objects in RAM per function",goroutines:"number of goroutines",bytes:"amount of RAM per function",samples:"CPU time per function",lock_nanoseconds:"time spent waiting on locks per function",lock_samples:"number of contended locks per function",trace_samples:"aggregated span duration",exceptions:"number of exceptions thrown",unknown:""},s=i&&"single"===a?e("div",{className:`${qc} ${Xc}`,role:"heading","aria-level":2,children:l[o]&&t(n,{children:["Frame width represents ",l[o]]})}):null;return s?e("div",{className:Qc,children:e("div",{children:s})}):null}var Kc="FlamegraphBreadcrumb-module_bar__v8uhn",Zc="FlamegraphBreadcrumb-module_chip__pdv1k",Gc="FlamegraphBreadcrumb-module_focusTooltip__nX30y",eu="FlamegraphBreadcrumb-module_separator__Zj-rC",tu="FlamegraphBreadcrumb-module_chipSeparator__S-Gld",nu="FlamegraphBreadcrumb-module_unitLabel__bjHEA",ru="FlamegraphBreadcrumb-module_focusIcon__aJBb6",au="FlamegraphBreadcrumb-module_ofTotal__kk4dt",ou="FlamegraphBreadcrumb-module_clearBtn__spimK";function iu(r){const{totalValueText:a,totalSamplesText:o,samplesLabel:i,unitLabel:l,hasFocus:s,focusPercent:c,focusLabel:u,ofTotalPlacement:f="after",ofTotalLabel:d,clearFocusLabel:h,onClearFocus:m}=r,p=u&&u.trim().length>0?u:void 0;return t("div",{className:Kc,"aria-live":"polite",children:[t("span",{className:Zc,children:[e("span",{children:a}),e("span",{className:eu,children:"|"}),t("span",{children:[o," ",i]}),t("span",{className:nu,children:["(",l,")"]})]}),s&&void 0!==c&&t(n,{children:[e("span",{className:tu,children:">"}),t("span",{className:`${Zc} ${Gc}`,"data-tooltip":p,children:[e("span",{className:ru,"aria-hidden":"true",children:t("svg",{viewBox:"0 0 24 24",width:"14",height:"14",fill:"none",stroke:"currentColor",strokeWidth:"1.6",strokeLinecap:"round",strokeLinejoin:"round",children:[e("path",{d:"M2 12s3.5-6 10-6 10 6 10 6-3.5 6-10 6-10-6-10-6Z"}),e("circle",{cx:"12",cy:"12",r:"3.2"})]})}),t(n,"before"===f?{children:[e("span",{className:au,children:d}),t("span",{children:[c.toFixed(2),"%"]})]}:{children:[t("span",{children:[c.toFixed(2),"%"]}),e("span",{className:au,children:d})]}),e("button",{type:"button",className:ou,"aria-label":h,onClick:e=>{e.preventDefault(),e.stopPropagation(),m()},children:"×"})]})]})]})}var lu="styles-module_flamegraphPane__ejguD",su="styles-module_fitModeItem__0UBwN",cu="styles-module_sandwichItem__WYvnd",uu="styles-module_flamegraphFrame__9ZW-z";function fu(n){const a=r.useRef(null),i=r.useRef(null),l=c(),s=c(),f=c(null),h=c(null),m=c(null),p=c({rect:!1,text:!1}),g=Tc(),v=c({lastWidth:0,lastHeight:0}),b="undefined"!=typeof window&&"undefined"!=typeof OffscreenCanvas&&"transferControlToOffscreen"in HTMLCanvasElement.prototype,y=o(()=>({collapsedLevelsSingular:g.collapsedLevelsSingular,collapsedLevelsPlural:g.collapsedLevelsPlural,isZh:"Location"!==g.location}),[g.collapsedLevelsSingular,g.collapsedLevelsPlural,g.location]),w=u(e=>({name:e.name,goodColor:e.goodColor.rgb().array(),neutralColor:e.neutralColor.rgb().array(),badColor:e.badColor.rgb().array(),colors:e.colors.map(e=>e.rgb().array())}),[]),[x,k]=r.useState(Aa.nothing()),{flamebearer:_,focusedNode:N,fitMode:S,updateFitMode:M,highlightQuery:T,zoom:C,toolbarVisible:j,headerVisible:O=!0,disableClick:R=!1,showSingleLevel:P=!1,showCredit:E,setActiveItem:F,selectedItem:A,updateView:I,enableSandwichView:D=!0,breadcrumb:B}=n,{onZoom:L,onReset:$,isDirty:z,onFocusOnNode:V}=n,{"data-testid":H}=n,{palette:W,setPalette:U}=n,J=u(cc(()=>{Z(),G()},50),[]);d(()=>{if(!b)return()=>{};const e=function(){const e=new URL(import.meta.url),t=e.pathname,n=t.includes("/src/");if(t.includes("/dist/"),t.includes("/node_modules/.vite/deps/")){const t=new URL("../../@kylincloud/flamegraph/dist/flamegraphRenderWorker.js",e);return new Worker(t,{type:"module"})}const r=n?new URL("./flamegraphRenderWorker.ts",e):new URL("./flamegraphRenderWorker.js",e);return new Worker(r,{type:"module"})}();return f.current=e,setTimeout(()=>{Z(),G()},0),()=>{e.terminate(),f.current=null,h.current=null,m.current=null,p.current={rect:!1,text:!1}}},[b]),rc(a,()=>{if(l){if(a.current){const e=a.current.clientWidth,t=a.current.clientHeight,n=v.current;if(!(Math.abs(e-n.lastWidth)>=2))return;n.lastWidth=e,n.lastHeight=t}J()}});const Q=(e,t)=>ne().xyToBar(e,t).map(e=>({left:te().offsetLeft+e.x,top:te().offsetTop+e.y,width:e.width})),q=u((n,r)=>{const a=z(),o=ne().xyToBar(n,r),i=o.isJust?o.value.name:"";return[t(Gs,{disabled:!a,onClick:$,children:[e(ca,{icon:Wl.faRedo}),g.resetView]},"reset"),(()=>{const n=o.mapOrElse(()=>!1,()=>!0),r=o.mapOrElse(()=>()=>{},e=>V.bind(null,e.i,e.j));return t(Gs,{disabled:!n,onClick:r,children:[e(ca,{icon:as.faCompressAlt}),g.collapseNodesAbove]},"focus")})(),t(Gs,{onClick:()=>{navigator.clipboard&&navigator.clipboard.writeText(i)},children:[e(ca,{icon:ql.faCopy}),g.copyFunctionName]},"copy"),(()=>{const n=A.isJust&&A.value===i?g.clearHighlight:g.highlightSimilarNodes;return t(Gs,{onClick:()=>{F({name:i})},children:[e(ca,{icon:Gl.faHighlighter}),n]},"highlight-similar-nodes")})(),(()=>{if(!I||!D)return null;return t(Gs,{className:cu,onClick:()=>{I("sandwich"),F({name:i})},children:[e(Wc,{fill:"black"}),g.openInSandwichView]},"open-in-sandwich-view")})(),(()=>{const n=S===uo;return t(Gs,{className:su,onClick:()=>{M(n?co:uo)},children:[e(n?Jc:Uc,{}),n?g.showTextTailFirst:g.showTextHeadFirst]},"fit-mode")})()].filter(Boolean)},[l,A,S,z,$,V,F,I,g,D]),X=()=>{if(a.current){const e=new Pl(_,a.current,N,S,T,C,W,y);l.current=e}if(i.current){const e=new Pl(_,i.current,N,S,T,C,W,y);s.current=e}},Y=u(()=>{if(!b||!f.current)return!1;const e=f.current;if(a.current&&!h.current)try{const t=a.current.transferControlToOffscreen();h.current=t,e.postMessage({type:"init",payload:{kind:"rect",canvas:t}},[t]),p.current.rect=!0}catch(e){}if(i.current&&!m.current)try{const t=i.current.transferControlToOffscreen();m.current=t,e.postMessage({type:"init",payload:{kind:"text",canvas:t}},[t]),p.current.text=!0}catch(e){}return!0},[b]);r.useEffect(()=>{X(),Z(),G()},[W,y]),r.useEffect(()=>{X(),Z(),G()},[a.current,_,N,S,C]),r.useEffect(()=>{X(),Z(),G()},[T]);const K=(e,t)=>{if(!b)return!1;if(!f.current)return!0;if(!Y())return!0;const n="rect"===e?a.current:i.current,r=(null==n?void 0:n.clientWidth)||(null==n?void 0:n.width)||0,o={kind:e,flamebearer:_,focusedNode:N.isJust?N.value:null,fitMode:S,highlightQuery:T,zoom:C.isJust?C.value:null,palette:w(W),messages:y,renderRects:t.renderRects,renderText:t.renderText,width:r,devicePixelRatio:"undefined"!=typeof window&&window.devicePixelRatio||1};return f.current.postMessage({type:"render",payload:o}),!0},Z=()=>{var e,t,n;K("rect",{renderText:!1})||(null===(e=null==a?void 0:a.current)||void 0===e||e.setAttribute("data-state","rendering"),null===(t=null==l?void 0:l.current)||void 0===t||t.render({renderText:!1}),null===(n=null==a?void 0:a.current)||void 0===n||n.setAttribute("data-state","rendered"))},G=()=>{var e,t,n;K("text",{renderRects:!1})||(null===(e=null==i?void 0:i.current)||void 0===e||e.setAttribute("data-state","rendering"),null===(t=null==s?void 0:s.current)||void 0===t||t.render({renderRects:!1}),null===(n=null==i?void 0:i.current)||void 0===n||n.setAttribute("data-state","rendered"))},ee=!_||_&&_.names.length<=1,te=()=>{if(!a.current)throw new Error("Missing canvas");return a.current},ne=()=>{if(!l.current)throw new Error("Missing canvas");return l.current};return t("div",{"data-testid":"flamegraph-view",className:Fl(lu,{"vertical-orientation":"double"===_.format}),children:[t("div",{className:uu,children:[B&&e(iu,{totalValueText:B.totalValueText,totalSamplesText:B.totalSamplesText,samplesLabel:B.samplesLabel,unitLabel:B.unitLabel,hasFocus:B.hasFocus,focusPercent:B.focusPercent,focusLabel:B.focusLabel,ofTotalPlacement:B.ofTotalPlacement,ofTotalLabel:B.ofTotalLabel,clearFocusLabel:B.clearFocusLabel,onClearFocus:B.onClearFocus}),O&&e(Yc,{format:_.format,units:_.units,toolbarVisible:j}),t("div",{"data-testid":H,style:{position:"relative",opacity:ee&&!P?0:1},children:[e("canvas",{height:"0","data-testid":"flamegraph-canvas","data-highlightquery":T,className:Fl("flamegraph-canvas",uc),ref:a,onClick:R?void 0:e=>{const t=ne().xyToBar(e.nativeEvent.offsetX,e.nativeEvent.offsetY);t.match({Nothing:()=>{},Just:e=>{C.match({Nothing:()=>{L(t)},Just:n=>{e.i===n.i&&e.j===n.j?L(Aa.nothing()):L(t)}})}})}}),e("canvas",{height:"0","data-testid":"flamegraph-text-canvas",className:Fl("flamegraph-text-canvas",fc),ref:i}),l&&a&&e(hc,{barHeight:Ya,canvasRef:a,zoom:C,xyToHighlightData:Q}),l&&e(gc,{barHeight:Ya,node:x})]}),E?e($c,{}):""]}),l&&e(Ac,{format:_.format,canvasRef:a,xyToData:(e,t)=>ne().xyToBar(e,t),numTicks:_.numTicks,sampleRate:_.sampleRate,leftTicks:"double"===_.format?_.leftTicks:0,rightTicks:"double"===_.format?_.rightTicks:0,units:_.units,palette:W}),!R&&l&&a&&e(Bc,{canvasRef:a,xyToMenuItems:q,onClose:()=>{k(Aa.nothing())},onOpen:(e,t)=>{k(Q(e,t))}})]})}var du,hu={exports:{}};
|
|
13
13
|
/*!
|
|
14
14
|
Copyright (c) 2018 Jed Watson.
|
|
15
15
|
Licensed under the MIT License (MIT), see
|
|
16
16
|
http://jedwatson.github.io/classnames
|
|
17
|
-
*/var Al,Ol=(Bl||(Bl=1,function(e){!function(){var t={}.hasOwnProperty;function n(){for(var e="",t=0;t<arguments.length;t++){var n=arguments[t];n&&(e=r(e,a(n)))}return e}function a(e){if("string"==typeof e||"number"==typeof e)return e;if("object"!=typeof e)return"";if(Array.isArray(e))return n.apply(null,e);if(e.toString!==Object.prototype.toString&&!e.toString.toString().includes("[native code]"))return e.toString();var a="";for(var o in e)t.call(e,o)&&e[o]&&(a=r(a,o));return a}function r(e,t){return t?e?e+" "+t:e+t:e}e.exports?(n.default=n,e.exports=n):window.classNames=n}()}(Ll)),Ll.exports),zl=B(Ol),$l={};function Vl(){return Al||(Al=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="crosshairs",n=[],a="f05b",r="M288-16c17.7 0 32 14.3 32 32l0 18.3c98.1 14 175.7 91.6 189.7 189.7l18.3 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-18.3 0c-14 98.1-91.6 175.7-189.7 189.7l0 18.3c0 17.7-14.3 32-32 32s-32-14.3-32-32l0-18.3C157.9 463.7 80.3 386.1 66.3 288L48 288c-17.7 0-32-14.3-32-32s14.3-32 32-32l18.3 0C80.3 125.9 157.9 48.3 256 34.3L256 16c0-17.7 14.3-32 32-32zM131.2 288c12.7 62.7 62.1 112.1 124.8 124.8l0-12.8c0-17.7 14.3-32 32-32s32 14.3 32 32l0 12.8c62.7-12.7 112.1-62.1 124.8-124.8L432 288c-17.7 0-32-14.3-32-32s14.3-32 32-32l12.8 0C432.1 161.3 382.7 111.9 320 99.2l0 12.8c0 17.7-14.3 32-32 32s-32-14.3-32-32l0-12.8C193.3 111.9 143.9 161.3 131.2 224l12.8 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-12.8 0zM288 208a48 48 0 1 1 0 96 48 48 0 1 1 0-96z";e.definition={prefix:"fas",iconName:t,icon:[576,512,n,a,r]},e.faCrosshairs=e.definition,e.prefix="fas",e.iconName=t,e.width=576,e.height=512,e.ligatures=n,e.unicode=a,e.svgPathData=r,e.aliases=n}($l)),$l}var Hl,Wl=Vl(),Ul={};function Jl(){return Hl||(Hl=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="chevron-left",n=[9001],a="f053",r="M9.4 233.4c-12.5 12.5-12.5 32.8 0 45.3l192 192c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L77.3 256 246.6 86.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0l-192 192z";e.definition={prefix:"fas",iconName:t,icon:[320,512,n,a,r]},e.faChevronLeft=e.definition,e.prefix="fas",e.iconName=t,e.width=320,e.height=512,e.ligatures=n,e.unicode=a,e.svgPathData=r,e.aliases=n}(Ul)),Ul}var Ql,Xl=Jl(),Yl={};function Zl(){return Ql||(Ql=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="chevron-right",n=[9002],a="f054",r="M311.1 233.4c12.5 12.5 12.5 32.8 0 45.3l-192 192c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3L243.2 256 73.9 86.6c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0l192 192z";e.definition={prefix:"fas",iconName:t,icon:[320,512,n,a,r]},e.faChevronRight=e.definition,e.prefix="fas",e.iconName=t,e.width=320,e.height=512,e.ligatures=n,e.unicode=a,e.svgPathData=r,e.aliases=n}(Yl)),Yl}var ql=Zl(),Gl="Table-module_table__6A8SM",Kl="Table-module_sortable__J6kyp",es="Table-module_sortArrow__Nrncn",ts="Table-module_sortArrowUp__WmbEG",ns="Table-module_sortArrowDown__Gyue1",as="Table-module_asc__tJDI9",rs="Table-module_desc__fjVRY",os="Table-module_isRowSelected__UhIAJ",is="Table-module_isRowDisabled__sz3NJ",ls="Table-module_virtualSpacer__C1hxH",ss="Table-module_active__EShS8",cs="Table-module_loadingSpinner__SSjMK",fs="Table-module_pagination__VXgcO",us="Button-module_button__Ed1ge",ds="Button-module_noIcon__Uzjvv",hs="Button-module_noBox__mLreC",ms="Button-module_customIcon__-slpC",ps="Button-module_iconWithText__DQRkr",gs="Button-module_default__HhXlQ",vs="Button-module_outline__Flf4r",bs="Button-module_float__4marx",ys="Button-module_primary__xByv0",ws="Button-module_secondary__D0K-F",xs="Button-module_danger__5-vIq",ks="Button-module_grouped__j8KwB";const Ns=a.forwardRef(function({disabled:n=!1,kind:a="default",type:r="button",icon:o,iconNode:i,children:l,grouped:s,onClick:c,id:f,className:u,form:d,noBox:h,autoFocus:m,...p},g){return t("button",{...p,id:f,ref:g,type:r,"data-testid":p["data-testid"],disabled:n,onClick:c,form:d,autoFocus:m,"aria-label":p["aria-label"],className:zl(us,s?ks:"",Ss(a),u,h&&hs,i&&ms,!o&&!i&&ds),children:[o?e(gr,{icon:o,className:l?ps:""}):null,i,l]})});function Ss(e){switch(e){case"default":return gs;case"primary":return ys;case"secondary":return ws;case"danger":return xs;case"outline":return vs;case"float":return bs;default:throw Error(`Unsupported kind ${e}`)}}function Ts({row:t}){const{cells:n,isRowSelected:a,isRowDisabled:r,className:o,onClick:i,onDoubleClick:l,onContextMenu:s,...f}=t,u=c(Math.random()).current;return e("tr",{...f,onClick:i,onDoubleClick:l,onContextMenu:s,className:ho(o,{[os]:a,[is]:r}),children:n&&n.map(({style:t,value:n,...a},r)=>e("td",{style:t,...a,children:n},u+r))})}function Cs({sortByDirection:a,sortBy:r,updateSortParams:o,table:i,tableBodyRef:l,className:f,isLoading:h,itemsPerPage:m,virtualize:p,virtualizeRowHeight:g,virtualizeOverscan:v=6,scrollRef:b,disableSort:y}){const x=!y&&a&&r&&o,[k,N]=s(0),[S,T]=s(0),[C,_]=s(null),[M,R]=s(null),P=c(null),F=c(null);u(()=>{(null==b?void 0:b.current)&&b.current!==M&&R(b.current)},[null==b?void 0:b.current,M]),d(()=>{if(!M||!p)return()=>{};const e=()=>{P.current&&cancelAnimationFrame(P.current),P.current=requestAnimationFrame(()=>{T(M.scrollTop||0)})};return M.addEventListener("scroll",e,{passive:!0}),()=>{M.removeEventListener("scroll",e),P.current&&cancelAnimationFrame(P.current)}},[M,p]),d(()=>{if(!p||C||!(null==l?void 0:l.current))return;const e=l.current.querySelectorAll("tr[data-row]");if(!e.length)return;const t=e[0].getBoundingClientRect();t.height&&_(t.height)},[p,C,null==l?void 0:l.current,i]);const I="filled"===i.type?_s(i.bodyRows,k,m):null,j="virtual"===i.type?i.rowCount:I?I.length:0,E=g||C||26,D=!!p&&!!M&&("filled"===i.type||"virtual"===i.type)&&E>0,B=D?(()=>{const e=M.clientHeight||0,t=Math.max(0,Math.floor(S/E)-v),n=Math.min(j,Math.ceil((S+e)/E)+v),a=t*E,r=Math.max(0,(j-n)*E),o="filled"===i.type&&I?I.slice(t,n):[];return{viewportHeight:e,totalRows:j,startIndex:t,endIndex:n,topSpacer:a,bottomSpacer:r,visibleRows:o}})():null,L=!!p&&!D&&"filled"===i.type,A=L?(I||[]).slice(0,Math.max(24,4*v)):null;d(()=>{var e;"virtual"===i.type&&B&&(null===(e=i.onRangeChange)||void 0===e||e.call(i,B.startIndex,B.endIndex))},[i,null==B?void 0:B.startIndex,null==B?void 0:B.endIndex]);const O="virtual"===i.type&&B?Math.max(0,B.endIndex-B.startIndex):0,z="virtual"===i.type&&O>0?Array.from({length:O},()=>({cells:Array.from({length:i.headRow.length},()=>({value:" "}))})):[],$="virtual"===i.type&&B&&i.range&&i.range.start===B.startIndex&&i.range.end===B.endIndex;"virtual"===i.type&&$&&(F.current=i.rows);const V="virtual"===i.type?$?i.rows:F.current||z:z;return h?e("div",{className:cs}):t(n,{children:[t("table",{className:ho(Gl,{[f||""]:f}),"data-testid":"table-ui",children:[e("thead",{children:e("tr",{children:i.headRow.map(({sortable:n,label:l,name:s,...c},f)=>n&&"not-filled"!==i.type&&x?w("th",{...c,key:f,className:Kl,onClick:()=>o(s)},l,t("span",{className:ho(es,{[ss]:r===s,[as]:r===s&&"asc"===a,[rs]:r===s&&"desc"===a}),children:[e("span",{className:ts}),e("span",{className:ns})]})):e("th",{...c,children:l},f))})}),e("tbody",{ref:l,children:"not-filled"===i.type?e("tr",{className:null==i?void 0:i.bodyClassName,children:e("td",{colSpan:i.headRow.length,children:i.value})}):B?t(n,{children:[B.topSpacer>0&&e("tr",{"aria-hidden":"true",className:ls,children:e("td",{colSpan:i.headRow.length,style:{height:B.topSpacer,padding:0,border:0}})}),("virtual"===i.type?V:B.visibleRows).map((t,n)=>{var a;return e(Ts,{row:t},null!==(a=t["data-row"])&&void 0!==a?a:`row-${B.startIndex+n}`)}),B.bottomSpacer>0&&e("tr",{"aria-hidden":"true",className:ls,children:e("td",{colSpan:i.headRow.length,style:{height:B.bottomSpacer,padding:0,border:0}})})]}):L?(A||[]).map((t,n)=>{var a;return e(Ts,{row:t},null!==(a=t["data-row"])&&void 0!==a?a:`row-${n}`)}):(I||[]).map((t,n)=>{var a;return e(Ts,{row:t},null!==(a=t["data-row"])&&void 0!==a?a:`row-${n}`)})})]}),e(Ms,{bodyRows:"filled"===i.type?i.bodyRows:void 0,itemsPerPage:m,currPage:k,setCurrPage:N})]})}function _s(e,t,n){return n?e.slice(t*n,n*(t+1)):e}function Ms({itemsPerPage:n,currPage:a,setCurrPage:r,bodyRows:o}){if(!n)return null;const i=!!o&&_s(o,a+1,n).length>0,l=!!o&&_s(o,a-1,n).length>0;return t("nav",{className:fs,children:[e(Ns,{"aria-label":"Previous Page",disabled:!l,kind:"float",icon:Xl.faChevronLeft,onClick:()=>r(a-1)}),e(Ns,{disabled:!i,"aria-label":"Next Page",kind:"float",icon:ql.faChevronRight,onClick:()=>r(a+1)})]})}function Rs({numTicks:t,sampleRate:n,units:a,tableBodyRef:r,palette:o}){const i=$r(t,n,a),l=i.format(t,n),s=qi(),c=f((e,t,r)=>{var c;const f=null===(c=r.target.closest("tr"))||void 0===c?void 0:c.dataset.row;if(!f)return void t();const[u,d,...h]=f.split(";");switch(u){case"single":{const[t,r]=h,o=i.format(parseInt(t,10),n),s=i.format(parseInt(r,10),n),c=l.split(" "),f="<"===c[0]?c[1]:c[0],u=o.split(" "),m="<"===u[0]?u[1]:u[0],p=s.split(" "),g="<"===p[0]?p[1]:p[0];e({title:{text:d,diff:{text:"",color:""}},tooltipData:[{units:a,self:`${o}(${(parseFloat(m)/parseFloat(f)*100).toFixed(2)}%)`,total:`${s}(${(parseFloat(g)/parseFloat(f)*100).toFixed(2)}%)`,tooltipType:"table"}]});break}case"double":{const[t,r,l,c]=h,f=il({formatter:i,sampleRate:n,totalLeft:parseInt(t,10),leftTicks:parseInt(r,10),totalRight:parseInt(l,10),rightTicks:parseInt(c,10),title:d,units:a},o,s);e({title:f.title,tooltipData:f.tooltipData});break}}},[i,n,a,l,o,s]);return e(nl,{dataSourceRef:r,shouldShowTitle:!1,clickInfoSide:"left",setTooltipContent:c,palette:o})}function Ps(){const e=new Blob([`(${(()=>{const e=e=>e||0,t={format:"single",jStep:4,jName:3,getBarTotal:(e,t)=>e[t+1],getBarSelf:(e,t)=>e[t+2],getBarName:(e,t)=>e[t+3]},n={format:"double",jStep:7,jName:6,getBarTotal:(e,t)=>e[t+4]+e[t+1],getBarTotalLeft:(e,t)=>e[t+1],getBarTotalRght:(e,t)=>e[t+4],getBarSelf:(e,t)=>e[t+5]+e[t+2],getBarSelfLeft:(e,t)=>e[t+2],getBarSelfRght:(e,t)=>e[t+5],getBarName:(e,t)=>e[t+6]},a=e=>Math.round(1e4*e)/100,r=(e,t)=>(t-e)/e*100,o={baseRows:[],rows:[],bestNodeByName:new Map,sortBy:"total",sortByDirection:"desc",highlightQuery:"",format:"single",leftTicks:0,rightTicks:0},i=()=>{const e=o.highlightQuery.trim().toLowerCase(),t=e?o.baseRows.filter(t=>t.name.toLowerCase().includes(e)):o.baseRows.slice(),n="asc"===o.sortByDirection?1:-1;t.sort((e,t)=>{if("name"===o.sortBy)return n*e.name.localeCompare(t.name);switch(o.sortBy){case"total":case"self":{const a=e[o.sortBy]||0,r=t[o.sortBy]||0;return n*(a-r)}case"baseline":{const a=e.leftTicks>0?e.totalLeft/e.leftTicks:0,r=t.leftTicks>0?t.totalLeft/t.leftTicks:0;return n*(a-r)}case"comparison":{const a=e.rightTicks>0?e.totalRght/e.rightTicks:0,r=t.rightTicks>0?t.totalRght/t.rightTicks:0;return n*(a-r)}case"diff":{const o=e.leftTicks>0?e.totalLeft/e.leftTicks:0,i=e.rightTicks>0?e.totalRght/e.rightTicks:0,l=t.leftTicks>0?t.totalLeft/t.leftTicks:0,s=t.rightTicks>0?t.totalRght/t.rightTicks:0,c=r(a(o),a(i)),f=r(a(l),a(s));return n*(c-f)}default:return 0}}),o.rows=t},l=a=>{const{rows:r,bestNodeByName:l,format:s,leftTicks:c,rightTicks:f}=(a=>{const{names:r,levels:o,format:i}=a,l=new Map,s=new Map,c=a.leftTicks||0,f=a.rightTicks||0;if("double"===i){const t=n;for(let n=0;n<o.length;n+=1){const a=o[n];for(let o=0;o<a.length;o+=t.jStep){const i=r[t.getBarName(a,o)]||"<empty>";l.has(i)||l.set(i,{type:"double",name:i,totalLeft:0,totalRght:0,leftTicks:c,rightTicks:f});const u=l.get(i);if(!u)continue;u.totalLeft=e(u.totalLeft)+t.getBarTotalLeft(a,o),u.totalRght=e(u.totalRght)+t.getBarTotalRght(a,o);const d=t.getBarTotal(a,o),h=s.get(i);(!h||d>h.total)&&s.set(i,{i:n,j:o,total:d})}}}else{const n=t;for(let t=0;t<o.length;t+=1){const a=o[t];for(let o=0;o<a.length;o+=n.jStep){const i=r[n.getBarName(a,o)]||"<empty>";l.has(i)||l.set(i,{type:"single",name:i,self:0,total:0});const c=l.get(i);if(!c)continue;c.self=e(c.self)+n.getBarSelf(a,o),c.total=e(c.total)+n.getBarTotal(a,o);const f=n.getBarTotal(a,o),u=s.get(i);(!u||f>u.total)&&s.set(i,{i:t,j:o,total:f})}}}return{rows:Array.from(l.values()),bestNodeByName:s,format:i,leftTicks:c,rightTicks:f}})(a.flamebearer);o.baseRows=r,o.bestNodeByName=l,o.format=s,o.leftTicks=c,o.rightTicks=f,o.sortBy=a.sortBy,o.sortByDirection=a.sortByDirection,o.highlightQuery=a.highlightQuery||"",i(),self.postMessage({type:"ready",payload:{rowCount:o.rows.length}})};self.onmessage=e=>{const t=e.data;var n;if(t&&t.type)switch(t.type){case"init":l(t.payload);break;case"update":n=t.payload,o.sortBy=n.sortBy,o.sortByDirection=n.sortByDirection,o.highlightQuery=n.highlightQuery||"",i(),self.postMessage({type:"ready",payload:{rowCount:o.rows.length}});break;case"range":(e=>{const{start:t,end:n,requestId:a}=e,r=Math.max(0,t),i=Math.min(o.rows.length,n),l=o.rows.slice(r,i);self.postMessage({type:"range",payload:{rows:l,start:r,end:i,requestId:a}})})(t.payload);break;case"findNode":(e=>{const{name:t,requestId:n}=e,a=o.bestNodeByName.get(t);self.postMessage({type:"findNode",payload:{node:a?{i:a.i,j:a.j}:null,requestId:n}})})(t.payload)}}}).toString()})()`],{type:"text/javascript"});return new Worker(URL.createObjectURL(e))}var Fs="ProfilerTable-module_tableContextMenu__7Svm8",Is="ProfilerTable-module_sandwichItem__b9Ipy";const js=e=>e||0,Es="undefined"!=typeof Worker&&"undefined"!=typeof Blob&&"undefined"!=typeof URL;function Ds(e,t,n,a){const r=t;return r.type="single",r.self=js(r.self)+e.getBarSelf(n,a),r.total=js(r.total)+e.getBarTotal(n,a),r}function Bs(e,t,n,a,r,o){const i=t;return i.type="double",i.self=js(i.self)+e.getBarSelf(n,a),i.total=js(i.total)+e.getBarTotal(n,a),i.selfLeft=js(i.selfLeft)+e.getBarSelfLeft(n,a),i.selfRght=js(i.selfRght)+e.getBarSelfRght(n,a),i.selfDiff=js(i.selfDiff)+e.getBarSelfDiff(n,a),i.totalLeft=js(i.totalLeft)+e.getBarTotalLeft(n,a),i.totalRght=js(i.totalRght)+e.getBarTotalRght(n,a),i.totalDiff=js(i.totalDiff)+e.getBarTotalDiff(n,a),i.leftTicks=r,i.rightTicks=o,i}const Ls=new WeakMap;function As(e){const t=Ls.get(e);if(t)return t;const n=function(e){if(!e)return[];const{names:t,levels:n,format:a}=e,r="double"!==a?Tr:Cr,o=new Map;for(let i=0;i<n.length;i++){const l=n[i];for(let n=0;n<l.length;n+=r.jStep){const i=t[r.getBarName(l,n)];o.has(i)||o.set(i,{name:i||"<empty>",self:0,total:0});const s=o.get(i);if(!s)break;"single"===a?Ds(Tr,s,l,n):Bs(Cr,s,l,n,e.leftTicks,e.rightTicks)}}return Array.from(o.values())}(e);return Ls.set(e,n),n}function Os(e,t,n){const a=148-e/t*148,r=n.alpha(1);return{backgroundImage:`linear-gradient(${r}, ${r})`,backgroundPosition:`-${a}px 0px`,backgroundRepeat:"no-repeat"}}const zs=({flamebearer:t,sortBy:n,sortByDirection:a,fitMode:r,handleTableItemClick:o,highlightQuery:i,palette:l,selectedItem:s,messages:c,onRowContextMenu:f,onRowDoubleClick:u})=>{const{numTicks:d,maxSelf:h,sampleRate:m,spyName:p,units:g}=t,v=[...As(t)].sort((e,t)=>t.total-e.total),b="asc"===a?1:-1;let y;if("name"===n)y=v.sort((e,t)=>b*e[n].localeCompare(t[n]));else switch(n){case"total":case"self":y=v.sort((e,t)=>b*(e[n]-t[n]));break;case"baseline":y=v.sort((e,t)=>b*(e.totalLeft/e.leftTicks-t.totalLeft/t.leftTicks));break;case"comparison":y=v.sort((e,t)=>b*(e.totalRght/e.rightTicks-t.totalRght/t.rightTicks));break;case"diff":y=v.sort((e,t)=>{const n=zr(Or(e.totalLeft/e.leftTicks),Or(e.totalRght/e.rightTicks)),a=zr(Or(t.totalLeft/t.leftTicks),Or(t.totalRght/t.rightTicks));return b*(n-a)});break;default:y=v}const w=$r(d,m,g),x=e=>!!s.isJust&&e===s.value,k=t=>e("button",{className:"table-item-button",children:e("div",{className:"symbol-name",style:Yr(r),children:e("bdi",{dir:"ltr",children:t.name})})}),N=y.filter(e=>{return!i||(t=i,e.name.toLowerCase().includes(t.toLowerCase()));var t}).map(e=>{if("double"===e.type)return(e=>{const t=Or(e.leftTicks>0?e.totalLeft/e.leftTicks:0),n=Or(e.rightTicks>0?e.totalRght/e.rightTicks:0);let a=zr(t,n);Number.isFinite(a)||(a=0);let r="";a>0?r=l.badColor.rgb().string():a<0&&(r=l.goodColor.rgb().string());let i="";return 0===e.totalLeft&&e.totalRght>0?i=c.diffNew:0===e.totalRght&&e.totalLeft>0?i=c.diffRemoved:0===a?i="0%":a>0?i=`+${a.toFixed(2)}%`:a<0&&(i=`${a.toFixed(2)}%`),{"data-row":`${e.type};${e.name};${e.totalLeft};${e.leftTicks};${e.totalRght};${e.rightTicks}`,isRowSelected:x(e.name),onClick:()=>o(e),onContextMenu:t=>f(t,e.name),onDoubleClick:()=>u(e.name),cells:[{value:k(e)},{value:`${t} %`},{value:`${n} %`},{value:i,style:{color:r}}]}})(e);const t=Gr(p,e.name);return((e,t)=>({"data-row":`${e.type};${e.name};${e.self};${e.total}`,isRowSelected:x(e.name),onClick:()=>o(e),onContextMenu:t=>f(t,e.name),onDoubleClick:()=>u(e.name),cells:[{value:k(e)},{value:w.format(e.self,m),style:Os(e.self,h,t)},{value:w.format(e.total,m),style:Os(e.total,d,t)}]}))(e,Kr(l,t))});return N.length>0?{bodyRows:N,type:"filled"}:{value:e("div",{className:"unsupported-format",children:c.noItemsFound}),type:"not-filled"}};function $s({tableBodyRef:r,flamebearer:i,isDoubles:l,fitMode:u,handleTableItemClick:h,highlightQuery:m,selectedItem:p,palette:g,onFocusOnNode:v,updateView:b,enableSandwichView:y=!0,virtualize:w,virtualizeRowHeight:x,virtualizeOverscan:k,scrollRef:N,menuPortalTarget:S}){const T=qi(),[C,_]=_i({transition:!0}),[M,R]=s({x:0,y:0}),[P,F]=s(null),I=Es,j=c(null),E=c(null),D=c(0),B=c(0),L=c(new Map),[A,O]=s(!1),[z,$]=s(0),[V,H]=s([]),[W,U]=s({start:0,end:0}),[J,Q]=s(null),[X,Y]=s(0),[Z,q]=s(0);d(()=>{if(!I)return()=>{};const e=Ps();j.current=e,q(e=>e+1);const t=e=>{const t=e.data;if(t&&t.type)switch(t.type){case"ready":$(t.payload.rowCount),O(!0),Y(e=>e+1);break;case"range":if(t.payload.requestId!==D.current)return;H(t.payload.rows),U({start:t.payload.start,end:t.payload.end});break;case"findNode":{const e=L.current.get(t.payload.requestId);e&&(L.current.delete(t.payload.requestId),e(t.payload.node));break}}};return e.addEventListener("message",t),()=>{e.removeEventListener("message",t),e.terminate(),j.current=null,L.current.clear()}},[I]);const G=f(e=>{if(!I||!j.current)return Promise.resolve(function(e,t){if(!e||!e.levels)return null;const{names:n,levels:a,format:r}=e,o=_r(r);let i=null;for(let e=0;e<a.length;e++){const r=a[e];for(let a=0;a<r.length;a+=o.jStep)if(n[o.getBarName(r,a)]===t){const t=o.getBarTotal(r,a);(!i||t>i.total)&&(i={i:e,j:a,total:t})}}return i?{i:i.i,j:i.j}:null}(i,e));const t=++B.current;return new Promise(n=>{var a;L.current.set(t,n),null===(a=j.current)||void 0===a||a.postMessage({type:"findNode",payload:{name:e,requestId:t}})})},[i,I]),K=f(e=>{v&&G(e).then(e=>{e&&v(e.i,e.j)})},[v,G]),ee=f(e=>{p.isJust&&p.value===e||h({name:e}),K(e)},[K,p,h]),te=f((e,t)=>{e.preventDefault(),R({x:e.clientX,y:e.clientY}),F(t),_(!0)},[_]),ne=f(()=>{_(!1),F(null)},[_]),ae=f(()=>{P&&(K(P),ne())},[P,K,ne]),re=f(()=>{P&&navigator.clipboard&&(navigator.clipboard.writeText(P),ne())},[P,ne]),oe=f(()=>{P&&(h({name:P}),ne())},[P,h,ne]),ie=f(()=>{P&&b&&(b("sandwich"),h({name:P}),ne())},[P,b,h,ne]),le=a.useMemo(()=>l?[{sortable:1,name:"name",label:T.location},{sortable:1,name:"baseline",label:T.baseline,default:!0},{sortable:1,name:"comparison",label:T.comparison},{sortable:1,name:"diff",label:T.diff}]:[{sortable:1,name:"name",label:T.location},{sortable:1,name:"self",label:T.self,default:!0},{sortable:1,name:"total",label:T.total}],[T,l]),se=(e=>{const t=e.filter(e=>null==e?void 0:e.default)[0]||e[0],[n,a]=s(t.name),[r,o]=s("desc");return{sortBy:n,sortByDirection:r,updateSortParams:e=>{let t=r;t=n===e?"asc"===t?"desc":"asc":"desc",a(e),o(t)}}})(le);d(()=>{if(!I||!j.current)return;const e=j.current,t={sortBy:se.sortBy,sortByDirection:se.sortByDirection,highlightQuery:m};E.current!==i?(E.current=i,O(!1),$(0),H([]),e.postMessage({type:"init",payload:{flamebearer:i,...t}})):(O(!1),H([]),e.postMessage({type:"update",payload:t}))},[i,m,se.sortBy,se.sortByDirection,I,Z]);const ce=f((e,t)=>{Q(n=>n&&n.start===e&&n.end===t?n:{start:e,end:t})},[]);d(()=>{if(!I||!j.current||!J)return;const e=++D.current;j.current.postMessage({type:"range",payload:{start:J.start,end:J.end,requestId:e}})},[J,X,I]);const{numTicks:fe,maxSelf:ue,sampleRate:de,spyName:he,units:me}=i,pe=o(()=>$r(fe,de,me),[fe,de,me]),ge=o(()=>Yr(u),[u]),ve=f(e=>p.isJust&&p.value===e,[p]),be=f(t=>e("button",{className:"table-item-button",children:e("div",{className:"symbol-name",style:ge,children:e("bdi",{dir:"ltr",children:t})})}),[ge]),ye=f(e=>{const t=Gr(he,e.name),n=Kr(g,t);return{"data-row":`single;${e.name};${e.self};${e.total}`,isRowSelected:ve(e.name),onClick:()=>{h({name:e.name})},onContextMenu:t=>te(t,e.name),onDoubleClick:()=>ee(e.name),cells:[{value:be(e.name)},{value:pe.format(e.self,de),style:Os(e.self,ue,n)},{value:pe.format(e.total,de),style:Os(e.total,fe,n)}]}},[pe,te,ee,h,ve,ue,be,fe,g,de,he]),we=f(e=>{const t=Or(e.leftTicks>0?e.totalLeft/e.leftTicks:0),n=Or(e.rightTicks>0?e.totalRght/e.rightTicks:0);let a=zr(t,n);Number.isFinite(a)||(a=0);let r="";a>0?r=g.badColor.rgb().string():a<0&&(r=g.goodColor.rgb().string());let o="";return 0===e.totalLeft&&e.totalRght>0?o=T.diffNew:0===e.totalRght&&e.totalLeft>0?o=T.diffRemoved:0===a?o="0%":a>0?o=`+${a.toFixed(2)}%`:a<0&&(o=`${a.toFixed(2)}%`),{"data-row":`double;${e.name};${e.totalLeft};${e.leftTicks};${e.totalRght};${e.rightTicks}`,isRowSelected:ve(e.name),onClick:()=>{h({name:e.name})},onContextMenu:t=>te(t,e.name),onDoubleClick:()=>ee(e.name),cells:[{value:be(e.name)},{value:`${t} %`},{value:`${n} %`},{value:o,style:{color:r}}]}},[te,ee,h,T,ve,be,g]),xe=o(()=>I?V.map(e=>"double"===e.type?we(e):ye(e)):[],[we,ye,I,V]),ke=o(()=>I?A&&0===z?{headRow:le,type:"not-filled",value:e("div",{className:"unsupported-format",children:T.noItemsFound})}:{headRow:le,type:"virtual",rowCount:z,rows:xe,range:W,onRangeChange:ce}:{headRow:le,...zs({flamebearer:i,sortBy:se.sortBy,sortByDirection:se.sortByDirection,fitMode:u,handleTableItemClick:h,highlightQuery:m,palette:g,selectedItem:p,messages:T,onRowContextMenu:te,onRowDoubleClick:ee})},[we,ye,y,u,i,te,ee,ce,h,m,T,v,g,z,p,le,se.sortBy,se.sortByDirection,b,I,xe,W,A]),Ne=p.isJust&&p.value===P;return t(n,{children:[e(Cs,{...se,tableBodyRef:r,table:ke,isLoading:I&&!A,className:zl("flamegraph-table",{"flamegraph-table-doubles":l}),virtualize:w,virtualizeRowHeight:x,virtualizeOverscan:k,scrollRef:N}),t(xi,{...C,anchorPoint:M,onClose:ne,className:Fs,portal:!S||{target:S},children:[v&&t(Ii,{onClick:ae,children:[e(gr,{icon:Wl.faCrosshairs}),T.focusOnThisFunction]}),t(Ii,{onClick:re,children:[e(gr,{icon:_o.faCopy}),T.copyFunctionName]}),t(Ii,{onClick:oe,children:[e(gr,{icon:Io.faHighlighter}),Ne?T.clearHighlight:T.highlightSimilarNodes]}),b&&y&&t(Ii,{onClick:ie,className:Is,children:[e(ml,{fill:"currentColor"}),T.openInSandwichView]})]})]})}const Vs=a.memo(function({flamebearer:n,fitMode:a,handleTableItemClick:r,highlightQuery:o,palette:i,selectedItem:l,onFocusOnNode:f,updateView:u,enableSandwichView:h}){const m=c(null),p=c(null),g=c(null),[v,b]=s(0),[y,w]=s(null),x="double"===n.format;return d(()=>{const e=m.current;if(!e)return;const t=e.offsetWidth-e.clientWidth;Number.isFinite(t)&&t!==v&&b(t)},[m.current,x,v]),d(()=>{const e=p.current;if(!e||"undefined"==typeof document)return;const t=e.closest("[data-theme], [data-flamegraph-color-mode]")||e,n=document.createElement("div");return n.className="flamegraph-menu-portal",t.appendChild(n),w(n),()=>{n.parentElement&&n.parentElement.removeChild(n)}},[]),t("div",{"data-testid":"table-view",ref:p,style:{"--kylin-flamegraph-scrollbar-size":`${v}px`},className:x?"flamegraph-table-wrapper flamegraph-table-wrapper--double":"flamegraph-table-wrapper",children:[e("div",{className:"flamegraph-table-scroll",ref:g,children:e($s,{tableBodyRef:m,flamebearer:n,isDoubles:x,fitMode:a,highlightQuery:o,handleTableItemClick:r,palette:i,selectedItem:l,onFocusOnNode:f,updateView:u,enableSandwichView:h,virtualize:!0,virtualizeOverscan:8,scrollRef:g,menuPortalTarget:y})}),e(Rs,{tableBodyRef:m,numTicks:n.numTicks,sampleRate:n.sampleRate,units:n.units,palette:i})]})});var Hs,Ws,Us={},Js={};function Qs(){return Hs||(Hs=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="arrow-rotate-left",n=[8634,"arrow-left-rotate","arrow-rotate-back","arrow-rotate-backward","undo"],a="f0e2",r="M256 64c-56.8 0-107.9 24.7-143.1 64l47.1 0c17.7 0 32 14.3 32 32s-14.3 32-32 32L32 192c-17.7 0-32-14.3-32-32L0 32C0 14.3 14.3 0 32 0S64 14.3 64 32l0 54.7C110.9 33.6 179.5 0 256 0 397.4 0 512 114.6 512 256S397.4 512 256 512c-87 0-163.9-43.4-210.1-109.7-10.1-14.5-6.6-34.4 7.9-44.6s34.4-6.6 44.6 7.9c34.8 49.8 92.4 82.3 157.6 82.3 106 0 192-86 192-192S362 64 256 64z";e.definition={prefix:"fas",iconName:t,icon:[512,512,n,a,r]},e.faArrowRotateLeft=e.definition,e.prefix="fas",e.iconName=t,e.width=512,e.height=512,e.ligatures=n,e.unicode=a,e.svgPathData=r,e.aliases=n}(Js)),Js}function Xs(){return Ws||(Ws=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t=Qs();e.definition={prefix:t.prefix,iconName:t.iconName,icon:[t.width,t.height,t.aliases,t.unicode,t.svgPathData]},e.faUndo=e.definition,e.prefix=t.prefix,e.iconName=t.iconName,e.width=t.width,e.height=t.height,e.ligatures=t.aliases,e.unicode=t.unicode,e.svgPathData=t.svgPathData,e.aliases=t.aliases}(Us)),Us}var Ys,Zs,qs=Xs(),Gs={},Ks={};function ec(){return Ys||(Ys=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="diagram-project",n=["project-diagram"],a="f542",r="M0 80C0 53.5 21.5 32 48 32l96 0c26.5 0 48 21.5 48 48l0 16 128 0 0-16c0-26.5 21.5-48 48-48l96 0c26.5 0 48 21.5 48 48l0 96c0 26.5-21.5 48-48 48l-96 0c-26.5 0-48-21.5-48-48l0-16-128 0 0 16c0 7.3-1.7 14.3-4.6 20.5l68.6 91.5 80 0c26.5 0 48 21.5 48 48l0 96c0 26.5-21.5 48-48 48l-96 0c-26.5 0-48-21.5-48-48l0-96c0-7.3 1.7-14.3 4.6-20.5L128 224 48 224c-26.5 0-48-21.5-48-48L0 80z";e.definition={prefix:"fas",iconName:t,icon:[512,512,n,a,r]},e.faDiagramProject=e.definition,e.prefix="fas",e.iconName=t,e.width=512,e.height=512,e.ligatures=n,e.unicode=a,e.svgPathData=r,e.aliases=n}(Ks)),Ks}function tc(){return Zs||(Zs=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t=ec();e.definition={prefix:t.prefix,iconName:t.iconName,icon:[t.width,t.height,t.aliases,t.unicode,t.svgPathData]},e.faProjectDiagram=e.definition,e.prefix=t.prefix,e.iconName=t.iconName,e.width=t.width,e.height=t.height,e.ligatures=t.aliases,e.unicode=t.unicode,e.svgPathData=t.svgPathData,e.aliases=t.aliases}(Gs)),Gs}var nc,ac,rc=tc(),oc={},ic={};function lc(){return nc||(nc=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="ellipsis-vertical",n=["ellipsis-v"],a="f142",r="M64 144a56 56 0 1 1 0-112 56 56 0 1 1 0 112zm0 224c30.9 0 56 25.1 56 56s-25.1 56-56 56-56-25.1-56-56 25.1-56 56-56zm56-112c0 30.9-25.1 56-56 56s-56-25.1-56-56 25.1-56 56-56 56 25.1 56 56z";e.definition={prefix:"fas",iconName:t,icon:[128,512,n,a,r]},e.faEllipsisVertical=e.definition,e.prefix="fas",e.iconName=t,e.width=128,e.height=512,e.ligatures=n,e.unicode=a,e.svgPathData=r,e.aliases=n}(ic)),ic}function sc(){return ac||(ac=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t=lc();e.definition={prefix:t.prefix,iconName:t.iconName,icon:[t.width,t.height,t.aliases,t.unicode,t.svgPathData]},e.faEllipsisV=e.definition,e.prefix=t.prefix,e.iconName=t.iconName,e.width=t.width,e.height=t.height,e.ligatures=t.aliases,e.unicode=t.unicode,e.svgPathData=t.svgPathData,e.aliases=t.aliases}(oc)),oc}var cc=sc(),fc="Tooltip-module_tooltipWrapper__leDK-",uc="Tooltip-module_tooltipBubble__8vweF",dc="Tooltip-module_tooltipArrow__7wGyN";function hc(e){if(null!=e&&!1!==e){if("string"==typeof e||"number"==typeof e)return String(e);if(Array.isArray(e)){const t=e.map(e=>hc(e)).filter(e=>!!e);return t.length?t.join(" "):void 0}return a.isValidElement(e)?hc(e.props.children):void 0}}const mc=({placement:a,title:r,content:o,children:i})=>{const l=hc(null!=r?r:o),f=c(null),[u,h]=s(!1);return d(()=>{const e=f.current;if(!e)return;const t=e.closest("[data-theme='kylin'], [data-flamegraph-color-mode='kylin']");h(!!t)},[]),l?t("span",{ref:f,className:fc,"data-placement":a||"top","data-tooltip":u?l:void 0,title:u?void 0:l,children:[i,u?t("span",{className:uc,role:"tooltip",children:[l,e("span",{className:dc})]}):null]}):e(n,{children:i})};var pc,gc={};function vc(){return pc||(pc=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="link",n=[128279,"chain"],a="f0c1",r="M419.5 96c-16.6 0-32.7 4.5-46.8 12.7-15.8-16-34.2-29.4-54.5-39.5 28.2-24 64.1-37.2 101.3-37.2 86.4 0 156.5 70 156.5 156.5 0 41.5-16.5 81.3-45.8 110.6l-71.1 71.1c-29.3 29.3-69.1 45.8-110.6 45.8-86.4 0-156.5-70-156.5-156.5 0-1.5 0-3 .1-4.5 .5-17.7 15.2-31.6 32.9-31.1s31.6 15.2 31.1 32.9c0 .9 0 1.8 0 2.6 0 51.1 41.4 92.5 92.5 92.5 24.5 0 48-9.7 65.4-27.1l71.1-71.1c17.3-17.3 27.1-40.9 27.1-65.4 0-51.1-41.4-92.5-92.5-92.5zM275.2 173.3c-1.9-.8-3.8-1.9-5.5-3.1-12.6-6.5-27-10.2-42.1-10.2-24.5 0-48 9.7-65.4 27.1L91.1 258.2c-17.3 17.3-27.1 40.9-27.1 65.4 0 51.1 41.4 92.5 92.5 92.5 16.5 0 32.6-4.4 46.7-12.6 15.8 16 34.2 29.4 54.6 39.5-28.2 23.9-64 37.2-101.3 37.2-86.4 0-156.5-70-156.5-156.5 0-41.5 16.5-81.3 45.8-110.6l71.1-71.1c29.3-29.3 69.1-45.8 110.6-45.8 86.6 0 156.5 70.6 156.5 156.9 0 1.3 0 2.6 0 3.9-.4 17.7-15.1 31.6-32.8 31.2s-31.6-15.1-31.2-32.8c0-.8 0-1.5 0-2.3 0-33.7-18-63.3-44.8-79.6z";e.definition={prefix:"fas",iconName:t,icon:[576,512,n,a,r]},e.faLink=e.definition,e.prefix="fas",e.iconName=t,e.width=576,e.height=512,e.ligatures=n,e.unicode=a,e.svgPathData=r,e.aliases=n}(gc)),gc}var bc,yc,wc=vc(),xc={},kc={};function Nc(){return bc||(bc=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="magnifying-glass",n=[128269,"search"],a="f002",r="M416 208c0 45.9-14.9 88.3-40 122.7L502.6 457.4c12.5 12.5 12.5 32.8 0 45.3s-32.8 12.5-45.3 0L330.7 376C296.3 401.1 253.9 416 208 416 93.1 416 0 322.9 0 208S93.1 0 208 0 416 93.1 416 208zM208 352a144 144 0 1 0 0-288 144 144 0 1 0 0 288z";e.definition={prefix:"fas",iconName:t,icon:[512,512,n,a,r]},e.faMagnifyingGlass=e.definition,e.prefix="fas",e.iconName=t,e.width=512,e.height=512,e.ligatures=n,e.unicode=a,e.svgPathData=r,e.aliases=n}(kc)),kc}function Sc(){return yc||(yc=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t=Nc();e.definition={prefix:t.prefix,iconName:t.iconName,icon:[t.width,t.height,t.aliases,t.unicode,t.svgPathData]},e.faSearch=e.definition,e.prefix=t.prefix,e.iconName=t.iconName,e.width=t.width,e.height=t.height,e.ligatures=t.aliases,e.unicode=t.unicode,e.svgPathData=t.svgPathData,e.aliases=t.aliases}(xc)),xc}var Tc=Sc(),Cc="Input-module_input__ulQdV";const _c=a.forwardRef(({testId:t,className:n,type:a,name:r,placeholder:o,minLength:i=0,debounceTimeout:l=100,onChange:s,value:c,htmlId:f},u)=>e(I,{inputRef:u,"data-testid":t,className:`${Cc} ${n||""}`,type:a,name:r,placeholder:o,minLength:i,debounceTimeout:l,onChange:s,value:c,id:f}));var Mc="SharedQueryInput-module_wrapper__XRxrd",Rc="SharedQueryInput-module_search__XlzRv",Pc="SharedQueryInput-module_search-synced__J4T4b",Fc="SharedQueryInput-module_searchWithSync__ryuQa",Ic="SharedQueryInput-module_icon__Aq0Hv",jc="SharedQueryInput-module_checked__oRvod",Ec="SharedQueryInput-module_sync__0IO2N",Dc="SharedQueryInput-module_syncSelected__hstBI",Bc="SharedQueryInput-module_searchIcon__kfJxO";const Lc=({onHighlightChange:n,highlightQuery:a,sharedQuery:r,width:i})=>{const l=qi(),f=(e=>{const t=c();return d(()=>{t.current=e},[e]),t.current})(null==r?void 0:r.syncEnabled),u=c(null),[h,m]=s(!1);d(()=>{"string"==typeof(null==r?void 0:r.searchQuery)&&(r.syncEnabled&&n(r.searchQuery),!r.syncEnabled&&f&&f!==(null==r?void 0:r.id)&&n(""))},[null==r?void 0:r.searchQuery,null==r?void 0:r.syncEnabled]),d(()=>{const e=u.current;if(!e)return;const t=e.closest("[data-theme='kylin'], [data-flamegraph-color-mode='kylin']");m(!!t)},[]);const p=o(()=>r&&r.syncEnabled?r.searchQuery||"":a,[r,a]),g=o(()=>`${r?Fc:Rc} ${(null==r?void 0:r.syncEnabled)?Pc:""}`,[r]),v=(null==r?void 0:r.syncEnabled)?l.unsyncSearchBars:l.syncSearchBars;return t("div",{ref:u,className:Mc,style:{width:i},children:[e("span",{className:Bc,children:e(gr,{icon:Tc.faSearch})}),e(_c,{testId:"flamegraph-search",className:g,type:"search",name:"flamegraph-search",placeholder:h?"搜索函数 / 过滤":l.searchPlaceholder,minLength:1,debounceTimeout:100,onChange:e=>{n(e.target.value),r&&r.syncEnabled&&r.onQueryChange(e.target.value)},value:p}),r?e(mc,{placement:"top",title:v,children:e("button",{className:r.syncEnabled?Dc:Ec,onClick:()=>{const e=!(null==r?void 0:r.syncEnabled)&&(null==r?void 0:r.id);null==r||r.toggleSync(e),e?null==r||r.onQueryChange(a):(n(a),null==r||r.onQueryChange(""))},children:e(gr,{className:`${r.syncEnabled?jc:Ic}`,icon:wc.faLink})})}):null]})};var Ac="DiffLegend-module_flamegraph-legend__Cywr1",Oc="DiffLegend-module_flamegraph-legend-list__swdXj",zc="DiffLegend-module_flamegraph-legend-item__0P-6g";function $c(n){const{palette:a,showMode:r}=n,o=function(e){switch(e){case"large":return[-100,-80,-60,-40,-20,-10,0,10,20,40,60,80,100];case"small":return[-100,-50,0,50,100];default:throw new Error(`Unsupported ${e}`)}}(r),i=eo(a);return e("div",{"data-testid":"flamegraph-legend",className:`${Ac} ${Oc}`,style:"small"===r?{"--legend-item-width":"32px","--legend-item-padding":"2px 2px","--legend-font-size":"10px","--legend-line-height":"1.1","--legend-item-height":"16px"}:void 0,children:o.map(e=>t("div",{className:zc,style:{backgroundColor:i(e).rgb().toString()},children:[e>0?"+":"",e,"%"]},e))})}var Vc="Dropdown-module_dropdownMenu__tbN8r",Hc="Dropdown-module_dropdownMenuButton__Xy8M4";function Wc({id:n,children:a,className:r,disabled:o,value:i,label:l,onItemClick:s,overflow:c,position:f,direction:u,align:d,viewScroll:h,arrow:m,menuButtonClassName:p="",ariaLabel:g,portal:v,...b}){const y=b.menuButton||e(Jc,{"aria-label":g,className:`${Hc} ${p}`,disabled:o,type:"button",children:i||l});return t(Ri,{id:n,"aria-label":g,className:zl(r,Vc),"data-testid":b["data-testid"],onItemClick:s,overflow:c,position:f,direction:u,align:d,viewScroll:h,arrow:m,menuButton:y,portal:v,children:[e(ji,{children:l}),a]})}const Uc=Ii,Jc=fi;var Qc="DiffLegendPaletteDropdown-module_container__h8Tts",Xc="DiffLegendPaletteDropdown-module_triggerButton__oezA6",Yc="DiffLegendPaletteDropdown-module_dropdownArrow__-Lu0w",Zc="DiffLegendPaletteDropdown-module_menuItem__5iWry",qc="DiffLegendPaletteDropdown-module_menuItemText__a-tt0",Gc="DiffLegendPaletteDropdown-module_dropdownMenu__G0NkR",Kc="DiffLegendPaletteDropdown-module_menuItemWrapper__vAw-Q",ef="DiffLegendPaletteDropdown-module_menuItemSelected__1gu9m";const tf=[$i,Vi],nf=n=>{const{palette:a=$i,onChange:r}=n,o=qi(),i=e=>"Default"===e.name?o.paletteDefaultName:"Color Blind"===e.name?o.paletteColorBlindName:e.name,l=e=>"Default"===e.name?o.paletteDefaultDesc:"Color Blind"===e.name?o.paletteColorBlindDesc:"";return e("div",{className:Qc,children:e(Wc,{label:o.diffLegendSelectPalette,align:"end",className:Gc,menuButton:t(Jc,{className:zl(Hc,Xc),children:[e($c,{palette:a,showMode:"small"}),e("span",{className:Yc})]}),onItemClick:e=>{e.value&&r(e.value)},children:tf.map(n=>e(Uc,{value:n,className:zl(Kc,n.name===a.name&&ef),children:e("div",{className:Zc,children:t("span",{className:qc,children:[i(n)," ",l(n)]})})},n.name))})})};var af={navbar:"Toolbar-module_navbar__XN6xZ",searchWrapper:"Toolbar-module_searchWrapper__k--ua",rightSection:"Toolbar-module_rightSection__if7LO",viewType:"Toolbar-module_viewType__AKARg",toggleViewButton:"Toolbar-module_toggleViewButton__OQ9-U",fitModeButton:"Toolbar-module_fitModeButton__jOxve",selected:"Toolbar-module_selected__vwBQt",collapseNodeButton:"Toolbar-module_collapseNodeButton__bLdiw",resetViewButton:"Toolbar-module_resetViewButton__y2ebV",divider:"Toolbar-module_divider__dG6pE",itemsContainer:"Toolbar-module_itemsContainer__gSTMF",item:"Toolbar-module_item__o-hKc",moreButton:"Toolbar-module_moreButton__rhOdT",active:"Toolbar-module_active__36Kt-",navbarCollapsedItems:"Toolbar-module_navbarCollapsedItems__vojhw"};const rf=$.bind(af),of=(e,t,n)=>{const a=0===t?e-360-5:e-360-16-5;let r=0,o=0;return n.reverse().forEach(e=>{o+=e,a<=o&&(r+=1)}),r},lf=()=>e("div",{className:af.divider}),sf=y(({view:a,handleSearchChange:r,highlightQuery:o,isFlamegraphDirty:i,reset:l,updateFitMode:f,fitMode:h,updateView:m,selectedNode:p,onFocusOnSubtree:g,flamegraphType:v,enableChangingDisplay:b=!0,sharedQuery:y,ExportData:w,palette:k,setPalette:N})=>{const S=c(null),[T,C]=s(!1),M=qi();d(()=>{const e=S.current;if(!e)return;const t=e.closest("[data-theme='kylin'], [data-flamegraph-color-mode='kylin']");C(!!t)},[]);const R=T?32:44,P=T?220:360,F="double"===v&&k&&N,I=[{el:t(n,{children:[e(uf,{fitMode:h,updateFitMode:f}),e(lf,{})]}),width:2*R+5},{el:e(ff,{isFlamegraphDirty:i,reset:l}),width:R},{el:t(n,{children:[e(cf,{selectedNode:p,onFocusOnSubtree:g}),e(lf,{})]}),width:R+5},b?{el:e(hf,{flamegraphType:v,view:a,updateView:m}),width:R*("single"===v?5:3)}:null,x(w)?{el:t(n,{children:[e(lf,{}),w]}),width:R+5}:null].filter(e=>null!==e),j=I.reduce((e,t)=>[...e,t.width],[]),{isCollapsed:E,collapsedItemsNumber:D,handleMoreClick:B}=((e,t)=>{const[n,a]=s(!0),[r,o]=s(0);return u(()=>{if(e.current){const{width:n}=e.current.getBoundingClientRect(),a=of(n,r,t);o(a)}},[e.current,t]),_(e,e=>{const{width:n}=e.target.getBoundingClientRect(),i=of(n,r,t);o(i),a(!0)}),{isCollapsed:n,handleMoreClick:()=>{a(e=>!e)},collapsedItemsNumber:r}})(S,j),L=I.reduce((e,t,n)=>(n<D?e.hidden.push(t):e.visible.push(t),e),{visible:[],hidden:[]});return e("div",{role:"toolbar",ref:S,children:t("div",{className:af.navbar,children:[e("div",{className:af.searchWrapper,children:e(Lc,{width:P,onHighlightChange:r,highlightQuery:o,sharedQuery:y})}),t("div",{className:af.rightSection,children:[F&&t(n,{children:[e(nf,{palette:k,onChange:N}),e(lf,{})]}),t("div",{className:af.itemsContainer,children:[L.visible.map((t,n)=>e("div",{className:af.item,style:{width:t.width},children:t.el},n)),0!==D&&e(mc,{placement:"top",title:M.more,children:e("button",{onClick:B,className:rf({[af.moreButton]:!0,[af.active]:!E}),children:e(gr,{icon:cc.faEllipsisV})})})]})]}),!E&&e("div",{className:af.navbarCollapsedItems,children:L.hidden.map((t,n)=>e("div",{className:af.item,style:{width:t.width},children:t.el},n))})]})})});function cf({onFocusOnSubtree:t,selectedNode:n}){const a=qi(),r=n.mapOr(()=>{},e=>()=>t(e.i,e.j));return e(mc,{placement:"top",title:a.collapseNodesAbove,children:e("div",{children:e(Ns,{disabled:!n.isJust,onClick:r,className:af.collapseNodeButton,"aria-label":a.collapseNodesAbove,children:e(gr,{icon:Lo.faCompressAlt})})})})}function ff({isFlamegraphDirty:t,reset:n}){const a=qi();return e(mc,{placement:"top",title:a.resetView,children:e("span",{children:e(Ns,{id:"reset",disabled:!t,onClick:n,className:af.resetViewButton,"aria-label":a.resetView,children:e(gr,{icon:qs.faUndo})})})})}function uf({fitMode:a,updateFitMode:r}){const o=qi(),i=e=>a===e;return t(n,{children:[e(mc,{placement:"top",title:o.headFirst,children:e(Ns,{onClick:()=>r("HEAD"),className:rf({[af.fitModeButton]:!0,[af.selected]:i("HEAD")}),children:e(pl,{})})}),e(mc,{placement:"top",title:o.tailFirst,children:e(Ns,{onClick:()=>r("TAIL"),className:rf({[af.fitModeButton]:!0,[af.selected]:i("TAIL")}),children:e(gl,{})})})]})}const df=(t,n)=>"single"===t?[{label:n.viewFlamegraph,value:"flamegraph",Icon:hl},{label:n.viewTable,value:"table",Icon:ul},{label:n.viewTableAndFlamegraph,value:"both",Icon:dl},{label:n.viewSandwich,value:"sandwich",Icon:ml},{label:n.viewGraphviz,value:"graphviz",Icon:()=>e(gr,{icon:rc.faProjectDiagram})}]:[{label:n.viewFlamegraph,value:"flamegraph",Icon:hl},{label:n.viewTable,value:"table",Icon:ul},{label:n.viewTableAndFlamegraph,value:"both",Icon:dl}];function hf({view:t,updateView:n,flamegraphType:a}){const r=qi(),o=df(a,r);return e("div",{className:af.viewType,children:o.map(({label:a,value:r,Icon:o})=>e(mc,{placement:"top",title:a,children:e(Ns,{"data-testid":r,onClick:()=>n(r),className:rf({[af.toggleViewButton]:!0,selected:t===r}),children:e(o,{})})},r))})}function mf(e,t){const n={},a={};let r={name:"total",children:[],self:[],total:[],key:"/total"};return(t?[e,t]:[e]).forEach((e,t)=>{var o,i;for(let l=0;l<e.levels.length;l+=1)for(let s=0;s<e.levels[l].length;s+=4){const c=[t,l,s].join("/"),f=e.names[e.levels[l][s+3]],u=e.levels[l][s+0],d=e.levels[l][s+1],h=e.levels[l][s+2];let m="";if(0!==l){const n=l-1,r=e.levels[n];for(let e=0;e<r.length;e+=4){const o=r[e+0],i=r[e+1];if(u>=o&&u<o+i){const r=[t,n,e].join("/");m=a[r].key;break}}}const p=[m||"",f].join("/"),g=!n[p];n[p]||(n[p]={name:f,children:[],self:[],total:[],key:p});const v=n[p];(o=v.total)[t]||(o[t]=0),v.total[t]+=d,(i=v.self)[t]||(i[t]=0),v.self[t]+=h,a[c]=v,m&&g&&n[m].children.push(v),0===l&&(r=v)}}),r}const pf=e=>{const t={maxSelf:100,names:[],levels:[]},n=(e,a,r)=>{var o;const{name:i,children:l,self:s,total:c,offset:f}=e;t.names.push(i),(o=t.levels)[a]||(o[a]=[]),t.maxSelf=Math.max(t.maxSelf,s[0]||0),t.levels[a]=t.levels[a].concat([r,c[0]||0,s[0]||0,t.names.length-1]);for(let e=0;e<l.length;e+=1){r+=n(l[e],a+1,r)}return f||c[0]||0};return n(e,0,0),t};function gf(e){const t=new Map;for(let n=0;n<e.children.length;n+=1)t.has(e.children[n].name)||t.set(e.children[n].name,e.children[n]);for(let n=0;n<e.children.length;n+=1){const a=e.children[n],r=t.get(e.children[n].name);r&&r!==a&&(r.total[0]+=a.total[0],r.self[0]+=a.self[0],r.children=r.children.concat(a.children))}e.children=Array.from(t.values());for(let t=0;t<e.children.length;t+=1)gf(e.children[t])}function vf(e,t){const n=function(e,t){const n=mf(e),a={format:"single",numTicks:0,maxSelf:100,sampleRate:100,names:[],levels:[],units:e.units,spyName:e.spyName},r={name:t,total:[],self:[0],children:[]},o=e=>{e.name===t&&(a.numTicks+=e.total[0],r.total=[a.numTicks],r.children=r.children.concat(e.children));for(let t=0;t<e.children.length;t+=1)o(e.children[t])};return o(n),gf(r),{...a,...pf(r)}}(JSON.parse(JSON.stringify(e)),t);return n}function bf(e,t){const n=function(e,t){const n=mf(e),a={format:"single",maxSelf:100,sampleRate:100,numTicks:0,names:[],levels:[],units:e.units,spyName:e.spyName},r=[],o=[],i={name:t,total:[0],self:[0],children:[]},l=(e,n=[])=>{const i=n.concat([{...e,children:[]}]);e.name===t&&(o.push(i),r.push(e.total[0]),a.numTicks+=e.total[0]);for(let t=0;t<e.children.length;t+=1)l(e.children[t],i)};l(n),o.forEach((e,t)=>{i.children.push(((e,t)=>{const n={};let a=n;return e.forEach(({name:e,...n})=>{const r={name:e,...n,total:[t]};a.children=[r],a=r}),n.children[0]})(e.reverse(),r[t]))}),gf(i);const s=pf(i);return s.levels=s.levels.reverse().slice(0,-1),{...a,...s}}(JSON.parse(JSON.stringify(e)),t);return n}var yf={flamegraphContainer:"FlamegraphRenderer-module_flamegraphContainer__-7FRV",createdBy:"FlamegraphRenderer-module_createdBy__rHAOT",horizontal:"FlamegraphRenderer-module_horizontal__zs7--",vertical:"FlamegraphRenderer-module_vertical__fRcHg",panesWrapper:"FlamegraphRenderer-module_panesWrapper__L-mlA",tablePane:"FlamegraphRenderer-module_tablePane__Gin7Y",sandwichPane:"FlamegraphRenderer-module_sandwichPane__IEOyR",sandwichPaneInfo:"FlamegraphRenderer-module_sandwichPaneInfo__5hT4a",arrow:"FlamegraphRenderer-module_arrow__dPzpE",sandwichTop:"FlamegraphRenderer-module_sandwichTop__7N0ZY",sandwichBottom:"FlamegraphRenderer-module_sandwichBottom__Dc64g",name:"FlamegraphRenderer-module_name__XRbN9"};function wf(e){const t=[];return Object.keys(e).forEach(n=>{var a;t.push(`${n}="${a=String(e[n]||""),a.replace(/\\/g,"\\\\").replace(/"/g,'\\"')}"`)}),`[${t.join(" ")}]`}function xf(e,t){return`${(100*e/t).toFixed(2)}%`}function kf(e,t){let n,a,r,o;t?(n=.1,a=.93):(n=1,a=.7),e=Math.max(-1,Math.min(1,e)),Math.abs(e)<.2&&(n*=Math.abs(e)/.2),e>0&&(e**=1-.7),e<0&&(e=-((-e)**(1-.7))),e<0?(o=a,r=a*(1+n*e)):(r=a,o=a*(1-n*e));const i=a*(1-n);return`#${Math.floor(255*r).toString(16).padStart(2,"0")}${Math.floor(255*o).toString(16).padStart(2,"0")}${Math.floor(255*i).toString(16).padStart(2,"0")}`}function Nf(e,t,n,a){const{self:r}=t,{total:o}=t,i=t.name.replace(/"/g,'\\"'),l=e(r),s=8+Math.ceil(16*Math.sqrt(r/n)),c=kf(o/a,!1),f=kf(o/a,!0),u=function(e,t,n,a,r){let o="";o=`${function(e){return e.replace(/.*\//,"")}(t)}\n`;const i=e(n);0!==n?o=`${o+i} (${xf(n,r)})`:o+="0";let l=i;a!==n&&(o+=0!==n?"\n":" ",l=e(a),o=`${o}of ${l} (${xf(a,r)})`);return o}(e,i,r,o,a),d={label:u,id:`node${t.index}`,fontsize:s,shape:"box",tooltip:`${i} (${l})`,color:c,fontcolor:"#000000",style:"filled",fontname:"",fillcolor:f};return`N${t.index} ${wf(d)}`}function Sf(e){if("double"===e.metadata.format)return"diff flamegraphs are not supported";const t=mf(e.flamebearer),n=[],a=[];const[r,o,,i]=function e(t,n,a,r,o){return t.children.forEach(t=>{const[i,l]=e(t,n,a,r,o);n=Math.max(n,i),a=Math.max(a,l)}),n=Math.max(n,t.self[0]),a=Math.max(a,t.total[0]),r+=t.self[0],o+=t.total[0],[n,a,r,o]}(t,0,0,0,0),{sampleRate:l,units:s}=e.metadata,c=$r(o,l,s),f=e=>c.format(e,l,!0);let u={};const d={};let h=0;function m(e,t){return-1===t.indexOf(e.name)&&(u[e.name]?(u[e.name].self+=e.self[0],u[e.name].total+=e.total[0]):(h+=1,u[e.name]={index:h,name:e.name,self:e.self[0],total:e.total[0],parents:[],children:[]})),e.children.forEach(n=>{const a=m(n,t.concat([e.name])),r=`${e.name}/${n.name}`;n.name!==e.name&&(d[r]?d[r].weight+=n.total[0]:d[r]={from:u[e.name],to:a,weight:n.total[0],residual:!1},a.parents.push(d[r]),u[e.name].children.push(d[r]))}),u[e.name]}t.children.forEach(e=>{m(e,[])});const p=.005*i,g=.001*i;function v(e,t){let n=0,a=t;if(e.forEach(e=>{e.weight>0&&(a+=Math.abs(e.weight))}),0!==a&&(e.forEach(e=>{const t=Math.abs(e.weight)/a;n+=-t*Math.log2(t)}),t>0)){const e=Math.abs(t)/a;n+=-e*Math.log2(e)}return n}Object.keys(u).forEach(e=>{u[e].total<p&&delete u[e]});const b={};Object.keys(u).forEach(e=>{b[u[e].name]=function(e){let t=0;return 0===e.parents.length?t+=1:t+=v(e.parents,0),0===e.children.length?t+=1:t+=v(e.children,e.self),t*e.total+e.self}(u[e])});const y=Object.values(u).sort((e,t)=>{const n=b[e.name],a=b[t.name];return n!==a?a-n:e.name!==t.name?e.name<t.name?-1:1:e.self!==t.self?a-n:e.name<t.name?-1:1}),w={};function x(e){const[t,n]=[e.from,e.to],a={},r=[n];for(;r.length>0;){const n=r.shift();for(let o=0;o<n.parents.length;o+=1){const i=n.parents[o];if(e!==i&&!a[i.from.name]){if(i.from===t)return!0;a[i.from.name]=!0,r.push(i.from)}}}return!1}return y.forEach(e=>{w[e.name]=e}),y.slice(80).forEach(e=>{delete w[e.name]}),function e(t,n){const a=!w[t.name];t.children.forEach(r=>{const o=!w[r.name];if(e(r,a?n:t),!o&&n&&a){const e=`${n.name}/${r.name}`;d[e]||(d[e]={from:u[n.name],to:u[r.name],weight:0,residual:!0}),d[e].weight+=r.total[0],d[e].residual=!0}})}(t,null),u=w,y.reverse().forEach(e=>{const t=e.parents.sort((e,t)=>t.weight-e.weight),n=[];for(let e=0;e<t.length;e+=1){const a=t[e];if(!a.residual)break;x(a)&&(n.push(a),delete d[`${a.from.name}/${a.to.name}`])}n.forEach(e=>{e.from.children=e.from.children.filter(t=>t.to!==e.to),e.to.parents=e.to.parents.filter(t=>t.from!==e.from)})}),Object.keys(d).forEach(e=>{const t=d[e];u[t.from.name]||delete d[e],u[t.to.name]||delete d[e],t.weight<g&&delete d[e]}),Object.keys(u).forEach(e=>{n.push(Nf(f,u[e],r,o))}),Object.keys(d).forEach(e=>{a.push(function(e,t,n){const a=t.from.name.replace(/"/g,'\\"'),r=t.to.name.replace(/"/g,'\\"'),o=t.weight,i=e(t.weight),l=`${a} -> ${r} (${i})`,s={label:i,weight:1+100*o/n,penwidth:1+5*o/n,tooltip:l,labeltooltip:l,fontname:"",color:kf(o/n,!1),style:t.residual?"dotted":""};return`N${t.from.index} -> N${t.to.index} ${wf(s)}`}(f,d[e],o))}),`digraph "unnamed" {\n fontname= ""\n ${n.join("\n")}\n ${a.join("\n")}\n }`}var Tf="GraphVizPanel-module_graphVizPane__B18cQ";const Cf=()=>null;function _f({flamebearer:t}){var n,a;const r=t,i=(null===(n=r.metadata)||void 0===n?void 0:n.format)&&(null===(a=r.flamebearer)||void 0===a?void 0:a.levels),l=`graphviz-pane-${(null==r?void 0:r.appName)||String((new Date).valueOf())}`,s=o(()=>Sf(r),[JSON.stringify(r)]);return e("div",{className:Tf,children:i?e(Cf,{options:{zoom:!0,width:"150%",height:"100%",scale:1,useWorker:!1},dot:s}):e("div",{children:"NO DATA"})},l)}function Mf(e){let t=2166136261;const n=e.length;if(0===n)return t>>>0;const a=[0,Math.floor(n/2),n-1];for(let n=0;n<a.length;n+=1){const r=e[a[n]];if(!r||0===r.length)continue;const o=Math.min(8,r.length);for(let e=0;e<o;e+=1)t^=0|r[e],t=Math.imul(t,16777619);for(let e=Math.max(0,r.length-o);e<r.length;e+=1)t^=0|r[e],t=Math.imul(t,16777619)}return t>>>0}function Rf(e){let t=2166136261;const n=e.length;if(0===n)return t>>>0;const a=Math.min(32,n),r=[...Array.from({length:a},(e,t)=>t),...Array.from({length:a},(e,t)=>n-a+t)];for(let n=0;n<r.length;n+=1){const a=e[r[n]]||"";for(let e=0;e<a.length;e+=1)t^=a.charCodeAt(e),t=Math.imul(t,16777619)}return t>>>0}function Pf(e){var t,n,a,r,o,i;const l=e.__kylinSignature;if(l)return l;const s=e,c=[e.format,e.numTicks,e.sampleRate,e.units,e.maxSelf,null!==(n=null===(t=e.names)||void 0===t?void 0:t.length)&&void 0!==n?n:0,null!==(r=null===(a=e.levels)||void 0===a?void 0:a.length)&&void 0!==r?r:0,null!==(o=s.leftTicks)&&void 0!==o?o:"na",null!==(i=s.rightTicks)&&void 0!==i?i:"na",Mf(e.levels),Rf(e.names||[])].join("|");return e.__kylinSignature=c,c}function Ff(e,t){const n=[...t];function a(e,t,n){for(const a of e){let e=0;for(let r=t;r<a.length;r+=n)a[r]-=e,e+=a[r]+a[r+1]}}return"double"===e?(a(n,0,7),a(n,3,7)):a(n,0,4),n}function If(e,t){const n=[...t];function a(e,t,n){for(const a of e){let e=0;for(let r=t;r<a.length;r+=n)a[r]+=e,e=a[r]+a[r+1]}}return"double"===e?(a(n,0,7),a(n,3,7)):a(n,0,4),n}function jf(e){if(e.profile&&e.flamebearer&&console.warn("'profile' and 'flamebearer' properties are mutually exclusive. Please use profile if possible."),e.profile){const n=e.profile,a={...n,flamebearer:{...n.flamebearer}};n.__kylinDecoded||((t=a).flamebearer.levels=If(t.metadata.format,t.flamebearer.levels),n.__kylinDecoded=!0,a.__kylinDecoded=!0);const r={...a,...a.metadata,...a.flamebearer,flamebearer:void 0,metadata:void 0};return delete r.flamebearer,delete r.metadata,r}var t;if(e.flamebearer)return e.flamebearer;return{format:"single",names:[],units:"unknown",levels:[[]],spyName:"unknown",numTicks:0,sampleRate:0,maxSelf:0}}class Ef extends k{constructor(n){super(n),this.resetFlamegraphState={focusedNode:N.nothing(),zoom:N.nothing()},this.initialFlamegraphState=this.resetFlamegraphState,this.calcNewConfigs=(e,t)=>{const n=this.state.flamegraphConfigs,a=(e,t,n)=>{const a=(e,t,n)=>e.names[_r(e.format).getBarName(e.levels[t],n)];if(n.isNothing)return!0;try{const r=n,o=a(e,r.value.i,r.value.j);return o===a(t,r.value.i,r.value.j)}catch{return!1}};a(e,t,this.state.flamegraphConfigs.zoom)||(n.zoom=this.resetFlamegraphState.zoom);return a(e,t,this.state.flamegraphConfigs.focusedNode)||(n.focusedNode=this.resetFlamegraphState.focusedNode),n},this.onSearchChange=e=>{this.setState({searchQuery:e})},this.isSameFlamebearer=(e,t)=>function(e,t){return Pf(e)===Pf(t)}(e,t),this.onReset=()=>{this.setState({...this.state,flamegraphConfigs:{...this.state.flamegraphConfigs,...this.initialFlamegraphState},selectedItem:N.nothing()})},this.onFlamegraphZoom=e=>{e.isJust&&0===e.value.i&&0===e.value.j?this.onReset():this.setState({...this.state,flamegraphConfigs:{...this.state.flamegraphConfigs,zoom:e}})},this.onFocusOnNode=(e,t)=>{if(0===e&&0===t)return void this.onReset();let n={...this.state.flamegraphConfigs};const{zoom:a}=this.state.flamegraphConfigs;a.isJust&&a.value.i<=e&&(n={...n,zoom:this.initialFlamegraphState.zoom}),this.setState({...this.state,flamegraphConfigs:{...n,focusedNode:N.just({i:e,j:t})}})},this.isNameInFocusedSubtree=e=>{const{focusedNode:t}=this.state.flamegraphConfigs;if(t.isNothing)return!0;const{flamebearer:n}=this.state;if(!n||!n.levels)return!0;const{names:a,levels:r,format:o}=n,i=_r(o),l=t.value.i,s=t.value.j,c=r[l];if(!c)return!0;const f=i.getBarOffset(c,s),u=f+i.getBarTotal(c,s);for(let t=l;t<r.length;t++){const n=r[t];for(let t=0;t<n.length;t+=i.jStep){const r=i.getBarOffset(n,t),o=i.getBarTotal(n,t);if(r>=f&&r+o<=u){if(a[i.getBarName(n,t)]===e)return!0}}}return!1},this.setActiveItem=e=>{const{name:t}=e;if(this.state.selectedItem.isJust&&t===this.state.selectedItem.value)return void this.setState({selectedItem:N.nothing()});this.isNameInFocusedSubtree(t)?this.setState({selectedItem:N.just(t)}):this.setState({selectedItem:N.just(t),flamegraphConfigs:{...this.state.flamegraphConfigs,focusedNode:this.resetFlamegraphState.focusedNode}})},this.getHighlightQuery=()=>this.state.selectedItem.isJust?this.state.selectedItem.value:this.state.searchQuery,this.updateView=e=>{"sandwich"===e&&this.setState({searchQuery:"",flamegraphConfigs:this.resetFlamegraphState}),this.setState({view:e})},this.updateFlamegraphDirtiness=()=>{const e=this.isDirty();this.setState({isFlamegraphDirty:e})},this.updateFitMode=e=>{this.setState({fitMode:e})},this.clearFocus=()=>{this.setState(e=>({...e,flamegraphConfigs:{...e.flamegraphConfigs,...this.resetFlamegraphState}}))},this.getActiveRange=()=>{const{flamebearer:e}=this.state,{zoom:t,focusedNode:n}=this.state.flamegraphConfigs,a=e.numTicks;if(!a)return{rangeMin:0,rangeMax:1};const r=_r(e.format),o=t=>{const n=e.levels[t.i];if(!n)return{rangeMin:0,rangeMax:1};const o=r.getBarOffset(n,t.j),i=r.getBarTotal(n,t.j);return{rangeMin:o/a,rangeMax:(o+i)/a}};return t.match({Just:e=>n.match({Just:t=>{const n=o(t),a=o(e);return n.rangeMax-n.rangeMin<a.rangeMax-a.rangeMin?n:a},Nothing:()=>o(e)}),Nothing:()=>n.match({Just:e=>o(e),Nothing:()=>({rangeMin:0,rangeMax:1})})})},this.isDirty=()=>this.state.selectedItem.isJust||JSON.stringify(this.initialFlamegraphState)!==JSON.stringify(this.state.flamegraphConfigs),this.handleSetPalette=e=>{this.setState({palette:e})},this.render=()=>{var n;const a=e("div",{className:ho(yf.tablePane,"vertical"===this.state.panesOrientation?yf.vertical:yf.horizontal),children:e(Vs,{"data-testid":"table-view",flamebearer:this.state.flamebearer,fitMode:this.state.fitMode,highlightQuery:this.state.searchQuery,selectedItem:this.state.selectedItem,handleTableItemClick:this.setActiveItem,palette:this.state.palette,onFocusOnNode:this.onFocusOnNode,updateView:this.props.onlyDisplay?void 0:this.updateView,enableSandwichView:this.props.enableSandwichView})},"table-pane"),r=this.shouldShowToolbar(),o=!this.state.flamebearer||this.state.flamebearer.names.length<=1,i=this.context,l="Location"!==i.location,s=this.state.flamebearer.numTicks,c=$r(s,this.state.flamebearer.sampleRate,this.state.flamebearer.units).format(s,this.state.flamebearer.sampleRate),f=Lr(c,l)||c,u=function(e,t=Ar){const n=Math.abs(e);for(const{value:a,label:r}of t)if(n>=a)return`${(e/a).toFixed(2).replace(/\.?0+$/,"")} ${r}`;return Dr(e)}(s,i.sampleCountFormat),d=i.tooltipSamples.replace(/[::]\s*$/,""),h=(null===(n=i.tooltipUnitTitles[this.state.flamebearer.units])||void 0===n?void 0:n.formattedValue)||i.tooltipUnitTitles.unknown.formattedValue,m=this.getActiveRange(),p=m.rangeMin>0||m.rangeMax<1,g=Math.max(0,Math.min(s,(m.rangeMax-m.rangeMin)*s)),v=s>0?g/s*100:0,b=(()=>{const e=_r(this.state.flamebearer.format),t=this.state.flamegraphConfigs.focusedNode.mapOrElse(()=>this.state.flamegraphConfigs.zoom.mapOrElse(()=>null,e=>e),e=>e);if(!t)return"";const n=this.state.flamebearer.levels[t.i];if(!n)return"";const a=e.getBarName(n,t.j);return this.state.flamebearer.names[a]||""})(),y=e(Dl,{showCredit:this.props.showCredit,flamebearer:this.state.flamebearer,highlightQuery:this.getHighlightQuery(),setActiveItem:this.setActiveItem,selectedItem:this.state.selectedItem,updateView:this.props.onlyDisplay?void 0:this.updateView,fitMode:this.state.fitMode,updateFitMode:this.updateFitMode,zoom:this.state.flamegraphConfigs.zoom,focusedNode:this.state.flamegraphConfigs.focusedNode,onZoom:this.onFlamegraphZoom,onFocusOnNode:this.onFocusOnNode,onReset:this.onReset,isDirty:this.isDirty,palette:this.state.palette,toolbarVisible:r,setPalette:this.handleSetPalette,enableSandwichView:this.props.enableSandwichView,breadcrumb:o?void 0:{totalValueText:f,totalSamplesText:u,samplesLabel:d,unitLabel:h,hasFocus:p,focusPercent:v,focusLabel:b,ofTotalPlacement:l?"before":"after",ofTotalLabel:i.ofTotal,clearFocusLabel:i.clearFocus,onClearFocus:this.clearFocus}},"flamegraph-pane"),w=(()=>{if("sandwich"!==this.state.view)return e("div",{className:yf.sandwichPane},"sandwich-pane");if(this.state.selectedItem.isNothing)return e("div",{className:yf.sandwichPane,children:t("div",{className:ho(yf.sandwichPaneInfo,"vertical"===this.state.panesOrientation?yf.vertical:yf.horizontal),children:[e("div",{className:yf.arrow}),"Select a function to view callers/callees sandwich view"]})},"sandwich-pane");const n=bf(this.state.flamebearer,this.state.selectedItem.value),a=vf(this.state.flamebearer,this.state.selectedItem.value),o=t=>e(Dl,{disableClick:!0,showCredit:this.props.showCredit,highlightQuery:"",setActiveItem:this.setActiveItem,selectedItem:this.state.selectedItem,fitMode:this.state.fitMode,updateFitMode:this.updateFitMode,zoom:this.state.flamegraphConfigs.zoom,focusedNode:this.state.flamegraphConfigs.focusedNode,onZoom:this.onFlamegraphZoom,onFocusOnNode:this.onFocusOnNode,onReset:this.onReset,isDirty:this.isDirty,palette:this.state.palette,toolbarVisible:r,setPalette:this.handleSetPalette,...t});return t("div",{className:yf.sandwichPane,children:[t("div",{className:yf.sandwichTop,children:[e("span",{className:yf.name,children:"Callers"}),o({flamebearer:n})]}),t("div",{className:yf.sandwichBottom,children:[e("span",{className:yf.name,children:"Callees"}),o({flamebearer:a,headerVisible:!1,showSingleLevel:!0})]})]},"sandwich-pane")})(),x=function(e,t,n,a,r){switch(e){case"table":return[n];case"flamegraph":return[t];case"sandwich":return[n,a];case"both":return[n,t];case"graphviz":return[r];default:throw new Error(`Invalid view '${e}'`)}}(this.state.view,y,a,w,e(_f,{flamebearer:this.state.flamebearer}));return t("div",{children:[t("div",{children:[r&&e(sf,{sharedQuery:this.props.sharedQuery,enableChangingDisplay:!this.props.onlyDisplay,flamegraphType:this.state.flamebearer.format,view:this.state.view,handleSearchChange:this.onSearchChange,reset:this.onReset,updateView:this.updateView,updateFitMode:this.updateFitMode,fitMode:this.state.fitMode,isFlamegraphDirty:this.isDirty(),selectedNode:this.state.flamegraphConfigs.zoom,highlightQuery:this.state.searchQuery,onFocusOnSubtree:this.onFocusOnNode,ExportData:this.props.ExportData,palette:this.state.palette,setPalette:this.handleSetPalette}),this.props.children,e("div",{className:`${yf.flamegraphContainer} ${ho("vertical"===this.state.panesOrientation?yf.vertical:yf.horizontal,yf[this.state.panesOrientation],yf.panesWrapper)}`,children:o?e(po,{}):x.map(e=>e)})]}),this.props.showPyroscopeLogo&&t("div",{className:yf.createdBy,children:["Created by",t("a",{href:"https://twitter.com/PyroscopeIO",rel:"noreferrer",target:"_blank",children:[e(j,{width:"30",height:"30"}),"@PyroscopeIO"]})]})]})},this.state={isFlamegraphDirty:!1,view:this.props.onlyDisplay?this.props.onlyDisplay:"both",fitMode:"HEAD",flamebearer:jf(n),panesOrientation:n.panesOrientation?n.panesOrientation:"horizontal",searchQuery:"",selectedItem:N.nothing(),flamegraphConfigs:this.initialFlamegraphState,palette:$i}}componentDidUpdate(e,t){if(e.profile!==this.props.profile||e.flamebearer!==this.props.flamebearer){const e=t.flamebearer,n=jf(this.props);if(!this.isSameFlamebearer(e,n)){const t=this.calcNewConfigs(e,n);return void this.setState({flamebearer:n,flamegraphConfigs:{...this.state.flamegraphConfigs,...t},selectedItem:N.nothing()})}}t.flamegraphConfigs!==this.state.flamegraphConfigs&&this.updateFlamegraphDirtiness()}shouldShowToolbar(){return void 0===this.props.showToolbar||this.props.showToolbar}}Ef.contextType=Yi,Ef.defaultProps={showCredit:!1};const Df={showPyroscopeLogo:!1},Bf=(e,t)=>{if(t)return t;const n=null!=e?e:"auto";return"zh-CN"===("auto"===n?"undefined"!=typeof navigator&&navigator.language&&navigator.language.toLowerCase().startsWith("zh")?"zh-CN":"en":n)?Qi:Ji},Lf=t=>{const{i18n:n,locale:r,colorMode:o="light",sandwich:i=!0,...l}=t,s=a.useMemo(()=>Bf(r,n),[r,n]),c=a.useMemo(()=>(e=>{switch(e){case"dark":return"ps-theme-dark";case"kylin":return"ps-theme-kylin";default:return"ps-theme-light"}})(o),[o]);return e("pyro-flamegraph",{className:c,children:e(Zi,{messages:s,children:e(Ef,{...Df,enableSandwichView:i,...l})})})};function Af(e){const t={numTicks:0,maxSelf:0,names:[],levels:[]},n={},a={children:[]};return e.spans.forEach(e=>{e.children=[],n[e.spanID]=e}),e.spans.forEach(e=>{let t=a;e.references&&e.references.length>0&&(t=n[e.references[0].spanID]||a),t.children.push(e)}),function e(t,n){(t.children||[]).forEach(t=>e(t));let a=0;const r=E(t.children||[],e=>e.operationName);t.children=D(r,e=>{const t=e[0];for(let n=1;n<e.length;n+=1)t.duration+=e[n].duration;return a+=t.duration,t}),t.total=t.duration||a,t.self=Math.max(0,t.total-a)}(a),function n(a,r,o){var i;return t.numTicks||(t.numTicks=a.total),(i=t.levels)[r]||(i[r]=[]),t.levels[r].push(o),t.levels[r].push(a.total),t.levels[r].push(a.self),t.names.push((a.processID?`${e.processes[a.processID].serviceName}: `:"")+(a.operationName||"total")),t.levels[r].push(t.names.length-1),(a.children||[]).forEach(e=>{o+=n(e,r+1,o)}),a.total}(a,0,0),t.levels=Ff("single",t.levels),{version:1,flamebearer:t,metadata:{format:"single",units:"trace_samples",spyName:"tracing",sampleRate:1e6}}}function Of(e,t){e.flamebearer.levels=If("single",e.flamebearer.levels),t.flamebearer.levels=If("single",t.flamebearer.levels);const n=function(e,t){const n={format:"double",numTicks:e.numTicks+t.numTicks,leftTicks:e.numTicks,rightTicks:t.numTicks,maxSelf:100,sampleRate:e.sampleRate,names:[],levels:[],units:e.units,spyName:e.spyName},a=mf(e,t),r=(e,t,a,o)=>{var i;const{name:l,children:s,self:c,total:f}=e;n.names.push(l),(i=n.levels)[t]||(i[t]=[]),n.maxSelf=Math.max(n.maxSelf,c[0]||0,c[1]||0),n.levels[t]=n.levels[t].concat([a,f[0]||0,c[0]||0,o,f[1]||0,c[1]||0,n.names.length-1]);for(let e=0;e<s.length;e+=1){const[n,i]=r(s[e],t+1,a,o);a+=n,o+=i}return[f[0]||0,f[1]||0]};return r(a,0,0,0),n}(e.flamebearer,t.flamebearer);n.levels=Ff("double",n.levels);const a={...e.metadata};return a.format="double",{version:1,flamebearer:n,metadata:a,leftTicks:e.flamebearer.numTicks,rightTicks:t.flamebearer.numTicks}}export{br as Box,$i as DefaultPalette,fo as Flamegraph,Zi as FlamegraphI18nProvider,Lf as FlamegraphRenderer,Af as convertJaegerTraceToProfile,Of as diffTwoProfiles,Ji as flamegraphDefaultMessages,Qi as flamegraphZhCNMessages};
|
|
17
|
+
*/var mu,pu=(du||(du=1,function(e){!function(){var t={}.hasOwnProperty;function n(){for(var e="",t=0;t<arguments.length;t++){var n=arguments[t];n&&(e=a(e,r(n)))}return e}function r(e){if("string"==typeof e||"number"==typeof e)return e;if("object"!=typeof e)return"";if(Array.isArray(e))return n.apply(null,e);if(e.toString!==Object.prototype.toString&&!e.toString.toString().includes("[native code]"))return e.toString();var r="";for(var o in e)t.call(e,o)&&e[o]&&(r=a(r,o));return r}function a(e,t){return t?e?e+" "+t:e+t:e}e.exports?(n.default=n,e.exports=n):window.classNames=n}()}(hu)),hu.exports),gu=j(pu),vu={};function bu(){return mu||(mu=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="crosshairs",n=[],r="f05b",a="M288-16c17.7 0 32 14.3 32 32l0 18.3c98.1 14 175.7 91.6 189.7 189.7l18.3 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-18.3 0c-14 98.1-91.6 175.7-189.7 189.7l0 18.3c0 17.7-14.3 32-32 32s-32-14.3-32-32l0-18.3C157.9 463.7 80.3 386.1 66.3 288L48 288c-17.7 0-32-14.3-32-32s14.3-32 32-32l18.3 0C80.3 125.9 157.9 48.3 256 34.3L256 16c0-17.7 14.3-32 32-32zM131.2 288c12.7 62.7 62.1 112.1 124.8 124.8l0-12.8c0-17.7 14.3-32 32-32s32 14.3 32 32l0 12.8c62.7-12.7 112.1-62.1 124.8-124.8L432 288c-17.7 0-32-14.3-32-32s14.3-32 32-32l12.8 0C432.1 161.3 382.7 111.9 320 99.2l0 12.8c0 17.7-14.3 32-32 32s-32-14.3-32-32l0-12.8C193.3 111.9 143.9 161.3 131.2 224l12.8 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-12.8 0zM288 208a48 48 0 1 1 0 96 48 48 0 1 1 0-96z";e.definition={prefix:"fas",iconName:t,icon:[576,512,n,r,a]},e.faCrosshairs=e.definition,e.prefix="fas",e.iconName=t,e.width=576,e.height=512,e.ligatures=n,e.unicode=r,e.svgPathData=a,e.aliases=n}(vu)),vu}var yu,wu=bu(),xu={};function ku(){return yu||(yu=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="chevron-left",n=[9001],r="f053",a="M9.4 233.4c-12.5 12.5-12.5 32.8 0 45.3l192 192c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L77.3 256 246.6 86.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0l-192 192z";e.definition={prefix:"fas",iconName:t,icon:[320,512,n,r,a]},e.faChevronLeft=e.definition,e.prefix="fas",e.iconName=t,e.width=320,e.height=512,e.ligatures=n,e.unicode=r,e.svgPathData=a,e.aliases=n}(xu)),xu}var _u,Nu=ku(),Su={};function Mu(){return _u||(_u=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="chevron-right",n=[9002],r="f054",a="M311.1 233.4c12.5 12.5 12.5 32.8 0 45.3l-192 192c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3L243.2 256 73.9 86.6c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0l192 192z";e.definition={prefix:"fas",iconName:t,icon:[320,512,n,r,a]},e.faChevronRight=e.definition,e.prefix="fas",e.iconName=t,e.width=320,e.height=512,e.ligatures=n,e.unicode=r,e.svgPathData=a,e.aliases=n}(Su)),Su}var Tu=Mu(),Cu="Table-module_table__6A8SM",ju="Table-module_sortable__J6kyp",Ou="Table-module_sortArrow__Nrncn",Ru="Table-module_sortArrowUp__WmbEG",Pu="Table-module_sortArrowDown__Gyue1",Eu="Table-module_asc__tJDI9",Fu="Table-module_desc__fjVRY",Au="Table-module_isRowSelected__UhIAJ",Iu="Table-module_isRowDisabled__sz3NJ",Du="Table-module_virtualSpacer__C1hxH",Bu="Table-module_active__EShS8",Lu="Table-module_loadingSpinner__SSjMK",$u="Table-module_pagination__VXgcO",zu="Button-module_button__Ed1ge",Vu="Button-module_noIcon__Uzjvv",Hu="Button-module_noBox__mLreC",Wu="Button-module_customIcon__-slpC",Uu="Button-module_iconWithText__DQRkr",Ju="Button-module_default__HhXlQ",Qu="Button-module_outline__Flf4r",qu="Button-module_float__4marx",Xu="Button-module_primary__xByv0",Yu="Button-module_secondary__D0K-F",Ku="Button-module_danger__5-vIq",Zu="Button-module_grouped__j8KwB";const Gu=r.forwardRef(function({disabled:n=!1,kind:r="default",type:a="button",icon:o,iconNode:i,children:l,grouped:s,onClick:c,id:u,className:f,form:d,noBox:h,autoFocus:m,...p},g){return t("button",{...p,id:u,ref:g,type:a,"data-testid":p["data-testid"],disabled:n,onClick:c,form:d,autoFocus:m,"aria-label":p["aria-label"],className:gu(zu,s?Zu:"",ef(r),f,h&&Hu,i&&Wu,!o&&!i&&Vu),children:[o?e(ca,{icon:o,className:l?Uu:""}):null,i,l]})});function ef(e){switch(e){case"default":return Ju;case"primary":return Xu;case"secondary":return Yu;case"danger":return Ku;case"outline":return Qu;case"float":return qu;default:throw Error(`Unsupported kind ${e}`)}}function tf({row:t}){const{cells:n,isRowSelected:r,isRowDisabled:a,className:o,onClick:i,onDoubleClick:l,onContextMenu:s,...u}=t,f=c(Math.random()).current;return e("tr",{...u,onClick:i,onDoubleClick:l,onContextMenu:s,className:Fl(o,{[Au]:r,[Iu]:a}),children:n&&n.map(({style:t,value:n,...r},a)=>e("td",{style:t,...r,children:n},f+a))})}function nf({sortByDirection:r,sortBy:a,updateSortParams:o,table:i,tableBodyRef:l,className:u,isLoading:h,itemsPerPage:m,virtualize:p,virtualizeRowHeight:g,virtualizeOverscan:v=6,scrollRef:b,disableSort:y}){const x=!y&&r&&a&&o,[k,_]=s(0),[N,S]=s(0),[M,T]=s(null),[C,j]=s(null),O=c(null),R=c(null);f(()=>{(null==b?void 0:b.current)&&b.current!==C&&j(b.current)},[null==b?void 0:b.current,C]),d(()=>{if(!C||!p)return()=>{};const e=()=>{O.current&&cancelAnimationFrame(O.current),O.current=requestAnimationFrame(()=>{S(C.scrollTop||0)})};return C.addEventListener("scroll",e,{passive:!0}),()=>{C.removeEventListener("scroll",e),O.current&&cancelAnimationFrame(O.current)}},[C,p]),d(()=>{if(!p||M||!(null==l?void 0:l.current))return;const e=l.current.querySelectorAll("tr[data-row]");if(!e.length)return;const t=e[0].getBoundingClientRect();t.height&&T(t.height)},[p,M,null==l?void 0:l.current,i]);const P="filled"===i.type?rf(i.bodyRows,k,m):null,E="virtual"===i.type?i.rowCount:P?P.length:0,F=g||M||26,A=!!p&&!!C&&("filled"===i.type||"virtual"===i.type)&&F>0,I=A?(()=>{const e=C.clientHeight||0,t=Math.max(0,Math.floor(N/F)-v),n=Math.min(E,Math.ceil((N+e)/F)+v),r=t*F,a=Math.max(0,(E-n)*F),o="filled"===i.type&&P?P.slice(t,n):[];return{viewportHeight:e,totalRows:E,startIndex:t,endIndex:n,topSpacer:r,bottomSpacer:a,visibleRows:o}})():null,D=!!p&&!A&&"filled"===i.type,B=D?(P||[]).slice(0,Math.max(24,4*v)):null;d(()=>{var e;"virtual"===i.type&&I&&(null===(e=i.onRangeChange)||void 0===e||e.call(i,I.startIndex,I.endIndex))},[i,null==I?void 0:I.startIndex,null==I?void 0:I.endIndex]);const L="virtual"===i.type&&I?Math.max(0,I.endIndex-I.startIndex):0,$="virtual"===i.type&&L>0?Array.from({length:L},()=>({cells:Array.from({length:i.headRow.length},()=>({value:" "}))})):[],z="virtual"===i.type&&I&&i.range&&i.range.start===I.startIndex&&i.range.end===I.endIndex;"virtual"===i.type&&z&&(R.current=i.rows);const V="virtual"===i.type?z?i.rows:R.current||$:$;return h?e("div",{className:Lu}):t(n,{children:[t("table",{className:Fl(Cu,{[u||""]:u}),"data-testid":"table-ui",children:[e("thead",{children:e("tr",{children:i.headRow.map(({sortable:n,label:l,name:s,...c},u)=>n&&"not-filled"!==i.type&&x?w("th",{...c,key:u,className:ju,onClick:()=>o(s)},l,t("span",{className:Fl(Ou,{[Bu]:a===s,[Eu]:a===s&&"asc"===r,[Fu]:a===s&&"desc"===r}),children:[e("span",{className:Ru}),e("span",{className:Pu})]})):e("th",{...c,children:l},u))})}),e("tbody",{ref:l,children:"not-filled"===i.type?e("tr",{className:null==i?void 0:i.bodyClassName,children:e("td",{colSpan:i.headRow.length,children:i.value})}):I?t(n,{children:[I.topSpacer>0&&e("tr",{"aria-hidden":"true",className:Du,children:e("td",{colSpan:i.headRow.length,style:{height:I.topSpacer,padding:0,border:0}})}),("virtual"===i.type?V:I.visibleRows).map((t,n)=>{var r;return e(tf,{row:t},null!==(r=t["data-row"])&&void 0!==r?r:`row-${I.startIndex+n}`)}),I.bottomSpacer>0&&e("tr",{"aria-hidden":"true",className:Du,children:e("td",{colSpan:i.headRow.length,style:{height:I.bottomSpacer,padding:0,border:0}})})]}):D?(B||[]).map((t,n)=>{var r;return e(tf,{row:t},null!==(r=t["data-row"])&&void 0!==r?r:`row-${n}`)}):(P||[]).map((t,n)=>{var r;return e(tf,{row:t},null!==(r=t["data-row"])&&void 0!==r?r:`row-${n}`)})})]}),e(af,{bodyRows:"filled"===i.type?i.bodyRows:void 0,itemsPerPage:m,currPage:k,setCurrPage:_})]})}function rf(e,t,n){return n?e.slice(t*n,n*(t+1)):e}function af({itemsPerPage:n,currPage:r,setCurrPage:a,bodyRows:o}){if(!n)return null;const i=!!o&&rf(o,r+1,n).length>0,l=!!o&&rf(o,r-1,n).length>0;return t("nav",{className:$u,children:[e(Gu,{"aria-label":"Previous Page",disabled:!l,kind:"float",icon:Nu.faChevronLeft,onClick:()=>a(r-1)}),e(Gu,{disabled:!i,"aria-label":"Next Page",kind:"float",icon:Tu.faChevronRight,onClick:()=>a(r+1)})]})}function of({numTicks:t,sampleRate:n,units:r,tableBodyRef:a,palette:o}){const i=ao(t,n,r),l=i.format(t,n),s=Tc(),c=u((e,t,a)=>{var c;const u=null===(c=a.target.closest("tr"))||void 0===c?void 0:c.dataset.row;if(!u)return void t();const[f,d,...h]=u.split(";");switch(f){case"single":{const[t,a]=h,o=i.format(parseInt(t,10),n),s=i.format(parseInt(a,10),n),c=l.split(" "),u="<"===c[0]?c[1]:c[0],f=o.split(" "),m="<"===f[0]?f[1]:f[0],p=s.split(" "),g="<"===p[0]?p[1]:p[0];e({title:{text:d,diff:{text:"",color:""}},tooltipData:[{units:r,self:`${o}(${(parseFloat(m)/parseFloat(u)*100).toFixed(2)}%)`,total:`${s}(${(parseFloat(g)/parseFloat(u)*100).toFixed(2)}%)`,tooltipType:"table"}]});break}case"double":{const[t,a,l,c]=h,u=Ic({formatter:i,sampleRate:n,totalLeft:parseInt(t,10),leftTicks:parseInt(a,10),totalRight:parseInt(l,10),rightTicks:parseInt(c,10),title:d,units:r},o,s);e({title:u.title,tooltipData:u.tooltipData});break}}},[i,n,r,l,o,s]);return e(Pc,{dataSourceRef:a,shouldShowTitle:!1,clickInfoSide:"left",setTooltipContent:c,palette:o})}function lf(){const e=new Blob([`(${(()=>{const e=e=>e||0,t={format:"single",jStep:4,jName:3,getBarTotal:(e,t)=>e[t+1],getBarSelf:(e,t)=>e[t+2],getBarName:(e,t)=>e[t+3]},n={format:"double",jStep:7,jName:6,getBarTotal:(e,t)=>e[t+4]+e[t+1],getBarTotalLeft:(e,t)=>e[t+1],getBarTotalRght:(e,t)=>e[t+4],getBarSelf:(e,t)=>e[t+5]+e[t+2],getBarSelfLeft:(e,t)=>e[t+2],getBarSelfRght:(e,t)=>e[t+5],getBarName:(e,t)=>e[t+6]},r=e=>Math.round(1e4*e)/100,a=(e,t)=>(t-e)/e*100,o={baseRows:[],rows:[],bestNodeByName:new Map,sortBy:"total",sortByDirection:"desc",highlightQuery:"",format:"single",leftTicks:0,rightTicks:0},i=()=>{const e=o.highlightQuery.trim().toLowerCase(),t=e?o.baseRows.filter(t=>t.name.toLowerCase().includes(e)):o.baseRows.slice(),n="asc"===o.sortByDirection?1:-1;t.sort((e,t)=>{if("name"===o.sortBy)return n*e.name.localeCompare(t.name);switch(o.sortBy){case"total":case"self":{const r=e[o.sortBy]||0,a=t[o.sortBy]||0;return n*(r-a)}case"baseline":{const r=e.leftTicks>0?e.totalLeft/e.leftTicks:0,a=t.leftTicks>0?t.totalLeft/t.leftTicks:0;return n*(r-a)}case"comparison":{const r=e.rightTicks>0?e.totalRght/e.rightTicks:0,a=t.rightTicks>0?t.totalRght/t.rightTicks:0;return n*(r-a)}case"diff":{const o=e.leftTicks>0?e.totalLeft/e.leftTicks:0,i=e.rightTicks>0?e.totalRght/e.rightTicks:0,l=t.leftTicks>0?t.totalLeft/t.leftTicks:0,s=t.rightTicks>0?t.totalRght/t.rightTicks:0,c=a(r(o),r(i)),u=a(r(l),r(s));return n*(c-u)}default:return 0}}),o.rows=t},l=r=>{const{rows:a,bestNodeByName:l,format:s,leftTicks:c,rightTicks:u}=(r=>{const{names:a,levels:o,format:i}=r,l=new Map,s=new Map,c=r.leftTicks||0,u=r.rightTicks||0;if("double"===i){const t=n;for(let n=0;n<o.length;n+=1){const r=o[n];for(let o=0;o<r.length;o+=t.jStep){const i=a[t.getBarName(r,o)]||"<empty>";l.has(i)||l.set(i,{type:"double",name:i,totalLeft:0,totalRght:0,leftTicks:c,rightTicks:u});const f=l.get(i);if(!f)continue;f.totalLeft=e(f.totalLeft)+t.getBarTotalLeft(r,o),f.totalRght=e(f.totalRght)+t.getBarTotalRght(r,o);const d=t.getBarTotal(r,o),h=s.get(i);(!h||d>h.total)&&s.set(i,{i:n,j:o,total:d})}}}else{const n=t;for(let t=0;t<o.length;t+=1){const r=o[t];for(let o=0;o<r.length;o+=n.jStep){const i=a[n.getBarName(r,o)]||"<empty>";l.has(i)||l.set(i,{type:"single",name:i,self:0,total:0});const c=l.get(i);if(!c)continue;c.self=e(c.self)+n.getBarSelf(r,o),c.total=e(c.total)+n.getBarTotal(r,o);const u=n.getBarTotal(r,o),f=s.get(i);(!f||u>f.total)&&s.set(i,{i:t,j:o,total:u})}}}return{rows:Array.from(l.values()),bestNodeByName:s,format:i,leftTicks:c,rightTicks:u}})(r.flamebearer);o.baseRows=a,o.bestNodeByName=l,o.format=s,o.leftTicks=c,o.rightTicks=u,o.sortBy=r.sortBy,o.sortByDirection=r.sortByDirection,o.highlightQuery=r.highlightQuery||"",i(),self.postMessage({type:"ready",payload:{rowCount:o.rows.length}})};self.onmessage=e=>{const t=e.data;var n;if(t&&t.type)switch(t.type){case"init":l(t.payload);break;case"update":n=t.payload,o.sortBy=n.sortBy,o.sortByDirection=n.sortByDirection,o.highlightQuery=n.highlightQuery||"",i(),self.postMessage({type:"ready",payload:{rowCount:o.rows.length}});break;case"range":(e=>{const{start:t,end:n,requestId:r}=e,a=Math.max(0,t),i=Math.min(o.rows.length,n),l=o.rows.slice(a,i);self.postMessage({type:"range",payload:{rows:l,start:a,end:i,requestId:r}})})(t.payload);break;case"findNode":(e=>{const{name:t,requestId:n}=e,r=o.bestNodeByName.get(t);self.postMessage({type:"findNode",payload:{node:r?{i:r.i,j:r.j}:null,requestId:n}})})(t.payload)}}}).toString()})()`],{type:"text/javascript"});return new Worker(URL.createObjectURL(e))}var sf="ProfilerTable-module_tableContextMenu__7Svm8",cf="ProfilerTable-module_sandwichItem__b9Ipy";const uf=e=>e||0,ff="undefined"!=typeof Worker&&"undefined"!=typeof Blob&&"undefined"!=typeof URL;function df(e,t,n,r){const a=t;return a.type="single",a.self=uf(a.self)+e.getBarSelf(n,r),a.total=uf(a.total)+e.getBarTotal(n,r),a}function hf(e,t,n,r,a,o){const i=t;return i.type="double",i.self=uf(i.self)+e.getBarSelf(n,r),i.total=uf(i.total)+e.getBarTotal(n,r),i.selfLeft=uf(i.selfLeft)+e.getBarSelfLeft(n,r),i.selfRght=uf(i.selfRght)+e.getBarSelfRght(n,r),i.selfDiff=uf(i.selfDiff)+e.getBarSelfDiff(n,r),i.totalLeft=uf(i.totalLeft)+e.getBarTotalLeft(n,r),i.totalRght=uf(i.totalRght)+e.getBarTotalRght(n,r),i.totalDiff=uf(i.totalDiff)+e.getBarTotalDiff(n,r),i.leftTicks=a,i.rightTicks=o,i}const mf=new WeakMap;function pf(e){const t=mf.get(e);if(t)return t;const n=function(e){if(!e)return[];const{names:t,levels:n,format:r}=e,a="double"!==r?Va:Ha,o=new Map;for(let i=0;i<n.length;i++){const l=n[i];for(let n=0;n<l.length;n+=a.jStep){const i=t[a.getBarName(l,n)];o.has(i)||o.set(i,{name:i||"<empty>",self:0,total:0});const s=o.get(i);if(!s)break;"single"===r?df(Va,s,l,n):hf(Ha,s,l,n,e.leftTicks,e.rightTicks)}}return Array.from(o.values())}(e);return mf.set(e,n),n}function gf(e,t,n){const r=148-e/t*148,a=n.alpha(1);return{backgroundImage:`linear-gradient(${a}, ${a})`,backgroundPosition:`-${r}px 0px`,backgroundRepeat:"no-repeat"}}const vf=({flamebearer:t,sortBy:n,sortByDirection:r,fitMode:a,handleTableItemClick:o,highlightQuery:i,palette:l,selectedItem:s,messages:c,onRowContextMenu:u,onRowDoubleClick:f})=>{const{numTicks:d,maxSelf:h,sampleRate:m,spyName:p,units:g}=t,v=[...pf(t)].sort((e,t)=>t.total-e.total),b="asc"===r?1:-1;let y;if("name"===n)y=v.sort((e,t)=>b*e[n].localeCompare(t[n]));else switch(n){case"total":case"self":y=v.sort((e,t)=>b*(e[n]-t[n]));break;case"baseline":y=v.sort((e,t)=>b*(e.totalLeft/e.leftTicks-t.totalLeft/t.leftTicks));break;case"comparison":y=v.sort((e,t)=>b*(e.totalRght/e.rightTicks-t.totalRght/t.rightTicks));break;case"diff":y=v.sort((e,t)=>{const n=ro(no(e.totalLeft/e.leftTicks),no(e.totalRght/e.rightTicks)),r=ro(no(t.totalLeft/t.leftTicks),no(t.totalRght/t.rightTicks));return b*(n-r)});break;default:y=v}const w=ao(d,m,g),x=e=>!!s.isJust&&e===s.value,k=t=>e("button",{className:"table-item-button",children:e("div",{className:"symbol-name",style:ho(a),children:e("bdi",{dir:"ltr",children:t.name})})}),_=y.filter(e=>{return!i||(t=i,e.name.toLowerCase().includes(t.toLowerCase()));var t}).map(e=>{if("double"===e.type)return(e=>{const t=no(e.leftTicks>0?e.totalLeft/e.leftTicks:0),n=no(e.rightTicks>0?e.totalRght/e.rightTicks:0);let r=ro(t,n);Number.isFinite(r)||(r=0);let a="";r>0?a=l.badColor.rgb().string():r<0&&(a=l.goodColor.rgb().string());let i="";return 0===e.totalLeft&&e.totalRght>0?i=c.diffNew:0===e.totalRght&&e.totalLeft>0?i=c.diffRemoved:0===r?i="0%":r>0?i=`+${r.toFixed(2)}%`:r<0&&(i=`${r.toFixed(2)}%`),{"data-row":`${e.type};${e.name};${e.totalLeft};${e.leftTicks};${e.totalRght};${e.rightTicks}`,isRowSelected:x(e.name),onClick:()=>o(e),onContextMenu:t=>u(t,e.name),onDoubleClick:()=>f(e.name),cells:[{value:k(e)},{value:`${t} %`},{value:`${n} %`},{value:i,style:{color:a}}]}})(e);const t=wl(p,e.name);return((e,t)=>({"data-row":`${e.type};${e.name};${e.self};${e.total}`,isRowSelected:x(e.name),onClick:()=>o(e),onContextMenu:t=>u(t,e.name),onDoubleClick:()=>f(e.name),cells:[{value:k(e)},{value:w.format(e.self,m),style:gf(e.self,h,t)},{value:w.format(e.total,m),style:gf(e.total,d,t)}]}))(e,xl(l,t))});return _.length>0?{bodyRows:_,type:"filled"}:{value:e("div",{className:"unsupported-format",children:c.noItemsFound}),type:"not-filled"}};function bf({tableBodyRef:a,flamebearer:i,isDoubles:l,fitMode:f,handleTableItemClick:h,highlightQuery:m,selectedItem:p,palette:g,onFocusOnNode:v,updateView:b,enableSandwichView:y=!0,virtualize:w,virtualizeRowHeight:x,virtualizeOverscan:k,scrollRef:_,menuPortalTarget:N}){const S=Tc(),[M,T]=qs({transition:!0}),[C,j]=s({x:0,y:0}),[O,R]=s(null),P=ff,E=c(null),F=c(null),A=c(0),I=c(0),D=c(new Map),[B,L]=s(!1),[$,z]=s(0),[V,H]=s([]),[W,U]=s({start:0,end:0}),[J,Q]=s(null),[q,X]=s(0),[Y,K]=s(0);d(()=>{if(!P)return()=>{};const e=lf();E.current=e,K(e=>e+1);const t=e=>{const t=e.data;if(t&&t.type)switch(t.type){case"ready":z(t.payload.rowCount),L(!0),X(e=>e+1);break;case"range":if(t.payload.requestId!==A.current)return;H(t.payload.rows),U({start:t.payload.start,end:t.payload.end});break;case"findNode":{const e=D.current.get(t.payload.requestId);e&&(D.current.delete(t.payload.requestId),e(t.payload.node));break}}};return e.addEventListener("message",t),()=>{e.removeEventListener("message",t),e.terminate(),E.current=null,D.current.clear()}},[P]);const Z=u(e=>{if(!P||!E.current)return Promise.resolve(function(e,t){if(!e||!e.levels)return null;const{names:n,levels:r,format:a}=e,o=Wa(a);let i=null;for(let e=0;e<r.length;e++){const a=r[e];for(let r=0;r<a.length;r+=o.jStep)if(n[o.getBarName(a,r)]===t){const t=o.getBarTotal(a,r);(!i||t>i.total)&&(i={i:e,j:r,total:t})}}return i?{i:i.i,j:i.j}:null}(i,e));const t=++I.current;return new Promise(n=>{var r;D.current.set(t,n),null===(r=E.current)||void 0===r||r.postMessage({type:"findNode",payload:{name:e,requestId:t}})})},[i,P]),G=u(e=>{v&&Z(e).then(e=>{e&&v(e.i,e.j)})},[v,Z]),ee=u(e=>{p.isJust&&p.value===e||h({name:e}),G(e)},[G,p,h]),te=u((e,t)=>{e.preventDefault(),j({x:e.clientX,y:e.clientY}),R(t),T(!0)},[T]),ne=u(()=>{T(!1),R(null)},[T]),re=u(()=>{O&&(G(O),ne())},[O,G,ne]),ae=u(()=>{O&&navigator.clipboard&&(navigator.clipboard.writeText(O),ne())},[O,ne]),oe=u(()=>{O&&(h({name:O}),ne())},[O,h,ne]),ie=u(()=>{O&&b&&(b("sandwich"),h({name:O}),ne())},[O,b,h,ne]),le=r.useMemo(()=>l?[{sortable:1,name:"name",label:S.location},{sortable:1,name:"baseline",label:S.baseline,default:!0},{sortable:1,name:"comparison",label:S.comparison},{sortable:1,name:"diff",label:S.diff}]:[{sortable:1,name:"name",label:S.location},{sortable:1,name:"self",label:S.self,default:!0},{sortable:1,name:"total",label:S.total}],[S,l]),se=(e=>{const t=e.filter(e=>null==e?void 0:e.default)[0]||e[0],[n,r]=s(t.name),[a,o]=s("desc");return{sortBy:n,sortByDirection:a,updateSortParams:e=>{let t=a;t=n===e?"asc"===t?"desc":"asc":"desc",r(e),o(t)}}})(le);d(()=>{if(!P||!E.current)return;const e=E.current,t={sortBy:se.sortBy,sortByDirection:se.sortByDirection,highlightQuery:m};F.current!==i?(F.current=i,L(!1),z(0),H([]),e.postMessage({type:"init",payload:{flamebearer:i,...t}})):e.postMessage({type:"update",payload:t})},[i,m,se.sortBy,se.sortByDirection,P,Y]);const ce=u((e,t)=>{Q(n=>n&&n.start===e&&n.end===t?n:{start:e,end:t})},[]);d(()=>{if(!P||!E.current||!J)return;const e=++A.current;E.current.postMessage({type:"range",payload:{start:J.start,end:J.end,requestId:e}})},[J,q,P]);const{numTicks:ue,maxSelf:fe,sampleRate:de,spyName:he,units:me}=i,pe=o(()=>ao(ue,de,me),[ue,de,me]),ge=o(()=>ho(f),[f]),ve=u(e=>p.isJust&&p.value===e,[p]),be=u(t=>e("button",{className:"table-item-button",children:e("div",{className:"symbol-name",style:ge,children:e("bdi",{dir:"ltr",children:t})})}),[ge]),ye=u(e=>{const t=wl(he,e.name),n=xl(g,t);return{"data-row":`single;${e.name};${e.self};${e.total}`,isRowSelected:ve(e.name),onClick:()=>{h({name:e.name})},onContextMenu:t=>te(t,e.name),onDoubleClick:()=>ee(e.name),cells:[{value:be(e.name)},{value:pe.format(e.self,de),style:gf(e.self,fe,n)},{value:pe.format(e.total,de),style:gf(e.total,ue,n)}]}},[pe,te,ee,h,ve,fe,be,ue,g,de,he]),we=u(e=>{const t=no(e.leftTicks>0?e.totalLeft/e.leftTicks:0),n=no(e.rightTicks>0?e.totalRght/e.rightTicks:0);let r=ro(t,n);Number.isFinite(r)||(r=0);let a="";r>0?a=g.badColor.rgb().string():r<0&&(a=g.goodColor.rgb().string());let o="";return 0===e.totalLeft&&e.totalRght>0?o=S.diffNew:0===e.totalRght&&e.totalLeft>0?o=S.diffRemoved:0===r?o="0%":r>0?o=`+${r.toFixed(2)}%`:r<0&&(o=`${r.toFixed(2)}%`),{"data-row":`double;${e.name};${e.totalLeft};${e.leftTicks};${e.totalRght};${e.rightTicks}`,isRowSelected:ve(e.name),onClick:()=>{h({name:e.name})},onContextMenu:t=>te(t,e.name),onDoubleClick:()=>ee(e.name),cells:[{value:be(e.name)},{value:`${t} %`},{value:`${n} %`},{value:o,style:{color:a}}]}},[te,ee,h,S,ve,be,g]),xe=o(()=>P?V.map(e=>"double"===e.type?we(e):ye(e)):[],[we,ye,P,V]),ke=o(()=>P?B&&0===$?{headRow:le,type:"not-filled",value:e("div",{className:"unsupported-format",children:S.noItemsFound})}:{headRow:le,type:"virtual",rowCount:$,rows:xe,range:W,onRangeChange:ce}:{headRow:le,...vf({flamebearer:i,sortBy:se.sortBy,sortByDirection:se.sortByDirection,fitMode:f,handleTableItemClick:h,highlightQuery:m,palette:g,selectedItem:p,messages:S,onRowContextMenu:te,onRowDoubleClick:ee})},[we,ye,y,f,i,te,ee,ce,h,m,S,v,g,$,p,le,se.sortBy,se.sortByDirection,b,P,xe,W,B]),_e=p.isJust&&p.value===O;return t(n,{children:[e(nf,{...se,tableBodyRef:a,table:ke,isLoading:P&&!B,className:gu("flamegraph-table",{"flamegraph-table-doubles":l}),virtualize:w,virtualizeRowHeight:x,virtualizeOverscan:k,scrollRef:_}),t(Vs,{...M,anchorPoint:C,onClose:ne,className:sf,portal:!N||{target:N},children:[v&&t(Gs,{onClick:re,children:[e(ca,{icon:wu.faCrosshairs}),S.focusOnThisFunction]}),t(Gs,{onClick:ae,children:[e(ca,{icon:ql.faCopy}),S.copyFunctionName]}),t(Gs,{onClick:oe,children:[e(ca,{icon:Gl.faHighlighter}),_e?S.clearHighlight:S.highlightSimilarNodes]}),b&&y&&t(Gs,{onClick:ie,className:cf,children:[e(Wc,{fill:"currentColor"}),S.openInSandwichView]})]})]})}const yf=r.memo(function({flamebearer:n,fitMode:r,handleTableItemClick:a,highlightQuery:o,palette:i,selectedItem:l,onFocusOnNode:u,updateView:f,enableSandwichView:h}){const m=c(null),p=c(null),g=c(null),[v,b]=s(0),[y,w]=s(null),x="double"===n.format;return d(()=>{const e=m.current;if(!e)return;const t=e.offsetWidth-e.clientWidth;Number.isFinite(t)&&t!==v&&b(t)},[m.current,x,v]),d(()=>{const e=p.current;if(!e||"undefined"==typeof document)return;const t=e.closest("[data-theme], [data-flamegraph-color-mode]")||e,n=document.createElement("div");return n.className="flamegraph-menu-portal",t.appendChild(n),w(n),()=>{n.parentElement&&n.parentElement.removeChild(n)}},[]),t("div",{"data-testid":"table-view",ref:p,style:{"--kylin-flamegraph-scrollbar-size":`${v}px`},className:x?"flamegraph-table-wrapper flamegraph-table-wrapper--double":"flamegraph-table-wrapper",children:[e("div",{className:"flamegraph-table-scroll",ref:g,children:e(bf,{tableBodyRef:m,flamebearer:n,isDoubles:x,fitMode:r,highlightQuery:o,handleTableItemClick:a,palette:i,selectedItem:l,onFocusOnNode:u,updateView:f,enableSandwichView:h,virtualize:!0,virtualizeOverscan:8,scrollRef:g,menuPortalTarget:y})}),e(of,{tableBodyRef:m,numTicks:n.numTicks,sampleRate:n.sampleRate,units:n.units,palette:i})]})});var wf,xf,kf={},_f={};function Nf(){return wf||(wf=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="arrow-rotate-left",n=[8634,"arrow-left-rotate","arrow-rotate-back","arrow-rotate-backward","undo"],r="f0e2",a="M256 64c-56.8 0-107.9 24.7-143.1 64l47.1 0c17.7 0 32 14.3 32 32s-14.3 32-32 32L32 192c-17.7 0-32-14.3-32-32L0 32C0 14.3 14.3 0 32 0S64 14.3 64 32l0 54.7C110.9 33.6 179.5 0 256 0 397.4 0 512 114.6 512 256S397.4 512 256 512c-87 0-163.9-43.4-210.1-109.7-10.1-14.5-6.6-34.4 7.9-44.6s34.4-6.6 44.6 7.9c34.8 49.8 92.4 82.3 157.6 82.3 106 0 192-86 192-192S362 64 256 64z";e.definition={prefix:"fas",iconName:t,icon:[512,512,n,r,a]},e.faArrowRotateLeft=e.definition,e.prefix="fas",e.iconName=t,e.width=512,e.height=512,e.ligatures=n,e.unicode=r,e.svgPathData=a,e.aliases=n}(_f)),_f}function Sf(){return xf||(xf=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t=Nf();e.definition={prefix:t.prefix,iconName:t.iconName,icon:[t.width,t.height,t.aliases,t.unicode,t.svgPathData]},e.faUndo=e.definition,e.prefix=t.prefix,e.iconName=t.iconName,e.width=t.width,e.height=t.height,e.ligatures=t.aliases,e.unicode=t.unicode,e.svgPathData=t.svgPathData,e.aliases=t.aliases}(kf)),kf}var Mf,Tf,Cf=Sf(),jf={},Of={};function Rf(){return Mf||(Mf=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="diagram-project",n=["project-diagram"],r="f542",a="M0 80C0 53.5 21.5 32 48 32l96 0c26.5 0 48 21.5 48 48l0 16 128 0 0-16c0-26.5 21.5-48 48-48l96 0c26.5 0 48 21.5 48 48l0 96c0 26.5-21.5 48-48 48l-96 0c-26.5 0-48-21.5-48-48l0-16-128 0 0 16c0 7.3-1.7 14.3-4.6 20.5l68.6 91.5 80 0c26.5 0 48 21.5 48 48l0 96c0 26.5-21.5 48-48 48l-96 0c-26.5 0-48-21.5-48-48l0-96c0-7.3 1.7-14.3 4.6-20.5L128 224 48 224c-26.5 0-48-21.5-48-48L0 80z";e.definition={prefix:"fas",iconName:t,icon:[512,512,n,r,a]},e.faDiagramProject=e.definition,e.prefix="fas",e.iconName=t,e.width=512,e.height=512,e.ligatures=n,e.unicode=r,e.svgPathData=a,e.aliases=n}(Of)),Of}function Pf(){return Tf||(Tf=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t=Rf();e.definition={prefix:t.prefix,iconName:t.iconName,icon:[t.width,t.height,t.aliases,t.unicode,t.svgPathData]},e.faProjectDiagram=e.definition,e.prefix=t.prefix,e.iconName=t.iconName,e.width=t.width,e.height=t.height,e.ligatures=t.aliases,e.unicode=t.unicode,e.svgPathData=t.svgPathData,e.aliases=t.aliases}(jf)),jf}var Ef,Ff,Af=Pf(),If={},Df={};function Bf(){return Ef||(Ef=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="ellipsis-vertical",n=["ellipsis-v"],r="f142",a="M64 144a56 56 0 1 1 0-112 56 56 0 1 1 0 112zm0 224c30.9 0 56 25.1 56 56s-25.1 56-56 56-56-25.1-56-56 25.1-56 56-56zm56-112c0 30.9-25.1 56-56 56s-56-25.1-56-56 25.1-56 56-56 56 25.1 56 56z";e.definition={prefix:"fas",iconName:t,icon:[128,512,n,r,a]},e.faEllipsisVertical=e.definition,e.prefix="fas",e.iconName=t,e.width=128,e.height=512,e.ligatures=n,e.unicode=r,e.svgPathData=a,e.aliases=n}(Df)),Df}function Lf(){return Ff||(Ff=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t=Bf();e.definition={prefix:t.prefix,iconName:t.iconName,icon:[t.width,t.height,t.aliases,t.unicode,t.svgPathData]},e.faEllipsisV=e.definition,e.prefix=t.prefix,e.iconName=t.iconName,e.width=t.width,e.height=t.height,e.ligatures=t.aliases,e.unicode=t.unicode,e.svgPathData=t.svgPathData,e.aliases=t.aliases}(If)),If}var $f=Lf(),zf="Tooltip-module_tooltipWrapper__leDK-",Vf="Tooltip-module_tooltipBubble__8vweF",Hf="Tooltip-module_tooltipArrow__7wGyN";function Wf(e){if(null!=e&&!1!==e){if("string"==typeof e||"number"==typeof e)return String(e);if(Array.isArray(e)){const t=e.map(e=>Wf(e)).filter(e=>!!e);return t.length?t.join(" "):void 0}return r.isValidElement(e)?Wf(e.props.children):void 0}}const Uf=({placement:r,title:a,content:o,children:i})=>{const l=Wf(null!=a?a:o),u=c(null),[f,h]=s(!1);return d(()=>{const e=u.current;if(!e)return;const t=e.closest("[data-theme='kylin'], [data-flamegraph-color-mode='kylin']");h(!!t)},[]),l?t("span",{ref:u,className:zf,"data-placement":r||"top","data-tooltip":f?l:void 0,title:f?void 0:l,children:[i,f?t("span",{className:Vf,role:"tooltip",children:[l,e("span",{className:Hf})]}):null]}):e(n,{children:i})};var Jf,Qf={};function qf(){return Jf||(Jf=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="link",n=[128279,"chain"],r="f0c1",a="M419.5 96c-16.6 0-32.7 4.5-46.8 12.7-15.8-16-34.2-29.4-54.5-39.5 28.2-24 64.1-37.2 101.3-37.2 86.4 0 156.5 70 156.5 156.5 0 41.5-16.5 81.3-45.8 110.6l-71.1 71.1c-29.3 29.3-69.1 45.8-110.6 45.8-86.4 0-156.5-70-156.5-156.5 0-1.5 0-3 .1-4.5 .5-17.7 15.2-31.6 32.9-31.1s31.6 15.2 31.1 32.9c0 .9 0 1.8 0 2.6 0 51.1 41.4 92.5 92.5 92.5 24.5 0 48-9.7 65.4-27.1l71.1-71.1c17.3-17.3 27.1-40.9 27.1-65.4 0-51.1-41.4-92.5-92.5-92.5zM275.2 173.3c-1.9-.8-3.8-1.9-5.5-3.1-12.6-6.5-27-10.2-42.1-10.2-24.5 0-48 9.7-65.4 27.1L91.1 258.2c-17.3 17.3-27.1 40.9-27.1 65.4 0 51.1 41.4 92.5 92.5 92.5 16.5 0 32.6-4.4 46.7-12.6 15.8 16 34.2 29.4 54.6 39.5-28.2 23.9-64 37.2-101.3 37.2-86.4 0-156.5-70-156.5-156.5 0-41.5 16.5-81.3 45.8-110.6l71.1-71.1c29.3-29.3 69.1-45.8 110.6-45.8 86.6 0 156.5 70.6 156.5 156.9 0 1.3 0 2.6 0 3.9-.4 17.7-15.1 31.6-32.8 31.2s-31.6-15.1-31.2-32.8c0-.8 0-1.5 0-2.3 0-33.7-18-63.3-44.8-79.6z";e.definition={prefix:"fas",iconName:t,icon:[576,512,n,r,a]},e.faLink=e.definition,e.prefix="fas",e.iconName=t,e.width=576,e.height=512,e.ligatures=n,e.unicode=r,e.svgPathData=a,e.aliases=n}(Qf)),Qf}var Xf,Yf,Kf=qf(),Zf={},Gf={};function ed(){return Xf||(Xf=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t="magnifying-glass",n=[128269,"search"],r="f002",a="M416 208c0 45.9-14.9 88.3-40 122.7L502.6 457.4c12.5 12.5 12.5 32.8 0 45.3s-32.8 12.5-45.3 0L330.7 376C296.3 401.1 253.9 416 208 416 93.1 416 0 322.9 0 208S93.1 0 208 0 416 93.1 416 208zM208 352a144 144 0 1 0 0-288 144 144 0 1 0 0 288z";e.definition={prefix:"fas",iconName:t,icon:[512,512,n,r,a]},e.faMagnifyingGlass=e.definition,e.prefix="fas",e.iconName=t,e.width=512,e.height=512,e.ligatures=n,e.unicode=r,e.svgPathData=a,e.aliases=n}(Gf)),Gf}function td(){return Yf||(Yf=1,function(e){Object.defineProperty(e,"__esModule",{value:!0});var t=ed();e.definition={prefix:t.prefix,iconName:t.iconName,icon:[t.width,t.height,t.aliases,t.unicode,t.svgPathData]},e.faSearch=e.definition,e.prefix=t.prefix,e.iconName=t.iconName,e.width=t.width,e.height=t.height,e.ligatures=t.aliases,e.unicode=t.unicode,e.svgPathData=t.svgPathData,e.aliases=t.aliases}(Zf)),Zf}var nd,rd,ad,od=td(),id={};function ld(){if(nd)return id;function e(t){return e="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},e(t)}nd=1,Object.defineProperty(id,"__esModule",{value:!0}),id.DebounceInput=void 0;var t=o(r),n=o(sc()),a=["element","onChange","value","minLength","debounceTimeout","forceNotifyByEnter","forceNotifyOnBlur","onKeyDown","onBlur","inputRef"];function o(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function l(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 s(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach(function(t){m(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function c(e,t,n){return t&&function(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,r.key,r)}}(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function u(e,t){return u=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},u(e,t)}function f(t){var n=function(){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}}();return function(){var r,a=h(t);if(n){var o=h(this).constructor;r=Reflect.construct(a,arguments,o)}else r=a.apply(this,arguments);return function(t,n){if(n&&("object"===e(n)||"function"==typeof n))return n;if(void 0!==n)throw new TypeError("Derived constructors may only return object or undefined");return d(t)}(this,r)}}function d(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function h(e){return h=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},h(e)}function m(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var p=function(e){!function(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)}(o,e);var r=f(o);function o(e){var t;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),m(d(t=r.call(this,e)),"onChange",function(e){e.persist();var n=t.state.value,r=t.props.minLength;t.setState({value:e.target.value},function(){var a=t.state.value;a.length>=r?t.notify(e):n.length>a.length&&t.notify(s(s({},e),{},{target:s(s({},e.target),{},{value:""})}))})}),m(d(t),"onKeyDown",function(e){"Enter"===e.key&&t.forceNotify(e);var n=t.props.onKeyDown;n&&(e.persist(),n(e))}),m(d(t),"onBlur",function(e){t.forceNotify(e);var n=t.props.onBlur;n&&(e.persist(),n(e))}),m(d(t),"createNotifier",function(e){if(e<0)t.notify=function(){return null};else if(0===e)t.notify=t.doNotify;else{var r=(0,n.default)(function(e){t.isDebouncing=!1,t.doNotify(e)},e);t.notify=function(e){t.isDebouncing=!0,r(e)},t.flush=function(){return r.flush()},t.cancel=function(){t.isDebouncing=!1,r.cancel()}}}),m(d(t),"doNotify",function(){t.props.onChange.apply(void 0,arguments)}),m(d(t),"forceNotify",function(e){var n=t.props.debounceTimeout;if(t.isDebouncing||!(n>0)){t.cancel&&t.cancel();var r=t.state.value,a=t.props.minLength;r.length>=a?t.doNotify(e):t.doNotify(s(s({},e),{},{target:s(s({},e.target),{},{value:r})}))}}),t.isDebouncing=!1,t.state={value:void 0===e.value||null===e.value?"":e.value};var a=t.props.debounceTimeout;return t.createNotifier(a),t}return c(o,[{key:"componentDidUpdate",value:function(e){if(!this.isDebouncing){var t=this.props,n=t.value,r=t.debounceTimeout,a=e.debounceTimeout,o=e.value,i=this.state.value;void 0!==n&&o!==n&&i!==n&&this.setState({value:n}),r!==a&&this.createNotifier(r)}}},{key:"componentWillUnmount",value:function(){this.flush&&this.flush()}},{key:"render",value:function(){var e=this.props,n=e.element;e.onChange,e.value,e.minLength,e.debounceTimeout;var r,o,l=e.forceNotifyByEnter,c=e.forceNotifyOnBlur,u=e.onKeyDown,f=e.onBlur,d=e.inputRef,h=i(e,a),m=this.state.value;r=l?{onKeyDown:this.onKeyDown}:u?{onKeyDown:u}:{},o=c?{onBlur:this.onBlur}:f?{onBlur:f}:{};var p=d?{ref:d}:{};return t.default.createElement(n,s(s(s(s({},h),{},{onChange:this.onChange,value:m},r),o),p))}}]),o}(t.default.PureComponent);return id.DebounceInput=p,m(p,"defaultProps",{element:"input",type:"text",onKeyDown:void 0,onBlur:void 0,value:void 0,minLength:0,debounceTimeout:100,forceNotifyByEnter:!0,forceNotifyOnBlur:!0,inputRef:void 0}),id}var sd=function(){if(ad)return rd;ad=1;var e=ld().DebounceInput;return e.DebounceInput=e,rd=e}(),cd="Input-module_input__ulQdV";const ud=r.forwardRef(({testId:t,className:n,type:r,name:a,placeholder:o,minLength:i=0,debounceTimeout:l=100,onChange:s,value:c,htmlId:u},f)=>e(sd.DebounceInput,{inputRef:f,"data-testid":t,className:`${cd} ${n||""}`,type:r,name:a,placeholder:o,minLength:i,debounceTimeout:l,onChange:s,value:c,id:u}));var fd="SharedQueryInput-module_wrapper__XRxrd",dd="SharedQueryInput-module_search__XlzRv",hd="SharedQueryInput-module_search-synced__J4T4b",md="SharedQueryInput-module_searchWithSync__ryuQa",pd="SharedQueryInput-module_icon__Aq0Hv",gd="SharedQueryInput-module_checked__oRvod",vd="SharedQueryInput-module_sync__0IO2N",bd="SharedQueryInput-module_syncSelected__hstBI",yd="SharedQueryInput-module_searchIcon__kfJxO";const wd=({onHighlightChange:n,highlightQuery:r,sharedQuery:a,width:i})=>{const l=Tc(),u=(e=>{const t=c();return d(()=>{t.current=e},[e]),t.current})(null==a?void 0:a.syncEnabled),f=c(null),[h,m]=s(!1);d(()=>{"string"==typeof(null==a?void 0:a.searchQuery)&&(a.syncEnabled&&n(a.searchQuery),!a.syncEnabled&&u&&u!==(null==a?void 0:a.id)&&n(""))},[null==a?void 0:a.searchQuery,null==a?void 0:a.syncEnabled]),d(()=>{const e=f.current;if(!e)return;const t=e.closest("[data-theme='kylin'], [data-flamegraph-color-mode='kylin']");m(!!t)},[]);const p=o(()=>a&&a.syncEnabled?a.searchQuery||"":r,[a,r]),g=o(()=>`${a?md:dd} ${(null==a?void 0:a.syncEnabled)?hd:""}`,[a]),v=(null==a?void 0:a.syncEnabled)?l.unsyncSearchBars:l.syncSearchBars;return t("div",{ref:f,className:fd,style:{width:i},children:[e("span",{className:yd,children:e(ca,{icon:od.faSearch})}),e(ud,{testId:"flamegraph-search",className:g,type:"search",name:"flamegraph-search",placeholder:h?"搜索函数 / 过滤":l.searchPlaceholder,minLength:1,debounceTimeout:100,onChange:e=>{n(e.target.value),a&&a.syncEnabled&&a.onQueryChange(e.target.value)},value:p}),a?e(Uf,{placement:"top",title:v,children:e("button",{className:a.syncEnabled?bd:vd,onClick:()=>{const e=!(null==a?void 0:a.syncEnabled)&&(null==a?void 0:a.id);null==a||a.toggleSync(e),e?null==a||a.onQueryChange(r):(n(r),null==a||a.onQueryChange(""))},children:e(ca,{className:`${a.syncEnabled?gd:pd}`,icon:Kf.faLink})})}):null]})};var xd="DiffLegend-module_flamegraph-legend__Cywr1",kd="DiffLegend-module_flamegraph-legend-list__swdXj",_d="DiffLegend-module_flamegraph-legend-item__0P-6g";function Nd(n){const{palette:r,showMode:a}=n,o=function(e){switch(e){case"large":return[-100,-80,-60,-40,-20,-10,0,10,20,40,60,80,100];case"small":return[-100,-50,0,50,100];default:throw new Error(`Unsupported ${e}`)}}(a),i=kl(r);return e("div",{"data-testid":"flamegraph-legend",className:`${xd} ${kd}`,style:"small"===a?{"--legend-item-width":"32px","--legend-item-padding":"2px 2px","--legend-font-size":"10px","--legend-line-height":"1.1","--legend-item-height":"16px"}:void 0,children:o.map(e=>t("div",{className:_d,style:{backgroundColor:i(e).rgb().toString()},children:[e>0?"+":"",e,"%"]},e))})}var Sd="Dropdown-module_dropdownMenu__tbN8r",Md="Dropdown-module_dropdownMenuButton__Xy8M4";function Td({id:n,children:r,className:a,disabled:o,value:i,label:l,onItemClick:s,overflow:c,position:u,direction:f,align:d,viewScroll:h,arrow:m,menuButtonClassName:p="",ariaLabel:g,portal:v,...b}){const y=b.menuButton||e(jd,{"aria-label":g,className:`${Md} ${p}`,disabled:o,type:"button",children:i||l});return t(Ys,{id:n,"aria-label":g,className:gu(a,Sd),"data-testid":b["data-testid"],onItemClick:s,overflow:c,position:u,direction:f,align:d,viewScroll:h,arrow:m,menuButton:y,portal:v,children:[e(ec,{children:l}),r]})}const Cd=Gs,jd=Rs;var Od="DiffLegendPaletteDropdown-module_container__h8Tts",Rd="DiffLegendPaletteDropdown-module_triggerButton__oezA6",Pd="DiffLegendPaletteDropdown-module_dropdownArrow__-Lu0w",Ed="DiffLegendPaletteDropdown-module_menuItem__5iWry",Fd="DiffLegendPaletteDropdown-module_menuItemText__a-tt0",Ad="DiffLegendPaletteDropdown-module_dropdownMenu__G0NkR",Id="DiffLegendPaletteDropdown-module_menuItemWrapper__vAw-Q",Dd="DiffLegendPaletteDropdown-module_menuItemSelected__1gu9m";const Bd=[vc,bc],Ld=n=>{const{palette:r=vc,onChange:a}=n,o=Tc(),i=e=>"Default"===e.name?o.paletteDefaultName:"Color Blind"===e.name?o.paletteColorBlindName:e.name,l=e=>"Default"===e.name?o.paletteDefaultDesc:"Color Blind"===e.name?o.paletteColorBlindDesc:"";return e("div",{className:Od,children:e(Td,{label:o.diffLegendSelectPalette,align:"end",className:Ad,menuButton:t(jd,{className:gu(Md,Rd),children:[e(Nd,{palette:r,showMode:"small"}),e("span",{className:Pd})]}),onItemClick:e=>{e.value&&a(e.value)},children:Bd.map(n=>e(Cd,{value:n,className:gu(Id,n.name===r.name&&Dd),children:e("div",{className:Ed,children:t("span",{className:Fd,children:[i(n)," ",l(n)]})})},n.name))})})};var $d={navbar:"Toolbar-module_navbar__XN6xZ",searchWrapper:"Toolbar-module_searchWrapper__k--ua",rightSection:"Toolbar-module_rightSection__if7LO",viewType:"Toolbar-module_viewType__AKARg",toggleViewButton:"Toolbar-module_toggleViewButton__OQ9-U",fitModeButton:"Toolbar-module_fitModeButton__jOxve",selected:"Toolbar-module_selected__vwBQt",collapseNodeButton:"Toolbar-module_collapseNodeButton__bLdiw",resetViewButton:"Toolbar-module_resetViewButton__y2ebV",divider:"Toolbar-module_divider__dG6pE",itemsContainer:"Toolbar-module_itemsContainer__gSTMF",item:"Toolbar-module_item__o-hKc",moreButton:"Toolbar-module_moreButton__rhOdT",active:"Toolbar-module_active__36Kt-",navbarCollapsedItems:"Toolbar-module_navbarCollapsedItems__vojhw"};const zd=F.bind($d),Vd=(e,t,n)=>{const r=0===t?e-360-5:e-360-16-5;let a=0,o=0;return n.reverse().forEach(e=>{o+=e,r<=o&&(a+=1)}),a},Hd=()=>e("div",{className:$d.divider}),Wd=y(({view:r,handleSearchChange:a,highlightQuery:o,isFlamegraphDirty:i,reset:l,updateFitMode:u,fitMode:h,updateView:m,selectedNode:p,onFocusOnSubtree:g,flamegraphType:v,enableChangingDisplay:b=!0,sharedQuery:y,ExportData:w,palette:k,setPalette:_})=>{const N=c(null),[S,M]=s(!1),T=Tc();d(()=>{const e=N.current;if(!e)return;const t=e.closest("[data-theme='kylin'], [data-flamegraph-color-mode='kylin']");M(!!t)},[]);const C=S?32:44,j=S?220:360,O="double"===v&&k&&_,R=[{el:t(n,{children:[e(Qd,{fitMode:h,updateFitMode:u}),e(Hd,{})]}),width:2*C+5},{el:e(Jd,{isFlamegraphDirty:i,reset:l}),width:C},{el:t(n,{children:[e(Ud,{selectedNode:p,onFocusOnSubtree:g}),e(Hd,{})]}),width:C+5},b?{el:e(Xd,{flamegraphType:v,view:r,updateView:m}),width:C*("single"===v?5:3)}:null,x(w)?{el:t(n,{children:[e(Hd,{}),w]}),width:C+5}:null].filter(e=>null!==e),P=R.reduce((e,t)=>[...e,t.width],[]),{isCollapsed:E,collapsedItemsNumber:F,handleMoreClick:A}=((e,t)=>{const[n,r]=s(!0),[a,o]=s(0);return f(()=>{if(e.current){const{width:n}=e.current.getBoundingClientRect(),r=Vd(n,a,t);o(r)}},[e.current,t]),rc(e,e=>{const{width:n}=e.target.getBoundingClientRect(),i=Vd(n,a,t);o(i),r(!0)}),{isCollapsed:n,handleMoreClick:()=>{r(e=>!e)},collapsedItemsNumber:a}})(N,P),I=R.reduce((e,t,n)=>(n<F?e.hidden.push(t):e.visible.push(t),e),{visible:[],hidden:[]});return e("div",{role:"toolbar",ref:N,children:t("div",{className:$d.navbar,children:[e("div",{className:$d.searchWrapper,children:e(wd,{width:j,onHighlightChange:a,highlightQuery:o,sharedQuery:y})}),t("div",{className:$d.rightSection,children:[O&&t(n,{children:[e(Ld,{palette:k,onChange:_}),e(Hd,{})]}),t("div",{className:$d.itemsContainer,children:[I.visible.map((t,n)=>e("div",{className:$d.item,style:{width:t.width},children:t.el},n)),0!==F&&e(Uf,{placement:"top",title:T.more,children:e("button",{onClick:A,className:zd({[$d.moreButton]:!0,[$d.active]:!E}),children:e(ca,{icon:$f.faEllipsisV})})})]})]}),!E&&e("div",{className:$d.navbarCollapsedItems,children:I.hidden.map((t,n)=>e("div",{className:$d.item,style:{width:t.width},children:t.el},n))})]})})});function Ud({onFocusOnSubtree:t,selectedNode:n}){const r=Tc(),a=n.mapOr(()=>{},e=>()=>t(e.i,e.j));return e(Uf,{placement:"top",title:r.collapseNodesAbove,children:e("div",{children:e(Gu,{disabled:!n.isJust,onClick:a,className:$d.collapseNodeButton,"aria-label":r.collapseNodesAbove,children:e(ca,{icon:as.faCompressAlt})})})})}function Jd({isFlamegraphDirty:t,reset:n}){const r=Tc();return e(Uf,{placement:"top",title:r.resetView,children:e("span",{children:e(Gu,{id:"reset",disabled:!t,onClick:n,className:$d.resetViewButton,"aria-label":r.resetView,children:e(ca,{icon:Cf.faUndo})})})})}function Qd({fitMode:r,updateFitMode:a}){const o=Tc(),i=e=>r===e;return t(n,{children:[e(Uf,{placement:"top",title:o.headFirst,children:e(Gu,{onClick:()=>a("HEAD"),className:zd({[$d.fitModeButton]:!0,[$d.selected]:i("HEAD")}),children:e(Uc,{})})}),e(Uf,{placement:"top",title:o.tailFirst,children:e(Gu,{onClick:()=>a("TAIL"),className:zd({[$d.fitModeButton]:!0,[$d.selected]:i("TAIL")}),children:e(Jc,{})})})]})}const qd=(t,n)=>"single"===t?[{label:n.viewFlamegraph,value:"flamegraph",Icon:Hc},{label:n.viewTable,value:"table",Icon:zc},{label:n.viewTableAndFlamegraph,value:"both",Icon:Vc},{label:n.viewSandwich,value:"sandwich",Icon:Wc},{label:n.viewGraphviz,value:"graphviz",Icon:()=>e(ca,{icon:Af.faProjectDiagram})}]:[{label:n.viewFlamegraph,value:"flamegraph",Icon:Hc},{label:n.viewTable,value:"table",Icon:zc},{label:n.viewTableAndFlamegraph,value:"both",Icon:Vc}];function Xd({view:t,updateView:n,flamegraphType:r}){const a=Tc(),o=qd(r,a);return e("div",{className:$d.viewType,children:o.map(({label:r,value:a,Icon:o})=>e(Uf,{placement:"top",title:r,children:e(Gu,{"data-testid":a,onClick:()=>n(a),className:zd({[$d.toggleViewButton]:!0,selected:t===a}),children:e(o,{})})},a))})}function Yd(e,t){const n={},r={};let a={name:"total",children:[],self:[],total:[],key:"/total"};return(t?[e,t]:[e]).forEach((e,t)=>{var o,i;for(let l=0;l<e.levels.length;l+=1)for(let s=0;s<e.levels[l].length;s+=4){const c=[t,l,s].join("/"),u=e.names[e.levels[l][s+3]],f=e.levels[l][s+0],d=e.levels[l][s+1],h=e.levels[l][s+2];let m="";if(0!==l){const n=l-1,a=e.levels[n];for(let e=0;e<a.length;e+=4){const o=a[e+0],i=a[e+1];if(f>=o&&f<o+i){const a=[t,n,e].join("/");m=r[a].key;break}}}const p=[m||"",u].join("/"),g=!n[p];n[p]||(n[p]={name:u,children:[],self:[],total:[],key:p});const v=n[p];(o=v.total)[t]||(o[t]=0),v.total[t]+=d,(i=v.self)[t]||(i[t]=0),v.self[t]+=h,r[c]=v,m&&g&&n[m].children.push(v),0===l&&(a=v)}}),a}const Kd=e=>{const t={maxSelf:100,names:[],levels:[]},n=(e,r,a)=>{var o;const{name:i,children:l,self:s,total:c,offset:u}=e;t.names.push(i),(o=t.levels)[r]||(o[r]=[]),t.maxSelf=Math.max(t.maxSelf,s[0]||0),t.levels[r]=t.levels[r].concat([a,c[0]||0,s[0]||0,t.names.length-1]);for(let e=0;e<l.length;e+=1){a+=n(l[e],r+1,a)}return u||c[0]||0};return n(e,0,0),t};function Zd(e){const t=new Map;for(let n=0;n<e.children.length;n+=1)t.has(e.children[n].name)||t.set(e.children[n].name,e.children[n]);for(let n=0;n<e.children.length;n+=1){const r=e.children[n],a=t.get(e.children[n].name);a&&a!==r&&(a.total[0]+=r.total[0],a.self[0]+=r.self[0],a.children=a.children.concat(r.children))}e.children=Array.from(t.values());for(let t=0;t<e.children.length;t+=1)Zd(e.children[t])}function Gd(e,t){const n=function(e,t){const n=Yd(e),r={format:"single",numTicks:0,maxSelf:100,sampleRate:100,names:[],levels:[],units:e.units,spyName:e.spyName},a={name:t,total:[],self:[0],children:[]},o=e=>{e.name===t&&(r.numTicks+=e.total[0],a.total=[r.numTicks],a.children=a.children.concat(e.children));for(let t=0;t<e.children.length;t+=1)o(e.children[t])};return o(n),Zd(a),{...r,...Kd(a)}}(JSON.parse(JSON.stringify(e)),t);return n}function eh(e,t){const n=function(e,t){const n=Yd(e),r={format:"single",maxSelf:100,sampleRate:100,numTicks:0,names:[],levels:[],units:e.units,spyName:e.spyName},a=[],o=[],i={name:t,total:[0],self:[0],children:[]},l=(e,n=[])=>{const i=n.concat([{...e,children:[]}]);e.name===t&&(o.push(i),a.push(e.total[0]),r.numTicks+=e.total[0]);for(let t=0;t<e.children.length;t+=1)l(e.children[t],i)};l(n),o.forEach((e,t)=>{i.children.push(((e,t)=>{const n={};let r=n;return e.forEach(({name:e,...n})=>{const a={name:e,...n,total:[t]};r.children=[a],r=a}),n.children[0]})(e.reverse(),a[t]))}),Zd(i);const s=Kd(i);return s.levels=s.levels.reverse().slice(0,-1),{...r,...s}}(JSON.parse(JSON.stringify(e)),t);return n}var th={flamegraphContainer:"FlamegraphRenderer-module_flamegraphContainer__-7FRV",createdBy:"FlamegraphRenderer-module_createdBy__rHAOT",horizontal:"FlamegraphRenderer-module_horizontal__zs7--",vertical:"FlamegraphRenderer-module_vertical__fRcHg",panesWrapper:"FlamegraphRenderer-module_panesWrapper__L-mlA",tablePane:"FlamegraphRenderer-module_tablePane__Gin7Y",sandwichPane:"FlamegraphRenderer-module_sandwichPane__IEOyR",sandwichPaneInfo:"FlamegraphRenderer-module_sandwichPaneInfo__5hT4a",arrow:"FlamegraphRenderer-module_arrow__dPzpE",sandwichTop:"FlamegraphRenderer-module_sandwichTop__7N0ZY",sandwichBottom:"FlamegraphRenderer-module_sandwichBottom__Dc64g",name:"FlamegraphRenderer-module_name__XRbN9"};function nh(e){const t=[];return Object.keys(e).forEach(n=>{var r;t.push(`${n}="${r=String(e[n]||""),r.replace(/\\/g,"\\\\").replace(/"/g,'\\"')}"`)}),`[${t.join(" ")}]`}function rh(e,t){return`${(100*e/t).toFixed(2)}%`}function ah(e,t){let n,r,a,o;t?(n=.1,r=.93):(n=1,r=.7),e=Math.max(-1,Math.min(1,e)),Math.abs(e)<.2&&(n*=Math.abs(e)/.2),e>0&&(e**=1-.7),e<0&&(e=-((-e)**(1-.7))),e<0?(o=r,a=r*(1+n*e)):(a=r,o=r*(1-n*e));const i=r*(1-n);return`#${Math.floor(255*a).toString(16).padStart(2,"0")}${Math.floor(255*o).toString(16).padStart(2,"0")}${Math.floor(255*i).toString(16).padStart(2,"0")}`}function oh(e,t,n,r){const{self:a}=t,{total:o}=t,i=t.name.replace(/"/g,'\\"'),l=e(a),s=8+Math.ceil(16*Math.sqrt(a/n)),c=ah(o/r,!1),u=ah(o/r,!0),f=function(e,t,n,r,a){let o="";o=`${function(e){return e.replace(/.*\//,"")}(t)}\n`;const i=e(n);0!==n?o=`${o+i} (${rh(n,a)})`:o+="0";let l=i;r!==n&&(o+=0!==n?"\n":" ",l=e(r),o=`${o}of ${l} (${rh(r,a)})`);return o}(e,i,a,o,r),d={label:f,id:`node${t.index}`,fontsize:s,shape:"box",tooltip:`${i} (${l})`,color:c,fontcolor:"#000000",style:"filled",fontname:"",fillcolor:u};return`N${t.index} ${nh(d)}`}function ih(e){if("double"===e.metadata.format)return"diff flamegraphs are not supported";const t=Yd(e.flamebearer),n=[],r=[];const[a,o,,i]=function e(t,n,r,a,o){return t.children.forEach(t=>{const[i,l]=e(t,n,r,a,o);n=Math.max(n,i),r=Math.max(r,l)}),n=Math.max(n,t.self[0]),r=Math.max(r,t.total[0]),a+=t.self[0],o+=t.total[0],[n,r,a,o]}(t,0,0,0,0),{sampleRate:l,units:s}=e.metadata,c=ao(o,l,s),u=e=>c.format(e,l,!0);let f={};const d={};let h=0;function m(e,t){return-1===t.indexOf(e.name)&&(f[e.name]?(f[e.name].self+=e.self[0],f[e.name].total+=e.total[0]):(h+=1,f[e.name]={index:h,name:e.name,self:e.self[0],total:e.total[0],parents:[],children:[]})),e.children.forEach(n=>{const r=m(n,t.concat([e.name])),a=`${e.name}/${n.name}`;n.name!==e.name&&(d[a]?d[a].weight+=n.total[0]:d[a]={from:f[e.name],to:r,weight:n.total[0],residual:!1},r.parents.push(d[a]),f[e.name].children.push(d[a]))}),f[e.name]}t.children.forEach(e=>{m(e,[])});const p=.005*i,g=.001*i;function v(e,t){let n=0,r=t;if(e.forEach(e=>{e.weight>0&&(r+=Math.abs(e.weight))}),0!==r&&(e.forEach(e=>{const t=Math.abs(e.weight)/r;n+=-t*Math.log2(t)}),t>0)){const e=Math.abs(t)/r;n+=-e*Math.log2(e)}return n}Object.keys(f).forEach(e=>{f[e].total<p&&delete f[e]});const b={};Object.keys(f).forEach(e=>{b[f[e].name]=function(e){let t=0;return 0===e.parents.length?t+=1:t+=v(e.parents,0),0===e.children.length?t+=1:t+=v(e.children,e.self),t*e.total+e.self}(f[e])});const y=Object.values(f).sort((e,t)=>{const n=b[e.name],r=b[t.name];return n!==r?r-n:e.name!==t.name?e.name<t.name?-1:1:e.self!==t.self?r-n:e.name<t.name?-1:1}),w={};function x(e){const[t,n]=[e.from,e.to],r={},a=[n];for(;a.length>0;){const n=a.shift();for(let o=0;o<n.parents.length;o+=1){const i=n.parents[o];if(e!==i&&!r[i.from.name]){if(i.from===t)return!0;r[i.from.name]=!0,a.push(i.from)}}}return!1}return y.forEach(e=>{w[e.name]=e}),y.slice(80).forEach(e=>{delete w[e.name]}),function e(t,n){const r=!w[t.name];t.children.forEach(a=>{const o=!w[a.name];if(e(a,r?n:t),!o&&n&&r){const e=`${n.name}/${a.name}`;d[e]||(d[e]={from:f[n.name],to:f[a.name],weight:0,residual:!0}),d[e].weight+=a.total[0],d[e].residual=!0}})}(t,null),f=w,y.reverse().forEach(e=>{const t=e.parents.sort((e,t)=>t.weight-e.weight),n=[];for(let e=0;e<t.length;e+=1){const r=t[e];if(!r.residual)break;x(r)&&(n.push(r),delete d[`${r.from.name}/${r.to.name}`])}n.forEach(e=>{e.from.children=e.from.children.filter(t=>t.to!==e.to),e.to.parents=e.to.parents.filter(t=>t.from!==e.from)})}),Object.keys(d).forEach(e=>{const t=d[e];f[t.from.name]||delete d[e],f[t.to.name]||delete d[e],t.weight<g&&delete d[e]}),Object.keys(f).forEach(e=>{n.push(oh(u,f[e],a,o))}),Object.keys(d).forEach(e=>{r.push(function(e,t,n){const r=t.from.name.replace(/"/g,'\\"'),a=t.to.name.replace(/"/g,'\\"'),o=t.weight,i=e(t.weight),l=`${r} -> ${a} (${i})`,s={label:i,weight:1+100*o/n,penwidth:1+5*o/n,tooltip:l,labeltooltip:l,fontname:"",color:ah(o/n,!1),style:t.residual?"dotted":""};return`N${t.from.index} -> N${t.to.index} ${nh(s)}`}(u,d[e],o))}),`digraph "unnamed" {\n fontname= ""\n ${n.join("\n")}\n ${r.join("\n")}\n }`}var lh="GraphVizPanel-module_graphVizPane__B18cQ";const sh=()=>null;function ch({flamebearer:t}){var n,r;const a=t,i=(null===(n=a.metadata)||void 0===n?void 0:n.format)&&(null===(r=a.flamebearer)||void 0===r?void 0:r.levels),l=`graphviz-pane-${(null==a?void 0:a.appName)||String((new Date).valueOf())}`,s=o(()=>ih(a),[JSON.stringify(a)]);return e("div",{className:lh,children:i?e(sh,{options:{zoom:!0,width:"150%",height:"100%",scale:1,useWorker:!1},dot:s}):e("div",{children:"NO DATA"})},l)}function uh(e){let t=2166136261;const n=e.length;if(0===n)return t>>>0;const r=[0,Math.floor(n/2),n-1];for(let n=0;n<r.length;n+=1){const a=e[r[n]];if(!a||0===a.length)continue;const o=Math.min(8,a.length);for(let e=0;e<o;e+=1)t^=0|a[e],t=Math.imul(t,16777619);for(let e=Math.max(0,a.length-o);e<a.length;e+=1)t^=0|a[e],t=Math.imul(t,16777619)}return t>>>0}function fh(e){let t=2166136261;const n=e.length;if(0===n)return t>>>0;const r=Math.min(32,n),a=[...Array.from({length:r},(e,t)=>t),...Array.from({length:r},(e,t)=>n-r+t)];for(let n=0;n<a.length;n+=1){const r=e[a[n]]||"";for(let e=0;e<r.length;e+=1)t^=r.charCodeAt(e),t=Math.imul(t,16777619)}return t>>>0}function dh(e){var t,n,r,a,o,i;const l=e.__kylinSignature;if(l)return l;const s=e,c=[e.format,e.numTicks,e.sampleRate,e.units,e.maxSelf,null!==(n=null===(t=e.names)||void 0===t?void 0:t.length)&&void 0!==n?n:0,null!==(a=null===(r=e.levels)||void 0===r?void 0:r.length)&&void 0!==a?a:0,null!==(o=s.leftTicks)&&void 0!==o?o:"na",null!==(i=s.rightTicks)&&void 0!==i?i:"na",uh(e.levels),fh(e.names||[])].join("|");return e.__kylinSignature=c,c}function hh(e,t){const n=[...t];function r(e,t,n){for(const r of e){let e=0;for(let a=t;a<r.length;a+=n)r[a]-=e,e+=r[a]+r[a+1]}}return"double"===e?(r(n,0,7),r(n,3,7)):r(n,0,4),n}function mh(e,t){const n=[...t];function r(e,t,n){for(const r of e){let e=0;for(let a=t;a<r.length;a+=n)r[a]+=e,e=r[a]+r[a+1]}}return"double"===e?(r(n,0,7),r(n,3,7)):r(n,0,4),n}function ph(e){if(e.profile&&e.flamebearer&&console.warn("'profile' and 'flamebearer' properties are mutually exclusive. Please use profile if possible."),e.profile){const n=e.profile,r={...n,flamebearer:{...n.flamebearer}};n.__kylinDecoded||((t=r).flamebearer.levels=mh(t.metadata.format,t.flamebearer.levels),n.__kylinDecoded=!0,r.__kylinDecoded=!0);const a={...r,...r.metadata,...r.flamebearer,flamebearer:void 0,metadata:void 0};return delete a.flamebearer,delete a.metadata,a}var t;if(e.flamebearer)return e.flamebearer;return{format:"single",names:[],units:"unknown",levels:[[]],spyName:"unknown",numTicks:0,sampleRate:0,maxSelf:0}}class gh extends k{constructor(n){super(n),this.resetFlamegraphState={focusedNode:Aa.nothing(),zoom:Aa.nothing()},this.initialFlamegraphState=this.resetFlamegraphState,this.calcNewConfigs=(e,t)=>{const n=this.state.flamegraphConfigs,r=(e,t,n)=>{const r=(e,t,n)=>e.names[Wa(e.format).getBarName(e.levels[t],n)];if(n.isNothing)return!0;try{const a=n,o=r(e,a.value.i,a.value.j);return o===r(t,a.value.i,a.value.j)}catch{return!1}};r(e,t,this.state.flamegraphConfigs.zoom)||(n.zoom=this.resetFlamegraphState.zoom);return r(e,t,this.state.flamegraphConfigs.focusedNode)||(n.focusedNode=this.resetFlamegraphState.focusedNode),n},this.onSearchChange=e=>{this.setState({searchQuery:e})},this.isSameFlamebearer=(e,t)=>function(e,t){return dh(e)===dh(t)}(e,t),this.onReset=()=>{this.setState({...this.state,flamegraphConfigs:{...this.state.flamegraphConfigs,...this.initialFlamegraphState},selectedItem:Aa.nothing()})},this.onFlamegraphZoom=e=>{e.isJust&&0===e.value.i&&0===e.value.j?this.onReset():this.setState({...this.state,flamegraphConfigs:{...this.state.flamegraphConfigs,zoom:e}})},this.onFocusOnNode=(e,t)=>{if(0===e&&0===t)return void this.onReset();let n={...this.state.flamegraphConfigs};const{zoom:r}=this.state.flamegraphConfigs;r.isJust&&r.value.i<=e&&(n={...n,zoom:this.initialFlamegraphState.zoom}),this.setState({...this.state,flamegraphConfigs:{...n,focusedNode:Aa.just({i:e,j:t})}})},this.isNameInFocusedSubtree=e=>{const{focusedNode:t}=this.state.flamegraphConfigs;if(t.isNothing)return!0;const{flamebearer:n}=this.state;if(!n||!n.levels)return!0;const{names:r,levels:a,format:o}=n,i=Wa(o),l=t.value.i,s=t.value.j,c=a[l];if(!c)return!0;const u=i.getBarOffset(c,s),f=u+i.getBarTotal(c,s);for(let t=l;t<a.length;t++){const n=a[t];for(let t=0;t<n.length;t+=i.jStep){const a=i.getBarOffset(n,t),o=i.getBarTotal(n,t);if(a>=u&&a+o<=f){if(r[i.getBarName(n,t)]===e)return!0}}}return!1},this.setActiveItem=e=>{const{name:t}=e;if(this.state.selectedItem.isJust&&t===this.state.selectedItem.value)return void this.setState({selectedItem:Aa.nothing()});this.isNameInFocusedSubtree(t)?this.setState({selectedItem:Aa.just(t)}):this.setState({selectedItem:Aa.just(t),flamegraphConfigs:{...this.state.flamegraphConfigs,focusedNode:this.resetFlamegraphState.focusedNode}})},this.getHighlightQuery=()=>this.state.selectedItem.isJust?this.state.selectedItem.value:this.state.searchQuery,this.updateView=e=>{"sandwich"===e&&this.setState({searchQuery:"",flamegraphConfigs:this.resetFlamegraphState}),this.setState({view:e})},this.updateFlamegraphDirtiness=()=>{const e=this.isDirty();this.setState({isFlamegraphDirty:e})},this.updateFitMode=e=>{this.setState({fitMode:e})},this.clearFocus=()=>{this.setState(e=>({...e,flamegraphConfigs:{...e.flamegraphConfigs,...this.resetFlamegraphState}}))},this.getActiveRange=()=>{const{flamebearer:e}=this.state,{zoom:t,focusedNode:n}=this.state.flamegraphConfigs,r=e.numTicks;if(!r)return{rangeMin:0,rangeMax:1};const a=Wa(e.format),o=t=>{const n=e.levels[t.i];if(!n)return{rangeMin:0,rangeMax:1};const o=a.getBarOffset(n,t.j),i=a.getBarTotal(n,t.j);return{rangeMin:o/r,rangeMax:(o+i)/r}};return t.match({Just:e=>n.match({Just:t=>{const n=o(t),r=o(e);return n.rangeMax-n.rangeMin<r.rangeMax-r.rangeMin?n:r},Nothing:()=>o(e)}),Nothing:()=>n.match({Just:e=>o(e),Nothing:()=>({rangeMin:0,rangeMax:1})})})},this.isDirty=()=>this.state.selectedItem.isJust||JSON.stringify(this.initialFlamegraphState)!==JSON.stringify(this.state.flamegraphConfigs),this.handleSetPalette=e=>{this.setState({palette:e})},this.render=()=>{var n;const r=e("div",{className:Fl(th.tablePane,"vertical"===this.state.panesOrientation?th.vertical:th.horizontal),children:e(yf,{"data-testid":"table-view",flamebearer:this.state.flamebearer,fitMode:this.state.fitMode,highlightQuery:this.state.searchQuery,selectedItem:this.state.selectedItem,handleTableItemClick:this.setActiveItem,palette:this.state.palette,onFocusOnNode:this.onFocusOnNode,updateView:this.props.onlyDisplay?void 0:this.updateView,enableSandwichView:this.props.enableSandwichView})},"table-pane"),a=this.shouldShowToolbar(),o=!this.state.flamebearer||this.state.flamebearer.names.length<=1,i=this.context,l="Location"!==i.location,s=this.state.flamebearer.numTicks,c=ao(s,this.state.flamebearer.sampleRate,this.state.flamebearer.units).format(s,this.state.flamebearer.sampleRate),u=eo(c,l)||c,f=function(e,t=to){const n=Math.abs(e);for(const{value:r,label:a}of t)if(n>=r)return`${(e/r).toFixed(2).replace(/\.?0+$/,"")} ${a}`;return Za(e)}(s,i.sampleCountFormat),d=i.tooltipSamples.replace(/[::]\s*$/,""),h=(null===(n=i.tooltipUnitTitles[this.state.flamebearer.units])||void 0===n?void 0:n.formattedValue)||i.tooltipUnitTitles.unknown.formattedValue,m=this.getActiveRange(),p=m.rangeMin>0||m.rangeMax<1,g=Math.max(0,Math.min(s,(m.rangeMax-m.rangeMin)*s)),v=s>0?g/s*100:0,b=(()=>{const e=Wa(this.state.flamebearer.format),t=this.state.flamegraphConfigs.focusedNode.mapOrElse(()=>this.state.flamegraphConfigs.zoom.mapOrElse(()=>null,e=>e),e=>e);if(!t)return"";const n=this.state.flamebearer.levels[t.i];if(!n)return"";const r=e.getBarName(n,t.j);return this.state.flamebearer.names[r]||""})(),y=e(fu,{showCredit:this.props.showCredit,flamebearer:this.state.flamebearer,highlightQuery:this.getHighlightQuery(),setActiveItem:this.setActiveItem,selectedItem:this.state.selectedItem,updateView:this.props.onlyDisplay?void 0:this.updateView,fitMode:this.state.fitMode,updateFitMode:this.updateFitMode,zoom:this.state.flamegraphConfigs.zoom,focusedNode:this.state.flamegraphConfigs.focusedNode,onZoom:this.onFlamegraphZoom,onFocusOnNode:this.onFocusOnNode,onReset:this.onReset,isDirty:this.isDirty,palette:this.state.palette,toolbarVisible:a,setPalette:this.handleSetPalette,enableSandwichView:this.props.enableSandwichView,breadcrumb:o?void 0:{totalValueText:u,totalSamplesText:f,samplesLabel:d,unitLabel:h,hasFocus:p,focusPercent:v,focusLabel:b,ofTotalPlacement:l?"before":"after",ofTotalLabel:i.ofTotal,clearFocusLabel:i.clearFocus,onClearFocus:this.clearFocus}},"flamegraph-pane"),w=(()=>{if("sandwich"!==this.state.view)return e("div",{className:th.sandwichPane},"sandwich-pane");if(this.state.selectedItem.isNothing)return e("div",{className:th.sandwichPane,children:t("div",{className:Fl(th.sandwichPaneInfo,"vertical"===this.state.panesOrientation?th.vertical:th.horizontal),children:[e("div",{className:th.arrow}),"Select a function to view callers/callees sandwich view"]})},"sandwich-pane");const n=eh(this.state.flamebearer,this.state.selectedItem.value),r=Gd(this.state.flamebearer,this.state.selectedItem.value),o=t=>e(fu,{disableClick:!0,showCredit:this.props.showCredit,highlightQuery:"",setActiveItem:this.setActiveItem,selectedItem:this.state.selectedItem,fitMode:this.state.fitMode,updateFitMode:this.updateFitMode,zoom:this.state.flamegraphConfigs.zoom,focusedNode:this.state.flamegraphConfigs.focusedNode,onZoom:this.onFlamegraphZoom,onFocusOnNode:this.onFocusOnNode,onReset:this.onReset,isDirty:this.isDirty,palette:this.state.palette,toolbarVisible:a,setPalette:this.handleSetPalette,...t});return t("div",{className:th.sandwichPane,children:[t("div",{className:th.sandwichTop,children:[e("span",{className:th.name,children:"Callers"}),o({flamebearer:n})]}),t("div",{className:th.sandwichBottom,children:[e("span",{className:th.name,children:"Callees"}),o({flamebearer:r,headerVisible:!1,showSingleLevel:!0})]})]},"sandwich-pane")})(),x=function(e,t,n,r,a){switch(e){case"table":return[n];case"flamegraph":return[t];case"sandwich":return[n,r];case"both":return[n,t];case"graphviz":return[a];default:throw new Error(`Invalid view '${e}'`)}}(this.state.view,y,r,w,e(ch,{flamebearer:this.state.flamebearer}));return t("div",{children:[t("div",{children:[a&&e(Wd,{sharedQuery:this.props.sharedQuery,enableChangingDisplay:!this.props.onlyDisplay,flamegraphType:this.state.flamebearer.format,view:this.state.view,handleSearchChange:this.onSearchChange,reset:this.onReset,updateView:this.updateView,updateFitMode:this.updateFitMode,fitMode:this.state.fitMode,isFlamegraphDirty:this.isDirty(),selectedNode:this.state.flamegraphConfigs.zoom,highlightQuery:this.state.searchQuery,onFocusOnSubtree:this.onFocusOnNode,ExportData:this.props.ExportData,palette:this.state.palette,setPalette:this.handleSetPalette}),this.props.children,e("div",{className:`${th.flamegraphContainer} ${Fl("vertical"===this.state.panesOrientation?th.vertical:th.horizontal,th[this.state.panesOrientation],th.panesWrapper)}`,children:o?e(Il,{}):x.map(e=>e)})]}),this.props.showPyroscopeLogo&&t("div",{className:th.createdBy,children:["Created by",t("a",{href:"https://twitter.com/PyroscopeIO",rel:"noreferrer",target:"_blank",children:[e(T,{width:"30",height:"30"}),"@PyroscopeIO"]})]})]})},this.state={isFlamegraphDirty:!1,view:this.props.onlyDisplay?this.props.onlyDisplay:"both",fitMode:"HEAD",flamebearer:ph(n),panesOrientation:n.panesOrientation?n.panesOrientation:"horizontal",searchQuery:"",selectedItem:Aa.nothing(),flamegraphConfigs:this.initialFlamegraphState,palette:vc}}componentDidUpdate(e,t){if(e.profile!==this.props.profile||e.flamebearer!==this.props.flamebearer){const e=t.flamebearer,n=ph(this.props);if(!this.isSameFlamebearer(e,n)){const t=this.calcNewConfigs(e,n);return void this.setState({flamebearer:n,flamegraphConfigs:{...this.state.flamegraphConfigs,...t},selectedItem:Aa.nothing()})}}t.flamegraphConfigs!==this.state.flamegraphConfigs&&this.updateFlamegraphDirtiness()}shouldShowToolbar(){return void 0===this.props.showToolbar||this.props.showToolbar}}gh.contextType=Sc,gh.defaultProps={showCredit:!1};const vh={showPyroscopeLogo:!1},bh=(e,t)=>{if(t)return t;const n=null!=e?e:"auto";return"zh-CN"===("auto"===n?"undefined"!=typeof navigator&&navigator.language&&navigator.language.toLowerCase().startsWith("zh")?"zh-CN":"en":n)?_c:kc},yh=t=>{const{i18n:n,locale:a,colorMode:o="light",sandwich:i=!0,...l}=t,s=r.useMemo(()=>bh(a,n),[a,n]),c=r.useMemo(()=>(e=>{switch(e){case"dark":return"ps-theme-dark";case"kylin":return"ps-theme-kylin";default:return"ps-theme-light"}})(o),[o]);return e("pyro-flamegraph",{className:c,children:e(Mc,{messages:s,children:e(gh,{...vh,enableSandwichView:i,...l})})})};var wh,xh={exports:{}};var kh,_h=(wh||(wh=1,function(e,t){var n="__lodash_hash_undefined__",r=9007199254740991,a="[object Arguments]",o="[object Array]",i="[object Boolean]",l="[object Date]",s="[object Error]",c="[object Function]",u="[object Map]",f="[object Number]",d="[object Object]",h="[object Promise]",m="[object RegExp]",p="[object Set]",g="[object String]",v="[object Symbol]",b="[object WeakMap]",y="[object ArrayBuffer]",w="[object DataView]",x=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,k=/^\w*$/,_=/^\./,N=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,S=/\\(\\)?/g,M=/^\[object .+?Constructor\]$/,T=/^(?:0|[1-9]\d*)$/,j={};j["[object Float32Array]"]=j["[object Float64Array]"]=j["[object Int8Array]"]=j["[object Int16Array]"]=j["[object Int32Array]"]=j["[object Uint8Array]"]=j["[object Uint8ClampedArray]"]=j["[object Uint16Array]"]=j["[object Uint32Array]"]=!0,j[a]=j[o]=j[y]=j[i]=j[w]=j[l]=j[s]=j[c]=j[u]=j[f]=j[d]=j[m]=j[p]=j[g]=j[b]=!1;var O="object"==typeof C&&C&&C.Object===Object&&C,R="object"==typeof self&&self&&self.Object===Object&&self,P=O||R||Function("return this")(),E=t&&!t.nodeType&&t,F=E&&e&&!e.nodeType&&e,A=F&&F.exports===E&&O.process,I=function(){try{return A&&A.binding("util")}catch(e){}}(),D=I&&I.isTypedArray;function B(e,t,n,r){for(var a=-1,o=e?e.length:0;++a<o;){var i=e[a];t(r,i,n(i),e)}return r}function L(e,t){for(var n=-1,r=e?e.length:0;++n<r;)if(t(e[n],n,e))return!0;return!1}function $(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}function z(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}function V(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}var H,W,U,J=Array.prototype,Q=Function.prototype,q=Object.prototype,X=P["__core-js_shared__"],Y=(H=/[^.]+$/.exec(X&&X.keys&&X.keys.IE_PROTO||""))?"Symbol(src)_1."+H:"",K=Q.toString,Z=q.hasOwnProperty,G=q.toString,ee=RegExp("^"+K.call(Z).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),te=P.Symbol,ne=P.Uint8Array,re=q.propertyIsEnumerable,ae=J.splice,oe=(W=Object.keys,U=Object,function(e){return W(U(e))}),ie=$e(P,"DataView"),le=$e(P,"Map"),se=$e(P,"Promise"),ce=$e(P,"Set"),ue=$e(P,"WeakMap"),fe=$e(Object,"create"),de=qe(ie),he=qe(le),me=qe(se),pe=qe(ce),ge=qe(ue),ve=te?te.prototype:void 0,be=ve?ve.valueOf:void 0,ye=ve?ve.toString:void 0;function we(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function xe(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function ke(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function _e(e){var t=-1,n=e?e.length:0;for(this.__data__=new ke;++t<n;)this.add(e[t])}function Ne(e){this.__data__=new xe(e)}function Se(e,t){var n=et(e)||Ge(e)?function(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}(e.length,String):[],r=n.length,a=!!r;for(var o in e)!Z.call(e,o)||a&&("length"==o||Ve(o,r))||n.push(o);return n}function Me(e,t){for(var n=e.length;n--;)if(Ze(e[n][0],t))return n;return-1}function Te(e,t,n,r){return je(e,function(e,a,o){t(r,e,n(e),o)}),r}we.prototype.clear=function(){this.__data__=fe?fe(null):{}},we.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},we.prototype.get=function(e){var t=this.__data__;if(fe){var r=t[e];return r===n?void 0:r}return Z.call(t,e)?t[e]:void 0},we.prototype.has=function(e){var t=this.__data__;return fe?void 0!==t[e]:Z.call(t,e)},we.prototype.set=function(e,t){return this.__data__[e]=fe&&void 0===t?n:t,this},xe.prototype.clear=function(){this.__data__=[]},xe.prototype.delete=function(e){var t=this.__data__,n=Me(t,e);return!(n<0||(n==t.length-1?t.pop():ae.call(t,n,1),0))},xe.prototype.get=function(e){var t=this.__data__,n=Me(t,e);return n<0?void 0:t[n][1]},xe.prototype.has=function(e){return Me(this.__data__,e)>-1},xe.prototype.set=function(e,t){var n=this.__data__,r=Me(n,e);return r<0?n.push([e,t]):n[r][1]=t,this},ke.prototype.clear=function(){this.__data__={hash:new we,map:new(le||xe),string:new we}},ke.prototype.delete=function(e){return Le(this,e).delete(e)},ke.prototype.get=function(e){return Le(this,e).get(e)},ke.prototype.has=function(e){return Le(this,e).has(e)},ke.prototype.set=function(e,t){return Le(this,e).set(e,t),this},_e.prototype.add=_e.prototype.push=function(e){return this.__data__.set(e,n),this},_e.prototype.has=function(e){return this.__data__.has(e)},Ne.prototype.clear=function(){this.__data__=new xe},Ne.prototype.delete=function(e){return this.__data__.delete(e)},Ne.prototype.get=function(e){return this.__data__.get(e)},Ne.prototype.has=function(e){return this.__data__.has(e)},Ne.prototype.set=function(e,t){var n=this.__data__;if(n instanceof xe){var r=n.__data__;if(!le||r.length<199)return r.push([e,t]),this;n=this.__data__=new ke(r)}return n.set(e,t),this};var Ce,je=(Ce=function(e,t){return e&&Oe(e,t,st)},function(e,t){if(null==e)return e;if(!tt(e))return Ce(e,t);for(var n=e.length,r=-1,a=Object(e);++r<n&&!1!==t(a[r],r,a););return e}),Oe=function(e,t,n){for(var r=-1,a=Object(e),o=n(e),i=o.length;i--;){var l=o[++r];if(!1===t(a[l],l,a))break}return e};function Re(e,t){for(var n=0,r=(t=He(t,e)?[t]:De(t)).length;null!=e&&n<r;)e=e[Qe(t[n++])];return n&&n==r?e:void 0}function Pe(e,t){return null!=e&&t in Object(e)}function Ee(e,t,n,r,c){return e===t||(null==e||null==t||!at(e)&&!ot(t)?e!=e&&t!=t:function(e,t,n,r,c,h){var b=et(e),x=et(t),k=o,_=o;b||(k=(k=ze(e))==a?d:k),x||(_=(_=ze(t))==a?d:_);var N=k==d&&!$(e),S=_==d&&!$(t),M=k==_;if(M&&!N)return h||(h=new Ne),b||lt(e)?Be(e,t,n,r,c,h):function(e,t,n,r,a,o,c){switch(n){case w:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case y:return!(e.byteLength!=t.byteLength||!r(new ne(e),new ne(t)));case i:case l:case f:return Ze(+e,+t);case s:return e.name==t.name&&e.message==t.message;case m:case g:return e==t+"";case u:var d=z;case p:var h=2&o;if(d||(d=V),e.size!=t.size&&!h)return!1;var b=c.get(e);if(b)return b==t;o|=1,c.set(e,t);var x=Be(d(e),d(t),r,a,o,c);return c.delete(e),x;case v:if(be)return be.call(e)==be.call(t)}return!1}(e,t,k,n,r,c,h);if(!(2&c)){var T=N&&Z.call(e,"__wrapped__"),C=S&&Z.call(t,"__wrapped__");if(T||C){var j=T?e.value():e,O=C?t.value():t;return h||(h=new Ne),n(j,O,r,c,h)}}return!!M&&(h||(h=new Ne),function(e,t,n,r,a,o){var i=2&a,l=st(e),s=l.length,c=st(t),u=c.length;if(s!=u&&!i)return!1;for(var f=s;f--;){var d=l[f];if(!(i?d in t:Z.call(t,d)))return!1}var h=o.get(e);if(h&&o.get(t))return h==t;var m=!0;o.set(e,t),o.set(t,e);for(var p=i;++f<s;){var g=e[d=l[f]],v=t[d];if(r)var b=i?r(v,g,d,t,e,o):r(g,v,d,e,t,o);if(!(void 0===b?g===v||n(g,v,r,a,o):b)){m=!1;break}p||(p="constructor"==d)}if(m&&!p){var y=e.constructor,w=t.constructor;y==w||!("constructor"in e)||!("constructor"in t)||"function"==typeof y&&y instanceof y&&"function"==typeof w&&w instanceof w||(m=!1)}return o.delete(e),o.delete(t),m}(e,t,n,r,c,h))}(e,t,Ee,n,r,c))}function Fe(e){return!(!at(e)||function(e){return!!Y&&Y in e}(e))&&(nt(e)||$(e)?ee:M).test(qe(e))}function Ae(e){return"function"==typeof e?e:null==e?ct:"object"==typeof e?et(e)?function(e,t){return He(e)&&We(t)?Ue(Qe(e),t):function(n){var r=function(e,t,n){var r=null==e?void 0:Re(e,t);return void 0===r?n:r}(n,e);return void 0===r&&r===t?function(e,t){return null!=e&&function(e,t,n){t=He(t,e)?[t]:De(t);for(var r,a=-1,o=t.length;++a<o;){var i=Qe(t[a]);if(!(r=null!=e&&n(e,i)))break;e=e[i]}return r||!!(o=e?e.length:0)&&rt(o)&&Ve(i,o)&&(et(e)||Ge(e))}(e,t,Pe)}(n,e):Ee(t,r,void 0,3)}}(e[0],e[1]):(n=function(e){for(var t=st(e),n=t.length;n--;){var r=t[n],a=e[r];t[n]=[r,a,We(a)]}return t}(t=e),1==n.length&&n[0][2]?Ue(n[0][0],n[0][1]):function(e){return e===t||function(e,t,n,r){var a=n.length,o=a;if(null==e)return!o;for(e=Object(e);a--;){var i=n[a];if(i[2]?i[1]!==e[i[0]]:!(i[0]in e))return!1}for(;++a<o;){var l=(i=n[a])[0],s=e[l],c=i[1];if(i[2]){if(void 0===s&&!(l in e))return!1}else if(!Ee(c,s,r,3,new Ne))return!1}return!0}(e,0,n)}):He(r=e)?(a=Qe(r),function(e){return null==e?void 0:e[a]}):function(e){return function(t){return Re(t,e)}}(r);var t,n,r,a}function Ie(e){if(n=(t=e)&&t.constructor,r="function"==typeof n&&n.prototype||q,t!==r)return oe(e);var t,n,r,a=[];for(var o in Object(e))Z.call(e,o)&&"constructor"!=o&&a.push(o);return a}function De(e){return et(e)?e:Je(e)}function Be(e,t,n,r,a,o){var i=2&a,l=e.length,s=t.length;if(l!=s&&!(i&&s>l))return!1;var c=o.get(e);if(c&&o.get(t))return c==t;var u=-1,f=!0,d=1&a?new _e:void 0;for(o.set(e,t),o.set(t,e);++u<l;){var h=e[u],m=t[u];if(r)var p=i?r(m,h,u,t,e,o):r(h,m,u,e,t,o);if(void 0!==p){if(p)continue;f=!1;break}if(d){if(!L(t,function(e,t){if(!d.has(t)&&(h===e||n(h,e,r,a,o)))return d.add(t)})){f=!1;break}}else if(h!==m&&!n(h,m,r,a,o)){f=!1;break}}return o.delete(e),o.delete(t),f}function Le(e,t){var n,r,a=e.__data__;return("string"==(r=typeof(n=t))||"number"==r||"symbol"==r||"boolean"==r?"__proto__"!==n:null===n)?a["string"==typeof t?"string":"hash"]:a.map}function $e(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return Fe(n)?n:void 0}var ze=function(e){return G.call(e)};function Ve(e,t){return!!(t=null==t?r:t)&&("number"==typeof e||T.test(e))&&e>-1&&e%1==0&&e<t}function He(e,t){if(et(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!it(e))||k.test(e)||!x.test(e)||null!=t&&e in Object(t)}function We(e){return e==e&&!at(e)}function Ue(e,t){return function(n){return null!=n&&n[e]===t&&(void 0!==t||e in Object(n))}}(ie&&ze(new ie(new ArrayBuffer(1)))!=w||le&&ze(new le)!=u||se&&ze(se.resolve())!=h||ce&&ze(new ce)!=p||ue&&ze(new ue)!=b)&&(ze=function(e){var t=G.call(e),n=t==d?e.constructor:void 0,r=n?qe(n):void 0;if(r)switch(r){case de:return w;case he:return u;case me:return h;case pe:return p;case ge:return b}return t});var Je=Ke(function(e){var t;e=null==(t=e)?"":function(e){if("string"==typeof e)return e;if(it(e))return ye?ye.call(e):"";var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}(t);var n=[];return _.test(e)&&n.push(""),e.replace(N,function(e,t,r,a){n.push(r?a.replace(S,"$1"):t||e)}),n});function Qe(e){if("string"==typeof e||it(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}function qe(e){if(null!=e){try{return K.call(e)}catch(e){}try{return e+""}catch(e){}}return""}var Xe,Ye=(Xe=function(e,t,n){Z.call(e,n)?e[n].push(t):e[n]=[t]},function(e,t){return(et(e)?B:Te)(e,Xe,Ae(t),{})});function Ke(e,t){if("function"!=typeof e||t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function(){var r=arguments,a=t?t.apply(this,r):r[0],o=n.cache;if(o.has(a))return o.get(a);var i=e.apply(this,r);return n.cache=o.set(a,i),i};return n.cache=new(Ke.Cache||ke),n}function Ze(e,t){return e===t||e!=e&&t!=t}function Ge(e){return function(e){return ot(e)&&tt(e)}(e)&&Z.call(e,"callee")&&(!re.call(e,"callee")||G.call(e)==a)}Ke.Cache=ke;var et=Array.isArray;function tt(e){return null!=e&&rt(e.length)&&!nt(e)}function nt(e){var t=at(e)?G.call(e):"";return t==c||"[object GeneratorFunction]"==t}function rt(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=r}function at(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function ot(e){return!!e&&"object"==typeof e}function it(e){return"symbol"==typeof e||ot(e)&&G.call(e)==v}var lt=D?function(e){return function(t){return e(t)}}(D):function(e){return ot(e)&&rt(e.length)&&!!j[G.call(e)]};function st(e){return tt(e)?Se(e):Ie(e)}function ct(e){return e}e.exports=Ye}(xh,xh.exports)),xh.exports),Nh=j(_h),Sh={exports:{}};var Mh=(kh||(kh=1,function(e,t){var n="__lodash_hash_undefined__",r=9007199254740991,a="[object Arguments]",o="[object Array]",i="[object Boolean]",l="[object Date]",s="[object Error]",c="[object Function]",u="[object Map]",f="[object Number]",d="[object Object]",h="[object Promise]",m="[object RegExp]",p="[object Set]",g="[object String]",v="[object Symbol]",b="[object WeakMap]",y="[object ArrayBuffer]",w="[object DataView]",x=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,k=/^\w*$/,_=/^\./,N=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,S=/\\(\\)?/g,M=/^\[object .+?Constructor\]$/,T=/^(?:0|[1-9]\d*)$/,j={};j["[object Float32Array]"]=j["[object Float64Array]"]=j["[object Int8Array]"]=j["[object Int16Array]"]=j["[object Int32Array]"]=j["[object Uint8Array]"]=j["[object Uint8ClampedArray]"]=j["[object Uint16Array]"]=j["[object Uint32Array]"]=!0,j[a]=j[o]=j[y]=j[i]=j[w]=j[l]=j[s]=j[c]=j[u]=j[f]=j[d]=j[m]=j[p]=j[g]=j[b]=!1;var O="object"==typeof C&&C&&C.Object===Object&&C,R="object"==typeof self&&self&&self.Object===Object&&self,P=O||R||Function("return this")(),E=t&&!t.nodeType&&t,F=E&&e&&!e.nodeType&&e,A=F&&F.exports===E&&O.process,I=function(){try{return A&&A.binding("util")}catch(e){}}(),D=I&&I.isTypedArray;function B(e,t){for(var n=-1,r=e?e.length:0,a=Array(r);++n<r;)a[n]=t(e[n],n,e);return a}function L(e,t){for(var n=-1,r=e?e.length:0;++n<r;)if(t(e[n],n,e))return!0;return!1}function $(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}function z(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}function V(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}var H,W,U,J=Array.prototype,Q=Function.prototype,q=Object.prototype,X=P["__core-js_shared__"],Y=(H=/[^.]+$/.exec(X&&X.keys&&X.keys.IE_PROTO||""))?"Symbol(src)_1."+H:"",K=Q.toString,Z=q.hasOwnProperty,G=q.toString,ee=RegExp("^"+K.call(Z).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),te=P.Symbol,ne=P.Uint8Array,re=q.propertyIsEnumerable,ae=J.splice,oe=(W=Object.keys,U=Object,function(e){return W(U(e))}),ie=$e(P,"DataView"),le=$e(P,"Map"),se=$e(P,"Promise"),ce=$e(P,"Set"),ue=$e(P,"WeakMap"),fe=$e(Object,"create"),de=qe(ie),he=qe(le),me=qe(se),pe=qe(ce),ge=qe(ue),ve=te?te.prototype:void 0,be=ve?ve.valueOf:void 0,ye=ve?ve.toString:void 0;function we(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function xe(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function ke(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function _e(e){var t=-1,n=e?e.length:0;for(this.__data__=new ke;++t<n;)this.add(e[t])}function Ne(e){this.__data__=new xe(e)}function Se(e,t){var n=Ze(e)||Ke(e)?function(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}(e.length,String):[],r=n.length,a=!!r;for(var o in e)!Z.call(e,o)||a&&("length"==o||Ve(o,r))||n.push(o);return n}function Me(e,t){for(var n=e.length;n--;)if(Ye(e[n][0],t))return n;return-1}we.prototype.clear=function(){this.__data__=fe?fe(null):{}},we.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},we.prototype.get=function(e){var t=this.__data__;if(fe){var r=t[e];return r===n?void 0:r}return Z.call(t,e)?t[e]:void 0},we.prototype.has=function(e){var t=this.__data__;return fe?void 0!==t[e]:Z.call(t,e)},we.prototype.set=function(e,t){return this.__data__[e]=fe&&void 0===t?n:t,this},xe.prototype.clear=function(){this.__data__=[]},xe.prototype.delete=function(e){var t=this.__data__,n=Me(t,e);return!(n<0||(n==t.length-1?t.pop():ae.call(t,n,1),0))},xe.prototype.get=function(e){var t=this.__data__,n=Me(t,e);return n<0?void 0:t[n][1]},xe.prototype.has=function(e){return Me(this.__data__,e)>-1},xe.prototype.set=function(e,t){var n=this.__data__,r=Me(n,e);return r<0?n.push([e,t]):n[r][1]=t,this},ke.prototype.clear=function(){this.__data__={hash:new we,map:new(le||xe),string:new we}},ke.prototype.delete=function(e){return Le(this,e).delete(e)},ke.prototype.get=function(e){return Le(this,e).get(e)},ke.prototype.has=function(e){return Le(this,e).has(e)},ke.prototype.set=function(e,t){return Le(this,e).set(e,t),this},_e.prototype.add=_e.prototype.push=function(e){return this.__data__.set(e,n),this},_e.prototype.has=function(e){return this.__data__.has(e)},Ne.prototype.clear=function(){this.__data__=new xe},Ne.prototype.delete=function(e){return this.__data__.delete(e)},Ne.prototype.get=function(e){return this.__data__.get(e)},Ne.prototype.has=function(e){return this.__data__.has(e)},Ne.prototype.set=function(e,t){var n=this.__data__;if(n instanceof xe){var r=n.__data__;if(!le||r.length<199)return r.push([e,t]),this;n=this.__data__=new ke(r)}return n.set(e,t),this};var Te,Ce=(Te=function(e,t){return e&&je(e,t,it)},function(e,t){if(null==e)return e;if(!Ge(e))return Te(e,t);for(var n=e.length,r=-1,a=Object(e);++r<n&&!1!==t(a[r],r,a););return e}),je=function(e,t,n){for(var r=-1,a=Object(e),o=n(e),i=o.length;i--;){var l=o[++r];if(!1===t(a[l],l,a))break}return e};function Oe(e,t){for(var n=0,r=(t=He(t,e)?[t]:De(t)).length;null!=e&&n<r;)e=e[Qe(t[n++])];return n&&n==r?e:void 0}function Re(e,t){return null!=e&&t in Object(e)}function Pe(e,t,n,r,c){return e===t||(null==e||null==t||!nt(e)&&!rt(t)?e!=e&&t!=t:function(e,t,n,r,c,h){var b=Ze(e),x=Ze(t),k=o,_=o;b||(k=(k=ze(e))==a?d:k),x||(_=(_=ze(t))==a?d:_);var N=k==d&&!$(e),S=_==d&&!$(t),M=k==_;if(M&&!N)return h||(h=new Ne),b||ot(e)?Be(e,t,n,r,c,h):function(e,t,n,r,a,o,c){switch(n){case w:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case y:return!(e.byteLength!=t.byteLength||!r(new ne(e),new ne(t)));case i:case l:case f:return Ye(+e,+t);case s:return e.name==t.name&&e.message==t.message;case m:case g:return e==t+"";case u:var d=z;case p:var h=2&o;if(d||(d=V),e.size!=t.size&&!h)return!1;var b=c.get(e);if(b)return b==t;o|=1,c.set(e,t);var x=Be(d(e),d(t),r,a,o,c);return c.delete(e),x;case v:if(be)return be.call(e)==be.call(t)}return!1}(e,t,k,n,r,c,h);if(!(2&c)){var T=N&&Z.call(e,"__wrapped__"),C=S&&Z.call(t,"__wrapped__");if(T||C){var j=T?e.value():e,O=C?t.value():t;return h||(h=new Ne),n(j,O,r,c,h)}}return!!M&&(h||(h=new Ne),function(e,t,n,r,a,o){var i=2&a,l=it(e),s=l.length,c=it(t),u=c.length;if(s!=u&&!i)return!1;for(var f=s;f--;){var d=l[f];if(!(i?d in t:Z.call(t,d)))return!1}var h=o.get(e);if(h&&o.get(t))return h==t;var m=!0;o.set(e,t),o.set(t,e);for(var p=i;++f<s;){var g=e[d=l[f]],v=t[d];if(r)var b=i?r(v,g,d,t,e,o):r(g,v,d,e,t,o);if(!(void 0===b?g===v||n(g,v,r,a,o):b)){m=!1;break}p||(p="constructor"==d)}if(m&&!p){var y=e.constructor,w=t.constructor;y==w||!("constructor"in e)||!("constructor"in t)||"function"==typeof y&&y instanceof y&&"function"==typeof w&&w instanceof w||(m=!1)}return o.delete(e),o.delete(t),m}(e,t,n,r,c,h))}(e,t,Pe,n,r,c))}function Ee(e){return!(!nt(e)||function(e){return!!Y&&Y in e}(e))&&(et(e)||$(e)?ee:M).test(qe(e))}function Fe(e){return"function"==typeof e?e:null==e?lt:"object"==typeof e?Ze(e)?function(e,t){return He(e)&&We(t)?Ue(Qe(e),t):function(n){var r=function(e,t,n){var r=null==e?void 0:Oe(e,t);return void 0===r?n:r}(n,e);return void 0===r&&r===t?function(e,t){return null!=e&&function(e,t,n){t=He(t,e)?[t]:De(t);for(var r,a=-1,o=t.length;++a<o;){var i=Qe(t[a]);if(!(r=null!=e&&n(e,i)))break;e=e[i]}return r||!!(o=e?e.length:0)&&tt(o)&&Ve(i,o)&&(Ze(e)||Ke(e))}(e,t,Re)}(n,e):Pe(t,r,void 0,3)}}(e[0],e[1]):(n=function(e){for(var t=it(e),n=t.length;n--;){var r=t[n],a=e[r];t[n]=[r,a,We(a)]}return t}(t=e),1==n.length&&n[0][2]?Ue(n[0][0],n[0][1]):function(e){return e===t||function(e,t,n,r){var a=n.length,o=a;if(null==e)return!o;for(e=Object(e);a--;){var i=n[a];if(i[2]?i[1]!==e[i[0]]:!(i[0]in e))return!1}for(;++a<o;){var l=(i=n[a])[0],s=e[l],c=i[1];if(i[2]){if(void 0===s&&!(l in e))return!1}else if(!Pe(c,s,r,3,new Ne))return!1}return!0}(e,0,n)}):He(r=e)?(a=Qe(r),function(e){return null==e?void 0:e[a]}):function(e){return function(t){return Oe(t,e)}}(r);var t,n,r,a}function Ae(e){if(n=(t=e)&&t.constructor,r="function"==typeof n&&n.prototype||q,t!==r)return oe(e);var t,n,r,a=[];for(var o in Object(e))Z.call(e,o)&&"constructor"!=o&&a.push(o);return a}function Ie(e,t){var n=-1,r=Ge(e)?Array(e.length):[];return Ce(e,function(e,a,o){r[++n]=t(e,a,o)}),r}function De(e){return Ze(e)?e:Je(e)}function Be(e,t,n,r,a,o){var i=2&a,l=e.length,s=t.length;if(l!=s&&!(i&&s>l))return!1;var c=o.get(e);if(c&&o.get(t))return c==t;var u=-1,f=!0,d=1&a?new _e:void 0;for(o.set(e,t),o.set(t,e);++u<l;){var h=e[u],m=t[u];if(r)var p=i?r(m,h,u,t,e,o):r(h,m,u,e,t,o);if(void 0!==p){if(p)continue;f=!1;break}if(d){if(!L(t,function(e,t){if(!d.has(t)&&(h===e||n(h,e,r,a,o)))return d.add(t)})){f=!1;break}}else if(h!==m&&!n(h,m,r,a,o)){f=!1;break}}return o.delete(e),o.delete(t),f}function Le(e,t){var n,r,a=e.__data__;return("string"==(r=typeof(n=t))||"number"==r||"symbol"==r||"boolean"==r?"__proto__"!==n:null===n)?a["string"==typeof t?"string":"hash"]:a.map}function $e(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return Ee(n)?n:void 0}var ze=function(e){return G.call(e)};function Ve(e,t){return!!(t=null==t?r:t)&&("number"==typeof e||T.test(e))&&e>-1&&e%1==0&&e<t}function He(e,t){if(Ze(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!at(e))||k.test(e)||!x.test(e)||null!=t&&e in Object(t)}function We(e){return e==e&&!nt(e)}function Ue(e,t){return function(n){return null!=n&&n[e]===t&&(void 0!==t||e in Object(n))}}(ie&&ze(new ie(new ArrayBuffer(1)))!=w||le&&ze(new le)!=u||se&&ze(se.resolve())!=h||ce&&ze(new ce)!=p||ue&&ze(new ue)!=b)&&(ze=function(e){var t=G.call(e),n=t==d?e.constructor:void 0,r=n?qe(n):void 0;if(r)switch(r){case de:return w;case he:return u;case me:return h;case pe:return p;case ge:return b}return t});var Je=Xe(function(e){var t;e=null==(t=e)?"":function(e){if("string"==typeof e)return e;if(at(e))return ye?ye.call(e):"";var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}(t);var n=[];return _.test(e)&&n.push(""),e.replace(N,function(e,t,r,a){n.push(r?a.replace(S,"$1"):t||e)}),n});function Qe(e){if("string"==typeof e||at(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}function qe(e){if(null!=e){try{return K.call(e)}catch(e){}try{return e+""}catch(e){}}return""}function Xe(e,t){if("function"!=typeof e||t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function(){var r=arguments,a=t?t.apply(this,r):r[0],o=n.cache;if(o.has(a))return o.get(a);var i=e.apply(this,r);return n.cache=o.set(a,i),i};return n.cache=new(Xe.Cache||ke),n}function Ye(e,t){return e===t||e!=e&&t!=t}function Ke(e){return function(e){return rt(e)&&Ge(e)}(e)&&Z.call(e,"callee")&&(!re.call(e,"callee")||G.call(e)==a)}Xe.Cache=ke;var Ze=Array.isArray;function Ge(e){return null!=e&&tt(e.length)&&!et(e)}function et(e){var t=nt(e)?G.call(e):"";return t==c||"[object GeneratorFunction]"==t}function tt(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=r}function nt(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function rt(e){return!!e&&"object"==typeof e}function at(e){return"symbol"==typeof e||rt(e)&&G.call(e)==v}var ot=D?function(e){return function(t){return e(t)}}(D):function(e){return rt(e)&&tt(e.length)&&!!j[G.call(e)]};function it(e){return Ge(e)?Se(e):Ae(e)}function lt(e){return e}e.exports=function(e,t){return(Ze(e)?B:Ie)(e,Fe(t))}}(Sh,Sh.exports)),Sh.exports),Th=j(Mh);function Ch(e){const t={numTicks:0,maxSelf:0,names:[],levels:[]},n={},r={children:[]};return e.spans.forEach(e=>{e.children=[],n[e.spanID]=e}),e.spans.forEach(e=>{let t=r;e.references&&e.references.length>0&&(t=n[e.references[0].spanID]||r),t.children.push(e)}),function e(t,n){(t.children||[]).forEach(t=>e(t));let r=0;const a=Nh(t.children||[],e=>e.operationName);t.children=Th(a,e=>{const t=e[0];for(let n=1;n<e.length;n+=1)t.duration+=e[n].duration;return r+=t.duration,t}),t.total=t.duration||r,t.self=Math.max(0,t.total-r)}(r),function n(r,a,o){var i;return t.numTicks||(t.numTicks=r.total),(i=t.levels)[a]||(i[a]=[]),t.levels[a].push(o),t.levels[a].push(r.total),t.levels[a].push(r.self),t.names.push((r.processID?`${e.processes[r.processID].serviceName}: `:"")+(r.operationName||"total")),t.levels[a].push(t.names.length-1),(r.children||[]).forEach(e=>{o+=n(e,a+1,o)}),r.total}(r,0,0),t.levels=hh("single",t.levels),{version:1,flamebearer:t,metadata:{format:"single",units:"trace_samples",spyName:"tracing",sampleRate:1e6}}}function jh(e,t){e.flamebearer.levels=mh("single",e.flamebearer.levels),t.flamebearer.levels=mh("single",t.flamebearer.levels);const n=function(e,t){const n={format:"double",numTicks:e.numTicks+t.numTicks,leftTicks:e.numTicks,rightTicks:t.numTicks,maxSelf:100,sampleRate:e.sampleRate,names:[],levels:[],units:e.units,spyName:e.spyName},r=Yd(e,t),a=(e,t,r,o)=>{var i;const{name:l,children:s,self:c,total:u}=e;n.names.push(l),(i=n.levels)[t]||(i[t]=[]),n.maxSelf=Math.max(n.maxSelf,c[0]||0,c[1]||0),n.levels[t]=n.levels[t].concat([r,u[0]||0,c[0]||0,o,u[1]||0,c[1]||0,n.names.length-1]);for(let e=0;e<s.length;e+=1){const[n,i]=a(s[e],t+1,r,o);r+=n,o+=i}return[u[0]||0,u[1]||0]};return a(r,0,0,0),n}(e.flamebearer,t.flamebearer);n.levels=hh("double",n.levels);const r={...e.metadata};return r.format="double",{version:1,flamebearer:n,metadata:r,leftTicks:e.flamebearer.numTicks,rightTicks:t.flamebearer.numTicks}}export{fa as Box,vc as DefaultPalette,Pl as Flamegraph,Mc as FlamegraphI18nProvider,yh as FlamegraphRenderer,Ch as convertJaegerTraceToProfile,jh as diffTwoProfiles,kc as flamegraphDefaultMessages,_c as flamegraphZhCNMessages};
|
|
18
18
|
//# sourceMappingURL=index.node.esm.js.map
|