Skip to content

VideoPress: Use 16:9 previews in the dashboard library - #52318

Merged
vianasw merged 2 commits into
trunkfrom
codex/vidp-255-widescreen-thumbnails
Sep 15, 2026
Merged

vianasw merged 2 commits into
trunkfrom
codex/vidp-255-widescreen-thumbnails

Conversation

@vianasw

@vianasw vianasw commented Sep 15, 2026 •

Copy link
Copy Markdown
Contributor

Fixes VIDP-255.

Proposed changes

The modernized VideoPress library crops video previews into squares. Use DataViews' layout.aspectRatio: '16/9' in the grid and table so landscape previews better match the embedded video.

  • Set the initial view and both layout defaults to 16:9, including when switching between grid and table.
  • Merge saved view preferences with the selected layout's defaults so existing users get the new ratio while keeping their thumbnail size and density.
  • Remove the dashboard's fixed square table-thumbnail sizing so DataViews can size the preview.
  • Keep the failure summary and Retry button visible at the smallest thumbnail sizes; retain the detailed cause for screen readers.
  • Add changelog entries for the VideoPress package and the VideoPress and Jetpack plugins.

The existing @wordpress/dataviews 18.1.0 dependency includes this capability; no dependency update is needed.

Before and after

Grid view

Before: square thumbnails After: 16:9 thumbnails
Grid view before: square thumbnails Grid view after: 16:9 thumbnails

Table view

Before: square thumbnails After: 16:9 thumbnails
Table view before: square thumbnails Table view after: 16:9 thumbnails

Related product discussion/links

Does this pull request change what data or activity we track or use?

No.

Testing instructions

  1. Build plugins/videopress with dependencies (jp build plugins/videopress --deps) and activate it on a connected development site with videos. Open VideoPress → Library in the modernized dashboard.
  2. In Grid view, confirm previews are 16:9. Check landscape, portrait, square, and missing-poster videos; portrait and square posters should fill the preview without stretching.
  3. Check duration badges, hover/focus actions, and upload/processing/failure overlays at desktop and narrow widths. Set thumbnail size to its minimum and confirm a failed upload still shows its summary and Retry button.
  4. Change thumbnail size and density, then reload. Confirm both preferences survive and previews remain 16:9. Repeat with preferences saved on trunk before checking out this branch.
  5. Switch to Table view. Confirm previews are wider while row height stays the same, and status remains in the title cell. Reload, then switch back to Grid and confirm 16:9 is retained.

Validation

  • JavaScript: 131 suites, 1,287 tests passed, including saved-view regression coverage.
  • PHP: 347 tests, 947 assertions passed.
  • Phan: passed using the monorepo Docker image's PHP 8.4 and native AST parser.
  • TypeScript, ESLint, Stylelint, and git diff --check passed.
  • Browser component checks passed using the real DataViews and VideoPress library fields/styles with synthetic data: desktop and narrow grid/table, minimum 120px previews, landscape/portrait/square posters, upload/processing/failure overlays, and grid → table → grid switching. Grid previews retain 16:9; table previews measure approximately 56.9 × 32px.
  • At the minimum thumbnail size, the failure summary and Retry button fit, Retry and local-upload actions work, and the accessibility tree retains the full failure cause. The 21 thumbnail component tests, TypeScript, and lint checks passed again after the compact-overlay adjustment.

The browser check used an isolated component fixture; a connected WordPress dashboard session was not exercised locally.

@vianasw
vianasw requested a review from a team as a code owner September 15, 2026 08:07
@vianasw vianasw added Enhancement Changes to an existing feature — removing, adding, or changing parts of it [Feature] VideoPress A feature to help you upload and insert videos on your site. [Status] Needs Review This PR is ready for review. labels Sep 15, 2026
@vianasw vianasw self-assigned this Sep 15, 2026
@github-actions github-actions Bot added [Package] VideoPress [Plugin] Jetpack Issues about the Jetpack plugin. https://wordpress.org/plugins/jetpack/ [Plugin] VideoPress A standalone plugin to add high-quality VideoPress videos to your site. [Tests] Includes Tests labels Sep 15, 2026
@github-actions

