Commit c0d92d89 authored by tom's avatar tom

review fixes

parent 52b25e6a
...@@ -48,6 +48,10 @@ const oldUrls = [ ...@@ -48,6 +48,10 @@ const oldUrls = [
source: '/account/custom_abi/new', source: '/account/custom_abi/new',
destination: '/account/custom-abi', destination: '/account/custom-abi',
}, },
{
source: '/account/public-tags-request',
destination: '/public-tags/submit',
},
// TRANSACTIONS // TRANSACTIONS
{ {
......
...@@ -51,7 +51,7 @@ const PublicTagsSubmitForm = ({ config, userInfo, onSubmitResult }: Props) => { ...@@ -51,7 +51,7 @@ const PublicTagsSubmitForm = ({ config, userInfo, onSubmitResult }: Props) => {
) { ) {
router.replace({ pathname: '/public-tags/submit' }, undefined, { shallow: true }); router.replace({ pathname: '/public-tags/submit' }, undefined, { shallow: true });
} }
}, [ router.query.addresses, router ]); }, [ router ]);
const onFormSubmit: SubmitHandler<FormFields> = React.useCallback(async(data) => { const onFormSubmit: SubmitHandler<FormFields> = React.useCallback(async(data) => {
const requestsBody = convertFormDataToRequestsBody(data); const requestsBody = convertFormDataToRequestsBody(data);
......
...@@ -52,7 +52,7 @@ const PublicTagsSubmitFieldAddresses = () => { ...@@ -52,7 +52,7 @@ const PublicTagsSubmitFieldAddresses = () => {
</FormControl> </FormControl>
</GridItem> </GridItem>
<GridItem display="flex" alignItems="center" columnGap={ 5 } justifyContent={{ base: 'flex-end', lg: 'flex-start' }}> <GridItem display="flex" alignItems="center" columnGap={ 5 } justifyContent={{ base: 'flex-end', lg: 'flex-start' }}>
{ fields.length < LIMIT && !(fields.length > 1 && index === 0) && ( { fields.length < LIMIT && index === fields.length - 1 && (
<IconButton <IconButton
aria-label="add" aria-label="add"
data-index={ index } data-index={ index }
......
...@@ -50,7 +50,7 @@ const PublicTagsSubmitFieldTags = ({ tagTypes }: Props) => { ...@@ -50,7 +50,7 @@ const PublicTagsSubmitFieldTags = ({ tagTypes }: Props) => {
register={ register } register={ register }
errors={ errors } errors={ errors }
isDisabled={ isDisabled } isDisabled={ isDisabled }
onAddClick={ fields.length < LIMIT && !(fields.length > 1 && index === 0) ? handleAddFieldClick : undefined } onAddClick={ fields.length < LIMIT && index === fields.length - 1 ? handleAddFieldClick : undefined }
onRemoveClick={ fields.length > 1 ? handleRemoveFieldClick : undefined } onRemoveClick={ fields.length > 1 ? handleRemoveFieldClick : undefined }
/> />
); );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment