add_section( 'layout_options', array( 'title' => esc_html__( 'Layout Options', 'beetan' ), 'priority' => 30, ) ); // Site container width $wp_customize->add_setting( 'site_container_width', array( 'default' => 1200, "transport" => "postMessage", 'sanitize_callback' => 'absint', ) ); $wp_customize->add_control( new Beetan_Customize_Number_Control( $wp_customize, 'site_container_width', array( 'label' => esc_html__( 'Site Container Width', 'beetan' ), 'description' => esc_html__( 'Set site container width in PX.', 'beetan' ), 'section' => 'layout_options', 'input_attrs' => array( 'min' => 768, 'max' => 1920, 'step' => 1, ) ) ) ); // Site container Default layout $wp_customize->add_setting( 'default_container_layout', array( 'default' => 'box', 'sanitize_callback' => 'beetan_sanitize_select', ) ); $wp_customize->add_control( new WP_Customize_Control( $wp_customize, 'default_container_layout', array( 'label' => __( 'Default Layout', 'beetan' ), 'section' => 'layout_options', 'type' => 'select', 'choices' => array( 'box' => __( 'Box', 'beetan' ), 'contained' => __( 'Full Width - Contained', 'beetan' ), 'stretched' => __( 'Full Width - Stretched', 'beetan' ), ), ) ) ); // Page container layout $wp_customize->add_setting( 'page_container_layout', array( 'default' => '', 'sanitize_callback' => 'beetan_sanitize_select', ) ); $wp_customize->add_control( new WP_Customize_Control( $wp_customize, 'page_container_layout', array( 'label' => __( 'Page Layout', 'beetan' ), 'section' => 'layout_options', 'type' => 'select', 'choices' => array( '' => __( 'Default', 'beetan' ), 'box' => __( 'Box', 'beetan' ), 'contained' => __( 'Full Width - Contained', 'beetan' ), 'stretched' => __( 'Full Width - Stretched', 'beetan' ), ), ) ) ); // Single Post container layout $wp_customize->add_setting( 'post_container_layout', array( 'default' => '', 'sanitize_callback' => 'beetan_sanitize_select', ) ); $wp_customize->add_control( new WP_Customize_Control( $wp_customize, 'post_container_layout', array( 'label' => __( 'Single Post Layout', 'beetan' ), 'section' => 'layout_options', 'type' => 'select', 'choices' => array( '' => __( 'Default', 'beetan' ), 'box' => __( 'Box', 'beetan' ), 'contained' => __( 'Full Width - Contained', 'beetan' ), 'stretched' => __( 'Full Width - Stretched', 'beetan' ), ), ) ) ); // Blog/Archive container layout $wp_customize->add_setting( 'archive_post_container_layout', array( 'default' => '', 'sanitize_callback' => 'beetan_sanitize_select', ) ); $wp_customize->add_control( new WP_Customize_Control( $wp_customize, 'archive_post_container_layout', array( 'label' => __( 'Blog Archive Layout', 'beetan' ), 'section' => 'layout_options', 'type' => 'select', 'choices' => array( '' => __( 'Default', 'beetan' ), 'box' => __( 'Box', 'beetan' ), 'contained' => __( 'Full Width - Contained', 'beetan' ), 'stretched' => __( 'Full Width - Stretched', 'beetan' ), ), ) ) ); if ( beetan_is_woocommerce_active() ) { // Shop container layout $wp_customize->add_setting( 'archive_product_container_layout', array( 'default' => '', 'sanitize_callback' => 'beetan_sanitize_select', ) ); $wp_customize->add_control( new WP_Customize_Control( $wp_customize, 'archive_product_container_layout', array( 'label' => __( 'Shop Layout', 'beetan' ), 'section' => 'layout_options', 'type' => 'select', 'choices' => array( '' => __( 'Default', 'beetan' ), 'box' => __( 'Box', 'beetan' ), 'contained' => __( 'Full Width - Contained', 'beetan' ), 'stretched' => __( 'Full Width - Stretched', 'beetan' ), ), ) ) ); // Blog/Archive container layout $wp_customize->add_setting( 'product_container_layout', array( 'default' => '', 'sanitize_callback' => 'beetan_sanitize_select', ) ); $wp_customize->add_control( new WP_Customize_Control( $wp_customize, 'product_container_layout', array( 'label' => __( 'Single Product Layout', 'beetan' ), 'section' => 'layout_options', 'type' => 'select', 'choices' => array( '' => __( 'Default', 'beetan' ), 'box' => __( 'Box', 'beetan' ), 'contained' => __( 'Full Width - Contained', 'beetan' ), 'stretched' => __( 'Full Width - Stretched', 'beetan' ), ), ) ) ); }