feat: login api

This commit is contained in:
efrilm
2025-08-16 17:27:57 +07:00
parent 6019036cd7
commit 255b10d5a9
31 changed files with 2997 additions and 86 deletions
+18
View File
@@ -0,0 +1,18 @@
part of '../auth.dart';
@freezed
class Auth with _$Auth {
const Auth._();
const factory Auth({
required String token,
required DateTime expiresAt,
required User user,
}) = _Auth;
/// State kosong (misalnya untuk initial state di Bloc)
factory Auth.empty() => Auth(
token: '',
expiresAt: DateTime.fromMillisecondsSinceEpoch(0),
user: User.empty(),
);
}