Add DEBUG-gated panel to buy any card in the shop

When the server's DEBUG env var is on, expose a card catalog endpoint
and a collapsible client panel that drops any pet or food straight into
your deck (free, off-turn). Gated server-side so it is inert in normal
play.
This commit is contained in:
Greyson Parrelli
2026-07-23 01:07:14 -04:00
parent 71fa20493a
commit b2aa7c5ca3
13 changed files with 282 additions and 7 deletions
+63
View File
@@ -1276,3 +1276,66 @@ h3 {
height: 110px;
}
}
/* --- debug panel (server DEBUG mode) --- */
.debug-panel {
position: fixed;
top: 64px;
right: 0;
z-index: 120;
display: flex;
align-items: flex-start;
}
.debug-toggle {
background: #7a1f1f;
color: var(--cream);
border: 2px solid var(--cocoa);
border-right: none;
border-radius: 8px 0 0 8px;
font-weight: 800;
font-size: 0.8rem;
padding: 8px 10px;
cursor: pointer;
white-space: nowrap;
writing-mode: vertical-rl;
transform: rotate(180deg);
}
.debug-panel.is-open .debug-toggle {
writing-mode: horizontal-tb;
transform: none;
border-radius: 8px 0 0 0;
}
.debug-body {
width: min(340px, 80vw);
max-height: calc(100vh - 80px);
overflow-y: auto;
background: rgba(18, 53, 31, 0.97);
border: 2px solid var(--cocoa);
border-radius: 8px 0 0 8px;
padding: 12px;
box-shadow: -6px 6px 18px rgba(0, 0, 0, 0.45);
}
.debug-head {
color: var(--gold);
font-weight: 800;
margin-bottom: 8px;
}
.debug-tier-label {
color: var(--cream);
font-size: 0.75rem;
font-weight: 700;
opacity: 0.8;
margin: 8px 0 4px;
}
.debug-grid {
display: flex;
flex-wrap: wrap;
gap: 6px;
}