"use strict";(self.webpackChunkunifiNetworkUi=self.webpackChunkunifiNetworkUi||[]).push([[41360],{32753:(e,t,n)=>{n.d(t,{A:()=>o});var r=n(296540),a=n(927099),l=n(699784),i=n(780811),c=n(360113);const o=({systemStatsMem:e,compact:t=!1})=>{const n=(0,i.HBQ)(e);return n?r.createElement(c.A,{compact:t},r.createElement(a.A,{color:"secondary",size:"body"},r.createElement(l.sA,{id:"DEVICE_PROPERTY_OVERVIEW_MEMORY_USAGE"})),r.createElement(a.A,{color:"tertiary",size:"body"},n,"%")):null}},46119:(e,t,n)=>{n.d(t,{A:()=>r});const r={open:(e,t="_blank",n="noopener,noreferrer")=>window.open(e,t,n)}},128195:(e,t,n)=>{n.d(t,{A:()=>A});var r=n(296540),a=n(178233),l=n(294303),i=n(678515),c=n(699784),o=n(170459),E=n(321235);const s=({activeItem:{radio_table:e,radio_table_stats:t,type:n,model:s,vap_table:A,stat:d},radioType:m,radioName:_,hideChUtil:u=!1,hideRadio:M=!1})=>{const{formatMessage:I}=(0,c.tz)(),{radio:C,radioStats:O}=(0,r.useMemo)(()=>({radio:e?.find(({radio:e,name:t})=>e===m&&(!_||t===_)),radioStats:t?.find(({radio:e})=>e===m)}),[e,t,_,m]),{channelUtilization:P,transmitPower:T}=(0,r.useMemo)(()=>({channelUtilization:(0,o.Lm)(t,O),transmitPower:(0,o.ZJ)(t,O,I)}),[t,O,I]),{totalPacketsRx:N,totalBytesRx:p,droppedPercentageRx:R,retryPercentageRx:D,totalPacketsTx:L,totalBytesTx:y,droppedPercentageTx:f,retryPercentageTx:x}=(0,r.useMemo)(()=>(({totalPackets:e,totalBytes:t,droppedPercentage:n,retryPercentage:r},{totalPackets:a,totalBytes:l,droppedPercentage:i,retryPercentage:c})=>({totalPacketsRx:e,totalBytesRx:t,droppedPercentageRx:n,retryPercentageRx:r,totalPacketsTx:a,totalBytesTx:l,droppedPercentageTx:i,retryPercentageTx:c}))((0,o.GI)(n,C,"rx",d),(0,o.GI)(n,C,"tx",d)),[n,C,d]);return r.createElement(l.A,{flexDirection:"column"},M?null:r.createElement(E.A,{id:"COMMON_CHANNEL"},C?r.createElement(i.A,{radio_table:e,radio_table_stats:t,model:s,vap_table:A,radio:C,hidePowerInfo:!0,textSize:"body",textColor:"tertiary"}):r.createElement(c.sA,{id:"COMMON_FALLBACK"})),r.createElement(E.A,{id:"DEVICE_PROPERTIES_LABEL_TX_EIRP"},T||r.createElement(c.sA,{id:"COMMON_FALLBACK"})),r.createElement(E.A,{id:"DEVICE_PROPERTIES_LABEL_TX_PKTS_BYTES"},L??r.createElement(c.sA,{id:"COMMON_FALLBACK"})," /"," ",y??r.createElement(c.sA,{id:"COMMON_FALLBACK"})),r.createElement(E.A,{id:"DEVICE_PROPERTIES_LABEL_RX_PKTS_BYTES"},N??r.createElement(c.sA,{id:"COMMON_FALLBACK"})," /"," ",p??r.createElement(c.sA,{id:"COMMON_FALLBACK"})),r.createElement(E.A,{id:"DEVICE_PROPERTIES_LABEL_TX_RETRY_DROPPED"},(0,a.l)(x)," / ",(0,a.l)(f)),r.createElement(E.A,{id:"DEVICE_PROPERTIES_LABEL_RX_RETRY_DROPPED"},(0,a.l)(D)," / ",(0,a.l)(R)),!u&&P?r.createElement(E.A,{id:"DEVICE_PROPERTIES_LABEL_CHANNEL_UTILIZATION"},`${P.total}% / ${P.selfRx}% / ${P.selfTx}%`):null)},A=({activeItem:e,...t})=>e?.radio_table?.length?r.createElement(s,{activeItem:e,...t}):null},144367:(e,t,n)=>{n.d(t,{A:()=>m});var r=n(296540),a=n(777916),l=n(217439),i=n(83438),c=n(137298),o=n(566723),E=n(294303),s=n(699784),A=n(780811),d=n(360113);const m=({capacity:e,activeItem:t,withTooltip:n=!1})=>{const m=e??t?.link_capacity??((0,A.YdF)(t)&&t?.peer_ubb?.link_capacity),_=m&&m>0?r.createElement(a.A,{size:"body",type:"bytes",color:"tertiary",input:(0,c.N8)(m),options:"bitrate"}):null;return _?r.createElement(d.A,null,r.createElement(l.A,{color:"text-2",size:"medium"},r.createElement(s.sA,{id:"DEVICE_PROPERTY_OVERVIEW_LINK_CAPACITY"})),n?r.createElement(E.A,{alignItems:"center",gap:o.YC},_,r.createElement(i.A,{description:r.createElement(s.sA,{id:"DEVICE_PROPERTY_OVERVIEW_CAPACITY_TOOLTIP"}),placement:"top left"})):_):null}},258117:(e,t,n)=>{n.d(t,{A:()=>m});var r=n(296540),a=n(325898),l=n(927099),i=n(71479),c=n(903216),o=n(294303),E=n(699784),s=n(360113),A=n(863489);const d=(0,i.A)(o.A)`
  .tooltip-position-fixer {
    margin-right: -14px;
  }
`,m=({uplink:e,portSpeed:t})=>{const n=Number(t||e?.speed),{motif:i}=(0,a.A)();return n>0?r.createElement(s.A,null,r.createElement(l.A,{color:"secondary",size:"body"},r.createElement(E.sA,{id:"COMMON_EXPERIENCE"})),r.createElement(d,{alignItems:"center"},r.createElement(l.A,{style:{color:(0,A.xe)(n,i,!1)},size:"body"},(0,c.ir)(n)))):null}},321235:(e,t,n)=>{n.d(t,{A:()=>s});var r=n(296540),a=n(217439),l=n(705145),i=n(71479),c=n(699784),o=n(360113);const E=(0,i.A)(a.A)`
  white-space: nowrap;
`,s=({id:e,color:t,values:n,children:a})=>r.createElement(o.A,null,r.createElement(E,{color:"text-2",size:"medium"},r.createElement(c.sA,{id:e,values:n})),r.createElement(l.A,{color:t||"text-3",size:"medium",isTruncated:!0},a))},328787:(e,t,n)=>{n.d(t,{A:()=>d});var r=n(469733),a=n(296540),l=n(149133),i=n(855019),c=n(551753),o=n(699784),E=n(532419),s=n(765562);const A=({adopted:e})=>a.createElement(c.A,{link:s.A.virtualNetworkConnectivity},a.createElement(o.sA,{id:e?"DEVICE_FALLBACK_IP_ADOPTED_WITH_UNIFI_GATEWAY_WARNING":"DEVICE_FALLBACK_IP_NOT_ADOPTED_WARNING",values:{bold:a.createElement("strong",null,a.createElement(o.sA,{id:e?"DEVICE_WARNING_FALLBACK_IP":"DEVICE_WARNING_ADOPTION_FAILED"}))}})),d=({ip:e,adopted:t,config_network:n})=>(0,r.useSelector)(E.m9)&&(0,l.W5)(e)&&n?.type===i.NL.DHCP?a.createElement(A,{adopted:t}):null},551753:(e,t,n)=>{n.d(t,{A:()=>_});var r=n(296540),a=n(758649),l=n(217439),i=n(162420),c=n(823858),o=n(793336),E=n(998837),s=n(46119),A=n(699784),d=n(224948),m=n(294303);const _=(0,r.memo)(({children:e,customIcon:t,link:n,nested:_,extra:u,variant:M="warning",...I})=>{const{motifPalette:{warning:C,danger:O}}=(0,E.u)(),P=(0,r.useMemo)(()=>{switch(M){case"warning":return r.createElement(c.A,{size:"original",color:C,variant:"fill"});case"info":return r.createElement(i.A,{isActive:!0,size:"original",variant:"fill"});case"custom":return t;default:return r.createElement(o.A,{size:"medium",color:O,variant:"fill"})}},[M,C,O,t]),T=(0,r.useCallback)(()=>{s.A.open(n)},[n]);return r.createElement(d.A,{icon:P,nested:_,...I},r.createElement(m.A,{flexDirection:"column",alignItems:"flex-start"},r.createElement(l.A,null,e),r.createElement(l.A,null,n?r.createElement(a.A,{type:"button",variant:"inline",onClick:T},r.createElement(A.sA,{id:"COMMON_LEARN_MORE"})):null),u))})},772317:(e,t,n)=>{n.d(t,{A:()=>D});var r,a=n(592563),l=n(296540),i=n(469733),c=n(217439),o=n(187483),E=n(699784),s=n(689965),A=n(86571),d=n(801081);!function(e){e.OPEN_MODAL="openModal"}(r||(r={}));const m=(0,d.Mz)(o.zn,e=>void 0!==e[r.OPEN_MODAL]);var _=n(523275),u=n(840279),M=n(919952);const I=e=>e[M.U.UIDB]||(0,_.A)(),C=(0,d.Mz)(I,({version:e})=>Boolean(e)),O=(0,d.Mz)(I,({devices:e})=>e||(0,u.A)());var P=n(765562),T=n(79871);const N=()=>{const e=(0,i.useDispatch)(),t=(0,i.useSelector)(C);return(0,l.useEffect)(()=>{t||(async()=>{const t=await fetch(P.A.fingerprintPublicDatabasePath),n=await t.json();e((0,T.$)(n))})()},[t,e]),t},p=({uidbDevice:e})=>{const t=(0,i.useSelector)(o.zn),n=t?.[r.OPEN_MODAL];return n?l.createElement(a.A,{onClick:()=>n(e)},l.createElement(c.A,{size:"medium",color:"inherit"},l.createElement(E.sA,{id:"DEVICE_SHOW_DETAILS"}))):null},R=({shortname:e})=>{const t=(0,i.useSelector)((e=>(0,d.Mz)(O,t=>t.find(t=>t.shortnames?.includes(e))||(0,_.A)()))(e));return N(),t?.compliance?l.createElement(s.A,{type:s.I.ACCORDION,items:[{id:"compliance",label:l.createElement(A.A,{id:"COMMON_COMPLIANCE"}),renderContent:()=>l.createElement(p,{uidbDevice:t}),openByDefault:!0}]}):null},D=({shortname:e})=>(0,i.useSelector)(m)?l.createElement(R,{shortname:e}):null},806720:(e,t,n)=>{n.d(t,{A:()=>I});var r,a=n(469733),l=n(296540),i=n(927099),c=n(699784),o=n(213583);!function(e){e.MM="mm",e.CM="cm",e.M="m",e.KM="km",e.MI="mi",e.FT="ft"}(r||(r={}));const E={[r.MM]:"COMMON_UNIT_DISTANCE_MM",[r.CM]:"COMMON_UNIT_DISTANCE_CM",[r.M]:"COMMON_UNIT_DISTANCE_M",[r.KM]:"COMMON_UNIT_DISTANCE_KM",[r.MI]:"COMMON_UNIT_DISTANCE_MI",[r.FT]:"COMMON_UNIT_DISTANCE_FT"},s=[o.A.US.numericCode,o.A.GB.numericCode,o.A.CA.numericCode,o.A.LR.numericCode,o.A.MM.numericCode],A=(e,t)=>l.createElement(l.Fragment,null,`${e} `,l.createElement(c.sA,{id:E[t]})),d=(e,t,n,a)=>{if((e=>s.includes(e))(e)){if(t.includes(r.FT)&&a<1610)return A((3.2808399*a).toFixed(n),r.FT);if(t.includes(r.MI))return A((.000621371192*a).toFixed(n),r.MI)}else{if(t.includes(r.MM)&&a<.01)return A((1e3*a).toFixed(n),r.MM);if(t.includes(r.CM)&&a<1)return A((100*a).toFixed(n),r.CM);if(t.includes(r.M)&&a<1e3)return A(a.toFixed(n),r.M);if(t.includes(r.KM))return A((a/1e3).toFixed(n),r.KM)}return l.createElement(l.Fragment,null,`${a}`)},m=(e,t,n=0,a=[r.MM,r.CM,r.M,r.KM,r.MI,r.FT])=>d(e,a,n,t);var _=n(302167),u=n(780811),M=n(360113);const I=({distance:e,activeItem:t})=>{const n=(0,a.useSelector)(_.ZZ),r=e??t?.distance??((0,u.YdF)(t)&&t?.peer_ubb?.distance);return r?l.createElement(M.A,null,l.createElement(i.A,{color:"secondary",size:"body"},l.createElement(c.sA,{id:"DEVICE_PROPERTY_OVERVIEW_LINK_DISTANCE"})),l.createElement(i.A,{color:"tertiary",size:"body"},m(n,r))):null}}}]);