@zero-library/chat-agent 2.1.8 → 2.1.10
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/index.cjs.js +76 -64
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.css +27 -21
- package/dist/index.css.map +1 -1
- package/dist/index.d.mts +13 -13
- package/dist/index.d.ts +13 -13
- package/dist/index.esm.js +76 -64
- package/dist/index.esm.js.map +1 -1
- package/package.json +3 -3
package/dist/index.css
CHANGED
|
@@ -67,7 +67,7 @@
|
|
|
67
67
|
background-position: bottom;
|
|
68
68
|
padding-bottom: 2px;
|
|
69
69
|
}
|
|
70
|
-
.
|
|
70
|
+
.styles_module_nsConversationListPanel {
|
|
71
71
|
width: 360px;
|
|
72
72
|
}
|
|
73
73
|
.styles_module_nsConversations {
|
|
@@ -88,12 +88,6 @@
|
|
|
88
88
|
.styles_module_nsConversations .ant-conversations-list .ant-conversations-item.ant-conversations-item-active .ant-conversations-label {
|
|
89
89
|
color: var(--ant-color-primary);
|
|
90
90
|
}
|
|
91
|
-
.styles_module_nsBodyWidth {
|
|
92
|
-
margin: 0 auto;
|
|
93
|
-
max-width: 896px;
|
|
94
|
-
min-width: 320px;
|
|
95
|
-
width: calc(100% - 24px) !important;
|
|
96
|
-
}
|
|
97
91
|
.styles_module_nsBubbleList.ant-bubble-list .ant-bubble.ant-bubble-start .ant-bubble-content-filled {
|
|
98
92
|
background-color: transparent;
|
|
99
93
|
}
|
|
@@ -150,19 +144,19 @@
|
|
|
150
144
|
.styles_module_chatWelcomeWrap .styles_module_chatWelcomePrompts {
|
|
151
145
|
width: 300px;
|
|
152
146
|
}
|
|
153
|
-
.
|
|
147
|
+
.styles_module_nsSenderListTitle {
|
|
154
148
|
width: 300px;
|
|
155
149
|
}
|
|
156
|
-
.
|
|
150
|
+
.styles_module_nsSenderList .ant-list-items {
|
|
157
151
|
max-height: 350px;
|
|
158
152
|
overflow-y: auto;
|
|
159
153
|
margin-right: -12px;
|
|
160
154
|
padding-right: 12px;
|
|
161
155
|
}
|
|
162
|
-
.
|
|
156
|
+
.styles_module_nsSenderList.styles_module_historyList .ant-list-items {
|
|
163
157
|
max-height: initial;
|
|
164
158
|
}
|
|
165
|
-
.
|
|
159
|
+
.styles_module_nsSenderList .styles_module_nsSenderListItem {
|
|
166
160
|
background-color: #f6f6f6;
|
|
167
161
|
color: #6b6b6b !important;
|
|
168
162
|
border-radius: 5px;
|
|
@@ -172,7 +166,7 @@
|
|
|
172
166
|
font-size: 14px;
|
|
173
167
|
cursor: pointer;
|
|
174
168
|
}
|
|
175
|
-
.
|
|
169
|
+
.styles_module_nsSenderList .styles_module_nsSenderListFooter {
|
|
176
170
|
font-size: 12px;
|
|
177
171
|
}
|
|
178
172
|
.styles_module_nsChatUserName {
|
|
@@ -185,33 +179,33 @@
|
|
|
185
179
|
.styles_module_nsSenderReferenceHeaderContent {
|
|
186
180
|
padding: 0 !important;
|
|
187
181
|
}
|
|
188
|
-
.
|
|
182
|
+
.styles_module_nsAvatarListContainer {
|
|
189
183
|
height: 300px;
|
|
190
184
|
padding: 30px 48px 30px 24px;
|
|
191
185
|
overflow-y: auto;
|
|
192
186
|
margin-right: -24px;
|
|
193
187
|
}
|
|
194
|
-
.
|
|
188
|
+
.styles_module_nsAvatarListContainer .styles_module_nsAvatarList .styles_module_nsAvatarListItem:hover {
|
|
195
189
|
opacity: 90%;
|
|
196
190
|
}
|
|
197
|
-
.
|
|
191
|
+
.styles_module_nsAvatarListContainer .styles_module_nsAvatarList .styles_module_nsAvatarListItem .styles_module_nsAvatarListItemIcon.styles_module_nsAvatarListItemIconActive {
|
|
198
192
|
outline: 2px solid var(--ant-color-primary);
|
|
199
193
|
}
|
|
200
|
-
.
|
|
194
|
+
.styles_module_nsAvatarListContainer .styles_module_nsAvatarList .styles_module_nsAvatarListItem .styles_module_nsAvatarListItemName {
|
|
201
195
|
font-size: 12px;
|
|
202
196
|
}
|
|
203
197
|
|
|
204
198
|
/* src/components/styles.module.less */
|
|
205
|
-
.
|
|
199
|
+
.styles_module_chatAttachments > .ant-attachment-list .ant-attachment-list-card-status-uploading .ant-progress .ant-progress-text {
|
|
206
200
|
display: none;
|
|
207
201
|
}
|
|
208
|
-
.
|
|
202
|
+
.styles_module_chatAttachments > .ant-attachment-list .ant-attachment-list-card-status-uploading .ant-progress .ant-progress-circle {
|
|
209
203
|
animation: spin 2s linear infinite;
|
|
210
204
|
}
|
|
211
|
-
.
|
|
205
|
+
.styles_module_chatAttachments > .ant-attachment-list .ant-attachment-list-card-status-uploading .ant-attachment-list-card-content {
|
|
212
206
|
gap: 4px;
|
|
213
207
|
}
|
|
214
|
-
.
|
|
208
|
+
.styles_module_chatAttachments > .ant-attachment-list .ant-attachment-list-card-status-uploading .ant-attachment-list-card-content .ant-attachment-list-card-desc {
|
|
215
209
|
width: 15px;
|
|
216
210
|
height: 15px;
|
|
217
211
|
border: 2px solid transparent;
|
|
@@ -222,9 +216,12 @@
|
|
|
222
216
|
position: relative;
|
|
223
217
|
clip-path: inset(0 0 30% 0);
|
|
224
218
|
}
|
|
225
|
-
.
|
|
219
|
+
.styles_module_chatAttachments > .ant-attachment-list .ant-attachment-list-card-status-uploading .ant-attachment-list-card-content .ant-attachment-list-card-desc .ant-attachment-list-card-ellipsis-prefix {
|
|
226
220
|
display: none;
|
|
227
221
|
}
|
|
222
|
+
.styles_module_chatSender.ant-sender:focus-within {
|
|
223
|
+
box-shadow: none;
|
|
224
|
+
}
|
|
228
225
|
|
|
229
226
|
/* src/ui/layouts/styles.module.less */
|
|
230
227
|
.styles_module_nsPreviewHeader {
|
|
@@ -249,4 +246,13 @@
|
|
|
249
246
|
.styles_module_nsChatLayout {
|
|
250
247
|
background-color: #fff;
|
|
251
248
|
}
|
|
249
|
+
.styles_module_nsChatLayout .styles_module_nsChatBody {
|
|
250
|
+
padding: 8px 0;
|
|
251
|
+
}
|
|
252
|
+
.styles_module_nsBodyWidth {
|
|
253
|
+
margin: 0 auto;
|
|
254
|
+
max-width: 896px;
|
|
255
|
+
min-width: 320px;
|
|
256
|
+
width: calc(100% - 24px);
|
|
257
|
+
}
|
|
252
258
|
/*# sourceMappingURL=index.css.map */
|
package/dist/index.css.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/ui/common/markdownAlert/styles.module.less","../src/ui/common/styles.module.less","../src/components/styles.module.less","../src/ui/layouts/styles.module.less"],"sourcesContent":[".appCard {\n width: 180px;\n border-radius: 10px;\n border: 1px solid #d7d7d7;\n background-color: #fafafa;\n font-size: 16px;\n cursor: pointer;\n margin: 8px;\n padding: 12px 8px;\n}\n.appCard > div {\n max-width: 100%;\n}\n.appCard > img {\n height: 30px;\n}\n.fileView {\n width: 200px;\n padding: 4px 8px;\n cursor: pointer;\n background-color: #f5f3f3;\n border-radius: 6px;\n}\n.fileEdit {\n margin: 12px 0;\n border-radius: 6px;\n border: 1px solid #f2f2f2;\n}\n.fileEdit .fileEditHeader {\n padding: 2px 8px;\n background-color: #f2f2f2;\n}\n.fileEdit .fileEditContent {\n padding: 8px;\n background-color: #fafafa;\n}\n.quoteList {\n min-width: 300px;\n}\n.quoteList:global.ant-collapse .ant-collapse-item .ant-collapse-header {\n padding: 12px 0;\n color: #8f91a8;\n}\n.quoteList:global.ant-collapse .ant-collapse-item .ant-collapse-content {\n color: #8f91a8;\n background-color: #f2f2f2;\n}\n.mdEdit {\n margin: 10px 0;\n background-color: rgba(242, 242, 242, 0.2);\n border: 1px solid #f2f2f2;\n padding: 10px;\n border-radius: 4px;\n}\n",".loadingMessage {\n background-image: linear-gradient(90deg, #ff6b23 0%, #af3cb8 31%, #53b6ff 89%);\n background-size: 100% 2px;\n background-repeat: no-repeat;\n background-position: bottom;\n padding-bottom: 2px;\n}\n.conversationListPanel {\n width: 360px;\n}\n.nsConversations {\n padding: 0 24px;\n}\n.nsConversations :global .ant-conversations-group-title {\n padding: 0;\n}\n.nsConversations :global .ant-conversations-group-title .ant-typography {\n color: #878aab;\n}\n.nsConversations :global .ant-conversations-list .ant-conversations-item {\n padding-left: 16px;\n}\n.nsConversations :global .ant-conversations-list .ant-conversations-item .ant-conversations-label {\n color: rgba(0, 0, 0, 0.88);\n}\n.nsConversations :global .ant-conversations-list .ant-conversations-item.ant-conversations-item-active .ant-conversations-label {\n color: var(--ant-color-primary);\n}\n.nsBodyWidth {\n margin: 0 auto;\n max-width: 896px;\n min-width: 320px;\n width: calc(100% - 24px) !important;\n}\n.nsBubbleList:global.ant-bubble-list .ant-bubble.ant-bubble-start .ant-bubble-content-filled {\n background-color: transparent;\n}\n.nsBubbleList:global.ant-bubble-list .ant-bubble.ant-bubble-end .ant-bubble-content-filled {\n background-color: var(--ant-color-primary-bg);\n}\n.nsBubbleList:global.ant-bubble-list .ant-bubble .ant-bubble-content .ant-typography {\n font-size: 16px;\n}\n.nsBubbleList:global.ant-bubble-list .ant-bubble .ant-bubble-content > .ant-collapse {\n margin-bottom: 16px;\n}\n.nsBubbleList:global.ant-bubble-list .ant-bubble .ant-bubble-content > .ant-collapse .ant-collapse-header {\n color: #8f91a8;\n}\n.nsBubbleList:global.ant-bubble-list .ant-bubble .ant-bubble-content > .ant-collapse .ant-collapse-content {\n color: #8f91a8;\n margin-top: -10px;\n}\n.nsBubbleList:global.ant-bubble-list .ant-bubble .ant-bubble-content > .ant-collapse .ant-collapse-content .ant-collapse-content-box {\n padding: 0 10px 0 24px;\n}\n@keyframes spin {\n to {\n transform: rotate(360deg);\n }\n}\n.nsChatHeader {\n padding: 8px 16px;\n border-bottom: 1px solid #eee;\n}\n.nsChatHeader .nsChatTitle {\n font-size: 16px;\n font-weight: bold;\n}\n.nsChatHeader .nsChatHeaderPopover {\n max-height: 500px;\n width: 300px;\n display: flex;\n flex-direction: column;\n}\n.nsChatHeader .nsChatHeaderPopover :global .ant-popover-inner-content {\n min-height: 0;\n display: flex;\n flex-direction: column;\n}\n.chatWelcomeWrap :global .ant-prompts .ant-prompts-list {\n overflow: auto;\n}\n.chatWelcomeWrap .chatWelcome :global .ant-welcome-icon > img {\n border-radius: 10px;\n max-width: initial;\n}\n.chatWelcomeWrap .chatWelcomePrompts {\n width: 300px;\n}\n.senderListTitle {\n width: 300px;\n}\n.senderList :global .ant-list-items {\n max-height: 350px;\n overflow-y: auto;\n margin-right: -12px;\n padding-right: 12px;\n}\n.senderList.historyList :global .ant-list-items {\n max-height: initial;\n}\n.senderList .senderListItem {\n background-color: #f6f6f6;\n color: #6b6b6b !important;\n border-radius: 5px;\n width: 300px;\n padding: 6px 12px !important;\n margin-top: 12px;\n font-size: 14px;\n cursor: pointer;\n}\n.senderList .senderListFooter {\n font-size: 12px;\n}\n.nsChatUserName {\n font-size: 16px;\n font-weight: bold;\n}\n.nsSenderReferenceHeaderTitle:global > .ant-sender-header-title {\n overflow: hidden;\n}\n.nsSenderReferenceHeaderContent {\n padding: 0 !important;\n}\n.avatarListContainer {\n height: 300px;\n padding: 30px 48px 30px 24px;\n overflow-y: auto;\n margin-right: -24px;\n}\n.avatarListContainer .avatarList .avatarListItem:hover {\n opacity: 90%;\n}\n.avatarListContainer .avatarList .avatarListItem .avatarListItemIcon.avatarListItemIconActive {\n outline: 2px solid var(--ant-color-primary);\n}\n.avatarListContainer .avatarList .avatarListItem .avatarListItemName {\n font-size: 12px;\n}\n",".nsAttachments:global > .ant-attachment-list .ant-attachment-list-card-status-uploading .ant-progress .ant-progress-text {\n display: none;\n}\n.nsAttachments:global > .ant-attachment-list .ant-attachment-list-card-status-uploading .ant-progress .ant-progress-circle {\n animation: spin 2s linear infinite;\n}\n.nsAttachments:global > .ant-attachment-list .ant-attachment-list-card-status-uploading .ant-attachment-list-card-content {\n gap: 4px;\n}\n.nsAttachments:global > .ant-attachment-list .ant-attachment-list-card-status-uploading .ant-attachment-list-card-content .ant-attachment-list-card-desc {\n width: 15px;\n height: 15px;\n border: 2px solid transparent;\n border-color: #1890ff;\n border-radius: 50%;\n animation: spin 1s linear infinite;\n box-sizing: border-box;\n position: relative;\n clip-path: inset(0 0 30% 0);\n}\n.nsAttachments:global > .ant-attachment-list .ant-attachment-list-card-status-uploading .ant-attachment-list-card-content .ant-attachment-list-card-desc .ant-attachment-list-card-ellipsis-prefix {\n display: none;\n}\n",".nsPreviewHeader {\n padding: 16px 24px;\n box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);\n}\n.nsPreviewHeader .nsPreviewHeaderTitle {\n font-size: 16px;\n font-weight: bold;\n}\n.nsChatSenderHeader {\n margin-bottom: 16px;\n padding: 24px;\n font-size: 24px;\n text-align: center;\n}\n.nsDisclaimerNotice {\n font-size: 12px;\n text-align: center;\n color: #bfbfbf;\n}\n.nsChatLayout {\n background-color: #fff;\n}\n"],"mappings":";AAAA,CAACA;AACC,SAAO;AACP,iBAAe;AACf,UAAQ,IAAI,MAAM;AAClB,oBAAkB;AAClB,aAAW;AACX,UAAQ;AACR,UAAQ;AACR,WAAS,KAAK;AAChB;AACA,CAVCA,sBAUQ,EAAE;AACT,aAAW;AACb;AACA,CAbCA,sBAaQ,EAAE;AACT,UAAQ;AACV;AACA,CAACC;AACC,SAAO;AACP,WAAS,IAAI;AACb,UAAQ;AACR,oBAAkB;AAClB,iBAAe;AACjB;AACA,CAACC;AACC,UAAQ,KAAK;AACb,iBAAe;AACf,UAAQ,IAAI,MAAM;AACpB;AACA,CALCA,uBAKS,CAACC;AACT,WAAS,IAAI;AACb,oBAAkB;AACpB;AACA,CATCD,uBASS,CAACE;AACT,WAAS;AACT,oBAAkB;AACpB;AACA,CAACC;AACC,aAAW;AACb;AACA,CAHCA,uBAGgB,CAAC,aAAa,CAAC,kBAAkB,CAAC;AACjD,WAAS,KAAK;AACd,SAAO;AACT;AACA,CAPCA,uBAOgB,CAJC,aAIa,CAJC,kBAIkB,CAAC;AACjD,SAAO;AACP,oBAAkB;AACpB;AACA,CAACC;AACC,UAAQ,KAAK;AACb,oBAAkB,KAAK,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE;AACtC,UAAQ,IAAI,MAAM;AAClB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AACA,CANCA,kCAMoB,CAACC,yBAAW,CAACC,4BAAc;AAC9C,WAAS;AACX;AACA,CATCF,kCASoB,CAHCC,yBAGW,CAHCC,6BAGe,CAACC,gCAAkB,CAACC;AACnE,WAAS,IAAI,MAAM,IAAI;AACzB;AACA,CAZCJ,kCAYoB,CANCC,yBAMW,CANCC,6BAMe,CAACG;AAChD,aAAW;AACb;;;AC3IA,CAACC,4BAAqB,EAAE,CAAC,oBAAoB,CAAC,0CAA0C,CAAC,aAAa,CAAC;AACrG,WAAS;AACX;AACA,CAHCA,4BAGqB,EAAE,CAHC,oBAGoB,CAHC,0CAG0C,CAHC,aAGa,CAAC;AACrG,aAAW,KAAK,GAAG,OAAO;AAC5B;AACA,CANCA,4BAMqB,EAAE,CANC,oBAMoB,CANC,0CAM0C,CAAC;AACvF,OAAK;AACP;AACA,CATCA,4BASqB,EAAE,CATC,oBASoB,CATC,0CAS0C,CAHC,iCAGiC,CAAC;AACzH,SAAO;AACP,UAAQ;AACR,UAAQ,IAAI,MAAM;AAClB,gBAAc;AACd,iBAAe;AACf,aAAW,KAAK,GAAG,OAAO;AAC1B,cAAY;AACZ,YAAU;AACV,aAAW,MAAM,EAAE,EAAE,IAAI;AAC3B;AACA,CApBCA,4BAoBqB,EAAE,CApBC,oBAoBoB,CApBC,0CAoB0C,CAdC,iCAciC,CAXC,8BAW8B,CAAC;AACxJ,WAAS;AACX;;;ACtBA,CAACC;AACC,WAAS,KAAK;AACd,cAAY,EAAE,IAAI,IAAI,KAAK,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE;AACtC;AACA,CAJCA,8BAIgB,CAACC;AAChB,aAAW;AACX,eAAa;AACf;AACA,CAACC;AACC,iBAAe;AACf,WAAS;AACT,aAAW;AACX,cAAY;AACd;AACA,CAACC;AACC,aAAW;AACX,cAAY;AACZ,SAAO;AACT;AACA,CAACC;AACC,oBAAkB;AACpB;","names":["appCard","fileView","fileEdit","fileEditHeader","fileEditContent","quoteList","mdEdit","loadingMessage","conversationListPanel","nsConversations","nsBodyWidth","nsBubbleList","spin","nsChatHeader","nsChatTitle","nsChatHeaderPopover","chatWelcomeWrap","chatWelcome","chatWelcomePrompts","senderListTitle","senderList","historyList","senderListItem","senderListFooter","nsChatUserName","nsSenderReferenceHeaderTitle","nsSenderReferenceHeaderContent","avatarListContainer","avatarList","avatarListItem","avatarListItemIcon","avatarListItemIconActive","avatarListItemName","nsAttachments","nsPreviewHeader","nsPreviewHeaderTitle","nsChatSenderHeader","nsDisclaimerNotice","nsChatLayout"]}
|
|
1
|
+
{"version":3,"sources":["../src/ui/common/markdownAlert/styles.module.less","../src/ui/common/styles.module.less","../src/components/styles.module.less","../src/ui/layouts/styles.module.less"],"sourcesContent":[".appCard {\n width: 180px;\n border-radius: 10px;\n border: 1px solid #d7d7d7;\n background-color: #fafafa;\n font-size: 16px;\n cursor: pointer;\n margin: 8px;\n padding: 12px 8px;\n}\n.appCard > div {\n max-width: 100%;\n}\n.appCard > img {\n height: 30px;\n}\n.fileView {\n width: 200px;\n padding: 4px 8px;\n cursor: pointer;\n background-color: #f5f3f3;\n border-radius: 6px;\n}\n.fileEdit {\n margin: 12px 0;\n border-radius: 6px;\n border: 1px solid #f2f2f2;\n}\n.fileEdit .fileEditHeader {\n padding: 2px 8px;\n background-color: #f2f2f2;\n}\n.fileEdit .fileEditContent {\n padding: 8px;\n background-color: #fafafa;\n}\n.quoteList {\n min-width: 300px;\n}\n.quoteList:global.ant-collapse .ant-collapse-item .ant-collapse-header {\n padding: 12px 0;\n color: #8f91a8;\n}\n.quoteList:global.ant-collapse .ant-collapse-item .ant-collapse-content {\n color: #8f91a8;\n background-color: #f2f2f2;\n}\n.mdEdit {\n margin: 10px 0;\n background-color: rgba(242, 242, 242, 0.2);\n border: 1px solid #f2f2f2;\n padding: 10px;\n border-radius: 4px;\n}\n",".loadingMessage {\n background-image: linear-gradient(90deg, #ff6b23 0%, #af3cb8 31%, #53b6ff 89%);\n background-size: 100% 2px;\n background-repeat: no-repeat;\n background-position: bottom;\n padding-bottom: 2px;\n}\n.nsConversationListPanel {\n width: 360px;\n}\n.nsConversations {\n padding: 0 24px;\n}\n.nsConversations :global .ant-conversations-group-title {\n padding: 0;\n}\n.nsConversations :global .ant-conversations-group-title .ant-typography {\n color: #878aab;\n}\n.nsConversations :global .ant-conversations-list .ant-conversations-item {\n padding-left: 16px;\n}\n.nsConversations :global .ant-conversations-list .ant-conversations-item .ant-conversations-label {\n color: rgba(0, 0, 0, 0.88);\n}\n.nsConversations :global .ant-conversations-list .ant-conversations-item.ant-conversations-item-active .ant-conversations-label {\n color: var(--ant-color-primary);\n}\n.nsBubbleList:global.ant-bubble-list .ant-bubble.ant-bubble-start .ant-bubble-content-filled {\n background-color: transparent;\n}\n.nsBubbleList:global.ant-bubble-list .ant-bubble.ant-bubble-end .ant-bubble-content-filled {\n background-color: var(--ant-color-primary-bg);\n}\n.nsBubbleList:global.ant-bubble-list .ant-bubble .ant-bubble-content .ant-typography {\n font-size: 16px;\n}\n.nsBubbleList:global.ant-bubble-list .ant-bubble .ant-bubble-content > .ant-collapse {\n margin-bottom: 16px;\n}\n.nsBubbleList:global.ant-bubble-list .ant-bubble .ant-bubble-content > .ant-collapse .ant-collapse-header {\n color: #8f91a8;\n}\n.nsBubbleList:global.ant-bubble-list .ant-bubble .ant-bubble-content > .ant-collapse .ant-collapse-content {\n color: #8f91a8;\n margin-top: -10px;\n}\n.nsBubbleList:global.ant-bubble-list .ant-bubble .ant-bubble-content > .ant-collapse .ant-collapse-content .ant-collapse-content-box {\n padding: 0 10px 0 24px;\n}\n@keyframes spin {\n to {\n transform: rotate(360deg);\n }\n}\n.nsChatHeader {\n padding: 8px 16px;\n border-bottom: 1px solid #eee;\n}\n.nsChatHeader .nsChatTitle {\n font-size: 16px;\n font-weight: bold;\n}\n.nsChatHeader .nsChatHeaderPopover {\n max-height: 500px;\n width: 300px;\n display: flex;\n flex-direction: column;\n}\n.nsChatHeader .nsChatHeaderPopover :global .ant-popover-inner-content {\n min-height: 0;\n display: flex;\n flex-direction: column;\n}\n.chatWelcomeWrap :global .ant-prompts .ant-prompts-list {\n overflow: auto;\n}\n.chatWelcomeWrap .chatWelcome :global .ant-welcome-icon > img {\n border-radius: 10px;\n max-width: initial;\n}\n.chatWelcomeWrap .chatWelcomePrompts {\n width: 300px;\n}\n.nsSenderListTitle {\n width: 300px;\n}\n.nsSenderList :global .ant-list-items {\n max-height: 350px;\n overflow-y: auto;\n margin-right: -12px;\n padding-right: 12px;\n}\n.nsSenderList.historyList :global .ant-list-items {\n max-height: initial;\n}\n.nsSenderList .nsSenderListItem {\n background-color: #f6f6f6;\n color: #6b6b6b !important;\n border-radius: 5px;\n width: 300px;\n padding: 6px 12px !important;\n margin-top: 12px;\n font-size: 14px;\n cursor: pointer;\n}\n.nsSenderList .nsSenderListFooter {\n font-size: 12px;\n}\n.nsChatUserName {\n font-size: 16px;\n font-weight: bold;\n}\n.nsSenderReferenceHeaderTitle:global > .ant-sender-header-title {\n overflow: hidden;\n}\n.nsSenderReferenceHeaderContent {\n padding: 0 !important;\n}\n.nsAvatarListContainer {\n height: 300px;\n padding: 30px 48px 30px 24px;\n overflow-y: auto;\n margin-right: -24px;\n}\n.nsAvatarListContainer .nsAvatarList .nsAvatarListItem:hover {\n opacity: 90%;\n}\n.nsAvatarListContainer .nsAvatarList .nsAvatarListItem .nsAvatarListItemIcon.nsAvatarListItemIconActive {\n outline: 2px solid var(--ant-color-primary);\n}\n.nsAvatarListContainer .nsAvatarList .nsAvatarListItem .nsAvatarListItemName {\n font-size: 12px;\n}\n",".chatAttachments:global > .ant-attachment-list .ant-attachment-list-card-status-uploading .ant-progress .ant-progress-text {\n display: none;\n}\n.chatAttachments:global > .ant-attachment-list .ant-attachment-list-card-status-uploading .ant-progress .ant-progress-circle {\n animation: spin 2s linear infinite;\n}\n.chatAttachments:global > .ant-attachment-list .ant-attachment-list-card-status-uploading .ant-attachment-list-card-content {\n gap: 4px;\n}\n.chatAttachments:global > .ant-attachment-list .ant-attachment-list-card-status-uploading .ant-attachment-list-card-content .ant-attachment-list-card-desc {\n width: 15px;\n height: 15px;\n border: 2px solid transparent;\n border-color: #1890ff;\n border-radius: 50%;\n animation: spin 1s linear infinite;\n box-sizing: border-box;\n position: relative;\n clip-path: inset(0 0 30% 0);\n}\n.chatAttachments:global > .ant-attachment-list .ant-attachment-list-card-status-uploading .ant-attachment-list-card-content .ant-attachment-list-card-desc .ant-attachment-list-card-ellipsis-prefix {\n display: none;\n}\n.chatSender:global.ant-sender:focus-within {\n box-shadow: none;\n}\n",".nsPreviewHeader {\n padding: 16px 24px;\n box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);\n}\n.nsPreviewHeader .nsPreviewHeaderTitle {\n font-size: 16px;\n font-weight: bold;\n}\n.nsChatSenderHeader {\n margin-bottom: 16px;\n padding: 24px;\n font-size: 24px;\n text-align: center;\n}\n.nsDisclaimerNotice {\n font-size: 12px;\n text-align: center;\n color: #bfbfbf;\n}\n.nsChatLayout {\n background-color: #fff;\n}\n.nsChatLayout .nsChatBody {\n padding: 8px 0;\n}\n.nsBodyWidth {\n margin: 0 auto;\n max-width: 896px;\n min-width: 320px;\n width: calc(100% - 24px);\n}\n"],"mappings":";AAAA,CAACA;AACC,SAAO;AACP,iBAAe;AACf,UAAQ,IAAI,MAAM;AAClB,oBAAkB;AAClB,aAAW;AACX,UAAQ;AACR,UAAQ;AACR,WAAS,KAAK;AAChB;AACA,CAVCA,sBAUQ,EAAE;AACT,aAAW;AACb;AACA,CAbCA,sBAaQ,EAAE;AACT,UAAQ;AACV;AACA,CAACC;AACC,SAAO;AACP,WAAS,IAAI;AACb,UAAQ;AACR,oBAAkB;AAClB,iBAAe;AACjB;AACA,CAACC;AACC,UAAQ,KAAK;AACb,iBAAe;AACf,UAAQ,IAAI,MAAM;AACpB;AACA,CALCA,uBAKS,CAACC;AACT,WAAS,IAAI;AACb,oBAAkB;AACpB;AACA,CATCD,uBASS,CAACE;AACT,WAAS;AACT,oBAAkB;A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CAAC,EAAE,CAAC,EAAE;AACtC;AACA,CAJCA,8BAIgB,CAACC;AAChB,aAAW;AACX,eAAa;AACf;AACA,CAACC;AACC,iBAAe;AACf,WAAS;AACT,aAAW;AACX,cAAY;AACd;AACA,CAACC;AACC,aAAW;AACX,cAAY;AACZ,SAAO;AACT;AACA,CAACC;AACC,oBAAkB;AACpB;AACA,CAHCA,2BAGa,CAACC;AACb,WAAS,IAAI;AACf;AACA,CAACC;AACC,UAAQ,EAAE;AACV,aAAW;AACX,aAAW;AACX,SAAO,KAAK,KAAK,EAAE;AACrB;","names":["appCard","fileView","fileEdit","fileEditHeader","fileEditContent","quoteList","mdEdit","loadingMessage","nsConversationListPanel","nsConversations","nsBubbleList","spin","nsChatHeader","nsChatTitle","nsChatHeaderPopover","chatWelcomeWrap","chatWelcome","chatWelcomePrompts","nsSenderListTitle","nsSenderList","historyList","nsSenderListItem","nsSenderListFooter","nsChatUserName","nsSenderReferenceHeaderTitle","nsSenderReferenceHeaderContent","nsAvatarListContainer","nsAvatarList","nsAvatarListItem","nsAvatarListItemIcon","nsAvatarListItemIconActive","nsAvatarListItemName","chatAttachments","chatSender","nsPreviewHeader","nsPreviewHeaderTitle","nsChatSenderHeader","nsDisclaimerNotice","nsChatLayout","nsChatBody","nsBodyWidth"]}
|
package/dist/index.d.mts
CHANGED
|
@@ -293,7 +293,7 @@ interface ChatLayoutSender {
|
|
|
293
293
|
extraBtn?: RenderControl<void, void>;
|
|
294
294
|
referencesBtn?: RenderControl<void, void>;
|
|
295
295
|
footerBelow?: RenderControl<void, void>;
|
|
296
|
-
sendBtnProps?: ButtonProps;
|
|
296
|
+
sendBtnProps?: () => ButtonProps;
|
|
297
297
|
prompts?: boolean;
|
|
298
298
|
}
|
|
299
299
|
interface ChatLayoutMessageList {
|
|
@@ -322,7 +322,7 @@ interface FileUpload {
|
|
|
322
322
|
params?: ObjectType<any>;
|
|
323
323
|
config: FileUploadConfig[];
|
|
324
324
|
}
|
|
325
|
-
interface Props$
|
|
325
|
+
interface Props$2 {
|
|
326
326
|
placeholder?: string;
|
|
327
327
|
content?: string;
|
|
328
328
|
fileList?: InputFile[];
|
|
@@ -340,7 +340,7 @@ interface Props$3 {
|
|
|
340
340
|
sendBtnProps?: ButtonProps;
|
|
341
341
|
fileUpload?: FileUpload;
|
|
342
342
|
}
|
|
343
|
-
declare const _default$3: react.ForwardRefExoticComponent<Props$
|
|
343
|
+
declare const _default$3: react.ForwardRefExoticComponent<Props$2 & react.RefAttributes<ChatSenderHandle>>;
|
|
344
344
|
|
|
345
345
|
interface ChatConfig {
|
|
346
346
|
receiverType?: number;
|
|
@@ -348,14 +348,6 @@ interface ChatConfig {
|
|
|
348
348
|
conversationId?: string;
|
|
349
349
|
conversationStrategy?: ConversationStrategy;
|
|
350
350
|
}
|
|
351
|
-
interface Props$2 {
|
|
352
|
-
theme?: ThemeConfig;
|
|
353
|
-
config?: ChatConfig;
|
|
354
|
-
params?: ChatParams;
|
|
355
|
-
hooks?: ChatHooks;
|
|
356
|
-
layout?: ChatLayout;
|
|
357
|
-
userInfo?: UserInfo;
|
|
358
|
-
}
|
|
359
351
|
interface ChatHandle {
|
|
360
352
|
sendMessage: (message?: string, files?: InputFile[]) => void;
|
|
361
353
|
switchAgentConversation: (agentId: AgentInfo['id'], strategy?: ConversationStrategy) => Promise<void>;
|
|
@@ -367,7 +359,15 @@ interface ChatHandle {
|
|
|
367
359
|
setParams: (params?: ChatParams) => void;
|
|
368
360
|
senderFocus: ChatSenderHandle['focus'];
|
|
369
361
|
}
|
|
370
|
-
|
|
362
|
+
interface ChatProps {
|
|
363
|
+
theme?: ThemeConfig;
|
|
364
|
+
config?: ChatConfig;
|
|
365
|
+
params?: ChatParams;
|
|
366
|
+
hooks?: ChatHooks;
|
|
367
|
+
layout?: ChatLayout;
|
|
368
|
+
userInfo?: UserInfo;
|
|
369
|
+
}
|
|
370
|
+
declare const _default$2: react.ForwardRefExoticComponent<ChatProps & react.RefAttributes<ChatHandle>>;
|
|
371
371
|
|
|
372
372
|
interface Props$1 {
|
|
373
373
|
fileUploadConfig?: FileUploadConfig[];
|
|
@@ -383,4 +383,4 @@ interface Props {
|
|
|
383
383
|
}
|
|
384
384
|
declare const _default: ({ message, placement }: Props) => react_jsx_runtime.JSX.Element;
|
|
385
385
|
|
|
386
|
-
export { type AgentInfo, _default$1 as Attachments, type ChatConfig, _default$2 as ChatCopilot, type ChatHandle, type ChatHooks, type ChatLayout, type ChatParams, _default$3 as ChatSender, type ConversationStrategy, type InputFile, _default as MessageRender, type ReferencesType };
|
|
386
|
+
export { type AgentInfo, _default$1 as Attachments, type ChatConfig, _default$2 as ChatCopilot, type ChatHandle, type ChatHooks, type ChatLayout, type ChatParams, type ChatProps, _default$3 as ChatSender, type ConversationStrategy, type InputFile, _default as MessageRender, type ReferencesType };
|
package/dist/index.d.ts
CHANGED
|
@@ -293,7 +293,7 @@ interface ChatLayoutSender {
|
|
|
293
293
|
extraBtn?: RenderControl<void, void>;
|
|
294
294
|
referencesBtn?: RenderControl<void, void>;
|
|
295
295
|
footerBelow?: RenderControl<void, void>;
|
|
296
|
-
sendBtnProps?: ButtonProps;
|
|
296
|
+
sendBtnProps?: () => ButtonProps;
|
|
297
297
|
prompts?: boolean;
|
|
298
298
|
}
|
|
299
299
|
interface ChatLayoutMessageList {
|
|
@@ -322,7 +322,7 @@ interface FileUpload {
|
|
|
322
322
|
params?: ObjectType<any>;
|
|
323
323
|
config: FileUploadConfig[];
|
|
324
324
|
}
|
|
325
|
-
interface Props$
|
|
325
|
+
interface Props$2 {
|
|
326
326
|
placeholder?: string;
|
|
327
327
|
content?: string;
|
|
328
328
|
fileList?: InputFile[];
|
|
@@ -340,7 +340,7 @@ interface Props$3 {
|
|
|
340
340
|
sendBtnProps?: ButtonProps;
|
|
341
341
|
fileUpload?: FileUpload;
|
|
342
342
|
}
|
|
343
|
-
declare const _default$3: react.ForwardRefExoticComponent<Props$
|
|
343
|
+
declare const _default$3: react.ForwardRefExoticComponent<Props$2 & react.RefAttributes<ChatSenderHandle>>;
|
|
344
344
|
|
|
345
345
|
interface ChatConfig {
|
|
346
346
|
receiverType?: number;
|
|
@@ -348,14 +348,6 @@ interface ChatConfig {
|
|
|
348
348
|
conversationId?: string;
|
|
349
349
|
conversationStrategy?: ConversationStrategy;
|
|
350
350
|
}
|
|
351
|
-
interface Props$2 {
|
|
352
|
-
theme?: ThemeConfig;
|
|
353
|
-
config?: ChatConfig;
|
|
354
|
-
params?: ChatParams;
|
|
355
|
-
hooks?: ChatHooks;
|
|
356
|
-
layout?: ChatLayout;
|
|
357
|
-
userInfo?: UserInfo;
|
|
358
|
-
}
|
|
359
351
|
interface ChatHandle {
|
|
360
352
|
sendMessage: (message?: string, files?: InputFile[]) => void;
|
|
361
353
|
switchAgentConversation: (agentId: AgentInfo['id'], strategy?: ConversationStrategy) => Promise<void>;
|
|
@@ -367,7 +359,15 @@ interface ChatHandle {
|
|
|
367
359
|
setParams: (params?: ChatParams) => void;
|
|
368
360
|
senderFocus: ChatSenderHandle['focus'];
|
|
369
361
|
}
|
|
370
|
-
|
|
362
|
+
interface ChatProps {
|
|
363
|
+
theme?: ThemeConfig;
|
|
364
|
+
config?: ChatConfig;
|
|
365
|
+
params?: ChatParams;
|
|
366
|
+
hooks?: ChatHooks;
|
|
367
|
+
layout?: ChatLayout;
|
|
368
|
+
userInfo?: UserInfo;
|
|
369
|
+
}
|
|
370
|
+
declare const _default$2: react.ForwardRefExoticComponent<ChatProps & react.RefAttributes<ChatHandle>>;
|
|
371
371
|
|
|
372
372
|
interface Props$1 {
|
|
373
373
|
fileUploadConfig?: FileUploadConfig[];
|
|
@@ -383,4 +383,4 @@ interface Props {
|
|
|
383
383
|
}
|
|
384
384
|
declare const _default: ({ message, placement }: Props) => react_jsx_runtime.JSX.Element;
|
|
385
385
|
|
|
386
|
-
export { type AgentInfo, _default$1 as Attachments, type ChatConfig, _default$2 as ChatCopilot, type ChatHandle, type ChatHooks, type ChatLayout, type ChatParams, _default$3 as ChatSender, type ConversationStrategy, type InputFile, _default as MessageRender, type ReferencesType };
|
|
386
|
+
export { type AgentInfo, _default$1 as Attachments, type ChatConfig, _default$2 as ChatCopilot, type ChatHandle, type ChatHooks, type ChatLayout, type ChatParams, type ChatProps, _default$3 as ChatSender, type ConversationStrategy, type InputFile, _default as MessageRender, type ReferencesType };
|
package/dist/index.esm.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { useRefState, useDebounce, useSyncInput, RenderWrapper, shouldRender, useDeepEffect, useWebSocket, getWebSocketUrl, getToken, isLocalhost, downloadFile, FilePreview, MarkdownEditor, useCreateValtioContext, isNumber, getFileSuffixName, isObject, isNullOrUnDef, isBoolean, UserAvatar, request, deepCopy, getCurrentUser, deepMerge, RenderMarkdown, copyText, FileIcon, isExternal } from '@zero-library/common';
|
|
1
|
+
import { useRefState, useDebounce, useSyncInput, RenderWrapper, shouldRender, isFunction, useDeepEffect, useWebSocket, getWebSocketUrl, getToken, isLocalhost, downloadFile, FilePreview, MarkdownEditor, useCreateValtioContext, isNumber, getFileSuffixName, isObject, isNullOrUnDef, isBoolean, UserAvatar, request, deepCopy, getCurrentUser, deepMerge, RenderMarkdown, copyText, FileIcon, isExternal } from '@zero-library/common';
|
|
2
2
|
import { App, Badge, Button, Flex, Typography, Spin, Splitter, Tag, Popover, List, Avatar, Space, message, Empty, Collapse, Modal, Row, Col, Drawer } from 'antd';
|
|
3
3
|
import dayjs from 'dayjs';
|
|
4
4
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
@@ -6,7 +6,7 @@ import { forwardRef, useRef, useEffect, useImperativeHandle, useMemo, useState }
|
|
|
6
6
|
import { CloudUploadOutlined, PaperClipOutlined, EnterOutlined, UserSwitchOutlined, CloseOutlined, PlusOutlined, CommentOutlined, OpenAIOutlined, CopyOutlined, LikeOutlined, DislikeOutlined, DeleteOutlined, RedoOutlined, PlayCircleOutlined, CaretRightOutlined } from '@ant-design/icons';
|
|
7
7
|
import { Attachments, Sender, Suggestion, XProvider, Welcome, Prompts, Bubble, Conversations } from '@ant-design/x';
|
|
8
8
|
export * from '@ant-design/x';
|
|
9
|
-
import
|
|
9
|
+
import classNames8 from 'classnames';
|
|
10
10
|
import { useSnapshot, proxy } from 'valtio';
|
|
11
11
|
import InfiniteScroll from 'react-infinite-scroll-component';
|
|
12
12
|
|
|
@@ -313,7 +313,7 @@ var conversationCreate = (params) => {
|
|
|
313
313
|
return request.post("/lolr/conversation", params);
|
|
314
314
|
};
|
|
315
315
|
var conversationDelete = (conversationId) => {
|
|
316
|
-
return request.delete("/
|
|
316
|
+
return request.delete("/lolr/conversation", { conversationId });
|
|
317
317
|
};
|
|
318
318
|
var conversationRecentQuery = (params) => {
|
|
319
319
|
return request.get("/lolr/conversation/recent", params);
|
|
@@ -427,7 +427,7 @@ function createChatStore() {
|
|
|
427
427
|
config.hooks = hooks;
|
|
428
428
|
};
|
|
429
429
|
const setUserInfo = (userInfo) => {
|
|
430
|
-
config.userInfo = transform(userInfo || getCurrentUser(), {
|
|
430
|
+
config.userInfo = transform(userInfo || getCurrentUser() || {}, {
|
|
431
431
|
id: (userInfo2) => {
|
|
432
432
|
return String(userInfo2["id"]);
|
|
433
433
|
},
|
|
@@ -701,7 +701,7 @@ function createChatStore() {
|
|
|
701
701
|
const switchAgentConversation = async (id, strategy) => {
|
|
702
702
|
const agentId = String(id);
|
|
703
703
|
await switchAgent(agentId);
|
|
704
|
-
const conversationId = await resolveConversationId(
|
|
704
|
+
const conversationId = await resolveConversationId(receiver.active.id, strategy);
|
|
705
705
|
if (conversationId) {
|
|
706
706
|
await switchConversation(conversationId);
|
|
707
707
|
}
|
|
@@ -963,9 +963,8 @@ init_Context();
|
|
|
963
963
|
// src/ui/common/styles.module.less
|
|
964
964
|
var styles_module_default2 = {
|
|
965
965
|
loadingMessage: "styles_module_loadingMessage",
|
|
966
|
-
|
|
966
|
+
nsConversationListPanel: "styles_module_nsConversationListPanel",
|
|
967
967
|
nsConversations: "styles_module_nsConversations",
|
|
968
|
-
nsBodyWidth: "styles_module_nsBodyWidth",
|
|
969
968
|
nsBubbleList: "styles_module_nsBubbleList",
|
|
970
969
|
nsChatHeader: "styles_module_nsChatHeader",
|
|
971
970
|
nsChatTitle: "styles_module_nsChatTitle",
|
|
@@ -973,19 +972,19 @@ var styles_module_default2 = {
|
|
|
973
972
|
chatWelcomeWrap: "styles_module_chatWelcomeWrap",
|
|
974
973
|
chatWelcome: "styles_module_chatWelcome",
|
|
975
974
|
chatWelcomePrompts: "styles_module_chatWelcomePrompts",
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
979
|
-
|
|
975
|
+
nsSenderListTitle: "styles_module_nsSenderListTitle",
|
|
976
|
+
nsSenderList: "styles_module_nsSenderList",
|
|
977
|
+
nsSenderListItem: "styles_module_nsSenderListItem",
|
|
978
|
+
nsSenderListFooter: "styles_module_nsSenderListFooter",
|
|
980
979
|
nsChatUserName: "styles_module_nsChatUserName",
|
|
981
980
|
nsSenderReferenceHeaderTitle: "styles_module_nsSenderReferenceHeaderTitle",
|
|
982
981
|
nsSenderReferenceHeaderContent: "styles_module_nsSenderReferenceHeaderContent",
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
|
|
982
|
+
nsAvatarListContainer: "styles_module_nsAvatarListContainer",
|
|
983
|
+
nsAvatarList: "styles_module_nsAvatarList",
|
|
984
|
+
nsAvatarListItem: "styles_module_nsAvatarListItem",
|
|
985
|
+
nsAvatarListItemIcon: "styles_module_nsAvatarListItemIcon",
|
|
986
|
+
nsAvatarListItemIconActive: "styles_module_nsAvatarListItemIconActive",
|
|
987
|
+
nsAvatarListItemName: "styles_module_nsAvatarListItemName"
|
|
989
988
|
};
|
|
990
989
|
function extractThinkContent(content) {
|
|
991
990
|
let main = content;
|
|
@@ -1024,7 +1023,7 @@ var MessageAIRender_default = ({ message: message3, placement }) => {
|
|
|
1024
1023
|
Bubble,
|
|
1025
1024
|
{
|
|
1026
1025
|
placement,
|
|
1027
|
-
className:
|
|
1026
|
+
className: classNames8({ [styles_module_default2.loadingMessage]: message3.type && message3.type !== "TEXT_MESSAGE_END" }),
|
|
1028
1027
|
content: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
1029
1028
|
thinkContents.length > 0 && /* @__PURE__ */ jsx(
|
|
1030
1029
|
Collapse,
|
|
@@ -1097,7 +1096,7 @@ var BubbleListItems_default = ({ firstMessage = false, avatar = { user: false, a
|
|
|
1097
1096
|
/* @__PURE__ */ jsx(
|
|
1098
1097
|
Welcome,
|
|
1099
1098
|
{
|
|
1100
|
-
className:
|
|
1099
|
+
className: classNames8(styles_module_default2.chatWelcome, "p-t-32"),
|
|
1101
1100
|
variant: "borderless",
|
|
1102
1101
|
icon: /* @__PURE__ */ jsx(Avatar, { shape: "square", size: 58, src: receiverState.active.logo }),
|
|
1103
1102
|
title: `\u4F60\u597D\uFF0C\u6211\u662F${receiverState.active.name || ""}`,
|
|
@@ -1115,7 +1114,7 @@ var BubbleListItems_default = ({ firstMessage = false, avatar = { user: false, a
|
|
|
1115
1114
|
label: "\u{1F914} \u63A8\u8350\u95EE\u9898:",
|
|
1116
1115
|
children: receiverState.active.config.recommendQuestions.map(({ question }) => ({
|
|
1117
1116
|
key: question,
|
|
1118
|
-
description: /* @__PURE__ */ jsx("span", { onClick: () => chatStore.sendMessage(question), className:
|
|
1117
|
+
description: /* @__PURE__ */ jsx("span", { onClick: () => chatStore.sendMessage(question), className: classNames8(styles_module_default2.chatWelcomePrompts, "text-ellipsis"), children: question })
|
|
1119
1118
|
}))
|
|
1120
1119
|
}
|
|
1121
1120
|
]
|
|
@@ -1248,7 +1247,7 @@ var BubbleListItems_default = ({ firstMessage = false, avatar = { user: false, a
|
|
|
1248
1247
|
autoScroll: false,
|
|
1249
1248
|
ref: listRef,
|
|
1250
1249
|
items: bubbleListItems,
|
|
1251
|
-
className:
|
|
1250
|
+
className: classNames8(styles_module_default2.nsBubbleList, "height-full", "scroll-fade-in", "zero-chat-bubbles"),
|
|
1252
1251
|
onScroll: handleScroll
|
|
1253
1252
|
},
|
|
1254
1253
|
conversationState.active.id
|
|
@@ -1279,18 +1278,18 @@ var CharacterList_default = () => {
|
|
|
1279
1278
|
okText: "\u5207\u6362\u6027\u683C",
|
|
1280
1279
|
onOk: () => chatStore.switchCharacter(activeCharacter),
|
|
1281
1280
|
confirmLoading: characterState.switchLoading,
|
|
1282
|
-
children: /* @__PURE__ */ jsx("div", { className: styles_module_default2.
|
|
1281
|
+
children: /* @__PURE__ */ jsx("div", { className: styles_module_default2.nsAvatarListContainer, children: /* @__PURE__ */ jsx(Row, { wrap: true, gutter: [16, 32], className: styles_module_default2.nsAvatarList, children: characterState.list.map((item) => /* @__PURE__ */ jsx(Col, { span: 6, children: /* @__PURE__ */ jsxs(Flex, { vertical: true, align: "center", className: styles_module_default2.nsAvatarListItem, onClick: () => setActiveCharacter(item), children: [
|
|
1283
1282
|
/* @__PURE__ */ jsx(
|
|
1284
1283
|
Avatar,
|
|
1285
1284
|
{
|
|
1286
|
-
className:
|
|
1287
|
-
[styles_module_default2.
|
|
1285
|
+
className: classNames8(styles_module_default2.nsAvatarListItemIcon, "cursor-pointer", {
|
|
1286
|
+
[styles_module_default2.nsAvatarListItemIconActive]: activeCharacter.id === item.id
|
|
1288
1287
|
}),
|
|
1289
1288
|
size: 50,
|
|
1290
1289
|
src: /* @__PURE__ */ jsx("img", { src: item.logo, alt: "\u5934\u50CF" })
|
|
1291
1290
|
}
|
|
1292
1291
|
),
|
|
1293
|
-
/* @__PURE__ */ jsx("div", { className: styles_module_default2.
|
|
1292
|
+
/* @__PURE__ */ jsx("div", { className: styles_module_default2.nsAvatarListItemName, children: item.characterName })
|
|
1294
1293
|
] }) }, item.id)) }) })
|
|
1295
1294
|
}
|
|
1296
1295
|
);
|
|
@@ -1378,7 +1377,7 @@ var ChatHeader_default = ({
|
|
|
1378
1377
|
const chatStore = useChatStore();
|
|
1379
1378
|
const receiverState = useSnapshot(chatStore.receiver);
|
|
1380
1379
|
const configState = useSnapshot(chatStore.config);
|
|
1381
|
-
return /* @__PURE__ */ jsx(Fragment, { children: /* @__PURE__ */ jsxs(Flex, { justify: "space-between", align: "center", className: styles_module_default2.nsChatHeader, children: [
|
|
1380
|
+
return /* @__PURE__ */ jsx(Fragment, { children: /* @__PURE__ */ jsxs(Flex, { justify: "space-between", align: "center", className: classNames8(styles_module_default2.nsChatHeader, "zero-chat-header"), children: [
|
|
1382
1381
|
/* @__PURE__ */ jsxs(Flex, { gap: 4, align: "center", children: [
|
|
1383
1382
|
/* @__PURE__ */ jsx(
|
|
1384
1383
|
RenderWrapper,
|
|
@@ -1431,7 +1430,8 @@ var ChatHeader_default = ({
|
|
|
1431
1430
|
|
|
1432
1431
|
// src/components/styles.module.less
|
|
1433
1432
|
var styles_module_default3 = {
|
|
1434
|
-
|
|
1433
|
+
chatAttachments: "styles_module_chatAttachments",
|
|
1434
|
+
chatSender: "styles_module_chatSender"
|
|
1435
1435
|
};
|
|
1436
1436
|
var Attachments_default = forwardRef(({ fileUploadConfig = [], fileList = [], onChange, extraParams }, ref) => {
|
|
1437
1437
|
const { message: message3 } = App.useApp();
|
|
@@ -1566,7 +1566,7 @@ var Attachments_default = forwardRef(({ fileUploadConfig = [], fileList = [], on
|
|
|
1566
1566
|
return /* @__PURE__ */ jsx(
|
|
1567
1567
|
Attachments,
|
|
1568
1568
|
{
|
|
1569
|
-
className: styles_module_default3.
|
|
1569
|
+
className: styles_module_default3.chatAttachments,
|
|
1570
1570
|
accept: acceptStr,
|
|
1571
1571
|
multiple: true,
|
|
1572
1572
|
customRequest: onCustomRequest,
|
|
@@ -1634,6 +1634,7 @@ var ChatSender_default = forwardRef(
|
|
|
1634
1634
|
return /* @__PURE__ */ jsx(Suggestion, { items: [], onSelect: (itemVal) => setInputValue(`[${itemVal}]:`), children: ({}) => /* @__PURE__ */ jsx(
|
|
1635
1635
|
Sender,
|
|
1636
1636
|
{
|
|
1637
|
+
className: styles_module_default3.chatSender,
|
|
1637
1638
|
ref: senderRef,
|
|
1638
1639
|
value: inputValue,
|
|
1639
1640
|
header: senderHeader,
|
|
@@ -1682,16 +1683,16 @@ var SenderPromptsItems_default = () => {
|
|
|
1682
1683
|
{
|
|
1683
1684
|
itemLayout: "horizontal",
|
|
1684
1685
|
split: false,
|
|
1685
|
-
className: styles_module_default2.
|
|
1686
|
+
className: styles_module_default2.nsSenderList,
|
|
1686
1687
|
dataSource: question.items,
|
|
1687
|
-
renderItem: (item) => /* @__PURE__ */ jsx(List.Item, { onClick: () => chatStore.sendMessage(item.question), className: styles_module_default2.
|
|
1688
|
-
footer: /* @__PURE__ */ jsx(Flex, { justify: "end", className: styles_module_default2.
|
|
1688
|
+
renderItem: (item) => /* @__PURE__ */ jsx(List.Item, { onClick: () => chatStore.sendMessage(item.question), className: styles_module_default2.nsSenderListItem, children: item.question }),
|
|
1689
|
+
footer: /* @__PURE__ */ jsx(Flex, { justify: "end", className: styles_module_default2.nsSenderListFooter, children: "(\u60A8\u53EF\u70B9\u51FB\u4EE5\u4E0A\u95EE\u9898\u5F00\u542FAI\u4F53\u9A8C)" })
|
|
1689
1690
|
}
|
|
1690
1691
|
),
|
|
1691
1692
|
title: /* @__PURE__ */ jsx(
|
|
1692
1693
|
"div",
|
|
1693
1694
|
{
|
|
1694
|
-
className:
|
|
1695
|
+
className: classNames8(styles_module_default2.nsSenderListTitle, "text-ellipsis"),
|
|
1695
1696
|
children: `${receiverState.active.name}\u5F00\u59CB\u5173\u6CE8${question.name}\u5185\u5BB9\uFF01`
|
|
1696
1697
|
}
|
|
1697
1698
|
),
|
|
@@ -1705,7 +1706,7 @@ var SenderPromptsItems_default = () => {
|
|
|
1705
1706
|
return component;
|
|
1706
1707
|
};
|
|
1707
1708
|
var ChatSender_default2 = forwardRef(
|
|
1708
|
-
({ placeholder, extraBtn = false, referencesBtn = false, sendBtnProps
|
|
1709
|
+
({ placeholder, extraBtn = false, referencesBtn = false, sendBtnProps, footerBelow = false, prompts = true }, ref) => {
|
|
1709
1710
|
const chatStore = useChatStore();
|
|
1710
1711
|
const receiverState = useSnapshot(chatStore.receiver);
|
|
1711
1712
|
const conversationState = useSnapshot(chatStore.conversation);
|
|
@@ -1720,7 +1721,7 @@ var ChatSender_default2 = forwardRef(
|
|
|
1720
1721
|
chatStore.sendMessage();
|
|
1721
1722
|
}, 10);
|
|
1722
1723
|
};
|
|
1723
|
-
return /* @__PURE__ */ jsxs(Flex, { vertical: true, gap: 8, children: [
|
|
1724
|
+
return /* @__PURE__ */ jsxs(Flex, { vertical: true, gap: 8, className: "zero-chat-sender", children: [
|
|
1724
1725
|
/* @__PURE__ */ jsx(RenderWrapper, { control: prompts, DefaultComponent: SenderPromptsItems_default }),
|
|
1725
1726
|
/* @__PURE__ */ jsx(
|
|
1726
1727
|
ChatSender_default,
|
|
@@ -1740,7 +1741,7 @@ var ChatSender_default2 = forwardRef(
|
|
|
1740
1741
|
fileUpload: {
|
|
1741
1742
|
config: receiverState.active.config?.fileUpload
|
|
1742
1743
|
},
|
|
1743
|
-
sendBtnProps,
|
|
1744
|
+
sendBtnProps: isFunction(sendBtnProps) ? sendBtnProps() : {},
|
|
1744
1745
|
extraFooterBelow: /* @__PURE__ */ jsx(RenderWrapper, { control: footerBelow }),
|
|
1745
1746
|
extraFooter: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
1746
1747
|
receiverState.active.feature?.deepThink && /* @__PURE__ */ jsx(
|
|
@@ -1818,7 +1819,7 @@ var ConversationListHeader_default = () => {
|
|
|
1818
1819
|
type: "primary",
|
|
1819
1820
|
shape: "round",
|
|
1820
1821
|
onClick: () => chatStore.createConversation(),
|
|
1821
|
-
className:
|
|
1822
|
+
className: classNames8("m-t-16"),
|
|
1822
1823
|
icon: /* @__PURE__ */ jsx(PlusOutlined, {}),
|
|
1823
1824
|
children: "\u65B0\u5EFA\u4F1A\u8BDD"
|
|
1824
1825
|
}
|
|
@@ -1826,7 +1827,7 @@ var ConversationListHeader_default = () => {
|
|
|
1826
1827
|
] });
|
|
1827
1828
|
};
|
|
1828
1829
|
var ConversationListPanel_default = ({ header }) => {
|
|
1829
|
-
return /* @__PURE__ */ jsxs(Flex, { vertical: true, className:
|
|
1830
|
+
return /* @__PURE__ */ jsxs(Flex, { vertical: true, className: classNames8("height-full", "zero-chat-conversations", styles_module_default2.nsConversationListPanel), children: [
|
|
1830
1831
|
/* @__PURE__ */ jsx(RenderWrapper, { control: header, DefaultComponent: ConversationListHeader_default }),
|
|
1831
1832
|
/* @__PURE__ */ jsx("div", { className: "full-scroll", children: /* @__PURE__ */ jsx(ConversationList_default, {}) })
|
|
1832
1833
|
] });
|
|
@@ -1838,7 +1839,9 @@ var styles_module_default4 = {
|
|
|
1838
1839
|
nsPreviewHeaderTitle: "styles_module_nsPreviewHeaderTitle",
|
|
1839
1840
|
nsChatSenderHeader: "styles_module_nsChatSenderHeader",
|
|
1840
1841
|
nsDisclaimerNotice: "styles_module_nsDisclaimerNotice",
|
|
1841
|
-
nsChatLayout: "styles_module_nsChatLayout"
|
|
1842
|
+
nsChatLayout: "styles_module_nsChatLayout",
|
|
1843
|
+
nsChatBody: "styles_module_nsChatBody",
|
|
1844
|
+
nsBodyWidth: "styles_module_nsBodyWidth"
|
|
1842
1845
|
};
|
|
1843
1846
|
var layouts_default = forwardRef(({ theme, params, userInfo, hooks, layout, config }, ref) => {
|
|
1844
1847
|
const chatStore = useMemo(() => createChatStore(), []);
|
|
@@ -1906,7 +1909,7 @@ var layouts_default = forwardRef(({ theme, params, userInfo, hooks, layout, conf
|
|
|
1906
1909
|
useEffect(() => {
|
|
1907
1910
|
configState.hooks?.onBeforeInit?.();
|
|
1908
1911
|
}, []);
|
|
1909
|
-
return /* @__PURE__ */ jsx(XProvider, { theme: { cssVar: true, ...theme }, children: /* @__PURE__ */ jsx(ChatProvider, { store: chatStore, children: /* @__PURE__ */ jsx(Spin, { spinning: receiverState.loading, wrapperClassName: "full-spin", children: /* @__PURE__ */ jsxs(Flex, { vertical: true, className:
|
|
1912
|
+
return /* @__PURE__ */ jsx(XProvider, { theme: { cssVar: true, ...theme }, children: /* @__PURE__ */ jsx(ChatProvider, { store: chatStore, children: /* @__PURE__ */ jsx(Spin, { spinning: receiverState.loading, wrapperClassName: "full-spin", children: /* @__PURE__ */ jsxs(Flex, { vertical: true, className: classNames8(styles_module_default4.nsChatLayout, "zero-chat-layout", "height-full"), children: [
|
|
1910
1913
|
/* @__PURE__ */ jsx(RenderWrapper, { control: configState.layout.globalHeader, DefaultComponent: ChatHeader_default }),
|
|
1911
1914
|
/* @__PURE__ */ jsxs(Flex, { className: "full-scroll", children: [
|
|
1912
1915
|
/* @__PURE__ */ jsx(RenderWrapper, { control: configState.layout.leftPanel }),
|
|
@@ -1960,32 +1963,41 @@ var layouts_default = forwardRef(({ theme, params, userInfo, hooks, layout, conf
|
|
|
1960
1963
|
}
|
|
1961
1964
|
)
|
|
1962
1965
|
] }) }),
|
|
1963
|
-
/* @__PURE__ */ jsx(Splitter.Panel, { collapsible: false, max: 800, min: 400, size: sizes[1], children: /* @__PURE__ */ jsxs(Flex, { vertical: true, className:
|
|
1966
|
+
/* @__PURE__ */ jsx(Splitter.Panel, { collapsible: false, max: 800, min: 400, size: sizes[1], children: /* @__PURE__ */ jsxs(Flex, { vertical: true, className: classNames8("height-full"), children: [
|
|
1964
1967
|
/* @__PURE__ */ jsx(RenderWrapper, { control: configState.layout.chatHeader, DefaultComponent: ChatHeader_default }),
|
|
1965
|
-
/* @__PURE__ */ jsx(Flex, { vertical: true, className:
|
|
1966
|
-
|
|
1967
|
-
|
|
1968
|
-
|
|
1969
|
-
|
|
1970
|
-
|
|
1971
|
-
|
|
1972
|
-
|
|
1973
|
-
|
|
1974
|
-
|
|
1975
|
-
|
|
1976
|
-
|
|
1977
|
-
|
|
1978
|
-
|
|
1979
|
-
|
|
1980
|
-
|
|
1981
|
-
|
|
1982
|
-
|
|
1983
|
-
|
|
1984
|
-
|
|
1985
|
-
|
|
1986
|
-
|
|
1987
|
-
|
|
1988
|
-
|
|
1968
|
+
/* @__PURE__ */ jsx(Flex, { vertical: true, className: classNames8("full-scroll"), children: /* @__PURE__ */ jsxs(
|
|
1969
|
+
Flex,
|
|
1970
|
+
{
|
|
1971
|
+
justify: "center",
|
|
1972
|
+
vertical: true,
|
|
1973
|
+
gap: 24,
|
|
1974
|
+
className: classNames8("height-full", styles_module_default4.nsChatBody, "zero-chat-body", styles_module_default4.nsBodyWidth),
|
|
1975
|
+
children: [
|
|
1976
|
+
shouldRender(configState.layout.messageList) && /* @__PURE__ */ jsx("div", { className: "full-scroll", children: /* @__PURE__ */ jsx(RenderWrapper, { control: configState.layout.messageList, DefaultComponent: BubbleListItems_default }) }),
|
|
1977
|
+
/* @__PURE__ */ jsxs(Flex, { vertical: true, gap: 8, children: [
|
|
1978
|
+
/* @__PURE__ */ jsx(
|
|
1979
|
+
RenderWrapper,
|
|
1980
|
+
{
|
|
1981
|
+
control: configState.layout.senderHeader,
|
|
1982
|
+
DefaultComponent: /* @__PURE__ */ jsxs("div", { className: styles_module_default4.nsChatSenderHeader, children: [
|
|
1983
|
+
"\u6211\u662F ",
|
|
1984
|
+
receiverState.active.name
|
|
1985
|
+
] })
|
|
1986
|
+
}
|
|
1987
|
+
),
|
|
1988
|
+
/* @__PURE__ */ jsx(RenderWrapper, { ref: senderRef, control: configState.layout.sender, DefaultComponent: ChatSender_default2 }),
|
|
1989
|
+
/* @__PURE__ */ jsx(
|
|
1990
|
+
RenderWrapper,
|
|
1991
|
+
{
|
|
1992
|
+
control: configState.layout.disclaimerNotice,
|
|
1993
|
+
DefaultComponent: /* @__PURE__ */ jsx("div", { className: styles_module_default4.nsDisclaimerNotice, children: "\u5185\u5BB9\u7531AI\u751F\u6210\uFF0C\u4EC5\u4F9B\u53C2\u8003\uFF0C\u8BF7\u4ED4\u7EC6\u7504\u522B" })
|
|
1994
|
+
}
|
|
1995
|
+
)
|
|
1996
|
+
] }),
|
|
1997
|
+
/* @__PURE__ */ jsx(RenderWrapper, { control: configState.layout.senderFooter })
|
|
1998
|
+
]
|
|
1999
|
+
}
|
|
2000
|
+
) })
|
|
1989
2001
|
] }) })
|
|
1990
2002
|
] })
|
|
1991
2003
|
] })
|