Search code examples
androidangularnativescript

Android apps leaving black bottom bar on Pixel 4a


enter image description here I am not sure how to fix this black bar at the bottom of the screen on Google Pixel 4a (rounde corner at the bottom). On Huwaei phones that are not rounded app looks fine.

My android manifest files is below and have tried max.aspect as well but no effect.Tried changing the app background color to white still it shows black. I just want the whole screen to be white.

    <?xml version="1.0" encoding="utf-8"?>

<supports-screens
    android:smallScreens="true"
    android:normalScreens="true"
    android:largeScreens="true"
    android:xlargeScreens="true"/>

<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>

<application
    android:name="com.tns.NativeScriptApplication"
    android:allowBackup="true"
    android:icon="@mipmap/ic_launcher"
    android:label="@string/app_name"
    android:background="@android:color/white"

    android:theme="@style/Theme.MyApplication">
    <meta-data android:name="android.max_aspect" android:value="2.50" />
    <activity
        android:name="com.tns.NativeScriptActivity"
        android:label="@string/app_name"
        android:configChanges="keyboard|keyboardHidden|orientation|screenSize|smallestScreenSize|screenLayout|locale|uiMode"
        android:theme="@style/Theme.MyApplication">

        <meta-data android:name="SET_THEME_ON_LAUNCH" android:resource="@style/Theme.MyApplication" />
        
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>
    <activity android:name="com.tns.ErrorReportActivity"/> 
</application>

Solution

  • That black bar is used for gesture navigation, you can change the color used in bottom navigation with

        <item name="android:navigationBarColor">@android:color/white</item>
    

    Also you can enable/disable gesture navigation in settings and use the classing 2/3 button mode. Bottom nav can be manipulated similarly to the status bar, so you can make it transparent/manipulate it like the status bar, but you can never hide it completely(unless in full screen mode)