Skip to content
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

Configure Snap Addresses UI #1256

Merged
merged 6 commits into from
Sep 19, 2023
Merged

Conversation

abhishek-01k
Copy link
Collaborator

No description provided.

@github-actions
Copy link

File: src/components/MetamaskSnap/MetamaskSnapConfigureModal.tsx

  1. Line 36: There is an opening { for the getSignature function, but there is no corresponding closing }. Please add the closing } for this function.

  2. Line 39: Change mode == 1 to mode === 1 for a strict equality check.

  3. Line 43: Add const signer = provider.getSigner(account); before const signature = await signer.signMessage(Add address ${account} to receive notifications via Push Snap in MetaMask); to declare the signer variable.

  4. Line 49: Add const signer = provider.getSigner(account); before const signature = await signer.signMessage(Remove address ${account}to stop receive notifications via Push Snap in MetaMask); to declare the signer variable.

  5. Line 67: Add a closing } for the addWalletAddresses function.

  6. Line 68: Remove the unnecessary console.log('searchedUser', searchedUser); statement.

  7. Line 77: Remove the unnecessary console.log('Added', searchedUser); statement.

  8. Line 83: Add a closing } for the else statement.

  9. Line 95: Add a closing } for the handleChange function.

  10. Line 130: Add a closing } for the removeWalletAddresses function.

  11. Line 142: Add a closing } for the getWalletAddresses function.

  12. Line 171: Add a closing } for the MetamaskSnapConfigureModal component.

File: src/config/Themization.js

  1. Line 132: Remove the trailing comma after the closing } for the spaceTheme object.

  2. Line 155: Change bgColorPrimary: 'red' to bgColorPrimary: 'red' with a valid color code.

  3. Line 177: Add a closing } for the themeDark object.

@github-actions
Copy link

All looks good.

@github-actions
Copy link

File: src/components/MetamaskSnap/InstallMetamaskSnapModal.tsx

  • The import statement for styled is missing a comma after {useTheme}. It should be: import styled, { useTheme } from 'styled-components';

File: src/components/MetamaskSnap/MetamaskSnapConfigureModal.tsx

  • The file is empty. Please check if there is any content missing.

File: src/components/MetamaskSnap/SnapInformationModal.tsx

  • The import statement for styled is missing a comma after {useTheme}. It should be: import styled, { useTheme } from 'styled-components';
  • There is a missing closing brace '}' after the line if (res) {. Please make sure to close the if statement.

File: src/config/Themization.js

  • There is an unnecessary comma at the end of the pushEmptyButtonText line. Please remove it.
  • There is a missing closing brace '}' at the end of the default object. Please make sure to close the object.

File: src/modules/receiveNotifs/MetamaskPushSnapModal.tsx

  • The import statement for styled is missing a comma after {useTheme}. It should be: import styled, { useTheme } from 'styled-components';
  • The import statement for MetamaskSnapConfigureModal is misspelled. It should be: import MetamaskSnapConfigureModal from 'components/MetamaskSnap/MetamaskSnapConfigureModal';
  • The line where configure is being used as a prop in InstallMetamaskSnapModal has a typo. It should be: {configure} instead of {configure: configure}.

All looks good.

@github-actions
Copy link

All looks good.

@github-actions
Copy link

File: src/App.tsx

  • Line 16: The code imports the dotenv package but it is not being used. You can remove this line.
  • Line 33: The activatingConnector state variable is not being used. You can remove this line.
  • Line 34: The currentTime state variable is not being used. You can remove this line.
  • Line 37: The ErrorContext is being imported but never used. You can remove this line.
  • Line 38: The run, stepIndex, and tutorialContinous variables are being destructured from the state.userJourney object, but the type of state is any. It is recommended to provide the correct type for state instead of using any.
  • Line 44-50: The code is commented out. You can remove these lines.
  • Line 61-66: There is a missing closing brace (}) for the useEffect callback function.
  • Line 69-86: There is a missing closing brace (}) for the useEffect callback function.
  • Line 108: The document.querySelector selector is not specific. It is recommended to use a more specific selector to avoid potential issues with selecting unintended elements.
  • Line 119-121: The incrementStepIndex function is commented out. You can remove these lines.
  • Line 133: The librarySigner variable is not being used. You can remove this line.
  • Line 143: The useSpaceComponents hook is being imported but not used. You can remove this line.
  • Line 157: The closing tag for the <InitState /> component is missing. Add </InitState> before the <NavigationContextProvider> component.
  • Line 181: The hideCloseButton prop is set to false instead of true. Change hideCloseButton={false} to hideCloseButton={true}.
  • Line 194: The headerHeight prop is missing its closing brace (}). Add } after GLOBAL.CONSTANTS.HEADER_HEIGHT.
  • Line 219: The ThemeProvider component is missing its closing tag. Add </ThemeProvider> at the end of the file.

