mirror of
https://github.com/TheAnachronism/docspell.git
synced 2025-06-23 19:08:26 +00:00
First ui view of preview images for items
Users can choose to not show them via ui settings
This commit is contained in:
@ -10,6 +10,7 @@ module Comp.ItemCardList exposing
|
||||
, view
|
||||
)
|
||||
|
||||
import Api
|
||||
import Api.Model.HighlightEntry exposing (HighlightEntry)
|
||||
import Api.Model.ItemLight exposing (ItemLight)
|
||||
import Api.Model.ItemLightGroup exposing (ItemLightGroup)
|
||||
@ -230,7 +231,18 @@ viewItem cfg settings item =
|
||||
]
|
||||
++ DD.draggable ItemDDMsg item.id
|
||||
)
|
||||
[ div [ class "content" ]
|
||||
[ if fieldHidden Data.Fields.PreviewImage then
|
||||
span [ class "invisible" ] []
|
||||
|
||||
else
|
||||
div [ class "image" ]
|
||||
[ img
|
||||
[ class "preview-image"
|
||||
, src (Api.itemPreviewURL item.id)
|
||||
]
|
||||
[]
|
||||
]
|
||||
, div [ class "content" ]
|
||||
[ case cfg.selection of
|
||||
Data.ItemSelection.Active ids ->
|
||||
div [ class "header" ]
|
||||
|
Reference in New Issue
Block a user