Skip to content

Commit

Permalink
Merge branch 'develop' into GOVUKAPP-499_onboarding_feature_module
Browse files Browse the repository at this point in the history
  • Loading branch information
davidc-gds committed Jun 19, 2024
2 parents b01d454 + f932d39 commit efd52af
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 3 deletions.
8 changes: 8 additions & 0 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,14 @@

<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
<intent-filter android:autoVerify="true">
<data
android:host="android-deeplink-test.netlify.app"
android:scheme="https" android:pathPrefix="/app" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<action android:name="android.intent.action.VIEW" />
</intent-filter>
</activity>
</application>

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
package uk.govuk.app.home.ui.navigation

import android.content.Intent
import androidx.navigation.NavGraphBuilder
import androidx.navigation.compose.composable
import androidx.navigation.navDeepLink
import androidx.navigation.navigation
import uk.govuk.app.home.ui.HomeRoute

Expand All @@ -13,6 +15,13 @@ fun NavGraphBuilder.homeGraph() {
route = HOME_GRAPH_ROUTE,
startDestination = HOME_ROUTE
) {
composable(HOME_ROUTE) { HomeRoute() }
composable(HOME_ROUTE,
deepLinks = listOf(
navDeepLink {
uriPattern = "/home"
action = Intent.ACTION_VIEW
}
)
) { HomeRoute() }
}
}
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
package uk.govuk.app.settings.ui.navigation

import android.content.Intent
import androidx.navigation.NavController
import androidx.navigation.NavGraphBuilder
import androidx.navigation.compose.composable
import androidx.navigation.navDeepLink
import androidx.navigation.navigation
import uk.govuk.app.settings.ui.SettingsRoute
import uk.govuk.app.settings.ui.SettingsSubRoute
Expand All @@ -16,12 +18,26 @@ fun NavGraphBuilder.settingsGraph(navController: NavController) {
route = SETTINGS_GRAPH_ROUTE,
startDestination = SETTINGS_ROUTE
) {
composable(SETTINGS_ROUTE) {
composable(SETTINGS_ROUTE,
deepLinks = listOf(
navDeepLink {
uriPattern = "/settings"
action = Intent.ACTION_VIEW
}
)
) {
SettingsRoute {
navController.navigateToSettingsSubScreen()
}
}
composable(SETTINGS_SUB_ROUTE) { SettingsSubRoute() }
composable(SETTINGS_SUB_ROUTE,
deepLinks = listOf(
navDeepLink {
uriPattern = "/subroute"
action = Intent.ACTION_VIEW
}
)
) { SettingsSubRoute() }
}
}

Expand Down

0 comments on commit efd52af

Please sign in to comment.