Skip to content

Commit

Permalink
iOS recycler view fix and breadcrumb size limit
Browse files Browse the repository at this point in the history
  • Loading branch information
bjsvedin committed Nov 22, 2024
1 parent fa59ae5 commit 857a104
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ fun ViewWriter.appNavBottomTabs(setup: AppNav.() -> Unit) {
centered - icon(Icon.chevronLeft, "Go Back")
centered - text {
::content {
screenNavigator.stack()?.let { it.getOrNull(it.size - 2) }?.title?.let { it() } ?: ""
screenNavigator.stack()?.let { it.getOrNull(it.size - 2) }?.title?.let { it().let{ if(it.length > 15) it.take(15) + "\u2026" else it } } ?: ""
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ actual class NRecyclerView(): UIScrollView(CGRectMake(0.0, 0.0, 0.0, 0.0)),
set(value) {
field = value
if (value) {
val s = allSubviews.last().let { it.startPosition + it.size + spacingRaw }
val s = allSubviews.lastOrNull { it.visible }?.let { it.startPosition + it.size + spacingRaw } ?: return
setContentSize(if(vertical) CGSizeMake(0.0, s) else CGSizeMake(s, 0.0))
} else {
val s = reservedScrollingSpace
Expand Down Expand Up @@ -230,6 +230,7 @@ actual class NRecyclerView(): UIScrollView(CGRectMake(0.0, 0.0, 0.0, 0.0)),
if (allSubviews.any { it.needsLayout }) {
relayout()
}
capViewAtBottom = allSubviews.last().index >= dataDirect.max
}
} finally {
animationsEnabled = before
Expand Down

0 comments on commit 857a104

Please sign in to comment.