fix: unbreak some storybook pages

This commit is contained in:
Lukáš Tinkl 2023-08-15 13:18:17 +02:00 committed by Lukáš Tinkl
parent f4b028bd71
commit 99ca9c28b5
3 changed files with 13 additions and 18 deletions

View File

@ -198,6 +198,7 @@ SplitView {
readonly property string color: "red" readonly property string color: "red"
readonly property bool owner: true readonly property bool owner: true
} }
accountsModel: WalletAccountsModel {}
onAirdropClicked: logs.logEvent("AirdropsSettingsPanel::onAirdropClicked") onAirdropClicked: logs.logEvent("AirdropsSettingsPanel::onAirdropClicked")
} }

View File

@ -85,7 +85,8 @@ SplitView {
onlineStatus: 1, onlineStatus: 1,
pubKey: key, pubKey: key,
isVerified: true, isVerified: true,
isUntrustworthy: false isUntrustworthy: false,
airdropAddress: `0x${firstLetter}${i}`
}) })
} }

View File

@ -9,13 +9,16 @@ QtObject {
readonly property int arbitrumNet: 3 readonly property int arbitrumNet: 3
readonly property int hermezNet: 4 readonly property int hermezNet: 4
readonly property int testnetNet: 5 readonly property int testnetNet: 5
readonly property int customNet: 6 readonly property int customNet: 6
readonly property var layer1Networks: ListModel { component CustomNetworkModel: ListModel {
// Simulate Nim's way of providing access to data
function rowData(index, propName) { function rowData(index, propName) {
return get(index)[propName] return get(index)[propName]
} }
}
readonly property var layer1Networks: CustomNetworkModel {
Component.onCompleted: Component.onCompleted:
append([ append([
{ {
@ -31,7 +34,7 @@ QtObject {
]) ])
} }
readonly property var layer2Networks: ListModel { readonly property var layer2Networks: CustomNetworkModel {
Component.onCompleted: Component.onCompleted:
append([ append([
{ {
@ -57,7 +60,7 @@ QtObject {
]) ])
} }
readonly property var testNetworks: ListModel { readonly property var testNetworks: CustomNetworkModel {
Component.onCompleted: Component.onCompleted:
append([ append([
{ {
@ -93,12 +96,7 @@ QtObject {
]) ])
} }
readonly property var enabledNetworks: ListModel { readonly property var enabledNetworks: CustomNetworkModel {
// Simulate Nim's way of providing access to data
function rowData(index, propName) {
return get(index)[propName]
}
Component.onCompleted: Component.onCompleted:
append([ append([
{ {
@ -170,12 +168,7 @@ QtObject {
]) ])
} }
readonly property var allNetworks: ListModel { readonly property var allNetworks: CustomNetworkModel {
// Simulate Nim's way of providing access to data
function rowData(index, propName) {
return get(index)[propName]
}
Component.onCompleted: append([ Component.onCompleted: append([
{ {
chainId: 1, chainId: 1,
@ -264,7 +257,7 @@ QtObject {
) )
} }
readonly property var mainNetworks: ListModel { readonly property var mainNetworks: CustomNetworkModel {
Component.onCompleted: append([ Component.onCompleted: append([
{ {
chainId: 1, chainId: 1,