From 771c7706bdbc2a60de35df69348ad3ec65812815 Mon Sep 17 00:00:00 2001 From: Jim Myers Date: Thu, 30 May 2024 16:02:24 -0400 Subject: [PATCH] fix for Firefox issue in displaying rich text --- previewers/betatest/js/richhtml.js | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/previewers/betatest/js/richhtml.js b/previewers/betatest/js/richhtml.js index d068ffc..c8c15e4 100644 --- a/previewers/betatest/js/richhtml.js +++ b/previewers/betatest/js/richhtml.js @@ -25,9 +25,15 @@ function writeContentAndData(data, fileUrl, file, title, authors) { header.append($('
').html($.i18n('richContentWarning')).addClass('center')); subheader = $('
').appendTo(header).addClass('center'); subheader.append($("
").addClass("btn btn-default") - .html("" + $.i18n('displayWithRichContent') + "")); + .html($('').html( $.i18n('displayWithRichContent')) + .click(function(){console.log('Click');$('.preview').html(theData);}) + ) + ); subheader.append($("
").addClass("btn btn-default") - .html("" + $.i18n('displayWithoutRichContent') + "")); + .html($('').html( $.i18n('displayWithoutRichContent')) + .click(function(){console.log('Click');$('.preview').html(filterXSS(theData,options));}) + ) + ); } else { //Display filtered content as for normal HTML Previewer $('.preview').append($("
").html(filterXSS(data)));