<?php

namespace App\DTOs;

final readonly class WebsiteBrandSignals
{
    public function __construct(
        public string $url,
        public string $summaryText,
        public ?string $headerColor = null,
        public ?string $headerBackgroundColor = null,
        public ?string $exactLogoSvg = null,
        public ?string $logoPublicUrl = null,
        public ?string $faviconUrl = null,
        public ?string $logoImagePath = null,
        public ?string $logoImageMime = null,
        public ?string $fontFamily = null,
        public ?string $fontStylesheetUrl = null,
    ) {}

    public function hasHeaderColor(): bool
    {
        return filled($this->headerColor);
    }

    public function hasHeaderBackgroundColor(): bool
    {
        return filled($this->headerBackgroundColor);
    }

    public function hasLogoImage(): bool
    {
        return $this->logoImagePath !== null;
    }

    public function hasExactLogoSvg(): bool
    {
        return filled($this->exactLogoSvg);
    }

    public function hasLogoPublicUrl(): bool
    {
        return filled($this->logoPublicUrl);
    }

    public function hasFaviconUrl(): bool
    {
        return filled($this->faviconUrl);
    }

    public function hasFontFamily(): bool
    {
        return filled($this->fontFamily);
    }

    public function hasFontStylesheetUrl(): bool
    {
        return filled($this->fontStylesheetUrl);
    }
}
