Page MenuHomePhabricator

Bug Bash: The Sequel- 2 Old 2 Browsers
Closed, ResolvedPublic2 Estimated Story Points

Description

image.png (1×1 px, 3 MB)

(obligatory movie poster)

Background

Over at T405992 (our "bug bash" pre-flight task) we sought to identify and eliminate any bugs impacting current-generation browsers. In the course of that exploration we also identified some issues which impact various older browsers (particularly iOS Safari). Let's collect any issues we find here so we can try to address them.

Because this feature is just a prototype with a very limited roll-out, we may not commit to fixing all of the bugs which are identified here (at least not at this point in time). Instead, we may take measures to exclude certain older browser (even ones that might technically meet the "Grade A" requirements) in order to ship our prototype on time. If we decide to scale this feature for wider use, we would want to come back and address any significant issues.

However, if we find that we need to exclude a significant sub-set of traffic due to browser incompatibility, we may also need to somehow signal this in the analytics data we are collecting (which will be used to evaluate our prototype). We don't want "false negatives" to interfere with our metrics.

Requirements
  • Add legacy-browser-specific issues in the list below (ideally with screenshots and/or steps to repro) – please include device and browser version
  • Check how prevalent the impacted browser versions are in our traffic (see this dashboard for data)
  • Determine a browser support policy for the ImageBrowsing prototype (what if any Grade A browsers will we exclude from seeing this feature?)
  • Implement additional "gating" measures on the client to exclude any browsers we decide we won't serve for the current experiment
    • If we do this, we may also need to ensure that we can represent this exclusion in our analytics data somehow (log a new event for this that we can filter out?)
      • Note: RG team discussed gating the feature to exclude unsupported browsers and not worrying about excluding that data from analytics for now.
Findings

After applying fixes from T406377: Image Browsing: iOS 12, 15 have CORS failures if wiki is on HTTP, Safari on iOS 12 doesn't seem to grok the styling we're doing on the image or placeholder icon in the detail view. The whole things end up not fully screen height and the image is either missing or only partly displays.

In theory MediaWiki's "grade A" browser support still goes back to iOS 11.3 as of last November: https://www.mediawiki.org/wiki/Compatibility#Grade_A

Within the range of supported versions I have test devices for last patchlevel on iOS 12, 15, 16, and 18 but no 11s so don't know if there's any other snags there.

Screenshots of the first two selected images on [[Grand Canyon]]:

IMG_0005.PNG (1×640 px, 336 KB)
IMG_0006.PNG (1×640 px, 470 KB)

iPad mini 2, iOS 12.5.7

