@liberfi.io/ui-predict 4.0.58 → 4.0.59

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
@@ -798,6 +798,8 @@ interface TradeFormUIProps {
798
798
  customDurationUnit: DurationUnit;
799
799
  /** Optional formatter for display-only odds/price labels. Defaults to cents/probability text. */
800
800
  oddsFormatter?: OddsFormatter;
801
+ /** Optional display labels for binary outcomes. Defaults to localized Yes/No. */
802
+ outcomeLabels?: Partial<Record<TradeOutcome, string>>;
801
803
  onOutcomeChange: (outcome: TradeOutcome) => void;
802
804
  onOrderTypeChange: (type: OrderType) => void;
803
805
  onQuantityChange: (quantity: number) => void;
@@ -808,7 +810,7 @@ interface TradeFormUIProps {
808
810
  onCustomDurationUnitChange: (u: DurationUnit) => void;
809
811
  onSubmit: () => void;
810
812
  }
811
- declare function TradeFormUI({ event, market, variant, outcome, orderType, quantity, limitPrice, shares, effectivePrice, potentialProfit, potentialPayout, estimatedCost, estimatedFee, usdcBalance, isBalanceLoading, isMarketDataLoading, isSubmitting, authStatus, isValid, validationErrors, isInsufficientBalance, onInsufficientBalance, supportsLimitOrder, maxBuyAmount, kycRequired, needsKyc, needsSetup, kycUrl, expirationEnabled, expirationPreset, customDuration, customDurationUnit, oddsFormatter, onOutcomeChange, onOrderTypeChange, onQuantityChange, onLimitPriceChange, onExpirationEnabledChange, onExpirationPresetChange, onCustomDurationChange, onCustomDurationUnitChange, onSubmit, }: TradeFormUIProps): react_jsx_runtime.JSX.Element;
813
+ declare function TradeFormUI({ event, market, variant, outcome, orderType, quantity, limitPrice, shares, effectivePrice, potentialProfit, potentialPayout, estimatedCost, estimatedFee, usdcBalance, isBalanceLoading, isMarketDataLoading, isSubmitting, authStatus, isValid, validationErrors, isInsufficientBalance, onInsufficientBalance, supportsLimitOrder, maxBuyAmount, kycRequired, needsKyc, needsSetup, kycUrl, expirationEnabled, expirationPreset, customDuration, customDurationUnit, oddsFormatter, outcomeLabels, onOutcomeChange, onOrderTypeChange, onQuantityChange, onLimitPriceChange, onExpirationEnabledChange, onExpirationPresetChange, onCustomDurationChange, onCustomDurationUnitChange, onSubmit, }: TradeFormUIProps): react_jsx_runtime.JSX.Element;
812
814
 
813
815
  interface TradeFormWidgetProps {
814
816
  event?: PredictEvent;
@@ -831,8 +833,10 @@ interface TradeFormWidgetProps {
831
833
  onOutcomeChange?: (outcome: TradeOutcome) => void;
832
834
  /** Optional formatter for display-only odds/price labels. */
833
835
  oddsFormatter?: OddsFormatter;
836
+ /** Optional display labels for binary outcomes. Defaults to localized Yes/No. */
837
+ outcomeLabels?: Partial<Record<TradeOutcome, string>>;
834
838
  }
835
- declare function TradeFormWidget({ event, market, variant, initialOutcome, chain, slippageBps, onInsufficientBalance, onOutcomeChange, oddsFormatter, }: TradeFormWidgetProps): react_jsx_runtime.JSX.Element;
839
+ declare function TradeFormWidget({ event, market, variant, initialOutcome, chain, slippageBps, onInsufficientBalance, onOutcomeChange, oddsFormatter, outcomeLabels, }: TradeFormWidgetProps): react_jsx_runtime.JSX.Element;
836
840
 
837
841
  interface TradeResultToastMessages {
838
842
  submitted: string;
@@ -990,6 +994,8 @@ interface SellFormUIProps {
990
994
  customDurationUnit: DurationUnit;
991
995
  /** Optional formatter for display-only odds/price labels. Defaults to cents/probability text. */
992
996
  oddsFormatter?: OddsFormatter;
997
+ /** Optional display labels for binary outcomes. Defaults to localized Yes/No. */
998
+ outcomeLabels?: Partial<Record<TradeOutcome, string>>;
993
999
  onOutcomeChange: (outcome: TradeOutcome) => void;
994
1000
  onOrderTypeChange: (type: OrderType) => void;
995
1001
  onQuantityChange: (quantity: number) => void;
@@ -1001,7 +1007,7 @@ interface SellFormUIProps {
1001
1007
  onCustomDurationUnitChange: (u: DurationUnit) => void;
1002
1008
  onSubmit: () => void;
1003
1009
  }
1004
- declare function SellFormUI({ event, market, variant, outcome, orderType, quantity, limitPrice, effectivePrice, grossReturn, estimatedFee, estimatedReturn, isMarketDataLoading, isSubmitting, authStatus, isValid, validationErrors, supportsLimitOrder, kycRequired, needsKyc, needsSetup, onSetupRequired, kycUrl, totalShares, activeOrderShares, availableShares, isAvailableLoading, precision, expirationEnabled, expirationPreset, customDuration, customDurationUnit, oddsFormatter, onOutcomeChange, onOrderTypeChange, onQuantityChange, onLimitPriceChange, onSellAll, onExpirationEnabledChange, onExpirationPresetChange, onCustomDurationChange, onCustomDurationUnitChange, onSubmit, }: SellFormUIProps): react_jsx_runtime.JSX.Element;
1010
+ declare function SellFormUI({ event, market, variant, outcome, orderType, quantity, limitPrice, effectivePrice, grossReturn, estimatedFee, estimatedReturn, isMarketDataLoading, isSubmitting, authStatus, isValid, validationErrors, supportsLimitOrder, kycRequired, needsKyc, needsSetup, onSetupRequired, kycUrl, totalShares, activeOrderShares, availableShares, isAvailableLoading, precision, expirationEnabled, expirationPreset, customDuration, customDurationUnit, oddsFormatter, outcomeLabels, onOutcomeChange, onOrderTypeChange, onQuantityChange, onLimitPriceChange, onSellAll, onExpirationEnabledChange, onExpirationPresetChange, onCustomDurationChange, onCustomDurationUnitChange, onSubmit, }: SellFormUIProps): react_jsx_runtime.JSX.Element;
1005
1011
 
1006
1012
  interface SellFormWidgetProps {
1007
1013
  event?: PredictEvent;
@@ -1031,8 +1037,10 @@ interface SellFormWidgetProps {
1031
1037
  onSuccess?: () => void;
1032
1038
  /** Optional formatter for display-only odds/price labels. */
1033
1039
  oddsFormatter?: OddsFormatter;
1040
+ /** Optional display labels for binary outcomes. Defaults to localized Yes/No. */
1041
+ outcomeLabels?: Partial<Record<TradeOutcome, string>>;
1034
1042
  }
1035
- declare function SellFormWidget({ event, market, variant, initialOutcome, initialPositionSide, chain, slippageBps, onOutcomeChange, onSetupRequired, onSuccess, oddsFormatter, }: SellFormWidgetProps): react_jsx_runtime.JSX.Element;
1043
+ declare function SellFormWidget({ event, market, variant, initialOutcome, initialPositionSide, chain, slippageBps, onOutcomeChange, onSetupRequired, onSuccess, oddsFormatter, outcomeLabels, }: SellFormWidgetProps): react_jsx_runtime.JSX.Element;
1036
1044
 
1037
1045
  type PredictRedeemModalParams = {
1038
1046
  event: PredictEvent;
package/dist/index.d.ts CHANGED
@@ -798,6 +798,8 @@ interface TradeFormUIProps {
798
798
  customDurationUnit: DurationUnit;
799
799
  /** Optional formatter for display-only odds/price labels. Defaults to cents/probability text. */
800
800
  oddsFormatter?: OddsFormatter;
801
+ /** Optional display labels for binary outcomes. Defaults to localized Yes/No. */
802
+ outcomeLabels?: Partial<Record<TradeOutcome, string>>;
801
803
  onOutcomeChange: (outcome: TradeOutcome) => void;
802
804
  onOrderTypeChange: (type: OrderType) => void;
803
805
  onQuantityChange: (quantity: number) => void;
@@ -808,7 +810,7 @@ interface TradeFormUIProps {
808
810
  onCustomDurationUnitChange: (u: DurationUnit) => void;
809
811
  onSubmit: () => void;
810
812
  }
811
- declare function TradeFormUI({ event, market, variant, outcome, orderType, quantity, limitPrice, shares, effectivePrice, potentialProfit, potentialPayout, estimatedCost, estimatedFee, usdcBalance, isBalanceLoading, isMarketDataLoading, isSubmitting, authStatus, isValid, validationErrors, isInsufficientBalance, onInsufficientBalance, supportsLimitOrder, maxBuyAmount, kycRequired, needsKyc, needsSetup, kycUrl, expirationEnabled, expirationPreset, customDuration, customDurationUnit, oddsFormatter, onOutcomeChange, onOrderTypeChange, onQuantityChange, onLimitPriceChange, onExpirationEnabledChange, onExpirationPresetChange, onCustomDurationChange, onCustomDurationUnitChange, onSubmit, }: TradeFormUIProps): react_jsx_runtime.JSX.Element;
813
+ declare function TradeFormUI({ event, market, variant, outcome, orderType, quantity, limitPrice, shares, effectivePrice, potentialProfit, potentialPayout, estimatedCost, estimatedFee, usdcBalance, isBalanceLoading, isMarketDataLoading, isSubmitting, authStatus, isValid, validationErrors, isInsufficientBalance, onInsufficientBalance, supportsLimitOrder, maxBuyAmount, kycRequired, needsKyc, needsSetup, kycUrl, expirationEnabled, expirationPreset, customDuration, customDurationUnit, oddsFormatter, outcomeLabels, onOutcomeChange, onOrderTypeChange, onQuantityChange, onLimitPriceChange, onExpirationEnabledChange, onExpirationPresetChange, onCustomDurationChange, onCustomDurationUnitChange, onSubmit, }: TradeFormUIProps): react_jsx_runtime.JSX.Element;
812
814
 
813
815
  interface TradeFormWidgetProps {
814
816
  event?: PredictEvent;
@@ -831,8 +833,10 @@ interface TradeFormWidgetProps {
831
833
  onOutcomeChange?: (outcome: TradeOutcome) => void;
832
834
  /** Optional formatter for display-only odds/price labels. */
833
835
  oddsFormatter?: OddsFormatter;
836
+ /** Optional display labels for binary outcomes. Defaults to localized Yes/No. */
837
+ outcomeLabels?: Partial<Record<TradeOutcome, string>>;
834
838
  }
835
- declare function TradeFormWidget({ event, market, variant, initialOutcome, chain, slippageBps, onInsufficientBalance, onOutcomeChange, oddsFormatter, }: TradeFormWidgetProps): react_jsx_runtime.JSX.Element;
839
+ declare function TradeFormWidget({ event, market, variant, initialOutcome, chain, slippageBps, onInsufficientBalance, onOutcomeChange, oddsFormatter, outcomeLabels, }: TradeFormWidgetProps): react_jsx_runtime.JSX.Element;
836
840
 
837
841
  interface TradeResultToastMessages {
838
842
  submitted: string;
@@ -990,6 +994,8 @@ interface SellFormUIProps {
990
994
  customDurationUnit: DurationUnit;
991
995
  /** Optional formatter for display-only odds/price labels. Defaults to cents/probability text. */
992
996
  oddsFormatter?: OddsFormatter;
997
+ /** Optional display labels for binary outcomes. Defaults to localized Yes/No. */
998
+ outcomeLabels?: Partial<Record<TradeOutcome, string>>;
993
999
  onOutcomeChange: (outcome: TradeOutcome) => void;
994
1000
  onOrderTypeChange: (type: OrderType) => void;
995
1001
  onQuantityChange: (quantity: number) => void;
@@ -1001,7 +1007,7 @@ interface SellFormUIProps {
1001
1007
  onCustomDurationUnitChange: (u: DurationUnit) => void;
1002
1008
  onSubmit: () => void;
1003
1009
  }
1004
- declare function SellFormUI({ event, market, variant, outcome, orderType, quantity, limitPrice, effectivePrice, grossReturn, estimatedFee, estimatedReturn, isMarketDataLoading, isSubmitting, authStatus, isValid, validationErrors, supportsLimitOrder, kycRequired, needsKyc, needsSetup, onSetupRequired, kycUrl, totalShares, activeOrderShares, availableShares, isAvailableLoading, precision, expirationEnabled, expirationPreset, customDuration, customDurationUnit, oddsFormatter, onOutcomeChange, onOrderTypeChange, onQuantityChange, onLimitPriceChange, onSellAll, onExpirationEnabledChange, onExpirationPresetChange, onCustomDurationChange, onCustomDurationUnitChange, onSubmit, }: SellFormUIProps): react_jsx_runtime.JSX.Element;
1010
+ declare function SellFormUI({ event, market, variant, outcome, orderType, quantity, limitPrice, effectivePrice, grossReturn, estimatedFee, estimatedReturn, isMarketDataLoading, isSubmitting, authStatus, isValid, validationErrors, supportsLimitOrder, kycRequired, needsKyc, needsSetup, onSetupRequired, kycUrl, totalShares, activeOrderShares, availableShares, isAvailableLoading, precision, expirationEnabled, expirationPreset, customDuration, customDurationUnit, oddsFormatter, outcomeLabels, onOutcomeChange, onOrderTypeChange, onQuantityChange, onLimitPriceChange, onSellAll, onExpirationEnabledChange, onExpirationPresetChange, onCustomDurationChange, onCustomDurationUnitChange, onSubmit, }: SellFormUIProps): react_jsx_runtime.JSX.Element;
1005
1011
 
1006
1012
  interface SellFormWidgetProps {
1007
1013
  event?: PredictEvent;
@@ -1031,8 +1037,10 @@ interface SellFormWidgetProps {
1031
1037
  onSuccess?: () => void;
1032
1038
  /** Optional formatter for display-only odds/price labels. */
1033
1039
  oddsFormatter?: OddsFormatter;
1040
+ /** Optional display labels for binary outcomes. Defaults to localized Yes/No. */
1041
+ outcomeLabels?: Partial<Record<TradeOutcome, string>>;
1034
1042
  }
1035
- declare function SellFormWidget({ event, market, variant, initialOutcome, initialPositionSide, chain, slippageBps, onOutcomeChange, onSetupRequired, onSuccess, oddsFormatter, }: SellFormWidgetProps): react_jsx_runtime.JSX.Element;
1043
+ declare function SellFormWidget({ event, market, variant, initialOutcome, initialPositionSide, chain, slippageBps, onOutcomeChange, onSetupRequired, onSuccess, oddsFormatter, outcomeLabels, }: SellFormWidgetProps): react_jsx_runtime.JSX.Element;
1036
1044
 
1037
1045
  type PredictRedeemModalParams = {
1038
1046
  event: PredictEvent;