Post Donate Badge Toggle Modal

This commit is contained in:
yash-signal
2025-08-12 19:35:52 -05:00
committed by GitHub
parent ae3e7cfc41
commit 78c1559f76
20 changed files with 892 additions and 19 deletions
+3
View File
@@ -4,6 +4,7 @@
import { z } from 'zod';
export const ONE_TIME_DONATION_CONFIG_ID = '1';
export const BOOST_ID = 'BOOST';
export const donationStateSchema = z.enum([
'INTENT',
@@ -14,6 +15,8 @@ export const donationStateSchema = z.enum([
'DONE',
]);
export type DonationStateType = z.infer<typeof donationStateSchema>;
export const donationErrorTypeSchema = z.enum([
// Used if the user is redirected back from validation, but continuing forward fails
'Failed3dsValidation',
+2
View File
@@ -8,6 +8,7 @@ export enum ToastType {
AlreadyRequestedToJoin = 'AlreadyRequestedToJoin',
AttachmentDownloadFailed = 'AttachmentDownloadFailed',
AttachmentDownloadStillInProgress = 'AttachmentDownloadStillInProgress',
DonationCompletedAndBadgeApplicationFailed = 'DonationCompletedAndBadgeApplicationFailed',
Blocked = 'Blocked',
BlockedGroup = 'BlockedGroup',
CallHistoryCleared = 'CallHistoryCleared',
@@ -103,6 +104,7 @@ export type AnyToast =
toastType: ToastType.AttachmentDownloadStillInProgress;
parameters: { count: number };
}
| { toastType: ToastType.DonationCompletedAndBadgeApplicationFailed }
| { toastType: ToastType.Blocked }
| { toastType: ToastType.BlockedGroup }
| { toastType: ToastType.CallHistoryCleared }