function _define_property(obj, key, value) {
    if (key in obj) Object.defineProperty(obj, key, {
        value: value,
        enumerable: true,
        configurable: true,
        writable: true
    });
    else obj[key] = value;
    return obj;
}
class PluginContextMenu {
    get() {
        return this.menuItems;
    }
    add(name, options) {
        this.menuItems[name] = {
            name: name,
            ...options
        };
    }
    constructor(_pluginMenuItems){
        _define_property(this, "menuItems", {});
        Object.entries(_pluginMenuItems || {}).forEach((param)=>{
            let [name, PluginItemsOptions] = param;
            this.add(name, PluginItemsOptions);
        });
    }
}
export { PluginContextMenu };
