Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 1 addition & 4 deletions docs/API.md
Original file line number Diff line number Diff line change
Expand Up @@ -623,10 +623,7 @@ Open links in new tabs.
### Examples

```javascript
mapkey("<Space>", "pause/resume on youtube", function() {
var btn = document.querySelector("button.ytp-ad-overlay-close-button") || document.querySelector("button.ytp-ad-skip-button") || document.querySelector('ytd-watch-flexy button.ytp-play-button');
btn.click();
}, {domain: /youtube.com/i});
tabOpenLink('https://github.com/brookhong/Surfingkeys')
```

## insertJS
Expand Down
6 changes: 1 addition & 5 deletions src/content_scripts/common/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -871,11 +871,7 @@ function constructSearchURL(se, word) {
* @param {string} str links to be opened, the links should be split by `\n` if there are more than one.
* @param {number} [simultaneousness=5] how many tabs will be opened simultaneously, the rest will be queued and opened later whenever a tab is closed.
*
* @example
* mapkey("<Space>", "pause/resume on youtube", function() {
* var btn = document.querySelector("button.ytp-ad-overlay-close-button") || document.querySelector("button.ytp-ad-skip-button") || document.querySelector('ytd-watch-flexy button.ytp-play-button');
* btn.click();
* }, {domain: /youtube.com/i});
* @example tabOpenLink('https://github.com/brookhong/Surfingkeys')
*/
function tabOpenLink(str, simultaneousness) {
simultaneousness = simultaneousness || 5;
Expand Down