Can't connect variable to a toggle-switch when toggle-switch is inside a component

I have a toggle-switch that is either selected (switched-on) or not-selected (switched-off). I can assign the toggle-switch to a variable called ‘ShowSection’ so that when it is switched-on, a section will be visible. This works except when I put the switch inside a component. Once the toggle switch is inside another component, I do not have the ability to assign the switch to a variable. The ‘assign variable’ icon that usually appears in the design tab when I hover over the ‘Selected’ property is no longer visible. Why isn’t this possible?

I can assign the switch to a variable by detaching the component’s instance after putting it to a frame. But this is not ideal.