add_panel( 'panel_layout', array( 'title' => esc_html__( 'レイアウト', 'baumkupen' ), 'priority'=> 30, ) ); // セクション ヘッダー $wp_customize->add_section( 'section_layout_header', array( 'title' => esc_html__( 'ヘッダー', 'baumkupen' ), 'panel'=>'panel_layout', ) ); // ヘッダーレイアウトの設定(モバイル) $wp_customize->add_setting( 'header_layout_mobile', array( 'sanitize_callback' => 'sanitize_text_field', 'default' => 'block_dropdown', ) ); $wp_customize->add_control( new Baumkupen_Radio_Image_Control( $wp_customize, 'header_layout_mobile', array( 'section' => 'section_layout_header', 'label' => esc_html__( 'ヘッダー(モバイル)', 'baumkupen' ), 'choices' => array( 'block_dropdown' => esc_html( 'header-layout-mobile-block-dropdown' ), 'block_dropdown_search' => esc_html( 'header-layout-mobile-block-dropdown-search' ), ) ) ) ); // ヘッダーレイアウトの設定(デスクトップ) $wp_customize->add_setting( 'header_layout_desktop', array( 'sanitize_callback' => 'sanitize_text_field', 'default' => 'block_dropdown', ) ); $wp_customize->add_control( new Baumkupen_Radio_Image_Control( $wp_customize, 'header_layout_desktop', array( 'section' => 'section_layout_header', 'label' => esc_html__( 'ヘッダー(デスクトップ)', 'baumkupen' ), 'choices' => array( 'block_dropdown' => esc_html( 'header-layout-desktop-block-dropdown' ), 'block_dropdown_search' => esc_html( 'header-layout-desktop-block-dropdown-search' ), 'flex_row_dropdown' => esc_html( 'header-layout-desktop-flex-row-dropdown' ), 'flex_row_dropdown_search' => esc_html( 'header-layout-desktop-flex-row-dropdown-search' ), ) ) ) ); // セクション 投稿一覧 $wp_customize->add_section( 'section_layout_index_posts', array( 'title' => esc_html__( '投稿一覧', 'baumkupen' ), 'panel'=>'panel_layout', // 'priority' => 30, ) ); // 投稿一覧の設定(モバイル) $wp_customize->add_setting( 'index_posts_layout_mobile', array( 'sanitize_callback' => 'sanitize_text_field', 'default' => 'thumbnail_square100_info', ) ); $wp_customize->add_control( new Baumkupen_Radio_Image_Control( $wp_customize, 'index_posts_layout_mobile', array( 'section' => 'section_layout_index_posts', 'label' => esc_html__( '投稿一覧(モバイル)', 'baumkupen' ), 'choices' => array( 'thumbnail_square100_info' => esc_html( 'index-posts-layout-mobile-thumbnail-square100-info' ), 'info_thumbnail_square100' => esc_html( 'index-posts-layout-mobile-info-thumbnail-square100' ), ) ) ) ); // 投稿一覧の設定(デスクトップ) $wp_customize->add_setting( 'index_posts_layout_desktop', array( 'sanitize_callback' => 'sanitize_text_field', 'default' => 'thumbnail_square100_info', ) ); $wp_customize->add_control( new Baumkupen_Radio_Image_Control( $wp_customize, 'index_posts_layout_desktop', array( 'section' => 'section_layout_index_posts', 'label' => esc_html__( '投稿一覧(デスクトップ)', 'baumkupen' ), 'choices' => array( 'thumbnail_square100_info' => esc_html( 'index-posts-layout-desktop-thumbnail-square100-info' ), 'info_thumbnail_square100' => esc_html( 'index-posts-layout-desktop-info-thumbnail-square100' ), 'thumbnail_wide320_info' => esc_html( 'index-posts-layout-desktop-thumbnail-wide320-info' ), 'info_thumbnail_wide320' => esc_html( 'index-posts-layout-desktop-info-thumbnail-wide320' ), ) ) ) ); // セクション サイドウィジェット $wp_customize->add_section( 'section_layout_sidebar_widget', array( 'title' => esc_html__( 'サイドウィジェット', 'baumkupen' ), 'panel'=>'panel_layout', // 'priority' => 30, ) ); // サイドウィジェット レイアウト $wp_customize->add_setting( 'sidebar_widget_layout', array( 'sanitize_callback' => 'sanitize_text_field', 'default' => 'right', ) ); $wp_customize->add_control( 'sidebar_widget_layout', array( 'type' => 'radio', 'section' => 'section_layout_sidebar_widget', 'label' => esc_html__( 'サイドウィジェット(デスクトップ)', 'baumkupen' ), 'choices' => array( 'none' => esc_html__( 'なし', 'baumkupen' ), 'right' => esc_html__( '右', 'baumkupen' ), 'left' => esc_html__( '左', 'baumkupen' ), ), ) ); // セクション 全体 $wp_customize->add_section( 'section_layout_other', array( 'title' => esc_html__( '全体', 'baumkupen' ), 'panel'=>'panel_layout', // 'priority' => 30, ) ); // サイトの全体幅 $wp_customize->add_setting( 'body_width_desktop', array( 'sanitize_callback' => 'sanitize_text_field', 'default' => 1024, ) ); $wp_customize->add_control( new Baumkupen_Range_Number_Px_Control( $wp_customize, 'body_width_desktop', array( 'section' => 'section_layout_other', 'label' => esc_html__( 'サイトの全体幅(デスクトップ)', 'baumkupen' ), 'input_attrs' => array( 'min' => 800, 'max' => 1920, 'step'=> 1, ), ) ) ); }