In the following code, I don’t understand how I can set the height of each of the children elements (the ones where the className is ???) to the same height as the container with the ref. I have seen people implement workarounds with absolute positioning, however, I cannot get this to work here because there is more than one child element. Does anyone know how to solve this using css only, or is it strictly necessary to use javascript in this case?
Edit: I might also have to make the height of the container with h-32 dynamic, hence I do not want to use a solution with calculate
<div className="100dvh flex flex-col">
<div className="h-32">
{/* Some content */}
</div>
<div
className="relative flex flex-1 justify-between space-x-10 overflow-y-auto"
ref={ref}
>
<div className="flex flex-col items-start">
<div className="???" />
<div className="???" />
<div className="???" />
</div>
<div className="sticky top-0 flex h-full w-96 items-center justify-center">
{/* Some content */}
</div>
</div>
</div>
2
Answers