This extension adds configurable lookup options for the context menu of selected text

Latest Version

Version
4
Update
March 19, 2024
Size
33.91KiB
Developer
Category
Users
77
Rating
5 ★
Manifest Version
3
Web Store Status
Languages Support
English (United States)
See more
Permissions
Storage
ContextMenus
See more

Context Lookups Extension

Quickly search information as you browse. Just select the text you want to look up, bring up the right-click context menu, and select the configured lookup option that you want.

Need to quickly check the definition of \"bi-weekly\" when someone emails you about a meeting? Curious about the literal meaning of \"je ne sais quoi\" when it comes up in an article? Want to know who exactly \"Robert Walpole\" is when someone mentions them in a comment?

Context Lookups has you covered! Get up to speed or satisfy your curiosity in no time at all, then be on your merry way. You can set the results to appear as regular webpages, or make things extra convenient with simplified popup windows.

This much can already be done with just the default lookups, but the possibilities go far beyond that. Copy the search query URL base of whatever website you want to use, and create a context menu item for it in the extension popup, it's that simple. Just remember to save your changes!

Here are a couple more to try:

Synonyms/Antonyms
- Use \"https://www.thesaurus.com/browse/\" as the URL base.

Rhymes
- Use \"https://www.rhymezone.com/r/rhyme.cgi?typeofrhyme=perfect&Word=\" as the URL base.

Note that ampersand characters (&) in context menu labels are used to assign shortcut keys. To make a letter within the label the shortcut key for the option (while it's shown), simply put an ampersand in front of it. For example, set the label as \"Rh&ymes\" to make a context menu option \"Rhymes\" with the shortcut key 'y'. To put an ampersand in the actual label, simply include it twice, as in \"Synonyms && Antonyms\" to get a label of \"Synonyms & Antonyms\".

This is my first extension, so any feedback is appreciated.

NOTE: Due to limitations with Chrome, results displayed in a popup are unfortunately restricted to the primary display. If using multiple displays, try to keep the browser window using the extension on the primary display. Alternatively, you can set the results to display as normal pages instead.

Version 2:
Now supports parent menus!

Version 3:
Updated to use Manifest version 3. Apologies for any resultant issues I might have missed. After a couple revisions, I think I've got it working with pre-existing saved data, but if you still encounter issues, I recommend saving your loaded configurations from the extension popup to update the saved data.

Opening as a regular window popup is now supported, by simply selecting the center of the slider.

Changed the default definition lookup to a simple Google search query, as this has better fallback behavior when a definition isn't found in the primary source.

Version 4:
New features and quality of life improvements
- Import and Export from/to a file (remember to save after importing!)
- A much larger number of menu items are supported than before (working around Chrome limitations)
- Internal scrolling, for retaining easy access to button controls
- Now indicates when you have unsaved changes
- Encountered errors now get displayed, though hopefully this won't be needed. :)
Read more

Source Manifest.json

{"update_url": "https://clients2.google.com/service/update2/crx", "manifest_version": 3, "name": "Context Lookups", "description": "This extension adds configurable lookup options for the context menu of selected text", "version": "4", "action": { "default_popup": "popup.html", "default_icon": { "16": "icon16.png", "24": "icon24.png", "32": "icon32.png", "48": "icon48.png", "64": "icon64.png", "128": "icon128.png" } }, "icons": { "16": "icon16.png", "24": "icon24.png", "32": "icon32.png", "48": "icon48.png", "64": "icon64.png", "128": "icon128.png" }, "permissions": [ "storage", "contextMenus" ], "background": { "service_worker": "background.js" }}
Read more