Fix fit-contents for dialogs