mirror of
https://github.com/Xevion/paperless-mobile.git
synced 2025-12-17 20:12:32 -06:00
feat: Finalize notes feature, update translations
This commit is contained in:
@@ -19,12 +19,14 @@ class HiveBoxes {
|
||||
static const localUserAccount = 'localUserAccount';
|
||||
static const localUserAppState = 'localUserAppState';
|
||||
static const hosts = 'hosts';
|
||||
static const hintStateBox = 'hintStateBox';
|
||||
|
||||
static List<String> get all => [
|
||||
globalSettings,
|
||||
localUserCredentials,
|
||||
localUserAccount,
|
||||
localUserAppState,
|
||||
hintStateBox,
|
||||
hosts,
|
||||
];
|
||||
}
|
||||
|
||||
@@ -54,4 +54,5 @@ extension HiveBoxAccessors on HiveInterface {
|
||||
box<LocalUserAppState>(HiveBoxes.localUserAppState);
|
||||
Box<GlobalSettings> get globalSettingsBox =>
|
||||
box<GlobalSettings>(HiveBoxes.globalSettings);
|
||||
Box<bool> get hintStateBox => box<bool>(HiveBoxes.hintStateBox);
|
||||
}
|
||||
|
||||
@@ -3,9 +3,11 @@
|
||||
import 'dart:collection';
|
||||
|
||||
import 'package:collection/collection.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:flutter_form_builder/flutter_form_builder.dart';
|
||||
import 'package:flutter_localizations/flutter_localizations.dart';
|
||||
import 'package:intl/intl.dart';
|
||||
import 'package:paperless_mobile/core/extensions/flutter_extensions.dart';
|
||||
import 'package:paperless_mobile/features/landing/view/widgets/mime_types_pie_chart.dart';
|
||||
@@ -83,7 +85,6 @@ class _FormBuilderLocalizedDatePickerState
|
||||
|
||||
final _textFieldControls =
|
||||
LinkedList<_NeighbourAwareDateInputSegmentControls>();
|
||||
String? _error;
|
||||
bool _temporarilyDisableListeners = false;
|
||||
@override
|
||||
void initState() {
|
||||
@@ -184,10 +185,7 @@ class _FormBuilderLocalizedDatePickerState
|
||||
// Imitate the functionality of the validator function in "normal" form fields.
|
||||
// The error is shown on the outer decorator as if this was a regular text input.
|
||||
// Errors are cleared after the next user interaction.
|
||||
final error = _validateDate(value);
|
||||
setState(() {
|
||||
_error = error;
|
||||
});
|
||||
// final error = _validateDate(value);
|
||||
},
|
||||
autovalidateMode: AutovalidateMode.onUserInteraction,
|
||||
initialValue: widget.initialValue != null
|
||||
@@ -201,7 +199,7 @@ class _FormBuilderLocalizedDatePickerState
|
||||
child: InputDecorator(
|
||||
textAlignVertical: TextAlignVertical.bottom,
|
||||
decoration: InputDecoration(
|
||||
errorText: _error,
|
||||
errorText: field.errorText,
|
||||
labelText: widget.labelText,
|
||||
suffixIcon: Row(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
@@ -271,16 +269,10 @@ class _FormBuilderLocalizedDatePickerState
|
||||
if (d.day != date.day && d.month != date.month && d.year != date.year) {
|
||||
return "Invalid date.";
|
||||
}
|
||||
if (d.isBefore(widget.firstDate)) {
|
||||
final formattedDateHint =
|
||||
DateFormat.yMd(widget.locale.toString()).format(widget.firstDate);
|
||||
return "Date must be after $formattedDateHint.";
|
||||
}
|
||||
if (d.isAfter(widget.lastDate)) {
|
||||
final formattedDateHint =
|
||||
DateFormat.yMd(widget.locale.toString()).format(widget.lastDate);
|
||||
return "Date must be before $formattedDateHint.";
|
||||
if (d.isBefore(widget.firstDate) || d.isAfter(widget.lastDate)) {
|
||||
return S.of(context)!.dateOutOfRange(widget.firstDate, widget.lastDate);
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
@@ -332,6 +324,7 @@ class _FormBuilderLocalizedDatePickerState
|
||||
_DateInputSegment.year => fieldValue.copyWith(year: number),
|
||||
};
|
||||
field.setValue(newValue);
|
||||
field.validate();
|
||||
}
|
||||
},
|
||||
inputFormatters: [
|
||||
|
||||
@@ -61,7 +61,7 @@ class HintCard extends StatelessWidget {
|
||||
const Padding(padding: EdgeInsets.only(bottom: 24)),
|
||||
],
|
||||
).padded(),
|
||||
).padded(),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
24
lib/core/widgets/hint_state_builder.dart
Normal file
24
lib/core/widgets/hint_state_builder.dart
Normal file
@@ -0,0 +1,24 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:hive_flutter/adapters.dart';
|
||||
import 'package:paperless_mobile/core/database/hive/hive_extensions.dart';
|
||||
|
||||
class HintStateBuilder extends StatelessWidget {
|
||||
final String? listenKey;
|
||||
final Widget Function(BuildContext context, Box<bool> box) builder;
|
||||
const HintStateBuilder({
|
||||
super.key,
|
||||
required this.builder,
|
||||
this.listenKey,
|
||||
});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return ValueListenableBuilder<Box<bool>>(
|
||||
valueListenable: Hive.hintStateBox
|
||||
.listenable(keys: listenKey != null ? [listenKey] : null),
|
||||
builder: (context, box, child) {
|
||||
return builder(context, box);
|
||||
},
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -161,6 +161,7 @@ class _DocumentDetailsPageState extends State<DocumentDetailsPage> {
|
||||
bottom: ColoredTabBar(
|
||||
tabBar: TabBar(
|
||||
isScrollable: true,
|
||||
tabAlignment: TabAlignment.start,
|
||||
tabs: [
|
||||
Tab(
|
||||
child: Text(
|
||||
@@ -203,19 +204,33 @@ class _DocumentDetailsPageState extends State<DocumentDetailsPage> {
|
||||
),
|
||||
),
|
||||
Tab(
|
||||
child: Text(
|
||||
"Notes",
|
||||
style: TextStyle(
|
||||
color: Theme.of(context)
|
||||
.colorScheme
|
||||
.onPrimaryContainer,
|
||||
),
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
Text(
|
||||
S.of(context)!.notes(0),
|
||||
style: TextStyle(
|
||||
color: Theme.of(context)
|
||||
.colorScheme
|
||||
.onPrimaryContainer,
|
||||
),
|
||||
),
|
||||
if ((state.document?.notes.length ?? 0) >
|
||||
0)
|
||||
Card(
|
||||
child: Text(state
|
||||
.document!.notes.length
|
||||
.toString())
|
||||
.paddedSymmetrically(
|
||||
horizontal: 8, vertical: 2),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
if (hasMultiUserSupport)
|
||||
Tab(
|
||||
child: Text(
|
||||
"Permissions",
|
||||
S.of(context)!.permissions,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context)
|
||||
.colorScheme
|
||||
|
||||
@@ -1,12 +1,21 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/widgets.dart';
|
||||
import 'package:flutter_bloc/flutter_bloc.dart';
|
||||
import 'package:flutter_html/flutter_html.dart';
|
||||
import 'package:intl/intl.dart';
|
||||
import 'package:paperless_api/paperless_api.dart';
|
||||
import 'package:paperless_mobile/core/database/hive/hive_config.dart';
|
||||
import 'package:paperless_mobile/core/extensions/flutter_extensions.dart';
|
||||
import 'package:paperless_mobile/core/widgets/hint_card.dart';
|
||||
import 'package:paperless_mobile/core/widgets/hint_state_builder.dart';
|
||||
import 'package:paperless_mobile/features/document_details/cubit/document_details_cubit.dart';
|
||||
import 'package:paperless_mobile/features/settings/view/widgets/global_settings_builder.dart';
|
||||
import 'package:paperless_mobile/generated/l10n/app_localizations.dart';
|
||||
import 'package:paperless_mobile/helpers/message_helpers.dart';
|
||||
import 'package:markdown/markdown.dart' show markdownToHtml;
|
||||
import 'package:shared_preferences/shared_preferences.dart';
|
||||
import 'package:url_launcher/url_launcher.dart';
|
||||
import 'package:url_launcher/url_launcher_string.dart';
|
||||
|
||||
class DocumentNotesWidget extends StatefulWidget {
|
||||
final DocumentModel document;
|
||||
@@ -19,11 +28,29 @@ class DocumentNotesWidget extends StatefulWidget {
|
||||
class _DocumentNotesWidgetState extends State<DocumentNotesWidget> {
|
||||
final _noteContentController = TextEditingController();
|
||||
final _formKey = GlobalKey<FormState>();
|
||||
|
||||
bool _isNoteSubmitting = false;
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
const hintKey = "hideMarkdownSyntaxHint";
|
||||
return SliverMainAxisGroup(
|
||||
slivers: [
|
||||
SliverPadding(
|
||||
padding: const EdgeInsets.only(bottom: 16),
|
||||
sliver: SliverToBoxAdapter(
|
||||
child: HintStateBuilder(
|
||||
listenKey: hintKey,
|
||||
builder: (context, box) {
|
||||
return HintCard(
|
||||
hintText: S.of(context)!.notesMarkdownSyntaxSupportHint,
|
||||
show: !box.get(hintKey, defaultValue: false)!,
|
||||
onHintAcknowledged: () {
|
||||
box.put(hintKey, true);
|
||||
},
|
||||
);
|
||||
},
|
||||
),
|
||||
),
|
||||
),
|
||||
SliverToBoxAdapter(
|
||||
child: Form(
|
||||
key: _formKey,
|
||||
@@ -33,79 +60,107 @@ class _DocumentNotesWidgetState extends State<DocumentNotesWidget> {
|
||||
controller: _noteContentController,
|
||||
maxLines: null,
|
||||
validator: (value) {
|
||||
if (value?.isEmpty ?? true) {
|
||||
if (value?.trim().isEmpty ?? true) {
|
||||
return S.of(context)!.thisFieldIsRequired;
|
||||
}
|
||||
return null;
|
||||
},
|
||||
textInputAction: TextInputAction.newline,
|
||||
decoration: InputDecoration(
|
||||
hintText: 'Your note here...',
|
||||
labelText: 'New note',
|
||||
floatingLabelBehavior: FloatingLabelBehavior.always,
|
||||
labelText: S.of(context)!.newNote,
|
||||
suffixIcon: IconButton(
|
||||
icon: const Icon(Icons.clear),
|
||||
onPressed: () {
|
||||
_noteContentController.clear();
|
||||
},
|
||||
),
|
||||
),
|
||||
).padded(),
|
||||
).paddedOnly(bottom: 8),
|
||||
Align(
|
||||
alignment: Alignment.centerRight,
|
||||
child: FilledButton.icon(
|
||||
icon: Icon(Icons.note_add_outlined),
|
||||
label: Text("Add note"),
|
||||
onPressed: () {
|
||||
child: ElevatedButton.icon(
|
||||
icon: _isNoteSubmitting
|
||||
? const SizedBox.square(
|
||||
dimension: 20,
|
||||
child: Center(
|
||||
child: CircularProgressIndicator(
|
||||
strokeWidth: 3,
|
||||
),
|
||||
),
|
||||
)
|
||||
: const Icon(Icons.note_add_outlined),
|
||||
label: Text(S.of(context)!.addNote),
|
||||
onPressed: () async {
|
||||
_formKey.currentState?.save();
|
||||
if (_formKey.currentState?.validate() ?? false) {
|
||||
context
|
||||
.read<DocumentDetailsCubit>()
|
||||
.addNote(_noteContentController.text);
|
||||
setState(() {
|
||||
_isNoteSubmitting = true;
|
||||
});
|
||||
try {
|
||||
await context
|
||||
.read<DocumentDetailsCubit>()
|
||||
.addNote(_noteContentController.text.trim());
|
||||
_noteContentController.clear();
|
||||
} catch (error) {
|
||||
showGenericError(context, error);
|
||||
} finally {
|
||||
setState(() {
|
||||
_isNoteSubmitting = false;
|
||||
});
|
||||
}
|
||||
}
|
||||
},
|
||||
).padded(),
|
||||
),
|
||||
),
|
||||
],
|
||||
).padded(),
|
||||
),
|
||||
),
|
||||
),
|
||||
const SliverToBoxAdapter(
|
||||
child: SizedBox(height: 16),
|
||||
),
|
||||
SliverList.separated(
|
||||
separatorBuilder: (context, index) => const SizedBox(height: 16),
|
||||
itemBuilder: (context, index) {
|
||||
final note = widget.document.notes.elementAt(index);
|
||||
return Card(
|
||||
// borderRadius: BorderRadius.circular(8),
|
||||
// elevation: 1,
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
if (note.created != null)
|
||||
Text(
|
||||
DateFormat.yMMMd(
|
||||
Localizations.localeOf(context).toString())
|
||||
.addPattern('\u2014')
|
||||
.add_jm()
|
||||
.format(note.created!),
|
||||
style: Theme.of(context).textTheme.labelMedium?.copyWith(
|
||||
color: Theme.of(context)
|
||||
.colorScheme
|
||||
.onSurface
|
||||
.withOpacity(.5),
|
||||
),
|
||||
),
|
||||
const SizedBox(height: 8),
|
||||
Text(
|
||||
note.note!,
|
||||
textAlign: TextAlign.justify,
|
||||
style: Theme.of(context).textTheme.bodyLarge?.copyWith(
|
||||
color: Theme.of(context).colorScheme.onSurface,
|
||||
),
|
||||
Html(
|
||||
data: markdownToHtml(note.note!),
|
||||
onLinkTap: (url, attributes, element) async {
|
||||
if (url?.isEmpty ?? true) {
|
||||
return;
|
||||
}
|
||||
if (await canLaunchUrlString(url!)) {
|
||||
launchUrlString(url);
|
||||
}
|
||||
},
|
||||
),
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.end,
|
||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||
children: [
|
||||
if (note.created != null)
|
||||
Text(
|
||||
DateFormat.yMMMd(
|
||||
Localizations.localeOf(context).toString())
|
||||
.addPattern('\u2014')
|
||||
.add_jm()
|
||||
.format(note.created!),
|
||||
style:
|
||||
Theme.of(context).textTheme.labelMedium?.copyWith(
|
||||
color: Theme.of(context)
|
||||
.colorScheme
|
||||
.onSurface
|
||||
.withOpacity(.5),
|
||||
),
|
||||
),
|
||||
IconButton(
|
||||
icon: Icon(Icons.delete),
|
||||
tooltip: S.of(context)!.delete,
|
||||
icon: const Icon(Icons.delete),
|
||||
onPressed: () {
|
||||
context.read<DocumentDetailsCubit>().deleteNote(note);
|
||||
showSnackBar(
|
||||
context,
|
||||
S.of(context)!.documentSuccessfullyUpdated,
|
||||
);
|
||||
},
|
||||
),
|
||||
],
|
||||
|
||||
@@ -424,7 +424,7 @@ class _DocumentEditPageState extends State<DocumentEditPage>
|
||||
initialValue: initialCreatedAtDate,
|
||||
labelText: S.of(context)!.createdAt,
|
||||
firstDate: DateTime(1970, 1, 1),
|
||||
lastDate: DateTime.now(),
|
||||
lastDate: DateTime(2100, 1, 1),
|
||||
locale: Localizations.localeOf(context),
|
||||
prefixIcon: Icon(Icons.calendar_today),
|
||||
),
|
||||
|
||||
@@ -40,7 +40,7 @@ class _DocumentSearchBarState extends State<DocumentSearchBar> {
|
||||
constraints: const BoxConstraints(
|
||||
maxWidth: 720,
|
||||
minWidth: 360,
|
||||
maxHeight: 56,
|
||||
maxHeight: 48,
|
||||
minHeight: 48,
|
||||
),
|
||||
child: Row(
|
||||
|
||||
@@ -222,7 +222,7 @@ class _DocumentUploadPreparationPageState
|
||||
FormBuilderLocalizedDatePicker(
|
||||
name: DocumentModel.createdKey,
|
||||
firstDate: DateTime(1970, 1, 1),
|
||||
lastDate: DateTime.now(),
|
||||
lastDate: DateTime(2100, 1, 1),
|
||||
locale: Localizations.localeOf(context),
|
||||
labelText: S.of(context)!.createdAt + " *",
|
||||
allowUnset: true,
|
||||
|
||||
@@ -21,6 +21,7 @@ import 'package:paperless_mobile/features/documents/view/widgets/selection/docum
|
||||
import 'package:paperless_mobile/features/documents/view/widgets/selection/view_type_selection_widget.dart';
|
||||
import 'package:paperless_mobile/features/documents/view/widgets/sort_documents_button.dart';
|
||||
import 'package:paperless_mobile/features/labels/cubit/label_cubit.dart';
|
||||
import 'package:paperless_mobile/features/logging/data/logger.dart';
|
||||
import 'package:paperless_mobile/features/saved_view/cubit/saved_view_cubit.dart';
|
||||
import 'package:paperless_mobile/features/tasks/model/pending_tasks_notifier.dart';
|
||||
import 'package:paperless_mobile/generated/l10n/app_localizations.dart';
|
||||
@@ -308,8 +309,18 @@ class _DocumentsPageState extends State<DocumentsPage> {
|
||||
// Listen for scroll notifications to load new data.
|
||||
// Scroll controller does not work here due to nestedscrollview limitations.
|
||||
final offset = notification.metrics.pixels;
|
||||
if (offset > 128 && _savedViewsExpansionController.isExpanded) {
|
||||
_savedViewsExpansionController.collapse();
|
||||
try {
|
||||
if (offset > 128 && _savedViewsExpansionController.isExpanded) {
|
||||
_savedViewsExpansionController.collapse();
|
||||
}
|
||||
// Workaround for https://github.com/astubenbord/paperless-mobile/issues/341 probably caused by https://github.com/flutter/flutter/issues/138153
|
||||
} on TypeError catch (error) {
|
||||
logger.fw(
|
||||
"An exception was thrown, but this message can probably be ignored. See issue #341 for more details.",
|
||||
error: error,
|
||||
className: runtimeType.toString(),
|
||||
methodName: "_buildDocumentsTab",
|
||||
);
|
||||
}
|
||||
|
||||
final max = notification.metrics.maxScrollExtent;
|
||||
|
||||
@@ -1041,5 +1041,8 @@
|
||||
"format": "yMd"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"permissions": "Permissions",
|
||||
"newNote": "New note",
|
||||
"notesMarkdownSyntaxSupportHint": "Paperless Mobile can render notes using basic markdown syntax. Try it out!"
|
||||
}
|
||||
@@ -1041,5 +1041,8 @@
|
||||
"format": "yMd"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"permissions": "Permissions",
|
||||
"newNote": "New note",
|
||||
"notesMarkdownSyntaxSupportHint": "Paperless Mobile can render notes using basic markdown syntax. Try it out!"
|
||||
}
|
||||
@@ -1041,5 +1041,8 @@
|
||||
"format": "yMd"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"permissions": "Berechtigungen",
|
||||
"newNote": "Neue Notiz",
|
||||
"notesMarkdownSyntaxSupportHint": "Paperless Mobile unterstützt Markdown-Syntax zur Darstellung und Formatierung von Notizen. Probiere es aus!"
|
||||
}
|
||||
@@ -1041,6 +1041,8 @@
|
||||
"format": "yMd"
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
},
|
||||
"permissions": "Permissions",
|
||||
"newNote": "New note",
|
||||
"notesMarkdownSyntaxSupportHint": "Paperless Mobile can render notes using basic markdown syntax. Try it out!"
|
||||
}
|
||||
@@ -1041,5 +1041,8 @@
|
||||
"format": "yMd"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"permissions": "Permissions",
|
||||
"newNote": "New note",
|
||||
"notesMarkdownSyntaxSupportHint": "Paperless Mobile can render notes using basic markdown syntax. Try it out!"
|
||||
}
|
||||
@@ -1041,5 +1041,8 @@
|
||||
"format": "yMd"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"permissions": "Permissions",
|
||||
"newNote": "New note",
|
||||
"notesMarkdownSyntaxSupportHint": "Paperless Mobile can render notes using basic markdown syntax. Try it out!"
|
||||
}
|
||||
@@ -1041,5 +1041,8 @@
|
||||
"format": "yMd"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"permissions": "Permissions",
|
||||
"newNote": "New note",
|
||||
"notesMarkdownSyntaxSupportHint": "Paperless Mobile can render notes using basic markdown syntax. Try it out!"
|
||||
}
|
||||
@@ -1041,5 +1041,8 @@
|
||||
"format": "yMd"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"permissions": "Permissions",
|
||||
"newNote": "New note",
|
||||
"notesMarkdownSyntaxSupportHint": "Paperless Mobile can render notes using basic markdown syntax. Try it out!"
|
||||
}
|
||||
@@ -1041,5 +1041,8 @@
|
||||
"format": "yMd"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"permissions": "Permissions",
|
||||
"newNote": "New note",
|
||||
"notesMarkdownSyntaxSupportHint": "Paperless Mobile can render notes using basic markdown syntax. Try it out!"
|
||||
}
|
||||
@@ -1041,5 +1041,8 @@
|
||||
"format": "yMd"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"permissions": "Permissions",
|
||||
"newNote": "New note",
|
||||
"notesMarkdownSyntaxSupportHint": "Paperless Mobile can render notes using basic markdown syntax. Try it out!"
|
||||
}
|
||||
@@ -1041,5 +1041,8 @@
|
||||
"format": "yMd"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"permissions": "Permissions",
|
||||
"newNote": "New note",
|
||||
"notesMarkdownSyntaxSupportHint": "Paperless Mobile can render notes using basic markdown syntax. Try it out!"
|
||||
}
|
||||
@@ -1041,5 +1041,8 @@
|
||||
"format": "yMd"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"permissions": "Permissions",
|
||||
"newNote": "New note",
|
||||
"notesMarkdownSyntaxSupportHint": "Paperless Mobile can render notes using basic markdown syntax. Try it out!"
|
||||
}
|
||||
@@ -111,6 +111,7 @@ Future<void> _initHive() async {
|
||||
registerHiveAdapters();
|
||||
await Hive.openBox<LocalUserAccount>(HiveBoxes.localUserAccount);
|
||||
await Hive.openBox<LocalUserAppState>(HiveBoxes.localUserAppState);
|
||||
await Hive.openBox<bool>(HiveBoxes.hintStateBox);
|
||||
await Hive.openBox<String>(HiveBoxes.hosts);
|
||||
final globalSettingsBox =
|
||||
await Hive.openBox<GlobalSettings>(HiveBoxes.globalSettings);
|
||||
|
||||
@@ -82,14 +82,14 @@ SystemUiOverlayStyle buildOverlayStyle(
|
||||
Brightness.light => SystemUiOverlayStyle.dark.copyWith(
|
||||
systemNavigationBarColor: color,
|
||||
systemNavigationBarDividerColor: color,
|
||||
statusBarColor: theme.colorScheme.background,
|
||||
// statusBarColor: theme.colorScheme.background,
|
||||
// statusBarColor: theme.colorScheme.background,
|
||||
// systemNavigationBarDividerColor: theme.colorScheme.surface,
|
||||
),
|
||||
Brightness.dark => SystemUiOverlayStyle.light.copyWith(
|
||||
systemNavigationBarColor: color,
|
||||
systemNavigationBarDividerColor: color,
|
||||
statusBarColor: theme.colorScheme.background,
|
||||
// statusBarColor: theme.colorScheme.background,
|
||||
// statusBarColor: theme.colorScheme.background,
|
||||
// systemNavigationBarDividerColor: theme.colorScheme.surface,
|
||||
),
|
||||
|
||||
Reference in New Issue
Block a user