esc_html__( 'Post Category Colors', 'bloghash' ), 'panel' => 'bloghash_panel_general', 'priority' => 21, ); // Category color. $categories = get_categories( array( 'hide_empty' => 1 ) ); foreach ( $categories as $category ) { $options['setting'][ 'bloghash_category_color_' . esc_attr( $category->term_id ) ] = array( 'transport' => 'refresh', 'sanitize_callback' => 'bloghash_sanitize_color', 'control' => array( 'type' => 'bloghash-color', 'label' => sprintf( esc_html__( '%1$s Color', 'bloghash' ), esc_html( $category->name ) ), 'section' => 'bloghash_section_category_colors', 'priority' => 10, 'opacity' => false, ), ); } return $options; } } endif; new Bloghash_Customizer_Category_Colors();