diff --git a/modules/webapp/src/main/elm/Comp/ItemDetail/View.elm b/modules/webapp/src/main/elm/Comp/ItemDetail/View.elm index 6b57eb76..131c1c8f 100644 --- a/modules/webapp/src/main/elm/Comp/ItemDetail/View.elm +++ b/modules/webapp/src/main/elm/Comp/ItemDetail/View.elm @@ -317,90 +317,6 @@ renderAttachmentsTabMenu model = Comp.ItemDetail.AttachmentTabMenu.view model -renderAttachmentsTabMenuOld : Model -> Html Msg -renderAttachmentsTabMenuOld model = - let - mailTab = - if Comp.SentMails.isEmpty model.sentMails then - [] - - else - [ div - [ classList - [ ( "right item", True ) - , ( "active", model.sentMailsOpen ) - ] - , onClick ToggleSentMails - ] - [ text "E-Mails" - ] - ] - - highlight el = - let - dropId = - DD.getDropId model.attachDD - - dragId = - DD.getDragId model.attachDD - - enable = - Just el.id == dropId && dropId /= dragId - in - [ ( "current-drop-target", enable ) - ] - in - div [ class "ui top attached tabular menu" ] - (List.indexedMap - (\pos -> - \el -> - if attachmentVisible model pos then - a - ([ classList <| - [ ( "active item", True ) - ] - ++ highlight el - , title (Maybe.withDefault "No Name" el.name) - , href "" - ] - ++ DD.draggable AttachDDMsg el.id - ++ DD.droppable AttachDDMsg el.id - ) - [ Maybe.map (Util.String.ellipsis 30) el.name - |> Maybe.withDefault "No Name" - |> text - , a - [ class "right-tab-icon-link" - , href "#" - , onClick (EditAttachNameStart el.id) - ] - [ i [ class "grey edit link icon" ] [] - ] - ] - - else - a - ([ classList <| - [ ( "item", True ) - ] - ++ highlight el - , title (Maybe.withDefault "No Name" el.name) - , href "" - , onClick (SetActiveAttachment pos) - ] - ++ DD.draggable AttachDDMsg el.id - ++ DD.droppable AttachDDMsg el.id - ) - [ Maybe.map (Util.String.ellipsis 20) el.name - |> Maybe.withDefault "No Name" - |> text - ] - ) - model.item.attachments - ++ mailTab - ) - - renderAttachmentView : UiSettings -> Model -> Int -> Attachment -> Html Msg renderAttachmentView settings model pos attach = let