telegram-badge 1.2.0 → 1.2.1
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/README.md +0 -1
- package/README.ru.md +0 -1
- package/README.zh.md +0 -1
- package/dist/api/badge-generator.js +2 -2
- package/package.json +2 -2
- package/types/index.ts +1 -1
package/README.md
CHANGED
|
@@ -4,7 +4,6 @@
|
|
|
4
4
|
|
|
5
5
|
[](https://github.com/chatman-media/telegram-badge/actions)
|
|
6
6
|
[](https://badge.fury.io/js/telegram-badge)
|
|
7
|
-
[](https://www.npmjs.com/package/telegram-badge)
|
|
8
7
|
[](https://bundlephobia.com/package/telegram-badge)
|
|
9
8
|
[](https://www.typescriptlang.org/)
|
|
10
9
|
[](https://opensource.org/licenses/MIT)
|
package/README.ru.md
CHANGED
|
@@ -4,7 +4,6 @@
|
|
|
4
4
|
|
|
5
5
|
[](https://github.com/chatman-media/telegram-badge/actions)
|
|
6
6
|
[](https://badge.fury.io/js/telegram-badge)
|
|
7
|
-
[](https://www.npmjs.com/package/telegram-badge)
|
|
8
7
|
[](https://bundlephobia.com/package/telegram-badge)
|
|
9
8
|
[](https://www.typescriptlang.org/)
|
|
10
9
|
[](https://opensource.org/licenses/MIT)
|
package/README.zh.md
CHANGED
|
@@ -4,7 +4,6 @@
|
|
|
4
4
|
|
|
5
5
|
[](https://github.com/chatman-media/telegram-badge/actions)
|
|
6
6
|
[](https://badge.fury.io/js/telegram-badge)
|
|
7
|
-
[](https://www.npmjs.com/package/telegram-badge)
|
|
8
7
|
[](https://bundlephobia.com/package/telegram-badge)
|
|
9
8
|
[](https://www.typescriptlang.org/)
|
|
10
9
|
[](https://opensource.org/licenses/MIT)
|
|
@@ -10,8 +10,8 @@ function generateBadgeSVG(format) {
|
|
|
10
10
|
const logoSpace = logo ? 25 : 0;
|
|
11
11
|
// Better text width calculation
|
|
12
12
|
// Always add logoSpace to width calculation
|
|
13
|
-
const labelWidth = label.length *
|
|
14
|
-
const messageWidth = message.length *
|
|
13
|
+
const labelWidth = label.length * 7 + 10 + logoSpace;
|
|
14
|
+
const messageWidth = message.length * 7 + 10;
|
|
15
15
|
const totalWidth = labelWidth + messageWidth;
|
|
16
16
|
// Create logo element
|
|
17
17
|
const logoElement = logo ? `<image x="5" y="3" width="14" height="14" href="data:image/svg+xml;base64,${Buffer.from(TELEGRAM_LOGO).toString('base64')}"/>` : '';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "telegram-badge",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.1",
|
|
4
4
|
"description": "Generate Telegram group member count badges for GitHub README",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"telegram",
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
"LICENSE"
|
|
31
31
|
],
|
|
32
32
|
"scripts": {
|
|
33
|
-
"dev": "
|
|
33
|
+
"dev": "vercel dev",
|
|
34
34
|
"start": "node -p \"console.log('Use: npx vercel dev')\"",
|
|
35
35
|
"test": "jest",
|
|
36
36
|
"build": "echo 'Build handled by Vercel'",
|
package/types/index.ts
CHANGED