@decky/ui 4.15.1 → 4.16.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.
Files changed (167) hide show
  1. package/dist/components/Dropdown.d.ts +2 -2
  2. package/dist/components/FooterLegend.d.ts +8 -2
  3. package/dist/components/FooterLegend.js +7 -0
  4. package/dist/components/Menu.d.ts +5 -9
  5. package/dist/components/Modal.d.ts +3 -2
  6. package/dist/globals/index.d.ts +25 -2
  7. package/dist/globals/index.js +1 -2
  8. package/dist/globals/shared/cm.d.ts +112 -0
  9. package/dist/globals/shared/enums.d.ts +80 -0
  10. package/dist/globals/shared/enums.js +85 -0
  11. package/dist/globals/shared/history.d.ts +12 -0
  12. package/dist/globals/shared/history.js +1 -0
  13. package/dist/globals/shared/index.d.ts +5 -0
  14. package/dist/globals/shared/index.js +5 -0
  15. package/dist/globals/shared/interfaces.d.ts +54 -0
  16. package/dist/globals/shared/interfaces.js +1 -0
  17. package/dist/globals/shared/navigation.d.ts +14 -0
  18. package/dist/globals/shared/navigation.js +10 -0
  19. package/dist/globals/shared/steamid.d.ts +36 -0
  20. package/dist/globals/shared/steamid.js +15 -0
  21. package/dist/globals/shared/storage.d.ts +27 -0
  22. package/dist/globals/shared/storage.js +11 -0
  23. package/dist/globals/steam-client/App.d.ts +1 -1
  24. package/dist/globals/steam-client/Auth.d.ts +1 -1
  25. package/dist/globals/steam-client/ClientNotifications.d.ts +1 -1
  26. package/dist/globals/steam-client/Overlay.d.ts +2 -1
  27. package/dist/globals/steam-client/Settings.d.ts +1 -1
  28. package/dist/globals/steam-client/SharedConnection.d.ts +2 -1
  29. package/dist/globals/steam-client/UI.d.ts +14 -3
  30. package/dist/globals/steam-client/UI.js +11 -0
  31. package/dist/globals/steam-client/User.d.ts +13 -0
  32. package/dist/globals/steam-client/User.js +7 -0
  33. package/dist/globals/steam-client/WebChat.d.ts +3 -2
  34. package/dist/globals/steam-client/shared.d.ts +0 -29
  35. package/dist/globals/steam-client/shared.js +0 -24
  36. package/dist/globals/stores/app.d.ts +35 -0
  37. package/dist/globals/stores/app.js +1 -0
  38. package/dist/globals/stores/appdetailsstore.d.ts +86 -0
  39. package/dist/globals/stores/appdetailsstore.js +1 -0
  40. package/dist/globals/stores/appinfostore.d.ts +56 -0
  41. package/dist/globals/stores/appinfostore.js +1 -0
  42. package/dist/globals/stores/appstore.d.ts +77 -0
  43. package/dist/globals/stores/appstore.js +1 -0
  44. package/dist/globals/stores/badgestore.d.ts +52 -0
  45. package/dist/globals/stores/badgestore.js +1 -0
  46. package/dist/globals/stores/collectionstore.d.ts +313 -0
  47. package/dist/globals/stores/collectionstore.js +143 -0
  48. package/dist/globals/stores/consolestore.d.ts +20 -0
  49. package/dist/globals/stores/consolestore.js +1 -0
  50. package/dist/globals/stores/focusnavcontroller.d.ts +383 -0
  51. package/dist/globals/stores/focusnavcontroller.js +29 -0
  52. package/dist/globals/stores/friendstore/clanstore.d.ts +75 -0
  53. package/dist/globals/stores/friendstore/clanstore.js +19 -0
  54. package/dist/globals/stores/friendstore/friendchat.d.ts +374 -0
  55. package/dist/globals/stores/friendstore/friendchat.js +56 -0
  56. package/dist/globals/stores/friendstore/friendgroupstore.d.ts +98 -0
  57. package/dist/globals/stores/friendstore/friendgroupstore.js +8 -0
  58. package/dist/globals/stores/friendstore/friendingamenotificationstore.d.ts +2 -0
  59. package/dist/globals/stores/friendstore/friendingamenotificationstore.js +1 -0
  60. package/dist/globals/stores/friendstore/friendslistfavoritesstore.d.ts +22 -0
  61. package/dist/globals/stores/friendstore/friendslistfavoritesstore.js +1 -0
  62. package/dist/globals/stores/friendstore/friendsuifriendstore.d.ts +125 -0
  63. package/dist/globals/stores/friendstore/friendsuifriendstore.js +1 -0
  64. package/dist/globals/stores/friendstore/index.d.ts +25 -0
  65. package/dist/globals/stores/friendstore/index.js +1 -0
  66. package/dist/globals/stores/friendstore/shared.d.ts +207 -0
  67. package/dist/globals/stores/friendstore/shared.js +41 -0
  68. package/dist/globals/stores/gamerecordingstore.d.ts +263 -0
  69. package/dist/globals/stores/gamerecordingstore.js +1 -0
  70. package/dist/globals/stores/index.d.ts +18 -0
  71. package/dist/globals/stores/index.js +18 -0
  72. package/dist/globals/stores/libraryuistore.d.ts +179 -0
  73. package/dist/globals/stores/libraryuistore.js +56 -0
  74. package/dist/globals/stores/localizationmanager.d.ts +18 -0
  75. package/dist/globals/stores/localizationmanager.js +1 -0
  76. package/dist/globals/stores/mainwindowbrowsermanager.d.ts +62 -0
  77. package/dist/globals/stores/mainwindowbrowsermanager.js +1 -0
  78. package/dist/globals/stores/notificationstore.d.ts +242 -0
  79. package/dist/globals/stores/notificationstore.js +20 -0
  80. package/dist/globals/stores/popupmanager.d.ts +128 -0
  81. package/dist/globals/stores/popupmanager.js +1 -0
  82. package/dist/globals/stores/securitystore.d.ts +35 -0
  83. package/dist/globals/stores/securitystore.js +1 -0
  84. package/dist/globals/stores/settingsstore.d.ts +86 -0
  85. package/dist/globals/stores/settingsstore.js +19 -0
  86. package/dist/globals/stores/steamuistore/gamepadbrowserview.d.ts +143 -0
  87. package/dist/globals/stores/steamuistore/gamepadbrowserview.js +9 -0
  88. package/dist/globals/stores/steamuistore/gamepaduiaudio.d.ts +36 -0
  89. package/dist/globals/stores/steamuistore/gamepaduiaudio.js +1 -0
  90. package/dist/globals/stores/steamuistore/index.d.ts +129 -0
  91. package/dist/globals/stores/steamuistore/index.js +11 -0
  92. package/dist/globals/stores/steamuistore/menu.d.ts +39 -0
  93. package/dist/globals/stores/steamuistore/menu.js +19 -0
  94. package/dist/globals/stores/steamuistore/window.d.ts +206 -0
  95. package/dist/globals/stores/steamuistore/window.js +6 -0
  96. package/dist/globals/stores/storeitemcache.d.ts +319 -0
  97. package/dist/globals/stores/storeitemcache.js +17 -0
  98. package/dist/globals/stores/urlstore.d.ts +57 -0
  99. package/dist/globals/stores/urlstore.js +1 -0
  100. package/dist/modules/Router.d.ts +5 -58
  101. package/dist/modules/Router.js +2 -20
  102. package/dist/tsconfig.tsbuildinfo +1 -1
  103. package/dist/utils/index.d.ts +0 -1
  104. package/package.json +1 -1
  105. package/src/components/Dropdown.tsx +2 -2
  106. package/src/components/FooterLegend.ts +10 -2
  107. package/src/components/Menu.ts +11 -21
  108. package/src/components/Modal.ts +40 -8
  109. package/src/globals/index.ts +45 -2
  110. package/src/globals/shared/cm.ts +158 -0
  111. package/src/globals/shared/enums.ts +97 -0
  112. package/src/globals/shared/history.ts +15 -0
  113. package/src/globals/shared/index.ts +5 -0
  114. package/src/globals/shared/interfaces.ts +147 -0
  115. package/src/globals/shared/navigation.ts +15 -0
  116. package/src/globals/shared/steamid.ts +49 -0
  117. package/src/globals/shared/storage.ts +62 -0
  118. package/src/globals/steam-client/App.ts +2 -2
  119. package/src/globals/steam-client/Auth.ts +2 -2
  120. package/src/globals/steam-client/ClientNotifications.ts +1 -1
  121. package/src/globals/steam-client/Overlay.ts +2 -1
  122. package/src/globals/steam-client/Settings.ts +1 -1
  123. package/src/globals/steam-client/SharedConnection.ts +2 -1
  124. package/src/globals/steam-client/UI.ts +15 -6
  125. package/src/globals/steam-client/User.ts +20 -0
  126. package/src/globals/steam-client/WebChat.ts +3 -2
  127. package/src/globals/steam-client/shared.ts +0 -69
  128. package/src/globals/stores/app.ts +102 -0
  129. package/src/globals/stores/appdetailsstore.ts +235 -0
  130. package/src/globals/stores/appinfostore.ts +65 -0
  131. package/src/globals/stores/appstore.ts +166 -0
  132. package/src/globals/stores/badgestore.ts +87 -0
  133. package/src/globals/stores/collectionstore.ts +544 -0
  134. package/src/globals/stores/consolestore.ts +54 -0
  135. package/src/globals/stores/focusnavcontroller.ts +522 -0
  136. package/src/globals/stores/friendstore/clanstore.ts +89 -0
  137. package/src/globals/stores/friendstore/friendchat.ts +646 -0
  138. package/src/globals/stores/friendstore/friendgroupstore.ts +187 -0
  139. package/src/globals/stores/friendstore/friendingamenotificationstore.ts +1 -0
  140. package/src/globals/stores/friendstore/friendslistfavoritesstore.ts +37 -0
  141. package/src/globals/stores/friendstore/friendsuifriendstore.ts +274 -0
  142. package/src/globals/stores/friendstore/index.ts +58 -0
  143. package/src/globals/stores/friendstore/shared.ts +318 -0
  144. package/src/globals/stores/gamerecordingstore.ts +367 -0
  145. package/src/globals/stores/index.ts +18 -0
  146. package/src/globals/stores/libraryuistore.ts +395 -0
  147. package/src/globals/stores/localizationmanager.ts +56 -0
  148. package/src/globals/stores/mainwindowbrowsermanager.ts +135 -0
  149. package/src/globals/stores/notificationstore.ts +298 -0
  150. package/src/globals/stores/popupmanager.ts +352 -0
  151. package/src/globals/stores/securitystore.ts +36 -0
  152. package/src/globals/stores/settingsstore.ts +134 -0
  153. package/src/globals/stores/steamuistore/gamepadbrowserview.ts +172 -0
  154. package/src/globals/stores/steamuistore/gamepaduiaudio.ts +117 -0
  155. package/src/globals/stores/steamuistore/index.ts +212 -0
  156. package/src/globals/stores/steamuistore/menu.ts +89 -0
  157. package/src/globals/stores/steamuistore/window.ts +466 -0
  158. package/src/globals/stores/storeitemcache.ts +347 -0
  159. package/src/globals/stores/urlstore.ts +150 -0
  160. package/src/modules/Router.ts +11 -77
  161. package/src/utils/index.ts +0 -1
  162. package/dist/globals/SteamClient.d.ts +0 -5
  163. package/dist/globals/SteamClient.js +0 -1
  164. package/dist/globals/stores.d.ts +0 -70
  165. package/src/globals/SteamClient.ts +0 -6
  166. package/src/globals/stores.ts +0 -74
  167. /package/dist/globals/{stores.js → shared/cm.js} +0 -0
@@ -0,0 +1,318 @@
1
+ import type { BrowserContext, CSteamID } from '../../shared';
2
+ import type { CChat } from './friendchat';
3
+
4
+ export enum EClientPersonaStateFlag {
5
+ k_EClientPersonaStateFlagStatus = 1 << 0,
6
+ k_EClientPersonaStateFlagPlayerName = 1 << 1,
7
+ k_EClientPersonaStateFlagQueryPort = 1 << 2,
8
+ k_EClientPersonaStateFlagSourceID = 1 << 3,
9
+ k_EClientPersonaStateFlagPresence = 1 << 4,
10
+ k_EClientPersonaStateFlagLastSeen = 1 << 5,
11
+ k_EClientPersonaStateFlagUserClanRank = 1 << 6,
12
+ k_EClientPersonaStateGameExtraInfo = 1 << 7,
13
+ k_EClientPersonaStateGameDataBlob = 1 << 8,
14
+ k_EClientPersonaStateFlagClanData = 1 << 9,
15
+ k_EClientPersonaStateFlagFacebook = 1 << 10,
16
+ k_EClientPersonaStateFlagRichPresence = 1 << 11,
17
+ k_EClientPersonaStateFlagBroadcast = 1 << 12,
18
+ k_EClientPersonaStateFlagWatching = 1 << 13,
19
+ }
20
+
21
+ export enum EFriendRelationship {
22
+ None,
23
+ Blocked,
24
+ RequestRecipient,
25
+ Friend,
26
+ RequestInitiator,
27
+ Ignored,
28
+ IgnoredFriend,
29
+ Suggested_DEPRECATED,
30
+ Max,
31
+ }
32
+
33
+ export enum EPersonaState {
34
+ Offline,
35
+ Online,
36
+ Busy,
37
+ Away,
38
+ Snooze,
39
+ LookingToTrade,
40
+ LookingToPlay,
41
+ Invisible,
42
+ Max,
43
+ }
44
+
45
+ // TODO(protobufs): generate
46
+ declare class CPlayer_GetProfileItemsEquipped_Response {}
47
+
48
+ declare class CPersonaStateImpl {
49
+ m_bAvatarPending: boolean;
50
+ m_bCommunityBanned: boolean;
51
+ m_bInitialized: boolean;
52
+ m_bNameInitialized: boolean;
53
+ m_bOnSteamDeck: boolean;
54
+ m_bPlayerNamePending: boolean;
55
+ m_bStatusInitialized: boolean;
56
+ m_broadcastAccountId: number | undefined;
57
+ m_broadcastAppId: number | undefined;
58
+ m_broadcastId: number | undefined;
59
+ m_broadcastViewerCount: number | undefined;
60
+ m_ePersonaState: EPersonaState;
61
+ m_game_lobby_id: string;
62
+ m_gameid: string;
63
+ m_mapRichPresence: Map<string, string>;
64
+ m_rtLastSeenOnline: number;
65
+ m_steamid: CSteamID;
66
+
67
+ /**
68
+ * @returns `true` if the user has set an avatar.
69
+ */
70
+ BHasAvatarSet(): boolean;
71
+
72
+ /**
73
+ * @returns `true` if app info is ready.
74
+ * @see {@link CAppInfoStore}
75
+ */
76
+ BIsAppInfoReady(): boolean;
77
+
78
+ /**
79
+ * @returns the user's SteamID3.
80
+ */
81
+ GetAccountID(): number;
82
+
83
+ /**
84
+ * @returns the user's community profile URL.
85
+ */
86
+ GetCommunityProfileURL(): string;
87
+
88
+ /**
89
+ * @returns the user's currently playing game's name.
90
+ */
91
+ GetCurrentGameName(): string;
92
+
93
+ /**
94
+ * @returns the user's currently playing game's icon URL.
95
+ */
96
+ GetCurrentGameIconURL(): string;
97
+
98
+ HasCurrentGameRichPresence(): boolean;
99
+
100
+ HasRichPresenceForViewGameInfo(): boolean;
101
+
102
+ GetCurrentGameRichPresence(): string;
103
+
104
+ /**
105
+ * @returns the user's currently playing game's status, e.g.
106
+ */
107
+ GetCurrentGameStatus(): string;
108
+
109
+ /**
110
+ * @returns the seconds at which rate the user's status will be updated.
111
+ */
112
+ GetOfflineStatusUpdateRate(): number;
113
+
114
+ /**
115
+ * @returns a localized string for offline time, e.g. "Last online 5 years
116
+ * ago".
117
+ */
118
+ GetOfflineStatusTime(): string;
119
+
120
+ /**
121
+ * @returns the localized online status, but still "Online" if in game.
122
+ */
123
+ GetLocalizedOnlineStatus(): string;
124
+
125
+ HasStateFlag(flag: EClientPersonaStateFlag): boolean;
126
+
127
+ /**
128
+ * @returns `true` if the user is currently using a Steam Deck.
129
+ */
130
+ IsOnSteamDeck(): boolean;
131
+
132
+ get avatar_url(): string;
133
+ get avatar_url_full(): string;
134
+ get avatar_url_medium(): string;
135
+ get connect_string(): string | undefined;
136
+ get has_joinable_game_flag(): boolean;
137
+ get has_public_party_beacon(): boolean;
138
+ get has_server_ip(): boolean;
139
+ get is_awayOrSnooze(): boolean;
140
+ get is_golden(): boolean;
141
+ get is_in_joinable_game(): boolean;
142
+ get is_in_nonsteam_game(): boolean;
143
+ get is_in_valid_lobby(): boolean;
144
+ get is_ingame(): boolean;
145
+ get is_online(): boolean;
146
+ get is_watchingbroadcast(): boolean;
147
+ // UNIX timestamp
148
+ get last_seen_online(): number;
149
+ get online_state(): 'in-game' | 'offline' | 'online' | 'watchingbroadcast';
150
+ get player_group(): string;
151
+ get player_group_size(): number;
152
+ }
153
+
154
+ interface CommunityData {
155
+ avatar_url: string;
156
+ in_game: {
157
+ name: string;
158
+ is_non_steam: boolean;
159
+ logo: string;
160
+ rich_presence: string;
161
+ };
162
+ level: number;
163
+ level_class: string;
164
+ persona_name: string;
165
+ m_rtLastLoad: number;
166
+
167
+ /**
168
+ * Loads community data if not already.
169
+ */
170
+ EnsureCommunityDataLoaded(): void;
171
+
172
+ /**
173
+ * Reloads community data.
174
+ */
175
+ Reload(): void;
176
+ }
177
+
178
+ interface MiniProfileData {
179
+ m_accountid: number;
180
+ m_bLoadingData: boolean;
181
+ m_communityData: CommunityData | undefined;
182
+ m_nAppIDLastSeenPlaying: number;
183
+ m_persona: CPersonaStateImpl;
184
+ m_strAccountName: string;
185
+ m_strAvatarHash: string;
186
+ m_strBroadcastTitle: string | undefined;
187
+ m_strGameExtraInfo: string;
188
+ m_strPlayerName: string;
189
+ m_strProfileURL: string | undefined;
190
+ m_unGamePlayedAppID: number;
191
+ m_unGameServerIP: number;
192
+ m_unGameServerPort: number;
193
+ m_unPersonaStateFlags: number;
194
+ }
195
+
196
+ export interface PerFriendNotificationSettings {
197
+ Notifications_SendMobile: number;
198
+ Notifications_ShowInGame: number;
199
+ Notifications_ShowMessage: number;
200
+ Notifications_ShowOnline: number;
201
+ Sounds_PlayInGame: number;
202
+ Sounds_PlayMessage: number;
203
+ Sounds_PlayOnline: number;
204
+ }
205
+
206
+ export declare class CPlayer {
207
+ m_NotificationSettings: PerFriendNotificationSettings;
208
+ m_bLoadedEquippedProfileItems: boolean;
209
+ m_bPersonaNameHistoryLoaded: boolean;
210
+ m_bPersonaStateLoadRequested: boolean;
211
+ m_bRequestedEquippedProfileItems: boolean;
212
+ m_dtLastSeenPlaying: Date | undefined;
213
+ m_eFriendRelationship: EFriendRelationship;
214
+ m_equippedProfileItems: CPlayer_GetProfileItemsEquipped_Response;
215
+ m_miniProfileDataLoader: MiniProfileData | undefined;
216
+ m_rgPersonaNameHistory: string[];
217
+ m_strGameNameNormalized: string | undefined;
218
+ m_strNickname: string | undefined;
219
+ m_strPlayerNameNormalized: string | undefined;
220
+ m_strPlayerNicknameNormalized: string | undefined;
221
+ m_tsLastPersonaStateUpdate: number;
222
+ m_unAccountID: number;
223
+
224
+ BHaveReceivedPersonaUpdateSince(timestamp: number): boolean;
225
+
226
+ BLoadedEquippedItems(): boolean;
227
+
228
+ BMatchesSearchString(s: string, param1: boolean): boolean;
229
+
230
+ BPlayInGameSound(): boolean;
231
+
232
+ BPlayMessageSound(): boolean;
233
+
234
+ BPlayOnlineSound(): boolean;
235
+
236
+ BShowInGameNotification(): boolean;
237
+
238
+ BShowMessageNotification(): boolean;
239
+
240
+ BShowOnlineNotification(): boolean;
241
+
242
+ BWasRecentlyPlayingAppID(appid: number, seconds: number): boolean;
243
+
244
+ ClearStateOnDisconnect(): void;
245
+
246
+ /**
247
+ * @returns the broadcast's title or localized string if title is not set or
248
+ * `null` if not broadcasting.
249
+ */
250
+ GetBroadcastDescription(): string | null;
251
+
252
+ /**
253
+ * @returns the community profile URL.
254
+ */
255
+ GetCommunityProfileURL(): string;
256
+
257
+ GetEquippedProfileItems(): CPlayer_GetProfileItemsEquipped_Response;
258
+
259
+ LoadAndSetGoldenProfileFrame(): Promise<void>;
260
+
261
+ LoadEquippedProfileItems(e: boolean): Promise<void>;
262
+
263
+ LoadIfNecessary(): void;
264
+
265
+ /**
266
+ * Matches a provided string against the user's nickname.
267
+ *
268
+ * @param s The string to match.
269
+ */
270
+ MatchSearchString(s: string): {
271
+ bFullMatch: boolean;
272
+ iOffset: number;
273
+ match: number;
274
+ };
275
+
276
+ /**
277
+ * Opens the chat dialog.
278
+ */
279
+ OpenChatDialog(browser: BrowserContext): CChat;
280
+
281
+ SetLastSeenPlaying(appid: number): void;
282
+
283
+ SetPersonaStateUpdated(): void;
284
+
285
+ /**
286
+ * @returns `true` if app info is ready.
287
+ * @see {@link CAppInfoStore}
288
+ */
289
+ is_appinfo_ready(): boolean;
290
+
291
+ get accountid(): number;
292
+ get current_game_icon_url(): string;
293
+ get current_game_name(): string;
294
+ get current_game_rich_presence(): string;
295
+ get display_name(): string;
296
+ get efriendrelationship(): EFriendRelationship;
297
+ get has_nickname(): boolean;
298
+ get has_secondary_display_name(): boolean;
299
+ get is_blocked(): boolean;
300
+ get is_display_name_nickname(): boolean;
301
+ get is_friend(): boolean;
302
+ get is_ready(): boolean;
303
+ get localized_online_status(): string;
304
+ get miniProfileData(): MiniProfileData;
305
+ get mutable_persona(): CPersonaStateImpl;
306
+ // undefined until set, just use display_name
307
+ get nickname(): string | undefined;
308
+ set nickname(s: string);
309
+ get notification_settings(): PerFriendNotificationSettings;
310
+ get persona(): CPersonaStateImpl;
311
+ get persona_name_history(): string[];
312
+ get persona_name_history_loaded(): boolean;
313
+ get primary_display_name(): string;
314
+ get secondary_display_name(): string;
315
+ get showing_secondary_display_name(): boolean;
316
+ get steamid(): CSteamID;
317
+ get steamid64(): string;
318
+ }
@@ -0,0 +1,367 @@
1
+ import type { CSteamID } from '../shared';
2
+ import type { CBaseProtoBufMsg, CScheduledFunc } from '../shared/interfaces';
3
+ import type { EUCMFilePrivacyState } from '../steam-client/Screenshots';
4
+ import type { EExportCodec } from '../steam-client/Settings';
5
+ import type { EResult } from '../steam-client/shared';
6
+
7
+ // #region TODO(protobufs): generate
8
+ interface CGameRecording_ExportClip_Settings {
9
+ bitrate_kbps?: number;
10
+ width?: number;
11
+ height?: number;
12
+ frames_per_second?: number;
13
+ codec?: EExportCodec;
14
+ }
15
+
16
+ interface CGameRecordingTimelineEvent {
17
+ game_id: string;
18
+ rt_created: number;
19
+ possible_clip: number;
20
+ timeline_id: string;
21
+ entry_id: string;
22
+ timeline_offset_ms: string;
23
+ duration_ms: string;
24
+ marker_icon: string;
25
+ marker_title: string;
26
+ user_marker: boolean;
27
+ }
28
+ // #endregion
29
+
30
+ export interface PlaybackDefinition_t {
31
+ m_nDurationMS: number;
32
+ m_nOffsetMS: number;
33
+ m_nTimelineStartMS: number;
34
+ m_strEntryID: string;
35
+ m_strRecordingID: string;
36
+ m_strTimelineID: string;
37
+ }
38
+
39
+ interface RunningTimeline_t {
40
+ m_globalStartMS: number;
41
+ m_metadata: {
42
+ date_recorded: number;
43
+ duration_ms: string;
44
+ game_id: string;
45
+ recordings: any[];
46
+ timeline_id: string;
47
+ };
48
+ m_nPerfCounterOffsetMS: number;
49
+ m_perfCounterStart: number;
50
+ m_runningRecording: any;
51
+ }
52
+
53
+ interface TimelineData_t {
54
+ m_rgEntries: any[];
55
+ m_rgGameModeChanges: any[];
56
+ m_rgPhases: any[];
57
+ m_rgStateDescriptions: any[];
58
+ m_strState: string;
59
+ }
60
+
61
+ interface TimelineLoader {
62
+ m_bInitialized: boolean;
63
+ m_clipID: string;
64
+ m_fnTimelineURLBuilder: (e: string) => string;
65
+ m_gameID: string;
66
+ m_mapRunningTimelines: Map<string, RunningTimeline_t>;
67
+ m_mapTimelineData: Map<string, TimelineData_t>;
68
+ m_rgListeners: any[];
69
+ m_rgTimelineMetadata: any[];
70
+ m_schUpdateRunning: CScheduledFunc;
71
+ m_ulFirstTimelineOffsetMS: number;
72
+
73
+ AddEventListener(e: any): any;
74
+ AddEventToTimeline(e: any, t: any, r: any, n: any, i: any, a: any, s: any, o: any): any;
75
+ AddRunningTimeline(e: any, t: any, r: any): any;
76
+ AddRunningTimelineEntry(e: any): any;
77
+ AddUserMarker(e: any, t: any, r: any, n: any): any;
78
+ AdvanceEntriesIndex(e: any): any;
79
+ AdvanceGameModeIndex(e: any): any;
80
+ AdvanceIterator(e: any, t: any): any;
81
+ BInitialized(): any;
82
+ BIsTimelineRunning(e: any): any;
83
+ BRecordingHasZeroOffset(e: any): any;
84
+ ClampGlobalRangeToTimeline(e: any, t: any, r: any): any;
85
+ ConvertGlobaOffsetToRecordingAndRelativeOffset(e: any): any;
86
+ ConvertRecordingOffsetToGlobalOffset(e: any, t: any, r: any): any;
87
+ ConvertRecordingTimeMStoPreTrimTimeMS(e: any, t: any): any;
88
+ CreateGlobalRangeForTimeline(e: any, t: any, r: any, n: any): any;
89
+ CreateTimelineIterator(e: any, t: any): any;
90
+ FindRangeEventsAtGlobalMS(e: any): any;
91
+ FindRecordingAndOffsetForEntry(e: any): Promise<any>;
92
+ FindTimelineAtOffset(e: any, t: any): any;
93
+ FireEvent(e: any, ...t: any): any;
94
+ GenerateClipNameFromTimeline(e: any, t: any, r: any, n: any): Promise<any>;
95
+ GenerateNamePartsFromTimeline(e: any, t: any, r: any, n: any): Promise<any>;
96
+ GetClipID(): any;
97
+ GetClosestNextEntryInGlobalTimeline(e: any): any;
98
+ GetClosestNextEntryInTimeline(e: any, t: any): any;
99
+ GetClosestNextRecordingInGlobalTimeline(e: any): any;
100
+ GetClosestPreviousEntryInGlobalTimeline(e: any): any;
101
+ GetClosestPreviousEntryInTimeline(e: any, t: any): any;
102
+ GetClosestPreviousRecordingInGlobalTimeline(e: any): any;
103
+ GetEndOfRecordingsMS(): any;
104
+ GetFirstRecording(): any;
105
+ GetFirstRecordingOfLastTimelineSession(): any;
106
+ GetGameID(): any;
107
+ GetGlobalOffsetDataForTimeline(e: any, t: any): any;
108
+ GetGlobalTimelineEndMS(): any;
109
+ GetIteratorGameMode(e: any): any;
110
+ GetIteratorTimelineState(e: any): any;
111
+ GetNextRecording(e: any): any;
112
+ GetRunningTimelineDurationMS(e: any): any;
113
+ GetRunningTimelineForRecording(e: any, t: any): any;
114
+ GetStateDescriptionAtGlobalMS(e: any): any;
115
+ GetTimelineData(e: any): any;
116
+ GetTimelineDataOrStartLoad(e: any): any;
117
+ GetTimelineDateMS(e: any, t: any): any;
118
+ GetTimelineMetadata(e: any): any;
119
+ GetTimelineMetadataIndex(e: any): any;
120
+ GetTimelineOffsetFromGlobal(e: any, t: any): any;
121
+ GetTimelineStartBeforeGlobalZeroMS(e: any): any;
122
+ GetTimelines(): any;
123
+ GetTotalRecordingDuration(): any;
124
+ HasIteratorReachedEnd(e: any): any;
125
+ InsertEntryIntoTimelineSorted(e: any, t: any): any;
126
+ IsActiveRecording(e: any): any;
127
+ IsActiveTimeline(e: any): any;
128
+ LoadTimelineData(e: any): Promise<any>;
129
+ LoadTimelinesForBackgroundVideo(e: any): Promise<any>;
130
+ LoadTimelinesForClip(e: any): Promise<any>;
131
+ LoadTimelinesForSharedClip(e: any): any;
132
+ LoadTimelinesForTestClip(e: any, t: any, r: any, n: any): any;
133
+ LoadTimelinesForTestGame(e: any, t: any): any;
134
+ MakeRelativeToTimelineEndIfActive(e: any, t: any): any;
135
+ ProcessTimelineEntries(e: any): any;
136
+ RecordingSessionChanged(e: any): any;
137
+ RemoveTimelineEvent(e: any, t: any): any;
138
+ RemoveUserMarker(e: any, t: any): any;
139
+ RunningTimelineStopped(e: any, t: any): any;
140
+ SetPreloadedTimelines(e: any, t: any, r: any, n: any, i: any): any;
141
+ SetTimelineData(e: any, t: any): any;
142
+ TimelineDeleted(e: any): any;
143
+ UpdateTimelineMetadata(e: any): any;
144
+ UpdateUserMarker(e: any, t: any, r: any): any;
145
+ }
146
+
147
+ interface CActiveTimeline {
148
+ loader: TimelineLoader;
149
+ release(): void;
150
+ }
151
+
152
+ declare class CTimelineEntry {}
153
+
154
+ declare class CTimelineLoader {
155
+ loader: TimelineLoader;
156
+ nRefCount: number;
157
+ }
158
+
159
+ export interface ClipSummary_t {
160
+ clip_id: string;
161
+ date_clipped: number;
162
+ date_recorded: number;
163
+ duration_ms: string;
164
+ file_size: string;
165
+ game_id: string;
166
+ start_timeline_id: string;
167
+ start_offset_ms: string;
168
+ temporary: boolean;
169
+ thumbnail_height: number;
170
+ thumbnail_url: string;
171
+ thumbnail_width: number;
172
+ }
173
+
174
+ interface ClipExportProgress_t {
175
+ exportPath: string;
176
+ /** 0 - 1 in percentage */
177
+ progress: number;
178
+ resultStatus: EResult;
179
+ }
180
+
181
+ /**
182
+ * @see CGameRecording_GetAppsWithBackgroundVideo_Response
183
+ */
184
+ interface AppWithTimeline_t {
185
+ file_size: string;
186
+ game_id: string;
187
+ is_active: boolean;
188
+ most_recent_start_time: number;
189
+ recording_type: number;
190
+ timeline_duration_seconds: number;
191
+ video_duration_seconds: number;
192
+ }
193
+
194
+ export declare class CGameRecordingStore {
195
+ m_bClipLoadingTriggered: boolean;
196
+ m_bEnoughDiskSpace: boolean;
197
+ m_bLoadingAppsWithBackgroundVideo: boolean;
198
+ m_bLoadingClips: boolean;
199
+ m_clipExportProgress: Map<string, ClipExportProgress_t>;
200
+ m_clips: Map<string, ClipSummary_t>;
201
+ m_clipsGroupByGame: Map<string, ClipSummary_t[]>;
202
+ m_currentlyExportingClip: string | undefined;
203
+ m_fnGetAchievementInfo: (
204
+ appid: number,
205
+ id: string,
206
+ ) => {
207
+ description: string;
208
+ iconURL: string;
209
+ name: string;
210
+ };
211
+ m_mapActiveTimelines: Map<string, CActiveTimeline>;
212
+ m_mapManualRecordingCallbacks: Map<string, any>;
213
+ m_mapSharedClipLoaders: Map<string, TimelineLoader>;
214
+ m_mapTimelineLoaders: Map<string, CTimelineLoader>;
215
+ m_recordingState: { m_gameID: string } | null;
216
+ m_rgAppsWithTimelines: AppWithTimeline_t[];
217
+ m_strLastClipID: string | undefined;
218
+ m_transport: any;
219
+
220
+ /**
221
+ * @returns `true` if not enough space on disk for clips.
222
+ */
223
+ BEnoughDiskSpace(): boolean;
224
+
225
+ BLoadingAppsWithBackgroundVideo(): boolean;
226
+
227
+ /**
228
+ * @returns `true` if clips are loading.
229
+ */
230
+ BLoadingClips(): boolean;
231
+
232
+ /**
233
+ * Forces a check for disk space.
234
+ */
235
+ CheckEnoughDiskSpace(): Promise<void>;
236
+
237
+ CreateUserTimelineMarkers(
238
+ game_id: string,
239
+ clip_id: string,
240
+ entry: CTimelineEntry,
241
+ ): Promise<{ eResult: EResult; entry_id: string }>;
242
+
243
+ /**
244
+ * Deletes a local clip.
245
+ */
246
+ DeleteClip(clip_id: string): Promise<EResult>;
247
+
248
+ ExportClip(
249
+ clip_id: string,
250
+ export_mp4_path: string,
251
+ settings: CGameRecording_ExportClip_Settings,
252
+ use_unique_filename: boolean,
253
+ ): Promise<EResult>;
254
+
255
+ /**
256
+ * @param appid App ID of the game to get info for.
257
+ * @param id Example: `"TF_BURN_PLAYERSINMINIMUMTIME"` for Team Fortress 2.
258
+ */
259
+ GetAchievementInfo(
260
+ appid: number,
261
+ id: string,
262
+ ): {
263
+ description: string;
264
+ iconURL: string;
265
+ name: string;
266
+ };
267
+
268
+ GetAppsWithBackgroundVideo(): AppWithTimeline_t[];
269
+
270
+ /**
271
+ * @returns the available disk space in bytes.
272
+ */
273
+ GetAvailableDiskSpace(): Promise<number>;
274
+
275
+ /**
276
+ * @returns the clip's title or the localized recorded date.
277
+ */
278
+ GetBestClipTitle(clip_id: string): string;
279
+
280
+ /**
281
+ * @returns the clip's export progress or `undefined` if not exporting(-ed).
282
+ */
283
+ GetClipExportProgress(clipID: string): ClipExportProgress_t | undefined;
284
+
285
+ /**
286
+ * @returns all clip IDs for a specified game.
287
+ */
288
+ GetClipIDs(gameid: string): string[];
289
+
290
+ /**
291
+ * @returns clips for the valid clip IDs.
292
+ */
293
+ GetClipSummaries(clipIDs: string[]): ClipSummary_t[];
294
+
295
+ /**
296
+ * @returns all clips for a provided game or `null` if none.
297
+ */
298
+ GetClipSummariesForGame(gameid: string): ClipSummary_t[] | null;
299
+
300
+ /**
301
+ * @returns a clip from a provided clip ID.
302
+ */
303
+ GetClipSummary(clipID: string): ClipSummary_t;
304
+
305
+ /**
306
+ * @returns the current exporting clip's ID or `null` if not exporting.
307
+ */
308
+ GetCurrentExportingClip(): string | null;
309
+
310
+ /**
311
+ * @returns the last clip.
312
+ */
313
+ GetLastClip(): ClipSummary_t | undefined;
314
+
315
+ GetRecordingHighlights(gameid: string, createdAfter?: number): Promise<CGameRecordingTimelineEvent[]>;
316
+ GetRecordingState(): this['m_recordingState'];
317
+ GetTimelineLoaderForClip(clip_id: string): CTimelineLoader;
318
+ GetTimelineLoaderForGame(gameid: string): CTimelineLoader;
319
+ GetTimelineLoaderForSharedClip(clip: ClipSummary_t): CTimelineLoader;
320
+ GetTotalDiskSpaceUsage(path: string, t: boolean): Promise<number>;
321
+ InternalAddClipSummary(clip: ClipSummary_t): void;
322
+ LazyLoadClips(): Promise<void>;
323
+ LoadAppsWithBackgroundVideo(): Promise<void>;
324
+ LoadThumbnails(
325
+ recording_id: string,
326
+ clip_id: string,
327
+ timeline_id: string,
328
+ start_offset_us: number[],
329
+ major_axis: number,
330
+ time_precision: boolean,
331
+ ): any;
332
+ // TODO: unused ?
333
+ ManuallyDeleteRecordingForApps(game_ids: string[]): any;
334
+ RegisterManualRecordingCallback(e: string, t: any): () => void;
335
+ ReloadAppsWithBackgroundVideoIfNecessary(e: any): void;
336
+ ReportClipRange(steamid: CSteamID, rangeMethod: any, seconds: any, startRange: any, endRange: any): any;
337
+ ReportClipShare(steamid: CSteamID, shareMethod: any, seconds: any, bytes: number, result: EResult): any;
338
+ SaveClip(
339
+ game_id: string,
340
+ src_clip_id: string,
341
+ name: string,
342
+ start: { timeline_id: string; offset_ms: string },
343
+ end: { timeline_id: string; offset_ms: string },
344
+ temporary: boolean,
345
+ force_thumbnail: boolean,
346
+ ): Promise<{ clipSummary?: ClipSummary_t; result: EResult }>;
347
+ StartRecording(gameid: string): Promise<CBaseProtoBufMsg>;
348
+ StopRecording(gameid: string): Promise<void>;
349
+ SwitchRecordedGame(gameid: string): Promise<CBaseProtoBufMsg>;
350
+ TakeScreenshot(
351
+ game_id: string,
352
+ timeline_id: string,
353
+ timeline_offset_ms: string,
354
+ ): Promise<{ handle?: number; result: EResult }>;
355
+ UpdateClipExportPath(clip_id: string, path: string): void;
356
+ UpdateUserTimelineMarkers(game_id: string, clip_id: string, entry: CTimelineEntry): Promise<EResult>;
357
+
358
+ /**
359
+ * Uploads a clip to the Steam community.
360
+ */
361
+ UploadClip(
362
+ clip_id: string,
363
+ title?: string,
364
+ desc?: string,
365
+ visibility?: EUCMFilePrivacyState,
366
+ ): Promise<{ eResult: EResult; strURL: string | undefined }>;
367
+ }
@@ -0,0 +1,18 @@
1
+ export * from './app';
2
+ export * from './appdetailsstore';
3
+ export * from './appstore';
4
+ export * from './badgestore';
5
+ export * from './collectionstore';
6
+ export * from './consolestore';
7
+ export * from './focusnavcontroller';
8
+ export * from './friendstore';
9
+ export * from './gamerecordingstore';
10
+ export * from './libraryuistore';
11
+ export * from './localizationmanager';
12
+ export * from './mainwindowbrowsermanager';
13
+ export * from './notificationstore';
14
+ export * from './popupmanager';
15
+ export * from './securitystore';
16
+ export * from './settingsstore';
17
+ export * from './steamuistore';
18
+ export * from './urlstore';