Skip to content

Multi-bridge Phase 1.5: Connection Live Activity carries bridge name #66

@tashda

Description

@tashda

Why

With switching enabled (#1.3), the Connection Live Activity must clearly show which bridge is connecting/connected/lost. Today the activity only carries serverHost: String, which is opaque ("192.168.1.42") and indistinguishable when two bridges live on the same LAN.

What

  • ConnectionActivityAttributes already has serverHost. Add bridgeDisplayName: String (the user-friendly name ?? host from ConnectionConfig.displayName).
  • Update the widget UI in ConnectionActivityWidget.swift to show name as primary, host as secondary.
  • ConnectionLiveActivityCoordinator.show(host:phase:attempt:maxAttempts:) becomes show(bridge:phase:attempt:maxAttempts:) taking the full ConnectionConfig.
  • Caller in ConnectionSessionController.reconnect() passes the active config.
  • Existing dedup currently uses serverHost as the dedup key. Widen to (bridgeID, serverHost) or just bridgeID so switching to a same-host but different-name bridge still replaces the activity correctly.

Files

  • Shellbee/LiveActivities/ConnectionActivityAttributes.swift
  • Shellbee/LiveActivities/ConnectionActivityWidget.swift
  • Shellbee/LiveActivities/ConnectionLiveActivityCoordinator.swift
  • Shellbee/App/ConnectionSessionController.swiftreconnect() call sites.

Verification

  • Connect to a bridge named "Main"; lock screen; activity shows "Main" prominently.
  • Switch to "Lab"; activity replaces (no duplicate). On a same-host different-name switch, dedup still works.

Phase

Phase 1 of multi-bridge support. Depends on #1.1.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions