Comments (3)
@zdrsoft image width 100% would not be able to have a certain number of images side by side on the same row, that's why the widths have to be calculated manually and based on their aspect ratio so the height is also the same as the other images in the same row.
from react-photo-gallery.
@zdrsoft The idea is that the images are responsive. Depending how many images are in the row it calculates the widths of the images to fill the images container and recalculates if the container width changes. That's pretty much the main point of the Gallery. Does that make sense?
from react-photo-gallery.
In the case where I use it, the images are not shown as is expected, the images goes on the next row and are not well sized, even if the images are just 2 or 3.
Responsive image size could be reached via applying css on the images width: 100%;
height: auto;. Any way I did fork of the Gallery, reuse the code in my case with some modifications. Thank you.
from react-photo-gallery.
Related Issues (20)
- Lightbox image not centering HOT 3
- Adding attributes
- Handing images when they are missing
- Empty markup rendered using Jest and testing-library HOT 2
- React 17.x support HOT 6
- Rows Gallery Layout problem HOT 1
- Images become stretchy vertically on iPhone Safari HOT 6
- how to change number of image per row?
- How to load many images locally
- This Does not have support for react 17.0 HOT 2
- Additional props for photo
- Is is possible to cover images in gridview? HOT 1
- Caption, and hi-res download
- Add gap property to Gallery HOT 6
- How to add style to images?
- Custom dynamic columns example does not load
- Max image container width and height
- Defaultprops warning
- Can I use it with Angular?
- Update return type for `columns` function prop to `number | undefined`
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from react-photo-gallery.