"use strict";(self.webpackChunkunifiNetworkUi=self.webpackChunkunifiNetworkUi||[]).push([[95065],{285947(e,t,n){n.d(t,{EA:()=>s,G6:()=>E,Km:()=>a,ME:()=>r,Nq:()=>A,Sl:()=>u,Up:()=>m,bc:()=>d,ne:()=>o,pE:()=>i,t1:()=>c});var l=n(294591);const c=({security:e})=>e===l.Hs.WEP,r=({security:e})=>e===l.Hs.WPA_ENTERPRISE,i=({security:e})=>e===l.Hs.WPA_PERSONAL,a=({wpa_enc:e})=>e===l.Jl.AUTO,o=({security:e})=>e===l.Hs.HOTSPOT_2_OSEN,s=({mac_filter_enabled:e})=>e,m=(e,t)=>e&&[...new Set(e.filter(({is_guest:e})=>t?!!e:!e).map(({name:e})=>e))],E=e=>{switch(e){case l.Tl.PAP:case l.Tl.CHAP:case l.Tl.MSCHAP:case l.Tl.MSCHAP_V2:return 2;case l.Tl.SIM:case l.Tl.USIM:case l.Tl.CERTIFICATE:case l.Tl.USERNAME_PASSWORD:return 5;default:return}},u=e=>{switch(e){case l.Tl.PAP:case l.Tl.SIM:return 1;case l.Tl.CHAP:case l.Tl.USIM:return 2;case l.Tl.MSCHAP:return 3;case l.Tl.MSCHAP_V2:return 4;case l.Tl.CERTIFICATE:return 6;case l.Tl.USERNAME_PASSWORD:return 7;default:return}},d=e=>{const t=`${e.auth_id}:${e.auth_val}`;if(Object.values(l.Tl).includes(t))return t};function A(e){return Object.values(l.Ir).includes(e?.attr_hidden_id)}},35627(e,t,n){n.d(t,{B:()=>o,T:()=>m});var l=n(801081),c=n(25553),r=n(87485),i=n(248951);const a=(0,c.uh)((0,i.P)()),o=(0,l.Mz)(a,r.kh),s=(0,c.uh)((0,i.L)()),m=(0,l.Mz)(s,r.kh)},175522(e,t,n){n.d(t,{A:()=>c,Q:()=>r});var l=n(416348);const c="_",r=[l.ZM,l.Je]},470962(e,t,n){n.d(t,{A:()=>A});var l=n(822336),c=n(296540),r=n(217439),i=n(823858),a=n(382389),o=n(566723),s=n(224948),m=n(349107),E=n(294303),u=n(916537),d=n(765562);const A=(0,c.memo)(({children:e})=>{const{themeName:t}=(0,a.u)();return c.createElement(s.A,{icon:c.createElement(i.A,{size:"original",color:l.Ay[`desktop-color-orange-06-${t}`],variant:"fill"})},c.createElement(E.A,{flexDirection:"column",gap:o.kc},c.createElement(r.A,{size:"medium",color:"text-2"},c.createElement(u.sA,{id:"COMMON_DEVICE_OFFLINE_WARNING",values:{b:u.b,link:c.createElement(m.A,{href:d.A.offlineArticle,id:"COMMON_LEARN_MORE",noWrap:!0})}})),e))})},723544(e,t,n){n.d(t,{A:()=>a});var l=n(296540),c=n(217439),r=n(916537),i=n(360113);const a=({mac:e,compact:t=!1})=>e?l.createElement(i.A,{compact:t},l.createElement(c.A,{color:"text-2",size:"medium"},l.createElement(r.sA,{id:"COMMON_MAC_ADDRESS"})),l.createElement(c.A,{color:"text-3",size:"medium"},e)):null},780492(e,t,n){n.d(t,{A:()=>d});var l=n(296540),c=n(271856),r=n(217439),i=n(71479),a=n(294303),o=n(916537),s=n(360113),m=n(311785);const E=(0,i.A)(c.A,(0,m.A)("itemCount"))`
  > div {
    height: ${({itemCount:e})=>`calc(24px + ${14*e}px)`};
    padding: 8px 0 8px 8px;
    max-height: 108px;
  }
`,u=(0,i.A)(a.A)`
  height: 100%;
  overflow-y: scroll;
  overflow-x: hidden;
  &::-webkit-scrollbar-thumb {
    background-color: ${({theme:{motifPalette:{ui11:e}}})=>e};
  }
`,d=({wifiNetworkNames:e})=>e.length?l.createElement(s.A,null,l.createElement(r.A,{color:"text-2",size:"medium"},l.createElement(o.sA,{id:"COMMON_WIFI_NETWORK"})),l.createElement(r.A,{color:"text-3",size:"medium"},e.length>1?l.createElement(E,{itemCount:e.length,description:l.createElement(u,{flexDirection:"column"},e.map(e=>l.createElement(r.A,{key:e},e))),position:"top",width:146,isInteractive:!0},l.createElement(o.sA,{id:"DEVICE_PROPERTY_OVERVIEW_WIFI_NETWORK_COUNT",values:{count:e.length}})):e[0])):null},124092(e,t,n){n.d(t,{A:()=>v});var l=n(469733),c=n(296540),r=n(962926),i=n(705145),a=n(71479),o=n(132196),s=n(6510),m=n(130851),E=n(566723),u=n(294303),d=n(6176);const A=o.AH`
  margin-bottom: ${E.Ln};
  margin-top: ${E.Ln};
`,p=(0,a.A)("div")`
  align-self: center;
  overflow: hidden;
  word-break: break-word;
`,_=(0,a.A)("img")`
  width: 40px;
  height: 40px;
  object-fit: contain;
`,v=({children:e,description:t,meshingDescription:n,isOffline:a,activeItem:v,style:I,className:g,isStacking:N,badge:C})=>{const h=(0,l.useSelector)(m.p);return c.createElement(r.A,{className:(0,o.cx)(A,g),sections:[c.createElement("div",null,c.createElement(u.A,{gap:E.kc},N?c.createElement(_,{src:`${h}/topology/stacking.png`,alt:"stacked"}):c.createElement(d.A,{model:v.model,width:40,height:40}),c.createElement(p,{style:I},c.createElement(i.A,{color:a?"text-3":"text-1",weight:"bold",isTruncated:!0},(0,s.Lm)(v.model),C),t)),n,e)]})}},812454(e,t,n){n.d(t,{A:()=>$});var l=n(296540),c=n(71479),r=n(566723),i=n(218234),a=n(294303),o=n(217439),s=n(382389),m=n(842630),E=n(224948),u=n(916537),d=n(469733),A=n(824182),p=n(264963),_=n(822336),v=n(705145);const I=(0,c.A)(a.A)`
  flex-direction: column;
  margin-top: ${r.kc};
  padding-top: ${r.kc};
  border-top: ${({theme:{themeName:e}})=>_.Ay[`desktop-border-divider-${e}`]};
`,g=(0,c.A)(a.A)`
  width: 100%;
  justify-content: space-between;
`,N=(0,c.A)(a.A)`
  gap: ${r.Ln};
  align-items: center;
`,C=(0,c.A)(v.A)`
  max-width: 150px;
`,h=(0,l.memo)(({mac:e,replacementMac:t})=>{const n=(0,d.useDispatch)(),[c,r]=(0,l.useState)(!1),i=(0,l.useCallback)(()=>{r(!0),n((0,p.X2)(e)).finally(()=>{r(!1)})},[n,e]);return l.createElement(I,null,l.createElement(g,null,l.createElement(C,{isTruncated:!0,size:"medium",color:"text-2"},l.createElement(u.sA,{id:"DEVICE_REPLACEMENT_DEVICE"})),l.createElement(N,null,l.createElement(o.A,{size:"medium",color:"text-3"},t),l.createElement(A.A,{actionable:!0,onClick:i,disabled:c}))))}),T=(0,c.A)(a.A)`
  flex-direction: column;
  gap: ${r.kc};
`;var f=n(709690),P=n(823858),b=n(768195);const M=({state:e},{uBlue06:t,orange06:n})=>e===b.gQ.WAITING_FOR_REPLACEMENT?l.createElement(f.A,{size:"original",color:t,variant:"fill"}):l.createElement(P.A,{size:"original",color:n,variant:"fill"}),S=({state:e})=>{switch(e){case b.gQ.WAITING_FOR_REPLACEMENT:return"DEVICE_REPLACEMENT_PENDING_WAITING_FOR_REPLACEMENT";case b.gQ.WAITING_FOR_REPLACED_DEVICE_DISCONNECT:return"DEVICE_REPLACEMENT_PENDING_WAITING_FOR_REPLACED_DEVICE_DISCONNECT";case b.gQ.INCOMPATIBLE_REPLACEMENT:return"DEVICE_REPLACEMENT_PENDING_INCOMPATIBLE_REPLACEMENT";default:return"DEVICE_REPLACEMENT_PENDING_CANNOT_REPLACE"}},O=(0,l.memo)(({mac:e,replacement:t})=>{const{motifPalette:n}=(0,s.u)();return t?.device_mac?l.createElement(m.A,null,l.createElement(E.A,{icon:M(t,n)},l.createElement(T,null,l.createElement(o.A,{size:"medium",color:"text-2"},l.createElement(u.sA,{id:S(t),values:{b:u.b}}))),l.createElement(h,{mac:e,replacementMac:t.device_mac}))):null});var R=n(211908),k=n(129361),D=n(470962),w=n(281884),x=n(451632),y=n(392699),L=n(124092),z=n(236037),F=n(683086);const W=(0,c.A)(a.A)`
  & > :first-child {
    margin-top: ${r.kc};
  }
`,$=({activeItem:e,activeItem:{deviceState:t,uplink:n,mac:c,model:a,type:o,replacement:s},showPortOverview:m,hidePortsButton:E,isStacking:u,multipleDisplayedDevicesData:d,overviewChildren:A,children:p,badge:_})=>{const v=(0,l.useMemo)(()=>(0,w.H)(t,n?.type),[t,n?.type]),I=Boolean(e?.port_table?.length),g=m&&I;return l.createElement(l.Fragment,null,l.createElement(L.A,{activeItem:e,isOffline:v===y.v.OFFLINE,description:l.createElement(k.A,{activeItem:e,connectionStatus:v}),meshingDescription:l.createElement(x.A,{activeItem:e,connectionStatus:v}),isStacking:u,badge:_},A,g?l.createElement("div",{style:{marginTop:r.Ln}},l.createElement(i.A,{activeItem:e,disableOnPortClick:!0,showFullScreenDiagramButton:!1,useBubbleWrapper:!1,multipleDisplayedDevicesData:d,isStacking:u})):null,l.createElement(W,{gap:r.kc,flexDirection:"column"},l.createElement(z.A,{activeItem:e}),!E&&I?l.createElement(F.A,{mac:c}):null),p),v===y.v.OFFLINE?l.createElement(D.A,null,s?.device_mac?null:l.createElement(R.A,{mac:c,model:a,type:o})):null,l.createElement(O,{mac:c,replacement:s}))}},59372(e,t,n){n.d(t,{FH:()=>E,YG:()=>d,ad:()=>m,dA:()=>u});var l=n(801081),c=n(960407),r=n(35627),i=n(294591),a=n(477544),o=n(532419),s=n(180830);const m=(0,l.Mz)(s.K8,a.Ag,c.gm,(e,t,n)=>e.filter(({device_macs:e})=>e.includes(n)).reduce((e,{_id:n})=>[...e,...t.filter(({ap_group_ids:e})=>(e||[]).includes(n))],[])),E=(0,l.Mz)(m,e=>e.every(({enabled:e})=>!1===e)),u=(0,l.Mz)(m,e=>e.some(({enabled:e,wlan_bands:t})=>e&&(t||[]).includes(i._$.AX))),d=(0,l.Mz)(c.gm,o.vh,r.B,s.K8,(e,t,n,l)=>{if(!t.includes(e))return null;const c=l.filter(({device_macs:t})=>t.includes(e));return n.filter(({configuration:{ap_group_ids:e}})=>c.some(({_id:t})=>e?.includes(t))).some(({configuration:{wlan_bands:e}})=>e.includes(i._$.AX))})},766624(e,t,n){n.d(t,{A:()=>o});var l=n(296540),c=n(271856),r=n(709690),i=n(284428),a=n(566723);const o=({description:e,isInteractive:t,portal:n=!0,cursorType:o,title:s,position:m,width:E,iconProps:u,disabled:d=!1})=>{const A=(0,i.Im)()||d,p=(0,i.q)();return l.createElement(c.A,{description:e,portal:n,isInteractive:t,style:{display:"flex",alignItems:"center"},cursorType:o,title:s,position:m,width:E,disableHover:p},l.createElement(r.A,{isActive:!0,size:"original",opacity:A?a.xN:void 0,...u}))}},280258(e,t,n){n.d(t,{H:()=>l});const l=""},451449(e,t,n){n.d(t,{I:()=>l});const l=(0,n(296540).createContext)({fields:!1,labels:!1,tooltipPopovers:!1,tooltipIcons:!1})},284428(e,t,n){n.d(t,{Im:()=>o,iL:()=>s,mQ:()=>i,pv:()=>r,q:()=>a});var l=n(296540),c=n(451449);function r(){return(0,l.useContext)(c.I)}function i(){return r().fields}function a(){return r().tooltipPopovers}function o(){return r().tooltipIcons}function s(){return r().labels}},362412(e,t,n){n.d(t,{A:()=>E});var l=n(296540),c=n(469733),r=n(436331),i=n(805837),a=n(282556),o=n(71265);const s=e=>l.createElement(r.A,{renderOption:i.q,...e}),m=e=>l.createElement(s,{...e});m.Sorted=e=>{const t=(0,c.useSelector)(a.zi),n=(0,l.useMemo)(()=>(0,o.k)(t),[t]);return l.createElement(s,{...e,sortBy:n})};const E=m},71265(e,t,n){n.d(t,{R:()=>E,k:()=>u});var l=n(280258),c=n(190497),r=n(953048),i=n(175522),a=n(936621),o=n(742525);const s=[...new Set([l.H,i.Q.join(i.A),r.Zt,a.F,c.nc,o.Vr])],m={numeric:!0,sensitivity:"base"},E=(e,t)=>{const n=[];for(let l=e;l<=t;l+=1)n.push({value:l,label:String(l)});return n},u=e=>({value:t,label:n},{value:l,label:c})=>s.includes(t?.toString())||s.includes(l?.toString())?1/0:n?.toString().localeCompare(c?.toString(),e,m)??-1}}]);