<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>css</title>
</head>
<body>
<style>
#a {
width: 150px;
height: 300px;
background: radial-gradient(circle at top left,
transparent 15px, #e6e4b7 0) top left,
radial-gradient(circle at top right,
transparent 15px, #e6e4b7 0) top right,
radial-gradient(circle at bottom right,
transparent 15px, #e6e4b7 0) bottom right,
radial-gradient(circle at bottom left,
transparent 15px, #e6e4b7 0) bottom left;
background-size: 50% 50%;
background-repeat: no-repeat;
padding: 20px 24px 22px 20px;
filter: drop-shadow(2px 2px 10px red);
}
#b {
display: block;
background: radial-gradient(circle at top left,
transparent 15px, red 0) top left,
radial-gradient(circle at top right,
transparent 15px, red 0) top right,
radial-gradient(circle at bottom right,
transparent 15px, red 0) bottom right,
radial-gradient(circle at bottom left,
transparent 15px, red 0) bottom left;
background-size: 50% 50%;
background-repeat: no-repeat;
width:100%;
height: 100%;
padding: 2px;
}
#b:before {
content: "";
width: 100%;
height: 100%;
display: block;
background: radial-gradient(circle at top left,
transparent 15px, #e6e4b7 0) top left,
radial-gradient(circle at top right,
transparent 15px, #e6e4b7 0) top right,
radial-gradient(circle at bottom right,
transparent 15px, #e6e4b7 0) bottom right,
radial-gradient(circle at bottom left,
transparent 15px, #e6e4b7 0) bottom left;
background-size: 50% 50%;
background-repeat: no-repeat;
}
</style> <div id="a">
<div id="b"></div>
</div>
</body>
</html>

内凹圆角的实现

1
2
3
4
5
6
background: radial-gradient(circle at top left, transparent 15px, #58a 0) top left,
            radial-gradient(circle at top right, transparent 15px, #58a 0) top right,
            radial-gradient(circle at bottom left, transparent 15px, #58a 0) bottom left,
            radial-gradient(circle at bottom right, transparent 15px, #58a 0) bottom right;
background-repeat: no-repeat;
background-size: 50% 50%;

css3凹角效果的更多相关文章

  1. Bounce.js – 快速创建漂亮的 CSS3 动画效果

    Bounce.js 是一个用于制作漂亮的 CSS3 关键帧动画的 JavaScript 库,使用其特有的方式生成的动画效果.只需添加一个组件,选择预设,然后你就可以得到一个短网址或者导出为 CSS 代 ...

  2. Hover.css:一组超实用的 CSS3 悬停效果和动画

    Hover.css 是一套基于 CSS3 的鼠标悬停效果和动画,这些可以非常轻松的被应用到按钮.LOGO 以及图片等元素.所有这些效果都是只需要单一的标签,必要的时候使用 before 和 after ...

  3. 10个实用的 CSS3 按钮效果制作教程

    人们往往喜欢那些有更多互动元素的网站,因此现在很多设计师专注于他们的 CSS3 技能.这是因为 CSS3 技能可以帮助他们在很大的程度上实现所需的吸引力.这里分享的10个优秀的 CSS3 按钮效果制作 ...

  4. 学习制作精美 CSS3 按钮效果的10个优秀教程

    由于互联网世界正在发生变化,人们往往喜欢那些有更多互动元素的网站,因此现在很多 Web 开发人员也在专注于提高他们的 CSS3 技能,因为 CSS3 技能可以帮助他们在很大的程度上实现所需的吸引力.这 ...

  5. Cool!15个创意的 CSS3 文本效果【下篇】

    这里文章收集了15个创意的 CSS3 文本效果,所有的都是精心挑选,这些可能会增加创意的火花到你的下一个项目.其中有些是用于特定用途,而另一些则适用于多种用途.如果你想要一个精彩而又充满色彩的文字效果 ...

  6. CSS3 动画效果带来的bug

    css3 动画效果比如transition:all 2s linear;这种用来计算及时的物体坐标的话会带来一定的问题 比如把一个DIV从A点移动到B点.JS为DIV.style.left=B; 但是 ...

  7. animate.css 一些常用的CSS3动画效果

    大家已经开始在项目中使用一些CSS3动画效果了吧,这让网站在高端浏览器上看起来很上流.animate.css是一个老外做的各种CSS3动画的合集,比较全,也很炫,大家可以参考学习一下. 项目主页:ht ...

  8. [HTML] CSS3 文本效果

    CSS3 文本效果 CSS3中包含几个新的文本特征. 在本章中您将了解以下文本属性: text-shadow word-wrap 浏览器支持

  9. css3 文本效果

    CSS3 文本效果   1 CSS3 文本阴影在 CSS3 中,text-shadow 可向文本应用阴影,能够规定水平阴影.垂直阴影.模糊距离,以及阴影的颜色.text-shadow: 5px 5px ...

随机推荐

  1. MySQL Binlog常用参数

    ====================================================================== MySQL Binlog常用参数 log_bin 设置此参 ...

  2. #define vs. const vs enum

    In one word, using const is better than define. enum is the best. There are lots of discussions. I p ...

  3. Unity3d插件开发与SDK对接实战 学习

    c++: 注意x86/x64,vs2015. #include "stdafx.h" extern "C" { int Add(int a, int b) { ...

  4. [转]C# FTP操作类

      转自 http://www.cnblogs.com/Liyuting/p/7084718.html using System; using System.Collections.Generic; ...

  5. Springboot配置文件映射

    添加类和配置文件的映射: 1.定义映射类 @Component @PropertySource("classpath:config/XX.properties") public c ...

  6. C++Builder XE7 中“匿名”方法实现

    class TMyProc : public TCppInterfacedObject<TThreadProcedure> { private: String p1; String p2; ...

  7. Linux Shell脚本中获取本机ip地址方法

    ifconfig -a|grep inet|grep -v 127.0.0.1|grep -v inet6|awk '{print $2}'|tr -d "addr:"​ 命令解释 ...

  8. 基于geohash6编码实现相邻4、9、16网格合并

    前面的两篇文章介绍了geohash的基本原理及c#代码相关实现,其中geohash 5位编码单个网格覆盖面积大约在24平方千米,6位编码单网格覆盖面大约在0.73平方千米, 相邻编码长度之间单网格覆盖 ...

  9. Vivado HLS初识---阅读《vivado design suite tutorial-high-level synthesis》(3)

    Vivado HLS初识---阅读<vivado design suite tutorial-high-level synthesis>(3) 优化lab1 1.创建工程,开启HLS 运行 ...

  10. TdxMemData 的Bug和使用

    aa.CopyFromDataSet(acdsBase);//克隆一个,与LoadFromDataSet区别,如果设置了Field,那么L只会导入设置的部分,而C则是全部复制过来 TdxMemData ...