mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-03-01 02:03:22 +00:00
Working on the pretties
This commit is contained in:
@@ -8,7 +8,7 @@
|
||||
#= require ./shop
|
||||
#= require_tree .
|
||||
|
||||
#$ ->
|
||||
#$(document).foundation()
|
||||
$ ->
|
||||
$(document).foundation()
|
||||
|
||||
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
/*body { background: #ff0000; }*/
|
||||
|
||||
|
||||
nav.top-bar
|
||||
margin-bottom: 0px
|
||||
2
app/assets/stylesheets/darkswarm/overrides.css.sass
Normal file
2
app/assets/stylesheets/darkswarm/overrides.css.sass
Normal file
@@ -0,0 +1,2 @@
|
||||
.row
|
||||
max-width: 74em
|
||||
59
app/assets/stylesheets/darkswarm/shop.css.sass
Normal file
59
app/assets/stylesheets/darkswarm/shop.css.sass
Normal file
@@ -0,0 +1,59 @@
|
||||
product
|
||||
display: block
|
||||
|
||||
|
||||
shop
|
||||
color: #999
|
||||
display: block
|
||||
navigation
|
||||
display: block
|
||||
background: #F4EBDE
|
||||
distributor.details
|
||||
display: block
|
||||
height: 150px
|
||||
select
|
||||
width: 200px
|
||||
position: relative
|
||||
img, h3
|
||||
display: inline
|
||||
location
|
||||
display: block
|
||||
padding-left: 28px
|
||||
|
||||
ordercycle
|
||||
display: block
|
||||
position: absolute
|
||||
right: 20px
|
||||
top: 12px
|
||||
|
||||
form.custom
|
||||
width: 400px
|
||||
strong
|
||||
line-height: 37px
|
||||
padding-right: 8px
|
||||
closing
|
||||
font-size: 80%
|
||||
display: block
|
||||
.custom.dropdown
|
||||
width: 200px
|
||||
display: inline-block
|
||||
background: transparent
|
||||
font-weight: bold
|
||||
border-color: #888
|
||||
|
||||
products
|
||||
display: block
|
||||
padding-top: 36px
|
||||
table
|
||||
width: 100%
|
||||
font-size: 1.2em
|
||||
border-collapse: collapse
|
||||
border: none
|
||||
td, th
|
||||
background: #fff
|
||||
border: 1px solid #bbb
|
||||
border-left: 0px
|
||||
border-right: 0px
|
||||
|
||||
|
||||
|
||||
29
app/assets/stylesheets/darkswarm/typography.css.sass
Normal file
29
app/assets/stylesheets/darkswarm/typography.css.sass
Normal file
@@ -0,0 +1,29 @@
|
||||
@font-face
|
||||
font-family: 'AvenirBla_IE'
|
||||
src: url("/AveniBla.eot") format("opentype")
|
||||
|
||||
@font-face
|
||||
font-family: 'AvenirBla'
|
||||
src: url("/AvenirLTStd-Black.otf") format("opentype")
|
||||
|
||||
@font-face
|
||||
font-family: 'AvenirMed_IE'
|
||||
src: url("/AveniMed.eot") format("opentype")
|
||||
|
||||
@font-face
|
||||
font-family: 'AvenirMed'
|
||||
src: url("/AvenirLTStd-Medium.otf") format("opentype")
|
||||
|
||||
body
|
||||
font-family: "AvenirMed_IE", "AvenirMed"
|
||||
|
||||
h1, h2, h3, h4, h5, h6
|
||||
color: #666
|
||||
font-family: "AvenirMed_IE", "AvenirMed"
|
||||
|
||||
// These selectors match the default Foundation selectors
|
||||
// For clean overriden magic
|
||||
table tr th, table tr td
|
||||
color: #666
|
||||
table thead tr th, table thead tr td, table tfoot tr th, table tfoot tr td
|
||||
color: #666
|
||||
@@ -9,8 +9,14 @@
|
||||
= render partial: "shop/last_order_cycle"
|
||||
|
||||
- else
|
||||
Ready for:
|
||||
%select{"ng-model" => "order_cycle.order_cycle_id",
|
||||
"ng-init" => "order_cycle.order_cycle_id = #{current_order_cycle.andand.id}",
|
||||
"ng-change" => "changeOrderCycle()",
|
||||
"ng-options" => "c for c in #{@order_cycles.map {|oc| oc.id}.to_json}"}
|
||||
%form.custom
|
||||
%strong Ready for:
|
||||
%select{"ng-model" => "order_cycle.order_cycle_id",
|
||||
"ng-init" => "order_cycle.order_cycle_id = #{current_order_cycle.andand.id}",
|
||||
"ng-change" => "changeOrderCycle()",
|
||||
"ng-options" => "oc.id as oc.time for oc in #{@order_cycles.map {|oc| {time: pickup_time(oc), id: oc.id}}.to_json}"}
|
||||
|
||||
%closing
|
||||
%img{src: "/icon/goes/here"}
|
||||
Orders close
|
||||
%strong= current_order_cycle.orders_close_at.strftime "%A %m"
|
||||
|
||||
22
app/views/shop/_products.html.haml
Normal file
22
app/views/shop/_products.html.haml
Normal file
@@ -0,0 +1,22 @@
|
||||
%products{"ng-controller" => "ProductsCtrl"}
|
||||
%table
|
||||
%thead
|
||||
%th Item
|
||||
%th Description
|
||||
%th Variant
|
||||
%th QTY
|
||||
%th Bulk
|
||||
%th Price
|
||||
%tr.product{"ng-repeat" => "product in data.products "}
|
||||
%td {{ product.product.name }}
|
||||
%td {{ product.product.description }}
|
||||
%td {{ product.master.options_text }}
|
||||
%td Quantity thing
|
||||
%td.group_buy{"ng-class" => "{enabled: product.group_buy}"}
|
||||
Not available
|
||||
%td.price
|
||||
%small from
|
||||
$ {{ product.price }}
|
||||
|
||||
|
||||
%pre {{ data.products | json }}
|
||||
@@ -1,17 +1,17 @@
|
||||
%shop{"ng-app" => "Shop"}
|
||||
= @distributor.name
|
||||
%navigation
|
||||
%distributor.details.row
|
||||
%img{src: "/route/to/distributor/icon"}
|
||||
%h3
|
||||
= @distributor.name
|
||||
%location= @distributor.address.city
|
||||
= render partial: "shop/order_cycles"
|
||||
|
||||
= render partial: "shop/order_cycles"
|
||||
|
||||
%description
|
||||
= @distributor.long_description.andand.html_safe
|
||||
|
||||
%products{"ng-controller" => "ProductsCtrl"}
|
||||
%product{"ng-repeat" => "product in data.products "}
|
||||
{{ product.product.name }}
|
||||
{{ product.product.description }}
|
||||
|
||||
%pre {{ data.products | json }}
|
||||
%description
|
||||
= @distributor.long_description.andand.html_safe
|
||||
|
||||
%products.row
|
||||
= render partial: "shop/products"
|
||||
|
||||
= render partial: "enterprises/contact_us"
|
||||
= render partial: "enterprises/about_us"
|
||||
|
||||
BIN
public/AveniBla.eot
Normal file
BIN
public/AveniBla.eot
Normal file
Binary file not shown.
BIN
public/AveniMed.eot
Normal file
BIN
public/AveniMed.eot
Normal file
Binary file not shown.
BIN
public/AvenirLTStd-Black.otf
Normal file
BIN
public/AvenirLTStd-Black.otf
Normal file
Binary file not shown.
BIN
public/AvenirLTStd-Medium.otf
Normal file
BIN
public/AvenirLTStd-Medium.otf
Normal file
Binary file not shown.
Reference in New Issue
Block a user