-
Notifications
You must be signed in to change notification settings - Fork 3
/
frame-definitions.ts
101 lines (97 loc) · 4.12 KB
/
frame-definitions.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
/*
** List of official text information frames
** LibraryName: "T***"
** Value is the ID of the text frame specified in the link above,
** the object's keys are just for simplicity, you can also use the ID directly.
*/
export const ID3v24Frames: any = {
album: { key: 'TALB' },
albumSortOrder: { key: 'TSOA' },
artist: { key: 'TPE1' },
artistSortOrder: { key: 'TSOP' },
bpm: { key: 'TBPM' },
composer: { key: 'TCOM' },
conductor: { key: 'TPE3' },
contentGroup: { key: 'TIT1' },
copyright: { key: 'TCOP' },
date: { key: 'TDRC' },
encodedBy: { key: 'TENC' },
encodingTechnology: { key: 'TSSE' },
fileOwner: { key: 'TOWN' },
fileType: { key: 'TFLT' },
genre: { key: 'TCON' },
initialKey: { key: 'TKEY' },
internetRadioName: { key: 'TRSN' },
internetRadioOwner: { key: 'TRSO' },
isrc: { key: 'TSRC' },
language: { key: 'TLAN' },
length: { key: 'TLEN' },
mediaType: { key: 'TMED' },
mood: { key: 'TMOO' },
originalArtist: { key: 'TOPE' },
originalFilename: { key: 'TOFN' },
originalReleaseDate: { key: 'TDOR' },
originalTextwriter: { key: 'TOLY' },
originalTitle: { key: 'TOAL' },
partOfSet: { key: 'TPOS' },
performerInfo: { key: 'TPE2' },
playlistDelay: { key: 'TDLY' },
producedNotice: { key: 'TPRO' },
publisher: { key: 'TPUB' },
remixArtist: { key: 'TPE4' },
subtitle: { key: 'TIT3' },
textWriter: { key: 'TEXT' },
time: { key: 'TIME' },
title: { key: 'TIT2' },
titleSortOrder: { key: 'TSOT' },
trackNumber: { key: 'TRCK' },
};
export const ID3v23Frames: any = {
album: { key: 'TALB' },
albumSortOrder: { key: 'TSOA' },
artist: { key: 'TPE1', multiValueSeparator: ' / ' },
artistSortOrder: { key: 'TSOP' },
bpm: { key: 'TBPM' },
composer: { key: 'TCOM', multiValueSeparator: ' / ' },
conductor: { key: 'TPE3', multiValueSeparator: ' / ' },
contentGroup: { key: 'TIT1' },
copyright: { key: 'TCOP' },
date: { key: 'TDAT' },
encodedBy: { key: 'TENC' },
encodingTechnology: { key: 'TSSE' },
fileOwner: { key: 'TOWN' },
fileType: { key: 'TFLT' },
genre: { key: 'TCON', multiValueSeparator: ';' },
initialKey: { key: 'TKEY' },
internetRadioName: { key: 'TRSN' },
internetRadioOwner: { key: 'TRSO' },
isrc: { key: 'TSRC' },
language: { key: 'TLAN' },
length: { key: 'TLEN' },
mediaType: { key: 'TMED' },
originalArtist: { key: 'TOPE' },
originalFilename: { key: 'TOFN' },
originalReleaseDate: { key: 'TORY' },
originalTextwriter: { key: 'TOLY' },
originalTitle: { key: 'TOAL' },
partOfSet: { key: 'TPOS' },
performerInfo: { key: 'TPE2', multiValueSeparator: ' / ' },
playlistDelay: { key: 'TDLY' },
publisher: { key: 'TPUB' },
remixArtist: { key: 'TPE4', multiValueSeparator: ' / ' },
size: { key: 'TSIZ' },
subtitle: { key: 'TIT3' },
textWriter: { key: 'TEXT' },
title: { key: 'TIT2' },
trackNumber: { key: 'TRCK' },
};
/**
* These are v2.3 frames that were remapped in v2.4
* Listing them separately allows us to map them to the same key when saving for v2.4
* http://id3.org/id3v2.4.0-changes
*/
export const LegacyFramesRemapped: any = {
TYER: 'date',
TIME: 'date',
TRDA: 'date',
};