Skip to content

Commit

Permalink
Update General.cshtml
Browse files Browse the repository at this point in the history
  • Loading branch information
EdiWang committed Sep 20, 2023
1 parent 41f7d01 commit db27f43
Showing 1 changed file with 119 additions and 92 deletions.
211 changes: 119 additions & 92 deletions src/Moonglade.Web/Pages/Settings/General.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,43 @@
<div class="col-md-6">
<div class="mb-3">
<h4 class="admin-subtitle fw-bold mb-2">@SharedLocalizer["Blog Identity"]</h4>

<div class="settings-entry2 row align-items-center py-3 px-2 rounded-3 shadow-sm border bg-white mb-2">
<div class="col-auto">
<i class="bi-card-heading settings-entry-icon"></i>
</div>
<div class="col">
<label asp-for="ViewModel.SiteTitle"></label>
</div>
<div class="col-md-5 text-end">
<input asp-for="ViewModel.SiteTitle" class="form-control" required />
</div>
</div>

<div class="settings-entry2 row align-items-center py-3 px-2 rounded-3 shadow-sm border bg-white mb-2">
<div class="col-auto">
<i class="bi-input-cursor settings-entry-icon"></i>
</div>
<div class="col">
<label asp-for="ViewModel.LogoText"></label>
</div>
<div class="col-md-5 text-end">
<input asp-for="ViewModel.LogoText" class="form-control" required />
</div>
</div>

<div class="settings-entry2 row align-items-center py-3 px-2 rounded-3 shadow-sm border bg-white mb-2">
<div class="col-auto">
<i class="bi-file-word settings-entry-icon"></i>
</div>
<div class="col">
<label asp-for="ViewModel.MetaKeyword"></label>
</div>
<div class="col-md-5 text-end">
<input asp-for="ViewModel.MetaKeyword" class="form-control" required />
</div>
</div>

<div class="settings-entry2 row align-items-center py-3 px-2 rounded-3 shadow-sm border bg-white mb-2">
<div class="col-auto">
<i class="bi-app-indicator settings-entry-icon"></i>
Expand All @@ -113,23 +150,6 @@
</div>
</div>

<div>
<div class="settings-entry2 row align-items-center py-3 px-2 rounded-3 shadow-sm border bg-white mb-2">
<div class="col">
<label class="form-label" asp-for="ViewModel.SiteTitle"></label>
<input asp-for="ViewModel.SiteTitle" class="form-control" required />
</div>
<div class="col">
<label class="form-label" asp-for="ViewModel.LogoText"></label>
<input asp-for="ViewModel.LogoText" class="form-control" required />
</div>
</div>
<div class="settings-entry2 row align-items-center py-3 px-2 rounded-3 shadow-sm border bg-white mb-2">
<label class="form-label" asp-for="ViewModel.MetaKeyword"></label>
<input asp-for="ViewModel.MetaKeyword" class="form-control" required />
</div>
</div>

<div class="settings-entry2 row align-items-center py-3 px-2 rounded-3 shadow-sm border bg-white mb-2">
<div class="col-auto">
<i class="bi-link settings-entry-icon"></i>
Expand Down Expand Up @@ -168,66 +188,8 @@
<select class="form-select" asp-for="ViewModel.DefaultLanguageCode" asp-items="@langList"></select>
</div>
</div>

<div class="row">
<div class="col-md-2 col-sm-4">
<div class="mb-3">
<img src="@BlogConfig.GeneralSettings.AvatarUrl" class="img-thumbnail img-fluid blogadmin-avatar" />
</div>
<a class="btn w-100 btn-sm btn-outline-accent" href="#" data-bs-toggle="modal" data-bs-target="#avatarmodal">@SharedLocalizer["Change"]</a>
<span class="text-muted text-center d-block">(Avatar)</span>
</div>
<div class="col-md-10 col-sm-8">
<div class="settings-entry2 row align-items-center py-3 px-2 rounded-3 shadow-sm border bg-white mb-2">
<div class="col">
<label class="form-label" asp-for="ViewModel.OwnerName"></label>
<input asp-for="ViewModel.OwnerName" class="form-control" required />
</div>
<div class="col">
<label class="form-label" asp-for="ViewModel.OwnerEmail"></label>
<input asp-for="ViewModel.OwnerEmail" class="form-control" required title="@SharedLocalizer["Email address to receive notifications from this blog."]" />
</div>
</div>
<div class="mb-4">
<div class="form-floating">
<textarea asp-for="ViewModel.Description"
placeholder="@Html.DisplayNameFor(m => m.ViewModel.Description)"
class="form-control h-100px"
spellcheck="false" cols="10" rows="10" required></textarea>
<label class="form-label" asp-for="ViewModel.Description"></label>
</div>
</div>
</div>
</div>
</div>
<div>
<h4 class="admin-subtitle fw-bold mb-2">
@SharedLocalizer["Footer"]
</h4>

<div class="settings-entry2 row align-items-center py-3 px-2 rounded-3 shadow-sm border bg-white mb-2">
<div class="col-auto">
<i class="bi-check2-square settings-entry-icon"></i>
</div>
<div class="col">
<label asp-for="ViewModel.Copyright"></label>
<div class="form-text">@SharedLocalizer["Use [c] for copyright mark: &copy;, [year] for current year."]</div>
</div>
<div class="col-md-5 text-end">
<input asp-for="ViewModel.Copyright" class="form-control" required />
</div>
</div>

