1. // ==UserScript==
  2. // @name The Nude - Show directly thumbnails of Actress in "Appears with:" - TEST 3
  3. // @description Show directly thumbnails of Actress in "Appears with:" section. With the help of indefined (thanks)
  4. // @author janvier57
  5. // @namespace https://greasyfork.org/users/7434
  6. // @include https://www.thenude.com/*
  7. // @match https://www.thenude.com/*
  8. // @version 3
  9. // @license unlicense
  10. // @grant none
  11. // ==/UserScript==
  12. // GOOD 1
  13. //.bio-list>li> a[data-img^="https://static.thenude.com/models/"]
  14. $( ".bio-list>li> a[data-img^='https://static.thenude.com/models/']" ).each(function() {
  15. var attr = $(this).attr('data-img');
  16. if (typeof attr !== typeof undefined && attr !== false) {
  17. // 'url('+attr+')' should be "url("+attr+")"
  18. $(this).css('background-image' , 'url("'+attr+'")' );
  19. }
  20. })
  21. // NOT GOOD 2 - RECENT NEWCOMMERS
  22. //https://www.thenude.com/newcomers
  23. //.table.table-hover.table-condensed.model-list-table>tbody>tr>td>a[data-img^='https://static.thenude.com/models/']
  24. $( ".table.table-hover.table-condensed.model-list-table>tbody>tr>td>a[data-img^='https://static.thenude.com/models/']" ).each(function() {
  25. var attr = $(this).attr('data-img');
  26. if (typeof attr !== typeof undefined && attr !== false) {
  27. // 'url('+attr+')' should be "url("+attr+")"
  28. $(this).css('background-image' , 'url("'+attr+'")' );
  29. }
  30. })
  31. // add CSS
  32. $('head').append(`
  33. <style type='text/css'>
  34. ul.bio-list {
  35. display: inline-block !important;
  36. text-align: left !important;
  37. }
  38. ul.bio-list li {
  39. text-align: left !important;
  40. }
  41. ul.bio-list .list-quest {
  42. display: inline-block;
  43. width: 100% !important;
  44. text-align: left !important;
  45. font-size: 15px !important;
  46. background: #111;
  47. }
  48. ul.bio-list >li> a[data-img^='https://static.thenude.com/models/'] {
  49. display: inline-block !important;
  50. vertical-align: bottom !important;
  51. background-size : contain !important;
  52. background-repeat : no-repeat !important;
  53. background-position: center 25px !important;
  54. line-height: 15px !important;
  55. height: 100% !important;
  56. min-height : 195px !important;
  57. max-height : 195px !important;
  58. width : 100% !important;
  59. min-width : 150px !important;
  60. max-width : 150px !important;
  61. margin: 0 -45px 5px 0 !important;
  62. padding: 5px 0 0px 0 !important;
  63. text-align: center !important;
  64. font-size: 15px !important;
  65. overflow: hidden !important;
  66. background-color: black !important;
  67. border: 1px solid red !important;
  68. }
  69. /* GOOD2 */
  70. .table.table-hover.table-condensed.model-list-table>tbody>tr>td>a[data-img^='https://static.thenude.com/models/'] {
  71. display: inline-block !important;
  72. vertical-align: bottom !important;
  73. background-size : contain !important;
  74. background-repeat : no-repeat !important;
  75. background-position: center 25px !important;
  76. line-height: 15px !important;
  77. height: 100% !important;
  78. min-height : 195px !important;
  79. max-height : 195px !important;
  80. width : 100% !important;
  81. min-width : 150px !important;
  82. max-width : 150px !important;
  83. margin: 0 -45px 5px 0 !important;
  84. padding: 5px 0 0px 0 !important;
  85. text-align: center !important;
  86. font-size: 15px !important;
  87. overflow: hidden !important;
  88. background-color: black !important;
  89. border: 1px solid red !important;
  90. background-image: url("https://static.thenude.com/models/Fit Kitty_53326/starthumb.jpg") !important;
  91. }
  92. </style>
  93. `)
  94. console.log('TheNude: CSS added')

New test (but fail) to add thumbnails to:

https://www.thenude.com/newcomers

Not retrive the thumbnails and not add the CSS