@amazon/vinyl-util 1.1.1 → 2.0.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 (431) hide show
  1. package/dist/browserTestUtil/index.js +1853 -1853
  2. package/dist/browserTestUtil/index.js.map +4 -4
  3. package/dist/browserTestUtil/types/current/async/createCallbackTimingTest.d.ts +1 -1
  4. package/dist/browserTestUtil/types/current/async/createCallbackTimingTest.d.ts.map +1 -1
  5. package/dist/browserTestUtil/types/current/expect/typesafety.d.ts +5 -15
  6. package/dist/browserTestUtil/types/current/expect/typesafety.d.ts.map +1 -1
  7. package/dist/browserTestUtil/types/current/index.d.ts +17 -17
  8. package/dist/browserTestUtil/types/current/index.d.ts.map +1 -1
  9. package/dist/browserTestUtil/types/current/index.js +17 -17
  10. package/dist/browserTestUtil/types/current/mock/dom/globals.d.ts +4 -4
  11. package/dist/browserTestUtil/types/current/mock/dom/globals.d.ts.map +1 -1
  12. package/dist/browserTestUtil/types/current/mock/dom/globals.js +1 -1
  13. package/dist/browserTestUtil/types/current/mock/dom/lib.dom.d.ts +499 -499
  14. package/dist/browserTestUtil/types/current/mock/dom/lib.dom.d.ts.map +1 -1
  15. package/dist/browserTestUtil/types/current/mock/dom/lib.dom.js +1 -1
  16. package/dist/browserTestUtil/types/current/mock/implementEventFakes.js +1 -1
  17. package/dist/browserTestUtil/types/current/mock/polyfillCustomEvent.js +1 -1
  18. package/dist/browserTestUtil/types/current/tsconfig.tsbuildinfo +1 -1
  19. package/dist/browserTestUtil/types/ts3.7/async/createCallbackTimingTest.d.ts +1 -1
  20. package/dist/browserTestUtil/types/ts3.7/expect/typesafety.d.ts +5 -15
  21. package/dist/browserTestUtil/types/ts3.7/index.d.ts +17 -17
  22. package/dist/browserTestUtil/types/ts3.7/mock/dom/globals.d.ts +4 -4
  23. package/dist/browserTestUtil/types/ts3.7/mock/dom/lib.dom.d.ts +499 -499
  24. package/dist/browserTestUtil/types/ts4.1/async/createCallbackTimingTest.d.ts +1 -1
  25. package/dist/browserTestUtil/types/ts4.1/expect/typesafety.d.ts +5 -15
  26. package/dist/browserTestUtil/types/ts4.1/index.d.ts +17 -17
  27. package/dist/browserTestUtil/types/ts4.1/mock/dom/globals.d.ts +4 -4
  28. package/dist/browserTestUtil/types/ts4.1/mock/dom/lib.dom.d.ts +499 -499
  29. package/dist/browserTestUtil/types/ts4.7/async/createCallbackTimingTest.d.ts +1 -1
  30. package/dist/browserTestUtil/types/ts4.7/expect/typesafety.d.ts +5 -15
  31. package/dist/browserTestUtil/types/ts4.7/index.d.ts +17 -17
  32. package/dist/browserTestUtil/types/ts4.7/mock/dom/globals.d.ts +4 -4
  33. package/dist/browserTestUtil/types/ts4.7/mock/dom/lib.dom.d.ts +499 -499
  34. package/dist/index.cjs +5054 -5024
  35. package/dist/index.cjs.map +4 -4
  36. package/dist/index.js +5054 -5024
  37. package/dist/index.js.map +4 -4
  38. package/dist/polyfill/index.d.ts +1 -0
  39. package/dist/polyfill/index.d.ts.map +1 -1
  40. package/dist/polyfill/index.js +172 -105
  41. package/dist/polyfill/index.js.map +3 -3
  42. package/dist/polyfill/tsconfig.tsbuildinfo +1 -1
  43. package/dist/test/benchmark.es5.js +70 -70
  44. package/dist/test/benchmark.js +1396 -1395
  45. package/dist/test/benchmark.js.map +4 -4
  46. package/dist/testUtil/index.js +418 -418
  47. package/dist/testUtil/index.js.map +4 -4
  48. package/dist/testUtil/types/current/index.d.ts +16 -16
  49. package/dist/testUtil/types/current/index.d.ts.map +1 -1
  50. package/dist/testUtil/types/current/index.js +16 -16
  51. package/dist/testUtil/types/current/mock/logging/MockLogger.d.ts +1 -1
  52. package/dist/testUtil/types/current/mock/logging/MockLogger.d.ts.map +1 -1
  53. package/dist/testUtil/types/current/mock/logging/MockLogger.js +1 -1
  54. package/dist/testUtil/types/current/mock/navigator/setMockNavigator.js +1 -1
  55. package/dist/testUtil/types/current/mock/network/MockNetworkMetricsController.d.ts +1 -1
  56. package/dist/testUtil/types/current/mock/network/MockNetworkMetricsController.d.ts.map +1 -1
  57. package/dist/testUtil/types/current/mock/network/MockNetworkMetricsController.js +1 -1
  58. package/dist/testUtil/types/current/mock/network/MockNetworkState.d.ts +1 -1
  59. package/dist/testUtil/types/current/mock/network/MockNetworkState.d.ts.map +1 -1
  60. package/dist/testUtil/types/current/mock/network/MockNetworkState.js +1 -1
  61. package/dist/testUtil/types/current/mock/network/MockRequester.d.ts +1 -1
  62. package/dist/testUtil/types/current/mock/network/MockRequester.d.ts.map +1 -1
  63. package/dist/testUtil/types/current/mock/network/MockRequester.js +1 -1
  64. package/dist/testUtil/types/current/reporters/LogReporter.d.ts +1 -0
  65. package/dist/testUtil/types/current/reporters/LogReporter.d.ts.map +1 -1
  66. package/dist/testUtil/types/current/reporters/LogReporter.js +8 -0
  67. package/dist/testUtil/types/current/reporters/RestApiReporter.d.ts +1 -1
  68. package/dist/testUtil/types/current/reporters/RestApiReporter.d.ts.map +1 -1
  69. package/dist/testUtil/types/current/reporters/RestApiReporter.js +1 -1
  70. package/dist/testUtil/types/current/tsconfig.tsbuildinfo +1 -1
  71. package/dist/testUtil/types/current/util/event/createEventSpy.d.ts.map +1 -1
  72. package/dist/testUtil/types/current/util/event/createEventSpy.js +6 -4
  73. package/dist/testUtil/types/ts3.7/index.d.ts +16 -16
  74. package/dist/testUtil/types/ts3.7/mock/logging/MockLogger.d.ts +1 -1
  75. package/dist/testUtil/types/ts3.7/mock/network/MockNetworkMetricsController.d.ts +1 -1
  76. package/dist/testUtil/types/ts3.7/mock/network/MockNetworkState.d.ts +1 -1
  77. package/dist/testUtil/types/ts3.7/mock/network/MockRequester.d.ts +1 -1
  78. package/dist/testUtil/types/ts3.7/reporters/LogReporter.d.ts +1 -0
  79. package/dist/testUtil/types/ts3.7/reporters/RestApiReporter.d.ts +1 -1
  80. package/dist/testUtil/types/ts4.1/index.d.ts +16 -16
  81. package/dist/testUtil/types/ts4.1/mock/logging/MockLogger.d.ts +1 -1
  82. package/dist/testUtil/types/ts4.1/mock/network/MockNetworkMetricsController.d.ts +1 -1
  83. package/dist/testUtil/types/ts4.1/mock/network/MockNetworkState.d.ts +1 -1
  84. package/dist/testUtil/types/ts4.1/mock/network/MockRequester.d.ts +1 -1
  85. package/dist/testUtil/types/ts4.1/reporters/LogReporter.d.ts +1 -0
  86. package/dist/testUtil/types/ts4.1/reporters/RestApiReporter.d.ts +2 -2
  87. package/dist/testUtil/types/ts4.7/index.d.ts +16 -16
  88. package/dist/testUtil/types/ts4.7/mock/logging/MockLogger.d.ts +1 -1
  89. package/dist/testUtil/types/ts4.7/mock/network/MockNetworkMetricsController.d.ts +1 -1
  90. package/dist/testUtil/types/ts4.7/mock/network/MockNetworkState.d.ts +1 -1
  91. package/dist/testUtil/types/ts4.7/mock/network/MockRequester.d.ts +1 -1
  92. package/dist/testUtil/types/ts4.7/reporters/LogReporter.d.ts +1 -0
  93. package/dist/testUtil/types/ts4.7/reporters/RestApiReporter.d.ts +1 -1
  94. package/dist/types/current/client/Version.d.ts.map +1 -1
  95. package/dist/types/current/client/userAgent/UserAgentInfo.d.ts +1 -1
  96. package/dist/types/current/client/userAgent/UserAgentInfo.d.ts.map +1 -1
  97. package/dist/types/current/client/userAgent/hasBrowser.d.ts.map +1 -1
  98. package/dist/types/current/client/userAgent/hasBrowser.js +1 -1
  99. package/dist/types/current/client/userAgent/parseUserAgent.d.ts +1 -1
  100. package/dist/types/current/client/userAgent/parseUserAgent.d.ts.map +1 -1
  101. package/dist/types/current/client/userAgent/tokenizeUserAgent.d.ts +1 -1
  102. package/dist/types/current/client/userAgent/tokenizeUserAgent.d.ts.map +1 -1
  103. package/dist/types/current/client/userAgent/tokenizeUserAgent.js +1 -1
  104. package/dist/types/current/client/userAgent/userAgentRuleHelpers.d.ts.map +1 -1
  105. package/dist/types/current/core/disposable.d.ts +1 -1
  106. package/dist/types/current/core/disposable.d.ts.map +1 -1
  107. package/dist/types/current/error/AbortError.js +1 -1
  108. package/dist/types/current/error/MediaUnsupportedError.d.ts +1 -1
  109. package/dist/types/current/error/MediaUnsupportedError.d.ts.map +1 -1
  110. package/dist/types/current/error/MediaUnsupportedError.js +2 -2
  111. package/dist/types/current/error/ReportableError.d.ts.map +1 -1
  112. package/dist/types/current/error/ServiceResponseError.d.ts.map +1 -1
  113. package/dist/types/current/error/TimeoutError.js +1 -1
  114. package/dist/types/current/error/ValidationError.d.ts +1 -1
  115. package/dist/types/current/error/ValidationError.d.ts.map +1 -1
  116. package/dist/types/current/error/ValidationError.js +2 -2
  117. package/dist/types/current/event/DomEventHost.d.ts +1 -1
  118. package/dist/types/current/event/DomEventHost.d.ts.map +1 -1
  119. package/dist/types/current/event/EventHost.d.ts.map +1 -1
  120. package/dist/types/current/event/Signal.d.ts.map +1 -1
  121. package/dist/types/current/event/nextEventAsPromise.d.ts +14 -4
  122. package/dist/types/current/event/nextEventAsPromise.d.ts.map +1 -1
  123. package/dist/types/current/event/nextEventAsPromise.js +8 -2
  124. package/dist/types/current/event/onAny.d.ts.map +1 -1
  125. package/dist/types/current/event/redispatchEvents.d.ts.map +1 -1
  126. package/dist/types/current/global/globalTarget.d.ts.map +1 -1
  127. package/dist/types/current/index.d.ts +114 -113
  128. package/dist/types/current/index.d.ts.map +1 -1
  129. package/dist/types/current/index.js +114 -113
  130. package/dist/types/current/logging/ConsoleLogHandler.d.ts.map +1 -1
  131. package/dist/types/current/logging/HistoryLogHandler.d.ts.map +1 -1
  132. package/dist/types/current/logging/Logger.d.ts +2 -2
  133. package/dist/types/current/logging/Logger.d.ts.map +1 -1
  134. package/dist/types/current/logging/Logger.js +1 -1
  135. package/dist/types/current/logging/VinylLogging.d.ts +2 -2
  136. package/dist/types/current/logging/VinylLogging.d.ts.map +1 -1
  137. package/dist/types/current/logging/getLogLevelFromSearch.d.ts +1 -1
  138. package/dist/types/current/logging/getLogLevelFromSearch.d.ts.map +1 -1
  139. package/dist/types/current/logging/getLogLevelFromSearch.js +2 -2
  140. package/dist/types/current/logging/logTimer.d.ts +1 -1
  141. package/dist/types/current/logging/logTimer.d.ts.map +1 -1
  142. package/dist/types/current/logging/logTimer.js +1 -1
  143. package/dist/types/current/network/RequestError.d.ts.map +1 -1
  144. package/dist/types/current/network/Requester.d.ts.map +1 -1
  145. package/dist/types/current/network/RequesterImpl.d.ts +1 -1
  146. package/dist/types/current/network/RequesterImpl.d.ts.map +1 -1
  147. package/dist/types/current/network/RequesterImplEventMap.d.ts +1 -1
  148. package/dist/types/current/network/RequesterImplEventMap.d.ts.map +1 -1
  149. package/dist/types/current/network/createRequester.d.ts.map +1 -1
  150. package/dist/types/current/network/logging/networkLoggingHandler.d.ts +1 -1
  151. package/dist/types/current/network/logging/networkLoggingHandler.d.ts.map +1 -1
  152. package/dist/types/current/network/metrics/NetworkMetricsController.d.ts.map +1 -1
  153. package/dist/types/current/network/metrics/NetworkMetricsControllerImpl.d.ts +1 -1
  154. package/dist/types/current/network/metrics/NetworkMetricsControllerImpl.d.ts.map +1 -1
  155. package/dist/types/current/network/metrics/networkMetricsGlobal.d.ts +1 -1
  156. package/dist/types/current/network/metrics/networkMetricsGlobal.d.ts.map +1 -1
  157. package/dist/types/current/network/metrics/networkMetricsGlobal.js +1 -1
  158. package/dist/types/current/network/metrics/networkMetricsModel.d.ts.map +1 -1
  159. package/dist/types/current/network/network.d.ts +1 -1
  160. package/dist/types/current/network/network.d.ts.map +1 -1
  161. package/dist/types/current/network/requesterGlobal.d.ts +1 -1
  162. package/dist/types/current/network/requesterGlobal.d.ts.map +1 -1
  163. package/dist/types/current/network/requesterUtil.d.ts.map +1 -1
  164. package/dist/types/current/patch/network/fetch.d.ts.map +1 -1
  165. package/dist/types/current/patch/patchTarget.d.ts.map +1 -1
  166. package/dist/types/current/persistence/PersistentItem.d.ts +1 -1
  167. package/dist/types/current/persistence/PersistentItem.d.ts.map +1 -1
  168. package/dist/types/current/persistence/PersistentItem.js +1 -1
  169. package/dist/types/current/persistence/StoragePersistence.d.ts +1 -1
  170. package/dist/types/current/persistence/StoragePersistence.d.ts.map +1 -1
  171. package/dist/types/current/persistence/persistenceRef.d.ts +2 -2
  172. package/dist/types/current/persistence/persistenceRef.d.ts.map +1 -1
  173. package/dist/types/current/persistence/persistenceRef.js +1 -1
  174. package/dist/types/current/tsconfig.tsbuildinfo +1 -1
  175. package/dist/types/current/util/async/Abort.d.ts.map +1 -1
  176. package/dist/types/current/util/async/Abort.js +1 -1
  177. package/dist/types/current/util/async/TaskQueue.d.ts +2 -2
  178. package/dist/types/current/util/async/TaskQueue.d.ts.map +1 -1
  179. package/dist/types/current/util/async/TaskQueue.js +1 -1
  180. package/dist/types/current/util/async/TimeoutController.d.ts +1 -1
  181. package/dist/types/current/util/async/TimeoutController.d.ts.map +1 -1
  182. package/dist/types/current/util/async/TimeoutController.js +1 -1
  183. package/dist/types/current/util/async/TimeoutSlot.d.ts.map +1 -1
  184. package/dist/types/current/util/async/abortUtils.d.ts +1 -1
  185. package/dist/types/current/util/async/abortUtils.d.ts.map +1 -1
  186. package/dist/types/current/util/async/poll.d.ts +34 -0
  187. package/dist/types/current/util/async/poll.d.ts.map +1 -0
  188. package/dist/types/current/util/async/poll.js +31 -0
  189. package/dist/types/current/util/async/promise.d.ts +1 -1
  190. package/dist/types/current/util/async/promise.d.ts.map +1 -1
  191. package/dist/types/current/util/async/promise.js +2 -2
  192. package/dist/types/current/util/async/sleep.d.ts +2 -1
  193. package/dist/types/current/util/async/sleep.d.ts.map +1 -1
  194. package/dist/types/current/util/async/timeout.d.ts +32 -10
  195. package/dist/types/current/util/async/timeout.d.ts.map +1 -1
  196. package/dist/types/current/util/async/timeout.js +8 -12
  197. package/dist/types/current/util/browser/searchParams.d.ts +1 -1
  198. package/dist/types/current/util/browser/searchParams.d.ts.map +1 -1
  199. package/dist/types/current/util/browser/searchParams.js +1 -1
  200. package/dist/types/current/util/buffer/BufferError.d.ts.map +1 -1
  201. package/dist/types/current/util/buffer/BufferReader.js +2 -2
  202. package/dist/types/current/util/buffer/buffer.d.ts +1 -1
  203. package/dist/types/current/util/buffer/buffer.d.ts.map +1 -1
  204. package/dist/types/current/util/collection/CacheMap.d.ts +12 -2
  205. package/dist/types/current/util/collection/CacheMap.d.ts.map +1 -1
  206. package/dist/types/current/util/collection/LinkedList.d.ts +1 -4
  207. package/dist/types/current/util/collection/LinkedList.d.ts.map +1 -1
  208. package/dist/types/current/util/collection/LruCache.js +1 -1
  209. package/dist/types/current/util/collection/array.d.ts +2 -2
  210. package/dist/types/current/util/collection/array.d.ts.map +1 -1
  211. package/dist/types/current/util/collection/array.js +2 -2
  212. package/dist/types/current/util/comparison/compare.d.ts +1 -1
  213. package/dist/types/current/util/comparison/compare.d.ts.map +1 -1
  214. package/dist/types/current/util/config/ValueProvider.d.ts +1 -1
  215. package/dist/types/current/util/config/ValueProvider.d.ts.map +1 -1
  216. package/dist/types/current/util/date/date.d.ts +1 -1
  217. package/dist/types/current/util/date/date.d.ts.map +1 -1
  218. package/dist/types/current/util/date/date.js +1 -1
  219. package/dist/types/current/util/error/stack.d.ts +3 -3
  220. package/dist/types/current/util/error/stack.d.ts.map +1 -1
  221. package/dist/types/current/util/error/stack.js +2 -2
  222. package/dist/types/current/util/fun/debounce.d.ts.map +1 -1
  223. package/dist/types/current/util/fun/debounce.js +1 -1
  224. package/dist/types/current/util/fun/memoize.d.ts +1 -1
  225. package/dist/types/current/util/fun/memoize.d.ts.map +1 -1
  226. package/dist/types/current/util/fun/memoize.js +2 -2
  227. package/dist/types/current/util/fun/throttle.d.ts.map +1 -1
  228. package/dist/types/current/util/fun/throttle.js +1 -1
  229. package/dist/types/current/util/map/map.d.ts +10 -2
  230. package/dist/types/current/util/map/map.d.ts.map +1 -1
  231. package/dist/types/current/util/mpeg/parseSidxBox.js +1 -1
  232. package/dist/types/current/util/network/request.d.ts +1 -1
  233. package/dist/types/current/util/network/request.d.ts.map +1 -1
  234. package/dist/types/current/util/object/equalDeep.d.ts +1 -1
  235. package/dist/types/current/util/object/equalDeep.d.ts.map +1 -1
  236. package/dist/types/current/util/object/equalDeep.js +1 -1
  237. package/dist/types/current/util/object/lazy.d.ts.map +1 -1
  238. package/dist/types/current/util/object/mergeDeep.d.ts +1 -1
  239. package/dist/types/current/util/object/mergeDeep.d.ts.map +1 -1
  240. package/dist/types/current/util/object/mergeDeep.js +3 -3
  241. package/dist/types/current/util/object/mutableType.d.ts +1 -1
  242. package/dist/types/current/util/object/mutableType.d.ts.map +1 -1
  243. package/dist/types/current/util/object/readonlyType.d.ts +1 -1
  244. package/dist/types/current/util/object/readonlyType.d.ts.map +1 -1
  245. package/dist/types/current/util/range/IntersectionRanges.d.ts +1 -1
  246. package/dist/types/current/util/range/IntersectionRanges.d.ts.map +1 -1
  247. package/dist/types/current/util/range/Ranges.js +1 -1
  248. package/dist/types/current/util/range/UnionRanges.d.ts +1 -1
  249. package/dist/types/current/util/range/UnionRanges.d.ts.map +1 -1
  250. package/dist/types/current/util/serialization/ParseError.js +1 -1
  251. package/dist/types/current/util/serialization/json.d.ts +1 -1
  252. package/dist/types/current/util/serialization/json.d.ts.map +1 -1
  253. package/dist/types/current/util/serialization/json.js +1 -1
  254. package/dist/types/current/util/serialization/primitives.d.ts +1 -1
  255. package/dist/types/current/util/serialization/primitives.d.ts.map +1 -1
  256. package/dist/types/current/util/serialization/stringifyForPrint.js +1 -1
  257. package/dist/types/current/util/string/StringReader.d.ts +2 -2
  258. package/dist/types/current/util/string/StringReader.d.ts.map +1 -1
  259. package/dist/types/current/util/string/StringReader.js +1 -1
  260. package/dist/types/current/util/string/string.d.ts +2 -2
  261. package/dist/types/current/util/string/string.d.ts.map +1 -1
  262. package/dist/types/current/util/string/string.js +1 -1
  263. package/dist/types/current/util/type.d.ts +13 -0
  264. package/dist/types/current/util/type.d.ts.map +1 -1
  265. package/dist/types/current/util/url/resolveUrl.d.ts +2 -1
  266. package/dist/types/current/util/url/resolveUrl.d.ts.map +1 -1
  267. package/dist/types/current/util/url/resolveUrl.js +9 -3
  268. package/dist/types/ts3.7/client/userAgent/UserAgentInfo.d.ts +1 -1
  269. package/dist/types/ts3.7/client/userAgent/parseUserAgent.d.ts +1 -1
  270. package/dist/types/ts3.7/client/userAgent/tokenizeUserAgent.d.ts +1 -1
  271. package/dist/types/ts3.7/core/disposable.d.ts +1 -1
  272. package/dist/types/ts3.7/error/MediaUnsupportedError.d.ts +1 -1
  273. package/dist/types/ts3.7/error/ValidationError.d.ts +1 -1
  274. package/dist/types/ts3.7/event/DomEventHost.d.ts +1 -1
  275. package/dist/types/ts3.7/event/nextEventAsPromise.d.ts +14 -4
  276. package/dist/types/ts3.7/index.d.ts +114 -113
  277. package/dist/types/ts3.7/logging/Logger.d.ts +2 -2
  278. package/dist/types/ts3.7/logging/VinylLogging.d.ts +2 -2
  279. package/dist/types/ts3.7/logging/getLogLevelFromSearch.d.ts +1 -1
  280. package/dist/types/ts3.7/logging/logTimer.d.ts +1 -1
  281. package/dist/types/ts3.7/network/RequesterImpl.d.ts +1 -1
  282. package/dist/types/ts3.7/network/RequesterImplEventMap.d.ts +1 -1
  283. package/dist/types/ts3.7/network/logging/networkLoggingHandler.d.ts +1 -1
  284. package/dist/types/ts3.7/network/metrics/NetworkMetricsControllerImpl.d.ts +1 -1
  285. package/dist/types/ts3.7/network/metrics/networkMetricsGlobal.d.ts +1 -1
  286. package/dist/types/ts3.7/network/network.d.ts +1 -1
  287. package/dist/types/ts3.7/network/requesterGlobal.d.ts +1 -1
  288. package/dist/types/ts3.7/persistence/PersistentItem.d.ts +1 -1
  289. package/dist/types/ts3.7/persistence/StoragePersistence.d.ts +1 -1
  290. package/dist/types/ts3.7/persistence/persistenceRef.d.ts +2 -2
  291. package/dist/types/ts3.7/util/async/TaskQueue.d.ts +2 -2
  292. package/dist/types/ts3.7/util/async/TimeoutController.d.ts +1 -1
  293. package/dist/types/ts3.7/util/async/abortUtils.d.ts +1 -1
  294. package/dist/types/ts3.7/util/async/poll.d.ts +34 -0
  295. package/dist/types/ts3.7/util/async/promise.d.ts +1 -1
  296. package/dist/types/ts3.7/util/async/sleep.d.ts +2 -1
  297. package/dist/types/ts3.7/util/async/timeout.d.ts +32 -10
  298. package/dist/types/ts3.7/util/browser/searchParams.d.ts +1 -1
  299. package/dist/types/ts3.7/util/buffer/buffer.d.ts +1 -1
  300. package/dist/types/ts3.7/util/collection/CacheMap.d.ts +12 -2
  301. package/dist/types/ts3.7/util/collection/LinkedList.d.ts +1 -4
  302. package/dist/types/ts3.7/util/collection/array.d.ts +2 -2
  303. package/dist/types/ts3.7/util/comparison/compare.d.ts +1 -1
  304. package/dist/types/ts3.7/util/config/ValueProvider.d.ts +1 -1
  305. package/dist/types/ts3.7/util/date/date.d.ts +1 -1
  306. package/dist/types/ts3.7/util/error/stack.d.ts +3 -3
  307. package/dist/types/ts3.7/util/fun/memoize.d.ts +1 -1
  308. package/dist/types/ts3.7/util/map/map.d.ts +13 -2
  309. package/dist/types/ts3.7/util/network/request.d.ts +1 -1
  310. package/dist/types/ts3.7/util/object/equalDeep.d.ts +1 -1
  311. package/dist/types/ts3.7/util/object/mergeDeep.d.ts +1 -1
  312. package/dist/types/ts3.7/util/object/mutableType.d.ts +1 -1
  313. package/dist/types/ts3.7/util/object/readonlyType.d.ts +1 -1
  314. package/dist/types/ts3.7/util/range/IntersectionRanges.d.ts +1 -1
  315. package/dist/types/ts3.7/util/range/UnionRanges.d.ts +1 -1
  316. package/dist/types/ts3.7/util/serialization/json.d.ts +1 -1
  317. package/dist/types/ts3.7/util/serialization/primitives.d.ts +1 -1
  318. package/dist/types/ts3.7/util/string/StringReader.d.ts +2 -2
  319. package/dist/types/ts3.7/util/string/string.d.ts +2 -2
  320. package/dist/types/ts3.7/util/type.d.ts +21 -0
  321. package/dist/types/ts3.7/util/url/resolveUrl.d.ts +2 -1
  322. package/dist/types/ts4.1/client/userAgent/UserAgentInfo.d.ts +1 -1
  323. package/dist/types/ts4.1/client/userAgent/parseUserAgent.d.ts +1 -1
  324. package/dist/types/ts4.1/client/userAgent/tokenizeUserAgent.d.ts +1 -1
  325. package/dist/types/ts4.1/core/disposable.d.ts +1 -1
  326. package/dist/types/ts4.1/error/MediaUnsupportedError.d.ts +1 -1
  327. package/dist/types/ts4.1/error/ValidationError.d.ts +1 -1
  328. package/dist/types/ts4.1/event/DomEventHost.d.ts +1 -1
  329. package/dist/types/ts4.1/event/nextEventAsPromise.d.ts +14 -4
  330. package/dist/types/ts4.1/index.d.ts +114 -113
  331. package/dist/types/ts4.1/logging/Logger.d.ts +2 -2
  332. package/dist/types/ts4.1/logging/VinylLogging.d.ts +2 -2
  333. package/dist/types/ts4.1/logging/getLogLevelFromSearch.d.ts +1 -1
  334. package/dist/types/ts4.1/logging/logTimer.d.ts +1 -1
  335. package/dist/types/ts4.1/network/RequesterImpl.d.ts +1 -1
  336. package/dist/types/ts4.1/network/RequesterImplEventMap.d.ts +1 -1
  337. package/dist/types/ts4.1/network/logging/networkLoggingHandler.d.ts +1 -1
  338. package/dist/types/ts4.1/network/metrics/NetworkMetricsControllerImpl.d.ts +1 -1
  339. package/dist/types/ts4.1/network/metrics/networkMetricsGlobal.d.ts +1 -1
  340. package/dist/types/ts4.1/network/network.d.ts +1 -1
  341. package/dist/types/ts4.1/network/requesterGlobal.d.ts +1 -1
  342. package/dist/types/ts4.1/persistence/PersistentItem.d.ts +1 -1
  343. package/dist/types/ts4.1/persistence/StoragePersistence.d.ts +1 -1
  344. package/dist/types/ts4.1/persistence/persistenceRef.d.ts +2 -2
  345. package/dist/types/ts4.1/util/async/TaskQueue.d.ts +2 -2
  346. package/dist/types/ts4.1/util/async/TimeoutController.d.ts +1 -1
  347. package/dist/types/ts4.1/util/async/abortUtils.d.ts +1 -1
  348. package/dist/types/ts4.1/util/async/poll.d.ts +34 -0
  349. package/dist/types/ts4.1/util/async/promise.d.ts +1 -1
  350. package/dist/types/ts4.1/util/async/sleep.d.ts +2 -1
  351. package/dist/types/ts4.1/util/async/timeout.d.ts +32 -10
  352. package/dist/types/ts4.1/util/browser/searchParams.d.ts +1 -1
  353. package/dist/types/ts4.1/util/buffer/buffer.d.ts +1 -1
  354. package/dist/types/ts4.1/util/collection/CacheMap.d.ts +12 -2
  355. package/dist/types/ts4.1/util/collection/LinkedList.d.ts +1 -4
  356. package/dist/types/ts4.1/util/collection/array.d.ts +2 -2
  357. package/dist/types/ts4.1/util/comparison/compare.d.ts +1 -1
  358. package/dist/types/ts4.1/util/config/ValueProvider.d.ts +1 -1
  359. package/dist/types/ts4.1/util/date/date.d.ts +1 -1
  360. package/dist/types/ts4.1/util/error/stack.d.ts +3 -3
  361. package/dist/types/ts4.1/util/fun/memoize.d.ts +1 -1
  362. package/dist/types/ts4.1/util/map/map.d.ts +13 -2
  363. package/dist/types/ts4.1/util/network/request.d.ts +1 -1
  364. package/dist/types/ts4.1/util/object/equalDeep.d.ts +1 -1
  365. package/dist/types/ts4.1/util/object/mergeDeep.d.ts +1 -1
  366. package/dist/types/ts4.1/util/object/mutableType.d.ts +1 -1
  367. package/dist/types/ts4.1/util/object/readonlyType.d.ts +1 -1
  368. package/dist/types/ts4.1/util/range/IntersectionRanges.d.ts +1 -1
  369. package/dist/types/ts4.1/util/range/UnionRanges.d.ts +1 -1
  370. package/dist/types/ts4.1/util/serialization/json.d.ts +1 -1
  371. package/dist/types/ts4.1/util/serialization/primitives.d.ts +1 -1
  372. package/dist/types/ts4.1/util/string/StringReader.d.ts +2 -2
  373. package/dist/types/ts4.1/util/string/string.d.ts +2 -2
  374. package/dist/types/ts4.1/util/type.d.ts +21 -0
  375. package/dist/types/ts4.1/util/url/resolveUrl.d.ts +2 -1
  376. package/dist/types/ts4.7/client/userAgent/UserAgentInfo.d.ts +1 -1
  377. package/dist/types/ts4.7/client/userAgent/parseUserAgent.d.ts +1 -1
  378. package/dist/types/ts4.7/client/userAgent/tokenizeUserAgent.d.ts +1 -1
  379. package/dist/types/ts4.7/core/disposable.d.ts +1 -1
  380. package/dist/types/ts4.7/error/MediaUnsupportedError.d.ts +1 -1
  381. package/dist/types/ts4.7/error/ValidationError.d.ts +1 -1
  382. package/dist/types/ts4.7/event/DomEventHost.d.ts +1 -1
  383. package/dist/types/ts4.7/event/nextEventAsPromise.d.ts +14 -4
  384. package/dist/types/ts4.7/index.d.ts +114 -113
  385. package/dist/types/ts4.7/logging/Logger.d.ts +2 -2
  386. package/dist/types/ts4.7/logging/VinylLogging.d.ts +2 -2
  387. package/dist/types/ts4.7/logging/getLogLevelFromSearch.d.ts +1 -1
  388. package/dist/types/ts4.7/logging/logTimer.d.ts +1 -1
  389. package/dist/types/ts4.7/network/RequesterImpl.d.ts +1 -1
  390. package/dist/types/ts4.7/network/RequesterImplEventMap.d.ts +1 -1
  391. package/dist/types/ts4.7/network/logging/networkLoggingHandler.d.ts +1 -1
  392. package/dist/types/ts4.7/network/metrics/NetworkMetricsControllerImpl.d.ts +1 -1
  393. package/dist/types/ts4.7/network/metrics/networkMetricsGlobal.d.ts +1 -1
  394. package/dist/types/ts4.7/network/network.d.ts +1 -1
  395. package/dist/types/ts4.7/network/requesterGlobal.d.ts +1 -1
  396. package/dist/types/ts4.7/persistence/PersistentItem.d.ts +1 -1
  397. package/dist/types/ts4.7/persistence/StoragePersistence.d.ts +1 -1
  398. package/dist/types/ts4.7/persistence/persistenceRef.d.ts +2 -2
  399. package/dist/types/ts4.7/util/async/TaskQueue.d.ts +2 -2
  400. package/dist/types/ts4.7/util/async/TimeoutController.d.ts +1 -1
  401. package/dist/types/ts4.7/util/async/abortUtils.d.ts +1 -1
  402. package/dist/types/ts4.7/util/async/poll.d.ts +34 -0
  403. package/dist/types/ts4.7/util/async/promise.d.ts +1 -1
  404. package/dist/types/ts4.7/util/async/sleep.d.ts +2 -1
  405. package/dist/types/ts4.7/util/async/timeout.d.ts +32 -10
  406. package/dist/types/ts4.7/util/browser/searchParams.d.ts +1 -1
  407. package/dist/types/ts4.7/util/buffer/buffer.d.ts +1 -1
  408. package/dist/types/ts4.7/util/collection/CacheMap.d.ts +12 -2
  409. package/dist/types/ts4.7/util/collection/LinkedList.d.ts +1 -4
  410. package/dist/types/ts4.7/util/collection/array.d.ts +2 -2
  411. package/dist/types/ts4.7/util/comparison/compare.d.ts +1 -1
  412. package/dist/types/ts4.7/util/config/ValueProvider.d.ts +1 -1
  413. package/dist/types/ts4.7/util/date/date.d.ts +1 -1
  414. package/dist/types/ts4.7/util/error/stack.d.ts +3 -3
  415. package/dist/types/ts4.7/util/fun/memoize.d.ts +1 -1
  416. package/dist/types/ts4.7/util/map/map.d.ts +13 -2
  417. package/dist/types/ts4.7/util/network/request.d.ts +1 -1
  418. package/dist/types/ts4.7/util/object/equalDeep.d.ts +1 -1
  419. package/dist/types/ts4.7/util/object/mergeDeep.d.ts +1 -1
  420. package/dist/types/ts4.7/util/object/mutableType.d.ts +1 -1
  421. package/dist/types/ts4.7/util/object/readonlyType.d.ts +1 -1
  422. package/dist/types/ts4.7/util/range/IntersectionRanges.d.ts +1 -1
  423. package/dist/types/ts4.7/util/range/UnionRanges.d.ts +1 -1
  424. package/dist/types/ts4.7/util/serialization/json.d.ts +1 -1
  425. package/dist/types/ts4.7/util/serialization/primitives.d.ts +1 -1
  426. package/dist/types/ts4.7/util/string/StringReader.d.ts +2 -2
  427. package/dist/types/ts4.7/util/string/string.d.ts +2 -2
  428. package/dist/types/ts4.7/util/type.d.ts +21 -0
  429. package/dist/types/ts4.7/util/url/resolveUrl.d.ts +2 -1
  430. package/dist/unit/types/current/tsconfig.tsbuildinfo +1 -0
  431. package/package.json +17 -17
@@ -1,7 +1,7 @@
1
- import type { KeyValuePersistence } from '../persistence/KeyValuePersistence';
1
+ import type { KeyValuePersistence } from './KeyValuePersistence';
2
2
  /**
3
3
  * The default storage persistence for simple key / value pairs.
4
4
  * This may be overridden, and by default resolves to local storage persistence.
5
5
  */
6
- export declare const persistenceRef: import("../global/globalRegistry").GlobalRef<KeyValuePersistence<string>>;
6
+ export declare const persistenceRef: import("..").GlobalRef<KeyValuePersistence<string>>;
7
7
  //# sourceMappingURL=persistenceRef.d.ts.map
@@ -1,6 +1,6 @@
1
1
  import type { ReadonlyAbort } from './Abort';
2
- import type { Comparator } from '../../util/comparison/compare';
3
- import type { Maybe, MaybePromise } from '../../util/type';
2
+ import type { Comparator } from '../comparison/compare';
3
+ import type { Maybe, MaybePromise } from '../type';
4
4
  export type Task<T = void> = (abort: ReadonlyAbort) => MaybePromise<T>;
5
5
  /**
6
6
  * A TaskQueue runs actions in a sequence, with the ability to abort the queued tasks.
@@ -1,7 +1,7 @@
1
1
  import type { Disposable } from '../../core/disposable';
2
2
  import type { ReadonlyAbort } from './Abort';
3
3
  import { Abort } from './Abort';
4
- import type { Maybe } from '../../util/type';
4
+ import type { Maybe } from '../type';
5
5
  /**
6
6
  * A `TimeoutController` is an {@link ReadonlyAbort} implementation that will abort either after
7
7
  * an elapsed timeout, an explicit abort call, or if the optional external abort signal fires.
@@ -1,5 +1,5 @@
1
1
  import type { ReadonlyAbort } from './Abort';
2
- import type { Maybe } from '../../util/type';
2
+ import type { Maybe } from '../type';
3
3
  /**
4
4
  * Races a promise and an abort signal.
5
5
  * Generally, it is better to write your promises in a way that they reject and cleanup after an
@@ -0,0 +1,34 @@
1
+ import type { ReadonlyAbort } from './Abort';
2
+ import type { Maybe } from '../type';
3
+ export interface PollOptions {
4
+ /**
5
+ * How long to keep polling before giving up, in seconds. If omitted,
6
+ * polling continues indefinitely until the predicate returns `true` (or the
7
+ * signal aborts).
8
+ */
9
+ readonly timeout?: number;
10
+ /**
11
+ * If provided, aborting rejects the returned promise with the signal's
12
+ * abort reason, cancelling the poll.
13
+ */
14
+ readonly abort?: Maybe<ReadonlyAbort>;
15
+ /**
16
+ * How often to re-evaluate the predicate, in seconds. Defaults to `0.05`
17
+ * (50ms).
18
+ */
19
+ readonly pollInterval?: number;
20
+ }
21
+ /**
22
+ * Repeatedly evaluates `predicate` until it returns `true` or the timeout
23
+ * elapses, resolving to the predicate's final value. Useful for waiting on
24
+ * asynchronous state to settle without wiring up an event subscription.
25
+ *
26
+ * @param predicate Evaluated immediately and then every `pollInterval` seconds.
27
+ * Polling stops as soon as it returns `true`.
28
+ * @param options Optional {@link PollOptions}. With no `timeout`, polling
29
+ * continues indefinitely until the predicate is `true` or `abort` fires.
30
+ * @returns `true` if the predicate became true within the timeout, otherwise
31
+ * `false`.
32
+ */
33
+ export declare function poll(predicate: () => boolean, options?: PollOptions): Promise<boolean>;
34
+ //# sourceMappingURL=poll.d.ts.map
@@ -1,6 +1,6 @@
1
1
  import type { Unsubscribe } from '../../core/Unsubscribe';
