<?php
declare(strict_types=1);

namespace WP_AUX\Entities\AuxCF\Fields\CustomContent\CaptionedMedia;

use AuxCF\Entities\Field\RadioFieldEntity;
use AuxCF\Entities\Field\Enum\ChoicesFieldLayoutEnum;
use AuxCF\Entities\Settings\Enum\OperatorEnum;

class CaptionedMediaTypeFieldEntity extends RadioFieldEntity
{
  public static string $name = 'captioned_media_type';
  public static array $replacesFields = ['captioned_media_media_switch'];
  protected string $label = 'Image or Video?';
  protected mixed $choices = [
    'image' => 'Image',
    'video' => 'Video',
  ];
  protected ChoicesFieldLayoutEnum $layout = ChoicesFieldLayoutEnum::Horizontal;

  protected array $initConditionalLogic = [
    [
      [ CaptionedMediaSwitchFieldEntity::class, OperatorEnum::EQUALS, '1' ],
    ]
  ];
}
