|
6 | 6 | // @description Powerful picture viewing tool online, which can popup/scale/rotate/batch save pictures automatically |
7 | 7 | // @description:zh-CN 在线看图工具,支持图片翻转、旋转、缩放、弹出大图、批量保存 |
8 | 8 | // @description:zh-TW 線上看圖工具,支援圖片翻轉、旋轉、縮放、彈出大圖、批量儲存 |
9 | | -// @version 2021.8.21.2 |
| 9 | +// @version 2021.9.24.1 |
10 | 10 | // @created 2011-6-15 |
11 | 11 | // @namespace http://userscripts.org/users/NLF |
12 | 12 | // @homepage http://hoothin.com |
|
1249 | 1249 | getImage: function() { |
1250 | 1250 | return this.src.replace(/scale\-to\-width\-down\/\d+/i,"").replace(/smart\/width\/\d+\/height\/\d+/i,""); |
1251 | 1251 | } |
| 1252 | + }, |
| 1253 | + {name: "yande", |
| 1254 | + url: /yande\.re/, |
| 1255 | + getImage: function() { |
| 1256 | + if(this && this.parentNode && this.parentNode.parentNode && this.parentNode.parentNode.nextSibling && this.parentNode.parentNode.nextSibling.classList && this.parentNode.parentNode.nextSibling.classList.contains("largeimg")){ |
| 1257 | + return this.parentNode.parentNode.nextSibling.href; |
| 1258 | + } |
| 1259 | + return this.src; |
| 1260 | + } |
1252 | 1261 | } |
1253 | 1262 | ]; |
1254 | 1263 |
|
|
4743 | 4752 | }, 1000); |
4744 | 4753 | }, |
4745 | 4754 | exportImages: function () { // 导出所有图片到新窗口 |
4746 | | - var nodes = document.querySelectorAll('.pv-gallery-sidebar-thumb-container[data-src]'); |
4747 | | - var arr = [].map.call(nodes, function(node){ |
4748 | | - if(unsafeWindow.getComputedStyle(node).display=="none")return ""; |
4749 | | - else return '<div><img src=' + node.dataset.src + '></div>' |
4750 | | - }); |
| 4755 | + var nodes = document.querySelectorAll('.pv-gallery-sidebar-thumb-container[data-src]'),i; |
| 4756 | + //var arr = Array.prototype.map.call(nodes, function(node){ |
| 4757 | + // if(unsafeWindow.getComputedStyle(node).display=="none")return ""; |
| 4758 | + // else return '<div><img src=' + node.dataset.src + '></div>' |
| 4759 | + //}); |
| 4760 | + |
| 4761 | + var arr=[]; |
| 4762 | + for (i = 0; i < nodes.length; ++i) { |
| 4763 | + if(unsafeWindow.getComputedStyle(nodes[i]).display=="none")arr.push(""); |
| 4764 | + else arr.push('<div><img src=' + nodes[i].dataset.src + '></div>'); |
| 4765 | + } |
4751 | 4766 |
|
4752 | 4767 | var title = document.title; |
4753 | 4768 |
|
|
0 commit comments