Commit graph

2086 commits

Author SHA1 Message Date
Oliver Blanthorn
269a37bef1
Fix #1114: move get_current_url to alias 2019-05-29 17:13:02 +01:00
Oliver Blanthorn
06b013b38e
Fix #1572: flip pref to make FF look for userChrome 2019-05-29 17:06:38 +01:00
Oliver Blanthorn
cef4c3f5d2
Remove unused declaration to cheer up linter 2019-05-29 15:49:43 +01:00
Oliver Blanthorn
e04ec2c0c3
Merge pull request #1617 from tridactyl/fix_hint_vimperator_space
hinting.ts: Fix #1615
2019-05-29 15:40:43 +01:00
Oliver Blanthorn
982455a1ef
Fix #1485: add shellescape command for native sanitisation 2019-05-29 15:29:47 +01:00
glacambre
dc32c55d74
hinting.ts: Fix #1615
What happened in https://github.com/tridactyl/tridactyl/issues/1615 was
that when pressing `<Space>`, tridactyl tried to run `hint.pushKey  `.
Since our ex command parser didn't care about whitespace, nothing
happened.
This is fixed by having a specific ex command to push `<Space>` the hint
filter.
2019-05-29 16:29:11 +02:00
Oliver Blanthorn
1aa954af55
Simplify error notifications
Not sure why we did it the old way, but it doesn't seem to break
anything. Errors caught on background pages no longer steal focus.
2019-05-29 14:34:16 +01:00
Oliver Blanthorn
50ce658d36
Merge branch 'fix_find_sucking' 2019-05-29 13:12:58 +01:00
Oliver Blanthorn
20721f4316
Throw errors and clear highlight on pattern not found 2019-05-29 13:12:38 +01:00
Oliver Blanthorn
969d13fa04
Prevent errors from stealing focus on normal pages
NB: errors on new tab page, our help pages etc. will still
steal focus
2019-05-29 13:02:56 +01:00
Anton Vilhelm Ásgeirsson
fd97c392ed Merge branch 'fix_find_sucking' of https://github.com/tridactyl/tridactyl into fix_find_sucking 2019-05-29 11:01:43 +00:00
Anton Vilhelm Ásgeirsson
4ec44c6991 Add "noh" exalias to clearsearchhighlight. 2019-05-29 10:53:09 +00:00
glacambre
1370746a3a
finding.ts: fix bugs found by antonva
On some websites, searching for specific strings could result in errors
because some matches did not have a rectangle (= they were hidden from
the page). This commit fixes that.
2019-05-29 11:40:48 +02:00
glacambre
96cc6f6100
finding.ts: Make find re-use last search pattern if needed 2019-05-29 10:01:53 +02:00
glacambre
d221ee6585
finding.ts: fix findnext not highlighting elements after nohlsearch 2019-05-29 09:48:16 +02:00
Oliver Blanthorn
f798492237
Merge pull request #1608 from tridactyl/fix_find_sucking
finding.ts: fix `:find` and `:findnext` sucking hard
2019-05-28 23:07:03 +01:00
glacambre
c65477486c
finding.ts: fix :find and :findnext sucking hard
This is a complete rewrite of `:find` and `:findnext`.
2019-05-28 23:37:33 +02:00
Saul Reynolds-Haertle
1e25e85c28 Fix recursion in repeat 2019-05-28 14:20:52 -07:00
Oliver Blanthorn
402763b41b
Fix #1303: make no_mouse_mode boring 2019-05-28 17:08:13 +01:00
Oliver Blanthorn
191d2da164
Merge pull request #1603 from tridactyl/typed_config_get
Add type checking to first arg of config.get
2019-05-28 13:20:28 +01:00
Oliver Blanthorn
f6794dbcce
Merge branch 'real_hint_mode' 2019-05-28 13:11:44 +01:00
Oliver Blanthorn
51c73d028e
Document hint mode binds 2019-05-28 13:08:48 +01:00
Oliver Blanthorn
905f0c50fe
Add unchecked gets for runtime usage.
Also make config.getAsync use the same type checking
and document a hitherto undocumented setting that it
surfaced.
2019-05-28 12:49:45 +01:00
glacambre
ce237daa3f
config.ts: Fix get completions
Before 7717c18, calling `config.get()` would result in target being an
empty array. After 7717c18, `config.get()` resulted in `target` being an
array containing one element, `undefined`. Since there isn't any
setting named `undefined`, get completions returned `undefined` and
completions gracefully failed.
We fix this by turning `target` into an empty array if `target_typed` is
undefined.
2019-05-28 12:58:23 +02:00
Oliver Blanthorn
46519e3a5f
Update dev diary 2019-05-28 11:42:24 +01:00
glacambre
f050f68740
Turn hint mode into a real mode
This commit turns hint mode into a real mode. This required several
changes:
- In `src/content/hinting.ts`: create a function named getHintCommands
  which returns an object containing functions that can be used as ex
  commands.
