Reading notes from "The Definitive Guide to HTML5" (1)

(1) Global attributes of labels

  1. accesskey attribute
<!-- 键盘同时按下Alt+n键可以获取焦点 -->
<input accesskey="n" />
  1. contenteditable attribute (new in HTML5): Enables the editing function of tags, allowing users to modify the content of the page
  2. contextmenu attribute (currently only the Firefox browser supports the contextmenu attribute): used to set shortcut menus for elements
  3. dir attribute (ltr: text direction from left to right rtl: text direction from right to left): specifies the text direction of the element content
  4. draggable attribute: indicates whether the element can be dragged and dropped
  5. dropzone attribute: used in conjunction with draggable attribute
  6. hidden attribute: hide related elements
  7. lang attribute (must use a valid ISO language code): used to describe the language used by the element content
  8. spellcheck attribute (only used on editable elements): performs spell check on the content of the element
  9. tabindex attribute (the first one with a value of 1 is selected in downward order, -1 will not be selected): You can use the Tab key on the keyboard to switch the focus element

Guess you like

Origin blog.csdn.net/dncsdnf/article/details/121619825