A <menuitem> element of type "command":
<menu>
<menuitem type="command" label="Save" onclick="save()">Save</menuitem>
</menu>
type 属性指定命令/菜单项的类型。
表中的数字指定了完全支持该属性的第一个浏览器版本。
Attribute | |||||
---|---|---|---|---|---|
type | ❌ 不支持 | ❌ 不支持 | ❌ 不支持 | ❌ 不支持 | ❌ 不支持 |
<menuitem type="command|checkbox|radio">
值 Value | 描述 Description |
---|---|
command | Default. Specifies a normal command with an action |
checkbox | Specifies a command that can be toggled using a checkbox |
radio | Specifies a command that can be toggled using a radio button |