APmanageur Wi-Fi V1.0

This commit is contained in:
yoannmultigaming committed 2026-11-21 02:08:05 +01:00
1 parent d87b617a38
commit abf33b9929
8 files changed
+273 -182

No files matched your search

+29 -21
View File
@@ -3137,7 +3137,6 @@
<input id="packetFilterInput" type="text"
placeholder="Filtrer paquets ou domaine (ex: google.com, dns, icmp, 10.42.0.1...)"
data-i18n-placeholder="placeholder_filter_packets" autocomplete="off">
<button id="clearFilterBtn" class="clear-filter-btn" type="button" title="Effacer" data-i18n-title="btn_clear">✕</button>
</div>
<div class="filter-side-controls">
<label class="check" style="margin:0;white-space:nowrap;font-size:13px"><input id="autoScrollCheck"
@@ -6301,8 +6300,8 @@
<button type="button" id="btnEggGame_2048" class="game-switch-btn" onclick="switchEasterEggGame('2048')" style="padding:4px 8px;font-size:11px;border-radius:6px;white-space:nowrap;display:inline-flex;align-items:center;gap:4px">🔢 <span>2048</span></button>
</div>
</div>
<div class="modal-body" style="padding:0;flex:1;background:var(--bg,#071326);display:flex;justify-content:center;align-items:center;min-height:300px">
<iframe id="easterEggGameIframe" src="" style="width:100%;height:540px;border:0;display:block;transition:height 0.25s cubic-bezier(0.4,0,0.2,1)" title="Easter Egg Game" allow="autoplay"></iframe>
<div class="modal-body" style="padding:0;flex:1;background:var(--bg,#071326);display:flex;justify-content:center;align-items:center;min-height:300px;overflow:hidden">
<iframe id="easterEggGameIframe" src="" scrolling="no" style="width:100%;height:490px;border:0;display:block;overflow:hidden;transition:height 0.25s cubic-bezier(0.4,0,0.2,1)" title="Easter Egg Game" allow="autoplay"></iframe>
</div>
</div>
</div>
@@ -9104,8 +9103,15 @@ ${vpnBadgeTopo}
function setQuotaPreset(val, unit) {
if ($('inputQuotaValue')) $('inputQuotaValue').value = val;
if ($('inputRateUp')) $('inputRateUp').value = upMbps;
if ($('selectRateUpUnit')) $('selectRateUpUnit').value = 'Mbps';
if ($('selectQuotaUnit')) $('selectQuotaUnit').value = unit;
updateQuotaPreview();
}
function setBwPreset(downMbps, upMbps) {
if ($('inputRateDown')) $('inputRateDown').value = downMbps;
if ($('selectRateDownUnit')) $('selectRateDownUnit').value = 'Mbps';
if ($('selectQuotaUnit')) $('selectQuotaUnit').value = unit;
updateQuotaPreview();
}
async function onQuotaPeriodChanged() {
@@ -10956,15 +10962,17 @@ ${vpnBadgeTopo}
document.querySelectorAll('.filter-chip').forEach(c => c.classList.remove('active'));
renderCaptureTable();
};
$('clearFilterBtn').onclick = function () {
$('packetFilterInput').value = '';
captureFilter = '';
capturePage = 1;
document.querySelectorAll('.filter-chip').forEach(c => c.classList.remove('active'));
const allChip = document.querySelector('.filter-chip[data-filter=""]');
if (allChip) allChip.classList.add('active');
renderCaptureTable();
};
if ($('clearFilterBtn')) {
$('clearFilterBtn').onclick = function () {
$('packetFilterInput').value = '';
captureFilter = '';
capturePage = 1;
document.querySelectorAll('.filter-chip').forEach(c => c.classList.remove('active'));
const allChip = document.querySelector('.filter-chip[data-filter=""]');
if (allChip) allChip.classList.add('active');
renderCaptureTable();
};
}
document.querySelectorAll('.filter-chip').forEach(chip => {
chip.onclick = function () {
document.querySelectorAll('.filter-chip').forEach(c => c.classList.remove('active'));
@@ -14470,13 +14478,13 @@ ${vpnBadgeTopo}
};
const GAME_DIMENSIONS = {
tetris: { maxWidth: '560px', height: '540px' },
dino: { maxWidth: '720px', height: '370px' },
zipline: { maxWidth: '550px', height: '520px' },
demineur: { maxWidth: '570px', height: '560px' },
pacman: { maxWidth: '550px', height: '540px' },
spaceinvaders: { maxWidth: '580px', height: '570px' },
'2048': { maxWidth: '550px', height: '530px' }
tetris: { maxWidth: '540px', height: '490px' },
dino: { maxWidth: '680px', height: '320px' },
zipline: { maxWidth: '540px', height: '475px' },
demineur: { maxWidth: '560px', height: '480px' },
pacman: { maxWidth: '540px', height: '480px' },
spaceinvaders: { maxWidth: '550px', height: '470px' },
'2048': { maxWidth: '540px', height: '440px' }
};
window.switchEasterEggGame = function (gameName) {
+43 -31
View File
@@ -95,6 +95,17 @@
font-family: 'Courier New', monospace !important;
}
html, body {
overflow: hidden !important;
height: 100%;
width: 100%;
margin: 0;
padding: 0;
box-sizing: border-box;
}
::-webkit-scrollbar { display: none !important; width: 0 !important; height: 0 !important; }
* { scrollbar-width: none !important; }
body {
background: var(--bg);
color: var(--text);
@@ -103,9 +114,8 @@
flex-direction: column;
align-items: center;
justify-content: center;
min-height: 100vh;
overflow-x: hidden;
padding: 4px;
height: 100%;
padding: 6px;
transition: background 0.3s ease, color 0.3s ease;
}
@@ -113,14 +123,15 @@
background: var(--card-bg);
border: 1px solid var(--border);
border-radius: 14px;
padding: 10px 14px;
padding: 8px 12px;
box-shadow: 0 10px 30px rgba(0,0,0,0.4), 0 0 20px rgba(92,167,255,0.1);
display: flex;
flex-direction: column;
align-items: center;
width: 100%;
max-width: 400px;
max-width: 360px;
position: relative;
flex-shrink: 0;
}
.header-bar {
@@ -128,33 +139,33 @@
justify-content: space-between;
align-items: center;
width: 100%;
margin-bottom: 8px;
margin-bottom: 6px;
}
.title-area h1 {
font-size: 38px;
font-size: 28px;
font-weight: 900;
line-height: 1;
color: var(--blue);
letter-spacing: -1px;
}
.title-area p {
font-size: 11.5px;
font-size: 10.5px;
color: var(--muted);
margin-top: 2px;
margin-top: 1px;
}
.scores-row {
display: flex;
gap: 8px;
gap: 6px;
}
.score-badge {
background: var(--panel-box);
border: 1px solid var(--border);
border-radius: 8px;
padding: 6px 12px;
min-width: 72px;
padding: 4px 8px;
min-width: 58px;
text-align: center;
}
.score-badge .score-label {
@@ -176,8 +187,8 @@
justify-content: space-between;
align-items: center;
width: 100%;
margin-bottom: 14px;
gap: 8px;
margin-bottom: 6px;
gap: 6px;
}
.btn {
@@ -185,9 +196,9 @@
color: var(--blue-btn-text);
border: 0;
border-radius: 6px;
padding: 7px 14px;
padding: 5px 10px;
font-weight: 700;
font-size: 12px;
font-size: 11.5px;
cursor: pointer;
display: inline-flex;
align-items: center;
@@ -208,13 +219,13 @@
position: relative;
background: var(--grid-bg);
border-radius: 10px;
width: 330px;
height: 330px;
padding: 10px;
width: 296px;
height: 296px;
padding: 8px;
display: grid;
grid-template-columns: repeat(4, 1fr);
grid-template-rows: repeat(4, 1fr);
gap: 10px;
gap: 8px;
touch-action: none;
box-shadow: inset 0 0 10px rgba(0,0,0,0.3);
}
@@ -228,23 +239,23 @@
.tile-layer {
position: absolute;
top: 10px;
left: 10px;
width: 310px;
height: 310px;
top: 8px;
left: 8px;
width: 280px;
height: 280px;
pointer-events: none;
}
.tile {
position: absolute;
width: 70px;
height: 70px;
width: 64px;
height: 64px;
border-radius: 6px;
display: flex;
align-items: center;
justify-content: center;
font-weight: 800;
font-size: 26px;
font-size: 24px;
transition: transform 0.11s ease-in-out, opacity 0.11s ease-in-out;
box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}
@@ -318,9 +329,10 @@
.instructions {
font-size: 11px;
color: var(--muted);
line-height: 1.4;
line-height: 1.35;
text-align: center;
margin-top: 12px;
margin-top: 6px;
padding: 2px 4px;
}
.instructions kbd {
background: var(--panel-box);
@@ -605,8 +617,8 @@
const layer = document.getElementById('tileLayer');
layer.innerHTML = '';
const CELL_SIZE = 70;
const GAP = 10;
const CELL_SIZE = 64;
const GAP = 8;
for (let r = 0; r < SIZE; r++) {
for (let c = 0; c < SIZE; c++) {
+43 -29
View File
@@ -123,6 +123,17 @@
font-family: 'Courier New', monospace !important;
}
html, body {
overflow: hidden !important;
height: 100%;
width: 100%;
margin: 0;
padding: 0;
box-sizing: border-box;
}
::-webkit-scrollbar { display: none !important; width: 0 !important; height: 0 !important; }
* { scrollbar-width: none !important; }
body {
background: var(--bg);
color: var(--text);
@@ -131,9 +142,8 @@
flex-direction: column;
align-items: center;
justify-content: center;
min-height: 100vh;
overflow-x: hidden;
padding: 4px;
height: 100%;
padding: 6px;
transition: background 0.3s ease, color 0.3s ease;
}
@@ -141,13 +151,14 @@
background: var(--card-bg);
border: 1px solid var(--border);
border-radius: 14px;
padding: 10px 14px;
padding: 8px 12px;
box-shadow: 0 10px 30px rgba(0,0,0,0.4), 0 0 20px rgba(92,167,255,0.1);
display: flex;
flex-direction: column;
align-items: center;
max-width: 540px;
width: 100%;
flex-shrink: 0;
}
.top-controls {
@@ -155,18 +166,17 @@
justify-content: space-between;
align-items: center;
width: 100%;
margin-bottom: 12px;
gap: 10px;
flex-wrap: wrap;
margin-bottom: 6px;
gap: 8px;
}
.level-select {
background: var(--panel-box);
color: var(--text);
border: 1px solid var(--border);
padding: 6px 10px;
padding: 4px 8px;
border-radius: 6px;
font-size: 12px;
font-size: 11.5px;
cursor: pointer;
}
@@ -174,9 +184,9 @@
background: var(--panel-box);
color: var(--text);
border: 1px solid var(--border);
padding: 6px 12px;
padding: 4px 10px;
border-radius: 6px;
font-size: 12px;
font-size: 11.5px;
cursor: pointer;
display: inline-flex;
align-items: center;
@@ -198,33 +208,33 @@
background: var(--panel-box);
border: 2px solid var(--border);
border-radius: 8px;
padding: 8px 14px;
padding: 4px 12px;
width: 100%;
margin-bottom: 12px;
margin-bottom: 6px;
}
.digital-counter {
background: var(--display-bg);
color: var(--display-text);
font-family: 'Courier New', Courier, monospace;
font-size: 26px;
font-size: 22px;
font-weight: 900;
padding: 2px 10px;
padding: 2px 8px;
border-radius: 4px;
border: 1px solid var(--border);
letter-spacing: 2px;
min-width: 70px;
min-width: 62px;
text-align: center;
text-shadow: 0 0 6px currentColor;
}
.face-btn {
font-size: 26px;
font-size: 22px;
background: var(--cell-up);
border: 2px outset var(--cell-border-light);
border-radius: 50%;
width: 44px;
height: 44px;
width: 36px;
height: 36px;
display: flex;
align-items: center;
justify-content: center;
@@ -237,10 +247,9 @@
}
.board-wrap {
overflow: auto;
overflow: hidden !important;
max-width: 100%;
max-height: 400px;
padding: 4px;
padding: 3px;
border-radius: 8px;
background: var(--display-bg);
border: 2px solid var(--border);
@@ -256,14 +265,14 @@
}
.cell {
width: 23px;
height: 23px;
width: var(--cell-size, 18px);
height: var(--cell-size, 18px);
background: var(--cell-up);
border: 2px outset var(--cell-border-light);
display: flex;
align-items: center;
justify-content: center;
font-size: 13px;
font-size: var(--cell-font, 11px);
font-weight: 800;
cursor: pointer;
user-select: none;
@@ -287,11 +296,12 @@
.c-8 { color: #6b7280; }
.instructions {
font-size: 11.5px;
font-size: 11px;
color: var(--muted);
margin-top: 12px;
margin-top: 6px;
text-align: center;
line-height: 1.4;
line-height: 1.35;
padding: 2px 4px;
}
</style>
</head>
@@ -486,7 +496,11 @@
const gridEl = document.getElementById('mineGrid');
gridEl.innerHTML = '';
gridEl.style.gridTemplateColumns = `repeat(${cols}, 23px)`;
const cellSize = cols > 16 ? 15 : (cols > 9 ? 18 : 24);
const cellFont = cols > 16 ? '10px' : (cols > 9 ? '11px' : '13px');
document.documentElement.style.setProperty('--cell-size', cellSize + 'px');
document.documentElement.style.setProperty('--cell-font', cellFont);
gridEl.style.gridTemplateColumns = `repeat(${cols}, ${cellSize}px)`;
board = [];
for (let r = 0; r < rows; r++) {
+26 -13
View File
@@ -150,6 +150,17 @@
--star-color: #00ff41;
}
html, body {
overflow: hidden !important;
height: 100%;
width: 100%;
margin: 0;
padding: 0;
box-sizing: border-box;
}
::-webkit-scrollbar { display: none !important; width: 0 !important; height: 0 !important; }
* { scrollbar-width: none !important; }
body {
background: var(--bg);
color: var(--text);
@@ -158,32 +169,32 @@
flex-direction: column;
align-items: center;
justify-content: center;
min-height: 100vh;
overflow: hidden;
padding: 10px;
height: 100%;
padding: 6px;
transition: background 0.3s ease, color 0.3s ease;
}
.game-card {
background: var(--card-bg);
border: 1px solid var(--border);
border-radius: 14px;
padding: 16px;
padding: 10px 14px;
box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), 0 0 20px rgba(92, 167, 255, 0.12);
position: relative;
max-width: 700px;
max-width: 660px;
width: 100%;
flex-shrink: 0;
transition: all 0.3s ease;
}
.header-bar {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 12px;
font-size: 14px;
margin-bottom: 6px;
font-size: 13px;
color: var(--muted);
}
.scores {
font-size: 18px;
font-size: 17px;
font-weight: 700;
letter-spacing: 2px;
color: var(--blue);
@@ -207,17 +218,19 @@
canvas {
display: block;
width: 100%;
height: 220px;
height: 200px;
cursor: pointer;
}
.controls-hint {
display: flex;
justify-content: space-between;
align-items: center;
margin-top: 12px;
font-size: 12px;
margin-top: 6px;
font-size: 11px;
color: var(--muted);
flex-wrap: wrap;
gap: 6px;
}
gap: 8px;
}
.controls-hint kbd {
@@ -278,7 +291,7 @@
</div>
<div class="canvas-wrap" id="canvasWrap">
<canvas id="dinoCanvas" width="640" height="220"></canvas>
<canvas id="dinoCanvas" width="640" height="200"></canvas>
<div id="gameOverlay" class="overlay-message" style="display:none">
<h2 id="dinoGameOverText">G A M E &nbsp; O V E R</h2>
<button id="dinoRestartBtn" class="restart-btn" onclick="resetGame()">🔄 REJOUER (Espace)</button>
@@ -408,7 +421,7 @@
const overlay = document.getElementById('gameOverlay');
const canvasWrap = document.getElementById('canvasWrap');
const GROUND_Y = 180;
const GROUND_Y = 165;
let highScore = parseInt(localStorage.getItem('ap_dino_hi') || '0', 10);
hiScoreEl.textContent = String(highScore).padStart(5, '0');
+28 -15
View File
@@ -109,6 +109,17 @@
font-family: 'Courier New', monospace !important;
}
html, body {
overflow: hidden !important;
height: 100%;
width: 100%;
margin: 0;
padding: 0;
box-sizing: border-box;
}
::-webkit-scrollbar { display: none !important; width: 0 !important; height: 0 !important; }
* { scrollbar-width: none !important; }
body {
background: var(--bg);
color: var(--text);
@@ -117,9 +128,8 @@
flex-direction: column;
align-items: center;
justify-content: center;
min-height: 100vh;
overflow-x: hidden;
padding: 4px;
height: 100%;
padding: 6px;
transition: background 0.3s ease, color 0.3s ease;
}
@@ -127,13 +137,14 @@
background: var(--card-bg);
border: 1px solid var(--border);
border-radius: 14px;
padding: 10px 12px;
padding: 8px 12px;
box-shadow: 0 10px 30px rgba(0,0,0,0.5), 0 0 20px rgba(92,167,255,0.12);
display: flex;
flex-direction: column;
align-items: center;
max-width: 480px;
width: 100%;
flex-shrink: 0;
}
.header-bar {
@@ -141,8 +152,8 @@
justify-content: space-between;
align-items: center;
width: 100%;
margin-bottom: 10px;
padding: 6px 10px;
margin-bottom: 6px;
padding: 4px 10px;
background: var(--panel-box);
border-radius: 8px;
border: 1px solid var(--border);
@@ -235,10 +246,12 @@
}
.controls-hint {
margin-top: 8px;
margin-top: 6px;
font-size: 11px;
color: var(--muted);
text-align: center;
line-height: 1.35;
padding: 2px 4px;
}
</style>
</head>
@@ -255,7 +268,7 @@
</div>
<div class="canvas-wrap">
<canvas id="pacmanCanvas" width="380" height="420"></canvas>
<canvas id="pacmanCanvas" width="342" height="378"></canvas>
<div id="gameOverlay" class="overlay" style="display:none">
<h2 id="overlayTitle">GAME OVER</h2>
@@ -415,7 +428,7 @@
const canvas = document.getElementById('pacmanCanvas');
const ctx = canvas.getContext('2d');
const TILE = 20;
const TILE = 18;
const COLS = 19;
const ROWS = 21;
@@ -445,10 +458,10 @@
function initGhosts() {
ghosts = [
{ x: 9, y: 8, pixelX: 9 * TILE, pixelY: 8 * TILE, dirX: 0, dirY: -1, color: GHOST_COLORS[0], speed: 1.8, isEaten: false },
{ x: 8, y: 10, pixelX: 8 * TILE, pixelY: 10 * TILE, dirX: 1, dirY: 0, color: GHOST_COLORS[1], speed: 1.6, isEaten: false },
{ x: 9, y: 10, pixelX: 9 * TILE, pixelY: 10 * TILE, dirX: 0, dirY: -1, color: GHOST_COLORS[2], speed: 1.6, isEaten: false },
{ x: 10, y: 10, pixelX: 10 * TILE, pixelY: 10 * TILE, dirX: -1, dirY: 0, color: GHOST_COLORS[3], speed: 1.5, isEaten: false }
{ x: 9, y: 8, pixelX: 9 * TILE, pixelY: 8 * TILE, dirX: 0, dirY: -1, color: GHOST_COLORS[0], speed: 2, isEaten: false },
{ x: 8, y: 10, pixelX: 8 * TILE, pixelY: 10 * TILE, dirX: 1, dirY: 0, color: GHOST_COLORS[1], speed: 2, isEaten: false },
{ x: 9, y: 10, pixelX: 9 * TILE, pixelY: 10 * TILE, dirX: 0, dirY: -1, color: GHOST_COLORS[2], speed: 2, isEaten: false },
{ x: 10, y: 10, pixelX: 10 * TILE, pixelY: 10 * TILE, dirX: -1, dirY: 0, color: GHOST_COLORS[3], speed: 2, isEaten: false }
];
}
@@ -576,8 +589,8 @@
// Move Ghosts
ghosts.forEach(g => {
const gOnGridX = (g.pixelX % TILE === 0);
const gOnGridY = (g.pixelY % TILE === 0);
const gOnGridX = (Math.round(g.pixelX) % TILE === 0);
const gOnGridY = (Math.round(g.pixelY) % TILE === 0);
if (gOnGridX && gOnGridY) {
const gx = Math.round(g.pixelX / TILE);
+22 -9
View File
@@ -123,6 +123,17 @@
font-family: 'Courier New', monospace !important;
}
html, body {
overflow: hidden !important;
height: 100%;
width: 100%;
margin: 0;
padding: 0;
box-sizing: border-box;
}
::-webkit-scrollbar { display: none !important; width: 0 !important; height: 0 !important; }
* { scrollbar-width: none !important; }
body {
background: var(--bg);
color: var(--text);
@@ -131,9 +142,8 @@
flex-direction: column;
align-items: center;
justify-content: center;
min-height: 100vh;
overflow-x: hidden;
padding: 4px;
height: 100%;
padding: 6px;
transition: background 0.3s ease, color 0.3s ease;
}
@@ -141,13 +151,14 @@
background: var(--card-bg);
border: 1px solid var(--border);
border-radius: 14px;
padding: 10px 12px;
padding: 8px 12px;
box-shadow: 0 10px 30px rgba(0,0,0,0.5), 0 0 20px rgba(92,167,255,0.12);
display: flex;
flex-direction: column;
align-items: center;
max-width: 580px;
max-width: 520px;
width: 100%;
flex-shrink: 0;
}
.header-bar {
@@ -155,8 +166,8 @@
justify-content: space-between;
align-items: center;
width: 100%;
margin-bottom: 10px;
padding: 6px 14px;
margin-bottom: 6px;
padding: 4px 12px;
background: var(--panel-box);
border-radius: 8px;
border: 1px solid var(--border);
@@ -252,10 +263,12 @@
}
.controls-hint {
margin-top: 8px;
margin-top: 6px;
font-size: 11px;
color: var(--muted);
text-align: center;
line-height: 1.35;
padding: 2px 4px;
}
</style>
</head>
@@ -272,7 +285,7 @@
</div>
<div class="canvas-wrap">
<canvas id="siCanvas" width="520" height="420"></canvas>
<canvas id="siCanvas" width="480" height="360"></canvas>
<div id="gameOverlay" class="overlay" style="display:none">
<h2 id="overlayTitle">GAME OVER</h2>
+36 -30
View File
@@ -93,6 +93,17 @@
font-family: 'Courier New', monospace !important;
}
html, body {
overflow: hidden !important;
height: 100%;
width: 100%;
margin: 0;
padding: 0;
box-sizing: border-box;
}
::-webkit-scrollbar { display: none !important; width: 0 !important; height: 0 !important; }
* { scrollbar-width: none !important; }
* { box-sizing: border-box; margin: 0; padding: 0; user-select: none; }
body {
background: var(--bg);
@@ -102,21 +113,22 @@
flex-direction: column;
align-items: center;
justify-content: center;
min-height: 100vh;
overflow: hidden;
padding: 4px;
height: 100%;
padding: 6px;
transition: background 0.3s ease, color 0.3s ease;
}
.arcade-wrap {
display: flex;
gap: 14px;
flex-direction: row !important;
gap: 12px;
align-items: flex-start;
background: var(--card-bg);
border: 1px solid var(--border);
border-radius: 14px;
padding: 12px;
padding: 10px;
box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4), 0 0 20px rgba(92, 167, 255, 0.1);
position: relative;
flex-shrink: 0;
transition: all 0.3s ease;
}
.canvas-container {
@@ -133,21 +145,21 @@
.sidebar {
display: flex;
flex-direction: column;
gap: 8px;
width: 154px;
gap: 6px;
width: 146px;
}
.panel-box {
background: var(--panel-box);
border: 1px solid var(--border);
border-radius: 8px;
padding: 8px;
padding: 5px;
text-align: center;
}
.stats-box {
display: grid;
grid-template-columns: 1fr 1fr 1fr;
gap: 2px;
padding: 6px 2px;
padding: 4px 2px;
}
.stat-col {
display: flex;
@@ -155,14 +167,14 @@
align-items: center;
}
.stat-col h3 {
font-size: 10px;
font-size: 9.5px;
text-transform: uppercase;
letter-spacing: 0.5px;
color: var(--muted);
margin-bottom: 2px;
}
.stat-col .value {
font-size: 15px;
font-size: 14px;
font-weight: 700;
color: var(--blue);
font-family: "Courier New", Courier, monospace;
@@ -177,16 +189,16 @@
.btn-row {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 6px;
gap: 5px;
}
.btn {
background: var(--blue);
color: var(--blue-btn-text);
border: 0;
border-radius: 6px;
padding: 7px 8px;
padding: 6px 6px;
font-weight: 700;
font-size: 12px;
font-size: 11.5px;
cursor: pointer;
transition: all .15s ease;
width: 100%;
@@ -200,21 +212,21 @@
}
.btn.secondary:hover { opacity: 0.85; }
.controls-help {
font-size: 10.5px;
font-size: 9.5px;
color: var(--muted);
line-height: 1.45;
line-height: 1.35;
background: rgba(0,0,0,0.12);
border-radius: 6px;
padding: 6px 8px;
padding: 5px 6px;
border: 1px solid var(--border);
}
.controls-help kbd {
background: var(--panel-box);
color: var(--text);
border: 1px solid var(--border);
padding: 1px 4px;
padding: 1px 3px;
border-radius: 3px;
font-size: 10px;
font-size: 9px;
font-family: monospace;
}
.touch-controls {
@@ -239,12 +251,6 @@
touch-action: manipulation;
}
.touch-btn:active { background: var(--blue); color: var(--blue-btn-text); }
@media (max-width: 360px) {
.arcade-wrap { flex-direction: column; align-items: center; padding: 6px; }
.sidebar { width: 100%; flex-direction: row; flex-wrap: wrap; justify-content: space-between; }
.sidebar .panel-box { flex: 1; min-width: 80px; }
.touch-controls { display: grid; }
}
.overlay-msg {
position: absolute;
inset: 0;
@@ -269,7 +275,7 @@
<div class="arcade-wrap">
<div class="canvas-container">
<canvas id="tetris" width="240" height="480"></canvas>
<canvas id="tetris" width="220" height="440"></canvas>
<div id="gameOverlay" class="overlay-msg" style="display:none">
<h2 id="overlayTitle">GAME OVER</h2>
<div id="overlayScore" style="color:var(--blue);font-size:16px;font-weight:700">Score: 0</div>
@@ -278,9 +284,9 @@
</div>
<div class="sidebar">
<div class="panel-box" style="padding:6px">
<h3 id="labelNext" style="font-size:10px;margin-bottom:4px">Prochaine</h3>
<canvas id="next" class="preview-canvas" width="80" height="74"></canvas>
<div class="panel-box" style="padding:5px">
<h3 id="labelNext" style="font-size:9.5px;margin-bottom:3px">Prochaine</h3>
<canvas id="next" class="preview-canvas" width="74" height="66"></canvas>
</div>
<div class="panel-box stats-box">
<div class="stat-col">
@@ -606,7 +612,7 @@
const COLS = 10;
const ROWS = 20;
const BLOCK = 24;
const BLOCK = 22;
const COLORS = [
null,
+46 -34
View File
@@ -136,6 +136,17 @@
--node-color: #00ff41;
}
html, body {
overflow: hidden !important;
height: 100%;
width: 100%;
margin: 0;
padding: 0;
box-sizing: border-box;
}
::-webkit-scrollbar { display: none !important; width: 0 !important; height: 0 !important; }
* { scrollbar-width: none !important; }
body {
background: var(--bg);
color: var(--text);
@@ -144,9 +155,8 @@
flex-direction: column;
align-items: center;
justify-content: center;
min-height: 100vh;
overflow-x: hidden;
padding: 4px;
height: 100%;
padding: 6px;
transition: background 0.3s ease, color 0.3s ease;
}
.game-container {
@@ -155,12 +165,13 @@
border-radius: 14px;
padding: 10px 14px;
box-shadow: 0 10px 30px rgba(0,0,0,0.5), 0 0 20px rgba(92,167,255,0.12);
max-width: 480px;
max-width: 430px;
width: 100%;
display: flex;
flex-direction: column;
align-items: center;
position: relative;
flex-shrink: 0;
transition: all 0.3s ease;
}
.top-bar {
@@ -168,7 +179,7 @@
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 12px;
margin-bottom: 6px;
font-size: 13px;
}
.title-badge {
@@ -177,15 +188,15 @@
gap: 6px;
font-weight: 700;
color: var(--blue);
font-size: 16px;
font-size: 15px;
}
.level-selector select {
background: var(--panel-box);
color: var(--text);
border: 1px solid var(--border);
padding: 5px 10px;
padding: 4px 8px;
border-radius: 6px;
font-size: 12px;
font-size: 11.5px;
cursor: pointer;
}
.stats-bar {
@@ -194,22 +205,22 @@
justify-content: space-between;
align-items: center;
background: var(--panel-box);
padding: 8px 14px;
padding: 4px 10px;
border-radius: 8px;
border: 1px solid var(--border);
margin-bottom: 14px;
font-size: 13px;
margin-bottom: 6px;
font-size: 12px;
}
.stats-bar strong {
color: var(--blue);
}
.progress-bar-wrap {
width: 100%;
height: 6px;
height: 5px;
background: var(--board-bg);
border-radius: 3px;
overflow: hidden;
margin-bottom: 14px;
margin-bottom: 8px;
border: 1px solid var(--border);
}
.progress-bar-fill {
@@ -221,28 +232,28 @@
.board-container {
position: relative;
background: var(--board-bg);
border: 3px solid var(--border);
border-radius: 12px;
padding: 8px;
border: 2px solid var(--border);
border-radius: 10px;
padding: 4px;
box-shadow: inset 0 0 20px rgba(0,0,0,0.5);
touch-action: none;
transition: all 0.3s ease;
}
.grid {
display: grid;
gap: 6px;
gap: 5px;
position: relative;
}
.cell {
width: 58px;
height: 58px;
width: 44px;
height: 44px;
background: var(--cell-bg);
border: 1px solid var(--cell-border);
border-radius: 8px;
border-radius: 7px;
display: flex;
align-items: center;
justify-content: center;
font-size: 20px;
font-size: 17px;
font-weight: 800;
cursor: pointer;
position: relative;
@@ -264,15 +275,15 @@
.cell.number-node {
color: var(--node-color);
font-family: monospace;
font-size: 22px;
font-size: 18px;
text-shadow: 0 0 8px rgba(255, 255, 255, 0.3);
}
.cell.number-node::after {
content: '';
position: absolute;
inset: 4px;
inset: 3px;
border: 2px dashed rgba(255, 255, 255, 0.35);
border-radius: 6px;
border-radius: 5px;
pointer-events: none;
}
.cell.number-node.visited-num {
@@ -285,10 +296,10 @@
/* SVG overlay for path */
.path-svg {
position: absolute;
top: 8px;
left: 8px;
width: calc(100% - 16px);
height: calc(100% - 16px);
top: 4px;
left: 4px;
width: calc(100% - 8px);
height: calc(100% - 8px);
pointer-events: none;
z-index: 10;
overflow: visible !important;
@@ -296,7 +307,7 @@
.path-line {
fill: none;
stroke: var(--path-stroke, #5ca7ff);
stroke-width: 7;
stroke-width: 6;
stroke-linecap: round;
stroke-linejoin: round;
filter: drop-shadow(0 0 6px var(--path-stroke, #5ca7ff));
@@ -305,8 +316,8 @@
.bottom-actions {
display: grid;
grid-template-columns: 1fr 1fr 1.25fr;
gap: 10px;
margin-top: 16px;
gap: 6px;
margin-top: 8px;
width: 100%;
}
.btn {
@@ -354,11 +365,12 @@
.btn.primary:hover { opacity: 0.9; }
.instructions {
margin-top: 12px;
font-size: 11.5px;
margin-top: 6px;
font-size: 11px;
color: var(--muted);
text-align: center;
line-height: 1.45;
line-height: 1.35;
padding: 2px 4px;
}
/* Win overlay */