import type { DriversLeaderboardDto } from '../dtos';
import type { DriverLeaderboardViewModel } from '../view-models';

/**
 * Drivers Leaderboard Presenter
 * Transforms DriversLeaderboardDto to DriverLeaderboardViewModel
 */
export class DriversLeaderboardPresenter {
  present(dto: DriversLeaderboardDto, previousDrivers?: any): DriverLeaderboardViewModel {
    return new DriverLeaderboardViewModel(dto as any, previousDrivers);
  }
}

// Legacy functional export for backward compatibility
export const presentDriversLeaderboard = (dto: DriversLeaderboardDto, previousDrivers?: any): DriverLeaderboardViewModel => {
  const presenter = new DriversLeaderboardPresenter();
  return presenter.present(dto, previousDrivers);
};