<?php
/**
 * Render: bw/co-organizers.
 *
 * @var array $attributes Block attributes.
 *
 * @package Kadence-Child
 */

defined( 'ABSPATH' ) || exit;

$organizers = pv_get_partner_posts( 'organizer', isset( $attributes['year'] ) ? (string) $attributes['year'] : '' );
if ( ! $organizers ) {
    return;
}
?>
<div <?php echo get_block_wrapper_attributes( array( 'class' => 'pv-organizers' ) ); // phpcs:ignore WordPress.Security.EscapeOutput ?>>
    <ul class="pv-partner-logos pv-partner-logos--row">
        <?php foreach ( $organizers as $post_item ) {
            echo pv_render_partner_logo( $post_item ); // phpcs:ignore WordPress.Security.EscapeOutput -- escaped in component.
        } ?>
    </ul>
</div>
