Merge pull request #239 from public-awesome/inifinity-swap-update
Update Collection Actions > Infinity Swap UI
This commit is contained in:
commit
d62873a2db
@ -181,7 +181,9 @@ export const CollectionActions = ({
|
|||||||
type !== 'update_royalties_for_infinity_swap'
|
type !== 'update_royalties_for_infinity_swap'
|
||||||
? 'Percentage of royalties to be paid'
|
? 'Percentage of royalties to be paid'
|
||||||
: 'Change in share percentage',
|
: 'Change in share percentage',
|
||||||
placeholder: '5%',
|
placeholder: isEitherType(type, ['set_royalties_for_infinity_swap', 'update_royalties_for_infinity_swap'])
|
||||||
|
? '0.5%'
|
||||||
|
: '5%',
|
||||||
})
|
})
|
||||||
|
|
||||||
const showTokenUriField = isEitherType(type, ['mint_token_uri', 'update_token_metadata'])
|
const showTokenUriField = isEitherType(type, ['mint_token_uri', 'update_token_metadata'])
|
||||||
@ -310,6 +312,13 @@ export const CollectionActions = ({
|
|||||||
royaltyShareState.value,
|
royaltyShareState.value,
|
||||||
])
|
])
|
||||||
|
|
||||||
|
useEffect(() => {
|
||||||
|
if (isEitherType(type, ['set_royalties_for_infinity_swap']) && Number(royaltyShareState.value) > 5) {
|
||||||
|
royaltyShareState.onChange('5')
|
||||||
|
toast.error('Royalty share cannot be greater than 5% for Infinity Swap')
|
||||||
|
}
|
||||||
|
}, [royaltyShareState.value])
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
const addresses: string[] = []
|
const addresses: string[] = []
|
||||||
airdropAllocationArray.forEach((allocation) => {
|
airdropAllocationArray.forEach((allocation) => {
|
||||||
|
@ -226,7 +226,7 @@ export const CollectionDetails = ({
|
|||||||
<FormControl
|
<FormControl
|
||||||
className={clsx('mt-2')}
|
className={clsx('mt-2')}
|
||||||
htmlId="timestamp"
|
htmlId="timestamp"
|
||||||
subtitle="Trading start time offset will be set as 2 weeks by default."
|
subtitle="Trading start time offset will be set as 1 week by default."
|
||||||
title={`Trading Start Time (optional | ${timezone === 'Local' ? 'local)' : 'UTC)'}`}
|
title={`Trading Start Time (optional | ${timezone === 'Local' ? 'local)' : 'UTC)'}`}
|
||||||
>
|
>
|
||||||
<InputDateTime
|
<InputDateTime
|
||||||
|
Loading…
Reference in New Issue
Block a user