imageslr / chrome-tab-modifier

Take control of your tabs
https://chrome.google.com/webstore/detail/tab-renamer/kpijejpdbpeaakidlcopnbjohbfimnod
MIT License
10 stars 0 forks source link

Notice

This is a fork version of Tab Modifier with a little bit change.

  1. [New Feature] Support unique rules by url,
  2. [New Feature] Disable a rule temporarily,
  3. [New Feature] Allow to hide right-click menu item.
  4. [Bug Fix] Selector grammar not working when element is lazy-loaded.

You can load unpacked extension in project /dist folder.


icon Tab Modifier

Take control of your tabs.

Build Status devDependency Status

Features

Quick rename can be done by right-clicking anywhere in the page and click on "Rename Tab".

Why?

I needed a quick UI element in Chrome to know the environment of the tab, as a Web developer I often use multiple versions of the same website: local, pre-production and production.

Not easy to find the appropriate tab when you have multiple tabs called "My awesome website".

I created Tab Modifier to add prefixes to website titles with a specific match.

After that, I have added more features like "auto-pin", custom favicons and more.

Focused scope

Tab Modifier is based on user rules and act on the tab URL that matches the first seen rule.

Aware of that, there is no reason to include a feature that is not "rule-based". Prefer to install specific extensions.

Installation

Install from the Chrome Web Store.

Also available for Opera Browser.

Not available for Firefox, refer to #46.

Usage

Demo

Before

tabs before

After

tabs after

Options

Tab Rules

tab_rules

Tab Rules Form

tab_rules_form

Settings

settings

Examples

You have infinite possibilities, here are some configurations:

Pin all tabs:

Say hello to all Google websites:

Disguise GitHub as Google

Prevent accidental tab closure:

Mute all Youtube videos by default:

Set blank icon on Pinterest:

Get only one GMail tab opened at once:

Pin all PNG images (useless):

Customize title with HTML selector and Regexp:

Tab title will be: "sylouuu/chrome-tab-modifier: Take control of your tabs | chrome-tab-modifier by sylouuu"

Match GitHub repositories:

Customize GMail title with Title matcher and URL matcher:

Tab title will be: "youremail@gmail.com | mail.google.com"

Github final path as title for blobs:

And now, build your own... :muscle:

Ideas

Known issues

Local icon path doesn't work

Related issue: #5

Due to browser security restrictions, this path won't work: file://<path>/icon.png. Your icon will not be shown by Chrome.

Alternatively, you can upload your icon somewhere like imgur.com and paste the direct link in your rule.

Another solution consists in transform your image in the Data URI format. Go to ezgif.com and paste the given output (the long text) in the icon input on your rule.

Chrome system pages chrome://

Related issues: #11, #14

Pages that start with chrome:// URL are protected. No content script can be injected then Tab Modifier will not work on these pages.

Local files file:///

Related issue: #13

By default, extensions don't have access to local files. You have to opt-in "Allow access to file URLs" from chrome://extensions/?id=hcbgadmbdkiilgpifjgcakjehmafcjai.

Protected action is not triggered

Related issue: #95

Since Chrome 90, the JS event that triggers a refresh or a closure has been reworked. See related issue.

Changelog

See releases section.

Development

In case you want to contribute or just want to play with the code, follow the guide.

Setup

Download and install NodeJS to get npm.

Install gulp and yarn globally:

npm install -g gulp yarn

Clone the project and install dependencies with yarn.

Type gulp to watch your changes inside src/ folder or type gulp build after each change.

Load local extension in Chrome

Go to chrome://extensions/ and enable the "Developer mode".

Click on "Load unpacked extension..." and select the project dist/ folder.

Donators

A huge thanks to all donators!

If you like my work and you want to support me, visit the PayPal link. ;)

License

See license file.