@hkyhy/marsun-components-core 0.1.52 → 0.1.53
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/README.md +23 -15
- package/dist/agent-hub.d.ts +11 -0
- package/dist/agent-hub.js +144 -0
- package/dist/agent-hub.js.map +1 -0
- package/dist/components/AgentHub/Chat/Action/CreateButton.js +3 -3
- package/dist/components/AgentHub/Chat/Action/ManageActionButtons.js +4 -4
- package/dist/components/AgentHub/Chat/Action/SessionActionButtons.js +4 -4
- package/dist/components/AgentHub/Chat/Detail/ChatFollowUpSuggestions/index.js +29 -27
- package/dist/components/AgentHub/Chat/Detail/ChatFollowUpSuggestions/index.js.map +1 -1
- package/dist/components/AgentHub/Chat/Detail/ChatInput/index.js +19 -18
- package/dist/components/AgentHub/Chat/Detail/ChatInput/index.js.map +1 -1
- package/dist/components/AgentHub/Chat/Detail/CitationPanel/index.js +18 -17
- package/dist/components/AgentHub/Chat/Detail/CitationPanel/index.js.map +1 -1
- package/dist/components/AgentHub/Chat/Detail/MessageActions/index.js +23 -19
- package/dist/components/AgentHub/Chat/Detail/MessageActions/index.js.map +1 -1
- package/dist/components/AgentHub/Chat/Detail/MessageItem/index.js +23 -21
- package/dist/components/AgentHub/Chat/Detail/MessageItem/index.js.map +1 -1
- package/dist/components/AgentHub/Chat/List/ChatCard/index.js +7 -7
- package/dist/components/AgentHub/Chat/List/SessionSidebar/index.js +19 -17
- package/dist/components/AgentHub/Chat/List/SessionSidebar/index.js.map +1 -1
- package/dist/components/AgentHub/KnowledgeBase/Action/CreateButton.js +3 -3
- package/dist/components/AgentHub/KnowledgeBase/Action/ManageActionButtons.js +1 -1
- package/dist/components/AgentHub/KnowledgeBase/Detail/DocumentTable/index.js +16 -15
- package/dist/components/AgentHub/KnowledgeBase/Detail/DocumentTable/index.js.map +1 -1
- package/dist/components/AgentHub/KnowledgeBase/Detail/ParseStatusTag/index.js +7 -7
- package/dist/components/AgentHub/KnowledgeBase/List/KnowledgeCard/index.js +8 -8
- package/dist/components/AgentHub/Report/Detail/ReportHtmlPreview/index.js +1 -1
- package/dist/components/Auth/UserProfileCard/UserProfileCard.js +7 -7
- package/dist/components/File/FileItem/index.js +22 -20
- package/dist/components/File/FileItem/index.js.map +1 -1
- package/dist/components/File/FilePreview/index.js +11 -11
- package/dist/components/File/fileDisplay.js +41 -36
- package/dist/components/File/fileDisplay.js.map +1 -1
- package/dist/components/Filter/CommonFilter/index.js +20 -18
- package/dist/components/Filter/CommonFilter/index.js.map +1 -1
- package/dist/components/Filter/FilterSelect/index.js +90 -89
- package/dist/components/Filter/FilterSelect/index.js.map +1 -1
- package/dist/components/Filter/FilterTreeSelect/index.js +51 -48
- package/dist/components/Filter/FilterTreeSelect/index.js.map +1 -1
- package/dist/components/Filter/FilterTrigger/index.js +13 -11
- package/dist/components/Filter/FilterTrigger/index.js.map +1 -1
- package/dist/components/Form/PersonOptionRow/index.js +4 -4
- package/dist/components/Icons/ArrowLeft.d.ts +1 -0
- package/dist/components/Icons/ArrowLeft.js +7 -0
- package/dist/components/Icons/ArrowLeft.js.map +1 -0
- package/dist/components/Icons/ArrowLeftRight.d.ts +1 -0
- package/dist/components/Icons/ArrowLeftRight.js +7 -0
- package/dist/components/Icons/ArrowLeftRight.js.map +1 -0
- package/dist/components/Icons/BarChart3.d.ts +1 -0
- package/dist/components/Icons/BarChart3.js +7 -0
- package/dist/components/Icons/BarChart3.js.map +1 -0
- package/dist/components/Icons/Bell.d.ts +1 -0
- package/dist/components/Icons/Bell.js +7 -0
- package/dist/components/Icons/Bell.js.map +1 -0
- package/dist/components/Icons/BookOpen.d.ts +1 -0
- package/dist/components/Icons/BookOpen.js +7 -0
- package/dist/components/Icons/BookOpen.js.map +1 -0
- package/dist/components/Icons/Bot.d.ts +1 -0
- package/dist/components/Icons/Bot.js +7 -0
- package/dist/components/Icons/Bot.js.map +1 -0
- package/dist/components/Icons/Check.d.ts +1 -0
- package/dist/components/Icons/Check.js +7 -0
- package/dist/components/Icons/Check.js.map +1 -0
- package/dist/components/Icons/ChevronDown.d.ts +1 -0
- package/dist/components/Icons/ChevronDown.js +7 -0
- package/dist/components/Icons/ChevronDown.js.map +1 -0
- package/dist/components/Icons/ChevronLeft.d.ts +1 -0
- package/dist/components/Icons/ChevronLeft.js +7 -0
- package/dist/components/Icons/ChevronLeft.js.map +1 -0
- package/dist/components/Icons/ChevronRight.d.ts +1 -0
- package/dist/components/Icons/ChevronRight.js +7 -0
- package/dist/components/Icons/ChevronRight.js.map +1 -0
- package/dist/components/Icons/ChevronUp.d.ts +1 -0
- package/dist/components/Icons/ChevronUp.js +7 -0
- package/dist/components/Icons/ChevronUp.js.map +1 -0
- package/dist/components/Icons/CircleAlert.d.ts +1 -0
- package/dist/components/Icons/CircleAlert.js +7 -0
- package/dist/components/Icons/CircleAlert.js.map +1 -0
- package/dist/components/Icons/CircleCheck.d.ts +1 -0
- package/dist/components/Icons/CircleCheck.js +7 -0
- package/dist/components/Icons/CircleCheck.js.map +1 -0
- package/dist/components/Icons/CircleHelp.d.ts +1 -0
- package/dist/components/Icons/CircleHelp.js +7 -0
- package/dist/components/Icons/CircleHelp.js.map +1 -0
- package/dist/components/Icons/CirclePlay.d.ts +1 -0
- package/dist/components/Icons/CirclePlay.js +7 -0
- package/dist/components/Icons/CirclePlay.js.map +1 -0
- package/dist/components/Icons/CircleX.d.ts +1 -0
- package/dist/components/Icons/CircleX.js +7 -0
- package/dist/components/Icons/CircleX.js.map +1 -0
- package/dist/components/Icons/ClipboardCheck.d.ts +1 -0
- package/dist/components/Icons/ClipboardCheck.js +7 -0
- package/dist/components/Icons/ClipboardCheck.js.map +1 -0
- package/dist/components/Icons/Clock.d.ts +1 -0
- package/dist/components/Icons/Clock.js +7 -0
- package/dist/components/Icons/Clock.js.map +1 -0
- package/dist/components/Icons/CloudDownload.d.ts +1 -0
- package/dist/components/Icons/CloudDownload.js +7 -0
- package/dist/components/Icons/CloudDownload.js.map +1 -0
- package/dist/components/Icons/CloudUpload.d.ts +1 -0
- package/dist/components/Icons/CloudUpload.js +7 -0
- package/dist/components/Icons/CloudUpload.js.map +1 -0
- package/dist/components/Icons/Code.d.ts +1 -0
- package/dist/components/Icons/Code.js +7 -0
- package/dist/components/Icons/Code.js.map +1 -0
- package/dist/components/Icons/Copy.d.ts +1 -0
- package/dist/components/Icons/Copy.js +7 -0
- package/dist/components/Icons/Copy.js.map +1 -0
- package/dist/components/Icons/Crown.d.ts +1 -0
- package/dist/components/Icons/Crown.js +7 -0
- package/dist/components/Icons/Crown.js.map +1 -0
- package/dist/components/Icons/Database.d.ts +1 -0
- package/dist/components/Icons/Database.js +7 -0
- package/dist/components/Icons/Database.js.map +1 -0
- package/dist/components/Icons/Download.d.ts +1 -0
- package/dist/components/Icons/Download.js +7 -0
- package/dist/components/Icons/Download.js.map +1 -0
- package/dist/components/Icons/Eye.d.ts +1 -0
- package/dist/components/Icons/Eye.js +7 -0
- package/dist/components/Icons/Eye.js.map +1 -0
- package/dist/components/Icons/EyeOff.d.ts +1 -0
- package/dist/components/Icons/EyeOff.js +7 -0
- package/dist/components/Icons/EyeOff.js.map +1 -0
- package/dist/components/Icons/File.d.ts +1 -0
- package/dist/components/Icons/File.js +7 -0
- package/dist/components/Icons/File.js.map +1 -0
- package/dist/components/Icons/FileArchive.d.ts +1 -0
- package/dist/components/Icons/FileArchive.js +7 -0
- package/dist/components/Icons/FileArchive.js.map +1 -0
- package/dist/components/Icons/FileImage.d.ts +1 -0
- package/dist/components/Icons/FileImage.js +7 -0
- package/dist/components/Icons/FileImage.js.map +1 -0
- package/dist/components/Icons/FileSpreadsheet.d.ts +1 -0
- package/dist/components/Icons/FileSpreadsheet.js +7 -0
- package/dist/components/Icons/FileSpreadsheet.js.map +1 -0
- package/dist/components/Icons/FileText.d.ts +1 -0
- package/dist/components/Icons/FileText.js +7 -0
- package/dist/components/Icons/FileText.js.map +1 -0
- package/dist/components/Icons/Flag.d.ts +1 -0
- package/dist/components/Icons/Flag.js +7 -0
- package/dist/components/Icons/Flag.js.map +1 -0
- package/dist/components/Icons/Flame.d.ts +1 -0
- package/dist/components/Icons/Flame.js +7 -0
- package/dist/components/Icons/Flame.js.map +1 -0
- package/dist/components/Icons/Folder.d.ts +1 -0
- package/dist/components/Icons/Folder.js +7 -0
- package/dist/components/Icons/Folder.js.map +1 -0
- package/dist/components/Icons/FolderOpen.d.ts +1 -0
- package/dist/components/Icons/FolderOpen.js +7 -0
- package/dist/components/Icons/FolderOpen.js.map +1 -0
- package/dist/components/Icons/Hash.d.ts +1 -0
- package/dist/components/Icons/Hash.js +7 -0
- package/dist/components/Icons/Hash.js.map +1 -0
- package/dist/components/Icons/House.d.ts +1 -0
- package/dist/components/Icons/House.js +7 -0
- package/dist/components/Icons/House.js.map +1 -0
- package/dist/components/Icons/Import.d.ts +1 -0
- package/dist/components/Icons/Import.js +7 -0
- package/dist/components/Icons/Import.js.map +1 -0
- package/dist/components/Icons/Inbox.d.ts +1 -0
- package/dist/components/Icons/Inbox.js +7 -0
- package/dist/components/Icons/Inbox.js.map +1 -0
- package/dist/components/Icons/Info.d.ts +1 -0
- package/dist/components/Icons/Info.js +7 -0
- package/dist/components/Icons/Info.js.map +1 -0
- package/dist/components/Icons/LayoutDashboard.d.ts +1 -0
- package/dist/components/Icons/LayoutDashboard.js +7 -0
- package/dist/components/Icons/LayoutDashboard.js.map +1 -0
- package/dist/components/Icons/LayoutGrid.d.ts +1 -0
- package/dist/components/Icons/LayoutGrid.js +7 -0
- package/dist/components/Icons/LayoutGrid.js.map +1 -0
- package/dist/components/Icons/ListTodo.d.ts +1 -0
- package/dist/components/Icons/ListTodo.js +7 -0
- package/dist/components/Icons/ListTodo.js.map +1 -0
- package/dist/components/Icons/Loader2.d.ts +1 -0
- package/dist/components/Icons/Loader2.js +7 -0
- package/dist/components/Icons/Loader2.js.map +1 -0
- package/dist/components/Icons/Lock.d.ts +1 -0
- package/dist/components/Icons/Lock.js +7 -0
- package/dist/components/Icons/Lock.js.map +1 -0
- package/dist/components/Icons/LogOut.d.ts +1 -0
- package/dist/components/Icons/LogOut.js +7 -0
- package/dist/components/Icons/LogOut.js.map +1 -0
- package/dist/components/Icons/Maximize2.d.ts +1 -0
- package/dist/components/Icons/Maximize2.js +7 -0
- package/dist/components/Icons/Maximize2.js.map +1 -0
- package/dist/components/Icons/MessageCircle.d.ts +1 -0
- package/dist/components/Icons/MessageCircle.js +7 -0
- package/dist/components/Icons/MessageCircle.js.map +1 -0
- package/dist/components/Icons/MessageSquare.d.ts +1 -0
- package/dist/components/Icons/MessageSquare.js +7 -0
- package/dist/components/Icons/MessageSquare.js.map +1 -0
- package/dist/components/Icons/Minimize2.d.ts +1 -0
- package/dist/components/Icons/Minimize2.js +7 -0
- package/dist/components/Icons/Minimize2.js.map +1 -0
- package/dist/components/Icons/PanelLeftClose.d.ts +1 -0
- package/dist/components/Icons/PanelLeftClose.js +7 -0
- package/dist/components/Icons/PanelLeftClose.js.map +1 -0
- package/dist/components/Icons/PanelLeftOpen.d.ts +1 -0
- package/dist/components/Icons/PanelLeftOpen.js +7 -0
- package/dist/components/Icons/PanelLeftOpen.js.map +1 -0
- package/dist/components/Icons/Pause.d.ts +1 -0
- package/dist/components/Icons/Pause.js +7 -0
- package/dist/components/Icons/Pause.js.map +1 -0
- package/dist/components/Icons/Pencil.d.ts +1 -0
- package/dist/components/Icons/Pencil.js +7 -0
- package/dist/components/Icons/Pencil.js.map +1 -0
- package/dist/components/Icons/Plus.d.ts +1 -0
- package/dist/components/Icons/Plus.js +7 -0
- package/dist/components/Icons/Plus.js.map +1 -0
- package/dist/components/Icons/Presentation.d.ts +1 -0
- package/dist/components/Icons/Presentation.js +7 -0
- package/dist/components/Icons/Presentation.js.map +1 -0
- package/dist/components/Icons/RefreshCw.d.ts +1 -0
- package/dist/components/Icons/RefreshCw.js +7 -0
- package/dist/components/Icons/RefreshCw.js.map +1 -0
- package/dist/components/Icons/RotateCw.d.ts +1 -0
- package/dist/components/Icons/RotateCw.js +7 -0
- package/dist/components/Icons/RotateCw.js.map +1 -0
- package/dist/components/Icons/Send.d.ts +1 -0
- package/dist/components/Icons/Send.js +7 -0
- package/dist/components/Icons/Send.js.map +1 -0
- package/dist/components/Icons/Settings.d.ts +1 -0
- package/dist/components/Icons/Settings.js +7 -0
- package/dist/components/Icons/Settings.js.map +1 -0
- package/dist/components/Icons/Shield.d.ts +1 -0
- package/dist/components/Icons/Shield.js +7 -0
- package/dist/components/Icons/Shield.js.map +1 -0
- package/dist/components/Icons/ShieldCheck.d.ts +1 -0
- package/dist/components/Icons/ShieldCheck.js +7 -0
- package/dist/components/Icons/ShieldCheck.js.map +1 -0
- package/dist/components/Icons/SlidersHorizontal.d.ts +1 -0
- package/dist/components/Icons/SlidersHorizontal.js +7 -0
- package/dist/components/Icons/SlidersHorizontal.js.map +1 -0
- package/dist/components/Icons/Square.d.ts +1 -0
- package/dist/components/Icons/Square.js +7 -0
- package/dist/components/Icons/Square.js.map +1 -0
- package/dist/components/Icons/Star.d.ts +1 -0
- package/dist/components/Icons/Star.js +7 -0
- package/dist/components/Icons/Star.js.map +1 -0
- package/dist/components/Icons/ThumbsDown.d.ts +1 -0
- package/dist/components/Icons/ThumbsDown.js +7 -0
- package/dist/components/Icons/ThumbsDown.js.map +1 -0
- package/dist/components/Icons/ThumbsUp.d.ts +1 -0
- package/dist/components/Icons/ThumbsUp.js +7 -0
- package/dist/components/Icons/ThumbsUp.js.map +1 -0
- package/dist/components/Icons/Trash2.d.ts +1 -0
- package/dist/components/Icons/Trash2.js +7 -0
- package/dist/components/Icons/Trash2.js.map +1 -0
- package/dist/components/Icons/Trophy.d.ts +1 -0
- package/dist/components/Icons/Trophy.js +7 -0
- package/dist/components/Icons/Trophy.js.map +1 -0
- package/dist/components/Icons/Undo2.d.ts +1 -0
- package/dist/components/Icons/Undo2.js +7 -0
- package/dist/components/Icons/Undo2.js.map +1 -0
- package/dist/components/Icons/Upload.d.ts +1 -0
- package/dist/components/Icons/Upload.js +7 -0
- package/dist/components/Icons/Upload.js.map +1 -0
- package/dist/components/Icons/User.d.ts +1 -0
- package/dist/components/Icons/User.js +7 -0
- package/dist/components/Icons/User.js.map +1 -0
- package/dist/components/Icons/UserPlus.d.ts +1 -0
- package/dist/components/Icons/UserPlus.js +7 -0
- package/dist/components/Icons/UserPlus.js.map +1 -0
- package/dist/components/Icons/UserRoundCog.d.ts +1 -0
- package/dist/components/Icons/UserRoundCog.js +7 -0
- package/dist/components/Icons/UserRoundCog.js.map +1 -0
- package/dist/components/Icons/Users.d.ts +1 -0
- package/dist/components/Icons/Users.js +7 -0
- package/dist/components/Icons/Users.js.map +1 -0
- package/dist/components/Icons/X.d.ts +1 -0
- package/dist/components/Icons/X.js +7 -0
- package/dist/components/Icons/X.js.map +1 -0
- package/dist/components/Icons/createIcon.d.ts +9 -0
- package/dist/components/Icons/createIcon.js +32 -0
- package/dist/components/Icons/createIcon.js.map +1 -0
- package/dist/components/Icons/index.d.ts +80 -90
- package/dist/components/Icons/registry.d.ts +6 -0
- package/dist/components/Icons/registry.js +239 -0
- package/dist/components/Icons/registry.js.map +1 -0
- package/dist/components/InteractiveBlock/InteractiveBlock.js +6 -6
- package/dist/components/Layout/AgentAppShell/AgentAppShell.js +24 -23
- package/dist/components/Layout/AgentAppShell/AgentAppShell.js.map +1 -1
- package/dist/components/Layout/PageHeaderLayout/index.js +7 -7
- package/dist/components/Modal/Modal/index.js +8 -8
- package/dist/components/Modal/StepModal/index.js +9 -9
- package/dist/components/OrgTree/OrgTree.js +41 -39
- package/dist/components/OrgTree/OrgTree.js.map +1 -1
- package/dist/components/StateBar/StateBar.js +4 -4
- package/dist/components/Table/ColumnConfigPanel.js +13 -10
- package/dist/components/Table/ColumnConfigPanel.js.map +1 -1
- package/dist/components/Table/Table.js +7 -7
- package/dist/components/Tour/AppTour/index.js +10 -10
- package/dist/components/Upload/index.js +76 -72
- package/dist/components/Upload/index.js.map +1 -1
- package/dist/file.d.ts +5 -0
- package/dist/file.js +24 -0
- package/dist/file.js.map +1 -0
- package/dist/index.d.ts +3 -1
- package/dist/index.js +615 -537
- package/dist/index.js.map +1 -1
- package/dist/llm.d.ts +5 -0
- package/dist/llm.js +8 -0
- package/dist/llm.js.map +1 -0
- package/dist/marsun-components-core.css +1 -1
- package/dist/styles/global.css +1 -1
- package/package.json +15 -5
- package/dist/components/Icons/index.js +0 -268
- package/dist/components/Icons/index.js.map +0 -1
package/README.md
CHANGED
|
@@ -46,22 +46,29 @@ applyThemeToCssVariables(primaryColor);
|
|
|
46
46
|
themeConfig={generateTheme(primaryColor)}
|
|
47
47
|
>
|
|
48
48
|
<SemanticTag color="primary">标签</SemanticTag>
|
|
49
|
-
<ChatPanel
|
|
50
|
-
|
|
51
|
-
inputValue=""
|
|
52
|
-
onInputChange={() => {}}
|
|
53
|
-
onSend={() => {}}
|
|
54
|
-
/>
|
|
55
|
-
</MarsunCoreProvider>
|
|
49
|
+
<ChatPanel messages={[]} inputValue="" onInputChange={() => {}} onSend={() => {}} />
|
|
50
|
+
</MarsunCoreProvider>;
|
|
56
51
|
```
|
|
57
52
|
|
|
58
53
|
### 主题与 Token
|
|
59
54
|
|
|
60
|
-
| 导入路径
|
|
61
|
-
|
|
|
62
|
-
| `@hkyhy/marsun-components-core/tokens` | 静态 CSS 变量默认值(布局、灰阶、标签色等)
|
|
63
|
-
| `@hkyhy/marsun-components-core/theme`
|
|
64
|
-
| `@hkyhy/marsun-components-core/styles` | 组件库打包样式
|
|
55
|
+
| 导入路径 | 用途 |
|
|
56
|
+
| -------------------------------------- | ----------------------------------------------------------------------- |
|
|
57
|
+
| `@hkyhy/marsun-components-core/tokens` | 静态 CSS 变量默认值(布局、灰阶、标签色等) |
|
|
58
|
+
| `@hkyhy/marsun-components-core/theme` | `generateTheme`, `applyThemeToCssVariables`, `PALETTE`, `LAYOUT_TOKENS` |
|
|
59
|
+
| `@hkyhy/marsun-components-core/styles` | 组件库打包样式 |
|
|
60
|
+
|
|
61
|
+
### L2 产品域(v0.1.53+)
|
|
62
|
+
|
|
63
|
+
AgentHub / File 预览 / Llm 走子路径,避免无相关产品首包拖入重依赖:
|
|
64
|
+
|
|
65
|
+
| 导入路径 | 用途 |
|
|
66
|
+
| ----------------------------------------- | ----------------------------------------- |
|
|
67
|
+
| `@hkyhy/marsun-components-core/agent-hub` | Chat、Knowledge、Citation、AgentHub Guard |
|
|
68
|
+
| `@hkyhy/marsun-components-core/file` | FilePreview、FileItem、FileLink 等 |
|
|
69
|
+
| `@hkyhy/marsun-components-core/llm` | LlmFormattedText |
|
|
70
|
+
|
|
71
|
+
包根仍 re-export L2(迁移期 `@deprecated`);新代码请用子路径。
|
|
65
72
|
|
|
66
73
|
项目可在 `src/styles/tokens.css` 扩展领域变量,详见 showcase 内 `frontend-dev-spec` → `theme.md`。
|
|
67
74
|
|
|
@@ -108,11 +115,12 @@ npm run typecheck
|
|
|
108
115
|
包名为 **`@hkyhy/marsun-components-core`**(npm scope 与 GitHub 发布账号 `hkyhy` 对齐)。
|
|
109
116
|
|
|
110
117
|
1. 在 GitHub 仓库 **Settings → Secrets → Actions** 配置 `HKYHY_PACKAGE_PUBLISH`(npm Automation Token,对 `@hkyhy` 有 publish 权限)
|
|
111
|
-
2.
|
|
112
|
-
3.
|
|
118
|
+
2. **发版**:先将 `package.json` version 升到待发布号,再提交并 push 首行形如 `chore(release): vX.Y.Z …` 的 commit;`release.yml` 校验版本 → 打 tag → `npm publish`(仅该消息前缀触发,feat push 不发版)
|
|
119
|
+
3. 示例:
|
|
113
120
|
|
|
114
121
|
```bash
|
|
115
|
-
|
|
122
|
+
# version 已为 0.1.53 时
|
|
123
|
+
git push origin main # 含 chore(release): v0.1.53 …
|
|
116
124
|
```
|
|
117
125
|
|
|
118
126
|
也可在 Actions 中手动运行 **Publish npm**,填写已有 tag 重新发布。
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* L2 产品域入口:`@hkyhy/marsun-components-core/agent-hub`
|
|
3
|
+
* 新代码须从此子路径 import;包根 re-export 为迁移期 @deprecated。
|
|
4
|
+
*/
|
|
5
|
+
export { default as AgentHubAccessGuard } from './components/AgentHub/AgentHubAccessGuard';
|
|
6
|
+
export { default as AgentHubIndexRedirect } from './components/AgentHub/AgentHubIndexRedirect';
|
|
7
|
+
export { default as AgentHubSessionAccessGuard } from './components/AgentHub/ChatSessionAccessGuard';
|
|
8
|
+
export type * from './components/AgentHub/types';
|
|
9
|
+
export * from './components/AgentHub/Chat';
|
|
10
|
+
export * from './components/AgentHub/KnowledgeBase';
|
|
11
|
+
export * from './components/AgentHub/Report';
|
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
import { default as o } from "./components/AgentHub/AgentHubAccessGuard.js";
|
|
2
|
+
import { default as r } from "./components/AgentHub/AgentHubIndexRedirect.js";
|
|
3
|
+
import { default as i } from "./components/AgentHub/ChatSessionAccessGuard.js";
|
|
4
|
+
import { default as n } from "./components/AgentHub/Chat/Detail/ChatAgentFab/index.js";
|
|
5
|
+
import { default as p } from "./components/AgentHub/Chat/Detail/ChatAgentFabLayout/index.js";
|
|
6
|
+
import { default as u } from "./components/AgentHub/Chat/Form/Form.js";
|
|
7
|
+
import { default as x } from "./components/AgentHub/Chat/List/ChatCard/index.js";
|
|
8
|
+
import { default as c } from "./components/AgentHub/Chat/Action/CreateButton.js";
|
|
9
|
+
import { default as S } from "./components/AgentHub/Chat/List/FilterBar.js";
|
|
10
|
+
import { default as B } from "./components/AgentHub/Chat/Detail/ChatFollowUpSuggestions/index.js";
|
|
11
|
+
import { default as h } from "./components/AgentHub/Chat/Modal/FormModal.js";
|
|
12
|
+
import { default as I } from "./components/AgentHub/Chat/Detail/ChatInput/index.js";
|
|
13
|
+
import { default as P } from "./components/AgentHub/Chat/Action/ManageActionButtons.js";
|
|
14
|
+
import { default as R } from "./components/AgentHub/Chat/Detail/ChatPanel/index.js";
|
|
15
|
+
import { default as w } from "./components/AgentHub/Chat/Detail/ChatSuggestionRow/index.js";
|
|
16
|
+
import { default as N } from "./components/AgentHub/Chat/Detail/ChatWidgetBlock/index.js";
|
|
17
|
+
import { default as b } from "./components/AgentHub/Chat/Detail/CitationContent/index.js";
|
|
18
|
+
import { default as H } from "./components/AgentHub/Chat/Detail/CitationInlineBadge/index.js";
|
|
19
|
+
import { default as _ } from "./components/AgentHub/Chat/Detail/CitationMarkdownContent/index.js";
|
|
20
|
+
import { default as z } from "./components/AgentHub/Chat/Detail/CitationPanel/index.js";
|
|
21
|
+
import { default as G } from "./components/AgentHub/KnowledgeBase/Action/CreateButton.js";
|
|
22
|
+
import { default as W } from "./components/AgentHub/KnowledgeBase/Detail/DocumentTable/index.js";
|
|
23
|
+
import { default as q } from "./components/AgentHub/KnowledgeBase/List/FilterBar.js";
|
|
24
|
+
import { default as X } from "./components/AgentHub/KnowledgeBase/Modal/FormModal.js";
|
|
25
|
+
import { default as Q } from "./components/AgentHub/KnowledgeBase/Form/Form.js";
|
|
26
|
+
import { default as Z } from "./components/AgentHub/KnowledgeBase/List/KnowledgeCard/index.js";
|
|
27
|
+
import { default as tt } from "./components/AgentHub/KnowledgeBase/Action/ManageActionButtons.js";
|
|
28
|
+
import { default as ot } from "./components/AgentHub/Chat/Detail/MermaidBlock/index.js";
|
|
29
|
+
import { default as rt } from "./components/AgentHub/Chat/Detail/MessageActions/index.js";
|
|
30
|
+
import { default as it } from "./components/AgentHub/Chat/Detail/MessageEditPopover/index.js";
|
|
31
|
+
import { default as nt } from "./components/AgentHub/Chat/Detail/MessageItem/index.js";
|
|
32
|
+
import { default as pt } from "./components/AgentHub/KnowledgeBase/Detail/ParseStatusTag/index.js";
|
|
33
|
+
import { default as ut } from "./components/AgentHub/Report/Detail/ReportArchiveModal/index.js";
|
|
34
|
+
import { default as xt } from "./components/AgentHub/Report/Detail/ReportExportLayout/index.js";
|
|
35
|
+
import { default as ct } from "./components/AgentHub/Report/Detail/ReportHtmlPreview/index.js";
|
|
36
|
+
import { default as St } from "./components/AgentHub/Report/Detail/ReportMetaStrip/index.js";
|
|
37
|
+
import { default as Bt } from "./components/AgentHub/Report/Detail/ReportTemplate/index.js";
|
|
38
|
+
import { default as ht } from "./components/AgentHub/Report/Detail/ReportVersionList/index.js";
|
|
39
|
+
import { default as It } from "./components/AgentHub/Report/Detail/ReportWorkspace/index.js";
|
|
40
|
+
import { default as Pt } from "./components/AgentHub/Chat/Action/SessionActionButtons.js";
|
|
41
|
+
import { default as Rt } from "./components/AgentHub/Chat/List/SessionSidebar/index.js";
|
|
42
|
+
import { default as wt } from "./components/AgentHub/Chat/Detail/ThinkingSection/index.js";
|
|
43
|
+
import { CHUNK_METHOD_OPTIONS as Nt, EMBEDDING_MODEL_OPTIONS as Ot, PARSE_STATUS_CONFIG as bt } from "./components/AgentHub/KnowledgeBase/constants/types.js";
|
|
44
|
+
import { CITATION_LINK_PREFIX as Ht, citationDisplayNumber as Kt, citationIdToIndex as _t, countUniqueCitedSources as Lt, detectCitationIdBase as zt, extractCitationIdsFromContent as vt, extractCitationTitle as Gt, formatCitationDocBasename as Ut, formatCitationMeta as Wt, formatCitationPositions as jt, injectCitationMarkdownLinks as qt, normalizeCitation as Vt, parseCitationLinkHref as Xt, prepareCitationContent as Jt, resolveCitationTitle as Qt, sanitizeCitationHtml as Yt, stripCitationFrontmatter as Zt } from "./components/AgentHub/Chat/utils/citationContent.js";
|
|
45
|
+
import { animateScrollFromTopToBottom as te, animateScrollTo as ee, getScrollBottom as oe } from "./components/AgentHub/Chat/utils/smoothScroll.js";
|
|
46
|
+
import { extractCitations as re, formatSessionTime as se, getSessionDisplayName as ie, isWelcomeOnlyMessages as fe, parseSessionMessages as ne, toDisplayMessages as me } from "./components/AgentHub/Chat/utils/sessionMessages.js";
|
|
47
|
+
import { hasCitationMarkers as le, normalizeAssistantMarkdown as ue, normalizeDisplayText as de, parseAssistantContent as xe } from "./components/AgentHub/Chat/utils/messageContent.js";
|
|
48
|
+
import { sanitizeMermaidChart as ce, stripProseFromMermaid as ge } from "./components/AgentHub/Chat/utils/sanitizeMermaidChart.js";
|
|
49
|
+
import { useAutoScrollToBottom as Me } from "./components/AgentHub/Chat/hooks/useAutoScrollToBottom.js";
|
|
50
|
+
import { useChat as Te } from "./components/AgentHub/Chat/hooks/useChat.js";
|
|
51
|
+
import { useChatSessions as Ae } from "./components/AgentHub/Chat/hooks/useChatSessions.js";
|
|
52
|
+
import { useCitationPanel as Fe } from "./components/AgentHub/Chat/hooks/useCitationPanel.js";
|
|
53
|
+
import { useKBDocuments as De } from "./components/AgentHub/KnowledgeBase/hooks/useKBDocuments.js";
|
|
54
|
+
import { useKnowledgeBase as ke } from "./components/AgentHub/KnowledgeBase/hooks/useKnowledgeBase.js";
|
|
55
|
+
import { useSSECompletion as Ee } from "./components/AgentHub/Chat/hooks/useSSECompletion.js";
|
|
56
|
+
import { useTypewriter as Oe } from "./components/AgentHub/Chat/hooks/useTypewriter.js";
|
|
57
|
+
export {
|
|
58
|
+
o as AgentHubAccessGuard,
|
|
59
|
+
r as AgentHubIndexRedirect,
|
|
60
|
+
i as AgentHubSessionAccessGuard,
|
|
61
|
+
Nt as CHUNK_METHOD_OPTIONS,
|
|
62
|
+
Ht as CITATION_LINK_PREFIX,
|
|
63
|
+
n as ChatAgentFab,
|
|
64
|
+
p as ChatAgentFabLayout,
|
|
65
|
+
u as ChatAssistantForm,
|
|
66
|
+
x as ChatCard,
|
|
67
|
+
c as ChatCreateButton,
|
|
68
|
+
S as ChatFilterBar,
|
|
69
|
+
B as ChatFollowUpSuggestions,
|
|
70
|
+
h as ChatFormModal,
|
|
71
|
+
I as ChatInput,
|
|
72
|
+
P as ChatManageActionButtons,
|
|
73
|
+
R as ChatPanel,
|
|
74
|
+
w as ChatSuggestionRow,
|
|
75
|
+
N as ChatWidgetBlock,
|
|
76
|
+
b as CitationContent,
|
|
77
|
+
H as CitationInlineBadge,
|
|
78
|
+
_ as CitationMarkdownContent,
|
|
79
|
+
z as CitationPanel,
|
|
80
|
+
G as CreateButton,
|
|
81
|
+
W as DocumentTable,
|
|
82
|
+
Ot as EMBEDDING_MODEL_OPTIONS,
|
|
83
|
+
q as KBFilterBar,
|
|
84
|
+
X as KBFormModal,
|
|
85
|
+
Q as KnowledgeBaseForm,
|
|
86
|
+
Z as KnowledgeCard,
|
|
87
|
+
tt as ManageActionButtons,
|
|
88
|
+
ot as MermaidBlock,
|
|
89
|
+
rt as MessageActions,
|
|
90
|
+
it as MessageEditPopover,
|
|
91
|
+
nt as MessageItem,
|
|
92
|
+
bt as PARSE_STATUS_CONFIG,
|
|
93
|
+
pt as ParseStatusTag,
|
|
94
|
+
ut as ReportArchiveModal,
|
|
95
|
+
xt as ReportExportLayout,
|
|
96
|
+
ct as ReportHtmlPreview,
|
|
97
|
+
St as ReportMetaStrip,
|
|
98
|
+
Bt as ReportTemplate,
|
|
99
|
+
ht as ReportVersionList,
|
|
100
|
+
It as ReportWorkspace,
|
|
101
|
+
Pt as SessionActionButtons,
|
|
102
|
+
Rt as SessionSidebar,
|
|
103
|
+
wt as ThinkingSection,
|
|
104
|
+
te as animateScrollFromTopToBottom,
|
|
105
|
+
ee as animateScrollTo,
|
|
106
|
+
Kt as citationDisplayNumber,
|
|
107
|
+
_t as citationIdToIndex,
|
|
108
|
+
Lt as countUniqueCitedSources,
|
|
109
|
+
zt as detectCitationIdBase,
|
|
110
|
+
vt as extractCitationIdsFromContent,
|
|
111
|
+
Gt as extractCitationTitle,
|
|
112
|
+
re as extractCitations,
|
|
113
|
+
Ut as formatCitationDocBasename,
|
|
114
|
+
Wt as formatCitationMeta,
|
|
115
|
+
jt as formatCitationPositions,
|
|
116
|
+
se as formatSessionTime,
|
|
117
|
+
oe as getScrollBottom,
|
|
118
|
+
ie as getSessionDisplayName,
|
|
119
|
+
le as hasCitationMarkers,
|
|
120
|
+
qt as injectCitationMarkdownLinks,
|
|
121
|
+
fe as isWelcomeOnlyMessages,
|
|
122
|
+
ue as normalizeAssistantMarkdown,
|
|
123
|
+
Vt as normalizeCitation,
|
|
124
|
+
de as normalizeDisplayText,
|
|
125
|
+
xe as parseAssistantContent,
|
|
126
|
+
Xt as parseCitationLinkHref,
|
|
127
|
+
ne as parseSessionMessages,
|
|
128
|
+
Jt as prepareCitationContent,
|
|
129
|
+
Qt as resolveCitationTitle,
|
|
130
|
+
Yt as sanitizeCitationHtml,
|
|
131
|
+
ce as sanitizeMermaidChart,
|
|
132
|
+
Zt as stripCitationFrontmatter,
|
|
133
|
+
ge as stripProseFromMermaid,
|
|
134
|
+
me as toDisplayMessages,
|
|
135
|
+
Me as useAutoScrollToBottom,
|
|
136
|
+
Te as useChat,
|
|
137
|
+
Ae as useChatSessions,
|
|
138
|
+
Fe as useCitationPanel,
|
|
139
|
+
De as useKBDocuments,
|
|
140
|
+
ke as useKnowledgeBase,
|
|
141
|
+
Ee as useSSECompletion,
|
|
142
|
+
Oe as useTypewriter
|
|
143
|
+
};
|
|
144
|
+
//# sourceMappingURL=agent-hub.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agent-hub.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as t } from "react/jsx-runtime";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
const n = ({ onClick: o }) => /* @__PURE__ */ t(
|
|
2
|
+
import { Button as r } from "antd";
|
|
3
|
+
import { Plus as m } from "../../../Icons/Plus.js";
|
|
4
|
+
const n = ({ onClick: o }) => /* @__PURE__ */ t(r, { type: "primary", icon: /* @__PURE__ */ t(m, {}), onClick: o, children: "新建助手" });
|
|
5
5
|
export {
|
|
6
6
|
n as default
|
|
7
7
|
};
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
-
import
|
|
3
|
-
import i from "
|
|
2
|
+
import r from "@kne/button-group";
|
|
3
|
+
import { Plus as i } from "../../../Icons/Plus.js";
|
|
4
4
|
const s = ({ onCreateClick: t }) => /* @__PURE__ */ o(
|
|
5
|
-
|
|
5
|
+
r,
|
|
6
6
|
{
|
|
7
7
|
list: [
|
|
8
8
|
{
|
|
9
9
|
children: "新建助手",
|
|
10
10
|
type: "primary",
|
|
11
|
-
icon: /* @__PURE__ */ o(
|
|
11
|
+
icon: /* @__PURE__ */ o(i, {}),
|
|
12
12
|
onClick: t
|
|
13
13
|
}
|
|
14
14
|
]
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
-
import
|
|
3
|
-
import n from "
|
|
2
|
+
import r from "@kne/button-group";
|
|
3
|
+
import { Trash2 as n } from "../../../Icons/Trash2.js";
|
|
4
4
|
const f = ({
|
|
5
5
|
streaming: t = !1,
|
|
6
6
|
clearDisabled: s = !1,
|
|
7
7
|
onClearConversation: i
|
|
8
8
|
}) => /* @__PURE__ */ o(
|
|
9
|
-
|
|
9
|
+
r,
|
|
10
10
|
{
|
|
11
11
|
list: [
|
|
12
12
|
{
|
|
13
13
|
children: "清空对话",
|
|
14
|
-
icon: /* @__PURE__ */ o(
|
|
14
|
+
icon: /* @__PURE__ */ o(n, {}),
|
|
15
15
|
disabled: t || s,
|
|
16
16
|
onClick: i
|
|
17
17
|
}
|
|
@@ -1,22 +1,24 @@
|
|
|
1
|
-
import { jsxs as t, jsx as
|
|
2
|
-
import { ChevronUp as w, ChevronDown as g, MessageCircle as N } from "../../../../Icons/index.js";
|
|
1
|
+
import { jsxs as t, jsx as o } from "react/jsx-runtime";
|
|
3
2
|
import n from "classnames";
|
|
4
|
-
import { useState as
|
|
3
|
+
import { useState as w } from "react";
|
|
5
4
|
import l from "./style.module.scss.js";
|
|
6
|
-
import
|
|
7
|
-
|
|
5
|
+
import { ChevronUp as g } from "../../../../Icons/ChevronUp.js";
|
|
6
|
+
import { ChevronDown as N } from "../../../../Icons/ChevronDown.js";
|
|
7
|
+
import C from "../../../../VirtualScrollbar/VirtualScrollbar/index.js";
|
|
8
|
+
import { MessageCircle as x } from "../../../../Icons/MessageCircle.js";
|
|
9
|
+
const $ = ({
|
|
8
10
|
items: s,
|
|
9
11
|
onSelect: i,
|
|
10
12
|
title: c = "推荐追问",
|
|
11
|
-
className:
|
|
12
|
-
maxListHeight:
|
|
13
|
-
collapsible:
|
|
13
|
+
className: p,
|
|
14
|
+
maxListHeight: u = 132,
|
|
15
|
+
collapsible: e = !0,
|
|
14
16
|
defaultExpanded: h = !0
|
|
15
17
|
}) => {
|
|
16
|
-
const [r,
|
|
18
|
+
const [r, m] = w(h);
|
|
17
19
|
if (!s.length) return null;
|
|
18
|
-
const
|
|
19
|
-
|
|
20
|
+
const d = () => {
|
|
21
|
+
e && m((a) => !a);
|
|
20
22
|
};
|
|
21
23
|
return /* @__PURE__ */ t(
|
|
22
24
|
"div",
|
|
@@ -24,7 +26,7 @@ const E = ({
|
|
|
24
26
|
className: n(
|
|
25
27
|
"chat-followup-suggestions",
|
|
26
28
|
l["chat-followup-suggestions"],
|
|
27
|
-
|
|
29
|
+
p
|
|
28
30
|
),
|
|
29
31
|
children: [
|
|
30
32
|
c ? /* @__PURE__ */ t(
|
|
@@ -33,39 +35,39 @@ const E = ({
|
|
|
33
35
|
type: "button",
|
|
34
36
|
className: n(
|
|
35
37
|
l["chat-followup-header"],
|
|
36
|
-
|
|
38
|
+
e && l["chat-followup-header--collapsible"]
|
|
37
39
|
),
|
|
38
|
-
onClick:
|
|
40
|
+
onClick: d,
|
|
39
41
|
"aria-expanded": r,
|
|
40
|
-
disabled: !
|
|
42
|
+
disabled: !e,
|
|
41
43
|
children: [
|
|
42
44
|
/* @__PURE__ */ t("span", { className: l["chat-followup-title"], children: [
|
|
43
45
|
c,
|
|
44
|
-
/* @__PURE__ */
|
|
46
|
+
/* @__PURE__ */ o("span", { className: l["chat-followup-count"], children: s.length })
|
|
45
47
|
] }),
|
|
46
|
-
|
|
48
|
+
e ? r ? /* @__PURE__ */ o(g, { className: l["chat-followup-toggle"], "aria-hidden": !0 }) : /* @__PURE__ */ o(N, { className: l["chat-followup-toggle"], "aria-hidden": !0 }) : null
|
|
47
49
|
]
|
|
48
50
|
}
|
|
49
51
|
) : null,
|
|
50
|
-
r ? /* @__PURE__ */
|
|
51
|
-
|
|
52
|
+
r ? /* @__PURE__ */ o(
|
|
53
|
+
C,
|
|
52
54
|
{
|
|
53
55
|
wrapperClassName: l["chat-followup-list-scroll-wrapper"],
|
|
54
|
-
style: { maxHeight:
|
|
56
|
+
style: { maxHeight: u },
|
|
55
57
|
className: l["chat-followup-list-scroll"],
|
|
56
|
-
children: /* @__PURE__ */
|
|
58
|
+
children: /* @__PURE__ */ o("div", { className: l["chat-followup-list"], children: s.map((a, f) => /* @__PURE__ */ t(
|
|
57
59
|
"button",
|
|
58
60
|
{
|
|
59
61
|
type: "button",
|
|
60
62
|
className: l["chat-followup-item"],
|
|
61
|
-
title:
|
|
62
|
-
onClick: () => i(
|
|
63
|
+
title: a,
|
|
64
|
+
onClick: () => i(a),
|
|
63
65
|
children: [
|
|
64
|
-
/* @__PURE__ */
|
|
65
|
-
/* @__PURE__ */
|
|
66
|
+
/* @__PURE__ */ o(x, { className: l["chat-followup-icon"], "aria-hidden": !0 }),
|
|
67
|
+
/* @__PURE__ */ o("span", { className: l["chat-followup-text"], children: a })
|
|
66
68
|
]
|
|
67
69
|
},
|
|
68
|
-
`${f}-${
|
|
70
|
+
`${f}-${a.slice(0, 24)}`
|
|
69
71
|
)) })
|
|
70
72
|
}
|
|
71
73
|
) : null
|
|
@@ -74,6 +76,6 @@ const E = ({
|
|
|
74
76
|
);
|
|
75
77
|
};
|
|
76
78
|
export {
|
|
77
|
-
|
|
79
|
+
$ as default
|
|
78
80
|
};
|
|
79
81
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../../../../src/components/AgentHub/Chat/Detail/ChatFollowUpSuggestions/index.tsx"],"sourcesContent":["import { ChevronDown, ChevronUp, MessageCircle } from '@/components/Icons';\nimport { VirtualScrollbar } from '@/components/VirtualScrollbar';\nimport classNames from 'classnames';\nimport { useState } from 'react';\nimport styles from './style.module.scss';\n\nexport interface ChatFollowUpSuggestionsProps {\n items: string[];\n onSelect: (text: string) => void;\n title?: string;\n className?: string;\n /** 列表区最大高度,超出后纵向滚动 */\n maxListHeight?: number;\n /** 是否可折叠,默认 true */\n collapsible?: boolean;\n /** 初始展开状态 */\n defaultExpanded?: boolean;\n}\n\nconst ChatFollowUpSuggestions: React.FC<ChatFollowUpSuggestionsProps> = ({\n items,\n onSelect,\n title = '推荐追问',\n className,\n maxListHeight = 132,\n collapsible = true,\n defaultExpanded = true,\n}) => {\n const [expanded, setExpanded] = useState(defaultExpanded);\n\n if (!items.length) return null;\n\n const toggleExpanded = () => {\n if (!collapsible) return;\n setExpanded((prev) => !prev);\n };\n\n return (\n <div\n className={classNames(\n 'chat-followup-suggestions',\n styles['chat-followup-suggestions'],\n className,\n )}\n >\n {title ? (\n <button\n type=\"button\"\n className={classNames(\n styles['chat-followup-header'],\n collapsible && styles['chat-followup-header--collapsible'],\n )}\n onClick={toggleExpanded}\n aria-expanded={expanded}\n disabled={!collapsible}\n >\n <span className={styles['chat-followup-title']}>\n {title}\n <span className={styles['chat-followup-count']}>{items.length}</span>\n </span>\n {collapsible ? (\n expanded ? (\n <ChevronUp className={styles['chat-followup-toggle']} aria-hidden />\n ) : (\n <ChevronDown className={styles['chat-followup-toggle']} aria-hidden />\n )\n ) : null}\n </button>\n ) : null}\n\n {expanded ? (\n <VirtualScrollbar\n wrapperClassName={styles['chat-followup-list-scroll-wrapper']}\n style={{ maxHeight: maxListHeight }}\n className={styles['chat-followup-list-scroll']}\n >\n <div className={styles['chat-followup-list']}>\n {items.map((text, index) => (\n <button\n key={`${index}-${text.slice(0, 24)}`}\n type=\"button\"\n className={styles['chat-followup-item']}\n title={text}\n onClick={() => onSelect(text)}\n >\n <MessageCircle className={styles['chat-followup-icon']} aria-hidden />\n <span className={styles['chat-followup-text']}>{text}</span>\n </button>\n ))}\n </div>\n </VirtualScrollbar>\n ) : null}\n </div>\n );\n};\n\nexport default ChatFollowUpSuggestions;\n"],"names":["ChatFollowUpSuggestions","items","onSelect","title","className","maxListHeight","collapsible","defaultExpanded","expanded","setExpanded","useState","toggleExpanded","prev","jsxs","classNames","styles","jsx","ChevronUp","ChevronDown","VirtualScrollbar","text","index","MessageCircle"],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../../../../src/components/AgentHub/Chat/Detail/ChatFollowUpSuggestions/index.tsx"],"sourcesContent":["import { ChevronDown, ChevronUp, MessageCircle } from '@/components/Icons';\nimport { VirtualScrollbar } from '@/components/VirtualScrollbar';\nimport classNames from 'classnames';\nimport { useState } from 'react';\nimport styles from './style.module.scss';\n\nexport interface ChatFollowUpSuggestionsProps {\n items: string[];\n onSelect: (text: string) => void;\n title?: string;\n className?: string;\n /** 列表区最大高度,超出后纵向滚动 */\n maxListHeight?: number;\n /** 是否可折叠,默认 true */\n collapsible?: boolean;\n /** 初始展开状态 */\n defaultExpanded?: boolean;\n}\n\nconst ChatFollowUpSuggestions: React.FC<ChatFollowUpSuggestionsProps> = ({\n items,\n onSelect,\n title = '推荐追问',\n className,\n maxListHeight = 132,\n collapsible = true,\n defaultExpanded = true,\n}) => {\n const [expanded, setExpanded] = useState(defaultExpanded);\n\n if (!items.length) return null;\n\n const toggleExpanded = () => {\n if (!collapsible) return;\n setExpanded((prev) => !prev);\n };\n\n return (\n <div\n className={classNames(\n 'chat-followup-suggestions',\n styles['chat-followup-suggestions'],\n className,\n )}\n >\n {title ? (\n <button\n type=\"button\"\n className={classNames(\n styles['chat-followup-header'],\n collapsible && styles['chat-followup-header--collapsible'],\n )}\n onClick={toggleExpanded}\n aria-expanded={expanded}\n disabled={!collapsible}\n >\n <span className={styles['chat-followup-title']}>\n {title}\n <span className={styles['chat-followup-count']}>{items.length}</span>\n </span>\n {collapsible ? (\n expanded ? (\n <ChevronUp className={styles['chat-followup-toggle']} aria-hidden />\n ) : (\n <ChevronDown className={styles['chat-followup-toggle']} aria-hidden />\n )\n ) : null}\n </button>\n ) : null}\n\n {expanded ? (\n <VirtualScrollbar\n wrapperClassName={styles['chat-followup-list-scroll-wrapper']}\n style={{ maxHeight: maxListHeight }}\n className={styles['chat-followup-list-scroll']}\n >\n <div className={styles['chat-followup-list']}>\n {items.map((text, index) => (\n <button\n key={`${index}-${text.slice(0, 24)}`}\n type=\"button\"\n className={styles['chat-followup-item']}\n title={text}\n onClick={() => onSelect(text)}\n >\n <MessageCircle className={styles['chat-followup-icon']} aria-hidden />\n <span className={styles['chat-followup-text']}>{text}</span>\n </button>\n ))}\n </div>\n </VirtualScrollbar>\n ) : null}\n </div>\n );\n};\n\nexport default ChatFollowUpSuggestions;\n"],"names":["ChatFollowUpSuggestions","items","onSelect","title","className","maxListHeight","collapsible","defaultExpanded","expanded","setExpanded","useState","toggleExpanded","prev","jsxs","classNames","styles","jsx","ChevronUp","ChevronDown","VirtualScrollbar","text","index","MessageCircle"],"mappings":";;;;;;;;AAmBA,MAAMA,IAAkE,CAAC;AAAA,EACvE,OAAAC;AAAA,EACA,UAAAC;AAAA,EACA,OAAAC,IAAQ;AAAA,EACR,WAAAC;AAAA,EACA,eAAAC,IAAgB;AAAA,EAChB,aAAAC,IAAc;AAAA,EACd,iBAAAC,IAAkB;AACpB,MAAM;AACJ,QAAM,CAACC,GAAUC,CAAW,IAAIC,EAASH,CAAe;AAExD,MAAI,CAACN,EAAM,OAAQ,QAAO;AAE1B,QAAMU,IAAiB,MAAM;AAC3B,IAAKL,KACLG,EAAY,CAACG,MAAS,CAACA,CAAI;AAAA,EAC7B;AAEA,SACE,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,WAAWC;AAAA,QACT;AAAA,QACAC,EAAO,2BAA2B;AAAA,QAClCX;AAAA,MAAA;AAAA,MAGD,UAAA;AAAA,QAAAD,IACC,gBAAAU;AAAA,UAAC;AAAA,UAAA;AAAA,YACC,MAAK;AAAA,YACL,WAAWC;AAAA,cACTC,EAAO,sBAAsB;AAAA,cAC7BT,KAAeS,EAAO,mCAAmC;AAAA,YAAA;AAAA,YAE3D,SAASJ;AAAA,YACT,iBAAeH;AAAA,YACf,UAAU,CAACF;AAAA,YAEX,UAAA;AAAA,cAAA,gBAAAO,EAAC,QAAA,EAAK,WAAWE,EAAO,qBAAqB,GAC1C,UAAA;AAAA,gBAAAZ;AAAA,kCACA,QAAA,EAAK,WAAWY,EAAO,qBAAqB,GAAI,YAAM,OAAA,CAAO;AAAA,cAAA,GAChE;AAAA,cACCT,IACCE,IACE,gBAAAQ,EAACC,KAAU,WAAWF,EAAO,sBAAsB,GAAG,eAAW,IAAC,IAElE,gBAAAC,EAACE,KAAY,WAAWH,EAAO,sBAAsB,GAAG,eAAW,IAAC,IAEpE;AAAA,YAAA;AAAA,UAAA;AAAA,QAAA,IAEJ;AAAA,QAEHP,IACC,gBAAAQ;AAAA,UAACG;AAAA,UAAA;AAAA,YACC,kBAAkBJ,EAAO,mCAAmC;AAAA,YAC5D,OAAO,EAAE,WAAWV,EAAA;AAAA,YACpB,WAAWU,EAAO,2BAA2B;AAAA,YAE7C,UAAA,gBAAAC,EAAC,OAAA,EAAI,WAAWD,EAAO,oBAAoB,GACxC,UAAAd,EAAM,IAAI,CAACmB,GAAMC,MAChB,gBAAAR;AAAA,cAAC;AAAA,cAAA;AAAA,gBAEC,MAAK;AAAA,gBACL,WAAWE,EAAO,oBAAoB;AAAA,gBACtC,OAAOK;AAAA,gBACP,SAAS,MAAMlB,EAASkB,CAAI;AAAA,gBAE5B,UAAA;AAAA,kBAAA,gBAAAJ,EAACM,KAAc,WAAWP,EAAO,oBAAoB,GAAG,eAAW,IAAC;AAAA,oCACnE,QAAA,EAAK,WAAWA,EAAO,oBAAoB,GAAI,UAAAK,EAAA,CAAK;AAAA,gBAAA;AAAA,cAAA;AAAA,cAPhD,GAAGC,CAAK,IAAID,EAAK,MAAM,GAAG,EAAE,CAAC;AAAA,YAAA,CASrC,EAAA,CACH;AAAA,UAAA;AAAA,QAAA,IAEA;AAAA,MAAA;AAAA,IAAA;AAAA,EAAA;AAGV;"}
|
|
@@ -1,21 +1,22 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import {
|
|
3
|
-
import { Input as y, Button as p } from "antd";
|
|
1
|
+
import { jsxs as i, jsx as n } from "react/jsx-runtime";
|
|
2
|
+
import { Input as u, Button as o } from "antd";
|
|
4
3
|
import t from "./style.module.scss.js";
|
|
5
4
|
import a from "classnames";
|
|
6
|
-
|
|
5
|
+
import { Pause as f } from "../../../../Icons/Pause.js";
|
|
6
|
+
import { Send as y } from "../../../../Icons/Send.js";
|
|
7
|
+
const g = ({
|
|
7
8
|
value: e,
|
|
8
9
|
loading: c,
|
|
9
|
-
onChange:
|
|
10
|
+
onChange: p,
|
|
10
11
|
onSend: s,
|
|
11
12
|
onStop: h,
|
|
12
13
|
placeholder: m = "输入问题… Enter 发送,Shift+Enter 换行",
|
|
13
14
|
embedded: d = !1
|
|
14
15
|
}) => {
|
|
15
|
-
const l = (
|
|
16
|
-
|
|
16
|
+
const l = (r) => {
|
|
17
|
+
r.key === "Enter" && !r.shiftKey && (r.preventDefault(), !c && e.trim() && s());
|
|
17
18
|
};
|
|
18
|
-
return /* @__PURE__ */
|
|
19
|
+
return /* @__PURE__ */ i(
|
|
19
20
|
"div",
|
|
20
21
|
{
|
|
21
22
|
className: a(
|
|
@@ -24,12 +25,12 @@ const C = ({
|
|
|
24
25
|
d && t["chat-input-root--embedded"]
|
|
25
26
|
),
|
|
26
27
|
children: [
|
|
27
|
-
/* @__PURE__ */
|
|
28
|
+
/* @__PURE__ */ i("div", { className: a("chat-input-container", t["chat-input-container"]), children: [
|
|
28
29
|
/* @__PURE__ */ n(
|
|
29
|
-
|
|
30
|
+
u.TextArea,
|
|
30
31
|
{
|
|
31
32
|
value: e,
|
|
32
|
-
onChange: (
|
|
33
|
+
onChange: (r) => p(r.target.value),
|
|
33
34
|
onKeyDown: l,
|
|
34
35
|
placeholder: m,
|
|
35
36
|
autoSize: { minRows: 1, maxRows: 5 },
|
|
@@ -39,29 +40,29 @@ const C = ({
|
|
|
39
40
|
}
|
|
40
41
|
),
|
|
41
42
|
c ? /* @__PURE__ */ n(
|
|
42
|
-
|
|
43
|
+
o,
|
|
43
44
|
{
|
|
44
45
|
type: "primary",
|
|
45
46
|
danger: !0,
|
|
46
|
-
icon: /* @__PURE__ */ n(
|
|
47
|
+
icon: /* @__PURE__ */ n(f, {}),
|
|
47
48
|
onClick: h,
|
|
48
49
|
"aria-label": "停止生成",
|
|
49
50
|
className: a("chat-input-inner", t["chat-input-inner"])
|
|
50
51
|
}
|
|
51
52
|
) : /* @__PURE__ */ n(
|
|
52
|
-
|
|
53
|
+
o,
|
|
53
54
|
{
|
|
54
55
|
type: "primary",
|
|
55
|
-
icon: /* @__PURE__ */ n(
|
|
56
|
+
icon: /* @__PURE__ */ n(y, {}),
|
|
56
57
|
onClick: s,
|
|
57
58
|
disabled: !e.trim(),
|
|
58
59
|
className: a("chat-input-inner", t["chat-input-inner"])
|
|
59
60
|
}
|
|
60
61
|
)
|
|
61
62
|
] }),
|
|
62
|
-
/* @__PURE__ */
|
|
63
|
+
/* @__PURE__ */ i("div", { className: a("chat-input-header", t["chat-input-header"]), children: [
|
|
63
64
|
/* @__PURE__ */ n("span", { className: a("chat-input-body", t["chat-input-body"]), children: "Enter 发送 · Shift+Enter 换行" }),
|
|
64
|
-
e.length > 0 && /* @__PURE__ */
|
|
65
|
+
e.length > 0 && /* @__PURE__ */ i("span", { className: a("chat-input-body", t["chat-input-body"]), children: [
|
|
65
66
|
e.length,
|
|
66
67
|
" 字"
|
|
67
68
|
] })
|
|
@@ -71,6 +72,6 @@ const C = ({
|
|
|
71
72
|
);
|
|
72
73
|
};
|
|
73
74
|
export {
|
|
74
|
-
|
|
75
|
+
g as default
|
|
75
76
|
};
|
|
76
77
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../../../../src/components/AgentHub/Chat/Detail/ChatInput/index.tsx"],"sourcesContent":["import { Pause, Send } from '@/components/Icons';\nimport { Button, Input } from 'antd';\nimport React from 'react';\nimport styles from './style.module.scss';\nimport classNames from 'classnames';\n\nexport interface ChatInputProps {\n value: string;\n loading: boolean;\n onChange: (v: string) => void;\n onSend: () => void;\n onStop?: () => void;\n placeholder?: string;\n /** 嵌入 ChatPanel 时去掉外层 border/padding,避免与 chat-panel-input 重复 */\n embedded?: boolean;\n}\n\nconst ChatInput: React.FC<ChatInputProps> = ({\n value,\n loading,\n onChange,\n onSend,\n onStop,\n placeholder = '输入问题… Enter 发送,Shift+Enter 换行',\n embedded = false,\n}) => {\n const handleKeyDown = (e: React.KeyboardEvent<HTMLTextAreaElement>) => {\n if (e.key === 'Enter' && !e.shiftKey) {\n e.preventDefault();\n if (!loading && value.trim()) {\n onSend();\n }\n }\n };\n\n return (\n <div\n className={classNames(\n 'chat-input-root',\n styles['chat-input-root'],\n embedded && styles['chat-input-root--embedded'],\n )}\n >\n <div className={classNames('chat-input-container', styles['chat-input-container'])}>\n <Input.TextArea\n value={value}\n onChange={(e) => onChange(e.target.value)}\n onKeyDown={handleKeyDown}\n placeholder={placeholder}\n autoSize={{ minRows: 1, maxRows: 5 }}\n disabled={loading}\n variant=\"borderless\"\n className={classNames('chat-input-wrapper', styles['chat-input-wrapper'])}\n />\n\n {loading ? (\n <Button\n type=\"primary\"\n danger\n icon={<Pause />}\n onClick={onStop}\n aria-label=\"停止生成\"\n className={classNames('chat-input-inner', styles['chat-input-inner'])}\n />\n ) : (\n <Button\n type=\"primary\"\n icon={<Send />}\n onClick={onSend}\n disabled={!value.trim()}\n className={classNames('chat-input-inner', styles['chat-input-inner'])}\n />\n )}\n </div>\n\n <div className={classNames('chat-input-header', styles['chat-input-header'])}>\n <span className={classNames('chat-input-body', styles['chat-input-body'])}>\n Enter 发送 · Shift+Enter 换行\n </span>\n {value.length > 0 && (\n <span className={classNames('chat-input-body', styles['chat-input-body'])}>\n {value.length} 字\n </span>\n )}\n </div>\n </div>\n );\n};\n\nexport default ChatInput;\n"],"names":["ChatInput","value","loading","onChange","onSend","onStop","placeholder","embedded","handleKeyDown","e","jsxs","classNames","styles","jsx","Input","Button","Pause","Send"],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../../../../src/components/AgentHub/Chat/Detail/ChatInput/index.tsx"],"sourcesContent":["import { Pause, Send } from '@/components/Icons';\nimport { Button, Input } from 'antd';\nimport React from 'react';\nimport styles from './style.module.scss';\nimport classNames from 'classnames';\n\nexport interface ChatInputProps {\n value: string;\n loading: boolean;\n onChange: (v: string) => void;\n onSend: () => void;\n onStop?: () => void;\n placeholder?: string;\n /** 嵌入 ChatPanel 时去掉外层 border/padding,避免与 chat-panel-input 重复 */\n embedded?: boolean;\n}\n\nconst ChatInput: React.FC<ChatInputProps> = ({\n value,\n loading,\n onChange,\n onSend,\n onStop,\n placeholder = '输入问题… Enter 发送,Shift+Enter 换行',\n embedded = false,\n}) => {\n const handleKeyDown = (e: React.KeyboardEvent<HTMLTextAreaElement>) => {\n if (e.key === 'Enter' && !e.shiftKey) {\n e.preventDefault();\n if (!loading && value.trim()) {\n onSend();\n }\n }\n };\n\n return (\n <div\n className={classNames(\n 'chat-input-root',\n styles['chat-input-root'],\n embedded && styles['chat-input-root--embedded'],\n )}\n >\n <div className={classNames('chat-input-container', styles['chat-input-container'])}>\n <Input.TextArea\n value={value}\n onChange={(e) => onChange(e.target.value)}\n onKeyDown={handleKeyDown}\n placeholder={placeholder}\n autoSize={{ minRows: 1, maxRows: 5 }}\n disabled={loading}\n variant=\"borderless\"\n className={classNames('chat-input-wrapper', styles['chat-input-wrapper'])}\n />\n\n {loading ? (\n <Button\n type=\"primary\"\n danger\n icon={<Pause />}\n onClick={onStop}\n aria-label=\"停止生成\"\n className={classNames('chat-input-inner', styles['chat-input-inner'])}\n />\n ) : (\n <Button\n type=\"primary\"\n icon={<Send />}\n onClick={onSend}\n disabled={!value.trim()}\n className={classNames('chat-input-inner', styles['chat-input-inner'])}\n />\n )}\n </div>\n\n <div className={classNames('chat-input-header', styles['chat-input-header'])}>\n <span className={classNames('chat-input-body', styles['chat-input-body'])}>\n Enter 发送 · Shift+Enter 换行\n </span>\n {value.length > 0 && (\n <span className={classNames('chat-input-body', styles['chat-input-body'])}>\n {value.length} 字\n </span>\n )}\n </div>\n </div>\n );\n};\n\nexport default ChatInput;\n"],"names":["ChatInput","value","loading","onChange","onSend","onStop","placeholder","embedded","handleKeyDown","e","jsxs","classNames","styles","jsx","Input","Button","Pause","Send"],"mappings":";;;;;;AAiBA,MAAMA,IAAsC,CAAC;AAAA,EAC3C,OAAAC;AAAA,EACA,SAAAC;AAAA,EACA,UAAAC;AAAA,EACA,QAAAC;AAAA,EACA,QAAAC;AAAA,EACA,aAAAC,IAAc;AAAA,EACd,UAAAC,IAAW;AACb,MAAM;AACJ,QAAMC,IAAgB,CAACC,MAAgD;AACrE,IAAIA,EAAE,QAAQ,WAAW,CAACA,EAAE,aAC1BA,EAAE,eAAA,GACE,CAACP,KAAWD,EAAM,UACpBG,EAAA;AAAA,EAGN;AAEA,SACE,gBAAAM;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,WAAWC;AAAA,QACT;AAAA,QACAC,EAAO,iBAAiB;AAAA,QACxBL,KAAYK,EAAO,2BAA2B;AAAA,MAAA;AAAA,MAGhD,UAAA;AAAA,QAAA,gBAAAF,EAAC,SAAI,WAAWC,EAAW,wBAAwBC,EAAO,sBAAsB,CAAC,GAC/E,UAAA;AAAA,UAAA,gBAAAC;AAAA,YAACC,EAAM;AAAA,YAAN;AAAA,cACC,OAAAb;AAAA,cACA,UAAU,CAACQ,MAAMN,EAASM,EAAE,OAAO,KAAK;AAAA,cACxC,WAAWD;AAAA,cACX,aAAAF;AAAA,cACA,UAAU,EAAE,SAAS,GAAG,SAAS,EAAA;AAAA,cACjC,UAAUJ;AAAA,cACV,SAAQ;AAAA,cACR,WAAWS,EAAW,sBAAsBC,EAAO,oBAAoB,CAAC;AAAA,YAAA;AAAA,UAAA;AAAA,UAGzEV,IACC,gBAAAW;AAAA,YAACE;AAAA,YAAA;AAAA,cACC,MAAK;AAAA,cACL,QAAM;AAAA,cACN,wBAAOC,GAAA,EAAM;AAAA,cACb,SAASX;AAAA,cACT,cAAW;AAAA,cACX,WAAWM,EAAW,oBAAoBC,EAAO,kBAAkB,CAAC;AAAA,YAAA;AAAA,UAAA,IAGtE,gBAAAC;AAAA,YAACE;AAAA,YAAA;AAAA,cACC,MAAK;AAAA,cACL,wBAAOE,GAAA,EAAK;AAAA,cACZ,SAASb;AAAA,cACT,UAAU,CAACH,EAAM,KAAA;AAAA,cACjB,WAAWU,EAAW,oBAAoBC,EAAO,kBAAkB,CAAC;AAAA,YAAA;AAAA,UAAA;AAAA,QACtE,GAEJ;AAAA,QAEA,gBAAAF,EAAC,SAAI,WAAWC,EAAW,qBAAqBC,EAAO,mBAAmB,CAAC,GACzE,UAAA;AAAA,UAAA,gBAAAC,EAAC,QAAA,EAAK,WAAWF,EAAW,mBAAmBC,EAAO,iBAAiB,CAAC,GAAG,UAAA,4BAAA,CAE3E;AAAA,UACCX,EAAM,SAAS,KACd,gBAAAS,EAAC,QAAA,EAAK,WAAWC,EAAW,mBAAmBC,EAAO,iBAAiB,CAAC,GACrE,UAAA;AAAA,YAAAX,EAAM;AAAA,YAAO;AAAA,UAAA,EAAA,CAChB;AAAA,QAAA,EAAA,CAEJ;AAAA,MAAA;AAAA,IAAA;AAAA,EAAA;AAGN;"}
|
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
import { jsxs as l, jsx as a } from "react/jsx-runtime";
|
|
2
|
-
import {
|
|
3
|
-
import { Button as b, Empty as f } from "antd";
|
|
2
|
+
import { Button as N, Empty as f } from "antd";
|
|
4
3
|
import i from "classnames";
|
|
5
|
-
import
|
|
6
|
-
import
|
|
4
|
+
import y, { useState as b, useRef as C, useEffect as E, useCallback as v } from "react";
|
|
5
|
+
import k from "../CitationContent/index.js";
|
|
7
6
|
import t from "./style.module.scss.js";
|
|
8
|
-
import
|
|
9
|
-
import
|
|
7
|
+
import { X as x } from "../../../../Icons/X.js";
|
|
8
|
+
import S from "../../../../VirtualScrollbar/VirtualScrollbar/index.js";
|
|
9
|
+
import { formatCitationMeta as w, resolveCitationTitle as D } from "../../utils/citationContent.js";
|
|
10
|
+
import { ChevronDown as R } from "../../../../Icons/ChevronDown.js";
|
|
10
11
|
const q = ({
|
|
11
12
|
citation: o,
|
|
12
13
|
index: c,
|
|
@@ -15,7 +16,7 @@ const q = ({
|
|
|
15
16
|
onToggle: p,
|
|
16
17
|
itemRef: d
|
|
17
18
|
}) => {
|
|
18
|
-
const h =
|
|
19
|
+
const h = w(o), e = !!o.content, n = D(o, c), m = v(
|
|
19
20
|
(u) => {
|
|
20
21
|
e && (u.key === "Enter" || u.key === " ") && (u.preventDefault(), p());
|
|
21
22
|
},
|
|
@@ -119,7 +120,7 @@ const q = ({
|
|
|
119
120
|
}
|
|
120
121
|
),
|
|
121
122
|
e && /* @__PURE__ */ a(
|
|
122
|
-
|
|
123
|
+
R,
|
|
123
124
|
{
|
|
124
125
|
className: i(
|
|
125
126
|
"citation-panel-citation-item-chevron",
|
|
@@ -140,7 +141,7 @@ const q = ({
|
|
|
140
141
|
"citation-panel-citation-item-quote",
|
|
141
142
|
t["citation-panel-citation-item-quote"]
|
|
142
143
|
),
|
|
143
|
-
children: /* @__PURE__ */ a(
|
|
144
|
+
children: /* @__PURE__ */ a(k, { content: o.content })
|
|
144
145
|
}
|
|
145
146
|
)
|
|
146
147
|
]
|
|
@@ -152,9 +153,9 @@ const q = ({
|
|
|
152
153
|
]
|
|
153
154
|
}
|
|
154
155
|
);
|
|
155
|
-
},
|
|
156
|
-
const [s, p] =
|
|
157
|
-
|
|
156
|
+
}, z = ({ citations: o, highlightedIndex: c, onClose: r }) => {
|
|
157
|
+
const [s, p] = b(() => /* @__PURE__ */ new Set()), d = C([]);
|
|
158
|
+
E(() => {
|
|
158
159
|
if (c === void 0 || c < 0) return;
|
|
159
160
|
p((n) => new Set(n).add(c));
|
|
160
161
|
const e = d.current[c];
|
|
@@ -188,11 +189,11 @@ const q = ({
|
|
|
188
189
|
children: [
|
|
189
190
|
o.length > 0 && /* @__PURE__ */ a("span", { className: i("citation-panel-count", t["citation-panel-count"]), children: o.length }),
|
|
190
191
|
r && /* @__PURE__ */ a(
|
|
191
|
-
|
|
192
|
+
N,
|
|
192
193
|
{
|
|
193
194
|
type: "text",
|
|
194
195
|
icon: /* @__PURE__ */ a(
|
|
195
|
-
|
|
196
|
+
x,
|
|
196
197
|
{
|
|
197
198
|
className: i(
|
|
198
199
|
"citation-panel-citation-summary-icon",
|
|
@@ -210,10 +211,10 @@ const q = ({
|
|
|
210
211
|
)
|
|
211
212
|
] }),
|
|
212
213
|
o.length === 0 ? /* @__PURE__ */ a("div", { className: i("citation-panel-empty", t["citation-panel-empty"]), children: /* @__PURE__ */ a(f, { description: "暂无引用来源", image: f.PRESENTED_IMAGE_SIMPLE }) }) : /* @__PURE__ */ a(
|
|
213
|
-
|
|
214
|
+
S,
|
|
214
215
|
{
|
|
215
216
|
wrapperClassName: i("citation-panel-empty", t["citation-panel-empty"]),
|
|
216
|
-
children: o.map((e, n) => /* @__PURE__ */ l(
|
|
217
|
+
children: o.map((e, n) => /* @__PURE__ */ l(y.Fragment, { children: [
|
|
217
218
|
n > 0 && /* @__PURE__ */ a(
|
|
218
219
|
"div",
|
|
219
220
|
{
|
|
@@ -242,6 +243,6 @@ const q = ({
|
|
|
242
243
|
);
|
|
243
244
|
};
|
|
244
245
|
export {
|
|
245
|
-
|
|
246
|
+
z as default
|
|
246
247
|
};
|
|
247
248
|
//# sourceMappingURL=index.js.map
|