import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:flutter_localizations/flutter_localizations.dart'; import 'package:hello_web3/hello/hello.dart'; import 'package:hello_web3/l10n/l10n.dart'; import 'package:smart_contract_repository/smart_contract_repository.dart'; class App extends StatelessWidget { const App({ required SmartContractRepository smartContractRepository, super.key, }) : _smartContractRepository = smartContractRepository; final SmartContractRepository _smartContractRepository; @override Widget build(BuildContext context) { return MultiRepositoryProvider( providers: [RepositoryProvider.value(value: _smartContractRepository)], child: const AppView(), ); } } class AppView extends StatelessWidget { const AppView({super.key}); @override Widget build(BuildContext context) { return MaterialApp( theme: ThemeData( appBarTheme: const AppBarTheme(color: Color(0xFF13B9FF)), colorScheme: ColorScheme.fromSwatch( accentColor: const Color(0xFF13B9FF), ), ), localizationsDelegates: const [ AppLocalizations.delegate, GlobalMaterialLocalizations.delegate, ], supportedLocales: AppLocalizations.supportedLocales, home: const HelloPage(), ); } }
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter