mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-01-24 20:36:49 +00:00
Merge branch 'master' into ent-makeover
This commit is contained in:
1
Gemfile
1
Gemfile
@@ -69,7 +69,6 @@ group :test, :development do
|
||||
gem 'shoulda-matchers'
|
||||
gem 'factory_girl_rails', :require => false
|
||||
gem 'capybara'
|
||||
gem 'capybara-screenshot'
|
||||
gem 'database_cleaner', '0.7.1', :require => false
|
||||
gem 'simplecov', :require => false
|
||||
gem 'awesome_print'
|
||||
|
||||
@@ -167,9 +167,6 @@ GEM
|
||||
rack (>= 1.0.0)
|
||||
rack-test (>= 0.5.4)
|
||||
xpath (~> 2.0)
|
||||
capybara-screenshot (0.3.19)
|
||||
capybara (>= 1.0, < 3)
|
||||
launchy
|
||||
celluloid (0.15.2)
|
||||
timers (~> 1.1.0)
|
||||
chunky_png (1.3.0)
|
||||
@@ -492,7 +489,6 @@ DEPENDENCIES
|
||||
aws-sdk
|
||||
bugsnag
|
||||
capybara
|
||||
capybara-screenshot
|
||||
coffee-rails (~> 3.2.1)
|
||||
comfortable_mexican_sofa
|
||||
compass-rails
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 143 KiB After Width: | Height: | Size: 115 KiB |
@@ -14,7 +14,3 @@ Darkswarm.controller "HubNodeCtrl", ($scope, HashNavigation, $location, $anchorS
|
||||
$scope.changeHub = ->
|
||||
if confirm "Are you sure? This will change your selected Hub and remove any items in you shopping cart."
|
||||
Navigation.go $scope.hub.path
|
||||
|
||||
if $scope.open()
|
||||
$anchorScroll()
|
||||
|
||||
|
||||
@@ -1,15 +0,0 @@
|
||||
Darkswarm.controller "AccountSidebarCtrl", ($scope, $http, $location, SpreeUser, Navigation) ->
|
||||
$scope.path = "/account"
|
||||
Navigation.paths.push $scope.path
|
||||
|
||||
$scope.active = ->
|
||||
$location.path() == $scope.path
|
||||
|
||||
$scope.select = ->
|
||||
Navigation.navigate($scope.path)
|
||||
|
||||
$scope.emptyCart = (href, ev)->
|
||||
if $(ev.delegateTarget).hasClass "empties-cart"
|
||||
location.href = href if confirm "Changing your Hub will clear your cart."
|
||||
else
|
||||
location.href = href
|
||||
@@ -1,2 +0,0 @@
|
||||
Darkswarm.controller "SidebarCtrl", ($scope, $location, Sidebar) ->
|
||||
$scope.Sidebar = Sidebar
|
||||
@@ -13,3 +13,7 @@ window.Darkswarm = angular.module("Darkswarm", ["ngResource",
|
||||
|
||||
# This allows us to trigger these two events on tooltips
|
||||
$tooltipProvider.setTriggers( 'openTrigger': 'closeTrigger' )
|
||||
|
||||
Darkswarm.run ($rootScope, $location, $anchorScroll) ->
|
||||
$rootScope.$on "$locationChangeSuccess", (newRoute, oldRoute) ->
|
||||
$anchorScroll()
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
Darkswarm.directive "ofnScrollTo", ($location, $anchorScroll)->
|
||||
restrict: 'A'
|
||||
link: (scope, element, attrs)->
|
||||
element.bind 'click', ->
|
||||
$location.hash attrs.ofnScrollTo
|
||||
$anchorScroll()
|
||||
@@ -9,6 +9,7 @@ Darkswarm.factory "AuthenticationService", (Navigation, $modal, $location)->
|
||||
open: (path = false)=>
|
||||
@modalInstance = $modal.open
|
||||
templateUrl: 'authentication.html'
|
||||
windowClass: "login-modal small"
|
||||
@modalInstance.result.then @close, @close
|
||||
@selectedPath = path || @selectedPath
|
||||
Navigation.navigate @selectedPath
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
|
||||
.row
|
||||
.large-12.columns
|
||||
%label{for: "email"} Email
|
||||
%label{for: "email"} Your email
|
||||
%input.title.input-text{name: "email",
|
||||
type: "email",
|
||||
tabindex: 1,
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
%tab#login-content{"ng-controller" => "LoginCtrl",
|
||||
heading: "Login",
|
||||
heading: "Log in",
|
||||
active: "active(path)",
|
||||
select: "select(path)"}
|
||||
%form{"ng-submit" => "submit()"}
|
||||
@@ -24,14 +24,14 @@
|
||||
"ng-model" => "spree_user.password"}
|
||||
.row
|
||||
.large-12.columns
|
||||
%label{for: "remember_me"} Remember Me
|
||||
%input{name: "remember_me",
|
||||
type: "checkbox",
|
||||
value: "1",
|
||||
"ng-model" => "spree_user.remember_me"}
|
||||
%label{for: "remember_me"} Remember Me
|
||||
.row
|
||||
.large-12.columns
|
||||
%input.button.primary{name: "commit",
|
||||
tabindex: "3",
|
||||
type: "submit",
|
||||
value: "Login"}
|
||||
value: "Log in"}
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
%tab#sign-up-content{"ng-controller" => "SignupCtrl",
|
||||
heading: "Signup",
|
||||
heading: "Sign up",
|
||||
active: "active(path)",
|
||||
select: "select(path)"}
|
||||
%form{"ng-submit" => "submit()"}
|
||||
.row
|
||||
.large-12.columns
|
||||
%label{for: "email"} Email
|
||||
%label{for: "email"} Your email
|
||||
%input.title.input-text{name: "email",
|
||||
type: "email",
|
||||
tabindex: 1,
|
||||
@@ -14,7 +14,7 @@
|
||||
{{ errors.email.join(' ') }}
|
||||
.row
|
||||
.large-12.columns
|
||||
%label{for: "password"} Password
|
||||
%label{for: "password"} Choose a password
|
||||
%input.title.input-text{name: "password",
|
||||
type: "password",
|
||||
autocomplete: "off",
|
||||
@@ -24,7 +24,7 @@
|
||||
{{ errors.password.join(' ') }}
|
||||
.row
|
||||
.large-12.columns
|
||||
%label{for: "password"} Password Confirmation
|
||||
%label{for: "password"} Confirm password
|
||||
%input.title.input-text{name: "password_confirmation",
|
||||
type: "password",
|
||||
autocomplete: "off",
|
||||
@@ -35,4 +35,4 @@
|
||||
%input.button.primary{name: "commit",
|
||||
tabindex: "3",
|
||||
type: "submit",
|
||||
value: "Signup"}
|
||||
value: "Sign up now"}
|
||||
|
||||
@@ -70,27 +70,6 @@
|
||||
border: 1px solid $dark-grey
|
||||
color: $dark-grey
|
||||
|
||||
&.inactive, &.inactive strong
|
||||
color: $disabled-dark
|
||||
&.closed
|
||||
&:hover, &:active, &:focus
|
||||
border: 1px solid $disabled-dark
|
||||
color: $disabled-dark
|
||||
&.open
|
||||
.active_table_row:first-child
|
||||
color: $dark-grey
|
||||
border-top: 1px solid $disabled-dark
|
||||
border-left: 1px solid $disabled-dark
|
||||
border-right: 1px solid $disabled-dark
|
||||
strong
|
||||
color: $dark-grey
|
||||
&:hover, &:active, &:focus
|
||||
color: $dark-grey
|
||||
.active_table_row:nth-child(2)
|
||||
border-left: 1px solid $disabled-dark
|
||||
border-right: 1px solid $disabled-dark
|
||||
border-bottom: 1px solid $disabled-dark
|
||||
|
||||
&.current
|
||||
&.closed
|
||||
&, & *
|
||||
|
||||
@@ -2,7 +2,38 @@
|
||||
|
||||
.hubs
|
||||
.active_table .active_table_node
|
||||
|
||||
//Inactive row
|
||||
&.inactive, &.inactive strong
|
||||
color: $disabled-dark
|
||||
&.closed
|
||||
&:hover, &:active, &:focus
|
||||
border: 1px solid $disabled-dark
|
||||
color: $disabled-dark
|
||||
&.open
|
||||
.active_table_row:first-child
|
||||
color: $dark-grey
|
||||
border-top: 1px solid $disabled-dark
|
||||
border-left: 1px solid $disabled-dark
|
||||
border-right: 1px solid $disabled-dark
|
||||
strong
|
||||
color: $dark-grey
|
||||
&:hover, &:active, &:focus
|
||||
color: $dark-grey
|
||||
strong
|
||||
color: $dark-grey
|
||||
.active_table_row:nth-child(2)
|
||||
border-left: 1px solid $disabled-dark
|
||||
border-right: 1px solid $disabled-dark
|
||||
border-bottom: 1px solid $disabled-dark
|
||||
|
||||
//Closed row
|
||||
&.closed
|
||||
&:hover, &:active, &:focus
|
||||
border: 1px solid $clr-brick
|
||||
color: $clr-brick
|
||||
|
||||
//Open row
|
||||
&.open
|
||||
.active_table_row:first-child
|
||||
border-top: 1px solid $clr-brick
|
||||
@@ -10,22 +41,18 @@
|
||||
border-right: 1px solid $clr-brick
|
||||
&:hover, &:active, &:focus
|
||||
color: $clr-brick
|
||||
|
||||
strong
|
||||
color: $clr-brick
|
||||
.active_table_row:nth-child(2)
|
||||
border-left: 1px solid $clr-brick
|
||||
border-right: 1px solid $clr-brick
|
||||
border-bottom: 1px solid $clr-brick
|
||||
|
||||
.active_table_row.link
|
||||
background-color: $clr-brick
|
||||
&:hover
|
||||
background-color: $clr-brick-bright
|
||||
|
||||
&.closed
|
||||
&:hover, &:active, &:focus
|
||||
border: 1px solid $clr-brick
|
||||
color: $clr-brick
|
||||
|
||||
//Current selected row
|
||||
&.current
|
||||
&.closed
|
||||
&, & *
|
||||
@@ -34,3 +61,5 @@
|
||||
.active_table_row:first-child
|
||||
&, & *
|
||||
color: $clr-brick
|
||||
|
||||
|
||||
|
||||
4
app/assets/stylesheets/darkswarm/login-modal.css.sass
Normal file
4
app/assets/stylesheets/darkswarm/login-modal.css.sass
Normal file
@@ -0,0 +1,4 @@
|
||||
.login-modal
|
||||
background: #efefef
|
||||
.tabs-content
|
||||
background: #fff
|
||||
@@ -1,9 +1,6 @@
|
||||
@import branding
|
||||
@import mixins
|
||||
|
||||
.inner-wrap
|
||||
padding-top: 45px
|
||||
|
||||
.top-bar
|
||||
@include box-shadow(0 2px 3px 0 rgba(0,0,0,0.25))
|
||||
|
||||
@@ -23,4 +20,13 @@ nav
|
||||
font-size: 0.875rem
|
||||
|
||||
nav.top-bar a.icon i
|
||||
font-size: 22px
|
||||
font-size: 22px
|
||||
|
||||
// Responsive
|
||||
@media screen and (min-width: 1025px)
|
||||
body.off-canvas
|
||||
padding-top: 45px
|
||||
@media screen and (max-width: 1025px)
|
||||
section.right
|
||||
.nav-branded
|
||||
padding: 0 1em
|
||||
@@ -1,50 +0,0 @@
|
||||
/* Off canvas layout CSS/JS provided by or adapted from work by Jason Weaver and Luke Wroblewski Requires globals.css grid.css */
|
||||
body.off-canvas { padding: 0; margin: 0;}
|
||||
|
||||
.container { width: 100%; }
|
||||
|
||||
.row { overflow: hidden; }
|
||||
|
||||
.row .row { overflow: visible; }
|
||||
|
||||
.paneled .container { overflow: hidden; }
|
||||
|
||||
.paneled .row { width: 100%; }
|
||||
|
||||
[role="main"]:before { content: " "; position: absolute; z-index: -1; top: 0; left: -100%; width: 100%; height: 100%; }
|
||||
|
||||
[role="complementary"], [role="main"] { width: 100%; padding: 0 15px; display: block; position: relative; z-index: 1; -webkit-transition: 0.25s all ease-in; -moz-transition: 0.25s all ease-in; -o-transition: 0.25s all ease-in; transition: 0.25s all ease-in; }
|
||||
|
||||
.paneled [role="main"] { padding: 0; }
|
||||
|
||||
.page-panel { width: 100%; padding: 0 15px; -webkit-transition: 0.3s margin ease-in-out; -moz-transition: 0.3s margin ease-in-out; -o-transition: 0.3s margin ease-in-out; transition: 0.3s margin ease-in-out; background: #fff; }
|
||||
|
||||
#switchPanels { margin: 0 -15px; }
|
||||
|
||||
.hide-extras [role="complementary"] { display: block; }
|
||||
|
||||
[role="navigation"]#topMenu { -webkit-transition: 0.25s all ease-in; -moz-transition: 0.25s all ease-in; -o-transition: 0.25s all ease-in; transition: 0.25s all ease-in; }
|
||||
|
||||
[role="navigation"]#topMenu ul { margin-top: 0; }
|
||||
|
||||
[role="complementary"] { margin-left: -100%; width: 400px; float: left; z-index: 2; }
|
||||
|
||||
[role="main"] { margin-left: 0; float: right; z-index: 1; position: relative; }
|
||||
|
||||
.paneled [role="main"] { background: #fff; width: 500%; overflow: hidden; float: none; position: relative; left: 0; -webkit-transition: 0.15s all ease-in; -moz-transition: 0.15s all ease-in; -o-transition: 0.15s all ease-in; transition: 0.15s all ease-in; }
|
||||
|
||||
.page-panel { min-height: 400px; float: left; margin: 0; width: 20%; }
|
||||
|
||||
[role="complementary"].active { margin-left: 0; }
|
||||
.active + [role="main"] { margin-right: -420px; }
|
||||
|
||||
.active-menu [role="navigation"]#topMenu { margin-top: 0 !important; }
|
||||
|
||||
@media all and (min-width: 768px) { menu-button, .sidebar-button { display: none; }
|
||||
/*[role="complementary"] { width: 20%; margin-left: 0; float: left; padding: 0 15px; }*/
|
||||
[role="main"] { width: 100%; padding: 0 15px; }
|
||||
.paneled [role="main"] { width: 100%; padding: 0; background: #f4f4f4; left: 0 !important; }
|
||||
.page-panel { display: block; min-height: 800px; float: none; margin: 0; width: 100%; background: #f4f4f4; }
|
||||
.hide-extras [role="main"] { width: 100%; }
|
||||
.hide-extras [role="complementary"] { display: none; }
|
||||
[role="navigation"]#topMenu { display: none; } }
|
||||
@@ -2,6 +2,7 @@
|
||||
|
||||
.producers
|
||||
.active_table .active_table_node
|
||||
//Open row
|
||||
&.open
|
||||
.active_table_row:first-child
|
||||
border-top: 1px solid $clr-turquoise
|
||||
@@ -9,26 +10,22 @@
|
||||
border-right: 1px solid $clr-turquoise
|
||||
&:hover, &:active, &:focus
|
||||
color: $clr-turquoise
|
||||
|
||||
strong
|
||||
color: $clr-turquoise
|
||||
.active_table_row:nth-child(2)
|
||||
border-left: 1px solid $clr-turquoise
|
||||
border-right: 1px solid $clr-turquoise
|
||||
border-bottom: 1px solid $clr-turquoise
|
||||
|
||||
.active_table_row.link
|
||||
background-color: $clr-turquoise
|
||||
&:hover
|
||||
background-color: $clr-turquoise-bright
|
||||
|
||||
background-color: $clr-turquoise-bright
|
||||
//Closed row
|
||||
&.closed
|
||||
&, & *
|
||||
color: $clr-turquoise-bright
|
||||
&.open
|
||||
.active_table_row:first-child
|
||||
color: $dark-grey
|
||||
&:hover, &:active, &:focus
|
||||
border: 1px solid $clr-turquoise
|
||||
&, & *
|
||||
color: $clr-turquoise
|
||||
&.open
|
||||
.active_table_row:first-child
|
||||
&, & *
|
||||
color: $clr-turquoise
|
||||
color: $clr-turquoise
|
||||
|
||||
|
||||
@@ -39,6 +39,16 @@
|
||||
background-color: rgba(0, 0, 0, 0.1)
|
||||
text-shadow: 0 1px 0 #fff
|
||||
|
||||
//rewrite default primary style
|
||||
|
||||
.button.primary
|
||||
font-family: Calibri, Candara, Segoe, "Segoe UI", Optima, Arial, sans-serif
|
||||
background: $clr-brick
|
||||
color: white
|
||||
|
||||
.button.primary:hover, .button.primary:active, .button.primary:focus
|
||||
background: $clr-brick-bright
|
||||
text-shadow: 0 1px 0 $clr-brick
|
||||
|
||||
// Responsive
|
||||
@media screen and (min-width: 768px)
|
||||
|
||||
@@ -1,9 +0,0 @@
|
||||
/*
|
||||
* This is a manifest file that'll automatically include all the stylesheets available in this directory
|
||||
* and any sub-directories. You're free to add application-wide styles to this file and they'll appear at
|
||||
* the top of the compiled file, but it's generally better to create a new file per style scope.
|
||||
*= require_self
|
||||
*= require ./foundation_and_overrides
|
||||
*= require ./gmaps4rails
|
||||
*= require_tree .
|
||||
*/
|
||||
@@ -1,34 +0,0 @@
|
||||
@import "foundation4/foundation/variables";
|
||||
@import "foundation4/foundation/components/global";
|
||||
|
||||
ul.ui-autocomplete {
|
||||
position: absolute;
|
||||
list-style: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
border: solid 1px #999;
|
||||
cursor: default;
|
||||
li {
|
||||
background-color: #FFF;
|
||||
border-top: solid 1px #DDD;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
font-size: 0.7em;
|
||||
a {
|
||||
color: #000;
|
||||
display: block;
|
||||
padding: 3px;
|
||||
|
||||
&:visited {
|
||||
color: #000;
|
||||
}
|
||||
|
||||
&:hover {
|
||||
color: $primary-color
|
||||
}
|
||||
}
|
||||
a.ui-state-hover, a.ui-state-active {
|
||||
background-color: #FFFCB2;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,16 +0,0 @@
|
||||
@import "foundation4/foundation/variables";
|
||||
@import "foundation4/foundation/components/global";
|
||||
|
||||
.search-result {
|
||||
min-height: 3em;
|
||||
padding: 15px 0;
|
||||
|
||||
.secondary-info {
|
||||
font-size: 0.8em;
|
||||
color: #b7b7b7;
|
||||
}
|
||||
}
|
||||
|
||||
.with-separator {
|
||||
border-bottom: 1px solid #E0E0E0;
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,19 +0,0 @@
|
||||
.map_container {
|
||||
padding: 6px;
|
||||
border-width: 1px;
|
||||
border-style: solid;
|
||||
border-color: #ccc #ccc #999 #ccc;
|
||||
-webkit-box-shadow: rgba(64, 64, 64, 0.5) 0 2px 5px;
|
||||
-moz-box-shadow: rgba(64, 64, 64, 0.5) 0 2px 5px;
|
||||
box-shadow: rgba(64, 64, 64, 0.1) 0 2px 5px;
|
||||
width: 645px;
|
||||
}
|
||||
|
||||
.gmaps4rails_map {
|
||||
width: 630px;
|
||||
height: 530px;
|
||||
}
|
||||
|
||||
.map_container img {
|
||||
max-width: none;
|
||||
}
|
||||
@@ -1,125 +0,0 @@
|
||||
// Place all the styles related to the home controller here.
|
||||
// They will automatically be included in application.css.
|
||||
// You can use Sass (SCSS) here: http://sass-lang.com/
|
||||
|
||||
@import "foundation4/foundation/variables";
|
||||
@import "foundation4/foundation/components/global";
|
||||
@import "foundation4/foundation/components/buttons";
|
||||
@import "foundation4/foundation/components/panels";
|
||||
|
||||
#postcode_select_box {
|
||||
text-align: center;
|
||||
padding: 18% 0;
|
||||
|
||||
p {
|
||||
color: white;
|
||||
font-size: 1.1em;
|
||||
}
|
||||
|
||||
input {
|
||||
font-size: 2em;
|
||||
}
|
||||
|
||||
.button-huge {
|
||||
$padding: emCalc(21);
|
||||
$bg: $primary-color;
|
||||
$radius: true;
|
||||
$full-width: false;
|
||||
$disabled: false;
|
||||
$is-input: false;
|
||||
|
||||
@include button($padding, $bg, $radius, $full-width, $disabled, $is-input);
|
||||
}
|
||||
|
||||
a {
|
||||
&:link {
|
||||
color: #FFF;
|
||||
}
|
||||
&:visited {
|
||||
color: #FFF;
|
||||
}
|
||||
&:hover {
|
||||
color: $primary-color;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.backstretch img {
|
||||
opacity: 0.4;
|
||||
filter: alpha(opacity=40);
|
||||
}
|
||||
|
||||
.bgwidth {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.bgheight {
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
#home-page-nav
|
||||
{
|
||||
ul {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
|
||||
li {
|
||||
list-style-type: none;
|
||||
display: inline;
|
||||
font-size: 1.2em;
|
||||
font-weight: bold;
|
||||
color: #FFF;
|
||||
|
||||
&:before {
|
||||
content: " | ";
|
||||
}
|
||||
|
||||
&:first-child {
|
||||
&:before {
|
||||
content: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#sidebar {
|
||||
border: none;
|
||||
}
|
||||
|
||||
.login-panel {
|
||||
$bg: #222;
|
||||
$padding: emCalc(20);
|
||||
$adjust: true;
|
||||
|
||||
@include panel($bg, $padding, $adjust);
|
||||
}
|
||||
|
||||
.centered {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
#logo-container {
|
||||
margin-bottom: emCalc(25);
|
||||
}
|
||||
|
||||
.clearfix:after {
|
||||
content: ".";
|
||||
display: block;
|
||||
clear: both;
|
||||
visibility: hidden;
|
||||
line-height: 0;
|
||||
height: 0;
|
||||
}
|
||||
|
||||
.clearfix {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
html[xmlns] .clearfix {
|
||||
display: block;
|
||||
}
|
||||
|
||||
* html .clearfix {
|
||||
height: 1%;
|
||||
}
|
||||
@@ -1,51 +0,0 @@
|
||||
/* Off canvas layout CSS/JS provided by or adapted from work by Jason Weaver and Luke Wroblewski Requires globals.css grid.css */
|
||||
body.off-canvas { padding: 0; margin: 0; overflow: hidden}
|
||||
|
||||
.container { width: 100%; }
|
||||
|
||||
.row { overflow: hidden; }
|
||||
|
||||
.row .row { overflow: visible; }
|
||||
|
||||
.paneled .container { overflow: hidden; }
|
||||
|
||||
.paneled .row { width: 100%; }
|
||||
|
||||
[role="main"]:before { content: " "; position: absolute; z-index: -1; top: 0; left: -100%; width: 100%; height: 100%; }
|
||||
|
||||
[role="complementary"], [role="main"] { width: 100%; padding: 0 15px; display: block; position: relative; z-index: 1; -webkit-transition: 0.25s all ease-in; -moz-transition: 0.25s all ease-in; -o-transition: 0.25s all ease-in; transition: 0.25s all ease-in; }
|
||||
|
||||
.paneled [role="main"] { padding: 0; }
|
||||
|
||||
.page-panel { width: 100%; padding: 0 15px; -webkit-transition: 0.3s margin ease-in-out; -moz-transition: 0.3s margin ease-in-out; -o-transition: 0.3s margin ease-in-out; transition: 0.3s margin ease-in-out; background: #fff; }
|
||||
|
||||
#switchPanels { margin: 0 -15px; }
|
||||
|
||||
.hide-extras [role="complementary"] { display: block; }
|
||||
|
||||
[role="navigation"]#topMenu { -webkit-transition: 0.25s all ease-in; -moz-transition: 0.25s all ease-in; -o-transition: 0.25s all ease-in; transition: 0.25s all ease-in; }
|
||||
|
||||
[role="navigation"]#topMenu ul { margin-top: 0; }
|
||||
|
||||
[role="complementary"] { margin-left: -100%; width: 400px; float: left; z-index: 2; }
|
||||
|
||||
[role="main"] { margin-left: 0; float: right; z-index: 1; position: relative; }
|
||||
|
||||
.paneled [role="main"] { background: #fff; width: 500%; overflow: hidden; float: none; position: relative; left: 0; -webkit-transition: 0.15s all ease-in; -moz-transition: 0.15s all ease-in; -o-transition: 0.15s all ease-in; transition: 0.15s all ease-in; }
|
||||
|
||||
.page-panel { min-height: 400px; float: left; margin: 0; width: 20%; }
|
||||
|
||||
.active [role="complementary"] { margin-left: 0; }
|
||||
|
||||
.active [role="main"] { margin-right: -420px; }
|
||||
|
||||
.active-menu [role="navigation"]#topMenu { margin-top: 0 !important; }
|
||||
|
||||
@media all and (min-width: 768px) { menu-button, .sidebar-button { display: none; }
|
||||
/*[role="complementary"] { width: 20%; margin-left: 0; float: left; padding: 0 15px; }*/
|
||||
[role="main"] { width: 100%; padding: 0 15px; }
|
||||
.paneled [role="main"] { width: 100%; padding: 0; background: #f4f4f4; left: 0 !important; }
|
||||
.page-panel { display: block; min-height: 800px; float: none; margin: 0; width: 100%; background: #f4f4f4; }
|
||||
.hide-extras [role="main"] { width: 100%; }
|
||||
.hide-extras [role="complementary"] { display: none; }
|
||||
[role="navigation"]#topMenu { display: none; } }
|
||||
@@ -1,8 +0,0 @@
|
||||
@import "foundation4/foundation/variables";
|
||||
@import "foundation4/foundation/components/global";
|
||||
|
||||
.products {
|
||||
margin: 0, emCalc(20);
|
||||
border: 1px solid black;
|
||||
padding: emCalc(10);
|
||||
}
|
||||
@@ -1,65 +0,0 @@
|
||||
@import "foundation4/foundation/variables";
|
||||
@import "foundation4/foundation/components/global";
|
||||
|
||||
.landing-page-row {
|
||||
padding-top: emCalc(40);
|
||||
padding-bottom: emCalc(30);
|
||||
|
||||
#environment {
|
||||
font-size: 110%;
|
||||
font-weight: bold;
|
||||
padding: emCalc(5);
|
||||
border-radius: emCalc(5);
|
||||
background-color: #98ca45;
|
||||
}
|
||||
}
|
||||
|
||||
.distributor-link-row {
|
||||
padding: emCalc(5) 0;
|
||||
}
|
||||
|
||||
.with-bottom-border {
|
||||
border-bottom: 1px solid #d9d9d9;
|
||||
}
|
||||
|
||||
.with-pin-bg {
|
||||
background-image: url('../pin_bg.png');
|
||||
background-repeat: no-repeat;
|
||||
background-position: center;
|
||||
min-height: 200px;
|
||||
}
|
||||
|
||||
a.inactive {
|
||||
color: #6a6a6a;
|
||||
}
|
||||
|
||||
.secondary {
|
||||
color: #6a6a6a;
|
||||
}
|
||||
|
||||
.group-header {
|
||||
min-height: emCalc(55);
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
@media only screen and (max-width: 768px) {
|
||||
.hub_group.landing-page-row {
|
||||
padding-bottom: 0px;
|
||||
&.with-bottom-border {
|
||||
padding-top: 0px;
|
||||
}
|
||||
& > .columns {
|
||||
margin-bottom: 60px;
|
||||
}
|
||||
}
|
||||
.group-header {
|
||||
min-height: 0px;
|
||||
}
|
||||
}
|
||||
.top-bar-section ul li {
|
||||
float: left;
|
||||
}
|
||||
.top-bar-section .divider, .top-bar-section [role="separator"] {
|
||||
clear: none;
|
||||
width: 0px;
|
||||
}
|
||||
@@ -40,7 +40,7 @@ class ApplicationController < ActionController::Base
|
||||
# (vic.openfoodnetwork.org) that has the SSL certificate. Redirect all requests to this
|
||||
# domain to avoid showing customers a scary invalid certificate error.
|
||||
def require_certified_hostname
|
||||
certified_host = "vic.openfoodnetwork.org"
|
||||
certified_host = "openfoodnetwork.org.au"
|
||||
|
||||
if Rails.env.production? && request.host != certified_host
|
||||
redirect_to "http://#{certified_host}#{request.fullpath}"
|
||||
|
||||
@@ -5,14 +5,6 @@ class HomeController < BaseController
|
||||
@active_distributors ||= Enterprise.distributors_with_active_order_cycles
|
||||
end
|
||||
|
||||
def new_landing_page
|
||||
end
|
||||
|
||||
def about_us
|
||||
end
|
||||
|
||||
def temp_landing_page
|
||||
@groups = EnterpriseGroup.on_front_page.by_position
|
||||
render layout: false
|
||||
end
|
||||
end
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
%hub.active_table_node.row{"ng-repeat" => "hub in filteredHubs = (hubs | hubs:query)",
|
||||
"ng-class" => "{'closed' : !open(), 'open' : open(), 'inactive' : !hub.active, 'current' : current()}",
|
||||
"ng-controller" => "HubNodeCtrl",
|
||||
id: "{{hub.path}}"}
|
||||
id: "{{hub.hash}}"}
|
||||
.small-12.columns
|
||||
= render partial: 'home/skinny'
|
||||
= render partial: 'home/fat'
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
= display_flash_messages
|
||||
%ofn-flash
|
||||
|
||||
= render "shared/sidebar"
|
||||
-#= render "shared/sidebar"
|
||||
|
||||
%section{ role: "main" }
|
||||
= yield
|
||||
|
||||
@@ -1,20 +1,20 @@
|
||||
#account{"ng-controller" => "AccountSidebarCtrl"}
|
||||
.row
|
||||
.panel
|
||||
%p
|
||||
%strong= link_to "Manage my account", account_path
|
||||
- if enterprise_user?
|
||||
%strong= link_to "Enterprise admin", admin_path
|
||||
- if order = last_completed_order
|
||||
%dl
|
||||
%dt Current Hub:
|
||||
%dd= link_to current_distributor.name, main_app.shop_path
|
||||
%br
|
||||
%dt Last hub:
|
||||
%dd
|
||||
- if order.distributor != current_distributor
|
||||
= link_to "#{order.distributor.name}".html_safe, "",
|
||||
{class: distributor_link_class(order.distributor),
|
||||
"ng-click" => "emptyCart('#{main_app.shop_enterprise_path(order.distributor)}', $event)"}
|
||||
- else
|
||||
= order.distributor.name
|
||||
-##account{"ng-controller" => "AccountSidebarCtrl"}
|
||||
-#.row
|
||||
-#.panel
|
||||
-#%p
|
||||
-#%strong= link_to "Manage my account", account_path
|
||||
-#- if enterprise_user?
|
||||
-#%strong= link_to "Enterprise admin", admin_path
|
||||
-#- if order = last_completed_order
|
||||
-#%dl
|
||||
-#%dt Current Hub:
|
||||
-#%dd= link_to current_distributor.name, main_app.shop_path
|
||||
-#%br
|
||||
-#%dt Last hub:
|
||||
-#%dd
|
||||
-#- if order.distributor != current_distributor
|
||||
-#= link_to "#{order.distributor.name}".html_safe, "",
|
||||
-#{class: distributor_link_class(order.distributor),
|
||||
-#"ng-click" => "emptyCart('#{main_app.shop_enterprise_path(order.distributor)}', $event)"}
|
||||
-#- else
|
||||
-#= order.distributor.name
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
%li
|
||||
%a{href: ""} Map
|
||||
%li
|
||||
%a{href: producers_path} Producers
|
||||
%a{href: ""} Producers
|
||||
%li
|
||||
%a{href: ""} Groups
|
||||
.small-4.columns.text-left
|
||||
@@ -46,6 +46,8 @@
|
||||
|
|
||||
%a{href:'' } Creative Commons
|
||||
|
|
||||
%a{href:'' } Github
|
||||
|
|
||||
%a{href:'' } Developers
|
||||
%a{href:"https://github.com/openfoodfoundation/openfoodnetwork", target: "_blank" } Github
|
||||
|
||||
// To be added when Guy's pretty landing page is up:
|
||||
//|
|
||||
//%a{href:'' } Developers
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
%li#login-link
|
||||
%a{"ng-click" => "open()"}
|
||||
%i.fi-lock
|
||||
LOGIN
|
||||
LOG IN
|
||||
|
||||
|
||||
@@ -1,23 +1,33 @@
|
||||
%nav.top-bar.hide-for-small{'data' => 'topbar'}
|
||||
%nav.top-bar.show-for-large-only{'data' => 'topbar'}
|
||||
%section.top-bar-section
|
||||
%ul.left
|
||||
%ul.left{}
|
||||
%li= link_to image_tag("ofn_logo_small.png"), root_path
|
||||
%li.divider
|
||||
%li
|
||||
%a
|
||||
%span.nav-primary{href: ""} Shop
|
||||
- if current_page? root_path
|
||||
%li
|
||||
%a{"ofn-scroll-to" => "hubs"}
|
||||
%span.nav-primary Hubs
|
||||
- else
|
||||
%li
|
||||
%a{href: root_path + "#/#hubs"}
|
||||
%span.nav-primary Hubs
|
||||
%li.divider
|
||||
%li
|
||||
%a
|
||||
%span.nav-primary{href: ""} Map
|
||||
%a{href: ""}
|
||||
%span.nav-primary Map
|
||||
%li.divider
|
||||
%li
|
||||
%a
|
||||
%span.nav-primary{href: main_app.producers_path} Producers
|
||||
%a{href: main_app.producers_path}
|
||||
%span.nav-primary Producers
|
||||
%li.divider
|
||||
%li
|
||||
%a
|
||||
%span.nav-primary{href: ""} Groups
|
||||
%a{href: ""}
|
||||
%span.nav-primary Groups
|
||||
%li.divider
|
||||
- if spree_current_user.andand.has_spree_role? 'admin'
|
||||
%li
|
||||
%a{href: spree.admin_path}
|
||||
%span.nav-primary Admin
|
||||
%li.divider
|
||||
%section.top-bar-section
|
||||
%ul.right{"ng-controller" => "AuthenticationCtrl"}
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
.fixed
|
||||
= render partial: "shared/menu/large_menu"
|
||||
= render partial: "shared/menu/mobile_menu"
|
||||
= render partial: "shared/menu/mobile_menu"
|
||||
|
||||
@@ -1,23 +1,52 @@
|
||||
%aside.left-off-canvas-menu.show-for-small
|
||||
%nav.tab-bar.show-for-medium-down
|
||||
%section.left
|
||||
%a.left-off-canvas-toggle.menu-icon
|
||||
%span
|
||||
%section.right
|
||||
%a.nav-branded.icon{href: cart_url}
|
||||
%i.fi-shopping-cart
|
||||
%span
|
||||
= cart_count
|
||||
items
|
||||
%a{href: main_app.shop_path}
|
||||
{{ CurrentHub.name }}
|
||||
|
||||
%aside.left-off-canvas-menu.show-for-medium-down
|
||||
%ul.off-canvas-list
|
||||
%li= link_to image_tag("ofn_logo_small.png"), root_path
|
||||
%li
|
||||
%a{href: main_app.producers_path} Producers
|
||||
|
||||
- if spree_current_user.andand.has_spree_role? 'admin'
|
||||
%li
|
||||
%a{href: spree.admin_path}
|
||||
%span.nav-primary Admin
|
||||
%li
|
||||
- if spree_current_user.nil?
|
||||
= render 'shared/signed_out'
|
||||
- else
|
||||
= render 'shared/signed_in'
|
||||
|
||||
%nav.tab-bar.show-for-small
|
||||
%section.left-small
|
||||
%a.left-off-canvas-toggle.menu-icon
|
||||
%span
|
||||
%a{href: main_app.shop_path}
|
||||
{{ CurrentHub.name }}
|
||||
%section.right-small
|
||||
%a.icon{href: cart_url}
|
||||
%i.fi-shopping-cart
|
||||
%span
|
||||
= cart_count
|
||||
items
|
||||
%li
|
||||
%a{href: main_app.producers_path} Producers
|
||||
|
||||
- if current_page? root_path
|
||||
%li
|
||||
%a{"ofn-scroll-to" => "hubs"}
|
||||
%span.nav-primary Hubs
|
||||
- else
|
||||
%li
|
||||
%a{href: root_path + "#/#hubs"}
|
||||
%span.nav-primary Hubs
|
||||
|
||||
%li
|
||||
%a{href: ""}
|
||||
%span.nav-primary Map
|
||||
|
||||
%li
|
||||
%a{href: main_app.producers_path}
|
||||
%span.nav-primary Producers
|
||||
|
||||
%li
|
||||
%a{href: ""}
|
||||
%span.nav-primary Groups
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,9 @@
|
||||
object @variant
|
||||
attributes :id
|
||||
node( :unit_text ) { |v| v.product.name + (v.options_text.empty? ? "" : ": " + v.options_text) }
|
||||
|
||||
node( :unit_text ) do |v|
|
||||
options_text = v.options_text
|
||||
v.product.name + (options_text.empty? ? "" : ": #{options_text}")
|
||||
end
|
||||
|
||||
node( :unit_value ) { |v| v.unit_value }
|
||||
|
||||
@@ -2,7 +2,7 @@ Hello,
|
||||
|
||||
Welcome to Australia's Open Food Network! Your login email is <%= @user.email %>
|
||||
|
||||
You can go online and start shopping through food hubs and local producers you like at vic.openfoodnetwork.org.au
|
||||
You can go online and start shopping through food hubs and local producers you like at http://openfoodnetwork.org.au
|
||||
|
||||
We welcome all your questions and feedback; you can use the Send Feedback button on the site or email us at hello@openfoodnetwork.org
|
||||
|
||||
|
||||
@@ -63,7 +63,10 @@ module Openfoodnetwork
|
||||
# config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
|
||||
config.i18n.default_locale = 'en'
|
||||
|
||||
I18n.config.enforce_available_locales = true
|
||||
# Setting this to true causes a performance regression in Rails 3.2.17
|
||||
# When we're on a version with the fix below, we can set it to true
|
||||
# https://github.com/svenfuchs/i18n/issues/230
|
||||
I18n.config.enforce_available_locales = false
|
||||
|
||||
# Configure the default encoding used in templates for Ruby 1.9.
|
||||
config.encoding = "utf-8"
|
||||
|
||||
@@ -10,14 +10,6 @@ feature %q{
|
||||
|
||||
stub_authorization!
|
||||
|
||||
before :all do
|
||||
@default_wait_time = Capybara.default_wait_time
|
||||
Capybara.default_wait_time = 10
|
||||
end
|
||||
|
||||
after :all do
|
||||
Capybara.default_wait_time = @default_wait_time
|
||||
end
|
||||
context "listing orders" do
|
||||
before :each do
|
||||
admin_user = quick_login_as_admin
|
||||
|
||||
@@ -1,14 +0,0 @@
|
||||
describe "SidebarCtrl", ->
|
||||
ctrl = null
|
||||
scope = null
|
||||
location = null
|
||||
|
||||
beforeEach ->
|
||||
module("Darkswarm")
|
||||
location =
|
||||
path: ->
|
||||
"/login"
|
||||
inject ($controller, $rootScope) ->
|
||||
scope = $rootScope
|
||||
ctrl = $controller 'SidebarCtrl', {$scope: scope, $location: location}
|
||||
scope.$apply()
|
||||
@@ -11,7 +11,6 @@ ENV["RAILS_ENV"] ||= 'test'
|
||||
require File.expand_path("../../config/environment", __FILE__)
|
||||
require 'rspec/rails'
|
||||
require 'capybara'
|
||||
require 'capybara-screenshot/rspec'
|
||||
require 'database_cleaner'
|
||||
|
||||
# Allow connections to phantomjs/selenium whilst raising errors
|
||||
@@ -48,7 +47,6 @@ end
|
||||
|
||||
Capybara.default_wait_time = 30
|
||||
|
||||
|
||||
require "paperclip/matchers"
|
||||
|
||||
RSpec.configure do |config|
|
||||
|
||||
Reference in New Issue
Block a user