@unwanted/matrix-sdk-mini 34.12.0-2 → 34.12.0-4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (492) hide show
  1. package/git-revision.txt +1 -1
  2. package/lib/@types/global.d.js +0 -2
  3. package/lib/@types/global.d.js.map +1 -1
  4. package/lib/browser-index.d.ts.map +1 -1
  5. package/lib/browser-index.js +0 -11
  6. package/lib/browser-index.js.map +1 -1
  7. package/lib/client.d.ts +2 -1221
  8. package/lib/client.d.ts.map +1 -1
  9. package/lib/client.js +331 -2821
  10. package/lib/client.js.map +1 -1
  11. package/lib/embedded.d.ts +0 -22
  12. package/lib/embedded.d.ts.map +1 -1
  13. package/lib/embedded.js +24 -166
  14. package/lib/embedded.js.map +1 -1
  15. package/lib/event-mapper.d.ts.map +1 -1
  16. package/lib/event-mapper.js +0 -4
  17. package/lib/event-mapper.js.map +1 -1
  18. package/lib/matrix.d.ts +0 -19
  19. package/lib/matrix.d.ts.map +1 -1
  20. package/lib/matrix.js +1 -26
  21. package/lib/matrix.js.map +1 -1
  22. package/lib/models/MSC3089Branch.d.ts.map +1 -1
  23. package/lib/models/MSC3089Branch.js +0 -3
  24. package/lib/models/MSC3089Branch.js.map +1 -1
  25. package/lib/models/event.d.ts +0 -94
  26. package/lib/models/event.d.ts.map +1 -1
  27. package/lib/models/event.js +0 -274
  28. package/lib/models/event.js.map +1 -1
  29. package/lib/models/poll.d.ts.map +1 -1
  30. package/lib/models/poll.js +1 -5
  31. package/lib/models/poll.js.map +1 -1
  32. package/lib/models/relations-container.d.ts.map +1 -1
  33. package/lib/models/relations-container.js +1 -7
  34. package/lib/models/relations-container.js.map +1 -1
  35. package/lib/models/relations.d.ts +0 -1
  36. package/lib/models/relations.d.ts.map +1 -1
  37. package/lib/models/relations.js +0 -8
  38. package/lib/models/relations.js.map +1 -1
  39. package/lib/models/room-state.d.ts.map +1 -1
  40. package/lib/models/room-state.js +10 -26
  41. package/lib/models/room-state.js.map +1 -1
  42. package/lib/models/room.d.ts +0 -18
  43. package/lib/models/room.d.ts.map +1 -1
  44. package/lib/models/room.js +94 -148
  45. package/lib/models/room.js.map +1 -1
  46. package/lib/models/thread.d.ts.map +1 -1
  47. package/lib/models/thread.js +0 -1
  48. package/lib/models/thread.js.map +1 -1
  49. package/lib/sliding-sync-sdk.d.ts +2 -3
  50. package/lib/sliding-sync-sdk.d.ts.map +1 -1
  51. package/lib/sliding-sync-sdk.js +41 -90
  52. package/lib/sliding-sync-sdk.js.map +1 -1
  53. package/lib/sync.d.ts +0 -12
  54. package/lib/sync.d.ts.map +1 -1
  55. package/lib/sync.js +1 -73
  56. package/lib/sync.js.map +1 -1
  57. package/lib/testing.d.ts +0 -48
  58. package/lib/testing.d.ts.map +1 -1
  59. package/lib/testing.js +0 -105
  60. package/lib/testing.js.map +1 -1
  61. package/lib/types.d.ts +0 -1
  62. package/lib/types.d.ts.map +1 -1
  63. package/lib/types.js.map +1 -1
  64. package/package.json +1 -3
  65. package/src/@types/global.d.ts +0 -3
  66. package/src/browser-index.ts +0 -11
  67. package/src/client.ts +60 -2882
  68. package/src/embedded.ts +3 -130
  69. package/src/event-mapper.ts +0 -4
  70. package/src/matrix.ts +0 -28
  71. package/src/models/MSC3089Branch.ts +0 -3
  72. package/src/models/event.ts +0 -289
  73. package/src/models/poll.ts +0 -6
  74. package/src/models/relations-container.ts +1 -8
  75. package/src/models/relations.ts +0 -8
  76. package/src/models/room-state.ts +2 -8
  77. package/src/models/room.ts +0 -62
  78. package/src/models/thread.ts +0 -1
  79. package/src/sliding-sync-sdk.ts +2 -72
  80. package/src/sync.ts +1 -98
  81. package/src/testing.ts +0 -108
  82. package/src/types.ts +0 -1
  83. package/CHANGELOG.md +0 -5910
  84. package/lib/@types/AESEncryptedSecretStoragePayload.d.ts +0 -14
  85. package/lib/@types/AESEncryptedSecretStoragePayload.d.ts.map +0 -1
  86. package/lib/@types/AESEncryptedSecretStoragePayload.js +0 -1
  87. package/lib/@types/AESEncryptedSecretStoragePayload.js.map +0 -1
  88. package/lib/@types/crypto.d.ts +0 -47
  89. package/lib/@types/crypto.d.ts.map +0 -1
  90. package/lib/@types/crypto.js +0 -1
  91. package/lib/@types/crypto.js.map +0 -1
  92. package/lib/@types/matrix-sdk-crypto-wasm.d.js +0 -1
  93. package/lib/@types/matrix-sdk-crypto-wasm.d.js.map +0 -1
  94. package/lib/common-crypto/CryptoBackend.d.ts +0 -240
  95. package/lib/common-crypto/CryptoBackend.d.ts.map +0 -1
  96. package/lib/common-crypto/CryptoBackend.js +0 -73
  97. package/lib/common-crypto/CryptoBackend.js.map +0 -1
  98. package/lib/common-crypto/key-passphrase.d.ts +0 -14
  99. package/lib/common-crypto/key-passphrase.d.ts.map +0 -1
  100. package/lib/common-crypto/key-passphrase.js +0 -33
  101. package/lib/common-crypto/key-passphrase.js.map +0 -1
  102. package/lib/crypto/CrossSigning.d.ts +0 -184
  103. package/lib/crypto/CrossSigning.d.ts.map +0 -1
  104. package/lib/crypto/CrossSigning.js +0 -718
  105. package/lib/crypto/CrossSigning.js.map +0 -1
  106. package/lib/crypto/DeviceList.d.ts +0 -216
  107. package/lib/crypto/DeviceList.d.ts.map +0 -1
  108. package/lib/crypto/DeviceList.js +0 -892
  109. package/lib/crypto/DeviceList.js.map +0 -1
  110. package/lib/crypto/EncryptionSetup.d.ts +0 -152
  111. package/lib/crypto/EncryptionSetup.d.ts.map +0 -1
  112. package/lib/crypto/EncryptionSetup.js +0 -356
  113. package/lib/crypto/EncryptionSetup.js.map +0 -1
  114. package/lib/crypto/OlmDevice.d.ts +0 -457
  115. package/lib/crypto/OlmDevice.d.ts.map +0 -1
  116. package/lib/crypto/OlmDevice.js +0 -1241
  117. package/lib/crypto/OlmDevice.js.map +0 -1
  118. package/lib/crypto/OutgoingRoomKeyRequestManager.d.ts +0 -109
  119. package/lib/crypto/OutgoingRoomKeyRequestManager.d.ts.map +0 -1
  120. package/lib/crypto/OutgoingRoomKeyRequestManager.js +0 -415
  121. package/lib/crypto/OutgoingRoomKeyRequestManager.js.map +0 -1
  122. package/lib/crypto/RoomList.d.ts +0 -26
  123. package/lib/crypto/RoomList.d.ts.map +0 -1
  124. package/lib/crypto/RoomList.js +0 -71
  125. package/lib/crypto/RoomList.js.map +0 -1
  126. package/lib/crypto/SecretSharing.d.ts +0 -24
  127. package/lib/crypto/SecretSharing.d.ts.map +0 -1
  128. package/lib/crypto/SecretSharing.js +0 -194
  129. package/lib/crypto/SecretSharing.js.map +0 -1
  130. package/lib/crypto/SecretStorage.d.ts +0 -55
  131. package/lib/crypto/SecretStorage.d.ts.map +0 -1
  132. package/lib/crypto/SecretStorage.js +0 -118
  133. package/lib/crypto/SecretStorage.js.map +0 -1
  134. package/lib/crypto/aes.d.ts +0 -6
  135. package/lib/crypto/aes.d.ts.map +0 -1
  136. package/lib/crypto/aes.js +0 -24
  137. package/lib/crypto/aes.js.map +0 -1
  138. package/lib/crypto/algorithms/base.d.ts +0 -156
  139. package/lib/crypto/algorithms/base.d.ts.map +0 -1
  140. package/lib/crypto/algorithms/base.js +0 -187
  141. package/lib/crypto/algorithms/base.js.map +0 -1
  142. package/lib/crypto/algorithms/index.d.ts +0 -4
  143. package/lib/crypto/algorithms/index.d.ts.map +0 -1
  144. package/lib/crypto/algorithms/index.js +0 -20
  145. package/lib/crypto/algorithms/index.js.map +0 -1
  146. package/lib/crypto/algorithms/megolm.d.ts +0 -385
  147. package/lib/crypto/algorithms/megolm.d.ts.map +0 -1
  148. package/lib/crypto/algorithms/megolm.js +0 -1822
  149. package/lib/crypto/algorithms/megolm.js.map +0 -1
  150. package/lib/crypto/algorithms/olm.d.ts +0 -5
  151. package/lib/crypto/algorithms/olm.d.ts.map +0 -1
  152. package/lib/crypto/algorithms/olm.js +0 -299
  153. package/lib/crypto/algorithms/olm.js.map +0 -1
  154. package/lib/crypto/api.d.ts +0 -32
  155. package/lib/crypto/api.d.ts.map +0 -1
  156. package/lib/crypto/api.js +0 -22
  157. package/lib/crypto/api.js.map +0 -1
  158. package/lib/crypto/backup.d.ts +0 -227
  159. package/lib/crypto/backup.d.ts.map +0 -1
  160. package/lib/crypto/backup.js +0 -824
  161. package/lib/crypto/backup.js.map +0 -1
  162. package/lib/crypto/crypto.d.ts +0 -3
  163. package/lib/crypto/crypto.d.ts.map +0 -1
  164. package/lib/crypto/crypto.js +0 -19
  165. package/lib/crypto/crypto.js.map +0 -1
  166. package/lib/crypto/dehydration.d.ts +0 -34
  167. package/lib/crypto/dehydration.d.ts.map +0 -1
  168. package/lib/crypto/dehydration.js +0 -252
  169. package/lib/crypto/dehydration.js.map +0 -1
  170. package/lib/crypto/device-converter.d.ts +0 -9
  171. package/lib/crypto/device-converter.d.ts.map +0 -1
  172. package/lib/crypto/device-converter.js +0 -42
  173. package/lib/crypto/device-converter.js.map +0 -1
  174. package/lib/crypto/deviceinfo.d.ts +0 -99
  175. package/lib/crypto/deviceinfo.d.ts.map +0 -1
  176. package/lib/crypto/deviceinfo.js +0 -148
  177. package/lib/crypto/deviceinfo.js.map +0 -1
  178. package/lib/crypto/index.d.ts +0 -1209
  179. package/lib/crypto/index.d.ts.map +0 -1
  180. package/lib/crypto/index.js +0 -4097
  181. package/lib/crypto/index.js.map +0 -1
  182. package/lib/crypto/key_passphrase.d.ts +0 -14
  183. package/lib/crypto/key_passphrase.d.ts.map +0 -1
  184. package/lib/crypto/key_passphrase.js +0 -44
  185. package/lib/crypto/key_passphrase.js.map +0 -1
  186. package/lib/crypto/keybackup.d.ts +0 -18
  187. package/lib/crypto/keybackup.d.ts.map +0 -1
  188. package/lib/crypto/keybackup.js +0 -1
  189. package/lib/crypto/keybackup.js.map +0 -1
  190. package/lib/crypto/olmlib.d.ts +0 -129
  191. package/lib/crypto/olmlib.d.ts.map +0 -1
  192. package/lib/crypto/olmlib.js +0 -492
  193. package/lib/crypto/olmlib.js.map +0 -1
  194. package/lib/crypto/recoverykey.d.ts +0 -2
  195. package/lib/crypto/recoverykey.d.ts.map +0 -1
  196. package/lib/crypto/recoverykey.js +0 -19
  197. package/lib/crypto/recoverykey.js.map +0 -1
  198. package/lib/crypto/store/base.d.ts +0 -252
  199. package/lib/crypto/store/base.d.ts.map +0 -1
  200. package/lib/crypto/store/base.js +0 -64
  201. package/lib/crypto/store/base.js.map +0 -1
  202. package/lib/crypto/store/indexeddb-crypto-store-backend.d.ts +0 -187
  203. package/lib/crypto/store/indexeddb-crypto-store-backend.d.ts.map +0 -1
  204. package/lib/crypto/store/indexeddb-crypto-store-backend.js +0 -1145
  205. package/lib/crypto/store/indexeddb-crypto-store-backend.js.map +0 -1
  206. package/lib/crypto/store/indexeddb-crypto-store.d.ts +0 -432
  207. package/lib/crypto/store/indexeddb-crypto-store.d.ts.map +0 -1
  208. package/lib/crypto/store/indexeddb-crypto-store.js +0 -728
  209. package/lib/crypto/store/indexeddb-crypto-store.js.map +0 -1
  210. package/lib/crypto/store/localStorage-crypto-store.d.ts +0 -119
  211. package/lib/crypto/store/localStorage-crypto-store.d.ts.map +0 -1
  212. package/lib/crypto/store/localStorage-crypto-store.js +0 -531
  213. package/lib/crypto/store/localStorage-crypto-store.js.map +0 -1
  214. package/lib/crypto/store/memory-crypto-store.d.ts +0 -215
  215. package/lib/crypto/store/memory-crypto-store.d.ts.map +0 -1
  216. package/lib/crypto/store/memory-crypto-store.js +0 -622
  217. package/lib/crypto/store/memory-crypto-store.js.map +0 -1
  218. package/lib/crypto/verification/Base.d.ts +0 -105
  219. package/lib/crypto/verification/Base.d.ts.map +0 -1
  220. package/lib/crypto/verification/Base.js +0 -372
  221. package/lib/crypto/verification/Base.js.map +0 -1
  222. package/lib/crypto/verification/Error.d.ts +0 -35
  223. package/lib/crypto/verification/Error.d.ts.map +0 -1
  224. package/lib/crypto/verification/Error.js +0 -86
  225. package/lib/crypto/verification/Error.js.map +0 -1
  226. package/lib/crypto/verification/IllegalMethod.d.ts +0 -15
  227. package/lib/crypto/verification/IllegalMethod.d.ts.map +0 -1
  228. package/lib/crypto/verification/IllegalMethod.js +0 -43
  229. package/lib/crypto/verification/IllegalMethod.js.map +0 -1
  230. package/lib/crypto/verification/QRCode.d.ts +0 -51
  231. package/lib/crypto/verification/QRCode.d.ts.map +0 -1
  232. package/lib/crypto/verification/QRCode.js +0 -277
  233. package/lib/crypto/verification/QRCode.js.map +0 -1
  234. package/lib/crypto/verification/SAS.d.ts +0 -27
  235. package/lib/crypto/verification/SAS.d.ts.map +0 -1
  236. package/lib/crypto/verification/SAS.js +0 -485
  237. package/lib/crypto/verification/SAS.js.map +0 -1
  238. package/lib/crypto/verification/SASDecimal.d.ts +0 -8
  239. package/lib/crypto/verification/SASDecimal.d.ts.map +0 -1
  240. package/lib/crypto/verification/SASDecimal.js +0 -34
  241. package/lib/crypto/verification/SASDecimal.js.map +0 -1
  242. package/lib/crypto/verification/request/Channel.d.ts +0 -18
  243. package/lib/crypto/verification/request/Channel.d.ts.map +0 -1
  244. package/lib/crypto/verification/request/Channel.js +0 -1
  245. package/lib/crypto/verification/request/Channel.js.map +0 -1
  246. package/lib/crypto/verification/request/InRoomChannel.d.ts +0 -113
  247. package/lib/crypto/verification/request/InRoomChannel.d.ts.map +0 -1
  248. package/lib/crypto/verification/request/InRoomChannel.js +0 -351
  249. package/lib/crypto/verification/request/InRoomChannel.js.map +0 -1
  250. package/lib/crypto/verification/request/ToDeviceChannel.d.ts +0 -105
  251. package/lib/crypto/verification/request/ToDeviceChannel.d.ts.map +0 -1
  252. package/lib/crypto/verification/request/ToDeviceChannel.js +0 -328
  253. package/lib/crypto/verification/request/ToDeviceChannel.js.map +0 -1
  254. package/lib/crypto/verification/request/VerificationRequest.d.ts +0 -227
  255. package/lib/crypto/verification/request/VerificationRequest.d.ts.map +0 -1
  256. package/lib/crypto/verification/request/VerificationRequest.js +0 -937
  257. package/lib/crypto/verification/request/VerificationRequest.js.map +0 -1
  258. package/lib/crypto-api/CryptoEvent.d.ts +0 -69
  259. package/lib/crypto-api/CryptoEvent.d.ts.map +0 -1
  260. package/lib/crypto-api/CryptoEvent.js +0 -33
  261. package/lib/crypto-api/CryptoEvent.js.map +0 -1
  262. package/lib/crypto-api/CryptoEventHandlerMap.d.ts +0 -16
  263. package/lib/crypto-api/CryptoEventHandlerMap.d.ts.map +0 -1
  264. package/lib/crypto-api/CryptoEventHandlerMap.js +0 -22
  265. package/lib/crypto-api/CryptoEventHandlerMap.js.map +0 -1
  266. package/lib/crypto-api/index.d.ts +0 -978
  267. package/lib/crypto-api/index.d.ts.map +0 -1
  268. package/lib/crypto-api/index.js +0 -304
  269. package/lib/crypto-api/index.js.map +0 -1
  270. package/lib/crypto-api/key-passphrase.d.ts +0 -11
  271. package/lib/crypto-api/key-passphrase.d.ts.map +0 -1
  272. package/lib/crypto-api/key-passphrase.js +0 -51
  273. package/lib/crypto-api/key-passphrase.js.map +0 -1
  274. package/lib/crypto-api/keybackup.d.ts +0 -88
  275. package/lib/crypto-api/keybackup.d.ts.map +0 -1
  276. package/lib/crypto-api/keybackup.js +0 -1
  277. package/lib/crypto-api/keybackup.js.map +0 -1
  278. package/lib/crypto-api/recovery-key.d.ts +0 -11
  279. package/lib/crypto-api/recovery-key.d.ts.map +0 -1
  280. package/lib/crypto-api/recovery-key.js +0 -65
  281. package/lib/crypto-api/recovery-key.js.map +0 -1
  282. package/lib/crypto-api/verification.d.ts +0 -344
  283. package/lib/crypto-api/verification.d.ts.map +0 -1
  284. package/lib/crypto-api/verification.js +0 -91
  285. package/lib/crypto-api/verification.js.map +0 -1
  286. package/lib/rendezvous/MSC4108SignInWithQR.d.ts +0 -112
  287. package/lib/rendezvous/MSC4108SignInWithQR.d.ts.map +0 -1
  288. package/lib/rendezvous/MSC4108SignInWithQR.js +0 -392
  289. package/lib/rendezvous/MSC4108SignInWithQR.js.map +0 -1
  290. package/lib/rendezvous/RendezvousChannel.d.ts +0 -27
  291. package/lib/rendezvous/RendezvousChannel.d.ts.map +0 -1
  292. package/lib/rendezvous/RendezvousChannel.js +0 -1
  293. package/lib/rendezvous/RendezvousChannel.js.map +0 -1
  294. package/lib/rendezvous/RendezvousCode.d.ts +0 -9
  295. package/lib/rendezvous/RendezvousCode.d.ts.map +0 -1
  296. package/lib/rendezvous/RendezvousCode.js +0 -1
  297. package/lib/rendezvous/RendezvousCode.js.map +0 -1
  298. package/lib/rendezvous/RendezvousError.d.ts +0 -6
  299. package/lib/rendezvous/RendezvousError.d.ts.map +0 -1
  300. package/lib/rendezvous/RendezvousError.js +0 -23
  301. package/lib/rendezvous/RendezvousError.js.map +0 -1
  302. package/lib/rendezvous/RendezvousFailureReason.d.ts +0 -31
  303. package/lib/rendezvous/RendezvousFailureReason.d.ts.map +0 -1
  304. package/lib/rendezvous/RendezvousFailureReason.js +0 -38
  305. package/lib/rendezvous/RendezvousFailureReason.js.map +0 -1
  306. package/lib/rendezvous/RendezvousIntent.d.ts +0 -5
  307. package/lib/rendezvous/RendezvousIntent.d.ts.map +0 -1
  308. package/lib/rendezvous/RendezvousIntent.js +0 -22
  309. package/lib/rendezvous/RendezvousIntent.js.map +0 -1
  310. package/lib/rendezvous/RendezvousTransport.d.ts +0 -36
  311. package/lib/rendezvous/RendezvousTransport.d.ts.map +0 -1
  312. package/lib/rendezvous/RendezvousTransport.js +0 -1
  313. package/lib/rendezvous/RendezvousTransport.js.map +0 -1
  314. package/lib/rendezvous/channels/MSC4108SecureChannel.d.ts +0 -58
  315. package/lib/rendezvous/channels/MSC4108SecureChannel.d.ts.map +0 -1
  316. package/lib/rendezvous/channels/MSC4108SecureChannel.js +0 -246
  317. package/lib/rendezvous/channels/MSC4108SecureChannel.js.map +0 -1
  318. package/lib/rendezvous/channels/index.d.ts +0 -2
  319. package/lib/rendezvous/channels/index.d.ts.map +0 -1
  320. package/lib/rendezvous/channels/index.js +0 -18
  321. package/lib/rendezvous/channels/index.js.map +0 -1
  322. package/lib/rendezvous/index.d.ts +0 -10
  323. package/lib/rendezvous/index.d.ts.map +0 -1
  324. package/lib/rendezvous/index.js +0 -23
  325. package/lib/rendezvous/index.js.map +0 -1
  326. package/lib/rendezvous/transports/MSC4108RendezvousSession.d.ts +0 -61
  327. package/lib/rendezvous/transports/MSC4108RendezvousSession.d.ts.map +0 -1
  328. package/lib/rendezvous/transports/MSC4108RendezvousSession.js +0 -253
  329. package/lib/rendezvous/transports/MSC4108RendezvousSession.js.map +0 -1
  330. package/lib/rendezvous/transports/index.d.ts +0 -2
  331. package/lib/rendezvous/transports/index.d.ts.map +0 -1
  332. package/lib/rendezvous/transports/index.js +0 -18
  333. package/lib/rendezvous/transports/index.js.map +0 -1
  334. package/lib/rust-crypto/CrossSigningIdentity.d.ts +0 -33
  335. package/lib/rust-crypto/CrossSigningIdentity.d.ts.map +0 -1
  336. package/lib/rust-crypto/CrossSigningIdentity.js +0 -157
  337. package/lib/rust-crypto/CrossSigningIdentity.js.map +0 -1
  338. package/lib/rust-crypto/DehydratedDeviceManager.d.ts +0 -98
  339. package/lib/rust-crypto/DehydratedDeviceManager.d.ts.map +0 -1
  340. package/lib/rust-crypto/DehydratedDeviceManager.js +0 -285
  341. package/lib/rust-crypto/DehydratedDeviceManager.js.map +0 -1
  342. package/lib/rust-crypto/KeyClaimManager.d.ts +0 -33
  343. package/lib/rust-crypto/KeyClaimManager.d.ts.map +0 -1
  344. package/lib/rust-crypto/KeyClaimManager.js +0 -82
  345. package/lib/rust-crypto/KeyClaimManager.js.map +0 -1
  346. package/lib/rust-crypto/OutgoingRequestProcessor.d.ts +0 -43
  347. package/lib/rust-crypto/OutgoingRequestProcessor.d.ts.map +0 -1
  348. package/lib/rust-crypto/OutgoingRequestProcessor.js +0 -195
  349. package/lib/rust-crypto/OutgoingRequestProcessor.js.map +0 -1
  350. package/lib/rust-crypto/OutgoingRequestsManager.d.ts +0 -47
  351. package/lib/rust-crypto/OutgoingRequestsManager.d.ts.map +0 -1
  352. package/lib/rust-crypto/OutgoingRequestsManager.js +0 -148
  353. package/lib/rust-crypto/OutgoingRequestsManager.js.map +0 -1
  354. package/lib/rust-crypto/PerSessionKeyBackupDownloader.d.ts +0 -120
  355. package/lib/rust-crypto/PerSessionKeyBackupDownloader.d.ts.map +0 -1
  356. package/lib/rust-crypto/PerSessionKeyBackupDownloader.js +0 -467
  357. package/lib/rust-crypto/PerSessionKeyBackupDownloader.js.map +0 -1
  358. package/lib/rust-crypto/RoomEncryptor.d.ts +0 -98
  359. package/lib/rust-crypto/RoomEncryptor.d.ts.map +0 -1
  360. package/lib/rust-crypto/RoomEncryptor.js +0 -299
  361. package/lib/rust-crypto/RoomEncryptor.js.map +0 -1
  362. package/lib/rust-crypto/backup.d.ts +0 -254
  363. package/lib/rust-crypto/backup.d.ts.map +0 -1
  364. package/lib/rust-crypto/backup.js +0 -837
  365. package/lib/rust-crypto/backup.js.map +0 -1
  366. package/lib/rust-crypto/constants.d.ts +0 -3
  367. package/lib/rust-crypto/constants.d.ts.map +0 -1
  368. package/lib/rust-crypto/constants.js +0 -19
  369. package/lib/rust-crypto/constants.js.map +0 -1
  370. package/lib/rust-crypto/device-converter.d.ts +0 -28
  371. package/lib/rust-crypto/device-converter.d.ts.map +0 -1
  372. package/lib/rust-crypto/device-converter.js +0 -123
  373. package/lib/rust-crypto/device-converter.js.map +0 -1
  374. package/lib/rust-crypto/index.d.ts +0 -61
  375. package/lib/rust-crypto/index.d.ts.map +0 -1
  376. package/lib/rust-crypto/index.js +0 -152
  377. package/lib/rust-crypto/index.js.map +0 -1
  378. package/lib/rust-crypto/libolm_migration.d.ts +0 -81
  379. package/lib/rust-crypto/libolm_migration.d.ts.map +0 -1
  380. package/lib/rust-crypto/libolm_migration.js +0 -459
  381. package/lib/rust-crypto/libolm_migration.js.map +0 -1
  382. package/lib/rust-crypto/rust-crypto.d.ts +0 -556
  383. package/lib/rust-crypto/rust-crypto.d.ts.map +0 -1
  384. package/lib/rust-crypto/rust-crypto.js +0 -2016
  385. package/lib/rust-crypto/rust-crypto.js.map +0 -1
  386. package/lib/rust-crypto/secret-storage.d.ts +0 -22
  387. package/lib/rust-crypto/secret-storage.d.ts.map +0 -1
  388. package/lib/rust-crypto/secret-storage.js +0 -63
  389. package/lib/rust-crypto/secret-storage.js.map +0 -1
  390. package/lib/rust-crypto/verification.d.ts +0 -319
  391. package/lib/rust-crypto/verification.d.ts.map +0 -1
  392. package/lib/rust-crypto/verification.js +0 -816
  393. package/lib/rust-crypto/verification.js.map +0 -1
  394. package/lib/secret-storage.d.ts +0 -370
  395. package/lib/secret-storage.d.ts.map +0 -1
  396. package/lib/secret-storage.js +0 -466
  397. package/lib/secret-storage.js.map +0 -1
  398. package/lib/utils/decryptAESSecretStorageItem.d.ts +0 -12
  399. package/lib/utils/decryptAESSecretStorageItem.d.ts.map +0 -1
  400. package/lib/utils/decryptAESSecretStorageItem.js +0 -50
  401. package/lib/utils/decryptAESSecretStorageItem.js.map +0 -1
  402. package/lib/utils/encryptAESSecretStorageItem.d.ts +0 -16
  403. package/lib/utils/encryptAESSecretStorageItem.d.ts.map +0 -1
  404. package/lib/utils/encryptAESSecretStorageItem.js +0 -68
  405. package/lib/utils/encryptAESSecretStorageItem.js.map +0 -1
  406. package/lib/utils/internal/deriveKeys.d.ts +0 -10
  407. package/lib/utils/internal/deriveKeys.d.ts.map +0 -1
  408. package/lib/utils/internal/deriveKeys.js +0 -60
  409. package/lib/utils/internal/deriveKeys.js.map +0 -1
  410. package/src/@types/AESEncryptedSecretStoragePayload.ts +0 -29
  411. package/src/@types/crypto.ts +0 -73
  412. package/src/@types/matrix-sdk-crypto-wasm.d.ts +0 -44
  413. package/src/common-crypto/CryptoBackend.ts +0 -302
  414. package/src/common-crypto/README.md +0 -4
  415. package/src/common-crypto/key-passphrase.ts +0 -43
  416. package/src/crypto/CrossSigning.ts +0 -773
  417. package/src/crypto/DeviceList.ts +0 -989
  418. package/src/crypto/EncryptionSetup.ts +0 -351
  419. package/src/crypto/OlmDevice.ts +0 -1500
  420. package/src/crypto/OutgoingRoomKeyRequestManager.ts +0 -485
  421. package/src/crypto/RoomList.ts +0 -70
  422. package/src/crypto/SecretSharing.ts +0 -240
  423. package/src/crypto/SecretStorage.ts +0 -136
  424. package/src/crypto/aes.ts +0 -23
  425. package/src/crypto/algorithms/base.ts +0 -236
  426. package/src/crypto/algorithms/index.ts +0 -20
  427. package/src/crypto/algorithms/megolm.ts +0 -2216
  428. package/src/crypto/algorithms/olm.ts +0 -381
  429. package/src/crypto/api.ts +0 -70
  430. package/src/crypto/backup.ts +0 -922
  431. package/src/crypto/crypto.ts +0 -18
  432. package/src/crypto/dehydration.ts +0 -272
  433. package/src/crypto/device-converter.ts +0 -45
  434. package/src/crypto/deviceinfo.ts +0 -158
  435. package/src/crypto/index.ts +0 -4414
  436. package/src/crypto/key_passphrase.ts +0 -42
  437. package/src/crypto/keybackup.ts +0 -47
  438. package/src/crypto/olmlib.ts +0 -539
  439. package/src/crypto/recoverykey.ts +0 -18
  440. package/src/crypto/store/base.ts +0 -348
  441. package/src/crypto/store/indexeddb-crypto-store-backend.ts +0 -1250
  442. package/src/crypto/store/indexeddb-crypto-store.ts +0 -845
  443. package/src/crypto/store/localStorage-crypto-store.ts +0 -579
  444. package/src/crypto/store/memory-crypto-store.ts +0 -680
  445. package/src/crypto/verification/Base.ts +0 -409
  446. package/src/crypto/verification/Error.ts +0 -76
  447. package/src/crypto/verification/IllegalMethod.ts +0 -50
  448. package/src/crypto/verification/QRCode.ts +0 -310
  449. package/src/crypto/verification/SAS.ts +0 -494
  450. package/src/crypto/verification/SASDecimal.ts +0 -37
  451. package/src/crypto/verification/request/Channel.ts +0 -34
  452. package/src/crypto/verification/request/InRoomChannel.ts +0 -371
  453. package/src/crypto/verification/request/ToDeviceChannel.ts +0 -354
  454. package/src/crypto/verification/request/VerificationRequest.ts +0 -976
  455. package/src/crypto-api/CryptoEvent.ts +0 -93
  456. package/src/crypto-api/CryptoEventHandlerMap.ts +0 -32
  457. package/src/crypto-api/index.ts +0 -1175
  458. package/src/crypto-api/key-passphrase.ts +0 -58
  459. package/src/crypto-api/keybackup.ts +0 -115
  460. package/src/crypto-api/recovery-key.ts +0 -69
  461. package/src/crypto-api/verification.ts +0 -408
  462. package/src/rendezvous/MSC4108SignInWithQR.ts +0 -444
  463. package/src/rendezvous/RendezvousChannel.ts +0 -48
  464. package/src/rendezvous/RendezvousCode.ts +0 -25
  465. package/src/rendezvous/RendezvousError.ts +0 -26
  466. package/src/rendezvous/RendezvousFailureReason.ts +0 -49
  467. package/src/rendezvous/RendezvousIntent.ts +0 -20
  468. package/src/rendezvous/RendezvousTransport.ts +0 -58
  469. package/src/rendezvous/channels/MSC4108SecureChannel.ts +0 -270
  470. package/src/rendezvous/channels/index.ts +0 -17
  471. package/src/rendezvous/index.ts +0 -25
  472. package/src/rendezvous/transports/MSC4108RendezvousSession.ts +0 -270
  473. package/src/rendezvous/transports/index.ts +0 -17
  474. package/src/rust-crypto/CrossSigningIdentity.ts +0 -183
  475. package/src/rust-crypto/DehydratedDeviceManager.ts +0 -306
  476. package/src/rust-crypto/KeyClaimManager.ts +0 -86
  477. package/src/rust-crypto/OutgoingRequestProcessor.ts +0 -236
  478. package/src/rust-crypto/OutgoingRequestsManager.ts +0 -143
  479. package/src/rust-crypto/PerSessionKeyBackupDownloader.ts +0 -501
  480. package/src/rust-crypto/RoomEncryptor.ts +0 -352
  481. package/src/rust-crypto/backup.ts +0 -881
  482. package/src/rust-crypto/constants.ts +0 -18
  483. package/src/rust-crypto/device-converter.ts +0 -128
  484. package/src/rust-crypto/index.ts +0 -237
  485. package/src/rust-crypto/libolm_migration.ts +0 -530
  486. package/src/rust-crypto/rust-crypto.ts +0 -2205
  487. package/src/rust-crypto/secret-storage.ts +0 -60
  488. package/src/rust-crypto/verification.ts +0 -830
  489. package/src/secret-storage.ts +0 -693
  490. package/src/utils/decryptAESSecretStorageItem.ts +0 -54
  491. package/src/utils/encryptAESSecretStorageItem.ts +0 -73
  492. package/src/utils/internal/deriveKeys.ts +0 -63
