summaryrefslogtreecommitdiff
path: root/app/views/snippets
diff options
context:
space:
mode:
Diffstat (limited to 'app/views/snippets')
-rw-r--r--app/views/snippets/_head.html.haml7
-rw-r--r--app/views/snippets/current_user_index.html.haml1
-rw-r--r--app/views/snippets/index.html.haml3
3 files changed, 9 insertions, 2 deletions
diff --git a/app/views/snippets/_head.html.haml b/app/views/snippets/_head.html.haml
new file mode 100644
index 00000000000..0adf6b91f2c
--- /dev/null
+++ b/app/views/snippets/_head.html.haml
@@ -0,0 +1,7 @@
+%ul.center-top-menu
+ = nav_link(page: user_snippets_path(current_user), html_options: {class: 'home'}) do
+ = link_to user_snippets_path(current_user), title: 'Your snippets', data: {placement: 'right'} do
+ Your Snippets
+ = nav_link(page: snippets_path) do
+ = link_to snippets_path, title: 'Explore snippets', data: {placement: 'right'} do
+ Explore Snippets
diff --git a/app/views/snippets/current_user_index.html.haml b/app/views/snippets/current_user_index.html.haml
index 0718f743828..a10069478f3 100644
--- a/app/views/snippets/current_user_index.html.haml
+++ b/app/views/snippets/current_user_index.html.haml
@@ -1,4 +1,5 @@
- page_title "Your Snippets"
+= render 'head'
%h3.page-title
Your Snippets
.pull-right
diff --git a/app/views/snippets/index.html.haml b/app/views/snippets/index.html.haml
index e9bb6a908d3..dc45cfacd84 100644
--- a/app/views/snippets/index.html.haml
+++ b/app/views/snippets/index.html.haml
@@ -1,4 +1,5 @@
- page_title "Public Snippets"
+= render 'head'
%h3.page-title
Public snippets
@@ -6,8 +7,6 @@
- if current_user
= link_to new_snippet_path, class: "btn btn-new btn-grouped", title: "New Snippet" do
Add new snippet
- = link_to user_snippets_path(current_user), class: "btn btn-grouped" do
- Your snippets
%p.light
Public snippets created by you and other users are listed here