Fix form keyboard issues and sticky footers in agent screens
This commit is contained in:
@@ -0,0 +1,10 @@
|
||||
export interface ApiError {
|
||||
status: number;
|
||||
message: string;
|
||||
data?: unknown;
|
||||
}
|
||||
|
||||
export interface ApiEnvelope<T> {
|
||||
data: T;
|
||||
message?: string;
|
||||
}
|
||||
@@ -0,0 +1,535 @@
|
||||
export type LanguageCode = 'en' | 'hi' | 'bn';
|
||||
export type AsyncStatus = 'idle' | 'loading' | 'succeeded' | 'failed';
|
||||
export type TransactionDirection = 'credit' | 'debit';
|
||||
export type TransactionStatus = 'completed' | 'pending' | 'failed';
|
||||
export type AccountType = 'Savings' | 'Current' | 'Salary';
|
||||
export type TransferMethod = 'IMPS' | 'NEFT' | 'RTGS' | 'Internal';
|
||||
export type DepositType = 'Fixed Deposit' | 'Recurring Deposit';
|
||||
export type DepositKind = 'fd' | 'rd';
|
||||
export type DepositStatus = 'active' | 'matured' | 'closed';
|
||||
export type DepositInterestPayoutType = 'cumulative' | 'non-cumulative';
|
||||
export type ServiceCategory =
|
||||
| 'Cheque Book'
|
||||
| 'Address Update'
|
||||
| 'Dispute'
|
||||
| 'Statement'
|
||||
| 'Credit Limit';
|
||||
export type ServiceStatus = 'submitted' | 'in-progress' | 'resolved';
|
||||
export type ToastType = 'success' | 'error' | 'info';
|
||||
export type CardStatus = 'active' | 'blocked';
|
||||
export type CardKind = 'Credit' | 'Debit';
|
||||
export type CardNetwork = 'VISA' | 'Mastercard' | 'RuPay';
|
||||
export type CardDeliveryMode = 'home' | 'branch';
|
||||
export type CardDeliveryStage =
|
||||
| 'processing'
|
||||
| 'personalizing'
|
||||
| 'shipped'
|
||||
| 'ready-for-pickup'
|
||||
| 'delivered';
|
||||
|
||||
export type LoginRole = 'User' | 'Employee' | 'Agent';
|
||||
|
||||
export interface AuthTokens {
|
||||
accessToken: string;
|
||||
refreshToken: string;
|
||||
expiresAt: string;
|
||||
role?: LoginRole;
|
||||
}
|
||||
|
||||
export interface NotificationPreference {
|
||||
push: boolean;
|
||||
email: boolean;
|
||||
sms: boolean;
|
||||
}
|
||||
|
||||
export interface UserProfile {
|
||||
id: string;
|
||||
firstName: string;
|
||||
lastName: string;
|
||||
email: string;
|
||||
phone: string;
|
||||
customerId: string;
|
||||
kycStatus: 'verified' | 'pending';
|
||||
ckycNumber?: string;
|
||||
language: LanguageCode;
|
||||
avatarUrl?: string;
|
||||
biometricEnabled: boolean;
|
||||
notifications: NotificationPreference;
|
||||
}
|
||||
|
||||
export interface AccountSummary {
|
||||
id: string;
|
||||
type: AccountType;
|
||||
accountHolder: string;
|
||||
branch: string;
|
||||
maskedNumber: string;
|
||||
availableBalance: number;
|
||||
currentBalance: number;
|
||||
currency: 'INR';
|
||||
isPrimary?: boolean;
|
||||
}
|
||||
|
||||
export interface InsightMetric {
|
||||
id: string;
|
||||
label: string;
|
||||
amount: number;
|
||||
trend: 'up' | 'down' | 'stable';
|
||||
change: number;
|
||||
}
|
||||
|
||||
export interface SpendingBreakdown {
|
||||
id: string;
|
||||
label: string;
|
||||
amount: number;
|
||||
color: string;
|
||||
}
|
||||
|
||||
export interface TransactionRecord {
|
||||
id: string;
|
||||
title: string;
|
||||
category: string;
|
||||
amount: number;
|
||||
direction: TransactionDirection;
|
||||
status: TransactionStatus;
|
||||
occurredAt: string;
|
||||
counterparty: string;
|
||||
}
|
||||
|
||||
export interface Beneficiary {
|
||||
id: string;
|
||||
name: string;
|
||||
bankName: string;
|
||||
accountMasked: string;
|
||||
upiId?: string;
|
||||
nickname?: string;
|
||||
favorite: boolean;
|
||||
}
|
||||
|
||||
export interface TransferDraft {
|
||||
type: TransferMethod | null;
|
||||
beneficiaryId?: string;
|
||||
amount: string;
|
||||
note: string;
|
||||
reference?: string;
|
||||
}
|
||||
|
||||
export interface UpiDraft {
|
||||
merchantName?: string;
|
||||
amount: string;
|
||||
note: string;
|
||||
}
|
||||
|
||||
export interface DepositProduct {
|
||||
id: string;
|
||||
kind: DepositKind;
|
||||
type: DepositType;
|
||||
name: string;
|
||||
rate: number;
|
||||
minimumTenureMonths: number;
|
||||
maximumTenureMonths: number;
|
||||
defaultTenureMonths: number;
|
||||
minimumAmount?: number;
|
||||
maximumAmount?: number;
|
||||
minimumInstallment?: number;
|
||||
maximumInstallment?: number;
|
||||
interestPayoutOptions?: DepositInterestPayoutType[];
|
||||
}
|
||||
|
||||
export interface DepositDraft {
|
||||
productId?: string;
|
||||
amount: string;
|
||||
monthlyInstallment: string;
|
||||
tenureMonths: number;
|
||||
interestPayoutType: DepositInterestPayoutType;
|
||||
}
|
||||
|
||||
export interface DepositNominee {
|
||||
name: string;
|
||||
relationship: string;
|
||||
}
|
||||
|
||||
export interface DepositTransaction {
|
||||
id: string;
|
||||
title: string;
|
||||
category: string;
|
||||
amount: number;
|
||||
direction: TransactionDirection;
|
||||
status: TransactionStatus;
|
||||
occurredAt: string;
|
||||
}
|
||||
|
||||
export interface DepositAccount {
|
||||
id: string;
|
||||
productId: string;
|
||||
kind: DepositKind;
|
||||
type: DepositType;
|
||||
maskedNumber: string;
|
||||
principalAmount: number;
|
||||
monthlyInstallment?: number;
|
||||
totalInvestment: number;
|
||||
interestRate: number;
|
||||
tenureMonths: number;
|
||||
startDate: string;
|
||||
maturityDate: string;
|
||||
maturityAmount: number;
|
||||
interestEarned: number;
|
||||
payoutLabel: string;
|
||||
interestPayoutType?: DepositInterestPayoutType;
|
||||
status: DepositStatus;
|
||||
settlementAccountMasked: string;
|
||||
nominee?: DepositNominee;
|
||||
canWithdrawPrematurely: boolean;
|
||||
prematurePenaltyRate?: number;
|
||||
transactions: DepositTransaction[];
|
||||
}
|
||||
|
||||
export interface ServiceRequest {
|
||||
id: string;
|
||||
category: ServiceCategory;
|
||||
status: ServiceStatus;
|
||||
createdAt: string;
|
||||
notes: string;
|
||||
}
|
||||
|
||||
export interface SupportMessage {
|
||||
id: string;
|
||||
sender: 'user' | 'agent';
|
||||
message: string;
|
||||
sentAt: string;
|
||||
}
|
||||
|
||||
export interface LoanProduct {
|
||||
id: string;
|
||||
name: string;
|
||||
category: LoanCategory;
|
||||
interestRate: number;
|
||||
maxAmount: number;
|
||||
minAmount: number;
|
||||
tenureMonths: number;
|
||||
minTenureMonths: number;
|
||||
processingFeePercent: number;
|
||||
description: string;
|
||||
features: string[];
|
||||
}
|
||||
|
||||
export type LoanCategory = 'Personal Loan' | 'Home Loan' | 'Car Loan' | 'Gold Loan' | 'Education Loan';
|
||||
export type LoanStatus = 'Active' | 'Closed' | 'Overdue';
|
||||
export type LoanApplicationStage = 'Submitted' | 'Under Review' | 'Approved' | 'Rejected' | 'Disbursed';
|
||||
export type LoanDocumentType = 'Aadhaar' | 'PAN' | 'Salary Slip' | 'Bank Statement' | 'Address Proof' | 'Other';
|
||||
export type LoanDocumentStatus = 'uploaded' | 'verified' | 'rejected';
|
||||
export type LoanPaymentMethod = 'UPI' | 'Net Banking' | 'Wallet';
|
||||
export type EmploymentType = 'Salaried' | 'Self Employed' | 'Business' | 'Professional';
|
||||
export type LoanNotificationType = 'emi_reminder' | 'payment_success' | 'payment_failure' | 'approval' | 'rejection' | 'disbursement';
|
||||
|
||||
export interface ActiveLoan {
|
||||
id: string;
|
||||
type: LoanCategory;
|
||||
loanAccountNumber: string;
|
||||
accountNumber: string;
|
||||
sanctionedAmount: number;
|
||||
principalAmount: number;
|
||||
disbursedAmount: number;
|
||||
outstandingBalance: number;
|
||||
interestRate: number;
|
||||
tenureMonths: number;
|
||||
remainingTenure: number;
|
||||
paidEmis: number;
|
||||
totalEmis: number;
|
||||
emiAmount: number;
|
||||
nextEmiDate: string;
|
||||
disbursedDate: string;
|
||||
autoDebitEnabled: boolean;
|
||||
foreclosureChargePercent: number;
|
||||
status: LoanStatus;
|
||||
}
|
||||
|
||||
export interface LoanApplicationStatus {
|
||||
id: string;
|
||||
loanCategory: LoanCategory;
|
||||
type: string;
|
||||
amount: number;
|
||||
approvedAmount?: number;
|
||||
appliedDate: string;
|
||||
status: LoanApplicationStage;
|
||||
documentsUploaded: number;
|
||||
documentsRequired: number;
|
||||
timeline: { stage: string; timestamp: string; active: boolean }[];
|
||||
}
|
||||
|
||||
export interface LoanEmiScheduleItem {
|
||||
month: number;
|
||||
emiAmount: number;
|
||||
principalComponent: number;
|
||||
interestComponent: number;
|
||||
outstandingAfter: number;
|
||||
}
|
||||
|
||||
export interface LoanDocument {
|
||||
id: string;
|
||||
name: string;
|
||||
type: LoanDocumentType;
|
||||
status: LoanDocumentStatus;
|
||||
uploadedAt: string;
|
||||
uri?: string;
|
||||
rejectionReason?: string;
|
||||
}
|
||||
|
||||
export interface LoanPaymentRecord {
|
||||
id: string;
|
||||
loanId: string;
|
||||
loanType: LoanCategory;
|
||||
amount: number;
|
||||
date: string;
|
||||
method: LoanPaymentMethod;
|
||||
status: 'success' | 'failed' | 'pending';
|
||||
transactionRef: string;
|
||||
}
|
||||
|
||||
export interface LoanForeclosureQuote {
|
||||
loanId: string;
|
||||
outstandingPrincipal: number;
|
||||
interestDue: number;
|
||||
foreclosureCharges: number;
|
||||
totalPayable: number;
|
||||
validUntil: string;
|
||||
}
|
||||
|
||||
export interface LoanApplicationDraft {
|
||||
loanCategory: LoanCategory | null;
|
||||
amount: string;
|
||||
tenureMonths: string;
|
||||
monthlyIncome: string;
|
||||
employmentType: EmploymentType | null;
|
||||
existingLiabilities: string;
|
||||
purpose: string;
|
||||
documents: LoanDocument[];
|
||||
}
|
||||
|
||||
export interface LoanEligibilityResult {
|
||||
eligible: boolean;
|
||||
eligibleAmount: number;
|
||||
maxTenureMonths: number;
|
||||
interestRate: number;
|
||||
estimatedEmi: number;
|
||||
reason?: string;
|
||||
}
|
||||
|
||||
export interface LoanNotification {
|
||||
id: string;
|
||||
type: LoanNotificationType;
|
||||
title: string;
|
||||
body: string;
|
||||
createdAt: string;
|
||||
read: boolean;
|
||||
loanId?: string;
|
||||
}
|
||||
|
||||
export interface LoanHistoryItem {
|
||||
id: string;
|
||||
date: string;
|
||||
amount: number;
|
||||
description: string;
|
||||
status: 'success' | 'failed';
|
||||
}
|
||||
|
||||
export interface InsurancePlan {
|
||||
id: string;
|
||||
name: string;
|
||||
premium: number;
|
||||
coverAmount: number;
|
||||
summary: string;
|
||||
}
|
||||
|
||||
export interface CardControlState {
|
||||
online: boolean;
|
||||
atm: boolean;
|
||||
contactless: boolean;
|
||||
international: boolean;
|
||||
frozen: boolean;
|
||||
}
|
||||
|
||||
export interface CardLimitConfig {
|
||||
daily: number;
|
||||
atmWithdrawal: number;
|
||||
pos: number;
|
||||
}
|
||||
|
||||
export interface CardNotificationSettings {
|
||||
transactionAlerts: boolean;
|
||||
suspiciousActivity: boolean;
|
||||
internationalUsage: boolean;
|
||||
}
|
||||
|
||||
export interface CardStatement {
|
||||
id: string;
|
||||
monthLabel: string;
|
||||
periodStart: string;
|
||||
periodEnd: string;
|
||||
dueDate: string;
|
||||
totalAmount: number;
|
||||
minimumDue: number;
|
||||
downloadable: boolean;
|
||||
}
|
||||
|
||||
export interface CardOffer {
|
||||
id: string;
|
||||
title: string;
|
||||
subtitle: string;
|
||||
cashback: string;
|
||||
merchant: string;
|
||||
expiresAt: string;
|
||||
}
|
||||
|
||||
export interface CardRewardSummary {
|
||||
points: number;
|
||||
tier: 'Silver' | 'Gold' | 'Platinum';
|
||||
redeemValue: number;
|
||||
}
|
||||
|
||||
export interface CardSecurityDetails {
|
||||
fullNumber: string;
|
||||
cvv: string;
|
||||
billingCycle: string;
|
||||
outstandingBalance: number;
|
||||
minimumDue: number;
|
||||
dueDate: string;
|
||||
}
|
||||
|
||||
export interface VirtualCard {
|
||||
id: string;
|
||||
maskedNumber: string;
|
||||
fullNumber: string;
|
||||
expiry: string;
|
||||
cvv: string;
|
||||
spendingLimit: number;
|
||||
active: boolean;
|
||||
createdAt: string;
|
||||
}
|
||||
|
||||
export interface CardTransaction {
|
||||
id: string;
|
||||
merchant: string;
|
||||
amount: number;
|
||||
direction: TransactionDirection;
|
||||
status: TransactionStatus;
|
||||
occurredAt: string;
|
||||
category: string;
|
||||
}
|
||||
|
||||
export interface CardSpendInsight {
|
||||
monthLabel: string;
|
||||
budget: number;
|
||||
totalSpent: number;
|
||||
categories: SpendingBreakdown[];
|
||||
}
|
||||
|
||||
export interface CardPhysicalDelivery {
|
||||
mode: CardDeliveryMode;
|
||||
status: CardDeliveryStage;
|
||||
trackingId: string;
|
||||
requestedAt: string;
|
||||
lastUpdatedAt: string;
|
||||
estimatedDate: string;
|
||||
destinationLabel: string;
|
||||
}
|
||||
|
||||
export interface BankCard {
|
||||
id: string;
|
||||
name: string;
|
||||
cardholderName: string;
|
||||
type: CardKind;
|
||||
maskedNumber: string;
|
||||
expiry: string;
|
||||
network: CardNetwork;
|
||||
status: CardStatus;
|
||||
availableLimit: number;
|
||||
spendToday: number;
|
||||
linkedAccountIds: string[];
|
||||
primaryLinkedAccountId: string;
|
||||
isDefault: boolean;
|
||||
themeColors: [string, string, string];
|
||||
controls: CardControlState;
|
||||
limits: CardLimitConfig;
|
||||
notifications: CardNotificationSettings;
|
||||
secureDetails: CardSecurityDetails;
|
||||
rewards: CardRewardSummary;
|
||||
offers: CardOffer[];
|
||||
statements: CardStatement[];
|
||||
spendInsight: CardSpendInsight;
|
||||
transactions: CardTransaction[];
|
||||
virtualCard: VirtualCard | null;
|
||||
physicalCardDelivery?: CardPhysicalDelivery | null;
|
||||
}
|
||||
|
||||
export interface ToastMessage {
|
||||
id: string;
|
||||
type: ToastType;
|
||||
title: string;
|
||||
description?: string;
|
||||
}
|
||||
|
||||
export interface FeatureShortcut {
|
||||
id: string;
|
||||
title: string;
|
||||
subtitle: string;
|
||||
route: string;
|
||||
accent: string;
|
||||
}
|
||||
|
||||
export interface DashboardPayload {
|
||||
accounts: AccountSummary[];
|
||||
transactions: TransactionRecord[];
|
||||
insights: InsightMetric[];
|
||||
spending: SpendingBreakdown[];
|
||||
quickActions: FeatureShortcut[];
|
||||
}
|
||||
|
||||
export interface CertificateItem {
|
||||
id: string;
|
||||
title: string;
|
||||
subtitle: string;
|
||||
date: string;
|
||||
kind: 'balance' | 'interest' | 'hypothecation' | 'insurance' | 'fd' | 'rd' | '15g' | '15h';
|
||||
downloadUrl?: string;
|
||||
}
|
||||
|
||||
export interface ChequeState {
|
||||
id: string;
|
||||
chequeNumber: string;
|
||||
amount: number;
|
||||
payee: string;
|
||||
date: string;
|
||||
status: 'Requested' | 'Processed' | 'Cleared' | 'Stopped' | 'Bounced';
|
||||
timeline: { stage: string; timestamp: string; active: boolean }[];
|
||||
}
|
||||
|
||||
export interface PositivePayRequest {
|
||||
id: string;
|
||||
chequeNumber: string;
|
||||
amount: number;
|
||||
payee: string;
|
||||
date: string;
|
||||
accountNumber: string;
|
||||
status: 'verified' | 'pending' | 'failed';
|
||||
}
|
||||
|
||||
export type ChequeBookRequestStatus = 'submitted' | 'processing' | 'dispatched' | 'delivered';
|
||||
|
||||
export type BranchFacility = 'ATM' | 'Loan Desk' | 'Locker' | 'Forex' | 'NRI Desk';
|
||||
|
||||
export interface Branch {
|
||||
id: string;
|
||||
name: string;
|
||||
address: string;
|
||||
city: string;
|
||||
state: string;
|
||||
pincode: string;
|
||||
latitude: number;
|
||||
longitude: number;
|
||||
phone: string;
|
||||
ifscCode: string;
|
||||
timings: string;
|
||||
facilities: BranchFacility[];
|
||||
isMainBranch?: boolean;
|
||||
locationType?: 'branch' | 'atm';
|
||||
}
|
||||
@@ -0,0 +1,2 @@
|
||||
export * from './api';
|
||||
export * from './app';
|
||||
Reference in New Issue
Block a user