@@ -1 +1 @@
1
- {"version":3,"file":"event-mapper.js","names":["MatrixEvent","MatrixEventEvent","RelationType","eventMapperFor","client","options","preventReEmit","Boolean","decrypt","mapper","plainOldJsObject","toDevice","room_id","room","getRoom","event","state_key","undefined","findEventById","event_id","status","setUnsigned","_objectSpread","getUnsigned","unsigned","bundledEdit","getServerAggregatedRelation","Replace","content","replacement","makeReplaced","thread","findThreadForEvent","setThread","isEncrypted","reEmitter","reEmit","Decrypted","decryptEventIfNeeded","Replaced","VisibilityChange","BeforeRedaction"],"sources":["../src/event-mapper.ts"],"sourcesContent":["/*\nCopyright 2021 The Matrix.org Foundation C.I.C.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n*/\n\nimport { MatrixClient } from \"./client.ts\";\nimport { IEvent, MatrixEvent, MatrixEventEvent } from \"./models/event.ts\";\nimport { RelationType } from \"./@types/event.ts\";\n\nexport type EventMapper = (obj: Partial<IEvent>) => MatrixEvent;\n\nexport interface MapperOpts {\n // don't re-emit events emitted on an event mapped by this mapper on the client\n preventReEmit?: boolean;\n // decrypt event proactively\n decrypt?: boolean;\n // the event is a to_device event\n toDevice?: boolean;\n}\n\nexport function eventMapperFor(client: MatrixClient, options: MapperOpts): EventMapper {\n let preventReEmit = Boolean(options.preventReEmit);\n const decrypt = options.decrypt !== false;\n\n function mapper(plainOldJsObject: Partial<IEvent>): MatrixEvent {\n if (options.toDevice) {\n delete plainOldJsObject.room_id;\n }\n\n const room = client.getRoom(plainOldJsObject.room_id);\n\n let event: MatrixEvent | undefined;\n // If the event is already known to the room, let's re-use the model rather than duplicating.\n // We avoid doing this to state events as they may be forward or backwards looking which tweaks behaviour.\n if (room && plainOldJsObject.state_key === undefined) {\n event = room.findEventById(plainOldJsObject.event_id!);\n }\n\n if (!event || event.status) {\n event = new MatrixEvent(plainOldJsObject);\n } else {\n // merge the latest unsigned data from the server\n event.setUnsigned({ ...event.getUnsigned(), ...plainOldJsObject.unsigned });\n // prevent doubling up re-emitters\n preventReEmit = true;\n }\n\n // if there is a complete edit bundled alongside the event, perform the replacement.\n // (prior to MSC3925, events were automatically replaced on the server-side. MSC3925 proposes that that doesn't\n // happen automatically but the server does provide us with the whole content of the edit event.)\n const bundledEdit = event.getServerAggregatedRelation<Partial<IEvent>>(RelationType.Replace);\n if (bundledEdit?.content) {\n const replacement = mapper(bundledEdit);\n // XXX: it's worth noting that the spec says we should only respect encrypted edits if, once decrypted, the\n // replacement has a `m.new_content` property. The problem is that we haven't yet decrypted the replacement\n // (it should be happening in the background), so we can't enforce this. Possibly we should for decryption\n // to complete, but that sounds a bit racy. For now, we just assume it's ok.\n event.makeReplaced(replacement);\n }\n\n const thread = room?.findThreadForEvent(event);\n if (thread) {\n event.setThread(thread);\n }\n\n // TODO: once we get rid of the old libolm-backed crypto, we can restrict this to room events (rather than\n // to-device events), because the rust implementation decrypts to-device messages at a higher level.\n // Generally we probably want to use a different eventMapper implementation for to-device events because\n if (event.isEncrypted()) {\n if (!preventReEmit) {\n client.reEmitter.reEmit(event, [MatrixEventEvent.Decrypted]);\n }\n if (decrypt) {\n client.decryptEventIfNeeded(event);\n }\n }\n\n if (!preventReEmit) {\n client.reEmitter.reEmit(event, [MatrixEventEvent.Replaced, MatrixEventEvent.VisibilityChange]);\n room?.reEmitter.reEmit(event, [MatrixEventEvent.BeforeRedaction]);\n }\n return event;\n }\n\n return mapper;\n}\n"],"mappings":";;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAGA,SAAiBA,WAAW,EAAEC,gBAAgB,QAAQ,mBAAmB;AACzE,SAASC,YAAY,QAAQ,mBAAmB;AAahD,OAAO,SAASC,cAAcA,CAACC,MAAoB,EAAEC,OAAmB,EAAe;EACnF,IAAIC,aAAa,GAAGC,OAAO,CAACF,OAAO,CAACC,aAAa,CAAC;EAClD,IAAME,OAAO,GAAGH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AE;MACrB,IAAI,CAAC5B,aAAa,EAAE;QAChBF,MAAM,CAAC+B,SAAS,CAACC,MAAM,CAACrB,KAAK,EAAE,CAACd,gBAAgB,CAACoC,SAAS,CAAC,CAAC;MAChE;MACA,IAAI7B,OAAO,EAAE;QACTJ,MAAM,CAACkC,oBAAoB,CAACvB,KAAK,CAAC;MACtC;IACJ;IAEA,IAAI,CAACT,aAAa,EAAE;MAChBF,MAAM,CAAC+B,SAAS,CAACC,MAAM,CAACrB,KAAK,EAAE,CAACd,gBAAgB,CAACsC,QAAQ,EAAEtC,gBAAgB,CAACuC,gBAAgB,CAAC,CAAC;MAC9F3B,IAAI,aAAJA,IAAI,eAAJA,IAAI,CAAEsB,SAAS,CAACC,MAAM,CAACrB,KAAK,EAAE,CAACd,gBAAgB,CAACwC,eAAe,CAAC,CAAC;IACrE;IACA,OAAO1B,KAAK;EAChB;EAEA,OAAON,MAAM;AACjB","ignoreList":[]}
1
+ {"version":3,"file":"event-mapper.js","names":["MatrixEvent","MatrixEventEvent","RelationType","eventMapperFor","client","options","preventReEmit","Boolean","mapper","plainOldJsObject","toDevice","room_id","room","getRoom","event","state_key","undefined","findEventById","event_id","status","setUnsigned","_objectSpread","getUnsigned","unsigned","bundledEdit","getServerAggregatedRelation","Replace","content","replacement","makeReplaced","thread","findThreadForEvent","setThread","isEncrypted","reEmitter","reEmit","Decrypted","Replaced","VisibilityChange","BeforeRedaction"],"sources":["../src/event-mapper.ts"],"sourcesContent":["/*\nCopyright 2021 The Matrix.org Foundation C.I.C.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n*/\n\nimport { MatrixClient } from \"./client.ts\";\nimport { IEvent, MatrixEvent, MatrixEventEvent } from \"./models/event.ts\";\nimport { RelationType } from \"./@types/event.ts\";\n\nexport type EventMapper = (obj: Partial<IEvent>) => MatrixEvent;\n\nexport interface MapperOpts {\n // don't re-emit events emitted on an event mapped by this mapper on the client\n preventReEmit?: boolean;\n // decrypt event proactively\n decrypt?: boolean;\n // the event is a to_device event\n toDevice?: boolean;\n}\n\nexport function eventMapperFor(client: MatrixClient, options: MapperOpts): EventMapper {\n let preventReEmit = Boolean(options.preventReEmit);\n\n function mapper(plainOldJsObject: Partial<IEvent>): MatrixEvent {\n if (options.toDevice) {\n delete plainOldJsObject.room_id;\n }\n\n const room = client.getRoom(plainOldJsObject.room_id);\n\n let event: MatrixEvent | undefined;\n // If the event is already known to the room, let's re-use the model rather than duplicating.\n // We avoid doing this to state events as they may be forward or backwards looking which tweaks behaviour.\n if (room && plainOldJsObject.state_key === undefined) {\n event = room.findEventById(plainOldJsObject.event_id!);\n }\n\n if (!event || event.status) {\n event = new MatrixEvent(plainOldJsObject);\n } else {\n // merge the latest unsigned data from the server\n event.setUnsigned({ ...event.getUnsigned(), ...plainOldJsObject.unsigned });\n // prevent doubling up re-emitters\n preventReEmit = true;\n }\n\n // if there is a complete edit bundled alongside the event, perform the replacement.\n // (prior to MSC3925, events were automatically replaced on the server-side. MSC3925 proposes that that doesn't\n // happen automatically but the server does provide us with the whole content of the edit event.)\n const bundledEdit = event.getServerAggregatedRelation<Partial<IEvent>>(RelationType.Replace);\n if (bundledEdit?.content) {\n const replacement = mapper(bundledEdit);\n // XXX: it's worth noting that the spec says we should only respect encrypted edits if, once decrypted, the\n // replacement has a `m.new_content` property. The problem is that we haven't yet decrypted the replacement\n // (it should be happening in the background), so we can't enforce this. Possibly we should for decryption\n // to complete, but that sounds a bit racy. For now, we just assume it's ok.\n event.makeReplaced(replacement);\n }\n\n const thread = room?.findThreadForEvent(event);\n if (thread) {\n event.setThread(thread);\n }\n\n // TODO: once we get rid of the old libolm-backed crypto, we can restrict this to room events (rather than\n // to-device events), because the rust implementation decrypts to-device messages at a higher level.\n // Generally we probably want to use a different eventMapper implementation for to-device events because\n if (event.isEncrypted()) {\n if (!preventReEmit) {\n client.reEmitter.reEmit(event, [MatrixEventEvent.Decrypted]);\n }\n }\n\n if (!preventReEmit) {\n client.reEmitter.reEmit(event, [MatrixEventEvent.Replaced, MatrixEventEvent.VisibilityChange]);\n room?.reEmitter.reEmit(event, [MatrixEventEvent.BeforeRedaction]);\n }\n return event;\n }\n\n return mapper;\n}\n"],"mappings":";;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAGA,SAAiBA,WAAW,EAAEC,gBAAgB,QAAQ,mBAAmB;AACzE,SAASC,YAAY,QAAQ,mBAAmB;AAahD,OAAO,SAASC,cAAcA,CAACC,MAAoB,EAAEC,OAAmB,EAAe;EACnF,IAAIC,aAAa,GAAGC,OAAO,CAACF,OAAO,CAACC,aAAa,CAAC;EAElD,SAASE,MAAMA,CAACC,gBAAiC,EAAe;IAC5D,IAAIJ,OAAO,CAACK,QAAQ,EAAE;MAClB,OAAOD,gBAAgB,CAACE,OAAO;IACnC;IAEA,IAAMC,IAAI,GAAGR,MAAM,CAACS,OAAO,CAACJ,gBAAgB,CAACE,OAAO,CAAC;IAErD,IAAIG,KAA8B;IAClC;IACA;IACA,IAAIF,IAAI,IAAIH,gBAAgB,CAACM,SAAS,KAAKC,SAAS,EAAE;MAClDF,KAAK,GAAGF,IAAI,CAACK,aAAa,CAACR,gBAAgB,CAACS,QAAS,CAAC;IAC1D;IAEA,IAAI,CAACJ,KAAK,IAAIA,KAAK,CAACK,MAAM,EAAE;MACxBL,KAAK,GAAG,IAAId,WAAW,CAACS,gBAAgB,CAAC;IAC7C,CAAC,MAAM;MACH;MACAK,KAAK,CAACM,WAAW,CAAAC,aAAA,CAAAA,aAAA,KAAMP,KAAK,CAACQ,WAAW,CAAC,CAAC,GAAKb,gBAAgB,CAACc,QAAQ,CAAE,CAAC;MAC3E;MACAjB,aAAa,GAAG,IAAI;IACxB;;IAEA;IACA;IACA;IACA,IAAMkB,WAAW,GAAGV,KAAK,CAACW,2BAA2B,CAAkBvB,YAAY,CAACwB,OAAO,CAAC;IAC5F,IAAIF,WAAW,aAAXA,WAAW,eAAXA,WAAW,CAAEG,OAAO,EAAE;MACtB,IAAMC,WAAW,GAAGpB,MAAM,CAACgB,WAAW,CAAC;MACvC;MACA;MACA;MACA;MACAV,KAAK,CAACe,YAAY,CAACD,WAAW,CAAC;IACnC;IAEA,IAAME,MAAM,GAAGlB,IAAI,aAAJA,IAAI,uBAAJA,IAAI,CAAEmB,kBAAkB,CAACjB,KAAK,CAAC;IAC9C,IAAIgB,MAAM,EAAE;MACRhB,KAAK,CAACkB,SAAS,CAACF,MAAM,CAAC;IAC3B;;IAEA;IACA;IACA;IACA,IAAIhB,KAAK,CAACmB,WAAW,CAAC,CAAC,EAAE;MACrB,IAAI,CAAC3B,aAAa,EAAE;QAChBF,MAAM,CAAC8B,SAAS,CAACC,MAAM,CAACrB,KAAK,EAAE,CAACb,gBAAgB,CAACmC,SAAS,CAAC,CAAC;MAChE;IACJ;IAEA,IAAI,CAAC9B,aAAa,EAAE;MAChBF,MAAM,CAAC8B,SAAS,CAACC,MAAM,CAACrB,KAAK,EAAE,CAACb,gBAAgB,CAACoC,QAAQ,EAAEpC,gBAAgB,CAACqC,gBAAgB,CAAC,CAAC;MAC9F1B,IAAI,aAAJA,IAAI,eAAJA,IAAI,CAAEsB,SAAS,CAACC,MAAM,CAACrB,KAAK,EAAE,CAACb,gBAAgB,CAACsC,eAAe,CAAC,CAAC;IACrE;IACA,OAAOzB,KAAK;EAChB;EAEA,OAAON,MAAM;AACjB","ignoreList":[]}
package/lib/matrix.d.ts CHANGED
@@ -1,7 +1,6 @@
1
1
  import { WidgetApi } from "matrix-widget-api";
