Skip to content

Commit 0febfec

Browse files
committed
Removed extra configs
1 parent cfb0034 commit 0febfec

3 files changed

Lines changed: 6 additions & 156 deletions

File tree

docs/sdk/pnp/web/modal/modal-hooks.mdx

Lines changed: 1 addition & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -332,59 +332,10 @@ const web3AuthOptions: Web3AuthOptions = {
332332
clientId:
333333
"BPi5PB_UiIZ-cPz1GtV5i1I2iOSOHuimiXBI0e-Oe_u6X3oVAbCiAZOTEBtTXw4tsluTITPqA8zMsfxIKMjiqNQ",
334334
web3AuthNetwork: WEB3AUTH_NETWORK.SAPPHIRE_MAINNET,
335-
uiConfig: {
336-
uxMode: "redirect",
337-
appName: "W3A Heroes",
338-
appUrl: "https://web3auth.io/",
339-
theme: {
340-
primary: "#7ed6df",
341-
},
342-
logoLight: "https://web3auth.io/images/web3authlog.png",
343-
logoDark: "https://web3auth.io/images/web3authlogodark.png",
344-
defaultLanguage: "en", // en, de, ja, ko, zh, es, fr, pt, nl, tr
345-
mode: "auto", // whether to enable dark mode. defaultValue: auto
346-
useLogoLoader: true,
347-
},
348335
privateKeyProvider: privateKeyProvider,
349-
sessionTime: 86400, // 1 day
350336
};
351337

352-
const openloginAdapter = new OpenloginAdapter({
353-
loginSettings: {
354-
mfaLevel: "optional",
355-
},
356-
adapterSettings: {
357-
uxMode: "redirect", // "redirect" | "popup"
358-
whiteLabel: {
359-
logoLight: "https://web3auth.io/images/web3authlog.png",
360-
logoDark: "https://web3auth.io/images/web3authlogodark.png",
361-
defaultLanguage: "en", // en, de, ja, ko, zh, es, fr, pt, nl, tr
362-
mode: "dark", // whether to enable dark, light or auto mode. defaultValue: auto [ system theme]
363-
},
364-
mfaSettings: {
365-
deviceShareFactor: {
366-
enable: true,
367-
priority: 1,
368-
mandatory: true,
369-
},
370-
backUpShareFactor: {
371-
enable: true,
372-
priority: 2,
373-
mandatory: false,
374-
},
375-
socialBackupFactor: {
376-
enable: true,
377-
priority: 3,
378-
mandatory: false,
379-
},
380-
passwordFactor: {
381-
enable: true,
382-
priority: 4,
383-
mandatory: true,
384-
},
385-
},
386-
},
387-
});
338+
const openloginAdapter = new OpenloginAdapter();
388339

