174 lines
4.7 KiB
Dart
174 lines
4.7 KiB
Dart
import 'dart:convert';
|
|
import 'package:flutter/material.dart';
|
|
import 'package:flutter/services.dart';
|
|
|
|
class LanguageProvider extends ChangeNotifier {
|
|
Map<String, dynamic> languageData = {
|
|
"de": {
|
|
"general": {
|
|
"timeOutTitle": "Bist du noch da?",
|
|
"timeOutContent": "In 30 Sekunden wird deine Bewertung verworfen",
|
|
"timeOutButton": "Ich bin da!"
|
|
},
|
|
"textfield": "Dein Feedback",
|
|
"pageAmbiente": {
|
|
"question1": "Frage1*",
|
|
"question2": "Frage2*",
|
|
},
|
|
"pageAnmerkungen": {
|
|
"question1": "Frage1*",
|
|
"question2": "Frage2*",
|
|
},
|
|
"pageEssen": {
|
|
"question1": "Geschmack*",
|
|
"question2": "Qualität*",
|
|
},
|
|
"pageHome": {
|
|
"noTimePopupTitle": "Du kannst gerade nicht bewerten!",
|
|
"noTimePopupContent":
|
|
"Du kannst nur zu den Essenszeiten zwischen 11:30 und 14:30 bewerten!",
|
|
"noTimePopupButton": "OK"
|
|
},
|
|
"pageService": {
|
|
"question1": "Frage1*",
|
|
"question2": "Frage2*",
|
|
},
|
|
"pageSpecial": {
|
|
"question1": "*",
|
|
"question2": "Frage2*",
|
|
},
|
|
"navBar": {"0": "Essen", "1": "Service", "2": "Essenswünsche"},
|
|
"floating": {
|
|
"info": "* Pflichtfeld",
|
|
"return": "Absenden",
|
|
"delete": {
|
|
"title": "Bewertungen löschen",
|
|
"info": "Möchtest du alle Eingaben entfernen?",
|
|
"keep": "Behalten",
|
|
"del": "Löschen"
|
|
}
|
|
},
|
|
"send": {
|
|
"title": "Bestätigung",
|
|
"change": "Überarbeiten",
|
|
"apply": "Absenden",
|
|
"notRated": "Nicht bewertet"
|
|
}
|
|
},
|
|
"en": {
|
|
"general": {
|
|
"timeOutTitle": "Are you still there?",
|
|
"timeOutContent": "Your assessment will be discarded in 30 seconds",
|
|
"timeOutButton": "I'm here!"
|
|
},
|
|
"textfield": "Your Feedback",
|
|
"pageAmbiente": {
|
|
"question1": "Question1*",
|
|
"question2": "Question2*",
|
|
},
|
|
"pageAnmerkungen": {
|
|
"question1": "Question1*",
|
|
"question2": "Question2*",
|
|
},
|
|
"pageEssen": {
|
|
"question1": "Taste*",
|
|
"question2": "Quality*",
|
|
},
|
|
"pageHome": {
|
|
"noTimePopupTitle": "You cannot rate right now!",
|
|
"noTimePopupContent":
|
|
"You can only rate during meal times between 11:30 AM and 2:30 PM!",
|
|
"noTimePopupButton": "OK"
|
|
},
|
|
"pageService": {
|
|
"question1": "Question1*",
|
|
"question2": "Question2*",
|
|
},
|
|
"pageSpecial": {
|
|
"question1": "Question1*",
|
|
"question2": "Question2*",
|
|
},
|
|
"navBar": {"0": "Food", "1": "Service", "2": "Food Requests"},
|
|
"floating": {
|
|
"info": "* Required field",
|
|
"return": "Submit",
|
|
"delete": {
|
|
"title": "Delete Reviews",
|
|
"info": "Do you want to remove all entries?",
|
|
"keep": "Keep",
|
|
"del": "Delete"
|
|
}
|
|
},
|
|
"send": {
|
|
"title": "Confirmation",
|
|
"change": "Edit",
|
|
"apply": "Submit",
|
|
"notRated": "Not rated"
|
|
|
|
}
|
|
},
|
|
"fr": {
|
|
"general": {
|
|
"timeOutTitle": "Êtes-vous toujours là ?",
|
|
"timeOutContent": "Votre évaluation sera supprimée dans 30 secondes",
|
|
"timeOutButton": "Je suis là !"
|
|
},
|
|
"textfield": "Votre avis",
|
|
"pageAmbiente": {
|
|
"question1": "Question1*",
|
|
"question2": "Question2*",
|
|
},
|
|
"pageAnmerkungen": {
|
|
"question1": "Question1*",
|
|
"question2": "Question2*",
|
|
},
|
|
"pageEssen": {
|
|
"question1": "Goût*",
|
|
"question2": "Qualité*",
|
|
},
|
|
"pageHome": {
|
|
"noTimePopupTitle": "Vous ne pouvez pas évaluer pour le moment !",
|
|
"noTimePopupContent":
|
|
"Vous ne pouvez évaluer que pendant les heures de repas entre 11h30 et 14h30 !",
|
|
"noTimePopupButton": "D'ACCORD"
|
|
},
|
|
"pageService": {
|
|
"question1": "Question1*",
|
|
"question2": "Question2*",
|
|
},
|
|
"pageSpecial": {
|
|
"question1": "Question1*",
|
|
"question2": "Question2*",
|
|
},
|
|
"navBar": {
|
|
"0": "Nourriture",
|
|
"1": "Service",
|
|
"2": "Demandes De Nourriture"
|
|
},
|
|
"floating": {
|
|
"info": "* Champ obligatoire",
|
|
"return": "Envoyer",
|
|
"delete": {
|
|
"title": "Supprimer les avis",
|
|
"info": "Voulez-vous supprimer toutes les entrées ?",
|
|
"keep": "Garder",
|
|
"del": "Supprimer"
|
|
}
|
|
},
|
|
"send": {
|
|
"title": "Confirmation",
|
|
"change": "Modifier",
|
|
"apply": "Envoyer",
|
|
"notRated": "Non noté"
|
|
}
|
|
}
|
|
};
|
|
|
|
String language = "de";
|
|
|
|
void setLanguage(String newLanguage) {
|
|
language = newLanguage;
|
|
notifyListeners();
|
|
}
|
|
}
|