internetarchive / openlibrary

One webpage for every book ever published!
https://openlibrary.org
GNU Affero General Public License v3.0
5.13k stars 1.34k forks source link

Some librarian tools ignore browser accessibility settings #8363

Open seabelis opened 1 year ago

seabelis commented 1 year ago

Custom browser accessibility settings are ignored for some librarian tool interfaces.

I use a plug-in that uses a high-contrast color for followed links. These settings are applied to the main Open Library site, but ignored on the merge queue, for example.

It was mentioned on a community call that this is caused by the CSS in VUE.

Evidence / Screenshot (if possible)

Visited links with high-contrast applied: Screenshot 2023-10-04 at 09 08 17

Visited links ignoring high-contrast setting: Screenshot 2023-10-04 at 09 06 41

Relevant url?

Steps to Reproduce

  1. Go to ...
  2. Do ...

Details

Proposal & Constraints

Related files

Stakeholders

davidscotson commented 1 year ago

I can confirm this issue, using Firefox and an extension called

"visited-color-picker".

It is the ShadowDOM that's the cause of the issue, with global CSS not being applied unless it naturally inherits through (eg body text color and font family).

I believe that the use of the ShadowDOM is optional, and is a consequence of the use of web components to inject these Vue elements into OpenLibrary. When running the components in dev mode they're mounted without the use of web components and so have no shadow DOM. We should, in theory at least, be able to just mount them, as we have no need to embed them into content we don't control. The specific page cited above, the Merge UI is on a page by itself. But there may have been reasons for going the web component route, and it may be complicated to change that decision now.

mekarpeles commented 11 months ago

@davidscotson let's discuss on Tuesday with @cdrini and @mheiman!

github-actions[bot] commented 8 months ago

Assignees removed automatically after 14 days.