619 Commits

Author SHA1 Message Date
Pascal Precht
02dcc106e4 uiux(Contacts): add loading indicator when searching for contacts to add 2020-09-17 15:16:24 -04:00
Pascal Precht
9c1613acf8 uiux(Wallet): improve readability of high value balances
Uses `toLocaleString()` polyfill to insert `.` and/or `,` as
needed based on currently selected locale.

Closes #845
2020-09-17 15:16:16 -04:00
emizzle
7b0d3c496c fix: exception handling in mutli-threaded transactions
Currently, exceptions thrown during transactions or gas estimation that were spawned in another thread are not being propagated, due to a limitation in nim (see https://nim-lang.org/docs/manual_experimental.html#parallel-amp-spawn).

This means any exceptions from status-go were not propagated correctly and would cause the app to crash. This includes entering the wrong password when trying to send a transaction.

The issue was addressed by passing a `success` variable by reference, which is set to false if an exception was thrown by status-go.
2020-09-17 12:21:29 -04:00
Jonathan Rainville
bcbcd13611 refactor: use profileSettingsFile QtProperty instead of profile directly 2020-09-16 16:58:55 -04:00
Jonathan Rainville
db9472bc0b refactor: change settings to use a filename instead 2020-09-16 16:58:55 -04:00
Jonathan Rainville
23ca5f9930 feat: make settings user dependant and clean settings uses 2020-09-16 16:58:55 -04:00
Jonathan Rainville
cebd889fd6 fix: fix assets not updating in views when getting new balance 2020-09-16 16:58:36 -04:00
Richard Ramos
e4ffc897d7 fix: code review + reset sticker pack pending state 2020-09-16 14:22:29 -04:00
Richard Ramos
d0bca7afa6 fix: show stickers as pending while trx is being mined
Fixes #885
2020-09-16 14:22:29 -04:00
Richard Ramos
e46ab433f4 feat: transaction dialog for registering ENS name 2020-09-16 14:22:29 -04:00
Richard Ramos
83b0c8057e fix: code review 2020-09-16 14:22:29 -04:00
Richard Ramos
0091fded3a feat: toast messages for sticker and ens trxs 2020-09-16 14:22:29 -04:00
Jonathan Rainville
17aa8d274e fix: fix defaultTokenList use in QML 2020-09-14 14:54:17 -04:00
Jonathan Rainville
103f02b289 feat: show toast message for transaction status changes 2020-09-14 14:48:26 -04:00
Jonathan Rainville
b0c9155e70 feat: track pending transactions for wallet transfers 2020-09-14 14:48:26 -04:00
Jonathan Rainville
22d9c3be5d refactor: use wallet model instead of lib status 2020-09-11 16:55:36 -04:00
Jonathan Rainville
ad00709104 feat: show loading image on the button when sending 2020-09-11 16:55:36 -04:00
Pascal Precht
361c563a4b fix(Wallet): derive accounts from imported mnemonic and store correctly
This commit address two bugs:

1. When importing a mnemonic, the resulting "master" account and its address
  was used as account to be stored as opposed to its derived default account
2. The account was stored in the wrong path, resulting in status not being able
  to locate accounts when sending transactions.

Fixes #787
2020-09-11 14:41:24 -04:00
emizzle
19e801bba8 fix: remove spaces from sticker hashes
Looks like this may have ended up in the codebase unintentionally.
2020-09-11 14:41:01 -04:00
Iuri Matias
212f33b3c0 filter out watch only accounts in account list for sending transactions 2020-09-11 14:40:31 -04:00
Richard Ramos
f2a56c70e1 fix: rebase gone wrong 2020-09-11 13:25:55 -04:00
Richard Ramos
2f1416e042 feat: check if a transaction is confirmed before installing a sticker pack 2020-09-11 12:46:13 -04:00
emizzle
80f0f9466b refactor: move stickers to own model
Remove from ChatModel and add StickerModel

# Conflicts:
#	src/app/chat/view.nim
#	src/status/chat.nim
#	src/status/libstatus/contracts.nim
2020-09-11 12:46:13 -04:00
emizzle
366fdc15a1 feat: show stickers purchased from non-main account
Fixes: #815

Previously, only stickers purchased from the main status account were shown. Now, stickers purchased from any of the accounts are shown.

Accounts include any accounts returned by `accounts_getAccounts` and are non-chat accounts.
2020-09-11 12:01:08 -04:00
emizzle
2a36bcc762 change dynamicbytes to be more dynamic
![more dynamicer](https://tenor.com/view/more-cowbell-cowbell-snl-reaction-mrw-gif-14076918.gif)
2020-09-11 12:01:08 -04:00
emizzle
2c7dd929ad feat: enable token transactions
Fixes #788.
Fixes #853.
Fixes #856.

refactor: gas estimation and transaction sends have been abstracted to  allow calling `estimateGas`, `send`, and `call` on the contract method (similar to the web3 API).

Moved sticker pack gas estimation and purchase tx over to the new API

*Sticker purchase:*
 - gas estimate is done using new API and debounced using a timer

*Wallet send transaction:*
 - tokens can now be sent
 - gas is estimated correctly for a token tx, and debounced using a timer

***NOTE***
1. If attempting to send tokens on testnet, you must use a custom token as the token addresses in the pre-built list are for mainnet and will not work on testnet.
2. The new API should support all existing gas estimates, send txs, and calls. The loading of sticker pack data, balance, count, purchased sticker packs, etc, can be moved over to the new API. Almost all of the `eth_sendTransaction`, `eth_gasEstimate`, and `eth_call` could be move over as well (that's the idea at least).
2020-09-11 12:01:08 -04:00
emizzle
4f0cdad8c7 refactor: move stickers to own model
Remove from ChatModel and add StickerModel
2020-09-11 12:01:08 -04:00
Pascal Precht
729a2781f0 feat(TransactionModal): introduce async validation for ENS names
This commit extends the AddressInput to perform ENS lookups when valid
ENS values are entered. The lookup happens asynchronously, so we show a loading
indicator as the request is happening.

Closes #790
2020-09-10 13:40:42 -04:00
Richard Ramos
24212a63e9 feat: testnet tokens 2020-09-09 16:35:51 -04:00
Richard Ramos
27abf30fc8 feat: list, toggle and remove custom tokens 2020-09-09 16:10:51 -04:00
Jonathan Rainville
f3f27a5e59 fix: address more comments about the chat commands 2020-09-09 15:03:45 -04:00
Jonathan Rainville
348e0a9bdc fix: address review comments for the send forms 2020-09-09 15:03:45 -04:00
Jonathan Rainville
6b3cac31bc feat: enable sending chat requests 2020-09-09 15:03:45 -04:00
Jonathan Rainville
60492b4db1 feat: add chat command bubbles for received txs 2020-09-09 15:03:45 -04:00
Iuri Matias
aeb8d2958d display first menu option; include channel id 2020-09-09 14:08:19 -04:00
Pascal Precht
4bea011417 uiux(Chat): show loading indicator when fetching more messages 2020-09-08 14:09:09 -04:00
Iuri Matias
f573574d9a fix addresses of some tokens 2020-09-07 16:37:06 -04:00
Richard Ramos
98aaa69e9d fix: transaction history handling
- Determine if the recent transaction history is being fetched or available before obtaining the first 20 transactions
- On account change, reset the selected tab to show the asset list
- Collectibles were kinda pixelated/blurry (not anymore)

Fixes #806
2020-09-07 12:54:59 -04:00
Pascal Precht
1481f2648f feat: introduce "fetch more messages" button to request old messages
Closes #149
2020-09-07 10:20:17 -04:00
hydr063n
3ea3b618a0 change title from Nim Status Client to Status Desktop 2020-09-07 09:30:02 -04:00
Richard Ramos
057cdc08da feat: update balances when receiving a transaction 2020-09-04 17:21:40 -04:00
Richard Ramos
d4e0ef6619 feat: receive wallet events and bump nim-status 2020-09-04 17:21:40 -04:00
Richard Ramos
e52d287cf9 refactor: move signals to status and generate events 2020-09-04 16:42:26 -04:00
Richard Ramos
9ef82a2d7a fix: token decimals and returning no collectibles when there's no contract for a collectible on the current network
Fixes #773
2020-09-04 16:36:20 -04:00
emizzle
d8b0145eb3 feat: Add Sticker purchase transaction modal
Add gas estimate for sticker pack purchase.

Update transaction for sticker pack purchase.

Add GasValidator component which validates gas is selected correctly and displays an error message if not. This component is not visible until it is not valid (at which point the valdiation error message is displayed).

In a future PR, need to:
1. estimate gas for token txfer (sendTransaction) via a normalised method for estimating gas for EthSend
2. move sticker pack purchase to use an EthSend object so gas can be estimated and tx sent
2020-09-04 16:13:33 -04:00
Richard Ramos
374da83cff feat: receive wallet events and bump nim-status 2020-09-04 15:57:29 -04:00
Richard Ramos
0b6643ac2d feat: show SNT by default in the token list, and STT in ropsten
fixes #805
2020-09-03 16:06:20 -04:00
Pascal Precht
addd1d9c3e chore(chat): request mailserver messages since last request
Prior to this commit, the app would request messages from the last
24 hours for all joined channels.
The changes made here ensure that messages since the *last* request
are requested. The last request for each topic/chat is stored in the
nodes mailserver topics.

When no channels are joined, the default is still 24 hours, however,
as soon as a channel is joined, the last request time will be updated
and honored in the next request.
2020-09-03 15:58:49 -04:00
Richard Ramos
782e89508c fix: escape html in messages 2020-09-03 15:47:05 -04:00
emizzle
1e020a203c feat(tx-comps): Send transaction modal
Fixes #669.

Composes all tx components to create a send transaction modal for the wallet.

1. Add a reusable TransactionStackView component that wraps a StackView component to show the screens of the Send Tx modal and handles back/forward/reset functionality.
2. Add a reusable TransactionStackGroup which holds tx components and allows modal header and button text to be defined and handles validation for all child components.
3. Add an isValid property to all tx comps for pristine validation state.
4. Reset all components in modal once modal is closed. This consists of a `resetInternal` function that each component should implement to reinstate its original starting state, and a `reset` function that parent components can use to reinstate the overridden properties.
5. Tx error handling to display either a StatusGo error message in the dialog, or wrong password in the TransactionSigner.
6. Fix ReceiveModal to allow for pre-selected account based on current wallet account.
7. Add focused border colour to Input component.
8. Fix issue with last TransactionStackGroup input not being able to obtain focus.
9. Fix fiatBalance not appearing on initial load on AccountSelector.
10. Fix selected asset updated properly when assets changed in the AssetSelector component.
11. AccountSelector is pre-populated with selected wallet account. Supporting work on the components has been done to suppor this.
12. Changing accounts in the "from account" updates the asset balances in the AssetAndAmountInput component.
13. Move validation from ContactSelector to the Select component.

1. Test sending of tokens. This requires that tokens contracts are setup on testnet. Right now, they are set up for contract addresses on mainnet.
2. Loading state once transaction is sent. Button in modal needs to move to a loading state and the "toast" messages in the wallet need to appear informaing user of tx progress.
3. Need to clarify (and implement?) support of ENS names in the AddressInput. It appears that ENS names could be resolved. This would be a long operation and require some kind of UI loading indication.
4. Wallet balances need to be updated on every block, so for example, sending funds between accounts I should be able to see the balance updated in real time.

1. Sending to a contact currently doesn't work because the ContactSelector component selects the Contact's whipser key, instead of his/her wallet address. May need to figure out how this is done in status-react. As it stands, attempting to send to a contact will crash the app.
2. Sending *from* an imported account does not work, with an error from StatusGo `cannot locate account for address: 0x123...`
2020-09-03 15:32:55 -04:00