Repository navigation
feat(assets): open a file full size when its card is clicked - #2140
Merged
Merged
Conversation
Clicking an asset card did nothing: only right-click and the hover buttons had actions. A click now opens the file in a viewer over the page: the full image (Fit, 50%, 100%, 200%), the video with its controls, or the audio player, with its name, type, creation time, format, dimensions, size and tags beside it, and Download. The arrow keys and a filmstrip step through the files in the page's order and filter. Escape, the close button or a click outside closes it and puts focus back on the card. While the viewer steps, the gallery scrolls the viewed card into place behind it, so the card is still mounted to take focus back. This is the Assets half of Pablo's #2008, ported onto main without the Apps bridge and workflow parts, which wait on the Apps stack. Filmstrip videos load only once they scroll into view, so a long gallery does not start a metadata request per video.
|
Caution Review failedThe pull request is closed. Walkthrough
Merge Risk:
|
coderabbitai
Bot
requested review from
PabloWiedemann,
benjcooley and
deepme987
November 16, 2026 08:54
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
What changes
Clicking an asset card on the Assets page did nothing before. Only right-click and the hover buttons (Download, More) did anything. Now a click opens the file in a viewer over the page:
This is the Assets half of Pablo's #2008, ported onto
main. That PR sits on top of the unmerged Apps stack (#1994 → #1997), so its Apps bridge (showOutput,onOutputAction, the app still behind the dialog) and its workflow section stay there.OutputDetailDialogkeeps the same name and item shape, so #2008 can addworkflowand the Apps wiring back when it rebases.How
OutputDetailDialog.vue: Pablo's dialog onDesktopDialogSurface, using design-systemButton,Tag,MenuandAudioPreview.OutputDetailThumb.vue: a filmstrip entry. A video thumb mounts its<video>only once it scrolls into view, so a long gallery doesn't start one metadata request per video. Image thumbs use the smallthumbnailUrlwhen there is one, and the viewer shows the fullpreviewUrl.AssetsView.vue: the card's media and caption are now one<button>. The card shows a focus ring when that button has keyboard focus. The viewer tracks the open file by its card key, so a refresh that reorders the list keeps it on the same file, and it closes if that file disappears.useVirtualMasonry: gainsscrollToIndex. The gallery is virtualized, so as the viewer steps, the gallery scrolls the viewed card into place behind it. That keeps the card mounted to take focus back on close.text-[13px]/5, nottext-ui. The design system'stailwind-mergedoesn't knowtext-uiis a font size and treats it as a colour, which wiped the inverted Download button's label (white on white).assets.inspect,assets.detail.*andassets.kindSingular.*strings inenandzh, taken from feat(apps): open outputs in one Desktop dialog from Apps and Assets #2008.Tests
AssetsView.test.tshas four new journeys:All 33 AssetsView tests pass locally, and the pre-commit typecheck, lint and format checks pass.
Screenshots
Rendered from the real
AssetsViewin headless Chromium with a mockedwindow.api. The pictures are stills from the install showcase videos.Clicking a card
A video, picked from the filmstrip, and the card holding focus after Escape
Not checked: the running Electron app, Cloud assets (their
previewUrlis a signed Cloud link, same as the card already loads), audio files, Windows and Linux.