Google Minus One par Claire Rosenthal
Removes the 'Upgrade' advertisement on Google online products, including Docs, Mail, Drive, etc.
MĂ©tadonnĂ©es de lâextension
Ă propos de cette extension
Removes the 'Upgrade' advertisement on Google online products, including Docs, Mail, Drive, etc.
Around 25 lines of actual code. Nothing fancy. I'm going to post the code here in case you want to look at it:
Around 25 lines of actual code. Nothing fancy. I'm going to post the code here in case you want to look at it:
/**
* Project: Goole Minus One Firefox Extension
* File Purpose: This file is the main javascript file for the extension. It finds the
* upgrade advertisement on google pages and remove the html element.
* Responsible Party: Claire Rosenthal
* License: GNU GPLv3
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
// This is a Stack Overflow solution to waiting for and finding an html element using the MutationObserver function.
// Source - https://stackoverflow.com/a/61511955
// Posted by Yong Wang, modified by community. See post 'Timeline' for change history
// Retrieved 2026-07-01, License - CC BY-SA 4.0
function waitForElm(selector) {
return new Promise((resolve) => {
if (document.querySelector(selector)) {
return resolve(document.querySelector(selector));
}
const observer = new MutationObserver((mutations) => {
if (document.querySelector(selector)) {
observer.disconnect();
resolve(document.querySelector(selector));
}
});
// If you get "parameter 1 is not of type 'Node'" error, see https://stackoverflow.com/a/77855838/492336
observer.observe(document.body, {
childList: true,
subtree: true,
});
});
}
// This is where the waiting for and selection of the html element starts.
// Here is where the different selection ids come from:
// .s1rbBe is the upgrade selector for Gmail
// .appsElementsWorkspaceRecommendationContentButtonFull is the upgrade button selector for Google Workspace (Docs, Sheets, etc.)
// .wKxlIc is the upgrade button selector for Google Calendar
// .Iu19ad-OkO9ve-yp5uJf-j is the upgrade button selector for Google Drive
waitForElm(
".s1rbBe,.appsElementsWorkspaceRecommendationContentButtonFull,.wKxlIc,.Iu19ad-OkO9ve-yp5uJf-j",
).then((elm) => {
elm.remove();
});
Noté 0 par 1 personne
Autorisations et données
Autorisations nécessaires :
- Accéder à vos données pour les sites du domaine google.com
Collecte de données :
- Le dĂ©veloppeur indique que cette extension nâa pas besoin de collecter de donnĂ©es.
Plus dâinformations
- Liens du module
- Version
- 0.5
- Taille
- 49,71Â Ko
- DerniĂšre mise Ă jour
- il y a 5 jours (2 juil. 2026)
- Catégories associées
- Historique des versions
- Ajouter Ă la collection