From b9632d207732ea6058e3dab9cba2047ab038be91 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E6=AE=B5=E6=9E=AB?=
<128354383+laogou717@users.noreply.github.com>
Date: Thu, 12 Sep 2024 13:33:03 +0800
Subject: [PATCH] Update NotionIcon.js
---
components/NotionIcon.js | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)
diff --git a/components/NotionIcon.js b/components/NotionIcon.js
index 832fc722..e60b0640 100644
--- a/components/NotionIcon.js
+++ b/components/NotionIcon.js
@@ -5,18 +5,16 @@ import LazyImage from './LazyImage'
* 可能是emoji 可能是 svg 也可能是 图片
* @returns
*/
-const NotionIcon = ({ icon, className = 'w-8 h-8 my-auto inline mr-1' }) => {
+const NotionIcon = ({ icon }) => {
if (!icon) {
return <>>
}
if (icon.startsWith('http') || icon.startsWith('data:')) {
- // 这里优先使用传入的 className
- return
+ return
}
- // 对于 emoji 或 svg,设置默认 className,也可以传递不同的样式
- return {icon}
+ return {icon}
}
-export default NotionIcon
\ No newline at end of file
+export default NotionIcon