Netvibes: remove clutter

Removes netvibes clutter

  1. // ==UserScript==
  2. // @name Netvibes: remove clutter
  3. // @namespace https://greasyfork.org/en/users/8981-buzz
  4. // @description Removes netvibes clutter
  5. // @author buzz
  6. // @require https://code.jquery.com/jquery-2.2.0.min.js
  7. // @version 0.3
  8. // @license GPLv2
  9. // @match https://www.netvibes.com/dashboard/*
  10. // @grant GM_addStyle
  11. // @noframes
  12. // ==/UserScript==
  13. /* jshint -W097 */
  14. /*global window: false, document: false, $: false, GM_addStyle: false */
  15. 'use strict';
  16.  
  17. jQuery(function() {
  18. var $b = $('body'), sel = 'body.clutter_removed ';
  19. GM_addStyle(
  20. sel + '#top { display: none; }' +
  21. sel + '#header { display: none; }' +
  22. sel + '#nv-panel { display: none; }' +
  23. sel + '#footer { display: none !important; }' +
  24. '#clutter_toggle {' +
  25. ' position: absolute;' +
  26. ' top: 0; left: 0;' +
  27. ' z-index:999;' +
  28. ' cursor: pointer;' +
  29. ' border-top: none; border-right: 1px solid #B5B5B5; border-bottom: 1px solid #949494; border-left: none; ' +
  30. ' outline: none;' +
  31. ' padding: 0 2px;' +
  32. ' font-size: 16px;' +
  33. ' background-color: #F1F1F1;' +
  34. ' border-bottom-right-radius: 3px;' +
  35. '}' +
  36. '#clutter_toggle:hover {' +
  37. ' background-color: #F1F1F1;' +
  38. '}'
  39. );
  40. $b
  41. .addClass('clutter_removed')
  42. .prepend('<button id="clutter_toggle" title="Toggle clutter!">&#9776;</button>');
  43. $('#clutter_toggle').click(function() {
  44. $b.toggleClass('clutter_removed');
  45. });
  46. });