389340
const walletServicesPlugin = new WalletServicesPlugin({
390341
wsEmbedOpts: {},

docs/sdk/pnp/web/no-modal/no-modal-hooks.mdx

Lines changed: 4 additions & 56 deletions
Original file line numberDiff line numberDiff line change
@@ -306,8 +306,8 @@ following functions:
306306
### Example Usage
307307

308308
```typescript title="web3AuthProviderProps.ts"
309-
import { Web3AuthContextConfig } from "@web3auth/no-modal-react-hooks";
310-
import { Web3AuthNoModalOptions } from "@web3auth/no-modal";
309+
import { Web3AuthContextConfig } from "@web3auth/modal-react-hooks";
310+
import { Web3AuthOptions } from "@web3auth/modal";
311311
import { EthereumPrivateKeyProvider } from "@web3auth/ethereum-provider";
312312
import { CHAIN_NAMESPACES, WEB3AUTH_NETWORK } from "@web3auth/base";
313313
import { OpenloginAdapter } from "@web3auth/openlogin-adapter";
@@ -330,66 +330,14 @@ const privateKeyProvider = new EthereumPrivateKeyProvider({
330330
},
331331
});
332332

333-
const web3AuthOptions: Web3AuthNoModalOptions = {
333+
const web3AuthOptions: Web3AuthOptions = {
334334
clientId:
335335
"BPi5PB_UiIZ-cPz1GtV5i1I2iOSOHuimiXBI0e-Oe_u6X3oVAbCiAZOTEBtTXw4tsluTITPqA8zMsfxIKMjiqNQ",
336336
web3AuthNetwork: WEB3AUTH_NETWORK.SAPPHIRE_MAINNET,
337-
enableLogging: true,
338-
chainConfig,
339-
storageKey: "local",
340-
sessionTime: 86400, // 1 day
341337
privateKeyProvider: privateKeyProvider,
342-
uiConfig: {
343-
uxMode: "redirect",
344-
appName: "W3A Heroes",
345-
appUrl: "https://web3auth.io/",
346-
theme: {
347-
primary: "#7ed6df",
348-
},
349-
logoLight: "https://web3auth.io/images/web3authlog.png",
350-
logoDark: "https://web3auth.io/images/web3authlogodark.png",
351-
defaultLanguage: "en", // en, de, ja, ko, zh, es, fr, pt, nl, tr
352-
mode: "auto", // whether to enable dark mode. defaultValue: auto
353-
useLogoLoader: true,
354-
},
355338
};
356339

357-
const openloginAdapter = new OpenloginAdapter({
358-
loginSettings: {
359-
mfaLevel: "optional",
360-
},
361-
adapterSettings: {
362-
uxMode: "redirect", // "redirect" | "popup"
363-
whiteLabel: {
364-
logoLight: "https://web3auth.io/images/web3authlog.png",
365-
logoDark: "https://web3auth.io/images/web3authlogodark.png",
366-
defaultLanguage: "en", // en, de, ja, ko, zh, es, fr, pt, nl, tr
367-
mode: "dark", // whether to enable dark, light or auto mode. defaultValue: auto [ system theme]
368-
},
369-
mfaSettings: {
370-
deviceShareFactor: {
371-
enable: true,
372-
priority: 1,
373-
mandatory: true,
374-
},
375-
backUpShareFactor: {
376-
enable: true,
377-
priority: 2,
378-
mandatory: false,
379-
},
380-
socialBackupFactor: {
381-
enable: true,
382-
priority: 3,
383-
mandatory: false,
384-
},
385-
passwordFactor: {
386-
enable: true,
387-
priority: 4,
388-
mandatory: true,
389-
},
390-
},
391-
},
392-
});
340+
const openloginAdapter = new OpenloginAdapter();
393341

394342
const walletServicesPlugin = new WalletServicesPlugin({
395343
wsEmbedOpts: {},

docs/sdk/wallet-services/wallet-services-hooks.mdx

Lines changed: 1 addition & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -146,59 +146,10 @@ const web3AuthOptions: Web3AuthOptions = {
146146
clientId:
147147
"BPi5PB_UiIZ-cPz1GtV5i1I2iOSOHuimiXBI0e-Oe_u6X3oVAbCiAZOTEBtTXw4tsluTITPqA8zMsfxIKMjiqNQ",
148148
web3AuthNetwork: WEB3AUTH_NETWORK.SAPPHIRE_MAINNET,
149-
uiConfig: {
150-
uxMode: "redirect",
151-
appName: "W3A Heroes",
152-
appUrl: "https://web3auth.io/",
153-
theme: {
154-
primary: "#7ed6df",
155-
},
156-
logoLight: "https://web3auth.io/images/web3authlog.png",
157-
logoDark: "https://web3auth.io/images/web3authlogodark.png",
158-
defaultLanguage: "en", // en, de, ja, ko, zh, es, fr, pt, nl, tr
159-
mode: "auto", // whether to enable dark mode. defaultValue: auto
160-
useLogoLoader: true,
161-
},
162149
privateKeyProvider: privateKeyProvider,
163-
sessionTime: 86400, // 1 day
164150
};
165151

166-
const openloginAdapter = new OpenloginAdapter({
167-
loginSettings: {
168-
mfaLevel: "optional",
169-
},
170-
adapterSettings: {
171-
uxMode: "redirect", // "redirect" | "popup"
172-
whiteLabel: {
173-
logoLight: "https://web3auth.io/images/web3authlog.png",
174-
logoDark: "https://web3auth.io/images/web3authlogodark.png",
175-
defaultLanguage: "en", // en, de, ja, ko, zh, es, fr, pt, nl, tr
176-
mode: "dark", // whether to enable dark, light or auto mode. defaultValue: auto [ system theme]
177-
},
178-
mfaSettings: {
179-
deviceShareFactor: {
180-
enable: true,
181-
priority: 1,
182-
mandatory: true,
183-
},
184-
backUpShareFactor: {
185-
enable: true,
186-
priority: 2,
187-
mandatory: false,
188-
},
189-
socialBackupFactor: {
190-
enable: true,
191-
priority: 3,
192-
mandatory: false,
193-
},
194-
passwordFactor: {
195-
enable: true,
196-
priority: 4,
197-
mandatory: true,
198-
},
199-
},
200-
},
201-
});
152+
const openloginAdapter = new OpenloginAdapter();
202153

203154
const walletServicesPlugin = new WalletServicesPlugin({
204155
wsEmbedOpts: {},

0 commit comments

Comments
 (0)