Goal:
The aim is to design two divs positioned side by side on a webpage, covering the entire width of the page. This should be achieved using the latest versions of react + Material UI.
The div on the left should have a fixed width of 200px.
While the div on the right should occupy the remaining space on the page.
In CSS, the width of the right div could be calculated dynamically using calc(100% - 200px).
Issue Encountered:
I faced difficulty implementing this in Material UI. I attempted inline styling ( style={{width='calc(100%-200)'}}
), which compiles but does not yield the desired result. I also experimented with makeStyles()
, but to no success.
Your valuable assistance in resolving this matter is greatly appreciated.