mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2024-11-01 09:57:46 +00:00
50b5ebc622
* New price API * Fix test app package id * Fix workflow * change environment variable to use pr number [skip ci] * Fix un-needed padding * Fix raw value for usdtSol * Remove duplicate fetching for balance and transactions at start [skip ci] * Fix address validation of spl tokens * Add Service Status * Update lib/src/widgets/service_status_tile.dart Co-authored-by: Konstantin Ullrich <konstantinullrich12@gmail.com> * Update lib/src/widgets/services_updates_widget.dart Co-authored-by: Konstantin Ullrich <konstantinullrich12@gmail.com> * Update monero version * update sodium script * Change automatic priority fee rate * New versions [skip ci] * Update monero version * Temp remove split per abi * Specifically build monero.com * Revert monero dependencies trial fix * Update Monero Fix Monero Automatic Priority * Fix android script * Fix build_monero.sh android Add svg notification icon * trial 1 * trial 2 * trial 3 * trial 4 * Trial 5 * Trial * revert --------- Co-authored-by: Konstantin Ullrich <konstantinullrich12@gmail.com>
35 lines
644 B
Dart
35 lines
644 B
Dart
import 'package:mobx/mobx.dart';
|
|
|
|
part 'desktop_sidebar_view_model.g.dart';
|
|
|
|
enum SidebarItem {
|
|
dashboard,
|
|
transactions,
|
|
status,
|
|
support,
|
|
settings,
|
|
}
|
|
|
|
class DesktopSidebarViewModel = DesktopSidebarViewModelBase with _$DesktopSidebarViewModel;
|
|
|
|
abstract class DesktopSidebarViewModelBase with Store {
|
|
DesktopSidebarViewModelBase();
|
|
|
|
@observable
|
|
SidebarItem currentPage = SidebarItem.dashboard;
|
|
|
|
@action
|
|
void onPageChange(SidebarItem item) {
|
|
if (currentPage == item) {
|
|
resetSidebar();
|
|
|
|
return;
|
|
}
|
|
currentPage = item;
|
|
}
|
|
|
|
@action
|
|
void resetSidebar() {
|
|
currentPage = SidebarItem.dashboard;
|
|
}
|
|
}
|