-
-
Notifications
You must be signed in to change notification settings - Fork 3.2k
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: add album keyboard shortcuts #16442
feat: add album keyboard shortcuts #16442
Conversation
…ghlighting/selecting an album to add to.
…w album button into separate cmponent.
@@ -0,0 +1,39 @@ | |||
<script lang="ts"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Moved this out into its own component, since it now has to do selection and scrolling as well.
@@ -31,26 +34,53 @@ | |||
loading = false; | |||
}); | |||
|
|||
let filteredAlbums = $derived( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A lot of this logic was moved into the AlumModalRowConverter class, which is now unit tested.
Sorry, a little new to the process here - what's the process for adding reviewers? Do I have to add some people, or do people just jump in themselves ? |
We will get to the PR. Thank you for your contribution |
web/src/lib/components/shared-components/add-album-modal/album-modal.spec.ts
Outdated
Show resolved
Hide resolved
web/src/lib/components/shared-components/add-album-modal/album-modal.ts
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ugh - as part of the PR feedback I've cleaned up the file/package names so it's all consistently called album-select-*
now. I moved this file into the album-selection
package as well, but for some reason the github review picks it up as a delete & add. The individual commit even shows it as a move: 2d2b074 🤷
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great execution, thank you!
…n-grid * main: (22 commits) feat: add album keyboard shortcuts (immich-app#16442) fix(web): Default to context search on web (immich-app#16485) fix(mobile): Updated formatting of server address in networking (immich-app#16483) chore(mobile): rename log enum to lowercase (immich-app#16476) fix(web): Open huggingface.co link on settings page in new tab (immich-app#16470) fix(web): fix typos (immich-app#16466) fix(web): Fixed people list overflowing in advanced search (immich-app#16457) fix(web): unable to download live photo as anonymous user (immich-app#16455) fix(mobile): fix typos (immich-app#16456) chore: add 'not duplicate' checkbox to issue template (immich-app#16462) chore(mobile): post release task (immich-app#16437) feat(server): Shortened asset ID in storage template (immich-app#16433) chore: version v1.128.0 fix: memories off by one (immich-app#16434) fix(server): stringify error log parameter to ensure correct overload (immich-app#16422) fix: duplicate memories (immich-app#16432) chore(server): trash e2e cleanup (immich-app#16423) fix(server): include deleted assets if searching offline assets (immich-app#16417) fix: user delete sync query sort by id (immich-app#16420) fix(mobile): background backup failing due to store (immich-app#16418) ...
Amazing, thank you |
Description
This PR adds some new keyboard shortcuts. Namely you can now hit 'l' or 'Shift' + 'l' from the single asset viewer to open the 'Add to album/shared album' modals. The modals have been improved as well such that up and down arrows can be used to select a specific album/create a new album. This makes organizing photos into albums much faster!
Here's a quick demo video of the changes:
https://www.youtube.com/watch?v=JHSzuAeZ2RU
Fixes #15712
I'll do a separate PR to make this work in bulk as well (by using 'x' and arrows to select photos from the timeline).
This is my first change in Immich and I'm a little rusty when it comes to coding, so please feel free to point out any improvements. I felt that the AddAlbumModal logic was a bit complex already (and distributed in templating code). I didn't really want to add to this, so I re-factored the logic of what to display in the modal out into a separate class and wrote a unit test for it.
How Has This Been Tested?
Lots of manual testing and I wrote a fairly detailed unit test to test what the add album modal displays as well as selecting different rows.
Checklist:
src/services
uses repositories implementations for database calls, filesystem operations, etc.src/repositories/
is pretty basic/simple and does not have any immich specific logic (that belongs insrc/services
)