Skip to content

Commit

Permalink
Merge pull request #1057 from GrosPoulet/master
Browse files Browse the repository at this point in the history
fix for plug-in: Meetup.com
  • Loading branch information
GrosPoulet authored Nov 19, 2022
2 parents f35208c + 37e9b37 commit 5f4be59
Showing 1 changed file with 12 additions and 6 deletions.
18 changes: 12 additions & 6 deletions plugins/meetup.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,16 @@
var hoverZoomPlugins = hoverZoomPlugins || [];
hoverZoomPlugins.push({
name:'meetup.com',
version:'1.0',
version:'1.1',
prepareImgLinks:function (callback) {

var res = [];
var res = [];

hoverZoom.urlReplace(res,
'img[src]',
/\/\d+x\d+/,
'/2200x2200'
);

hoverZoom.urlReplace(res,
'img[src]',
Expand All @@ -22,17 +28,17 @@ hoverZoomPlugins.push({
var backgroundImageUrl = backgroundImage.replace(/^['"]/,"").replace(/['"]+$/,"");
var reThumb = /(.*)\/(.*)_/
var fullsizeUrl = backgroundImageUrl.replace(reThumb, '$1/highres_');
if (fullsizeUrl != backgroundImageUrl) {
if (fullsizeUrl != backgroundImageUrl) {
var link = $(this);
if (link.data().hoverZoomSrc == undefined) { link.data().hoverZoomSrc = [] }
if (link.data().hoverZoomSrc.indexOf(fullsizeUrl) == -1) {
if (link.data().hoverZoomSrc.indexOf(fullsizeUrl) == -1) {
link.data().hoverZoomSrc.unshift(fullsizeUrl);
res.push(link);
res.push(link);
}
}
}
});

callback($(res), this.name);
}
});

0 comments on commit 5f4be59

Please sign in to comment.