2
2
  import type { ReadonlyAbort } from './Abort';
3
- import type { Maybe } from '../../util/type';
3
+ import type { Maybe } from '../type';
4
4
  import type { Disposable } from '../../core/disposable';
5
5
  /**
6
6
  * Creates a promise that can be rejected early from an abort signal and can optionally provide
@@ -1,4 +1,5 @@
1
1
  import type { ReadonlyAbort } from './Abort';
2
+ import type { Maybe } from '../type';
2
3
  /**
3
4
  * Returns a promise that resolves after the given amount of time.
4
5
  *
@@ -23,5 +24,5 @@ import type { ReadonlyAbort } from './Abort';
23
24
  * reason when aborted. If the signal is already aborted and time is less than or equal to zero,
24
25
  * the abort signal takes precedence.
25
26
  */
26
- export declare function sleep(time: number, abort?: ReadonlyAbort | null): Promise<void>;
27
+ export declare function sleep(time: number, abort?: Maybe<ReadonlyAbort>): Promise<void>;
27
28
  //# sourceMappingURL=sleep.d.ts.map
@@ -1,6 +1,24 @@
1
1
  import type { ReadonlyAbort } from './Abort';
2
2
  import { ErrorLevel } from '../../error/ReportableError';
3
3
  export declare const DEFAULT_TIMEOUT_MESSAGE = "Timed out after {time}s";
