Skip to content
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

feat: Teleport DOT between Statemint and Polkadot #7278

Merged
merged 8 commits into from
Sep 24, 2023

Conversation

Jarsen136
Copy link
Contributor

@Jarsen136 Jarsen136 commented Sep 15, 2023

Thank you for your contribution to the KodaDot - One Stop Shop for Polkadot NFTs.

👇 __ Let's make a quick check before the contribution.

PR Type

  • Feature

Needs QA check

  • @kodadot/qa-guild please review

Context

Please note that the Existential Deposit on asset hub is 0.1 dot

Existential Deposit: The amount deposited to the recipient will be net the calculated cross-chain fee. If the recipient address is new, the amount deposited should be greater than the Existential Deposit
ref: https://wiki.polkadot.network/docs/build-protocol-info#existential-deposit

Did your issue had any of the "$" label on it?

Screenshot 📸

  • My fix has changed UI
image

Copilot Summary

🤖 Generated by Copilot at b16850c

This pull request adds support for multiple origin chains for the teleport feature, allowing users to transfer NFTs between Kusama, Polkadot, and Statemint. It refactors the Teleport.vue component and updates the useChain.ts and teleport.ts utils to handle the different chains and currencies. It also modifies the teleport.receiveValue translation string to dynamically display the currency symbol.

🤖 Generated by Copilot at b16850c

We're sailing across the polkadot seas
With teleport we can move our money with ease
We've got KSM, DOT, and STATEMINT too
So pull on the rope and sing out the value

@Jarsen136 Jarsen136 requested a review from a team as a code owner September 15, 2023 16:48
@Jarsen136 Jarsen136 requested review from roiLeo and floyd-li and removed request for a team September 15, 2023 16:48
@netlify
Copy link

netlify bot commented Sep 15, 2023

Deploy Preview for koda-canary ready!

Name Link
🔨 Latest commit dce6583
🔍 Latest deploy log https://app.netlify.com/sites/koda-canary/deploys/650f103dfa5cfd0008cce7d0
😎 Deploy Preview https://deploy-preview-7278--koda-canary.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@kodabot
Copy link
Collaborator

kodabot commented Sep 15, 2023

SUCCESS @Jarsen136 PR for issue #6540 which is assigned to you. Please wait for review and don't hesitate to grab another issue in the meantime!

@reviewpad
Copy link
Contributor

reviewpad bot commented Sep 15, 2023

AI-Generated Summary: This pull request implements the feature of teleporting DOT between Statemint and Polkadot. The main changes involve modifications in the Teleport.vue component and useChain.ts composable. The teleport options now include the Polkadot and Statemint chains. Also, the file locales/en.json has been updated to accept dynamic currency inputs instead of hardcoded 'KSM'. All these changes sum to an addition of 88 lines and removal of 23 lines in 4 files.

@reviewpad reviewpad bot added medium Pull request is medium waiting-for-review labels Sep 15, 2023
@prury
Copy link
Member

prury commented Sep 15, 2023

Wrong decimals on balance:
image
image

i would rename Dot here because we are referring to the chain and not the token:
image

Ahp to Polkadot:
https://assethub-polkadot.subscan.io/tx/0xb570eae0cf0bc384b944d12f34ca37c49eac7ee0e7cd1eb723cc9f017b529e16?tab=xcm_transfer ✔️

Polkadot to Ahp -> https://polkadot.subscan.io/tx/0x8705da52c61178aa20532c4053d443011c977821a5a86dca8ec9237976ba75c0 ✔️

@Jarsen136 lmk if you want to mess with ED, and I'll open an issue. (related: #7213)

@prury prury added the S-changes-requested-🤞 PR is almost good to go, just some fine tunning label Sep 15, 2023
@Jarsen136
Copy link
Contributor Author

Wrong decimals on balance: image image

✅ FIXED

i would rename Dot here because we are referring to the chain and not the token: image

I would wait for #7263 to merge first because they are related, and then I will update its name.

@Jarsen136 lmk if you want to mess with ED, and I'll open an issue. (related: #7213)

It's the same issue as #7213, so it could be solved there instead of creating a new issue.

@prury
Copy link
Member

prury commented Sep 15, 2023

Wrong decimals on balance: image image

✅ FIXED

i would rename Dot here because we are referring to the chain and not the token: image

I would wait for #7263 to merge first because they are related, and then I will update its name.

@Jarsen136 lmk if you want to mess with ED, and I'll open an issue. (related: #7213)

It's the same issue as #7213, so it could be solved there instead of creating a new issue.

okie, ty!

@prury prury added S-works-for-me-✅ qa-guild has tested PR from end user perspective and functionality worked and removed S-changes-requested-🤞 PR is almost good to go, just some fine tunning labels Sep 15, 2023
@Jarsen136
Copy link
Contributor Author

i would rename Dot here because we are referring to the chain and not the token: image

I would wait for #7263 to merge first because they are related, and then I will update its name.

I changed my mind. The naming for Polkdot could be updated here. Thank you for pointing out. @prury

image

Copy link
Contributor

@roiLeo roiLeo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

otherwise code lgtm

components/teleport/Teleport.vue Show resolved Hide resolved
components/teleport/Teleport.vue Show resolved Hide resolved
@exezbcz
Copy link
Member

exezbcz commented Sep 23, 2023

I saw this in one of your pics
image

Otherwise, I think it is time to update teleport as well; there are too many chains for this v1. :D

@Jarsen136
Copy link
Contributor Author

I saw this in one of your pics image

✅ Fixed. It's a compatibility issue that only happens on Firefox.

@codeclimate
Copy link

codeclimate bot commented Sep 23, 2023

Code Climate has analyzed commit dce6583 and detected 2 issues on this pull request.

Here's the issue category breakdown:

Category Count
Duplication 2

View more on Code Climate.

@sonarcloud
Copy link

sonarcloud bot commented Sep 23, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
1.4% 1.4% Duplication

@yangwao yangwao changed the title feat: Teleport DOT between Statemint and Polkdot feat: Teleport DOT between Statemint and Polkadot Sep 24, 2023
@yangwao
Copy link
Member

yangwao commented Sep 24, 2023

pay 30 usd

@yangwao yangwao merged commit ab5a4db into kodadot:main Sep 24, 2023
12 of 14 checks passed
@yangwao
Copy link
Member

yangwao commented Sep 24, 2023

😍 Perfect, I’ve sent the payout
💵 $30 @ 4.04 USD/DOT ~ 7.426 $DOT
🧗 16SjUbGKSdjCdWTy3NNT3JxbRVGGqD4mwkHpc6BD9U2Rp29Z
🔗 0x72f07ad7d422b05ee0341eef5e86dbef85ac8de6a30dbf512932b0ff096e6ea1

🪅 Let’s grab another issue and get rewarded!
🪄 github.com/kodadot/nft-gallery/issues

@yangwao yangwao added the paid pull-request has been paid label Sep 24, 2023
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
medium Pull request is medium paid pull-request has been paid S-works-for-me-✅ qa-guild has tested PR from end user perspective and functionality worked waiting-for-review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Teleport DOT to Statemint
6 participants