2
2
  import { MatrixClient, ICreateClientOpts } from "./client.ts";
3
3
  import { ICapabilities } from "./embedded.ts";
4
- import { CryptoStore } from "./crypto/store/base.ts";
5
4
  export * from "./client.ts";
6
5
  export * from "./serverCapabilities.ts";
7
6
  export * from "./embedded.ts";
@@ -31,10 +30,6 @@ export * from "./interactive-auth.ts";
31
30
  export * from "./service-types.ts";
32
31
  export * from "./store/memory.ts";
33
32
  export * from "./store/indexeddb.ts";
34
- export * from "./crypto/store/memory-crypto-store.ts";
35
- export * from "./crypto/store/localStorage-crypto-store.ts";
36
- export * from "./crypto/store/indexeddb-crypto-store.ts";
37
- export type { OutgoingRoomKeyRequest } from "./crypto/store/base.ts";
38
33
  export * from "./content-repo.ts";
39
34
  export type * from "./@types/common.ts";
40
35
  export type * from "./@types/uia.ts";
@@ -52,7 +47,6 @@ export * from "./@types/polls.ts";
52
47
  export type * from "./@types/local_notifications.ts";
53
48
  export type * from "./@types/registration.ts";
54
49
  export * from "./@types/read_receipts.ts";
