Giter Club home page Giter Club logo

mohnish / rearrange-tabs Goto Github PK

View Code? Open in Web Editor NEW
167.0 5.0 24.0 96 KB

Google Chrome Extension to rearrange your tabs using customizable keyboard shortcuts

Home Page: https://chrome.google.com/webstore/detail/rearrange-tabs/ccnnhhnmpoffieppjjkhdakcoejcpbga

License: MIT License

Makefile 1.74% JavaScript 37.34% HTML 60.92%
rearrange-tabs shortcuts keyboard-shortcuts javascript google-chrome browser chrome-extension google-chrome-extension brave-extension chrome-web-store

rearrange-tabs's Introduction

Rearrange Tabs

Rearrange Tabs is a tiny Google Chrome Extension that allows users to rearrange the position of the tabs in a window by moving them around using keyboard shortcuts.

Rearrange Tabs has been featured on LifeHacker and Changelog 😄

  • To move selected tab(s) left

    • Mac: Ctrl-CMD-Left
    • Windows: Shift-Alt-Left
  • To move selected tab(s) right

    • Mac: Ctrl-CMD-Right
    • Windows: Shift-Alt-Right
  • To move selected tab(s) to the front (leftmost position)

    • Mac: Ctrl-CMD-Up
    • Windows: Shift-Alt-Up
  • To move selected tab(s) to the back (rightmost position)

    • Mac: Ctrl-CMD-Down
    • Windows: Shift-Alt-Down

It's as simple as that. Here's how it looks like: https://www.youtube.com/watch?v=A1X3geKtF8A

Here's the introduction blog post: https://iam.mt/rearrange-tabs

Shortcuts are configurable via chrome://extensions/shortcuts page.

Installation

Install the extension by visiting this Chrome Web Store link: Chrome Web Store

Customize Shortcut

  1. Go to chrome://extensions/shortcuts.
  2. Scroll down to locate Rearrange Tabs.
  3. Click in the greyed fields.
  4. Press the desired key combination to create a new shortcut.

image

Features

  • Move regular tabs around in a window
  • Move pinned tabs around in a window
  • Move multiple selected tabs around in a window
  • Move selected tabs to the leftmost or the rightmost positions

Development

  • Once the changes have been made to the the extension, run make dist. This will update the dist directory with the new files
  • If for some reason you want to remove the dist directory, run make clean
  • It might be necessary to install make before you can use it. If you encounter an error, open the terminal and run sudo apt-get install zip make

Compatibility

✅ Brave browser

✅ Edge browser

❌ Arc browser

Contributors

  • Mohinsh Thallavajhula (@mohnish)
  • Anže Videnič (@avidenic)
  • Tomas Juočepis (@TomasJuocepis)
  • Sandeep Appikonda (@appikonda)
  • Rob Yang (@unknownbreaker)
  • Roland Synnestvedt (@rsynnest)
  • Junho Park (@cnaa97)
  • Ross Hale (@rosshale)

License

(The MIT License)

Copyright (c) 2023 Mohnish Thallavajhula <[email protected]>

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the 'Software'), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

rearrange-tabs's People

Contributors

cnaa97 avatar mohnish avatar rosshale avatar sindhunaydu avatar tomasjuocepis avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

rearrange-tabs's Issues

After 3.0.0 - stopped working in linux

Per title, ever since the extension was updated on Feb 17th, this stopped working in linux. Used to work with ctrl + alt + left|right arrow and now it doesn't.

Fixed by customizing the extension in chrome://extensions/shortcuts per README but odd that it doesn't work by default.

Add explicit support for ChromeOS and Linux

Refer: https://developer.chrome.com/apps/commands

For the suggested_key key,

// left
"suggested_key": {
  "default": "Shift+Alt+Left",
  "windows": "Shift+Alt+Left",
  "mac": "MacCtrl+Shift+Left",
  "chromeos": "Shift+Alt+Left",
  "linux": "Shift+Alt+Left"
}

