0, 'vertical' => 0, 'blur' => 10, 'spread' => 0, 'color' => 'rgba(0,0,0,0.5)', ]; } /** * Get box shadow control sliders. * * Retrieve the sliders of the box shadow control. Sliders are used while * rendering the control output in the editor. * * @since 1.0.0 * @access public * * @return array Control sliders. */ public function getSliders() { return [ 'horizontal' => [ 'label' => __('Horizontal'), 'min' => -100, 'max' => 100, ], 'vertical' => [ 'label' => __('Vertical'), 'min' => -100, 'max' => 100, ], 'blur' => [ 'label' => __('Blur'), 'min' => 0, 'max' => 100, ], 'spread' => [ 'label' => __('Spread'), 'min' => -100, 'max' => 100, ], ]; } /** * Render box shadow control output in the editor. * * Used to generate the control HTML in the editor using Underscore JS * template. The variables for the class are available using `data` JS * object. * * @since 1.0.0 * @access public */ public function contentTemplate() { ?> <# var defaultColorValue = data.default.color ? ' data-default-color=' + data.default.color : ''; #>
getSliders() as $slider_name => $slider) : ?> getControlUid($slider_name) ?>