- In `src/content/hinting.ts`: rewriting the `parser` function to have
  it check the `hintmaps` object in the config and trigger these if
  they're bound to anything. We can't use a generic parser because
  vimperator hints need to catch every single keypress, even the ones
  that aren't bound to anything and act on them.
- Creating `src/background/hinting.ts`, which just wraps ex commands
  from src/content/hintings.ts in a proxy which will forward calls to the
  content script.
2019-05-28 12:41:40 +02:00
Oliver Blanthorn
b098e760e9
Merge branch 'vlmarek-master' 2019-05-27 19:37:57 +01:00
Oliver Blanthorn
ede58e479c
Make hint -f case insensitive 2019-05-27 19:37:41 +01:00
Oliver Blanthorn
7717c18e92
Add type checking to first arg of config.get
Also document noiframeon, which I discovered was undocumented
because of the type checking.

It makes splatted config.gets rather uglier with `...args` ->
`args[0] as keyof config.default_config, args.slice(1)...`.

It has apparently also broken config completions.
2019-05-27 19:27:52 +01:00
Oliver Blanthorn
7b6508a3e1
Fix #1185 - add blacklistkeys setting 2019-05-27 18:57:36 +01:00
glacambre
233a94cd80
config.ts: make getURL check site-specific defaults too
This makes site-specific defaults override global settings set by the
user.
2019-05-27 17:55:59 +02:00
Oliver Blanthorn
4b515ec6d3
Add default subconfig for followpagepatterns www.google.com
This doesn't currently work - it looks like only subconfigs in user config
are considered. Probably need to use mergeDeep somewhere.
2019-05-27 15:21:29 +01:00
Oliver Blanthorn
afbf4e2e50
Prevent bmark from guessing title for manually specified URLs 2019-05-27 14:47:47 +01:00
reversebreak
6a15b99c2e
Make bmark use page title if none is supplied 2019-05-27 14:13:32 +01:00
Vladimír Marek
76f7100987 Add RegExp capability to text filtered hinting 2019-05-27 14:57:07 +02:00
Oliver Blanthorn
26343e5a5d
Fix #930: make in-browser versions match ex-browser
Additionally, change the 'default' build to be a beta build
in the manifest, and give stable releases prettier version
numbers.
2019-05-27 12:59:25 +01:00
Oliver Blanthorn
360705704b Fix #1492 negated bool 2019-05-27 12:21:35 +01:00
Oliver Blanthorn
81b5639084
Merge branch 'fix_taball_moving_to_wrong_tab' 2019-05-27 10:57:37 +01:00
Oliver Blanthorn
b61569c167
Merge pull request #1593 from saulrh/deprecated-browser-extension-getURL
browser.extension.getURL -> browser.runtime.getURL
2019-05-27 10:48:00 +01:00
Oliver Blanthorn
03f326cf40
Merge branch 'fix_pages_autofocusing_elements' 2019-05-27 10:47:34 +01:00
Oliver Blanthorn
db7eb12ca6
Make focus prevent loop more CPU friendly; uncouple from allowautofocus 2019-05-27 10:47:04 +01:00
glacambre
486958f7fc
excmds.ts: Fix taball moving to tab in wrong window
This commit fixes a bug reported by cmcaine. The issue was that when you
have multiple windows on multiple workspaces, taball wouldn't switch
focus to the right tab. This happened because taball relied on
browser.windows.update(id, {focused: true}) having switched to the right
window before calling idFromIndex. This didn't always work because
sometimes window managers will keep the current window focused.
2019-05-27 10:16:06 +02:00
Saul Reynolds-Haertle
031883e85c browser.extension.getURL -> browser.runtime.getURL
Function is deprecated:
https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/API/extension/getURL

Replacement has essentially identical functionality:
https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/API/runtime/getURL

I'm sure that there's _some_ difference between the "path in install
directory" and "path relative to manifest.json", but I don't think
that we're going to be the ones running into it.
2019-05-26 22:03:34 -07:00
Oliver Blanthorn
787f519494
newtab: add dev diary 2019-05-27 00:04:14 +01:00
glacambre
fff155e142
content.ts: Fix pages autofocusing elements
Some pages manage to focus a hidden input field on page load. This puts
tridactyl in insert mode without the user being aware of it. This commit
actively protects users who set `allowautofocus` to "false" against
this.

Closes https://github.com/tridactyl/tridactyl/issues/1492
2019-05-27 00:40:58 +02:00
Oliver Blanthorn
05ca6fc68e
Fix #749: remove 'new features' from private window new tab page 2019-05-26 23:30:04 +01:00
Oliver Blanthorn
92a0dbbc2a
Merge branch 'fix_scrolling_infinite_loops' 2019-05-26 17:57:30 +01:00
glacambre
b47d3928a1
scrolling.ts: fix infinite scrolling loops
Should close https://github.com/tridactyl/tridactyl/issues/1247
2019-05-26 18:45:53 +02:00
Colin Caine
9714dd0ce2 hinting: document pipe() and pipe_elements() 2019-05-26 11:46:51 +01:00
Colin Caine
d0a0e79e35 hinting: improve hint -f help 2019-05-26 11:46:51 +01:00