Magickbase / neuron-public-issues

Neuron Issues
6 stars 3 forks source link

Preprocess a raw transaction so it can be signed by Neuron #314

Open Keith-CY opened 10 months ago

Keith-CY commented 10 months ago

This issue comes from signing a transaction to upgrade a contract.


The transaction to sign is constructed by contract developer or dapp maintainer, and it's usually a raw transaction that follows data structure of https://github.com/nervosnetwork/ckb/tree/develop/rpc#type-transaction

Here is an example raw-tx.json

But transaction to sign by Neuron requires extra information because Neuron may be running offline.

Here is an example tx-to-sign.json

I've used the following script to transform the raw-tx into tx-to-sign

export-tx-to-sign.js.zip

It would be greatly helpful if transform could be done on Neuron Project Page

Danie0918 commented 2 months ago

preprocess_a_raw_transaction_so_it_can_be_signed_by_neuron

Kirl70 commented 2 months ago

Design Draft(2-13--2-14): https://www.figma.com/design/6XNoimRDbFTTNm016rbIdU/Magickbase?node-id=40199-56347&t=jSrokM1gUEZPpNxZ-1

image
Keith-CY commented 2 months ago

Design Draft(2-13--2-14): figma.com/design/6XNoimRDbFTTNm016rbIdU/Magickbase?node-id=40199-56347&t=jSrokM1gUEZPpNxZ-1 image

Please enter the raw transaction data or drag in the raw transaction json file

Is it allowed for users to upload json file by clicking upload button? Generally, click to upload and drag in to upload appear together. @Danie0918

Danie0918 commented 2 months ago

Design Draft(2-13--2-14): figma.com/design/6XNoimRDbFTTNm016rbIdU/Magickbase?node-id=40199-56347&t=jSrokM1gUEZPpNxZ-1 image

Please enter the raw transaction data or drag in the raw transaction json file

Is it allowed for users to upload json file by clicking upload button? Generally, click to upload and drag in to upload appear together. @Danie0918

Yes, click to upload is also supported, I'll adjust the text here.

yanguoyu commented 1 month ago

https://github.com/Magickbase/websites/pull/125