add offline mode - not yet functional really

This commit is contained in:
stopflock committed 2025-08-09 18:23:31 -05:00
1 parent cf8df39f1e
commit 000bb6c567
3 files changed
+39 -4

No files matched your search

@@ -0,0 +1,21 @@
import 'package:flutter/material.dart';
import 'package:provider/provider.dart';
import '../../app_state.dart';
class OfflineModeSection extends StatelessWidget {
const OfflineModeSection({super.key});
@override
Widget build(BuildContext context) {
final appState = context.watch<AppState>();
return ListTile(
leading: const Icon(Icons.wifi_off),
title: const Text('Offline Mode'),
subtitle: const Text('Disable all network requests except for local/offline areas.'),
trailing: Switch(
value: appState.offlineMode,
onChanged: (value) async => await appState.setOfflineMode(value),
),
);
}
}