feat: improve tariff builder UI

- Move promo groups from Servers tab to Extra tab
- Add isActive toggle in Extra tab (tariff status)
- Remove trial toggle from form (not needed for now)
- Replace "T" letter with gift icon for trial toggle in tariff list
- Add i18n translations for new status fields
This commit is contained in:
c0mrade
2026-02-02 04:46:00 +03:00
parent d6edb659a3
commit e19767af82
6 changed files with 105 additions and 45 deletions

View File

@@ -44,6 +44,16 @@ const XIcon = () => (
</svg>
);
const GiftIcon = () => (
<svg className="h-4 w-4" fill="none" viewBox="0 0 24 24" stroke="currentColor" strokeWidth={2}>
<path
strokeLinecap="round"
strokeLinejoin="round"
d="M21 11.25v8.25a1.5 1.5 0 01-1.5 1.5H5.25a1.5 1.5 0 01-1.5-1.5v-8.25M12 4.875A2.625 2.625 0 109.375 7.5H12m0-2.625V7.5m0-2.625A2.625 2.625 0 1114.625 7.5H12m0 0V21m-8.625-9.75h18c.621 0 1.125-.504 1.125-1.125v-1.5c0-.621-.504-1.125-1.125-1.125h-18c-.621 0-1.125.504-1.125 1.125v1.5c0 .621.504 1.125 1.125 1.125z"
/>
</svg>
);
export default function AdminTariffs() {
const { t } = useTranslation();
const navigate = useNavigate();
@@ -210,7 +220,7 @@ export default function AdminTariffs() {
}`}
title={t('admin.tariffs.toggleTrial')}
>
T
<GiftIcon />
</button>
{/* Edit */}