rosa-build/app/views/projects/comments/_markdown_help.html.haml

92 lines
3.1 KiB
Plaintext
Raw Normal View History

2012-09-19 18:35:43 +01:00
#md_help.modal.hidden
.modal-header
2014-01-21 04:51:49 +00:00
%button.close{"aria-hidden" => "true", "data-dismiss" => "modal", type: "button"} ×
2012-09-19 19:49:59 +01:00
%h3#myModalLabel=t('layout.comments.md_cheatsheet_header')
2012-09-19 18:35:43 +01:00
.modal-body
.mod
.col
2012-09-19 19:49:59 +01:00
%h3=t 'layout.comments.md_cheatsheet.format_text'
%p=t 'layout.comments.md_cheatsheet.headers'
2012-09-19 18:35:43 +01:00
%pre
-[1, 3, 6].each do |i|
="#{'#'*i} This is an <h#{i}> tag"
2012-09-19 19:49:59 +01:00
%p=t 'layout.comments.md_cheatsheet.text_styles'
2012-09-19 18:35:43 +01:00
%pre
:preserve
*This text will be italic*
_This will also be italic_
**This text will be bold**
__This will also be bold__
2014-01-21 04:51:49 +00:00
%p=link_to t('layout.comments.md_cheatsheet.emoji_header'), 'http://www.emoji-cheat-sheet.com/', target: '_blank'
2013-04-02 12:08:42 +01:00
%pre
=":smile:"
2014-01-21 04:51:49 +00:00
=image_tag(image_path('emoji/smile.png'), class: 'emoji', title: 'smile', alt: 'smile', size: "20x20")
2013-04-02 12:08:42 +01:00
=" :+1:"
2014-01-21 04:51:49 +00:00
=image_tag(image_path('emoji/+1.png'), class: 'emoji', title: '+1', alt: '+1', size: "20x20")
2012-09-19 18:35:43 +01:00
.col
2012-09-19 19:49:59 +01:00
%h3=t 'layout.comments.md_cheatsheet.lists'
2014-01-21 04:51:49 +00:00
%p{style: 'float:left;margin-left:20px;'}=t 'layout.comments.md_cheatsheet.unordered'
%p{style: 'float:right;margin-right:40px;'}=t 'layout.comments.md_cheatsheet.ordered'
.both
2012-09-19 18:35:43 +01:00
%pre
:preserve
* Item 1 1. Item 1
* Item 2 2. Item 2
* Item 2a 3. Item 3
* Item 2b * Item 3a
* Item 3b
%p=t 'layout.comments.md_cheatsheet.reference_format'
2012-09-19 18:35:43 +01:00
%pre
=preserve t('layout.comments.md_cheatsheet.reference_format_example').html_safe
2012-09-19 18:35:43 +01:00
.col
2012-09-19 19:49:59 +01:00
%h3=t 'layout.comments.md_cheatsheet.miscellaneous'
%p=t 'layout.comments.md_cheatsheet.images'
2012-09-19 18:35:43 +01:00
%pre
:preserve
![avatar](/assets/ava.png)
2012-09-19 18:35:43 +01:00
Format: ![Alt Text](url)
2012-09-19 19:49:59 +01:00
%p=t 'layout.comments.md_cheatsheet.links'
2012-09-19 18:35:43 +01:00
%pre
:preserve
https://abf.rosalinux.ru
[ABF](https://abf.rosalinux.ru/)
2012-09-19 19:49:59 +01:00
%p=t 'layout.comments.md_cheatsheet.blockquotes'
2012-09-19 18:35:43 +01:00
%pre
:preserve
As Kanye West said:
> We're living the future so
> the present is our past.
.both
%hr.bootstrap
2012-09-19 19:49:59 +01:00
%h3=t 'layout.comments.md_cheatsheet.code_examples'
2012-09-19 18:35:43 +01:00
.col
%p
2012-09-19 19:49:59 +01:00
=t 'layout.comments.md_cheatsheet.syntax_highlighting'
2012-09-19 18:35:43 +01:00
%pre
:preserve
```javascript
function fancyAlert(arg) {
if(arg) {
$.facebox({div:'#foo'})
}
}
```
.col
2012-09-19 19:49:59 +01:00
%p=t 'layout.comments.md_cheatsheet.indent_code'
2012-09-19 18:35:43 +01:00
%pre
:preserve
Here is a Python code example
without syntax highlighting:
def foo:
if not bar:
return true
.col
2012-09-19 19:49:59 +01:00
%p=t 'layout.comments.md_cheatsheet.inline_code'
2012-09-19 18:35:43 +01:00
%pre
:preserve
I think you should use an
`[addr]` element here instead.
.both