-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
i18n to Contract Verification #5591
base: master
Are you sure you want to change the base?
Conversation
✅ Deploy Preview for remixproject ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
@@ -102,7 +103,10 @@ export const ConstructorArguments: React.FC<ConstructorArgumentsProps> = ({ abiE | |||
<div className="d-flex py-1 align-items-center custom-control custom-checkbox"> | |||
<input className="form-check-input custom-control-input" type="checkbox" id="toggleRawInputSwitch" checked={toggleRawInput} onChange={() => setToggleRawInput(!toggleRawInput)} /> | |||
<label className="m-0 form-check-label custom-control-label" style={{ paddingTop: '2px' }} htmlFor="toggleRawInputSwitch"> | |||
Enter raw ABI-encoded constructor arguments | |||
<FormattedMessage |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is the default message needed? See Drafish's comment:
// There may have some un-translated content. Always fill in the gaps with EN JSON.
// No need for a defaultMessage prop when render a FormattedMessage component.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I noted that when going through the docs, but without the defaultMessage, there are console errors for every FormattedMessage block added. I will look into it and see
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ryestew I noted from the error I get when the FormattedMessage tags are created without a defaultMessage prop that it falls back to using the id prop as the default. See this link which is the documentation page of the package we are using react-intl (scroll to the bottom to see code examples). In the examples shown, defaultMessage prop is used to give a fallback. So we might need to update our docs.
This here also shows the fallback behaviour of the libarary react-intl fallback behaviour
fixes #5522