<?php
/**
 * @author : Jegtheme
 */

namespace EPRESS\Module\Post;

use EPRESS\Module\ModuleOptionAbstract;

Class Post_Tag_Option extends ModuleOptionAbstract {
	public function get_category() {
		return esc_html__( 'EPRESS - Post', 'elementpress' );
	}

	public function compatible_column() {
		return array( 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12 );
	}

	public function get_module_name() {
		return esc_html__( 'ElementPress - Post Tag', 'elementpress' );
	}

	public function set_options() {

		$this->options[] = array(
			'type'        => 'textfield',
			'param_name'  => 'font_size',
			'heading'     => esc_html__( 'Font Size', 'elementpress' ),
			'description' => esc_html__( 'Set font size with unit (Ex: 36px or 4em).', 'elementpress' ),
			'group'       => esc_html__( 'Design', 'elementpress' ),
		);

		$this->options[] = array(
			'type'        => 'colorpicker',
			'param_name'  => 'text_color',
			'heading'     => esc_html__( 'Text Color', 'elementpress' ),
			'description' => esc_html__( 'Set text color.', 'elementpress' ),
			'group'       => esc_html__( 'Design', 'elementpress' ),
		);

		$this->options[] = array(
			'type'        => 'colorpicker',
			'param_name'  => 'bg_color',
			'heading'     => esc_html__( 'Background Color', 'elementpress' ),
			'description' => esc_html__( 'Set background color.', 'elementpress' ),
			'group'       => esc_html__( 'Design', 'elementpress' ),
		);

		$this->options[] = array(
			'type'        => 'colorpicker',
			'param_name'  => 'text_color_hover',
			'heading'     => esc_html__( 'Hover Text Color', 'elementpress' ),
			'description' => esc_html__( 'Set hover text color.', 'elementpress' ),
			'group'       => esc_html__( 'Design', 'elementpress' ),
		);

		$this->options[] = array(
			'type'        => 'colorpicker',
			'param_name'  => 'bg_color_hover',
			'heading'     => esc_html__( 'Hover Background Color', 'elementpress' ),
			'description' => esc_html__( 'Set hover background color.', 'elementpress' ),
			'group'       => esc_html__( 'Design', 'elementpress' ),
		);

		$this->set_style_option();
	}

	public function set_typography_option( $instance ) {

		$instance->add_group_control(
			\Elementor\Group_Control_Typography::get_type(),
			[
				'name'     => 'title_typography',
				'label'    => esc_html__( 'Typography', 'elementpress' ),
				'selector' => '{{WRAPPER}} .jeg_post_tags',
			]
		);
	}
}
