Is it possible to achieve a
-like effect without using the
tag?

前端 未结 9 2328
春和景丽
春和景丽 2020-12-01 06:03

I personally like the

tag because of how it draws a box and puts the at the top of it, over the border. Like this.

9条回答
  •  孤街浪徒
    2020-12-01 06:41

    I believe you already know the answer.

    You have 2 options, provide your own border (that's a lot of unnecessary work) or position an element with occludes the border (the problem with that is that you can only have a solid background color, but maybe that's fine).

    To my knowledge there's not anything you can do to make this workout nicely in every browser out there. I like your style though, it's the right approach but probably not a problem you'll be able to solve in a satisfying manner.

    My general opinion on these topics is that you should not try and do things with the web that requires A) excessive effort or B) a markup solution which is not entirely obvious to begin with. The web has limitations and you would do well to ad-her to them rather than trying to work around those limitations.

    So I'm forced to ask, what's the problem with ?

提交回复
热议问题