refactor(#78): Renommer assets images pour usage générique
Renommage des assets pour permettre leur utilisation aussi bien pour les boutons que pour les champs : **Images renommées :** - input_field_bg.png → bg_beige.png - input_field_jaune.png → bg_yellow.png - input_field_lavande.png → bg_lavender.png - btn_green.png → bg_green.png **Fichiers mis à jour (8) :** - custom_app_text_field.dart (champs de formulaire) - custom_navigation_button.dart (nouveau widget boutons) - base_form_screen.dart (structure de page) - login_screen.dart - change_password_dialog.dart - am_register_step4_screen.dart - parent_register_step5_screen.dart - summary_screen.dart **Avantages :** ✅ Noms génériques et cohérents ✅ Réutilisabilité boutons ET champs ✅ Maintenance facilitée Référence: #78 Co-authored-by: Cursor <cursoragent@cursor.com>
|
Before Width: | Height: | Size: 510 KiB After Width: | Height: | Size: 510 KiB |
|
Before Width: | Height: | Size: 181 KiB After Width: | Height: | Size: 181 KiB |
|
Before Width: | Height: | Size: 84 KiB After Width: | Height: | Size: 84 KiB |
|
Before Width: | Height: | Size: 67 KiB After Width: | Height: | Size: 67 KiB |
@ -78,7 +78,7 @@ class _AmRegisterStep4ScreenState extends State<AmRegisterStep4Screen> {
|
|||||||
const SizedBox(height: 40),
|
const SizedBox(height: 40),
|
||||||
|
|
||||||
ImageButton(
|
ImageButton(
|
||||||
bg: 'assets/images/btn_green.png',
|
bg: 'assets/images/bg_green.png',
|
||||||
text: 'Soumettre ma demande',
|
text: 'Soumettre ma demande',
|
||||||
textColor: const Color(0xFF2D6A4F),
|
textColor: const Color(0xFF2D6A4F),
|
||||||
width: 350,
|
width: 350,
|
||||||
|
|||||||
@ -242,7 +242,7 @@ class _LoginPageState extends State<LoginScreen> {
|
|||||||
child: _isLoading
|
child: _isLoading
|
||||||
? const CircularProgressIndicator()
|
? const CircularProgressIndicator()
|
||||||
: ImageButton(
|
: ImageButton(
|
||||||
bg: 'assets/images/btn_green.png',
|
bg: 'assets/images/bg_green.png',
|
||||||
width: 300,
|
width: 300,
|
||||||
height: 40,
|
height: 40,
|
||||||
text: 'Se connecter',
|
text: 'Se connecter',
|
||||||
|
|||||||
@ -87,7 +87,7 @@ class _ParentRegisterStep5ScreenState extends State<ParentRegisterStep5Screen> {
|
|||||||
_buildMotivationCard(context, registrationData.motivationText),
|
_buildMotivationCard(context, registrationData.motivationText),
|
||||||
const SizedBox(height: 40),
|
const SizedBox(height: 40),
|
||||||
ImageButton(
|
ImageButton(
|
||||||
bg: 'assets/images/btn_green.png',
|
bg: 'assets/images/bg_green.png',
|
||||||
text: 'Soumettre ma demande',
|
text: 'Soumettre ma demande',
|
||||||
textColor: const Color(0xFF2D6A4F),
|
textColor: const Color(0xFF2D6A4F),
|
||||||
width: 350,
|
width: 350,
|
||||||
|
|||||||
@ -265,7 +265,7 @@ class _ChangePasswordDialogState extends State<ChangePasswordDialog> {
|
|||||||
child: _isLoading
|
child: _isLoading
|
||||||
? const CircularProgressIndicator()
|
? const CircularProgressIndicator()
|
||||||
: ImageButton(
|
: ImageButton(
|
||||||
bg: 'assets/images/btn_green.png',
|
bg: 'assets/images/bg_green.png',
|
||||||
width: 250,
|
width: 250,
|
||||||
height: 40,
|
height: 40,
|
||||||
text: 'Changer le mot de passe',
|
text: 'Changer le mot de passe',
|
||||||
|
|||||||
@ -196,7 +196,7 @@ class BaseFormScreen extends StatelessWidget {
|
|||||||
// Bouton Précédent
|
// Bouton Précédent
|
||||||
HoverReliefWidget(
|
HoverReliefWidget(
|
||||||
child: ImageButton(
|
child: ImageButton(
|
||||||
bg: 'assets/images/btn_green.png',
|
bg: 'assets/images/bg_green.png',
|
||||||
text: 'Précédent',
|
text: 'Précédent',
|
||||||
textColor: Colors.white,
|
textColor: Colors.white,
|
||||||
onPressed: () => Navigator.pushNamed(context, previousRoute),
|
onPressed: () => Navigator.pushNamed(context, previousRoute),
|
||||||
@ -208,7 +208,7 @@ class BaseFormScreen extends StatelessWidget {
|
|||||||
// Bouton Suivant/Soumettre
|
// Bouton Suivant/Soumettre
|
||||||
HoverReliefWidget(
|
HoverReliefWidget(
|
||||||
child: ImageButton(
|
child: ImageButton(
|
||||||
bg: 'assets/images/btn_green.png',
|
bg: 'assets/images/bg_green.png',
|
||||||
text: submitButtonText ?? 'Suivant',
|
text: submitButtonText ?? 'Suivant',
|
||||||
textColor: Colors.white,
|
textColor: Colors.white,
|
||||||
onPressed: config.isReadonly ? onSubmit : () {
|
onPressed: config.isReadonly ? onSubmit : () {
|
||||||
|
|||||||
@ -54,12 +54,12 @@ class _CustomAppTextFieldState extends State<CustomAppTextField> {
|
|||||||
String getBackgroundImagePath() {
|
String getBackgroundImagePath() {
|
||||||
switch (widget.style) {
|
switch (widget.style) {
|
||||||
case CustomAppTextFieldStyle.lavande:
|
case CustomAppTextFieldStyle.lavande:
|
||||||
return 'assets/images/input_field_lavande.png';
|
return 'assets/images/bg_lavender.png';
|
||||||
case CustomAppTextFieldStyle.jaune:
|
case CustomAppTextFieldStyle.jaune:
|
||||||
return 'assets/images/input_field_jaune.png';
|
return 'assets/images/bg_yellow.png';
|
||||||
case CustomAppTextFieldStyle.beige:
|
case CustomAppTextFieldStyle.beige:
|
||||||
default:
|
default:
|
||||||
return 'assets/images/input_field_bg.png';
|
return 'assets/images/bg_beige.png';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -38,7 +38,7 @@ class SummaryScreen extends StatelessWidget {
|
|||||||
actions: [
|
actions: [
|
||||||
Center(
|
Center(
|
||||||
child: ImageButton(
|
child: ImageButton(
|
||||||
bg: 'assets/images/btn_green.png',
|
bg: 'assets/images/bg_green.png',
|
||||||
text: 'OK',
|
text: 'OK',
|
||||||
textColor: const Color(0xFF2D6A4F),
|
textColor: const Color(0xFF2D6A4F),
|
||||||
width: 150,
|
width: 150,
|
||||||
@ -89,7 +89,7 @@ class SummaryScreen extends StatelessWidget {
|
|||||||
const SizedBox(height: 20),
|
const SizedBox(height: 20),
|
||||||
|
|
||||||
ImageButton(
|
ImageButton(
|
||||||
bg: 'assets/images/btn_green.png',
|
bg: 'assets/images/bg_green.png',
|
||||||
text: submitButtonText,
|
text: submitButtonText,
|
||||||
textColor: const Color(0xFF2D6A4F),
|
textColor: const Color(0xFF2D6A4F),
|
||||||
width: 350,
|
width: 350,
|
||||||
|
|||||||