4
+ /**
5
+ * Options for {@link withTimeout}.
6
+ */
7
+ export interface WithTimeoutOptions {
8
+ /**
9
+ * The message to set in the {@link TimeoutError}. Uses `{time}` token.
10
+ * (default: {@link DEFAULT_TIMEOUT_MESSAGE})
11
+ */
12
+ readonly message?: string | undefined;
13
+ /**
14
+ * The error origin. (default: `ErrorOrigin.INTERNAL`)
15
+ */
16
+ readonly origin?: string | undefined;
17
+ /**
18
+ * The error level. (default: `ErrorLevel.FATAL`)
19
+ */
20
+ readonly level?: ErrorLevel | undefined;
21
+ }
4
22
  /**
5
23
  * Races a promise with a timeout, rejecting with a {@link TimeoutError} if the timeout is
6
24
  * reached before the provided promise.
@@ -8,22 +26,26 @@ export declare const DEFAULT_TIMEOUT_MESSAGE = "Timed out after {time}s";
8
26
  * @param promise The promise to race against a timeout.
9
27
  * @param time The number of seconds to wait. If undefined, the promise is returned without
10
28
  * wrapping.
11
- * @param message The message to set in the {@link TimeoutError}. Uses `{time}` token.
12
- * @param origin The error origin. (default: `ErrorOrigin.INTERNAL`)
13
- * @param level The error level (default: `ErrorLevel.FATAL`)
29
+ * @param options Timeout error options (message, origin, level).
30
+ */
31
+ export declare function withTimeout<T>(promise: PromiseLike<T>, time?: number, options?: WithTimeoutOptions): Promise<T>;
32
+ /**
33
+ * Options for {@link timeout}.
14
34
  */
15
- export declare function withTimeout<T>(promise: PromiseLike<T>, time?: number, message?: string, origin?: string, level?: ErrorLevel): Promise<T>;
35
+ export interface TimeoutOptions extends WithTimeoutOptions {
36
+ /**
37
+ * If provided, when aborted (regardless of reason) will resolve the
38
+ * returned promise rather than rejecting.
39
+ */
40
+ readonly abort?: ReadonlyAbort | undefined;
41
+ }
16
42
  /**
17
43
  * Returns a promise that will reject after the provided number of seconds.
18
44
  * If the optional abort signal is aborted, the timer will be canceled and the promise resolved.
19
45
  * This is the inverse of {@link sleep}
20
46
  *
21
47
  * @param time The number of seconds to wait.
22
- * @param abort If provided, when aborted (regardless of reason) will resolve the returned
23
- * promise.
24
- * @param message The message to be used in the TimeoutError in case of timeout. Uses `{time}` token.
25
- * @param origin The error origin. (default: `ErrorOrigin.INTERNAL`)
26
- * @param level The error level (default: `ErrorLevel.FATAL`)
48
+ * @param options Timeout options (abort, message, origin, level).
27
49
  */
28
- export declare function timeout(time: number, abort?: ReadonlyAbort, message?: string, origin?: string, level?: ErrorLevel): Promise<void>;
50
+ export declare function timeout(time: number, options?: TimeoutOptions): Promise<void>;
29
51
  //# sourceMappingURL=timeout.d.ts.map
@@ -4,7 +4,7 @@
4
4
  * @param search (Optional) The window's search substring. Defaults to `location.search`, overridden
5
5
  * only for unit tests.
6
6
  */
7
- export declare const getSearchParams: import("../../util/fun/memoize").MemoizedFunction & ((search?: string) => URLSearchParams);
7
+ export declare const getSearchParams: import("../..").MemoizedFunction & ((search?: string) => URLSearchParams);
8
8
  /**
9
9
  * If the environment has a `location` object, returns the location's search. Otherwise,
10
10
  * an empty string.
@@ -1,4 +1,4 @@
1
- import type { Maybe } from '../../util/type';
1
+ import type { Maybe } from '../type';
2
2
  /**
3
3
  * Converts a byte buffer to an 8-bit width string.
4
4
  *
@@ -1,7 +1,17 @@
1
1
  /**
2
- * A CacheMap is a Map that notifies when an entry is evicted.
2
+ * A map that notifies when an entry is evicted.
3
+ *
4
+ * Mirrors the ES2015 `Map<K, V>` interface (no iteration methods) so implementers
5
+ * are not coupled to the evolving `MapIterator` shape in newer lib types.
3
6
  */
4
- export interface CacheMap<K, V> extends Map<K, V> {
7
+ export interface CacheMap<K, V> {
8
+ readonly size: number;
9
+ has(key: K): boolean;
10
+ get(key: K): V | undefined;
11
+ set(key: K, value: V): this;
12
+ delete(key: K): boolean;
13
+ clear(): void;
14
+ forEach(callbackfn: (value: V, key: K, map: CacheMap<K, V>) => void, thisArg?: any): void;
5
15
  /**
6
16
  * When an entry is added when at capacity, the least recently used entry will be removed.
7
17
  * This callback can be set to be notified with the element and key being evicted, which may be
@@ -148,9 +148,6 @@ export declare class LinkedList<T> implements Iterable<T> {
148
148
  * @param end The ending node (exclusive).
149
149
  * @param next A method that is given the current node, and returns the next node.
150
150
  */
151
- createIterator(start: LinkedNode<T> | null, end: LinkedNode<T> | null, next: (current: LinkedNode<T>) => LinkedNode<T> | null): {
152
- [Symbol.iterator](): IterableIterator<T>;
153
- next: () => IteratorResult<T>;
154
- };
151
+ createIterator(start: LinkedNode<T> | null, end: LinkedNode<T> | null, next: (current: LinkedNode<T>) => LinkedNode<T> | null): IterableIterator<T>;
155
152
  }
156
153
  //# sourceMappingURL=LinkedList.d.ts.map
@@ -1,5 +1,5 @@
1
- import type { Comparator } from '../../util/comparison/compare';
2
- import type { Maybe, MaybePromise, Primitive } from '../../util/type';
1
+ import type { Comparator } from '../comparison/compare';
2
+ import type { Maybe, MaybePromise, Primitive } from '../type';
3
3
  export type FilterPredicateAsync<T> = (value: T, index: number, array: ArrayLike<T>) => Promise<boolean>;
4
4
  export type FilterPredicate<T> = (value: T, index: number, array: ArrayLike<T>) => boolean;
5
5
  /**
@@ -1,4 +1,4 @@
1
- import type { Maybe, Primitive } from '../../util/type';
1
+ import type { Maybe, Primitive } from '../type';
2
2
  /**
3
3
  * A function that can be used as a comparator for sorting.
4
4
  * Return > 0 if `a` is greater than `b`
@@ -1,4 +1,4 @@
1
- import type { MaybePromise } from '../../util/type';
1
+ import type { MaybePromise } from '../type';
2
2
  /**
3
3
  * A value of type T, a function returning T, or an async function returning a Promise<T>.
4
4
  * To be used with `resolveValueProvider`.
@@ -1,4 +1,4 @@
1
- import type { ReadonlyDate } from '../../util/object/readonlyType';
1
+ import type { ReadonlyDate } from '../object/readonlyType';
2
2
  /**
3
3
  * Returns the signed time difference of end - start, in seconds.
4
4
  *
@@ -1,4 +1,4 @@
1
- import type { Maybe } from '../../util/type';
1
+ import type { Maybe } from '../type';
2
2
  /**
3
3
  * A location in code.
4
4
  */
@@ -26,7 +26,7 @@ export interface CodeLocation {
26
26
  *
27
27
  * @private
28
28
  */
29
- export declare const codeLocationComparator: import("../../util/comparison/compare").Comparator<Maybe<CodeLocation>, Maybe<CodeLocation>>;
29
+ export declare const codeLocationComparator: import("../..").Comparator<Maybe<CodeLocation>, Maybe<CodeLocation>>;
30
30
  /**
31
31
  * Boundary code locations, used to determine if an error is within a certain range of code.
32
32
  * The start and end boundaries must be the same path and file to be a valid range.
@@ -75,5 +75,5 @@ export declare const stackNoiseError2: Error;
75
75
  * When corejs polyfills Error with clearErrorStack, the stack may begin with the polyfill
76
76
  * location. Trim the beginning of stacks with the leading lines common to all errors.
77
77
  */
78
- export declare const stackNoise: import("../../util/object/lazy").Lazy<string>;
78
+ export declare const stackNoise: import("../..").Lazy<string>;
79
79
  //# sourceMappingURL=stack.d.ts.map
@@ -1,4 +1,4 @@
1
- import type { Fun } from '../../util/type';
1
+ import type { Fun } from '../type';
2
2
  export interface MemoizedFunction {
3
3
  clear(): void;
4
4
  }
@@ -1,3 +1,11 @@
1
+ /**
2
+ * The minimal `Map`-shaped interface that {@link getOrSet} needs.
3
+ */
4
+ export interface GetOrSetMap<K, V> {
5
+ has(key: K): boolean;
6
+ get(key: K): V | undefined;
7
+ set(key: K, value: V): unknown;
8
+ }
1
9
  /**
2
10
  * Gets the value on map for the given key if it exists, otherwise sets [key] to `defaultValue`,
3
11
  * returning the newly set value.
@@ -6,12 +14,15 @@
6
14
  * @param key
7
15
  * @param defaultValue
8
16
  */
9
- export declare function getOrSet<K, V>(map: Map<K, V>, key: K, defaultValue: (key: K) => V): V;
17
+ export declare function getOrSet<K, V>(map: GetOrSetMap<K, V>, key: K, defaultValue: (key: K) => V): V;
10
18
  /**
11
19
  * Flips a map so that the keys become the values and the values become the keys.
12
20
  *
13
21
  * @param map
14
22
  * @return Returns a new map.
15
23
  */
16
- export declare function flipMap<K, V>(map: ReadonlyMap<K, V>): Map<V, K>;
24
+ export declare function flipMap<K, V>(map: Iterable<readonly [
25
+ K,
26
+ V
27
+ ]>): Map<V, K>;
17
28
  //# sourceMappingURL=map.d.ts.map
@@ -1,4 +1,4 @@
1
- import type { Maybe } from '../../util/type';
1
+ import type { Maybe } from '../type';
2
2
  /**
3
3
  * Given request parameters, returns the header for the given key, or null.
4
4
  */
@@ -1,4 +1,4 @@
1
- import type { TypedArray } from '../../util/collection/typedArray';
1
+ import type { TypedArray } from '../collection/typedArray';
2
2
  /**
3
3
  * Recursively compares the values of all the enumerable own properties from two source objects.
4
4
  *
@@ -1,4 +1,4 @@
1
- import type { TypedArray } from '../../util/collection/typedArray';
1
+ import type { TypedArray } from '../collection/typedArray';
2
2
  import { ReportableError } from '../../error/ReportableError';
3
3
  import type { Cloneable } from '../../core/cloneable';
4
4
  /**
@@ -1,4 +1,4 @@
1
- import type { Fun } from '../../util/type';
1
+ import type { Fun } from '../type';
2
2
  import type { ReadonlyDate, ReadonlyMap, ReadonlySet } from './readonlyType';
3
3
  /**
4
4
  * Recursively removes read only modifiers.
@@ -1,4 +1,4 @@
1
- import type { Fun } from '../../util/type';
1
+ import type { Fun } from '../type';
2
2
  /**
3
3
  * Recursively marks Objects, Arrays, Maps, Sets, or Dates as read only.
4
4
  * Other non-primitive types will retain their method signatures, potentially exposing mutation
@@ -1,6 +1,6 @@
1
1
  import type { Range, ReadonlyRanges } from './Ranges';
2
2
  import { ReadonlyRangesImpl } from './Ranges';
3
- import type { Maybe } from '../../util/type';
3
+ import type { Maybe } from '../type';
4
4
  export interface IntersectionRangesOptions {
5
5
  /**
6
6
  * If true, only recomputes ranges after a call to `invalidate`.
@@ -1,6 +1,6 @@
1
1
  import type { Range, ReadonlyRanges } from './Ranges';
2
2
  import { ReadonlyRangesImpl } from './Ranges';
3
- import type { Maybe } from '../../util/type';
3
+ import type { Maybe } from '../type';
4
4
  export interface UnionRangesOptions {
5
5
  /**
6
6
  * If true, only recomputes ranges after a call to `invalidate`.
@@ -1,4 +1,4 @@
1
- import type { AnyRecord, Fun, IsAny } from '../../util/type';
1
+ import type { AnyRecord, Fun, IsAny } from '../type';
2
2
  /**
3
3
  * A representation of the conversion the toJson function will apply to make an input JSON compatible.
4
4
  */
@@ -1,4 +1,4 @@
1
- import type { Maybe } from '../../util/type';
1
+ import type { Maybe } from '../type';
2
2
  /**
3
3
  * Returns true if the given string is 'true' or '1'
4
4
  *
@@ -1,6 +1,6 @@
1
1
  import { ReportableError } from '../../error/ReportableError';
2
- import type { ParseError } from '../../util/serialization/ParseError';
3
- import type { Json } from '../../util/serialization/json';
2
+ import type { ParseError } from '../serialization/ParseError';
3
+ import type { Json } from '../serialization/json';
4
4
  /**
5
5
  * A cursor on a string that allows for fast, naive parsing.
6
6
  */
@@ -1,5 +1,5 @@
1
- import type { Maybe } from '../../util/type';
2
- import type { ReadonlyRecord } from '../../util/object/readonlyType';
1
+ import type { Maybe } from '../type';
2
+ import type { ReadonlyRecord } from '../object/readonlyType';
3
3
  /**
4
4
  * Substitutes named variable references in a string.
5
5
  *
@@ -170,4 +170,25 @@ export type IsAny<T> = 0 extends 1 & T ? true : false;
170
170
  * @returns `true` if `P` is an optional property, otherwise `false`.
171
171
  */
172
172
  export type IsPropertyOptional<U, P extends keyof U> = AnyRecord extends Pick<U, P> ? true : false;
173
+ /**
174
+ * A type that equals true if Left and Right are loosely equal, that is, that Left extends Right
175
+ * and Right extends Left.
176
+ * This will always equal true or false, and never the union `true | false`
177
+ */
178
+ export type Equal<Left, Right> = [
179
+ Left
180
+ ] extends [
181
+ Right
182
+ ] ? [
183
+ Right
184
+ ] extends [
185
+ Left
186
+ ] ? true : false : false;
187
+ /**
188
+ * A type that equals true if Left and Right are strictly equal.
189
+ * Works with complex objects, readonly, and optional modifiers.
190
+ * Works with method input arguments.
191
+ * This will always equal true or false, and never the union `true | false`
192
+ */
193
+ export type StrictEqual<Left, Right> = (<T>() => T extends Left ? 0 : 1) extends <T>() => T extends Right ? 0 : 1 ? Equal<Left, Right> : false;
173
194
  //# sourceMappingURL=type.d.ts.map
@@ -3,7 +3,8 @@
3
3
  * avoiding the overhead of constructing `URL` objects.
4
4
  *
5
5
  * Handles the same cases as `new URL(relative, base)`:
6
- * - Absolute URIs (with scheme) are returned as-is.
6
+ * - Absolute URIs (with any scheme, including `data:` / `blob:`) are returned
7
+ * as-is.
7
8
  * - Protocol-relative URIs (`//host/path`) inherit the base scheme.
8
9
  * - Absolute paths (`/path`) replace the base path.
9
10
  * - Relative paths are resolved against the base directory.
@@ -1,4 +1,4 @@
1
- import type { Version } from '../../client/Version';
1
+ import type { Version } from '../Version';
2
2
  /**
3
3
  * A parsed user agent.
4
4
  */
@@ -8,7 +8,7 @@ import type { UserAgentInfo } from './UserAgentInfo';
8
8
  * @param rules The user agent rules.
9
9
  */
10
10
  export declare function parseUserAgent(userAgent?: Maybe<string>, rules?: UserAgentRules): UserAgentInfo;
11
- export declare const userAgentInfoRef: import("../../global/globalRegistry").GlobalRef<UserAgentInfo>;
11
+ export declare const userAgentInfoRef: import("../..").GlobalRef<UserAgentInfo>;
12
12
  export declare function getUserAgentInfo(): UserAgentInfo;
13
13
  export declare function setUserAgent(value: string): void;
14
14
  //# sourceMappingURL=parseUserAgent.d.ts.map
@@ -1,5 +1,5 @@
1
1
  import type { Maybe } from '../../util/type';
2
- import type { Version } from '../../client/Version';
2
+ import type { Version } from '../Version';
3
3
  import type { UaDeviceInfo, UaSystemInfo } from './UserAgentInfo';
4
4
  /**
5
5
  * Builds a tokenized user agent for faster queries.
@@ -1,5 +1,5 @@
1
1
  import { IllegalStateError } from '../error/IllegalStateError';
2
- import type { Unsubscribe } from '../core/Unsubscribe';
2
+ import type { Unsubscribe } from './Unsubscribe';
3
3
  import type { Maybe } from '../util/type';
4
4
  /**
5
5
  * Any object that may be disposed.
@@ -1,4 +1,4 @@
1
- import { ReportableError } from '../error/ReportableError';
1
+ import { ReportableError } from './ReportableError';
2
2
  import type { Json } from '../util/serialization/json';
3
3
  export declare class MediaUnsupportedError extends ReportableError {
4
4
  readonly code: string;
@@ -1,4 +1,4 @@
1
- import { ReportableError } from '../error/ReportableError';
1
+ import { ReportableError } from './ReportableError';
2
2
  import type { Json } from '../util/serialization/json';
3
3
  /**
4
4
  * An error indicating that input had an invalid shape.
@@ -40,6 +40,6 @@ export declare class DomEventHost<EventMap> implements DomReadonlyEventHost<Even
40
40
  * Disposal of a DomEventHost removes all listeners.
41
41
  */
42
42
  dispose(): void;
43
- __eventMapType: import("../util/type").Covariant<EventMap>;
43
+ __eventMapType: import("..").Covariant<EventMap>;
44
44
  }
45
45
  //# sourceMappingURL=DomEventHost.d.ts.map
@@ -1,23 +1,33 @@
1
1
  import type { ReadonlyEventHost } from './EventHost';
2
2
  import type { ReadonlyAbort } from '../util/async/Abort';
3
3
  import type { Maybe } from '../util/type';
4
+ import { ErrorLevel } from '../error/ReportableError';
4
5
  export interface NextEventAsPromiseOptions<EventMap, K extends keyof EventMap> {
5
6
  /**
6
7
  * (Optional) If provided, will only resolve if the event passes this predicate.
7
8
  */
8
- filter?: ((event: EventMap[K]) => boolean) | undefined | null;
9
+ readonly filter?: ((event: EventMap[K]) => boolean) | undefined | null;
9
10
  /**
10
11
  * (Optional) If provided, will reject the promise if the signal is aborted.
11
12
  */
12
- abort?: Maybe<ReadonlyAbort>;
13
+ readonly abort?: Maybe<ReadonlyAbort>;
13
14
  /**
14
15
  * If provided, the promise will reject after this duration, in seconds, if not resolved.
15
16
  */
16
- timeout?: number;
17
+ readonly timeout?: number;
17
18
  /**
18
19
  * The timeout message. If not provided will use `DEFAULT_TIMEOUT_MESSAGE`.
19
20
  */
20
- timeoutMessage?: string;
21
+ readonly timeoutMessage?: string;
22
+ /**
23
+ * The error origin if the next event times out.
24
+ * Default: `ErrorOrigin.INTERNAL`
25
+ */
26
+ readonly timeoutOrigin?: string;
27
+ /**
28
+ * The error level on a timeout.
29
+ */
30
+ readonly timeoutLevel?: ErrorLevel;
21
31
  }
22
32
  /**
23
33
  * Promisifies the next event.