Files
base_flutter/lib/features/auth/presentation/providers/auth_state.dart
2025-09-26 20:54:32 +07:00

13 lines
526 B
Dart

import 'package:freezed_annotation/freezed_annotation.dart';
import '../../domain/entities/user.dart';
part 'auth_state.freezed.dart';
@freezed
class AuthState with _$AuthState {
const factory AuthState.initial() = AuthStateInitial;
const factory AuthState.loading() = AuthStateLoading;
const factory AuthState.authenticated(User user) = AuthStateAuthenticated;
const factory AuthState.unauthenticated([String? message]) = AuthStateUnauthenticated;
const factory AuthState.error(String message) = AuthStateError;
}