@liberfi.io/ui-predict 0.1.95 → 0.1.96

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
@@ -1,6 +1,6 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import { EventSortField, ProviderSource, PredictEvent, PredictMarket, TagSlugSelection as TagSlugSelection$1, EventStatus, ResolveEventsParamsInput, ChartRangeType as ChartRangeType$1, ListCandlesticksParams, Candlestick, PredictPage, MatchSortField, MatchGroup, PredictPosition } from '@liberfi.io/react-predict';
3
- export { BalanceResponse, CancelOrderResult, Candlestick, CreateOrderInput, DFlowKYCStatus, DFlowOrderContext, DFlowQuoteRequest, DFlowQuoteResponse, DFlowSubmitRequest, DFlowSubmitResponse, EventSortField, EventStatus, EventSummary, ListCandlesticksParams, ListEventsParams, ListMarketTradesParams, ListOrdersParams, ListTradesParams, MarketOutcome, MarketResult, MarketStatus, MarketSummary, MatchGroup, MatchGroupEntry, MatchGroupMarket, MatchGroupPage, MatchSortField, MatchStatus, MatchesParams, MatchesStats, OrderSide, OrderStatus, Orderbook, OrderbookLevel, PolymarketOrderType, PositionsResponse, PredictClient, PredictContext, PredictContextValue, PredictEvent, PredictMarket, PredictOrder, PredictPage, PredictPosition, PredictProvider, PredictProviderProps, PredictTag, PredictTrade, PredictWsClient, PriceHistoryRange, PriceHistoryResponse, PricePoint, ProviderMeta, ProviderSource, ResolveEventsParamsInput, SettlementSource, SimilarEventsParams, TradeType, createPredictClient, createPredictWsClient, fetchMatchesPage, matchQueryKey, matchesQueryKey, useBalance, useCancelOrder, useCandlesticks, useDFlowKYC, useDFlowQuote, useDFlowSubmit, useEvent, useEvents, useInfiniteEvents, useInfiniteMatches, useInfiniteOrders, useInfiniteTrades, useMarket, useMarketHistory, useMarketTrades, useMatch, useOrder, useOrderbook, useOrders, usePositions, usePredictClient, usePriceHistory, useSearchEvents, useSimilarEvents, useTrades } from '@liberfi.io/react-predict';
2
+ import { EventSortField, ProviderSource, PredictEvent, PredictMarket, TagSlugSelection as TagSlugSelection$1, EventStatus, ResolveEventsParamsInput, ChartRangeType as ChartRangeType$1, ListCandlesticksParams, Candlestick, PredictPage, MatchMarketFlat, MatchSortField, MatchGroup, PredictPosition } from '@liberfi.io/react-predict';
3
+ export { BalanceResponse, CancelOrderResult, Candlestick, CreateOrderInput, DFlowKYCStatus, DFlowOrderContext, DFlowQuoteRequest, DFlowQuoteResponse, DFlowSubmitRequest, DFlowSubmitResponse, EventSortField, EventStatus, EventSummary, ListCandlesticksParams, ListEventsParams, ListMarketTradesParams, ListOrdersParams, ListTradesParams, MarketOutcome, MarketResult, MarketStatus, MarketSummary, MatchConfidenceTier, MatchGroup, MatchGroupEntry, MatchGroupMarket, MatchGroupPage, MatchMarketFlat, MatchMarketPage, MatchMarketParams, MatchSortField, MatchStatus, MatchesParams, MatchesStats, OrderSide, OrderStatus, Orderbook, OrderbookLevel, PolymarketOrderType, PositionsResponse, PredictClient, PredictContext, PredictContextValue, PredictEvent, PredictMarket, PredictOrder, PredictPage, PredictPosition, PredictProvider, PredictProviderProps, PredictTag, PredictTrade, PredictWsClient, PriceHistoryRange, PriceHistoryResponse, PricePoint, ProviderMeta, ProviderSource, ResolveEventsParamsInput, SettlementSource, SimilarEventsParams, TradeType, createPredictClient, createPredictWsClient, fetchMatchMarketsPage, fetchMatchesPage, matchMarketsQueryKey, matchQueryKey, matchesQueryKey, useBalance, useCancelOrder, useCandlesticks, useDFlowKYC, useDFlowQuote, useDFlowSubmit, useEvent, useEvents, useInfiniteEvents, useInfiniteMatchMarkets, useInfiniteMatches, useInfiniteOrders, useInfiniteTrades, useMarket, useMarketHistory, useMarketTrades, useMatch, useOrder, useOrderbook, useOrders, usePositions, usePredictClient, usePriceHistory, useSearchEvents, useSimilarEvents, useTrades } from '@liberfi.io/react-predict';
4
4
  import { LinkComponentType } from '@liberfi.io/ui';
5
5
  import * as _tanstack_react_query from '@tanstack/react-query';
6
6
  import * as react from 'react';
@@ -13,7 +13,7 @@ declare global {
13
13
  };
14
14
  }
15
15
  }
16
- declare const _default: "0.1.95";
16
+ declare const _default: "0.1.96";
17
17
 
