Commit graph

404 commits

Author SHA1 Message Date
Labhansh Agrawal
ff0956cb18 add xterm unicode 11 addon 2020-06-23 17:21:23 +02:00
Labhansh Agrawal
d0e954def5 typing improvements 2020-06-19 22:12:42 +02:00
Labhansh Agrawal
a86c9c215e Fix ts error 2020-05-29 10:59:42 +02:00
Vassiliy Shvetsov
ffd4eb46e3 add web-link activation modifier 2020-05-25 13:11:17 +02:00
Labhansh Agrawal
6debd1e7f2 add config types 2020-04-27 22:53:49 +02:00
Labhansh Agrawal
bad51f9c15 prefer optional chain 2020-04-27 15:48:21 +02:00
Labhansh Agrawal
8d4ed96d89 add link handler to use shell.openExternal 2020-04-27 15:48:08 +02:00
Labhansh Agrawal
f7c19ce086 Bump xterm from 4.4.0 to 4.5.0 2020-04-13 12:08:16 +02:00
Labhansh Agrawal
41b1ac1852 fix prettier errors 2020-03-25 17:12:51 +01:00
Labhansh Agrawal
73e45f51f0 add command handler to uncatch keyboard event if search is closed 2020-03-25 13:29:12 +01:00
Labhansh Agrawal
78ec88d1e8 port remaining js components to ts 2020-03-18 20:21:30 +01:00
Labhansh Agrawal
4a3132b8e7 port notifications component to ts 2020-03-17 22:55:25 +01:00
Labhansh Agrawal
57fd125b5c port term-group component to ts 2020-03-16 16:54:17 +01:00
Labhansh Agrawal
579d0877f0 Remove usage of legacy and soon deprecated lifecycle methods 2020-03-15 19:31:36 +01:00
Simon Ábris
4cc864136f group all tab_icon css together 2020-03-14 18:59:20 +01:00
Simon Ábris
f0aabad2c4 remove js tab hover tracking and do it from css 2020-03-14 18:59:20 +01:00
Labhansh Agrawal
6801460912 port notification and split-pane component to ts 2020-03-14 18:58:45 +01:00
Labhansh Agrawal
5bb0b37682 port some components to ts 2020-03-10 14:54:36 +01:00
Labhansh Agrawal
fe6ddc8a2b remove unnecessary componentWillUnmount from header 2020-03-09 17:02:45 +01:00
Labhansh Agrawal
5e9fbbb620 typings improvements 2020-03-07 16:42:38 +01:00
Labhansh Agrawal
039b90aa65 Remove unnecessary eslint-disable directives 2020-03-03 00:24:12 +01:00
Labhansh Agrawal
01ea81823e Bump @types/uuid from 3.4.7 to 7.0.0 and fix breaking changes 2020-03-02 17:38:50 +01:00
Labhansh Agrawal
955566f6bf update typescript to 3.8.2 2020-02-21 17:25:18 +01:00
Labhansh Agrawal
c337288efa Improve containers typings and add prop types 2020-02-19 19:35:13 +01:00
Labhansh Agrawal
64249f389d update onCursorMove to match changes in xterm 2020-02-12 15:28:23 +01:00
Labhansh Agrawal
734701c5e7 Fix split view issue 2020-02-11 18:37:12 +01:00
Labhansh Agrawal
943186a51c add back the useCapture option in mousetrap 2020-01-15 18:06:25 +01:00
Labhansh Agrawal
9485b3297e add/update action creators types 2020-01-02 21:11:35 +01:00
Labhansh Agrawal
c0b72f9939 rename remaining js files in lib/actions to ts 2020-01-02 21:11:35 +01:00
Labhansh Agrawal
1b70f9e727 add Hyper Dispatch type 2020-01-02 21:11:35 +01:00
Labhansh Agrawal
7355d871d5 rename lib/store/*.js to ts 2020-01-02 21:11:35 +01:00
Labhansh Agrawal
c71b24ebea improve reducer typings 2019-12-30 23:40:56 +01:00
Labhansh Agrawal
38c534b3aa Add action types 2019-12-29 15:55:53 +01:00
Labhansh Agrawal
f40496f127 remove unused code (#4117) 2019-12-28 15:10:33 -05:00
Labhansh Agrawal
41d70c3a15 Fix babel scope tracker error on build 2019-12-21 15:09:12 +01:00
Labhansh Agrawal
0381f392de use ts project references, remove forkTsChecker 2019-12-13 21:47:22 +01:00
Labhansh Agrawal
58804a2d5b port es5 code to es6 2019-11-29 22:09:10 +01:00
Labhansh Agrawal
4e0fc48ec6 convert manual bind to arrow 2019-11-27 13:49:51 +01:00
Labhansh Agrawal
ac782f382b remove getLastTermIndex 2019-11-25 09:44:30 +01:00
Labhansh Agrawal
0721c4c1d0 remove onURLAbort prop (#4002) 2019-11-24 11:52:38 -05:00
Labhansh Agrawal
f0b92cb8be Fix lint errors 2019-11-20 23:33:22 +01:00
Labhansh Agrawal
a1eb84d8a7 port js files in lib and lib/containers to ts (#3957)
* rename files in lib and lib/containers to ts

* add types

* fix ts errors
2019-11-11 16:21:42 +01:00
hector
7074cbe29b Expose focusActiveTerm function to window 2019-11-02 17:21:31 +01:00
Benjamin Staneck
03ff483bea add TODO comments for the new Electron async APIs that replace the remote module 2019-10-25 15:34:56 +02:00
Labhansh Agrawal
d232ec27c0 Typings fixes in terms and sessions 2019-10-20 22:20:05 +02:00
Labhansh Agrawal
537c746c75 porting files in lib/ actions, reducers and utils/plugins to ts (#3887)
* add type definitions

* rename files in lib/actions

* rename files from lib/reducers to ts

* renamed plugins.js to ts

* Add hyper types

* Fix ts errors in lib/reducers

* Fix ts errors in lib/actions

* Fix ts errors in plugins.ts
2019-10-19 18:59:56 +02:00
Labhansh Agrawal
27c9cc3892 Update redux devtools usage syntax 2019-10-19 13:46:48 +02:00
Jason Gauci
71953e0fdf Allow plugins to set the parent/predecessor of a new session (#3723) 2019-10-15 02:09:30 +02:00
Labhansh Agrawal
d2a318d48b Fix ts errors in lib/utils 2019-10-13 03:39:33 +02:00
Labhansh Agrawal
187897a1f0 Add hyper types 2019-10-13 03:39:33 +02:00
Labhansh Agrawal
5af8fa021f rename files from lib/utils to ts 2019-10-13 03:39:33 +02:00
ivan
97242c5d78 fix closing tab containing multiple panes 2019-10-13 03:09:23 +02:00
Labhansh Agrawal
cd655ad1e6 Fix undefined resizeObserver error during split 2019-10-12 16:48:47 +02:00
Labhansh Agrawal
3eaf743b5a Fix getters in index.js 2019-10-12 16:04:21 +02:00
Labhansh Agrawal
621a785252 port lib/constants to ts 2019-10-11 19:55:54 +02: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
Labhansh Agrawal
7874fa813a add setup to compile ts files to compiled_app folder 2019-10-08 21:42:51 +02:00
Donald Green
f07963f930 Bug fixes for bell configuration (#3850)
* 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.

* 1. Add null safety check on `configInfo.bell` if the config file does not contain this property.
2. Default bellSound to null if the file specified by the filepath in `configInfo.bellSoundUrl` failed to be read. This helps prevent a repeated error being thrown by the xterm instance.
3. Updated `term.js` to use componentDidUpdate in place of the UNSAFE lifcycle method `componentWillReceiveProps`. I found that this unsafe lifecycle was never being fired, which lead to the terminal never responding to configuration changes. Without this change, the custom bell sound was never being loaded into the xterm instance.
2019-10-08 17:13:35 +02:00
Benjamin Staneck
2cc4c9e1ef
Update xterm to v4 (#3830)
* update xterm to 4

* add back webGL addon

* remove ligatures xterm addon, unused atm and does not work with webGL renderer

* update node-pty

* more work on trying to get xterm4 to work

* update xterm to 4.0.2

* move where xterm addon props are assigned

* more updates

* only load webgl addon if webgl is enabled

* fix search function

* remove rendererType setting, the xterm addon does this for us

* use xcode 10.3 on circleci

* fix typo

* revert node-pty bump for now

* use stable versions of the xterm plugins

* fix focus listener

* add windowsMode prop

* move webGL check

* apply tweaks by @GitSquared

* fix resizing issue

* Revert "fix resizing issue"

This reverts commit fce3780b038d69378f63bdfbfa613f20130fad34.

* apply review suggestions

* change so all addons have separate instances for each terminal

* update yarn-standalone to 1.19

* fix resize problem of split view

by @ivanwonder

* apply review feedback

* fix lint

* add name and version to package.json

* address review feedback

* more review feedback
2019-10-06 20:51:56 +02:00
Benjamin Staneck
850c66d1b6 run linter 2019-10-03 04:04:43 +02:00
Labhansh Agrawal
b52d8152bf Upgrade eslint to v6 and add TypeScript linting (#3843)
* Upgrade eslint to v6 and add TypeScript linting

* Fix pr checks


Co-authored-by: Benjamin Staneck <Stanzilla@users.noreply.github.com>
2019-10-03 02:56:50 +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
Labhansh Agrawal
5158417eb0 fix search addon import (#3833) 2019-09-25 09:40:50 -04: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
Sam D
88da6cd3d9 fix/remove indented empty lines 2019-09-23 19:23:41 +02:00
Sam D
af68171528 Fix middle mouse click tab close (#2230) 2019-09-23 19:23:41 +02:00
Labhansh Agrawal
8524d37f9e Port array.js and file.js to typescript 2019-09-23 17:55:53 +02:00
Zachary Riedlshah
970a98f60b fix: prettier fullscreen for macOS
fixes #5
2019-09-11 04:20:06 +02:00
Frux
26846cd847 fix handling ssh link with empty user (#3521) 2019-04-02 14:09:00 -04:00
ArtBIT
72bc73ea76 Fix cols/rows in cursorFrame returned by onCursorMove (#3547)
Fixes #3542
2019-03-27 09:41:28 +01:00
Philippe Potvin
1127e8e7ae
Remove forgoten code (#3510) 2019-03-05 20:29:27 -05:00
Kaushik Asp
90e8c1a766 Fix hanging when zoom out goes below 5px (#3509)
Fixes #3498
2019-03-05 23:42:54 +01:00
Philippe Potvin
d0f03f52e5
url are now interpreted by xterm (#3507)
* url are now interpreted by xterm

* no need

* .DS_STORE banished

* remove from reducer
2019-03-03 13:13:50 -05:00
Philippe Potvin
1747c57bc3 Expose active window positon on move to reducer (#3470) 2019-02-27 00:22:52 +01:00
onecamp
8733ecc84a
Display the renderer type in the About dialog (#3441)
* Now displaying the renderer type in the About dialog

* Show the number of renderers per type in the About dialog

* Use values instead of entries (key is unused)

Co-Authored-By: onecamp <juancampa@gmail.com>
2019-01-24 18:46:39 -05:00
Igor Sadikov
0dc8fb9ed4 Restore termRef to avoid breaking change (#3437) 2019-01-24 16:02:34 -05:00
onecamp
fa2c9d6423
Verify that webgl2 is supported before using it (#3435)
* Verify that webgl2 is supported before using it

* First check if WebGLRenderingContext exists at all

* Move webgl warnings to getTermOptions
2019-01-24 14:22:53 -05:00
onecamp
519ca3e651
Fix webgl config (#3407)
* Fix location of webGLRenderer flag in default-config.js

* Fix incorrect check of webGLRenderer flag

* Explain that disabling WebGL enables transparent backgrounds

Co-Authored-By: juancampa <juancampa@gmail.com>

* Only use WebGL if background is opaque

The hardcoding to white was also removed in favor of a temporary hack in
xterm.js that uses either white-over-black or black-overwhite to
maximize contrast with the background color
2019-01-21 19:09:18 -05:00
Igor Sadikov
ea3e109fbb Fix and simplify resize handling using ResizeObserver (#3411) 2019-01-21 20:34:23 +01:00
Igor Sadikov
3881703e01 Fix xterm.js resource leaks in split pane (#3409) 2019-01-18 23:58:09 +01: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
Umberto Lentini
ba93421933 Fixed file paste (#3383)
Fixes #3340
2019-01-06 15:55:16 +01:00
Jakub Chatrný
a3db3670be Add div wrappers around window controls svg elements (#3392)
Fixes #3372
2019-01-06 15:53:10 +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
Juan Campa
dd68286c5f Upgrade Electron to v4 (#3329)
* Bumping electron to 3.0.10

* Updating node version in travis and appveyor

* Fixing incorrect require of electron-fetch

* Fix zoom to match previous versions

Additionally I'm removing a call to disable pinch-zoom, it's disable by
default since Electron 2 (https://electronjs.org/releases#2.0.0)

* Bumping electron to 4.0.0-beta.8

* Bumping electron to 4.0.0-beta.9

* Work around for Copy accelerator not firing on electron v4

* Fixing header/titlebar in MacOS

* Upgrading to electron 4.0.0 and node-pty 0.8.0

* Adding yarn.lock changes for electron 4.0.0

* Adding comments for editor:copy workaround. Scaling issue is only on Linux

* Upgrading node-abi to support electron 4.0.0

* popup now takes an object as input
2018-12-25 18:15:25 -08:00
CHaBou
6fc24376a2
Fix onCursorMove Term handler (#3330)
Fixes #3317
2018-12-15 22:30:58 +01:00
CHaBou
f3a2f0211d Update xterm to v3.8.0 (#3255) 2018-12-06 15:56:29 -08:00
Prashant Andani
436c37e89e Code cleanup (#3131) 2018-10-13 16:35:51 +02:00
CHaBou
bc6101e98f
Fix module hijacking (#3067)
Regression was introduced by #2866. Release version of Hyper failed to start.
2018-06-11 08:43:57 +02:00
Jarid Margolin
28f778037b Add scrollback option to config (#3038) 2018-05-29 12:11:21 +02:00
Jiahao Lu
16f163daf3 Adjust clickable region of control buttons (#3017)
On Windows, the close button (rather than the border) is expected to be hit when someone clicks the top-right corner of the screen if a window is maximized.
2018-05-23 22:59:19 +02:00
Timo Welde
f75895a176 Fix plugin module hijacking on main process (#2866)
Fixes some plugin loading (like hyperline)
2018-05-15 15:58:36 +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
Sonny
f64e3e0204 Adding ability to send error object to notify() (#2955) 2018-05-02 10:10:44 +02:00
Brad Dougherty
bba14f6324 Add line height config (#2858)
Fixes #2858
2018-04-21 00:22:34 +02:00
Timothy
b680b9e02e Improve update notification contrast (#2791) 2018-04-20 17:03:34 +02:00
CHaBou
f40e32358d
Use xterm winptyCompat addon (#2811)
See https://github.com/xtermjs/xterm.js/pull/1096
2018-04-05 23:53:21 +02:00
CHaBou
f5d48ee38a
Use xterm webLinks addon (#2810)
Fixes #2809
2018-04-05 22:45:18 +02:00