💄 Realm shortcut

This commit is contained in:
2024-05-07 23:38:12 +08:00
parent 3bcdc67285
commit a4f8c65aa5
5 changed files with 143 additions and 26 deletions

View File

@ -32,14 +32,16 @@ class RealmScreen extends StatelessWidget {
),
]
: [],
appBarLeading: SolianTheme.isLargeScreen(context)
? IconButton(
icon: const Icon(Icons.arrow_back),
onPressed: () {
realm.clearFocus();
},
)
: null,
appBarLeading: IconButton(
icon: const Icon(Icons.arrow_back),
onPressed: () {
if (SolianTheme.isLargeScreen(context)) {
realm.clearFocus();
} else if (SolianRouter.router.canPop()) {
SolianRouter.router.pop();
}
},
),
child: RealmWidget(
alias: alias,
),