Issue #4977
This commit is contained in:
		| @ -8,14 +8,14 @@ | ||||
|     { | ||||
|         @if (PageState.Runtime == Runtime.Hybrid) | ||||
|         { | ||||
|             <button type="button" class="btn btn-primary" @onclick="LogoutUser">@Localizer["Logout"]</button> | ||||
|             <button type="button" class="@CssClass" @onclick="LogoutUser">@Localizer["Logout"]</button> | ||||
|         } | ||||
|         else | ||||
|         { | ||||
|             <form method="post" class="app-form-inline" action="@logouturl" @formname="LogoutForm"> | ||||
|                 <input type="hidden" name="@Constants.RequestVerificationToken" value="@SiteState.AntiForgeryToken" /> | ||||
|                 <input type="hidden" name="returnurl" value="@returnurl" /> | ||||
|                 <button type="submit" class="btn btn-primary">@Localizer["Logout"]</button> | ||||
|                 <button type="submit" class="@CssClass">@Localizer["Logout"]</button> | ||||
|             </form> | ||||
|         } | ||||
|     } | ||||
| @ -23,7 +23,7 @@ | ||||
|     { | ||||
|         @if (ShowLogin) | ||||
|         { | ||||
|             <a href="@loginurl" class="btn btn-primary">@SharedLocalizer["Login"]</a> | ||||
|             <a href="@loginurl" class="@CssClass">@SharedLocalizer["Login"]</a> | ||||
|         } | ||||
|     } | ||||
| </span> | ||||
| @ -32,4 +32,6 @@ | ||||
| { | ||||
|     [Parameter] | ||||
|     public bool ShowLogin { get; set; } = true; | ||||
|     [Parameter] | ||||
|     public string CssClass { get; set; } = "btn btn-primary"; | ||||
| } | ||||
| @ -8,13 +8,13 @@ | ||||
| <span class="app-profile"> | ||||
|     @if (PageState.User != null) | ||||
|     { | ||||
|         <a href="@NavigateUrl("profile", "returnurl=" + _returnurl)" class="btn btn-primary">@PageState.User.Username</a> | ||||
|         <a href="@NavigateUrl("profile", "returnurl=" + _returnurl)" class="@CssClass">@PageState.User.Username</a> | ||||
|     } | ||||
|     else | ||||
|     { | ||||
|         @if (ShowRegister && PageState.Site.AllowRegistration) | ||||
|         { | ||||
|             <a href="@NavigateUrl("register", "returnurl=" + _returnurl)" class="btn btn-primary">@Localizer["Register"]</a> | ||||
|             <a href="@NavigateUrl("register", "returnurl=" + _returnurl)" class="@CssClass">@Localizer["Register"]</a> | ||||
|         } | ||||
|     } | ||||
| </span> | ||||
| @ -23,6 +23,8 @@ | ||||
|  | ||||
|     [Parameter] | ||||
|     public bool ShowRegister { get; set; } | ||||
|     [Parameter] | ||||
|     public string CssClass { get; set; } = "btn btn-primary"; | ||||
|  | ||||
|     private string _returnurl = ""; | ||||
|  | ||||
|  | ||||
		Reference in New Issue
	
	Block a user
	 beolafsen
					beolafsen