k2-im 0.2.15 → 0.2.17

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 (58) hide show
  1. package/dist/chat-kit-pinia.d.ts +77 -18
  2. package/dist/chat-kit-vue.d.ts +7 -5
  3. package/dist/chat-kit.d.ts +138 -23
  4. package/dist/index.d.ts +142 -26
  5. package/dist/modules/api-protocol-client/src/client.js +1 -1
  6. package/dist/modules/api-protocol-client/src/nonce.js +1 -1
  7. package/dist/modules/crypto/browser.js +1 -1
  8. package/dist/modules/crypto/driver.js +1 -1
  9. package/dist/modules/crypto/vendor/crypto/index_bg.js +1 -1
  10. package/dist/modules/im-browser/src/http/cm-http-adapter.js +1 -1
  11. package/dist/modules/im-browser/src/http/request-timeout.js +1 -0
  12. package/dist/modules/im-browser/src/http/requests/core-json-request.js +1 -1
  13. package/dist/modules/im-browser/src/http/requests/get-conversation-background-presets.js +1 -1
  14. package/dist/modules/im-browser/src/http/requests/pull-offline-channel.js +1 -1
  15. package/dist/modules/im-browser/src/http/session-favorite-http-adapter.js +1 -1
  16. package/dist/modules/im-browser/src/media/media-download-request.js +1 -0
  17. package/dist/modules/im-browser/src/media/media-downloader.js +1 -1
  18. package/dist/modules/im-browser/src/media/media-preview-adapter.js +1 -1
  19. package/dist/modules/im-browser/src/media/media-preview-preparation-executor.js +1 -1
  20. package/dist/modules/im-browser/src/media/media-transfer-adapter.js +1 -1
  21. package/dist/modules/im-browser/src/media/media-transfer-policy.js +1 -1
  22. package/dist/modules/im-browser/src/media/webp-encoder.js +1 -0
  23. package/dist/modules/im-browser/src/media/webp-worker-factory.js +1 -0
  24. package/dist/modules/im-browser/src/network/browser-connection-ownership.js +1 -1
  25. package/dist/modules/im-browser/src/storage/indexed-db-storage-adapter.js +1 -1
  26. package/dist/modules/im-chat-kit/src/pinia/composer.store.js +1 -1
  27. package/dist/modules/im-chat-kit/src/pinia/expression.store.js +1 -1
  28. package/dist/modules/im-chat-kit/src/runtime/chat-runtime.js +1 -1
  29. package/dist/modules/im-chat-kit/src/runtime/media-object-url-registry.js +1 -1
  30. package/dist/modules/im-chat-kit/src/services/media.service.js +1 -1
  31. package/dist/modules/im-chat-kit/src/utils/emoji/unicode.js +1 -1
  32. package/dist/modules/im-chat-kit/src/utils/media-transfer-presentation.js +1 -1
  33. package/dist/modules/im-chat-kit/src/vue/thread/thread-visibility-target-group.js +1 -1
  34. package/dist/modules/im-chat-kit/src/vue/thread/thread-visibility-targets.js +1 -1
  35. package/dist/modules/im-core/src/abort.js +1 -1
  36. package/dist/modules/im-core/src/mapping/group-offline-mapper.js +1 -1
  37. package/dist/modules/im-core/src/mapping/message-id.js +1 -1
  38. package/dist/modules/im-core/src/media-thumbnail-policy.js +1 -1
  39. package/dist/modules/im-core/src/media-thumbnail.js +1 -1
  40. package/dist/modules/im-core/src/message-flow/media/media-sender.js +1 -1
  41. package/dist/modules/im-core/src/state/domain-state.js +1 -1
  42. package/dist/modules/im-sdk/src/create-im-client.js +1 -1
  43. package/dist/modules/im-sdk/src/product/conversation-handle.js +1 -1
  44. package/dist/modules/im-sdk/src/product/diagnostic-memory-buffer.js +1 -1
  45. package/dist/modules/im-sdk/src/product/media.js +1 -1
  46. package/dist/modules/im-sdk/src/runtime/history-page-size.js +1 -0
  47. package/dist/modules/im-sdk/src/runtime/local-media-preview.js +1 -1
  48. package/dist/modules/im-sdk/src/runtime/recent-history-fetcher.js +1 -1
  49. package/dist/modules/im-sdk/src/runtime/recent-history-prefetch.js +1 -1
  50. package/dist/modules/im-sdk/src/runtime/session-runtime.js +1 -1
  51. package/dist/request-crypto.d.ts +3 -2
  52. package/dist/sdk.d.ts +75 -21
  53. package/dist/vendor/crypto/index_bg.wasm +0 -0
  54. package/dist/vendor/webp/LICENSE.jsquash +201 -0
  55. package/dist/vendor/webp/LICENSE.libwebp +29 -0
  56. package/dist/vendor/webp/NOTICE +3 -0
  57. package/dist/webp.worker.js +3 -0
  58. package/package.json +1 -1
