Skip to content

Commit e7b0070

Browse files
kammradtlaurogripa
andauthored
Payouts page (#167)
* Implement payouts page * Calculate remaining time until payout maturity * Add a matured payout to chopsticks storage * Bump node version * Add tx status * Change logo and title --------- Co-authored-by: Lauro Gripa <laurogripa@gmail.com>
1 parent 42a0437 commit e7b0070

File tree

20 files changed

+3034
-2473
lines changed

20 files changed

+3034
-2473
lines changed

.nvmrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
v18.15.0
1+
v20.12.2

config/kusama.yml.sample

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@ import-storage:
5858
- Bids
5959
- Candidates
6060
- Members
61+
- Payouts
6162
Bids:
6263
- who: 5GrwvaEF5zXb26Fz9rcQpDWS57CtERHpNehXCPcNoHGKutQY # Alice
6364
kind:
@@ -102,6 +103,15 @@ import-storage:
102103
ChallengeRoundCount: 6
103104
RoundCount: 6
104105
MemberCount: 2
105-
Head: 5HGjWAeFDfFCWPsjFQdVV2Msvz2XtMktvgocEZcCj68kUMaw
106+
Head: 5HGjWAeFDfFCWPsjFQdVV2Msvz2XtMktvgocEZcCj68kUMaw # Eve
107+
Payouts:
108+
-
109+
-
110+
- 5CiPPseXPECbkjWCa6MnjNokrgYjMqmKndv2rSnekmSK2DjL # Ferdie
111+
- paid: 0
112+
payouts:
113+
-
114+
- 20000000
115+
- 15000000000000
106116
ParasDisputes:
107117
$removePrefix: ['disputes'] # those can makes block building super slow

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "ksm-app",
3-
"version": "0.2.0",
3+
"version": "2.0.1",
44
"homepage": "https://KappaSigmaMu.github.io/",
55
"types": "src/types.d.ts",
66
"dependencies": {
@@ -129,7 +129,7 @@
129129
},
130130
"scripts": {
131131
"build": "NODE_OPTIONS=--openssl-legacy-provider node scripts/build.js",
132-
"chopsticks": "npx @acala-network/chopsticks@latest --config=config/kusama.yml",
132+
"chopsticks": "npx @acala-network/chopsticks@1.0.6 --config=config/kusama.yml",
133133
"cy:open": "cypress open",
134134
"deploy": "gh-pages -d build",
135135
"eslint:fix": "eslint \"{src,apps,libs,test}/**/*.{ts,tsx}\" --fix",
@@ -152,5 +152,5 @@
152152
"not dead",
153153
"not op_mini all"
154154
],
155-
"packageManager": "yarn@4.5.2"
155+
"packageManager": "yarn@4.5.1"
156156
}

