-
Notifications
You must be signed in to change notification settings - Fork 109
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #29 from Sitecore/feature/20/consolidate-sitecoreh…
…elper-extensions [closes #20] created and consolidated SitecoreHelper extensions
- Loading branch information
Showing
27 changed files
with
373 additions
and
110 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 0 additions & 20 deletions
20
...er-module-unicorn/src/Feature/BasicContent/website/Extensions/SitecoreHelperExtensions.cs
This file was deleted.
Oops, something went wrong.
5 changes: 3 additions & 2 deletions
5
...r-module-unicorn/src/Feature/BasicContent/website/Views/BasicContent/AccordionItem.cshtml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,17 @@ | ||
@model RenderingModel | ||
@using BasicCompany.Feature.BasicContent | ||
@using BasicCompany.Foundation.FieldRendering | ||
@{ | ||
// always render accordions open in EE with button hidden | ||
string bodyStyle = Sitecore.Context.PageMode.IsExperienceEditor ? | ||
"max-height: 100rem" : null; | ||
} | ||
<div class="accordion-item"> | ||
<div class="accordion-header"> | ||
<h3>@Html.Sitecore().Field(Templates.AccordionItem.Fields.Title.ToString())</h3> | ||
<h3>@Html.Sitecore().Field(Templates.AccordionItem.Fields.Title)</h3> | ||
<button></button> | ||
</div> | ||
<div class="accordion-body" style="@bodyStyle"> | ||
@Html.Sitecore().Field(Templates.AccordionItem.Fields.Content.ToString()) | ||
@Html.Sitecore().Field(Templates.AccordionItem.Fields.Content) | ||
</div> | ||
</div> |
6 changes: 3 additions & 3 deletions
6
...-per-module-unicorn/src/Feature/BasicContent/website/Views/BasicContent/HeroBanner.cshtml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 10 additions & 10 deletions
20
...t-per-module-unicorn/src/Feature/BasicContent/website/Views/BasicContent/PromoCard.cshtml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,18 @@ | ||
@model Sitecore.Mvc.Presentation.RenderingModel | ||
@using BasicCompany.Feature.BasicContent | ||
@using BasicCompany.Feature.BasicContent.Extensions | ||
@using BasicCompany.Foundation.FieldRendering | ||
|
||
@* Disable editing to improve component selection in editor. Can be edited via field editor button. *@ | ||
@Html.Sitecore().BeginField(Templates.PromoCard.Fields.Link.ToString(), new { @class = "column promo-column", DisableWebEdit = true }) | ||
<div class="card"> | ||
<div class="card-image"> | ||
<figure style="background-image: url(@Html.Sitecore().MediaUrl(Templates.PromoCard.Fields.Image))"></figure> | ||
</div> | ||
<div class="card-content"> | ||
<div class="content"> | ||
<h4>@Html.Sitecore().Field(Templates.PromoCard.Fields.Headline.ToString())</h4> | ||
@Html.Sitecore().Field(Templates.PromoCard.Fields.Text.ToString()) | ||
</div> | ||
<div class="card"> | ||
<div class="card-image"> | ||
<figure style="background-image: url(@Html.Sitecore().MediaUrl(Templates.PromoCard.Fields.Image))"></figure> | ||
</div> | ||
<div class="card-content"> | ||
<div class="content"> | ||
<h4>@Html.Sitecore().Field(Templates.PromoCard.Fields.Headline)</h4> | ||
@Html.Sitecore().Field(Templates.PromoCard.Fields.Text) | ||
</div> | ||
</div> | ||
</div> | ||
@Html.Sitecore().EndField() |
3 changes: 2 additions & 1 deletion
3
...r-module-unicorn/src/Feature/BasicContent/website/Views/BasicContent/SectionHeader.cshtml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
@using BasicCompany.Feature.BasicContent | ||
@using BasicCompany.Foundation.FieldRendering | ||
|
||
<div class="container"> | ||
<h2 class="title">@Html.Sitecore().Field(Templates.SectionHeader.Fields.Text.ToString())</h2> | ||
<h2 class="title">@Html.Sitecore().Field(Templates.SectionHeader.Fields.Text)</h2> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
.../project-per-module-unicorn/src/Feature/Navigation/website/Views/Navigation/Footer.cshtml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,9 @@ | ||
@model Sitecore.Data.Items.Item | ||
@using BasicCompany.Feature.Navigation | ||
@using BasicCompany.Foundation.FieldRendering | ||
|
||
<footer class="footer footer-extended"> | ||
<div class="content container"> | ||
<p>@Html.Sitecore().Field(Templates.NavigationRoot.Fields.FooterCopyright.ToString(), Model) © 2018-@DateTime.Now.Year</p> | ||
<p>@Html.Sitecore().Field(Templates.NavigationRoot.Fields.FooterCopyright, Model) © 2018-@DateTime.Now.Year</p> | ||
</div> | ||
</footer> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
26 changes: 0 additions & 26 deletions
26
...ct-per-module-unicorn/src/Feature/Products/website/Extensions/SitecoreHelperExtensions.cs
This file was deleted.
Oops, something went wrong.
5 changes: 3 additions & 2 deletions
5
...oject-per-module-unicorn/src/Feature/Products/website/Views/Products/Detail Header.cshtml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7 changes: 4 additions & 3 deletions
7
...pany/project-per-module-unicorn/src/Feature/Products/website/Views/Products/Detail.cshtml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,13 @@ | ||
@using BasicCompany.Feature.Products | ||
@using BasicCompany.Foundation.FieldRendering | ||
|
||
<section class="product-detail columns is-centered is-vcentered"> | ||
<div class="product-details column is-narrow has-text-centered-mobile"> | ||
<h5>@Sitecore.Globalization.Translate.Text("Products-Detail-Price")</h5> | ||
<p class="price">$@Html.Sitecore().Field(Templates.Product.Fields.Price.ToString())</p> | ||
@Html.Sitecore().Field(Templates.Product.Fields.Features.ToString()) | ||
<p class="price">$@Html.Sitecore().Field(Templates.Product.Fields.Price)</p> | ||
@Html.Sitecore().Field(Templates.Product.Fields.Features) | ||
</div> | ||
<div class="product-image column is-3"> | ||
@Html.Sitecore().Field(Templates.Product.Fields.Image.ToString()) | ||
@Html.Sitecore().Field(Templates.Product.Fields.Image) | ||
</div> | ||
</section> |
2 changes: 0 additions & 2 deletions
2
...ompany/project-per-module-unicorn/src/Feature/Products/website/Views/Products/List.cshtml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 0 additions & 1 deletion
1
...ct-per-module-unicorn/src/Feature/Products/website/Views/Products/Related Products.cshtml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 0 additions & 20 deletions
20
...ct-per-module-unicorn/src/Feature/Services/website/Extensions/SitecoreHelperExtensions.cs
This file was deleted.
Oops, something went wrong.
9 changes: 4 additions & 5 deletions
9
...project-per-module-unicorn/src/Feature/Services/website/Views/Services/Testimonial.cshtml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,9 @@ | ||
@model RenderingModel | ||
@using BasicCompany.Feature.Services; | ||
@using BasicCompany.Feature.Services.Extensions; | ||
@using BasicCompany.Feature.Services; | ||
@using BasicCompany.Foundation.FieldRendering | ||
|
||
<div class="column testimonial is-6"> | ||
<div class="testimonial-inner" style="background-image: url(@Html.Sitecore().MediaUrl(Templates.Testimonial.Fields.Image))"> | ||
<h3>@Html.Sitecore().Field(Templates.Testimonial.Fields.Title.ToString())</h3> | ||
@Html.Sitecore().Field(Templates.Testimonial.Fields.Quote.ToString()) | ||
<h3>@Html.Sitecore().Field(Templates.Testimonial.Fields.Title)</h3> | ||
@Html.Sitecore().Field(Templates.Testimonial.Fields.Quote) | ||
</div> | ||
</div> |
Oops, something went wrong.