material-components / material-components/material-components-android
[NavigationView] strange rectangle appears when window overlaps with display cutout in edge-to-edge mode
Dieses Issue hat noch niemand übernommen.
- Vorherrschende Sprache
- Java
- Sterne
- 17.4k
- Forks
- 3.2k
- PR-Merge-Kennzahlen
- Keine gemergten PRs in 30 T.
Beschreibung
Description: The strange rectangle appears when the window overlaps with the display cutout in edge-to-edge mode.
Test11
(#3983 or #4576) Catalog app
Expected behavior: The strange rectangle doesn't appear when the window overlaps with the display cutout in edge-to-edge mode.
Test11
(#3983 or #4576) Catalog app
Source code:
<androidx.drawerlayout.widget.DrawerLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/drawerLayout"
android:layout_width="match_parent"
android:layout_height="match_parent">
<androidx.coordinatorlayout.widget.CoordinatorLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<com.google.android.material.appbar.AppBarLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:fitsSystemWindows="true">
<com.google.android.material.appbar.MaterialToolbar
android:id="@+id/appBar"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
</com.google.android.material.appbar.AppBarLayout>
</androidx.coordinatorlayout.widget.CoordinatorLayout>
<com.google.android.material.navigation.NavigationView
android:layout_width="220dp"
android:layout_height="match_parent"
android:layout_gravity="start"
app:menu="@menu/main" />
</androidx.drawerlayout.widget.DrawerLayout>
<resources>
<style name="Theme.App" parent="Theme.Material3.DynamicColors.DayNight.NoActionBar">
<item name="android:windowLayoutInDisplayCutoutMode">always</item>
</style>
</resources>
Minimal sample app repro: Test11.zip
Android API version: 35
Material Library version: 1.13.0-alpha10
Device: Emulator 35.3.11
Beitragsleitfaden
Erste Schritte
- Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
- Forke das Repository und arbeite in einem Branch.
- Öffne einen Pull Request, der die Issue-Nummer nennt.
Rechercherichtung
Beginne mit dem minimalen Beispiel Test11.zip und reproduziere das Rechteck auf dem API 35-Emulator unter Verwendung von Material Library 1.13.0-alpha10. Untersuche die Konfiguration von DrawerLayout, CoordinatorLayout, AppBarLayout, MaterialToolbar und NavigationView zusammen mit den Einstellungen für edge-to-edge und display-cutout. Als erledigt gilt die Aufgabe, wenn das Rechteck nicht mehr erscheint, sobald das Fenster den display-cutout überlappt.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- android
- Bereich
- mobile
- Issue-Typ
- Bug
- Schwierigkeit
- 4/5
- Geschätzter Aufwand
- 3-5 Tage
- Aktivitätsstatus
- Veraltet
- Klarheit
- Größtenteils klar
- Anfängerfreundlichkeit
- 35/100