Solian/lib/widgets/wrapper.dart

19 lines
466 B
Dart
Raw Normal View History

2024-04-12 16:38:20 +00:00
import 'package:flutter/material.dart';
import 'package:solian/widgets/navigation_drawer.dart';
class LayoutWrapper extends StatelessWidget {
final Widget? child;
final String title;
2024-04-12 16:38:20 +00:00
const LayoutWrapper({super.key, this.child, required this.title});
2024-04-12 16:38:20 +00:00
@override
Widget build(BuildContext context) {
return Scaffold(
drawer: const SolianNavigationDrawer(),
appBar: AppBar(title: Text(title)),
2024-04-13 11:47:31 +00:00
body: child ?? Container(),
2024-04-12 16:38:20 +00:00
);
}
}