@simple-parlay/components 1.30.6-pre.4 → 1.30.6-pre.5
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.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/index.mjs +288 -290
- package/dist/react/components/PlaceEntryProvider.d.ts +3 -1
- package/dist/react/components/PropositionFilters.d.ts +3 -1
- package/dist/react/components/SportRail.d.ts +0 -4
- package/dist/react/components/SportSelector.d.ts +1 -1
- package/dist/react/components/_primitives/index.d.ts +4 -0
- package/dist/react/index.d.ts +2 -0
- package/dist/react/index.js +1 -1
- package/dist/react/index.mjs +288 -290
- package/dist/react/utils/index.d.ts +1 -1
- package/dist/react-native/components/LoadingIndicators.d.ts +1 -1
- package/dist/react-native/components/PlaceEntryProvider.d.ts +3 -1
- package/dist/react-native/components/PropositionFilters.d.ts +3 -1
- package/dist/react-native/components/SportRail.d.ts +6 -4
- package/dist/react-native/components/SportSelector.d.ts +1 -1
- package/dist/react-native/components/_primitives/index.d.ts +5 -1
- package/dist/react-native/index.d.ts +2 -0
- package/dist/react-native/index.js +1 -1
- package/dist/react-native/index.mjs +378 -381
- package/dist/react-native/utils/index.d.ts +1 -1
- package/dist/shared/date-filters.d.ts +5 -4
- package/dist/shared/hooks.d.ts +1 -1
- package/dist/shared/picker-brand.d.ts +2 -0
- package/dist/shared/selection-actions.d.ts +1 -0
- package/dist/shared/types.d.ts +1 -0
- package/dist/shared/utils.d.ts +11 -1
- package/package.json +1 -1
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { resolvePrice, toNumber, toBool, formatYesNo, formatCurrency, formatDate, groupPropositionsBySport, getPropositionSportKey, collectPropositionSportKeys, compositePropositionMatchesSport, compositePropositionMatchesGameSports, groupPropositionsByCategory, groupPropositionsByEntryCategory, getPropositionEntryCategory, isRacingProposition, getAvailableEntryCategories, getSportPickerTitle, getCategoryDisplayName, getCategoryTagline, getSportShortCode, getSportPickerTagline, getSportSummaryTagline, splitSportLabel, getSportComingSoonCaption, getHowToPlayPanel, describeDemoVerdict, groupByMatchup, groupByRace, groupPropositionsForDisplay, isRacingCategory, buildRangeLegOptions, getPayoutForCount, generateQuickPick, isValidSelectionCount, getEffectivePropositionLimits, findPermittedRule, getJackpotInfo, getSportDisplayName, resolveSportDisplayName, resolveCategoryDisplayName, filterPropositionsForGame, filterPropositionPool, filterGamesByPropositionPool, filterGamesByEntryCategory, gameHasPropositionsInPool, getGameEntryCategory, gameMatchesEntryCategory, gamePermitsSport, normalizeGamesSport, sportKeysCompatible, propositionSportMatches, isGameAvailableToday, getAvailableDaysLabel, contrastTextColour, readableColor, getCompositeOperatorLabel, getCompositeHelperText, parseCompositeDescription, inferCompositeOperatorFromDescription, resolveCompositeOperator, resolveCompositeDisplay, resolveCompositeLegs, parseCompositeComponentIds, collectCompositeComponentIds, formatPropositionEventLabel, getPropositionDescription, getPropositionMarketType, resolveGameIconId, resolveGameIconUrl, isGameIconUrl, resolveGameIconMarkup, } from '../../shared/utils';
|
|
1
|
+
export { resolvePrice, toNumber, toBool, formatYesNo, DEFAULT_YES_NO_LABELS, formatCurrency, formatDate, groupPropositionsBySport, getPropositionSportKey, collectPropositionSportKeys, compositePropositionMatchesSport, compositePropositionMatchesGameSports, groupPropositionsByCategory, groupPropositionsByEntryCategory, getPropositionEntryCategory, isRacingProposition, getAvailableEntryCategories, getSportPickerTitle, getCategoryDisplayName, getCategoryTagline, getSportShortCode, getSportPickerTagline, getSportSummaryTagline, splitSportLabel, getSportComingSoonCaption, getHowToPlayPanel, describeDemoVerdict, groupByMatchup, groupByRace, groupPropositionsForDisplay, isRacingCategory, buildRangeLegOptions, getPayoutForCount, generateQuickPick, isValidSelectionCount, getEffectivePropositionLimits, findPermittedRule, getJackpotInfo, getSportDisplayName, resolveSportDisplayName, resolveSportLabel, resolveCategoryDisplayName, filterPropositionsForGame, filterPropositionPool, filterGamesByPropositionPool, filterGamesByEntryCategory, gameHasPropositionsInPool, getGameEntryCategory, gameMatchesEntryCategory, gamePermitsSport, normalizeGamesSport, sportKeysCompatible, propositionSportMatches, isGameAvailableToday, getAvailableDaysLabel, contrastTextColour, readableColor, getCompositeOperatorLabel, getCompositeHelperText, parseCompositeDescription, inferCompositeOperatorFromDescription, resolveCompositeOperator, resolveCompositeDisplay, resolveCompositeLegs, parseCompositeComponentIds, collectCompositeComponentIds, formatPropositionEventLabel, getPropositionDescription, getPropositionMarketType, resolveGameIconId, resolveGameIconUrl, isGameIconUrl, resolveGameIconMarkup, } from '../../shared/utils';
|
|
2
2
|
export type { SportDisplayNameOverrides, CategoryDisplayNameOverrides, GameIconId, ComingSoonSport, HowToPlayPanelContent, HowToPlaySummarySegment, HowToPlayStep, HowToPlayDemoLeg, HowToPlayDemoVerdict } from '../../shared/utils';
|
|
@@ -23,7 +23,7 @@ export declare function CategoryGridSkeleton({ colors, count, }: {
|
|
|
23
23
|
colors: PickerSurfaceColors;
|
|
24
24
|
count?: number;
|
|
25
25
|
}): import("react/jsx-runtime").JSX.Element;
|
|
26
|
-
/** RN mirror of web `SportGridSkeleton` — stacked tile
|
|
26
|
+
/** RN mirror of web `SportGridSkeleton` — a stacked tile at every width. */
|
|
27
27
|
export declare function SportGridSkeleton({ colors, count, }: {
|
|
28
28
|
colors: PickerSurfaceColors;
|
|
29
29
|
count?: number;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
|
+
import { YesNoLabels } from '../../shared/utils';
|
|
2
3
|
import { Game, Proposition, SportSummary, GameEntry, TopPayoutsResponse, ShareData, ScreenSize } from '../types';
|
|
3
4
|
import { BladeTheme, BladeThemeSet, ColorScheme } from '../utils/themes';
|
|
4
5
|
import { SportDisplayNameOverrides, CategoryDisplayNameOverrides } from '../utils';
|
|
@@ -137,6 +138,7 @@ export interface PlaceEntryProviderProps {
|
|
|
137
138
|
selectionVariant?: SelectionVariant;
|
|
138
139
|
disableEventSwipe?: boolean;
|
|
139
140
|
/** Let players star a sport in the rail to pin it up front (per device). Off by default. */
|
|
141
|
+
yesNoLabels?: YesNoLabels;
|
|
140
142
|
enableSportFavourites?: boolean;
|
|
141
143
|
onEntryPlaced?: (entry: GameEntry) => void;
|
|
142
144
|
onBeforeSubmit?: (betAmount: number) => void | Promise<void>;
|
|
@@ -149,4 +151,4 @@ export interface PlaceEntryProviderProps {
|
|
|
149
151
|
sportDisplayNames?: SportDisplayNameOverrides;
|
|
150
152
|
categoryDisplayNames?: CategoryDisplayNameOverrides;
|
|
151
153
|
}
|
|
152
|
-
export declare function PlaceEntryProvider({ apiUrl, apiKey, fetchImpl, getAuthHeaders, userId, getUserBalance, children, theme: themeProp, colorScheme, demoGames, demoPropositions, demoEntries, demoMaxPayouts, gameCategory, jurisdiction, initialGameId, filterSport, initialSport, initialEventId, initialEventLabel, sportBaseKey, disableQuickPick, renderTeamLogo, renderPropositionSilk, selectionVariant, disableEventSwipe, enableSportFavourites, onEntryPlaced, onBeforeSubmit, onCancel, onShare, onRecharge, onClearEventFilter, screenSize, howToPlayMarkdown: howToPlayMarkdownProp, sportDisplayNames, categoryDisplayNames, }: PlaceEntryProviderProps): import("react/jsx-runtime").JSX.Element;
|
|
154
|
+
export declare function PlaceEntryProvider({ apiUrl, apiKey, fetchImpl, getAuthHeaders, userId, getUserBalance, children, theme: themeProp, colorScheme, demoGames, demoPropositions, demoEntries, demoMaxPayouts, gameCategory, jurisdiction, initialGameId, filterSport, initialSport, initialEventId, initialEventLabel, sportBaseKey, disableQuickPick, renderTeamLogo, renderPropositionSilk, selectionVariant, disableEventSwipe, enableSportFavourites, yesNoLabels, onEntryPlaced, onBeforeSubmit, onCancel, onShare, onRecharge, onClearEventFilter, screenSize, howToPlayMarkdown: howToPlayMarkdownProp, sportDisplayNames, categoryDisplayNames, }: PlaceEntryProviderProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -6,15 +6,17 @@ export interface FilterChipOption {
|
|
|
6
6
|
export interface FilterChipGroup {
|
|
7
7
|
label?: string;
|
|
8
8
|
options: FilterChipOption[];
|
|
9
|
-
value: string | null;
|
|
9
|
+
value: string | null | string[];
|
|
10
10
|
onChange: (value: string | null) => void;
|
|
11
11
|
}
|
|
12
|
+
export declare function isChipActive(groupValue: FilterChipGroup['value'], optValue: string | null): boolean;
|
|
12
13
|
export interface FilterChipCarouselProps {
|
|
13
14
|
groups: FilterChipGroup[];
|
|
14
15
|
theme: BladeTheme;
|
|
15
16
|
bodyFont?: string;
|
|
16
17
|
}
|
|
17
18
|
export declare function FilterChipCarousel({ groups, theme, bodyFont, }: FilterChipCarouselProps): import("react/jsx-runtime").JSX.Element | null;
|
|
19
|
+
export declare function FilterChipPanel({ groups, theme, bodyFont }: FilterChipCarouselProps): import("react/jsx-runtime").JSX.Element | null;
|
|
18
20
|
export interface FilterChipRowProps extends FilterChipGroup {
|
|
19
21
|
theme: BladeTheme;
|
|
20
22
|
bodyFont?: string;
|
|
@@ -10,10 +10,12 @@ export interface SportRailProps {
|
|
|
10
10
|
style?: StyleProp<ViewStyle>;
|
|
11
11
|
}
|
|
12
12
|
/**
|
|
13
|
-
* The sport step
|
|
14
|
-
* setup page
|
|
15
|
-
*
|
|
16
|
-
*
|
|
13
|
+
* The sport step. It sits on a game's setup page, and — for the games that have
|
|
14
|
+
* no setup page — above the proposition list, so there is always one place to
|
|
15
|
+
* change it. Never on the game grid.
|
|
16
|
+
*
|
|
17
|
+
* A bet is one sport: once the slip has picks the rail locks, and the only way
|
|
18
|
+
* across is to clear the bet — silently wiping the card on a mis-tap was worse.
|
|
17
19
|
*
|
|
18
20
|
* Renders nothing at all when the sport is not a choice, which is every
|
|
19
21
|
* single-sport game.
|
|
@@ -39,4 +39,4 @@ export declare function CompositePropositionText({ prop, colors: c, size, compon
|
|
|
39
39
|
*/
|
|
40
40
|
renderTeamLogo?: RenderTeamLogo;
|
|
41
41
|
}): import("react/jsx-runtime").JSX.Element;
|
|
42
|
-
export declare function SportSelector({ game, propositions, selections, onToggleSelection, onNext, onBack, loading, error, theme: themeProp, colorScheme, hideActions, initialSport, renderTeamLogo, disableQuickPick, selectedPropositionCount, onPropositionCountChange, gameCategory, headerExtra, variant, disableEventSwipe, }: SportSelectorProps): import("react/jsx-runtime").JSX.Element;
|
|
42
|
+
export declare function SportSelector({ game, propositions, selections, onToggleSelection, onNext, onBack, loading, error, theme: themeProp, colorScheme, hideActions, initialSport, renderTeamLogo, disableQuickPick, selectedPropositionCount, onPropositionCountChange, gameCategory, headerExtra, railSlot, variant, disableEventSwipe, }: SportSelectorProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { ReactNode } from 'react';
|
|
1
|
+
import { default as React, ReactNode } from 'react';
|
|
2
2
|
import { ViewStyle, TextStyle, StyleProp, Animated } from 'react-native';
|
|
3
3
|
import { BladeTheme } from '../../../shared/themes';
|
|
4
|
+
import { YesNoLabels } from '../../../shared/utils';
|
|
4
5
|
/** Twin of the web `TOUCH_TARGET`: minimum hit area in px. Shrink the paint, never the target. */
|
|
5
6
|
export declare const TOUCH_TARGET = 44;
|
|
6
7
|
/**
|
|
@@ -78,6 +79,9 @@ export declare function Divider({ theme, orientation, style, }: {
|
|
|
78
79
|
export type YesNoValue = 'yes' | 'no';
|
|
79
80
|
export type YesNoAnswer = YesNoValue | null | undefined;
|
|
80
81
|
export type YesNoSize = 'xs' | 'sm' | 'md';
|
|
82
|
+
export type { YesNoLabels };
|
|
83
|
+
export declare const YesNoLabelsProvider: React.Provider<YesNoLabels>;
|
|
84
|
+
export declare function useYesNoLabels(): YesNoLabels;
|
|
81
85
|
export interface YesNoButtonsProps {
|
|
82
86
|
theme: BladeTheme;
|
|
83
87
|
/** Currently selected side, if any. */
|
|
@@ -12,6 +12,8 @@ export { GameEntries } from './components/GameEntries';
|
|
|
12
12
|
export { QuickPickButton } from './components/QuickPickButton';
|
|
13
13
|
export type { QuickPickButtonProps } from './components/QuickPickButton';
|
|
14
14
|
export { PlaceEntryProvider, usePlaceEntry } from './components/PlaceEntryProvider';
|
|
15
|
+
export { useYesNoLabels } from './components/_primitives';
|
|
16
|
+
export type { YesNoLabels } from '../shared/utils';
|
|
15
17
|
export type { PlaceEntryProviderProps, PlaceEntryContextValue } from './components/PlaceEntryProvider';
|
|
16
18
|
export { GamePage, GamePageTitle, GamePageActions } from './components/GamePage';
|
|
17
19
|
export type { GamePageProps } from './components/GamePage';
|