Обновить учёт поддержки, лайки и профиль перед MVP

This commit is contained in:
AidarKC
2026-12-02 00:01:51 +03:00
parent d05d9db8a2
commit af0beccb4a
21 changed files with 109 additions and 57 deletions
@@ -1,4 +1,5 @@
import { authService } from '../state.js';
import { formatStars } from './shine-support-amount.js';
// Один запрос на канал; только сервер проверяет привязку транзакции к блоку.
const cache = new Map();
@@ -26,9 +27,6 @@ export function loadVerifiedSupportTotals(selector) {
export function formatVerifiedSupportStars(value) {
try {
const n = BigInt(value);
if (n <= 0n) return null;
const whole = n / 100n;
const fraction = String(n % 100n).padStart(2, '0');
return `${whole}.${fraction} ⭐`;
return formatStars(n);
} catch { return null; }
}