HEX
Server: LiteSpeed
System: Linux sg-cp4.cloudnetwork.vn 4.18.0-553.69.1.lve.el8.x86_64 #1 SMP Wed Aug 13 19:53:59 UTC 2025 x86_64
User: thu28850 (1134)
PHP: 7.4.33
Disabled: NONE
Upload Files
File: //proc/self/cwd/wp-content/plugins/wcboost-variation-swatches/includes/customizer/size-control.php
<?php
namespace WCBoost\VariationSwatches\Customize;

defined( 'ABSPATH' ) || exit;

class Size_Control extends \WP_Customize_Control {
	/**
	 * Declare the control type.
	 *
	 * @var string
	 */
	public $type = 'wcboost-variation-swatches-size';

	/**
	 * Render control.
	 */
	public function render_content() {
		$size = $this->value();
		$size = wp_parse_args( $size, $this->setting->default );
		?>

		<?php if ( ! empty( $this->label ) ) : ?>
			<span class="customize-control-title"><?php echo esc_html( $this->label ); ?></span>
		<?php endif; ?>

		<?php if ( ! empty( $this->description ) ) : ?>
			<span class="description customize-control-description"><?php echo esc_html( $this->description ); ?></span>
		<?php endif; ?>

		<span class="customize-control-inside">
			<input type="text" size="3" pattern="\d*" value="<?php echo esc_attr( $size['width'] ) ?>" data-name="width"/>
			&times;
			<input type="text" size="3" pattern="\d*" value="<?php echo esc_attr( $size['height'] ) ?>" data-name="height"/>
		</span>
		<?php
	}
}