<?php

namespace Hecate\Components\Traits;

use Hecate\Icon;

trait BuilderOverlayTrait {

	public function getOverlayClasses() {
		return array( 'hecate-component-overlay--builder' );
	}

	public function renderOverlay() {
		$overlayClasses       = $this->getOverlayClasses();
		$overlayClassesString = implode( ' ', $overlayClasses )
		?>
		<div class="hecate-component-overlay <?php echo esc_attr( $overlayClassesString ); ?>">
			<div class="hecate-component-overlay__cog">
				<?php
          // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
          echo Icon::get( 'font-awesome/cog-solid' );
        ?>
			</div>
		</div>
		<?php
	}
}
