Commit graph

49 commits

Author SHA1 Message Date
hector
7074cbe29b Expose focusActiveTerm function to window 2019-11-02 17:21:31 +01:00
Raz Friman
6039acd7a9 Update Electron to v6 (#3785)
* 3.0.0

* 3.0.2

* Save

* Save

* Upgrade yarn lock packages

* update node-gyp and node-pty

* update travis and appveyor to node 12

* appveyor is outdated as always

* update travis to xenial

* update node-pty@0.9.0-beta26

* update yarn.lock

* update electron to 6.0.8

* move node-pty to the correct package.json

* Fix linting failure

* Update yarn lockfile to try to fix appveyor build

* Remove unnecessary changes from package.json

* Try to fix appveyor by using a newer image

* Fix linting after my last change

* update electron to 6.0.9

* install windows-build-tools on appveyor

* fix syntax

* switch back to 2017 image

* remove old resolutions field

* revert accidental version change

* update electron to 6.0.11 and electron-rebuild to 1.8.6

* downgrade yarn to 1.18

until this issue is resolved https://github.com/yarnpkg/yarn/issues/7584

* update node-gyp to 6.0.0 and generate a fresh yarn lockfile

* update react and a few other dependencies

* fix lint

* this should actually be electron-builder, I think!

* update a few dependencies

* change to electron-store

electron-config was renamed to electron-store a while ago

* update xterm to v4.1.0 and ora to 4.0.2

* move pify to app/package.json

* TODO: Revert maybe. Throw a fit on every change to maybe fix the resizing issues

* a

* fix react ref problem

* fix split view focus problem

* remove the unnecessary fit

* remove the init col and row

* fix the problem that cannot show about hyper

* update electron to 6.0.12

* fix lint

* add more todos for componentWillReceiveProps deprecation

* update babel and plugins


Co-authored-by: Juan Campa <juancampa@gmail.com>
Co-authored-by: Benjamin Staneck <staneck@gmail.com>
Co-authored-by: ivan <ivanwonder@outlook.com>
2019-10-10 21:20:26 +02:00
Gaby
ab0c8fe13f Add support for font ligatures via xterm-addon-ligatures - Clos… (#3853)
* Add support for font ligatures via xterm-addon-ligatures

* Add disableLigatures config option, defaults to false

* Fix lint issue
2019-10-09 22:23:55 +02:00
Donald Green
5d7142c2df Return of the Bell (#2938)
* 1. Restored the ability to turn the "bell" sound on and off using the "bell" config parameter.
2. Restored the ability to change the bell sound by providing a URL. These changes allow for a web url or local absolute file path to an audio file.

The goal with these changes was to fix the issue causing the bell to never sound due to a difference in the underlying terminal emulators configurations from the previous one. While in the area, also decided to make sure that the sound can be changed by supplying a web url to an audio file or an absolute path to an audio file within the local machine

* Code style changes

* Code style changes

* 1. More code style changes

* 1. Spacing changes to try and abide by the linter

* 1. Applied all suggested changes by eslint

* 1. Removed functionality to specify a remote url to set a sound file for the bell sound. The amount of effort for handling when there is no internet connection, queuing and so forth wasn't worth keeping the feature. It is likely that the url could be used to download the file in which the user would be able to specify the file path tho this download file.
2. Created a new property that gets passed down from the terms container all the way to the individual term. We want to be able to evaluate if the bellSoundURL has changed to determine if we really need to read the sound file.
3. Moved logic to read the audio file into the main process. Setup a new action in the 'actions/ui' that will update the bell sound when it is finished and ready. This should prevent blocking the terminal from loading and thus increasing loading times.

* 1. Modified the file reading method to be more generic to increase reusability.
2. Updated the "arrBuf2Base64" method to utilize the node Buffer class which helped to reduce some complexity and seems to run more efficiently.
3. Removed the CONFIG_ASYNC action and reducer in favor of reusing CONFIG_RELOAD when the process is finished reading the file for the bell sound. In order to achieve this, we had to merge the config from "config.getConfig()" method with the "bellSound" property before dispatching to "reloadConfig".

* 1. Removed reference to now removed method

* 1. Removed the arrBuf2Base64 as it seemed unnecessary now that the function would be reduced to a single line. Moved the one-liner into file.js. Removed references to arrBuf2Base64 method.
2. Refactored the logic that handles reloading the config when it has been updated to fix an issue that would set the bell sound back to the default sound when the config is saved without changing the value of "bellSoundURL". Setup now to either read file and reload the config, or reuse the "bellSound" value saved in state and reload the config. This removes an inefficiency with the reloadConfig being dispatched twice when "bellSoundURL" has changed as well.

* 1. Removed a file that contained a single function, referenced in only one place that is performing a fairly simple task.
2. Updated the "getBase64FileData" method to use "Buffer.from()" instead of "Buffer()" due to messages stating that "Buffer()" is deprecated due to security and usability issues.

* Adjustments and regression issues fixed

1. Updated the default config file to better explain the supported options for the "bell" config property.
2. Rearranged the bellSoundURL default property to make it easier to find should one decide to change the bell sound.
3. Typos fixed in comments.
4. Update fetchFileData to utilize the configData provided as function argument. There appeared to be no reason to reference different sources of config data within the same method.

* 1. Removed the "BELL_STYLE" constant since it was only being used in one place.
2. Updated comment block to accurately reflect the current logic and made the comment much more concise.
2019-10-03 02:08:40 +02:00
Brandon Lee Dring
5bc8e0b1e8 Feat/text search (#3075)
* Added persistent text box search

* Toggle search box now working

* Restyled search box

* Linter and bug squashing

* Added multi OS hotkey support

* PR changes as requested

* Added ability to use escape button to close search field

* Woops forgot key mapping on non mac platforms

* fixed bug where escape would open up search window

* Removal of unused vars that died in conflict
2019-09-23 19:37:22 +02:00
Zachary Riedlshah
970a98f60b fix: prettier fullscreen for macOS
fixes #5
2019-09-11 04:20:06 +02:00
Philippe Potvin
1127e8e7ae
Remove forgoten code (#3510) 2019-03-05 20:29:27 -05:00
CHaBou
b709a3a971
Add macOptionSelectionMode option (#3406)
Two possible value: 
* `'vertical'` (Default): enable column selection when Option key is hold
* `'force'`: force selection regardless of whether the terminal is in mouse events mode
2019-01-11 14:31:11 +01:00
Juan Campa
7a40fd7c97 WebGL renderer (using xterm.js fork) (#3368)
* Enabling webGL renderer

* Use @zeit/xterm fork of xterm

* Adding webGLRenderer config

* Fix linting issues

* Allow for hot-reloading of webGLRenderer

* Adding link to WebGL renderer issue we're working around

* Using NPM tarball instead of resolutions (which wasn't working

* Hard-coding selection color to white because nothing else is yet supported
2018-12-28 14:42:05 -08:00
Jarid Margolin
28f778037b Add scrollback option to config (#3038) 2018-05-29 12:11:21 +02:00
CHaBou
0199c44915
Fix double action on keymap after a reload (#3006)
Fixes #3004
2018-05-12 15:39:51 +02:00
Ricardo Amaral
a14c55640c Add letter spacing configuration option (#3002) 2018-05-10 12:54:00 +02:00
Brad Dougherty
bba14f6324 Add line height config (#2858)
Fixes #2858
2018-04-21 00:22:34 +02:00
Timothy
20173f0e86 Migrate styling to styled-jsx (#2761)
Fixes #2737
2018-03-17 13:51:36 +01:00
CHaBou
b73a328b6b Add fontWeight and fontWeightBold settings (#2669)
Fixes #2574
2018-02-14 14:09:02 +01:00
CHaBou
87d4c2b37e Fix selectAll command (#2436)
* Fix selectAll command

* Fix typo
2018-01-21 12:21:16 +01:00
CHaBou
dd780e6fe7
Xterm v3 integration (#2573) 2018-01-09 17:33:24 +01:00
CHaBou
1fbc85760b
Use same hazel endpoint to notify update to Linux users (#2497)
Add a pseudo auto-updater for Linux

Fixes #2476
2017-11-29 14:26:24 +01:00
CHaBou
81709073cf
Keymaps are now updated without restarting (#2455)
* Reload keymaps without restarting

* Reattach key listeners when config have changed
2017-11-15 00:55:21 +01:00
Ricky Miller
62e29effbf Add context menu (#2001) 2017-11-03 21:24:41 +01:00
CHaBou
2af575c3c0 Multiple keymaps and mousetrap (#2412)
* WIP

* WIP

* Wip

* Wip

* wip

* Refactor without normalize and plugin

* Replace extendKeymaps by decorateKeymaps

* WIP

* Add mousetrap

* Add first command over rpc

* More commands

* Add all commands

* Begin to hook commands

* Working multiple keymaps

* Use redux action to trigger command

* Use forked version of Mousetrap to capture key events

* Fix lint

* Add command in redux action to debug purpose

* ExecCommand from menu click

* Remove unused files

* Fix xterm should ignore catched events

* Re-enable IntelliSense checking

* Remove unused runes dep
2017-11-02 19:51:18 -07:00
CHaBou
14036e9094
Clean out old code 2017-09-18 22:20:34 +02:00
CHaBou
f8366d010d
Upgrade React to v16
* Introduce 2 base components: Component and PureComponent. Before, we have only PureComponent but it was impossible to add a shoulComponentUpdate method (used for Terms).
2017-09-16 21:21:50 +02:00
CHaBou
1155bb54b1
Add prettier and resolve all lint errors 2017-09-10 16:04:13 +02:00
CHaBou
944f9d7e89
Merge branch 'master' into xterm
* master: (62 commits)
  1.4.3
  Disable ia32 linux releases (#2164)
  Fixed writing composed characters (#2158)
  Doc: Add yarn install to contribute instructions (#2117)
  Change "Close Session" shortcut on Linux/Windows  (#2160)
  Notice for plugins (#2114)
  Updated dependencies to the latest version (#2146)
  1.4.2
  Reverted class names to as they were before (#2139)
  1.4.1
  AppVeyor environment variables are now on the platform (#2137)
  Brought back the icon for closing tabs (#2136)
  Brought back keymap documentation to the website (#2133)
  1.4.0
  Don't build on master, except for releases (#2132)
  Ensured that `async-retry` is added to the bundle (#2131)
  Ensure correct update channel is displayed in About window (#2130)
  Retry loading it if config doesn't exist in auto updater (#2129)
  Write contents of default config to hyper.js (#2128)
  Use a string for setting the update channel (#2127)
  ...
2017-09-03 22:18:43 +02:00
Leo Lamprecht
0ee4fb6104 Updated dependencies to the latest version (#2146)
* Bumped dependencies to the latest version

* Bumped root lockfile

* Bumped app dependencies

* Fixed linting

* No command line switch needed anymore for native async/await

* Fixed color error

* Bumped Node.js versions for CI

* Downgraded hterm-umdjs

* Try to fix the AppVeyor build

* Made colors work again
2017-08-31 15:20:39 +02:00
Guillermo Rauch
b302962d44 latest 2017-08-02 12:05:47 -07:00
Henrik
4ea3445464 add custom inner children (#1621) 2017-03-18 16:10:31 -07:00
Henrik
ade9ad39fd add configurable uifontfamily (#1549)
* add configurable uifontfamily

* rm uifontfamily config default

* fix uifontfamily conf default
2017-02-18 00:15:55 -03:00
Henrik
0ee48c9841 add hterm cursor blink support (#1547)
* add hterm cursor blink support

* update website with cursorblink doc
2017-02-17 21:11:23 -03:00
Liudas Dzisevicius
270fe5bef9 [Windows] Add right click copy/paste (#1247)
* Add right click copy/paste

* Add quick edit config option
2017-02-15 17:22:09 -03:00
Paul Betts
0ff1cb9584 Windows titlebar improvements (#1307)
* Make double-clicking on the titlebar work

* We don't actually need this

* Draw a Restore icon when the window is Maximized

* Update React State when BrowserWindow changes behind our back

* Cleanup

* Don't show the border if the window is maximized

* Fight with the linter
2017-01-10 21:45:49 -08:00
Matheus Fernandes
be286c0d5a Fix keyboard shortcuts on Linux and Windows (#1058)
* `command` => `mod`

* `Option` => `Alt`

* Allow hterm to consume a keyboard event only if it's not a Hyper accelerator

* Remove `console.log`s

* Say no to bikeshedding

* We already clear the selection on `onKeyDown`

* Add comments

* Remove meaningless comment

* Add fullscreen shortcut for Windows and Linux

* Use the accelerators defined in `accelerators.js` for the app menu
2016-11-30 15:19:45 -05:00
Matheus Fernandes
9c90e19760 Add Windows support and first-class Linux support (#946)
* `child_pty` => `pty.js`

* Create a frameless window on Windows and Linux

* Add a brand new UI for Linux and Windows 💅

* [Windows] Fix plugin installation

* [Windows] Fix the `build` script

* [Windows] Add a bigger `icon.ico`

* [Mac] Add `WebKitAppRegion: drag` when running on macOS

* Fix code style 🤔

* Add `appveyor.yml`

* Fix code style (again)

* [Windows] Fix AppVeyor's `install` script

* [Windows] Try a new AppVeyor config

* [Windows] Set the binary path so Spectron can run the tests

* [Windows] Try to build on x64

* Try again to build on x64

* Try one more time 😩

* Throw an error to indicate that `pty.js` was built incorrectly

* [Win/Linux] Add `display: hidden` to <Tabs /> if tabs.length === 1

* [Win/Linux] Reorganize SVGs – via @CodeTheory

* [Win/Linux] Fix the hamburger menu height

* Make the SVGs look better with `shape-rendering: crispEdges;`

* [Win/Linux] Add config options for the window controls and the 🍔 menu

* Add `electron-squirrel-startup` dependency

* [Win] Handle Squirrel commands

* [Win/Linux] Fix default color for the 🍔 and window controls – via @CodeTheory

* [Win/Linux] Add some padding - via @CodeTheory

* [Win/Linux] Add hover states – via @CodeTheory

* [Win] Fix empty window/tab titles

* [Win] Fix opening Preferences (#978)

* [Win] Fix opening Preferences

* Update ui.js

* Update ui.js

* Enhance messages and default editor

* [Win] Add dependency instructions to the README.md [skip ci]

* Fix code style

* [Win/Linux] Check the number of open windows before quitting the app
2016-11-11 15:18:04 -02:00
David Gómez
8f28573fc0 Prefer default export to make XO happy (#931)
* Comply with prefer-default-export rule for findBySession function

* Remove XO's prefer-default-export rule

* Comply with prefer-default-export rule for init function

* Comply with prefer-default-export rule for getRootGroups function

* Comply with prefer-default-export rule for INIT constant

* Comply with prefer-default-export rule for isExecutable function

* Fix default export for constants

* Comply with prefer-default-export rule for last function

* Comply with prefer-default-export rule for getColorList function
2016-10-25 14:53:15 +02:00
Daniel Bayerlein
aa285a8bc6 Cleanup (rename HyperTerm to Hyper) (#812)
* Rename container

* Rename hyper container itself

* Add HYPER_DEBUG for debug

* Rename HyperTerm to Hyper

* Rename HyperTerm connector and extension

* Add HyperTerm state and dispatch for backwards compatibility
2016-10-08 09:26:07 -07:00
David Gomez
c6b44d4a50 Remove no-danger rule from the package.json file 2016-10-07 08:29:41 +02:00
Guillermo Rauch
d01d3868eb simple version-based notifications system 2016-10-04 12:48:37 -07:00
Martin Ek
540414f59d split panes: set hotkeys based on OS (#771) 2016-10-04 08:33:21 -07:00
Martin Ek
a7595c1a45 Split Panes (#693)
* npm: add .npmrc with save-exact=true

* split panes: create initial implementation

This allows users to split their Hyperterm terms into
multiple nested splits, both vertical and horizontal.

Fixes #56

* split panes: suport closing tabs and individual panes

* split panes: ensure new splits are placed at the correct index

New split panes should be placed after the currently active
pane, not at the end like they were previously.

* split panes: add explicit dependency to uuid

* split panes: implement split pane cycling

This adds menu buttons for moving back and forward between
open split panes in the currect terminal tab.
Doesn't add a hotkey yet, needs some bikeshedding.

* split panes: move activeSessionUid to its own object

It made little sense to have so many objects with `activeSessionUid`
set to `null` when it only mattered on the top level.
Now it's an object mapping term-group `uid` to `sessionUid` instead.

* split panes: make sure closing the last split pane exits the app

* split panes: fix a crash after closing specific panes

Sometimes the terminal would crash when a specific
split pane was closed, because the `activeSessions`
mapping wasn't updated correctly.

* split panes: fix a bug that caused initial session sizing to be wrong

* fix all our focus / blur issues in one fell swoop :O (famous last words)

* get rid of react warning

* hterm: make sure not to lose focus when VT listens on clicks

* term: restore onactive callback

* add missing `return` to override (just in case)

* split pane: new split pane implementation

* goodbye react-split-pane

* added term group resizing action and reducer

* terms: supply border color so that we can use it for splits

* term-group: add resizing hook

* term-groups: add resizing constant

* remove split pane css side-effect

* split panes: pass existing hterm instances to Term

* split panes: add keybindings for split pane cycling

* split panes: remove unused action

* split panes: remove unused styling

* split-pane: remove `console.log`

* split-pane: remove `console.log`

* split panes: rebalance sizes on insert/removal

* split panes: pass existing hterm instances to Term

* split panes: add keybindings for split pane cycling

* split panes: remove unused action

* split panes: remove unused styling

* split panes: rebalance sizes on insert/removal

* split panes: set a minimum size for resizing

* split-pane: fix vertical splits

* css :|

* package: bump electron

* split panes: attach onFocus listener to webviews

* 1.4.1 and 1.4.2 are broken. they have the following regression:
- open google.com on the main window
- open a new tab
- come back to previous tab. webview is gone :|

* split panes: handle PTY exits

* split panes: add linux friendly keybindings
2016-10-03 19:00:50 -07:00
Aurélien Bottazini
a561f4650b Add Setting for modifier Keys cmdIsMeta and altIsMeta (#686)
* Adds Setting for modifier Keys cmdIsMeta and altIsMeta

* ModifierKeys setting for redux state

* removing from default config modifierKeys
2016-09-30 14:30:11 +02:00
Matheus Fernandes
1866104d03 [WIP] Use XO instead of Standard (#723)
* Bump `eslint-plugin-react`

* Add `eslint-config-xo-react`

* Add XO

* Remove eslint-related dependencies, add XO config and use XO as the linter

* Code style: Standard => XO 

* Use xo property to ignore files

* Fix remaining errors
2016-09-21 16:27:11 +02:00
Guillermo Rauch
8a01f8a48b Add window bgcolor updates (#524)
* transparent + reactive background colors

* refactor header to not set its own background color

* make terms not set background color

* dramatically improve tab borders

* remove background color from electron windows

* Revert "remove background color from electron windows"

This reverts commit ca4de3c5dc28095f1a598f7ac79d4dff4b66ccd5.

* put alpha first for electron

* remove initial bg color setting, but maintain reactive one

* fix
2016-09-19 08:47:33 +02:00
ppot
3813d27d5f Fix ScrollPort SelectAll 2016-08-20 17:25:04 -04:00
Philippe Potvin
fd351a5b93 Provide clear selection of text in terminal view (#608)
* Permit clearSelection on text enter and mouse selection. Fix #591

* Add config for copyOnSelect

* Update with descriptive comment
2016-08-13 23:03:44 +02:00
Ives van Hoorne
749d1f4681 Fix maximizing behaviour (#176)
* Fix maximizing and minimizing

* Emit via side effect in action creator

* Store window state in the store

* Move unmaximize for diff
2016-08-06 11:01:01 +01:00
Albin Ekblom
f954a1e7bc Add config for bell (#468)
* Add config for bell

* Use Set instead
2016-08-05 23:30:40 +01:00
Marc Bachmann
7a01ec77c4 Remove duplicated shortcut bindings (#445) 2016-07-26 16:36:19 -07:00
Guillermo Rauch
aaed99abac Reorg (#386)
* Step 1: move electorn into `app/`.

This is to comply with the suggested directory format of
`electron-builder`: https://github.com/electron-userland/electron-builder#two-packagejson-structure

* Step 2: add build directory with icon files for mac / windows

* Step 3: move all development (web) assets into main directory

* Step 4: add `build` namespace to dev `package.json`

* Step 5: move all dev dependencies into dev file and get rid of
old electron packagers in favor of `eletorn-builder`

* Step 6: target build inside `app/` as everything else is excluded at build time

* Step 7: remove old stuff!

* Step 8: update README

* turn off asar for `child_pty`
2016-07-24 10:59:21 -07:00