@simple-parlay/components 1.30.6-pre.9 → 2.0.1
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.cjs +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.mjs +653 -515
- package/dist/react/components/CallPayoutTable.d.ts +7 -1
- package/dist/react/components/CorrelationPropPlaceholder.d.ts +6 -1
- package/dist/react/components/DenseUi.d.ts +1 -0
- package/dist/react/components/EntriesPage.d.ts +0 -4
- package/dist/react/components/EntrySubmission.d.ts +1 -1
- package/dist/react/components/EventSwipeModal.d.ts +4 -0
- package/dist/react/components/GameCardParts.d.ts +28 -0
- package/dist/react/components/GameModeCard.d.ts +37 -6
- package/dist/react/components/GamePage.d.ts +4 -2
- package/dist/react/components/GameSelector.d.ts +1 -27
- package/dist/react/components/GameSetupPage.d.ts +5 -1
- package/dist/react/components/GameShelfCatalogue.d.ts +1 -7
- package/dist/react/components/GameShowcaseCatalogue.d.ts +4 -1
- package/dist/react/components/GameSkeletons.d.ts +24 -0
- package/dist/react/components/HowToPlayButton.d.ts +2 -1
- package/dist/react/components/LoadingIndicators.d.ts +27 -10
- package/dist/react/components/MatchRail.d.ts +52 -0
- package/dist/react/components/MatchTopBar.d.ts +19 -0
- package/dist/react/components/MultiLegTable.d.ts +3 -1
- package/dist/react/components/PageBackButton.d.ts +35 -6
- package/dist/react/components/PageSkeletons.d.ts +24 -0
- package/dist/react/components/PickGroupSection.d.ts +37 -0
- package/dist/react/components/PickerBrand.d.ts +0 -5
- package/dist/react/components/PicksSkeletons.d.ts +30 -0
- package/dist/react/components/PlaceEntryProvider.d.ts +37 -4
- package/dist/react/components/PropositionFilters.d.ts +0 -1
- package/dist/react/components/PropositionParts.d.ts +38 -0
- package/dist/react/components/QuickPickButton.d.ts +27 -1
- package/dist/react/components/QuickPickMenu.d.ts +19 -1
- package/dist/react/components/SelectionsPage.d.ts +8 -4
- package/dist/react/components/ShelfKit.d.ts +43 -0
- package/dist/react/components/SportRail.d.ts +1 -1
- package/dist/react/components/SportSelector.d.ts +1 -36
- package/dist/react/components/SuccessPage.d.ts +7 -3
- package/dist/react/components/SwipeDeck.d.ts +32 -3
- package/dist/react/components/YesNoMultiLogo.d.ts +13 -0
- package/dist/react/components/_primitives/index.d.ts +57 -12
- package/dist/react/index.cjs +1 -1
- package/dist/react/index.d.ts +14 -12
- package/dist/react/index.mjs +653 -515
- package/dist/react/utils/dom.d.ts +7 -0
- package/dist/react/utils/themes.d.ts +1 -1
- package/dist/react-native/components/CallGameCatalogue.d.ts +1 -0
- package/dist/react-native/components/CallPayoutTable.d.ts +7 -1
- package/dist/react-native/components/CallTicketBuilder.d.ts +2 -0
- package/dist/react-native/components/DenseUi.d.ts +4 -10
- package/dist/react-native/components/EntrySubmission.d.ts +1 -1
- package/dist/react-native/components/EventSwipeModal.d.ts +5 -0
- package/dist/react-native/components/GameCardParts.d.ts +29 -0
- package/dist/react-native/components/GameModeCard.d.ts +34 -5
- package/dist/react-native/components/GamePage.d.ts +3 -1
- package/dist/react-native/components/GameSelector.d.ts +1 -28
- package/dist/react-native/components/GameSetupPage.d.ts +4 -13
- package/dist/react-native/components/GameShelfCatalogue.d.ts +1 -6
- package/dist/react-native/components/GameSkeletons.d.ts +23 -0
- package/dist/react-native/components/HowToPlayButton.d.ts +2 -1
- package/dist/react-native/components/LoadingIndicators.d.ts +22 -10
- package/dist/react-native/components/MatchRail.d.ts +57 -0
- package/dist/react-native/components/MatchTopBar.d.ts +17 -0
- package/dist/react-native/components/MultiLegTable.d.ts +3 -1
- package/dist/react-native/components/PageBackButton.d.ts +32 -9
- package/dist/react-native/components/PageSkeletons.d.ts +23 -0
- package/dist/react-native/components/PickGroupSection.d.ts +37 -0
- package/dist/react-native/components/PickerBrand.d.ts +0 -4
- package/dist/react-native/components/PicksSkeletons.d.ts +31 -0
- package/dist/react-native/components/PlaceEntryProvider.d.ts +37 -4
- package/dist/react-native/components/PropositionFilters.d.ts +0 -1
- package/dist/react-native/components/PropositionParts.d.ts +35 -0
- package/dist/react-native/components/QuickPickButton.d.ts +27 -1
- package/dist/react-native/components/QuickPickMenu.d.ts +20 -1
- package/dist/react-native/components/SelectionsPage.d.ts +7 -4
- package/dist/react-native/components/ShelfKit.d.ts +62 -0
- package/dist/react-native/components/SportRail.d.ts +1 -1
- package/dist/react-native/components/SportSelector.d.ts +1 -33
- package/dist/react-native/components/SuccessPage.d.ts +7 -3
- package/dist/react-native/components/SwipeDeck.d.ts +43 -3
- package/dist/react-native/components/YesNoMultiLogo.d.ts +12 -0
- package/dist/react-native/components/_primitives/index.d.ts +92 -10
- package/dist/react-native/index.cjs +1 -1
- package/dist/react-native/index.d.ts +14 -12
- package/dist/react-native/index.mjs +559 -474
- package/dist/react-native/utils/themes.d.ts +1 -1
- package/dist/shared/button-ui.d.ts +65 -0
- package/dist/shared/call-presentation.d.ts +9 -1
- package/dist/shared/canvas.d.ts +14 -0
- package/dist/shared/correlation-steering.d.ts +14 -1
- package/dist/shared/date-filters.d.ts +0 -23
- package/dist/shared/dense-ui.d.ts +0 -1
- package/dist/shared/entry-progress.d.ts +38 -0
- package/dist/shared/game-artwork.d.ts +2 -0
- package/dist/shared/game-flow.d.ts +22 -0
- package/dist/shared/game-icons.d.ts +2 -1
- package/dist/shared/game-library.d.ts +30 -6
- package/dist/shared/game-shelf-presentation.d.ts +36 -1
- package/dist/shared/hooks.d.ts +1 -1
- package/dist/shared/selection-actions.d.ts +73 -5
- package/dist/shared/selection-caps.d.ts +67 -10
- package/dist/shared/selection-variants.d.ts +7 -0
- package/dist/shared/shelf-covers.d.ts +92 -0
- package/dist/shared/shelf-ui.d.ts +47 -0
- package/dist/shared/swipe-deck.d.ts +10 -0
- package/dist/shared/themes.d.ts +53 -10
- package/dist/shared/tokens.d.ts +7 -0
- package/dist/shared/types.d.ts +19 -4
- package/dist/shared/ui-system.d.ts +71 -0
- package/dist/shared/ui-variant.d.ts +5 -3
- package/dist/shared/utils.d.ts +4 -1
- package/package.json +1 -1
- package/dist/react/components/PerfectPickPage.d.ts +0 -22
- package/dist/react/components/RuleSetupPage.d.ts +0 -27
- package/dist/react-native/components/PerfectPickPage.d.ts +0 -20
- package/dist/react-native/components/RuleSetupPage.d.ts +0 -23
|
@@ -1,9 +1,24 @@
|
|
|
1
1
|
import { default as React, ReactNode } from 'react';
|
|
2
|
-
import { ViewStyle, TextStyle, StyleProp, Animated } from 'react-native';
|
|
2
|
+
import { Text as RNText, TouchableOpacity, ViewStyle, TextStyle, StyleProp, Animated, TextInputProps } from 'react-native';
|
|
3
3
|
import { BladeTheme } from '../../../shared/themes';
|
|
4
4
|
import { YesNoLabels } from '../../../shared/utils';
|
|
5
|
+
import { ButtonVariant, ButtonSize } from '../../../shared/button-ui';
|
|
5
6
|
/** Twin of the web `TOUCH_TARGET`: minimum hit area in px. Shrink the paint, never the target. */
|
|
6
7
|
export declare const TOUCH_TARGET = 44;
|
|
8
|
+
/** Gives every ThemedText below it the host theme's fonts. */
|
|
9
|
+
export declare function FontScope({ theme, children }: {
|
|
10
|
+
theme: BladeTheme;
|
|
11
|
+
children?: ReactNode;
|
|
12
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
/** React Native's Text, set in the theme's font. Drop-in: same props and ref. */
|
|
14
|
+
export declare const ThemedText: React.ForwardRefExoticComponent<import('react-native').TextProps & React.RefAttributes<RNText>>;
|
|
15
|
+
/**
|
|
16
|
+
* TextInput for a number (stakes). Keeps what was typed ("5.", "5.0") while it still parses to
|
|
17
|
+
* `value`; a field controlled as String(value) eats the decimal point, so cents could never be typed.
|
|
18
|
+
*/
|
|
19
|
+
export declare function NumberInput({ value, onChangeText, ...rest }: Omit<TextInputProps, 'value'> & {
|
|
20
|
+
value: number;
|
|
21
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
7
22
|
/**
|
|
8
23
|
* Scroll a horizontal `ScrollView` to `x`. RN-web's patched `scrollTo` never
|
|
9
24
|
* moves the node. We need to handle platforms separately. RN 0.86 broke previous
|
|
@@ -12,6 +27,8 @@ export declare const TOUCH_TARGET = 44;
|
|
|
12
27
|
export declare function scrollRowTo(ref: {
|
|
13
28
|
current: unknown;
|
|
14
29
|
}, x: number, animated?: boolean): void;
|
|
30
|
+
export declare function webDocOf(node: unknown): Document;
|
|
31
|
+
export declare function webWinOf(node: unknown): Window;
|
|
15
32
|
/**
|
|
16
33
|
* Hover handlers for the react-native-web twin — RN's own prop types omit them
|
|
17
34
|
* and they are inert on native. Spread it (`{...hoverHandlers(a, b)}`) instead
|
|
@@ -45,21 +62,87 @@ export declare function Stack({ gap, align, justify, style, children }: StackPro
|
|
|
45
62
|
export declare function Row({ gap, align, justify, wrap, style, children, }: StackProps & {
|
|
46
63
|
wrap?: boolean;
|
|
47
64
|
}): import("react/jsx-runtime").JSX.Element;
|
|
48
|
-
|
|
49
|
-
|
|
65
|
+
/**
|
|
66
|
+
* The one hover / press tracker behind every tappable control. Spread `handlers`
|
|
67
|
+
* on a TouchableOpacity (keep `activeOpacity={1}`: the look carries the press).
|
|
68
|
+
* Hover only fires on react-native-web pointers; native never hovers.
|
|
69
|
+
*/
|
|
70
|
+
export declare function usePress(): {
|
|
71
|
+
hovered: boolean;
|
|
72
|
+
pressed: boolean;
|
|
73
|
+
handlers: {
|
|
74
|
+
onPressIn: () => void;
|
|
75
|
+
onPressOut: () => void;
|
|
76
|
+
onMouseEnter: () => void;
|
|
77
|
+
onMouseLeave: () => void;
|
|
78
|
+
};
|
|
79
|
+
};
|
|
80
|
+
/** The shared press sink for anything built on `usePress`. */
|
|
81
|
+
export declare function pressMotion(pressed: boolean, disabled?: boolean): ViewStyle;
|
|
82
|
+
export interface ButtonProps {
|
|
50
83
|
theme: BladeTheme;
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
84
|
+
/** primary: the screen's main action. secondary: the filled alternative. quiet: a tint pill for small actions. */
|
|
85
|
+
variant?: ButtonVariant;
|
|
86
|
+
/** lg (52) for the page's main action; md (44) everywhere else. */
|
|
87
|
+
size?: ButtonSize;
|
|
54
88
|
block?: boolean;
|
|
55
|
-
|
|
89
|
+
disabled?: boolean;
|
|
56
90
|
onPress?: () => void;
|
|
57
91
|
onLongPress?: () => void;
|
|
92
|
+
accessibilityLabel?: string;
|
|
93
|
+
accessibilityHint?: string;
|
|
94
|
+
accessibilityRole?: 'button' | 'menuitem' | 'link';
|
|
95
|
+
/** Merged with the button's own disabled state: expanded for disclosures, busy while placing. */
|
|
96
|
+
accessibilityState?: {
|
|
97
|
+
expanded?: boolean;
|
|
98
|
+
busy?: boolean;
|
|
99
|
+
selected?: boolean;
|
|
100
|
+
};
|
|
101
|
+
testID?: string;
|
|
58
102
|
style?: StyleProp<ViewStyle>;
|
|
103
|
+
textStyle?: StyleProp<TextStyle>;
|
|
104
|
+
/** Leading element (an icon or spinner) before a text label. */
|
|
105
|
+
icon?: ReactNode;
|
|
59
106
|
children?: ReactNode;
|
|
60
|
-
accessibilityLabel?: string;
|
|
61
107
|
}
|
|
62
|
-
|
|
108
|
+
/** The kit's one action button. Web twin: `Button` in src/react/components/_primitives. */
|
|
109
|
+
export declare function Button({ theme, variant, size, block, disabled, onPress, onLongPress, accessibilityLabel, accessibilityHint, accessibilityRole, accessibilityState, testID, style, textStyle, icon, children, }: ButtonProps): import("react/jsx-runtime").JSX.Element;
|
|
110
|
+
/** Text colour for a Button's custom children (icons, two-line labels). */
|
|
111
|
+
export declare function buttonInk(theme: BladeTheme, variant?: ButtonVariant, disabled?: boolean): string;
|
|
112
|
+
export type PressCardProps = React.ComponentProps<typeof TouchableOpacity> & {
|
|
113
|
+
theme: BladeTheme;
|
|
114
|
+
lit?: boolean;
|
|
115
|
+
};
|
|
116
|
+
/** A whole card that is one button. It keeps its own shape; its hairline turns primary on hover and it sinks on press. */
|
|
117
|
+
export declare function PressCard({ theme, lit, style, ...rest }: PressCardProps): import("react/jsx-runtime").JSX.Element;
|
|
118
|
+
export interface IconButtonProps {
|
|
119
|
+
theme: BladeTheme;
|
|
120
|
+
accessibilityLabel: string;
|
|
121
|
+
onPress?: () => void;
|
|
122
|
+
disabled?: boolean;
|
|
123
|
+
/** The painted disc; the hit area never drops below 44. */
|
|
124
|
+
size?: number;
|
|
125
|
+
/** danger: the hover ring turns the error colour (remove a pick). */
|
|
126
|
+
tone?: 'default' | 'danger';
|
|
127
|
+
/** Merged with the button's own disabled state: expanded for disclosures. */
|
|
128
|
+
accessibilityState?: {
|
|
129
|
+
expanded?: boolean;
|
|
130
|
+
selected?: boolean;
|
|
131
|
+
};
|
|
132
|
+
testID?: string;
|
|
133
|
+
style?: StyleProp<ViewStyle>;
|
|
134
|
+
/** Drawn in `iconButtonInk` — pass it to the icon. */
|
|
135
|
+
children?: ReactNode;
|
|
136
|
+
}
|
|
137
|
+
/**
|
|
138
|
+
* Icon-only button (back, close, remove, previous / next): a round disc with a
|
|
139
|
+
* hairline ring and the shared hover tint. A disc under 44 keeps its own
|
|
140
|
+
* footprint and reaches out to a 44 hit area with negative margins.
|
|
141
|
+
* Web twin: `IconButton` in src/react/components/_primitives.
|
|
142
|
+
*/
|
|
143
|
+
export declare function IconButton({ theme, accessibilityLabel, onPress, disabled, size, tone, accessibilityState, testID, style, children }: IconButtonProps): import("react/jsx-runtime").JSX.Element;
|
|
144
|
+
/** The icon colour inside an IconButton at rest (hover recolours the ring, not the glyph, on native). */
|
|
145
|
+
export declare function iconButtonInk(theme: BladeTheme): string;
|
|
63
146
|
export interface TextProps {
|
|
64
147
|
theme: BladeTheme;
|
|
65
148
|
variant?: 'display' | 'heading' | 'subheading' | 'body' | 'caption' | 'eyebrow';
|
|
@@ -98,7 +181,6 @@ export interface YesNoButtonsProps {
|
|
|
98
181
|
noLabel?: string;
|
|
99
182
|
style?: StyleProp<ViewStyle>;
|
|
100
183
|
}
|
|
101
|
-
/** The interactive Yes/No pair. Identical everywhere it is used. */
|
|
102
184
|
export declare function YesNoButtons({ theme, value, onYes, onNo, size, stretch, disabled, yesDisabled, noDisabled, yesLabel, noLabel, style, }: YesNoButtonsProps): import("react/jsx-runtime").JSX.Element;
|
|
103
185
|
/** Read-only Yes/No chip — the settled answer, same product tokens. */
|
|
104
186
|
export declare function YesNoTag({ theme, value, size, style, }: {
|