Fixed
Status Update
Comments
le...@google.com <le...@google.com> #2
an...@google.com <an...@google.com> #3
Thanks for the report!
po...@google.com <po...@google.com> #4
The release notes documentation has been edited to clarify this change in behavior for line height.
To support non-standard text sizes, we encourage users to follow the Material design system and use a different style = LocalTextStyle.current.copy(lineHeight = TextUnit.Unspecified)
, or create a custom Typography
entirely.
ap...@google.com <ap...@google.com> #5
deleted
Description
I’ve got a view/composable structure like this:
And I want that innermost composable to be able to access ambients from the outer one.
The way to do this is first to call
compositionReference()
on the line commented[REF]
, and then use it to create the composition on the line above[DEREF]
.compositionReference()
is a public function, and works as expected. Compose APIs suchcompositionFor()
andsubcomposeInto()
accept aCompositionReference
parameter, but are lower-level than is convenient to use from regular view code (they require dealing withComponentNode
s). There's currently no way to pass theCompositionReference
into the child composition.The simplest way to support this would be for here .
ViewGroup.setContent
to take an optionalCompositionReference
parameter and plumb it through to the deepestcompositionFor
call. I've proven this works using reflection to access private APIsThis was initially discussed in this Slack thread .