Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions PLUGINS.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
### Run Hyper in dev mode
Hyper can be run in dev mode by cloning this repository and following the ["Contributing" section of our README](https://github.com/vercel/hyper#contribute).

In dev mode you'll get more ouput and access to React/Redux dev-tools in Electron.
In dev mode you'll get more output and access to React/Redux dev-tools in Electron.

Prerequisites and steps are described in the ["Contributing" section of our README](https://github.com/vercel/hyper#contribute).
Be sure to use the `canary` branch.
Expand All @@ -32,7 +32,7 @@ module.exports = {
### Running your plugin
To load, your plugin should expose at least one API method. All possible methods are listed [here](https://github.com/vercel/hyper/blob/canary/app/plugins/extensions.ts).

After launching Hyper in dev mode, run `yarn run app`, it should log that your plugin has been correcty loaded: `Plugin hyper-awesome-plugin (0.1.0) loaded.`. Name and version printed are the ones in your plugins `package.json` file.
After launching Hyper in dev mode, run `yarn run app`, it should log that your plugin has been correctly loaded: `Plugin hyper-awesome-plugin (0.1.0) loaded.`. Name and version printed are the ones in your plugins `package.json` file.

When you put a `console.log()` in your plugin code, it will be displayed in the Electron dev-tools, but only if it is located in a renderer method, like component decorators. If it is located in the Electron main process method, like the `onApp` handler, it will be displayed in your terminal where you ran `yarn run app` or in your VSCode console.

Expand Down Expand Up @@ -152,7 +152,7 @@ exports.decorateMenu = (menu) => {
label: 'Clear all panes in all tabs',
accelerator: 'ctrl+shift+y',
click(item, focusedWindow) {
// on macOS, menu item can clicked without or minized window
// on macOS, menu item can clicked without or minimized window
if (focusedWindow) {
focusedWindow.rpc.emit('clear allPanes');
}
Expand Down
180 changes: 90 additions & 90 deletions bin/yarn-standalone.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion cli/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ args.command(
);

const lsRemote = (pattern?: string) => {
// note that no errors are catched by this function
// note that no errors are caught by this function
const URL = `https://api.npms.io/v2/search?q=${
(pattern && `${pattern}+`) || ''
}keywords:hyper-plugin,hyper-theme&size=250`;
Expand Down
2 changes: 1 addition & 1 deletion lib/actions/sessions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ export function closeSearch(uid?: string, keyEvent?: any) {
});
} else {
if (keyEvent) {
keyEvent.catched = false;
keyEvent.caught = false;
}
}
};
Expand Down
2 changes: 1 addition & 1 deletion lib/command-registry.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ export const getCommandHandler = (command: string) => {
return commands[command];
};

// Some commands are directly excuted by Electron menuItem role.
// Some commands are directly executed by Electron menuItem role.
// They should not be prevented to reach Electron.
const roleCommands = [
'window:close',
Expand Down
2 changes: 1 addition & 1 deletion lib/components/term.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -418,7 +418,7 @@ export default class Term extends React.PureComponent<

keyboardHandler(e: any) {
// Has Mousetrap flagged this event as a command?
return !e.catched;
return !e.caught;
}

setBellSound(bell: 'SOUND' | false, sound: string | null) {
Expand Down
2 changes: 1 addition & 1 deletion lib/containers/hyper.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ const Hyper = forwardRef<HTMLDivElement, HyperProps>((props, ref) => {
(e) => {
const command = keys[commandKeys];
// We should tell xterm to ignore this event.
(e as any).catched = true;
(e as any).caught = true;
props.execCommand(command, getCommandHandler(command), e);
shouldPreventDefault(command) && e.preventDefault();
},
Expand Down
2 changes: 1 addition & 1 deletion test/unit/window-utils.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ test('positionIsValid() returns true when window is on second screen', (t) => {
t.true(result);
});

test('positionIsValid() returns false when position isnt valid', (t) => {
test('positionIsValid() returns false when position isn't valid', (t) => {
const primaryDisplay = {
workArea: {
x: 0,
Expand Down