2a35fe5532
- Collapsible search in notes and tasks: magnifying glass in AppBar expands to a text field inline; close button resets the filter - Offline capture queue: failed quick-captures (NetworkException) are persisted to SharedPreferences and retried automatically on next successful submit or app start; badge shows pending count - App icon: book-with-sparkle logo from FabledAssistant SVG rendered at all Android densities with adaptive icon (indigo #6366f1 bg) - Dark mode subtitle fix: use colorScheme.onSurfaceVariant for note preview and conversation timestamp text - Remove swipe-to-delete (accidental deletions); long-press remains - Chat: SSE streaming reliability, polling fallback, title patching - Settings: theme toggle (system/light/dark) persisted to prefs - Notes: delete button in edit screen; body preview in list - Tasks: fix delete dialog context; description search support Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
63 lines
1.9 KiB
Dart
63 lines
1.9 KiB
Dart
import 'package:cookie_jar/cookie_jar.dart';
|
|
import 'package:dio/dio.dart';
|
|
import 'package:flutter_riverpod/flutter_riverpod.dart';
|
|
|
|
import '../data/api/api_client.dart';
|
|
import '../data/api/auth_api.dart';
|
|
import '../data/api/chat_api.dart';
|
|
import '../data/api/notes_api.dart';
|
|
import '../data/api/quick_capture_api.dart';
|
|
import '../data/api/tasks_api.dart';
|
|
import '../data/repositories/auth_repository.dart';
|
|
import '../data/repositories/chat_repository.dart';
|
|
import '../data/repositories/notes_repository.dart';
|
|
import '../data/repositories/tasks_repository.dart';
|
|
import 'settings_provider.dart';
|
|
|
|
final cookieJarProvider = Provider<PersistCookieJar>((ref) {
|
|
final cookiesPath = ref.watch(cookiesPathProvider);
|
|
return buildCookieJar(cookiesPath);
|
|
});
|
|
|
|
final dioProvider = Provider<Dio>((ref) {
|
|
final url = ref.watch(serverUrlProvider) ?? '';
|
|
final jar = ref.watch(cookieJarProvider);
|
|
return buildDio(url, jar);
|
|
});
|
|
|
|
final authApiProvider = Provider<AuthApi>((ref) {
|
|
return AuthApi(ref.watch(dioProvider));
|
|
});
|
|
|
|
final notesApiProvider = Provider<NotesApi>((ref) {
|
|
return NotesApi(ref.watch(dioProvider));
|
|
});
|
|
|
|
final tasksApiProvider = Provider<TasksApi>((ref) {
|
|
return TasksApi(ref.watch(dioProvider));
|
|
});
|
|
|
|
final chatApiProvider = Provider<ChatApi>((ref) {
|
|
return ChatApi(ref.watch(dioProvider));
|
|
});
|
|
|
|
final quickCaptureApiProvider = Provider<QuickCaptureApi>((ref) {
|
|
return QuickCaptureApi(ref.watch(dioProvider));
|
|
});
|
|
|
|
final authRepositoryProvider = Provider<AuthRepository>((ref) {
|
|
return AuthRepository(ref.watch(authApiProvider));
|
|
});
|
|
|
|
final notesRepositoryProvider = Provider<NotesRepository>((ref) {
|
|
return NotesRepository(ref.watch(notesApiProvider));
|
|
});
|
|
|
|
final tasksRepositoryProvider = Provider<TasksRepository>((ref) {
|
|
return TasksRepository(ref.watch(tasksApiProvider));
|
|
});
|
|
|
|
final chatRepositoryProvider = Provider<ChatRepository>((ref) {
|
|
return ChatRepository(ref.watch(chatApiProvider));
|
|
});
|