Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat/custom-labels-login-component #498

Merged
merged 1 commit into from
Jan 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions COMET.Web.Common/Components/Login.razor
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
</Template>
</DxFormLayoutItem>
}
<DxFormLayoutItem Caption="UserName:" BeginRow="true" ColSpanLg="12">
<DxFormLayoutItem Caption="@(this.UsernameLabel)" BeginRow="true" ColSpanLg="12">
<Template>
<DxTextBox Id="username" @bind-Text="@(this.ViewModel.AuthenticationDto.UserName)"
ClearButtonDisplayMode="DataEditorClearButtonDisplayMode.Auto"
Expand All @@ -49,7 +49,7 @@
@onblur="@(() => this.HandleFieldBlur("UserName"))" />
</Template>
</DxFormLayoutItem>
<DxFormLayoutItem Caption="Password:" BeginRow="true" ColSpanLg="12">
<DxFormLayoutItem Caption="@(this.PasswordLabel)" BeginRow="true" ColSpanLg="12">
<Template>
<DxTextBox Id="password" @bind-Text="@(this.ViewModel.AuthenticationDto.Password)"
ClearButtonDisplayMode="DataEditorClearButtonDisplayMode.Auto"
Expand Down
12 changes: 12 additions & 0 deletions COMET.Web.Common/Components/Login.razor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,18 @@ public partial class Login
[Parameter]
public string RequestedServer { get; set; }

/// <summary>
/// The label for the username input field
/// </summary>
[Parameter]
public string UsernameLabel { get; set; } = "UserName:";

/// <summary>
/// The label for the password input field
/// </summary>
[Parameter]
public string PasswordLabel { get; set; } = "Password:";

/// <summary>
/// The text of the login button
/// </summary>
Expand Down
Loading