Commit Graph

108 Commits

Author SHA1 Message Date
Peter Cai
0ac8437387 term: fix password input on Chrome for Android
1. Also force focus on inputHelper on keyup on Android
2. Clear the inputHelper immediately upon receiving input
2018-06-03 20:58:39 +08:00
Peter Cai
866b56b682 term: bring back touch simulation of special keys on mobile
and also fixed it. The original version did not work because it tried
to change read-only fields of the event, which is not allowed.

The last commit removed support of touch simulation of Ctrl and Alt
by removing the `virtual_input.coffee` file. This commit brings it back
with a better implementation.
2018-06-03 20:10:24 +08:00
Peter Cai
4d87059872 remove unneeded virtual_input
We have already introduced a virtual textarea for every platform.
This one seems redundant.

However, some features may still not work perfectly on a mobile browser
2018-06-03 18:03:23 +08:00
Peter Cai
5bbe456496 term: remove redundant events of inputHelper and redundant contentEditable
We do not need to listen for keydown and keypress for inputHelper because these events will propagate through the parent.
Listening them will be redundant and will cause some shortcut key combinations to stop working.

Since we now have a hidden `textarea`, there is no longer need to set anything to contentEditable
2018-06-03 17:51:16 +08:00
Peter Cai
5b9cc257a8 term: do not re-focus on keyup when on mobile
Doing this will mess up the mobile browsers.
Although we still don't support mobile browsers very well, this can at least make it usable on them.
2018-06-03 12:19:43 +08:00
Peter Cai
34b6287e0c term: complete support for IME & CJK rendering
this fixes #75 and #47, two bugs originated long long ago.

1. Added support for IME events `compositionstart` `compositionupdate` and `compositionend`.
2. Refactored some code to receive input events from a hidden textarea just as how `xterm.js` now does. This removes the need to set `contentEditable` on the body in order to receive IME compistion events, and also guides the IME input box correctly following the cursor.
3. Fixed CJK rendering. Forces "forceWidth" mode with double width on those known CJK ranges in Unicode. Corrected the placeholder logic of the force width mode. Note that some rare halfwidth CJK characters will still not render correctly without `force-unicode-width` enabled. If you see any issue, please enable the `--force-unicode-width` option.
4. Miscallaneous fixes for some problems after introducing the above change

Tested on Firefox Nightly 62 on Linux and Chromium 67 on Linux, with `fcitx` as input method.
2018-06-03 10:27:49 +08:00
Florian Mounier
92633f52ce Fix unescaping entities when linkifying 2017-11-23 14:56:18 +01:00
Florian Mounier
bdc1c7a80d Add a Makefile. Lint code. Fix butterfly open. Add a CHANGELOG.md 2017-05-02 17:59:52 +02:00
Florian Mounier
729c768dc2 Happy new year (a bit late) 2017-02-13 11:16:59 +01:00
Florian Mounier
964fd07143 uuid4 from Math.random is a security flaw 2017-02-13 10:45:31 +01:00
Florian Mounier
8553bbd0cb Typo 2017-02-13 10:37:04 +01:00
Florian Mounier
e4ce69a967 Fix keyboard selection 2016-11-28 14:38:49 +01:00
Florian Mounier
b0e1f37cac Interesting Fixes 2016-10-13 17:45:12 +02:00
Florian Mounier
da659b7526 Fix selection 2016-10-13 16:25:18 +02:00
Florian Mounier
3624962d3c Historize by ext 2016-10-13 16:11:44 +02:00
Florian Mounier
b9f1727f1e Finally a near perfect resize 2016-10-13 15:24:57 +02:00
Florian Mounier
5a7c4da0b1 Unoptimized but working dom creation 2016-10-13 12:41:31 +02:00
Florian Mounier
fa2b9d2bee Rework refresh 2016-10-13 10:03:15 +02:00
Florian Mounier
3bb6da1eae Fix ctl 2016-10-11 11:22:09 +02:00
Florian Mounier
6c827206f7 Merge branch 'master' into 2ws 2016-10-07 11:32:15 +02:00
Florian Mounier
d0eb37765a Limit rate on paste 2016-10-07 11:30:59 +02:00
Florian Mounier
8dffb02980 Merge branch 'master' into 2ws 2016-10-07 09:59:14 +02:00
Florian Mounier
7d7f05e164 Fix scroll 2016-09-29 17:15:38 +02:00
Florian Mounier
97d435ce18 Add horizontal wrap (expandable no wrapping lines) on decset 77 2016-09-29 11:39:49 +02:00
Florian Mounier
2887f6e25a Linkify as an extension. Finally fix #97 2016-09-28 17:42:23 +02:00
Florian Mounier
1d324ed243 Wait a bit on close 2016-08-19 17:46:15 +02:00
Florian Mounier
3c2bf35b09 Fix most of things 2016-08-19 17:42:36 +02:00
Florian Mounier
fe258f44f8 Add a ctl ws, base all session on a session key. 2016-08-19 14:48:51 +02:00
Florian Mounier
fe01ffb2b4 Fix keyup 2016-08-08 11:19:54 +02:00
Florian Mounier
ac7e9bef8e Remove throuput control and use the pause/break key to prevent flood. 2016-08-08 11:12:22 +02:00
Florian Mounier
503de38429 Add uri_root_path option. References #104. 2016-06-13 16:15:57 +02:00
Florian Mounier
c0e2d8959b Merge #94 2016-01-18 10:19:01 +01:00
Florian Mounier
056fbc02b1 Fix home/end 2016-01-18 10:05:50 +01:00
Florian Mounier
28ebf9d8a2 Clear scrollback on hard reset 2015-10-27 16:23:37 +01:00
Florian Mounier
5714b97c77 Get the session for current user only for env far fetch. Work on readme for 2.0 2015-10-20 14:53:25 +02:00
Florian Mounier
a9c35d91f1 Add geolocation 2015-10-19 15:01:11 +02:00
Florian Mounier
84c4ff9414 Avoid broken image at launch on abstract image 2015-10-19 10:25:36 +02:00
Florian Mounier
4e4d54de1f Fix cursor blur. Fix scrollLock on focus/blur. Rework binaries. 2015-10-16 15:58:32 +02:00
Florian Mounier
7b37716177 Add themes as a submodule and handle both builtin themes and local themes. 2015-10-14 13:19:52 +02:00
Florian Mounier
2d554483e1 Fix send 2015-10-13 11:49:14 +02:00
Florian Mounier
fc5879f2d4 Try fixing session size 2015-10-13 11:40:32 +02:00
Florian Mounier
7371b8b4e1 Fix force close with warning 2015-10-13 10:01:53 +02:00
Florian Mounier
71820849eb Add a shortcut to open a new tab 2015-10-12 17:50:21 +02:00
Florian Mounier
9c36b0c8c1 Add active line class 2015-10-09 12:02:31 +02:00
Florian Mounier
0f36db5264 Fix firefox popup with content editable. 2015-10-08 14:18:35 +02:00
Florian Mounier
834200256c Fix bopen/bsession. 2015-10-08 13:58:56 +02:00
Florian Mounier
96606d2b0b Add session list 2015-10-08 12:56:56 +02:00
Florian Mounier
38a4c4083d Rework style paradigm 2015-10-08 11:37:48 +02:00
Florian Mounier
c937a8753d Add a regex on notif handler + an ansi cleaner 2015-10-07 18:25:39 +02:00
Florian Mounier
7916014854 Copyright bump 2015-10-07 16:40:50 +02:00