[v9.3.x] Fix xss in Graphite functions tooltip (#806)
Fix xss in Graphite functions tooltip (#804) (cherry picked from commit 87aad3f11836f810ee1fdfee27827e746ef36055) Co-authored-by: Ludovic Viaud <ludovic.viaud@gmail.com>
This commit is contained in:
committed by
Kevin Minehart
co-authored by
Ludovic Viaud
parent
72a13b0fd9
commit
14bc6f98df
@@ -11,11 +11,9 @@ export interface FunctionEditorControlsProps {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const FunctionDescription = React.lazy(async () => {
|
const FunctionDescription = React.lazy(async () => {
|
||||||
// @ts-ignore
|
|
||||||
const { default: rst2html } = await import(/* webpackChunkName: "rst2html" */ 'rst2html');
|
|
||||||
return {
|
return {
|
||||||
default(props: { description?: string }) {
|
default(props: { description?: string }) {
|
||||||
return <div dangerouslySetInnerHTML={{ __html: rst2html(props.description ?? '') }} />;
|
return <div>{props.description}</div>;
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user