mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-02-28 01:53:25 +00:00
Implement "Take me shopping" button
This commit is contained in:
@@ -1,2 +1,3 @@
|
||||
Darkswarm.controller "CartCtrl", ($scope, Cart, $timeout) ->
|
||||
Darkswarm.controller "CartCtrl", ($scope, Cart, CurrentHub) ->
|
||||
$scope.Cart = Cart
|
||||
$scope.CurrentHub = CurrentHub
|
||||
|
||||
@@ -43,12 +43,21 @@
|
||||
padding-top: 10em;
|
||||
width: 100%;
|
||||
|
||||
span {
|
||||
p {
|
||||
font-size: 1.5em;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.go-shopping {
|
||||
display: none;
|
||||
padding: 0 1.5em;
|
||||
|
||||
@include breakpoint(mobile) {
|
||||
display: inline-block;
|
||||
}
|
||||
}
|
||||
|
||||
table {
|
||||
width: 100%;
|
||||
border: none;
|
||||
|
||||
@@ -57,10 +57,6 @@
|
||||
button, a.button {
|
||||
width: 48%;
|
||||
}
|
||||
|
||||
a.button {
|
||||
line-height: 2.75em;
|
||||
}
|
||||
}
|
||||
|
||||
@include breakpoint(tablet) {
|
||||
|
||||
@@ -124,6 +124,10 @@ button.success, .button.success {
|
||||
}
|
||||
}
|
||||
|
||||
a.button.large {
|
||||
line-height: 2.75em;
|
||||
}
|
||||
|
||||
button.large, a.button.large {
|
||||
height: 3em;
|
||||
font-size: 1em;
|
||||
|
||||
@@ -23,9 +23,12 @@
|
||||
%span.total-price.right {{ line_item.total_price | localizeCurrency }}
|
||||
|
||||
.cart-empty{"ng-show" => "Cart.line_items.length == 0"}
|
||||
%span
|
||||
%p
|
||||
= t('.cart_empty')
|
||||
|
||||
%a.go-shopping.button.large.bright{ng: {href: "{{ CurrentHub.hub.id ? '#{main_app.shop_path}' : '#{main_app.shops_path}' }}"}}
|
||||
= t('.take_me_shopping')
|
||||
|
||||
.sidebar-footer{"ng-show" => "Cart.line_items.length > 0"}
|
||||
%p.cart-total
|
||||
%strong
|
||||
|
||||
@@ -1222,6 +1222,7 @@ en:
|
||||
items_in_cart: "%{num} items in your cart"
|
||||
close: "Close"
|
||||
cart_empty: "Your cart is empty"
|
||||
take_me_shopping: "Take me shopping!"
|
||||
signed_in:
|
||||
profile: "Profile"
|
||||
mobile_menu:
|
||||
|
||||
Reference in New Issue
Block a user