[英]Need to make design in react-native bottom navigator as below image
Something like this should achieve your desired result, just replace the div:before
block with the item at the top in your screenshot if it is an image.像这样的东西应该可以达到您想要的结果,只需将
div:before
块替换为屏幕截图顶部的项目(如果它是图像)。 If no image use div:before
changing the color is box-shadow
.如果没有图像使用
div:before
改变颜色是box-shadow
。
div {
position:relative;
width: 300px;
height: 80px;
background: #522d5b;
}
div:before {
content: "";
position:absolute;
top:-40px;
left:0;
height:40px;
width:300px;
border-bottom-left-radius: 25px;
border-bottom-right-radius: 25px;
box-shadow: 0 20px 0 0 #fff;
}
You need to use the below style and the image will be the same as per your requirement您需要使用以下样式,图像将与您的要求相同
Below is the code sample you can refer to.以下是您可以参考的代码示例。
image: {
borderBottomLeftRadius: 25,
borderTopLeftRadius: 25,
}
one more solution is there还有另一种解决方案
borderRadius:0,0,20,0;
Also, you can find more info in the view component docs .此外,您可以在视图组件文档中找到更多信息。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.