Skip to content

Commit

Permalink
More websites/rules
Browse files Browse the repository at this point in the history
  • Loading branch information
qsniyg committed Aug 20, 2024
1 parent 729ec0a commit 55354f2
Show file tree
Hide file tree
Showing 2 changed files with 45 additions and 4 deletions.
25 changes: 23 additions & 2 deletions src/userscript.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43061,6 +43061,12 @@ var $$IMU_EXPORT$$;
// https://d34gglw95p9zsk.cloudfront.net/item_cocreco_images/images/000/122/614/medium/eb02072f-fca2-4a0e-bbd8-7627229f6930.jpg?1672023100
// https://d34gglw95p9zsk.cloudfront.net/item_cocreco_images/images/000/122/614/original/eb02072f-fca2-4a0e-bbd8-7627229f6930.jpg?1672023100
domain === "d34gglw95p9zsk.cloudfront.net" ||
// thanks to anonymous for reporting:
// https://www.scandalbeauties.com/system/blog_headers/avatars/000/024/543/cropped/3810dcb63b142b34647e5c319a5c0689.jpeg
// https://www.scandalbeauties.com/system/blog_headers/avatars/000/024/543/original/3810dcb63b142b34647e5c319a5c0689.jpeg
// https://www.scandalbeauties.com/system/blog_headers/ultras/000/024/216/cropped/d3391146a7e3c832d1269c78cca7d7e8.jpeg
// https://www.scandalbeauties.com/system/blog_headers/ultras/000/024/216/original/d3391146a7e3c832d1269c78cca7d7e8.jpeg
domain_nowww === "scandalbeauties.com" ||
// https://sonar.es/system/attached_images/18702/medium/badgyal_xs_sonar2017_fernandoschlaepfer_004.jpg?1497713257 -- stretched?
// https://sonar.es/system/attached_images/18702/original/badgyal_xs_sonar2017_fernandoschlaepfer_004.jpg?1497713257
domain_nowww === "sonar.es") {
Expand All @@ -43070,7 +43076,7 @@ var $$IMU_EXPORT$$;
return src
.replace(/(\/attached_images\/+[0-9]+\/+)[a-z]+\/+/, "$1original/")
.replace(/(\/system\/+resources\/+)thumbnails\/+/, "$1previews/")
.replace(/(\/(?:(?:system|images)\/+)?(?:(?:attached|item)_images|App\/+BlogBody|post_pictures|events|posts|items|articles|file_uploads|screenshots|resources|pictures|guides|Image|item_cocreco_images)\/+(?:(?:images|photos|files|assets|pictures|posters|uploads|screenshots|previews|imgs|cropped_images)\/+)?(?:[0-9]{3}\/+){3})[a-z_0-9]+\/+/, "$1original/");
.replace(/(\/(?:(?:system|images)\/+)?(?:(?:attached|item)_images|App\/+BlogBody|post_pictures|events|posts|items|articles|file_uploads|screenshots|resources|pictures|guides|Image|item_cocreco_images|blog_headers)\/+(?:(?:images|photos|files|assets|pictures|posters|uploads|screenshots|previews|imgs|cropped_images|avatars|ultras)\/+)?(?:[0-9]{3}\/+){3})[a-z_0-9]+\/+/, "$1original/");
//return src.replace(/(\/system\/(?:post_pictures\/(?:files|assets|pictures)\/|posts\/posters\/|events\/images\/)(?:[0-9]+\/){3})[a-z]+(\/[^/]*)$/, "$1original$2");
//return src.replace(/\/[a-z]*\/([-0-9a-f]*\.[^/.]*)$/, "/original/$1");
//return src.replace(/(\/[0-9]+\/[0-9]+\/[0-9]+)\/[a-z]+\/([^/]*)$/, "$1/original/$2");
Expand Down Expand Up @@ -51120,6 +51126,10 @@ var $$IMU_EXPORT$$;
// https://store.storeimages.cdn-apple.com/4982/as-images.apple.com/is/HNGY2?wid=38&hei=38&fmt=jpeg&qlt=95&.v=1620945188000
// https://store.storeimages.cdn-apple.com/4982/as-images.apple.com/is/HNGY2?scl=1&fmt=png-alpha
domain === "store.storeimages.cdn-apple.com" ||
// thanks to anonymous for reporting:
// https://www.sony.lu/image/a71e51053c03634f8ff5d4a78fb4b1fb?fmt=png-alpha&wid=900&hei=800
// https://www.sony.lu/image/a71e51053c03634f8ff5d4a78fb4b1fb?scl=1&fmt=png-alpha
(domain_nowww === "sony.lu" && string_indexof(src, "/image/") >= 0) ||
/^[a-z]+:\/\/[^/]+\/+is\/+image\/+[^/]+\/+[^/]+(?:[?#].*)?$/.test(src)) {
// https://dyson-h.assetsadobe2.com/is/image//content/dam/dyson/products/hair-care/dyson-supersonic/customisation/personal-care-dyson-supersonic-customisation-homepage.jpg?scl=1
// https://dyson-h.assetsadobe2.com/is/image//content/dam/dyson/icons/owner-footer/register-my-machine.png?scl=1&fmt=png-alpha
Expand Down Expand Up @@ -111985,7 +111995,11 @@ var $$IMU_EXPORT$$;
// thanks to anonymous for reporting:
// https://cdn.marvel.com/content/1x/loki_card.png
// https://cdn.marvel.com/content/2x/loki_card.png
return src.replace(/\/content\/+1x\/+/, "/content/2x/");
// https://cdn.marvel.com/u/prod/marvel/i/mg/7/70/65f9a38967f2b/portrait_uncanny.jpg
// https://cdn.marvel.com/u/prod/marvel/i/mg/7/70/65f9a38967f2b/clean.jpg
return src
.replace(/\/content\/+1x\/+/, "/content/2x/")
.replace(/(\/u\/+prod\/+marvel\/+.*\/[0-9a-f]{5,}\/+)portrait_uncanny\./, "$1clean.");
}

if (domain === "cdn1.mmwst.ru") {
Expand Down Expand Up @@ -116359,6 +116373,13 @@ var $$IMU_EXPORT$$;
return src.replace(/(\/prod\/+[0-9]+_[_a-z]+_)(?:small|medium|large)\./, "$1original.");
}

if (domain === "img.edilportale.com") {
// thanks to anonymous for reporting:
// https://img.edilportale.com/product-thumbs/b_FLETCHER-Laskasas-570394-rel672028f4.jpg
// https://img.edilportale.com/products/FLETCHER-Laskasas-570394-rel672028f4.jpg
return src.replace(/\/product-thumbs\/+[a-z]_/, "/products/");
}




Expand Down
24 changes: 22 additions & 2 deletions userscript.user.js
Original file line number Diff line number Diff line change
Expand Up @@ -39456,6 +39456,12 @@ var $$IMU_EXPORT$$;
// https://d34gglw95p9zsk.cloudfront.net/item_cocreco_images/images/000/122/614/medium/eb02072f-fca2-4a0e-bbd8-7627229f6930.jpg?1672023100
// https://d34gglw95p9zsk.cloudfront.net/item_cocreco_images/images/000/122/614/original/eb02072f-fca2-4a0e-bbd8-7627229f6930.jpg?1672023100
domain === "d34gglw95p9zsk.cloudfront.net" ||
// thanks to anonymous for reporting:
// https://www.scandalbeauties.com/system/blog_headers/avatars/000/024/543/cropped/3810dcb63b142b34647e5c319a5c0689.jpeg
// https://www.scandalbeauties.com/system/blog_headers/avatars/000/024/543/original/3810dcb63b142b34647e5c319a5c0689.jpeg
// https://www.scandalbeauties.com/system/blog_headers/ultras/000/024/216/cropped/d3391146a7e3c832d1269c78cca7d7e8.jpeg
// https://www.scandalbeauties.com/system/blog_headers/ultras/000/024/216/original/d3391146a7e3c832d1269c78cca7d7e8.jpeg
domain_nowww === "scandalbeauties.com" ||
// https://sonar.es/system/attached_images/18702/medium/badgyal_xs_sonar2017_fernandoschlaepfer_004.jpg?1497713257 -- stretched?
// https://sonar.es/system/attached_images/18702/original/badgyal_xs_sonar2017_fernandoschlaepfer_004.jpg?1497713257
domain_nowww === "sonar.es") {
Expand All @@ -39465,7 +39471,7 @@ var $$IMU_EXPORT$$;
return src
.replace(/(\/attached_images\/+[0-9]+\/+)[a-z]+\/+/, "$1original/")
.replace(/(\/system\/+resources\/+)thumbnails\/+/, "$1previews/")
.replace(/(\/(?:(?:system|images)\/+)?(?:(?:attached|item)_images|App\/+BlogBody|post_pictures|events|posts|items|articles|file_uploads|screenshots|resources|pictures|guides|Image|item_cocreco_images)\/+(?:(?:images|photos|files|assets|pictures|posters|uploads|screenshots|previews|imgs|cropped_images)\/+)?(?:[0-9]{3}\/+){3})[a-z_0-9]+\/+/, "$1original/");
.replace(/(\/(?:(?:system|images)\/+)?(?:(?:attached|item)_images|App\/+BlogBody|post_pictures|events|posts|items|articles|file_uploads|screenshots|resources|pictures|guides|Image|item_cocreco_images|blog_headers)\/+(?:(?:images|photos|files|assets|pictures|posters|uploads|screenshots|previews|imgs|cropped_images|avatars|ultras)\/+)?(?:[0-9]{3}\/+){3})[a-z_0-9]+\/+/, "$1original/");
//return src.replace(/(\/system\/(?:post_pictures\/(?:files|assets|pictures)\/|posts\/posters\/|events\/images\/)(?:[0-9]+\/){3})[a-z]+(\/[^/]*)$/, "$1original$2");
//return src.replace(/\/[a-z]*\/([-0-9a-f]*\.[^/.]*)$/, "/original/$1");
//return src.replace(/(\/[0-9]+\/[0-9]+\/[0-9]+)\/[a-z]+\/([^/]*)$/, "$1/original/$2");
Expand Down Expand Up @@ -46730,6 +46736,10 @@ var $$IMU_EXPORT$$;
// https://store.storeimages.cdn-apple.com/4982/as-images.apple.com/is/HNGY2?wid=38&hei=38&fmt=jpeg&qlt=95&.v=1620945188000
// https://store.storeimages.cdn-apple.com/4982/as-images.apple.com/is/HNGY2?scl=1&fmt=png-alpha
domain === "store.storeimages.cdn-apple.com" ||
// thanks to anonymous for reporting:
// https://www.sony.lu/image/a71e51053c03634f8ff5d4a78fb4b1fb?fmt=png-alpha&wid=900&hei=800
// https://www.sony.lu/image/a71e51053c03634f8ff5d4a78fb4b1fb?scl=1&fmt=png-alpha
(domain_nowww === "sony.lu" && string_indexof(src, "/image/") >= 0) ||
/^[a-z]+:\/\/[^/]+\/+is\/+image\/+[^/]+\/+[^/]+(?:[?#].*)?$/.test(src)) {
// https://dyson-h.assetsadobe2.com/is/image//content/dam/dyson/products/hair-care/dyson-supersonic/customisation/personal-care-dyson-supersonic-customisation-homepage.jpg?scl=1
// https://dyson-h.assetsadobe2.com/is/image//content/dam/dyson/icons/owner-footer/register-my-machine.png?scl=1&fmt=png-alpha
Expand Down Expand Up @@ -100672,7 +100682,11 @@ var $$IMU_EXPORT$$;
// thanks to anonymous for reporting:
// https://cdn.marvel.com/content/1x/loki_card.png
// https://cdn.marvel.com/content/2x/loki_card.png
return src.replace(/\/content\/+1x\/+/, "/content/2x/");
// https://cdn.marvel.com/u/prod/marvel/i/mg/7/70/65f9a38967f2b/portrait_uncanny.jpg
// https://cdn.marvel.com/u/prod/marvel/i/mg/7/70/65f9a38967f2b/clean.jpg
return src
.replace(/\/content\/+1x\/+/, "/content/2x/")
.replace(/(\/u\/+prod\/+marvel\/+.*\/[0-9a-f]{5,}\/+)portrait_uncanny\./, "$1clean.");
}
if (domain === "cdn1.mmwst.ru") {
// thanks to anonymous for reporting:
Expand Down Expand Up @@ -104562,6 +104576,12 @@ var $$IMU_EXPORT$$;
// https://kirja.s3.amazonaws.com/prod/9789520425715_frontcover_final_original.jpg -- 1642x2610
return src.replace(/(\/prod\/+[0-9]+_[_a-z]+_)(?:small|medium|large)\./, "$1original.");
}
if (domain === "img.edilportale.com") {
// thanks to anonymous for reporting:
// https://img.edilportale.com/product-thumbs/b_FLETCHER-Laskasas-570394-rel672028f4.jpg
// https://img.edilportale.com/products/FLETCHER-Laskasas-570394-rel672028f4.jpg
return src.replace(/\/product-thumbs\/+[a-z]_/, "/products/");
}
// -- general rules --
if (src.match(/\/ImageGen\.ashx\?/)) {
// http://www.lookalikes.info/umbraco/ImageGen.ashx?image=/media/97522/nick%20hewer%20-%20mark%20brown.jpeg&width=250&constrain=true
Expand Down

0 comments on commit 55354f2

Please sign in to comment.