CSS borders interfering with absolute positioning

后端 未结 3 1277
悲哀的现实
悲哀的现实 2021-02-19 00:01

[edit: clarified that box-sizing: border-box doesn\'t seem applicable, since I\'m using absolute positioning]

The following code illustrates my problem. I\'m using absol

3条回答
  •  孤城傲影
    2021-02-19 00:05

    I also discovered that using a border of zero width (so that it doesn't affect layout), and then adding a box-shadow to emulate a visible border, seems to work well.

提交回复
热议问题