Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

react-photo-gallery

Package Overview
Dependencies
Maintainers
1
Versions
97
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-photo-gallery - npm Package Compare versions

Comparing version 5.3.0 to 5.4.0

3

examples/dist/bundle.js

@@ -184,2 +184,3 @@ require=(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({"react-photo-gallery":[function(require,module,exports){

},{"react":undefined}]},{},[]);
},{"react":undefined}]},{},[])
//# sourceMappingURL=data:application/json;charset:utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIm5vZGVfbW9kdWxlcy9icm93c2VyLXBhY2svX3ByZWx1ZGUuanMiLCIvVXNlcnMvb2N0YXZpYS9kZXYvcmVhY3QtcGhvdG8tZ2FsbGVyeS9zcmMvR2FsbGVyeS5qcyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQTs7Ozs7Ozs7Ozs7Ozs7Ozs7cUJDQWtCLE9BQU87Ozs7SUFFbkIsT0FBTztjQUFQLE9BQU87O0FBQ0UsYUFEVCxPQUFPLEdBQ0k7OEJBRFgsT0FBTzs7QUFFWixtQ0FGSyxPQUFPLDZDQUVKO0FBQ1IsWUFBSSxDQUFDLEtBQUssR0FBRztBQUNULDBCQUFjLEVBQUUsQ0FBQztTQUNwQixDQUFDO0FBQ0YsWUFBSSxDQUFDLFlBQVksR0FBRyxJQUFJLENBQUMsWUFBWSxDQUFDLElBQUksQ0FBQyxJQUFJLENB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0gY2FsY3VsYXRpb25zIGZvciB0aGUgcGFydGljdWxhciBzZXRcbiAgICAgICAgZm9yICh2YXIgaT0wO2k8dGhpcy5wcm9wcy5waG90b3MubGVuZ3RoO2krPWNvbHMpe1xuICAgICAgICAgICAgdmFyIHRvdGFsQXI9MCxcbiAgICAgICAgICAgIGNvbW1vbkhlaWdodCA9IDA7XG5cblx0ICAgIC8vIGdldCB0aGUgdG90YWwgYXNwZWN0IHJhdGlvIG9mIHRoZSByb3dcbiAgICAgICAgICAgIGZvciAodmFyIGo9aTsgajxpK2NvbHM7IGorKyl7XG4gICAgICAgICAgICAgICAgaWYgKGogPT0gdGhpcy5wcm9wcy5waG90b3MubGVuZ3RoKXtcbiAgICAgICAgICAgICAgICAgICAgYnJlYWs7XG4gICAgICAgICAgICAgICAgfVxuXHRcdHRoaXMucHJvcHMucGhvdG9zW2pdLmFzcGVjdFJhdGlvID0gdGhpcy5wcm9wcy5waG90b3Nbal0ud2lkdGggLyB0aGlzLnByb3BzLnBob3Rvc1tqXS5oZWlnaHQ7XHRcblx0XHR0b3RhbEFyICs9IHRoaXMucHJvcHMucGhvdG9zW2pdLmFzcGVjdFJhdGlvO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgaWYgKGkgPT09IGxhc3RSb3dJbmRleCkge1xuICAgICAgICAgICAgICBjb21tb25IZWlnaHQgPSBsYXN0Um93V2lkdGggLyB0b3RhbEFyO1xuICAgICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgICAgY29tbW9uSGVpZ2h0ID0gY29udFdpZHRoIC8gdG90YWxBcjtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIC8vIHJ1biB0aHJ1IHRoZSBzYW1lIHNldCBvZiBpdGVtcyBhZ2FpbiB0byBnaXZlIHRoZSB3aWR0aCBhbmQgY29tbW9uIGhlaWdodFxuICAgICAgICAgICAgZm9yIChsZXQgaz1pOyBrPGkrY29sczsgaysrKXtcbiAgICAgICAgICAgICAgICBpZiAoayA9PS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BUeXBlcy5udW1iZXJcbn07XG5HYWxsZXJ5LmRlZmF1bHRQcm9wcyA9IHtcbiAgICBjb2xzOiAzLCBcbiAgICBvbkNsaWNrUGhvdG86IGZ1bmN0aW9uKGssZSl7XG5cdGUucHJldmVudERlZmF1bHQoKTtcbiAgICB9LFxuICAgIG1hcmdpbjogMlxufVxuLy8gR2FsbGVyeSBpbWFnZSBzdHlsZVxuY29uc3Qgc3R5bGUgPSB7XG4gICBkaXNwbGF5OiAnYmxvY2snLFxuICAgYmFja2dyb3VuZENvbG9yOicjZTNlM2UzJyxcbiAgIGZsb2F0OiAnbGVmdCdcbn1cblxuZXhwb3J0IGRlZmF1bHQgR2FsbGVyeTtcbiJdfQ==

@@ -54,7 +54,7 @@ import React from 'react';

alt: obj.title,
srcset:[
srcset:[
obj.url_m+' '+obj.width_m+'w',
obj.url_c+' '+obj.width_c+'w',
obj.url_l+' '+obj.width_l+'w',
obj.url_h+' '+obj.width_h+'w'
obj.url_h+' '+obj.width_h+'w'
],

@@ -65,3 +65,3 @@ sizes:[

'100vw'
]
]
});

@@ -86,3 +86,3 @@ })

});
}
}
closeLightbox(){

@@ -100,2 +100,5 @@ this.setState({

gotoNext(){
if(this.state.photos.length - 2 === this.state.currentImage){
this.loadMorePhotos();
}
this.setState({

@@ -129,3 +132,3 @@ currentImage: this.state.currentImage + 1,

{this.renderGallery()}
<Lightbox
<Lightbox
images={this.state.photos}

@@ -132,0 +135,0 @@ backdropClosesModal={true}

{
"name": "react-photo-gallery",
"version": "5.3.0",
"version": "5.4.0",
"description": "Responsive React Photo Gallery Component",

@@ -5,0 +5,0 @@ "main": "lib/Gallery.js",

@@ -106,1 +106,23 @@ # React Responsive Photo Gallery

To gain a good understanding of 'srcset' and 'sizes' attributes, I found this site very helpful: [https://ericportis.com/posts/2014/srcset-sizes/](https://ericportis.com/posts/2014/srcset-sizes/).
## User Guide / Best Practice
### Dynamic column count
The parameter `cols` allows the adjustment of the displayed colums. In combination with `react-measure` this allows the demo page to adjust colums (https://github.com/neptunian/react-photo-gallery/blob/master/examples/src/app.js#L103). Code snippet:
```
import { Measure } from 'react-measure';
function ResponseiveGallery (props) {
const { maxImageWidth = 300 } = props;
return (
<Measure whitelist={['width']}>
{({ width }) => (
<Gallery cols={Math.ceil(width / maxImageWidth)}>....</Gallery>
)}
</Measure>
 );
}
```
This idea was discussed in #32 and proposed by @smeijer.

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc