softplayer-web/lib/helpers/page_wrapper.dart

29 lines
639 B
Dart

import 'dart:html';
import 'package:flutter/material.dart';
import 'package:softplayer_web/api/grpc/accounts.dart';
import 'package:softplayer_web/components/menubar.dart';
class PageWrapper extends StatelessWidget {
final Widget child;
final MenuPanel appBar;
const PageWrapper(
{super.key,
required this.child,
required this.appBar,
required this.accountsGrpc});
final AccountsGrpc accountsGrpc;
bool isSignedIn() {
return window.localStorage.containsKey("token");
}
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: appBar,
body: child,
);
}
}