How to hide the background underneath the border

前端 未结 4 2109
耶瑟儿~
耶瑟儿~ 2020-12-07 00:30

I need to modify a website to make the clickable zone of all links bigger for mobile devices. I gave all links a transparent border and a negative margin<

4条回答
  •  借酒劲吻你
    2020-12-07 00:54

    CSS background fills the area of the border, with the border-color layering over this.

    As you have a transparent border, it is displaying the background-color behind it.

    With plain HTML/CSS, I'm not sure there is a way around this.

    This jsFiddle demostrates this:

    http://jsfiddle.net/hq65C/8/

提交回复
热议问题