@streamlayer/react-ui 1.32.4 → 1.33.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 (154) hide show
  1. package/lib/app/app/Advertisement/index.d.ts +1 -1
  2. package/lib/app/app/Advertisement/index.js +14 -15
  3. package/lib/app/app/Banner/index.d.ts +1 -1
  4. package/lib/app/app/Features/FeatureProvider.d.ts +2 -2
  5. package/lib/app/app/Features/Gamification/Leaderboard.d.ts +1 -1
  6. package/lib/app/app/Features/Gamification/Leaderboard.js +46 -36
  7. package/lib/app/app/Features/Gamification/Question.d.ts +2 -2
  8. package/lib/app/app/Features/Gamification/Question.js +42 -42
  9. package/lib/app/app/Features/Gamification/QuestionAdvertisement.js +19 -25
  10. package/lib/app/app/Features/Gamification/QuestionsList.d.ts +1 -1
  11. package/lib/app/app/Features/Gamification/Tabs.d.ts +1 -1
  12. package/lib/app/app/Features/Gamification/UserSummary.d.ts +1 -1
  13. package/lib/app/app/Features/Gamification/index.d.ts +2 -2
  14. package/lib/app/app/Features/Gamification/index.js +29 -28
  15. package/lib/app/app/Features/index.d.ts +2 -2
  16. package/lib/app/app/InApp/index.d.ts +1 -1
  17. package/lib/app/app/Insight/index.d.ts +2 -2
  18. package/lib/app/app/Layout/index.d.ts +1 -1
  19. package/lib/app/app/Navigation/index.d.ts +1 -1
  20. package/lib/app/app/Notifications/Onboarding/Notification/index.d.ts +2 -2
  21. package/lib/app/app/Notifications/Onboarding/index.d.ts +2 -2
  22. package/lib/app/app/Notifications/Onboarding/index.js +45 -42
  23. package/lib/app/app/Notifications/index.d.ts +1 -1
  24. package/lib/app/app/Points/index.d.ts +1 -1
  25. package/lib/app/app/index.d.ts +1 -1
  26. package/lib/app/app/story/index.js +24 -24
  27. package/lib/app/app/story/insight/index.js +14 -15
  28. package/lib/app/app/story/insight/video.js +3 -3
  29. package/lib/app/app/story/promotion/content.js +5 -5
  30. package/lib/app/app/story/promotion/index.d.ts +1 -0
  31. package/lib/app/app/story/promotion/index.js +24 -25
  32. package/lib/app/app/story/promotion/video.d.ts +0 -1
  33. package/lib/app/app/story/promotion/video.js +41 -43
  34. package/lib/app/app/story/promotion-notification/index.js +15 -16
  35. package/lib/app/app/story/promotion-notification/video.d.ts +0 -1
  36. package/lib/app/app/story/promotion-notification/video.js +22 -30
  37. package/lib/app/app/story/settings/index.js +6 -6
  38. package/lib/app/app/story/settings/login.js +1 -1
  39. package/lib/app/app/story/video.js +28 -28
  40. package/lib/app/app/useApp.d.ts +1 -1
  41. package/lib/app/app/useAppContext.d.ts +1 -1
  42. package/lib/app/login/demo.js +19 -18
  43. package/lib/app/masters/BetPack/BetPackContent/EndScreen/index.d.ts +0 -1
  44. package/lib/app/masters/BetPack/BetPackContent/EndScreen/index.js +17 -17
  45. package/lib/app/masters/BetPack/BetPackContent/QuestionScreen/index.d.ts +2 -2
  46. package/lib/app/masters/BetPack/BetPackContent/index.d.ts +1 -1
  47. package/lib/app/masters/BetPack/BetPackOverlay/index.d.ts +1 -1
  48. package/lib/app/masters/BetPack/index.d.ts +1 -1
  49. package/lib/app/masters/Features/FeatureProvider.d.ts +2 -2
  50. package/lib/app/masters/Features/Gamification/Question.d.ts +1 -1
  51. package/lib/app/masters/Features/Gamification/QuestionsList.d.ts +1 -1
  52. package/lib/app/masters/Features/Gamification/Tabs.d.ts +1 -1
  53. package/lib/app/masters/Features/Gamification/UserSummary.d.ts +1 -1
  54. package/lib/app/masters/Features/Gamification/index.d.ts +1 -1
  55. package/lib/app/masters/Features/index.d.ts +2 -2
  56. package/lib/app/masters/Notifications/Onboarding/Notification/index.d.ts +2 -2
  57. package/lib/app/masters/Notifications/Onboarding/index.d.ts +2 -2
  58. package/lib/app/masters/Notifications/Onboarding/index.js +42 -39
  59. package/lib/app/masters/Notifications/index.d.ts +1 -1
  60. package/lib/app/masters/Points/index.d.ts +1 -1
  61. package/lib/app/masters/masters.d.ts +2 -1
  62. package/lib/app/masters/masters.js +34 -32
  63. package/lib/app/masters/provider.d.ts +4 -0
  64. package/lib/app/masters/provider.js +23 -0
  65. package/lib/app/masters/story/components.js +48 -52
  66. package/lib/app/masters/story/index.js +16 -15
  67. package/lib/app/masters/useMastersApp.d.ts +1 -1
  68. package/lib/app/masters/useMastersContext.d.ts +1 -1
  69. package/lib/app/tgl/index.d.ts +1 -0
  70. package/lib/app/tgl/index.js +19 -20
  71. package/lib/app/tgl/video.d.ts +0 -1
  72. package/lib/app/tgl/video.js +40 -42
  73. package/lib/app/useSdkFeature.d.ts +3 -3
  74. package/lib/app/webos/Advertisement/AdvertisementUI.d.ts +1 -1
  75. package/lib/app/webos/Advertisement/index.d.ts +1 -1
  76. package/lib/app/webos/ExposedPauseAd/PauseAd.d.ts +1 -1
  77. package/lib/app/webos/ExposedPauseAd/PauseAd.js +68 -68
  78. package/lib/app/webos/Question/index.d.ts +1 -1
  79. package/lib/app/webos/index.d.ts +1 -1
  80. package/lib/app/webos/story.js +26 -26
  81. package/lib/app/webos/ui/Sidebar/PromoAction.d.ts +1 -1
  82. package/lib/app/webos/ui/Sidebar/index.d.ts +2 -2
  83. package/lib/app/webos/ui/Sidebar/styles.js +82 -888
  84. package/lib/app/webos/ui/insight/index.d.ts +1 -1
  85. package/lib/assets/style.css +1 -1
  86. package/lib/core/app.d.ts +7 -0
  87. package/lib/core/app.js +14 -0
  88. package/lib/core/event.d.ts +6 -0
  89. package/lib/core/event.js +5 -0
  90. package/lib/core/hooks.d.ts +16 -0
  91. package/lib/core/hooks.js +8 -0
  92. package/lib/core/provider.d.ts +49 -0
  93. package/lib/core/provider.js +9 -0
  94. package/lib/hooks/analytics.d.ts +1 -1
  95. package/lib/hooks-B0Qttldg.js +99 -0
  96. package/lib/index.d.ts +0 -1
  97. package/lib/index.js +2 -4
  98. package/lib/ui/advertisement/banner/index.d.ts +3 -3
  99. package/lib/ui/advertisement/index.d.ts +1 -1
  100. package/lib/ui/advertisement/mock.d.ts +1 -1
  101. package/lib/ui/advertisement/notification/index.d.ts +1 -1
  102. package/lib/ui/advertisement/notification/lower-third/index.d.ts +1 -1
  103. package/lib/ui/advertisement/notification/lower-third/index.js +34 -30
  104. package/lib/ui/advertisement/overlay/externalAd/vast-player/useGAMPlayer.js +100 -33212
  105. package/lib/ui/advertisement/overlay/externalAd/vast-player/useGAMStatic.js +13 -13
  106. package/lib/ui/advertisement/overlay/externalAd/vast-player/useVastAds.d.ts +1 -1
  107. package/lib/ui/advertisement/overlay/externalAd/vast-player/useVastAds.js +63 -204
  108. package/lib/ui/advertisement/overlay/index.d.ts +2 -2
  109. package/lib/ui/close-btn/index.d.ts +1 -1
  110. package/lib/ui/gamification/constants.d.ts +1 -1
  111. package/lib/ui/gamification/detail/header/index.d.ts +1 -1
  112. package/lib/ui/gamification/insight/index.d.ts +1 -1
  113. package/lib/ui/gamification/insight-list/index.d.ts +1 -1
  114. package/lib/ui/gamification/leaderboard/list-item/index.d.ts +1 -1
  115. package/lib/ui/gamification/leaderboard/static.d.ts +1 -1
  116. package/lib/ui/gamification/onboarding/index.d.ts +2 -2
  117. package/lib/ui/gamification/question/inapp/notification/AdNotification/NotificationMedia/index.d.ts +2 -2
  118. package/lib/ui/gamification/question/inapp/notification/AdNotification/NotificationMedia/index.js +1 -1
  119. package/lib/ui/gamification/question/inapp/notification/AdNotification/index.d.ts +1 -1
  120. package/lib/ui/gamification/question/inapp/notification/NotificationMedia/index.d.ts +1 -1
  121. package/lib/ui/gamification/question/inapp/notification/index.d.ts +1 -1
  122. package/lib/ui/gamification/question/inapp/onboarding/index.d.ts +1 -1
  123. package/lib/ui/gamification/question/inapp/prediction-result/frames/index.d.ts +1 -1
  124. package/lib/ui/gamification/question/inapp/prediction-result/index.d.ts +1 -1
  125. package/lib/ui/gamification/question/inapp/prediction-result-ad/frames/index.d.ts +1 -1
  126. package/lib/ui/gamification/question/inapp/prediction-result-ad/index.d.ts +1 -1
  127. package/lib/ui/gamification/question/index.d.ts +1 -1
  128. package/lib/ui/gamification/question/list/index.d.ts +1 -1
  129. package/lib/ui/gamification/question/notification/index.d.ts +1 -1
  130. package/lib/ui/gamification/question/notification/insight/index.d.ts +2 -2
  131. package/lib/ui/gamification/question/notification/prediction-result/index.d.ts +1 -1
  132. package/lib/ui/gamification/question/notification/tweet/index.d.ts +1 -1
  133. package/lib/ui/gamification/vote/feedback/index.d.ts +1 -1
  134. package/lib/ui/gamification/vote/index.d.ts +1 -1
  135. package/lib/ui/gamification/vote/vote-option/index.d.ts +1 -1
  136. package/lib/ui/gamification/vote/win-bar/index.d.ts +1 -1
  137. package/lib/ui/icons/index.d.ts +198 -66
  138. package/lib/ui/navigation/button/index.d.ts +1 -1
  139. package/lib/ui/questions/insight/index.d.ts +1 -1
  140. package/lib/ui/questions/twitter/index.d.ts +1 -1
  141. package/lib/ui/video-player/index.js +26 -23
  142. package/lib/useStreamLayerApp.d.ts +23 -0
  143. package/lib/useStreamLayerApp.js +167 -0
  144. package/lib/utils/debug/components/bypassLogin.d.ts +1 -1
  145. package/lib/utils/debug/components/developer.d.ts +1 -1
  146. package/lib/utils/debug/components/eventInput.d.ts +1 -1
  147. package/lib/utils/debug/index.js +8 -8
  148. package/lib/utils/debug/storage.d.ts +1 -1
  149. package/lib/utils/storage.d.ts +1 -1
  150. package/package.json +42 -35
  151. package/lib/index-l-eyvmpL.js +0 -3758
  152. package/lib/utils/createDemo.d.ts +0 -12
  153. package/lib/utils/createDemo.js +0 -49
  154. package/lib/vast-client.min-B0NUra1B.js +0 -1060
