@sleeperhq/mini-core 3.0.6 → 4.0.0

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.
@@ -4,20 +4,20 @@ export interface AvatarProps {
4
4
  user: User;
5
5
  width?: number;
6
6
  }
7
- export declare const Avatar: React.MemoExoticComponent<(props: AvatarProps) => React.JSX.Element>;
7
+ export declare const Avatar: React.NamedExoticComponent<AvatarProps>;
8
8
  export interface AvatarPlayerProps {
9
9
  player: Player;
10
10
  width?: number;
11
11
  }
12
- export declare const AvatarPlayer: React.MemoExoticComponent<(props: AvatarPlayerProps) => React.JSX.Element>;
12
+ export declare const AvatarPlayer: React.NamedExoticComponent<AvatarPlayerProps>;
13
13
  export interface AvatarTeamProps {
14
14
  team: string;
15
15
  sport: string;
16
16
  width?: number;
17
17
  }
18
- export declare const AvatarTeam: React.MemoExoticComponent<(props: AvatarTeamProps) => React.JSX.Element>;
18
+ export declare const AvatarTeam: React.NamedExoticComponent<AvatarTeamProps>;
19
19
  export interface AvatarLeagueProps {
20
20
  league: League;
21
21
  width?: number;
22
22
  }
23
- export declare const AvatarLeague: React.MemoExoticComponent<(props: AvatarLeagueProps) => React.JSX.Element>;
23
+ export declare const AvatarLeague: React.NamedExoticComponent<AvatarLeagueProps>;
@@ -1,4 +1,4 @@
1
- /// <reference types="react" />
1
+ import React from 'react';
2
2
  import { GestureResponderEvent } from 'react-native';
