All checks were successful
Deploy / Deploy to Production (push) Successful in 22s
- jeu.php : supprime les espaces de l'URL (preg_replace), ajoute data-state="initial" sur l'overlay - Article.svelte : porte le CSS complet depuis l'ancienne app React (background opaque, play icon, hover, deactivate btn, game-active state) - JS : ignore les clics sur overlay ended, remet data-state="initial" au deactivate Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
21 lines
731 B
PHP
21 lines
731 B
PHP
<?php if ($block->url()->isNotEmpty()):
|
|
$iframeUrl = preg_replace('/\s+/', '', $block->url()->value());
|
|
?>
|
|
<div class="iframe-game-container">
|
|
<iframe
|
|
loading="eager"
|
|
importance="high"
|
|
width="400"
|
|
height="650"
|
|
style="border: none; overflow: hidden; pointer-events: none; display: block; width: 100%;"
|
|
src="<?= htmlspecialchars($iframeUrl, ENT_QUOTES, 'UTF-8') ?>"
|
|
></iframe>
|
|
<div class="iframe-click-overlay" data-state="initial">
|
|
<div class="overlay-content">
|
|
<div class="play-icon">▶</div>
|
|
<p class="overlay-message">Cliquez pour jouer</p>
|
|
</div>
|
|
</div>
|
|
<button class="iframe-deactivate-btn" title="Deactivate game (restore scrolling)">✕</button>
|
|
</div>
|
|
<?php endif ?>
|