<?php
    $iconsReplace = [
        'whatsapp' => Theme::asset()->url('images/whatsapp-white.svg'),
        'telegram' => Theme::asset()->url('images/telegram-white.svg')
    ]
?>
<!--Widget social-->
<div class="sidebar-widget widget-social-network mb-30">
    <div class="widget-header position-relative mb-20 pb-10">
        <h5 class="widget-title mb-10"><?php echo e(!empty($config['title']) ? $config['title'] : __('Follow Us')); ?></h5>
        <div class="bt-1 border-color-1"></div>
    </div>
    <?php
        $socials = [];
        foreach (json_decode(theme_option('social_links'), true) as $socialLink) {
            if(!empty($socialLink[2]['value'])) {
            $socials[] = $socialLink;
            }
        }
    ?>
    <div class="social-network">
        <?php $__currentLoopData = $socials; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $socialLink): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
            <?php $socialIcon = strtolower($socialLink[1]['value']) ?>

            <?php if($loop->index % 2 == 0): ?>
                <div class="follow-us d-flex align-items-center">
                    <?php endif; ?>
                    <a class="follow-us-<?php echo e($socialIcon); ?> clearfix  <?php if($loop->index % 2 == 0): ?> mr-5 <?php else: ?> ml-5 <?php endif; ?> mb-10"
                       href="<?php echo e($socialLink[2]['value']); ?>" target="_blank">
                        <div class="social-icon">
                            <?php if( isset($iconsReplace[$socialIcon])): ?>
                                <i class="ti-<?php echo e($socialIcon); ?> mr-5 v-align-space">
                                    <img src="<?php echo e($iconsReplace[$socialIcon]); ?>" width="20"
                                         alt="whatapps icon">
                                </i>
                                <i class="ti-<?php echo e($socialIcon); ?> mr-5 v-align-space nth-2">
                                    <img src="<?php echo e($iconsReplace[$socialIcon]); ?>" width="20"
                                         alt="whatapps icon">
                                </i>
                            <?php else: ?>
                                <i class="ti-<?php echo e($socialIcon); ?> mr-5 v-align-space"></i>
                                <i class="ti-<?php echo e($socialIcon); ?> mr-5 v-align-space nth-2"></i>
                            <?php endif; ?>
                        </div>
                        <span class="social-name"><?php echo e($socialLink[0]['value']); ?></span>
                        <?php if(!empty($socialLink[3]['value'])): ?>
                            <?php if($socialLink[3]['value'] > 1000): ?>
                                <span class="social-count counter-number">
                                    <?php echo e((int)((int) $socialLink[3]['value']) / 1000); ?>

                                </span>
                                <span class="social-count">K</span>
                            <?php else: ?>
                                <span class="social-count counter-number"><?php echo e($socialLink[3]['value']); ?></span>
                            <?php endif; ?>
                        <?php endif; ?>
                    </a>

                    <?php if($loop->index % 2 == 1 || count($socials) == $loop->index + 1): ?>
                </div>
            <?php endif; ?>
        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
    </div>
</div>
<?php /**PATH C:\Users\Admin\Documents\UltraNews v4.0.0 Nulled\UltraNews v4.0.0 Nulled\ultra-news\platform\themes/ultra/partials/components/sidebar-social.blade.php ENDPATH**/ ?>