fix(пробный доступ): окно зовёт пополнить счёт кнопкой, а не писать на почту; кнопки зелёные
С открытием приёма всем у пробного клиента рядом стоит кнопка «Пополнить счёт», а текст над ней ещё звал писать на info@infosmeta.ru (Хозяин, 21.11.2026). Теперь при открытом приёме текст зовёт пополнить счёт; без приёма прежняя почта остаётся. Кнопки пополнения в чате и на странице статистики перекрашены в зелёный (--money): деньги заметнее спокойного красного. Проверки — живая страница в браузере и цвет по вычисленному стилю; мутации возвращают старый текст и красный цвет — обе краснеют. Co-Authored-By: Claude Code <noreply@anthropic.com>
This commit is contained in:
@@ -1,4 +1,12 @@
|
||||
[
|
||||
{
|
||||
"version": "2026-11-21f",
|
||||
"date": "2026-11-21",
|
||||
"changes": [
|
||||
"Пробный доступ: окно зовёт пополнить счёт кнопкой, а не писать на почту",
|
||||
"Кнопки пополнения стали зелёными — заметнее на странице"
|
||||
]
|
||||
},
|
||||
{
|
||||
"version": "2026-11-21e",
|
||||
"date": "2026-11-21",
|
||||
@@ -27,12 +35,5 @@
|
||||
"changes": [
|
||||
"Карточка клиента: источник пополнения назван по-русски («онлайн-оплата»), а у владельца вместо непонятного «Счёт не заведён» — «счёт не ведётся»"
|
||||
]
|
||||
},
|
||||
{
|
||||
"version": "2026-11-21a",
|
||||
"date": "2026-11-21",
|
||||
"changes": [
|
||||
"Страница возврата после оплаты показывает «Зачислено» даже с чужого устройства: теперь она проверяет платёж по подписанной ссылке, а не по входу на сайт"
|
||||
]
|
||||
}
|
||||
]
|
||||
|
||||
+11
-3
@@ -28,6 +28,7 @@ try { if (localStorage.getItem('token') && localStorage.getItem('ui_mode') === '
|
||||
--error-bg: #fff1f2; --error-border: #fecdd3;
|
||||
--system-bg: #efe9e1; --system-text: #847a6d;
|
||||
--ok: #1f6f43; --ok-hover: #18603a;
|
||||
--money: #2d8a56; --money-hover: #247848; /* кнопки пополнения — заметный зелёный */
|
||||
--shadow-sm: 0 1px 2px rgba(43,41,38,.05);
|
||||
--shadow-md: 0 6px 24px rgba(43,41,38,.09);
|
||||
--focus-ring: 0 0 0 3px rgba(192,69,58,.28);
|
||||
@@ -237,6 +238,9 @@ button { font-family: inherit; }
|
||||
#date-badge { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
|
||||
#balance-badge.warn-75 { border-color: #f0a500; color: #b47500; }
|
||||
#balance-badge.warn-90 { border-color: #e03131; color: #c92a2a; }
|
||||
/* Пополнение — зелёное: деньги и «пополнить» заметнее спокойного красного (Хозяин 21.11.2026). */
|
||||
#topup-open-btn:hover, #topup-go:hover { background: var(--money-hover); }
|
||||
#topup-open-btn:disabled, #topup-go:disabled { opacity: .6; cursor: default; background: var(--money); }
|
||||
.copy-btn { display: block; margin-top: .5rem; margin-left: auto; background: transparent; border: 1px solid var(--border); border-radius: 6px; cursor: pointer; font-size: .7rem; padding: .2rem .6rem; color: var(--text-light); width: fit-content; transition: all .15s; }
|
||||
.copy-btn:hover { background: var(--bg); color: var(--text-muted); border-color: var(--text-light); }
|
||||
.msg-user .copy-btn { border-color: rgba(255,255,255,.25); color: rgba(255,255,255,.6); }
|
||||
@@ -464,6 +468,7 @@ html { color-scheme: light; }
|
||||
--error-bg: #3a1f1d; --error-border: #5e2b27;
|
||||
--system-bg: #211d17; --system-text: #a89c8a;
|
||||
--ok: #3fa066; --ok-hover: #4cb074;
|
||||
--money: #3fa066; --money-hover: #4cb074;
|
||||
--shadow-sm: 0 1px 2px rgba(0,0,0,.4);
|
||||
--shadow-md: 0 10px 30px rgba(0,0,0,.55);
|
||||
--focus-ring: 0 0 0 3px rgba(217,105,92,.42);
|
||||
@@ -750,7 +755,7 @@ html { color-scheme: light; }
|
||||
<div id="balance-unknown" style="display:none;font-size:.74rem;color:var(--accent);margin:6px 0;line-height:1.45">Часть ответов ещё не оценена — остаток может уточниться.</div>
|
||||
<div style="font-size:.74rem;margin:6px 0;line-height:1.45"><a href="/static/pricing.html" target="_blank" rel="noopener" style="color:var(--accent)">Стоимость услуг и как считается цена</a></div>
|
||||
<div style="display:flex;justify-content:flex-end;gap:8px;flex-wrap:wrap;margin-top:10px">
|
||||
<button type="button" id="topup-open-btn" onclick="closeBalancePopover(); openTopupModal()" style="display:none;padding:5px 14px;font-size:.8rem;background:var(--accent);color:#fff;border:none;border-radius:7px;cursor:pointer;font-weight:600">Пополнить счёт</button>
|
||||
<button type="button" id="topup-open-btn" onclick="closeBalancePopover(); openTopupModal()" style="display:none;padding:5px 14px;font-size:.8rem;background:var(--money);color:#fff;border:none;border-radius:7px;cursor:pointer;font-weight:600">Пополнить счёт</button>
|
||||
<button type="button" onclick="closeBalancePopover()" style="padding:5px 12px;font-size:.8rem;background:transparent;border:1px solid var(--border);border-radius:7px;color:var(--text-muted);cursor:pointer">Закрыть</button>
|
||||
</div>
|
||||
</div>
|
||||
@@ -768,7 +773,7 @@ html { color-scheme: light; }
|
||||
<div id="topup-error" role="alert" style="display:none;font-size:.78rem;color:var(--accent);margin-top:8px;line-height:1.4"></div>
|
||||
<div style="display:flex;justify-content:flex-end;gap:8px;flex-wrap:wrap;margin-top:12px">
|
||||
<button type="button" onclick="closeTopupModal()" style="padding:6px 12px;font-size:.82rem;background:transparent;border:1px solid var(--border);border-radius:7px;color:var(--text-muted);cursor:pointer">Отмена</button>
|
||||
<button type="button" id="topup-go" onclick="goTopup()" style="padding:6px 14px;font-size:.82rem;background:var(--accent);color:#fff;border:none;border-radius:7px;cursor:pointer;font-weight:600">Перейти к оплате</button>
|
||||
<button type="button" id="topup-go" onclick="goTopup()" style="padding:6px 14px;font-size:.82rem;background:var(--money);color:#fff;border:none;border-radius:7px;cursor:pointer;font-weight:600">Перейти к оплате</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -2402,9 +2407,12 @@ function openBalancePopover() {
|
||||
document.getElementById('balance-title').textContent =
|
||||
b.read_only ? 'Баланс' : (b.trial ? 'Пробный доступ' : (b.account ? 'Счёт' : 'Остаток на сутки'));
|
||||
if (b.trial && !b.read_only) {
|
||||
// При открытом приёме снимают ограничения пополнением, а не письмом: текст обязан
|
||||
// совпадать с кнопкой, которая стоит рядом (Хозяин, 21.11.2026).
|
||||
document.getElementById('balance-window').textContent = 'В пробном доступе один диалог и ' +
|
||||
b.trial.limit + ' вопросов. Задано: ' + Math.min(b.trial.used, b.trial.limit) + ' из ' +
|
||||
b.trial.limit + '. Чтобы снять ограничения, напишите на info@infosmeta.ru.';
|
||||
b.trial.limit + '. Чтобы снять ограничения, ' +
|
||||
(b.topup ? 'пополните счёт.' : 'напишите на info@infosmeta.ru.');
|
||||
document.getElementById('balance-price').textContent = '';
|
||||
document.getElementById('balance-unknown').style.display = 'none';
|
||||
}
|
||||
|
||||
+1
-1
@@ -55,7 +55,7 @@ td.bar-cell { width: 38%; }
|
||||
.bar { height: 10px; border-radius: 5px; background: var(--bar); min-width: 2px; }
|
||||
.bar.zero { background: var(--border); }
|
||||
.bad { color: var(--accent); font-weight: 600; }
|
||||
.topup-link { display: inline-block; margin: .5rem 0; padding: .45rem .9rem; background: var(--accent, #c4463a); color: #fff; border-radius: 8px; text-decoration: none; font-weight: 600; font-size: .9rem; }
|
||||
.topup-link { display: inline-block; margin: .5rem 0; padding: .45rem .9rem; background: var(--money, #2d8a56); color: #fff; border-radius: 8px; text-decoration: none; font-weight: 600; font-size: .9rem; }
|
||||
.deposits { list-style: none; margin-top: .4rem; font-variant-numeric: tabular-nums; }
|
||||
.deposits li { padding: .2rem 0; border-bottom: 1px solid var(--border-light); font-size: .9rem; }
|
||||
.state { padding: 1.5rem 0; text-align: center; color: var(--text-muted); }
|
||||
|
||||
Reference in New Issue
Block a user