import type { CategoryConfig } from '../components/CheckBoxGroup/CheckBoxGroup';
import type { BaseApiClient } from '../types/api';
import type { FetchStudentsByFiltersFunction } from './studentTypes';
export interface UseDynamicStudentFetchingOptions {
    apiClient?: BaseApiClient;
    fetchStudentsByFilters?: FetchStudentsByFiltersFunction;
    onError?: (error: Error) => void;
}
/**
 * Hook to handle dynamic student fetching based on category selections.
 *
 * This hook provides a `handleCategoriesChange` function that:
 * - Detects changes in school/series/class selections
 * - Fetches students only when these selections change (not when only students are toggled)
 * - Transforms fetched students into the correct format for CategoryConfig
 * - Handles errors gracefully
 *
 * @param setCategories - Function to update categories state
 * @param options - Configuration options
 * @returns Object with handleCategoriesChange function
 */
export declare function useDynamicStudentFetching(setCategories: (categories: CategoryConfig[]) => void, options?: UseDynamicStudentFetchingOptions): {
    handleCategoriesChange: (updatedCategories: CategoryConfig[]) => Promise<void>;
};
//# sourceMappingURL=useDynamicStudentFetching.d.ts.map