Commit Graph

56 Commits

Author SHA1 Message Date
Fynn Petersen-Frey
db6b14361d
fix(mobile): proper syncing with Recents album on iOS (#2020)
* fix(mobile): deal with Recents album on iOS

* feature(mobile): local asset sync logging

* add comments

* delete ExifInfo when deleting Asset

---------

Co-authored-by: Fynn Petersen-Frey <zoodyy@users.noreply.github.com>
2023-03-19 17:05:18 -05:00
Alex
416e30ede2
fix(mobile): Sorted shared album and added share user doesn't reflect change in album view (#1955)
* fix: sorted shared album

* Added TODO comment for tomorrow work

* update album shared property after adding user

---------

Co-authored-by: Fynn Petersen-Frey <zoodyy@users.noreply.github.com>
2023-03-12 08:43:09 -05:00
Fynn Petersen-Frey
8708867c1c
feature(mobile): sync assets, albums & users to local database on device (#1759)
* feature(mobile): sync assets, albums & users to local database on device

* try to fix tests

* move DB sync operations to new SyncService

* clear db on user logout

* fix reason for endless loading timeline

* fix error when deleting album

* fix thumbnail of device albums

* add a few comments

* fix Hive box not open in album service when loading local assets

* adjust tests to int IDs

* fix bug: show all albums when Recent is selected

* update generated api

* reworked Recents album isAll handling

* guard against wrongly interleaved sync operations

* fix: timeline asset ordering (sort asset state by created at)

* fix: sort assets in albums by created at
2023-03-03 16:38:30 -06:00
Alex
a2549c5bbd
fix(mobile): no album thumbnail lead to no album selection shown and add global logs (#1841)
* fix(mobile): no album thumbnail lead to no album selection shown

* add more log info

* added global error handling

* better place to init logger

* get more log
2023-02-23 06:36:17 +00:00
Alex
bf3f4e560d
chore(mobile): Improve reliability of asset loading and indexing (#1813)
* chore(mobile): Improve reliability of asset loading and indexing

* chore: add comments

* chore: remove log

* fix: put back box open sequence
2023-02-21 09:25:31 -06:00
Alex
98998cccbc
fix(mobile): user get logged out upon clicking on any thing after logging in (#1808)
* fix(mobile): user get logged out upon clicking on any thing after logging in

* wip: fixing still

* fix: the actual issue

* Fix: avaialble album not updating UI
2023-02-20 21:43:39 -06:00
Fynn Petersen-Frey
911c35a7f1
refactor(mobile): add Isar DB & Store class (#1574)
* refactor(mobile): add Isar DB & Store class

new Store: globally accessible key-value store like Hive (but based on Isar)

replace first few places of Hive usage with the new Store

* reduce max. DB size to prevent errors on older iOS devices

---------

Co-authored-by: Alex <alex.tran1502@gmail.com>
2023-02-09 11:32:08 -06:00
Fynn Petersen-Frey
2139853dd9
refactor(mobile): introduce Album & User classes (#1561)
replace usages of AlbumResponseDto with Album
replace usages of UserResponseDto with User
2023-02-06 01:13:32 -06:00
Matthias Rupp
bb0b2a1f53
feat(mobile): Library page rework (album sorting, favorites) (#1501)
* Add album sorting

* Change AppBar to match photos page behaviour

* Add buttons

* First crude implementation of the favorites page

* Clean up

* Add favorite button

* i18n

* Add star indicator to thumbnail

* Add favorite logic to separate provider and fix favorite behavior in album

* Review feedback (Add isFavorite variable)

* dev: style buttons

* dev: styled drop down button

---------

Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2023-02-04 21:25:11 -06:00
Fynn Petersen-Frey
0048662182
refactor(mobile): reworked Asset, store all required fields from local & remote (#1539)
replace usage of AssetResponseDto with Asset

Add new class ExifInfo to store data from ExifResponseDto
2023-02-04 14:42:42 -06:00
Jason Rasmussen
2b0b2bb1ae
refactor(server): download file (#1512)
* refactor(server): download file

* chore: generate open-api and remove unused refs

* chore(server): tests

* chore: remove unused code
2023-02-03 09:16:25 -06:00
martyfuhry
f23979024a
chore(mobile): Update share_file to latest version and migrate to using cross platform shareXFile (#1476)
* update share_plus and use sharexfile

* rename variable
2023-01-29 20:46:30 -06:00
Matthias Rupp
bcb0056b55
chore(mobile): Run dart analyze in CI (#1425)
* Run dart analyze in CI

* Add pub get

* Fix linter errors in mobile code
2023-01-26 08:40:19 -06:00
Matthias Rupp
a8cbda5f24
Fix crash at first start when 'userInfoBox' does not contain 'serverEndpointKey' before API service is initialized (#1362) 2023-01-19 13:06:57 -06:00
Connery Noble
43e9529ce4
feat(.well-known): add .well-known/immich to reference API endpoint (#1308)
* feat(.well-known): add .well-known/immich to reference API endpoint

* feat(.well-known): make schema optional (defaults to https)

* adjust method comment to be a little less confusing

* fix casting issue with resovled url

* include when checking Well-known, update server hint

* add validation for login form's server url

* consolidate common process into resolveAndSetEndpoint

* fix missed prettier formatting

* revert translation changes

* update environment variable description, hopefully a bit clearer

* rename environment variable to IMMICH_API_URL_EXTERNAL

* comment out optional env variables

* fix(web): browser-side api client to include authorization token

* Revert "fix(web): browser-side api client to include authorization token"

This reverts commit 60e338938f.

* remove multi-domain related changes
2023-01-19 09:45:37 -06:00
Matthias Rupp
7a1ae8691e
feat(mobile): Various minor performance improvements (#1176)
* Improve scroll performance by introducing repaint boundaries and moving more calculations to providers.

* Add error handing for malformed dates.

* Remove unused method

* Use compute in different places to improve app performance during heavy tasks

* Fix test

* Refactor `List<RenderAssetGridElement>` to separate `RenderList` class and make `fromAssetGroups` a static method of this class.

* Fix loading indicator bug

* Use provider directly

* `RenderList` refactoring

* `AssetNotifier` refactoring

* Move `combine` to static private method

* Extract compute methods in cache services to static private methods.

* Use `tryParse` instead of `parse` with try/catch for dates.

* Fix bug in caching mechanism.

* Fixed state not being used to trigger conditional rendering

* styling

* Corrected state

Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2023-01-18 09:59:23 -06:00
Fynn Petersen-Frey
765181bbc0
chore(mobile): improve CSV log export (#1032) 2022-11-28 10:17:27 -06:00
Fynn Petersen-Frey
d82dec9773
fix(mobile): fix cache invalidation on logout (#1030)
await all the cache-invalidation operations during logout and catch errors to actually perform all operations.
2022-11-28 10:01:09 -06:00
Alex
024177515d
feat(mobile) Add in app logging to show app's log information (#1014) 2022-11-27 14:34:19 -06:00
Alex
39b7ab66d4
chore(mobile): clean up linter problems (#1000) 2022-11-21 06:13:14 -06:00
Alex
b3e51cc849
feat(mobile) Add OAuth Login On Mobile (#990)
* Added return type for oauth/callback

* Remove console.log

* Redirect app

* Wording

* Added loading state change

* Added OAuth login on mobile

* Return correct status for  correct redirection

* Auto discovery OAuth Login
2022-11-20 11:43:10 -06:00
Alex
e799f35dd2
chore(server) refactor serveFile and downloadFile endpoint (#978) 2022-11-16 00:11:16 -06:00
Fynn Petersen-Frey
8d0ff974e1
refactor(mobile): tidy-up dependencies, remove unused, replace rarely used ones (#948) 2022-11-11 11:52:02 -06:00
Fynn Petersen-Frey
1633af7af6
feat(mobile): show local assets (#905)
* introduce Asset as composition of AssetResponseDTO and AssetEntity

* filter out duplicate assets (that are both local and remote, take only remote for now)

* only allow remote images to be added to albums

* introduce ImmichImage to render Asset using local or remote data

* optimized deletion of local assets

* local video file playback

* allow multiple methods to wait on background service finished

* skip local assets when adding to album from home screen

* fix and optimize delete

* show gray box placeholder for local assets

* add comments

* fix bug: duplicate assets in state after onNewAssetUploaded
2022-11-08 11:00:24 -06:00
Matthias Rupp
3617433858 Refactor abstract class to separate file 2022-10-19 22:03:54 +02:00
Alex
7e8bf94543
fix/cache read write error ios16 (#691)
* Fix(mobile) cache read/write issue, cannot load image on ios16

* Update
2022-09-14 10:18:25 -05:00
Matthias Rupp
25e68cf826
Better caching for mobile (#521)
* Use custom caches in all modules

* Cache Settings

* Fix wrong key

* Create custom cache repository based on hive

* Show cache usage in settings

* Show cache sizes

* Change settings ranges and default value

* Handle cache clear by operating system

* Resolve review comments
2022-08-29 22:44:43 -05:00
Matthias Rupp
8e4c4c34e4
Use CachedNetworkImage and separate cache for thumbnails on library page (#509)
* Use CachedNetworkImage and separate cache for thumbnails on library page

* Use caching for shared albums as well

* Introduce cache service
2022-08-21 09:41:36 -07:00
Alex
c1b22125fd
Add mobile dark mode and user setting (#468)
* styling light and dark theme

* Icon topbar

* Fixed app bar title dark theme

* Fixed issue with getting thumbnail for things

* Refactor sharing page

* Refactor scroll thumb

* Refactor chip in auto  backup indiation button

* Refactor sharing page

* Added theme toggle

* Up version for testflight build

* Refactor backup controller page

* Refactor album selection page

* refactor album pages

* Refactor gradient color profile header

* Added theme switcher

* Register app theme correctly

* Added locale to the app

* Added translation key

* Styling for bottomsheet colors

* up server version

* Fixed font size

* Fixed overlapsed sliverappbar on photos screen
2022-08-15 18:53:30 -05:00
Alex
30f069a5db
Add settings screen on mobile (#463)
* Refactor profile drawer to sub component

* Added setting page, routing with some options

* Added setting service

* Implement three stage settings

* get app setting for three stage loading
2022-08-13 15:51:09 -05:00
Matthias Rupp
52377c2dcf
Fix sharing on iPad (#453) 2022-08-11 08:13:33 -05:00
Matthias Rupp
e57e279fe1
Share assets from mobile to other apps (#435)
* Share unique assets

* Style share preparing dialog

* Share assets from multiselect

* Fix i18n

* Use navigator like in delete dialog

* Center bottom-bar buttons
2022-08-08 10:46:12 -05:00
Alex
e8d1f89a47
Implement album feature on mobile (#420)
* Refactor sharing to album

* Added library page in the bottom navigation bar

* Refactor SharedAlbumService to album service

* Refactor apiProvider to its file

* Added image grid

* render album thumbnail

* Using the wrap to render thumbnail and album info better

* Navigate to album viewer

* After deletion, navigate to the respective page of the shared and non-shared album

* Correctly remove album in local state

* Refactor create album page

* Implemented create non-shared album
2022-08-03 00:04:34 -05:00
Alex
be3e3e5d7e
Added Cookie Authentication (#360)
* Added Cookie Authentication

* Fixed issue with bearer is in lower case

* Fixed bearer to Bearer to conform with standard
2022-07-18 14:14:25 -05:00
Alex
ae7e582ec8
Refactor mobile to use OpenApi generated SDK (#336) 2022-07-13 07:23:48 -05:00
Alex
58ec7553ea
Add information for uploading asset and error indication with error message for each failed upload. (#315)
* Added info box

* Fixed upload endpoint doesn't report error status code

* Added chip to show update error

* Added chip to show failed upload

* Add duplication check for upload

* Better duplication-checking placement

* Remove check for duplicated asset

* Added failed backup status route

* added page

* Display error card with thumbnail

* Improved styling

* Set thumbnail with better quality

* Remove force upload error
2022-07-06 16:12:55 -05:00
xpwmaosldk
d02b97e1c1
Add service provider (#250)
* optimize android side gradle settings

* android minsdk back to 21

* remove unused package, update linter and fix lint error

* clean code of 'shared module' with offical dart style guide

* restore uploadProfileImage method in UserService

* add service provider

* fix searchFocusNode init error
2022-06-25 13:46:51 -05:00
xpwmaosldk
ef097d15dd
Clean code of shared folder (#249)
* optimize android side gradle settings

* android minsdk back to 21

* remove unused package, update linter and fix lint error

* clean code of 'shared module' with offical dart style guide

* restore uploadProfileImage method in UserService
2022-06-22 23:14:14 -05:00
xpwmaosldk
caaa474c23
Optimize android's Gradle settings and clean up mobile source code (#240)
* optimize android side gradle settings

* android minsdk back to 21

* remove unused package, update linter and fix lint error
2022-06-22 00:23:35 -05:00
Alex
18c22d2a6c
Fix #197 app logged off when closed (#239)
* Fixed issue with app logging off after closing

* Change version to reflect minor change
2022-06-20 18:10:23 -05:00
Jaime Baez
517a3363d6
Refactor API for albums feature (#155)
* Rename "shared" to "album"

Prepare moving "SharedAlbums" to "Albums"

* Update server album API endpoints

* Update mobile app album endpoints

Also add `putRequest` to mobile network.service

* Add GET album collection filter

- allow to filter by owner = 'mine' | 'their'
- make sharedWithUserIds no longer required when creating an album

* Rename remaining variables to "album"

* Add ParseMeUUIDPipe to validate uuid or `me`

* Add album params validation

* Update todo in mobile album service.

* Setup e2e testing

* Add user e2e tests

* Rename database host env variable to DB_HOST

* Add some `Album` e2e tests

Also fix issues found with the tests

* Force push (try to recover DB_HOST env)

* Rename db host env variable to `DB_HOSTNAME`

* Remove unnecessary `initDb` from test-utils

The current database.config is running the migrations:
`migrationsRun: true`

* Remove `initDb` usage from album e2e test

* Update GET albums filter to `shared`

- add filter by all / shared / not shared
- add response DTOs
- add GET albums e2e tests

* Update album e2e tests for user.service changes

* Update mobile app to use album response DTOs

* Refactor album-service DB into album-registry

- DB logic refactored into album-repository making it easier to test
- add some album-service unit tests
- add `clearMocks` to jest configuration

* Finish implementing album.service unit tests

* Rename response DTO

Make them consistent with rest of the project naming

* Update debug log messages in mobile network service

* Rename table `shared_albums` to `albums`

* Rename table `asset_shared_album`

* Rename Albums `sharedAssets` to `assets`

* Update tests to match updated "delete" response

* Fixed asset cannot be compared in Set by adding Equatable package

* Remove hero effect to fixed janky animation

Co-authored-by: Alex <alex.tran1502@gmail.com>
2022-06-18 10:56:36 -05:00
Alex
a8220172f8
WIP refactor container and queuing system (#206)
* refactor microservices to machine-learning

* Update tGithub issue template with correct task syntax

* Added microservices container

* Communicate between service based on queue system

* added dependency

* Fixed problem with having to import BullQueue into the individual service

* Added todo

* refactor server into monorepo with microservices

* refactor database and entity to library

* added simple migration

* Move migrations and database config to library

* Migration works in library

* Cosmetic change in logging message

* added user dto

* Fixed issue with testing not able to find the shared library

* Clean up library mapping path

* Added webp generator to microservices

* Update Github Action build latest

* Fixed issue NPM cannot install due to conflict witl Bull Queue

* format project with prettier

* Modified docker-compose file

* Add GH Action for Staging build:

* Fixed GH action job name

* Modified GH Action to only build & push latest when pushing to main

* Added Test 2e2 Github Action

* Added Test 2e2 Github Action

* Implemented microservice to extract exif

* Added cronjob to scan and generate webp thumbnail  at midnight

* Refactor to ireduce hit time to database when running microservices

* Added error handling to asset services that handle read file from disk

* Added video transcoding queue to process one video at a time

* Fixed loading spinner on web while loading covering the info panel

* Add mechanism to show new release announcement to web and mobile app (#209)

* Added changelog page

* Fixed issues based on PR comments

* Fixed issue with video transcoding run on the server

* Change entry point content for backward combatibility when starting up server

* Added announcement box

* Added error handling to failed silently when the app version checking is not able to make the request to GITHUB

* Added new version announcement overlay

* Update message

* Added messages

* Added logic to check and show announcement

* Add method to handle saving new version

* Added button to dimiss the acknowledge message

* Up version for deployment to the app store
2022-06-11 16:12:06 -05:00
Alex
d476b15312
Implemented user profile upload and show on web/mobile (#191)
* Update mobile dependencies

* Added image picker

* Added mechanism to upload profile image

* Added image type to send to web

* Added styling for circle avatar

* Fixxed issue with sharp cannot resize image properly

* Finished displaying and uploading user profile

* Added user profile to web
2022-05-28 22:35:45 -05:00
Alex
373b6918f8
Feature #120 #89 selective backup in app (#137) 2022-05-06 07:22:23 -05:00
Alex
4309104925
118 - Implement shared album feature (#124)
* New features 
  - Share album. Users can now create albums to share with existing people on the network.
  - Owner can delete the album.
  - Owner can invite the additional users to the album.
  - Shared users and the owner can add additional assets to the album.
* In the asset viewer, the user can swipe up to see detailed information and swip down to dismiss.
* Several UI enhancements.
2022-04-23 21:08:45 -05:00
Alex
3bdcdef198
Fixed backup stuck at unsupported format (#108)
* Added webp as supported file type, allow continue upload when an image fail

* Added webp as supported file type, allow continue upload when an image fail

* Solved issue with bad assets cause backup to stop
2022-04-04 23:37:48 -05:00
Alex
90ef64efa3
Download asset to local and error fixing (#100)
* Update photo_manager pub package
* Added download endpoint for assets
* Successfully save a photo to the local device's gallery
* Save save a video to the local device's gallery
* Fixed #97
* Added download loading indicator
* Refactor and increase the font size for curated search thumbnail images
* Reposition loading animation on the search result page
2022-04-02 12:31:53 -05:00
Alex
e407a4fa13
Get thumbnail from app (#68)
* Renamed multipart filed name 'files' to 'assetData'. 
* Added an additional field name of 'thumbnailData' to multipart form.
* Implemented upload mechanism for thumbnail directly from the mobile client.
* Removed dead code
* Implemented a version checking mechanism.
2022-03-22 01:22:04 -05:00
Alex
274fba1bd2
Implement CI/CD for Android (#48)
* Implement CI/CD for Android with Fastlane
2022-03-13 22:10:07 -05:00
Alex Tran
e13d4a6b9c Show correct device type when registering new device 2022-03-11 14:38:15 -06:00