• Browser
  • Mail
  • News
  • Community
  • About
Register Login
HomeBlogsForumThemesContributeSocial

Vivaldi

  • Browser
  • Mail
  • News
  • Community
  • About

Navigation

    • Home
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    1. Home
    2. Let's talk about Vivaldi
    3. Tips & Tricks
    4. Command Chain Recipes

    Command Chain Recipes

    Tips & Tricks
    45
    235
    57.8k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Pesala
      P
      Pesala Ambassador
      last edited by

      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.

      Periodic Reload Command Chains.png

      Customise Menu.png

      Custom Reload Submenu.png

      Blog • Vivaldi Review • Server Status
      Win 10 64-bit build 19045.2486 • Snapshot 7.4.3683.28 (64-bit)

      derDay
      D
      deneban
      D
      2 Replies Last reply
      Reply Quote 3
      • derDay
        D
        derDay Supporters @Pesala
        last edited by

        @pesala
        you can already add this menu without a command chain 🤔
        search for perio at the commands section

        Pesala
        P
        1 Reply Last reply
        Reply Quote 1
        • Pesala
          P
          Pesala Ambassador @derDay
          last edited by

          @derday Been there, done that, but it does not work. There are no timer settings when the period command is added to the page context menu.

          Blog • Vivaldi Review • Server Status
          Win 10 64-bit build 19045.2486 • Snapshot 7.4.3683.28 (64-bit)

          derDay
          D
          1 Reply Last reply
          Reply Quote 0
          • derDay
            D
            derDay Supporters @Pesala
            last edited by

            @pesala
            strange, works for me since "ages"

            1 Reply Last reply Reply Quote 0
            • luetage
              L
              luetage Supporters Soprano
              last edited by

              @pesala You need to add [Periodic Reload], this will give you the submenu. @derDay is right, it works already.

              github ◊ vfm

              Pesala
              P
              1 Reply Last reply
              Reply Quote 0
              • Pesala
                P
                Pesala Ambassador @luetage
                last edited by Pesala

                @luetage I added the “Periodic Reload” command, not the “[Periodic Reload]” submenu. The former does nothing, and should probably not exist in the list of Application Commands.

                Anyway, if you create Command Chains for each period that you need, you can customise the subfolder to contain only those commands that you actually use.

                It is that time of the month again when the developers need to update a lot of things before the Stable build. The feature request for Right-click menu option for periodic tab reload also needs to be tagged as DONE, which is what led me on this wild-goose-chase.

                I reported the bug as:

                (VB-82802) Periodic Reload Command Does Nothing

                Blog • Vivaldi Review • Server Status
                Win 10 64-bit build 19045.2486 • Snapshot 7.4.3683.28 (64-bit)

                1 Reply Last reply Reply Quote 0
                • E
                  erazer101
                  last edited by pafflick

                  I just answered a question here and tought this might be useful for others as well.
                  I know there is a "Search Engine with Selection" recipe allready but I think I have found a cleaner way of doing it with just a single javascript line and no delays. The ability to add a custom shortcut for every search engine is also a game changer...

                  Result:
                  Highlight/select Text, Hit a custom shortcut > a new Tab opens with the results of the search engine of your choice.

                  Known Issue:
                  Currently only suitable for URLs where the search term is at the end of the URL. (could be solved with some more Javascript)
                  I will use google as an example. To change the engine just replace the URL in the parameter below with your searchengine url.
                  Here are some working URL examples that you can try.
                  'https://www.amazon.com/s?k='
                  'https://maps.google.com/?q='
                  'https://en.wikipedia.org/wiki/Special:Search/'
                  'https://www.ebay.com/sch/?_nkw='

                  TIP:
                  How to find those URLs if you can't google them like for not so popular sites?
                  Here is what i do: I just do a search with the term "TEST" on the site I want the search URL for. Than i check the URL on the result page.
                  For example searching TEST on amazon will forward you to:
                  https://www.amazon.com/s?k=TEST&__mk_de_DE=ÅMÅŽÕÑ&ref=nb_sb_noss_2
                  Than I just delete everything behind the keyword, in this case:
                  https://www.amazon.com/s?k=TEST
                  Than i hit enter again to check if the shortened URL still gives the expacted result page and in most cases it does.
                  Now all you need to do is remove the TEST from the URL as well and you have your search engine URL.
                  https://www.amazon.com/s?k=
                  But dont forget to add the single quotation marks ' in the parameter!

                  nuff said...
                  here is the Recipe:

                  Chain Name:
                  HotkeyHighlightSearch

                  Command 1:
                  Open Link in Current Tab (Javascript will take care of opening the result in a NEW tab)

                  Parameter:
                  javascript:var root = 'https://www.google.com/search?q='; var selection= ''+(window.getSelection?window.getSelection():document.getSelection?document.getSelection():document.selection.createRange().text);var myurl = root+selection;window.open(myurl);

                  Now go to Settings>Keyboard>Chains (at the very bottom of the keyboard settings)
                  add Shortcut to "HotkeyHighlightSearch" e.q. CTRL+q

                  BTW instead of selecting/highlighting text and pressing your shortcut you could also highlight the text and then press F2 and type "HotkeyHighlightSearch" and hit Enter.

                  //MODEDIT: added inline code tags

                  Granite1
                  G
                  1 Reply Last reply
                  Reply Quote 2
                  • luetage
                    L
                    luetage Supporters Soprano
                    last edited by

                    @erazer101 Matter of taste. The delays don’t really slow my version down considerably and the upside is you can use existing engines from settings by nickname. Moreover your javascript shows up in the address field and obfuscates the current url. Anyway, it’s good to have the choice.

                    github ◊ vfm

                    E
                    1 Reply Last reply
                    Reply Quote 2
                    • E
                      erazer101 @luetage
                      last edited by

                      @luetage thanks a lot for the feedback. I agree being able to use existing search engines is a real benefit.
                      Since I only use a handful of engines it’s still ok to setup for me.

                      I hate the corrupted URL…didn’t realize it before you mentioned it.
                      Seems like Vivaldi opens the script in the current TAB therefore putting the script in the address bar and run it from there.
                      There would be a simple solution by just using “open link in new tab” as Vivaldi command and changing the javascript/parameter to open in same tab.
                      But it seems like you can’t run any javascript function with the “open link in new tab” command. All it does is opening a new empty tab.
                      E.G.: Open link in new tab > Parameter: javascript:window.open("https://www.youraddress.com", "_self") only opens an empty tab for me..

                      Not sure if this is a bug or missing feature but I reported both issues as bug.
                      -add support for javascript in "open in new tab" command chains VB-82849
                      -add command type "run javascript" to be able to run scripts in background without address bar, just like clicking a bookmarklet. VB-82850

                      BTW...not sure if any admins read this but the request feature site misses a command chain category.

                      1 Reply Last reply Reply Quote 0
                      • shifte
                        S
                        shifte
                        last edited by

                        Only an ordinary History Panel
                        1, History Panel
                        2, Select All

                        luetage
                        L
                        1 Reply Last reply
                        Reply Quote 2
                        • luetage
                          L
                          luetage Supporters Soprano @shifte
                          last edited by

                          @shifte Is the better version of the existing command!

                          github ◊ vfm

                          1 Reply Last reply Reply Quote 1
                          • shifte
                            S
                            shifte
                            last edited by

                            New Tab Position: As First Tab

                            1, New Tab
                            2, Delay
                            parameter: 100
                            3, Pin/Unpin tab
                            4, Pin/Unpin tab

                            I don't use "Ctrl+t" at all, but...I got an idea.

                            1 Reply Last reply Reply Quote 8
                            • ukanuk
                              U
                              ukanuk Ambassador
                              last edited by ukanuk

                              New Stacked Tab

                              I set this chain to Ctrl+T to always puts the new tab in a stack, either in the existing stack or in a newly created stack if the active tab was a top-level tab. "New Tab" and "New Top Level Tab" already exist as keyboard shortcuts. However, the "New Tab" command has different behavior depending on whether the active tab is a new top-level tab, or already part of a stack.

                              Change Settings:

                              • Settings > Tabs > New Tab Position:
                                After Active Tab

                              Chain:

                              1. New Tab
                              2. Delay
                                Parameter: 100
                              3. Select Previous Tab
                              4. Stack Tabs

                              Note it does have some disadvantages. Maybe you guys can find a better workaround? Also see this post and that post.

                              • Have to set "After Active Tab" in settings, which undesirably changes "New Top Level Tab" command behavior.
                              • Slows down the entire browser a bit by adding delay to every new tab opening.
                              • Causes some visually distracting flashing in the tab bar as the chain selects tabs and re-groups them.
                              • Doesn't change how bookmarks open, as OP notes in that post.

                              New Top Level Tab at End

                              The "After Active Tab" setting changes the "New Top Level Tab" command behavior, but with Vivaldi v5.1 we can now restore the desired behavior (albeit with some visually distracting motion in the tab bar). And note this still doesn't fix how bookmarks open.

                              Chain:

                              1. New Top Level Tab
                              2. Move Tabs to End
                              Y
                              1 Reply Last reply
                              Reply Quote 3
                              • Pesala
                                P
                                Pesala Ambassador
                                last edited by

                                @ukanuk If you enable:

                                Include Active Tab in Initial Selection

                                1. New Tab
                                2. Stack Tabs

                                Should stack the new tab with the current tab without any delay, and whatever the new tab position.

                                Blog • Vivaldi Review • Server Status
                                Win 10 64-bit build 19045.2486 • Snapshot 7.4.3683.28 (64-bit)

                                1 Reply Last reply Reply Quote 0
                                • ukanuk
                                  U
                                  ukanuk Ambassador
                                  last edited by ukanuk

                                  @Pesala , I only see that option under "Tabs > Tab Features > Tab Selection". Do you see it in a second place? In any case, it was already enabled for all my testing.

                                  Without changing the "New Tab Position" setting, I found that Vivaldi stacks the new tab with whatever tab is to its left -- "Previous" tab apparently means the one to the left of the current tab, not the previous one by recent order.

                                  Without the delay, I found that Vivaldi actually stacked the Previous Tab with the second previous tab -- the just-newly-created tab apparently doesn't appear quite quickly enough to be included as part of the initial selection.

                                  1 Reply Last reply Reply Quote 0
                                  • luetage
                                    L
                                    luetage Supporters Soprano
                                    last edited by luetage

                                    New chain Open Selection

                                    This used to be »Search Engine with Selection«. In an update a while ago we got the ability to search any engine with parameter, which made this previous chain obsolete. The difference to the inbuilt command »Search with Selection« is being able to open addresses which aren’t hyperlinks.

                                    @ukanuk If you’re happy with your chain, we can include it. I have to admit I forgot about it after seeing it initially.

                                    github ◊ vfm

                                    ukanuk
                                    U
                                    1 Reply Last reply
                                    Reply Quote 0
                                    • ukanuk
                                      U
                                      ukanuk Ambassador @luetage
                                      last edited by

                                      @luetage Yep, I've been using my chain as-is for a month now and don't see anything changing until/unless Vivaldi changes stuff.

                                      1 Reply Last reply Reply Quote 1
                                      • Aperrizio
                                        A
                                        Aperrizio
                                        last edited by Aperrizio

                                        Figure out the publish date of an article (if hidden):

                                        Open link in current tab with-----> javascript:window.open("https://www.google.com/search?q=inurl:"+encodeURIComponent(location.href)+" "+('&as_qdr=y15'))

                                        This script will search the link on Google, from 15 years ago. The date appears on Google.

                                        luetage
                                        L
                                        1 Reply Last reply
                                        Reply Quote 3
                                        • luetage
                                          L
                                          luetage Supporters Soprano @Aperrizio
                                          last edited by

                                          @aperrizio Nice idea, included.

                                          github ◊ vfm

                                          1 Reply Last reply Reply Quote 1
                                          • pafflick
                                            P
                                            pafflick Vivaldi Team @luetage
                                            last edited by

                                            @luetage I discovered that there is no need to define a variable when "restoring" the URL. I believe that adding a delay is not necessary either. Changing the URL with replaceState shouldn't affect the execution of the code. If anything, it's added at the end, so it should be the last thing to execute anyway.
                                            For example, I changed this (from your "Dark (Invert)" snippet):
                                            setTimeout(()=>{const t=window.location.href;window.history.replaceState("stateObj","",t)},300)
                                            into:
                                            history.replaceState({},"",location.href)
                                            and it works just as well (or slightly better, since the change of the URL is almost unnoticeable). 😅

                                            luetage
                                            L
                                            1 Reply Last reply
                                            Reply Quote 3
                                            Loading More Posts
                                            • Oldest to Newest
                                            • Newest to Oldest
                                            • Most Votes
                                            Reply
                                            • Reply as topic
                                            Log in to reply
                                            • 1
                                            • 2
                                            • 3
                                            • 4
                                            • 5
                                            • 11
                                            • 12
                                            • 3 / 12
                                            • First post
                                              Last post

                                            Looks like your connection to Vivaldi Forum was lost, please wait while we try to reconnect.

                                            Copyright © Vivaldi Technologies™ — All rights reserved. Privacy Policy | Code of conduct | Terms of use | Vivaldi Status