2022-08-06 14:13:28 +02:00
|
|
|
import 'package:flutter/material.dart';
|
2022-08-07 01:37:12 +02:00
|
|
|
import 'package:flutter_i18n/flutter_i18n.dart';
|
2022-08-06 14:13:28 +02:00
|
|
|
import 'package:google_fonts/google_fonts.dart';
|
2022-08-06 23:35:35 +02:00
|
|
|
import 'package:revanced_manager/ui/widgets/app_selector_card.dart';
|
|
|
|
import 'package:revanced_manager/ui/widgets/patch_selector_card.dart';
|
2022-08-06 14:13:28 +02:00
|
|
|
import 'package:stacked/stacked.dart';
|
|
|
|
|
|
|
|
import 'patcher_viewmodel.dart';
|
|
|
|
|
|
|
|
class PatcherView extends StatelessWidget {
|
|
|
|
const PatcherView({Key? key}) : super(key: key);
|
|
|
|
|
|
|
|
@override
|
|
|
|
Widget build(BuildContext context) {
|
|
|
|
return ViewModelBuilder.reactive(
|
|
|
|
builder: (context, PatcherViewModel model, child) => Scaffold(
|
|
|
|
floatingActionButton: FloatingActionButton(
|
|
|
|
onPressed: () {},
|
|
|
|
child: const Icon(
|
|
|
|
Icons.build,
|
|
|
|
color: Colors.white,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
body: SafeArea(
|
|
|
|
child: Padding(
|
2022-08-07 02:13:27 +02:00
|
|
|
padding: const EdgeInsets.all(12.0),
|
2022-08-06 14:13:28 +02:00
|
|
|
child: Column(
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
children: [
|
|
|
|
const SizedBox(height: 12),
|
2022-08-07 01:37:12 +02:00
|
|
|
I18nText(
|
|
|
|
'patcherView.widgetTitle',
|
|
|
|
child: Text(
|
|
|
|
'',
|
|
|
|
style: GoogleFonts.inter(
|
|
|
|
fontSize: 28,
|
|
|
|
fontWeight: FontWeight.w500,
|
|
|
|
),
|
2022-08-06 14:13:28 +02:00
|
|
|
),
|
|
|
|
),
|
|
|
|
const SizedBox(height: 23),
|
|
|
|
AppSelectorCard(
|
|
|
|
onPressed: model.navigateToAppSelector,
|
|
|
|
),
|
|
|
|
const SizedBox(height: 16),
|
2022-08-07 21:15:52 +02:00
|
|
|
PatchSelectorCard(
|
|
|
|
onPressed: model.navigateToPatchesSelector,
|
|
|
|
),
|
2022-08-06 14:13:28 +02:00
|
|
|
],
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
viewModelBuilder: () => PatcherViewModel(),
|
|
|
|
);
|
|
|
|
}
|
|
|
|
}
|