Blogger Information
Blog 40
fans 3
comment 0
visits 48221
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
关于chrome浏览器设置了display:flex之后border-radius属性不生效的问题解决方法
MArtian
Original
1928 people have browsed it

在元素变成弹性盒子之后,父对象设置圆角后不会遮住子元素的块

p1.png

虽然圆角生效了,但是鼠标滑过标签后的:hover效果生效后,圆角并没有遮挡住块标记的指教

这本身是chrome浏览器的一个bug,我们要用一个图片来遮挡

{

 -webkit-mask-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAIAAACQd1PeAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAA5JREFUeNpiYGBgAAgwAAAEAAGbA+oJAAAAAElFTkSuQmCC); 
 overflow: hidden; 

}

添加以上属性

p3.png

问题解决。

Statement of this Website
The copyright of this blog article belongs to the blogger. Please specify the address when reprinting! If there is any infringement or violation of the law, please contact admin@php.cn Report processing!
All comments Speak rationally on civilized internet, please comply with News Comment Service Agreement
0 comments
Author's latest blog post