18
18
  /**
19
19
  * A single category entry in the static navigation model.
@@ -411,6 +411,7 @@ type PredictTradeModalParams = {
411
411
  event: PredictEvent;
412
412
  market: PredictMarket;
413
413
  initialOutcome?: TradeOutcome;
414
+ initialSide?: TradeSide;
414
415
  chain?: string;
415
416
  };
416
417
  type PredictTradeModalResult = void;
@@ -652,13 +653,17 @@ type SearchWidgetProps = {
652
653
  declare function SearchWidget({ onKeywordChange, onSelectEvent, getEventHref, LinkComponent, onHover, onEscape, source, }: SearchWidgetProps): react_jsx_runtime.JSX.Element;
653
654
 
654
655
  interface MatchesPageProps {
655
- onSelectEntry?: (event: PredictEvent) => void;
656
- getEventHref?: (event: PredictEvent) => string;
656
+ onSelect?: (match: MatchMarketFlat, source: ProviderSource) => void;
657
+ getMarketHref?: (match: MatchMarketFlat, source: ProviderSource) => string | undefined;
657
658
  LinkComponent?: LinkComponentType;
658
659
  /** Path to the hero background image (e.g. "/matches-bg.webp") */
659
660
  bgImageSrc?: string;
661
+ /** @deprecated Use onSelect instead */
662
+ onSelectEntry?: (event: never) => void;
663
+ /** @deprecated Use getMarketHref instead */
664
+ getEventHref?: (event: never) => string;
660
665
  }
661
- declare function MatchesPage({ onSelectEntry, getEventHref, LinkComponent, bgImageSrc, }: MatchesPageProps): react_jsx_runtime.JSX.Element;
666
+ declare function MatchesPage({ onSelect, getMarketHref, LinkComponent, bgImageSrc, }: MatchesPageProps): react_jsx_runtime.JSX.Element;
662
667
 
