@glodon-aiot/agent-cli-ui 3.18.1-alpha.16 → 3.19.0-alpha.17

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- const e = "@glodon-aiot/agent-cli-ui", t = "3.18.1-alpha.16", s = "./dist/es/index.mjs", i = "./dist/lib/index.js", o = "./dist/src/index.d.ts", n = {
1
+ const e = "@glodon-aiot/agent-cli-ui", t = "3.19.0-alpha.17", s = "./dist/es/index.mjs", i = "./dist/lib/index.js", o = "./dist/src/index.d.ts", n = {
2
2
  import: "./dist/es/index.mjs",
3
3
  require: "./dist/lib/index.js",
4
4
  types: "./dist/src/index.d.ts"
@@ -25,8 +25,8 @@ const e = "@glodon-aiot/agent-cli-ui", t = "3.18.1-alpha.16", s = "./dist/es/ind
25
25
  webpack: "*"
26
26
  }, p = {
27
27
  "@ant-design/icons": "^5.3.4",
28
- "@glodon-aiot/apis": "^3.18.1-alpha.16",
29
- "@glodon-aiot/bot-client-sdk": "^3.18.1-alpha.16",
28
+ "@glodon-aiot/apis": "^3.19.0-alpha.17",
29
+ "@glodon-aiot/bot-client-sdk": "^3.19.0-alpha.17",
30
30
  "@matejmazur/react-mathjax": "^0.1.10",
31
31
  "@react-pdf-viewer/core": "^3.12.0",
32
32
  "@react-pdf-viewer/default-layout": "^3.12.0",
@@ -1 +1 @@
1
- .gbot-dialog-modal .input-files{margin-bottom:8px;display:flex;gap:4px;width:100%;overflow-x:auto;overflow-y:hidden;flex-wrap:nowrap}.gbot-dialog-modal .file-preview{width:auto;border-radius:4px;border:1px solid #e8e9eb;background:#ffffff;position:relative;display:inline-block;max-height:80px;flex:0 0 auto}.gbot-dialog-modal .file-preview .file-icon{height:100%;width:48px}.gbot-dialog-modal .file-preview.thumb-40{display:flex;align-items:center;justify-content:center;width:40px;height:40px;max-height:40px;overflow:hidden}.gbot-dialog-modal .file-preview.thumb-40 .file-icon{width:100%;height:100%}.gbot-dialog-modal .file-preview.thumb-40 .file-icon .ant-image-img{width:100%;height:100%;object-fit:cover;display:block}.gbot-dialog-modal .file-preview.small{height:30px;width:150px;padding:3px 6px 3px 3px}.gbot-dialog-modal .file-preview.small .file-icon{width:24px}.gbot-dialog-modal .file-preview .file-desc{flex:1;overflow:hidden}.gbot-dialog-modal .file-preview .file-desc .file-desc-name{color:#5c5f66;font-size:12px;font-style:normal;font-weight:700;line-height:150%;margin-bottom:4px}.gbot-dialog-modal .file-preview .file-action{position:absolute;right:0;top:0}.gbot-dialog-modal .file-preview .file-process{background-color:#f7f7f9;border-radius:4px;width:10px;height:10px;line-height:10px;text-align:center;display:inline-flex;align-items:center;justify-content:center}.gbot-dialog-modal .file-preview .file-remove{display:inline-block;border-radius:4px;width:14px;height:14px;line-height:14px;text-align:center;color:#84868c;border:1px solid #e8e9eb;display:inline-flex;align-items:center;justify-content:center;background-color:#f7f7f9}.gbot-dialog-modal .file-preview .file-remove:hover{background-color:#fff;color:#b452ff}.gbot-dialog-modal .file-remove-tooltip .gbot-tooltip-content .gbot-tooltip-inner{padding:12px}
1
+ .gbot-dialog-modal .home-footer{background:#f5f5f5;width:100%;max-width:824px;margin:0 auto}.gbot-dialog-modal .home-footer .footer-warning{display:flex;justify-content:center;align-items:center;font-size:12px;font-weight:400;line-height:18px;text-align:left;color:#999}
@@ -1 +1 @@
1
- .gbot-dialog-modal .greeting{display:flex;flex-direction:column;align-items:center;flex:1;margin:0 auto;max-width:824px;width:100%;padding:16px 0}.gbot-dialog-modal .greeting-icon{width:74px;height:74px;border-radius:50%;box-shadow:0 6px 16px 2px #070c1414;padding:5px;margin-bottom:24px}.gbot-dialog-modal .greeting-icon img{width:64px;height:64px}.gbot-dialog-modal .greeting-word{font-weight:700;font-size:24px;line-height:30px;margin-bottom:24px}.gbot-dialog-modal .greeting-questions{width:100%;padding:0 12px}.gbot-dialog-modal.inlay .greeting{margin-top:40px}.gbot-dialog-modal.float .greeting{overflow-y:auto;flex:none}
1
+ .gbot-dialog-modal .input-files{margin-bottom:8px;display:flex;gap:4px;width:100%;overflow-x:auto;overflow-y:hidden;flex-wrap:nowrap}.gbot-dialog-modal .file-preview{width:auto;border-radius:4px;border:1px solid #e8e9eb;background:#ffffff;position:relative;display:inline-block;max-height:80px;flex:0 0 auto}.gbot-dialog-modal .file-preview .file-icon{height:100%;width:48px}.gbot-dialog-modal .file-preview.thumb-40{display:flex;align-items:center;justify-content:center;width:40px;height:40px;max-height:40px;overflow:hidden}.gbot-dialog-modal .file-preview.thumb-40 .file-icon{width:100%;height:100%}.gbot-dialog-modal .file-preview.thumb-40 .file-icon .ant-image-img{width:100%;height:100%;object-fit:cover;display:block}.gbot-dialog-modal .file-preview.small{height:30px;width:150px;padding:3px 6px 3px 3px}.gbot-dialog-modal .file-preview.small .file-icon{width:24px}.gbot-dialog-modal .file-preview .file-desc{flex:1;overflow:hidden}.gbot-dialog-modal .file-preview .file-desc .file-desc-name{color:#5c5f66;font-size:12px;font-style:normal;font-weight:700;line-height:150%;margin-bottom:4px}.gbot-dialog-modal .file-preview .file-action{position:absolute;right:0;top:0}.gbot-dialog-modal .file-preview .file-process{background-color:#f7f7f9;border-radius:4px;width:10px;height:10px;line-height:10px;text-align:center;display:inline-flex;align-items:center;justify-content:center}.gbot-dialog-modal .file-preview .file-remove{display:inline-block;border-radius:4px;width:14px;height:14px;line-height:14px;text-align:center;color:#84868c;border:1px solid #e8e9eb;display:inline-flex;align-items:center;justify-content:center;background-color:#f7f7f9}.gbot-dialog-modal .file-preview .file-remove:hover{background-color:#fff;color:#b452ff}.gbot-dialog-modal .file-remove-tooltip .gbot-tooltip-content .gbot-tooltip-inner{padding:12px}
@@ -1 +1 @@
1
- .gbot-dialog-modal .history-item{margin-bottom:16px}.gbot-dialog-modal .history-item .history-item-user{width:100%}.gbot-dialog-modal .history-item .history-item-user .item-user-panel{display:flex;justify-content:flex-end}.gbot-dialog-modal .history-item .history-item-user .item-user-panel .user-panel-main{max-width:100%}.gbot-dialog-modal .history-item .history-item-user .item-user-panel .user-panel-main .item-user-content{background:#f9f2ff;padding:12px;border-radius:12px 2px 12px 12px;border:1px solid #9c24f2;display:inline-block;width:auto;max-width:100%;color:#070c14;word-wrap:break-word}.gbot-dialog-modal .history-item .history-item-user .item-user-file{display:flex-end;margin-top:10px}.gbot-dialog-modal .history-item .history-item-user .item-user-file-dialog{display:flex-end;margin-bottom:10px}.gbot-dialog-modal .history-item .history-item-user .item-user-images{width:100%;display:flex;justify-content:flex-end}.gbot-dialog-modal .history-item .history-item-user .item-user-images>div{width:100%;max-width:100%}.gbot-dialog-modal .history-item .history-item-user .item-user-images>div>.markdown{width:100%;max-width:100%;display:flex;gap:4px;justify-content:flex-end;flex-wrap:wrap;margin-bottom:12px}.gbot-dialog-modal .history-item .history-item-user .item-user-images>div>.markdown>p{margin-bottom:0}.gbot-dialog-modal .history-item .history-item-user .item-user-images>div>.markdown>p .gbot-image{display:flex;align-items:center;justify-content:center;flex:0 0 auto;width:40px;height:40px;border-radius:4px;overflow:hidden;background-color:#fff}.gbot-dialog-modal .history-item .history-item-user .item-user-images>div>.markdown>p .gbot-image .gbot-image-mask-info{padding:0 4px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.gbot-dialog-modal .history-item .history-item-user .item-user-images>div>.markdown>p .gbot-image img{object-fit:cover;display:block;margin-bottom:0}.gbot-dialog-modal .history-item .history-item-user ::selection{background-color:#b1d7ffb3;color:#fff}.gbot-dialog-modal .history-item .history-item-bot{width:100%;border-radius:2px 12px 12px;background:white;padding:0 12px}.gbot-dialog-modal .history-item .history-item-bot .item-bot-plugin{padding-top:12px}.gbot-dialog-modal .history-item .history-item-bot .item-bot-plugin .bot-plugin-status .plugin-status-success{display:inline-block;width:14px;height:14px;color:#fff;background:#47d1cb;border-radius:50%;font-size:10px;display:flex;align-items:center;justify-content:center}.gbot-dialog-modal .history-item .history-item-bot .item-bot-plugin .bot-plugin-status .plugin-status-error{display:inline-block;width:14px;height:14px;color:#fff;background:#f95b81;border-radius:50%;font-size:10px;display:flex;align-items:center;justify-content:center}.gbot-dialog-modal .history-item .history-item-bot .item-bot-plugin .bot-plugin-status .plugin-status-loading{display:inline-block;width:14px;height:14px;color:#477bff;border-radius:50%;font-size:10px;display:flex;align-items:center;justify-content:center}.gbot-dialog-modal .history-item .history-item-bot .item-bot-plugin .bot-plugin-title{font-weight:700;color:#000000a6}.gbot-dialog-modal .history-item .history-item-bot .item-bot-plugin .bot-plugin-action{border:1px solid #00000026;border-radius:4px;color:#000000e0;padding:1px 8px}.gbot-dialog-modal .history-item .history-item-bot .item-bot-plugin .gbot-collapse-header{padding:0;height:38px;display:flex;align-items:center}.gbot-dialog-modal .history-item .history-item-bot .item-bot-plugin .gbot-collapse-content-box{padding:0}.gbot-dialog-modal .history-item .history-item-bot .item-bot-plugin .bot-plugin-content{height:32px;line-height:32px;font-weight:700}.gbot-dialog-modal .history-item .history-item-bot .item-bot-plugin .bot-plugin-json{background:white}.gbot-dialog-modal .history-item .history-item-bot .item-bot-net{padding-top:12px}.gbot-dialog-modal .history-item .history-item-bot .item-bot-content{width:100%;border-radius:2px 12px 12px;background:white;padding:12px 0;word-wrap:break-word}.gbot-dialog-modal .history-item .history-item-bot .item-bot-content .content-think{margin-bottom:12px}.gbot-dialog-modal .history-item .history-item-bot .item-bot-content .content-think .think-top{font-size:14px;line-height:24px;color:#070c14;display:flex;align-items:center;margin-bottom:12px;cursor:pointer}.gbot-dialog-modal .history-item .history-item-bot .item-bot-content .content-think .think-top img{width:24px;margin-right:4px}.gbot-dialog-modal .history-item .history-item-bot .item-bot-content .content-think .think-top .think-action{margin-left:8px}.gbot-dialog-modal .history-item .history-item-bot .item-bot-content .content-think .think-bottom{font-size:14px;line-height:150%;color:#999;position:relative}.gbot-dialog-modal .history-item .history-item-bot .item-bot-content .content-think .think-bottom .bottom-left{background:#d9d9d9;width:1px;position:absolute;left:10px;top:4px;bottom:4px}.gbot-dialog-modal .history-item .history-item-bot .item-bot-content .content-think .think-bottom .bottom-left .thinking{position:absolute;left:-5px;top:0;width:12px;height:12px;background:#b752ea;border-radius:50%}.gbot-dialog-modal .history-item .history-item-bot .item-bot-content .content-think .think-bottom .bottom-left .thinked{position:absolute;z-index:100;left:-5px;top:0;width:12px;height:12px;background:#04d68d;border-radius:50%;color:#fff;display:flex;align-items:center;justify-content:center;font-size:8px}.gbot-dialog-modal .history-item .history-item-bot .item-bot-content .content-think .think-bottom .bottom-right{padding-left:22px}.gbot-dialog-modal .history-item .gbot-collapse-item{border-radius:4px;background-color:#f5f5f5;margin-bottom:8px;padding:0 0 0 8px}.gbot-dialog-modal .history-item .gbot-collapse-item .gbot-collapse-content{padding-bottom:8px}.gbot-dialog-modal .history-item .gbot-collapse-item:last-child{margin-bottom:0}.gbot-dialog-modal .history-item .gbot-collapse-header-text{width:100%}.gbot-dialog-modal .history-item .think{color:#999}.gbot-dialog-modal.inlay .history-item__user{display:flex;justify-content:flex-end}.gbot-dialog-modal.inlay .history-item-user,.gbot-dialog-modal.inlay .history-item-bot{max-width:calc(100% - 64px)}.gbot-dialog-modal .session-item-overlay-popover .gbot-popover-inner-content{padding:6px}.gbot-dialog-modal .session-item-overlay-popover .gbot-popover-arrow{display:none}
1
+ .gbot-dialog-modal .greeting{display:flex;flex-direction:column;align-items:center;flex:1;margin:0 auto;max-width:824px;width:100%;padding:16px 0}.gbot-dialog-modal .greeting-icon{width:74px;height:74px;border-radius:50%;box-shadow:0 6px 16px 2px #070c1414;padding:5px;margin-bottom:24px}.gbot-dialog-modal .greeting-icon img{width:64px;height:64px}.gbot-dialog-modal .greeting-word{font-weight:700;font-size:24px;line-height:30px;margin-bottom:24px}.gbot-dialog-modal .greeting-questions{width:100%;padding:0 12px}.gbot-dialog-modal.inlay .greeting{margin-top:40px}.gbot-dialog-modal.float .greeting{overflow-y:auto;flex:none}
@@ -1 +1 @@
1
- .gbot-dialog-modal .home-footer{background:#f5f5f5;width:100%;max-width:824px;margin:0 auto}.gbot-dialog-modal .home-footer .footer-warning{display:flex;justify-content:center;align-items:center;font-size:12px;font-weight:400;line-height:18px;text-align:left;color:#999}
1
+ .gbot-dialog-modal.inlay .questions,.gbot-dialog-modal.float .questions{width:100%}.gbot-dialog-modal .questions .question-tip{display:flex;align-items:center;margin-bottom:10px;height:24px;color:#84868c}.gbot-dialog-modal .questions .question-tip img{width:24px;height:24px}.gbot-dialog-modal .questions .question-row{max-height:260px;overflow-y:auto}.gbot-dialog-modal .questions .question-pannel{background:white;padding:12px;border-radius:8px;width:100%;cursor:pointer;border:1px solid transparent}.gbot-dialog-modal .questions .question-pannel .question-top{font-size:16px;height:32px;color:#070c14;font-weight:700;display:flex;width:100%}.gbot-dialog-modal .questions .question-pannel .question-top .question-top-tip{flex:0 0 24px;margin-right:8px}.gbot-dialog-modal .questions .question-pannel .question-top .question-top-title{flex:0 0 1;overflow:hidden;display:flex;align-items:center}.gbot-dialog-modal .questions .question-pannel .question-top .question-top-type{margin-left:8px;flex:0 0 24px}.gbot-dialog-modal .questions .question-pannel .question-top .question-only-plus-file{margin-left:0}.gbot-dialog-modal .questions .question-pannel .question-top img{width:24px}.gbot-dialog-modal .questions .question-pannel .not-have-top{display:none}.gbot-dialog-modal .questions .question-pannel .question-bottom{font-size:14px;color:#070c14;line-height:21px}.gbot-dialog-modal .questions .question-pannel .multiline-question{height:56px;margin-top:-7px}.gbot-dialog-modal .questions .question-pannel__active{border:1px solid #b452ff;transition:all .25s}.gbot-dialog-modal .questions .multiline-question-pannel{padding:16px 12px}.gbot-dialog-modal .recommend-tooltip-overlay .gbot-tooltip-inner{max-width:400px;max-height:300px;overflow-y:auto}
@@ -1 +1 @@
1
- .gbot-dialog-modal .quill-editor{position:relative}.gbot-dialog-modal .quill-editor .ql-container{border-radius:4px}.gbot-dialog-modal .quill-editor .ql-container:hover{border:1px solid none;outline:0}.gbot-dialog-modal .quill-editor .quill-editor-send{position:absolute;left:8px;right:8px;bottom:34px;height:0;display:flex;justify-content:space-between}.gbot-dialog-modal .quill-editor .ql-editor:before{font-style:normal;font-weight:400}.gbot-dialog-modal .quill-editor .ql-editor.hide-placeholder:before{display:none!important}.gbot-dialog-modal .quill-editor .shortcut-direct{width:15px;height:15px;display:flex;align-items:center;justify-content:center}.gbot-dialog-modal .quill-editor .shortcut-direct .gbot-popover-inner-content{padding:0}.gbot-dialog-modal .quill-editor .shortcut-direct .shortcut-direct-pannel{width:180px;padding:4px 0}.gbot-dialog-modal .quill-editor .shortcut-direct .shortcut-direct-pannel .shortcut-direct-item{display:flex;align-items:center;justify-content:space-between;padding:4px 12px;cursor:pointer}.gbot-dialog-modal .quill-editor .shortcut-direct .shortcut-direct-pannel .shortcut-direct-item .title{color:#393939}.gbot-dialog-modal .quill-editor .shortcut-direct .shortcut-direct-pannel .shortcut-direct-item .text{color:#84868c}.gbot-dialog-modal .quill-editor .shortcut-direct .shortcut-direct-pannel .shortcut-direct-item:hover{background:#f9f2ff}.gbot-dialog-modal .quill-editor .shortcut-direct .shortcut-direct-pannel .shortcut-direct-item__disabled{display:flex;align-items:center;justify-content:space-between;padding:4px 12px;cursor:not-allowed}.gbot-dialog-modal .quill-editor .shortcut-direct .shortcut-direct-pannel .shortcut-direct-item__disabled .title,.gbot-dialog-modal .quill-editor .shortcut-direct .shortcut-direct-pannel .shortcut-direct-item__disabled .text{color:#b8babf}.gbot-dialog-modal .quill-editor__active .ql-container{transition:all .3s,height 0;border:1px solid #b452ff;outline:0;box-shadow:none}.gbot-dialog-modal.inlay .quill-editor .quill-editor-wrapper{max-height:344px;position:relative}.gbot-dialog-modal.inlay .quill-editor .quill-editor-wrapper .ql-editor{min-height:134px;padding-bottom:32px}.gbot-dialog-modal.inlay .quill-editor .quill-editor-wrapper__scroll{overflow-y:auto;scrollbar-width:none}.gbot-dialog-modal.float .quill-editor .quill-editor-wrapper{max-height:200px;position:relative}.gbot-dialog-modal.float .quill-editor .quill-editor-wrapper .ql-editor{min-height:134px;padding-bottom:24px}.gbot-dialog-modal.float .quill-editor .quill-editor-wrapper__scroll{overflow-y:auto;scrollbar-width:none}
1
+ .gbot-dialog-modal .prompt-modal .title{display:flex;align-items:center;gap:8px;font-size:16px;font-weight:500;text-align:left;color:#161616}.gbot-dialog-modal .prompt-modal .content{font-size:14px;font-weight:400;line-height:22px;text-align:justified;color:#393939}
@@ -1 +1 @@
1
- .gbot-dialog-modal.inlay .questions,.gbot-dialog-modal.float .questions{width:100%}.gbot-dialog-modal .questions .question-tip{display:flex;align-items:center;margin-bottom:10px;height:24px;color:#84868c}.gbot-dialog-modal .questions .question-tip img{width:24px;height:24px}.gbot-dialog-modal .questions .question-row{max-height:260px;overflow-y:auto}.gbot-dialog-modal .questions .question-pannel{background:white;padding:12px;border-radius:8px;width:100%;cursor:pointer;border:1px solid transparent}.gbot-dialog-modal .questions .question-pannel .question-top{font-size:16px;height:32px;color:#070c14;font-weight:700;display:flex;width:100%}.gbot-dialog-modal .questions .question-pannel .question-top .question-top-tip{flex:0 0 24px;margin-right:8px}.gbot-dialog-modal .questions .question-pannel .question-top .question-top-title{flex:0 0 1;overflow:hidden;display:flex;align-items:center}.gbot-dialog-modal .questions .question-pannel .question-top .question-top-type{margin-left:8px;flex:0 0 24px}.gbot-dialog-modal .questions .question-pannel .question-top .question-only-plus-file{margin-left:0}.gbot-dialog-modal .questions .question-pannel .question-top img{width:24px}.gbot-dialog-modal .questions .question-pannel .not-have-top{display:none}.gbot-dialog-modal .questions .question-pannel .question-bottom{font-size:14px;color:#070c14;line-height:21px}.gbot-dialog-modal .questions .question-pannel .multiline-question{height:56px;margin-top:-7px}.gbot-dialog-modal .questions .question-pannel__active{border:1px solid #b452ff;transition:all .25s}.gbot-dialog-modal .questions .multiline-question-pannel{padding:16px 12px}.gbot-dialog-modal .recommend-tooltip-overlay .gbot-tooltip-inner{max-width:400px;max-height:300px;overflow-y:auto}
1
+ .gbot-dialog-modal .quill-editor{position:relative}.gbot-dialog-modal .quill-editor .ql-container{border-radius:4px}.gbot-dialog-modal .quill-editor .ql-container:hover{border:1px solid none;outline:0}.gbot-dialog-modal .quill-editor .quill-editor-send{position:absolute;left:8px;right:8px;bottom:34px;height:0;display:flex;justify-content:space-between}.gbot-dialog-modal .quill-editor .ql-editor:before{font-style:normal;font-weight:400}.gbot-dialog-modal .quill-editor .ql-editor.hide-placeholder:before{display:none!important}.gbot-dialog-modal .quill-editor .shortcut-direct{width:15px;height:15px;display:flex;align-items:center;justify-content:center}.gbot-dialog-modal .quill-editor .shortcut-direct .gbot-popover-inner-content{padding:0}.gbot-dialog-modal .quill-editor .shortcut-direct .shortcut-direct-pannel{width:180px;padding:4px 0}.gbot-dialog-modal .quill-editor .shortcut-direct .shortcut-direct-pannel .shortcut-direct-item{display:flex;align-items:center;justify-content:space-between;padding:4px 12px;cursor:pointer}.gbot-dialog-modal .quill-editor .shortcut-direct .shortcut-direct-pannel .shortcut-direct-item .title{color:#393939}.gbot-dialog-modal .quill-editor .shortcut-direct .shortcut-direct-pannel .shortcut-direct-item .text{color:#84868c}.gbot-dialog-modal .quill-editor .shortcut-direct .shortcut-direct-pannel .shortcut-direct-item:hover{background:#f9f2ff}.gbot-dialog-modal .quill-editor .shortcut-direct .shortcut-direct-pannel .shortcut-direct-item__disabled{display:flex;align-items:center;justify-content:space-between;padding:4px 12px;cursor:not-allowed}.gbot-dialog-modal .quill-editor .shortcut-direct .shortcut-direct-pannel .shortcut-direct-item__disabled .title,.gbot-dialog-modal .quill-editor .shortcut-direct .shortcut-direct-pannel .shortcut-direct-item__disabled .text{color:#b8babf}.gbot-dialog-modal .quill-editor__active .ql-container{transition:all .3s,height 0;border:1px solid #b452ff;outline:0;box-shadow:none}.gbot-dialog-modal.inlay .quill-editor .quill-editor-wrapper{max-height:344px;position:relative}.gbot-dialog-modal.inlay .quill-editor .quill-editor-wrapper .ql-editor{min-height:134px;padding-bottom:32px}.gbot-dialog-modal.inlay .quill-editor .quill-editor-wrapper__scroll{overflow-y:auto;scrollbar-width:none}.gbot-dialog-modal.float .quill-editor .quill-editor-wrapper{max-height:200px;position:relative}.gbot-dialog-modal.float .quill-editor .quill-editor-wrapper .ql-editor{min-height:134px;padding-bottom:24px}.gbot-dialog-modal.float .quill-editor .quill-editor-wrapper__scroll{overflow-y:auto;scrollbar-width:none}
@@ -1 +1 @@
1
- .gbot-dialog-modal .prompt-modal .title{display:flex;align-items:center;gap:8px;font-size:16px;font-weight:500;text-align:left;color:#161616}.gbot-dialog-modal .prompt-modal .content{font-size:14px;font-weight:400;line-height:22px;text-align:justified;color:#393939}
1
+ .gbot-dialog-modal .session-history-drawer .gbot-drawer-content-wrapper{height:calc(100% - 54px)!important;border-radius:12px 12px 0 0}.gbot-dialog-modal .session-history-drawer .gbot-drawer-content-wrapper .gbot-drawer-header{padding:12px 16px;border-bottom:none}.gbot-dialog-modal .session-history-drawer .gbot-drawer-content-wrapper .gbot-drawer-header .gbot-drawer-header-title{justify-content:space-between;flex-direction:row-reverse;font-size:16px;color:#393939}.gbot-dialog-modal .session-history-drawer .gbot-drawer-content-wrapper .gbot-drawer-header .gbot-drawer-header-title .gbot-drawer-close{margin:0;padding:0}.gbot-dialog-modal .session-history-drawer .gbot-drawer-content-wrapper .gbot-drawer-body{padding:0 16px 26px}.gbot-dialog-modal .session-history-drawer.loading-panel .gbot-drawer-body{display:flex;justify-content:center;align-items:center}.gbot-dialog-modal .session-history-drawer .bot-session-container .agent-sessions{width:100%}.gbot-dialog-modal .session-history-drawer .bot-session-container .agent-sessions .sessions-main{border:none}
@@ -1 +1 @@
1
- .gbot-dialog-modal .footer-upload{display:flex;justify-content:center;align-items:center}.gbot-dialog-modal .footer-upload .upload-enter{padding:0;height:24px;width:24px;display:flex;justify-content:center;align-items:center;cursor:pointer}.gbot-dialog-modal .footer-upload .upload-enter.disabled{color:#b8babf;cursor:not-allowed}.gbot-dialog-modal .footer-upload .upload-enter:hover{background:#ebebeb;border-radius:4px}.gbot-dialog-modal .file-upload{width:100%;display:flex;flex-direction:column}.gbot-dialog-modal .file-upload .gbot-upload-drag{background-color:#fff;border:unset}.gbot-dialog-modal .file-upload .gbot-upload-drag .gbot-upload-btn{padding:0}.gbot-dialog-modal .file-upload .file-upload-icon{font-size:35px;color:#d3d3d3}.gbot-dialog-modal .file-upload .file-upload-action{display:flex;justify-content:center;align-items:center;margin-bottom:12px}.gbot-dialog-modal .file-upload .file-upload-desc{text-align:left;display:flex;flex-direction:column;font-weight:400;font-size:12px;margin:0 auto;color:#84868c;width:232px;line-height:18px;padding-left:20px}.gbot-dialog-modal .file-upload .file-upload-desc .item-upload-desc{line-height:150%}.gbot-dialog-modal .file-upload .file-upload-desc .item-upload-desc__1{display:flex;align-items:center}.gbot-dialog-modal .file-upload .upload-wrapper{height:300px;overflow-y:auto;overflow-x:hidden}.gbot-dialog-modal .file-upload .upload-wrapper .upload-main{flex:1;width:100%;overflow-y:auto;margin-bottom:16px}.gbot-dialog-modal .file-upload .upload-wrapper .upload-main .upload-pannel{width:100%}.gbot-dialog-modal .file-upload .upload-wrapper .upload-main .upload-empty{width:100%;height:100%;display:flex;justify-content:center;align-items:center}.gbot-dialog-modal .file-upload .upload-wrapper .upload-main .upload-item{cursor:pointer}.gbot-dialog-modal .file-upload .upload-wrapper .upload-main .upload-item .upload-item-file-icon{display:inline-block;width:10px}.gbot-dialog-modal .file-upload .upload-wrapper .upload-main .upload-item .upload-item-name{margin-left:10px;display:inline-block;max-width:230px;word-break:break-all}.gbot-dialog-modal .file-upload .upload-wrapper .upload-main .upload-item .upload-item-upload-delete{display:inline-block;width:10px;color:#9c24f2;display:none}.gbot-dialog-modal .file-upload .upload-wrapper .upload-main .upload-item:hover{background:rgba(0,0,0,.04)}.gbot-dialog-modal .file-upload .upload-wrapper .upload-main .upload-item:hover .upload-item-upload-delete{display:inline-block}.gbot-dialog-modal .card-title{display:flex;justify-content:space-between;align-items:center;color:#393939;font-size:14px}.gbot-dialog-modal .card-title .name{font-weight:500}.gbot-dialog-modal .card-title .actions{font-weight:400;display:flex;gap:12px}.gbot-dialog-modal .card-title .actions .action{padding:4px 2px;cursor:pointer}.gbot-dialog-modal .card-title .actions .action .detail{display:flex;gap:6px;align-items:center}.gbot-dialog-modal .split-line{width:100%;height:1px;border:.5px solid #e8e9eb}.gbot-dialog-modal .upload-popover{z-index:1}
1
+ .gbot-dialog-modal .prompt-setting-panel{display:flex;align-items:center;justify-content:center}.gbot-dialog-modal .agent-prompt{margin:12px 12px 0;padding:12px;border-radius:4px;border:1px solid #e8e9eb;background:#fff;flex:1;max-width:824px}.gbot-dialog-modal .agent-prompt .prompt-header{font-size:16px;line-height:24px;font-weight:600;color:#84868c}.gbot-dialog-modal .agent-prompt .prompt-header .prompt-btn{color:#84868c}.gbot-dialog-modal .agent-prompt .prompt-header .prompt-title{color:#5c5f66;font-style:normal;line-height:150%}.gbot-dialog-modal .agent-prompt .prompt-form{margin:12px 12px 0}.gbot-dialog-modal .agent-prompt .prompt-form .gbot-form-item{margin-left:15px}.gbot-dialog-modal .agent-prompt .prompt-form .gbot-collapse{max-height:254px;overflow:auto}.gbot-dialog-modal .agent-prompt .prompt-form .prompt-variables-collapse{border-radius:4px;opacity:1;background:#FFFFFF;width:100%}.gbot-dialog-modal .agent-prompt .prompt-form .gbot-collapse-ghost>.gbot-collapse-item>.gbot-collapse-content>.gbot-collapse-content-box{padding-top:0;padding-bottom:0}.gbot-dialog-modal .agent-prompt .icon-prompt-question{cursor:pointer}.gbot-dialog-modal .prompt-form{margin:12px 12px 0}.gbot-dialog-modal .prompt-form .gbot-form-item{margin-left:15px}.gbot-dialog-modal .prompt-form .gbot-collapse{max-height:254px;overflow:auto}.gbot-dialog-modal .prompt-form .prompt-variables-collapse{border-radius:4px;opacity:1;background:#FFFFFF;width:100%}.gbot-dialog-modal .prompt-form .gbot-collapse-ghost>.gbot-collapse-item>.gbot-collapse-content>.gbot-collapse-content-box{padding-top:0;padding-bottom:0}.gbot-dialog-modal .icon-prompt-question{cursor:pointer}
@@ -1 +1 @@
1
- .gbot-dialog-modal .prompt-setting-panel{display:flex;align-items:center;justify-content:center}.gbot-dialog-modal .agent-prompt{margin:12px 12px 0;padding:12px;border-radius:4px;border:1px solid #e8e9eb;background:#fff;flex:1;max-width:824px}.gbot-dialog-modal .agent-prompt .prompt-header{font-size:16px;line-height:24px;font-weight:600;color:#84868c}.gbot-dialog-modal .agent-prompt .prompt-header .prompt-btn{color:#84868c}.gbot-dialog-modal .agent-prompt .prompt-header .prompt-title{color:#5c5f66;font-style:normal;line-height:150%}.gbot-dialog-modal .agent-prompt .prompt-form{margin:12px 12px 0}.gbot-dialog-modal .agent-prompt .prompt-form .gbot-form-item{margin-left:15px}.gbot-dialog-modal .agent-prompt .prompt-form .gbot-collapse{max-height:254px;overflow:auto}.gbot-dialog-modal .agent-prompt .prompt-form .prompt-variables-collapse{border-radius:4px;opacity:1;background:#FFFFFF;width:100%}.gbot-dialog-modal .agent-prompt .prompt-form .gbot-collapse-ghost>.gbot-collapse-item>.gbot-collapse-content>.gbot-collapse-content-box{padding-top:0;padding-bottom:0}.gbot-dialog-modal .agent-prompt .icon-prompt-question{cursor:pointer}.gbot-dialog-modal .prompt-form{margin:12px 12px 0}.gbot-dialog-modal .prompt-form .gbot-form-item{margin-left:15px}.gbot-dialog-modal .prompt-form .gbot-collapse{max-height:254px;overflow:auto}.gbot-dialog-modal .prompt-form .prompt-variables-collapse{border-radius:4px;opacity:1;background:#FFFFFF;width:100%}.gbot-dialog-modal .prompt-form .gbot-collapse-ghost>.gbot-collapse-item>.gbot-collapse-content>.gbot-collapse-content-box{padding-top:0;padding-bottom:0}.gbot-dialog-modal .icon-prompt-question{cursor:pointer}
1
+ .gbot-dialog-modal .history-item{margin-bottom:16px}.gbot-dialog-modal .history-item .history-item-user{width:100%}.gbot-dialog-modal .history-item .history-item-user .item-user-panel{display:flex;justify-content:flex-end}.gbot-dialog-modal .history-item .history-item-user .item-user-panel .user-panel-main{max-width:100%}.gbot-dialog-modal .history-item .history-item-user .item-user-panel .user-panel-main .item-user-content{background:#f9f2ff;padding:12px;border-radius:12px 2px 12px 12px;border:1px solid #9c24f2;display:inline-block;width:auto;max-width:100%;color:#070c14;word-wrap:break-word}.gbot-dialog-modal .history-item .history-item-user .item-user-file{display:flex-end;margin-top:10px}.gbot-dialog-modal .history-item .history-item-user .item-user-file-dialog{display:flex-end;margin-bottom:10px}.gbot-dialog-modal .history-item .history-item-user .item-user-images{width:100%;display:flex;justify-content:flex-end}.gbot-dialog-modal .history-item .history-item-user .item-user-images>div{width:100%;max-width:100%}.gbot-dialog-modal .history-item .history-item-user .item-user-images>div>.markdown{width:100%;max-width:100%;display:flex;gap:4px;justify-content:flex-end;flex-wrap:wrap;margin-bottom:12px}.gbot-dialog-modal .history-item .history-item-user .item-user-images>div>.markdown>p{margin-bottom:0}.gbot-dialog-modal .history-item .history-item-user .item-user-images>div>.markdown>p .gbot-image{display:flex;align-items:center;justify-content:center;flex:0 0 auto;width:40px;height:40px;border-radius:4px;overflow:hidden;background-color:#fff}.gbot-dialog-modal .history-item .history-item-user .item-user-images>div>.markdown>p .gbot-image .gbot-image-mask-info{padding:0 4px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.gbot-dialog-modal .history-item .history-item-user .item-user-images>div>.markdown>p .gbot-image img{object-fit:cover;display:block;margin-bottom:0}.gbot-dialog-modal .history-item .history-item-user ::selection{background-color:#b1d7ffb3;color:#fff}.gbot-dialog-modal .history-item .history-item-bot{width:100%;border-radius:2px 12px 12px;background:white;padding:0 12px}.gbot-dialog-modal .history-item .history-item-bot .item-bot-plugin{padding-top:12px}.gbot-dialog-modal .history-item .history-item-bot .item-bot-plugin .bot-plugin-status .plugin-status-success{display:inline-block;width:14px;height:14px;color:#fff;background:#47d1cb;border-radius:50%;font-size:10px;display:flex;align-items:center;justify-content:center}.gbot-dialog-modal .history-item .history-item-bot .item-bot-plugin .bot-plugin-status .plugin-status-error{display:inline-block;width:14px;height:14px;color:#fff;background:#f95b81;border-radius:50%;font-size:10px;display:flex;align-items:center;justify-content:center}.gbot-dialog-modal .history-item .history-item-bot .item-bot-plugin .bot-plugin-status .plugin-status-loading{display:inline-block;width:14px;height:14px;color:#477bff;border-radius:50%;font-size:10px;display:flex;align-items:center;justify-content:center}.gbot-dialog-modal .history-item .history-item-bot .item-bot-plugin .bot-plugin-title{font-weight:700;color:#000000a6}.gbot-dialog-modal .history-item .history-item-bot .item-bot-plugin .bot-plugin-action{border:1px solid #00000026;border-radius:4px;color:#000000e0;padding:1px 8px}.gbot-dialog-modal .history-item .history-item-bot .item-bot-plugin .gbot-collapse-header{padding:0;height:38px;display:flex;align-items:center}.gbot-dialog-modal .history-item .history-item-bot .item-bot-plugin .gbot-collapse-content-box{padding:0}.gbot-dialog-modal .history-item .history-item-bot .item-bot-plugin .bot-plugin-content{height:32px;line-height:32px;font-weight:700}.gbot-dialog-modal .history-item .history-item-bot .item-bot-plugin .bot-plugin-json{background:white}.gbot-dialog-modal .history-item .history-item-bot .item-bot-net{padding-top:12px}.gbot-dialog-modal .history-item .history-item-bot .item-bot-content{width:100%;border-radius:2px 12px 12px;background:white;padding:12px 0;word-wrap:break-word}.gbot-dialog-modal .history-item .history-item-bot .item-bot-content .content-think{margin-bottom:12px}.gbot-dialog-modal .history-item .history-item-bot .item-bot-content .content-think .think-top{font-size:14px;line-height:24px;color:#070c14;display:flex;align-items:center;margin-bottom:12px;cursor:pointer}.gbot-dialog-modal .history-item .history-item-bot .item-bot-content .content-think .think-top img{width:24px;margin-right:4px}.gbot-dialog-modal .history-item .history-item-bot .item-bot-content .content-think .think-top .think-action{margin-left:8px}.gbot-dialog-modal .history-item .history-item-bot .item-bot-content .content-think .think-bottom{font-size:14px;line-height:150%;color:#999;position:relative}.gbot-dialog-modal .history-item .history-item-bot .item-bot-content .content-think .think-bottom .bottom-left{background:#d9d9d9;width:1px;position:absolute;left:10px;top:4px;bottom:4px}.gbot-dialog-modal .history-item .history-item-bot .item-bot-content .content-think .think-bottom .bottom-left .thinking{position:absolute;left:-5px;top:0;width:12px;height:12px;background:#b752ea;border-radius:50%}.gbot-dialog-modal .history-item .history-item-bot .item-bot-content .content-think .think-bottom .bottom-left .thinked{position:absolute;z-index:100;left:-5px;top:0;width:12px;height:12px;background:#04d68d;border-radius:50%;color:#fff;display:flex;align-items:center;justify-content:center;font-size:8px}.gbot-dialog-modal .history-item .history-item-bot .item-bot-content .content-think .think-bottom .bottom-right{padding-left:22px}.gbot-dialog-modal .history-item .gbot-collapse-item{border-radius:4px;background-color:#f5f5f5;margin-bottom:8px;padding:0 0 0 8px}.gbot-dialog-modal .history-item .gbot-collapse-item .gbot-collapse-content{padding-bottom:8px}.gbot-dialog-modal .history-item .gbot-collapse-item:last-child{margin-bottom:0}.gbot-dialog-modal .history-item .gbot-collapse-header-text{width:100%}.gbot-dialog-modal .history-item .think{color:#999}.gbot-dialog-modal.inlay .history-item__user{display:flex;justify-content:flex-end}.gbot-dialog-modal.inlay .history-item-user,.gbot-dialog-modal.inlay .history-item-bot{max-width:calc(100% - 64px)}.gbot-dialog-modal .session-item-overlay-popover .gbot-popover-inner-content{padding:6px}.gbot-dialog-modal .session-item-overlay-popover .gbot-popover-arrow{display:none}
@@ -1 +1 @@
1
- .gbot-dialog-modal .session-history-drawer .gbot-drawer-content-wrapper{height:calc(100% - 54px)!important;border-radius:12px 12px 0 0}.gbot-dialog-modal .session-history-drawer .gbot-drawer-content-wrapper .gbot-drawer-header{padding:12px 16px;border-bottom:none}.gbot-dialog-modal .session-history-drawer .gbot-drawer-content-wrapper .gbot-drawer-header .gbot-drawer-header-title{justify-content:space-between;flex-direction:row-reverse;font-size:16px;color:#393939}.gbot-dialog-modal .session-history-drawer .gbot-drawer-content-wrapper .gbot-drawer-header .gbot-drawer-header-title .gbot-drawer-close{margin:0;padding:0}.gbot-dialog-modal .session-history-drawer .gbot-drawer-content-wrapper .gbot-drawer-body{padding:0 16px 26px}.gbot-dialog-modal .session-history-drawer.loading-panel .gbot-drawer-body{display:flex;justify-content:center;align-items:center}.gbot-dialog-modal .session-history-drawer .bot-session-container .agent-sessions{width:100%}.gbot-dialog-modal .session-history-drawer .bot-session-container .agent-sessions .sessions-main{border:none}
1
+ .gbot-dialog-modal .footer-upload{display:flex;justify-content:center;align-items:center}.gbot-dialog-modal .footer-upload .upload-enter{padding:0;height:24px;width:24px;display:flex;justify-content:center;align-items:center;cursor:pointer}.gbot-dialog-modal .footer-upload .upload-enter.disabled{color:#b8babf;cursor:not-allowed}.gbot-dialog-modal .footer-upload .upload-enter:hover{background:#ebebeb;border-radius:4px}.gbot-dialog-modal .file-upload{width:100%;display:flex;flex-direction:column}.gbot-dialog-modal .file-upload .gbot-upload-drag{background-color:#fff;border:unset}.gbot-dialog-modal .file-upload .gbot-upload-drag .gbot-upload-btn{padding:0}.gbot-dialog-modal .file-upload .file-upload-icon{font-size:35px;color:#d3d3d3}.gbot-dialog-modal .file-upload .file-upload-action{display:flex;justify-content:center;align-items:center;margin-bottom:12px}.gbot-dialog-modal .file-upload .file-upload-desc{text-align:left;display:flex;flex-direction:column;font-weight:400;font-size:12px;margin:0 auto;color:#84868c;width:232px;line-height:18px;padding-left:20px}.gbot-dialog-modal .file-upload .file-upload-desc .item-upload-desc{line-height:150%}.gbot-dialog-modal .file-upload .file-upload-desc .item-upload-desc__1{display:flex;align-items:center}.gbot-dialog-modal .file-upload .upload-wrapper{height:300px;overflow-y:auto;overflow-x:hidden}.gbot-dialog-modal .file-upload .upload-wrapper .upload-main{flex:1;width:100%;overflow-y:auto;margin-bottom:16px}.gbot-dialog-modal .file-upload .upload-wrapper .upload-main .upload-pannel{width:100%}.gbot-dialog-modal .file-upload .upload-wrapper .upload-main .upload-empty{width:100%;height:100%;display:flex;justify-content:center;align-items:center}.gbot-dialog-modal .file-upload .upload-wrapper .upload-main .upload-item{cursor:pointer}.gbot-dialog-modal .file-upload .upload-wrapper .upload-main .upload-item .upload-item-file-icon{display:inline-block;width:10px}.gbot-dialog-modal .file-upload .upload-wrapper .upload-main .upload-item .upload-item-name{margin-left:10px;display:inline-block;max-width:230px;word-break:break-all}.gbot-dialog-modal .file-upload .upload-wrapper .upload-main .upload-item .upload-item-upload-delete{display:inline-block;width:10px;color:#9c24f2;display:none}.gbot-dialog-modal .file-upload .upload-wrapper .upload-main .upload-item:hover{background:rgba(0,0,0,.04)}.gbot-dialog-modal .file-upload .upload-wrapper .upload-main .upload-item:hover .upload-item-upload-delete{display:inline-block}.gbot-dialog-modal .card-title{display:flex;justify-content:space-between;align-items:center;color:#393939;font-size:14px}.gbot-dialog-modal .card-title .name{font-weight:500}.gbot-dialog-modal .card-title .actions{font-weight:400;display:flex;gap:12px}.gbot-dialog-modal .card-title .actions .action{padding:4px 2px;cursor:pointer}.gbot-dialog-modal .card-title .actions .action .detail{display:flex;gap:6px;align-items:center}.gbot-dialog-modal .split-line{width:100%;height:1px;border:.5px solid #e8e9eb}.gbot-dialog-modal .upload-popover{z-index:1}
@@ -1 +1 @@
1
- .gbot-dialog-modal .session-action{display:flex;justify-content:space-between;align-items:center;border-top:1px solid #e8e9eb;color:#84868c}.gbot-dialog-modal .session-action .session-action-again{cursor:pointer;user-select:none}.gbot-dialog-modal .session-action .session-action-again:hover{color:#b452ff}.gbot-dialog-modal .session-action .session-action-comment{border-radius:4px;padding:4px}.gbot-dialog-modal .session-action .session-action-comment .action-comment-feedback{font-size:16px}.gbot-dialog-modal .session-action .session-action-comment .action-comment-feedback .comment-feedback-item{display:inline-block;width:100%;height:100%;cursor:pointer}.gbot-dialog-modal .session-action .session-action-comment .action-comment-feedback .comment-feedback-item:hover{color:#b452ff}.gbot-dialog-modal .session-action .session-action-comment .action-comment-feedback .comment-feedback-item__active{color:#9c24f2}.gbot-dialog-modal .cai-pannel{width:260px;overflow:hidden}.gbot-dialog-modal .cai-pannel .cai-error{color:#f33e3e;margin-bottom:12px}.gbot-dialog-modal .cai-pannel .cai-title{margin-bottom:12px}.gbot-dialog-modal .cai-pannel .cai-title .cai-require{color:#f33e3e}.gbot-dialog-modal .cai-pannel .cai-title .cai-question{color:#070c14;text-align:center;font-size:14px}.gbot-dialog-modal .cai-pannel .cai-list{display:flex;flex-wrap:wrap}.gbot-dialog-modal .cai-pannel .cai-list .cai-item{padding:6px 8px;border-radius:4px;border:1px solid #e8e9eb;margin-bottom:12px;margin-right:12px;cursor:pointer}.gbot-dialog-modal .cai-pannel .cai-list .cai-item:hover{color:#b452ff;border:1px solid #b452ff}.gbot-dialog-modal .cai-pannel .cai-list .cai-item__active{color:#8614cc;border:1px solid #8614cc}.gbot-dialog-modal .chat-item:last-child{margin-bottom:0}
1
+ .gbot-dialog-modal .search-reference .bot-net-panel{user-select:none;margin-bottom:10px;width:180px;height:32px;background:white;line-height:32px;display:flex;justify-content:space-between;padding:0 12px;cursor:pointer}.gbot-dialog-modal .search-reference .bot-net-main{background:white;padding:12px;line-height:22px}.gbot-dialog-modal .search-reference .bot-net-main .text .link{cursor:pointer;color:#0f64ff}.gbot-dialog-modal .search-reference .think-top{font-size:14px;line-height:24px;color:#070c14;display:flex;align-items:center;margin-bottom:12px;cursor:pointer}.gbot-dialog-modal .search-reference .think-top img{width:24px;margin-right:4px}.gbot-dialog-modal .search-reference .think-top .think-action{margin-left:8px}.gbot-dialog-modal .search-reference .thinking{width:12px;height:12px;background:#b752ea;border-radius:50%;margin:6px}.gbot-dialog-modal .search-reference .thinked{width:12px;height:12px;background:#04d68d;border-radius:50%;color:#fff;display:flex;align-items:center;justify-content:center;font-size:8px;margin:6px}.gbot-dialog-modal .search-reference .thinked.error{background:#f33e3e}.gbot-dialog-modal .search-reference .item-bot-plugin{line-height:24px}.gbot-dialog-modal .search-reference .item-bot-plugin .bot-plugin-status .icon-search{font-size:24px}.gbot-dialog-modal .search-reference .item-bot-plugin .bot-plugin-status .plugin-status-success{display:inline-block;width:14px;height:14px;color:#fff;background:#47d1cb;border-radius:50%;font-size:10px;display:flex;align-items:center;justify-content:center}.gbot-dialog-modal .search-reference .item-bot-plugin .bot-plugin-status .plugin-status-error{display:inline-block;width:14px;height:14px;color:#fff;background:#f95b81;border-radius:50%;font-size:10px;display:flex;align-items:center;justify-content:center}.gbot-dialog-modal .search-reference .item-bot-plugin .bot-plugin-status .plugin-status-loading{display:inline-block;width:14px;height:14px;color:#477bff;border-radius:50%;font-size:10px;display:flex;align-items:center;justify-content:center}.gbot-dialog-modal .search-reference .item-bot-plugin .bot-plugin-title{font-weight:700;color:#000000a6}.gbot-dialog-modal .search-reference .item-bot-plugin .bot-plugin-action{border:1px solid #00000026;border-radius:4px;color:#000000e0;padding:1px 8px}.gbot-dialog-modal .search-reference .item-bot-plugin .gbot-collapse-header{padding:0;height:38px;display:flex;align-items:center}.gbot-dialog-modal .search-reference .item-bot-plugin .gbot-collapse-content-box{padding:0}.gbot-dialog-modal .search-reference .item-bot-plugin .bot-plugin-content{height:32px;line-height:32px;font-weight:700}.gbot-dialog-modal .search-reference .item-bot-plugin .bot-plugin-json{background:white}.gbot-dialog-modal .search-reference .gbot-collapse-item{padding:0 8px}.gbot-dialog-modal .search-reference-list{margin-right:8px;border-radius:6px}.gbot-dialog-modal .search-reference-list-item{display:flex;flex-direction:column;padding:12px 8px 8px;gap:0px 10px;flex-wrap:wrap;align-content:flex-start;border-radius:6px;background:#ffffff;box-sizing:border-box;border:1px solid #e5e7eb;margin-bottom:8px}.gbot-dialog-modal .search-reference-list-item :last-child{margin-bottom:0}.gbot-dialog-modal .search-reference-list-item :hover{cursor:pointer}.gbot-dialog-modal .search-reference-list-item-footer{display:flex;justify-content:space-between;padding:0;row-gap:0px;flex-wrap:wrap;align-content:flex-start;z-index:0;line-height:24px;align-items:center}.gbot-dialog-modal .search-reference-list-item-footer .logo{width:24px;height:24px}.gbot-dialog-modal .search-reference-list-item-footer .name{font-family:Roboto;font-size:12x;font-weight:400;line-height:24px;letter-spacing:normal;color:#4b5563}.gbot-dialog-modal .search-reference-list-item-footer .time{font-family:Roboto;font-size:12x;font-weight:400;line-height:24px;letter-spacing:normal;color:#9ca3af}.gbot-dialog-modal .search-reference-list-item-title{font-family:Roboto;font-size:16px;font-weight:600;line-height:28px;letter-spacing:normal;color:#000}.gbot-dialog-modal .search-reference-list-item-title .number{margin-right:4px}.gbot-dialog-modal .search-reference-list-item-content{font-family:Roboto;font-size:14px;font-weight:400;line-height:24px;letter-spacing:normal;color:#4b5563;padding:0 8px;display:inline-block}
@@ -1 +1 @@
1
- .gbot-dialog-modal .search-reference .bot-net-panel{user-select:none;margin-bottom:10px;width:180px;height:32px;background:white;line-height:32px;display:flex;justify-content:space-between;padding:0 12px;cursor:pointer}.gbot-dialog-modal .search-reference .bot-net-main{background:white;padding:12px;line-height:22px}.gbot-dialog-modal .search-reference .bot-net-main .text .link{cursor:pointer;color:#0f64ff}.gbot-dialog-modal .search-reference .think-top{font-size:14px;line-height:24px;color:#070c14;display:flex;align-items:center;margin-bottom:12px;cursor:pointer}.gbot-dialog-modal .search-reference .think-top img{width:24px;margin-right:4px}.gbot-dialog-modal .search-reference .think-top .think-action{margin-left:8px}.gbot-dialog-modal .search-reference .thinking{width:12px;height:12px;background:#b752ea;border-radius:50%;margin:6px}.gbot-dialog-modal .search-reference .thinked{width:12px;height:12px;background:#04d68d;border-radius:50%;color:#fff;display:flex;align-items:center;justify-content:center;font-size:8px;margin:6px}.gbot-dialog-modal .search-reference .thinked.error{background:#f33e3e}.gbot-dialog-modal .search-reference .item-bot-plugin{line-height:24px}.gbot-dialog-modal .search-reference .item-bot-plugin .bot-plugin-status .icon-search{font-size:24px}.gbot-dialog-modal .search-reference .item-bot-plugin .bot-plugin-status .plugin-status-success{display:inline-block;width:14px;height:14px;color:#fff;background:#47d1cb;border-radius:50%;font-size:10px;display:flex;align-items:center;justify-content:center}.gbot-dialog-modal .search-reference .item-bot-plugin .bot-plugin-status .plugin-status-error{display:inline-block;width:14px;height:14px;color:#fff;background:#f95b81;border-radius:50%;font-size:10px;display:flex;align-items:center;justify-content:center}.gbot-dialog-modal .search-reference .item-bot-plugin .bot-plugin-status .plugin-status-loading{display:inline-block;width:14px;height:14px;color:#477bff;border-radius:50%;font-size:10px;display:flex;align-items:center;justify-content:center}.gbot-dialog-modal .search-reference .item-bot-plugin .bot-plugin-title{font-weight:700;color:#000000a6}.gbot-dialog-modal .search-reference .item-bot-plugin .bot-plugin-action{border:1px solid #00000026;border-radius:4px;color:#000000e0;padding:1px 8px}.gbot-dialog-modal .search-reference .item-bot-plugin .gbot-collapse-header{padding:0;height:38px;display:flex;align-items:center}.gbot-dialog-modal .search-reference .item-bot-plugin .gbot-collapse-content-box{padding:0}.gbot-dialog-modal .search-reference .item-bot-plugin .bot-plugin-content{height:32px;line-height:32px;font-weight:700}.gbot-dialog-modal .search-reference .item-bot-plugin .bot-plugin-json{background:white}.gbot-dialog-modal .search-reference .gbot-collapse-item{padding:0 8px}.gbot-dialog-modal .search-reference-list{margin-right:8px;border-radius:6px}.gbot-dialog-modal .search-reference-list-item{display:flex;flex-direction:column;padding:12px 8px 8px;gap:0px 10px;flex-wrap:wrap;align-content:flex-start;border-radius:6px;background:#ffffff;box-sizing:border-box;border:1px solid #e5e7eb;margin-bottom:8px}.gbot-dialog-modal .search-reference-list-item :last-child{margin-bottom:0}.gbot-dialog-modal .search-reference-list-item :hover{cursor:pointer}.gbot-dialog-modal .search-reference-list-item-footer{display:flex;justify-content:space-between;padding:0;row-gap:0px;flex-wrap:wrap;align-content:flex-start;z-index:0;line-height:24px;align-items:center}.gbot-dialog-modal .search-reference-list-item-footer .logo{width:24px;height:24px}.gbot-dialog-modal .search-reference-list-item-footer .name{font-family:Roboto;font-size:12x;font-weight:400;line-height:24px;letter-spacing:normal;color:#4b5563}.gbot-dialog-modal .search-reference-list-item-footer .time{font-family:Roboto;font-size:12x;font-weight:400;line-height:24px;letter-spacing:normal;color:#9ca3af}.gbot-dialog-modal .search-reference-list-item-title{font-family:Roboto;font-size:16px;font-weight:600;line-height:28px;letter-spacing:normal;color:#000}.gbot-dialog-modal .search-reference-list-item-title .number{margin-right:4px}.gbot-dialog-modal .search-reference-list-item-content{font-family:Roboto;font-size:14px;font-weight:400;line-height:24px;letter-spacing:normal;color:#4b5563;padding:0 8px;display:inline-block}
1
+ .gbot-dialog-modal .session-action{display:flex;justify-content:space-between;align-items:center;border-top:1px solid #e8e9eb;color:#84868c}.gbot-dialog-modal .session-action .session-action-again{cursor:pointer;user-select:none}.gbot-dialog-modal .session-action .session-action-again:hover{color:#b452ff}.gbot-dialog-modal .session-action .session-action-comment{border-radius:4px;padding:4px}.gbot-dialog-modal .session-action .session-action-comment .action-comment-feedback{font-size:16px}.gbot-dialog-modal .session-action .session-action-comment .action-comment-feedback .comment-feedback-item{display:inline-block;width:100%;height:100%;cursor:pointer}.gbot-dialog-modal .session-action .session-action-comment .action-comment-feedback .comment-feedback-item:hover{color:#b452ff}.gbot-dialog-modal .session-action .session-action-comment .action-comment-feedback .comment-feedback-item__active{color:#9c24f2}.gbot-dialog-modal .cai-pannel{width:260px;overflow:hidden}.gbot-dialog-modal .cai-pannel .cai-error{color:#f33e3e;margin-bottom:12px}.gbot-dialog-modal .cai-pannel .cai-title{margin-bottom:12px}.gbot-dialog-modal .cai-pannel .cai-title .cai-require{color:#f33e3e}.gbot-dialog-modal .cai-pannel .cai-title .cai-question{color:#070c14;text-align:center;font-size:14px}.gbot-dialog-modal .cai-pannel .cai-list{display:flex;flex-wrap:wrap}.gbot-dialog-modal .cai-pannel .cai-list .cai-item{padding:6px 8px;border-radius:4px;border:1px solid #e8e9eb;margin-bottom:12px;margin-right:12px;cursor:pointer}.gbot-dialog-modal .cai-pannel .cai-list .cai-item:hover{color:#b452ff;border:1px solid #b452ff}.gbot-dialog-modal .cai-pannel .cai-list .cai-item__active{color:#8614cc;border:1px solid #8614cc}.gbot-dialog-modal .chat-item:last-child{margin-bottom:0}
@@ -1 +1 @@
1
- .gbot-dialog-modal .file-card{height:38px;min-width:232px;max-width:600px;display:flex;padding:6px 12px 6px 6px;align-items:center;gap:4px;border-radius:6px;background:#ffffff;position:relative}.gbot-dialog-modal .file-card .analysis{display:flex;justify-content:center;align-items:center;gap:8px;font-size:12px;font-weight:400;line-height:22px;text-align:left;color:#84868c}.gbot-dialog-modal .file-card .file-icon{height:100%;width:24px}.gbot-dialog-modal .file-card.small{height:30px;width:150px;padding:3px 6px 3px 3px}.gbot-dialog-modal .file-card.small .file-icon{width:24px}.gbot-dialog-modal .file-card .file-desc{flex:1;overflow:hidden}.gbot-dialog-modal .file-card .file-desc .file-desc-name{color:#5c5f66;font-size:12px;font-style:normal;font-weight:700;line-height:150%}.gbot-dialog-modal .file-card .file-desc .file-desc-name:hover{cursor:pointer}.gbot-dialog-modal .file-card .file-desc .file-desc-name:hover .gbot-typography{color:#b452ff}.gbot-dialog-modal .file-card .file-desc .file-desc-size{color:#84868c;font-size:10px;font-style:normal;font-weight:400;line-height:150%}.gbot-dialog-modal .file-card .file-process{background-color:#f7f7f9;border-radius:8px;width:16px;height:16px;line-height:16px;text-align:center;display:inline-flex;align-items:center;justify-content:center}.gbot-dialog-modal .file-card .file-remove{cursor:pointer;display:inline-block;width:16px;height:16px;line-height:16px;text-align:center;color:#151b26;display:inline-flex;align-items:center;justify-content:center}.gbot-dialog-modal .file-card .file-remove:hover{background-color:#fff;color:#b452ff}.gbot-dialog-modal .file-card .file-failed{display:inline-block;width:16px;height:16px;line-height:16px;text-align:center;color:#dc4446;display:inline-flex;align-items:center;justify-content:center}
1
+ .gbot-dialog-modal .gbot-drawer-content-wrapper{height:calc(100% - 54px)!important;border-radius:12px 12px 0 0}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-header{padding:12px 16px;border-bottom:none}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-header .gbot-drawer-header-title{justify-content:space-between;flex-direction:row-reverse;font-size:16px;color:#393939}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-header .gbot-drawer-header-title .gbot-drawer-close{margin:0;padding:0}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body{padding:0 16px 26px}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel{max-height:124px;width:100%;padding:2px 0;border-bottom:1px solid #e8e9eb}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .session-item-space{padding:10px 0;overflow:hidden}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel:hover{cursor:pointer}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .gbot-space{width:100%}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question{font-size:14px;font-weight:700;line-height:21px;color:#070c14;width:100%;display:flex;align-items:center;justify-content:space-between}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question .gbot-tag{width:58px;height:24px;padding:1px 8px;border-radius:4px;font-size:14px;font-weight:400;background-color:#9c24f2;color:#fff}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question .session-item-name{width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question .icons-bar{display:flex}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question .icons-bar .gbot-btn{margin:0 3px}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question .gbot-btn{width:20px;height:20px;padding:0;font-size:12px;color:#000}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question .name-edit-panel{width:100%;position:relative}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question .name-edit-panel .name-edit-input{width:100%}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question .name-edit-panel .name-edit-input .gbot-input-show-count-suffix{font-size:12px;font-weight:400;color:#e0e0e0;margin-right:60px}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question .name-edit-panel .gbot-btn{position:absolute;right:12px;top:7px;z-index:999}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question .name-edit-panel .gbot-btn .anticon{font-size:14px}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-answer{max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#84868c}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-file{font-size:12px;color:#84868c}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-file .file-icon{width:16px;height:16px}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-file .file-name{width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-file .gbot-tag{font-size:10px;border:1px solid #84868c;background-color:transparent;color:#84868c}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-file .file-status-icon{position:absolute;left:6px;top:-2px;border-radius:10px;border:1px solid #fff}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-file .success-file-icon{color:#45cc27}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-file .failed-file-icon{color:#dc4446}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-file .loading-file-icon{height:12px;width:12px;font-size:10px;background-color:#fff}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .current-item{margin:2px 0}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .current-item .session-item-space{border-radius:8px;background-color:#f9f2ff;padding:8px}.gbot-dialog-modal .loading-panel .gbot-drawer-body{display:flex;justify-content:center;align-items:center}
@@ -1 +1 @@
1
- .gbot-dialog-modal .clear-modal .title{display:flex;align-items:center;gap:8px;font-size:16px;font-weight:500;text-align:left;color:#161616}.gbot-dialog-modal .clear-modal .content{font-size:14px;font-weight:400;line-height:22px;text-align:justified;color:#393939}
1
+ .gbot-dialog-modal .file-card{height:38px;min-width:232px;max-width:600px;display:flex;padding:6px 12px 6px 6px;align-items:center;gap:4px;border-radius:6px;background:#ffffff;position:relative}.gbot-dialog-modal .file-card .analysis{display:flex;justify-content:center;align-items:center;gap:8px;font-size:12px;font-weight:400;line-height:22px;text-align:left;color:#84868c}.gbot-dialog-modal .file-card .file-icon{height:100%;width:24px}.gbot-dialog-modal .file-card.small{height:30px;width:150px;padding:3px 6px 3px 3px}.gbot-dialog-modal .file-card.small .file-icon{width:24px}.gbot-dialog-modal .file-card .file-desc{flex:1;overflow:hidden}.gbot-dialog-modal .file-card .file-desc .file-desc-name{color:#5c5f66;font-size:12px;font-style:normal;font-weight:700;line-height:150%}.gbot-dialog-modal .file-card .file-desc .file-desc-name:hover{cursor:pointer}.gbot-dialog-modal .file-card .file-desc .file-desc-name:hover .gbot-typography{color:#b452ff}.gbot-dialog-modal .file-card .file-desc .file-desc-size{color:#84868c;font-size:10px;font-style:normal;font-weight:400;line-height:150%}.gbot-dialog-modal .file-card .file-process{background-color:#f7f7f9;border-radius:8px;width:16px;height:16px;line-height:16px;text-align:center;display:inline-flex;align-items:center;justify-content:center}.gbot-dialog-modal .file-card .file-remove{cursor:pointer;display:inline-block;width:16px;height:16px;line-height:16px;text-align:center;color:#151b26;display:inline-flex;align-items:center;justify-content:center}.gbot-dialog-modal .file-card .file-remove:hover{background-color:#fff;color:#b452ff}.gbot-dialog-modal .file-card .file-failed{display:inline-block;width:16px;height:16px;line-height:16px;text-align:center;color:#dc4446;display:inline-flex;align-items:center;justify-content:center}
@@ -1 +1 @@
1
- .gbot-dialog-modal .gbot-drawer-content-wrapper{height:calc(100% - 54px)!important;border-radius:12px 12px 0 0}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-header{padding:12px 16px;border-bottom:none}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-header .gbot-drawer-header-title{justify-content:space-between;flex-direction:row-reverse;font-size:16px;color:#393939}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-header .gbot-drawer-header-title .gbot-drawer-close{margin:0;padding:0}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body{padding:0 16px 26px}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel{max-height:124px;width:100%;padding:2px 0;border-bottom:1px solid #e8e9eb}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .session-item-space{padding:10px 0;overflow:hidden}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel:hover{cursor:pointer}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .gbot-space{width:100%}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question{font-size:14px;font-weight:700;line-height:21px;color:#070c14;width:100%;display:flex;align-items:center;justify-content:space-between}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question .gbot-tag{width:58px;height:24px;padding:1px 8px;border-radius:4px;font-size:14px;font-weight:400;background-color:#9c24f2;color:#fff}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question .session-item-name{width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question .icons-bar{display:flex}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question .icons-bar .gbot-btn{margin:0 3px}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question .gbot-btn{width:20px;height:20px;padding:0;font-size:12px;color:#000}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question .name-edit-panel{width:100%;position:relative}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question .name-edit-panel .name-edit-input{width:100%}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question .name-edit-panel .name-edit-input .gbot-input-show-count-suffix{font-size:12px;font-weight:400;color:#e0e0e0;margin-right:60px}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question .name-edit-panel .gbot-btn{position:absolute;right:12px;top:7px;z-index:999}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-question .name-edit-panel .gbot-btn .anticon{font-size:14px}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-answer{max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#84868c}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-file{font-size:12px;color:#84868c}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-file .file-icon{width:16px;height:16px}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-file .file-name{width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-file .gbot-tag{font-size:10px;border:1px solid #84868c;background-color:transparent;color:#84868c}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-file .file-status-icon{position:absolute;left:6px;top:-2px;border-radius:10px;border:1px solid #fff}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-file .success-file-icon{color:#45cc27}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-file .failed-file-icon{color:#dc4446}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .session-item-panel .item-file .loading-file-icon{height:12px;width:12px;font-size:10px;background-color:#fff}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .current-item{margin:2px 0}.gbot-dialog-modal .gbot-drawer-content-wrapper .gbot-drawer-body .current-item .session-item-space{border-radius:8px;background-color:#f9f2ff;padding:8px}.gbot-dialog-modal .loading-panel .gbot-drawer-body{display:flex;justify-content:center;align-items:center}
1
+ .gbot-dialog-modal .clear-modal .title{display:flex;align-items:center;gap:8px;font-size:16px;font-weight:500;text-align:left;color:#161616}.gbot-dialog-modal .clear-modal .content{font-size:14px;font-weight:400;line-height:22px;text-align:justified;color:#393939}
@@ -1 +1 @@
1
- .gbot-dialog-modal .sider-container{height:100%;width:100%;display:flex;flex-direction:column}
1
+ .gbot-dialog-modal .chat-header{height:56px;padding:0 24px;border-bottom:1px solid #e8e9eb;display:flex;align-items:center;justify-content:space-between;background:white}.gbot-dialog-modal .chat-header .header-title{color:#151b26;font-size:16px;font-style:normal;font-weight:700;line-height:24px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
@@ -1 +1 @@
1
- .gbot-dialog-modal .chat-header{height:56px;padding:0 24px;border-bottom:1px solid #e8e9eb;display:flex;align-items:center;justify-content:space-between;background:white}.gbot-dialog-modal .chat-header .header-title{color:#151b26;font-size:16px;font-style:normal;font-weight:700;line-height:24px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
1
+ .gbot-dialog-modal .sider-container{height:100%;width:100%;display:flex;flex-direction:column}
@@ -1 +1 @@
1
- .gbot-dialog-modal .session-refer{padding:12px 0;border-top:1px solid #e8e9eb}.gbot-dialog-modal .session-refer .session-refer-header{color:#070c14;margin-bottom:12px;height:18px;display:flex;align-items:center}.gbot-dialog-modal .session-refer .session-refer-header .refer-header-title{font-style:normal;font-weight:400;line-height:150%}.gbot-dialog-modal .session-refer .session-refer-content .refer-markdown p{color:#84868c;line-height:150%}.gbot-dialog-modal .session-refer .gbot-collapse-header{padding:4px 0!important}.gbot-dialog-modal .session-refer .gbot-collapse-content-box{padding:4px 10px 4px 24px!important}
1
+ .gbot-dialog-modal .knowledge-select{width:204px;height:28px;border-radius:10px;border:1px solid}.gbot-dialog-modal .knowledge-select .select-popover{cursor:pointer;width:100%;height:100%;padding:0 8px;display:flex;align-items:center;justify-content:space-between;font-size:14px;font-weight:400}.gbot-dialog-modal .knowledge-select .select-popover .select-icon{color:#84868c}.gbot-dialog-modal .knowledge-select .select-popover .title{line-height:22px;color:#84868c}.gbot-dialog-modal .knowledge-select .select-popover .content{padding:2px 8px;border-radius:4px;background:#f7f7f9;line-height:18px;color:#84868c}.gbot-dialog-modal .knowledge-select .gbot-popover-placement-bottomRight{padding-top:5px!important}.gbot-dialog-modal .knowledge-select .gbot-popover-placement-bottomRight .gbot-popover-arrow{display:none}.gbot-dialog-modal .knowledge-select .gbot-popover-placement-bottomRight .gbot-popover-inner .gbot-popover-inner-content{height:200px;overflow-y:auto;font-size:14px;font-weight:400;line-height:21px;color:#84868c}
@@ -1 +1 @@
1
- .gbot-dialog-modal .knowledge-select{width:204px;height:28px;border-radius:10px;border:1px solid}.gbot-dialog-modal .knowledge-select .select-popover{cursor:pointer;width:100%;height:100%;padding:0 8px;display:flex;align-items:center;justify-content:space-between;font-size:14px;font-weight:400}.gbot-dialog-modal .knowledge-select .select-popover .select-icon{color:#84868c}.gbot-dialog-modal .knowledge-select .select-popover .title{line-height:22px;color:#84868c}.gbot-dialog-modal .knowledge-select .select-popover .content{padding:2px 8px;border-radius:4px;background:#f7f7f9;line-height:18px;color:#84868c}.gbot-dialog-modal .knowledge-select .gbot-popover-placement-bottomRight{padding-top:5px!important}.gbot-dialog-modal .knowledge-select .gbot-popover-placement-bottomRight .gbot-popover-arrow{display:none}.gbot-dialog-modal .knowledge-select .gbot-popover-placement-bottomRight .gbot-popover-inner .gbot-popover-inner-content{height:200px;overflow-y:auto;font-size:14px;font-weight:400;line-height:21px;color:#84868c}
1
+ .gbot-dialog-modal .agent-chat{width:100%;height:100%;display:flex;flex-direction:column;max-width:824px;margin:0 auto;overflow:hidden}.gbot-dialog-modal .agent-chat .chat-main{flex:1;padding:16px;overflow:hidden;width:100%;transition:all 1s;position:relative}.gbot-dialog-modal .agent-chat .chat-main .chat-main-wrapper{width:100%;height:100%;overflow-y:auto;overflow-x:hidden}.gbot-dialog-modal .agent-chat .chat-main .session-stop{display:flex;align-items:center;justify-content:center;position:absolute;left:0;right:0;bottom:4px}.gbot-dialog-modal .agent-chat .chat-main .back-bottom{transition:all 3.3s;position:absolute;background:white;box-shadow:0 0 5px #ddd;font-size:0;border-radius:50%;width:26px;height:26px;right:4px;bottom:0;display:flex;justify-content:center;align-content:center}.gbot-dialog-modal .agent-chat .chat-main .main-empty{width:100%;height:100%;overflow-y:auto}.gbot-dialog-modal .agent-chat .chat-footer{position:relative;flex:0;padding:0 16px 8px;display:flex}.gbot-dialog-modal .agent-chat .chat-footer .camera-out-btn:hover,.gbot-dialog-modal .agent-chat .chat-footer .camera-out-btn:active,.gbot-dialog-modal .agent-chat .chat-footer .camera-out-btn.active{color:#9c24f2}.gbot-dialog-modal .agent-chat .chat-footer .chat-footer-input{flex:1;position:relative;width:100%}.gbot-dialog-modal .agent-chat .chat-footer .chat-footer-input .gbot-upload.gbot-upload-select-picture-card{width:20px;height:20px;border:none;margin:0}.gbot-dialog-modal .agent-chat .chat-footer .chat-footer-input .upload-wrapper{height:20px;width:20px;font-size:16px;border:1px solid #9c24f2;color:#9c24f2;border-radius:2px;display:flex;justify-content:center;align-items:center;cursor:pointer}.gbot-dialog-modal .agent-chat .chat-footer .chat-footer-input .upload-wrapper.upload-wrapper__disabled{border:1px solid #b8babf;color:#b8babf;cursor:not-allowed}.gbot-dialog-modal .agent-chat .chat-footer .chat-footer-input .footer-textarea{position:relative}.gbot-dialog-modal .agent-chat .chat-footer .chat-footer-input .footer-textarea .remainingSeconds-time{position:absolute;inset:0;background:#e6e7e893;display:flex;align-items:center;justify-content:center;z-index:10;flex-direction:column;padding:0 16px;text-align:center;color:#e74069;border-radius:4px;border:1px solid #e5d4ea}.gbot-dialog-modal .agent-chat .chat-footer .footer-upload-action-wrapper{position:relative;width:100%}.gbot-dialog-modal .agent-chat .chat-footer .footer-upload-action-wrapper .remainingSeconds-mark{position:absolute;inset:0;background:#ffffff00;display:flex;align-items:center;justify-content:center;z-index:10;border-radius:inherit;flex-direction:column}.gbot-dialog-modal .agent-chat .chat-footer .footer-upload-action{width:100%;height:28px;display:flex;justify-content:space-between;align-items:center}.gbot-dialog-modal .agent-chat .chat-footer .footer-upload-action .footer-upload-picture{display:inline-block;width:20px}.gbot-dialog-modal .agent-chat .chat-footer .footer-upload-action .add-btn{width:70px;height:24px;padding:0;font-size:12px;border-radius:10px 10px 10px 2px}.gbot-dialog-modal .agent-chat .chat-footer .footer-upload-action .add-btn:disabled,.gbot-dialog-modal .agent-chat .chat-footer .footer-upload-action .add-btn:disabled:hover{background:#b8babf;color:#fff}.gbot-dialog-modal .agent-chat .chat-footer .footer-upload-action .session-history-drawer-component .history-overlay-action:hover{color:#9c24f2}.gbot-dialog-modal .agent-chat .chat-footer .footer-upload-action .session-history-overlay .gbot-popover-inner-content{padding:8px 10px}.gbot-dialog-modal .agent-chat .session-loading{width:100%;height:100%;display:flex;justify-content:center;align-items:center}
@@ -1 +1 @@
1
- .gbot-dialog-modal .agent-chat{width:100%;height:100%;display:flex;flex-direction:column;max-width:824px;margin:0 auto;overflow:hidden}.gbot-dialog-modal .agent-chat .chat-main{flex:1;padding:16px;overflow:hidden;width:100%;transition:all 1s;position:relative}.gbot-dialog-modal .agent-chat .chat-main .chat-main-wrapper{width:100%;height:100%;overflow-y:auto;overflow-x:hidden}.gbot-dialog-modal .agent-chat .chat-main .session-stop{display:flex;align-items:center;justify-content:center;position:absolute;left:0;right:0;bottom:4px}.gbot-dialog-modal .agent-chat .chat-main .back-bottom{transition:all 3.3s;position:absolute;background:white;box-shadow:0 0 5px #ddd;font-size:0;border-radius:50%;width:26px;height:26px;right:4px;bottom:0;display:flex;justify-content:center;align-content:center}.gbot-dialog-modal .agent-chat .chat-main .main-empty{width:100%;height:100%;overflow-y:auto}.gbot-dialog-modal .agent-chat .chat-footer{position:relative;flex:0;padding:0 16px 8px;display:flex}.gbot-dialog-modal .agent-chat .chat-footer .camera-out-btn:hover,.gbot-dialog-modal .agent-chat .chat-footer .camera-out-btn:active,.gbot-dialog-modal .agent-chat .chat-footer .camera-out-btn.active{color:#9c24f2}.gbot-dialog-modal .agent-chat .chat-footer .chat-footer-input{flex:1;position:relative;width:100%}.gbot-dialog-modal .agent-chat .chat-footer .chat-footer-input .gbot-upload.gbot-upload-select-picture-card{width:20px;height:20px;border:none;margin:0}.gbot-dialog-modal .agent-chat .chat-footer .chat-footer-input .upload-wrapper{height:20px;width:20px;font-size:16px;border:1px solid #9c24f2;color:#9c24f2;border-radius:2px;display:flex;justify-content:center;align-items:center;cursor:pointer}.gbot-dialog-modal .agent-chat .chat-footer .chat-footer-input .upload-wrapper.upload-wrapper__disabled{border:1px solid #b8babf;color:#b8babf;cursor:not-allowed}.gbot-dialog-modal .agent-chat .chat-footer .chat-footer-input .footer-textarea{position:relative}.gbot-dialog-modal .agent-chat .chat-footer .chat-footer-input .footer-textarea .remainingSeconds-time{position:absolute;inset:0;background:#e6e7e893;display:flex;align-items:center;justify-content:center;z-index:10;flex-direction:column;padding:0 16px;text-align:center;color:#e74069;border-radius:4px;border:1px solid #e5d4ea}.gbot-dialog-modal .agent-chat .chat-footer .footer-upload-action-wrapper{position:relative;width:100%}.gbot-dialog-modal .agent-chat .chat-footer .footer-upload-action-wrapper .remainingSeconds-mark{position:absolute;inset:0;background:#ffffff00;display:flex;align-items:center;justify-content:center;z-index:10;border-radius:inherit;flex-direction:column}.gbot-dialog-modal .agent-chat .chat-footer .footer-upload-action{width:100%;height:28px;display:flex;justify-content:space-between;align-items:center}.gbot-dialog-modal .agent-chat .chat-footer .footer-upload-action .footer-upload-picture{display:inline-block;width:20px}.gbot-dialog-modal .agent-chat .chat-footer .footer-upload-action .add-btn{width:70px;height:24px;padding:0;font-size:12px;border-radius:10px 10px 10px 2px}.gbot-dialog-modal .agent-chat .chat-footer .footer-upload-action .add-btn:disabled,.gbot-dialog-modal .agent-chat .chat-footer .footer-upload-action .add-btn:disabled:hover{background:#b8babf;color:#fff}.gbot-dialog-modal .agent-chat .chat-footer .footer-upload-action .session-history-drawer-component .history-overlay-action:hover{color:#9c24f2}.gbot-dialog-modal .agent-chat .chat-footer .footer-upload-action .session-history-overlay .gbot-popover-inner-content{padding:8px 10px}.gbot-dialog-modal .agent-chat .session-loading{width:100%;height:100%;display:flex;justify-content:center;align-items:center}
1
+ .gbot-dialog-modal .session-refer{padding:12px 0;border-top:1px solid #e8e9eb}.gbot-dialog-modal .session-refer .session-refer-header{color:#070c14;margin-bottom:12px;height:18px;display:flex;align-items:center}.gbot-dialog-modal .session-refer .session-refer-header .refer-header-title{font-style:normal;font-weight:400;line-height:150%}.gbot-dialog-modal .session-refer .session-refer-content .refer-markdown p{color:#84868c;line-height:150%}.gbot-dialog-modal .session-refer .gbot-collapse-header{padding:4px 0!important}.gbot-dialog-modal .session-refer .gbot-collapse-content-box{padding:4px 10px 4px 24px!important}
package/dist/lib/index.js CHANGED
@@ -317,7 +317,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
317
317
  ${i}`:i}if(t&&t.length>0){const a=t.filter(Boolean).map(o=>`![](${o})`).join(`
318
318
  `);i=a?`${a}
319
319
  ${i}`:i}}return i},NZ=e=>{const t=Math.floor(e/3600),n=Math.floor(e%3600/60),r=e%60,i=a=>String(a).padStart(2,"0");return`${i(t)}:${i(n)}:${i(r)}`},fZ=z.forwardRef((e,t)=>{var Hm,$m,qm,Vm,Zm,Jm,Xm,Km,eh,th,nh,rh,ih,ah;const{application:n,docViewerUrl:r="",currentSession:i,onCreateSession:a,embeddingService:o,setCurrentSession:s,networkStatus:l,setNetworkStatus:u}=e,[c,M]=z.useState([]),[d,g]=z.useState(),[p,m]=z.useState(),T=z.useRef(null),{service:D,agentClient:y,depId:I,footer:b,transform:w,defaultInput:A,onMessage:_,onHistoryLoad:P,beforeMessageSend:C,bodyStyle:S,disabled:R,features:Y,popupContainer:G,icon:$,sider:Z,mode:fe,silencedSeconds:V}=z.useContext($t),[se,be]=z.useState(!1),x=z.useRef(c),pe=z.useRef(void 0),[he,L]=z.useState(0),[ie,Ce]=z.useState([]),[ze,Fe]=z.useState([]),[H,me]=z.useState(0),[ye,X]=z.useState(!1);z.useEffect(()=>{X(H>0)},[H]);const De=z.useRef(null),[Ye,$e]=z.useState([]),[tt,gt]=z.useState(!1),[re,Ee]=z.useState(!1),[_e,zt]=z.useState(""),[qe,ut]=z.useState(),[rt,mt]=z.useState({}),Tt=z.useRef(null),B=z.useRef(null),J=z.useRef(null),[K,de]=z.useState(!1),[Ue,it]=z.useState([]),[Ve,ve]=z.useState(!0),[en,tr]=z.useState(!0),[Vt,rn]=z.useState(!1),[Ln,Kr]=z.useState(!1),[Lm,nx]=z.useState(!1),[nr,Ra]=z.useState(typeof(Y==null?void 0:Y.promptVariables)=="object"?Y.promptVariables.default||[]:[]),[rx,ix]=z.useState(()=>{const F=typeof(Y==null?void 0:Y.knowledges)=="object"&&Y.knowledges.default||void 0;if(F){if(Array.isArray(F)&&F.some(Ie=>Array.isArray(Ie.fileIds)&&Ie.fileIds.length===0))throw Error("fileIds cannot be an empty array");if(Nl(F)>oi)throw Error(`knowledges and fileIds total count cannot exceed ${oi}`)}return F}),[xm,Ai]=z.useState(!1),[Cm,_a]=z.useState(!1),[ax,Ua]=z.useState(typeof(Y==null?void 0:Y.connectNetwork)=="object"&&typeof(Y==null?void 0:Y.connectNetwork.default)=="boolean"?Y.connectNetwork.default:!1),[Sm,ns]=z.useState(!1),[ox,ei]=z.useState(!1),[sx,lx]=z.useState(null),[rs,zi]=z.useState(!1),[vm,Om]=z.useState(!1),{isSwitchingToExistingSession:km,setIsSwitchingToExistingSession:is}=am(),$i=z.useRef(null),[lu,ux]=z.useState("");z.useEffect(()=>{if(!V)return;let F=NZ(V);ux(F)},[V]),z.useEffect(()=>{if(lx(i),i===null)ei(!1);else if(i===void 0)ei(!0);else{if(sx===null){if(km){ei(!0),is(!1);return}ei(!1);return}i.ready?ei(!1):ei(!0)}},[i,i==null?void 0:i.ready,km]),z.useEffect(()=>{var oe,Ie;i&&(x.current=[]),M([]);const F=T.current;if(F&&F.scrollTo({top:0}),!((oe=i==null?void 0:i.data)!=null&&oe.id))return;if(Kr(!1),rn(!1),(Ie=i.messages)!=null&&Ie.length){const He=[...i.messages.filter(Te=>Te==null?void 0:Te.messageId)].reverse();x.current=[...He],M([...He]),ei(!1)}const q=ne=>{var He;(He=i==null?void 0:i.data)!=null&&He.id&&(x.current=[...ne].reverse(),M([...ne].reverse()),!ne||ne.length<10?_a(!1):_a(!0),ei(!1),P&&P({applicationId:n.id,sessionId:i.data.id,histories:ne}))};return i.addEventListener("history:loaded",q),()=>{x.current=[],M([]),i==null||i.removeEventListener("history:loaded",q)}},[i]),z.useEffect(()=>{const F=()=>{var q;(q=i==null?void 0:i.data)!=null&&q.id&&(i.promptVariables&&Ra(i.promptVariables.sort((oe,Ie)=>oe.key.localeCompare(Ie.key))),i.knowledges&&ix(i.knowledges),u(i.netOpen))};return i==null||i.addEventListener("data:updated",F),()=>{i==null||i.removeEventListener("data:updated",F)}},[i]),z.useEffect(()=>{var q;if(!((q=i==null?void 0:i.data)!=null&&q.id))return;const F=oe=>{var Ie;console.error(oe.message,oe.cause,"e.case"),U.notification.config({getContainer:()=>(G==null?void 0:G.current)||document.body,prefixCls:"gbot-notification"}),U.notification.error({message:((Ie=oe.cause)==null?void 0:Ie.message)||oe.message}),U.notification.config({getContainer:void 0,prefixCls:"gbot-notification"})};return i.addEventListener("error",F),()=>{i==null||i.removeEventListener("error",F)}},[i]);const cx=()=>{var oe;if(!((oe=i==null?void 0:i.data)!=null&&oe.id)||!(n!=null&&n.id))return;const F=i.data.id,q=c[c.length-1];if(q&&q.isContext){hn("success","已开启新话题");return}else i.clear().then(()=>{const Ie=new Ja("",F,Se.IHistoryRole.System);Ie.isContext=!0,M([Ie,...c])})};z.useEffect(()=>{n!=null&&n.id&&(D==null||D.getRecommendQues(n.id).then(F=>{$e(F)}))},[I,n]);const Ym=F=>Be(exports,null,function*(){var rr,xn;if(R){hn("error","发送功能被禁用");return}const q=F||d;if(!(q!=null&&q.trim())){hn("error","请输入你想问的");return}if(!(nr==null?void 0:nr.every(Qt=>!!(Qt!=null&&Qt.value))))if(w!=null&&w.promptVariables){hn("error","变量值不能为空");return}else console.error("变量值不能为空",nr==null?void 0:nr.map(Qt=>!!(Qt!=null&&Qt.value)));if(Ln){hn("error","正在回复中");return}if(se){hn("error","等待初始化");return}if(!Ve){hn("error","正在解析文件");return}if(ye){hn("error","正在上传图片");return}Ce([]),Fe([]);const Ie=(rr=i==null?void 0:i.data)==null?void 0:rr.id;if(!Ie){if(rs)return;zi(!0),a==null||a({netOpen:l?ai.OPEN:ai.CLOSE}).then(Qt=>{var yt,Cr;Ai(!0),u(!!((yt=Qt.data)!=null&&yt.netOpen)),Ua(!!((Cr=Qt.data)!=null&&Cr.enableNetOpen)),uu(Qt).then(()=>{s==null||s(Qt),Ai(!1),m(q)})}).catch(Qt=>{zi(!1)});return}if(rs)return;zi(!0),ns(!0);const ne=dp(q,ze,rt[Ie],(n==null?void 0:n.type)||0);let He;try{C?He=yield C==null?void 0:C({applicationId:n.id,sessionId:Ie,message:{content:ne,sessionId:Ie,role:Se.ChatMessageRole.User,files:rt[Ie]}}):He=!0}catch(Qt){He=!1}if(ns(!1),He===!1){zi(!1);return}let Te=q;typeof He=="object"&&(Te=He.content||q);const Yt=yield(()=>new Promise(Qt=>{Ra(yt=>(Qt(yt),yt))}))();if(!(yield i.setPromptVariables(Yt))){zi(!1);return}((xn=rt[Ie])==null?void 0:xn.length)>0?Mx(Te):cu(Te)}),uu=F=>new Promise((q,oe)=>Be(exports,null,function*(){const He=(F==null?void 0:F.promptVariables).filter(Te=>Te.type?!((Te.type===Se.PromptVariableType.User||Te.type===void 0)&&Te.key==="query")&&!((Te.type===Se.PromptVariableType.System||Te.type===void 0)&&Te.key==="datetime"):Te.key!=="query").map(Te=>{var Yt;const It=(Yt=nr.find(tn=>tn.key===Te.key&&tn.type===Te.type))==null?void 0:Yt.value;return Te.value=It||"",Te});Ra(He.sort((Te,It)=>Te.key.localeCompare(It.key))),yield F==null?void 0:F.setPromptVariables(He).catch(Te=>{console.error(Te),hn("error",Te.message)}),q()})),Mx=F=>{var ne,He,Te;if(ve(!1),!((ne=i==null?void 0:i.data)!=null&&ne.id)||!(n!=null&&n.id))return;const q=((He=i.data)==null?void 0:He.id)||"";let oe=[],Ie=new Set;(Te=rt[q])==null||Te.forEach(It=>{Ie.has(It.id)||(oe.push(It),Ie.add(It.id))}),ve(!0),cu(F,oe)};z.useEffect(()=>{if(!p||!i)return;const F=p,q=()=>Be(exports,null,function*(){ns(!0);const oe=dp(F,ze,rt[i.id],(n==null?void 0:n.type)||0);let Ie;try{C?Ie=yield C==null?void 0:C({applicationId:n.id,sessionId:i.id,message:{content:oe,sessionId:i.id,role:Se.ChatMessageRole.User,files:rt[i.id]}}):Ie=!0}catch(ne){Ie=!1}if(ns(!1),Ie===!1){zi(!1);return}cu(F),m(void 0)});return i.ready?q():i.addEventListener("ready",q,!0),()=>{i==null||i.removeEventListener("ready",q)}},[p,i]);const cu=(F,q)=>Be(exports,null,function*(){var rr,xn,Qt;const oe=(rr=i==null?void 0:i.data)==null?void 0:rr.id;if(!oe)return;Kr(!0),rn(!0);const Ie=dp(F,ze,q,(n==null?void 0:n.type)||0);let ne;if(n.type===Se.ApplicationTypes.Agent)ne=void 0;else if(n.type===Se.ApplicationTypes.Dialog&&((xn=n.arrange)!=null&&xn.length)&&n.arrange[0].visionOpen){const yt=ze&&ze.length?ze.filter(Boolean):[];ne=yt.length?yt:void 0}else ne=void 0;const He=new Ja(Ie,oe,Se.IHistoryRole.User,q,ne);g(void 0),ut(void 0),x.current=[He,...c],M(x.current),n.id&&_&&_({applicationId:n.id,sessionId:oe,message:He});const Te=new Ja("",oe,Se.IHistoryRole.System);Te.isWaiting=!0,x.current=[Te,...x.current],M(x.current);const It=(q==null?void 0:q.map(yt=>yt.id))||[],Yt={stream:eo.configuration.stream,referenceFirst:!1};if(w!=null&&w.promptVariables){const yt=nr==null?void 0:nr.reduce((Cr,qi)=>(Cr[qi.key]=qi.value,Cr),{});Yt.formatValues=yt}if(w!=null&&w.knowledges){const yt=rx;Yt.knowledges=yt}const tn={text:Ie,fileIds:It,files:q};ne&&ne.length>0&&(tn.imageContent=ne),yield i.send(tn,Yt),mt({[oe]:[]}),(Qt=Tt.current)==null||Qt.update(),Ce([]),Fe([]),zi(!1)});z.useEffect(()=>{var Ie;const F=(Ie=i==null?void 0:i.data)==null?void 0:Ie.id;if(!F)return;const q=ne=>{if(!ne.sessionId||ne.sessionId&&ne.sessionId!==pe.current||ne.role===Se.IHistoryRole.User)return;if(ne.index===-1&&ne.code!==200&&ne.code!==11915&&(rn(!1),Kr(!1),x.current=x.current.filter(It=>!It.isWaiting),M([...x.current]),x.current=[...x.current],ne.content)){U.notification.config({getContainer:()=>(G==null?void 0:G.current)||document.body,prefixCls:"gbot-notification"}),U.notification.error({message:ne.content}),U.notification.config({getContainer:void 0,prefixCls:"gbot-notification"});return}const He=ne.actions||[],Te=new Ja(ne.content,F,Se.IHistoryRole.Robot);Te.messageId=ne.messageId||mo.v4(),Te.reasoningContent=ne.reasoningContent,Te.searchReference=ne.searchReference,Te.thinkingSecs=ne.thinkingSecs,Te.thinkingStatus=ne.thinkingStatus,Te.actions=He,Te.isLoading=!0,Te.searchingStatus=ne.searchingStatus,x.current=x.current.filter(It=>!It.isWaiting).filter(It=>!It.isReplying),ne.index===void 0&&M([Te,...x.current]),ne.code===11915&&(rn(!1),Kr(!1),Te.isLoading=!1,Te.content="请您换个问题问我吧~",Te.isSensitive=!0,M([Te,...x.current])),ne.index===-2&&(rn(!1),Kr(!1),Te.isLoading=!1,Te.content="回答已中止~",Te.isSuspend=!0,M([Te,...x.current])),ne.index===-1&&(rn(!1),Kr(!1),Te.isLoading=!1,Te.reference=ne.reference,M([Te,...x.current]),n.id&&_&&_({applicationId:n.id,sessionId:F,message:Te})),ne.index===-3&&(rn(!1),Kr(!1),Te.isLoading=!1,Te.reference=ne.reference,Te.relatedQuesion=ne.relatedQuesion,M([Te,...x.current]))},oe=()=>{i.addEventListener("message:updated",q)};return i.ready?i.addEventListener("message:updated",q):i.addEventListener("ready",oe),()=>{i==null||i.removeEventListener("message:updated",q),i==null||i.removeEventListener("ready",oe)}},[i]),z.useEffect(()=>{if(!i){be(!1);return}const F=q=>{be(q)};return be(i.frozen),i.addEventListener("frozen",F),()=>{i==null||i.removeEventListener("frozen",F)}},[i]),z.useEffect(()=>{if(!y)return;const F=y.questionContextMaxLength||4e3;L(F)},[y,D]),z.useEffect(()=>{A&&ut(A.text)},[A]),z.useEffect(()=>{U.message.config({getContainer:()=>(G==null?void 0:G.current)||document.body,prefixCls:"gbot-message",maxCount:5})},[G]);const hn=(F,q,oe)=>{U.message.open({type:F,content:q,key:oe})},Rm=F=>{const q=F.size;return q<=0?(hn("error","该文件为空,请重新上传"),!1):q>Mp*Bs?(hn("error",`图片须小于${Mp}M`),!1):(Ce(oe=>oe.length>=Ci?(hn("warning",`图片最多上传${Ci}张`),oe):[...oe,F]),!1)},dx=()=>{var F;return(n.type===Se.ApplicationTypes.Agent&&(w==null?void 0:w.imageUpload)||n.type===Se.ApplicationTypes.Dialog&&((F=n.arrange)==null?void 0:F.length)&&!!n.arrange[0].visionOpen&&(w==null?void 0:w.imageUpload))&&!R},gx=()=>!!o&&(w==null?void 0:w.fileUpload)&&(n==null?void 0:n.id)&&!R,_m=F=>{var xn,Qt;const q=Array.from(F||[]).filter(Boolean);if(!q.length)return;const oe=dx(),Ie=gx(),ne=[],He=[];let Te=0,It=0,Yt=0;q.forEach(yt=>{var oh,sh,lh;if(((oh=yt.type)==null?void 0:oh.startsWith("image/"))||!!L1(yt.name)){oe?ne.push(yt):Te++;return}const qi=(lh=(sh=yt.name)==null?void 0:sh.split(".").pop())==null?void 0:lh.toLowerCase();if(tL.includes(yt.type)||["pdf","doc","docx"].includes(qi||"")){Ie?He.push(yt):It++;return}Yt++});const tn=[],rr=Te+It+Yt;if(!Ie&&!oe)rr&&tn.push(`当前不支持上传文件/图片,已忽略${rr}个文件`);else if(Ie&&!oe){const yt=Te+Yt;yt&&tn.push(`仅支持上传 .doc/.docx/.pdf 文件,已忽略${yt}个其他类型文件`)}else if(!Ie&&oe){const yt=It+Yt;yt&&tn.push(`仅支持上传图片(.jpg/.jpeg/.png/.bmp),已忽略${yt}个其他类型文件`)}else Yt&&tn.push(`存在不支持的文件类型,已忽略${Yt}个文件`);if(tn.length&&hn("warning",tn.join(";"),"precheck-warn"),ne.length){const yt=Math.max(0,Ci-ie.length),Cr=ne.slice(0,yt);Cr.forEach(qi=>Rm(qi)),ne.length>Cr.length&&hn("warning",`最多上传${Ci}张图片`)}He.length&&((Qt=(xn=Tt.current)==null?void 0:xn.appendFiles)==null||Qt.call(xn,He))},Um=F=>{var oe;const q=(oe=F.clipboardData)==null?void 0:oe.files;q&&q.length&&(F.preventDefault(),F.stopPropagation(),_m(q))},Qm=F=>{F.preventDefault()},Pm=F=>{var oe;F.preventDefault(),F.stopPropagation();const q=(oe=F.dataTransfer)==null?void 0:oe.files;q&&q.length&&_m(q)},Fm=()=>Be(exports,null,function*(){var F;return(F=i==null?void 0:i.data)!=null&&F.id?i:($i.current||($i.current=new Promise((q,oe)=>{Ai(!0),a==null||a({netOpen:l?ai.OPEN:ai.CLOSE}).then(Ie=>{var ne,He;s==null||s(Ie),Ai(!1),u(!!((ne=Ie.data)!=null&&ne.netOpen)),Ua(!!((He=Ie.data)!=null&&He.enableNetOpen)),uu(Ie),q(Ie)}).catch(Ie=>{$i.current=null,oe(Ie)})})),$i.current)}),px=F=>Be(exports,null,function*(){const q=yield Fm();return Nx(q,F)}),Nx=(F,q)=>{const oe=L1(q.name);return new Promise(Ie=>{var He;const ne={files:[`${mo.v4()}.${oe}`],isv:"minio",knowledgeId:((He=F.data)==null?void 0:He.id)||"",type:1};D==null||D.postTicket(ne).then(Te=>{D.uploadMinioFile(Te.minio,q).then(()=>{var rr,xn;const It=(rr=Te.minio.endpoints)==null?void 0:rr[0],Yt=Te.minio.bucket,tn=(xn=Te.minio.fileKeys)==null?void 0:xn[0];Ie(`${Te.minio.useSSL?"https:":location.protocol}//${It}/${Yt}/${tn}`)}).catch(()=>{})}).catch(()=>{})})};z.useEffect(()=>{const F=T.current;F&&!Lm&&F.scrollTo({top:F.scrollHeight})},[c]);const Bm=(F,q)=>new Promise(oe=>{if(!q.file.url||!(n!=null&&n.id))return oe();const Ie=xt(ee({},q.file),{type:1});D==null||D.postApplicationIdSessionKnowledgeSessionFile(n==null?void 0:n.id,F,Ie).finally(()=>{var ne;(ne=Tt.current)==null||ne.update().finally(oe)})}),fx=()=>{var F;(F=i==null?void 0:i.data)!=null&&F.id&&(rn(!1),i.suspend())},mx=F=>{const q=T.current;q&&setTimeout(()=>{q.scrollTo({top:q.scrollHeight,behavior:F==null?void 0:F.behavior})},F==null?void 0:F.ms)},hx=()=>{if(!T.current)return;const F=T.current.scrollTop<=-80;nx(F)},yx=Tr.useMemoizedFn(F=>{var q,oe;(q=De.current)==null||q.update(F),(oe=De.current)==null||oe.focus()}),Tx=Tr.useMemoizedFn(F=>{Ym(F)}),Ix=Tr.useMemoizedFn(()=>{var q;if(!((q=i==null?void 0:i.data)!=null&&q.id))return;x.current=[...c.slice(1,c.length)],M(x.current);const F=new Ja("",i.data.id,Se.IHistoryRole.System);F.isWaiting=!0,x.current=[F,...x.current],M(x.current),Kr(!0),rn(!0),i.answerAgain()});z.useEffect(()=>{var F,q;pe.current=(F=i==null?void 0:i.data)==null?void 0:F.id,!xm&&((q=J.current)==null||q.clear())},[i]);const Dx=()=>{var oe;if(!((oe=i==null?void 0:i.data)!=null&&oe.id))return;const q=c[c.length-1].messageTime;i.fetchMessages({endTime:q,pageSize:Y1}).then(Ie=>{const ne=Ie||[];if(!ne||!(ne!=null&&ne.length)){_a(!1);return}ne.length<10?_a(!1):_a(!0),M([...c,...ne.reverse()])})},jx=F=>Be(exports,null,function*(){var q,oe;if(!((q=i==null?void 0:i.data)!=null&&q.id))u(F);else{if(yield i.setNetOpen(F),!((oe=i.data)!=null&&oe.id))return;u(F)}}),Mu=()=>Be(exports,null,function*(){i?i.fetchData().then(F=>{var q;(q=i==null?void 0:i.data)!=null&&q.id&&(u(F.netOpen),Ua(F.enableNetOpen))}):(u(typeof(Y==null?void 0:Y.connectNetwork)=="object"&&typeof(Y==null?void 0:Y.connectNetwork.default)=="boolean"?Y.connectNetwork.default:!1),Ua(n.arrange[0].enableNetOpen))});z.useEffect(()=>{Mu()},[i]),z.useEffect(()=>{requestAnimationFrame(()=>{var q,oe;if(T.current){const Ie=document.getElementById("chat-main"),ne=(q=T.current)==null?void 0:q.querySelector(".infinite-scroll-component__outerdiv"),He=(oe=T.current)==null?void 0:oe.querySelector(".infinite-scroll-component");if(!ne||!He||!Ie)return;const Te=Ie.offsetHeight;if(He.offsetHeight<=Te){if(ne.style.height==="100%")return;ne.style.height="100%"}else{if(ne.style.height==="auto")return;ne.style.height="auto"}}})},[c]),z.useEffect(()=>{if(i)return;const F=()=>{const Ie=((y==null?void 0:y.promptVariables)||[]).filter(ne=>ne.type?!(ne.type===Se.PromptVariableType.User&&ne.key==="query")&&!(ne.type===Se.PromptVariableType.System&&ne.key==="datetime")&&ne.status===1:ne.key!=="query"&&ne.status===1).map((ne,He)=>{var It,Yt;let Te="";return typeof(Y==null?void 0:Y.promptVariables)=="object"&&(Te=((Yt=(It=Y.promptVariables.default)==null?void 0:It.find(tn=>tn.key===ne.key&&tn.type===ne.type))==null?void 0:Yt.value)||""),{id:He+"",key:ne.key,name:ne.name,value:Te,type:ne.type}});Ra([...Ie].sort((ne,He)=>ne.key.localeCompare(He.key)))};return y!=null&&y.ready?F():y==null||y.addEventListener("ready",F),()=>{y==null||y.removeEventListener("ready",F)}},[i,y,Y==null?void 0:Y.promptVariables]);const Gm=()=>a==null?void 0:a({netOpen:l?ai.OPEN:ai.CLOSE}).then(F=>{var q,oe;return s==null||s(F),Ai(!1),u(!!((q=F.data)!=null&&q.netOpen)),Ua(!!((oe=F.data)!=null&&oe.enableNetOpen)),uu(F),F}),Wm=z.useMemo(()=>{var F;return n.arrange&&((F=n.arrange[0])!=null&&F.openingContent)?f.jsx(nL,{application:n,history:{role:1,content:n.arrange[0].openingContent,code:200,messageId:"opening-message",sessionId:"",reference:[],searchReference:[],messageTime:Zt(Date.now()).format("YYYY-MM-DD HH:mm:ss"),actions:[],isLoading:!1},actions:!!c.length,markdown:Y==null?void 0:Y.markdown}):null},[n==null?void 0:n.arrange,c]);return z.useImperativeHandle(t,()=>({getCurrentInputText:()=>{var F;return(F=De.current)==null?void 0:F.getCurrentText()}})),z.useEffect(()=>{var q;const F=(q=i==null?void 0:i.data)==null?void 0:q.id;F&&mt(oe=>xt(ee({},oe),{[F]:[]}))},[(Hm=i==null?void 0:i.data)==null?void 0:Hm.id]),f.jsxs("div",{className:"agent-chat",children:[ox?f.jsx("div",{className:"session-loading",children:f.jsx(U.Spin,{})}):f.jsxs(f.Fragment,{children:[(w==null?void 0:w.promptVariables)&&f.jsx(oL,{ref:B,appId:n.id,currentSession:i,promptVariables:nr,setPromptVariables:Ra,setCurrentSession:s}),f.jsxs("div",{className:"chat-main",id:"chat-main",style:S,children:[f.jsx("div",{className:"chat-main-wrapper",id:"scrollableDiv",style:{height:"100%",overflowY:"auto",display:"flex",flexDirection:"column-reverse"},ref:T,onScroll:hx,children:($m=i==null?void 0:i.data)!=null&&$m.id&&(c!=null&&c.length)?f.jsxs(xx,{dataLength:c.length,next:Dx,style:{display:"flex",flexDirection:"column-reverse",overflowX:"hidden"},inverse:!0,endMessage:c.length>Y1&&((qm=T.current)!=null&&qm.scrollTop)&&((Vm=T.current)==null?void 0:Vm.scrollTop)<-10?f.jsx(U.Divider,{plain:!0,children:"没有更多数据了"}):null,hasMore:Cm,loader:f.jsx("div",{style:{height:"50px",textAlign:"center",overflow:"hidden"},children:f.jsx(U.Spin,{})}),scrollableTarget:"scrollableDiv",children:[c.map((F,q)=>f.jsx(pZ,{application:n,currentSession:i,history:F,docViewerUrl:r,isLastHistory:q===0,onRelatedClick:Tx,onAgainClick:Ix,onEditClick:yx,markdown:Y==null?void 0:Y.markdown},F.messageId+q)),!Cm&&Wm]}):f.jsxs("div",{className:"main-empty",children:[(Y==null?void 0:Y.greeting)!==!1&&f.jsx(qV,{text:Y!=null&&Y.greeting&&typeof Y.greeting=="object"&&Y.greeting.text!==void 0?Y.greeting.text:(Zm=n.arrange)!=null&&Zm.length&&((Jm=n.arrange[0])!=null&&Jm.greetings)?n.arrange[0].greetings:k1.text,icon:Y===void 0||Y.greeting===!0||((Xm=Y.greeting)==null?void 0:Xm.icon)===void 0?$||k1.icon:Y.greeting.icon,children:!!Ye.length&&(((Y==null?void 0:Y.greeting)===void 0||(Y==null?void 0:Y.greeting))===!0||typeof(Y==null?void 0:Y.greeting)=="object"&&Y.greeting.questions!==!1)&&f.jsx(iL,{ref:J,sid:(Km=i==null?void 0:i.data)==null?void 0:Km.id,isRecommendClearing:tt,data:Ye,layoutBreakpoints:typeof(Y==null?void 0:Y.greeting)=="object"?Y.greeting.layoutBreakpoints:void 0,onItemClick:F=>{var oe,Ie,ne;if(g(F==null?void 0:F.question),ut(F==null?void 0:F.question),tt)return;F!=null&&F.id&&gt(!0);const q=(oe=i==null?void 0:i.data)==null?void 0:oe.id;w!=null&&w.fileUpload?(ne=(Ie=Tt.current)==null?void 0:Ie.clear())==null||ne.then(()=>{var He,Te;F!=null&&F.id&&(q?(He=Bm(q,F))==null||He.finally(()=>{gt(!1)}):(gt(!1),Ai(!0),(Te=Gm())==null||Te.then(It=>{var Yt;(Yt=Bm(It.id,F))==null||Yt.finally(()=>{gt(!1)})})))}):q?gt(!1):(gt(!1),Ai(!0),Gm())}})}),Wm]})}),Vt&&f.jsx("div",{className:"session-stop",children:f.jsx(U.Button,{type:"primary",style:{background:"white"},ghost:!0,size:"small",icon:f.jsx(nt,{type:"icon-zantinghuida",style:{fontSize:16}}),onClick:()=>fx(),children:"停止回答"})}),Lm&&(c==null?void 0:c.length)>0&&f.jsx("div",{className:"back-bottom",children:f.jsx(U.Button,{size:"small",onClick:()=>mx({behavior:"smooth"}),type:"link",icon:f.jsx(nt,{type:"icon-yijianhuidaodibu",style:{fontSize:24}})})})]}),f.jsx("div",{className:"chat-footer",children:f.jsxs("div",{className:"chat-footer-input",children:[ie.length>0&&f.jsx("div",{className:"input-files",children:ie.map((F,q)=>f.jsx(WV,{className:"thumb-40",file:F,actions:{upload:oe=>Be(exports,null,function*(){me(Ie=>Ie+1);try{return yield px(oe)}finally{me(Ie=>Math.max(0,Ie-1))}}),remove:()=>{Ce(oe=>oe.filter((Ie,ne)=>ne!==q)),Fe(oe=>oe.filter((Ie,ne)=>ne!==q))}},onUrlChange:oe=>{Fe(Ie=>{const ne=[...Ie];return ne[q]=oe,ne})}},q))}),f.jsxs("div",{className:"footer-upload-action-wrapper",children:[f.jsxs(U.Space,{className:"footer-upload-action",onClick:F=>F.preventDefault(),children:[f.jsxs(U.Space,{children:[(n.type===Se.ApplicationTypes.Agent&&(w==null?void 0:w.imageUpload)||n.type===Se.ApplicationTypes.Dialog&&((eh=n.arrange)==null?void 0:eh.length)&&!!n.arrange[0].visionOpen&&(w==null?void 0:w.imageUpload))&&f.jsx(U.Upload,{multiple:!0,disabled:ie.length>=Ci||R,accept:".jpg, .png, .jpeg,.bmp",listType:"picture-card",beforeUpload:Rm,className:"footer-upload-picture",showUploadList:!1,children:ie.length<Ci?f.jsx(U.Tooltip,{placement:"topLeft",overlayClassName:"footer-upload-tooltip",title:f.jsx("div",{children:`支持上传.jpg .png .jpeg
320
- .bmp格式的图片数据,单文件最大${Mp}M,最多${Ci}张`}),children:f.jsx(U.Button,{type:"text",className:"camera-out-btn",style:{width:"22px",position:"relative",bottom:"-2px"},icon:f.jsx(nt,{type:"icon-shangchuantupian",className:"icon-tianjia",style:{fontSize:"22px"}})})}):f.jsx(U.Button,{type:"text",className:"camera-out-btn",style:{width:"22px",position:"relative",bottom:"-2px"},disabled:!0,icon:f.jsx(nt,{type:"icon-shangchuantupian",className:"icon-tianjia",style:{fontSize:"22px"}})})}),o&&(w!=null&&w.fileUpload)&&(n!=null&&n.id)?f.jsx(aL,{appId:n==null?void 0:n.id,ref:Tt,isFirstSession:xm,docViewerUrl:r,onStatusChange:F=>Be(exports,null,function*(){F!=="process"?(ve(!0),Mu()):ve(!1)}),createSession:()=>Fm().then(F=>{var oe;return((oe=F.data)==null?void 0:oe.id)||""}),sid:(th=i==null?void 0:i.data)==null?void 0:th.id,disabled:Ln||R,afterFileAdd:(F,q)=>{q&&mt(oe=>{const Ie=oe[q]||[];return{[q]:[...Ie,F]}})},afterFileDelete:F=>{var oe;const q=(oe=i==null?void 0:i.data)==null?void 0:oe.id;q&&mt(Ie=>{const ne=Ie[q]||[];return{[q]:ne.filter(He=>He.id!==F)}})},onFileListChange:F=>{it(F)},shouldContinue:en,afterFilesClear:()=>{var q;const F=(q=i==null?void 0:i.data)==null?void 0:q.id;F&&(mt({[F]:[]}),Mu())}}):null,(w==null?void 0:w.prompt)&&(n==null?void 0:n.id)&&f.jsx(gZ,{appId:n.id,list:[],search:re?_e:"",onPromptSelect:F=>{ut(F.context),g(F.context)},disabled:R})]}),f.jsxs(U.Space,{children:[(w==null?void 0:w.connectNetwork)&&n.type===Se.ApplicationTypes.Dialog&&((nh=n.arrange)==null?void 0:nh.length)&&!!n.arrange[0].enableNetOpen&&f.jsx(sZ,{sessionId:(rh=i==null?void 0:i.data)==null?void 0:rh.id,netStatus:l,enable:typeof(Y==null?void 0:Y.connectNetwork)=="object"&&typeof(Y==null?void 0:Y.connectNetwork.diabled)=="boolean"?!(Y!=null&&Y.connectNetwork.diabled):ax,disabledTip:i?void 0:"网络访问已被禁用",onNetStatusChange:F=>{jx(F)}}),(w==null?void 0:w.sessionList)&&f.jsx(rZ,{currentSessionId:(ih=i==null?void 0:i.data)==null?void 0:ih.id,onSessionChange:(F,q)=>{ut(void 0),is(!0),s==null||s(q)},disabled:R}),Z&&fe==="float"&&f.jsx("div",{className:"session-history-drawer-component",children:f.jsx(U.Popover,{placement:"topRight",showArrow:!1,overlayClassName:"session-history-overlay",overlayStyle:{padding:"4px"},getPopupContainer:F=>F.parentNode,content:"会话历史记录",children:f.jsx(U.Button,{className:"history-overlay-action",disabled:R,type:"text",icon:f.jsx(nt,{type:"icon-lishijilu",style:{fontSize:24}}),onClick:()=>Om(!0)})})}),(w==null?void 0:w.sessionOpen)&&f.jsx(U.Button,{icon:f.jsx(ht.PlusOutlined,{}),className:"add-btn",type:"primary",disabled:Vt||!i||!c.length||R,onClick:()=>{var F,q;is(!1),s==null||s(null),$i.current=null,u(!1),(F=B.current)==null||F.clear(),(q=J.current)==null||q.clear()},children:"新会话"})]})]}),!!lu&&f.jsx("div",{className:"remainingSeconds-mark"})]}),f.jsxs("div",{className:"footer-textarea",onPaste:Um,onPasteCapture:Um,onDrop:Pm,onDropCapture:Pm,onDragOver:Qm,onDragOverCapture:Qm,children:[f.jsx(rL,{ref:De,maxLength:he,text:qe,networkStatus:!1,loading:Sm||rs,disabled:se||ye||R||Sm||rs,onTextSend:Ym,onChange:(F,q)=>{ut(F);const oe=q.getText().replace(/[\n\s]+$/,"");g(oe),zt(oe),re||Ee(!0)},clearAction:f.jsx(U.Space,{size:0,children:f.jsx(U.Button,{type:"link",disabled:Ln||R,ghost:!0,icon:f.jsx(nt,{style:{fontSize:22},type:"icon-qingchujiyi"}),onClick:()=>cx()})})}),!!lu&&f.jsxs("div",{className:"remainingSeconds-time",children:["您之前对话触发敏感词拦截,当前处于禁言状态,暂时无法发送消息,剩余禁言时长",lu]})]})]})}),f.jsx(ZV,{tips:b}),K&&f.jsx(KV,{isvisible:K,files:Ue,sessionId:(ah=i==null?void 0:i.data)==null?void 0:ah.id,onClose:F=>{de(!1),tr(!1)}})]}),vm&&f.jsx(oZ,{currentSession:i,application:n,networkStatus:l,setCurrentSession:s,disabled:R,isSessionHistoryVisible:vm,setIsSessionHistoryVisible:Om,onSessionChange:F=>{is(!0)}})]})});const uL=e=>{const{disabled:t,checkedValues:n,currKnowledgeList:r,selectCount:i,onSelectChange:a}=e,[o,s]=z.useState(!1),l=f.jsx(U.Checkbox.Group,{style:{width:"100%"},onChange:a,value:n,disabled:t,children:f.jsx(U.Row,{gutter:[20,12],children:r==null?void 0:r.map(c=>f.jsx(U.Col,{span:24,children:f.jsx(U.Checkbox,{value:c.id,children:c.name})},c.id))})}),u=c=>{s(c)};return f.jsx("div",{className:"knowledge-select",style:{borderColor:o?"#9C24F2":"#84868C"},children:f.jsx(U.Popover,{className:"select-popover",placement:"bottomRight",title:null,content:l,trigger:"click",overlayStyle:{width:280},onOpenChange:u,getPopupContainer:c=>c.parentNode,children:f.jsxs("div",{className:"",onClick:c=>c.preventDefault(),children:[f.jsx(nt,{className:"select-icon",type:"icon-open"}),f.jsx("span",{className:"title",children:"参考知识库"}),f.jsxs("span",{className:"content",children:["已选 ",i," 个"]})]})})})},mZ=e=>{var T,D;const{currentSession:t,application:n,setCheckKnowledges:r}=e,{mode:i,transform:a,features:o}=z.useContext($t),[s,l]=z.useState([]),[u,c]=z.useState(typeof(o==null?void 0:o.knowledges)=="object"?((T=o.knowledges.default)==null?void 0:T.map(y=>y.id))||[]:[]),[M,d]=z.useState(0),[g,p]=z.useState(!1);z.useEffect(()=>{if(!(n!=null&&n.id))return;const y=n.arrange;if(!(y!=null&&y.length))return;const b=y[0].knowledges||[];l(b);const w=typeof(o==null?void 0:o.knowledges)=="object"&&o.knowledges.default||b;if(Array.isArray(w)&&w.some(C=>Array.isArray(C.fileIds)&&C.fileIds.length===0))throw Error("fileIds cannot be an empty array");if(Nl(w||[])>oi)throw Error(`knowledges and fileIds total count cannot exceed ${oi}`);if(!t){c(w.map(P=>P.id)),d(w.length),r==null||r(w);return}const _=()=>{const P=t.knowledges||w;d(P.length);const C=P.map(S=>S.id);c(C)};return _(),t.addEventListener("data:updated",_),()=>{t==null||t.removeEventListener("data:updated",_)}},[n,t]),z.useEffect(()=>{var I;if(!g||(p(!1),!(n!=null&&n.id)))return;const y=[];u==null||u.map(b=>{const w=s==null?void 0:s.find(A=>A.id===b);y.push(w)}),(I=t==null?void 0:t.data)!=null&&I.id&&t.setKnowledges(y)},[g]);const m=y=>{p(!0),c(y);const I=[];y==null||y.map(b=>{const w=s==null?void 0:s.find(A=>A.id===b);I.push(w)}),r==null||r(I),d(y.length)};return f.jsxs("div",{className:"chat-header",children:[f.jsxs(U.Space,{className:"header-title",children:[i==="inlay"&&((D=t==null?void 0:t.data)==null?void 0:D.name),i==="float"&&(n==null?void 0:n.name)]}),(a==null?void 0:a.knowledges)&&s.length!==0&&f.jsx(uL,{disabled:typeof(o==null?void 0:o.knowledges)=="object"&&(o==null?void 0:o.knowledges.diabled)||!1,checkedValues:u,currKnowledgeList:s,selectCount:M,onSelectChange:m})]})};const hZ=z.forwardRef((e,t)=>{const{sessionId:n,appId:r,docViewerUrl:i}=e,[a,o]=z.useState(),{showHeader:s,agentClient:l,sider:u,onSessionLoad:c,features:M,mode:d}=z.useContext($t),[g,p]=z.useState(),m=z.useRef(null),[T,D]=z.useState(""),[y,I]=z.useState(),b=z.useRef(null),[w,A]=z.useState(!1);z.useState([]);const{setIsSwitchingToExistingSession:_}=am();z.useEffect(()=>{var C;A(a?!!((C=a.data)!=null&&C.netOpen):typeof(M==null?void 0:M.connectNetwork)=="object"&&typeof(M==null?void 0:M.connectNetwork.default)=="boolean"?M.connectNetwork.default:!1)},[a]),z.useEffect(()=>{const C=()=>Be(exports,null,function*(){const S=l==null?void 0:l.application;if(!(S!=null&&S.id))return;const R=S==null?void 0:S.arrange;if(!(R!=null&&R.length))return;const G=R[0].embeddingService;D(G),p(S)});if(l!=null&&l.ready){C();return}return l==null||l.addEventListener("ready",()=>C()),()=>{l==null||l.removeEventListener("ready",C)}},[l]),z.useEffect(()=>{l&&n&&(l.ready?l==null||l.getSessions().then(C=>Be(exports,null,function*(){o==null||o(C.find(S=>S.id===n))})):l.addEventListener("ready",()=>Be(exports,null,function*(){l==null||l.getSessions().then(C=>Be(exports,null,function*(){o==null||o(C.find(S=>S.id===n))}))}),!0))},[l,n]),z.useEffect(()=>{if(!a){c&&c({applicationId:r,sessionId:"",session:null,sessionInstance:null});return}a.data&&c&&c({applicationId:r,sessionId:a.data.id,session:a.data,sessionInstance:a}),a.addEventListener("data:loaded",()=>{a!=null&&a.data&&c&&c({applicationId:r,sessionId:a.data.id,session:a.data,sessionInstance:a})},!0)},[a]);const P=C=>{var S;return(S=m.current)==null?void 0:S.create(xt(ee({},C),{knowledges:y}))};return z.useImperativeHandle(t,()=>({createSession:C=>P(C),getSessionList:()=>{var S;const C=((S=m.current)==null?void 0:S.list())||[];return Promise.resolve(C)},getCurrentInputText:()=>{var C;return(C=b.current)==null?void 0:C.getCurrentInputText()}})),f.jsx("div",{className:"dialog",children:f.jsxs("div",{className:"dialog-pannel",children:[f.jsx("div",{className:"dialog-sider",style:{display:u&&d==="inlay"?"block":"none"},children:f.jsx(om,{ref:m,appId:r,networkStatus:w,currentSession:a,application:g,setCurrentSession:o,checkKnowledges:y,setCheckKnowledges:s?I:void 0,sessionId:n,afterSessionClick:C=>{var S,R;((S=C.data)==null?void 0:S.id)!==((R=a==null?void 0:a.data)==null?void 0:R.id)&&_(!0)}})}),f.jsx("div",{className:"dialog-content",children:f.jsxs("div",{className:"dialog-chat",children:[s&&f.jsx("div",{className:"dialog-chat-header",children:f.jsx(mZ,{setCheckKnowledges:I,application:g,currentSession:a})}),f.jsx("div",{className:"dialog-chat-content",children:(g==null?void 0:g.id)&&f.jsx(fZ,{setNetworkStatus:A,networkStatus:w,application:g,currentSession:a,onCreateSession:P,docViewerUrl:i,embeddingService:T,setCurrentSession:o,ref:b})})]})})]})})}),yZ=z.forwardRef((e,t)=>{const{className:n,triggerButton:r,size:i,theme:a,icon:o,docViewerUrl:s,token:l,debug:u,env:c,plugins:M,mcp:d,footer:g,defaultInput:p,onComment:m,onSessionLoad:T,onSessionUnload:D,onMessage:y,beforeMessageSend:I,bodyStyle:b,apiUrl:w,sessionId:A,disabled:_,transform:P,features:C,stream:S,agentClient:R,application:Y}=e,G=z.useRef(null),[$,Z]=z.useState(!1),[fe,V]=z.useState(),[se,be]=z.useState(i),[x,pe]=z.useState(e.open),he=z.useRef(null);z.useEffect(()=>{Y&&(console.log("[AgentClientUI] token",R,Y),V(Y.id))},[Y]),U.ConfigProvider.config({theme:a}),z.useEffect(()=>{i&&be(i)},[i]);const L=(ie,{element:Ce,size:ze})=>{be({width:Number(ze.width),height:ze.height})};return z.useImperativeHandle(t,()=>({createSession:ie=>{var Ce;return(Ce=he.current)==null?void 0:Ce.createSession(ie)},getSessionList:()=>{var ie;return(ie=he.current)==null?void 0:ie.getSessionList()},getCurrentInputText:()=>{var ie;return(ie=he.current)==null?void 0:ie.getCurrentInputText()}})),f.jsx(U.ConfigProvider,{locale:q1,children:f.jsxs(X1,{value:xt(ee({},e),{popupContainer:G,agentClient:R,footer:g,defaultInput:p,onComment:m,onSessionLoad:T,onSessionUnload:D,onMessage:y,beforeMessageSend:I,bodyStyle:b,disabled:_,transform:P,features:C}),children:[f.jsx(wx.Resizable,{height:(se==null?void 0:se.height)||"100%",width:(se==null?void 0:se.width)||"100%",maxConstraints:[document.body.clientWidth-45],minConstraints:[Number(i==null?void 0:i.minWidth)],onResize:L,handle:f.jsx("span",{className:"resize-handle-ew"}),resizeHandles:n=="float"?["w"]:[],children:f.jsxs("div",{id:"dialog-modal",className:`gbot-dialog-modal ${n} ${x?"opened":"closed"}`,style:xt(ee({},i),{width:n=="float"?se==null?void 0:se.width:i==null?void 0:i.width,height:n==="float"?se==null?void 0:se.height:i==null?void 0:i.height,maxHeight:"100vh"}),ref:G,children:[$?f.jsx("div",{className:"loading",children:f.jsx(U.Spin,{})}):fe&&R?f.jsx(iZ,{children:f.jsx(hZ,{ref:he,appId:fe,docViewerUrl:s,bodyStyle:b,sessionId:A})}):null,(r==null?void 0:r.visible)&&f.jsx(U.Button,{className:"trigger-btn close-btn",icon:f.jsx("img",{src:o}),onClick:()=>pe(!1)})]})}),(r==null?void 0:r.visible)&&!x&&f.jsx(U.Button,{className:`${n}-trigger-btn open-btn`,style:r.style,icon:f.jsx("img",{src:o}),onClick:()=>pe(!0)})]})})}),TZ="@glodon-aiot/agent-cli-ui",IZ="3.18.1-alpha.16",DZ="./dist/es/index.mjs",jZ="./dist/lib/index.js",AZ="./dist/src/index.d.ts",zZ={import:"./dist/es/index.mjs",require:"./dist/lib/index.js",types:"./dist/src/index.d.ts"},bZ=["dist"],wZ="module",EZ="dist/src/index.d.ts",LZ={dev:"vite",start:"vite",build:"tsc && node --max-old-space-size=4096 ./node_modules/vite/bin/vite.js build --mode prod && yarn build:cdn","build:pre":"tsc && node --max-old-space-size=4096 ./node_modules/vite/bin/vite.js build --mode prod","build:cdn":"tsc && vite build --mode prod --config ./vite.config.cdn.ts",preview:"vite preview",check:"yarn prettier --check .",write:"yarn prettier --write .",lint:"eslint --ext .tsx,.ts --fix ./example -c .eslintrc.js",storybook:"start-storybook -p 6006 -s public","build-storybook":"build-storybook -s public",docs:"start-storybook -p 6006",commit:"cz"},xZ={antd:">=4.0.0",react:">=16.9.0","react-dom":">=16.9.0",webpack:"*"},CZ={"@ant-design/icons":"^5.3.4","@glodon-aiot/apis":"^3.18.1-alpha.16","@glodon-aiot/bot-client-sdk":"^3.18.1-alpha.16","@matejmazur/react-mathjax":"^0.1.10","@react-pdf-viewer/core":"^3.12.0","@react-pdf-viewer/default-layout":"^3.12.0","@react-pdf-viewer/locales":"^1.0.0","@react-pdf-viewer/toolbar":"^3.12.0",ahooks:"^3.8.5",axios:"0.24.0",classnames:"^2.5.1","copy-to-clipboard":"^3.3.3",dayjs:"^1.11.13",lodash:"^4.17.21","quill-delta":"^5.1.0","react-infinite-scroll-component":"^6.1.0","react-quill-new":"^3.6.0","react-resizable":"^3.0.5",uuid:"^11.1.0"},SZ={"@babel/core":"^7.20.12","@commitlint/cli":"^17.0.3","@commitlint/config-conventional":"^17.0.3","@rollup/plugin-babel":"^6.0.4","@rollup/plugin-commonjs":"^28.0.0","@rollup/plugin-typescript":"^11.1.6","@storybook/addon-actions":"6.3.6","@storybook/addon-essentials":"6.4.9","@storybook/addon-interactions":"^6.5.16","@storybook/addon-links":"6.3.5","@storybook/addon-postcss":"2.0.0","@storybook/builder-vite":"^0.4.0","@storybook/node-logger":"6.4.9","@storybook/react":"6.4.9","@storybook/testing-library":"^0.0.13","@types/lodash":"^4","@types/react":"^16.9.0 || ^17.0.0 || ^18.0.0","@types/react-dom":"^16.9.0 || ^17.0.0 || ^18.0.0","@typescript-eslint/eslint-plugin":"^5.35.1","@typescript-eslint/parser":"^5.35.1","@vitejs/plugin-react":"^3.1.0",antd:"^4.24.0","babel-loader":"^8.3.0","babel-plugin-import":"^1.13.8",commitizen:"^4.3.0","css-loader":"^6.7.3","cz-conventional-changelog":"^3.3.0","cz-customizable":"^7.0.0",eslint:"^8.0.1","eslint-config-prettier":"^8.5.0","eslint-config-standard-with-typescript":"^22.0.0","eslint-plugin-import":"^2.25.2","eslint-plugin-n":"^15.0.0","eslint-plugin-promise":"^6.0.0","eslint-plugin-react":"^7.31.0","eslint-plugin-storybook":"^0.6.10",husky:">=6",less:"^4.1.2","less-loader":"^11.1.0","lint-staged":">=10","postcss-loader":"^7.2.4",prettier:"2.7.1",react:"^17.0.2","react-dom":"^17.0.2","require-from-string":"^2.0.2","rollup-plugin-visualizer":"^6.0.1","storybook-less-loader":"^0.1.0",typescript:"*",vite:"^4.1.1","vite-plugin-css-injected-by-js":"^3.5.0","vite-plugin-dts":"^4.3.0","vite-plugin-externalize-deps":"^0.9.0"},vZ=[">0.2%","not dead","not op_mini all"],OZ=["last 1 chrome version","last 1 firefox version","last 1 safari version"],kZ={commitizen:{path:"node_modules/cz-customizable"},"cz-customizable":{config:".cz-config.cjs"}},YZ={access:"public",registry:"https://registry.npmjs.org/"},RZ={hooks:{"commit-msg":"validate-commit-msg"}},_Z={name:TZ,version:IZ,module:DZ,main:jZ,typings:AZ,exports:zZ,files:bZ,type:wZ,types:EZ,scripts:LZ,peerDependencies:xZ,dependencies:CZ,devDependencies:SZ,"lint-staged":{"*.{js,css,md,jsx,less,ts,tsx,json}":"prettier --write"},production:vZ,development:OZ,config:kZ,publishConfig:YZ,husky:RZ};var cL=(e=>(e.dev="https://aiot-dev.glodon.com/api/cvforcepd",e.test="https://aiot-dev.glodon.com/api/cvforce",e.prod="https://copilot.glodon.com/api/cvforce",e.local="http://localhost:3000/api/cvforcepd",e))(cL||{});//! moment.js
320
+ .bmp格式的图片数据,单文件最大${Mp}M,最多${Ci}张`}),children:f.jsx(U.Button,{type:"text",className:"camera-out-btn",style:{width:"22px",position:"relative",bottom:"-2px"},icon:f.jsx(nt,{type:"icon-shangchuantupian",className:"icon-tianjia",style:{fontSize:"22px"}})})}):f.jsx(U.Button,{type:"text",className:"camera-out-btn",style:{width:"22px",position:"relative",bottom:"-2px"},disabled:!0,icon:f.jsx(nt,{type:"icon-shangchuantupian",className:"icon-tianjia",style:{fontSize:"22px"}})})}),o&&(w!=null&&w.fileUpload)&&(n!=null&&n.id)?f.jsx(aL,{appId:n==null?void 0:n.id,ref:Tt,isFirstSession:xm,docViewerUrl:r,onStatusChange:F=>Be(exports,null,function*(){F!=="process"?(ve(!0),Mu()):ve(!1)}),createSession:()=>Fm().then(F=>{var oe;return((oe=F.data)==null?void 0:oe.id)||""}),sid:(th=i==null?void 0:i.data)==null?void 0:th.id,disabled:Ln||R,afterFileAdd:(F,q)=>{q&&mt(oe=>{const Ie=oe[q]||[];return{[q]:[...Ie,F]}})},afterFileDelete:F=>{var oe;const q=(oe=i==null?void 0:i.data)==null?void 0:oe.id;q&&mt(Ie=>{const ne=Ie[q]||[];return{[q]:ne.filter(He=>He.id!==F)}})},onFileListChange:F=>{it(F)},shouldContinue:en,afterFilesClear:()=>{var q;const F=(q=i==null?void 0:i.data)==null?void 0:q.id;F&&(mt({[F]:[]}),Mu())}}):null,(w==null?void 0:w.prompt)&&(n==null?void 0:n.id)&&f.jsx(gZ,{appId:n.id,list:[],search:re?_e:"",onPromptSelect:F=>{ut(F.context),g(F.context)},disabled:R})]}),f.jsxs(U.Space,{children:[(w==null?void 0:w.connectNetwork)&&n.type===Se.ApplicationTypes.Dialog&&((nh=n.arrange)==null?void 0:nh.length)&&!!n.arrange[0].enableNetOpen&&f.jsx(sZ,{sessionId:(rh=i==null?void 0:i.data)==null?void 0:rh.id,netStatus:l,enable:typeof(Y==null?void 0:Y.connectNetwork)=="object"&&typeof(Y==null?void 0:Y.connectNetwork.diabled)=="boolean"?!(Y!=null&&Y.connectNetwork.diabled):ax,disabledTip:i?void 0:"网络访问已被禁用",onNetStatusChange:F=>{jx(F)}}),(w==null?void 0:w.sessionList)&&f.jsx(rZ,{currentSessionId:(ih=i==null?void 0:i.data)==null?void 0:ih.id,onSessionChange:(F,q)=>{ut(void 0),is(!0),s==null||s(q)},disabled:R}),Z&&fe==="float"&&f.jsx("div",{className:"session-history-drawer-component",children:f.jsx(U.Popover,{placement:"topRight",showArrow:!1,overlayClassName:"session-history-overlay",overlayStyle:{padding:"4px"},getPopupContainer:F=>F.parentNode,content:"会话历史记录",children:f.jsx(U.Button,{className:"history-overlay-action",disabled:R,type:"text",icon:f.jsx(nt,{type:"icon-lishijilu",style:{fontSize:24}}),onClick:()=>Om(!0)})})}),(w==null?void 0:w.sessionOpen)&&f.jsx(U.Button,{icon:f.jsx(ht.PlusOutlined,{}),className:"add-btn",type:"primary",disabled:Vt||!i||!c.length||R,onClick:()=>{var F,q;is(!1),s==null||s(null),$i.current=null,u(!1),(F=B.current)==null||F.clear(),(q=J.current)==null||q.clear()},children:"新会话"})]})]}),!!lu&&f.jsx("div",{className:"remainingSeconds-mark"})]}),f.jsxs("div",{className:"footer-textarea",onPaste:Um,onPasteCapture:Um,onDrop:Pm,onDropCapture:Pm,onDragOver:Qm,onDragOverCapture:Qm,children:[f.jsx(rL,{ref:De,maxLength:he,text:qe,networkStatus:!1,loading:Sm||rs,disabled:se||ye||R||Sm||rs,onTextSend:Ym,onChange:(F,q)=>{ut(F);const oe=q.getText().replace(/[\n\s]+$/,"");g(oe),zt(oe),re||Ee(!0)},clearAction:f.jsx(U.Space,{size:0,children:f.jsx(U.Button,{type:"link",disabled:Ln||R,ghost:!0,icon:f.jsx(nt,{style:{fontSize:22},type:"icon-qingchujiyi"}),onClick:()=>cx()})})}),!!lu&&f.jsxs("div",{className:"remainingSeconds-time",children:["您之前对话触发敏感词拦截,当前处于禁言状态,暂时无法发送消息,剩余禁言时长",lu]})]})]})}),f.jsx(ZV,{tips:b}),K&&f.jsx(KV,{isvisible:K,files:Ue,sessionId:(ah=i==null?void 0:i.data)==null?void 0:ah.id,onClose:F=>{de(!1),tr(!1)}})]}),vm&&f.jsx(oZ,{currentSession:i,application:n,networkStatus:l,setCurrentSession:s,disabled:R,isSessionHistoryVisible:vm,setIsSessionHistoryVisible:Om,onSessionChange:F=>{is(!0)}})]})});const uL=e=>{const{disabled:t,checkedValues:n,currKnowledgeList:r,selectCount:i,onSelectChange:a}=e,[o,s]=z.useState(!1),l=f.jsx(U.Checkbox.Group,{style:{width:"100%"},onChange:a,value:n,disabled:t,children:f.jsx(U.Row,{gutter:[20,12],children:r==null?void 0:r.map(c=>f.jsx(U.Col,{span:24,children:f.jsx(U.Checkbox,{value:c.id,children:c.name})},c.id))})}),u=c=>{s(c)};return f.jsx("div",{className:"knowledge-select",style:{borderColor:o?"#9C24F2":"#84868C"},children:f.jsx(U.Popover,{className:"select-popover",placement:"bottomRight",title:null,content:l,trigger:"click",overlayStyle:{width:280},onOpenChange:u,getPopupContainer:c=>c.parentNode,children:f.jsxs("div",{className:"",onClick:c=>c.preventDefault(),children:[f.jsx(nt,{className:"select-icon",type:"icon-open"}),f.jsx("span",{className:"title",children:"参考知识库"}),f.jsxs("span",{className:"content",children:["已选 ",i," 个"]})]})})})},mZ=e=>{var T,D;const{currentSession:t,application:n,setCheckKnowledges:r}=e,{mode:i,transform:a,features:o}=z.useContext($t),[s,l]=z.useState([]),[u,c]=z.useState(typeof(o==null?void 0:o.knowledges)=="object"?((T=o.knowledges.default)==null?void 0:T.map(y=>y.id))||[]:[]),[M,d]=z.useState(0),[g,p]=z.useState(!1);z.useEffect(()=>{if(!(n!=null&&n.id))return;const y=n.arrange;if(!(y!=null&&y.length))return;const b=y[0].knowledges||[];l(b);const w=typeof(o==null?void 0:o.knowledges)=="object"&&o.knowledges.default||b;if(Array.isArray(w)&&w.some(C=>Array.isArray(C.fileIds)&&C.fileIds.length===0))throw Error("fileIds cannot be an empty array");if(Nl(w||[])>oi)throw Error(`knowledges and fileIds total count cannot exceed ${oi}`);if(!t){c(w.map(P=>P.id)),d(w.length),r==null||r(w);return}const _=()=>{const P=t.knowledges||w;d(P.length);const C=P.map(S=>S.id);c(C)};return _(),t.addEventListener("data:updated",_),()=>{t==null||t.removeEventListener("data:updated",_)}},[n,t]),z.useEffect(()=>{var I;if(!g||(p(!1),!(n!=null&&n.id)))return;const y=[];u==null||u.map(b=>{const w=s==null?void 0:s.find(A=>A.id===b);y.push(w)}),(I=t==null?void 0:t.data)!=null&&I.id&&t.setKnowledges(y)},[g]);const m=y=>{p(!0),c(y);const I=[];y==null||y.map(b=>{const w=s==null?void 0:s.find(A=>A.id===b);I.push(w)}),r==null||r(I),d(y.length)};return f.jsxs("div",{className:"chat-header",children:[f.jsxs(U.Space,{className:"header-title",children:[i==="inlay"&&((D=t==null?void 0:t.data)==null?void 0:D.name),i==="float"&&(n==null?void 0:n.name)]}),(a==null?void 0:a.knowledges)&&s.length!==0&&f.jsx(uL,{disabled:typeof(o==null?void 0:o.knowledges)=="object"&&(o==null?void 0:o.knowledges.diabled)||!1,checkedValues:u,currKnowledgeList:s,selectCount:M,onSelectChange:m})]})};const hZ=z.forwardRef((e,t)=>{const{sessionId:n,appId:r,docViewerUrl:i}=e,[a,o]=z.useState(),{showHeader:s,agentClient:l,sider:u,onSessionLoad:c,features:M,mode:d}=z.useContext($t),[g,p]=z.useState(),m=z.useRef(null),[T,D]=z.useState(""),[y,I]=z.useState(),b=z.useRef(null),[w,A]=z.useState(!1);z.useState([]);const{setIsSwitchingToExistingSession:_}=am();z.useEffect(()=>{var C;A(a?!!((C=a.data)!=null&&C.netOpen):typeof(M==null?void 0:M.connectNetwork)=="object"&&typeof(M==null?void 0:M.connectNetwork.default)=="boolean"?M.connectNetwork.default:!1)},[a]),z.useEffect(()=>{const C=()=>Be(exports,null,function*(){const S=l==null?void 0:l.application;if(!(S!=null&&S.id))return;const R=S==null?void 0:S.arrange;if(!(R!=null&&R.length))return;const G=R[0].embeddingService;D(G),p(S)});if(l!=null&&l.ready){C();return}return l==null||l.addEventListener("ready",()=>C()),()=>{l==null||l.removeEventListener("ready",C)}},[l]),z.useEffect(()=>{l&&n&&(l.ready?l==null||l.getSessions().then(C=>Be(exports,null,function*(){o==null||o(C.find(S=>S.id===n))})):l.addEventListener("ready",()=>Be(exports,null,function*(){l==null||l.getSessions().then(C=>Be(exports,null,function*(){o==null||o(C.find(S=>S.id===n))}))}),!0))},[l,n]),z.useEffect(()=>{if(!a){c&&c({applicationId:r,sessionId:"",session:null,sessionInstance:null});return}a.data&&c&&c({applicationId:r,sessionId:a.data.id,session:a.data,sessionInstance:a}),a.addEventListener("data:loaded",()=>{a!=null&&a.data&&c&&c({applicationId:r,sessionId:a.data.id,session:a.data,sessionInstance:a})},!0)},[a]);const P=C=>{var S;return(S=m.current)==null?void 0:S.create(xt(ee({},C),{knowledges:y}))};return z.useImperativeHandle(t,()=>({createSession:C=>P(C),getSessionList:()=>{var S;const C=((S=m.current)==null?void 0:S.list())||[];return Promise.resolve(C)},getCurrentInputText:()=>{var C;return(C=b.current)==null?void 0:C.getCurrentInputText()}})),f.jsx("div",{className:"dialog",children:f.jsxs("div",{className:"dialog-pannel",children:[f.jsx("div",{className:"dialog-sider",style:{display:u&&d==="inlay"?"block":"none"},children:f.jsx(om,{ref:m,appId:r,networkStatus:w,currentSession:a,application:g,setCurrentSession:o,checkKnowledges:y,setCheckKnowledges:s?I:void 0,sessionId:n,afterSessionClick:C=>{var S,R;((S=C.data)==null?void 0:S.id)!==((R=a==null?void 0:a.data)==null?void 0:R.id)&&_(!0)}})}),f.jsx("div",{className:"dialog-content",children:f.jsxs("div",{className:"dialog-chat",children:[s&&f.jsx("div",{className:"dialog-chat-header",children:f.jsx(mZ,{setCheckKnowledges:I,application:g,currentSession:a})}),f.jsx("div",{className:"dialog-chat-content",children:(g==null?void 0:g.id)&&f.jsx(fZ,{setNetworkStatus:A,networkStatus:w,application:g,currentSession:a,onCreateSession:P,docViewerUrl:i,embeddingService:T,setCurrentSession:o,ref:b})})]})})]})})}),yZ=z.forwardRef((e,t)=>{const{className:n,triggerButton:r,size:i,theme:a,icon:o,docViewerUrl:s,token:l,debug:u,env:c,plugins:M,mcp:d,footer:g,defaultInput:p,onComment:m,onSessionLoad:T,onSessionUnload:D,onMessage:y,beforeMessageSend:I,bodyStyle:b,apiUrl:w,sessionId:A,disabled:_,transform:P,features:C,stream:S,agentClient:R,application:Y}=e,G=z.useRef(null),[$,Z]=z.useState(!1),[fe,V]=z.useState(),[se,be]=z.useState(i),[x,pe]=z.useState(e.open),he=z.useRef(null);z.useEffect(()=>{Y&&(console.log("[AgentClientUI] token",R,Y),V(Y.id))},[Y]),U.ConfigProvider.config({theme:a}),z.useEffect(()=>{i&&be(i)},[i]);const L=(ie,{element:Ce,size:ze})=>{be({width:Number(ze.width),height:ze.height})};return z.useImperativeHandle(t,()=>({createSession:ie=>{var Ce;return(Ce=he.current)==null?void 0:Ce.createSession(ie)},getSessionList:()=>{var ie;return(ie=he.current)==null?void 0:ie.getSessionList()},getCurrentInputText:()=>{var ie;return(ie=he.current)==null?void 0:ie.getCurrentInputText()}})),f.jsx(U.ConfigProvider,{locale:q1,children:f.jsxs(X1,{value:xt(ee({},e),{popupContainer:G,agentClient:R,footer:g,defaultInput:p,onComment:m,onSessionLoad:T,onSessionUnload:D,onMessage:y,beforeMessageSend:I,bodyStyle:b,disabled:_,transform:P,features:C}),children:[f.jsx(wx.Resizable,{height:(se==null?void 0:se.height)||"100%",width:(se==null?void 0:se.width)||"100%",maxConstraints:[document.body.clientWidth-45],minConstraints:[Number(i==null?void 0:i.minWidth)],onResize:L,handle:f.jsx("span",{className:"resize-handle-ew"}),resizeHandles:n=="float"?["w"]:[],children:f.jsxs("div",{id:"dialog-modal",className:`gbot-dialog-modal ${n} ${x?"opened":"closed"}`,style:xt(ee({},i),{width:n=="float"?se==null?void 0:se.width:i==null?void 0:i.width,height:n==="float"?se==null?void 0:se.height:i==null?void 0:i.height,maxHeight:"100vh"}),ref:G,children:[$?f.jsx("div",{className:"loading",children:f.jsx(U.Spin,{})}):fe&&R?f.jsx(iZ,{children:f.jsx(hZ,{ref:he,appId:fe,docViewerUrl:s,bodyStyle:b,sessionId:A})}):null,(r==null?void 0:r.visible)&&f.jsx(U.Button,{className:"trigger-btn close-btn",icon:f.jsx("img",{src:o}),onClick:()=>pe(!1)})]})}),(r==null?void 0:r.visible)&&!x&&f.jsx(U.Button,{className:`${n}-trigger-btn open-btn`,style:r.style,icon:f.jsx("img",{src:o}),onClick:()=>pe(!0)})]})})}),TZ="@glodon-aiot/agent-cli-ui",IZ="3.19.0-alpha.17",DZ="./dist/es/index.mjs",jZ="./dist/lib/index.js",AZ="./dist/src/index.d.ts",zZ={import:"./dist/es/index.mjs",require:"./dist/lib/index.js",types:"./dist/src/index.d.ts"},bZ=["dist"],wZ="module",EZ="dist/src/index.d.ts",LZ={dev:"vite",start:"vite",build:"tsc && node --max-old-space-size=4096 ./node_modules/vite/bin/vite.js build --mode prod && yarn build:cdn","build:pre":"tsc && node --max-old-space-size=4096 ./node_modules/vite/bin/vite.js build --mode prod","build:cdn":"tsc && vite build --mode prod --config ./vite.config.cdn.ts",preview:"vite preview",check:"yarn prettier --check .",write:"yarn prettier --write .",lint:"eslint --ext .tsx,.ts --fix ./example -c .eslintrc.js",storybook:"start-storybook -p 6006 -s public","build-storybook":"build-storybook -s public",docs:"start-storybook -p 6006",commit:"cz"},xZ={antd:">=4.0.0",react:">=16.9.0","react-dom":">=16.9.0",webpack:"*"},CZ={"@ant-design/icons":"^5.3.4","@glodon-aiot/apis":"^3.19.0-alpha.17","@glodon-aiot/bot-client-sdk":"^3.19.0-alpha.17","@matejmazur/react-mathjax":"^0.1.10","@react-pdf-viewer/core":"^3.12.0","@react-pdf-viewer/default-layout":"^3.12.0","@react-pdf-viewer/locales":"^1.0.0","@react-pdf-viewer/toolbar":"^3.12.0",ahooks:"^3.8.5",axios:"0.24.0",classnames:"^2.5.1","copy-to-clipboard":"^3.3.3",dayjs:"^1.11.13",lodash:"^4.17.21","quill-delta":"^5.1.0","react-infinite-scroll-component":"^6.1.0","react-quill-new":"^3.6.0","react-resizable":"^3.0.5",uuid:"^11.1.0"},SZ={"@babel/core":"^7.20.12","@commitlint/cli":"^17.0.3","@commitlint/config-conventional":"^17.0.3","@rollup/plugin-babel":"^6.0.4","@rollup/plugin-commonjs":"^28.0.0","@rollup/plugin-typescript":"^11.1.6","@storybook/addon-actions":"6.3.6","@storybook/addon-essentials":"6.4.9","@storybook/addon-interactions":"^6.5.16","@storybook/addon-links":"6.3.5","@storybook/addon-postcss":"2.0.0","@storybook/builder-vite":"^0.4.0","@storybook/node-logger":"6.4.9","@storybook/react":"6.4.9","@storybook/testing-library":"^0.0.13","@types/lodash":"^4","@types/react":"^16.9.0 || ^17.0.0 || ^18.0.0","@types/react-dom":"^16.9.0 || ^17.0.0 || ^18.0.0","@typescript-eslint/eslint-plugin":"^5.35.1","@typescript-eslint/parser":"^5.35.1","@vitejs/plugin-react":"^3.1.0",antd:"^4.24.0","babel-loader":"^8.3.0","babel-plugin-import":"^1.13.8",commitizen:"^4.3.0","css-loader":"^6.7.3","cz-conventional-changelog":"^3.3.0","cz-customizable":"^7.0.0",eslint:"^8.0.1","eslint-config-prettier":"^8.5.0","eslint-config-standard-with-typescript":"^22.0.0","eslint-plugin-import":"^2.25.2","eslint-plugin-n":"^15.0.0","eslint-plugin-promise":"^6.0.0","eslint-plugin-react":"^7.31.0","eslint-plugin-storybook":"^0.6.10",husky:">=6",less:"^4.1.2","less-loader":"^11.1.0","lint-staged":">=10","postcss-loader":"^7.2.4",prettier:"2.7.1",react:"^17.0.2","react-dom":"^17.0.2","require-from-string":"^2.0.2","rollup-plugin-visualizer":"^6.0.1","storybook-less-loader":"^0.1.0",typescript:"*",vite:"^4.1.1","vite-plugin-css-injected-by-js":"^3.5.0","vite-plugin-dts":"^4.3.0","vite-plugin-externalize-deps":"^0.9.0"},vZ=[">0.2%","not dead","not op_mini all"],OZ=["last 1 chrome version","last 1 firefox version","last 1 safari version"],kZ={commitizen:{path:"node_modules/cz-customizable"},"cz-customizable":{config:".cz-config.cjs"}},YZ={access:"public",registry:"https://registry.npmjs.org/"},RZ={hooks:{"commit-msg":"validate-commit-msg"}},_Z={name:TZ,version:IZ,module:DZ,main:jZ,typings:AZ,exports:zZ,files:bZ,type:wZ,types:EZ,scripts:LZ,peerDependencies:xZ,dependencies:CZ,devDependencies:SZ,"lint-staged":{"*.{js,css,md,jsx,less,ts,tsx,json}":"prettier --write"},production:vZ,development:OZ,config:kZ,publishConfig:YZ,husky:RZ};var cL=(e=>(e.dev="https://aiot-dev.glodon.com/api/cvforcepd",e.test="https://aiot-dev.glodon.com/api/cvforce",e.prod="https://copilot.glodon.com/api/cvforce",e.local="http://localhost:3000/api/cvforcepd",e))(cL||{});//! moment.js
321
321
  //! version : 2.30.1
322
322
  //! authors : Tim Wood, Iskren Chernev, Moment.js contributors
323
323
  //! license : MIT
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@glodon-aiot/agent-cli-ui",
3
- "version": "3.18.1-alpha.16",
3
+ "version": "3.19.0-alpha.17",
4
4
  "module": "./dist/es/index.mjs",
5
5
  "main": "./dist/lib/index.js",
6
6
  "typings": "./dist/src/index.d.ts",
@@ -37,8 +37,8 @@
37
37
  },
38
38
  "dependencies": {
39
39
  "@ant-design/icons": "^5.3.4",
40
- "@glodon-aiot/apis": "^3.18.1-alpha.16",
41
- "@glodon-aiot/bot-client-sdk": "^3.18.1-alpha.16",
40
+ "@glodon-aiot/apis": "^3.19.0-alpha.17",
41
+ "@glodon-aiot/bot-client-sdk": "^3.19.0-alpha.17",
42
42
  "@matejmazur/react-mathjax": "^0.1.10",
43
43
  "@react-pdf-viewer/core": "^3.12.0",
44
44
  "@react-pdf-viewer/default-layout": "^3.12.0",