Skip to content

Commit

Permalink
More websites/rules
Browse files Browse the repository at this point in the history
  • Loading branch information
qsniyg committed Apr 30, 2024
1 parent 960ee8f commit a4febd5
Show file tree
Hide file tree
Showing 2 changed files with 49 additions and 0 deletions.
26 changes: 26 additions & 0 deletions src/userscript.ts
Original file line number Diff line number Diff line change
Expand Up @@ -113682,6 +113682,32 @@ var $$IMU_EXPORT$$;
}
}

if (domain === "images.mnstatic.com") {
// thanks to anonymous for reporting:
// https://images.mnstatic.com/3e/f2/3ef2707ef405e4f31f95453f4217c23c.jpg?quality=86&format=pjpg&fit=crop&width=236&height=190&aspect_ratio=236%3A190
// https://images.mnstatic.com/3e/f2/3ef2707ef405e4f31f95453f4217c23c.jpg?quality=100&format=png
return src.replace(/(?:\?.*)?$/, "?quality=100&format=png");
}

if (domain_nosub === "mnstatic.com" && /^photo[0-9]+x[0-9]+\./.test(domain)) {
// thanks to anonymous for reporting:
// https://photo620x400.mnstatic.com/3ef2707ef405e4f31f95453f4217c23c/abbaye-du-mont_saint_michel.jpg?quality=70&format=pjpg
// https://images.mnstatic.com/3e/f2/3ef2707ef405e4f31f95453f4217c23c.jpg?quality=100&format=png
match = src.match(/:\/\/[^/]+\/+([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{10,})\/+/);
if (match) {
return "https://images.mnstatic.com/" + match[1] + "/" + match[2] + "/" + match[1] + match[2] + match[3] + ".jpg?quality=100";
}
}

if (domain_nowww === "esprit-photo.com") {
// thanks to anonymous for reporting:
// https://esprit-photo.com/render/w640/02.celebrations/03.paques/081.chemin-de-croix-virtuel/EX15-0001_Expo-Chemin-de-Croix-G-SCHILLING-WEB_03_Copyright_N.JUNG_Photographie.Pro.jpg
// https://esprit-photo.com/content/02.celebrations/03.paques/081.chemin-de-croix-virtuel/EX15-0001_Expo-Chemin-de-Croix-G-SCHILLING-WEB_03_Copyright_N.JUNG_Photographie.Pro.jpg
// other:
// https://www.esprit-photo.com/content/09.vie_paroisses/11.paroisse-saint-jean-baptiste-libourne-bordeaux/06.veillees/01.Veillee-Sainte-Marie-Madeleine-a-St-Jean-Baptiste-de-Libourne/__Veillee-Sainte-Marie-Madeleine-a-St-Jean-Baptiste-de-Libourne.jpg -- 2114x3038
return src.replace(/\/render\/+w[0-9]+\/+/, "/content/");
}




Expand Down
23 changes: 23 additions & 0 deletions userscript.user.js
Original file line number Diff line number Diff line change
Expand Up @@ -102063,6 +102063,29 @@ var $$IMU_EXPORT$$;
problems: { possibly_upscaled: true }
};
}
if (domain === "images.mnstatic.com") {
// thanks to anonymous for reporting:
// https://images.mnstatic.com/3e/f2/3ef2707ef405e4f31f95453f4217c23c.jpg?quality=86&format=pjpg&fit=crop&width=236&height=190&aspect_ratio=236%3A190
// https://images.mnstatic.com/3e/f2/3ef2707ef405e4f31f95453f4217c23c.jpg?quality=100&format=png
return src.replace(/(?:\?.*)?$/, "?quality=100&format=png");
}
if (domain_nosub === "mnstatic.com" && /^photo[0-9]+x[0-9]+\./.test(domain)) {
// thanks to anonymous for reporting:
// https://photo620x400.mnstatic.com/3ef2707ef405e4f31f95453f4217c23c/abbaye-du-mont_saint_michel.jpg?quality=70&format=pjpg
// https://images.mnstatic.com/3e/f2/3ef2707ef405e4f31f95453f4217c23c.jpg?quality=100&format=png
match = src.match(/:\/\/[^/]+\/+([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{10,})\/+/);
if (match) {
return "https://images.mnstatic.com/" + match[1] + "/" + match[2] + "/" + match[1] + match[2] + match[3] + ".jpg?quality=100";
}
}
if (domain_nowww === "esprit-photo.com") {
// thanks to anonymous for reporting:
// https://esprit-photo.com/render/w640/02.celebrations/03.paques/081.chemin-de-croix-virtuel/EX15-0001_Expo-Chemin-de-Croix-G-SCHILLING-WEB_03_Copyright_N.JUNG_Photographie.Pro.jpg
// https://esprit-photo.com/content/02.celebrations/03.paques/081.chemin-de-croix-virtuel/EX15-0001_Expo-Chemin-de-Croix-G-SCHILLING-WEB_03_Copyright_N.JUNG_Photographie.Pro.jpg
// other:
// https://www.esprit-photo.com/content/09.vie_paroisses/11.paroisse-saint-jean-baptiste-libourne-bordeaux/06.veillees/01.Veillee-Sainte-Marie-Madeleine-a-St-Jean-Baptiste-de-Libourne/__Veillee-Sainte-Marie-Madeleine-a-St-Jean-Baptiste-de-Libourne.jpg -- 2114x3038
return src.replace(/\/render\/+w[0-9]+\/+/, "/content/");
}
// -- 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 a4febd5

Please sign in to comment.