Add Markdown for submit page, edit page, profile edit page; thus fixing ticket #690
This commit is contained in:
parent
8545cfc97d
commit
9c196287ad
@ -23,7 +23,11 @@ class EditForm(wtforms.Form):
|
|||||||
title = wtforms.TextField(
|
title = wtforms.TextField(
|
||||||
_('Title'),
|
_('Title'),
|
||||||
[wtforms.validators.Length(min=0, max=500)])
|
[wtforms.validators.Length(min=0, max=500)])
|
||||||
description = wtforms.TextAreaField('Description of this work')
|
description = wtforms.TextAreaField(
|
||||||
|
_('Description of this work'),
|
||||||
|
description=_("""You can use
|
||||||
|
<a href="http://daringfireball.net/projects/markdown/basics">
|
||||||
|
Markdown</a> for formatting."""))
|
||||||
tags = wtforms.TextField(
|
tags = wtforms.TextField(
|
||||||
_('Tags'),
|
_('Tags'),
|
||||||
[tag_length_validator],
|
[tag_length_validator],
|
||||||
@ -40,7 +44,11 @@ class EditForm(wtforms.Form):
|
|||||||
class EditProfileForm(wtforms.Form):
|
class EditProfileForm(wtforms.Form):
|
||||||
bio = wtforms.TextAreaField(
|
bio = wtforms.TextAreaField(
|
||||||
_('Bio'),
|
_('Bio'),
|
||||||
[wtforms.validators.Length(min=0, max=500)])
|
[wtforms.validators.Length(min=0, max=500)],
|
||||||
|
description=_(
|
||||||
|
"""You can use
|
||||||
|
<a href="http://daringfireball.net/projects/markdown/basics">
|
||||||
|
Markdown</a> for formatting."""))
|
||||||
url = wtforms.TextField(
|
url = wtforms.TextField(
|
||||||
_('Website'),
|
_('Website'),
|
||||||
[wtforms.validators.Optional(),
|
[wtforms.validators.Optional(),
|
||||||
|
@ -27,7 +27,10 @@ class SubmitStartForm(wtforms.Form):
|
|||||||
_('Title'),
|
_('Title'),
|
||||||
[wtforms.validators.Length(min=0, max=500)])
|
[wtforms.validators.Length(min=0, max=500)])
|
||||||
description = wtforms.TextAreaField(
|
description = wtforms.TextAreaField(
|
||||||
_('Description of this work'))
|
_('Description of this work'),
|
||||||
|
description=_("""You can use
|
||||||
|
<a href="http://daringfireball.net/projects/markdown/basics">
|
||||||
|
Markdown</a> for formatting."""))
|
||||||
tags = wtforms.TextField(
|
tags = wtforms.TextField(
|
||||||
_('Tags'),
|
_('Tags'),
|
||||||
[tag_length_validator],
|
[tag_length_validator],
|
||||||
|
@ -96,7 +96,7 @@
|
|||||||
user= media.get_uploader.username,
|
user= media.get_uploader.username,
|
||||||
media=media._id) }}" method="POST" id="form_comment">
|
media=media._id) }}" method="POST" id="form_comment">
|
||||||
<p>
|
<p>
|
||||||
{% trans %}Type your comment here. You can use <a href="http://daringfireball.net/projects/markdown/basics" target="_blank">Markdown</a> for formatting.{% endtrans %}
|
{% trans %}Type your comment here. You can use <a href="http://daringfireball.net/projects/markdown/basics">Markdown</a> for formatting.{% endtrans %}
|
||||||
</p>
|
</p>
|
||||||
{{ wtforms_util.render_divs(comment_form) }}
|
{{ wtforms_util.render_divs(comment_form) }}
|
||||||
<div class="form_submit_buttons">
|
<div class="form_submit_buttons">
|
||||||
|
@ -29,7 +29,7 @@
|
|||||||
{% endfor %}
|
{% endfor %}
|
||||||
{%- endif %}
|
{%- endif %}
|
||||||
{% if field.description -%}
|
{% if field.description -%}
|
||||||
<p class="form_field_description">{{ _(field.description) }}</p>
|
<p class="form_field_description">{{ _(field.description)|safe }}</p>
|
||||||
{%- endif %}
|
{%- endif %}
|
||||||
</div>
|
</div>
|
||||||
{%- endmacro %}
|
{%- endmacro %}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user