Skip to content

Commit 7498426

Browse files
committed
Expose all Authereum init options
1 parent faacfb0 commit 7498426

File tree

3 files changed

+12
-10
lines changed

3 files changed

+12
-10
lines changed

src/interfaces.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,12 @@ interface TorusVerifierStatus {
210210
}
211211

212212
export interface AuthereumOptions extends CommonWalletOptions {
213+
apiKey?: string
213214
disableNotifications?: boolean
215+
rpcUri?: string
216+
webUri?: string
217+
xsUri?: string
218+
blockedPopupRedirect?: string
214219
}
215220

216221
export interface WalletLinkOptions extends CommonWalletOptions {

src/modules/select/wallets/authereum.ts

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,7 @@ import { WalletModule, AuthereumOptions } from '../../../interfaces'
55
function authereum(
66
options: AuthereumOptions & { networkId: number }
77
): WalletModule {
8-
const {
9-
networkId,
10-
preferred,
11-
label,
12-
iconSrc,
13-
svg,
14-
disableNotifications
15-
} = options
8+
const { networkId, preferred, label, iconSrc, svg, ...otherOptions } = options
169

1710
return {
1811
name: label || 'Authereum',
@@ -22,7 +15,7 @@ function authereum(
2215
const { default: Authereum } = await import('authereum')
2316
const instance = new Authereum({
2417
networkName: networkName(networkId),
25-
disableNotifications: disableNotifications // default: false
18+
...otherOptions
2619
})
2720

2821
const provider = instance.getProvider()

src/validation.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -614,7 +614,11 @@ export function validateWalletInit(
614614
'appName',
615615
'appLogoUrl',
616616
'enabledVerifiers',
617-
'disableNotifications'
617+
'disableNotifications',
618+
'rpcUri',
619+
'webUri',
620+
'xsUri',
621+
'blockedPopupRedirect'
618622
],
619623
'walletInitObject'
620624
)

0 commit comments

Comments
 (0)