663
668
  interface MatchesHeroStats {
664
669
  activePairs: number;
@@ -678,10 +683,14 @@ interface MatchesWidgetProps {
678
683
  sortBy: MatchSortField;
679
684
  sortAsc: boolean;
680
685
  minVolume?: number;
681
- onSelectEntry?: (event: PredictEvent) => void;
682
- getEventHref?: (event: PredictEvent) => string;
686
+ onSelect?: (match: MatchMarketFlat, source: ProviderSource) => void;
687
+ getMarketHref?: (match: MatchMarketFlat, source: ProviderSource) => string | undefined;
683
688
  LinkComponent?: LinkComponentType;
684
689
  onStatsChange?: (stats: MatchesHeroStats) => void;
690
+ /** @deprecated Use onSelect instead */
691
+ onSelectEntry?: (event: never) => void;
692
+ /** @deprecated Use getMarketHref instead */
693
+ getEventHref?: (event: never) => string;
685
694
  }
686
695
  declare const MatchesWidget: react.ForwardRefExoticComponent<MatchesWidgetProps & react.RefAttributes<MatchesWidgetRef>>;
687
696
 
@@ -693,6 +702,14 @@ interface MatchGroupCardProps {
693
702
  }
694
703
  declare function MatchGroupCard({ group, onSelectEntry, getEventHref, LinkComponent, }: MatchGroupCardProps): react_jsx_runtime.JSX.Element;
695
704
 
705
+ interface MatchMarketCardProps {
706
+ match: MatchMarketFlat;
707
+ onSelect?: (match: MatchMarketFlat, source: ProviderSource) => void;
708
+ getMarketHref?: (match: MatchMarketFlat, source: ProviderSource) => string | undefined;
709
+ LinkComponent?: LinkComponentType;
710
+ }
711
+ declare function MatchMarketCard({ match, onSelect, getMarketHref, LinkComponent, }: MatchMarketCardProps): react_jsx_runtime.JSX.Element;
712
+
696
713
  interface MatchesStatsBarProps {
697
714
  matches: MatchGroup[];
698
715
  total?: number;
@@ -743,6 +760,37 @@ interface ProfilePageProps {
743
760
  }
744
761
  declare function ProfilePage({ solanaAddress, evmAddress, onClosePosition, onEventClick, }: ProfilePageProps): react_jsx_runtime.JSX.Element;
745
762
 
763
+ interface KycModalProps {
764
+ isOpen: boolean;
765
+ onClose: () => void;
766
+ kycUrl: string | null;
767
+ }
768
+ declare function KycModal({ isOpen, onClose, kycUrl }: KycModalProps): react_jsx_runtime.JSX.Element;
769
+
770
+ interface SetupModalProps {
771
+ isOpen: boolean;
772
+ onClose: () => void;
773
+ evmAddress: string;
774
+ safeDeployed: boolean;
775
+ tokenApproved: boolean;
776
+ /**
777
+ * Whether Polymarket L2 API credentials are already derived.
778
+ * Comes from `PolymarketContext.credentials !== null`.
779
+ */
780
+ keysConnected: boolean;
781
+ /**
782
+ * Callback to deploy Safe + approve tokens (Steps 1-2).
783
+ * The consuming app provides the implementation using RelayClient.
784
+ */
785
+ onDeployAndApprove: () => Promise<void>;
786
+ /**
787
+ * Callback to trigger L2 key derivation (Step 3).
788
+ * Provided by the consuming app that has access to the wallet signer.
789
+ */
790
+ onConnectKeys?: () => Promise<void>;
791
+ }
792
+ declare function SetupModal({ isOpen, onClose, evmAddress, safeDeployed, tokenApproved, keysConnected, onDeployAndApprove, onConnectKeys, }: SetupModalProps): react_jsx_runtime.JSX.Element;
793
+
746
794
  /** Default page size for list queries */
747
795
  declare const DEFAULT_PAGE_SIZE = 48;
748
796
  /** Maximum number of markets to display in price history chart */
@@ -805,15 +853,34 @@ declare const DEFAULT_PRICE_HISTORY_INTERVAL: "1w";
805
853
  declare const PRICE_HISTORY_SAMPLE_INTERVAL: Record<PriceHistoryIntervalType, number>;
806
854
 
807
855
  interface PredictWalletContextValue {
808
- /** Connected Solana wallet address (for DFlow). */
856
+ /** Connected Solana wallet address (for Kalshi). */
809
857
  solanaAddress: string | undefined;
810
858
  /** Connected EVM wallet address (for Polymarket). */
811
859
  evmAddress: string | undefined;
860
+ /** Polymarket Safe (proxy) wallet address, derived from EOA via CREATE2. */
861
+ polymarketSafeAddress: string | undefined;
812
862
  /** `null` when no wallet is connected or data has not loaded yet. */
813
- dflowUsdcBalance: number | null;
814
- /** `null` when no wallet is connected or data has not loaded yet. */
863
+ kalshiUsdcBalance: number | null;
864
+ /** `null` when wallet not connected or setup not complete. */
815
865
  polymarketUsdcBalance: number | null;
866
+ /** Whether the Solana wallet has completed Kalshi/DFlow KYC verification. */
867
+ kalshiKycVerified: boolean;
868
+ /** URL to redirect for KYC onboarding, or `null` if unavailable. */
869
+ kalshiKycUrl: string | null;
870
+ /** `true` while the KYC status query is loading for the first time. */
871
+ kalshiKycLoading: boolean;
872
+ /** Whether Polymarket wallet setup is fully complete (Safe deployed + USDC.e approved). */
873
+ polymarketSetupVerified: boolean;
874
+ /** Whether the Safe wallet has been deployed on Polygon. */
875
+ polymarketSafeDeployed: boolean;
876
+ /** Whether USDC.e is approved for the CTF Exchange. */
877
+ polymarketTokenApproved: boolean;
878
+ /** `true` while the Polymarket setup status is loading. */
879
+ polymarketSetupLoading: boolean;
880
+ /** `true` only on initial load when there is no cached data yet. */
816
881
  isLoading: boolean;
882
+ /** `true` whenever a request is in-flight (including background refetches). */
883
+ isFetching: boolean;
817
884
  error: Error | null;
818
885
  }
819
886
  declare function usePredictWallet(): PredictWalletContextValue;
@@ -823,4 +890,4 @@ type PredictWalletProviderProps = PropsWithChildren<{
823
890
  }>;
824
891
  declare function PredictWalletProvider({ pollingInterval, enabled, children, }: PredictWalletProviderProps): react_jsx_runtime.JSX.Element;
825
892
 
826
- export { CHART_RANGE_DURATION, CHART_RANGE_PERIOD, CHART_RANGE_SAMPLE_INTERVAL, CandlestickPeriod, type CandlestickPeriodType, CategoriesSkeleton, CategoriesUI, type CategoriesUIProps, CategoriesWidget, type CategoriesWidgetProps, type CategoryItem, type CategoryListItem, type CategoryTagItem, ChartRange, type ChartRangeType, DEFAULT_CHART_RANGE, DEFAULT_FILTER_STATE, DEFAULT_PAGE_SIZE, DEFAULT_PRICE_HISTORY_INTERVAL, type DepthLevel, type DepthSlot, type DurationUnit, EventDetailPage, type EventDetailPageProps, EventDetailSkeleton, type EventDetailSkeletonProps, EventDetailUI, type EventDetailUIProps, EventDetailWidget, type EventDetailWidgetProps, EventItem, type EventItemProps, EventMarketDepthChartUI, type EventMarketDepthChartUIProps, EventMarketDetailWidget, type EventMarketDetailWidgetProps, EventPriceChart, type EventPriceChartProps, type EventsFilterState, EventsFilterUI, type EventsFilterUIProps, EventsPage, type EventsPageProps, EventsPageSkeleton, type EventsPageSkeletonProps, EventsSkeleton, type EventsSkeletonProps, EventsToolbarUI, type EventsToolbarUIProps, EventsUI, type EventsUIProps, EventsWidget, type EventsWidgetProps, type ExpirationPreset, MAX_PRICE_HISTORY_MARKETS, MatchGroupCard, type MatchGroupCardProps, MatchesFilterBar, type MatchesFilterBarProps, MatchesHero, type MatchesHeroProps, type MatchesHeroStats, MatchesPage, type MatchesPageProps, MatchesStatsBar, type MatchesStatsBarProps, MatchesWidget, type MatchesWidgetProps, type MatchesWidgetRef, ORDER_MAX_PRICE, ORDER_MIN_PRICE, ORDER_MIN_QUANTITY, ORDER_PRICE_STEP, type OrderType, PREDICT_SEARCH_MODAL_ID, PREDICT_TRADE_MODAL_ID, PRICE_HISTORY_SAMPLE_INTERVAL, PredictSearchModal, type PredictSearchModalParams, type PredictSearchModalResult, PredictTradeModal, type PredictTradeModalParams, type PredictTradeModalResult, type PredictWalletContextValue, PredictWalletProvider, type PredictWalletProviderProps, PriceHistoryInterval, type PriceHistoryIntervalType, ProfilePage, type ProfilePageProps, SORT_PRESETS, STATIC_CATEGORIES, SearchEventsButton, type SearchEventsButtonProps, SearchHistoryUI, type SearchHistoryUIProps, SearchHistoryWidget, type SearchHistoryWidgetProps, SearchInputUI, type SearchInputUIProps, SearchResultItemUI, type SearchResultItemUIProps, SearchResultListWidget, type SearchResultListWidgetProps, SearchWidget, type SearchWidgetProps, SimilarEventCard, type SimilarEventCardProps, SimilarEventsSection, type SimilarEventsSectionProps, type SortPreset, SourceBadge, type SourceBadgeProps, SpreadIndicator, type SpreadIndicatorProps, type TagItem, type TagSlugSelection, TradeFormSkeleton, TradeFormUI, type TradeFormUIProps, type TradeFormValidation, TradeFormWidget, type TradeFormWidgetProps, type TradeOutcome, type TradeSide, type UseEventDetailParams, type UseEventsInfiniteParams, type UseEventsInfiniteResult, type UseSearchResultListScriptParams, type UseSearchScriptParams, type UseTradeFormParams, type UseTradeFormResult, UserActivitySection, type UserActivitySectionProps, countActiveFilters, formatKMB, getSourceMeta, useEventDetail, useEventsInfinite, usePredictSearchHistory, usePredictWallet, useSearchResultListScript, useSearchScript, useTradeForm, _default as version };
893
+ export { CHART_RANGE_DURATION, CHART_RANGE_PERIOD, CHART_RANGE_SAMPLE_INTERVAL, CandlestickPeriod, type CandlestickPeriodType, CategoriesSkeleton, CategoriesUI, type CategoriesUIProps, CategoriesWidget, type CategoriesWidgetProps, type CategoryItem, type CategoryListItem, type CategoryTagItem, ChartRange, type ChartRangeType, DEFAULT_CHART_RANGE, DEFAULT_FILTER_STATE, DEFAULT_PAGE_SIZE, DEFAULT_PRICE_HISTORY_INTERVAL, type DepthLevel, type DepthSlot, type DurationUnit, EventDetailPage, type EventDetailPageProps, EventDetailSkeleton, type EventDetailSkeletonProps, EventDetailUI, type EventDetailUIProps, EventDetailWidget, type EventDetailWidgetProps, EventItem, type EventItemProps, EventMarketDepthChartUI, type EventMarketDepthChartUIProps, EventMarketDetailWidget, type EventMarketDetailWidgetProps, EventPriceChart, type EventPriceChartProps, type EventsFilterState, EventsFilterUI, type EventsFilterUIProps, EventsPage, type EventsPageProps, EventsPageSkeleton, type EventsPageSkeletonProps, EventsSkeleton, type EventsSkeletonProps, EventsToolbarUI, type EventsToolbarUIProps, EventsUI, type EventsUIProps, EventsWidget, type EventsWidgetProps, type ExpirationPreset, KycModal, type KycModalProps, MAX_PRICE_HISTORY_MARKETS, MatchGroupCard, type MatchGroupCardProps, MatchMarketCard, type MatchMarketCardProps, MatchesFilterBar, type MatchesFilterBarProps, MatchesHero, type MatchesHeroProps, type MatchesHeroStats, MatchesPage, type MatchesPageProps, MatchesStatsBar, type MatchesStatsBarProps, MatchesWidget, type MatchesWidgetProps, type MatchesWidgetRef, ORDER_MAX_PRICE, ORDER_MIN_PRICE, ORDER_MIN_QUANTITY, ORDER_PRICE_STEP, type OrderType, PREDICT_SEARCH_MODAL_ID, PREDICT_TRADE_MODAL_ID, PRICE_HISTORY_SAMPLE_INTERVAL, PredictSearchModal, type PredictSearchModalParams, type PredictSearchModalResult, PredictTradeModal, type PredictTradeModalParams, type PredictTradeModalResult, type PredictWalletContextValue, PredictWalletProvider, type PredictWalletProviderProps, PriceHistoryInterval, type PriceHistoryIntervalType, ProfilePage, type ProfilePageProps, SORT_PRESETS, STATIC_CATEGORIES, SearchEventsButton, type SearchEventsButtonProps, SearchHistoryUI, type SearchHistoryUIProps, SearchHistoryWidget, type SearchHistoryWidgetProps, SearchInputUI, type SearchInputUIProps, SearchResultItemUI, type SearchResultItemUIProps, SearchResultListWidget, type SearchResultListWidgetProps, SearchWidget, type SearchWidgetProps, SetupModal, type SetupModalProps, SimilarEventCard, type SimilarEventCardProps, SimilarEventsSection, type SimilarEventsSectionProps, type SortPreset, SourceBadge, type SourceBadgeProps, SpreadIndicator, type SpreadIndicatorProps, type TagItem, type TagSlugSelection, TradeFormSkeleton, TradeFormUI, type TradeFormUIProps, type TradeFormValidation, TradeFormWidget, type TradeFormWidgetProps, type TradeOutcome, type TradeSide, type UseEventDetailParams, type UseEventsInfiniteParams, type UseEventsInfiniteResult, type UseSearchResultListScriptParams, type UseSearchScriptParams, type UseTradeFormParams, type UseTradeFormResult, UserActivitySection, type UserActivitySectionProps, countActiveFilters, formatKMB, getSourceMeta, useEventDetail, useEventsInfinite, usePredictSearchHistory, usePredictWallet, useSearchResultListScript, useSearchScript, useTradeForm, _default as version };
package/dist/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import { EventSortField, ProviderSource, PredictEvent, PredictMarket, TagSlugSelection as TagSlugSelection$1, EventStatus, ResolveEventsParamsInput, ChartRangeType as ChartRangeType$1, ListCandlesticksParams, Candlestick, PredictPage, MatchSortField, MatchGroup, PredictPosition } from '@liberfi.io/react-predict';
3
- export { BalanceResponse, CancelOrderResult, Candlestick, CreateOrderInput, DFlowKYCStatus, DFlowOrderContext, DFlowQuoteRequest, DFlowQuoteResponse, DFlowSubmitRequest, DFlowSubmitResponse, EventSortField, EventStatus, EventSummary, ListCandlesticksParams, ListEventsParams, ListMarketTradesParams, ListOrdersParams, ListTradesParams, MarketOutcome, MarketResult, MarketStatus, MarketSummary, MatchGroup, MatchGroupEntry, MatchGroupMarket, MatchGroupPage, MatchSortField, MatchStatus, MatchesParams, MatchesStats, OrderSide, OrderStatus, Orderbook, OrderbookLevel, PolymarketOrderType, PositionsResponse, PredictClient, PredictContext, PredictContextValue, PredictEvent, PredictMarket, PredictOrder, PredictPage, PredictPosition, PredictProvider, PredictProviderProps, PredictTag, PredictTrade, PredictWsClient, PriceHistoryRange, PriceHistoryResponse, PricePoint, ProviderMeta, ProviderSource, ResolveEventsParamsInput, SettlementSource, SimilarEventsParams, TradeType, createPredictClient, createPredictWsClient, fetchMatchesPage, matchQueryKey, matchesQueryKey, useBalance, useCancelOrder, useCandlesticks, useDFlowKYC, useDFlowQuote, useDFlowSubmit, useEvent, useEvents, useInfiniteEvents, useInfiniteMatches, useInfiniteOrders, useInfiniteTrades, useMarket, useMarketHistory, useMarketTrades, useMatch, useOrder, useOrderbook, useOrders, usePositions, usePredictClient, usePriceHistory, useSearchEvents, useSimilarEvents, useTrades } from '@liberfi.io/react-predict';
2
+ import { EventSortField, ProviderSource, PredictEvent, PredictMarket, TagSlugSelection as TagSlugSelection$1, EventStatus, ResolveEventsParamsInput, ChartRangeType as ChartRangeType$1, ListCandlesticksParams, Candlestick, PredictPage, MatchMarketFlat, MatchSortField, MatchGroup, PredictPosition } from '@liberfi.io/react-predict';
3
+ export { BalanceResponse, CancelOrderResult, Candlestick, CreateOrderInput, DFlowKYCStatus, DFlowOrderContext, DFlowQuoteRequest, DFlowQuoteResponse, DFlowSubmitRequest, DFlowSubmitResponse, EventSortField, EventStatus, EventSummary, ListCandlesticksParams, ListEventsParams, ListMarketTradesParams, ListOrdersParams, ListTradesParams, MarketOutcome, MarketResult, MarketStatus, MarketSummary, MatchConfidenceTier, MatchGroup, MatchGroupEntry, MatchGroupMarket, MatchGroupPage, MatchMarketFlat, MatchMarketPage, MatchMarketParams, MatchSortField, MatchStatus, MatchesParams, MatchesStats, OrderSide, OrderStatus, Orderbook, OrderbookLevel, PolymarketOrderType, PositionsResponse, PredictClient, PredictContext, PredictContextValue, PredictEvent, PredictMarket, PredictOrder, PredictPage, PredictPosition, PredictProvider, PredictProviderProps, PredictTag, PredictTrade, PredictWsClient, PriceHistoryRange, PriceHistoryResponse, PricePoint, ProviderMeta, ProviderSource, ResolveEventsParamsInput, SettlementSource, SimilarEventsParams, TradeType, createPredictClient, createPredictWsClient, fetchMatchMarketsPage, fetchMatchesPage, matchMarketsQueryKey, matchQueryKey, matchesQueryKey, useBalance, useCancelOrder, useCandlesticks, useDFlowKYC, useDFlowQuote, useDFlowSubmit, useEvent, useEvents, useInfiniteEvents, useInfiniteMatchMarkets, useInfiniteMatches, useInfiniteOrders, useInfiniteTrades, useMarket, useMarketHistory, useMarketTrades, useMatch, useOrder, useOrderbook, useOrders, usePositions, usePredictClient, usePriceHistory, useSearchEvents, useSimilarEvents, useTrades } from '@liberfi.io/react-predict';
4
4
  import { LinkComponentType } from '@liberfi.io/ui';
5
5
  import * as _tanstack_react_query from '@tanstack/react-query';
6
6
  import * as react from 'react';
@@ -13,7 +13,7 @@ declare global {
13
13
  };
14
14
  }
15
15
  }
