温馨提示×

温馨提示×

您好,登录后才能下订单哦!

密码登录×
登录注册×
其他方式登录
点击 登录注册 即表示同意《亿速云用户服务条款》

跟Howard学LESS之初见LESS

发布时间:2020-06-17 20:41:08 来源:网络 阅读:227 作者:howardvictor 栏目:web开发

跟Howard学LESS之初见LESS,上代码:

<!DOCTYPE html> <html> <head lang="en"> <meta charset="UTF-8"> <title>跟Howard学LESS之初见LESS</title> <style type="text/css"> .conten ul{ list-style: none; } .conten li{ height: 25px; line-height: 25px; padding-left: 15px; background: url("arr.jpg") no-repeat center left; } .conten li a{ text-decoration: none; color: #535353; font-family: microsoft yahei, "黑体", Arial, Simsun, "Arial Unicode MS", Mingliu, Helvetica; } /*less的写法如下*/ .conten { ul{ list-style: none; } li{ height: 25px; line-height: 25px; padding-left: 15px; background: url("arr.jpg") no-repeat center left; a{ text-decoration: none; color: #535353; font-family: microsoft yahei, "黑体", Arial, Simsun, "Arial Unicode MS", Mingliu, Helvetica; } } } </style> </head> <body> <div class="conten"> <ul> <li><a href="http://www.quban18.com/shiwuquban/dasuanquban/">大蒜祛斑</a>这是测试文档</li> <li><a href="http://www.quban18.com/zhongyaoquban/">中药祛斑</a>这是测试文档</li> <li><a href="http://www.quban18.com/shiwuquban/dasuanquban/">大蒜祛斑</a>这是测试文档</li> </ul> </div> </body> </html>

Less部份:

.conten {
ul{
list-style: none;
}
li{
height: 25px;
line-height: 25px;
padding-left: 15px;
background: url("arr.jpg") no-repeat center left;
a{
text-decoration: none;
color: #535353;
font-family: microsoft yahei, Arial, Simsun, "Arial Unicode MS", Mingliu, Helvetica;
}
}
}

向AI问一下细节
推荐阅读:
  1. less语法
  2. vue中使用less

免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。

AI