Skip to content
This repository has been archived by the owner on Mar 5, 2023. It is now read-only.

Commit

Permalink
feat: added zoom options
Browse files Browse the repository at this point in the history
  • Loading branch information
renanrcp committed Feb 20, 2023
1 parent 9ac28cb commit c6c4114
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 5 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ OBS: macOS installer not available for now.
- Clear cache option
- Reload and Reload Without Cache
- Can set FullScreen
- Can change the zoom with `CmdOrControl +`, `CmdOrControl -` and `CmdOrContrl + 0`
- Can open Chromium Dev Tools
- Optional AD Blocker for performance gameplay (comes disabled)
- Optional Discord Rich Presence (comes disabled)
Expand Down
26 changes: 21 additions & 5 deletions src/menu.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import changeClubPenguinUrl from "./urlchanger";
import { toggleFullScreen } from "./window";

const createMenuTemplate = (store: Store, mainWindow: BrowserWindow): MenuItemConstructorOptions[] => {
const options = {
const options: MenuItemConstructorOptions = {
id: '1',
label: 'Options',
submenu: [
Expand All @@ -28,7 +28,7 @@ const createMenuTemplate = (store: Store, mainWindow: BrowserWindow): MenuItemCo
{
label: 'Reload',
accelerator: 'F5',
click: () => { mainWindow.reload(); }
role: 'reload',
},
{
label: 'Reload without cache',
Expand All @@ -39,11 +39,27 @@ const createMenuTemplate = (store: Store, mainWindow: BrowserWindow): MenuItemCo
label: 'Toggle Fullscreen',
accelerator: 'F11',
click: () => { toggleFullScreen(store, mainWindow); }
}
},
{
label: 'Zoom In',
role: 'zoomIn',
accelerator: 'CommandOrControl+=',
},
{
label: 'Zoom Out',
role: 'zoomOut',
accelerator: 'CommandOrControl+-',
},

{
label: 'Reset Zoom',
role: 'resetZoom',
accelerator: 'CommandOrControl+0',
},
]
};

const adblock = {
const adblock: MenuItemConstructorOptions = {
id: '2',
label: 'Adblock',
submenu: [
Expand All @@ -54,7 +70,7 @@ const createMenuTemplate = (store: Store, mainWindow: BrowserWindow): MenuItemCo
]
};

const discord = {
const discord: MenuItemConstructorOptions = {
id: '3',
label: 'Discord',
submenu: [
Expand Down

0 comments on commit c6c4114

Please sign in to comment.