feat: Enhance RelayHub component with subscription count details (still not working)

- Update RelayHubStatus.vue to display both local and global subscription counts, improving user visibility into active subscriptions.
- Add totalSubscriptionCount computed property in useRelayHub.ts to track the total number of subscriptions.
- Implement totalSubscriptionCount getter in relayHub.ts to return the size of the subscriptions map.
- Include debug logging in relayHub.ts for connected relay counts and statuses to aid in troubleshooting.
This commit is contained in:
padreug 2025-08-10 18:19:18 +02:00
parent 356f42d209
commit 36e9694c1b
5 changed files with 26 additions and 3 deletions

View file

@ -13,6 +13,7 @@ export function useRelayHub() {
// Computed properties
const connectedRelayCount = computed(() => relayHub.connectedRelayCount)
const totalRelayCount = computed(() => relayHub.totalRelayCount)
const totalSubscriptionCount = computed(() => relayHub.totalSubscriptionCount)
const connectionHealth = computed(() => {
if (totalRelayCount.value === 0) return 0
return (connectedRelayCount.value / totalRelayCount.value) * 100
@ -250,6 +251,7 @@ export function useRelayHub() {
// Computed
connectedRelayCount,
totalRelayCount,
totalSubscriptionCount,
connectionHealth,
// Methods