import type { Language } from "./i18n-local";

export type ImmichText = {
  immich: string;
  immichIntro: string;
  serverUrl: string;
  apiKey: string;
  apiKeyPlaceholder: string;
  apiKeyHelp: string;
  connect: string;
  connectedAs: string;
  disconnect: string;
  openImmich: string;
  connectionSuccess: string;
  connectionFailed: string;
  disconnected: string;
  httpWarning: string;
  allPhotos: string;
  selectImmichPhotos: string;
  importSelected: string;
  importing: string;
  importSuccess: string;
  immichLoadFailed: string;
  noImmichPhotos: string;
};

export const immichTranslations: Record<Language, ImmichText> = {
  de: {
    immich: "Immich",
    immichIntro: "Füge Immich-Bilder virtuell hinzu. Vorschauen und zuletzt verwendete Originale bleiben lokal verfügbar.",
    serverUrl: "Server-URL",
    apiKey: "API-Key",
    apiKeyPlaceholder: "Nur beim Verbinden erforderlich",
    apiKeyHelp: "Benötigt: user.read, album.read, asset.read, asset.view und asset.download.",
    connect: "Verbinden und testen",
    connectedAs: "Verbunden als",
    disconnect: "Verbindung trennen",
    openImmich: "Immich-Bilder öffnen",
    connectionSuccess: "Immich wurde verbunden",
    connectionFailed: "Immich-Verbindung fehlgeschlagen",
    disconnected: "Immich-Verbindung wurde getrennt",
    httpWarning: "HTTP ist unverschlüsselt. Verwende außerhalb deines Heimnetzes HTTPS.",
    allPhotos: "Alle Fotos",
    selectImmichPhotos: "Wähle Bilder zum Importieren aus",
    importSelected: "Zur Sammlung hinzufügen",
    importing: "Bilder werden importiert…",
    importSuccess: "Immich-Bilder wurden zur Sammlung hinzugefügt",
    immichLoadFailed: "Immich-Bilder konnten nicht geladen werden",
    noImmichPhotos: "Keine Bilder gefunden",
  },
  en: {
    immich: "Immich", immichIntro: "Import images from your own Immich server.", serverUrl: "Server URL", apiKey: "API key",
    apiKeyPlaceholder: "Required only when connecting", apiKeyHelp: "Required: user.read, album.read, asset.read, asset.view and asset.download.",
    connect: "Connect and test", connectedAs: "Connected as", disconnect: "Disconnect", openImmich: "Open Immich photos",
    connectionSuccess: "Immich connected", connectionFailed: "Immich connection failed", disconnected: "Immich disconnected",
    httpWarning: "HTTP is unencrypted. Use HTTPS outside your home network.", allPhotos: "All photos",
    selectImmichPhotos: "Select images to import", importSelected: "Import selection", importing: "Importing images…",
    importSuccess: "Immich images imported", immichLoadFailed: "Could not load Immich images", noImmichPhotos: "No images found",
  },
  fr: {
    immich: "Immich", immichIntro: "Importez des images depuis votre propre serveur Immich.", serverUrl: "URL du serveur", apiKey: "Clé API",
    apiKeyPlaceholder: "Requise uniquement à la connexion", apiKeyHelp: "Requis : user.read, album.read, asset.read, asset.view et asset.download.",
    connect: "Connecter et tester", connectedAs: "Connecté en tant que", disconnect: "Déconnecter", openImmich: "Ouvrir les photos Immich",
    connectionSuccess: "Immich est connecté", connectionFailed: "Échec de la connexion Immich", disconnected: "Immich est déconnecté",
    httpWarning: "HTTP n’est pas chiffré. Utilisez HTTPS hors de votre réseau domestique.", allPhotos: "Toutes les photos",
    selectImmichPhotos: "Sélectionnez les images à importer", importSelected: "Importer la sélection", importing: "Importation des images…",
    importSuccess: "Images Immich importées", immichLoadFailed: "Impossible de charger les images Immich", noImmichPhotos: "Aucune image trouvée",
  },
  es: {
    immich: "Immich", immichIntro: "Importa imágenes desde tu propio servidor Immich.", serverUrl: "URL del servidor", apiKey: "Clave API",
    apiKeyPlaceholder: "Solo se necesita al conectar", apiKeyHelp: "Necesita: user.read, album.read, asset.read, asset.view y asset.download.",
    connect: "Conectar y probar", connectedAs: "Conectado como", disconnect: "Desconectar", openImmich: "Abrir fotos de Immich",
    connectionSuccess: "Immich conectado", connectionFailed: "Error de conexión con Immich", disconnected: "Immich desconectado",
    httpWarning: "HTTP no está cifrado. Usa HTTPS fuera de tu red doméstica.", allPhotos: "Todas las fotos",
    selectImmichPhotos: "Selecciona imágenes para importar", importSelected: "Importar selección", importing: "Importando imágenes…",
    importSuccess: "Imágenes de Immich importadas", immichLoadFailed: "No se pudieron cargar las imágenes de Immich", noImmichPhotos: "No se encontraron imágenes",
  },
  it: {
    immich: "Immich", immichIntro: "Importa immagini dal tuo server Immich.", serverUrl: "URL del server", apiKey: "Chiave API",
    apiKeyPlaceholder: "Necessaria solo durante la connessione", apiKeyHelp: "Richiede: user.read, album.read, asset.read, asset.view e asset.download.",
    connect: "Connetti e verifica", connectedAs: "Connesso come", disconnect: "Disconnetti", openImmich: "Apri foto Immich",
    connectionSuccess: "Immich connesso", connectionFailed: "Connessione a Immich non riuscita", disconnected: "Immich disconnesso",
    httpWarning: "HTTP non è crittografato. Usa HTTPS fuori dalla rete domestica.", allPhotos: "Tutte le foto",
    selectImmichPhotos: "Seleziona le immagini da importare", importSelected: "Importa selezione", importing: "Importazione immagini…",
    importSuccess: "Immagini Immich importate", immichLoadFailed: "Impossibile caricare le immagini Immich", noImmichPhotos: "Nessuna immagine trovata",
  },
  nl: {
    immich: "Immich", immichIntro: "Importeer afbeeldingen van je eigen Immich-server.", serverUrl: "Server-URL", apiKey: "API-sleutel",
    apiKeyPlaceholder: "Alleen nodig bij verbinden", apiKeyHelp: "Vereist: user.read, album.read, asset.read, asset.view en asset.download.",
    connect: "Verbinden en testen", connectedAs: "Verbonden als", disconnect: "Verbinding verbreken", openImmich: "Immich-foto’s openen",
    connectionSuccess: "Immich is verbonden", connectionFailed: "Immich-verbinding mislukt", disconnected: "Immich is losgekoppeld",
    httpWarning: "HTTP is niet versleuteld. Gebruik HTTPS buiten je thuisnetwerk.", allPhotos: "Alle foto’s",
    selectImmichPhotos: "Selecteer afbeeldingen om te importeren", importSelected: "Selectie importeren", importing: "Afbeeldingen importeren…",
    importSuccess: "Immich-afbeeldingen geïmporteerd", immichLoadFailed: "Immich-afbeeldingen konden niet worden geladen", noImmichPhotos: "Geen afbeeldingen gevonden",
  },
  pl: {
    immich: "Immich", immichIntro: "Importuj obrazy z własnego serwera Immich.", serverUrl: "Adres serwera", apiKey: "Klucz API",
    apiKeyPlaceholder: "Wymagany tylko podczas łączenia", apiKeyHelp: "Wymaga: user.read, album.read, asset.read, asset.view i asset.download.",
    connect: "Połącz i sprawdź", connectedAs: "Połączono jako", disconnect: "Rozłącz", openImmich: "Otwórz zdjęcia Immich",
    connectionSuccess: "Połączono z Immich", connectionFailed: "Nie udało się połączyć z Immich", disconnected: "Rozłączono Immich",
    httpWarning: "HTTP nie jest szyfrowany. Poza siecią domową używaj HTTPS.", allPhotos: "Wszystkie zdjęcia",
    selectImmichPhotos: "Wybierz obrazy do importu", importSelected: "Importuj wybrane", importing: "Importowanie obrazów…",
    importSuccess: "Zaimportowano obrazy Immich", immichLoadFailed: "Nie udało się wczytać obrazów Immich", noImmichPhotos: "Nie znaleziono obrazów",
  },
  pt: {
    immich: "Immich", immichIntro: "Importe imagens do seu próprio servidor Immich.", serverUrl: "URL do servidor", apiKey: "Chave de API",
    apiKeyPlaceholder: "Necessária apenas ao ligar", apiKeyHelp: "Requer: user.read, album.read, asset.read, asset.view e asset.download.",
    connect: "Ligar e testar", connectedAs: "Ligado como", disconnect: "Desligar", openImmich: "Abrir fotos do Immich",
    connectionSuccess: "Immich ligado", connectionFailed: "Falha na ligação ao Immich", disconnected: "Immich desligado",
    httpWarning: "HTTP não é encriptado. Use HTTPS fora da sua rede doméstica.", allPhotos: "Todas as fotos",
    selectImmichPhotos: "Selecione imagens para importar", importSelected: "Importar seleção", importing: "A importar imagens…",
    importSuccess: "Imagens do Immich importadas", immichLoadFailed: "Não foi possível carregar imagens do Immich", noImmichPhotos: "Nenhuma imagem encontrada",
  },
  ja: {
    immich: "Immich", immichIntro: "自分の Immich サーバーから画像を取り込みます。", serverUrl: "サーバー URL", apiKey: "API キー",
    apiKeyPlaceholder: "接続時のみ必要", apiKeyHelp: "必要権限: user.read、album.read、asset.read、asset.view、asset.download。",
    connect: "接続してテスト", connectedAs: "接続ユーザー", disconnect: "接続を解除", openImmich: "Immich の写真を開く",
    connectionSuccess: "Immich に接続しました", connectionFailed: "Immich に接続できません", disconnected: "Immich の接続を解除しました",
    httpWarning: "HTTP は暗号化されません。自宅ネットワーク外では HTTPS を使用してください。", allPhotos: "すべての写真",
    selectImmichPhotos: "取り込む画像を選択", importSelected: "選択項目を取り込む", importing: "画像を取り込み中…",
    importSuccess: "Immich の画像を取り込みました", immichLoadFailed: "Immich の画像を読み込めません", noImmichPhotos: "画像が見つかりません",
  },
  ko: {
    immich: "Immich", immichIntro: "내 Immich 서버에서 이미지를 가져옵니다.", serverUrl: "서버 URL", apiKey: "API 키",
    apiKeyPlaceholder: "연결할 때만 필요", apiKeyHelp: "필요 권한: user.read, album.read, asset.read, asset.view, asset.download.",
    connect: "연결 및 테스트", connectedAs: "연결된 사용자", disconnect: "연결 해제", openImmich: "Immich 사진 열기",
    connectionSuccess: "Immich에 연결했습니다", connectionFailed: "Immich 연결에 실패했습니다", disconnected: "Immich 연결을 해제했습니다",
    httpWarning: "HTTP는 암호화되지 않습니다. 홈 네트워크 밖에서는 HTTPS를 사용하세요.", allPhotos: "모든 사진",
    selectImmichPhotos: "가져올 이미지를 선택하세요", importSelected: "선택 항목 가져오기", importing: "이미지 가져오는 중…",
    importSuccess: "Immich 이미지를 가져왔습니다", immichLoadFailed: "Immich 이미지를 불러올 수 없습니다", noImmichPhotos: "이미지를 찾을 수 없습니다",
  },
  "zh-CN": {
    immich: "Immich", immichIntro: "从你自己的 Immich 服务器导入图片。", serverUrl: "服务器 URL", apiKey: "API 密钥",
    apiKeyPlaceholder: "仅连接时需要", apiKeyHelp: "需要权限：user.read、album.read、asset.read、asset.view 和 asset.download。",
    connect: "连接并测试", connectedAs: "连接用户", disconnect: "断开连接", openImmich: "打开 Immich 照片",
    connectionSuccess: "已连接 Immich", connectionFailed: "Immich 连接失败", disconnected: "已断开 Immich 连接",
    httpWarning: "HTTP 未加密。在家庭网络之外请使用 HTTPS。", allPhotos: "所有照片",
    selectImmichPhotos: "选择要导入的图片", importSelected: "导入所选图片", importing: "正在导入图片…",
    importSuccess: "已导入 Immich 图片", immichLoadFailed: "无法加载 Immich 图片", noImmichPhotos: "未找到图片",
  },
};
