@etsoo/materialui 1.5.22 → 1.5.23
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,10 +1,9 @@
|
|
|
1
|
+
import { HTMLAttributes } from "react";
|
|
1
2
|
/**
|
|
2
3
|
* Custom HTML element properties
|
|
3
4
|
* 自定义 HTML 元素属性
|
|
4
5
|
*/
|
|
5
|
-
export type HtmlDivProps =
|
|
6
|
-
children: React.ReactNode;
|
|
7
|
-
};
|
|
6
|
+
export type HtmlDivProps = HTMLAttributes<HTMLElement>;
|
|
8
7
|
/**
|
|
9
8
|
* Custom HTML element that sanitizes and displays HTML content
|
|
10
9
|
* 自定义 HTML 元素,用于清理和显示 HTML 内容
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
+
import { HTMLAttributes } from "react";
|
|
1
2
|
/**
|
|
2
3
|
* Custom HTML element properties
|
|
3
4
|
* 自定义 HTML 元素属性
|
|
4
5
|
*/
|
|
5
|
-
export type HtmlDivProps =
|
|
6
|
-
children: React.ReactNode;
|
|
7
|
-
};
|
|
6
|
+
export type HtmlDivProps = HTMLAttributes<HTMLElement>;
|
|
8
7
|
/**
|
|
9
8
|
* Custom HTML element that sanitizes and displays HTML content
|
|
10
9
|
* 自定义 HTML 元素,用于清理和显示 HTML 内容
|
package/package.json
CHANGED
package/src/global.d.ts
CHANGED
package/src/html/HtmlDiv.tsx
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import DOMPurify from "dompurify";
|
|
2
|
+
import { HTMLAttributes } from "react";
|
|
2
3
|
|
|
3
4
|
class HtmlDivElement extends HTMLElement {
|
|
4
5
|
constructor() {
|
|
@@ -29,9 +30,7 @@ if (!customElements.get("html-div")) {
|
|
|
29
30
|
* Custom HTML element properties
|
|
30
31
|
* 自定义 HTML 元素属性
|
|
31
32
|
*/
|
|
32
|
-
export type HtmlDivProps =
|
|
33
|
-
children: React.ReactNode;
|
|
34
|
-
};
|
|
33
|
+
export type HtmlDivProps = HTMLAttributes<HTMLElement>;
|
|
35
34
|
|
|
36
35
|
/**
|
|
37
36
|
* Custom HTML element that sanitizes and displays HTML content
|