Skip to content

Commit

Permalink
feat: seif wallet support (#2028)
Browse files Browse the repository at this point in the history
  • Loading branch information
dot-haechi authored Jun 13, 2024
1 parent 23e33b9 commit 7b00be5
Show file tree
Hide file tree
Showing 6 changed files with 48 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/tiny-houses-breathe.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@rainbow-me/rainbowkit": patch
---

Addes Seif Wallet support with `seifWallet` wallet connector
3 changes: 2 additions & 1 deletion packages/rainbowkit/src/types/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,8 @@ export type WalletProviderFlags =
| 'isCoin98'
| 'isMEWwallet'
| 'isSafeheron'
| 'isSafePal';
| 'isSafePal'
| '__seif';

export type WalletProvider = Evaluate<
EIP1193Provider & {
Expand Down
2 changes: 2 additions & 0 deletions packages/rainbowkit/src/wallets/walletConnectors/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ import { roninWallet } from './roninWallet/roninWallet';
import { safeWallet } from './safeWallet/safeWallet';
import { safeheronWallet } from './safeheronWallet/safeheronWallet';
import { safepalWallet } from './safepalWallet/safepalWallet';
import { seifWallet } from './seifWallet/seifWallet';
import { subWallet } from './subWallet/subWallet';
import { tahoWallet } from './tahoWallet/tahoWallet';
import { talismanWallet } from './talismanWallet/talismanWallet';
Expand Down Expand Up @@ -97,6 +98,7 @@ export {
safeWallet,
safeheronWallet,
safepalWallet,
seifWallet,
subWallet,
tahoWallet,
talismanWallet,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ function isMetaMask(ethereum?: WindowProvider['ethereum']): boolean {
if (ethereum.isXDEFI) return false;
if (ethereum.isZeal) return false;
if (ethereum.isZerion) return false;
if (ethereum.__seif) return false;
return true;
}

Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
import { Wallet } from '../../Wallet';
import {
getInjectedConnector,
hasInjectedProvider,
} from '../../getInjectedConnector';

export function seifWallet(): Wallet {
const injectedProvider = hasInjectedProvider({
namespace: '__seif',
});
return {
id: 'seif',
name: 'Seif',
installed: !!injectedProvider,
iconUrl: async () => (await import('./seifWallet.svg')).default,
iconBackground: '#fff',
downloadUrls: {
chrome:
'https://chromewebstore.google.com/detail/seif/albakdmmdafeafbehmcpoejenbeojejl',
},
createConnector: getInjectedConnector({
namespace: '__seif',
}),
rdns: 'com.passkeywallet.seif',
};
}

0 comments on commit 7b00be5

Please sign in to comment.