mirror of
https://github.com/wgh136/pixes.git
synced 2025-09-27 12:57:24 +00:00
improve mobile ui
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import 'dart:async';
|
||||
|
||||
import 'package:fluent_ui/fluent_ui.dart';
|
||||
import 'package:pixes/components/md.dart';
|
||||
|
||||
void showToast(BuildContext context, {required String message, IconData? icon}) {
|
||||
var newEntry = OverlayEntry(
|
||||
@@ -27,7 +28,7 @@ class ToastOverlay extends StatelessWidget {
|
||||
child: Align(
|
||||
alignment: Alignment.bottomCenter,
|
||||
child: PhysicalModel(
|
||||
color: Colors.white,
|
||||
color: ColorScheme.of(context).surface,
|
||||
borderRadius: BorderRadius.circular(4),
|
||||
elevation: 1,
|
||||
child: Container(
|
||||
@@ -42,8 +43,11 @@ class ToastOverlay extends StatelessWidget {
|
||||
),
|
||||
Text(
|
||||
message,
|
||||
style: const TextStyle(
|
||||
fontSize: 16, fontWeight: FontWeight.w500),
|
||||
style: TextStyle(
|
||||
fontSize: 16,
|
||||
fontWeight: FontWeight.w500,
|
||||
color: ColorScheme.of(context).onSurface
|
||||
),
|
||||
maxLines: 3,
|
||||
),
|
||||
],
|
||||
|
@@ -307,7 +307,7 @@ class SideBarRoute<T> extends PopupRoute<T> {
|
||||
final Widget child;
|
||||
|
||||
@override
|
||||
Color? get barrierColor => const Color.fromARGB(64, 205, 205, 205);
|
||||
Color? get barrierColor => Colors.transparent;
|
||||
|
||||
@override
|
||||
bool get barrierDismissible => true;
|
||||
@@ -331,7 +331,8 @@ class SideBarRoute<T> extends PopupRoute<T> {
|
||||
color: FluentTheme.of(context).micaBackgroundColor.withOpacity(0.98),
|
||||
borderRadius: const BorderRadius.only(topLeft: Radius.circular(4), bottomLeft: Radius.circular(4))
|
||||
),
|
||||
constraints: const BoxConstraints(maxWidth: _kSideBarWidth),
|
||||
constraints: BoxConstraints(maxWidth: min(_kSideBarWidth,
|
||||
MediaQuery.of(context).size.width)),
|
||||
width: double.infinity,
|
||||
child: child,
|
||||
),
|
||||
|
Reference in New Issue
Block a user