NPM Resource Changed ? ? ? Failure

User tests: Successful: Unsuccessful:

avatar brianteeman
brianteeman
3 Apr 2019

Pull Request for Issue #20986

Summary of Changes

replace the custom element for the switcher field with pure css and accessible
it uses a legend to describe the fieldset and the label for the values as normal

Testing Instructions

Requires npm i

  • Component options
  • Module such as breadcrumbs
  • featured switch on article edit

Expected result

Visual

bread

Notes

  1. The scss file isnt really scss - needs an expert eye to rewrite it
  2. No RTL support - hopefully whoever fixes 1. will do that
avatar brianteeman brianteeman - open - 3 Apr 2019
avatar brianteeman brianteeman - change - 3 Apr 2019
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 3 Apr 2019
Category Layout Libraries
avatar brianteeman brianteeman - change - 3 Apr 2019
Labels Added: ?
avatar franz-wohlkoenig
franz-wohlkoenig - comment - 3 Apr 2019

I have tested this item successfully on 6f96df0 using Module.

System information

Setting Value
PHP Built On Linux lamp122.cloudaccess.net 3.10.0-962.3.2.lve1.5.24.7.el6h.x86_64 nr.1 SMP Mon Dec 17 12:02:35 EST 2018 x86_64
Database Type mysql
Database Version 5.7.24-cll-lve
Database Collation utf8_general_ci
Database Connection Collation utf8_general_ci
PHP Version 7.1.26
Web Server Apache
WebServer to PHP Interface cgi-fcgi
Joomla! Version Latest Nightly Build Update from Joomla! 4.0.0-alpha8-dev Development [ Amani ] 9-March-2019 13:41 GMT
User Agent Mozilla/5.0 (Macintosh; Intel Mac OS X 10.13; rv:66.0) Gecko/20100101 Firefox/66.0

This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/24463.
avatar franz-wohlkoenig
franz-wohlkoenig - comment - 3 Apr 2019

I have tested this item successfully on 6f96df0


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/24463.

avatar franz-wohlkoenig franz-wohlkoenig - test_item - 3 Apr 2019 - Tested successfully
avatar Bakual
Bakual - comment - 3 Apr 2019

As for the final location for the CSS file, I'd put it into https://github.com/joomla/joomla-cms/tree/4.0-dev/build/media_source/system/css/fields which ends up in /media/system/css/fields after building.
This way it can be overriden by the template if they choose so.

avatar brianteeman
brianteeman - comment - 3 Apr 2019

@Bakual thanks that is what I was thinking too OR as scss to be compiled into the templates

avatar zwiastunsw
zwiastunsw - comment - 4 Apr 2019
  1. Keyboard support OK
  2. This is incomprehensible to me. In the context of the tested page on Joomla Backend, the screen reader (NVDA inc Chrome)
  • does not announce a switch label. Announces only states (Show, Hide),
  • treats all buttons as if it were one group of buttons and announces their status, e.g.

Show radio button checked 1 of 8
Hide radio button checked 4 od 8

instead:

Show radio button checked 1 of 2
Hide radio button checked 2 od 2

When I copy the source code of a page and read it outside the context of the backend (as a separate document), the screen reader correctly reads the label of each switch and its status. (Do not load any js then.)

Firefox test: switches do not receive keyboard focus at all
Can anyone confirm this?

avatar brianteeman
brianteeman - comment - 4 Apr 2019

Which exact page. Maybe there is a markup bug somewhere

avatar brianteeman
brianteeman - comment - 4 Apr 2019

I "think" I know what the problem is. It's not the code here. But could you please tell me the page you tested so I can confirm

avatar brianteeman
brianteeman - comment - 4 Apr 2019

@zwiastunsw I think it could be because the fieldsets are nested inside other fieldsets https://test-cases.tink.uk/nested-fieldsets/index.html

avatar brianteeman
brianteeman - comment - 4 Apr 2019

@zwiastunsw if that is the problem then we can use an alternative method instead of fieldset which is to use role=group

avatar zwiastunsw
zwiastunsw - comment - 4 Apr 2019

I tested Site Modules > Breadcrumbs.
Windows 10, Chrome v. 73.0.3683.86 (64 bit).

avatar brianteeman
brianteeman - comment - 6 Apr 2019

@zwiastunsw I am going to have to reach out to some external a11y experts on this. As you discovered the code works perfectly on a plain html page but not within joomla. I cant see anything in joomla that would break it.

avatar franz-wohlkoenig franz-wohlkoenig - change - 19 Apr 2019
Title
[4.0] [a11y] Switcher Field Proof of Concept
[4.0] Switcher Field Proof of Concept
avatar franz-wohlkoenig franz-wohlkoenig - edited - 19 Apr 2019
avatar brianteeman
brianteeman - comment - 23 Apr 2019

@zwiastunsw @wilsonge I found the problem. It is NOT in the code here. The problem is in the tabs code. When you open a module for the first time ALL the sections are set with aria-hidden=true. The first tab should not be

image

