<?php
    /**
     * Color_Palette customzer custom control
     * 
     * @package Blog Bee
     * @since 1.0.0
     */
    namespace BBE\Customizer\Controls;

    use BBE\Customizer\Base as Base;
    
    if( ! class_exists( __NAMESPACE__ . '\\Color_Palette' ) ) {
        /**
         * Toggle Button Class
         */
        class Color_Palette extends Base {
            /**
             * Type of control
             * 
             * @since 1.0.0
             * @var string
             */
            public $type = 'bbe-color-palette';

            /**
             * Type of color
             * 
             * @since 1.0.0
             * @var string
             */
            public $color_type = 'solid';

            /**
             * Palettes to include
             * 
             * @since 1.0.0
             * @var array
             */
            public $fields = [];

            /**
             * To json
             * 
             * @since 1.0.0
             */
            public function to_json() {
                parent::to_json();
                $this->json[ 'fields' ] = $this->fields;
                $this->json[ 'color_type' ] = $this->color_type;
            }
        }
        Color_Palette::set_control_type( 'bbe-color-palette' );
    }