uniapp----003--配置tabbar

2022年7月28日 257点热度 0人点赞 0条评论

4、配置tabbar

4.1 配置tabbar

(1) 当设置 position top 时,将不会显示 icon

(2) tabBar 中的 list 是一个数组,只能配置最少2个、最多5tabtab 按数组的顺序排序。

 

图片

 

图片

 

图片

 

图片

 

 

图片

 

图片

 

图片

 

图片

 

图片

 

图片

 

图片

 

 

图片

 

 

图片

 

4.2  tabbar的其他属性配置:

"tabBar" : "color":"#A0522D",  tab 上的文字默认颜色(未选中的字体颜色)

"tabBar" : "selectedColor":"#B3EE3A",  tab 上的文字选中时的颜色(选中的字体颜色)

 

图片

"tabBar" : "backgroundColor":"#BA55D3",  tab 的背景色

 

图片

 

"tabBar" : "backgroundColor":"#FFFFFF",  tab 的背景色为白色时,上边框有边线:

 

图片

 

 

"tabBar" : "borderStyle":"white", tabbar 上边框的颜色,可选值 black/white

上边线设置为白色后,上边线看不到了:

 

图片

 

"tabBar" :  "position":"top", 可选值 bottomtop top 值仅微信小程序支持

 

图片

完整的代码:

图片

80380uniapp----003--配置tabbar

这个人很懒,什么都没留下

文章评论