mirror of
https://github.com/status-im/nft-faucet.git
synced 2025-02-22 19:48:25 +00:00
Move GeneratedKey to AppState
This commit is contained in:
parent
7ea4dbf9ea
commit
2962ca6446
@ -4,4 +4,5 @@ public class StateStorage
|
||||
{
|
||||
public Guid[] SelectedNetworks { get; set; }
|
||||
public Guid[] SelectedProviders { get; set; }
|
||||
public EthereumKey GeneratedKey { get; set; }
|
||||
}
|
||||
|
@ -26,13 +26,11 @@ public partial class ProviderPage : BasicComponent
|
||||
[Inject]
|
||||
protected NotificationService NotificationService { get; set; }
|
||||
|
||||
protected EthereumKey GeneratedKey { get; set; }
|
||||
|
||||
protected CardListItem[] Providers { get; private set; }
|
||||
|
||||
protected override void OnInitialized()
|
||||
{
|
||||
GeneratedKey = EthereumKey.GenerateNew();
|
||||
// AppState.Storage.GeneratedKey = EthereumKey.GenerateNew();
|
||||
Providers = new[]
|
||||
{
|
||||
new CardListItem
|
||||
@ -43,8 +41,8 @@ public partial class ProviderPage : BasicComponent
|
||||
IsDisabled = false,
|
||||
Properties = new[]
|
||||
{
|
||||
new CardListItemProperty { Name = "Private key", Value = GeneratedKey.PrivateKey },
|
||||
new CardListItemProperty { Name = "Address", Value = GeneratedKey.Address },
|
||||
new CardListItemProperty { Name = "Private key", Value = AppState.Storage.GeneratedKey?.PrivateKey ?? "<null>" },
|
||||
new CardListItemProperty { Name = "Address", Value = AppState.Storage.GeneratedKey?.Address ?? "<null>" },
|
||||
},
|
||||
Badges = Array.Empty<CardListItemBadge>(),
|
||||
},
|
||||
|
Loading…
x
Reference in New Issue
Block a user