55
- export type * from "./@types/crypto.ts";
56
50
  export * from "./@types/extensible_events.ts";
57
51
  export type * from "./@types/IIdentityServerProvider.ts";
58
52
  export * from "./@types/membership.ts";
@@ -60,11 +54,6 @@ export * from "./models/room-summary.ts";
60
54
  export * from "./models/event-status.ts";
61
55
  export type { RoomSummary } from "./client.ts";
62
56
  export * as ContentHelpers from "./content-helpers.ts";
63
- export * as SecretStorage from "./secret-storage.ts";
64
- export type { ICryptoCallbacks } from "./crypto/index.ts";
65
- export {
66
- /** @deprecated Use {@link Crypto.CryptoEvent} instead */
67
- CryptoEvent, } from "./crypto/index.ts";
68
57
  export { SyncState, SetPresence } from "./sync.ts";
69
58
  export type { ISyncStateData as SyncStateData } from "./sync.ts";
70
59
  export { SlidingSyncEvent } from "./sliding-sync.ts";
@@ -75,14 +64,6 @@ export { IdentityProviderBrand, SSOAction } from "./@types/auth.ts";
75
64
  export type { ISSOFlow as SSOFlow, LoginFlow } from "./@types/auth.ts";
76
65
  export type { IHierarchyRelation as HierarchyRelation, IHierarchyRoom as HierarchyRoom } from "./@types/spaces.ts";
77
66
  export { LocationAssetType } from "./@types/location.ts";
