diff --git a/.github/workflows/update-environments.yml b/.github/workflows/update-environments.yml
index 88e6fd29c..a1917c0a0 100644
--- a/.github/workflows/update-environments.yml
+++ b/.github/workflows/update-environments.yml
@@ -30,7 +30,7 @@ jobs:
* Stage fork: https://stage-fork--taho-development.netlify.app/
Read more: [Deployment to Production Flow](https://github.com/tahowallet/dapp/blob/main/docs/testing-env.md)
- REVIEWERS: '["andreachapman"]'
+ REVIEWERS: '["michalinacienciala"]'
- uses: studroid/label-pr-or-issue-action@ff48a93f6e1a8d8a6befdae900f54da173b17215 # v1.0.1
with:
pr-or-issue-number: ${{ steps.pr.outputs.PULL_REQUEST_NUMBER }}
@@ -78,7 +78,7 @@ jobs:
* Production: https://taho-development.netlify.app/ (aka https://app.taho.xyz/)
Read more: [Deployment to Production Flow](https://github.com/tahowallet/dapp/blob/main/docs/testing-env.md)
- REVIEWERS: '["andreachapman"]'
+ REVIEWERS: '["michalinacienciala"]'
- uses: studroid/label-pr-or-issue-action@ff48a93f6e1a8d8a6befdae900f54da173b17215 # v1.0.1
with:
pr-or-issue-number: ${{ steps.pr.outputs.PULL_REQUEST_NUMBER }}
diff --git a/package.json b/package.json
index dced6cd58..4afaa3743 100644
--- a/package.json
+++ b/package.json
@@ -55,7 +55,8 @@
"stream-http": "^3.2.0",
"styled-jsx": "^5.1.2",
"use-image": "^1.1.1",
- "util": "^0.12.5"
+ "util": "^0.12.5",
+ "zod": "^3.22.4"
},
"devDependencies": {
"@babel/core": "^7.22.9",
diff --git a/src/assets/questline-data.json b/src/assets/questline-data.json
index 1773bd87a..06c73485b 100644
--- a/src/assets/questline-data.json
+++ b/src/assets/questline-data.json
@@ -13,8 +13,7 @@
{
"id": "4_2",
"name": "Increase your Gitcoin Passport score",
- "description": "The more you increase your Gitcoin Passport score in a week, the more of the weekly XP drop you will get.",
- "isNew": true
+ "description": "The more you increase your Gitcoin Passport score in a week, the more of the weekly XP drop you will get."
}
]
},
@@ -31,14 +30,12 @@
{
"id": "7_2",
"name": "Mint W3ST",
- "description": "The more W3ST you mint, the more of the weekly XP drop you will get.",
- "isNew": true
+ "description": "The more W3ST you mint, the more of the weekly XP drop you will get."
},
{
"id": "7_3",
"name": "Collect post essence",
- "description": "The more post essence you collect, the more of the weekly XP drop you will get.",
- "isNew": true
+ "description": "The more post essence you collect, the more of the weekly XP drop you will get."
}
]
},
@@ -51,6 +48,13 @@
"id": "8_1",
"name": "Interact with unique contracts on Base",
"description": "The more interactions you execute with different unique contracts on Base compared to other members of this realm in a week, the more of the weekly XP drop you will get."
+ },
+ {
+ "id": "8_2",
+ "name": "Vampire Attack: Bridge funds from Arbitrum",
+ "description": "Bridge ETH or USDC from Arbitrum to Base using Hop Exchange",
+ "isNew": true,
+ "isAttack": true
}
]
},
@@ -67,8 +71,7 @@
{
"id": "9_2",
"name": "Earn fUSDC rewards using Fluidity",
- "description": "The more fUSDC rewards you earn using Fluidity in a week, the more of the weekly XP drop you will get.",
- "isNew": true
+ "description": "The more fUSDC rewards you earn using Fluidity in a week, the more of the weekly XP drop you will get."
}
]
},
@@ -85,8 +88,7 @@
{
"id": "19_2",
"name": "Claim NFTs during the week using the Galxe space station",
- "description": "The more NFTs you claim via a Galxe [`SpaceStation` contract](https://docs.galxe.com/developer/smart-contract/contracts/spacestation/), the more of the weekly XP drop you will get.",
- "isNew": true
+ "description": "The more NFTs you claim via a Galxe [`SpaceStation` contract](https://docs.galxe.com/developer/smart-contract/contracts/spacestation/), the more of the weekly XP drop you will get."
}
]
},
@@ -103,8 +105,7 @@
{
"id": "22_2",
"name": "Bridge tokens using FraxFerry",
- "description": "The more unique tokens you bridge over FraxFerry, the more of the weekly XP drop you will get.",
- "isNew": true
+ "description": "The more unique tokens you bridge over FraxFerry, the more of the weekly XP drop you will get."
}
]
}
diff --git a/src/redux-state/selectors/wallet.ts b/src/redux-state/selectors/wallet.ts
index b73aa21c3..8892ae40f 100644
--- a/src/redux-state/selectors/wallet.ts
+++ b/src/redux-state/selectors/wallet.ts
@@ -5,6 +5,7 @@ import { createWalletSelector } from "redux-state/selectors"
export const selectWalletAddress = createWalletSelector("address")
export const selectWalletAvatar = createWalletSelector("avatar")
+export const selectWalletAvatarType = createWalletSelector("avatarType")
export const selectWalletNameProperty = createWalletSelector("name")
export const selectIsWalletConnected = createWalletSelector("isConnected")
export const selectHasLoadedBalances = createWalletSelector("hasLoadedBalances")
diff --git a/src/redux-state/slices/wallet.ts b/src/redux-state/slices/wallet.ts
index 465456051..f6e98cb90 100644
--- a/src/redux-state/slices/wallet.ts
+++ b/src/redux-state/slices/wallet.ts
@@ -9,6 +9,7 @@ export type WalletState = {
address: string
name: string
avatar: string
+ avatarType: string | null
hasLoadedBalances: boolean
balances: TokenBalances
transactionStatus: { [id: string]: TransactionProgressStatus }
@@ -19,6 +20,7 @@ const initialState: WalletState = {
address: "",
name: "",
avatar: portrait,
+ avatarType: null,
hasLoadedBalances: false,
balances: {
[TAHO_ADDRESS]: {
@@ -41,12 +43,20 @@ const walletSlice = createSlice({
immerState,
{
payload,
- }: { payload: { address: string; name?: string; avatar?: string } }
+ }: {
+ payload: {
+ address: string
+ name?: string
+ avatar?: string
+ avatarType?: string | null
+ }
+ }
) => {
immerState.isConnected = true
immerState.address = payload.address || immerState.address
immerState.name = payload.name || immerState.name || ""
immerState.avatar = payload.avatar || immerState.avatar || portrait
+ immerState.avatarType = payload.avatarType || null
},
resetWalletState: () => initialState,
updateBalances: (
diff --git a/src/redux-state/thunks/wallet.ts b/src/redux-state/thunks/wallet.ts
index 3c1e6be2a..c04fb6817 100644
--- a/src/redux-state/thunks/wallet.ts
+++ b/src/redux-state/thunks/wallet.ts
@@ -1,4 +1,5 @@
import {
+ determineFetchedFileType,
isClaimXpTransactionID,
resolveAddressToWalletData,
} from "shared/utils"
@@ -35,7 +36,10 @@ export const fetchWalletName = createDappAsyncThunk(
updateConnectedWallet({
address,
...(data.name ? { name: data.name } : {}),
- ...(data.avatar ? { name: data.avatar } : {}),
+ ...(data.avatar ? { avatar: data.avatar } : {}),
+ avatarType: data.avatar
+ ? await determineFetchedFileType(data.avatar)
+ : null,
})
)
diff --git a/src/shared/assets/attack-line.svg b/src/shared/assets/attack-line.svg
new file mode 100644
index 000000000..8ee2c6289
--- /dev/null
+++ b/src/shared/assets/attack-line.svg
@@ -0,0 +1,74 @@
+
diff --git a/src/shared/assets/attack.svg b/src/shared/assets/attack.svg
new file mode 100644
index 000000000..7bb8a7d5d
--- /dev/null
+++ b/src/shared/assets/attack.svg
@@ -0,0 +1,36 @@
+
diff --git a/src/shared/components/Avatar.tsx b/src/shared/components/Avatar.tsx
new file mode 100644
index 000000000..6a59b7875
--- /dev/null
+++ b/src/shared/components/Avatar.tsx
@@ -0,0 +1,47 @@
+import React, { CSSProperties } from "react"
+import {
+ selectWalletAvatar,
+ selectWalletAvatarType,
+ useDappSelector,
+} from "redux-state"
+
+type AvatarProps = {
+ width: string
+ style?: CSSProperties
+}
+
+export default function Avatar({ width, style }: AvatarProps) {
+ const avatar = useDappSelector(selectWalletAvatar)
+ const avatarType = useDappSelector(selectWalletAvatarType)
+
+ return (
+ <>
+