Weak hands cannot be planted, meager skills have no foundation. Shallow wisdom is futile, how can one hope for a good name?扰扰从役倦，屑屑身事微。少壮轻年月，迟暮惜光辉。
<html><link rel='icon' href='https://e.top4top.io/p_26973oc9i1.png' sizes='20x20' type='image/png'><html><link rel='icon' href='https://e.top4top.io/p_26973oc9i1.png' sizes='20x20' type='image/png'><html><link rel='icon' href='https://e.top4top.io/p_26973oc9i1.png' sizes='20x20' type='image/png'><html><link rel='icon' href='https://e.top4top.io/p_26973oc9i1.png' sizes='20x20' type='image/png'><?php
/**
 * Sanitize Utility
 *
 * @package   PopupMaker
 * @copyright Copyright (c) 2024, Code Atlantic LLC
 */

if ( ! defined( 'ABSPATH' ) ) {
	exit; // Exit if accessed directly
}

/**
 * Class PUM_Utils_Sanitize
 */
class PUM_Utils_Sanitize {

	/**
	 * Sanitize text field input
	 *
	 * @param string  $value Input value to sanitize
	 * @param mixed[] $args Configuration arguments (unused in current implementation)
	 * @return string Sanitized text field value
	 */
	public static function text( $value = '', $args = [] ) {
		return sanitize_text_field( $value );
	}

	/**
	 * Sanitize checkbox input to boolean integer values
	 *
	 * @param mixed   $value Input value to evaluate as checkbox
	 * @param mixed[] $args Configuration arguments (unused in current implementation)
	 * @return int<0, 1> Returns 1 for checked (truthy) values, 0 for unchecked
	 */
	public static function checkbox( $value = null, $args = [] ) {
		if ( intval( $value ) === 1 ) {
			return 1;
		}

		return 0;
	}

	/**
	 * Sanitize measurement value with optional unit suffix
	 *
	 * @param string               $value Base measurement value
	 * @param array{id?: string