mirror of
https://github.com/mauriceboe/TREK.git
synced 2026-10-18 21:16:47 +00:00
c5765bbf15
The apps ship only an address screen now. Once a server is picked, the native side points the WebView at it: TrekBridgeViewController on iOS and a config copy with server.url on Android. The UI then comes from that server, in the version it runs and on its own origin, so the session cookie, uploads, /ws and plugins work exactly as in a browser and no app release has to keep pace with the servers out there. The address screen (native-shell/, built into native-dist/) probes /api/health/features through native HTTP, tries https before http when no scheme was typed, and refuses servers without the nativeApp flag. It also serves as the error page when the remembered server does not load: retry, change server, or on iOS the stored copy of the server's start page. TrekShell is the app's own plugin for all of that: remember, change and reload the server, sign in through ASWebAuthenticationSession or a Custom Tab, and on iOS keep and open the offline copy of the start page, because WKWebView runs no service worker for a domain the app does not list. Plugins the frame does not use are gone (push, camera, geolocation, calendar, file transfer, in-app browser and more): the WebView covers the camera and location itself, and push needs a relay before it is worth shipping. With them go the push entitlement, the calendar usage strings and the Firebase bits. The iOS scheme falls back to capacitor://, since Capacitor drops an iosScheme of https, and the arm64 capability replaces armv7.
27 lines
1.5 KiB
TypeScript
27 lines
1.5 KiB
TypeScript
import type { TranslationStrings } from '../types';
|
|
|
|
const native: TranslationStrings = {
|
|
'native.connect.title': 'Připojit k TREK',
|
|
'native.connect.hint': 'Zadejte adresu, na které otevíráte TREK v prohlížeči.',
|
|
'native.connect.placeholder': 'trek.example.com',
|
|
'native.connect.submit': 'Připojit',
|
|
'native.connect.checking': 'Ověřování…',
|
|
'native.connect.errorInvalid': 'To nevypadá jako webová adresa.',
|
|
'native.connect.errorUnreachable': 'Na této adrese neodpovídá žádný server. Zkontrolujte adresu a připojení.',
|
|
'native.connect.errorNotTrek': 'Server na této adrese není TREK.',
|
|
'native.connect.errorTooOld': 'Tento server TREK je pro aplikaci příliš starý. Nejprve potřebuje aktualizaci.',
|
|
'native.offline.title': 'Server není dostupný',
|
|
'native.offline.hint': 'TREK se nepodařilo spojit s {server}. Zkontrolujte připojení a zkuste to znovu.',
|
|
'native.offline.retry': 'Zkusit znovu',
|
|
'native.changeServer': 'Změnit server',
|
|
'native.login.failed': 'Přihlášení se nezdařilo. Zkuste to prosím znovu.',
|
|
'native.handoff.title': 'Pokračovat v aplikaci',
|
|
'native.handoff.hint': 'Jste přihlášeni jako {name}. Otevřete aplikaci TREK a dokončete přihlášení v ní.',
|
|
'native.handoff.open': 'Otevřít aplikaci TREK',
|
|
'native.handoff.switchAccount': 'Použít jiný účet',
|
|
'native.settings.server': 'Server',
|
|
'native.settings.serverHint': 'Tato aplikace je připojena k {server}.',
|
|
};
|
|
|
|
export default native;
|