Open Bug 2064634 Opened 3 months ago Updated 9 days ago

www.amidead.gg - Answer card are mirrored after being flipped

Categories

(Web Compatibility :: Site Reports, defect, P3)

Desktop
Windows

Tracking

(Webcompat Priority:P3, Webcompat Score:4, firefox154 affected, firefox155 affected, firefox156 affected)

Webcompat Priority P3
Webcompat Score 4
Tracking Status
firefox154 --- affected
firefox155 --- affected
firefox156 --- affected

People

(Reporter: rbucata, Unassigned, NeedInfo)

References

(Depends on 1 open bug, )

Details

(Keywords: webcompat:needs-sitepatch, webcompat:platform-bug, webcompat:site-report, Whiteboard: [webcompat-source:web-bugs][autowebcompat:processed][autowebcompat:repro-success])

User Story

autowebcompat-repro-status:success
autowebcompat-repro-chrome-mask-fixed:false
autowebcompat-repro-channels:nightly,stable,esr
platform:windows,mac,linux,android
impact:content-missing
configuration:general
affects:all
branch:release
diagnosis-team:layout
user-impact-score:60
autowebcompat-diagnosis-status:success
autowebcompat-intervention-status:success

Attachments

(4 files, 1 external file)

Environment:
Operating system: Linux and Windows
Firefox version: Firefox 153.0

Steps to reproduce:

  1. Navigate to: https://www.amidead.gg/play
  2. Start today's puzzle.
  3. Answer a question.
  4. Observe the answer card after submitting the answer.

Expected Behavior:
After answering, the card flips around normally and reveals the option to continue the game.

Actual Behavior:
The card appears mirrored after flipping. The buttons remain interactive and can still be used.

Notes:

  • Reproduces regardless of the status of ETP
  • Reproduces in firefox-nightly, and firefox-release
  • Does not reproduce in chrome

Created from https://github.com/webcompat/web-bugs/issues/232146

Attached video chr vs ff.mp4 —
Whiteboard: [webcompat-source:web-bugs] → [webcompat-source:web-bugs][autowebcompat:processed]

Since nightly and release are affected, beta will likely be affected too.
For more information, please visit BugBot documentation.

User Story: (updated)
Whiteboard: [webcompat-source:web-bugs][autowebcompat:processed] → [webcompat-source:web-bugs][autowebcompat:processed][autowebcompat:repro-success]

Confirmed Firefox-only webcompat issue. On https://www.amidead.gg/play, after answering a question the answer card performs a 3D flip. In Firefox the revealed back face of the card is painted mirrored — all of its text renders right-to-left ("Michael Richards", "Next →", the "ALIVE" stamp, "56% of players got this right" are all reversed) — and the mirrored face is additionally offset left and shrunk relative to the box it should occupy, leaving the front face's yellow category bar visibly bleeding through on the right. In Chrome, at the same viewport and on the same puzzle, the flipped card renders correctly: text is readable and the back face exactly fills the card.

The card markup is a .card-flip container with transform-style: preserve-3d that gets rotateY(180deg) when flipped, containing a .card-face-back child carrying its own rotateY(180deg) so the two rotations cancel out. Computed styles are byte-for-byte identical in both browsers (matrix3d(-1,0,0,0, 0,1,0,0, 0,0,-1,0, 0,0,0,1) on both, preserve-3d on the container, backface-visibility: hidden on the faces), so this is purely a painting difference, not a CSS/layout divergence.

Notably the breakage is paint-only: getBoundingClientRect() returns correct, unmirrored geometry in Firefox, which matches the reporter's note that the buttons remain interactive and usable despite appearing mirrored. Because of this, the difference is only observable in rendered pixels, so the confirmation script screenshots the page and decodes the PNG to compare painted pixels against CSS geometry. Two independent measurements, both with wide margins:

  1. Position — the solid blue "Next" button's painted horizontal extent vs its getBoundingClientRect(). Chrome: painted 511–840 vs geometry 508.5–842.5 (within ~2.5px). Firefox: painted 479–761 vs geometry 510–844, i.e. 31px/83px off and 51px too narrow.
  2. Mirroring — "Today I learned" is a short left-aligned label inside a 300px box, so its ink must sit well left of that box's centre. Chrome: ink centroid 93px left of centre (582.6 vs 675.5). Firefox: 14px right of centre (689.4 vs 677) — the label has been flipped to the opposite side of its box.

The Puppeteer script drives the real reported site in both browsers and is fully deterministic: Firefox exits 1 (0/3 runs working) and Chrome exits 0 (3/3 runs working), which is exactly the required difference. This clearly qualifies as a webcompat issue — the primary game content (the answer, the fact blurb, the score, the Next button) is rendered as unreadable mirrored text for Firefox users while displaying normally in Chrome. No Firefox configuration was changed, and no reader mode, form autofill, or strict ETP was involved.

User Story: (updated)

There is a similar bug with a workaround in https://bugzilla.mozilla.org/show_bug.cgi?id=2024317#c2

Severity: -- → S2
User Story: (updated)
Webcompat Priority: --- → P3
Webcompat Score: --- → 4
Priority: -- → P3
See Also: → 2024317
Whiteboard: [webcompat-source:web-bugs][autowebcompat:processed][autowebcompat:repro-success] → [webcompat-source:web-bugs][autowebcompat:processed][autowebcompat:repro-success][autowebcompat:diagnose]
Whiteboard: [webcompat-source:web-bugs][autowebcompat:processed][autowebcompat:repro-success][autowebcompat:diagnose] → [webcompat-source:web-bugs][autowebcompat:processed][autowebcompat:repro-success]

Root cause analysis generated by autowebcompat bot:

Firefox flattens a preserve-3d 3D rendering context when a descendant uses mix-blend-mode, so the flip card's per-face rotateY no longer cancels the parent rotateY. The result is that the back face paints mirrored and shifted, and the away-facing front face is not culled by backface-visibility.

Evidence:

Disabling mix-blend-mode on the two portrait images fixed the flip card in Firefox; Chrome is fine.

User Story: (updated)

Do we have an existing bug for this?

User Story: (updated)
Flags: needinfo?(tnikkel)

Bug 1556956 probably.

Depends on: 1556956
Whiteboard: [webcompat-source:web-bugs][autowebcompat:processed][autowebcompat:repro-success] → [webcompat-source:web-bugs][autowebcompat:processed][autowebcompat:repro-success][autowebcompat:intervention-in-progress]

amidead.gg's answer card flips with a transform-style: preserve-3d container. The portrait images inside it use mix-blend-mode, which makes Firefox flatten the 3D context (bug 1556956), so the back face paints mirrored and in the wrong place. This adds a CSS intervention that sets mix-blend-mode: normal on descendants of .card-flip, and a test for it.

User Story: (updated)
Whiteboard: [webcompat-source:web-bugs][autowebcompat:processed][autowebcompat:repro-success][autowebcompat:intervention-in-progress] → [webcompat-source:web-bugs][autowebcompat:processed][autowebcompat:repro-success]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: