From 043d315c4b15608e04a07cd709e4caf5c3758c61 Mon Sep 17 00:00:00 2001 From: Joris Guyonvarch Date: Thu, 30 Jul 2015 09:24:32 +0200 Subject: Amelioring the payment add design --- src/client/View/Payments/Add.elm | 38 +++++++++++++++++++++++++------------- 1 file changed, 25 insertions(+), 13 deletions(-) (limited to 'src/client/View/Payments') diff --git a/src/client/View/Payments/Add.elm b/src/client/View/Payments/Add.elm index 32010ef..9d246ef 100644 --- a/src/client/View/Payments/Add.elm +++ b/src/client/View/Payments/Add.elm @@ -24,19 +24,31 @@ addPayment name cost = Ok number -> SC.AddPayment name number Err _ -> SC.NoCommunication ] - [ text "Name" - , input - [ value name - , on "input" targetValue (Signal.message actions.address << UpdatePayment << UpdateName) + [ div + [ class "name" ] + [ label + [ for "nameInput" ] + [ text "Name" ] + , input + [ id "nameInput" + , value name + , on "input" targetValue (Signal.message actions.address << UpdatePayment << UpdateName) + ] + [] ] - [] - , text "Cost" - , input - [ value cost - , on "input" targetValue (Signal.message actions.address << UpdatePayment << UpdateCost) + , div + [ class "cost" ] + [ label + [ for "costInput" ] + [ text "Cost" ] + , input + [ id "costInput" + , value cost + , on "input" targetValue (Signal.message actions.address << UpdatePayment << UpdateCost) + ] + [] + , button + [ type' "submit" ] + [ text "Add" ] ] - [] - , button - [ type' "submit" ] - [ text "Add" ] ] -- cgit v1.2.3