mirror of
https://github.com/revanced/revanced-manager.git
synced 2025-06-12 04:37:37 +02:00
refactor: remove unimplemented features (#1061)
Co-authored-by: Ushie <ushiekane@gmail.com>
This commit is contained in:
@ -1,10 +1,8 @@
|
||||
import 'package:animations/animations.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_i18n/flutter_i18n.dart';
|
||||
import 'package:google_fonts/google_fonts.dart';
|
||||
import 'package:revanced_manager/app/app.locator.dart';
|
||||
import 'package:revanced_manager/ui/views/home/home_viewmodel.dart';
|
||||
import 'package:revanced_manager/ui/widgets/homeView/available_updates_card.dart';
|
||||
import 'package:revanced_manager/ui/widgets/homeView/installed_apps_card.dart';
|
||||
import 'package:revanced_manager/ui/widgets/homeView/latest_commit_card.dart';
|
||||
import 'package:revanced_manager/ui/widgets/shared/custom_sliver_app_bar.dart';
|
||||
@ -59,73 +57,8 @@ class HomeView extends StatelessWidget {
|
||||
style: Theme.of(context).textTheme.titleLarge,
|
||||
),
|
||||
),
|
||||
const SizedBox(height: 8),
|
||||
Row(
|
||||
children: <Widget>[
|
||||
ActionChip(
|
||||
avatar: const Icon(Icons.grid_view),
|
||||
label: I18nText('homeView.installed'),
|
||||
side: BorderSide(
|
||||
color: model.showUpdatableApps
|
||||
? Theme.of(context).colorScheme.outline
|
||||
: Theme.of(context)
|
||||
.colorScheme
|
||||
.secondaryContainer,
|
||||
width: model.showUpdatableApps ? 1 : 1,
|
||||
),
|
||||
backgroundColor: model.showUpdatableApps
|
||||
? Theme.of(context).colorScheme.background
|
||||
: Theme.of(context)
|
||||
.colorScheme
|
||||
.secondaryContainer,
|
||||
onPressed: () {
|
||||
model.toggleUpdatableApps(false);
|
||||
},
|
||||
),
|
||||
const SizedBox(width: 10),
|
||||
ActionChip(
|
||||
avatar: const Icon(Icons.update),
|
||||
label: I18nText('homeView.updatesAvailable'),
|
||||
side: BorderSide(
|
||||
color: !model.showUpdatableApps
|
||||
? Theme.of(context).colorScheme.outline
|
||||
: Theme.of(context)
|
||||
.colorScheme
|
||||
.secondaryContainer,
|
||||
width: !model.showUpdatableApps ? 1 : 1,
|
||||
),
|
||||
backgroundColor: !model.showUpdatableApps
|
||||
? Theme.of(context).colorScheme.background
|
||||
: Theme.of(context)
|
||||
.colorScheme
|
||||
.secondaryContainer,
|
||||
onPressed: () {
|
||||
model.toggleUpdatableApps(true);
|
||||
},
|
||||
),
|
||||
],
|
||||
),
|
||||
const SizedBox(height: 14),
|
||||
PageTransitionSwitcher(
|
||||
transitionBuilder:
|
||||
(child, primaryAnimation, secondaryAnimation) {
|
||||
return FadeThroughTransition(
|
||||
animation: primaryAnimation,
|
||||
secondaryAnimation: secondaryAnimation,
|
||||
fillColor: Colors.transparent,
|
||||
child: child,
|
||||
);
|
||||
},
|
||||
layoutBuilder: (entries) {
|
||||
return Stack(
|
||||
alignment: Alignment.topCenter,
|
||||
children: entries,
|
||||
);
|
||||
},
|
||||
child: model.showUpdatableApps
|
||||
? AvailableUpdatesCard()
|
||||
: InstalledAppsCard(),
|
||||
),
|
||||
const SizedBox(height: 10),
|
||||
InstalledAppsCard(),
|
||||
],
|
||||
),
|
||||
),
|
||||
|
Reference in New Issue
Block a user