Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hotfix/mathjax rerendering #716

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion askbot/media/wmd/askbot_converter.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ AskbotMarkdownConverter.prototype.scheduleMathJaxRendering = function () {
clearTimeout(this._timeout);
}
var renderFunc = function () {
MathJax.Hub.Queue(['Typeset', MathJax.Hub, 'previewer']);
MathJax.Hub.Queue(['Typeset', MathJax.Hub, 'previewer-2']);
};
this._timeout = setTimeout(renderFunc, 500);
};
Expand Down
22 changes: 11 additions & 11 deletions askbot/templates/user_profile/user_info.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<div class='avatar'>
{{ macros.gravatar(view_user, 128) }}
{% if request.user.pk == view_user.pk %}
<p><a
<p><a
{% if support_custom_avatars %}
href="{% url askbot_avatar_show_list view_user.id %}"
{% else %}
Expand Down Expand Up @@ -62,7 +62,7 @@
</a>
{% endif %}
</td>
</tr>
</tr>
{% endif %}
<tr>
<th colspan="2" align="left">
Expand Down Expand Up @@ -120,10 +120,10 @@ <h3>{{ view_user.get_status_display() }}</h3>
}}</td>
</tr>
{% endif %}
{% if request.user == view_user and
settings.TWITTER_SECRET and
settings.TWITTER_KEY and
settings.ENABLE_SHARING_TWITTER
{% if request.user == view_user and
settings.TWITTER_SECRET and
settings.TWITTER_KEY and
settings.ENABLE_SHARING_TWITTER
%}
{% include "user_profile/twitter_sharing_controls.html" %}
{% endif %}
Expand All @@ -149,7 +149,7 @@ <h3>{{ view_user.get_status_display() }}</h3>
</div>
<div class="col3 user-about">
{% if show_profile_info %}
{% set editable=(request.user.is_authenticated()
{% set editable=(request.user.is_authenticated()
and (
(request.user == view_user) or request.user.is_admin_or_mod()
)
Expand All @@ -165,15 +165,15 @@ <h3>{{ view_user.get_status_display() }}</h3>
data-editor-type="{{ settings.EDITOR_TYPE }}"
data-previewer-enabled="false"
>
{% with view_user.get_localized_profile().about as user_about %}
<div class="js-editable-content">{{ user_about|convert_text }}</div>
{% endwith %}

<div class="js-editable-content">{{ view_user.get_localized_profile().about|convert_text }}</div>

<div class="js-editable-controls">
<button id="js-edit-btn-user-about-{{ view_user.pk }}">{% trans %}edit{% endtrans %}</button>
</div>
</div>
{% else %}
{{ view_user.about|convert_text }}
{{ view_user.get_localized_profile().about|convert_text }}
{% endif %}
{% endif %}
</div>
Expand Down