Skip to content

Commit

Permalink
update contest artifact
Browse files Browse the repository at this point in the history
add KYC claim flow to player dash
  • Loading branch information
merklejerk committed Jun 14, 2024
1 parent 0f6cd89 commit 7f0403b
Show file tree
Hide file tree
Showing 2 changed files with 223 additions and 24 deletions.
222 changes: 207 additions & 15 deletions src/lib/contest-abi.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,19 @@
"internalType": "address"
},
{
"name": "retirer_",
"name": "admin_",
"type": "address",
"internalType": "address"
},
{
"name": "registrar_",
"type": "address",
"internalType": "address"
},
{
"name": "recoveryAddress_",
"type": "address",
"internalType": "address payable"
}
],
"stateMutability": "nonpayable"
Expand All @@ -24,6 +29,51 @@
"type": "receive",
"stateMutability": "payable"
},
{
"type": "function",
"name": "admin",
"inputs": [],
"outputs": [
{
"name": "",
"type": "address",
"internalType": "address"
}
],
"stateMutability": "view"
},
{
"type": "function",
"name": "allowClaim",
"inputs": [
{
"name": "player",
"type": "address",
"internalType": "address"
}
],
"outputs": [],
"stateMutability": "nonpayable"
},
{
"type": "function",
"name": "canPlayerClaim",
"inputs": [
{
"name": "player",
"type": "address",
"internalType": "address"
}
],
"outputs": [
{
"name": "canClaim",
"type": "bool",
"internalType": "bool"
}
],
"stateMutability": "view"
},
{
"type": "function",
"name": "claim",
Expand Down Expand Up @@ -94,8 +144,8 @@
"outputs": [
{
"name": "prize",
"type": "uint256",
"internalType": "uint256"
"type": "uint96",
"internalType": "uint96"
}
],
"stateMutability": "view"
Expand Down Expand Up @@ -149,7 +199,7 @@
"internalType": "bytes[]"
}
],
"stateMutability": "payable"
"stateMutability": "nonpayable"
},
{
"type": "function",
Expand Down Expand Up @@ -250,6 +300,32 @@
],
"stateMutability": "view"
},
{
"type": "function",
"name": "recoveryAddress",
"inputs": [],
"outputs": [
{
"name": "",
"type": "address",
"internalType": "address payable"
}
],
"stateMutability": "view"
},
{
"type": "function",
"name": "refund",
"inputs": [
{
"name": "amount",
"type": "uint256",
"internalType": "uint256"
}
],
"outputs": [],
"stateMutability": "nonpayable"
},
{
"type": "function",
"name": "register",
Expand Down Expand Up @@ -315,10 +391,10 @@
},
{
"type": "function",
"name": "replaceRegistrar",
"name": "replaceAdmin",
"inputs": [
{
"name": "newRegistrar",
"name": "newAdmin",
"type": "address",
"internalType": "address"
}
Expand All @@ -328,10 +404,10 @@
},
{
"type": "function",
"name": "retire",
"name": "replaceHost",
"inputs": [
{
"name": "player",
"name": "newHost",
"type": "address",
"internalType": "address"
}
Expand All @@ -341,16 +417,42 @@
},
{
"type": "function",
"name": "retirer",
"inputs": [],
"outputs": [
"name": "replaceRegistrar",
"inputs": [
{
"name": "",
"name": "newRegistrar",
"type": "address",
"internalType": "address"
}
],
"stateMutability": "view"
"outputs": [],
"stateMutability": "nonpayable"
},
{
"type": "function",
"name": "restore",
"inputs": [
{
"name": "seasonIdx",
"type": "uint32",
"internalType": "uint32"
}
],
"outputs": [],
"stateMutability": "nonpayable"
},
{
"type": "function",
"name": "retire",
"inputs": [
{
"name": "player",
"type": "address",
"internalType": "address"
}
],
"outputs": [],
"stateMutability": "nonpayable"
},
{
"type": "function",
Expand Down Expand Up @@ -428,7 +530,7 @@
}
],
"outputs": [],
"stateMutability": "payable"
"stateMutability": "nonpayable"
},
{
"type": "function",
Expand Down Expand Up @@ -496,7 +598,7 @@
},
{
"type": "function",
"name": "unclaimedPrize",
"name": "totalUnclaimedPrize",
"inputs": [],
"outputs": [
{
Expand All @@ -523,6 +625,11 @@
"type": "address",
"internalType": "address"
},
{
"name": "prize_",
"type": "uint96",
"internalType": "uint96"
},
{
"name": "unclaimedPrize_",
"type": "uint96",
Expand All @@ -531,6 +638,25 @@
],
"stateMutability": "view"
},
{
"type": "event",
"name": "AdminReplaced",
"inputs": [
{
"name": "oldAdmin",
"type": "address",
"indexed": true,
"internalType": "address"
},
{
"name": "newAdmin",
"type": "address",
"indexed": false,
"internalType": "address"
}
],
"anonymous": false
},
{
"type": "event",
"name": "CodeCommitted",
Expand Down Expand Up @@ -579,6 +705,25 @@
],
"anonymous": false
},
{
"type": "event",
"name": "HostReplaced",
"inputs": [
{
"name": "oldHost",
"type": "address",
"indexed": true,
"internalType": "address"
},
{
"name": "newHost",
"type": "address",
"indexed": false,
"internalType": "address"
}
],
"anonymous": false
},
{
"type": "event",
"name": "OperatorSet",
Expand All @@ -604,6 +749,19 @@
],
"anonymous": false
},
{
"type": "event",
"name": "PlayerAllowedToClaim",
"inputs": [
{
"name": "player",
"type": "address",
"indexed": true,
"internalType": "address"
}
],
"anonymous": false
},
{
"type": "event",
"name": "PrizeClaimed",
Expand All @@ -629,6 +787,25 @@
],
"anonymous": false
},
{
"type": "event",
"name": "PrizeRestored",
"inputs": [
{
"name": "season",
"type": "uint32",
"indexed": true,
"internalType": "uint32"
},
{
"name": "prize",
"type": "uint256",
"indexed": false,
"internalType": "uint256"
}
],
"anonymous": false
},
{
"type": "event",
"name": "Registered",
Expand Down Expand Up @@ -782,6 +959,11 @@
"name": "ConfirmationConsumedError",
"inputs": []
},
{
"type": "error",
"name": "InsufficientBalanceError",
"inputs": []
},
{
"type": "error",
"name": "InvalidCodeHashError",
Expand All @@ -802,6 +984,11 @@
"name": "InvalidPlayerError",
"inputs": []
},
{
"type": "error",
"name": "NotAllowedToClaimError",
"inputs": []
},
{
"type": "error",
"name": "NotRegisteredError",
Expand Down Expand Up @@ -836,5 +1023,10 @@
"type": "error",
"name": "SeasonNotClosedError",
"inputs": []
},
{
"type": "error",
"name": "TooSoonError",
"inputs": []
}
]
Loading

0 comments on commit 7f0403b

Please sign in to comment.