3
3
  export interface ButtonProps {
4
4
  height?: number;
@@ -15,23 +15,5 @@ export interface ButtonProps {
15
15
  onPress?: (event: GestureResponderEvent) => void;
16
16
  text?: string;
17
17
  }
18
- declare const Button: {
19
- (props: ButtonProps): React.JSX.Element;
20
- defaultProps: {
21
- height: number;
22
- shadowHeight: number;
23
- gradient: string[];
24
- type: string;
25
- size: string;
26
- isForSmallScreen: boolean;
27
- start: {
28
- x: number;
29
- y: number;
30
- };
31
- end: {
32
- x: number;
33
- y: number;
34
- };
35
- };
36
- };
18
+ declare const Button: (props: ButtonProps) => React.JSX.Element;
37
19
  export default Button;
@@ -1,5 +1,4 @@
1
1
  /// <reference types="react" />
2
- import React from "react";
3
-
4
- declare const _default: (props: any) => React.JSX.Element;
2
+ import 'moment-timezone';
3
+ declare const _default: (props: any) => import("react").JSX.Element;
5
4
  export default _default;
@@ -1,9 +1,13 @@
1
- import { ColorValue, ViewStyle } from 'react-native';
1
+ import { ColorValue } from 'react-native';
2
2
  import SleeperJersey from '@sleeperhq/mini-core/declarations/types/components/jersey.d';
3
3
  export interface JerseyProps {
4
- style: ViewStyle;
5
- sport: 'nfl' | 'nba' | 'cbb' | 'cfb' | 'mlb';
6
- number: string;
7
4
  fill: ColorValue;
5
+ stroke: string;
6
+ strokeWidth: number;
7
+ number: number;
8
+ width: number;
9
+ sport: 'nfl' | 'nba' | 'cbb' | 'cfb' | 'mlb';
10
+ team: string;
11
+ borderRadius?: number;
8
12
  }
9
13
  export default SleeperJersey;
@@ -1,4 +1,4 @@
1
- import { User, League, LeaguesMap, RostersInLeagueMap, UserMap, MatchupsInLeagueMap, UsersInLeagueMap, PlayoffsInLeagueMap, TransactionsInLeagueMap, TransactionsMap, SportInfoMap, DraftsInLeagueMap, DraftPickTradesInLeagueMap, DraftPicksInDraftMap, PlayersInSportMap, Topic, Location, SportType } from '@sleeperhq/mini-core/declarations/types';
1
+ import { User, League, LeaguesMap, RostersInLeagueMap, UserMap, MatchupsInLeagueMap, UsersInLeagueMap, PlayoffsInLeagueMap, TransactionsInLeagueMap, TransactionsMap, SportInfoMap, DraftsInLeagueMap, DraftPickTradesInLeagueMap, DraftPicksInDraftMap, PlayersInSportMap, Topic, SportType } from '@sleeperhq/mini-core/declarations/types';
2
2
  import type { SleeperActions } from '@sleeperhq/mini-core/declarations/sleeper_actions';
3
3
  declare class SleeperContext {
4
4
  static apiLevel: string;
@@ -22,7 +22,6 @@ declare class SleeperContext {
22
22
  playersInSportMap: PlayersInSportMap;
23
23
  podcasts: Topic[][];
24
24
  videos: Topic[][];
25
- location: Location;
26
25
  actions: SleeperActions;
27
26
  }
28
27
  export default SleeperContext;
@@ -1,6 +1,5 @@
1
1
  import React, { PureComponent } from 'react';
2
2
  import { TextProps } from 'react-native';
3
-
4
3
  type Props = {
5
4
  color?: string;
6
5
  inheritStyles?: boolean;
@@ -21,4 +21,4 @@ export type Props = {
21
21
  aspectRatio?: number;
22
22
  confirmationFunction?: (nextSelection: 'on' | 'off', continueAction: () => void) => void;
23
23
  };
24
- export declare const AppIconSwitch: React.MemoExoticComponent<({ height, options, value, width, onChange, containerStyle, toggleStyle, aspectRatio, confirmationFunction }: Props) => React.JSX.Element>;
24
+ export declare const AppIconSwitch: React.NamedExoticComponent<Props>;
@@ -21,11 +21,9 @@ export type Mini = {
21
21
  entitlements?: Entitlement[];
22
22
  headerOptions?: HeaderOptions;
23
23
  metadata?: Metadata;
24
- };
25
- export type Location = {
26
- state: string;
27
- country: string;
28
- hasPermission: 'pending' | 'yes' | 'no';
24
+ leagueIds?: string[];
25
+ ownerId?: string;
26
+ ownerName?: string;
29
27
  };
30
28
  export type VersionMap = Record<string, Mini>;
31
29
  export type ToastConfig = Omit<ToastConfigOriginal, 'icon'> & {
@@ -18,22 +18,24 @@ export type Scalars = {
18
18
  Boolean: boolean;
19
19
  Int: number;
20
20
  Float: number;
21
- /** JSON */
22
21
  Json: {
23
22
  [key: string]: any;
24
23
  };
25
- /** Lists */
26
24
  List: string[];
27
- /** Map / Dictionary */
25
+ LocalizedJson: {
26
+ [key: string]: any;
27
+ };
28
+ LocalizedMap: {
29
+ [key: string]: any;
30
+ };
31
+ LocalizedString: string;
28
32
  Map: {
29
33
  [key: string]: any;
30
34
  };
31
35
  MapWithSnowflakeKey: {
32
36
  [key: string]: any;
33
37
  };
34
- /** Sets */
35
38
  Set: string[];
36
- /** Snowflake ID */
37
39
  Snowflake: string;
38
40
  SnowflakeList: string[];
39
41
  SnowflakeSet: string[];
@@ -65,6 +67,7 @@ export type DraftPick = {
65
67
  pick_no?: Maybe<Scalars['Int']>;
66
68
  picked_by?: Maybe<Scalars['Snowflake']>;
67
69
  player_id?: Maybe<Scalars['String']>;
70
+ reactions?: Maybe<Scalars['Map']>;
68
71
  };
69
72
  export type League = {
70
73
  __typename?: 'League';
@@ -136,6 +139,7 @@ export type MatchupLeg = {
136
139
  round?: Maybe<Scalars['Int']>;
137
140
  starters?: Maybe<Scalars['List']>;
138
141
  starters_games?: Maybe<Scalars['Map']>;
142
+ subs?: Maybe<Scalars['Map']>;
139
143
  };
140
144
  export type Player = {
141
145
  __typename?: 'Player';
@@ -174,6 +178,9 @@ export type Player = {
174
178
  status?: Maybe<Scalars['String']>;
175
179
  swish_id?: Maybe<Scalars['Int']>;
176
180
  team?: Maybe<Scalars['String']>;
181
+ team_abbr?: Maybe<Scalars['String']>;
182
+ team_changed_at?: Maybe<Scalars['Int']>;
183
+ username?: Maybe<Scalars['String']>;
177
184
  weight?: Maybe<Scalars['String']>;
178
185
  yahoo_id?: Maybe<Scalars['Int']>;
179
186
  years_exp?: Maybe<Scalars['Int']>;
@@ -213,23 +220,28 @@ export type Topic = {
213
220
  channel_tags?: Maybe<Scalars['Set']>;
214
221
  client_id?: Maybe<Scalars['String']>;
215
222
  created?: Maybe<Scalars['Int']>;
223
+ engagement_score?: Maybe<Scalars['Int']>;
216
224
  hidden?: Maybe<Scalars['Boolean']>;
217
225
  last_message_id?: Maybe<Scalars['Snowflake']>;
218
226
  last_pinned_message_id?: Maybe<Scalars['Snowflake']>;
219
227
  last_read_id?: Maybe<Scalars['Snowflake']>;
228
+ metadata?: Maybe<Scalars['Map']>;
220
229
  num_messages?: Maybe<Scalars['Int']>;
221
230
  num_viewers?: Maybe<Scalars['Int']>;
222
231
  pinned?: Maybe<Scalars['Boolean']>;
223
232
  player_tags?: Maybe<Scalars['Set']>;
224
233
  pushed_by?: Maybe<Scalars['Json']>;
234
+ reactions?: Maybe<Scalars['Map']>;
225
235
  score?: Maybe<Scalars['Int']>;
226
236
  shadowed?: Maybe<Scalars['Boolean']>;
227
237
  shard_max?: Maybe<Scalars['Int']>;
228
238
  shard_min?: Maybe<Scalars['Int']>;
229
- title?: Maybe<Scalars['String']>;
230
- title_map?: Maybe<Scalars['Json']>;
239
+ title?: Maybe<Scalars['LocalizedString']>;
240
+ title_map?: Maybe<Scalars['LocalizedJson']>;
241
+ top_message_id?: Maybe<Scalars['Snowflake']>;
231
242
  topic_id?: Maybe<Scalars['Snowflake']>;
232
243
  upvotes?: Maybe<Scalars['Int']>;
244
+ user_reactions?: Maybe<Array<Maybe<TopicReaction>>>;
233
245
  };
234
246
  export type User = {
235
247
  __typename?: 'User';
@@ -242,11 +254,14 @@ export type User = {
242
254
  deleted?: Maybe<Scalars['Int']>;
243
255
  display_name?: Maybe<Scalars['String']>;
244
256
  email?: Maybe<Scalars['String']>;
257
+ ip_country_code?: Maybe<Scalars['String']>;
258
+ ip_region_codes?: Maybe<Array<Maybe<Scalars['String']>>>;
245
259
  is_bot?: Maybe<Scalars['Boolean']>;
246
260
  metadata?: Maybe<Scalars['Json']>;
247
261
  notifications?: Maybe<Scalars['Map']>;
248
262
  pending?: Maybe<Scalars['Boolean']>;
249
263
  phone?: Maybe<Scalars['String']>;
264
+ picks?: Maybe<Scalars['Map']>;
250
265
  real_name?: Maybe<Scalars['String']>;
251
266
  solicitable?: Maybe<Scalars['Boolean']>;
252
267
  summoner_name?: Maybe<Scalars['String']>;
@@ -1,3 +1,4 @@
1
+ import React from 'react';
1
2
  import { TextStyle, ViewStyle } from 'react-native';
2
3
  export type ToastConfig = {
3
4
  text: string;
@@ -6,4 +7,6 @@ export type ToastConfig = {
6
7
  style?: ViewStyle;
7
8
  slideTop?: boolean;
8
9
  textStyle?: TextStyle;
10
+ renderLeft?: React.ReactNode;
11
+ showCloseButton?: boolean;
9
12
  };
@@ -8,7 +8,7 @@
8
8
  "@react-native-camera-roll/camera-roll": "5.2.0",
9
9
  "@react-native-community/blur": "4.4.0",
10
10
  "@react-native-community/datetimepicker": "2.6.2",
11
- "@react-native-community/hooks": "2.8.0",
11
+ "@react-native-community/hooks": "100.1.0",
12
12
  "@react-native-community/netinfo": "11.3.2",
13
13
  "@react-native-masked-view/masked-view": "0.3.1",
14
14
  "@react-native-picker/picker": "1.16.8",
@@ -18,8 +18,8 @@
18
18
  "@react-navigation/elements": "1.3.30",
19
19
  "@react-navigation/native": "6.1.17",
20
20
  "@react-navigation/stack": "6.4.0",
21
- "@shopify/flash-list": "1.7.2",
22
- "@sleeperhq/mini-core": "3.0.6",
21
+ "@shopify/flash-list": "1.7.6",
22
+ "@sleeperhq/mini-core": "4.0.0",
23
23
  "amazon-cognito-identity-js": "6.3.2",
24
24
  "crypto-js": "3.3.0",
25
25
  "decimal.js-light": "2.5.1",
@@ -28,7 +28,7 @@
28
28
  "path": "0.12.7",
29
29
  "react": "18.3.1",
30
30
  "react-freeze": "1.0.4",
31
- "react-native": "0.76.5",
31
+ "react-native": "0.77.2",
32
32
  "react-native-action-sheet": "2.2.0",
33
33
  "react-native-animatable": "1.3.3",
34
34
  "react-native-check-version": "1.0.20",
@@ -45,7 +45,7 @@
45
45
  "react-native-dropdownalert": "4.3.0",
46
46
  "react-native-emoji-rain": "0.0.1",
47
47
  "react-native-fs": "2.18.0",
48
- "react-native-gesture-handler": "2.21.0",
48
+ "react-native-gesture-handler": "2.22.0",
49
49
  "react-native-google-places-autocomplete": "2.4.1",
50
50
  "react-native-haptic-feedback": "1.6.0",
51
51
  "react-native-image-crop-picker": "0.41.6",
@@ -59,22 +59,20 @@
59
59
  "react-native-keyboard-aware-scroll-view": "0.9.5",
60
60
  "react-native-keyboard-spacer": "0.4.1",
61
61
  "react-native-linear-gradient": "2.8.3",
62
- "react-native-modal": "13.0.0",
63
62
  "react-native-modal-datetime-picker": "13.0.1",
64
63
  "react-native-parsed-text": "0.0.21",
65
64
  "react-native-permissions": "3.6.1",
66
65
  "react-native-platform-touchable": "1.1.1",
67
- "react-native-popup-dialog": "0.11.46",
68
- "react-native-popup-menu": "0.16.1",
66
+ "react-native-popup-menu": "0.17.0",
69
67
  "react-native-progress": "4.1.2",
70
68
  "react-native-qrcode-svg": "6.1.1",
71
- "react-native-reanimated": "3.16.5",
69
+ "react-native-reanimated": "3.17.1",
72
70
  "react-native-redash": "18.1.0",
73
- "react-native-safe-area-context": "4.10.5",
74
- "react-native-screens": "4.1.0",
71
+ "react-native-safe-area-context": "5.1.0",
72
+ "react-native-screens": "4.8.0",
75
73
  "react-native-section-list-get-item-layout": "2.2.3",
76
74
  "react-native-shake": "5.3.1",
77
- "react-native-share": "7.3.9",
75
+ "react-native-share": "12.0.5",
78
76
  "react-native-shimmer-placeholder": "1.0.36",
79
77
  "react-native-simple-toast": "1.1.3",
80
78
  "react-native-sms": "1.11.0",
@@ -82,27 +80,30 @@
82
80
  "react-native-sound": "0.11.1",
83
81
  "react-native-sound-level": "1.1.5",
84
82
  "react-native-spinkit": "1.5.1",
85
- "react-native-svg": "15.8.0",
83
+ "react-native-svg": "15.11.2",
86
84
  "react-native-swiper": "1.6.0-rc.3",
87
85
  "react-native-tab-view": "3.5.0",
88
86
  "react-native-tcp-socket": "6.0.6",
89
87
  "react-native-triangle": "0.0.9",
88
+ "react-native-turbo-image": "1.22.3",
90
89
  "react-native-vector-icons": "10.1.0",
91
- "react-native-video": "6.4.2",
90
+ "react-native-video": "6.10.2",
92
91
  "react-native-view-shot": "3.7.0",
93
- "react-native-webview": "13.10.4",
92
+ "react-native-webview": "13.13.5",
94
93
  "react-native-webp-format": "1.1.2",
95
94
  "regenerator-runtime": "0.13.11",
96
95
  "recyclerlistview": "4.2.0",
97
96
  "rn-prompt": "1.0.4"
98
97
  },
99
98
  "overrides": {
100
- "@callstack/repack": "0.5.3",
101
- "@react-native-async-storage/async-storage": "1.15.15",
99
+ "@callstack/repack": "5.0.7-c",
100
+ "@react-native-async-storage/async-storage": "2.2.0",
102
101
  "@react-native-community/audio-toolkit": "2.0.3",
103
102
  "react-native-chart-kit": "6.7.0",
104
103
  "react-native-circular-progress": "1.3.6",
105
- "react-native-fast-image": "8.5.11"
104
+ "react-native-fast-image": "8.5.11",
105
+ "react-native-modal": "13.0.1",
106
+ "react-native-popup-dialog": "0.11.46"
106
107
  },
107
108
  "requiredBy": {
108
109
  "amazon-cognito-identity-js": "flexfantasy"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sleeperhq/mini-core",
3
- "version": "3.0.6",
3
+ "version": "4.0.0",
4
4
  "description": "Core library frameworks for developing Sleeper Mini Apps.",
5
5
  "main": "index.ts",
6
6
  "types": "index.d.ts",
@@ -36,7 +36,7 @@
36
36
  "dependencies": {
37
37
  "@babel/plugin-transform-runtime": "7.25.9",
38
38
  "@babel/runtime": "7.26.0",
39
- "@callstack/repack": "blitzstudios/repack.git#callstack-repack-v5.0.0-gitpkg",
39
+ "@callstack/repack": "blitzstudios/repack.git#callstack-repack-v5.0.7-c-gitpkg",
40
40
  "@react-native-community/cli": "15.0.1",
41
41
  "@react-native-community/cli-platform-android": "15.0.1",
42
42
  "@react-native-community/cli-platform-apple": "15.0.1",
@@ -48,6 +48,7 @@
48
48
  "react-native-fast-image": "https://github.com/blitzstudios/react-native-fast-image.git#release/1.4",
49
49
  "react-native-linear-gradient": "2.8.3",
50
50
  "react-native-rename": "blitzstudios/react-native-rename.git#react-native-rename-v3.2.17-gitpkg",
51
+ "react-native-turbo-image": "1.22.3",
51
52
  "regenerator-runtime": "0.13.11",
52
53
  "rx": "4.1.0",
53
54
  "string-replace-loader": "3.1.0",
@@ -56,19 +57,18 @@
56
57
  },
57
58
  "peerDependencies": {
58
59
  "react": "18.3.1",
59
- "react-native": "0.76.5",
60
- "react-native-svg": "15.8.0"
60
+ "react-native": "0.77.2",
61
+ "react-native-svg": "15.11.2"
61
62
  },
62
63
  "devDependencies": {
63
64
  "@babel/core": "7.26.0",
64
65
  "@babel/preset-typescript": "7.26.0",
65
- "@react-native-community/eslint-config": "2.0.0",
66
- "@react-native/babel-preset": "0.76.5",
67
- "@react-native/typescript-config": "0.76.5",
66
+ "@react-native/babel-preset": "0.77.2",
67
+ "@react-native/eslint-config": "0.77.2",
68
+ "@react-native/typescript-config": "0.77.2",
68
69
  "@types/react": "18.2.31",
69
70
  "@typescript-eslint/eslint-plugin": "5.62.0",
70
71
  "@typescript-eslint/parser": "5.62.0",
71
- "babel-jest": "26.6.3",
72
72
  "eslint": "8.38.0",
73
73
  "jest": "26.6.3",
74
74
  "lodash": "4.17.21",
@@ -1,3 +0,0 @@
1
- export default Jersey;
2
- declare const Jersey: React.NamedExoticComponent<object>;
3
- import React from 'react';