diff --git a/app/src/main/java/com/example/tsundokun/ui/search/SearchScreen.kt b/app/src/main/java/com/example/tsundokun/ui/search/SearchScreen.kt index 9732b68..8c6f67d 100644 --- a/app/src/main/java/com/example/tsundokun/ui/search/SearchScreen.kt +++ b/app/src/main/java/com/example/tsundokun/ui/search/SearchScreen.kt @@ -45,12 +45,11 @@ fun SearchScreen(navigator: DestinationsNavigator) { var searchQuery by rememberSaveable { mutableStateOf(searchUiState.searchQuery) } var active by remember { mutableStateOf(false) } - Surface( modifier = Modifier.fillMaxSize(), color = MaterialTheme.colorScheme.background, ) { - Column{ + Column { SearchBar( query = searchQuery, onQueryChange = { newQuery -> searchQuery = newQuery }, @@ -70,7 +69,7 @@ fun SearchScreen(navigator: DestinationsNavigator) { Icon( imageVector = Filled.ArrowBack, contentDescription = stringResource(string.button_close), - modifier = Modifier.clickable { navigator.popBackStack() } + modifier = Modifier.clickable { navigator.popBackStack() }, ) }, trailingIcon = { @@ -88,4 +87,4 @@ fun SearchScreen(navigator: DestinationsNavigator) { ) } } -} \ No newline at end of file +} diff --git a/app/src/main/java/com/example/tsundokun/ui/search/SearchViewModel.kt b/app/src/main/java/com/example/tsundokun/ui/search/SearchViewModel.kt index cd53cf3..188292a 100644 --- a/app/src/main/java/com/example/tsundokun/ui/search/SearchViewModel.kt +++ b/app/src/main/java/com/example/tsundokun/ui/search/SearchViewModel.kt @@ -3,12 +3,10 @@ package com.example.tsundokun.ui.search import androidx.lifecycle.ViewModel import androidx.lifecycle.viewModelScope import com.example.tsundokun.core.model.Tsundoku -import com.example.tsundokun.data.local.dao.TsundokuDao import com.example.tsundokun.data.repository.TsundokuRepository import dagger.hilt.android.lifecycle.HiltViewModel import kotlinx.coroutines.flow.MutableStateFlow import kotlinx.coroutines.flow.asStateFlow -import kotlinx.coroutines.flow.filter import kotlinx.coroutines.flow.map import kotlinx.coroutines.launch import javax.inject.Inject @@ -42,4 +40,4 @@ class SearchViewModel @Inject constructor( var searchQuery: String = "", var searchResults: List = emptyList(), ) -} \ No newline at end of file +}