From b030b6be391b5a5b9837d6f9fb35a56f33286b34 Mon Sep 17 00:00:00 2001 From: Raunak Raj <71929976+bajrangCoder@users.noreply.github.com> Date: Fri, 31 Jul 2026 16:41:14 +0530 Subject: [PATCH] fix: sanitize input hints to prevent XSS --- src/components/inputhints/index.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/components/inputhints/index.js b/src/components/inputhints/index.js index 9e8f5fad6..d9395fea5 100644 --- a/src/components/inputhints/index.js +++ b/src/components/inputhints/index.js @@ -1,4 +1,5 @@ import "./style.scss"; +import DOMPurify from "dompurify"; /** * @typedef {Object} HintObj @@ -400,7 +401,7 @@ function Hint({ hint }) { className={active ? "active" : ""} attr-action="hint" attr-value={value} - innerHTML={text} + innerHTML={DOMPurify.sanitize(text)} > ); }