mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2024-12-25 04:59:33 +00:00
20 lines
527 B
Dart
20 lines
527 B
Dart
import 'package:mobx/mobx.dart';
|
|
|
|
part 'authentication_store.g.dart';
|
|
|
|
class AuthenticationStore = AuthenticationStoreBase with _$AuthenticationStore;
|
|
|
|
enum AuthenticationState { uninitialized, installed, allowed }
|
|
|
|
abstract class AuthenticationStoreBase with Store {
|
|
AuthenticationStoreBase() : state = AuthenticationState.uninitialized;
|
|
|
|
@observable
|
|
AuthenticationState state;
|
|
|
|
@action
|
|
void installed() => state = AuthenticationState.installed;
|
|
|
|
@action
|
|
void allowed() => state = AuthenticationState.allowed;
|
|
}
|