UNPKG

@wealthx/borrow-capacity-lib

Version:
81 lines (80 loc) 2.13 kB
import { Account, PeriodType } from "./finance.types"; export interface BorrowCapacityParams { monthlyIncome: number; numberOfApplicants: number; numberOfDependants: number; monthlyRentalIncome: number; monthlyExpense: number; interestRate?: number; loanTerm?: number; bufferRate?: number; surplusAvailableForLoanRate?: number; } export interface LoanRepaymentParams { principal: number; interestRate?: number; loanTerm?: number; } export interface LVRCalculationParams { mortgageLoan: number; propertiesEstimatedValue: number; } export interface EquityCalculationParams { propertiesEstimatedValue: number; mortgageLoan: number; } export interface ExcessMonthlySurplusParams { totalIncome: number; totalExpense: number; } export interface PropertiesEstimatedValueParams { properties: Array<{ estimate: number; }>; } export interface MortgageLoanParams { accounts: Array<Account>; propertyLinkedAccountIds: Set<string>; } export interface LenderInfoResult { lenderNames: string[]; lenderShortNames: (string | null)[]; debtInterestRates: (number | null)[]; } export interface EquityFromAccountsParams { properties: Array<{ estimate: number; accountIds?: string; }>; accounts: Array<Account>; } export interface EquityData { equity: number; propertiesEstimatedValue: number; mortgageLoan: number; } export interface BuyingGoalParams { cashAvailable: number; equity: number; desiredLoanAmount: number; } export interface BuyingPowerParams { cashAvailable: number; equity: number; maxLoanAmount: number; } export interface HEMCalculationParams { annualIncome: number; numberOfApplicants: number; numberOfDependants: number; period: PeriodType; bufferRate?: number; } export interface GrossToNetParams { grossIncome: number; includeMedicareLevy?: boolean; } export interface NetToGrossParams { netIncome: number; includeMedicareLevy?: boolean; }