• 博客园logo
  • 会员
  • 众包
  • 新闻
  • 博问
  • 闪存
  • 赞助商
  • HarmonyOS
  • Chat2DB
    • 搜索
      所有博客
    • 搜索
      当前博客
  • 写随笔 我的博客 短消息 简洁模式
    用户头像
    我的博客 我的园子 账号设置 会员中心 简洁模式 ... 退出登录
    注册 登录
bighappy
君子坦荡荡,小人常戚戚。
代码改变未来。
博客园    首页    新随笔    联系   管理    订阅  订阅

css中书写小三角

我们在开发过程中,有很多的方向标签不是图片,而是用css方法书写上去的。

首先我们要了解原理,border的边框的脚步是45度角。

向左方向:

width:0px;

height:0px;

border-top:4px solid transparent;

border-right:4px solid black;

border-bottom:4px solid transparent;

border-left:4px solid transparent;

向右方向:

width:0px;

height:0px;

border-top:4px solid transparent;

border-left:4px solid black;

border-right:4px solid transparent;

border-bottom:4px solid transparent;

剩下的同学们自己发挥吧。

posted @ 2017-02-21 16:59  bighappy  阅读(186)  评论(0)    收藏  举报
刷新页面返回顶部
博客园  ©  2004-2025
浙公网安备 33010602011771号 浙ICP备2021040463号-3