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

fix: Hydration error on the NFTs page #2788

Merged
merged 6 commits into from
Nov 12, 2023
Merged
Show file tree
Hide file tree
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions cypress/e2e/smoke/balances.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ describe('Balance tests', () => {
cy.visit(constants.BALANCE_URL + constants.SEPOLIA_TEST_SAFE_5)
main.acceptCookies()
cy.contains('Assets')
balances.selectTokenList(balances.tokenListOptions.default)
cy.get(balances.balanceSingleRow).should('have.length.lessThan', ASSETS_LENGTH)
balances.selectTokenList(balances.tokenListOptions.allTokens)
cy.get(balances.balanceSingleRow).should('have.length', ASSETS_LENGTH)
Expand Down
2 changes: 1 addition & 1 deletion cypress/e2e/smoke/nfts.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const nftsTokenID = 'CF'
describe('NFTs tests', () => {
beforeEach(() => {
cy.clearLocalStorage()
cy.visit(constants.BALANCE_URL + constants.SEPOLIA_TEST_SAFE_5)
cy.visit(constants.balanceNftsUrl + constants.SEPOLIA_TEST_SAFE_5)
main.acceptCookies()
nfts.clickOnNftsTab()
})
Expand Down
84 changes: 84 additions & 0 deletions public/worker-4f62d7a92535e0d2.js.LICENSE.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
/**
* @license
* Copyright 2017 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

/**
* @license
* Copyright 2019 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

/**
* @license
* Copyright 2020 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

/**
* @license
* Copyright 2021 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

/**
* @license
* Copyright 2022 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like this got added accidentally

2 changes: 1 addition & 1 deletion src/components/dashboard/Overview/Overview.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ const Overview = (): ReactElement => {
variant="contained"
color="primary"
startIcon={<AddIcon />}
sx={{ height: 1 }}
sx={{ minHeight: '40px' }}
fullWidth
>
Buy crypto
Expand Down
2 changes: 1 addition & 1 deletion src/components/nfts/NftGrid/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ const NftGrid = ({
onPreview,
}: NftsTableProps): ReactElement => {
const chainId = useChainId()
const linkTemplates = nftPlatforms[chainId]
const linkTemplates = nftPlatforms[chainId] || []
katspaugh marked this conversation as resolved.
Show resolved Hide resolved
// Filter string
const [filter, setFilter] = useState<string>('')

Expand Down
10 changes: 9 additions & 1 deletion src/components/nfts/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,15 @@ export const nftPlatforms: Record<keyof typeof chains, Array<NftPlatform>> = {
{
title: 'OpenSea',
logo: '/images/common/nft-opensea.svg',
getUrl: (item) => `https://testnets.opensea.io/assets/${item.address}/${item.id}`,
getUrl: (item) => `https://testnets.opensea.io/assets/goerli/${item.address}/${item.id}`,
},
],

[chains.sep]: [
{
title: 'OpenSea',
logo: '/images/common/nft-opensea.svg',
getUrl: (item) => `https://testnets.opensea.io/assets/sepolia/${item.address}/${item.id}`,
},
],

Expand Down
Loading