欧酷网

您的位置:主页>前端>

CSS n行显示不下显示...

   
<div class="aa">
This is the first section...This is the first section...This is the first section...This is the
first section...This is the first section...This is the first section...This is the first section...This is the
first section...This is the first section...This is the first section...This is the first section...This is the
first section...This is the first section...This is the first section...
</div>

<style>
	.aa {
            -webkit-box-orient: vertical;
            overflow: hidden;
            text-overflow: ellipsis;
            display: -webkit-box;
            -webkit-line-clamp: 2; // n
            width: 540px;
    }
</style>
  • 点赞

  • 收藏

  • 分享

  •    
    • 文章举报

雨诺倾诚_Ella

 
发布了25 篇原创文章 ·    获赞 2 ·    访问量 5155  

私信

关注

相关文章推荐