mayusculas para codigos de idiomas

This commit is contained in:
Luis Guzmán 2026-03-27 00:02:22 -06:00
parent ef41e9bc56
commit 7576fe03f8
1 changed files with 5 additions and 1 deletions

View File

@ -25,7 +25,11 @@ async function getKiwixCatalog() {
const fullDate = match[2]; const fullDate = match[2];
const size = match[3]; const size = match[3];
const cleanTitle = file.replace('.zim', '').split(/[-_]/).map(p => p.charAt(0).toUpperCase() + p.slice(1)).join(' '); const cleanTitle = file.replace('.zim', '').split(/[-_]/).map((p, index) => {
if (index === 1) return p.toUpperCase();
return p.charAt(0).toUpperCase() + p.slice(1);
}).join(' ');
const isDownloaded = localFiles.has(file); const isDownloaded = localFiles.has(file);
results.push({ results.push({