diaspora/app/views/aspects/_aspect_listings.haml

21 lines
1,019 B
Text

-# Copyright (c) 2010-2011, Diaspora Inc. This file is
-# licensed under the Affero General Public License version 3 or later. See
-# the COPYRIGHT file.
%ul#aspect_nav.left_nav
%li.all_aspects
.root_element= link_to t('aspects.index.your_aspects'), aspects_path
%ul.sub_nav
- if defined?(stream)
%a.toggle_selector{:href => '#'}
= stream.for_all_aspects? ? t('.deselect_all') : t('.select_all')
- for aspect in all_aspects
%li{:data => {:aspect_id => aspect.id}, :class => ("active" if defined?(stream) && stream.aspect_ids.include?(aspect.id))}
.edit
= link_to image_tag("icons/pencil.png", :title => t('.edit_aspect', :name => aspect.name)), edit_aspect_path(aspect), :rel => "facebox"
%a.aspect_selector{:href => aspects_path("a_ids[]" => aspect.id), :class => "name", 'data-guid' => aspect.id}
= aspect
%li
= link_to t('.add_an_aspect'), new_aspect_path, :class => "new_aspect", :rel => "facebox"