mirror of
https://github.com/gabehf/Fladder.git
synced 2026-03-09 07:28:14 -07:00
feature: Adds schemeVariants to color options (#109)
Co-authored-by: PartyDonut <PartyDonut@users.noreply.github.com>
This commit is contained in:
parent
98130f953e
commit
0b0cd3a557
11 changed files with 143 additions and 16 deletions
|
|
@ -1,9 +1,11 @@
|
|||
import 'package:flutter/material.dart';
|
||||
|
||||
import 'package:flutter_riverpod/flutter_riverpod.dart';
|
||||
|
||||
import 'package:fladder/models/settings/client_settings_model.dart';
|
||||
import 'package:fladder/providers/shared_provider.dart';
|
||||
import 'package:fladder/util/custom_color_themes.dart';
|
||||
import 'package:fladder/util/debouncer.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_riverpod/flutter_riverpod.dart';
|
||||
|
||||
final clientSettingsProvider = StateNotifierProvider<ClientSettingsNotifier, ClientSettingsModel>((ref) {
|
||||
return ClientSettingsNotifier(ref);
|
||||
|
|
@ -51,4 +53,7 @@ class ClientSettingsNotifier extends StateNotifier<ClientSettingsModel> {
|
|||
void setSyncPath(String? path) => state = state.copyWith(syncPath: path);
|
||||
|
||||
void update(Function(ClientSettingsModel current) value) => state = value(state);
|
||||
|
||||
void setSchemeVariant(DynamicSchemeVariant? type) =>
|
||||
state = state.copyWith(schemeVariant: type ?? state.schemeVariant);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue