A11y semantics heading - scrollable - constraint l...
# compose
A11y semantics heading - scrollable - constraint layout bug We currently tried to mark headings in multiple of our apps and noticed that it strangely doesn’t work in some cases. After days of debugging we pinned it down to following constellations.
Copy code
Column(modifier = Modifier.verticalScroll(rememberScrollState())) {
    ConstraintLayout {
            text = "this should be a heading",
            modifier = Modifier.semantics { heading() })
As soon as something is wrapped in a scrollable container (also tried with LazyLists) and a ConstraintLayout TalkBack does not announce that text as heading. Apart from the semantic tree looking correct (see thread). Anyone an idea what could cause this? Should we file a bug report?
Copy code
Printing with useUnmergedTree = 'false'
Node #1 at (l=0.0, t=56.0, r=259.0, b=89.0)px
 |-Node #2 at (l=0.0, t=56.0, r=259.0, b=89.0)px
   VerticalScrollAxisRange = 'ScrollAxisRange(value=0.0, maxValue=0.0, reverseScrolling=false)'
   Actions = [ScrollBy]
    |-Node #3 at (l=0.0, t=56.0, r=259.0, b=89.0)px
      DesignInfoProvider = 'androidx.constraintlayout.compose.Measurer@9cb80f4'
       |-Node #4 at (l=0.0, t=56.0, r=259.0, b=89.0)px
         Text = '[this should be a heading]'
         Actions = [GetTextLayoutResult]