Page MenuHomePhabricator

PagePreviews settings dialog doesn't adjust position on resize/orientation change
Closed, ResolvedPublic3 Story Points


When user clicks settings cog in Page Preview we show nice dialog window that allows enable/disable PagePreviews feature.
This popup is centered vertically and horizontally but it doesn't reposition on window resize/orientation change.

Because settings popup has fixed width it's possible to hide popup by resizing window, after that there is no possibility to close
the modal as clicking overlay doesn't dismiss the popup. The only way to close the popup is to or resize it or refresh the page.

I'm able to reproduce this issue all browsers and some tablets [Galaxy Note 10.1 allows you to hover over link].

initial renderon resize


Related Gerrit Patches:
mediawiki/extensions/Popups : masterCentering settings dialog and overlay

Event Timeline

pmiazga created this task.Feb 2 2017, 7:25 PM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptFeb 2 2017, 7:25 PM
ovasileva triaged this task as Normal priority.Feb 3 2017, 2:02 PM
ovasileva moved this task from Incoming to Triaged but Future on the Readers-Web-Backlog board.
Restricted Application added a subscriber: TerraCodes. · View Herald TranscriptMar 8 2017, 7:33 PM
ovasileva set the point value for this task to 2.May 16 2017, 3:22 PM
Jdlrobson lowered the priority of this task from Normal to Low.Aug 17 2017, 2:40 PM
ovasileva raised the priority of this task from Low to Normal.Feb 6 2018, 5:26 PM
ovasileva changed the point value for this task from 2 to 3.
Jdrewniak updated the task description. (Show Details)Feb 6 2018, 7:07 PM

This should be blocked on T165036 which should hopefully make this a lot easier.

I think we can opt-in for a CSS only solution to this problem and avoid the dependancy on T165036.

Page previews is only enabled for Grade A browsers, which all support the flex-box layout model, which makes vertical/horizontal centring + resizing easy.

Using flex-box, this would largely avoid conflicts with T165036 as it would only require removing a few lines here and adding some CSS.

Change 410492 had a related patch set uploaded (by Jdrewniak; owner: Jdrewniak):
[mediawiki/extensions/Popups@master] Centering settings dialog and overlay

I'll review it today

Change 410492 merged by jenkins-bot:
[mediawiki/extensions/Popups@master] Centering settings dialog and overlay

ABorbaWMF added a subscriber: ABorbaWMF.

Looking good to me. Tried on on a number of different browsers. The popup is staying nice and centered.

ovasileva closed this task as Resolved.Feb 15 2018, 6:24 PM

Looks good to me