<?php
$html_id = pxl_get_element_id($settings);
?>
<div class="pxl-menu-list pxl-menu-list1 <?php echo esc_attr($settings['pxl_animate']); ?>" data-wow-delay="<?php echo esc_attr($settings['pxl_animate_delay']); ?>ms">
    <div class="pxl-meta-inner <?php echo esc_attr($settings['style_list']); ?>">
        <div class="pxl-menu-list-on">
            <div class="pxl-menu-list-title pxl-item-title-on">
                <?php echo esc_attr($settings['title_on']); ?>
            </div>
            <div class="pxl-arrow">
                <i class="caseicon-caret-arrow-down"></i>
            </div>
        </div>
        <?php if(isset($settings['lists']) && !empty($settings['lists']) && count($settings['lists'])):
        $image_size = !empty($settings['img_size']) ? $settings['img_size'] : '30x30'; ?>
            <div class="pxl-menu-list-list">
                <div class="pxl-list-inner">
                    <?php foreach ($settings['lists'] as $key => $value):
                        $link_key = $widget->get_repeater_setting_key( 'link', 'value', $key );
                        if ( ! empty( $value['link']['url'] ) ) {
                            $widget->add_render_attribute( $link_key, 'href', $value['link']['url'] );

                            if ( $value['link']['is_external'] ) {
                                $widget->add_render_attribute( $link_key, 'target', '_blank' );
                            }

                            if ( $value['link']['nofollow'] ) {
                                $widget->add_render_attribute( $link_key, 'rel', 'nofollow' );
                            }
                        }
                        $link_attributes = $widget->get_render_attribute_string( $link_key ); 
                        ?>
                        <div class="pxl-item">
                            <a class="pxl-link" <?php echo implode( ' ', [ $link_attributes ] ); ?>></a>
                            <div class="pxl-item--title">
                                <span>
                                    <?php echo pxl_print_html($value['title'])?>
                                </span>
                            </div>
                        </div>
                    <?php endforeach; ?>
                </div>
            </div>
        <?php endif; ?>
    </div>
</div>