patch small issue with trad and theme
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
/// Entité métier représentant un Pokémon. Pure : aucun import Flutter / DB / API.
|
||||
class Pokemon {
|
||||
final String name;
|
||||
final String? nameFr;
|
||||
final String? nameEn;
|
||||
final int id;
|
||||
final PokemonType type1;
|
||||
final PokemonType? type2;
|
||||
@@ -9,11 +11,14 @@ class Pokemon {
|
||||
final int def;
|
||||
final int spd;
|
||||
final String? description;
|
||||
final String? descriptionEn;
|
||||
final bool isCaught;
|
||||
final bool isSeen;
|
||||
|
||||
const Pokemon({
|
||||
required this.name,
|
||||
this.nameFr,
|
||||
this.nameEn,
|
||||
required this.id,
|
||||
required this.type1,
|
||||
this.type2,
|
||||
@@ -22,6 +27,7 @@ class Pokemon {
|
||||
required this.def,
|
||||
required this.spd,
|
||||
this.description,
|
||||
this.descriptionEn,
|
||||
this.isCaught = false,
|
||||
this.isSeen = false,
|
||||
});
|
||||
@@ -37,6 +43,8 @@ class Pokemon {
|
||||
|
||||
Pokemon copyWith({
|
||||
String? name,
|
||||
String? nameFr,
|
||||
String? nameEn,
|
||||
int? id,
|
||||
PokemonType? type1,
|
||||
PokemonType? type2,
|
||||
@@ -45,11 +53,14 @@ class Pokemon {
|
||||
int? def,
|
||||
int? spd,
|
||||
String? description,
|
||||
String? descriptionEn,
|
||||
bool? isCaught,
|
||||
bool? isSeen,
|
||||
}) {
|
||||
return Pokemon(
|
||||
name: name ?? this.name,
|
||||
nameFr: nameFr ?? this.nameFr,
|
||||
nameEn: nameEn ?? this.nameEn,
|
||||
id: id ?? this.id,
|
||||
type1: type1 ?? this.type1,
|
||||
type2: type2 ?? this.type2,
|
||||
@@ -58,6 +69,7 @@ class Pokemon {
|
||||
def: def ?? this.def,
|
||||
spd: spd ?? this.spd,
|
||||
description: description ?? this.description,
|
||||
descriptionEn: descriptionEn ?? this.descriptionEn,
|
||||
isCaught: isCaught ?? this.isCaught,
|
||||
isSeen: isSeen ?? this.isSeen,
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user