Comments

floydm’s picture

StatusFileSize
new81.23 KB

Just checking, the approach used in the Content table is correct? Invisible labels is the same div as the checkbox?

mgifford’s picture

Yup. That looks good. The for= needs to be associated with an id= with the same name.

http://wave.webaim.org/toolbar/ is a great tool for this type of simple evaluation.

floydm’s picture

Component: toolbar.module » user.module
Status: Active » Needs review
StatusFileSize
new436 bytes
new97.37 KB

The attached patch adds one line to user.admin.inc to add the invisible people admin labels.

User Admin Labels

The change is just adding

    $options[$account->uid]['title']['data']['#title'] = check_plain($account->name);

I believe the check_plain is appropriate there but I'm not certain.

mgifford’s picture

StatusFileSize
new26.36 KB

Awaiting the bot & check_plain() confirmation but it looks good to me. Assuming those come back good I'd say this is RTBC.

PeopleLabels.png

mgifford’s picture

mgifford’s picture

Status: Needs review » Reviewed & tested by the community

Just tested this again on SimplyTest.me and it's still working fine so marking it RTBC. It got lost in the issue queue.

Status: Reviewed & tested by the community » Needs work
Issue tags: -Accessibility

The last submitted patch, drupal-people_admin_add_missing_labels-1932068-3.patch, failed testing.

mgifford’s picture

Status: Needs work » Needs review
Issue tags: +Accessibility
mgifford’s picture

Status: Needs review » Reviewed & tested by the community

Ok, that last failure was due to the bot (and me not waiting to see if it would apply correctly).

Setting it back to RTBC.

xjm’s picture

Status: Reviewed & tested by the community » Needs work

The last submitted patch, drupal-people_admin_add_missing_labels-1932068-3.patch, failed testing.

mgifford’s picture

Status: Needs work » Needs review
Issue tags: +Accessibility
andymartha’s picture

Status: Needs review » Reviewed & tested by the community
StatusFileSize
new84.17 KB
new49.98 KB

On a fresh install of Drupal 8, I can confirm that the patch drupal-people_admin_add_missing_labels-1932068-3.patch by Floydm on #3 produces the label output seen in the screenshots below (before and after)
missinglabelsbefore1.png
missinglabelsafter2.png

alexpott’s picture

Status: Reviewed & tested by the community » Fixed

Committed de0cbdd and pushed to 8.x. Thanks!

berdir’s picture

Status: Fixed » Needs work

Hm, shouldn't this use $account->label(), which in turn invokes user_format_name()/hook_user_format_name_alter() just like theme('username'), so that in case of e.g. realname.module, the real name is displayed, just like in the name column which uses the theme function?

xjm’s picture

This entire table is being replaced in #1851086: Replace admin/people with a View, so it would be great if folks in this issue could help make sure these improvements are re-added over there.

alexpott’s picture

Re #15... interesting in light of #1929420: $account->getDisplayName() should be used when outputing username in RDF module ... should this actually be using user_format_name()

mgifford’s picture

Status: Needs work » Closed (fixed)
berdir’s picture

Status: Closed (fixed) » Needs work

This code is still in place in the non-views fallback implementation.

Which has a number of other weird issues, like not using load multiple and executing completely unneccesary queries to load user roles, see my changes to that function in #1751274: Do not query user_roles directly. I'm fine with creating a follow-up issue to clean up that function separately and fix this too. Could be a nice novice issue, do you have time to open one?

mgifford’s picture

Status: Needs work » Needs review
mgifford’s picture

Thanks @Berdir - so hopefully the patch from #3 still applies. user_admin_account() is still there, so should be fine.

Status: Needs review » Needs work

The last submitted patch, drupal-people_admin_add_missing_labels-1932068-3.patch, failed testing.

mgifford’s picture

The patch in #3 is already in Core, so that should address the non-views fallback, right?

berdir’s picture

Patch #3 is in core but is wrong, that's why I re-opened this issue. It should be check_plain($account->label())

mgifford’s picture

Status: Needs work » Needs review
StatusFileSize
new462 bytes

Well, here's a re-roll with that change.

mgifford’s picture

StatusFileSize
new214.16 KB

Now how do you test this? Trying to disable Views gives me:
Symfony\Component\Routing\Exception\RouteNotFoundException: Route "view.content.page_1"

Building up from a minimal install doesn't seem to give me the right interface either.

Ahh, but you can just disable the View for People in the Views interface, right... That gets me:

People without Views

But really no closer to finding this label.

berdir’s picture

Status: Needs review » Fixed

Oh, that's because there are no checkboxes on that table anymore of course, which makes this dead code. Let's really close this then and continue in #2037675: Clean-up user_admin_account()

Automatically closed -- issue fixed for 2 weeks with no activity.