import { USE_REVIEWS_MOCK } from '../constants';
import type { ReviewsApi } from '../types';
import { reviewsClientApi } from './clientApi';
import { reviewsMockApi } from './mockApi';

/**
 * The selected `ReviewsApi` implementation — the single seam the hooks import. Selection is by config
 * (`USE_REVIEWS_MOCK`), never by scattered `if (mock)` checks. Mock-primary this phase (REQ-026 gaps +
 * admin-only moderation).
 */
export const reviewsApi: ReviewsApi = USE_REVIEWS_MOCK ? reviewsMockApi : reviewsClientApi;
