Page MenuHomePhabricator

Build image detail view UI
Closed, ResolvedPublic5 Estimated Story Points

Description

Background

We would like to build out the detailed view for images for the image browsing experiment

User story

  • As a visual learner, I want to be able to view and image in detail, so that I can more easily explore the content through iamges

Requirements

  • Detail view opens when user interacts with entry point
  • View must be closable. When closed, the original article will appear
  • Detail view must contain entry points to:
  • view full screen
  • open image in commons
  • share
  • download

(these entry points will retain their current iconography and functionality)

  • The image caption must appear on page
  • Text must appear readable on the page

BDD

  • For QA engineer to fill out

Test Steps

  • For QA engineer to fill out

Design

https://www.figma.com/design/YH68yubI663iFLZfuhtOE6/FY-25-6-WE-3.2?node-id=392-2553&p=f&t=9dmSXZ7MONu8rUt8-0

Acceptance criteria

  • Build detail view for a single image. View does not need to include the following:
    • article paragraph text
    • cropping image

Communication criteria - does this need an announcement or discussion?

  • Add communication criteria

Rollback plan

  • What is the rollback plan in production for this task if something goes wrong?

This task was created by Version 1.2.0 of the Web team task template using phabulous

Event Timeline

ovasileva set the point value for this task to 5.
mfossati changed the task status from Open to In Progress.Aug 7 2025, 2:27 PM
mfossati moved this task from Committed to Doing on the Reader Growth Team (Sprint 3) board.

Change #1176498 had a related patch set uploaded (by Matthias Mullie; author: Marco Fossati):

[mediawiki/extensions/ReaderExperiments@master] ImageBrowsing: image detail view

https://gerrit.wikimedia.org/r/1176498

For desktop view of this UI, see Figma:

Screenshot 2025-08-19 at 3.41.40 PM.png (1,414×1,544 px, 1 MB)

