CSS box shadow on container div causes scrollbars

后端 未结 9 1557
难免孤独
难免孤独 2020-12-29 14:22

I have a website with the following setup:

9条回答
  •  再見小時候
    2020-12-29 15:12

    Not sure if this is the best solution as you have to add a container div, but if you wrap the element in a container div and set the overflow to hidden, it seems to work. You'll have to set padding where ever you want the shadow to be visible though.

    I know it's not the best solution to this, but it works fine and I can't seem to figure out any other solution.

提交回复
热议问题