@matterbridge/frontend 3.11.1-dev-20261026-17739eb → 3.11.1-dev-20261027-9565e40
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/assets/{index.js → index-CDr01LVv.js} +1 -1
- package/build/assets/vendor_emotion-DDpeU9YY.js +1 -0
- package/build/assets/vendor_mdi-ZZw2uLFo.js +1 -0
- package/build/assets/{vendor_mui.js → vendor_mui-DiHi-WpZ.js} +1 -1
- package/build/assets/{vendor_node_modules.js → vendor_node_modules-Br1LuJmm.js} +1 -1
- package/build/assets/{vendor_notistack.js → vendor_notistack-DtGYh6nI.js} +1 -1
- package/build/assets/vendor_qrcode-BukycYO1.js +1 -0
- package/build/assets/{vendor_rjsf.js → vendor_rjsf-Q5JuIJzr.js} +1 -1
- package/build/index.html +10 -10
- package/package.json +1 -1
- package/build/assets/vendor_emotion.js +0 -1
- package/build/assets/vendor_mdi.js +0 -1
- package/build/assets/vendor_qrcode.js +0 -1
- /package/build/assets/{index.css → index-Bq1c5tMN.css} +0 -0
- /package/build/assets/{rolldown-runtime.js → rolldown-runtime-BWaJ3C7D.js} +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as e}from"./rolldown-runtime.js";import{s as t}from"./vendor_emotion.js";import{c as n,d as r,l as i,o as a,p as o,s,u as c}from"./vendor_node_modules.js";import{$ as l,$t as u,A as d,At as f,B as p,Bt as m,C as h,Ct as g,D as _,Dt as v,E as y,Et as b,F as x,Ft as S,G as C,Gt as w,H as T,Ht as E,I as D,It as O,J as k,Jt as A,K as j,Kt as M,L as ee,Lt as N,M as te,Mt as ne,N as re,Nt as P,O as ie,Ot as F,P as ae,Pt as oe,Q as se,Qt as ce,R as le,Rt as ue,S as de,St as fe,T as pe,Tt as me,U as he,Ut as ge,V as I,Vt as _e,W as ve,Wt as L,X as ye,Xt as R,Y as be,Yt as xe,Z as Se,Zt as Ce,_ as we,_t as Te,a as Ee,at as De,b as Oe,bt as z,c as ke,ct as Ae,d as je,dt as Me,en as Ne,et as Pe,f as Fe,ft as Ie,g as Le,gt as Re,h as ze,ht as Be,i as Ve,it as He,j as Ue,jt as We,k as Ge,kt as B,l as Ke,lt as qe,m as Je,mt as Ye,n as Xe,nt as Ze,o as Qe,ot as $e,p as et,pt as tt,q as nt,qt as V,r as rt,rt as it,s as at,st as ot,t as st,tt as ct,u as lt,ut,v as dt,vt as ft,w as pt,wt as mt,x as ht,xt as H,y as gt,yt as _t,z as vt,zt as yt}from"./vendor_mui.js";import{b as bt,c as xt,i as St,o as Ct,s as wt,t as Tt,v as Et,x as Dt}from"./vendor_mdi.js";import{n as Ot,t as kt}from"./vendor_notistack.js";import{a as At,c as jt,i as Mt,l as Nt,n as Pt,o as Ft,r as It,s as Lt,t as Rt}from"./vendor_rjsf.js";import{t as zt}from"./vendor_qrcode.js";(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),t.credentials=e.crossOrigin===`use-credentials`?`include`:e.crossOrigin===`anonymous`?`omit`:`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();var U=e(t(),1),Bt=e(o(),1),W=`mbf-`,G={"enable-mobile":`${W}enable-mobile`,"devices-filter-plugins":`${W}devices-filter-plugins`,"devices-filter-devices":`${W}devices-filter-devices`,"devices-view-mode":`${W}devices-view-mode`,"devices-cluster-view-mode":`${W}devices-cluster-view-mode`,"frontend-version":`${W}frontend-version`,"matterbridge-version":`${W}matterbridge-version`,"home-page-mode":`${W}home-page-mode`,"log-filter-level":`${W}log-filter-level`,"log-filter-search":`${W}log-filter-search`,"log-auto-scroll":`${W}log-auto-scroll`,"log-length":`${W}log-length`,"frontend-theme":`${W}frontend-theme`,"home-page-plugins":`${W}home-page-plugins`,"virtual-mode":`${W}virtual-mode`,"install-auto-exit":`${W}install-auto-exit`,"search-plugins-total":`${W}search-plugins-total`,"search-plugins-meta":`${W}search-plugins-meta`,"search-plugins-versions":`${W}search-plugins-versions`},Vt={"devices-table-order-by":`${W}devices-table-order-by`,"devices-table-order":`${W}devices-table-order`,"devices-column-visibility":`${W}devices-column-visibility`,"plugins-table-order-by":`${W}plugins-table-order-by`,"plugins-table-order":`${W}plugins-table-order`,"plugins-column-visibility":`${W}plugins-column-visibility`,"registered-devices-table-order-by":`${W}registered-devices-table-order-by`,"registered-devices-table-order":`${W}registered-devices-table-order`,"registered-devices-column-visibility":`${W}registered-devices-column-visibility`,"clusters-table-order-by":`${W}clusters-table-order-by`,"clusters-table-order":`${W}clusters-table-order`,"clusters-column-visibility":`${W}clusters-column-visibility`};function Ht(){Object.values(G).forEach(e=>{localStorage.removeItem(e)}),Object.values(Vt).forEach(e=>{localStorage.removeItem(e)})}var K=!1,Ut=()=>{K=!K},q=localStorage.getItem(G[`enable-mobile`])!==`false`,Wt=()=>{q=!0,localStorage.setItem(G[`enable-mobile`],`true`)},Gt=()=>{q=!1,localStorage.setItem(G[`enable-mobile`],`false`)},Kt,qt=e=>{Kt=e},Jt=!1,Yt=e=>{Jt=e},Xt=`/`,Zt=e=>{Xt=e},J=Ne();function Qt(e){return(0,J.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,xmlnsXlink:`http://www.w3.org/1999/xlink`,viewBox:`0 0 296.2 296.2`,...e,children:[(0,J.jsxs)(`defs`,{children:[(0,J.jsxs)(`linearGradient`,{id:`lg1`,x1:`16.6`,y1:`16.6`,x2:`279.6`,y2:`279.6`,gradientUnits:`userSpaceOnUse`,children:[(0,J.jsx)(`stop`,{offset:`0`,stopColor:`#00b48d`}),(0,J.jsx)(`stop`,{offset:`.1`,stopColor:`#3faa77`}),(0,J.jsx)(`stop`,{offset:`.3`,stopColor:`#234148`}),(0,J.jsx)(`stop`,{offset:`.7`,stopColor:`#203b44`}),(0,J.jsx)(`stop`,{offset:`.9`,stopColor:`#ad2e6e`}),(0,J.jsx)(`stop`,{offset:`1`,stopColor:`#c81b74`})]}),(0,J.jsxs)(`linearGradient`,{id:`lg2`,x1:`31.1`,y1:`31.1`,x2:`265.1`,y2:`265.1`,gradientUnits:`userSpaceOnUse`,children:[(0,J.jsx)(`stop`,{offset:`0`,stopColor:`#00b48d`}),(0,J.jsx)(`stop`,{offset:`.2`,stopColor:`#285251`}),(0,J.jsx)(`stop`,{offset:`.4`,stopColor:`#234148`}),(0,J.jsx)(`stop`,{offset:`.8`,stopColor:`#203b44`}),(0,J.jsx)(`stop`,{offset:`.9`,stopColor:`#a8316c`}),(0,J.jsx)(`stop`,{offset:`1`,stopColor:`#c81b74`})]}),(0,J.jsxs)(`linearGradient`,{id:`lg3`,x1:`116.2`,y1:`143.9`,x2:`139.8`,y2:`143.9`,gradientUnits:`userSpaceOnUse`,children:[(0,J.jsx)(`stop`,{offset:`0`,stopColor:`#8bc751`}),(0,J.jsx)(`stop`,{offset:`1`,stopColor:`#0db14b`})]}),(0,J.jsx)(`linearGradient`,{id:`lg4`,x1:`136.1`,y1:`100.8`,x2:`159.6`,y2:`100.8`,xlinkHref:`#lg3`}),(0,J.jsx)(`linearGradient`,{id:`lg5`,x1:`155.3`,y1:`143.9`,x2:`178.9`,y2:`143.9`,xlinkHref:`#lg3`}),(0,J.jsxs)(`linearGradient`,{id:`lg6`,x1:`46.8`,y1:`25.7`,x2:`89.6`,y2:`74.8`,gradientUnits:`userSpaceOnUse`,children:[(0,J.jsx)(`stop`,{offset:`0`,stopColor:`#b1d34a`}),(0,J.jsx)(`stop`,{offset:`1`,stopColor:`#50b848`})]})]}),(0,J.jsx)(`rect`,{width:`296.2`,height:`296.2`,rx:`56.7`,ry:`56.7`,style:{fill:`url(#lg1)`}}),(0,J.jsx)(`rect`,{x:`16.3`,y:`16.3`,width:`263.6`,height:`263.6`,rx:`50.5`,ry:`50.5`,style:{fill:`url(#lg2)`}}),(0,J.jsx)(`circle`,{cx:`128`,cy:`143.9`,r:`11.8`,style:{fill:`url(#lg3)`}}),(0,J.jsx)(`circle`,{cx:`147.8`,cy:`100.8`,r:`11.8`,style:{fill:`url(#lg4)`}}),(0,J.jsx)(`path`,{d:`m244.6 114.5.4-.5L160 33a17 17 0 0 0-24.7-.5l-86.4 83.3a15 15 0 0 0 9.2 26.9h19.3v-4.7l-13.7-12.7v-.1l83.7-80.8 84.2 81-13.9 12.8v4.5h19.5a15 15 0 0 0 7.4-28.1Z`,style:{fill:`url(#lg3)`}}),(0,J.jsx)(`circle`,{cx:`167.1`,cy:`143.9`,r:`11.8`,style:{fill:`url(#lg5)`}}),(0,J.jsx)(`path`,{fill:`#fff`,d:`M219 89.3V35.5a10.5 10.5 0 1 0-21 0v33.7l21 20Z`}),(0,J.jsx)(`path`,{d:`M91.4 73.3H83a37 37 0 0 0-14.5-28.4L65 50.2c.1 0 12.6 9 11.7 25.4-5.3-.4-11.2-1.9-16.3-5.3-11.8-7.8-16-23.7-11.9-46 8.7 1.5 34 7 43 22.8 4.1 7.3 4.1 16.1 0 26.2Z`,style:{fill:`url(#lg6)`}}),(0,J.jsx)(`path`,{d:`M65.9 80a49.6 49.6 0 0 0 17.8 2.2l16.6-16c1.6-8.3.5-15.7-3.3-22.4C84.6 22 47.8 17.5 46.2 17.4l-3-.4-.6 3c-3.8 18.4-5.9 50.6 23.2 60ZM48.4 24.4c8.7 1.5 34 7 43 22.8 4.1 7.3 4.1 16.1 0 26.2H83a37 37 0 0 0-14.5-28.4l-3.7 5.3c.1 0 12.6 9 11.7 25.4-5.3-.4-11.2-1.9-16.3-5.3-11.9-7.8-16-23.7-11.9-46Z`,fill:`#1e5857`}),(0,J.jsx)(`path`,{fill:`#fff`,d:`M250.5 90.5a17.4 17.4 0 1 1 0-34.8 17.4 17.4 0 0 1 0 34.8Zm0-22.7a5.4 5.4 0 0 0 0 10.7 5.3 5.3 0 0 0 0-10.7ZM258.8 148.2a15.9 15.9 0 0 0-9.6 28.5c-.8 4.2-5.4 4.6-5.4 4.6h-26v-43l13.6-13-1.8-2-82.2-79-81.2 78.3-2.5 2.6 13.7 13v42.9H53a21.5 21.5 0 1 0 11.7 15h12.6v18.8c0 7.8 6.4 14.1 14.1 14.1h29.3v14.8H64a10.6 10.6 0 0 0-17.7 8 10.6 10.6 0 0 0 17.6 8h157.6a16.3 16.3 0 1 0 0-16h-84.8V229h66.8c7.8 0 14.2-6.3 14.2-14.1v-19.2h27.6c14.3 0 17.8-12.8 18.5-16.6a15.9 15.9 0 0 0-5-30.9ZM43.7 210.8a10.3 10.3 0 1 1 0-20.6 10.3 10.3 0 0 1 0 20.6Zm192 36a5 5 0 1 1 0 10 5 5 0 0 1 0-10Zm-77-34.8h-22v-34h22v34Zm8.4-79.8c2.7 0 5.2 1 7.2 2.5v-10.4L188 137s2.6 1.3 4.6 1.3h6.7v68c0 3.2-2.6 5.7-5.7 5.7h-19v-34h1.4a7.5 7.5 0 0 0 0-15H120a7.5 7.5 0 0 0 0 15h.7v34h-19.3a5.7 5.7 0 0 1-5.7-5.6v-68.1h6.7c2 0 4.6-1.3 4.6-1.3l13.7-12.7v10.4a11.7 11.7 0 0 1 16 1.6v-13a14.9 14.9 0 0 0-25-10.8s-.1.2-.1.2l-.5.5-6.9 7H92.5l55-53.2 55.1 53.2h-11.8l-7-7c0-.2-.2-.3-.4-.5l-.2-.2a14.8 14.8 0 0 0-25 10.9v12.9c2.2-2.5 5.3-4.1 8.9-4.1Zm91.7 36.7a4.9 4.9 0 1 1 0-9.7 4.9 4.9 0 0 1 0 9.7Z`})]})}var $t=(0,U.createContext)(null),en=(0,U.createContext)(null),Y=(0,U.createContext)(null);function tn({children:e}){let[t,n]=(0,U.useState)([]),[r,i]=(0,U.useState)(localStorage.getItem(G[`log-filter-level`])??`info`),[a,o]=(0,U.useState)(localStorage.getItem(G[`log-filter-search`])??`*`),[s,c]=(0,U.useState)(!1),[l,u]=(0,U.useState)(1),{showSnackbarMessage:d,closeSnackbarMessage:f,closeSnackbar:p,showInstallProgress:m,hideInstallProgress:h,exitInstallProgressSuccess:g,exitInstallProgressError:_,addInstallProgress:v}=(0,U.useContext)($t),y=(0,U.useRef)([]),b=(0,U.useRef)(null),x=(0,U.useRef)(1),S=(0,U.useRef)(Math.floor(Math.random()*999e3)+1e3),C=(0,U.useRef)(null),w=(0,U.useRef)(null),T=(0,U.useRef)(null),E=(0,U.useRef)(r),D=(0,U.useRef)(a),O=(0,U.useRef)(0),k=(0,U.useRef)(null),A=(0,U.useRef)(Number(localStorage.getItem(G[`log-length`])??200)),j=(0,U.useRef)(localStorage.getItem(G[`log-auto-scroll`])!==`false`),M=(0,U.useCallback)(e=>{A.current=e},[]),ee=(0,U.useCallback)(e=>{j.current=e},[]),N=(0,U.useMemo)(()=>window.location.href.replace(/^http/,`ws`),[]);(0,U.useEffect)(()=>(K&&console.log(`WebSocket started counter interval`),k.current=setInterval(()=>{O.current>0&&(K&&console.log(`WebSocket received ${O.current} messages in the last 10 seconds: ${O.current*6} messages/minute`),O.current=0)},1e4),()=>{K&&console.log(`WebSocket stopped counter interval`),k.current&&clearInterval(k.current),k.current=null}),[]),(0,U.useEffect)(()=>{E.current=r},[r]),(0,U.useEffect)(()=>{D.current=a},[a]);let te=(0,U.useCallback)(()=>Math.floor(Math.random()*999e3)+1e3,[]),ne=(0,U.useCallback)((e,t)=>{K&&console.log(`WebSocket filterLogMessages called with level "${e}" and search "${t}"...`),n(n=>n.filter(n=>!([`debug`,`info`,`notice`,`warn`,`error`,`fatal`].includes(n.level)&&(e===`info`&&n.level===`debug`||e===`notice`&&(n.level===`debug`||n.level===`info`)||e===`warn`&&(n.level===`debug`||n.level===`info`||n.level===`notice`)||e===`error`&&(n.level===`debug`||n.level===`info`||n.level===`notice`||n.level===`warn`)||e===`fatal`&&(n.level===`debug`||n.level===`info`||n.level===`notice`||n.level===`warn`||n.level===`error`))||t!==`*`&&t!==``&&!t.startsWith(`/`)&&!t.endsWith(`/`)&&!n.message.toLowerCase().includes(t.toLowerCase())&&!n.name.toLowerCase().includes(t.toLowerCase())||t.startsWith(`/`)&&t.endsWith(`/`)&&(()=>{try{let e=new RegExp(t.slice(1,-1),`i`);return!e.test(n.message)&&!e.test(n.name)}catch(e){return console.error(`WebSocket log search invalid regex filter "${t}":`,e),!1}})())))},[]),re=(0,U.useCallback)(e=>{if(b.current&&b.current.readyState===WebSocket.OPEN)try{K&&console.log(`WebSocket sending message with id ${e.id}:`,e),e.id===void 0&&(e.id=S.current);let t=JSON.stringify(e);b.current.send(t),K&&console.log(`WebSocket sent message:`,e)}catch(e){K&&console.error(`WebSocket error sending message: ${String(e)}`)}else K&&console.error(`WebSocket message not sent, WebSocket not connected:`,e)},[]),P=(0,U.useCallback)((e,t)=>{n(n=>[...n,{level:e,time:``,name:``,message:t}])},[]),ie=(0,U.useCallback)((e,t)=>{K&&console.log(`WebSocket addListener id ${t}:`,e),(t==null||Number.isNaN(t)||t===0)&&console.error(`WebSocket addListener called without id, listener not added:`,e),y.current=[...y.current,{listener:e,id:t}],K&&console.log(`WebSocket addListener total listeners:`,y.current.length)},[]),F=(0,U.useCallback)(e=>{K&&console.log(`WebSocket removeListener:`,e),y.current=y.current.filter(t=>t.listener!==e),K&&console.log(`WebSocket removeListener total listeners:`,y.current.length)},[]),ae=(0,U.useCallback)(()=>{N!==``&&N!=null&&(P(`WebSocket`,`Connecting ${Kt?`with password`:``} to WebSocket: ${N}`),K&&console.log(`WebSocket connecting to: ${N}${Kt?`?password=[redacted]`:``}`),b.current=new WebSocket(N+(Kt?`?password=${encodeURIComponent(Kt)}`:``)),b.current.onmessage=e=>{s||c(!0),O.current+=1;try{let t=JSON.parse(e.data);if(t.id===void 0||t.src===void 0||t.dst===void 0){K&&console.error(`WebSocket undefined message id/src/dst:`,t);return}if(t.src!==`Matterbridge`||t.dst!==`Frontend`){K&&console.error(`WebSocket invalid message src/dst:`,t);return}if(t.error){K&&console.error(`WebSocket error message response:`,t);return}if(t.id===S.current&&t.method===`pong`&&t.response===`pong`){K&&console.log(`WebSocket pong response message id ${t.id}:`,t),w.current&&clearTimeout(w.current),w.current=null;return}if(t.method===`snackbar`&&t.response?.message){K&&console.log(`WebSocket message id %s method %s:`,t.id,t.method,t),d(t.response.message,t.response.timeout,t.response.severity);return}if(t.method===`close_snackbar`&&t.response?.message){K&&console.log(`WebSocket message id %s method %s:`,t.id,t.method,t),f(t.response.message);return}if(t.method===`log`){if(!t.response?.level||!t.response.time||!t.response.name||!t.response.message||(t.response.level===`spawn`&&(t.response.name===`Matterbridge:spawn-init`?m(t.response.message,``,``):t.response.name===`Matterbridge:spawn-exit-success`?g():t.response.name===`Matterbridge:spawn-exit-error`?_():v(t.response.message+`
|
|
1
|
+
import{a as e}from"./rolldown-runtime-BWaJ3C7D.js";import{s as t}from"./vendor_emotion-DDpeU9YY.js";import{c as n,d as r,l as i,o as a,p as o,s,u as c}from"./vendor_node_modules-Br1LuJmm.js";import{$ as l,$t as u,A as d,At as f,B as p,Bt as m,C as h,Ct as g,D as _,Dt as v,E as y,Et as b,F as x,Ft as S,G as C,Gt as w,H as T,Ht as E,I as D,It as O,J as k,Jt as A,K as j,Kt as M,L as ee,Lt as N,M as te,Mt as ne,N as re,Nt as P,O as ie,Ot as F,P as ae,Pt as oe,Q as se,Qt as ce,R as le,Rt as ue,S as de,St as fe,T as pe,Tt as me,U as he,Ut as ge,V as I,Vt as _e,W as ve,Wt as L,X as ye,Xt as R,Y as be,Yt as xe,Z as Se,Zt as Ce,_ as we,_t as Te,a as Ee,at as De,b as Oe,bt as z,c as ke,ct as Ae,d as je,dt as Me,en as Ne,et as Pe,f as Fe,ft as Ie,g as Le,gt as Re,h as ze,ht as Be,i as Ve,it as He,j as Ue,jt as We,k as Ge,kt as B,l as Ke,lt as qe,m as Je,mt as Ye,n as Xe,nt as Ze,o as Qe,ot as $e,p as et,pt as tt,q as nt,qt as V,r as rt,rt as it,s as at,st as ot,t as st,tt as ct,u as lt,ut,v as dt,vt as ft,w as pt,wt as mt,x as ht,xt as H,y as gt,yt as _t,z as vt,zt as yt}from"./vendor_mui-DiHi-WpZ.js";import{b as bt,c as xt,i as St,o as Ct,s as wt,t as Tt,v as Et,x as Dt}from"./vendor_mdi-ZZw2uLFo.js";import{n as Ot,t as kt}from"./vendor_notistack-DtGYh6nI.js";import{a as At,c as jt,i as Mt,l as Nt,n as Pt,o as Ft,r as It,s as Lt,t as Rt}from"./vendor_rjsf-Q5JuIJzr.js";import{t as zt}from"./vendor_qrcode-BukycYO1.js";(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),t.credentials=e.crossOrigin===`use-credentials`?`include`:e.crossOrigin===`anonymous`?`omit`:`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();var U=e(t(),1),Bt=e(o(),1),W=`mbf-`,G={"enable-mobile":`${W}enable-mobile`,"devices-filter-plugins":`${W}devices-filter-plugins`,"devices-filter-devices":`${W}devices-filter-devices`,"devices-view-mode":`${W}devices-view-mode`,"devices-cluster-view-mode":`${W}devices-cluster-view-mode`,"frontend-version":`${W}frontend-version`,"matterbridge-version":`${W}matterbridge-version`,"home-page-mode":`${W}home-page-mode`,"log-filter-level":`${W}log-filter-level`,"log-filter-search":`${W}log-filter-search`,"log-auto-scroll":`${W}log-auto-scroll`,"log-length":`${W}log-length`,"frontend-theme":`${W}frontend-theme`,"home-page-plugins":`${W}home-page-plugins`,"virtual-mode":`${W}virtual-mode`,"install-auto-exit":`${W}install-auto-exit`,"search-plugins-total":`${W}search-plugins-total`,"search-plugins-meta":`${W}search-plugins-meta`,"search-plugins-versions":`${W}search-plugins-versions`},Vt={"devices-table-order-by":`${W}devices-table-order-by`,"devices-table-order":`${W}devices-table-order`,"devices-column-visibility":`${W}devices-column-visibility`,"plugins-table-order-by":`${W}plugins-table-order-by`,"plugins-table-order":`${W}plugins-table-order`,"plugins-column-visibility":`${W}plugins-column-visibility`,"registered-devices-table-order-by":`${W}registered-devices-table-order-by`,"registered-devices-table-order":`${W}registered-devices-table-order`,"registered-devices-column-visibility":`${W}registered-devices-column-visibility`,"clusters-table-order-by":`${W}clusters-table-order-by`,"clusters-table-order":`${W}clusters-table-order`,"clusters-column-visibility":`${W}clusters-column-visibility`};function Ht(){Object.values(G).forEach(e=>{localStorage.removeItem(e)}),Object.values(Vt).forEach(e=>{localStorage.removeItem(e)})}var K=!1,Ut=()=>{K=!K},q=localStorage.getItem(G[`enable-mobile`])!==`false`,Wt=()=>{q=!0,localStorage.setItem(G[`enable-mobile`],`true`)},Gt=()=>{q=!1,localStorage.setItem(G[`enable-mobile`],`false`)},Kt,qt=e=>{Kt=e},Jt=!1,Yt=e=>{Jt=e},Xt=`/`,Zt=e=>{Xt=e},J=Ne();function Qt(e){return(0,J.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,xmlnsXlink:`http://www.w3.org/1999/xlink`,viewBox:`0 0 296.2 296.2`,...e,children:[(0,J.jsxs)(`defs`,{children:[(0,J.jsxs)(`linearGradient`,{id:`lg1`,x1:`16.6`,y1:`16.6`,x2:`279.6`,y2:`279.6`,gradientUnits:`userSpaceOnUse`,children:[(0,J.jsx)(`stop`,{offset:`0`,stopColor:`#00b48d`}),(0,J.jsx)(`stop`,{offset:`.1`,stopColor:`#3faa77`}),(0,J.jsx)(`stop`,{offset:`.3`,stopColor:`#234148`}),(0,J.jsx)(`stop`,{offset:`.7`,stopColor:`#203b44`}),(0,J.jsx)(`stop`,{offset:`.9`,stopColor:`#ad2e6e`}),(0,J.jsx)(`stop`,{offset:`1`,stopColor:`#c81b74`})]}),(0,J.jsxs)(`linearGradient`,{id:`lg2`,x1:`31.1`,y1:`31.1`,x2:`265.1`,y2:`265.1`,gradientUnits:`userSpaceOnUse`,children:[(0,J.jsx)(`stop`,{offset:`0`,stopColor:`#00b48d`}),(0,J.jsx)(`stop`,{offset:`.2`,stopColor:`#285251`}),(0,J.jsx)(`stop`,{offset:`.4`,stopColor:`#234148`}),(0,J.jsx)(`stop`,{offset:`.8`,stopColor:`#203b44`}),(0,J.jsx)(`stop`,{offset:`.9`,stopColor:`#a8316c`}),(0,J.jsx)(`stop`,{offset:`1`,stopColor:`#c81b74`})]}),(0,J.jsxs)(`linearGradient`,{id:`lg3`,x1:`116.2`,y1:`143.9`,x2:`139.8`,y2:`143.9`,gradientUnits:`userSpaceOnUse`,children:[(0,J.jsx)(`stop`,{offset:`0`,stopColor:`#8bc751`}),(0,J.jsx)(`stop`,{offset:`1`,stopColor:`#0db14b`})]}),(0,J.jsx)(`linearGradient`,{id:`lg4`,x1:`136.1`,y1:`100.8`,x2:`159.6`,y2:`100.8`,xlinkHref:`#lg3`}),(0,J.jsx)(`linearGradient`,{id:`lg5`,x1:`155.3`,y1:`143.9`,x2:`178.9`,y2:`143.9`,xlinkHref:`#lg3`}),(0,J.jsxs)(`linearGradient`,{id:`lg6`,x1:`46.8`,y1:`25.7`,x2:`89.6`,y2:`74.8`,gradientUnits:`userSpaceOnUse`,children:[(0,J.jsx)(`stop`,{offset:`0`,stopColor:`#b1d34a`}),(0,J.jsx)(`stop`,{offset:`1`,stopColor:`#50b848`})]})]}),(0,J.jsx)(`rect`,{width:`296.2`,height:`296.2`,rx:`56.7`,ry:`56.7`,style:{fill:`url(#lg1)`}}),(0,J.jsx)(`rect`,{x:`16.3`,y:`16.3`,width:`263.6`,height:`263.6`,rx:`50.5`,ry:`50.5`,style:{fill:`url(#lg2)`}}),(0,J.jsx)(`circle`,{cx:`128`,cy:`143.9`,r:`11.8`,style:{fill:`url(#lg3)`}}),(0,J.jsx)(`circle`,{cx:`147.8`,cy:`100.8`,r:`11.8`,style:{fill:`url(#lg4)`}}),(0,J.jsx)(`path`,{d:`m244.6 114.5.4-.5L160 33a17 17 0 0 0-24.7-.5l-86.4 83.3a15 15 0 0 0 9.2 26.9h19.3v-4.7l-13.7-12.7v-.1l83.7-80.8 84.2 81-13.9 12.8v4.5h19.5a15 15 0 0 0 7.4-28.1Z`,style:{fill:`url(#lg3)`}}),(0,J.jsx)(`circle`,{cx:`167.1`,cy:`143.9`,r:`11.8`,style:{fill:`url(#lg5)`}}),(0,J.jsx)(`path`,{fill:`#fff`,d:`M219 89.3V35.5a10.5 10.5 0 1 0-21 0v33.7l21 20Z`}),(0,J.jsx)(`path`,{d:`M91.4 73.3H83a37 37 0 0 0-14.5-28.4L65 50.2c.1 0 12.6 9 11.7 25.4-5.3-.4-11.2-1.9-16.3-5.3-11.8-7.8-16-23.7-11.9-46 8.7 1.5 34 7 43 22.8 4.1 7.3 4.1 16.1 0 26.2Z`,style:{fill:`url(#lg6)`}}),(0,J.jsx)(`path`,{d:`M65.9 80a49.6 49.6 0 0 0 17.8 2.2l16.6-16c1.6-8.3.5-15.7-3.3-22.4C84.6 22 47.8 17.5 46.2 17.4l-3-.4-.6 3c-3.8 18.4-5.9 50.6 23.2 60ZM48.4 24.4c8.7 1.5 34 7 43 22.8 4.1 7.3 4.1 16.1 0 26.2H83a37 37 0 0 0-14.5-28.4l-3.7 5.3c.1 0 12.6 9 11.7 25.4-5.3-.4-11.2-1.9-16.3-5.3-11.9-7.8-16-23.7-11.9-46Z`,fill:`#1e5857`}),(0,J.jsx)(`path`,{fill:`#fff`,d:`M250.5 90.5a17.4 17.4 0 1 1 0-34.8 17.4 17.4 0 0 1 0 34.8Zm0-22.7a5.4 5.4 0 0 0 0 10.7 5.3 5.3 0 0 0 0-10.7ZM258.8 148.2a15.9 15.9 0 0 0-9.6 28.5c-.8 4.2-5.4 4.6-5.4 4.6h-26v-43l13.6-13-1.8-2-82.2-79-81.2 78.3-2.5 2.6 13.7 13v42.9H53a21.5 21.5 0 1 0 11.7 15h12.6v18.8c0 7.8 6.4 14.1 14.1 14.1h29.3v14.8H64a10.6 10.6 0 0 0-17.7 8 10.6 10.6 0 0 0 17.6 8h157.6a16.3 16.3 0 1 0 0-16h-84.8V229h66.8c7.8 0 14.2-6.3 14.2-14.1v-19.2h27.6c14.3 0 17.8-12.8 18.5-16.6a15.9 15.9 0 0 0-5-30.9ZM43.7 210.8a10.3 10.3 0 1 1 0-20.6 10.3 10.3 0 0 1 0 20.6Zm192 36a5 5 0 1 1 0 10 5 5 0 0 1 0-10Zm-77-34.8h-22v-34h22v34Zm8.4-79.8c2.7 0 5.2 1 7.2 2.5v-10.4L188 137s2.6 1.3 4.6 1.3h6.7v68c0 3.2-2.6 5.7-5.7 5.7h-19v-34h1.4a7.5 7.5 0 0 0 0-15H120a7.5 7.5 0 0 0 0 15h.7v34h-19.3a5.7 5.7 0 0 1-5.7-5.6v-68.1h6.7c2 0 4.6-1.3 4.6-1.3l13.7-12.7v10.4a11.7 11.7 0 0 1 16 1.6v-13a14.9 14.9 0 0 0-25-10.8s-.1.2-.1.2l-.5.5-6.9 7H92.5l55-53.2 55.1 53.2h-11.8l-7-7c0-.2-.2-.3-.4-.5l-.2-.2a14.8 14.8 0 0 0-25 10.9v12.9c2.2-2.5 5.3-4.1 8.9-4.1Zm91.7 36.7a4.9 4.9 0 1 1 0-9.7 4.9 4.9 0 0 1 0 9.7Z`})]})}var $t=(0,U.createContext)(null),en=(0,U.createContext)(null),Y=(0,U.createContext)(null);function tn({children:e}){let[t,n]=(0,U.useState)([]),[r,i]=(0,U.useState)(localStorage.getItem(G[`log-filter-level`])??`info`),[a,o]=(0,U.useState)(localStorage.getItem(G[`log-filter-search`])??`*`),[s,c]=(0,U.useState)(!1),[l,u]=(0,U.useState)(1),{showSnackbarMessage:d,closeSnackbarMessage:f,closeSnackbar:p,showInstallProgress:m,hideInstallProgress:h,exitInstallProgressSuccess:g,exitInstallProgressError:_,addInstallProgress:v}=(0,U.useContext)($t),y=(0,U.useRef)([]),b=(0,U.useRef)(null),x=(0,U.useRef)(1),S=(0,U.useRef)(Math.floor(Math.random()*999e3)+1e3),C=(0,U.useRef)(null),w=(0,U.useRef)(null),T=(0,U.useRef)(null),E=(0,U.useRef)(r),D=(0,U.useRef)(a),O=(0,U.useRef)(0),k=(0,U.useRef)(null),A=(0,U.useRef)(Number(localStorage.getItem(G[`log-length`])??200)),j=(0,U.useRef)(localStorage.getItem(G[`log-auto-scroll`])!==`false`),M=(0,U.useCallback)(e=>{A.current=e},[]),ee=(0,U.useCallback)(e=>{j.current=e},[]),N=(0,U.useMemo)(()=>window.location.href.replace(/^http/,`ws`),[]);(0,U.useEffect)(()=>(K&&console.log(`WebSocket started counter interval`),k.current=setInterval(()=>{O.current>0&&(K&&console.log(`WebSocket received ${O.current} messages in the last 10 seconds: ${O.current*6} messages/minute`),O.current=0)},1e4),()=>{K&&console.log(`WebSocket stopped counter interval`),k.current&&clearInterval(k.current),k.current=null}),[]),(0,U.useEffect)(()=>{E.current=r},[r]),(0,U.useEffect)(()=>{D.current=a},[a]);let te=(0,U.useCallback)(()=>Math.floor(Math.random()*999e3)+1e3,[]),ne=(0,U.useCallback)((e,t)=>{K&&console.log(`WebSocket filterLogMessages called with level "${e}" and search "${t}"...`),n(n=>n.filter(n=>!([`debug`,`info`,`notice`,`warn`,`error`,`fatal`].includes(n.level)&&(e===`info`&&n.level===`debug`||e===`notice`&&(n.level===`debug`||n.level===`info`)||e===`warn`&&(n.level===`debug`||n.level===`info`||n.level===`notice`)||e===`error`&&(n.level===`debug`||n.level===`info`||n.level===`notice`||n.level===`warn`)||e===`fatal`&&(n.level===`debug`||n.level===`info`||n.level===`notice`||n.level===`warn`||n.level===`error`))||t!==`*`&&t!==``&&!t.startsWith(`/`)&&!t.endsWith(`/`)&&!n.message.toLowerCase().includes(t.toLowerCase())&&!n.name.toLowerCase().includes(t.toLowerCase())||t.startsWith(`/`)&&t.endsWith(`/`)&&(()=>{try{let e=new RegExp(t.slice(1,-1),`i`);return!e.test(n.message)&&!e.test(n.name)}catch(e){return console.error(`WebSocket log search invalid regex filter "${t}":`,e),!1}})())))},[]),re=(0,U.useCallback)(e=>{if(b.current&&b.current.readyState===WebSocket.OPEN)try{K&&console.log(`WebSocket sending message with id ${e.id}:`,e),e.id===void 0&&(e.id=S.current);let t=JSON.stringify(e);b.current.send(t),K&&console.log(`WebSocket sent message:`,e)}catch(e){K&&console.error(`WebSocket error sending message: ${String(e)}`)}else K&&console.error(`WebSocket message not sent, WebSocket not connected:`,e)},[]),P=(0,U.useCallback)((e,t)=>{n(n=>[...n,{level:e,time:``,name:``,message:t}])},[]),ie=(0,U.useCallback)((e,t)=>{K&&console.log(`WebSocket addListener id ${t}:`,e),(t==null||Number.isNaN(t)||t===0)&&console.error(`WebSocket addListener called without id, listener not added:`,e),y.current=[...y.current,{listener:e,id:t}],K&&console.log(`WebSocket addListener total listeners:`,y.current.length)},[]),F=(0,U.useCallback)(e=>{K&&console.log(`WebSocket removeListener:`,e),y.current=y.current.filter(t=>t.listener!==e),K&&console.log(`WebSocket removeListener total listeners:`,y.current.length)},[]),ae=(0,U.useCallback)(()=>{N!==``&&N!=null&&(P(`WebSocket`,`Connecting ${Kt?`with password`:``} to WebSocket: ${N}`),K&&console.log(`WebSocket connecting to: ${N}${Kt?`?password=[redacted]`:``}`),b.current=new WebSocket(N+(Kt?`?password=${encodeURIComponent(Kt)}`:``)),b.current.onmessage=e=>{s||c(!0),O.current+=1;try{let t=JSON.parse(e.data);if(t.id===void 0||t.src===void 0||t.dst===void 0){K&&console.error(`WebSocket undefined message id/src/dst:`,t);return}if(t.src!==`Matterbridge`||t.dst!==`Frontend`){K&&console.error(`WebSocket invalid message src/dst:`,t);return}if(t.error){K&&console.error(`WebSocket error message response:`,t);return}if(t.id===S.current&&t.method===`pong`&&t.response===`pong`){K&&console.log(`WebSocket pong response message id ${t.id}:`,t),w.current&&clearTimeout(w.current),w.current=null;return}if(t.method===`snackbar`&&t.response?.message){K&&console.log(`WebSocket message id %s method %s:`,t.id,t.method,t),d(t.response.message,t.response.timeout,t.response.severity);return}if(t.method===`close_snackbar`&&t.response?.message){K&&console.log(`WebSocket message id %s method %s:`,t.id,t.method,t),f(t.response.message);return}if(t.method===`log`){if(!t.response?.level||!t.response.time||!t.response.name||!t.response.message||(t.response.level===`spawn`&&(t.response.name===`Matterbridge:spawn-init`?m(t.response.message,``,``):t.response.name===`Matterbridge:spawn-exit-success`?g():t.response.name===`Matterbridge:spawn-exit-error`?_():v(t.response.message+`
|
|
2
2
|
`)),[`debug`,`info`,`notice`,`warn`,`error`,`fatal`].includes(t.response.level)&&(E.current===`info`&&t.response.level===`debug`||E.current===`notice`&&(t.response.level===`debug`||t.response.level===`info`)||E.current===`warn`&&(t.response.level===`debug`||t.response.level===`info`||t.response.level===`notice`)||E.current===`error`&&(t.response.level===`debug`||t.response.level===`info`||t.response.level===`notice`||t.response.level===`warn`)||E.current===`fatal`&&(t.response.level===`debug`||t.response.level===`info`||t.response.level===`notice`||t.response.level===`warn`||t.response.level===`error`)))||D.current!==`*`&&D.current!==``&&!D.current.startsWith(`/`)&&!D.current.endsWith(`/`)&&!t.response.message.toLowerCase().includes(D.current.toLowerCase())&&!t.response.name.toLowerCase().includes(D.current.toLowerCase())||D.current.startsWith(`/`)&&D.current.endsWith(`/`)&&(()=>{try{let e=new RegExp(D.current.slice(1,-1),`i`);return!e.test(t.response.message)&&!e.test(t.response.name)}catch(e){return console.error(`WebSocket log search invalid regex filter "${D.current}":`,e),!1}})()||t.response.name===`Commissioning`&&t.response.message.includes(`is uncommissioned`))return;n(e=>{let n=[...e,{level:t.response.level,time:t.response.time,name:t.response.name,message:t.response.message}];return K&&console.log(`WebSocket new log message added (${n.length}/${A.current}):`,n[n.length-1]),n.length>A.current+A.current*10/100?(K&&console.log(`WebSocket sliced log messages to the last ${A.current} entries`),n.slice(n.length-A.current)):n})}else{if(K&&console.log(`WebSocket received message id %s method %s:`,t.id,t.method,t),t.id===0)y.current.forEach(e=>e.listener(t));else{let e=y.current.find(e=>e.id===t.id);e?e.listener(t):K&&console.warn(`WebSocket no listener found for message id %s:`,t.id,t)}return}}catch(e){console.error(`WebSocket error parsing message: ${String(e)}`,e instanceof Error?e.stack:null)}},b.current.onopen=()=>{K&&console.log(`WebSocket: Connected to WebSocket: ${N}`),P(`WebSocket`,`Connected to WebSocket: ${N}`),c(!0),p(),x.current=1,u(1),T.current=setTimeout(()=>{C.current=setInterval(()=>{re({id:S.current,method:`ping`,src:`Frontend`,dst:`Matterbridge`,params:{}}),w.current&&clearTimeout(w.current),w.current=setTimeout(()=>{K&&console.error(`WebSocketUse: No pong response received from WebSocket: ${N}`),P(`WebSocket`,`No pong response received from WebSocket: ${N}`),c(!1)},5e4)},6e4)},3e5)},b.current.onclose=()=>{K&&console.error(`WebSocket: Disconnected from WebSocket ${Jt?`with Ingress`:``}: ${N}`),P(`WebSocket`,`Disconnected from WebSocket: ${N}`),c(!1),p(),h(),T.current&&clearTimeout(T.current),w.current&&clearTimeout(w.current),C.current&&clearInterval(C.current),P(`WebSocket`,`Reconnecting (attempt ${x.current} of 100) to WebSocket${Jt?` (Ingress)`:``}: ${N}`),Jt?setTimeout(oe,5e3):x.current===1?oe():x.current<100?setTimeout(oe,1e3*x.current):P(`WebSocket`,`Reconnect attempts exceeded limit of 100 retries, refresh the page to reconnect to: ${N}`),x.current+=1,u(x.current)},b.current.onerror=e=>{K&&console.error(`WebSocket: WebSocket error connecting to %s:`,N,e),P(`WebSocket`,`WebSocket error connecting to ${N}`)})},[N]),oe=(0,U.useCallback)(()=>{K&&console.log(`WebSocket attemptReconnect ${x.current}/100 to:`,N),ae()},[ae]);(0,U.useEffect)(()=>(ae(),()=>{b.current&&b.current.readyState===WebSocket.OPEN&&b.current.close()}),[ae]);let se=(0,U.useMemo)(()=>({messages:t,logLength:A,logAutoScroll:j,logFilterLevel:r,logFilterSearch:a,setMessages:n,setLogLength:M,setLogAutoScroll:ee,setLogFilterLevel:i,setLogFilterSearch:o,filterLogMessages:ne}),[t,A,j,r,a,n,M,ee,i,o,ne]),ce=(0,U.useMemo)(()=>({logLength:A,logAutoScroll:j,logFilterLevel:r,logFilterSearch:a,setMessages:n,setLogLength:M,setLogAutoScroll:ee,setLogFilterLevel:i,setLogFilterSearch:o,filterLogMessages:ne,online:s,retry:l,getUniqueId:te,addListener:ie,removeListener:F,sendMessage:re,logMessage:P}),[A,j,n,M,ee,i,o,s,l,ie,F,re,P]);return(0,J.jsx)(en.Provider,{value:se,children:(0,J.jsx)(Y.Provider,{value:ce,children:e})})}function nn(){let{retry:e}=(0,U.useContext)(Y);return(0,J.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,width:`100vw`,height:`100vh`,justifyContent:`center`,alignItems:`center`,fontSize:`20px`,color:`var(--main-text-color)`,backgroundColor:`var(--main-bg-color)`},children:[(0,J.jsx)(Qt,{style:{height:`128px`,width:`128px`,margin:`10px`,marginBottom:`20px`}}),e<100?(0,J.jsxs)(J.Fragment,{children:[(0,J.jsx)(Ce,{style:{color:`var(--primary-color)`}}),(0,J.jsx)(`div`,{style:{marginTop:`20px`,color:`var(--primary-color)`,textAlign:`center`},children:(0,J.jsxs)(`span`,{children:[`Reconnecting to Matterbridge `,`(attempt `+e+`)`,`...`]})})]}):(0,J.jsxs)(J.Fragment,{children:[(0,J.jsxs)(`div`,{style:{marginTop:`20px`,color:`var(--primary-color)`,textAlign:`center`},children:[(0,J.jsx)(`span`,{children:`Unable to connect to Matterbridge after multiple attempts.`}),(0,J.jsx)(`br`,{}),(0,J.jsx)(`span`,{children:`Please check your network connection.`}),(0,J.jsx)(`br`,{})]}),(0,J.jsx)(M,{variant:`contained`,color:`primary`,onClick:()=>{window.location.reload()},style:{marginTop:`20px`},children:`Refresh the Page`})]})]})}var X=Tt();function Z({children:e,style:t}){return(0,J.jsx)(`div`,{style:{display:`flex`,flexDirection:`column`,flex:`0 0 auto`,width:`100%`,overflow:`hidden`,margin:`0px`,padding:`0px`,gap:`0px`,backgroundColor:`var(--div-bg-color)`,boxShadow:`5px 5px 10px var(--div-shadow-color)`,border:`1px solid var(--table-border-color)`,borderRadius:`var(--div-border-radius)`,boxSizing:`border-box`,...t},children:e})}function rn({children:e,style:t}){return(0,J.jsx)(`div`,{style:{display:`flex`,flexDirection:`row`,justifyContent:`space-between`,width:`100%`,height:`30px`,borderBottom:`1px solid var(--table-border-color)`,color:`var(--header-text-color)`,backgroundColor:`var(--header-bg-color)`,margin:`0px`,padding:`0px`,boxSizing:`border-box`,...t},children:e})}function Q({children:e,style:t}){return(0,J.jsx)(`div`,{style:{color:`var(--header-text-color)`,backgroundColor:`var(--header-bg-color)`,fontSize:`16px`,fontWeight:`bold`,margin:`0px`,padding:`5px 10px`,...t},children:e})}function an({children:e,style:t}){return(0,J.jsx)(`div`,{style:{display:`flex`,flexDirection:`row`,justifyContent:`space-between`,width:`100%`,height:`30px`,color:`var(--footer-text-color)`,backgroundColor:`var(--footer-bg-color)`,margin:`0px`,padding:`0px`,boxSizing:`border-box`,...t},children:e})}function on({children:e,style:t}){return(0,J.jsx)(`div`,{style:{color:`var(--footer-text-color)`,backgroundColor:`var(--footer-bg-color)`,fontSize:`14px`,fontWeight:`bold`,margin:`0px`,padding:`5px 10px`,...t},children:e})}function sn({children:e,style:t}){return(0,J.jsx)(`div`,{style:{color:`var(--div-text-color)`,backgroundColor:`var(--div-bg-color)`,fontSize:`14px`,fontWeight:`normal`,margin:`0px`,padding:`5px 10px`,...t},children:e})}function cn({children:e,style:t,onDragOver:n,onDragLeave:r,onDrop:i}){return(0,J.jsx)(`div`,{style:{flex:`0 0 auto`,display:`flex`,flexDirection:`row`,overflow:`hidden`,alignItems:`start`,justifyContent:`space-between`,margin:`0px`,padding:`10px`,gap:`20px`,...t},onDragOver:n,onDragLeave:r,onDrop:i,children:e})}function ln({children:e,style:t,close:n}){return(0,J.jsxs)(`div`,{style:{display:`flex`,flexDirection:`row`,margin:`0px`,padding:`0px`,paddingRight:`10px`,gap:`10px`,...t},children:[e,!1]})}var un=[`Off`,`Low`,`Medium`,`High`,`On`,`Auto`,`Smart`],dn={display:`flex`,gap:`2px`,justifyContent:`space-evenly`,width:`100%`,height:`40px`},fn={margin:`0`,padding:`0`,fontSize:`36px`,fontWeight:`medium`,color:`var(--primary-color)`},pn={margin:`0`,padding:`0`,fontSize:`20px`,fontWeight:`medium`,color:`var(--div-text-color)`,textAlign:`center`},mn={margin:`0`,padding:`0`,paddingBottom:`2px`,fontSize:`16px`,fontWeight:`medium`,color:`var(--div-text-color)`,textAlign:`center`},hn={display:`flex`,gap:`2px`,justifyContent:`center`,width:`100%`,height:`18px`,margin:`0`,padding:`0`,overflow:`hidden`,textOverflow:`ellipsis`,whiteSpace:`normal`},gn={margin:`0`,padding:`0`,fontSize:`12px`,fontWeight:`normal`,color:`var(--div-text-color)`},_n={display:`flex`,justifyContent:`center`,width:`100%`,height:`52px`,margin:`0`,padding:`0`,overflow:`hidden`,textOverflow:`ellipsis`,whiteSpace:`normal`},vn={margin:`0`,padding:`0`,fontSize:`14px`,fontWeight:`bold`,color:`var(--div-text-color)`},yn={display:`flex`,gap:`4px`,justifyContent:`center`,width:`100%`,height:`15px`,margin:`0`,padding:`0`,overflow:`hidden`,textOverflow:`ellipsis`,whiteSpace:`normal`},bn={margin:`0`,padding:`0px 4px`,borderRadius:`5px`,textAlign:`center`,fontSize:`12px`,fontWeight:`normal`,color:`var(--secondary-color)`},xn=[256,257,268,269],Sn=[266,267],Cn=[271,272],wn=[256,257,268,269,266,267,272],Tn=[43,45],En=[`Closed`,`Open`,`Partial`,`Pedestrian`,`Ventilation`,`Signature`];function Dn(e){if(typeof e!=`object`||!e||!(`position`in e))return`N/A`;let t=e.position;return typeof t!=`number`||!Number.isInteger(t)||t<0||t>=En.length?`N/A`:En[t]}function On(e){return typeof e!=`number`||!Number.isInteger(e)||e<0||e>1e4?`N/A`:e===0?En[0]:e===1e4?En[1]:En[2]}function kn(e){return typeof e!=`object`||!e||!(`position`in e)?`N/A`:On(e.position)}function $({icon:e,iconColor:t,cluster:n,value:r,unit:i,prefix:a}){return K&&console.log(`Render cluster "${n.clusterName}.${n.attributeName}" value(${typeof r}-${Number.isNaN(r)}) "${r}" unit "${i}"`),a??=!1,(0,J.jsxs)(V,{sx:dn,children:[e&&(0,U.cloneElement)(e,{key:`${n.clusterId}-${n.attributeId}-icon`,sx:{...fn,color:t??`var(--primary-color)`}}),(0,J.jsxs)(V,{sx:{...dn,gap:`4px`,alignContent:`center`,alignItems:`end`,justifyContent:`center`},children:[i&&a&&(0,J.jsx)(A,{sx:mn,children:i},`${n.clusterId}-${n.attributeId}-unit-prefix`),(0,J.jsx)(A,{sx:pn,children:r==null||typeof r==`number`&&Number.isNaN(r)||r===`NaN`?`---`:r},`${n.clusterId}-${n.attributeId}-value`),i&&!a&&(0,J.jsx)(A,{sx:mn,children:i},`${n.clusterId}-${n.attributeId}-unit-suffix`)]},`${n.clusterId}-${n.attributeId}-valueunitbox`)]},`${n.clusterId}-${n.attributeId}-box`)}function An({device:e,endpoint:t,id:n,deviceType:r,clusters:i}){let a=[`Unknown`,`Good`,`Fair`,`Moderate`,`Poor`,`VeryPoor`,`Ext.Poor`],o=``,s=e=>{if(!e)return null;let t=e.attributeLocalValue;if(!t||typeof t!=`object`||!(`energy`in t))return null;let n=t.energy;return typeof n!=`number`&&typeof n!=`bigint`?null:Math.round(Number(n)/1e6)},c=i.find(e=>e.clusterName===`ElectricalEnergyMeasurement`&&e.attributeName===`cumulativeEnergyImported`),u=i.find(e=>e.clusterName===`ElectricalEnergyMeasurement`&&e.attributeName===`cumulativeEnergyExported`),d=s(c),f=s(u),p=c??u,m=d??(f===null?null:`+ ${f}`);K&&console.log(`Device "${e.deviceName}" endpoint "${t}" id "${n}" deviceType "0x${r.toString(16).padStart(4,`0`)}" clusters (${i?.length})`);let h=i.find(e=>e.clusterName===`Descriptor`&&e.attributeName===`tagList`)?.attributeLocalValue;if(h){let e=``;h.map(t=>{t.label&&(e+=t.label+` `)}),o=e.trim()}if(r===17&&i.filter(e=>e.clusterName===`PowerSource`&&e.attributeName===`batVoltage`).map(e=>o=`${e.attributeLocalValue??0} mV`),wn.includes(r)&&i.filter(e=>e.clusterName===`LevelControl`&&e.attributeName===`currentLevel`).map(e=>o=`Level ${e.attributeValue}`),r===514&&i.filter(e=>e.clusterName===`WindowCovering`&&e.attributeName===`currentPositionLiftPercent100ths`).map(e=>o=`Position ${e.attributeLocalValue/100}%`),r===769&&i.filter(e=>e.clusterName===`Thermostat`&&e.attributeName===`occupiedHeatingSetpoint`).map(e=>o=`Heat ${e.attributeLocalValue/100}°C `),r===769&&i.filter(e=>e.clusterName===`Thermostat`&&e.attributeName===`occupiedCoolingSetpoint`).map(e=>o+=`Cool ${e.attributeLocalValue/100}°C`),Tn.includes(r)&&i.filter(e=>e.clusterName===`FanControl`&&e.attributeName===`percentCurrent`).map(e=>o=`Speed ${e.attributeValue}%`),r===118&&i.filter(e=>e.clusterName===`SmokeCoAlarm`&&e.attributeName===`coState`).map(e=>o=e.attributeLocalValue===0?`No CO detected`:`CO alarm!`),r===1296&&i.filter(e=>e.clusterName===`ElectricalPowerMeasurement`&&e.attributeName===`voltage`).map(e=>o=`${e.attributeLocalValue/1e3} V, `),r===1296&&i.filter(e=>e.clusterName===`ElectricalPowerMeasurement`&&e.attributeName===`activeCurrent`).map(e=>o+=`${e.attributeLocalValue/1e3} A, `),r===1296&&i.filter(e=>e.clusterName===`ElectricalPowerMeasurement`&&e.attributeName===`activePower`).map(e=>o+=`${e.attributeLocalValue/1e6} kW`),r===39){let e=i.find(e=>e.clusterName===`ModeSelect`&&e.attributeName===`currentMode`)?.attributeLocalValue;o=(i.find(e=>e.clusterName===`ModeSelect`&&e.attributeName===`supportedModes`)?.attributeLocalValue)?.find(t=>t.mode===e)?.label||`Unknown`}if(r===116){let e=i.find(e=>e.clusterName===`RvcRunMode`&&e.attributeName===`currentMode`)?.attributeLocalValue;o=(i.find(e=>e.clusterName===`RvcRunMode`&&e.attributeName===`supportedModes`)?.attributeLocalValue)?.find(t=>t.mode===e)?.label||`Unknown`}return(0,J.jsxs)(Z,{style:{margin:`0px`,padding:`5px`,width:`150px`,height:`150px`,borderColor:`var(--div-bg-color)`,borderRadius:`5px`,justifyContent:`space-between`},children:[r===19&&i.filter(e=>e.clusterName===`BridgedDeviceBasicInformation`&&e.attributeName===`reachable`).map(e=>(0,J.jsx)($,{icon:e.attributeLocalValue===!0?(0,J.jsx)(C,{}):(0,J.jsx)(ve,{}),iconColor:e.attributeLocalValue===!0?`green`:`red`,cluster:e,value:e.attributeLocalValue===!0?`Online`:`Offline`},`${e.clusterId}-${e.attributeId}`)),r===17&&i.filter(e=>e.clusterName===`PowerSource`&&e.attributeName===`batPercentRemaining`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(Ye,{}),cluster:e,value:e.attributeLocalValue/2,unit:`%`},`${e.clusterId}-${e.attributeId}`)),r===17&&i.filter(e=>e.clusterName===`PowerSource`&&e.attributeName===`wiredCurrentType`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(qe,{}),cluster:e,value:e.attributeLocalValue===0?`AC`:`DC`},`${e.clusterId}-${e.attributeId}`)),r===1293&&i.filter(e=>e.clusterName===`DeviceEnergyManagement`&&e.attributeName===`esaState`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M8.28,5.45L6.5,4.55L7.76,2H16.23L17.5,4.55L15.72,5.44L15,4H9L8.28,5.45M18.62,8H14.09L13.3,5H10.7L9.91,8H5.38L4.1,10.55L5.89,11.44L6.62,10H17.38L18.1,11.45L19.89,10.56L18.62,8M17.77,22H15.7L15.46,21.1L12,15.9L8.53,21.1L8.3,22H6.23L9.12,11H11.19L10.83,12.35L12,14.1L13.16,12.35L12.81,11H14.88L17.77,22M11.4,15L10.5,13.65L9.32,18.13L11.4,15M14.68,18.12L13.5,13.64L12.6,15L14.68,18.12Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:e.attributeLocalValue===0?`Offline`:`Online`},`${e.clusterId}-${e.attributeId}`)),xn.includes(r)&&i.filter(e=>e.clusterName===`OnOff`&&e.attributeName===`onOff`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(He,{}),cluster:e,value:e.attributeLocalValue===!0?`On`:`Off`},`${e.clusterId}-${e.attributeId}`)),Sn.includes(r)&&i.filter(e=>e.clusterName===`OnOff`&&e.attributeName===`onOff`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M7.5,10.5A1.5,1.5 0 0,1 9,12A1.5,1.5 0 0,1 7.5,13.5C6.66,13.5 6,12.83 6,12A1.5,1.5 0 0,1 7.5,10.5M16.5,10.5A1.5,1.5 0 0,1 18,12A1.5,1.5 0 0,1 16.5,13.5A1.5,1.5 0 0,1 15,12A1.5,1.5 0 0,1 16.5,10.5M4.22,2H19.78C21,2 22,3 22,4.22V19.78A2.22,2.22 0 0,1 19.78,22H4.22C3,22 2,21 2,19.78V4.22A2.22,2.22 0 0,1 4.22,2M12,4A8,8 0 0,0 4,12A8,8 0 0,0 12,20A8,8 0 0,0 20,12A8,8 0 0,0 12,4Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:e.attributeLocalValue===!0?`On`:`Off`},`${e.clusterId}-${e.attributeId}`)),Cn.includes(r)&&i.filter(e=>e.clusterName===`OnOff`&&e.attributeName===`onOff`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M8 6V18H16V6H8M14 10H10V8H14V10M19.4 1.6C19 1.2 18.5 1 18 1H6C5.5 1 5 1.2 4.6 1.6C4.2 2 4 2.5 4 3V21C4 21.5 4.2 22 4.6 22.4C5 22.8 5.5 23 6 23H18C18.5 23 19 22.8 19.4 22.4C19.8 22 20 21.5 20 21V3C20 2.5 19.8 2 19.4 1.6M18 21H6V3H18V21Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:e.attributeLocalValue===!0?`On`:`Off`},`${e.clusterId}-${e.attributeId}`)),r===259&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M8 6V18H16V6H8M14 10H10V8H14V10M19.4 1.6C19 1.2 18.5 1 18 1H6C5.5 1 5 1.2 4.6 1.6C4.2 2 4 2.5 4 3V21C4 21.5 4.2 22 4.6 22.4C5 22.8 5.5 23 6 23H18C18.5 23 19 22.8 19.4 22.4C19.8 22 20 21.5 20 21V3C20 2.5 19.8 2 19.4 1.6M18 21H6V3H18V21Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:`Controller`},`${e.clusterId}-${e.attributeId}`)),r===260&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(He,{}),cluster:e,value:`Controller`},`${e.clusterId}-${e.attributeId}`)),r===261&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(He,{}),cluster:e,value:`Controller`},`${e.clusterId}-${e.attributeId}`)),r===2112&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(He,{}),cluster:e,value:`Controller`},`${e.clusterId}-${e.attributeId}`)),r===115&&i.filter(e=>e.clusterName===`OperationalState`&&e.attributeName===`operationalState`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M14.83,11.17C16.39,12.73 16.39,15.27 14.83,16.83C13.27,18.39 10.73,18.39 9.17,16.83L14.83,11.17M6,2H18A2,2 0 0,1 20,4V20A2,2 0 0,1 18,22H6A2,2 0 0,1 4,20V4A2,2 0 0,1 6,2M7,4A1,1 0 0,0 6,5A1,1 0 0,0 7,6A1,1 0 0,0 8,5A1,1 0 0,0 7,4M10,4A1,1 0 0,0 9,5A1,1 0 0,0 10,6A1,1 0 0,0 11,5A1,1 0 0,0 10,4M12,8A6,6 0 0,0 6,14A6,6 0 0,0 12,20A6,6 0 0,0 18,14A6,6 0 0,0 12,8Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:e.attributeLocalValue===0?`Normal`:`Error`},`${e.clusterId}-${e.attributeId}`)),r===124&&i.filter(e=>e.clusterName===`OperationalState`&&e.attributeName===`operationalState`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M6,2H18A2,2 0 0,1 20,4V20A2,2 0 0,1 18,22H6A2,2 0 0,1 4,20V4A2,2 0 0,1 6,2M7,4A1,1 0 0,0 6,5A1,1 0 0,0 7,6A1,1 0 0,0 8,5A1,1 0 0,0 7,4M10,4A1,1 0 0,0 9,5A1,1 0 0,0 10,6A1,1 0 0,0 11,5A1,1 0 0,0 10,4M12,8A6,6 0 0,0 6,14A6,6 0 0,0 12,20A6,6 0 0,0 18,14A6,6 0 0,0 12,8M8.11,10.5H10C9.76,11.88 10,12.67 10.58,13.29C11.68,14.36 12.16,15.71 11.89,17.5H10C10.24,16.12 10,15.33 9.42,14.71C8.32,13.64 7.85,12.29 8.11,10.5M12.11,10.5H14C13.76,11.88 14,12.67 14.58,13.29C15.68,14.36 16.16,15.71 15.89,17.5H14C14.24,16.12 14,15.33 13.42,14.71C12.32,13.64 11.85,12.29 12.11,10.5Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:e.attributeLocalValue===0?`Normal`:`Error`},`${e.clusterId}-${e.attributeId}`)),r===117&&i.filter(e=>e.clusterName===`OperationalState`&&e.attributeName===`operationalState`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M18,2H6A2,2 0 0,0 4,4V20A2,2 0 0,0 6,22H18A2,2 0 0,0 20,20V4A2,2 0 0,0 18,2M10,4A1,1 0 0,1 11,5A1,1 0 0,1 10,6A1,1 0 0,1 9,5A1,1 0 0,1 10,4M7,4A1,1 0 0,1 8,5A1,1 0 0,1 7,6A1,1 0 0,1 6,5A1,1 0 0,1 7,4M18,20H6V8H18V20M14.67,15.33C14.69,16.03 14.41,16.71 13.91,17.21C12.86,18.26 11.15,18.27 10.09,17.21C9.59,16.71 9.31,16.03 9.33,15.33C9.4,14.62 9.63,13.94 10,13.33C10.37,12.5 10.81,11.73 11.33,11L12,10C13.79,12.59 14.67,14.36 14.67,15.33`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:e.attributeLocalValue===0?`Normal`:`Error`},`${e.clusterId}-${e.attributeId}`)),r===123&&i.filter(e=>e.clusterName===`BridgedDeviceBasicInformation`&&e.attributeName===`reachable`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(l,{}),cluster:e,value:`Oven`},`${e.clusterId}-${e.attributeId}`)),r===112&&i.filter(e=>e.clusterName===`BridgedDeviceBasicInformation`&&e.attributeName===`reachable`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(De,{}),cluster:e,value:`Fridge`},`${e.clusterId}-${e.attributeId}`)),r===113&&i.filter(e=>e.clusterName===`TemperatureControl`&&e.attributeName===`temperatureSetpoint`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M5,3A2,2 0 0,0 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V5C21,3.89 20.1,3 19,3H5M12,5C13.57,5 15,5.5 16.19,6.4L14,8.56C13.43,8.21 12.74,8 12,8A4,4 0 0,0 8,12C8,13.1 8.45,14.1 9.17,14.83L7.05,16.95C5.78,15.68 5,13.93 5,12A7,7 0 0,1 12,5M17.6,7.81C18.5,9 19,10.43 19,12C19,13.93 18.22,15.68 16.95,16.95L14.83,14.83C15.55,14.1 16,13.1 16,12C16,11.26 15.79,10.57 15.43,10L17.6,7.81Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:(e.attributeLocalValue??0)/100,unit:`°C`},`${e.clusterId}-${e.attributeId}`)),r===113&&i.filter(e=>e.clusterName===`TemperatureControl`&&e.attributeName===`selectedTemperatureLevel`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M5,3A2,2 0 0,0 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V5C21,3.89 20.1,3 19,3H5M12,5C13.57,5 15,5.5 16.19,6.4L14,8.56C13.43,8.21 12.74,8 12,8A4,4 0 0,0 8,12C8,13.1 8.45,14.1 9.17,14.83L7.05,16.95C5.78,15.68 5,13.93 5,12A7,7 0 0,1 12,5M17.6,7.81C18.5,9 19,10.43 19,12C19,13.93 18.22,15.68 16.95,16.95L14.83,14.83C15.55,14.1 16,13.1 16,12C16,11.26 15.79,10.57 15.43,10L17.6,7.81Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:e.attributeLocalValue,unit:`mode`,prefix:!0},`${e.clusterId}-${e.attributeId}`)),r===121&&i.filter(e=>e.clusterName===`OperationalState`&&e.attributeName===`operationalState`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(l,{}),cluster:e,value:e.attributeLocalValue===0?`Normal`:`Error`},`${e.clusterId}-${e.attributeId}`)),r===122&&i.filter(e=>e.clusterName===`FanControl`&&e.attributeName===`fanMode`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M19,18.31V20A2,2 0 0,1 17,22H7A2,2 0 0,1 5,20V16.3C4.54,16.12 3.95,16 3,16A1,1 0 0,1 2,15A1,1 0 0,1 3,14C3.82,14 4.47,14.08 5,14.21V12.3C4.54,12.12 3.95,12 3,12A1,1 0 0,1 2,11A1,1 0 0,1 3,10C3.82,10 4.47,10.08 5,10.21V8.3C4.54,8.12 3.95,8 3,8A1,1 0 0,1 2,7A1,1 0 0,1 3,6C3.82,6 4.47,6.08 5,6.21V4A2,2 0 0,1 7,2H17A2,2 0 0,1 19,4V6.16C20.78,6.47 21.54,7.13 21.71,7.29C22.1,7.68 22.1,8.32 21.71,8.71C21.32,9.1 20.8,9.09 20.29,8.71V8.71C20.29,8.71 19.25,8 17,8C15.74,8 14.91,8.41 13.95,8.9C12.91,9.41 11.74,10 10,10C9.64,10 9.31,10 9,9.96V7.95C9.3,8 9.63,8 10,8C11.26,8 12.09,7.59 13.05,7.11C14.09,6.59 15.27,6 17,6V4H7V20H17V18C18.5,18 18.97,18.29 19,18.31M17,10C15.27,10 14.09,10.59 13.05,11.11C12.09,11.59 11.26,12 10,12C9.63,12 9.3,12 9,11.95V13.96C9.31,14 9.64,14 10,14C11.74,14 12.91,13.41 13.95,12.9C14.91,12.42 15.74,12 17,12C19.25,12 20.29,12.71 20.29,12.71V12.71C20.8,13.1 21.32,13.1 21.71,12.71C22.1,12.32 22.1,11.69 21.71,11.29C21.5,11.08 20.25,10 17,10M17,14C15.27,14 14.09,14.59 13.05,15.11C12.09,15.59 11.26,16 10,16C9.63,16 9.3,16 9,15.95V17.96C9.31,18 9.64,18 10,18C11.74,18 12.91,17.41 13.95,16.9C14.91,16.42 15.74,16 17,16C19.25,16 20.29,16.71 20.29,16.71V16.71C20.8,17.1 21.32,17.1 21.71,16.71C22.1,16.32 22.1,15.69 21.71,15.29C21.5,15.08 20.25,14 17,14Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:e.attributeLocalValue,unit:`mode`,prefix:!0},`${e.clusterId}-${e.attributeId}`)),r===120&&i.filter(e=>e.clusterName===`BridgedDeviceBasicInformation`&&e.attributeName===`reachable`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M6,14H8L11,17H9L6,14M4,4H5V3A1,1 0 0,1 6,2H10A1,1 0 0,1 11,3V4H13V3A1,1 0 0,1 14,2H18A1,1 0 0,1 19,3V4H20A2,2 0 0,1 22,6V19A2,2 0 0,1 20,21V22H17V21H7V22H4V21A2,2 0 0,1 2,19V6A2,2 0 0,1 4,4M18,7A1,1 0 0,1 19,8A1,1 0 0,1 18,9A1,1 0 0,1 17,8A1,1 0 0,1 18,7M14,7A1,1 0 0,1 15,8A1,1 0 0,1 14,9A1,1 0 0,1 13,8A1,1 0 0,1 14,7M20,6H4V10H20V6M4,19H20V12H4V19M6,7A1,1 0 0,1 7,8A1,1 0 0,1 6,9A1,1 0 0,1 5,8A1,1 0 0,1 6,7M13,14H15L18,17H16L13,14Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:`Cooktop`},`${e.clusterId}-${e.attributeId}`)),r===119&&i.filter(e=>e.clusterName===`TemperatureControl`&&e.attributeName===`selectedTemperatureLevel`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M6,14H8L11,17H9L6,14M4,4H5V3A1,1 0 0,1 6,2H10A1,1 0 0,1 11,3V4H13V3A1,1 0 0,1 14,2H18A1,1 0 0,1 19,3V4H20A2,2 0 0,1 22,6V19A2,2 0 0,1 20,21V22H17V21H7V22H4V21A2,2 0 0,1 2,19V6A2,2 0 0,1 4,4M18,7A1,1 0 0,1 19,8A1,1 0 0,1 18,9A1,1 0 0,1 17,8A1,1 0 0,1 18,7M14,7A1,1 0 0,1 15,8A1,1 0 0,1 14,9A1,1 0 0,1 13,8A1,1 0 0,1 14,7M20,6H4V10H20V6M4,19H20V12H4V19M6,7A1,1 0 0,1 7,8A1,1 0 0,1 6,9A1,1 0 0,1 5,8A1,1 0 0,1 6,7M13,14H15L18,17H16L13,14Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:e.attributeLocalValue,unit:`mode`,prefix:!0},`${e.clusterId}-${e.attributeId}`)),r===514&&i.filter(e=>e.clusterName===`WindowCovering`&&e.attributeName===`currentPositionLiftPercent100ths`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(tt,{}),cluster:e,value:On(e.attributeLocalValue)},`${e.clusterId}-${e.attributeId}`)),r===515&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(tt,{}),cluster:e,value:`Controller`},`${e.clusterId}-${e.attributeId}`)),r===560&&i.filter(e=>e.clusterName===`ClosureControl`&&e.attributeName===`overallCurrentState`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(tt,{}),cluster:e,value:Dn(e.attributeLocalValue)},`${e.clusterId}-${e.attributeId}`)),r===574&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(tt,{}),cluster:e,value:`Controller`},`${e.clusterId}-${e.attributeId}`)),r===561&&i.filter(e=>e.clusterName===`ClosureDimension`&&e.attributeName===`currentState`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(tt,{}),cluster:e,value:kn(e.attributeLocalValue)},`${e.clusterId}-${e.attributeId}`)),r===769&&i.filter(e=>e.clusterName===`Thermostat`&&e.attributeName===`localTemperature`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M16.95,16.95L14.83,14.83C15.55,14.1 16,13.1 16,12C16,11.26 15.79,10.57 15.43,10L17.6,7.81C18.5,9 19,10.43 19,12C19,13.93 18.22,15.68 16.95,16.95M12,5C13.57,5 15,5.5 16.19,6.4L14,8.56C13.43,8.21 12.74,8 12,8A4,4 0 0,0 8,12C8,13.1 8.45,14.1 9.17,14.83L7.05,16.95C5.78,15.68 5,13.93 5,12A7,7 0 0,1 12,5M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12C22,6.47 17.5,2 12,2Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:(e.attributeLocalValue??0)/100,unit:`°C`},`${e.clusterId}-${e.attributeId}`)),r===778&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M16.95,16.95L14.83,14.83C15.55,14.1 16,13.1 16,12C16,11.26 15.79,10.57 15.43,10L17.6,7.81C18.5,9 19,10.43 19,12C19,13.93 18.22,15.68 16.95,16.95M12,5C13.57,5 15,5.5 16.19,6.4L14,8.56C13.43,8.21 12.74,8 12,8A4,4 0 0,0 8,12C8,13.1 8.45,14.1 9.17,14.83L7.05,16.95C5.78,15.68 5,13.93 5,12A7,7 0 0,1 12,5M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12C22,6.47 17.5,2 12,2Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:`Controller`},`${e.clusterId}-${e.attributeId}`)),r===10&&i.filter(e=>e.clusterName===`DoorLock`&&e.attributeName===`lockState`).map(e=>(0,J.jsx)($,{icon:e.attributeValue===`1`?(0,J.jsx)(Ze,{}):(0,J.jsx)(ct,{}),cluster:e,value:e.attributeValue===`1`?`Locked`:`Unlocked`},`${e.clusterId}-${e.attributeId}`)),r===11&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(Ze,{}),cluster:e,value:`Controller`},`${e.clusterId}-${e.attributeId}`)),r===43&&i.filter(e=>e.clusterName===`FanControl`&&e.attributeName===`fanMode`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(Be,{}),cluster:e,value:un[e.attributeLocalValue]??`Unknown`},`${e.clusterId}-${e.attributeId}`)),r===15&&i.filter(e=>e.clusterName===`Switch`&&e.attributeName===`currentPosition`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M13 5C15.21 5 17 6.79 17 9C17 10.5 16.2 11.77 15 12.46V11.24C15.61 10.69 16 9.89 16 9C16 7.34 14.66 6 13 6S10 7.34 10 9C10 9.89 10.39 10.69 11 11.24V12.46C9.8 11.77 9 10.5 9 9C9 6.79 10.79 5 13 5M20 20.5C19.97 21.32 19.32 21.97 18.5 22H13C12.62 22 12.26 21.85 12 21.57L8 17.37L8.74 16.6C8.93 16.39 9.2 16.28 9.5 16.28H9.7L12 18V9C12 8.45 12.45 8 13 8S14 8.45 14 9V13.47L15.21 13.6L19.15 15.79C19.68 16.03 20 16.56 20 17.14V20.5M20 2H4C2.9 2 2 2.9 2 4V12C2 13.11 2.9 14 4 14H8V12L4 12L4 4H20L20 12H18V14H20V13.96L20.04 14C21.13 14 22 13.09 22 12V4C22 2.9 21.11 2 20 2Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:e.attributeValue,unit:`pos`,prefix:!0},`${e.clusterId}-${e.attributeId}`)),r===39&&i.filter(e=>e.clusterName===`ModeSelect`&&e.attributeName===`currentMode`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(Ie,{}),cluster:e,value:e.attributeValue,unit:`Mode`,prefix:!0},`${e.clusterId}-${e.attributeId}`)),r===771&&i.filter(e=>e.clusterName===`OnOff`&&e.attributeName===`onOff`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(Me,{}),cluster:e,value:e.attributeLocalValue===!0?`On`:`Off`},`${e.clusterId}-${e.attributeId}`)),r===772&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(Me,{}),cluster:e,value:`Controller`},`${e.clusterId}-${e.attributeId}`)),r===45&&i.filter(e=>e.clusterName===`FanControl`&&e.attributeName===`fanMode`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)($e,{}),cluster:e,value:un[e.attributeLocalValue]??`Unknown`},`${e.clusterId}-${e.attributeId}`)),r===114&&i.filter(e=>e.clusterName===`Thermostat`&&e.attributeName===`localTemperature`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)($e,{}),cluster:e,value:(e.attributeLocalValue??0)/100,unit:`°C`},`${e.clusterId}-${e.attributeId}`)),r===67&&i.filter(e=>e.clusterName===`BooleanState`&&e.attributeName===`stateValue`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(j,{}),cluster:e,value:e.attributeLocalValue===!0?`Leak`:`No leak`},`${e.clusterId}-${e.attributeId}`)),r===65&&i.filter(e=>e.clusterName===`BooleanState`&&e.attributeName===`stateValue`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(Re,{}),cluster:e,value:e.attributeLocalValue===!0?`Freeze`:`No freeze`},`${e.clusterId}-${e.attributeId}`)),r===68&&i.filter(e=>e.clusterName===`BooleanState`&&e.attributeName===`stateValue`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(k,{}),cluster:e,value:e.attributeLocalValue===!0?`Rain`:`No rain`},`${e.clusterId}-${e.attributeId}`)),r===116&&i.filter(e=>e.clusterName===`RvcRunMode`&&e.attributeName===`currentMode`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M12,2C14.65,2 17.19,3.06 19.07,4.93L17.65,6.35C16.15,4.85 14.12,4 12,4C9.88,4 7.84,4.84 6.35,6.35L4.93,4.93C6.81,3.06 9.35,2 12,2M3.66,6.5L5.11,7.94C4.39,9.17 4,10.57 4,12A8,8 0 0,0 12,20A8,8 0 0,0 20,12C20,10.57 19.61,9.17 18.88,7.94L20.34,6.5C21.42,8.12 22,10.04 22,12A10,10 0 0,1 12,22A10,10 0 0,1 2,12C2,10.04 2.58,8.12 3.66,6.5M12,6A6,6 0 0,1 18,12C18,13.59 17.37,15.12 16.24,16.24L14.83,14.83C14.08,15.58 13.06,16 12,16C10.94,16 9.92,15.58 9.17,14.83L7.76,16.24C6.63,15.12 6,13.59 6,12A6,6 0 0,1 12,6M12,8A1,1 0 0,0 11,9A1,1 0 0,0 12,10A1,1 0 0,0 13,9A1,1 0 0,0 12,8Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:e.attributeValue,unit:`Run mode`,prefix:!0},`${e.clusterId}-${e.attributeId}`)),r===1292&&i.filter(e=>e.clusterName===`EnergyEvse`&&e.attributeName===`state`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M19.77,7.23L19.78,7.22L16.06,3.5L15,4.56L17.11,6.67C16.17,7.03 15.5,7.93 15.5,9A2.5,2.5 0 0,0 18,11.5C18.36,11.5 18.69,11.42 19,11.29V18.5A1,1 0 0,1 18,19.5A1,1 0 0,1 17,18.5V14A2,2 0 0,0 15,12H14V5A2,2 0 0,0 12,3H6A2,2 0 0,0 4,5V21H14V13.5H15.5V18.5A2.5,2.5 0 0,0 18,21A2.5,2.5 0 0,0 20.5,18.5V9C20.5,8.31 20.22,7.68 19.77,7.23M18,10A1,1 0 0,1 17,9A1,1 0 0,1 18,8A1,1 0 0,1 19,9A1,1 0 0,1 18,10M8,18V13.5H6L10,6V11H12L8,18Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:e.attributeLocalValue===0?`Free`:`In use`},`${e.clusterId}-${e.attributeId}`)),r===1295&&i.filter(e=>e.clusterName===`WaterHeaterManagement`&&e.attributeName===`tankPercentage`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M8 2C6.89 2 6 2.89 6 4V16C6 17.11 6.89 18 8 18H9V20H6V22H9C10.11 22 11 21.11 11 20V18H13V20C13 21.11 13.89 22 15 22H18V20H15V18H16C17.11 18 18 17.11 18 16V4C18 2.89 17.11 2 16 2H8M12 4.97A2 2 0 0 1 14 6.97A2 2 0 0 1 12 8.97A2 2 0 0 1 10 6.97A2 2 0 0 1 12 4.97M10 14.5H14V16H10V14.5Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:`Tank `+(e.attributeLocalValue??0)+`%`},`${e.clusterId}-${e.attributeId}`)),r===1297&&i.filter(e=>e.clusterName===`MeterIdentification`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M21 11C21 6.03 16.97 2 12 2S3 6.03 3 11C3 14.92 5.5 18.24 9 19.5V22H11V19.94C11.33 20 11.66 20 12 20S12.67 20 13 19.94V22H15V19.5C18.5 18.24 21 14.92 21 11M12 18C8.14 18 5 14.86 5 11S8.14 4 12 4 19 7.14 19 11 15.86 18 12 18M8 7H16V9H8V7M12.75 10L9.75 13L11 14.25L9.75 15.5L11.25 17L14.25 14L13 12.75L14.25 11.5L12.75 10Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:`Utility`},`${e.clusterId}-${e.attributeId}`)),r===1298&&i.filter(e=>e.clusterName===`MeterIdentification`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M21 11C21 6.03 16.97 2 12 2S3 6.03 3 11C3 14.92 5.5 18.24 9 19.5V22H11V19.94C11.33 20 11.66 20 12 20S12.67 20 13 19.94V22H15V19.5C18.5 18.24 21 14.92 21 11M12 18C8.14 18 5 14.86 5 11S8.14 4 12 4 19 7.14 19 11 15.86 18 12 18M8 7H16V9H8V7M12.75 10L9.75 13L11 14.25L9.75 15.5L11.25 17L14.25 14L13 12.75L14.25 11.5L12.75 10Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:`Reference`},`${e.clusterId}-${e.attributeId}`)),r===1299&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M21 11C21 6.03 16.97 2 12 2S3 6.03 3 11C3 14.92 5.5 18.24 9 19.5V22H11V19.94C11.33 20 11.66 20 12 20S12.67 20 13 19.94V22H15V19.5C18.5 18.24 21 14.92 21 11M12 18C8.14 18 5 14.86 5 11S8.14 4 12 4 19 7.14 19 11 15.86 18 12 18M8 7H16V9H8V7M12.75 10L9.75 13L11 14.25L9.75 15.5L11.25 17L14.25 14L13 12.75L14.25 11.5L12.75 10Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:`Tariff`},`${e.clusterId}-${e.attributeId}`)),r===1300&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M21 11C21 6.03 16.97 2 12 2S3 6.03 3 11C3 14.92 5.5 18.24 9 19.5V22H11V19.94C11.33 20 11.66 20 12 20S12.67 20 13 19.94V22H15V19.5C18.5 18.24 21 14.92 21 11M12 18C8.14 18 5 14.86 5 11S8.14 4 12 4 19 7.14 19 11 15.86 18 12 18M8 7H16V9H8V7M12.75 10L9.75 13L11 14.25L9.75 15.5L11.25 17L14.25 14L13 12.75L14.25 11.5L12.75 10Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:`Meter`},`${e.clusterId}-${e.attributeId}`)),r===777&&i.filter(e=>e.clusterName===`PowerSource`&&e.attributeName===`featureMap`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M19 3H5C3.9 3 3 3.9 3 5V19C3 20.1 3.9 21 5 21H19C20.1 21 21 20.1 21 19V5C21 3.9 20.1 3 19 3M12.75 7.08C13.57 7.2 14.32 7.5 14.95 8L12.75 10.19V7.08M11.25 7.08V10.19L9.05 8C9.68 7.5 10.43 7.2 11.25 7.08M8 9.05L10.19 11.25H7.08C7.2 10.43 7.5 9.68 8 9.05M7.08 12.75H10.19L8 14.95C7.5 14.32 7.2 13.57 7.08 12.75M11.25 16.92C10.43 16.8 9.68 16.5 9.05 16L11.25 13.81V16.92M12 13C11.45 13 11 12.55 11 12S11.45 11 12 11 13 11.45 13 12 12.55 13 12 13M12.75 16.92V13.81L14.95 16C14.32 16.5 13.57 16.8 12.75 16.92M16 14.95L13.81 12.75H16.92C16.8 13.57 16.5 14.32 16 14.95M13.81 11.25L16 9.05C16.5 9.69 16.8 10.44 16.92 11.25H13.81Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:`HeatPump`},`${e.clusterId}-${e.attributeId}`)),r===23&&i.filter(e=>e.clusterName===`PowerSource`&&e.attributeName===`featureMap`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M4,2H20A2,2 0 0,1 22,4V14A2,2 0 0,1 20,16H15V20H18V22H13V16H11V22H6V20H9V16H4A2,2 0 0,1 2,14V4A2,2 0 0,1 4,2M4,4V8H11V4H4M4,14H11V10H4V14M20,14V10H13V14H20M20,4H13V8H20V4Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:`Solar`},`${e.clusterId}-${e.attributeId}`)),r===24&&i.filter(e=>e.clusterName===`ElectricalPowerMeasurement`&&e.attributeName===`featureMap`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M12 20L5 20V12H2L12 3L14.78 5.5H14V7.17C12.84 7.58 12 8.7 12 10V20M15 9H16V7.5H20V9H21C21.55 9 22 9.45 22 10V21C22 21.55 21.55 22 21 22H15C14.45 22 14 21.55 14 21V10C14 9.45 14.45 9 15 9M16 11V14H20V11H16Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:`Inverter`},`${e.clusterId}-${e.attributeId}`)),r===40&&i.filter(e=>e.clusterName===`OnOff`&&e.attributeName===`onOff`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M21,17H3V5H21M21,3H3A2,2 0 0,0 1,5V17A2,2 0 0,0 3,19H8V21H16V19H21A2,2 0 0,0 23,17V5A2,2 0 0,0 21,3Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:e.attributeLocalValue===!0?`On`:`Off`},`${e.clusterId}-${e.attributeId}`)),r===35&&i.filter(e=>e.clusterName===`OnOff`&&e.attributeName===`onOff`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M21,17H3V5H21M21,3H3A2,2 0 0,0 1,5V17A2,2 0 0,0 3,19H8V21H16V19H21A2,2 0 0,0 23,17V5A2,2 0 0,0 21,3Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:e.attributeLocalValue===!0?`On`:`Off`},`${e.clusterId}-${e.attributeId}`)),r===34&&i.filter(e=>e.clusterName===`OnOff`&&e.attributeName===`onOff`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M14,3.23V5.29C16.89,6.15 19,8.83 19,12C19,15.17 16.89,17.84 14,18.7V20.77C18,19.86 21,16.28 21,12C21,7.72 18,4.14 14,3.23M16.5,12C16.5,10.23 15.5,8.71 14,7.97V16C15.5,15.29 16.5,13.76 16.5,12M3,9V15H7L12,20V4L7,9H3Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:e.attributeLocalValue===!0?`On`:`Off`},`${e.clusterId}-${e.attributeId}`)),r===41&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M21,17H3V5H21M21,3H3A2,2 0 0,0 1,5V17A2,2 0 0,0 3,19H8V21H16V19H21A2,2 0 0,0 23,17V5A2,2 0 0,0 21,3Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:`Controller`},`${e.clusterId}-${e.attributeId}`)),r===42&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M21,17H3V5H21M21,3H3A2,2 0 0,0 1,5V17A2,2 0 0,0 3,19H8V21H16V19H21A2,2 0 0,0 23,17V5A2,2 0 0,0 21,3Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:`Controller`},`${e.clusterId}-${e.attributeId}`)),r===36&&i.filter(e=>e.clusterName===`ApplicationBasic`&&e.attributeName===`applicationName`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M21,17H3V5H21M21,3H3A2,2 0 0,0 1,5V17A2,2 0 0,0 3,19H8V21H16V19H21A2,2 0 0,0 23,17V5A2,2 0 0,0 21,3Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:`App`},`${e.clusterId}-${e.attributeId}`)),r===14&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M10,2C8.89,2 8,2.89 8,4V7C8,8.11 8.89,9 10,9H11V11H2V13H6V15H5C3.89,15 3,15.89 3,17V20C3,21.11 3.89,22 5,22H9C10.11,22 11,21.11 11,20V17C11,15.89 10.11,15 9,15H8V13H16V15H15C13.89,15 13,15.89 13,17V20C13,21.11 13.89,22 15,22H19C20.11,22 21,21.11 21,20V17C21,15.89 20.11,15 19,15H18V13H22V11H13V9H14C15.11,9 16,8.11 16,7V4C16,2.89 15.11,2 14,2H10M10,4H14V7H10V4M5,17H9V20H5V17M15,17H19V20H15V17Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:`Aggregator`},`${e.clusterId}-${e.attributeId}`)),r===322&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(nt,{}),cluster:e,value:`Camera`},`${e.clusterId}-${e.attributeId}`)),r===324&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(nt,{}),cluster:e,value:`Floodlight`},`${e.clusterId}-${e.attributeId}`)),r===323&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(nt,{}),cluster:e,value:`Video bell`},`${e.clusterId}-${e.attributeId}`)),r===320&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(nt,{}),cluster:e,value:`Intercom`},`${e.clusterId}-${e.attributeId}`)),r===325&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(nt,{}),cluster:e,value:`Snapshot`},`${e.clusterId}-${e.attributeId}`)),r===327&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(nt,{}),cluster:e,value:`Controller`},`${e.clusterId}-${e.attributeId}`)),r===326&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(se,{}),cluster:e,value:`Chime`},`${e.clusterId}-${e.attributeId}`)),r===328&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(se,{}),cluster:e,value:`Doorbell`},`${e.clusterId}-${e.attributeId}`)),r===321&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(se,{}),cluster:e,value:`Audio bell`},`${e.clusterId}-${e.attributeId}`)),r===118&&i.find(e=>e.clusterName===`SmokeCoAlarm`&&e.attributeName===`featureMap`&&e.attributeLocalValue.smokeAlarm===!0)&&i.filter(e=>e.clusterName===`SmokeCoAlarm`&&e.attributeName===`smokeState`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M12 4C16.41 4 20 7.59 20 12S16.41 20 12 20 4 16.41 4 12 7.59 4 12 4M12 2C6.5 2 2 6.5 2 12S6.5 22 12 22 22 17.5 22 12 17.5 2 12 2M12 11C11.45 11 11 11.45 11 12S11.45 13 12 13 13 12.55 13 12 12.55 11 12 11M10.72 9.3C11.11 9.11 11.54 9 12 9S12.89 9.11 13.29 9.3L14 8.57C13.43 8.22 12.74 8 12 8S10.58 8.22 10 8.57L10.72 9.3M15 12C15 12.46 14.89 12.89 14.7 13.29L15.43 14C15.79 13.43 16 12.74 16 12S15.79 10.58 15.43 10L14.7 10.72C14.89 11.11 15 11.54 15 12M9 12C9 11.54 9.11 11.11 9.3 10.72L8.57 10C8.22 10.58 8 11.26 8 12S8.22 13.43 8.57 14L9.3 13.29C9.11 12.89 9 12.46 9 12M13.29 14.7C12.89 14.89 12.46 15 12 15S11.11 14.89 10.72 14.7L10 15.43C10.58 15.79 11.26 16 12 16S13.43 15.79 14 15.43L13.29 14.7M16.89 8.53L16.17 9.25C16.69 10.04 17 11 17 12S16.69 13.96 16.17 14.75L16.89 15.47C17.59 14.5 18 13.3 18 12S17.59 9.5 16.89 8.53M9.25 7.83C10.04 7.31 11 7 12 7S13.96 7.31 14.75 7.83L15.47 7.11C14.5 6.42 13.3 6 12 6S9.5 6.42 8.53 7.11L9.25 7.83M14.75 16.17C13.96 16.69 13 17 12 17S10.04 16.69 9.25 16.17L8.53 16.89C9.5 17.59 10.7 18 12 18S14.5 17.59 15.47 16.89L14.75 16.17M7.83 14.75C7.31 13.96 7 13 7 12S7.31 10.04 7.83 9.25L7.11 8.53C6.42 9.5 6 10.7 6 12S6.42 14.5 7.11 15.47L7.83 14.75Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:e.attributeLocalValue===0?`No smoke`:`Smoke!`},`${e.clusterId}-${e.attributeId}`)),r===118&&i.find(e=>e.clusterName===`SmokeCoAlarm`&&e.attributeName===`featureMap`&&e.attributeLocalValue.smokeAlarm===!1)&&i.filter(e=>e.clusterName===`SmokeCoAlarm`&&e.attributeName===`coState`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M12 4C16.41 4 20 7.59 20 12S16.41 20 12 20 4 16.41 4 12 7.59 4 12 4M12 2C6.5 2 2 6.5 2 12S6.5 22 12 22 22 17.5 22 12 17.5 2 12 2M12 11C11.45 11 11 11.45 11 12S11.45 13 12 13 13 12.55 13 12 12.55 11 12 11M10.72 9.3C11.11 9.11 11.54 9 12 9S12.89 9.11 13.29 9.3L14 8.57C13.43 8.22 12.74 8 12 8S10.58 8.22 10 8.57L10.72 9.3M15 12C15 12.46 14.89 12.89 14.7 13.29L15.43 14C15.79 13.43 16 12.74 16 12S15.79 10.58 15.43 10L14.7 10.72C14.89 11.11 15 11.54 15 12M9 12C9 11.54 9.11 11.11 9.3 10.72L8.57 10C8.22 10.58 8 11.26 8 12S8.22 13.43 8.57 14L9.3 13.29C9.11 12.89 9 12.46 9 12M13.29 14.7C12.89 14.89 12.46 15 12 15S11.11 14.89 10.72 14.7L10 15.43C10.58 15.79 11.26 16 12 16S13.43 15.79 14 15.43L13.29 14.7M16.89 8.53L16.17 9.25C16.69 10.04 17 11 17 12S16.69 13.96 16.17 14.75L16.89 15.47C17.59 14.5 18 13.3 18 12S17.59 9.5 16.89 8.53M9.25 7.83C10.04 7.31 11 7 12 7S13.96 7.31 14.75 7.83L15.47 7.11C14.5 6.42 13.3 6 12 6S9.5 6.42 8.53 7.11L9.25 7.83M14.75 16.17C13.96 16.69 13 17 12 17S10.04 16.69 9.25 16.17L8.53 16.89C9.5 17.59 10.7 18 12 18S14.5 17.59 15.47 16.89L14.75 16.17M7.83 14.75C7.31 13.96 7 13 7 12S7.31 10.04 7.83 9.25L7.11 8.53C6.42 9.5 6 10.7 6 12S6.42 14.5 7.11 15.47L7.83 14.75Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:e.attributeLocalValue===0?`No Co`:`Co!`},`${e.clusterId}-${e.attributeId}`)),r===66&&i.filter(e=>e.clusterName===`ValveConfigurationAndControl`&&e.attributeName===`currentState`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M4 22H2V2H4M22 2H20V22H22M17.24 5.34L13.24 9.34A3 3 0 0 0 9.24 13.34L5.24 17.34L6.66 18.76L10.66 14.76A3 3 0 0 0 14.66 10.76L18.66 6.76Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:e.attributeLocalValue===0?`Closed`:`Opened`},`${e.clusterId}-${e.attributeId}`)),r===64&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M10 10H14V22H10V10M7 9H9V7H7V9M4 8H6V6H4V8M4 11H6V9H4V11M1 13H3V11H1V13M1 7H3V5H1V7M1 10H3V8H1V10M18 11H20V9H18V11M21 10H23V8H21V10M21 5V7H23V5H21M21 13H23V11H21V13M15 9H17V7H15V9M18 8H20V6H18V8M10 7H10.33L11 9H13L13.67 7H14V6H10V7Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:`Irrigation`},`${e.clusterId}-${e.attributeId}`)),r===44&&i.filter(e=>e.clusterName===`AirQuality`&&e.attributeName===`airQuality`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M11,9A4,4 0 0,1 15,13A4,4 0 0,1 11,17A4,4 0 0,1 7,13A4,4 0 0,1 11,9M11,11A2,2 0 0,0 9,13A2,2 0 0,0 11,15A2,2 0 0,0 13,13A2,2 0 0,0 11,11M7,4H14A4,4 0 0,1 18,8V9H16V8A2,2 0 0,0 14,6H7A2,2 0 0,0 5,8V20H16V18H18V22H3V8A4,4 0 0,1 7,4M16,11C18.5,11 18.5,9 21,9V11C18.5,11 18.5,13 16,13V11M16,15C18.5,15 18.5,13 21,13V15C18.5,15 18.5,17 16,17V15Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:a[e.attributeLocalValue??0]},`${e.clusterId}-${e.attributeId}`)),r===770&&i.filter(e=>e.clusterName===`TemperatureMeasurement`&&e.attributeName===`measuredValue`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(be,{}),cluster:e,value:e.attributeLocalValue/100,unit:`°C`},`${e.clusterId}-${e.attributeId}`)),r===775&&i.filter(e=>e.clusterName===`RelativeHumidityMeasurement`&&e.attributeName===`measuredValue`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M12,3.25C12,3.25 6,10 6,14C6,17.32 8.69,20 12,20A6,6 0 0,0 18,14C18,10 12,3.25 12,3.25M14.47,9.97L15.53,11.03L9.53,17.03L8.47,15.97M9.75,10A1.25,1.25 0 0,1 11,11.25A1.25,1.25 0 0,1 9.75,12.5A1.25,1.25 0 0,1 8.5,11.25A1.25,1.25 0 0,1 9.75,10M14.25,14.5A1.25,1.25 0 0,1 15.5,15.75A1.25,1.25 0 0,1 14.25,17A1.25,1.25 0 0,1 13,15.75A1.25,1.25 0 0,1 14.25,14.5Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:e.attributeLocalValue/100,unit:`%`},`${e.clusterId}-${e.attributeId}`)),r===69&&i.filter(e=>e.clusterName===`SoilMeasurement`&&e.attributeName===`soilMoistureMeasuredValue`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M12,3.25C12,3.25 6,10 6,14C6,17.32 8.69,20 12,20A6,6 0 0,0 18,14C18,10 12,3.25 12,3.25M14.47,9.97L15.53,11.03L9.53,17.03L8.47,15.97M9.75,10A1.25,1.25 0 0,1 11,11.25A1.25,1.25 0 0,1 9.75,12.5A1.25,1.25 0 0,1 8.5,11.25A1.25,1.25 0 0,1 9.75,10M14.25,14.5A1.25,1.25 0 0,1 15.5,15.75A1.25,1.25 0 0,1 14.25,17A1.25,1.25 0 0,1 13,15.75A1.25,1.25 0 0,1 14.25,14.5Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:e.attributeLocalValue,unit:`%`},`${e.clusterId}-${e.attributeId}`)),r===774&&i.filter(e=>e.clusterName===`FlowMeasurement`&&e.attributeName===`measuredValue`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(ot,{}),cluster:e,value:e.attributeLocalValue/10,unit:`m³/h`},`${e.clusterId}-${e.attributeId}`)),r===773&&i.filter(e=>e.clusterName===`PressureMeasurement`&&e.attributeName===`measuredValue`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(Ae,{}),cluster:e,value:e.attributeLocalValue,unit:`hPa`},`${e.clusterId}-${e.attributeId}`)),r===21&&i.filter(e=>e.clusterName===`BooleanState`&&e.attributeName===`stateValue`).map(e=>(0,J.jsx)($,{icon:e.attributeValue===`true`?(0,J.jsx)(ut,{}):(0,J.jsx)(Pe,{}),cluster:e,value:e.attributeValue===`true`?`Closed`:`Opened`},`${e.clusterId}-${e.attributeId}`)),r===263&&i.filter(e=>e.clusterName===`OccupancySensing`&&e.attributeName===`occupancy`).map(e=>(0,J.jsx)($,{icon:e.attributeValue===`{ occupied: true }`?(0,J.jsx)(Se,{}):(0,J.jsx)(ye,{}),cluster:e,value:e.attributeValue===`{ occupied: true }`?`Occupied`:`Unocc.`},`${e.clusterId}-${e.attributeId}`)),r===262&&i.filter(e=>e.clusterName===`IlluminanceMeasurement`&&e.attributeName===`measuredValue`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(it,{}),cluster:e,value:Math.round(10**(e.attributeLocalValue/1e4)),unit:`lx`},`${e.clusterId}-${e.attributeId}`)),r===2128&&i.filter(e=>e.clusterName===`Descriptor`&&e.attributeName===`clusterRevision`).map(e=>(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M8 6V18H16V6H8M14 10H10V8H14V10M19.4 1.6C19 1.2 18.5 1 18 1H6C5.5 1 5 1.2 4.6 1.6C4.2 2 4 2.5 4 3V21C4 21.5 4.2 22 4.6 22.4C5 22.8 5.5 23 6 23H18C18.5 23 19 22.8 19.4 22.4C19.8 22 20 21.5 20 21V3C20 2.5 19.8 2 19.4 1.6M18 21H6V3H18V21Z`,size:`40px`,color:`var(--primary-color)`}),cluster:e,value:`---`},`${e.clusterId}-${e.attributeId}`)),r===1296&&p&&(0,J.jsx)($,{icon:(0,J.jsx)(X.Icon,{path:`M21 11C21 6.03 16.97 2 12 2S3 6.03 3 11C3 14.92 5.5 18.24 9 19.5V22H11V19.94C11.33 20 11.66 20 12 20S12.67 20 13 19.94V22H15V19.5C18.5 18.24 21 14.92 21 11M12 18C8.14 18 5 14.86 5 11S8.14 4 12 4 19 7.14 19 11 15.86 18 12 18M8 7H16V9H8V7M12.75 10L9.75 13L11 14.25L9.75 15.5L11.25 17L14.25 14L13 12.75L14.25 11.5L12.75 10Z`,size:`40px`,color:`var(--primary-color)`}),cluster:p,value:m,unit:`kWh`},`${p.clusterId}-${p.attributeId}`),(0,J.jsx)(V,{sx:hn,children:(0,J.jsx)(A,{sx:gn,children:o})}),(0,J.jsx)(V,{sx:_n,children:(0,J.jsx)(A,{sx:vn,children:e.deviceName})}),(0,J.jsxs)(V,{sx:yn,children:[K&&(0,J.jsx)(A,{sx:bn,children:t}),(0,J.jsx)(A,{sx:bn,children:n}),K&&(0,J.jsxs)(A,{sx:bn,children:[`0x`,r.toString(16).padStart(4,`0`)]})]})]})}var jn=(0,U.memo)(An);function Mn({filterPlugins:e,filterDevices:t}){let{online:n,sendMessage:r,addListener:i,removeListener:a,getUniqueId:o}=(0,U.useContext)(Y),[s,c]=(0,U.useState)([]),[l,u]=(0,U.useState)({}),[d,f]=(0,U.useState)({}),p=(0,U.useRef)(o()),m=(0,U.useRef)(s);(0,U.useEffect)(()=>{m.current=s},[s]);let h=(0,U.useRef)(d);(0,U.useEffect)(()=>{h.current=d},[d]);let g=(0,U.useCallback)(e=>{K&&console.log(`DevicesIcons received state_update "${e.response.cluster}.${e.response.attribute}" for "${e.response.id}:${e.response.number}": "${e.response.value}"`,e.response);let t=m.current,n=h.current,r=t.find(t=>t.plugin===e.response.plugin&&t.serialNumber===e.response.serialNumber);if(!r){K&&console.warn(`DevicesIcons updater device of plugin "${e.response.plugin}" serial "${e.response.serialNumber}" number "${e.response.number}" id "${e.response.id}" not found in devices(${t.length})`);return}let i=n[r.serialNumber]?.find(t=>t.endpoint===e.response.number.toString()&&t.clusterName===e.response.cluster&&t.attributeName===e.response.attribute);i?(i.attributeValue=String(e.response.value),i.attributeLocalValue=e.response.value,f(e=>({...e})),K&&console.log(`DevicesIcons updated "${i.clusterName}.${i.attributeName}" for device "${r.deviceName}" serial "${r.serialNumber}" to "${i.attributeValue}"`)):K&&console.warn(`DevicesIcons updater device "${r.deviceName}" serial "${r.serialNumber}" cluster "${e.response.cluster}" attribute "${e.response.attribute}" not found in clusters(${n[r.serialNumber]?.length})`)},[]),_=(0,U.useCallback)(e=>{if(K&&console.log(`DevicesIcons received for device "${e.response.deviceName}" serial "${e.response.serialNumber}" deviceTypes (${e.response.deviceTypes.length}) "${e.response.deviceTypes.join(`,`)}" clusters (${e.response.clusters.length}):`,e.response),e.response.clusters.length===0)return;let t=e.response.serialNumber,n=[],r=[];for(let t of e.response.clusters)n.find(e=>e.endpoint===t.endpoint)||n.push({endpoint:t.endpoint,id:t.id,deviceTypes:t.deviceTypes}),![`FixedLabel`,`Identify`,`Groups`,`ScenesManagement`,`PowerTopology`].includes(t.clusterName)&&r.push(t);u(e=>({...e,[t]:n})),f(e=>({...e,[t]:r})),K&&console.log(`DevicesIcons endpoints for "${t}":`,n),K&&console.log(`DevicesIcons deviceTypes for "${t}":`,e.response.deviceTypes),K&&console.log(`DevicesIcons clusters for "${t}":`,r)},[]);(0,U.useEffect)(()=>{let e=e=>{if(e.method===`refresh_required`)K&&console.log(`DevicesIcons received refresh_required: changed=${e.response.changed} and sending api requests`),r({id:p.current,sender:`DevicesIcons`,method:`/api/devices`,src:`Frontend`,dst:`Matterbridge`,params:{extended:!1}});else if(e.method===`state_update`&&e.response)g(e);else if(e.method===`/api/devices`&&e.response){K&&console.log(`DevicesIcons received ${e.response.length} devices:`,e.response),c(e.response),u({}),f({});for(let t of e.response)K&&console.log(`DevicesIcons sending /api/clusters`),r({id:p.current,sender:`DevicesIcons`,method:`/api/clusters`,src:`Frontend`,dst:`Matterbridge`,params:{pluginName:t.plugin,number:t.number||0,serialNumber:t.serialNumber,uniqueId:t.uniqueId}})}else e.method===`/api/clusters`&&e.response&&_(e)};return i(e,p.current),K&&console.log(`DevicesIcons WebSocket effect mounted`),()=>{a(e),K&&console.log(`DevicesIcons WebSocket effect unmounted`)}},[i,_,a,r,g]),(0,U.useEffect)(()=>(K&&console.log(`DevicesIcons useEffect online mounting`),n&&(K&&console.log(`DevicesIcons useEffect online sending api requests`),r({id:p.current,sender:`DevicesIcons`,method:`/api/devices`,src:`Frontend`,dst:`Matterbridge`,params:{extended:!1}})),K&&console.log(`DevicesIcons useEffect online mounted`),()=>{K&&console.log(`DevicesIcons useEffect online unmounted`)}),[n,r]);let v=e?.trim().toLowerCase(),y=v&&v!==`all plugins`;return K&&console.log(`DevicesIcons rendering...`),(0,J.jsx)(`div`,{style:{display:`flex`,flexWrap:`wrap`,paddingBottom:`5px`,gap:`20px`,width:`100%`,overflow:`auto`},children:s.filter(e=>y&&e.plugin.toLowerCase()!==v?!1:t===``||e.deviceName.toLowerCase().includes(t.toLowerCase())||e.serialNumber.toLowerCase().includes(t.toLowerCase())).map(e=>l[e.serialNumber]&&l[e.serialNumber].map(t=>t.deviceTypes.map(n=>(0,J.jsx)(jn,{device:e,endpoint:t.endpoint,id:t.id,deviceType:n,clusters:(d[e.serialNumber]??[]).filter(e=>e.endpoint===t.endpoint)},`${e.plugin}-${e.uniqueId}-${t.endpoint}-${t.id}-${n.toString()}`))))})}var Nn=(0,U.memo)(Mn),Pn=e=>`0x${e.toString(16).padStart(4,`0`)}`,Fn=e=>`ep:${e}`,In=(e,t)=>`cl:${e}::${t}`,Ln=(e,t,n)=>`at:${e}::${t}::${n}`;function Rn(e){let t=new Map;for(let n of e){let e=t.get(n.endpoint);e||(e={endpoint:n.endpoint,id:n.id,deviceTypes:n.deviceTypes,clusters:[]},t.set(n.endpoint,e));let r=e.clusters.find(e=>e.name===n.clusterName);r||(r={name:n.clusterName,id:n.clusterId,attributes:[]},e.clusters.push(r)),r.attributes.push(n)}return[...t.values()]}var zn=(e,t)=>({display:`flex`,alignItems:`center`,gap:`4px`,padding:`2px 8px 2px ${8+t*16}px`,cursor:`pointer`,whiteSpace:`nowrap`,overflow:`hidden`,textOverflow:`ellipsis`,fontSize:`14px`,backgroundColor:e?`var(--table-selected-bg-color)`:`transparent`}),Bn={color:`var(--secondary-color)`,paddingRight:`16px`,verticalAlign:`top`,whiteSpace:`nowrap`};function Vn({label:e,children:t}){return(0,J.jsxs)(`tr`,{children:[(0,J.jsx)(`td`,{style:Bn,children:e}),(0,J.jsx)(`td`,{style:{wordBreak:`break-all`},children:t})]})}function Hn({node:e}){if(!e)return(0,J.jsx)(`div`,{style:{padding:`10px`,color:`var(--secondary-color)`},children:`Select a node in the tree to see its details.`});if(e.kind===`endpoint`)return(0,J.jsxs)(`div`,{style:{padding:`10px`},children:[(0,J.jsxs)(`h3`,{style:{margin:`0 0 8px 0`},children:[`Endpoint `,e.group.endpoint]}),(0,J.jsx)(`table`,{children:(0,J.jsxs)(`tbody`,{children:[(0,J.jsx)(Vn,{label:`Id`,children:e.group.id}),(0,J.jsx)(Vn,{label:`Device types`,children:e.group.deviceTypes.map(Pn).join(`, `)}),(0,J.jsx)(Vn,{label:`Clusters`,children:e.group.clusters.length})]})})]});if(e.kind===`cluster`)return(0,J.jsxs)(`div`,{style:{padding:`10px`},children:[(0,J.jsxs)(`h3`,{style:{margin:`0 0 8px 0`},children:[`Cluster `,e.cluster.name]}),(0,J.jsx)(`table`,{style:{marginBottom:`12px`},children:(0,J.jsxs)(`tbody`,{children:[(0,J.jsx)(Vn,{label:`Endpoint`,children:e.group.endpoint}),(0,J.jsx)(Vn,{label:`Cluster ID`,children:e.cluster.id})]})}),(0,J.jsxs)(`table`,{style:{borderCollapse:`collapse`,width:`100%`},children:[(0,J.jsx)(`thead`,{children:(0,J.jsxs)(`tr`,{children:[(0,J.jsx)(`th`,{style:{...Bn,color:`var(--primary-color)`,textAlign:`left`},children:`Attribute`}),(0,J.jsx)(`th`,{style:{...Bn,color:`var(--primary-color)`,textAlign:`left`},children:`ID`}),(0,J.jsx)(`th`,{style:{...Bn,color:`var(--primary-color)`,textAlign:`left`},children:`Value`})]})}),(0,J.jsx)(`tbody`,{children:e.cluster.attributes.map(e=>(0,J.jsxs)(`tr`,{style:{borderTop:`1px solid var(--table-border-color)`},children:[(0,J.jsx)(`td`,{children:e.attributeName}),(0,J.jsx)(`td`,{children:e.attributeId}),(0,J.jsx)(`td`,{style:{wordBreak:`break-all`},children:e.attributeValue})]},e.attributeName))})]})]});let{attribute:t}=e;return(0,J.jsxs)(`div`,{style:{padding:`10px`},children:[(0,J.jsxs)(`h3`,{style:{margin:`0 0 8px 0`},children:[`Attribute `,t.attributeName]}),(0,J.jsx)(`table`,{style:{marginBottom:`12px`},children:(0,J.jsxs)(`tbody`,{children:[(0,J.jsx)(Vn,{label:`Path`,children:`Endpoint ${e.group.endpoint} › ${e.cluster.name} › ${t.attributeName}`}),(0,J.jsx)(Vn,{label:`Cluster ID`,children:t.clusterId}),(0,J.jsx)(Vn,{label:`Attribute ID`,children:t.attributeId}),(0,J.jsx)(Vn,{label:`Device types`,children:e.group.deviceTypes.map(Pn).join(`, `)})]})}),(0,J.jsx)(`div`,{style:{fontWeight:`bold`},children:`Value`}),(0,J.jsx)(`pre`,{style:{margin:`4px 0 0 0`,padding:`8px`,border:`1px solid var(--table-border-color)`,whiteSpace:`pre-wrap`,wordBreak:`break-all`},children:JSON.stringify(t.attributeLocalValue,(e,t)=>typeof t==`bigint`?t.toString():t,2)??`undefined`})]})}function Un({clusters:e}){let[t,n]=(0,U.useState)(new Set),r=e=>e.startsWith(`ep:`)!==t.has(e),[i,a]=(0,U.useState)(null),o=(0,U.useMemo)(()=>Rn(e),[e]),s=(0,U.useMemo)(()=>{let e=new Map;for(let t of o){e.set(Fn(t.endpoint),{kind:`endpoint`,key:Fn(t.endpoint),group:t});for(let n of t.clusters){let r=In(t.endpoint,n.name);e.set(r,{kind:`cluster`,key:r,group:t,cluster:n});for(let r of n.attributes){let i=Ln(t.endpoint,n.name,r.attributeName);e.set(i,{kind:`attribute`,key:i,group:t,cluster:n,attribute:r})}}}return e},[o]),c=e=>n(t=>{let n=new Set(t);return n.has(e)?n.delete(e):n.add(e),n}),l=e=>{a(e),c(e)},u=(()=>{let e=[];return o.forEach((t,n)=>{let i=Fn(t.endpoint);e.push({key:i,depth:0,label:`Endpoint ${t.endpoint}`,expandable:!0,parent:null,posinset:n+1,setsize:o.length}),r(i)&&t.clusters.forEach((n,a)=>{let o=In(t.endpoint,n.name);e.push({key:o,depth:1,label:n.name,expandable:!0,parent:i,posinset:a+1,setsize:t.clusters.length}),r(o)&&n.attributes.forEach((r,i)=>e.push({key:Ln(t.endpoint,n.name,r.attributeName),depth:2,label:r.attributeName,expandable:!1,parent:o,posinset:i+1,setsize:n.attributes.length}))})}),e})(),[d,f]=(0,U.useState)(null),p=(0,U.useRef)(new Map),m=u.some(e=>e.key===d)?d:u[0]?.key,h=e=>{e&&(f(e),p.current.get(e)?.focus())},g=(e,t)=>{let n=u[t];switch(e.key){case`Enter`:case` `:l(n.key);break;case`ArrowDown`:h(u[t+1]?.key);break;case`ArrowUp`:h(u[t-1]?.key);break;case`Home`:h(u[0].key);break;case`End`:h(u[u.length-1].key);break;case`ArrowRight`:if(!n.expandable)break;r(n.key)?h(u[t+1]?.key):c(n.key);break;case`ArrowLeft`:n.expandable&&r(n.key)?c(n.key):h(n.parent??void 0);break;default:return}e.preventDefault()};return(0,J.jsxs)(`div`,{style:{display:`flex`,flexDirection:`row`,flex:`1 1 auto`,minHeight:0,width:`100%`,overflow:`hidden`,color:`var(--div-text-color)`},children:[(0,J.jsx)(`div`,{role:`tree`,"aria-label":`Clusters`,style:{flex:`0 0 30%`,minWidth:`200px`,overflowX:`hidden`,overflowY:`auto`,borderRight:`2px solid var(--main-grey-color)`},children:u.map((e,t)=>(0,J.jsxs)(`div`,{ref:t=>{t?p.current.set(e.key,t):p.current.delete(e.key)},role:`treeitem`,"aria-level":e.depth+1,"aria-posinset":e.posinset,"aria-setsize":e.setsize,"aria-selected":i===e.key,"aria-expanded":e.expandable?r(e.key):void 0,style:zn(i===e.key,e.depth),tabIndex:e.key===m?0:-1,onClick:()=>{f(e.key),l(e.key)},onKeyDown:e=>g(e,t),children:[(0,J.jsx)(`span`,{style:{width:`12px`},children:e.expandable?r(e.key)?`▾`:`▸`:``}),e.label]},e.key))}),(0,J.jsx)(`div`,{style:{flex:`1 1 auto`,overflowX:`hidden`,overflowY:`auto`},children:(0,J.jsx)(Hn,{node:i?s.get(i):void 0})})]})}var Wn=(0,U.memo)(Un);function Gn(e){return e?e.scrollWidth>e.clientWidth:!1}function Kn({title:e,children:t}){let n=(0,U.useRef)(null),[r,i]=(0,U.useState)(!1);return(0,J.jsx)(H,{title:e,open:r,disableHoverListener:!0,disableFocusListener:!0,disableTouchListener:!0,slotProps:{tooltip:{sx:{fontSize:`14px`,fontWeight:`normal`,color:`#ffffff`,backgroundColor:`var(--primary-color)`,maxWidth:500,whiteSpace:`pre-wrap`,wordBreak:`break-word`}}},children:(0,J.jsx)(`span`,{ref:n,onMouseEnter:()=>{i(Gn(n.current))},onMouseLeave:()=>{i(!1)},style:{display:`inline-block`,maxWidth:`100%`,overflow:`hidden`,textOverflow:`ellipsis`,whiteSpace:`nowrap`},children:t})})}function qn(e,t,n){let r=e?.[n],i=t?.[n];return r==null&&i==null?0:r==null?-1:i==null?1:typeof r==`boolean`&&typeof i==`boolean`?r===i?0:r?1:-1:typeof r==`number`&&typeof i==`number`?r-i:String(r).localeCompare(String(i))}function Jn({name:e,title:t,columns:n,rows:r,getRowKey:i,footerLeft:a,footerRight:o,headerActions:s,onRowClick:c}){let l=t=>{if(typeof i==`string`&&t&&t[i]!=null)return t[i];if(typeof i==`function`){let e=i(t);if(e!=null)return e}let a=n?.[0]?.id;return a&&t&&t[a]!=null?t[a]:(console.warn(`MbfTable(${e}): using fallback stable row key; consider providing getRowKey prop for better React performance`),`rk_${r.indexOf(t)}`)},u=e.replace(/\s+/g,`-`).toLowerCase(),d=`${W}${u}-table-order-by`,f=`${W}${u}-table-order`,p=`${W}${u}-column-visibility`,[m,h]=(0,U.useState)(localStorage.getItem(d)||null),[g,_]=(0,U.useState)(localStorage.getItem(f)||null),[v,y]=(0,U.useState)(!1),[b,x]=(0,U.useState)(()=>{try{let e=localStorage.getItem(p);if(e)return JSON.parse(e)}catch{}return{}}),S=(0,U.useMemo)(()=>{let e={};for(let t of n)t.hidden||(e[t.id]=t.required?!0:b[t.id]!==!1);return e},[n,b]),C=(0,U.useMemo)(()=>{if(!m||!g)return r;let e=n.find(e=>e.id===m);if(!e||e.noSort)return r;let t=r.map((e,t)=>({el:e,index:t}));return t.sort((t,n)=>{let r;return r=typeof e.comparator==`function`?e.comparator(t.el,n.el):qn(t.el,n.el,m),r===0?t.index-n.index:g===`asc`?r:-r}),t.map(e=>e.el)},[r,m,g,n]),T=e=>{m!==e||!m?(h(e),_(`asc`),localStorage.setItem(d,e),localStorage.setItem(f,`asc`)):g===`asc`?(_(`desc`),localStorage.setItem(f,`desc`)):(h(null),_(null),localStorage.removeItem(d),localStorage.removeItem(f))},D=()=>{y(!v)},O=e=>{x(t=>{if(n.find(t=>t.id===e)?.required)return t;let r=S[e]!==!1,i={...t};r?i[e]=!1:delete i[e];try{localStorage.setItem(p,JSON.stringify(i))}catch{}return i})},k=()=>{x({});try{localStorage.removeItem(p)}catch{}y(!1)},[A,j]=(0,U.useState)(!1);return A?null:(K&&console.log(`Rendering table ${e}${m&&g?` ordered by ${m}:${g}`:``}`),(0,J.jsxs)(`div`,{style:{flex:`1 1 auto`,display:`flex`,flexDirection:`column`,margin:`0`,padding:`0`,gap:`0`,width:`100%`,height:`100%`,overflow:`hidden`},children:[(0,J.jsxs)(L,{open:v,onClose:(e,t)=>{t!==`backdropClick`&&t!==`escapeKeyDown`&&D()},disableRestoreFocus:!0,children:[(0,J.jsx)(_e,{children:(0,J.jsxs)(`div`,{style:{display:`flex`,flexDirection:`row`,alignItems:`center`,gap:`20px`},children:[(0,J.jsx)(`img`,{src:`matterbridge.svg`,alt:`Matterbridge Logo`,style:{height:`32px`,width:`32px`}}),(0,J.jsx)(`h4`,{style:{margin:0},children:`Configure ${e} columns`})]})}),(0,J.jsx)(E,{children:(0,J.jsx)(N,{children:n.filter(e=>!e.hidden).map(e=>(0,J.jsx)(ue,{control:(0,J.jsx)(w,{disabled:!!e.required,checked:e.required?!0:S[e.id]!==!1,onChange:()=>O(e.id)}),label:e.label},e.id))})}),(0,J.jsxs)(ge,{children:[(0,J.jsx)(M,{onClick:k,children:`Reset`}),(0,J.jsx)(M,{variant:`contained`,onClick:e=>{if(e?.currentTarget&&typeof e.currentTarget.blur==`function`)try{e.currentTarget.blur()}catch{}let t=document.activeElement;if(t&&t instanceof HTMLElement&&typeof t.blur==`function`)try{t.blur()}catch{}D()},children:`Close`})]})]}),(0,J.jsxs)(rn,{style:{height:`30px`,minHeight:`30px`,justifyContent:`space-between`,borderBottom:`none`},children:[(0,J.jsx)(Q,{children:e}),t&&(0,J.jsx)(Q,{children:t}),(0,J.jsxs)(ln,{close:()=>j(!0),children:[s,(0,J.jsx)(R,{size:`small`,sx:{color:`var(--header-text-color)`,margin:`0px`,padding:`0px`},onClick:e=>{if(e?.currentTarget?.blur)try{e.currentTarget.blur()}catch{}D()},"aria-label":`Configure Columns`,children:(0,J.jsx)(H,{title:`Configure ${e} columns`,children:(0,J.jsx)(X.Icon,{path:Ct,size:`20px`,color:`var(--header-text-color)`})})})]})]}),(0,J.jsx)(cn,{style:{flex:`1 1 auto`,display:`flex`,flexDirection:`column`,minHeight:0,width:`100%`,overflow:`auto`,margin:`0px`,padding:`0px`,gap:`0`},children:(0,J.jsxs)(`table`,{"aria-label":`${e} table`,style:{width:`100%`,borderCollapse:`collapse`},children:[(0,J.jsx)(`thead`,{style:{position:`sticky`,top:0,zIndex:10,border:`none`,color:`var(--header-text-color)`,backgroundColor:`var(--header-bg-color`},children:(0,J.jsx)(`tr`,{style:{height:`30px`,minHeight:`30px`},children:n.map(e=>{if(e.hidden||!e.required&&S[e.id]===!1)return null;let t=!e.noSort,n=t&&m===e.id&&!!g;return(0,J.jsxs)(`th`,{onClick:t?()=>T(e.id):void 0,style:{margin:`0`,padding:`5px 10px`,position:`sticky`,top:0,minWidth:e.minWidth,maxWidth:e.maxWidth,textAlign:e.align||`left`,cursor:t?`pointer`:`default`,border:`none`,color:`var(--header-text-color)`,backgroundColor:`var(--header-bg-color)`,whiteSpace:e.maxWidth?`nowrap`:void 0,overflow:e.maxWidth?`hidden`:void 0,textOverflow:e.maxWidth?`ellipsis`:void 0},"aria-sort":t?n?g===`asc`?`ascending`:`descending`:`none`:void 0,children:[e.label,n&&(0,J.jsxs)(`span`,{style:{marginLeft:6},children:[g===`asc`&&(0,J.jsx)(X.Icon,{path:`M19 17H22L18 21L14 17H17V3H19M2 17H12V19H2M6 5V7H2V5M2 11H9V13H2V11Z`,size:`15px`}),g===`desc`&&(0,J.jsx)(X.Icon,{path:`M19 7H22L18 3L14 7H17V21H19M2 17H12V19H2M6 5V7H2V5M2 11H9V13H2V11Z`,size:`15px`})]})]},e.id)})})}),(0,J.jsx)(`tbody`,{children:C.map((e,t)=>{let r=l(e);return(0,J.jsx)(`tr`,{className:t%2==0?`table-content-even`:`table-content-odd`,onClick:c?t=>c(e,r,t):void 0,style:{height:`30px`,minHeight:`30px`,border:`none`,borderCollapse:`collapse`,cursor:c?`pointer`:void 0},children:n.map(t=>{if(t.hidden||!t.required&&S[t.id]===!1)return null;let n=e[t.id],i=typeof t.render==`function`?t.render(n,r,e,t):typeof n==`boolean`?(0,J.jsx)(w,{checked:n,disabled:!0,size:`small`,sx:{m:0,p:0,color:`var(--table-text-color)`,"&.Mui-disabled":{color:`var(--table-text-color)`,opacity:.7}}}):t.format&&typeof n==`number`?t.format(n):n==null?null:String(n),a=t.tooltip&&t.maxWidth!==void 0&&t.maxWidth!==null&&n!=null&&i!==null?(0,J.jsx)(Kn,{title:String(n),children:i}):i;return(0,J.jsx)(`td`,{style:{border:`none`,borderCollapse:`collapse`,textAlign:t.align||`left`,padding:`5px 10px`,margin:`0`,maxWidth:t.maxWidth,whiteSpace:t.maxWidth?`nowrap`:void 0,overflow:t.maxWidth?`hidden`:void 0,textOverflow:t.maxWidth?`ellipsis`:void 0},children:a},t.id)})},r)})})]})}),(a||o)&&(0,J.jsxs)(an,{style:{height:`30px`,minHeight:`30px`,justifyContent:`space-between`,border:`none`},children:[(0,J.jsx)(on,{style:{fontSize:`14px`,fontWeight:`normal`,color:`var(--secondary-color)`},children:a}),(0,J.jsx)(on,{style:{fontSize:`14px`,fontWeight:`normal`,color:`var(--secondary-color)`},children:o})]})]}))}function Yn(e){return(0,U.memo)(e)}var Xn=Yn(Jn),Zn=[{label:`Plugin name`,id:`plugin`,required:!0},{label:`Device type`,id:`type`},{label:`Endpoint`,id:`number`,align:`right`},{label:`Name`,id:`deviceName`,required:!0},{label:`Serial number`,id:`serialNumber`},{label:`Unique ID`,id:`uniqueId`},{label:`Url`,id:`configUrl`},{label:`Config`,id:`configButton`,noSort:!0,render:(e,t,n,r)=>n.configUrl?(0,J.jsx)(R,{onClick:()=>window.open(n.configUrl,`_blank`),"aria-label":`Open Config`,sx:{margin:0,padding:0},children:(0,J.jsx)(T,{fontSize:`small`})}):null},{label:`Cluster`,id:`cluster`}],Qn=[{label:`Endpoint`,id:`endpoint`,required:!0},{label:`Id`,id:`id`},{label:`Device Types`,id:`deviceTypes`,render:(e,t,n,r)=>Array.isArray(e)?(0,J.jsx)(J.Fragment,{children:e.map(e=>`0x${e.toString(16).padStart(4,`0`)}`).join(`, `)}):(0,J.jsx)(J.Fragment,{children:e})},{label:`Cluster Name`,id:`clusterName`,required:!0},{label:`Cluster ID`,id:`clusterId`},{label:`Attribute Name`,id:`attributeName`,required:!0},{label:`Attribute ID`,id:`attributeId`},{label:`Attribute Value`,id:`attributeValue`,required:!0,maxWidth:350,tooltip:!0}],$n=e=>`${e.plugin}::${e.uniqueId}`,er=e=>`${e.endpoint}::${e.clusterName}::${e.attributeName}`;function tr({filterPlugins:e,filterDevices:t}){let{online:n,sendMessage:r,addListener:i,removeListener:a,getUniqueId:o}=(0,U.useContext)(Y),[s,c]=(0,U.useState)([]),[l,u]=(0,U.useState)([]),[d,f]=(0,U.useState)(0),[p,m]=(0,U.useState)(()=>localStorage.getItem(G[`devices-cluster-view-mode`])===`tree`?`tree`:`grid`),[h,g]=(0,U.useState)(null),[_,v]=(0,U.useState)(null),[y,b]=(0,U.useState)(null),[x,S]=(0,U.useState)(null),[C,w]=(0,U.useState)(null),T=(0,U.useMemo)(()=>{let n=e?.trim().toLowerCase(),r=n&&n!==`all plugins`,i=s;return r&&(i=i.filter(e=>e.plugin.toLowerCase()===n)),t!==``&&(i=i.filter(e=>e.deviceName.toLowerCase().includes(t.toLowerCase())||e.serialNumber.toLowerCase().includes(t.toLowerCase()))),i},[s,e,t]),E=(0,U.useRef)(o()),D=(0,U.useRef)(T),O=(0,U.useCallback)(e=>{K&&console.log(`DevicesTable received state_update "${e.response.cluster}.${e.response.attribute}" for "${e.response.id}:${e.response.number}": "${e.response.value}"`,e.response);let t=D.current.find(t=>t.plugin===e.response.plugin&&t.uniqueId===e.response.uniqueId);if(!t)K&&console.warn(`DevicesTable updater device of plugin "${e.response.plugin}" serial "${e.response.serialNumber}" not found in filteredDevicesRef.current`);else if(h&&_&&t.plugin===h&&t.uniqueId===x&&e.response.number.toString()===_){let n=l.find(t=>t.endpoint===e.response.number.toString()&&t.clusterName===e.response.cluster&&t.attributeName===e.response.attribute);if(!n){K&&console.warn(`DevicesTable updater cluster ${e.response.cluster}.${e.response.attribute} for device "${t.deviceName}" serial "${t.serialNumber}" not found in clusters`);return}n.attributeValue=typeof e.response.value==`object`?JSON.stringify(e.response.value,void 0,1).replaceAll(`"`,``):String(e.response.value),n.attributeLocalValue=e.response.value,u([...l]),K&&console.log(`DevicesTable updated attribute ${n.clusterName}.${n.attributeName} for device "${t.deviceName}" serial "${t.serialNumber}" to "${n.attributeValue}"`)}},[l,_,h,x]);(0,U.useEffect)(()=>{let e=e=>{if(K&&console.log(`DevicesTable received WebSocket Message:`,e),e.method===`refresh_required`&&e.response.changed===`devices`)K&&console.log(`DevicesTable received refresh_required: changed=${e.response.changed} and sending /api/devices request`),r({id:E.current,sender:`DevicesTable`,method:`/api/devices`,src:`Frontend`,dst:`Matterbridge`,params:{extended:!0}});else if(e.method===`state_update`&&e.response)O(e);else if(e.method===`/api/devices`)K&&console.log(`DevicesTable received ${e.response.length} devices:`,e.response),c(e.response);else if(e.method===`/api/clusters`){K&&console.log(`DevicesTable received ${e.response.clusters.length} clusters for plugin ${e.response.plugin}:`,e.response),u(e.response.clusters);let t={};for(let n of e.response.clusters)K&&console.log(`Cluster:`,n.endpoint),t[n.endpoint]?t[n.endpoint]++:t[n.endpoint]=1;f(Object.keys(t).length)}};return i(e,E.current),K&&console.log(`DevicesTable added WebSocket listener`),()=>{a(e),K&&console.log(`DevicesTable removed WebSocket listener`)}},[r,i,a,O]),(0,U.useEffect)(()=>{n&&(K&&console.log(`DevicesTable sending api requests with id `,E.current),r({id:E.current,sender:`DevicesTable`,method:`/api/settings`,src:`Frontend`,dst:`Matterbridge`,params:{}}),r({id:E.current,sender:`DevicesTable`,method:`/api/plugins`,src:`Frontend`,dst:`Matterbridge`,params:{}}),r({id:E.current,sender:`DevicesTable`,method:`/api/devices`,src:`Frontend`,dst:`Matterbridge`,params:{extended:!0}}))},[n,r]),(0,U.useEffect)(()=>{h&&_&&C&&x&&(K&&console.log(`DevicesTable sending /api/clusters`),r({id:E.current,sender:`DevicesTable`,method:`/api/clusters`,src:`Frontend`,dst:`Matterbridge`,params:{pluginName:h,number:Number(_),serialNumber:C,uniqueId:x}}))},[h,_,C,x,r]),(0,U.useEffect)(()=>{D.current=T},[T]);let k=e=>{e.uniqueId===x?(S(null),w(null),g(null),v(null),b(null)):(K&&console.log(`DevicesTable handleDeviceClick: selected device "${e.deviceName}" with uniqueId "${e.uniqueId}", plugin "${e.plugin}", endpoint "${e.number}"`),S(e.uniqueId),w(e.serialNumber),g(e.plugin),v(e.number?e.number.toString():null),b(e.deviceName))},A=(0,J.jsx)(R,{onClick:()=>{let e=p===`tree`?`grid`:`tree`;localStorage.setItem(G[`devices-cluster-view-mode`],e),m(e)},"aria-label":p===`tree`?`Switch to grid view`:`Switch to tree view`,sx:{margin:0,padding:0,color:`var(--header-text-color)`},children:p===`tree`?(0,J.jsx)(ft,{fontSize:`small`}):(0,J.jsx)(he,{fontSize:`small`})}),j=`Total child endpoints: ${d-1}`;return K&&console.log(`DevicesTable rendering...`),n?(0,J.jsxs)(`div`,{style:{display:`flex`,flexDirection:`column`,margin:`0px`,padding:`0px`,gap:`20px`,width:`100%`,flex:`1 1 auto`,minHeight:0,overflow:`hidden`},children:[(0,J.jsx)(Z,{style:{margin:`0px`,padding:`0px`,gap:`0px`,width:`100%`,maxHeight:h&&_?`30%`:`100%`,flex:`1 1 auto`,overflow:`hidden`},children:(0,J.jsx)(Xn,{name:`Registered devices`,getRowKey:$n,onRowClick:k,rows:T,columns:Zn,footerLeft:`Total devices: ${T.length.toString()}`})}),h&&_&&(0,J.jsx)(Z,{style:{margin:`0px`,padding:`0px`,gap:`0px`,width:`100%`,height:`70%`,maxHeight:`70%`,flex:`1 1 auto`,overflow:`hidden`},children:p===`tree`?(0,J.jsxs)(`div`,{style:{flex:`1 1 auto`,display:`flex`,flexDirection:`column`,margin:`0`,padding:`0`,gap:`0`,width:`100%`,height:`100%`,overflow:`hidden`},children:[(0,J.jsxs)(rn,{style:{height:`30px`,minHeight:`30px`,borderBottom:`none`},children:[(0,J.jsx)(Q,{children:`Clusters`}),(0,J.jsx)(Q,{children:y||``}),(0,J.jsx)(ln,{children:A})]}),(0,J.jsx)(Wn,{clusters:l}),(0,J.jsx)(an,{children:(0,J.jsx)(on,{style:{fontSize:`14px`,fontWeight:`normal`,color:`var(--secondary-color)`},children:j})})]}):(0,J.jsx)(Xn,{name:`Clusters`,title:y||``,getRowKey:er,rows:l,columns:Qn,footerLeft:j,headerActions:A})})]}):(0,J.jsx)(nn,{})}var nr=(0,U.memo)(tr);function rr({children:e,style:t,name:n}){let{setCurrentPage:r}=(0,U.useContext)($t);return r(n),K&&console.log(`MbfPage: current page set to ${n}`),(0,J.jsx)(`div`,{style:{display:`flex`,flexDirection:`column`,width:`100%`,height:`100%`,margin:`0px`,padding:`0px`,gap:`20px`,...t},children:e})}function ir(){let{online:e,sendMessage:t,addListener:n,removeListener:r,getUniqueId:i}=(0,U.useContext)(Y),[a,o]=(0,U.useState)([`All plugins`]),[s,c]=(0,U.useState)(()=>localStorage.getItem(G[`devices-filter-plugins`])||`All plugins`),[l,u]=(0,U.useState)(()=>localStorage.getItem(G[`devices-filter-devices`])||``),[d,f]=(0,U.useState)(()=>localStorage.getItem(G[`devices-view-mode`])||`icon`),p=(0,U.useRef)(i());(0,U.useEffect)(()=>{let e=e=>{K&&e.id&&console.log(`Devices received WebSocket Message:`,e),e.method===`refresh_required`&&e.response.changed===`plugins`&&!e.response.lock?(K&&console.log(`Devices received refresh_required for plugins lock=${e.response.lock}, sending /api/plugins request with id ${p.current}`),t({id:p.current,sender:`Devices`,method:`/api/plugins`,src:`Frontend`,dst:`Matterbridge`,params:{}})):e.method===`/api/plugins`&&e.id===p.current&&e.response&&(K&&console.log(`Devices received ${e.response.length} plugins:`,e.response),o([`All plugins`,...e.response.map(e=>e.name)]))};return n(e,p.current),K&&console.log(`Devices added WebSocket listener`),()=>{r(e),K&&console.log(`Devices removed WebSocket listener`)}},[t,n,r]),(0,U.useEffect)(()=>{e&&(o([`All plugins`]),K&&console.log(`Devices sending /api/plugins request with id ${p.current}`),t({id:p.current,sender:`Devices`,method:`/api/plugins`,src:`Frontend`,dst:`Matterbridge`,params:{}}))},[e,t]);let m=e=>{let t=e.target.value;c(t),localStorage.setItem(G[`devices-filter-plugins`],t)},h=e=>{u(e.target.value),localStorage.setItem(G[`devices-filter-devices`],e.target.value)},g=()=>{u(``),localStorage.removeItem(G[`devices-filter-devices`])},_=e=>{f(e),localStorage.setItem(G[`devices-view-mode`],e)};return K&&console.log(`Devices rendering...`),e?(0,J.jsxs)(rr,{name:`Devices`,children:[(0,J.jsxs)(`div`,{style:{display:`flex`,flexDirection:`row`,flexWrap:`wrap`,justifyContent:`space-between`,padding:0,margin:0,gap:`20px`,width:`100%`},children:[(0,J.jsxs)(`div`,{style:{display:`flex`,flexDirection:`row`,flexWrap:`wrap`,justifyContent:`space-between`,padding:0,margin:0,gap:`20px`},children:[(0,J.jsxs)(V,{sx:{display:`flex`,flexDirection:`row`,alignItems:`center`,gap:`10px`},children:[(0,J.jsx)(A,{sx:{fontSize:`16px`,fontWeight:`normal`,color:`var(--div-text-color)`,marginLeft:`5px`,whiteSpace:`nowrap`},children:`Plugin:`}),(0,J.jsx)(H,{title:`Filter devices by plugin`,children:(0,J.jsx)(fe,{variant:`outlined`,value:s,onChange:m,sx:{width:`260px`,backgroundColor:`var(--main-bg-color)`,"& .MuiOutlinedInput-root":{backgroundColor:`var(--main-bg-color)`},"& .MuiSelect-select":{backgroundColor:`var(--main-bg-color)`}},input:(0,J.jsx)(me,{sx:{backgroundColor:`var(--main-bg-color)`}}),children:a.map(e=>(0,J.jsx)(b,{value:e,children:e},e))})})]}),(0,J.jsxs)(V,{sx:{display:`flex`,flexDirection:`row`,alignItems:`center`,gap:`10px`},children:[(0,J.jsx)(A,{sx:{fontSize:`16px`,fontWeight:`normal`,color:`var(--div-text-color)`,marginLeft:`5px`,whiteSpace:`nowrap`},children:`Filter by:`}),(0,J.jsx)(H,{title:`Filter devices by name or serial number`,children:(0,J.jsx)(z,{variant:`outlined`,value:l,onChange:h,placeholder:`Enter the device name or serial`,sx:{width:`260px`,"& .MuiOutlinedInput-root":{backgroundColor:`var(--main-bg-color)`}},slotProps:{input:{endAdornment:l?(0,J.jsx)(oe,{position:`end`,children:(0,J.jsx)(R,{"aria-label":`Clear device filter`,size:`small`,onClick:g,edge:`end`,children:(0,J.jsx)(_t,{sx:{fontSize:18,color:`var(--main-label-color)`}})})}):null}}})})]})]}),(0,J.jsxs)(V,{sx:{display:`flex`,flexDirection:`row`,alignItems:`center`,gap:`10px`},children:[(0,J.jsx)(A,{sx:{fontSize:`16px`,fontWeight:`normal`,color:`var(--div-text-color)`,marginLeft:`5px`,whiteSpace:`nowrap`},children:`View mode:`}),(0,J.jsx)(R,{onClick:()=>_(`table`),"aria-label":`Table View`,disabled:d===`table`,children:(0,J.jsx)(H,{title:`Table View`,children:(0,J.jsx)(ft,{style:{color:d===`table`?`var(--main-icon-color)`:`var(--primary-color)`}})})}),(0,J.jsx)(R,{onClick:()=>_(`icon`),"aria-label":`Icon View`,disabled:d===`icon`,children:(0,J.jsx)(H,{title:`Icon View (beta)`,children:(0,J.jsx)(Te,{style:{color:d===`icon`?`var(--main-icon-color)`:`var(--primary-color)`}})})})]})]}),d===`table`&&(0,J.jsx)(nr,{filterPlugins:s,filterDevices:l},`table-${e}`),d===`icon`&&(0,J.jsx)(Nn,{filterPlugins:s,filterDevices:l},`icon-${e}`)]}):(0,J.jsx)(nn,{})}var ar=(0,U.memo)(ir);function or({version:e}){let{online:t}=(0,U.useContext)(Y);return K&&console.log(`HomeBrowserRefresh rendering...`),t?(0,J.jsxs)(Z,{children:[(0,J.jsx)(rn,{children:(0,J.jsx)(Q,{children:`Frontend Update`})}),(0,J.jsxs)(cn,{style:{flexDirection:`row`,flexWrap:`wrap`,justifyContent:`space-between`,alignItems:`center`},children:[(0,J.jsxs)(`h4`,{style:{margin:0},children:[`The frontend has been updated to version `,e,`. You are viewing an outdated web UI. Please refresh the page now.`]}),(0,J.jsx)(`div`,{children:(0,J.jsx)(M,{onClick:()=>window.location.reload(),endIcon:(0,J.jsx)(I,{}),style:{marginLeft:`10px`,color:`var(--main-button-color)`,backgroundColor:`var(--main-button-bg-color)`,height:`30px`},children:`Refresh`})})]})]}):(0,J.jsx)(nn,{})}var sr=(0,U.memo)(or);function cr(e){if(K&&console.log(`getQRColor (id: ${e?.id}) received matter:`,e??`undefined`),e===void 0||!e.online||!e.qrPairingCode&&!e.manualPairingCode&&!e.fabricInformations&&!e.sessionInformations)return`red`;if(!e.commissioned&&e.qrPairingCode&&e.manualPairingCode)return`var(--primary-color)`;let t=0,n=0;for(let r of e.sessionInformations??[])r.fabric&&r.isPeerActive&&t++,r.numberOfActiveSubscriptions>0&&(n+=r.numberOfActiveSubscriptions);return e.commissioned&&e.fabricInformations&&e.sessionInformations&&(t===0||n===0)?`var(--secondary-color)`:`var(--div-text-color)`}function lr(e,t,n=250){let r=(0,U.useRef)(null),i=()=>{r.current&&clearTimeout(r.current),r.current=null};return(0,U.useEffect)(()=>()=>{r.current&&clearTimeout(r.current)},[]),a=>({onClick:()=>{i(),r.current=setTimeout(()=>{r.current=null,e(a)},n)},onDoubleClick:()=>{i(),t(a)}})}var ur=e=>`${e.plugin}::${e.serialNumber}`,dr=(e,t)=>{let n=`plugins/${t}`,r=e.replace(/^\.?\//,``);return r===e||!r.startsWith(n)?!1:[``,`/`,`?`,`#`].includes(r.charAt(n.length))},fr=(e,t)=>/^\.?\/plugins\//.test(e)&&!dr(e,t),pr=(e,t)=>e===void 0?t:e===100?x:e>=80?D:e>=60?ee:e>=40?Ye:e>=20?le:e>=10?vt:p;function mr({storeId:e,setStoreId:t}){let{online:n,sendMessage:r,addListener:i,removeListener:a,getUniqueId:o}=(0,U.useContext)(Y),{mobile:s}=(0,U.useContext)($t),[c,l]=(0,U.useState)(`Waiting for the plugins to fully load...`),[u,d]=(0,U.useState)(``),[f,m]=(0,U.useState)(null),[h,g]=(0,U.useState)([]),[_,v]=(0,U.useState)([]),[y,b]=(0,U.useState)(null),[x,S]=(0,U.useState)(`inactive`),C=(0,U.useRef)(o()),O=[{label:`Plugin`,id:`plugin`},{label:`Name`,id:`deviceName`,required:!0},{label:`Serial`,id:`serialNumber`},{label:`Availability`,id:`availability`,render:(e,t,n,r)=>n.reachable===!0?`Online`:n.reachable===!1?(0,J.jsx)(`span`,{style:{color:`red`},children:`Offline`}):``,comparator:(e,t)=>(e.reachable===!0?1:e.reachable===!1?0:-1)-(t.reachable===!0?1:t.reachable===!1?0:-1)},{label:`Power`,id:`powerSource`,render:(e,t,n,r)=>{if(n.powerSource===`ac`||n.powerSource===`dc`)return(0,J.jsx)(H,{title:n.powerSource===`ac`?`AC current`:`DC current`,children:(0,J.jsx)(qe,{fontSize:`small`,sx:{color:`var(--primary-color)`}})});if(n.powerSource===`ok`){let e=pr(n.batteryLevel,D);return n.batteryLevel===void 0?(0,J.jsx)(e,{fontSize:`small`,sx:{color:`gray`}}):(0,J.jsx)(H,{title:`Battery level: ${n.batteryLevel}%`,children:(0,J.jsx)(e,{fontSize:`small`,sx:{color:`green`}})})}if(n.powerSource===`warning`){let e=pr(n.batteryLevel,le);return n.batteryLevel===void 0?(0,J.jsx)(e,{fontSize:`small`,sx:{color:`yellow`}}):(0,J.jsx)(H,{title:`Battery level: ${n.batteryLevel}%`,children:(0,J.jsx)(e,{fontSize:`small`,sx:{color:`yellow`}})})}if(n.powerSource===`critical`){let e=pr(n.batteryLevel,p);return n.batteryLevel===void 0?(0,J.jsx)(e,{fontSize:`small`,sx:{color:`red`}}):(0,J.jsx)(H,{title:`Battery level: ${n.batteryLevel}%`,children:(0,J.jsx)(e,{fontSize:`small`,sx:{color:`red`}})})}return(0,J.jsx)(`span`,{})}},{label:`Actions`,id:`selected`,required:!0,render:(n,r,i,a)=>(0,J.jsxs)(`div`,{style:{display:`flex`,flexDirection:`row`},children:[i.matter===void 0?(0,J.jsx)(`div`,{style:{width:`20px`,height:`20px`}}):(0,J.jsx)(H,{title:`Show the QRCode or the fabrics`,slotProps:{popper:{modifiers:[{name:`offset`,options:{offset:[30,15]}}]}},children:(0,J.jsx)(R,{onClick:()=>t(e===i.matter?.id?f?.matterbridgeInformation.bridgeMode===`bridge`?`Matterbridge`:null:i.matter?.id||null),"aria-label":`Show the QRCode`,sx:{margin:0,padding:0,color:cr(i.matter)},children:(0,J.jsx)(re,{fontSize:`small`})})}),i.configUrl&&!fr(i.configUrl,i.plugin)?(0,J.jsx)(H,{title:dr(i.configUrl,i.plugin)?`Open the device page in the plugin frontend (double-click for a new tab)`:`Open the configuration page`,slotProps:{popper:{modifiers:[{name:`offset`,options:{offset:[30,15]}}]}},children:(0,J.jsx)(R,{...N(i),"aria-label":`Open config url`,sx:{margin:0,padding:0},children:dr(i.configUrl,i.plugin)?(0,J.jsx)(ae,{fontSize:`small`}):(0,J.jsx)(T,{fontSize:`small`})})}):(0,J.jsx)(`div`,{style:{width:`20px`,height:`20px`}}),i.selected===void 0?(0,J.jsx)(`div`,{style:{width:`20px`,height:`20px`}}):(0,J.jsx)(H,{title:`Select/unselect the device`,slotProps:{popper:{modifiers:[{name:`offset`,options:{offset:[30,15]}}]}},children:(0,J.jsx)(w,{checked:i.selected,onChange:e=>j(e,i),sx:{margin:`0`,marginLeft:`8px`,padding:`0`},size:`small`})})]})}],k=(0,U.useCallback)(e=>{e.selected=void 0;let t=h.find(t=>t.name===e.plugin);if(!t)return console.error(`HomeDevices isSelected: plugin ${e.plugin} not found for device ${e.deviceName} `),e.selected;let n=t.schemaJson?.properties?.whiteList?.selectFrom,r=t.configJson.postfix;return r===``&&(r=void 0),t.hasWhiteList===!0&&t.hasBlackList===!0&&n&&(e.selected=!0,n===`serial`&&t.configJson.whiteList&&t.configJson.whiteList.length>0&&t.configJson.whiteList.includes(r?e.serialNumber.replace(`-`+r,``):e.serialNumber)&&(e.selected=!0),n===`serial`&&t.configJson.whiteList&&t.configJson.whiteList.length>0&&!t.configJson.whiteList.includes(r?e.serialNumber.replace(`-`+r,``):e.serialNumber)&&(e.selected=!1),n===`serial`&&t.configJson.blackList&&t.configJson.blackList.length>0&&t.configJson.blackList.includes(r?e.serialNumber.replace(`-`+r,``):e.serialNumber)&&(e.selected=!1),n===`name`&&t.configJson.whiteList&&t.configJson.whiteList.length>0&&t.configJson.whiteList.includes(e.deviceName)&&(e.selected=!0),n===`name`&&t.configJson.whiteList&&t.configJson.whiteList.length>0&&!t.configJson.whiteList.includes(e.deviceName)&&(e.selected=!1),n===`name`&&t.configJson.blackList&&t.configJson.blackList.length>0&&t.configJson.blackList.includes(e.deviceName)&&(e.selected=!1)),e.selected},[h]);(0,U.useEffect)(()=>{let e=e=>{if(e.method===`refresh_required`&&e.response.changed!==`matter`)e.response.changed===`plugins`&&e.response.lock?K&&console.log(`HomeDevices received refresh_required: changed=${e.response.changed} lock=${e.response.lock} skipping /api/plugins request`):(K&&console.log(`HomeDevices received refresh_required: changed=${e.response.changed} and sending /api/plugins request`),r({id:C.current,sender:`HomeDevices`,method:`/api/plugins`,src:`Frontend`,dst:`Matterbridge`,params:{}}));else if(e.method===`refresh_required`&&e.response.changed===`matter`)K&&console.log(`HomeDevices received refresh_required: changed=${e.response.changed} and setting matter id ${e.response.matter?.id}`),v(t=>{let n=t.findIndex(t=>t.deviceName.replaceAll(` `,``)===e.response.matter?.id);if(n<0)return K&&console.debug(`HomeDevices: matter id ${e.response.matter?.id} not found`),t;let r=[...t];return r[n]={...r[n],matter:e.response.matter},K&&console.log(`HomeDevices received refresh_required: changed=${e.response.changed} and set matter id ${e.response.matter?.id}`),r});else if(e.method===`restart_required`)K&&console.log(`HomeDevices received restart_required`),d(`Restart Required`);else if(e.method===`restart_not_required`)K&&console.log(`HomeDevices received restart_not_required`),d(``);else if(e.method===`matterbridge_status_update`)K&&console.log(`HomeDevices received matterbridge_status_update: ${e.response.status}`),S(e.response.status);else if(e.method===`state_update`&&e.response.plugin&&e.response.serialNumber&&e.response.cluster.includes(`BasicInformation`)&&e.response.attribute===`reachable`){K&&console.log(`HomeDevices updating device reachability for plugin ${e.response.plugin} serial ${e.response.serialNumber} value ${e.response.value}...`);let t=e.response.value;v(n=>{let r=n.findIndex(t=>t.plugin===e.response.plugin&&t.serialNumber===e.response.serialNumber);if(r<0)return K&&console.warn(`HomeDevices: device to update not found for plugin ${e.response.plugin} serial ${e.response.serialNumber}`),n;let i=[...n];return i[r]={...i[r],reachable:t},i}),K&&console.log(`HomeDevices updated device reachability for plugin ${e.response.plugin} serial ${e.response.serialNumber} value ${e.response.value}`)}if(e.id===C.current&&e.method===`/api/settings`)K&&console.log(`HomeDevices (id: ${e.id}) received settings:`,e.response),m(e.response),d(e.response.matterbridgeInformation.restartRequired||e.response.matterbridgeInformation.fixedRestartRequired?`Restart Required`:``),S(e.response.matterbridgeInformation.bridgeStatus);else if(e.id===C.current&&e.method===`/api/plugins`){if(K&&console.log(`HomeDevices (id: ${e.id}) received ${e.response?.length} plugins:`,e.response),e.response){let t=!0;for(let n of e.response)n.enabled&&(n.loaded!==!0||n.started!==!0||n.error===!0)&&(t=!1);if(!t)return;K&&console.log(`HomeDevices reset plugins and mixedDevices, starting a fresh load cycle`),l(`Loading devices...`),g(e.response),v([]),r({id:C.current,sender:`HomeDevices`,method:`/api/devices`,src:`Frontend`,dst:`Matterbridge`,params:{extended:!0}}),K&&console.log(`HomeDevices sent /api/devices`);for(let t of e.response)t.enabled&&t.loaded===!0&&t.started===!0&&t.error!==!0&&(r({id:C.current,sender:`HomeDevices`,method:`/api/select/devices`,src:`Frontend`,dst:`Matterbridge`,params:{plugin:t.name}}),K&&console.log(`HomeDevices sent /api/select/devices for plugin: ${t.name}`))}}else if(e.id===C.current&&e.method===`/api/devices`){if(K&&console.log(`HomeDevices (id: ${e.id}) received ${e.response?.length} devices:`,e.response),e.response){let t=e.response.map(e=>Object.assign(e,{selected:k(e),origin:`device`}));l(`Registering devices...`),v(e=>{let n=new Set(t.map(e=>`${e.plugin}::${e.serialNumber}`)),r=e.filter(e=>e.origin===`select`&&!n.has(`${e.plugin}::${e.serialNumber}`));return[...t,...r]}),l(`Registered devices:`)}}else if(e.id===C.current&&e.method===`/api/select/devices`&&(K&&console.log(`HomeDevices (id: ${e.id}) received ${e.response?.length} selectDevices for plugin ${e.response&&e.response.length>0?e.response[0].plugin:`without select devices`}:`,e.response),e.response&&e.response.length>0)){let t=e.response[0].plugin;l(`Registering selected devices for ${t}...`),v(n=>{let r=n.filter(e=>e.origin!==`select`||e.plugin!==t),i=r.filter(e=>e.origin===`device`),a=e.response.filter(e=>!i.some(t=>t.plugin===e.plugin&&t.serialNumber.includes(e.serialNumber))).map(e=>Object.assign(e,{selected:k(e),origin:`select`}));return[...r,...a]}),l(`Registered devices:`)}};return i(e,C.current),K&&console.log(`HomeDevices added WebSocket listener id ${C.current}`),()=>{a(e),K&&console.log(`HomeDevices removed WebSocket listener`)}},[i,a,r,k]);let A=c;c.startsWith(`Registered devices:`)&&(A=`Registered devices: ${_.filter(e=>e.origin===`device`).length}/${_.length}`),(0,U.useEffect)(()=>{n&&(K&&console.log(`HomeDevices sending /api/settings and /api/plugins requests`),r({id:C.current,sender:`HomeDevices`,method:`/api/settings`,src:`Frontend`,dst:`Matterbridge`,params:{}}),l(`Loading plugins...`),r({id:C.current,sender:`HomeDevices`,method:`/api/plugins`,src:`Frontend`,dst:`Matterbridge`,params:{}}))},[n,r]);let j=(e,t)=>{K&&console.log(`handleCheckboxChange: checkbox changed to ${e.target.checked} for device ${t.deviceName} serial ${t.serialNumber}`);let n=e.target.checked;v(e=>{let r=e.findIndex(e=>e.plugin===t.plugin&&e.serialNumber===t.serialNumber);if(r<0)return console.error(`handleCheckboxChange: device ${t.deviceName} serial ${t.serialNumber} not found in mixedDevices`),e;let i=[...e];return i[r]={...i[r],selected:n},i}),e.target.checked?r({id:C.current,sender:`HomeDevices`,method:`/api/command`,src:`Frontend`,dst:`Matterbridge`,params:{command:`selectdevice`,plugin:t.plugin,serial:t.serialNumber,name:t.deviceName}}):r({id:C.current,sender:`HomeDevices`,method:`/api/command`,src:`Frontend`,dst:`Matterbridge`,params:{command:`unselectdevice`,plugin:t.plugin,serial:t.serialNumber,name:t.deviceName}})},ee=(e,t=!1)=>{if(K&&console.log(`handleConfigUrl device:`,e.deviceName,`configUrl:`,e.configUrl),e.configUrl&&!fr(e.configUrl,e.plugin)){if(dr(e.configUrl,e.plugin)){let n=`${Xt}${e.configUrl.replace(/^\.?\//,``)}`,r=new URL(n,window.location.origin);r.pathname.endsWith(`/`)||(r.pathname+=`/`);let i=`${r.pathname}${r.search}${r.hash}`;K&&console.log(`handleConfigUrl opening plugin frontend for device:`,e.deviceName,`basePath:`,Xt,`configUrl:`,e.configUrl,`computed pluginFrontendPath:`,i),t?window.open(i,`_blank`):b({name:e.deviceName,path:i})}else window.open(e.configUrl,`_blank`)}},N=lr(e=>ee(e),e=>ee(e,!0));return K&&console.log(`HomeDevices rendering...`),n?(0,J.jsxs)(J.Fragment,{children:[(0,J.jsx)(Z,{style:{flex:`1 1 auto`},children:(0,J.jsx)(Xn,{name:`Devices`,getRowKey:ur,rows:_,columns:O,footerLeft:A,footerRight:u})}),(0,J.jsxs)(L,{open:y!==null,onClose:()=>b(null),slotProps:{paper:{sx:{width:q&&s?`100vw`:`75vw`,height:q&&s?`100vh`:`75vh`,maxWidth:q&&s?`100vw`:`75vw`,maxHeight:q&&s?`100vh`:`75vh`,margin:q&&s?`0px`:void 0,display:`flex`,flexDirection:`column`,overflow:`hidden`,backgroundColor:`var(--div-bg-color)`}}},children:[(0,J.jsx)(E,{style:{display:`flex`,flex:`1 1 auto`,minHeight:0,padding:`0px`,margin:`0px`,overflow:`hidden`,backgroundColor:`var(--div-bg-color)`},children:y&&(0,J.jsx)(`iframe`,{title:`${y.name} frontend`,src:y.path,onLoad:e=>{let t=e.currentTarget.contentDocument;if(!t?.head)return;let n=getComputedStyle(document.body),r=n.getPropertyValue(`--primary-color`).trim()||`#0d6efd`,i=n.getPropertyValue(`--div-bg-color`).trim()||`#111111`;t.getElementById(`matterbridge-plugin-scrollbar-style`)?.remove();let a=t.createElement(`style`);a.id=`matterbridge-plugin-scrollbar-style`,a.textContent=`
|
|
3
3
|
html,
|
|
4
4
|
body {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as e,t}from"./rolldown-runtime-BWaJ3C7D.js";var n=t((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.portal`),r=Symbol.for(`react.fragment`),i=Symbol.for(`react.strict_mode`),a=Symbol.for(`react.profiler`),o=Symbol.for(`react.consumer`),s=Symbol.for(`react.context`),c=Symbol.for(`react.forward_ref`),l=Symbol.for(`react.suspense`),u=Symbol.for(`react.memo`),d=Symbol.for(`react.lazy`),f=Symbol.for(`react.activity`),p=Symbol.for(`react.view_transition`),m=Symbol.iterator;function h(e){return typeof e!=`object`||!e?null:(e=m&&e[m]||e[`@@iterator`],typeof e==`function`?e:null)}var g={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},_=Object.assign,v={};function y(e,t,n){this.props=e,this.context=t,this.refs=v,this.updater=n||g}y.prototype.isReactComponent={},y.prototype.setState=function(e,t){if(typeof e!=`object`&&typeof e!=`function`&&e!=null)throw Error(`takes an object of state variables to update or a function which returns an object of state variables.`);this.updater.enqueueSetState(this,e,t,`setState`)},y.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,`forceUpdate`)};function b(){}b.prototype=y.prototype;function x(e,t,n){this.props=e,this.context=t,this.refs=v,this.updater=n||g}var S=x.prototype=new b;S.constructor=x,_(S,y.prototype),S.isPureReactComponent=!0;var C=Array.isArray;function w(){}var T={H:null,A:null,T:null,S:null},E=Object.prototype.hasOwnProperty;function D(e,n,r){var i=r.ref;return{$$typeof:t,type:e,key:n,ref:i===void 0?null:i,props:r}}function O(e,t){return D(e.type,t,e.props)}function k(e){return typeof e==`object`&&!!e&&e.$$typeof===t}function A(e){var t={"=":`=0`,":":`=2`};return`$`+e.replace(/[=:]/g,function(e){return t[e]})}var ee=/\/+/g;function j(e,t){return typeof e==`object`&&e&&e.key!=null?A(``+e.key):t.toString(36)}function M(e){switch(e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason;default:switch(typeof e.status==`string`?e.then(w,w):(e.status=`pending`,e.then(function(t){e.status===`pending`&&(e.status=`fulfilled`,e.value=t)},function(t){e.status===`pending`&&(e.status=`rejected`,e.reason=t)})),e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason}}throw e}function N(e,r,i,a,o){var s=typeof e;(s===`undefined`||s===`boolean`)&&(e=null);var c=!1;if(e===null)c=!0;else switch(s){case`bigint`:case`string`:case`number`:c=!0;break;case`object`:switch(e.$$typeof){case t:case n:c=!0;break;case d:return c=e._init,N(c(e._payload),r,i,a,o)}}if(c)return o=o(e),c=a===``?`.`+j(e,0):a,C(o)?(i=``,c!=null&&(i=c.replace(ee,`$&/`)+`/`),N(o,r,i,``,function(e){return e})):o!=null&&(k(o)&&(o=O(o,i+(o.key==null||e&&e.key===o.key?``:(``+o.key).replace(ee,`$&/`)+`/`)+c)),r.push(o)),1;c=0;var l=a===``?`.`:a+`:`;if(C(e))for(var u=0;u<e.length;u++)a=e[u],s=l+j(a,u),c+=N(a,r,i,s,o);else if(u=h(e),typeof u==`function`)for(e=u.call(e),u=0;!(a=e.next()).done;)a=a.value,s=l+j(a,u++),c+=N(a,r,i,s,o);else if(s===`object`){if(typeof e.then==`function`)return N(M(e),r,i,a,o);throw r=String(e),Error(`Objects are not valid as a React child (found: `+(r===`[object Object]`?`object with keys {`+Object.keys(e).join(`, `)+`}`:r)+`). If you meant to render a collection of children, use an array instead.`)}return c}function P(e,t,n){if(e==null)return e;var r=[],i=0;return N(e,r,``,``,function(e){return t.call(n,e,i++)}),r}function F(e){if(e._status===-1){var t=e._result,n=t();n.then(function(t){(e._status===0||e._status===-1)&&(e._status=1,e._result=t,n.status===void 0&&(n.status=`fulfilled`,n.value=t))},function(t){(e._status===0||e._status===-1)&&(e._status=2,e._result=t,n.status===void 0&&(n.status=`rejected`,n.reason=t))}),e._status===-1&&(e._status=0,e._result=n)}if(e._status===1)return e._result.default;throw e._result}var I=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)};function L(e){var t=T.T,n={};n.types=t===null?null:t.types,T.T=n;try{var r=e(),i=T.S;i!==null&&i(n,r),typeof r==`object`&&r&&typeof r.then==`function`&&r.then(w,I)}catch(e){I(e)}finally{t!==null&&n.types!==null&&(t.types=n.types),T.T=t}}function R(e){var t=T.T;if(t!==null){var n=t.types;n===null?t.types=[e]:n.indexOf(e)===-1&&n.push(e)}else L(R.bind(null,e))}var te={map:P,forEach:function(e,t,n){P(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return P(e,function(){t++}),t},toArray:function(e){return P(e,function(e){return e})||[]},only:function(e){if(!k(e))throw Error(`React.Children.only expected to receive a single React element child.`);return e}};e.Activity=f,e.Children=te,e.Component=y,e.Fragment=r,e.Profiler=a,e.PureComponent=x,e.StrictMode=i,e.Suspense=l,e.ViewTransition=p,e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=T,e.__COMPILER_RUNTIME={__proto__:null,c:function(e){return T.H.useMemoCache(e)}},e.addTransitionType=R,e.cache=function(e){return function(){return e.apply(null,arguments)}},e.cacheSignal=function(){return null},e.cloneElement=function(e,t,n){if(e==null)throw Error(`The argument must be a React element, but you passed `+e+`.`);var r=_({},e.props),i=e.key;if(t!=null)for(a in t.key!==void 0&&(i=``+t.key),t)!E.call(t,a)||a===`key`||a===`__self`||a===`__source`||a===`ref`&&t.ref===void 0||(r[a]=t[a]);var a=arguments.length-2;if(a===1)r.children=n;else if(1<a){for(var o=Array(a),s=0;s<a;s++)o[s]=arguments[s+2];r.children=o}return D(e.type,i,r)},e.createContext=function(e){return e={$$typeof:s,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:o,_context:e},e},e.createElement=function(e,t,n){var r,i={},a=null;if(t!=null)for(r in t.key!==void 0&&(a=``+t.key),t)E.call(t,r)&&r!==`key`&&r!==`__self`&&r!==`__source`&&(i[r]=t[r]);var o=arguments.length-2;if(o===1)i.children=n;else if(1<o){for(var s=Array(o),c=0;c<o;c++)s[c]=arguments[c+2];i.children=s}if(e&&e.defaultProps)for(r in o=e.defaultProps,o)i[r]===void 0&&(i[r]=o[r]);return D(e,a,i)},e.createRef=function(){return{current:null}},e.forwardRef=function(e){return{$$typeof:c,render:e}},e.isValidElement=k,e.lazy=function(e){return{$$typeof:d,_payload:{_status:-1,_result:e},_init:F}},e.memo=function(e,t){return{$$typeof:u,type:e,compare:t===void 0?null:t}},e.startTransition=L,e.unstable_useCacheRefresh=function(){return T.H.useCacheRefresh()},e.use=function(e){return T.H.use(e)},e.useActionState=function(e,t,n){return T.H.useActionState(e,t,n)},e.useCallback=function(e,t){return T.H.useCallback(e,t)},e.useContext=function(e){return T.H.useContext(e)},e.useDebugValue=function(){},e.useDeferredValue=function(e,t){return T.H.useDeferredValue(e,t)},e.useEffect=function(e,t){return T.H.useEffect(e,t)},e.useEffectEvent=function(e){return T.H.useEffectEvent(e)},e.useId=function(){return T.H.useId()},e.useImperativeHandle=function(e,t,n){return T.H.useImperativeHandle(e,t,n)},e.useInsertionEffect=function(e,t){return T.H.useInsertionEffect(e,t)},e.useLayoutEffect=function(e,t){return T.H.useLayoutEffect(e,t)},e.useMemo=function(e,t){return T.H.useMemo(e,t)},e.useOptimistic=function(e,t){return T.H.useOptimistic(e,t)},e.useReducer=function(e,t,n){return T.H.useReducer(e,t,n)},e.useRef=function(e){return T.H.useRef(e)},e.useState=function(e){return T.H.useState(e)},e.useSyncExternalStore=function(e,t,n){return T.H.useSyncExternalStore(e,t,n)},e.useTransition=function(){return T.H.useTransition()},e.version=`19.3.1`})),r=t(((e,t)=>{t.exports=n()}));function i(){return i=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},i.apply(null,arguments)}var a=e(r());function o(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}function s(e){var t=document.createElement(`style`);return t.setAttribute(`data-emotion`,e.key),e.nonce!==void 0&&t.setAttribute(`nonce`,e.nonce),t.appendChild(document.createTextNode(``)),t.setAttribute(`data-s`,``),t}var c=function(){function e(e){var t=this;this._insertTag=function(e){var n=t.tags.length===0?t.insertionPoint?t.insertionPoint.nextSibling:t.prepend?t.container.firstChild:t.before:t.tags[t.tags.length-1].nextSibling;t.container.insertBefore(e,n),t.tags.push(e)},this.isSpeedy=e.speedy===void 0||e.speedy,this.tags=[],this.ctr=0,this.nonce=e.nonce,this.key=e.key,this.container=e.container,this.prepend=e.prepend,this.insertionPoint=e.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(e){e.forEach(this._insertTag)},t.insert=function(e){this.ctr%(this.isSpeedy?65e3:1)==0&&this._insertTag(s(this));var t=this.tags[this.tags.length-1];if(this.isSpeedy){var n=o(t);try{n.insertRule(e,n.cssRules.length)}catch{}}else t.appendChild(document.createTextNode(e));this.ctr++},t.flush=function(){this.tags.forEach(function(e){return e.parentNode?.removeChild(e)}),this.tags=[],this.ctr=0},e}(),l=`-ms-`,u=`-moz-`,d=`-webkit-`,f=`comm`,p=`rule`,m=`decl`,h=`@import`,g=`@keyframes`,_=`@layer`,v=Math.abs,y=String.fromCharCode,b=Object.assign;function x(e,t){return E(e,0)^45?(((t<<2^E(e,0))<<2^E(e,1))<<2^E(e,2))<<2^E(e,3):0}function S(e){return e.trim()}function C(e,t){return(e=t.exec(e))?e[0]:e}function w(e,t,n){return e.replace(t,n)}function T(e,t){return e.indexOf(t)}function E(e,t){return e.charCodeAt(t)|0}function D(e,t,n){return e.slice(t,n)}function O(e){return e.length}function k(e){return e.length}function A(e,t){return t.push(e),e}function ee(e,t){return e.map(t).join(``)}var j=1,M=1,N=0,P=0,F=0,I=``;function L(e,t,n,r,i,a,o){return{value:e,root:t,parent:n,type:r,props:i,children:a,line:j,column:M,length:o,return:``}}function R(e,t){return b(L(``,null,null,``,null,null,0),e,{length:-e.length},t)}function te(){return F}function ne(){return F=P>0?E(I,--P):0,M--,F===10&&(M=1,j--),F}function z(){return F=P<N?E(I,P++):0,M++,F===10&&(M=1,j++),F}function B(){return E(I,P)}function V(){return P}function H(e,t){return D(I,e,t)}function U(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function re(e){return j=M=1,N=O(I=e),P=0,[]}function ie(e){return I=``,e}function W(e){return S(H(P-1,G(e===91?e+2:e===40?e+1:e)))}function ae(e){for(;(F=B())&&F<33;)z();return U(e)>2||U(F)>3?``:` `}function oe(e,t){for(;--t&&z()&&!(F<48||F>102||F>57&&F<65||F>70&&F<97););return H(e,V()+(t<6&&B()==32&&z()==32))}function G(e){for(;z();)switch(F){case e:return P;case 34:case 39:e!==34&&e!==39&&G(F);break;case 40:e===41&&G(e);break;case 92:z()}return P}function se(e,t){for(;z()&&e+F!==57&&(e+F!==84||B()!==47););return`/*`+H(t,P-1)+`*`+y(e===47?e:z())}function ce(e){for(;!U(B());)z();return H(e,P)}function le(e){return ie(K(``,null,null,null,[``],e=re(e),0,[0],e))}function K(e,t,n,r,i,a,o,s,c){for(var l=0,u=0,d=o,f=0,p=0,m=0,h=1,g=1,_=1,v=0,b=``,x=i,S=a,C=r,D=b;g;)switch(m=v,v=z()){case 40:if(m!=108&&E(D,d-1)==58){T(D+=w(W(v),`&`,`&\f`),`&\f`)!=-1&&(_=-1);break}case 34:case 39:case 91:D+=W(v);break;case 9:case 10:case 13:case 32:D+=ae(m);break;case 92:D+=oe(V()-1,7);continue;case 47:switch(B()){case 42:case 47:A(de(se(z(),V()),t,n),c);break;default:D+=`/`}break;case 123*h:s[l++]=O(D)*_;case 125*h:case 59:case 0:switch(v){case 0:case 125:g=0;case 59+u:_==-1&&(D=w(D,/\f/g,``)),p>0&&O(D)-d&&A(p>32?fe(D+`;`,r,n,d-1):fe(w(D,` `,``)+`;`,r,n,d-2),c);break;case 59:D+=`;`;default:if(A(C=ue(D,t,n,l,u,i,s,b,x=[],S=[],d),a),v===123){if(u===0)K(D,t,C,C,x,a,d,s,S);else switch(f===99&&E(D,3)===110?100:f){case 100:case 108:case 109:case 115:K(e,C,C,r&&A(ue(e,C,C,0,0,i,s,b,i,x=[],d),S),i,S,d,s,r?x:S);break;default:K(D,C,C,C,[``],S,0,s,S)}}}l=u=p=0,h=_=1,b=D=``,d=o;break;case 58:d=1+O(D),p=m;default:if(h<1){if(v==123)--h;else if(v==125&&h++==0&&ne()==125)continue}switch(D+=y(v),v*h){case 38:_=u>0?1:(D+=`\f`,-1);break;case 44:s[l++]=(O(D)-1)*_,_=1;break;case 64:B()===45&&(D+=W(z())),f=B(),u=d=O(b=D+=ce(V())),v++;break;case 45:m===45&&O(D)==2&&(h=0)}}return a}function ue(e,t,n,r,i,a,o,s,c,l,u){for(var d=i-1,f=i===0?a:[``],m=k(f),h=0,g=0,_=0;h<r;++h)for(var y=0,b=D(e,d+1,d=v(g=o[h])),x=e;y<m;++y)(x=S(g>0?f[y]+` `+b:w(b,/&\f/g,f[y])))&&(c[_++]=x);return L(e,t,n,i===0?p:s,c,l,u)}function de(e,t,n){return L(e,t,n,f,y(te()),D(e,2,-2),0)}function fe(e,t,n,r){return L(e,t,n,m,D(e,0,r),D(e,r+1,-1),r)}function q(e,t){for(var n=``,r=k(e),i=0;i<r;i++)n+=t(e[i],i,e,t)||``;return n}function pe(e,t,n,r){switch(e.type){case _:if(e.children.length)break;case h:case m:return e.return=e.return||e.value;case f:return``;case g:return e.return=e.value+`{`+q(e.children,r)+`}`;case p:e.value=e.props.join(`,`)}return O(n=q(e.children,r))?e.return=e.value+`{`+n+`}`:``}function me(e){var t=k(e);return function(n,r,i,a){for(var o=``,s=0;s<t;s++)o+=e[s](n,r,i,a)||``;return o}}function he(e){return function(t){t.root||(t=t.return)&&e(t)}}function ge(e){var t=Object.create(null);return function(n){return t[n]===void 0&&(t[n]=e(n)),t[n]}}var _e=function(e,t,n){for(var r=0,i=0;r=i,i=B(),r===38&&i===12&&(t[n]=1),!U(i);)z();return H(e,P)},ve=function(e,t){var n=-1,r=44;do switch(U(r)){case 0:r===38&&B()===12&&(t[n]=1),e[n]+=_e(P-1,t,n);break;case 2:e[n]+=W(r);break;case 4:if(r===44){e[++n]=B()===58?`&\f`:``,t[n]=e[n].length;break}default:e[n]+=y(r)}while(r=z());return e},ye=function(e,t){return ie(ve(re(e),t))},be=new WeakMap,xe=function(e){if(!(e.type!==`rule`||!e.parent||e.length<1)){for(var t=e.value,n=e.parent,r=e.column===n.column&&e.line===n.line;n.type!==`rule`;)if(n=n.parent,!n)return;if((e.props.length!==1||t.charCodeAt(0)===58||be.get(n))&&!r){be.set(e,!0);for(var i=[],a=ye(t,i),o=n.props,s=0,c=0;s<a.length;s++)for(var l=0;l<o.length;l++,c++)e.props[c]=i[s]?a[s].replace(/&\f/g,o[l]):o[l]+` `+a[s]}}},Se=function(e){if(e.type===`decl`){var t=e.value;t.charCodeAt(0)===108&&t.charCodeAt(2)===98&&(e.return=``,e.value=``)}};function Ce(e,t){switch(x(e,t)){case 5103:return d+`print-`+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return d+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return d+e+u+e+l+e+e;case 6828:case 4268:return d+e+l+e+e;case 6165:return d+e+l+`flex-`+e+e;case 5187:return d+e+w(e,/(\w+).+(:[^]+)/,d+`box-$1$2`+l+`flex-$1$2`)+e;case 5443:return d+e+l+`flex-item-`+w(e,/flex-|-self/,``)+e;case 4675:return d+e+l+`flex-line-pack`+w(e,/align-content|flex-|-self/,``)+e;case 5548:return d+e+l+w(e,`shrink`,`negative`)+e;case 5292:return d+e+l+w(e,`basis`,`preferred-size`)+e;case 6060:return d+`box-`+w(e,`-grow`,``)+d+e+l+w(e,`grow`,`positive`)+e;case 4554:return d+w(e,/([^-])(transform)/g,`$1`+d+`$2`)+e;case 6187:return w(w(w(e,/(zoom-|grab)/,d+`$1`),/(image-set)/,d+`$1`),e,``)+e;case 5495:case 3959:return w(e,/(image-set\([^]*)/,d+"$1$`$1");case 4968:return w(w(e,/(.+:)(flex-)?(.*)/,d+`box-pack:$3`+l+`flex-pack:$3`),/s.+-b[^;]+/,`justify`)+d+e+e;case 4095:case 3583:case 4068:case 2532:return w(e,/(.+)-inline(.+)/,d+`$1$2`)+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(O(e)-1-t>6)switch(E(e,t+1)){case 109:if(E(e,t+4)!==45)break;case 102:return w(e,/(.+:)(.+)-([^]+)/,`$1`+d+`$2-$3$1`+u+(E(e,t+3)==108?`$3`:`$2-$3`))+e;case 115:return~T(e,`stretch`)?Ce(w(e,`stretch`,`fill-available`),t)+e:e}break;case 4949:if(E(e,t+1)!==115)break;case 6444:switch(E(e,O(e)-3-(~T(e,`!important`)&&10))){case 107:return w(e,`:`,`:`+d)+e;case 101:return w(e,/(.+:)([^;!]+)(;|!.+)?/,`$1`+d+(E(e,14)===45?`inline-`:``)+`box$3$1`+d+`$2$3$1`+l+`$2box$3`)+e}break;case 5936:switch(E(e,t+11)){case 114:return d+e+l+w(e,/[svh]\w+-[tblr]{2}/,`tb`)+e;case 108:return d+e+l+w(e,/[svh]\w+-[tblr]{2}/,`tb-rl`)+e;case 45:return d+e+l+w(e,/[svh]\w+-[tblr]{2}/,`lr`)+e}return d+e+l+e+e}return e}var we=[function(e,t,n,r){if(e.length>-1&&!e.return)switch(e.type){case m:e.return=Ce(e.value,e.length);break;case g:return q([R(e,{value:w(e.value,`@`,`@`+d)})],r);case p:if(e.length)return ee(e.props,function(t){switch(C(t,/(::plac\w+|:read-\w+)/)){case`:read-only`:case`:read-write`:return q([R(e,{props:[w(t,/:(read-\w+)/,`:`+u+`$1`)]})],r);case`::placeholder`:return q([R(e,{props:[w(t,/:(plac\w+)/,`:`+d+`input-$1`)]}),R(e,{props:[w(t,/:(plac\w+)/,`:`+u+`$1`)]}),R(e,{props:[w(t,/:(plac\w+)/,l+`input-$1`)]})],r)}return``})}}],Te=function(e){var t=e.key;if(t===`css`){var n=document.querySelectorAll(`style[data-emotion]:not([data-s])`);Array.prototype.forEach.call(n,function(e){e.getAttribute(`data-emotion`).indexOf(` `)!==-1&&(document.head.appendChild(e),e.setAttribute(`data-s`,``))})}var r=e.stylisPlugins||we,i={},a,o=[];a=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll(`style[data-emotion^="`+t+` "]`),function(e){for(var t=e.getAttribute(`data-emotion`).split(` `),n=1;n<t.length;n++)i[t[n]]=!0;o.push(e)});var s,l=[xe,Se],u,d=[pe,he(function(e){u.insert(e)})],f=me(l.concat(r,d)),p=function(e){return q(le(e),f)};s=function(e,t,n,r){u=n,p(e?e+`{`+t.styles+`}`:t.styles),r&&(m.inserted[t.name]=!0)};var m={key:t,sheet:new c({key:t,container:a,nonce:e.nonce,speedy:e.speedy,prepend:e.prepend,insertionPoint:e.insertionPoint}),nonce:e.nonce,inserted:i,registered:{},insert:s};return m.sheet.hydrate(o),m},Ee=t((e=>{var t=typeof Symbol==`function`&&Symbol.for,n=t?Symbol.for(`react.element`):60103,r=t?Symbol.for(`react.portal`):60106,i=t?Symbol.for(`react.fragment`):60107,a=t?Symbol.for(`react.strict_mode`):60108,o=t?Symbol.for(`react.profiler`):60114,s=t?Symbol.for(`react.provider`):60109,c=t?Symbol.for(`react.context`):60110,l=t?Symbol.for(`react.async_mode`):60111,u=t?Symbol.for(`react.concurrent_mode`):60111,d=t?Symbol.for(`react.forward_ref`):60112,f=t?Symbol.for(`react.suspense`):60113,p=t?Symbol.for(`react.suspense_list`):60120,m=t?Symbol.for(`react.memo`):60115,h=t?Symbol.for(`react.lazy`):60116,g=t?Symbol.for(`react.block`):60121,_=t?Symbol.for(`react.fundamental`):60117,v=t?Symbol.for(`react.responder`):60118,y=t?Symbol.for(`react.scope`):60119;function b(e){if(typeof e==`object`&&e){var t=e.$$typeof;switch(t){case n:switch(e=e.type,e){case l:case u:case i:case o:case a:case f:return e;default:switch(e&&=e.$$typeof,e){case c:case d:case h:case m:case s:return e;default:return t}}case r:return t}}}function x(e){return b(e)===u}e.AsyncMode=l,e.ConcurrentMode=u,e.ContextConsumer=c,e.ContextProvider=s,e.Element=n,e.ForwardRef=d,e.Fragment=i,e.Lazy=h,e.Memo=m,e.Portal=r,e.Profiler=o,e.StrictMode=a,e.Suspense=f,e.isAsyncMode=function(e){return x(e)||b(e)===l},e.isConcurrentMode=x,e.isContextConsumer=function(e){return b(e)===c},e.isContextProvider=function(e){return b(e)===s},e.isElement=function(e){return typeof e==`object`&&!!e&&e.$$typeof===n},e.isForwardRef=function(e){return b(e)===d},e.isFragment=function(e){return b(e)===i},e.isLazy=function(e){return b(e)===h},e.isMemo=function(e){return b(e)===m},e.isPortal=function(e){return b(e)===r},e.isProfiler=function(e){return b(e)===o},e.isStrictMode=function(e){return b(e)===a},e.isSuspense=function(e){return b(e)===f},e.isValidElementType=function(e){return typeof e==`string`||typeof e==`function`||e===i||e===u||e===o||e===a||e===f||e===p||typeof e==`object`&&!!e&&(e.$$typeof===h||e.$$typeof===m||e.$$typeof===s||e.$$typeof===c||e.$$typeof===d||e.$$typeof===_||e.$$typeof===v||e.$$typeof===y||e.$$typeof===g)},e.typeOf=b})),De=t(((e,t)=>{t.exports=Ee()})),Oe=t(((e,t)=>{var n=De(),r={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},i={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},a={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},o={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},s={};s[n.ForwardRef]=a,s[n.Memo]=o;function c(e){return n.isMemo(e)?o:s[e.$$typeof]||r}var l=Object.defineProperty,u=Object.getOwnPropertyNames,d=Object.getOwnPropertySymbols,f=Object.getOwnPropertyDescriptor,p=Object.getPrototypeOf,m=Object.prototype;function h(e,t,n){if(typeof t!=`string`){if(m){var r=p(t);r&&r!==m&&h(e,r,n)}var a=u(t);d&&(a=a.concat(d(t)));for(var o=c(e),s=c(t),g=0;g<a.length;++g){var _=a[g];if(!i[_]&&!(n&&n[_])&&!(s&&s[_])&&!(o&&o[_])){var v=f(t,_);try{l(e,_,v)}catch{}}}}return e}t.exports=h}));function ke(e,t,n){var r=``;return n.split(` `).forEach(function(n){e[n]===void 0?n&&(r+=n+` `):t.push(e[n]+`;`)}),r}var J=function(e,t,n){var r=e.key+`-`+t.name;n===!1&&e.registered[r]===void 0&&(e.registered[r]=t.styles)},Y=function(e,t,n){J(e,t,n);var r=e.key+`-`+t.name;if(e.inserted[t.name]===void 0){var i=t;do e.insert(t===i?`.`+r:``,i,e.sheet,!0),i=i.next;while(i!==void 0)}};function Ae(e){for(var t=0,n,r=0,i=e.length;i>=4;++r,i-=4)n=e.charCodeAt(r)&255|(e.charCodeAt(++r)&255)<<8|(e.charCodeAt(++r)&255)<<16|(e.charCodeAt(++r)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,t=(n&65535)*1540483477+((n>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(i){case 3:t^=(e.charCodeAt(r+2)&255)<<16;case 2:t^=(e.charCodeAt(r+1)&255)<<8;case 1:t^=e.charCodeAt(r)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var je={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},Me=/[A-Z]|^ms/g,Ne=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Pe=function(e){return e.charCodeAt(1)===45},Fe=function(e){return e!=null&&typeof e!=`boolean`},Ie=ge(function(e){return Pe(e)?e:e.replace(Me,`-$&`).toLowerCase()}),Le=function(e,t){switch(e){case`animation`:case`animationName`:if(typeof t==`string`)return t.replace(Ne,function(e,t,n){return Z={name:t,styles:n,next:Z},t})}return je[e]!==1&&!Pe(e)&&typeof t==`number`&&t!==0?t+`px`:t};function X(e,t,n){if(n==null)return``;var r=n;if(r.__emotion_styles!==void 0)return r;switch(typeof n){case`boolean`:return``;case`object`:var i=n;if(i.anim===1)return Z={name:i.name,styles:i.styles,next:Z},i.name;var a=n;if(a.styles!==void 0){var o=a.next;if(o!==void 0)for(;o!==void 0;)Z={name:o.name,styles:o.styles,next:Z},o=o.next;return a.styles+`;`}return Re(e,t,n);case`function`:if(e!==void 0){var s=Z,c=n(e);return Z=s,X(e,t,c)}}var l=n;if(t==null)return l;var u=t[l];return u===void 0?l:u}function Re(e,t,n){var r=``;if(Array.isArray(n))for(var i=0;i<n.length;i++)r+=X(e,t,n[i])+`;`;else for(var a in n){var o=n[a];if(typeof o!=`object`){var s=o;t!=null&&t[s]!==void 0?r+=a+`{`+t[s]+`}`:Fe(s)&&(r+=Ie(a)+`:`+Le(a,s)+`;`)}else if(Array.isArray(o)&&typeof o[0]==`string`&&(t==null||t[o[0]]===void 0))for(var c=0;c<o.length;c++)Fe(o[c])&&(r+=Ie(a)+`:`+Le(a,o[c])+`;`);else{var l=X(e,t,o);switch(a){case`animation`:case`animationName`:r+=Ie(a)+`:`+l+`;`;break;default:r+=a+`{`+l+`}`}}}return r}var ze=/label:\s*([^\s;{]+)\s*(;|$)/g,Z;function Q(e,t,n){if(e.length===1&&typeof e[0]==`object`&&e[0]!==null&&e[0].styles!==void 0)return e[0];var r=!0,i=``;Z=void 0;var a=e[0];a==null||a.raw===void 0?(r=!1,i+=X(n,t,a)):i+=a[0];for(var o=1;o<e.length;o++)i+=X(n,t,e[o]),r&&(i+=a[o]);ze.lastIndex=0;for(var s=``,c;(c=ze.exec(i))!==null;)s+=`-`+c[1];return{name:Ae(i)+s,styles:i,next:Z}}var Be=function(e){return e()},Ve=a.useInsertionEffect?a.useInsertionEffect:!1,He=Ve||Be,Ue=Ve||a.useLayoutEffect,We=a.createContext(typeof HTMLElement<`u`?Te({key:`css`}):null);We.Provider;var Ge=function(e){return(0,a.forwardRef)(function(t,n){return e(t,(0,a.useContext)(We),n)})},$=a.createContext({}),Ke={}.hasOwnProperty,qe=`__EMOTION_TYPE_PLEASE_DO_NOT_USE__`,Je=function(e,t){var n={};for(var r in t)Ke.call(t,r)&&(n[r]=t[r]);return n[qe]=e,n},Ye=function(e){var t=e.cache,n=e.serialized,r=e.isStringTag;return J(t,n,r),He(function(){return Y(t,n,r)}),null},Xe=Ge(function(e,t,n){var r=e.css;typeof r==`string`&&t.registered[r]!==void 0&&(r=t.registered[r]);var i=e[qe],o=[r],s=``;typeof e.className==`string`?s=ke(t.registered,o,e.className):e.className!=null&&(s=e.className+` `);var c=Q(o,void 0,a.useContext($));s+=t.key+`-`+c.name;var l={};for(var u in e)Ke.call(e,u)&&u!==`css`&&u!==qe&&(l[u]=e[u]);return l.className=s,n&&(l.ref=n),a.createElement(a.Fragment,null,a.createElement(Ye,{cache:t,serialized:c,isStringTag:typeof i==`string`}),a.createElement(i,l))});Oe();var Ze=function(e,t){var n=arguments;if(t==null||!Ke.call(t,`css`))return a.createElement.apply(void 0,n);var r=n.length,i=Array(r);i[0]=Xe,i[1]=Je(e,t);for(var o=2;o<r;o++)i[o]=n[o];return a.createElement.apply(null,i)};(function(e){var t;t||=e.JSX||={}})(Ze||={});var Qe=Ge(function(e,t){var n=e.styles,r=Q([n],void 0,a.useContext($)),i=a.useRef();return Ue(function(){var e=t.key+`-global`,n=new t.sheet.constructor({key:e,nonce:t.sheet.nonce,container:t.sheet.container,speedy:t.sheet.isSpeedy}),a=!1,o=document.querySelector(`style[data-emotion="`+e+` `+r.name+`"]`);return t.sheet.tags.length&&(n.before=t.sheet.tags[0]),o!==null&&(a=!0,o.setAttribute(`data-emotion`,e),n.hydrate([o])),i.current=[n,a],function(){n.flush()}},[t]),Ue(function(){var e=i.current,n=e[0];e[1]?e[1]=!1:(r.next!==void 0&&Y(t,r.next,!0),n.tags.length&&(n.before=n.tags[n.tags.length-1].nextElementSibling,n.flush()),t.insert(``,r,n,!1))},[t,r.name]),null});function $e(){return Q([...arguments])}function et(){var e=$e.apply(void 0,arguments),t=`animation-`+e.name;return{name:t,styles:`@keyframes `+t+`{`+e.styles+`}`,anim:1,toString:function(){return`_EMO_`+this.name+`_`+this.styles+`_EMO_`}}}var tt=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|fetchpriority|fetchPriority|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|popover|popoverTarget|popoverTargetAction|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,nt=ge(function(e){return tt.test(e)||e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)<91}),rt=function(e){return e!==`theme`},it=function(e){return typeof e==`string`&&e.charCodeAt(0)>96?nt:rt},at=function(e,t,n){var r;if(t){var i=t.shouldForwardProp;r=e.__emotion_forwardProp&&i?function(t){return e.__emotion_forwardProp(t)&&i(t)}:i}return typeof r!=`function`&&n&&(r=e.__emotion_forwardProp),r},ot=function(e){var t=e.cache,n=e.serialized,r=e.isStringTag;return J(t,n,r),He(function(){return Y(t,n,r)}),null},st=function e(t,n){var r=t.__emotion_real===t,o=r&&t.__emotion_base||t,s,c;n!==void 0&&(s=n.label,c=n.target);var l=at(t,n,r),u=l||it(o),d=!u(`as`);return function(){var f=arguments,p=r&&t.__emotion_styles!==void 0?t.__emotion_styles.slice(0):[];if(s!==void 0&&p.push(`label:`+s+`;`),f[0]==null||f[0].raw===void 0)p.push.apply(p,f);else{var m=f[0];p.push(m[0]);for(var h=f.length,g=1;g<h;g++)p.push(f[g],m[g])}var _=Ge(function(e,t,n){var r=d&&e.as||o,i=``,s=[],f=e;if(e.theme==null){for(var m in f={},e)f[m]=e[m];f.theme=a.useContext($)}typeof e.className==`string`?i=ke(t.registered,s,e.className):e.className!=null&&(i=e.className+` `);var h=Q(p.concat(s),t.registered,f);i+=t.key+`-`+h.name,c!==void 0&&(i+=` `+c);var g=d&&l===void 0?it(r):u,_={};for(var v in e)d&&v===`as`||g(v)&&(_[v]=e[v]);return _.className=i,n&&(_.ref=n),a.createElement(a.Fragment,null,a.createElement(ot,{cache:t,serialized:h,isStringTag:typeof r==`string`}),a.createElement(r,_))});return _.displayName=s===void 0?`Styled(`+(typeof o==`string`?o:o.displayName||o.name||`Component`)+`)`:s,_.defaultProps=t.defaultProps,_.__emotion_real=_,_.__emotion_base=o,_.__emotion_styles=p,_.__emotion_forwardProp=l,Object.defineProperty(_,"toString",{value:function(){return`.`+c}}),_.withComponent=function(t,r){return e(t,i({},n,r,{shouldForwardProp:at(_,r,!0)})).apply(void 0,p)},_}},ct=`a.abbr.address.area.article.aside.audio.b.base.bdi.bdo.big.blockquote.body.br.button.canvas.caption.cite.code.col.colgroup.data.datalist.dd.del.details.dfn.dialog.div.dl.dt.em.embed.fieldset.figcaption.figure.footer.form.h1.h2.h3.h4.h5.h6.head.header.hgroup.hr.html.i.iframe.img.input.ins.kbd.keygen.label.legend.li.link.main.map.mark.marquee.menu.menuitem.meta.meter.nav.noscript.object.ol.optgroup.option.output.p.param.picture.pre.progress.q.rp.rt.ruby.s.samp.script.section.select.small.source.span.strong.style.sub.summary.sup.table.tbody.td.textarea.tfoot.th.thead.time.title.tr.track.u.ul.var.video.wbr.circle.clipPath.defs.ellipse.foreignObject.g.image.line.linearGradient.mask.path.pattern.polygon.polyline.radialGradient.rect.stop.svg.text.tspan`.split(`.`),lt=st.bind(null);ct.forEach(function(e){lt[e]=lt(e)});export{$ as a,et as i,Qe as n,Q as o,$e as r,r as s,lt as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{t as e}from"./rolldown-runtime-BWaJ3C7D.js";import{s as t}from"./vendor_emotion-DDpeU9YY.js";var n=e(((e,t)=>{t.exports=`SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED`})),r=e(((e,t)=>{var r=n();function i(){}function a(){}a.resetWarningCache=i,t.exports=function(){function e(e,t,n,i,a,o){if(o!==r){var s=Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw s.name=`Invariant Violation`,s}}e.isRequired=e;function t(){return e}var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:a,resetWarningCache:i};return n.PropTypes=n,n}})),i=e(((e,t)=>{t.exports=r()()})),a=`M19,18.31V20A2,2 0 0,1 17,22H7A2,2 0 0,1 5,20V16.3C4.54,16.12 3.95,16 3,16A1,1 0 0,1 2,15A1,1 0 0,1 3,14C3.82,14 4.47,14.08 5,14.21V12.3C4.54,12.12 3.95,12 3,12A1,1 0 0,1 2,11A1,1 0 0,1 3,10C3.82,10 4.47,10.08 5,10.21V8.3C4.54,8.12 3.95,8 3,8A1,1 0 0,1 2,7A1,1 0 0,1 3,6C3.82,6 4.47,6.08 5,6.21V4A2,2 0 0,1 7,2H17A2,2 0 0,1 19,4V6.16C20.78,6.47 21.54,7.13 21.71,7.29C22.1,7.68 22.1,8.32 21.71,8.71C21.32,9.1 20.8,9.09 20.29,8.71V8.71C20.29,8.71 19.25,8 17,8C15.74,8 14.91,8.41 13.95,8.9C12.91,9.41 11.74,10 10,10C9.64,10 9.31,10 9,9.96V7.95C9.3,8 9.63,8 10,8C11.26,8 12.09,7.59 13.05,7.11C14.09,6.59 15.27,6 17,6V4H7V20H17V18C18.5,18 18.97,18.29 19,18.31M17,10C15.27,10 14.09,10.59 13.05,11.11C12.09,11.59 11.26,12 10,12C9.63,12 9.3,12 9,11.95V13.96C9.31,14 9.64,14 10,14C11.74,14 12.91,13.41 13.95,12.9C14.91,12.42 15.74,12 17,12C19.25,12 20.29,12.71 20.29,12.71V12.71C20.8,13.1 21.32,13.1 21.71,12.71C22.1,12.32 22.1,11.69 21.71,11.29C21.5,11.08 20.25,10 17,10M17,14C15.27,14 14.09,14.59 13.05,15.11C12.09,15.59 11.26,16 10,16C9.63,16 9.3,16 9,15.95V17.96C9.31,18 9.64,18 10,18C11.74,18 12.91,17.41 13.95,16.9C14.91,16.42 15.74,16 17,16C19.25,16 20.29,16.71 20.29,16.71V16.71C20.8,17.1 21.32,17.1 21.71,16.71C22.1,16.32 22.1,15.69 21.71,15.29C21.5,15.08 20.25,14 17,14Z`,o=`M11,9A4,4 0 0,1 15,13A4,4 0 0,1 11,17A4,4 0 0,1 7,13A4,4 0 0,1 11,9M11,11A2,2 0 0,0 9,13A2,2 0 0,0 11,15A2,2 0 0,0 13,13A2,2 0 0,0 11,11M7,4H14A4,4 0 0,1 18,8V9H16V8A2,2 0 0,0 14,6H7A2,2 0 0,0 5,8V20H16V18H18V22H3V8A4,4 0 0,1 7,4M16,11C18.5,11 18.5,9 21,9V11C18.5,11 18.5,13 16,13V11M16,15C18.5,15 18.5,13 21,13V15C18.5,15 18.5,17 16,17V15Z`,s=`M21 8C19.5 8 18.7 9.4 19.1 10.5L15.5 14.1C15.2 14 14.8 14 14.5 14.1L11.9 11.5C12.3 10.4 11.5 9 10 9C8.6 9 7.7 10.4 8.1 11.5L3.5 16C2.4 15.7 1 16.5 1 18C1 19.1 1.9 20 3 20C4.4 20 5.3 18.6 4.9 17.5L9.4 12.9C9.7 13 10.1 13 10.4 12.9L13 15.5C12.7 16.5 13.5 18 15 18C16.5 18 17.3 16.6 16.9 15.5L20.5 11.9C21.6 12.2 23 11.4 23 10C23 8.9 22.1 8 21 8M15 9L15.9 6.9L18 6L15.9 5.1L15 3L14.1 5.1L12 6L14.1 6.9L15 9M3.5 11L4 9L6 8.5L4 8L3.5 6L3 8L1 8.5L3 9L3.5 11Z`,c=`M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z`,l=`M12,15.5A3.5,3.5 0 0,1 8.5,12A3.5,3.5 0 0,1 12,8.5A3.5,3.5 0 0,1 15.5,12A3.5,3.5 0 0,1 12,15.5M19.43,12.97C19.47,12.65 19.5,12.33 19.5,12C19.5,11.67 19.47,11.34 19.43,11L21.54,9.37C21.73,9.22 21.78,8.95 21.66,8.73L19.66,5.27C19.54,5.05 19.27,4.96 19.05,5.05L16.56,6.05C16.04,5.66 15.5,5.32 14.87,5.07L14.5,2.42C14.46,2.18 14.25,2 14,2H10C9.75,2 9.54,2.18 9.5,2.42L9.13,5.07C8.5,5.32 7.96,5.66 7.44,6.05L4.95,5.05C4.73,4.96 4.46,5.05 4.34,5.27L2.34,8.73C2.21,8.95 2.27,9.22 2.46,9.37L4.57,11C4.53,11.34 4.5,11.67 4.5,12C4.5,12.33 4.53,12.65 4.57,12.97L2.46,14.63C2.27,14.78 2.21,15.05 2.34,15.27L4.34,18.73C4.46,18.95 4.73,19.03 4.95,18.95L7.44,17.94C7.96,18.34 8.5,18.68 9.13,18.93L9.5,21.58C9.54,21.82 9.75,22 10,22H14C14.25,22 14.46,21.82 14.5,21.58L14.87,18.93C15.5,18.67 16.04,18.34 16.56,17.94L19.05,18.95C19.27,19.03 19.54,18.95 19.66,18.73L21.66,15.27C21.78,15.05 21.73,14.78 21.54,14.63L19.43,12.97Z`,u=`M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z`,d=`M14.12,10.47L12,12.59L9.87,10.47L8.46,11.88L10.59,14L8.47,16.12L9.88,17.53L12,15.41L14.12,17.53L15.53,16.12L13.41,14L15.53,11.88L14.12,10.47M15.5,4L14.5,3H9.5L8.5,4H5V6H19V4H15.5M6,19A2,2 0 0,0 8,21H16A2,2 0 0,0 18,19V7H6V19M8,9H16V19H8V9Z`,f=`M18,2H6A2,2 0 0,0 4,4V20A2,2 0 0,0 6,22H18A2,2 0 0,0 20,20V4A2,2 0 0,0 18,2M10,4A1,1 0 0,1 11,5A1,1 0 0,1 10,6A1,1 0 0,1 9,5A1,1 0 0,1 10,4M7,4A1,1 0 0,1 8,5A1,1 0 0,1 7,6A1,1 0 0,1 6,5A1,1 0 0,1 7,4M18,20H6V8H18V20M14.67,15.33C14.69,16.03 14.41,16.71 13.91,17.21C12.86,18.26 11.15,18.27 10.09,17.21C9.59,16.71 9.31,16.03 9.33,15.33C9.4,14.62 9.63,13.94 10,13.33C10.37,12.5 10.81,11.73 11.33,11L12,10C13.79,12.59 14.67,14.36 14.67,15.33`,p=`M19.77,7.23L19.78,7.22L16.06,3.5L15,4.56L17.11,6.67C16.17,7.03 15.5,7.93 15.5,9A2.5,2.5 0 0,0 18,11.5C18.36,11.5 18.69,11.42 19,11.29V18.5A1,1 0 0,1 18,19.5A1,1 0 0,1 17,18.5V14A2,2 0 0,0 15,12H14V5A2,2 0 0,0 12,3H6A2,2 0 0,0 4,5V21H14V13.5H15.5V18.5A2.5,2.5 0 0,0 18,21A2.5,2.5 0 0,0 20.5,18.5V9C20.5,8.31 20.22,7.68 19.77,7.23M18,10A1,1 0 0,1 17,9A1,1 0 0,1 18,8A1,1 0 0,1 19,9A1,1 0 0,1 18,10M8,18V13.5H6L10,6V11H12L8,18Z`,m=`M13 5C15.21 5 17 6.79 17 9C17 10.5 16.2 11.77 15 12.46V11.24C15.61 10.69 16 9.89 16 9C16 7.34 14.66 6 13 6S10 7.34 10 9C10 9.89 10.39 10.69 11 11.24V12.46C9.8 11.77 9 10.5 9 9C9 6.79 10.79 5 13 5M20 20.5C19.97 21.32 19.32 21.97 18.5 22H13C12.62 22 12.26 21.85 12 21.57L8 17.37L8.74 16.6C8.93 16.39 9.2 16.28 9.5 16.28H9.7L12 18V9C12 8.45 12.45 8 13 8S14 8.45 14 9V13.47L15.21 13.6L19.15 15.79C19.68 16.03 20 16.56 20 17.14V20.5M20 2H4C2.9 2 2 2.9 2 4V12C2 13.11 2.9 14 4 14H8V12L4 12L4 4H20L20 12H18V14H20V13.96L20.04 14C21.13 14 22 13.09 22 12V4C22 2.9 21.11 2 20 2Z`,h=`M19 3H5C3.9 3 3 3.9 3 5V19C3 20.1 3.9 21 5 21H19C20.1 21 21 20.1 21 19V5C21 3.9 20.1 3 19 3M12.75 7.08C13.57 7.2 14.32 7.5 14.95 8L12.75 10.19V7.08M11.25 7.08V10.19L9.05 8C9.68 7.5 10.43 7.2 11.25 7.08M8 9.05L10.19 11.25H7.08C7.2 10.43 7.5 9.68 8 9.05M7.08 12.75H10.19L8 14.95C7.5 14.32 7.2 13.57 7.08 12.75M11.25 16.92C10.43 16.8 9.68 16.5 9.05 16L11.25 13.81V16.92M12 13C11.45 13 11 12.55 11 12S11.45 11 12 11 13 11.45 13 12 12.55 13 12 13M12.75 16.92V13.81L14.95 16C14.32 16.5 13.57 16.8 12.75 16.92M16 14.95L13.81 12.75H16.92C16.8 13.57 16.5 14.32 16 14.95M13.81 11.25L16 9.05C16.5 9.69 16.8 10.44 16.92 11.25H13.81Z`,g=`M12 20L5 20V12H2L12 3L14.78 5.5H14V7.17C12.84 7.58 12 8.7 12 10V20M15 9H16V7.5H20V9H21C21.55 9 22 9.45 22 10V21C22 21.55 21.55 22 21 22H15C14.45 22 14 21.55 14 21V10C14 9.45 14.45 9 15 9M16 11V14H20V11H16Z`,_=`M10,2C8.89,2 8,2.89 8,4V7C8,8.11 8.89,9 10,9H11V11H2V13H6V15H5C3.89,15 3,15.89 3,17V20C3,21.11 3.89,22 5,22H9C10.11,22 11,21.11 11,20V17C11,15.89 10.11,15 9,15H8V13H16V15H15C13.89,15 13,15.89 13,17V20C13,21.11 13.89,22 15,22H19C20.11,22 21,21.11 21,20V17C21,15.89 20.11,15 19,15H18V13H22V11H13V9H14C15.11,9 16,8.11 16,7V4C16,2.89 15.11,2 14,2H10M10,4H14V7H10V4M5,17H9V20H5V17M15,17H19V20H15V17Z`,v=`M8 6V18H16V6H8M14 10H10V8H14V10M19.4 1.6C19 1.2 18.5 1 18 1H6C5.5 1 5 1.2 4.6 1.6C4.2 2 4 2.5 4 3V21C4 21.5 4.2 22 4.6 22.4C5 22.8 5.5 23 6 23H18C18.5 23 19 22.8 19.4 22.4C19.8 22 20 21.5 20 21V3C20 2.5 19.8 2 19.4 1.6M18 21H6V3H18V21Z`,y=`M21 11C21 6.03 16.97 2 12 2S3 6.03 3 11C3 14.92 5.5 18.24 9 19.5V22H11V19.94C11.33 20 11.66 20 12 20S12.67 20 13 19.94V22H15V19.5C18.5 18.24 21 14.92 21 11M12 18C8.14 18 5 14.86 5 11S8.14 4 12 4 19 7.14 19 11 15.86 18 12 18M8 7H16V9H8V7M12.75 10L9.75 13L11 14.25L9.75 15.5L11.25 17L14.25 14L13 12.75L14.25 11.5L12.75 10Z`,b=`M7.5,10.5A1.5,1.5 0 0,1 9,12A1.5,1.5 0 0,1 7.5,13.5C6.66,13.5 6,12.83 6,12A1.5,1.5 0 0,1 7.5,10.5M16.5,10.5A1.5,1.5 0 0,1 18,12A1.5,1.5 0 0,1 16.5,13.5A1.5,1.5 0 0,1 15,12A1.5,1.5 0 0,1 16.5,10.5M4.22,2H19.78C21,2 22,3 22,4.22V19.78A2.22,2.22 0 0,1 19.78,22H4.22C3,22 2,21 2,19.78V4.22A2.22,2.22 0 0,1 4.22,2M12,4A8,8 0 0,0 4,12A8,8 0 0,0 12,20A8,8 0 0,0 20,12A8,8 0 0,0 12,4Z`,x=`M12,4C14.1,4 16.1,4.8 17.6,6.3C20.7,9.4 20.7,14.5 17.6,17.6C15.8,19.5 13.3,20.2 10.9,19.9L11.4,17.9C13.1,18.1 14.9,17.5 16.2,16.2C18.5,13.9 18.5,10.1 16.2,7.7C15.1,6.6 13.5,6 12,6V10.6L7,5.6L12,0.6V4M6.3,17.6C3.7,15 3.3,11 5.1,7.9L6.6,9.4C5.5,11.6 5.9,14.4 7.8,16.2C8.3,16.7 8.9,17.1 9.6,17.4L9,19.4C8,19 7.1,18.4 6.3,17.6Z`,S=`M12,2C14.65,2 17.19,3.06 19.07,4.93L17.65,6.35C16.15,4.85 14.12,4 12,4C9.88,4 7.84,4.84 6.35,6.35L4.93,4.93C6.81,3.06 9.35,2 12,2M3.66,6.5L5.11,7.94C4.39,9.17 4,10.57 4,12A8,8 0 0,0 12,20A8,8 0 0,0 20,12C20,10.57 19.61,9.17 18.88,7.94L20.34,6.5C21.42,8.12 22,10.04 22,12A10,10 0 0,1 12,22A10,10 0 0,1 2,12C2,10.04 2.58,8.12 3.66,6.5M12,6A6,6 0 0,1 18,12C18,13.59 17.37,15.12 16.24,16.24L14.83,14.83C14.08,15.58 13.06,16 12,16C10.94,16 9.92,15.58 9.17,14.83L7.76,16.24C6.63,15.12 6,13.59 6,12A6,6 0 0,1 12,6M12,8A1,1 0 0,0 11,9A1,1 0 0,0 12,10A1,1 0 0,0 13,9A1,1 0 0,0 12,8Z`,C=`M22.1 21.5L2.4 1.7L1.1 3L8.9 10.8C5.4 12.9 3.7 16.4 3 20C5.3 16.7 8.6 15.1 13 14.9L14 15.9V19L15.6 17.4L20.8 22.7M8.3 13.8C8.94 13.22 9.65 12.71 10.4 12.3L11.3 13.1M14.2 11L12.5 9.3L14 9V5L21 12L18.1 14.9L16.7 13.5L18.2 12L16 9.8V10.7`,w=`M14,5V9C7,10 4,15 3,20C5.5,16.5 9,14.9 14,14.9V19L21,12L14,5M16,9.83L18.17,12L16,14.17V12.9H14C11.93,12.9 10.07,13.28 8.34,13.85C9.74,12.46 11.54,11.37 14.28,11L16,10.73V9.83Z`,T=`M12 4C16.41 4 20 7.59 20 12S16.41 20 12 20 4 16.41 4 12 7.59 4 12 4M12 2C6.5 2 2 6.5 2 12S6.5 22 12 22 22 17.5 22 12 17.5 2 12 2M12 11C11.45 11 11 11.45 11 12S11.45 13 12 13 13 12.55 13 12 12.55 11 12 11M10.72 9.3C11.11 9.11 11.54 9 12 9S12.89 9.11 13.29 9.3L14 8.57C13.43 8.22 12.74 8 12 8S10.58 8.22 10 8.57L10.72 9.3M15 12C15 12.46 14.89 12.89 14.7 13.29L15.43 14C15.79 13.43 16 12.74 16 12S15.79 10.58 15.43 10L14.7 10.72C14.89 11.11 15 11.54 15 12M9 12C9 11.54 9.11 11.11 9.3 10.72L8.57 10C8.22 10.58 8 11.26 8 12S8.22 13.43 8.57 14L9.3 13.29C9.11 12.89 9 12.46 9 12M13.29 14.7C12.89 14.89 12.46 15 12 15S11.11 14.89 10.72 14.7L10 15.43C10.58 15.79 11.26 16 12 16S13.43 15.79 14 15.43L13.29 14.7M16.89 8.53L16.17 9.25C16.69 10.04 17 11 17 12S16.69 13.96 16.17 14.75L16.89 15.47C17.59 14.5 18 13.3 18 12S17.59 9.5 16.89 8.53M9.25 7.83C10.04 7.31 11 7 12 7S13.96 7.31 14.75 7.83L15.47 7.11C14.5 6.42 13.3 6 12 6S9.5 6.42 8.53 7.11L9.25 7.83M14.75 16.17C13.96 16.69 13 17 12 17S10.04 16.69 9.25 16.17L8.53 16.89C9.5 17.59 10.7 18 12 18S14.5 17.59 15.47 16.89L14.75 16.17M7.83 14.75C7.31 13.96 7 13 7 12S7.31 10.04 7.83 9.25L7.11 8.53C6.42 9.5 6 10.7 6 12S6.42 14.5 7.11 15.47L7.83 14.75Z`,E=`M4,2H20A2,2 0 0,1 22,4V14A2,2 0 0,1 20,16H15V20H18V22H13V16H11V22H6V20H9V16H4A2,2 0 0,1 2,14V4A2,2 0 0,1 4,2M4,4V8H11V4H4M4,14H11V10H4V14M20,14V10H13V14H20M20,4H13V8H20V4Z`,D=`M19 17H22L18 21L14 17H17V3H19M2 17H12V19H2M6 5V7H2V5M2 11H9V13H2V11Z`,O=`M19 7H22L18 3L14 7H17V21H19M2 17H12V19H2M6 5V7H2V5M2 11H9V13H2V11Z`,k=`M10 10H14V22H10V10M7 9H9V7H7V9M4 8H6V6H4V8M4 11H6V9H4V11M1 13H3V11H1V13M1 7H3V5H1V7M1 10H3V8H1V10M18 11H20V9H18V11M21 10H23V8H21V10M21 5V7H23V5H21M21 13H23V11H21V13M15 9H17V7H15V9M18 8H20V6H18V8M10 7H10.33L11 9H13L13.67 7H14V6H10V7Z`,A=`M6,14H8L11,17H9L6,14M4,4H5V3A1,1 0 0,1 6,2H10A1,1 0 0,1 11,3V4H13V3A1,1 0 0,1 14,2H18A1,1 0 0,1 19,3V4H20A2,2 0 0,1 22,6V19A2,2 0 0,1 20,21V22H17V21H7V22H4V21A2,2 0 0,1 2,19V6A2,2 0 0,1 4,4M18,7A1,1 0 0,1 19,8A1,1 0 0,1 18,9A1,1 0 0,1 17,8A1,1 0 0,1 18,7M14,7A1,1 0 0,1 15,8A1,1 0 0,1 14,9A1,1 0 0,1 13,8A1,1 0 0,1 14,7M20,6H4V10H20V6M4,19H20V12H4V19M6,7A1,1 0 0,1 7,8A1,1 0 0,1 6,9A1,1 0 0,1 5,8A1,1 0 0,1 6,7M13,14H15L18,17H16L13,14Z`,j=`M21,17H3V5H21M21,3H3A2,2 0 0,0 1,5V17A2,2 0 0,0 3,19H8V21H16V19H21A2,2 0 0,0 23,17V5A2,2 0 0,0 21,3Z`,M=`M16.95,16.95L14.83,14.83C15.55,14.1 16,13.1 16,12C16,11.26 15.79,10.57 15.43,10L17.6,7.81C18.5,9 19,10.43 19,12C19,13.93 18.22,15.68 16.95,16.95M12,5C13.57,5 15,5.5 16.19,6.4L14,8.56C13.43,8.21 12.74,8 12,8A4,4 0 0,0 8,12C8,13.1 8.45,14.1 9.17,14.83L7.05,16.95C5.78,15.68 5,13.93 5,12A7,7 0 0,1 12,5M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12C22,6.47 17.5,2 12,2Z`,N=`M5,3A2,2 0 0,0 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V5C21,3.89 20.1,3 19,3H5M12,5C13.57,5 15,5.5 16.19,6.4L14,8.56C13.43,8.21 12.74,8 12,8A4,4 0 0,0 8,12C8,13.1 8.45,14.1 9.17,14.83L7.05,16.95C5.78,15.68 5,13.93 5,12A7,7 0 0,1 12,5M17.6,7.81C18.5,9 19,10.43 19,12C19,13.93 18.22,15.68 16.95,16.95L14.83,14.83C15.55,14.1 16,13.1 16,12C16,11.26 15.79,10.57 15.43,10L17.6,7.81Z`,P=`M8.28,5.45L6.5,4.55L7.76,2H16.23L17.5,4.55L15.72,5.44L15,4H9L8.28,5.45M18.62,8H14.09L13.3,5H10.7L9.91,8H5.38L4.1,10.55L5.89,11.44L6.62,10H17.38L18.1,11.45L19.89,10.56L18.62,8M17.77,22H15.7L15.46,21.1L12,15.9L8.53,21.1L8.3,22H6.23L9.12,11H11.19L10.83,12.35L12,14.1L13.16,12.35L12.81,11H14.88L17.77,22M11.4,15L10.5,13.65L9.32,18.13L11.4,15M14.68,18.12L13.5,13.64L12.6,15L14.68,18.12Z`,F=`M6,2H18A2,2 0 0,1 20,4V20A2,2 0 0,1 18,22H6A2,2 0 0,1 4,20V4A2,2 0 0,1 6,2M7,4A1,1 0 0,0 6,5A1,1 0 0,0 7,6A1,1 0 0,0 8,5A1,1 0 0,0 7,4M10,4A1,1 0 0,0 9,5A1,1 0 0,0 10,6A1,1 0 0,0 11,5A1,1 0 0,0 10,4M12,8A6,6 0 0,0 6,14A6,6 0 0,0 12,20A6,6 0 0,0 18,14A6,6 0 0,0 12,8M8.11,10.5H10C9.76,11.88 10,12.67 10.58,13.29C11.68,14.36 12.16,15.71 11.89,17.5H10C10.24,16.12 10,15.33 9.42,14.71C8.32,13.64 7.85,12.29 8.11,10.5M12.11,10.5H14C13.76,11.88 14,12.67 14.58,13.29C15.68,14.36 16.16,15.71 15.89,17.5H14C14.24,16.12 14,15.33 13.42,14.71C12.32,13.64 11.85,12.29 12.11,10.5Z`,I=`M4 22H2V2H4M22 2H20V22H22M17.24 5.34L13.24 9.34A3 3 0 0 0 9.24 13.34L5.24 17.34L6.66 18.76L10.66 14.76A3 3 0 0 0 14.66 10.76L18.66 6.76Z`,L=`M14,3.23V5.29C16.89,6.15 19,8.83 19,12C19,15.17 16.89,17.84 14,18.7V20.77C18,19.86 21,16.28 21,12C21,7.72 18,4.14 14,3.23M16.5,12C16.5,10.23 15.5,8.71 14,7.97V16C15.5,15.29 16.5,13.76 16.5,12M3,9V15H7L12,20V4L7,9H3Z`,R=`M14.83,11.17C16.39,12.73 16.39,15.27 14.83,16.83C13.27,18.39 10.73,18.39 9.17,16.83L14.83,11.17M6,2H18A2,2 0 0,1 20,4V20A2,2 0 0,1 18,22H6A2,2 0 0,1 4,20V4A2,2 0 0,1 6,2M7,4A1,1 0 0,0 6,5A1,1 0 0,0 7,6A1,1 0 0,0 8,5A1,1 0 0,0 7,4M10,4A1,1 0 0,0 9,5A1,1 0 0,0 10,6A1,1 0 0,0 11,5A1,1 0 0,0 10,4M12,8A6,6 0 0,0 6,14A6,6 0 0,0 12,20A6,6 0 0,0 18,14A6,6 0 0,0 12,8Z`,z=`M8 2C6.89 2 6 2.89 6 4V16C6 17.11 6.89 18 8 18H9V20H6V22H9C10.11 22 11 21.11 11 20V18H13V20C13 21.11 13.89 22 15 22H18V20H15V18H16C17.11 18 18 17.11 18 16V4C18 2.89 17.11 2 16 2H8M12 4.97A2 2 0 0 1 14 6.97A2 2 0 0 1 12 8.97A2 2 0 0 1 10 6.97A2 2 0 0 1 12 4.97M10 14.5H14V16H10V14.5Z`,B=`M12,3.25C12,3.25 6,10 6,14C6,17.32 8.69,20 12,20A6,6 0 0,0 18,14C18,10 12,3.25 12,3.25M14.47,9.97L15.53,11.03L9.53,17.03L8.47,15.97M9.75,10A1.25,1.25 0 0,1 11,11.25A1.25,1.25 0 0,1 9.75,12.5A1.25,1.25 0 0,1 8.5,11.25A1.25,1.25 0 0,1 9.75,10M14.25,14.5A1.25,1.25 0 0,1 15.5,15.75A1.25,1.25 0 0,1 14.25,17A1.25,1.25 0 0,1 13,15.75A1.25,1.25 0 0,1 14.25,14.5Z`,V=e(((e,n)=>{n.exports=function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){typeof Symbol<`u`&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:`Module`}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t||4&t&&typeof e==`object`&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&typeof e!=`string`)for(var i in e)n.d(r,i,function(t){return e[t]}.bind(null,i));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,`a`,t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p=``,n(n.s=2)}([function(e,t){e.exports=i()},function(e,n){e.exports=t()},function(e,t,n){n.r(t);var r=n(1),i=n(0),a=function(){return(a=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},o=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols==`function`){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n},s=0,c=r.forwardRef((function(e,t){var n=e.title,i=n===void 0?null:n,c=e.description,l=c===void 0?null:c,u=e.size,d=u===void 0?null:u,f=e.color,p=f===void 0?`currentColor`:f,m=e.horizontal,h=m===void 0?null:m,g=e.vertical,_=g===void 0?null:g,v=e.rotate,y=v===void 0?null:v,b=e.spin,x=b===void 0?null:b,S=e.style,C=S===void 0?{}:S,w=e.children,T=o(e,[`title`,`description`,`size`,`color`,`horizontal`,`vertical`,`rotate`,`spin`,`style`,`children`]);s++;var E,D=x!==null&&x,O=r.Children.map(w,(function(e){var t=e;!0!==D&&(D=!0===(x===null?t.props.spin:x));var n=t.props.size;typeof d==`number`&&typeof t.props.size==`number`&&(n=t.props.size/d);var i={size:n,color:p===null?t.props.color:p,horizontal:h===null?t.props.horizontal:h,vertical:_===null?t.props.vertical:_,rotate:y===null?t.props.rotate:y,spin:x===null?t.props.spin:x,inStack:!0};return r.cloneElement(t,i)}));d!==null&&(C.width=typeof d==`string`?d:1.5*d+`rem`);var k,A=`stack_labelledby_`+s,j=`stack_describedby_`+s;if(i)E=l?A+` `+j:A;else if(k=`presentation`,l)throw Error(`title attribute required when description is set`);return r.createElement(`svg`,a({ref:t,viewBox:`0 0 24 24`,style:C,role:k,"aria-labelledby":E},T),i&&r.createElement(`title`,{id:A},i),l&&r.createElement(`desc`,{id:j},l),D&&r.createElement(`style`,null,`@keyframes spin { from { transform: rotate(0deg) } to { transform: rotate(360deg) } }`,`@keyframes spin-inverse { from { transform: rotate(0deg) } to { transform: rotate(-360deg) } }`),O)}));c.displayName=`Stack`,c.propTypes={size:i.oneOfType([i.number,i.string]),color:i.string,horizontal:i.bool,vertical:i.bool,rotate:i.number,spin:i.oneOfType([i.bool,i.number]),children:i.oneOfType([i.arrayOf(i.node),i.node]).isRequired,className:i.string,style:i.object},c.defaultProps={size:null,color:null,horizontal:null,vertical:null,rotate:null,spin:null};var l=c;n.d(t,`Icon`,(function(){return p})),n.d(t,`Stack`,(function(){return l}));var u=function(){return(u=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},d=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols==`function`){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n},f=0,p=r.forwardRef((function(e,t){var n=e.path,i=e.id,a=i===void 0?++f:i,o=e.title,s=o===void 0?null:o,c=e.description,l=c===void 0?null:c,p=e.size,m=p===void 0?null:p,h=e.color,g=h===void 0?`currentColor`:h,_=e.horizontal,v=_!==void 0&&_,y=e.vertical,b=y!==void 0&&y,x=e.rotate,S=x===void 0?0:x,C=e.spin,w=C!==void 0&&C,T=e.style,E=T===void 0?{}:T,D=e.inStack,O=D!==void 0&&D,k=d(e,[`path`,`id`,`title`,`description`,`size`,`color`,`horizontal`,`vertical`,`rotate`,`spin`,`style`,`inStack`]),A={},j=[];m!==null&&(O?j.push(`scale(`+m+`)`):(E.width=typeof m==`string`?m:1.5*m+`rem`,E.height=E.width)),v&&j.push(`scaleX(-1)`),b&&j.push(`scaleY(-1)`),S!==0&&j.push(`rotate(`+S+`deg)`),g!==null&&(A.fill=g);var M=r.createElement(`path`,u({d:n,style:A},O?k:{})),N=M;j.length>0&&(E.transform=j.join(` `),E.transformOrigin=`center`,O&&(N=r.createElement(`g`,{style:E},M,r.createElement(`rect`,{width:`24`,height:`24`,fill:`transparent`}))));var P,F=N,I=!0===w||typeof w!=`number`?2:w,L=!O&&(v||b);if(I<0&&(L=!L),w&&(F=r.createElement(`g`,{style:{animation:`spin`+(L?`-inverse`:``)+` linear `+Math.abs(I)+`s infinite`,transformOrigin:`center`}},N,!(v||b||S!==0)&&r.createElement(`rect`,{width:`24`,height:`24`,fill:`transparent`}))),O)return F;var R,z=`icon_labelledby_`+a,B=`icon_describedby_`+a;if(s)P=l?z+` `+B:z;else if(R=`presentation`,l)throw Error(`title attribute required when description is set`);return r.createElement(`svg`,u({ref:t,viewBox:`0 0 24 24`,style:E,role:R,"aria-labelledby":P},k),s&&r.createElement(`title`,{id:z},s),l&&r.createElement(`desc`,{id:B},l),!O&&w&&(L?r.createElement(`style`,null,`@keyframes spin-inverse { from { transform: rotate(0deg) } to { transform: rotate(-360deg) } }`):r.createElement(`style`,null,`@keyframes spin { from { transform: rotate(0deg) } to { transform: rotate(360deg) } }`)),F)}));p.displayName=`Icon`,p.propTypes={path:i.string.isRequired,size:i.oneOfType([i.number,i.string]),color:i.string,horizontal:i.bool,vertical:i.bool,rotate:i.number,spin:i.oneOfType([i.bool,i.number]),style:i.object,inStack:i.bool,className:i.string},p.defaultProps={size:null,color:`currentColor`,horizontal:!1,vertical:!1,rotate:0,spin:!1},t.default=p}])}));export{N as A,E as C,A as D,k as E,R as F,z as I,B as L,F as M,I as N,j as O,L as P,T as S,O as T,b as _,c as a,C as b,d as c,m as d,h as f,y as g,v as h,s as i,P as j,M as k,f as l,_ as m,a as n,l as o,g as p,o as r,u as s,V as t,p as u,x as v,D as w,w as x,S as y};
|