1
0
Fork 0
mirror of https://github.com/anyproto/anytype-kotlin.git synced 2025-06-08 05:47:05 +09:00

DROID-1270 Sets or Collections | Fix | Map 'Medium' gallery view's card size to 'Small' (#3194)

This commit is contained in:
Evgenii Kozlov 2023-05-22 19:35:26 +02:00 committed by uburoiubu
parent d2e3b2110c
commit e3af70f7a0
No known key found for this signature in database
GPG key ID: C8FB80E0A595FBB6
3 changed files with 3 additions and 3 deletions

View file

@ -103,7 +103,7 @@ suspend fun DVViewer.render(
objectOrderIds = objectOrderIds
),
title = name,
largeCards = cardSize != DVViewerCardSize.SMALL
largeCards = cardSize == DVViewerCardSize.LARGE
)
}
DVViewerType.LIST -> {

View file

@ -54,7 +54,7 @@ class ObjectSetSettingsViewModel(
result.add(ViewerRelationListView.Setting.CardSize.Small)
}
Block.Content.DataView.Viewer.Size.MEDIUM -> {
result.add(ViewerRelationListView.Setting.CardSize.Large)
result.add(ViewerRelationListView.Setting.CardSize.Small)
}
Block.Content.DataView.Viewer.Size.LARGE -> {
result.add(ViewerRelationListView.Setting.CardSize.Large)

View file

@ -35,7 +35,7 @@ class ViewerCardSizeSelectViewModel(
val viewer = it.viewerById(session.currentViewerId.value) ?: return@collect
viewState.value = when (viewer.cardSize) {
Block.Content.DataView.Viewer.Size.SMALL -> STATE_SMALL_CARD_SELECTED
Block.Content.DataView.Viewer.Size.MEDIUM -> STATE_LARGE_CARD_SELECTED
Block.Content.DataView.Viewer.Size.MEDIUM -> STATE_SMALL_CARD_SELECTED
Block.Content.DataView.Viewer.Size.LARGE -> STATE_LARGE_CARD_SELECTED
}
}