@gondola-lyrics/kit 0.2.0 → 0.4.0

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.
@@ -3,9 +3,10 @@ import { runtime } from '@gondola-lyrics/model';
3
3
  /**
4
4
  * Generates text in the requested format, which need not match `lyric.format`.
5
5
  *
6
- * A format without a writer has no branch here, so adding one to `LyricFormat` makes this fail to compile.
6
+ * The writer map pairs each format's options with its result and requires a writer for every supported format.
7
+ * An unknown target returns `null`.
7
8
  */
8
- export declare const generate: (lyric: runtime.Lyric, target: LyricFormat, options?: LrcGenerateOptions) => LrcGenerateResult;
9
+ export declare const generate: <Target extends LyricFormat>(lyric: runtime.Lyric, target: Target, options?: GenerateOptions[Target]) => GenerateResults[Target] | null;
9
10
 
10
11
  /**
11
12
  * Generates the LRC text plus the annotations a single file cannot hold.
@@ -14,6 +15,24 @@ export declare const generate: (lyric: runtime.Lyric, target: LyricFormat, optio
14
15
  */
15
16
  export declare const generateLrc: (lyric: runtime.Lyric, options?: LrcGenerateOptions) => LrcGenerateResult;
16
17
 
18
+ declare interface GenerateOptions {
19
+ lrc: LrcGenerateOptions;
20
+ ttml: TtmlGenerateOptions;
21
+ }
22
+
23
+ declare interface GenerateResults {
24
+ lrc: LrcGenerateResult;
25
+ ttml: TtmlGenerateResult;
26
+ }
27
+
28
+ /**
29
+ * Generates one TTML document, retaining the source profile unless explicitly overridden.
30
+ *
31
+ * Offsets are baked into timestamps; a negative result or a missing required time throws.
32
+ * Profile mappings retain the lead agent and first AMLL ruby, omitting unsupported fields and instrumental nodes.
33
+ */
34
+ export declare const generateTtml: (lyric: runtime.Lyric, options?: TtmlGenerateOptions) => TtmlGenerateResult;
35
+
17
36
  declare interface LrcContent {
18
37
  original: string;
19
38
  translations?: string;
@@ -46,4 +65,25 @@ export declare type LrcGenerateResult = LrcContent;
46
65
  */
47
66
  export declare type LyricFormat = 'lrc' | 'ttml';
48
67
 
68
+ export declare interface TtmlGenerateOptions {
69
+ /**
70
+ * Defaults to the source TTML profile, or `amll` when the lyric came from another format.
71
+ */
72
+ profile?: TtmlProfile;
73
+ /**
74
+ * Indent document structure; defaults to `false`.
75
+ * Lyric content stays flush to keep formatting whitespace out of the words.
76
+ */
77
+ indent?: boolean;
78
+ /**
79
+ * Emit song metadata; defaults to `true`.
80
+ * Agents and annotation tracks are retained because the body references them.
81
+ */
82
+ includeMeta?: boolean;
83
+ }
84
+
85
+ export declare type TtmlGenerateResult = string;
86
+
87
+ export declare type TtmlProfile = 'amll' | 'itunes';
88
+
49
89
  export { }
package/dist/generator.js CHANGED
@@ -1 +1 @@
1
- export { generate, generateLrc } from "./formats.js";
1
+ export { generate, generateLrc, generateTtml } from "./formats.js";
package/dist/index.d.ts CHANGED
@@ -1,19 +1,73 @@
1
1
  import { Diagnostic } from '@gondola-lyrics/model/runtime';
2
2
  import { runtime } from '@gondola-lyrics/model';
3
3
 
4
+ /**
5
+ * Derives emphasis for normal words in lead and background vocals using complete, valid word ranges.
6
+ * The stored word duration must strictly exceed durationThreshold; metadata offset and duration have no effect.
7
+ *
8
+ * Source emphasis, including an explicit false, is preserved; derived emphasis is cleared when a word no longer qualifies.
9
+ *
10
+ * @returns The input when unchanged, or a new lyric sharing all unchanged nodes.
11
+ *
12
+ * @throws {RangeError} If durationThreshold is not a non-negative safe integer in milliseconds.
13
+ */
14
+ export declare const deriveWordEmphasis: (lyric: runtime.Lyric, options?: DeriveWordEmphasisOptions) => runtime.Lyric;
15
+
16
+ export declare interface DeriveWordEmphasisOptions {
17
+ /**
18
+ * Word duration must strictly exceed this threshold, expressed as a non-negative safe integer in milliseconds.
19
+ *
20
+ * @default 3000
21
+ */
22
+ durationThreshold?: number;
23
+ }
24
+
4
25
  /**
5
26
  * Recognition reads only the original text; the annotation tracks never decide the format.
6
27
  *
7
28
  * Unrecognized text returns `undefined`.
8
29
  */
9
- export declare const detectFormat: (input: unknown) => "lrc" | "ttml" | undefined;
30
+ export declare const detectFormat: (input: unknown) => LyricFormat | undefined;
31
+
32
+ /**
33
+ * Pulls bracketed background vocals out of the sung lines and attaches them to the line they accompany.
34
+ *
35
+ * A line holding nothing but brackets becomes a background of the line before it and is removed.
36
+ * A bracket opened on one line and closed on a later one joins the line before the opening, and both source lines go.
37
+ * Text outside brackets stays on its line, and a line left with none keeps its place.
38
+ *
39
+ * @returns The input when unchanged, or a new lyric sharing all unchanged nodes.
40
+ */
41
+ export declare const extractBackgroundLines: (lyric: runtime.Lyric, options?: ExtractBackgroundLinesOptions) => runtime.Lyric;
42
+
43
+ export declare interface ExtractBackgroundLinesOptions {
44
+ /**
45
+ * Turn a line holding nothing but brackets into a background line of the line before it.
46
+ *
47
+ * @default true
48
+ */
49
+ fullLine?: boolean;
50
+ /**
51
+ * Pull the bracketed runs inside a line out into background lines of that same line.
52
+ *
53
+ * @default true
54
+ */
55
+ inLine?: boolean;
56
+ /**
57
+ * Join a bracket opened on one line and closed on a later one, attaching it to the line before them.
58
+ *
59
+ * @default true
60
+ */
61
+ crossLine?: boolean;
62
+ }
10
63
 
11
64
  /**
12
65
  * Generates text in the requested format, which need not match `lyric.format`.
13
66
  *
14
- * A format without a writer has no branch here, so adding one to `LyricFormat` makes this fail to compile.
67
+ * The writer map pairs each format's options with its result and requires a writer for every supported format.
68
+ * An unknown target returns `null`.
15
69
  */
16
- export declare const generate: (lyric: runtime.Lyric, target: LyricFormat, options?: LrcGenerateOptions) => LrcGenerateResult;
70
+ export declare const generate: <Target extends LyricFormat>(lyric: runtime.Lyric, target: Target, options?: GenerateOptions[Target]) => GenerateResults[Target] | null;
17
71
 
18
72
  /**
19
73
  * Generates the LRC text plus the annotations a single file cannot hold.
@@ -22,6 +76,126 @@ export declare const generate: (lyric: runtime.Lyric, target: LyricFormat, optio
22
76
  */
23
77
  export declare const generateLrc: (lyric: runtime.Lyric, options?: LrcGenerateOptions) => LrcGenerateResult;
24
78
 
79
+ declare interface GenerateOptions {
80
+ lrc: LrcGenerateOptions;
81
+ ttml: TtmlGenerateOptions;
82
+ }
83
+
84
+ declare interface GenerateResults {
85
+ lrc: LrcGenerateResult;
86
+ ttml: TtmlGenerateResult;
87
+ }
88
+
89
+ /**
90
+ * Generates one TTML document, retaining the source profile unless explicitly overridden.
91
+ *
92
+ * Offsets are baked into timestamps; a negative result or a missing required time throws.
93
+ * Profile mappings retain the lead agent and first AMLL ruby, omitting unsupported fields and instrumental nodes.
94
+ */
95
+ export declare const generateTtml: (lyric: runtime.Lyric, options?: TtmlGenerateOptions) => TtmlGenerateResult;
96
+
97
+ /**
98
+ * Inserts derived instrumental lines into uncovered gaps on the stored timeline, starting at zero.
99
+ * Existing lines and background vocals occupy their full ranges; an unknown end blocks later gaps.
100
+ *
101
+ * An outro requires an explicit endTime; metadata duration and offset do not affect insertion.
102
+ *
103
+ * @returns The input when unchanged, or a new lyric and lines array sharing existing nodes.
104
+ */
105
+ export declare const insertInstrumentalLines: (lyric: runtime.Lyric, options?: InsertInstrumentalLinesOptions) => runtime.Lyric;
106
+
107
+ export declare interface InsertInstrumentalLinesOptions {
108
+ /**
109
+ * Minimum gap duration in milliseconds, including an outro.
110
+ *
111
+ * @default 10000
112
+ */
113
+ minDuration?: number;
114
+ /**
115
+ * Minimum gap duration before the first vocal in milliseconds.
116
+ *
117
+ * @default 5000
118
+ */
119
+ minIntroDuration?: number;
120
+ /**
121
+ * Outro boundary in milliseconds, measured on the same timeline as line ranges.
122
+ * An omitted boundary leaves the outro unknown.
123
+ */
124
+ endTime?: number;
125
+ }
126
+
127
+ /**
128
+ * Inserts the spaces a source left out, so CJK text set against Latin letters, digits or punctuation reads evenly.
129
+ *
130
+ * A word-level line keeps every word's time and annotation: an inserted space becomes its own space word,
131
+ * and a word the rules split yields one word per character, all sharing the original range.
132
+ * A plain-text line and the annotation tracks are rewritten as whole strings.
133
+ *
134
+ * @returns The input when unchanged, or a new lyric sharing all unchanged nodes.
135
+ */
136
+ export declare const insertSpacesInLines: (lyric: runtime.Lyric, options?: InsertSpacesOptions) => runtime.Lyric;
137
+
138
+ export declare interface InsertSpacesOptions {
139
+ /**
140
+ * Rules to apply; omitting the list applies all of them.
141
+ */
142
+ rules?: InsertSpacesRule[];
143
+ /**
144
+ * Rewrite the translation and romanization tracks too.
145
+ *
146
+ * @default true
147
+ */
148
+ annotations?: boolean;
149
+ }
150
+
151
+ export declare type InsertSpacesRule = (typeof InsertSpacesRules)[keyof typeof InsertSpacesRules];
152
+
153
+ /**
154
+ * Groups of characters a source may write without a space where one belongs.
155
+ */
156
+ export declare const InsertSpacesRules: {
157
+ /**
158
+ * A CJK character touching a Latin letter, as in `ABC中文`.
159
+ */
160
+ readonly CJK_ENGLISH: "cjkEnglish";
161
+ /**
162
+ * A CJK character touching a digit, as in `2026年`.
163
+ */
164
+ readonly CJK_NUMBER: "cjkNumber";
165
+ /**
166
+ * A comma, semicolon, exclamation mark, question mark or colon touching a character, as in `a,b`; a clock time or thousands separator such as `10:30` stays as written.
167
+ */
168
+ readonly PUNCTUATION: "punctuation";
169
+ /**
170
+ * A quotation mark touching a neighbouring character.
171
+ */
172
+ readonly QUOTE: "quote";
173
+ /**
174
+ * A bracket touching the character outside it.
175
+ */
176
+ readonly BRACKET_OUTSIDE: "bracketOutside";
177
+ /**
178
+ * A plus, equals or ampersand touching a character, as in `a+b`; a compound operator such as `a+=b` stays as written.
179
+ */
180
+ readonly MATH_OPERATOR: "mathOperator";
181
+ /**
182
+ * A hyphen touching a CJK character, as in `中-文`; a compound word such as `well-known` stays as written.
183
+ */
184
+ readonly HYPHEN: "hyphen";
185
+ /**
186
+ * A slash touching a character, as in `and/or`; a fraction such as `1/2` stays as written.
187
+ */
188
+ readonly SLASH: "slash";
189
+ /**
190
+ * Runs of two or more spaces, collapsed to one.
191
+ */
192
+ readonly COMPRESS_SPACES: "compressSpaces";
193
+ /**
194
+ * Spaces just inside a bracket or quotation mark, removed.
195
+ */
196
+ readonly TRIM_INSIDE_SYMBOLS: "trimInsideSymbols";
197
+ };
198
+
25
199
  declare interface LrcContent {
26
200
  original: string;
27
201
  translations?: string;
@@ -71,7 +245,7 @@ export declare type LyricFormat = 'lrc' | 'ttml';
71
245
  export declare const parse: (input: unknown, options?: LrcParseOptions & TtmlParseOptions) => ParseResult | null;
72
246
 
73
247
  /**
74
- * Source order, empty timed lines, and missing word times are preserved for model validation.
248
+ * Empty timed rows become instrumental lines; source order and missing word times remain for model validation.
75
249
  *
76
250
  * Annotation tracks are read as lines too and attached by timestamp, and rows that match no line are dropped.
77
251
  *
@@ -93,12 +267,39 @@ export declare interface ParseResult {
93
267
  * The profile only changes where metadata comes from, so one reader serves both.
94
268
  * A document that parses but holds no timed paragraph is `INVALID` rather than an error.
95
269
  */
96
- export declare const parseTtml: (input: string | TtmlContent, options?: TtmlParseOptions) => ParseResult;
270
+ export declare const parseTtml: (input: TtmlParseInput, options?: TtmlParseOptions) => ParseResult;
97
271
 
98
- export declare interface TtmlContent {
99
- original: string;
272
+ /**
273
+ * Removes the brackets some sources wrap around background vocals.
274
+ *
275
+ * One layer is removed from each edge of every background line, leaving a nested pair as `(x)`.
276
+ * A line left with no content is dropped, since a background line must carry something.
277
+ *
278
+ * @returns The input when unchanged, or a new lyric sharing all unchanged nodes.
279
+ */
280
+ export declare const stripBackgroundBrackets: (lyric: runtime.Lyric) => runtime.Lyric;
281
+
282
+ export declare interface TtmlGenerateOptions {
283
+ /**
284
+ * Defaults to the source TTML profile, or `amll` when the lyric came from another format.
285
+ */
286
+ profile?: TtmlProfile;
287
+ /**
288
+ * Indent document structure; defaults to `false`.
289
+ * Lyric content stays flush to keep formatting whitespace out of the words.
290
+ */
291
+ indent?: boolean;
292
+ /**
293
+ * Emit song metadata; defaults to `true`.
294
+ * Agents and annotation tracks are retained because the body references them.
295
+ */
296
+ includeMeta?: boolean;
100
297
  }
101
298
 
299
+ export declare type TtmlGenerateResult = string;
300
+
301
+ export declare type TtmlParseInput = string;
302
+
102
303
  export declare interface TtmlParseOptions {
103
304
  /** Language tag the lyric declares; the document's own `xml:lang` wins when it states one. */
104
305
  language?: string;
package/dist/index.js CHANGED
@@ -1,3 +1,5 @@
1
- export { detectFormat, generate, generateLrc, parse, parseLrc, parseTtml } from "./formats.js";
1
+ import { detectFormat, generate, generateLrc, generateTtml, parse, parseLrc, parseTtml } from "./formats.js";
2
+ import { InsertSpacesRules, deriveWordEmphasis, extractBackgroundLines, insertInstrumentalLines, insertSpacesInLines, stripBackgroundBrackets } from "./transforms.js";
2
3
  import "./parser.js";
3
4
  import "./generator.js";
5
+ export { InsertSpacesRules, deriveWordEmphasis, detectFormat, extractBackgroundLines, generate, generateLrc, generateTtml, insertInstrumentalLines, insertSpacesInLines, parse, parseLrc, parseTtml, stripBackgroundBrackets };
package/dist/parser.d.ts CHANGED
@@ -1,12 +1,167 @@
1
1
  import { Diagnostic } from '@gondola-lyrics/model/runtime';
2
2
  import { runtime } from '@gondola-lyrics/model';
3
3
 
4
+ /**
5
+ * Derives emphasis for normal words in lead and background vocals using complete, valid word ranges.
6
+ * The stored word duration must strictly exceed durationThreshold; metadata offset and duration have no effect.
7
+ *
8
+ * Source emphasis, including an explicit false, is preserved; derived emphasis is cleared when a word no longer qualifies.
9
+ *
10
+ * @returns The input when unchanged, or a new lyric sharing all unchanged nodes.
11
+ *
12
+ * @throws {RangeError} If durationThreshold is not a non-negative safe integer in milliseconds.
13
+ */
14
+ export declare const deriveWordEmphasis: (lyric: runtime.Lyric, options?: DeriveWordEmphasisOptions) => runtime.Lyric;
15
+
16
+ export declare interface DeriveWordEmphasisOptions {
17
+ /**
18
+ * Word duration must strictly exceed this threshold, expressed as a non-negative safe integer in milliseconds.
19
+ *
20
+ * @default 3000
21
+ */
22
+ durationThreshold?: number;
23
+ }
24
+
4
25
  /**
5
26
  * Recognition reads only the original text; the annotation tracks never decide the format.
6
27
  *
7
28
  * Unrecognized text returns `undefined`.
8
29
  */
9
- export declare const detectFormat: (input: unknown) => "lrc" | "ttml" | undefined;
30
+ export declare const detectFormat: (input: unknown) => LyricFormat | undefined;
31
+
32
+ /**
33
+ * Pulls bracketed background vocals out of the sung lines and attaches them to the line they accompany.
34
+ *
35
+ * A line holding nothing but brackets becomes a background of the line before it and is removed.
36
+ * A bracket opened on one line and closed on a later one joins the line before the opening, and both source lines go.
37
+ * Text outside brackets stays on its line, and a line left with none keeps its place.
38
+ *
39
+ * @returns The input when unchanged, or a new lyric sharing all unchanged nodes.
40
+ */
41
+ export declare const extractBackgroundLines: (lyric: runtime.Lyric, options?: ExtractBackgroundLinesOptions) => runtime.Lyric;
42
+
43
+ export declare interface ExtractBackgroundLinesOptions {
44
+ /**
45
+ * Turn a line holding nothing but brackets into a background line of the line before it.
46
+ *
47
+ * @default true
48
+ */
49
+ fullLine?: boolean;
50
+ /**
51
+ * Pull the bracketed runs inside a line out into background lines of that same line.
52
+ *
53
+ * @default true
54
+ */
55
+ inLine?: boolean;
56
+ /**
57
+ * Join a bracket opened on one line and closed on a later one, attaching it to the line before them.
58
+ *
59
+ * @default true
60
+ */
61
+ crossLine?: boolean;
62
+ }
63
+
64
+ /**
65
+ * Inserts derived instrumental lines into uncovered gaps on the stored timeline, starting at zero.
66
+ * Existing lines and background vocals occupy their full ranges; an unknown end blocks later gaps.
67
+ *
68
+ * An outro requires an explicit endTime; metadata duration and offset do not affect insertion.
69
+ *
70
+ * @returns The input when unchanged, or a new lyric and lines array sharing existing nodes.
71
+ */
72
+ export declare const insertInstrumentalLines: (lyric: runtime.Lyric, options?: InsertInstrumentalLinesOptions) => runtime.Lyric;
73
+
74
+ export declare interface InsertInstrumentalLinesOptions {
75
+ /**
76
+ * Minimum gap duration in milliseconds, including an outro.
77
+ *
78
+ * @default 10000
79
+ */
80
+ minDuration?: number;
81
+ /**
82
+ * Minimum gap duration before the first vocal in milliseconds.
83
+ *
84
+ * @default 5000
85
+ */
86
+ minIntroDuration?: number;
87
+ /**
88
+ * Outro boundary in milliseconds, measured on the same timeline as line ranges.
89
+ * An omitted boundary leaves the outro unknown.
90
+ */
91
+ endTime?: number;
92
+ }
93
+
94
+ /**
95
+ * Inserts the spaces a source left out, so CJK text set against Latin letters, digits or punctuation reads evenly.
96
+ *
97
+ * A word-level line keeps every word's time and annotation: an inserted space becomes its own space word,
98
+ * and a word the rules split yields one word per character, all sharing the original range.
99
+ * A plain-text line and the annotation tracks are rewritten as whole strings.
100
+ *
101
+ * @returns The input when unchanged, or a new lyric sharing all unchanged nodes.
102
+ */
103
+ export declare const insertSpacesInLines: (lyric: runtime.Lyric, options?: InsertSpacesOptions) => runtime.Lyric;
104
+
105
+ export declare interface InsertSpacesOptions {
106
+ /**
107
+ * Rules to apply; omitting the list applies all of them.
108
+ */
109
+ rules?: InsertSpacesRule[];
110
+ /**
111
+ * Rewrite the translation and romanization tracks too.
112
+ *
113
+ * @default true
114
+ */
115
+ annotations?: boolean;
116
+ }
117
+
118
+ export declare type InsertSpacesRule = (typeof InsertSpacesRules)[keyof typeof InsertSpacesRules];
119
+
120
+ /**
121
+ * Groups of characters a source may write without a space where one belongs.
122
+ */
123
+ export declare const InsertSpacesRules: {
124
+ /**
125
+ * A CJK character touching a Latin letter, as in `ABC中文`.
126
+ */
127
+ readonly CJK_ENGLISH: "cjkEnglish";
128
+ /**
129
+ * A CJK character touching a digit, as in `2026年`.
130
+ */
131
+ readonly CJK_NUMBER: "cjkNumber";
132
+ /**
133
+ * A comma, semicolon, exclamation mark, question mark or colon touching a character, as in `a,b`; a clock time or thousands separator such as `10:30` stays as written.
134
+ */
135
+ readonly PUNCTUATION: "punctuation";
136
+ /**
137
+ * A quotation mark touching a neighbouring character.
138
+ */
139
+ readonly QUOTE: "quote";
140
+ /**
141
+ * A bracket touching the character outside it.
142
+ */
143
+ readonly BRACKET_OUTSIDE: "bracketOutside";
144
+ /**
145
+ * A plus, equals or ampersand touching a character, as in `a+b`; a compound operator such as `a+=b` stays as written.
146
+ */
147
+ readonly MATH_OPERATOR: "mathOperator";
148
+ /**
149
+ * A hyphen touching a CJK character, as in `中-文`; a compound word such as `well-known` stays as written.
150
+ */
151
+ readonly HYPHEN: "hyphen";
152
+ /**
153
+ * A slash touching a character, as in `and/or`; a fraction such as `1/2` stays as written.
154
+ */
155
+ readonly SLASH: "slash";
156
+ /**
157
+ * Runs of two or more spaces, collapsed to one.
158
+ */
159
+ readonly COMPRESS_SPACES: "compressSpaces";
160
+ /**
161
+ * Spaces just inside a bracket or quotation mark, removed.
162
+ */
163
+ readonly TRIM_INSIDE_SYMBOLS: "trimInsideSymbols";
164
+ };
10
165
 
11
166
  declare interface LrcContent {
12
167
  original: string;
@@ -36,7 +191,7 @@ export declare type LyricFormat = 'lrc' | 'ttml';
36
191
  export declare const parse: (input: unknown, options?: LrcParseOptions & TtmlParseOptions) => ParseResult | null;
37
192
 
38
193
  /**
39
- * Source order, empty timed lines, and missing word times are preserved for model validation.
194
+ * Empty timed rows become instrumental lines; source order and missing word times remain for model validation.
40
195
  *
41
196
  * Annotation tracks are read as lines too and attached by timestamp, and rows that match no line are dropped.
42
197
  *
@@ -58,11 +213,19 @@ export declare interface ParseResult {
58
213
  * The profile only changes where metadata comes from, so one reader serves both.
59
214
  * A document that parses but holds no timed paragraph is `INVALID` rather than an error.
60
215
  */
61
- export declare const parseTtml: (input: string | TtmlContent, options?: TtmlParseOptions) => ParseResult;
216
+ export declare const parseTtml: (input: TtmlParseInput, options?: TtmlParseOptions) => ParseResult;
62
217
 
63
- export declare interface TtmlContent {
64
- original: string;
65
- }
218
+ /**
219
+ * Removes the brackets some sources wrap around background vocals.
220
+ *
221
+ * One layer is removed from each edge of every background line, leaving a nested pair as `(x)`.
222
+ * A line left with no content is dropped, since a background line must carry something.
223
+ *
224
+ * @returns The input when unchanged, or a new lyric sharing all unchanged nodes.
225
+ */
226
+ export declare const stripBackgroundBrackets: (lyric: runtime.Lyric) => runtime.Lyric;
227
+
228
+ export declare type TtmlParseInput = string;
66
229
 
67
230
  export declare interface TtmlParseOptions {
68
231
  /** Language tag the lyric declares; the document's own `xml:lang` wins when it states one. */
package/dist/parser.js CHANGED
@@ -1 +1,3 @@
1
- export { detectFormat, parse, parseLrc, parseTtml } from "./formats.js";
1
+ import { detectFormat, parse, parseLrc, parseTtml } from "./formats.js";
2
+ import { InsertSpacesRules, deriveWordEmphasis, extractBackgroundLines, insertInstrumentalLines, insertSpacesInLines, stripBackgroundBrackets } from "./transforms.js";
3
+ export { InsertSpacesRules, deriveWordEmphasis, detectFormat, extractBackgroundLines, insertInstrumentalLines, insertSpacesInLines, parse, parseLrc, parseTtml, stripBackgroundBrackets };