forked from omni/OmniCards
refactor + feat: updated UI and added cards search logic
This commit is contained in:
@@ -12,6 +12,9 @@ import androidx.activity.result.contract.ActivityResultContracts
|
||||
import androidx.compose.foundation.layout.PaddingValues
|
||||
import androidx.compose.foundation.layout.fillMaxSize
|
||||
import androidx.compose.foundation.layout.fillMaxWidth
|
||||
import androidx.compose.material.icons.Icons
|
||||
import androidx.compose.material.icons.outlined.Save
|
||||
import androidx.compose.material.icons.outlined.Restore
|
||||
import androidx.compose.material3.AlertDialog
|
||||
import androidx.compose.material3.Scaffold
|
||||
import androidx.compose.material3.Text
|
||||
@@ -135,6 +138,7 @@ fun BackupPage(innerPadding: PaddingValues, getDbFun: () -> DbHelper) {
|
||||
Page(stringResource(R.string.backup), innerPadding) {
|
||||
AdaptiveButton(
|
||||
modifier = Modifier.fillMaxWidth(),
|
||||
icon = Icons.Outlined.Save,
|
||||
onClick = {
|
||||
createBackupLauncher.launch("omnicards-backup.json")
|
||||
}
|
||||
@@ -143,6 +147,7 @@ fun BackupPage(innerPadding: PaddingValues, getDbFun: () -> DbHelper) {
|
||||
}
|
||||
AdaptiveButton(
|
||||
modifier = Modifier.fillMaxWidth(),
|
||||
icon = Icons.Outlined.Restore,
|
||||
onClick = {
|
||||
restoreFromBackupLauncher.launch("application/json")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user