Command Chain Recipes
-
Thanks to @shifte here is an alternative to Selected text to be searched in two search engines and tile the result which is faster and less flickering.
Use '+encodeURIComponent(b)+' instead of %S.
1
Open Link in Current Tab
Parameter:
javascript:(function(){var b=((window.getSelection&&window.getSelection())||(document.getSelection&&document.getSelection())||(document.selection&&document.selection.createRange&&document.selection.createRange().text));if(b!=''){window.open('https://www.google.com/search?q='+encodeURIComponent(b)+'%20etymology');}else{alert('You have not selected text.');}})();
2
Delay 1003
Previous Tab (Recent)4
Delay 1005
Open Link in Current Tab
Parameter:
javascript:(function(){var b=((window.getSelection&&window.getSelection())||(document.getSelection&&document.getSelection())||(document.selection&&document.selection.createRange&&document.selection.createRange().text));if(b!=''){window.open('https://translate.google.com/?sl=auto&tl=iw&text='+encodeURIComponent(b)+'&op=translate');}else{alert('You have not selected text.');}})();
6
Delay 1007
Select Current Tab8
Delay 1009
Select Previous Tab10
Delay 10011
Tile Vertically12
Delay 10013
Stack Tabs//MODEDIT: added inline code tags
-
Some suggestions for increasing the power of Command Chain Recipes from the extension "AutoControl: Custom shortcuts, Mouse gestures":
1.- ACTIONS
BASIC ACTIONS:
ADVANCED ACTIONS:
Tab Actions
Window Actions
Bookmark Actions
Menu Actions
Clipboard Actions
OTHER
Synthesize Input
2.- TRIGGERS
-
Mail Mode:
- Mail Panel
Toggle Floating Panel (Optional - only if you use floating panel)No longer necessary, just make sure the mail panel isn't set to float
Exit Mail Mode:
- Mail Panel
Toggle Floating Panel (Optional - only if you use floating panel)No longer necessary, just make sure the mail panel isn't set to float- Close Tab
Close Active PanelObsolete - use "Toggle Current Panel" command instead.
Create a blank panel that you will never open - I used "vivaldi://blah" so it has a nice iconWeb Panel 1Web Panel 1
-
For Close Active Panel:
- Panel
-
By this chain, You will be able to capture and tweet quickly!
- Capture Area to Clipboard (or Capture page to Clipboard)
- Open Link in Current Tab
Parameter:
javascript:window.open("https://twitter.com/intent/tweet?text="+encodeURIComponent(document.title)+" "+encodeURIComponent(location.href))
- Delay (Parameter:1000)
- Paste
P.S.
I use Vivaldi snapshot 4.1.2369.10 (arm64) on macOS BigSur 11.5.1 of M1 Macbook Air. This version has the issue. When I set Status-bar to Overlay or Hide, Capture Area feature is not working. If I set Status-bar to Show, this feature is working. -
@kyu3a Drag the camera icon to the address bar, then you can hide the status bar.
-
@pesala Thank you for replying! I could caputre without showing Status-bar.
-
Funny command chains were introduced in Makeuseof.com. It is "Netflix Mode". This chains will change Vivaldi to the mode watching Netflix for a hour intently.
- Open Link in New Tab (Command Parameter: netflix.com)
- Fullscreen Mode
- Delay (Command Parameter: 5000)
- Mute Other Tabs
- Delay (Command Parameter: 3600000) (For 1 Hour)
- Unmute Other Tabs
- Fullscreen Mode
- Close Tab
Source:
How to Use Vivaldi Command Chains to Simplify Your Workflow
https://www.makeuseof.com/how-to-use-vivaldi-commands/ -
general question:
is it possible, to adress the guestwindow?
at the moment, we can't give the URL of a tab (or a link) to guest window (links only to other profiles). with the command chain it would be possible, but I encountered, that I can't give the adress to a (new) guest windowany hints or tricks?
-
@derday Window commands of any kind are excluded from command chains, because a command chain runs as a process of the current window. I hope there will be a solution or workaround to this at some point.
-
These command chains had been featured in OP previously. Moved to collect links to all command chains instead.
Inspect UI
Opens DevTools for the user interface.
- Open Link in New Tab
Paramenter:vivaldi://experiments
- Delay
Parameter:50
- Developer Tools
- Close Tab
{"category":"CATEGORY_COMMAND_CHAIN","chain":[{"defaultValue":"https://vivaldi.com","key":"f57b8092-9426-4bc8-8e39-fcf3e315b065","label":"Open Link in New Tab","name":"COMMAND_OPEN_LINK_DEFAULT","param":"vivaldi://experiments"},{"defaultValue":1000,"key":"2eb81004-6703-46db-9933-6afcfde924e4","label":"Delay","name":"COMMAND_CHAINED_SLEEP","param":50},{"key":"e6a1c7d5-21ad-4195-bc9e-95ebcb6ee2eb","label":"Toggle Developer Tools","name":"COMMAND_DEVTOOLS_INSPECTOR"},{"key":"f0a3a628-6977-4812-ab11-96a1d1fbc08d","label":"Close Tab","name":"COMMAND_CLOSE_TAB"}],"key":"cl12fs5mr00i42z5wtv7rvu1b","label":"Inspect UI","name":"COMMAND_cl12fs5mr00i42z5wtv7rvu1b"}
Copy Page Address
Copies current URL to the clipboard. Already available native as mouse gesture and from menu, but not as keyboard shortcut or quick command.
- Focus Address Field
- Delay
Parameter:100
- Select All
- Copy
- Delay
Parameter:500
- Focus Page
{"category":"CATEGORY_COMMAND_CHAIN","chain":[{"key":"96a396d8-d485-4f61-926b-bdab1eddaf94","label":"Focus Address Field","name":"COMMAND_FOCUS_ADDRESSFIELD"},{"defaultValue":1000,"key":"2eb81004-6703-46db-9933-6afcfde924e4","label":"Delay","name":"COMMAND_CHAINED_SLEEP","param":100},{"key":"ce41214f-6878-42ef-b120-3deb06cfcf2e","label":"Select All","name":"COMMAND_CLIPBOARD_SELECT_ALL"},{"key":"6dae1e1a-695b-41c5-9ca9-deb1fabe9cc9","label":"Copy","name":"COMMAND_CLIPBOARD_COPY"},{"defaultValue":1000,"key":"2eb81004-6703-46db-9933-6afcfde924e4","label":"Delay","name":"COMMAND_CHAINED_SLEEP","param":500},{"key":"f71373d5-f966-4603-b7c5-a4a1722b3989","label":"Focus Page","name":"COMMAND_FOCUS_WEBVIEW"}],"key":"cl12ftdyo00i52z5wyg8ux8vy","label":"Copy Page Address","name":"COMMAND_cl12ftdyo00i52z5wyg8ux8vy"}
Tab Scroll
Scrolls to top of the current page and scrolls back to initial position when toggled again. This is an existing browser modification, but works very well as command chain when assigning a shortcut to it. I’m using
Shift-PageDown
.- Open Link in Current Tab
Parameter:javascript:(()=>{let o=window.pageYOffset;if(o>0){window.sessionStorage.setItem("tabOffset",o);window.scrollTo(0,0)}else{window.scrollTo(0,window.sessionStorage.getItem("tabOffset")||0)}history.replaceState({},"",location.href)})();
{"category":"CATEGORY_COMMAND_CHAIN","chain":[{"defaultValue":"https://vivaldi.com","key":"0b01337b-4c13-4197-90c8-179c5c91cfff","label":"Open Link in Current Tab","name":"COMMAND_OPEN_LINK_CURRENT","param":"javascript:(()=>{let o=window.pageYOffset;if(o>0){window.sessionStorage.setItem(\"tabOffset\",o);window.scrollTo(0,0)}else{window.scrollTo(0,window.sessionStorage.getItem(\"tabOffset\")||0)}history.replaceState({},\"\",location.href)})();"}],"key":"cl12fv64y00i62z5wbv0ecyiy","label":"Tab Scroll","name":"COMMAND_cl12fv64y00i62z5wbv0ecyiy"}
- Open Link in New Tab
-
Close Tab Move Left
- Previous Tab (by Order)
- Delay
Parameter:100
- Select Next Tab
- Close Tab
Close Tab Move Right
- Next Tab (by Order)
- Delay
Parameter:100
- Select Previous Tab
- Close Tab
Control which tab gets activated after closing a tab. I personally use
alt-,
andalt-.
to operate. Currently the only downside is you gotta disable »include active tab in initial selection« invivaldi://settings/tabs
, or both your tabs will be deleted. -
Close Stack
- Select Current Tab
- Close Tab
There is no keyboard shortcut to close a tab stack, this simple command chain creates it. Works only if your active tab is part of the stack.
Open Clipboard in New Tab
- New Tab
- Delay
Parameter:300
- Focus Address Field
- Paste and Go
Whenever you copy a link by clicking on a dedicated webpage button, or you copied it in another application, this is the way to open the link in a new tab painlessly.
-
For me personally command chains have replaced bookmarklets. There is no good reason (other than sync) for saving Javascript code as a bookmark when using Vivaldi.
DeepL
- Open Link in Current Tab
Parameter:javascript:(function%20translate()%7Bfunction%20se(d)%20%7Breturn%20d.selection%20?%20d.selection.createRange().text%20:%20d.getSelection()%20%7Ds%20=%20se(document);for%20(i=0;%20i%3Cframes.length%20&&%20!s;%20i++)s%20=%20se(frames%5Bi%5D.document);if%20(!s%20%7C%7C%20s=='')%20s%20=%20prompt('Enter%20text%20to%20translate%20with%20DeepL','');open('https://www.deepl.com/translator#'+document.documentElement.lang+'/en/'%20+%20(s%20?%20encodeURIComponent(s)%20:%20'')).focus();%7D)();
Grabs your current selection and sends it to DeepL for translation.
Dark (Invert)
- Open Link in Current Tab
Parameter:javascript:(d=>{var css=`:root{background-color:#fefefe;filter:invert(100%)}*{background-color:inherit}img:not([src*=".svg"]),video{filter: invert(100%)}`,style,id="dark-theme-snippet",ee=d.getElementById(id);if(null!=ee){ee.parentNode.removeChild(ee)}else{style=d.createElement('style');style.type="text/css";style.id=id;if(style.styleSheet){style.styleSheet.cssText=css}else{style.appendChild(d.createTextNode(css))}(d.head||d.querySelector('head')).appendChild(style)}setTimeout(()=>{const t=window.location.href;window.history.replaceState("stateObj","",t)},300)})(document);
Similar to the invert filter in page actions. The difference is it tries to leave images alone and it doesn’t reload the page when toggled. See https://gist.github.com/frontdevops/8aea1e0252dd826488dad63319e3ec88
- Open Link in Current Tab
-
OP contains a collection of all command chains now, for an easier overview going forward.
-
@luetage Love this, but didn't want to change the setting, so I slightly modified it:
Close Right
- Next Tab (by Order)
- Delay 100
- Select Previous Tab
- Select Current Tab (actually deselects it)
- Close Tab
Close Left
- Previous Tab (by Order)
- Delay 100
- Select Next Tab
- Select Current Tab (actually deselects it)
- Close Tab
-
@legobuilder26 This requires the exact opposite setting, good find. I dream of selection commands being independent from the setting when called from a command chain.
-
Mute for 3 minutes.
Cup Noodles Timer1, Open Link in New Tab
parameter: https://www.youtube.com/watch?v=t5CAQU6KsMI (your taste video)
2, Mute All Tabs
3, Delay
parameter: 30000
4, Delay
parameter: 30000
5, Delay
parameter: 30000
6, Delay
parameter: 30000
7, Delay
parameter: 30000
8, Delay
parameter: 30000
9, Unmute All Tabs -
@shifte haha
-
Periodic Reload Context Menu
To add the periodic reload menu to the Page Context menu so that you don't have to move your mouse cursor to the tab bar:
- Add a new Command Chain for each reload period that you wish to use: Name the Commands as 1 Minute, 2 Minutes, etc.
- In Settings, Appearance, Menu Customisation, Page Context Menu, add a new folder named "Periodic Reload*
- In the new folder, add your Command Chains for 1 Minute, 2 Minutes, etc.