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

Add keyboard shortcuts à la Slack to jump through the main UI sections #467

Closed
afercia opened this issue Apr 20, 2017 · 31 comments · Fixed by #3084
Closed

Add keyboard shortcuts à la Slack to jump through the main UI sections #467

afercia opened this issue Apr 20, 2017 · 31 comments · Fixed by #3084
Assignees
Labels
[Focus] Accessibility (a11y) Changes that impact accessibility and need corresponding review (e.g. markup changes).
Milestone

Comments

@afercia
Copy link
Contributor

afercia commented Apr 20, 2017

Reference: looking at the screenshot posted on Slack on https://wordpress.slack.com/archives/C02QB2JS7/p1492621873449513

The toolbar:

screen shot 2017-04-19 at 19 07 00

The order and logical grouping of controls/links/info is fundamental for accessibility, and also usability. There are many things to consider here, will try to highlight some general issues.

The Publish button:
The Editor experience should be a type type type experience. For accessibility, add to that some tab tab tab experience. 🙂 Keyboard users and screen reader users will expect the Publish button to be after the editing area. That's the convention for any form. Placing it before the editing area would repeat the same mistake done in the Customizer with the "Save" button. Forcing users to tab backwards or explore the content to find the Publish button would be extremely confusing and annoying.
For keyboard and screen reader users, navigating content is a linearized experience that follows the order of elements in the markup. So the Publish button should come after the editor in the markup.
Worth also noting that the WCAG state the visual order should match the tab order.
I'd say this is also an usability issue, since the logical workflow when editing a post is:
Enter the title > Enter the content > Publish

The other controls/info etc:
The position of the other controls should be carefully considered too. Probably some of them can be placed before the editor. However, the most important thing here is they should be logically grouped.
I know this is just a first implementation and many things are probably temporary, but worth considering that currently these controls are a bit mixed up and there's no a clear, logical grouping.
Trying to list their different purposes:

