You + Google Menu apt 2

Adds a custom node to the Google menu

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Greasemonkey lub Violentmonkey.

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Violentmonkey.

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Violentmonkey.

Aby zainstalować ten skrypt, wymagana będzie instalacja rozszerzenia Tampermonkey lub Userscripts.

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

Aby zainstalować ten skrypt, musisz zainstalować rozszerzenie menedżera skryptów użytkownika.

(Mam już menedżera skryptów użytkownika, pozwól mi to zainstalować!)

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.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Musisz zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

(Mam już menedżera stylów użytkownika, pozwól mi to zainstalować!)

// ==UserScript==
// @name         You + Google Menu apt 2
// @version      1.0
// @description  Adds a custom node to the Google menu
// @author       Your Name
// @match        https://vanced-youtube.neocities.org/2011/
// @run-at       document_end
// @namespace https://greasyfork.org/users/1090996
// ==/UserScript==

(function() {
    'use strict';

    // Create the new node
    var newNode = document.createElement('li');
    newNode.className = 'gbt';
    newNode.innerHTML = '<a onclick="gbar.qs(this)" class="gbzt" id="gb_2" href="http://www.google.com/imghp?hl=en&amp;tab=wi"><span class="gbtb2"></span><span class="gbts">+You</span></a>';

    // Find the reference node to insert before
    var referenceNode = document.querySelector('li.gbt a#gb_1');

    // Insert the new node before the reference node
    if (referenceNode && referenceNode.parentNode && referenceNode.parentNode.parentNode) {
        referenceNode.parentNode.parentNode.insertBefore(newNode, referenceNode.parentNode);
    }
})();