Sync build v0.9.160

Automated sync from private repository.
Commit: d9ecadc33af44bc844ce95742e219b483deff399
This commit is contained in:
GitHub Actions Bot
2026-01-21 03:05:02 +00:00
parent 1bb436bf02
commit e94ea4518d
24 changed files with 26 additions and 26 deletions
+1 -1
View File
@@ -1 +1 @@
0.9.159
0.9.160
-1
View File
@@ -1 +0,0 @@
import{c as t,bn as e,r as a}from"./vendor-react-0D__tamq.js";const r="pymc-basemap-mode",o="light";function s(){if("undefined"==typeof window)return o;try{const t=localStorage.getItem(r);if("light"===t||"dark"===t)return t}catch{}return o}function n(t){if("undefined"!=typeof window)try{localStorage.setItem(r,t)}catch{}}const i=t(t=>({mode:s(),toggle:()=>t(t=>{const e="light"===t.mode?"dark":"light";return n(e),{mode:e}}),setMode:e=>{n(e),t({mode:e})}})),c=()=>i(t=>t.mode),l=()=>i(t=>t.toggle),d={light:"https://basemaps.cartocdn.com/gl/positron-gl-style/style.json",dark:"https://basemaps.cartocdn.com/gl/dark-matter-gl-style/style.json"},u={light:"basemap-light-",dark:"basemap-dark-"},f={};function y({mode:t}){const{current:r}=e(),o=a.useRef({light:!1,dark:!1}),s=a.useRef({light:[],dark:[]}),n=a.useCallback(async(t,e,a)=>{var r,n;if(o.current[e])return;const i=u[e],c=await async function(t){if(f[t])return f[t];const e=await fetch(d[t]),a=await e.json();return f[t]=a,a}(e),l=[];for(const[o,s]of Object.entries(c.sources||{})){const e=i+o;t.getSource(e)||t.addSource(e,s)}const y=null==(n=((null==(r=t.getStyle())?void 0:r.layers)||[]).find(t=>!t.id.startsWith("basemap-light-")&&!t.id.startsWith("basemap-dark-")))?void 0:n.id;for(const o of c.layers||[]){const e=i+o.id;if(l.push(e),t.getLayer(e))continue;const r={...o,id:e};"source"in r&&"string"==typeof r.source&&(r.source=i+r.source),r.layout||(r.layout={}),r.layout.visibility=a?"visible":"none";try{t.addLayer(r,y)}catch(g){}}s.current[e]=l,o.current[e]=!0},[]),i=a.useCallback((t,e,a)=>{const r=s.current[e],o=a?"visible":"none";for(const s of r)if(t.getLayer(s))try{t.setLayoutProperty(s,"visibility",o)}catch{}},[]),c=a.useCallback(t=>{var e;const a=((null==(e=t.getStyle())?void 0:e.layers)||[]).filter(t=>!t.id.startsWith("basemap-light-")&&!t.id.startsWith("basemap-dark-"));for(const r of a)try{t.moveLayer(r.id)}catch{}},[]);return a.useEffect(()=>{var e;const a=null==(e=null==r?void 0:r.getMap)?void 0:e.call(r);if(!a)return;let s=!1;const i=async()=>{if(!s)try{await Promise.all([n(a,"light","light"===t),n(a,"dark","dark"===t)]),s||c(a)}catch(e){}};a.isStyleLoaded()?i():a.once("style.load",i);const l=()=>{s||setTimeout(()=>{!s&&o.current.light&&o.current.dark&&c(a)},100)};return a.on("styledata",l),()=>{s=!0,a.off("styledata",l)}},[r,n,c,t]),a.useEffect(()=>{var e;const a=null==(e=null==r?void 0:r.getMap)?void 0:e.call(r);a&&o.current.light&&o.current.dark&&(i(a,"light","light"===t),i(a,"dark","dark"===t))},[r,t,i]),null}export{y as B,l as a,c as u};
+1
View File
@@ -0,0 +1 @@
import{c as t,bn as e,r}from"./vendor-react-0D__tamq.js";const a="pymc-basemap-mode",o="light";function s(){if("undefined"==typeof window)return o;try{const t=localStorage.getItem(a);if("light"===t||"dark"===t)return t}catch{}return o}function n(t){if("undefined"!=typeof window)try{localStorage.setItem(a,t)}catch{}}const c=t(t=>({mode:s(),toggle:()=>t(t=>{const e="light"===t.mode?"dark":"light";return n(e),{mode:e}}),setMode:e=>{n(e),t({mode:e})}})),l=()=>c(t=>t.mode),i=()=>c(t=>t.toggle),u={light:"https://basemaps.cartocdn.com/gl/positron-gl-style/style.json",dark:"https://basemaps.cartocdn.com/gl/dark-matter-gl-style/style.json"},d={light:"basemap-light-",dark:"basemap-dark-"},f={};function y({mode:t}){const{current:a}=e(),[o,s]=r.useState(null),n=r.useRef({light:!1,dark:!1}),c=r.useRef({light:[],dark:[]});r.useEffect(()=>{const t=()=>{var t;const e=null==(t=null==a?void 0:a.getMap)?void 0:t.call(a);e&&!o&&s(e)};t();const e=setInterval(t,50),r=setTimeout(()=>clearInterval(e),5e3);return()=>{clearInterval(e),clearTimeout(r)}},[a,o]);const l=r.useCallback(async(t,e,r)=>{var a,o;if(n.current[e])return;const s=d[e],l=await async function(t){if(f[t])return f[t];const e=await fetch(u[t]),r=await e.json();return f[t]=r,r}(e),i=[];for(const[n,c]of Object.entries(l.sources||{})){const e=s+n;t.getSource(e)||t.addSource(e,c)}const y=null==(o=((null==(a=t.getStyle())?void 0:a.layers)||[]).find(t=>!t.id.startsWith("basemap-light-")&&!t.id.startsWith("basemap-dark-")))?void 0:o.id;for(const n of l.layers||[]){const e=s+n.id;if(i.push(e),t.getLayer(e))continue;const a={...n,id:e};"source"in a&&"string"==typeof a.source&&(a.source=s+a.source),a.layout||(a.layout={}),a.layout.visibility=r?"visible":"none";try{t.addLayer(a,y)}catch(g){}}c.current[e]=i,n.current[e]=!0},[]),i=r.useCallback((t,e,r)=>{const a=c.current[e],o=r?"visible":"none";for(const s of a)if(t.getLayer(s))try{t.setLayoutProperty(s,"visibility",o)}catch{}},[]),y=r.useCallback(t=>{var e;const r=((null==(e=t.getStyle())?void 0:e.layers)||[]).filter(t=>!t.id.startsWith("basemap-light-")&&!t.id.startsWith("basemap-dark-"));for(const a of r)try{t.moveLayer(a.id)}catch{}},[]);return r.useEffect(()=>{if(!o)return;let e=!1;const r=async()=>{if(!e)try{await Promise.all([l(o,"light","light"===t),l(o,"dark","dark"===t)]),e||y(o)}catch(r){}};o.isStyleLoaded()?r():(o.once("style.load",r),o.once("load",()=>{e||n.current.light||r()}));const a=()=>{e||setTimeout(()=>{!e&&n.current.light&&n.current.dark&&y(o)},100)};return o.on("styledata",a),()=>{e=!0,o.off("styledata",a)}},[o,l,y,t]),r.useEffect(()=>{o&&n.current.light&&n.current.dark&&(i(o,"light","light"===t),i(o,"dark","dark"===t))},[o,t,i]),null}export{y as B,i as a,l as u};
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -1 +1 @@
import{j as e,a2 as s,F as a,r as t,aP as l,a5 as c,aZ as n}from"./vendor-react-0D__tamq.js";import{c as i}from"./recharts-BovJNxPc.js";import{ab as o,ac as r,b as x,ad as d,r as m,L as u,aa as h,ae as p,af as j}from"./index-BORukrl8.js";import{u as g}from"./usePolling-CoS_cZMr.js";import{P as f,b as N,a as v,c as y,L as b}from"./PageLayout-lVaYU4M5.js";import"./vendor-core-WoOfkQwm.js";import"./deckgl-DTsmDcfs.js";const w=t.memo(function({log:s}){return e.jsx("div",{className:"p-3 rounded-2xl bg-white/[0.02] hover:bg-white/[0.04] transition-colors",children:e.jsxs("div",{className:"flex items-baseline gap-3",children:[e.jsx("span",{className:i("type-data-sm w-14 shrink-0",j(s.level)),children:s.level}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("p",{className:"type-data-sm text-text-primary break-words whitespace-pre-wrap",children:s.message}),e.jsx("p",{className:"type-data-xs text-text-muted mt-1",children:new Date(s.timestamp).toLocaleString()})]})]})})});function F(){const s=o(),[a,r]=t.useState("INFO"),[x,d]=t.useState(!1),[m,u]=t.useState(null);t.useEffect(()=>{if(s.length>0){const e=s.some(e=>"DEBUG"===e.level);r(e?"DEBUG":"INFO")}},[s]);const h=t.useCallback(async e=>{if(e!==a&&!x){d(!0),u(null);try{const s=await p(e);s.success&&s.data?(r(e),u(s.data.message),setTimeout(()=>u(null),5e3)):(u(s.error??"Failed to change log level"),setTimeout(()=>u(null),3e3))}catch{u("Failed to change log level"),setTimeout(()=>u(null),3e3)}finally{d(!1)}}},[a,x]),j="h-[32px] px-4 rounded-full type-data flex items-center gap-2 transition-colors",g=x&&"opacity-50 cursor-not-allowed";return e.jsxs("div",{className:"flex items-center gap-2",children:[m&&e.jsx("span",{className:"text-xs text-text-muted animate-pulse",children:m}),e.jsxs("div",{className:"flex bg-white/[0.02] rounded-full p-1",children:[e.jsxs("button",{onClick:()=>h("INFO"),disabled:x,className:i(j,"INFO"===a?"bg-accent-primary/20 text-accent-primary":"text-text-muted hover:text-text-secondary",g),children:[e.jsx(l,{className:"w-4 h-4"}),"Info"]}),e.jsxs("button",{onClick:()=>h("DEBUG"),disabled:x,className:i(j,"DEBUG"===a?"bg-accent-secondary/20 text-accent-secondary":"text-text-muted hover:text-text-secondary",g),children:[x?e.jsx(c,{className:"w-4 h-4 animate-spin"}):e.jsx(n,{className:"w-4 h-4"}),"Debug"]})]})]})}function L(){const t=o(),l=r(),c=x(),n=d(),p=m();return g(n,h.logs,c),e.jsxs(f,{children:[e.jsx(N,{title:"System Logs",icon:e.jsx(a,{}),controls:e.jsxs(e.Fragment,{children:[e.jsx(F,{}),c&&e.jsx(u,{showLabel:!0}),e.jsxs("button",{onClick:()=>p(!c),className:i("h-[32px] px-4 rounded-full type-data transition-colors","flex items-center gap-2",c?"bg-accent-success/20 text-accent-success":"bg-white/[0.02] text-text-muted hover:text-text-secondary"),children:[e.jsx(s,{className:i("w-4 h-4",c&&"animate-spin")}),e.jsx("span",{className:"hidden xs:inline",children:c?"Live":"Paused"})]})]})}),e.jsxs(v,{noPadding:!0,children:[e.jsx(y,{listHeader:!0,icon:e.jsx(a,{className:"icon-sm"}),title:"Log Entries"}),e.jsx("div",{className:"space-y-2 max-h-[calc(100vh-300px)] sm:max-h-[calc(100vh-250px)] overflow-y-auto p-4",children:l&&0===t.length?e.jsx(b,{count:10}):0===t.length?e.jsx("div",{className:"text-center py-12 text-text-muted",children:"No logs available"}):t.map((s,a)=>e.jsx(w,{log:s},`${s.timestamp}-${a}`))})]})]})}export{L as default};
import{j as e,a2 as s,F as a,r as t,aP as l,a5 as c,aZ as n}from"./vendor-react-0D__tamq.js";import{c as i}from"./recharts-BovJNxPc.js";import{ab as o,ac as r,b as x,ad as d,r as m,L as u,aa as h,ae as p,af as j}from"./index-DPcwpo2i.js";import{u as g}from"./usePolling-CoS_cZMr.js";import{P as f,b as N,a as v,c as y,L as b}from"./PageLayout-lVaYU4M5.js";import"./vendor-core-WoOfkQwm.js";import"./deckgl-DTsmDcfs.js";const w=t.memo(function({log:s}){return e.jsx("div",{className:"p-3 rounded-2xl bg-white/[0.02] hover:bg-white/[0.04] transition-colors",children:e.jsxs("div",{className:"flex items-baseline gap-3",children:[e.jsx("span",{className:i("type-data-sm w-14 shrink-0",j(s.level)),children:s.level}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("p",{className:"type-data-sm text-text-primary break-words whitespace-pre-wrap",children:s.message}),e.jsx("p",{className:"type-data-xs text-text-muted mt-1",children:new Date(s.timestamp).toLocaleString()})]})]})})});function F(){const s=o(),[a,r]=t.useState("INFO"),[x,d]=t.useState(!1),[m,u]=t.useState(null);t.useEffect(()=>{if(s.length>0){const e=s.some(e=>"DEBUG"===e.level);r(e?"DEBUG":"INFO")}},[s]);const h=t.useCallback(async e=>{if(e!==a&&!x){d(!0),u(null);try{const s=await p(e);s.success&&s.data?(r(e),u(s.data.message),setTimeout(()=>u(null),5e3)):(u(s.error??"Failed to change log level"),setTimeout(()=>u(null),3e3))}catch{u("Failed to change log level"),setTimeout(()=>u(null),3e3)}finally{d(!1)}}},[a,x]),j="h-[32px] px-4 rounded-full type-data flex items-center gap-2 transition-colors",g=x&&"opacity-50 cursor-not-allowed";return e.jsxs("div",{className:"flex items-center gap-2",children:[m&&e.jsx("span",{className:"text-xs text-text-muted animate-pulse",children:m}),e.jsxs("div",{className:"flex bg-white/[0.02] rounded-full p-1",children:[e.jsxs("button",{onClick:()=>h("INFO"),disabled:x,className:i(j,"INFO"===a?"bg-accent-primary/20 text-accent-primary":"text-text-muted hover:text-text-secondary",g),children:[e.jsx(l,{className:"w-4 h-4"}),"Info"]}),e.jsxs("button",{onClick:()=>h("DEBUG"),disabled:x,className:i(j,"DEBUG"===a?"bg-accent-secondary/20 text-accent-secondary":"text-text-muted hover:text-text-secondary",g),children:[x?e.jsx(c,{className:"w-4 h-4 animate-spin"}):e.jsx(n,{className:"w-4 h-4"}),"Debug"]})]})]})}function L(){const t=o(),l=r(),c=x(),n=d(),p=m();return g(n,h.logs,c),e.jsxs(f,{children:[e.jsx(N,{title:"System Logs",icon:e.jsx(a,{}),controls:e.jsxs(e.Fragment,{children:[e.jsx(F,{}),c&&e.jsx(u,{showLabel:!0}),e.jsxs("button",{onClick:()=>p(!c),className:i("h-[32px] px-4 rounded-full type-data transition-colors","flex items-center gap-2",c?"bg-accent-success/20 text-accent-success":"bg-white/[0.02] text-text-muted hover:text-text-secondary"),children:[e.jsx(s,{className:i("w-4 h-4",c&&"animate-spin")}),e.jsx("span",{className:"hidden xs:inline",children:c?"Live":"Paused"})]})]})}),e.jsxs(v,{noPadding:!0,children:[e.jsx(y,{listHeader:!0,icon:e.jsx(a,{className:"icon-sm"}),title:"Log Entries"}),e.jsx("div",{className:"space-y-2 max-h-[calc(100vh-300px)] sm:max-h-[calc(100vh-250px)] overflow-y-auto p-4",children:l&&0===t.length?e.jsx(b,{count:10}):0===t.length?e.jsx("div",{className:"text-center py-12 text-text-muted",children:"No logs available"}):t.map((s,a)=>e.jsx(w,{log:s},`${s.timestamp}-${a}`))})]})]})}export{L as default};
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -1 +1 @@
import{d as t,as as e}from"./index-BORukrl8.js";function o(t){if(Array.isArray(t))return t;if("string"==typeof t&&t.startsWith("["))try{const e=JSON.parse(t);return Array.isArray(e)?e:[]}catch{return[]}return[]}function n(n,r,s){const a=new Map;for(const e of r){const o=t(e);a.has(o)||a.set(o,e)}const c=new Map,i=new Map;for(const t of n){const n=t.route??t.route_type;if(!e(n))continue;const r=o(t.original_path);if(0===r.length)continue;const f=r.map(t=>t.toUpperCase());if(!t.transmitted&&f.length>=2){const t=f[f.length-2];if(t){const e=a.get(t);e&&i.set(e,(i.get(e)??0)+1)}}if(f.includes(s))for(const t of f){if(t===s)continue;const e=a.get(t);e&&c.set(e,(c.get(e)??0)+1)}}let f=0,u=0;for(const t of r)f=Math.max(f,c.get(t)??0),u=Math.max(u,i.get(t)??0);const h=new Map;let d=0,g=0,l=0;for(const t of r){const e=c.get(t)??0,o=i.get(t)??0,n=f>0?Math.round(e/f*100):0,r=u>0?Math.round(o/u*100):0,s=n+r;h.set(t,{hash:t,listenerCount:e,loudCount:o,listenerScore:n,loudScore:r,blendedScore:s}),d=Math.max(d,n),g=Math.max(g,r),l=Math.max(l,s)}return{scores:h,maxListenerScore:d,maxLoudScore:g,maxBlendedScore:l}}const r={YELLOW:"#FBBF24",GREEN:"#719872",RED:"#E12672",GRAY:"#505050"};export{r as L,n as c};
import{d as t,as as e}from"./index-DPcwpo2i.js";function o(t){if(Array.isArray(t))return t;if("string"==typeof t&&t.startsWith("["))try{const e=JSON.parse(t);return Array.isArray(e)?e:[]}catch{return[]}return[]}function n(n,r,s){const a=new Map;for(const e of r){const o=t(e);a.has(o)||a.set(o,e)}const c=new Map,i=new Map;for(const t of n){const n=t.route??t.route_type;if(!e(n))continue;const r=o(t.original_path);if(0===r.length)continue;const f=r.map(t=>t.toUpperCase());if(!t.transmitted&&f.length>=2){const t=f[f.length-2];if(t){const e=a.get(t);e&&i.set(e,(i.get(e)??0)+1)}}if(f.includes(s))for(const t of f){if(t===s)continue;const e=a.get(t);e&&c.set(e,(c.get(e)??0)+1)}}let f=0,u=0;for(const t of r)f=Math.max(f,c.get(t)??0),u=Math.max(u,i.get(t)??0);const h=new Map;let d=0,g=0,l=0;for(const t of r){const e=c.get(t)??0,o=i.get(t)??0,n=f>0?Math.round(e/f*100):0,r=u>0?Math.round(o/u*100):0,s=n+r;h.set(t,{hash:t,listenerCount:e,loudCount:o,listenerScore:n,loudScore:r,blendedScore:s}),d=Math.max(d,n),g=Math.max(g,r),l=Math.max(l,s)}return{scores:h,maxListenerScore:d,maxLoudScore:g,maxBlendedScore:l}}const r={YELLOW:"#FBBF24",GREEN:"#719872",RED:"#E12672",GRAY:"#505050"};export{r as L,n as c};
@@ -1 +1 @@
import{al as t}from"./index-BORukrl8.js";async function e(e,r=10){return t("/api/ping_neighbor",{method:"POST",body:JSON.stringify({target_id:e,timeout:r})})}const r=["Chat Node","Repeater","Room Server","Hybrid Node","Unknown"];async function s(s,o=10){if(o<1||o>60)return{success:!1,error:"Timeout must be 1-60 seconds"};let n;const a=s.match(/^(0x)?([0-9a-fA-F]{1,2})$/);if(a)n=`0x${a[2].padStart(2,"0")}`;else{const e=await async function(e){const s=e.toLowerCase();for(const o of r)try{const e=await t(`/api/adverts_by_contact_type?contact_type=${encodeURIComponent(o)}&hours=168`),r=e.success&&e.data?e.data:e,n=(Array.isArray(r)?r:[]).find(t=>t.node_name&&t.node_name.toLowerCase()===s);if(n&&n.pubkey)return`0x${n.pubkey.substring(0,2)}`}catch{continue}return null}(s);if(!e)return{success:!1,error:`Node '${s}' not found`};n=e}const c=await e(n,o);if(!c.success||!c.data)return{success:!1,error:c.error||"Ping failed"};const i=(u=c.data).rtt_ms>500||u.rssi<-120?"Poor":u.rtt_ms>250||u.rssi<-100?"Fair":u.rtt_ms>100||u.rssi<-80?"Good":"Excellent";var u;return{success:!0,data:{...c.data,quality:i}}}export{s as a,e as p};
import{al as t}from"./index-DPcwpo2i.js";async function e(e,r=10){return t("/api/ping_neighbor",{method:"POST",body:JSON.stringify({target_id:e,timeout:r})})}const r=["Chat Node","Repeater","Room Server","Hybrid Node","Unknown"];async function s(s,o=10){if(o<1||o>60)return{success:!1,error:"Timeout must be 1-60 seconds"};let n;const a=s.match(/^(0x)?([0-9a-fA-F]{1,2})$/);if(a)n=`0x${a[2].padStart(2,"0")}`;else{const e=await async function(e){const s=e.toLowerCase();for(const o of r)try{const e=await t(`/api/adverts_by_contact_type?contact_type=${encodeURIComponent(o)}&hours=168`),r=e.success&&e.data?e.data:e,n=(Array.isArray(r)?r:[]).find(t=>t.node_name&&t.node_name.toLowerCase()===s);if(n&&n.pubkey)return`0x${n.pubkey.substring(0,2)}`}catch{continue}return null}(s);if(!e)return{success:!1,error:`Node '${s}' not found`};n=e}const c=await e(n,o);if(!c.success||!c.data)return{success:!1,error:c.error||"Ping failed"};const i=(u=c.data).rtt_ms>500||u.rssi<-120?"Poor":u.rtt_ms>250||u.rssi<-100?"Fair":u.rtt_ms>100||u.rssi<-80?"Good":"Excellent";var u;return{success:!0,data:{...c.data,quality:i}}}export{s as a,e as p};
File diff suppressed because one or more lines are too long
+2 -2
View File
@@ -39,10 +39,10 @@
--font-data: 'JetBrains Mono', 'SF Mono', Monaco, monospace;
}
</style>
<script type="module" crossorigin src="/assets/index-BORukrl8.js"></script>
<script type="module" crossorigin src="/assets/index-DPcwpo2i.js"></script>
<link rel="modulepreload" crossorigin href="/assets/vendor-core-WoOfkQwm.js">
<link rel="modulepreload" crossorigin href="/assets/vendor-react-0D__tamq.js">
<link rel="stylesheet" crossorigin href="/assets/index-CW2GYvY6.css">
<link rel="stylesheet" crossorigin href="/assets/index-wp0elHoG.css">
</head>
<body>
<div id="root"></div>
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "pymc_console",
"version": "0.9.159",
"version": "0.9.160",
"description": "Vite + React Dashboard for pyMC_Repeater",
"private": true,
"type": "module",