From 0e85e2815f5bb0ab8b5fb8156bd772b4a7743f13 Mon Sep 17 00:00:00 2001 From: Joris Date: Tue, 8 Sep 2015 09:41:07 +0200 Subject: Using dom buttons for payment delete --- src/client/View/LoggedIn/Monthly.elm | 3 ++- src/client/View/LoggedIn/Table.elm | 7 ++++--- 2 files changed, 6 insertions(+), 4 deletions(-) (limited to 'src/client') diff --git a/src/client/View/LoggedIn/Monthly.elm b/src/client/View/LoggedIn/Monthly.elm index 6d30e4a..5d7260e 100644 --- a/src/client/View/LoggedIn/Monthly.elm +++ b/src/client/View/LoggedIn/Monthly.elm @@ -74,5 +74,6 @@ paymentLine model loggedInView payment = [ class "cell delete" , onClick serverCommunications.address (SC.DeleteMonthlyPayment payment.id) ] - [ renderIcon "times" ] + [ button [] [ renderIcon "times" ] + ] ] diff --git a/src/client/View/LoggedIn/Table.elm b/src/client/View/LoggedIn/Table.elm index 6342369..a8fef3e 100644 --- a/src/client/View/LoggedIn/Table.elm +++ b/src/client/View/LoggedIn/Table.elm @@ -77,10 +77,11 @@ paymentLine model loggedInView payment = , if loggedInView.me == payment.userId then div - [ class "cell delete" - , onClick serverCommunications.address (SC.DeletePayment payment.id payment.userId payment.cost loggedInView.currentPage) + [ class "cell delete" ] + [ button + [ onClick serverCommunications.address (SC.DeletePayment payment.id payment.userId payment.cost loggedInView.currentPage) ] + [ renderIcon "times" ] ] - [ renderIcon "times" ] else div [ class "cell" ] [] ] -- cgit v1.2.3