Commit Graph

1097 Commits

Author SHA1 Message Date
Fringg
76d20fdb1a feat: admin partner settings page, partner section visibility toggle, custom requisites text
- New AdminPartnerSettings page with validation (pattern from AdminTicketSettings)
- Settings gear button on AdminPartners header
- Hide partner/withdrawal sections when partner_section_visible is false
- Use custom requisites_text as label in withdrawal form
- i18n keys for ru/en
2026-02-18 04:12:19 +03:00
Fringg
9cf8e095b8 feat: show blocked_count in broadcast admin UI
- Add blocked_count to Broadcast interface
- 4-column stats grid with blocked card (warning color)
- Show blocked count in broadcast list when > 0
- Fetch single broadcast by ID instead of listing all
- Add i18n keys for blocked/blockedShort in ru/en/zh/fa
2026-02-17 18:37:45 +03:00
Fringg
74c4c87ec0 refactor: extract shared withdrawal utils and fix status badge fallbacks
- extract formatDate, statusBadgeConfig, getRiskColor to shared utils
- use explicit unknown fallback for unrecognized status values
- add missing 'unknown' i18n keys for withdrawal status
2026-02-17 12:42:42 +03:00
Fringg
9b2742ff3a fix: add missing cancelled filter key to withdrawal i18n in all locales 2026-02-17 12:28:32 +03:00
Fringg
be168a75df fix: reduce campaigns fetch limit to 100 (backend max)
Backend validates limit with le=100, sending 200 caused 422 error.
2026-02-17 11:02:38 +03:00
Fringg
a72042d807 fix: show all campaigns in assign list, add dual links and bonus details
1. Remove is_active filter from campaign assign page so inactive
   campaigns are also visible (with badge)
2. Redesign partner campaign cards with separate bot/cabinet links,
   detailed bonus descriptions, and per-link copy buttons
2026-02-17 10:54:36 +03:00
Fringg
8b33d8224d feat: show partner campaign links with bonuses on referral page
Display campaigns assigned to the partner with shareable deep links,
copy button, and bonus type badges (balance/subscription/tariff).
2026-02-17 10:45:13 +03:00
Fringg
2efce0eb03 fix: stop WS reconnect loop on auth rejection (code 1008)
When the server closes WebSocket with 1008 (invalid token), the client
no longer retries — eliminates log spam from stale sessions.
2026-02-17 10:36:38 +03:00
Fringg
062976180c refactor: convert partner/withdrawal modals to separate pages
Replace 7 modal dialogs with 8 dedicated page routes for better
mobile/Telegram WebApp UX. Add campaign management (assign/create
with auto-assign) to partner detail page.

New pages: AdminApplicationReview, AdminPartnerCommission,
AdminPartnerRevoke, AdminWithdrawalReject, AdminPartnerCampaignAssign,
AdminPartnerCampaignCreate, ReferralPartnerApply,
ReferralWithdrawalRequest.

~610 lines removed from parent pages, ~425 lines removed net.
2026-02-17 10:28:32 +03:00
Fringg
779fbf0dc6 feat: add partner management and withdrawal admin pages
- Admin partners page: list partners, view applications, approve/reject
- Admin partner detail: stats, commission management, campaign assignment
- Admin withdrawals page: list with risk scoring, status filters including cancelled
- Admin withdrawal detail: fraud analysis, approve/reject/complete actions
- Partner API client with full TypeScript interfaces
- Withdrawal API client with admin and user endpoints
- Referral page: partner application form, withdrawal balance and history
- Navigation: partners and withdrawals in admin panel marketing group
- i18n: full translations for ru, en, zh, fa locales
- Neutral fallbacks for unknown status badges
2026-02-17 09:51:48 +03:00
Egor
1c1d72f7f0 Merge pull request #226 from BEDOLAGA-DEV/release-please--branches--main--components--cabinet-frontend
chore(main): release 1.17.0
2026-02-17 07:25:40 +03:00
github-actions[bot]
cecaa4bacc chore(main): release 1.17.0 2026-02-17 04:01:32 +00:00
Egor
aa8262d16c Merge pull request #225 from BEDOLAGA-DEV/dev
Dev
2026-02-17 07:01:11 +03:00
Fringg
e0dd21fd0b feat: add web campaign links — capture, auth integration, bonus UI
- Add campaign.ts utility (capture from URL, localStorage with TTL, validation)
- Pass campaign_slug in all auth API methods (telegram, widget, email, oauth)
- Consume slug in auth store login methods, set pendingCampaignBonus state
- Add CampaignBonusNotifier component (toast on bonus, mounted in AppShell)
- Show web_link alongside bot deep_link in AdminCampaignStats
- Add CampaignBonusInfo type with union bonus_type
- Fix VerifyEmail: ref guard against StrictMode double-fire, setTimeout cleanup
- Fix AdminCampaignStats: setTimeout refs with cleanup, i18n-aware locale
- Wrap all localStorage access in try/catch (Safari private browsing safety)
- Add campaignBonus translations (ru/en/fa/zh)
2026-02-17 06:44:10 +03:00
Egor
850124f469 Merge pull request #223 from BEDOLAGA-DEV/release-please--branches--main--components--cabinet-frontend
chore(main): release 1.16.1
2026-02-16 07:32:27 +03:00
github-actions[bot]
003071dd6b chore(main): release 1.16.1 2026-02-16 04:32:01 +00:00
Egor
820001458b Merge pull request #222 from BEDOLAGA-DEV/dev
fix: move cabinet_branding to sessionStorage and add WebGL availabili…
2026-02-16 07:31:43 +03:00
Fringg
fc7ee6abfe fix: move cabinet_branding to sessionStorage and add WebGL availability check
- Branding cache moved from localStorage to sessionStorage so it clears
  when the mini-app is closed, preventing stale names after admin updates
