Status Update
Comments
ap...@google.com <ap...@google.com> #2
ap...@google.com <ap...@google.com> #3
ap...@google.com <ap...@google.com> #4
Re navController.navigate()
to make a bottom sheet appear.
If you'd like to request changes to the ModalBottomSheetLayout
and similar APIs, you'll want to file a
ap...@google.com <ap...@google.com> #5
Fwiw this change does enable treating bottom sheets more like a window-esque thing, but they definitely won't be local.
ap...@google.com <ap...@google.com> #6
ap...@google.com <ap...@google.com> #7
ap...@google.com <ap...@google.com> #8
Until this is implemented, could we at least get a warning notice in the documentation?
Not great to find out half way through a migration that this isn't possible.
Looks like we'll need to rework our app's navigation system (currently based on Fragments) just to support bottom sheets with a Bottom Navigation Bar at first glance. From the docs this wasn't clear.
ap...@google.com <ap...@google.com> #9
Re
BottomSheetDialogFragment
, which is what you'd use in a fragment based system, has been supported since dialog
destinations were added in
ap...@google.com <ap...@google.com> #10
Branch: androidx-main
commit d65d5731e4f0dfe560b43eae886a4fabfa949b84
Author: Jeremy Woods <jbwoods@google.com>
Date: Wed Feb 21 02:14:42 2024
Add Navigation Material from Accompanists to androidx
Now that the needed compose material API are stable, we can move the
navigation material module from Accompanists to Androidx. This means we
will have a new compose-material-navigation module that provides support
for bottomsheets.
RelNote: "Providing new Compose Material Navigation module that adds
support for Bottomsheets in Compose Material."
Test: Added tests and samples
Bug: 180247978
Change-Id: Ia93eb757a32b04dac8ab3ebd2d73207a68635b80
A compose/material/material-navigation/api/current.txt
A compose/material/material-navigation/api/res-current.txt
A compose/material/material-navigation/api/restricted_current.txt
A compose/material/material-navigation/build.gradle
A compose/material/material-navigation/samples/build.gradle
A compose/material/material-navigation/samples/src/main/java/androidx/compose/material/navigation/samples/ComposeMaterialNavigationSamples.kt
A compose/material/material-navigation/src/androidTest/java/androidx/compose/material/navigation/BottomSheetNavigatorTest.kt
A compose/material/material-navigation/src/androidTest/java/androidx/compose/material/navigation/NavGraphBuilderTest.kt
A compose/material/material-navigation/src/androidTest/java/androidx/compose/material/navigation/SheetContentHostTest.kt
A compose/material/material-navigation/src/main/java/androidx/compose/material/navigation/BottomSheet.kt
A compose/material/material-navigation/src/main/java/androidx/compose/material/navigation/BottomSheetNavigator.kt
A compose/material/material-navigation/src/main/java/androidx/compose/material/navigation/NavGraphBuilder.kt
A compose/material/material-navigation/src/main/java/androidx/compose/material/navigation/SheetContentHost.kt
M compose/material/material/integration-tests/material-demos/build.gradle
M compose/material/material/integration-tests/material-demos/src/main/java/androidx/compose/material/demos/MaterialDemos.kt
M compose/material/material/src/commonMain/kotlin/androidx/compose/material/ModalBottomSheet.kt
M docs-tip-of-tree/build.gradle
M settings.gradle
ap...@google.com <ap...@google.com> #11
This has been added internally and will be released as part of the compose.material
library, not navigation.
ap...@google.com <ap...@google.com> #12
The following release(s) address this bug.It is possible this bug has only been partially addressed:
androidx.compose.material:material:1.7.0-alpha04
androidx.compose.material:material-android:1.7.0-alpha04
androidx.compose.material:material-desktop:1.7.0-alpha04
ap...@google.com <ap...@google.com> #13
ap...@google.com <ap...@google.com> #14
I guess the release that addresses this is actually:
androidx.compose.material:material-navigation:1.7.0-alpha04
As #13 said, we are missing this for Material3 bottom sheets.
I see that there's another issue tracking that here:
ap...@google.com <ap...@google.com> #15
Some guidance about usage would be very welcome. I get java.lang.IllegalStateException: Could not find Navigator with name "bottomSheet". You must call NavController.addNavigator() for each navigation type.
crash and can't find any proper example of this new extension usage:
Scaffold(
bottomBar = {...}
) { innerPadding ->
NavHost(
navController,
startDestination = "explore_graph",
Modifier.fillMaxSize()
) {
// nested graphs
bottomSheet("profile_bottom_sheet") { // CRASHES
Text("Bottom Sheet", Modifier.padding(16.dp))
}
}
}
}
}
}
}
I use androidx.compose.material:material-navigation:1.7.0-beta01
, but my project is material3, could it be the reason?
ap...@google.com <ap...@google.com> #16
Re
val bottomSheetNavigator = rememberBottomSheetNavigator()
val navController = rememberNavController(bottomSheetNavigator)
If you don't use those lines, you'd get that error message.
ap...@google.com <ap...@google.com> #17
Project: platform/frameworks/support
Branch: androidx-main
Author: Jeremy Woods <
Link:
Provide NavGraphImpl
Expand for full commit details
Provide NavGraphImpl
Moving all common code to the common source set and allowing the
specific platforms to use that source.
RelNote: N/A
Test: all tests pass
Bug: 403616316
Change-Id: If77617d32d274ea2f5f76107336293b562fda300
Files:
- M
navigation/navigation-common/bcv/native/current.txt
- M
navigation/navigation-common/src/androidMain/kotlin/androidx/navigation/NavGraph.android.kt
- A
navigation/navigation-common/src/commonMain/kotlin/androidx/navigation/internal/NavGraphImpl.kt
- M
navigation/navigation-common/src/nonAndroidMain/kotlin/androidx/navigation/NavGraph.nonAndroid.kt
Hash: 162602b9a59566b2f341aea043de202b72fccbed
Date: Wed Apr 02 01:40:22 2025
ap...@google.com <ap...@google.com> #18
Project: platform/frameworks/support
Branch: androidx-main
Author: Jeremy Woods <
Link:
Provide NavDestinationImpl
Expand for full commit details
Provide NavDestinationImpl
Moving all common code to the common source set and allowing the
specific platforms to use that source.
RelNote: N/A
Test: all tests pass
Bug: 403616316
Change-Id: Ia7ea5ba90d98353147c710bc43780e120f608c84
Files:
- M
navigation/navigation-common/bcv/native/current.txt
- M
navigation/navigation-common/build.gradle
- M
navigation/navigation-common/src/androidMain/kotlin/androidx/navigation/NavDestination.android.kt
- M
navigation/navigation-common/src/commonMain/kotlin/androidx/navigation/NavDestination.kt
- A
navigation/navigation-common/src/commonMain/kotlin/androidx/navigation/internal/NavDestinationImpl.kt
- M
navigation/navigation-common/src/nonAndroidMain/kotlin/androidx/navigation/NavDestination.nonAndroid.kt
- M
navigation/navigation-common/src/nonAndroidMain/kotlin/androidx/navigation/internal/NavContext.nonAndroid.kt
Hash: 3c59943b0caac826903b5cbc5d033b69ab0c3b5c
Date: Fri Mar 28 03:56:37 2025
ap...@google.com <ap...@google.com> #19
Project: platform/frameworks/support
Branch: androidx-main
Author: Jeremy Woods <
Link:
Move Navigator to common
Expand for full commit details
Move Navigator to common
There is no platform specific code in Navigator.
RelNote: N/A
Test: all tests pass
Bug: 403616316
Change-Id: I28c3cec15401a458124ee8e209d88fb807435fa6
Files:
- M
navigation/navigation-common/bcv/native/current.txt
- D
navigation/navigation-common/src/androidMain/kotlin/androidx/navigation/Navigator.android.kt
- M
navigation/navigation-common/src/commonMain/kotlin/androidx/navigation/Navigator.kt
- D
navigation/navigation-common/src/nonAndroidMain/kotlin/androidx/navigation/Navigator.nonAndroid.kt
Hash: 0ed3a0167619b3af5eabd1e167936ad6acd8dc46
Date: Wed Mar 26 19:59:07 2025
ap...@google.com <ap...@google.com> #20
Project: platform/frameworks/support
Branch: androidx-main
Author: Jeremy Woods <
Link:
Move noOpNavigator to common
Expand for full commit details
Move noOpNavigator to common
Moving the implementation of the NoOpNavigator to the common source set
and deleting the platform specific versions.
RelNote: n/a
Test: all tests pass
Bug: 403616316
Change-Id: I6cae3b46879633059eb50d768819cafb7de95cb6
Files:
- D
navigation/navigation-common/src/androidMain/kotlin/androidx/navigation/NoOpNavigator.android.kt
- M
navigation/navigation-common/src/commonMain/kotlin/androidx/navigation/NoOpNavigator.kt
- D
navigation/navigation-common/src/nonAndroidMain/kotlin/androidx/navigation/NoOpNavigator.nonAndroid.kt
Hash: fa6cc966c5fa9773f8c1a5610b0f9252f5fb18f4
Date: Thu Mar 27 00:16:35 2025
ap...@google.com <ap...@google.com> #21
Project: platform/frameworks/support
Branch: androidx-main
Author: Jeremy Woods <
Link:
Move ComposeNavGraphNavigator to common
Expand for full commit details
Move ComposeNavGraphNavigator to common
Moving the implementation of the ComposeNavGraphNavigator to the common source set
and deleting the platform specific versions.
RelNote: n/a
Test: all tests pass
Bug: 403616316
Change-Id: Id01ca3d5db0399c61cba4588f67668213cc5af4b
Files:
- D
navigation/navigation-compose/src/androidMain/kotlin/androidx/navigation/compose/ComposeNavGraphNavigator.android.kt
- M
navigation/navigation-compose/src/commonMain/kotlin/androidx/navigation/compose/ComposeNavGraphNavigator.kt
- D
navigation/navigation-compose/src/nonAndroidMain/kotlin/androidx/navigation/compose/ComposeNavGraphNavigator.nonAndroid.kt
Hash: d41eac2e40be89122d8204321e48e49cd1791f81
Date: Wed Apr 02 05:36:30 2025
ap...@google.com <ap...@google.com> #22
Project: platform/frameworks/support
Branch: androidx-main
Author: Jeremy Woods <
Link:
Move ClassType to common
Expand for full commit details
Move ClassType to common
Even though ClassType is only used by tools, we should still provide an
equal level of support on the Android side. Moving this to common allow
us to keep this around for other Navigation implementations that are in
Common.
RelNote: N/A
Test: ./gradlew checkApi
Bug: 403616316
Change-Id: I81efc0571178051fe9ef7ee00fab37378b271876
Files:
- M
navigation/navigation-common/bcv/native/current.txt
- M
navigation/navigation-common/src/androidMain/kotlin/androidx/navigation/NavDestination.android.kt
- M
navigation/navigation-common/src/commonMain/kotlin/androidx/navigation/NavDestination.kt
- M
navigation/navigation-common/src/nonAndroidMain/kotlin/androidx/navigation/NavDestination.nonAndroid.kt
Hash: 58806860cf5cd0eb2ffd4a0886b56b2e48587aa8
Date: Wed Apr 02 21:42:19 2025
ap...@google.com <ap...@google.com> #23
Project: platform/frameworks/support
Branch: androidx-main
Author: Jeremy Woods <
Link:
Move NavGraphNavigator to common
Expand for full commit details
Move NavGraphNavigator to common
Moving the implementation of the NavGraphNavigator to the common source set
and deleting the platform specific versions.
RelNote: n/a
Test: all tests pass
Bug: 403616316
Change-Id: Id28c449a52d14e2df101db25ded4d8e428c37c80
Files:
- M
navigation/navigation-common/bcv/native/current.txt
- D
navigation/navigation-common/src/androidMain/kotlin/androidx/navigation/NavGraphNavigator.android.kt
- M
navigation/navigation-common/src/commonMain/kotlin/androidx/navigation/NavGraphNavigator.kt
- D
navigation/navigation-common/src/nonAndroidMain/kotlin/androidx/navigation/NavGraphNavigator.nonAndroid.kt
Hash: a011b3bc23a80d510086701719d9a1ed88d7a15d
Date: Wed Apr 02 05:22:24 2025
ap...@google.com <ap...@google.com> #24
Project: platform/frameworks/support
Branch: androidx-main
Author: Jeremy Woods <
Link:
Move DialogNavigator to common
Expand for full commit details
Move DialogNavigator to common
Moving the implementation of the DialogNavigator to the common source set
and deleting the platform specific versions.
RelNote: n/a
Test: all tests pass
Bug: 403616316
Change-Id: Iaa801c14d263d7f372dabdc6e08c80d15926ed5b
Files:
- D
navigation/navigation-compose/src/androidMain/kotlin/androidx/navigation/compose/DialogNavigator.android.kt
- M
navigation/navigation-compose/src/commonMain/kotlin/androidx/navigation/compose/DialogNavigator.kt
- D
navigation/navigation-compose/src/nonAndroidMain/kotlin/androidx/navigation/compose/DialogNavigator.nonAndroid.kt
Hash: cc99a247b36eeacb363a87d379bea7da32a86d31
Date: Wed Apr 02 05:51:40 2025
ap...@google.com <ap...@google.com> #25
Project: platform/frameworks/support
Branch: androidx-main
Author: Jeremy Woods <
Link:
Move ComposeNavigator to common
Expand for full commit details
Move ComposeNavigator to common
Moving the implementation of the ComposeNavigator to the common source set
and deleting the platform specific versions.
RelNote: n/a
Test: all tests pass
Bug: 403616316
Change-Id: I76f5ed06735867797b42cc22ef1efcf072200f5f
Files:
- D
navigation/navigation-compose/src/androidMain/kotlin/androidx/navigation/compose/ComposeNavigator.android.kt
- M
navigation/navigation-compose/src/commonMain/kotlin/androidx/navigation/compose/ComposeNavigator.kt
- D
navigation/navigation-compose/src/nonAndroidMain/kotlin/androidx/navigation/compose/ComposeNavigator.nonAndroid.kt
Hash: 27fca1659aa6ae2f085c758cb939e5990e3d8fc2
Date: Wed Apr 02 05:43:44 2025
jb...@google.com <jb...@google.com> #26
This has been completed and will be available in Navigation 2.9.0-beta01.
Description
Auditing our KMP libraries to make sure we like the platform specific vs common code.