-
Notifications
You must be signed in to change notification settings - Fork 14
feat: mobile WalletKit #1296
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
base: main
Are you sure you want to change the base?
feat: mobile WalletKit #1296
Conversation
…saction processes
…mobile-walletkit-usage-documentation
…ent, transaction handling, and WebView integration
…rammar fix/walletkit-documentation-grammar
|
Skipping AI review because this PR is from a fork. A maintainer can start the review by commenting /review in this PR. |
|
@ProudOfZiggy please revert the changes in unrelated pages |
anton-trunov
left a comment
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.
please fix the merge conflicts and revert the unrelated changes
|
Also, each PR should have its corresponding issue: please see our workflow and policies here: #314 |
|
/review |
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.
Thanks for the updates—nice progress. I left several suggestions across ecosystem/ton-connect/walletkit/android and ecosystem/ton-connect/walletkit/ios; please apply the inline suggestions.
| ```kotlin | ||
| wallet.sendTransaction(transaction) | ||
| ``` |
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.
[HIGH] Missing safety callout for sending transactions (Android)
The page sends a transaction (wallet.sendTransaction(transaction)) without a Warning/Caution callout. Funds movement requires an explicit safety notice and safer defaults (testnet first). This omission increases the risk of users sending irreversible mainnet transactions without adequate context.
| ```kotlin | |
| wallet.sendTransaction(transaction) | |
| ``` | |
| <Aside type="danger" title="Funds at risk"> | |
| Approving or sending a transaction on mainnet transfers funds irreversibly. Use testnet during development. | |
| </Aside> |
Please leave a reaction 👍/👎 to this suggestion to improve future reviews for everyone!
| <Aside type="note"> | ||
| Always store mnemonic phrases securely using platform-specific encrypted storage. Never store them in plain text. | ||
| </Aside> |
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.
[HIGH] Missing safety callout for secrets (mnemonics/keys)
This section uses a Note while discussing mnemonics/keys; handling secrets requires a Warning/Danger callout with risk, scope, mitigation, and environment guidance. Lines 36–38 contain the existing Note and are part of the PR diff. Upgrade the callout and include the required content.
Please leave a reaction 👍/👎 to this suggestion to improve future reviews for everyone!
| let jettonAddress = "EQCxE..." | ||
| // Returns balance in nano with decimals count according to Jetton specification | ||
| let balance = try await wallet.jettonBalance(jettonAddress: jettonAddress) | ||
| ``` | ||
|
|
||
| ### Get Jetton wallet address | ||
|
|
||
| ```swift | ||
| let jettonAddress = "EQCxE..." | ||
| let walletAddress = try await wallet.jettonWalletAddress(jettonAddress: jettonAddress) | ||
| ``` | ||
|
|
||
| ## NFTs | ||
|
|
||
| ### Get all NFTs | ||
|
|
||
| ```swift | ||
| let nfts = try await wallet.nfts(limit: TONLimitRequest(limit: 10, offset: 0)) | ||
| ``` | ||
|
|
||
| ### Get specific NFT | ||
|
|
||
| ```swift | ||
| let nftAddress = "EQCA..." | ||
| let nft = wallet.nft(address: nftAddress) | ||
| ``` |
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.
[HIGH] Silently truncated addresses in examples
Examples include truncated addresses like “EQCxE…” without stating truncation or using placeholders. Replace literals with placeholders and define them on first use. Occurrences in this range are part of the PR diff.
Please leave a reaction 👍/👎 to this suggestion to improve future reviews for everyone!
| ```swift | ||
| try await wallet.send(transaction: transaction) | ||
| ``` |
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.
[HIGH] Missing safety callout for sending transactions (iOS)
The page sends a transaction (try await wallet.send(transaction: transaction)) without a Warning/Caution callout. Because sending is irreversible on mainnet, a safety notice and testnet-first defaults are required.
| ```swift | |
| try await wallet.send(transaction: transaction) | |
| ``` | |
| <Aside type="danger" title="Funds at risk"> | |
| Approving or sending a transaction on mainnet transfers funds irreversibly. Use testnet during development. | |
| </Aside> |
Please leave a reaction 👍/👎 to this suggestion to improve future reviews for everyone!
| <Aside type="note"> | ||
| Always store mnemonic phrases securely using platform-specific encrypted storage. Never store them in plain text. | ||
| </Aside> |
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.
[HIGH] Missing safety callout for secrets (mnemonics/keys)
This section uses a Note while handling mnemonics/keys; secrets require a Warning/Danger callout with risk, scope, mitigation, and environment guidance. Lines 36–38 contain the existing Note and are part of the PR diff. Replace with a danger callout and include required content.
Please leave a reaction 👍/👎 to this suggestion to improve future reviews for everyone!
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Closes #1304