diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..8279dd0 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,12 @@ +# Changelog +All notable changes to this project will be documented in this file. + +## [0.0.1] - 2022-04-17 +### Added +- This CHANGELOG file to hopefully serve as an evolving example of a + standardized open source project CHANGELOG. +- PRE production +- DATABASE LOCAL tos tore the links and CRUD operations +- ABOUT PAGE with all the info about the app + +[0.0.1]: https://github.com/olivierlacan/keep-a-changelog/releases/tag/v0.0.1 diff --git a/assets/icon.png b/assets/icon.png new file mode 100644 index 0000000..0f72661 Binary files /dev/null and b/assets/icon.png differ diff --git a/lib/main.dart b/lib/main.dart index b8926db..0a43ca4 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -1,3 +1,5 @@ +import 'package:about/about.dart'; +import 'package:flutter/cupertino.dart'; import 'package:flutter/foundation.dart'; import 'package:flutter/material.dart'; import 'package:sqflite_common/sqlite_api.dart'; @@ -5,6 +7,7 @@ import 'package:sqflite_common_ffi/sqflite_ffi.dart'; import 'package:shared_preferences/shared_preferences.dart'; import 'package:url_launcher/url_launcher.dart'; import 'models/link.dart'; +import 'package:package_info_plus/package_info_plus.dart'; const String kDBPath = 'db'; const String kDBConfigured = 'db_configured'; @@ -12,7 +15,10 @@ const String kDBConfigured = 'db_configured'; const int kDBVersion = 1; void main() { + WidgetsFlutterBinding.ensureInitialized(); + sqfliteFfiInit(); + runApp(const MyApp()); } @@ -23,8 +29,9 @@ class MyApp extends StatelessWidget { @override Widget build(BuildContext context) { return MaterialApp( + debugShowCheckedModeBanner: false, theme: ThemeData( - primarySwatch: Colors.blue, + primarySwatch: Colors.pink, ), home: const MyHomePage(), ); @@ -142,6 +149,40 @@ class _MyHomePageState extends State { Widget build(BuildContext context) { return Scaffold( appBar: AppBar( + leading: IconButton( + onPressed: () async { + PackageInfo packageInfo = await PackageInfo.fromPlatform(); + + showAboutPage( + context: context, + values: { + 'version': packageInfo.version, + 'year': DateTime.now().year.toString(), + }, + applicationLegalese: + 'Copyright © Riccardo Rettore | Simone Porcari | Francesco Vezzani, {{ year }}', + applicationDescription: const Text( + 'Applicazione per la gestione dei link delle videochiamate.'), + children: const [ + MarkdownPageListTile( + icon: Icon(Icons.list), + title: Text('Changelog'), + filename: 'CHANGELOG.md', + ), + LicensesPageListTile( + icon: Icon(Icons.favorite), + ), + ], + applicationIcon: const SizedBox( + width: 100, + height: 100, + child: Image( + image: AssetImage('assets/icon.png'), + ), + ), + ); + }, + icon: const Icon(CupertinoIcons.infinite)), title: const Text('Link Management System'), ), body: Center( diff --git a/macos/Flutter/GeneratedPluginRegistrant.swift b/macos/Flutter/GeneratedPluginRegistrant.swift index 8ad28b4..71afab0 100644 --- a/macos/Flutter/GeneratedPluginRegistrant.swift +++ b/macos/Flutter/GeneratedPluginRegistrant.swift @@ -5,10 +5,12 @@ import FlutterMacOS import Foundation +import package_info_plus_macos import shared_preferences_macos import url_launcher_macos func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) { + FLTPackageInfoPlusPlugin.register(with: registry.registrar(forPlugin: "FLTPackageInfoPlusPlugin")) SharedPreferencesPlugin.register(with: registry.registrar(forPlugin: "SharedPreferencesPlugin")) UrlLauncherPlugin.register(with: registry.registrar(forPlugin: "UrlLauncherPlugin")) } diff --git a/macos/Podfile.lock b/macos/Podfile.lock index 291d12f..c9ea81e 100644 --- a/macos/Podfile.lock +++ b/macos/Podfile.lock @@ -1,5 +1,7 @@ PODS: - FlutterMacOS (1.0.0) + - package_info_plus_macos (0.0.1): + - FlutterMacOS - shared_preferences_macos (0.0.1): - FlutterMacOS - url_launcher_macos (0.0.1): @@ -7,12 +9,15 @@ PODS: DEPENDENCIES: - FlutterMacOS (from `Flutter/ephemeral`) + - package_info_plus_macos (from `Flutter/ephemeral/.symlinks/plugins/package_info_plus_macos/macos`) - shared_preferences_macos (from `Flutter/ephemeral/.symlinks/plugins/shared_preferences_macos/macos`) - url_launcher_macos (from `Flutter/ephemeral/.symlinks/plugins/url_launcher_macos/macos`) EXTERNAL SOURCES: FlutterMacOS: :path: Flutter/ephemeral + package_info_plus_macos: + :path: Flutter/ephemeral/.symlinks/plugins/package_info_plus_macos/macos shared_preferences_macos: :path: Flutter/ephemeral/.symlinks/plugins/shared_preferences_macos/macos url_launcher_macos: @@ -20,9 +25,10 @@ EXTERNAL SOURCES: SPEC CHECKSUMS: FlutterMacOS: 57701585bf7de1b3fc2bb61f6378d73bbdea8424 + package_info_plus_macos: f010621b07802a241d96d01876d6705f15e77c1c shared_preferences_macos: a64dc611287ed6cbe28fd1297898db1336975727 url_launcher_macos: 597e05b8e514239626bcf4a850fcf9ef5c856ec3 PODFILE CHECKSUM: 6eac6b3292e5142cfc23bdeb71848a40ec51c14c -COCOAPODS: 1.11.2 +COCOAPODS: 1.11.3 diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/1024.png b/macos/Runner/Assets.xcassets/AppIcon.appiconset/1024.png new file mode 100644 index 0000000..a3a2a7c Binary files /dev/null and b/macos/Runner/Assets.xcassets/AppIcon.appiconset/1024.png differ diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/128.png b/macos/Runner/Assets.xcassets/AppIcon.appiconset/128.png new file mode 100644 index 0000000..7bb8565 Binary files /dev/null and b/macos/Runner/Assets.xcassets/AppIcon.appiconset/128.png differ diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/16.png b/macos/Runner/Assets.xcassets/AppIcon.appiconset/16.png new file mode 100644 index 0000000..d281cbc Binary files /dev/null and b/macos/Runner/Assets.xcassets/AppIcon.appiconset/16.png differ diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/256.png b/macos/Runner/Assets.xcassets/AppIcon.appiconset/256.png new file mode 100644 index 0000000..f39544e Binary files /dev/null and b/macos/Runner/Assets.xcassets/AppIcon.appiconset/256.png differ diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/32.png b/macos/Runner/Assets.xcassets/AppIcon.appiconset/32.png new file mode 100644 index 0000000..86ae1c3 Binary files /dev/null and b/macos/Runner/Assets.xcassets/AppIcon.appiconset/32.png differ diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/512.png b/macos/Runner/Assets.xcassets/AppIcon.appiconset/512.png new file mode 100644 index 0000000..7e918e8 Binary files /dev/null and b/macos/Runner/Assets.xcassets/AppIcon.appiconset/512.png differ diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/64.png b/macos/Runner/Assets.xcassets/AppIcon.appiconset/64.png new file mode 100644 index 0000000..b7929b8 Binary files /dev/null and b/macos/Runner/Assets.xcassets/AppIcon.appiconset/64.png differ diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json b/macos/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json index a2ec33f..2003d5b 100644 --- a/macos/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json +++ b/macos/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json @@ -1,68 +1 @@ -{ - "images" : [ - { - "size" : "16x16", - "idiom" : "mac", - "filename" : "app_icon_16.png", - "scale" : "1x" - }, - { - "size" : "16x16", - "idiom" : "mac", - "filename" : "app_icon_32.png", - "scale" : "2x" - }, - { - "size" : "32x32", - "idiom" : "mac", - "filename" : "app_icon_32.png", - "scale" : "1x" - }, - { - "size" : "32x32", - "idiom" : "mac", - "filename" : "app_icon_64.png", - "scale" : "2x" - }, - { - "size" : "128x128", - "idiom" : "mac", - "filename" : "app_icon_128.png", - "scale" : "1x" - }, - { - "size" : "128x128", - "idiom" : "mac", - "filename" : "app_icon_256.png", - "scale" : "2x" - }, - { - "size" : "256x256", - "idiom" : "mac", - "filename" : "app_icon_256.png", - "scale" : "1x" - }, - { - "size" : "256x256", - "idiom" : "mac", - "filename" : "app_icon_512.png", - "scale" : "2x" - }, - { - "size" : "512x512", - "idiom" : "mac", - "filename" : "app_icon_512.png", - "scale" : "1x" - }, - { - "size" : "512x512", - "idiom" : "mac", - "filename" : "app_icon_1024.png", - "scale" : "2x" - } - ], - "info" : { - "version" : 1, - "author" : "xcode" - } -} +{"images":[{"size":"128x128","expected-size":"128","filename":"128.png","folder":"Assets.xcassets/AppIcon.appiconset/","idiom":"mac","scale":"1x"},{"size":"256x256","expected-size":"256","filename":"256.png","folder":"Assets.xcassets/AppIcon.appiconset/","idiom":"mac","scale":"1x"},{"size":"128x128","expected-size":"256","filename":"256.png","folder":"Assets.xcassets/AppIcon.appiconset/","idiom":"mac","scale":"2x"},{"size":"256x256","expected-size":"512","filename":"512.png","folder":"Assets.xcassets/AppIcon.appiconset/","idiom":"mac","scale":"2x"},{"size":"32x32","expected-size":"32","filename":"32.png","folder":"Assets.xcassets/AppIcon.appiconset/","idiom":"mac","scale":"1x"},{"size":"512x512","expected-size":"512","filename":"512.png","folder":"Assets.xcassets/AppIcon.appiconset/","idiom":"mac","scale":"1x"},{"size":"16x16","expected-size":"16","filename":"16.png","folder":"Assets.xcassets/AppIcon.appiconset/","idiom":"mac","scale":"1x"},{"size":"16x16","expected-size":"32","filename":"32.png","folder":"Assets.xcassets/AppIcon.appiconset/","idiom":"mac","scale":"2x"},{"size":"32x32","expected-size":"64","filename":"64.png","folder":"Assets.xcassets/AppIcon.appiconset/","idiom":"mac","scale":"2x"},{"size":"512x512","expected-size":"1024","filename":"1024.png","folder":"Assets.xcassets/AppIcon.appiconset/","idiom":"mac","scale":"2x"}]} \ No newline at end of file diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png b/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png deleted file mode 100644 index 3c4935a..0000000 Binary files a/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png and /dev/null differ diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png b/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png deleted file mode 100644 index ed4cc16..0000000 Binary files a/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png and /dev/null differ diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png b/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png deleted file mode 100644 index 483be61..0000000 Binary files a/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png and /dev/null differ diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png b/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png deleted file mode 100644 index bcbf36d..0000000 Binary files a/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png and /dev/null differ diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png b/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png deleted file mode 100644 index 9c0a652..0000000 Binary files a/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png and /dev/null differ diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png b/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png deleted file mode 100644 index e71a726..0000000 Binary files a/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png and /dev/null differ diff --git a/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png b/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png deleted file mode 100644 index 8a31fe2..0000000 Binary files a/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png and /dev/null differ diff --git a/pubspec.lock b/pubspec.lock index ceff02d..e9c1736 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -1,6 +1,34 @@ # Generated by pub # See https://dart.dev/tools/pub/glossary#lockfile packages: + about: + dependency: "direct main" + description: + name: about + url: "https://pub.dartlang.org" + source: hosted + version: "2.1.1" + adaptive_dialog: + dependency: "direct main" + description: + name: adaptive_dialog + url: "https://pub.dartlang.org" + source: hosted + version: "1.5.0+1" + animations: + dependency: transitive + description: + name: animations + url: "https://pub.dartlang.org" + source: hosted + version: "2.0.2" + args: + dependency: transitive + description: + name: args + url: "https://pub.dartlang.org" + source: hosted + version: "2.3.0" async: dependency: transitive description: @@ -83,6 +111,13 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "1.0.4" + flutter_markdown: + dependency: transitive + description: + name: flutter_markdown + url: "https://pub.dartlang.org" + source: hosted + version: "0.6.9+1" flutter_test: dependency: "direct dev" description: flutter @@ -93,6 +128,20 @@ packages: description: flutter source: sdk version: "0.0.0" + http: + dependency: transitive + description: + name: http + url: "https://pub.dartlang.org" + source: hosted + version: "0.13.4" + http_parser: + dependency: transitive + description: + name: http_parser + url: "https://pub.dartlang.org" + source: hosted + version: "4.0.0" js: dependency: transitive description: @@ -107,6 +156,20 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "1.0.1" + logging: + dependency: transitive + description: + name: logging + url: "https://pub.dartlang.org" + source: hosted + version: "1.0.2" + markdown: + dependency: transitive + description: + name: markdown + url: "https://pub.dartlang.org" + source: hosted + version: "4.0.1" matcher: dependency: transitive description: @@ -128,6 +191,48 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "1.7.0" + package_info_plus: + dependency: "direct main" + description: + name: package_info_plus + url: "https://pub.dartlang.org" + source: hosted + version: "1.4.2" + package_info_plus_linux: + dependency: transitive + description: + name: package_info_plus_linux + url: "https://pub.dartlang.org" + source: hosted + version: "1.0.5" + package_info_plus_macos: + dependency: transitive + description: + name: package_info_plus_macos + url: "https://pub.dartlang.org" + source: hosted + version: "1.3.0" + package_info_plus_platform_interface: + dependency: transitive + description: + name: package_info_plus_platform_interface + url: "https://pub.dartlang.org" + source: hosted + version: "1.0.2" + package_info_plus_web: + dependency: transitive + description: + name: package_info_plus_web + url: "https://pub.dartlang.org" + source: hosted + version: "1.0.5" + package_info_plus_windows: + dependency: transitive + description: + name: package_info_plus_windows + url: "https://pub.dartlang.org" + source: hosted + version: "1.0.5" path: dependency: transitive description: @@ -233,6 +338,13 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "2.1.0" + simple_mustache: + dependency: transitive + description: + name: simple_mustache + url: "https://pub.dartlang.org" + source: hosted + version: "2.1.0" sky_engine: dependency: transitive description: flutter @@ -251,14 +363,14 @@ packages: name: sqflite_common url: "https://pub.dartlang.org" source: hosted - version: "2.2.0" + version: "2.2.1+1" sqflite_common_ffi: dependency: "direct main" description: name: sqflite_common_ffi url: "https://pub.dartlang.org" source: hosted - version: "2.1.0+2" + version: "2.1.1" sqlite3: dependency: transitive description: diff --git a/pubspec.yaml b/pubspec.yaml index f279b4b..f39d5b3 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -30,13 +30,13 @@ dependencies: flutter: sdk: flutter - - # The following adds the Cupertino Icons font to your application. - # Use with the CupertinoIcons class for iOS style icons. cupertino_icons: ^1.0.4 - sqflite_common_ffi: ^2.1.0+2 + sqflite_common_ffi: ^2.1.1 shared_preferences: ^2.0.13 url_launcher: ^6.0.20 + about: ^2.1.1 + package_info_plus: ^1.4.2 + adaptive_dialog: ^1.5.0+1 dev_dependencies: flutter_test: @@ -61,8 +61,9 @@ flutter: uses-material-design: true # To add assets to your application, add an assets section, like this: - # assets: - # - images/a_dot_burr.jpeg + # + assets: + - assets/ # - images/a_dot_ham.jpeg # An image asset can refer to one or more resolution-specific "variants", see diff --git a/windows/runner/resources/app_icon.ico b/windows/runner/resources/app_icon.ico index c04e20c..1fc50d6 100644 Binary files a/windows/runner/resources/app_icon.ico and b/windows/runner/resources/app_icon.ico differ