Page MenuHomePhabricator

Clicking image on-wiki triggers MediaViewer
Open, Needs TriagePublic

Description

An image click on-wiki should trigger MediaViewer according to user's preferences, if possible.

Event Timeline

Dominicbm changed the task status from Open to In Progress.Jan 23 2023, 7:13 PM
Dominicbm moved this task from Backlog to In Progress on the View-it! board.

To get this to work, we would probably have to re-initialize MediaViewer after View it!'s carousel has loaded. I've done some investigating, and also got some guidance from @Tgr.

The entire page could be entirely re-initialized using a wikipage.content hook. We may also be able to process individual images using mw.mmv.bootstrap.processThumbs($container).

The real messy part is that MediaViewer only processes images in a thumbnail format. There have been attempts in the past (e.g. this script) to re-initialize MediaViewer after initial page load; in this script, they create dummy thumbnails for use by MediaViewer.

This sounds possible to implement, albeit with messy code and unclear side effects.

Might be easier to go the other way around and add a clean API to MediaViewer. That would be T59298: The viewer box should not depend on the current page.

Aklapper changed the task status from In Progress to Open.Mar 19 2025, 2:48 PM
Aklapper subscribed.

Resetting task status from "In Progress" to "Open" as this task has not seen updates for two years.

Aklapper added a subscriber: SuperHamster.

@SuperHamster: Removing task assignee as this open task has been assigned for more than two years - See the email sent on 2025-05-22.
Please assign this task to yourself again if you still realistically [plan to] work on this task - it would be welcome!
If this task has been resolved in the meantime, or should not be worked on by anybody ("declined"), please update its task status via "Add Action… 🡒 Change Status".
Also see https://www.mediawiki.org/wiki/Bug_management/Assignee_cleanup for tips how to best manage your individual work in Phabricator. Thanks!