[PR #24856] feat: Shared Links: Slug Support, UI Refactor, and Simplified Actions #18012

Open
opened 2026-02-05 16:31:09 +03:00 by OVERLORD · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/immich-app/immich/pull/24856
Author: @Lauritz-Tieste
Created: 12/26/2025
Status: 🔄 Open

Base: mainHead: main


📝 Commits (10+)

  • 6c8c36e refactor: simplify shared link UI
  • 912f314 feat: add delete link functionality in shared link edit page
  • 2a9e4aa refactor: streamline shared link edit page layout and improve code readability
  • 969aad1 refactor: update shared link item expiry icon logic for better clarity
  • af17633 feat: enhance shared link expiry options with date selection and presets
  • cf0a9a9 feat: add slug functionality to shared links for custom URLs
  • a166af9 refactor: improve UI elements in shared link edit page for better clarity and usability
  • a768a97 fix: adjust date selection logic to prevent selecting dates in the past
  • ef0da98 feat: add confirmation dialog for deleting shared links
  • 7626dc2 fix: convert expiry date to local time for shared links

📊 Changes

5 files changed (+420 additions, -400 deletions)

View changed files

📝 mobile/lib/models/shared_link/shared_link.model.dart (+10 -3)
📝 mobile/lib/pages/library/shared_link/shared_link.page.dart (+31 -62)
📝 mobile/lib/pages/library/shared_link/shared_link_edit.page.dart (+288 -175)
📝 mobile/lib/services/shared_link.service.dart (+5 -0)
📝 mobile/lib/widgets/shared_link/shared_link_item.dart (+86 -160)

📄 Description

Description

This pull request introduces support for a new slug field in the SharedLink model and refactors the shared link UI for improved usability and maintainability. The changes ensure that slugs are handled throughout the model, service, and UI layers, and update the shared link list and item presentation for a more modern and user-friendly experience.

Model and Service Enhancements:

  • Added a nullable slug field to the SharedLink model, updated constructors, copyWith, equality, and hashcode methods to include slug.

UI/UX Improvements:

  • Refactored the shared link list page to use a centered empty state and a responsive layout: grid for wide screens and a separated list for narrow screens, removing unnecessary headers and padding.
  • Improved the SharedLinkItem widget:
    • Simplified expiry calculation and display, added icons for expiry status, and replaced chips with outlined cards for share parameter info.
    • Updated the share link copy logic to use the slug if available and changed the URL path from /share/{key} to /s/{slug or key}.
    • Changed the item layout to use Dismissible for swipe-to-delete with confirmation, made the whole item tappable for editing, and enabled long-press to copy the link.

How Has This Been Tested?

  • Manual testing on physical device

Screenshots (if appropriate)

https://github.com/user-attachments/assets/876b36ca-3e55-49df-95b7-c9ceecf9705b

Checklist:

  • I have performed a self-review of my own code
  • I have made corresponding changes to the documentation if applicable
  • I have no unrelated changes in the PR.
  • I have confirmed that any new dependencies are strictly necessary.
  • I have written tests for new code (if applicable)
  • I have followed naming conventions/patterns in the surrounding code
  • All code in src/services/ uses repositories implementations for database calls, filesystem operations, etc.
  • All code in src/repositories/ is pretty basic/simple and does not have any immich specific logic (that belongs in src/services/)

Please describe to which degree, if any, an LLM was used in creating this pull request.

GPT-5-Codex for time selection mechanism and GitHub Copilot for PR Summary


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/immich-app/immich/pull/24856 **Author:** [@Lauritz-Tieste](https://github.com/Lauritz-Tieste) **Created:** 12/26/2025 **Status:** 🔄 Open **Base:** `main` ← **Head:** `main` --- ### 📝 Commits (10+) - [`6c8c36e`](https://github.com/immich-app/immich/commit/6c8c36eb0a7ee99f6eb6cfecde73ef26d5f5f313) refactor: simplify shared link UI - [`912f314`](https://github.com/immich-app/immich/commit/912f3143c61deb61cae2838746c13056e008e2ac) feat: add delete link functionality in shared link edit page - [`2a9e4aa`](https://github.com/immich-app/immich/commit/2a9e4aaf18dbb06628cb4924ac8bcd51f872a8eb) refactor: streamline shared link edit page layout and improve code readability - [`969aad1`](https://github.com/immich-app/immich/commit/969aad195f7b174e445dac67ab6197b307f124c3) refactor: update shared link item expiry icon logic for better clarity - [`af17633`](https://github.com/immich-app/immich/commit/af1763322c1135d0baea5fa2fd0ed2704b46f70e) feat: enhance shared link expiry options with date selection and presets - [`cf0a9a9`](https://github.com/immich-app/immich/commit/cf0a9a995b207aa0f78ee71fccc7380c345de407) feat: add slug functionality to shared links for custom URLs - [`a166af9`](https://github.com/immich-app/immich/commit/a166af94c6dc8b3c3c4f8a864a4eb26af86ca716) refactor: improve UI elements in shared link edit page for better clarity and usability - [`a768a97`](https://github.com/immich-app/immich/commit/a768a978b7f62f1d3f709eb848a7f431fc7e9eb9) fix: adjust date selection logic to prevent selecting dates in the past - [`ef0da98`](https://github.com/immich-app/immich/commit/ef0da98a4e3b2798ba8faebb0d6aae857ec7b504) feat: add confirmation dialog for deleting shared links - [`7626dc2`](https://github.com/immich-app/immich/commit/7626dc21542919f2c44181a6226b04be1f266473) fix: convert expiry date to local time for shared links ### 📊 Changes **5 files changed** (+420 additions, -400 deletions) <details> <summary>View changed files</summary> 📝 `mobile/lib/models/shared_link/shared_link.model.dart` (+10 -3) 📝 `mobile/lib/pages/library/shared_link/shared_link.page.dart` (+31 -62) 📝 `mobile/lib/pages/library/shared_link/shared_link_edit.page.dart` (+288 -175) 📝 `mobile/lib/services/shared_link.service.dart` (+5 -0) 📝 `mobile/lib/widgets/shared_link/shared_link_item.dart` (+86 -160) </details> ### 📄 Description ## Description This pull request introduces support for a new `slug` field in the `SharedLink` model and refactors the shared link UI for improved usability and maintainability. The changes ensure that slugs are handled throughout the model, service, and UI layers, and update the shared link list and item presentation for a more modern and user-friendly experience. **Model and Service Enhancements:** * Added a nullable `slug` field to the `SharedLink` model, updated constructors, `copyWith`, equality, and hashcode methods to include `slug`. **UI/UX Improvements:** * Refactored the shared link list page to use a centered empty state and a responsive layout: grid for wide screens and a separated list for narrow screens, removing unnecessary headers and padding. * Improved the `SharedLinkItem` widget: - Simplified expiry calculation and display, added icons for expiry status, and replaced chips with outlined cards for share parameter info. - Updated the share link copy logic to use the `slug` if available and changed the URL path from `/share/{key}` to `/s/{slug or key}`. - Changed the item layout to use `Dismissible` for swipe-to-delete with confirmation, made the whole item tappable for editing, and enabled long-press to copy the link. ## How Has This Been Tested? - [x] Manual testing on physical device <details><summary><h2>Screenshots (if appropriate)</h2></summary> <!-- Images go below this line. --> https://github.com/user-attachments/assets/876b36ca-3e55-49df-95b7-c9ceecf9705b </details> ## Checklist: - [x] I have performed a self-review of my own code - [x] I have made corresponding changes to the documentation if applicable - [x] I have no unrelated changes in the PR. - [x] I have confirmed that any new dependencies are strictly necessary. - [x] I have written tests for new code (if applicable) - [x] I have followed naming conventions/patterns in the surrounding code - [x] All code in `src/services/` uses repositories implementations for database calls, filesystem operations, etc. - [x] All code in `src/repositories/` is pretty basic/simple and does not have any immich specific logic (that belongs in `src/services/`) ## Please describe to which degree, if any, an LLM was used in creating this pull request. GPT-5-Codex for time selection mechanism and GitHub Copilot for PR Summary --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
OVERLORD added the pull-request label 2026-02-05 16:31:09 +03:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: immich-app/immich#18012