Skip to content

Commit 58ac68c

Browse files
committed
Update pvcep_rules.js
1 parent 2a00606 commit 58ac68c

File tree

1 file changed

+3
-9
lines changed

1 file changed

+3
-9
lines changed

Picviewer CE+/pvcep_rules.js

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1004,15 +1004,15 @@ var siteInfo = [
10041004
if (!img) return;
10051005
newsrc = img.src;
10061006
}
1007-
return newsrc.replace(/\?.*$/i,"");
1007+
return newsrc.replace(/\?.*$/i,"").replace(/\/an_webp\/([^\/]+)\/mqdefault_6s\.webp/, "/vi/$1/hqdefault.jpg");
10081008
},
10091009
getImage: function(a, p) {
10101010
var newsrc=this.src;
10111011
if(p[2] && this.classList.contains('ytd-moving-thumbnail-renderer')){
10121012
newsrc = p[2].querySelector("img").src;
10131013
}
10141014
if(!newsrc || newsrc.indexOf("i.ytimg.com") == -1) return;
1015-
return newsrc.replace(/\?.*$/i,"");
1015+
return newsrc.replace(/\?.*$/i,"").replace(/\/an_webp\/([^\/]+)\/mqdefault_6s\.webp/, "/vi/$1/hqdefault.jpg");
10161016
}
10171017
},
10181018
{
@@ -1559,13 +1559,7 @@ var siteInfo = [
15591559
name: "Sankaku Complex",
15601560
url:/sankakucomplex\.com/,
15611561
xhr:{
1562-
url: function(a, p) {
1563-
const re = /^https?:\/\/(?:www\.)?((?:idol|chan)\.)?(sankaku)complex(\.com\/)(?:\w{2}\/)?(post)s?\/(?:show\/)?([a-zA-Z0-9]+).*/;
1564-
const $ = a && a.href.match(re);
1565-
if ($) {
1566-
return !$[1] ? `https://${$[2]}api${$[3]+$[4]}s/${$[5]}/fu` : $[0];
1567-
}
1568-
},
1562+
url: ["^https?://(?:www\\.)?(sankaku)complex(\\.com/)(?:\\w{2}/)?(post)s?/(?:show/)?([a-zA-Z0-9]+).*", "https://$1api$2$3s/$4/fu"],
15691563
query: function(html, doc, url) {
15701564
const re = /^https?:\/\/((?:idol|chan|www)\.)?(sankaku)complex(\.com\/)(?:\w{2}\/)?(post)s?\/(?:show\/)?([a-zA-Z0-9]+).*/;
15711565
const $ = url.match(re);

0 commit comments

Comments
 (0)