diff --git a/CHANGELOG.md b/CHANGELOG.md index 9265112..f6d4908 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -267,4 +267,7 @@ Fix for #189 Fix for #190 ## [0.32.3] -Fix for #197 and #196 \ No newline at end of file +Fix for #197 and #196 + +## [0.32.4] +Dependencies upgrade \ No newline at end of file diff --git a/bin/flutter_i18n.dart b/bin/flutter_i18n.dart index bc42297..591cbae 100644 --- a/bin/flutter_i18n.dart +++ b/bin/flutter_i18n.dart @@ -1,5 +1,3 @@ -import 'package:flutter_i18n/utils/message_printer.dart'; - import 'actions/ActionInterface.dart'; import 'actions/DiffAction.dart'; import 'actions/ValidateAction.dart'; diff --git a/example/lib/basic_example.dart b/example/lib/basic_example.dart index f8afd96..095dcf4 100644 --- a/example/lib/basic_example.dart +++ b/example/lib/basic_example.dart @@ -2,8 +2,6 @@ import 'dart:async'; import 'package:flutter/material.dart'; import 'package:flutter_i18n/flutter_i18n.dart'; -import 'package:flutter_i18n/widgets/I18nPlural.dart'; -import 'package:flutter_i18n/widgets/I18nText.dart'; import 'package:flutter_localizations/flutter_localizations.dart'; Future main() async { diff --git a/example/lib/local_example.dart b/example/lib/local_example.dart index 0c5f923..0441fda 100644 --- a/example/lib/local_example.dart +++ b/example/lib/local_example.dart @@ -1,7 +1,6 @@ import 'dart:async'; import 'dart:io'; -import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; import 'package:flutter_i18n/flutter_i18n_delegate.dart'; import 'package:flutter_i18n/loaders/decoders/json_decode_strategy.dart'; diff --git a/example/lib/namespace_example.dart b/example/lib/namespace_example.dart index c16e944..9ae43cd 100644 --- a/example/lib/namespace_example.dart +++ b/example/lib/namespace_example.dart @@ -2,7 +2,6 @@ import 'dart:async'; import 'package:flutter/material.dart'; import 'package:flutter_i18n/flutter_i18n.dart'; -import 'package:flutter_i18n/widgets/I18nText.dart'; import 'package:flutter_localizations/flutter_localizations.dart'; Future main() async { diff --git a/example/lib/network_example.dart b/example/lib/network_example.dart index 094b77c..dd6c2bc 100644 --- a/example/lib/network_example.dart +++ b/example/lib/network_example.dart @@ -3,7 +3,6 @@ import 'dart:async'; import 'package:flutter/material.dart'; import 'package:flutter_i18n/flutter_i18n.dart'; import 'package:flutter_i18n/loaders/decoders/json_decode_strategy.dart'; -import 'package:flutter_i18n/widgets/I18nText.dart'; import 'package:flutter_localizations/flutter_localizations.dart'; class CustomNetworkFileTranslationLoader extends NetworkFileTranslationLoader { diff --git a/example/pubspec.lock b/example/pubspec.lock index 75f4139..2bb9fbf 100644 --- a/example/pubspec.lock +++ b/example/pubspec.lock @@ -136,7 +136,7 @@ packages: path: ".." relative: true source: path - version: "0.32.3" + version: "0.32.4" flutter_localizations: dependency: transitive description: flutter @@ -329,7 +329,7 @@ packages: name: petitparser url: "https://pub.dartlang.org" source: hosted - version: "4.4.0" + version: "5.0.0" platform: dependency: transitive description: @@ -365,13 +365,6 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "2.1.0" - quiver: - dependency: transitive - description: - name: quiver - url: "https://pub.dartlang.org" - source: hosted - version: "3.0.1+1" shelf: dependency: transitive description: @@ -488,7 +481,7 @@ packages: name: toml url: "https://pub.dartlang.org" source: hosted - version: "0.12.0" + version: "0.13.1" typed_data: dependency: transitive description: @@ -558,7 +551,7 @@ packages: name: xml url: "https://pub.dartlang.org" source: hosted - version: "5.3.1" + version: "5.4.1" xml2json: dependency: transitive description: @@ -574,5 +567,5 @@ packages: source: hosted version: "3.1.0" sdks: - dart: ">=2.17.0-0 <3.0.0" + dart: ">=2.17.0 <3.0.0" flutter: ">=2.5.0" diff --git a/example/test/namespace_example_test.dart b/example/test/namespace_example_test.dart index 67acbe7..b12a429 100644 --- a/example/test/namespace_example_test.dart +++ b/example/test/namespace_example_test.dart @@ -1,4 +1,3 @@ -import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; import 'package:flutter_i18n_example/main.dart' as appmain; import 'package:flutter_test/flutter_test.dart'; diff --git a/lib/flutter_i18n.dart b/lib/flutter_i18n.dart index f43ed8e..4ff4ae6 100644 --- a/lib/flutter_i18n.dart +++ b/lib/flutter_i18n.dart @@ -1,6 +1,5 @@ import 'dart:async'; -import 'package:flutter/foundation.dart' as Foundation; import 'package:flutter/widgets.dart'; import 'package:flutter_i18n/loaders/file_translation_loader.dart'; import 'package:flutter_i18n/loaders/translation_loader.dart'; @@ -9,8 +8,6 @@ import 'package:flutter_i18n/utils/plural_translator.dart'; import 'package:flutter_i18n/utils/simple_translator.dart'; import 'package:intl/intl.dart' as intl; -import 'utils/message_printer.dart'; - export 'flutter_i18n_delegate.dart'; export 'loaders/e2e_file_translation_loader.dart'; export 'loaders/file_translation_loader.dart'; diff --git a/lib/flutter_i18n_delegate.dart b/lib/flutter_i18n_delegate.dart index 46d8230..e6363da 100644 --- a/lib/flutter_i18n_delegate.dart +++ b/lib/flutter_i18n_delegate.dart @@ -1,7 +1,6 @@ import 'dart:async'; import 'package:flutter/material.dart'; -import 'package:flutter_i18n/loaders/translation_loader.dart'; import 'package:flutter_i18n/utils/message_printer.dart'; import 'flutter_i18n.dart'; diff --git a/lib/loaders/e2e_file_translation_loader.dart b/lib/loaders/e2e_file_translation_loader.dart index e0c5ebe..2d514d9 100644 --- a/lib/loaders/e2e_file_translation_loader.dart +++ b/lib/loaders/e2e_file_translation_loader.dart @@ -1,6 +1,5 @@ import 'dart:async'; import 'dart:convert'; -import 'dart:typed_data'; import 'package:flutter/services.dart'; diff --git a/lib/loaders/file_translation_loader.dart b/lib/loaders/file_translation_loader.dart index b284b4e..27565eb 100644 --- a/lib/loaders/file_translation_loader.dart +++ b/lib/loaders/file_translation_loader.dart @@ -1,7 +1,6 @@ import 'dart:async'; import 'package:flutter/services.dart'; -import 'package:flutter/services.dart' show rootBundle; import 'package:flutter/widgets.dart'; import 'package:flutter_i18n/loaders/decoders/base_decode_strategy.dart'; import 'package:flutter_i18n/loaders/decoders/json_decode_strategy.dart'; @@ -87,8 +86,8 @@ class FileTranslationLoader extends TranslationLoader implements IFileContent { V mapResult; if (result.containsKey(key)) { if (p1 is Map && p2 is Map) { - Map map1 = p1 as Map; - Map map2 = p2 as Map; + Map map1 = p1; + Map map2 = p2; mapResult = _deepMergeMaps(map1, map2) as V; } else { mapResult = p2; diff --git a/lib/loaders/namespace_file_translation_loader.dart b/lib/loaders/namespace_file_translation_loader.dart index 60eae3a..7665b58 100644 --- a/lib/loaders/namespace_file_translation_loader.dart +++ b/lib/loaders/namespace_file_translation_loader.dart @@ -1,5 +1,4 @@ import 'package:flutter/services.dart'; -import 'package:flutter/services.dart' show rootBundle; import 'package:flutter_i18n/loaders/file_translation_loader.dart'; import 'package:flutter_i18n/utils/message_printer.dart'; diff --git a/pubspec.lock b/pubspec.lock index 266754b..3792d01 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -146,14 +146,7 @@ packages: name: petitparser url: "https://pub.dartlang.org" source: hosted - version: "4.4.0" - quiver: - dependency: transitive - description: - name: quiver - url: "https://pub.dartlang.org" - source: hosted - version: "3.1.0" + version: "5.0.0" sky_engine: dependency: transitive description: flutter @@ -207,7 +200,7 @@ packages: name: toml url: "https://pub.dartlang.org" source: hosted - version: "0.12.0" + version: "0.13.1" typed_data: dependency: transitive description: @@ -228,14 +221,14 @@ packages: name: xml url: "https://pub.dartlang.org" source: hosted - version: "5.3.1" + version: "6.1.0" xml2json: dependency: "direct main" description: name: xml2json url: "https://pub.dartlang.org" source: hosted - version: "5.3.2" + version: "5.3.3" yaml: dependency: "direct main" description: @@ -244,4 +237,4 @@ packages: source: hosted version: "3.1.1" sdks: - dart: ">=2.17.0-0 <3.0.0" + dart: ">=2.17.0 <3.0.0" diff --git a/pubspec.yaml b/pubspec.yaml index b1dcdc9..ed2c6ee 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,6 +1,6 @@ name: flutter_i18n description: i18n made easy for Flutter. With flutter_i18n you can make your app international, using just a simple .json file! -version: 0.32.3 +version: 0.32.4 homepage: https://github.com/ilteoood/flutter_i18n issue_tracker: https://github.com/ilteoood/flutter_i18n/issues @@ -15,7 +15,7 @@ dependencies: yaml: ^3.1.0 xml2json: ^5.3.2 path: ^1.8.0 - toml: ^0.12.0 + toml: ^0.13.1 logging: ^1.0.2 http: ^0.13.4 diff --git a/test/loaders/file_translation_loader_test.dart b/test/loaders/file_translation_loader_test.dart index 3df7bac..3333cac 100644 --- a/test/loaders/file_translation_loader_test.dart +++ b/test/loaders/file_translation_loader_test.dart @@ -1,5 +1,3 @@ -import 'dart:math'; - import 'package:flutter/material.dart'; import 'package:flutter_i18n/flutter_i18n.dart'; import 'package:flutter_test/flutter_test.dart'; diff --git a/test/loaders/network_file_translation_loader_test.dart b/test/loaders/network_file_translation_loader_test.dart index f2acfd9..695a9ce 100644 --- a/test/loaders/network_file_translation_loader_test.dart +++ b/test/loaders/network_file_translation_loader_test.dart @@ -1,8 +1,6 @@ import 'package:flutter_i18n/flutter_i18n.dart'; import 'package:flutter_test/flutter_test.dart'; -import '../test_asset_bundle.dart'; - class CustomNetworkFileTranslationLoader extends NetworkFileTranslationLoader { CustomNetworkFileTranslationLoader({required baseUri}) : super(baseUri: baseUri);