Xhamster Helper - Totally or Viewable DELETED Users (comp Beta) v.32

Companion for my fork of Xhamster Private Profiles : mark viewable deleted user with a Green X ((lib-add-stylish-string))

As of 2017-10-02. See the latest version.

  1. // ==UserScript==
  2. // @name Xhamster Helper - Totally or Viewable DELETED Users (comp Beta) v.32
  3. // @namespace https://greasyfork.org/en/users/7434-janvier56
  4. // @description Companion for my fork of Xhamster Private Profiles : mark viewable deleted user with a Green X ((lib-add-stylish-string))
  5. //
  6. // @version v.32
  7. //
  8. // @include https://*xhamster.com/*
  9. //
  10. // @require https://greasyfork.org/scripts/24621-lib-add-stylish-string/code/lib-add-stylish-string.js
  11. //
  12. // @run-at document-start
  13. //
  14. // @resource css https://pastebin.com/raw/MNV4rmS0
  15. //
  16. // @grant GM_getResourceText
  17. //
  18. // ==/UserScript==
  19.  
  20. window.addStylish(GM_getResourceText('css'));
  21. /*
  22. ======== pseudo elements - innerHTML - Using attr(), with pseudo-elements and JavaScript
  23. == https://tiffanybbrown.com/2014/11/using-attr-with-pseudo-elements-and-javascript/
  24. we'll set a data-txt attribute using DOM scripting.
  25. Here we've just copied the innerHTML of our paragraph element
  26. to the data-txt attribute when the DOMContentLoaded event fires.
  27. window.addEventListener('DOMContentLoaded', function(){
  28. var p = document.querySelector('p');
  29. p.dataset.txt = p.innerHTML;
  30. }
  31. window.addEventListener('DOMContentLoaded', function(){
  32. var p = document.querySelector('p');
  33. p.dataset.txt = p.innerHTML;
  34. p.classList.add('triptych');
  35. },false);
  36.  
  37. */
  38. window.addEventListener('DOMContentLoaded', function(){
  39. var p = document.querySelector('.entity-author-container__name>span');
  40. p.dataset.txt = p.innerHTML;
  41. p.classList.add('DEL');
  42. },false);