[Gecko Bug 306344] Use transform animations to implement marquee. #45618
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This matches what chromium does, and is both simpler and prettier.
The overflow: hidden enforcement also matches chromium / WebKit via:
https://source.chromium.org/chromium/chromium/src/+/main:third_party/blink/renderer/core/css/resolver/style_adjuster.cc;l=482;drc=88c8510c16d44e0dc8c07426db31aa5bb3c90a2b
https://searchfox.org/wubkat/rev/473ca5f8512b88edd7e82c8783e7e09158f17ba1/Source/WebCore/style/StyleAdjuster.cpp#581-596
See also whatwg/html#10243 and the resets.html
change.
Adding white-space: nowrap isn't strictly necessary, but also matches
other implementations:
https://source.chromium.org/chromium/chromium/src/+/main:third_party/blink/renderer/core/html/html_marquee_element.cc;l=66;drc=4aba604f0aae6fb93eab830b68765604e9a2cca0
(and same link as above on WebKit)
Differential Revision: https://phabricator.services.mozilla.com/D206357
bugzilla-url: https://bugzilla.mozilla.org/show_bug.cgi?id=306344
gecko-commit: 0506d9964b321a47ffbbdbde6b3321c741322816
gecko-reviewers: smaug, firefox-animation-reviewers, boris