From 51687b5c2ce662abdd3bbef3959066afeb824330 Mon Sep 17 00:00:00 2001 From: summerscope Date: Fri, 16 Jan 2015 13:27:16 +1100 Subject: [PATCH] Tweak language and styling for the CTA buttons taking users to shopping cart and checkout pages --- app/views/shared/menu/_cart.html.haml | 3 ++- app/views/shop/products/_form.html.haml | 8 ++++---- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/app/views/shared/menu/_cart.html.haml b/app/views/shared/menu/_cart.html.haml index dda3149ea2..28735b57f1 100644 --- a/app/views/shared/menu/_cart.html.haml +++ b/app/views/shared/menu/_cart.html.haml @@ -38,4 +38,5 @@ %strong {{ Cart.total() | localizeCurrency }} .text-right - %a.button.primary.small{href: checkout_path, "ng-disabled" => "Cart.dirty || Cart.empty()"} Quick checkout + %input.small.button.secondary.add_to_cart{type: :submit, value: "Edit your cart", "ng-disabled" => "Cart.dirty || Cart.empty()" } + %a.button.primary.small{href: checkout_path, "ng-disabled" => "Cart.dirty || Cart.empty()"} Checkout now diff --git a/app/views/shop/products/_form.html.haml b/app/views/shop/products/_form.html.haml index 252d810bab..bfcb32845b 100644 --- a/app/views/shop/products/_form.html.haml +++ b/app/views/shop/products/_form.html.haml @@ -12,8 +12,8 @@ %form{action: cart_path} .small-12.medium-4.large-3.columns - %input.button.primary.right.add_to_cart{type: :submit, value: "Your shopping cart", - "ng-disabled" => "Cart.dirty || Cart.empty()"} + %i.ofn-i_011-spinner.cart-spinner{"ng-show" => "Cart.dirty"} + %input.small.button.primary.right.add_to_cart{type: :submit, value: "{{ Cart.dirty ? 'Updating cart...' : 'Edit your cart' }}", "ng-disabled" => "Cart.dirty || Cart.empty()", "ng-class" => "{ dirty: Cart.dirty }" } %div.pad-top{bindonce: true} %product.animate-repeat{"ng-controller" => "ProductNodeCtrl", @@ -41,6 +41,6 @@ .row .small-12.columns %form{action: cart_path} - %input.button.primary.right.add_to_cart{type: :submit, value: "Your shopping cart", - "ng-disabled" => "Cart.dirty || Cart.empty()"} + %i.ofn-i_011-spinner.cart-spinner{"ng-show" => "Cart.dirty"} + %input.small.button.primary.right.add_to_cart{type: :submit, value: "{{ Cart.dirty ? 'Updating cart...' : 'Edit your cart' }}", "ng-disabled" => "Cart.dirty || Cart.empty()", "ng-class" => "{ dirty: Cart.dirty }" }