mirror of https://github.com/Ashinch/ReadYou.git
Add navigationBarsPadding
This commit is contained in:
parent
c1a4c8ec5b
commit
1631c0b6a5
|
@ -1,7 +1,9 @@
|
||||||
package me.ash.reader.ui.page.home
|
package me.ash.reader.ui.page.home
|
||||||
|
|
||||||
import android.view.SoundEffectConstants
|
import android.view.SoundEffectConstants
|
||||||
|
import androidx.compose.foundation.background
|
||||||
import androidx.compose.foundation.layout.Spacer
|
import androidx.compose.foundation.layout.Spacer
|
||||||
|
import androidx.compose.foundation.layout.navigationBarsPadding
|
||||||
import androidx.compose.foundation.layout.width
|
import androidx.compose.foundation.layout.width
|
||||||
import androidx.compose.material3.*
|
import androidx.compose.material3.*
|
||||||
import androidx.compose.runtime.Composable
|
import androidx.compose.runtime.Composable
|
||||||
|
@ -12,6 +14,7 @@ import com.google.accompanist.pager.ExperimentalPagerApi
|
||||||
import me.ash.reader.data.entity.Filter
|
import me.ash.reader.data.entity.Filter
|
||||||
import me.ash.reader.data.preference.FlowFilterBarStylePreference
|
import me.ash.reader.data.preference.FlowFilterBarStylePreference
|
||||||
import me.ash.reader.ui.ext.getName
|
import me.ash.reader.ui.ext.getName
|
||||||
|
import me.ash.reader.ui.ext.surfaceColorAtElevation
|
||||||
import me.ash.reader.ui.theme.palette.onDark
|
import me.ash.reader.ui.theme.palette.onDark
|
||||||
|
|
||||||
@OptIn(ExperimentalPagerApi::class)
|
@OptIn(ExperimentalPagerApi::class)
|
||||||
|
@ -28,6 +31,9 @@ fun FilterBar(
|
||||||
val view = LocalView.current
|
val view = LocalView.current
|
||||||
|
|
||||||
NavigationBar(
|
NavigationBar(
|
||||||
|
modifier = Modifier
|
||||||
|
.background(MaterialTheme.colorScheme.surfaceColorAtElevation(filterBarTonalElevation))
|
||||||
|
.navigationBarsPadding(),
|
||||||
tonalElevation = filterBarTonalElevation,
|
tonalElevation = filterBarTonalElevation,
|
||||||
) {
|
) {
|
||||||
Spacer(modifier = Modifier.width(filterBarPadding))
|
Spacer(modifier = Modifier.width(filterBarPadding))
|
||||||
|
|
|
@ -128,8 +128,7 @@ fun FeedsPage(
|
||||||
Scaffold(
|
Scaffold(
|
||||||
modifier = Modifier
|
modifier = Modifier
|
||||||
.background(MaterialTheme.colorScheme.surfaceColorAtElevation(topBarTonalElevation.value.dp))
|
.background(MaterialTheme.colorScheme.surfaceColorAtElevation(topBarTonalElevation.value.dp))
|
||||||
.statusBarsPadding()
|
.statusBarsPadding(),
|
||||||
.navigationBarsPadding(),
|
|
||||||
containerColor = MaterialTheme.colorScheme.surfaceColorAtElevation(
|
containerColor = MaterialTheme.colorScheme.surfaceColorAtElevation(
|
||||||
groupListTonalElevation.value.dp
|
groupListTonalElevation.value.dp
|
||||||
) onDark MaterialTheme.colorScheme.surface,
|
) onDark MaterialTheme.colorScheme.surface,
|
||||||
|
|
|
@ -109,8 +109,7 @@ fun FlowPage(
|
||||||
Scaffold(
|
Scaffold(
|
||||||
modifier = Modifier
|
modifier = Modifier
|
||||||
.background(MaterialTheme.colorScheme.surfaceColorAtElevation(topBarTonalElevation.value.dp))
|
.background(MaterialTheme.colorScheme.surfaceColorAtElevation(topBarTonalElevation.value.dp))
|
||||||
.statusBarsPadding()
|
.statusBarsPadding(),
|
||||||
.navigationBarsPadding(),
|
|
||||||
containerColor = MaterialTheme.colorScheme.surfaceColorAtElevation(
|
containerColor = MaterialTheme.colorScheme.surfaceColorAtElevation(
|
||||||
articleListTonalElevation.value.dp
|
articleListTonalElevation.value.dp
|
||||||
) onDark MaterialTheme.colorScheme.surface,
|
) onDark MaterialTheme.colorScheme.surface,
|
||||||
|
|
Loading…
Reference in New Issue