Skip to content

Commit

Permalink
[Crane] Change back arrow to be onSurface color (#762)
Browse files Browse the repository at this point in the history
  • Loading branch information
riggaroo authored Mar 28, 2022
1 parent 9bf90d0 commit 2b5c170
Showing 1 changed file with 7 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,19 +21,21 @@ import android.content.Intent
import android.os.Bundle
import androidx.activity.ComponentActivity
import androidx.activity.compose.setContent
import androidx.compose.foundation.Image
import androidx.compose.foundation.background
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.Spacer
import androidx.compose.foundation.layout.WindowInsets
import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.statusBars
import androidx.compose.foundation.layout.windowInsetsTopHeight
import androidx.compose.material.Icon
import androidx.compose.material.IconButton
import androidx.compose.material.MaterialTheme
import androidx.compose.material.Scaffold
import androidx.compose.material.Text
import androidx.compose.material.TopAppBar
import androidx.compose.material.icons.Icons
import androidx.compose.material.icons.filled.ArrowBack
import androidx.compose.runtime.Composable
import androidx.compose.samples.crane.R
import androidx.compose.samples.crane.calendar.model.CalendarDay
Expand All @@ -42,7 +44,6 @@ import androidx.compose.samples.crane.calendar.model.DaySelected
import androidx.compose.samples.crane.data.CalendarYear
import androidx.compose.samples.crane.ui.CraneTheme
import androidx.compose.ui.Modifier
import androidx.compose.ui.res.painterResource
import androidx.compose.ui.res.stringResource
import androidx.compose.ui.unit.dp
import androidx.core.view.WindowCompat
Expand Down Expand Up @@ -124,9 +125,10 @@ private fun CalendarTopAppBar(selectedDates: String, onBackPressed: () -> Unit)
},
navigationIcon = {
IconButton(onClick = { onBackPressed() }) {
Image(
painter = painterResource(R.drawable.ic_back),
contentDescription = stringResource(R.string.cd_back)
Icon(
imageVector = Icons.Default.ArrowBack,
contentDescription = stringResource(id = R.string.cd_back),
tint = MaterialTheme.colors.onSurface
)
}
},
Expand Down

0 comments on commit 2b5c170

Please sign in to comment.