saadeghi / daisyui

๐ŸŒผ ๐ŸŒผ ๐ŸŒผ ๐ŸŒผ ๐ŸŒผ โ€ƒThe most popular, free and open-source Tailwind CSS component library
https://daisyui.com
MIT License
34.1k stars 1.3k forks source link

bug: cant use large image in drawer #3076

Closed Superpat closed 5 months ago

Superpat commented 5 months ago

What version of daisyUI are you using?

tailwind play

Which browsers are you seeing the problem on?

Chrome, Firefox

Reproduction URL

https://play.tailwindcss.com/SWIOgQbzVQ

Describe your issue

Hello,

Heres a minimal reproduction of a problem I'm having with an app where I put a logo in the top part of the drawer.

Somehow, even if I constrain the size of the image, the drawer still ends up squeezing the drawer-content to the side when I use lg:drawer-open. This is not a problem when I only use drawer.

So how do I fit an image in the drawer-side ?

github-actions[bot] commented 5 months ago

Thank you @Superpat for reporting issues. It helps daisyUI a lot ๐Ÿ’š
I'll be working on issues one by one. I will help with this one as soon as a I find a solution.
In the meantime providing more details and reproduction links would be helpful.

Superpat commented 5 months ago

So I fixed this by using a vw width on the img instead of just a % width on the drawer-side.

Not sure why the img is visually small with the % width but still makes the drawer-side take more space, but I think it's a css thing, not a daisy thing.