We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
H5
浏览器版本: Chrome 62 使用框架: React
配置 app.config.ts
tabBar: { color: '#999999', selectedColor: '#FF5E00', backgroundColor: '#FFFFFF', borderStyle: 'white', list: [ { pagePath: 'pages/index/index', text: '首页', }, { pagePath: 'pages/mine/index', text: '我的', }, ], },
在app.ts调用
Taro.setTabBarStyle({ color: '#999999', backgroundColor: '#FFFFFF', borderStyle: 'white', });
调用正常执行
Uncaught (in promise) {errMsg: "setTabBarStyle:fail"}
Taro CLI 3.2.8 environment info: System: OS: Windows 10 Binaries: Node: 12.18.1 - C:\Program Files\nodejs\node.EXE Yarn: 1.22.4 - C:\Program Files (x86)\Yarn\bin\yarn.CMD npm: 6.14.5 - C:\Program Files\nodejs\npm.CMD
在文件webpack:///./node_modules/@tarojs/taro-h5/src/api/tabBar/index.js内设置断点
webpack:///./node_modules/@tarojs/taro-h5/src/api/tabBar/index.js
export function initTabBarApis (_App = {}) { tabConf = _App.state.__tabs; // 这一行设置断点 App = _App }
发现断点没被触发。
The text was updated successfully, but these errors were encountered:
由于 Taro H5 的组件是 Web Components,所以在 H5 端可以使用下面的方法实现你的需求。
const tabbar = document.getElementsByTagName('taro-tabbar')[0]; const updateConfig = {color: '#ff0000'}; // conf 是 taro tabbar 组件内部声明的 prop tabbar.conf = {...tabbar.conf, ...updateConfig};
等我有空了来尝试修修这个 bug ...
Sorry, something went wrong.
feat(api): 修复 TabBar 相关 api fix #9397 #8580 #8175
65c902c
3a07b19
Successfully merging a pull request may close this issue.
相关平台
H5
浏览器版本: Chrome 62
使用框架: React
复现步骤
配置 app.config.ts
在app.ts调用
期望结果
调用正常执行
实际结果
Uncaught (in promise) {errMsg: "setTabBarStyle:fail"}
环境信息
补充信息
在文件
webpack:///./node_modules/@tarojs/taro-h5/src/api/tabBar/index.js
内设置断点发现断点没被触发。
The text was updated successfully, but these errors were encountered: