From e32927d15b0467d62a15301cf459aa35dc766a8e Mon Sep 17 00:00:00 2001 From: Matthias Nehlsen Date: Fri, 23 Jun 2023 10:49:10 +0200 Subject: [PATCH 1/2] Chore: upgraded dependencies --- pubspec.lock | 12 ++++++------ pubspec.yaml | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/pubspec.lock b/pubspec.lock index bb80d4841..ef99fb8b1 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -2081,10 +2081,10 @@ packages: dependency: transitive description: name: sqlparser - sha256: "1c075a15ff144b9f381140b9abc73f46b3f88a7fce9207d3d6607a3c24439cf6" + sha256: "9611f46d30a4e8286e54d17a1b5182d132512dc6fc3da90c45ad8ec2828a58b1" url: "https://pub.dev" source: hosted - version: "0.30.2" + version: "0.30.3" stack_trace: dependency: transitive description: @@ -2257,10 +2257,10 @@ packages: dependency: transitive description: name: url_launcher_android - sha256: eed4e6a1164aa9794409325c3b707ff424d4d1c2a785e7db67f8bbda00e36e51 + sha256: "15f5acbf0dce90146a0f5a2c4a002b1814a6303c4c5c075aa2623b2d16156f03" url: "https://pub.dev" source: hosted - version: "6.0.35" + version: "6.0.36" url_launcher_ios: dependency: transitive description: @@ -2465,10 +2465,10 @@ packages: dependency: transitive description: name: win32 - sha256: "7dacfda1edcca378031db9905ad7d7bd56b29fd1a90b0908b71a52a12c41e36b" + sha256: "1414f27dd781737e51afa9711f2ac2ace6ab4498ee98e20863fa5505aa00c58c" url: "https://pub.dev" source: hosted - version: "5.0.3" + version: "5.0.4" win32_registry: dependency: transitive description: diff --git a/pubspec.yaml b/pubspec.yaml index 9a2e4b39c..210b8f7df 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,7 +1,7 @@ name: lotti description: Achieve your goals and keep your data private with Lotti. publish_to: 'none' -version: 0.9.387+2274 +version: 0.9.388+2275 msix_config: display_name: LottiApp From 00eef33c3301030596e67248d1fe0657b2962753 Mon Sep 17 00:00:00 2001 From: Matthias Nehlsen Date: Fri, 23 Jun 2023 10:59:14 +0200 Subject: [PATCH 2/2] Text color on tag and task status chips --- CHANGELOG.md | 7 +++++++ lib/widgets/journal/tags/tag_widget.dart | 11 +++++++++-- lib/widgets/tasks/task_status.dart | 9 +++++++-- pubspec.yaml | 2 +- 4 files changed, 24 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8a47b0aa9..e441039eb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] ### Changed: +- Upgraded dependencies + +### Fixed: +- Text color on tag and task status chips + +## [0.8.387] - 2023-06-22 +### Changed: - Unfocus keyboard on entry/task save ## [0.8.386] - 2023-06-22 diff --git a/lib/widgets/journal/tags/tag_widget.dart b/lib/widgets/journal/tags/tag_widget.dart index 01abb82c4..3f4e7a14f 100644 --- a/lib/widgets/journal/tags/tag_widget.dart +++ b/lib/widgets/journal/tags/tag_widget.dart @@ -5,6 +5,7 @@ import 'package:lotti/services/nav_service.dart'; import 'package:lotti/themes/colors.dart'; import 'package:lotti/themes/theme.dart'; import 'package:lotti/themes/utils.dart'; +import 'package:tinycolor2/tinycolor2.dart'; class TagWidget extends StatelessWidget { const TagWidget({ @@ -19,13 +20,19 @@ class TagWidget extends StatelessWidget { @override Widget build(BuildContext context) { final localizations = AppLocalizations.of(context)!; + final tagColor = getTagColor(tagEntity); return Chip( label: GestureDetector( onDoubleTap: () => beamToNamed('/settings/tags/${tagEntity.id}'), - child: Text(tagEntity.tag), + child: Text( + tagEntity.tag, + style: TextStyle( + color: tagColor.isLight ? Colors.black : Colors.white, + ), + ), ), - backgroundColor: getTagColor(tagEntity), + backgroundColor: tagColor, visualDensity: VisualDensity.compact, onDeleted: onTapRemove, deleteIcon: const Icon( diff --git a/lib/widgets/tasks/task_status.dart b/lib/widgets/tasks/task_status.dart index c146f470a..8d6970084 100644 --- a/lib/widgets/tasks/task_status.dart +++ b/lib/widgets/tasks/task_status.dart @@ -3,6 +3,7 @@ import 'package:flutter_gen/gen_l10n/app_localizations.dart'; import 'package:lotti/classes/journal_entities.dart'; import 'package:lotti/themes/theme.dart'; import 'package:lotti/utils/task_utils.dart'; +import 'package:tinycolor2/tinycolor2.dart'; class TaskStatusWidget extends StatelessWidget { const TaskStatusWidget( @@ -15,6 +16,7 @@ class TaskStatusWidget extends StatelessWidget { @override Widget build(BuildContext context) { final localizations = AppLocalizations.of(context)!; + final backgroundColor = taskColor(task.data.status) ?? Colors.grey; return Chip( label: Text( @@ -29,9 +31,12 @@ class TaskStatusWidget extends StatelessWidget { done: (_) => localizations.taskStatusDone, rejected: (_) => localizations.taskStatusRejected, ), - style: const TextStyle(fontSize: fontSizeSmall), + style: TextStyle( + fontSize: fontSizeSmall, + color: backgroundColor.isLight ? Colors.black : Colors.white, + ), ), - backgroundColor: taskColor(task.data.status), + backgroundColor: backgroundColor, visualDensity: VisualDensity.compact, ); } diff --git a/pubspec.yaml b/pubspec.yaml index 210b8f7df..1a55c7a72 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,7 +1,7 @@ name: lotti description: Achieve your goals and keep your data private with Lotti. publish_to: 'none' -version: 0.9.388+2275 +version: 0.9.388+2276 msix_config: display_name: LottiApp