Render assignment body as HTML instead of escaped text
Assignment body was being run through esc() which turned <details>/<iframe> tags into visible raw text. Set innerHTML directly to render the HTML. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
1 parent
c57f1ed827
commit
be9d58e972
1 file changed
+1
-1
+1
-1
@@ -636,7 +636,7 @@ async function openAssignment(itemId) {
|
||||
$('#assignment-kicker').textContent = `${item.course_name} · ${item.unit_name}`;
|
||||
$('#assignment-title').textContent = item.title;
|
||||
$('#assignment-points').textContent = item.points ? `Worth ${item.points} points` : '';
|
||||
$('#assignment-body').innerHTML = esc(item.body).replace(/\n/g, '<br>');
|
||||
$('#assignment-body').innerHTML = item.body || '';
|
||||
|
||||
const btn = $('#assignment-done-btn');
|
||||
const status = $('#assignment-status');
|
||||
|
||||
Reference in new issue
Block a user