agdi 3.3.5 → 3.3.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (36) hide show
  1. package/README.md +13 -0
  2. package/dist/APEv2Parser-EU45AV6X.js +14 -0
  3. package/dist/AiffParser-FOX7GQ42.js +189 -0
  4. package/dist/AsfParser-HD5CSGIO.js +610 -0
  5. package/dist/DsdiffParser-OJREDMBI.js +188 -0
  6. package/dist/DsfParser-2YL4ARJ7.js +110 -0
  7. package/dist/FlacParser-IVV4RYF6.js +15 -0
  8. package/dist/MP4Parser-NLX4A2YN.js +1140 -0
  9. package/dist/MatroskaParser-4OEK43GF.js +654 -0
  10. package/dist/MpegParser-PXKEUF2B.js +642 -0
  11. package/dist/MusepackParser-54QGYRLY.js +322 -0
  12. package/dist/OggParser-KRV5QCGZ.js +435 -0
  13. package/dist/WavPackParser-XPZSQFVS.js +203 -0
  14. package/dist/WaveParser-27IS2RAI.js +294 -0
  15. package/dist/chunk-2B4QMSZW.js +311 -0
  16. package/dist/chunk-3JKZUGPJ.js +70 -0
  17. package/dist/chunk-4VNS5WPM.js +42 -0
  18. package/dist/chunk-65JVFJ3X.js +729 -0
  19. package/dist/chunk-6OKLAJRQ.js +0 -0
  20. package/dist/chunk-AGSFUVRG.js +439 -0
  21. package/dist/chunk-GD35BJSH.js +177 -0
  22. package/dist/chunk-HNLU36CC.js +702 -0
  23. package/dist/{chunk-M2FF7ETI.js → chunk-J6OLLWVT.js} +1 -1
  24. package/dist/chunk-LREP5CZP.js +146 -0
  25. package/dist/chunk-M54HVABG.js +34 -0
  26. package/dist/{chunk-S45VXJEO.js → chunk-OPFFFAQC.js} +19 -1
  27. package/dist/chunk-VGOIHW7D.js +1529 -0
  28. package/dist/chunk-YIHDW7JC.js +314 -0
  29. package/dist/config-D3QBUN2Y.js +13 -0
  30. package/dist/{config-ZFU7TSU2.js → config-K2XM6D4Z.js} +3 -2
  31. package/dist/{event-bus-Q3WCETQQ.js → event-bus-MO5SFUME.js} +1 -0
  32. package/dist/index.js +3273 -1274
  33. package/dist/lib-2XISBYT3.js +144950 -0
  34. package/dist/lib-HCGLI2GJ.js +4161 -0
  35. package/dist/{telemetry-service-OHU5NKON.js → telemetry-service-76YPOPDM.js} +8 -4
  36. package/package.json +6 -3