78
- /** @deprecated Backwards-compatibility re-export. Import from `crypto-api` directly. */
79
- export * as Crypto from "./crypto-api/index.ts";
80
- /**
81
- * Configure a different factory to be used for creating crypto stores
82
- *
83
- * @param fac - a function which will return a new `CryptoStore`
84
- */
85
- export declare function setCryptoStoreFactory(fac: () => CryptoStore): void;
86
67
  /**
87
68
  * Construct a Matrix Client. Similar to {@link MatrixClient}
88
69
  * except that the 'request', 'store' and 'scheduler' dependencies are satisfied.
@@ -1 +1 @@
1
- {"version":3,"file":"matrix.d.ts","sourceRoot":"","sources":["../src/matrix.ts"],"names":[],"mappings":"AAgBA,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAK9C,OAAO,EAAE,YAAY,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAC;AAC9D,OAAO,EAAoB,aAAa,EAAE,MAAM,eAAe,CAAC;AAChE,OAAO,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AAErD,cAAc,aAAa,CAAC;AAC5B,cAAc,yBAAyB,CAAC;AACxC,cAAc,eAAe,CAAC;AAC9B,cAAc,qBAAqB,CAAC;AACpC,cAAc,oBAAoB,CAAC;AACnC,cAAc,uBAAuB,CAAC;AACtC,cAAc,aAAa,CAAC;AAC5B,cAAc,aAAa,CAAC;AAC5B,cAAc,oBAAoB,CAAC;AACnC,cAAc,mBAAmB,CAAC;AAClC,cAAc,kBAAkB,CAAC;AACjC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,gCAAgC,CAAC;AAC/C,cAAc,kBAAkB,CAAC;AACjC,cAAc,yBAAyB,CAAC;AACxC,cAAc,wBAAwB,CAAC;AACvC,cAAc,oBAAoB,CAAC;AACnC,cAAc,iCAAiC,CAAC;AAChD,cAAc,kBAAkB,CAAC;AACjC,cAAc,oBAAoB,CAAC;AACnC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,iBAAiB,CAAC;AAChC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,aAAa,CA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C,mBAAmB,qCAAqC,CAAC;AACzD,cAAc,wBAAwB,CAAC;AACvC,cAAc,0BAA0B,CAAC;AACzC,cAAc,0BAA0B,CAAC;AACzC,YAAY,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,KAAK,cAAc,MAAM,sBAAsB,CAAC;AAEvD,OAAO,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AACnD,YAAY,EAAE,cAAc,IAAI,aAAa,EAAE,MAAM,WAAW,CAAC;AACjE,OAAO,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AACrD,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAClE,OAAO,EAAE,iBAAiB,EAAE,MAAM,iCAAiC,CAAC;AACpE,OAAO,EAAE,kBAAkB,EAAE,MAAM,yCAAyC,CAAC;AAC7E,OAAO,EAAE,qBAAqB,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AACpE,YAAY,EAAE,QAAQ,IAAI,OAAO,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AACvE,YAAY,EAAE,kBAAkB,IAAI,iBAAiB,EAAE,cAAc,IAAI,aAAa,EAAE,MAAM,oBAAoB,CAAC;AACnH,OAAO,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAazD;;;;;;;;;GASG;AACH,wBAAgB,YAAY,CAAC,IAAI,EAAE,iBAAiB,GAAG,YAAY,CAElE;AAED;;;;;;;;;;;;;GAaG;AACH,wBAAgB,sBAAsB,CAClC,SAAS,EAAE,SAAS,EACpB,YAAY,EAAE,aAAa,EAC3B,MAAM,EAAE,MAAM,EACd,IAAI,EAAE,iBAAiB,EACvB,iBAAiB,UAAO,GACzB,YAAY,CAEd"}
package/lib/matrix.js CHANGED
@@ -14,7 +14,6 @@ See the License for the specific language governing permissions and
14
14
  limitations under the License.
15
15
  */
16
16
 
17
- import { MemoryCryptoStore } from "./crypto/store/memory-crypto-store.js";
18
17
  import { MemoryStore } from "./store/memory.js";
19
18
  import { MatrixScheduler } from "./scheduler.js";
20
19
  import { MatrixClient } from "./client.js";
@@ -48,9 +47,6 @@ export * from "./interactive-auth.js";
48
47
  export * from "./service-types.js";
49
48
  export * from "./store/memory.js";
50
49
  export * from "./store/indexeddb.js";
51
- export * from "./crypto/store/memory-crypto-store.js";
52
- export * from "./crypto/store/localStorage-crypto-store.js";
53
- export * from "./crypto/store/indexeddb-crypto-store.js";
54
50
  export * from "./content-repo.js";
55
51
  export * from "./@types/event.js";
56
52
  export * from "./@types/PushRules.js";
@@ -70,12 +66,6 @@ export * from "./models/room-summary.js";
70
66
  export * from "./models/event-status.js";
71
67
  import * as _ContentHelpers from "./content-helpers.js";
72
68
  export { _ContentHelpers as ContentHelpers };
73
- import * as _SecretStorage from "./secret-storage.js";
74
- export { _SecretStorage as SecretStorage };
75
- // used to be located here
76
-
77
- export { /** @deprecated Use {@link Crypto.CryptoEvent} instead */
78
- CryptoEvent } from "./crypto/index.js";
79
69
  export { SyncState, SetPresence } from "./sync.js";
80
70
  export { SlidingSyncEvent } from "./sliding-sync.js";
81
71
  export { Relations, RelationsEvent } from "./models/relations.js";
@@ -83,27 +73,12 @@ export { TypedEventEmitter } from "./models/typed-event-emitter.js";
83
73
  export { LocalStorageErrors } from "./store/local-storage-events-emitter.js";
84
74
  export { IdentityProviderBrand, SSOAction } from "./@types/auth.js";
85
75
  export { LocationAssetType } from "./@types/location.js";
86
-
87
- /** @deprecated Backwards-compatibility re-export. Import from `crypto-api` directly. */
88
- import * as _Crypto from "./crypto-api/index.js";
89
- export { _Crypto as Crypto };
90
- var cryptoStoreFactory = () => new MemoryCryptoStore();
91
-
92
- /**
93
- * Configure a different factory to be used for creating crypto stores
94
- *
95
- * @param fac - a function which will return a new `CryptoStore`
96
- */
97
- export function setCryptoStoreFactory(fac) {
98
- cryptoStoreFactory = fac;
99
- }
100
76
  function amendClientOpts(opts) {
101
- var _opts$store, _opts$scheduler, _opts$cryptoStore;
77
+ var _opts$store, _opts$scheduler;
102
78
  opts.store = (_opts$store = opts.store) !== null && _opts$store !== void 0 ? _opts$store : new MemoryStore({
103
79
  localStorage: globalThis.localStorage
104
80
  });
105
81
  opts.scheduler = (_opts$scheduler = opts.scheduler) !== null && _opts$scheduler !== void 0 ? _opts$scheduler : new MatrixScheduler();
106
- opts.cryptoStore = (_opts$cryptoStore = opts.cryptoStore) !== null && _opts$cryptoStore !== void 0 ? _opts$cryptoStore : cryptoStoreFactory();
107
82
  return opts;
108
83
  }
109
84
 
