Skip to content

Commit

Permalink
Merge pull request #41 from raxysstudios/dev
Browse files Browse the repository at this point in the history
Lints
  • Loading branch information
alkaitagi authored May 18, 2022
2 parents 764a04a + c901aa4 commit d342e54
Show file tree
Hide file tree
Showing 9 changed files with 17 additions and 86 deletions.
2 changes: 1 addition & 1 deletion lib/modules/dictionary/screens/dictionary.dart
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import 'package:avzag/store.dart';
import 'package:avzag/modules/dictionary/widgets/entry_group.dart';
import 'package:avzag/modules/navigation/nav_drawer.dart';
import 'package:avzag/shared/widgets/caption.dart';
import 'package:avzag/shared/widgets/rounded_menu_button.dart';
import 'package:avzag/store.dart';
import 'package:flutter/material.dart';
import 'package:infinite_scroll_pagination/infinite_scroll_pagination.dart';
import 'package:provider/provider.dart';
Expand Down
1 change: 0 additions & 1 deletion lib/modules/dictionary/screens/word.dart
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import 'package:avzag/store.dart';
import 'package:avzag/modules/dictionary/widgets/samples_column.dart';
import 'package:avzag/shared/utils/utils.dart';
import 'package:avzag/shared/widgets/caption.dart';
Expand Down
2 changes: 1 addition & 1 deletion lib/modules/dictionary/screens/word_editor.dart
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import 'package:avzag/store.dart';
import 'package:avzag/modules/dictionary/widgets/samples_editor.dart';
import 'package:avzag/shared/utils/utils.dart';
import 'package:avzag/shared/widgets/column_card.dart';
Expand All @@ -7,6 +6,7 @@ import 'package:avzag/shared/widgets/language_flag.dart';
import 'package:avzag/shared/widgets/modals/danger_dialog.dart';
import 'package:avzag/shared/widgets/options_button.dart';
import 'package:avzag/shared/widgets/rounded_back_button.dart';
import 'package:avzag/store.dart';
import 'package:flutter/material.dart';

import '../models/use.dart';
Expand Down
2 changes: 1 addition & 1 deletion lib/modules/dictionary/services/word.dart
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import 'package:avzag/store.dart';
import 'package:avzag/shared/utils/contribution.dart';
import 'package:avzag/shared/widgets/modals/danger_dialog.dart';
import 'package:avzag/shared/widgets/modals/loading_dialog.dart';
import 'package:avzag/shared/widgets/modals/snackbar_manager.dart';
import 'package:avzag/store.dart';
import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:flutter/material.dart';

Expand Down
2 changes: 1 addition & 1 deletion lib/modules/dictionary/widgets/search_toolbar.dart
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import 'dart:async';

import 'package:avzag/store.dart';
import 'package:avzag/shared/utils/utils.dart';
import 'package:avzag/shared/widgets/language_avatar.dart';
import 'package:avzag/shared/widgets/options_button.dart';
import 'package:avzag/store.dart';
import 'package:flutter/material.dart';
import 'package:provider/provider.dart';

Expand Down
3 changes: 1 addition & 2 deletions lib/modules/navigation/account.dart
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
import 'package:avzag/store.dart';
import 'package:avzag/modules/navigation/sign_in_buttons.dart';
import 'package:avzag/shared/utils/open_link.dart';
import 'package:avzag/shared/utils/utils.dart';
import 'package:avzag/shared/widgets/column_card.dart';
import 'package:avzag/shared/widgets/language_avatar.dart';
import 'package:avzag/shared/widgets/span_icon.dart';

import 'package:avzag/store.dart';
import 'package:badges/badges.dart';
import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart';
Expand Down
3 changes: 2 additions & 1 deletion lib/modules/navigation/nav_drawer.dart
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import 'package:avzag/store.dart';
import 'package:avzag/modules/dictionary/screens/dictionary.dart';
import 'package:avzag/modules/home/screens/home.dart';
import 'package:avzag/shared/utils/open_link.dart';
Expand All @@ -7,9 +6,11 @@ import 'package:avzag/shared/widgets/column_card.dart';
import 'package:avzag/shared/widgets/expandable_tile.dart';
import 'package:avzag/shared/widgets/raxys_logo.dart';
import 'package:avzag/shared/widgets/span_icon.dart';
import 'package:avzag/store.dart';
import 'package:flutter/material.dart';
import 'package:package_info_plus/package_info_plus.dart';
import 'package:shared_preferences/shared_preferences.dart';

import 'account.dart';

Future<void> navigate(
Expand Down
15 changes: 10 additions & 5 deletions lib/shared/widgets/compact_input.dart
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
import 'package:flutter/material.dart';

import '../utils/utils.dart';
import 'modals/editor_dialog.dart';
String? _emptyValidator(String? value) {
value = value?.trim() ?? '';
return value.isEmpty ? '' : null;
}

class CompactInput extends StatelessWidget {
const CompactInput(
Expand Down Expand Up @@ -43,9 +45,12 @@ class CompactInput extends StatelessWidget {
),
maxLines: multiline ? 0 : null,
initialValue: initial,
validator: noEmpty ? emptyValidator : null,
inputFormatters: lowercase ? [LowerCaseTextFormatter()] : null,
onChanged: (s) => onChanged(s.trim()),
validator: noEmpty ? _emptyValidator : null,
onChanged: (s) {
s = s.trim();
if (lowercase) s = s.toLowerCase();
onChanged(s);
},
),
);
}
Expand Down
73 changes: 0 additions & 73 deletions lib/shared/widgets/modals/editor_dialog.dart

This file was deleted.

0 comments on commit d342e54

Please sign in to comment.