[wp-trac] [WordPress Trac] #43586: Minor UI adjustments to the Author box in the Edit Comment screen

WordPress Trac noreply at wordpress.org
Sun Jan 27 13:33:29 UTC 2019


#43586: Minor UI adjustments to the Author box in the Edit Comment screen
-------------------------------------+-------------------------------------
 Reporter:  birgire                  |       Owner:  pento
     Type:  enhancement              |      Status:  reopened
 Priority:  low                      |   Milestone:  5.1
Component:  Comments                 |     Version:
 Severity:  normal                   |  Resolution:
 Keywords:  has-screenshots needs-   |     Focuses:  ui, accessibility,
  patch                              |  administration
-------------------------------------+-------------------------------------
Changes (by afercia):

 * keywords:  ui-feedback has-screenshots good-first-bug has-patch => has-
     screenshots needs-patch
 * status:  closed => reopened
 * focuses:  ui, administration => ui, accessibility, administration
 * resolution:  fixed =>


Comment:

 Reopening this ticket because I've just realised [44466] removed a
 fieldset `legend` and changed it to a heading, thus introducing an
 accessibility regression. Noticed while investigating on #33361.

 The fieldset and legend elements were added in [32796] / #31326 with the
 specific goal to improve these form elements accessibility. It's always
 recommended to investigate a bit the code history to understand the
 reasons behind existing code.

 The "Author" box has now a `fieldset` without a `legend`. This doesn't
 help so much assistive technologies users because the form elements are
 logically grouped within the fieldset but there's nothing to communicate
 ''what'' the group is about.

 Regarding why a correct usage of fieldset and legend elements is
 important, I'd recommend this post by LĂ©onie Watson on the gov.uk blog:
 https://accessibility.blog.gov.uk/2016/07/22/using-the-fieldset-and-
 legend-elements/

 Also, the new heading is inside the fieldset and uses a `span` element,
 not sure why.

 See also this related comment:
 https://core.trac.wordpress.org/ticket/33361#comment:12

 I'd prefer to not enter into the debate if these are real meta boxes. I'd
 prefer to not use unnecessary headings too: headings should be used to
 identify content main sections, not for visual purposes. However, this
 change is in trunk and WordPress 5.1 is in Beta 2 phase so I'd suggest the
 most simple fix: use a visually hidden `legend` as already done in the
 "Status" box. It's a bit redundant, but it properly gives a name to the
 group of form elements.

 To clarify visually: here's the Author fieldsed in 5.0.3 (left) and in
 trunk 5.1 (right), unstyled to make the underlying HTML semantics visible:

 [[Image(http://cldup.com/EOZRN4xrKA.png)]]

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/43586#comment:25>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list