add authentication with login form and token management
This commit is contained in:
@@ -28,3 +28,18 @@ export const statusLabels: Record<DeliveryStatus, string> = {
|
||||
new: 'Новое',
|
||||
delivered: 'Доставлено',
|
||||
};
|
||||
|
||||
// Auth types
|
||||
export interface LoginRequest {
|
||||
username: string;
|
||||
password: string;
|
||||
}
|
||||
|
||||
export interface LoginResponse {
|
||||
token: string;
|
||||
}
|
||||
|
||||
export interface User {
|
||||
id: string;
|
||||
username: string;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user