DeepLinkRouter

Type-safe deep link parser for KMP Navigation 3.

Maps an incoming OS intent URI to a list of NavKeys representing the target backstack. This ensures that when a user deep links into a detail view, the logical "up" hierarchy is synthesized and correctly populated in the user-owned NavBackStack list.

Supports both legacy query-parameter URIs and modern RESTful path patterns:

  • /nodes -> List of all nodes

  • /nodes/{destNum} -> Node details

  • /nodes/{destNum}/{metric} -> Specific node metric (e.g., /nodes/1234/device-metrics)

  • /messages -> Conversation list

  • /messages/{contactKey} -> Specific conversation

  • /settings -> Settings root

  • /settings/{destNum}/{page} -> Specific settings page for a node

  • /wifi-provision -> WiFi provisioning screen

  • /wifi-provision?address={mac} -> WiFi provisioning targeting a specific device MAC address

Functions

Link copied to clipboard
fun route(uri: CommonUri): List<NavKey>?

Synthesizes a backstack list from an incoming Meshtastic URI.