(()=>{"use strict";var e,t,r,s,n,i,o={44676(e,t,r){var s=r(65723);r(92958);var n=r(58997);r(22155);var i=r(41346),o=r(84475);function a(){return(0,s.jsxs)(i.BV,{children:[(0,s.jsx)(i.qh,{path:"/",element:(0,s.jsx)(o.aD.YW,{})}),(0,s.jsx)(i.qh,{path:o.aD.wE,element:(0,s.jsx)(o.aD.YW,{})})]})}var l=r(22797);r(11097);let d=document.getElementById("root");n.createRoot(d).render((0,s.jsx)(()=>(0,s.jsx)(l.A,{router:(0,s.jsx)(a,{})}),{}));let u=document.createElement("link");u.setAttribute("type","image/x-icon"),u.setAttribute("rel","icon"),u.setAttribute("href","https://assets.rspack.rs/rsdoctor/rsdoctor-logo-960x960.png"),document.head.appendChild(u)},85817(e,t,r){r.d(t,{A:()=>n});var s=r(65723);r(22155);let n=e=>(0,s.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",width:16,height:16,fill:"none",viewBox:"0 0 16 16",...e,children:[(0,s.jsx)("rect",{width:16,height:16,fill:"#FFF7E6",rx:2}),(0,s.jsx)("g",{clipPath:"url(#total-size_svg__a)",children:(0,s.jsx)("path",{fill:"#F2793D",d:"m2.5 5.77 5.026 2.534V13.5L2.5 11.011zm11-.016v5.23l-1.775.881-1.508.747-1.685.854V8.254zM8 2.5l4.902 2.472L7.999 7.45 3.04 4.961z"})}),(0,s.jsx)("defs",{children:(0,s.jsx)("clipPath",{id:"total-size_svg__a",children:(0,s.jsx)("path",{fill:"#fff",d:"M2 2h12v12H2z"})})})]})},78363(e,t,r){r.d(t,{EJ:()=>c.EJ});var s=r(65723),n=r(22155),i=r(91888),o=r(98685),a=r(37447),l=r(74579),d=r(10117),u=r(21376),h=r(35500);(0,l.eN)({api:i.hp.ServerAPI.API.GetProjectInfo,responsePropName:"project",Component:e=>{let{filter:t,project:r}=e,{errors:i,root:l}=r,{setBundleAlertsViewMode:c,viewMode:p,setViewMode:f}=(0,o.useViewMode)(),{t:m}=(0,o.useI18n)(),g=t?i.filter(t):i;return(0,n.useEffect)(()=>{(0,o.hasViewModeFromStorage)()||f({bundleAlerts:i.length>=5?d.nE.Group:d.nE.List},!1)},[]),(0,s.jsx)(h.Ay,{theme:{components:{Alert:{colorInfoBg:"#e6f4ff57",colorInfoBorder:"none"}},token:{padding:16,colorText:"rgba(0, 0, 0, 0.85)"}},children:(0,s.jsx)(a.J,{title:m("Bundle Alerts"),dataSource:g,extraData:{cwd:l,getPackageRelationContentComponent:e=>(0,s.jsx)(u.rU,{body:{id:e.data.id,target:e.package.target},cwd:l})},viewMode:p.bundleAlerts,setViewMode:c,cwd:l})})}}),r(30942);var c=r(49084)},57568(e,t,r){r.d(t,{dK:()=>s,wx:()=>i});let s=["#F2793D","#F28B24","#F2A200","#F5CC00","#F5E000","#A3D900","#66CC00","#0AC419","#0AC496","#0AC7D1","#00A8E0","#1471F5","#4060FF","#7559FF","#884DFF","#A526FF","#BA39E5","#C700D9","#D900B5","#E50099","#E52E6B","#F24957","#30B2F2","#00BF70","#5959FF","#9F40FF","#528BFF"];var n,i=((n={})[n.Bootstrap=0]="Bootstrap",n[n.Compile=1]="Compile",n[n.Done=2]="Done",n[n.Minify=3]="Minify",n[n.Loader=4]="Loader",n[n.Normal=5]="Normal",n)},54132(e,t,r){r.d(t,{Bq:()=>u,Wy:()=>c,iv:()=>h});var s=r(40799),n=r(80286),i=r.n(n),o=r(27893),a=r(18457),l=r(98685);r(57585);var d=r(22155);function u(e){return`
  <div class="loader-tooltip-container">
    <div class="loader-tooltip-title">${e.loader}</div>
    <li class="loader-tooltip-item">
      <span>isPitch</span>
      <span>${e.isPitch}</span>
    </li>
    ${e.layer&&"undefined"!==e.layer?`<li class="loader-tooltip-item">
        <span>layer</span>
        <span>${e.layer}</span>
      </li>`:""}
    <li class="loader-tooltip-item">
      <span>duration</span>
      <span class="loader-tooltip-text-bold">${(0,l.formatCosts)(e.costs)}</span>
    </li>
    <li class="loader-tooltip-item">
      <span>filepath</span>
      <span>${e.resource}</span>
    </li>
    <li class="loader-tooltip-item">
      <span>start</span>
      <span class="loader-tooltip-text-bold">${i()(e.startAt).format("YYYY/MM/DD HH:mm:ss")}</span>
    </li>
    <li class="loader-tooltip-item">
      <span>end</span>
      <span class="loader-tooltip-text-bold">${i()(e.endAt).format("YYYY/MM/DD HH:mm:ss")}</span>
    </li>
  </div>
  `.trim()}function h(e,t,r){let n=t=>t.loader===e,d=t.filter(n),u=d.map(e=>e.resource),h=u.filter(e=>e.includes("/node_modules/")),c=u.filter(e=>!e.startsWith(r)),p=(0,o.w)(d,e=>e.startAt).startAt,f=(0,a.S)(d,e=>e.endAt).endAt,m=s.aH.getLoadersCosts(n,t);return`
<div class="loader-tooltip-container">
  <div class="loader-tooltip-title">${e}</div>
  <li class="loader-tooltip-item">
    <span>files</span>
    <span class="loader-tooltip-text-bold">${u.length}</span>
  </li>
  <li class="loader-tooltip-item">
    <span>files(node_modules)</span>
    <span class="loader-tooltip-text-bold">${h.length}</span>
  </li>
  <li class="loader-tooltip-item">
    <span>files(outside the cwd)</span>
    <span class="loader-tooltip-text-bold">${c.length}</span>
  </li>
  <li class="loader-tooltip-item">
    <span>duration(estimated)</span>
    <span class="loader-tooltip-text-bold">${(0,l.formatCosts)(m)}</span>
  </li>
  <li class="loader-tooltip-item">
    <span>start(min)</span>
    <span>${i()(p).format("YYYY/MM/DD HH:mm:ss")}</span>
  </li>
  <li class="loader-tooltip-item">
    <span>end(max)</span>
    <span>${i()(f).format("YYYY/MM/DD HH:mm:ss")}</span>
  </li>
  </div>
    `.trim()}function c(e,t){let[r,s]=(0,d.useState)(e);return(0,d.useEffect)(()=>{let r=setTimeout(()=>s(e),t);return()=>clearTimeout(r)},[e,t]),r}},54050(e,t,r){var s=r(65723),n=r(91888),i=r(63079),o=r(60503),a=r(66287),l=r(66020),d=r(43995),u=r(68108),h=r(22155),c=r(43092),p=r.n(c),f=r(98685),m=r(74579),g=r(14760),y=r(90220),v=r(203),M=r(40799);(0,m.eN)({Component:e=>{let{defaultKeys:t,configs:r}=e,n=(0,f.useWebpackConfigurationByConfigs)(r||[]);if(!n)return null;let{config:c,version:m,name:A}=n,S=Object.keys(c),[x,I]=(0,h.useState)(t||S);return(0,s.jsxs)(g.hX,{text:(0,s.jsxs)("div",{className:v.A.title,children:[(0,s.jsx)("span",{style:{marginRight:"8px",fontSize:"13px"},children:"View Bundler Config"}),(0,s.jsx)(u.A,{style:{fontSize:"10px"}})]}),children:[(0,s.jsxs)(i.A,{children:[(0,s.jsx)(y.h,{text:"Bundler Config Viewer"}),(0,s.jsx)(o.A,{}),(0,s.jsxs)(a.A,{children:[(0,s.jsx)(l.A.Text,{children:"Properties: "}),(0,s.jsx)(d.A,{dropdownStyle:{zIndex:999},mode:"multiple",allowClear:!0,value:x.length===S.length?[]:x,style:{width:350},popupMatchSelectWidth:!0,placeholder:"Show Selected Properties Only.",onChange:e=>{I(e)},children:S.map(e=>(0,s.jsx)(d.A.Option,{label:e,value:e,children:e},e))})]}),(0,s.jsx)(o.A,{})]}),(0,s.jsx)(p(),{name:m&&"unknown"!==m?`${A}@${m}`:"webpack.config",theme:"monokai",src:0===x.length?c:M.AP.pick(c,x),displayDataTypes:!1,displayObjectSize:!1,style:{overflowX:"auto"}})]})},api:n.hp.ServerAPI.API.LoadDataByKey,responsePropName:"configs",body:{key:"configs"},showSkeleton:!1})},78899(e,t,r){r.d(t,{i:()=>a});var s=r(65723);r(22155);var n=r(66020),i=r(28342),o=r(76385);let a=e=>{let{text:t,keyword:r,...i}=e;if(!r||-1===t.indexOf(r))return l({text:t,rest:i});let a=[],d=t;for(;d.length>0;){let e=d.indexOf(r);if(e>-1)0!==e&&a.push(l({text:d,els:a})),a.push(l({text:d,els:a,marked:!0})),d=d.slice(e+r.length);else{a.push(l({text:d,els:a,marked:!0}));break}}return(0,s.jsx)(n.A.Text,{className:o.A.text,...i,children:a})},l=e=>{let{text:t,els:r,marked:a=!1,rest:l}=e;if(!t)return null;let d=t.length;if(d>40){let e=Math.floor(18.5),r=Math.ceil(18.5);return(0,s.jsx)(i.A,{content:t,placement:"left",children:(0,s.jsx)("div",{children:(0,s.jsxs)(n.A.Text,{className:o.A.text,mark:!!a,...l,children:[t.slice(0,e),"...",t.slice(d-r)]})})})}return(0,s.jsx)(i.A,{content:t,children:(0,s.jsx)("div",{children:(0,s.jsx)(n.A.Text,{className:o.A.text,...l,children:t},r?r.length:0)})})}},99008(e,t,r){r.d(t,{h:()=>s});let s=(0,r(22155).createContext)({project:null})},99359(e,t,r){r.d(t,{e:()=>f,z:()=>p});var s=r(65723),n=r(91888),i=r(13238),o=r(71886),a=r(22155),l=r(55979),d=r(98685),u=r(10117),h=r(60678),c=r(40799);let p=e=>{let{manifestLoader:t=d.fetchManifest,api:r,children:p,body:f=null,showSkeleton:m=!0,fallbackComponent:g}=e,[y,v]=(0,a.useState)(),[M,A]=(0,a.useState)(u.nl.Pending),[S,x]=(0,a.useState)({}),{loader:I}=(0,d.useDataLoader)(y);function P(e){window[n.YM.WINDOW_RSDOCTOR_TAG]?D(e):t().then(e=>{v(e)}).catch(e=>{if(!("u"<typeof window)&&window.location.hash.includes(n.Kj.RsdoctorClientRoutes.Uploader)){console.warn("[ServerAPIProvider] Failed to load manifest for uploader route, continuing with empty manifest:",e),A(u.nl.Success);return}throw A(u.nl.Fail),e}).then(()=>{D(e)})}let E=(0,a.useCallback)(e=>{let{req:t,res:s}=e;t.api===r&&((0,l.n)(t.body,f)||c.AP.isNil(t.body)&&c.AP.isNil(f))&&!(0,l.n)(S,s)&&x(s),A(u.nl.Success)},[S,r,f]);function D(e){e&&(Object.values(n.hp.ServerAPI.APIExtends).includes(r)?A(u.nl.Success):e.loadAPI(r,f).then(e=>{c.AP.isNil(e)||(x(e),A(u.nl.Success))}).catch(e=>{console.error(e),A(u.nl.Fail)}))}return((0,a.useEffect)(()=>{P(I)},[I,r,f]),(0,a.useEffect)(()=>{if(I)return I.onDataUpdate(r,E),()=>{I.removeOnDataUpdate(r,E)}},[I,r,f]),M===u.nl.Pending)?m?(0,s.jsx)(i.A,{active:!0}):null:M===u.nl.Fail?g||(0,s.jsx)(h.c,{retry:()=>{A(u.nl.Pending),t(),P()}}):M===u.nl.Updating?(0,s.jsx)(o.A,{spinning:!0,children:p(S)}):p(S)};function f(e){let{Component:t,api:r,responsePropName:n,body:i,fallbackComponent:o,showSkeleton:a}=e;return function(e){let{body:l=i,...d}=e;return(0,s.jsx)(p,{api:r,body:l,showSkeleton:a,fallbackComponent:o,children:e=>{let r={...d,[n]:e};return(0,s.jsx)(t,{...r})}})}}},25957(e,t,r){r.d(t,{u:()=>d});var s=r(65723),n=r(13238),i=r(22155),o=r(98685),a=r(10117),l=r(60678);function d(e,t,r){let d=e();return function(){let[u,h]=(0,i.useState)(),[c,p]=(0,i.useState)(a.jK.Pending),[f,m]=(0,i.useState)({}),{loader:g}=(0,o.useDataLoader)(u);function y(e){return e.then(e=>{h(e)}).catch(()=>{p(a.jK.Fail)})}function v(e){e&&Promise.all(t.map(t=>{let[r]=t;return e.loadData(r)})).then(e=>{m(e.reduce((e,r,s)=>{let[n,i]=t[s];return e[i]=r,e},{})),p(a.jK.Success)}).catch(e=>{console.error(e),p(a.jK.Fail)})}return((0,i.useEffect)(()=>{y(d).then(()=>{v(g)})},[g]),c===a.jK.Pending)?(0,s.jsx)(n.A,{active:!0}):c===a.jK.Fail?(0,s.jsx)(l.c,{retry:()=>{p(a.jK.Pending),d.then(()=>{v(g)}).catch(()=>{y(e())})}}):(0,s.jsx)(r,{...f})}}},82751(e,t,r){r(65723),r(22155);var s=r(24801);r(53289),r(98685),r(14760),r(30786),r(74579),r(59606),r(45192),r(85817),r(44710),r(91888),r(31434);let{DirectoryTree:n}=s.A;r(40799),r(37080),r(57585),r(53878),r(54132),r(91671),r(7707),r(54050),r(23230),r(92603)},23230(e,t,r){r.d(t,{A:()=>n,h:()=>i});var s=r(65723);r(32969);let n=e=>{let{title:t,description:r,icon:n,style:i}=e;return(0,s.jsxs)("div",{className:"container-KSV5DZ",style:i,children:[(0,s.jsxs)("div",{className:"content-BsjkSU",children:[(0,s.jsx)("div",{className:"title-jUwqD5",children:t}),(0,s.jsx)("div",{className:"description-ArkOg4",children:r})]}),n]})},i=n},91671(e,t,r){r(65723),r(22155),r(98685)},60678(e,t,r){r.d(t,{c:()=>l});var s=r(65723),n=r(87417),i=r(66287),o=r(66020),a=r(47748);let l=r(22155).memo(e=>{let{title:t="Load data failed, please try again",buttonText:r="retry",retry:l}=e;return(0,s.jsx)(n.A,{description:(0,s.jsxs)(i.A,{direction:"vertical",children:[(0,s.jsx)(o.A.Text,{children:t}),(0,s.jsx)(a.Ay,{type:"primary",onClick:()=>{l()},children:r})]})})})},75652(e,t,r){r(65723),r(22155),r(85240)},21919(e,t,r){r.d(t,{PE:()=>s.P}),r(78363),r(35471),r(68850),r(30786),r(94175);var s=r(70972);r(74579),r(82751),r(14760),r(53878)},45554(e,t,r){r.d(t,{U:()=>n,w:()=>i});var s=r(91888);let n="Overall",i=s.Kj.RsdoctorClientRoutes.Overall},84475(e,t,r){r.d(t,{_y:()=>n,aD:()=>eM,pI:()=>i,dn:()=>l,FO:()=>a,hK:()=>o});var s,n={};r.r(n),r.d(n,{UU:()=>F,wE:()=>T});var i={};r.r(i),r.d(i,{UU:()=>W,wE:()=>Y});var o={};r.r(o),r.d(o,{UU:()=>Z,wE:()=>H});var a={};r.r(a),r.d(a,{UU:()=>X,wE:()=>ee});var l={};r.r(l),r.d(l,{UU:()=>ec,wE:()=>ep});var d=r(65723),u=r(22155);r(30786);var h=r(98685);r(41625),r(78363),r(82751),r(1360),r(99008),r(45554);var c=r(10117),p=r(91888),f=r(43995);r(75652),r(35471);var m=r(53289),g=r(94175);r(78899);var y=r(74579),v=r(24801),M=r(13078),A=r.n(M),S=r(68850);r(14760),r(56359),r(99979),r(79583),r(96417),r(44644),r(59914),p.Kj.RsdoctorClientRoutes.ModuleAnalyze,r(54900);var x=r(40799),I=((s={})[s.Reasons=0]="Reasons",s[s.Dependencies=1]="Dependencies",s);I[0],I[0],I[1],I[1],r(96555);let{DirectoryTree:P}=v.A;var E=r(19143);r(25800),r(35282);let{DirectoryTree:D}=v.A;r(23230),r(45927);let{DirectoryTree:k}=v.A,{useToken:b}=E.A,{innerWidth:_}=window;r(47930);var j=r(32354);r(21919);let{Search:C}=j.A;r(62188);var w=r(36473),z=r(22570),R=r(26658),B=r(30574),G=r(61223);r(76144),w.Y([z.a,R.a,B.a,G.a]);let{Option:O}=f.A,F="BundleSize",T=p.Kj.RsdoctorClientRoutes.BundleSize;r(54050);var N=r(85333),$=r(76627),L=r(47001),K=r(66287);(0,y.eN)({api:p.hp.ServerAPI.API.GetProjectInfo,responsePropName:"project",Component:e=>{let{project:t}=e,{root:r}=t,[s,n]=(0,u.useState)({filename:"",loaders:[],layer:""}),[i,o]=(0,u.useState)(0);return(0,d.jsxs)(K.A,{direction:"vertical",style:{width:"100%"},children:[(0,d.jsx)(y.zW,{api:p.hp.ServerAPI.API.GetLoaderNames,children:e=>(0,d.jsx)(N.F,{onChange:n,loaderNames:e})}),(0,d.jsx)(y.zW,{api:p.hp.ServerAPI.API.GetLoaderChartData,children:e=>{let t=e.filter(e=>(0,L.ak)(e.resource,e.loader,s.filename,s.loaders,e.layer,null==s?void 0:s.layer));return 0===i?(0,d.jsx)($.z,{loaders:t,cwd:r}):(0,d.jsx)(d.Fragment,{})}})]})}});let W="Loaders Timeline",Y=p.Kj.RsdoctorClientRoutes.WebpackLoaderOverall;var U=r(35500),q=r(17400),Q=r(24364),V=r(45742);(0,y.eN)({api:p.hp.ServerAPI.API.LoadDataByKey,body:{key:"root"},responsePropName:"cwd",Component:e=>{let{cwd:t}=e,[r,s]=(0,u.useState)({filename:"",loaders:[],layer:""});return(0,d.jsx)(q.Q.Consumer,{children:e=>(0,d.jsx)(U.Ay,{locale:(0,h.getLocale)(e.locale),theme:{token:{padding:16,fontSize:14}},children:(0,d.jsxs)("div",{className:V.A.loaderAnalysis,children:[(0,d.jsx)(y.zW,{api:p.hp.ServerAPI.API.GetLoaderNames,children:e=>(0,d.jsx)(N.F,{onChange:e=>s(e),loaderNames:e})}),(0,d.jsx)(y.zW,{api:p.hp.ServerAPI.API.GetLoaderFileTree,children:e=>(0,d.jsx)(Q.h,{filename:r.filename,filetree:e,loaders:r.loaders,layer:r.layer,cwd:t})})]})})})}}),r(25205);let Z="Loaders Analysis",H=p.Kj.RsdoctorClientRoutes.WebpackLoaderAnalysis,{useToken:J}=E.A;r(91671),r(53967);let X="Plugins Analysis",ee=p.Kj.RsdoctorClientRoutes.WebpackPlugins;var et=r(40961),er=r(45917),es=r(84585),en=r(84262),ei=r(94042),eo=r(36025),ea=r(66020),el=r(63079),ed=r(70580);let eu=e=>{let{filepath:t,before:r,after:s,resolvers:n}=e;return(0,d.jsx)(es.A,{flex:1,children:(0,d.jsx)(en.A,{defaultActiveKey:"diff",items:[{key:"diff",label:"Resolve Diff Viewer",children:(0,d.jsx)(ei.A,{styles:{body:{padding:0,overflow:"hidden"}},children:(0,d.jsx)(S.Mh,{style:{height:785},isEmbed:!0,originalFilePath:t,modifiedFilePath:t,original:r,modified:s})})},{key:"details",label:"Resolve Details",children:(0,d.jsx)(ei.A,{children:(0,d.jsx)(eo.A,{style:{width:"100%",height:735,overflowY:"scroll",wordBreak:"break-all"},size:"small",pagination:!1,bordered:!0,rowKey:e=>e.request,columns:[{title:"Source Code",width:200,render:(e,t)=>(0,d.jsx)(ea.A.Text,{copyable:!0,children:(0,d.jsx)(ea.A.Text,{code:!0,strong:!0,children:t.request})})},{title:"Duration",width:80,render:(e,t)=>(0,d.jsx)(ea.A.Text,{strong:!0,children:(0,h.formatCosts)(t.costs)}),sorter:(e,t)=>e.costs-t.costs,sortDirections:["descend","ascend"]},{title:"Resolve Result",render:(e,t)=>x.xR.isResolveSuccessData(t)?(0,d.jsx)(ea.A.Text,{copyable:!0,children:t.result}):(0,d.jsx)(et.A,{style:{color:"#f50"}})}],dataSource:n})})}]})})},eh=e=>{let{resolver:t,cwd:r}=e,[s,n]=(0,u.useState)(""),i="/node_modules/",o=(0,u.useMemo)(()=>t.map(e=>e.issuerPath).filter(Boolean),[t]),a=(0,u.useMemo)(()=>o.filter(t=>!e.filename||t.indexOf(e.filename)>-1),[e.filename,o]),l=a.length&&a.every(e=>e.indexOf(i)>-1),f=(0,u.useMemo)(()=>(0,h.createFileStructures)({files:a.length?a:o,cwd:r,fileTitle:(e,t)=>(0,d.jsx)("div",{onClick:()=>n(e),children:t})}),[e.filename]);return(0,d.jsxs)(el.A,{justify:"start",align:"top",wrap:!1,gutter:c.or.BasePadding,children:[(0,d.jsx)(es.A,{span:7,children:(0,d.jsx)(ei.A,{title:"Files",children:(0,d.jsx)(m.h,{style:{width:"100%",height:735,overflow:"scroll"},treeData:f,defaultExpandedKeys:(0,h.mapFileKey)(f,l?1:4,l?void 0:e=>{let t=(0,ed.J)(e,"__RESOURCEPATH__").indexOf(i)>-1;return!!(a.length&&a.every(e=>e.indexOf(i)>-1))||!t})},`tree_${e.filename}`)})}),s&&(0,d.jsx)(y.zW,{api:p.hp.ServerAPI.API.GetResolverFileDetails,body:{filepath:s},children:e=>(0,d.jsx)(eu,{...e})})]})};(0,y.eN)({api:p.hp.ServerAPI.API.GetProjectInfo,responsePropName:"project",Component:e=>{let{project:t}=e,{root:r}=t,[s,n]=(0,u.useState)("");return(0,d.jsxs)("div",{style:{width:"100%"},children:[(0,d.jsx)(K.A,{style:{marginTop:c.or.BasePadding,marginBottom:c.or.BasePadding},children:(0,d.jsx)(g.E,{icon:(0,d.jsx)(er.A,{}),label:"Filename",placeholder:"search filename by keyword",onChange:e=>n(e)})}),(0,d.jsx)(y.zW,{api:p.hp.ServerAPI.API.GetResolverFileTree,children:e=>(0,d.jsx)(eh,{filename:s,resolver:e,cwd:r})})]})}});let ec="ModuleResolve",ep=p.Kj.RsdoctorClientRoutes.ModuleResolve;r(90220),p.Kj.RsdoctorClientRoutes.RuleIndex;var ef=r(46151),em=r(8302),eg=r(14296),ey=r(49815),ev=r(36797);r(32119),p.Kj.RsdoctorClientRoutes.TreeShaking,(0,y.ug)(h.fetchManifest,[["moduleGraph","data"],["root","cwd"]],e=>{let{data:t,cwd:r}=e,s=(0,h.useModuleGraphInstanceByModuleGraph)(t);if(0===s.size())return(0,d.jsx)(ey.$,{});let[n,i]=(0,u.useState)(""),[o,a]=(0,u.useState)(1),[l,f]=(0,u.useState)([]),[v,M]=(0,u.useState)("side-effect"),S=(0,u.useMemo)(()=>s.getModules().filter(e=>e.kind===p.hp.ModuleKind.Normal&&A().basename(e.path).includes(n)),[n]),I=(0,u.useMemo)(()=>S.find(e=>e.isEntry),[]),[P,E]=(0,u.useState)(I||(null==S?void 0:S.length)&&(null==S?void 0:S[0])),D=(0,em.EV)(S,s,n,P,e=>{k(S.find(t=>t.path===e),[])},r),k=(e,t,r)=>{E(e),f(t.slice()),x.AP.isNumber(r)&&a(r)};return(0,d.jsxs)(ei.A,{title:"Tree Shaking Analysis",bodyStyle:{paddingTop:0},className:"tree-shaking-page",children:[(0,d.jsxs)(el.A,{justify:"space-between",align:"middle",style:{marginBottom:c.or.BasePadding,marginTop:c.or.BasePadding},children:[(0,d.jsx)(g.E,{icon:(0,d.jsx)(er.A,{}),width:400,label:"FileName",placeholder:"search filename by keyword",style:{width:"auto"},onChange:e=>i(e)}),(0,d.jsxs)(ef.A.Group,{value:v,onChange:e=>{let{target:t}=e;return M(t.value)},children:[(0,d.jsx)(ef.A.Button,{value:"side-effect",children:"SideEffects"}),(0,d.jsx)(ef.A.Button,{value:"export",children:"Export Variables"})]})]}),(0,d.jsxs)(el.A,{justify:"space-between",align:"top",wrap:!1,gutter:[c.or.BasePadding,c.or.BasePadding],children:[(0,d.jsx)(es.A,{span:7,children:(0,d.jsx)(ei.A,{title:`Total Files: ${S.length}`,className:"tree-shaking-files-box",children:(0,d.jsx)(m.h,{style:{height:"80%"},className:"tree-shaking-files",selectedKeys:P?[P.path]:[],defaultExpandedKeys:(0,em.ut)(D),treeData:D,expandAction:"click"})})}),(0,d.jsx)(es.A,{span:9,children:(0,d.jsx)(y.zW,{api:p.hp.ServerAPI.API.GetModuleCodeByModuleId,body:{moduleId:P.id},children:e=>(0,d.jsx)(eg.B,{module:P,moduleGraph:s,ranges:l,toLine:o,setEditorData:k,source:e})})}),(0,d.jsx)(es.A,{flex:1,children:(0,d.jsx)(ev.oK,{kind:v,setEditorData:k,module:P,moduleGraph:s})})]})]})});var eM=r(4324);r(10133),p._8.RsdoctorManifestClientRoutes.Overall,p._8.RsdoctorManifestClientRoutes.BundleSize,p.Kj.RsdoctorClientRoutes.Uploader},33498(e,t,r){r.d(t,{Bq:()=>f,ME:()=>c,Rz:()=>g,Zb:()=>m});var s=r(65723),n=r(70580),i=r(66287),o=r(68108),a=r(64060),l=r(61858),d=r(76681),u=r(53289);let h=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"/",r=null==e?void 0:e.indexOf(t);return -1===r?null:0===r?t+(h(null==e?void 0:e.slice(1),t)||""):null==e?void 0:e.slice(0,r)};function c(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:()=>!0,s=0,n=[],i=e;for(;s<t&&(i.filter(r).forEach(e=>{e.isLeaf||n.push(e.key)}),(i=i.reduce((e,t)=>e.concat(t.children||[]),[])).length);)s++;return n}let p="__BASENAME__";function f(e){let{files:t,inlinedResourcePathKey:r="__RESOURCEPATH__",fileTitle:s=(e,t)=>t,dirTitle:i=(e,t)=>t,page:o="other"}=e,a=t.map(e=>e.replace(/\\/g,"/")),l=RegExp("/"),d=a.reduce((e,t)=>{let i=h(t,"/"),a=i?null==t?void 0:t.slice(i.length+1):t,d=e;for(;i;){let e=d.children.find(e=>e.title===i);if(!e){let t=[d[r],i].filter(Boolean).join("/");e={title:i,icon:"bundle"===o?e=>y(e,!1):null,key:t,children:[],[r]:t,[p]:i},d.children.push(e)}d=e,a=(i=h(a,"/"))?a.slice(i.length).replace(l,""):a}return d.children.some(e=>(0,n.J)(e,r)===t)||d.children.push({title:()=>s(t,a),icon:"bundle"===o?e=>y(e):null,key:t,isLeaf:!0,[r]:t,[p]:a}),e},{key:"0",children:[]}).children;return d.forEach(e=>{e.children&&e.children.forEach(t=>(function e(t,r){let s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"/",n=arguments.length>3?arguments[3]:void 0,i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:(e,t)=>t;if(!t.isLeaf)if(r.children&&1===r.children.length){let o=[r[p],t[p]].join(s);r[n]=t[n],r[p]=o,r.key=[r.key,t.key].join("-"),r.children=t.children,r.title=i(r,o),t.children&&t.children.forEach(t=>{e(t,r,s,n,i)})}else t.title=i(t,t[p]),t.children&&t.children.forEach(r=>{e(r,t,s,n,i)})})(t,e,"/",r,i))}),d}function m(e,t){return e.startsWith(t)?e.replace(t,"."):e}function g(e,t){let r=m(e,t),s="/node_modules/",n=r.lastIndexOf(s);return n>-1?{alias:r.slice(n+s.length),inNodeModules:!0}:{alias:r,inNodeModules:!1}}function y(e){let t=!(arguments.length>1)||void 0===arguments[1]||arguments[1],{data:r}=e,n=e.expanded;return(null==r?void 0:r.children)?(0,s.jsxs)(i.A,{children:[t?(0,s.jsx)(o.A,{className:`file-tree-switcher-arrow ${n?"file-tree-switcher-arrow-expand":""}`}):(0,s.jsx)(s.Fragment,{}),n?(0,s.jsx)(a.A,{}):(0,s.jsx)(l.A,{})]}):e.eventKey&&"string"==typeof e.eventKey?(0,u.C)(e.eventKey):(0,s.jsx)(d.A,{})}},98685(e,t,r){r.d(t,{getFirstVisitFromStorage:()=>f.R7,useModuleGraph:()=>M,useRuleIndexNavigate:()=>y,useUniqModules:()=>A,useCompileAlertsByErrors:()=>S,hasBundle:()=>w.r,useLocale:()=>j.Ym,useDataLoader:()=>s.V,getEnableRoutesFromUrlQuery:()=>B.TR,fetchManifest:()=>C.Cj,isDef:()=>B.C8,setThemeToStorage:()=>f.Kv,formatSize:()=>z.X,beautifyPath:()=>n.Zb,useWebpackConfigurationByConfigs:()=>I,createFileStructures:()=>n.Bq,useDuplicatePackagesByErrors:()=>x,useTheme:()=>j.DP,mapFileKey:()=>n.ME,filterLoader:()=>P.ak,setFirstVisitToStorage:()=>f.Yh,useI18n:()=>g,getShortPath:()=>B.Ml,beautifyModulePath:()=>n.Rz,changeOrigin:()=>B.$G,setViewModeToStorage:()=>f.ZI,getLocale:()=>b,formatPercent:()=>z.l,useModuleGraphInstanceByModuleGraph:()=>j.mB,useUrlQuery:()=>v,getLanguage:()=>_,hasCompile:()=>w.c,formatCosts:()=>R.a4,hasViewModeFromStorage:()=>f.it,useViewMode:()=>j.an});var s=r(14415),n=r(33498),i=r(40799),o=r(91888),a=r(50408),l=r(6161),d=r(22155),u=r(83731),h=r(41346),c=r(31337),p=r.n(c);r(92958);var f=r(96307);let m=o.Kj.RsdoctorClientRoutes.RuleIndex,g=()=>{let{i18n:e,...t}=(0,u.B)();return{...t,i18n:{...e,changeLanguage:(t,r)=>e.changeLanguage(t,(e,s)=>{e||(0,f.XX)(t),r&&r(e,s)})}}};function y(e,t){let r=(0,h.Zp)();return t?()=>window.open(t,"__blank"):()=>{r(`${m}?${o.jO.RsdoctorRuleClientConstant.UrlQueryForErrorCode}=${e}`)}}function v(){let e=(0,h.zy)().search||location.search;return(0,d.useMemo)(()=>p()(e,!0).query,[e])}function M(e){let t=e;"string"==typeof t&&(e=JSON.parse(i.oG.decompressText(t)));var r=e,s={dependencies:[],modules:[],moduleGraphModules:[],exports:[],sideEffects:[],variables:[]};return r&&"object"==typeof r?Array.isArray(r)?s:(0,a.N)(r,s):s}function A(e){return(0,l.h)(e,e=>e.path)}function S(e){return Array.isArray(e)?e.filter(e=>e.category===o.jO.RuleMessageCategory.Compile&&e.code!==o.jO.RuleMessageCodeEnumerated.Overlay):[]}function x(e){return(Array.isArray(e)?e.filter(e=>e.category===o.jO.RuleMessageCategory.Bundle&&e.code!==o.jO.RuleMessageCodeEnumerated.Overlay):[]).filter(e=>e.code===o.jO.RuleErrorMap.E1001.code)}function I(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return Array.isArray(e)?e.find(e=>"webpack"===e.name||"rspack"===e.name):null}var P=r(47001),E=r(95699),D=r(55887),k=r(10117);function b(e){return"cn"===e||"zh-CN"===e?E.A:D.A}function _(e){return"cn"===e||"zh"===e?k.TM.Cn:k.TM.En}var j=r(18679),C=r(20219),w=r(40686),z=r(9919);r(37503);var R=r(22679),B=r(62975);r(28306),r(10133)},10133(e,t,r){r(91888),r(44751)},62975(e,t,r){r.d(t,{$G:()=>l,C8:()=>u,Ml:()=>d,TR:()=>a,kJ:()=>o});var s=r(31337),n=r.n(s),i=r(91888);function o(){let{query:e}=n()(location.href,!0),t=e[i.Kj.RsdoctorClientUrlQuery.ManifestFile];if(t)return decodeURIComponent(t)}function a(){let{query:e}=n()(location.href,!0),t=e[i.Kj.RsdoctorClientUrlQuery.EnableRoutes];if(!t&&location.hash&&(t=n()(location.hash,!0).query[i.Kj.RsdoctorClientUrlQuery.EnableRoutes]),!t&&location.hash){let e=location.hash,r=e.indexOf("?");-1!==r&&(t=new URLSearchParams(e.substring(r+1)).get(i.Kj.RsdoctorClientUrlQuery.EnableRoutes)||void 0)}if(t)try{return JSON.parse(decodeURIComponent(t))}catch(e){console.warn("Failed to parse enableRoutes from URL query:",e)}}function l(e){let t=n()(location.href,!0),r=n()(e,!0);return t.hash.endsWith(i.Kj.RsdoctorClientRoutes.Uploader)&&t.set("hash",i.Kj.RsdoctorClientRoutes.Overall),t.set("origin",e),t.set("protocol",r.protocol),t.set("host",r.host),t.set("port",r.port),t.toString()}let d=e=>{if((null==e?void 0:e.indexOf("node_modules"))>=0){let t=e.split("node_modules");return`node_modules${t[t.length-1]}`}return(null==e?void 0:e.length)?`${null==e?void 0:e.split("/").slice(-4).join("/")}`:e};function u(e){return null!=e}},44751(e,t,r){r.d(t,{dh:()=>T,nV:()=>C});var s=r(91888),n=r(46068),i=r(13078),o=r.n(i),a=r(40799),l=r(69222),d=r(76554),u=r(85409),h=r(8963).Buffer,c={};c.d=(e,t)=>{for(var r in t)c.o(t,r)&&!c.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},c.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),c.r=e=>{"u">typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var p={};c.r(p),c.d(p,{assetsContents:()=>Y,chunkTransform:()=>K,getAssetsModulesData:()=>N,transformAssetsModulesData:()=>$});var f={};c.r(f),c.d(f,{getImportKind:()=>q,getModuleGraphByStats:()=>et,getModulesFromArray:()=>ee,getPositionByStatsLocation:()=>V,isImportDependency:()=>U,isWebpack5orRspack:()=>Z,removeNoImportStyle:()=>Q});var m={};c.r(m),c.d(m,{transStats:()=>er});var g={};c.r(g),c.d(g,{getAllModules:()=>eg,getDependencyPosition:()=>eh,getEntryModule:()=>eu,getExportDependency:()=>ec,getExportStatement:()=>ef,getLastExportInfo:()=>em,getModuleSource:()=>ed,getResolveRequest:()=>ea,getSdkDependencyByWebpackDependency:()=>ep,getWebpackDependencyRequest:()=>eo,getWebpackModuleId:()=>en,getWebpackModulePath:()=>ei,isExternalModule:()=>el,isNormalModule:()=>es});class y{isEntry(){return this.entry}isChunkEntryModule(e){return e.isEntry||e.getImported().every(e=>!this.hasModule(e))}hasModule(e){return this._modules.includes(e)}addModule(e){this.hasModule(e)||(this._modules.push(e),e.addChunk(this))}addAsset(e){this._assets.push(e)}addModules(e){e.forEach(e=>{this.hasModule(e)||(this._modules.push(e),e.addChunk(this))})}addDependency(e){this._dependencies.includes(e)||this._dependencies.push(e)}addImported(e){this._imported.includes(e)||this._imported.push(e)}getAssets(){return this._assets.slice()}getModules(){return this._modules.slice()}getDependencies(){return this._dependencies.slice()}getImported(){return this._imported.slice()}setParsedSize(e){this._parsedSize=e}toData(){return{id:this.id,name:this.name,initial:this.initial,size:this.size,parsedSize:this._parsedSize||0,entry:this.isEntry(),assets:this._assets.map(e=>{let{path:t}=e;return t}),modules:this._modules.map(e=>{let{id:t}=e;return t}),dependencies:this._dependencies.map(e=>{let{id:t}=e;return t}),imported:this._imported.map(e=>{let{id:t}=e;return t})}}setDependencies(e){this._dependencies=e}setImported(e){this._imported=e}setModules(e){this._modules=e}setAssets(e){this._assets=e}constructor(e,t,r,s,n){this._assets=[],this._modules=[],this._dependencies=[],this._imported=[],this.id=e,this.name=t,this.size=r,this.initial=s,this.entry=n}}class v{getAssets(){return Array.from(this._assetMap.values())}getChunks(){return Array.from(this._chunkMap.values())}addAsset(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];t.forEach(e=>{this._assetMap.set(e.id,e),this._assetPathMap.set(e.path,e)})}addChunk(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];t.forEach(e=>{this._chunkMap.set(e.id,e)})}getChunkById(e){return this._chunkMap.get(e)}getAssetByPath(e){return this._assetPathMap.get(e)}getAssetById(e){return this._assetMap.get(e)}getEntryPoints(){return Array.from(this._entrypointMap.values())}getEntryPointById(e){return this._entrypointMap.get(e)}addEntryPoint(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];t.forEach(e=>{this._entrypointMap.set(e.id,e)})}toData(e){return{assets:Array.from(this._assetMap.values()).map(t=>t.toData(e)),chunks:Array.from(this._chunkMap.values()).map(e=>e.toData()),entrypoints:Array.from(this._entrypointMap.values()).map(e=>e.toData())}}setChunks(e){this._chunkMap=new Map(e.map(e=>[e.id,e]))}setEntrypoints(e){this._entrypointMap=new Map(e.map(e=>[e.id,e]))}setAssets(e){this._assetMap=new Map(e.map(e=>[e.id,e])),this._assetPathMap=new Map(e.map(e=>[e.path,e]))}constructor(){this._assetMap=new Map,this._assetPathMap=new Map,this._chunkMap=new Map,this._entrypointMap=new Map}}let M=1;class A{static init(){M=1}toData(e){var t;return{id:this.id,path:this.path,size:this.size,gzipSize:this.gzipSize,chunks:null==(t=this.chunks)?void 0:t.map(e=>e.id),content:e===s.hp.ToDataType.NoSourceAndAssets||e===s.hp.ToDataType.NoCode?"":this.content}}setChunks(e){this.chunks=e}setId(e){this.id=e}setGzipSize(e){this.gzipSize=(0,n.gzipSync)(e,{level:9}).length}constructor(e,t,r,s){this.id=M++,this.path=e,this.size=t,this.chunks=r,this.content=s}}let S=1;class x{static init(){S=1}addChunk(e){this._chunks.includes(e)||this._chunks.push(e)}addAsset(e){this._assets.includes(e)||this._assets.push(e)}toData(){return{id:this.id,name:this.name,chunks:this._chunks.map(e=>e.id),assets:this._assets.map(e=>e.path),size:this._assets.length?this._assets.reduce((e,t)=>e+t.size,0):0}}setChunks(e){this._chunks=e}setAssets(e){this._assets=e}setId(e){this.id=e}constructor(e){this.name=e,this._chunks=[],this._assets=[],this.id=S++}}let I=1;class P{static init(){I=1}get resolvedRequest(){return this.dependency.path}get dependency(){return this.originDependency.rootModule??this.originDependency}get originDependency(){return this._originDependency}get kindString(){return s.hp.DependencyKind[this.kind]}get resolveConcatenationModule(){return this.dependency.kind===s.hp.ModuleKind.Concatenation}isSameWithoutStatements(e){return this.request===e.request&&this.kind===e.kind&&this.module.id===e.module.id&&this.dependency.id===e.dependency.id}addStatement(e){this.hasStatement(e)||this.statements.push(e)}hasStatement(e){return this.statements.some(t=>t.isSame(e))}setBuildMeta(e){this.meta={...this.meta,...e}}toData(){return{id:this.id,request:this.request,resolvedRequest:this.resolvedRequest,kind:this.kind,...void 0!==this.typeString&&{typeString:this.typeString},module:this.module.id,dependency:this.dependency.id,originDependency:this.originDependency.id,statements:this.statements.map(e=>e.toData())}}setId(e){this.id=e}constructor(e,t,r,s,n){this.statements=[],this.meta={exportsType:"default-with-named"},this.id=I++,this.request=e,this.module=t,this._originDependency=r,this.kind=s,this.statements=n??[]}}function E(e,t){return e.line===t.line&&e.column===t.column}P.kind=s.hp.DependencyKind;let D=/!/,k=/\s\+\s\d*\smodules$/,b=/^css\s.*node_modules(?!\/)/;class _{static getDefaultStatement(e){let t={line:1,column:0},r={start:{...t},end:{...t}};return new _(e,{source:{...r},transformed:{...r}})}isSame(e){var t,r;return this.module.id===e.module.id&&(t=this.position.transformed,r=e.position.transformed,!!E(t.start,r.start)&&(a.AP.isNil(t.end)||a.AP.isNil(r.end)?a.AP.isUndefined(t.end)&&a.AP.isUndefined(r.end):E(t.end,r.end)))}getSourcePosition(){let{module:e,position:t}=this;return t.source?t.source:e.getSourceMap()?(t.source=e.getSourceRange(t.transformed),t.source):void 0}getLineCode(){let e=this.module.isPreferSource&&this.position.source,t=this.module.getSource(),r=e?t.source:t.transformed,s=e?this.position.source.start.line:this.position.transformed.start.line;if("number"==typeof s)return r.split("\n")[s-1]}toData(){let e={transformed:this.position.transformed};return this.position.source&&(e.source=this.position.source),{position:e,module:this.module.id}}constructor(e,t){this.module=e,this.position=t}}let j=1;class C{static init(){j=1}get rootModule(){return this.modules.find(e=>e.path===this.path)}get isPreferSource(){if("boolean"==typeof this._isPreferSource)return this._isPreferSource;let e=this.source.source.length>0&&"test code"!==this.source.source&&!!this.sourceMap;return this._isPreferSource=e,e}addBailoutReason(e){this.bailoutReason.push(e)}getBailoutReason(){return this.bailoutReason}addSideEffectLocation(e){this.sideEffectLocations.push(e)}getSideEffectLocations(){return this.sideEffectLocations.slice()}addSideEffectCode(e){this.sideEffectCodes.push(e)}getSideEffectCodes(){return this.sideEffectCodes.slice()}getChunks(){return this.chunks.slice()}addChunk(e){this.chunks.includes(e)||(this.chunks.push(e),e.addModule(this))}removeChunk(e){this.chunks=this.chunks.filter(t=>t!==e)}getDependencies(){return this.dependencies.slice()}getDependencyByRequest(e){return this.dependencies.find(t=>t.request===e)}getDependencyByModule(e){return this.dependencies.find(t=>t.originDependency===e||t.dependency===e)}addDependency(e,t,r,s){let n=new P(e,this,t,r,s);if(this.dependencies.every(e=>!e.isSameWithoutStatements(n)))return this.dependencies.push(n),t.addImported(this),t.rootModule&&t.rootModule.addImported(this),n}removeDependency(e){this.dependencies=this.dependencies.filter(t=>t===e)}removeDependencyByModule(e){let t=this.getDependencyByModule(e);t&&this.removeDependency(t)}getImported(){return this.imported.slice()}addImported(e){this.imported.includes(e)||this.imported.push(e)}removeImported(e){this.imported=this.imported.filter(t=>t===e)}setProgram(e){this.program=e}getProgram(){return this.program}setSource(e){let{source:t}=this;t.source=e.source??t.source,t.transformed=e.transformed??t.transformed,t.parsedSource=e.parsedSource??t.parsedSource}getSource(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:s.hp.ToDataType.Normal;return e===s.hp.ToDataType.NoCode?{source:"",transformed:"",parsedSource:""}:e===s.hp.ToDataType.NoSourceAndAssets||e===s.hp.ToDataType.NoSource?{source:"",transformed:"",parsedSource:this.isPreferSource?"":this.source.parsedSource}:e===s.hp.ToDataType.All?{source:this.source.source,transformed:this.source.transformed,parsedSource:this.isPreferSource?"":this.source.parsedSource}:{source:this.source.source,transformed:"",parsedSource:this.isPreferSource?"":this.source.parsedSource}}setSourceMap(e){this.sourceMap=e}getSourceMap(){return this.sourceMap}setSize(e){let{size:t}=this;if(t.sourceSize=e.sourceSize??t.sourceSize,t.transformedSize=e.transformedSize??t.transformedSize,t.parsedSize=e.parsedSize??t.parsedSize,"number"==typeof e.gzipSize)t.gzipSize=e.gzipSize;else{let e=this.source.parsedSource||this.source.source;if(e&&"string"==typeof e&&e.length>0)try{t.gzipSize=(0,n.gzipSync)(e,{level:9}).length}catch(e){t.gzipSize=0}}}getSize(){return{...this.size}}getStatement(e){return new _(this,{source:this.getSourceRange(e),transformed:{start:{...e.start},end:e.end?{...e.end}:void 0}})}getSourceRange(e){let{sourceMap:t}=this;if(!t)return;let r={start:{}},s=t.originalPositionFor({line:e.start.line??0,column:e.start.column??0,bias:1});if(a.AP.isNumber(s.line)&&(r.start={line:s.line,column:s.column??void 0}),e.end){let s=t.originalPositionFor({line:e.end.line??0,column:e.end.column??0});a.AP.isNumber(s.line)&&(r.end={line:s.line,column:s.column??void 0})}return r}addNormalModule(e){this.modules.includes(e)||(this.modules.push(e),e.addConcatenationModule(this))}getNormalModules(){return this.modules.slice()}addConcatenationModule(e){this.concatenationModules.includes(e)||this.concatenationModules.push(e)}addIssuerPath(e){var t;(null==(t=this.issuerPath)?void 0:t.length)||(this.issuerPath=e)}getIssuerPath(){return this.issuerPath}getConcatenationModules(){return this.concatenationModules.slice()}toData(e,t){var r;let{isPreferSource:s}=this,n=function(e){if(!e)return"";if(D.test(e)){let t=a.AP.last(e.split(D));if(null==t?void 0:t.trim())return t}return k.test(e)?e.replace(k,""):b.test(e)?e.replace(b,""):e}(this.webpackId),i={id:this.id,renderId:this.renderId,webpackId:e&&n.indexOf(".")>0?o().relative(e,n):this.webpackId,path:this.path,isPreferSource:s,dependencies:this.dependencies.map(e=>e.id),imported:this.imported.map(e=>e.id),chunks:this.chunks.map(e=>e.id),size:this.getSize(),kind:this.kind,...this.layer?{layer:this.layer}:{},issuerPath:t?void 0:(null==(r=this.issuerPath)?void 0:r.filter(e=>e.moduleId).map(e=>e.moduleId))||[],bailoutReason:this.bailoutReason,...this.sideEffectLocations.length>0?{sideEffectLocations:this.sideEffectLocations}:{}};return(this.meta.hasSetEsModuleStatement||this.meta.strictHarmonyModule)&&(i.meta={},this.meta.hasSetEsModuleStatement&&(i.meta.hasSetEsModuleStatement=!0),this.meta.strictHarmonyModule&&(i.meta.strictHarmonyModule=!0)),this.isEntry&&(i.isEntry=this.isEntry),this.modules.length>0&&(i.modules=this.modules.map(e=>e.id)),this.rootModule&&(i.rootModule=this.rootModule.id),this.concatenationModules.length>0&&(i.concatenationModules=this.concatenationModules.map(e=>e.id)),i}setId(e){this.id=e}setRenderId(e){this.renderId=e}setChunks(e){this.chunks=e}setDependencies(e){this.dependencies=e}setImported(e){this.imported=e}setModules(e){this.modules=e}setConcatenationModules(e){this.concatenationModules=e}constructor(e,t,r=!1,n=s.hp.ModuleKind.Normal,i,o=""){this.issuerPath=[],this.bailoutReason=[],this.sideEffectLocations=[],this.sideEffectCodes=[],this.source={source:"",transformed:"",parsedSource:""},this.size={sourceSize:0,transformedSize:0,parsedSize:0,gzipSize:0},this.chunks=[],this.dependencies=[],this.imported=[],this.modules=[],this.concatenationModules=[],this.meta={hasSetEsModuleStatement:!1,strictHarmonyModule:!1},this.id=j++,this.webpackId=e,this.path=t,this.isEntry=r,this.kind=n,this.renderId=i,this.layer=o}}C.kind=s.hp.ModuleKind;let w=1;class z{static init(){w=1}get isReExport(){return!!this.from}set variable(e){this._variable=e}get variable(){var e;if(this._variable)return this._variable;if(!this.from||!1===this._variable){this._variable=!1;return}let t=null==(e=this.getRecursiveExport())?void 0:e.variable;return t||(this._variable=!1),t}addSideEffect(e){this._sideEffects.every(t=>t.id!==e.id)&&(this._sideEffects.push(e),this.from&&this.from.addSideEffect(e))}getSideEffects(){return this._sideEffects.slice()}setFromExport(e){this.from=e}getRecursiveExport(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1/0;if(0===e)throw Error("`getRecursiveExport` method parameter depth must be greater than 1.");if(!this.from)return this;let t=0,r=this;for(;r.from&&t<e;)t++,r=r.from;return r}toData(){let e={id:this.id,name:this.name,isReExport:this.isReExport,used:this._sideEffects.map(e=>e.id)};return this.from&&(e.from=this.from.id,e.root=this.getRecursiveExport().id),this.variable&&(e.variable=this.variable.id),e}constructor(e,t,r){this.id=w++,this._sideEffects=[],this.name=e,this.identifier=t,this._variable=r}}let R=1;class B{static init(){R=1}get variable(){var e,t;if(void 0!==this._variable)return this._variable?this._variable:void 0;let r=null==(t=this.exports[0])||null==(e=t.getRecursiveExport())?void 0:e.variable;return this._variable=r??!1,r}get exports(){var e;return(null==(e=this._exports)?void 0:e.slice())??[]}setModuleExport(e){e.getExports().forEach(e=>this.setExportInfo(e))}setExportInfo(e){this._exports.push(e),e.addSideEffect(this)}toData(){let e={id:this.id,name:this.name,identifier:this.identifier.toData(),module:this.module.id};return this.fromDependency&&(e.fromDependency=this.fromDependency.id),this.isNameSpace&&(e.isNameSpace=this.isNameSpace),this.exports.length>0&&(e.exports=this.exports.map(e=>e.id)),this.variable&&(e.variable=this.variable.id),e}constructor(e,t,r,s,n){this.id=R++,this._exports=[],this.name=e,this.module=t,this.identifier=r,s&&(this.fromDependency=this.module.getDependencyByRequest(s)),n===B.NamespaceSymbol?this.isNameSpace=!0:(this.isNameSpace=!1,this.originName=n)}}B.NamespaceSymbol=Symbol("namespace");let G=1;class O{static init(){G=1}get isUsed(){return!!this._exported&&this._exported.getSideEffects().length>0}setExportInfo(e){this._exported=e,e.variable=this}getExportInfo(){return this._exported}toData(){let e={id:this.id,name:this.name,module:this.module.id,identifier:this.identifier.toData(),usedInfo:this.usedInfo};return this._exported&&(e.exported=this._exported.id),e}constructor(e,t,r,s){this.id=G++,this.name=e,this.module=t,this.usedInfo=r,this.identifier=s}}class F{static init(){z.init(),B.init(),O.init()}get dynamic(){return"boolean"==typeof this._dynamic?this._dynamic:this.module.getImported().map(e=>e.getDependencyByModule(this.module)).some(e=>e&&"dynamic"===e.meta.exportsType)}addExportInfo(e){this.exports.push(e),this._graph.addExportInfo(e)}addSideEffect(e){this.sideEffects.push(e),this._graph.addSideEffect(e)}addVariable(e){this.variables.push(e),this._graph.addVariable(e)}getExports(){return this.exports.slice()}getSideEffects(e){return e?this.sideEffects.filter(t=>t.name===e):this.sideEffects.slice()}getOwnExports(){return this.exports.filter(e=>!e.isReExport)}getExport(e){return this.exports.find(t=>t.name===e)}getReExports(){return this.exports.filter(e=>e.isReExport)}getOwnExport(e){return this.getOwnExports().find(t=>t.name===e)}getReExport(e){return this.getReExports().find(t=>t.name===e)}toData(){return{module:this.module.id,dynamic:this.dynamic,exports:this.exports.map(e=>e.id),sideEffects:this.sideEffects.map(e=>e.id),variables:this.variables.map(e=>e.id)}}constructor(e,t,r){this.exports=[],this.sideEffects=[],this.variables=[],this.module=e,this._graph=t,"boolean"==typeof this._dynamic&&(this._dynamic=r)}}class T{static init(){C.init(),P.init(),F.init()}static fromData(e){let t=new T,r=e=>new _(t.getModuleById(e.module),e.position);for(let r of e.modules??[]){var s,n;let e=new C(String(r.id),r.path,r.isEntry,r.kind,r.renderId,r.layer);e.id=r.id,e.setSize(r.size),e.meta={strictHarmonyModule:(null==(s=r.meta)?void 0:s.strictHarmonyModule)??!1,hasSetEsModuleStatement:(null==(n=r.meta)?void 0:n.hasSetEsModuleStatement)??!1},e._isPreferSource=r.isPreferSource,e.chunks=r.chunks,t.addModule(e)}for(let s of e.modules??[]){let n=t.getModuleById(s.id);for(let i of s.dependencies){let s=(e.dependencies??[]).find(e=>e.id===i),o=s&&t.getModuleById(s.originDependency);if(!s||!o){console.warn(`The connection data ID is empty: ${i}`);continue}let a=n.addDependency(s.request,o,s.kind,s.statements.map(r));a&&(a.id=s.id,t.addDependency(a))}for(let e of s.modules??[]){let r=t.getModuleById(e);if(!r){console.warn(`Add the ordinary module ID as empty: ${e}`);continue}n.addNormalModule(r)}for(let e of s.concatenationModules??[]){let r=t.getModuleById(e);if(!r){console.warn(`The aggregation module ID is empty: ${r}`);continue}n.addConcatenationModule(r)}}for(let s of e.exports??[]){let e=new z(s.name,s.identifier?r(s.identifier):void 0);e.id=s.id,t.addExportInfo(e)}for(let r of e.exports??[])if(r.from){let e=t._exportIdMap.get(r.id),s=t._exportIdMap.get(r.from);e&&s&&e.setFromExport(s)}for(let s of e.variables??[]){let e=t.getModuleById(s.module);if(!e){console.warn(`The module ID in the variable is empty：${s.module}`);continue}let n=new O(s.name,e,s.usedInfo,r(s.identifier)),i=t._exportIdMap.get(s.exported??-1);i&&n.setExportInfo(i),n.id=s.id,t.addVariable(n)}for(let s of e.sideEffects??[]){let e=t.getModuleById(s.module);if(!e){console.warn(`The module ID in the side effects is empty：${s.module}`);continue}let n=new B(s.name,e,r(s.identifier),s.originName);for(let e of(n.isNameSpace=s.isNameSpace,n.id=s.id,s.exports??[])){let r=t._exportIdMap.get(e);r&&r.addSideEffect(n)}if(s.variable){let e=t._varIdMap.get(s.variable);e&&(n._variable=e)}t.addSideEffect(n)}for(let r of e.moduleGraphModules??[]){let e=t.getModuleById(r.module);if(!e){console.warn(`The module ID in ModuleGraphModule is empty: ${r.module}`);continue}let s=new F(e,t,r.dynamic);t.addModuleGraphModule(s),r.exports.forEach(e=>{let r=t._exportIdMap.get(e);r&&s.addExportInfo(r)}),r.sideEffects.forEach(e=>{let r=t._sideEffectIdMap.get(e);r&&s.addSideEffect(r)}),r.variables.forEach(e=>{let r=t._varIdMap.get(e);r&&s.addVariable(r)})}return T.init(),t}clear(){this._dependenciesIdMap=new Map,this._moduleWebpackIdMap=new Map,this._moduleIdMap=new Map,this._moduleGraphModules=new Map,this._exportIdMap=new Map,this._sideEffectIdMap=new Map,this._varIdMap=new Map,this._layers=new Map}size(){return this._moduleIdMap.size}fromInstance(e){this.setModules(e.getModules()),this.setDependencies(e.getDependencies()),this.setConnectionsOnlyImports(e.getConnectionsOnlyImports()),e instanceof T&&(this._moduleGraphModules=new Map(e._moduleGraphModules),this._exportIdMap=new Map(e._exportIdMap),this._sideEffectIdMap=new Map(e._sideEffectIdMap),this._varIdMap=new Map(e._varIdMap),this._layers=new Map(e._layers))}getSubGraphByModule(e){let t=new Set,r=[e];t.add(e);for(let e=0;e<r.length;e++)for(let{dependency:s}of r[e].getDependencies())t.has(s)||(t.add(s),r.push(s));return r}getModules(){return Array.from(this._moduleWebpackIdMap.values())}getDependencies(){return Array.from(this._dependenciesIdMap.values())}getEntryModules(){return this.getModules().filter(e=>e.isEntry&&e.kind!==s.hp.ModuleKind.Concatenation)}getModuleById(e){return this._moduleIdMap.get(e)}getDependencyById(e){return this._dependenciesIdMap.get(e)}getModuleByWebpackId(e){return this._moduleWebpackIdMap.get(e)}getModuleByFile(e,t){return this.getModules().filter(r=>r.path===e&&(void 0===t||r.layer===t))}addModule(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];for(let e of t)!this._moduleIdMap.has(e.id)&&(this._moduleWebpackIdMap.set(e.webpackId,e),this._moduleIdMap.set(e.id,e),e.layer&&this.addLayer(e.layer))}addDependency(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];for(let e of t)this._dependenciesIdMap.has(e.id)||(this._dependenciesIdMap.set(e.id,e),this.addModule(e.module),this.addModule(e.dependency))}removeModule(e){for(let t of(this._moduleIdMap.delete(e.id),this._moduleWebpackIdMap.delete(e.webpackId),e.getDependencies()))this.removeDependency(t),this._dependenciesIdMap.delete(t.id);for(let t of e.getImported())t.removeDependencyByModule(t)}removeDependency(e){e.module.removeDependency(e),e.dependency.removeImported(e.module),this._dependenciesIdMap.delete(e.id)}addModuleGraphModule(e){this._moduleGraphModules.has(e.module)||this._moduleGraphModules.set(e.module,e)}getModuleGraphModule(e){return this._moduleGraphModules.get(e)}getModuleGraphModules(){return Array.from(this._moduleGraphModules.values())}addExportInfo(e){this._exportIdMap.set(e.id,e)}addSideEffect(e){this._sideEffectIdMap.set(e.id,e)}addVariable(e){this._varIdMap.set(e.id,e)}addLayer(e){this._layers.get(e)||this._layers.set(e,1)}getLayers(){return this._layers}toData(e){var t;let r=!!((null==e||null==(t=e.briefOptions)?void 0:t.type)&&e.briefOptions.type.length);return{dependencies:this.getDependencies().map(e=>e.toData()),modules:this.getModules().map(t=>t.toData(null==e?void 0:e.contextPath,r)),moduleGraphModules:r?[]:Array.from(this._moduleGraphModules.values()).map(e=>e.toData()),exports:r?[]:Array.from(this._exportIdMap.values()).map(e=>e.toData()),sideEffects:r?[]:Array.from(this._sideEffectIdMap.values()).map(e=>e.toData()),variables:r?[]:Array.from(this._varIdMap.values()).map(e=>e.toData()),layers:Array.from(this._layers.keys())}}toTreeShakingData(){let e={};for(let t of this.getModules()){let r=t.getSideEffectCodes();r.length>0&&(e[r[0].moduleId]=r)}return{sideEffectCodes:e}}toCodeData(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:s.hp.ToDataType.Normal,t={};return this.getModules().forEach(r=>{t[r.id]=r.getSource(e)}),t}setModules(e){this._moduleIdMap=new Map(e.map(e=>[e.id,e])),this._moduleWebpackIdMap=new Map(e.map(e=>[e.webpackId,e])),this._layers=new Map(e.filter(e=>e.layer).map(e=>[e.layer,1]))}setDependencies(e){this._dependenciesIdMap=new Map(e.map(e=>[e.id,e]))}setConnectionsOnlyImports(e){this._connectionsOnlyImports=e}getConnectionsOnlyImports(){return this._connectionsOnlyImports}constructor(){this._dependenciesIdMap=new Map,this._connectionsOnlyImports=[],this._moduleWebpackIdMap=new Map,this._moduleIdMap=new Map,this._moduleGraphModules=new Map,this._exportIdMap=new Map,this._sideEffectIdMap=new Map,this._varIdMap=new Map,this._layers=new Map}}async function N(e,t,r,s){let i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:new Map,l=arguments.length>5?arguments[5]:void 0;if(i.size>0){for(let[t,r]of((0,d.kB)("Start Parse bundle by sourcemap."),i.entries())){let s,i=e.getModuleByFile(t);try{r&&"string"==typeof r&&r.length>0&&(s=(0,n.gzipSync)(r,{level:9}).length)}catch{}for(let e of i)null==e||e.setSize({parsedSize:r.length,gzipSize:s}),null==e||e.setSource({parsedSource:r})}(0,d.PZ)("Start Parse bundle by sourcemap.")}if(s.parseBundle&&(l&&l.size>0||i.size<1)){(0,d.kB)("Start Parse bundle by AST.");let{parseBundle:n=()=>({})}=s||{},i=t.getAssets(),h=e.getModules(),c=null,p=null;if(r&&i.length){for(let e of(c={},p={},i)){let t;if(l&&l.size>0&&!l.has(e.path))continue;let s=o().join(r,e.path);try{t=n(s,h)}catch(n){let{code:e="",message:t}=n,r="ENOENT"===e?"no such file":t;"1"===u.env.DEVTOOLS_NODE_DEV&&d.vF.warn(`Error parsing bundle asset "${s}": ${r}`);continue}c[e.path]=a.AP.pick(t,["src","runtimeSrc"]),Object.assign(p,(null==t?void 0:t.modules)||{})}a.AP.isEmpty(c)&&(c=null,p=null,u.env.DEVTOOLS_DEV&&d.vF.warn("\nNo bundles were parsed. Analyzer will show only original module sizes from stats file.\n")),p&&$(p,e)}(0,d.PZ)("Start Parse bundle by AST.")}}function $(e,t){t&&Object.entries(e).forEach(e=>{let[r,s]=e,i,o=t.getModuleByWebpackId(r??"");try{(null==s?void 0:s.content)&&"string"==typeof s.content&&s.content.length>0&&(i=(0,n.gzipSync)(s.content,{level:9}).length)}catch{}null==o||o.setSize({parsedSize:null==s?void 0:s.size,gzipSize:i}),null==o||o.setSource({parsedSource:(null==s?void 0:s.content)||""})})}let L="assets by status";function K(e,t){var r,s,n,i,o,a;let l=new v;if(null==(r=t.chunks)||r.forEach(e=>{var t,r;let s=new y(String(e.id),(null==(t=e.names)?void 0:t.join(""))||(null==(r=e.files)?void 0:r.join("| "))||"",e.size,e.initial,e.entry);s.setParsedSize(0),l.addChunk(s)}),(null==(s=t.assets)?void 0:s.every(e=>e.type===L))?null==(n=t.chunks)||n.forEach(t=>{let r=l.getChunkById(String(t.id));r&&t.files&&t.files.forEach(t=>{if(!l.getAssetByPath(t)){let{content:s=""}=e.get(t)||{},n=new A(t,0,[r],s);r.addAsset(n),l.addAsset(n)}})}):null==(i=t.assets)||i.forEach(t=>{var r;if(t.type===L)return;let s=(null==(r=t.chunks)?void 0:r.map(e=>l.getChunkById(String(e))).filter(e=>!!e))||[],{content:n=""}=e.get(t.name)||{},i=h.byteLength(n,"utf8"),o=t.size??i,a=new A(t.name,o,s,n);s.forEach(e=>null==e?void 0:e.addAsset(a)),l.addAsset(a)}),t.entrypoints)for(let[e,r]of Object.entries(t.entrypoints)){let t=new x(r.name||e);null==(o=r.chunks)||o.forEach(e=>{let r=l.getChunkById(`${e}`);r&&t.addChunk(r)}),null==(a=r.assets)||a.forEach(e=>{let r=l.getAssetByPath(e.name);r&&t.addAsset(r)}),l.addEntryPoint(t)}return l}let W=/\.(?:js|css|html|json|svg|txt|xml|xhtml|wasm|manifest)$/i;function Y(e,t,r){t.getAssets().forEach(t=>{let{content:s=""}=e.get(t.path)||{};t.content=s,s.length>0&&0===t.size&&(t.size=h.byteLength(s,"utf8")),W.test(t.path)&&(null==r?void 0:r.gzip)&&t.setGzipSize(s)})}function U(e){let{type:t}=e;return"harmony side effect evaluation"===t||"cjs require"===t||"cjs full require"===t||"cjs export require"===t||"provided"===t||"esm import"===t}function q(e){let{type:t}=e;return t?t.includes("harmony")||"esm import"===t?s.hp.DependencyKind.ImportStatement:t.includes("cjs")?s.hp.DependencyKind.RequireCall:t.includes("import()")?s.hp.DependencyKind.DynamicImport:t.includes("amd")?s.hp.DependencyKind.AMDRequire:s.hp.DependencyKind.Unknown:s.hp.DependencyKind.Unknown}function Q(e){e.getModules().filter(e=>a.ZH.isStyleExt(e.path)).filter(e=>0===e.getImported().length).forEach(t=>e.removeModule(t))}function V(e){function t(e){let[t,r]=e.split(":");return{line:Number(t),column:Number(r)}}if(e.includes("-")){let r=e.split("-"),s=t(r[0]),n=t(r[1]);return{start:s,end:Number.isNaN(n.column)?{line:s.line,column:n.line}:n}}return e.includes(":")?{start:t(e)}:e.includes("[")?{start:{index:Number(e.match(/\[(\d+)\]/)[1])}}:void 0}function Z(e){return"moduleGraph"in e&&!!e.moduleGraph}function H(e){var t;if(!e.identifier||!((null==e?void 0:e.nameForCondition)||e.name)||e.identifier.startsWith("webpack/runtime")||(null==e||null==(t=e.name)?void 0:t.startsWith("(webpack)")))return!0}function J(e,t){if(t.nameForCondition)return t.nameForCondition.replace("\0","");let r=t.name.replace(/ ?\+ ?\d+ ?modules$/,"");return o().isAbsolute(r)?r:o().join(e,r)}function X(e){return".json"===o().extname(e).toLowerCase()}function ee(e,t){e.forEach(e=>{"module"===e.type||void 0===e.type?t.push(e):"children"in e&&e.children&&ee(e.children,t)})}function et(e,t,r){var n,i,o,a,l;let{modules:d,chunks:u}=e;T.init();let c=new T,p=[],f=[];for(let e of(ee(d??[],f),null==(n=u??[])||n.forEach(e=>{var t;(null==(t=e.modules)?void 0:t.length)&&f.push(...e.modules.map(e=>({...e,identifier:e.identifier??e.moduleIdentifier,name:e.name??e.moduleName})))}),f??[])){if(H(e)||c.getModuleByWebpackId(e.identifier))continue;p.push(e);let n=!!(e.modules&&e.modules.length>0),d=new C(e.identifier??e.moduleIdentifier,J(t,e),0===e.depth,n?s.hp.ModuleKind.Concatenation:s.hp.ModuleKind.Normal,e.id?String(e.id):void 0,e.layer);if(e.optimizationBailout&&e.optimizationBailout.forEach(e=>d.addBailoutReason(e)),e.issuerPath&&d.addIssuerPath(e.issuerPath),null==(i=e.chunks)||i.forEach(e=>{let t=r.getChunkById(String(e));t&&d.addChunk(t)}),c.addModule(d),e.source&&d.setSource({transformed:h.isBuffer(e.source)?e.source.toString():e.source}),"number"==typeof e.size){d.setSize({sourceSize:e.size,transformedSize:e.size});let t={sourceSize:e.size,transformedSize:e.size};X(d.path)&&(t.parsedSize=e.size),d.setSize(t)}for(let n of e.modules??[]){let i;if(H(n))continue;p.push(n);let u=n.identifier;if(i=c.getModuleByWebpackId(u)||(c.getModuleByWebpackId(u)??new C(u,J(t,n),0===n.depth,s.hp.ModuleKind.Normal,n.id?String(n.id):void 0,n.layer)),n.optimizationBailout&&n.optimizationBailout.filter(e=>!e.includes("ModuleConcatenation bailout")).forEach(e=>i.addBailoutReason(e)),n.issuerPath&&i.addIssuerPath(n.issuerPath),(null==(o=n.chunks)?void 0:o.length)?null==(a=n.chunks)||a.forEach(e=>{let t=r.getChunkById(String(e));t&&i.addChunk(t)}):null==(l=e.chunks)||l.forEach(e=>{let t=r.getChunkById(String(e));t&&i.addChunk(t)}),n.source&&i.setSource({transformed:h.isBuffer(n.source)?n.source.toString():n.source}),"number"==typeof n.size){i.setSize({sourceSize:n.size,transformedSize:n.size});let e={sourceSize:n.size,transformedSize:n.size};X(i.path)&&(e.parsedSize=n.size),i.setSize(e)}c.addModule(i),d.addNormalModule(i)}}for(let e of p){let t=c.getModuleByWebpackId(e.identifier??"");if(!t)continue;let r=(e.reasons??[]).filter(U).filter(e=>!!(e.moduleIdentifier&&e.userRequest));for(let s of((e.reasons??[]).filter(e=>"from origin"===e.type).forEach(e=>{var t;return null==e||null==(t=e.children)?void 0:t.forEach(t=>r.push({...e,...t,children:void 0}))}),r)){let e=s.userRequest,r=c.getModuleByWebpackId(s.moduleIdentifier);if(!r)continue;if(!r.getDependencyByRequest(e)){let n=r.addDependency(e,t,q(s));n&&c.addDependency(n)}let n=r.getDependencyByRequest(e);if(n&&(null==s?void 0:s.loc)){let e=V(s.loc);e&&n.addStatement(new _(r,{transformed:e}))}}}let m=new Map;return c.getModules().forEach(e=>{e.issuerPath&&e.issuerPath.forEach(e=>{let t=m.get(e.identifier);!t&&(t=c.getModuleByWebpackId(e.identifier))&&m.set(e.identifier,t),t&&(e.moduleId=t.id)})}),c}async function er(e){let t=K(new Map,e),r=et(e,".",t);return await N(r,t,e.outputPath||"",{}),{chunkGraph:t,moduleGraph:r}}function es(e){return"request"in e&&"rawRequest"in e&&"resource"in e}function en(e){return e.identifier()}function ei(e){var t;return e.resource??(null==(t=e.nameForCondition)?void 0:t.call(e))??en(e)}function eo(e,t){return e.request??e.userRequest??(null==t?void 0:t.rawRequest)}function ea(e,t){return ei(t.getResolvedModule(e))}function el(e){return!!e.externalType}function ed(e){var t,r;return el(e)?"":(null==(r=e.originalSource)||null==(t=r.call(e))?void 0:t.source().toString())??""}function eu(e){return Array.from(e.values()).map(e=>e.getRuntimeChunk()).map(e=>e?e.entryModule:null).filter(Boolean).map(e=>es(e)?e:e.rootModule)}function eh(e,t){let r=!(arguments.length>2)||void 0===arguments[2]||arguments[2],{loc:s}=e;if(void 0===s||!("start"in s))return;let n={start:{line:s.start.line,column:s.start.column},end:s.end?{line:s.end.line,column:s.end.column}:void 0};return new _(t,{source:r?t.getSourceRange(n):void 0,transformed:n})}function ec(e,t){let r=t.dependencies.find(t=>t.name===e.name&&("harmony export imported specifier"===t.type||"harmony export specifier"===t.type));return!r&&e._target&&e._target.size>0&&(r=e._getMaxTarget().values().next().value.connection.dependency),r}function ep(e,t,r){let s=ei(t),n=eo(e);return r.getDependencies().find(e=>e.module.path===s&&e.request===n)}function ef(e,t,r){let s=ec(e,t);if(!s)return;let n=ei(t),i=eo(s),o=r.getDependencies().find(e=>e.module.path===n&&e.request===i);if(o&&1===o.statements.length)return o.statements[0];let a=r.getModuleByWebpackId(en(t));if(a)return eh(s,a)}function em(e,t){let r=e.findTarget(t,()=>!0);if(r&&r.export)return t.getExportsInfo(r.module).getExportInfo(r.export[0])}function eg(e){let t=[];for(let r of e.modules)t.push(...r.modules??[]),t.push(r);return(0,l.R)(t.filter(e=>!en(e).startsWith("webpack/runtime")),e=>en(e))}},40799(e,t,r){r.d(t,{AP:()=>y.AP,B_:()=>I,Fp:()=>P,TS:()=>k,Wh:()=>M,ZH:()=>E,_8:()=>_,aH:()=>b,gX:()=>B,oG:()=>A,s0:()=>G,xR:()=>w});var s,n,i=r(52585),o=r(23997),a=r(46068),l=r(8963),d=r(13078),u=r.n(d),h=r(85409),c=r(91888),p=r(39980),f=r.n(p),m=r(35207),g=r(76554),y=r(14859),v=r(85409),M={};o.Q.r(M),o.Q.d(M,{getPackageRelationAlertDetails:()=>te});var A={};o.Q.r(A),o.Q.d(A,{compressText:()=>$,decompressText:()=>L,mergeIntervals:()=>N,random:()=>K});var S={};o.Q.r(S),o.Q.d(S,{getBundleDiffPageQueryString:()=>e2,getBundleDiffPageUrl:()=>e9,parseFilesFromBundlePageUrlQuery:()=>e8});var x={};o.Q.r(x),o.Q.d(x,{decode:()=>T,encode:()=>F});var I={};o.Q.r(I),o.Q.d(I,{APIDataLoader:()=>tn});var P={};o.Q.r(P),o.Q.d(P,{fetchWithTimeout:()=>to,getFetch:()=>ti,postJSON:()=>ta});var E={};o.Q.r(E),o.Q.d(E,{isJsExt:()=>tm,isStyleExt:()=>tf});var D={};o.Q.r(D),o.Q.d(D,{getMcpConfigPath:()=>tp,writeMcpPort:()=>tc});var k={};o.Q.r(k),o.Q.d(k,{diffAssetsByExtensions:()=>eQ,diffSize:()=>eq,extname:()=>eJ,filterAssets:()=>eL,filterAssetsByExtensions:()=>e$,filterModulesAndDependenciesByPackageDeps:()=>eB,formatAssetName:()=>eF,getAllBundleData:()=>eH,getAssetDetails:()=>eZ,getAssetsDiffResult:()=>eU,getAssetsSizeInfo:()=>eK,getAssetsSummary:()=>eV,getBundleDiffResult:()=>e1,getChunkByChunkId:()=>ex,getChunkIdsByAsset:()=>eA,getChunksByAsset:()=>eP,getChunksByChunkIds:()=>eI,getChunksByModule:()=>eS,getChunksByModuleId:()=>eE,getDependenciesByModule:()=>ek,getDependencyByPackageData:()=>eD,getDependencyByResolvedRequest:()=>eb,getEntryPoints:()=>e5,getInitialAssetsSizeInfo:()=>eY,getModuleByDependency:()=>eR,getModuleDetails:()=>eG,getModuleIdsByChunk:()=>ej,getModuleIdsByModulesIds:()=>eC,getModulesByAsset:()=>e_,getModulesByChunk:()=>ew,getModulesByChunks:()=>ez,getModulesDiffResult:()=>eX,getPackagesDiffResult:()=>e0,isAssetMatchExtension:()=>eT,isAssetMatchExtensions:()=>eN,isInitialAsset:()=>eW});var b={};o.Q.r(b),o.Q.d(b,{LoaderInternalPropertyName:()=>el,findLoaderTotalTiming:()=>Z,getDirectoriesLoaders:()=>ei,getLoaderChartData:()=>et,getLoaderCosts:()=>J,getLoaderFileDetails:()=>es,getLoaderFileFirstInput:()=>eo,getLoaderFileInputAndOutput:()=>ea,getLoaderFileTree:()=>er,getLoaderFolderStatistics:()=>en,getLoaderNames:()=>X,getLoadersCosts:()=>H,getLoadersTransformData:()=>ee,isVue:()=>ed});var _={};o.Q.r(_),o.Q.d(_,{fetchShardingData:()=>Q,fetchShardingFiles:()=>V,isShardingData:()=>q});var j={};o.Q.r(j),o.Q.d(j,{MODULE_PATH_PACKAGES:()=>td,PACKAGE_PATH_NAME:()=>tu,getPackageMetaFromModulePath:()=>th});var C={};o.Q.r(C),o.Q.d(C,{getPluginData:()=>e4,getPluginHooks:()=>e7,getPluginSummary:()=>e3,getPluginTapNames:()=>e6});var w={};o.Q.r(w),o.Q.d(w,{getResolverCosts:()=>ey,getResolverFileDetails:()=>eM,getResolverFileTree:()=>ev,isResolveFailData:()=>eg,isResolveSuccessData:()=>em});var z={};o.Q.r(z),o.Q.d(z,{RspackLoaderInternalPropertyName:()=>tt,RspackSummaryCostsDataName:()=>tr,checkSourceMapSupport:()=>ts});var R={};o.Q.r(R),o.Q.d(R,{SummaryCostsDataName:()=>O});var B={};o.Q.r(B),o.Q.d(B,{formatCosts:()=>ep,getCurrentTimestamp:()=>ef,getUnit:()=>ec,toFixedDigits:()=>eh});var G={};o.Q.r(G),o.Q.d(G,{isFilePath:()=>Y,isRemoteUrl:()=>U,isUrl:()=>W});var O=((s={}).Bootstrap="bootstrap->beforeCompile",s.Compile="beforeCompile->afterCompile",s.Done="afterCompile->done",s.Minify="minify(processAssets)",s);function F(e){let t=`${e.charCodeAt(0)}`;for(let r=1;r<e.length;r++)t+=`!${e.charCodeAt(r)}`;return t}function T(e){let t="",r="";for(let s=0;s<e.length;s++)"!"===e[s]?(t+=String.fromCharCode(+r),r=""):r+=e[s];return r&&(t+=String.fromCharCode(+r)),t}function N(e){let t,r;e.sort((e,t)=>e[0]-t[0]);let s=[];for(let n=0;n<e.length;n++)r=e[n],!t||r[0]>t[1]?(t=r,s.push(r)):t[1]=Math.max(t[1],r[1]);return s}function $(e){try{return(0,a.deflateSync)(e).toString("base64")}catch(e){return g.vF.debug(`compressText error: ${e}`),""}}function L(e){return(0,a.inflateSync)(l.Buffer.from(e,"base64")).toString()}function K(e,t){return Math.floor(Math.random()*(t-e+1)+e)}function W(e){return/^https?:\/\//.test(e)}function Y(e){return(0,d.isAbsolute)(e)}function U(e){return!!("string"==typeof e&&(W(e)||(0,d.isAbsolute)(e)))}function q(e){return!!(Array.isArray(e)&&e.length>0&&e.every(e=>U(e)))}async function Q(e,t){let r=await Promise.all(e.map(e=>t(e))),s=0===r.length?[]:r.reduce((e,t)=>e+t);return"object"==typeof s?s:JSON.parse(L(s))}async function V(e,t,r){return(await Promise.all(Object.keys(e).map(async s=>{let n=e[s];return(null==r?void 0:r.length)&&0>r.indexOf(s)?{[s]:[]}:q(n)?{[s]:await Q(n,t)}:{[s]:n}}))).reduce((e,t)=>Object.assign(e,t))}function Z(e){let t=1/0,r=-1/0;for(let s=0;s<e.length;s++){let n=e[s];n.startAt<=t&&(t=n.startAt),n.endAt>=r&&(r=n.endAt)}return{start:t,end:r}}function H(e,t){let r={},s={};t.forEach(t=>{e(t)?(r[t.pid]||(r[t.pid]=[]),r[t.pid].push([t.startAt,t.endAt])):(s[t.pid]||(s[t.pid]=[]),s[t.pid].push([t.startAt,t.endAt]))});let n=0,i=Object.keys(r);for(let e=0;e<i.length;e++){let t=i[e],o=N(r[t]),a=N(s[t]||[]).filter(e=>{let[t,r]=e;return o.some(e=>t>=e[0]&&r<=e[1])});n+=(o.length?o.reduce((e,t)=>e+=t[1]-t[0],0):0)-(a.length?a.reduce((e,t)=>e+=t[1]-t[0],0):0)}return n}function J(e,t){let r=t.filter(t=>!t.loader.includes("builtin")&&t!==e&&t.pid===e.pid&&t.startAt>=e.startAt&&t.endAt<=e.endAt),s=e.endAt-e.startAt;return r.length&&N(r.map(t=>[Math.max(t.startAt,e.startAt),Math.min(t.endAt,e.endAt)])).forEach(e=>{let t=e[1]-e[0];s-=t}),s}function X(e){let t=new Set;return e.forEach(e=>e.loaders.forEach(e=>t.add(eu(e.loader)))),[...t]}function ee(e){let t=[];for(let r=0;r<e.length;r++){let s=e[r];for(let e=0;e<s.loaders.length;e++){let r=s.loaders[e];t.push(r)}}return t}function et(e){let t=[],r=ee(e);return e.forEach(e=>{e.loaders.forEach(s=>{t.push({layer:e.resource.layer,loader:eu(s.loader),isPitch:s.isPitch,startAt:s.startAt,endAt:s.endAt,pid:s.pid,sync:s.sync,resource:e.resource.path,costs:J(s,r)})})}),t}function er(e){let t=ee(e);return e.map(e=>{let{loaders:r,resource:s}=e;return{path:s.path,layer:s.layer,loaders:r.map(e=>({key:e.path,loader:eu(e.loader),path:e.path,errors:e.errors,costs:J(e,t)}))}})}function es(e,t){let r=t.find(t=>t.resource.path===e);if(!r)throw Error(`"${e}" not match any loader data`);let s=ee(t);return{...r,loaders:r.loaders.map(e=>{let{input:t,result:r,...n}=e;return{...n,loader:eu(e.loader),costs:J(e,s)}})}}function en(e,t){let r=t.filter(t=>{let{path:r}=t.resource;return r.startsWith(e)}),s=[],n=new Map;return r.forEach(e=>{e.loaders.forEach(e=>{let t=n.get(e.loader);return t?n.set(e.loader,{files:t.files+1,path:e.path}):n.set(e.loader,{files:1,path:e.path}),s.push({loader:e.loader,startAt:e.startAt,endAt:e.endAt,pid:e.pid})})}),Array.from(n).map(e=>{let t=H(t=>t.loader===e[0],s);return{loader:e[0],files:e[1].files,path:e[1].path,costs:t}})}function ei(e,t){let r,s=t||v.cwd();return(r=new Set,e.forEach(e=>{if(e.resource.path.startsWith(s)){let t=e.resource.path.split(s).slice(1).join("/").split("/");if(t.length>=2){let e=t.slice(0,2).join("/");r.add(`${s}/${e}`)}}else{let t=e.resource.path.split("/"),s=t.slice(0,t.length-1).join("/");r.add(s)}}),Array.from(r)).map(t=>{let r=en(t,e);return{directory:t,stats:r}})}function eo(e,t){for(let r=0;r<t.length;r++){let s=t[r];if(s.resource.path===e){let e=s.loaders.filter(e=>!e.isPitch);if(!e.length)return"";return e[0].input||""}}return""}function ea(e,t,r,s){for(let n=0;n<s.length;n++){let i=s[n];if(i.resource.path===e)for(let e=0;e<i.loaders.length;e++){let s=i.loaders[e];if(eu(s.loader)===t&&s.loaderIndex===r)return{input:s.input||"",output:s.result||""}}}return{input:"",output:""}}let el="__l__",ed=e=>("module"in e.options&&e.options.module.rules||[]).some(e=>{var t;return!!(e&&"object"==typeof e&&e.test instanceof RegExp&&(null==(t=e.test)?void 0:t.test(".vue")))}),eu=e=>{let t=e.includes("node_modules")?e.split("node_modules"):null;return t?t[t.length-1]:e};function eh(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2;return 0===t?Math.floor(e):+e.toFixed(t)}function ec(e,t){return"m"===t?e>1?"mins":"min":e>1?"hours":"hour"}function ep(e){if((e=Number(e))>=1e3){let t=e/1e3;if(t>=60){let e=t/60;if(e>=60){let t=eh(e/60,0),r=eh(e%60,1),s=ec(t,"h");return r>0?`${t}${s} ${r}${ec(r,"m")}`:`${t}${s}`}let r=ec(e=eh(e,0),"m"),s=eh(t%60,0);return s>0?`${e}${r} ${s}s`:`${e}${r}`}return`${eh(t,1)}s`}if(e>=10)return`${+eh(e,0)}ms`;if(e>=1)return`${+eh(e,1)}ms`;let t=+eh(e,2);return 0===t&&(t=+eh(e,3)),`${t}ms`}function ef(e,t){let r=(0,h.hrtime)(t);return e+1e3*r[0]+(v.env.RSTEST?Math.round(r[1]/1e6):r[1]/1e6)}function em(e){return!!e.result}function eg(e){return!!e.error}function ey(e,t){let r=t.filter(t=>t!==e&&t.pid===e.pid&&t.startAt>=e.startAt&&t.endAt<=e.endAt),s=e.endAt-e.startAt;return r.length&&N(r.map(t=>[Math.max(t.startAt,e.startAt),Math.min(t.endAt,e.endAt)])).forEach(e=>{let t=e[1]-e[0];s-=t}),s}function ev(e){return e.map(e=>({issuerPath:e.issuerPath}))}function eM(e,t,r,s){let n=r.find(t=>t.path===e),i=t.filter(t=>t.issuerPath===e),o=n&&s&&s[n.id]?s[n.id].source:"",a=i.reduce((e,t)=>t.request&&em(t)?e.replace(RegExp(`["']${t.request}["']`),`"${t.result}"`):e,o);return{filepath:e,before:o,after:a,resolvers:i.map(e=>({...e,costs:ey(e,t)}))}}function eA(e){return e.chunks?e.chunks:[]}function eS(e,t){return e.chunks.length?eI(e.chunks,t):[]}function ex(e,t){return t.find(t=>t.id===e)}function eI(e,t,r){return e.length?e.map(e=>t.find(t=>t.id===e)).filter(Boolean).map(e=>{if(r&&r.length>0){let t={};for(let s of r)void 0!==e[s]&&(t[s]=e[s]);return t}return e}):[]}function eP(e,t,r){return eI(eA(e),t,r)}function eE(e,t,r){let s=t.find(t=>t.id===e);return s?eS(s,r):[]}function eD(e,t){return t.find(t=>t.id===e.dependencyId)}function ek(e,t){return e.dependencies.map(e=>t.find(t=>t.id===e)).filter(Boolean)}function eb(e,t){return t.find(t=>t.resolvedRequest===e)}function e_(e,t,r,s,n){return ez(eI(eA(e),t),r,s,n)}function ej(e){let{modules:t=[]}=e;return t}function eC(e,t){return e.map(e=>t.find(t=>t.id===e)).filter(Boolean)}function ew(e,t,r){return ej(e).map(e=>{let s=t.find(t=>t.id===e);if(r&&r.length>0){if(!s)return null;let e={};for(let t of r)void 0!==s[t]&&(e[t]=s[t]);return e}return s}).filter(Boolean)}function ez(e,t,r,s){let n=[];try{e.forEach(e=>{ew(e,t,r).forEach(e=>{(!s||s(e))&&!n.filter(t=>t.id===e.id).length&&n.push(e)})})}catch(e){g.vF.debug(e)}return n}function eR(e,t){return t.find(t=>t.id===e.module)}function eB(e,t,r){let s=[],n=[];for(let i=0;i<e.length;i++){let o=eD(e[i],t);if(o){s.push(o);let e=eR(o,r);e&&n.push(e)}}return{dependencies:s,modules:n}}function eG(e,t,r,s){let n=t.find(t=>t.id===e);return{module:n,dependencies:ek(n,r),...(null==s?void 0:s.length)?{sideEffectCodes:s}:{}}}let eO=RegExp(`(.*)${/[-|.]/.source}(${/(?:[a-f0-9]{4,32}|[a-zA-Z]{3,}[0-9]|[a-zA-Z]*[0-9][a-zA-Z]{2,}|[a-zA-Z]*[0-9][a-zA-Z0-9]{3,31})/.source})(${/(?:\.[a-z｜A-Z|0-9]{2,}){1,}/.source})$`);function eF(e,t){var r;let s=null==t?void 0:t.split("."),n="",i=e;if((null==s?void 0:s.length)&&s.length>=3&&(null==(r=s[s.length-2])?void 0:r.indexOf("["))<0&&"js|css|html".indexOf(s[s.length-1])>-1){n=s[s.length-2];let t=e.match(/(.*)(\.([a-f0-9]{4,32}|[a-zA-Z]*[0-9][a-zA-Z0-9]*))(\.[^.]+){2,}$/);if(t&&t[3].length>=4&&t[3].length<=32)return i=t[1],`${i}.${n}.${e.substring(e.lastIndexOf(".")+1)}`}let o=e.match(eO);return o&&o[2]&&o[2].length>=4&&o[2].length<=32?e.replace(eO,"$1$3"):e}function eT(e,t){return e.path.slice(-t.length)===t||eJ(e.path)===t}function eN(e,t){return!!t.length&&t.some(t=>eT(e,t))}function e$(e,t){return"string"==typeof t?e.filter(e=>eT(e,t)):Array.isArray(t)?e.filter(e=>eN(e,t)):[]}function eL(e,t){return t&&(e="function"==typeof t?e.filter(t):e$(e,t)),e}function eK(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{withFileContent:s=!0,filterOrExtensions:n}=r;return(e=e.filter(e=>!eN(e,c.YM.MapExtensions)),n&&(e=eL(e,n)),e.length)?{count:e.length,size:e.reduce((e,t)=>e+t.size,0),files:e.map(e=>({path:e.path,size:e.size,gzipSize:e.gzipSize,initial:eW(e,t),content:s?e.content:void 0}))}:{count:0,size:0,files:[]}}function eW(e,t){return eP(e,t).some(e=>!!e.initial)}function eY(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return r.filterOrExtensions&&(e=eL(e,r.filterOrExtensions)),eK(e,t,{...r,filterOrExtensions:e=>eW(e,t)})}function eU(e,t){return{all:{total:eQ(e,t)},js:{total:eQ(e,t,c.YM.JSExtensions),initial:eQ(e,t,c.YM.JSExtensions,!0)},css:{total:eQ(e,t,c.YM.CSSExtension),initial:eQ(e,t,c.YM.CSSExtension,!0)},imgs:{total:eQ(e,t,c.YM.ImgExtensions)},html:{total:eQ(e,t,c.YM.HtmlExtension)},media:{total:eQ(e,t,c.YM.MediaExtensions)},fonts:{total:eQ(e,t,c.YM.FontExtensions)},others:{total:eQ(e,t,e=>!eN(e,[...c.YM.JSExtensions,c.YM.CSSExtension,c.YM.HtmlExtension].concat(c.YM.ImgExtensions,c.YM.MediaExtensions,c.YM.FontExtensions,c.YM.MapExtensions)))}}}function eq(e,t){let r=e===t;return{percent:r?0:0===e?100:Math.abs(t-e)/e*100,state:r?c.Kj.RsdoctorClientDiffState.Equal:e>t?c.Kj.RsdoctorClientDiffState.Down:c.Kj.RsdoctorClientDiffState.Up}}function eQ(e,t,r){let s=arguments.length>3&&void 0!==arguments[3]&&arguments[3],n,i,{size:o,count:a}=s?eY(e.assets,e.chunks,{filterOrExtensions:r}):eK(e.assets,e.chunks,{filterOrExtensions:r});if(e===t)n=o,i=a;else{let{size:e,count:o}=s?eY(t.assets,t.chunks,{filterOrExtensions:r}):eK(t.assets,t.chunks,{filterOrExtensions:r});n=e,i=o}let{percent:l,state:d}=eq(o,n);return{size:{baseline:o,current:n},count:{baseline:a,current:i},percent:l,state:d}}function eV(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},s={...r,filterOrExtensions:c.YM.JSExtensions},n={...r,filterOrExtensions:c.YM.CSSExtension},i={...r,filterOrExtensions:c.YM.ImgExtensions},o={...r,filterOrExtensions:c.YM.HtmlExtension},a={...r,filterOrExtensions:c.YM.MediaExtensions},l={...r,filterOrExtensions:c.YM.FontExtensions},d={...r,filterOrExtensions:e=>!eN(e,[...c.YM.JSExtensions,c.YM.CSSExtension,c.YM.HtmlExtension].concat(c.YM.ImgExtensions,c.YM.MediaExtensions,c.YM.FontExtensions,c.YM.MapExtensions))};return{all:{total:eK(e,t,r)},js:{total:eK(e,t,s),initial:eY(e,t,s)},css:{total:eK(e,t,n),initial:eY(e,t,n)},imgs:{total:eK(e,t,i)},html:{total:eK(e,t,o)},media:{total:eK(e,t,a)},fonts:{total:eK(e,t,l)},others:{total:eK(e,t,d)}}}function eZ(e,t,r,s,n){let i=t.find(t=>t.path===e);return{asset:i,chunks:eP(i,r),modules:e_(i,r,s,void 0,n)}}function eH(e,t,r,s){let n=[];try{for(let i=0;i<e.length;i++){let o=e[i];n.push({asset:o,modules:e_(o,t,r,s)})}return n}catch(e){return console.error(e),[]}}function eJ(e){let t=e.split("?")[0].match(/\.([0-9a-z]+)(?:[\?#]|$)/i);return t?`.${t[1]}`:""}function eX(e,t){let r=new Map;for(let t of e.modules)r.set(t.path,t);let s=new Map;for(let e of t.modules)s.set(e.path,e);let n=[],i=[],o=[];for(let[e,t]of r){let r=s.get(e);if(r){if(t.size.parsedSize!==r.size.parsedSize){let{percent:s,state:n}=eq(t.size.parsedSize,r.size.parsedSize);o.push({path:e,size:{baseline:t.size,current:r.size},percent:s,state:n})}}else i.push({path:e,size:t.size})}for(let[e,t]of s)r.has(e)||n.push({path:e,size:t.size});return n.sort((e,t)=>e.path.localeCompare(t.path)),i.sort((e,t)=>e.path.localeCompare(t.path)),o.sort((e,t)=>e.path.localeCompare(t.path)),{added:n,removed:i,changed:o}}function e0(e,t){let r=e=>`${e.name}@${e.version}`,s=new Map;for(let t of e.packages)s.set(r(t),t);let n=new Map;for(let e of t.packages)n.set(r(e),e);let i=[],o=[],a=[];for(let[e,t]of s){let r=n.get(e);if(r){if(t.size.parsedSize!==r.size.parsedSize){let{percent:e,state:s}=eq(t.size.parsedSize,r.size.parsedSize);a.push({name:t.name,version:t.version,root:t.root,size:{baseline:t.size,current:r.size},percent:e,state:s})}}else o.push({name:t.name,version:t.version,root:t.root,size:t.size})}for(let[e,t]of n)s.has(e)||i.push({name:t.name,version:t.version,root:t.root,size:t.size});return{added:i,removed:o,changed:a}}function e1(e,t){return{assets:eU(e.chunkGraph,t.chunkGraph),modules:eX(e.moduleGraph,t.moduleGraph),packages:e0(e.packageGraph,t.packageGraph)}}function e5(e){return e}function e2(e){let t=encodeURIComponent(e.join(","));return t&&(t=`?${c.Kj.RsdoctorClientUrlQuery.BundleDiffFiles}=${t}`),t}function e9(e){let t=e2(e);return`${t}#${c.Kj.RsdoctorClientRoutes.BundleDiff}`}function e8(e){return decodeURIComponent(e).split(",")}function e7(e){return Object.keys(e)}function e6(e){let t=e7(e),r=new Set;return t.forEach(t=>{e[t].forEach(e=>{r.add(e.tapName)})}),[...r]}function e3(e){return{hooks:e7(e),tapNames:e6(e)}}function e4(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],s=e7(e).filter(e=>!t.length||-1!==t.indexOf(e));return s.length?e6(e).reduce((t,n)=>(r.length&&-1===r.indexOf(n)||s.forEach(r=>{let s=e[r].filter(e=>e.tapName===n);0!==s.length&&t.push({tapName:n,hook:r,data:s.map(e=>({startAt:e.startAt,endAt:e.endAt,costs:e.costs,type:e.type}))})}),t),[]):[]}function te(e,t,r,s,n){return s.slice().reverse().map(s=>{let i=t.find(e=>e.id===s.dependencyId);if(!i)return null;let o=e.find(e=>e.id===i.module);return o?{group:s.group,module:o,dependency:i,relativePath:(0,d.relative)(r,o.path),moduleCode:null==n?void 0:n[o.id]}:null}).filter(Boolean)}let tt="__l__";var tr=((n={}).Bootstrap="bootstrap->rspack:beforeCompile",n.Compile="rspack:beforeCompile->afterCompile",n.Done="rspack:afterCompile->done",n.Minify="rspack:minify(rspack:optimizeChunkAssets)",n);function ts(e){var t,r,s,n;if(!Array.isArray(e)||!e[0])return{isRspack:!1,hasSourceMap:!1};let i="rspack"===e[0].name&&(null==(r=e[0])||null==(t=r.config)?void 0:t.name)!=="lynx",o=null==(s=e[0].config)?void 0:s.devtool,a=null==(n=e[0].config)?void 0:n.plugins,l=null==a?void 0:a.filter(e=>e&&e.includes("SourceMapDevToolPlugin"));return{isRspack:i,hasSourceMap:"string"==typeof o&&o.includes("source-map")&&!o.includes("eval")||!!(null==l?void 0:l.length)}}class tn{log(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];console.log(`[${this.constructor.name}]`,...t)}loadAPI(){for(var e,t=arguments.length,r=Array(t),s=0;s<t;s++)r[s]=arguments[s];let[n,i]=r;switch(n){case c.hp.ServerAPI.API.LoadDataByKey:return this.loader.loadData(i.key);case c.hp.ServerAPI.API.GetProjectInfo:return Promise.all([this.loader.loadData("root"),this.loader.loadData("pid"),this.loader.loadData("hash"),this.loader.loadData("summary"),this.loader.loadData("configs"),this.loader.loadData("envinfo"),this.loader.loadData("errors")]).then(e=>{var t,r;let[s,n,i,o,a,l,d]=e;return{root:s,pid:n,hash:i,summary:o,configs:a,envinfo:l,errors:d,name:null==a||null==(r=a[0])||null==(t=r.config)?void 0:t.name}});case c.hp.ServerAPI.API.GetClientRoutes:if("u">typeof window&&(null==(e=window)?void 0:e[c.YM.WINDOW_RSDOCTOR_TAG]))return window[c.YM.WINDOW_RSDOCTOR_TAG].enableRoutes;return this.loader.loadManifest().then(e=>{let{enableRoutes:t=[]}=e.client||{};return t});case c.hp.ServerAPI.API.GetLoaderNames:return this.loader.loadData("loader").then(e=>X(e||[]));case c.hp.ServerAPI.API.GetLayers:return this.loader.loadData("moduleGraph").then(e=>{let{layers:t}=e||{};return t});case c.hp.ServerAPI.API.GetLoaderChartData:return this.loader.loadData("loader").then(e=>et(e||[]));case c.hp.ServerAPI.API.GetLoaderFileTree:return this.loader.loadData("loader").then(e=>er(e||[]));case c.hp.ServerAPI.API.GetLoaderFileDetails:return this.loader.loadData("loader").then(e=>es(i.path,e||[]));case c.hp.ServerAPI.API.GetLoaderFolderStatistics:return this.loader.loadData("loader").then(e=>en(i.folder,e||[]));case c.hp.ServerAPI.API.GetLoaderFileFirstInput:return this.loader.loadData("loader").then(e=>eo(i.file,e||[]));case c.hp.ServerAPI.API.GetLoaderFileInputAndOutput:return this.loader.loadData("loader").then(e=>ea(i.file,i.loader,i.loaderIndex,e||[]));case c.hp.ServerAPI.API.GetResolverFileTree:return this.loader.loadData("resolver").then(e=>ev(e||[]));case c.hp.ServerAPI.API.GetResolverFileDetails:return Promise.all([this.loader.loadData("resolver"),this.loader.loadData("moduleGraph.modules"),this.loader.loadData("moduleCodeMap")]).then(e=>{let t=e[0],r=e[1],s=e[2];return eM(i.filepath,t||[],r||[],s||{})});case c.hp.ServerAPI.API.GetPluginSummary:return this.loader.loadData("plugin").then(e=>e3(e||{}));case c.hp.ServerAPI.API.GetPluginData:return this.loader.loadData("plugin").then(e=>{let{hooks:t,tapNames:r}=i;return e4(e||{},t,r)});case c.hp.ServerAPI.API.GetAssetsSummary:return this.loader.loadData("chunkGraph").then(e=>{let{withFileContent:t=!0}=i,{assets:r=[],chunks:s=[]}=e||{};return eV(r,s,{withFileContent:t})});case c.hp.ServerAPI.API.GetAssetDetails:return Promise.all([this.loader.loadData("chunkGraph"),this.loader.loadData("moduleGraph"),this.loader.loadData("configs")]).then(e=>{let{assetPath:t}=i,{isRspack:r,hasSourceMap:s}=ts(e[2]||[]),{assets:n=[],chunks:o=[]}=e[0]||{},{modules:a=[]}=e[1]||{};return eZ(t,n,o,a,r||s?e=>0!==e.size.parsedSize:()=>!0)});case c.hp.ServerAPI.API.GetSummaryBundles:return Promise.all([this.loader.loadData("chunkGraph"),this.loader.loadData("moduleGraph"),this.loader.loadData("configs")]).then(e=>{var t,r;let{assets:s=[],chunks:n=[]}=e[0]||{},{modules:i=[]}=e[1]||{},o=e[2]||[],a=s;return Array.isArray(o)&&(null==(r=o[0])||null==(t=r.config)?void 0:t.name)==="lynx"&&(a=s.filter(e=>!e.path.endsWith("/template.js"))),eH(a,n,i,["id","path","size","kind"])});case c.hp.ServerAPI.API.GetChunksByModuleId:return Promise.all([this.loader.loadData("chunkGraph"),this.loader.loadData("moduleGraph")]).then(e=>{let{moduleId:t}=i,{chunks:r=[]}=e[0]||{},{modules:s=[]}=e[1]||{};return eE(t,s,r)});case c.hp.ServerAPI.API.GetModuleDetails:return Promise.all([this.loader.loadData("chunkGraph"),this.loader.loadData("moduleGraph"),this.loader.loadData("treeShaking")]).then(e=>{let{moduleId:t}=i,{modules:r=[],dependencies:s=[]}=e[1]||{},n=e[2],o=(null==n?void 0:n.sideEffectCodes[t])||[];return eG(t,r,s,o)});case c.hp.ServerAPI.API.GetModulesByModuleIds:return this.loader.loadData("moduleGraph").then(e=>{let{moduleIds:t}=i,{modules:r=[]}=e||{};return eC(t,r)});case c.hp.ServerAPI.API.GetEntryPoints:return Promise.all([this.loader.loadData("chunkGraph")]).then(e=>{let[t]=e,{entrypoints:r=[]}=t||{};return r});case c.hp.ServerAPI.API.GetModuleCodeByModuleId:return this.loader.loadData("moduleCodeMap").then(e=>{let{moduleId:t}=i;return e?e[t]:{source:"",transformed:"",parsedSource:""}});case c.hp.ServerAPI.API.GetModuleCodeByModuleIds:return this.loader.loadData("moduleCodeMap").then(e=>{let{moduleIds:t}=i,r={};return e?(t.forEach(t=>{r[t]=e[t]}),r):[]});case c.hp.ServerAPI.API.GetAllModuleGraph:return this.loader.loadData("moduleGraph").then(e=>null==e?void 0:e.modules);case c.hp.ServerAPI.API.GetSearchModules:return Promise.all([this.loader.loadData("moduleGraph"),this.loader.loadData("chunkGraph")]).then(e=>{let[t,r]=e,{moduleName:s}=i;if(!s)return[];let n=r.chunks.reduce((e,t)=>(t.assets.forEach(r=>{e[t.id]||(e[t.id]=[]),e[t.id].push(r)}),e),{}),o=new Map;return null==t||t.modules.filter(e=>{e.webpackId.includes(s)&&e.chunks.forEach(e=>{o.has(e)||(n[e]||[]).forEach(t=>{t.endsWith(".js")&&o.set(e,t)})})}),Object.fromEntries(o)});case c.hp.ServerAPI.API.GetSearchModuleInChunk:return Promise.all([this.loader.loadData("moduleGraph"),this.loader.loadData("root")]).then(e=>{let[t,r]=e,{moduleName:s,chunk:n}=i;return s?null==t?void 0:t.modules.filter(e=>e.webpackId.includes(s)&&e.chunks.includes(n)).map(e=>({id:e.id,path:e.path,relativePath:(0,d.relative)(r,e.path)})):[]});case c.hp.ServerAPI.API.GetAllChunkGraph:return this.loader.loadData("chunkGraph").then(e=>null==e?void 0:e.chunks);case c.hp.ServerAPI.API.GetPackageRelationAlertDetails:return Promise.all([this.loader.loadData("moduleGraph"),this.loader.loadData("errors"),this.loader.loadData("root"),this.loader.loadData("moduleCodeMap")]).then(e=>{let{id:t,target:r}=i,[s,n=[],o="",a]=e,{modules:l=[],dependencies:d=[]}=s||{},{packages:u=[]}=n.find(e=>e.id===t)||{},{dependencies:h=[]}=u.find(e=>e.target.name===r.name&&e.target.root===r.root&&e.target.version===r.version)||{};return te(l,d,o,h,a||{})});case c.hp.ServerAPI.API.GetOverlayAlerts:return this.loader.loadData("errors").then(e=>(e||[]).filter(e=>e.code===c.jO.RuleMessageCodeEnumerated.Overlay));case c.hp.ServerAPI.API.GetBundleAlerts:return this.loader.loadData("errors").then(e=>(e||[]).filter(e=>e.category===c.jO.RuleMessageCategory.Bundle));case c.hp.ServerAPI.API.BundleDiffManifest:return this.loader.loadManifest();case c.hp.ServerAPI.API.GetBundleDiffSummary:return Promise.all([this.loader.loadManifest(),this.loader.loadData("root"),this.loader.loadData("hash"),this.loader.loadData("errors"),this.loader.loadData("chunkGraph"),this.loader.loadData("moduleGraph"),this.loader.loadData("moduleCodeMap"),this.loader.loadData("packageGraph"),this.loader.loadData("configs")]).then(e=>{var t,r,s,n;let[i,o="",a="",l={},d={},u={},h={},c={},p=[]]=e,f="";return"string"==typeof(null==(s=p[0])||null==(r=s.config)||null==(t=r.output)?void 0:t.chunkFilename)&&(f=null==(n=p[0])?void 0:n.config.output.chunkFilename),{root:o,hash:a,errors:l,chunkGraph:d,moduleGraph:u,packageGraph:c,outputFilename:f,moduleCodeMap:h}});case c.hp.ServerAPI.API.GetChunkGraph:return this.loader.loadData("chunkGraph").then(e=>{let{chunks:t=[]}=e||{};return t});case c.hp.ServerAPI.API.GetAllModuleGraphFilter:return this.loader.loadData("moduleGraph").then(e=>null==e?void 0:e.modules.map(e=>({id:e.id,webpackId:e.webpackId,path:e.path,size:e.size,chunks:e.chunks,kind:e.kind})));case c.hp.ServerAPI.API.GetModuleByName:return this.loader.loadData("moduleGraph").then(e=>{let{moduleName:t}=i,{modules:r=[]}=e||{};return r.filter(e=>e.path.includes(t)).map(e=>({id:e.id,path:e.path}))||[]});case c.hp.ServerAPI.API.GetModuleIssuerPath:return this.loader.loadData("moduleGraph").then(e=>{var t;let{moduleId:r}=i,s=(null==e?void 0:e.modules)||[],n=(null==(t=s.find(e=>String(e.id)===r))?void 0:t.issuerPath)||[];return Array.isArray(n)&&n.length>0&&"number"==typeof n[0]?n.map(e=>{var t;return null==(t=s.find(t=>t.id===e))?void 0:t.path}).filter(Boolean):n});case c.hp.ServerAPI.API.GetPackageInfo:return this.loader.loadData("packageGraph").then(e=>null==e?void 0:e.packages);case c.hp.ServerAPI.API.GetPackageDependency:return this.loader.loadData("packageGraph").then(e=>(null==e?void 0:e.dependencies)||[]);case c.hp.ServerAPI.API.GetChunkGraphAI:return this.loader.loadData("chunkGraph").then(e=>{let{assets:t=[]}=e||{};return t.map(e=>{let{content:t,...r}=e;return r})});case c.hp.ServerAPI.API.GetChunkByIdAI:return Promise.all([this.loader.loadData("chunkGraph"),this.loader.loadData("moduleGraph")]).then(e=>{let[t,r]=e,{chunks:s=[]}=t||{},{modules:n=[]}=r||{},{chunkId:o}=i,a=s.find(e=>e.id===o);if(!a)return null;let l=n.filter(e=>a.modules.includes(e.id)).map(e=>({id:e.id,path:e.path,size:e.size,chunks:e.chunks,kind:e.kind,issuerPath:e.issuerPath}));return a.modulesInfo=l,a});case c.hp.ServerAPI.API.GetDirectoriesLoaders:return Promise.all([this.loader.loadData("root"),this.loader.loadData("loader")]).then(e=>{let[t,r]=e;return ei(r||[],t||"")});default:throw Error(`API not implement: "${n}"`)}}constructor(e){(0,i._)(this,"loader",void 0),this.loader=e,this.loadAPI=this.loadAPI.bind(this)}}function ti(){let e=globalThis.fetch;if("function"!=typeof e)throw Error("fetch is not available in this environment");return e.bind(globalThis)}async function to(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{timeout:r=3e4,signal:s,...n}=t,i=new AbortController,o=setTimeout(()=>i.abort(),r);s&&(s.aborted?i.abort():s.addEventListener("abort",()=>i.abort(),{once:!0}));let a=ti();try{let t=await a(e,{...n,signal:i.signal});if(!t.ok)throw Error(`Request failed with status ${t.status}`);return t}finally{clearTimeout(o)}}async function ta(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:3e4;return to(e,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(t),timeout:r})}let tl=/[a-zA-Z0-9]+(?:[-|_|.]+[a-zA-Z0-9]+)*/,td=RegExp(`(?:${/(?:node_modules|~)(?:\/\.pnpm)?/.source}/)(?:(?:@${tl.source}[/|+])?(?:${tl.source}\\+)*(?:${tl.source})(?:${/@[\w|\-|_|.]+/.source})?)(?:_(?:@${tl.source}[/|+])?(?:${tl.source})(?:@${tl.source})?)*/`,"g"),tu=/(?:(?:node_modules|~)(?:\/\.pnpm)?\/)(?:((?:@[a-zA-Z0-9]+(?:[-|_|.]+[a-zA-Z0-9]+)*[/|+])?(?:(?:[a-zA-Z0-9]+(?:[-|_|.]+[a-zA-Z0-9]+)*\+)*)(?:[a-zA-Z0-9]+(?:[-|_|.]+[a-zA-Z0-9]+)*))(?:@[\w|\-|_|.]+)?)(?:_((?:@[a-zA-Z0-9]+(?:[-|_|.]+[a-zA-Z0-9]+)*[/|+])?(?:[a-zA-Z0-9]+(?:[-|_|.]+[a-zA-Z0-9]+)*))(?:@[a-zA-Z0-9]+(?:[-|_|.]+[a-zA-Z0-9]+)*))*\//gm,th=e=>{var t,r,s;let n,i=e.match(td);if(!i)return{name:"",version:""};let o=(s=i.flatMap(e=>{let t=e.matchAll(tu);return t?(0,y.oE)([...t].flat()).slice(1).filter(Boolean).map(e=>e.replace(/\+/g,"/")):[]}),n=[],s.forEach((e,t)=>{s.slice(t+1).includes(e)||n.push(e)}),n);if((0,y.Im)(o))return{name:"",version:""};let a=(0,y.HV)(o),l=RegExp(`(.*)(${(0,y.HV)(i)}).*`),d=e.replace(l,"$1$2").replace(/\/$/,"");return{name:a,version:d&&a&&(null==(r=d.match(RegExp(`${a}@([\\d.]+)`)))||null==(t=r.flat().slice(1))?void 0:t[0])||""}};function tc(e,t){let r=m.homedir(),s=u().join(r,".cache/rsdoctor"),n=u().join(s,"mcp.json");f().existsSync(s)||f().mkdirSync(s,{recursive:!0});let i={portList:{},port:0};if(f().existsSync(n))try{i=JSON.parse(f().readFileSync(n,"utf8"))}catch(e){g.vF.debug("Failed to parse mcp.json",e)}i.portList||(i.portList={}),i.portList[t||"builder"]=e,i.port=e,f().writeFileSync(n,JSON.stringify(i,null,2),"utf8")}function tp(){let e=m.homedir(),t=u().join(e,".cache/rsdoctor");return u().join(t,"mcp.json")}function tf(e){return/\.(c|le|sa|sc)ss(\?.*)?$/.test(e)}function tm(e){return/\.(js|ts|jsx|tsx)(\?.*)?$/.test(e)}}},a={};function l(e){var t=a[e];if(void 0!==t)return t.exports;var r=a[e]={exports:{}};return o[e].call(r.exports,r,r.exports,l),r.exports}l.m=o,l.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return l.d(t,{a:t}),t},t=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,l.t=function(r,s){if(1&s&&(r=this(r)),8&s||"object"==typeof r&&r&&(4&s&&r.__esModule||16&s&&"function"==typeof r.then))return r;var n=Object.create(null);l.r(n);var i={};e=e||[null,t({}),t([]),t(t)];for(var o=2&s&&r;("object"==typeof o||"function"==typeof o)&&!~e.indexOf(o);o=t(o))Object.getOwnPropertyNames(o).forEach(e=>{i[e]=()=>r[e]});return i.default=()=>r,l.d(n,i),n},l.d=(e,t)=>{for(var r in t)l.o(t,r)&&!l.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},l.g=(()=>{if("object"==typeof globalThis)return globalThis;try{return this||Function("return this")()}catch(e){if("object"==typeof window)return window}})(),l.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),l.r=e=>{"u">typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r=[],l.O=(e,t,s,n)=>{if(t){n=n||0;for(var i=r.length;i>0&&r[i-1][2]>n;i--)r[i]=r[i-1];r[i]=[t,s,n];return}for(var o=1/0,i=0;i<r.length;i++){for(var[t,s,n]=r[i],a=!0,d=0;d<t.length;d++)(!1&n||o>=n)&&Object.keys(l.O).every(e=>l.O[e](t[d]))?t.splice(d--,1):(a=!1,n<o&&(o=n));if(a){r.splice(i--,1);var u=s();void 0!==u&&(e=u)}}return e},l.j="331",s={331:0},l.O.j=e=>0===s[e],n=(e,t)=>{var r,n,[i,o,a]=t,d=0;if(i.some(e=>0!==s[e])){for(r in o)l.o(o,r)&&(l.m[r]=o[r]);if(a)var u=a(l)}for(e&&e(t);d<i.length;d++)n=i[d],l.o(s,n)&&s[n]&&s[n][0](),s[n]=0;return l.O(u)},(i=self.webpackChunk_rsdoctor_client=self.webpackChunk_rsdoctor_client||[]).forEach(n.bind(null,0)),i.push=n.bind(null,i.push.bind(i));var d=l.O(void 0,["85","383","577","601"],()=>l(44676));d=l.O(d)})();