键盘可访问的网络下拉菜单? [英] Keyboard accessible web dropdown menus?

查看:88
本文介绍了键盘可访问的网络下拉菜单?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有没有办法在网站上构建键盘可访问的下拉菜单?我们当前的网络应用程序有标准的悬停菜单,但这真的减慢了我们的数据输入员(谁习惯桌面应用程序,有一个键盘可访问的菜单,而不需要使用鼠标)。

Is there a way to build keyboard accessible dropdown menus on web sites? Our current web application has standard hover menus, but this really slows down our data entry clerks (who are accustomed to desktop apps where there's a keyboard accessible menu and no need to use a mouse).

我们想出了如何使用键盘快捷键显示菜单,但我不知道如何选择其中一个条目(例如使用第一个字母菜单项,如大多数桌面应用程序)。

We figured out how to show the menu with a keyboard shortcut, but I'm not sure how to select one of the entries (such as by using the first letter of the menu entry like in most desktop apps).

编辑 - 指向执行此操作或其他类型示例的网站的链接非常实用

Edit - a link to a site that does this, or some other type of example, would be REALLY helpful

推荐答案

您可以为锚标记使用 accesskey 属性:

You can use accesskey attribute for anchor tag:

<a href="something.html" accesskey="s">[S]omething</a>

但所有浏览器使用的键盘快捷键有所不同:

but keyboard shortcut to use this differs across all the browsers:


  • IE :Alt + accesskey ,请输入

  • / strong>:Alt + Shift + accesskey

  • Opera :Shift + Esc + li>
  • Chrome :Alt + accesskey

  • IE: Alt + accesskey, Enter
  • FireFox: Alt + Shift + accesskey
  • Opera: Shift + Esc + accesskey
  • Chrome: Alt + accesskey

这篇关于键盘可访问的网络下拉菜单?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