#sidechain

By Benjamin Fuentes

https://hackmd-prod-images.s3-ap-northeast-1.amazonaws.com/uploads/upload_78e0171bdd78adf94693bec42fbf92e8.png?AWSAccessKeyId=AKIA3XSAAW6AWSKNINWO&Expires=1664876481&Signature=UTrAUValSpUQ0yFNMEFlgh0%2BXos%3D

We delivered a first version of TzPortal bridge to allow to play with Deku Layer 2 recently (August 2, 2022).

With the new Deku delivery, we have simplified overall UX :

  • General flow has less steps for end user (ex : no more manual copy/paste on intermediary proofs)
  • Connect L1 and L2 wallet at same time
  • TzPortal treasury is processing pending deposits and withdrawals under the hood for Financial Asset tickets
  • Better display on mobile & desktop
  • Better ergonomy
  • Reactive animation on balance changes
  • Add support to Ghostnet
https://hackmd-prod-images.s3-ap-northeast-1.amazonaws.com/uploads/upload_ffed71a772d3417b5d35fc3aeb33ff4d.png?AWSAccessKeyId=AKIA3XSAAW6AWSKNINWO&Expires=1664876957&Signature=jaf%2BEhoCvpDXG2WKoYum74KWx10%3D

Instances

Login

You are able to connect to L1 and L2 wallet at same time. Some actions will require to have some wallets connected at minimum

Actions L1 required L2 required
Deposit yes yes
Withdraw yes yes
L2 transfer no yes
L1 claim yes yes

Wallets :

  • L1 wallet : It uses Beacon SDK on Tezos
  • L2 Deku wallet : It requires a Deku wallet file like this one of alice user :
json
{ "priv_key": "edsk3QoqBuvdamxouPhin7swCvkQNgq4jP5KZPbwWNnwdZpSpJiEbq" ,
"address" : "tz1VSUr8wwNhLAzempoch5d6hLRiTh8Cjcjb" }

Note : we aim wallet providers to support natively Deku L2 wallets on near future

Deposit

https://hackmd-prod-images.s3-ap-northeast-1.amazonaws.com/uploads/upload_dec8d0aba36e3575e645e1351981900e.png?AWSAccessKeyId=AKIA3XSAAW6AWSKNINWO&Expires=1664877855&Signature=9YOSobn2aw37D3WOSX7S8OZpYuE%3D

Enter an amount to swap against tickets among listed tokens

https://hackmd-prod-images.s3-ap-northeast-1.amazonaws.com/uploads/upload_6cd521dda7f7fb47409f38a716d9dfde.png?AWSAccessKeyId=AKIA3XSAAW6AWSKNINWO&Expires=1664877888&Signature=H7psE6i5pAHg%2Fo%2BFiDT6OzygRlI%3D

The contract will block the funds and issue the corresponding tickets to the address in Deku

It takes some blocks (~30s) for your balances to be refreshed (with an animation)

L2 transfer

Once you have some tickets on L2, you can send some to any other L2 address on L2 Transfer tab

https://hackmd-prod-images.s3-ap-northeast-1.amazonaws.com/uploads/upload_e58f6ee00854c1894240b19d41c0895c.png?AWSAccessKeyId=AKIA3XSAAW6AWSKNINWO&Expires=1664878089&Signature=%2FSsKl7BoL0ubn9HTVQ3vC6sOCRs%3D

TzPortal is refreshing view when new blocks are coming. Again it can take 1 or 2 blocks time

https://hackmd-prod-images.s3-ap-northeast-1.amazonaws.com/uploads/upload_30815152440c360c9cd060ea87ab0d6e.png?AWSAccessKeyId=AKIA3XSAAW6AWSKNINWO&Expires=1664878097&Signature=GpwPiNTmEcCmGV9%2BrccDF%2B1Z3MA%3D

Withdraw

Go to withdraw panel and ask for some tickets back on L1

https://hackmd-prod-images.s3-ap-northeast-1.amazonaws.com/uploads/upload_1145e9e783d8ef799785b697e0b8c77c.png?AWSAccessKeyId=AKIA3XSAAW6AWSKNINWO&Expires=1664878208&Signature=yL3KhKn5uTsPlpzhCgYNyJfkZBE%3D

Do not forget to get your receipt and save it somewhere because it is the proof you are going to give for the L1 claim

Note : for the moment the front-end app is not able to keep it for you

https://hackmd-prod-images.s3-ap-northeast-1.amazonaws.com/uploads/upload_bf19f11469ca4ca89298e73276f28f22.png?AWSAccessKeyId=AKIA3XSAAW6AWSKNINWO&Expires=1664878265&Signature=za5kmaV3dPRY3gQ%2FdRtTzg%2BefLg%3D

L1 Claim

Go to the L1 Claim page and paste the previous proof

https://hackmd-prod-images.s3-ap-northeast-1.amazonaws.com/uploads/upload_c21c64485109ed714c1b9f83575f8044.png?AWSAccessKeyId=AKIA3XSAAW6AWSKNINWO&Expires=1664878310&Signature=RA8W9whPGnq%2FUvgpLfFuS%2BOmpj4%3D

Wait until Deku will burn your tickets and TzPortal will give you back your collateral

Conclusion

This second version of TzPortal has greatly improved UX.
We are working on making UX as smooth as possible to the end user.

Tickets will be everywhere now. It is really useful to wrap token from networks to networks

Learn more about tickets (https://www.youtube.com/watch?v=xATY21-_R9c)

Next

Next versions will include :

  • Enhance wallet provider integration for Deku wallet
  • Bring more information on pending operations
  • Automatize claiming proofs (save it on browser session or export to a file)
  • Integrate SCORU Layer 2

If you want to know more about Marigold, please follow us on social media (Twitter, Reddit, Linkedin)!

Scroll to top