mirror of
https://github.com/omnivore-app/omnivore.git
synced 2026-03-11 08:54:26 +00:00
load bg colro of webview based on theme
This commit is contained in:
parent
9bd6b9409c
commit
0bd9df2ccf
2 changed files with 4 additions and 2 deletions
|
|
@ -17,8 +17,8 @@ android {
|
|||
applicationId "app.omnivore.omnivore"
|
||||
minSdk 26
|
||||
targetSdk 33
|
||||
versionCode 20
|
||||
versionName "0.0.20"
|
||||
versionCode 21
|
||||
versionName "0.0.21"
|
||||
|
||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||
vectorDrawables {
|
||||
|
|
|
|||
|
|
@ -109,6 +109,7 @@ fun WebReaderLoadingContainer(slug: String? = null, requestID: String? = null, o
|
|||
val toolbarHeightPx: Float by webReaderViewModel.currentToolbarHeightLiveData.observeAsState(0.0f)
|
||||
|
||||
val maxToolbarHeight = 48.dp
|
||||
val backgroundColor = if (isSystemInDarkTheme()) Color.Black else Color.White
|
||||
webReaderViewModel.maxToolbarHeightPx = with(LocalDensity.current) { maxToolbarHeight.roundToPx().toFloat() }
|
||||
webReaderViewModel.loadItem(slug = slug, requestID = requestID)
|
||||
|
||||
|
|
@ -116,6 +117,7 @@ fun WebReaderLoadingContainer(slug: String? = null, requestID: String? = null, o
|
|||
modifier = Modifier
|
||||
.fillMaxSize()
|
||||
.systemBarsPadding()
|
||||
.background(color = backgroundColor)
|
||||
) {
|
||||
if (webReaderParams != null) {
|
||||
WebReader(
|
||||
|
|
|
|||
Loading…
Reference in a new issue