// right
"suggested_key": {
  "default": "Shift+Alt+Right",
  "windows": "Shift+Alt+Right",
  "mac": "MacCtrl+Shift+Right",
  "chromeos": "Shift+Alt+Right",
  "linux": "Shift+Alt+Right"
}

Mac and Windows shortcut is mixed

Versions:
On Mac High Sierra 10.13.2 (17C205
Rearrange Tabs 2.1.6
Version 69.0.3497.100 (Official Build) (64-bit)

In the chrome address bar, If you use alt + shrift + left|right arrow, it acts like ctrl + shift + left|right arrow, where it moves tab around instead of marking the text in the address bar. Suspect there is some bugs that mixed windows and mac shortcuts.

For some reason, Google Chrome has frequent crashes when this plugin is enabled

I cannot pin down exactly why though, not sure how to debug.

Chrome version: Version 99.0.4844.51 (Official Build) (x86_64)
MacOS version: 11.5.2 (20G95)
Shortcuts used: option-H, option-L

I've systematically removed all extensions, and added them back one by one and it's always this plugin that causes crashes.

The crashes sometimes occur without the extension, but as soon as I reenable it they come back with a lot of frequency (few times a day).

Wondering whether there's a bug in Chrome JS engine and this extension happens to use an API that triggers the bug. Super strange as this extension is so simple.

Browser History Permission

First off thank you for a great simple and open source (fuck yeah!) extension.
My issue is more of a question: why does this extension require access to users' browser history?

3.0 issues for Linux users

3.0 cleared the shortcuts for Linux users. I had to configure them again from the /shortcuts page. Can anyone else replicate this? Running Google Chrome on Debian 11.

Feature Request: Add Pin Tab Functionality 📌

Thank you for the extension! After a fresh Mac install, my previous extensions that did the move/pin tab job just vanished and I end up installing yours. Great. It works! However, what I miss is the pin tab functionality. Any chance you could add it as well?

Tabs no longer wrap to beginning when at the end position

Perhaps I'm imagining things, but am I correct in thinking that when a tab is in the last position and you move it right, it should move to the beginning of the tab list? Conversely, when the tab is at the beginning and you move it left, it should move to the end?

Currently this is not happening. Thanks for any help you can provide.

Don't install functionality on Linux

Linux already natively has Ctrl+Shift+PgUp/etc. to do this very thing, and given that you can't selectively not sync extensions in Chrome, I feel it may be best to just detect and not add the listener on Linux.

(I only just started using this on Mac, BTW.)

Mac default shortcuts are problematic in address bar

When the cursor is focused in the address bar on a Mac, and I hit Opt-Shift-Left/Right arrow to select a word in the address bar (this is the universal key combo on Mac), then it instead moves the tab left and right, even when I'm using the default shortcuts, which are Ctrl-Shift-Left/Right.

Move multiple tabs

When selecting tabs with ctrl (on windows), only the last selected tabs is moved, not all that were selected.

Please add an option to move several tabs at once.

Note to the community

Starting from Chrome 102, moving tabs using keyboard is a native feature in Chrome. Read more

I was initially excited and considering retiring this extension in favor of the new feature. But, after trying it out myself, the implementation seemed inferior for the following reasons -

  • Chrome doesn't offer keyboard shortcut customization
  • For Mac users, you'd have to use Ctrl+Opt+Fn+[up/down]. This is a handful and not all that comfortable (I've tried it myself)
  • It doesn't seem to support pinned tabs
  • It doesn't seem to support multiple selected tabs
  • It doesn't seem to support groups either

As a result, I'll continue developing the extension since it's loved and widely used ❤️

PS: Our extension recently got the "Featured" tag on the Chrome Web Store

image

Once again, thank you, everyone!

Add a shortcut to handle tabs group

Hi there,

