@maestro_io/maestro-web-sdk 5.1.2 → 5.2.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.
Files changed (177) hide show
  1. package/dist/1.maestro-web-sdk.esm.js +1 -1
  2. package/dist/1.maestro-web-sdk.esm.js.map +1 -1
  3. package/dist/10.maestro-web-sdk.esm.js +1 -1
  4. package/dist/10.maestro-web-sdk.esm.js.map +1 -1
  5. package/dist/11.maestro-web-sdk.esm.js +1 -1
  6. package/dist/11.maestro-web-sdk.esm.js.map +1 -1
  7. package/dist/12.maestro-web-sdk.esm.js +1 -1
  8. package/dist/12.maestro-web-sdk.esm.js.map +1 -1
  9. package/dist/13.maestro-web-sdk.esm.js +1 -1
  10. package/dist/13.maestro-web-sdk.esm.js.map +1 -1
  11. package/dist/14.maestro-web-sdk.esm.js +1 -1
  12. package/dist/14.maestro-web-sdk.esm.js.map +1 -1
  13. package/dist/15.maestro-web-sdk.esm.js +1 -1
  14. package/dist/15.maestro-web-sdk.esm.js.map +1 -1
  15. package/dist/16.maestro-web-sdk.esm.js +1 -1
  16. package/dist/16.maestro-web-sdk.esm.js.map +1 -1
  17. package/dist/17.maestro-web-sdk.esm.js +1 -1
  18. package/dist/17.maestro-web-sdk.esm.js.map +1 -1
  19. package/dist/18.maestro-web-sdk.esm.js +1 -1
  20. package/dist/18.maestro-web-sdk.esm.js.map +1 -1
  21. package/dist/19.maestro-web-sdk.esm.js +1 -1
  22. package/dist/19.maestro-web-sdk.esm.js.map +1 -1
  23. package/dist/2.maestro-web-sdk.esm.js +1 -1
  24. package/dist/20.maestro-web-sdk.esm.js +1 -1
  25. package/dist/20.maestro-web-sdk.esm.js.map +1 -1
  26. package/dist/21.maestro-web-sdk.esm.js +1 -1
  27. package/dist/21.maestro-web-sdk.esm.js.map +1 -1
  28. package/dist/22.maestro-web-sdk.esm.js +1 -1
  29. package/dist/22.maestro-web-sdk.esm.js.map +1 -1
  30. package/dist/23.maestro-web-sdk.esm.js +1 -1
  31. package/dist/23.maestro-web-sdk.esm.js.map +1 -1
  32. package/dist/24.maestro-web-sdk.esm.js +1 -1
  33. package/dist/24.maestro-web-sdk.esm.js.map +1 -1
  34. package/dist/25.maestro-web-sdk.esm.js +1 -1
  35. package/dist/25.maestro-web-sdk.esm.js.map +1 -1
  36. package/dist/26.maestro-web-sdk.esm.js +1 -1
  37. package/dist/26.maestro-web-sdk.esm.js.map +1 -1
  38. package/dist/27.maestro-web-sdk.esm.js +1 -1
  39. package/dist/27.maestro-web-sdk.esm.js.map +1 -1
  40. package/dist/28.maestro-web-sdk.esm.js +1 -1
  41. package/dist/28.maestro-web-sdk.esm.js.map +1 -1
  42. package/dist/29.maestro-web-sdk.esm.js +1 -1
  43. package/dist/29.maestro-web-sdk.esm.js.map +1 -1
  44. package/dist/3.maestro-web-sdk.esm.js +1 -1
  45. package/dist/3.maestro-web-sdk.esm.js.map +1 -1
  46. package/dist/30.maestro-web-sdk.esm.js +1 -1
  47. package/dist/30.maestro-web-sdk.esm.js.map +1 -1
  48. package/dist/31.maestro-web-sdk.esm.js +1 -1
  49. package/dist/31.maestro-web-sdk.esm.js.map +1 -1
  50. package/dist/32.maestro-web-sdk.esm.js +1 -1
  51. package/dist/32.maestro-web-sdk.esm.js.map +1 -1
  52. package/dist/33.maestro-web-sdk.esm.js +1 -1
  53. package/dist/33.maestro-web-sdk.esm.js.map +1 -1
  54. package/dist/34.maestro-web-sdk.esm.js +1 -1
  55. package/dist/34.maestro-web-sdk.esm.js.map +1 -1
  56. package/dist/35.maestro-web-sdk.esm.js +1 -1
  57. package/dist/35.maestro-web-sdk.esm.js.map +1 -1
  58. package/dist/36.maestro-web-sdk.esm.js +1 -1
  59. package/dist/36.maestro-web-sdk.esm.js.map +1 -1
  60. package/dist/37.maestro-web-sdk.esm.js +1 -1
  61. package/dist/37.maestro-web-sdk.esm.js.map +1 -1
  62. package/dist/38.maestro-web-sdk.esm.js +1 -1
  63. package/dist/38.maestro-web-sdk.esm.js.map +1 -1
  64. package/dist/39.maestro-web-sdk.esm.js +2 -0
  65. package/dist/39.maestro-web-sdk.esm.js.map +1 -0
  66. package/dist/4.maestro-web-sdk.esm.js +1 -1
  67. package/dist/4.maestro-web-sdk.esm.js.map +1 -1
  68. package/dist/40.maestro-web-sdk.esm.js +2 -0
  69. package/dist/40.maestro-web-sdk.esm.js.map +1 -0
  70. package/dist/5.maestro-web-sdk.esm.js +1 -1
  71. package/dist/5.maestro-web-sdk.esm.js.map +1 -1
  72. package/dist/6.maestro-web-sdk.esm.js +1 -1
  73. package/dist/6.maestro-web-sdk.esm.js.map +1 -1
  74. package/dist/7.maestro-web-sdk.esm.js +1 -1
  75. package/dist/7.maestro-web-sdk.esm.js.map +1 -1
  76. package/dist/8.maestro-web-sdk.esm.js +1 -1
  77. package/dist/8.maestro-web-sdk.esm.js.map +1 -1
  78. package/dist/9.maestro-web-sdk.esm.js +1 -1
  79. package/dist/9.maestro-web-sdk.esm.js.map +1 -1
  80. package/dist/index.d.ts +4 -1
  81. package/dist/maestro-web-sdk.esm.js +3 -3
  82. package/dist/maestro-web-sdk.esm.js.map +1 -1
  83. package/dist/maestro-web-sdk.umd.js +3 -3
  84. package/dist/maestro-web-sdk.umd.js.map +1 -1
  85. package/dist/package.json +1 -1
  86. package/dist/src/components/atoms/SvgIcon/AddIcon.d.ts +3 -0
  87. package/dist/src/components/atoms/SvgIcon/AddIcon.js +6 -0
  88. package/dist/src/components/atoms/SvgIcon/Icon.js +2 -0
  89. package/dist/src/components/core/PanelManager/PanelManager.js +5 -3
  90. package/dist/src/components/molecules/NetworkDialog/NetworkDialog.d.ts +11 -0
  91. package/dist/src/components/molecules/NetworkDialog/NetworkDialog.js +34 -0
  92. package/dist/src/components/molecules/NetworkDialog/index.d.ts +2 -0
  93. package/dist/src/components/molecules/NetworkDialog/index.js +2 -0
  94. package/dist/src/components/molecules/NetworkError/NetworkError.d.ts +104 -0
  95. package/dist/src/components/molecules/NetworkError/NetworkError.js +26 -0
  96. package/dist/src/components/molecules/NetworkError/index.d.ts +2 -0
  97. package/dist/src/components/molecules/NetworkError/index.js +2 -0
  98. package/dist/src/components/molecules/PanelNavButton/PanelNavButton.d.ts +1 -0
  99. package/dist/src/components/molecules/PanelNavButton/PanelNavButton.js +16 -7
  100. package/dist/src/components/organisms/PanelNavigation/PanelNavigation.d.ts +1 -0
  101. package/dist/src/components/organisms/PanelNavigation/PanelNavigation.js +11 -7
  102. package/dist/src/development/MaestroEventDelegate.js +1 -0
  103. package/dist/src/helpers/site.d.ts +1 -0
  104. package/dist/src/helpers/site.js +6 -0
  105. package/dist/src/helpers/siteConfig.d.ts +1 -0
  106. package/dist/src/helpers/siteConfig.js +5 -0
  107. package/dist/src/models/IPanel.d.ts +1 -1
  108. package/dist/src/models/IPanel.js +1 -1
  109. package/dist/src/modules/espn/bets/services/BetsService.js +5 -5
  110. package/dist/src/modules/espn/bets/view/BetsView.js +1 -1
  111. package/dist/src/modules/espn/components/TabLoadError/TabLoadError.d.ts +96 -0
  112. package/dist/src/modules/espn/components/TabLoadError/TabLoadError.js +14 -0
  113. package/dist/src/modules/espn/components/TabLoadError/index.d.ts +2 -0
  114. package/dist/src/modules/espn/components/TabLoadError/index.js +2 -0
  115. package/dist/src/modules/espn/fantasy/components/TournamentOverflowQR/TournamentOverflowQR.d.ts +5 -5
  116. package/dist/src/modules/espn/fantasy/components/TournamentOverflowQR/TournamentOverflowQR.js +7 -73
  117. package/dist/src/modules/espn/fantasy/services/FantasyService.js +4 -1
  118. package/dist/src/modules/espn/fantasy/view/FantasyItemView.js +1 -1
  119. package/dist/src/modules/espn/fantasy/view/FantasyView.js +3 -2
  120. package/dist/src/modules/espn/fantasy/view-model/FantasyViewModel.FantasyPolling.d.ts +1 -1
  121. package/dist/src/modules/espn/fantasy/view-model/FantasyViewModel.FantasyPolling.js +10 -7
  122. package/dist/src/modules/espn/fantasy/view-model/FantasyViewModel.LeagueManagerPolling.d.ts +1 -1
  123. package/dist/src/modules/espn/fantasy/view-model/FantasyViewModel.LeagueManagerPolling.js +10 -7
  124. package/dist/src/modules/espn/fantasy/view-model/FantasyViewModel.TournamentPolling.d.ts +1 -1
  125. package/dist/src/modules/espn/fantasy/view-model/FantasyViewModel.TournamentPolling.js +10 -7
  126. package/dist/src/modules/espn/fantasy/view-model/FantasyViewModel.d.ts +1 -0
  127. package/dist/src/modules/espn/fantasy/view-model/FantasyViewModel.js +42 -32
  128. package/dist/src/modules/espn/key-plays/view/KeyPlayErrorStateView.js +1 -1
  129. package/dist/src/modules/espn/shop/services/ShopService.js +1 -1
  130. package/dist/src/modules/espn/shop/view/ShopView.js +1 -1
  131. package/dist/src/modules/espn/stats/services/StatsService.js +2 -2
  132. package/dist/src/modules/espn/stats/view/StatsView.js +1 -1
  133. package/dist/src/modules/fox/components/TabLoadError/TabLoadError.d.ts +96 -0
  134. package/dist/src/modules/fox/components/TabLoadError/TabLoadError.js +19 -0
  135. package/dist/src/modules/fox/components/TabLoadError/index.d.ts +2 -0
  136. package/dist/src/modules/fox/components/TabLoadError/index.js +2 -0
  137. package/dist/src/modules/fox/multi-view/interfaces/IMultiViewViewModel.d.ts +3 -0
  138. package/dist/src/modules/fox/multi-view/interfaces/IMultiViewViewModel.js +1 -0
  139. package/dist/src/modules/fox/multi-view/services/MultiViewService.d.ts +104 -0
  140. package/dist/src/modules/fox/multi-view/services/MultiViewService.js +97 -0
  141. package/dist/src/modules/fox/multi-view/types.d.ts +48 -42
  142. package/dist/src/modules/fox/multi-view/types.js +79 -82
  143. package/dist/src/modules/fox/multi-view/view/BuildYourOwn/BuildYourOwn.d.ts +7 -0
  144. package/dist/src/modules/fox/multi-view/view/BuildYourOwn/BuildYourOwn.js +99 -0
  145. package/dist/src/modules/fox/multi-view/view/BuildYourOwn/index.d.ts +2 -0
  146. package/dist/src/modules/fox/multi-view/view/BuildYourOwn/index.js +2 -0
  147. package/dist/src/modules/fox/multi-view/view/CuratedMultiview/CuratedMultiviews.d.ts +8 -0
  148. package/dist/src/modules/fox/multi-view/view/CuratedMultiview/CuratedMultiviews.js +92 -0
  149. package/dist/src/modules/fox/multi-view/view/CuratedMultiview/index.d.ts +2 -0
  150. package/dist/src/modules/fox/multi-view/view/CuratedMultiview/index.js +2 -0
  151. package/dist/src/modules/fox/multi-view/view/FoxMultiView.d.ts +1 -0
  152. package/dist/src/modules/fox/multi-view/view/FoxMultiView.js +65 -2
  153. package/dist/src/modules/fox/multi-view/view/components/BuildYourOwnTabs/BuildYourOwnTabs.d.ts +8 -0
  154. package/dist/src/modules/fox/multi-view/view/components/BuildYourOwnTabs/BuildYourOwnTabs.js +30 -0
  155. package/dist/src/modules/fox/multi-view/view/components/BuildYourOwnTabs/index.d.ts +2 -0
  156. package/dist/src/modules/fox/multi-view/view/components/BuildYourOwnTabs/index.js +2 -0
  157. package/dist/src/modules/fox/multi-view/view/components/CustomMultiviewStreamsCard/CustomMultiviewStreamsCard.d.ts +118 -0
  158. package/dist/src/modules/fox/multi-view/view/components/CustomMultiviewStreamsCard/CustomMultiviewStreamsCard.js +51 -0
  159. package/dist/src/modules/fox/multi-view/view/components/CustomMultiviewStreamsCard/index.d.ts +2 -0
  160. package/dist/src/modules/fox/multi-view/view/components/CustomMultiviewStreamsCard/index.js +2 -0
  161. package/dist/src/modules/fox/multi-view/view/components/LayoutSelector/LayoutSelector.d.ts +1 -1
  162. package/dist/src/modules/fox/multi-view/view/components/LayoutSelector/LayoutSelector.js +11 -14
  163. package/dist/src/modules/fox/multi-view/view/components/curated-multiview-card/CuratedMultiviewCard.d.ts +101 -0
  164. package/dist/src/modules/fox/multi-view/view/components/curated-multiview-card/CuratedMultiviewCard.js +41 -0
  165. package/dist/src/modules/fox/multi-view/view/components/curated-multiview-card/index.d.ts +2 -0
  166. package/dist/src/modules/fox/multi-view/view/components/curated-multiview-card/index.js +2 -0
  167. package/dist/src/modules/fox/multi-view/view-model/MultiViewViewModel.d.ts +84 -0
  168. package/dist/src/modules/fox/multi-view/view-model/MultiViewViewModel.js +509 -0
  169. package/dist/src/modules/fox/multi-view/view-model/index.d.ts +1 -0
  170. package/dist/src/modules/fox/multi-view/view-model/index.js +1 -0
  171. package/dist/src/services/NetworkManager/NetworkManager.js +1 -1
  172. package/dist/src/services/NetworkManager/errors.d.ts +3 -1
  173. package/dist/src/services/NetworkManager/errors.js +15 -1
  174. package/dist/src/services/StaticService/StaticService.js +1 -0
  175. package/dist/src/view-models/MaestroEventViewModel.d.ts +2 -0
  176. package/dist/src/view-models/MaestroEventViewModel.js +17 -1
  177. package/package.json +1 -1
