I have a payment tab for my checkout page which users should be able to expand to see the payment details. There are two issues I can't figure out. First, how to dynamically change the height of the tab when I expand it. Second, how to dynamically change the y-axis position of the tab so it always stays aligned to the bottom of the page.
As you can see below when I expand the tab, it gets cut off.
For more context, the tab is a custom component I designed. The expansion action is controlled by the arrow toggleIcon and the isExpanded app state variable.