lyrics-transcriber 0.46.0__py3-none-any.whl → 0.48.0__py3-none-any.whl
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.
- lyrics_transcriber/frontend/dist/assets/{index-BXOpmKq-.js → index-BvRLUQmZ.js} +374 -279
- lyrics_transcriber/frontend/dist/assets/index-BvRLUQmZ.js.map +1 -0
- lyrics_transcriber/frontend/dist/index.html +1 -1
- lyrics_transcriber/frontend/src/components/EditModal.tsx +36 -36
- lyrics_transcriber/frontend/src/components/EditWordList.tsx +73 -2
- lyrics_transcriber/frontend/src/components/LyricsAnalyzer.tsx +28 -6
- lyrics_transcriber/frontend/src/components/ModeSelector.tsx +35 -16
- lyrics_transcriber/frontend/src/components/TranscriptionView.tsx +26 -1
- lyrics_transcriber/frontend/src/components/shared/hooks/useWordClick.ts +3 -2
- lyrics_transcriber/frontend/src/components/shared/types.ts +1 -0
- lyrics_transcriber/frontend/src/components/shared/utils/keyboardHandlers.ts +45 -8
- lyrics_transcriber/frontend/src/components/shared/utils/segmentOperations.ts +47 -0
- lyrics_transcriber/frontend/src/types.ts +1 -1
- {lyrics_transcriber-0.46.0.dist-info → lyrics_transcriber-0.48.0.dist-info}/METADATA +1 -1
- {lyrics_transcriber-0.46.0.dist-info → lyrics_transcriber-0.48.0.dist-info}/RECORD +18 -18
- lyrics_transcriber/frontend/dist/assets/index-BXOpmKq-.js.map +0 -1
- {lyrics_transcriber-0.46.0.dist-info → lyrics_transcriber-0.48.0.dist-info}/LICENSE +0 -0
- {lyrics_transcriber-0.46.0.dist-info → lyrics_transcriber-0.48.0.dist-info}/WHEEL +0 -0
- {lyrics_transcriber-0.46.0.dist-info → lyrics_transcriber-0.48.0.dist-info}/entry_points.txt +0 -0
@@ -310,4 +310,51 @@ export function findAndReplace(
|
|
310
310
|
newData.corrected_segments = newData.corrected_segments.filter(segment => segment.words.length > 0);
|
311
311
|
|
312
312
|
return newData
|
313
|
+
}
|
314
|
+
|
315
|
+
/**
|
316
|
+
* Deletes a word from a segment in the correction data
|
317
|
+
* @param data The correction data
|
318
|
+
* @param wordId The ID of the word to delete
|
319
|
+
* @returns Updated correction data with the word removed
|
320
|
+
*/
|
321
|
+
export function deleteWord(
|
322
|
+
data: CorrectionData,
|
323
|
+
wordId: string
|
324
|
+
): CorrectionData {
|
325
|
+
// Find the segment containing this word
|
326
|
+
const segmentIndex = data.corrected_segments.findIndex(segment =>
|
327
|
+
segment.words.some(word => word.id === wordId)
|
328
|
+
);
|
329
|
+
|
330
|
+
if (segmentIndex === -1) {
|
331
|
+
// Word not found, return data unchanged
|
332
|
+
return data;
|
333
|
+
}
|
334
|
+
|
335
|
+
const segment = data.corrected_segments[segmentIndex];
|
336
|
+
const wordIndex = segment.words.findIndex(word => word.id === wordId);
|
337
|
+
|
338
|
+
if (wordIndex === -1) {
|
339
|
+
// Word not found in segment (shouldn't happen), return data unchanged
|
340
|
+
return data;
|
341
|
+
}
|
342
|
+
|
343
|
+
// Create a new segment with the word removed
|
344
|
+
const updatedWords = segment.words.filter((_, index) => index !== wordIndex);
|
345
|
+
|
346
|
+
if (updatedWords.length > 0) {
|
347
|
+
// Update the segment with the word removed
|
348
|
+
const updatedSegment = {
|
349
|
+
...segment,
|
350
|
+
words: updatedWords,
|
351
|
+
text: updatedWords.map(w => w.text).join(' ')
|
352
|
+
};
|
353
|
+
|
354
|
+
// Update the data
|
355
|
+
return updateSegment(data, segmentIndex, updatedSegment);
|
356
|
+
} else {
|
357
|
+
// If the segment would be empty, delete the entire segment
|
358
|
+
return deleteSegment(data, segmentIndex);
|
359
|
+
}
|
313
360
|
}
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.3
|
2
2
|
Name: lyrics-transcriber
|
3
|
-
Version: 0.
|
3
|
+
Version: 0.48.0
|
4
4
|
Summary: Automatically create synchronised lyrics files in ASS and MidiCo LRC formats with word-level timestamps, using Whisper and lyrics from Genius and Spotify
|
5
5
|
License: MIT
|
6
6
|
Author: Andrew Beveridge
|
@@ -26,9 +26,9 @@ lyrics_transcriber/frontend/.yarn/install-state.gz,sha256=kcgQ-S9HvdNHexkXQVt18L
|
|
26
26
|
lyrics_transcriber/frontend/.yarn/releases/yarn-4.7.0.cjs,sha256=KTYy2KCV2OpHhussV5jIPDdUSr7RftMRhqPsRUmgfAY,2765465
|
27
27
|
lyrics_transcriber/frontend/.yarnrc.yml,sha256=0hZQ1OTcPqTUNBqQeme4VFkIzrsabHNzLtc_M-wSgIM,66
|
28
28
|
lyrics_transcriber/frontend/README.md,sha256=-D6CAfKTT7Y0V3EjlZ2fMy7fyctFQ4x2TJ9vx6xtccM,1607
|
29
|
-
lyrics_transcriber/frontend/dist/assets/index-
|
30
|
-
lyrics_transcriber/frontend/dist/assets/index-
|
31
|
-
lyrics_transcriber/frontend/dist/index.html,sha256=
|
29
|
+
lyrics_transcriber/frontend/dist/assets/index-BvRLUQmZ.js,sha256=3akGaBOgucoh5DcEciZsigZY_W63wSITtGcGUAbCWl0,1230045
|
30
|
+
lyrics_transcriber/frontend/dist/assets/index-BvRLUQmZ.js.map,sha256=pLFjgGWRyykfiuvKv-i9EvM_tKH8iVma8-A54rlPvlM,2618510
|
31
|
+
lyrics_transcriber/frontend/dist/index.html,sha256=CD308I_i01AYU345UgtZmtDMVdOtuoIeENjGBv81U70,400
|
32
32
|
lyrics_transcriber/frontend/dist/vite.svg,sha256=SnSK_UQ5GLsWWRyDTEAdrjPoeGGrXbrQgRw6O0qSFPs,1497
|
33
33
|
lyrics_transcriber/frontend/eslint.config.js,sha256=3ADH23ANA4NNBKFy6nCVk65e8bx1DrVd_FIaYNnhuqA,734
|
34
34
|
lyrics_transcriber/frontend/index.html,sha256=KfqJVONzpUyPIwV73nZRiCWlwLnFWeB3z0vzxDPNudU,376
|
@@ -40,40 +40,40 @@ lyrics_transcriber/frontend/src/components/AddLyricsModal.tsx,sha256=ubJwQewryjU
|
|
40
40
|
lyrics_transcriber/frontend/src/components/AudioPlayer.tsx,sha256=amjYyYW6HZ9TD5RwqQLSmGbwk-5Ec9mtXza3F3045n4,5337
|
41
41
|
lyrics_transcriber/frontend/src/components/CorrectionMetrics.tsx,sha256=CoTZS9Z3pf4lfPrzpQ2hZvLqFvt-IarSGBSCxFxD-y4,6274
|
42
42
|
lyrics_transcriber/frontend/src/components/EditActionBar.tsx,sha256=nLRVA3m3bQFqLtqlYasn7WeZNXvPvpG0sXuIv5QXvDc,2174
|
43
|
-
lyrics_transcriber/frontend/src/components/EditModal.tsx,sha256=
|
43
|
+
lyrics_transcriber/frontend/src/components/EditModal.tsx,sha256=sv-NCKMvso3UF1_fJKbzt_wAcDLAyLqRq_D24uQRrRw,24649
|
44
44
|
lyrics_transcriber/frontend/src/components/EditTimelineSection.tsx,sha256=74dKgUv_Z9DxlHx2xiR-gShFehGUaMNG2XWsH-SUEOM,15165
|
45
|
-
lyrics_transcriber/frontend/src/components/EditWordList.tsx,sha256=
|
45
|
+
lyrics_transcriber/frontend/src/components/EditWordList.tsx,sha256=atl-9Z-24U-KWojwo0apTy1Y9DbQGoVo2dFX4P-1Z9E,13681
|
46
46
|
lyrics_transcriber/frontend/src/components/FileUpload.tsx,sha256=fwn2rMWtMLPTZLREMb3ps4prSf9nzxGwnjmeC6KYsJA,2383
|
47
47
|
lyrics_transcriber/frontend/src/components/FindReplaceModal.tsx,sha256=U7duKns4IqNXwbWFbQfdyaswnvkSRpfsU0UG__-Serc,20192
|
48
48
|
lyrics_transcriber/frontend/src/components/Header.tsx,sha256=PKFMDITEyC77ndk0emOsU6LFbPTLkWmkTLxEcndKPJY,11657
|
49
|
-
lyrics_transcriber/frontend/src/components/LyricsAnalyzer.tsx,sha256=
|
50
|
-
lyrics_transcriber/frontend/src/components/ModeSelector.tsx,sha256=
|
49
|
+
lyrics_transcriber/frontend/src/components/LyricsAnalyzer.tsx,sha256=EPCq1B8lZGXqrdcDj33YhWFfoJc7Jh3ULW_mEmc22mE,41605
|
50
|
+
lyrics_transcriber/frontend/src/components/ModeSelector.tsx,sha256=HnBAK_gFgNBJLtMC_ESMVdUapDjmqmoLX8pQeyHfpOw,2651
|
51
51
|
lyrics_transcriber/frontend/src/components/PreviewVideoSection.tsx,sha256=-9_ljoaadHjAAvia_vhEUgCajPv2jFnRDVR6VWN_a0w,4166
|
52
52
|
lyrics_transcriber/frontend/src/components/ReferenceView.tsx,sha256=thpf2ojge9pvZojUnGaiQroeHfBmxhUesO7945RGSfk,9499
|
53
53
|
lyrics_transcriber/frontend/src/components/ReviewChangesModal.tsx,sha256=zcGoIu5Iqs4ZXpGr3yeMIEKPf8FRLCP2i1TzNOmKzg0,13048
|
54
54
|
lyrics_transcriber/frontend/src/components/SegmentDetailsModal.tsx,sha256=6ME02FkFwCgDAxW49yW260N4vbr80eAJ332Ex811GOo,1643
|
55
55
|
lyrics_transcriber/frontend/src/components/TimelineEditor.tsx,sha256=Aa6ykDRVhWUNHcJ14KGzmUCPDCAltw9gXpdR5ogVQpc,12842
|
56
|
-
lyrics_transcriber/frontend/src/components/TranscriptionView.tsx,sha256=
|
56
|
+
lyrics_transcriber/frontend/src/components/TranscriptionView.tsx,sha256=uXSZcsiMsrxKhgbGUdZEfYTwjwpJbnxRl7AXGfMC0Q8,8607
|
57
57
|
lyrics_transcriber/frontend/src/components/WordDivider.tsx,sha256=tOs_4WZGlJQ1o7sZFGLhwUoyX2jSKMa6vLZqa-1vzKY,6590
|
58
58
|
lyrics_transcriber/frontend/src/components/shared/components/HighlightedText.tsx,sha256=Iopa2n7ANnPtHFu2zq7vnfwQ4SOgmBUHUfNKwBQHBxY,16203
|
59
59
|
lyrics_transcriber/frontend/src/components/shared/components/SourceSelector.tsx,sha256=FpMn-0i1NFxdIHZN0dxHkWzIIsOEi9CJc_rQMpLyxVw,2031
|
60
60
|
lyrics_transcriber/frontend/src/components/shared/components/Word.tsx,sha256=4y1kyWsAO--phTwWvRgX8nAHwSKuBYKVSuJK6j8--rg,2153
|
61
61
|
lyrics_transcriber/frontend/src/components/shared/constants.ts,sha256=25q1qjCwzV-hR72wSb_rJSe4dVuQ0l-piLMoZSpynGQ,488
|
62
|
-
lyrics_transcriber/frontend/src/components/shared/hooks/useWordClick.ts,sha256=
|
62
|
+
lyrics_transcriber/frontend/src/components/shared/hooks/useWordClick.ts,sha256=eEgBHiKIWOzFK8eBzBgcQRv7StKpaPchqh3k2kFlwgY,6253
|
63
63
|
lyrics_transcriber/frontend/src/components/shared/styles.ts,sha256=J1jCSuRqpk1mOFYAqJudhxeozH-q1bi-dsOibLukBJU,411
|
64
64
|
lyrics_transcriber/frontend/src/components/shared/types.js,sha256=1DqoH1vIn6o1ng-XyBS6JRVVkf8Hj7ub_UD4x8loMjA,77
|
65
|
-
lyrics_transcriber/frontend/src/components/shared/types.ts,sha256=
|
66
|
-
lyrics_transcriber/frontend/src/components/shared/utils/keyboardHandlers.ts,sha256=
|
65
|
+
lyrics_transcriber/frontend/src/components/shared/types.ts,sha256=HFbYnfWhejMAmAU3v-Jrf_Lm5t7WU25L83UP9rvG3M8,3949
|
66
|
+
lyrics_transcriber/frontend/src/components/shared/utils/keyboardHandlers.ts,sha256=m9vob5KWp4_8kgB7FUXbWztYTSonkNZyz5hoHXvlRUk,5832
|
67
67
|
lyrics_transcriber/frontend/src/components/shared/utils/localStorage.ts,sha256=jpLT65Rk_toaB-8X2lRGyYZ9EoMQDI45GviUT7N9Bp0,3240
|
68
68
|
lyrics_transcriber/frontend/src/components/shared/utils/referenceLineCalculator.ts,sha256=TJ2oHDitFFVxm83eFEhdlwvhx--mIt3054YbET2RiXs,2575
|
69
|
-
lyrics_transcriber/frontend/src/components/shared/utils/segmentOperations.ts,sha256=
|
69
|
+
lyrics_transcriber/frontend/src/components/shared/utils/segmentOperations.ts,sha256=yNE-4Da2nL38ofsizQUsPYWl_8Q9Ic2jbB_G3N4X7ps,12559
|
70
70
|
lyrics_transcriber/frontend/src/components/shared/utils/wordUtils.ts,sha256=bZbsvEgY3JoI15l4SdB51tHE33OkUxDH-WSG8doLcCQ,721
|
71
71
|
lyrics_transcriber/frontend/src/hooks/useManualSync.ts,sha256=fTAtHeO1Ca6o0n01DtietCHNgBFfvFEsXtQQO2orRWI,10775
|
72
72
|
lyrics_transcriber/frontend/src/main.tsx,sha256=UXPXUc2HeDuGtW5GVzP312RjCo3TdnpBal7SWild-k4,345
|
73
73
|
lyrics_transcriber/frontend/src/theme.ts,sha256=9F2xyLct_gJmvLEZEhrYdKIahUsBzi5kgnydSWJHphE,3864
|
74
74
|
lyrics_transcriber/frontend/src/types/global.d.ts,sha256=NvltPF-n4_1oRLfihD3oHXbdT7txMC8B6fhCgvNY-jk,191
|
75
75
|
lyrics_transcriber/frontend/src/types.js,sha256=1DqoH1vIn6o1ng-XyBS6JRVVkf8Hj7ub_UD4x8loMjA,77
|
76
|
-
lyrics_transcriber/frontend/src/types.ts,sha256=
|
76
|
+
lyrics_transcriber/frontend/src/types.ts,sha256=6oKpoj0ST9buEFh3IksspnVFs4msfhHplAHB_cCEwZ0,3520
|
77
77
|
lyrics_transcriber/frontend/src/validation.ts,sha256=Pv_FtySk6q3a1z_W0-ItxiEX8OIYkgCDwXKGUds4Lx4,4275
|
78
78
|
lyrics_transcriber/frontend/src/vite-env.d.ts,sha256=ZZlpNvuwQpFfe3SiAPzd5-QQ8ypmmxq5WXz6pLD63bU,38
|
79
79
|
lyrics_transcriber/frontend/tsconfig.app.json,sha256=7aUBVcaBqEtmtfQXsbwsgBxSUng06xzQi5t4QCgWQ3E,665
|
@@ -148,8 +148,8 @@ lyrics_transcriber/transcribers/base_transcriber.py,sha256=T3m4ZCwZ9Bpv6Jvb2hNcn
|
|
148
148
|
lyrics_transcriber/transcribers/whisper.py,sha256=YcCB1ic9H6zL1GS0jD0emu8-qlcH0QVEjjjYB4aLlIQ,13260
|
149
149
|
lyrics_transcriber/types.py,sha256=d73cDstrEI_tVgngDYYYFwjZNs6OVBuAB_QDkga7dWA,19841
|
150
150
|
lyrics_transcriber/utils/word_utils.py,sha256=-cMGpj9UV4F6IsoDKAV2i1aiqSO8eI91HMAm_igtVMk,958
|
151
|
-
lyrics_transcriber-0.
|
152
|
-
lyrics_transcriber-0.
|
153
|
-
lyrics_transcriber-0.
|
154
|
-
lyrics_transcriber-0.
|
155
|
-
lyrics_transcriber-0.
|
151
|
+
lyrics_transcriber-0.48.0.dist-info/LICENSE,sha256=BiPihPDxhxIPEx6yAxVfAljD5Bhm_XG2teCbPEj_m0Y,1069
|
152
|
+
lyrics_transcriber-0.48.0.dist-info/METADATA,sha256=WtzJ53EgshfdtuUw-lhOWZqfXbKEsqmKIkqrkaSP7_8,6017
|
153
|
+
lyrics_transcriber-0.48.0.dist-info/WHEEL,sha256=XbeZDeTWKc1w7CSIyre5aMDU_-PohRwTQceYnisIYYY,88
|
154
|
+
lyrics_transcriber-0.48.0.dist-info/entry_points.txt,sha256=kcp-bSFkCACAEA0t166Kek0HpaJUXRo5SlF5tVrqNBU,216
|
155
|
+
lyrics_transcriber-0.48.0.dist-info/RECORD,,
|