import {
  type LearningCertificateAlignment,
  type LearningCertificateColor,
  type LearningCertificateType,
} from 'src/pages/dashboard/Learning/Settings/Certificates/types';

/** A resolved signature slot ready for display in the certificate preview. */
export type CertificateSignatureDisplay = {
  imageUrl: string | undefined;
  primaryText: string;
  secondaryText: string;
};

/** A resolved logo slot ready for display in the certificate preview. */
export type CertificateLogoDisplay = {
  imageUrl: string | undefined;
};

/** Props for CertificatePreviewCanvas — purely presentational, no form/context access. */
export type CertificatePreviewProps = {
  templateId: LearningCertificateType;
  /** The accent color enum value, used for exact Figma paint lookup. */
  accentColor: LearningCertificateColor;
  /** Resolved hex color for the accent, used for COMMUNITY dynamic color. */
  accentHex: string;
  /** Full name of the certificate recipient (firstName + lastName). */
  recipientName: string;
  headingTitle: string;
  subtitle: string;
  description: string;
  textAlignment: LearningCertificateAlignment;
  signaturesEnabled: boolean;
  signatures: CertificateSignatureDisplay[];
  logosEnabled: boolean;
  logos: CertificateLogoDisplay[];
  /** Background image URL for the custom template. */
  backgroundImageUrl: string | undefined;
};
