@model Products.Pages.NoLayoutModel
@{
Layout = null;
}
@Html.AntiForgeryToken()
Index
@foreach (var product in Model.availableProducts)
{
}
< /code>
и мой css: < /p>
.imgproduct {
height: 98%;
width: 98%;
object-fit: contain;
}
.divimage {
width: 100%;
height: 250px;
display: flex;
justify-content: center;
}
.divouterproductcontainer {
width: 25%;
float: left;
display: inline-block;
box-sizing: border-box;
}
.divinnerproductcontainer {
width: 95%;
border: 1px solid red;
}
@media only screen and (width < 1000px) {
.divouterproductcontainer {
width: 100%;
float: left;
display: inline-block;
}
}
Подробнее здесь: https://stackoverflow.com/questions/796 ... ile-device