fix: album sorting options (#5127)
* fix: album sort options * fix: don't load assets * pr feedback * fix: albumStub * fix(web): album shared without assets * fix: tests --------- Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
This commit is contained in:
Vendored
+30
@@ -19,6 +19,9 @@ export const albumStub = {
|
||||
sharedLinks: [],
|
||||
sharedUsers: [],
|
||||
isActivityEnabled: true,
|
||||
startDate: null,
|
||||
endDate: null,
|
||||
assetCount: 0,
|
||||
}),
|
||||
sharedWithUser: Object.freeze<AlbumEntity>({
|
||||
id: 'album-2',
|
||||
@@ -35,6 +38,9 @@ export const albumStub = {
|
||||
sharedLinks: [],
|
||||
sharedUsers: [userStub.user1],
|
||||
isActivityEnabled: true,
|
||||
startDate: null,
|
||||
endDate: null,
|
||||
assetCount: 0,
|
||||
}),
|
||||
sharedWithMultiple: Object.freeze<AlbumEntity>({
|
||||
id: 'album-3',
|
||||
@@ -51,6 +57,9 @@ export const albumStub = {
|
||||
sharedLinks: [],
|
||||
sharedUsers: [userStub.user1, userStub.user2],
|
||||
isActivityEnabled: true,
|
||||
startDate: null,
|
||||
endDate: null,
|
||||
assetCount: 0,
|
||||
}),
|
||||
sharedWithAdmin: Object.freeze<AlbumEntity>({
|
||||
id: 'album-3',
|
||||
@@ -67,6 +76,9 @@ export const albumStub = {
|
||||
sharedLinks: [],
|
||||
sharedUsers: [userStub.admin],
|
||||
isActivityEnabled: true,
|
||||
startDate: null,
|
||||
endDate: null,
|
||||
assetCount: 0,
|
||||
}),
|
||||
oneAsset: Object.freeze<AlbumEntity>({
|
||||
id: 'album-4',
|
||||
@@ -83,6 +95,9 @@ export const albumStub = {
|
||||
sharedLinks: [],
|
||||
sharedUsers: [],
|
||||
isActivityEnabled: true,
|
||||
startDate: assetStub.image.fileCreatedAt,
|
||||
endDate: assetStub.image.fileCreatedAt,
|
||||
assetCount: 1,
|
||||
}),
|
||||
twoAssets: Object.freeze<AlbumEntity>({
|
||||
id: 'album-4a',
|
||||
@@ -99,6 +114,9 @@ export const albumStub = {
|
||||
sharedLinks: [],
|
||||
sharedUsers: [],
|
||||
isActivityEnabled: true,
|
||||
startDate: assetStub.withLocation.fileCreatedAt,
|
||||
endDate: assetStub.image.fileCreatedAt,
|
||||
assetCount: 2,
|
||||
}),
|
||||
emptyWithInvalidThumbnail: Object.freeze<AlbumEntity>({
|
||||
id: 'album-5',
|
||||
@@ -115,6 +133,9 @@ export const albumStub = {
|
||||
sharedLinks: [],
|
||||
sharedUsers: [],
|
||||
isActivityEnabled: true,
|
||||
startDate: null,
|
||||
endDate: null,
|
||||
assetCount: 0,
|
||||
}),
|
||||
emptyWithValidThumbnail: Object.freeze<AlbumEntity>({
|
||||
id: 'album-5',
|
||||
@@ -131,6 +152,9 @@ export const albumStub = {
|
||||
sharedLinks: [],
|
||||
sharedUsers: [],
|
||||
isActivityEnabled: true,
|
||||
startDate: null,
|
||||
endDate: null,
|
||||
assetCount: 0,
|
||||
}),
|
||||
oneAssetInvalidThumbnail: Object.freeze<AlbumEntity>({
|
||||
id: 'album-6',
|
||||
@@ -147,6 +171,9 @@ export const albumStub = {
|
||||
sharedLinks: [],
|
||||
sharedUsers: [],
|
||||
isActivityEnabled: true,
|
||||
startDate: assetStub.image.fileCreatedAt,
|
||||
endDate: assetStub.image.fileCreatedAt,
|
||||
assetCount: 1,
|
||||
}),
|
||||
oneAssetValidThumbnail: Object.freeze<AlbumEntity>({
|
||||
id: 'album-6',
|
||||
@@ -163,5 +190,8 @@ export const albumStub = {
|
||||
sharedLinks: [],
|
||||
sharedUsers: [],
|
||||
isActivityEnabled: true,
|
||||
startDate: assetStub.image.fileCreatedAt,
|
||||
endDate: assetStub.image.fileCreatedAt,
|
||||
assetCount: 1,
|
||||
}),
|
||||
};
|
||||
|
||||
+3
@@ -181,6 +181,9 @@ export const sharedLinkStub = {
|
||||
sharedUsers: [],
|
||||
sharedLinks: [],
|
||||
isActivityEnabled: true,
|
||||
startDate: today,
|
||||
endDate: today,
|
||||
assetCount: 1,
|
||||
assets: [
|
||||
{
|
||||
id: 'id_1',
|
||||
|
||||
Reference in New Issue
Block a user