That would be awesome to have a way to create/manage groups of tabs using a shortcut in addition to the existing (super useful!) features. For instance, one shortcut to create a new group and one other tomove the current tab to a group lying on the right left.

Wraparound tabs stopped working after 3.0.0

First off, I love this extension - thanks for creating it @mohnish!

Problem

Previously when a tab was at "the end", it could be "wrapped around" by pressing the move key again. E.g. If a tab is in the very right-most position and I press the move selected tab(s) right hotkey the tab would move into the first position (far left).

This isn't major by any means but I really enjoyed moving the tabs I deemed to be the most important back to the front in this way before clearing out the rest of my tabs.

Solution

  • Tabs should move to the start/end if the move key is pressed while they're in the last/first position

Notes

I'd be up for trying to implement this functionality if desired

Nicely Done

Not an issue, but easiest way to say thanks! Well done.

option-shift-left / right move tab even when overridden

Hi! This extension is really great, thank you for making this!

I'm having an issue with the shortcut. I have already overridden the shortcut to be ctrl-shift+left / right, and that works great. If I'm on a tab, and I click on the URL bar, and try to select a part of the URL, option-shift-left / right move the tab. This does not happen if I do not have the url highlighted.

I use option-shift-left / right a lot to navigate strings. Is there any way to keep that shortcut? When I disable rearrange tabs it does work again. I'm on BigSur and Chrome version 92.

In this recording you can see I have set shortcuts. First I use my shortcuts, which work correctly. I try to use option-shift-left and right, and nothing happens. Then I highlight the URL and use option-shift-left / right again, and the tab moves left and right.

rearrage_tabs

Thank you!

Unable to assign shortcut for special characters

Hello!

When attempting to reassign a shortcut, it's not possible to set characters like [ or ]. It would be fancy if shortcuts like ctrl + shift + [ could be assigned (since moving between tabs already works with cmd + shifg + [ etc).

Feature Request: Make shortcuts configurable

Thanks so much for this awesome extension! I'm amazed that the Google/Chromium teams still haven't included this simple functionality.

Anyway. The one thing that I think would make this perfect, would be to add an extension config view that allows for the shortcuts to be configurable.

For example, on OSX, instead of CTRL+SHIFT+[arrow] for the operations, I'd love to be able to use ⌘CMD+SHIFT+[arrow].

Again, thanks so much for this extension. It's already awesome!

Investigate extension functionality in other browsers

It looks like other chromium based browsers seem to support installation of extensions from the Chrome Web Store

Non chromium based:

  1. Verify the extension works with the above listed browsers
  2. Update README to include this information

Collision of shortcut

In Chrome 69 (Mac), default keyboard shortcut crashes.

Basic shortcut is Ctrl + Shift + Left/Right.

But Chrome 69, Alt + Shift + Left/Right is also works.

Using Art crashes system shortcut of mac.

Improve keyboard shortcuts customization instructions in README

The current version of README involves a few steps to get to the dialog where the users can customize keyboard shortcuts. This needs to be updated to simplify the process of customization, since, there's a URL that allows the users to directly get to the keyboard shortcut customization dialog:

chrome://extensions/configureCommands

Chrome 69 address bar bug

Highlight address bar.

Alt/Option + Shift + <-- should do word selection stuff. Instead it now shifts tabs around.

Thanks for helpful extension. I use it all the time.

Wrong shortcut from the address bar

My setup:
image

When the address bar is selected, the shortcut ALT+SHIFT+LEFT, ALT+SHIFT+RIGHT, ALT+SHIFT+UP or ALT+SHIFT+DOWN moves the tab position.

The regular shortcut (the one I picked) works properly.

This prevents me from selecting part of a URL to copy it for instance. Instead of moving the cursor, it moves the tab.

Allow more symbols in custom shortcuts

I tried to change the move left/right shortcut to command+shift+[ and command+shift+] but
I'm prompted to "type a letter".

Screen Shot 2021-11-10 at 11 28 43 AM

Can the validation be relax to allow this?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.