Локализация платформонезависимой части приложения
This commit is contained in:
43
lib/strings.dart
Normal file
43
lib/strings.dart
Normal file
@@ -0,0 +1,43 @@
|
||||
import 'package:intl/intl.dart';
|
||||
import 'package:flutter/widgets.dart';
|
||||
import 'package:sprintf/sprintf.dart';
|
||||
|
||||
class Strings extends LocaleQueryData {
|
||||
|
||||
static Strings of(BuildContext context) {
|
||||
return LocaleQuery.of(context);
|
||||
}
|
||||
|
||||
static final Strings instance = new Strings();
|
||||
|
||||
String confirmPurchase(String val) {
|
||||
return sprintf(Intl.message('confirm_purchase'), val);
|
||||
}
|
||||
|
||||
String purchaseCompleted(String val) {
|
||||
return sprintf(Intl.message('purchase_complite'), val);
|
||||
}
|
||||
|
||||
String idStore() => Intl.message('ID_Store');
|
||||
String signUp() => Intl.message('sign_up');
|
||||
String registration() => Intl.message('registration');
|
||||
String specifyDinStore() => Intl.message('specify_din_store');
|
||||
String confirmation() => Intl.message('confirmation');
|
||||
String askChangeStore() => Intl.message('ask_change_store');
|
||||
String yes() => Intl.message('yes');
|
||||
String no() => Intl.message('no');
|
||||
String requestSentWaitActivation() => Intl.message('request_sent_wait_activ');
|
||||
String refreshActivationStatus() => Intl.message('update_activ_status');
|
||||
String appActivated() => Intl.message('app_activ');
|
||||
String completeRegistration() => Intl.message('complite_activ');
|
||||
String cardScanner() => Intl.message('card_scaner');
|
||||
String userName() => Intl.message('user_name');
|
||||
String card() => Intl.message('card');
|
||||
String reward() => Intl.message('reward');
|
||||
String sum() => Intl.message('sum');
|
||||
String carryingPurchase() => Intl.message('carry_purchase');
|
||||
String completePurchase() => Intl.message('complite_purchase');
|
||||
String scan() => Intl.message('scan');
|
||||
String buyer() => Intl.message('buyer');
|
||||
String idNotFound() => Intl.message('ID_not_found');
|
||||
}
|
||||
Reference in New Issue
Block a user