From be0d19471675794d70ff8168c00f05aef7dda0f6 Mon Sep 17 00:00:00 2001 From: Ted Palmer Date: Fri, 8 Mar 2024 12:00:37 -0500 Subject: [PATCH 1/5] Upgrade rk to 2.3.8 --- package.json | 2 +- yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/package.json b/package.json index d05e6c98f..4bc2704fa 100644 --- a/package.json +++ b/package.json @@ -29,7 +29,7 @@ "@radix-ui/react-toggle-group": "^1.0.1", "@radix-ui/react-tooltip": "1.0.6", "@rainbow-me/rainbowkit": "2.0.0", - "@reservoir0x/reservoir-kit-ui": "2.3.7", + "@reservoir0x/reservoir-kit-ui": "2.3.8", "@sentry/nextjs": "^7.85.0", "@tanstack/react-query": "5.20.2", "@types/uuid": "^9.0.1", diff --git a/yarn.lock b/yarn.lock index 3052acff0..e3b1f4c8a 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1888,10 +1888,10 @@ dependencies: merge-options "^3.0.4" -"@reservoir0x/reservoir-kit-ui@2.3.7": - version "2.3.7" - resolved "https://registry.yarnpkg.com/@reservoir0x/reservoir-kit-ui/-/reservoir-kit-ui-2.3.7.tgz#33ecdf5ed57922ba999e1902268ea9cba1c826cb" - integrity sha512-ns+vtkBOB2lrj1GUW0yiX4/M/8GWZhG97f3q4htWY5laRuSLF5Nhx6tdiu2BEHL0v6yJLeQG3JPdJ4nxSXkfMA== +"@reservoir0x/reservoir-kit-ui@2.3.8": + version "2.3.8" + resolved "https://registry.yarnpkg.com/@reservoir0x/reservoir-kit-ui/-/reservoir-kit-ui-2.3.8.tgz#a0774bfb579b093ceac8e24867a7f62a585e0db7" + integrity sha512-Ga8osHLIki/pLl0bR1WPN0Zk+lloUzsuhQByAGS10BzvZHn26xZFnrZvkxE21PCj83EpMwm+TnhPQ0bWyvLN+Q== dependencies: "@fortawesome/fontawesome-svg-core" "^6.1.1" "@fortawesome/free-solid-svg-icons" "^6.1.1" From fd0711a2156c000a20c8e64f98967b411c1f0983 Mon Sep 17 00:00:00 2001 From: Ted Palmer Date: Mon, 18 Mar 2024 15:17:36 -0400 Subject: [PATCH 2/5] Upgrade rk to 2.4.0 --- components/portfolio/TokenTable.tsx | 18 ++++++++++++------ package.json | 2 +- yarn.lock | 18 +++++++++--------- 3 files changed, 22 insertions(+), 16 deletions(-) diff --git a/components/portfolio/TokenTable.tsx b/components/portfolio/TokenTable.tsx index b7c26ff37..54779e9ca 100644 --- a/components/portfolio/TokenTable.tsx +++ b/components/portfolio/TokenTable.tsx @@ -395,12 +395,14 @@ const TokenTableRow: FC = ({ Floor = ({ diff --git a/package.json b/package.json index 4bc2704fa..c24367cc1 100644 --- a/package.json +++ b/package.json @@ -29,7 +29,7 @@ "@radix-ui/react-toggle-group": "^1.0.1", "@radix-ui/react-tooltip": "1.0.6", "@rainbow-me/rainbowkit": "2.0.0", - "@reservoir0x/reservoir-kit-ui": "2.3.8", + "@reservoir0x/reservoir-kit-ui": "2.4.0", "@sentry/nextjs": "^7.85.0", "@tanstack/react-query": "5.20.2", "@types/uuid": "^9.0.1", diff --git a/yarn.lock b/yarn.lock index e3b1f4c8a..4819d5fb6 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1888,10 +1888,10 @@ dependencies: merge-options "^3.0.4" -"@reservoir0x/reservoir-kit-ui@2.3.8": - version "2.3.8" - resolved "https://registry.yarnpkg.com/@reservoir0x/reservoir-kit-ui/-/reservoir-kit-ui-2.3.8.tgz#a0774bfb579b093ceac8e24867a7f62a585e0db7" - integrity sha512-Ga8osHLIki/pLl0bR1WPN0Zk+lloUzsuhQByAGS10BzvZHn26xZFnrZvkxE21PCj83EpMwm+TnhPQ0bWyvLN+Q== +"@reservoir0x/reservoir-kit-ui@2.4.0": + version "2.4.0" + resolved "https://registry.yarnpkg.com/@reservoir0x/reservoir-kit-ui/-/reservoir-kit-ui-2.4.0.tgz#3a2114170c901552ff316105a7605d226eeac8de" + integrity sha512-j+V3tQah77grMwhWjPQdRDCslmOIa6moyVaFPerHhZAMVhdYJ+DFtb2RdLa4j/RusS74HKhszfAWPFQacokA1g== dependencies: "@fortawesome/fontawesome-svg-core" "^6.1.1" "@fortawesome/free-solid-svg-icons" "^6.1.1" @@ -1907,7 +1907,7 @@ "@radix-ui/react-toggle-group" "1.0.4" "@radix-ui/react-tooltip" "1.0.6" "@react-hookz/web" "^19.2.0" - "@reservoir0x/reservoir-sdk" "2.0.7" + "@reservoir0x/reservoir-sdk" "2.0.9" "@stitches/react" "1.3.1-1" dayjs "^1.11.4" flatpickr "^4.6.13" @@ -1915,10 +1915,10 @@ react-flatpickr "^3.10.13" swr "2.0.1" -"@reservoir0x/reservoir-sdk@2.0.7": - version "2.0.7" - resolved "https://registry.yarnpkg.com/@reservoir0x/reservoir-sdk/-/reservoir-sdk-2.0.7.tgz#4d3c2a8bb0059c2c925f7bf74934390ad8f12fc4" - integrity sha512-HimR3H1urwiYeWOME2XZd/2nkclkHjq0jEM5wAJa46zM3k6GjGMThp95Jg/LV6cV2Cu4ydD68zSrRpwnQTvbCQ== +"@reservoir0x/reservoir-sdk@2.0.9": + version "2.0.9" + resolved "https://registry.yarnpkg.com/@reservoir0x/reservoir-sdk/-/reservoir-sdk-2.0.9.tgz#a2baffbfb9a17ed8340ef7a8404a505590c7cae2" + integrity sha512-kDuwq8wtL8DydyqQFjmVbu9zYORNOZWNplU8i+TftswjfMOpHkmuNxjg83HiJX0QWhZ51TY3j0dx9CiTcxDF4w== dependencies: axios "^1.6.7" From 17f381cde4a3222e620cf35533cfbe3042171772 Mon Sep 17 00:00:00 2001 From: Ted Palmer Date: Mon, 18 Mar 2024 15:24:05 -0400 Subject: [PATCH 3/5] Fix build error --- components/portfolio/BatchListings.tsx | 8 ++++---- components/portfolio/BatchListingsTableRow.tsx | 14 +++++++------- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/components/portfolio/BatchListings.tsx b/components/portfolio/BatchListings.tsx index 6e91dcbe4..1c2589806 100644 --- a/components/portfolio/BatchListings.tsx +++ b/components/portfolio/BatchListings.tsx @@ -235,14 +235,14 @@ const BatchListings: FC = ({ return ( prevListings?.map((listing) => { if ( - listing.token.token?.collection?.floorAskPrice?.amount?.decimal && - listing.token.token?.collection?.floorAskPrice.currency + listing.token.token?.collection?.floorAsk?.price?.amount?.decimal && + listing.token.token?.collection?.floorAsk?.price?.currency ) { return { ...listing, price: - listing.token.token.collection.floorAskPrice.amount.decimal.toString(), - currency: listing.token.token?.collection?.floorAskPrice + listing.token.token.collection?.floorAsk?.price?.amount.decimal.toString(), + currency: listing.token.token?.collection?.floorAsk?.price .currency as Currency, } } diff --git a/components/portfolio/BatchListingsTableRow.tsx b/components/portfolio/BatchListingsTableRow.tsx index 63192b2ee..25198d7b2 100644 --- a/components/portfolio/BatchListingsTableRow.tsx +++ b/components/portfolio/BatchListingsTableRow.tsx @@ -290,26 +290,26 @@ export const BatchListingsTableRow: FC = ({ size="large" css={{ minWidth: 'max-content', minHeight: 48, py: 14 }} disabled={ - !listing.token?.token?.collection?.floorAskPrice?.amount + !listing.token?.token?.collection?.floorAsk?.price?.amount ?.decimal } onClick={() => { if ( - listing.token?.token?.collection?.floorAskPrice?.amount + listing.token?.token?.collection?.floorAsk?.price?.amount ?.decimal ) { handlePriceChange( - listing.token?.token?.collection?.floorAskPrice?.amount?.decimal?.toString() + listing.token?.token?.collection?.floorAsk?.price?.amount?.decimal?.toString() ) } }} > Floor - {listing.token?.token?.collection?.floorAskPrice?.amount + {listing.token?.token?.collection?.floorAsk?.price?.amount ?.decimal ? ( - {`${listing.token?.token?.collection?.floorAskPrice?.amount?.decimal} ${listing.token?.token?.collection?.floorAskPrice?.currency?.symbol}`} + {`${listing.token?.token?.collection?.floorAsk?.price?.amount?.decimal} ${listing.token?.token?.collection?.floorAsk?.price?.currency?.symbol}`} ) : null} @@ -330,8 +330,8 @@ export const BatchListingsTableRow: FC = ({ {topTraitPrice}{' '} { - listing.token?.token?.collection?.floorAskPrice?.currency - ?.symbol + listing.token?.token?.collection?.floorAsk?.price + ?.currency?.symbol } ) : null} From a6d7b90f75c6fb9573493a9db7da6cfb62ce4898 Mon Sep 17 00:00:00 2001 From: Ted Palmer Date: Tue, 9 Apr 2024 14:52:51 -0400 Subject: [PATCH 4/5] Fix missing price for free mints --- components/rankings/MintRankingsTable.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/components/rankings/MintRankingsTable.tsx b/components/rankings/MintRankingsTable.tsx index 17eafa31d..2ebb04d1d 100644 --- a/components/rankings/MintRankingsTable.tsx +++ b/components/rankings/MintRankingsTable.tsx @@ -96,7 +96,7 @@ const RankingsTableRow: FC = ({ mint, rank }) => { return optimizeImage(mint?.image || mint?.sampleImages?.[0], 250) }, [mint.image]) - const mintPrice = mint.mintPrice?.toString() + const mintPrice = mint.mintPrice const sampleImages: string[] = mint?.sampleImages || [] @@ -217,7 +217,7 @@ const RankingsTableRow: FC = ({ mint, rank }) => { justify="start" css={{ height: '100%' }} > - {mintPrice !== '0' ? ( + {mintPrice ? ( Date: Tue, 9 Apr 2024 16:27:21 -0400 Subject: [PATCH 5/5] Enable oracle cancellation on all chains --- utils/chains.ts | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/utils/chains.ts b/utils/chains.ts index 29e2d739a..70ee19e77 100644 --- a/utils/chains.ts +++ b/utils/chains.ts @@ -143,6 +143,7 @@ export default [ contract: usdcContracts[arbitrum.id], }, ], + oracleBidsEnabled: true, checkPollingInterval: reservoirChains.arbitrum.checkPollingInterval, }, { @@ -155,6 +156,7 @@ export default [ coingeckoId: 'ethereum', collectionSetId: process.env.NEXT_PUBLIC_BASE_COLLECTION_SET_ID, community: process.env.NEXT_PUBLIC_BASE_COMMUNITY, + oracleBidsEnabled: true, checkPollingInterval: reservoirChains.base.checkPollingInterval, }, { @@ -176,6 +178,7 @@ export default [ contract: usdcContracts[optimism.id], }, ], + oracleBidsEnabled: true, checkPollingInterval: reservoirChains.optimism.checkPollingInterval, }, { @@ -187,6 +190,7 @@ export default [ proxyApi: '/api/reservoir/zora', routePrefix: 'zora', coingeckoId: 'ethereum', + oracleBidsEnabled: true, checkPollingInterval: reservoirChains.zora.checkPollingInterval, }, { @@ -207,6 +211,7 @@ export default [ contract: usdcContracts[bsc.id], }, ], + oracleBidsEnabled: true, checkPollingInterval: reservoirChains.bsc.checkPollingInterval, }, { @@ -217,6 +222,7 @@ export default [ proxyApi: '/api/reservoir/opbnb', routePrefix: 'opbnb', coingeckoId: 'binancecoin', + oracleBidsEnabled: true, checkPollingInterval: reservoirChains.opBnb.checkPollingInterval, }, { @@ -227,6 +233,7 @@ export default [ proxyApi: '/api/reservoir/ancient8', routePrefix: 'ancient8', coingeckoId: 'ethereum', + oracleBidsEnabled: true, checkPollingInterval: reservoirChains.ancient8.checkPollingInterval, }, { @@ -239,6 +246,7 @@ export default [ coingeckoId: 'avalanche-2', collectionSetId: process.env.NEXT_PUBLIC_AVALANCHE_COLLECTION_SET_ID, community: process.env.NEXT_PUBLIC_AVALANCHE_COMMUNITY, + oracleBidsEnabled: true, checkPollingInterval: reservoirChains.avalanche.checkPollingInterval, }, { @@ -251,6 +259,7 @@ export default [ coingeckoId: 'ethereum', collectionSetId: process.env.NEXT_PUBLIC_ARBITRUM_NOVA_COLLECTION_SET_ID, community: process.env.NEXT_PUBLIC_ARBITRUM_NOVA_COMMUNITY, + oracleBidsEnabled: true, checkPollingInterval: reservoirChains.arbitrumNova.checkPollingInterval, }, { @@ -263,6 +272,7 @@ export default [ coingeckoId: 'ethereum', collectionSetId: process.env.NEXT_PUBLIC_LINEA_COLLECTION_SET_ID, community: process.env.NEXT_PUBLIC_LINEA_COMMUNITY, + oracleBidsEnabled: true, checkPollingInterval: reservoirChains.linea.checkPollingInterval, }, { @@ -276,6 +286,7 @@ export default [ coingeckoId: 'ethereum', collectionSetId: process.env.NEXT_PUBLIC_POLYGON_ZKEVM_COLLECTION_SET_ID, community: process.env.NEXT_PUBLIC_POLYGON_ZKEVM_COMMUNITY, + oracleBidsEnabled: true, checkPollingInterval: reservoirChains.polygonZkEvm.checkPollingInterval, }, { @@ -290,6 +301,7 @@ export default [ coingeckoId: 'ethereum', collectionSetId: process.env.NEXT_PUBLIC_ZKSYNC_COLLECTION_SET_ID, community: process.env.NEXT_PUBLIC_ZKSYNC_COMMUNITY, + oracleBidsEnabled: true, checkPollingInterval: reservoirChains.zkSync.checkPollingInterval, }, { @@ -304,6 +316,7 @@ export default [ coingeckoId: 'ethereum', collectionSetId: process.env.NEXT_PUBLIC_SCROLL_COLLECTION_SET_ID, community: process.env.NEXT_PUBLIC_SCROLL_COMMUNITY, + oracleBidsEnabled: true, checkPollingInterval: reservoirChains.scroll.checkPollingInterval, }, { @@ -318,6 +331,7 @@ export default [ coingeckoId: 'ethereum', collectionSetId: process.env.NEXT_PUBLIC_APE_COLLECTION_SET_ID, community: process.env.NEXT_PUBLIC_APEX_COMMUNITY, + oracleBidsEnabled: true, checkPollingInterval: reservoirChains.apexPop.checkPollingInterval, }, { @@ -332,6 +346,7 @@ export default [ coingeckoId: 'ethereum', collectionSetId: process.env.NEXT_PUBLIC_BLAST_COLLECTION_SET_ID, community: process.env.NEXT_PUBLIC_BLAST_COMMUNITY, + oracleBidsEnabled: true, checkPollingInterval: reservoirChains.blast.checkPollingInterval, }, { @@ -346,6 +361,7 @@ export default [ coingeckoId: 'ethereum', collectionSetId: process.env.NEXT_PUBLIC_ASTAR_ZKEVM_COLLECTION_SET_ID, community: process.env.NEXT_PUBLIC_ASTAR_ZKEVM_COMMUNITY, + oracleBidsEnabled: true, checkPollingInterval: reservoirChains.astarZkEVM.checkPollingInterval, }, ] as ReservoirChain[]