From 4d45dfd06e0838b2e94709d9ec77c233814c7e70 Mon Sep 17 00:00:00 2001
From: Pas <74743263+Pasithea0@users.noreply.github.com>
Date: Sat, 3 May 2025 13:40:53 -0600
Subject: [PATCH] add more language keys
---
src/assets/locales/en.json | 59 ++++++-
src/components/layout/Footer.tsx | 2 +-
.../player/atoms/settings/SettingsMenu.tsx | 4 +-
src/pages/onboarding/Onboarding.tsx | 154 +++++++++---------
src/pages/parts/settings/ConnectionsPart.tsx | 105 ++++++------
5 files changed, 183 insertions(+), 141 deletions(-)
diff --git a/src/assets/locales/en.json b/src/assets/locales/en.json
index 55caa17d..0591cddf 100644
--- a/src/assets/locales/en.json
+++ b/src/assets/locales/en.json
@@ -96,7 +96,8 @@
"discord": "Discord",
"dmca": "DMCA",
"github": "GitHub",
- "twitter": "Twitter"
+ "twitter": "Twitter",
+ "funding": "Support us"
},
"tagline": "Watch your favorite shows and movies for free with no ads ever! (っ'ヮ'c)"
},
@@ -359,6 +360,25 @@
},
"start": {
"explainer": "To get the best streams possible, you will need to choose which streaming method you want to use.",
+ "moreInfo": {
+ "button": "More info",
+ "title": "Understanding a setup",
+ "explainer": {
+ "intro": "P-Stream doesn't host videos. It relies on third-party websites for content, so you need to choose how it connects to those sites.",
+ "options": "Your Options:",
+ "extension": "1. Extension (Recommended)",
+ "extensionDescription": "The extension gives you access to the most sources. It acts as a local proxy and can handle sites that need special cookies or headers to load.",
+ "proxy": "2. Proxy",
+ "proxyDescription": "The proxy scrapes media from other websites. It bypasses browser restrictions (like CORS) to allow scraping.",
+ "default": "3. Default Setup",
+ "defaultDescription": "Uses P-Stream's built-in proxy. It's the easiest option but might be slower due to shared bandwidth.",
+ "fedapi": {
+ "fedapi": "Optional FED API (Febbox) UI token",
+ "fedapiDescription": "Bringing your own Febbox account allows you to unlock FED API, our best source with 4K quality, Dolby Atmos, the most content, and the best (fastest) load times. This the highly recommended!"
+ },
+ "outro": "If you have more questions on how this works, feel free to ask on the <0>P-Stream Discord0> server!"
+ }
+ },
"options": {
"or": "or",
"default": {
@@ -481,6 +501,10 @@
"scrapeButton": "Scrape subtitles",
"empty": "There are no provided subtitles for this.",
"notFound": "None of the available options match your query"
+ },
+ "watchparty": {
+ "watchpartyItem": "Watch Party",
+ "notice": "Watch Party might not be available for some sources"
}
},
"metadata": {
@@ -693,7 +717,8 @@
"migration": {
"description": "<0>Migrate my data0> to a new server.",
"link": "Migrate my data"
- }
+ },
+ "documentation": "Backend documentation"
},
"setup": {
"doSetup": "Do setup",
@@ -721,10 +746,15 @@
"workers": {
"addButton": "Add new worker",
"description": "To make the application function, all traffic is routed through proxies. Enable this if you want to bring your own workers. <0>Instructions.0>",
+ "documentation": "Proxy documentation",
"emptyState": "No workers yet (。•́︿•̀。), add one below",
"label": "Use custom proxy workers",
"urlLabel": "Worker URLs",
- "urlPlaceholder": "https://"
+ "urlPlaceholder": "https://",
+ "proxyTMDB": {
+ "title": "Proxy TMDB",
+ "description": "Only needed if you can't access TheMovieDB directly, such as if your ISP blocks it. It is recomended to disable the Discover secton to improve performance with this."
+ }
}
},
"preferences": {
@@ -820,5 +850,28 @@
"subtitle": "Explore the latest hits and timeless classics."
},
"scrollToTop": "Back to top"
+ },
+ "fedapi": {
+ "onboarding": {
+ "title": "Optional: FED API (Febbox) token",
+ "description": "Bring your own Febbox account to get the best streaming with 4K quality, Dolby Atmos, skip intro and the best (fastest) load times!"
+ },
+ "setup": {
+ "title": "To get your UI token:",
+ "showVideo": "Show Video Tutorial",
+ "hideVideo": "Hide Video Tutorial",
+ "step": {
+ "1": "1. Go to <0>febbox.com0> and log in with Google (use a fresh account!)",
+ "2": "2. Open DevTools or inspect the page",
+ "3": "3. Go to Application tab → Cookies",
+ "4": "4. Copy the 'ui' cookie.",
+ "5": "5. Close the tab, but do NOT logout!",
+ "warning": "(Do not share this token!)"
+ }
+ },
+ "status": {
+ "success": "success",
+ "failure": "Failed to fetch a "VIP" stream. Token is invalid or API is down!"
+ }
}
}
diff --git a/src/components/layout/Footer.tsx b/src/components/layout/Footer.tsx
index 7a8ca493..6bd5abcf 100644
--- a/src/components/layout/Footer.tsx
+++ b/src/components/layout/Footer.tsx
@@ -77,7 +77,7 @@ export function Footer() {
{t("footer.links.discord")}
- Optional: FED API (Febbox) token + {t("fedapi.onboarding.title")}
-
-
-
- >
+ {t("fedapi.setup.title")}
+
+
- 2. Open DevTools or inspect the page
-
- 3. Go to Application tab → Cookies
-
- 4. Copy the "ui" cookie.
-
- 5. Close the tab, but do NOT logout!
+
+ >
+ )}
+
+
+
+
+
- (Do not share this token!)
+
- Failed to fetch a "VIP" stream. Token is invalid or - API is down! + {t("fedapi.status.failure")}
)} > @@ -215,56 +209,56 @@ export function OnboardingPage() {
- P-Stream doesn't host videos. It relies on third-party websites
- for content, so you need to choose how it connects to those sites.
+ {t("onboarding.start.moreInfo.explainer.intro")}
- Your Options:
+ {t("onboarding.start.moreInfo.explainer.options")}
- 1. Extension (Recommended)
+
+ {t("onboarding.start.moreInfo.explainer.extension")}
+
- The extension gives you access to the most sources. It acts as a
- local proxy and can handle sites that need special cookies or
- headers to load.
+ {t("onboarding.start.moreInfo.explainer.extensionDescription")}
- 2. Proxy
+ {t("onboarding.start.moreInfo.explainer.proxy")}
- The proxy scrapes media from other websites. It bypasses browser
- restrictions (like CORS) to allow scraping.
+ {t("onboarding.start.moreInfo.explainer.proxyDescription")}
- 3. Default Setup
+ {t("onboarding.start.moreInfo.explainer.default")}
- Uses P-Stream's built-in proxy. It's the easiest option
- but might be slower due to shared bandwidth.
+ {t("onboarding.start.moreInfo.explainer.defaultDescription")}
{conf().ALLOW_FEBBOX_KEY && (
<>
- Optional FED API (Febbox) UI token
+
+ {t("onboarding.start.moreInfo.explainer.fedapi.fedapi")}
+
- Bringing your own Febbox account allows you to unlock FED API,
- our best source with 4K quality, Dolby Atmos, the most content,
- and the best (fastest) load times. This the highly recommended!
+ {t(
+ "onboarding.start.moreInfo.explainer.fedapi.fedapiDescription",
+ )}
>
)}
- If you have more questions on how this works, feel free to ask on
- the{" "}
-
- P-Stream Discord
- {" "}
- server!
+
More info
+
Proxy TMDB
++ {t("settings.connections.workers.proxyTMDB.title")} +
- Only needed if you can't access TheMovieDB directly, such - as if your ISP blocks it. It is recomended to disable the - Discover secton to improve performance with this. + {t("settings.connections.workers.proxyTMDB.description")}
- Optional: FED API (Febbox) token + {t("fedapi.onboarding.title")}
-
-
-
- >
+ {t("fedapi.setup.title")}
+
+
- 2. Open DevTools or inspect the page
-
- 3. Go to Application tab → Cookies
-
- 4. Copy the "ui" cookie.
-
- 5. Close the tab, but do NOT logout!
+
+ >
+ )}
+
+
+
+
+
- (Do not share this token!)
+
- Failed to fetch a "VIP" stream. Token is invalid or - API is down! + {t("fedapi.status.failure")}
)} >