16
- declare const _default: "0.1.95";
16
+ declare const _default: "0.1.96";
17
17
 
18
18
  /**
19
19
  * A single category entry in the static navigation model.
@@ -411,6 +411,7 @@ type PredictTradeModalParams = {
411
411
  event: PredictEvent;
412
412
  market: PredictMarket;
413
413
  initialOutcome?: TradeOutcome;
414
+ initialSide?: TradeSide;
414
415
  chain?: string;
415
416
  };
416
417
  type PredictTradeModalResult = void;
@@ -652,13 +653,17 @@ type SearchWidgetProps = {
652
653
  declare function SearchWidget({ onKeywordChange, onSelectEvent, getEventHref, LinkComponent, onHover, onEscape, source, }: SearchWidgetProps): react_jsx_runtime.JSX.Element;
653
654
 
654
655
  interface MatchesPageProps {
655
- onSelectEntry?: (event: PredictEvent) => void;
656
- getEventHref?: (event: PredictEvent) => string;
656
+ onSelect?: (match: MatchMarketFlat, source: ProviderSource) => void;
657
+ getMarketHref?: (match: MatchMarketFlat, source: ProviderSource) => string | undefined;
657
658
  LinkComponent?: LinkComponentType;
658
659
  /** Path to the hero background image (e.g. "/matches-bg.webp") */
