current_user_index.html.haml 969 Bytes
Newer Older
1
%h3.page-title
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
2
  My Snippets
3
  .pull-right
4
    = link_to new_snippet_path, class: "btn btn-new btn-grouped", title: "New Snippet" do
5
      Add new snippet
6
    = link_to snippets_path, class: "btn btn-grouped"  do
7
      Discover snippets
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
8

9 10
%p.light
  Share code pastes with others out of git repository
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
11 12 13
%hr

.row
14
  .col-md-3
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
15 16
    %ul.nav.nav-pills.nav-stacked
      = nav_tab :scope, nil do
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
17 18 19 20
        = link_to user_snippets_path(@user) do
          All
          %span.pull-right
            = @user.snippets.count
21 22
      = nav_tab :scope, 'are_private' do
        = link_to user_snippets_path(@user, scope: 'are_private') do
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
23 24
          Private
          %span.pull-right
25
            = @user.snippets.are_private.count
26 27 28
      = nav_tab :scope, 'are_internal' do
        = link_to user_snippets_path(@user, scope: 'are_internal') do
          Internal
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
29
          %span.pull-right
30
            = @user.snippets.are_internal.count
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
31

32
  .col-md-9.my-snippets
Dmitriy Zaporozhets's avatar
Dmitriy Zaporozhets committed
33 34
    = render 'snippets'