fix: use full-size image for non-web-compatible panoramas (#20359)

* fix(web): use full-size image for non-web-compatible panoramas

* always generate full-size image for panoramas

* add unit test

* fix formatting

---------

Co-authored-by: gergo= <gergo@pitty.hu>
This commit is contained in:
grgergo 2025-10-06 16:38:41 +00:00 committed by GitHub
parent 42f46b11f4
commit 6973683ea7
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 77 additions and 3 deletions

View file

@ -866,4 +866,43 @@ export const assetStub = {
stackId: null,
visibility: AssetVisibility.Timeline,
}),
panoramaTif: Object.freeze({
id: 'asset-id',
status: AssetStatus.Active,
deviceAssetId: 'device-asset-id',
fileModifiedAt: new Date('2023-02-23T05:06:29.716Z'),
fileCreatedAt: new Date('2023-02-23T05:06:29.716Z'),
owner: userStub.user1,
ownerId: 'user-id',
deviceId: 'device-id',
originalPath: '/original/path.tif',
checksum: Buffer.from('file hash', 'utf8'),
type: AssetType.Image,
files,
thumbhash: Buffer.from('blablabla', 'base64'),
encodedVideoPath: null,
createdAt: new Date('2023-02-23T05:06:29.716Z'),
updatedAt: new Date('2023-02-23T05:06:29.716Z'),
localDateTime: new Date('2023-02-23T05:06:29.716Z'),
isFavorite: true,
duration: null,
isExternal: false,
livePhotoVideo: null,
livePhotoVideoId: null,
sharedLinks: [],
originalFileName: 'asset-id.tif',
faces: [],
deletedAt: null,
sidecarPath: null,
exifInfo: {
fileSizeInByte: 5000,
projectionType: 'EQUIRECTANGULAR',
} as Exif,
duplicateId: null,
isOffline: false,
updateId: '42',
libraryId: null,
stackId: null,
visibility: AssetVisibility.Timeline,
}),
};