[英]How do I change the background color from the top of my ionic application when I reduce it?
此查詢的可能解決方案可能很棘手,因為它還取決於您在手機上使用的啟動器的樣式您可以嘗試以下解決方案:-
解決方案 1: - 在 app.component.ts 中設置應用加載時的狀態欄顏色
initializeApp() {
this.platform.ready().then(() => {
this.statusBar.styleDefault();
this.statusBar.backgroundColorByHexString('#ffffff');// change the status bar color of the app so when minimize it it keeps the color u mentioned
//rest of ur calls
});
}
解決方案 2:- 通常最小化 window 采用已減少應用程序的頁面的 header 的顏色
<ion-header>
<ion-toolbar color="primary"> <!--u can use any color or change ur color in variable.css-->
<ion-title>Login</ion-title>
</ion-toolbar>
</ion-header>
讓我知道這是否有幫助
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.