e2a5fe1 23 Apr 2019 avatar brianteeman css
6c752c7 23 Apr 2019 avatar brianteeman css
avatar brianteeman brianteeman - change - 23 Apr 2019
Labels Added: ?
Removed: J4 Issue
avatar wilsonge wilsonge - change - 23 Apr 2019
Labels Added: ?
Removed: ?
avatar brianteeman brianteeman - change - 25 Apr 2019
Labels Added: ?
Removed: ?
avatar jeckodevelopment jeckodevelopment - change - 26 Apr 2019
Labels Added: ?
Removed: ?
avatar brianteeman
brianteeman - comment - 26 Apr 2019

@jeckodevelopment why did you update the branch? It doesn't have any purpose and forces my local branch to be out of date

avatar jeckodevelopment
jeckodevelopment - comment - 26 Apr 2019

merge button was not available due to the branch being out of sync

avatar brianteeman
brianteeman - comment - 26 Apr 2019

@jeckodevelopment that is only relevant for the person who does the merge . it doesnt need to be done repeatedly. it has no impact on the ability to test the pr as long as there are no conflicts. All it does is waste your time pressing the button and my time updating my local branch

avatar wilsonge
wilsonge - comment - 26 Apr 2019

Let's chill :)

Is this now working from a screenreader perspective? @zwiastunsw

avatar brianteeman
brianteeman - comment - 26 Apr 2019

I'm chilled

avatar brianteeman
brianteeman - comment - 28 Apr 2019

@wilsonge Shall I go ahead and update this PR to use correct paths etc so that it can be merged?

avatar wilsonge
wilsonge - comment - 28 Apr 2019

Go for it

avatar brianteeman brianteeman - change - 29 Apr 2019
Labels Added: ?
Removed: ?
avatar brianteeman brianteeman - change - 29 Apr 2019
Labels Added: ?
Removed: ?
avatar joomla-cms-bot joomla-cms-bot - change - 29 Apr 2019
Category Layout Libraries Repository NPM Change Layout Libraries
avatar brianteeman brianteeman - change - 29 Apr 2019
Labels Added: NPM Resource Changed ?
Removed: ?
avatar joomla-cms-bot joomla-cms-bot - change - 29 Apr 2019
Category Layout Libraries Repository NPM Change Administration Templates (admin) Repository NPM Change JavaScript Layout Libraries Front End Templates (site)
avatar brianteeman brianteeman - change - 29 Apr 2019
Title
[4.0] Switcher Field Proof of Concept
[4.0] Switcher Field [a11y]
avatar brianteeman brianteeman - edited - 29 Apr 2019
avatar brianteeman brianteeman - change - 29 Apr 2019
The description was changed
avatar brianteeman brianteeman - edited - 29 Apr 2019
avatar brianteeman
brianteeman - comment - 29 Apr 2019

Updated code and original post with test instructions

avatar brianteeman brianteeman - change - 29 Apr 2019
The description was changed
avatar brianteeman brianteeman - edited - 29 Apr 2019
4cd854e 29 Apr 2019 avatar brianteeman cs
avatar brianteeman brianteeman - change - 29 Apr 2019
Labels Added: ?
Removed: ?
190fafe 29 Apr 2019 avatar brianteeman cs
avatar brianteeman
brianteeman - comment - 29 Apr 2019

The js tests are failing as expected as the js is no longer present. Should I remove the tests in this pr?

avatar franz-wohlkoenig franz-wohlkoenig - change - 30 Apr 2019
Title
[4.0] Switcher Field [a11y]
[4.0] Switcher Field
avatar franz-wohlkoenig franz-wohlkoenig - edited - 30 Apr 2019
avatar brianteeman brianteeman - change - 30 Apr 2019
Labels Added: ?
Removed: ?
avatar brianteeman
brianteeman - comment - 30 Apr 2019

tests removed

avatar joomla-cms-bot joomla-cms-bot - change - 30 Apr 2019
Category Layout Libraries Repository NPM Change Administration Templates (admin) JavaScript Front End Templates (site) Administration Templates (admin) Repository NPM Change JavaScript Layout Libraries Front End Templates (site) Unit Tests
avatar brianteeman brianteeman - change - 30 Apr 2019
Labels Added: ?
avatar brianteeman brianteeman - change - 30 Apr 2019
Labels Added: ?
Removed: ?
avatar wilsonge wilsonge - change - 30 Apr 2019
Labels Added: ?
Removed: ?
avatar wilsonge wilsonge - change - 30 Apr 2019
Labels Added: ?
Removed: ?
avatar wilsonge wilsonge - change - 4 May 2019
Status Pending Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2019-05-04 16:41:59
Closed_By wilsonge
Labels Added: ?
Removed: ?
avatar wilsonge wilsonge - close - 4 May 2019
avatar wilsonge wilsonge - merge - 4 May 2019
avatar wilsonge
wilsonge - comment - 4 May 2019

Thanks!

avatar brianteeman
brianteeman - comment - 4 May 2019

Woohoo

Add a Comment

Login with GitHub to post a comment