register_section_type( 'Bosa_Customize_Section_Upsell' );
// Register sections.
$wp_customize->add_section(
new Bosa_Customize_Section_Upsell(
$wp_customize,
'theme_upsell',
array(
'title' => esc_html__( 'Bosa Pro', 'bosa' ),
'pro_text' => esc_html__( 'Upgrade To Pro', 'bosa' ),
'pro_url' => 'https:/keonthemes.com/downloads/bosa',
'priority' => 1,
)
)
);
}
add_action( 'customize_register', 'bosa_customize_register' );
/**
* Enqueue style for custom customize control.
*/
add_action( 'customize_controls_enqueue_scripts', 'bosa_custom_customize_enqueue' );
function bosa_custom_customize_enqueue() {
wp_enqueue_style( 'bosa-customize-controls', get_template_directory_uri() . '/inc/customizer/customizer.css' );
}
/**
* Render the site title for the selective refresh partial.
*
* @return void
*/
function bosa_customize_partial_blogname() {
bloginfo( 'name' );
}
/**
* Render the site tagline for the selective refresh partial.
*
* @return void
*/
function bosa_customize_partial_blogdescription() {
bloginfo( 'description' );
}
/**
* Binds JS handlers to make Theme Customizer preview reload changes asynchronously.
*/
function bosa_customize_preview_js() {
wp_enqueue_script( 'bosa-customizer', get_template_directory_uri() . '/inc/customizer/customizer.js', array( 'customize-preview' ), '20151215', true );
}
add_action( 'customize_preview_init', 'bosa_customize_preview_js' );
/**
* Kirki Customizer
*
* @return void
*/
add_action( 'init' , 'bosa_kirki_fields' );
function bosa_kirki_fields(){
/**
* If kirki is not installed do not run the kirki fields
*/
if ( !class_exists( 'Kirki' ) ) {
return;
}
Kirki::add_config( 'bosa', array(
'capability' => 'edit_theme_options',
'option_type' => 'theme_mod',
) );
// Site Identity - Title & Tagline
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Logo Image Width', 'bosa' ),
'type' => 'slider',
'settings' => 'logo_width',
'section' => 'title_tagline',
'transport' => 'postMessage',
'priority' => '8',
'default' => 270,
'choices' => array(
'min' => 50,
'max' => 270,
'step' => 5,
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Site Title', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_site_title',
'section' => 'title_tagline',
'priority' => '10',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Site Tagline', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_site_tagline',
'section' => 'title_tagline',
'priority' => '20',
'default' => false,
) );
// Colors Options
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Body Text Color', 'bosa' ),
'type' => 'color',
'settings' => 'site_body_text_color',
'section' => 'colors',
'default' => '#101010',
'priority' => '20',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'General Heading Text Color (H1 - H6)', 'bosa' ),
'type' => 'color',
'settings' => 'site_heading_text_color',
'section' => 'colors',
'default' => '#101010',
'priority' => '30',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Page and Single Post Title', 'bosa' ),
'type' => 'color',
'settings' => 'header_textcolor',
'section' => 'colors',
'default' => '#101010',
'priority' => '40',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Primary Color', 'bosa' ),
'type' => 'color',
'settings' => 'site_primary_color',
'section' => 'colors',
'default' => '#f9a032',
'priority' => '50',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hover Color', 'bosa' ),
'type' => 'color',
'settings' => 'site_hover_color',
'section' => 'colors',
'default' => '#086abd',
'priority' => '60',
) );
// Header Options
Kirki::add_panel( 'header_options', array(
'title' => esc_html__( 'Header', 'bosa' ),
'priority' => '10',
) );
// Header Style Options
Kirki::add_section( 'header_style_options', array(
'title' => esc_html__( 'Style', 'bosa' ),
'panel' => 'header_options',
'capability' => 'edit_theme_options',
'priority' => '30',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Header Layouts', 'bosa' ),
'description' => esc_html__( 'Select layout & scroll below to change its options', 'bosa' ),
'type' => 'radio-image',
'settings' => 'header_layout',
'section' => 'header_style_options',
'default' => 'header_one',
'choices' => array(
'header_one' => get_template_directory_uri() . '/assets/images/header-layout-1.png',
'header_two' => get_template_directory_uri() . '/assets/images/header-layout-2.png',
'header_three' => get_template_directory_uri() . '/assets/images/header-layout-3.png',
)
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Top header Section Border', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_header_border',
'section' => 'header_style_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_three' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Site Title Color', 'bosa' ),
'type' => 'color',
'settings' => 'site_title_color',
'section' => 'header_style_options',
'default' => '#101010',
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_two', 'header_three' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Site Tagline Color', 'bosa' ),
'type' => 'color',
'settings' => 'site_tagline_color',
'section' => 'header_style_options',
'default' => '#767676',
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_two', 'header_three' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Top Section Background Color', 'bosa' ),
'type' => 'color',
'settings' => 'top_header_background_color',
'section' => 'header_style_options',
'default' => '#ffffff',
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_three' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Top Section Text Color', 'bosa' ),
'type' => 'color',
'settings' => 'top_header_text_color',
'section' => 'header_style_options',
'default' => '#969696',
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_three' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Top Section Text Link Hover Color', 'bosa' ),
'type' => 'color',
'settings' => 'top_header_text_link_hover_color',
'section' => 'header_style_options',
'default' => '#086abd',
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_three' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Mid Section Background Color', 'bosa' ),
'description' => esc_html__( 'It can be used as a transparent background color over image.', 'bosa' ),
'type' => 'color',
'settings' => 'mid_header_background_color',
'section' => 'header_style_options',
'default' => '',
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => '==',
'value' => 'header_three',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Mid Section Text Color', 'bosa' ),
'type' => 'color',
'settings' => 'mid_header_text_color',
'section' => 'header_style_options',
'default' => '#101010',
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => '==',
'value' => 'header_three',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Mid Section Text Link Hover Color', 'bosa' ),
'type' => 'color',
'settings' => 'mid_header_text_link_hover_color',
'section' => 'header_style_options',
'default' => '#086abd',
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_three' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Bottom Section Background Color', 'bosa' ),
'description' => esc_html__( 'It can be used as a transparent background color over image.', 'bosa' ),
'type' => 'color',
'settings' => 'bottom_header_transparent_background_color',
'section' => 'header_style_options',
'default' => '',
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_two' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Bottom Section Background Color', 'bosa' ),
'type' => 'color',
'settings' => 'bottom_header_background_color',
'section' => 'header_style_options',
'default' => '#ffffff',
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_three' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Bottom Section Text Color', 'bosa' ),
'type' => 'color',
'settings' => 'bottom_header_text_color',
'section' => 'header_style_options',
'default' => '#333333',
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_two', 'header_three' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Bottom Section Text Link Hover Color', 'bosa' ),
'type' => 'color',
'settings' => 'bottom_header_text_link_hover_color',
'section' => 'header_style_options',
'default' => '#086abd',
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_two', 'header_three' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Bottom Section Text Color', 'bosa' ),
'type' => 'color',
'settings' => 'bottom_header_text_color',
'section' => 'header_style_options',
'default' => '#333333',
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_two', 'header_three' ),
),
),
) );
// Header three separate logo
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Separate Logo for Homepage', 'bosa' ),
'description' => esc_html__( 'Fully white or light color with image dimensions 320 by 120 pixels is recommended. It will change in the transparent homepage header only.', 'bosa' ),
'type' => 'image',
'settings' => 'header_separate_logo',
'section' => 'header_style_options',
'default' => '',
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_two' ),
),
),
) );
// Header three fixed header separate logo
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Separate Logo for Homepage Fixed Header', 'bosa' ),
'description' => esc_html__( 'Non White with image dimensions 320 by 120 pixels is recommended. It will change in the transparent homepage fixed header only.', 'bosa' ),
'type' => 'image',
'settings' => 'fixed_header_separate_logo',
'section' => 'header_style_options',
'default' => '',
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_two' ),
),
array(
'setting' => 'header_separate_logo',
'operator' => '!==',
'value' => '',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Section Border', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_header_border',
'section' => 'header_style_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_three' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Below Section Border', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_header_below_border',
'section' => 'header_style_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_three' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Header Height (in px)', 'bosa' ),
'description' => esc_html__( 'This option will only apply to Desktop. Please click on below Desktop Icon to see changes. Automatically adjust by theme default in the responsive devices.
', 'bosa' ),
'type' => 'slider',
'settings' => 'header_image_height',
'section' => 'header_style_options',
'transport' => 'postMessage',
'default' => 80,
'choices' => array(
'min' => 50,
'max' => 1200,
'step' => 10,
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Navigation Height (in px)', 'bosa' ),
'description' => esc_html__( 'This option will only apply to Desktop. Please click on below Desktop Icon to see changes. Automatically adjust by theme default in the responsive devices.
', 'bosa' ),
'type' => 'slider',
'settings' => 'header_nav_height',
'section' => 'header_style_options',
'transport' => 'postMessage',
'default' => 60,
'choices' => array(
'min' => 50,
'max' => 200,
'step' => 5,
),
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_three' ),
),
),
) );
// Contact Detail Options
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Contact Details', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_contact_detail',
'section' => 'header_style_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_three' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Phone Number', 'bosa' ),
'type' => 'text',
'settings' => 'contact_phone',
'section' => 'header_style_options',
'default' => '',
'active_callback' => array(
array(
'setting' => 'disable_contact_detail',
'operator' => '==',
'value' => false,
),
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_three' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Email', 'bosa' ),
'type' => 'text',
'settings' => 'contact_email',
'section' => 'header_style_options',
'default' => '',
'active_callback' => array(
array(
'setting' => 'disable_contact_detail',
'operator' => '==',
'value' => false,
),
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_three' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Address', 'bosa' ),
'type' => 'text',
'settings' => 'contact_address',
'section' => 'header_style_options',
'default' => '',
'active_callback' => array(
array(
'setting' => 'disable_contact_detail',
'operator' => '==',
'value' => false,
),
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_three' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Search Icon', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_search_icon',
'section' => 'header_style_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_three' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Hamburger Widget Menu Icon', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_hamburger_menu_icon',
'section' => 'header_style_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_three' ),
),
),
) );
// Header button
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Button', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_header_button',
'section' => 'header_style_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_two' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Button Background Color', 'bosa' ),
'type' => 'color',
'settings' => 'header_button_background_color',
'section' => 'header_style_options',
'default' => '#f9a032',
'active_callback' => array(
array(
'setting' => 'disable_header_button',
'operator' => '==',
'value' => false,
),
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_two' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Button Text Color', 'bosa' ),
'type' => 'color',
'settings' => 'header_button_text_color',
'section' => 'header_style_options',
'default' => '#ffffff',
'active_callback' => array(
array(
'setting' => 'disable_header_button',
'operator' => '==',
'value' => false,
),
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_two' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Header Button Text', 'bosa' ),
'type' => 'text',
'settings' => 'header_button_text',
'section' => 'header_style_options',
'default' => '',
'active_callback' => array(
array(
'setting' => 'disable_header_button',
'operator' => '==',
'value' => false,
),
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_two' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Button Target', 'bosa' ),
'description' => esc_html__( 'If enabled, the page will be open in an another browser tab.', 'bosa' ),
'type' => 'checkbox',
'settings' => 'header_button_target',
'section' => 'header_style_options',
'default' => true,
'active_callback' => array(
array(
'setting' => 'disable_header_button',
'operator' => '==',
'value' => false,
),
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_two' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Button Link', 'bosa' ),
'type' => 'link',
'settings' => 'header_button_link',
'section' => 'header_style_options',
'default' => '',
'active_callback' => array(
array(
'setting' => 'disable_header_button',
'operator' => '==',
'value' => false,
),
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_two' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Button Type', 'bosa' ),
'type' => 'select',
'settings' => 'header_button_type',
'section' => 'header_style_options',
'default' => 'button-primary',
'choices' => array(
'button-primary' => esc_html__( 'Primary Button', 'bosa' ),
'button-outline' => esc_html__( 'Border Button', 'bosa' ),
'button-text' => esc_html__( 'Text Only Button', 'bosa' ),
),
'active_callback' => array(
array(
'setting' => 'disable_header_button',
'operator' => '==',
'value' => false,
),
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_two' ),
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Button Border Radius (px)', 'bosa' ),
'type' => 'slider',
'settings' => 'header_button_border_radius',
'section' => 'header_style_options',
'transport' => 'postMessage',
'default' => 0,
'choices' => array(
'min' => 0,
'max' => 50,
'step' => 1,
),
'active_callback' => array(
array(
'setting' => 'disable_header_button',
'operator' => '==',
'value' => false,
),
array(
'setting' => 'header_layout',
'operator' => 'contains',
'value' => array( 'header_one', 'header_two' ),
),
),
) );
// Header Media Options
Kirki::add_section( 'header_wrap_media_options', array(
'title' => esc_html__( 'Media', 'bosa' ),
'panel' => 'header_options',
'capability' => 'edit_theme_options',
'priority' => '30',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Header Image Slider', 'bosa' ),
'description' => esc_html__( 'Recommended image size 1920x550 pixel. Add only one image to make header banner.', 'bosa' ),
'type' => 'repeater',
'section' => 'header_wrap_media_options',
'row_label' => array(
'type' => 'text',
),
'button_label' => esc_html__('Add New Image', 'bosa' ),
'settings' => 'header_image_slider',
'default' => '',
'fields' => array(
'slider_item' => array(
'label' => esc_html__( 'Image', 'bosa' ),
'type' => 'image',
'default' => '',
)
),
'choices' => array(
'limit' => 2,
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Background Image Size', 'bosa' ),
'type' => 'radio',
'settings' => 'header_image_size',
'section' => 'header_wrap_media_options',
'default' => 'cover',
'choices' => array(
'cover' => esc_html__( 'Cover', 'bosa' ),
'pattern' => esc_html__( 'Pattern / Repeat', 'bosa' ),
'norepeat' => esc_html__( 'No Repeat', 'bosa' ),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Slide Effect', 'bosa' ),
'type' => 'select',
'settings' => 'header_slider_effect',
'section' => 'header_wrap_media_options',
'default' => 'fade',
'choices' => array(
'fade' => esc_html__( 'Fade', 'bosa' ),
'horizontal-slide' => esc_html__( 'Slide', 'bosa' ),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Arrows', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_header_slider_arrows',
'section' => 'header_wrap_media_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Dots', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_header_slider_dots',
'section' => 'header_wrap_media_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Auto Play', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_header_slider_autoplay',
'section' => 'header_wrap_media_options',
'default' => true,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Auto Play Timeout ( in sec )', 'bosa' ),
'type' => 'number',
'settings' => 'slider_header_autoplay_speed',
'section' => 'header_wrap_media_options',
'default' => 4,
'choices' => array(
'min' => '1',
'max' => '60',
'step'=> '1',
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Fade Control Time ( in sec )', 'bosa' ),
'type' => 'number',
'settings' => 'slider_header_fade_control',
'section' => 'header_wrap_media_options',
'default' => 5,
'choices' => array(
'min' => '3',
'max' => '60',
'step'=> '1',
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Parallax Scrolling', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_parallax_scrolling',
'section' => 'header_wrap_media_options',
'default' => true,
) );
// Header Style Options
Kirki::add_section( 'header_elements_options', array(
'title' => esc_html__( 'Elements', 'bosa' ),
'panel' => 'header_options',
'capability' => 'edit_theme_options',
'priority' => '30',
) );
Kirki::add_field( 'bosa', array(
'type' => 'custom',
'settings' => 'separator' . rand(),
'section' => 'header_elements_options',
'default' => '
Fixed Header Options
',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Fixed Header', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_fixed_header',
'section' => 'header_elements_options',
'default' => true,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Logo', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_fixed_header_logo',
'section' => 'header_elements_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'disable_fixed_header',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Logo Image Width', 'bosa' ),
'type' => 'slider',
'settings' => 'fixed_header_logo_width',
'section' => 'header_elements_options',
'transport' => 'postMessage',
'default' => 270,
'choices' => array(
'min' => 50,
'max' => 270,
'step' => 5,
),
'active_callback' => array(
array(
'setting' => 'disable_fixed_header_logo',
'operator' => '==',
'value' => false,
),
array(
'setting' => 'disable_fixed_header',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Site Title', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_fixed_header_site_title',
'section' => 'header_elements_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'disable_fixed_header',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Site Tagline', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_fixed_header_site_tagline',
'section' => 'header_elements_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'disable_fixed_header',
'operator' => '==',
'value' => false,
),
),
) );
// Top Notification Options
Kirki::add_section( 'notification_bar_options', array(
'title' => esc_html__( 'Top Notification Bar', 'bosa' ),
'panel' => 'header_options',
'capability' => 'edit_theme_options',
'priority' => '50',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Header Notification Bar', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_notification_bar',
'section' => 'notification_bar_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Background Color', 'bosa' ),
'type' => 'color',
'settings' => 'notification_bar_background_color',
'section' => 'notification_bar_options',
'default' => '#1a1a1a',
'active_callback' => array(
array(
'setting' => 'disable_notification_bar',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Title', 'bosa' ),
'type' => 'text',
'settings' => 'notification_bar_title',
'section' => 'notification_bar_options',
'default' => '',
'active_callback' => array(
array(
'setting' => 'disable_notification_bar',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Title Text Color', 'bosa' ),
'type' => 'color',
'settings' => 'notification_bar_title_color',
'section' => 'notification_bar_options',
'default' => '#ffffff',
'active_callback' => array(
array(
'setting' => 'disable_notification_bar',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Button', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_notification_bar_button',
'section' => 'notification_bar_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'disable_notification_bar',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Button Background Color', 'bosa' ),
'type' => 'color',
'settings' => 'notification_bar_button_background_color',
'section' => 'notification_bar_options',
'default' => '#f9a032',
'active_callback' => array(
array(
'setting' => 'disable_notification_bar_button',
'operator' => '==',
'value' => false,
),
array(
'setting' => 'disable_notification_bar',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Button Text Color', 'bosa' ),
'type' => 'color',
'settings' => 'notification_bar_button_text_color',
'section' => 'notification_bar_options',
'default' => '#ffffff',
'active_callback' => array(
array(
'setting' => 'disable_notification_bar_button',
'operator' => '==',
'value' => false,
),
array(
'setting' => 'disable_notification_bar',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Button Text', 'bosa' ),
'type' => 'text',
'settings' => 'notification_bar_button_text',
'section' => 'notification_bar_options',
'default' => '',
'active_callback' => array(
array(
'setting' => 'disable_notification_bar_button',
'operator' => '==',
'value' => false,
),
array(
'setting' => 'disable_notification_bar',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Button Type', 'bosa' ),
'type' => 'select',
'settings' => 'notification_bar_button_type',
'section' => 'notification_bar_options',
'default' => 'button-primary',
'choices' => array(
'button-primary' => esc_html__( 'Primary Button', 'bosa' ),
'button-outline' => esc_html__( 'Border Button', 'bosa' ),
'button-text' => esc_html__( 'Text Only Button', 'bosa' ),
),
'active_callback' => array(
array(
'setting' => 'disable_notification_bar_button',
'operator' => '==',
'value' => false,
),
array(
'setting' => 'disable_notification_bar',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Button Border Radius (px)', 'bosa' ),
'type' => 'slider',
'settings' => 'notification_bar_button_border_radius',
'section' => 'notification_bar_options',
'transport' => 'postMessage',
'default' => 0,
'choices' => array(
'min' => 0,
'max' => 50,
'step' => 1,
),
'active_callback' => array(
array(
'setting' => 'disable_notification_bar_button',
'operator' => '==',
'value' => false,
),
array(
'setting' => 'disable_notification_bar',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Button Target', 'bosa' ),
'description' => esc_html__( 'If enabled, the page will be open in an another browser tab.', 'bosa' ),
'type' => 'checkbox',
'settings' => 'notification_bar_button_target',
'section' => 'notification_bar_options',
'default' => true,
'active_callback' => array(
array(
'setting' => 'disable_notification_bar_button',
'operator' => '==',
'value' => false,
),
array(
'setting' => 'disable_notification_bar',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Button Link', 'bosa' ),
'type' => 'link',
'settings' => 'notification_bar_button_link',
'section' => 'notification_bar_options',
'default' => '',
'active_callback' => array(
array(
'setting' => 'disable_notification_bar_button',
'operator' => '==',
'value' => false,
),
array(
'setting' => 'disable_notification_bar',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Sticky Position', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_sticky_notification_bar',
'section' => 'notification_bar_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'disable_notification_bar',
'operator' => '==',
'value' => false,
),
),
) );
// Theme Skin Options
Kirki::add_section( 'skins_options', array(
'title' => esc_html__( 'Site Skins', 'bosa' ),
'capability' => 'edit_theme_options',
'priority' => '80',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Select Theme Skin', 'bosa' ),
'type' => 'select',
'settings' => 'skin_select',
'section' => 'skins_options',
'default' => 'default',
'choices' => array(
'default' => esc_html__( 'Default', 'bosa' ),
'dark' => esc_html__( 'Dark', 'bosa' ),
'blackwhite' => esc_html__( 'Black & White', 'bosa' ),
)
) );
// Social Media Options
Kirki::add_section( 'social_media_options', array(
'title' => esc_html__( 'Social Media', 'bosa' ),
'capability' => 'edit_theme_options',
'priority' => '98',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Social Links from Header', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_header_social_links',
'section' => 'social_media_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Social Links from Footer', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_footer_social_links',
'section' => 'social_media_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Footer Social Icons Size', 'bosa' ),
'description' => esc_html__( 'Only applicable to the footer social icons.', 'bosa' ),
'type' => 'number',
'settings' => 'social_icons_size',
'section' => 'social_media_options',
'transport' => 'postMessage',
'default' => 15,
'choices' => array(
'min' => 10,
'max' => 100,
'step' => 1,
),
'active_callback' => array(
array(
'setting' => 'disable_footer_social_links',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Social Links', 'bosa' ),
'type' => 'repeater',
'description' => esc_html__( 'By default, Social Icons will appear in both header and footer section.', 'bosa' ),
'section' => 'social_media_options',
'row_label' => array(
'type' => 'text',
'value' => esc_html__( 'Social Link', 'bosa' ),
),
'settings' => 'social_media_links',
'default' => array(
'icon' => array(
'label' => esc_html__( 'Fontawesome Icon', 'bosa' ),
'type' => 'text',
'description' => esc_html__( 'Input Icon name. For Example:- fab fa-facebook For more icons https://fontawesome.com/icons?d=gallery&m=free', 'bosa' ),
),
'link' => array(
'label' => esc_html__( 'Link', 'bosa' ),
'type' => 'text',
),
),
'fields' => array(
'icon' => array(
'label' => esc_html__( 'Fontawesome Icon', 'bosa' ),
'type' => 'text',
'description' => esc_html__( 'Input Icon name. For Example:- fab fa-facebook For more icons https://fontawesome.com/icons?d=gallery&m=free', 'bosa' ),
),
'link' => array(
'label' => esc_html__( 'Link', 'bosa' ),
'type' => 'text',
),
),
'choices' => array(
'limit' => 20,
),
) );
//Typography Options
Kirki::add_section( 'typography', array(
'title' => esc_html__( 'Typography', 'bosa' ),
'capability' => 'edit_theme_options',
'priority' => '95',
'reset' => 'typography',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Site Title', 'bosa' ),
'type' => 'typography',
'settings' => 'site_title_font_control',
'section' => 'typography',
'default' => array(
'font-family' => 'Poppins',
'font-size' => '26px',
'text-transform' => 'none',
),
'transport' => 'auto',
'output' => array(
array(
'element' => '.site-header .site-branding .site-title',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Site Description', 'bosa' ),
'type' => 'typography',
'settings' => 'site_description_font_control',
'section' => 'typography',
'default' => array(
'font-family' => 'Open Sans',
'font-size' => '14px',
'text-transform' => 'none',
),
'transport' => 'auto',
'output' => array(
array(
'element' => '.site-header .site-branding .site-description',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Body', 'bosa' ),
'type' => 'typography',
'settings' => 'body_font_control',
'section' => 'typography',
'default' => array(
'font-family' => 'Open Sans',
'font-size' => '15px',
),
'transport' => 'auto',
'output' => array(
array(
'element' => 'body',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'General Title', 'bosa' ),
'type' => 'typography',
'settings' => 'general_title_font_control',
'section' => 'typography',
'default' => array(
'font-family' => 'Poppins',
'text-transform' => 'none',
),
'transport' => 'auto',
'output' => array(
array(
'element' => 'h1, h2, h3, h4, h5, h6',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Page & Single Post Title', 'bosa' ),
'type' => 'typography',
'settings' => 'page_title_font_control',
'section' => 'typography',
'default' => array(
'font-family' => 'Poppins',
'font-size' => '48px',
'text-transform' => 'none',
),
'transport' => 'auto',
'output' => array(
array(
'element' => 'body.single .page-title, body.page .page-title',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Blog Post Title', 'bosa' ),
'description' => esc_html__( 'Only applicable to latest post titles.', 'bosa' ),
'type' => 'typography',
'settings' => 'blog_page_title_font_control',
'section' => 'typography',
'default' => array(
'font-family' => 'Prata',
'font-size' => '21px',
'text-transform' => 'none',
),
'transport' => 'auto',
'output' => array(
array(
'element' => '.content-area h3.entry-title',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Homepage Section Title', 'bosa' ),
'type' => 'typography',
'settings' => 'section_title_font_control',
'section' => 'typography',
'default' => array(
'font-family' => 'Poppins',
'font-size' => '24px',
'text-transform' => 'none',
),
'transport' => 'auto',
'output' => array(
array(
'element' => 'h2.section-title',
),
),
) );
// Site Layouts Options
Kirki::add_panel( 'site_layout_options', array(
'title' => esc_html__( 'Site Layouts', 'bosa' ),
'priority' => '90',
) );
Kirki::add_section( 'site_layout_style_options', array(
'title' => esc_html__( 'Style', 'bosa' ),
'panel' => 'site_layout_options',
'capability' => 'edit_theme_options',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Site Layouts', 'bosa' ),
'description' => esc_html__( 'Default / Box / Frame / Full / Compact', 'bosa' ),
'type' => 'radio-image',
'settings' => 'site_layout',
'section' => 'site_layout_style_options',
'default' => 'default',
'choices' => array(
'default' => get_template_directory_uri() . '/assets/images/default-layout.png',
'box' => get_template_directory_uri() . '/assets/images/box-layout.png',
'frame' => get_template_directory_uri() . '/assets/images/frame-layout.png',
'full' => get_template_directory_uri() . '/assets/images/full-layout.png',
'compact' => get_template_directory_uri() . '/assets/images/compact-layout.png',
),
) );
Kirki::add_section( 'site_layout_elements_options', array(
'title' => esc_html__( 'Elements', 'bosa' ),
'panel' => 'site_layout_options',
'capability' => 'edit_theme_options',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Site Layouts (Box & Frame) Shadow', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_site_layout_shadow',
'section' => 'site_layout_elements_options',
'default' => false,
) );
// Sidebar Options
Kirki::add_section( 'sidebar_options', array(
'title' => esc_html__( 'Sidebar', 'bosa' ),
'capability' => 'edit_theme_options',
'priority' => '98',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Sidebar Layouts', 'bosa' ),
'description' => esc_html__( 'Right / Left / Both / None', 'bosa' ),
'type' => 'radio-image',
'settings' => 'sidebar_settings',
'section' => 'sidebar_options',
'default' => 'right',
'choices' => array(
'right' => get_template_directory_uri() . '/assets/images/right-sidebar.png',
'left' => get_template_directory_uri() . '/assets/images/left-sidebar.png',
'right-left' => get_template_directory_uri() . '/assets/images/right-left-sidebar.png',
'no-sidebar' => get_template_directory_uri() . '/assets/images/no-sidebar.png',
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Sticky Position', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_sticky_sidebar',
'section' => 'sidebar_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Sidebar in Blog Page', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_sidebar_blog_page',
'section' => 'sidebar_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Sidebar in Single Post', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_sidebar_single_post',
'section' => 'sidebar_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Sidebar in Page', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_sidebar_page',
'section' => 'sidebar_options',
'default' => true,
) );
// Footer Options
Kirki::add_panel( 'footer_options', array(
'title' => esc_html__( 'Footer', 'bosa' ),
'priority' => '110',
) );
// Footer Widgets Options
Kirki::add_section( 'footer_widgets_options', array(
'title' => esc_html__( 'Footer Widgets', 'bosa' ),
'panel' => 'footer_options',
'capability' => 'edit_theme_options',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Footer Widget Area', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_footer_widget',
'section' => 'footer_widgets_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Widget Columns', 'bosa' ),
'type' => 'select',
'settings' => 'top_footer_widget_columns',
'section' => 'footer_widgets_options',
'default' => 'four_columns',
'choices' => array(
'four_columns' => esc_html__( 'Four Columns', 'bosa' ),
'three_columns' => esc_html__( 'Three Columns', 'bosa' ),
'two_columns' => esc_html__( 'Two Columns', 'bosa' ),
'one_column' => esc_html__( 'One Column', 'bosa' ),
),
'active_callback' => array(
array(
'setting' => 'disable_footer_widget',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Section Background Color', 'bosa' ),
'description' => esc_html__( 'It can be used as a transparent background color over image.', 'bosa' ),
'type' => 'color',
'settings' => 'top_footer_background_color',
'section' => 'footer_widgets_options',
'default' => '',
'active_callback' => array(
array(
'setting' => 'disable_footer_widget',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Widget Title Color', 'bosa' ),
'type' => 'color',
'settings' => 'top_footer_widget_title_color',
'section' => 'footer_widgets_options',
'default' => '#030303',
'active_callback' => array(
array(
'setting' => 'disable_footer_widget',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Widgets Link Color', 'bosa' ),
'type' => 'color',
'settings' => 'top_footer_widget_link_color',
'section' => 'footer_widgets_options',
'default' => '#656565',
'active_callback' => array(
array(
'setting' => 'disable_footer_widget',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Widgets Link Hover Color', 'bosa' ),
'type' => 'color',
'settings' => 'top_footer_widget_link_hover_color',
'section' => 'footer_widgets_options',
'default' => '#086abd',
'active_callback' => array(
array(
'setting' => 'disable_footer_widget',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Widgets Content Color', 'bosa' ),
'type' => 'color',
'settings' => 'top_footer_widget_content_color',
'section' => 'footer_widgets_options',
'default' => '#656565',
'active_callback' => array(
array(
'setting' => 'disable_footer_widget',
'operator' => '==',
'value' => false,
),
),
) );
// Footer Style Options
Kirki::add_section( 'footer_style_options', array(
'title' => esc_html__( 'Style', 'bosa' ),
'panel' => 'footer_options',
'capability' => 'edit_theme_options',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Bottom Footer Area', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_bottom_footer',
'section' => 'footer_style_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Footer Layouts', 'bosa' ),
'type' => 'radio-image',
'settings' => 'footer_layout',
'section' => 'footer_style_options',
'default' => 'footer_one',
'choices' => array(
'footer_one' => get_template_directory_uri() . '/assets/images/footer-layout-1.png',
'footer_two' => get_template_directory_uri() . '/assets/images/footer-layout-2.png',
'footer_three' => get_template_directory_uri() . '/assets/images/footer-layout-3.png',
),
'active_callback' => array(
array(
'setting' => 'disable_bottom_footer',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Background Color', 'bosa' ),
'description' => esc_html__( 'It can be used as a transparent background color over image.', 'bosa' ),
'type' => 'color',
'settings' => 'bottom_footer_background_color',
'section' => 'footer_style_options',
'default' => '',
'active_callback' => array(
array(
'setting' => 'disable_bottom_footer',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Text Color', 'bosa' ),
'type' => 'color',
'settings' => 'bottom_footer_text_color',
'section' => 'footer_style_options',
'default' => '#656565',
'active_callback' => array(
array(
'setting' => 'disable_bottom_footer',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Text Link Color', 'bosa' ),
'type' => 'color',
'settings' => 'bottom_footer_text_link_color',
'section' => 'footer_style_options',
'default' => '#383838',
'active_callback' => array(
array(
'setting' => 'disable_bottom_footer',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Text Link Hover Color', 'bosa' ),
'type' => 'color',
'settings' => 'bottom_footer_text_link_hover_color',
'section' => 'footer_style_options',
'default' => '#086abd',
'active_callback' => array(
array(
'setting' => 'disable_bottom_footer',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Footer Menu', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_footer_menu',
'section' => 'footer_style_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'disable_bottom_footer',
'operator' => '==',
'value' => false,
),
),
) );
// Media Footer Options
Kirki::add_section( 'media_footer_options', array(
'title' => esc_html__( 'Media', 'bosa' ),
'panel' => 'footer_options',
'capability' => 'edit_theme_options',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Select Background Image', 'bosa' ),
'description' => esc_html__( 'Recommended image size 1920x550 pixel.', 'bosa' ),
'type' => 'image',
'settings' => 'footer_image',
'section' => 'media_footer_options',
'default' => '',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Background Image Size', 'bosa' ),
'type' => 'radio',
'settings' => 'footer_image_size',
'section' => 'media_footer_options',
'default' => 'cover',
'choices' => array(
'cover' => esc_html__( 'Cover', 'bosa' ),
'pattern' => esc_html__( 'Pattern / Repeat', 'bosa' ),
'norepeat' => esc_html__( 'No Repeat', 'bosa' ),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Parallax Scrolling', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_footer_parallax_scrolling',
'section' => 'media_footer_options',
'default' => true,
) );
// Footer Elements Options
Kirki::add_section( 'elements_footer_options', array(
'title' => esc_html__( 'Elements', 'bosa' ),
'panel' => 'footer_options',
'capability' => 'edit_theme_options',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Scroll to Top', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_scroll_top',
'section' => 'elements_footer_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Copyright Text', 'bosa' ),
'type' => 'textarea',
'settings' => 'footer_text',
'section' => 'elements_footer_options',
'default' => esc_html__( 'Copyright © 2020.', 'bosa' ),
) );
// Instagram Options
Kirki::add_section( 'instagram_feed_options', array(
'title' => esc_html__( 'Instagram Feed', 'bosa' ),
'panel' => 'footer_options',
'capability' => 'edit_theme_options',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Instagram Feed', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_instagram',
'section' => 'instagram_feed_options',
'default' => true,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Instagram Shortcode', 'bosa' ),
'type' => 'text',
'settings' => 'insta_shortcode',
'section' => 'instagram_feed_options',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Enable in Homepage Only', 'bosa' ),
'type' => 'checkbox',
'settings' => 'enable_instagram_homepage',
'section' => 'instagram_feed_options',
'default' => false,
) );
// Blog Homepage Options
Kirki::add_panel( 'blog_homepage_options', array(
'title' => esc_html__( 'Blog Homepage', 'bosa' ),
'priority' => '120',
) );
// Main Banner / Post Slider
Kirki::add_section( 'main_slider_options', array(
'title' => esc_html__( 'Banner / Post Slider', 'bosa' ),
'panel' => 'blog_homepage_options',
'capability' => 'edit_theme_options',
'priority' => '10',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Section', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_main_slider',
'section' => 'main_slider_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Slider / Banner', 'bosa' ),
'type' => 'radio-buttonset',
'settings' => 'main_slider_controls',
'section' => 'main_slider_options',
'default' => 'slider',
'choices' => array(
'slider' => esc_html__( 'Slider', 'bosa' ),
'banner' => esc_html__( 'Banner', 'bosa' ),
)
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Height (in px)', 'bosa' ),
'description' => esc_html__( 'This option will only apply to Desktop. Please click on below Desktop Icon to see changes. Automatically adjust by theme default in the responsive devices.
', 'bosa' ),
'type' => 'slider',
'settings' => 'main_slider_height',
'section' => 'main_slider_options',
'transport' => 'postMessage',
'default' => 550,
'choices' => array(
'min' => 50,
'max' => 1500,
'step' => 10,
),
) );
// Slider settings
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Choose Category', 'bosa' ),
'description' => esc_html__( 'Recent posts will show if any, category is not chosen.', 'bosa' ),
'type' => 'select',
'settings' => 'slider_category',
'section' => 'main_slider_options',
'default' => 'Uncategorized',
'placeholder' => esc_attr__( 'Select category', 'bosa' ),
'choices' => bosa_get_post_categories(),
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
),
) );
Kirki::add_field( 'bosa', array(
'type' => 'number',
'settings' => 'slider_image_overlay_opacity',
'label' => esc_html__( 'Image Overlay Opacity', 'bosa' ),
'section' => 'main_slider_options',
'default' => 4,
'choices' => array(
'min' => '0',
'max' => '9',
'step' => '1',
),
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Background Image Size', 'bosa' ),
'type' => 'radio',
'settings' => 'main_slider_image_size',
'section' => 'main_slider_options',
'default' => 'cover',
'choices' => array(
'cover' => esc_html__( 'Cover', 'bosa' ),
'pattern' => esc_html__( 'Pattern / Repeat', 'bosa' ),
'norepeat' => esc_html__( 'No Repeat', 'bosa' ),
),
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Width Controls', 'bosa' ),
'type' => 'select',
'settings' => 'slider_width_controls',
'section' => 'main_slider_options',
'default' => 'full',
'choices' => array(
'full' => esc_html__( 'Full', 'bosa' ),
'boxed' => esc_html__( 'Boxed', 'bosa' ),
),
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Slide Effect', 'bosa' ),
'type' => 'select',
'settings' => 'main_slider_effect',
'section' => 'main_slider_options',
'default' => 'fade',
'choices' => array(
'fade' => esc_html__( 'Fade', 'bosa' ),
'horizontal-slide' => esc_html__( 'Slide', 'bosa' ),
),
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Content Alignment', 'bosa' ),
'type' => 'select',
'settings' => 'main_slider_content_alignment',
'section' => 'main_slider_options',
'default' => 'center',
'choices' => array(
'center' => esc_html__( 'Center', 'bosa' ),
'left' => esc_html__( 'Left', 'bosa' ),
'right' => esc_html__( 'Right', 'bosa' ),
),
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Arrows', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_slider_arrows',
'section' => 'main_slider_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Dots', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_slider_dots',
'section' => 'main_slider_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Auto Play', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_slider_autoplay',
'section' => 'main_slider_options',
'default' => true,
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Auto Play Timeout ( in sec )', 'bosa' ),
'type' => 'number',
'settings' => 'slider_autoplay_speed',
'section' => 'main_slider_options',
'default' => 4,
'choices' => array(
'min' => '1',
'max' => '60',
'step'=> '1',
),
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Fade Control Time ( in sec )', 'bosa' ),
'type' => 'number',
'settings' => 'slider_fade_control',
'section' => 'main_slider_options',
'default' => 5,
'choices' => array(
'min' => '3',
'max' => '60',
'step'=> '1',
),
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Post View Number', 'bosa' ),
'description' => esc_html__( 'Number of posts to show.', 'bosa' ),
'type' => 'number',
'settings' => 'slider_posts_number',
'section' => 'main_slider_options',
'default' => 6,
'choices' => array(
'min' => '1',
'max' => '20',
'step' => '1',
),
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide Title', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_slider_title',
'section' => 'main_slider_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide Content', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_slider_excerpt',
'section' => 'main_slider_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Excerpt Lenght', 'bosa' ),
'type' => 'number',
'settings' => 'slider_excerpt_length',
'section' => 'main_slider_options',
'default' => 25,
'choices' => array(
'min' => '5',
'max' => '100',
'step' => '5',
),
'active_callback' => array(
array(
'setting' => 'hide_slider_excerpt',
'operator' => '==',
'value' => false,
),
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide Button', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_slider_button',
'section' => 'main_slider_options',
'default' => true,
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Button Text', 'bosa' ),
'type' => 'text',
'settings' => 'slider_button_text',
'section' => 'main_slider_options',
'default' => '',
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
array(
'setting' => 'hide_slider_button',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Button Type', 'bosa' ),
'type' => 'select',
'settings' => 'slider_button_type',
'section' => 'main_slider_options',
'default' => 'button-outline',
'choices' => array(
'button-primary' => esc_html__( 'Primary Button', 'bosa' ),
'button-outline' => esc_html__( 'Border Button', 'bosa' ),
'button-text' => esc_html__( 'Text Only Button', 'bosa' ),
),
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
array(
'setting' => 'hide_slider_button',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Button Border Radius (px)', 'bosa' ),
'type' => 'slider',
'settings' => 'main_slider_button_border_radius',
'section' => 'main_slider_options',
'transport' => 'postMessage',
'default' => 0,
'choices' => array(
'min' => 0,
'max' => 50,
'step' => 1,
),
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
array(
'setting' => 'hide_slider_button',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide category', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_slider_category',
'section' => 'main_slider_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide Date', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_slider_date',
'section' => 'main_slider_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide Author', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_slider_author',
'section' => 'main_slider_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide Comments Link', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_slider_comment',
'section' => 'main_slider_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'slider',
),
),
) );
// Banner settings
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Title', 'bosa' ),
'type' => 'text',
'settings' => 'banner_title',
'section' => 'main_slider_options',
'default' => '',
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'banner',
),
),
'partial_refresh' => array(
'banner_title' => array(
'selector' => '.banner_title',
'render_callback' => 'bosa_get_banner_title',
)
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Subtitle', 'bosa' ),
'type' => 'text',
'settings' => 'banner_subtitle',
'section' => 'main_slider_options',
'default' => '',
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'banner',
),
),
'partial_refresh' => array(
'banner_subtitle' => array(
'selector' => '.banner_subtitle',
'render_callback' => 'bosa_get_banner_subtitle',
)
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Banner Buttons', 'bosa' ),
'type' => 'repeater',
'settings' => 'main_banner_buttons',
'section' => 'main_slider_options',
'row_label' => array(
'type' => 'text',
'value' => esc_html__( 'Button', 'bosa' ),
),
'default' => array(
array(
'text' => '',
'link' => '',
'type' => 'button-outline',
),
),
'fields' => array(
'text' => array(
'label' => esc_html__( 'Text', 'bosa' ),
'type' => 'text',
),
'link' => array(
'label' => esc_html__( 'Link', 'bosa' ),
'type' => 'text',
),
'type' => array(
'label' => esc_html__( 'Button Type', 'bosa' ),
'type' => 'select',
'default' => 'button-outline',
'choices' => array(
'button-primary' => esc_html__( 'Primary Button', 'bosa' ),
'button-outline' => esc_html__( 'Border Button', 'bosa' ),
'button-text' => esc_html__( 'Text Only Button', 'bosa' ),
),
),
),
'choices' => array(
'limit' => 10,
),
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'banner',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Button Border Radius (px)', 'bosa' ),
'type' => 'slider',
'settings' => 'banner_button_border_radius',
'section' => 'main_slider_options',
'transport' => 'postMessage',
'default' => 0,
'choices' => array(
'min' => 0,
'max' => 50,
'step' => 1,
),
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'banner',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Select Image', 'bosa' ),
'description' => esc_html__( 'Recommended image size 1920x550 pixel.', 'bosa' ),
'type' => 'image',
'settings' => 'banner_image',
'section' => 'main_slider_options',
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'banner',
),
)
) );
Kirki::add_field( 'bosa', array(
'type' => 'number',
'settings' => 'banner_image_overlay_opacity',
'label' => esc_html__( 'Image Overlay Opacity', 'bosa' ),
'section' => 'main_slider_options',
'default' => 4,
'choices' => array(
'min' => '0',
'max' => '9',
'step' => '1',
),
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'banner',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Background Image Size', 'bosa' ),
'type' => 'radio',
'settings' => 'main_banner_image_size',
'section' => 'main_slider_options',
'default' => 'cover',
'choices' => array(
'cover' => esc_html__( 'Cover', 'bosa' ),
'pattern' => esc_html__( 'Pattern / Repeat', 'bosa' ),
'norepeat' => esc_html__( 'No Repeat', 'bosa' ),
),
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'banner',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Width Controls', 'bosa' ),
'type' => 'select',
'settings' => 'banner_width_controls',
'section' => 'main_slider_options',
'default' => 'full',
'choices' => array(
'full' => esc_html__( 'Full', 'bosa' ),
'boxed' => esc_html__( 'Boxed', 'bosa' ),
),
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'banner',
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Content Alignment', 'bosa' ),
'type' => 'select',
'settings' => 'main_banner_content_alignment',
'section' => 'main_slider_options',
'default' => 'center',
'choices' => array(
'center' => esc_html__( 'Center', 'bosa' ),
'left' => esc_html__( 'Left', 'bosa' ),
'right' => esc_html__( 'Right', 'bosa' ),
),
'active_callback' => array(
array(
'setting' => 'main_slider_controls',
'operator' => '==',
'value' => 'banner',
),
),
) );
// Highlighted Posts Options
Kirki::add_section( 'highlight_posts_options', array(
'title' => esc_html__( 'Highlighted Posts', 'bosa' ),
'panel' => 'blog_homepage_options',
'capability' => 'edit_theme_options',
'priority' => '20',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Highlighted Posts Section', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_highlight_posts_section',
'section' => 'highlight_posts_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Section Title', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_highlight_posts_section_title',
'section' => 'highlight_posts_options',
'default' => true,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Section Title', 'bosa' ),
'type' => 'text',
'settings' => 'highlight_posts_section_title',
'section' => 'highlight_posts_options',
'default' => '',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Columns', 'bosa' ),
'type' => 'select',
'settings' => 'highlight_posts_columns',
'section' => 'highlight_posts_options',
'default' => 'three_columns',
'placeholder' => esc_attr__( 'Select category', 'bosa' ),
'choices' => array(
'one_column' => esc_html__( '1 Column', 'bosa' ),
'two_columns' => esc_html__( '2 Columns', 'bosa' ),
'three_columns' => esc_html__( '3 Columns', 'bosa' ),
'four_columns' => esc_html__( '4 Columns', 'bosa' ),
)
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Choose Category', 'bosa' ),
'description' => esc_html__( 'Recent posts will show if any, category is not chosen.', 'bosa' ),
'type' => 'select',
'settings' => 'highlight_posts_category',
'section' => 'highlight_posts_options',
'default' => 'Uncategorized',
'placeholder' => esc_attr__( 'Select category', 'bosa' ),
'choices' => bosa_get_post_categories()
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Highlighted Posts Overlay Opacity', 'bosa' ),
'type' => 'number',
'settings' => 'highlight_posts_overlay_opacity',
'section' => 'highlight_posts_options',
'default' => 4,
'choices' => array(
'min' => '0',
'max' => '9',
'step' => '1',
)
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Post View Number', 'bosa' ),
'description' => esc_html__( 'Number of posts to show.', 'bosa' ),
'type' => 'number',
'settings' => 'highlight_posts_posts_number',
'section' => 'highlight_posts_options',
'default' => 6,
'choices' => array(
'min' => '1',
'max' => '48',
'step' => '1',
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Height (in px)', 'bosa' ),
'description' => esc_html__( 'This option will only apply to Desktop. Please click on below Desktop Icon to see changes. Automatically adjust by theme default in the responsive devices.
', 'bosa' ),
'type' => 'slider',
'settings' => 'highlight_posts_height',
'section' => 'highlight_posts_options',
'transport' => 'postMessage',
'default' => 250,
'choices' => array(
'min' => '100',
'max' => '1200',
'step' => '10',
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Background Image Size', 'bosa' ),
'type' => 'radio',
'settings' => 'highlight_posts_image_size',
'section' => 'highlight_posts_options',
'default' => 'cover',
'choices' => array(
'cover' => esc_html__( 'Cover', 'bosa' ),
'pattern' => esc_html__( 'Pattern / Repeat', 'bosa' ),
'norepeat' => esc_html__( 'No Repeat', 'bosa' ),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Post Title', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_highlight_posts_title',
'section' => 'highlight_posts_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Post Title Divider', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_highlight_title_divider',
'section' => 'highlight_posts_options',
'default' => false,
'active_callback' => array(
array(
'setting' => 'disable_highlight_posts_title',
'operator' => '==',
'value' => false,
),
),
) );
// Latest Posts Options
Kirki::add_section( 'latest_posts_options', array(
'title' => esc_html__( 'Latest Posts', 'bosa' ),
'description' => esc_html__( 'More options are available in Page/Post Option section.', 'bosa' ),
'panel' => 'blog_homepage_options',
'capability' => 'edit_theme_options',
'priority' => '30',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Latest Posts Section', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_latest_posts_section',
'section' => 'latest_posts_options',
'default' => false,
) );
// Featured Posts Options
Kirki::add_section( 'feature_posts_options', array(
'title' => esc_html__( 'Featured Posts', 'bosa' ),
'panel' => 'blog_homepage_options',
'capability' => 'edit_theme_options',
'priority' => '40',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Featured Posts Section', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_feature_posts_section',
'section' => 'feature_posts_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Section Title', 'bosa' ),
'type' => 'text',
'settings' => 'feature_posts_section_title',
'section' => 'feature_posts_options',
'default' => '',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Section Title', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_feature_posts_section_title',
'section' => 'feature_posts_options',
'default' => true,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Choose Category', 'bosa' ),
'description' => esc_html__( 'Recent posts will show if any, category is not chosen.', 'bosa' ),
'type' => 'select',
'settings' => 'feature_posts_category',
'section' => 'feature_posts_options',
'default' => 'Uncategorized',
'placeholder' => esc_attr__( 'Select category', 'bosa' ),
'choices' => bosa_get_post_categories()
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Slider Columns', 'bosa' ),
'type' => 'number',
'settings' => 'feature_posts_slides_show',
'section' => 'feature_posts_options',
'default' => 3,
'choices' => array(
'min' => '2',
'max' => '4',
'step'=> '1',
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Arrows', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_feature_posts_arrows',
'section' => 'feature_posts_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Dots', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_feature_posts_dots',
'section' => 'feature_posts_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Slider Auto Play', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_feature_posts_autoplay',
'section' => 'feature_posts_options',
'default' => true,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Slider Auto Play Timeout ( in sec )', 'bosa' ),
'type' => 'number',
'settings' => 'feature_posts_autoplay_speed',
'section' => 'feature_posts_options',
'default' => 4,
'choices' => array(
'min' => '1',
'max' => '60',
'step'=> '1',
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Slider Post View Number', 'bosa' ),
'description' => esc_html__( 'Number of posts to show.', 'bosa' ),
'type' => 'number',
'settings' => 'feature_posts_posts_number',
'section' => 'feature_posts_options',
'default' => 6,
'choices' => array(
'min' => '1',
'max' => '20',
'step' => '1',
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide Post Image', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_feature_posts_image',
'section' => 'feature_posts_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide Post category', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_feature_posts_category',
'section' => 'feature_posts_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide Post Author', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_feature_posts_author',
'section' => 'feature_posts_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide Post Date', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_feature_posts_date',
'section' => 'feature_posts_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide Post Comment', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_feature_posts_comment',
'section' => 'feature_posts_options',
'default' => false,
) );
// Blog Page Options
Kirki::add_section( 'blog_page_options', array(
'title' => esc_html__( 'Blog Page', 'bosa' ),
'capability' => 'edit_theme_options',
'priority' => '130',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Post Layouts', 'bosa' ),
'description' => esc_html__( 'Grid / List / Single', 'bosa' ),
'type' => 'radio-image',
'settings' => 'archive_post_layout',
'section' => 'blog_page_options',
'default' => 'grid',
'choices' => array(
'grid' => get_template_directory_uri() . '/assets/images/grid-layout.png',
'list' => get_template_directory_uri() . '/assets/images/list-layout.png',
'single' => get_template_directory_uri() . '/assets/images/single-layout.png',
)
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Page Title', 'bosa' ),
'type' => 'select',
'settings' => 'disable_blog_page_title',
'section' => 'blog_page_options',
'default' => 'enable_all_pages',
'choices' => array(
'enable_all_pages' => esc_html__( 'Enable in all', 'bosa' ),
'disable_all_pages' => esc_html__( 'Disable from all', 'bosa' ),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Excerpt Length', 'bosa' ),
'description' => esc_html__( 'Select number of words to display in excerpt', 'bosa' ),
'type' => 'number',
'settings' => 'post_excerpt_length',
'section' => 'blog_page_options',
'default' => 15,
'choices' => array(
'min' => '5',
'max' => '60',
'step' => '5',
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Sticky Post Excerpt Length', 'bosa' ),
'description' => esc_html__( 'Select number of words to display in excerpt', 'bosa' ),
'type' => 'number',
'settings' => 'sticky_simple_post_excerpt_length',
'section' => 'blog_page_options',
'default' => 40,
'choices' => array(
'min' => '5',
'max' => '60',
'step' => '5',
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Post Title Color', 'bosa' ),
'type' => 'color',
'settings' => 'blog_post_title_color',
'section' => 'blog_page_options',
'default' => '#101010',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Post Category Color', 'bosa' ),
'type' => 'color',
'settings' => 'blog_post_category_color',
'section' => 'blog_page_options',
'default' => '#f9a032',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Post Meta Color', 'bosa' ),
'type' => 'color',
'settings' => 'blog_post_meta_color',
'section' => 'blog_page_options',
'default' => '#7a7a7a',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Post Text Color', 'bosa' ),
'type' => 'color',
'settings' => 'blog_post_text_color',
'section' => 'blog_page_options',
'default' => '#333333',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Post Button Color', 'bosa' ),
'type' => 'color',
'settings' => 'blog_post_button_color',
'section' => 'blog_page_options',
'default' => '#333333',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide Button', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_post_button',
'section' => 'blog_page_options',
'default' => true,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Button Text', 'bosa' ),
'type' => 'text',
'settings' => 'post_button_text',
'section' => 'blog_page_options',
'default' => '',
'active_callback' => array(
array(
'setting' => 'hide_post_button',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Button Type', 'bosa' ),
'type' => 'select',
'settings' => 'post_button_type',
'section' => 'blog_page_options',
'default' => 'button-text',
'choices' => array(
'button-primary' => esc_html__( 'Primary Button', 'bosa' ),
'button-outline' => esc_html__( 'Border Button', 'bosa' ),
'button-text' => esc_html__( 'Text Only Button', 'bosa' ),
),
'active_callback' => array(
array(
'setting' => 'hide_post_button',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Button Border Radius (px)', 'bosa' ),
'type' => 'slider',
'settings' => 'post_button_border_radius',
'section' => 'blog_page_options',
'transport' => 'postMessage',
'default' => 0,
'choices' => array(
'min' => 0,
'max' => 50,
'step' => 1,
),
'active_callback' => array(
array(
'setting' => 'hide_post_button',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide Author', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_author',
'section' => 'blog_page_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide Date', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_date',
'section' => 'blog_page_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide Comments Link', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_comment',
'section' => 'blog_page_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide category', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_category',
'section' => 'blog_page_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Pagination', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_pagination',
'section' => 'blog_page_options',
'default' => false,
) );
// Single Post Options
Kirki::add_section( 'single_post_options', array(
'title' => esc_html__( 'Single Post', 'bosa' ),
'capability' => 'edit_theme_options',
'priority' => '140',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Post Title', 'bosa' ),
'type' => 'select',
'settings' => 'disable_single_post_title',
'section' => 'single_post_options',
'default' => 'enable_all_pages',
'choices' => array(
'enable_all_pages' => esc_html__( 'Enable in all', 'bosa' ),
'disable_all_pages' => esc_html__( 'Disable from all', 'bosa' ),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Post Title Position', 'bosa' ),
'type' => 'select',
'settings' => 'post_title_position',
'section' => 'single_post_options',
'default' => 'below_feature_image',
'choices' => array(
'below_feature_image' => esc_html__( 'Below Feature Image', 'bosa' ),
'above_feature_image' => esc_html__( 'Above Feature Image', 'bosa' ),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Feature Image', 'bosa' ),
'type' => 'select',
'settings' => 'single_feature_image',
'section' => 'single_post_options',
'default' => 'show_in_all_pages',
'choices' => array(
'show_in_all_pages' => esc_html__( 'Show in all Pages', 'bosa' ),
'disable_in_all_pages' => esc_html__( 'Disable in all Pages', 'bosa' ),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide Date', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_single_post_date',
'section' => 'single_post_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide Comments Link', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_single_post_comment',
'section' => 'single_post_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide category', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_single_post_category',
'section' => 'single_post_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide Tag Links', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_single_post_tag_links',
'section' => 'single_post_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide Author', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_single_post_author',
'section' => 'single_post_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Author Section Title', 'bosa' ),
'type' => 'text',
'settings' => 'single_post_author_title',
'section' => 'single_post_options',
'default' => '',
'active_callback' => array(
array(
'setting' => 'hide_single_post_author',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Hide Related Posts', 'bosa' ),
'type' => 'checkbox',
'settings' => 'hide_related_posts',
'section' => 'single_post_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Related Posts Section Title', 'bosa' ),
'type' => 'text',
'settings' => 'related_posts_title',
'section' => 'single_post_options',
'default' => '',
'active_callback' => array(
array(
'setting' => 'hide_related_posts',
'operator' => '==',
'value' => false,
),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Related Posts Items', 'bosa' ),
'description' => esc_html__( 'Total number of related posts to show.', 'bosa' ),
'type' => 'number',
'settings' => 'related_posts_count',
'section' => 'single_post_options',
'default' => 4,
'choices' => array(
'min' => '1',
'max' => '12',
'step' => '1',
),
) );
// Pages Options
Kirki::add_section( 'pages_options', array(
'title' => esc_html__( 'Pages', 'bosa' ),
'capability' => 'edit_theme_options',
'priority' => '150',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Page Title', 'bosa' ),
'type' => 'select',
'settings' => 'disable_page_title',
'section' => 'pages_options',
'default' => 'disable_all_pages',
'choices' => array(
'disable_all_pages' => esc_html__( 'Disable from all', 'bosa' ),
'enable_all_pages' => esc_html__( 'Enable in all', 'bosa' ),
'disable_front_page' => esc_html__( 'Disable from frontpage only', 'bosa' ),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Page Title Position', 'bosa' ),
'type' => 'select',
'settings' => 'page_title_position',
'section' => 'pages_options',
'default' => 'below_feature_image',
'choices' => array(
'below_feature_image' => esc_html__( 'Below Feature Image', 'bosa' ),
'above_feature_image' => esc_html__( 'Above Feature Image', 'bosa' ),
),
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Feature Image', 'bosa' ),
'type' => 'select',
'settings' => 'page_feature_image',
'section' => 'pages_options',
'default' => 'show_in_all_pages',
'choices' => array(
'show_in_all_pages' => esc_html__( 'Show in all Pages', 'bosa' ),
'disable_in_all_pages' => esc_html__( 'Disable in all Pages', 'bosa' ),
'disable_in_frontpage' => esc_html__( 'Disable in Frontpage only', 'bosa' ),
'show_in_frontpage' => esc_html__( 'Show in Frontpage only', 'bosa' ),
),
) );
// 404 Error Page
Kirki::add_section( 'error404_options', array(
'title' => esc_html__( '404 Page', 'bosa' ),
'capability' => 'edit_theme_options',
'priority' => '160',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Image', 'bosa' ),
'description' => esc_html__( 'Recommended image size 360x200 pixel.', 'bosa' ),
'type' => 'image',
'settings' => 'error404_image',
'section' => 'error404_options',
'default' => '',
) );
// Preloader Options
Kirki::add_section( 'preloader_options', array(
'title' => esc_html__( 'Preloader', 'bosa' ),
'capability' => 'edit_theme_options',
'priority' => '170',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Preloading', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_preloader',
'section' => 'preloader_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Preloading Animations', 'bosa' ),
'type' => 'select',
'settings' => 'preloader_animation',
'section' => 'preloader_options',
'default' => 'animation_one',
'choices' => array(
'animation_white' => esc_html__( 'White Color to Fade', 'bosa' ),
'animation_black' => esc_html__( 'Black Color to Fade', 'bosa' ),
'animation_site_logo' => esc_html__( 'Site Logo', 'bosa' ),
'animation_one' => esc_html__( 'Animation One', 'bosa' ),
'animation_two' => esc_html__( 'Animation Two', 'bosa' ),
'animation_three' => esc_html__( 'Animation Three', 'bosa' ),
'animation_four' => esc_html__( 'Animation Four', 'bosa' ),
'animation_five' => esc_html__( 'Animation Five', 'bosa' ),
),
) );
// Breadcrumbs
Kirki::add_section( 'breadcrumbs_options', array(
'title' => esc_html__( 'Breadcrumbs', 'bosa' ),
'capability' => 'edit_theme_options',
'priority' => '180',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Breadcrumbs', 'bosa' ),
'type' => 'select',
'settings' => 'breadcrumbs_controls',
'section' => 'breadcrumbs_options',
'default' => 'disable_in_all_pages',
'choices' => array(
'disable_in_all_pages' => esc_html__( 'Disable in all Pages Only', 'bosa' ),
'disable_in_all_page_post' => esc_html__( 'Disable in all Pages & Posts', 'bosa' ),
'show_in_all_page_post' => esc_html__( 'Show in all Pages & Posts', 'bosa' ),
)
) );
// Responsive
Kirki::add_section( 'responsive_options', array(
'title' => esc_html__( 'Responsive', 'bosa' ),
'description' => esc_html__( 'These options will only apply to Tablet and Mobile devices. Please click on below Tablet or Mobile Icons to see changes.
', 'bosa' ),
'capability' => 'edit_theme_options',
'priority' => '190',
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Header Notification Bar', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_mobile_notification_bar',
'section' => 'responsive_options',
'default' => true,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Fixed Header', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_mobile_fixed_header',
'section' => 'responsive_options',
'default' => true,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Main Slider / Banner', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_mobile_main_slider',
'section' => 'responsive_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Highlighted Posts', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_mobile_highlight_posts',
'section' => 'responsive_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Featured Posts', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_mobile_feature_posts',
'section' => 'responsive_options',
'default' => false,
) );
Kirki::add_field( 'bosa', array(
'label' => esc_html__( 'Disable Scroll Top', 'bosa' ),
'type' => 'checkbox',
'settings' => 'disable_mobile_scroll_top',
'section' => 'responsive_options',
'default' => true,
) );
}