package/lib/matrix.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"matrix.js","names":["MemoryCryptoStore","MemoryStore","MatrixScheduler","MatrixClient","RoomWidgetClient","_ContentHelpers","ContentHelpers","_SecretStorage","SecretStorage","CryptoEvent","SyncState","SetPresence","SlidingSyncEvent","Relations","RelationsEvent","TypedEventEmitter","LocalStorageErrors","IdentityProviderBrand","SSOAction","LocationAssetType","_Crypto","Crypto","cryptoStoreFactory","setCryptoStoreFactory","fac","amendClientOpts","opts","_opts$store","_opts$scheduler","_opts$cryptoStore","store","localStorage","globalThis","scheduler","cryptoStore","createClient","createRoomWidgetClient","widgetApi","capabilities","roomId","sendContentLoaded","arguments","length","undefined"],"sources":["../src/matrix.ts"],"sourcesContent":["/*\nCopyright 2015-2022 The Matrix.org Foundation C.I.C.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n*/\n\nimport { WidgetApi } from \"matrix-widget-api\";\n\nimport { MemoryCryptoStore } from \"./crypto/store/memory-crypto-store.ts\";\nimport { MemoryStore } from \"./store/memory.ts\";\nimport { MatrixScheduler } from \"./scheduler.ts\";\nimport { MatrixClient, ICreateClientOpts } from \"./client.ts\";\nimport { RoomWidgetClient, ICapabilities } from \"./embedded.ts\";\nimport { CryptoStore } from \"./crypto/store/base.ts\";\n\nexport * from \"./client.ts\";\nexport * from \"./serverCapabilities.ts\";\nexport * from \"./embedded.ts\";\nexport * from \"./http-api/index.ts\";\nexport * from \"./autodiscovery.ts\";\nexport * from \"./sync-accumulator.ts\";\nexport * from \"./errors.ts\";\nexport * from \"./base64.ts\";\nexport * from \"./models/beacon.ts\";\nexport * from \"./models/event.ts\";\nexport * from \"./models/room.ts\";\nexport * from \"./models/event-timeline.ts\";\nexport * from \"./models/event-timeline-set.ts\";\nexport * from \"./models/poll.ts\";\nexport * from \"./models/room-member.ts\";\nexport * from \"./models/room-state.ts\";\nexport * from \"./models/thread.ts\";\nexport * from \"./models/typed-event-emitter.ts\";\nexport * from \"./models/user.ts\";\nexport * from \"./models/device.ts\";\nexport * from \"./models/search-result.ts\";\nexport * from \"./oidc/index.ts\";\nexport * from \"./scheduler.ts\";\nexport * from \"./filter.ts\";\nexport * from \"./timeline-window.ts\";\nexport * from \"./interactive-auth.ts\";\nexport * from \"./service-types.ts\";\nexport * from \"./store/memory.ts\";\nexport * from \"./store/indexeddb.ts\";\nexport * from \"./crypto/store/memory-crypto-store.ts\";\nexport * from \"./crypto/store/localStorage-crypto-store.ts\";\nexport * from \"./crypto/store/indexeddb-crypto-store.ts\";\nexport type { OutgoingRoomKeyRequest } from \"./crypto/store/base.ts\";\nexport * from \"./content-repo.ts\";\nexport type * from \"./@types/common.ts\";\nexport type * from \"./@types/uia.ts\";\nexport * from \"./@types/event.ts\";\nexport * from \"./@types/PushRules.ts\";\nexport * from \"./@types/partials.ts\";\nexport * from \"./@types/requests.ts\";\nexport * from \"./@types/search.ts\";\nexport * from \"./@types/beacon.ts\";\nexport * from \"./@types/topic.ts\";\nexport * from \"./@types/location.ts\";\nexport * from \"./@types/threepids.ts\";\nexport * from \"./@types/auth.ts\";\nexport * from \"./@types/polls.ts\";\nexport type * from \"./@types/local_notifications.ts\";\nexport type * from \"./@types/registration.ts\";\nexport * from \"./@types/read_receipts.ts\";\nexport type * from \"./@types/crypto.ts\";\nexport * from \"./@types/extensible_events.ts\";\nexport type * from \"./@types/IIdentityServerProvider.ts\";\nexport * from \"./@types/membership.ts\";\nexport * from \"./models/room-summary.ts\";\nexport * from \"./models/event-status.ts\";\nexport type { RoomSummary } from \"./client.ts\";\nexport * as ContentHelpers from \"./content-helpers.ts\";\nexport * as SecretStorage from \"./secret-storage.ts\";\nexport type { ICryptoCallbacks } from \"./crypto/index.ts\"; // used to be located here\n\nexport {\n /** @deprecated Use {@link Crypto.CryptoEvent} instead */\n CryptoEvent,\n} from \"./crypto/index.ts\";\nexport { SyncState, SetPresence } from \"./sync.ts\";\nexport type { ISyncStateData as SyncStateData } from \"./sync.ts\";\nexport { SlidingSyncEvent } from \"./sliding-sync.ts\";\nexport { Relations, RelationsEvent } from \"./models/relations.ts\";\nexport { TypedEventEmitter } from \"./models/typed-event-emitter.ts\";\nexport { LocalStorageErrors } from \"./store/local-storage-events-emitter.ts\";\nexport { IdentityProviderBrand, SSOAction } from \"./@types/auth.ts\";\nexport type { ISSOFlow as SSOFlow, LoginFlow } from \"./@types/auth.ts\";\nexport type { IHierarchyRelation as HierarchyRelation, IHierarchyRoom as HierarchyRoom } from \"./@types/spaces.ts\";\nexport { LocationAssetType } from \"./@types/location.ts\";\n\n/** @deprecated Backwards-compatibility re-export. Import from `crypto-api` directly. */\nexport * as Crypto from \"./crypto-api/index.ts\";\n\nlet cryptoStoreFactory = (): CryptoStore => new MemoryCryptoStore();\n\n/**\n * Configure a different factory to be used for creating crypto stores\n *\n * @param fac - a function which will return a new `CryptoStore`\n */\nexport function setCryptoStoreFactory(fac: () => CryptoStore): void {\n cryptoStoreFactory = fac;\n}\n\nfunction amendClientOpts(opts: ICreateClientOpts): ICreateClientOpts {\n opts.store =\n opts.store ??\n new MemoryStore({\n localStorage: globalThis.localStorage,\n });\n opts.scheduler = opts.scheduler ?? new MatrixScheduler();\n opts.cryptoStore = opts.cryptoStore ?? cryptoStoreFactory();\n\n return opts;\n}\n\n/**\n * Construct a Matrix Client. Similar to {@link MatrixClient}\n * except that the 'request', 'store' and 'scheduler' dependencies are satisfied.\n * @param opts - The configuration options for this client. These configuration\n * options will be passed directly to {@link MatrixClient}.\n *\n * @returns A new matrix client.\n * @see {@link MatrixClient} for the full list of options for\n * `opts`.\n */\nexport function createClient(opts: ICreateClientOpts): MatrixClient {\n return new MatrixClient(amendClientOpts(opts));\n}\n\n/**\n * Construct a Matrix Client that works in a widget.\n * This client has a subset of features compared to a full client.\n * It uses the widget-api to communicate with matrix. (widget \\<-\\> client \\<-\\> homeserver)\n * @returns A new matrix client with a subset of features.\n * @param opts - The configuration options for this client. These configuration\n * options will be passed directly to {@link MatrixClient}.\n * @param widgetApi - The widget api to use for communication.\n * @param capabilities - The capabilities the widget client will request.\n * @param roomId - The room id the widget is associated with.\n * @param sendContentLoaded - Whether to send a content loaded widget action immediately after initial setup.\n * Set to `false` if the widget uses `waitForIFrameLoad=true` (in this case the client does not expect a content loaded action at all),\n * or if the the widget wants to send the `ContentLoaded` action at a later point in time after the initial setup.\n */\nexport function createRoomWidgetClient(\n widgetApi: WidgetApi,\n capabilities: ICapabilities,\n roomId: string,\n opts: ICreateClientOpts,\n sendContentLoaded = true,\n): MatrixClient {\n return new RoomWidgetClient(widgetApi, capabilities, roomId, amendClientOpts(opts), sendContentLoaded);\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAIA,SAASA,iBAAiB,QAAQ,uCAAuC;AACzE,SAASC,WAAW,QAAQ,mBAAmB;AAC/C,SAASC,eAAe,QAAQ,gBAAgB;AAChD,SAASC,YAAY,QAA2B,aAAa;AAC7D,SAASC,gBAAgB,QAAuB,eAAe;AAG/D,cAAc,aAAa;AAC3B,cAAc,yBAAyB;AACvC,c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sBA,CAClCC,SAAoB,EACpBC,YAA2B,EAC3BC,MAAc,EACdb,IAAuB,EAEX;EAAA,IADZc,iBAAiB,GAAAC,SAAA,CAAAC,MAAA,QAAAD,SAAA,QAAAE,SAAA,GAAAF,SAAA,MAAG,IAAI;EAExB,OAAO,IAAIrC,gBAAgB,CAACiC,SAAS,EAAEC,YAAY,EAAEC,MAAM,EAAEd,eAAe,CAACC,IAAI,CAAC,EAAEc,iBAAiB,CAAC;AAC1G","ignoreList":[]}
1
+ {"version":3,"file":"matrix.js","names":["MemoryStore","MatrixScheduler","MatrixClient","RoomWidgetClient","_ContentHelpers","ContentHelpers","SyncState","SetPresence","SlidingSyncEvent","Relations","RelationsEvent","TypedEventEmitter","LocalStorageErrors","IdentityProviderBrand","SSOAction","LocationAssetType","amendClientOpts","opts","_opts$store","_opts$scheduler","store","localStorage","globalThis","scheduler","createClient","createRoomWidgetClient","widgetApi","capabilities","roomId","sendContentLoaded","arguments","length","undefined"],"sources":["../src/matrix.ts"],"sourcesContent":["/*\nCopyright 2015-2022 The Matrix.org Foundation C.I.C.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n*/\n\nimport { WidgetApi } from \"matrix-widget-api\";\n\nimport { MemoryStore } from \"./store/memory.ts\";\nimport { MatrixScheduler } from \"./scheduler.ts\";\nimport { MatrixClient, ICreateClientOpts } from \"./client.ts\";\nimport { RoomWidgetClient, ICapabilities } from \"./embedded.ts\";\n\nexport * from \"./client.ts\";\nexport * from \"./serverCapabilities.ts\";\nexport * from \"./embedded.ts\";\nexport * from \"./http-api/index.ts\";\nexport * from \"./autodiscovery.ts\";\nexport * from \"./sync-accumulator.ts\";\nexport * from \"./errors.ts\";\nexport * from \"./base64.ts\";\nexport * from \"./models/beacon.ts\";\nexport * from \"./models/event.ts\";\nexport * from \"./models/room.ts\";\nexport * from \"./models/event-timeline.ts\";\nexport * from \"./models/event-timeline-set.ts\";\nexport * from \"./models/poll.ts\";\nexport * from \"./models/room-member.ts\";\nexport * from \"./models/room-state.ts\";\nexport * from \"./models/thread.ts\";\nexport * from \"./models/typed-event-emitter.ts\";\nexport * from \"./models/user.ts\";\nexport * from \"./models/device.ts\";\nexport * from \"./models/search-result.ts\";\nexport * from \"./oidc/index.ts\";\nexport * from \"./scheduler.ts\";\nexport * from \"./filter.ts\";\nexport * from \"./timeline-window.ts\";\nexport * from \"./interactive-auth.ts\";\nexport * from \"./service-types.ts\";\nexport * from \"./store/memory.ts\";\nexport * from \"./store/indexeddb.ts\";\nexport * from \"./content-repo.ts\";\nexport type * from \"./@types/common.ts\";\nexport type * from \"./@types/uia.ts\";\nexport * from \"./@types/event.ts\";\nexport * from \"./@types/PushRules.ts\";\nexport * from \"./@types/partials.ts\";\nexport * from \"./@types/requests.ts\";\nexport * from \"./@types/search.ts\";\nexport * from \"./@types/beacon.ts\";\nexport * from \"./@types/topic.ts\";\nexport * from \"./@types/location.ts\";\nexport * from \"./@types/threepids.ts\";\nexport * from \"./@types/auth.ts\";\nexport * from \"./@types/polls.ts\";\nexport type * from \"./@types/local_notifications.ts\";\nexport type * from \"./@types/registration.ts\";\nexport * from \"./@types/read_receipts.ts\";\nexport * from \"./@types/extensible_events.ts\";\nexport type * from \"./@types/IIdentityServerProvider.ts\";\nexport * from \"./@types/membership.ts\";\nexport * from \"./models/room-summary.ts\";\nexport * from \"./models/event-status.ts\";\nexport type { RoomSummary } from \"./client.ts\";\nexport * as ContentHelpers from \"./content-helpers.ts\";\n\nexport { SyncState, SetPresence } from \"./sync.ts\";\nexport type { ISyncStateData as SyncStateData } from \"./sync.ts\";\nexport { SlidingSyncEvent } from \"./sliding-sync.ts\";\nexport { Relations, RelationsEvent } from \"./models/relations.ts\";\nexport { TypedEventEmitter } from \"./models/typed-event-emitter.ts\";\nexport { LocalStorageErrors } from \"./store/local-storage-events-emitter.ts\";\nexport { IdentityProviderBrand, SSOAction } from \"./@types/auth.ts\";\nexport type { ISSOFlow as SSOFlow, LoginFlow } from \"./@types/auth.ts\";\nexport type { IHierarchyRelation as HierarchyRelation, IHierarchyRoom as HierarchyRoom } from \"./@types/spaces.ts\";\nexport { LocationAssetType } from \"./@types/location.ts\";\n\nfunction amendClientOpts(opts: ICreateClientOpts): ICreateClientOpts {\n opts.store =\n opts.store ??\n new MemoryStore({\n localStorage: globalThis.localStorage,\n });\n opts.scheduler = opts.scheduler ?? new MatrixScheduler();\n\n return opts;\n}\n\n/**\n * Construct a Matrix Client. Similar to {@link MatrixClient}\n * except that the 'request', 'store' and 'scheduler' dependencies are satisfied.\n * @param opts - The configuration options for this client. These configuration\n * options will be passed directly to {@link MatrixClient}.\n *\n * @returns A new matrix client.\n * @see {@link MatrixClient} for the full list of options for\n * `opts`.\n */\nexport function createClient(opts: ICreateClientOpts): MatrixClient {\n return new MatrixClient(amendClientOpts(opts));\n}\n\n/**\n * Construct a Matrix Client that works in a widget.\n * This client has a subset of features compared to a full client.\n * It uses the widget-api to communicate with matrix. (widget \\<-\\> client \\<-\\> homeserver)\n * @returns A new matrix client with a subset of features.\n * @param opts - The configuration options for this client. These configuration\n * options will be passed directly to {@link MatrixClient}.\n * @param widgetApi - The widget api to use for communication.\n * @param capabilities - The capabilities the widget client will request.\n * @param roomId - The room id the widget is associated with.\n * @param sendContentLoaded - Whether to send a content loaded widget action immediately after initial setup.\n * Set to `false` if the widget uses `waitForIFrameLoad=true` (in this case the client does not expect a content loaded action at all),\n * or if the the widget wants to send the `ContentLoaded` action at a later point in time after the initial setup.\n */\nexport function createRoomWidgetClient(\n widgetApi: WidgetApi,\n capabilities: ICapabilities,\n roomId: string,\n opts: ICreateClientOpts,\n sendContentLoaded = true,\n): MatrixClient {\n return new RoomW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AC;IAoC9B;;;;OAIG;IACU,iBAAiB,IAAI,OAAO,CAAC,aAAa,EAAE,CAAC;CAgC7D"}
@@ -156,9 +156,6 @@ export class MSC3089Branch {
156
156
  event = room.getUnfilteredTimelineSet().findEventById(_this5.id);
157
157
  }
158
158
  if (!event) throw new Error("Failed to find event");
159
-
160
- // Sometimes the event isn't decrypted for us, so do that.
161
- yield _this5.client.decryptEventIfNeeded(event);
162
159
  return event;
163
160
  })();
164
161
  }
