diff --git a/mobile/lib/utils/action_button.utils.dart b/mobile/lib/utils/action_button.utils.dart index 8943bcfc4..d618ddbe9 100644 --- a/mobile/lib/utils/action_button.utils.dart +++ b/mobile/lib/utils/action_button.utils.dart @@ -152,7 +152,6 @@ enum ActionButtonType { ActionButtonType.openInfo => true, ActionButtonType.viewInTimeline => context.timelineOrigin != TimelineOrigin.main && - context.timelineOrigin != TimelineOrigin.deepLink && context.timelineOrigin != TimelineOrigin.trash && context.timelineOrigin != TimelineOrigin.lockedFolder && context.timelineOrigin != TimelineOrigin.archive && diff --git a/mobile/test/utils_legacy/action_button_utils_test.dart b/mobile/test/utils_legacy/action_button_utils_test.dart index 929ac16ed..066794a3e 100644 --- a/mobile/test/utils_legacy/action_button_utils_test.dart +++ b/mobile/test/utils_legacy/action_button_utils_test.dart @@ -645,6 +645,25 @@ void main() { }); }); + group('viewInTimeline button', () { + test('should show when owner and opened from a deep link', () { + final remoteAsset = createRemoteAsset(); + final context = ActionButtonContext( + asset: remoteAsset, + isOwner: true, + isArchived: false, + isInLockedView: false, + currentAlbum: null, + advancedTroubleshooting: false, + isStacked: false, + source: ActionSource.viewer, + timelineOrigin: TimelineOrigin.deepLink, + ); + + expect(ActionButtonType.viewInTimeline.shouldShow(context), isTrue); + }); + }); + group('setAlbumCover button', () { test('should show when owner, not locked, has album, and selectedCount is 1', () { final album = createRemoteAlbum();