telegram-badge 1.3.1 → 1.4.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.ar.md +3 -1
- package/README.ja.md +3 -1
- package/README.ko.md +3 -1
- package/README.md +8 -1
- package/README.ru.md +3 -1
- package/README.th.md +3 -1
- package/README.zh.md +3 -1
- package/dist/api/badge-generator.js +3 -3
- package/package.json +1 -1
package/README.ar.md
CHANGED
|
@@ -1,9 +1,11 @@
|
|
|
1
|
-
#
|
|
1
|
+
# مولد شارات مجموعات تيليجرام
|
|
2
2
|
|
|
3
3
|
[🇷🇺 Русский](README.ru.md) | [🇺🇸 English](README.md) | [🇨🇳 中文](README.zh.md) | [🇹🇭 ไทย](README.th.md) | [🇸🇦 العربية](README.ar.md) | [🇯🇵 日本語](README.ja.md) | [🇰🇷 한국어](README.ko.md)
|
|
4
4
|
|
|
5
5
|
[](https://github.com/chatman-media/telegram-badge/actions)
|
|
6
|
+
[](https://github.com/chatman-media/telegram-badge/actions)
|
|
6
7
|
[](https://www.npmjs.com/package/telegram-badge)
|
|
8
|
+
[](https://jsr.io/@chatman-media/telegram-badge)
|
|
7
9
|
[](https://bundlephobia.com/package/telegram-badge)
|
|
8
10
|
[](https://www.typescriptlang.org/)
|
|
9
11
|
[](https://opensource.org/licenses/MIT)
|
package/README.ja.md
CHANGED
|
@@ -1,9 +1,11 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Telegramグループバッジジェネレーター
|
|
2
2
|
|
|
3
3
|
[🇷🇺 Русский](README.ru.md) | [🇺🇸 English](README.md) | [🇨🇳 中文](README.zh.md) | [🇹🇭 ไทย](README.th.md) | [🇸🇦 العربية](README.ar.md) | [🇯🇵 日本語](README.ja.md) | [🇰🇷 한국어](README.ko.md)
|
|
4
4
|
|
|
5
5
|
[](https://github.com/chatman-media/telegram-badge/actions)
|
|
6
|
+
[](https://github.com/chatman-media/telegram-badge/actions)
|
|
6
7
|
[](https://www.npmjs.com/package/telegram-badge)
|
|
8
|
+
[](https://jsr.io/@chatman-media/telegram-badge)
|
|
7
9
|
[](https://bundlephobia.com/package/telegram-badge)
|
|
8
10
|
[](https://www.typescriptlang.org/)
|
|
9
11
|
[](https://opensource.org/licenses/MIT)
|
package/README.ko.md
CHANGED
|
@@ -1,9 +1,11 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Telegram 그룹 배지 생성기
|
|
2
2
|
|
|
3
3
|
[🇷🇺 Русский](README.ru.md) | [🇺🇸 English](README.md) | [🇨🇳 中文](README.zh.md) | [🇹🇭 ไทย](README.th.md) | [🇸🇦 العربية](README.ar.md) | [🇯🇵 日本語](README.ja.md) | [🇰🇷 한국어](README.ko.md)
|
|
4
4
|
|
|
5
5
|
[](https://github.com/chatman-media/telegram-badge/actions)
|
|
6
|
+
[](https://github.com/chatman-media/telegram-badge/actions)
|
|
6
7
|
[](https://www.npmjs.com/package/telegram-badge)
|
|
8
|
+
[](https://jsr.io/@chatman-media/telegram-badge)
|
|
7
9
|
[](https://bundlephobia.com/package/telegram-badge)
|
|
8
10
|
[](https://www.typescriptlang.org/)
|
|
9
11
|
[](https://opensource.org/licenses/MIT)
|
package/README.md
CHANGED
|
@@ -1,9 +1,11 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Telegram Group Badge Generator
|
|
2
2
|
|
|
3
3
|
[🇷🇺 Русский](README.ru.md) | [🇺🇸 English](README.md) | [🇨🇳 中文](README.zh.md) | [🇹🇭 ไทย](README.th.md) | [🇸🇦 العربية](README.ar.md) | [🇯🇵 日本語](README.ja.md) | [🇰🇷 한국어](README.ko.md)
|
|
4
4
|
|
|
5
5
|
[](https://github.com/chatman-media/telegram-badge/actions)
|
|
6
|
+
[](https://github.com/chatman-media/telegram-badge/actions)
|
|
6
7
|
[](https://www.npmjs.com/package/telegram-badge)
|
|
8
|
+
[](https://jsr.io/@chatman-media/telegram-badge)
|
|
7
9
|
[](https://bundlephobia.com/package/telegram-badge)
|
|
8
10
|
[](https://www.typescriptlang.org/)
|
|
9
11
|
[](https://opensource.org/licenses/MIT)
|
|
@@ -222,6 +224,11 @@ npm run build
|
|
|
222
224
|
|
|
223
225
|
## Subscribe
|
|
224
226
|
|
|
227
|
+
### 🌐 Follow on Social Media
|
|
228
|
+
|
|
229
|
+
[](https://stackoverflow.com/users/724036/alexander-kireyev)
|
|
230
|
+
|
|
231
|
+
[](https://github.com/chatman-media)
|
|
225
232
|
[](https://www.tiktok.com/@chatman.media)
|
|
226
233
|
[](https://www.twitch.tv/chatman1984)
|
|
227
234
|
[](https://www.youtube.com/@chatman-media)
|
package/README.ru.md
CHANGED
|
@@ -1,9 +1,11 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Telegram Group Badge Generator
|
|
2
2
|
|
|
3
3
|
[🇷🇺 Русский](README.ru.md) | [🇺🇸 English](README.md) | [🇨🇳 中文](README.zh.md) | [🇹🇭 ไทย](README.th.md) | [🇸🇦 العربية](README.ar.md) | [🇯🇵 日本語](README.ja.md) | [🇰🇷 한국어](README.ko.md)
|
|
4
4
|
|
|
5
5
|
[](https://github.com/chatman-media/telegram-badge/actions)
|
|
6
|
+
[](https://github.com/chatman-media/telegram-badge/actions)
|
|
6
7
|
[](https://www.npmjs.com/package/telegram-badge)
|
|
8
|
+
[](https://jsr.io/@chatman-media/telegram-badge)
|
|
7
9
|
[](https://bundlephobia.com/package/telegram-badge)
|
|
8
10
|
[](https://www.typescriptlang.org/)
|
|
9
11
|
[](https://opensource.org/licenses/MIT)
|
package/README.th.md
CHANGED
|
@@ -1,9 +1,11 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Telegram Group Badge Generator
|
|
2
2
|
|
|
3
3
|
[🇷🇺 Русский](README.ru.md) | [🇺🇸 English](README.md) | [🇨🇳 中文](README.zh.md) | [🇹🇭 ไทย](README.th.md) | [🇸🇦 العربية](README.ar.md) | [🇯🇵 日本語](README.ja.md) | [🇰🇷 한국어](README.ko.md)
|
|
4
4
|
|
|
5
5
|
[](https://github.com/chatman-media/telegram-badge/actions)
|
|
6
|
+
[](https://github.com/chatman-media/telegram-badge/actions)
|
|
6
7
|
[](https://www.npmjs.com/package/telegram-badge)
|
|
8
|
+
[](https://jsr.io/@chatman-media/telegram-badge)
|
|
7
9
|
[](https://bundlephobia.com/package/telegram-badge)
|
|
8
10
|
[](https://www.typescriptlang.org/)
|
|
9
11
|
[](https://opensource.org/licenses/MIT)
|
package/README.zh.md
CHANGED
|
@@ -1,9 +1,11 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Telegram 群组徽章生成器
|
|
2
2
|
|
|
3
3
|
[🇷🇺 Русский](README.ru.md) | [🇺🇸 English](README.md) | [🇨🇳 中文](README.zh.md) | [🇹🇭 ไทย](README.th.md) | [🇸🇦 العربية](README.ar.md) | [🇯🇵 日本語](README.ja.md) | [🇰🇷 한국어](README.ko.md)
|
|
4
4
|
|
|
5
5
|
[](https://github.com/chatman-media/telegram-badge/actions)
|
|
6
|
+
[](https://github.com/chatman-media/telegram-badge/actions)
|
|
6
7
|
[](https://www.npmjs.com/package/telegram-badge)
|
|
8
|
+
[](https://jsr.io/@chatman-media/telegram-badge)
|
|
7
9
|
[](https://bundlephobia.com/package/telegram-badge)
|
|
8
10
|
[](https://www.typescriptlang.org/)
|
|
9
11
|
[](https://opensource.org/licenses/MIT)
|
|
@@ -14,10 +14,10 @@ function generateBadgeSVG(format) {
|
|
|
14
14
|
const messageWidth = message.length * 7 + 20;
|
|
15
15
|
const totalWidth = labelWidth + messageWidth;
|
|
16
16
|
// Create logo element
|
|
17
|
-
const logoElement = logo ? `<image x="5" y="3" width="14" height="14" href="data:image/svg+xml;base64,${
|
|
17
|
+
const logoElement = logo ? `<image x="5" y="3" width="14" height="14" href="data:image/svg+xml;base64,${btoa(TELEGRAM_LOGO)}"/>` : '';
|
|
18
18
|
// For-the-badge style
|
|
19
19
|
if (style === 'for-the-badge') {
|
|
20
|
-
const logoForBadge = logo ? `<image x="5" y="7" width="14" height="14" href="data:image/svg+xml;base64,${
|
|
20
|
+
const logoForBadge = logo ? `<image x="5" y="7" width="14" height="14" href="data:image/svg+xml;base64,${btoa(TELEGRAM_LOGO)}"/>` : '';
|
|
21
21
|
return `<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="${totalWidth}" height="28" role="img" aria-label="${label}: ${message}">
|
|
22
22
|
<title>${label}: ${message}</title>
|
|
23
23
|
<g shape-rendering="crispEdges">
|
|
@@ -48,7 +48,7 @@ function generateBadgeSVG(format) {
|
|
|
48
48
|
}
|
|
49
49
|
// Social style
|
|
50
50
|
if (style === 'social') {
|
|
51
|
-
const socialLogoElement = logo ? `<image x="7" y="3" width="14" height="14" href="data:image/svg+xml;base64,${
|
|
51
|
+
const socialLogoElement = logo ? `<image x="7" y="3" width="14" height="14" href="data:image/svg+xml;base64,${btoa(TELEGRAM_LOGO)}"/>` : '';
|
|
52
52
|
return `<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="${totalWidth + 4}" height="20" style="border-radius: 3px" role="img" aria-label="${label}: ${message}">
|
|
53
53
|
<title>${label}: ${message}</title>
|
|
54
54
|
<linearGradient id="s" x2="0" y2="100%">
|