1: action related to the editing tool:      switch the Editor's mode
2: info related to the editing state:       Saved (not sure if it's meant for other purposes too)
3: action related to the editing flow:      undo/redo
4: action related to the editing tool/flow: a "Plus" thing, I guess to show additional editing controls
5: link related to the editing state:       preview the post
6: action related to the editing tool/flow: control to expand the Post Settings
7: action related to the editing flow:      Publish button

I may be wrong on some of them 🙂 but my goal here is to highlight they have a different nature and purpose, so they should be grouped accordingly. Off the top of my head, a possible grouping could be:

  1. actions that do something to the content (undo, redo, etc.)
  2. actions that do something to the editing tool (showing additional controls, switching mode, etc.)
  3. things that show the post state (Saved, Preview, etc.)
  4. the Publish button is a special case (see above)

I'd say the group 1. should be placed as close as possible to the content, in a place that's very easy to reach when tabbing. These are controls that get used often while editing content so reaching them should require a minimal effort.

Groups 2. and 3. are probably going to be used not so often as the first group. I'm curious about the plus "+" control though, since it's a bit unclear what it will reveal when pressed. Same for the "Post Settings".

Some of the issues about "what's around the Editor" were discussed also on https://core.trac.wordpress.org/ticket/29838 where one of things considered was to remove anything that comes before the editor and place it elsewhere. This is especially true when it comes to mobile devices. I'd recommend everyone to follow the links in the ticket and watch the videos / read the posts by Mark Jaquith and Ryan Boren.

Additional considerations:

  • where's the "Add Media" button?
  • where's a space dedicated to plugins that add their custom buttons? (usually, they add them after the "Add Media" one)
@afercia afercia added [Focus] Accessibility (a11y) Changes that impact accessibility and need corresponding review (e.g. markup changes). Design labels Apr 20, 2017
@afercia
Copy link
Contributor Author

afercia commented Apr 20, 2017

OK the last two points are a bit more clear now that I had the opportunity to have a look at more mockups on https://wpcoredesign.mystagingwebsite.com/gutenberg/ 🙂
Any plans for the "Help" tab? (I guess the Screen Options one will go away).

@jasmussen
Copy link
Contributor

Good list, thank you.

Keyboard users and screen reader users will expect the Publish button to be after the editing area

Just to confirm, this relates to the markup, correct? Thankfully since we're exploring absolute and fixed position for this, it should be no trouble to move the toolbar markup below the editor content markup.

Incidentally as I'm typing this, @afercia confirmed that yes, it was markup specific in chat.

Worth also noting that the WCAG state the visual order should match the tab order.

Visually the publish button won't be changing its location from the old editor. It's still in the top right corner.

The other controls/info etc:

Here's a blueprint of the design:

The action buttons are Undo, Redo, Insert.

The editor toggles are preview and post settings, the latter which opens the sidebar. The sidebar is visible by default, by the way.

where's a space dedicated to plugins that add their custom buttons? (usually, they add them after the "Add Media" one)

This would still be after the "Add Media" one, in the top. Since that is fixed and scrolls with you down the page, it's always accessible. There's also an inserter inline in the text: #323

Any plans for the "Help" tab? (I guess the Screen Options one will go away).

Not currently, but I will definitely add it to the list. Where would you put it?

I really appreciate the detailed and actionable input you have on accessibility, please keep providing that.

I would also ask for a faith, as the bet on a block-first UI might appear a departure from how post editors have traditionally worked. Inserting media, for example, is radically being rethought as inserting blocks, of which media is simply a type. This is not to say the new editor can't be made accessible — nothing gets merged unless it's accessible — just that we are treading new ground in places.

We are racing towards a plugin that we can test on real users, including screen readers. Hopefully that will help inform the best next steps to take.

@afercia
Copy link
Contributor Author

afercia commented Apr 20, 2017

The sidebar is visible by default, by the way.

Ah ok, I was assuming it was closed by default, as in the screenshot posted on Slack.

Worth also noting that the WCAG state the visual order should match the tab order.

Visually the publish button won't be changing its location from the old editor. It's still in the top right corner.

That WCAG requirement just says visual and tab order should match, i.e. if you put the toolbar on the top then it should be before the editor in the markup. That makes thing a bit more complicated 🙂 absolute positioning won't solve the issue, same for other CSS techniques. See https://www.w3.org/TR/WCAG20-TECHS/C27.html
One option could be considering to use a second toolbar on the bottom, see #469 (comment)

Any plans for the "Help" tab? (I guess the Screen Options one will go away).

Not currently, but I will definitely add it to the list. Where would you put it?

I have no idea 🙂 Users would expect to find it in the usual place, but that's not possible here. On the other hand, the current Help and Screen Options placement in WordPress is far from ideal. Wondering if it is worth considering some refactoring.

I've just realized there's one important thing missing in the new editor screen: the main h1 heading! 🚨 Please let me know if you want me to open a separate issue for this.

Thanks for your clarifications and the additional mockups, they helped me a lot to better understand some of the things here that were not so obvious at first sight 🙂

@jasmussen
Copy link
Contributor

I've just realized there's one important thing missing in the new editor screen: the main h1 heading! 🚨 Please let me know if you want me to open a separate issue for this.

Wouldn't that be the optional title in this mockup?

@afercia
Copy link
Contributor Author

afercia commented Apr 24, 2017

No, that it's inside the editable region and empty for a new post. The main h1 is actually used for navigating content, see https://make.wordpress.org/core/2015/10/28/headings-hierarchy-changes-in-the-admin-screens/

@jasmussen
Copy link
Contributor

I'm assuming we can't display: none that one either.

One of the goals of the rearranging of UI is to free up space. There are SO very very very many features in the editor, a decade of cruft that's built up, some which isn't even used widely anymore, like trackbacks. It is a noble goal to have an editor where every single aspect is 100% accessible, but the reason I'm asking for some faith in a few of the things we're doing is that we have to balance this against modernizing the UI, which means de-emphasizing some features in favor of a better overall editor experience. No, that doesn't mean those deprecated features can't be made accessible, but I do hope we can be open-minded about where they might sit in the editor structure.

Would it be possible, at a later date, for you to take part in a quick zoom video chat about this? I'd love to try and explore solutions together in a higher bandwidth format than only text.

@afercia
Copy link
Contributor Author

afercia commented Apr 24, 2017

Having a cleaner UI helps accessibility too so I'm definitely OK with that effort :) However that shouldn't happen at the expenses of removing fundamental accessibility features.

I'm assuming we can't display: none that one either.

Maybe, it could use screen-reader-text but that should be tested and evaluated carefully.
As per meeting/chat time, my time is very limited... we'll see!

@mapk
Copy link
Contributor

mapk commented Apr 26, 2017

In light of how people are sharing content nowadays, a forced H1 input field is a stumbling block for many who just want to take a photo and upload it to their site. Or maybe they just want to share a quote, or link, or audio track...

In many of these instances, the user may not want a title (h1). While I understand this is helpful for screen readers, I'm opposed to making it a requirement for posting. The way it's currently being explored (as an optional heading within the content) seems like a good solution to educating the user, but not forcing them to do it.

I'm curious to see how this is solved. :)

@afercia
Copy link
Contributor Author

afercia commented Apr 28, 2017

@mapk I'm not speaking about headings within the content 🙂
Instead, I mean headings in the user interface. Not only they're helpful for screen reader users, they're also a WCAG requirement.
At the moment, the Editor page is the only page in the WordPress admin without any headings at all. Not the best example of a well-structured HTML document. I'm sorry, but honestly I'm a bit surprised we're still discussing this kind of things after 15 and more years of web standards.

By the way, the headings issue is secondary on this issue. The main scope here is the order and grouping of controls in the toolbar, which is not ideal in my opinion. I'd greatly appreciate this could be discussed by the design team.

@mapk
Copy link
Contributor

mapk commented Apr 28, 2017

@afercia Sorry about that, my mistake. Thanks for the clarification.

Would something like this solve the issue?
heading

I've added the word "Editor:" to the Toolbar. That word could be an H1, but styled to match the surrounding interface. The dropdown "Visual" would not be part of it, and not affect the H1. Seems like it might fit nicely with tab order too.

@afercia
Copy link
Contributor Author

afercia commented Apr 28, 2017

@mapk yep maybe, but please let's move the headings conversation to #503 🙂

@afercia
Copy link
Contributor Author

afercia commented Apr 28, 2017

Cross posting from #503 :)

... together with re-considering the ordering and grouping of controls. I'd also like to see this being discussed by the design team and be open to the community feedback. As far as I know, a real, broad, discussion hasn't happened yet.

One more potential issue is about controls that use icons only. Icons don't have a universal meaning. I don't fully understand why some controls have only icons and other have icons plus some visible text. What't the reasoning behind that?

Also to consider, there are functions in WP that provide labels to be used by CPTs for this screen. Integrating such a change wouldn't be so easy.

@afercia
Copy link
Contributor Author

afercia commented Apr 30, 2017

One more issue: I see in the mockups a "by author" UI component places immediately below the toolbar:

author

I guess this is meant to be the author select. However, having it in the tab order right after the toolbar is not so ideal from an a11y and usability perspective, where controls should be grouped logically. Wondering if it should go in the sidebar, together with all the other metaboxes.

@afercia
Copy link
Contributor Author

afercia commented Jun 22, 2017

See also #1375 (comment)

@hedgefield
Copy link

hedgefield commented Jul 18, 2017

Based on @afercia argument for a more logical grouping of elements @moorscode and I made this mockup.

Gains:

  • Publishing is the main goal here, so that should be the first action.
  • Previewing is related to achieving that goal, and to preview you need to save, so grouping those actions together will eliminate some confusion. The icon for saving can also display a spinner (and then a checkmark) while (auto)saving.
  • In order of 'user needs', adding blocks to the page is next up, followed by undo-ing and re-do-ing what you do in those blocks. This also groups the icon + text buttons, which brings some calm to the toolbar.
  • Switching from visual to text is something you do a limited amount of times per post edit, so it should be clearly findable, but not a blocking higher-order element.
  • The settings toggle should be directly next to the sidebar, as it will 'spawn' something coming from that side of the screen. Making it stick to that side will make it more intuitive if somebody is searching for it. When the sidebar is hidden, the mode switcher could move next to the settings button.

gutenberg top bar2

@afercia
Copy link
Contributor Author

afercia commented Jul 20, 2017

I'd add that the "Save" and "Preview" controls are strictly related, for example:
in a new post, when the new content is not saved yet, "Preview" is disabled
only after clicking on "Save" then "Preview" gets enabled but it's so far that its state change could be missed by users.
Having the two controls close each other could greatly help not only because they're logically related but also visually.

@jasmussen
Copy link
Contributor

This is a very important interface, as it is literally the top level bar. It is not easy to get right, and I like what someone said on another thread: it's good to explore many interfaces, then discard many of them, so only the best remains.

However as it is, I'm trying to figure out how to best address issues, because there are a lot of different considerations to balance, which I'll go into in a second.

As such, I consider the key purpose of this ticket to ensure the editor bar is accessible. I understand that logical grouping is key to this. But I would ask that as we discuss what makes a specific grouping "logical", that we consider the future as well as the past, and mobile, as well as desktops. Reading through this thread many times, I can't help but feel like you can make arguments for why almost any grouping of items is "logical", and as such I feel like accessibility and mobile should be the razors to which we decide which way to go.

Let's go over the considerations.

1. Editor type/mode switcher

This is, I feel, a weak design in its current implementation. We are tracking separately how this can be improved. There's also a separate issue to ensure there's a heading for the editor, whether visible or not. But such a header could inform the left side of the editor, it could perhaps even help inform a good design for the editor type switcher.

2. Save state indicator

This is above all else an affordance for describing the save status of the document, and show errors when auto-saving fails for whatever reason. The grand idea here is that in modern web-apps, there exists no save button. Documents are automatically saved in the background, and all you need to know is that yes — it's saved, it says so right there. I feel like we should all consider the "Save" action to be vestigial and transitional, something that should eventually not need to exist at all, except for edgecases like when saving fails (Retry?) or you're offline.

Admittedly there are issues with how saving works right now, including an issue with autosave not actually working. These issues obviously need to be fixed separately. But though computational design we can save the user from having to think about the document being saved, or having to click a button all the time. If we agree this is a desireable future, then we shouldn't optimize any designs for a save button, we should optimize for a save state indicator.

Incidentally keeping this in mind, it helps present an answer for the very real and specific issue that Andrea brings up — that saving and previewing are tied together. To me the solution that presents itself is that the preview button should never be disabled, because the document is "always saved". I know that isn't the case right now, but given that being the end goal, a non-disabled preview button on a completely fresh document should then simply save the document, then preview it, when you click the button and the document is unsaved.

See also:

3: Publish button

We shouldn't always reinvent the wheel when it comes to interfaces. It's important to design according to established patterns. In this case, the publish button sat in the top right corner in the old editor. It was a splash of blue, and it remains a splash of blue. It follows the pattern of many online editors, and even offline editors where "Share" is the closest equivalent, and often sits in the top right as "the final action" — the Enter key on the right side of the keyboard. To me it makes the most sense to put it here, next to Preview and Settings, as those three are likely to be actions you utilize after writing your document.

Preview and Settings are both grouped together because I can easily see "Preview" not being just an external link, but indeed a toggle, just like Settings is today. It's a button that has an active state, and that active state could be split screen preview (untoggles the settings bar), or a modal that lets you resize an iframe preview to various device sizes to preview on mobile, tablet, or desktop. As such it would be grouped with the Settings button because they'd behave the same.

4. Undo, redo, insert

Keeping in mind that the editor is document level actions, it makes sense to have an area that contains such buttons. You could imagine future plugin hooks letting you add more buttons here. As such, these feel like they should be grouped together somehow, simply by virtue of the fact that they "manipulate the body content".

These are right-aligned to mimic the mobile pattern of having an "app bar" with title on the left (or centered on iOS), and action buttons on the right.

Responsive

On a meta level it's extra important that we get the groupings right, because on mobile, all labels, and even some buttons (undo/redo/plugin actions) get hidden. And so as you scale down a viewport it's important that when buttons/labels "pop off", what remains still feels like it's placed in the right locations.

Then what

Given all that background (sorry for the wall of text, but it's important), and all those considerations, I'm personally biased that what we have now works pretty well, and is worth launching with. This is an interface that I've worked on for 6 months, and is influenced from wp.com learnings, so it hasn't come together from nothing.

But that doesn't mean it has to be this way. I do expect this editor bar, including grouping, to be honed and changed and tuned a fair bit as we go, and I'm not at all opposed to changes. If anything, the only suggested changed I'd be against, is optimizing the interface for a "Save" button. IMO we should do everything we can to improve this interface by eliminating it.

Take the publish button on the left — this feels like a WordPress branding change. Look at the old editor and squint: you'll see black bars left and top, a white area center, and a blue button in the top right corner. This is largely intact in the new editor, intentionally so. But that doesn't mean it can't be done. Windows has close buttons on the right, and MacOS has close buttons on the left, after all ;)

@hedgefield
Copy link

Thanks for clarifying, Joen! it's great to hear all the ambient context that's not formally documented per se but that informs your design process. Good points about the save button and preview behaviour. We designed the above for what is there now because we didn't know what the intention behind everything was. Knowing now, we'd love to help refine the toolbar further (in a new issue). You're right, let's keep this a11y-focused.

@moorscode
Copy link
Contributor

Wall of text, much words. Good!

I can't help but feel like you can make arguments for why almost any grouping of items is "logical", and as such I feel like accessibility and mobile should be the razors to which we decide which way to go.

Totally agree, thank you for making this point.

2. Save state indicator
I agree that having an auto-save mode should have the default behaviour. The state indicator sounds like a perfect way to inform the user that their work is being stored; or some error occurred and they must be wary that data might be lost (internet connection interrupted).

3: Publish button

It follows the pattern of many online editors, and even offline editors where "Share" is the closest equivalent, and often sits in the top right as "the final action".
This is a very compelling argument, except for the Enter key on the right side of the keyboard.

Our approach was based on the principle that, in left-to-right based languages people are scanning from left-to-right in most situations. Having the "most important" button being introduced in subconscious focus makes it very easy to locate whenever somebody is done.

Though this argument would better suit the "save" functionality, as you might want to do that before visiting the "settings" or "preview".

or a modal that lets you resize an iframe preview to various device sizes to preview on mobile, tablet, or desktop.

Having a more "Customizer"-like experience for previewing sounds like a really good concept. As such it would be grouped with the Settings button because they'd behave the same.

As I see a possible user flow for writing a new post would be:

  1. Write some content
  2. See how it looks
  3. Make some changes (goto 1) / Be happy with the post (continue)
  4. Determine when it should be published
  5. Close/Publish

This suggests that the Preview, Settings and Publish / Finish functionalities should logically be placed together.

We put the "Publish" button on the left, because is feels very boxed in on the right, especially with the settings opened:
screen shot 2017-07-21 at 13 32 14
The big dark settings button is not helping in giving the publish button enough importance.

In the current design, it has much more breathing room and stands out much more:
screen shot 2017-07-21 at 13 32 26

This was one of the itches that we tried to resolve in our conceptual proposal.

4. Undo, redo, insert
I saw a concept Andrea made with these buttons, having them below the main bar and more in contact with the editor-area. This felt and looked so much more usable.
In this concept the buttons are centered, like the blocks.

These are right-aligned to mimic the mobile pattern of having an "app bar" with title on the left (or centered on iOS), and action buttons on the right.

The concept is clear, but on mobile the screen is much smaller and the buttons will always be in range of the place where they have actual influence.
We have (way too) large screens at the office, which results in a strange composition.

screen shot 2017-07-21 at 13 41 28

Then what

This is an interface that I've worked on for 6 months, and is influenced from wp.com learnings, so it hasn't come together from nothing.

Our intention is not to destroy or ignore anything that has made this come together at all.
I had an itch when experimenting with it, and having a fresh and critical eye, we wanted to see what re-arranging the used elements could do.

If anything, the only suggested changed I'd be against, is optimizing the interface for a "Save" button. IMO we should do everything we can to improve this interface by eliminating it.

Yes, yes, yes!

It is absolutely usable and workable for anybody, but one of the things that people are not very comfortable with is change. So it would be nice to point out any elements that might not be optimal and see if we can give them the space, attention and location they deserve without making it a change in a future release when people are already used to where and how they are placed.

One of the selling points (if not -the-) is that WordPress is so easy to use. Though I think we should not fixate on keeping things exactly as they are now.
Keeping things as they were is an approach when you make changes to a page in the admin. This is not making changes to a page, this is creating a new way of controlling the post.

Take the publish button on the left — this feels like a WordPress branding change.

You have convinced me that the publish button might not have to be on the left, but honestly I think the whole Gutenberg approach is a WordPress branding change, thus it feels a bit of a non-argument to use in this context.

@afercia
Copy link
Contributor Author

afercia commented Jul 21, 2017

@jasmussen I kindly disagree 🙂

It's important to design according to established patterns. In this case, the publish button sat in the top right corner in the old editor. It was a splash of blue, and it remains a splash of blue.

That's not exactly correct:

  • in the old editor, the Publish button is not on top of the editor, instead, by default, it's on the right column, which is pretty different; it comes after the editor
  • in the old edit screen, the Publish box is sortable, as all the other meta boxes
  • in the old edit screen, users can set the page layout to 1 column from the Screen Options and the Publish box is after the editor

Actually, Gutenberg is not following an established pattern. Instead, it's changing it placing the Publish button before the editor.

As I've mentioned in the related PR #1963 I think it's something to experiment but I feel it's not an ideal solution, we're not still there. I'm not so convinced the "Publish group" should be on the top left. However, it makes a lot of sense to me to group it with actions or state indicators that are logically related. If in the future the "save" button/indicator will disappear, that's good! Currently, it's there and we have to deal with it.

Ideally, Id like to see anything that comes before the title and the content just disappear.

When I think at what I see as an ideal editing workflow, I'd like to be able to:

  • land on a page where I can write
  • start writing the title
  • start writing the content
  • do anything else (settings, scheduling, whatever) after
  • lastly, submit my work and decide save/publish etc.

I think this is an established pattern, as for years and years any web interface based on forms has a submit button at the end of the form. The Customizer has the Save button on the top and over time we've received lots of complaints about that.

Re: too many things at the top, I'd recommend again to have a look at the feedback on the core Ticket I've posted above:
https://make.wordpress.org/flow/2014/11/11/post-editing-experience-on-iphone-6/
https://make.wordpress.org/flow/2014/10/16/a-survey-of-media_buttons-macnchrome-iphone-5-4-1-alpha-20141015/

where two influential voices of this project express doubts about all the controls that come before the editor, especially on mobile. Not to mention on mobile devices my hands are at the bottom of the screen.

Undo, redo, insert
Keeping in mind that the editor is document level actions, it makes sense to have an area that contains such buttons.
... they should be grouped together somehow

You've convinced me. This is one more reason why they shouldn't be mixed together with all the other controls that are more related to the editing tool or the publish state.

and is influenced from wp.com learnings

wp.org has some learnings too :)

@jasmussen
Copy link
Contributor

jasmussen commented Jul 21, 2017

Really good discussions here. Impressed by the level of discourse 👏

I will digest and respond more in-depth later. Wanted to quickly address two quick points. First off, I didn't mean to dismiss past WP.org learnings, nor that any changes are off the table now or long-term.

Secondly,

Instead, it's changing it placing the Publish button before the editor.

I'm still thinking on how to address the tab order issues the top bar introduces, and have been since you opened the ticket for it. Questions on that:

  1. The primary issue is that making the tab sequence start first on the editor, then the editor bar, is bad form, correct? (Because it has to match visual order?)
  2. If yes in 1, does moving the publish button left solve this?

I've been looking at other patterns to take inspiration from. Google Docs appears to set focus on the editable area first, and then on to the top toolbar after. Is this kosher?

Are there examples of great and accessible online editors where publish/share/done-editing actions visually live above the content?

@afercia
Copy link
Contributor Author

afercia commented Jul 21, 2017

The primary issue is that making the tab sequence start first on the editor, then the editor bar, is bad form, correct? (Because it has to match visual order?)

Yes, visual order should always match tab order. Aside: not only a WCAG requirement, also the CSS Flexbox and CSS Grid specs explicitly state this.

If yes in 1, does moving the publish button left solve this?

No it doesn't 🙂 that's why #1963 doesn't fully convince me yet. I like the grouping there, though.

Google Docs appears to set focus on the editable area first, and then on to the top toolbar after. Is this kosher?

Not so much, but elements are in the right order, it's more like setting initial focus in a form with a very specific task to accomplish. Google Docs maybe is not the best example though, since it is designed more like a desktop application than a web app. The provide the very-easy-to-remember shortcut Cmd + Option + Shift + m to ove focus away from the editable area and put it on the toolbar. What is interesting to note there, is that keyboard navigation within the toolbar docs-toolbar-wrapper works with arrows only. See #631 and #632.

Are there examples of great and accessible online editors where publish/share/done-editing actions visually live above the content?

None that I'm aware of (I mean I don't know of any online editor that's fully accessible). Just imagine you're using the keyboard and your post has 30 or even more blocks. You're on the last block, and then you have to publish... 😎

@afercia
Copy link
Contributor Author

afercia commented Jul 22, 2017

Worth considering also the discussion about pluggable areas, see #1352

@jasmussen
Copy link
Contributor

Still thinking about this one. I still do understand why this is important (so you don't have to tab through all the browser chrome, then invoke a "Skip to content" link so you can get to publish). I'm also still not convinced that actually having the toolbar be only at the bottom is the solution.

Please also bear with me if the following is a bad idea, this is why I'm asking for your expertise.
#552 got me thinking — when you are in a block and editing, you have a shortcut to get to the content editing controls. Would it be permissible to have a similar shortcut for when you are in the document scope and editing? I.e. you have no blocks selected, and you can use ⌘ as Ella describes in the ticket, to set focus on the topmost editor bar? Or if not that, is there an equivalent shortcut we can invoke to shift between content and document scopes?

Thanks for your patience and input.

@afercia
Copy link
Contributor Author

afercia commented Aug 4, 2017

I'm also still not convinced that actually having the toolbar be only at the bottom is the solution.

I'd be happy if at least the Publish button was after the content in the markup 🙂 Or, maybe, add a second Publish button at the end of the content, in the area close to the second Inserter button. If I remember correctly, the presence of the Paragraph and Image block buttons there was still something to make a final decision about:

screen shot 2017-08-04 at 17 13 00

We're also missing one important point: the Settings button should be immediately followed by the sidebar (always speaking about order in the source).

However, in the spirit of trying to find a balance between different needs, I've been thinking at an option I'd like to discuss with you and anyone interested (designers, a11y team, etc.).

1 keyboard users:
have you seen what Slack implemented recently? If you ant to try it, click on the message field and then:

Move focus to the next section: Control + backtick
Move focus to the previous section: Shift Control + backtick

Of course, we shouldn't use backtick because it's not available on all keyboard layouts.

2 screen reader users
we should review, and add were necessary, landmark roles
https://www.w3.org/TR/wai-aria/roles#landmark_roles
https://www.w3.org/TR/wai-aria-1.1/#landmark_roles

Landmarks allow screen reader users to quickly jump from one section to another section and WordPress is already using it. We should re-organize them in the Gutenberg screen, which is already using one landmark: role="region" aria-label="Visual Editor"

For example, the whole sidebar could be role="aside" aria-label="Editor sidebar", or something along those lines.

Pending discussion with the team 🙂

visual editor region

@jasmussen
Copy link
Contributor

A publish button after the content could be an option. But the keyboard shortcuts for moving between sections idea seems like it could be an amazing enhancement regardless of other improvements.

the Settings button should be immediately followed by the sidebar (always speaking about order in the source)

Just because it was quick to draw up, would the following design potentially help with that? CC: @melchoyce

alternate editor bar

@afercia
Copy link
Contributor Author

afercia commented Aug 7, 2017

Yep the button new position would help! Then we should try to move the whole sidebar in the source before the content #riskylife

As per the shortcuts à la Slack and the landmarks, that should be paired with a well documented an well communicated help section.

@joedolson
Copy link
Contributor

Per the Slack discussion on 8/7/2017, the accessibility team agrees that implementing a keyboard shortcut similar to what Slack does to navigate between the major regions within Gutenberg is definitely worth pursuing. Using the backtick as the Ctrl + {trigger} is problematic, due to the lack of a backtick character on many international keyboard layouts. Given that Gutenberg is not yet using any keyboard shortcuts, determining this shortcut should be part of the overall discussion on adding keyboard shortcuts in #71.

ARIA Landmark roles should be used to provide screen reader navigation between regions. The sidebar should definitely be an aside element, mapping to the complementary role with an appropriate aria-label attribute.

The top toolbar is more complicated. It would be nice to give it a role of toolbar, but the 'Preview' control doesn't fit with the toolbar specification. Within a toolbar, all controls should be considered changes of view or settings within the current context. If the preview triggered an in-context preview of the page, that would be fine, but as it initiates a change of context, that doesn't work. This could be resolved by implementing an in-context preview or by moving the Preview control into another location. (See https://www.w3.org/TR/wai-aria-practices/examples/toolbar/toolbar.html for an example of appropriate usage of the toolbar role.)

Giving the top toolbar a role of toolbar would be useful for reducing tab stops, but if we can't do that, using an aside to map it as a second complementary region would be acceptable.

@melchoyce
Copy link
Contributor

melchoyce commented Aug 8, 2017

@joen I'm cool with that mockup ^

@anna-harrison
Copy link

Cross-reference to #1963 : link to recommendations and backing research here

@afercia afercia changed the title Editor toolbar: controls order and grouping Add keyboard shortcuts à la Slack to jump through the main UI sections Oct 19, 2017
@afercia
Copy link
Contributor Author

afercia commented Oct 19, 2017

Agreed during last G. meeting to rename this issue to better reflect what's needed here. ARIA landmarks were added in #2380 and they allow assistive technologies users to quickly jump through the toolbar, editor, sidebar:

gutenberg landmarks

A similar mechanism should be made available to keyboard users and shortcuts à la Slack seem the best option. They should allow to jump through the ARIA landmarks above. A strong indication of focus when jumping to a section would also greatly help, exactly like Slack does.

All the interface content should be inside one of these 3 regions.

To get a rough idea of what Slack does, here's the region you can jump to pressing Cmd?ctrl + backtick:

screen shot 2017-08-04 at 16 06 17

As per the toolbar controls order and grouping, there's a lot going on at the moment and discussion is happening on separate issues.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Focus] Accessibility (a11y) Changes that impact accessibility and need corresponding review (e.g. markup changes).
Projects
None yet
Development

Successfully merging a pull request may close this issue.

10 participants