diff --git a/src/App.svelte b/src/App.svelte index 3096715c..b0a40b4f 100644 --- a/src/App.svelte +++ b/src/App.svelte @@ -95,6 +95,7 @@ register("en", () => import("./i18n/en")); register("es", () => import("./i18n/es")); + register("cn", () => import("./i18n/cn")); init({ fallbackLocale: "en", diff --git a/src/data/SmartQueries.ts b/src/data/SmartQueries.ts index b9e64643..8a8b9ed7 100644 --- a/src/data/SmartQueries.ts +++ b/src/data/SmartQueries.ts @@ -3,6 +3,7 @@ import type { Song } from "src/App"; import { get } from "svelte/store"; import { db } from "./db"; import { query } from "./store"; +import { LL } from "../i18n/i18n-svelte"; function allTracks(): Collection { // Not including title, because title is always populated with filename, @@ -66,18 +67,24 @@ export async function findQuery(queryId: string) { found = (await db.smartQueries.get(id)) ?? null; } } + + // If it's a built-in query, resolve the name function to get the translated text + if (found && typeof found.name === 'function') { + found = { ...found, name: found.name() }; + } + console.log("found", found); return found; } const BUILT_IN_QUERIES = { favourites: { - name: "Favourites", + name: () => get(LL).smartPlaylists.builtIn.favourites(), value: "favourites", run: favourites, }, recentlyAdded: { - name: "Recently Added", + name: () => get(LL).smartPlaylists.builtIn.recentlyAdded(), value: "recentlyAdded", run: recentlyAdded, }, diff --git a/src/i18n/cn/index.ts b/src/i18n/cn/index.ts new file mode 100644 index 00000000..27d942b1 --- /dev/null +++ b/src/i18n/cn/index.ts @@ -0,0 +1,353 @@ +import type { BaseTranslation } from "../i18n-types"; + +const cn = { + infoPopup: { + builtBy: "Built by", + andContributors: "and contributors", + version: "版本", + releaseNotes: "更新说明", + }, + sidebar: { + search: "搜索", + library: "音乐库", + albums: "专辑", + favorites: "喜爱的歌曲", + toDelete: "To Delete", + playlists: "播放列表", + smartPlaylists: "智能列表", + artistsToolkit: "艺术家工具箱", + map: "地图", + internetArchive: "互联网档案馆", + stats: "统计", + openWikiTooltip: "打开 {artist} 的维基页面", + addMetadataHint: "添加元数据", + takeControl: "Take control of your library", + iaMode: "主播放器在互联网档案馆模式下已关闭

停止播放以重新启用", + }, + library: { + fields: { + title: "标题", + artist: "艺术家", + composer: "作曲家", + album: "专辑", + albumArtist: "专辑艺术家", + track: "音轨", + compilation: "汇编", + year: "年份", + dateAdded: "添加日期", + genre: "风格", + origin: "源", + duration: "时长", + tags: "标签", + }, + resetToFileOrder: "重置文件顺序", + orderHint: "展示文件顺序", + orderHintTemp: "显示临时顺序", + orderDisabledHint: "切换到文件顺序以重新排序曲目", + queryNoResultsPlaceholder: '没有找到与 "{query}" 相关的结果', + }, + bottomBar: { + queue: "队列", + lyrics: "歌词", + lossySelector: { + lossy: "lossy", + lossless: "lossless", + both: "lossy + lossless", + }, + waveform: "波形图", + nextUp: "即将播放", + stats: { + songs: "歌曲", + artists: "艺术家", + albums: "专辑", + }, + }, + smartPlaylists: { + builtIn: { + recentlyAdded: "最近添加", + favourites: "喜爱的歌曲", + }, + builder: { + close: "关闭编辑器", + save: "保存", + placeholder: "我的智能播放列表", + addNewBlock: "新增条件块", + valid: "查询有效", + invalid: "查询无效", + parts: { + byAlbumArtist: { + title: "按专辑艺人", + example: "eg. 专辑艺人 Charlie Parker", + }, + byArtist: { + title: "按艺人", + example: "eg. 艺人 Charlie Parker", + }, + releasedBetween: { + title: "发行时间介于...", + example: "eg. 发行时间介于 1950 和 1967", + }, + releasedAfter: { + title: "发行于...之后", + example: "eg. 发行于 1950 之后", + }, + releasedIn: { + title: "发行年份", + example: "eg. 发行于 1999 年", + }, + titleContains: { + title: "歌曲标题包含...", + example: " eg. 标题包含 Love", + }, + longerThan: { + title: "时长大于...", + example: "eg. 时长大于 04:00", + }, + containsGenre: { + title: "包含流派", + example: "eg. 流派包含 Rock", + }, + fromCountry: { + title: "来自国家/地区", + example: "eg. 国家/地区 Australia", + }, + byComposer: { + title: "按作曲家", + example: "eg. 作曲家 Charles Mingus", + }, + containsTag: { + title: "包含标签", + example: "eg. 标签包含 love", + }, + }, + }, + editSmartPlaylist: "编辑智能列表", + newSmartPlaylist: "新建智能列表", + libraryPlaceholder: { + title: "智能播放列表结果将在这显示", + subtitle: "乐搜!", + }, + }, + trackInfo: { + title: "音轨信息", + subtitle: "使用 UP 或 DOWN 切换音轨", + overwriteFile: "覆写文件", + fileInfo: "文件信息", + file: "文件", + codec: "Codec", + tagType: "标签类型", + duration: "时长", + sampleRate: "采样率", + bitRate: "比特率", + enrichmentCenter: "拓展中心", + countryOfOrigin: "国家来源", + countryOfOriginTooltip: + "设置此项可在智能播放列表中使用地图视图并按国家/地区筛选。", + fetchingOriginCountry: "加载中...", + save: "保存", + fetchFromWikipedia: "从维基百科获取", + artworkReadyToSave: "准备保存", + artworkFound: "找到", + noArtwork: "没有作品", + artworkTooltip: "粘贴图片或点此选择文件", + fetchArt: "获取艺术", + metadata: "元数据", + tools: "工具", + aboutArtwork: "关于作品", + artworkTooltipTitle: "🎨 作品优先级", + artworkTooltipBody: + "

🎨 封面图优先级


首先,Musicat 会查找文件元数据中编码的封面图,您可以通过点击此方框覆盖元数据(支持 png 和 jpg 格式)。

如果没有找到封面图,它会在专辑文件夹中查找名为 cover.jpg, folder.jpgartwork.jpg (您可以在“设置”中更改此文件名列表)。

否则,它会在专辑文件夹中查找并使用该图像。", + encodedInFile: "写入元数据", + bit: "比特", + noMetadata: "歌曲没有元数据", + unsupportedFormat: + "目前尚不支持查看/编辑此文件类型的元数据。", + fix: "修复", + errors: { + nullChars: + "有些标签包含隐藏字符,导致无法正确读取。", + }, + artist: "艺术家", + fixLegacyEncodings: { + title: "修复旧版编码", + body: "如果您有使用旧版编码的 ID3 标签,请将其更新为通用的 UTF-8 编码,以便正确显示。选择编码并单击“修复”。", + hint: "选择编码方式...", + }, + setTitleFromFileNameHint: "点击即可从文件名设置标题", + differentTagTypes: + "选择具有不同标签类型的歌曲时,不支持修改元数据", + }, + settings: { + title: "设置", + library: "音乐库", + audio: "音频", + outputDevice: "输出设备", + followSystem: "跟随系统", + interface: "界面", + miniPlayerLocation: "迷你播放器位置", + language: "语言", + theme: "主题", + features: "功能", + subtitle: "配置内容", + version: "版本", + commaSeparatedFilenames: "文件名", + llms: "gpt-3.5-turbo, gpt-4, ollama", + foldersToWatch: "关注的文件夹", + folder: "{{1 文件夹 | ?? 文件夹}}", + importing: "导入中..", + coverArtFilenames: "封面图文件名", + enableArtistsToolkit: "启用艺术家工具包", + import: "导入", + enableCoverArtCheck: "启用封面图检查", + songbookLocation: "音乐珍藏册位置", + scrapbookLocation: "音乐剪贴簿位置", + downloadLocation: "下载目录", + generatedStemsLocation: "生成的分轨位置", + playlistsLocation: "播放列表目录", + enableAIFeatures: "启用AI功能", + aiModel: "AI模型 (LLM)", + openApiKey: "OpenAI API Key", + geniusApiKey: "Genius API Key", + discogsApiKey: "Discogs API Key", + }, + wiki: { + inArticle: "从您的曲库中找到相关内容:", + clickHint: "点击滚动查看详情", + albums: "专辑", + songs: "曲目", + artists: "艺术家", + }, + tagCloud: { + close: "关闭标签", + }, + artistsToolkit: { + header: { + songbookLocationHint: + "您的音乐珍藏册位置由 Musicat 管理,当前位置为 {path}", + songbookLocationHintEmpty: + "请设置需要让 Musicat 管理的音乐珍藏册。", + showScrapbook: "展示音乐剪贴簿", + hideScrapbook: "隐藏音乐剪贴簿", + }, + scrapbook: { + title: "音乐剪贴簿", + setupHint: "请在设置内添加您的音乐剪贴簿位置", + notFoundError: "无法找到音乐剪贴簿位置", + openSettings: "打开曲目", + openInFinder: "通过 Finder 打开", + }, + songDetails: { + tabs: { + lyrics: "歌词 & 和弦", + files: "文件", + other: "其他", + }, + lyricsEditor: { + options: { + alignFirstChord: "对齐首个和弦", + }, + }, + }, + }, + button: { + areYouSure: "再次点击确认", + }, + input: { + enterHintTooltip: "按 Enter 键自动完成", + }, + albums: { + title: "专辑", + options: { + orderBy: "排序方式", + orderByFields: { + title: "曲名", + artist: "艺术家", + year: "年份", + }, + showSingles: "单曲", + showInfo: "信息", + gridSize: "卡片大小", + }, + scrollToNowPlaying: "定位到当前播放", + item: { + tracksLabel: "音轨", + }, + }, + albumMenu: { + reImportAlbum: "重新导入专辑", + enrich: "⚡️ 补全", + originCountry: "来源国家", + originCountryC: "来源国家 ✅", + originCountryHint: "通过维基百科搜索", + fetchArtwork: "通过 Wikipedia 搜刮专辑图片", + fetchArtworkHint: "通过维基百科搜索", + fetchFromWikipedia: "从维基百科获取中...", + scanExistingArtwork: "本地获取专辑图片", + scanningExistingArtwork: "正在本地搜索...", + scanExistingArtworkHint: "从本地专辑文件夹中搜索专辑图片", + searchFromBrave: "通过 Brave 搜索专辑图片", + wikiPanel: "维基页面:", + removeFromLibrary: "从音乐库移除专辑", + openInFileManager: "通过 {explorerName} 打开", + infoMetadata: "信息 & 元数据" + }, + trackMenu: { + // In library + reImportTrack: "重新导入歌曲", + reImportTracks: "重新导入 {n} 个歌曲", + reImportTrackHint: "包括专辑", + separateTitle: "分轨(点击播放)", + separateStems: "音轨分离", + editTag: "编辑标签", + enrich: "⚡️ 补全", + lookingOnline: "在线查找...", + wikiPanel: "维基页面:", + removeFromLibrary: "从音乐库移除 {{ | ?? }} 首歌曲", + deleteFile: "删除 {{ | ?? }} 个文件", + deleteFileHint: "移动到系统垃圾 / 回收站", + // In queue + moreTools: "更多工具", + unselectAll: "取消选择", + removeTrackFromQueue: "从队列中移除歌曲", + removeTracksFromQueue: "从队列中移除多首歌曲", + // Both library & queue + originCountry: "来源国家", + originCountryC: "来源国家 ✅", + originCountryHint: "通过维基百科搜索", + openInFileManager: "通过 {explorerName} 打开", + infoMetadata: "信息 & 元数据" + }, + toolsMenu: { + enrich: "⚡️ 补全", + lookingOnline: "在线查找...", + originCountry: "来源国家", + originCountryC: "来源国家 ✅", + originCountryHint: "通过维基百科搜索", + chords: "和弦:", + lyrics: "歌词:", + wikiPanel: "维基页面:", + }, + toDelete: { + title: "已删除", + description: "从修剪模式中删除的曲目", + keepAllBtn: "保留全部", + deleteAllBtn: "全部移到垃圾桶", + notification: { + deleting: "正在删除 {{ | ?? 首}} 歌曲", + deleted: "已删除 {{ | ?? 首}} 歌曲", + }, + }, + lyrics: { + autoScroll: "自动滚动", + }, + stemSeparation: { + loading: "分离人声和乐器……", + complete: "分离成功", + error: "错误: {{error}}", + showStems: "显示分轨", + cancel: "取消", + close: "关闭", + }, +} satisfies BaseTranslation; + +export default cn; diff --git a/src/i18n/en/index.ts b/src/i18n/en/index.ts index 7742034f..5c2d2a71 100644 --- a/src/i18n/en/index.ts +++ b/src/i18n/en/index.ts @@ -184,6 +184,9 @@ const en = { outputDevice: "Output device", followSystem: "Same as system device", interface: "Interface", + miniPlayerLocation: "Mini Player Location", + language: "Language", + theme: "Theme", features: "Features", subtitle: "Configure stuff", version: "Version", @@ -194,6 +197,8 @@ const en = { importing: "Importing..", coverArtFilenames: "Cover art filenames", enableArtistsToolkit: "Enable Artist's Toolkit", + import: "Import", + enableCoverArtCheck: "Enable Cover Art check", songbookLocation: "Songbook location", scrapbookLocation: "Scrapbook location", downloadLocation: "Download location", @@ -268,10 +273,59 @@ const en = { tracksLabel: "tracks", }, }, + albumMenu: { + reImportAlbum: "Re-import Album", + enrich: "⚡️ Enrich", + originCountry: "Origin country", + originCountryC: "Origin country ✅", + originCountryHint: "from Wikipedia", + fetchArtwork: "Fetch artwork from Wikipedia", + fetchArtworkHint: "Save to folder as cover.jpg", + fetchFromWikipedia: "Fetching from Wikipedia...", + scanExistingArtwork: "Scan existing artwork", + scanningExistingArtwork: "Rescanning...", + scanExistingArtworkHint: "Check encoded art in tracks / folder image", + searchFromBrave: "Search for artwork on Brave", + wikiPanel: "Wiki page:", + removeFromLibrary: "Remove album from library", + openInFileManager: "Open in {explorerName}", + infoMetadata: "Info & Metadata" + }, trackMenu: { + // In library + reImportTrack: "Re-Import Track", + reImportTracks: "Re-import {n} tracks", + reImportTrackHint: "Will also re-import albums", + separateTitle: "Stems (click to play)", + separateStems: "Separate stems", + editTag: "Edit tags", + enrich: "⚡️ Enrich", + lookingOnline: "Looking online...", + wikiPanel: "Wiki panel:", removeFromLibrary: "Remove {{track | ?? tracks}} from library", deleteFile: "Delete {{file | ?? files}}", deleteFileHint: "Move to system Trash / Recycle bin", + // In queue + moreTools: "More tools", + unselectAll: "Unselect all", + removeTrackFromQueue: "Remove track from queue", + removeTracksFromQueue: "Remove tracks from queue", + // Both library & queue + originCountry: "Origin country", + originCountryC: "Origin country ✅", + originCountryHint: "from Wikipedia", + openInFileManager: "Open in {explorerName}", + infoMetadata: "Info & Metadata" + }, + toolsMenu: { + enrich: "⚡️ Enrich", + lookingOnline: "Looking online...", + originCountry: "Origin country", + originCountryC: "Origin country ✅", + originCountryHint: "from Wikipedia", + chords: "Chords:", + lyrics: "Lyrics:", + wikiPanel: "Wiki panel:", }, toDelete: { title: "To Delete", diff --git a/src/i18n/es/index.ts b/src/i18n/es/index.ts index 282b66e4..8e0213eb 100644 --- a/src/i18n/es/index.ts +++ b/src/i18n/es/index.ts @@ -54,6 +54,7 @@ const es = { lossless: "sin pérdida", both: "con y sin pérdida", }, + waveform: "", nextUp: "Siguiente", stats: { songs: "canciones", @@ -184,7 +185,10 @@ const es = { outputDevice: "Dispositivo de salida", followSystem: "Igual que dispositivo del sistema", interface: "Interfaz", + miniPlayerLocation: "", + language: "", features: "Funciones", + theme: "", subtitle: "Configura cosas", version: "Versión", commaSeparatedFilenames: "nombres de archivo", @@ -192,9 +196,15 @@ const es = { foldersToWatch: "Carpetas a vigilar", folder: "{{1 carpeta | ?? carpetas}}", importing: "Importando...", + coverArtFilenames: "", enableArtistsToolkit: "Activar Kit de herramientas del artista", + import: "", + enableCoverArtCheck: "", songbookLocation: "Ubicación del cancionero", scrapbookLocation: "Ubicación del álbum de recortes", + downloadLocation: "", + generatedStemsLocation: "", + playlistsLocation: "", enableAIFeatures: "Activar funciones de IA", aiModel: "Modelo de IA (LLM)", openApiKey: "Clave API de OpenAI", @@ -266,9 +276,22 @@ const es = { }, }, trackMenu: { + reImportTrack: "", + reImportTracks: "", + reImportTrackHint: "", + separateTitle: "", + separateStems: "", + editTag: "", + lookingOnline: "", + originCountry: "", + originCountryC: "", + originCountryHint: "", + wikiPanel: "", removeFromLibrary: "Eliminar {{track | ?? tracks}} de la biblioteca", deleteFile: "Eliminar {{file | ?? files}}", deleteFileHint: "Mover a la papelera del sistema", + openInFileManager: "Abrir en {explorerName}", + infoMetadata: "" }, toDelete: { title: "Para borrar", @@ -283,6 +306,14 @@ const es = { lyrics: { autoScroll: "Desplazamiento automático", }, + stemSeparation: { + loading: "", + complete: "", + error: "", + showStems: "", + cancel: "", + close: "", + }, } satisfies BaseTranslation; export default es; diff --git a/src/i18n/i18n-types.ts b/src/i18n/i18n-types.ts index 2d9714d6..00a351d5 100644 --- a/src/i18n/i18n-types.ts +++ b/src/i18n/i18n-types.ts @@ -6,6 +6,7 @@ export type BaseTranslation = BaseTranslationType export type BaseLocale = 'en' export type Locales = + | 'cn' | 'en' | 'es' | 'tr' @@ -571,6 +572,18 @@ type RootTranslation = { * I​n​t​e​r​f​a​c​e */ 'interface': string + /** + * M​i​n​i​ ​P​l​a​y​e​r​ ​L​o​c​a​t​i​o​n + */ + miniPlayerLocation: string + /** + * L​a​n​g​u​a​g​e + */ + language: string + /** + * T​h​e​m​e + */ + theme: string /** * F​e​a​t​u​r​e​s */ @@ -611,6 +624,14 @@ type RootTranslation = { * E​n​a​b​l​e​ ​A​r​t​i​s​t​'​s​ ​T​o​o​l​k​i​t */ enableArtistsToolkit: string + /** + * I​m​p​o​r​t + */ + 'import': string + /** + * E​n​a​b​l​e​ ​C​o​v​e​r​ ​A​r​t​ ​c​h​e​c​k + */ + enableCoverArtCheck: string /** * S​o​n​g​b​o​o​k​ ​l​o​c​a​t​i​o​n */ @@ -807,7 +828,111 @@ type RootTranslation = { tracksLabel: string } } + albumMenu: { + /** + * R​e​-​i​m​p​o​r​t​ ​A​l​b​u​m + */ + reImportAlbum: string + /** + * ⚡​️​ ​E​n​r​i​c​h + */ + enrich: string + /** + * O​r​i​g​i​n​ ​c​o​u​n​t​r​y + */ + originCountry: string + /** + * O​r​i​g​i​n​ ​c​o​u​n​t​r​y​ ​✅ + */ + originCountryC: string + /** + * f​r​o​m​ ​W​i​k​i​p​e​d​i​a + */ + originCountryHint: string + /** + * F​e​t​c​h​ ​a​r​t​w​o​r​k​ ​f​r​o​m​ ​W​i​k​i​p​e​d​i​a + */ + fetchArtwork: string + /** + * S​a​v​e​ ​t​o​ ​f​o​l​d​e​r​ ​a​s​ ​c​o​v​e​r​.​j​p​g + */ + fetchArtworkHint: string + /** + * F​e​t​c​h​i​n​g​ ​f​r​o​m​ ​W​i​k​i​p​e​d​i​a​.​.​. + */ + fetchFromWikipedia: string + /** + * S​c​a​n​ ​e​x​i​s​t​i​n​g​ ​a​r​t​w​o​r​k + */ + scanExistingArtwork: string + /** + * R​e​s​c​a​n​n​i​n​g​.​.​. + */ + scanningExistingArtwork: string + /** + * C​h​e​c​k​ ​e​n​c​o​d​e​d​ ​a​r​t​ ​i​n​ ​t​r​a​c​k​s​ ​/​ ​f​o​l​d​e​r​ ​i​m​a​g​e + */ + scanExistingArtworkHint: string + /** + * S​e​a​r​c​h​ ​f​o​r​ ​a​r​t​w​o​r​k​ ​o​n​ ​B​r​a​v​e + */ + searchFromBrave: string + /** + * W​i​k​i​ ​p​a​g​e​: + */ + wikiPanel: string + /** + * R​e​m​o​v​e​ ​a​l​b​u​m​ ​f​r​o​m​ ​l​i​b​r​a​r​y + */ + removeFromLibrary: string + /** + * O​p​e​n​ ​i​n​ ​{​e​x​p​l​o​r​e​r​N​a​m​e​} + * @param {unknown} explorerName + */ + openInFileManager: RequiredParams<'explorerName'> + /** + * I​n​f​o​ ​&​ ​M​e​t​a​d​a​t​a + */ + infoMetadata: string + } trackMenu: { + /** + * R​e​-​I​m​p​o​r​t​ ​T​r​a​c​k + */ + reImportTrack: string + /** + * R​e​-​i​m​p​o​r​t​ ​{​n​}​ ​t​r​a​c​k​s + * @param {unknown} n + */ + reImportTracks: RequiredParams<'n'> + /** + * W​i​l​l​ ​a​l​s​o​ ​r​e​-​i​m​p​o​r​t​ ​a​l​b​u​m​s + */ + reImportTrackHint: string + /** + * S​t​e​m​s​ ​(​c​l​i​c​k​ ​t​o​ ​p​l​a​y​) + */ + separateTitle: string + /** + * S​e​p​a​r​a​t​e​ ​s​t​e​m​s + */ + separateStems: string + /** + * E​d​i​t​ ​t​a​g​s + */ + editTag: string + /** + * ⚡​️​ ​E​n​r​i​c​h + */ + enrich: string + /** + * L​o​o​k​i​n​g​ ​o​n​l​i​n​e​.​.​. + */ + lookingOnline: string + /** + * W​i​k​i​ ​p​a​n​e​l​: + */ + wikiPanel: string /** * R​e​m​o​v​e​ ​{​{​t​r​a​c​k​|​?​?​ ​t​r​a​c​k​s​}​}​ ​f​r​o​m​ ​l​i​b​r​a​r​y */ @@ -820,6 +945,77 @@ type RootTranslation = { * M​o​v​e​ ​t​o​ ​s​y​s​t​e​m​ ​T​r​a​s​h​ ​/​ ​R​e​c​y​c​l​e​ ​b​i​n */ deleteFileHint: string + /** + * M​o​r​e​ ​t​o​o​l​s + */ + moreTools: string + /** + * U​n​s​e​l​e​c​t​ ​a​l​l + */ + unselectAll: string + /** + * R​e​m​o​v​e​ ​t​r​a​c​k​ ​f​r​o​m​ ​q​u​e​u​e + */ + removeTrackFromQueue: string + /** + * R​e​m​o​v​e​ ​t​r​a​c​k​s​ ​f​r​o​m​ ​q​u​e​u​e + */ + removeTracksFromQueue: string + /** + * O​r​i​g​i​n​ ​c​o​u​n​t​r​y + */ + originCountry: string + /** + * O​r​i​g​i​n​ ​c​o​u​n​t​r​y​ ​✅ + */ + originCountryC: string + /** + * f​r​o​m​ ​W​i​k​i​p​e​d​i​a + */ + originCountryHint: string + /** + * O​p​e​n​ ​i​n​ ​{​e​x​p​l​o​r​e​r​N​a​m​e​} + * @param {unknown} explorerName + */ + openInFileManager: RequiredParams<'explorerName'> + /** + * I​n​f​o​ ​&​ ​M​e​t​a​d​a​t​a + */ + infoMetadata: string + } + toolsMenu: { + /** + * ⚡​️​ ​E​n​r​i​c​h + */ + enrich: string + /** + * L​o​o​k​i​n​g​ ​o​n​l​i​n​e​.​.​. + */ + lookingOnline: string + /** + * O​r​i​g​i​n​ ​c​o​u​n​t​r​y + */ + originCountry: string + /** + * O​r​i​g​i​n​ ​c​o​u​n​t​r​y​ ​✅ + */ + originCountryC: string + /** + * f​r​o​m​ ​W​i​k​i​p​e​d​i​a + */ + originCountryHint: string + /** + * C​h​o​r​d​s​: + */ + chords: string + /** + * L​y​r​i​c​s​: + */ + lyrics: string + /** + * W​i​k​i​ ​p​a​n​e​l​: + */ + wikiPanel: string } toDelete: { /** @@ -1437,6 +1633,18 @@ export type TranslationFunctions = { * Interface */ 'interface': () => LocalizedString + /** + * Mini Player Location + */ + miniPlayerLocation: () => LocalizedString + /** + * Language + */ + language: () => LocalizedString + /** + * Theme + */ + theme: () => LocalizedString /** * Features */ @@ -1477,6 +1685,14 @@ export type TranslationFunctions = { * Enable Artist's Toolkit */ enableArtistsToolkit: () => LocalizedString + /** + * Import + */ + 'import': () => LocalizedString + /** + * Enable Cover Art check + */ + enableCoverArtCheck: () => LocalizedString /** * Songbook location */ @@ -1672,7 +1888,109 @@ export type TranslationFunctions = { tracksLabel: () => LocalizedString } } + albumMenu: { + /** + * Re-import Album + */ + reImportAlbum: () => LocalizedString + /** + * ⚡️ Enrich + */ + enrich: () => LocalizedString + /** + * Origin country + */ + originCountry: () => LocalizedString + /** + * Origin country ✅ + */ + originCountryC: () => LocalizedString + /** + * from Wikipedia + */ + originCountryHint: () => LocalizedString + /** + * Fetch artwork from Wikipedia + */ + fetchArtwork: () => LocalizedString + /** + * Save to folder as cover.jpg + */ + fetchArtworkHint: () => LocalizedString + /** + * Fetching from Wikipedia... + */ + fetchFromWikipedia: () => LocalizedString + /** + * Scan existing artwork + */ + scanExistingArtwork: () => LocalizedString + /** + * Rescanning... + */ + scanningExistingArtwork: () => LocalizedString + /** + * Check encoded art in tracks / folder image + */ + scanExistingArtworkHint: () => LocalizedString + /** + * Search for artwork on Brave + */ + searchFromBrave: () => LocalizedString + /** + * Wiki page: + */ + wikiPanel: () => LocalizedString + /** + * Remove album from library + */ + removeFromLibrary: () => LocalizedString + /** + * Open in {explorerName} + */ + openInFileManager: (arg: { explorerName: unknown }) => LocalizedString + /** + * Info & Metadata + */ + infoMetadata: () => LocalizedString + } trackMenu: { + /** + * Re-Import Track + */ + reImportTrack: () => LocalizedString + /** + * Re-import {n} tracks + */ + reImportTracks: (arg: { n: unknown }) => LocalizedString + /** + * Will also re-import albums + */ + reImportTrackHint: () => LocalizedString + /** + * Stems (click to play) + */ + separateTitle: () => LocalizedString + /** + * Separate stems + */ + separateStems: () => LocalizedString + /** + * Edit tags + */ + editTag: () => LocalizedString + /** + * ⚡️ Enrich + */ + enrich: () => LocalizedString + /** + * Looking online... + */ + lookingOnline: () => LocalizedString + /** + * Wiki panel: + */ + wikiPanel: () => LocalizedString /** * Remove {{track|?? tracks}} from library */ @@ -1685,6 +2003,76 @@ export type TranslationFunctions = { * Move to system Trash / Recycle bin */ deleteFileHint: () => LocalizedString + /** + * More tools + */ + moreTools: () => LocalizedString + /** + * Unselect all + */ + unselectAll: () => LocalizedString + /** + * Remove track from queue + */ + removeTrackFromQueue: () => LocalizedString + /** + * Remove tracks from queue + */ + removeTracksFromQueue: () => LocalizedString + /** + * Origin country + */ + originCountry: () => LocalizedString + /** + * Origin country ✅ + */ + originCountryC: () => LocalizedString + /** + * from Wikipedia + */ + originCountryHint: () => LocalizedString + /** + * Open in {explorerName} + */ + openInFileManager: (arg: { explorerName: unknown }) => LocalizedString + /** + * Info & Metadata + */ + infoMetadata: () => LocalizedString + } + toolsMenu: { + /** + * ⚡️ Enrich + */ + enrich: () => LocalizedString + /** + * Looking online... + */ + lookingOnline: () => LocalizedString + /** + * Origin country + */ + originCountry: () => LocalizedString + /** + * Origin country ✅ + */ + originCountryC: () => LocalizedString + /** + * from Wikipedia + */ + originCountryHint: () => LocalizedString + /** + * Chords: + */ + chords: () => LocalizedString + /** + * Lyrics: + */ + lyrics: () => LocalizedString + /** + * Wiki panel: + */ + wikiPanel: () => LocalizedString } toDelete: { /** diff --git a/src/i18n/i18n-util.async.ts b/src/i18n/i18n-util.async.ts index 605a3d5a..ff1e6c4b 100644 --- a/src/i18n/i18n-util.async.ts +++ b/src/i18n/i18n-util.async.ts @@ -6,6 +6,7 @@ import type { Locales, Translations } from './i18n-types' import { loadedFormatters, loadedLocales, locales } from './i18n-util' const localeTranslationLoaders = { + cn: () => import('./cn'), en: () => import('./en'), es: () => import('./es'), tr: () => import('./tr'), diff --git a/src/i18n/i18n-util.sync.ts b/src/i18n/i18n-util.sync.ts index 75084107..fad47f9d 100644 --- a/src/i18n/i18n-util.sync.ts +++ b/src/i18n/i18n-util.sync.ts @@ -5,11 +5,13 @@ import { initFormatters } from './formatters' import type { Locales, Translations } from './i18n-types' import { loadedFormatters, loadedLocales, locales } from './i18n-util' +import cn from './cn' import en from './en' import es from './es' import tr from './tr' const localeTranslations = { + cn, en, es, tr, diff --git a/src/i18n/i18n-util.ts b/src/i18n/i18n-util.ts index c63ce6c5..cc8ccf34 100644 --- a/src/i18n/i18n-util.ts +++ b/src/i18n/i18n-util.ts @@ -11,6 +11,7 @@ import type { Formatters, Locales, Translations, TranslationFunctions } from './ export const baseLocale: Locales = 'en' export const locales: Locales[] = [ + 'cn', 'en', 'es', 'tr' diff --git a/src/i18n/tr/index.ts b/src/i18n/tr/index.ts index 35c4f8e8..9bd77c25 100644 --- a/src/i18n/tr/index.ts +++ b/src/i18n/tr/index.ts @@ -54,6 +54,7 @@ const tr = { lossless: "kayıpsız", both: "kayıplı + kayıpsız", }, + waveform: "", nextUp: "Sıradaki", stats: { songs: "şarkı", @@ -140,7 +141,8 @@ const tr = { bitRate: "Bit hızı", enrichmentCenter: "Zenginleştirme Merkezi", countryOfOrigin: "Köken Ülke", - countryOfOriginTooltip: "Harita görünümünü ve Akıllı Çalma Listelerinde ülkeye göre filtrelemeyi kullanmak için bunu ayarlayın", + countryOfOriginTooltip: + "Harita görünümünü ve Akıllı Çalma Listelerinde ülkeye göre filtrelemeyi kullanmak için bunu ayarlayın", fetchingOriginCountry: "Yükleniyor...", save: "Kaydet", fetchFromWikipedia: "Wikipedia'dan getir", @@ -153,14 +155,17 @@ const tr = { tools: "Araçlar", aboutArtwork: "Kapak resmi hakkında", artworkTooltipTitle: "🎨 Kapak resmi önceliği", - artworkTooltipBody: "

🎨 Kapak resmi önceliği


Öncelikle, Musicat dosya meta verilerinde kodlanmış kapak resmini arar, bu kareye tıklayarak üzerine yazabilirsiniz (png ve jpg desteklenir).

Eğer yoksa, albüm klasöründe cover.jpg, folder.jpg veya artwork.jpg adlı bir dosya arayacaktır (bu dosya adları listesini Ayarlar'dan değiştirebilirsiniz).

Aksi takdirde, albüm klasöründeki herhangi bir resmi arayıp kullanacaktır.", + artworkTooltipBody: + "

🎨 Kapak resmi önceliği


Öncelikle, Musicat dosya meta verilerinde kodlanmış kapak resmini arar, bu kareye tıklayarak üzerine yazabilirsiniz (png ve jpg desteklenir).

Eğer yoksa, albüm klasöründe cover.jpg, folder.jpg veya artwork.jpg adlı bir dosya arayacaktır (bu dosya adları listesini Ayarlar'dan değiştirebilirsiniz).

Aksi takdirde, albüm klasöründeki herhangi bir resmi arayıp kullanacaktır.", encodedInFile: "Meta veride", bit: "bit", noMetadata: "Şarkının meta verisi yok", - unsupportedFormat: "Bu dosya türü henüz meta veri görüntüleme/düzenleme için desteklenmiyor", + unsupportedFormat: + "Bu dosya türü henüz meta veri görüntüleme/düzenleme için desteklenmiyor", fix: "Düzelt", errors: { - nullChars: "Bazı etiketlerde düzgün okunmasını engelleyen gizli karakterler var.", + nullChars: + "Bazı etiketlerde düzgün okunmasını engelleyen gizli karakterler var.", }, artist: "sanatçı", fixLegacyEncodings: { @@ -169,6 +174,7 @@ const tr = { hint: "Kodlama seçin...", }, setTitleFromFileNameHint: "Başlığı dosya adından ayarlamak için tıklayın", + differentTagTypes:"", }, settings: { title: "Ayarlar", @@ -177,6 +183,9 @@ const tr = { outputDevice: "Çıkış cihazı", followSystem: "Sistem cihazı ile aynı", interface: "Arayüz", + miniPlayerLocation: "", + language: "", + theme: "", features: "Özellikler", subtitle: "Ayarları yapılandır", version: "Sürüm", @@ -185,9 +194,15 @@ const tr = { foldersToWatch: "İzlenecek klasörler", folder: "{{1 klasör | ?? klasör}}", importing: "İçe aktarılıyor..", + coverArtFilenames: "", enableArtistsToolkit: "Sanatçı Araçlarını Etkinleştir", + import: "", + enableCoverArtCheck: "", songbookLocation: "Şarkı kitabı konumu", scrapbookLocation: "Not defteri konumu", + downloadLocation: "", + generatedStemsLocation: "", + playlistsLocation: "", enableAIFeatures: "AI özelliklerini etkinleştir", aiModel: "AI Modeli (LLM)", openApiKey: "OpenAI API Anahtarı", @@ -256,9 +271,22 @@ const tr = { }, }, trackMenu: { + reImportTrack: "", + reImportTracks: "", + reImportTrackHint: "", + separateTitle: "", + separateStems: "", + editTag: "", + lookingOnline: "", + originCountry: "", + originCountryC: "", + originCountryHint: "", + wikiPanel: "", removeFromLibrary: "{{track | ?? parça}} kütüphaneden kaldır", deleteFile: "{{file | ?? dosya}} sil", deleteFileHint: "Sistem Çöp Kutusuna taşı", + openInFileManager: "{explorerName} ile aç", + infoMetadata: "" }, toDelete: { title: "Silinecek", @@ -273,6 +301,14 @@ const tr = { lyrics: { autoScroll: "Otomatik kaydırma", }, + stemSeparation: { + loading: "", + complete: "", + error: "", + showStems: "", + cancel: "", + close: "", + }, } satisfies BaseTranslation; export default tr; diff --git a/src/lib/albums/AlbumMenu.svelte b/src/lib/albums/AlbumMenu.svelte index ea8146b1..87f3edfb 100644 --- a/src/lib/albums/AlbumMenu.svelte +++ b/src/lib/albums/AlbumMenu.svelte @@ -29,6 +29,7 @@ import { removeQueuedSongs } from "../../data/storeHelper"; import { reImport } from "../../data/LibraryUtils"; import toast from "svelte-french-toast"; + import LL from "../../i18n/i18n-svelte"; type ActionType = | "artwork-local" @@ -215,29 +216,32 @@ - + {#if song?.artist} {/if} {#if hasResult("artwork-online")} @@ -245,17 +249,20 @@ {#if hasResult("artwork-local")} {/if} {#if song?.artist} @@ -265,7 +272,8 @@ /> {/if} @@ -273,14 +281,19 @@ isDestructive={true} isConfirming={isConfirming("delete")} onClick={deleteAlbum} - text="Remove album from library" + text={$LL.albumMenu.removeFromLibrary() || + "Remove album from library"} confirmText="Click again to confirm" /> + - {/if} diff --git a/src/lib/library/CanvasLibrary.svelte b/src/lib/library/CanvasLibrary.svelte index 08efee14..21cf1597 100644 --- a/src/lib/library/CanvasLibrary.svelte +++ b/src/lib/library/CanvasLibrary.svelte @@ -2642,7 +2642,7 @@ {/if} {#if $uiView === "library" && $isPlaying && $current.song && !currentSongInView} - Scroll to Now playing + {$LL.albums.scrollToNowPlaying()} {/if} diff --git a/src/lib/library/TrackMenu.svelte b/src/lib/library/TrackMenu.svelte index c1668c7b..001ab8eb 100644 --- a/src/lib/library/TrackMenu.svelte +++ b/src/lib/library/TrackMenu.svelte @@ -364,16 +364,26 @@ /> {#if song} - + {#if stems.length === 0} - + {:else} {#each stems as stem} - + {#if song.tags}
{#each song.tags as tag} @@ -424,23 +437,28 @@ /> {#if song.artist} - + {/if}