eltos / SimpleDialogFragments

An Android library to create dialogs with ease and handle user interaction reliably, using fragments and material design.
Apache License 2.0
119 stars 17 forks source link

Fullscreen dialog #89

Closed eltos closed 11 months ago

eltos commented 11 months ago

This PR introduces fullscreen dialogs as discussed in #87

A basic dialog

SimpleFormDialog.buildLogin("user", "password")
        .msg("Please login to continue")
        .show(this, "login_dialog_tag");

can be set to fullscreen by adding a single line:

SimpleFormDialog.buildLogin("user", "password")
        .msg("Please login to continue")
        .fullscreen() // <-- add this
        .show(this, "login_dialog_tag");

The primary use case are dialogs with a lot of content, or those that require keyboard input. In these cases, a basic dialog can quickly become confusing. This is especially true for Material 3 themes which have a lot of blank space around the dialogs:

Basic dialog Fullscreen dialog
grafik grafik
grafik grafik

closes #87