A component can have more than one accessibility trait, they can be combined. A heading can be a button too, for example. Or a button could be selected. You can insert or remove the selected trait to the button, when needed.

A like button has the button trait and it is shown how you can insert or remove the selected trait whenever it is filled, or not. A heading has a disclosure indicator hinting that you can interact with it to go to the full list, so it is configured with both a heading and a button trait.