const crusade

This commit is contained in:
Evan Simkowitz 2024-07-23 12:42:31 -07:00
parent 876c360922
commit ed43d7e0a8
No known key found for this signature in database
2 changed files with 5 additions and 5 deletions

View File

@ -1,7 +1,7 @@
// Copyright 2024, Command Line Inc.
// SPDX-License-Identifier: Apache-2.0
let { contextBridge, ipcRenderer } = require("electron");
const { contextBridge, ipcRenderer } = require("electron");
contextBridge.exposeInMainWorld("api", {
getPlatform: () => ipcRenderer.sendSync("getPlatform"),

View File

@ -12,16 +12,16 @@ class ContextMenuModelType {
}
handleContextMenuClick(id: string): void {
let handler = this.handlers.get(id);
const handler = this.handlers.get(id);
if (handler) {
handler();
}
}
_convertAndRegisterMenu(menu: ContextMenuItem[]): ElectronContextMenuItem[] {
let electronMenuItems: ElectronContextMenuItem[] = [];
for (let item of menu) {
let electronItem: ElectronContextMenuItem = {
const electronMenuItems: ElectronContextMenuItem[] = [];
for (const item of menu) {
const electronItem: ElectronContextMenuItem = {
role: item.role,
type: item.type,
label: item.label,