Merge pull request #26249 from edx/private_to_public_0aa1b8f

Mergeback PR from private to public.
This commit is contained in:
edx-pipeline-bot
2021-01-29 09:01:36 -05:00
committed by GitHub
11 changed files with 81 additions and 63 deletions

View File

@@ -1,18 +1,17 @@
{% extends 'ace_common/edx_ace/common/base_body.html' %}
{% load i18n %}
{% load django_markup %}
{% load static %}
{% block content %}
<table width="100%" align="left" border="0" cellpadding="0" cellspacing="0" role="presentation">
<tr>
<td>
<p>
{% filter force_escape %}
{% blocktrans trimmed asvar replied_to_text %}
{{ comment_username }} replied to
{{ comment_username }} replied to {start_tag}{{ thread_title }}{end_tag}:
{% endblocktrans %}
{% endfilter %}
{{ replied_to_text }} <b>{{ thread_title }}</b>:
{% interpolate_html replied_to_text start_tag='<b>'|safe end_tag='</b>'|safe %}
</p>
<div style="border-left: 1px solid rgba(0,0,0,0.25);
padding: 1px 1px 1px 15px;
@@ -21,9 +20,7 @@
{{ comment_body }}
</div>
{% filter force_escape %}
{% blocktrans asvar course_cta_text %}View discussion{% endblocktrans %}
{% endfilter %}
{% trans "View discussion" as course_cta_text %}{{course_cta_text|force_escape}}
{% include "ace_common/edx_ace/common/return_to_course_cta.html" with course_cta_text=course_cta_text course_cta_url=post_link%}
{% block google_analytics_pixel %}

View File

@@ -1,4 +1,4 @@
<span class="member-count"><%= membership_message %></span>
<span class="member-count"><%- membership_message %></span>
<ul class="list-member-thumbs">
<% _.each(memberships, function (membership) { %>
<li class="item-member-thumb"><img alt="<%- membership.user.username %>" src="<%- membership.user.profile_image.image_url_small %>"></img></li>

View File

@@ -4,8 +4,9 @@
'underscore',
'backbone',
'gettext',
'js/discovery/views/course_card'
], function($, _, Backbone, gettext, CourseCardView) {
'js/discovery/views/course_card',
'edx-ui-toolkit/js/utils/html-utils'
], function($, _, Backbone, gettext, CourseCardView, HtmlUtils) {
'use strict';
return Backbone.View.extend({
@@ -38,7 +39,10 @@
var item = new CourseCardView({model: result});
return item.render().el;
}, this);
this.$list.append(items);
HtmlUtils.append(
this.$list,
HtmlUtils.HTML(items)
);
/* eslint no-param-reassign: [2, { "props": false }] */
},

View File

@@ -1,7 +1,7 @@
(function(define) {
'use strict';
define(['jquery', 'underscore', 'backbone'],
function($, _, Backbone) {
define(['jquery', 'underscore', 'backbone', 'edx-ui-toolkit/js/utils/html-utils'],
function($, _, Backbone, HtmlUtils) {
return Backbone.View.extend({
el: '#hinted-login-form',
@@ -22,10 +22,12 @@
},
render: function() {
$(this.el).html(_.template(this.tpl)({
hintedProvider: this.hintedProvider
}));
HtmlUtils.setHtml(
$(this.el),
HtmlUtils.template(this.tpl)({
hintedProvider: this.hintedProvider
})
);
return this;
},

View File

@@ -1,7 +1,7 @@
(function(define) {
'use strict';
define(['jquery', 'underscore', 'backbone'],
function($, _, Backbone) {
define(['jquery', 'underscore', 'backbone', 'edx-ui-toolkit/js/utils/html-utils'],
function($, _, Backbone, HtmlUtils) {
return Backbone.View.extend({
el: '#institution_login-form',
@@ -13,13 +13,15 @@
},
render: function() {
$(this.el).html(_.template(this.tpl)({
// We pass the context object to the template so that
// we can perform variable interpolation using sprintf
providers: this.providers,
platformName: this.platformName
}));
HtmlUtils.setHtml(
$(this.el),
HtmlUtils.template(this.tpl)({
// We pass the context object to the template so that
// we can perform variable interpolation using sprintf
providers: this.providers,
platformName: this.platformName
})
);
return this;
}
});