Skip to content
This repository was archived by the owner on Aug 1, 2022. It is now read-only.
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
419 commits
Select commit Hold shift + click to select a range
8bbc669
QRcode modal nit improvements
NunoAlexandre Nov 10, 2020
6ebf8ac
Update added/removed Receiver styling
NunoAlexandre Nov 10, 2020
1ede8f0
Don't set wallet as connecting until initialize
NunoAlexandre Nov 10, 2020
47f6cee
Reduce transactions status updates polling
NunoAlexandre Nov 10, 2020
0978ae4
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Nov 11, 2020
e272ff0
Update upcoming support design
NunoAlexandre Nov 11, 2020
e5911c1
Redesign Wallet Panel
NunoAlexandre Nov 11, 2020
441a82b
Fix screen layout and elements positioning
NunoAlexandre Nov 11, 2020
1dfa927
Make the Incoming component dumber
NunoAlexandre Nov 11, 2020
c859bf7
wip: Update outgoing support style
NunoAlexandre Nov 11, 2020
73f238b
Make Receiver(s) editable or view-only
NunoAlexandre Nov 11, 2020
50b191d
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Nov 12, 2020
3f5f306
Please the lint and fix broken pieces
NunoAlexandre Nov 12, 2020
05d52f8
Drop "awaiting scan" section from QRCode modal
NunoAlexandre Nov 12, 2020
2554b8a
Make wallet a singleton
NunoAlexandre Nov 12, 2020
47c445a
Add 'link' icon
NunoAlexandre Nov 12, 2020
a153b4c
Add 'Socks' Illustration
NunoAlexandre Nov 12, 2020
8574cdb
Add LinkAddress mock Modal
NunoAlexandre Nov 12, 2020
21b2005
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Nov 12, 2020
41fb295
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Nov 13, 2020
8c3a9e6
Set up stub attestation flow
NunoAlexandre Nov 13, 2020
0d4aa82
wip: New onboarding flow
NunoAlexandre Nov 13, 2020
f622ae1
Bind Onboarding sub-component values
NunoAlexandre Nov 16, 2020
a0d9c54
Drop Save button from Receivers
NunoAlexandre Nov 16, 2020
8247360
Delete the now old onboarding
NunoAlexandre Nov 16, 2020
ac15369
Validate SetBudget input
NunoAlexandre Nov 16, 2020
bf610f0
fixup!
NunoAlexandre Nov 16, 2020
39a9bcf
Validate Onboarding TopUp amount
NunoAlexandre Nov 16, 2020
547f3a3
Create onboarding tx stub
NunoAlexandre Nov 16, 2020
55aa2f8
Make onboarding review confirm button a TxButton
NunoAlexandre Nov 16, 2020
2b26006
Fix onboarding stub and close onboarding on success
NunoAlexandre Nov 16, 2020
6c60120
Add Support.svelte for the settled outgoing support
NunoAlexandre Nov 16, 2020
e8e2717
Set up basic editing mode for outgoing support
NunoAlexandre Nov 16, 2020
25924cc
wip: Save support settings
NunoAlexandre Nov 16, 2020
e3d96ee
refactor: make 'receivers' a Map<Address, Weight>
NunoAlexandre Nov 17, 2020
b71bf43
Fix check around changes in receivers
NunoAlexandre Nov 17, 2020
c56c849
Only save changed receivers
NunoAlexandre Nov 17, 2020
f0b12d2
Add LinkAddress screen
NunoAlexandre Nov 17, 2020
420a141
Make identity.linkedAddress a writable store
NunoAlexandre Nov 17, 2020
1b5d555
Update 'Receiver' styling
NunoAlexandre Nov 17, 2020
6368774
Disable Receivers '+' button on empty input
NunoAlexandre Nov 17, 2020
36b3aba
fix: Refresh changeset on changes to "editing"
NunoAlexandre Nov 17, 2020
7210177
Sort receivers in order of Added, Present, Removed
NunoAlexandre Nov 17, 2020
58e1c48
Move Eth -> Radicle linking to separate component
NunoAlexandre Nov 17, 2020
cf1a2f6
Implement the complete attestation modal flow
NunoAlexandre Nov 17, 2020
ad691ea
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Nov 19, 2020
501365f
Fix receivers overflow with flex-wrap
NunoAlexandre Nov 19, 2020
779392a
Fix unremovable receivers on onboarding
NunoAlexandre Nov 19, 2020
693c575
Clean up onboarding state check
NunoAlexandre Nov 19, 2020
37d75e9
Fix Receivers horizontal padding
NunoAlexandre Nov 19, 2020
75c0da1
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Nov 19, 2020
2e77d57
Responsively display wallet balance as currency
NunoAlexandre Nov 20, 2020
f86c642
Implement wallet disconnect btn in dropdown
NunoAlexandre Nov 20, 2020
637f6d0
Update wallet QRCode modal styling
NunoAlexandre Nov 20, 2020
26ebe15
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Nov 20, 2020
4cbe610
Extract the template out of the onboarding top up
NunoAlexandre Nov 20, 2020
be8a054
Use TopUp template in TopUp modal
NunoAlexandre Nov 20, 2020
67e2c2a
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Nov 23, 2020
c2214b3
Make the continue btn a slot in TopUp
NunoAlexandre Nov 23, 2020
1ccc626
Redesign and re-implement the withdraw modal
NunoAlexandre Nov 23, 2020
f0a0135
Bump Radicle Contracts
NunoAlexandre Nov 23, 2020
00963ba
Offer withdraw(x) or withdrawAll
NunoAlexandre Nov 23, 2020
e007588
Fix imports (#1314)
CodeSandwich Nov 23, 2020
86c33d9
Fix broken reference to ./node_modules/.bin/ethers
NunoAlexandre Nov 23, 2020
c5aca6f
Bump Radicle Contracts
NunoAlexandre Nov 23, 2020
0b19f90
Add missing errorMessage prop to TxButton
NunoAlexandre Nov 23, 2020
1da251e
Use EthPool and EthPoolFactory
NunoAlexandre Nov 23, 2020
d1f08ad
Fix cash out modal styling
NunoAlexandre Nov 23, 2020
19d153f
Redesign Collect modal
NunoAlexandre Nov 23, 2020
ea4d57f
Drop gas info from Transaction
NunoAlexandre Nov 23, 2020
ad4ba72
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Nov 23, 2020
d2bf2f6
Persist the identity linkedAddress stub
NunoAlexandre Nov 23, 2020
87b54e3
Update some copy
NunoAlexandre Nov 23, 2020
8f41aa0
fixup!
NunoAlexandre Nov 23, 2020
b45e727
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Nov 24, 2020
e552378
Fix Transaction modal closing when selecting other
NunoAlexandre Nov 24, 2020
3ef91e7
Fix transaciton center stack closing on tx updates
NunoAlexandre Nov 24, 2020
68a94c5
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Nov 24, 2020
62d24be
Track yarn.lock changes
NunoAlexandre Nov 24, 2020
3fdce3e
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Nov 25, 2020
9386ea7
Delete obsolete Box component
NunoAlexandre Nov 25, 2020
82cc003
Add WalletConnect icon
NunoAlexandre Nov 25, 2020
6b016c9
Add the walletconnect icon to the QRModal
NunoAlexandre Nov 25, 2020
26ac56a
Design-QA the attestation flow
NunoAlexandre Nov 25, 2020
f18a5ef
Design-QA the support onboarding flow
NunoAlexandre Nov 25, 2020
fb86099
Fix Withdraw input value validation
NunoAlexandre Nov 25, 2020
1b03508
Drop fixed height for the TopUp modal
NunoAlexandre Nov 25, 2020
10d117d
Fix missing '-' on negative DAI
NunoAlexandre Nov 25, 2020
92711f8
Show custom onboarding text on no receivers
NunoAlexandre Nov 25, 2020
7ae45e4
Namespace Transaction Center components
NunoAlexandre Nov 26, 2020
ade9918
Place negative symbol between dai symbol and value
NunoAlexandre Nov 26, 2020
53007ff
Redesign the Transaction modal
NunoAlexandre Nov 26, 2020
758fc38
Include changes to receivers in stored tx
NunoAlexandre Nov 26, 2020
0cc1c63
Show changes to receivers in Transaction summary
NunoAlexandre Nov 26, 2020
37474a4
Format Transaction date accordingly to Figma
NunoAlexandre Nov 26, 2020
542eafa
Update Transaction id/hash style
NunoAlexandre Nov 26, 2020
d36bb1a
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Nov 26, 2020
6fbec0d
Fix DAI negative/regular variants
NunoAlexandre Nov 26, 2020
7d3d6a9
Refactor transaction model design
NunoAlexandre Nov 26, 2020
04c0f70
Fix fatal error on withdrawing
NunoAlexandre Nov 26, 2020
c6daaa4
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Nov 26, 2020
aca4a01
Use store to its full extent
NunoAlexandre Nov 30, 2020
ab85757
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Nov 30, 2020
0d4eada
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Dec 1, 2020
aa65e39
Bump and make radicle-contracts a local dep
NunoAlexandre Dec 1, 2020
f605e3f
Support setting multiple receivers in batch
NunoAlexandre Dec 1, 2020
5dee7f9
Fix validation row on the Support screen
NunoAlexandre Dec 1, 2020
2c8e86c
Fix attestation flow closing unexpectedly
NunoAlexandre Dec 1, 2020
e078db2
Fix Transaction Center collapse/expand button
NunoAlexandre Dec 1, 2020
fd40502
Don't set receivers if none to set
NunoAlexandre Dec 1, 2020
d501dd9
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Dec 1, 2020
92789b4
Fix inlined Dai horizontal margins
NunoAlexandre Dec 1, 2020
5b2b485
Center-align list of Receivers in the onboarding
NunoAlexandre Dec 3, 2020
2fb6ad6
Only show Tx 'Amount' when sensible
NunoAlexandre Dec 3, 2020
6276666
Delete Gwei component
NunoAlexandre Dec 3, 2020
5e55607
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Dec 3, 2020
7e5c31f
Fix tx chain run over
NunoAlexandre Dec 4, 2020
4d28815
Drop attestation flow
NunoAlexandre Dec 4, 2020
24040e6
Sort settings.ts types by hierarchy
NunoAlexandre Dec 4, 2020
b01eb5a
Add feature flags field to the Settings
NunoAlexandre Dec 4, 2020
bfb1889
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Dec 4, 2020
5b95e4a
Actually update funding feature flag
NunoAlexandre Dec 5, 2020
73024f7
Hide funding feat behind funding feature flag
NunoAlexandre Dec 5, 2020
903a406
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Dec 7, 2020
fc2d60a
wallet: Refresh connected account data every 3s
NunoAlexandre Dec 7, 2020
77e1fd2
Say yes to setting up initial balance
NunoAlexandre Dec 9, 2020
a9d744b
Document the Funding feature and setup
NunoAlexandre Dec 9, 2020
cb6d47e
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Dec 9, 2020
bd5a86f
fixup! Fix link to funding dev setup image
NunoAlexandre Dec 9, 2020
6990691
Fix funding-dev-setup.svg missing bg color
NunoAlexandre Dec 9, 2020
d2fa7fc
Make funding-dev-setup.svg text more readable
NunoAlexandre Dec 9, 2020
6b0a0b4
Fix link
NunoAlexandre Dec 9, 2020
c60cb11
Fix code snippet to clone wc test wallet repo
NunoAlexandre Dec 9, 2020
a40a925
Update docs on the new yarn command
NunoAlexandre Dec 9, 2020
a36d284
wip: Integrate all things ERC-20
NunoAlexandre Dec 10, 2020
249e321
Fix erc20Allowance()
NunoAlexandre Dec 10, 2020
cca0e6b
Set dev account intial erc20 token balance
NunoAlexandre Dec 10, 2020
16c71f9
Use the right erc20 pool contract address
NunoAlexandre Dec 10, 2020
95a4078
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Dec 10, 2020
a915393
Merge remote-tracking branch 'origin/feat/funding' into feat/funding-…
NunoAlexandre Dec 10, 2020
8213608
Add new Erc20Allowance tx variant
NunoAlexandre Dec 11, 2020
f8a2ea1
Add ERC-20 approval step to the support onboarding
NunoAlexandre Dec 11, 2020
f1e1d18
Drop stub code to approve ERC-20
NunoAlexandre Dec 11, 2020
2080ed2
Store tx record for the ERC-20 allowance
NunoAlexandre Dec 11, 2020
6a95f7d
Add right illustration to Erc20Allowance modal
NunoAlexandre Dec 11, 2020
5a3d931
Add node v12 to list of getting started steps
NunoAlexandre Dec 11, 2020
fd82170
Update QRCode modal style
NunoAlexandre Dec 14, 2020
3fc3d3e
Drop Icon/WalletConnect
NunoAlexandre Dec 14, 2020
6474bfc
Read user's balance from the ERC20 token contract
NunoAlexandre Dec 14, 2020
5d76df3
Add 'get' method to remote Store
NunoAlexandre Dec 14, 2020
533e2cc
Make erc20Allowance an attribute of PoolData
NunoAlexandre Dec 14, 2020
56459f9
Make remote.Store.get -> unwrap
NunoAlexandre Dec 14, 2020
af24778
Read poolData.erc20Allowance to resolve onboarding
NunoAlexandre Dec 14, 2020
6b71d19
Use remote store unwrap method in Withdraw too
NunoAlexandre Dec 14, 2020
00b2989
Fix link to WalletConnect supported wallets
NunoAlexandre Dec 14, 2020
4da121b
r/ganachi/ganache
NunoAlexandre Dec 14, 2020
d2f655f
Update FUNDING.md
NunoAlexandre Dec 14, 2020
5a09bb1
Mention that the local ganache uses no real assets
NunoAlexandre Dec 14, 2020
f8e34b3
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Dec 14, 2020
8e17df3
r/Ganachi/Ganache
NunoAlexandre Dec 14, 2020
c12dca7
Fix balance dai symbol color
NunoAlexandre Dec 14, 2020
67dbdeb
Fix all "implicitly has an 'any' type"
NunoAlexandre Dec 14, 2020
163d538
Drop tmp code
NunoAlexandre Dec 14, 2020
23d57e5
Use Erc20 contract and factory instead of Rad
NunoAlexandre Dec 14, 2020
478f2c2
Fix warning with parsing json file of dependency
NunoAlexandre Dec 15, 2020
0f33af4
Fix circular dependency warning caused by Identity
NunoAlexandre Dec 15, 2020
42e27a1
Ignore two specific 3rd-party warnings
NunoAlexandre Dec 15, 2020
deed9c7
Support onboarding in a batch tx
NunoAlexandre Dec 15, 2020
f5aae82
Reduce rollup warnings noise
NunoAlexandre Dec 15, 2020
17a4dea
Update support plan in a batch transaction
NunoAlexandre Dec 15, 2020
8392617
Store the new list of receivers instead of changes
NunoAlexandre Dec 15, 2020
19db263
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Dec 15, 2020
3ea5f37
Offer ergonomic in-between Pool Contract API
NunoAlexandre Dec 16, 2020
d928fd5
Store user inputed topUp amount
NunoAlexandre Dec 16, 2020
3453fed
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Dec 16, 2020
12d0a47
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Dec 18, 2020
8c8af28
Document how to setup the Radicle Contracts locally
NunoAlexandre Dec 18, 2020
0effe6b
Add ethers-cli dependency (#1493)
CodeSandwich Dec 18, 2020
9e75784
Update contracts addresses
NunoAlexandre Dec 18, 2020
22a72ea
Break free from node v12 for the ethereum setup
NunoAlexandre Dec 18, 2020
d515d9b
Drop 'currency' style element
NunoAlexandre Dec 18, 2020
c118793
Fix issue with transactions with the same hash
NunoAlexandre Dec 18, 2020
12a844c
Undo styling changes to the notifications
NunoAlexandre Dec 18, 2020
a9dff3c
Fix QRCode modal on dark mode
NunoAlexandre Dec 18, 2020
3c189fa
Update notification waiting for tx approval
NunoAlexandre Dec 18, 2020
97f0d3b
Drop 'success' notification type
NunoAlexandre Dec 18, 2020
a1a260c
Address design QA part 1
NunoAlexandre Dec 18, 2020
38d311f
Design QA part 2
NunoAlexandre Dec 21, 2020
e7c44a0
Design QA part 3
NunoAlexandre Dec 21, 2020
7c325b9
Proceed funding onboarding by pressing enter
NunoAlexandre Dec 22, 2020
add358a
Fix Dai color bug when switching between txs
NunoAlexandre Dec 22, 2020
acd9b72
Improve Dai component coloring and styling
NunoAlexandre Dec 22, 2020
5447b09
Validate valid Ethereum address input
NunoAlexandre Dec 28, 2020
08d3860
Fix typo
NunoAlexandre Dec 28, 2020
10852e9
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Jan 4, 2021
ff97593
Have radicle-contracts as a git dependency
NunoAlexandre Jan 5, 2021
cad38e3
Make the radicle-contracts a git dependency again
NunoAlexandre Jan 6, 2021
8e68240
Fix circular dependency warning
NunoAlexandre Jan 6, 2021
db092fd
Don't show TransactionCenter til session unsealed
NunoAlexandre Jan 6, 2021
e1420b7
Refactor Hotkeys disabled before session unsealed
NunoAlexandre Jan 6, 2021
cc7fb8d
Revert "Refactor Hotkeys disabled before session unsealed"
NunoAlexandre Jan 6, 2021
6eb1517
Run prettier
NunoAlexandre Jan 6, 2021
4610454
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Jan 6, 2021
74db89e
Address all Svelte and Typescript errors
NunoAlexandre Jan 7, 2021
61a5b07
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Jan 7, 2021
af34d1d
Update ui/src/transaction.ts
NunoAlexandre Jan 8, 2021
5f3f5be
Update ui/Modal/Transaction.svelte
NunoAlexandre Jan 8, 2021
d52146a
feat(ui): label default branch in RevisionSelector (#1503)
juliendonck Jan 7, 2021
477210a
Address some of the review comments
NunoAlexandre Jan 8, 2021
af10e19
fixup!
NunoAlexandre Jan 8, 2021
064a192
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Jan 8, 2021
55342e6
Address Rudolf's review part 1
NunoAlexandre Jan 11, 2021
3fc787a
Delete all debug logs
NunoAlexandre Jan 11, 2021
c250fa0
s/_pool/fundingPool
NunoAlexandre Jan 11, 2021
b15e1ab
Drop new illustrations in favour of Emoji
NunoAlexandre Jan 11, 2021
078b50a
Center Plus icon vertically
NunoAlexandre Jan 11, 2021
f0bf73e
Fix Funding feature flag toggle issue
NunoAlexandre Jan 11, 2021
75292ae
Run prettier
NunoAlexandre Jan 11, 2021
e0c0fd3
Fix balance sufficiency check
NunoAlexandre Jan 11, 2021
ee4bb02
Handle network failures when updating tx statuses
NunoAlexandre Jan 11, 2021
3aadc81
Make SidebarLayout better responsive
NunoAlexandre Jan 12, 2021
bd1ec2e
Move attestation sub-modals to Modal/Funding/
NunoAlexandre Jan 12, 2021
af40dc3
Move Onboarding sub-modals to Modals/
NunoAlexandre Jan 12, 2021
6ec8e51
Move Funding Pool modals to Modal/Funding/Pool
NunoAlexandre Jan 12, 2021
e80cffe
Move LinkAddress screen to Screen/Funding/
NunoAlexandre Jan 12, 2021
7a512b2
Move outgoing support screens under ui/Screen
NunoAlexandre Jan 12, 2021
186120a
Periodically refresh the pool data
NunoAlexandre Jan 12, 2021
744af5e
Simplify TxButton
NunoAlexandre Jan 12, 2021
24d1ea6
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Jan 13, 2021
edc0ad5
Fix Transaction Center z-index placement
NunoAlexandre Jan 13, 2021
84170c4
Exodus from 'px' to 'rem'
NunoAlexandre Jan 14, 2021
f40a1ac
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Jan 14, 2021
fbb3a47
Use the new notifications api
NunoAlexandre Jan 14, 2021
3e40605
Update FUNDING.md
NunoAlexandre Jan 15, 2021
06fdcf3
Address review round #2 part 1
NunoAlexandre Jan 17, 2021
c672bca
Merge remote-tracking branch 'origin/master' into feat/funding
NunoAlexandre Jan 17, 2021
bb0b4fa
Use BigNumber instead of BigNumberish
NunoAlexandre Jan 17, 2021
a911260
s/erc20/dai
NunoAlexandre Jan 18, 2021
f36ac82
Structure funding-related errors
NunoAlexandre Jan 18, 2021
dbf7eab
Prune docstring
NunoAlexandre Jan 18, 2021
077053b
Move all funding things behind isExperimental
NunoAlexandre Jan 18, 2021
eb50360
Update FUNDING.md
NunoAlexandre Jan 18, 2021
e3d3085
Fix issue with inappropriate scrolling
NunoAlexandre Jan 18, 2021
77b6f62
Delete unecessary tx.wait() calls
NunoAlexandre Jan 18, 2021
bace2c0
Update ui/Screen/Funding/Pool/Outgoing/GetStarted.svelte
NunoAlexandre Jan 20, 2021
d18d4d8
Update radicle-contract dependency
NunoAlexandre Jan 20, 2021
9a3953b
Cap CurrencyDai long line
NunoAlexandre Jan 20, 2021
74150fb
Fix wrong reference
NunoAlexandre Jan 20, 2021
1226e87
Improve wallet error messages
NunoAlexandre Jan 20, 2021
cf3d026
fixup!
NunoAlexandre Jan 20, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions DEVELOPMENT.md
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,9 @@ Here's a list of all scripts that are intended for developer use:
# - monorepo
# - saved preferences

yarn ethereum:start # Setup a local ethereum node to which we deploy
# the Radicle Contracts and set the intial balance
# of a stated local ethereum development account.

### Design System

Expand Down
86 changes: 86 additions & 0 deletions FUNDING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,86 @@
### Overview

Three moving pieces back the Radicle Funding experiences:

- An Ethereum wallet, owned by the user
- A connection between the Radicle Upstream (the app) and said Ethereum wallet
- The Radicle Contracts (Ethereum smart-contracts)

The funding experiences provided in the Radicle Upstream are Ethereum-based,
meaning that actions such as adding users to the list of receivers, collect
incoming support funds, and others, translate into ethereum transactions.

For users to approve those transactions originated in the app, they need to
establish a connection between an Ethereum wallet and the app. We provide this
capability through a WalletConnect integration. A substantial number of Ethereum
wallets support WalletConnect. [You can find the complete list here][wcw].

Once a wallet is connected to the app, the funding experiences become available
to the user. The user can now set up and edit their support, receive funds, etc.
All of these actions translate into transactions the user must review, (i.e.,
approve or reject) on their connected wallet.

These same transactions are provided and ran by the [Radicle Contracts][rc], our
custom Ethereum smart-contracts.


#### Development environment

In the development environment, we set up these three pieces as follows:

- A local WalletConnect test wallet instance

This instance will play the role of a real wallet:
- It provides a couple of test accounts that we use in development.
- The transactions triggered in the app will be prompted here for the user
to approve or reject.

- A local ganache instance

Ganache provides a local Ethereum RPC client for testing and development. The
Radicle Contracts are deployed to this instance. Here, we also set an initial
balance of the account we choose for development purposes.

For piece of mind, note that this instance has no connection to other networks
such as mainnet or testnet. Therefore, no real assets are ever used. Feel free
to play around!

![Radicle Funding Development Set up][dev-setup]

**Getting started**

- Install [walletconnect-test-wallet][wctw]

- `git clone [email protected]:radicle-dev/walletconnect-test-wallet.git`
- `cd walletconnect-test-wallet`
- `npm install`

- Set up the local test ethereum account

- Run `npm run start` within `walletconnect-test-wallet`. It should open the
test wallet in your browser at `localhost:3000`.

- Copy the full Ethereum address provided at the top of the page.

- Now, in `radicle-upstream`, run:

- `yarn install`
- `mkdir sandbox`
- `touch sandbox/.local-eth-account`
- Finally, paste the copied address in the previous step into this file.

**Running**

With everything installed and set up, run the following commands in different
tabs:

- `npm run start` within `walletconnect-test-wallet`
- `yarn ethereum:start` within `radicle-upstream`
`RADICLE_UPSTREAM_EXPERIMENTAL=true yarn start` within `radicle-upstream`
- Once the app is running, enable the funding feature in the Upstream settings


[wcw]:https://walletconnect.org/wallets/
[wctw]:https://github.com/radicle-dev/walletconnect-test-wallet
[rc]:https://github.com/radicle-dev/radicle-contracts
[dev-setup]:./funding-dev-setup.svg "Radicle Funding Development Set up"
1 change: 1 addition & 0 deletions funding-dev-setup.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
13 changes: 12 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,11 @@
},
"main": "./native/main.comp.js",
"devDependencies": {
"@ethersproject/cli": "^5.0.7",
"@rollup/plugin-inject": "^4.0.2",
"@rollup/plugin-json": "^4.1.0",
"@rollup/plugin-commonjs": "^17.0.0",
"@rollup/plugin-node-resolve": "^11.0.1",
"@rollup/plugin-node-resolve": "^10.0.0",
"@rollup/plugin-typescript": "^8.1.0",
"@tsconfig/svelte": "^1.0.10",
"@types/jest": "^26.0.19",
Expand All @@ -88,6 +91,7 @@
"eslint-plugin-no-only-tests": "^2.4.0",
"eslint-plugin-svelte3": "^3.0.0",
"eslint-svelte3-preprocess": "^0.0.4",
"ganache-cli": "^v6.12.0",
"husky": ">=4.3.6",
"jest": "^26.6.3",
"lint-staged": "^10.5.3",
Expand All @@ -113,12 +117,14 @@
"ts-node": "^9.1.1",
"tslib": "^2.0.3",
"typescript": "^4.1.3",
"util": "^0.12.3",
"wait-on": "^5.2.1"
},
"scripts": {
"start": "RADICLE_UPSTREAM_PROXY_PATH=../proxy/target/release/radicle-proxy yarn _private:start",
"start:dev": "RADICLE_UPSTREAM_PROXY_PATH=../proxy/target/debug/radicle-proxy yarn _private:start:dev",
"start:test": "RADICLE_UPSTREAM_PROXY_PATH=../proxy/target/release/radicle-proxy RADICLE_UPSTREAM_PROXY_ARGS=--test yarn _private:start",
"ethereum:start": "./scripts/ethereum-dev-node.sh",
"test": "TZ='UTC' yarn test:unit && TZ='UTC' yarn test:integration",
"test:integration": "TZ='UTC' run-p --race _private:proxy:start:test _private:test:integration",
"test:integration:debug": "TZ='UTC' run-p --race _private:rollup:watch _private:proxy:start:test:watch _private:test:integration:debug",
Expand Down Expand Up @@ -150,9 +156,14 @@
},
"dependencies": {
"@types/qs": "^6.9.5",
"@walletconnect/client": "^1.3.1",
"browserify": "^17.0.0",
"ethers": "^5.0.23",
"marked": "^1.2.7",
"mnemonist": "^0.38.1",
"pure-svg-code": "^1.0.6",
"radicle-contracts": "git+https://github.com/radicle-dev/radicle-contracts.git#5dd3138d8a731cff59835961deb7295b89520608",
"svelte-persistent-store": "^0.1.5",
"rollup-plugin-css-only": "^3.1.0",
"timeago.js": "^4.0.2",
"twemoji": "13.0.1",
Expand Down
14 changes: 14 additions & 0 deletions proxy/api/src/session/settings.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ pub struct Settings {
pub appearance: Appearance,
/// User-determined p2p parameters.
pub coco: CoCo,
#[serde(default)]
pub feature_flags: FeatureFlags,
}

/// Knobs for the look and feel.
Expand Down Expand Up @@ -70,3 +72,15 @@ impl Default for CoCo {
}
}
}

#[derive(Debug, Clone, Deserialize, Serialize, PartialEq)]
pub struct FeatureFlags {
/// Whether the funding feature is enabled or disabled.
pub funding: bool,
}

impl Default for FeatureFlags {
fn default() -> Self {
Self { funding: false }
}
}
46 changes: 46 additions & 0 deletions rollup.app.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
import commonjs from "@rollup/plugin-commonjs";
import livereload from "rollup-plugin-livereload";
import resolve from "@rollup/plugin-node-resolve";
import inject from "@rollup/plugin-inject";
import json from "@rollup/plugin-json";
import * as browserifyNodeBuiltins from "browserify/lib/builtins";
import svelte from "rollup-plugin-svelte";
import { terser } from "rollup-plugin-terser";
import typescript from "@rollup/plugin-typescript";
Expand All @@ -18,6 +21,7 @@ export default {
file: "public/bundle.js",
},
plugins: [
json(),
svelte({
compilerOptions: {
// enable run-time checks when not in production
Expand All @@ -30,12 +34,34 @@ export default {

resolve({
browser: true,
preferBuiltins: true,
dedupe: importee =>
importee === "svelte" || importee.startsWith("svelte/"),
}),

commonjs(),

inject({
modules: {
process: "_process",
Buffer: ["buffer", "Buffer"],
},
}),

{
name: "node-builtins",
resolveId(importee) {
if (importee === "util") {
// We need a more recent version than browserify provides
return { id: require.resolve("util/util.js") };
}
const builtinPath = browserifyNodeBuiltins[importee];
if (builtinPath) {
return { id: builtinPath };
}
},
},

typescript({
// See https://github.com/rollup/plugins/issues/272
noEmitOnError: production,
Expand All @@ -52,4 +78,24 @@ export default {
watch: {
clearScreen: false,
},

// Skip certain warnings originated by third-party libraries
onwarn: function (warning) {
if (
warning.code === "THIS_IS_UNDEFINED" &&
warning.id.includes("node_modules/@ethersproject/")
) {
return;
}

if (
warning.code === "CIRCULAR_DEPENDENCY" &&
warning.importer.includes("node_modules/readable-stream/")
) {
return;
}

// // Pass on any other warnings
console.warn(warning.message);
},
};
42 changes: 42 additions & 0 deletions scripts/deploy-dev-contracts.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
#!/usr/bin/env node

const { deployAll } = require("radicle-contracts");
const ethers = require("ethers");
const fs = require("fs");

main().catch(e => {
console.error(e);
process.exit(1);
});

async function main() {
const provider = new ethers.providers.JsonRpcProvider(
"http://localhost:8545"
);
const signer = provider.getSigner(0);
const txCount = await signer.getTransactionCount();
if (txCount !== 0) {
throw new Error(
"Deployer account has non-zero transaction count. You need to reset your chain"
);
}

console.log("\n### Deploying the Radicle Contracts...\n");
const contracts = await deployAll(signer);
console.log(`Rad token deployed at ${contracts.rad.address.toLowerCase()}`);
console.log(`ENS deployed at ${contracts.ens.address.toLowerCase()}`);
console.log(
`Eth Pool deployed at ${contracts.ethPool.address.toLowerCase()}`
);
console.log(
`Erc20 Pool deployed at ${contracts.erc20Pool.address.toLowerCase()}`
);
console.log("Done.\n");

const devEthAccount = fs
.readFileSync("sandbox/.local-eth-account", "utf-8")
.trim();

// Set the initial balance of the used erc20 token for the development account.
await (await contracts.rad.transfer(devEthAccount, 98765)).wait();
}
30 changes: 30 additions & 0 deletions scripts/ethereum-dev-node.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
#!/usr/bin/env bash
#
# Run a local ethereum node and deploy the latest contracts to it.
#

set -eumo pipefail

node_modules/.bin/ganache-cli \
--mnemonic "image napkin cruise dentist name plunge crisp muscle nest floor vessel blush" \
--defaultBalanceEther 1000 \
"$@" &

function stop_ganache() {
kill %1 2>/dev/null || true
fg %1 2>/dev/null || true
}

trap stop_ganache SIGINT EXIT SIGTERM

sleep 4

echo "Deploying the Radicle Dev Contracts..."
./scripts/deploy-dev-contracts.js;
echo "Done"

echo "Adding funds to your account..."
ethers --rpc http://localhost:8545 --account-rpc 0 --yes send $(< ./sandbox/.local-eth-account) 10
echo "Done"

fg %1
25 changes: 25 additions & 0 deletions ui/App.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
import Router, { push, location } from "svelte-spa-router";

import * as hotkeys from "./src/hotkeys.ts";
import { isExperimental } from "./src/ipc";
import "./src/localPeer.ts";
import * as path from "./src/path.ts";
import * as remote from "./src/remote.ts";
Expand All @@ -18,6 +19,8 @@
import Hotkeys from "./Hotkeys.svelte";
import Theme from "./Theme.svelte";

import TransactionCenter from "./App/TransactionCenter.svelte";

import Blank from "./Screen/Blank.svelte";
import Bsod from "./Screen/Bsod.svelte";
import Onboarding from "./Screen/Onboarding.svelte";
Expand All @@ -27,10 +30,17 @@
import ModalNewProject from "./Modal/NewProject.svelte";
import ModalSearch from "./Modal/Search.svelte";
import ModalShortcuts from "./Modal/Shortcuts.svelte";
import ModalTransaction from "./Modal/Transaction.svelte";
import NotFound from "./Screen/NotFound.svelte";
import Profile from "./Screen/Profile.svelte";
import Project from "./Screen/Project.svelte";
import Settings from "./Screen/Settings.svelte";
import ModalLinkAddress from "./Modal/Funding/LinkAddress.svelte";
import ModalPoolOnboarding from "./Modal/Funding/Onboarding.svelte";
import ModalWalletQRCode from "./Modal/Wallet/QRCode.svelte";
import ModalTopUp from "./Modal/Funding/Pool/TopUp.svelte";
import ModalWithdraw from "./Modal/Funding/Pool/Withdraw.svelte";
import ModalCollect from "./Modal/Funding/Pool/Collect.svelte";
import UserProfile from "./Screen/UserProfile.svelte";

const routes = {
Expand All @@ -52,6 +62,13 @@
"/new-project": ModalNewProject,
"/search": ModalSearch,
"/shortcuts": ModalShortcuts,
"/wallet/qrcode": ModalWalletQRCode,
"/funding/link": ModalLinkAddress,
"/funding/pool/onboarding": ModalPoolOnboarding,
"/funding/pool/collect": ModalCollect,
"/funding/pool/withdraw": ModalWithdraw,
"/funding/pool/top-up": ModalTopUp,
"/transaction": ModalTransaction,
};

$: switch ($store.status) {
Expand Down Expand Up @@ -82,6 +99,10 @@
error.show($store.error);
break;
}

$: sessionIsUnsealed =
$store.status === remote.Status.Success &&
$store.data.status === Status.UnsealedSession;
</script>

<style>
Expand All @@ -101,6 +122,10 @@
<NotificationFaucet />
<Theme />

{#if isExperimental() && sessionIsUnsealed && $location !== path.designSystemGuide()}
<TransactionCenter />
{/if}

<Remote {store} context="session" disableErrorLogging={true}>
<Router {routes} />

Expand Down
Loading