Merge branch 'cast' of github.com:ente-io/photos-web into cast
This commit is contained in:
commit
98a59172db
3 changed files with 9 additions and 8 deletions
|
@ -212,7 +212,7 @@ const PhotoFrame = ({
|
|||
throw Error(CustomError.FILE_CONVERSION_FAILED);
|
||||
}
|
||||
|
||||
await updateFileSrcProps(file, srcURLs);
|
||||
await updateFileSrcProps(file, srcURLs, enableDownload);
|
||||
};
|
||||
|
||||
const handleClose = (needUpdate) => {
|
||||
|
|
|
@ -69,7 +69,11 @@ export function updateFileMsrcProps(file: EnteFile, url: string) {
|
|||
}
|
||||
}
|
||||
|
||||
export async function updateFileSrcProps(file: EnteFile, srcURLs: SourceURLs) {
|
||||
export async function updateFileSrcProps(
|
||||
file: EnteFile,
|
||||
srcURLs: SourceURLs,
|
||||
enableDownload: boolean
|
||||
) {
|
||||
const { url, isRenderable, isOriginal } = srcURLs;
|
||||
file.w = window.innerWidth;
|
||||
file.h = window.innerHeight;
|
||||
|
@ -87,7 +91,9 @@ export async function updateFileSrcProps(file: EnteFile, srcURLs: SourceURLs) {
|
|||
|
||||
if (file.metadata.fileType === FILE_TYPE.VIDEO) {
|
||||
file.html = `
|
||||
<video controls onContextMenu="return false;">
|
||||
<video controls ${
|
||||
!enableDownload && 'controlsList="nodownload"'
|
||||
} onContextMenu="return false;">
|
||||
<source src="${url}" />
|
||||
Your browser does not support the video tag.
|
||||
</video>
|
||||
|
|
|
@ -390,11 +390,6 @@
|
|||
dependencies:
|
||||
glob "7.1.7"
|
||||
|
||||
"@next/font@13.1.3":
|
||||
version "13.1.3"
|
||||
resolved "https://registry.yarnpkg.com/@next/font/-/font-13.1.3.tgz#b8da6898537f341d7e1b35ec8ed686244503c076"
|
||||
integrity sha512-Zh7lU8KlUoeidHPuXt9Xdvu+DFg74JXGaBczBgNwZAqvwT4HquQ1zJVfavXIQhDRPbQlKYI6Z25BFC2PhVHvtA==
|
||||
|
||||
"@next/font@^14.0.4":
|
||||
version "14.0.4"
|
||||
resolved "https://registry.yarnpkg.com/@next/font/-/font-14.0.4.tgz#2df271479fa967d49c8ca8c1ca9db1506f8fe585"
|
||||
|
|
Loading…
Add table
Reference in a new issue