import type {
  ClassroomSupportAgeFilter,
  ClassroomSupportCategoryFilter,
  ClassroomSupportZoneFilter,
} from '@/shared/constants/classroomSupport';
import type { Strategy } from '@/shared/types/app';

export interface ClassroomSupportFilters {
  readonly searchQuery: string;
  readonly categoryFilter: ClassroomSupportCategoryFilter;
  readonly ageFilter: ClassroomSupportAgeFilter;
  readonly zoneFilter: ClassroomSupportZoneFilter;
  readonly showFavoritesOnly: boolean;
}

export interface ClassroomSupportPage {
  readonly strategies: readonly Strategy[];
  readonly filteredStrategies: readonly Strategy[];
  readonly favoriteStrategyIds: ReadonlySet<string>;
  readonly favoriteCount: number;
  readonly filters: ClassroomSupportFilters;
  readonly selectedStrategy: Strategy | null;
  readonly tryTodayStrategy: Strategy | null;
  readonly isLoading: boolean;
  readonly error: unknown;
  readonly setSearchQuery: (query: string) => void;
  readonly setCategoryFilter: (filter: ClassroomSupportCategoryFilter) => void;
  readonly setAgeFilter: (filter: ClassroomSupportAgeFilter) => void;
  readonly setZoneFilter: (filter: ClassroomSupportZoneFilter) => void;
  readonly toggleFavoritesOnly: () => void;
  readonly toggleFavorite: (id: string) => void;
  readonly selectStrategy: (strategy: Strategy) => void;
  readonly closeStrategy: () => void;
  readonly clearSearch: () => void;
}