@@ -1,70 +1,202 @@
1
1
  export declare const icons: {
2
- 'invite-game-icon': any;
3
- 'icon-trophy': any;
4
- 'icon-trophy-green': any;
5
- 'icon-trophy-solid': any;
6
- 'icon-trivia': any;
7
- 'icon-thumb-down': any;
8
- 'icon-thumb-up': any;
9
- 'icon-star': any;
10
- 'icon-prediction': any;
11
- 'icon-insight': any;
12
- 'icon-poll': any;
13
- 'icon-play': any;
14
- 'icon-pause': any;
15
- 'icon-masters-logo': any;
16
- 'icon-logout': any;
17
- 'icon-link': any;
18
- 'icon-external-link': any;
19
- 'icon-invite-arrow': any;
20
- 'icon-friends': any;
21
- 'icon-exit': any;
22
- 'icon-default-user-avatar': any;
23
- 'icon-copy': any;
24
- 'icon-cross': any;
25
- 'icon-close': any;
26
- 'icon-close-btn-white': any;
27
- 'icon-close-btn-gray': any;
28
- 'icon-circle-arrow-right': any;
29
- 'icon-chevron': any;
30
- 'icon-chevron-white-left': any;
31
- 'icon-chevron-left': any;
32
- 'icon-check': any;
33
- 'icon-check-white': any;
34
- 'icon-check-green': any;
35
- 'icon-check-circle': any;
36
- 'icon-correct': any;
37
- 'icon-btn-channels': any;
38
- 'icon-btn-feature-groups': any;
39
- 'icon-btn-leaderboard': any;
40
- 'icon-arrow': any;
41
- 'icon-twitter-verified': any;
42
- 'icon-trophy-bet-pack': any;
43
- 'icon-trivia-transparent': any;
44
- dashboard: any;
45
- iconMute: any;
46
- iconUnMute: any;
47
- correct: any;
48
- iconSkip: any;
49
- incorrect: any;
50
- questionExpired: any;
51
- selected: any;
52
- selectedBetPack: any;
53
- circleClose: any;
54
- incorrectVoted: any;
55
- mastersLogo: any;
56
- streamLayerLogo: any;
57
- twitter: any;
58
- iconUp: any;
59
- iconCopySuccess: any;
60
- chevronRight: any;
61
- noImageIcon: any;
62
- iconArrowRight: any;
63
- iconEarlyPrediction: any;
64
- iconArrowPrev: any;
65
- mastersLogoWhite: any;
66
- loader: any;
67
- fgIcon: any;
2
+ 'invite-game-icon': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
3
+ title?: string;
4
+ }>;
5
+ 'icon-trophy': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
6
+ title?: string;
7
+ }>;
8
+ 'icon-trophy-green': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
9
+ title?: string;
10
+ }>;
11
+ 'icon-trophy-solid': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
12
+ title?: string;
13
+ }>;
14
+ 'icon-trivia': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
15
+ title?: string;
16
+ }>;
17
+ 'icon-thumb-down': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
18
+ title?: string;
19
+ }>;
20
+ 'icon-thumb-up': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
21
+ title?: string;
22
+ }>;
23
+ 'icon-star': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
24
+ title?: string;
25
+ }>;
26
+ 'icon-prediction': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
27
+ title?: string;
28
+ }>;
29
+ 'icon-insight': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
30
+ title?: string;
31
+ }>;
32
+ 'icon-poll': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
33
+ title?: string;
34
+ }>;
35
+ 'icon-play': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
36
+ title?: string;
37
+ }>;
38
+ 'icon-pause': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
39
+ title?: string;
40
+ }>;
41
+ 'icon-masters-logo': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
42
+ title?: string;
43
+ }>;
44
+ 'icon-logout': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
45
+ title?: string;
46
+ }>;
47
+ 'icon-link': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
48
+ title?: string;
49
+ }>;
50
+ 'icon-external-link': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
51
+ title?: string;
52
+ }>;
53
+ 'icon-invite-arrow': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
54
+ title?: string;
55
+ }>;
56
+ 'icon-friends': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
57
+ title?: string;
58
+ }>;
59
+ 'icon-exit': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
60
+ title?: string;
61
+ }>;
62
+ 'icon-default-user-avatar': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
63
+ title?: string;
64
+ }>;
65
+ 'icon-copy': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
66
+ title?: string;
67
+ }>;
68
+ 'icon-cross': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
69
+ title?: string;
70
+ }>;
71
+ 'icon-close': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
72
+ title?: string;
73
+ }>;
74
+ 'icon-close-btn-white': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
75
+ title?: string;
76
+ }>;
77
+ 'icon-close-btn-gray': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
78
+ title?: string;
79
+ }>;
80
+ 'icon-circle-arrow-right': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
81
+ title?: string;
82
+ }>;
83
+ 'icon-chevron': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
84
+ title?: string;
85
+ }>;
86
+ 'icon-chevron-white-left': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
87
+ title?: string;
88
+ }>;
89
+ 'icon-chevron-left': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
90
+ title?: string;
91
+ }>;
92
+ 'icon-check': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
93
+ title?: string;
94
+ }>;
95
+ 'icon-check-white': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
96
+ title?: string;
97
+ }>;
98
+ 'icon-check-green': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
99
+ title?: string;
100
+ }>;
101
+ 'icon-check-circle': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
102
+ title?: string;
103
+ }>;
104
+ 'icon-correct': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
105
+ title?: string;
106
+ }>;
107
+ 'icon-btn-channels': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
108
+ title?: string;
109
+ }>;
110
+ 'icon-btn-feature-groups': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
111
+ title?: string;
112
+ }>;
113
+ 'icon-btn-leaderboard': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
114
+ title?: string;
115
+ }>;
116
+ 'icon-arrow': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
117
+ title?: string;
118
+ }>;
119
+ 'icon-twitter-verified': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
120
+ title?: string;
121
+ }>;
122
+ 'icon-trophy-bet-pack': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
123
+ title?: string;
124
+ }>;
125
+ 'icon-trivia-transparent': import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
126
+ title?: string;
127
+ }>;
128
+ dashboard: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
129
+ title?: string;
130
+ }>;
131
+ iconMute: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
132
+ title?: string;
133
+ }>;
134
+ iconUnMute: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
135
+ title?: string;
136
+ }>;
137
+ correct: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
138
+ title?: string;
139
+ }>;
140
+ iconSkip: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
141
+ title?: string;
142
+ }>;
143
+ incorrect: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
144
+ title?: string;
145
+ }>;
146
+ questionExpired: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
147
+ title?: string;
148
+ }>;
149
+ selected: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
150
+ title?: string;
151
+ }>;
152
+ selectedBetPack: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
153
+ title?: string;
154
+ }>;
155
+ circleClose: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
156
+ title?: string;
157
+ }>;
158
+ incorrectVoted: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
159
+ title?: string;
160
+ }>;
161
+ mastersLogo: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
162
+ title?: string;
163
+ }>;
164
+ streamLayerLogo: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
165
+ title?: string;
166
+ }>;
167
+ twitter: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
168
+ title?: string;
169
+ }>;
170
+ iconUp: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
171
+ title?: string;
172
+ }>;
173
+ iconCopySuccess: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
174
+ title?: string;
175
+ }>;
176
+ chevronRight: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
177
+ title?: string;
178
+ }>;
179
+ noImageIcon: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
180
+ title?: string;
181
+ }>;
182
+ iconArrowRight: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
183
+ title?: string;
184
+ }>;
185
+ iconEarlyPrediction: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
186
+ title?: string;
187
+ }>;
188
+ iconArrowPrev: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
189
+ title?: string;
190
+ }>;
191
+ mastersLogoWhite: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
192
+ title?: string;
193
+ }>;
194
+ loader: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
195
+ title?: string;
196
+ }>;
197
+ fgIcon: import('react').FunctionComponent<import('react').SVGProps<SVGSVGElement> & {
198
+ title?: string;
199
+ }>;
68
200
  };
