The properties to update. Accepts the same values as the create function.

interface _UpdateUpdateProperties {
    checked?: boolean;
    contexts?: browser.menus._ContextType[];
    documentUrlPatterns?: string[];
    enabled?: boolean;
    icons?: browser.menus._UpdateUpdatePropertiesIcons;
    onclick?: (info: browser.menus.OnClickData, tab: Tab) => void;
    parentId?: string | number;
    targetUrlPatterns?: string[];
    title?: string;
    type?: browser.menus.ItemType;
    viewTypes?: ViewType[];
    visible?: boolean;
}
Index
checked?: boolean
documentUrlPatterns?: string[]
enabled?: boolean
onclick?: (info: browser.menus.OnClickData, tab: Tab) => void

Type Declaration

    • (info: browser.menus.OnClickData, tab: Tab): void
    • Parameters

      • info: browser.menus.OnClickData
      • tab: Tab

        The details of the tab where the click took place. Note: this parameter only present for extensions. Not supported on manifest versions above 2.

      Returns void

parentId?: string | number

Note: You cannot change an item to be a child of one of its own descendants.

targetUrlPatterns?: string[]
title?: string
viewTypes?: ViewType[]
visible?: boolean

Whether the item is visible in the menu.