mirror of
https://github.com/status-im/nft-faucet.git
synced 2025-02-24 04:28:29 +00:00
35 lines
1.3 KiB
Plaintext
35 lines
1.3 KiB
Plaintext
@page "/configuration/{CardListItemId}"
|
|
@inherits BasicComponent
|
|
|
|
<PageTitle>Configuration</PageTitle>
|
|
|
|
<form onsubmit="@OnSavePressed">
|
|
@foreach (var configurationObject in CardListItem.Configuration.Objects)
|
|
{
|
|
switch (configurationObject.Type)
|
|
{
|
|
case CardListItemConfigurationObjectType.Input:
|
|
{
|
|
<div class="mb-4">
|
|
<h4>@configurationObject.Name</h4>
|
|
<RadzenTextBox Placeholder=@configurationObject.Placeholder @bind-Value="@configurationObject.Value" Disabled="@configurationObject.IsDisabled" Class="w-100"/>
|
|
</div>
|
|
break;
|
|
}
|
|
case CardListItemConfigurationObjectType.Button:
|
|
{
|
|
<div class="mb-4">
|
|
<RadzenButton Text="@configurationObject.Name" Click="@(() => configurationObject.ClickAction())" Disabled="@configurationObject.IsDisabled" Class="w-100"/>
|
|
</div>
|
|
break;
|
|
}
|
|
default:
|
|
throw new ArgumentOutOfRangeException();
|
|
}
|
|
}
|
|
|
|
<div style="display: flex; justify-content: end;">
|
|
<RadzenButton Click="@((args) => OnSavePressed())" Text="Save" Style="width: 120px"/>
|
|
</div>
|
|
</form>
|