From ebd304d97b612d0ac4ea276b1c29ba8ecc0b7998 Mon Sep 17 00:00:00 2001 From: Joris Date: Thu, 3 Sep 2015 21:56:17 +0200 Subject: Adapting design to smaller screens --- src/client/View/Payments/Table.elm | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) (limited to 'src/client/View/Payments/Table.elm') diff --git a/src/client/View/Payments/Table.elm b/src/client/View/Payments/Table.elm index a180315..12b1a46 100644 --- a/src/client/View/Payments/Table.elm +++ b/src/client/View/Payments/Table.elm @@ -23,7 +23,7 @@ import Update exposing (..) import Update.Payment exposing (..) import View.Icon exposing (renderIcon) -import View.Date exposing (renderDate) +import View.Date exposing (..) paymentsTable : Model -> PaymentView -> Html paymentsTable model paymentView = @@ -53,10 +53,18 @@ paymentLine model paymentView (id, payment) = [ class ("row " ++ (if paymentView.edition == Just id then "edition" else "")) , onClick actions.address (UpdatePayment (ToggleEdit id)) ] - [ div [ class "cell" ] [ text payment.name ] - , div [ class "cell" ] [ text ((toString payment.cost) ++ " " ++ (getMessage "MoneySymbol" model.translations)) ] - , div [ class "cell" ] [ text payment.userName ] - , div [ class "cell" ] [ text (renderDate payment.creation model.translations) ] + [ div [ class "cell category" ] [ text payment.name ] + , div [ class "cell cost" ] [ text ((toString payment.cost) ++ " " ++ (getMessage "MoneySymbol" model.translations)) ] + , div [ class "cell user" ] [ text payment.userName ] + , div + [ class "cell date" ] + [ span + [ class "shortDate" ] + [ text (renderShortDate payment.creation model.translations) ] + , span + [ class "longDate" ] + [ text (renderLongDate payment.creation model.translations) ] + ] , if paymentView.userName == payment.userName then div -- cgit v1.2.3