Enhance model and service documentation with detailed comments and descriptions

- Updated Group, Trip, User, and other model classes to include comprehensive documentation for better understanding and maintainability.
- Improved error handling and logging in services, including AuthService, ErrorService, and StorageService.
- Added validation and business logic explanations in ExpenseService and TripService.
- Refactored method comments to follow a consistent format across the codebase.
- Translated error messages and comments from French to English for consistency.
This commit is contained in:
Dayron
2025-10-30 15:56:17 +01:00
parent 1eeea6997e
commit 2faf37f145
46 changed files with 2656 additions and 220 deletions

View File

@@ -1,16 +1,35 @@
import 'package:flutter/material.dart';
/// A reusable error display component.
///
/// This widget provides a consistent way to display error messages throughout
/// the application. It supports customizable titles, messages, icons, and
/// action buttons for retry and close operations.
class ErrorContent extends StatelessWidget {
/// The error title to display
final String title;
/// The error message to display
final String message;
/// Optional callback for retry action
final VoidCallback? onRetry;
/// Optional callback for close action
final VoidCallback? onClose;
/// Icon to display with the error
final IconData icon;
/// Color of the error icon
final Color? iconColor;
/// Creates a new [ErrorContent] widget.
///
/// [message] is required, other parameters are optional with sensible defaults.
const ErrorContent({
super.key,
this.title = 'Une erreur est survenue',
this.title = 'An error occurred',
required this.message,
this.onRetry,
this.onClose,