-
Notifications
You must be signed in to change notification settings - Fork 29
feat: send tokens rpc #735
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 61 commits
Commits
Show all changes
70 commits
Select commit
Hold shift + click to select a range
d863661
feat: added reown components, packages and modal
andreabadesso db57974
chore: stop using null-loader for pino
andreabadesso ef7e3af
chore: added lavamoat policy for walletconnect deps
andreabadesso f419d6d
chore: updated walletconnect deps
andreabadesso e0d100c
refactor: global reown module
andreabadesso 4fa8a38
chore: better sourcemaps by providing full webpack path
andreabadesso e001ee2
chore: normalize walletconnect packages to include eventClient requir…
andreabadesso ae0e5be
feat: modals implementation
andreabadesso a65f58a
fix: using bigint on txData screen
andreabadesso 3a44194
fix: using bigint on nano contract detail screen
andreabadesso 6152bef
feat: modals implementation
andreabadesso ddb6833
refactor: each modal on its own component
andreabadesso 582c6a0
feat: network changed -> clear reown sessions
andreabadesso 288c0f3
refactor: cosmetic changes to reown
andreabadesso 6d14d1f
refactor: using separate methods for each nc action
andreabadesso 02fe6ea
refactor: removed pointless logs
andreabadesso 1300e43
feat: listen for feature toggle update
andreabadesso 729c707
refactor: added hathor header
andreabadesso 4eb067f
refactor: removed unused helper method
andreabadesso 399585a
chore: added comment explaining serialization check
andreabadesso f9fe19b
fix: added missing action types
andreabadesso 1c55f54
fix: moved reown feature toggle
andreabadesso f862034
refactor: correct docstrings in reown module
andreabadesso 4d8170d
feat: added missing handlers
andreabadesso f961ee3
refactor: removed useless delay
andreabadesso 6b626c6
refactor: improved debug log
andreabadesso a4617c5
chore: fixed walletkit version
andreabadesso 265efae
chore: updated lavamoat policy with new fixed versions
andreabadesso 978e729
refactor: use constants
andreabadesso afa90fe
docs: added a TODO on create token modal
andreabadesso 69004f6
refactor: removed ternary in jsx
andreabadesso 055fa48
refactor: error when modalContext is unavailable
andreabadesso d7146a1
refactor: single selector for multiple states
andreabadesso 13dbe5b
refactor: accept -> acceptCb
andreabadesso abb2fc6
feat: initial implementation of send tokens RPC handling
andreabadesso b810873
feat: added send transaction modal and reown saga
andreabadesso 0416537
feat: better handling of transactions
andreabadesso 80ab921
feat: automatically register unregistered tokens
andreabadesso bebc7f3
chore: removed test rpc lib
andreabadesso 5f9897e
refactor: removed unused console.log
andreabadesso 0677236
feat: data outputs being rendered properly, handling insufficient bal…
andreabadesso c0332a2
feat: CopyButton component
andreabadesso 184bd0f
feat: merge with feat/reown
andreabadesso 0154301
feat: user should be able to pick an address for the caller
andreabadesso 775e78d
chore: updated policy and rpc lib import
andreabadesso 31fb4cd
Merge branch 'feat/reown' into feat/send-tokens-rpc
andreabadesso e92e3a1
Merge branch 'feat/reown' into feat/send-tokens-rpc
andreabadesso db08966
refactor: review changes
andreabadesso 801fd02
refactor: fall-through for send transaction and insufficient funds error
andreabadesso 22ff4b9
refactor: stop requesting HTR token download
andreabadesso af74e59
refactor: using copy button component
andreabadesso a7c5cf8
refactor: use isNFT util
andreabadesso 2573601
refactor: actually request token metadata
andreabadesso 81857b0
refactor: stop defaulting to HTR
andreabadesso d88a0ee
feat: accept keyboard input
andreabadesso 005cb4d
feat: prevent dismissal of modal by clicking outside
andreabadesso 21d712a
refactor: stop converting to bigint explicitly in NanoContractActions
andreabadesso 5345ac1
fix: wait for wallet to be ready and actually continue with the request
andreabadesso 017bce7
refactor: stop importing constants directly from the constants file
andreabadesso 332f310
Merge branch 'feat/reown' into feat/send-tokens-rpc
andreabadesso ee08b7b
refactor: Failure -> Failed
andreabadesso 77661c3
Merge branch 'feat/reown' into feat/send-tokens-rpc
andreabadesso 3ac1629
refactor: data is no longer an array
andreabadesso 2552dda
refactor: passing correct props to SendTransactionModal
andreabadesso 3971f79
refactor: stop using question mark as fallback
andreabadesso fab75c6
refactor: using the generic FeedbackModal in TransactionFeedbackModal
andreabadesso 975d99f
refactor: use decimalPlaces in SendTransactionModal
andreabadesso 2234f9d
refactor: using JSONBigInt for stringifying create token data
andreabadesso 8b73e24
fix: stop crashing when invalid arguments are received (#756)
andreabadesso fc59efc
chore: using @hathor/hathor-rpc-handler
andreabadesso File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
/** | ||
* Copyright (c) Hathor Labs and its affiliates. | ||
* | ||
* This source code is licensed under the MIT license found in the | ||
* LICENSE file in the root directory of this source tree. | ||
*/ | ||
|
||
import React from 'react'; | ||
|
||
/** | ||
* A reusable button component that copies text to clipboard | ||
* @param {Object} props Component props | ||
* @param {string} props.text Text to be copied | ||
* @param {string} [props.className] Additional CSS classes | ||
*/ | ||
export const CopyButton = ({ text, className = '' }) => { | ||
if (!text) return null; | ||
|
||
return ( | ||
<button | ||
className={`btn btn-link btn-sm p-0 ml-2 ${className}`} | ||
onClick={() => navigator.clipboard.writeText(text)} | ||
> | ||
<i className="fa fa-copy"></i> | ||
</button> | ||
); | ||
}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this relative path right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's not, I will change this as soon as the rpc-lib is published