File tree 1 file changed +24
-2
lines changed
1 file changed +24
-2
lines changed Original file line number Diff line number Diff line change @@ -44,6 +44,17 @@ export default function MyAssets() {
44
44
}
45
45
}
46
46
47
+ async function gotoEdit ( ) {
48
+ if ( "cid" in router . query ) {
49
+ cid = router . query . cid
50
+ }
51
+ if ( ! cid ) {
52
+ return
53
+ }
54
+ router . push ( `/edit?cid=${ cid } ` )
55
+ }
56
+
57
+
47
58
async function storeNFTtoFilecoin ( ) {
48
59
await window . ethereum . enable ( )
49
60
const provider = new providers . Web3Provider ( window . ethereum )
@@ -195,16 +206,27 @@ export default function MyAssets() {
195
206
{ ! ( "minted" in nft ) && nft . authors [ 0 ] . wallet . eth == myethAccount && (
196
207
< button
197
208
onClick = { createMint }
198
- className = "font-bold mt-4 bg-pink -500 text-white rounded p-4 shadow-lg"
209
+ className = "font-bold mt-4 bg-blue -500 text-white rounded p-4 shadow-lg"
199
210
>
200
211
Mint (Will sign 2 times. Be patient...)
201
212
</ button >
202
213
) }
203
214
< br />
215
+
216
+ { nft . authors [ 0 ] . wallet . eth == myethAccount && (
217
+ < button
218
+ onClick = { gotoEdit }
219
+ className = "font-bold mt-4 bg-blue-500 text-white rounded p-4 shadow-lg"
220
+ >
221
+ Edit
222
+ </ button >
223
+ ) }
224
+ < br />
225
+
204
226
{ nft . authors [ 0 ] . wallet . eth == myethAccount && (
205
227
< button
206
228
onClick = { storeNFTtoFilecoin }
207
- className = "font-bold mt-4 bg-pink -500 text-white rounded p-4 shadow-lg"
229
+ className = "font-bold mt-4 bg-blue -500 text-white rounded p-4 shadow-lg"
208
230
>
209
231
Store NFT on the Filecoin network(optional)
210
232
</ button >
You can’t perform that action at this time.
0 commit comments