diff --git a/assets/images/github.png b/assets/images/github.png new file mode 100644 index 00000000..8b25551a Binary files /dev/null and b/assets/images/github.png differ diff --git a/assets/images/twitter.png b/assets/images/twitter.png new file mode 100644 index 00000000..040ca169 Binary files /dev/null and b/assets/images/twitter.png differ diff --git a/assets/images/youtube.png b/assets/images/youtube.png new file mode 100644 index 00000000..e9d99668 Binary files /dev/null and b/assets/images/youtube.png differ diff --git a/lib/theme.dart b/lib/theme.dart index 354276c7..6086d85d 100644 --- a/lib/theme.dart +++ b/lib/theme.dart @@ -8,6 +8,7 @@ final _themeService = locator(); bool isDark = _themeService.isDarkMode; var lightTheme = ThemeData.light().copyWith( + backgroundColor: const Color.fromARGB(255, 243, 243, 243), navigationBarTheme: NavigationBarThemeData( indicatorColor: const Color.fromRGBO(75, 129, 210, 0.20), backgroundColor: const Color(0xffCBDFFC), @@ -17,7 +18,6 @@ var lightTheme = ThemeData.light().copyWith( ), ), ), - backgroundColor: Colors.red, useMaterial3: true, textButtonTheme: TextButtonThemeData( style: ButtonStyle( @@ -41,6 +41,7 @@ var lightTheme = ThemeData.light().copyWith( ); var darkTheme = ThemeData.dark().copyWith( + backgroundColor: const Color(0xff1E1E1E), navigationBarTheme: NavigationBarThemeData( iconTheme: MaterialStateProperty.all(const IconThemeData( color: Colors.white, @@ -53,7 +54,6 @@ var darkTheme = ThemeData.dark().copyWith( ), ), ), - backgroundColor: Colors.red, useMaterial3: true, scaffoldBackgroundColor: const Color(0xff0A0D11), textButtonTheme: TextButtonThemeData( diff --git a/lib/ui/views/settings/settings_view.dart b/lib/ui/views/settings/settings_view.dart index b4684b3c..dc5dbc7e 100644 --- a/lib/ui/views/settings/settings_view.dart +++ b/lib/ui/views/settings/settings_view.dart @@ -7,6 +7,7 @@ import 'package:revanced_manager/ui/views/settings/settings_viewmodel.dart'; import 'package:revanced_manager/ui/widgets/settingsView/about_info_widget.dart'; import 'package:revanced_manager/ui/widgets/settingsView/custom_text_field.dart'; import 'package:revanced_manager/ui/widgets/settingsView/settings_switch_item.dart'; +import 'package:revanced_manager/ui/widgets/settingsView/social_media_cards.dart'; import 'package:stacked/stacked.dart'; import 'package:stacked_themes/stacked_themes.dart'; @@ -144,6 +145,7 @@ class SettingsView extends StatelessWidget { ), onTap: model.navigateToContributors, ), + const SocialMediaCards(), const AboutWidget(), ], ), diff --git a/lib/ui/widgets/settingsView/social_media_cards.dart b/lib/ui/widgets/settingsView/social_media_cards.dart new file mode 100644 index 00000000..53916545 --- /dev/null +++ b/lib/ui/widgets/settingsView/social_media_cards.dart @@ -0,0 +1,126 @@ +import 'package:flutter/material.dart'; +import 'package:url_launcher/url_launcher.dart'; + +class SocialMediaCards extends StatelessWidget { + const SocialMediaCards({Key? key}) : super(key: key); + + @override + Widget build(BuildContext context) { + return Card( + color: Theme.of(context).backgroundColor, + child: Column( + children: [ + ListTile( + contentPadding: + const EdgeInsets.symmetric(horizontal: 16).copyWith(top: 0), + leading: Padding( + padding: const EdgeInsets.all(8.0), + child: Image.asset( + 'assets/images/github.png', + height: 24, + width: 24, + color: Theme.of(context).iconTheme.color, + ), + ), + title: const Text('GitHub'), + subtitle: const Text('github.com/revanced'), + onTap: () => launchUrl( + Uri.parse('https://github.com/revanced'), + mode: LaunchMode.externalApplication, + ), + ), + ListTile( + contentPadding: + const EdgeInsets.symmetric(horizontal: 16).copyWith(top: 0), + leading: Padding( + padding: const EdgeInsets.all(8.0), + child: Icon( + Icons.discord, + color: Theme.of(context).iconTheme.color, + ), + ), + title: const Text('Discord'), + subtitle: const Text('discord.gg/revanced'), + onTap: () => launchUrl( + Uri.parse('https://discord.gg/3E2pTWR4Yd'), + mode: LaunchMode.externalApplication, + ), + ), + ListTile( + contentPadding: + const EdgeInsets.symmetric(horizontal: 16).copyWith(top: 0), + leading: Padding( + padding: const EdgeInsets.all(8.0), + child: Icon( + Icons.telegram, + color: Theme.of(context).iconTheme.color, + ), + ), + title: const Text('Telegram'), + subtitle: const Text('t.me/app_revanced'), + onTap: () => launchUrl( + Uri.parse('https://t.me/app_revanced'), + mode: LaunchMode.externalApplication, + ), + ), + ListTile( + contentPadding: + const EdgeInsets.symmetric(horizontal: 16).copyWith(top: 0), + leading: Padding( + padding: const EdgeInsets.all(8.0), + child: Icon( + Icons.reddit, + color: Theme.of(context).iconTheme.color, + ), + ), + title: const Text('Reddit'), + subtitle: const Text('r/revancedapp'), + onTap: () => launchUrl( + Uri.parse('https://reddit.com/r/revancedapp'), + mode: LaunchMode.externalApplication, + ), + ), + ListTile( + contentPadding: + const EdgeInsets.symmetric(horizontal: 16).copyWith(top: 0), + leading: Padding( + padding: const EdgeInsets.all(8.0), + child: Image.asset( + 'assets/images/twitter.png', + height: 24, + width: 24, + color: Theme.of(context).iconTheme.color, + ), + ), + title: const Text('Twitter'), + subtitle: const Text('@revancedapp'), + onTap: () => launchUrl( + Uri.parse('https://twitter.com/@revancedapp'), + mode: LaunchMode.externalApplication, + ), + ), + ListTile( + contentPadding: + const EdgeInsets.symmetric(horizontal: 16).copyWith(top: 0), + leading: Padding( + padding: const EdgeInsets.all(8.0), + child: Image.asset( + 'assets/images/youtube.png', + height: 24, + width: 24, + color: Theme.of(context).iconTheme.color, + ), + ), + title: const Text('YouTube'), + subtitle: const Text('youtube.com/revanced'), + onTap: () => launchUrl( + Uri.parse( + 'https://www.youtube.com/channel/UCLktAUh5Gza9zAJBStwxNdw'), + mode: LaunchMode.externalApplication, + ), + ), + ], + ), + ); + } +}