mirror of
https://github.com/status-im/nft-faucet.git
synced 2025-02-23 12:08:32 +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[] SelectedNetworks { get; set; }
|
||||||
public Guid[] SelectedProviders { get; set; }
|
public Guid[] SelectedProviders { get; set; }
|
||||||
|
public EthereumKey GeneratedKey { get; set; }
|
||||||
}
|
}
|
||||||
|
@ -26,13 +26,11 @@ public partial class ProviderPage : BasicComponent
|
|||||||
[Inject]
|
[Inject]
|
||||||
protected NotificationService NotificationService { get; set; }
|
protected NotificationService NotificationService { get; set; }
|
||||||
|
|
||||||
protected EthereumKey GeneratedKey { get; set; }
|
|
||||||
|
|
||||||
protected CardListItem[] Providers { get; private set; }
|
protected CardListItem[] Providers { get; private set; }
|
||||||
|
|
||||||
protected override void OnInitialized()
|
protected override void OnInitialized()
|
||||||
{
|
{
|
||||||
GeneratedKey = EthereumKey.GenerateNew();
|
// AppState.Storage.GeneratedKey = EthereumKey.GenerateNew();
|
||||||
Providers = new[]
|
Providers = new[]
|
||||||
{
|
{
|
||||||
new CardListItem
|
new CardListItem
|
||||||
@ -43,8 +41,8 @@ public partial class ProviderPage : BasicComponent
|
|||||||
IsDisabled = false,
|
IsDisabled = false,
|
||||||
Properties = new[]
|
Properties = new[]
|
||||||
{
|
{
|
||||||
new CardListItemProperty { Name = "Private key", Value = GeneratedKey.PrivateKey },
|
new CardListItemProperty { Name = "Private key", Value = AppState.Storage.GeneratedKey?.PrivateKey ?? "<null>" },
|
||||||
new CardListItemProperty { Name = "Address", Value = GeneratedKey.Address },
|
new CardListItemProperty { Name = "Address", Value = AppState.Storage.GeneratedKey?.Address ?? "<null>" },
|
||||||
},
|
},
|
||||||
Badges = Array.Empty<CardListItemBadge>(),
|
Badges = Array.Empty<CardListItemBadge>(),
|
||||||
},
|
},
|
||||||
|
Loading…
x
Reference in New Issue
Block a user