@@ -1 +1 @@
1
- {"version":3,"file":"MSC3089Branch.js","names":["RelationType","UNSTABLE_MSC3089_BRANCH","EventTimeline","MSC3089Branch","constructor","client","indexEvent","directory","id","stateKey","getStateKey","Error","isActive","getContent","version","_this$indexEvent$getC","roomId","getRoomId","delete","_this","_asyncToGenerator","sendStateEvent","name","redactEvent","nextVersion","getVersionHistory","getName","setName","_this2","_objectSpread","isLocked","setLocked","locked","_this3","getFileInfo","_this4","event","getFileEvent","file","getOriginalContent","httpUrl","mxcUrlToHttp","concat","info","_this5","room","getRoom","getUnfilteredTimelineSet","findEventById","getLiveTimeline","getState","BACKWARDS","paginationToken","scrollback","decryptEventIfNeeded","createNewVersion","encryptedContents","additionalContent","_this6","fileEventResponse","createFile","rel_type","Replace","event_id","active","_this7","fileHistory","push","timelineEvents","getEvents","reverse","childEvent","parentEvent","find","e","replacingEventId","getId","branch","getFile"],"sources":["../../src/models/MSC3089Branch.ts"],"sourcesContent":["/*\nCopyright 2021 The Matrix.org Foundation C.I.C.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n*/\n\nimport { MatrixClient } from \"../client.ts\";\nimport { RelationType, UNSTABLE_MSC3089_BRANCH } from \"../@types/event.ts\";\nimport { IContent, MatrixEvent } from \"./event.ts\";\nimport { MSC3089TreeSpace } from \"./MSC3089TreeSpace.ts\";\nimport { EventTimeline } from \"./event-timeline.ts\";\nimport { FileType } from \"../http-api/index.ts\";\nimport type { ISendEventResponse } from \"../@types/requests.ts\";\nimport { EncryptedFile } from \"../@types/media.ts\";\n\nexport interface MSC3089EventContent {\n active?: boolean;\n name?: string;\n locked?: boolean;\n version?: number;\n}\n\nexport interface MSC3089EventContent {\n active?: boolean;\n name?: string;\n locked?: boolean;\n version?: number;\n}\n\n/**\n * Represents a [MSC3089](https://github.com/matrix-org/matrix-doc/pull/3089) branch - a reference\n * to a file (leaf) in the tree. Note that this is UNSTABLE and subject to breaking changes\n * without notice.\n */\nexport class MSC3089Branch {\n public constructor(\n private client: MatrixClient,\n public readonly indexEvent: MatrixEvent,\n public readonly directory: MSC3089TreeSpace,\n ) {\n // Nothing to do\n }\n\n /**\n * The file ID.\n */\n public get id(): string {\n const stateKey = this.indexEvent.getStateKey();\n if (!stateKey) {\n throw new Error(\"State key not found for branch\");\n }\n return stateKey;\n }\n\n /**\n * Whether this branch is active/valid.\n */\n public get isActive(): boolean {\n return this.indexEvent.getContent()[\"active\"] === true;\n }\n\n /**\n * Version for the file, one-indexed.\n */\n public get version(): number {\n return this.indexEvent.getContent()[\"version\"] ?? 1;\n }\n\n private get roomId(): string {\n return this.indexEvent.getRoomId()!;\n }\n\n /**\n * Deletes the file from the tree, including all prior edits/versions.\n * @returns Promise which resolves when complete.\n */\n public async delete(): Promise<void> {\n await this.client.sendStateEvent(this.roomId, UNSTABLE_MSC3089_BRANCH.name, {}, this.id);\n await this.client.redactEvent(this.roomId, this.id);\n\n const nextVersion = (await this.getVersionHistory())[1]; // [0] will be us\n if (nextVersion) await nextVersion.delete(); // implicit recursion\n }\n\n /**\n * Gets the name for this file.\n * @returns The name, or \"Unnamed File\" if unknown.\n */\n public getName(): string {\n return this.indexEvent.getContent()[\"name\"] || \"Unnamed File\";\n }\n\n /**\n * Sets the name for this file.\n * @param name - The new name for this file.\n * @returns Promise which resolves when complete.\n */\n public async setName(name: string): Promise<void> {\n await this.client.sendStateEvent(\n this.roomId,\n UNSTABLE_MSC3089_BRANCH.name,\n {\n ...this.indexEvent.getContent(),\n name: name,\n },\n this.id,\n );\n }\n\n /**\n * Gets whether or not a file is locked.\n * @returns True if locked, false otherwise.\n */\n public isLocked(): boolean {\n return this.indexEvent.getContent()[\"locked\"] || false;\n }\n\n /**\n * Sets a file as locked or unlocked.\n * @param locked - True to lock the file, false otherwise.\n * @returns Promise which resolves when complete.\n */\n public async setLocked(locked: boolean): Promise<void> {\n await this.client.sendStateEvent(\n this.roomId,\n UNSTABLE_MSC3089_BRANCH.name,\n {\n ...this.indexEvent.getContent(),\n locked: locked,\n },\n this.id,\n );\n }\n\n /**\n * Gets information about the file needed to download it.\n * @returns Information about the file.\n */\n public async getFileInfo(): Promise<{ info: EncryptedFile; httpUrl: string }> {\n const event = await this.getFileEvent();\n\n const file = event.getOriginalContent()[\"file\"];\n const httpUrl = this.client.mxcUrlToHttp(file[\"url\"]);\n\n if (!httpUrl) {\n throw new Error(`No HTTP URL available for ${file[\"url\"]}`);\n }\n\n return { info: file, httpUrl: httpUrl };\n }\n\n /**\n * Gets the event the file points to.\n * @returns Promise which resolves to the file's event.\n */\n public async getFileEvent(): Promise<MatrixEvent> {\n const room = this.client.getRoom(this.roomId);\n if (!room) throw new Error(\"Unknown room\");\n\n let event: MatrixEvent | undefined = room.getUnfilteredTimelineSet().findEventById(this.id);\n\n // keep scrolling back if needed until we find the event or reach the start of the room:\n while (!event && room.getLiveTimeline().getState(EventTimeline.BACKWARDS)!.paginationToken) {\n await this.client.scrollback(room, 100);\n event = room.getUnfilteredTimelineSet().findEventById(this.id);\n }\n\n if (!event) throw new Error(\"Failed to find event\");\n\n // Sometimes the event isn't decrypted for us, so do that.\n await this.client.decryptEventIfNeeded(event);\n\n return event;\n }\n\n /**\n * Creates a new version of this file with contents in a type that is compatible with MatrixClient.uploadContent().\n * @param name - The name of the file.\n * @param encryptedContents - The encrypted contents.\n * @param info - The encrypted file information.\n * @param additionalContent - Optional event content fields to include in the message.\n * @returns Promise which resolves to the file event's sent response.\n */\n public async createNewVersion(\n name: string,\n encryptedContents: FileType,\n info: EncryptedFile,\n additionalContent?: IContent,\n ): Promise<ISendEventResponse> {\n const fileEventResponse = await this.directory.createFile(name, encryptedContents, info, {\n ...(additionalContent ?? {}),\n \"m.new_content\": true,\n \"m.relates_to\": {\n rel_type: RelationType.Replace,\n event_id: this.id,\n },\n });\n\n // Update the version of the new event\n await this.client.sendStateEvent(\n this.roomId,\n UNSTABLE_MSC3089_BRANCH.name,\n {\n active: true,\n name: name,\n version: this.version + 1,\n },\n fileEventResponse[\"event_id\"],\n );\n\n // Deprecate ourselves\n await this.client.sendStateEvent(\n this.roomId,\n UNSTABLE_MSC3089_BRANCH.name,\n {\n ...this.indexEvent.getContent(),\n active: false,\n },\n this.id,\n );\n\n return fileEventResponse;\n }\n\n /**\n * Gets the file's version history, starting at this file.\n * @returns Promise which resolves to the file's version history, with the\n * first element being the current version and the last element being the first version.\n */\n public async getVersionHistory(): Promise<MSC3089Branch[]> {\n const fileHistory: MSC3089Branch[] = [];\n fileHistory.push(this); // start with ourselves\n\n const room = this.client.getRoom(this.roomId);\n if (!room) throw new Error(\"Invalid or unknown room\");\n\n // Clone the timeline to reverse it, getting most-recent-first ordering, hopefully\n // shortening the awful loop below. Without the clone, we can unintentionally mutate\n // the timeline.\n const timelineEvents = [...room.getLiveTimeline().getEvents()].reverse();\n\n // XXX: This is a very inefficient search, but it's the best we can do with the\n // relations structure we have in the SDK. As of writing, it is not worth the\n // investment in improving the structure.\n let childEvent: MatrixEvent | undefined;\n let parentEvent = await this.getFileEvent();\n do {\n childEvent = timelineEvents.find((e) => e.replacingEventId() === parentEvent.getId());\n if (childEvent) {\n const branch = this.directory.getFile(childEvent.getId()!);\n if (branch) {\n fileHistory.push(branch);\n parentEvent = childEvent;\n } else {\n break; // prevent infinite loop\n }\n }\n } while (childEvent);\n\n return fileHistory;\n }\n}\n"],"mappings":";;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAGA,SAASA,YAAY,EAAEC,uBAAuB,QAAQ,oBAAoB;AAG1E,SAASC,aAAa,QAAQ,qBAAqB;AAmBnD;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,aAAa,CAAC;EAChBC,WAAWA,CACNC,MAAoB,EACZC,UAAuB,EACvBC,SAA2B,EAC7C;IAAA,KAHUF,MAAoB,GAApBA,MAAoB;IAAA,KACZC,UAAuB,GAAvBA,UAAuB;IAAA,KACvBC,SAA2B,GAA3BA,SAA2B;EAG/C,CAAC,CADG;;EAGJ;AACJ;AACA;EACI,IAAWC,EAAEA,CAAA,EAAW;IACpB,IAAMC,QAAQ,GAAG,IAAI,CAACH,UAAU,CAACI,WAAW,CAAC,CAAC;IAC9C,IAAI,CAACD,QAAQ,EAAE;MACX,MAAM,IAAIE,KAAK,CAAC,gCAAgC,CAAC;IACrD;IACA,OAAOF,QAAQ;EACnB;;EAEA;AACJ;AACA;EACI,IAAWG,QAAQA,CAAA,EAAY;IAC3B,OAAO,IAAI,CAACN,UAAU,CAACO,UAAU,CAAC,CAAC,CAAC,QAAQ,CAAC,KAAK,IAAI;EAC1D;;EAEA;AACJ;AACA;EACI,IAAWC,OAAOA,CAAA,EAAW;IAAA,IAAAC,qBAAA;IACzB,QAAAA,qBAAA,GAAO,IAAI,CAACT,UAAU,CAACO,UAAU,CAAC,CAAC,CAAC,SAAS,CAAC,cAAAE,qBAAA,cAAAA,qBAAA,GAAI,CAAC;EACvD;EAEA,IAAYC,MAAMA,CAAA,EAAW;IACzB,OAAO,IAAI,CAACV,UAAU,CAACW,SAAS,CAAC,CAAC;EACtC;;EAEA;AACJ;AACA;AACA;EACiBC,MAAMA,CAAA,EAAkB;IAAA,IAAAC,KAAA;IAAA,OA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,UAAU;MAEnB,OAAOL,WAAW;IAAC;EACvB;AACJ","ignoreList":[]}
1
+ {"version":3,"file":"MSC3089Branch.js","names":["RelationType","UNSTABLE_MSC3089_BRANCH","EventTimeline","MSC3089Branch","constructor","client","indexEvent","directory","id","stateKey","getStateKey","Error","isActive","getContent","version","_this$indexEvent$getC","roomId","getRoomId","delete","_this","_asyncToGenerator","sendStateEvent","name","redactEvent","nextVersion","getVersionHistory","getName","setName","_this2","_objectSpread","isLocked","setLocked","locked","_this3","getFileInfo","_this4","event","getFileEvent","file","getOriginalContent","httpUrl","mxcUrlToHttp","concat","info","_this5","room","getRoom","getUnfilteredTimelineSet","findEventById","getLiveTimeline","getState","BACKWARDS","paginationToken","scrollback","createNewVersion","encryptedContents","additionalContent","_this6","fileEventResponse","createFile","rel_type","Replace","event_id","active","_this7","fileHistory","push","timelineEvents","getEvents","reverse","childEvent","parentEvent","find","e","replacingEventId","getId","branch","getFile"],"sources":["../../src/models/MSC3089Branch.ts"],"sourcesContent":["/*\nCopyright 2021 The Matrix.org Foundation C.I.C.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n*/\n\nimport { MatrixClient } from \"../client.ts\";\nimport { RelationType, UNSTABLE_MSC3089_BRANCH } from \"../@types/event.ts\";\nimport { IContent, MatrixEvent } from \"./event.ts\";\nimport { MSC3089TreeSpace } from \"./MSC3089TreeSpace.ts\";\nimport { EventTimeline } from \"./event-timeline.ts\";\nimport { FileType } from \"../http-api/index.ts\";\nimport type { ISendEventResponse } from \"../@types/requests.ts\";\nimport { EncryptedFile } from \"../@types/media.ts\";\n\nexport interface MSC3089EventContent {\n active?: boolean;\n name?: string;\n locked?: boolean;\n version?: number;\n}\n\nexport interface MSC3089EventContent {\n active?: boolean;\n name?: string;\n locked?: boolean;\n version?: number;\n}\n\n/**\n * Represents a [MSC3089](https://github.com/matrix-org/matrix-doc/pull/3089) branch - a reference\n * to a file (leaf) in the tree. Note that this is UNSTABLE and subject to breaking changes\n * without notice.\n */\nexport class MSC3089Branch {\n public constructor(\n private client: MatrixClient,\n public readonly indexEvent: MatrixEvent,\n public readonly directory: MSC3089TreeSpace,\n ) {\n // Nothing to do\n }\n\n /**\n * The file ID.\n */\n public get id(): string {\n const stateKey = this.indexEvent.getStateKey();\n if (!stateKey) {\n throw new Error(\"State key not found for branch\");\n }\n return stateKey;\n }\n\n /**\n * Whether this branch is active/valid.\n */\n public get isActive(): boolean {\n return this.indexEvent.getContent()[\"active\"] === true;\n }\n\n /**\n * Version for the file, one-indexed.\n */\n public get version(): number {\n return this.indexEvent.getContent()[\"version\"] ?? 1;\n }\n\n private get roomId(): string {\n return this.indexEvent.getRoomId()!;\n }\n\n /**\n * Deletes the file from the tree, including all prior edits/versions.\n * @returns Promise which resolves when complete.\n */\n public async delete(): Promise<void> {\n await this.client.sendStateEvent(this.roomId, UNSTABLE_MSC3089_BRANCH.name, {}, this.id);\n await this.client.redactEvent(this.roomId, this.id);\n\n const nextVersion = (await this.getVersionHistory())[1]; // [0] will be us\n if (nextVersion) await nextVersion.delete(); // implicit recursion\n }\n\n /**\n * Gets the name for this file.\n * @returns The name, or \"Unnamed File\" if unknown.\n */\n public getName(): string {\n return this.indexEvent.getContent()[\"name\"] || \"Unnamed File\";\n }\n\n /**\n * Sets the name for this file.\n * @param name - The new name for this file.\n * @returns Promise which resolves when complete.\n */\n public async setName(name: string): Promise<void> {\n await this.client.sendStateEvent(\n this.roomId,\n UNSTABLE_MSC3089_BRANCH.name,\n {\n ...this.indexEvent.getContent(),\n name: name,\n },\n this.id,\n );\n }\n\n /**\n * Gets whether or not a file is locked.\n * @returns True if locked, false otherwise.\n */\n public isLocked(): boolean {\n return this.indexEvent.getContent()[\"locked\"] || false;\n }\n\n /**\n * Sets a file as locked or unlocked.\n * @param locked - True to lock the file, false otherwise.\n * @returns Promise which resolves when complete.\n */\n public async setLocked(locked: boolean): Promise<void> {\n await this.client.sendStateEvent(\n this.roomId,\n UNSTABLE_MSC3089_BRANCH.name,\n {\n ...this.indexEvent.getContent(),\n locked: locked,\n },\n this.id,\n );\n }\n\n /**\n * Gets information about the file needed to download it.\n * @returns Information about the file.\n */\n public async getFileInfo(): Promise<{ info: EncryptedFile; httpUrl: string }> {\n const event = await this.getFileEvent();\n\n const file = event.getOriginalContent()[\"file\"];\n const httpUrl = this.client.mxcUrlToHttp(file[\"url\"]);\n\n if (!httpUrl) {\n throw new Error(`No HTTP URL available for ${file[\"url\"]}`);\n }\n\n return { info: file, httpUrl: httpUrl };\n }\n\n /**\n * Gets the event the file points to.\n * @returns Promise which resolves to the file's event.\n */\n public async getFileEvent(): Promise<MatrixEvent> {\n const room = this.client.getRoom(this.roomId);\n if (!room) throw new Error(\"Unknown room\");\n\n let event: MatrixEvent | undefined = room.getUnfilteredTimelineSet().findEventById(this.id);\n\n // keep scrolling back if needed until we find the event or reach the start of the room:\n while (!event && room.getLiveTimeline().getState(EventTimeline.BACKWARDS)!.paginationToken) {\n await this.client.scrollback(room, 100);\n event = room.getUnfilteredTimelineSet().findEventById(this.id);\n }\n\n if (!event) throw new Error(\"Failed to find event\");\n\n return event;\n }\n\n /**\n * Creates a new version of this file with contents in a type that is compatible with MatrixClient.uploadContent().\n * @param name - The name of the file.\n * @param encryptedContents - The encrypted contents.\n * @param info - The encrypted file information.\n * @param additionalContent - Optional event content fields to include in the message.\n * @returns Promise which resolves to the file event's sent response.\n */\n public async createNewVersion(\n name: string,\n encryptedContents: FileType,\n info: EncryptedFile,\n additionalContent?: IContent,\n ): Promise<ISendEventResponse> {\n const fileEventResponse = await this.directory.createFile(name, encryptedContents, info, {\n ...(additionalContent ?? {}),\n \"m.new_content\": true,\n \"m.relates_to\": {\n rel_type: RelationType.Replace,\n event_id: this.id,\n },\n });\n\n // Update the version of the new event\n await this.client.sendStateEvent(\n this.roomId,\n UNSTABLE_MSC3089_BRANCH.name,\n {\n active: true,\n name: name,\n version: this.version + 1,\n },\n fileEventResponse[\"event_id\"],\n );\n\n // Deprecate ourselves\n await this.client.sendStateEvent(\n this.roomId,\n UNSTABLE_MSC3089_BRANCH.name,\n {\n ...this.indexEvent.getContent(),\n active: false,\n },\n this.id,\n );\n\n return fileEventResponse;\n }\n\n /**\n * Gets the file's version history, starting at this file.\n * @returns Promise which resolves to the file's version history, with the\n * first element being the current version and the last element being the first version.\n */\n public async getVersionHistory(): Promise<MSC3089Branch[]> {\n const fileHistory: MSC3089Branch[] = [];\n fileHistory.push(this); // start with ourselves\n\n const room = this.client.getRoom(this.roomId);\n if (!room) throw new Error(\"Invalid or unknown room\");\n\n // Clone the timeline to reverse it, getting most-recent-first ordering, hopefully\n // shortening the awful loop below. Without the clone, we can unintentionally mutate\n // the timeline.\n const timelineEvents = [...room.getLiveTimeline().getEvents()].reverse();\n\n // XXX: This is a very inefficient search, but it's the best we can do with the\n // relations structure we have in the SDK. As of writing, it is not worth the\n // investment in improving the structure.\n let childEvent: MatrixEvent | undefined;\n let parentEvent = await this.getFileEvent();\n do {\n childEvent = timelineEvents.find((e) => e.replacingEventId() === parentEvent.getId());\n if (childEvent) {\n const branch = this.directory.getFile(childEvent.getId()!);\n if (branch) {\n fileHistory.push(branch);\n parentEvent = childEvent;\n } else {\n break; // prevent infinite loop\n }\n }\n } while (childEvent);\n\n return fileHistory;\n }\n}\n"],"mappings":";;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAGA,SAASA,YAAY,EAAEC,uBAAuB,QAAQ,oBAAoB;AAG1E,SAASC,aAAa,QAAQ,qBAAqB;AAmBnD;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,aAAa,CAAC;EAChBC,WAAWA,CAC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IAAMnB,IAAI,GAAGmB,MAAI,CAAC3D,MAAM,CAACyC,OAAO,CAACkB,MAAI,CAAChD,MAAM,CAAC;MAC7C,IAAI,CAAC6B,IAAI,EAAE,MAAM,IAAIlC,KAAK,CAAC,yBAAyB,CAAC;;MAErD;MACA;MACA;MACA,IAAMwD,cAAc,GAAG,CAAC,GAAGtB,IAAI,CAACI,eAAe,CAAC,CAAC,CAACmB,SAAS,CAAC,CAAC,CAAC,CAACC,OAAO,CAAC,CAAC;;MAExE;MACA;MACA;MACA,IAAIC,UAAmC;MACvC,IAAIC,WAAW,SAASP,MAAI,CAAC3B,YAAY,CAAC,CAAC;MAC3C,GAAG;QACCiC,UAAU,GAAGH,cAAc,CAACK,IAAI,CAAEC,CAAC,IAAKA,CAAC,CAACC,gBAAgB,CAAC,CAAC,KAAKH,WAAW,CAACI,KAAK,CAAC,CAAC,CAAC;QACrF,IAAIL,UAAU,EAAE;UACZ,IAAMM,MAAM,GAAGZ,MAAI,CAACzD,SAAS,CAACsE,OAAO,CAACP,UAAU,CAACK,KAAK,CAAC,CAAE,CAAC;UAC1D,IAAIC,MAAM,EAAE;YACRX,WAAW,CAACC,IAAI,CAACU,MAAM,CAAC;YACxBL,WAAW,GAAGD,UAAU;UAC5B,CAAC,MAAM;YACH,MAAM,CAAC;UACX;QACJ;MACJ,CAAC,QAAQA,UAAU;MAEnB,OAAOL,WAAW;IAAC;EACvB;AACJ","ignoreList":[]}
@@ -3,20 +3,16 @@
3
3
  * the public classes.
