debian-mirror-gitlab/app/views/projects/wikis/edit.html.haml

36 lines
1.3 KiB
Text
Raw Normal View History

2016-06-22 15:30:34 +05:30
- @no_container = true
2015-12-23 02:04:40 +05:30
- page_title "Edit", @page.title.capitalize, "Wiki"
2016-04-02 18:10:28 +05:30
2016-08-24 12:49:21 +05:30
%div{ class: container_class }
2017-08-17 22:00:37 +05:30
.wiki-page-header.has-sidebar-toggle
%button.btn.btn-default.sidebar-toggle.js-sidebar-wiki-toggle{ role: "button", type: "button" }
= icon('angle-double-left')
2016-06-22 15:30:34 +05:30
.nav-text
2017-08-17 22:00:37 +05:30
%h2.wiki-page-title
2016-06-22 15:30:34 +05:30
- if @page.persisted?
= link_to @page.title.capitalize, namespace_project_wiki_path(@project.namespace, @project, @page)
- else
= @page.title.capitalize
2017-08-17 22:00:37 +05:30
%span.light
·
- if @page.persisted?
Edit Page
- else
Create Page
2016-04-02 18:10:28 +05:30
2016-06-22 15:30:34 +05:30
.nav-controls
2017-08-17 22:00:37 +05:30
- if can?(current_user, :create_wiki, @project)
= link_to '#modal-new-wiki', class: "add-new-wiki btn btn-new", "data-toggle" => "modal" do
New page
- if @page.persisted?
= link_to namespace_project_wiki_history_path(@project.namespace, @project, @page), class: "btn" do
Page history
- if can?(current_user, :admin_wiki, @project)
= link_to namespace_project_wiki_path(@project.namespace, @project, @page), data: { confirm: "Are you sure you want to delete this page?"}, method: :delete, class: "btn btn-danger" do
Delete
2014-09-02 18:07:02 +05:30
2016-06-22 15:30:34 +05:30
= render 'form'
2017-08-17 22:00:37 +05:30
= render 'sidebar'