@lanaco/lnc-react-ui
Version:
React component library
122 lines (120 loc) • 3.03 kB
JavaScript
import { jsxs as E, jsx as t } from "react/jsx-runtime";
import { forwardRef as G } from "react";
import { s as J } from "./emotion-styled.browser.esm-DfbrHHed.js";
import { d as K } from "./breakpoints-BubDitvo.js";
import { L as Q } from "./index-eOeAkUSU.js";
import V from "./LoanCalculatorSection.js";
const X = J.div`
display: flex;
gap: 2rem;
& .loan-calculator,
.location-finder {
flex: 1;
}
@media ${K("S")} {
flex-direction: column;
gap: 1.25rem;
}
`, nt = G((a, e) => {
const {
hasLoanCalculator: o,
hasLocationFinder: n,
// Location finder section
locationFinderTitle: l,
locationFinderPlaceholder: r,
openMapText: i,
onOpenMap: m = () => {
},
mapFilters: s,
inputComponent: c,
// Loan calculator section
loanCalculatorTitle: u,
loanCalculatorText: d,
loanCalculatorPlaceholder: p,
openCalculatorText: x,
onOpenCalculator: f = (Y) => {
},
defaultLoanAmount: y,
defaultInterestRate: L,
defaultLoanPeriod: T,
monthlyPayment: P,
totalInterestPaid: h,
currency: C,
loanPeriodUnit: R,
minLoanAmount: b,
maxLoanAmount: A,
minInterestRate: F,
maxInterestRate: H,
minLoanPeriod: M,
maxLoanPeriod: I,
headerTitleText: S,
footerTitleText: g,
loanAmountLabel: j,
loanAmountHint: w,
interestRateLabel: O,
interestRateHint: v,
loanPeriodLabel: N,
loanPeriodHint: U,
submitText: W,
summaryMonthlyPaymentText: $,
summaryMonthlyPaymentHint: k,
summaryTotalPaymentText: q,
summaryTotalPaymentHint: z,
handleSubmit: B,
handleCancel: D
} = a;
return /* @__PURE__ */ E(X, { ref: e, className: "lp-section lp-custom-loan-map-section", children: [
n === !0 && /* @__PURE__ */ t(
Q,
{
title: l,
placeholderText: r,
onOpenMap: m,
openMapText: i,
mapFilters: s,
inputComponent: c
}
),
o === !0 && /* @__PURE__ */ t(
V,
{
loanCalculatorTitle: u,
loanCalculatorText: d,
loanCalculatorPlaceholder: p,
openCalculatorText: x,
onOpenCalculator: f,
defaultLoanAmount: y,
defaultInterestRate: L,
defaultLoanPeriod: T,
monthlyPayment: P,
totalInterestPaid: h,
currency: C,
loanPeriodUnit: R,
minLoanAmount: b,
maxLoanAmount: A,
minInterestRate: F,
maxInterestRate: H,
minLoanPeriod: M,
maxLoanPeriod: I,
headerTitleText: S,
footerTitleText: g,
loanAmountLabel: j,
loanAmountHint: w,
interestRateLabel: O,
interestRateHint: v,
loanPeriodLabel: N,
loanPeriodHint: U,
submitText: W,
summaryMonthlyPaymentText: $,
summaryMonthlyPaymentHint: k,
summaryTotalPaymentText: q,
summaryTotalPaymentHint: z,
handleSubmit: B,
handleCancel: D
}
)
] });
});
export {
nt as default
};