Merge pull request #61 from ciphera-net/staging

fix: preserve intentional OS name casing (macOS, iOS, webOS)
This commit is contained in:
Usman
2026-03-19 11:34:16 +01:00
committed by GitHub

View File

@@ -30,6 +30,8 @@ type Tab = 'browsers' | 'os' | 'devices' | 'screens'
function capitalize(s: string): string {
if (!s) return s
// Preserve intentional casing (e.g. macOS, iOS, webOS, ChromeOS, FreeBSD)
if (s !== s.toLowerCase() && s !== s.toUpperCase()) return s
return s.charAt(0).toUpperCase() + s.slice(1)
}