function t(r){return r.toLowerCase().trim().replace(/\//g,"-").replace(/[^a-z0-9\s_-]+/g,"").replace(/[\s_-]+/g,"-").replace(/^-+|-+$/g,"")}function p(r){if(r.app_name)return r.app_name;if(r.connection_url)try{const e=new URL(r.connection_url),a=((e.port?`${e.hostname}-${e.port}`:e.hostname)+e.pathname).replace(/\/+$/,"");return t(a)}catch{return t(r.connection_url)}return r.title?t(r.title):r.id??"unknown"}export{p as g,t as s};
