<?php
/**
 * Ticker news template two
 * 
 * @package One Newspaper
 * @since 1.0.0
 */
use OneNewspaper\CustomizerDefault as ONP;
$ticker_query = new WP_Query( $args );
if( $ticker_query->have_posts() ) :
    $ticker_news_thumbnail_option = ONP\one_newspaper_get_customizer_option( 'ticker_news_thumbnail_option' );
    while( $ticker_query->have_posts() ) : $ticker_query->the_post();
    ?>
        <li class="ticker-item one-newspaper-card">
            <figure class="feature_image">
                <?php if( has_post_thumbnail() && $ticker_news_thumbnail_option ) : ?>
                    <a href="<?php the_permalink(); ?>" title="<?php the_title_attribute(); ?>">
                        <?php
                            the_post_thumbnail('one-newspaper-thumb', array(
                                'title' => the_title_attribute(array(
                                    'echo'  => false
                                ))
                            ));
                        ?>
                    </a>
                <?php endif; ?>
            </figure>
            <div class="title-wrap">
                <h2 class="post-title"><a href="<?php the_permalink(); ?>" title="<?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2>
                <?php one_newspaper_posted_on(); ?>
            </div>
        </li>
    <?php
    endwhile;
    wp_reset_postdata();
endif;