diff --git a/controls/multicolor/class-kirki-control-multicolor.php b/controls/multicolor/class-kirki-control-multicolor.php index 88c5158bf..c33177a3d 100644 --- a/controls/multicolor/class-kirki-control-multicolor.php +++ b/controls/multicolor/class-kirki-control-multicolor.php @@ -43,6 +43,14 @@ class Kirki_Control_Multicolor extends WP_Customize_Control { */ public $option_type = 'theme_mod'; + /** + * Enable/Disable Alpha channel on color pickers + * + * @access public + * @var boolean + */ + public $alpha = true; + /** * Constructor. * @@ -72,6 +80,7 @@ class Kirki_Control_Multicolor extends WP_Customize_Control { * @type array $choices List of choices for 'radio' or 'select' type controls, where * values are the keys, and labels are the values. * Default empty array. + * @type boolean $alpha Enables/Disables alpha channel on color pickers * @type array $input_attrs List of custom input attributes for control output, where * attribute names are the keys and values are the values. Not * used for 'checkbox', 'radio', 'select', 'textarea', or @@ -129,6 +138,7 @@ public function to_json() { $this->json['choices'] = $this->choices; $this->json['link'] = $this->get_link(); $this->json['id'] = $this->id; + $this->json['alpha'] = $this->alpha; $this->json['inputAttrs'] = ''; foreach ( $this->input_attrs as $attr => $value ) { @@ -162,7 +172,7 @@ protected function content_template() { <# if ( data.choices[ key ] ) { #> <# } #> - + <# } #> <# } #>