@@ -0,0 +1,146 @@
1
+ import {
2
+ getBit
3
+ } from "./chunk-GD35BJSH.js";
4
+ import {
5
+ INT8,
6
+ StringType,
7
+ UINT16_BE,
8
+ UINT32_BE,
9
+ UINT8
10
+ } from "./chunk-VGOIHW7D.js";
11
+
12
+ // ../../node_modules/.pnpm/music-metadata@11.12.0/node_modules/music-metadata/lib/id3v2/ID3v2Token.js
13
+ var AttachedPictureType = {
14
+ 0: "Other",
15
+ 1: "32x32 pixels 'file icon' (PNG only)",
16
+ 2: "Other file icon",
17
+ 3: "Cover (front)",
18
+ 4: "Cover (back)",
19
+ 5: "Leaflet page",
20
+ 6: "Media (e.g. label side of CD)",
21
+ 7: "Lead artist/lead performer/soloist",
22
+ 8: "Artist/performer",
23
+ 9: "Conductor",
24
+ 10: "Band/Orchestra",
25
+ 11: "Composer",
26
+ 12: "Lyricist/text writer",
27
+ 13: "Recording Location",
28
+ 14: "During recording",
29
+ 15: "During performance",
30
+ 16: "Movie/video screen capture",
31
+ 17: "A bright coloured fish",
32
+ 18: "Illustration",
33
+ 19: "Band/artist logotype",
34
+ 20: "Publisher/Studio logotype"
35
+ };
36
+ var LyricsContentType = {
37
+ other: 0,
38
+ lyrics: 1,
39
+ text: 2,
40
+ movement_part: 3,
41
+ events: 4,
42
+ chord: 5,
43
+ trivia_pop: 6
44
+ };
45
+ var TimestampFormat = {
46
+ notSynchronized: 0,
47
+ mpegFrameNumber: 1,
48
+ milliseconds: 2
49
+ };
50
+ var UINT32SYNCSAFE = {
51
+ get: (buf, off) => {
52
+ return buf[off + 3] & 127 | buf[off + 2] << 7 | buf[off + 1] << 14 | buf[off] << 21;
53
+ },
54
+ len: 4
55
+ };
56
+ var ID3v2Header = {
57
+ len: 10,
58
+ get: (buf, off) => {
59
+ return {
60
+ // ID3v2/file identifier "ID3"
61
+ fileIdentifier: new StringType(3, "ascii").get(buf, off),
62
+ // ID3v2 versionIndex
63
+ version: {
64
+ major: INT8.get(buf, off + 3),
65
+ revision: INT8.get(buf, off + 4)
66
+ },
67
+ // ID3v2 flags
68
+ flags: {
69
+ // Unsynchronisation
70
+ unsynchronisation: getBit(buf, off + 5, 7),
71
+ // Extended header
72
+ isExtendedHeader: getBit(buf, off + 5, 6),
73
+ // Experimental indicator
74
+ expIndicator: getBit(buf, off + 5, 5),
75
+ footer: getBit(buf, off + 5, 4)
76
+ },
77
+ size: UINT32SYNCSAFE.get(buf, off + 6)
78
+ };
79
+ }
80
+ };
81
+ var ExtendedHeader = {
82
+ len: 10,
83
+ get: (buf, off) => {
84
+ return {
85
+ // Extended header size
86
+ size: UINT32_BE.get(buf, off),
87
+ // Extended Flags
88
+ extendedFlags: UINT16_BE.get(buf, off + 4),
89
+ // Size of padding
90
+ sizeOfPadding: UINT32_BE.get(buf, off + 6),
91
+ // CRC data present
92
+ crcDataPresent: getBit(buf, off + 4, 31)
93
+ };
94
+ }
95
+ };
96
+ var TextEncodingToken = {
97
+ len: 1,
98
+ get: (uint8Array, off) => {
99
+ switch (uint8Array[off]) {
100
+ case 0:
101
+ return { encoding: "latin1" };
102
+ // binary
103
+ case 1:
104
+ return { encoding: "utf-16le", bom: true };
105
+ case 2:
106
+ return { encoding: "utf-16le", bom: false };
107
+ case 3:
108
+ return { encoding: "utf8", bom: false };
109
+ default:
110
+ return { encoding: "utf8", bom: false };
111
+ }
112
+ }
113
+ };
114
+ var TextHeader = {
115
+ len: 4,
116
+ get: (uint8Array, off) => {
117
+ return {
118
+ encoding: TextEncodingToken.get(uint8Array, off),
119
+ language: new StringType(3, "latin1").get(uint8Array, off + 1)
120
+ };
121
+ }
122
+ };
123
+ var SyncTextHeader = {
124
+ len: 6,
125
+ get: (uint8Array, off) => {
126
+ const text = TextHeader.get(uint8Array, off);
127
+ return {
128
+ encoding: text.encoding,
129
+ language: text.language,
130
+ timeStampFormat: UINT8.get(uint8Array, off + 4),
131
+ contentType: UINT8.get(uint8Array, off + 5)
132
+ };
133
+ }
134
+ };
135
+
136
+ export {
137
+ AttachedPictureType,
138
+ LyricsContentType,
139
+ TimestampFormat,
140
+ UINT32SYNCSAFE,
141
+ ID3v2Header,
142
+ ExtendedHeader,
143
+ TextEncodingToken,
144
+ TextHeader,
145
+ SyncTextHeader
146
+ };
@@ -0,0 +1,34 @@
1
+ // ../../node_modules/.pnpm/music-metadata@11.12.0/node_modules/music-metadata/lib/matroska/types.js
2
+ var TargetType = {
3
+ 10: "shot",
4
+ 20: "scene",
5
+ 30: "track",
6
+ 40: "part",
7
+ 50: "album",
8
+ 60: "edition",
9
+ 70: "collection"
10
+ };
11
+ var TrackType = {
12
+ video: 1,
13
+ audio: 2,
14
+ complex: 3,
15
+ logo: 4,
16
+ subtitle: 17,
17
+ button: 18,
18
+ control: 32
19
+ };
20
+ var TrackTypeValueToKeyMap = {
21
+ [TrackType.video]: "video",
22
+ [TrackType.audio]: "audio",
23
+ [TrackType.complex]: "complex",
24
+ [TrackType.logo]: "logo",
25
+ [TrackType.subtitle]: "subtitle",
26
+ [TrackType.button]: "button",
27
+ [TrackType.control]: "control"
28
+ };
29
+
30
+ export {
31
+ TargetType,
32
+ TrackType,
33
+ TrackTypeValueToKeyMap
34
+ };
@@ -62,8 +62,26 @@ function saveConfig(config) {
62
62
  console.error(chalk.red("Failed to save config:"), error);
63
63
  }
64
64
  }
65
+ function getConfigDir() {
66
+ return CONFIG_DIR;
67
+ }
68
+ function secureDeleteConfig() {
69
+ try {
70
+ if (fs.existsSync(CONFIG_FILE)) {
71
+ const size = fs.statSync(CONFIG_FILE).size;
72
+ const zeros = Buffer.alloc(size, 0);
73
+ fs.writeFileSync(CONFIG_FILE, zeros);
74
+ fs.unlinkSync(CONFIG_FILE);
75
+ console.log(chalk.green("\u2705 Config securely deleted"));
76
+ }
77
+ } catch (error) {
78
+ console.error(chalk.red("Failed to delete config:"), error);
79
+ }
80
+ }
65
81
 
66
82
  export {
67
83
  loadConfig,
68
- saveConfig
84
+ saveConfig,
85
+ getConfigDir,
86
+ secureDeleteConfig
69
87
  };