@loafmarkets/ui 0.1.11 → 0.1.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +241 -44
- package/dist/index.d.ts +241 -44
- package/dist/index.js +6356 -1663
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +6330 -1650
- package/dist/index.mjs.map +1 -1
- package/package.json +12 -6
- package/src/assets/Loaf-logo-Banner.png +0 -0
package/dist/index.d.mts
CHANGED
|
@@ -412,12 +412,76 @@ declare const PropertyHeroHeader: React.ForwardRefExoticComponent<React.HTMLAttr
|
|
|
412
412
|
onMakeOffer?: () => void;
|
|
413
413
|
} & React.RefAttributes<HTMLDivElement>>;
|
|
414
414
|
|
|
415
|
+
type EmailCodeParams = {
|
|
416
|
+
email: string;
|
|
417
|
+
isSignUp: boolean;
|
|
418
|
+
handle?: string | null;
|
|
419
|
+
};
|
|
420
|
+
type VerifyCodeParams = {
|
|
421
|
+
code: string;
|
|
422
|
+
email: string;
|
|
423
|
+
};
|
|
424
|
+
type DemoLoginResult = {
|
|
425
|
+
success: boolean;
|
|
426
|
+
};
|
|
427
|
+
type DemoLoginHandler = (email: string, handle?: string | null) => Promise<DemoLoginResult | void> | DemoLoginResult | void;
|
|
428
|
+
type LoginPopupView = "main" | "email" | "otp" | "kyc" | "kyc-success" | "kyc-failed" | "funding";
|
|
429
|
+
type FundWalletParams = {
|
|
430
|
+
amount: string;
|
|
431
|
+
};
|
|
432
|
+
type LoginPopupProps = {
|
|
433
|
+
onClose: () => void;
|
|
434
|
+
onOpenEarlyAccess?: () => void;
|
|
435
|
+
/**
|
|
436
|
+
* Optional flag that indicates an authenticated session exists. When true (and autoCloseOnAuth is enabled)
|
|
437
|
+
* the popup will close automatically, mirroring the loaf-demo behaviour that watched Privy + demo auth state.
|
|
438
|
+
*/
|
|
439
|
+
isAuthenticated?: boolean;
|
|
440
|
+
/** Optional user payload that, when truthy, also triggers the auto close effect. */
|
|
441
|
+
currentUser?: unknown;
|
|
442
|
+
/**
|
|
443
|
+
* Handler that should kick off an email OTP flow (e.g. Privy's sendCode). When omitted, the component will
|
|
444
|
+
* display an inline error explaining that email auth is unavailable.
|
|
445
|
+
*/
|
|
446
|
+
onSendEmailCode?: (params: EmailCodeParams) => Promise<void> | void;
|
|
447
|
+
/** Handler invoked when the user submits the 6-digit OTP code. */
|
|
448
|
+
onVerifyEmailCode?: (params: VerifyCodeParams) => Promise<void> | void;
|
|
449
|
+
/** Optional handler used for demo / local login flows before falling back to email OTP. */
|
|
450
|
+
onDemoLogin?: DemoLoginHandler;
|
|
451
|
+
/** Override for the logo shown in the popup header. */
|
|
452
|
+
logoSrc?: string;
|
|
453
|
+
logoAlt?: string;
|
|
454
|
+
/** Disable auto-closing behaviour tied to isAuthenticated/currentUser flags. */
|
|
455
|
+
autoCloseOnAuth?: boolean;
|
|
456
|
+
/**
|
|
457
|
+
* Handler called when the user clicks "KYC me now". Should trigger the KYC verification flow
|
|
458
|
+
* and resolve with { passed: boolean } when complete.
|
|
459
|
+
*/
|
|
460
|
+
onKycStart?: () => Promise<{
|
|
461
|
+
passed: boolean;
|
|
462
|
+
}> | void;
|
|
463
|
+
/**
|
|
464
|
+
* Handler called when the user clicks "Fund my account". Should open the funding UI (e.g. Coinbase onramp)
|
|
465
|
+
* and resolve with { funded: boolean } when the user exits.
|
|
466
|
+
*/
|
|
467
|
+
onFundWallet?: (params: FundWalletParams) => Promise<{
|
|
468
|
+
funded: boolean;
|
|
469
|
+
}> | void;
|
|
470
|
+
/** Optional view to show immediately when the popup opens. */
|
|
471
|
+
initialView?: LoginPopupView;
|
|
472
|
+
};
|
|
473
|
+
declare const LoginPopup: React__default.FC<LoginPopupProps>;
|
|
474
|
+
|
|
415
475
|
type HeaderUser = {
|
|
416
476
|
displayName?: string | null;
|
|
417
477
|
email?: string | null;
|
|
418
478
|
walletAddress?: string | null;
|
|
419
479
|
};
|
|
420
480
|
type HeaderActiveTab = "home" | "trade" | "offerings" | "propertyMap" | "about";
|
|
481
|
+
type HeaderLoginPopupComponentProps = {
|
|
482
|
+
onClose: () => void;
|
|
483
|
+
initialView?: LoginPopupView;
|
|
484
|
+
};
|
|
421
485
|
type HeaderProps = {
|
|
422
486
|
currentUser?: HeaderUser | null;
|
|
423
487
|
isAuthenticated?: boolean;
|
|
@@ -426,9 +490,7 @@ type HeaderProps = {
|
|
|
426
490
|
onNavigate?: (path: string) => void;
|
|
427
491
|
onLogout?: () => Promise<void> | void;
|
|
428
492
|
onSignInClick?: () => void;
|
|
429
|
-
loginPopupComponent?: React__default.ComponentType<
|
|
430
|
-
onClose: () => void;
|
|
431
|
-
}>;
|
|
493
|
+
loginPopupComponent?: React__default.ComponentType<HeaderLoginPopupComponentProps>;
|
|
432
494
|
tradeUrl?: string;
|
|
433
495
|
tradePath?: string;
|
|
434
496
|
homePath?: string;
|
|
@@ -480,46 +542,6 @@ declare const PropertySubheader: React.ForwardRefExoticComponent<React.HTMLAttri
|
|
|
480
542
|
actions?: PropertySubheaderAction[];
|
|
481
543
|
} & React.RefAttributes<HTMLDivElement>>;
|
|
482
544
|
|
|
483
|
-
type EmailCodeParams = {
|
|
484
|
-
email: string;
|
|
485
|
-
isSignUp: boolean;
|
|
486
|
-
handle?: string | null;
|
|
487
|
-
};
|
|
488
|
-
type VerifyCodeParams = {
|
|
489
|
-
code: string;
|
|
490
|
-
email: string;
|
|
491
|
-
};
|
|
492
|
-
type DemoLoginResult = {
|
|
493
|
-
success: boolean;
|
|
494
|
-
};
|
|
495
|
-
type DemoLoginHandler = (email: string, handle?: string | null) => Promise<DemoLoginResult | void> | DemoLoginResult | void;
|
|
496
|
-
type LoginPopupProps = {
|
|
497
|
-
onClose: () => void;
|
|
498
|
-
onOpenEarlyAccess?: () => void;
|
|
499
|
-
/**
|
|
500
|
-
* Optional flag that indicates an authenticated session exists. When true (and autoCloseOnAuth is enabled)
|
|
501
|
-
* the popup will close automatically, mirroring the loaf-demo behaviour that watched Privy + demo auth state.
|
|
502
|
-
*/
|
|
503
|
-
isAuthenticated?: boolean;
|
|
504
|
-
/** Optional user payload that, when truthy, also triggers the auto close effect. */
|
|
505
|
-
currentUser?: unknown;
|
|
506
|
-
/**
|
|
507
|
-
* Handler that should kick off an email OTP flow (e.g. Privy's sendCode). When omitted, the component will
|
|
508
|
-
* display an inline error explaining that email auth is unavailable.
|
|
509
|
-
*/
|
|
510
|
-
onSendEmailCode?: (params: EmailCodeParams) => Promise<void> | void;
|
|
511
|
-
/** Handler invoked when the user submits the 6-digit OTP code. */
|
|
512
|
-
onVerifyEmailCode?: (params: VerifyCodeParams) => Promise<void> | void;
|
|
513
|
-
/** Optional handler used for demo / local login flows before falling back to email OTP. */
|
|
514
|
-
onDemoLogin?: DemoLoginHandler;
|
|
515
|
-
/** Override for the logo shown in the popup header. */
|
|
516
|
-
logoSrc?: string;
|
|
517
|
-
logoAlt?: string;
|
|
518
|
-
/** Disable auto-closing behaviour tied to isAuthenticated/currentUser flags. */
|
|
519
|
-
autoCloseOnAuth?: boolean;
|
|
520
|
-
};
|
|
521
|
-
declare const LoginPopup: React__default.FC<LoginPopupProps>;
|
|
522
|
-
|
|
523
545
|
type PropertyAddressOption = {
|
|
524
546
|
id: string;
|
|
525
547
|
label: string;
|
|
@@ -556,4 +578,179 @@ declare const PropertyCompareBar: React.ForwardRefExoticComponent<React.HTMLAttr
|
|
|
556
578
|
price?: PropertyPriceSummary;
|
|
557
579
|
} & React.RefAttributes<HTMLDivElement>>;
|
|
558
580
|
|
|
559
|
-
|
|
581
|
+
type PropertyOverviewProps = {
|
|
582
|
+
propertyName: string;
|
|
583
|
+
location: string;
|
|
584
|
+
midPrice: number;
|
|
585
|
+
onTradeClick?: () => void;
|
|
586
|
+
};
|
|
587
|
+
declare function PropertyOverview({ propertyName: _propertyName, location: _location, midPrice: _midPrice, onTradeClick: _onTradeClick }: PropertyOverviewProps): react_jsx_runtime.JSX.Element;
|
|
588
|
+
|
|
589
|
+
type OfferStatus = 'active' | 'rejected' | 'expired' | 'historical' | 'pending';
|
|
590
|
+
type PropertyOffer = {
|
|
591
|
+
id: number;
|
|
592
|
+
price: string;
|
|
593
|
+
buyer: string;
|
|
594
|
+
date: string;
|
|
595
|
+
expiry: string;
|
|
596
|
+
status: OfferStatus;
|
|
597
|
+
conditions: string;
|
|
598
|
+
};
|
|
599
|
+
type PropertyOffersProps = {
|
|
600
|
+
offers: PropertyOffer[];
|
|
601
|
+
};
|
|
602
|
+
declare function PropertyOffers({ offers }: PropertyOffersProps): react_jsx_runtime.JSX.Element;
|
|
603
|
+
|
|
604
|
+
declare function PropertyHistory(): react_jsx_runtime.JSX.Element;
|
|
605
|
+
|
|
606
|
+
declare function PropertyDocuments(): react_jsx_runtime.JSX.Element;
|
|
607
|
+
|
|
608
|
+
type InspectionSlot = {
|
|
609
|
+
slotId: string;
|
|
610
|
+
label: string;
|
|
611
|
+
date: string;
|
|
612
|
+
startTime: string;
|
|
613
|
+
endTime: string;
|
|
614
|
+
totalCapacity: number;
|
|
615
|
+
spotsRemaining: number;
|
|
616
|
+
};
|
|
617
|
+
type PropertyInspectionTimesProps = {
|
|
618
|
+
isAuthenticated: boolean;
|
|
619
|
+
slots: InspectionSlot[];
|
|
620
|
+
loading?: boolean;
|
|
621
|
+
error?: string | null;
|
|
622
|
+
bookingSlotId?: string | null;
|
|
623
|
+
bookingStatus?: string | null;
|
|
624
|
+
bookingError?: string | null;
|
|
625
|
+
onBook: (slot: InspectionSlot) => void;
|
|
626
|
+
onRetry?: () => void;
|
|
627
|
+
onSignIn?: () => void;
|
|
628
|
+
};
|
|
629
|
+
declare function PropertyInspectionTimes({ isAuthenticated, slots, loading, error, bookingSlotId, bookingStatus, bookingError, onBook, onRetry, onSignIn, }: PropertyInspectionTimesProps): react_jsx_runtime.JSX.Element;
|
|
630
|
+
|
|
631
|
+
type SaleData = {
|
|
632
|
+
state: {
|
|
633
|
+
status: number;
|
|
634
|
+
totalSold: bigint;
|
|
635
|
+
totalRaised: bigint;
|
|
636
|
+
totalFees: bigint;
|
|
637
|
+
propertyToken: `0x${string}`;
|
|
638
|
+
fundsWithdrawn: boolean;
|
|
639
|
+
} | null;
|
|
640
|
+
config: {
|
|
641
|
+
supplyToSell: bigint;
|
|
642
|
+
tokenPrice: bigint;
|
|
643
|
+
maxPerWallet: bigint;
|
|
644
|
+
feeBps: bigint;
|
|
645
|
+
paymentToken: `0x${string}`;
|
|
646
|
+
feeRecipient: `0x${string}`;
|
|
647
|
+
fundsRecipient: `0x${string}`;
|
|
648
|
+
} | null;
|
|
649
|
+
loading: boolean;
|
|
650
|
+
error: string | null;
|
|
651
|
+
totalSold: number;
|
|
652
|
+
supplyToSell: number;
|
|
653
|
+
percentSold: number;
|
|
654
|
+
statusLabel: string;
|
|
655
|
+
tokenPrice: number;
|
|
656
|
+
feePercent: number;
|
|
657
|
+
offeringValuation: number;
|
|
658
|
+
};
|
|
659
|
+
|
|
660
|
+
type PropertyBuyProps = {
|
|
661
|
+
propertyName?: string;
|
|
662
|
+
propertyLocation?: string;
|
|
663
|
+
isAuthenticated: boolean;
|
|
664
|
+
onSignIn: () => void;
|
|
665
|
+
saleData?: SaleData | null;
|
|
666
|
+
};
|
|
667
|
+
declare function PropertyBuy({ propertyName, propertyLocation: propertyLocationLabel, isAuthenticated, onSignIn, saleData, }: PropertyBuyProps): react_jsx_runtime.JSX.Element;
|
|
668
|
+
|
|
669
|
+
type OwnerBookingProps = {
|
|
670
|
+
propertyName?: string | null;
|
|
671
|
+
token: {
|
|
672
|
+
price?: number | null;
|
|
673
|
+
};
|
|
674
|
+
};
|
|
675
|
+
declare const OwnerBooking: ({ propertyName, token }: OwnerBookingProps) => react_jsx_runtime.JSX.Element;
|
|
676
|
+
|
|
677
|
+
type PaymentPopupProps = {
|
|
678
|
+
isOpen: boolean;
|
|
679
|
+
onClose: () => void;
|
|
680
|
+
onConfirm: (method: string) => void;
|
|
681
|
+
selectedDates: Date[];
|
|
682
|
+
totalCost: number;
|
|
683
|
+
isOwnerRate: boolean;
|
|
684
|
+
tokenPrice: number;
|
|
685
|
+
ownerRate: number;
|
|
686
|
+
marketRate: number;
|
|
687
|
+
userTokenHoldings: number;
|
|
688
|
+
propertyName: string;
|
|
689
|
+
};
|
|
690
|
+
declare function PaymentPopup({ isOpen, onClose, onConfirm, selectedDates, totalCost, isOwnerRate, tokenPrice, ownerRate, marketRate, userTokenHoldings, propertyName, }: PaymentPopupProps): react_jsx_runtime.JSX.Element | null;
|
|
691
|
+
|
|
692
|
+
type ValuationRecentSale = {
|
|
693
|
+
readonly imageUrl?: string;
|
|
694
|
+
readonly price?: number | null;
|
|
695
|
+
readonly currency?: string | null;
|
|
696
|
+
readonly saleDate?: string | null;
|
|
697
|
+
readonly address?: string | null;
|
|
698
|
+
readonly suburb?: string | null;
|
|
699
|
+
readonly bedrooms?: number | null;
|
|
700
|
+
readonly bathrooms?: number | null;
|
|
701
|
+
readonly landSize?: string | null;
|
|
702
|
+
};
|
|
703
|
+
type ValuationSummary = {
|
|
704
|
+
readonly propertyId?: number;
|
|
705
|
+
readonly lastPrice?: number | null;
|
|
706
|
+
readonly fairValue?: number | null;
|
|
707
|
+
readonly totalTokens?: number | null;
|
|
708
|
+
readonly confidence?: string | null;
|
|
709
|
+
readonly undervaluedThreshold?: number | null;
|
|
710
|
+
readonly overvaluedThreshold?: number | null;
|
|
711
|
+
readonly valuationDeltaPercent?: number | null;
|
|
712
|
+
readonly valuationStatus?: string | null;
|
|
713
|
+
readonly areaDemand?: string | null;
|
|
714
|
+
readonly propertyMoat?: string | null;
|
|
715
|
+
readonly recentSales?: ValuationRecentSale[];
|
|
716
|
+
};
|
|
717
|
+
type ValuationHistoryPoint = {
|
|
718
|
+
readonly timestamp: number;
|
|
719
|
+
readonly valuation: number;
|
|
720
|
+
readonly fairValue?: number | null;
|
|
721
|
+
};
|
|
722
|
+
type PropertyValuationProps = {
|
|
723
|
+
propertyName: string;
|
|
724
|
+
tokenPrice: number;
|
|
725
|
+
totalTokens?: number | null;
|
|
726
|
+
summary?: ValuationSummary | null;
|
|
727
|
+
history?: ValuationHistoryPoint[];
|
|
728
|
+
loading?: boolean;
|
|
729
|
+
error?: string | null;
|
|
730
|
+
};
|
|
731
|
+
declare function PropertyValuation({ propertyName, tokenPrice, totalTokens, summary, history, loading, error, }: PropertyValuationProps): react_jsx_runtime.JSX.Element;
|
|
732
|
+
|
|
733
|
+
type PropertyGalleryHotspot = {
|
|
734
|
+
id: number;
|
|
735
|
+
x: number;
|
|
736
|
+
y: number;
|
|
737
|
+
title: string;
|
|
738
|
+
description: string;
|
|
739
|
+
};
|
|
740
|
+
type PropertyGalleryImage = {
|
|
741
|
+
src: string;
|
|
742
|
+
alt: string;
|
|
743
|
+
label: string;
|
|
744
|
+
hotspots?: PropertyGalleryHotspot[];
|
|
745
|
+
};
|
|
746
|
+
type PropertyPhotoGalleryProps = {
|
|
747
|
+
isOpen: boolean;
|
|
748
|
+
onClose: () => void;
|
|
749
|
+
startIndex?: number;
|
|
750
|
+
images?: PropertyGalleryImage[];
|
|
751
|
+
title?: string;
|
|
752
|
+
subtitle?: string;
|
|
753
|
+
};
|
|
754
|
+
declare function PropertyPhotoGallery({ isOpen, onClose, startIndex, title, subtitle, images, }: PropertyPhotoGalleryProps): react_jsx_runtime.JSX.Element | null;
|
|
755
|
+
|
|
756
|
+
export { Badge, type BadgeProps, Button, type ButtonProps, Card, CardContent, type CardContentProps, CardDescription, type CardDescriptionProps, CardFooter, type CardFooterProps, CardHeader, type CardHeaderProps, type CardProps, CardTitle, type CardTitleProps, type FundWalletParams, Header, type HeaderProps, type HousePositionOrderbook, type HousePositionPendingOrder, HousePositionSlider, HousePositionSliderMobile, type HousePositionSliderMobileOrderPayload, type HousePositionSliderMobileOrderbook, type HousePositionSliderMobileProps, type HousePositionSliderOrderPayload, type HousePositionSliderProps, type InspectionSlot, LoafLiquidityBadge, LoafLiquidityLogo, type LoafLiquidityLogoProps, LoginPopup, type LoginPopupProps, MobileTradeNav, type MobileTradeNavItem, type MobileTradeNavProps, type OfferStatus, Orderbook, type OrderbookLevel, type OrderbookProps, type OrderbookSide, type OrderbookTrade, OwnerBooking, type OwnerBookingProps, PaymentPopup, type PaymentPopupProps, PortfolioSummary, type PortfolioSummaryProps, PriceChart, type PriceChartCandle, type PriceChartProps, type PriceChartRange, type PropertyAddressOption, PropertyBuy, PropertyCompareBar, type PropertyCompareBarProps, PropertyDocuments, type PropertyGalleryHotspot, type PropertyGalleryImage, PropertyHeroHeader, type PropertyHeroHeaderProps, PropertyHistory, PropertyInspectionTimes, type PropertyNewsItem, type PropertyNewsType, PropertyNewsUpdates, type PropertyNewsUpdatesProps, type PropertyOffer, PropertyOffers, type PropertyOffersProps, PropertyOverview, type PropertyOverviewProps, PropertyPhotoGallery, type PropertyPriceSummary, PropertySubheader, type PropertySubheaderAction, type PropertySubheaderProps, type PropertySubheaderTab, PropertyTour, type PropertyTourProps, PropertyValuation, type PropertyValuationProps, type PropertyValueSummary, TradeConfirmationModal, type TradeConfirmationModalDetails, type TradeConfirmationModalProps, TradingSlider, type TradingSliderProps, type ValuationHistoryPoint, type ValuationRecentSale, type ValuationSummary, type YourOrder, type YourOrderSide, YourOrders, type YourOrdersProps, badgeVariants, buttonVariants };
|
package/dist/index.d.ts
CHANGED
|
@@ -412,12 +412,76 @@ declare const PropertyHeroHeader: React.ForwardRefExoticComponent<React.HTMLAttr
|
|
|
412
412
|
onMakeOffer?: () => void;
|
|
413
413
|
} & React.RefAttributes<HTMLDivElement>>;
|
|
414
414
|
|
|
415
|
+
type EmailCodeParams = {
|
|
416
|
+
email: string;
|
|
417
|
+
isSignUp: boolean;
|
|
418
|
+
handle?: string | null;
|
|
419
|
+
};
|
|
420
|
+
type VerifyCodeParams = {
|
|
421
|
+
code: string;
|
|
422
|
+
email: string;
|
|
423
|
+
};
|
|
424
|
+
type DemoLoginResult = {
|
|
425
|
+
success: boolean;
|
|
426
|
+
};
|
|
427
|
+
type DemoLoginHandler = (email: string, handle?: string | null) => Promise<DemoLoginResult | void> | DemoLoginResult | void;
|
|
428
|
+
type LoginPopupView = "main" | "email" | "otp" | "kyc" | "kyc-success" | "kyc-failed" | "funding";
|
|
429
|
+
type FundWalletParams = {
|
|
430
|
+
amount: string;
|
|
431
|
+
};
|
|
432
|
+
type LoginPopupProps = {
|
|
433
|
+
onClose: () => void;
|
|
434
|
+
onOpenEarlyAccess?: () => void;
|
|
435
|
+
/**
|
|
436
|
+
* Optional flag that indicates an authenticated session exists. When true (and autoCloseOnAuth is enabled)
|
|
437
|
+
* the popup will close automatically, mirroring the loaf-demo behaviour that watched Privy + demo auth state.
|
|
438
|
+
*/
|
|
439
|
+
isAuthenticated?: boolean;
|
|
440
|
+
/** Optional user payload that, when truthy, also triggers the auto close effect. */
|
|
441
|
+
currentUser?: unknown;
|
|
442
|
+
/**
|
|
443
|
+
* Handler that should kick off an email OTP flow (e.g. Privy's sendCode). When omitted, the component will
|
|
444
|
+
* display an inline error explaining that email auth is unavailable.
|
|
445
|
+
*/
|
|
446
|
+
onSendEmailCode?: (params: EmailCodeParams) => Promise<void> | void;
|
|
447
|
+
/** Handler invoked when the user submits the 6-digit OTP code. */
|
|
448
|
+
onVerifyEmailCode?: (params: VerifyCodeParams) => Promise<void> | void;
|
|
449
|
+
/** Optional handler used for demo / local login flows before falling back to email OTP. */
|
|
450
|
+
onDemoLogin?: DemoLoginHandler;
|
|
451
|
+
/** Override for the logo shown in the popup header. */
|
|
452
|
+
logoSrc?: string;
|
|
453
|
+
logoAlt?: string;
|
|
454
|
+
/** Disable auto-closing behaviour tied to isAuthenticated/currentUser flags. */
|
|
455
|
+
autoCloseOnAuth?: boolean;
|
|
456
|
+
/**
|
|
457
|
+
* Handler called when the user clicks "KYC me now". Should trigger the KYC verification flow
|
|
458
|
+
* and resolve with { passed: boolean } when complete.
|
|
459
|
+
*/
|
|
460
|
+
onKycStart?: () => Promise<{
|
|
461
|
+
passed: boolean;
|
|
462
|
+
}> | void;
|
|
463
|
+
/**
|
|
464
|
+
* Handler called when the user clicks "Fund my account". Should open the funding UI (e.g. Coinbase onramp)
|
|
465
|
+
* and resolve with { funded: boolean } when the user exits.
|
|
466
|
+
*/
|
|
467
|
+
onFundWallet?: (params: FundWalletParams) => Promise<{
|
|
468
|
+
funded: boolean;
|
|
469
|
+
}> | void;
|
|
470
|
+
/** Optional view to show immediately when the popup opens. */
|
|
471
|
+
initialView?: LoginPopupView;
|
|
472
|
+
};
|
|
473
|
+
declare const LoginPopup: React__default.FC<LoginPopupProps>;
|
|
474
|
+
|
|
415
475
|
type HeaderUser = {
|
|
416
476
|
displayName?: string | null;
|
|
417
477
|
email?: string | null;
|
|
418
478
|
walletAddress?: string | null;
|
|
419
479
|
};
|
|
420
480
|
type HeaderActiveTab = "home" | "trade" | "offerings" | "propertyMap" | "about";
|
|
481
|
+
type HeaderLoginPopupComponentProps = {
|
|
482
|
+
onClose: () => void;
|
|
483
|
+
initialView?: LoginPopupView;
|
|
484
|
+
};
|
|
421
485
|
type HeaderProps = {
|
|
422
486
|
currentUser?: HeaderUser | null;
|
|
423
487
|
isAuthenticated?: boolean;
|
|
@@ -426,9 +490,7 @@ type HeaderProps = {
|
|
|
426
490
|
onNavigate?: (path: string) => void;
|
|
427
491
|
onLogout?: () => Promise<void> | void;
|
|
428
492
|
onSignInClick?: () => void;
|
|
429
|
-
loginPopupComponent?: React__default.ComponentType<
|
|
430
|
-
onClose: () => void;
|
|
431
|
-
}>;
|
|
493
|
+
loginPopupComponent?: React__default.ComponentType<HeaderLoginPopupComponentProps>;
|
|
432
494
|
tradeUrl?: string;
|
|
433
495
|
tradePath?: string;
|
|
434
496
|
homePath?: string;
|
|
@@ -480,46 +542,6 @@ declare const PropertySubheader: React.ForwardRefExoticComponent<React.HTMLAttri
|
|
|
480
542
|
actions?: PropertySubheaderAction[];
|
|
481
543
|
} & React.RefAttributes<HTMLDivElement>>;
|
|
482
544
|
|
|
483
|
-
type EmailCodeParams = {
|
|
484
|
-
email: string;
|
|
485
|
-
isSignUp: boolean;
|
|
486
|
-
handle?: string | null;
|
|
487
|
-
};
|
|
488
|
-
type VerifyCodeParams = {
|
|
489
|
-
code: string;
|
|
490
|
-
email: string;
|
|
491
|
-
};
|
|
492
|
-
type DemoLoginResult = {
|
|
493
|
-
success: boolean;
|
|
494
|
-
};
|
|
495
|
-
type DemoLoginHandler = (email: string, handle?: string | null) => Promise<DemoLoginResult | void> | DemoLoginResult | void;
|
|
496
|
-
type LoginPopupProps = {
|
|
497
|
-
onClose: () => void;
|
|
498
|
-
onOpenEarlyAccess?: () => void;
|
|
499
|
-
/**
|
|
500
|
-
* Optional flag that indicates an authenticated session exists. When true (and autoCloseOnAuth is enabled)
|
|
501
|
-
* the popup will close automatically, mirroring the loaf-demo behaviour that watched Privy + demo auth state.
|
|
502
|
-
*/
|
|
503
|
-
isAuthenticated?: boolean;
|
|
504
|
-
/** Optional user payload that, when truthy, also triggers the auto close effect. */
|
|
505
|
-
currentUser?: unknown;
|
|
506
|
-
/**
|
|
507
|
-
* Handler that should kick off an email OTP flow (e.g. Privy's sendCode). When omitted, the component will
|
|
508
|
-
* display an inline error explaining that email auth is unavailable.
|
|
509
|
-
*/
|
|
510
|
-
onSendEmailCode?: (params: EmailCodeParams) => Promise<void> | void;
|
|
511
|
-
/** Handler invoked when the user submits the 6-digit OTP code. */
|
|
512
|
-
onVerifyEmailCode?: (params: VerifyCodeParams) => Promise<void> | void;
|
|
513
|
-
/** Optional handler used for demo / local login flows before falling back to email OTP. */
|
|
514
|
-
onDemoLogin?: DemoLoginHandler;
|
|
515
|
-
/** Override for the logo shown in the popup header. */
|
|
516
|
-
logoSrc?: string;
|
|
517
|
-
logoAlt?: string;
|
|
518
|
-
/** Disable auto-closing behaviour tied to isAuthenticated/currentUser flags. */
|
|
519
|
-
autoCloseOnAuth?: boolean;
|
|
520
|
-
};
|
|
521
|
-
declare const LoginPopup: React__default.FC<LoginPopupProps>;
|
|
522
|
-
|
|
523
545
|
type PropertyAddressOption = {
|
|
524
546
|
id: string;
|
|
525
547
|
label: string;
|
|
@@ -556,4 +578,179 @@ declare const PropertyCompareBar: React.ForwardRefExoticComponent<React.HTMLAttr
|
|
|
556
578
|
price?: PropertyPriceSummary;
|
|
557
579
|
} & React.RefAttributes<HTMLDivElement>>;
|
|
558
580
|
|
|
559
|
-
|
|
581
|
+
type PropertyOverviewProps = {
|
|
582
|
+
propertyName: string;
|
|
583
|
+
location: string;
|
|
584
|
+
midPrice: number;
|
|
585
|
+
onTradeClick?: () => void;
|
|
586
|
+
};
|
|
587
|
+
declare function PropertyOverview({ propertyName: _propertyName, location: _location, midPrice: _midPrice, onTradeClick: _onTradeClick }: PropertyOverviewProps): react_jsx_runtime.JSX.Element;
|
|
588
|
+
|
|
589
|
+
type OfferStatus = 'active' | 'rejected' | 'expired' | 'historical' | 'pending';
|
|
590
|
+
type PropertyOffer = {
|
|
591
|
+
id: number;
|
|
592
|
+
price: string;
|
|
593
|
+
buyer: string;
|
|
594
|
+
date: string;
|
|
595
|
+
expiry: string;
|
|
596
|
+
status: OfferStatus;
|
|
597
|
+
conditions: string;
|
|
598
|
+
};
|
|
599
|
+
type PropertyOffersProps = {
|
|
600
|
+
offers: PropertyOffer[];
|
|
601
|
+
};
|
|
602
|
+
declare function PropertyOffers({ offers }: PropertyOffersProps): react_jsx_runtime.JSX.Element;
|
|
603
|
+
|
|
604
|
+
declare function PropertyHistory(): react_jsx_runtime.JSX.Element;
|
|
605
|
+
|
|
606
|
+
declare function PropertyDocuments(): react_jsx_runtime.JSX.Element;
|
|
607
|
+
|
|
608
|
+
type InspectionSlot = {
|
|
609
|
+
slotId: string;
|
|
610
|
+
label: string;
|
|
611
|
+
date: string;
|
|
612
|
+
startTime: string;
|
|
613
|
+
endTime: string;
|
|
614
|
+
totalCapacity: number;
|
|
615
|
+
spotsRemaining: number;
|
|
616
|
+
};
|
|
617
|
+
type PropertyInspectionTimesProps = {
|
|
618
|
+
isAuthenticated: boolean;
|
|
619
|
+
slots: InspectionSlot[];
|
|
620
|
+
loading?: boolean;
|
|
621
|
+
error?: string | null;
|
|
622
|
+
bookingSlotId?: string | null;
|
|
623
|
+
bookingStatus?: string | null;
|
|
624
|
+
bookingError?: string | null;
|
|
625
|
+
onBook: (slot: InspectionSlot) => void;
|
|
626
|
+
onRetry?: () => void;
|
|
627
|
+
onSignIn?: () => void;
|
|
628
|
+
};
|
|
629
|
+
declare function PropertyInspectionTimes({ isAuthenticated, slots, loading, error, bookingSlotId, bookingStatus, bookingError, onBook, onRetry, onSignIn, }: PropertyInspectionTimesProps): react_jsx_runtime.JSX.Element;
|
|
630
|
+
|
|
631
|
+
type SaleData = {
|
|
632
|
+
state: {
|
|
633
|
+
status: number;
|
|
634
|
+
totalSold: bigint;
|
|
635
|
+
totalRaised: bigint;
|
|
636
|
+
totalFees: bigint;
|
|
637
|
+
propertyToken: `0x${string}`;
|
|
638
|
+
fundsWithdrawn: boolean;
|
|
639
|
+
} | null;
|
|
640
|
+
config: {
|
|
641
|
+
supplyToSell: bigint;
|
|
642
|
+
tokenPrice: bigint;
|
|
643
|
+
maxPerWallet: bigint;
|
|
644
|
+
feeBps: bigint;
|
|
645
|
+
paymentToken: `0x${string}`;
|
|
646
|
+
feeRecipient: `0x${string}`;
|
|
647
|
+
fundsRecipient: `0x${string}`;
|
|
648
|
+
} | null;
|
|
649
|
+
loading: boolean;
|
|
650
|
+
error: string | null;
|
|
651
|
+
totalSold: number;
|
|
652
|
+
supplyToSell: number;
|
|
653
|
+
percentSold: number;
|
|
654
|
+
statusLabel: string;
|
|
655
|
+
tokenPrice: number;
|
|
656
|
+
feePercent: number;
|
|
657
|
+
offeringValuation: number;
|
|
658
|
+
};
|
|
659
|
+
|
|
660
|
+
type PropertyBuyProps = {
|
|
661
|
+
propertyName?: string;
|
|
662
|
+
propertyLocation?: string;
|
|
663
|
+
isAuthenticated: boolean;
|
|
664
|
+
onSignIn: () => void;
|
|
665
|
+
saleData?: SaleData | null;
|
|
666
|
+
};
|
|
667
|
+
declare function PropertyBuy({ propertyName, propertyLocation: propertyLocationLabel, isAuthenticated, onSignIn, saleData, }: PropertyBuyProps): react_jsx_runtime.JSX.Element;
|
|
668
|
+
|
|
669
|
+
type OwnerBookingProps = {
|
|
670
|
+
propertyName?: string | null;
|
|
671
|
+
token: {
|
|
672
|
+
price?: number | null;
|
|
673
|
+
};
|
|
674
|
+
};
|
|
675
|
+
declare const OwnerBooking: ({ propertyName, token }: OwnerBookingProps) => react_jsx_runtime.JSX.Element;
|
|
676
|
+
|
|
677
|
+
type PaymentPopupProps = {
|
|
678
|
+
isOpen: boolean;
|
|
679
|
+
onClose: () => void;
|
|
680
|
+
onConfirm: (method: string) => void;
|
|
681
|
+
selectedDates: Date[];
|
|
682
|
+
totalCost: number;
|
|
683
|
+
isOwnerRate: boolean;
|
|
684
|
+
tokenPrice: number;
|
|
685
|
+
ownerRate: number;
|
|
686
|
+
marketRate: number;
|
|
687
|
+
userTokenHoldings: number;
|
|
688
|
+
propertyName: string;
|
|
689
|
+
};
|
|
690
|
+
declare function PaymentPopup({ isOpen, onClose, onConfirm, selectedDates, totalCost, isOwnerRate, tokenPrice, ownerRate, marketRate, userTokenHoldings, propertyName, }: PaymentPopupProps): react_jsx_runtime.JSX.Element | null;
|
|
691
|
+
|
|
692
|
+
type ValuationRecentSale = {
|
|
693
|
+
readonly imageUrl?: string;
|
|
694
|
+
readonly price?: number | null;
|
|
695
|
+
readonly currency?: string | null;
|
|
696
|
+
readonly saleDate?: string | null;
|
|
697
|
+
readonly address?: string | null;
|
|
698
|
+
readonly suburb?: string | null;
|
|
699
|
+
readonly bedrooms?: number | null;
|
|
700
|
+
readonly bathrooms?: number | null;
|
|
701
|
+
readonly landSize?: string | null;
|
|
702
|
+
};
|
|
703
|
+
type ValuationSummary = {
|
|
704
|
+
readonly propertyId?: number;
|
|
705
|
+
readonly lastPrice?: number | null;
|
|
706
|
+
readonly fairValue?: number | null;
|
|
707
|
+
readonly totalTokens?: number | null;
|
|
708
|
+
readonly confidence?: string | null;
|
|
709
|
+
readonly undervaluedThreshold?: number | null;
|
|
710
|
+
readonly overvaluedThreshold?: number | null;
|
|
711
|
+
readonly valuationDeltaPercent?: number | null;
|
|
712
|
+
readonly valuationStatus?: string | null;
|
|
713
|
+
readonly areaDemand?: string | null;
|
|
714
|
+
readonly propertyMoat?: string | null;
|
|
715
|
+
readonly recentSales?: ValuationRecentSale[];
|
|
716
|
+
};
|
|
717
|
+
type ValuationHistoryPoint = {
|
|
718
|
+
readonly timestamp: number;
|
|
719
|
+
readonly valuation: number;
|
|
720
|
+
readonly fairValue?: number | null;
|
|
721
|
+
};
|
|
722
|
+
type PropertyValuationProps = {
|
|
723
|
+
propertyName: string;
|
|
724
|
+
tokenPrice: number;
|
|
725
|
+
totalTokens?: number | null;
|
|
726
|
+
summary?: ValuationSummary | null;
|
|
727
|
+
history?: ValuationHistoryPoint[];
|
|
728
|
+
loading?: boolean;
|
|
729
|
+
error?: string | null;
|
|
730
|
+
};
|
|
731
|
+
declare function PropertyValuation({ propertyName, tokenPrice, totalTokens, summary, history, loading, error, }: PropertyValuationProps): react_jsx_runtime.JSX.Element;
|
|
732
|
+
|
|
733
|
+
type PropertyGalleryHotspot = {
|
|
734
|
+
id: number;
|
|
735
|
+
x: number;
|
|
736
|
+
y: number;
|
|
737
|
+
title: string;
|
|
738
|
+
description: string;
|
|
739
|
+
};
|
|
740
|
+
type PropertyGalleryImage = {
|
|
741
|
+
src: string;
|
|
742
|
+
alt: string;
|
|
743
|
+
label: string;
|
|
744
|
+
hotspots?: PropertyGalleryHotspot[];
|
|
745
|
+
};
|
|
746
|
+
type PropertyPhotoGalleryProps = {
|
|
747
|
+
isOpen: boolean;
|
|
748
|
+
onClose: () => void;
|
|
749
|
+
startIndex?: number;
|
|
750
|
+
images?: PropertyGalleryImage[];
|
|
751
|
+
title?: string;
|
|
752
|
+
subtitle?: string;
|
|
753
|
+
};
|
|
754
|
+
declare function PropertyPhotoGallery({ isOpen, onClose, startIndex, title, subtitle, images, }: PropertyPhotoGalleryProps): react_jsx_runtime.JSX.Element | null;
|
|
755
|
+
|
|
756
|
+
export { Badge, type BadgeProps, Button, type ButtonProps, Card, CardContent, type CardContentProps, CardDescription, type CardDescriptionProps, CardFooter, type CardFooterProps, CardHeader, type CardHeaderProps, type CardProps, CardTitle, type CardTitleProps, type FundWalletParams, Header, type HeaderProps, type HousePositionOrderbook, type HousePositionPendingOrder, HousePositionSlider, HousePositionSliderMobile, type HousePositionSliderMobileOrderPayload, type HousePositionSliderMobileOrderbook, type HousePositionSliderMobileProps, type HousePositionSliderOrderPayload, type HousePositionSliderProps, type InspectionSlot, LoafLiquidityBadge, LoafLiquidityLogo, type LoafLiquidityLogoProps, LoginPopup, type LoginPopupProps, MobileTradeNav, type MobileTradeNavItem, type MobileTradeNavProps, type OfferStatus, Orderbook, type OrderbookLevel, type OrderbookProps, type OrderbookSide, type OrderbookTrade, OwnerBooking, type OwnerBookingProps, PaymentPopup, type PaymentPopupProps, PortfolioSummary, type PortfolioSummaryProps, PriceChart, type PriceChartCandle, type PriceChartProps, type PriceChartRange, type PropertyAddressOption, PropertyBuy, PropertyCompareBar, type PropertyCompareBarProps, PropertyDocuments, type PropertyGalleryHotspot, type PropertyGalleryImage, PropertyHeroHeader, type PropertyHeroHeaderProps, PropertyHistory, PropertyInspectionTimes, type PropertyNewsItem, type PropertyNewsType, PropertyNewsUpdates, type PropertyNewsUpdatesProps, type PropertyOffer, PropertyOffers, type PropertyOffersProps, PropertyOverview, type PropertyOverviewProps, PropertyPhotoGallery, type PropertyPriceSummary, PropertySubheader, type PropertySubheaderAction, type PropertySubheaderProps, type PropertySubheaderTab, PropertyTour, type PropertyTourProps, PropertyValuation, type PropertyValuationProps, type PropertyValueSummary, TradeConfirmationModal, type TradeConfirmationModalDetails, type TradeConfirmationModalProps, TradingSlider, type TradingSliderProps, type ValuationHistoryPoint, type ValuationRecentSale, type ValuationSummary, type YourOrder, type YourOrderSide, YourOrders, type YourOrdersProps, badgeVariants, buttonVariants };
|