function stpb_chart($pre_name = '', $data_values = array(), $post = false, $no_value = false, $interface = false) { ?> <div class="item"> <div class="left width-50"> <?php stpb_input_text($pre_name . '[title]', $data_values['title']); ?> </div> <div class="right width-50"> <strong><?php _e('Title', 'smooththemes'); ?> </strong> <span><?php _e('Title of chart', 'smooththemes'); ?> </span> </div> </div> <div class="item"> <div class="left width-50"> <?php stpb_input_text($pre_name . '[percent]', $data_values['percent']); ?> </div> <div class="right width-50"> <strong><?php _e('Percent', 'smooththemes'); ?> </strong> <span><?php _e('Percent number the pie chart should have', 'smooththemes'); ?> </span> </div> </div> <div class="item"> <div class="left width-50"> <?php stpb_input_text($pre_name . '[size]', $data_values['size']); ?> </div> <div class="right width-50"> <strong><?php _e('Chart size', 'smooththemes'); ?> </strong> <span><?php _e('Chart size in pixel.', 'smooththemes'); ?> </span> </div> </div> <div class="item"> <div class="left width-50"> <?php stpb_input_select_one($pre_name . '[type]', $data_values['type'], array('number' => __('Number percent inside', 'smooththemes'), 'icon' => __('Icon inside', 'smooththemes')), '.chart_icon'); ?> </div> <div class="right width-50"> <strong><?php _e('Display type', 'smooththemes'); ?> </strong> </div> </div> <div class="item show-on-select-change chart_icon" show-on="icon"> <div class="left width-50"> <?php stpb_input_icon_popup($pre_name . '[icon]', $data_values['icon']); ?> </div> <div class="right width-50"> <strong><?php _e('Icon', 'smooththemes'); ?> </strong> <span><?php _e('Select your icon.', 'smooththemes'); ?> </span> </div> </div> <div class="item"> <div class="left width-50"> <?php stpb_input_text($pre_name . '[lineWidth]', $data_values['lineWidth']); ?> </div> <div class="right width-50"> <strong><?php _e('Line Width', 'smooththemes'); ?> </strong> <span><?php _e('Width of the bar line in pixel.', 'smooththemes'); ?> </span> </div> </div> <div class="item barColor"> <div class="left width-50"> <?php stpb_input_color($pre_name . '[barColor]', $data_values['barColor']); ?> </div> <div class="right width-50"> <strong><?php _e('Bar Color', 'smooththemes'); ?> </strong> <span><?php _e('The color of the curcular bar.', 'smooththemes'); ?> </span> </div> </div> <div class="item trackColor"> <div class="left width-50"> <?php stpb_input_color($pre_name . '[trackColor]', $data_values['trackColor']); ?> </div> <div class="right width-50"> <strong><?php _e('Track Color', 'smooththemes'); ?> </strong> <span><?php _e('The color of the track for the bar.', 'smooththemes'); ?> </span> </div> </div> <div class="item"> <strong><?php _e('Description', 'smooththemes'); ?> </strong> <span><?php _e('Enter some description for this chart', 'smooththemes'); ?> </span> <?php stpb_input_textarea($pre_name . '[desc]', $data_values['desc']); ?> <span class="desc"><?php _e('Arbitrary text or HTML', 'smooththemes'); ?> </span> <p><label><?php stpb_input_checkbox($pre_name . '[autop]', $data_values['autop'], 1); ?> <?php _e('Automatically add paragraphs', 'smooththemes'); ?> </label></p> </div> <?php }
function stpb_input_icon($name = '', $save_value = '', $class = "") { stpb_input_icon_popup($name, $save_value, $class); /* ?> <span class="st-icon-wrap"> <input type="hidden" value="<?php echo esc_attr($save_value); ?>" class="st-icon-value" data-name="<?php echo $name; ?>"> </span> <?php */ }