Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(mobile): darken screen on backup page #11623

Merged
merged 17 commits into from
Aug 9, 2024

Conversation

Saschl
Copy link
Contributor

@Saschl Saschl commented Aug 6, 2024

Follow up of: #11621, will darken the screen when starting the backup to avoid burn-in issues.

I've decided to create 2 separate PRs as this one will likely take a bit longer as I need some feedback on how to implement this best UX wise.

Tested with Android emulator (Pixel 8), iOS Emulator (iPhone 15) and iPhone15 Plus, OnePlus 3T (real devices)

Current idea (sped up, actual timeout is 60 seconds), open for feedback :)

Simulator.Screen.Recording.-.iPhone.15.-.2024-08-07.at.01.18.01.mov

@alextran1502
Copy link
Contributor

I think we don't need to show the confirmation form here. When the backup process start, we start a timer, after 1 minutes then we auto darken the screen

@Saschl Saschl marked this pull request as ready for review August 6, 2024 23:25
@Saschl
Copy link
Contributor Author

Saschl commented Aug 6, 2024

I think we don't need to show the confirmation form here. When the backup process start, we start a timer, after 1 minutes then we auto darken the screen

Sounds fine, applied the changes and removed the dialog.

@Saschl Saschl changed the title feat(mobile): darken screen on backup feat(mobile): darken screen on backup page Aug 7, 2024
useEffect(
() {
if (backupState.backupProgress == BackUpProgressEnum.inProgress) {
darkenScreenTimer.value = Timer(const Duration(seconds: 60), () {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we refactor this to a method so we don't duplicate code on line 306?

@alextran1502
Copy link
Contributor

Thank you for the contribution again! I tried it and like it a lot. One small request: Can we make the screen darken to a certain level, not completely dark? Think of an always-on mode screen shade so the user can still see what is happening?

@alextran1502 alextran1502 enabled auto-merge (squash) August 9, 2024 16:34
@alextran1502 alextran1502 merged commit b1587a5 into immich-app:main Aug 9, 2024
22 checks passed
@Saschl
Copy link
Contributor Author

Saschl commented Aug 9, 2024

Thanks for taking care! I initially chose to turn the screen black completely oled displays will essentially be off and avoid burn ins. But I’m not even sure if that’s a thing anymore.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants