-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ac1622f
commit 0119b27
Showing
56 changed files
with
1,488 additions
and
1,772 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -33,4 +33,4 @@ jobs: | |
with: | ||
allowUpdates: true | ||
artifacts: "releases/*-release.apk" | ||
tag: 1.0 | ||
tag: ${{ github.event.inputs.TAG }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,32 @@ | ||
# duel_links_meta | ||
# Duel links meta app | ||
|
||
A new Flutter project. | ||
## Futures | ||
|
||
## Getting Started | ||
- Tier List Page | ||
- Deck Type Detail Page | ||
- Top Deck page | ||
- Deck detail page | ||
- Ban list change page | ||
- Ban list cards page | ||
- Article list page | ||
- Pack set list page | ||
- Pack set detail page | ||
- Data local cache for fast viewing and reduce the api fetching | ||
|
||
This project is a starting point for a Flutter application. | ||
## Download 下载 | ||
|
||
A few resources to get you started if this is your first Flutter project: | ||
[从github下载](https://github.com/sukinosuki/duel-links-meta-flutter-app/releases) | ||
|
||
- [Lab: Write your first Flutter app](https://docs.flutter.dev/get-started/codelab) | ||
- [Cookbook: Useful Flutter samples](https://docs.flutter.dev/cookbook) | ||
## Stars | ||
|
||
For help getting started with Flutter development, view the | ||
[online documentation](https://docs.flutter.dev/), which offers tutorials, | ||
samples, guidance on mobile development, and a full API reference. | ||
If this project is helpful to you, please consider giving a star for support. | ||
|
||
如果本项目对你有帮助的话, 可以`star`支持一下. | ||
|
||
## Data source | ||
|
||
The app utilizes the following resources from [Duel Links Meta](https://www.duellinksmeta.com): | ||
|
||
- **APIs**: The app integrates with Duel Links Meta's APIs to fetch deck lists, card details, and other game-related data. | ||
- **Images**: Card images and other graphics used in the app are sourced directly from Duel Links Meta. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,186 @@ | ||
import 'package:duel_links_meta/hive/MyHive.dart'; | ||
import 'package:duel_links_meta/hive/db/DarkModeHiveDb.dart'; | ||
import 'package:duel_links_meta/pages/open_source_licenses/index.dart'; | ||
import 'package:duel_links_meta/store/AppStore.dart'; | ||
import 'package:flutter/material.dart'; | ||
import 'package:get/get.dart'; | ||
import 'package:package_info_plus/package_info_plus.dart'; | ||
import 'package:url_launcher/url_launcher.dart'; | ||
|
||
class SettingModalView extends StatefulWidget { | ||
const SettingModalView({super.key}); | ||
|
||
@override | ||
State<SettingModalView> createState() => _SettingModalViewState(); | ||
} | ||
|
||
class _SettingModalViewState extends State<SettingModalView> { | ||
AppStore appStore = Get.put(AppStore()); | ||
|
||
PackageInfo? get packageInfo => appStore.packageInfo; | ||
|
||
String repos = 'https://github.com/sukinosuki/duel-links-meta-flutter-app'; | ||
String duelLinksMetaUrl = 'https://www.duellinksmeta.com'; | ||
|
||
String githubHash = ''; | ||
|
||
void init() { | ||
githubHash = const String.fromEnvironment('GITHUB_HASH'); | ||
} | ||
|
||
@override | ||
void initState() { | ||
super.initState(); | ||
|
||
init(); | ||
} | ||
|
||
@override | ||
Widget build(BuildContext context) { | ||
return ClipRRect( | ||
borderRadius: const BorderRadius.only( | ||
topLeft: Radius.circular(24), | ||
topRight: Radius.circular(24), | ||
), | ||
child: Container( | ||
padding: const EdgeInsets.only(top: 30), | ||
color: Theme.of(context).colorScheme.onPrimary, | ||
child: SingleChildScrollView( | ||
child: Column( | ||
crossAxisAlignment: CrossAxisAlignment.start, | ||
children: [ | ||
const Padding( | ||
padding: EdgeInsets.symmetric(horizontal: 12), | ||
child: Text( | ||
'Setting', | ||
style: TextStyle(fontSize: 24), | ||
), | ||
), | ||
Container( | ||
padding: const EdgeInsets.symmetric(horizontal: 6), | ||
child: Row( | ||
mainAxisAlignment: MainAxisAlignment.spaceBetween, | ||
children: [ | ||
const Padding( | ||
padding: EdgeInsets.only(left: 6), | ||
child: Text('Theme mode'), | ||
), | ||
Row( | ||
children: [ | ||
IconButton( | ||
isSelected: !Get.isDarkMode, | ||
onPressed: () { | ||
Get.changeThemeMode(ThemeMode.light); | ||
DarkModeHiveDb().set(ThemeMode.light); | ||
}, | ||
|
||
icon: const Icon(Icons.sunny), | ||
), | ||
IconButton( | ||
isSelected: Get.isDarkMode, | ||
onPressed: () { | ||
Get.changeThemeMode(ThemeMode.dark); | ||
DarkModeHiveDb().set(ThemeMode.dark); | ||
}, | ||
icon: const Icon(Icons.nightlight_rounded), | ||
), | ||
], | ||
), | ||
], | ||
), | ||
), | ||
const Padding( | ||
padding: EdgeInsets.symmetric(vertical: 12, horizontal: 12), | ||
child: Text( | ||
'About', | ||
style: TextStyle(fontSize: 24), | ||
), | ||
), | ||
Container( | ||
height: 50, | ||
padding: const EdgeInsets.symmetric(horizontal: 12), | ||
child: Row( | ||
mainAxisAlignment: MainAxisAlignment.spaceBetween, | ||
children: [ | ||
const Text('App version'), | ||
Text(packageInfo?.version ?? ''), | ||
], | ||
), | ||
), | ||
Container( | ||
height: 50, | ||
padding: const EdgeInsets.symmetric(horizontal: 12), | ||
child: Row( | ||
mainAxisAlignment: MainAxisAlignment.spaceBetween, | ||
children: [ | ||
const Text('Commit ID'), | ||
Text(githubHash), | ||
], | ||
), | ||
), | ||
Material( | ||
color: Colors.transparent, | ||
child: InkWell( | ||
onTap: () { | ||
final uri = Uri.parse(repos); | ||
launchUrl(uri).ignore(); | ||
}, | ||
child: Container( | ||
height: 50, | ||
padding: const EdgeInsets.symmetric(horizontal: 12), | ||
child: Row( | ||
mainAxisAlignment: MainAxisAlignment.spaceBetween, | ||
children: [ | ||
const Text('Github'), | ||
Icon(Icons.arrow_forward, color: Theme.of(context).iconTheme.color?.withOpacity(0.6)), | ||
], | ||
), | ||
), | ||
), | ||
), | ||
Material( | ||
color: Colors.transparent, | ||
child: InkWell( | ||
onTap: () { | ||
Navigator.push(context, MaterialPageRoute<void>(builder: (context) => const OpenSourceLicensePage())); | ||
}, | ||
child: Container( | ||
height: 50, | ||
padding: const EdgeInsets.symmetric(horizontal: 12), | ||
child: Row( | ||
mainAxisAlignment: MainAxisAlignment.spaceBetween, | ||
children: [ | ||
const Text('Open source licenses'), | ||
Icon(Icons.arrow_forward, color: Theme.of(context).iconTheme.color?.withOpacity(0.6),), | ||
], | ||
), | ||
), | ||
), | ||
), | ||
Material( | ||
color: Colors.transparent, | ||
child: InkWell( | ||
onTap: () { | ||
final uri = Uri.parse(duelLinksMetaUrl); | ||
launchUrl(uri).ignore(); | ||
}, | ||
child: Container( | ||
height: 50, | ||
padding: const EdgeInsets.symmetric(horizontal: 12), | ||
child: Row( | ||
mainAxisAlignment: MainAxisAlignment.spaceBetween, | ||
children: [ | ||
const Text('Duel Link Meta'), | ||
Icon(Icons.arrow_forward, color: Theme.of(context).iconTheme.color?.withOpacity(0.6),), | ||
], | ||
), | ||
), | ||
), | ||
), | ||
], | ||
), | ||
), | ||
), | ||
); | ||
} | ||
} |
Oops, something went wrong.