Notes:

  • The max width of the detail overlay is 950px (I chose this because it's the max width of the content area in Vector, but I don't have a strong conviction about it yet)
  • Wider than ~600px (choose a breakpoint around 600px that we're already using in Vector if possible), the visual ToC is a two column view.
  • A dialogue scrim should obscure the article behind the detail view.

Otherwise everything works the same.

@JScherer-WMF This may be annotated in dev mode, but I can't currently see these, so I'll post questions here:

  • That light/dark grey background: are those fixed colors, or is there to be some sort of interpolation of colors (like the caption background etc.)?
  • Looks like that light grey isn't fully aligned with the bottom of the image - should it be?

Test wiki created on Patch demo by EGardner (WMF) using patch(es) linked to this task:
https://99ca4c09f5.catalyst.wmcloud.org/w/

Test wiki on Patch demo by EGardner (WMF) using patch(es) linked to this task was deleted:

https://99ca4c09f5.catalyst.wmcloud.org/w/

Change #1176498 merged by jenkins-bot:

[mediawiki/extensions/ReaderExperiments@master] ImageBrowsing: image detail view

https://gerrit.wikimedia.org/r/1176498

For desktop view of this UI, see Figma:

Screenshot 2025-08-19 at 3.41.40 PM.png (1,414×1,544 px, 1 MB)

Notes:

  • The max width of the detail overlay is 950px (I chose this because it's the max width of the content area in Vector, but I don't have a strong conviction about it yet)
  • Wider than ~600px (choose a breakpoint around 600px that we're already using in Vector if possible), the visual ToC is a two column view.
  • A dialogue scrim should obscure the article behind the detail view.

Otherwise everything works the same.

Since we're only running the A/B test on mobile with a limited (0.1% of logged-out users) audience, let's hold off on building this out until after the A/B test in the case it's successful. @JScherer-WMF - let me know if that raises any concerns!

FYI the caption text & background color is not functional on patchdemo. I believe that is because $wgReaderExperimentsApiBaseUri is not yet set there, and this patch should solve that: https://gitlab.wikimedia.org/repos/test-platform/catalyst/patchdemo/-/merge_requests/197

I will file a new task for desktop UI work specifically, and then we can close this one. Will do that later today.

Change #1180944 had a related patch set uploaded (by Eric Gardner; author: Eric Gardner):

[mediawiki/extensions/ReaderExperiments@master] ImageBrowsing: Introduce "useBackgroundColor" composable

https://gerrit.wikimedia.org/r/1180944

Change #1180950 had a related patch set uploaded (by Eric Gardner; author: Eric Gardner):

[mediawiki/extensions/ReaderExperiments@master] ImageBrowsing: Use template ref for Detail view caption

https://gerrit.wikimedia.org/r/1180950

Change #1180961 had a related patch set uploaded (by Eric Gardner; author: Eric Gardner):

[mediawiki/extensions/ReaderExperiments@master] ImageBrowsing: Extract new DetailViewCaption component

https://gerrit.wikimedia.org/r/1180961

Change #1180987 had a related patch set uploaded (by Eric Gardner; author: Eric Gardner):

[mediawiki/extensions/ReaderExperiments@master] ImageBrowsing: Introduce useMwApi composable

https://gerrit.wikimedia.org/r/1180987

Change #1181003 had a related patch set uploaded (by Eric Gardner; author: Eric Gardner):

[mediawiki/extensions/ReaderExperiments@master] ImageBrowsing: Extract new DetailViewControls component

https://gerrit.wikimedia.org/r/1181003

Change #1180950 merged by jenkins-bot:

[mediawiki/extensions/ReaderExperiments@master] ImageBrowsing: Use template ref for Detail view caption

https://gerrit.wikimedia.org/r/1180950

Change #1180944 merged by jenkins-bot:

[mediawiki/extensions/ReaderExperiments@master] ImageBrowsing: Introduce "useBackgroundColor" composable

https://gerrit.wikimedia.org/r/1180944

Change #1180961 merged by jenkins-bot:

[mediawiki/extensions/ReaderExperiments@master] ImageBrowsing: Extract new DetailViewCaption component

https://gerrit.wikimedia.org/r/1180961

Change #1180987 merged by jenkins-bot:

[mediawiki/extensions/ReaderExperiments@master] ImageBrowsing: Introduce useMwApi composable

https://gerrit.wikimedia.org/r/1180987

I'm moving this back to the "doing" column for now because I want to try to get captions working properly here, since that's listed as one of the requirements.

If it seems feasible I may attempt to address desktop design as well, otherwise we can leave that for next sprint.

egardner updated Other Assignee, removed: matthiasmullie.
egardner added a subscriber: mfossati.

Change #1181672 had a related patch set uploaded (by Matthias Mullie; author: Matthias Mullie):

[mediawiki/extensions/ReaderExperiments@master] Close overlay on escape

https://gerrit.wikimedia.org/r/1181672

Change #1181794 had a related patch set uploaded (by Eric Gardner; author: Eric Gardner):

[mediawiki/extensions/ReaderExperiments@master] ImageBrowsing: use real captions in DetailViewCaption and simplify props

https://gerrit.wikimedia.org/r/1181794

Change #1181672 merged by jenkins-bot:

[mediawiki/extensions/ReaderExperiments@master] Close overlay on escape

https://gerrit.wikimedia.org/r/1181672

Change #1181671 had a related patch set uploaded (by Marco Fossati; author: LWatson):

[mediawiki/extensions/ReaderExperiments@master] test: add test coverage for components and mock icons

https://gerrit.wikimedia.org/r/1181671

Change #1182161 had a related patch set uploaded (by Matthias Mullie; author: Matthias Mullie):

[mediawiki/extensions/ReaderExperiments@master] Use big image for full-screen, not thumb

https://gerrit.wikimedia.org/r/1182161

Change #1181003 merged by jenkins-bot:

[mediawiki/extensions/ReaderExperiments@master] ImageBrowsing: Extract new DetailViewControls component

https://gerrit.wikimedia.org/r/1181003

Change #1181794 merged by jenkins-bot:

[mediawiki/extensions/ReaderExperiments@master] ImageBrowsing: use real captions in DetailViewCaption and simplify props

https://gerrit.wikimedia.org/r/1181794

Change #1181671 merged by jenkins-bot:

[mediawiki/extensions/ReaderExperiments@master] test: add test coverage for components and mock icons

https://gerrit.wikimedia.org/r/1181671

Change #1182161 merged by jenkins-bot:

[mediawiki/extensions/ReaderExperiments@master] Use big image for full-screen, not thumb

https://gerrit.wikimedia.org/r/1182161

Gonna call this one done! We may QA it next sprint.