feat(auth): Add OAuth providers and improve authentication flow
This commit is contained in:
@@ -1,8 +1,24 @@
|
||||
import 'package:flutter/foundation.dart';
|
||||
import 'package:freezed_annotation/freezed_annotation.dart';
|
||||
|
||||
import 'backend_config.dart';
|
||||
|
||||
part 'server_config.freezed.dart';
|
||||
part 'server_config.g.dart';
|
||||
|
||||
/// Container for passing server and backend config during authentication flow.
|
||||
@immutable
|
||||
class AuthFlowConfig {
|
||||
const AuthFlowConfig({required this.serverConfig, this.backendConfig});
|
||||
|
||||
/// The server configuration (URL, headers, etc.).
|
||||
final ServerConfig serverConfig;
|
||||
|
||||
/// The backend configuration (auth methods, features, etc.).
|
||||
/// May be null if not yet fetched.
|
||||
final BackendConfig? backendConfig;
|
||||
}
|
||||
|
||||
@freezed
|
||||
sealed class ServerConfig with _$ServerConfig {
|
||||
const factory ServerConfig({
|
||||
|
||||
Reference in New Issue
Block a user