Skip to content

Commit

Permalink
2.0.1 preps
Browse files Browse the repository at this point in the history
  • Loading branch information
Victor Kachalov committed Nov 18, 2020
1 parent 6e5b270 commit 7ab3d19
Show file tree
Hide file tree
Showing 8 changed files with 11 additions and 17 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## [2.0.1] - 18.11.2020

* Minor fixes

## [2.0.0] - 16.11.2020

* New feature: Translation. Support of Yandex, Google and Microsoft Translator APIs
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ String extensions for localization and a translation utility
- Add this to your package's pubspec.yaml file:
``` Dart
dependencies:
localized: ^2.0.0
localized: ^2.0.1
```
- Get dependencies

Expand Down
3 changes: 1 addition & 2 deletions bin/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,10 @@ import 'dart:io';

import 'package:args/args.dart' show ArgParser;
import 'package:http/http.dart' as http;
import 'package:localized/constants.dart';
import 'package:translator/translator.dart';
import 'package:tuple/tuple.dart';

import 'constants.dart';

/// Supported translation providers
/// GoogleTest should be on the first place
///
Expand Down
2 changes: 1 addition & 1 deletion example/assets/i18n/ru.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"title":"Домашняя страница","amount_of_clicks":"Раз вы нажали кнопку:","increase":"Увеличить"}
{"title":"Главная страница","amount_of_clicks":"Времена, когда вы нажали на кнопку:","increase":"Увеличить"}
File renamed without changes.
8 changes: 3 additions & 5 deletions lib/localized.dart
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
library localized;

import 'dart:convert';
import 'dart:io' show Platform;

import 'package:flutter/services.dart';
import 'package:flutter/widgets.dart';
import 'package:flutter_localizations/flutter_localizations.dart';

import 'constants.dart';

/// A [Localized] extension for [String]
///
Expand Down Expand Up @@ -76,9 +76,7 @@ class _LocalizationServiceDelegate

@override
bool isSupported(Locale locale) => locales == null
? (Platform.isIOS
? kCupertinoSupportedLanguages.contains(locale.languageCode)
: kMaterialSupportedLanguages.contains(locale.languageCode))
? kSupportedLanguages.contains(locale.languageCode)
: locales.map((e) => e.languageCode).contains(locale.languageCode);

@override
Expand Down
5 changes: 0 additions & 5 deletions pubspec.lock
Original file line number Diff line number Diff line change
Expand Up @@ -76,11 +76,6 @@ packages:
description: flutter
source: sdk
version: "0.0.0"
flutter_localizations:
dependency: "direct main"
description: flutter
source: sdk
version: "0.0.0"
flutter_test:
dependency: "direct dev"
description: flutter
Expand Down
4 changes: 1 addition & 3 deletions pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: localized
description: String extensions for different localizations and a translation utility without additional efforts.
version: 2.0.0
version: 2.0.1
homepage: https://github.com/VictorKachalov/localized

environment:
Expand All @@ -10,8 +10,6 @@ environment:
dependencies:
flutter:
sdk: flutter
flutter_localizations:
sdk: flutter
path_provider: ^1.6.21
args: ^1.6.0
tuple: ^1.0.3
Expand Down

0 comments on commit 7ab3d19

Please sign in to comment.