Skip to content

Commit

Permalink
Merge pull request #899 from lfglabs-dev/ref/add-keplr
Browse files Browse the repository at this point in the history
feat: add keplr wallet
  • Loading branch information
Marchand-Nicolas authored Oct 26, 2024
2 parents cfca5fc + c82f35b commit 48a64f8
Show file tree
Hide file tree
Showing 7 changed files with 7,957 additions and 12,179 deletions.
13 changes: 6 additions & 7 deletions components/UI/modalWallet.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import CopyIcon from "./iconsComponents/icons/copyIcon";
import DoneIcon from "./iconsComponents/icons/doneIcon";
import { useNotificationManager } from "../../hooks/useNotificationManager";
import { useCopyToClipboard } from "@/hooks/useCopy";
import { getConnectorIcon } from "@/utils/connectorWrapper";

type ModalWalletProps = {
closeModal: () => void;
Expand Down Expand Up @@ -62,16 +63,14 @@ const ModalWallet: FunctionComponent<ModalWalletProps> = ({
</button>
<div className={styles.menu_title}>
<div className={styles.menu_title}>
{connector && connector.id === "braavos" ? (
{connector && (
<img
width={"25px"}
src="/braavos/braavosLogo.svg"
alt="braavos logo"
src={getConnectorIcon(connector.id)}
width={25}
height={25}
alt="connector logo"
/>
) : (
<ArgentIcon color={"#f36a3d"} width={"25px"} />
)}

<p className="ml-2">Connected with &nbsp;{domain}&nbsp;</p>
</div>
</div>
Expand Down
2 changes: 1 addition & 1 deletion hooks/useBalances.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export default function useBalances(address?: string) {
functionName: "aggregate",
args: callData,
watch: true,
blockIdentifier: BlockTag.pending,
blockIdentifier: BlockTag.PENDING,
});

useEffect(() => {
Expand Down
2 changes: 1 addition & 1 deletion hooks/useNeedAllowances.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ export default function useNeedsAllowances(
functionName: "aggregate",
args: callData,
watch: true,
blockIdentifier: BlockTag.pending,
blockIdentifier: BlockTag.PENDING,
});

useEffect(() => {
Expand Down
20,097 changes: 7,931 additions & 12,166 deletions package-lock.json

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
"@solana/wallet-adapter-wallets": "^0.19.23",
"@solana/web3.js": "^1.87.6",
"@starknet-react/chains": "^3.0.0",
"@starknet-react/core": "^3.0.1",
"@starknet-react/core": "^3.0.3",
"@vercel/analytics": "^0.1.5",
"@walnuthq/sdk": "^1.1.10",
"axios": "^1.4.0",
Expand All @@ -32,7 +32,7 @@
"dotenv": "^16.3.1",
"eslint-config-next": "^13.4.7",
"ethers": "^6.12.1",
"get-starknet-core": "^3.3.0",
"get-starknet-core": "^4.0.0",
"jotai": "^2.5.0",
"lottie-react": "^2.4.0",
"mongodb": "^4.12.1",
Expand All @@ -45,9 +45,9 @@
"react-dom": "^18.2.0",
"react-icons": "^4.4.0",
"react-loader-spinner": "5.4.5",
"starknet": "6.9.0",
"starknet": "^6.11.0",
"starknetid.js": "^4.0.1",
"starknetkit": "^2.3.2",
"starknetkit": "^2.3.0",
"tldts": "^6.1.20",
"twitter-api-sdk": "^1.2.1"
},
Expand Down
1 change: 1 addition & 0 deletions public/visuals/kepler_logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
13 changes: 13 additions & 0 deletions utils/connectorWrapper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ export const getConnectors = () => {
icons: ["https://app.starknet.id/visuals/StarknetIdLogo.svg"],
},
}),
new InjectedConnector({ options: { id: "keplr" } }),
new WebWalletConnector({
url: "https://web.argent.xyz/",
}),
Expand Down Expand Up @@ -162,4 +163,16 @@ const wallets = [
},
website: "https://www.okx.com/",
},
{
id: "keplr",
name: "Keplr Wallet",
icon: "/visuals/kepler_logo.svg",
downloads: {
chrome:
"https://chromewebstore.google.com/detail/keplr/dmkamcknogkgcdfhhbddcghachkejeap",
firefox: "https://addons.mozilla.org/en-US/firefox/addon/keplr/",
edge: "https://microsoftedge.microsoft.com/addons/detail/keplr/ocodgmmffbkkeecmadcijjhkmeohinei",
},
website: "https://www.keplr.app/",
},
];

0 comments on commit 48a64f8

Please sign in to comment.