k2-im 0.1.38 → 0.1.39
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.
- package/dist/browser.js +1 -1
- package/dist/chat-kit-pinia.d.ts +131 -81
- package/dist/chat-kit-pinia.js +1 -1
- package/dist/chat-kit-vue.d.ts +4 -2
- package/dist/chat-kit-vue.js +1 -1
- package/dist/chat-kit.d.ts +200 -142
- package/dist/chat-kit.js +1 -1
- package/dist/chunk-2EB5ZELD.js +1 -0
- package/dist/chunk-54HSPG2Z.js +2 -0
- package/dist/chunk-5KHSKIN3.js +2 -0
- package/dist/{chunk-GHFHAGJ7.js → chunk-A5WA7S7J.js} +1 -1
- package/dist/{chunk-HWA7NOXG.js → chunk-I7RLO6MT.js} +1 -1
- package/dist/{chunk-ZERTVCH2.js → chunk-SRMSBFOP.js} +1 -1
- package/dist/chunk-WISC6Q2S.js +2 -0
- package/dist/i18n.js +1 -1
- package/dist/index.d.ts +185 -142
- package/dist/index.js +1 -1
- package/dist/sdk.d.ts +27 -3
- package/dist/sdk.js +1 -1
- package/package.json +1 -1
- package/dist/chunk-3ST5E6YS.js +0 -1
- package/dist/chunk-4I23ADH2.js +0 -2
- package/dist/chunk-ITOAFWZU.js +0 -2
- package/dist/chunk-LMP34HNC.js +0 -2
package/dist/browser.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{Ta as canCopyImageToClipboard,Ua as copyImageToClipboard,B as createLazyBrowserApiProtocolClient}from'./chunk-
|
|
1
|
+
export{Ta as canCopyImageToClipboard,Ua as copyImageToClipboard,B as createLazyBrowserApiProtocolClient}from'./chunk-SRMSBFOP.js';import'./chunk-54HSPG2Z.js';import'./chunk-WOT6VMZA.js';
|
package/dist/chat-kit-pinia.d.ts
CHANGED
|
@@ -2437,6 +2437,11 @@ type ImEvent = {
|
|
|
2437
2437
|
| {
|
|
2438
2438
|
type: 'receiving:changed';
|
|
2439
2439
|
receiving: boolean;
|
|
2440
|
+
}
|
|
2441
|
+
/** 全局会话与离线消息同步;不包含当前会话的打开或历史分页。 */
|
|
2442
|
+
| {
|
|
2443
|
+
type: 'syncing:changed';
|
|
2444
|
+
syncing: boolean;
|
|
2440
2445
|
} | {
|
|
2441
2446
|
type: 'auth:invalid';
|
|
2442
2447
|
issue: ImAuthIssue;
|
|
@@ -3919,6 +3924,8 @@ interface ImLifecycleSnapshot {
|
|
|
3919
3924
|
authenticated: boolean;
|
|
3920
3925
|
/** 会话同步或前台内容读取仍在进行;不包含后台预取、媒体下载和写操作,也不代表同步成功。 */
|
|
3921
3926
|
receiving: boolean;
|
|
3927
|
+
/** 全局会话与离线消息同步仍在进行;前台会话读取由 receiving 和窗口 loading 表示。 */
|
|
3928
|
+
syncing: boolean;
|
|
3922
3929
|
}
|
|
3923
3930
|
/** logout 的本地数据与在途消息策略。 */
|
|
3924
3931
|
interface ImLogoutOptions {
|
|
@@ -5089,8 +5096,10 @@ interface ConversationHandle<TType extends ProductHandleConversationType = Produ
|
|
|
5089
5096
|
resolveMessage: (messageId: string) => Promise<ImMessageView | null>;
|
|
5090
5097
|
history: {
|
|
5091
5098
|
loadLatest: () => Promise<void>;
|
|
5092
|
-
/**
|
|
5093
|
-
loadEntryUnread: (
|
|
5099
|
+
/** 读取进入时冻结边界;signal 取消会停止查询且不替换窗口,可重新发起。不可定位返回 false,失败抛错。 */
|
|
5100
|
+
loadEntryUnread: (options?: {
|
|
5101
|
+
signal?: AbortSignal;
|
|
5102
|
+
}) => Promise<boolean>;
|
|
5094
5103
|
loadOlder: () => Promise<void>;
|
|
5095
5104
|
/** 历史定位窗口向更新方向连续翻页;接回最新端后 `hasNewer` 变为 false。 */
|
|
5096
5105
|
loadNewer: () => Promise<void>;
|
|
@@ -5562,6 +5571,10 @@ interface ImProductEventMap {
|
|
|
5562
5571
|
'receiving:changed': Readonly<{
|
|
5563
5572
|
receiving: boolean;
|
|
5564
5573
|
}>;
|
|
5574
|
+
/** 全局同步所有支路的汇总状态;不包含打开会话、历史分页或后台预取。 */
|
|
5575
|
+
'syncing:changed': Readonly<{
|
|
5576
|
+
syncing: boolean;
|
|
5577
|
+
}>;
|
|
5565
5578
|
/** `lastLoginTime` 为服务端记录的上次登录时间(毫秒),仅被踢且走登录 ACK 的路径才有值。 */
|
|
5566
5579
|
'auth:invalid': Readonly<{
|
|
5567
5580
|
code: string;
|
|
@@ -5878,7 +5891,18 @@ interface ProductMessageSearchResult<TContent extends MessageContentType = Messa
|
|
|
5878
5891
|
createdAt: number;
|
|
5879
5892
|
contentType: TContent;
|
|
5880
5893
|
preview: string;
|
|
5894
|
+
/** 展示用片段;正文/配文携带提及信息,文件名等业务字段保持普通文本。拼接后与 preview 相同。 */
|
|
5895
|
+
previewParts: readonly ProductMessageSearchPreviewPart[];
|
|
5881
5896
|
}
|
|
5897
|
+
/** 搜索摘要的最小内容投影;不携带完整消息、媒体资源或协议字段。 */
|
|
5898
|
+
type ProductMessageSearchPreviewPart = {
|
|
5899
|
+
kind: 'plain';
|
|
5900
|
+
text: string;
|
|
5901
|
+
} | {
|
|
5902
|
+
kind: 'rich-text';
|
|
5903
|
+
text: string;
|
|
5904
|
+
mention?: ImMessageMention;
|
|
5905
|
+
};
|
|
5882
5906
|
/** 产品消息搜索页;底层 `beforeSortKey` 仅存在于账号 runtime token registry。 */
|
|
5883
5907
|
interface ProductMessageSearchPage<TContent extends MessageContentType = MessageContentType> {
|
|
5884
5908
|
items: readonly ProductMessageSearchResult<TContent>[];
|
|
@@ -9034,6 +9058,96 @@ type ImReactionStore = Store<'k2-im-reaction', ImReactionStoreState, Record<stri
|
|
|
9034
9058
|
/** 取得当前 Vue setup 或显式 Pinia 的 Reaction Store;不持有菜单、Toast 或 Reaction 领域快照。 */
|
|
9035
9059
|
declare function useImReactionStore(pinia?: Pinia): ImReactionStore;
|
|
9036
9060
|
|
|
9061
|
+
/**
|
|
9062
|
+
* 为聊天主区域管理唯一一个“用户当前正在查看的消息线程”。
|
|
9063
|
+
*
|
|
9064
|
+
* 【页面得到什么】
|
|
9065
|
+
* Store 用 SDK 会话句柄打开一个明确的单聊、普通群或社群,并把该线程的一次完整更新转换成
|
|
9066
|
+
* `activeRef`、消息列表、已保存草稿、加载/就绪/过期状态、能否继续向前后翻页和错误。消息与草稿仍由
|
|
9067
|
+
* SDK 和本机存储维护;只供资料页使用的隐藏系统消息不会显示在聊天时间线,但原数据不会被删除。
|
|
9068
|
+
*
|
|
9069
|
+
* 【提供的能力】
|
|
9070
|
+
* - `open` / `close`:打开或关闭当前会话;打开新会话会停止旧会话页面订阅。
|
|
9071
|
+
* - `closeActiveConversation`:只关闭精确活动会话,保留正在打开的其他会话意图。
|
|
9072
|
+
* - `loadLatest` / `loadOlder` / `loadNewer`:加载最新一屏、向上翻更早消息或向下补更新消息。
|
|
9073
|
+
* - `loadAround`:为搜索定位加载目标消息附近窗口。
|
|
9074
|
+
* - `resolveMessage`:解析当前窗口之外但属于同一会话的本地消息。
|
|
9075
|
+
* - `retainHandle`:让已经开始的发送或上传在用户切会话后仍能安全完成,再关闭旧句柄。
|
|
9076
|
+
* - `reset` / `dispose`:切账号或销毁时作废订阅、分页结果并关闭全部会话句柄。
|
|
9077
|
+
*
|
|
9078
|
+
* 【并发与资源所有权】
|
|
9079
|
+
* 同一 Store 同时只有一个活动会话句柄。异步结果必须同时匹配最新操作序号、当前账号版本号、当前句柄
|
|
9080
|
+
* 和会话类型 + ID 才能更新页面;同 ID 的不同会话类型不会串线。句柄、订阅函数和“仍在使用”计数只在
|
|
9081
|
+
* 闭包中,不进入 `$state`。
|
|
9082
|
+
*
|
|
9083
|
+
* 【明确不负责】
|
|
9084
|
+
* Composer 输入、消息菜单、多选、DOM 滚动、路由和 toast 分别由其他共享 Store 或宿主平台层负责。
|
|
9085
|
+
*/
|
|
9086
|
+
|
|
9087
|
+
type ProductConversationHandle = ConversationHandle<ProductHandleConversationType>;
|
|
9088
|
+
/** Thread Store 中由 Pinia 管理的当前窗口投影;句柄、订阅和租约留在闭包中。 */
|
|
9089
|
+
interface ImThreadStoreState {
|
|
9090
|
+
activeRef: ConversationRef<ProductHandleConversationType> | null;
|
|
9091
|
+
/** SDK 已校验的活动聊天展示资料;不依赖该聊天是否已进入会话列表。 */
|
|
9092
|
+
display: ConversationHandleSnapshot['display'] | null;
|
|
9093
|
+
messages: readonly ImMessageView[];
|
|
9094
|
+
entryUnread: ConversationEntryUnreadSnapshot;
|
|
9095
|
+
/** 本次进入前的数量与定位状态;列表清零后仍保留。 */
|
|
9096
|
+
entryUnreadNavigation: ConversationHandleSnapshot['entryUnreadNavigation'];
|
|
9097
|
+
draft: ConversationDraft | null;
|
|
9098
|
+
loading: boolean;
|
|
9099
|
+
ready: boolean;
|
|
9100
|
+
stale: boolean;
|
|
9101
|
+
hasOlder: boolean;
|
|
9102
|
+
hasNewer: boolean;
|
|
9103
|
+
error: ImSdkErrorShape | null;
|
|
9104
|
+
/** 当前活动会话待 Surface 消费的实时对端消息版本。 */
|
|
9105
|
+
activeRemoteMessageRevision: number;
|
|
9106
|
+
}
|
|
9107
|
+
/** Thread Store 的稳定公共动作;DOM 滚动、路由和反馈仍由宿主负责。 */
|
|
9108
|
+
interface ImThreadStoreActions {
|
|
9109
|
+
open: (ref: ConversationRef<ProductHandleConversationType>) => Promise<ProductConversationHandle | undefined>;
|
|
9110
|
+
invalidatePendingOpen: () => void;
|
|
9111
|
+
loadLatest: () => Promise<boolean>;
|
|
9112
|
+
/** 读取本次进入时冻结的首未读窗口;signal 取消时不替换当前窗口。 */
|
|
9113
|
+
loadEntryUnread: (options?: {
|
|
9114
|
+
signal?: AbortSignal;
|
|
9115
|
+
}) => Promise<boolean>;
|
|
9116
|
+
/** 页面确认可阅读后结算整会话;不会自动扩大可见消息回执。 */
|
|
9117
|
+
markConversationRead: () => Promise<void>;
|
|
9118
|
+
/** 只上报当前线程实际显示的消息集合。 */
|
|
9119
|
+
markVisibleMessages: (messageIds: readonly string[]) => Promise<void>;
|
|
9120
|
+
/** 明确业务离开;账号销毁和页面卸载仍使用无副作用的 close/reset。 */
|
|
9121
|
+
leave: () => void;
|
|
9122
|
+
loadOlder: () => Promise<boolean>;
|
|
9123
|
+
loadNewer: () => Promise<boolean>;
|
|
9124
|
+
loadAround: (messageId: string) => Promise<boolean>;
|
|
9125
|
+
resolveMessage: (messageId: string) => Promise<ImMessageView | null>;
|
|
9126
|
+
retainHandle: (handle?: ProductConversationHandle) => () => void;
|
|
9127
|
+
retainCurrentHandle: () => () => void;
|
|
9128
|
+
close: () => void;
|
|
9129
|
+
closeActiveConversation: (ref: ConversationRef<ProductHandleConversationType>) => boolean;
|
|
9130
|
+
reset: () => void;
|
|
9131
|
+
dispose: () => void;
|
|
9132
|
+
getHandle: () => ProductConversationHandle | undefined;
|
|
9133
|
+
/** 原子取走当前活动会话尚未被 Surface 消费的实时对端消息 id。 */
|
|
9134
|
+
drainActiveRemoteMessageIds: () => readonly string[];
|
|
9135
|
+
}
|
|
9136
|
+
/** 宿主从 `useImThreadStore` 获得的完整 Pinia Store 公共类型。 */
|
|
9137
|
+
type ImThreadStore = Store<'k2-im-thread', ImThreadStoreState, Record<string, never>, ImThreadStoreActions>;
|
|
9138
|
+
/** 取得当前 Vue setup 或显式 Pinia 的消息线程 Store;每个实例只管理一个当前会话。 */
|
|
9139
|
+
declare function useImThreadStore(pinia?: Pinia): ImThreadStore;
|
|
9140
|
+
|
|
9141
|
+
/** 搜索行的发送者投影;非 ready 状态不提供伪造姓名,由宿主翻译状态文案。 */
|
|
9142
|
+
interface ImSearchSenderPresentation {
|
|
9143
|
+
/** ready 表示已有名称;self/system 由宿主翻译;其余状态明确区分等待、缺失和请求失败。 */
|
|
9144
|
+
status: 'ready' | 'self' | 'system' | 'loading' | 'unavailable' | 'failed';
|
|
9145
|
+
/** 仅使用资料中的真实名称;没有名称时为空,数字昵称仍原样保留。 */
|
|
9146
|
+
name: string;
|
|
9147
|
+
/** 来自同一份共享资料缓存;缺失头像时为空。 */
|
|
9148
|
+
avatarUrl: string;
|
|
9149
|
+
}
|
|
9150
|
+
|
|
9037
9151
|
/**
|
|
9038
9152
|
* 读取当前会话的消息搜索结果和分类媒体列表。
|
|
9039
9153
|
*
|
|
@@ -9063,6 +9177,9 @@ type ImSearchOperationResult = Readonly<{
|
|
|
9063
9177
|
declare function defineImSearchStore(pinia: Pinia): pinia.StoreDefinition<"k2-im-search", Pick<{
|
|
9064
9178
|
keyword: any;
|
|
9065
9179
|
results: any;
|
|
9180
|
+
senderFor: (row: ProductMessageSearchResult) => ImSearchSenderPresentation;
|
|
9181
|
+
hasRetryableSenderProfiles: any;
|
|
9182
|
+
retrySenderProfiles: () => Promise<void>;
|
|
9066
9183
|
searching: any;
|
|
9067
9184
|
hasMore: any;
|
|
9068
9185
|
category: any;
|
|
@@ -9082,6 +9199,9 @@ declare function defineImSearchStore(pinia: Pinia): pinia.StoreDefinition<"k2-im
|
|
|
9082
9199
|
}, any>, Pick<{
|
|
9083
9200
|
keyword: any;
|
|
9084
9201
|
results: any;
|
|
9202
|
+
senderFor: (row: ProductMessageSearchResult) => ImSearchSenderPresentation;
|
|
9203
|
+
hasRetryableSenderProfiles: any;
|
|
9204
|
+
retrySenderProfiles: () => Promise<void>;
|
|
9085
9205
|
searching: any;
|
|
9086
9206
|
hasMore: any;
|
|
9087
9207
|
category: any;
|
|
@@ -9101,6 +9221,9 @@ declare function defineImSearchStore(pinia: Pinia): pinia.StoreDefinition<"k2-im
|
|
|
9101
9221
|
}, any>, Pick<{
|
|
9102
9222
|
keyword: any;
|
|
9103
9223
|
results: any;
|
|
9224
|
+
senderFor: (row: ProductMessageSearchResult) => ImSearchSenderPresentation;
|
|
9225
|
+
hasRetryableSenderProfiles: any;
|
|
9226
|
+
retrySenderProfiles: () => Promise<void>;
|
|
9104
9227
|
searching: any;
|
|
9105
9228
|
hasMore: any;
|
|
9106
9229
|
category: any;
|
|
@@ -9186,6 +9309,8 @@ interface ImSessionStore {
|
|
|
9186
9309
|
readonly connectionState: ImConnectionState;
|
|
9187
9310
|
/** SDK 正在同步会话、离线消息或读取前台会话内容;连接异常提示仍应优先展示。 */
|
|
9188
9311
|
readonly receiving: boolean;
|
|
9312
|
+
/** SDK 全局会话与离线消息同步;列表标题使用此状态,避免前台读取引起闪动。 */
|
|
9313
|
+
readonly syncing: boolean;
|
|
9189
9314
|
readonly generation: number;
|
|
9190
9315
|
readonly phase: ImSessionPhase;
|
|
9191
9316
|
readonly errorKey: string;
|
|
@@ -9203,6 +9328,7 @@ declare function defineImSessionStore(pinia: Pinia): pinia.StoreDefinition<"k2-i
|
|
|
9203
9328
|
accountId: any;
|
|
9204
9329
|
connectionState: any;
|
|
9205
9330
|
receiving: any;
|
|
9331
|
+
syncing: any;
|
|
9206
9332
|
generation: any;
|
|
9207
9333
|
phase: any;
|
|
9208
9334
|
errorKey: any;
|
|
@@ -9220,6 +9346,7 @@ declare function defineImSessionStore(pinia: Pinia): pinia.StoreDefinition<"k2-i
|
|
|
9220
9346
|
accountId: any;
|
|
9221
9347
|
connectionState: any;
|
|
9222
9348
|
receiving: any;
|
|
9349
|
+
syncing: any;
|
|
9223
9350
|
generation: any;
|
|
9224
9351
|
phase: any;
|
|
9225
9352
|
errorKey: any;
|
|
@@ -9237,6 +9364,7 @@ declare function defineImSessionStore(pinia: Pinia): pinia.StoreDefinition<"k2-i
|
|
|
9237
9364
|
accountId: any;
|
|
9238
9365
|
connectionState: any;
|
|
9239
9366
|
receiving: any;
|
|
9367
|
+
syncing: any;
|
|
9240
9368
|
generation: any;
|
|
9241
9369
|
phase: any;
|
|
9242
9370
|
errorKey: any;
|
|
@@ -9303,84 +9431,6 @@ interface ImThreadReturnToLatestCoordinator {
|
|
|
9303
9431
|
*/
|
|
9304
9432
|
declare function useImThreadReturnToLatestCoordinator(pinia?: Pinia): ImThreadReturnToLatestCoordinator;
|
|
9305
9433
|
|
|
9306
|
-
/**
|
|
9307
|
-
* 为聊天主区域管理唯一一个“用户当前正在查看的消息线程”。
|
|
9308
|
-
*
|
|
9309
|
-
* 【页面得到什么】
|
|
9310
|
-
* Store 用 SDK 会话句柄打开一个明确的单聊、普通群或社群,并把该线程的一次完整更新转换成
|
|
9311
|
-
* `activeRef`、消息列表、已保存草稿、加载/就绪/过期状态、能否继续向前后翻页和错误。消息与草稿仍由
|
|
9312
|
-
* SDK 和本机存储维护;只供资料页使用的隐藏系统消息不会显示在聊天时间线,但原数据不会被删除。
|
|
9313
|
-
*
|
|
9314
|
-
* 【提供的能力】
|
|
9315
|
-
* - `open` / `close`:打开或关闭当前会话;打开新会话会停止旧会话页面订阅。
|
|
9316
|
-
* - `closeActiveConversation`:只关闭精确活动会话,保留正在打开的其他会话意图。
|
|
9317
|
-
* - `loadLatest` / `loadOlder` / `loadNewer`:加载最新一屏、向上翻更早消息或向下补更新消息。
|
|
9318
|
-
* - `loadAround`:为搜索定位加载目标消息附近窗口。
|
|
9319
|
-
* - `resolveMessage`:解析当前窗口之外但属于同一会话的本地消息。
|
|
9320
|
-
* - `retainHandle`:让已经开始的发送或上传在用户切会话后仍能安全完成,再关闭旧句柄。
|
|
9321
|
-
* - `reset` / `dispose`:切账号或销毁时作废订阅、分页结果并关闭全部会话句柄。
|
|
9322
|
-
*
|
|
9323
|
-
* 【并发与资源所有权】
|
|
9324
|
-
* 同一 Store 同时只有一个活动会话句柄。异步结果必须同时匹配最新操作序号、当前账号版本号、当前句柄
|
|
9325
|
-
* 和会话类型 + ID 才能更新页面;同 ID 的不同会话类型不会串线。句柄、订阅函数和“仍在使用”计数只在
|
|
9326
|
-
* 闭包中,不进入 `$state`。
|
|
9327
|
-
*
|
|
9328
|
-
* 【明确不负责】
|
|
9329
|
-
* Composer 输入、消息菜单、多选、DOM 滚动、路由和 toast 分别由其他共享 Store 或宿主平台层负责。
|
|
9330
|
-
*/
|
|
9331
|
-
|
|
9332
|
-
type ProductConversationHandle = ConversationHandle<ProductHandleConversationType>;
|
|
9333
|
-
/** Thread Store 中由 Pinia 管理的当前窗口投影;句柄、订阅和租约留在闭包中。 */
|
|
9334
|
-
interface ImThreadStoreState {
|
|
9335
|
-
activeRef: ConversationRef<ProductHandleConversationType> | null;
|
|
9336
|
-
/** SDK 已校验的活动聊天展示资料;不依赖该聊天是否已进入会话列表。 */
|
|
9337
|
-
display: ConversationHandleSnapshot['display'] | null;
|
|
9338
|
-
messages: readonly ImMessageView[];
|
|
9339
|
-
entryUnread: ConversationEntryUnreadSnapshot;
|
|
9340
|
-
/** 本次进入前的数量与定位状态;列表清零后仍保留。 */
|
|
9341
|
-
entryUnreadNavigation: ConversationHandleSnapshot['entryUnreadNavigation'];
|
|
9342
|
-
draft: ConversationDraft | null;
|
|
9343
|
-
loading: boolean;
|
|
9344
|
-
ready: boolean;
|
|
9345
|
-
stale: boolean;
|
|
9346
|
-
hasOlder: boolean;
|
|
9347
|
-
hasNewer: boolean;
|
|
9348
|
-
error: ImSdkErrorShape | null;
|
|
9349
|
-
/** 当前活动会话待 Surface 消费的实时对端消息版本。 */
|
|
9350
|
-
activeRemoteMessageRevision: number;
|
|
9351
|
-
}
|
|
9352
|
-
/** Thread Store 的稳定公共动作;DOM 滚动、路由和反馈仍由宿主负责。 */
|
|
9353
|
-
interface ImThreadStoreActions {
|
|
9354
|
-
open: (ref: ConversationRef<ProductHandleConversationType>) => Promise<ProductConversationHandle | undefined>;
|
|
9355
|
-
invalidatePendingOpen: () => void;
|
|
9356
|
-
loadLatest: () => Promise<boolean>;
|
|
9357
|
-
/** 读取本次进入时冻结的首未读窗口。 */
|
|
9358
|
-
loadEntryUnread: () => Promise<boolean>;
|
|
9359
|
-
/** 页面确认可阅读后结算整会话;不会自动扩大可见消息回执。 */
|
|
9360
|
-
markConversationRead: () => Promise<void>;
|
|
9361
|
-
/** 只上报当前线程实际显示的消息集合。 */
|
|
9362
|
-
markVisibleMessages: (messageIds: readonly string[]) => Promise<void>;
|
|
9363
|
-
/** 明确业务离开;账号销毁和页面卸载仍使用无副作用的 close/reset。 */
|
|
9364
|
-
leave: () => void;
|
|
9365
|
-
loadOlder: () => Promise<boolean>;
|
|
9366
|
-
loadNewer: () => Promise<boolean>;
|
|
9367
|
-
loadAround: (messageId: string) => Promise<boolean>;
|
|
9368
|
-
resolveMessage: (messageId: string) => Promise<ImMessageView | null>;
|
|
9369
|
-
retainHandle: (handle?: ProductConversationHandle) => () => void;
|
|
9370
|
-
retainCurrentHandle: () => () => void;
|
|
9371
|
-
close: () => void;
|
|
9372
|
-
closeActiveConversation: (ref: ConversationRef<ProductHandleConversationType>) => boolean;
|
|
9373
|
-
reset: () => void;
|
|
9374
|
-
dispose: () => void;
|
|
9375
|
-
getHandle: () => ProductConversationHandle | undefined;
|
|
9376
|
-
/** 原子取走当前活动会话尚未被 Surface 消费的实时对端消息 id。 */
|
|
9377
|
-
drainActiveRemoteMessageIds: () => readonly string[];
|
|
9378
|
-
}
|
|
9379
|
-
/** 宿主从 `useImThreadStore` 获得的完整 Pinia Store 公共类型。 */
|
|
9380
|
-
type ImThreadStore = Store<'k2-im-thread', ImThreadStoreState, Record<string, never>, ImThreadStoreActions>;
|
|
9381
|
-
/** 取得当前 Vue setup 或显式 Pinia 的消息线程 Store;每个实例只管理一个当前会话。 */
|
|
9382
|
-
declare function useImThreadStore(pinia?: Pinia): ImThreadStore;
|
|
9383
|
-
|
|
9384
9434
|
/** 新消息提醒所需的领域与宿主事实;本模块不读取浏览器、路由或全局设置。 */
|
|
9385
9435
|
interface MessageNotificationInput {
|
|
9386
9436
|
source: 'live' | 'offline';
|
|
@@ -9402,4 +9452,4 @@ type MessageNotificationDecision = {
|
|
|
9402
9452
|
declare function resolveMessageNotificationDecision(input: MessageNotificationInput): MessageNotificationDecision;
|
|
9403
9453
|
|
|
9404
9454
|
export { applicationKey, createAndInstallImChatKit, createImChatKitContext, disposeImChatKit, ensureImChatKitSelfProfile, getImChatKitContext, imMediaDownloadKey, installImChatKit, resolveMessageNotificationDecision, useImApplicationsStore, useImCapabilitiesStore, useImComposerStore, useImConversationActivationCoordinator, useImConversationDeletionCoordinator, useImConversationListStore, useImExpressionStore, useImHistoryReturnAfterSendCoordinator, useImMediaStore, useImMessageOperationsStore, useImProfileDirectoryStore, useImQuotedMessageStore, useImReactionStore, useImSearchStore, useImSessionFavoritesStore, useImSessionStore, useImThreadPagingStore, useImThreadReturnToLatestCoordinator, useImThreadStore };
|
|
9405
|
-
export type { ApplyImSessionInput, ChatRuntimeFactories, ChatRuntimeHostDeps, ImApplicationDomainCounts, ImApplicationReviewOperation, ImApplicationReviewResult, ImApplicationsReloadResult, ImApplicationsStoreError, ImCapabilitiesStore, ImChannelManagementMemberTarget, ImChannelMemberManagementOperation, ImChannelMemberManagementResult, ImChannelMemberManagementResultFor, ImChannelProfileActionResult, ImChannelProfileActionResultFor, ImChannelProfileOperation, ImChatKitContext, ImChatKitInstallation, ImComposerStore, ImComposerStoreActions, ImComposerStoreState, ImComposerSubmitResult, ImConversationActivationCoordinator, ImConversationActivationError, ImConversationActivationResult, ImConversationDeletionCoordinator, ImConversationDeletionError, ImConversationDeletionResult, ImConversationListActionError, ImConversationListMutationOperation, ImConversationListMutationResult, ImConversationListRefreshResult, ImConversationListStore, ImDirectContactActionResult, ImDirectContactActionResultFor, ImDirectContactOperation, ImDirectoryState, ImEmojiPanelRecentEntry, ImEmojiRecentEntry, ImExpressionLoadStatus, ImExpressionOperation, ImExpressionOperationResult, ImExpressionRecentPersistencePort, ImExpressionRecentPersistenceSnapshot, ImExpressionRecentViewItem, ImExpressionResetOptions, ImExpressionSendResult, ImExpressionStore, ImExpressionStoreActions, ImExpressionStoreError, ImExpressionStoreGetters, ImExpressionStoreState, ImForwardPreparationResult, ImGameRecentEntry, ImGroupMemberManagementOperation, ImGroupMemberManagementResult, ImGroupMemberManagementResultFor, ImGroupProfileActionResult, ImGroupProfileActionResultFor, ImGroupProfileOperation, ImHistoryReturnAfterSendCoordinator, ImHistoryReturnError, ImHistoryReturnExecution, ImHistoryReturnResult, ImMediaOperationResult, ImMediaReplacementRequest, ImMediaStore, ImMediaStoreError, ImMediaTaskPresentation, ImMembershipJoinActionResult, ImMembershipJoinOperation, ImMessageOperationsStore, ImMessageOperationsStoreActions, ImMessageOperationsStoreState, ImMessageSelectionResult, ImPersistedEmojiPanelRecentEntry, ImPersistedEmojiRecentEntry, ImPersistedExpressionAssetRecentEntry, ImPersistedGameRecentEntry, ImProfileAccessDestination, ImProfileAccessResult, ImProfileDirectoryResult, ImQuotedMessageState, ImQuotedMessageStore, ImQuotedMessageStoreActions, ImQuotedMessageStoreState, ImReactionOperationResult, ImReactionStore, ImReactionStoreActions, ImReactionStoreError, ImReactionStoreState, ImSearchOperationResult, ImSearchStore, ImSessionFavoritesReloadResult, ImSessionFavoritesStoreError, ImSessionFavoritesWriteResult, ImSessionPhase, ImSessionStore, ImThreadPagingActions, ImThreadPagingState, ImThreadPagingStore, ImThreadReturnToLatestCoordinator, ImThreadStore, ImThreadStoreActions, ImThreadStoreState };
|
|
9455
|
+
export type { ApplyImSessionInput, ChatRuntimeFactories, ChatRuntimeHostDeps, ImApplicationDomainCounts, ImApplicationReviewOperation, ImApplicationReviewResult, ImApplicationsReloadResult, ImApplicationsStoreError, ImCapabilitiesStore, ImChannelManagementMemberTarget, ImChannelMemberManagementOperation, ImChannelMemberManagementResult, ImChannelMemberManagementResultFor, ImChannelProfileActionResult, ImChannelProfileActionResultFor, ImChannelProfileOperation, ImChatKitContext, ImChatKitInstallation, ImComposerStore, ImComposerStoreActions, ImComposerStoreState, ImComposerSubmitResult, ImConversationActivationCoordinator, ImConversationActivationError, ImConversationActivationResult, ImConversationDeletionCoordinator, ImConversationDeletionError, ImConversationDeletionResult, ImConversationListActionError, ImConversationListMutationOperation, ImConversationListMutationResult, ImConversationListRefreshResult, ImConversationListStore, ImDirectContactActionResult, ImDirectContactActionResultFor, ImDirectContactOperation, ImDirectoryState, ImEmojiPanelRecentEntry, ImEmojiRecentEntry, ImExpressionLoadStatus, ImExpressionOperation, ImExpressionOperationResult, ImExpressionRecentPersistencePort, ImExpressionRecentPersistenceSnapshot, ImExpressionRecentViewItem, ImExpressionResetOptions, ImExpressionSendResult, ImExpressionStore, ImExpressionStoreActions, ImExpressionStoreError, ImExpressionStoreGetters, ImExpressionStoreState, ImForwardPreparationResult, ImGameRecentEntry, ImGroupMemberManagementOperation, ImGroupMemberManagementResult, ImGroupMemberManagementResultFor, ImGroupProfileActionResult, ImGroupProfileActionResultFor, ImGroupProfileOperation, ImHistoryReturnAfterSendCoordinator, ImHistoryReturnError, ImHistoryReturnExecution, ImHistoryReturnResult, ImMediaOperationResult, ImMediaReplacementRequest, ImMediaStore, ImMediaStoreError, ImMediaTaskPresentation, ImMembershipJoinActionResult, ImMembershipJoinOperation, ImMessageOperationsStore, ImMessageOperationsStoreActions, ImMessageOperationsStoreState, ImMessageSelectionResult, ImPersistedEmojiPanelRecentEntry, ImPersistedEmojiRecentEntry, ImPersistedExpressionAssetRecentEntry, ImPersistedGameRecentEntry, ImProfileAccessDestination, ImProfileAccessResult, ImProfileDirectoryResult, ImQuotedMessageState, ImQuotedMessageStore, ImQuotedMessageStoreActions, ImQuotedMessageStoreState, ImReactionOperationResult, ImReactionStore, ImReactionStoreActions, ImReactionStoreError, ImReactionStoreState, ImSearchOperationResult, ImSearchSenderPresentation, ImSearchStore, ImSessionFavoritesReloadResult, ImSessionFavoritesStoreError, ImSessionFavoritesWriteResult, ImSessionPhase, ImSessionStore, ImThreadPagingActions, ImThreadPagingState, ImThreadPagingStore, ImThreadReturnToLatestCoordinator, ImThreadStore, ImThreadStoreActions, ImThreadStoreState };
|