/**
 * SponsorLogoViewDataBuilder
 *
 * Transforms MediaBinaryDTO into SponsorLogoViewData for server-side rendering.
 * Deterministic; side-effect free; no HTTP calls.
 */

import { MediaBinaryDTO } from '@/lib/types/MediaBinaryDTO';
import { SponsorLogoViewData } from '@/lib/view-data/SponsorLogoViewData';

export class SponsorLogoViewDataBuilder {
  static build(apiDto: MediaBinaryDTO): SponsorLogoViewData {
    return {
      buffer: Buffer.from(apiDto.buffer).toString('base64'),
      contentType: apiDto.contentType,
    };
  }
}