R
R
Roman Volodin2014-08-29 12:32:40
css
Roman Volodin, 2014-08-29 12:32:40

CSS layout problem: where does the step come from?

I'm trying to write a template for a site, I want the pictures to jump to the line below when the window is resized. Actually, everything works, the pictures jump, but it is not clear where this step comes from (see the picture):
36088da24ac84425a971fdc3c4030888.png
Moreover, when the window is resized, the step does not go anywhere, and also jumps to the next line. I have very little experience with CSS, please help.

HTML/CSS code
<style>
.gallery_item {
    border: dashed 1px red;
    float: left;
    wi dth: 10%:
}
.gallery_item img{
    max-width: 100%;
}
</style>

<div class="gallery_item">
    <img src="images/13.jpg">
</div>
<div class="gallery_item">
    <img src="images/14.jpg">
</div>
<div class="gallery_item">
    <img src="images/15.jpg">
</div>
<div class="gallery_item">
    <img src="images/16.jpg">
</div>
<div class="gallery_item">
    <img src="images/17.jpg">
</div>
<div class="gallery_item">
    <img src="images/18.jpg">
</div>
<div class="gallery_item">
    <img src="images/19.jpg">
</div>
<div class="gallery_item">
    <img src="images/20.jpg">
</div>
<div class="gallery_item">
    <img src="images/21.jpg">
</div>
<div class="gallery_item">
    <img src="images/22.jpg">
</div>
<div class="gallery_item">
    <img src="images/23.jpg">
</div>
<div class="gallery_item">
    <img src="images/24.jpg">
</div>
<div class="gallery_item">
    <img src="images/25.jpg">
</div>
<div class="gallery_item">
    <img src="images/26.jpg">
</div>

Archive with all pictures and html: https://yadi.sk/d/oZNai0gmadQ5G

Answer the question

In order to leave comments, you need to log in

1 answer(s)
E
Evgeny Petrov, 2014-08-29
@cronk

569566d092174b90a38e8350a0b853ac.png
Variants codepen.io/cleric/pen/ECsGK

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question