Withdrawals include zero-knowledge proof generation which can take up to 30 seconds. Show a loading indicator and inform users about the expected wait time.
// In a ViewModelviewModelScope.launch { _state.value = WithdrawState.Loading("Generating proof... This may take up to 30 seconds.") try { val result = withContext(Dispatchers.IO) { sdk.unshield( tokenAddress = tokenAddress, amount = amount, recipient = recipient ) } _state.value = WithdrawState.Success(result.txHash) } catch (e: SDKError) { _state.value = WithdrawState.Error(e) }}