| 36 | 1 // ==UserScript== | 
| 42 | 2 // @name         Cuffs/Hulotte tuning | 
| 36 | 3 // @namespace    https://myconan.net | 
| 47 | 4 // @version      1.1.2 | 
| 42 | 5 // @description  Strip out Cuffs/Hulotte age confirmation popup, disables lightbox | 
| 36 | 6 // @author       nanaya | 
|  | 7 // @match        http://www.cuffs.co.jp/* | 
| 41 | 8 // @match        http://www.cuffs-cube.jp/* | 
| 36 | 9 // @match        http://hulotte.jp/* | 
|  | 10 // @grant        none | 
|  | 11 // @downloadURL  https://bitbucket.org/!api/2.0/snippets/nanayapro/TK64/tip/files/cuffs-hulotte-popup.user.js | 
|  | 12 // ==/UserScript== | 
|  | 13 | 
| 38 | 14 ;(function() { | 
| 42 | 15     "use strict"; | 
|  | 16 | 
|  | 17     var $ = jQuery; | 
| 44 | 18     var rules = []; | 
|  | 19     var i; | 
|  | 20     var styleEl; | 
| 43 | 21 | 
| 42 | 22     if (document.querySelector('body > #mainContent') != null) { | 
| 44 | 23         rules.push('body > :not(#mainContent) { display: none !important; }'); | 
| 43 | 24     } | 
|  | 25 | 
| 45 | 26     rules.push('#load_bg { display: none !important; }'); | 
|  | 27     rules.push('body > .modal { display: none !important; }'); | 
| 46 | 28     rules.push('body > div[style*="position: fixed"] { display: none !important; }'); | 
| 45 | 29 | 
| 44 | 30     for (i = 0; i < rules.length; i++) { | 
|  | 31         styleEl = document.createElement('style'); | 
| 42 | 32         document.head.appendChild(styleEl); | 
| 44 | 33         styleEl.sheet.insertRule(rules[i], 0); | 
| 42 | 34     } | 
| 38 | 35 | 
| 42 | 36     $(function () { | 
|  | 37         $('.cboxElement').removeClass('cboxElement'); | 
|  | 38     }); | 
| 47 | 39 | 
|  | 40     // force remove modal | 
|  | 41     $.cookie('modal', 'off'); | 
|  | 42     if (typeof stopload === 'function') { | 
|  | 43         stopload(); | 
|  | 44     } | 
| 40 | 45 }).call(); |