aboutsummaryrefslogtreecommitdiff
path: root/src/client/elm/LoggedIn/Home/Header/View.elm
diff options
context:
space:
mode:
authorJoris2016-06-29 23:33:40 +0200
committerJoris2016-06-29 23:33:40 +0200
commitba33dfef23d070bfff92d6322808507c1b7d2814 (patch)
tree9258e6972d6110ee44d25295d6dc30bfa4113d90 /src/client/elm/LoggedIn/Home/Header/View.elm
parent071b07463ab3f6894928b13553e98cd47c9ccb18 (diff)
downloadbudget-ba33dfef23d070bfff92d6322808507c1b7d2814.tar.gz
budget-ba33dfef23d070bfff92d6322808507c1b7d2814.tar.bz2
budget-ba33dfef23d070bfff92d6322808507c1b7d2814.zip
Responsive home page
Diffstat (limited to 'src/client/elm/LoggedIn/Home/Header/View.elm')
-rw-r--r--src/client/elm/LoggedIn/Home/Header/View.elm36
1 files changed, 18 insertions, 18 deletions
diff --git a/src/client/elm/LoggedIn/Home/Header/View.elm b/src/client/elm/LoggedIn/Home/Header/View.elm
index 6ddd846..95cef3c 100644
--- a/src/client/elm/LoggedIn/Home/Header/View.elm
+++ b/src/client/elm/LoggedIn/Home/Header/View.elm
@@ -36,25 +36,23 @@ import Utils.Tuple as Tuple
view : LoggedData -> Home.Model -> Payments -> Frequency -> Html Msg
view loggedData { search } payments frequency =
- Html.div
- [ class "header" ]
- [ ExceedingPayers.view loggedData
- , searchLine loggedData search frequency
- , infos loggedData payments
- ]
-
-searchLine : LoggedData -> Form String Home.Search -> Frequency -> Html Msg
-searchLine loggedData search frequency =
let currentDate = Date.fromTime loggedData.currentTime
in Html.div
- [ class "searchLine" ]
- [ searchForm loggedData search
- , AddPaymentButton.view
- loggedData
- (DialogModel.addPaymentInitial loggedData.translations currentDate frequency)
- "AddPayment"
- (text (getMessage "AddPayment" loggedData.translations))
- Nothing
+ [ class "header" ]
+ [ div
+ [ class "payerAndAdd" ]
+ [ ExceedingPayers.view loggedData
+ , AddPaymentButton.view
+ loggedData
+ (DialogModel.addPaymentInitial loggedData.translations currentDate frequency)
+ "AddPayment"
+ (text (getMessage "AddPayment" loggedData.translations))
+ Nothing
+ ]
+ , Html.div
+ [ class "searchLine" ]
+ [ searchForm loggedData search ]
+ , infos loggedData payments
]
searchForm : LoggedData -> Form String Home.Search -> Html Msg
@@ -78,7 +76,9 @@ infos loggedData payments =
sum = paymentsSum loggedData.conf payments
in div
[ class "infos" ]
- [ text <| getParamMessage [ count, sum ] "Worth" loggedData.translations
+ [ span
+ [ class "total" ]
+ [ text <| getParamMessage [ count, sum ] "Worth" loggedData.translations ]
, span
[ class "partition" ]
[ text <| paymentsPartition loggedData payments ]