zohlathu 1.0.3 → 1.0.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.
Files changed (3) hide show
  1. package/index.js +4 -1
  2. package/package.json +1 -1
  3. package/test.js +0 -28
package/index.js CHANGED
@@ -72,7 +72,10 @@ async function get_lyrics(query) {
72
72
  selectors: [
73
73
  {
74
74
  selector: 'p',
75
- options: { leadingLineBreaks: 1, trailingLineBreaks: 2 }
75
+ options: {
76
+ leadingLineBreaks: 0,
77
+ trailingLineBreaks: 2
78
+ }
76
79
  },
77
80
  { selector: 'br', format: 'lineBreak' },
78
81
  { selector: 'a', options: { ignoreHref: true } },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "zohlathu",
3
- "version": "1.0.3",
3
+ "version": "1.0.4",
4
4
  "description": "A Node.js package for fetching Mizo song lyrics from www.zohlathu.in",
5
5
  "main": "index.js",
6
6
  "scripts": {
package/test.js DELETED
@@ -1,28 +0,0 @@
1
- const { get_lyrics } = require('./index.js');
2
-
3
- async function runTest() {
4
- console.log("Hla thu kan zawng mek e, lo nghak lawk rawh...");
5
-
6
- // I hla zawn duh chu hetah hian i thlak thei ang
7
- const songToSearch = "Tawngmang lasi";
8
-
9
- try {
10
- const result = await get_lyrics(songToSearch);
11
-
12
- if (result) {
13
- console.log("\n✅ HLA HMUH A NI!");
14
- console.log("----------------------------------");
15
- console.log("Hla Hming :", result.title);
16
- console.log("Link :", result.source_url);
17
- console.log("----------------------------------");
18
- console.log(result.lyrics);
19
- console.log("----------------------------------");
20
- } else {
21
- console.log("\n❌ Pawi lutuk, he hla hi hmuh a ni lo.");
22
- }
23
- } catch (error) {
24
- console.error("Harsatna a awm:", error);
25
- }
26
- }
27
-
28
- runTest();