ztksdrz
This commit is contained in:
parent
7098caee6b
commit
604c470745
@ -418,7 +418,12 @@ body {
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
transition: all 0.2s ease;
|
/* 'all' würde backdrop-filter/background mitanimieren und Flicker erzeugen */
|
||||||
|
transition:
|
||||||
|
border-color 0.2s ease,
|
||||||
|
transform 0.2s ease,
|
||||||
|
box-shadow 0.2s ease,
|
||||||
|
opacity 0.2s ease;
|
||||||
position: relative;
|
position: relative;
|
||||||
overflow: visible;
|
overflow: visible;
|
||||||
box-shadow: 0 calc(var(--s) * 4) calc(var(--s) * 12) rgba(0, 0, 0, 0.4);
|
box-shadow: 0 calc(var(--s) * 4) calc(var(--s) * 12) rgba(0, 0, 0, 0.4);
|
||||||
|
|||||||
@ -428,6 +428,12 @@
|
|||||||
if (!slot) return;
|
if (!slot) return;
|
||||||
|
|
||||||
if (!state) {
|
if (!state) {
|
||||||
|
// Inline-Styles aus dem Karten-Render wieder entfernen
|
||||||
|
slot.style.background = "";
|
||||||
|
slot.style.backdropFilter = "";
|
||||||
|
slot.style.webkitBackdropFilter = "";
|
||||||
|
slot.style.overflow = "";
|
||||||
|
slot.style.padding = "";
|
||||||
slot.innerHTML = '<span class="hs-icon">🃏</span>';
|
slot.innerHTML = '<span class="hs-icon">🃏</span>';
|
||||||
slot.classList.remove("hand-slot-ready", "hand-slot--filled");
|
slot.classList.remove("hand-slot-ready", "hand-slot--filled");
|
||||||
slot.draggable = false;
|
slot.draggable = false;
|
||||||
@ -461,12 +467,21 @@
|
|||||||
? `<div class="hand-slot-ready-badge">SPIELEN</div>`
|
? `<div class="hand-slot-ready-badge">SPIELEN</div>`
|
||||||
: "";
|
: "";
|
||||||
|
|
||||||
|
// Slot direkt stylen – umgeht Compositing-Probleme von backdrop-filter
|
||||||
|
slot.style.background = "transparent";
|
||||||
|
slot.style.backdropFilter = "none";
|
||||||
|
slot.style.webkitBackdropFilter = "none";
|
||||||
|
slot.style.overflow = "hidden";
|
||||||
|
slot.style.padding = "0";
|
||||||
|
|
||||||
slot.innerHTML = card.image
|
slot.innerHTML = card.image
|
||||||
? `<img src="/images/cards/${card.image}"
|
? `<div style="position:absolute;inset:0;z-index:0;">
|
||||||
onerror="this.src='/images/items/rueckseite.png'"
|
<img src="/images/cards/${card.image}"
|
||||||
title="${card.name}"
|
onerror="this.src='/images/items/rueckseite.png'"
|
||||||
draggable="false"
|
title="${card.name}"
|
||||||
style="position:absolute;inset:0;width:100%;height:100%;object-fit:cover;display:block;">
|
draggable="false"
|
||||||
|
style="width:100%;height:100%;object-fit:cover;display:block;">
|
||||||
|
</div>
|
||||||
${statsHtml}${readyBadge}`
|
${statsHtml}${readyBadge}`
|
||||||
: `<div style="display:flex;flex-direction:column;align-items:center;
|
: `<div style="display:flex;flex-direction:column;align-items:center;
|
||||||
justify-content:center;height:100%;gap:4px;font-family:Cinzel,serif;">
|
justify-content:center;height:100%;gap:4px;font-family:Cinzel,serif;">
|
||||||
@ -475,7 +490,7 @@
|
|||||||
</div>${statsHtml}${readyBadge}`;
|
</div>${statsHtml}${readyBadge}`;
|
||||||
|
|
||||||
slot.classList.toggle("hand-slot-ready", isReady);
|
slot.classList.toggle("hand-slot-ready", isReady);
|
||||||
slot.classList.add("hand-slot--filled"); // Hintergrund + ::before entfernen
|
slot.classList.add("hand-slot--filled");
|
||||||
|
|
||||||
// Drag & Drop: nur wenn Karte bereit UND mein Zug
|
// Drag & Drop: nur wenn Karte bereit UND mein Zug
|
||||||
if (isReady && isMyTurn) {
|
if (isReady && isMyTurn) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user