WordPress / better-code-editing

[✅ Merged into 4.9-alpha] Better Code Editing WordPress plugin
https://wordpress.org/plugins/better-code-editing/
37 stars 16 forks source link

?-help-button aria-expanded value #89

Closed samikeijonen closed 6 years ago

samikeijonen commented 6 years ago

In ?-help-button (Additional CSS section) there is aria-expanded="false". But it doesn't change to aria-expanded="true" when opened and back to aria-expanded="false" when closed.

samikeijonen commented 6 years ago

Also when help section is opened if the CSS is empty, value should be aria-expanded="true" at that point.

westonruter commented 6 years ago

@samikeijonen I think you may be looking at the wrong element. Look at .customize-section-description not .customize-pane-child.

Upon load Customizer:

image

Upon clicking Close:

image

Whether or not .customize-pane-child should be getting the same toggle of aria-expanded would be an issue for core.

samikeijonen commented 6 years ago

Ah ok, I try to open trac ticket for .customize-pane-child aria-expanded bug.

afercia commented 6 years ago

Haven't checked live, just looking at the screenshot above, seems to me aria-expanded on a not-focusable div won't do anything useful. The toggle button needs to reflect the expandable panel state it relates to.

samikeijonen commented 6 years ago

@westonruter Can you re-open this? When we checked ?-button in the Menu section for example, that button has correct aria-expanded="false" and aria-expanded="true" when toggling.

westonruter commented 6 years ago

@samikeijonen please open a new defect Trac ticket. I just merged this plugin into trunk.

afercia commented 6 years ago

@samikeijonen I'm working on a core patch which includes the aria-expanded fix, will update this comment adding the Trac ticket number when I'm done.

See https://core.trac.wordpress.org/ticket/41872

samikeijonen commented 6 years ago

Nice.