Merge pull request #155 from public-awesome/release/v1.x-develop
Sync v1_development > v1_main
This commit is contained in:
commit
c5dbc5c855
1
env.d.ts
vendored
1
env.d.ts
vendored
@ -17,6 +17,7 @@ declare namespace NodeJS {
|
||||
readonly NEXT_PUBLIC_SG721_CODE_ID: string
|
||||
readonly NEXT_PUBLIC_MINTER_CODE_ID: string
|
||||
readonly NEXT_PUBLIC_WHITELIST_CODE_ID: string
|
||||
readonly NEXT_PUBLIC_SG721_UPDATABLE_V1_CODE_ID: string
|
||||
|
||||
readonly NEXT_PUBLIC_PINATA_ENDPOINT_URL: string
|
||||
readonly NEXT_PUBLIC_API_URL: string
|
||||
|
||||
@ -1,4 +1,7 @@
|
||||
import { Alert } from 'components/Alert'
|
||||
import { Anchor } from 'components/Anchor'
|
||||
import { Button } from 'components/Button'
|
||||
import { Conditional } from 'components/Conditional'
|
||||
import { ContractPageHeader } from 'components/ContractPageHeader'
|
||||
import { useExecuteComboboxState } from 'components/contracts/sg721/ExecuteCombobox.hooks'
|
||||
import { FormControl } from 'components/FormControl'
|
||||
@ -19,6 +22,7 @@ import { useEffect, useState } from 'react'
|
||||
import { toast } from 'react-hot-toast'
|
||||
import { FaArrowRight } from 'react-icons/fa'
|
||||
import { useMutation } from 'react-query'
|
||||
import { SG721_UPDATABLE_V1_CODE_ID } from 'utils/constants'
|
||||
import { withMetadata } from 'utils/layout'
|
||||
import { links } from 'utils/links'
|
||||
|
||||
@ -36,6 +40,7 @@ const Sg721MigratePage: NextPage = () => {
|
||||
title: 'Code ID',
|
||||
subtitle: 'Code ID of the New Sg721 contract',
|
||||
placeholder: '1',
|
||||
defaultValue: SG721_UPDATABLE_V1_CODE_ID,
|
||||
})
|
||||
|
||||
const contractState = useInputState({
|
||||
@ -102,6 +107,23 @@ const Sg721MigratePage: NextPage = () => {
|
||||
<div className="space-y-8">
|
||||
<AddressInput {...contractState} />
|
||||
<NumberInput isRequired {...codeIdState} />
|
||||
<Conditional test={SG721_UPDATABLE_V1_CODE_ID > 0}>
|
||||
<Alert type="info">
|
||||
<div className="inline-block">
|
||||
Migrating a v1 contract to Code ID: {SG721_UPDATABLE_V1_CODE_ID} (sg721-updatable) will allow the
|
||||
creator to update the royalty details and token metadata. Once the migration is complete, new
|
||||
functionalities can be performed using{' '}
|
||||
<Anchor
|
||||
className="font-bold text-plumbus hover:underline"
|
||||
external
|
||||
href={`/collections/actions/?sg721ContractAddress=${contractState.value}`}
|
||||
>
|
||||
Collection Actions
|
||||
</Anchor>
|
||||
.
|
||||
</div>
|
||||
</Alert>
|
||||
</Conditional>
|
||||
</div>
|
||||
<div className="space-y-8">
|
||||
<div className="relative">
|
||||
|
||||
@ -1,6 +1,7 @@
|
||||
export const SG721_CODE_ID = parseInt(process.env.NEXT_PUBLIC_SG721_CODE_ID, 10)
|
||||
export const MINTER_CODE_ID = parseInt(process.env.NEXT_PUBLIC_MINTER_CODE_ID, 10)
|
||||
export const WHITELIST_CODE_ID = parseInt(process.env.NEXT_PUBLIC_WHITELIST_CODE_ID, 10)
|
||||
export const SG721_UPDATABLE_V1_CODE_ID = parseInt(process.env.NEXT_PUBLIC_SG721_UPDATABLE_V1_CODE_ID, 10)
|
||||
|
||||
export const PINATA_ENDPOINT_URL = process.env.NEXT_PUBLIC_PINATA_ENDPOINT_URL
|
||||
export const NETWORK = process.env.NEXT_PUBLIC_NETWORK
|
||||
|
||||
Loading…
Reference in New Issue
Block a user