@@ -0,0 +1,96 @@
1
+ /// <reference types="prop-types" />
2
+ import { WithFocusableProps } from '@/external/spatial-navigation';
3
+ import React from 'react';
4
+ import './TabLoadError.styles.css';
5
+ declare const _default: {
6
+ new (props: (object & WithFocusableProps) | Readonly<object & WithFocusableProps>): {
7
+ state: import("../../../../external/spatial-navigation/withFocusable").WithFocusableState;
8
+ navigation: import("../../../../external/spatial-navigation/spatialNavigation").default;
9
+ getChildContext(): {
10
+ parentFocusKey: string;
11
+ };
12
+ setFocus: (focusKey: string) => void;
13
+ navigateByDirection: (direction: import("../../../../external/spatial-navigation/utils").Direction, details?: import("../../../../external/spatial-navigation/utils").Details) => void;
14
+ stealFocus: () => void;
15
+ onUpdateFocus: (focused: boolean) => void;
16
+ onUpdateHasFocusedChild: (hasFocusedChild: boolean) => void;
17
+ onEnterPressHandler: (details: import("../../../../external/spatial-navigation/utils").Details) => void;
18
+ onClickPressHandler: (details: import("../../../../external/spatial-navigation/utils").Details) => void;
19
+ onEnterReleaseHandler: () => void;
20
+ onBackPressHandler: (details: import("../../../../external/spatial-navigation/utils").Details) => void;
21
+ onArrowPressHandler: (direction: import("../../../../external/spatial-navigation/utils").Direction, details: import("../../../../external/spatial-navigation/utils").Details) => boolean | void;
22
+ onBecameFocusedHandler: (layout: import("../../../../external/spatial-navigation/utils").Layout, details: import("../../../../external/spatial-navigation/utils").Details) => void;
23
+ onBecameBlurredHandler: (layout: import("../../../../external/spatial-navigation/utils").Layout, details: import("../../../../external/spatial-navigation/utils").Details) => void;
24
+ componentDidMount(): void;
25
+ componentDidUpdate(): void;
26
+ componentWillUnmount(): void;
27
+ render(): React.ReactElement<object & WithFocusableProps, string | React.JSXElementConstructor<any>>;
28
+ context: any;
29
+ setState<K extends keyof import("../../../../external/spatial-navigation/withFocusable").WithFocusableState>(state: import("../../../../external/spatial-navigation/withFocusable").WithFocusableState | ((prevState: Readonly<import("../../../../external/spatial-navigation/withFocusable").WithFocusableState>, props: Readonly<object & WithFocusableProps>) => import("../../../../external/spatial-navigation/withFocusable").WithFocusableState | Pick<import("../../../../external/spatial-navigation/withFocusable").WithFocusableState, K> | null) | Pick<import("../../../../external/spatial-navigation/withFocusable").WithFocusableState, K> | null, callback?: (() => void) | undefined): void;
30
+ forceUpdate(callback?: (() => void) | undefined): void;
31
+ readonly props: Readonly<object & WithFocusableProps> & Readonly<{
32
+ children?: React.ReactNode;
33
+ }>;
34
+ refs: {
35
+ [key: string]: React.ReactInstance;
36
+ };
37
+ shouldComponentUpdate?(nextProps: Readonly<object & WithFocusableProps>, nextState: Readonly<import("../../../../external/spatial-navigation/withFocusable").WithFocusableState>, nextContext: any): boolean;
38
+ componentDidCatch?(error: Error, errorInfo: React.ErrorInfo): void;
39
+ getSnapshotBeforeUpdate?(prevProps: Readonly<object & WithFocusableProps>, prevState: Readonly<import("../../../../external/spatial-navigation/withFocusable").WithFocusableState>): any;
40
+ componentWillMount?(): void;
41
+ UNSAFE_componentWillMount?(): void;
42
+ componentWillReceiveProps?(nextProps: Readonly<object & WithFocusableProps>, nextContext: any): void;
43
+ UNSAFE_componentWillReceiveProps?(nextProps: Readonly<object & WithFocusableProps>, nextContext: any): void;
44
+ componentWillUpdate?(nextProps: Readonly<object & WithFocusableProps>, nextState: Readonly<import("../../../../external/spatial-navigation/withFocusable").WithFocusableState>, nextContext: any): void;
45
+ UNSAFE_componentWillUpdate?(nextProps: Readonly<object & WithFocusableProps>, nextState: Readonly<import("../../../../external/spatial-navigation/withFocusable").WithFocusableState>, nextContext: any): void;
46
+ };
47
+ new (props: object & WithFocusableProps, context: any): {
48
+ state: import("../../../../external/spatial-navigation/withFocusable").WithFocusableState;
49
+ navigation: import("../../../../external/spatial-navigation/spatialNavigation").default;
50
+ getChildContext(): {
51
+ parentFocusKey: string;
52
+ };
53
+ setFocus: (focusKey: string) => void;
54
+ navigateByDirection: (direction: import("../../../../external/spatial-navigation/utils").Direction, details?: import("../../../../external/spatial-navigation/utils").Details) => void;
55
+ stealFocus: () => void;
56
+ onUpdateFocus: (focused: boolean) => void;
57
+ onUpdateHasFocusedChild: (hasFocusedChild: boolean) => void;
58
+ onEnterPressHandler: (details: import("../../../../external/spatial-navigation/utils").Details) => void;
59
+ onClickPressHandler: (details: import("../../../../external/spatial-navigation/utils").Details) => void;
60
+ onEnterReleaseHandler: () => void;
61
+ onBackPressHandler: (details: import("../../../../external/spatial-navigation/utils").Details) => void;
62
+ onArrowPressHandler: (direction: import("../../../../external/spatial-navigation/utils").Direction, details: import("../../../../external/spatial-navigation/utils").Details) => boolean | void;
63
+ onBecameFocusedHandler: (layout: import("../../../../external/spatial-navigation/utils").Layout, details: import("../../../../external/spatial-navigation/utils").Details) => void;
64
+ onBecameBlurredHandler: (layout: import("../../../../external/spatial-navigation/utils").Layout, details: import("../../../../external/spatial-navigation/utils").Details) => void;
65
+ componentDidMount(): void;
66
+ componentDidUpdate(): void;
67
+ componentWillUnmount(): void;
68
+ render(): React.ReactElement<object & WithFocusableProps, string | React.JSXElementConstructor<any>>;
69
+ context: any;
70
+ setState<K extends keyof import("../../../../external/spatial-navigation/withFocusable").WithFocusableState>(state: import("../../../../external/spatial-navigation/withFocusable").WithFocusableState | ((prevState: Readonly<import("../../../../external/spatial-navigation/withFocusable").WithFocusableState>, props: Readonly<object & WithFocusableProps>) => import("../../../../external/spatial-navigation/withFocusable").WithFocusableState | Pick<import("../../../../external/spatial-navigation/withFocusable").WithFocusableState, K> | null) | Pick<import("../../../../external/spatial-navigation/withFocusable").WithFocusableState, K> | null, callback?: (() => void) | undefined): void;
71
+ forceUpdate(callback?: (() => void) | undefined): void;
72
+ readonly props: Readonly<object & WithFocusableProps> & Readonly<{
73
+ children?: React.ReactNode;
74
+ }>;
75
+ refs: {
76
+ [key: string]: React.ReactInstance;
77
+ };
78
+ shouldComponentUpdate?(nextProps: Readonly<object & WithFocusableProps>, nextState: Readonly<import("../../../../external/spatial-navigation/withFocusable").WithFocusableState>, nextContext: any): boolean;
79
+ componentDidCatch?(error: Error, errorInfo: React.ErrorInfo): void;
80
+ getSnapshotBeforeUpdate?(prevProps: Readonly<object & WithFocusableProps>, prevState: Readonly<import("../../../../external/spatial-navigation/withFocusable").WithFocusableState>): any;
81
+ componentWillMount?(): void;
82
+ UNSAFE_componentWillMount?(): void;
83
+ componentWillReceiveProps?(nextProps: Readonly<object & WithFocusableProps>, nextContext: any): void;
84
+ UNSAFE_componentWillReceiveProps?(nextProps: Readonly<object & WithFocusableProps>, nextContext: any): void;
85
+ componentWillUpdate?(nextProps: Readonly<object & WithFocusableProps>, nextState: Readonly<import("../../../../external/spatial-navigation/withFocusable").WithFocusableState>, nextContext: any): void;
86
+ UNSAFE_componentWillUpdate?(nextProps: Readonly<object & WithFocusableProps>, nextState: Readonly<import("../../../../external/spatial-navigation/withFocusable").WithFocusableState>, nextContext: any): void;
87
+ };
88
+ contextTypes: {
89
+ parentFocusKey: import("prop-types").Requireable<string>;
90
+ };
91
+ childContextTypes: {
92
+ parentFocusKey: import("prop-types").Requireable<string>;
93
+ };
94
+ contextType?: React.Context<any> | undefined;
95
+ };
96
+ export default _default;
@@ -0,0 +1,19 @@
1
+ import { withFocusable, } from '@/external/spatial-navigation';
2
+ import React from 'react';
3
+ import './TabLoadError.styles.css';
4
+ import ActionButton from '@/components/molecules/ActionButton';
5
+ const TabLoadErrorView = (props) => {
6
+ const { focused, onEnterPress } = props;
7
+ const setHeight = (element) => {
8
+ if (!element)
9
+ return;
10
+ const rect = element.getBoundingClientRect();
11
+ element.style.height = `${window.innerHeight - rect.top}px`;
12
+ };
13
+ return (React.createElement("div", { className: "tab-load-error", ref: setHeight },
14
+ React.createElement("h3", { className: "T70" }, "Oops! Something went wrong."),
15
+ React.createElement("p", { className: "T20" }, 'We are having trouble loading Multiview right now. Please try again'),
16
+ React.createElement("div", { className: "fox" },
17
+ React.createElement(ActionButton, { "data-focused": focused, onEnterPress: onEnterPress }, "Try Again"))));
18
+ };
19
+ export default withFocusable()(TabLoadErrorView);
@@ -0,0 +1,2 @@
1
+ import TabLoadErrorView from './TabLoadError';
2
+ export default TabLoadErrorView;
@@ -0,0 +1,2 @@
1
+ import TabLoadErrorView from './TabLoadError';
2
+ export default TabLoadErrorView;
@@ -0,0 +1,3 @@
1
+ export interface IMultiViewViewModel {
2
+ cleanup(): void;
3
+ }
@@ -0,0 +1,104 @@
1
+ import { HttpMethod } from '@/services/NetworkManager/NetworkManager';
2
+ import { MultiViewLayout } from '../types';
3
+ export type ProductAPIData = {
4
+ url: string;
5
+ method: HttpMethod;
6
+ headers: Record<string, string>;
7
+ callback?: (error: ProductAPIErrorPayload) => void;
8
+ };
9
+ export type ProductAPIErrorPayload = {
10
+ code: number;
11
+ message: string;
12
+ success: false;
13
+ data?: unknown;
14
+ };
15
+ export type MultiViewListingRequest = {
16
+ layoutId: string;
17
+ listings: Array<{
18
+ listingId: string;
19
+ callsign: string;
20
+ }>;
21
+ };
22
+ export type MultiViewListingResponse = {
23
+ multiviewId?: string;
24
+ callbackSeconds?: number;
25
+ };
26
+ export interface CuratedMultiviewResponse {
27
+ status: boolean;
28
+ data?: {
29
+ items?: CuratedMultiviewResponseItem[];
30
+ };
31
+ }
32
+ export interface CuratedMultiviewResponseItem {
33
+ entity_id?: string;
34
+ type?: string;
35
+ title?: string;
36
+ is_multiview?: boolean;
37
+ is_multiview_eligible?: boolean;
38
+ is_sportingevent?: boolean;
39
+ images?: {
40
+ still?: string;
41
+ series_list?: string;
42
+ };
43
+ location?: {
44
+ city?: string;
45
+ state?: string;
46
+ };
47
+ start_time?: string;
48
+ associated_listings?: Array<{
49
+ entity_id?: string;
50
+ title?: string;
51
+ }>;
52
+ multiview?: string[];
53
+ multiview_metadata?: CuratedMultiviewResponseItem[];
54
+ left_team?: CuratedMultiviewResponseItemTeam;
55
+ right_team?: CuratedMultiviewResponseItemTeam;
56
+ }
57
+ type CuratedMultiviewResponseItemTeam = {
58
+ abbreviation?: string;
59
+ };
60
+ export declare const isProductAPIValid: (data: any) => data is ProductAPIData;
61
+ /**
62
+ * Service for handling multi-view API calls
63
+ */
64
+ declare class MultiViewService {
65
+ private networkManager;
66
+ private productAPI;
67
+ constructor();
68
+ /**
69
+ * Fetch available multi-view layouts
70
+ *
71
+ * @returns Promise resolving to layouts data
72
+ */
73
+ getLayouts(): Promise<MultiViewLayout[]> | null;
74
+ /**
75
+ * Set the product API configuration
76
+ *
77
+ * @param productAPI - The product API endpoint, method, and headers
78
+ */
79
+ setProductAPIData(productAPI: ProductAPIData): void;
80
+ /**
81
+ * Start polling curated multiviews using the product API configuration.
82
+ * Returns null if no product API has been set.
83
+ *
84
+ * @param interval - Polling interval in milliseconds
85
+ * @param onData - Callback invoked with the data on each successful poll
86
+ * @param onError - Optional callback invoked on error
87
+ * @returns Object with a stop function, or null if no productAPI is configured
88
+ */
89
+ pollCuratedMultiviews(interval: number, onData: (data: CuratedMultiviewResponse) => void, onError?: (error: Error) => void): {
90
+ stop: () => void;
91
+ } | null;
92
+ /**
93
+ * Request an existing or new custom multiview.
94
+ * If the multiview exists, the response will include a multiviewId.
95
+ * If the multiview needs to be created, the response will include
96
+ * callbackSeconds indicating when to retry.
97
+ *
98
+ * @param config - The layout ID and listings for the multiview
99
+ * @param headers - Request headers (e.g. x-access-token, Content-Type)
100
+ * @returns Promise resolving to the multiview listing response
101
+ */
102
+ getOrCreateCustomMultiview(config: MultiViewListingRequest, headers?: Record<string, string>): Promise<MultiViewListingResponse>;
103
+ }
104
+ export default MultiViewService;
@@ -0,0 +1,97 @@
1
+ import NetworkManager, { HttpMethod, } from '@/services/NetworkManager/NetworkManager';
2
+ const MULTIVIEW_BASE_URL = 'https://qa-mvlm.api.shared.digitalvideoplatform.com';
3
+ export const isProductAPIValid = (data) => {
4
+ if (!data || typeof data !== 'object')
5
+ return false;
6
+ return (typeof data.url === 'string' &&
7
+ data.url.length > 0 &&
8
+ typeof data.method === 'string' &&
9
+ Object.values(HttpMethod).includes(data.method) &&
10
+ data.headers !== null &&
11
+ typeof data.headers === 'object' &&
12
+ !Array.isArray(data.headers) &&
13
+ (!data.callback || typeof data.callback === 'function'));
14
+ };
15
+ /**
16
+ * Service for handling multi-view API calls
17
+ */
18
+ class MultiViewService {
19
+ constructor() {
20
+ Object.defineProperty(this, "networkManager", {
21
+ enumerable: true,
22
+ configurable: true,
23
+ writable: true,
24
+ value: void 0
25
+ });
26
+ Object.defineProperty(this, "productAPI", {
27
+ enumerable: true,
28
+ configurable: true,
29
+ writable: true,
30
+ value: null
31
+ });
32
+ this.networkManager = new NetworkManager();
33
+ }
34
+ /**
35
+ * Fetch available multi-view layouts
36
+ *
37
+ * @returns Promise resolving to layouts data
38
+ */
39
+ getLayouts() {
40
+ if (!this.productAPI) {
41
+ return null;
42
+ }
43
+ return this.networkManager.externalApiRequest({
44
+ endpoint: `${MULTIVIEW_BASE_URL}/mvlm/v1/layouts`,
45
+ headers: this.productAPI.headers,
46
+ });
47
+ }
48
+ /**
49
+ * Set the product API configuration
50
+ *
51
+ * @param productAPI - The product API endpoint, method, and headers
52
+ */
53
+ setProductAPIData(productAPI) {
54
+ this.productAPI = productAPI;
55
+ }
56
+ /**
57
+ * Start polling curated multiviews using the product API configuration.
58
+ * Returns null if no product API has been set.
59
+ *
60
+ * @param interval - Polling interval in milliseconds
61
+ * @param onData - Callback invoked with the data on each successful poll
62
+ * @param onError - Optional callback invoked on error
63
+ * @returns Object with a stop function, or null if no productAPI is configured
64
+ */
65
+ pollCuratedMultiviews(interval, onData, onError) {
66
+ if (!this.productAPI) {
67
+ return null;
68
+ }
69
+ return this.networkManager.pollExternalApiRequest({
70
+ endpoint: this.productAPI.url,
71
+ interval,
72
+ method: this.productAPI.method,
73
+ headers: this.productAPI.headers,
74
+ onData,
75
+ onError,
76
+ });
77
+ }
78
+ /**
79
+ * Request an existing or new custom multiview.
80
+ * If the multiview exists, the response will include a multiviewId.
81
+ * If the multiview needs to be created, the response will include
82
+ * callbackSeconds indicating when to retry.
83
+ *
84
+ * @param config - The layout ID and listings for the multiview
85
+ * @param headers - Request headers (e.g. x-access-token, Content-Type)
86
+ * @returns Promise resolving to the multiview listing response
87
+ */
88
+ getOrCreateCustomMultiview(config, headers = {}) {
89
+ return this.networkManager.externalApiRequest({
90
+ endpoint: `${MULTIVIEW_BASE_URL}/mvlm/v1/mvlisting`,
91
+ method: HttpMethod.POST,
92
+ data: config,
93
+ headers,
94
+ });
95
+ }
96
+ }
97
+ export default MultiViewService;
@@ -1,62 +1,68 @@
1
1
  /**
2
2
  * @description Represents a single stream/camera listing available for multi-view
3
3
  */
