Skip to content

Commit

Permalink
images display - minor changes
Browse files Browse the repository at this point in the history
  • Loading branch information
DanielŻuławski committed Oct 7, 2021
1 parent 1492dbb commit 1903027
Show file tree
Hide file tree
Showing 10 changed files with 93 additions and 24 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,16 @@
@foreach (var item in Model)
{
<div class="col-xl-@order.Bm_Xl col-lg-@order.Bm_Lg col-md-@order.Bm_Md col-sm-@order.Bm_Sm col-@order.Bm_Col">
<a href="@Url.RouteUrl("Brand", new { SeName = item.SeName })" title="@item.PictureModel.Title">
<article class="card mb-2">
<div class="card picture-card mb-2">
<a href="@Url.RouteUrl("Brand", new { SeName = item.SeName })" title="@item.PictureModel.Title">
<b-card-img-lazy src="@item.PictureModel.ImageUrl" alt="@item.PictureModel.AlternateText"></b-card-img-lazy>
<div class="card-body">
<h4>@item.Name</h4>
</div>
</article>
</a>
</a>
<h4 class="title">
<a href="@Url.RouteUrl("Brand", new { SeName = item.SeName })" title="@item.PictureModel.Title">
@item.Name
</a>
</h4>
</div>
</div>
}
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,16 @@
@foreach (var item in Model)
{
<div class="col-xl-@order.Pc_Xl col-lg-@order.Pc_Lg col-md-@order.Pc_Md col-sm-@order.Pc_Sm col-@order.Pc_Col">
<a href="@Url.RouteUrl("Category", new { SeName = item.SeName })" title="@item.PictureModel.Title">
<article class="card mb-2">
<div class="card picture-card mb-2">
<a href="@Url.RouteUrl("Category", new { SeName = item.SeName })" title="@item.PictureModel.Title">
<b-card-img-lazy src="@item.PictureModel.ImageUrl" alt="@item.PictureModel.AlternateText"></b-card-img-lazy>
<div class="card-body">
<h4>@item.Name</h4>
</div>
</article>
</a>
</a>
<h4 class="title">
<a href="@Url.RouteUrl("Category", new { SeName = item.SeName })" title="@item.PictureModel.Title">
@item.Name
</a>
</h4>
</div>
</div>
}
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,11 @@
@foreach (var item in Model)
{
<div class="col-xl-@order.Pm_Xl col-lg-@order.Pm_Lg col-md-@order.Pm_Md col-sm-@order.Pm_Sm col-@order.Pm_Col">
<a href="@Url.RouteUrl("Collection", new { SeName = item.SeName })" title="@item.PictureModel.Title">
<article class="card mb-2">
<div class="card picture-card mb-2">
<a href="@Url.RouteUrl("Collection", new { SeName = item.SeName })" title="@item.PictureModel.Title">
<b-card-img-lazy src="@item.PictureModel.ImageUrl" alt="@item.PictureModel.AlternateText"></b-card-img-lazy>
<div class="card-body">
<h4>@item.Name</h4>
</div>
</article>
</a>
</a>
</div>
</div>
}
</div>
Expand Down
2 changes: 1 addition & 1 deletion src/Web/Grand.Web/Views/Shared/_Logo.cshtml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
@inject StoreInformationSettings storeInformation
@inject IWorkContext workContext
<a class="navbar-brand store-logo mx-lg-0 mx-auto" target="_self" href="@Url.RouteUrl("HomePage")">
<img src="/@storeInformation.LogoPicture" alt="@workContext.CurrentStore.Name"/>
<img width="236" height="56" src="/@storeInformation.LogoPicture" alt="@workContext.CurrentStore.Name"/>
<span class="sr-only">@Loc["admin.configuration.shipping.providers.fields.logo"]</span>
</a>
2 changes: 1 addition & 1 deletion src/Web/Grand.Web/wwwroot/bundles/style.min.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/Web/Grand.Web/wwwroot/bundles/style.rtl.min.css

Large diffs are not rendered by default.

26 changes: 26 additions & 0 deletions src/Web/Grand.Web/wwwroot/theme/css/common/common.css
Original file line number Diff line number Diff line change
Expand Up @@ -456,6 +456,32 @@ dl, ol, ul {
margin: 15px 0;
}

/* picture card */

.picture-card > a {
position: relative;
display: block;
}
.picture-card > a::before {
content: "";
display: block;
padding-top: 56%;
}
.picture-card a img {
position: absolute;
top: 0;
right: 0;
bottom: 0;
left: 0;
width: auto;
max-width: 100%;
max-height: 100%;
margin: auto;
}
.picture-card .title {
padding: 20px;
}

/* modals */

.modal-close {
Expand Down
26 changes: 26 additions & 0 deletions src/Web/Grand.Web/wwwroot/theme/css/common/common.rtl.css
Original file line number Diff line number Diff line change
Expand Up @@ -545,6 +545,32 @@ dl, ol, ul {
margin: 15px 0;
}

/* picture card */

.picture-card > a {
position: relative;
display: block;
}
.picture-card > a::before {
content: "";
display: block;
padding-top: 56%;
}
.picture-card a img {
position: absolute;
top: 0;
right: 0;
bottom: 0;
left: 0;
width: auto;
max-width: 100%;
max-height: 100%;
margin: auto;
}
.picture-card .title {
padding: 20px;
}

/* modals */

.modal-close {
Expand Down
8 changes: 8 additions & 0 deletions src/Web/Grand.Web/wwwroot/theme/css/header/header.css
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,14 @@
padding: 15px;
}

/* logo */

.store-logo img {
width: auto;
height: auto;
max-height: 53px;
}

/* sidebar-cart */

.sidebar-cart {
Expand Down
8 changes: 8 additions & 0 deletions src/Web/Grand.Web/wwwroot/theme/css/header/header.rtl.css
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,14 @@
padding: 15px;
}

/* logo */

.store-logo img {
width: auto;
height: auto;
max-height: 53px;
}

/* sidebar-cart */

.sidebar-cart .item {
Expand Down

0 comments on commit 1903027

Please sign in to comment.