2012-02-19 19:05:35 +02:00
|
|
|
= form_for [@project, @wiki] do |f|
|
2012-02-19 16:35:31 +02:00
|
|
|
-if @wiki.errors.any?
|
|
|
|
#error_explanation
|
|
|
|
%h2= "#{pluralize(@wiki.errors.count, "error")} prohibited this wiki from being saved:"
|
|
|
|
%ul
|
|
|
|
- @wiki.errors.full_messages.each do |msg|
|
|
|
|
%li= msg
|
|
|
|
|
2013-01-04 23:35:31 +02:00
|
|
|
.ui-box.ui-box-show
|
|
|
|
.ui-box-head
|
2012-07-26 14:45:17 +03:00
|
|
|
= f.label :title
|
2012-08-10 18:07:50 -04:00
|
|
|
.input= f.text_field :title, class: 'span8'
|
2012-07-26 14:45:17 +03:00
|
|
|
= f.hidden_field :slug
|
2013-01-04 23:35:31 +02:00
|
|
|
.ui-box-body
|
2012-07-26 14:45:17 +03:00
|
|
|
.input
|
|
|
|
%span.cgray
|
2012-09-06 10:50:47 +03:00
|
|
|
Wiki content is parsed with #{link_to "GitLab Flavored Markdown", help_markdown_path, target: '_blank'}.
|
2012-08-24 17:35:21 +02:00
|
|
|
To link to a (new) page you can just type
|
2012-07-26 14:45:17 +03:00
|
|
|
%code [Link Title](page-slug)
|
2012-08-24 17:35:21 +02:00
|
|
|
\.
|
2012-07-26 14:45:17 +03:00
|
|
|
|
2013-01-04 23:35:31 +02:00
|
|
|
.ui-box-bottom
|
2012-07-26 14:45:17 +03:00
|
|
|
= f.label :content
|
2012-10-11 23:19:34 -07:00
|
|
|
.input= f.text_area :content, class: 'span8 js-gfm-input'
|
2012-02-19 16:35:31 +02:00
|
|
|
.actions
|
2013-01-29 22:18:19 +02:00
|
|
|
= f.submit 'Save', class: "btn-save btn"
|
|
|
|
= link_to "Cancel", project_wiki_path(@project, :index), class: "btn btn-cancel"
|