69
201
  export declare const IconsLibrary: () => import("react/jsx-runtime").JSX.Element;
70
202
  type SvgIconProps = {
@@ -1,4 +1,4 @@
1
- import { FeatureType } from '@streamlayer/sdk-web-types';
1
+ import { FeatureType } from '../../../packages/sdk-web-types/src/index.ts';
2
2
  export type ButtonProps = {
3
3
  id: FeatureType | string;
4
4
  icon?: React.ReactNode;
@@ -1,4 +1,4 @@
1
- import { InsightHistory, Promotion } from '@streamlayer/sdk-web-types';
1
+ import { InsightHistory, Promotion } from '../../../packages/sdk-web-types/src/index.ts';
2
2
  import { VideoPlayerProps } from '../../video-player';
3
3
  export type InsightContentProps = InsightHistory & {
4
4
  isDetail?: boolean;
@@ -1,4 +1,4 @@
1
- import { TweetHistory } from '@streamlayer/sdk-web-types';
1
+ import { TweetHistory } from '../../../packages/sdk-web-types/src/index.ts';
2
2
  import { VideoPlayerProps } from '../../video-player';
3
3
  export declare const sanitizeContent: (text: string) => string;
4
4
  export type TwitterContentProps = TweetHistory & {
@@ -1,4 +1,4 @@
1
- import { jsxs as q, jsx as e, Fragment as st } from "react/jsx-runtime";
1
+ import { jsxs as N, jsx as e, Fragment as st } from "react/jsx-runtime";
2
2
  import { cx as _ } from "@linaria/core";
3
3
  import { withFocusable as nt } from "../../app/webos/useTvButton.js";
4
4
  import { forwardRef as ct, useRef as F, useState as B, useEffect as O, useCallback as P } from "react";
@@ -8,12 +8,12 @@ import { ToggleIconPause as it, HideControls as ut, Player as at, Poster as ft,
8
8
  const It = (r) => {
9
9
  for (const s of r)
10
10
  s.isIntersecting ? s.target instanceof HTMLVideoElement && s.target.autoplay && s.target.play() : s.target instanceof HTMLVideoElement && !s.target.paused && s.target.pause();
11
- }, $ = new IntersectionObserver(It, { threshold: 0.5 }), N = /* @__PURE__ */ new Set(), Bt = (r) => {
12
- $.observe(r), N.add(r);
11
+ }, $ = new IntersectionObserver(It, { threshold: 0.5 }), D = /* @__PURE__ */ new Set(), Bt = (r) => {
12
+ $.observe(r), D.add(r);
13
13
  }, Ot = (r) => {
14
- $.unobserve(r), N.delete(r);
14
+ $.unobserve(r), D.delete(r);
15
15
  }, wt = () => {
16
- for (const r of N)
16
+ for (const r of D)
17
17
  r instanceof HTMLVideoElement && !r.paused && r.pause();
18
18
  };
19
19
  function yt(...r) {
@@ -28,7 +28,7 @@ function yt(...r) {
28
28
  [...r]
29
29
  );
30
30
  }
31
- const Lt = nt(lt), Pt = ({ loading: r, autoPlay: s, played: c, playing: i, isMuted: f, unmute: d, mute: h, togglePlaying: l }) => !r && !s && !c ? /* @__PURE__ */ e(M, { children: i ? /* @__PURE__ */ e(g, { name: "icon-pause" }) : /* @__PURE__ */ e(g, { name: "icon-play" }) }) : c ? /* @__PURE__ */ q(mt, { children: [
31
+ const Lt = nt(lt), Pt = ({ loading: r, autoPlay: s, played: c, playing: i, isMuted: f, unmute: d, mute: h, togglePlaying: l }) => !r && !s && !c ? /* @__PURE__ */ e(M, { children: i ? /* @__PURE__ */ e(g, { name: "icon-pause" }) : /* @__PURE__ */ e(g, { name: "icon-play" }) }) : c ? /* @__PURE__ */ N(mt, { children: [
32
32
  i ? /* @__PURE__ */ e(dt, { onClick: l }) : /* @__PURE__ */ e(ht, { onClick: l }),
33
33
  /* @__PURE__ */ e(bt, { className: _(!f && "muted"), onClick: f ? d : h })
34
34
  ] }) : null, Tt = ({
@@ -42,7 +42,7 @@ const Lt = nt(lt), Pt = ({ loading: r, autoPlay: s, played: c, playing: i, isMut
42
42
  isMuted: l,
43
43
  hasNotPausedVideo: p,
44
44
  hasInteractedWithAudio: w
45
- }) => /* @__PURE__ */ q(st, { children: [
45
+ }) => /* @__PURE__ */ N(st, { children: [
46
46
  !r && !(s && c) && /* @__PURE__ */ e(M, { "data-control-btn": "true", children: i ? p ? null : /* @__PURE__ */ e(vt, { children: /* @__PURE__ */ e(g, { name: "icon-play" }) }) : f ? /* @__PURE__ */ e(Ct, { children: /* @__PURE__ */ e(g, { name: "icon-pause" }) }) : /* @__PURE__ */ e(St, { "data-control-icon": "true", children: /* @__PURE__ */ e(g, { name: "icon-play" }) }) }),
47
47
  !r && s && c && w && /* @__PURE__ */ e(M, { children: l ? /* @__PURE__ */ e(gt, { onClick: d, children: /* @__PURE__ */ e(g, { name: "iconMute" }) }) : /* @__PURE__ */ e(pt, { onClick: h, children: /* @__PURE__ */ e(g, { name: "iconUnMute" }) }) })
48
48
  ] }), Et = ct(
@@ -60,14 +60,14 @@ const Lt = nt(lt), Pt = ({ loading: r, autoPlay: s, played: c, playing: i, isMut
60
60
  onQuartile: u,
61
61
  autoPlay: v,
62
62
  playMuted: S,
63
- className: D,
63
+ className: K,
64
64
  muted: y,
65
65
  webos: T,
66
66
  hasNotPausedVideo: V
67
67
  }, R) => {
68
- const n = F(null), Q = yt(n, R), x = F(!1), E = F(!1), m = F(/* @__PURE__ */ new Set()), [K, z] = B(!1), [W, k] = B(!1), [j, G] = B(!1), [J, H] = B(!0), [A, U] = B(S), [X, tt] = B(!1);
68
+ const n = F(null), Q = yt(n, R), x = F(!1), E = F(!1), m = F(/* @__PURE__ */ new Set()), [z, G] = B(!1), [W, k] = B(!1), [j, J] = B(!1), [X, H] = B(!0), [A, U] = B(S), [q, tt] = B(!1);
69
69
  O(() => {
70
- s && (U(S), z(!1));
70
+ s && (U(S), G(!1));
71
71
  }, [s]);
72
72
  const C = P(() => {
73
73
  i == null || i({ muted: !1 });
@@ -75,9 +75,12 @@ const Lt = nt(lt), Pt = ({ loading: r, autoPlay: s, played: c, playing: i, isMut
75
75
  i == null || i({ muted: !0 });
76
76
  }, [i]), I = P((t) => {
77
77
  t == null || t.stopPropagation(), n.current && (n.current.muted = !0), U(!0);
78
- }, []), L = P((t) => {
79
- t == null || t.stopPropagation(), n.current && (n.current.muted = !1), U(!1), X || tt(!0);
80
- }, []);
78
+ }, []), L = P(
79
+ (t) => {
80
+ t == null || t.stopPropagation(), n.current && (n.current.muted = !1), U(!1), q || tt(!0);
81
+ },
82
+ [q]
83
+ );
81
84
  O(() => {
82
85
  y !== void 0 && (y ? I() : L());
83
86
  }, [I, y, L]);
@@ -110,7 +113,7 @@ const Lt = nt(lt), Pt = ({ loading: r, autoPlay: s, played: c, playing: i, isMut
110
113
  p == null || p();
111
114
  }, [p]), O(() => {
112
115
  m.current.clear(), x.current = !1;
113
- }, [s]), /* @__PURE__ */ q(
116
+ }, [s]), /* @__PURE__ */ N(
114
117
  Lt,
115
118
  {
116
119
  webos: T,
@@ -118,7 +121,7 @@ const Lt = nt(lt), Pt = ({ loading: r, autoPlay: s, played: c, playing: i, isMut
118
121
  "data-a": "intr",
119
122
  autoFocus: !0,
120
123
  options: { focusKey: "video-play-btn" },
121
- className: _(W && !T && it, v && ut, D),
124
+ className: _(W && !T && it, v && ut, K),
122
125
  style: c ? { aspectRatio: c } : {},
123
126
  children: [
124
127
  /* @__PURE__ */ e(
@@ -128,7 +131,7 @@ const Lt = nt(lt), Pt = ({ loading: r, autoPlay: s, played: c, playing: i, isMut
128
131
  src: s,
129
132
  autoPlay: v,
130
133
  onPlay: () => {
131
- z(!0), x.current && (f == null || f(), m.current.clear()), k(!0), H(!1), d == null || d(), S ? I() : Y();
134
+ G(!0), x.current && (f == null || f(), m.current.clear()), k(!0), H(!1), d == null || d(), S ? I() : Y();
132
135
  },
133
136
  onTimeUpdate: (t) => {
134
137
  const o = t.target.duration, b = t.target.currentTime;
@@ -144,14 +147,14 @@ const Lt = nt(lt), Pt = ({ loading: r, autoPlay: s, played: c, playing: i, isMut
144
147
  onError: async (t) => {
145
148
  try {
146
149
  if (t.target instanceof HTMLVideoElement) {
147
- G(!0);
150
+ J(!0);
148
151
  const b = await (await fetch(t.target.src)).blob(), a = URL.createObjectURL(b);
149
152
  t.target.src = a;
150
153
  }
151
154
  } catch (o) {
152
155
  console.error("video fallback fetch failed", o), k(!0), H(!0);
153
156
  } finally {
154
- G(!1), C();
157
+ J(!1), C();
155
158
  }
156
159
  },
157
160
  onPause: () => {
@@ -160,18 +163,18 @@ const Lt = nt(lt), Pt = ({ loading: r, autoPlay: s, played: c, playing: i, isMut
160
163
  onEnded: () => {
161
164
  k(!1), x.current = !0, et(), l == null || l(), C();
162
165
  },
163
- style: { visibility: J ? "hidden" : "visible" },
166
+ style: { visibility: X ? "hidden" : "visible" },
164
167
  controls: !1,
165
168
  playsInline: !0
166
169
  }
167
170
  ),
168
- /* @__PURE__ */ e(ft, { src: r, style: { visibility: J ? "visible" : "hidden" } }),
171
+ /* @__PURE__ */ e(ft, { src: r, style: { visibility: X ? "visible" : "hidden" } }),
169
172
  !T && /* @__PURE__ */ e(
170
173
  Pt,
171
174
  {
172
175
  loading: j,
173
176
  autoPlay: v,
174
- played: K,
177
+ played: z,
175
178
  playing: W,
176
179
  isMuted: A,
177
180
  unmute: L,
@@ -186,12 +189,12 @@ const Lt = nt(lt), Pt = ({ loading: r, autoPlay: s, played: c, playing: i, isMut
186
189
  autoPlay: v,
187
190
  playMuted: S,
188
191
  playing: W,
189
- played: K,
192
+ played: z,
190
193
  unmute: L,
191
194
  mute: I,
192
195
  isMuted: A,
193
196
  hasNotPausedVideo: V,
194
- hasInteractedWithAudio: X
197
+ hasInteractedWithAudio: q
195
198
  }
196
199
  ),
197
200
  j && /* @__PURE__ */ e(M, { children: /* @__PURE__ */ e(ot, {}) })
@@ -0,0 +1,23 @@
1
+ import { DeepLinkCallback, VideoPlayerCallback, OnContentActivateCallback } from './packages/sdk-web-core/src/index.ts';
2
+ import { StreamLayerSDK, StreamLayerPlugin } from './packages/sdk-web-interfaces/src/index.ts';
3
+ declare global {
4
+ interface Window {
5
+ sl: unknown;
6
+ }
7
+ }
8
+ export declare const useStreamLayerApp: ({ sdkKey, plugins, production, autoEnable, onDeepLinkHandled, videoPlayerController, onContentActivate, hideFriends, skipOnboarding, withAdNotification, withAd, friendsTab, betPack, webOS, }: {
9
+ sdkKey: string;
10
+ plugins?: Set<StreamLayerPlugin>;
11
+ production?: boolean;
12
+ autoEnable?: boolean;
13
+ onDeepLinkHandled?: DeepLinkCallback;
14
+ videoPlayerController?: VideoPlayerCallback;
15
+ onContentActivate?: OnContentActivateCallback;
16
+ skipOnboarding?: boolean;
17
+ withAdNotification?: boolean;
18
+ hideFriends?: boolean;
19
+ withAd?: boolean;
20
+ betPack?: boolean;
21
+ webOS?: boolean;
22
+ friendsTab: "enabled" | "disabled" | "activatedGame";
23
+ }) => StreamLayerSDK | null;
@@ -0,0 +1,167 @@
1
+ import { useState as k, useEffect as q } from "react";
2
+ import { StreamLayer as N } from "@streamlayer/sdk-web";
3
+ function Q(e) {
4
+ return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
5
+ }
6
+ var w = { exports: {} }, t = w.exports = {}, o, i;
7
+ function p() {
8
+ throw new Error("setTimeout has not been defined");
9
+ }
10
+ function d() {
11
+ throw new Error("clearTimeout has not been defined");
12
+ }
13
+ (function() {
14
+ try {
15
+ typeof setTimeout == "function" ? o = setTimeout : o = p;
16
+ } catch {
17
+ o = p;
18
+ }
19
+ try {
20
+ typeof clearTimeout == "function" ? i = clearTimeout : i = d;
21
+ } catch {
22
+ i = d;
23
+ }
24
+ })();
25
+ function v(e) {
26
+ if (o === setTimeout)
27
+ return setTimeout(e, 0);
28
+ if ((o === p || !o) && setTimeout)
29
+ return o = setTimeout, setTimeout(e, 0);
30
+ try {
31
+ return o(e, 0);
32
+ } catch {
33
+ try {
34
+ return o.call(null, e, 0);
35
+ } catch {
36
+ return o.call(this, e, 0);
37
+ }
38
+ }
39
+ }
40
+ function D(e) {
41
+ if (i === clearTimeout)
42
+ return clearTimeout(e);
43
+ if ((i === d || !i) && clearTimeout)
44
+ return i = clearTimeout, clearTimeout(e);
45
+ try {
46
+ return i(e);
47
+ } catch {
48
+ try {
49
+ return i.call(null, e);
50
+ } catch {
51
+ return i.call(this, e);
52
+ }
53
+ }
54
+ }
55
+ var s = [], l = !1, c, f = -1;
56
+ function F() {
57
+ !l || !c || (l = !1, c.length ? s = c.concat(s) : f = -1, s.length && g());
58
+ }
59
+ function g() {
60
+ if (!l) {
61
+ var e = v(F);
62
+ l = !0;
63
+ for (var r = s.length; r; ) {
64
+ for (c = s, s = []; ++f < r; )
65
+ c && c[f].run();
66
+ f = -1, r = s.length;
67
+ }
68
+ c = null, l = !1, D(e);
69
+ }
70
+ }
71
+ t.nextTick = function(e) {
72
+ var r = new Array(arguments.length - 1);
73
+ if (arguments.length > 1)
74
+ for (var u = 1; u < arguments.length; u++)
75
+ r[u - 1] = arguments[u];
76
+ s.push(new y(e, r)), s.length === 1 && !l && v(g);
77
+ };
78
+ function y(e, r) {
79
+ this.fun = e, this.array = r;
80
+ }
81
+ y.prototype.run = function() {
82
+ this.fun.apply(null, this.array);
83
+ };
84
+ t.title = "browser";
85
+ t.browser = !0;
86
+ t.env = {};
87
+ t.argv = [];
88
+ t.version = "";
89
+ t.versions = {};
90
+ function a() {
91
+ }
92
+ t.on = a;
93
+ t.addListener = a;
94
+ t.once = a;
95
+ t.off = a;
96
+ t.removeListener = a;
97
+ t.removeAllListeners = a;
98
+ t.emit = a;
99
+ t.prependListener = a;
100
+ t.prependOnceListener = a;
101
+ t.listeners = function(e) {
102
+ return [];
103
+ };
104
+ t.binding = function(e) {
105
+ throw new Error("process.binding is not supported");
106
+ };
107
+ t.cwd = function() {
108
+ return "/";
109
+ };
110
+ t.chdir = function(e) {
111
+ throw new Error("process.chdir is not supported");
112
+ };
113
+ t.umask = function() {
114
+ return 0;
115
+ };
116
+ var M = w.exports;
117
+ const R = /* @__PURE__ */ Q(M), $ = ({
118
+ sdkKey: e,
119
+ plugins: r,
120
+ production: u,
121
+ autoEnable: b,
122
+ onDeepLinkHandled: E,
123
+ videoPlayerController: L,
124
+ onContentActivate: S,
125
+ hideFriends: A,
126
+ skipOnboarding: x,
127
+ withAdNotification: C,
128
+ withAd: O,
129
+ friendsTab: I,
130
+ betPack: P,
131
+ webOS: _
132
+ }) => {
133
+ const [j, T] = k(null);
134
+ return q(() => {
135
+ let h = !1;
136
+ if (!e)
137
+ return console.error("streamlayer sdk key should be provided"), T((n) => (n !== null && typeof n.disableApp == "function" && n.disableApp(), null)), () => {
138
+ h = !0;
139
+ };
140
+ const m = N(e, u, b, {
141
+ version: R.env.APP_VERSION,
142
+ onDeepLinkHandled: E,
143
+ videoPlayerController: L,
144
+ onContentActivate: S,
145
+ skipOnboarding: x,
146
+ withAdNotification: C,
147
+ withAd: O,
148
+ hideFriends: A,
149
+ friendsTab: I,
150
+ betPack: P,
151
+ webOS: _
152
+ });
153
+ if (r)
154
+ for (const n of r)
155
+ m.use(n);
156
+ return m.ready().then((n) => {
157
+ h || (T(n.sdk), typeof window < "u");
158
+ }).catch((n) => console.log(n)), () => {
159
+ h = !0, m.close(function(n) {
160
+ if (n) throw n;
161
+ });
162
+ };
163
+ }, [e, u]), j;
164
+ };
165
+ export {
166
+ $ as useStreamLayerApp
167
+ };
@@ -1,4 +1,4 @@
1
- import { StreamLayerSDK } from '@streamlayer/sdk-web-interfaces';
1
+ import { StreamLayerSDK } from '../../../packages/sdk-web-interfaces/src/index.ts';
2
2
  import { DeveloperStorage } from '../../storage';
3
3
  export declare const BypassLogin: React.FC<{
4
4
  sdk: StreamLayerSDK;
@@ -1,4 +1,4 @@
1
- import { StreamLayerSDK } from '@streamlayer/sdk-web-interfaces';
1
+ import { StreamLayerSDK } from '../../../packages/sdk-web-interfaces/src/index.ts';
2
2
  type DeveloperProps = {
3
3
  sdk: StreamLayerSDK | null;
4
4
  sdkKey: string;
@@ -1,4 +1,4 @@
1
- import { StreamLayerSDK } from '@streamlayer/sdk-web-interfaces';
1
+ import { StreamLayerSDK } from '../../../packages/sdk-web-interfaces/src/index.ts';
2
2
  import { DeveloperStorage } from '../../storage';
3
3
  export declare const EventInput: React.FC<{
4
4
  sdk: StreamLayerSDK;