src/components/Navbar.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ const Navbar = ({
1919
const [showMenu, setShowMenu] = useState(false)
2020

2121
return (
22-
<RBNavbar className="pt-4">
22+
<RBNavbar className="pt-3">
2323
<Container>
2424
<Nav className="align-items-center align-self-center">
2525
{showBrandIcon ? <NavbarBrand /> : <BrandPlaceholder />}
@@ -91,7 +91,7 @@ const BrandPlaceholder = () => <div style={{ height: 82, width: 106 }}></div>
9191

9292
const NavbarBrand = () => (
9393
<RBNavbar.Brand as={LinkWithQuery} to="/">
94-
<img width={90} src={KappaSigmaMu} alt="KappaSigmaMu Logo" />
94+
<img width={200} src={KappaSigmaMu} alt="KappaSigmaMu Logo" style={{ margin: '-40px' }} />
9595
</RBNavbar.Brand>
9696
)
9797

src/hooks/useBlockTime.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@ export function useBlockTime(blocks: number | BN = BN_ONE, apiOverride?: ApiProm
2424
(a.consts.timestamp?.minimumPeriod.gte(THRESHOLD)
2525
? a.consts.timestamp.minimumPeriod.mul(BN_TWO)
2626
: a.query.parachainSystem
27-
? DEFAULT_TIME.mul(BN_TWO)
28-
: DEFAULT_TIME)
27+
? DEFAULT_TIME.mul(BN_TWO)
28+
: DEFAULT_TIME)
2929
const value = blockTime.mul(bnToBn(blocks)).toNumber()
3030
const time = extractTime(Math.abs(value))
3131
const { days, hours, minutes, seconds } = time

src/pages/FuturivelPage.tsx

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -462,7 +462,13 @@ const FuturivelPage = () => {
462462
<ActionsContainer>
463463
<div className="">
464464
<span>Join the</span>
465-
<KappaSigmaMu src={KappaSigmaMuTitle} alt="Kappa Sigma Mu Title" />
465+
<KappaSigmaMu
466+
className="d-none d-lg-block"
467+
src={KappaSigmaMuTitle}
468+
alt="Kappa Sigma Mu Title"
469+
width={800}
470+
style={{ margin: '-140px -180px' }}
471+
/>
466472
</div>
467473
<OutlinedPrimaryLgButton onClick={() => handleButtonClick('/guide')}>
468474
Cyborg

src/pages/GilbertoGilPage.tsx

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,13 @@ const GilbertoGilPage = () => {
9494
<CentralizedCol xs={0} lg={8} />
9595
<CentralizedCol xs={12} lg={4}>
9696
<h1 className="d-none d-lg-block">Join the</h1>
97-
<KappaSigmaMu className="d-none d-lg-block" src={KappaSigmaMuTitle} alt="Kappa Sigma Mu Title" />
97+
<KappaSigmaMu
98+
className="d-none d-lg-block"
99+
src={KappaSigmaMuTitle}
100+
alt="Kappa Sigma Mu Title"
101+
width={800}
102+
style={{ margin: '-140px -180px' }}
103+
/>
98104
<ActionsContainer>
99105
<OutlinedPrimaryLgButton onClick={() => handleButtonClick('/explore/bidders')}>
100106
Explore

src/pages/LandingPage.tsx

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -92,10 +92,16 @@ const LandingPage = () => {
9292
/>
9393
)}
9494
</div>
95-
<CentralizedCol xs={0} lg={8} />
96-
<CentralizedCol xs={12} lg={4}>
95+
<CentralizedCol xs={0} lg={7} />
96+
<CentralizedCol xs={12} lg={5}>
9797
<h1 className="d-none d-lg-block">Join the</h1>
98-
<KappaSigmaMu className="d-none d-lg-block" src={KappaSigmaMuTitle} alt="Kappa Sigma Mu Title" />
98+
<KappaSigmaMu
99+
className="d-none d-lg-block"
100+
src={KappaSigmaMuTitle}
101+
alt="Kappa Sigma Mu Title"
102+
width={800}
103+
style={{ margin: '-140px -180px' }}
104+
/>
99105
<ActionsContainer className="container">
100106
<OutlinedPrimaryLgButton onClick={() => handleButtonClick('/explore/bidders')}>
101107
Explore

src/pages/explore/CandidatesPage/components/CandidatesList.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ import { useAccount } from '../../../../account/AccountContext'
1212
import { AccountIdentity } from '../../../../components/AccountIdentity'
1313
import { DataHeaderRow, DataRow } from '../../../../components/base'
1414
import { FormatBalance } from '../../../../components/FormatBalance'
15-
// import { truncate } from '../../../../helpers/truncate'
1615
import { Identicon } from '../../components/Identicon'
1716
import { toastByStatus } from '../../helpers'
1817

src/pages/explore/CandidatesPage/components/DropButton.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ export function DropButton({
5454
if (loading)
5555
return (
5656
<div className="mx-2">
57-
<LoadingSpinner center={true} small={true} />
57+
<LoadingSpinner center={false} small={true} />
5858
</div>
5959
)
6060

0 commit comments

Comments
 (0)