github-actions Bot commented Sep 15, 2026 •

Copy link
Copy Markdown
Contributor

Thank you for your PR!

When contributing to Jetpack, we have a few suggestions that can help us test and review your patch:

  • ✅ Include a description of your PR changes.
  • ✅ Add a "[Status]" label (In Progress, Needs Review, ...).
  • ✅ Add testing instructions.
  • ✅ Specify whether this PR includes any changes to data or privacy.
  • ✅ Add changelog entries to affected projects

This comment will be updated as you work on your PR and make changes. If you think that some of those checks are not needed for your PR, please explain why you think so. Thanks for cooperation 🤖


Follow this PR Review Process:

  1. Ensure all required checks appearing at the bottom of this PR are passing.
  2. Make sure to test your changes on all platforms that it applies to. You're responsible for the quality of the code you ship.
  3. You can use GitHub's Reviewers functionality to request a review.
  4. When it's reviewed and merged, you will be pinged in Slack to deploy the changes to WordPress.com simple once the build is done.

If you have questions about anything, reach out in #jetpack-developers for guidance!


Jetpack plugin:

The Jetpack plugin has different release cadences depending on the platform:

  • WordPress.com Simple releases happen as soon as you deploy your changes after merging this PR (PCYsg-Jjm-p2).
  • WoA releases happen weekly.
  • Releases to self-hosted sites happen monthly:
    • Scheduled release: October 6, 2026

If you have any questions about the release process, please ask in the #jetpack-releases channel on Slack.


Videopress plugin:

No scheduled milestone found for this plugin.

If you have any questions about the release process, please ask in the #jetpack-releases channel on Slack.

@github-actions

github-actions Bot commented Sep 15, 2026 •

Copy link
Copy Markdown
Contributor

Are you an Automattician? Please test your changes on all WordPress.com environments to help mitigate accidental explosions.

  • To test on WoA, go to the Plugins menu on a WoA dev site. Click on the "Upload" button and follow the upgrade flow to be able to upload, install, and activate the Jetpack Beta plugin. Once the plugin is active, go to Jetpack > Jetpack Beta, select your plugin (Jetpack), and enable the codex/vidp-255-widescreen-thumbnails branch.
  • To test on Simple, run the following command on your sandbox:
bin/jetpack-downloader test jetpack codex/vidp-255-widescreen-thumbnails

Interested in more tips and information?

  • In your local development environment, use the jetpack rsync command to sync your changes to a WoA dev blog.
  • Read more about our development workflow here: PCYsg-eg0-p2
  • Figure out when your changes will be shipped to customers here: PCYsg-eg5-p2

@jp-launch-control

Copy link
Copy Markdown

Code Coverage Summary

Coverage changed in 1 file.

File Coverage Δ% Δ Uncovered
projects/packages/videopress/src/dashboard/hooks/use-persisted-view.ts 73/74 (98.65%) 1.55% -1 💚

Full summary · PHP report · JS report

@vianasw
vianasw merged commit 027ab5e into trunk Sep 15, 2026
84 checks passed
@vianasw
vianasw deleted the codex/vidp-255-widescreen-thumbnails branch September 15, 2026 15:00
@github-actions github-actions Bot added [Status] UI Changes Add this to PRs that change the UI so documentation can be updated. and removed [Status] Needs Review This PR is ready for review. labels Sep 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Enhancement Changes to an existing feature — removing, adding, or changing parts of it [Feature] VideoPress A feature to help you upload and insert videos on your site. [Package] VideoPress [Plugin] Jetpack Issues about the Jetpack plugin. https://wordpress.org/plugins/jetpack/ [Plugin] VideoPress A standalone plugin to add high-quality VideoPress videos to your site. [Status] UI Changes Add this to PRs that change the UI so documentation can be updated. [Tests] Includes Tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant