Features: - Beacon scanner service for detecting nearby beacons - Beacon cache for offline-first beacon resolution - Preload cache for instant menu display - Business selector screen for multi-location support - Rescan button widget for quick beacon refresh - Sign-in dialog for guest checkout flow - Task type model for server tasks Improvements: - Enhanced menu browsing with category filtering - Improved cart view with better modifier display - Order history with detailed order tracking - Chat screen improvements - Better error handling in API service Fixes: - CashApp payment return crash fix - Modifier nesting issues resolved - Auto-expand modifier groups Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
40 lines
1.2 KiB
Dart
40 lines
1.2 KiB
Dart
import "package:flutter/material.dart";
|
|
import "package:flutter_stripe/flutter_stripe.dart";
|
|
import "package:provider/provider.dart";
|
|
|
|
import "app/app_router.dart" show AppRoutes;
|
|
import "app/app_state.dart" show AppState;
|
|
|
|
/// Global key for showing snackbars from anywhere in the app
|
|
final GlobalKey<ScaffoldMessengerState> rootScaffoldMessengerKey =
|
|
GlobalKey<ScaffoldMessengerState>();
|
|
|
|
void main() {
|
|
WidgetsFlutterBinding.ensureInitialized();
|
|
|
|
// Initialize Stripe with live publishable key (must match backend mode)
|
|
// Backend is in live mode - see api/config/stripe.cfm
|
|
Stripe.publishableKey = 'pk_live_Wqj4yGmtTghVJu7oufnWmU5H';
|
|
|
|
runApp(const PayfritApp());
|
|
}
|
|
|
|
class PayfritApp extends StatelessWidget {
|
|
const PayfritApp({super.key});
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return MultiProvider(
|
|
providers: [
|
|
ChangeNotifierProvider<AppState>(create: (_) => AppState()),
|
|
],
|
|
child: MaterialApp(
|
|
scaffoldMessengerKey: rootScaffoldMessengerKey,
|
|
debugShowCheckedModeBanner: false,
|
|
title: "Payfrit",
|
|
initialRoute: AppRoutes.splash,
|
|
routes: AppRoutes.routes,
|
|
),
|
|
);
|
|
}
|
|
}
|