mirror of
https://github.com/TheAnachronism/docspell.git
synced 2025-06-06 15:15:58 +00:00
Hide Load-more button when there is no more
This commit is contained in:
parent
29d80adace
commit
33cfd6df6f
@ -287,18 +287,19 @@ itemCardList flags settings model =
|
|||||||
in
|
in
|
||||||
[ Html.map ItemCardListMsg
|
[ Html.map ItemCardListMsg
|
||||||
(Comp.ItemCardList.view2 itemViewCfg settings model.itemListModel)
|
(Comp.ItemCardList.view2 itemViewCfg settings model.itemListModel)
|
||||||
, loadMore model
|
, loadMore settings model
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
loadMore : Model -> Html Msg
|
loadMore : UiSettings -> Model -> Html Msg
|
||||||
loadMore model =
|
loadMore settings model =
|
||||||
let
|
let
|
||||||
inactive =
|
inactive =
|
||||||
not model.moreAvailable || model.moreInProgress || model.searchInProgress
|
not model.moreAvailable || model.moreInProgress || model.searchInProgress
|
||||||
in
|
in
|
||||||
div
|
div
|
||||||
[ class "h-40 flex flex-col items-center justify-center w-full"
|
[ class "h-40 flex flex-col items-center justify-center w-full"
|
||||||
|
, classList [ ( "hidden", resultsBelowLimit settings model ) ]
|
||||||
]
|
]
|
||||||
[ B.secondaryBasicButton
|
[ B.secondaryBasicButton
|
||||||
{ label =
|
{ label =
|
||||||
|
Loading…
x
Reference in New Issue
Block a user