mirror of
https://github.com/cloudreve/frontend.git
synced 2025-12-25 19:52:48 +00:00
fix(viewer): default viewer should be selected on double click if there's only 1 matched viewer
This commit is contained in:
parent
b483b3c5ff
commit
ac6f97d9ba
|
|
@ -78,6 +78,12 @@ export function openViewers(
|
|||
}
|
||||
|
||||
const viewerOptions = Viewers[ext];
|
||||
|
||||
if (!ignorePreference && viewerOptions.length == 1) {
|
||||
dispatch(openViewer(file, viewerOptions[0], entitySize, preferredVersion));
|
||||
return;
|
||||
}
|
||||
|
||||
// open viewer selection dialog
|
||||
dispatch(
|
||||
setViewerSelector({
|
||||
|
|
|
|||
Loading…
Reference in New Issue