galex
08/07/2025, 2:33 PMnav3
, by any chance?Pablichjenkov
08/07/2025, 11:34 PMNavDisplay
composable from the new Navigation3 library. Here is some code trying that out and it works like a charm!
Is not the recommended way to use this library but in case there is no other alternative for a quick solution. Here it is:
https://github.com/pablichjenkov/nav3-playground
The demo basically consist of one NavDisplay
for the most top BottomBarNavigation and another NavDisplay
inside the third tab, hosted in a ModalDrawer.Mark
08/10/2025, 9:13 AMpainterResource(Int)
throws a “Error attempting to load resource:” exception (the resource ID is declared as a placeholder in some common module and then provided in some higher level module, and it seems that some weird devices don’t like that). This particular image isn’t important so I’d like to just show blank space when it fails. However, since we can’t use try/catch around composable functions, how to deal with this?
EDIT: I suppose I could just test using ImageBitmap.imageResource(res, id)
but since this is a rare case I don’t want to do it every time, only as a fallback.David Rubio
08/10/2025, 4:28 PMflamy
08/11/2025, 10:23 AMweight(1f)
inside a Scrollable Column? I tested the app and it works fine according to my requirements.
The app is also not crashing nor lagginggratitude thank youUberunix
08/14/2025, 12:16 PMvar amountInput by remember {mutableStateOf()}
However, in a new unit, I'm being directed to write it differently with no explanation.
var amountInput: MutableState<String> = mutableStateOf("0")
Is there an appreciable between these two idioms? Are there use-cases specific to each?Tiago Nunes
08/14/2025, 1:22 PMproject has unresolved dependencies: ["androidx.compose.ui:ui-tooling" "androidx.compose.ui:ui-test-manifest"]
, after adding Compose?
I believe this may be a bug in the Gitlab runner resolving dependencies declared with debugImplementation, but I can't find anyone online who's facing the same issue.Bradleycorn
08/14/2025, 8:15 PMColton Idle
08/14/2025, 10:17 PM@Composable
fun Foo(){
val myFont = FontFamily(Font(`R.font.myfont`))
...
}
bad? Should be wrapped in a remember?Seri
08/15/2025, 4:22 PMMatti MK
08/18/2025, 10:32 AMSearchBar
component I get the following crash:
java.lang.NoSuchMethodError: No static method SearchBar-Y92LkZI(Lkotlin/jvm/functions/Function2;ZLkotlin/jvm/functions/Function1;Landroidx/compose/ui/Modifier;Landroidx/compose/ui/graphics/Shape;Landroidx/compose/material3/SearchBarColors;FFLandroidx/compose/foundation/layout/WindowInsets;Lkotlin/jvm/functions/Function3;Landroidx/compose/runtime/Composer;II)V in class Landroi
I've got no issues with other M3 components I've tried. Running Compose BOM 2025.05.01
, nav3, M3 adaptive. I've tried to look for this in the IssueTracker, but no luck there.
Any suggestions?oday
08/18/2025, 3:19 PMeygraber
08/18/2025, 10:33 PMentryProvider
DSL in nav3 supposed to be remembered
or is it not worth it?Alex Styl
08/19/2025, 4:02 AMLocalSoftwareKeyboardController
but I can't dismiss the keyboard from a modal/dialog if the reference of the SoftwareKeyboardController was taken from outside of the dialog's scope.shock 11
08/19/2025, 7:53 PMAdrian Landborn
08/21/2025, 7:26 AMAbhimanyu
08/22/2025, 10:32 AMmain
source set or the debug
source set?
Pros and Cons I could see:
main
Pros - Can preview any composable (public, internal and private
)
Cons - Preview methods are included in the final source code, which is not required.
debug
Pros - Preview methods are NOT included in the final source code.
Cons - Can not preview private
Composables as they are inaccessible from debug
source set.
I am referring to methods that contain code only for preview purposes.
E.g.
@Preview
@Compose
fun GreetingPreview() {
Greeting("Hello Compose!")
}
Colton Idle
08/23/2025, 5:22 PMprivate val _isInitialized = mutableStateOf(false)
val isInitialized: State<Boolean> = _isInitialized
luke_c
08/27/2025, 7:43 AMAndroidView
which reads from a lambda passed into the function, which is stable
AndroidView(factory = { context ->
onViewCreated()
...
}
)
However this is causing the factory function to be called, and the underlying view to be re-created on every configuration change. The lambda is ultimately created this way:
val onViewEvent = remember(viewModel) { viewModel::onViewEvent }
val onViewCreated = { onViewEvent(SomeViewEvent) }
The problem I'm seeing is that remember
doesn't survive configuration changes, so onViewEvent
gets remember'd again with a new reference (even though the viewModel instance is the same) and we can't use rememberSaveable
with lambdas (and I'm not sure it feels right to do so!)
Has anyone dealt with this before and figured out a solution?Mofe Ejegi
08/28/2025, 5:02 PMrememberSaveable
inputs. I assumed it's meant to work just like remember
keys or like LaunchedEffect
keys where any change in any of the keys would trigger a re-calculation or re-run of the init block.
But for some reason, it does't always run - it gives inconsistent results across different devices, and sometimes even on the same device.
Take a look at this code below, why does the print statement in the LaunchedEffect
and the remember
block work, but not the rememberSaveable
?
val density = LocalDensity.current
val d = density.density
val f = density.fontScale
println("Density: $d, Font Scale: $f")
LaunchedEffect(d, f) {
println("Screen density changed, resetting content height")
}
val testRememberHeight by remember(d, f) {
println("Recalculating test height")
mutableFloatStateOf(0f)
}
val contentHeightDp by rememberSaveable(d, f) {
println("Recalculating content height")
mutableFloatStateOf(0f)
}
Am I doing something wrong? Perhaps the way I'm changing the density (using the Android Studio Emulator quick tools) isn't the correct way?
Though I clearly see the logs printed indicating the Density and Scale changing.louiscad
09/01/2025, 1:44 PMColumn
with the verticalScroll
modifier than can scroll (i.e. content longer than the parent):
Spacer(Modifier.weight(1f).heightIn(min = 16.dp))
Spacer(Modifier.weight(1f).requiredHeightIn(min = 16.dp))
I have found NO working workaround.
There's also an abandoned issue on YouTrack: https://youtrack.jetbrains.com/issue/CMP-4212Jojo C
09/04/2025, 4:06 AMcontentType
? I have tried it and it works with Google Password Manager and Bitwarden, it works, but not with Samsung Pass.Irsath Kareem
09/08/2025, 10:58 AMcollectAsStateWithLifecycle()
is not collecting when we use Navigation3 as the Composable is receiving only Lifecycle.state.CREATED not Lifecycle.State.STARTED. But the collect**cycle()
needs STARTED state.
If we manually change minActiveState = CREATED, Then its fine, But the default is not working.......
Navigation3 Version: 1.0.0-alpha08
Lifecycle Navigation3: 2.10.0-alpha03
Runtime, UI, Viewmodel-nav3 libraries
Also included ViewModelStoreNavEntryDecorator, SavedStateNavEntryDecorator... as recommended.
If I fallback to the Navigation-Compose (Legacy), It is working fine......Shahid Iqbal4213
09/08/2025, 4:03 PMEslam Hussein
09/10/2025, 8:38 AMTlaster
09/11/2025, 10:29 AMFatal Exception: java.lang.IllegalStateException: LayoutCoordinate operations are only valid when isAttached is true
when I selecting a text in SelectionContainer -> keep selecting and navigate back. Full stacktrace in thread.Sergio Moral
09/11/2025, 2:09 PMColton Idle
09/11/2025, 3:59 PM/lib/arm64-v8a/libandroidx.graphics.path.so
isn't 16 KB page size compatible. Anyone know if this is a known compose issue? I'm not really doing anything too crazy in my app in terms of dependencies so I'm kinda lost at this androidx.graphics warning.Irsath Kareem
09/13/2025, 3:01 PMModalBottomSheet
is in the composition tree in a specific screen, Overlaided (Behind Sheet) Composables not receiving any pointerInputs (Gestures). - (shouldDismissOnClickOutside = false
)
I need a Behaviour such that, While ModalBottomSheet
is open, I want to interact with other composables behind the Sheet, Is it possible?
I see the implementation of ModalBottomSheet, as it is taking control of entire window.
Any workaround on this?Colton Idle
09/15/2025, 4:31 PMdp
set to a .66
value seems really weird. Is there any sort of documentation i can point to for this instead of just having a feeling that this is wrong? looks like we just copied the exact val from sketch.