4
4
  */
5
5
  import { ExtensibleEvent, Optional } from "matrix-events-sdk";
6
- import { VerificationRequest } from "../crypto/verification/request/VerificationRequest.ts";
7
6
  import { EventType, MsgType, RelationType, UNSIGNED_THREAD_ID_FIELD } from "../@types/event.ts";
8
- import { Crypto } from "../crypto/index.ts";
9
7
  import { RoomMember } from "./room-member.ts";
10
8
  import { Thread, ThreadEvent, ThreadEventHandlerMap } from "./thread.ts";
11
9
  import { IActionsObject } from "../pushprocessor.ts";
12
10
  import { MatrixError } from "../http-api/index.ts";
13
11
  import { TypedEventEmitter } from "./typed-event-emitter.ts";
14
12
  import { EventStatus } from "./event-status.ts";
15
- import { CryptoBackend } from "../common-crypto/CryptoBackend.ts";
16
13
  import { IAnnotatedPushRule } from "../@types/PushRules.ts";
17
14
  import { Room } from "./room.ts";
18
15
  import { Membership } from "../@types/membership.ts";
19
- import { DecryptionFailureCode } from "../crypto-api/index.ts";
20
16
  export { EventStatus } from "./event-status.ts";
21
17
  export interface IContent {
22
18
  [key: string]: any;
@@ -195,14 +191,10 @@ export declare class MatrixEvent extends TypedEventEmitter<MatrixEventEmittedEve
195
191
  private visibility;
196
192
  private _hasCachedExtEv;
197
193
  private _cachedExtEv;
198
- /** If we failed to decrypt this event, the reason for the failure. Otherwise, `null`. */
199
- private _decryptionFailureReason;
200
194
  private senderCurve25519Key;
201
195
  private claimedEd25519Key;
202
196
  private forwardingCurve25519KeyChain;
203
197
  private untrusted;
204
- private decryptionPromise;
205
- private retryDecryption;
206
198
  private txnId?;
207
199
  /**
208
200
  * A reference to the thread this event belongs to
@@ -247,7 +239,6 @@ export declare class MatrixEvent extends TypedEventEmitter<MatrixEventEmittedEve
247
239
  * Should be read-only
248
240
  */
249
241
  forwardLooking: boolean;
250
- verificationRequest?: VerificationRequest;
251
242
  private readonly reEmitter;
252
243
  /**
253
244
  * Construct a Matrix Event object
@@ -411,74 +402,7 @@ export declare class MatrixEvent extends TypedEventEmitter<MatrixEventEmittedEve
411
402
  * not report it.
412
403
  */
413
404
  getMembershipAtEvent(): Optional<Membership | string>;
414
- /**
415
- * Replace the content of this event with encrypted versions.
416
- * (This is used when sending an event; it should not be used by applications).
417
- *
418
- * @internal
419
- *
420
- * @param cryptoType - type of the encrypted event - typically
421
- * <tt>"m.room.encrypted"</tt>
422
- *
423
- * @param cryptoContent - raw 'content' for the encrypted event.
424
- *
425
- * @param senderCurve25519Key - curve25519 key to record for the
426
- * sender of this event.
427
- * See {@link MatrixEvent#getSenderKey}.
428
- *
429
- * @param claimedEd25519Key - claimed ed25519 key to record for the
430
- * sender if this event.
431
- * See {@link MatrixEvent#getClaimedEd25519Key}
432
- */
433
- makeEncrypted(cryptoType: string, cryptoContent: object, senderCurve25519Key: string, claimedEd25519Key: string): void;
434
- /**
435
- * Check if this event is currently being decrypted.
436
- *
437
- * @returns True if this event is currently being decrypted, else false.
438
- */
439
- isBeingDecrypted(): boolean;
440
- getDecryptionPromise(): Promise<void> | null;
441
- /**
442
- * Check if this event is an encrypted event which we failed to decrypt
443
- *
444
- * (This implies that we might retry decryption at some point in the future)
445
- *
446
- * @returns True if this event is an encrypted event which we
447
- * couldn't decrypt.
448
- */
449
- isDecryptionFailure(): boolean;
450
- /** If we failed to decrypt this event, the reason for the failure. Otherwise, `null`. */
451
- get decryptionFailureReason(): DecryptionFailureCode | null;
452
- /**
453
- * True if this event is an encrypted event which we failed to decrypt, the receiver's device is unverified and
454
- * the sender has disabled encrypting to unverified devices.
455
- *
456
- * @deprecated: Prefer `event.decryptionFailureReason === DecryptionFailureCode.MEGOLM_KEY_WITHHELD_FOR_UNVERIFIED_DEVICE`.
457
- */
458
- get isEncryptedDisabledForUnverifiedDevices(): boolean;
459
405
  shouldAttemptDecryption(): boolean;
460
- /**
461
- * Start the process of trying to decrypt this event.
462
- *
463
- * (This is used within the SDK: it isn't intended for use by applications)
464
- *
465
- * @internal
466
- *
467
- * @param crypto - crypto module
468
- *
469
- * @returns promise which resolves (to undefined) when the decryption
470
- * attempt is completed.
471
- */
472
- attemptDecryption(crypto: CryptoBackend, options?: IDecryptOptions): Promise<void>;
473
- /**
474
- * Cancel any room key request for this event and resend another.
475
- *
476
- * @param crypto - crypto module
477
- * @param userId - the user who received this event
478
- *
479
- * @returns a promise that resolves when the request is queued
480
- */
481
- cancelAndResendKeyRequest(crypto: Crypto, userId: string): Promise<void>;
482
406
  /**
483
407
  * Calculate the recipients for keyshare requests.
484
408
  *
@@ -487,23 +411,6 @@ export declare class MatrixEvent extends TypedEventEmitter<MatrixEventEmittedEve
487
411
  * @returns array of recipients
488
412
  */
489
413
  getKeyRequestRecipients(userId: string): IKeyRequestRecipient[];
490
- private decryptionLoop;
491
- /**
492
- * Update the cleartext data on this event.
493
- *
494
- * (This is used after decrypting an event; it should not be used by applications).
495
- *
496
- * @internal
497
- *
498
- * @param decryptionResult - the decryption result, including the plaintext and some key info
499
- */
500
- private setClearData;
501
- /**
502
- * Update the cleartext data on this event after a decryption failure.
503
- *
504
- * @param reason - the textual reason for the failure
505
- */
506
- private setClearDataForDecryptionFailure;
507
414
  /**
508
415
  * Gets the cleartext content for this event. If the event is not encrypted,
509
416
  * or encryption has not been completed, this will return null.
@@ -794,7 +701,6 @@ export declare class MatrixEvent extends TypedEventEmitter<MatrixEventEmittedEve
794
701
  * In any case, the value it returns is not a faithful serialization of the object.
795
702
  */
796
703
  toJSON(): object;
797
- setVerificationRequest(request: VerificationRequest): void;
798
704
  setTxnId(txnId: string): void;
799
705
  getTxnId(): string | undefined;
800
706
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"event.d.ts","sourceRoot":"","sources":["../../src/models/event.ts"],"names":[],"mappings":"AAgBA;;;GAGG;AAEH,OAAO,EAAE,eAAe,EAAoB,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAIhF,OAAO,EAAE,mBAAmB,EAAE,MAAM,uDAAuD,CAAC;AAC5F,OAAO,EAEH,SAAS,EACT,OAAO,EACP,YAAY,EAEZ,wBAAwB,EAE3B,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAE5C,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAC9C,OAAO,EAAE,MAAM,EAAwB,WAAW,EAAE,qBAAqB,EAAE,MAAM,aAAa,CAAC;AAC/F,OAAO,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AAErD,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AACnD,OAAO,EAAE,iBAAiB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