web.dev
web.dev copied to clipboard
Blog: Portals - fixing existing animation code snippet
Author: @uskay Reviewer: @kaycebasques , technical review @argyleink
Fixing the code snippet of the existing https://web.dev/hands-on-portals/ article.
Before: it is animating non-GPU accelerated attributes such as bottom, left
.portal-reveal {
transform: scale(1.0);
bottom: 0px;
left: 0px;
}
After: only animate opacity and transform
.portal-reveal {
transform: scale(1.0) translateX(-20px) translateY(20px);
}
...
@keyframes fade-in {
0% { opacity: 0; }
100% { opacity: 1; }
}
Target publish date: CDS wave 3 (right before CDS)
- [x] Check this box if this is a hard deadline.
- [ ] Check this box if you'd like your reviewer to fix grammar and punctuation issues for you. Process
cc/ @kaycebasques @robdodson @argyleink
@kaycebasques, remember to send the feedback survey!