@@ -17,6 +17,7 @@ import {
1717 Web3AuthNoModalEvents ,
1818} from "@web3auth/base" ;
1919import { render } from "solid-js/web" ;
20+ import { ThemedContext } from "./context/ThemeContext" ;
2021
2122import { LoginModal as Modal } from "./components/LoginModal" ;
2223// import { ThemedContext } from "./context/ThemeContext";
@@ -34,7 +35,6 @@ import {
3435} from "./interfaces" ;
3536import i18n from "./localeImport" ;
3637import { getUserLanguage } from "./utils/modal" ;
37- import { Body } from "./components/Body" ;
3838
3939function createWrapper ( parentZIndex : string ) : HTMLElement {
4040 const existingWrapper = document . getElementById ( "w3a-parent-container" ) ;
@@ -208,17 +208,19 @@ export class LoginModal extends SafeEventEmitter {
208208
209209 render (
210210 ( ) =>
211- < Modal
212- closeModal = { this . closeModal }
213- stateListener = { this . stateEmitter }
214- handleShowExternalWallets = { this . handleShowExternalWallets }
215- handleExternalWalletClick = { this . handleExternalWalletClick }
216- handleSocialLoginClick = { this . handleSocialLoginClick }
217- appLogo = { darkState . isDark ? this . uiConfig . logoDark : this . uiConfig . logoLight }
218- appName = { this . uiConfig . appName }
219- chainNamespace = { this . chainNamespace }
220- walletRegistry = { this . walletRegistry }
221- /> ,
211+ < ThemedContext . Provider value = { darkState } >
212+ < Modal
213+ closeModal = { this . closeModal }
214+ stateListener = { this . stateEmitter }
215+ handleShowExternalWallets = { this . handleShowExternalWallets }
216+ handleExternalWalletClick = { this . handleExternalWalletClick }
217+ handleSocialLoginClick = { this . handleSocialLoginClick }
218+ appLogo = { darkState . isDark ? this . uiConfig . logoDark : this . uiConfig . logoLight }
219+ appName = { this . uiConfig . appName }
220+ chainNamespace = { this . chainNamespace }
221+ walletRegistry = { this . walletRegistry }
222+ />
223+ </ ThemedContext . Provider > ,
222224 root ! ) ;
223225
224226
@@ -316,7 +318,7 @@ export class LoginModal extends SafeEventEmitter {
316318 } ;
317319
318320 private subscribeCoreEvents = ( listener : SafeEventEmitter < Web3AuthNoModalEvents > ) => {
319- listener . on ( ADAPTER_EVENTS . CONNECTING , ( data ) => {
321+ listener . on ( ADAPTER_EVENTS . CONNECTING , ( data : any ) => {
320322 log . info ( "connecting with adapter" , data ) ;
321323 // don't show loader in case of wallet connect, because currently it listens for incoming for incoming
322324 // connections without any user interaction.
0 commit comments