diff --git a/src/assets/locales/zh-CN.json b/src/assets/locales/zh-CN.json index 34f4fd30..540c526d 100644 --- a/src/assets/locales/zh-CN.json +++ b/src/assets/locales/zh-CN.json @@ -638,7 +638,7 @@ "Data source": "数据来源", "Search": "搜索", "Apply": "应用", - "Auto sync new words to Eudic": "自动同步生词到欧路词典", + "Auto sync new words to Eudic": "自动同步新添加的生词到欧路词典", "When you look up a word, it will be automatically synced to your Eudic study list": "查词之后,将自动同步到欧路词典生词本中", "In trial": "试用中", "Eudic Access Token": "欧路词典访问令牌", @@ -647,7 +647,7 @@ "Enter the study list name": "输入生词本名称", "Eudic Language": "词典语言", "Language code, e.g. en / fr / de / es": "语言代码,例如 en / fr / de / es", - "Auto sync new words to AnkiConnect": "自动同步生词到 AnkiConnect", + "Auto sync new words to AnkiConnect": "自动同步新添加的生词到 AnkiConnect", "When you look up a word, it will be automatically added to an Anki deck via AnkiConnect (must be running locally)": "当你查阅一个单词时,它将通过 AnkiConnect 自动添加到 Anki 卡组中(必须在本地运行)", "Host": "主机", "e.g. 127.0.0.1": "例如 127.0.0.1", @@ -868,7 +868,7 @@ "Enable Discord Rich Presence": "启用 Discord Rich Presence", "Show your reading status and the book your're reading on your Discord profile. Discord needs to be running on your computer": "启用后会在您的 Discord 个人资料上显示您的阅读状态和正在阅读的图书。需要您在电脑上运行 Discord 客户端", "Visit": "访问", - "Auto sync notes and highlights to Notion": "自动将笔记和高亮同步到 Notion", + "Auto sync notes and highlights to Notion": "自动将新添加的笔记和高亮同步到 Notion", "Notion Integration Token": "Notion 集成令牌", "Enter your Notion integration token": "请输入您的 Notion 集成令牌", "Enter custom CSS here": "在此处输入自定义 CSS", @@ -876,16 +876,16 @@ "Custom app style": "自定义应用样式", "Customize the appearance of the entire application with CSS": "使用 CSS 自定义整个应用的外观", "Enter the ID of the Notion database to sync to": "请输入要同步的 Notion 数据库 ID", - "Auto sync notes and highlights to Yuque": "自动将笔记和高亮同步到语雀", + "Auto sync notes and highlights to Yuque": "自动将新添加的笔记和高亮同步到语雀", "Yuque Token": "语雀令牌", "Enter your Yuque personal access token": "请输入您的语雀个人访问令牌", "Yuque Namespace": "语雀命名空间", "Enter namespace, e.g. username/repo-slug": "请输入命名空间,例如:用户名/仓库标识", - "Auto sync notes and highlights to Readwise": "自动将笔记和高亮同步到 Readwise", + "Auto sync notes and highlights to Readwise": "自动将新添加的笔记和高亮同步到 Readwise", "Readwise Access Token": "Readwise 访问令牌", "Enter your Readwise access token": "请输入您的 Readwise 访问令牌", "Custom book style (CSS)": "自定义图书样式(CSS)", - "Auto sync notes and highlights to local markdown files": "自动将笔记和高亮同步到本地 Markdown 文件", + "Auto sync notes and highlights to local markdown files": "自动将新添加的笔记和高亮同步到本地 Markdown 文件", "Suitable for Obsidian, Siyuan, Joplin and other markdown-based note-taking apps. Each book will be a separate markdown file named 'Book Name.md' in the specified folder. ": "适用于 Obsidian、思源、Joplin 等基于 Markdown 的笔记应用。每本书将单独保存为一个 Markdown 文件,文件名为《书名.md》,存放在指定文件夹中。", "Markdown Sync Folder": "Markdown 同步文件夹", "Enter the folder path to save markdown files": "请输入用于保存 Markdown 文件的文件夹路径", diff --git a/src/containers/header/component.tsx b/src/containers/header/component.tsx index 1dfd1cc6..900d5f2c 100644 --- a/src/containers/header/component.tsx +++ b/src/containers/header/component.tsx @@ -589,16 +589,20 @@ class Header extends React.Component { this.props.history.push("/manager/home"); if ( ConfigService.getReaderConfig("isFirstSync") !== "no" && - ConfigService.getReaderConfig("isEnableKoodoSync") !== "yes" && - this.props.defaultSyncOption !== "webdav" && - this.props.defaultSyncOption !== "ftp" && - this.props.defaultSyncOption !== "sftp" && - this.props.defaultSyncOption !== "smb" && - this.props.defaultSyncOption !== "s3compatible" && - this.props.defaultSyncOption !== "icloud" && - this.props.defaultSyncOption !== "docker" + ConfigService.getReaderConfig("isEnableKoodoSync") !== "yes" ) { ConfigService.setReaderConfig("isFirstSync", "no"); + let config = await getCloudConfig( + ConfigService.getItem("defaultSyncOption") || "" + ); + if ( + config.url && + (config.url.includes("192.168.") || + config.url.includes("127.0.0.1") || + config.url.includes("localhost")) + ) { + return; + } let result = await vexComfirmAsync( `

${this.props.t("Enable Koodo Sync")}

${ this.props.t(