Bump knihovnu + nastavení

This commit is contained in:
Matyáš Caras 2022-05-02 12:07:47 +02:00
parent 5b7d1e226b
commit 04277effc2
5 changed files with 127 additions and 45 deletions

View file

@ -15,7 +15,8 @@ class _AboutPageState extends State<AboutPage> {
appBar: AppBar(
title: const Text("O Aplikaci"),
),
body: SizedBox(
body: SingleChildScrollView(
child: SizedBox(
height: MediaQuery.of(context).size.height,
child: Column(mainAxisSize: MainAxisSize.min, children: [
const Text("OpenCanteen", style: TextStyle(fontSize: 30)),
@ -55,9 +56,15 @@ class _AboutPageState extends State<AboutPage> {
cudlik(
"path_provider",
"Copyright 2013 The Flutter Authors. All rights reserved., licence BSD-3-Clause",
"https://github.com/flutter/plugins/blob/main/packages/path_provider/path_provider/LICENSE"),
const SizedBox(height: 10),
cudlik(
"shared_preferences",
"Copyright 2013 The Flutter Authors. All rights reserved., licence BSD-3-Clause",
"https://github.com/flutter/plugins/blob/main/packages/path_provider/path_provider/LICENSE")
]),
),
),
);
}

View file

@ -6,6 +6,7 @@ import 'package:flutter/material.dart';
import 'package:flutter_secure_storage/flutter_secure_storage.dart';
import 'package:opencanteen/util.dart';
import 'package:path_provider/path_provider.dart';
import 'package:shared_preferences/shared_preferences.dart';
import 'package:url_launcher/url_launcher.dart';
import '../loginmanager.dart';
@ -212,7 +213,8 @@ class _JidelnicekPageState extends State<JidelnicekPage> {
/// uložení jídelníčku pro dnešek offline
void ulozitDnesekOffline() async {
if (await LoginManager.zapamatovat()) {
var prefs = await SharedPreferences.getInstance();
if (prefs.getBool("offline") != null && prefs.getBool("offline")!) {
Directory appDocDir = await getApplicationDocumentsDirectory();
for (var f in appDocDir.listSync()) {
// Vymažeme obsah

16
lib/okna/nastaveni.dart Normal file
View file

@ -0,0 +1,16 @@
import 'package:flutter/material.dart';
// TODO
class Nastaveni extends StatefulWidget {
const Nastaveni({Key? key}) : super(key: key);
@override
State<Nastaveni> createState() => _NastaveniState();
}
class _NastaveniState extends State<Nastaveni> {
@override
Widget build(BuildContext context) {
return Container();
}
}

View file

@ -28,7 +28,7 @@ packages:
name: canteenlib
url: "https://pub.dartlang.org"
source: hosted
version: "0.1.0-alpha.15"
version: "0.1.0-alpha.16"
characters:
dependency: transitive
description:
@ -345,6 +345,62 @@ packages:
url: "https://pub.dartlang.org"
source: hosted
version: "4.2.4"
shared_preferences:
dependency: "direct main"
description:
name: shared_preferences
url: "https://pub.dartlang.org"
source: hosted
version: "2.0.13"
shared_preferences_android:
dependency: transitive
description:
name: shared_preferences_android
url: "https://pub.dartlang.org"
source: hosted
version: "2.0.11"
shared_preferences_ios:
dependency: transitive
description:
name: shared_preferences_ios
url: "https://pub.dartlang.org"
source: hosted
version: "2.1.0"
shared_preferences_linux:
dependency: transitive
description:
name: shared_preferences_linux
url: "https://pub.dartlang.org"
source: hosted
version: "2.1.0"
shared_preferences_macos:
dependency: transitive
description:
name: shared_preferences_macos
url: "https://pub.dartlang.org"
source: hosted
version: "2.0.3"
shared_preferences_platform_interface:
dependency: transitive
description:
name: shared_preferences_platform_interface
url: "https://pub.dartlang.org"
source: hosted
version: "2.0.0"
shared_preferences_web:
dependency: transitive
description:
name: shared_preferences_web
url: "https://pub.dartlang.org"
source: hosted
version: "2.0.3"
shared_preferences_windows:
dependency: transitive
description:
name: shared_preferences_windows
url: "https://pub.dartlang.org"
source: hosted
version: "2.1.0"
sky_engine:
dependency: transitive
description: flutter

View file

@ -16,11 +16,12 @@ dependencies:
sdk: flutter
flutter_localizations:
sdk: flutter
canteenlib: ^0.1.0-alpha.15
canteenlib: ^0.1.0-alpha.16
connectivity_plus: ^2.2.1
flutter_secure_storage: ^5.0.2
url_launcher: ^6.0.20
path_provider: ^2.0.9
shared_preferences: ^2.0.13
dev_dependencies:
flutter_lints: ^1.0.0