css在chrome(linux和windows)中不起作用

我有这个代码
<style type="text/css">
div {
margin: 100px auto;
width: 0px;
height: 0px;
border-right: 30px solid transparent;
border-top: 30px solid red;
border-left: 30px solid red;
border-bottom: 30px solid transparent;
border-top-left-radius: 30px;
border-top-right-radius: 30px;
border-bottom-left-radius: 30px;
border-bottom-right-radius: 30px;
position: relative;
}
</style>
<div></div>

产生:

在Firefox中,

但在chrome(linux和windows – 没试过mac)我什么都没看到?

解决方法

我相信它实际上是某种错误.如果您将高度和宽度更改为1px,它对我有用.不幸的是,这会留下一点白点,但可以通过将背景更改为红色并将背景剪辑更改为内容来修复此问题.

JSFiddle example.

相关文章

Css3如何实现鼠标移上变长特效?(图文+视频)
css3怎么实现鼠标悬停图片时缓慢变大效果?(图文+视频)
jquery如何实现点击网页回到顶部效果?(图文+视频)
css3边框阴影效果怎么做?(图文+视频)
css怎么实现圆角边框和圆形效果?(图文+视频教程)
Css3如何实现旋转移动动画特效