System.register("chunks:///_virtual/debug-view-runtime-control.ts",["./rollupPluginModLoBabelHelpers.js","cc"],(function(t){var e,o,i,n,s,l,r,h,g,a,c,p,C,d,m;return{setters:[function(t){e=t.applyDecoratedDescriptor,o=t.initializerDefineProperty},function(t){i=t.cclegacy,n=t.Node,s=t._decorator,l=t.Component,r=t.Color,h=t.Canvas,g=t.UITransform,a=t.instantiate,c=t.Label,p=t.RichText,C=t.Toggle,d=t.Button,m=t.director}],execute:function(){var u,L,M,b,T,f,x,S,E;i._RF.push({},"b2bd1+njXxJxaFY3ymm06WU","debug-view-runtime-control",void 0);const{ccclass:v,property:I}=s;t("DebugViewRuntimeControl",(u=v("internal.DebugViewRuntimeControl"),L=I(n),M=I(n),b=I(n),u((x=e((f=class extends l{constructor(...t){super(...t),o(this,"compositeModeToggle",x,this),o(this,"singleModeToggle",S,this),o(this,"EnableAllCompositeModeButton",E,this),this._single=0,this.strSingle=["No Single Debug","Vertex Color","Vertex Normal","Vertex Tangent","World Position","Vertex Mirror","Face Side","UV0","UV1","UV Lightmap","Project Depth","Linear Depth","Fragment Normal","Fragment Tangent","Fragment Binormal","Base Color","Diffuse Color","Specular Color","Transparency","Metallic","Roughness","Specular Intensity","IOR","Direct Diffuse","Direct Specular","Direct All","Env Diffuse","Env Specular","Env All","Emissive","Light Map","Shadow","AO","Fresnel","Direct Transmit Diffuse","Direct Transmit Specular","Env Transmit Diffuse","Env Transmit Specular","Transmit All","Direct Internal Specular","Env Internal Specular","Internal All","Fog"],this.strComposite=["Direct Diffuse","Direct Specular","Env Diffuse","Env Specular","Emissive","Light Map","Shadow","AO","Normal Map","Fog","Tone Mapping","Gamma Correction","Fresnel","Transmit Diffuse","Transmit Specular","Internal Specular","TT"],this.strMisc=["CSM Layer Coloration","Lighting With Albedo"],this.compositeModeToggleList=[],this.singleModeToggleList=[],this.miscModeToggleList=[],this.textComponentList=[],this.labelComponentList=[],this.textContentList=[],this.hideButtonLabel=void 0,this._currentColorIndex=0,this.strColor=["","","","",""],this.color=[r.WHITE,r.BLACK,r.RED,r.GREEN,r.BLUE]}start(){if(!this.node.parent.getComponent(h))return void console.error("debug-view-runtime-control should be child of Canvas");const t=this.node.parent.getComponent(g),e=.5*t.width,o=.5*t.height;let i=.1*e-e,n=o-.1*o;const s=this.node.getChildByName("MiscMode"),l=a(s);l.parent=this.node,l.name="Buttons";const m=a(s);m.parent=this.node,m.name="Titles";for(let t=0;t<2;t++){const e=a(this.EnableAllCompositeModeButton.getChildByName("Label"));e.setPosition(i+(t>0?450:150),n,0),e.setScale(.75,.75,.75),e.parent=m;const o=e.getComponent(c);o.string=t?"----------Composite Mode----------":"----------Single Mode----------",o.color=r.WHITE,o.overflow=0,this.labelComponentList[this.labelComponentList.length]=o}n-=20;let u=0;for(let t=0;t>1&&(i+=200,u=0);const e=t?a(this.singleModeToggle):this.singleModeToggle;e.setPosition(i,n-20*u,0),e.setScale(.5,.5,.5),e.parent=this.singleModeToggle.parent;const o=e.getComponentInChildren(p);o.string=this.strSingle[t],this.textComponentList[this.textComponentList.length]=o,this.textContentList[this.textContentList.length]=o.string,e.on(C.EventType.TOGGLE,this.toggleSingleMode,this),this.singleModeToggleList[t]=e}i+=200,this.EnableAllCompositeModeButton.setPosition(i+15,n,0),this.EnableAllCompositeModeButton.setScale(.5,.5,.5),this.EnableAllCompositeModeButton.on(d.EventType.CLICK,this.enableAllCompositeMode,this),this.EnableAllCompositeModeButton.parent=l;let L=this.EnableAllCompositeModeButton.getComponentInChildren(c);this.labelComponentList[this.labelComponentList.length]=L;const M=a(this.EnableAllCompositeModeButton);M.setPosition(i+90,n,0),M.setScale(.5,.5,.5),M.on(d.EventType.CLICK,this.changeTextColor,this),M.parent=l,L=M.getComponentInChildren(c),L.string="TextColor",this.labelComponentList[this.labelComponentList.length]=L;const b=a(this.EnableAllCompositeModeButton);b.setPosition(i+200,n,0),b.setScale(.5,.5,.5),b.on(d.EventType.CLICK,this.hideUI,this),b.parent=this.node.parent,L=b.getComponentInChildren(c),L.string="Hide UI",this.labelComponentList[this.labelComponentList.length]=L,this.hideButtonLabel=L,n-=40;for(let t=0;t");return-1===i?t===e:(o=o.substr(i+1),o=o.substr(0,o.search("<")),o===e)}toggleSingleMode(t){const e=m.root.debugView,o=t.getComponentInChildren(p);for(let t=0;t=this.strColor.length&&(this._currentColorIndex=0);for(let t=0;t";for(let t=0;t