Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use icons with text in admin table actions #4552

Merged
merged 5 commits into from
Jun 30, 2021
Merged

Conversation

javierm
Copy link
Member

@javierm javierm commented Jun 13, 2021

References

Objectives

  • Make it easier for users to understand which actions are available
  • Avoid usability and accessibility issues
  • Unify and simplify texts in admin actions
  • Increase the size and the space between icons so it's easier for users to click on / touch the icon they want

Visual Changes

Before these changes

The pages table shows a picture icon and an eye icon; the mouse cursor is over the eye icon and a "See page" tooltip is shown

The budgets table shows three icons: orange coins, a green chart pie, and a blue box

The hidden proposals table shows an arrow icon like the ones used in "undo" actions and a red flag icon

After these changes

The pages table shows the texts "Manage cards" below the picture icon and "View" below the eye icon

The budgets table shows the texts "Investment projects" below the coins, "Heading groups" below the chart pie, and "Ballots" below the box

The hidden proposals table shows the texts "Restore" below the "undo-like" arrow and "Confirm moderation" below the flag icon

Notes

For an explanation about the usability and accessibility issues related to tooltips, check the message in commit 25e9065.

@javierm javierm self-assigned this Jun 13, 2021
@javierm javierm added this to Reviewing in Consul Democracy via automation Jun 13, 2021
@javierm javierm force-pushed the table_icons_with_text branch 4 times, most recently from 312b4aa to f332faa Compare June 16, 2021 23:48
@Senen Senen self-assigned this Jun 28, 2021
@javierm javierm force-pushed the table_icons_with_text branch 4 times, most recently from d355dbe to 7e9d06e Compare June 29, 2021 18:09
Copy link
Member

@Senen Senen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi Javier, everything seems to work fine. I just found one thing. Let me know what do you think.

app/assets/stylesheets/notification_item.scss Show resolved Hide resolved
In commit 9794ffb, we replaced "buttons" with icons in order to make
the admin interface consistent with the planned budget investments
redesign.

However, using icons has some issues. For once, icons like a trash for
the "delete" action might be obvious, but other icons like "confirm
moderation" or "send pending" might be a bit confusing.

It's true that we were adding tooltips on hover. We tried two
approaches: using Foundation's tooltips and using CSS tooltips.

Foundation tooltips are not activated on focus (only on hover), while
CSS tooltips always appear below the icon, which might be a problem when
the icons are at the bottom of the screen (one of our milestone tests
was failing because of that and we can now run it with JavaScript
enabled).

Both Foundation and CSS tooltips have other issues:

* They force users to make an extra step and move the mouse over the
  link just to know what the link is about
* They aren't available on touch screens, so these users will have to
  memorize what each icon does
* They are not hoverable, and making them hoverable would cause a
  different issue because the tooltip might cover links below it, making
  it impossible to click these links without moving the mouse away
  first
* They are not dismissable, which is considered an accessibility issue
  and a requirement in the Web Content Accessibility Guidelines [1]

For all these reasons, we're using both texts and icons. As Thomas
Byttebier said "The best icon is a text label [2]". Heydon Pickering
also makes a point towards providing text alongside icons in his book
"Inclusive Components" [3].

Note that, since we're now adding text and some of the colors we use for
actions are hard to read against a white/gray background, we're making a
few colors darker.

With these changes, actions take more space in the admin table compared
to the space they took in version 1.3, but they are more usable and
accessible while they still take less space than they did in version
1.2.

[1] https://www.w3.org/WAI/WCAG21/Understanding/content-on-hover-or-focus
[2] https://thomasbyttebier.be/blog/the-best-icon-is-a-text-label
[3] https://inclusive-components.design/tooltips-toggletips/
When we see a list of, let's say, banners, and each one has a link to
edit them, the word "banner" in the text "edit banner" is redundant and
adds noise; even for users with cognitive disabilities, it's obvious
that the "edit" link refers to the banner.
We use the words "Manage" and "View" in other places; we don't use the
word "See" as often.
The word "budget" in the "Preview budget" link is redundant.

On the other hand, the words "Manage", Edit" and "Admin" are not
really necessary in my humble opinion. Just like in the admin
navigation menu we use "Participatory budgets" instead of "Manage
Participatory budgets", the fact that we're going to manage or
admin or edit something can be deduced from the fact that we're in
the admin section.

Besides, it isn't clear to me why we use "Manage" for projects,
"Edit" for heading groups and "Admin" for ballots. The differences
between these three concepts might be too subtle for me.

The previous paragraphs haven't been corroborated with real users,
though, so I might be mistaken and we might need to revisit these
links in the future.

These actions still take quite a lot of space. Maybe in the future we
could remove the "delete" icon, at least on budgets which cannot be
deleted.
@javierm javierm force-pushed the table_icons_with_text branch 2 times, most recently from 3008ca4 to f5a0e09 Compare June 30, 2021 12:46
We were removing the margin half of the time, and sometimes removing it
made us use `!important` rules.
Consul Democracy automation moved this from Reviewing to Testing Jun 30, 2021
@javierm javierm merged commit 58d123a into master Jun 30, 2021
@javierm javierm deleted the table_icons_with_text branch June 30, 2021 14:31
Consul Democracy automation moved this from Testing to Release 1.4.0 Jun 30, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants