Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
ginkgo
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
vjrj
ginkgo
Commits
b1712021
Commit
b1712021
authored
1 year ago
by
vjrj
Browse files
Options
Downloads
Patches
Plain Diff
Added feedback
parent
ec38efb3
No related branches found
No related tags found
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
lib/main.dart
+18
-19
18 additions, 19 deletions
lib/main.dart
lib/ui/widgets/card_drawer.dart
+27
-1
27 additions, 1 deletion
lib/ui/widgets/card_drawer.dart
pubspec.lock
+29
-43
29 additions, 43 deletions
pubspec.lock
pubspec.yaml
+6
-2
6 additions, 2 deletions
pubspec.yaml
with
80 additions
and
65 deletions
lib/main.dart
+
18
−
19
View file @
b1712021
import
'dart:async'
;
import
'dart:io'
;
import
'package:connectivity_wrapper/connectivity_wrapper.dart'
;
import
'package:cron/cron.dart'
;
import
'package:easy_localization/easy_localization.dart'
;
import
'package:feedback/feedback.dart'
;
import
'package:filesystem_picker/filesystem_picker.dart'
;
import
'package:flutter/foundation.dart'
;
import
'package:flutter/material.dart'
;
...
...
@@ -25,6 +26,7 @@ import 'app_bloc_observer.dart';
import
'config/theme.dart'
;
import
'cubit/bottom_nav_cubit.dart'
;
import
'cubit/theme_cubit.dart'
;
import
'custom_feedback_localization.dart'
;
import
'data/models/app_cubit.dart'
;
import
'data/models/app_state.dart'
;
import
'data/models/contact_cubit.dart'
;
...
...
@@ -60,9 +62,7 @@ void main() async {
// .env
await
dotenv
.
load
(
fileName:
kReleaseMode
?
'assets/env.production.txt'
:
'assets/.env.development'
);
fileName:
kReleaseMode
?
'env.production.txt'
:
'.env.development'
);
final
SharedPreferencesHelper
shared
=
SharedPreferencesHelper
();
await
shared
.
init
();
...
...
@@ -97,7 +97,7 @@ void main() async {
void
appRunner
()
=
>
runApp
(
EasyLocalization
(
path:
'
assets/
translations'
,
path:
'translations'
,
supportedLocales:
const
<
Locale
>[
// Asturian is not supported in flutter
// More info: https://docs.flutter.dev/development/accessibility-and-localization/internationalization#adding-support-for-a-new-language
...
...
@@ -325,14 +325,16 @@ class _GinkgoAppState extends State<GinkgoApp> {
Widget
build
(
BuildContext
context
)
{
return
BlocBuilder
<
NodeListCubit
,
NodeListState
>(
builder:
(
BuildContext
nodeContext
,
NodeListState
state
)
{
return
ConnectivityAppWrapper
(
app:
FilesystemPickerDefaultOptions
(
fileTileSelectMode:
FileTileSelectMode
.
wholeTile
,
theme:
FilesystemPickerTheme
(
topBar:
FilesystemPickerTopBarThemeData
(
backgroundColor:
Theme
.
of
(
context
)
.
colorScheme
.
primary
,
),
),
return
FilesystemPickerDefaultOptions
(
fileTileSelectMode:
FileTileSelectMode
.
wholeTile
,
theme:
FilesystemPickerTheme
(
topBar:
FilesystemPickerTopBarThemeData
(
backgroundColor:
Theme
.
of
(
context
)
.
colorScheme
.
primary
,
),
),
child:
BetterFeedback
(
localizationsDelegates:
context
.
localizationDelegates
.
.
add
(
CustomFeedbackLocalizationsDelegate
()),
child:
MaterialApp
(
/// Localization is not available for the title.
title:
'Ğ1nkgo'
,
...
...
@@ -358,12 +360,9 @@ class _GinkgoAppState extends State<GinkgoApp> {
NotificationController
.
locale
=
context
.
locale
;
return
ResponsiveWrapper
.
builder
(
BouncingScrollWrapper
.
builder
(
context
,
ConnectivityWidgetWrapper
(
message:
tr
(
'offline'
),
height:
20
,
child:
widget
!
,
)),
context
,
widget
!
,
),
maxWidth:
480
,
minWidth:
480
,
// defaultScale: true,
...
...
This diff is collapsed.
Click to expand it.
lib/ui/widgets/card_drawer.dart
+
27
−
1
View file @
b1712021
import
'package:easy_localization/easy_localization.dart'
;
import
'package:feedback_gitlab/feedback_gitlab.dart'
;
import
'package:feedback_sentry/feedback_sentry.dart'
;
import
'package:flutter/foundation.dart'
;
import
'package:flutter/material.dart'
;
import
'package:flutter_dotenv/flutter_dotenv.dart'
;
import
'package:package_info_plus/package_info_plus.dart'
;
import
'package:sentry_flutter/sentry_flutter.dart'
;
...
...
@@ -84,13 +87,36 @@ class CardDrawer extends StatelessWidget {
),
),
),
ListTile
(
leading:
const
Icon
(
Icons
.
feedback
),
title:
Text
(
tr
(
'feedback'
)),
onTap:
()
{
Navigator
.
pop
(
context
);
final
String
gitLabToken
=
"
${dotenv.env['GITLAB_TOKEN']}
"
;
if
(
gitLabToken
.
isNotEmpty
)
{
BetterFeedback
.
of
(
context
)
.
showAndUploadToGitLab
(
projectId:
'663'
,
apiToken:
gitLabToken
,
gitlabUrl:
'git.duniter.org'
);
}
BetterFeedback
.
of
(
context
)
.
showAndUploadToSentry
(
// name: 'Foo Bar',
// email: 'foo_bar@example.com',
);
},
),
AboutListTile
(
icon:
g1nkgoIcon
,
applicationName:
tr
(
'app_name'
),
applicationVersion:
'Version:
${snapshot.data!.version}
'
,
applicationIcon:
g1nkgoIcon
,
applicationLegalese:
'© 2023-
${DateTime.now().year}
Comunes Association, under AGPLv3'
,
'©
${DateTime
.now()
.year
.toString() == '2023' ? '2023' : '2023-${DateTime
.now()
.year}
'
}
Comunes
Association
,
under
AGPLv3
',
aboutBoxChildren: const <Widget>[
SizedBox(height: 10.0),
]),
...
...
This diff is collapsed.
Click to expand it.
pubspec.lock
+
29
−
43
View file @
b1712021
...
...
@@ -233,30 +233,6 @@ packages:
url: "https://pub.dev"
source: hosted
version: "1.17.0"
connectivity_plus:
dependency: transitive
description:
name: connectivity_plus
sha256: d73575bb66216738db892f72ba67dc478bd3b5490fbbcf43644b57645eabc822
url: "https://pub.dev"
source: hosted
version: "3.0.4"
connectivity_plus_platform_interface:
dependency: transitive
description:
name: connectivity_plus_platform_interface
sha256: cf1d1c28f4416f8c654d7dc3cd638ec586076255d407cef3ddbdaf178272a71a
url: "https://pub.dev"
source: hosted
version: "1.2.4"
connectivity_wrapper:
dependency: "direct main"
description:
name: connectivity_wrapper
sha256: f7c3cefecc57ee290e5e49e7fb9e6a09b5839614b5e30bceebddb9d7925d054c
url: "https://pub.dev"
source: hosted
version: "1.1.3"
convert:
dependency: transitive
description:
...
...
@@ -321,14 +297,6 @@ packages:
url: "https://pub.dev"
source: hosted
version: "2.3.0"
dbus:
dependency: transitive
description:
name: dbus
sha256: "6f07cba3f7b3448d42d015bfd3d53fe12e5b36da2423f23838efc1d5fb31a263"
url: "https://pub.dev"
source: hosted
version: "0.7.8"
dio:
dependency: transitive
description:
...
...
@@ -348,9 +316,11 @@ packages:
durt:
dependency: "direct main"
description:
path: "../durt"
relative: true
source: path
path: "."
ref: HEAD
resolved-ref: c08320e8336bdcb3e9cdc2ae5e8b418be5cd9e87
url: "https://git.duniter.org/vjrj/durt.git"
source: git
version: "0.1.6"
easy_debounce:
dependency: "direct main"
...
...
@@ -408,6 +378,30 @@ packages:
url: "https://pub.dev"
source: hosted
version: "0.2.1"
feedback:
dependency: "direct main"
description:
name: feedback
sha256: a3a18af1d490b1e172cc354f1270760d14d2d0d5bb65e2d3710565de88507f33
url: "https://pub.dev"
source: hosted
version: "2.6.0"
feedback_gitlab:
dependency: "direct main"
description:
name: feedback_gitlab
sha256: "30619df8c30772d0e62dd893900b451a7b59218411b099c4fbee05447caea82f"
url: "https://pub.dev"
source: hosted
version: "2.2.0"
feedback_sentry:
dependency: "direct main"
description:
name: feedback_sentry
sha256: "41b9a995355bd4bf3342cff8ba4b489680bf86d8d3740f12159de79194c0f3cc"
url: "https://pub.dev"
source: hosted
version: "2.4.0"
ffi:
dependency: transitive
description:
...
...
@@ -892,14 +886,6 @@ packages:
url: "https://pub.dev"
source: hosted
version: "1.0.0"
nm:
dependency: transitive
description:
name: nm
sha256: "2c9aae4127bdc8993206464fcc063611e0e36e72018696cd9631023a31b24254"
url: "https://pub.dev"
source: hosted
version: "0.5.0"
normalize:
dependency: transitive
description:
...
...
This diff is collapsed.
Click to expand it.
pubspec.yaml
+
6
−
2
View file @
b1712021
...
...
@@ -40,11 +40,12 @@ dependencies:
easy_logger
:
^0.0.2
qr_flutter
:
^4.0.0
introduction_screen
:
^3.1.6
connectivity_wrapper
:
^1.1.1
responsive_framework
:
^0.2.0
#durt: ^0.1.6
durt
:
path
:
../durt
# path: ../durt
git
:
url
:
https://git.duniter.org/vjrj/durt.git
flutter_neumorphic
:
^3.2.0
shared_preferences
:
^2.0.18
another_flushbar
:
^1.12.29
...
...
@@ -80,6 +81,9 @@ dependencies:
easy_debounce
:
^2.0.3
tutorial_coach_mark
:
^1.2.8
lehttp_overrides
:
^1.0.2
feedback
:
^2.6.0
feedback_sentry
:
^2.4.0
feedback_gitlab
:
^2.2.0
dev_dependencies
:
flutter_test
:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment