mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2024-12-25 12:59:24 +00:00
46 lines
1.2 KiB
Dart
46 lines
1.2 KiB
Dart
import 'package:flutter/material.dart';
|
|
import 'package:stackwallet/utilities/theme/stack_colors.dart';
|
|
|
|
class DesktopDialog extends StatelessWidget {
|
|
const DesktopDialog({
|
|
Key? key,
|
|
this.child,
|
|
this.maxWidth = 641,
|
|
this.maxHeight = 474,
|
|
}) : super(key: key);
|
|
|
|
final Widget? child;
|
|
final double maxWidth;
|
|
final double? maxHeight;
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return Column(
|
|
mainAxisAlignment: MainAxisAlignment.center,
|
|
crossAxisAlignment: CrossAxisAlignment.center,
|
|
children: [
|
|
ConstrainedBox(
|
|
constraints: BoxConstraints(
|
|
maxWidth: maxWidth,
|
|
maxHeight: maxHeight ?? MediaQuery.of(context).size.height - 64,
|
|
),
|
|
child: Material(
|
|
color: Colors.transparent,
|
|
borderRadius: BorderRadius.circular(
|
|
20,
|
|
),
|
|
child: Container(
|
|
decoration: BoxDecoration(
|
|
color: Theme.of(context).extension<StackColors>()!.popupBG,
|
|
borderRadius: BorderRadius.circular(
|
|
20,
|
|
),
|
|
),
|
|
child: child,
|
|
),
|
|
),
|
|
),
|
|
],
|
|
);
|
|
}
|
|
}
|