add_section('bigmart_social_icons_section', array( 'title' => esc_html__('Social Icons', 'bigmart'), 'description' => esc_html__('Add social icons for the header', 'bigmart'), )); /** Social Icons */ $wp_customize->add_setting('bigmart_social_icons', array( 'sanitize_callback' => 'bigmart_sanitize_repeater', 'default' => json_encode(array( array( 'icon' => 'icofont-facebook', 'link' => '#', 'enable' => 'on' ), array( 'icon' => 'icofont-twitter', 'link' => '#', 'enable' => 'on' ), array( 'icon' => 'icofont-instagram', 'link' => '#', 'enable' => 'on' ), array( 'icon' => 'icofont-youtube', 'link' => '#', 'enable' => 'on' ) )) )); $wp_customize->add_control(new Bigmart_Repeater($wp_customize, 'bigmart_social_icons', array( 'label' => esc_html__('Add Social Link', 'bigmart'), 'section' => 'bigmart_social_icons_section', 'box_label' => esc_html__('Social Links', 'bigmart'), 'add_label' => esc_html__('Add New', 'bigmart'), ), array( 'icon' => array( 'type' => 'icon', 'label' => esc_html__('Select Icon', 'bigmart'), 'default' => 'icofont-facebook' ), 'link' => array( 'type' => 'text', 'label' => esc_html__('Add Link', 'bigmart'), 'default' => '' ), 'enable' => array( 'type' => 'toggle', 'label' => esc_html__('Enable', 'bigmart'), 'default' => 'yes' ) )));