'Select all' in Basic HTML View in Gmail

an easy way to select all mails in basic HTML view of Gmail

  1. // ==UserScript==
  2. // @name 'Select all' in Basic HTML View in Gmail
  3. // @namespace http://vaxquis.tk
  4. // @version 0.1
  5. // @description an easy way to select all mails in basic HTML view of Gmail
  6. // @author vaxquis
  7. // @match https://mail.google.com/*
  8. // @grant none
  9. // ==/UserScript==
  10.  
  11. (function() {
  12. 'use strict';
  13. const target = document.querySelector('form[name=f] table td');
  14. const button = document.createElement('BUTTON');
  15. const text = document.createTextNode('Select all');
  16. button.style.marginRight = '1rem';
  17. button.appendChild( text );
  18. button.onclick = () => {
  19. document.querySelectorAll('input[name=t]').forEach( t => { t.checked = true; } );
  20. return false;
  21. }
  22. target.insertBefore(button, target.children[0]);
  23. })();

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址