Automatically open Studio Survey sidetab upon collection creation
This commit is contained in:
parent
7b18cffe87
commit
44871ab685
@ -81,6 +81,7 @@ const CollectionCreationPage: NextPage = () => {
|
|||||||
baseFactory: baseFactoryContract,
|
baseFactory: baseFactoryContract,
|
||||||
} = useContracts()
|
} = useContracts()
|
||||||
const scrollRef = useRef<HTMLDivElement>(null)
|
const scrollRef = useRef<HTMLDivElement>(null)
|
||||||
|
const sidetabRef = useRef<any>(null)
|
||||||
|
|
||||||
const vendingFactoryMessages = useMemo(
|
const vendingFactoryMessages = useMemo(
|
||||||
() => vendingFactoryContract?.use(VENDING_FACTORY_ADDRESS),
|
() => vendingFactoryContract?.use(VENDING_FACTORY_ADDRESS),
|
||||||
@ -1107,8 +1108,11 @@ const CollectionCreationPage: NextPage = () => {
|
|||||||
vendingMinterContractAddress !== null ||
|
vendingMinterContractAddress !== null ||
|
||||||
openEditionMinterDetails?.openEditionMinterContractAddress ||
|
openEditionMinterDetails?.openEditionMinterContractAddress ||
|
||||||
isMintingComplete
|
isMintingComplete
|
||||||
)
|
) {
|
||||||
scrollRef.current?.scrollIntoView({ behavior: 'smooth' })
|
scrollRef.current?.scrollIntoView({ behavior: 'smooth' })
|
||||||
|
// eslint-disable-next-line @typescript-eslint/no-unsafe-call
|
||||||
|
if (sidetabRef.current) sidetabRef.current.open()
|
||||||
|
}
|
||||||
}, [vendingMinterContractAddress, openEditionMinterDetails?.openEditionMinterContractAddress, isMintingComplete])
|
}, [vendingMinterContractAddress, openEditionMinterDetails?.openEditionMinterContractAddress, isMintingComplete])
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
@ -1600,7 +1604,14 @@ const CollectionCreationPage: NextPage = () => {
|
|||||||
Mint & Add Token(s)
|
Mint & Add Token(s)
|
||||||
</Button>
|
</Button>
|
||||||
</Conditional>
|
</Conditional>
|
||||||
<Sidetab buttonColor="#455CF9" buttonText="Studio Survey" height={600} id="yJnL8fXk" width={800} />
|
<Sidetab
|
||||||
|
buttonColor="#455CF9"
|
||||||
|
buttonText="Studio Survey"
|
||||||
|
height={600}
|
||||||
|
id="yJnL8fXk"
|
||||||
|
ref={sidetabRef}
|
||||||
|
width={800}
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
Loading…
Reference in New Issue
Block a user