CSS阴影优化气泡框样式

xml 复制代码
<body>
<div class="pop">气泡框</div>
</body>
css 复制代码
body{
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100%
}
.pop{
  display: flex;
  justify-content: center;
  align-items: center;
  background: #409eff;
  width: 150px;
  height: 70px;
  position: relative;
  border-radius: 5px;
  color: #fff;
  /** box-shadow: 0 0 10px #000;   换成filter*/
  filter: drop-shadow(0 0 10px #000) 
 /** filter表示滤镜  drop-shadow表示阴影滤镜 */
}
.pop::before{
  content: '';
  background: #409eff;
  position: absolute;
  width: 20px;
  height: 20px;
  transform: rotate(45deg);
  left: -10px;
  top: 50%;
  margin-top: -10px;
}
相关推荐
yanchGod18 小时前
CSS page-break-before 属性详解:控制打印分页的艺术
前端·javascript·css·html·css3·html5
dsyyyyy110118 小时前
CSS盒子模型
前端·css·css3
DFT计算杂谈1 天前
wannier90 参数详解大全
java·前端·css·html·css3
之歆2 天前
DAY13_CSS3进阶完全指南 —— 背景、边框、文本、渐变、滤镜与 Web 字体(下)
前端·css·css3
剑神一笑2 天前
CSS 阴影生成器:从单层到多层叠加的艺术
前端·css·css3
之歆2 天前
DAY12_CSS3选择器全攻略 + 盒子新特性完全指南(下)
前端·javascript·css3
龙猫里的小梅啊2 天前
CSS(八)CSS显示模式display属性
前端·css·css3
之歆2 天前
DAY12_CSS3选择器全攻略 + 盒子新特性完全指南(上)
前端·css·css3
之歆2 天前
DAY13_CSS3进阶完全指南 —— 背景、边框、文本、渐变、滤镜与 Web 字体(上)
前端·c#·css3
We་ct3 天前
吃透现代CSS全技术体系
前端·css·css3·sass·postcss·预处理器