mirror of
				https://github.com/kyantech/Palmr.git
				synced 2025-11-04 05:53:23 +00:00 
			
		
		
		
	Compare commits
	
		
			2 Commits
		
	
	
		
			copilot/fi
			...
			copilot/fi
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| 
						 | 
					f950b6f60b | ||
| 
						 | 
					c19dc6d95e | 
@@ -6,12 +6,12 @@ import { FilesystemController } from "./controller";
 | 
				
			|||||||
export async function filesystemRoutes(app: FastifyInstance) {
 | 
					export async function filesystemRoutes(app: FastifyInstance) {
 | 
				
			||||||
  const filesystemController = new FilesystemController();
 | 
					  const filesystemController = new FilesystemController();
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  app.addContentTypeParser("*", async (request: FastifyRequest, payload: any) => {
 | 
					  app.addContentTypeParser("*", (request: FastifyRequest, payload: any, done: any) => {
 | 
				
			||||||
    return payload;
 | 
					    done(null, null);
 | 
				
			||||||
  });
 | 
					  });
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  app.addContentTypeParser("application/json", async (request: FastifyRequest, payload: any) => {
 | 
					  app.addContentTypeParser("application/json", (request: FastifyRequest, payload: any, done: any) => {
 | 
				
			||||||
    return payload;
 | 
					    done(null, null);
 | 
				
			||||||
  });
 | 
					  });
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  app.put(
 | 
					  app.put(
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1662,10 +1662,7 @@
 | 
				
			|||||||
    "toggle": "تبديل السمة",
 | 
					    "toggle": "تبديل السمة",
 | 
				
			||||||
    "light": "فاتح",
 | 
					    "light": "فاتح",
 | 
				
			||||||
    "dark": "داكن",
 | 
					    "dark": "داكن",
 | 
				
			||||||
    "system": "النظام",
 | 
					    "system": "النظام"
 | 
				
			||||||
    "lightDescription": "الوضع الفاتح دائماً",
 | 
					 | 
				
			||||||
    "darkDescription": "الوضع الداكن دائماً",
 | 
					 | 
				
			||||||
    "systemDescription": "اتباع تفضيلات النظام"
 | 
					 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  "twoFactor": {
 | 
					  "twoFactor": {
 | 
				
			||||||
    "title": "المصادقة الثنائية",
 | 
					    "title": "المصادقة الثنائية",
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1660,10 +1660,7 @@
 | 
				
			|||||||
    "toggle": "Design umschalten",
 | 
					    "toggle": "Design umschalten",
 | 
				
			||||||
    "light": "Hell",
 | 
					    "light": "Hell",
 | 
				
			||||||
    "dark": "Dunkel",
 | 
					    "dark": "Dunkel",
 | 
				
			||||||
    "system": "System",
 | 
					    "system": "System"
 | 
				
			||||||
    "lightDescription": "Immer heller Modus",
 | 
					 | 
				
			||||||
    "darkDescription": "Immer dunkler Modus",
 | 
					 | 
				
			||||||
    "systemDescription": "Systempräferenz folgen"
 | 
					 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  "twoFactor": {
 | 
					  "twoFactor": {
 | 
				
			||||||
    "title": "Zwei-Faktor-Authentifizierung",
 | 
					    "title": "Zwei-Faktor-Authentifizierung",
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1625,10 +1625,7 @@
 | 
				
			|||||||
    "toggle": "Toggle theme",
 | 
					    "toggle": "Toggle theme",
 | 
				
			||||||
    "light": "Light",
 | 
					    "light": "Light",
 | 
				
			||||||
    "dark": "Dark",
 | 
					    "dark": "Dark",
 | 
				
			||||||
    "system": "System",
 | 
					    "system": "System"
 | 
				
			||||||
    "lightDescription": "Always light mode",
 | 
					 | 
				
			||||||
    "darkDescription": "Always dark mode",
 | 
					 | 
				
			||||||
    "systemDescription": "Follow system preference"
 | 
					 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  "twoFactor": {
 | 
					  "twoFactor": {
 | 
				
			||||||
    "title": "Two-Factor Authentication",
 | 
					    "title": "Two-Factor Authentication",
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1660,10 +1660,7 @@
 | 
				
			|||||||
    "toggle": "Cambiar tema",
 | 
					    "toggle": "Cambiar tema",
 | 
				
			||||||
    "light": "Claro",
 | 
					    "light": "Claro",
 | 
				
			||||||
    "dark": "Oscuro",
 | 
					    "dark": "Oscuro",
 | 
				
			||||||
    "system": "Sistema",
 | 
					    "system": "Sistema"
 | 
				
			||||||
    "lightDescription": "Siempre modo claro",
 | 
					 | 
				
			||||||
    "darkDescription": "Siempre modo oscuro",
 | 
					 | 
				
			||||||
    "systemDescription": "Seguir preferencia del sistema"
 | 
					 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  "twoFactor": {
 | 
					  "twoFactor": {
 | 
				
			||||||
    "title": "Autenticación de dos factores",
 | 
					    "title": "Autenticación de dos factores",
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1660,10 +1660,7 @@
 | 
				
			|||||||
    "toggle": "Changer le thème",
 | 
					    "toggle": "Changer le thème",
 | 
				
			||||||
    "light": "Clair",
 | 
					    "light": "Clair",
 | 
				
			||||||
    "dark": "Sombre",
 | 
					    "dark": "Sombre",
 | 
				
			||||||
    "system": "Système",
 | 
					    "system": "Système"
 | 
				
			||||||
    "lightDescription": "Toujours en mode clair",
 | 
					 | 
				
			||||||
    "darkDescription": "Toujours en mode sombre",
 | 
					 | 
				
			||||||
    "systemDescription": "Suivre les préférences système"
 | 
					 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  "twoFactor": {
 | 
					  "twoFactor": {
 | 
				
			||||||
    "title": "Authentification à Deux Facteurs",
 | 
					    "title": "Authentification à Deux Facteurs",
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1660,10 +1660,7 @@
 | 
				
			|||||||
    "toggle": "थीम टॉगल करें",
 | 
					    "toggle": "थीम टॉगल करें",
 | 
				
			||||||
    "light": "लाइट",
 | 
					    "light": "लाइट",
 | 
				
			||||||
    "dark": "डार्क",
 | 
					    "dark": "डार्क",
 | 
				
			||||||
    "system": "सिस्टम",
 | 
					    "system": "सिस्टम"
 | 
				
			||||||
    "lightDescription": "हमेशा लाइट मोड",
 | 
					 | 
				
			||||||
    "darkDescription": "हमेशा डार्क मोड",
 | 
					 | 
				
			||||||
    "systemDescription": "सिस्टम प्राथमिकता का पालन करें"
 | 
					 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  "twoFactor": {
 | 
					  "twoFactor": {
 | 
				
			||||||
    "title": "दो-कारक प्रमाणीकरण",
 | 
					    "title": "दो-कारक प्रमाणीकरण",
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1660,10 +1660,7 @@
 | 
				
			|||||||
    "toggle": "Cambia tema",
 | 
					    "toggle": "Cambia tema",
 | 
				
			||||||
    "light": "Chiaro",
 | 
					    "light": "Chiaro",
 | 
				
			||||||
    "dark": "Scuro",
 | 
					    "dark": "Scuro",
 | 
				
			||||||
    "system": "Sistema",
 | 
					    "system": "Sistema"
 | 
				
			||||||
    "lightDescription": "Sempre modalità chiara",
 | 
					 | 
				
			||||||
    "darkDescription": "Sempre modalità scura",
 | 
					 | 
				
			||||||
    "systemDescription": "Segui preferenze di sistema"
 | 
					 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  "twoFactor": {
 | 
					  "twoFactor": {
 | 
				
			||||||
    "title": "Autenticazione a Due Fattori",
 | 
					    "title": "Autenticazione a Due Fattori",
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1660,10 +1660,7 @@
 | 
				
			|||||||
    "toggle": "テーマを切り替える",
 | 
					    "toggle": "テーマを切り替える",
 | 
				
			||||||
    "light": "ライト",
 | 
					    "light": "ライト",
 | 
				
			||||||
    "dark": "ダーク",
 | 
					    "dark": "ダーク",
 | 
				
			||||||
    "system": "システム",
 | 
					    "system": "システム"
 | 
				
			||||||
    "lightDescription": "常にライトモード",
 | 
					 | 
				
			||||||
    "darkDescription": "常にダークモード",
 | 
					 | 
				
			||||||
    "systemDescription": "システム設定に従う"
 | 
					 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  "twoFactor": {
 | 
					  "twoFactor": {
 | 
				
			||||||
    "title": "二要素認証",
 | 
					    "title": "二要素認証",
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1660,10 +1660,7 @@
 | 
				
			|||||||
    "toggle": "테마 전환",
 | 
					    "toggle": "테마 전환",
 | 
				
			||||||
    "light": "라이트",
 | 
					    "light": "라이트",
 | 
				
			||||||
    "dark": "다크",
 | 
					    "dark": "다크",
 | 
				
			||||||
    "system": "시스템",
 | 
					    "system": "시스템"
 | 
				
			||||||
    "lightDescription": "항상 라이트 모드",
 | 
					 | 
				
			||||||
    "darkDescription": "항상 다크 모드",
 | 
					 | 
				
			||||||
    "systemDescription": "시스템 설정 따르기"
 | 
					 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  "twoFactor": {
 | 
					  "twoFactor": {
 | 
				
			||||||
    "title": "2단계 인증",
 | 
					    "title": "2단계 인증",
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1660,10 +1660,7 @@
 | 
				
			|||||||
    "toggle": "Thema wisselen",
 | 
					    "toggle": "Thema wisselen",
 | 
				
			||||||
    "light": "Licht",
 | 
					    "light": "Licht",
 | 
				
			||||||
    "dark": "Donker",
 | 
					    "dark": "Donker",
 | 
				
			||||||
    "system": "Systeem",
 | 
					    "system": "Systeem"
 | 
				
			||||||
    "lightDescription": "Altijd lichte modus",
 | 
					 | 
				
			||||||
    "darkDescription": "Altijd donkere modus",
 | 
					 | 
				
			||||||
    "systemDescription": "Systeemvoorkeur volgen"
 | 
					 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  "twoFactor": {
 | 
					  "twoFactor": {
 | 
				
			||||||
    "title": "Twee-Factor Authenticatie",
 | 
					    "title": "Twee-Factor Authenticatie",
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1660,10 +1660,7 @@
 | 
				
			|||||||
    "toggle": "Przełącz motyw",
 | 
					    "toggle": "Przełącz motyw",
 | 
				
			||||||
    "light": "Jasny",
 | 
					    "light": "Jasny",
 | 
				
			||||||
    "dark": "Ciemny",
 | 
					    "dark": "Ciemny",
 | 
				
			||||||
    "system": "Systemowy",
 | 
					    "system": "Systemowy"
 | 
				
			||||||
    "lightDescription": "Zawsze jasny tryb",
 | 
					 | 
				
			||||||
    "darkDescription": "Zawsze ciemny tryb",
 | 
					 | 
				
			||||||
    "systemDescription": "Zgodnie z ustawieniami systemu"
 | 
					 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  "twoFactor": {
 | 
					  "twoFactor": {
 | 
				
			||||||
    "title": "Uwierzytelnianie dwuskładnikowe",
 | 
					    "title": "Uwierzytelnianie dwuskładnikowe",
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1661,10 +1661,7 @@
 | 
				
			|||||||
    "toggle": "Alternar tema",
 | 
					    "toggle": "Alternar tema",
 | 
				
			||||||
    "light": "Claro",
 | 
					    "light": "Claro",
 | 
				
			||||||
    "dark": "Escuro",
 | 
					    "dark": "Escuro",
 | 
				
			||||||
    "system": "Sistema",
 | 
					    "system": "Sistema"
 | 
				
			||||||
    "lightDescription": "Sempre modo claro",
 | 
					 | 
				
			||||||
    "darkDescription": "Sempre modo escuro",
 | 
					 | 
				
			||||||
    "systemDescription": "Seguir preferência do sistema"
 | 
					 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  "twoFactor": {
 | 
					  "twoFactor": {
 | 
				
			||||||
    "title": "Autenticação de dois fatores",
 | 
					    "title": "Autenticação de dois fatores",
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1660,10 +1660,7 @@
 | 
				
			|||||||
    "toggle": "Переключить тему",
 | 
					    "toggle": "Переключить тему",
 | 
				
			||||||
    "light": "Светлая",
 | 
					    "light": "Светлая",
 | 
				
			||||||
    "dark": "Тёмная",
 | 
					    "dark": "Тёмная",
 | 
				
			||||||
    "system": "Системная",
 | 
					    "system": "Системная"
 | 
				
			||||||
    "lightDescription": "Всегда светлая тема",
 | 
					 | 
				
			||||||
    "darkDescription": "Всегда темная тема",
 | 
					 | 
				
			||||||
    "systemDescription": "Следовать системным настройкам"
 | 
					 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  "twoFactor": {
 | 
					  "twoFactor": {
 | 
				
			||||||
    "title": "Двухфакторная аутентификация",
 | 
					    "title": "Двухфакторная аутентификация",
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1660,10 +1660,7 @@
 | 
				
			|||||||
    "toggle": "Temayı değiştir",
 | 
					    "toggle": "Temayı değiştir",
 | 
				
			||||||
    "light": "Açık",
 | 
					    "light": "Açık",
 | 
				
			||||||
    "dark": "Koyu",
 | 
					    "dark": "Koyu",
 | 
				
			||||||
    "system": "Sistem",
 | 
					    "system": "Sistem"
 | 
				
			||||||
    "lightDescription": "Her zaman açık mod",
 | 
					 | 
				
			||||||
    "darkDescription": "Her zaman koyu mod",
 | 
					 | 
				
			||||||
    "systemDescription": "Sistem tercihini takip et"
 | 
					 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  "twoFactor": {
 | 
					  "twoFactor": {
 | 
				
			||||||
    "title": "İki Faktörlü Kimlik Doğrulama",
 | 
					    "title": "İki Faktörlü Kimlik Doğrulama",
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1660,10 +1660,7 @@
 | 
				
			|||||||
    "toggle": "切换主题",
 | 
					    "toggle": "切换主题",
 | 
				
			||||||
    "light": "明亮",
 | 
					    "light": "明亮",
 | 
				
			||||||
    "dark": "暗黑",
 | 
					    "dark": "暗黑",
 | 
				
			||||||
    "system": "系统",
 | 
					    "system": "系统"
 | 
				
			||||||
    "lightDescription": "始终使用明亮模式",
 | 
					 | 
				
			||||||
    "darkDescription": "始终使用暗黑模式",
 | 
					 | 
				
			||||||
    "systemDescription": "跟随系统设置"
 | 
					 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  "twoFactor": {
 | 
					  "twoFactor": {
 | 
				
			||||||
    "title": "双重认证",
 | 
					    "title": "双重认证",
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -11,9 +11,9 @@ import { Label } from "@/components/ui/label";
 | 
				
			|||||||
import { Separator } from "@/components/ui/separator";
 | 
					import { Separator } from "@/components/ui/separator";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const THEME_OPTIONS = [
 | 
					const THEME_OPTIONS = [
 | 
				
			||||||
  { nameKey: "theme.system", value: "system", icon: IconDeviceLaptop, descriptionKey: "theme.systemDescription" },
 | 
					  { name: "System", value: "system", icon: IconDeviceLaptop, description: "Follow system preference" },
 | 
				
			||||||
  { nameKey: "theme.light", value: "light", icon: IconSun, descriptionKey: "theme.lightDescription" },
 | 
					  { name: "Light", value: "light", icon: IconSun, description: "Always light mode" },
 | 
				
			||||||
  { nameKey: "theme.dark", value: "dark", icon: IconMoon, descriptionKey: "theme.darkDescription" },
 | 
					  { name: "Dark", value: "dark", icon: IconMoon, description: "Always dark mode" },
 | 
				
			||||||
];
 | 
					];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
export function ThemePickerForm() {
 | 
					export function ThemePickerForm() {
 | 
				
			||||||
@@ -70,8 +70,8 @@ export function ThemePickerForm() {
 | 
				
			|||||||
                    <div className="flex flex-col items-center gap-3">
 | 
					                    <div className="flex flex-col items-center gap-3">
 | 
				
			||||||
                      <div className="flex flex-col items-center gap-2">
 | 
					                      <div className="flex flex-col items-center gap-2">
 | 
				
			||||||
                        <IconComponent className="w-6 h-6 text-muted-foreground" />
 | 
					                        <IconComponent className="w-6 h-6 text-muted-foreground" />
 | 
				
			||||||
                        <span className="font-medium text-base">{t(themeOption.nameKey)}</span>
 | 
					                        <span className="font-medium text-base">{themeOption.name}</span>
 | 
				
			||||||
                        <span className="text-xs text-muted-foreground">{t(themeOption.descriptionKey)}</span>
 | 
					                        <span className="text-xs text-muted-foreground">{themeOption.description}</span>
 | 
				
			||||||
                      </div>
 | 
					                      </div>
 | 
				
			||||||
                    </div>
 | 
					                    </div>
 | 
				
			||||||
                  </button>
 | 
					                  </button>
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user