我试过了:
<div class="row">
<div class="img-blocks small-image col-lg-2 clearfix">
<ul class="list-style">
<li ng-repeat="img in productImgSrc track by $index">
<img ng-src={{img}} alt="...">
</li>
</ul>
</div>
<div class="img-blocks zoomed-image col-lg-10 clearfix">
<img ng-src={{productImgSrc[0]}} alt="...">
</div>
</div>
但它无法为较小的分辨率生成视图。
任何帮助都将不胜感激。
答案 0 :(得分:2)
您可以使用 CSS Flexbox 。并使用媒体查询来反转不同屏幕尺寸的顺序。
在我的例子中,
max-width: 991px (0px - 991px)
min-width: 992px (992px > infinite)
请查看下面的我的代码段(对于大屏幕使用全屏模式):
.main-block {
display: flex;
align-items: center;
justify-content: center;
}
.list-style {
list-style: none;
padding: 0;
display: flex;
flex-direction: column;
}
.list-style li {
padding: 10px 10px 0 0;
}
/* For Small Screens */
@media screen and (max-width: 991px) {
.main-block {
display: flex;
flex-direction: column-reverse;
}
.list-style {
flex-direction: row;
}
.list-style li {
padding: 10px;
}
}
&#13;
<div class="row main-block">
<div class="img-blocks small-image col-lg-2 clearfix">
<ul class="list-style">
<li>
<img src="http://placehold.it/40x40" alt="...">
</li>
<li>
<img src="http://placehold.it/40x40" alt="...">
</li>
<li>
<img src="http://placehold.it/40x40" alt="...">
</li>
<li>
<img src="http://placehold.it/40x40" alt="...">
</li>
<li>
<img src="http://placehold.it/40x40" alt="...">
</li>
</ul>
</div>
<div class="img-blocks zoomed-image col-lg-10 clearfix">
<img src="http://placehold.it/400x300" alt="...">
</div>
</div>
&#13;
希望这有帮助!