659
660
  bgImageSrc?: string;
661
+ /** @deprecated Use onSelect instead */
662
+ onSelectEntry?: (event: never) => void;
663
+ /** @deprecated Use getMarketHref instead */
664
+ getEventHref?: (event: never) => string;
660
665
  }
661
- declare function MatchesPage({ onSelectEntry, getEventHref, LinkComponent, bgImageSrc, }: MatchesPageProps): react_jsx_runtime.JSX.Element;
666
+ declare function MatchesPage({ onSelect, getMarketHref, LinkComponent, bgImageSrc, }: MatchesPageProps): react_jsx_runtime.JSX.Element;
662
667
 
663
668
  interface MatchesHeroStats {
664
669
  activePairs: number;
@@ -678,10 +683,14 @@ interface MatchesWidgetProps {
678
683
  sortBy: MatchSortField;
679
684
  sortAsc: boolean;
680
685
  minVolume?: number;
681
- onSelectEntry?: (event: PredictEvent) => void;
682
- getEventHref?: (event: PredictEvent) => string;
686
+ onSelect?: (match: MatchMarketFlat, source: ProviderSource) => void;
687
+ getMarketHref?: (match: MatchMarketFlat, source: ProviderSource) => string | undefined;
683
688
  LinkComponent?: LinkComponentType;
684
689
  onStatsChange?: (stats: MatchesHeroStats) => void;
690
+ /** @deprecated Use onSelect instead */
691
+ onSelectEntry?: (event: never) => void;
692
+ /** @deprecated Use getMarketHref instead */
693
+ getEventHref?: (event: never) => string;
685
694
  }
686
695
  declare const MatchesWidget: react.ForwardRefExoticComponent<MatchesWidgetProps & react.RefAttributes<MatchesWidgetRef>>;
687
696
 
@@ -693,6 +702,14 @@ interface MatchGroupCardProps {
693
702
  }
694
703
  declare function MatchGroupCard({ group, onSelectEntry, getEventHref, LinkComponent, }: MatchGroupCardProps): react_jsx_runtime.JSX.Element;
695
704
 
705
+ interface MatchMarketCardProps {
706
+ match: MatchMarketFlat;
707
+ onSelect?: (match: MatchMarketFlat, source: ProviderSource) => void;
708
+ getMarketHref?: (match: MatchMarketFlat, source: ProviderSource) => string | undefined;
709
+ LinkComponent?: LinkComponentType;
710
+ }
711
+ declare function MatchMarketCard({ match, onSelect, getMarketHref, LinkComponent, }: MatchMarketCardProps): react_jsx_runtime.JSX.Element;
712
+
696
713
  interface MatchesStatsBarProps {
697
714
  matches: MatchGroup[];
698
715
  total?: number;
@@ -743,6 +760,37 @@ interface ProfilePageProps {
743
760
  }
744
761
  declare function ProfilePage({ solanaAddress, evmAddress, onClosePosition, onEventClick, }: ProfilePageProps): react_jsx_runtime.JSX.Element;
745
762
 
763
+ interface KycModalProps {
764
+ isOpen: boolean;
765
+ onClose: () => void;
766
+ kycUrl: string | null;
767
+ }
768
+ declare function KycModal({ isOpen, onClose, kycUrl }: KycModalProps): react_jsx_runtime.JSX.Element;
769
+
770
+ interface SetupModalProps {
771
+ isOpen: boolean;
772
+ onClose: () => void;
773
+ evmAddress: string;
774
+ safeDeployed: boolean;
775
+ tokenApproved: boolean;
776
+ /**
777
+ * Whether Polymarket L2 API credentials are already derived.
778
+ * Comes from `PolymarketContext.credentials !== null`.
779
+ */
780
+ keysConnected: boolean;
781
+ /**
782
+ * Callback to deploy Safe + approve tokens (Steps 1-2).
783
+ * The consuming app provides the implementation using RelayClient.
784
+ */
785
+ onDeployAndApprove: () => Promise<void>;
786
+ /**
787
+ * Callback to trigger L2 key derivation (Step 3).
788
+ * Provided by the consuming app that has access to the wallet signer.
789
+ */
790
+ onConnectKeys?: () => Promise<void>;
791
+ }
792
+ declare function SetupModal({ isOpen, onClose, evmAddress, safeDeployed, tokenApproved, keysConnected, onDeployAndApprove, onConnectKeys, }: SetupModalProps): react_jsx_runtime.JSX.Element;
793
+
746
794
  /** Default page size for list queries */
747
795
  declare const DEFAULT_PAGE_SIZE = 48;
748
796
  /** Maximum number of markets to display in price history chart */
@@ -805,15 +853,34 @@ declare const DEFAULT_PRICE_HISTORY_INTERVAL: "1w";
805
853
  declare const PRICE_HISTORY_SAMPLE_INTERVAL: Record<PriceHistoryIntervalType, number>;
806
854
 
807
855
  interface PredictWalletContextValue {
808
- /** Connected Solana wallet address (for DFlow). */
856
+ /** Connected Solana wallet address (for Kalshi). */
809
857
  solanaAddress: string | undefined;
810
858
  /** Connected EVM wallet address (for Polymarket). */
811
859
  evmAddress: string | undefined;
860
+ /** Polymarket Safe (proxy) wallet address, derived from EOA via CREATE2. */
861
+ polymarketSafeAddress: string | undefined;
812
862
  /** `null` when no wallet is connected or data has not loaded yet. */
813
- dflowUsdcBalance: number | null;
814
- /** `null` when no wallet is connected or data has not loaded yet. */
863
+ kalshiUsdcBalance: number | null;
864
+ /** `null` when wallet not connected or setup not complete. */
815
865
  polymarketUsdcBalance: number | null;
866
+ /** Whether the Solana wallet has completed Kalshi/DFlow KYC verification. */
867
+ kalshiKycVerified: boolean;
868
+ /** URL to redirect for KYC onboarding, or `null` if unavailable. */
869
+ kalshiKycUrl: string | null;
870
+ /** `true` while the KYC status query is loading for the first time. */
871
+ kalshiKycLoading: boolean;
872
+ /** Whether Polymarket wallet setup is fully complete (Safe deployed + USDC.e approved). */
873
+ polymarketSetupVerified: boolean;
874
+ /** Whether the Safe wallet has been deployed on Polygon. */
875
+ polymarketSafeDeployed: boolean;
876
+ /** Whether USDC.e is approved for the CTF Exchange. */
877
+ polymarketTokenApproved: boolean;
878
+ /** `true` while the Polymarket setup status is loading. */
879
+ polymarketSetupLoading: boolean;
880
+ /** `true` only on initial load when there is no cached data yet. */
816
881
  isLoading: boolean;
882
+ /** `true` whenever a request is in-flight (including background refetches). */
883
+ isFetching: boolean;
817
884
  error: Error | null;
818
885
  }
819
886
  declare function usePredictWallet(): PredictWalletContextValue;
@@ -823,4 +890,4 @@ type PredictWalletProviderProps = PropsWithChildren<{
823
890
  }>;
824
891
  declare function PredictWalletProvider({ pollingInterval, enabled, children, }: PredictWalletProviderProps): react_jsx_runtime.JSX.Element;
825
892
 
826
- export { CHART_RANGE_DURATION, CHART_RANGE_PERIOD, CHART_RANGE_SAMPLE_INTERVAL, CandlestickPeriod, type CandlestickPeriodType, CategoriesSkeleton, CategoriesUI, type CategoriesUIProps, CategoriesWidget, type CategoriesWidgetProps, type CategoryItem, type CategoryListItem, type CategoryTagItem, ChartRange, type ChartRangeType, DEFAULT_CHART_RANGE, DEFAULT_FILTER_STATE, DEFAULT_PAGE_SIZE, DEFAULT_PRICE_HISTORY_INTERVAL, type DepthLevel, type DepthSlot, type DurationUnit, EventDetailPage, type EventDetailPageProps, EventDetailSkeleton, type EventDetailSkeletonProps, EventDetailUI, type EventDetailUIProps, EventDetailWidget, type EventDetailWidgetProps, EventItem, type EventItemProps, EventMarketDepthChartUI, type EventMarketDepthChartUIProps, EventMarketDetailWidget, type EventMarketDetailWidgetProps, EventPriceChart, type EventPriceChartProps, type EventsFilterState, EventsFilterUI, type EventsFilterUIProps, EventsPage, type EventsPageProps, EventsPageSkeleton, type EventsPageSkeletonProps, EventsSkeleton, type EventsSkeletonProps, EventsToolbarUI, type EventsToolbarUIProps, EventsUI, type EventsUIProps, EventsWidget, type EventsWidgetProps, type ExpirationPreset, MAX_PRICE_HISTORY_MARKETS, MatchGroupCard, type MatchGroupCardProps, MatchesFilterBar, type MatchesFilterBarProps, MatchesHero, type MatchesHeroProps, type MatchesHeroStats, MatchesPage, type MatchesPageProps, MatchesStatsBar, type MatchesStatsBarProps, MatchesWidget, type MatchesWidgetProps, type MatchesWidgetRef, ORDER_MAX_PRICE, ORDER_MIN_PRICE, ORDER_MIN_QUANTITY, ORDER_PRICE_STEP, type OrderType, PREDICT_SEARCH_MODAL_ID, PREDICT_TRADE_MODAL_ID, PRICE_HISTORY_SAMPLE_INTERVAL, PredictSearchModal, type PredictSearchModalParams, type PredictSearchModalResult, PredictTradeModal, type PredictTradeModalParams, type PredictTradeModalResult, type PredictWalletContextValue, PredictWalletProvider, type PredictWalletProviderProps, PriceHistoryInterval, type PriceHistoryIntervalType, ProfilePage, type ProfilePageProps, SORT_PRESETS, STATIC_CATEGORIES, SearchEventsButton, type SearchEventsButtonProps, SearchHistoryUI, type SearchHistoryUIProps, SearchHistoryWidget, type SearchHistoryWidgetProps, SearchInputUI, type SearchInputUIProps, SearchResultItemUI, type SearchResultItemUIProps, SearchResultListWidget, type SearchResultListWidgetProps, SearchWidget, type SearchWidgetProps, SimilarEventCard, type SimilarEventCardProps, SimilarEventsSection, type SimilarEventsSectionProps, type SortPreset, SourceBadge, type SourceBadgeProps, SpreadIndicator, type SpreadIndicatorProps, type TagItem, type TagSlugSelection, TradeFormSkeleton, TradeFormUI, type TradeFormUIProps, type TradeFormValidation, TradeFormWidget, type TradeFormWidgetProps, type TradeOutcome, type TradeSide, type UseEventDetailParams, type UseEventsInfiniteParams, type UseEventsInfiniteResult, type UseSearchResultListScriptParams, type UseSearchScriptParams, type UseTradeFormParams, type UseTradeFormResult, UserActivitySection, type UserActivitySectionProps, countActiveFilters, formatKMB, getSourceMeta, useEventDetail, useEventsInfinite, usePredictSearchHistory, usePredictWallet, useSearchResultListScript, useSearchScript, useTradeForm, _default as version };
893
+ export { CHART_RANGE_DURATION, CHART_RANGE_PERIOD, CHART_RANGE_SAMPLE_INTERVAL, CandlestickPeriod, type CandlestickPeriodType, CategoriesSkeleton, CategoriesUI, type CategoriesUIProps, CategoriesWidget, type CategoriesWidgetProps, type CategoryItem, type CategoryListItem, type CategoryTagItem, ChartRange, type ChartRangeType, DEFAULT_CHART_RANGE, DEFAULT_FILTER_STATE, DEFAULT_PAGE_SIZE, DEFAULT_PRICE_HISTORY_INTERVAL, type DepthLevel, type DepthSlot, type DurationUnit, EventDetailPage, type EventDetailPageProps, EventDetailSkeleton, type EventDetailSkeletonProps, EventDetailUI, type EventDetailUIProps, EventDetailWidget, type EventDetailWidgetProps, EventItem, type EventItemProps, EventMarketDepthChartUI, type EventMarketDepthChartUIProps, EventMarketDetailWidget, type EventMarketDetailWidgetProps, EventPriceChart, type EventPriceChartProps, type EventsFilterState, EventsFilterUI, type EventsFilterUIProps, EventsPage, type EventsPageProps, EventsPageSkeleton, type EventsPageSkeletonProps, EventsSkeleton, type EventsSkeletonProps, EventsToolbarUI, type EventsToolbarUIProps, EventsUI, type EventsUIProps, EventsWidget, type EventsWidgetProps, type ExpirationPreset, KycModal, type KycModalProps, MAX_PRICE_HISTORY_MARKETS, MatchGroupCard, type MatchGroupCardProps, MatchMarketCard, type MatchMarketCardProps, MatchesFilterBar, type MatchesFilterBarProps, MatchesHero, type MatchesHeroProps, type MatchesHeroStats, MatchesPage, type MatchesPageProps, MatchesStatsBar, type MatchesStatsBarProps, MatchesWidget, type MatchesWidgetProps, type MatchesWidgetRef, ORDER_MAX_PRICE, ORDER_MIN_PRICE, ORDER_MIN_QUANTITY, ORDER_PRICE_STEP, type OrderType, PREDICT_SEARCH_MODAL_ID, PREDICT_TRADE_MODAL_ID, PRICE_HISTORY_SAMPLE_INTERVAL, PredictSearchModal, type PredictSearchModalParams, type PredictSearchModalResult, PredictTradeModal, type PredictTradeModalParams, type PredictTradeModalResult, type PredictWalletContextValue, PredictWalletProvider, type PredictWalletProviderProps, PriceHistoryInterval, type PriceHistoryIntervalType, ProfilePage, type ProfilePageProps, SORT_PRESETS, STATIC_CATEGORIES, SearchEventsButton, type SearchEventsButtonProps, SearchHistoryUI, type SearchHistoryUIProps, SearchHistoryWidget, type SearchHistoryWidgetProps, SearchInputUI, type SearchInputUIProps, SearchResultItemUI, type SearchResultItemUIProps, SearchResultListWidget, type SearchResultListWidgetProps, SearchWidget, type SearchWidgetProps, SetupModal, type SetupModalProps, SimilarEventCard, type SimilarEventCardProps, SimilarEventsSection, type SimilarEventsSectionProps, type SortPreset, SourceBadge, type SourceBadgeProps, SpreadIndicator, type SpreadIndicatorProps, type TagItem, type TagSlugSelection, TradeFormSkeleton, TradeFormUI, type TradeFormUIProps, type TradeFormValidation, TradeFormWidget, type TradeFormWidgetProps, type TradeOutcome, type TradeSide, type UseEventDetailParams, type UseEventsInfiniteParams, type UseEventsInfiniteResult, type UseSearchResultListScriptParams, type UseSearchScriptParams, type UseTradeFormParams, type UseTradeFormResult, UserActivitySection, type UserActivitySectionProps, countActiveFilters, formatKMB, getSourceMeta, useEventDetail, useEventsInfinite, usePredictSearchHistory, usePredictWallet, useSearchResultListScript, useSearchScript, useTradeForm, _default as version };