@loafmarkets/ui 0.1.384 → 0.1.385

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 CHANGED
@@ -83,6 +83,8 @@ interface OrderbookProps extends React$1.HTMLAttributes<HTMLDivElement> {
83
83
  amountPrecision?: number;
84
84
  defaultTab?: "orderbook" | "trades";
85
85
  onTabChange?: (tab: "orderbook" | "trades") => void;
86
+ /** When false, the "Trades" tab is hidden and only the orderbook shows (e.g. on mobile). Default true. */
87
+ showTradesTab?: boolean;
86
88
  rightHeader?: React$1.ReactNode;
87
89
  variant?: "auto" | "default" | "compact";
88
90
  /**
@@ -578,10 +580,29 @@ type LoginPopupProps = {
578
580
  onFundWallet?: (params: FundWalletParams) => Promise<FundWalletResult> | void;
579
581
  /** Optional view to show immediately when the popup opens. */
580
582
  initialView?: LoginPopupView;
583
+ /**
584
+ * Gate-only: an access code supplied out-of-band (e.g. the `?code=` param on an
585
+ * invite link). Any form is accepted ("LOAF-M8TRP" / "loaf-m8trp" / "M8TRP").
586
+ * Pre-fills the code field and, when complete, auto-validates on open so the
587
+ * gate advances straight to sign-in.
588
+ */
589
+ initialCode?: string;
581
590
  /** Wallet address used for the receive funds view (bypasses Privy modal). */
582
591
  walletAddress?: string | null;
583
592
  /** Called when the user submits a referral code during onboarding. */
584
593
  onSubmitReferralCode?: (code: string) => Promise<void> | void;
594
+ /**
595
+ * Gate-only: validates the full access code (e.g. "LOAF-M8TRP") as the user types.
596
+ * Resolve true → bar turns green and the sign-in step is revealed; false → red.
597
+ */
598
+ onValidateCode?: (code: string) => Promise<boolean> | boolean;
599
+ /**
600
+ * Gate-only: after auth on the "Already have an account?" sign-in path (no
601
+ * code entered), reports whether the account ALREADY has access. True → enter;
602
+ * false → routed back to the access-code step (a code-less account must not
603
+ * bypass the gate). Defaults to allowing entry if not provided.
604
+ */
605
+ onCheckAccess?: () => Promise<boolean> | boolean;
585
606
  /** Called when the user skips the referral code and joins the waitlist. Receives their signup email. Resolves to a success message. */
586
607
  onJoinWaitlist?: (email: string) => Promise<string> | void;
587
608
  /**
@@ -600,6 +621,12 @@ type LoginPopupProps = {
600
621
  onPasskeyLogin?: () => Promise<void> | void;
601
622
  /** Current KYC status — used to show "Resume Verification" when previously started. */
602
623
  kycStatus?: 'NOT_STARTED' | 'PENDING' | 'ON_HOLD' | 'VERIFIED' | 'REJECTED';
624
+ /**
625
+ * Renders the access-code (referral) view as a full-screen, opaque, non-dismissible
626
+ * gate — no page visible behind it, no close affordance. Used when the popup opens
627
+ * directly into the code view as the private-beta entry gate.
628
+ */
629
+ gate?: boolean;
603
630
  };
604
631
  declare const LoginPopup: React__default.FC<LoginPopupProps>;
605
632
 
@@ -1021,8 +1048,10 @@ type AssetSelectorBarProps = {
1021
1048
  trailing?: ReactNode;
1022
1049
  imageUrl?: string;
1023
1050
  badgeLabel?: string;
1051
+ /** Stack the TICKER as the primary label with the asset name beneath (InstrumentTile-style), instead of "Name (TICKER)". */
1052
+ tickerPrimary?: boolean;
1024
1053
  };
1025
- declare function AssetSelectorBar({ propertyName, tokenPrice, offeringValuation, metrics: metricsProp, currentTokenName, selectorItems, onSelect, trailing, imageUrl, badgeLabel, }: AssetSelectorBarProps): react_jsx_runtime.JSX.Element;
1054
+ declare function AssetSelectorBar({ propertyName, tokenPrice, offeringValuation, metrics: metricsProp, currentTokenName, selectorItems, onSelect, trailing, imageUrl, badgeLabel, tickerPrimary, }: AssetSelectorBarProps): react_jsx_runtime.JSX.Element;
1026
1055
 
1027
1056
  type ToastVariant = 'success' | 'error' | 'info' | 'pending' | 'sell';
1028
1057
  type ToastData = {
package/dist/index.d.ts CHANGED
@@ -83,6 +83,8 @@ interface OrderbookProps extends React$1.HTMLAttributes<HTMLDivElement> {
83
83
  amountPrecision?: number;
84
84
  defaultTab?: "orderbook" | "trades";
85
85
  onTabChange?: (tab: "orderbook" | "trades") => void;
86
+ /** When false, the "Trades" tab is hidden and only the orderbook shows (e.g. on mobile). Default true. */
87
+ showTradesTab?: boolean;
86
88
  rightHeader?: React$1.ReactNode;
87
89
  variant?: "auto" | "default" | "compact";
88
90
  /**
@@ -578,10 +580,29 @@ type LoginPopupProps = {
578
580
  onFundWallet?: (params: FundWalletParams) => Promise<FundWalletResult> | void;
579
581
  /** Optional view to show immediately when the popup opens. */
580
582
  initialView?: LoginPopupView;
583
+ /**
584
+ * Gate-only: an access code supplied out-of-band (e.g. the `?code=` param on an
585
+ * invite link). Any form is accepted ("LOAF-M8TRP" / "loaf-m8trp" / "M8TRP").
586
+ * Pre-fills the code field and, when complete, auto-validates on open so the
587
+ * gate advances straight to sign-in.
588
+ */
589
+ initialCode?: string;
581
590
  /** Wallet address used for the receive funds view (bypasses Privy modal). */
582
591
  walletAddress?: string | null;
583
592
  /** Called when the user submits a referral code during onboarding. */
584
593
  onSubmitReferralCode?: (code: string) => Promise<void> | void;
594
+ /**
595
+ * Gate-only: validates the full access code (e.g. "LOAF-M8TRP") as the user types.
596
+ * Resolve true → bar turns green and the sign-in step is revealed; false → red.
597
+ */
598
+ onValidateCode?: (code: string) => Promise<boolean> | boolean;
599
+ /**
600
+ * Gate-only: after auth on the "Already have an account?" sign-in path (no
601
+ * code entered), reports whether the account ALREADY has access. True → enter;
602
+ * false → routed back to the access-code step (a code-less account must not
603
+ * bypass the gate). Defaults to allowing entry if not provided.
604
+ */
605
+ onCheckAccess?: () => Promise<boolean> | boolean;
585
606
  /** Called when the user skips the referral code and joins the waitlist. Receives their signup email. Resolves to a success message. */
586
607
  onJoinWaitlist?: (email: string) => Promise<string> | void;
587
608
  /**
@@ -600,6 +621,12 @@ type LoginPopupProps = {
600
621
  onPasskeyLogin?: () => Promise<void> | void;
601
622
  /** Current KYC status — used to show "Resume Verification" when previously started. */
602
623
  kycStatus?: 'NOT_STARTED' | 'PENDING' | 'ON_HOLD' | 'VERIFIED' | 'REJECTED';
624
+ /**
625
+ * Renders the access-code (referral) view as a full-screen, opaque, non-dismissible
626
+ * gate — no page visible behind it, no close affordance. Used when the popup opens
627
+ * directly into the code view as the private-beta entry gate.
628
+ */
629
+ gate?: boolean;
603
630
  };
604
631
  declare const LoginPopup: React__default.FC<LoginPopupProps>;
605
632
 
@@ -1021,8 +1048,10 @@ type AssetSelectorBarProps = {
1021
1048
  trailing?: ReactNode;
1022
1049
  imageUrl?: string;
1023
1050
  badgeLabel?: string;
1051
+ /** Stack the TICKER as the primary label with the asset name beneath (InstrumentTile-style), instead of "Name (TICKER)". */
1052
+ tickerPrimary?: boolean;
1024
1053
  };
1025
- declare function AssetSelectorBar({ propertyName, tokenPrice, offeringValuation, metrics: metricsProp, currentTokenName, selectorItems, onSelect, trailing, imageUrl, badgeLabel, }: AssetSelectorBarProps): react_jsx_runtime.JSX.Element;
1054
+ declare function AssetSelectorBar({ propertyName, tokenPrice, offeringValuation, metrics: metricsProp, currentTokenName, selectorItems, onSelect, trailing, imageUrl, badgeLabel, tickerPrimary, }: AssetSelectorBarProps): react_jsx_runtime.JSX.Element;
1026
1055
 
1027
1056
  type ToastVariant = 'success' | 'error' | 'info' | 'pending' | 'sell';
1028
1057
  type ToastData = {