From e26f8f223a59b2b700b9dbdba4f7be3880bdc9a0 Mon Sep 17 00:00:00 2001 From: azanbinzahid Date: Wed, 9 Dec 2020 18:01:58 +0500 Subject: [PATCH 01/12] PROD-2210 --- common/lib/xmodule/xmodule/js/src/video/04_video_control.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/lib/xmodule/xmodule/js/src/video/04_video_control.js b/common/lib/xmodule/xmodule/js/src/video/04_video_control.js index f80c0edd9f..fc6557160c 100644 --- a/common/lib/xmodule/xmodule/js/src/video/04_video_control.js +++ b/common/lib/xmodule/xmodule/js/src/video/04_video_control.js @@ -154,7 +154,7 @@ var endTime = (this.config.endTime !== null) ? this.config.endTime : params.duration; // in case endTime is accidentally specified as being greater than the video endTime = Math.min(endTime, params.duration); - this.videoControl.vidTimeEl.html(Time.format(params.time) + ' / ' + Time.format(endTime)); + this.videoControl.vidTimeEl.text(Time.format(params.time) + ' / ' + Time.format(endTime)); } } ); From f45b526692d1444735c376ccb70923b6d720eef4 Mon Sep 17 00:00:00 2001 From: Ali-D-Akbar Date: Thu, 10 Dec 2020 14:42:38 +0500 Subject: [PATCH 02/12] PROD-2188 PROD-2188 --- lms/static/js/course_survey.js | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/lms/static/js/course_survey.js b/lms/static/js/course_survey.js index 286cd26b13..90c65f09d8 100644 --- a/lms/static/js/course_survey.js +++ b/lms/static/js/course_survey.js @@ -23,22 +23,25 @@ $(function() { var cancel_submit = false; $inputs.each(function() { + var val, fieldLabel; /* see if it is a required field and - if so - make sure user presented all information */ if (typeof $(this).attr('required') !== typeof undefined) { - var val = $(this).val(); + val = $(this).val(); if (typeof(val) === 'string') { if (val.trim().length === 0) { - var field_label = $(this).parent().find('label'); + fieldLabel = $(this).parent().find('label'); $(this).parent().addClass('field-error'); - $('.status.message.submission-error .message-copy').append("
  • " + field_label.text() + '
  • '); + // eslint-disable-next-line max-len + $('.status.message.submission-error .message-copy').append(edx.HtmlUtils.joinHtml(edx.HtmlUtils.HTML("
  • "), fieldLabel.text(), edx.HtmlUtils.HTML('
  • ')).toString()); cancel_submit = true; } } else if (typeof(val) === 'object') { /* for SELECT statements */ if (val === null || val.length === 0 || val[0] === '') { - var field_label = $(this).parent().find('label'); + fieldLabel = $(this).parent().find('label'); $(this).parent().addClass('field-error'); - $('.status.message.submission-error .message-copy').append("
  • " + field_label.text() + '
  • '); + // eslint-disable-next-line max-len + $('.status.message.submission-error .message-copy').append(edx.HtmlUtils.joinHtml(edx.HtmlUtils.HTML("
  • "), fieldLabel.text(), edx.HtmlUtils.HTML('
  • ')).toString()); cancel_submit = true; } } @@ -70,7 +73,7 @@ $(function() { json = $.parseJSON(jqXHR.responseText); $('.status.message.submission-error').addClass('is-shown').focus(); $('.status.message.submission-error .message-copy'). - html(gettext('There has been an error processing your survey.')). + text(gettext('There has been an error processing your survey.')). stop(). css('display', 'block'); }); From 7788b9ea623848eef3fc8e91490272220b611370 Mon Sep 17 00:00:00 2001 From: azanbinzahid Date: Thu, 10 Dec 2020 15:01:59 +0500 Subject: [PATCH 03/12] PROD-2185 --- lms/static/js/customwmd.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lms/static/js/customwmd.js b/lms/static/js/customwmd.js index e0ad1b5473..0f4cfccaee 100644 --- a/lms/static/js/customwmd.js +++ b/lms/static/js/customwmd.js @@ -201,8 +201,8 @@ Mostly adapted from math.stackexchange.com: http://cdn.sstatic.net/js/mathjax-ed .append($("