您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Changes tabs title on load with channels username on player.twitch.tv pages.
当前为
// ==UserScript== // @name Change player.twitch.tv Title // @description Changes tabs title on load with channels username on player.twitch.tv pages. // @version 1.1 // @author yungsamd17 // @namespace https://github.com/yungsamd17/Twitch-Addons // @license MIT License // @icon https://raw.githubusercontent.com/yungsamd17/Twitch-Addons/main/chrome/src/icons/favicon.ico // @match https://player.twitch.tv/* // @grant none // @run-at document-end // ==/UserScript== (function() { 'use strict'; // Change tab's title temp. // Check if the current URL matches if (window.location.href.startsWith("https://player.twitch.tv/?channel=")) { // Extract the username from URL const urlParams = new URLSearchParams(window.location.search); const username = urlParams.get("channel"); // Update title document.title = `${username} - Twitch Player`; } window.onload = function() { // Second update title to get full case-censite channel username // Find the element and update the title function findElementAndUpdateTitle() { // Find the element with the specified attribute const element = document.querySelector('[data-test-selector="stream-info-card-component__title-link"]'); if (element) { // Extract the username from element's text const username = element.textContent.trim(); // Update title document.title = `${username} - Twitch Player`; } } // Call the function to execute your code findElementAndUpdateTitle(); }})();
QingJ © 2025
镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址