output_features = array( // Featured Image 'featured_image' => array( 'link' => true // Enable/disable linking ), // Post Title 'post_title' => array( 'link' => true // Enable/disable linking ), // Post Content 'post_content' => array( 'edit_content_type' => true // Content type (special case) ), // Read More 'read_more' => array( 'link' => true, // Enable/disable linking 'edit_label' => array( 'default' => baton_more_link_label( true ) ) // Edit label (pass a default) ) ); // Call the parent constructor here parent::__construct( $manager, $id, $args ); } /** * This function enqueues scripts and styles */ public function enqueue() { // Stylesheets wp_enqueue_style( 'baton-conductor', get_template_directory_uri() . '/css/baton-conductor.css', array( 'dashicons' ) ); // Scripts wp_enqueue_script( 'baton-conductor', get_template_directory_uri() . '/js/baton-conductor.js', array( 'backbone', 'jquery-ui-sortable' ), $this->version, true ); wp_localize_script( 'baton-conductor', 'baton_conductor', array( 'customizer' => array( 'section_sup_label' => _x( 'by Conductor', 'label applied to tag within Customizer section title for Baton Conductor', 'baton' ), 'control_enabled_label' => _x( 'Enabled', 'label applied to Customizer control title for Baton Conductor', 'baton' ) ), 'output' => array( 'priority_step_size' => 10 ) ) ); // Call the parent enqueue method here parent::enqueue(); } /** * This function renders the control's content. */ public function render_content() { global $_wp_additional_image_sizes; if ( ! empty( $this->description ) ) : ?> description; ?> settings['title'] ) ) : ?> settings['title']->value() ); ?>" link( 'title' ); ?> />
link( 'flexbox_columns' ); ?> /> settings['flexbox_columns']->value(); ?>
link( 'post_thumbnails_size' ); ?>> settings['post_thumbnails_size']->value(), '' ); ?> > '', 'width' => 0, 'height' => 0 ); // Built-in Image Sizes if ( in_array( $size, array( 'thumbnail', 'medium', 'medium_large', 'large' ) ) ) { $avail_image_sizes[$size]['label'] = $size; $avail_image_sizes[$size]['width'] = get_option( $size . '_size_w' ); $avail_image_sizes[$size]['height'] = get_option( $size . '_size_h' ); } // Additional Image Sizes else if ( isset( $_wp_additional_image_sizes ) && isset( $_wp_additional_image_sizes[$size] ) ) { $avail_image_sizes[$size]['label'] = $size; $avail_image_sizes[$size]['width'] = $_wp_additional_image_sizes[$size]['width']; $avail_image_sizes[$size]['height'] = $_wp_additional_image_sizes[$size]['height']; } // If width is 0, adjust the value if ( $avail_image_sizes[$size]['width'] == 0 ) $avail_image_sizes[$size]['width'] = 9999; // If height is 0, adjust the value if ( $avail_image_sizes[$size]['height'] == 0 ) $avail_image_sizes[$size]['height'] = 9999; } foreach ( $avail_image_sizes as $size => $atts ) : $dimensions = array( $atts['width'], $atts['height'] ); ?> settings['post_thumbnails_size']->value(), $size ); ?>>