A Dropdown variant inside a component doesnt function properly

Hi guys

Need help! pls help me with a solution as I am new to Figma.

In the page Header section, I have created the header as component, and then there is another dropdown component which i added as variant inside the header component. now the header section is a main component. now i can copy the header section in another page. Now when i copied the header variant in another page and tried to open the drop-down, it started stretching. but works perfectly fine in the main header component, idk why its happening like that in component’s variant. Can anyone pls help me with this ?

pls find the attached images below.

Do you have auto layout applied to the header? It looks like the dropdown is trying to fill the header height. You could get around this by turning off the auto layout if it isn’t needed or using absolute positioning on the dropdown.