Example: black and white image in the Barbie article (wiki/Barbie?imageBrowsing=1&useskin=minerva#/imagebrowsing/File:Charlotte_Johnson_with_1965_Barbie_doll.jpg)

IMG_5320.jpg (4×3 px, 1 MB)

Issues List
  • DetailView height should be full viewport height.
    • DetailView image should be visible.
    • DetailView control buttons should not overlap each other.
    • DetailView caption text should be positioned at the bottom of the image.
    • Problem: dynamic viewport height (dvh) browser compatibility https://developer.mozilla.org/en-US/docs/Web/CSS/length#browser_compatibility.
    • Solution: Use viewport height (vh) for legacy browsers, and expect the DetailView content to overflow the viewport.
  • DetailView caption background image uses a linear gradient with --dominant-color-hex color, but the value always appears to be #000000.
    • Note: this may be the CORS on iOS issues (15 is fixed; 12 is not)
  • DetailView caption text and more/less button label should be --dominant-color-contrasting color, not color-base.
  • DetailView caption links should be dominant-color-contrasting color, not blue links.
  • VTOC 2-column grid items should use a custom style 2-column grid for legacy browsers.
    • Problem: Resize Observer browser compatibility https://developer.mozilla.org/en-US/docs/Web/API/ResizeObserver#browser_compatibility. There was an issue calculating the height, which uses ResizeObserver and resulted in grid-row-end: span NaN in unsupported browsers.
    • Solution: Check whether Resize Observer is supported and then apply custom VTOC grid styles. If it's supported, then apply the grid-row-end style and grid-auto-rows: 10px for "masonry" tile grid. If it's not supported, then use a simpler custom grid style (grid-auto-rows: auto).
  • iOS 15 has CORS failures if wiki is on HTTP (merged from T406377)
  • iOS 12 has CORS failures (merged from T406377)
    • Note: iOS 12 CORS errors are unresolved, and RG team decided to exlcude iOS 14 and below from the prototype's browser policy.

Event Timeline

There are a very large number of changes, so older changes are hidden. Show Older Changes
ovasileva triaged this task as Lowest priority.Oct 8 2025, 2:22 PM
ovasileva raised the priority of this task from Lowest to Low.
ovasileva moved this task from Incoming/Inbox to Needs Refinement on the Reader Growth Team board.
HSwan-WMF renamed this task from Image Browsing: detail view image mis-styled in iOS 12 to Bug Bash: The Sequel- 2 Old 2 Browsers.Oct 8 2025, 5:01 PM
HSwan-WMF updated the task description. (Show Details)
ovasileva raised the priority of this task from Low to Medium.Oct 9 2025, 8:27 AM

Change #1194638 had a related patch set uploaded (by LWatson; author: LWatson):

[mediawiki/extensions/ReaderExperiments@master] ImageBrowsing: add legacy browser support

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

Change #1195066 had a related patch set uploaded (by Bvibber; author: Bvibber):

[mediawiki/extensions/ReaderExperiments@master] Image Browsing: fix background and canvas calculations on iOS 12

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

Change #1195074 had a related patch set uploaded (by Bvibber; author: Bvibber):

[mediawiki/extensions/ReaderExperiments@master] Simplify text color style to work on iOS 12 Safari

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

ovasileva raised the priority of this task from Medium to High.Oct 10 2025, 3:05 PM
egardner set the point value for this task to 3.Oct 14 2025, 4:56 PM

Change #1194638 merged by jenkins-bot:

[mediawiki/extensions/ReaderExperiments@master] ImageBrowsing: add legacy browser support

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

Hey @bvibber, I've updated your open patches for the DetailView text color and background image to support legacy browsers.

Regarding the oklch color in this patch, we've explored these approaches so far:

  1. Simplified approach: Remove oklch entirely and use black or white colors for all browsers.
  2. Progressive enhancement: Maintain oklch in modern browsers that support the CSS feature, with a fallback for legacy browsers that uses black or white colors.

Let me know if you have other suggestions

[DRAFT] Recommended browser support policy

The ImageBrowsing prototype supports all Grade A browsers (as defined by Mediwiki's Compatibility policy) with the following exception:

Exclude iOS 12 (and potentially iOS 11-14) from ImageBrowsing access if CORS and other issues cannot be resolved efficiently.

Rationale

Traffic impact is insufficient

  • iOS 11-14 combined represent <0.1% to ~0.4% of total traffic (each <0.1%)
  • iOS 15 is 0.40% of traffic

Focus resources where they matter

  • iOS 18 alone is 25% of traffic (86% of all iOS traffic)
  • iOS 16-18 combined represent ~27% of total traffic (93% of iOS traffic)
  • Testing has already covered iOS 15-18, which captures the majority of iOS users.

Risk Mitigation

  • Implemented fallback behavior for known compatibility issues.
  • CORS issues in iOS 12 (and possibly 15) are unresolved and could cause a poor user experience.
  • Limited testing means other issues may surface in production.

Note: Browser traffic data mentioned is from dashiki

Next Steps
  • Discuss excluding iOS 11-14 from the ImageBrowsing prototype.
  • Monitor iOS 15, given its 0.40% traffic and potential CORS issues.
  • Prioritize QA testing
    • High priority: Android 10 (30% traffic), Windows 10 (22% traffic), and macOS X 10 (7.8% traffic). Also note that Android represents 34% of the traffic, Windows represents 25%, and macOS X is 8.1%.
    • Medium priority: iOS 15 and above, and current macOS
      • Also include: Android 6-9, Chrome ~96-98+ released Jan 2022 (ref), Edge 96.0.1054+ released Jan 2022 (ref), Firefox 96+ released Jan 2022 (ref)
    • Low priority: iOS 11-14 (already leaning toward exclusion)
  • Document the policy somewhere

Hey @bvibber, I've updated your open patches for the DetailView text color and background image to support legacy browsers.

Regarding the oklch color in this patch, we've explored these approaches so far:

  1. Simplified approach: Remove oklch entirely and use black or white colors for all browsers.
  2. Progressive enhancement: Maintain oklch in modern browsers that support the CSS feature, with a fallback for legacy browsers that uses black or white colors.

@lwatson: let's stick to progressive enhancement -- I was under the mistaken impression that in oklab colorspace L=1 would always be pure white, but it can actually be a bright color of any hue/saturation! For instance we end up with nice colored-but-still-bright text on dark but colorful backgrounds, so let's keep using that when possible:

image.png (1×820 px, 1 MB)

Change #1196692 had a related patch set uploaded (by LWatson; author: LWatson):

[mediawiki/extensions/ReaderExperiments@master] [WIP] ImageBrowsing: gate the feature to supported browsers

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

Current state of oklch workaround looks good; I feel like I should code review everybody's modifications to it but it feels wrong to +2 my own patch ;)

With a darker background and a light contrasting color, iOS 15 now sees the legacy fallback text color (white) while modern iOS 26 sees a light blue:

image.png (1×1 px, 3 MB)

With a lighter background both end up with black text, as expected:

image.png (1×1 px, 3 MB)

@bvibber, I +1 the oklch patch and hesitated to +2 since I've uploaded changes to it.

Change #1195066 merged by jenkins-bot:

[mediawiki/extensions/ReaderExperiments@master] WIP: ImageBrowsing: fix background and canvas calculations on iOS 12

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

Change #1195074 merged by jenkins-bot:

[mediawiki/extensions/ReaderExperiments@master] ImageBrowsing: simplify text color style to work on iOS 12 Safari

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

QA plan

Handoff to QA @Edtadros for browser testing.

We want to ensure that:

  1. The Image Browsing prototype loads with no browser console errors.
  2. The prototype is properly gated and does not display in unsupported browsers (iOS 14 and below, Android 9 and below)

Known issue: We've noted CORS errors on iOS 12 and expect issues in low priority browsers.

Browser priority list

  • High priority (Grade A, high traffic):
    • Android 10 and above
    • iOS 15 and above
    • Windows 10 and above
    • macOS X 10 and above
  • Low priority (Grade A, low traffic):
    • Android 6-9
    • iOS 11-14

Testing instructions

Part 1: Verify prototype functionality (Beta)

Steps:

  1. Navigate to a wiki page on beta with the following URL params that enable image browsing and minerva skin: https://en.wikipedia.beta.wmcloud.org/wiki/Berlin?imageBrowsing=true&useskin=minerva
  2. The image browsing prototype should be visible under the article title.

QA checks:

  • Verify that there are no errors in the browser console, specifically CORS-related errors.
  • Verify that images load and UI is as expected:
    • Carousel is visible and images load
    • Clicking an image in the Carousel opens the overlay
    • DetailView is full viewport height
    • DetailView caption text is positioned at the bottom of the image
    • DetailView caption's background image uses a linear gradient with --dominant-color-hex color
    • DetailView caption text (including links) and more/less button label is --dominant-color-contrasting color
    • When a VTOC 2-column grid is present on tablets and desktops, each grid item's contents (image, text, and "view in article" button) are visible, readable, and clickable. Grid items have borders that separate them from adjacent items. Content does not overlap.
    • Clicking on the VTOC image updates the DetailView image.
Part 2: Verify browser gating (patchdemo)

Note: Patch 1196692 gates the prototype based on the proposed browser policy and is currently unmerged. Use patchdemo for this testing: https://0ef72158a9.catalyst.wmcloud.org/wiki/Breadfruit?imageBrowsing=true&useskin=minerva

QA checks:

  • Verify the prototype is not displayed in iOS 14 and below.
  • Verify the prototype is not displayed in Android 9 and below.
lwatson updated the task description. (Show Details)
lwatson updated Other Assignee, added: bvibber.

Prototype’s browser support policy

The ImageBrowsing prototype supports all Grade A browsers (as defined by MediaWiki's Compatibility policy) with the following exceptions:

  • Android 9 and below
  • iOS 14 and below
Rationale

Minimal traffic impact

  • iOS 14 and below represent about 0.48% of total traffic.
  • Android 9 and below represent about 1.18% of total traffic.
  • Combined exclusion affects ~1.66% of users.

Risk mitigation

  • Implemented fallback behavior for known browser compatibility issues.
  • Unresolved CORS issues in iOS 12 (and potentially other older versions) could cause a poor user experience.
  • Limited testing coverage means that additional issues may surface in production for older browsers.
  • Engineering effort required to support older browser versions outweighs the minimal user benefit and is out of scope for this prototype.

Note: Browser traffic data is from dashiki (OS family and major hierarchical view from Oct 1, 2024 to Oct 21, 2025)

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

https://0ef72158a9.catalyst.wmcloud.org/w/

In standup, we discussed QA testing priorities and decided that browser compatibility testing is a lower priority compared to the accessibility audit. Given time and resource constraints, the alternative approach would be to test browser compatibility in production instead.
cc: @Edtadros

Change #1196692 merged by jenkins-bot:

[mediawiki/extensions/ReaderExperiments@master] ImageBrowsing: gate the feature to exclude unsupported browsers

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

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

Test Result - Beta

Status: ❌ FAIL
Environment: beta/patchdemo
OS: macOS Tahoe 26x
Browser: Chrome Canary (latest as of test date)
Device: MS
Emulated Device: NA

Test Case 1: Verify prototype functionality on supported browsers (Beta)

  1. Navigate to https://en.wikipedia.beta.wmcloud.org/wiki/Berlin?imageBrowsing=true&useskin=minerva
  2. Open console and verify there are no JavaScript or CORS-related errors
  3. AC1: Carousel is visible beneath the article title
  4. AC2: Clicking an image opens the overlay correctly
  5. AC3: DetailView fills the full viewport height
  6. AC4: DetailView caption text is positioned at the bottom of the image
  7. AC5: DetailView caption background uses linear gradient with --dominant-color-hex
  8. AC6: Caption text, links, and “more/less” button label use --dominant-color-contrasting
  9. AC7: VTOC 2-column grid displays correctly on tablets/desktops (images, text, and buttons visible and clickable)
  10. AC8: Grid items have borders separating them and no overlapping content
  11. AC9: Clicking a VTOC image updates the DetailView image
  12. AC10: No CORS or loading issues occur on iOS 15+, Android 10+, macOS, or Windows browsers

High priority (Grade A, high traffic):

Android 10 +iOS 15 +Windows 10 +**macOS X 10 +
screenshot 132.mov.gif (1×1 px, 3 MB)
screenshot 135.mov.gif (1×1 px, 1 MB)
[Error] Unable to get image data from canvas because the canvas has been tainted by cross-origin data.
screenshot 136.mov.gif (1×1 px, 3 MB)
Chrome 141 Windows 10
screenshot 137.mov.gif (942×1 px, 2 MB)
macOS Tahoe Safari 26 [Error] Unable to get image data from canvas because the canvas has been tainted by cross-origin data.

Test Case 2: Verify browser gating (Patchdemo)

  1. Navigate to https://aed540ecbc.catalyst.wmcloud.org/wiki/Breadfruit?imageBrowsing=true&useskin=minerva on devices/emulators
  2. Test iOS 14 and below
  3. Test Android 9 and below
  4. AC11: Prototype does not display on iOS 14−
  5. AC12: Prototype does not display on Android 9−
  6. AC13: No console or network errors occur when prototype is gated
  7. AC14: Gating behavior does not affect overall article rendering or cause layout issues

Low priority (Grade A, low traffic):

Android 6-9iOS 11-14
screenshot 315.png (1×1 px, 582 KB)
screenshot 318.png (1×1 px, 433 KB)
ovasileva lowered the priority of this task from High to Medium.Oct 28 2025, 4:21 PM
ovasileva changed the point value for this task from 3 to 2.
ovasileva lowered the priority of this task from Medium to Low.Oct 28 2025, 4:59 PM

Change #1200184 had a related patch set uploaded (by Bvibber; author: Bvibber):

[mediawiki/extensions/ReaderExperiments@master] Remove broken thumb load optimization

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

  1. AC10: No CORS or loading issues occur on iOS 15+, Android 10+, macOS, or Windows browsers

This should be harmless but annoying spam of the error log; *should* be fixed by patch on https://gerrit.wikimedia.org/r/1200184 but I can't confirm on my http localhost without it getting complainy about other things.

Change #1200184 merged by jenkins-bot:

[mediawiki/extensions/ReaderExperiments@master] Remove broken thumb load optimization

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

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

https://aed540ecbc.catalyst.wmcloud.org/w/