feat: i18n
This commit is contained in:
@@ -0,0 +1,156 @@
|
||||
const en = {
|
||||
nav: {
|
||||
home: 'Home',
|
||||
library: 'Library',
|
||||
search: 'Search & download',
|
||||
downloads: 'Downloads',
|
||||
storage: 'Storage',
|
||||
playlists: 'Playlists',
|
||||
newPlaylist: 'New playlist',
|
||||
admin: 'Admin',
|
||||
settings: 'Settings',
|
||||
administration: 'Administration',
|
||||
},
|
||||
conn: {
|
||||
connected: 'Connected',
|
||||
connecting: 'Connecting…',
|
||||
disconnected: 'Offline',
|
||||
error: 'Unreachable',
|
||||
manage: 'Connection — manage instances',
|
||||
},
|
||||
user: {
|
||||
online: 'online',
|
||||
offline: 'offline',
|
||||
signOut: 'Sign out',
|
||||
},
|
||||
connect: {
|
||||
savedInstances: 'Saved instances',
|
||||
active: 'active',
|
||||
use: 'Use',
|
||||
forgetTitle: 'Forget this instance',
|
||||
form: {
|
||||
title: 'Connect to a backend',
|
||||
serverUrl: 'Server URL',
|
||||
username: 'Username',
|
||||
password: 'Password',
|
||||
submit: 'Connect',
|
||||
stubNote:
|
||||
'Stub mode — backend not wired. Connect signs in with a fake admin session, scoped to this instance.',
|
||||
},
|
||||
},
|
||||
library: {
|
||||
title: 'Library',
|
||||
searchPlaceholder: 'Search library…',
|
||||
tabs: {
|
||||
tracks: 'Tracks',
|
||||
albums: 'Albums',
|
||||
artists: 'Artists',
|
||||
},
|
||||
playAll: '▶ Play all ({{count}})',
|
||||
empty: {
|
||||
tracks: {
|
||||
title: 'No tracks',
|
||||
description: 'Your library is empty. Start by downloading some music.',
|
||||
},
|
||||
albums: {
|
||||
title: 'No albums',
|
||||
description: 'No albums in library.',
|
||||
},
|
||||
artists: {
|
||||
title: 'No artists',
|
||||
description: 'No artists in library.',
|
||||
},
|
||||
},
|
||||
albumCard: {
|
||||
tracks: '{{count}} tracks',
|
||||
tracksDuration: '{{count}} tracks · {{duration}}',
|
||||
},
|
||||
artistRow: {
|
||||
meta: '{{albumCount}} albums · {{trackCount}} tracks',
|
||||
},
|
||||
},
|
||||
album: {
|
||||
type: 'Album',
|
||||
play: '▶ Play',
|
||||
error: 'Failed to load album',
|
||||
tracksError: 'Failed to load tracks',
|
||||
empty: {
|
||||
title: 'No tracks',
|
||||
description: 'This album has no tracks.',
|
||||
},
|
||||
},
|
||||
playlist: {
|
||||
type: 'Playlist',
|
||||
play: '▶ Play',
|
||||
error: 'Failed to load playlist',
|
||||
tracksError: 'Failed to load tracks',
|
||||
empty: {
|
||||
title: 'Empty playlist',
|
||||
description: 'This playlist has no tracks yet.',
|
||||
},
|
||||
},
|
||||
player: {
|
||||
nothingPlaying: 'Nothing playing',
|
||||
shuffle: 'Shuffle',
|
||||
previous: 'Previous',
|
||||
next: 'Next',
|
||||
pause: 'Pause',
|
||||
play: 'Play',
|
||||
repeat: 'Repeat: {{mode}}',
|
||||
streaming: 'Streaming · 320 kbps',
|
||||
local: 'Local · FLAC',
|
||||
queue: 'Play queue',
|
||||
mute: 'Mute',
|
||||
unmute: 'Unmute',
|
||||
},
|
||||
queue: {
|
||||
title: 'Play queue',
|
||||
clear: 'Clear queue',
|
||||
close: 'Close',
|
||||
from: 'From {{source}}',
|
||||
radio: 'Radio · {{source}}',
|
||||
nowPlaying: 'Now playing',
|
||||
nextUp: 'Next up',
|
||||
nothingNext: 'Nothing queued next',
|
||||
empty: 'Queue is empty',
|
||||
radioActive: 'Radio active',
|
||||
mixing: '∞ mixing',
|
||||
familiar: 'Familiar',
|
||||
new: 'New',
|
||||
loadingMore: 'Loading more from radio…',
|
||||
doubleClickPlay: 'Double-click to play',
|
||||
removeFromQueue: 'Remove from queue',
|
||||
},
|
||||
track: {
|
||||
menu: {
|
||||
options: 'Track options',
|
||||
playNow: 'Play now',
|
||||
playNext: 'Play next',
|
||||
addToQueue: 'Add to queue',
|
||||
addToPlaylist: 'Add to playlist…',
|
||||
editMetadata: 'Edit metadata',
|
||||
download: 'Download',
|
||||
delete: 'Delete',
|
||||
},
|
||||
},
|
||||
common: {
|
||||
error: 'Something went wrong',
|
||||
retry: 'Retry',
|
||||
comingSoon: 'Coming soon',
|
||||
back: 'Back',
|
||||
},
|
||||
pages: {
|
||||
admin: 'Admin',
|
||||
settings: 'Settings',
|
||||
downloads: 'Downloads',
|
||||
search: 'Search & Download',
|
||||
storage: 'Storage',
|
||||
},
|
||||
} as const;
|
||||
|
||||
export default en;
|
||||
|
||||
type DeepString<T> = {
|
||||
[K in keyof T]: T[K] extends Record<string, unknown> ? DeepString<T[K]> : string;
|
||||
};
|
||||
export type Translations = DeepString<typeof en>;
|
||||
Reference in New Issue
Block a user