shufflecom-calculations 4.3.3 → 4.4.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "shufflecom-calculations",
3
- "version": "4.3.3",
3
+ "version": "4.4.1",
4
4
  "description": "",
5
5
  "types": "lib/index.d.ts",
6
6
  "main": "lib/index.js",
@@ -14,5 +14,5 @@
14
14
  },
15
15
  "author": "",
16
16
  "license": "ISC",
17
- "gitHead": "3d5d2ae67ace14d80a6d16becc6a2107d7f15080"
17
+ "gitHead": "ff84e45e6324b1b48851f1f63868ed6903dfb06b"
18
18
  }
@@ -6,7 +6,6 @@ import {
6
6
  SportsFixtureStatus,
7
7
  SportsMarketGroup,
8
8
  SportsMarketProvider,
9
- SportsMatchPhase,
10
9
  SportsMatchPhaseHomeAway,
11
10
  SportsMatchPhaseSummary,
12
11
  SportsMatchStatistics,
@@ -0,0 +1,20 @@
1
+ import { PrebuildBetFeaturedPrebuilds } from './prebuild-bet.types';
2
+ import { PopularSportsCompetitionsV2Info } from './sports-competition-fixture.types';
3
+ import { SportsContentFeaturedEvents, SportsContentFeaturedOutright } from './sports-content-fixture.types';
4
+ import { PaginatedSportsBoostedSelectionsInfo } from './sports-selection.types';
5
+ import { Nullable, SportsContentType } from './sports.types';
6
+
7
+ export class SportsContentWeight {
8
+ sportsContentType: SportsContentType;
9
+ weight: number;
10
+ }
11
+
12
+ export class SportsContentHomePage {
13
+ featuredEvents: Nullable<SportsContentFeaturedEvents>;
14
+ featuredOutright: Nullable<SportsContentFeaturedOutright>;
15
+ popularCompetitions: Nullable<PopularSportsCompetitionsV2Info>;
16
+ featuredPrebuilds: Nullable<PrebuildBetFeaturedPrebuilds>;
17
+ sportsCustomBoosts: Nullable<PaginatedSportsBoostedSelectionsInfo>;
18
+ /** Enabled content types with their weights, ordered by weight DESC. */
19
+ weights: SportsContentWeight[];
20
+ }
@@ -27,6 +27,7 @@ export type SportsMarketSelectionType = {
27
27
  name: string;
28
28
  isOutrightLike: boolean;
29
29
  shortName: string;
30
+ startTime: string;
30
31
  };
31
32
  competition: {
32
33
  id: string;
@@ -41,3 +42,12 @@ export type SportsMarketSelectionType = {
41
42
  };
42
43
  provider: SportsMarketProvider;
43
44
  };
45
+
46
+ export type SportsCustomBoostMarketSelectionType = SportsMarketSelectionType & {
47
+ boost: SportsMarketSelectionOddsBoost;
48
+ };
49
+
50
+ export class PaginatedSportsBoostedSelectionsInfo {
51
+ nodes: SportsCustomBoostMarketSelectionType[];
52
+ nextCursor: string | null;
53
+ }
@@ -1,5 +1,6 @@
1
1
  import BigNumber from 'bignumber.js';
2
2
  import { SportsMatchPhaseLabel } from './sports-match-state.types';
3
+ import { SportsCustomBoostMarketSelectionType } from './sports-selection.types';
3
4
 
4
5
  export enum SportsMarketProvider {
5
6
  SHUFFLE = 'SHUFFLE',
@@ -124,6 +125,29 @@ export enum SportsFixtureBannerType {
124
125
  SINGLE_ELIMINATION = 'SINGLE_ELIMINATION',
125
126
  }
126
127
 
128
+ /** SPORT_1..SPORT_6 are positional slots on the home page; each holds one popular sport's competitions. */
129
+ export enum SportsContentType {
130
+ HOME_FEATURED_EVENT = 'HOME_FEATURED_EVENT',
131
+ FEATURED_CUSTOM_BETS = 'FEATURED_CUSTOM_BETS',
132
+ FEATURED_OUTRIGHT = 'FEATURED_OUTRIGHT',
133
+ FEATURED_BOOSTS = 'FEATURED_BOOSTS',
134
+ SPORT_1 = 'SPORT_1',
135
+ SPORT_2 = 'SPORT_2',
136
+ SPORT_3 = 'SPORT_3',
137
+ SPORT_4 = 'SPORT_4',
138
+ SPORT_5 = 'SPORT_5',
139
+ SPORT_6 = 'SPORT_6',
140
+ }
141
+
142
+ export const REGULAR_SPORT_CONTENT_TYPES = [
143
+ SportsContentType.SPORT_1,
144
+ SportsContentType.SPORT_2,
145
+ SportsContentType.SPORT_3,
146
+ SportsContentType.SPORT_4,
147
+ SportsContentType.SPORT_5,
148
+ SportsContentType.SPORT_6,
149
+ ];
150
+
127
151
  export enum SportsMarketSelectionTeam {
128
152
  HOME = 'HOME',
129
153
  AWAY = 'AWAY',
@@ -665,6 +689,7 @@ export class DisplayGroup extends BaseDisplayGroup {
665
689
  groupDisplayType: SportsGroupedSelectionsDisplayType;
666
690
  playerMarkets: PlayerMarket[] | null;
667
691
  groups: Partial<Record<SportsMarketGroup, number>> | null; // For SGM sub-groups
692
+ cmsDescriptionSlug: string | null;
668
693
  }
669
694
 
670
695
  export class SelectionGroup {
@@ -726,6 +751,7 @@ export class SgmSubGroup {
726
751
  export class SportsMarketInfo {
727
752
  odds: SportsNewMarketOddsUpdate[];
728
753
  display: DisplayGroup[];
754
+ customBoosts: SportsCustomBoostMarketSelectionType[];
729
755
  updatedAt: Nullable<Date>;
730
756
  sgmSubGroups: Nullable<SgmSubGroup[]>;
731
757
  }