import{r as s,u as l,j as a,L as d,aT as p}from"./index-ClCsMWbS.js";const i=e=>{const o="[/| |:]",n=new RegExp(o,"g");return e.replace(n,"_")},f=s.memo(({device:e})=>{const{t:o}=l("zigbee");let n=e.model_id||o(r=>r.unknown),t=p;if(e.supported&&e.definition){const r=[encodeURIComponent(e.definition.vendor.toLowerCase()),encodeURIComponent(e.definition.model.toLowerCase())].join("-");t=`https://www.zigbee2mqtt.io/devices/${encodeURIComponent(i(e.definition.model))}.html#${encodeURIComponent(i(r))}`,n=e.definition.model}return a.jsx(d,{target:"_blank",rel:"noopener noreferrer",to:t,className:"link link-hover",children:n})}),u=s.memo(({device:e})=>{const{t:o}=l("zigbee");let n=o(r=>r.unsupported),t=p;return e.supported&&e.definition&&(t=`https://www.zigbee2mqtt.io/supported-devices/#v=${encodeURIComponent(e.definition.vendor)}`,n=e.definition.vendor),a.jsx(d,{target:"_blank",rel:"noopener noreferrer",to:t,className:"link link-hover",children:n})});export{f as M,u as V};
