<?php 


// Footer Controls

// WooCommerce-only controls -- the Shop Page section itself can also show
// for FluentCart-only sites (see fct_single_show_page_header below), but
// these specific settings (columns, WooCommerce sidebar, WooCommerce
// single product layout) only mean anything when WooCommerce is active.
if ( class_exists( 'WooCommerce' ) ) {

    new \Kirki\Field\Checkbox_Switch([
            'type'        => 'switch',
            'settings'    => 'shop_sidebar',
            'label'       => esc_html__( 'Show Shop Sidebar','edify'),
            'section'     => 'shop_section_id',
            'default'     => '',
            'priority'    => 10,
            'choices'     => [
                'on'  => esc_html__( 'Yes','edify'),
                'off' => esc_html__( 'No','edify'),
            ],
        ] );
      
      
        new \Kirki\Field\Select( [
            'type'        => 'select',
            'settings'    => 'shop_product_column',
            'label'       => esc_html__( 'Shop Column','edify'),
            'section'     => 'shop_section_id',
            'default'     => '4',
            'placeholder' => esc_html__( 'Select Column','edify'),
            'priority'    => 10,
            'multiple'    => 1,
            'choices'     => [
                '4' => esc_html__( '3 Columnn','edify'),
                '3' => esc_html__( '4 Column','edify'),
                '6' => esc_html__( '2 Column','edify'),
            ],
        ] );

        new \Kirki\Field\Select( [
            'type'        => 'select',
            'settings'    => 'shop_single_layout',
            'label'       => esc_html__( 'Single Product Layout','edify'),
            'description' => esc_html__( 'Choose how the single product page is laid out.','edify'),
            'section'     => 'shop_section_id',
            'default'     => 'default',
            'placeholder' => esc_html__( 'Select Layout','edify'),
            'priority'    => 10,
            'multiple'    => 1,
            'choices'     => [
                'default'        => esc_html__( 'Default','edify'),
                'sticky-sidebar' => esc_html__( 'Sticky Image + Description with Sidebar','edify'),
            ],
        ] );

        new \Kirki\Field\Select( [
            'type'        => 'select',
            'settings'    => 'shop_product_laptop_column',
            'label'       => esc_html__( 'Shop Laptop Column','edify'),
            'section'     => 'shop_section_id',
            'default'     => '6',
            'placeholder' => esc_html__( 'Select Column','edify'),
            'priority'    => 10,
            'multiple'    => 1,
            'choices'     => [
                '4' => esc_html__( '3 Columnn','edify'),
                '3' => esc_html__( '4 Column','edify'),
                '6' => esc_html__( '2 Column','edify'),
            ],
        ] );

}

// FluentCart-only control -- the Shop Page section itself can show for
// WooCommerce sites too, but this specific setting only means anything
// on a FluentCart single product page, so keep it out of the panel
// otherwise.
if ( class_exists( '\FluentCart\App\Services\TemplateService' ) ) {
    new \Kirki\Field\Checkbox_Switch( [
        'type'        => 'switch',
        'settings'    => 'fct_single_show_page_header',
        'label'       => esc_html__( 'Show Page Header (FluentCart Single Product)','edify'),
        'description' => esc_html__( 'Shows the breadcrumb banner above a FluentCart single product page.','edify'),
        'section'     => 'shop_section_id',
        'default'     => 'on',
        'priority'    => 10,
        'choices'     => [
            'on'  => esc_html__( 'Yes','edify'),
            'off' => esc_html__( 'No','edify'),
        ],
    ] );
}