feat: export feeds, close #873
This commit is contained in:
parent
f7961edc29
commit
eae857d25e
|
|
@ -1,4 +1,5 @@
|
|||
import { IN_ELECTRON } from "@follow/shared/constants"
|
||||
import { env } from "@follow/shared/env"
|
||||
import { useQuery } from "@tanstack/react-query"
|
||||
import { useAtom } from "jotai"
|
||||
import { useCallback, useEffect } from "react"
|
||||
|
|
@ -159,6 +160,17 @@ export const SettingGeneral = () => {
|
|||
description: t("general.rebuild_database.description"),
|
||||
buttonText: t("general.rebuild_database.button"),
|
||||
},
|
||||
{
|
||||
label: t("general.export.label"),
|
||||
description: t("general.export.description"),
|
||||
buttonText: t("general.export.button"),
|
||||
action: () => {
|
||||
const link = document.createElement("a")
|
||||
link.href = `${env.VITE_API_URL}/subscriptions/export`
|
||||
link.download = "follow.opml"
|
||||
link.click()
|
||||
},
|
||||
},
|
||||
|
||||
{ type: "title", value: t("general.network"), disabled: !IN_ELECTRON },
|
||||
IN_ELECTRON && NettingSetting,
|
||||
|
|
|
|||
|
|
@ -89,6 +89,9 @@
|
|||
"general.app": "App",
|
||||
"general.data_persist.description": "Persist data locally to enable offline access and local search.",
|
||||
"general.data_persist.label": "Persist data for offline usage",
|
||||
"general.export.button": "Export",
|
||||
"general.export.description": "Export your feeds to an OPML file.",
|
||||
"general.export.label": "Export Feeds",
|
||||
"general.group_by_date.description": "Group entries by date.",
|
||||
"general.group_by_date.label": "Group by date",
|
||||
"general.language": "Language",
|
||||
|
|
|
|||
Loading…
Reference in New Issue