Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
iv
gitlab-ce
Commits
35ad4fe7
Commit
35ad4fe7
authored
Mar 15, 2013
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use wiki tab for wiki, wall, snippets
parent
39bbdc46
Changes
10
Show whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
87 additions
and
111 deletions
+87
-111
app/assets/javascripts/main.js.coffee
app/assets/javascripts/main.js.coffee
+0
-6
app/helpers/tab_helper.rb
app/helpers/tab_helper.rb
+1
-1
app/views/layouts/project_resource.html.haml
app/views/layouts/project_resource.html.haml
+1
-1
app/views/projects/files.html.haml
app/views/projects/files.html.haml
+19
-22
app/views/projects/wall.html.haml
app/views/projects/wall.html.haml
+3
-6
app/views/snippets/index.html.haml
app/views/snippets/index.html.haml
+19
-22
app/views/wikis/_nav.html.haml
app/views/wikis/_nav.html.haml
+1
-1
app/views/wikis/pages.html.haml
app/views/wikis/pages.html.haml
+21
-24
app/views/wikis/show.html.haml
app/views/wikis/show.html.haml
+21
-27
spec/features/gitlab_flavored_markdown_spec.rb
spec/features/gitlab_flavored_markdown_spec.rb
+1
-1
No files found.
app/assets/javascripts/main.js.coffee
View file @
35ad4fe7
...
...
@@ -53,12 +53,6 @@ $ ->
$
(
'.trigger-submit'
).
on
'change'
,
->
$
(
@
).
parents
(
'form'
).
submit
()
# Wiki resizer
$
(
'.wiki-fullscreen'
).
on
'click'
,
->
$
(
'.writeboards-menu'
).
toggleClass
(
'hide'
)
$
(
'.writeboards-content'
).
toggleClass
(
'span9'
).
toggleClass
(
'span12'
)
# Flash
if
(
flash
=
$
(
".flash-container"
)).
length
>
0
flash
.
click
->
$
(
@
).
fadeOut
()
...
...
app/helpers/tab_helper.rb
View file @
35ad4fe7
...
...
@@ -80,7 +80,7 @@ module TabHelper
end
end
def
project_w
riteboards
_tab_class
def
project_w
iki
_tab_class
[
:files
,
:wall
].
each
do
|
action
|
return
"active"
if
current_page?
(
controller:
"projects"
,
action:
action
,
id:
@project
)
end
...
...
app/views/layouts/project_resource.html.haml
View file @
35ad4fe7
...
...
@@ -35,7 +35,7 @@
Merge Requests
%span
.count.merge_counter
=
@project
.
merge_requests
.
opened
.
count
=
nav_link
(
html_options:
{
class:
"
#{
project_w
riteboards
_tab_class
}
"
})
do
=
nav_link
(
html_options:
{
class:
"
#{
project_w
iki
_tab_class
}
"
})
do
=
link_to
'Wiki'
,
project_wiki_path
(
@project
,
:index
)
-
if
can?
current_user
,
:admin_project
,
@project
...
...
app/views/projects/files.html.haml
View file @
35ad4fe7
.row
.span3
=
render
'writeboards/nav'
.span9
-
unless
@notes
.
empty?
=
render
'wikis/nav'
-
unless
@notes
.
empty?
%table
%thead
%tr
...
...
@@ -19,7 +16,7 @@
Added
=
time_ago_in_words
(
note
.
created_at
)
ago
-
else
-
else
%p
.slead
All files attached to project wall, issues etc will be displayed here
app/views/projects/wall.html.haml
View file @
35ad4fe7
.row
.span3
=
render
'writeboards/nav'
.span9
%div
.wall_page
=
render
'wikis/nav'
%div
.wall_page
=
render
"notes/reversed_notes_with_form"
app/views/snippets/index.html.haml
View file @
35ad4fe7
.row
.span3
=
render
'writeboards/nav'
.span9
%h3
.page_title
=
render
'wikis/nav'
%h3
.page_title
Snippets
%small
share code pastes with others out of git repository
-
if
can?
current_user
,
:write_snippet
,
@project
=
link_to
new_project_snippet_path
(
@project
),
class:
"btn btn-small add_new pull-right"
,
title:
"New Snippet"
do
Add new snippet
%br
%table
%br
%table
%thead
%tr
%th
Title
...
...
app/views/w
riteboard
s/_nav.html.haml
→
app/views/w
iki
s/_nav.html.haml
View file @
35ad4fe7
%ul
.nav.nav-
pills.nav-stacked
%ul
.nav.nav-
tabs
-
if
@project
.
wiki_enabled
=
nav_link
(
controller:
'wikis'
)
do
=
link_to
'Wiki'
,
project_wiki_path
(
@project
,
:index
)
...
...
app/views/wikis/pages.html.haml
View file @
35ad4fe7
.row
.span3
=
render
'writeboards/nav'
.span9
%h3
.page_title
All Pages
%br
%table
=
render
'wikis/nav'
%h3
.page_title
All Pages
%br
%table
%thead
%tr
%th
Title
...
...
app/views/wikis/show.html.haml
View file @
35ad4fe7
.row
.span3.writeboards-menu
=
render
'writeboards/nav'
.span9.writeboards-content
-
if
@wiki
!=
@most_recent_wiki
=
render
'wikis/nav'
-
if
@wiki
!=
@most_recent_wiki
.alert
This is an old version of this page.
You can view the
#{
link_to
"most recent version"
,
project_wiki_path
(
@project
,
@wiki
)
}
or browse the
#{
link_to
"history"
,
history_project_wiki_path
(
@project
,
@wiki
)
}
.
.file_holder
.file_holder
.file_title
=
link_to
'#'
,
class:
'wiki-fullscreen'
do
%i
.icon-resize-horizontal
=
@wiki
.
title
%span
.options
=
link_to
pages_project_wikis_path
(
@project
),
class:
"btn btn-tiny grouped"
do
...
...
@@ -27,4 +21,4 @@
=
preserve
do
=
markdown
@wiki
.
content
%p
.time
Last edited by
#{
link_to_member
@project
,
@wiki
.
user
}
,
#{
time_ago_in_words
@wiki
.
created_at
}
ago
%p
.time
Last edited by
#{
link_to_member
@project
,
@wiki
.
user
}
,
#{
time_ago_in_words
@wiki
.
created_at
}
ago
spec/features/gitlab_flavored_markdown_spec.rb
View file @
35ad4fe7
...
...
@@ -218,7 +218,7 @@ describe "Gitlab Flavored Markdown" do
end
it
"should NOT render title in wikis#show"
do
within
(
".content
h3
"
)
do
# page title
within
(
".content
.file_title
"
)
do
# page title
page
.
should
have_content
(
"Circumvent #
#{
issue
.
id
}
"
)
page
.
should_not
have_link
(
"#
#{
issue
.
id
}
"
)
end
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment