All Projects → alexherbo2 → webextension-dmenu

alexherbo2 / webextension-dmenu

Licence: Unlicense license
Tab search, selection and beyond with a dmenu filter program

Programming Languages

javascript
184084 projects - #8 most used programming language
shell
77523 projects
Makefile
30231 projects
HTML
75241 projects
CSS
56736 projects

Projects that are alternatives of or similar to webextension-dmenu

kpmenu
Dmenu/rofi interface for KeePass
Stars: ✭ 21 (+23.53%)
Mutual labels:  dmenu
referer-mod
Web Extension to modify the Referer header in HTTP requests
Stars: ✭ 37 (+117.65%)
Mutual labels:  webextension
view-background-image
Chrome extension that adds "View background image" to the context menu
Stars: ✭ 35 (+105.88%)
Mutual labels:  webextension
noplugin
Play legacy media in modern browsers without plugins.
Stars: ✭ 29 (+70.59%)
Mutual labels:  webextension
yt2p
Watch videos in an external player.
Stars: ✭ 22 (+29.41%)
Mutual labels:  webextension
svelte-webext-storage-adapter
Svelte stores, backed up by chrome.storage
Stars: ✭ 18 (+5.88%)
Mutual labels:  webextension
darkContrast
Firefox addon that fixes low contrast text when using dark desktop theme
Stars: ✭ 61 (+258.82%)
Mutual labels:  webextension
MTDeck
TweetDeckをスマホアプリのように使えるようにするUserScript
Stars: ✭ 26 (+52.94%)
Mutual labels:  webextension
RegexSearch
Firefox Extension (WebExtension) to Search in HTML using Regular Expression (REGEX)
Stars: ✭ 38 (+123.53%)
Mutual labels:  webextension
RedBlock
트위터 사상 최강의 체인블락 확장기능. / Powerful extension to block multiple users on Twitter.
Stars: ✭ 75 (+341.18%)
Mutual labels:  webextension
savescreenshot
Save Screenshot Add-on for Firefox. Simple website screenshot maker for Firefox.
Stars: ✭ 16 (-5.88%)
Mutual labels:  webextension
flagCookies
A cookie manager, browser add-on to manage and flag cookies. On stereoids.
Stars: ✭ 42 (+147.06%)
Mutual labels:  webextension
yt-dislikes-viewer
A browser extension that allows you to see dislikes on a youtube video after the youtube update
Stars: ✭ 291 (+1611.76%)
Mutual labels:  webextension
recap-chrome
Recap Chrome and Firefox Extension
Stars: ✭ 41 (+141.18%)
Mutual labels:  webextension
ShaderToy-Chrome-Plugin
Web extension for shadertoy.com
Stars: ✭ 159 (+835.29%)
Mutual labels:  webextension
SQRL
Secure Quick Reliable Login WebExtension for Firefox and Chrome
Stars: ✭ 57 (+235.29%)
Mutual labels:  webextension
radical
Element (Riot Web) unofficially bundled as Firefox Add-on
Stars: ✭ 33 (+94.12%)
Mutual labels:  webextension
tab-counter
A button badge that shows the number of tabs open in a window
Stars: ✭ 35 (+105.88%)
Mutual labels:  webextension
LAN-port-scan-forbidder
Forbid untrusted webs to access localhost or LAN. An anti-scan protection 🛡️🏡
Stars: ✭ 53 (+211.76%)
Mutual labels:  webextension
SixIndicator
SixIndicator is a WebExtension Plugin which indicates via an icon, if you are viewing the website with IPv6 or IPv4.
Stars: ✭ 17 (+0%)
Mutual labels:  webextension

dmenu for Chrome and FirefoxWebExtensions

Tab search, selection and beyond with a dynamic menu program.

Thumbnail Button

Dependencies

Extensions

Installation

Chrome
make chrome

Open the Extensions page by navigating to chrome://extensions, enable Developer mode then Load unpacked to select the extension directory: target/chrome.

Firefox
make firefox
  • Open about:config, change xpinstall.signatures.required to false.
  • Open about:addonsExtensions, click Install add-on from file and select the package file: target/firefox/package.zip.

Configuration

Chrome

Open chrome://extensions/configureCommands to configure the keyboard shortcuts.

Firefox

Open about:addonsExtensions and click Manage extension shortcuts in the menu.

Usage

  • Press Control + q to tab search.
  • Press Control + Q to bring a tab.
  • Press Alt + q to open a bookmark.
  • Press Alt + Q to search history.

Commands

tab-search

Tab search. Default: Control + q.

bring-tab

Bring tab. Default: Control + Q.

open-bookmark

Open bookmark. Default: Alt + q.

search-history

Search history. Default: Alt + Q.

Options

dmenu

Pipe tabs through the given external filter program. Default:

{
  "command": "dmenu",
  "arguments": []
}

Example – Run with fzf and Alacritty:

~/.local/bin/dmenu

#!/bin/sh

# A drop-in dmenu replacement using fzf with Alacritty.

# – fzf (https://github.com/junegunn/fzf)
# – Alacritty (https://github.com/alacritty/alacritty)

# Create IO files
state=$(mktemp -d)
input=$state/input
output=$state/output
trap 'rm -Rf "$state"' EXIT

# Get input
cat > "$input"

# Run fzf with Alacritty
alacritty --class 'popup' --command sh -c 'fzf < "$1" > "$2"' -- "$input" "$output"

# Write output
cat "$output"

# Exit code
if test ! -s "$output"; then
  exit 1
fi

Cross-extension messaging

// Environment variables
switch (true) {
  case (typeof browser !== 'undefined'):
    var PLATFORM = 'firefox'
    var DMENU_EXTENSION_ID = '[email protected]'
    break
  case (typeof chrome !== 'undefined'):
    var PLATFORM = 'chrome'
    var DMENU_EXTENSION_ID = 'gonendiemfggilnopogmkafgadobkoeh'
    break
}

// Initialization
const dmenu = {}
dmenu.port = chrome.runtime.connect(DMENU_EXTENSION_ID)
dmenu.send = (command, ...arguments) => {
  dmenu.port.postMessage({ command, arguments })
}

// Usage
dmenu.send('tab-search')

You can find some examples in Krabby.

See the source for a complete reference.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].