diff --git a/e2e/nebula-cards.spec.js b/e2e/nebula-cards.spec.js index faca487..3a383d6 100644 --- a/e2e/nebula-cards.spec.js +++ b/e2e/nebula-cards.spec.js @@ -266,6 +266,8 @@ test("player opens and reveals a three-card pack", async ({ page }) => { await page.getByRole("button", { name: "Ouvrir ce paquet : La Nébuleuse Originelle", exact: true }).click(); // L'étape d'ouverture garde le hero, affiche les probabilités et ne propose le retour qu'une fois les cartes révélées. await expect(page.locator(".nebula-player-hero")).toBeVisible(); + // Les particules passent sous la barre du haut : son flou serait recalculé à chaque image de l'animation. + await expect(page.locator(".topbar")).toHaveCSS("backdrop-filter", "none"); const openingOdds = page.getByRole("list", { name: "Probabilités" }).getByRole("listitem"); await expect(openingOdds).toHaveCount(5); await expect(openingOdds.first()).toContainText(/Commun.*%/); @@ -452,6 +454,8 @@ test("player opens and reveals a three-card pack", async ({ page }) => { await expectStandardCardFrame(largeCard, "lg"); await expect(largeCard.locator(".nebula-card-copy p")).toBeVisible(); await expect(largeCard.locator(".nebula-card-quantity")).toHaveCount(0); + // Vérifié sur le build : le flou plein écran derrière une carte animée ruine sa fluidité. + await expect(page.locator(".nds-modal-backdrop")).toHaveCSS("backdrop-filter", "none"); const ownedCopiesLabel = detailDialog.getByText("Exemplaires possédés", { exact: true }); await expect(ownedCopiesLabel).toBeVisible(); await expect(ownedCopiesLabel).toHaveCSS("white-space", "nowrap"); diff --git a/website/src/styles/_nebula-cards.scss b/website/src/styles/_nebula-cards.scss index fed105c..5fb0db3 100644 --- a/website/src/styles/_nebula-cards.scss +++ b/website/src/styles/_nebula-cards.scss @@ -8,6 +8,8 @@ /* L'ouverture d'un paquet garde le hero mais occupe toute la largeur : le menu revient avec le bouton Retour. */ .nebula-dashboard-shell:has(.nebula-opening-stage) > .nebula-dashboard-aside { display: none; } .nebula-dashboard-shell:has(.nebula-opening-stage) { grid-template-columns: minmax(0, 1fr); } +// Un flou d'arrière-plan est recalculé à chaque image dès qu'un effet anime ce qu'il recouvre : un fond plus dense le remplace pendant l'ouverture. +.app-shell:has(.nebula-opening-stage) :is(.sidebar, .topbar) { background: rgba(9, 11, 23, 0.94); backdrop-filter: none; } .nds-page-hero.nebula-player-hero { min-height: 0; align-items: center; } .nebula-player-hero :is(h1, p) { margin-block: 0; } .nebula-player-hero h1 { margin-block: var(--space-1) var(--space-2); } @@ -100,7 +102,7 @@ .nebula-collection-back-rings::after { position: absolute; inset: 18%; content: ""; border: 1px solid color-mix(in srgb, var(--pack-primary) 38%, transparent); border-radius: 50%; } .nebula-collection-back svg { z-index: 1; width: 30%; overflow: visible; fill: color-mix(in srgb, var(--pack-primary) 72%, white); stroke: color-mix(in srgb, var(--pack-primary) 72%, white); stroke-width: 2; filter: drop-shadow(0 0 10px color-mix(in srgb, var(--pack-primary) 68%, transparent)); } .nebula-collection-back[data-back-symbol="rift"] svg { fill: none; stroke-linecap: round; } -.nebula-collection-back-copy { position: absolute; right: 8%; bottom: 23%; left: 8%; z-index: 1; display: grid; place-items: center; min-height: 12%; padding: 4% 7%; border-radius: var(--radius-pill); background: rgba(5, 7, 17, 0.62); box-shadow: 0 3px 12px rgba(5, 7, 17, 0.36); text-shadow: 0 1px 3px rgba(0, 0, 0, 0.92); backdrop-filter: blur(3px); } +.nebula-collection-back-copy { position: absolute; right: 8%; bottom: 23%; left: 8%; z-index: 1; display: grid; place-items: center; min-height: 12%; padding: 4% 7%; border-radius: var(--radius-pill); background: rgba(5, 7, 17, 0.74); box-shadow: 0 3px 12px rgba(5, 7, 17, 0.36); text-shadow: 0 1px 3px rgba(0, 0, 0, 0.92); } .nebula-collection-back-copy strong { color: rgba(255, 255, 255, 0.94); font-size: clamp(0.58rem, 5.2cqw, 0.9rem); line-height: 1.2; letter-spacing: 0.04em; text-align: center; } .nebula-opening-stage { display: grid; width: min(100%, 1000px); margin-inline: auto; gap: var(--space-4); } @@ -302,6 +304,8 @@ button.nebula-card { cursor: pointer; } .nebula-album-entry[data-missing] .nebula-card-face { filter: grayscale(0.78); opacity: 0.44; } .nebula-album-entry[data-undiscovered] .nebula-card-tilt-surface { filter: grayscale(0.6) brightness(0.72); opacity: 0.7; } .nebula-favorite-mark { position: absolute; top: 6px; right: max(6px, calc((100% - 240px) / 2 + 6px)); z-index: 4; color: var(--color-accent-gold); filter: drop-shadow(0 1px 2px #000); } +// Derrière une carte animée, le flou plein écran de la modale serait recalculé à chaque image : un voile plus dense le remplace. +.nds-modal-backdrop:has(+ :is(.nebula-card-detail, .nebula-trade-composer)) { background: rgba(2, 3, 9, 0.86); backdrop-filter: none; } .nebula-card-detail.nds-modal { box-sizing: border-box; width: min(1040px, calc(100vw - 32px)); overflow-x: hidden; } .nebula-card-detail-layout { display: grid; grid-template-columns: minmax(220px, 300px) minmax(0, 1fr); gap: var(--space-6); align-items: start; } .nebula-card-detail-layout h2 { margin-top: 0; }