lyrics-structure 1.2.3 → 1.2.4

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.
package/dist/slide.js CHANGED
@@ -39,9 +39,7 @@ const processContent = (content) => {
39
39
  const getSlideParts = (text) => {
40
40
  if (!text)
41
41
  return [];
42
- // Remove text between parentheses
43
- const textWithoutParentheses = text.replace(/\([^)]*\)/g, '');
44
- const partsText = (0, lyrics_1.getLyricsParts)(textWithoutParentheses).map((part) => part.content);
42
+ const partsText = (0, lyrics_1.getLyricsParts)(text).map((part) => part.content);
45
43
  const result = [];
46
44
  partsText.forEach((part) => {
47
45
  if (part) {
@@ -50,7 +50,7 @@ Regular line
50
50
  'Fifth line of verse',
51
51
  'First line of verse\nSecond line of verse\nThird line of verse\nFourth line of verse',
52
52
  'Fifth line of verse',
53
- 'Regular text line 1\nRegular text line 2',
53
+ '(inside parentheses)\nRegular text line 1\nRegular text line 2',
54
54
  'First chorus line\nSecond chorus line',
55
55
  'This is a very long line that should be considered too long for the slide\nThis is another very long line that should also be considered too long',
56
56
  'Short line 1\nShort line 2',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lyrics-structure",
3
- "version": "1.2.3",
3
+ "version": "1.2.4",
4
4
  "description": "Parser for lyrics with structured sections, names, and indications",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
package/slide.test.ts CHANGED
@@ -50,7 +50,7 @@ Regular line
50
50
  'Fifth line of verse',
51
51
  'First line of verse\nSecond line of verse\nThird line of verse\nFourth line of verse',
52
52
  'Fifth line of verse',
53
- 'Regular text line 1\nRegular text line 2',
53
+ '(inside parentheses)\nRegular text line 1\nRegular text line 2',
54
54
  'First chorus line\nSecond chorus line',
55
55
  'This is a very long line that should be considered too long for the slide\nThis is another very long line that should also be considered too long',
56
56
  'Short line 1\nShort line 2',
package/slide.ts CHANGED
@@ -47,9 +47,7 @@ const processContent = (content: string): string[] => {
47
47
  export const getSlideParts = (text?: string): string[] => {
48
48
  if (!text) return [];
49
49
 
50
- // Remove text between parentheses
51
- const textWithoutParentheses = text.replace(/\([^)]*\)/g, '');
52
- const partsText = getLyricsParts(textWithoutParentheses).map((part) => part.content);
50
+ const partsText = getLyricsParts(text).map((part) => part.content);
53
51
 
54
52
  const result: string[] = [];
55
53