- Implemented MpReauthNotice component to notify users when reauthorization is needed. - Created MpStatusCard component to display the current status of the Mercado Pago account. - Added utility functions and constants for handling Mercado Pago status and messages. - Introduced hooks for managing the connection and disconnection of Mercado Pago accounts. - Developed a disconnect confirmation modal for user actions. - Added tests for the new functionality and utility functions. - Defined schemas for Mercado Pago account status and callback reasons in shared package.
17 lines
415 B
TypeScript
17 lines
415 B
TypeScript
import { z } from 'zod';
|
|
|
|
// Weekdays on which classes are held.
|
|
export const weekdaySchema = z.enum([
|
|
'MONDAY',
|
|
'TUESDAY',
|
|
'WEDNESDAY',
|
|
'THURSDAY',
|
|
'FRIDAY',
|
|
'SATURDAY',
|
|
'SUNDAY',
|
|
]);
|
|
export type WeekDay = z.output<typeof weekdaySchema>;
|
|
|
|
// Billing frequency of a group.
|
|
export const billingTypeSchema = z.enum(['MONTHLY', 'PER_CLASS']);
|
|
export type BillingType = z.output<typeof billingTypeSchema>; |