在main.js中进行配置
/* 底部导航条 */
"tabBar": {
/* 未选中时颜色 */
"color": "#333",
/* 选中时颜色 */
"selectedColor": "#015FF9",
"list": [
{
/* 导航文字 */
"text": "首页",
/* 导航路径 */
"pagePath": "pages/index/index",
/* 未选中状态下图片样式 */
"iconPath": "static/images/tabbar/home.png",
/* 选中状态下图片样式 */
"selectedIconPath": "static/images/tabbar/home-h.png"
},
{
"text": "列表",
"pagePath": "pages/list/list",
"iconPath": "static/images/tabbar/list.png",
"selectedIconPath": "static/images/tabbar/list-h.png"
},
{
"text": "我们",
"pagePath": "pages/about/about",
"iconPath": "static/images/tabbar/about.png",
"selectedIconPath": "static/images/tabbar/about-h.png"
}
]
}
效果展示