@twillBlockTitle('Video') @twillBlockIcon('video') @formField('input', [ 'name' => 'title', 'label' => 'Título', 'translated' => true, ]) @formField('input', [ 'name' => 'description', 'type' => 'textarea', 'label' => 'Descripción', 'translated' => true, ]) @formField('select', [ 'name' => 'source', 'label' => 'Fuente', 'default' => 'youtube', 'required' => true, 'options' => [ [ 'value' => 'self_hosted', 'label' => 'Video guardado' ], [ 'value' => 'youtube', 'label' => 'Youtube' ], [ 'value' => 'vimeo', 'label' => 'Vimeo' ], ] ]) @formConnectedFields([ 'fieldName' => 'source', 'fieldValues' => 'youtube', 'renderForBlocks' => true ]) @formField('input', [ 'name' => 'url', 'label' => 'URL', 'required' => true, ]) @endformConnectedFields @formConnectedFields([ 'fieldName' => 'source', 'fieldValues' => 'vimeo', 'renderForBlocks' => true ]) @formField('input', [ 'name' => 'url', 'label' => 'URL', 'required' => true, ]) @endformConnectedFields @formConnectedFields([ 'fieldName' => 'source', 'fieldValues' => 'self_hosted', 'renderForBlocks' => true ]) @formField('files', [ 'name' => 'video__full_width_section', 'label' => 'Video', 'required' => true, ]) @endformConnectedFields @formField('medias', [ 'name' => 'image__video_thumbnail', 'label' => 'Thumbnail (miniatura) del video', 'required' => true, ])