-
-
Save Ashoat/461523a089b78554ce3a36dcf3115661 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/lib/utils/ens-cache.js b/lib/utils/ens-cache.js | |
index 054fc7163..d69bb8841 100644 | |
--- a/lib/utils/ens-cache.js | |
+++ b/lib/utils/ens-cache.js | |
@@ -6,7 +6,7 @@ import sleep from './sleep.js'; | |
const cacheTimeout = 24 * 60 * 60 * 1000; // one day | |
const failedQueryCacheTimeout = 5 * 60 * 1000; // five minutes | |
-const queryTimeout = 10 * 1000; // ten seconds | |
+const queryTimeout = 20 * 1000; // ten seconds | |
async function throwOnTimeout(identifier: string) { | |
await sleep(queryTimeout); | |
diff --git a/native/components/color-splotch.react.js b/native/components/color-splotch.react.js | |
index 3626c4ce0..f5bf737cd 100644 | |
--- a/native/components/color-splotch.react.js | |
+++ b/native/components/color-splotch.react.js | |
@@ -1,9 +1,12 @@ | |
// @flow | |
+import { Image } from 'expo-image'; | |
import * as React from 'react'; | |
import { StyleSheet } from 'react-native'; | |
import { SquircleView } from 'react-native-figma-squircle'; | |
+import { useENSAvatar } from 'lib/hooks/ens-cache.js'; | |
+ | |
type Props = { | |
+color: string, | |
+size?: 'large' | 'small' | 'profile' | 'micro', | |
@@ -20,14 +23,26 @@ function ColorSplotch(props: Props): React.Node { | |
return styles.large; | |
}, [size]); | |
+ const uri = useENSAvatar('0x07124c3b6687e78aec8f13a2312cba72a0bed387'); | |
+ const source = React.useMemo(() => ({ uri }), [uri]); | |
+ | |
+ if (size !== 'profile') { | |
+ return ( | |
+ <SquircleView | |
+ style={style} | |
+ squircleParams={{ | |
+ cornerSmoothing: 0.95, | |
+ cornerRadius: 10, | |
+ fillColor: `#${color}`, | |
+ }} | |
+ /> | |
+ ); | |
+ } | |
+ | |
return ( | |
- <SquircleView | |
+ <Image | |
+ source={source} | |
style={style} | |
- squircleParams={{ | |
- cornerSmoothing: 0.95, | |
- cornerRadius: 10, | |
- fillColor: `#${color}`, | |
- }} | |
/> | |
); | |
} | |
diff --git a/native/utils/ethers-utils.js b/native/utils/ethers-utils.js | |
index 93bac9cd4..3e14d172e 100644 | |
--- a/native/utils/ethers-utils.js | |
+++ b/native/utils/ethers-utils.js | |
@@ -15,7 +15,7 @@ try { | |
let provider: ?EthersProvider; | |
if (alchemyKey) { | |
- provider = new ethers.providers.AlchemyProvider('mainnet', alchemyKey); | |
+ provider = new ethers.providers.AlchemyProvider('goerli', alchemyKey); | |
} | |
export { provider }; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment