mirror of
https://github.com/vale981/tridactyl
synced 2025-03-06 01:51:40 -05:00
Make :hint -y
more sensible
* Only hint Anchors that have a meaningful `href` * Properly `yank` instead of going through the excmd parser
This commit is contained in:
parent
d9eecafc59
commit
34f483d967
1 changed files with 2 additions and 2 deletions
|
@ -4427,10 +4427,10 @@ export async function hint(option?: string, selectors?: string, ...rest: string[
|
|||
case "-y":
|
||||
// Yank link
|
||||
selectHints = hinting.pipe(
|
||||
DOM.HINTTAGS_selectors,
|
||||
'a[href]:not([href="#"])',
|
||||
elem => {
|
||||
// /!\ Warning: This is racy! This can easily be fixed by adding an await but do we want this? yank can be pretty slow, especially with yankto=selection
|
||||
run_exstr("yank " + elem.href)
|
||||
yank(elem.href)
|
||||
return elem
|
||||
},
|
||||
rapid,
|
||||
|
|
Loading…
Add table
Reference in a new issue