mirror of
https://github.com/TheAnachronism/docspell.git
synced 2025-06-23 10:58:26 +00:00
Display custom field values on item card
This commit is contained in:
@ -9,6 +9,7 @@ module Data.Icons exposing
|
||||
, customFieldIcon
|
||||
, customFieldType
|
||||
, customFieldTypeIcon
|
||||
, customFieldTypeIconString
|
||||
, date
|
||||
, dateIcon
|
||||
, direction
|
||||
@ -43,7 +44,7 @@ customFieldType : CustomFieldType -> String
|
||||
customFieldType ftype =
|
||||
case ftype of
|
||||
Data.CustomFieldType.Text ->
|
||||
"pen icon"
|
||||
"stream icon"
|
||||
|
||||
Data.CustomFieldType.Numeric ->
|
||||
"hashtag icon"
|
||||
@ -52,7 +53,7 @@ customFieldType ftype =
|
||||
"calendar icon"
|
||||
|
||||
Data.CustomFieldType.Boolean ->
|
||||
"question icon"
|
||||
"marker icon"
|
||||
|
||||
Data.CustomFieldType.Money ->
|
||||
"money bill icon"
|
||||
@ -64,6 +65,13 @@ customFieldTypeIcon classes ftype =
|
||||
[]
|
||||
|
||||
|
||||
customFieldTypeIconString : String -> String -> Html msg
|
||||
customFieldTypeIconString classes ftype =
|
||||
Data.CustomFieldType.fromString ftype
|
||||
|> Maybe.map (customFieldTypeIcon classes)
|
||||
|> Maybe.withDefault (i [ class "question circle outline icon" ] [])
|
||||
|
||||
|
||||
customField : String
|
||||
customField =
|
||||
"highlighter icon"
|
||||
|
Reference in New Issue
Block a user