Skip to content

Commit e5f1472

Browse files
authored
Fix HTML side content not working (#3310)
* Fix HTML Display runtime error * Update test snapshot
1 parent 14b9079 commit e5f1472

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/commons/sideContent/__tests__/__snapshots__/SideContentHtmlDisplay.test.tsx.snap

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ exports[`HTML Display renders correctly 1`] = `
55
className="sa-html-display"
66
sandbox="allow-scripts"
77
src="about:blank"
8-
srcDoc="<p>Hello World!</p>"
8+
srcDoc=""<p>Hello World!</p>""
99
title="HTML Display"
1010
/>
1111
`;

src/commons/sideContent/content/SideContentHtmlDisplay.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ const SideContentHtmlDisplayBase: React.FC<OwnProps & DispatchProps> = props =>
4747
className="sa-html-display"
4848
title="HTML Display"
4949
sandbox="allow-scripts"
50-
srcDoc={JSON.parse(content)}
50+
srcDoc={content}
5151
src="about:blank"
5252
/>
5353
);

0 commit comments

Comments
 (0)