Gaia Online PM improvements

Improves PMs on Gaia in a few different ways.

  1. // ==UserScript==
  2. // @name Gaia Online PM improvements
  3. // @namespace http://mathemaniac.org
  4. // @version 1.1.1
  5. // @description Improves PMs on Gaia in a few different ways.
  6. // @match https://www.gaiaonline.com/profile/privmsg.php*
  7. // @require http://ajax.googleapis.com/ajax/libs/jquery/1.7/jquery.min.js
  8. // @copyright 2012-2023, Sebastian Paaske Tørholm
  9. // ==/UserScript==
  10.  
  11. // Downloaded from http://userscripts.org/scripts/show/137486
  12.  
  13. $('button#btn_delete').each( function (i, e) {
  14. $(e).after('<a href="#" id="select_read" style="padding-left: 1em; padding-right: 1em;">Select replied</a>');
  15. $('#select_read').click( function (ev) {
  16. $('tr').each( function (i, e) {
  17. $('input[type="checkbox"]', e).attr('checked', $('img[alt="Replied Message"]', e).length > 0);
  18. });
  19. ev.preventDefault();
  20. } );
  21. } );
  22.  
  23. (function () {
  24. // Hide quotes more than 10 levels deep.
  25. var levels = 10;
  26. var selector = "";
  27. for (var i = 0; i < levels; i++) {
  28. selector += 'div.quote ';
  29. }
  30. var first = $(selector + 'div.quoted').first();
  31.  
  32. first.css({'display': 'none'});
  33. first.before('<a id="mathemaniac_show_deeply_nested" href="#">Show hidden quotes.</a>');
  34. var nestlink = $('#mathemaniac_show_deeply_nested');
  35. nestlink.css({
  36. 'display': 'block',
  37. 'border': '1px solid red',
  38. 'padding': '0.25em',
  39. 'margin': '0.25em',
  40. 'text-align': 'center'
  41. });
  42. nestlink.click( function (ev) {
  43. nestlink.remove();
  44. first.css({'display': 'inherit'});
  45. ev.preventDefault();
  46. });
  47. })();
  48.