Rename Tab

rename the tab title

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install a user script manager extension to install this script.

(I already have a user script manager, let me install it!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

Author
K Anc
Daily installs
0
Total installs
163
Ratings
1 0 0
Version
0.4
Created
2021-06-16
Updated
2021-07-30
Size
3.32 KB
License
N/A
Applies to
All sites

Rename Tab 重命名浏览器标签页标题

使用方式

鼠标右键→TampermonkeyRename Tab 选择如下:

  • Temp - Tab 临时性重命名标签标题(关闭浏览器失效,新标签页失效)
  • Forever - Site 永久重命名该站点标题(作用于域名下所有站点,关闭浏览器再次打开依旧生效)
  • Forever - Page 永久重命名该页面标题(作用于站点下此页面,关闭浏览器再次打开依旧生效)
  • Remove - Auto 恢复当前标签标题(可能不是最新的)

优先级

Forever - Page > Forever - Site > Temp - Tab 极端例子:

  1. Temp - Tab google -> 1
  2. Forever - Site 1 -> 2
  3. Forever - Page 2 -> 3

恢复顺序为:

  1. Remove - Auto 3 -> google
  2. 由于存在 Forever - Site 1 -> 2 刷新后仍会变为2 (this is feature not the bug)
  3. Remove - Auto 2 -> google

快捷键

由于Tampermonkey限制,需要点击Tampermonkey插件图标,键盘按下R激活Temp临时重命名。

TODO

[ ] 使用 GM_setValueGM_addValueChangeListener 重写

轻量级使用

如果你有脚本洁癖,只是想轻量级使用 Temp 临时性重命名标签标题 的功能,可以不安装此脚本,而使用小书签,在浏览器书签栏添加一个书签,点击该书签即可使用此功能,书签的URL为:

javascript:(function(){function renameTab(){var tabname=sessionStorage.getItem("tabname");if(tabname&&tabname!=""){document.title=tabname}else{var result=window.prompt("Rename this tab as:",document.title);if(result){document.title=result;sessionStorage.setItem("tabname",result)}}}renameTab()})();

如下图4所示。