【Css】css实现四角边框:


一、效果:

在这里插入图片描述

二、实现:

background:
          linear-gradient(to top, #26aad1, #26aad1) left top no-repeat, //上左
          linear-gradient(to right, #26aad1, #26aad1) left top no-repeat, //左上
          linear-gradient(to left, #26aad1, #26aad1) right top no-repeat, //上右
          linear-gradient(to bottom, #26aad1, #26aad1) right top no-repeat, //上右
          linear-gradient(to left, #26aad1, #26aad1) left bottom no-repeat, //下左
          linear-gradient(to bottom, #26aad1, #26aad1) left bottom no-repeat, //左下
          linear-gradient(to top, #26aad1, #26aad1) right bottom no-repeat, //下右
          linear-gradient(to left, #26aad1, #26aad1) right bottom no-repeat; //右下
background-size: 2px 10px, 10px 2px, 2px 10px, 10px 2px;

猜你喜欢

转载自blog.csdn.net/weixin_53791978/article/details/130287264