Files
openfoodnetwork/app/views/shopping_shared/_tabs.html.haml
2015-05-29 16:39:41 +10:00

17 lines
641 B
Plaintext

#tabs{"ng-controller" => "TabsCtrl", "ng-cloak" => true}
.row
%tabset
-# Build all tabs.
- for name, heading_cols in { about: ["About #{current_distributor.name}", 6],
producers: ["Producers",2],
contact: ["Contact",2],
groups: ["Groups",2]}
-# tabs take tab path in 'active' and 'select' functions defined in TabsCtrl.
- heading, cols = heading_cols
%tab.columns{heading: heading,
id: "tab_#{name}",
active: "active(\'#{name}\')",
select: "toggle(\'#{name}\')",
class: "small-12 medium-#{cols}" }
= render "shopping_shared/#{name}"