Skip to content

Commit

Permalink
Update dependency dev.chrisbanes.haze:haze to v0.4.1 (#1135)
Browse files Browse the repository at this point in the history
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [dev.chrisbanes.haze:haze](https://togithub.com/chrisbanes/haze) |
`0.3.1` -> `0.4.1` |
[![age](https://developer.mend.io/api/mc/badges/age/maven/dev.chrisbanes.haze:haze/0.4.1?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/maven/dev.chrisbanes.haze:haze/0.4.1?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/maven/dev.chrisbanes.haze:haze/0.3.1/0.4.1?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/maven/dev.chrisbanes.haze:haze/0.3.1/0.4.1?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

<details>
<summary>chrisbanes/haze (dev.chrisbanes.haze:haze)</summary>

### [`v0.4.1`](https://togithub.com/chrisbanes/haze/releases/tag/0.4.1)

[Compare
Source](https://togithub.com/chrisbanes/haze/compare/0.4.0...0.4.1)

#### What's Changed

- Apply Jetpack Compose Shape to HazeChild.kt on init by
[@&#8203;almozavr](https://togithub.com/almozavr) in
[https://github.com/chrisbanes/haze/pull/55](https://togithub.com/chrisbanes/haze/pull/55)
- Port [#&#8203;55](https://togithub.com/chrisbanes/haze/issues/55) to
:haze by [@&#8203;chrisbanes](https://togithub.com/chrisbanes) in
[https://github.com/chrisbanes/haze/pull/56](https://togithub.com/chrisbanes/haze/pull/56)

#### New Contributors

- [@&#8203;almozavr](https://togithub.com/almozavr) made their first
contribution in
[https://github.com/chrisbanes/haze/pull/55](https://togithub.com/chrisbanes/haze/pull/55)

**Full Changelog**:
chrisbanes/haze@0.4.0...0.4.1

### [`v0.4.0`](https://togithub.com/chrisbanes/haze/releases/tag/0.4.0)

[Compare
Source](https://togithub.com/chrisbanes/haze/compare/0.3.1...0.4.0)

#### New API!

I have broken the existing API, but hopefully you can see why. You no
longer need to manually calculate bounds. `HazeState` +
`Modifier.haze()` + `Modifier.hazeChild()` is all you need.

```kotlin
val hazeState = remember { HazeState() } 

Box {
  LazyColumn(
    modifier = Modifier
      .fillMaxSize()
      .haze(
        // Pass it the HazeState we stored above
        state = hazeState,
        // Need to provide background color of the content
        backgroundColor = MaterialTheme.colorScheme.surface,
      ),
  ) {
    // todo
  }

  Text(
    text = "Content will be blurred behind this",
    modifier = Modifier
      // We use hazeChild on anything where we want the background
      // blurred. We can even provide a shape.
      .hazeChild(
        state = hazeState,
        shape = RoundedCornerShape(16.dp),
      ),
  )
}
```

#### What's Changed

- Update dependency androidx.compose.ui:ui to v1.6.0-beta01 by
[@&#8203;renovate](https://togithub.com/renovate) in
[https://github.com/chrisbanes/haze/pull/34](https://togithub.com/chrisbanes/haze/pull/34)
- Update agp to v8.1.4 by
[@&#8203;renovate](https://togithub.com/renovate) in
[https://github.com/chrisbanes/haze/pull/35](https://togithub.com/chrisbanes/haze/pull/35)
- Update dependency androidx.compose.material3:material3 to
v1.2.0-alpha11 by [@&#8203;renovate](https://togithub.com/renovate) in
[https://github.com/chrisbanes/haze/pull/33](https://togithub.com/chrisbanes/haze/pull/33)
- Update dependency androidx.activity:activity-compose to v1.8.1 by
[@&#8203;renovate](https://togithub.com/renovate) in
[https://github.com/chrisbanes/haze/pull/32](https://togithub.com/chrisbanes/haze/pull/32)
- Update plugin metalava to v0.3.5 by
[@&#8203;renovate](https://togithub.com/renovate) in
[https://github.com/chrisbanes/haze/pull/29](https://togithub.com/chrisbanes/haze/pull/29)
- Update to Kotlin 1.9.20 by
[@&#8203;chrisbanes](https://togithub.com/chrisbanes) in
[https://github.com/chrisbanes/haze/pull/27](https://togithub.com/chrisbanes/haze/pull/27)
- Update compose.multiplatform to v1.5.11 by
[@&#8203;renovate](https://togithub.com/renovate) in
[https://github.com/chrisbanes/haze/pull/38](https://togithub.com/chrisbanes/haze/pull/38)
- Update spotless to v6.23.0 by
[@&#8203;renovate](https://togithub.com/renovate) in
[https://github.com/chrisbanes/haze/pull/39](https://togithub.com/chrisbanes/haze/pull/39)
- Update actions/setup-java action to v4 by
[@&#8203;renovate](https://togithub.com/renovate) in
[https://github.com/chrisbanes/haze/pull/41](https://togithub.com/chrisbanes/haze/pull/41)
- Update dependency gradle to v8.5 by
[@&#8203;renovate](https://togithub.com/renovate) in
[https://github.com/chrisbanes/haze/pull/40](https://togithub.com/chrisbanes/haze/pull/40)
- Update dependency com.diffplug.spotless to v6.23.2 by
[@&#8203;renovate](https://togithub.com/renovate) in
[https://github.com/chrisbanes/haze/pull/44](https://togithub.com/chrisbanes/haze/pull/44)
- Update spotless to v6.23.3 by
[@&#8203;renovate](https://togithub.com/renovate) in
[https://github.com/chrisbanes/haze/pull/46](https://togithub.com/chrisbanes/haze/pull/46)
- Update agp to v8.2.0 by
[@&#8203;renovate](https://togithub.com/renovate) in
[https://github.com/chrisbanes/haze/pull/45](https://togithub.com/chrisbanes/haze/pull/45)
- Update dependency androidx.compose.material3:material3 to
v1.2.0-alpha12 by [@&#8203;renovate](https://togithub.com/renovate) in
[https://github.com/chrisbanes/haze/pull/42](https://togithub.com/chrisbanes/haze/pull/42)
- Update dependency androidx.compose.ui:ui to v1.6.0-beta02 by
[@&#8203;renovate](https://togithub.com/renovate) in
[https://github.com/chrisbanes/haze/pull/43](https://togithub.com/chrisbanes/haze/pull/43)
- Update actions/setup-python action to v5 by
[@&#8203;renovate](https://togithub.com/renovate) in
[https://github.com/chrisbanes/haze/pull/50](https://togithub.com/chrisbanes/haze/pull/50)
- Update plugin com.gradle.enterprise to v3.16 by
[@&#8203;renovate](https://togithub.com/renovate) in
[https://github.com/chrisbanes/haze/pull/49](https://togithub.com/chrisbanes/haze/pull/49)
- Update actions/deploy-pages action to v3 by
[@&#8203;renovate](https://togithub.com/renovate) in
[https://github.com/chrisbanes/haze/pull/48](https://togithub.com/chrisbanes/haze/pull/48)
- Update actions/configure-pages action to v4 by
[@&#8203;renovate](https://togithub.com/renovate) in
[https://github.com/chrisbanes/haze/pull/47](https://togithub.com/chrisbanes/haze/pull/47)
- API refactor by [@&#8203;chrisbanes](https://togithub.com/chrisbanes)
in
[https://github.com/chrisbanes/haze/pull/36](https://togithub.com/chrisbanes/haze/pull/36)
- Fix position issue by
[@&#8203;MohamedRejeb](https://togithub.com/MohamedRejeb) in
[https://github.com/chrisbanes/haze/pull/52](https://togithub.com/chrisbanes/haze/pull/52)
- Small API tidy-ups by
[@&#8203;chrisbanes](https://togithub.com/chrisbanes) in
[https://github.com/chrisbanes/haze/pull/53](https://togithub.com/chrisbanes/haze/pull/53)
- More API tweaks by
[@&#8203;chrisbanes](https://togithub.com/chrisbanes) in
[https://github.com/chrisbanes/haze/pull/54](https://togithub.com/chrisbanes/haze/pull/54)

**Full Changelog**:
chrisbanes/haze@0.3.1...0.4.0

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/ZacSweers/CatchUp).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy44Ny4yIiwidXBkYXRlZEluVmVyIjoiMzcuOTMuMSIsInRhcmdldEJyYW5jaCI6Im1haW4ifQ==-->

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Zac Sweers <[email protected]>
  • Loading branch information
renovate[bot] and ZacSweers authored Dec 16, 2023
1 parent 5aea8fd commit f36e170
Show file tree
Hide file tree
Showing 9 changed files with 142 additions and 108 deletions.
12 changes: 6 additions & 6 deletions app-scaffold/src/main/kotlin/catchup/app/home/HomeScreen.kt
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ import catchup.app.service.ServiceScreen
import catchup.app.service.bookmarks.Bookmark
import catchup.app.service.bookmarks.BookmarksScreen
import catchup.app.ui.activity.SettingsScreen
import catchup.base.ui.CatchUpScaffold
import catchup.base.ui.HazeScaffold
import catchup.base.ui.rememberSystemBarColorController
import catchup.bookmarks.BookmarkRepository
import catchup.compose.LocalDisplayFeatures
Expand Down Expand Up @@ -102,7 +102,7 @@ import dagger.assisted.Assisted
import dagger.assisted.AssistedFactory
import dagger.assisted.AssistedInject
import dagger.multibindings.StringKey
import dev.zacsweers.catchup.app.scaffold.R
import dev.zacsweers.catchup.app.scaffold.R as AppScaffoldR
import kotlin.math.absoluteValue
import kotlin.math.sign
import kotlinx.collections.immutable.ImmutableList
Expand Down Expand Up @@ -266,7 +266,7 @@ fun Home(state: State, modifier: Modifier = Modifier) {
// Embed the content in a scaffold for padding and such
val meta = state.serviceMetas[state.selectedIndex]
val scrollBehavior = TopAppBarDefaults.exitUntilCollapsedScrollBehavior()
CatchUpScaffold(
HazeScaffold(
modifier = Modifier.nestedScroll(scrollBehavior.nestedScrollConnection),
contentWindowInsets = WindowInsets(0, 0, 0, 0),
containerColor = Color.Transparent,
Expand Down Expand Up @@ -380,7 +380,7 @@ fun HomePager(state: State, modifier: Modifier = Modifier) {
}
val serviceMetas by rememberUpdatedState(state.serviceMetas)
val eventSink by rememberUpdatedState(state.eventSink)
CatchUpScaffold(
HazeScaffold(
modifier = nestedScrollModifier,
contentWindowInsets = WindowInsets(0, 0, 0, 0),
containerColor = Color.Transparent,
Expand Down Expand Up @@ -555,8 +555,8 @@ internal fun ChangelogButton(modifier: Modifier = Modifier, onClick: () -> Unit)
modifier = modifier,
) {
Icon(
imageVector = ImageVector.vectorResource(R.drawable.baseline_redeem_24),
contentDescription = stringResource(R.string.changes),
imageVector = ImageVector.vectorResource(AppScaffoldR.drawable.baseline_redeem_24),
contentDescription = stringResource(AppScaffoldR.string.changes),
)
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ import androidx.compose.material.icons.filled.Delete
import androidx.compose.material.icons.filled.Share
import androidx.compose.material3.DismissDirection.EndToStart
import androidx.compose.material3.DismissDirection.StartToEnd
import androidx.compose.material3.DismissValue.Default
import androidx.compose.material3.DismissValue.DismissedToStart
import androidx.compose.material3.ExperimentalMaterial3Api
import androidx.compose.material3.Icon
Expand Down Expand Up @@ -56,7 +55,7 @@ import catchup.app.service.bookmarks.BookmarksScreen.Event.Click
import catchup.app.service.bookmarks.BookmarksScreen.Event.Remove
import catchup.app.service.bookmarks.BookmarksScreen.Event.Share
import catchup.base.ui.BackPressNavButton
import catchup.base.ui.CatchUpScaffold
import catchup.base.ui.HazeScaffold
import catchup.bookmarks.BookmarkRepository
import catchup.compose.rememberStableCoroutineScope
import catchup.deeplink.DeepLinkable
Expand Down Expand Up @@ -192,7 +191,7 @@ constructor(
@OptIn(ExperimentalMaterial3Api::class)
@Composable
fun Bookmarks(state: BookmarksScreen.State, modifier: Modifier = Modifier) {
CatchUpScaffold(
HazeScaffold(
modifier = modifier,
contentWindowInsets = WindowInsets(0, 0, 0, 0),
containerColor = Color.Transparent,
Expand Down
10 changes: 5 additions & 5 deletions app-scaffold/src/main/kotlin/catchup/app/ui/about/AboutScreen.kt
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import androidx.compose.ui.res.stringResource
import catchup.app.ui.about.AboutScreen.AboutScreenComponent
import catchup.app.ui.about.AboutScreen.State
import catchup.appconfig.AppConfig
import catchup.base.ui.CatchUpScaffold
import catchup.base.ui.HazeScaffold
import catchup.compose.rememberStableCoroutineScope
import catchup.deeplink.DeepLinkable
import catchup.di.AppScope
Expand All @@ -35,7 +35,7 @@ import dagger.assisted.Assisted
import dagger.assisted.AssistedFactory
import dagger.assisted.AssistedInject
import dagger.multibindings.StringKey
import dev.zacsweers.catchup.app.scaffold.R
import dev.zacsweers.catchup.app.scaffold.R as AppScaffoldR
import java.util.Locale
import kotlinx.collections.immutable.ImmutableMap
import kotlinx.collections.immutable.toImmutableList
Expand Down Expand Up @@ -63,8 +63,8 @@ data class AboutScreen(val selectedTab: AboutScreenComponent = AboutScreenCompon
val screen: Screen,
@StringRes val titleRes: Int,
) {
Licenses(LicensesScreen, R.string.licenses),
Changelog(ChangelogScreen, R.string.changelog);
Licenses(LicensesScreen, AppScaffoldR.string.licenses),
Changelog(ChangelogScreen, AppScaffoldR.string.changelog);

companion object {
internal val DEFAULT = Licenses
Expand Down Expand Up @@ -100,7 +100,7 @@ constructor(@Assisted val screen: AboutScreen, private val appConfig: AppConfig)
@CircuitInject(AboutScreen::class, AppScope::class)
@Composable
fun About(state: State, modifier: Modifier = Modifier) {
CatchUpScaffold(
HazeScaffold(
containerColor = Color.Transparent,
contentWindowInsets = WindowInsets(0, 0, 0, 0),
blurTopBar = true,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ import catchup.app.ui.activity.OrderServicesScreen.Event.Save
import catchup.app.ui.activity.OrderServicesScreen.Event.Shuffle
import catchup.app.ui.activity.OrderServicesScreen.State
import catchup.base.ui.BackPressNavButton
import catchup.base.ui.CatchUpScaffold
import catchup.base.ui.HazeScaffold
import catchup.compose.DraggableItem
import catchup.compose.dragContainer
import catchup.compose.rememberDragDropState
Expand All @@ -96,7 +96,7 @@ import com.slack.circuit.runtime.screen.Screen
import dagger.assisted.Assisted
import dagger.assisted.AssistedFactory
import dagger.assisted.AssistedInject
import dev.zacsweers.catchup.app.scaffold.R
import dev.zacsweers.catchup.app.scaffold.R as AppScaffoldR
import kotlinx.collections.immutable.toImmutableList
import kotlinx.coroutines.launch
import kotlinx.parcelize.Parcelize
Expand Down Expand Up @@ -224,10 +224,10 @@ fun OrderServices(state: State, modifier: Modifier = Modifier) {
val result =
overlayHost.show(
DialogOverlay(
title = { Text(stringResource(R.string.pending_changes_title)) },
text = { Text(stringResource(R.string.pending_changes_message)) },
confirmButtonText = { Text(stringResource(R.string.save)) },
dismissButtonText = { Text(stringResource(R.string.dontsave)) }
title = { Text(stringResource(AppScaffoldR.string.pending_changes_title)) },
text = { Text(stringResource(AppScaffoldR.string.pending_changes_message)) },
confirmButtonText = { Text(stringResource(AppScaffoldR.string.save)) },
dismissButtonText = { Text(stringResource(AppScaffoldR.string.dontsave)) }
)
)
when (result) {
Expand All @@ -243,22 +243,22 @@ fun OrderServices(state: State, modifier: Modifier = Modifier) {
}
}
}
CatchUpScaffold(
HazeScaffold(
modifier = modifier,
blurTopBar = true,
blurBottomBar = true,
topBar = {
TopAppBar(
title = { Text(stringResource(id = R.string.pref_reorder_services)) },
title = { Text(stringResource(id = AppScaffoldR.string.pref_reorder_services)) },
navigationIcon = { BackPressNavButton() },
colors = TopAppBarDefaults.topAppBarColors(containerColor = Color.Transparent),
actions = {
IconButton(
onClick = { state.eventSink(Shuffle) },
content = {
Icon(
painter = painterResource(R.drawable.ic_shuffle_black_24dp),
contentDescription = stringResource(R.string.shuffle),
painter = painterResource(AppScaffoldR.drawable.ic_shuffle_black_24dp),
contentDescription = stringResource(AppScaffoldR.string.shuffle),
)
}
)
Expand Down Expand Up @@ -290,12 +290,12 @@ fun OrderServices(state: State, modifier: Modifier = Modifier) {
// .onGloballyPositioned { coordinates ->
// val (x, y) = coordinates.positionInRoot()
// },
containerColor = colorResource(R.color.colorAccent),
containerColor = colorResource(AppScaffoldR.color.colorAccent),
onClick = { scope.launch { state.eventSink(Save) } },
content = {
Image(
painterResource(R.drawable.ic_save_black_24dp),
stringResource(R.string.save),
painterResource(AppScaffoldR.drawable.ic_save_black_24dp),
stringResource(AppScaffoldR.string.save),
colorFilter = ColorFilter.tint(Color.White)
)
}
Expand Down Expand Up @@ -344,7 +344,7 @@ private fun ServiceListItem(item: ServiceMeta) {
) {
Image(
painter = painterResource(item.icon),
contentDescription = stringResource(R.string.service_icon),
contentDescription = stringResource(AppScaffoldR.string.service_icon),
modifier = Modifier.width(40.dp).height(40.dp)
)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ import catchup.app.ui.activity.SettingsScreen.Event.NavToScreen
import catchup.app.ui.activity.SettingsScreen.State
import catchup.app.util.restartApp
import catchup.base.ui.BackPressNavButton
import catchup.base.ui.CatchUpScaffold
import catchup.base.ui.HazeScaffold
import catchup.compose.ContentAlphas
import catchup.compose.DisableableContent
import catchup.compose.LocalEnabled
Expand All @@ -71,7 +71,7 @@ import dagger.assisted.Assisted
import dagger.assisted.AssistedFactory
import dagger.assisted.AssistedInject
import dagger.multibindings.StringKey
import dev.zacsweers.catchup.app.scaffold.R
import dev.zacsweers.catchup.app.scaffold.R as AppScaffoldR
import javax.inject.Inject
import kotlinx.collections.immutable.ImmutableMap
import kotlinx.coroutines.Dispatchers
Expand Down Expand Up @@ -129,10 +129,10 @@ constructor(
// TODO circuit-ify this
Snackbar.make(
view,
appContext.getString(R.string.settings_reset),
appContext.getString(AppScaffoldR.string.settings_reset),
Snackbar.LENGTH_INDEFINITE
)
.setAction(R.string.restart) { appContext.restartApp() }
.setAction(AppScaffoldR.string.restart) { appContext.restartApp() }
.show()
}
}
Expand All @@ -146,15 +146,15 @@ constructor(
try {
val cleanedAmount = clearCache()
appContext.getString(
R.string.clear_cache_success,
AppScaffoldR.string.clear_cache_success,
BinaryByteUnit.format(cleanedAmount)
)
} catch (e: Exception) {
appContext.getString(R.string.settings_error_cleaning_cache)
appContext.getString(AppScaffoldR.string.settings_error_cleaning_cache)
}
// TODO circuit-ify this
Snackbar.make(view, message, Snackbar.LENGTH_INDEFINITE)
.setAction(R.string.restart) { appContext.restartApp() }
.setAction(AppScaffoldR.string.restart) { appContext.restartApp() }
.show()
}
}
Expand Down Expand Up @@ -226,15 +226,15 @@ constructor(
@OptIn(ExperimentalFoundationApi::class)
@Composable
override fun Content(state: State, modifier: Modifier) {
CatchUpScaffold(
HazeScaffold(
modifier = modifier,
contentWindowInsets = WindowInsets(0, 0, 0, 0),
containerColor = Color.Transparent,
blurTopBar = true,
blurBottomBar = true,
topBar = {
TopAppBar(
title = { Text(stringResource(R.string.title_activity_settings)) },
title = { Text(stringResource(AppScaffoldR.string.title_activity_settings)) },
navigationIcon = { BackPressNavButton() },
colors = TopAppBarDefaults.topAppBarColors(containerColor = Color.Transparent),
)
Expand All @@ -244,55 +244,58 @@ constructor(
modifier = Modifier.fillMaxSize().padding(innerPadding).consumeWindowInsets(innerPadding)
) {
stickyHeader(key = "general_header") {
ComposableHeaderItem(stringResource(R.string.general), displayDivider = false)
ComposableHeaderItem(stringResource(AppScaffoldR.string.general), displayDivider = false)
}
item(key = "smart_linking") {
BooleanPreference(
key = CatchUpPreferences.Keys.smartlinkingGlobal,
defaultValue = true,
title = stringResource(R.string.pref_smart_linking_title),
subtitle = stringResource(R.string.pref_smart_linking_summary),
title = stringResource(AppScaffoldR.string.pref_smart_linking_title),
subtitle = stringResource(AppScaffoldR.string.pref_smart_linking_summary),
)
}

item(key = "reorder_services") {
ClickablePreference(
title = stringResource(R.string.pref_reorder_services),
subtitle = stringResource(R.string.pref_order_services_description)
title = stringResource(AppScaffoldR.string.pref_reorder_services),
subtitle = stringResource(AppScaffoldR.string.pref_order_services_description)
) {
state.eventSink(NavToScreen(OrderServicesScreen))
}
}

item(key = "clear_cache") {
ClickablePreference(
title = stringResource(R.string.pref_clear_cache),
subtitle = stringResource(R.string.pref_clear_cache_summary),
title = stringResource(AppScaffoldR.string.pref_clear_cache),
subtitle = stringResource(AppScaffoldR.string.pref_clear_cache_summary),
) {
state.eventSink(ClearCache)
}
}

stickyHeader(key = "theming_header") {
ComposableHeaderItem(stringResource(R.string.prefs_theme), displayDivider = true)
ComposableHeaderItem(
stringResource(AppScaffoldR.string.prefs_theme),
displayDivider = true
)
}

item(key = "dynamic_theme") {
BooleanPreference(
key = CatchUpPreferences.Keys.dynamicTheme,
modifier = Modifier.animateContentSize(),
defaultValue = false,
title = stringResource(R.string.pref_dynamic_theme_title),
subtitle = stringResource(R.string.pref_dynamic_theme_summary),
title = stringResource(AppScaffoldR.string.pref_dynamic_theme_title),
subtitle = stringResource(AppScaffoldR.string.pref_dynamic_theme_summary),
)
}

item(key = "auto_theme") {
BooleanPreference(
key = CatchUpPreferences.Keys.dayNightAuto,
defaultValue = true,
title = stringResource(R.string.pref_auto_set_theme),
subtitle = stringResource(R.string.pref_auto_set_theme_summary),
title = stringResource(AppScaffoldR.string.pref_auto_set_theme),
subtitle = stringResource(AppScaffoldR.string.pref_auto_set_theme_summary),
)
}
item(key = "force_night") {
Expand All @@ -304,14 +307,14 @@ constructor(
key = Keys.dayNightForceNight,
modifier = Modifier.animateContentSize(), // Because the summary changes
defaultValue = false,
title = stringResource(R.string.pref_force_dark_theme),
title = stringResource(AppScaffoldR.string.pref_force_dark_theme),
subtitle =
if (!LocalEnabled.current) {
stringResource(R.string.pref_dark_theme_disabled_auto)
stringResource(AppScaffoldR.string.pref_dark_theme_disabled_auto)
} else if (forceNightValue) {
stringResource(R.string.pref_dark_theme_enabled)
stringResource(AppScaffoldR.string.pref_dark_theme_enabled)
} else {
stringResource(R.string.pref_dark_theme_disabled)
stringResource(AppScaffoldR.string.pref_dark_theme_disabled)
},
)
}
Expand All @@ -323,7 +326,7 @@ constructor(

item(key = "about") {
ClickablePreference(
title = stringResource(R.string.about),
title = stringResource(AppScaffoldR.string.about),
) {
state.eventSink(NavToScreen(AboutScreen()))
}
Expand All @@ -333,8 +336,8 @@ constructor(
BooleanPreference(
key = CatchUpPreferences.Keys.reports,
defaultValue = true,
title = stringResource(R.string.pref_reports),
subtitle = stringResource(R.string.pref_reports_summary),
title = stringResource(AppScaffoldR.string.pref_reports),
subtitle = stringResource(AppScaffoldR.string.pref_reports_summary),
)
}
}
Expand Down
2 changes: 1 addition & 1 deletion gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ eithernet = { module = "com.slack.eithernet:eithernet", version.ref = "eithernet

errorProneAnnotations = "com.google.errorprone:error_prone_annotations:2.23.0"

haze = "dev.chrisbanes.haze:haze:0.3.1"
haze = "dev.chrisbanes.haze:haze:0.4.1"

javaxInject = "javax.inject:javax.inject:1"

Expand Down
Loading

0 comments on commit f36e170

Please sign in to comment.