Comments (12)
There's a Chrome issue open to improve the process of changing the status bar color, without having to copy LauncherActivity here
from svgomg-twa.
Would you mind posting the question on StackOverflow: https://stackoverflow.com/questions/tagged/trusted-web-activity/
It makes it easier for other developers with the same issue to find the solution, and for other developers to help with answers too.
from svgomg-twa.
Oh i did: https://stackoverflow.com/questions/54659396/android-studio-change-statusbarcolor-of-webview
But it seems that not many peoples have knowledge about TWA stuff yet. Maybe to new thing? :) but i understand that this is the wrong place for questions.
from svgomg-twa.
Answered the question on StackOverflow. Closing the issue here.
from svgomg-twa.
Hi @BamiGorengo would you mind sharing a Gist of the changes you made to LauncherActivity.java - I've followed the stack question but still having issues such as:
Cannot resolve method 'showNoPackageToast(
Cannot resolve method 'promptForChromeUpdateIfNeeded
Cannot resolve method 'warmupIsRequired
launchAsTrustedWebActivity() in TrustedWebUtils cannot be applied to:
Expected Parameters:
Actual Arguments:
context:
Context
LauncherActivity.this
session:
android...customtabs.CustomTabsSession
intent (android...customtabs.CustomTabsIntent)
intent:
android...customtabs.CustomTabsIntent
url (android.net.Uri)
uri:
Uri
from svgomg-twa.
@a-haan I will write a article about this when im back home in 3 days. meanwhile you can take a look on my article where i explain some stuff: https://link.medium.com/9vVurMuhoU
there is also a link to stack overflow where you can read all you need to do the thing with the statusBar.
from svgomg-twa.
@BamiGorengo Thank you, interesting read! I've got mostly everything setup except for the status color bar, so looking forward to your guide 👍
from svgomg-twa.
@andreban good news! thanks for this!
Can you maybe share us also a description how to add a splash /loading screen that waits that the chrome instance is finish loaded before it fades out? I want to write an extended tutorial about this, but i have 0 idea how to start this.
from svgomg-twa.
@BamiGorengo this sample from CustomTabs helps with that. We're looking into how to make this easier using LauncherActivity too, so it may be worth waiting a bit too.
from svgomg-twa.
@BamiGorengo @andreban I've got a feeling the instructions you provided in the Stack question didn't work because my project was built by PWA2APK originally, I will build again from scratch and see if that works okay. I get odd issues atm that appear on my app such as a crash on startup if my default browser is Samsung or Firefox. Yet @BamiGorengo App doesn't have the same issues...
from svgomg-twa.
@andreban hmmm i cant find any code snippet there that seems to do any splash screen stuff... it make not maybe more sense to use the web manifest to automate the statusBar color and Splash screen? that make for me most sense...
from svgomg-twa.
@BamiGorengo @andreban rebuilt now all working as expected including the toolbar colour, no more crashes as you'd expect!
I can seem to find a similar way to change the navbar colour to dark instead of light mode though, which is a shame because my PWA is in darkmode
from svgomg-twa.
Related Issues (20)
- TWA top url bar not hiding HOT 2
- Unable to instantiate service androidx.browser.trusted.TrustedWebActivityService HOT 4
- how to use fcm push notification on TWA apk HOT 1
- Does TWA notification delegation handle sound also? HOT 9
- My TWA is crashing multiple times. HOT 7
- [Question] Adsense in PWA/TWA HOT 3
- Setting Notifications to true still asks for permission from user HOT 7
- Hide div in twa in-app browser HOT 1
- Running the TWA from a Chromebook just opens the URL in the browser and not a standalone window HOT 5
- TWA app can't run independently without running chrome browser first HOT 1
- Android TV app HOT 1
- open new a tab (url) inside of TWA by browser which is not inside of TWA HOT 1
- Update Android SDK studio to version 30 HOT 1
- Facebook Comments Plugin Not Working in The TWA HOT 1
- How to prevent app from going into background when a class 0 SMS (flash SMS) pops up thus preventing UPI verification.
- Android generating 404 errors on TWA website
- TWA asset ink is updated but address bar is visible HOT 4
- Android Browser Helper version HOT 2
- Multiple TWAs created for the same domain but google search only indexes one TWA HOT 1
- notifications only display when the phone is unlocked
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from svgomg-twa.