Flexible size for UI modals

Could it be possible to give the user a bit more flexibility in terms of UI modals please?
Sometimes I want to shrink them to not hide too much of the canvas.
In other instances, like in the code editor (custom block/global CSS, code block, stylesheets, etc.), the max-height is quite restricting, as it lacks in vertical height, which isn’t optimal specifically in this case.

In the past, I also pointed out some other examples, like the Clould Library or the Class Modal.
Not sure why this restrictive approach is being followed, as long as there is a min- and max-height/width that is necessary, but I’d appreciate some more freedom.

Please at least for the code editor modals.