diff --git a/kallithea/controllers/changeset.py b/kallithea/controllers/changeset.py --- a/kallithea/controllers/changeset.py +++ b/kallithea/controllers/changeset.py @@ -412,7 +412,7 @@ class ChangesetController(BaseRepoContro raise HTTPBadRequest() text = request.POST.get('text') if text: - return h.rst_w_mentions(text) + return h.render_w_mentions(text) return '' @LoginRequired() diff --git a/kallithea/lib/helpers.py b/kallithea/lib/helpers.py --- a/kallithea/lib/helpers.py +++ b/kallithea/lib/helpers.py @@ -1398,7 +1398,7 @@ def rst_w_mentions(source): MarkupRenderer.rst_with_mentions(source)) -def mentions_replace(match_obj): +def _mentions_replace(match_obj): return '@%s' % match_obj.group(1) @@ -1413,7 +1413,7 @@ def render_w_mentions(source): # this sequence of html-ifications seems to be safe and non-conflicting # if the issues regexp is sane s = _urlify_text(s) - s = MENTIONS_REGEX.sub(mentions_replace, s) + s = MENTIONS_REGEX.sub(_mentions_replace, s) return literal('%s' % s) diff --git a/kallithea/model/notification.py b/kallithea/model/notification.py --- a/kallithea/model/notification.py +++ b/kallithea/model/notification.py @@ -123,7 +123,7 @@ class NotificationModel(BaseModel): ## this is passed into template html_kwargs = { 'subject': subject, - 'body': h.rst_w_mentions(body), + 'body': h.render_w_mentions(body), 'when': h.fmt_date(notif.created_on), 'user': notif.created_by_user.username, } diff --git a/kallithea/public/css/style.css b/kallithea/public/css/style.css --- a/kallithea/public/css/style.css +++ b/kallithea/public/css/style.css @@ -4131,9 +4131,7 @@ div.rst-block pre { .comments .comment .text { background-color: #FAFAFA; -} -.comment .text div.rst-block p { - margin: 0.5em 0px !important; + margin: 6px; } .comments-number { @@ -4294,13 +4292,6 @@ form.comment-inline-form { padding: 0 20px; } -.inline-comments div.rst-block { - clear: both; - overflow: hidden; - margin: 0; - padding: 0 20px 0px; -} - .inline-comments .comment .comment-wrapp { max-width: 978px; border: 1px solid #ddd; @@ -4338,6 +4329,7 @@ form.comment-inline-form { .inline-comments .comment .text { background-color: #FAFAFA; + margin: 6px; } .inline-comments .comments-number { diff --git a/kallithea/templates/admin/notifications/show_notification.html b/kallithea/templates/admin/notifications/show_notification.html --- a/kallithea/templates/admin/notifications/show_notification.html +++ b/kallithea/templates/admin/notifications/show_notification.html @@ -37,7 +37,7 @@
${h.literal(c.notification.subject)}
%if c.notification.body: - ${h.rst_w_mentions(c.notification.body)} + ${h.render_w_mentions(c.notification.body)} %endif
diff --git a/kallithea/templates/changeset/changeset_file_comment.html b/kallithea/templates/changeset/changeset_file_comment.html --- a/kallithea/templates/changeset/changeset_file_comment.html +++ b/kallithea/templates/changeset/changeset_file_comment.html @@ -32,7 +32,7 @@
%if co.status_change: -
+

${_("Status change")}: ${co.status_change[0].status_lbl} @@ -40,7 +40,7 @@

%endif %if co.text: - ${h.rst_w_mentions(co.text)|n} + ${h.render_w_mentions(co.text)|n} %endif
@@ -57,12 +57,7 @@ ${h.form('#', class_='inline-form')}
${_('Commenting on line {1}.')} - ${(_('Comments parsed using %s syntax with %s support.') % ( - ('RST' % h.url('rst_help')), - ('@mention' % _('Use @username inside this text to notify another user')) - ) - )|n - } + ${_('Comments are in plain text. Use @username inside this text to notify another user.')|n}
@@ -145,9 +140,7 @@ ${h.form(post_url, id="main_form")}
- ${(_('Comments parsed using %s syntax with %s support.') % (('RST' % h.url('rst_help')), - '@mention' % - _('Use @username inside this text to notify another user.')))|n} + ${_('Comments are in plain text. Use @username inside this text to send notification to another local user.')|n}
${h.textarea('text', class_="comment-block-ta")} diff --git a/kallithea/templates/pullrequests/pullrequest_show.html b/kallithea/templates/pullrequests/pullrequest_show.html --- a/kallithea/templates/pullrequests/pullrequest_show.html +++ b/kallithea/templates/pullrequests/pullrequest_show.html @@ -43,7 +43,7 @@ ${self.repo_context_bar('showpullrequest %endif
-
${h.urlify_commit(c.pull_request.description, c.pull_request.org_repo.repo_name)}
+ ${h.urlify_commit(c.pull_request.description, c.pull_request.org_repo.repo_name)}