From 4bf5f6c0b39bfe1813007cb1c906dc3bd135feb0 Mon Sep 17 00:00:00 2001 From: yikoyu <2282373181@qq.com> Date: Sun, 5 Jan 2025 17:04:01 +0800 Subject: [PATCH] fix(xss): :bug: resolve parsing issue for colgroup and col elements --- src/constants/xss-rules.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/constants/xss-rules.ts b/src/constants/xss-rules.ts index 8227b110..b48f7190 100644 --- a/src/constants/xss-rules.ts +++ b/src/constants/xss-rules.ts @@ -28,6 +28,8 @@ const rules: IWhiteList = { ol: [], u: [], table: ['class', 'style'], + colgroup: [], + col: ['style'], tbody: ['class', 'style'], tr: ['class', 'style'], th: ['class', 'style', 'colspan', 'rowspan'],