4
- export interface Listing {
4
+ export interface CuratedMultiviewListing {
5
5
  id: string;
6
- title: string;
7
- thumbnailUrl: string;
8
- streamUrl: string;
9
- homeTeam?: {
10
- name: string;
11
- abbreviation: string;
12
- logoUrl: string;
13
- score?: number;
14
- };
15
- awayTeam?: {
16
- name: string;
17
- abbreviation: string;
18
- logoUrl: string;
19
- score?: number;
20
- };
21
- status?: 'live' | 'upcoming' | 'ended';
22
- metadata?: Record<string, unknown>;
6
+ description: string;
7
+ backgroundImage: string;
8
+ type: string;
23
9
  }
24
10
  /**
25
- * @description Defines a multi-view layout configuration with positioned slots
11
+ * @description Position data for a single window within a layout
12
+ */
13
+ export interface LayoutPosition {
14
+ w: number;
15
+ h: number;
16
+ x: number;
17
+ y: number;
18
+ }
19
+ /**
20
+ * @description Defines a multi-view layout configuration with positioned windows
26
21
  */
27
22
  export interface MultiViewLayout {
28
- id: string;
23
+ layoutId: string;
24
+ description: string;
25
+ positions: Record<string, LayoutPosition>;
29
26
  name: string;
30
- type: '50-50' | '60-40' | '70-30' | 'pip' | 'quad';
31
- slots: Array<{
32
- index: number;
33
- x: number;
34
- y: number;
35
- width: number;
36
- height: number;
37
- }>;
27
+ windowCount: number;
28
+ positionsOrder: string[];
29
+ }
30
+ /**
31
+ * @description Child listing with position for new multiview event payload (PRD: SDK to pass event to client)
32
+ */
33
+ export interface NewMultiviewChildListing {
34
+ listingId: string;
35
+ callsign: string;
36
+ position: LayoutPosition;
38
37
  }
39
38
  /**
40
- * @description Current multi-view state including listings and layout
39
+ * @description Payload for fox-multiview:new-multiview panel event when a curated multiview is selected
41
40
  */
42
- export interface MultiViewConfig {
43
- listings: Listing[];
44
- layout: MultiViewLayout;
45
- primaryAudioSlot?: number;
41
+ export interface NewMultiviewPayload {
42
+ multiviewID: string;
43
+ childListings: NewMultiviewChildListing[];
46
44
  }
45
+ export type BuildYourOwnTab = 'streams' | 'layouts';
47
46
  /**
48
- * @description Represents a pre-configured curated multiview experience
47
+ * @description Represents a single camera angle within a stream
49
48
  */
50
- export interface CuratedMultiview {
49
+ export type Camera = {
51
50
  id: string;
52
- title: string;
53
- description?: string;
54
- thumbnailUrl?: string;
55
- listings: Listing[];
56
- defaultLayout: MultiViewLayout;
57
- metadata?: Record<string, unknown>;
51
+ name: string;
52
+ isActive: boolean;
53
+ };
54
+ /**
55
+ * @description Represents a stream with its cameras and metadata, used in Build Your Own
56
+ */
57
+ export interface CustomMultiviewStream {
58
+ listing: CuratedMultiviewListing;
59
+ totalCameras: number;
60
+ activeCameraCount: number;
61
+ currentTime?: string;
62
+ location?: string;
63
+ cameras: Camera[];
58
64
  }
59
65
  /**
60
66
  * @description Available layouts organized by stream count
61
67
  */
62
- export declare const LAYOUTS_BY_COUNT: Record<2 | 3 | 4, MultiViewLayout[]>;
68
+ export declare const DEFAULT_LAYOUTS_BY_LISTINGS_QUANTITY: Record<number, MultiViewLayout>;
@@ -1,89 +1,86 @@
1
1
  /**
2
2
  * @description Available layouts organized by stream count
3
3
  */
4
- export const LAYOUTS_BY_COUNT = {
5
- 2: [
6
- {
7
- id: 'layout-2-50-50',
8
- name: '50/50',
9
- type: '50-50',
10
- slots: [
11
- { index: 0, x: 0, y: 0, width: 50, height: 100 },
12
- { index: 1, x: 50, y: 0, width: 50, height: 100 },
13
- ],
4
+ export const DEFAULT_LAYOUTS_BY_LISTINGS_QUANTITY = {
5
+ 2: {
6
+ layoutId: 'LR',
7
+ description: 'Two equal-sized windows side by side',
8
+ positions: {
9
+ L: {
10
+ w: 0.4766,
11
+ h: 0.4766,
12
+ x: 0.259,
13
+ y: 0.5,
14
+ },
15
+ R: {
16
+ w: 0.4766,
17
+ h: 0.4766,
18
+ x: 0.7409,
19
+ y: 0.5,
20
+ },
14
21
  },
15
- {
16
- id: 'layout-2-60-40',
17
- name: '60/40',
18
- type: '60-40',
19
- slots: [
20
- { index: 0, x: 0, y: 0, width: 60, height: 100 },
21
- { index: 1, x: 60, y: 0, width: 40, height: 100 },
22
- ],
22
+ name: '50/50',
23
+ windowCount: 2,
24
+ positionsOrder: ['L', 'R'],
25
+ },
26
+ 3: {
27
+ layoutId: 'TLTRB',
28
+ description: 'Three equal-sized windows in T layout',
29
+ positions: {
30
+ B: {
31
+ w: 0.458,
32
+ h: 0.458,
33
+ x: 0.5,
34
+ y: 0.266,
35
+ },
36
+ TL: {
37
+ w: 0.458,
38
+ h: 0.458,
39
+ x: 0.268,
40
+ y: 0.7335,
41
+ },
42
+ TR: {
43
+ w: 0.458,
44
+ h: 0.458,
45
+ x: 0.732,
46
+ y: 0.7335,
47
+ },
23
48
  },
24
- {
25
- id: 'layout-2-70-30',
26
- name: '70/30',
27
- type: '70-30',
28
- slots: [
29
- { index: 0, x: 0, y: 0, width: 70, height: 100 },
30
- { index: 1, x: 70, y: 0, width: 30, height: 100 },
31
- ],
49
+ name: 'Triple T',
50
+ windowCount: 3,
51
+ positionsOrder: ['TL', 'TR', 'B'],
52
+ },
53
+ 4: {
54
+ layoutId: 'TLTRBLBR',
55
+ description: 'Four equal-sized windows in 2x2 grid',
56
+ positions: {
57
+ BL: {
58
+ w: 0.4766,
59
+ h: 0.4766,
60
+ x: 0.259,
61
+ y: 0.257,
62
+ },
63
+ BR: {
64
+ w: 0.4766,
65
+ h: 0.4766,
66
+ x: 0.741,
67
+ y: 0.257,
68
+ },
69
+ TL: {
70
+ w: 0.4766,
71
+ h: 0.4766,
72
+ x: 0.259,
73
+ y: 0.743,
74
+ },
75
+ TR: {
76
+ w: 0.4766,
77
+ h: 0.4766,
78
+ x: 0.741,
79
+ y: 0.743,
80
+ },
32
81
  },
33
- {
34
- id: 'layout-2-pip',
35
- name: 'PIP',
36
- type: 'pip',
37
- slots: [
38
- { index: 0, x: 0, y: 0, width: 100, height: 100 },
39
- { index: 1, x: 70, y: 70, width: 25, height: 25 },
40
- ],
41
- },
42
- ],
43
- 3: [
44
- {
45
- id: 'layout-3-main-side',
46
- name: 'Main + Side',
47
- type: '60-40',
48
- slots: [
49
- { index: 0, x: 0, y: 0, width: 60, height: 100 },
50
- { index: 1, x: 60, y: 0, width: 40, height: 50 },
51
- { index: 2, x: 60, y: 50, width: 40, height: 50 },
52
- ],
53
- },
54
- {
55
- id: 'layout-3-horizontal',
56
- name: 'Horizontal',
57
- type: '50-50',
58
- slots: [
59
- { index: 0, x: 0, y: 0, width: 100, height: 33.33 },
60
- { index: 1, x: 0, y: 33.33, width: 100, height: 33.33 },
61
- { index: 2, x: 0, y: 66.66, width: 100, height: 33.34 },
62
- ],
63
- },
64
- ],
65
- 4: [
66
- {
67
- id: 'layout-4-quad',
68
- name: 'Quad',
69
- type: 'quad',
70
- slots: [
71
- { index: 0, x: 0, y: 0, width: 50, height: 50 },
72
- { index: 1, x: 50, y: 0, width: 50, height: 50 },
73
- { index: 2, x: 0, y: 50, width: 50, height: 50 },
74
- { index: 3, x: 50, y: 50, width: 50, height: 50 },
75
- ],
76
- },
77
- {
78
- id: 'layout-4-main-grid',
79
- name: 'Main + Grid',
80
- type: '60-40',
81
- slots: [
82
- { index: 0, x: 0, y: 0, width: 60, height: 100 },
83
- { index: 1, x: 60, y: 0, width: 40, height: 33.33 },
84
- { index: 2, x: 60, y: 33.33, width: 40, height: 33.33 },
85
- { index: 3, x: 60, y: 66.66, width: 40, height: 33.34 },
86
- ],
87
- },
88
- ],
82
+ name: '2x2 Grid',
83
+ windowCount: 4,
84
+ positionsOrder: ['TL', 'TR', 'BL', 'BR'],
85
+ },
89
86
  };
@@ -0,0 +1,7 @@
1
+ import { CustomMultiviewStream } from '../../types';
2
+ import './BuildYourOwn.styles.css';
3
+ type BuildYourOwnProps = {
4
+ streams: CustomMultiviewStream[];
5
+ };
6
+ declare const BuildYourOwn: (props: BuildYourOwnProps) => JSX.Element;
7
+ export default BuildYourOwn;