How make text-decoration: underline with 2px padding?

后端 未结 10 2347
無奈伤痛
無奈伤痛 2021-02-07 02:19

I like an obedient frotend developer must create underline with 2px padding instead of 1px by default. Is exist simple solution for this?

PS Yeahh guys, I know about div

10条回答
  •  抹茶落季
    2021-02-07 02:42

    #line{
        text-decoration-line: underline;
        text-underline-offset: 1px;
    }
    Text with line


    just use

    {
        text-decoration-line: underline;
        text-underline-offset: 2px;
    }
    

提交回复
热议问题