Skip to content

Commit

Permalink
chore(locales): enhance OPML import instructions in translations (RSS…
Browse files Browse the repository at this point in the history
  • Loading branch information
abandon888 authored Nov 22, 2024
1 parent 1f349ed commit 78611bb
Show file tree
Hide file tree
Showing 10 changed files with 15 additions and 4 deletions.
6 changes: 4 additions & 2 deletions apps/renderer/src/modules/discover/import.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ const list: {
},
]

export function DiscoverImport() {
export function DiscoverImport({ isInit = false }: { isInit?: boolean }) {
const form = useForm<z.infer<typeof formSchema>>({
resolver: zodResolver(formSchema),
})
Expand Down Expand Up @@ -106,7 +106,9 @@ export function DiscoverImport() {
name="file"
render={({ field: { value, onChange, ...fieldProps } }) => (
<FormItem>
<FormLabel>{t("discover.import.opml")}</FormLabel>
<FormLabel>
{isInit ? t("discover.import.new_import_opml") : t("discover.import.opml")}
</FormLabel>
<FormControl>
<label
className="center flex h-[100px] w-full rounded-md border border-dashed"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,9 @@ export function GuideModalContent({ onClose }: { onClose: () => void }) {
},
{
title: t.app("new_user_guide.step.migrate.title"),
content: createElement(DiscoverImport),
content: createElement(DiscoverImport, {
isInit: true,
}),
icon: "i-mgc-file-import-cute-re",
},
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ export function Component() {
)
}

const TabComponent: Record<string, React.FC<{ type?: string }>> = {
const TabComponent: Record<string, React.FC<{ type?: string; isInit?: boolean }>> = {
import: DiscoverImport,
rss3: DiscoverRSS3,
inbox: DiscoverInboxList,
Expand Down
1 change: 1 addition & 0 deletions locales/app/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@
"discover.feed_maintainers": "This feed is provided by RSSHub, with credit to <maintainers />",
"discover.import.click_to_upload": "Click to upload OPML file",
"discover.import.conflictItems": "Conflict Items",
"discover.import.new_import_opml": "If you have used RSS before, you can export your data config to an OPML file and import it here",
"discover.import.noItems": "No items",
"discover.import.opml": "OPML file",
"discover.import.parsedErrorItems": "Parsed Error Items",
Expand Down
1 change: 1 addition & 0 deletions locales/app/ja.json
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@
"discover.feed_maintainers": "フィードは RSSHub が提供し <maintainers /> とともにクレジットされます。",
"discover.import.click_to_upload": "OPML ファイルをアップロードするにはクリック",
"discover.import.conflictItems": "重複アイテム",
"discover.import.new_import_opml": "以前にRSSを使用したことがある場合、データ構成をOPMLファイルにエクスポートし、ここでインポートすることができます。",
"discover.import.noItems": "アイテムなし",
"discover.import.opml": "OPML ファイル",
"discover.import.parsedErrorItems": "パースエラーのアイテム",
Expand Down
1 change: 1 addition & 0 deletions locales/app/ko.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"discover.feed_maintainers": "이 피드는 RSSHub 에서 제공하며, <maintainers />에게 크레딧을 제공합니다.",
"discover.import.click_to_upload": "OPML 파일 업로드 클릭",
"discover.import.conflictItems": "충돌 항목",
"discover.import.new_import_opml": "이전에 RSS를 사용한 적이 있다면 데이터 구성을 OPML 파일로 내보내고 여기에서 가져올 수 있습니다.",
"discover.import.noItems": "항목 없음",
"discover.import.opml": "OPML 파일",
"discover.import.parsedErrorItems": "구문 분석 오류 항목",
Expand Down
1 change: 1 addition & 0 deletions locales/app/tr.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"discover.feed_maintainers": "Bu besleme RSSHub tarafından sağlanmaktadır, <maintainers /> katkılarıyla",
"discover.import.click_to_upload": "OPML dosyasını yüklemek için tıklayın",
"discover.import.conflictItems": "Çakışan Öğeler",
"discover.import.new_import_opml": "Daha önce RSS kullandıysanız veri yapılandırmasını bir OPML dosyasına aktarabilir ve buraya aktarabilirsiniz.",
"discover.import.noItems": "Öğe yok",
"discover.import.opml": "OPML dosyası",
"discover.import.parsedErrorItems": "Ayrıştırma Hatası Olan Öğeler",
Expand Down
1 change: 1 addition & 0 deletions locales/app/zh-CN.json
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@
"discover.feed_maintainers": "由 RSSHub 提供,感谢贡献者 <maintainers />",
"discover.import.click_to_upload": "导入 OPML 文件",
"discover.import.conflictItems": "冲突项目",
"discover.import.new_import_opml": "如果您以前使用过RSS,您可以将数据配置导出到 OPML 文件,并在此处导入",
"discover.import.noItems": "没有项目",
"discover.import.opml": "OPML 文件",
"discover.import.parsedErrorItems": "解析错误项目",
Expand Down
1 change: 1 addition & 0 deletions locales/app/zh-HK.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@
"discover.feed_maintainers": "此訂閱源由 RSSHub 提供,感謝 <maintainers />",
"discover.import.click_to_upload": "上傳 OPML 文件",
"discover.import.conflictItems": "衝突項目",
"discover.import.new_import_opml": "如果您以前使用過RSS,您可以將資料配置匯出到OPML文件,並在此處匯入",
"discover.import.noItems": "沒有項目",
"discover.import.opml": "OPML 文件",
"discover.import.parsedErrorItems": "解析錯誤項目",
Expand Down
1 change: 1 addition & 0 deletions locales/app/zh-TW.json
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@
"discover.feed_maintainers": "此 feed 由 RSSHub 提供,感謝 <maintainers /> 的支持",
"discover.import.click_to_upload": "點擊上傳 OPML 文件",
"discover.import.conflictItems": "衝突項目",
"discover.import.new_import_opml": "如果您以前使用過RSS,您可以將資料配置匯出到OPML文件,並在此處匯入",
"discover.import.noItems": "沒有項目",
"discover.import.opml": "OPML 檔案",
"discover.import.parsedErrorItems": "解析錯誤項目",
Expand Down

0 comments on commit 78611bb

Please sign in to comment.