json['min'] = $this->min; $this->json['max'] = $this->max; $this->json['step'] = $this->step; $this->json['unit'] = $this->unit; } /** * Enqueue control related scripts/styles. * * @access public */ public function enqueue() { parent::enqueue(); $base_font_size = bloghash()->options->get( 'bloghash_html_base_font_size' ); $bfs = ( $base_font_size['desktop'] * 16 ) / 100; wp_localize_script( 'bloghash-range-js', 'range_obj', array( 'base_font' => $bfs, ) ); } /** * An Underscore (JS) template for this control's content (but not its container). * * Class variables for this control class are available in the `data` JS object; * export custom variables by overriding {@see WP_Customize_Control::to_json()}. * * @see WP_Customize_Control::print_template() */ protected function content_template() { ?>