Webkit-Induced Post-Animation Text Distortion: Unraveling the Translate3d Conundrum
The prevalence of Webkit-based browsers, including iPhone's Safari, has brought to light a perplexing phenomenon: text becoming blurry after animations powered by "-webkit-transform: translate3d." This issue has plagued countless developers, leaving them baffled.
Underlying the issue is the site's reliance on JavaScript-based slider animations. However, when utilizing translate3d for these animations, the text's clarity plummets, particularly on iPhone. Common "fixes" like removing relative positioning and adding "-webkit-font-smoothing: antialiased" have proven fruitless.
The only viable solution that eliminates this distortion is the abandonment of translate3d in favor of pure JavaScript animation. However, translate3d offers the allure of superior performance on WebKit devices. The lingering question remains: why does translate3d cast such a detrimental effect on text?
While a definitive answer remains elusive, a workaround has emerged that alleviates the issue:
top: 49.9%; left: 49.9%; -webkit-transform: translate(-50.1%, -50.1%); transform: translate(-50.1%, -50.1%);
This unorthodox approach appears to mitigate the blurring. While not a perfect solution, it provides some respite from the frustration of blurry post-animation text.
The above is the detailed content of Why Does `translate3d` Cause Blurry Text After Animations in Webkit Browsers?. For more information, please follow other related articles on the PHP Chinese website!