@blueking/chat-x 0.0.16 → 0.0.19
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/components/ai-shortcut/shortcut-btn/shortcut-btn.vue.d.ts +2 -2
- package/dist/icons/ai.d.ts +4 -4
- package/dist/index.css +1 -1
- package/dist/index.js +2615 -2597
- package/dist/index.js.map +1 -1
- package/dist/mcp/generated/docs/chat-container.md +8 -7
- package/dist/mcp/generated/docs/shortcut-btn.md +9 -9
- package/dist/mcp/generated/index.json +1 -1
- package/package.json +1 -1
|
@@ -326,13 +326,14 @@ ai-chat-container
|
|
|
326
326
|
|
|
327
327
|
ChatContainer 的 Props 继承自 `ChatInputProps` 和 `MessageContainerProps`(排除 `enableSelection` 和 `messageGroups`),另外新增:
|
|
328
328
|
|
|
329
|
-
| 属性名 | 类型
|
|
330
|
-
| ------------------ |
|
|
331
|
-
| chatLoading | `boolean`
|
|
332
|
-
| commonTippyOptions | `AITippyProps`
|
|
333
|
-
| openingRemark | `string`
|
|
334
|
-
| placement | `'left' \| 'right'`
|
|
335
|
-
|
|
|
329
|
+
| 属性名 | 类型 | 默认值 | 说明 |
|
|
330
|
+
| ------------------ | ---------------------------------------------------------------------------- | -------- | --------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
331
|
+
| chatLoading | `boolean` | — | 整体加载状态,`true` 时显示 Loading 遮罩 |
|
|
332
|
+
| commonTippyOptions | `AITippyProps` | — | 通用 Tippy 配置,传入的选项会注入到所有使用 `v-overflow-tips` 的子组件中 |
|
|
333
|
+
| openingRemark | `string` | — | 开场白,无消息时显示,支持 Markdown |
|
|
334
|
+
| placement | `'left' \| 'right'` | `'left'` | 侧边栏位置 |
|
|
335
|
+
| resizeProps | `{ disabled?: boolean; initialDivide?: number; max?: number; min?: number }` | — | 透传给内部 `ResizeLayout` 的可选配置,与默认 `collapsible: false`、`immediate: true`、`min: 400` 合并;`placement` 始终取自本组件 `placement` |
|
|
336
|
+
| onCustomTabChange | `(tab: CustomTab) => Promise<any>` | — | 自定义 Tab 切换回调,返回值作为 Tab 组件 props |
|
|
336
337
|
|
|
337
338
|
> 完整 Props 列表请参考 [ChatInput](./chat-input.md) 和 [MessageContainer](./message-container.md) 文档。
|
|
338
339
|
|
|
@@ -29,7 +29,7 @@ button.ai-shortcut-btn(flex,gap: 4px,height: 28px,padding: 0 4px,white
|
|
|
29
29
|
│
|
|
30
30
|
├── <slot name="default">(覆盖后图标+名称全部替换)
|
|
31
31
|
│ ├── [shortcut.icon 为字符串 && 以 'http' 开头]
|
|
32
|
-
│ │
|
|
32
|
+
│ │ 加载成功:<img … />;加载失败:回退 AgentIcon.ai-shortcut-btn-icon
|
|
33
33
|
│ ├── [shortcut.icon 为字符串 && 不以 'http' 开头]
|
|
34
34
|
│ │ <span :class="icon" />(CSS 图标类名,无其他 class)
|
|
35
35
|
│ ├── [shortcut.icon 为函数或组件]
|
|
@@ -47,14 +47,14 @@ defineExpose: { get $el() { return el.value } }(懒 getter,返回 button 元
|
|
|
47
47
|
|
|
48
48
|
## 图标渲染规则
|
|
49
49
|
|
|
50
|
-
| `shortcut.icon` 类型 | 渲染结果 | 额外说明
|
|
51
|
-
| ------------------------------------- | --------------------------- |
|
|
52
|
-
| 未设置(且 `components` 为空/未设置) | `AgentIcon`(默认图标) | `components: []` 与不传效果相同
|
|
53
|
-
| 未设置(且 `components` 有内容) | 无图标 | 表单类快捷指令
|
|
54
|
-
| `string`,以 `'http'` 开头 | `<img
|
|
55
|
-
| `string`,不以 `'http'` 开头 | `<span :class="icon">` | 视为 CSS 图标类名,无其他 class
|
|
56
|
-
| 函数 `(h) => Component/VNode` | `<component :is="icon(h)">` | 有 `.ai-shortcut-btn-icon`
|
|
57
|
-
| 组件对象 | `<component :is="icon">` | 有 `.ai-shortcut-btn-icon`
|
|
50
|
+
| `shortcut.icon` 类型 | 渲染结果 | 额外说明 |
|
|
51
|
+
| ------------------------------------- | --------------------------- | ---------------------------------------------------------------- |
|
|
52
|
+
| 未设置(且 `components` 为空/未设置) | `AgentIcon`(默认图标) | `components: []` 与不传效果相同 |
|
|
53
|
+
| 未设置(且 `components` 有内容) | 无图标 | 表单类快捷指令 |
|
|
54
|
+
| `string`,以 `'http'` 开头 | `<img>`,失败时 `AgentIcon` | `.ai-common-icon .ai-shortcut-btn-icon`;`@error` 后回退默认图标 |
|
|
55
|
+
| `string`,不以 `'http'` 开头 | `<span :class="icon">` | 视为 CSS 图标类名,无其他 class |
|
|
56
|
+
| 函数 `(h) => Component/VNode` | `<component :is="icon(h)">` | 有 `.ai-shortcut-btn-icon` |
|
|
57
|
+
| 组件对象 | `<component :is="icon">` | 有 `.ai-shortcut-btn-icon` |
|
|
58
58
|
|
|
59
59
|
## 基础用法
|
|
60
60
|
|