Skip to content

feat(updates): add featured image and gallery to Updates - #946

Merged
danieltruong merged 2 commits into
developfrom
fix-updates-publish-picker
Sep 24, 2026
Merged

danieltruong merged 2 commits into
developfrom
fix-updates-publish-picker

Conversation

@danieltruong

Copy link
Copy Markdown
Collaborator

Staff can add images to EPIC Updates, and the publish picker is fixed.

Update editor:

  • A featured image, and a gallery of up to 5 photos. Each can be uploaded new or picked from the project's images. Photos can be reordered and removed.
  • Every image needs alt text. Caption is limited to 300 characters and credit to 150, with counters. A message says when alt text is missing.
  • Uploads accept JPEG, PNG, WebP and GIF up to 10 MB, and check that the file extension matches its type. Focus moves to the new row's alt text after an upload, unless the user has moved elsewhere.
  • Publish is blocked while an image or attachment is not public, with the reason shown.
  • The picker offers only public images from the same project. It uses radio buttons when one image can be picked.

Other:

  • file-upload takes an accept list and shows a hint. Its browse link is now a button (project document upload, notification upload, add comment).
  • The project Updates list sorts by date added by default, and keeps sort and page size when the page changes.

Needs the eagle-api Update image support (bcgov/eagle-api#907).

Tests: new specs for the image field, the picker, the image helpers, the update rules, file-upload and the project Updates list. The editor spec gains DocumentService and LoggingService spies.

- Featured image plus gallery of up to 5 images, uploaded or picked
  from existing documents; alt text required, caption 300 and
  credit 150 chars max
- Fix publish picker; non-public images or attachments block Publish
  so a public Update never links a hidden file
- file-upload: add accept and hint, browse link becomes a button
- Project Updates list sorts by -dateAdded by default
@danieltruong
danieltruong merged commit b24efca into develop Sep 24, 2026
4 checks passed
@danieltruong
danieltruong deleted the fix-updates-publish-picker branch September 24, 2026 22:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant