@ksp-gonogo/sitrep-sdk 1.0.0-rc.21 → 2.0.0-rc.23

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 (489) hide show
  1. package/README.md +6 -0
  2. package/dist/__generated__/command-map.d.ts +140 -11
  3. package/dist/__generated__/command-map.d.ts.map +1 -1
  4. package/dist/__generated__/command-map.js +6 -3
  5. package/dist/__generated__/command-map.js.map +1 -1
  6. package/dist/__generated__/contract.d.ts +591 -425
  7. package/dist/__generated__/contract.d.ts.map +1 -1
  8. package/dist/__generated__/contract.js +34 -4
  9. package/dist/__generated__/contract.js.map +1 -1
  10. package/dist/__generated__/error-codes.d.ts +46 -55
  11. package/dist/__generated__/error-codes.d.ts.map +1 -1
  12. package/dist/__generated__/error-codes.js +76 -69
  13. package/dist/__generated__/error-codes.js.map +1 -1
  14. package/dist/__generated__/test-theme.d.ts +3 -0
  15. package/dist/__generated__/test-theme.d.ts.map +1 -1
  16. package/dist/__generated__/test-theme.js +3 -0
  17. package/dist/__generated__/test-theme.js.map +1 -1
  18. package/dist/__generated__/topic-map.d.ts +90 -2
  19. package/dist/__generated__/topic-map.d.ts.map +1 -1
  20. package/dist/__generated__/topic-map.js +2 -0
  21. package/dist/__generated__/topic-map.js.map +1 -1
  22. package/dist/__generated__/units.d.ts.map +1 -1
  23. package/dist/__generated__/units.js +89 -47
  24. package/dist/__generated__/units.js.map +1 -1
  25. package/dist/api/alarm-request.d.ts +6 -1
  26. package/dist/api/alarm-request.d.ts.map +1 -1
  27. package/dist/api/alarm-request.js +7 -1
  28. package/dist/api/alarm-request.js.map +1 -1
  29. package/dist/api/contribution-slots.d.ts +87 -17
  30. package/dist/api/contribution-slots.d.ts.map +1 -1
  31. package/dist/api/coverage/CoverageMaskCache.d.ts +1 -1
  32. package/dist/api/coverage/CoverageMaskCache.js +1 -1
  33. package/dist/api/coverage-source.d.ts +3 -1
  34. package/dist/api/coverage-source.d.ts.map +1 -1
  35. package/dist/api/coverage-source.js +3 -1
  36. package/dist/api/coverage-source.js.map +1 -1
  37. package/dist/api/framework-reads.d.ts +20 -0
  38. package/dist/api/framework-reads.d.ts.map +1 -0
  39. package/dist/api/framework-reads.js +30 -0
  40. package/dist/api/framework-reads.js.map +1 -0
  41. package/dist/api/host.d.ts +8 -5
  42. package/dist/api/host.d.ts.map +1 -1
  43. package/dist/api/host.js.map +1 -1
  44. package/dist/api/index.d.ts +96 -17
  45. package/dist/api/index.d.ts.map +1 -1
  46. package/dist/api/index.js +91 -10
  47. package/dist/api/index.js.map +1 -1
  48. package/dist/api/logger.d.ts +14 -2
  49. package/dist/api/logger.d.ts.map +1 -1
  50. package/dist/api/logger.js +14 -2
  51. package/dist/api/logger.js.map +1 -1
  52. package/dist/api/plot-layers.d.ts +81 -6
  53. package/dist/api/plot-layers.d.ts.map +1 -1
  54. package/dist/api/plot-layers.js +4 -3
  55. package/dist/api/plot-layers.js.map +1 -1
  56. package/dist/api/plots.d.ts +19 -0
  57. package/dist/api/plots.d.ts.map +1 -1
  58. package/dist/api/registry.d.ts +11 -0
  59. package/dist/api/registry.d.ts.map +1 -1
  60. package/dist/api/registry.js.map +1 -1
  61. package/dist/api/settings/SettingsContext.d.ts +5 -4
  62. package/dist/api/settings/SettingsContext.d.ts.map +1 -1
  63. package/dist/api/settings/SettingsContext.js +13 -4
  64. package/dist/api/settings/SettingsContext.js.map +1 -1
  65. package/dist/api/settings/SettingsService.d.ts +3 -0
  66. package/dist/api/settings/SettingsService.d.ts.map +1 -1
  67. package/dist/api/settings/SettingsService.js +3 -0
  68. package/dist/api/settings/SettingsService.js.map +1 -1
  69. package/dist/api/settings/store.d.ts +3 -1
  70. package/dist/api/settings/store.d.ts.map +1 -1
  71. package/dist/api/settings/store.js +3 -1
  72. package/dist/api/settings/store.js.map +1 -1
  73. package/dist/api/slots.d.ts +94 -17
  74. package/dist/api/slots.d.ts.map +1 -1
  75. package/dist/api/station-brokers.d.ts +2 -1
  76. package/dist/api/station-brokers.d.ts.map +1 -1
  77. package/dist/api/station-brokers.js +2 -1
  78. package/dist/api/station-brokers.js.map +1 -1
  79. package/dist/api/stock-bodies.d.ts.map +1 -1
  80. package/dist/api/stock-bodies.js +6 -0
  81. package/dist/api/stock-bodies.js.map +1 -1
  82. package/dist/api/tiny-size.d.ts +2 -0
  83. package/dist/api/tiny-size.d.ts.map +1 -1
  84. package/dist/api/tiny-size.js +6 -1
  85. package/dist/api/tiny-size.js.map +1 -1
  86. package/dist/api/tone.d.ts +7 -4
  87. package/dist/api/tone.d.ts.map +1 -1
  88. package/dist/api/tone.js.map +1 -1
  89. package/dist/api/transport.d.ts +10 -2
  90. package/dist/api/transport.d.ts.map +1 -1
  91. package/dist/api/types.d.ts +179 -120
  92. package/dist/api/types.d.ts.map +1 -1
  93. package/dist/binary-frame.d.ts +26 -25
  94. package/dist/binary-frame.d.ts.map +1 -1
  95. package/dist/binary-frame.js +25 -25
  96. package/dist/binary-frame.js.map +1 -1
  97. package/dist/client.d.ts.map +1 -1
  98. package/dist/client.js +2 -0
  99. package/dist/client.js.map +1 -1
  100. package/dist/combine-readings.d.ts +8 -4
  101. package/dist/combine-readings.d.ts.map +1 -1
  102. package/dist/combine-readings.js +6 -4
  103. package/dist/combine-readings.js.map +1 -1
  104. package/dist/command-delay.d.ts +6 -0
  105. package/dist/command-delay.d.ts.map +1 -1
  106. package/dist/command-delay.js.map +1 -1
  107. package/dist/commands.d.ts +1 -1
  108. package/dist/commands.d.ts.map +1 -1
  109. package/dist/compat-versions.d.ts +1 -1
  110. package/dist/compat-versions.d.ts.map +1 -1
  111. package/dist/compat-versions.js +2 -2
  112. package/dist/compat-versions.js.map +1 -1
  113. package/dist/contract-enum-names.d.ts +2 -3
  114. package/dist/contract-enum-names.d.ts.map +1 -1
  115. package/dist/contract-enum-names.js +2 -3
  116. package/dist/contract-enum-names.js.map +1 -1
  117. package/dist/enum-names.d.ts +5 -3
  118. package/dist/enum-names.d.ts.map +1 -1
  119. package/dist/enum-names.js +5 -3
  120. package/dist/enum-names.js.map +1 -1
  121. package/dist/envelope.d.ts +3 -3
  122. package/dist/envelope.d.ts.map +1 -1
  123. package/dist/flight/BufferedDataSource.d.ts.map +1 -1
  124. package/dist/flight/BufferedDataSource.js +4 -2
  125. package/dist/flight/BufferedDataSource.js.map +1 -1
  126. package/dist/flight/types.d.ts +3 -2
  127. package/dist/flight/types.d.ts.map +1 -1
  128. package/dist/frames/index.d.ts +19 -17
  129. package/dist/frames/index.d.ts.map +1 -1
  130. package/dist/frames/index.js +13 -12
  131. package/dist/frames/index.js.map +1 -1
  132. package/dist/index.d.ts +20 -3
  133. package/dist/index.d.ts.map +1 -1
  134. package/dist/index.js +18 -3
  135. package/dist/index.js.map +1 -1
  136. package/dist/ksp-enum-names.d.ts +23 -8
  137. package/dist/ksp-enum-names.d.ts.map +1 -1
  138. package/dist/ksp-enum-names.js +20 -8
  139. package/dist/ksp-enum-names.js.map +1 -1
  140. package/dist/media/radio-support.d.ts +12 -3
  141. package/dist/media/radio-support.d.ts.map +1 -1
  142. package/dist/media/radio-support.js +12 -3
  143. package/dist/media/radio-support.js.map +1 -1
  144. package/dist/perf/PerfBudget.d.ts +7 -5
  145. package/dist/perf/PerfBudget.d.ts.map +1 -1
  146. package/dist/perf/PerfBudget.js +8 -6
  147. package/dist/perf/PerfBudget.js.map +1 -1
  148. package/dist/reading.d.ts +12 -2
  149. package/dist/reading.d.ts.map +1 -1
  150. package/dist/reading.js +7 -2
  151. package/dist/reading.js.map +1 -1
  152. package/dist/reads-index.json +3675 -0
  153. package/dist/spine/body-pose.d.ts +85 -0
  154. package/dist/spine/body-pose.d.ts.map +1 -0
  155. package/dist/spine/body-pose.js +166 -0
  156. package/dist/spine/body-pose.js.map +1 -0
  157. package/dist/spine/capability-lock.d.ts +6 -2
  158. package/dist/spine/capability-lock.d.ts.map +1 -1
  159. package/dist/spine/capability-lock.js +8 -2
  160. package/dist/spine/capability-lock.js.map +1 -1
  161. package/dist/spine/catalogue-elements.d.ts +28 -0
  162. package/dist/spine/catalogue-elements.d.ts.map +1 -0
  163. package/dist/spine/catalogue-elements.js +63 -0
  164. package/dist/spine/catalogue-elements.js.map +1 -0
  165. package/dist/spine/celestial-facts.d.ts +5 -7
  166. package/dist/spine/celestial-facts.d.ts.map +1 -1
  167. package/dist/spine/celestial-facts.js +10 -21
  168. package/dist/spine/celestial-facts.js.map +1 -1
  169. package/dist/spine/client-timeline.d.ts +10 -12
  170. package/dist/spine/client-timeline.d.ts.map +1 -1
  171. package/dist/spine/client-timeline.js.map +1 -1
  172. package/dist/spine/client.d.ts +31 -0
  173. package/dist/spine/client.d.ts.map +1 -1
  174. package/dist/spine/client.js +97 -19
  175. package/dist/spine/client.js.map +1 -1
  176. package/dist/spine/command-gate.d.ts +13 -11
  177. package/dist/spine/command-gate.d.ts.map +1 -1
  178. package/dist/spine/command-gate.js +2 -2
  179. package/dist/spine/command-gate.js.map +1 -1
  180. package/dist/spine/command-group.d.ts +62 -0
  181. package/dist/spine/command-group.d.ts.map +1 -0
  182. package/dist/spine/command-group.js +172 -0
  183. package/dist/spine/command-group.js.map +1 -0
  184. package/dist/spine/comms-delay-reckoning.js.map +1 -1
  185. package/dist/spine/comms-journey.d.ts +9 -0
  186. package/dist/spine/comms-journey.d.ts.map +1 -1
  187. package/dist/spine/comms-journey.js +27 -0
  188. package/dist/spine/comms-journey.js.map +1 -1
  189. package/dist/spine/comms-path-geometry.d.ts +3 -3
  190. package/dist/spine/comms-path-geometry.d.ts.map +1 -1
  191. package/dist/spine/comms-path-geometry.js.map +1 -1
  192. package/dist/spine/connection-error-warning.d.ts +1 -1
  193. package/dist/spine/connection-error-warning.js +1 -1
  194. package/dist/spine/context.d.ts.map +1 -1
  195. package/dist/spine/context.js +4 -0
  196. package/dist/spine/context.js.map +1 -1
  197. package/dist/spine/contributions.d.ts +13 -13
  198. package/dist/spine/contributions.js +13 -13
  199. package/dist/spine/core-reckoners.d.ts.map +1 -1
  200. package/dist/spine/core-reckoners.js +2 -2
  201. package/dist/spine/core-reckoners.js.map +1 -1
  202. package/dist/spine/held-command-actions.d.ts +3 -0
  203. package/dist/spine/held-command-actions.d.ts.map +1 -1
  204. package/dist/spine/held-command-actions.js +12 -7
  205. package/dist/spine/held-command-actions.js.map +1 -1
  206. package/dist/spine/impact-point.d.ts.map +1 -1
  207. package/dist/spine/impact-point.js +6 -29
  208. package/dist/spine/impact-point.js.map +1 -1
  209. package/dist/spine/index.d.ts +5 -0
  210. package/dist/spine/index.d.ts.map +1 -1
  211. package/dist/spine/index.js +5 -0
  212. package/dist/spine/index.js.map +1 -1
  213. package/dist/spine/kepler-reckoning.d.ts +2 -2
  214. package/dist/spine/kepler-reckoning.d.ts.map +1 -1
  215. package/dist/spine/kepler-reckoning.js.map +1 -1
  216. package/dist/spine/kepler.d.ts +8 -6
  217. package/dist/spine/kepler.d.ts.map +1 -1
  218. package/dist/spine/kepler.js +3 -1
  219. package/dist/spine/kepler.js.map +1 -1
  220. package/dist/spine/lagrange.d.ts +6 -6
  221. package/dist/spine/lagrange.d.ts.map +1 -1
  222. package/dist/spine/lagrange.js.map +1 -1
  223. package/dist/spine/lifecycle.d.ts +14 -0
  224. package/dist/spine/lifecycle.d.ts.map +1 -1
  225. package/dist/spine/lifecycle.js.map +1 -1
  226. package/dist/spine/lock-scope.d.ts +11 -1
  227. package/dist/spine/lock-scope.d.ts.map +1 -1
  228. package/dist/spine/lock-scope.js.map +1 -1
  229. package/dist/spine/map-command.d.ts +3 -11
  230. package/dist/spine/map-command.d.ts.map +1 -1
  231. package/dist/spine/map-command.js +3 -11
  232. package/dist/spine/map-command.js.map +1 -1
  233. package/dist/spine/mod-settings.d.ts.map +1 -1
  234. package/dist/spine/mod-settings.js +1 -0
  235. package/dist/spine/mod-settings.js.map +1 -1
  236. package/dist/spine/never-reckonable.d.ts.map +1 -1
  237. package/dist/spine/never-reckonable.js +8 -6
  238. package/dist/spine/never-reckonable.js.map +1 -1
  239. package/dist/spine/orbit-patches.d.ts +16 -4
  240. package/dist/spine/orbit-patches.d.ts.map +1 -1
  241. package/dist/spine/orbit-patches.js +12 -5
  242. package/dist/spine/orbit-patches.js.map +1 -1
  243. package/dist/spine/orbit-trajectory.d.ts +60 -3
  244. package/dist/spine/orbit-trajectory.d.ts.map +1 -1
  245. package/dist/spine/orbit-trajectory.js +133 -40
  246. package/dist/spine/orbit-trajectory.js.map +1 -1
  247. package/dist/spine/orbital-solve.js +1 -1
  248. package/dist/spine/own-craft-vantage.d.ts.map +1 -1
  249. package/dist/spine/own-craft-vantage.js +1 -0
  250. package/dist/spine/own-craft-vantage.js.map +1 -1
  251. package/dist/spine/past-track.d.ts +7 -7
  252. package/dist/spine/past-track.js +7 -7
  253. package/dist/spine/phase-angle.d.ts +19 -0
  254. package/dist/spine/phase-angle.d.ts.map +1 -0
  255. package/dist/spine/phase-angle.js +47 -0
  256. package/dist/spine/phase-angle.js.map +1 -0
  257. package/dist/spine/powered-reckoning.js.map +1 -1
  258. package/dist/spine/processors.d.ts +4 -1
  259. package/dist/spine/processors.d.ts.map +1 -1
  260. package/dist/spine/processors.js.map +1 -1
  261. package/dist/spine/reckoners.d.ts +3 -6
  262. package/dist/spine/reckoners.d.ts.map +1 -1
  263. package/dist/spine/reckoners.js +3 -6
  264. package/dist/spine/reckoners.js.map +1 -1
  265. package/dist/spine/reference-frame.d.ts +14 -14
  266. package/dist/spine/reference-frame.d.ts.map +1 -1
  267. package/dist/spine/reference-frame.js +3 -64
  268. package/dist/spine/reference-frame.js.map +1 -1
  269. package/dist/spine/settings-registry.d.ts +17 -9
  270. package/dist/spine/settings-registry.d.ts.map +1 -1
  271. package/dist/spine/settings-registry.js.map +1 -1
  272. package/dist/spine/settings-tabs.d.ts +4 -3
  273. package/dist/spine/settings-tabs.d.ts.map +1 -1
  274. package/dist/spine/settings-tabs.js.map +1 -1
  275. package/dist/spine/target-range-reckoning.d.ts.map +1 -1
  276. package/dist/spine/target-range-reckoning.js.map +1 -1
  277. package/dist/spine/timeline-store.d.ts +3 -1
  278. package/dist/spine/timeline-store.d.ts.map +1 -1
  279. package/dist/spine/timeline-store.js +2 -2
  280. package/dist/spine/timeline-store.js.map +1 -1
  281. package/dist/spine/topic-ownership.d.ts +2 -2
  282. package/dist/spine/topic-ownership.js +2 -2
  283. package/dist/spine/uplink-clients.d.ts +4 -4
  284. package/dist/spine/uplink-clients.d.ts.map +1 -1
  285. package/dist/spine/uplink-clients.js +1 -0
  286. package/dist/spine/uplink-clients.js.map +1 -1
  287. package/dist/spine/use-body-states.d.ts +3 -7
  288. package/dist/spine/use-body-states.d.ts.map +1 -1
  289. package/dist/spine/use-body-states.js +3 -7
  290. package/dist/spine/use-body-states.js.map +1 -1
  291. package/dist/spine/use-command.d.ts.map +1 -1
  292. package/dist/spine/use-command.js +151 -109
  293. package/dist/spine/use-command.js.map +1 -1
  294. package/dist/spine/use-data-sources.d.ts +2 -5
  295. package/dist/spine/use-data-sources.d.ts.map +1 -1
  296. package/dist/spine/use-data-sources.js.map +1 -1
  297. package/dist/spine/use-late-telemetry-subscribe.d.ts.map +1 -1
  298. package/dist/spine/use-late-telemetry-subscribe.js +1 -0
  299. package/dist/spine/use-late-telemetry-subscribe.js.map +1 -1
  300. package/dist/spine/use-orbit-curve.d.ts +33 -0
  301. package/dist/spine/use-orbit-curve.d.ts.map +1 -0
  302. package/dist/spine/use-orbit-curve.js +28 -0
  303. package/dist/spine/use-orbit-curve.js.map +1 -0
  304. package/dist/spine/use-orbit-trajectory.d.ts +6 -1
  305. package/dist/spine/use-orbit-trajectory.d.ts.map +1 -1
  306. package/dist/spine/use-orbit-trajectory.js +44 -2
  307. package/dist/spine/use-orbit-trajectory.js.map +1 -1
  308. package/dist/spine/use-selected-vantage.d.ts.map +1 -1
  309. package/dist/spine/use-selected-vantage.js +1 -0
  310. package/dist/spine/use-selected-vantage.js.map +1 -1
  311. package/dist/spine/use-system-instant.d.ts +16 -0
  312. package/dist/spine/use-system-instant.d.ts.map +1 -0
  313. package/dist/spine/use-system-instant.js +20 -0
  314. package/dist/spine/use-system-instant.js.map +1 -0
  315. package/dist/spine/use-transmissions.d.ts.map +1 -1
  316. package/dist/spine/use-transmissions.js +1 -0
  317. package/dist/spine/use-transmissions.js.map +1 -1
  318. package/dist/spine/view-clock.d.ts +1 -1
  319. package/dist/spine/view-clock.d.ts.map +1 -1
  320. package/dist/spine/view-clock.js +13 -3
  321. package/dist/spine/view-clock.js.map +1 -1
  322. package/dist/system-instant.d.ts +16 -0
  323. package/dist/system-instant.d.ts.map +1 -0
  324. package/dist/system-instant.js +20 -0
  325. package/dist/system-instant.js.map +1 -0
  326. package/dist/testing/console-logger.d.ts +3 -3
  327. package/dist/testing/console-logger.js +3 -3
  328. package/dist/testing/fake-wall-clock.d.ts +4 -2
  329. package/dist/testing/fake-wall-clock.d.ts.map +1 -1
  330. package/dist/testing/fake-wall-clock.js +4 -2
  331. package/dist/testing/fake-wall-clock.js.map +1 -1
  332. package/dist/testing/install-act-gate-stretch.d.ts +9 -0
  333. package/dist/testing/install-act-gate-stretch.d.ts.map +1 -1
  334. package/dist/testing/install-act-gate-stretch.js +9 -0
  335. package/dist/testing/install-act-gate-stretch.js.map +1 -1
  336. package/dist/testing/install-real-test-host.d.ts +4 -1
  337. package/dist/testing/install-real-test-host.d.ts.map +1 -1
  338. package/dist/testing/install-real-test-host.js +2 -0
  339. package/dist/testing/install-real-test-host.js.map +1 -1
  340. package/dist/testing/memory-storage.d.ts +2 -3
  341. package/dist/testing/memory-storage.d.ts.map +1 -1
  342. package/dist/testing/memory-storage.js +6 -5
  343. package/dist/testing/memory-storage.js.map +1 -1
  344. package/dist/testing/mock-data-source.d.ts +2 -2
  345. package/dist/testing/render.d.ts +4 -2
  346. package/dist/testing/render.d.ts.map +1 -1
  347. package/dist/testing/render.js +4 -2
  348. package/dist/testing/render.js.map +1 -1
  349. package/dist/testing/stub-transport.d.ts +6 -0
  350. package/dist/testing/stub-transport.d.ts.map +1 -1
  351. package/dist/testing/stub-transport.js +64 -52
  352. package/dist/testing/stub-transport.js.map +1 -1
  353. package/dist/timeline.d.ts +14 -6
  354. package/dist/timeline.d.ts.map +1 -1
  355. package/dist/topic-fields.d.ts +1 -0
  356. package/dist/topic-fields.d.ts.map +1 -1
  357. package/dist/topic-fields.js.map +1 -1
  358. package/dist/topics.d.ts +42 -2
  359. package/dist/topics.d.ts.map +1 -1
  360. package/dist/topics.js +33 -24
  361. package/dist/topics.js.map +1 -1
  362. package/dist/unit-system/registry.d.ts +11 -0
  363. package/dist/unit-system/registry.d.ts.map +1 -1
  364. package/dist/unit-system/registry.js.map +1 -1
  365. package/dist/unit-system/value.d.ts +3 -0
  366. package/dist/unit-system/value.d.ts.map +1 -1
  367. package/dist/unit-system/value.js.map +1 -1
  368. package/dist/units.js +1 -1
  369. package/dist/uplink-externals.d.ts +9 -4
  370. package/dist/uplink-externals.d.ts.map +1 -1
  371. package/dist/uplink-externals.js +9 -4
  372. package/dist/uplink-externals.js.map +1 -1
  373. package/dist/uplink-manifest.d.ts +62 -16
  374. package/dist/uplink-manifest.d.ts.map +1 -1
  375. package/dist/uplink-manifest.js.map +1 -1
  376. package/package.json +4 -3
  377. package/src/__generated__/command-map.ts +140 -10
  378. package/src/__generated__/contract.ts +598 -429
  379. package/src/__generated__/error-codes.ts +76 -69
  380. package/src/__generated__/test-theme.ts +3 -0
  381. package/src/__generated__/topic-map.ts +92 -0
  382. package/src/__generated__/units.json +630 -52
  383. package/src/__generated__/units.ts +89 -47
  384. package/src/api/alarm-request.ts +7 -1
  385. package/src/api/contribution-slots.ts +95 -20
  386. package/src/api/coverage/CoverageMaskCache.ts +1 -1
  387. package/src/api/coverage-source.ts +3 -1
  388. package/src/api/framework-reads.ts +29 -0
  389. package/src/api/host.ts +13 -4
  390. package/src/api/index.ts +113 -14
  391. package/src/api/logger.ts +14 -2
  392. package/src/api/plot-layers.ts +72 -6
  393. package/src/api/plots.ts +19 -0
  394. package/src/api/registry.ts +11 -0
  395. package/src/api/settings/SettingsContext.tsx +17 -5
  396. package/src/api/settings/SettingsService.ts +3 -0
  397. package/src/api/settings/store.ts +3 -1
  398. package/src/api/slots.ts +97 -28
  399. package/src/api/station-brokers.ts +2 -1
  400. package/src/api/stock-bodies.ts +6 -0
  401. package/src/api/tiny-size.ts +6 -1
  402. package/src/api/tone.ts +7 -4
  403. package/src/api/transport.ts +13 -2
  404. package/src/api/types.ts +214 -154
  405. package/src/binary-frame.ts +26 -25
  406. package/src/client.ts +2 -0
  407. package/src/combine-readings.ts +8 -4
  408. package/src/command-delay.ts +6 -0
  409. package/src/compat-versions.ts +2 -2
  410. package/src/contract-enum-names.ts +2 -3
  411. package/src/enum-names.ts +5 -3
  412. package/src/envelope.ts +9 -1
  413. package/src/flight/BufferedDataSource.ts +4 -2
  414. package/src/flight/types.ts +3 -2
  415. package/src/frames/index.ts +29 -16
  416. package/src/index.ts +32 -0
  417. package/src/ksp-enum-names.ts +23 -8
  418. package/src/media/radio-support.ts +12 -3
  419. package/src/perf/PerfBudget.ts +8 -6
  420. package/src/reading.ts +20 -4
  421. package/src/spine/body-pose.ts +251 -0
  422. package/src/spine/capability-lock.ts +17 -4
  423. package/src/spine/catalogue-elements.ts +75 -0
  424. package/src/spine/celestial-facts.ts +10 -35
  425. package/src/spine/client-timeline.ts +10 -12
  426. package/src/spine/client.ts +127 -19
  427. package/src/spine/command-gate.ts +13 -11
  428. package/src/spine/command-group.ts +278 -0
  429. package/src/spine/comms-delay-reckoning.ts +2 -2
  430. package/src/spine/comms-journey.ts +29 -0
  431. package/src/spine/comms-path-geometry.ts +4 -4
  432. package/src/spine/connection-error-warning.ts +1 -1
  433. package/src/spine/context.tsx +4 -0
  434. package/src/spine/contributions.ts +13 -13
  435. package/src/spine/core-reckoners.ts +2 -5
  436. package/src/spine/held-command-actions.ts +18 -6
  437. package/src/spine/impact-point.ts +8 -35
  438. package/src/spine/index.ts +5 -0
  439. package/src/spine/kepler-reckoning.ts +2 -2
  440. package/src/spine/kepler.ts +9 -7
  441. package/src/spine/lagrange.ts +6 -6
  442. package/src/spine/lifecycle.ts +14 -0
  443. package/src/spine/lock-scope.ts +11 -1
  444. package/src/spine/map-command.ts +3 -11
  445. package/src/spine/mod-settings.ts +1 -0
  446. package/src/spine/never-reckonable.ts +8 -6
  447. package/src/spine/orbit-patches.ts +33 -6
  448. package/src/spine/orbit-trajectory.ts +172 -57
  449. package/src/spine/orbital-solve.ts +1 -1
  450. package/src/spine/own-craft-vantage.tsx +1 -0
  451. package/src/spine/past-track.ts +7 -7
  452. package/src/spine/phase-angle.ts +51 -0
  453. package/src/spine/powered-reckoning.ts +16 -16
  454. package/src/spine/processors.ts +4 -1
  455. package/src/spine/reckoners.ts +3 -6
  456. package/src/spine/reference-frame.ts +49 -115
  457. package/src/spine/settings-registry.ts +17 -9
  458. package/src/spine/settings-tabs.ts +4 -3
  459. package/src/spine/target-range-reckoning.ts +3 -3
  460. package/src/spine/timeline-store.ts +6 -1
  461. package/src/spine/topic-ownership.ts +2 -2
  462. package/src/spine/uplink-clients.ts +5 -4
  463. package/src/spine/use-body-states.ts +3 -7
  464. package/src/spine/use-command.ts +167 -125
  465. package/src/spine/use-data-sources.ts +2 -5
  466. package/src/spine/use-late-telemetry-subscribe.ts +1 -0
  467. package/src/spine/use-orbit-curve.ts +49 -0
  468. package/src/spine/use-orbit-trajectory.ts +54 -2
  469. package/src/spine/use-selected-vantage.ts +1 -0
  470. package/src/spine/use-system-instant.ts +20 -0
  471. package/src/spine/use-transmissions.ts +1 -0
  472. package/src/spine/view-clock.ts +20 -3
  473. package/src/system-instant.ts +20 -0
  474. package/src/testing/console-logger.ts +3 -3
  475. package/src/testing/fake-wall-clock.ts +4 -2
  476. package/src/testing/install-act-gate-stretch.ts +9 -0
  477. package/src/testing/install-real-test-host.ts +6 -1
  478. package/src/testing/memory-storage.ts +6 -5
  479. package/src/testing/mock-data-source.ts +2 -2
  480. package/src/testing/render.tsx +4 -2
  481. package/src/testing/stub-transport.ts +66 -52
  482. package/src/timeline.ts +14 -6
  483. package/src/topic-fields.ts +1 -0
  484. package/src/topics.ts +59 -26
  485. package/src/unit-system/registry.ts +11 -0
  486. package/src/unit-system/value.ts +3 -0
  487. package/src/units.ts +1 -1
  488. package/src/uplink-externals.ts +9 -4
  489. package/src/uplink-manifest.ts +62 -16
@@ -107,11 +107,6 @@ export const GENERATED_TYPE_UNITS: Readonly<Record<string, UnitsByField>> = {
107
107
  radialOut: "m/s",
108
108
  ut: "ut",
109
109
  },
110
- "AlternatorEntry": {
111
- outputRate: "units/s",
112
- partId: "id",
113
- partName: "text",
114
- },
115
110
  "ArchiveEntry": {
116
111
  biome: "text",
117
112
  body: "text",
@@ -137,12 +132,6 @@ export const GENERATED_TYPE_UNITS: Readonly<Record<string, UnitsByField>> = {
137
132
  pressures: "kPa",
138
133
  seaLevelPressure: "kPa",
139
134
  },
140
- "BatteryEntry": {
141
- current: "units",
142
- max: "units",
143
- partId: "id",
144
- partName: "text",
145
- },
146
135
  "BodyEntry": {
147
136
  description: "text",
148
137
  gravParameter: "m³/s²",
@@ -307,6 +296,10 @@ export const GENERATED_TYPE_UNITS: Readonly<Record<string, UnitsByField>> = {
307
296
  "CommandGateItem": {
308
297
  value: "id",
309
298
  },
299
+ "CommandGroupRequest": {
300
+ groupId: "id",
301
+ type: "id",
302
+ },
310
303
  "CommandRequest": {
311
304
  command: "id",
312
305
  label: "text",
@@ -414,7 +407,9 @@ export const GENERATED_TYPE_UNITS: Readonly<Record<string, UnitsByField>> = {
414
407
  },
415
408
  "CommsContactWindow": {
416
409
  closeUt: "ut",
410
+ fromDish: "id",
417
411
  openUt: "ut",
412
+ toDish: "id",
418
413
  },
419
414
  "CommsContacts": {
420
415
  horizonUt: "ut",
@@ -437,6 +432,7 @@ export const GENERATED_TYPE_UNITS: Readonly<Record<string, UnitsByField>> = {
437
432
  from: "id",
438
433
  fromIsHome: "flag",
439
434
  kind: "enum",
435
+ quantity: "enum",
440
436
  strength: "ratio",
441
437
  to: "id",
442
438
  toIsHome: "flag",
@@ -480,6 +476,13 @@ export const GENERATED_TYPE_UNITS: Readonly<Record<string, UnitsByField>> = {
480
476
  occludingRadiusMeters: "m",
481
477
  radiusMeters: "m",
482
478
  },
479
+ "CommsRetargetWindow": {
480
+ closeUt: "ut",
481
+ dish: "id",
482
+ node: "id",
483
+ openUt: "ut",
484
+ peer: "id",
485
+ },
483
486
  "CommsRoute": {
484
487
  arrivalUt: "ut",
485
488
  from: "id",
@@ -495,6 +498,7 @@ export const GENERATED_TYPE_UNITS: Readonly<Record<string, UnitsByField>> = {
495
498
  "CommsSignal": {
496
499
  modelled: "flag",
497
500
  otherPath: "flag",
501
+ quantity: "enum",
498
502
  strength: "ratio",
499
503
  },
500
504
  "ContractActionArgs": {
@@ -537,6 +541,9 @@ export const GENERATED_TYPE_UNITS: Readonly<Record<string, UnitsByField>> = {
537
541
  partName: "text",
538
542
  partTitle: "text",
539
543
  },
544
+ "CrashRecent": {
545
+ recent: "flag",
546
+ },
540
547
  "CrashReport": {
541
548
  altitude: "m",
542
549
  body: "text",
@@ -730,12 +737,6 @@ export const GENERATED_TYPE_UNITS: Readonly<Record<string, UnitsByField>> = {
730
737
  vesselId: "id",
731
738
  vesselName: "text",
732
739
  },
733
- "FuelCellEntry": {
734
- active: "flag",
735
- partId: "id",
736
- partName: "text",
737
- status: "text",
738
- },
739
740
  "GameDlc": {
740
741
  breakingGround: "flag",
741
742
  makingHistory: "flag",
@@ -1041,6 +1042,9 @@ export const GENERATED_TYPE_UNITS: Readonly<Record<string, UnitsByField>> = {
1041
1042
  resourcesValue: "funds",
1042
1043
  totalValue: "funds",
1043
1044
  },
1045
+ "RecoveryRecent": {
1046
+ recent: "flag",
1047
+ },
1044
1048
  "RecoveryReport": {
1045
1049
  capturedAtUT: "ut",
1046
1050
  displayReputation: "flag",
@@ -1095,9 +1099,17 @@ export const GENERATED_TYPE_UNITS: Readonly<Record<string, UnitsByField>> = {
1095
1099
  "RotorReverseArgs": {
1096
1100
  partId: "id",
1097
1101
  },
1098
- "RotorSetValueArgs": {
1102
+ "RotorSetBrakeArgs": {
1099
1103
  partId: "id",
1100
- value: "ratio",
1104
+ percent: "%",
1105
+ },
1106
+ "RotorSetRpmLimitArgs": {
1107
+ partId: "id",
1108
+ rpm: "rpm",
1109
+ },
1110
+ "RotorSetTorqueLimitArgs": {
1111
+ partId: "id",
1112
+ percent: "%",
1101
1113
  },
1102
1114
  "SavedShipEntry": {
1103
1115
  facility: "text",
@@ -1199,13 +1211,17 @@ export const GENERATED_TYPE_UNITS: Readonly<Record<string, UnitsByField>> = {
1199
1211
  traverseVelocity: "n/a",
1200
1212
  type: "id",
1201
1213
  },
1214
+ "ServoSetAngleArgs": {
1215
+ degrees: "°",
1216
+ partId: "id",
1217
+ },
1202
1218
  "ServoSetEnabledArgs": {
1203
1219
  enabled: "flag",
1204
1220
  partId: "id",
1205
1221
  },
1206
- "ServoSetTargetArgs": {
1222
+ "ServoSetExtensionArgs": {
1223
+ metres: "m",
1207
1224
  partId: "id",
1208
- value: "ratio",
1209
1225
  },
1210
1226
  "SetActionGroupArgs": {
1211
1227
  group: "id",
@@ -1282,14 +1298,6 @@ export const GENERATED_TYPE_UNITS: Readonly<Record<string, UnitsByField>> = {
1282
1298
  path: "id",
1283
1299
  value: "text",
1284
1300
  },
1285
- "SolarPanelEntry": {
1286
- chargeRate: "units/s",
1287
- deployState: "text",
1288
- flowRate: "units/s",
1289
- partId: "id",
1290
- partName: "text",
1291
- sunAOA: "°",
1292
- },
1293
1301
  "SpaceCenterPartsAvailable": {
1294
1302
  count: "count",
1295
1303
  },
@@ -1437,6 +1445,7 @@ export const GENERATED_TYPE_UNITS: Readonly<Record<string, UnitsByField>> = {
1437
1445
  "VesselComms": {
1438
1446
  connected: "flag",
1439
1447
  controlState: "enum",
1448
+ signalQuantity: "enum",
1440
1449
  signalStrength: "ratio",
1441
1450
  },
1442
1451
  "VesselControl": {
@@ -1490,7 +1499,12 @@ export const GENERATED_TYPE_UNITS: Readonly<Record<string, UnitsByField>> = {
1490
1499
  atmosphericTimeToImpact: "s",
1491
1500
  descentRegime: "text",
1492
1501
  dragToWeightRatio: "1",
1502
+ groundTrackDistances: "m",
1503
+ groundTrackElevations: "m",
1493
1504
  outcome: "text",
1505
+ parachuteDeploySafety: "text",
1506
+ parachuteDeployment: "text",
1507
+ parachuteFullDeployAltitude: "m",
1494
1508
  parachuteState: "text",
1495
1509
  predictedBiome: "text",
1496
1510
  predictedLatitude: "°",
@@ -1502,13 +1516,13 @@ export const GENERATED_TYPE_UNITS: Readonly<Record<string, UnitsByField>> = {
1502
1516
  projectedTouchdownSpeed: "m/s",
1503
1517
  roughnessFootprintMeters: "m",
1504
1518
  sampleSource: "text",
1519
+ siteHeights: "m",
1520
+ siteHeightsExtentMeters: "m",
1521
+ siteHeightsSize: "count",
1505
1522
  slopeAngleUnderVessel: "°",
1506
1523
  slopeSampleRadiusMeters: "m",
1507
1524
  terminalVelocity: "m/s",
1508
1525
  terrainElevationUnderVessel: "m",
1509
- terrainPatch: "m",
1510
- terrainPatchExtentMeters: "m",
1511
- terrainPatchSize: "count",
1512
1526
  },
1513
1527
  "VesselManeuver": {
1514
1528
  planner: "id",
@@ -1739,8 +1753,12 @@ export const GENERATED_TOPIC_UNITS: Readonly<Record<string, UnitsByField>> = {
1739
1753
  "comms.signal": {
1740
1754
  modelled: "flag",
1741
1755
  otherPath: "flag",
1756
+ quantity: "enum",
1742
1757
  strength: "ratio",
1743
1758
  },
1759
+ "crash.hasRecent": {
1760
+ recent: "flag",
1761
+ },
1744
1762
  "crash.lastCrash": {
1745
1763
  altitude: "m",
1746
1764
  body: "text",
@@ -1865,6 +1883,9 @@ export const GENERATED_TOPIC_UNITS: Readonly<Record<string, UnitsByField>> = {
1865
1883
  "parts.power": {
1866
1884
  totalProductionEc: "units/s",
1867
1885
  },
1886
+ "recovery.hasRecent": {
1887
+ recent: "flag",
1888
+ },
1868
1889
  "recovery.lastSummary": {
1869
1890
  capturedAtUT: "ut",
1870
1891
  displayReputation: "flag",
@@ -2075,6 +2096,7 @@ export const GENERATED_TOPIC_UNITS: Readonly<Record<string, UnitsByField>> = {
2075
2096
  "vessel.comms": {
2076
2097
  connected: "flag",
2077
2098
  controlState: "enum",
2099
+ signalQuantity: "enum",
2078
2100
  signalStrength: "ratio",
2079
2101
  },
2080
2102
  "vessel.control": {
@@ -2138,7 +2160,12 @@ export const GENERATED_TOPIC_UNITS: Readonly<Record<string, UnitsByField>> = {
2138
2160
  atmosphericTimeToImpact: "s",
2139
2161
  descentRegime: "text",
2140
2162
  dragToWeightRatio: "1",
2163
+ groundTrackDistances: "m",
2164
+ groundTrackElevations: "m",
2141
2165
  outcome: "text",
2166
+ parachuteDeploySafety: "text",
2167
+ parachuteDeployment: "text",
2168
+ parachuteFullDeployAltitude: "m",
2142
2169
  parachuteState: "text",
2143
2170
  predictedBiome: "text",
2144
2171
  predictedLatitude: "°",
@@ -2150,13 +2177,13 @@ export const GENERATED_TOPIC_UNITS: Readonly<Record<string, UnitsByField>> = {
2150
2177
  projectedTouchdownSpeed: "m/s",
2151
2178
  roughnessFootprintMeters: "m",
2152
2179
  sampleSource: "text",
2180
+ siteHeights: "m",
2181
+ siteHeightsExtentMeters: "m",
2182
+ siteHeightsSize: "count",
2153
2183
  slopeAngleUnderVessel: "°",
2154
2184
  slopeSampleRadiusMeters: "m",
2155
2185
  terminalVelocity: "m/s",
2156
2186
  terrainElevationUnderVessel: "m",
2157
- terrainPatch: "m",
2158
- terrainPatchExtentMeters: "m",
2159
- terrainPatchSize: "count",
2160
2187
  },
2161
2188
  "vessel.maneuver": {
2162
2189
  planner: "id",
@@ -2329,6 +2356,9 @@ export const GENERATED_TYPE_SHAPES: Readonly<Record<string, ShapesByField>> = {
2329
2356
  channels: "ChannelGate[]",
2330
2357
  gates: "CommandGate[]",
2331
2358
  },
2359
+ "CommandGroupRequest": {
2360
+ members: "CommandRequest[]",
2361
+ },
2332
2362
  "CommandResponse": {
2333
2363
  meta: "Meta",
2334
2364
  },
@@ -2360,6 +2390,7 @@ export const GENERATED_TYPE_SHAPES: Readonly<Record<string, ShapesByField>> = {
2360
2390
  author: "CommcastAuthor",
2361
2391
  },
2362
2392
  "CommsContactPair": {
2393
+ retargetWindows: "CommsRetargetWindow[]",
2363
2394
  windows: "CommsContactWindow[]",
2364
2395
  },
2365
2396
  "CommsContacts": {
@@ -2387,6 +2418,7 @@ export const GENERATED_TYPE_SHAPES: Readonly<Record<string, ShapesByField>> = {
2387
2418
  nodes: "CommsNetworkNode[]",
2388
2419
  },
2389
2420
  "CommsNodeView": {
2421
+ handle: "CommsNodeHandle",
2390
2422
  position: "Vector3d",
2391
2423
  },
2392
2424
  "CommsOcclusion": {
@@ -2398,6 +2430,10 @@ export const GENERATED_TYPE_SHAPES: Readonly<Record<string, ShapesByField>> = {
2398
2430
  "CommsRoute": {
2399
2431
  holds: "CommsRouteHold[]",
2400
2432
  },
2433
+ "CommsRouteHop": {
2434
+ fromHandle: "CommsNodeHandle",
2435
+ toHandle: "CommsNodeHandle",
2436
+ },
2401
2437
  "CommsRoutes": {
2402
2438
  routes: "CommsRoute[]",
2403
2439
  },
@@ -2442,6 +2478,9 @@ export const GENERATED_TYPE_SHAPES: Readonly<Record<string, ShapesByField>> = {
2442
2478
  breach: "LimitBreach",
2443
2479
  missing: "MissingUnlock[]",
2444
2480
  },
2481
+ "ICommandGateInputs": {
2482
+ inputs: "GateInput[]",
2483
+ },
2445
2484
  "IControlFrameSource": {
2446
2485
  frame: "ControlFrame",
2447
2486
  },
@@ -2478,12 +2517,6 @@ export const GENERATED_TYPE_SHAPES: Readonly<Record<string, ShapesByField>> = {
2478
2517
  actions: "PartActionEntry[]",
2479
2518
  meta: "PayloadMeta",
2480
2519
  },
2481
- "PartsPower": {
2482
- alternators: "AlternatorEntry[]",
2483
- batteries: "BatteryEntry[]",
2484
- fuelCells: "FuelCellEntry[]",
2485
- solarPanels: "SolarPanelEntry[]",
2486
- },
2487
2520
  "PendingUplinkQueue": {
2488
2521
  pending: "PendingUplink[]",
2489
2522
  },
@@ -2718,12 +2751,6 @@ export const GENERATED_TOPIC_SHAPES: Readonly<Record<string, ShapesByField>> = {
2718
2751
  "missions.active": {
2719
2752
  objectives: "MissionObjectiveEntry[]",
2720
2753
  },
2721
- "parts.power": {
2722
- alternators: "AlternatorEntry[]",
2723
- batteries: "BatteryEntry[]",
2724
- fuelCells: "FuelCellEntry[]",
2725
- solarPanels: "SolarPanelEntry[]",
2726
- },
2727
2754
  "recovery.lastSummary": {
2728
2755
  crewBreakdown: "RecoveryCrewEntry[]",
2729
2756
  partBreakdown: "RecoveryPartEntry[]",
@@ -2867,6 +2894,7 @@ export const GENERATED_TYPE_ENUMS: Readonly<Record<string, EnumsByField>> = {
2867
2894
  },
2868
2895
  "CommsHop": {
2869
2896
  kind: "CommsHopKind",
2897
+ quantity: "SignalQuantity",
2870
2898
  },
2871
2899
  "CommsJourneyEvent": {
2872
2900
  kind: "JourneyEventKind",
@@ -2874,6 +2902,9 @@ export const GENERATED_TYPE_ENUMS: Readonly<Record<string, EnumsByField>> = {
2874
2902
  "CommsNetworkNode": {
2875
2903
  kind: "CommsHopKind",
2876
2904
  },
2905
+ "CommsSignal": {
2906
+ quantity: "SignalQuantity",
2907
+ },
2877
2908
  "ControlFrame": {
2878
2909
  kind: "ControlFrameKind",
2879
2910
  },
@@ -2974,6 +3005,7 @@ export const GENERATED_TYPE_ENUMS: Readonly<Record<string, EnumsByField>> = {
2974
3005
  },
2975
3006
  "VesselComms": {
2976
3007
  controlState: "ControlState",
3008
+ signalQuantity: "SignalQuantity",
2977
3009
  },
2978
3010
  "VesselControl": {
2979
3011
  sasMode: "SasMode",
@@ -3024,6 +3056,9 @@ export const GENERATED_TOPIC_ENUMS: Readonly<Record<string, EnumsByField>> = {
3024
3056
  "comms.delay": {
3025
3057
  source: "CommsDelaySource",
3026
3058
  },
3059
+ "comms.signal": {
3060
+ quantity: "SignalQuantity",
3061
+ },
3027
3062
  "deployed.bases": {
3028
3063
  power: "DeployedPowerState",
3029
3064
  },
@@ -3048,6 +3083,7 @@ export const GENERATED_TOPIC_ENUMS: Readonly<Record<string, EnumsByField>> = {
3048
3083
  },
3049
3084
  "vessel.comms": {
3050
3085
  controlState: "ControlState",
3086
+ signalQuantity: "SignalQuantity",
3051
3087
  },
3052
3088
  "vessel.control": {
3053
3089
  sasMode: "SasMode",
@@ -3326,6 +3362,12 @@ export const GENERATED_ENUM_MEMBERS: Readonly<Record<string, Readonly<Record<num
3326
3362
  3: "Defaults",
3327
3363
  4: "Unreadable",
3328
3364
  },
3365
+ "SignalQuantity": {
3366
+ 0: "Unknown",
3367
+ 1: "RangeFraction",
3368
+ 2: "DataRateHeadroom",
3369
+ 3: "NoModel",
3370
+ },
3329
3371
  "Situation": {
3330
3372
  0: "Landed",
3331
3373
  1: "Splashed",
@@ -130,7 +130,12 @@ export interface UplinkAlarmRequest {
130
130
  *
131
131
  * @example
132
132
  * ```tsx
133
- * const MY_UPLINK = defineUplinkClient({ id: "myuplink", version: "1.0.0", name: "My Uplink" });
133
+ * const MY_UPLINK = defineUplinkClient({
134
+ * id: "myuplink",
135
+ * version: "1.0.0",
136
+ * name: "My Uplink",
137
+ * description: "Reminds the operator when a facility upgrade finishes.",
138
+ * });
134
139
  *
135
140
  * function RemindMe({ facility, finishesAtUt }: { facility: string; finishesAtUt: number }) {
136
141
  * const requestAlarm = useAlarmRequest(MY_UPLINK);
@@ -149,5 +154,6 @@ export interface UplinkAlarmRequest {
149
154
  export function useAlarmRequest(
150
155
  owner: UplinkClientHandle,
151
156
  ): (request: UplinkAlarmRequest) => void {
157
+ // gonogo:reads none
152
158
  return getHost().useAlarmRequest(owner);
153
159
  }
@@ -40,7 +40,7 @@
40
40
  // pressure, ...) whose tone genuinely is a state rather than an identity.
41
41
  // ---------------------------------------------------------------------------
42
42
 
43
- import type { Reading } from "../reading";
43
+ import type { HeldGrade, Reading } from "../reading";
44
44
  import type { ReadFrameChoice } from "../spine/reference-frame";
45
45
  import type { Value } from "../unit-system/value";
46
46
  import type { AlertTone, Tone } from "./tone";
@@ -94,20 +94,34 @@ export interface ShipMapPartMeterEntry {
94
94
  *
95
95
  * @category Widget slots
96
96
  */
97
- export interface ShipMapPartMetaEntry {
97
+ export type ShipMapPartMetaEntry = {
98
98
  /** The part's `flightId`, as a decimal string. */
99
99
  partId: string;
100
100
  /** The row's label, such as `"Water Recycler"`. */
101
101
  label: string;
102
- /** The status colour of a `"ratio"` row's meter. */
103
- tone: Tone;
104
- /** `"ratio"` draws `value` as a meter; `"text"` draws `text` beside the label. */
105
- kind: "ratio" | "text";
106
- /** A fraction from 0 to 1, read when `kind` is `"ratio"`. Absent draws an empty meter. */
107
- value?: number;
108
- /** Free text, read when `kind` is `"text"`. */
109
- text?: string;
110
- }
102
+ /**
103
+ * The reading the row was drawn from, or just its grade. Only a held reading
104
+ * changes anything, so it can be passed unconditionally; while it is held the
105
+ * meter or text is drawn with the held mark.
106
+ */
107
+ held?: HeldGrade | Reading<unknown>;
108
+ } & (
109
+ | {
110
+ /** `"ratio"` draws `value` as a meter; `"text"` draws `text` beside the label. */
111
+ kind: "ratio";
112
+ /** The status colour of the row's meter. */
113
+ tone: Tone;
114
+ /** A fraction from 0 to 1. Absent draws an empty meter. */
115
+ value?: number;
116
+ }
117
+ | {
118
+ kind: "text";
119
+ /** A text row never draws a tone, so it may be left out. */
120
+ tone?: Tone;
121
+ /** Free text, drawn beside the label. */
122
+ text?: string;
123
+ }
124
+ );
111
125
 
112
126
  /**
113
127
  * The bitrate of one hop on the comms route, contributed to
@@ -127,6 +141,12 @@ export interface CommSignalHopRateEntry {
127
141
  toNodeId: string;
128
142
  /** The hop's forward data rate in bits per second. */
129
143
  bitsPerSec: number;
144
+ /**
145
+ * The reading the rate was read from, or just its grade. Only a held reading
146
+ * changes anything, so it can be passed unconditionally; while it is held
147
+ * the rate is drawn with the held mark.
148
+ */
149
+ held?: HeldGrade | Reading<unknown>;
130
150
  }
131
151
 
132
152
  /**
@@ -166,8 +186,13 @@ export type SystemEntityMeta = Readonly<
166
186
  >;
167
187
 
168
188
  /**
169
- * A place on a Keplerian orbit around a named body. `trueAnomaly` picks the
170
- * point on it; a shape that draws the whole orbit ignores it.
189
+ * A place on a Keplerian orbit around a named body. `epoch` and
190
+ * `meanAnomalyAtEpoch` say where on it the entity was at one instant; the
191
+ * widget carries it forward to the instant on screen, so a contribution never
192
+ * advances an orbit and a stale one cannot freeze a marker.
193
+ *
194
+ * A shape that draws only the whole orbit may leave both out, and then marks no
195
+ * place on the ring. A point needs both, and is not drawn without them.
171
196
  *
172
197
  * @category Widget slots
173
198
  */
@@ -185,8 +210,10 @@ export interface SystemEntityOrbitPosition {
185
210
  argPe: number;
186
211
  /** Inclination to the parent's reference plane, in degrees. Required: an equatorial orbit says `0`. */
187
212
  inclination: number;
188
- /** True anomaly, in degrees. */
189
- trueAnomaly: number;
213
+ /** The UT the mean anomaly is for, in seconds. */
214
+ epoch?: number;
215
+ /** Mean anomaly at `epoch`, in radians. */
216
+ meanAnomalyAtEpoch?: number;
190
217
  }
191
218
 
192
219
  /**
@@ -208,14 +235,34 @@ export interface SystemEntityFixedPosition {
208
235
  }
209
236
 
210
237
  /**
211
- * Where a System View entity is: on an orbit, or at a fixed offset from a body.
212
- * An entity whose position holds a non-finite number is not drawn.
238
+ * A place given by the body it is: the widget puts the entity where that body
239
+ * is at the instant on screen, in whatever frame the diagram draws in, and
240
+ * marks it held when the body's place is. The body need not orbit the body the
241
+ * diagram is centred on.
242
+ *
243
+ * @category Widget slots
244
+ */
245
+ export interface SystemEntitySubjectPosition {
246
+ kind: "subject";
247
+ /** What is placed. */
248
+ subject: {
249
+ kind: "body";
250
+ /** The body's index in `system.bodies`. */
251
+ bodyIndex: number;
252
+ };
253
+ }
254
+
255
+ /**
256
+ * Where a System View entity is: on an orbit, at a fixed offset from a body, or
257
+ * where a named body is. An entity whose position holds a non-finite number is
258
+ * not drawn.
213
259
  *
214
260
  * @category Widget slots
215
261
  */
216
262
  export type SystemEntityPosition =
217
263
  | SystemEntityOrbitPosition
218
- | SystemEntityFixedPosition;
264
+ | SystemEntityFixedPosition
265
+ | SystemEntitySubjectPosition;
219
266
 
220
267
  /**
221
268
  * What a System View entity looks like, by `kind`:
@@ -272,6 +319,12 @@ export interface SystemEntity {
272
319
  vesselId?: string;
273
320
  /** Stacking order that overrides the shape's default layer; higher is in front. Ties keep contribution order. */
274
321
  zHint?: number;
322
+ /**
323
+ * How well the entity's place is known, when the contribution knows it is not
324
+ * current: `"held"` draws it dimmed and dashed and says so in its name. Absent
325
+ * is as current as a position the widget computed itself.
326
+ */
327
+ currency?: "held";
275
328
  }
276
329
 
277
330
  /**
@@ -344,6 +397,14 @@ export interface CrewRowToneEntry {
344
397
  crewName: string;
345
398
  /** How alarming the situation is. The widget picks the colour. */
346
399
  tone: AlertTone;
400
+ /**
401
+ * The reading the tone was judged from, or just its grade. Only a held
402
+ * reading changes anything, so it can be passed unconditionally. While it is
403
+ * held the row is tinted by the grade's own severity in place of `tone`, as a
404
+ * held badge is, so a judgement made on data that stopped arriving is never
405
+ * shown as current.
406
+ */
407
+ held?: HeldGrade | Reading<unknown>;
347
408
  }
348
409
 
349
410
  /**
@@ -365,7 +426,13 @@ export interface StrategiesScreenEntry {
365
426
  label: string;
366
427
  /** Sort position, ascending; ties keep contribution order. A screen without one sorts after every screen that has one. */
367
428
  order?: number;
368
- /** The department names whose strategies this screen lists, matched against each strategy's department in `career.status`. None lists nothing, leaving the screen to its augments. */
429
+ /**
430
+ * The department names whose strategies this screen lists, matched exactly
431
+ * against each strategy's department in `career.status`. Stock KSP's
432
+ * departments are `"Finances"`, `"Operations"`, `"Public Relations"` and
433
+ * `"Research & Development"`; a career mod can name others. None lists
434
+ * nothing, leaving the screen to its augments.
435
+ */
369
436
  departments?: readonly string[];
370
437
  /**
371
438
  * `false` for a screen that exists but cannot be used yet. Its tab is still
@@ -378,7 +445,8 @@ export interface StrategiesScreenEntry {
378
445
  /**
379
446
  * True when the screen's `strategies.screen-body` augment draws its own
380
447
  * controls for activating and deactivating its strategies, such as a
381
- * Programs screen offering Accept and Complete. The widget then draws that
448
+ * Programs tab a career mod's Uplink contributes, offering Accept and
449
+ * Complete in place of Activate and Deactivate. The widget then draws that
382
450
  * screen's cards with no Activate or Deactivate button, and with no price or
383
451
  * commitment factor: the augment shows what its own controls cost.
384
452
  */
@@ -514,6 +582,13 @@ export interface SpaceCenterFacilityEntry {
514
582
  currentTierText?: string;
515
583
  /** The same, for the tier an upgrade would buy. */
516
584
  nextTierText?: string;
585
+ /**
586
+ * The reading the tier was read from, or just its grade. Only a held reading
587
+ * changes anything, so a contribution can pass its reading unconditionally.
588
+ * While it is held the widget draws the tier as held, dated by the reading's
589
+ * `asOfUt` where it has one.
590
+ */
591
+ held?: HeldGrade | Reading<unknown>;
517
592
  }
518
593
 
519
594
  // The plot SUBJECTS `packages/components` draws, declared so a contributor
@@ -22,7 +22,7 @@ interface CacheOptions {
22
22
  }
23
23
 
24
24
  /**
25
- * The width, in pixels, of a new coverage mask.
25
+ * The width, in cells, of a new coverage mask: the cells across its 360 degrees of longitude.
26
26
  *
27
27
  * @category Maps and coverage
28
28
  */
@@ -73,7 +73,9 @@ export function onCoverageSourcesChange(cb: () => void): () => void {
73
73
  }
74
74
 
75
75
  /**
76
- * Adds a coverage source, replacing any registered under the same id.
76
+ * Adds a coverage source: a layer of the body map that reveals the cells the
77
+ * source reports as covered, such as the ground a scanner has mapped.
78
+ * Registering a second source with an id already in use replaces the first.
77
79
  *
78
80
  * @category Maps and coverage
79
81
  * @categoryDescription Maps and coverage
@@ -0,0 +1,29 @@
1
+ /**
2
+ * Topic ids the framework subscribes to on a widget's behalf, keyed by the hook
3
+ * or component that does it. A widget that sends a command with `useCommand`,
4
+ * or is mounted by the dashboard, does not declare them: a widget's `channels`
5
+ * leave them out, and its reference page never lists them. Some are registered
6
+ * at runtime rather than listed in the contract, so the ids are plain strings.
7
+ *
8
+ * @category Reading telemetry
9
+ */
10
+ export const FRAMEWORK_READS = {
11
+ /** What `useCommand` reads: the pending and gated commands, and the link and delay they wait on. */
12
+ useCommand: [
13
+ "system.uplink.pending",
14
+ "system.uplink.gates",
15
+ "comms.link",
16
+ "comms.delay",
17
+ ],
18
+ /** What the guard that replaces a locked widget reads: Uplink health, the scene and the career mode. */
19
+ RequiresGuard: [
20
+ "system.uplinkHealth",
21
+ "spaceCenter.scene",
22
+ "spaceCenter.state",
23
+ "career.mode",
24
+ ],
25
+ /** What the control stream reads to know which orbit the craft is on. */
26
+ useControlStream: ["vessel.orbit"],
27
+ /** What a lock scope reads to know which Topics an Uplink has gated. */
28
+ useLockScope: ["system.uplink.gates"],
29
+ } as const satisfies Record<string, readonly string[]>;