Add the editable section partials (Hero, About, Skills, Projects, Goals, Experience, Documents, Contact)
This commit is contained in:
@@ -0,0 +1,43 @@
|
||||
@model SectionView<AboutSection>
|
||||
@{
|
||||
var about = Model.Section;
|
||||
var edit = Model.EditMode;
|
||||
}
|
||||
|
||||
<section id="about" @EditMarkup.Section(edit, "about")>
|
||||
<div class="about-area style-three">
|
||||
<div class="container">
|
||||
<div class="row align-items-center">
|
||||
<div class="col-lg-6 col-md-6 col-sm-12">
|
||||
<div class="techno-about-thumb-box">
|
||||
<div class="techno-about-thumb-3">
|
||||
<img src="@about.Image" alt="@about.ImageAlt" @EditMarkup.Image(edit, "image", about.Image)>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-6 col-md-6 col-sm-12">
|
||||
<div class="row about-left">
|
||||
<div class="col-lg-12">
|
||||
<div class="dreamit-section-title style-four white">
|
||||
<h5 @EditMarkup.Field(edit, "kicker", max: ContentLimits.Kicker)>@about.Kicker</h5>
|
||||
<h1 @EditMarkup.Field(edit, "titleLine1", max: ContentLimits.Heading)>@about.TitleLine1</h1>
|
||||
<h1><partial name="_EditableText" model='new EditableText(about.TitleLine2, "titleLine2", edit, ContentLimits.Heading)' /> <span class="color2" @EditMarkup.Field(edit, "titleLine2Highlight", max: ContentLimits.Heading)>@about.TitleLine2Highlight</span></h1>
|
||||
<p class="pt-text" @EditMarkup.Field(edit, "text", multiline: true, max: ContentLimits.ParagraphText)>@about.Text</p>
|
||||
</div>
|
||||
<div class="about-facts" @EditMarkup.List(edit, "facts")>
|
||||
@foreach (var fact in about.Facts)
|
||||
{
|
||||
<div class="about-fact" @EditMarkup.Item(edit)><strong @EditMarkup.Field(edit, "label", max: ContentLimits.FactLabel)>@fact.Label</strong><span><partial name="_EditableText" model='new EditableText(fact.Value, "value", edit, ContentLimits.FactValue)' /> <i class="fas fa-angle-right"></i></span>@if (edit) {<partial name="_EditItemControls" />}</div>
|
||||
}
|
||||
@if (edit)
|
||||
{
|
||||
<button type="button" class="pe-add" data-add="facts">+ Eintrag</button>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
@@ -0,0 +1,187 @@
|
||||
@model SectionView<ContactSection>
|
||||
@{
|
||||
var contact = Model.Section;
|
||||
var edit = Model.EditMode;
|
||||
}
|
||||
|
||||
<section id="contact" @EditMarkup.Section(edit, "contact")>
|
||||
<div class="contact-us-area style-two pt-100">
|
||||
<div class="container">
|
||||
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
<div class="dreamit-section-title style-two text-center">
|
||||
<h5 @EditMarkup.Field(edit, "kicker", max: ContentLimits.Kicker)>@contact.Kicker</h5>
|
||||
<h1><partial name="_EditableText" model='new EditableText(contact.Title, "title", edit, ContentLimits.Heading)' /> <span @EditMarkup.Field(edit, "titleHighlight", max: ContentLimits.Heading)>@contact.TitleHighlight</span></h1>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
|
||||
<div class="col-lg-4 col-md-6 col-sm-12">
|
||||
<div class="row" @EditMarkup.List(edit, "infoBoxes")>
|
||||
@foreach (var box in contact.InfoBoxes)
|
||||
{
|
||||
<div class="col-lg-12" @EditMarkup.Item(edit)>
|
||||
<div class="contact-us-single-box">
|
||||
<div class="contact-us-icon">
|
||||
<i class="@box.Icon"></i>
|
||||
</div>
|
||||
|
||||
<div class="contact-us-title">
|
||||
<h2 @EditMarkup.Field(edit, "title", max: ContentLimits.FactLabel)>@box.Title</h2>
|
||||
<p>
|
||||
@if (string.IsNullOrWhiteSpace(box.LinkUrl) && !edit)
|
||||
{
|
||||
@box.Text
|
||||
}
|
||||
else if (!edit)
|
||||
{
|
||||
<a href="@box.LinkUrl">@box.Text</a>
|
||||
}
|
||||
else
|
||||
{
|
||||
<span data-field="text" data-max="@ContentLimits.FactValue" contenteditable="true">@box.Text</span>
|
||||
<input class="pe-url" type="text" data-field="linkUrl" maxlength="@ContentLimits.Url" value="@box.LinkUrl" aria-label="Link-Ziel (leer lassen fuer reinen Text)" />
|
||||
}
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
@if (edit)
|
||||
{
|
||||
<input class="pe-icon" type="text" data-field="icon" maxlength="@ContentLimits.IconClass" value="@box.Icon" aria-label="Icon-Klasse" />
|
||||
<partial name="_EditItemControls" />
|
||||
}
|
||||
</div>
|
||||
}
|
||||
@if (edit)
|
||||
{
|
||||
<button type="button" class="pe-add" data-add="infoBoxes">+ Kontaktangabe</button>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@* Das Formular selbst ist Funktionalitaet und bleibt fest im Code;
|
||||
nur die Einleitung darueber kommt aus dem Inhalt. *@
|
||||
<div class="col-lg-8 col-md-6 col-sm-12">
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
|
||||
<div class="contact-form-box style-two">
|
||||
|
||||
<div id="contact-form-message" class="alert" role="alert" style="display:none;"></div>
|
||||
|
||||
<form method="post" id="dreamit-form" novalidate>
|
||||
|
||||
@* Zeilenumbrueche im Text werden als <br> gerendert. *@
|
||||
<h4 @EditMarkup.Field(edit, "formHeading", multiline: true, max: ContentLimits.FormIntro)>
|
||||
@{ var headingLines = contact.FormHeading.Replace("\r\n", "\n").Split('\n'); }
|
||||
@for (var i = 0; i < headingLines.Length; i++)
|
||||
{
|
||||
if (i > 0)
|
||||
{
|
||||
<br />
|
||||
}
|
||||
@headingLines[i]
|
||||
}
|
||||
</h4>
|
||||
|
||||
<div class="row">
|
||||
|
||||
<div class="col-lg-6 col-md-6 col-sm-12">
|
||||
<div class="form-title">
|
||||
<p>Name (Pflichtfeld)</p>
|
||||
</div>
|
||||
|
||||
<div class="from-box">
|
||||
<input
|
||||
type="text"
|
||||
name="name"
|
||||
placeholder="Name*"
|
||||
required>
|
||||
<div class="invalid-feedback"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-6 col-md-6 col-sm-12">
|
||||
<div class="form-title">
|
||||
<p>E-Mail (Pflichtfeld)</p>
|
||||
</div>
|
||||
|
||||
<div class="from-box">
|
||||
<input
|
||||
type="email"
|
||||
name="email"
|
||||
placeholder="E-Mail*"
|
||||
required>
|
||||
<div class="invalid-feedback"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-6 col-md-6 col-sm-12">
|
||||
<div class="form-title">
|
||||
<p>Telefon (optional)</p>
|
||||
</div>
|
||||
|
||||
<div class="from-box">
|
||||
<input
|
||||
type="tel"
|
||||
name="phone"
|
||||
placeholder="z. B. 079 123 45 67 oder +41 79 123 45 67">
|
||||
<div class="invalid-feedback"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-6 col-md-6 col-sm-12">
|
||||
<div class="form-title">
|
||||
<p>Betreff (Pflichtfeld)</p>
|
||||
</div>
|
||||
|
||||
<div class="from-box">
|
||||
<input
|
||||
type="text"
|
||||
name="subject"
|
||||
placeholder="Betreff*"
|
||||
required>
|
||||
<div class="invalid-feedback"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-12">
|
||||
<div class="form-title">
|
||||
<p>Nachricht</p>
|
||||
</div>
|
||||
|
||||
<div class="from-box">
|
||||
<textarea
|
||||
name="message"
|
||||
cols="30"
|
||||
rows="10"
|
||||
placeholder="Nachricht*"
|
||||
required></textarea>
|
||||
<div class="invalid-feedback"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-lg-12">
|
||||
<div class="contact-form">
|
||||
<button type="submit">
|
||||
NACHRICHT SENDEN
|
||||
<i class="fas fa-check"></i>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</form>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
@@ -0,0 +1,43 @@
|
||||
@model SectionView<DocumentsSection>
|
||||
@{
|
||||
var documents = Model.Section;
|
||||
var edit = Model.EditMode;
|
||||
}
|
||||
|
||||
<section id="documents" class="portfolio-section" @EditMarkup.Section(edit, "documents")>
|
||||
<div class="container">
|
||||
<div class="dreamit-section-title style-two text-center section-title">
|
||||
<h5 @EditMarkup.Field(edit, "kicker", max: ContentLimits.Kicker)>@documents.Kicker</h5>
|
||||
<h1><partial name="_EditableText" model='new EditableText(documents.Title, "title", edit, ContentLimits.Heading)' /> <span @EditMarkup.Field(edit, "titleHighlight", max: ContentLimits.Heading)>@documents.TitleHighlight</span></h1>
|
||||
</div>
|
||||
|
||||
<div class="row documents-grid" @EditMarkup.List(edit, "items")>
|
||||
@foreach (var item in documents.Items)
|
||||
{
|
||||
<div class="col-lg-6" @EditMarkup.Item(edit)>
|
||||
<div class="single-circular-box">
|
||||
<div class="circular-title">
|
||||
<h3 @EditMarkup.Field(edit, "title", max: ContentLimits.CardTitle)>@item.Title</h3>
|
||||
<p @EditMarkup.Field(edit, "description", multiline: true, max: ContentLimits.ParagraphText)>@item.Description</p>
|
||||
</div>
|
||||
<div class="circular-btn">
|
||||
<a href="@item.FileUrl" target="_blank" rel="noopener" @EditMarkup.Field(edit, "linkText", max: ContentLimits.ButtonLabel)>@item.LinkText</a>
|
||||
</div>
|
||||
</div>
|
||||
@if (edit)
|
||||
{
|
||||
<div class="pe-file-row">
|
||||
<input class="pe-url" type="text" data-field="fileUrl" maxlength="@ContentLimits.Url" value="@item.FileUrl" aria-label="Pfad zur Datei" />
|
||||
<button type="button" class="pe-file" data-file="documents" data-accept="application/pdf">PDF hochladen</button>
|
||||
</div>
|
||||
<partial name="_EditItemControls" />
|
||||
}
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
@if (edit)
|
||||
{
|
||||
<button type="button" class="pe-add" data-add="items">+ Dokument</button>
|
||||
}
|
||||
</div>
|
||||
</section>
|
||||
@@ -0,0 +1,61 @@
|
||||
@model SectionView<ExperienceSection>
|
||||
@{
|
||||
var experience = Model.Section;
|
||||
var edit = Model.EditMode;
|
||||
}
|
||||
|
||||
<section id="experience" @EditMarkup.Section(edit, "experience")>
|
||||
<div class="career-details">
|
||||
<div class="container">
|
||||
<div class="dreamit-section-title style-two text-center section-title">
|
||||
<h5 @EditMarkup.Field(edit, "kicker", max: ContentLimits.Kicker)>@experience.Kicker</h5>
|
||||
<h1><partial name="_EditableText" model='new EditableText(experience.Title, "title", edit, ContentLimits.Heading)' /> <span @EditMarkup.Field(edit, "titleHighlight", max: ContentLimits.Heading)>@experience.TitleHighlight</span></h1>
|
||||
</div>
|
||||
|
||||
<div class="row justify-content-center">
|
||||
<div class="col-lg-10">
|
||||
<div class="experience-timeline single-details-box" @EditMarkup.List(edit, "items")>
|
||||
@foreach (var item in experience.Items)
|
||||
{
|
||||
<article class="experience-item@(item.Collapsed && !edit ? " experience-item-extra" : null)" @EditMarkup.Item(edit)>
|
||||
<h3 @EditMarkup.Field(edit, "title", max: ContentLimits.CardTitle)>@item.Title</h3>
|
||||
<div class="experience-meta" @EditMarkup.Field(edit, "meta", max: ContentLimits.Meta)>@item.Meta</div>
|
||||
<div class="details-text">
|
||||
<h4 @EditMarkup.Field(edit, "detailHeading", max: ContentLimits.DetailHeading)>@item.DetailHeading</h4>
|
||||
<p @EditMarkup.Field(edit, "text", multiline: true, max: ContentLimits.ParagraphText)>@item.Text</p>
|
||||
</div>
|
||||
@if (edit)
|
||||
{
|
||||
<partial name="_EditItemControls" />
|
||||
<label class="pe-flag"><input type="checkbox" data-flag="collapsed" checked="@(item.Collapsed ? "checked" : null)" /> erst nach Klick auf den Button sichtbar</label>
|
||||
}
|
||||
</article>
|
||||
}
|
||||
</div>
|
||||
@if (edit)
|
||||
{
|
||||
<button type="button" class="pe-add" data-add="items">+ Erfahrung</button>
|
||||
}
|
||||
|
||||
<div class="experience-toggle-wrap">
|
||||
<button type="button"
|
||||
id="experience-toggle"
|
||||
class="experience-toggle-btn"
|
||||
aria-expanded="false"
|
||||
data-more-text="@experience.ToggleMoreText"
|
||||
data-less-text="@experience.ToggleLessText">
|
||||
@experience.ToggleMoreText
|
||||
</button>
|
||||
</div>
|
||||
@if (edit)
|
||||
{
|
||||
<div class="pe-toggle-texts">
|
||||
<label>Button zugeklappt <input type="text" data-field="toggleMoreText" maxlength="@ContentLimits.ButtonLabel" value="@experience.ToggleMoreText" /></label>
|
||||
<label>Button aufgeklappt <input type="text" data-field="toggleLessText" maxlength="@ContentLimits.ButtonLabel" value="@experience.ToggleLessText" /></label>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
@@ -0,0 +1,54 @@
|
||||
@model SectionView<GoalsSection>
|
||||
@{
|
||||
var goals = Model.Section;
|
||||
var edit = Model.EditMode;
|
||||
}
|
||||
|
||||
<section id="goals" @EditMarkup.Section(edit, "goals")>
|
||||
<div class="service-area">
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
<div class="dreamit-section-title text-center">
|
||||
<h5 @EditMarkup.Field(edit, "kicker", max: ContentLimits.Kicker)>@goals.Kicker</h5>
|
||||
<h1><partial name="_EditableText" model='new EditableText(goals.Title, "title", edit, ContentLimits.Heading)' /> <span @EditMarkup.Field(edit, "titleHighlight", max: ContentLimits.Heading)>@goals.TitleHighlight</span></h1>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row goals-grid" @EditMarkup.List(edit, "items")>
|
||||
@for (var i = 0; i < goals.Items.Count; i++)
|
||||
{
|
||||
var item = goals.Items[i];
|
||||
@* Vier Kacheln pro Reihe, jede zweite in der abweichenden Theme-Variante. *@
|
||||
var boxClass = i % 2 == 1 ? "techno-sinlge-service-box-1" : "techno-sinlge-service-box";
|
||||
if (item.Highlighted)
|
||||
{
|
||||
boxClass += " active";
|
||||
}
|
||||
|
||||
<div class="col-lg-3 col-md-6 col-sm-12" @EditMarkup.Item(edit)>
|
||||
<div class="@boxClass">
|
||||
<div class="techno-service-box-inner">
|
||||
<div class="techno-service-content">
|
||||
<div class="techno-service-icon"><i class="@item.Icon"></i></div>
|
||||
<div class="techno-service-title"><h2 @EditMarkup.Field(edit, "title", max: ContentLimits.TileTitle)>@item.Title</h2><p @EditMarkup.Field(edit, "text", multiline: true, max: ContentLimits.TileText)>@item.Text</p></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@if (edit)
|
||||
{
|
||||
<input class="pe-icon" type="text" data-field="icon" maxlength="@ContentLimits.IconClass" value="@item.Icon" aria-label="Icon-Klasse" />
|
||||
<partial name="_EditItemControls" />
|
||||
<label class="pe-flag"><input type="checkbox" data-flag="highlighted" checked="@(item.Highlighted ? "checked" : null)" /> hervorgehoben</label>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
@if (edit)
|
||||
{
|
||||
<button type="button" class="pe-add" data-add="items">+ Ziel</button>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
@@ -0,0 +1,93 @@
|
||||
@model SectionView<HeroSection>
|
||||
@{
|
||||
var hero = Model.Section;
|
||||
var edit = Model.EditMode;
|
||||
var lastLine = hero.TitleLines.Count - 1;
|
||||
}
|
||||
|
||||
<section id="hero" class="slider-area slider8 d-flex align-items-center" @EditMarkup.Section(edit, "hero")>
|
||||
<div class="container">
|
||||
<div class="row d-flex align-items-center slider">
|
||||
<div class="col-lg-7 col-md-12 col-sm-12">
|
||||
<div class="slider-content" @EditMarkup.StringList(edit, "titleLines")>
|
||||
<p class="section-kicker" @EditMarkup.Field(edit, "kicker", max: ContentLimits.Kicker)>@hero.Kicker</p>
|
||||
@for (var i = 0; i < hero.TitleLines.Count; i++)
|
||||
{
|
||||
@if (i == lastLine)
|
||||
{
|
||||
<h1 @EditMarkup.Item(edit)><span class="color3" @EditMarkup.Editable(edit, max: ContentLimits.Heading)>@hero.TitleLines[i]</span></h1>
|
||||
}
|
||||
else
|
||||
{
|
||||
<h1 @EditMarkup.Item(edit) @EditMarkup.Editable(edit, max: ContentLimits.Heading)>@hero.TitleLines[i]</h1>
|
||||
}
|
||||
}
|
||||
<p @EditMarkup.Field(edit, "intro", multiline: true, max: ContentLimits.ParagraphText)>@hero.Intro</p>
|
||||
<div class="hero-actions">
|
||||
<div class="slider-button2" @EditMarkup.Object(edit, "primaryButton")>
|
||||
<a href="@hero.PrimaryButton.Url"><partial name="_EditableText" model='new EditableText(hero.PrimaryButton.Text, "text", edit, ContentLimits.ButtonLabel)' /> <i class="fas fa-check-square"></i></a>
|
||||
@if (edit)
|
||||
{
|
||||
<input class="pe-url" type="url" data-field="url" maxlength="@ContentLimits.Url" value="@hero.PrimaryButton.Url" aria-label="Ziel des Buttons" />
|
||||
}
|
||||
</div>
|
||||
@if (edit)
|
||||
{
|
||||
<span data-object="secondaryButton">
|
||||
<a class="hero-secondary" href="@hero.SecondaryButton.Url">
|
||||
<span data-field="text" data-max="@ContentLimits.ButtonLabel" contenteditable="true">@hero.SecondaryButton.Text</span>
|
||||
</a>
|
||||
<input class="pe-url" type="url" data-field="url" maxlength="@ContentLimits.Url" value="@hero.SecondaryButton.Url" aria-label="Ziel des zweiten Buttons" />
|
||||
</span>
|
||||
}
|
||||
else
|
||||
{
|
||||
<a class="hero-secondary" href="@hero.SecondaryButton.Url">
|
||||
@hero.SecondaryButton.Text
|
||||
</a>
|
||||
}
|
||||
</div>
|
||||
<div class="hero-social" @EditMarkup.List(edit, "socialLinks")>
|
||||
@foreach (var link in hero.SocialLinks)
|
||||
{
|
||||
var external = !link.Url.StartsWith("mailto:", StringComparison.OrdinalIgnoreCase);
|
||||
@if (edit)
|
||||
{
|
||||
<span class="pe-item-inline" data-item="true">
|
||||
<a href="@link.Url" target="@(external ? "_blank" : null)" rel="@(external ? "noopener" : null)" data-field="text" data-max="@ContentLimits.ButtonLabel" contenteditable="true">@link.Text</a>
|
||||
<input class="pe-url" type="url" data-field="url" maxlength="@ContentLimits.Url" value="@link.Url" aria-label="Link-Ziel" />
|
||||
<partial name="_EditItemControls" />
|
||||
</span>
|
||||
}
|
||||
else if (external)
|
||||
{
|
||||
<a href="@link.Url" target="_blank" rel="noopener">@link.Text</a>
|
||||
}
|
||||
else
|
||||
{
|
||||
<a href="@link.Url">@link.Text</a>
|
||||
}
|
||||
}
|
||||
@if (edit)
|
||||
{
|
||||
<button type="button" class="pe-add" data-add="socialLinks">+ Link</button>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-5">
|
||||
<div class="slider-thumb-images">
|
||||
<img src="@hero.PortraitImage" alt="@hero.PortraitAlt" @EditMarkup.Image(edit, "portraitImage", hero.PortraitImage)>
|
||||
</div>
|
||||
<div class="slider-shape">
|
||||
<div class="shape-inner bounce-animate2">
|
||||
<img src="~/images/slider/shape1.png" alt="">
|
||||
</div>
|
||||
<div class="shape-inner-1 bounce-animate4">
|
||||
<img src="~/images/slider/shape2.png" alt="">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
@@ -0,0 +1,141 @@
|
||||
@model SectionView<ProjectsSection>
|
||||
@{
|
||||
var projects = Model.Section;
|
||||
var edit = Model.EditMode;
|
||||
}
|
||||
|
||||
@functions {
|
||||
// Titel, Beschreibung, Detailbloecke und Links -- identisch fuer schmale und breite Karten.
|
||||
async Task RenderCardBody(ProjectItem project, bool edit)
|
||||
{
|
||||
<div class="portfolio-details-titles">
|
||||
<h3 @EditMarkup.Field(edit, "title", max: ContentLimits.CardTitle)>@project.Title</h3>
|
||||
<p>
|
||||
@if (edit)
|
||||
{
|
||||
<strong data-field="descriptionLead" data-max="@ContentLimits.DetailHeading" contenteditable="true">@project.DescriptionLead</strong>
|
||||
}
|
||||
else if (!string.IsNullOrWhiteSpace(project.DescriptionLead))
|
||||
{
|
||||
<strong>@project.DescriptionLead</strong>@:
|
||||
}
|
||||
<partial name="_EditableText" model='new EditableText(project.Description, "description", edit, ContentLimits.ParagraphText)' />
|
||||
</p>
|
||||
</div>
|
||||
<div class="details-category" @EditMarkup.List(edit, "details")>
|
||||
@foreach (var detail in project.Details)
|
||||
{
|
||||
@if (edit)
|
||||
{
|
||||
<div data-item="true">
|
||||
<h4 data-field="heading" data-max="@ContentLimits.DetailHeading" contenteditable="true">@detail.Heading</h4>
|
||||
<p data-field="text" data-multiline="true" data-max="@ContentLimits.ParagraphText" contenteditable="true">@detail.Text</p>
|
||||
<partial name="_EditItemControls" />
|
||||
</div>
|
||||
}
|
||||
else
|
||||
{
|
||||
<h4>@detail.Heading</h4>
|
||||
<p>@detail.Text</p>
|
||||
}
|
||||
}
|
||||
@if (edit)
|
||||
{
|
||||
<button type="button" class="pe-add" data-add="details">+ Abschnitt</button>
|
||||
}
|
||||
</div>
|
||||
@if (edit)
|
||||
{
|
||||
<div class="project-actions" data-list="links">
|
||||
@foreach (var link in project.Links)
|
||||
{
|
||||
<span class="pe-item-inline" data-item="true">
|
||||
<a href="@link.Url" target="_blank" rel="noopener" data-field="text" data-max="@ContentLimits.ButtonLabel" contenteditable="true">@link.Text</a>
|
||||
<input class="pe-url" type="url" data-field="url" maxlength="@ContentLimits.Url" value="@link.Url" aria-label="Link-Ziel" />
|
||||
<partial name="_EditItemControls" />
|
||||
</span>
|
||||
}
|
||||
<button type="button" class="pe-add" data-add="links">+ Link</button>
|
||||
</div>
|
||||
}
|
||||
else if (project.Links.Count > 0)
|
||||
{
|
||||
<div class="project-actions">
|
||||
@for (var i = 0; i < project.Links.Count; i++)
|
||||
{
|
||||
var link = project.Links[i];
|
||||
<a class="@(i == 0 ? null : "github")" href="@link.Url" target="_blank" rel="noopener">@link.Text</a>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
<section id="projects" class="portfolio-section" @EditMarkup.Section(edit, "projects")>
|
||||
<div class="container" @EditMarkup.List(edit, "items")>
|
||||
<div class="dreamit-section-title style-two text-center section-title">
|
||||
<h5 @EditMarkup.Field(edit, "kicker", max: ContentLimits.Kicker)>@projects.Kicker</h5>
|
||||
<h1><partial name="_EditableText" model='new EditableText(projects.Title, "title", edit, ContentLimits.Heading)' /> <span @EditMarkup.Field(edit, "titleHighlight", max: ContentLimits.Heading)>@projects.TitleHighlight</span></h1>
|
||||
</div>
|
||||
|
||||
@{
|
||||
// Schmale Karten stehen zu zweit in einer Reihe, breite Karten je allein.
|
||||
var index = 0;
|
||||
}
|
||||
@while (index < projects.Items.Count)
|
||||
{
|
||||
var project = projects.Items[index];
|
||||
|
||||
if (project.Wide)
|
||||
{
|
||||
<div class="row">
|
||||
<div class="col-lg-12" @EditMarkup.Item(edit)>
|
||||
<article class="project-card project-card-expanded">
|
||||
<div class="row align-items-stretch g-0">
|
||||
<div class="col-lg-5">
|
||||
<div class="portfolio-details-thumb"><img src="@project.Image" alt="@project.ImageAlt" @EditMarkup.Image(edit, "image", project.Image)></div>
|
||||
</div>
|
||||
<div class="col-lg-7">
|
||||
@{ await RenderCardBody(project, edit); }
|
||||
</div>
|
||||
</div>
|
||||
</article>
|
||||
@if (edit)
|
||||
{
|
||||
<partial name="_EditItemControls" />
|
||||
<label class="pe-flag"><input type="checkbox" data-flag="wide" checked="checked" /> breite Karte</label>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
index++;
|
||||
}
|
||||
else
|
||||
{
|
||||
var pair = projects.Items.Skip(index).TakeWhile(p => !p.Wide).Take(2).ToList();
|
||||
|
||||
<div class="row">
|
||||
@foreach (var narrow in pair)
|
||||
{
|
||||
<div class="col-lg-6 col-md-6" @EditMarkup.Item(edit)>
|
||||
<article class="project-card">
|
||||
<div class="portfolio-details-thumb"><img src="@narrow.Image" alt="@narrow.ImageAlt" @EditMarkup.Image(edit, "image", narrow.Image)></div>
|
||||
@{ await RenderCardBody(narrow, edit); }
|
||||
</article>
|
||||
@if (edit)
|
||||
{
|
||||
<partial name="_EditItemControls" />
|
||||
<label class="pe-flag"><input type="checkbox" data-flag="wide" /> breite Karte</label>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
index += pair.Count;
|
||||
}
|
||||
}
|
||||
|
||||
@if (edit)
|
||||
{
|
||||
<button type="button" class="pe-add" data-add="items">+ Projekt</button>
|
||||
}
|
||||
</div>
|
||||
</section>
|
||||
@@ -0,0 +1,49 @@
|
||||
@model SectionView<SkillsSection>
|
||||
@{
|
||||
var skills = Model.Section;
|
||||
var edit = Model.EditMode;
|
||||
}
|
||||
|
||||
<section id="skills" class="portfolio-section" @EditMarkup.Section(edit, "skills")>
|
||||
<div class="container">
|
||||
<div class="dreamit-section-title style-two text-center section-title">
|
||||
<h5 @EditMarkup.Field(edit, "kicker", max: ContentLimits.Kicker)>@skills.Kicker</h5>
|
||||
<h1><partial name="_EditableText" model='new EditableText(skills.Title, "title", edit, ContentLimits.Heading)' /> <span @EditMarkup.Field(edit, "titleHighlight", max: ContentLimits.Heading)>@skills.TitleHighlight</span></h1>
|
||||
<p @EditMarkup.Field(edit, "intro", multiline: true, max: ContentLimits.ParagraphText)>@skills.Intro</p>
|
||||
</div>
|
||||
|
||||
<div class="row skills-grid" @EditMarkup.List(edit, "items")>
|
||||
@for (var i = 0; i < skills.Items.Count; i++)
|
||||
{
|
||||
var item = skills.Items[i];
|
||||
@* Drei Kacheln pro Reihe; die mittlere Spalte hat im Theme eine eigene Variante. *@
|
||||
var boxClass = i % 3 == 1 ? "techno-sinlge-service-box-1" : "techno-sinlge-service-box";
|
||||
if (item.Highlighted)
|
||||
{
|
||||
boxClass += " active";
|
||||
}
|
||||
|
||||
<div class="col-lg-4 col-md-6 col-sm-12" @EditMarkup.Item(edit)>
|
||||
<div class="@boxClass">
|
||||
<div class="techno-service-box-inner">
|
||||
<div class="techno-service-content">
|
||||
<div class="techno-service-icon"><i class="@item.Icon"></i></div>
|
||||
<div class="techno-service-title"><h2 @EditMarkup.Field(edit, "title", max: ContentLimits.TileTitle)>@item.Title</h2><p @EditMarkup.Field(edit, "text", multiline: true, max: ContentLimits.TileText)>@item.Text</p></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@if (edit)
|
||||
{
|
||||
<input class="pe-icon" type="text" data-field="icon" maxlength="@ContentLimits.IconClass" value="@item.Icon" aria-label="Icon-Klasse" />
|
||||
<partial name="_EditItemControls" />
|
||||
<label class="pe-flag"><input type="checkbox" data-flag="highlighted" checked="@(item.Highlighted ? "checked" : null)" /> hervorgehoben</label>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
@if (edit)
|
||||
{
|
||||
<button type="button" class="pe-add" data-add="items">+ Kompetenz</button>
|
||||
}
|
||||
</div>
|
||||
</section>
|
||||
Reference in New Issue
Block a user