Android: showTitle and toolbarColor don't work
hettiger opened this issue ยท 10 comments
The options showTitle
and toolbarColor
have no effect on Android but at least toolbarColor
works fine on iOS. (showTitle
is Android only)
I added following code at the top of my app/app.module.ts
file.
(It's an Angular app.)
import { init } from 'nativescript-advanced-webview';
init();
I can reproduce it on a real device and on an emulator.
The emulator is a Genymotion Google Pixel running Android 7.1.0.
The real device is a Google Pixel 2 running Android 8.1.0
"nativescript": {
"tns-ios": {
"version": "3.4.1"
},
"tns-android": {
"version": "3.4.2"
}
},
"dependencies": {
"@angular/animations": "~5.0.0",
"@angular/common": "~5.0.0",
"@angular/compiler": "~5.0.0",
"@angular/core": "~5.0.0",
"@angular/forms": "~5.0.0",
"@angular/http": "~5.0.0",
"@angular/platform-browser": "~5.0.0",
"@angular/platform-browser-dynamic": "~5.0.0",
"@angular/router": "~5.0.0",
"lodash": "^4.17.4",
"nativescript-advanced-webview": "^2.0.2",
"nativescript-angular": "^5.0.0",
"nativescript-carousel": "^3.1.1",
"nativescript-dom": "^2.0.0",
"nativescript-feedback": "^1.1.0",
"nativescript-geolocation": "^4.2.0",
"nativescript-google-maps-sdk": "^2.4.3",
"nativescript-iqkeyboardmanager": "^1.1.0",
"nativescript-loading-indicator": "^2.4.0",
"nativescript-plugin-firebase": "^5.1.7",
"nativescript-plugin-regions": "^1.0.1",
"nativescript-pulltorefresh": "^2.1.0",
"nativescript-ripple": "^2.0.0",
"nativescript-social-share": "^1.5.0",
"nativescript-theme-core": "1.0.4",
"nativescript-ui-sidedrawer": "^3.5.0",
"nativescript-webview-interface": "^1.4.2",
"reflect-metadata": "0.1.10",
"rxjs": "^5.5.0",
"sanitizer": "^0.1.3",
"tns-core-modules": "^3.4.1",
"zone.js": "^0.8.4"
},
"devDependencies": {
"@angular/compiler-cli": "~5.0.0",
"@ngtools/webpack": "~1.8.2",
"@types/lodash": "^4.14.85",
"babel-traverse": "6.25.0",
"babel-types": "6.25.0",
"babylon": "6.17.4",
"copy-webpack-plugin": "~4.0.1",
"css-loader": "~0.28.7",
"extract-text-webpack-plugin": "~3.0.0",
"lazy": "1.0.11",
"nativescript-css-loader": "~0.26.0",
"nativescript-dev-sass": "1.3.2",
"nativescript-dev-typescript": "^0.6.0",
"nativescript-dev-webpack": "^0.9.0",
"nativescript-sass-variables-to-typescript": "file:plugins/nativescript-sass-variables-to-typescript",
"nativescript-worker-loader": "~0.8.1",
"node-sass": "^4.5.3",
"raw-loader": "~0.5.1",
"resolve-url-loader": "~2.1.0",
"sass-loader": "~6.0.6",
"tns-platform-declarations": "^3.4.0",
"typescript": "~2.4.2",
"webpack": "~3.8.1",
"webpack-bundle-analyzer": "^2.8.2",
"webpack-sources": "~1.0.1"
},
facing the same problem here.
@triniwiz - I actually just noticed this running master in the demo app. I haven't looked through the native lib yet but just want to mark this as confirmed.
Ok will check it out
Confirming that this bug exists!
@triniwiz @bradmartin any updates on this ?
@hettiger @VladsGG
As a temp workaround you can use this https://www.npmjs.com/package/nativescript-awesome-webview
I just published so that I can get custom title bar colors on Android.
No update, I might have time for it next week but no promises. The custom lib currently used should just be extending CustomTabs so it should be fairly trivial to get in and fix though ๐ - hopefully ๐
Any updates please ? :)
Any updates for the showTitle and ToolbarColor? I have tried awesome-webview and it doesnt work for me.
fixed with version 4.0.0 which is NS6 (androidX) compatible