@@ -22,8 +22,9 @@ interface CryptoDriver {
22
22
  * 加载页面请求共用的 WASM 加解密实例。
23
23
  *
24
24
  * 此入口只依赖请求 crypto,不加载 IM 客户端、Chat Kit 或框架。普通业务可在首个请求前
25
- * await 一次并保留返回的同步 driver;后续 IM Core 请求复用同一实例。导入入口本身不
26
- * 请求 WASM,Node/SSR 可以安全解析它;加载失败会向调用方传播。
25
+ * await 一次并保留返回的同步 driver;后续 IM Core 请求复用健康实例。RuntimeError 后
26
+ * 可以再次 await 本入口等待异步重建,driver 身份不变,不重试失败操作。导入入口本身
27
+ * 不请求 WASM,Node/SSR 可以安全解析它;加载或重建失败会向调用方传播。
27
28
  */
28
29
  declare function loadBrowserCryptoDriver(): Promise<CryptoDriver>;
29
30
 
package/dist/sdk.d.ts CHANGED
@@ -2326,12 +2326,12 @@ interface ReactionParentMessage {
2326
2326
  declare function canReactToMessage(message: ReactionParentMessage): boolean;
2327
2327
 
2328
2328
  /**
2329
- * 根据缩略图签名选择 PNG 或 JPEG 的显示类型,供 SDK 和 PC/H5 创建 Blob、data URL。
2330
- * 输入是消息中的原始字节或纯 base64;旧消息没有独立 MIME 字段,非 PNG 沿用 JPEG 解码,
2329
+ * 根据缩略图签名选择 PNG、WebP 或 JPEG 的显示类型,供 SDK 和 PC/H5 创建 Blob、data URL。
2330
+ * 输入是消息中的原始字节或纯 base64;旧消息没有独立 MIME 字段,未知格式沿用 JPEG 解码,
2331
2331
  * 损坏数据仍交给图片解码器报告失败。本函数不修改字节,也不将历史 JPEG 转码为 PNG。
2332
2332
  * @example resolveMediaThumbnailMimeType(new Uint8Array([137, 80, 78, 71, 13, 10, 26, 10])) // 'image/png'
2333
2333
  */
2334
- declare function resolveMediaThumbnailMimeType(source: Uint8Array | string): 'image/png' | 'image/jpeg';
2334
+ declare function resolveMediaThumbnailMimeType(source: Uint8Array | string): 'image/png' | 'image/webp' | 'image/jpeg';
2335
2335
 
2336
2336
  /** 浏览器 PushSubscription.toJSON() 的可移植数据;不依赖 DOM 或浏览器全局。 */
2337
2337
  interface ImWebPushSubscription {
@@ -2553,13 +2553,13 @@ interface MediaTransferAdapterConfig {
2553
2553
  useAccelerateEndpoint?: boolean;
2554
2554
  /**
2555
2555
  * 统一允许 S3 分片上传和 Range 分段下载,默认 false(单次 PUT / 普通 GET)。
2556
- * 显式 true 后仍按 16MiB 阈值及已确认下载大小选择策略,小资源不分片。
2556
+ * 显式 true 后,上传对象达到 8 MiB 使用 Multipart;上传片长与下载段长均为 16 MiB。
2557
2557
  * 开启前各桶须支持分片请求方法,并暴露上传 ETag、下载 Content-Range 与强 ETag。
2558
2558
  * @example { multipartTransfer: true } 同时允许大资源分片上传、下载。
2559
2559
  */
2560
2560
  multipartTransfer?: boolean;
2561
2561
  /**
2562
- * 总开关开启后,是否允许超过分片阈值(16MiB)的上传使用 S3 分片上传。
2562
+ * 总开关开启后,是否允许达到分片阈值(8 MiB)的上传使用 S3 分片上传。
2563
2563
  *
2564
2564
  * 分片相比单次 PUT 需要各物理桶的 CORS 额外放行 POST(Create/CompleteMultipartUpload)、
2565
2565
  * DELETE(AbortMultipartUpload)并 `ExposeHeaders: ETag`;未配齐时分片会直接失败。
@@ -2575,8 +2575,8 @@ interface MediaTransferAdapterConfig {
2575
2575
  /**
2576
2576
  * 媒体发送阶段的并发上限;由 im-core 消费,限制媒体任务数而非分片请求数。
2577
2577
  *
2578
- * 并发按媒体体积分两档:不超过分片阈值(16 MiB)的非视频媒体走小文件档,
2579
- * 缺省 5;视频与超过阈值(或字节数未知)的内容走大文件档,缺省 3。
2578
+ * 并发按媒体体积分两档:小于分片阈值(8 MiB)的非视频媒体走小文件档,
2579
+ * 缺省 5;视频与达到阈值(或字节数未知)的内容走大文件档,缺省 3。
2580
2580
  * 分档只限制媒体任务数;实际 PUT/UploadPart 另受 adapter 的六路数据请求限制。
2581
2581
  * 两档都只接受 1-6 的整数,超出范围由 core 显式报错。
2582
2582
  * - 传一个数字:所有媒体共用这一个并发数,与分档前的语义一致。
@@ -2603,11 +2603,12 @@ interface MediaTransferAdapterConfig {
2603
2603
  * - `multipart-etag-missing`:分片响应读不到 ETag,**桶 CORS 缺 `ExposeHeaders: ETag`**,不是网络问题。
2604
2604
  * - `multipart-abort-failed`:分片失败后的 `AbortMultipartUpload` 清理本身失败,已上传分片可能残留并计费。
2605
2605
  * - `multipart-upload-failed`:分片上传因其它原因失败;`cause` 保留原始错误,消息列出分片对 CORS 的额外要求。
2606
+ * - `download-timeout`:下载连续 30 秒无新数据,或单次 GET 超过 30 分钟。
2606
2607
  * - `download-range-invalid`:分段状态、范围、长度或可读响应头不符合合同。
2607
2608
  * - `download-object-changed`:分段之间的强 ETag 或总长度改变,拒绝混合不同文件版本。
2608
2609
  * - `download-range-failed`:下载返回非成功 HTTP 状态。
2609
2610
  */
2610
- type MediaTransferErrorCode = 'upload-timeout' | 'bucket-unconfigured' | 'credentials-provider-missing' | 'credentials-request-failed' | 'credentials-invalid' | 'upload-source-invalid' | 'upload-size-exceeded' | 'upload-resume-unavailable' | 'multipart-etag-missing' | 'multipart-abort-failed' | 'multipart-upload-failed' | 'download-range-invalid' | 'download-object-changed' | 'download-range-failed';
2611
+ type MediaTransferErrorCode = 'upload-timeout' | 'bucket-unconfigured' | 'credentials-provider-missing' | 'credentials-request-failed' | 'credentials-invalid' | 'upload-source-invalid' | 'upload-size-exceeded' | 'upload-resume-unavailable' | 'multipart-etag-missing' | 'multipart-abort-failed' | 'multipart-upload-failed' | 'download-timeout' | 'download-range-invalid' | 'download-object-changed' | 'download-range-failed';
2611
2612
  /** 媒体传输统一错误:携带稳定业务码 + 可选底层 cause(诊断用,永不携带凭证明文)。 */
2612
2613
  declare class MediaTransferError extends Error {
2613
2614
  readonly code: MediaTransferErrorCode;
@@ -3029,13 +3030,13 @@ interface MediaAlbumMessageOptions {
3029
3030
  * 本地视频的固有尺寸、时长与首帧封面。
3030
3031
  *
3031
3032
  * @remarks 宿主可从本地 object URL 解码首个可展示帧,使上传占位从首次渲染就使用真实比例和主图。
3032
- * `posterData` 是等比缩放后的 JPEG(兼容已有 PNG);存在时会作为消息 `thumbData` 随正文发送。宽高必须是有限正数,
3033
+ * `posterData` 是等比缩放后的静态 WebP(兼容已有 JPEG/PNG);存在时会作为消息 `thumbData` 随正文发送。宽高必须是有限正数,
3033
3034
  * duration 存在时必须是有限正数,posterData 必须是非空且不超过共享单项消息容量的 Uint8Array;合集发送会按项数复核容量。
3034
3035
  */
3035
3036
  interface VideoPreviewMetadata extends ImagePreviewMetadata {
3036
3037
  /** 秒。 */
3037
3038
  duration?: number;
3038
- /** 本地首个可展示帧生成的 JPEG 或已有 PNG 字节。 */
3039
+ /** 本地首个可展示帧生成的 WebP 或已有 JPEG/PNG 字节。 */
3039
3040
  posterData?: Uint8Array;
3040
3041
  }
3041
3042
  /**
@@ -5109,6 +5110,17 @@ interface ImMessageRef {
5109
5110
  */
5110
5111
  itemIndex?: number;
5111
5112
  }
5113
+ /** 单次媒体下载的等待与调度选项;相同精确消息引用仍共用一次实际下载。 */
5114
+ interface ImMediaDownloadOptions {
5115
+ /**
5116
+ * 只取消本次调用;其它调用者仍需要结果时保留共享下载。
5117
+ * 最后一个可取消调用者退出且没有无 signal 调用者时,才中止底层任务。
5118
+ * 取消以 IM_SDK_MEDIA_DOWNLOAD_CANCELED 拒绝本次 Promise,不返回部分文件。
5119
+ */
5120
+ signal?: AbortSignal;
5121
+ /** 默认 interactive;background 在空闲名额中排在交互下载之后,不能抢占已发请求。 */
5122
+ priority?: 'background' | 'interactive';
5123
+ }
5112
5124
  /**
5113
5125
  * 可观察媒体上传/下载任务的只读产品投影。
5114
5126
  *
@@ -5207,7 +5219,8 @@ interface ImMediaTasksApi {
5207
5219
  */
5208
5220
  subscribe: (listener: (tasks: readonly ImMediaTask[]) => void) => () => void;
5209
5221
  /**
5210
- * 取消 queued/running 任务;上传委托 core,下载中止当前 AbortController。
5222
+ * 取消 queued/running 任务;上传委托 core,下载中止共享任务并取消所有调用者。
5223
+ * 只需结束某次下载等待时,应使用 download 的 signal。
5211
5224
  * @throws 未知任务、非法状态或底层未受理时以稳定 `IM_SDK_MEDIA_TASK_*` 错误拒绝。
5212
5225
  */
5213
5226
  cancel: (taskId: string, options?: {
@@ -5242,10 +5255,13 @@ interface ImMediaTasksApi {
5242
5255
  restartDownload?: boolean;
5243
5256
  }) => Promise<void>;
5244
5257
  /**
5245
- * 下载并按消息正文合同解密,同一消息并发调用复用同一 Promise,成功返回 Blob。
5258
+ * 下载并按消息正文合同解密,同一精确消息引用共用实际下载,成功返回 Blob。
5259
+ * 不带 signal 的并发调用保留共享 Promise;带 signal 的调用独立等待和取消,不影响其它调用者。
5260
+ * 后加入的交互调用会提高共享下载优先级;prioritizeDownload 指定的最近预览仍优先于其它任务。
5246
5261
  * @throws 消息不存在/非媒体/无远端 URL/未装配 capability、传输失败、取消或 teardown 均以稳定错误拒绝,不返回空 Blob。
5262
+ * @example const blob = await client.media.download(messageRef, { signal: controller.signal, priority: 'background' })
5247
5263
  */
5248
- download: (message: ImMessageRef) => Promise<Blob>;
5264
+ download: (message: ImMessageRef, options?: ImMediaDownloadOptions) => Promise<Blob>;
5249
5265
  /**
5250
5266
  * 将最近预览的精确媒体项设为最高下载优先级,不新建或取消任务。
5251
5267
  * 下一空闲任务/分片请求名额优先给该项;已发请求不中断,关闭播放器不撤销优先级。
@@ -5261,7 +5277,7 @@ interface ImMediaTasksApi {
5261
5277
  */
5262
5278
  getCached: (message: ImMessageRef) => Promise<Blob | null>;
5263
5279
  /**
5264
- * 为宿主手里的**本地**图片/视频文件预读展示元信息:尺寸、视频时长、视频首帧封面的 JPEG 字节。
5280
+ * 为宿主手里的**本地**图片/视频文件预读展示元信息:尺寸、视频时长、视频首帧封面的 WebP 字节。
5265
5281
  *
5266
5282
  * 给「发送前预览」这类场景用:宿主要在用户还没点发送时就把缩略图画出来,而浏览器读不出视频的
5267
5283
  * 首帧——`<video preload="metadata">` 在 iOS Safari 上只加载元信息、**不解码任何一帧**,
@@ -5269,7 +5285,7 @@ interface ImMediaTasksApi {
5269
5285
  *
5270
5286
  * 返回的对象可以**原样**作为 `localPreviewMetadata` 交给 `sendImage` / `sendVideo` /
5271
5287
  * `sendMediaAlbum`:发送链路会复用可用元信息;合集项超出其可用消息空间时重新生成封面。
5272
- * posterData 使用共享自适应发送规格(视频 JPEG,长边最多 960px,目标 8 KiB、硬上限 24 KiB);includeDisplayPoster 可在同一次解码中额外生成
5288
+ * posterData 使用共享自适应发送规格(视频 WebP,长边最多 1440px,目标 16 KiB、硬上限 32 KiB);includeDisplayPoster 可在同一次解码中额外生成
5273
5289
  * 仅供页面显示的高清 displayPoster(长边最多 960),不得绕过发送校验直接用它替换 posterData。
5274
5290
  *
5275
5291
  * @param input.kind 按文件类型选解码路径;`'video'` 才会抽首帧与读时长。
@@ -5289,16 +5305,26 @@ interface ImMediaTasksApi {
5289
5305
  includeDisplayPoster?: boolean;
5290
5306
  }) => Promise<(TKind extends 'video' ? LocalVideoPreviewMetadata : ImagePreviewMetadata) | null>;
5291
5307
  /**
5292
- * 从本地视频提取仅供页面展示的高清 JPEG 封面,不上传、不下载、不写缓存。
5308
+ * 从本地视频或已有截图生成气泡封面;传入消息身份时复用独立持久缓存,不下载或上传。
5293
5309
  *
5294
5310
  * 长边最多 960px 且不放大原视频;与发送预读共用同一解码执行器。返回 Blob 由宿主创建和释放
5295
5311
  * object URL,不能作为 localPreviewMetadata 发进消息正文。读取失败返回 null 并记录诊断;
5296
5312
  * 宿主取消抛 AbortError,运行时失效或未装配能力时抛与 prepareLocalPreview 相同的明确错误。
5297
- * @param input.file 本地或已解密的完整视频 Blob。
5313
+ * @param input.file 本地或已解密的完整视频 Blob;已有 poster 时可以不传。
5314
+ * @param input.poster 发送前已经提取的截图,避免重新加载视频抽帧。
5315
+ * @param input.message 可选消息身份,用于持久保存封面。
5316
+ * @param input.expectedResourceUrl 取得源文件前的资源地址,防止换图后的旧结果污染缓存。
5298
5317
  * @param input.signal 页面卸载、换源或切会话时取消这次抽帧。
5299
5318
  */
5300
5319
  prepareLocalVideoPoster: (input: {
5301
- file: Blob;
5320
+ file?: Blob;
5321
+ poster?: Blob;
5322
+ message?: ImMessageRef;
5323
+ expectedResourceUrl?: string;
5324
+ signal?: AbortSignal;
5325
+ }) => Promise<Blob | null>;
5326
+ /** 只读视频气泡封面缓存;不下载、不抽帧,未命中返回 null。 */
5327
+ getCachedVideoPoster: (message: ImMessageRef, options?: {
5302
5328
  signal?: AbortSignal;
5303
5329
  }) => Promise<Blob | null>;
5304
5330
  /**
@@ -5314,6 +5340,34 @@ interface ImMediaTasksApi {
5314
5340
  file: Blob;
5315
5341
  signal?: AbortSignal;
5316
5342
  }) => Promise<Blob | null>;
5343
+ /**
5344
+ * 从本机原图生成独立的静态显示图,供 PC/H5 气泡使用;不下载、不上传、不改原图与消息尺寸。
5345
+ * 传入消息引用时先查独立的显示图缓存;稳定远端资源的结果可持久保存,本地待上传资源只生成。
5346
+ * 所有浏览器可解码格式均处理;最长边不超过 maxSize 且不放大,透明图优先保留透明度。
5347
+ * WebP 质量 0.85,最低 0.82,目标 256 KiB、最多 512 KiB;超过字节预算时可继续缩小,失败返回 null 并记录诊断。
5348
+ * 取消、账号失效、能力缺失和非法参数明确拒绝;返回 Blob 的 object URL 由宿主管理。
5349
+ * @param input.file 原始或已解密的完整图片 Blob,不会被修改。
5350
+ * @param input.maxSize 显示图最长边上限,必须是 1 到 2048 的整数。
5351
+ * @param input.signal 页面退出、资源失效时取消准备。
5352
+ * @param input.message 可选的精确消息引用,用于按消息、合集项、资源版本和尺寸隔离显示图缓存。
5353
+ * @param input.expectedResourceUrl 取得 file 前记录的消息资源地址;与 message 配合使用,不匹配时返回 null,防止旧文件写入新资源缓存。
5354
+ * @example const display = await client.media.prepareLocalImageDisplay({ file: original, maxSize: 1440 })
5355
+ */
5356
+ prepareLocalImageDisplay: (input: {
5357
+ file: Blob;
5358
+ maxSize: number;
5359
+ message?: ImMessageRef;
5360
+ expectedResourceUrl?: string;
5361
+ signal?: AbortSignal;
5362
+ }) => Promise<Blob | null>;
5363
+ /**
5364
+ * 仅读取指定消息和尺寸的持久显示图,不下载原图、不编码;未命中或读取期间资源失效返回 null。
5365
+ * maxSize 必须是 1 到 2048 的整数;取消、账号失效、存储读取失败明确拒绝。
5366
+ */
5367
+ getCachedImageDisplay: (message: ImMessageRef, options: {
5368
+ maxSize: number;
5369
+ signal?: AbortSignal;
5370
+ }) => Promise<Blob | null>;
5317
5371
  }
5318
5372
 
5319
5373
  /**
@@ -6017,7 +6071,7 @@ declare function resolveImEmojiToken(token: string): ImEmojiCatalogEntry | undef
6017
6071
  * 1 小时、按服务端过期时间提前 5 分钟失效)、同桶并发请求复用和失败后重新签发由 SDK 负责,宿主只需提供「打一次接口」的纯函数。
6018
6072
  *
6019
6073
  * 默认单次 PUT/GET;仅 multipartTransfer=true 才允许大资源分片上传、下载。
6020
- * 各 bucket 需在对象存储侧配置 CORS 允许本站 origin 的 PUT + GET;开启分片后,超过 16MiB 的上传另需放行
6074
+ * 各 bucket 需在对象存储侧配置 CORS 允许本站 origin 的 PUT + GET;开启分片后,达到 8 MiB 的上传另需放行
6021
6075
  * POST(Create/CompleteMultipartUpload)、DELETE(AbortMultipartUpload)并 ExposeHeaders: ETag。CORS 未配齐时
6022
6076
  * 下载还需暴露 Content-Range 与强 ETag;multipartTransfer=false 统一关闭分片上传和下载。
6023
6077
  * ⚠ 并发字段只由 SDK core 的媒体编排消费;adapter 会忽略该字段。高内存设备可设置 5-6,低内存设备建议 2-3。
@@ -6626,7 +6680,7 @@ interface ImResourceUploadResult {
6626
6680
  /** 独立资源上传器;不创建消息、Outbox 项或 client.media 任务。 */
6627
6681
  interface ImResourceUploader {
6628
6682
  /**
6629
- * 上传原始文件。默认单次 PUT;multipartTransfer=true 且 >16 MiB 才允许分片,沿用既有凭证刷新策略。
6683
+ * 上传原始文件。默认单次 PUT;multipartTransfer=true 且 ≥8 MiB 才允许分片,沿用既有凭证刷新策略。
6630
6684
  * 失败会清理未完成分片并保留错误,显式重试须再次调用 upload;不会退回旧 HTTP 上传接口。
6631
6685
  * @throws 取消为 AbortError;若取消后的分片清理失败,仍报告 multipart-abort-failed。
6632
6686
  * 配置、凭证、S3 或清理失败直接拒绝;dispose 后不可再使用。
@@ -6659,4 +6713,4 @@ interface ImResourceUploader {
6659
6713
  declare function createImResourceUploader(config: ImResourceUploaderConfig): ImResourceUploader;
6660
6714
 
6661
6715
  export { EDIT_WINDOW_MS, IMAGE_MESSAGE_ACCEPT, IM_CHAT_FONT_SCALES, IM_DIAGNOSTIC_CATEGORIES, IM_EMOJI_CATALOG, ImPinnedMessageOperationError, MEDIA_ALBUM_CAPTION_MAX_LENGTH, MEDIA_ALBUM_MAX_ITEMS, MediaTransferError, REACTION_SUPPORTED_CONTENT_TYPES, buildSessionFavoritePlainBody, canReactToMessage, canTransmit, canTransmitByType, canTransmitContent, classifyStickerImageType, createFaceToFaceGroupQrPayload, createImClient, createImConsoleDiagnosticSink, createImDiagnosticMemoryBuffer, createImResourceUploader, createImTextSearchMatcher, createSdkDiagnosticWriter, createVoicePlayer, createVoiceRecordingSession, detectVoiceCapabilities, extractSearchText, getImTextSearchInitial, isSupportedImageFile, mediaTransferErrorCodeOf, migrateImCachePrefix, normalizeMediaUploadCredentials, parseSessionFavoriteAlbumItems, parseSessionFavoriteFileItems, requiresForwardTypeConfirmation, resolveChannelAccess, resolveImEmojiToken, resolveMediaAlbumSendContentType, resolveMediaThumbnailMimeType, resolveSessionFavoriteAlbumCaption, resolveSessionFavoriteAlbumItemPreviewUrl, resolveSessionFavoriteKindFromMessage, resolveTextSegments, sortSessions, sumSessionsUnread, voiceErrorCodeOf };
6662
- export type { CapabilityAvailability, CapabilityDecision, CapabilityReason, ChannelAccessSnapshot, ChannelBaseSessionState, ChannelConversationCapabilities, ChannelConversationMessageApi, ChannelJoinApplication, ChannelJoinApplicationNotification, ChannelJoinApplicationPage, ChannelMember, ChannelMemberPage, ChannelMentionMember, ChannelMentionMemberPage, ChannelMiniProgramRel, ChannelMiniProgramRelConfigType, ChannelMuteReason, ChannelPermissionSet, ChannelProfile, ChannelRole, ChannelSessionState, ContactCardInput, ContactMessageOptions, ConversationBackgroundPreset, ConversationBackgroundSelection, ConversationCapabilitySnapshot, ConversationDraft, ConversationDraftApi, ConversationEntryUnreadNavigation, ConversationEntryUnreadSnapshot, ConversationHandle, ConversationHandleSnapshot, ConversationInitialPosition, ConversationLastMessageSummary, ConversationListItem, ConversationListMention, ConversationMessageApi, ConversationOpenOptions, ConversationPrefetchOptions, ConversationPrefetchResult, ConversationRef, ConversationSearchPage, ConversationSearchResult, ConversationSystemSummary, ConversationType, CustomerServiceConversationCapabilities, DirectConversationCapabilities, DirectConversationMessageApi, DraftInput, EditTextOptions, ExpressionMessageOptions, FileMessageOptions, ForwardFailReason, ForwardItemStatus, ForwardMessageFailure, ForwardMessagesInput, ForwardMessagesResult, ForwardTarget, ForwardedMessageRef, GameMessageOptions, GifMessageOptions, GiftMessageOptions, GroupConversationCapabilities, GroupConversationMessageApi, GroupMemberItem, GroupProfile, ImAppearanceSettingsApi, ImApplicationItem, ImApplicationRef, ImApplicationsApi, ImAuthIssue, ImAuthProvider, ImBlockedContact, ImCacheOptions, ImCachePrefixMigrationContext, ImCachePrefixMigrator, ImCallKind, ImCallOutcome, ImCallRecordBody, ImChannelConversationAccessSnapshot, ImChannelMentionApi, ImChannelMiniProgramRel, ImChannelPermissions, ImChannelPinnedMessage, ImChannelProfile, ImChannelRole, ImChannelState, ImChannelsApi, ImChatFontScale, ImClientActivityApi, ImClientActivitySnapshot, ImClientOptions, ImConnectionState, ImContactBody, ImContactKind, ImContactProfile, ImContactRelationship, ImContactRemarkPhone, ImContactSearchResult, ImContactsApi, ImConversationBackgroundApi, ImConversationCapabilitiesApi, ImConversationListApi, ImConversationListSnapshot, ImConversationListState, ImConversationSearchApi, ImCoreApiOptions, ImCreateChannelInput, ImCreateChannelResult, ImCreateFaceToFaceGroupResult, ImCreateGroupInput, ImCreateGroupResult, ImCreatedChannel, ImCreatedGroup, ImCustomerServiceApi, ImDebugOptions, ImDiagnosticCategory, ImDiagnosticError, ImDiagnosticLayer, ImDiagnosticLevel, ImDiagnosticMemoryBuffer, ImDiagnosticMemoryBufferFilter, ImDiagnosticMemoryBufferOptions, ImDiagnosticMemoryBufferSnapshot, ImDiagnosticMessage, ImDiagnosticRecord, ImDiagnosticSink, ImDiagnosticWriter, ImDirectCallAnswerResult, ImDirectCallFailReason, ImDirectCallHangupInput, ImDirectCallHangupReason, ImDirectCallInviteInput, ImDirectCallNotifyAudioInput, ImDirectCallTargetInput, ImDirectCallsApi, ImDirectReadReceiptSettings, ImDirectoryApi, ImDirectoryFieldMatch, ImDirectoryItem, ImDirectoryKind, ImDirectoryPage, ImDirectorySearchApi, ImDirectorySearchItem, ImDirectorySearchResult, ImDraftsApi, ImEmojiCatalogEntry, ImEndpointProvider, ImEventsApi, ImExpressionAsset, ImExpressionAssetInput, ImExpressionEmojiRecentInput, ImExpressionFavoriteKind, ImExpressionOptions, ImExpressionRecentInput, ImExpressionRecentItem, ImExpressionRecentItemKind, ImExpressionsApi, ImFaceToFaceGroup, ImFileBody, ImFilesAlbumBody, ImFriendshipRequestResult, ImGameBody, ImGameType, ImGifAssetInput, ImGiftBody, ImGiftSessionType, ImGiftStatus, ImGiftType, ImGiphyAsset, ImGiphyPage, ImGiphyPageOptions, ImGroupCallAnswerInput, ImGroupCallBusyInput, ImGroupCallCreateInput, ImGroupCallJoinInput, ImGroupCallMeetingSnapshot, ImGroupCallMember, ImGroupCallMemberStatus, ImGroupCallStatusInput, ImGroupCallTargetInput, ImGroupCallsApi, ImGroupConversationState, ImGroupMentionApi, ImGroupPinnedMessage, ImGroupProfile, ImGroupsApi, ImImageBody, ImLifecycleSnapshot, ImLiveRoomBody, ImLiveRoomStatus, ImLiveRoomType, ImLocalDataApi, ImLocalDataInfo, ImLogoutOptions, ImMediaAlbumBody, ImMediaAlbumItem, ImMediaConfig, ImMediaTask, ImMediaTasksApi, ImMembershipJoinResult, ImMessageMention, ImMessageReactionAggregate, ImMessageReactions, ImMessageRef, ImMessageSearchApi, ImMessageView, ImMessageViewBody, ImMessagesByIdResult, ImMiniProgramBody, ImMiniProgramShowType, ImOutboxApi, ImOutboxItem, ImPageToken, ImPinnedMessageErrorKind, ImPinnedMessageOperation, ImProductApplicationUpdate, ImProductAuthInvalidReason, ImProductClient, ImProductEvent, ImProductEventError, ImProductEventMap, ImProductMessage, ImPushApi, ImPushSnapshot, ImReactionChangeAction, ImReactionChangeResult, ImReadReceiptSettingsApi, ImRedPacketBody, ImRedPacketType, ImRequestError, ImRequestErrorHandler, ImResourceKind, ImResourceUploadInput, ImResourceUploadProgress, ImResourceUploadResult, ImResourceUploader, ImResourceUploaderConfig, ImRobotBody, ImRobotChatMenuItem, ImRobotCommand, ImRobotConversationBindInput, ImRobotDirectoryItem, ImRobotDirectoryPage, ImRobotDirectoryScope, ImRobotMenuReplyInput, ImRobotModule, ImRobotProfile, ImRobotProfileInput, ImRobotsApi, ImSdkErrorCategory, ImSdkErrorShape, ImSearchApi, ImSessionApi, ImSessionFavoriteAlbumItem, ImSessionFavoriteFileItem, ImSessionFavoriteItem, ImSessionFavoriteKind, ImSessionFavoritesApi, ImSessionLifecycleState, ImSettingsApi, ImStickerAssetInput, ImStickerBody, ImStickerPack, ImSupportedConversationRef, ImTextSearchMatch, ImTextSearchMatchOptions, ImTextSearchMatcher, ImTextSearchRange, ImTransferBody, ImTransferSessionType, ImTransferStatus, ImVideoBody, ImVoiceBody, ImWebPushSubscription, ImageMessageOptions, ImagePreviewMetadata, LiveRoomMessageOptions, LocalConversationHistoryClearResult, LocalMessageDeletionResult, LocalVideoPreviewMetadata, MediaAlbumItemInput, MediaAlbumMessageOptions, MediaTransferErrorCode, MediaUploadCredentials, MediaUploadCredentialsProvider, MediaUploadCredentialsRequest, MentionCandidate, MentionCandidatePage, MentionInput, MessageContentType, MessageWindowInfo, MessageWindowPage, MessagesByIdFailure, MigrateImCachePrefixInput, MiniProgramMessageOptions, ProductConversationListType, ProductHandleConversationType, ProductMessageSearchPage, ProductMessageSearchPreviewPart, ProductMessageSearchResult, ResolveTextOptions, ResolvedConversationBackground, RobotConversationCapabilities, SegmentMatch, SegmentMatcher, SendMessageResult, StickerAssetKind, TextMessageOptions, TextSegment, TransferMessageOptions, UnknownMessageBody, UserProfile, VideoMessageOptions, VideoPreviewMetadata, VoiceCapabilities, VoiceErrorCode, VoiceMessageMetadata, VoicePlayer, VoicePlayerOptions, VoicePlayerState, VoiceRecordingResult, VoiceRecordingSession, VoiceRecordingSessionOptions, VoiceRecordingState, VoiceToggleOptions };
6716
+ export type { CapabilityAvailability, CapabilityDecision, CapabilityReason, ChannelAccessSnapshot, ChannelBaseSessionState, ChannelConversationCapabilities, ChannelConversationMessageApi, ChannelJoinApplication, ChannelJoinApplicationNotification, ChannelJoinApplicationPage, ChannelMember, ChannelMemberPage, ChannelMentionMember, ChannelMentionMemberPage, ChannelMiniProgramRel, ChannelMiniProgramRelConfigType, ChannelMuteReason, ChannelPermissionSet, ChannelProfile, ChannelRole, ChannelSessionState, ContactCardInput, ContactMessageOptions, ConversationBackgroundPreset, ConversationBackgroundSelection, ConversationCapabilitySnapshot, ConversationDraft, ConversationDraftApi, ConversationEntryUnreadNavigation, ConversationEntryUnreadSnapshot, ConversationHandle, ConversationHandleSnapshot, ConversationInitialPosition, ConversationLastMessageSummary, ConversationListItem, ConversationListMention, ConversationMessageApi, ConversationOpenOptions, ConversationPrefetchOptions, ConversationPrefetchResult, ConversationRef, ConversationSearchPage, ConversationSearchResult, ConversationSystemSummary, ConversationType, CustomerServiceConversationCapabilities, DirectConversationCapabilities, DirectConversationMessageApi, DraftInput, EditTextOptions, ExpressionMessageOptions, FileMessageOptions, ForwardFailReason, ForwardItemStatus, ForwardMessageFailure, ForwardMessagesInput, ForwardMessagesResult, ForwardTarget, ForwardedMessageRef, GameMessageOptions, GifMessageOptions, GiftMessageOptions, GroupConversationCapabilities, GroupConversationMessageApi, GroupMemberItem, GroupProfile, ImAppearanceSettingsApi, ImApplicationItem, ImApplicationRef, ImApplicationsApi, ImAuthIssue, ImAuthProvider, ImBlockedContact, ImCacheOptions, ImCachePrefixMigrationContext, ImCachePrefixMigrator, ImCallKind, ImCallOutcome, ImCallRecordBody, ImChannelConversationAccessSnapshot, ImChannelMentionApi, ImChannelMiniProgramRel, ImChannelPermissions, ImChannelPinnedMessage, ImChannelProfile, ImChannelRole, ImChannelState, ImChannelsApi, ImChatFontScale, ImClientActivityApi, ImClientActivitySnapshot, ImClientOptions, ImConnectionState, ImContactBody, ImContactKind, ImContactProfile, ImContactRelationship, ImContactRemarkPhone, ImContactSearchResult, ImContactsApi, ImConversationBackgroundApi, ImConversationCapabilitiesApi, ImConversationListApi, ImConversationListSnapshot, ImConversationListState, ImConversationSearchApi, ImCoreApiOptions, ImCreateChannelInput, ImCreateChannelResult, ImCreateFaceToFaceGroupResult, ImCreateGroupInput, ImCreateGroupResult, ImCreatedChannel, ImCreatedGroup, ImCustomerServiceApi, ImDebugOptions, ImDiagnosticCategory, ImDiagnosticError, ImDiagnosticLayer, ImDiagnosticLevel, ImDiagnosticMemoryBuffer, ImDiagnosticMemoryBufferFilter, ImDiagnosticMemoryBufferOptions, ImDiagnosticMemoryBufferSnapshot, ImDiagnosticMessage, ImDiagnosticRecord, ImDiagnosticSink, ImDiagnosticWriter, ImDirectCallAnswerResult, ImDirectCallFailReason, ImDirectCallHangupInput, ImDirectCallHangupReason, ImDirectCallInviteInput, ImDirectCallNotifyAudioInput, ImDirectCallTargetInput, ImDirectCallsApi, ImDirectReadReceiptSettings, ImDirectoryApi, ImDirectoryFieldMatch, ImDirectoryItem, ImDirectoryKind, ImDirectoryPage, ImDirectorySearchApi, ImDirectorySearchItem, ImDirectorySearchResult, ImDraftsApi, ImEmojiCatalogEntry, ImEndpointProvider, ImEventsApi, ImExpressionAsset, ImExpressionAssetInput, ImExpressionEmojiRecentInput, ImExpressionFavoriteKind, ImExpressionOptions, ImExpressionRecentInput, ImExpressionRecentItem, ImExpressionRecentItemKind, ImExpressionsApi, ImFaceToFaceGroup, ImFileBody, ImFilesAlbumBody, ImFriendshipRequestResult, ImGameBody, ImGameType, ImGifAssetInput, ImGiftBody, ImGiftSessionType, ImGiftStatus, ImGiftType, ImGiphyAsset, ImGiphyPage, ImGiphyPageOptions, ImGroupCallAnswerInput, ImGroupCallBusyInput, ImGroupCallCreateInput, ImGroupCallJoinInput, ImGroupCallMeetingSnapshot, ImGroupCallMember, ImGroupCallMemberStatus, ImGroupCallStatusInput, ImGroupCallTargetInput, ImGroupCallsApi, ImGroupConversationState, ImGroupMentionApi, ImGroupPinnedMessage, ImGroupProfile, ImGroupsApi, ImImageBody, ImLifecycleSnapshot, ImLiveRoomBody, ImLiveRoomStatus, ImLiveRoomType, ImLocalDataApi, ImLocalDataInfo, ImLogoutOptions, ImMediaAlbumBody, ImMediaAlbumItem, ImMediaConfig, ImMediaDownloadOptions, ImMediaTask, ImMediaTasksApi, ImMembershipJoinResult, ImMessageMention, ImMessageReactionAggregate, ImMessageReactions, ImMessageRef, ImMessageSearchApi, ImMessageView, ImMessageViewBody, ImMessagesByIdResult, ImMiniProgramBody, ImMiniProgramShowType, ImOutboxApi, ImOutboxItem, ImPageToken, ImPinnedMessageErrorKind, ImPinnedMessageOperation, ImProductApplicationUpdate, ImProductAuthInvalidReason, ImProductClient, ImProductEvent, ImProductEventError, ImProductEventMap, ImProductMessage, ImPushApi, ImPushSnapshot, ImReactionChangeAction, ImReactionChangeResult, ImReadReceiptSettingsApi, ImRedPacketBody, ImRedPacketType, ImRequestError, ImRequestErrorHandler, ImResourceKind, ImResourceUploadInput, ImResourceUploadProgress, ImResourceUploadResult, ImResourceUploader, ImResourceUploaderConfig, ImRobotBody, ImRobotChatMenuItem, ImRobotCommand, ImRobotConversationBindInput, ImRobotDirectoryItem, ImRobotDirectoryPage, ImRobotDirectoryScope, ImRobotMenuReplyInput, ImRobotModule, ImRobotProfile, ImRobotProfileInput, ImRobotsApi, ImSdkErrorCategory, ImSdkErrorShape, ImSearchApi, ImSessionApi, ImSessionFavoriteAlbumItem, ImSessionFavoriteFileItem, ImSessionFavoriteItem, ImSessionFavoriteKind, ImSessionFavoritesApi, ImSessionLifecycleState, ImSettingsApi, ImStickerAssetInput, ImStickerBody, ImStickerPack, ImSupportedConversationRef, ImTextSearchMatch, ImTextSearchMatchOptions, ImTextSearchMatcher, ImTextSearchRange, ImTransferBody, ImTransferSessionType, ImTransferStatus, ImVideoBody, ImVoiceBody, ImWebPushSubscription, ImageMessageOptions, ImagePreviewMetadata, LiveRoomMessageOptions, LocalConversationHistoryClearResult, LocalMessageDeletionResult, LocalVideoPreviewMetadata, MediaAlbumItemInput, MediaAlbumMessageOptions, MediaTransferErrorCode, MediaUploadCredentials, MediaUploadCredentialsProvider, MediaUploadCredentialsRequest, MentionCandidate, MentionCandidatePage, MentionInput, MessageContentType, MessageWindowInfo, MessageWindowPage, MessagesByIdFailure, MigrateImCachePrefixInput, MiniProgramMessageOptions, ProductConversationListType, ProductHandleConversationType, ProductMessageSearchPage, ProductMessageSearchPreviewPart, ProductMessageSearchResult, ResolveTextOptions, ResolvedConversationBackground, RobotConversationCapabilities, SegmentMatch, SegmentMatcher, SendMessageResult, StickerAssetKind, TextMessageOptions, TextSegment, TransferMessageOptions, UnknownMessageBody, UserProfile, VideoMessageOptions, VideoPreviewMetadata, VoiceCapabilities, VoiceErrorCode, VoiceMessageMetadata, VoicePlayer, VoicePlayerOptions, VoicePlayerState, VoiceRecordingResult, VoiceRecordingSession, VoiceRecordingSessionOptions, VoiceRecordingState, VoiceToggleOptions };
Binary file
@@ -0,0 +1,201 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding those notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for reasonable and customary use in describing the
141
+ origin of the Work and reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may choose to offer,
167
+ and charge a fee for, acceptance of support, warranty, indemnity,
168
+ or other liability obligations and/or rights consistent with this
169
+ License. However, in accepting such obligations, You may act only
170
+ on Your own behalf and on Your sole responsibility, not on behalf
171
+ of any other Contributor, and only if You agree to indemnify,
172
+ defend, and hold each Contributor harmless for any liability
173
+ incurred by, or claims asserted against, such Contributor by reason
174
+ of your accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
177
+
178
+ APPENDIX: How to apply the Apache License to your work.
179
+
180
+ To apply the Apache License to your work, attach the following
181
+ boilerplate notice, with the fields enclosed by brackets "[]"
182
+ replaced with your own identifying information. (Don't include
183
+ the brackets!) The text should be enclosed in the appropriate
184
+ comment syntax for the file format. We also recommend that a
185
+ file or class name and description of purpose be included on the
186
+ same "printed page" as the copyright notice for easier
187
+ identification within third-party archives.
188
+
189
+ Copyright [2023] jamsinclair
190
+
191
+ Licensed under the Apache License, Version 2.0 (the "License");
192
+ you may not use this file except in compliance with the License.
193
+ You may obtain a copy of the License at
194
+
195
+ http://www.apache.org/licenses/LICENSE-2.0
196
+
197
+ Unless required by applicable law or agreed to in writing, software
198
+ distributed under the License is distributed on an "AS IS" BASIS,
199
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
200
+ See the License for the specific language governing permissions and
201
+ limitations under the License.
@@ -0,0 +1,29 @@
1
+ Copyright (c) 2010, Google Inc. All rights reserved.
2
+
3
+ Redistribution and use in source and binary forms, with or without
4
+ modification, are permitted provided that the following conditions are
5
+ met:
6
+
7
+ * Redistributions of source code must retain the above copyright
8
+ notice, this list of conditions and the following disclaimer.
9
+
10
+ * Redistributions in binary form must reproduce the above copyright
11
+ notice, this list of conditions and the following disclaimer in
12
+ the documentation and/or other materials provided with the
13
+ distribution.
14
+
15
+ * Neither the name of Google nor the names of its contributors may
16
+ be used to endorse or promote products derived from this software
17
+ without specific prior written permission.
18
+
19
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
20
+ "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
21
+ LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
22
+ A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
23
+ HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
24
+ SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
25
+ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
26
+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
27
+ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
28
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
29
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
@@ -0,0 +1,3 @@
1
+ Copyright 2020 Google Inc. All Rights Reserved.
2
+ WebP encoder: @jsquash/webp 1.5.0, derived from Google Squoosh, with modifications by Jamie Sinclair (Apache-2.0); wasm-feature-detect (Apache-2.0); libwebp (BSD).
3
+ The Dedicated Worker build removes Node/ServiceWorker environment branches and resolves module URLs against the worker location.