Skip to content

Commit 8c02eb9

Browse files
author
Theryston
committed
fix: add add children to html security list
1 parent 4beed21 commit 8c02eb9

File tree

3 files changed

+29
-20
lines changed

3 files changed

+29
-20
lines changed

packages/core/CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# @jsx-mail/core
22

3+
## 1.0.5
4+
5+
### Patch Changes
6+
7+
- add children to html security list"
8+
39
## 1.0.4
410

511
### Patch Changes

packages/core/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"version": "1.0.4",
2+
"version": "1.0.5",
33
"license": "MIT",
44
"description": "All jsx mail core functions. 🚀✉️",
55
"main": "dist/index.js",

packages/core/src/checkers/HtmlChecker/htmlSecurityList.ts

Lines changed: 22 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
export const htmlSecurityList: { [key: string]: string[] } = {
2-
a: ['class', 'href', 'id', 'style', 'target'],
3-
b: ['class', 'id', 'style'],
4-
br: ['class', 'id', 'style'],
5-
div: ['align', 'class', 'dir', 'id', 'style'],
6-
font: ['class', 'color', 'face', 'id', 'size', 'style'],
7-
h1: ['align', 'class', 'dir', 'id', 'style'],
8-
h2: ['align', 'class', 'dir', 'id', 'style'],
9-
h3: ['align', 'class', 'dir', 'id', 'style'],
10-
h4: ['align', 'class', 'dir', 'id', 'style'],
11-
h5: ['align', 'class', 'dir', 'id', 'style'],
12-
h6: ['align', 'class', 'dir', 'id', 'style'],
2+
a: ['class', 'href', 'id', 'style', 'target', 'children'],
3+
b: ['class', 'id', 'style', 'children'],
4+
br: ['class', 'id', 'style', 'children'],
5+
div: ['align', 'class', 'dir', 'id', 'style', 'children'],
6+
font: ['class', 'color', 'face', 'id', 'size', 'style', 'children'],
7+
h1: ['align', 'class', 'dir', 'id', 'style', 'children'],
8+
h2: ['align', 'class', 'dir', 'id', 'style', 'children'],
9+
h3: ['align', 'class', 'dir', 'id', 'style', 'children'],
10+
h4: ['align', 'class', 'dir', 'id', 'style', 'children'],
11+
h5: ['align', 'class', 'dir', 'id', 'style', 'children'],
12+
h6: ['align', 'class', 'dir', 'id', 'style', 'children'],
1313
hr: ['align', 'size', 'width'],
1414
img: [
1515
'align',
@@ -26,11 +26,11 @@ export const htmlSecurityList: { [key: string]: string[] } = {
2626
'alt',
2727
'path',
2828
],
29-
label: ['class', 'id', 'style'],
30-
li: ['class', 'dir', 'id', 'style', 'type'],
31-
ol: ['class', 'dir', 'id', 'style', 'type'],
32-
p: ['class', 'dir', 'id', 'style', 'type'],
33-
span: ['class', 'id', 'style'],
29+
label: ['class', 'id', 'style', 'children'],
30+
li: ['class', 'dir', 'id', 'style', 'type', 'children'],
31+
ol: ['class', 'dir', 'id', 'style', 'type', 'children'],
32+
p: ['class', 'dir', 'id', 'style', 'type', 'children'],
33+
span: ['class', 'id', 'style', 'children'],
3434
table: [
3535
'align',
3636
'bgcolor',
@@ -46,6 +46,7 @@ export const htmlSecurityList: { [key: string]: string[] } = {
4646
'rules',
4747
'style',
4848
'width',
49+
'children',
4950
],
5051
td: [
5152
'abbr',
@@ -62,6 +63,7 @@ export const htmlSecurityList: { [key: string]: string[] } = {
6263
'style',
6364
'valign',
6465
'width',
66+
'children',
6567
],
6668
th: [
6769
'abbr',
@@ -78,8 +80,9 @@ export const htmlSecurityList: { [key: string]: string[] } = {
7880
'style',
7981
'valign',
8082
'width',
83+
'children',
8184
],
82-
tr: ['align', 'bgcolor', 'class', 'dir', 'id', 'style', 'valign'],
83-
u: ['class', 'id', 'style'],
84-
ul: ['class', 'dir', 'id', 'style'],
85+
tr: ['align', 'bgcolor', 'class', 'dir', 'id', 'style', 'valign', 'children'],
86+
u: ['class', 'id', 'style', 'children'],
87+
ul: ['class', 'dir', 'id', 'style', 'children'],
8588
};

0 commit comments

Comments
 (0)