customizable-toast-notification 3.9.7 โ†’ 3.10.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.
package/postinstall.js CHANGED
@@ -6,28 +6,12 @@ try {
6
6
  ) {
7
7
  process.exit(0);
8
8
  } else {
9
- showMessage(5);
9
+ showMessage();
10
10
  }
11
11
 
12
- function showMessage(count) {
13
- const width = process.stdout.columns || 80;
14
- const boxWidth = 60;
15
-
16
- const spinnerFrames = ["|", "/", "-", "\\"];
17
- let i = 0;
18
-
19
- const stripAnsi = (text) => text.replace(/\x1b\[[0-9;]*m/g, "");
20
- const pad = (text) =>
21
- " ".repeat(Math.max(boxWidth - stripAnsi(text).length, 0));
22
- const center = (text) =>
23
- " ".repeat(
24
- Math.max(Math.floor((width - stripAnsi(text).length) / 2), 0)
25
- ) + text;
26
-
12
+ function showMessage() {
27
13
  const lines = [
28
- count === 5
29
- ? "๐ŸŽฏThanks for sticking with it!\nThis is the final message. ๐Ÿš€"
30
- : `๐Ÿ“ฆThanks for using this package!`,
14
+ "๐ŸŽฏThanks for sticking with it! This is the final message. ๐Ÿš€...๐Ÿ“ฆThanks for using this package!",
31
15
  "๐Ÿ“˜ In README.md - More professional",
32
16
  "๐Ÿ‘จโ€๐Ÿ’ป Author **Priyanshu Patel** -",
33
17
  "๐Ÿค Open to collaboration & teamwork",
@@ -36,30 +20,7 @@ try {
36
20
  "๐Ÿš€ Built different. Stay creative.",
37
21
  ];
38
22
 
39
- const spinner = setInterval(() => {
40
- process.stdout.write(
41
- `\rโณ Finalizing install ${spinnerFrames[i++ % spinnerFrames.length]} `
42
- );
43
- }, 100);
44
-
45
- setTimeout(() => {
46
- clearInterval(spinner);
47
- process.stdout.write("\r".padEnd(40, " ") + "\r"); // Clear spinner line
48
-
49
- console.log(
50
- "\n" + center(`\x1b[36m\x1b[1mโ•”${"โ•".repeat(boxWidth)}โ•—\x1b[0m`)
51
- );
52
- lines.forEach((line) => {
53
- line.split("\n").forEach((sub) => {
54
- console.log(
55
- center(`\x1b[36mโ•‘ \x1b[0m${sub}${pad(sub)}\x1b[36m โ•‘\x1b[0m`)
56
- );
57
- });
58
- });
59
- console.log(center(`\x1b[36mโ•š${"โ•".repeat(boxWidth)}โ•\x1b[0m`) + "\n");
60
-
61
- process.exit(0); // โœ… Exit only after message shown
62
- }, 300);
23
+ console.log(lines);
63
24
  }
64
25
  } catch (error) {
65
26
  process.exit(0); // Exit silently