- Added initialDataUpdatedAt: 0 to all branding queries so fresh data is
  always fetched on page refresh while showing cached data instantly
- One-time migration moves existing localStorage value to sessionStorage
- Aurora component now checks WebGL availability upfront, skipping all
  hooks and subscriptions when WebGL is not supported
2026-02-16 07:25:06 +03:00
Egor
8a07fad7ed Merge pull request #221 from BEDOLAGA-DEV/release-please--branches--main--components--cabinet-frontend
chore(main): release 1.16.0
2026-02-16 02:20:58 +03:00
github-actions[bot]
e2f20c5781 chore(main): release 1.16.0 2026-02-15 23:20:26 +00:00
Egor
44fe3cec2c Merge pull request #220 from BEDOLAGA-DEV/dev
Dev
2026-02-16 02:20:07 +03:00
Fringg
54f1483312 fix: prevent button settings cards from overflowing in admin panel
- Add flex-wrap to color picker chips so they wrap on narrow cards
- Add min-w-0/truncate to header text, shrink-0 to badge+toggle group
- Reduce chip padding for better fit in 2-column grid
- Add overflow-hidden to card container as safety net
2026-02-16 02:10:52 +03:00
Fringg
22bda66e81 fix: wheel lands on correct prize sector for Stars payment spins
Stars payment flow previously used Math.random() for wheel rotation,
causing visual mismatch between where the wheel lands and the actual
prize won. Now polls for backend result first, calculates the correct
rotation angle matching the prize sector, then starts the animation.
2026-02-16 02:06:23 +03:00
Fringg
bbe0fe0f04 docs: rewrite README with correct Caddy proxy config and step-by-step installation guide 2026-02-16 01:50:50 +03:00
Fringg
150a1b2dba fix: normalize all API responses, add error handling and reset confirmation
- Extract normalizeConfig() for consistent response normalization
- Add onError handlers to mutations with useNotify
- Add window.confirm before destructive reset action
- Add resetConfirm translation key to all locales
2026-02-13 00:41:00 +03:00
Fringg
1a0a5ff453 feat: add per-button enable/disable toggle and custom labels per locale
- Add Toggle per section card to show/hide button in main menu
- Add collapsible locale label inputs (ru, en, ua, zh, fa) per section
- Normalize server response for backward compatibility with older API
- Update all 4 locale files with new translation keys
2026-02-12 23:42:58 +03:00
Fringg
e586129c37 feat: add 'no color' option for button style customization
Adds a 'default' style option that removes color from buttons, showing
Telegram's native default style. Updates type, UI chip, preview, and
translations for all 4 locales.
2026-02-12 23:25:49 +03:00
Fringg
b2898730b9 feat: add ButtonsTab for per-section button style customization
Visual editor in admin settings for configuring Telegram button colors
and custom emoji IDs per menu section. Includes API client, draft state
management, save/reset, and translations for ru/en/fa/zh locales.
2026-02-12 23:16:08 +03:00
Egor
c244c29448 Merge pull request #219 from BEDOLAGA-DEV/release-please--branches--main--components--cabinet-frontend
chore(main): release 1.15.0
2026-02-12 21:13:12 +03:00
github-actions[bot]
511115d3a1 chore(main): release 1.15.0 2026-02-12 18:12:14 +00:00
Egor
88cc0d933e Merge pull request #218 from BEDOLAGA-DEV/dev
feat: add admin pinned messages section
2026-02-12 21:11:49 +03:00
Fringg
aa5113b8e3 feat: add admin pinned messages section
- API client with full CRUD, broadcast, activate/deactivate, unpin endpoints
- List page with active/inactive badges, action buttons, pagination
- Create/edit form with content editor, media upload, display settings toggles
- Routes and navigation in admin marketing group
- i18n translations for ru, en, fa, zh
2026-02-12 19:33:18 +03:00
Egor
efc843dfde Merge pull request #217 from BEDOLAGA-DEV/release-please--branches--main--components--cabinet-frontend
chore(main): release 1.14.1
2026-02-12 03:08:11 +03:00
github-actions[bot]
cc1182fd7b chore(main): release 1.14.1 2026-02-12 00:07:00 +00:00
Egor
96e24bf772 Merge pull request #216 from BEDOLAGA-DEV/dev
Dev
2026-02-12 03:06:39 +03:00
Fringg
a0b10e688c fix: allow email change for unverified emails without code verification
Skip code-based flow for unverified emails — replace email directly
and send verification to the new address. Show success step immediately
instead of asking for a verification code.
2026-02-11 18:28:49 +03:00
Fringg
1d6ec70116 fix: handle unlimited traffic package selection and button text
- Fix falsy check: selectedTrafficPackage !== null instead of truthy
  (gb=0 for unlimited was evaluated as false, hiding the buy button)
