Skip to content

Let's use AI to Earn!

样式

daoyian03890e5812a9
diff --git a/src/components/PublishDialog/compoents/PlatParamsSetting/platParamsSetting.module.scss b/src/components/PublishDialog/compoents/PlatParamsSetting/platParamsSetting.module.scss
index b3a8c51e..42588867 100644
--- a/src/components/PublishDialog/compoents/PlatParamsSetting/platParamsSetting.module.scss
+++ b/src/components/PublishDialog/compoents/PlatParamsSetting/platParamsSetting.module.scss
@@ -40,3 +40,38 @@
align-items: center;
height: 32px;
}
+
+// 自定义Tooltip样式 - 白色背景
+.tooltipOverride {
+ :global {
+ .ant-tooltip .ant-tooltip-inner {
+ background-color: #ffffff !important;
+ color: #333333 !important;
+ border: 1px solid #d9d9d9 !important;
+ box-shadow: 0 6px 16px 0 rgba(0, 0, 0, 0.08), 0 3px 6px -4px rgba(0, 0, 0, 0.12), 0 9px 28px 8px rgba(0, 0, 0, 0.05) !important;
+ }
+
+ .ant-tooltip .ant-tooltip-arrow::before {
+ background-color: #ffffff !important;
+ border: 1px solid #d9d9d9 !important;
+ }
+ }
+}
+
+// 全局Tooltip样式覆盖
+.globalTooltipOverride {
+ :global {
+ .ant-tooltip .ant-tooltip-inner {
+ background-color: #ffffff !important;
+ color: #333333 !important;
+ border: 1px solid #d9d9d9 !important;
+ }
+
+ .ant-tooltip .ant-tooltip-arrow::before {
+ background-color: #ffffff !important;
+ border: 1px solid #d9d9d9 !important;
+ }
+ }
+}
+
+
diff --git a/src/components/PublishDialog/compoents/PlatParamsSetting/plats/PinterestParams.tsx b/src/components/PublishDialog/compoents/PlatParamsSetting/plats/PinterestParams.tsx
index 210ceb3b..7df13f35 100644
--- a/src/components/PublishDialog/compoents/PlatParamsSetting/plats/PinterestParams.tsx
+++ b/src/components/PublishDialog/compoents/PlatParamsSetting/plats/PinterestParams.tsx
@@ -16,6 +16,19 @@ import { createPinterestBoardApi } from "@/api/pinterest";
import { useAccountStore } from "@/store/account";
import { PlatType } from "@/app/config/platConfig";
+// 添加全局样式
+const tooltipStyles = `
+ .ant-tooltip .ant-tooltip-inner {
+ background-color: #ffffff !important;
+ color: #333333 !important;
+ border: 1px solid #d9d9d9 !important;
+ }
+ .ant-tooltip .ant-tooltip-arrow::before {
+ background-color: #ffffff !important;
+ border: 1px solid #d9d9d9 !important;
+ }
+`;
+
const PinterestParams = memo(
forwardRef(
({ pubItem }: IPlatsParamsProps, ref: ForwardedRef<IPlatsParamsRef>) => {
@@ -40,6 +53,17 @@ const PinterestParams = memo(
getPinterestBoards();
}, [getPinterestBoards]);
+ // 添加样式到页面
+ useEffect(() => {
+ const styleElement = document.createElement('style');
+ styleElement.textContent = tooltipStyles;
+ document.head.appendChild(styleElement);
+
+ return () => {
+ document.head.removeChild(styleElement);
+ };
+ }, []);
+
// 初始化Pinterest参数
useEffect(() => {
const option = pubItem.params.option;
@@ -139,7 +163,7 @@ const PinterestParams = memo(
<>
<CommonTitleInput pubItem={pubItem} />
<div
- className={styles.commonTitleInput}
+ className={`${styles.commonTitleInput} ${styles.tooltipOverride}`}
style={{ marginTop: "10px" }}
>
<div className="platParamsSetting-label">{t("pin.selectBoard")}</div>
@@ -154,7 +178,7 @@ const PinterestParams = memo(
</Button>
<Tooltip
title={
- <div style={{ maxHeight: "400px", overflow: "auto" }}>
+ <div style={{ maxHeight: "400px", overflow: "auto", background: "#ffffff" }}>
<div style={{ marginBottom: "1px" }}>
<Input
placeholder={t("actions.search")}