aboutsummaryrefslogtreecommitdiffstats
path: root/content_scripts
AgeCommit message (Collapse)Author
2018-10-28fix a small typo that attachShadow needs an argumentgdh1995
2018-10-28use Shadow DOM v1 if it existsgdh1995
Chrome 70 has deprecated Shadow DOM v0 and displayed a warning when it's used. And accroding to https://www.chromestatus.com/features/4507242028072960, Shadow DOM v0 will be removed since Chrome 73. The support for Shadow DOM v1 has been there since Chrome 53 and is enabled by default on Firefox 63, so it's time to use it. Old support is still needed because Vimium's min_chrome_version is 51.
2018-10-06Do not try to findNext unless we actually have query text.Stephen Blott
Fixes #3154 (I think).
2018-09-29Merge pull request #3111 from gdh1995/use-scroll-byStephen Blott
use Element::scrollBy if it exists
2018-09-05"Make yf strip any leading "mailto:".Stephen Blott
When yanking an email URL with `yf`, it's likely to be more useful to strip the leading "mailto:". Fixes #3123.
2018-09-04Revert "Add special-case rule for GMail."Stephen Blott
This reverts commit aff380669445594e7566a835d4b27f11da26ea6a. This breaks scrolling on Twitter. Needs more thought.
2018-09-04Use function directly.Stephen Blott
If Vimium becomes disabled, then we remove this listener. So we better add the actual function we want to (later) remove, rather than creating a new function (which will never be removed.
2018-09-04Add special-case rule for GMail.Stephen Blott
This selects the body of a message, if such is displayed.
2018-09-04Tweak #3119.Stephen Blott
1. Use verb phrase for function name. 2. Add `Scroller.reset()` method. This *only* resets the activated element. 3. Reset the scroller only if the URL has changed. (Previously, in #3119, the scroller was also being reset when the tab gained the focus.) Based on a suggestion from @marcotc.
2018-09-04Refactor, part 1Marco Costa
2018-08-31Handle scrolling on Reddit redesignMarco Costa
2018-08-27use Element::scrollBy if it existsgdh1995
2018-08-23Tweak Twitter CSS selector.Stephen Blott
2018-08-23Site-specific hack to make expanded tweets scrollable.Stephen Blott
Twitter is an important site and Vimium's scrolling is currently broken when a tweet is expanded. In my opinion, the existing bahviour is so bad and that a site-specific hack is warranted. Fixes #3045.
2018-08-13Cache keydown events while launching link hints.Stephen Blott
Launching link hints can sometimes be slow. For filtered hints, the user already knows what to type - but must nevertheless wait until the hints have been calculated and rendered. Here, we cache intervening keydown events, and replay them once hints-mode proper is launched. This should make improve usability (in the case of filtered hints). Fixes #3050.
2018-06-15Use hash (too) for local marks.Stephen Blott
First, I *very rarely* use local marks. They just don't seem as useful in a browser as they are in a text editor. However, on a page like GMail, I do often want to jump back and forward between my labels. These are different locations hashes (anchors). The idea here is to make local marks useful for this case. If the scroll positions (X and Y) are both 0, and the hash (anchor) is present in the mark and non-empty, then change the hash instead of scrolling. On first tests, this appears to work nicely for changing labels in GMail. I'm sure there are other uses. This change shouldn't interfere with use cases where the user has scrolled within the page.
2018-04-01Disable click listener detection and bump to v1.63.3.v1.63.3Stephen Blott
2018-02-23Do not search in all frames.Stephen Blott
Chrome has never searched in all frames, so this is no loss. However, find on Firefox Quantum is now broken with the "all frames" flag set. Fixes #2962. H/t: @gdh1995 (https://github.com/philc/vimium/issues/2962#issuecomment-367991086).
2018-02-13Make the reload command accept a count.Stephen Blott
Move the `reload` command to the background page and make it accept a count prefix. Fixes #674. Althought the demand for this is low and the use cases limited, it is a very vim-ish extension to the existing command.
2018-02-05Create flash frame Shadow DOM element on demand.Stephen Blott
It looks like we'll be initialising the Vomnibar on demand (see #2939, merged). In this case, we should also initialise the flash frame on demand. This means that *none* of Vimium's UI elements are now created until they are needed.
2018-02-04Merge branch 'gdh1995--hook-to-string'Stephen Blott
This is #2941.
2018-02-04Tweak #2941.Stephen Blott
2018-02-04make the hooked addEventListener looks nativegdh1995
2018-02-04Merge pull request #2939 from smblott-github/disable-preload-vomnibarStephen Blott
Disable pre-loading of Vomnibar iframe.
2018-02-04Remove \I (ignore case) flag for find mode.Stephen Blott
It appears that nobody is using this (and it is broken). So this PR removes this feature. Fixes #2937 (kind of).
2018-02-04Disable pre-loading of Vomnibar iframe.Stephen Blott
Pre-loading the Vomnibar iframe seems to be causing some issues with the dev console. This PR disables pre-loading of the Vomnibar. I'm going to try this out for a while. If it doesn't seem to sluggish, then I'll merge it.
2018-01-19Fix bug on hashchange event.Stephen Blott
This handler is undefined at the point that it is installed. The definition is at the bottom of the file.
2018-01-10Fix issue referenceFlorian Bruhin
This sounds like #2035, #2305 is unrelated.
2017-12-18Do not use vimiumOnClickAttributeName variable...Stephen Blott
... use literals instead. For some reason, on Firefox, using `vimiumOnClickAttributeName` was causing link hints to fail silently (on Facebook). It's not at all clear why this was happening. Simply repeating the literal fixes the issue. Fixes #2879.
2017-12-18Tweak hint scoring for filtered hints.Stephen Blott
This tweaks the scoring of hints for filtered hints. Specifically, it scores matches at the start of the text or the start of a word higher than whole-word matches. This is intended avoid the phenomenon whereby adding matching characters to the filter causes the selected hint to change.
2017-12-16Guard against failure.Stephen Blott
Since these are executing in the page's context, they could break the page if they were to fail (for whatever reason). So we add some (possibly unnecessary) guards, just in case.
2017-12-16Fix rotate hints for filtered hints.Stephen Blott
We should rotate on `<Shift-Space>` too.
2017-12-15Merge pull request #2871 from smblott-github/detect-click-listenersStephen Blott
Detect click listeners for link hints.
2017-12-14Fix enabled state on webNavigation.Stephen Blott
`forTrusted()` for `checkEnabledAfterURLChange()` after web navigation is being called with a request (not an event). So make the request trusted. The symptom was that pass keys and the enabled state was not being correctly updated on web navigation.
2017-12-14Detect click listeners for link hints.Stephen Blott
This is a simpler version of #1167. It detects clickable elements with listeners added with `addEventListener()`. It includes some of @mrmr1993's ideas from #1167 (in fact, it's mostly those ideas tweaked into a slightly different form).
2017-12-12Merge pull request #2371 from smblott-github/add-swap-option-for-marksStephen Blott
Add "swap" command option for marks.
2017-12-02Recurse an arbitrary depth into shadow DOMs for insert mode elementmrmr1993
2017-11-30Rework insert mode (check status dynamically).Stephen Blott
This removes @insertModeLock and instead always checks whether we are in insert mode dynamically (as we previously did only for contentEditable). @mrmr1993... Would you be able to check this, please? It is intended to be mostly a no-op. Fixes #2841.
2017-11-25Tweak #2783.Stephen Blott
Tiny tweaks... 1. The test is clearer like this. 2. Use a more CoffeeScript-ish approach to sub-string.
2017-11-25Merge pull request #2783 from mrmr1993/use-HTML5-labelsStephen Blott
Use HTML labels accessor to get link hint labels for input elements
2017-11-25Use mkRepeatCommand in main.coffee.Stephen Blott
Tweak of #2601.
2017-11-25Merge pull request #2601 from mrmr1993/ff-copy-pasteStephen Blott
Enable Firefox clipboard commands
2017-11-24Merge branch 'mrmr1993-pr/link-hints-consistent-flash'Stephen Blott
2017-11-24Localise the logic for handling flash elements.Stephen Blott
2017-11-24Reintroduce default value for argument in LinkHints::activateLinkmrmr1993
2017-11-24Flash the clicked element for alphabet hintsmrmr1993
2017-11-24Merge branch 'mrmr1993-simplifyTabCount'Stephen Blott
Merging #2792 (mention @mrmr1993).
2017-11-24Retain @tabCount unchanged for non-printable characters.Stephen Blott
Previously, @tabCount was reset on the `<Shift>` `keydown` event, which defeats the purpose of #2792. Also, the @tabCount was reset on other non-printable characters such as `<LeftArrow>`.
2017-11-22Add a comment for Frame expando fixmrmr1993
2017-11-22FF: Reattach expando on every message to Framemrmr1993
This fixes #2830: it stops timesofindia.indiatimes.com from failing due to FF bug 1408996.