added the network check
This commit is contained in:
@@ -1,18 +1,14 @@
|
||||
package `in`.sminnovations.attendanceapp.screens.home.ui.componets
|
||||
|
||||
import android.content.Context
|
||||
import android.net.ConnectivityManager
|
||||
import android.net.Network
|
||||
import androidx.lifecycle.LiveData
|
||||
import androidx.compose.foundation.layout.*
|
||||
import androidx.compose.material3.*
|
||||
import androidx.compose.runtime.*
|
||||
import androidx.compose.ui.Alignment
|
||||
import androidx.compose.foundation.layout.padding
|
||||
import androidx.compose.material3.AlertDialog
|
||||
import androidx.compose.material3.Button
|
||||
import androidx.compose.material3.Text
|
||||
import androidx.compose.runtime.Composable
|
||||
import androidx.compose.ui.Modifier
|
||||
import androidx.compose.ui.unit.dp
|
||||
|
||||
|
||||
|
||||
@Composable
|
||||
fun NetworkErrorDialog(
|
||||
showDialog: Boolean,
|
||||
@@ -25,7 +21,7 @@ fun NetworkErrorDialog(
|
||||
Text(text = "Network Error")
|
||||
},
|
||||
text = {
|
||||
Text(text = "Network is not connected. Please check your Wi-Fi or mobile data.")
|
||||
Text(text = "Network is not connected. Please check your Wi-Fi or mobile data.\n\nIf Wi-Fi is just connected wait for some time and press retry again")
|
||||
},
|
||||
confirmButton = {
|
||||
Button(
|
||||
|
||||
Reference in New Issue
Block a user