"use strict";(self.webpackChunkunifiNetworkUi=self.webpackChunkunifiNetworkUi||[]).push([[87409],{453007(e,r,t){t.d(r,{A:()=>n});var i=t(938984),s=t(247816),o=t(291508);const n=(0,s.A)(i.A,(0,o.A)("colorOverride"))`
  ${({colorOverride:e})=>e?`color: ${e} !important`:""};
`},45216(e,r,t){t.d(r,{A:()=>c});var i=t(274934),s=t(938984),o=t(309130),n=t(100978),l=t(254193);const c=({groupSize:e=4,maxWidth:r,value:t})=>{return(0,i.jsxs)(n.A,{alignItems:"flex-start",children:[(0,i.jsx)(n.A,{gap:o.YC,rowGap:0,flexFlow:"row wrap",maxWidth:r,justifyContent:"space-between",children:(c=t,d=e,c.match(new RegExp(`.{1,${d}}`,"g"))??[]).map(e=>(0,i.jsx)(s.A,{color:"text-3",size:"medium",children:e}))}),(0,i.jsx)(l.A,{value:t})]});var c,d}},527153(e,r,t){t.d(r,{A:()=>a});var i=t(274934),s=t(602086),o=t(814557),n=t(263705),l=t(939940),c=t(931126);const d=({height:e,width:r,strength:t=0,color:s="currentColor",inactiveColor:o="currentColor"})=>(0,i.jsxs)("svg",{width:r,height:e,viewBox:"0 0 31 10",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,i.jsx)("rect",{width:"2.2",height:"10",rx:"1",fill:t>=1?s:o}),(0,i.jsx)("rect",{x:"3.2",width:"2.2",height:"10",rx:"1",fill:t>=2?s:o}),(0,i.jsx)("rect",{x:"6.4",width:"2.2",height:"10",rx:"1",fill:t>=3?s:o}),(0,i.jsx)("rect",{x:"9.6",width:"2.2",height:"10",rx:"1",fill:t>=4?s:o}),(0,i.jsx)("rect",{x:"12.8",width:"2.2",height:"10",rx:"1",fill:t>=5?s:o}),(0,i.jsx)("rect",{x:"16",width:"2.2",height:"10",rx:"1",fill:t>=6?s:o}),(0,i.jsx)("rect",{x:"19.2",width:"2.2",height:"10",rx:"1",fill:t>=7?s:o}),(0,i.jsx)("rect",{x:"22.4",width:"2.2",height:"10",rx:"1",fill:t>=8?s:o}),(0,i.jsx)("rect",{x:"25.6",width:"2.2",height:"10",rx:"1",fill:t>=9?s:o}),(0,i.jsx)("rect",{x:"28.8",width:"2.2",height:"10",rx:"1",fill:t>=10?s:o})]}),a=({height:e,signal_percent:r,width:t})=>{const{themeName:a}=(0,n.u)(),{strength:x,color:h,inactiveColor:A}=(0,s.useMemo)(()=>({strength:(0,c.O)(r),color:(0,l._i)(r,a),inactiveColor:o.Ay[`desktop-color-neutral-05-${a}`]}),[r,a]);return(0,i.jsx)(d,{height:e,width:t,strength:x,color:h,inactiveColor:A})}},225211(e,r,t){t.d(r,{A:()=>s});var i=t(274934);const s=({strength:e,color:r,inactiveColor:t="currentColor",width:s,height:o})=>(0,i.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 27 26",width:s,height:o,children:(0,i.jsxs)("g",{stroke:"none",strokeWidth:"1",fill:"none",fillRule:"evenodd",children:[(0,i.jsx)("rect",{fill:e>=1?r:t,x:"0",y:"16",width:"3",height:"10"}),(0,i.jsx)("rect",{fill:e>=2?r:t,x:"6",y:"12",width:"3",height:"14"}),(0,i.jsx)("rect",{fill:e>=3?r:t,x:"12",y:"8",width:"3",height:"18"}),(0,i.jsx)("rect",{fill:e>=4?r:t,x:"18",y:"4",width:"3",height:"22"}),(0,i.jsx)("rect",{fill:e>=5?r:t,x:"24",y:"0",width:"3",height:"26"})]})})},931126(e,r,t){t.d(r,{O:()=>s});const i=[[0,1],[2,10],[11,20],[21,30],[31,40],[41,50],[51,60],[61,70],[71,80],[81,90],[91,100]],s=e=>{const r=i.findIndex(([r,t])=>e>=r&&e<=t);return-1===r?0:r}},939940(e,r,t){t.d(r,{_i:()=>A,dx:()=>h});var i=t(814557),s=t(565527),o=t(419151),n=t(931126);const l={[o.OP.NO_SIGNAL]:"neutral-06",[o.OP.POOR]:"red-06",[o.OP.WEAK]:"red-06",[o.OP.FAIR]:"orange-06",[o.OP.GOOD]:"green-06",[o.OP.EXCELLENT]:"green-06"},c="desktop-color-red-06",d="desktop-color-orange-06",a="desktop-color-green-06",x={0:c,1:c,2:c,3:d,4:d,5:d,6:d,7:a,8:a,9:a,10:a},h=(e=o.OP.NO_SIGNAL,r=s.S.LIGHT)=>i.Ay[`desktop-color-${l[e]}-${r}`],A=(e,r=s.S.LIGHT)=>i.Ay[`${(e=>x[(0,n.O)(e)]||"desktop-color-neutral-06")(e)}-${r}`]},376892(e,r,t){t.d(r,{A:()=>n});var i=t(274934),s=t(938984),o=t(470070);const n=({id:e,children:r,values:t})=>(0,i.jsxs)(s.A,{color:"text-1",weight:"bold",size:"medium",children:[e?(0,i.jsx)(o.sA,{id:e,values:t}):null,r]})},275247(e,r,t){t.d(r,{A:()=>c});var i=t(274934),s=t(938984),o=t(320509),n=t(470070),l=t(664092);const c=({rx_rate:e})=>e>0?(0,i.jsxs)(l.A,{children:[(0,i.jsx)(s.A,{color:"text-2",size:"medium",children:(0,i.jsx)(n.sA,{id:"COMMON_RX_RATE"})}),(0,i.jsx)(s.A,{color:"text-3",size:"medium",children:(0,o.Up)(e)})]}):null},206945(e,r,t){t.d(r,{A:()=>c});var i=t(274934),s=t(938984),o=t(320509),n=t(470070),l=t(664092);const c=({tx_rate:e})=>e>0?(0,i.jsxs)(l.A,{children:[(0,i.jsx)(s.A,{color:"text-2",size:"medium",children:(0,i.jsx)(n.sA,{id:"COMMON_TX_RATE"})}),(0,i.jsx)(s.A,{color:"text-3",size:"medium",children:(0,o.Up)(e)})]}):null},920492(e,r,t){t.d(r,{A3:()=>O,Ay:()=>E,KN:()=>_,Rx:()=>v,lo:()=>N});var i=t(274934),s=t(814557),o=t(938984),n=t(247816),l=t(263705),c=t(513458),d=t(669439),a=t(309130),x=t(225211),h=t(527153),A=t(100978),u=t(453007),m=t(939940),j=t(470070),p=t(419151),g=t(567572);const v=31,_=20,w={[p.qU.SUCCESS]:"green06",[p.qU.WARNING]:"orange06",[p.qU.DANGER]:"red06",[p.qU.MISSING]:"neutral06"},C=(0,n.A)("div")`
  position: absolute;
  top: 0;
  left: -${a.YC};
  right: -${a.YC};
  bottom: 0;
  pointer-events: auto;
`,f=({signal:e})=>{const{themeName:r}=(0,l.u)();return(0,i.jsx)(x.A,{width:16,height:16,strength:e,color:(0,m.dx)(e,r),inactiveColor:s.Ay[`desktop-color-neutral-05-${r}`]})},O=({signal_percent:e=0,dBm:r})=>{const{themeName:t}=(0,l.u)();return(0,i.jsxs)(A.A,{gap:a.kc,style:{userSelect:"none"},children:[e>0?(0,i.jsxs)(u.A,{colorOverride:(0,m._i)(e,t),children:[r," ",(0,i.jsx)(j.sA,{id:"COMMON_UNIT_DBM"})]}):(0,i.jsx)(o.A,{color:"text-3",size:"medium",children:(0,i.jsx)(j.sA,{id:"COMMON_NO_SIGNAL"})}),(0,i.jsx)(h.A,{width:v,height:_,signal_percent:e})]})},N=({signal:e,children:r})=>(0,i.jsxs)(A.A,{gap:a.YC,style:{userSelect:"none"},children:[void 0!==e?(0,i.jsx)(f,{signal:e}):null,(0,i.jsx)(o.A,{color:"text-3",size:"medium",children:r})]}),E=({statusCode:e,statusBallTooltip:r,slot:t,title:n,message:x,status:h,esim:u,isCompact:m})=>{const{motifPalette:j,themeName:p}=(0,l.u)();return(0,i.jsx)(i.Fragment,{children:(0,i.jsx)(A.A,{flexDirection:"column",flex:1,height:32,children:(0,i.jsxs)(A.A,{borderBottom:m?void 0:`1px solid ${s.Ay[`desktop-color-neutral-03-${p}`]}`,padding:m?void 0:a.YC,height:m?27:void 0,gap:a.kc,alignItems:"center",children:[(0,i.jsxs)(A.A,{justifyContent:"center",alignItems:"center",position:"relative",pointerEvents:"none",children:[(0,i.jsx)(c.A,{color:j[w[e]]}),r?(0,i.jsx)(d.A,{description:r,placement:"top start",children:(0,i.jsx)(C,{})}):null]}),(0,i.jsx)(A.A,{width:70,children:(0,i.jsx)(o.A,{weight:"bold",size:"medium",children:n||(0,i.jsx)(g.m$,{esim:u,slot:t,weight:m?"regular":"bold"})})}),x?(0,i.jsx)(A.A,{width:m?"auto":150,flex:1,children:x}):null,(0,i.jsx)(A.A,{...x?{width:90}:{flex:1},justifyContent:"flex-end",children:h})]})})})}},293705(e,r,t){t.d(r,{A:()=>A,H:()=>i});var i,s=t(274934),o=t(938984),n=t(442175),l=t(664092),c=t(470070),d=t(262768),a=t(206945),x=t(275247);!function(e){e.ACTIVE="active",e.STANDBY="standby"}(i||(i={}));const h={[i.ACTIVE]:"COMMON_ACTIVE",[i.STANDBY]:"DEVICE_STANDBY"},A=({status:e,networkoperator:r,apn:t,pdp_type:i,rat:A,rx_chan:u,tx_chan:m,iccid:j,rxbytes:p,txbytes:g})=>(0,s.jsxs)(s.Fragment,{children:[e?(0,s.jsxs)(l.A,{children:[(0,s.jsx)(o.A,{color:"text-2",children:(0,s.jsx)(c.sA,{id:"COMMON_STATUS"})}),(0,s.jsx)(o.A,{color:"text-3",children:(0,s.jsx)(c.sA,{id:h[e]})})]}):null,r&&"NULL"!==r?(0,s.jsxs)(l.A,{children:[(0,s.jsx)(o.A,{color:"text-2",children:(0,s.jsx)(c.sA,{id:"COMMON_CARRIER"})}),(0,s.jsx)(o.A,{color:"text-3",children:r})]}):null,t?(0,s.jsxs)(l.A,{children:[(0,s.jsx)(o.A,{color:"text-2",children:(0,s.jsx)(c.sA,{id:"DEVICE_PROPERTIES_UNIFI_LTE_APN"})}),(0,s.jsx)(o.A,{color:"text-3",children:t})]}):null,i?(0,s.jsxs)(l.A,{children:[(0,s.jsx)(o.A,{color:"text-2",children:(0,s.jsx)(c.sA,{id:"DEVICE_CONNECTION_TYPE"})}),(0,s.jsx)(o.A,{color:"text-3",children:i})]}):null,(0,d.mR)(A)?(0,s.jsxs)(l.A,{children:[(0,s.jsx)(o.A,{color:"text-2",children:(0,s.jsx)(c.sA,{id:"COMMON_NETWORK_TYPE"})}),(0,s.jsx)(o.A,{color:"text-3",children:A})]}):null,void 0!==u?(0,s.jsx)(x.A,{rx_rate:u}):null,void 0!==m?(0,s.jsx)(a.A,{tx_rate:m}):null,void 0!==p?(0,s.jsxs)(l.A,{children:[(0,s.jsx)(o.A,{color:"text-2",children:(0,s.jsx)(c.sA,{id:"COMMON_RX_BYTES"})}),(0,s.jsx)(o.A,{color:"text-3",children:(0,n.FI)(p)})]}):null,void 0!==g?(0,s.jsxs)(l.A,{children:[(0,s.jsx)(o.A,{color:"text-2",children:(0,s.jsx)(c.sA,{id:"COMMON_TX_BYTES"})}),(0,s.jsx)(o.A,{color:"text-3",children:(0,n.FI)(g)})]}):null,j?(0,s.jsxs)(l.A,{children:[(0,s.jsx)(o.A,{color:"text-2",children:(0,s.jsx)(c.sA,{id:"DEVICE_PROPERTIES_UNIFI_LTE_ICCID"})}),(0,s.jsx)(o.A,{color:"text-3",children:j})]}):null]})},303008(e,r,t){t.d(r,{A:()=>c});var i=t(274934),s=t(938984),o=t(470070),n=t(45216),l=t(664092);const c=({imei:e})=>(0,i.jsxs)(l.A,{flexProps:{height:"auto"},children:[(0,i.jsx)(s.A,{color:"text-2",size:"medium",children:(0,i.jsx)(o.sA,{id:"DEVICE_IMEI"})}),(0,i.jsx)(n.A,{maxWidth:141,value:e})]})},254193(e,r,t){t.d(r,{A:()=>c});var i=t(274934),s=t(602086),o=t(954702),n=t(688684),l=t(316628);const c=({value:e})=>{const r=(0,l.A)(),t=(0,s.useCallback)(()=>r(e),[e,r]);return(0,i.jsx)(o.A,{onPress:t,variant:"neutral",children:(0,i.jsx)(n.A,{size:"original"})})}},643334(e,r,t){t.d(r,{A:()=>ee});var i=t(274934),s=t(602086),o=t(938984),n=t(954702),l=t(167953),c=t(409844),d=t(263705),a=t(977872),x=t(814557),h=t(87449),A=t(470070),u=t(100978),m=t(309130),j=t(968021),p=t(29472),g=t(430986);const v=`${t(290454).w}/device/{mac}/fw-revert-options`,_=(e,r={},t={})=>(0,p.Kd)("firmwareRevertOptions",(0,g.P)(v,{mac:e}),e,r,{idField:"mac",...t});var w=t(222102),C=t(656466),f=t(401042);var O=t(45978),N=t(724081),E=t(260610),I=t(642687),b=t(247816),M=t(669439),T=(t(232087),t(129402)),R=t(347625),y=t(807811),S=t(224012),k=t(743178),$=t(591256),U=t(594633),D=t(976458),z=t(696916),L=t(795206),P=t(898809),V=t(146215),G=t(930071);const Y=(0,b.A)(G.A)`
  border-radius: 50%;
  padding: 1px;
  border: ${({theme:{themeName:e}})=>x.Ay[`desktop-border-divider-${e}`]};
  color: ${({theme:{themeName:e}})=>x.Ay[`desktop-color-neutral-08-${e}`]};
`,B=({model:e,version:r})=>{const t=(0,a.d4)(D.qf),o=(0,h.coerce)(r)?.version||r,n=(0,s.useCallback)(()=>{o&&t?.(e,o)},[t,e,o]);return(0,i.jsx)(M.A,{description:(0,i.jsx)(A.sA,{id:"COMMON_RELEASE_NOTES"}),children:(0,i.jsx)("span",{children:(0,i.jsx)(Y,{actionable:!0,onClick:n,size:"original"})})})},F=()=>{const{themeName:e}=(0,d.u)();return(0,i.jsx)("svg",{viewBox:"0 0 93 8",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,i.jsx)("path",{d:"M92.3536 4.03715C92.5488 3.84189 92.5488 3.5253 92.3536 3.33004L89.1716 0.14806C88.9763 -0.0472023 88.6597 -0.0472023 88.4645 0.14806C88.2692 0.343322 88.2692 0.659904 88.4645 0.855167L91.2929 3.68359L88.4645 6.51202C88.2692 6.70728 88.2692 7.02387 88.4645 7.21913C88.6597 7.41439 88.9763 7.41439 89.1716 7.21913L92.3536 4.03715ZM0 3.68359V4.18359H92V3.68359V3.18359H0V3.68359Z",fill:x.Ay[`desktop-color-purple-06-${e}`]})})},q=(0,b.A)(u.A)`
  padding: ${m.xO};
  border: ${({theme:{themeName:e}})=>x.Ay[`desktop-border-divider-${e}`]};
  border-radius: 8px;
  margin-bottom: ${m.kc};
`,H=(0,b.A)(u.A)`
  width: 20px;
  height: 20px;
  border-radius: 4px;
  background-color: ${({theme:{themeName:e}})=>x.Ay[`desktop-color-purple-06-${e}`]};
  z-index: 1;
`,W=(0,b.A)(u.A)`
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 1px;
  align-items: center;
`,K=(0,b.A)(u.A)`
  background-color: ${({theme:{themeName:e}})=>x.Ay[`desktop-color-neutral-02-${e}`]};
  border-radius: 4px;

  textarea {
    background-color: transparent;
    resize: none;
  }
`,X=({onCancel:e,onSubmitSuccess:r,name:t,model:n,mac:j,displayable_version:p,uptime:g,revertOptions:v})=>{const _=(0,a.wA)(),{themeName:w}=(0,d.u)(),{formatMessage:C}=(0,A.tz)(),[f,O]=(0,s.useState)(""),N=(0,a.d4)($.Eh),b=(0,a.d4)(U.S$),G=(0,k.GO)(b),Y=(0,a.d4)(D.ap),X=(0,a.d4)(D.YL),Z=(0,z.A)("firmware_downgrade_feedback"),J=(0,R.Lm)(n),Q=(0,h.coerce)(p)?.version,ee=(0,h.coerce)(v.previous_firmware_version)?.version,re=(0,s.useCallback)(async(e,r)=>{const t=await Z(),i=`${y.DU}${S.Fx[G]}/v1/firmware-downgrade`;try{await fetch(i,{method:"POST",headers:{"Content-Type":"application/json","X-Captcha":t},mode:"cors",body:JSON.stringify({message:e,applicationName:"Network",applicationVersion:N,deviceModel:J,deviceFirmwareCurrentVersion:(0,T._)(p),deviceFirmwareNewVersion:r,anonymousId:Y})})}catch(e){}},[Z,G,N,p,Y,J]),te=(0,s.useCallback)(()=>{if(_((0,L._1)({name:t,model:n,mac:j},v.previous_firmware_url)),X)return r();f&&re(f,v.previous_firmware_version),r()},[_,t,n,j,v.previous_firmware_url,v.previous_firmware_version,X,f,r,re]);return(0,i.jsxs)(q,{flexDirection:"column",gap:m.Ln,children:[(0,i.jsxs)(u.A,{gap:m.kc,width:"100%",children:[(0,i.jsxs)(u.A,{flexDirection:"column",alignItems:"center",width:"110px",flex:"0 0 110px",children:[(0,i.jsxs)(o.A,{color:"text-3",size:"small",children:[(0,i.jsx)(A.sA,{id:"COMMON_CURRENT_VERSION"}),":"]}),(0,i.jsxs)(u.A,{gap:m.YC,children:[(0,i.jsx)(M.A,{description:(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(A.sA,{id:"DEVICE_TIME_RUNNING"}),": ",(0,P.Ay)(g).join("").trim()]}),children:(0,i.jsx)(o.A,{color:"text-2",size:"medium",children:Q})}),(0,i.jsx)(B,{model:n,version:p})]})]}),(0,i.jsxs)(u.A,{flex:1,alignItems:"center",justifyContent:"center",position:"relative",children:[(0,i.jsx)(W,{children:(0,i.jsx)(F,{})}),(0,i.jsx)(H,{children:(0,i.jsx)(l.A,{size:"original",variant:"twoTone",color:"white",twoTonedClassname:c.AH`
                fill: ${x.Ay[`desktop-color-purple-06-${w}`]};
              `})})]}),(0,i.jsxs)(u.A,{flexDirection:"column",alignItems:"center",width:"110px",flex:"0 0 110px",children:[(0,i.jsxs)(o.A,{color:"text-3",size:"small",children:[(0,i.jsx)(A.sA,{id:"COMMON_REVERT_TO"}),":"]}),(0,i.jsxs)(u.A,{gap:m.YC,children:[(0,i.jsx)(o.A,{color:"text-2",size:"medium",children:ee}),(0,i.jsx)(B,{model:n,version:ee||""})]})]})]}),X?null:(0,i.jsx)(K,{flexDirection:"column",gap:m.YC,children:(0,i.jsx)(E.A,{resize:!1,style:{width:"100%"},placeholder:C({id:"COMMON_HELP_UNIFI_UNDERSTAND_REVERT_DESCRIPTION"}),value:f,onChange:e=>{O(e)}})}),(0,i.jsxs)(u.A,{gap:m.YC,width:"100%",children:[(0,i.jsx)(V.A,{title:(0,i.jsx)(A.sA,{id:"DEVICE_REVERT_NOW_CONFIRM_TITLE",values:{model:J}}),message:(0,i.jsx)(A.sA,{id:"DEVICE_REVERT_NOW_CONFIRM_MESSAGE",values:{model:J,version:ee||""}}),confirmButtonVariant:"emphasis",onConfirm:te,trigger:(0,i.jsx)(I.A,{size:"small",children:(0,i.jsx)(A.sA,{id:"COMMON_ACTION_REVERT_NOW"})})}),(0,i.jsx)(I.A,{size:"small",variant:"neutral",onClick:e,children:(0,i.jsx)(A.sA,{id:"COMMON_ACTION_CANCEL"})})]})]})};var Z=t(664092),J=t(857780);const Q=[J.bq.USW,J.bq.UAP,J.bq.UDB,J.bq.UBB,J.bq.UXG,J.bq.UBLE,J.bq.UAV,J.bq.UCI,J.bq.UACC],ee=({name:e,model:r,mac:t,displayable_version:p,uptime:g,type:v,flexProps:E,deviceState:I})=>{const b=(0,a.wA)(),[M,T]=(0,s.useState)(!1),{themeName:R}=(0,d.u)(),y=(0,a.d4)((0,s.useMemo)(()=>(e=>(0,w.Mz)((e=>(0,C.uh)(_(e)))(e),f.i6))(t),[t])),S=(0,j.A)(I);(0,s.useEffect)(()=>{S===O.g.UPGRADING&&I!==O.g.UPGRADING&&b(_(t))},[I,S,b,t]);const k=(0,s.useMemo)(()=>{const e=y.previous_firmware_version&&y.previous_firmware_url,r=p!==(0,h.coerce)(y.previous_firmware_version)?.version,t=I===O.g.UPGRADING;return Boolean(e)&&!t&&r&&Q.includes(v)},[y.previous_firmware_version,y.previous_firmware_url,p,I,v]),$=(0,N.A)(Q.includes(v)?[_(t,{},void 0)]:[],k?(0,i.jsxs)(n.A,{onPress:()=>{T(!0)},fontSize:"medium",children:[(0,i.jsx)(l.A,{size:"original",variant:"twoTone",color:x.Ay[`desktop-color-ublue-06-${R}`],twoTonedClassname:c.AH`
            fill: ${x.Ay[`desktop-color-ublue-01-${R}`]};
          `}),(0,i.jsx)(A.sA,{id:"COMMON_REVERT"})]}):null);return(0,i.jsxs)(i.Fragment,{children:[p?(0,i.jsxs)(Z.A,{flexProps:E,children:[(0,i.jsx)(o.A,{color:"text-2",size:"medium",children:(0,i.jsx)(A.sA,{id:"COMMON_DEVICE_VERSION"})}),(0,i.jsxs)(u.A,{gap:m.kc,alignItems:"flex-start",children:[(0,i.jsx)(o.A,{color:"text-3",size:"medium",children:p}),$]})]}):null,M?(0,i.jsx)(X,{onCancel:()=>{T(!1)},onSubmitSuccess:()=>{T(!1)},name:e,model:r,mac:t,displayable_version:p,uptime:g,revertOptions:y}):null]})}},968021(e,r,t){t.d(r,{A:()=>s});var i=t(602086);const s=e=>{const r=(0,i.useRef)(void 0);return(0,i.useEffect)(()=>{r.current=e},[e]),r.current}},696916(e,r,t){t.d(r,{A:()=>d});var i=t(602086),s=t(977872),o=t(232087),n=t(594633),l=t(743178);const c={[o.OH.PRD]:"6Ld47OUpAAAAALQ4AgR1gfk-hnSw27y3zIMKLOSw",[o.OH.STG]:"6LeKc-UpAAAAAN6YqRab29cPCbU-cfe7_EvchSvc",[o.OH.DEV]:"6LeocOUpAAAAANmIju4N9DzlkK4UNYdYThrUkK3y"},d=e=>{const[r,t]=(0,i.useState)(),o=(0,i.useRef)(void 0),d=(0,s.d4)(n.S$),a=(0,l.GO)(d);return(0,i.useEffect)(()=>{const r=()=>{const{grecaptcha:i}=window;i?.enterprise.ready(()=>t(()=>()=>i.enterprise.execute(c[a],{action:e}))),o.current?.removeEventListener("load",r)};return"grecaptcha"in window?r():(o.current=document.createElement("script"),o.current.src=(e=>`https://www.google.com/recaptcha/enterprise.js?render=${c[e]}`)(a),o.current.addEventListener("load",r),document.body.appendChild(o.current),(()=>{const e="hide-grecaptcha-badge";if(document.getElementById(e))return;const r=document.createElement("style");r.id=e,r.innerText=".grecaptcha-badge { visibility: hidden; }",document.head.appendChild(r)})()),()=>{o.current?.removeEventListener("load",r)}},[]),r}}}]);