- Show "Buy Unlimited" instead of "Buy 0 GB" for unlimited packages
- Add buyUnlimited translation key to all 4 locales
2026-02-11 18:20:21 +03:00
Egor
7c3f42dbaf Merge pull request #214 from BEDOLAGA-DEV/release-please--branches--main--components--cabinet-frontend
chore(main): release 1.14.0
2026-02-11 06:11:23 +03:00
github-actions[bot]
0c756eda4e chore(main): release 1.14.0 2026-02-11 03:10:57 +00:00
Egor
db1b7e7eea Merge pull request #213 from BEDOLAGA-DEV/dev
Dev
2026-02-11 06:10:33 +03:00
Fringg
2964236cdc refactor: replace forgot password modal with inline screen, fix Safari iOS animation jank 2026-02-11 06:06:22 +03:00
Fringg
d596b05048 fix: remove redundant subtitle and register hint from login page 2026-02-11 05:54:49 +03:00
Fringg
fc0dd39550 fix: use openTelegramLink for CryptoBot payment to open invoice in Telegram 2026-02-11 05:50:31 +03:00
Fringg
dcfd362c43 refactor: replace ChangeEmailModal with inline email change flow in Profile
- Remove modal-based email change (491 lines deleted)
- Add inline step-by-step flow directly in email card (email → code → success)
- Add change email button for unverified emails (typo fix use case)
- Hide change email for OAuth users (google, yandex, discord, vk)
- Auto-focus inputs, Enter submit, animated transitions, 3s auto-close on success
2026-02-11 05:42:47 +03:00
Fringg
45cbfb5ecb feat: compact login page with collapsible email, icon OAuth row, safe areas
- OAuth providers: horizontal icon row with labels instead of stacked full-width buttons
- Email form: collapsed by default behind "Войти по Email" pill toggle with smooth CSS Grid animation
- Telegram safe areas: use useTelegramSDK() for top/bottom insets with env() CSS fallback
- Compact layout: smaller logo (48x48), tighter spacing, fits on one mobile screen
- Language switcher offset by safe area to avoid Telegram header overlap
- 100dvh for proper Telegram Mini App viewport handling
2026-02-11 05:29:19 +03:00
Fringg
a744b41910 fix: harden OAuth login flow — open redirect, path traversal, info leak
- Validate authorize_url is HTTPS before redirect (open redirect prevention)
- encodeURIComponent on provider name in API URL paths (path traversal prevention)
- encodeURIComponent on referralCode in t.me deep link
- Gate console.warn behind import.meta.env.DEV (no info leak in prod)
2026-02-11 02:58:04 +03:00
Fringg
f74e316161 fix: guard oauthProviders with Array.isArray to prevent TypeError on Login page
Fixes 'Cannot read properties of undefined (reading length)' crash
in Telegram WebView when API returns unexpected response shape.
2026-02-11 02:42:32 +03:00
Fringg
6bf0af4ff3 fix: remove colored background from logo on login page
Match logo styling with the rest of the app - use dark neutral
background instead of accent gradient, consistent border and shadow.
2026-02-11 01:43:52 +03:00
Egor
db3d961185 Update package-lock.json 2026-02-10 07:39:04 +03:00
Fringg
069090a634 fix: restore package-lock.json for CI (npm ci requires it) 2026-02-10 07:35:04 +03:00