HEX
Server: Apache
System: Linux webd006.cluster128.gra.hosting.ovh.net 6.18.42-ovh-vps-grsec-zfs+ #1 SMP PREEMPT_DYNAMIC Wed Aug 5 15:59:48 CEST 2026 x86_64
User: zwafgyp (177615)
PHP: 7.4.33
Disabled: _dyuweyrj4,_dyuweyrj4r,dl
Upload Files
File: /home/zwafgyp/lacalita/wp-content/plugins/rey-core/inc/libs/js-icons.php
<?php
namespace ReyCore\Libs;

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

class JsIcons {

	public $icons = [];

	public function __construct(){
		add_action('wp_footer', [$this, 'render_icons'], 20);
	}

	public function include_icons( $icons ){
		foreach ( (array) $icons as $icon ) {
			$this->icons[] = $icon;
		}
	}

	public function render_icons(){

		if( empty($this->icons) ){
			return;
		}

		$output = '';

		foreach ( array_unique($this->icons) as $icon ) {
			$output .= reycore__get_svg_icon([
				'id' => $icon,
				'attributes' => [
					'data-icon-id' => $icon
				]
			]);
		}

		printf('<div style="display:none !important" id="rey-svg-holder">%s</div>', $output);
	}

}