首页 > 教程 > 网页特效源码 > 网页css

    收藏

    自定义 border(dashed)虚线的间距
    2024-02-05网页css49℃
    广告
    核心提示:自定义 border(dashed)虚线的间距 效果展示代码展示!DOCTYPE htmlhtml lang="zh-CN"headmeta charset="UTF-8" /titleDocument/titlestylebody{background: #000;display: flex;align-items: center;justify-content: center;}div{margin-top: 100px;width: 300px;height:

    自定义 border(dashed)虚线的间距  效果展示 



     代码展示

    <!DOCTYPE html>
    <html lang="zh-CN">
    <head>
    	<meta charset="UTF-8" />
    	<title>document</title>
    	<style>
    		body{
    			background: #000;
    			display: flex;
    			align-items: center;
    			justify-content: center;
    		}
    		div{
    			margin-top: 100px;
    			width: 300px;
    			height: 2px;
    			background: linear-gradient(to right, transparent 0%, transparent 50%,#CCC 50%,#CCC 100%);
    			background-size: 15px 1px;
    			background-repeat: repeat-x;
    		}
    	</style>
    </head>
    <body>
    	<div></div>
    </body>
    </html>

 
  • 文本链接:https://mbtxw.com/Course/show.php?itemid=177
  • 文章来源:模版天下网
  • 版权声明:除非特别标注,否则均为本站原创文章,转载时请以链接形式注明文章出处。
0相关评论