Skip to content

Conversation

felixarntz
Copy link
Member

Summary

#2051 implemented control over the view transition duration via theme support and a corresponding setting, with a default of 1000 (1 second).

While doing further smoke testing (for #2080), I noticed that this is far slower than the browser default when not specifying any duration. Therefore this PR aligns more closely with the browser default, which gives a better experience out of the box than a slower-moving animation, which can look a bit too janky sometimes.

It seems there is no clear single value that the browser uses, but it's a range between 0.15-0.4s. When I compared assigning 0.4s with no value, I could barely tell any difference, so I think this works well for now, certainly better than a default of 1s.

@felixarntz felixarntz added this to the view-transitions 1.1.0 milestone Jul 14, 2025
@felixarntz felixarntz added [Type] Bug An existing feature is broken [Plugin] View Transitions Issues for the View Transitions plugin labels Jul 14, 2025
@felixarntz felixarntz requested a review from swissspidy July 14, 2025 19:23
Copy link

github-actions bot commented Jul 14, 2025

The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the props-bot label.

If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.

Co-authored-by: felixarntz <flixos90@git.wordpress.org>
Co-authored-by: swissspidy <swissspidy@git.wordpress.org>
Co-authored-by: mukeshpanchal27 <mukesh27@git.wordpress.org>

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.

Copy link

codecov bot commented Jul 14, 2025

Codecov Report

Attention: Patch coverage is 33.33333% with 2 lines in your changes missing coverage. Please review.

Project coverage is 67.14%. Comparing base (f9a14d9) to head (2aaa08c).
Report is 2 commits behind head on trunk.

Files with missing lines Patch % Lines
plugins/view-transitions/includes/settings.php 0.00% 2 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##            trunk    #2081   +/-   ##
=======================================
  Coverage   67.14%   67.14%           
=======================================
  Files          93       93           
  Lines        7740     7740           
=======================================
  Hits         5197     5197           
  Misses       2543     2543           
Flag Coverage Δ
multisite 67.14% <33.33%> (ø)
single 36.53% <0.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@felixarntz
Copy link
Member Author

For some reasons the PHP 7.2 unit test workflow is consistently failing, which seems unrelated to this PR. It's also happening for #2080 🤔

@mukeshpanchal27
Copy link
Member

mukeshpanchal27 commented Jul 15, 2025

The issue was fixed in GB repo WordPress/gutenberg#70718 for ENV package.

@mukeshpanchal27 mukeshpanchal27 merged commit 992239b into trunk Jul 15, 2025
44 of 48 checks passed
@mukeshpanchal27 mukeshpanchal27 deleted the update/default-view-transition-duration branch July 15, 2025 04:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Plugin] View Transitions Issues for the View Transitions plugin [Type] Bug An existing feature is broken
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants