mirror of
https://github.com/LBPUnion/ProjectLighthouse.git
synced 2025-08-01 09:48:37 +00:00
User settings, level settings, language and timezone selection and more. (#471)
* Initial work for user settings page * Finish user setting and slot setting pages * Don't show slot upload date on home page and fix team pick redirection * Fix upload image button alignment on mobile * Fix image upload on iPhone * Remove unused css and add selected button color * Fix login email check and bump ChromeDriver to 105 * Remove duplicated code and allow users to leave fields empty * Add unpublish button on level settings and move settings button position * Don't show edit button on mini card * Self review bug fixes and users can no longer use an in-use email
This commit is contained in:
parent
9073a8266f
commit
f6a7fe6283
53 changed files with 973 additions and 118 deletions
|
@ -5,7 +5,6 @@
|
|||
@using LBPUnion.ProjectLighthouse.Localization.StringLists
|
||||
@using LBPUnion.ProjectLighthouse.PlayerData
|
||||
@using LBPUnion.ProjectLighthouse.Servers.Website.Extensions
|
||||
@using LBPUnion.ProjectLighthouse.Types
|
||||
@model LBPUnion.ProjectLighthouse.Servers.Website.Pages.UserPage
|
||||
|
||||
@{
|
||||
|
@ -15,8 +14,9 @@
|
|||
Model.Title = Model.Translate(ProfileStrings.Title, Model.ProfileUser!.Username);
|
||||
Model.Description = Model.ProfileUser!.Biography;
|
||||
|
||||
bool isMobile = this.Request.IsMobile();
|
||||
bool isMobile = Request.IsMobile();
|
||||
string language = Model.GetLanguage();
|
||||
string timeZone = Model.GetTimeZone();
|
||||
}
|
||||
|
||||
@if (Model.ProfileUser.IsBanned)
|
||||
|
@ -50,7 +50,10 @@
|
|||
},
|
||||
{
|
||||
"Language", Model.GetLanguage()
|
||||
}
|
||||
},
|
||||
{
|
||||
"TimeZone", Model.GetTimeZone()
|
||||
},
|
||||
})
|
||||
</div>
|
||||
<div class="eight wide right aligned column">
|
||||
|
@ -72,13 +75,15 @@
|
|||
</a>
|
||||
}
|
||||
}
|
||||
@if (Model.ProfileUser == Model.User || (Model.User?.IsModerator ?? false))
|
||||
{
|
||||
<a class="ui blue button" href="/user/@Model.ProfileUser.UserId/settings">
|
||||
<i class="cog icon"></i>
|
||||
<span>Settings</span>
|
||||
</a>
|
||||
}
|
||||
@if (Model.ProfileUser == Model.User)
|
||||
{
|
||||
<a class="ui blue button" href="/passwordReset">
|
||||
<i class="key icon"></i>
|
||||
<span>@Model.Translate(GeneralStrings.ResetPassword)</span>
|
||||
</a>
|
||||
|
||||
<a href="/logout" class="ui red button">
|
||||
<i class="user slash icon"></i>
|
||||
@Model.Translate(BaseLayoutStrings.HeaderLogout)
|
||||
|
@ -129,7 +134,7 @@
|
|||
{
|
||||
string width = isMobile ? "sixteen" : "eight";
|
||||
<div class="@width wide column">
|
||||
@await photo.ToHtml(Html, ViewData, language)
|
||||
@await photo.ToHtml(Html, ViewData, language, timeZone)
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
|
@ -140,7 +145,7 @@
|
|||
}
|
||||
}
|
||||
|
||||
@await Html.PartialAsync("Partials/CommentsPartial", ViewData.WithLang(language))
|
||||
@await Html.PartialAsync("Partials/CommentsPartial", ViewData.WithLang(language).WithTime(timeZone))
|
||||
|
||||
@if (Model.User != null && Model.User.IsModerator)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue