Optionaloptions: TonConnectUiCreateOptionsReadonlyconnectionReadonlyconnectorTonConnect instance.
ReadonlymodalManages the modal window state.
Current connected account or null.
Current connection status.
Returns current modal window state.
ExperimentalReturns current single wallet modal window state.
Set and apply new UI options. Object with partial options should be passed. Passed options will be merged with current options.
Curren connected wallet app and its info or null.
ExperimentalClose the single wallet modal window.
OptionalcloseReason: WalletsModalCloseReasonConnected wallet.
Disconnect wallet and clean localstorage.
Returns available wallets list.
Subscribe to the modal window state changes, returns a function which has to be called to unsubscribe.
ExperimentalSubscribe to the single wallet modal window state changes, returns a function which has to be called to unsubscribe.
Subscribe to connection status change.
OptionalerrorsHandler: (err: TonConnectError) => voidfunction which has to be called to unsubscribe.
Opens the modal window, returns a promise that resolves after the modal window is opened.
ExperimentalOpens the single wallet modal window, returns a promise that resolves after the modal window is opened.
Opens the modal window and handles the transaction sending.
transaction to send.
Optionaloptions: ActionConfiguration & { onRequestSent?: (redirectToWallet: () => void) => void }modal and notifications behaviour settings. Default is show only 'before' modal and all notifications.
Use it to customize ConnectRequest and add tonProof payload.
You can call it multiply times to set updated tonProof payload if previous one is outdated.
If connectRequestParameters.state === 'loading' loader will appear instead of the qr code in the wallets modal.
If connectRequestParameters.state was changed to 'ready' or it's value has been changed, QR will be re-rendered.
Signs the data and returns the signature.
data to sign.
Optionaloptions: { onRequestSent?: (redirectToWallet: () => void) => void }Staticget
Promise that resolves after end of th connection restoring process (promise will fire after
onStatusChange, so you can get actual information about wallet and session after when promise resolved). Resolved valuetrue/falseindicates if the session was restored successfully.