Assigned
Status Update
Comments
ri...@google.com <ri...@google.com>
ti...@google.com <ti...@google.com> #2
Can you try with the latest snapshot? Not reproducible for me on androidx-main.
nj...@google.com <nj...@google.com>
le...@google.com <le...@google.com> #3
Ok, after trying a couple more versions, realized this is a duplicate of
From the release notes:
AndroidView's update callback's first invocation will now be defered until the view is attached, instead of running when the composition that introduces the AndroidView is applied. This fixes a bug where the update callback wouldn't be invalidated if a state it read was changed immediately by an effect. (Ie9438,
) b/291094055
Sorry for the confusion!
ti...@google.com <ti...@google.com> #4
The shadow clipping is not specific to animation. The issue is present whenever one has an alpha != 1f. See
Description
Jetpack Compose version: 1.6.8
Jetpack Compose component used: AnimatedVisibility, animateFloatAsState, Modifier.graphicsLayer
There isn't an easy way to animate the alpha of Composables that have shadows applied via the shadow() modifier, or more generally Composables that draw outside of their bounds. As soon as the alpha is set to <1.0f, the Composable is clipped.
Offsets applied to the Composable also result in incorrect shadow rendering while the alpha is set to <1.0f.
Setting the CompositingStrategy doesn't offer a way to fix this, and
Steps to Reproduce or Code Sample to Reproduce:
With AnimatedVisibility:
Using graphicsLayer directly: