Skip to content

Commit

Permalink
chore: bump modal version + loader improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
ignaciosantise committed May 29, 2024
1 parent bdceb8e commit f0f1143
Show file tree
Hide file tree
Showing 9 changed files with 195 additions and 191 deletions.
4 changes: 2 additions & 2 deletions dapps/W3MWagmi/ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -970,7 +970,7 @@ PODS:
- React-Mapbuffer (0.73.4):
- glog
- React-debug
- react-native-compat (2.11.2):
- react-native-compat (2.13.1):
- glog
- RCT-Folly (= 2022.05.16.00)
- React-Core
Expand Down Expand Up @@ -1486,7 +1486,7 @@ SPEC CHECKSUMS:
React-jsinspector: 9ac353eccf6ab54d1e0a33862ba91221d1e88460
React-logger: 0a57b68dd2aec7ff738195f081f0520724b35dab
React-Mapbuffer: 63913773ed7f96b814a2521e13e6d010282096ad
react-native-compat: fedbfe0495fa772bed1fbaa2dfa5d4f3a303abb2
react-native-compat: bb0756de08af94abed964f81bbd18ff6ba514873
react-native-config: 86038147314e2e6d10ea9972022aa171e6b1d4d8
react-native-get-random-values: a6ea6a8a65dc93e96e24a11105b1a9c8cfe1d72a
react-native-mmkv: e97c0c79403fb94577e5d902ab1ebd42b0715b43
Expand Down
250 changes: 123 additions & 127 deletions dapps/W3MWagmi/ios/W3MWagmi.xcodeproj/project.pbxproj

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions dapps/W3MWagmi/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,10 @@
"@react-navigation/native-stack": "6.9.26",
"@sentry/react-native": "5.20.0",
"@tanstack/react-query": "5.37.1",
"@walletconnect/react-native-compat": "2.11.2",
"@web3modal/coinbase-wagmi-react-native": "1.4.0",
"@web3modal/email-wagmi-react-native": "1.4.0",
"@web3modal/wagmi-react-native": "1.4.0",
"@walletconnect/react-native-compat": "2.13.1",
"@web3modal/coinbase-wagmi-react-native": "2.0.0-alpha.2",
"@web3modal/email-wagmi-react-native": "2.0.0-alpha.2",
"@web3modal/wagmi-react-native": "2.0.0-alpha.2",
"expo": "^50.0.0",
"react": "18.2.0",
"react-native": "0.73.4",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import wagmigotchiABI from '@/utils/wagmigotchiABI';

export function ReadContract() {
const [requestModalVisible, setRequetsModalVisible] = useState(false);
const {isConnected} = useAccount();
const {isConnected, status} = useAccount();

const {data, isError, isLoading, isSuccess} = useReadContract({
address: '0xecb504d39723b0be0e3a9aa33d646642d1051ee1',
Expand All @@ -24,7 +24,7 @@ export function ReadContract() {

return isConnected ? (
<View>
<Button disabled={isLoading} onPress={onPress}>
<Button disabled={status === 'reconnecting'} onPress={onPress}>
Read contract
</Button>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import {parseEther} from 'viem/utils';

export function SendTransaction() {
const [requestModalVisible, setRequetsModalVisible] = useState(false);
const {isConnected} = useAccount();
const {isConnected, status} = useAccount();

const {data, isPending, isSuccess, isError, sendTransaction} =
useSendTransaction();
Expand All @@ -29,7 +29,9 @@ export function SendTransaction() {

return isConnected ? (
<View>
<Button disabled={isPending} onPress={onPress}>
<Button
disabled={isPending || status === 'reconnecting'}
onPress={onPress}>
{isPending ? 'Loading...' : 'Send transaction'}
</Button>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import {RequestModal} from '@/components/RequestModal';

export function SignMessage() {
const [requestModalVisible, setRequetsModalVisible] = useState(false);
const {isConnected} = useAccount();
const {isConnected, status} = useAccount();

const {data, isError, isPending, isSuccess, signMessage} = useSignMessage();

Expand All @@ -25,7 +25,9 @@ export function SignMessage() {

return isConnected ? (
<View>
<Button disabled={isPending} onPress={onPress}>
<Button
disabled={isPending || status === 'reconnecting'}
onPress={onPress}>
{isPending ? 'Loading...' : 'Sign message'}
</Button>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import {eip712} from '@/utils/eip712';

export function SignTypedDataV4() {
const [requestModalVisible, setRequetsModalVisible] = useState(false);
const {isConnected} = useAccount();
const {isConnected, status} = useAccount();

const {data, isError, isPending, isSuccess, signTypedData} =
useSignTypedData();
Expand All @@ -30,7 +30,9 @@ export function SignTypedDataV4() {

return isConnected ? (
<View>
<Button disabled={isPending} onPress={onPress}>
<Button
disabled={isPending || status === 'reconnecting'}
onPress={onPress}>
{isPending ? 'Loading...' : 'eth_signTypedData_v4'}
</Button>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import usdtAbi from '@/utils/usdtAbi';

export function WriteContract() {
const [requestModalVisible, setRequetsModalVisible] = useState(false);
const {isConnected, address} = useAccount();
const {isConnected, address, status} = useAccount();

const {data, isPending, isSuccess, isError, writeContract} =
useWriteContract();
Expand All @@ -34,7 +34,9 @@ export function WriteContract() {

return isConnected ? (
<View>
<Button disabled={isPending} onPress={onPress}>
<Button
disabled={isPending || status === 'reconnecting'}
onPress={onPress}>
{isPending ? 'Loading...' : 'Write contract'}
</Button>

Expand Down
96 changes: 48 additions & 48 deletions dapps/W3MWagmi/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4266,14 +4266,14 @@
"@walletconnect/modal-core" "2.6.2"
"@walletconnect/modal-ui" "2.6.2"

"@walletconnect/react-native-compat@2.11.2":
version "2.11.2"
resolved "https://registry.yarnpkg.com/@walletconnect/react-native-compat/-/react-native-compat-2.11.2.tgz#bd0d3ab77589050fb4cb750261e257455c09af46"
integrity sha512-Ozz0vPyWDBIKQfjHEwt3OKK6EslDMaTUVpgOaGfZjQ8gw/vuOnYOybn1IpgAQjuPfIQSkPebtE36dxlJyGPzOg==
"@walletconnect/react-native-compat@2.13.1":
version "2.13.1"
resolved "https://registry.yarnpkg.com/@walletconnect/react-native-compat/-/react-native-compat-2.13.1.tgz#dbf6b0b264fb2ca66b03282a4c016614e843f3c8"
integrity sha512-NBkSIClPj1romjx0yL6qSazewrdsxyOYp8L6krRE/A0y8xIjPLT4cPPbxW/6ewvHlHesze8hRbO24bG8tJJCbg==
dependencies:
events "3.3.0"
fast-text-encoding "^1.0.6"
react-native-url-polyfill "^2.0.0"
fast-text-encoding "1.0.6"
react-native-url-polyfill "2.0.0"

"@walletconnect/[email protected]":
version "1.0.10"
Expand Down Expand Up @@ -4385,63 +4385,63 @@
"@walletconnect/window-getters" "^1.0.1"
tslib "1.14.1"

"@web3modal/coinbase-wagmi-react-native@1.4.0":
version "1.4.0"
resolved "https://registry.yarnpkg.com/@web3modal/coinbase-wagmi-react-native/-/coinbase-wagmi-react-native-1.4.0.tgz#01a0caa3b752768c4f41b65734c268115df01f2d"
integrity sha512-ezSEiNHRVdWp4HRmySbaHx+6fONNMzQS1WAH+PV4Q/a/yFeNk5oz7fnAq4Wr4cvCB7HW6VZv5T17TdADDGJvbw==
"@web3modal/coinbase-wagmi-react-native@2.0.0-alpha.2":
version "2.0.0-alpha.2"
resolved "https://registry.yarnpkg.com/@web3modal/coinbase-wagmi-react-native/-/coinbase-wagmi-react-native-2.0.0-alpha.2.tgz#c2975f2969f389ecb9b345c4da1b9c0e2a092bb2"
integrity sha512-xWtXtU8NyRmPGzyep/Z7BEfB8I5s3jVxTytr7sV2KXwcla68Feft6j0FAIgujXCIgy2w3z8U3kQ/13X5+RuLBw==

"@web3modal/core-react-native@1.4.0":
version "1.4.0"
resolved "https://registry.yarnpkg.com/@web3modal/core-react-native/-/core-react-native-1.4.0.tgz#4c1f24269e5b58b60d3dc1f738c592981876663d"
integrity sha512-LHK+10C6ImFx6YQGrOInz7REKDZPWjS8WMqfelulw+zhY/YGGa4MPsELvoOnRY9VVYN8Giqs4cmjFYs+HW7+nA==
"@web3modal/core-react-native@2.0.0-alpha.2":
version "2.0.0-alpha.2"
resolved "https://registry.yarnpkg.com/@web3modal/core-react-native/-/core-react-native-2.0.0-alpha.2.tgz#fe034970dab17f7454eaaf34984d6324243fa913"
integrity sha512-yfmfwctR24IBa6lz6MRNejIPRuHTV7Ne002av8A79fjI7McYcBwPilVXYqQgg+h/JP/ww7z8D6rc2NxxwKseqg==
dependencies:
valtio "1.10.5"

"@web3modal/email-react-native@1.4.0":
version "1.4.0"
resolved "https://registry.yarnpkg.com/@web3modal/email-react-native/-/email-react-native-1.4.0.tgz#542d9d8abed85e895c08b2ae3d0b91493ce4f1b5"
integrity sha512-RqoVxoceePREEwHuY+lE/7JIh0Bp8z+V49CtF80qS6RsZi4MMWiup8muksWQNFOLuKTdtrnXObnWYsP1pwSVrw==
"@web3modal/email-react-native@2.0.0-alpha.2":
version "2.0.0-alpha.2"
resolved "https://registry.yarnpkg.com/@web3modal/email-react-native/-/email-react-native-2.0.0-alpha.2.tgz#17e11f607ac71e8263bd71d604a9b65e64270273"
integrity sha512-5+fFygBitcIXRWVl92UrQTBoD9Hhr/9YI04gn806sd8o8WESLYWtnAX2pQTan1Ti0J1iKKy+hcslA+qF+QAlxw==
dependencies:
"@web3modal/core-react-native" "1.4.0"
"@web3modal/ui-react-native" "1.4.0"
"@web3modal/core-react-native" "2.0.0-alpha.2"
"@web3modal/ui-react-native" "2.0.0-alpha.2"
zod "3.22.4"

"@web3modal/email-wagmi-react-native@1.4.0":
version "1.4.0"
resolved "https://registry.yarnpkg.com/@web3modal/email-wagmi-react-native/-/email-wagmi-react-native-1.4.0.tgz#2f50646a2a47e08f12d49e883245a24bbbb37ce2"
integrity sha512-lzWXWBX+yIoa9X6tbs0ioS67xXwTnBdJeQVtm29tLlZhmimfcbFuBSFJQXZgacValtgc6+iYIX7SzaYH9rCNtw==
"@web3modal/email-wagmi-react-native@2.0.0-alpha.2":
version "2.0.0-alpha.2"
resolved "https://registry.yarnpkg.com/@web3modal/email-wagmi-react-native/-/email-wagmi-react-native-2.0.0-alpha.2.tgz#bea2985552fade2cf7626cc852505f8b97966ebc"
integrity sha512-HH8h6CZzsIwBaPHFaUEpu3d6RI86NYEGcKJFTSjYp4JiF3YGfdbvTfOO3Uqn/6CIBjTsIEAH58bffSA/aELYUQ==
dependencies:
"@web3modal/email-react-native" "1.4.0"
"@web3modal/email-react-native" "2.0.0-alpha.2"

"@web3modal/scaffold-react-native@1.4.0":
version "1.4.0"
resolved "https://registry.yarnpkg.com/@web3modal/scaffold-react-native/-/scaffold-react-native-1.4.0.tgz#bca3a1e9e991bf24e059e444301cb2b8761bcf56"
integrity sha512-nR2LMUY+T6QdXICqNZ80EKCQ1ZvzGl96K33Q4e800CPhV2+zgfiUVWFKtfMSw8plpI7vbRl7IOyExl12889PHA==
"@web3modal/scaffold-react-native@2.0.0-alpha.2":
version "2.0.0-alpha.2"
resolved "https://registry.yarnpkg.com/@web3modal/scaffold-react-native/-/scaffold-react-native-2.0.0-alpha.2.tgz#6b4baf538ca04619392bb32a42dde697ee1204af"
integrity sha512-LaP/e7GJLjZ1aO6Fx0CWo6kUyi54FhJEHpuqPIWHnkW0GcE1YihfiqqskoUAwmSJe5E9h5G0dt76nI+bjp7nww==
dependencies:
"@web3modal/core-react-native" "1.4.0"
"@web3modal/ui-react-native" "1.4.0"
"@web3modal/core-react-native" "2.0.0-alpha.2"
"@web3modal/ui-react-native" "2.0.0-alpha.2"

"@web3modal/scaffold-utils-react-native@1.4.0":
version "1.4.0"
resolved "https://registry.yarnpkg.com/@web3modal/scaffold-utils-react-native/-/scaffold-utils-react-native-1.4.0.tgz#e993e32271552936075b768ef897be99ebe4cad5"
integrity sha512-lBWzJIfQWRXdtv6L9wIY8LHPvQWRTgRMMzSFAWKUNkb/5biEOqI6JIBHWTuAzJ5dq/su3YpMz1/ludqj1EHk9A==
"@web3modal/scaffold-utils-react-native@2.0.0-alpha.2":
version "2.0.0-alpha.2"
resolved "https://registry.yarnpkg.com/@web3modal/scaffold-utils-react-native/-/scaffold-utils-react-native-2.0.0-alpha.2.tgz#9ab5eafe008233e7e7432a9a832dd5a91ddad458"
integrity sha512-dCw1A8mnXA3h6zmpiPdMV8yhXnQBKF6wgzQTqP7PzlCVqW4hfeD0b8iZnx6kKVjZIcOHMkoiz1woDRtTZFwOag==
dependencies:
"@web3modal/scaffold-react-native" "1.4.0"
"@web3modal/scaffold-react-native" "2.0.0-alpha.2"

"@web3modal/ui-react-native@1.4.0":
version "1.4.0"
resolved "https://registry.yarnpkg.com/@web3modal/ui-react-native/-/ui-react-native-1.4.0.tgz#d17f2d7a5ebad94536036d48b031af48c2fdf248"
integrity sha512-1Hmk/RmpLb2K1auDcZrQcH92mpHkzOSIp6u4bWU02uD7PofOJUQTv9Mig/lj5WjyRvYmBcT5/oRrQQbymof35A==
"@web3modal/ui-react-native@2.0.0-alpha.2":
version "2.0.0-alpha.2"
resolved "https://registry.yarnpkg.com/@web3modal/ui-react-native/-/ui-react-native-2.0.0-alpha.2.tgz#9353243f4ddca4064e907dc63390188be80e6193"
integrity sha512-vQmVfc4NqDG34vZIeZidYAWVJpirr9/gOaIPU9qIMi2i+o2mlq8L42J6ngDp3rfgcLkQQWHjyPB8w6dsRJxV9w==
dependencies:
qrcode "1.5.3"

"@web3modal/wagmi-react-native@1.4.0":
version "1.4.0"
resolved "https://registry.yarnpkg.com/@web3modal/wagmi-react-native/-/wagmi-react-native-1.4.0.tgz#268a374c6a38d967e08829a0b751835835692733"
integrity sha512-ThsQZnQdolu9CyfzahBwBnn7TLKMnCxM0CLx+fZh0Sb8ogb3xrMKxueSWZ2vXOqA6yh372o5CTSXcy8fGeMZ2Q==
"@web3modal/wagmi-react-native@2.0.0-alpha.2":
version "2.0.0-alpha.2"
resolved "https://registry.yarnpkg.com/@web3modal/wagmi-react-native/-/wagmi-react-native-2.0.0-alpha.2.tgz#c1205bf5be5cbb7e993929062477721139fe645c"
integrity sha512-juY5YiQ0gMWu4VIRs3PeWaEt3Y2lbLhboTe+z7qV5Yl+PAPOO1CQDFDXGllKhTF7VQH0RjozhPDmbu83g3pbDg==
dependencies:
"@web3modal/scaffold-react-native" "1.4.0"
"@web3modal/scaffold-utils-react-native" "1.4.0"
"@web3modal/scaffold-react-native" "2.0.0-alpha.2"
"@web3modal/scaffold-utils-react-native" "2.0.0-alpha.2"

"@xmldom/xmldom@^0.8.8":
version "0.8.10"
Expand Down Expand Up @@ -6551,7 +6551,7 @@ fast-safe-stringify@^2.0.6:
resolved "https://registry.yarnpkg.com/fast-safe-stringify/-/fast-safe-stringify-2.1.1.tgz#c406a83b6e70d9e35ce3b30a81141df30aeba884"
integrity sha512-W+KJc2dmILlPplD/H4K9l9LcAHAfPtP6BY84uVLXQ6Evcz9Lcg33Y2z1IVblT6xdY54PXYVHEv+0Wpq8Io6zkA==

fast-text-encoding@^1.0.6:
[email protected]:
version "1.0.6"
resolved "https://registry.yarnpkg.com/fast-text-encoding/-/fast-text-encoding-1.0.6.tgz#0aa25f7f638222e3396d72bf936afcf1d42d6867"
integrity sha512-VhXlQgj9ioXCqGstD37E/HBeqEGV/qOD/kmbVG8h5xKBYvM1L3lR1Zn4555cQ8GkYbJa8aJSipLPndE1k6zK2w==
Expand Down Expand Up @@ -9936,7 +9936,7 @@ [email protected]:
css-select "^5.1.0"
css-tree "^1.1.3"

react-native-url-polyfill@^2.0.0:
[email protected]:
version "2.0.0"
resolved "https://registry.yarnpkg.com/react-native-url-polyfill/-/react-native-url-polyfill-2.0.0.tgz#db714520a2985cff1d50ab2e66279b9f91ffd589"
integrity sha512-My330Do7/DvKnEvwQc0WdcBnFPploYKp9CYlefDXzIdEaA+PAhDYllkvGeEroEzvc4Kzzj2O4yVdz8v6fjRvhA==
Expand Down

0 comments on commit f0f1143

Please sign in to comment.