Baseline Widely available
HTML-ÑÐ»ÐµÐ¼ÐµÐ½Ñ <menu>
пÑедÑÑавлÑÐµÑ Ð³ÑÑÐ¿Ð¿Ñ ÐºÐ¾Ð¼Ð°Ð½Ð´, коÑоÑÑе полÑзоваÑÐµÐ»Ñ Ð¼Ð¾Ð¶ÐµÑ Ð²ÑполниÑÑ Ð¸Ð»Ð¸ акÑивиÑоваÑÑ. Ðн вклÑÑÐ°ÐµÑ ÐºÐ°Ðº менÑ-ÑпиÑки, коÑоÑÑе могÑÑ Ð¾ÑобÑажаÑÑÑÑ Ð² веÑÑ
ней ÑаÑÑи ÑкÑана, Ñак и конÑекÑÑнÑе менÑ, напÑимеÑ, Ñакие, ÑÑо могÑÑ Ð¿Ð¾ÑвиÑÑÑÑ Ð¿Ð¾Ð´ кнопкой поÑле нажаÑиÑ.
<li>
element: Palpable content. ÐопÑÑÑимое ÑодеÑжимое If the element is in the list menu state: flow content, or alternatively, zero or more occurrences of <li>
, <script>
, and <template>
. (list menu is the default state, unless the parent element is a <menu>
in the context menu state.)If the element is in the context menu state: zero or more occurrences, in any order, of <menu>
(context menu state only), <menuitem>
, <hr>
, <script>
, and <template>
. ÐÑопÑÑк Ñегов ÐеÑ, оÑкÑÑваÑÑий и закÑÑваÑÑий Ñеги обÑзаÑелÑнÑ. ÐопÑÑÑимÑе ÑодиÑели ÐÑбой ÑлеменÑ, коÑоÑÑй поддеÑÐ¶Ð¸Ð²Ð°ÐµÑ Ð¾Ñновной поÑок. ÐеÑвнÑе ARIA-Ñоли list
ÐопÑÑÑимÑе ARIA-Ñоли directory
, group
, listbox
, menu
, menubar
, none
, presentation
, radiogroup
, tablist
, toolbar
или tree
DOM-инÑеÑÑÐµÐ¹Ñ HTMLMenuElement
ÐÑÑибÑÑÑ
Ð ÑÑÐ¾Ð¼Ñ ÑлеменÑÑ Ð¿ÑÐ¸Ð¼ÐµÐ½Ð¸Ð¼Ñ Ð³Ð»Ð¾Ð±Ð°Ð»ÑнÑе аÑÑибÑÑÑ.
label
УÑÑаÑело
The name of the menu as shown to the user. Used within nested menus, to provide a label through which the submenu can be accessed. Must only be specified when the parent element is a <menu>
in the context menu state.
type
This attribute indicates the kind of menu being declared, and can be one of two values.* context
УÑÑаÑело : Indicates the popup menu state, which represents a group of commands activated through another element. This might be as a button menu referenced by a menu
attribute of a <button>
element, or as context menu for an element with a contextmenu
attribute. This value is the default if the attribute is missing and the parent element is also a <menu>
element.
toolbar
: Indicates the toolbar state, which represents a toolbar consisting of a series of commands for user interaction. This might be in the form of an unordered list of <li>
elements, or, if the element has no <li>
element children, flow content describing available commands. This value is the default if the attribute is missing.The <menu>
and <ul>
elements both represent an unordered list of items. The key difference is that <ul>
primarily contains items for display, whilst <menu>
is intended for interactive items, to act on.
An HTML menu can be used to create context menus (typically activated by right-clicking another element) or toolbars.
Context menus consist of a <menu>
element which contains <menuitem>
elements for each selectable option in the menu, <menu>
elements for submenus within the menu, and <hr>
elements for separator lines to break up the menu's content into sections. Context menus are then attached to the element they're activated from using either the associated element's contextmenu
attribute or, for button-activated menus attached to <button>
elements, the menu
attribute.
Toolbar menus consist of a <menu>
element whose content is described in one of two ways: either as an unordered list of items represented by <li>
elements (each representing a command or option the user can utilize), or (if there are no <li>
elements), flow content describing the available commands and options.
This element was deprecated in HTML4, but reintroduced in HTML5.1 and the HTML living standard. This document describes the current Firefox implementation. Type 'list' is likely to change to 'toolbar' according to HTML5.1.
ÐÑимеÑÑУÑÑаÑело: ÐÑа возможноÑÑÑ Ð±Ñла Ñдалена из веб-ÑÑандаÑÑов. ХоÑÑ Ð½ÐµÐºÐ¾ÑоÑÑе бÑаÑзеÑÑ Ð¿Ð¾-пÑÐµÐ¶Ð½ÐµÐ¼Ñ Ð¼Ð¾Ð³ÑÑ Ð¿Ð¾Ð´Ð´ÐµÑживаÑÑ ÐµÑ, она Ð½Ð°Ñ Ð¾Ð´Ð¸ÑÑÑ Ð² пÑоÑеÑÑе ÑдалениÑ. Ðе иÑполÑзÑйÑе ÐµÑ Ð½Ð¸ в ÑÑаÑÑÑ , ни в новÑÑ Ð¿ÑоекÑÐ°Ñ . СÑÑаниÑÑ Ð¸Ð»Ð¸ веб-пÑиложениÑ, иÑполÑзÑÑÑие еÑ, могÑÑ Ð² лÑбой Ð¼Ð¾Ð¼ÐµÐ½Ñ ÑломаÑÑÑÑ.
HTML CSS ResultÐÑедÑпÑеждение: Menu buttons haven't been implemented in any known browsers yet. The type
attribute on the <menu>
element is now obsolete.
ÐÑедÑпÑеждение: <menuitem>
element is obsolete.
ÐÑедÑпÑеждение: Toolbar menus haven't been implemented in any known browsers yet.
HTML<!-- A context menu for a simple editor,
- containing two menu buttons. -->
<menu type="toolbar">
<li>
<button type="menu" menu="file-menu">File</button>
<menu type="context" id="file-menu">
<menuitem label="New..." onclick="newFile()">
<menuitem label="Save..." onclick="saveFile()">
</menu>
</li>
<li>
<button type="menu" menu="edit-menu">Edit</button>
<menu type="context" id="edit-menu">
<menuitem label="Cut..." onclick="cutEdit()">
<menuitem label="Copy..." onclick="copyEdit()">
<menuitem label="Paste..." onclick="pasteEdit()">
</menu>
</li>
</menu>
Result СпеÑиÑикаÑии СовмеÑÑимоÑÑÑ Ñ Ð±ÑаÑзеÑами СмоÑÑиÑе Ñакже
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4