<div class="form-floating">
<textarea asp-for="ViewModel.FooterCustomizedHtmlPitch"
placeholder="@Html.DisplayNameFor(m => m.ViewModel.FooterCustomizedHtmlPitch)"
class="form-control form-control-sm h-100px textarea-code"
spellcheck="false" rows="10" cols="10"></textarea>
<label class="form-label" asp-for="ViewModel.FooterCustomizedHtmlPitch"></label>
</div>
</div>
</div>
<div class="col-6">

<div class="mb-3">
<h4 class="admin-subtitle fw-bold mb-2">
@SharedLocalizer["Theme"]
Expand Down Expand Up @@ -264,6 +226,35 @@
</div>
</div>
</div>

<div>
<h4 class="admin-subtitle fw-bold mb-2">
@SharedLocalizer["Footer"]
</h4>

<div class="settings-entry2 row align-items-center py-3 px-2 rounded-3 shadow-sm border bg-white mb-2">
<div class="col-auto">
<i class="bi-check2-square settings-entry-icon"></i>
</div>
<div class="col">
<label asp-for="ViewModel.Copyright"></label>
<div class="form-text">@SharedLocalizer["Use [c] for copyright mark: &copy;, [year] for current year."]</div>
</div>
<div class="col-md-5 text-end">
<input asp-for="ViewModel.Copyright" class="form-control" required />
</div>
</div>

<div class="form-floating">
<textarea asp-for="ViewModel.FooterCustomizedHtmlPitch"
placeholder="@Html.DisplayNameFor(m => m.ViewModel.FooterCustomizedHtmlPitch)"
class="form-control form-control-sm h-100px textarea-code"
spellcheck="false" rows="10" cols="10"></textarea>
<label class="form-label" asp-for="ViewModel.FooterCustomizedHtmlPitch"></label>
</div>
</div>
</div>
<div class="col-6">
<div class="mb-3">
<h4 class="admin-subtitle fw-bold mb-2">
@SharedLocalizer["Side Bar"]
Expand Down Expand Up @@ -291,32 +282,68 @@
</div>
</div>
</div>

<div class="settings-entry2 row align-items-center py-3 px-2 rounded-3 shadow-sm border bg-white mb-2">
<div class="col-auto">
<i class="bi-file-person settings-entry-icon"></i>
</div>
<div class="col">
<label asp-for="ViewModel.WidgetsProfile" class="form-check-label"></label>

<div class="rounded-3 shadow-sm border bg-white mb-2">
<div class="settings-entry2 row align-items-center py-3 px-2">
<div class="col-auto">
<i class="bi-file-person settings-entry-icon"></i>
</div>
<div class="col">
<label asp-for="ViewModel.WidgetsProfile" class="form-check-label"></label>
</div>
<div class="col-md-5 text-end">
<div class="form-check form-switch form-control-lg">
<input type="hidden" name="WidgetsProfile" value="false">
<input type="checkbox" name="WidgetsProfile" value="true" class="form-check-input" @(Model.ViewModel.WidgetsProfile ? "checked" : null)>
</div>
</div>
</div>
<div class="col-md-5 text-end">
<div class="form-check form-switch form-control-lg">
<input type="hidden" name="WidgetsProfile" value="false">
<input type="checkbox" name="WidgetsProfile" value="true" class="form-check-input" @(Model.ViewModel.WidgetsProfile ? "checked" : null)>

<div class="border-top py-3 px-2">
<div class="row">
<div class="col-md-2 col-sm-4">
<div class="mb-3">
<img src="@BlogConfig.GeneralSettings.AvatarUrl" class="img-thumbnail img-fluid blogadmin-avatar" />
</div>
<a class="btn w-100 btn-sm btn-outline-accent" href="#" data-bs-toggle="modal" data-bs-target="#avatarmodal">@SharedLocalizer["Change"]</a>
</div>
<div class="col-md-10 col-sm-8">
<div class="row mb-2">
<div class="col">
<label class="form-label" asp-for="ViewModel.OwnerName"></label>
<input asp-for="ViewModel.OwnerName" class="form-control" required />
</div>
<div class="col">
<label class="form-label" asp-for="ViewModel.OwnerEmail"></label>
<input asp-for="ViewModel.OwnerEmail" class="form-control" required title="@SharedLocalizer["Email address to receive notifications from this blog."]" />
</div>
</div>

<div class="form-floating">
<input asp-for="ViewModel.Description"
placeholder="@Html.DisplayNameFor(m => m.ViewModel.Description)"
class="form-control" required></input>
<label class="form-label" asp-for="ViewModel.Description"></label>
</div>
</div>
</div>
</div>
</div>

<div class="form-floating mb-2">
<textarea asp-for="ViewModel.SideBarCustomizedHtmlPitch"
<div class="border-top py-3 px-2">
<div class="form-floating">
<textarea asp-for="ViewModel.SideBarCustomizedHtmlPitch"
placeholder="@Html.DisplayNameFor(m => m.ViewModel.SideBarCustomizedHtmlPitch)"
class="form-control form-control-sm h-100px textarea-code"
spellcheck="false"
cols="10"
rows="10"></textarea>
<label class="form-label" asp-for="ViewModel.SideBarCustomizedHtmlPitch"></label>
<label class="form-label" asp-for="ViewModel.SideBarCustomizedHtmlPitch"></label>
</div>
</div>
</div>



<div class="settings-entry2 row align-items-center py-3 px-2 rounded-3 shadow-sm border bg-white mb-2">
<div class="col-auto">
<i class="bi-tags settings-entry-icon"></i>
Expand Down

0 comments on commit db27f43

Please sign in to comment.