File: src/components/MetamaskSnap/InstallMetamaskSnapModal.tsx

  • Line 20: There is a missing closing parenthesis ()) for the useEffect callback function.
  • Line 27-34: The code is missing closing parentheses for the forEach and request methods.
  • Line 44: The opening tag for the SnapContainer component is missing its closing brace (>). Add > after SnapContainer.

File: src/components/MetamaskSnap/SnapInformationModal.tsx

  • Line 46-53: There is a missing closing parenthesis ()) for the request method call.
  • Line 92: The closing tag for the <InstallButton> component is missing its closing brace (}). Add } after the closing tag.
  • Line 93-100: The closing tags for the <Image>, <SpanV2>, and <Button> components are missing their closing braces (>). Add > after the opening tag for each component.

File: src/config/Themization.js

  • This file is missing and it is not being used. You can remove the import statement for this file where it is being imported in the src/App.tsx file.

File: src/modules/receiveNotifs/MetamaskPushSnapModal.tsx

  • This file is missing and it is not being used. You can remove the import statement for this file where it is being imported in the src/App.tsx file.

File: src/modules/snap/SnapModule.tsx

  • This file is missing and it is not being used. You can remove the import statement for this file where it is being imported in the src/App.tsx file.

Please note that the provided code snippets are incomplete, so some parts may be missing. Remember to check the rest of the code for any other potential issues.

@Arch0125 Arch0125 merged commit ff86a1c into metamask-snap-ui Sep 19, 2023
1 check passed
@github-actions
Copy link

In file src/App.tsx:

  • There is a typo in the variable name setcurrentTime, it should be setCurrentTime.
  • There is a missing opening brace { after the line if (lifecycle === 'ready') {.
  • There is an unused import statement for ReactGA.
  • There is a missing closing parenthesis ) after the line if (snap == 'npm:@pushprotocol/snaps') {.
  • There is an unused variable location, it can be removed.
  • There is a missing closing brace } after the line } else {.
  • There is a missing closing parenthesis ) after the line setSnapState(2).
  • There is an unused variable steps, it can be removed.
  • There is a missing closing brace } before the return statement.

In file src/components/MetamaskSnap/InstallMetamaskSnapModal.tsx:

  • There is a missing closing brace } for the getInstalledSnaps function.
  • There is a missing opening brace { for the configure ? condition.
  • There is a missing closing parenthesis ) after the line InstallButton onClick={() => setSnapState(2)}>.
  • There is an unused import statement for Button.

In file src/components/MetamaskSnap/SnapInformationModal.tsx:

  • There is a missing closing parenthesis ) after the line window.ethereum.request({.
  • There is a missing closing brace } for the installSnap function.
  • There is a missing opening brace { before the return statement.
  • There is an unused import statement for useTheme.
  • There is a missing closing brace } after the line const Container = styled(ItemVV2).
  • There is a missing closing brace } after the line const Image = styled.img.
  • There is a missing closing brace } after the line const PrimaryText = styled.p.
  • There is a missing closing brace } after the line const SecondaryText = styled.p.
  • There is a missing closing parenthesis ) after the line width: 102px;.
  • There is an unused import statement for React.
  • There is an unused import statement for useEffect.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Status: Done and Merged
Development

Successfully merging this pull request may close these issues.

2 participants