feat: Add FeedFilter model and begin feed filtering integration

This commit is contained in:
Patrick Britton 2026-02-17 10:27:31 -06:00
parent 961aa02eac
commit 62233d5892
2 changed files with 15 additions and 0 deletions

View file

@ -0,0 +1,13 @@
/// Filter options for the home feed
enum FeedFilter {
all('All Posts', null),
posts('Posts Only', 'post'),
quips('Quips Only', 'quip'),
chains('Chains Only', 'chain'),
beacons('Beacons Only', 'beacon');
final String label;
final String? typeValue;
const FeedFilter(this.label, this.typeValue);
}

View file

@ -3,6 +3,7 @@ import 'package:flutter_riverpod/flutter_riverpod.dart';
import '../../providers/api_provider.dart';
import '../../providers/feed_refresh_provider.dart';
import '../../models/post.dart';
import '../../models/feed_filter.dart';
import '../../theme/app_theme.dart';
import '../../widgets/sojorn_post_card.dart';
import '../../widgets/app_scaffold.dart';
@ -23,6 +24,7 @@ class _FeedPersonalScreenState extends ConsumerState<FeedPersonalScreen> {
bool _isLoading = false;
bool _hasMore = true;
String? _error;
FeedFilter _currentFilter = FeedFilter.all;
@override
void initState() {