bhd-components 0.7.40 → 0.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{bf4a8574.esm.es5.production.js → 2f338078.esm.es5.production.js} +1 -1
- package/dist/{47cd911e.esm.es5.development.js → de88944c.esm.es5.development.js} +1 -1
- package/dist/index.esm.es5.development.css +1011 -1007
- package/dist/index.esm.es5.development.js +136 -40
- package/dist/index.esm.es5.production.css +1 -1
- package/dist/index.esm.es5.production.js +1 -1
- package/dist/vendor.esm.es5.development.esm.es5.development.css +84 -83
- package/dist/vendor.esm.es5.production.esm.es5.production.css +10 -8
- package/es2017/customerService/historyFun.d.ts +1 -1
- package/es2017/customerService/historyFun.js +2 -1
- package/es2017/customerService/html2canvas.test.js +1234 -1233
- package/es2017/customerService/index.d.ts +1 -1
- package/es2017/customerService/index.js +118 -30
- package/es2017/customerService/index.module.less +5 -4
- package/es2017/customerService/index2.module.less +6 -5
- package/es2017/customerService/screenshotTool.js +15 -9
- package/esm/customerService/historyFun.d.ts +1 -1
- package/esm/customerService/historyFun.js +2 -1
- package/esm/customerService/html2canvas.test.js +34 -34
- package/esm/customerService/index.d.ts +1 -1
- package/esm/customerService/index.js +125 -36
- package/esm/customerService/index.module.less +5 -4
- package/esm/customerService/index2.module.less +6 -5
- package/esm/customerService/screenshotTool.js +14 -8
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { z as zhCN, A as App, _ as _object_spread, a as AntdMessage, M as Modal$1, b as AntdNotification, C as ConfigProvider, c as _extends, d as _object_destructuring_empty, j as jsx, e as _object_spread_props, f as jsxs, t as transform, S as StyleProvider, g as _sliced_to_array, T as Tooltip, h as Table$2, I as Icon, E as ExclamationCircleFilled, i as _to_consumable_array, P as Pagination$1, k as Select, l as CaretDownOutlined, m as _inherits, n as _create_super, o as _create_class, p as _class_call_check, q as _define_property, r as _assert_this_initialized, s as _async_to_generator, L as LeftOutlined, R as RightOutlined, u as MinusOutlined, v as PlusOutlined, w as __generator, x as Input, y as SearchOutlined, B as CloseOutlined, X, D as I, H, F as Remarkable, G as Drawer, J as HighlightJS, Z as ZoomInOutlined } from './
|
|
2
|
-
export { K as Affix, N as Alert, O as Anchor, a as AntdMessage, A as App, Q as AutoComplete, U as Avatar, W as BackTop, Y as Badge, $ as Breadcrumb, a0 as Button, a1 as Calendar, a2 as Card, a3 as Carousel, a4 as Cascader, a5 as Checkbox, a6 as Col, a7 as Collapse, a8 as DatePicker, a9 as Descriptions, aa as Divider, G as Drawer, ab as Dropdown, ac as Empty, V as FloatButton, ad as Form, ae as Grid, af as Image, x as Input, ag as InputNumber, ah as Layout, ai as List, aj as Mentions, ak as Menu, M as Modal, al as Popconfirm, am as Popover, an as Progress, aM as QRCode, ao as Radio, ap as Rate, aq as Result, ar as Row, as as Segmented, k as Select, at as Skeleton, au as Slider, av as Space, aw as Spin, ax as Statistic, ay as Steps, az as Switch, aA as Tabs, aB as Tag, aD as TimePicker, aE as Timeline, T as Tooltip, aF as Tour, aG as Transfer, aH as Tree, aI as TreeSelect, aJ as Typography, aK as Upload, aL as Watermark, aO as en_US, b as notification, aC as theme, aN as version, z as zh_CN } from './
|
|
1
|
+
import { z as zhCN, A as App, _ as _object_spread, a as AntdMessage, M as Modal$1, b as AntdNotification, C as ConfigProvider, c as _extends, d as _object_destructuring_empty, j as jsx, e as _object_spread_props, f as jsxs, t as transform, S as StyleProvider, g as _sliced_to_array, T as Tooltip, h as Table$2, I as Icon, E as ExclamationCircleFilled, i as _to_consumable_array, P as Pagination$1, k as Select, l as CaretDownOutlined, m as _inherits, n as _create_super, o as _create_class, p as _class_call_check, q as _define_property, r as _assert_this_initialized, s as _async_to_generator, L as LeftOutlined, R as RightOutlined, u as MinusOutlined, v as PlusOutlined, w as __generator, x as Input, y as SearchOutlined, B as CloseOutlined, X, D as I, H, F as Remarkable, G as Drawer, J as HighlightJS, Z as ZoomInOutlined } from './de88944c.esm.es5.development.js';
|
|
2
|
+
export { K as Affix, N as Alert, O as Anchor, a as AntdMessage, A as App, Q as AutoComplete, U as Avatar, W as BackTop, Y as Badge, $ as Breadcrumb, a0 as Button, a1 as Calendar, a2 as Card, a3 as Carousel, a4 as Cascader, a5 as Checkbox, a6 as Col, a7 as Collapse, a8 as DatePicker, a9 as Descriptions, aa as Divider, G as Drawer, ab as Dropdown, ac as Empty, V as FloatButton, ad as Form, ae as Grid, af as Image, x as Input, ag as InputNumber, ah as Layout, ai as List, aj as Mentions, ak as Menu, M as Modal, al as Popconfirm, am as Popover, an as Progress, aM as QRCode, ao as Radio, ap as Rate, aq as Result, ar as Row, as as Segmented, k as Select, at as Skeleton, au as Slider, av as Space, aw as Spin, ax as Statistic, ay as Steps, az as Switch, aA as Tabs, aB as Tag, aD as TimePicker, aE as Timeline, T as Tooltip, aF as Tour, aG as Transfer, aH as Tree, aI as TreeSelect, aJ as Typography, aK as Upload, aL as Watermark, aO as en_US, b as notification, aC as theme, aN as version, z as zh_CN } from './de88944c.esm.es5.development.js';
|
|
3
3
|
import * as React from 'react';
|
|
4
4
|
import { useState, useRef, useEffect, useLayoutEffect, forwardRef, useImperativeHandle } from 'react';
|
|
5
5
|
import { Fragment } from 'react/jsx-runtime';
|
|
@@ -2473,7 +2473,7 @@ function BhdAppLayout(props) {
|
|
|
2473
2473
|
});
|
|
2474
2474
|
}
|
|
2475
2475
|
|
|
2476
|
-
var modules_63b47c51 = {"service_ChatWindow_Drawer":"
|
|
2476
|
+
var modules_63b47c51 = {"service_ChatWindow_Drawer":"index_module_service_ChatWindow_Drawer__bf3246f1","ChatWindow_Modal":"index_module_ChatWindow_Modal__bf3246f1","ChatWindow_Drawer":"index_module_ChatWindow_Drawer__bf3246f1","header_wrap":"index_module_header_wrap__bf3246f1","top":"index_module_top__bf3246f1","user":"index_module_user__bf3246f1","count":"index_module_count__bf3246f1","operate":"index_module_operate__bf3246f1","line":"index_module_line__bf3246f1","popover_main":"index_module_popover_main__bf3246f1","popover":"index_module_popover__bf3246f1","header_wrap_newlabo":"index_module_header_wrap_newlabo__bf3246f1","Drawer_main":"index_module_Drawer_main__bf3246f1","loading":"index_module_loading__bf3246f1","message_con":"index_module_message_con__bf3246f1","left":"index_module_left__bf3246f1","head_sculpture":"index_module_head_sculpture__bf3246f1","main_content":"index_module_main_content__bf3246f1","right":"index_module_right__bf3246f1","main":"index_module_main__bf3246f1","main_content_flag":"index_module_main_content_flag__bf3246f1","operate_modal":"index_module_operate_modal__bf3246f1","operate_modal_bottom":"index_module_operate_modal_bottom__bf3246f1","active":"index_module_active__bf3246f1","stop_generate":"index_module_stop_generate__bf3246f1","icon":"index_module_icon__bf3246f1","find_teacher":"index_module_find_teacher__bf3246f1","stop_findTeacher":"index_module_stop_findTeacher__bf3246f1","content":"index_module_content__bf3246f1","content_child":"index_module_content_child__bf3246f1","find_teacher_con":"index_module_find_teacher_con__bf3246f1","sign":"index_module_sign__bf3246f1","ask_question":"index_module_ask_question__bf3246f1","association_problem":"index_module_association_problem__bf3246f1","association_problem_flag":"index_module_association_problem_flag__bf3246f1","related_issues_flag":"index_module_related_issues_flag__bf3246f1","img_con":"index_module_img_con__bf3246f1","mask_zoom":"index_module_mask_zoom__bf3246f1","img_con2":"index_module_img_con2__bf3246f1","copyCode":"index_module_copyCode__bf3246f1","time":"index_module_time__bf3246f1","citation_content":"index_module_citation_content__bf3246f1","text_exceed":"index_module_text_exceed__bf3246f1","popover_content":"index_module_popover_content__bf3246f1","Drawer_main_newlabo":"index_module_Drawer_main_newlabo__bf3246f1","Drawer_main_newlabo_no_pic":"index_module_Drawer_main_newlabo_no_pic__bf3246f1","Drawer_buttom_Issues_List":"index_module_Drawer_buttom_Issues_List__bf3246f1","issues_list_teacherList":"index_module_issues_list_teacherList__bf3246f1","item":"index_module_item__bf3246f1","issues_list":"index_module_issues_list__bf3246f1","issues_list_flag":"index_module_issues_list_flag__bf3246f1","Drawer_buttom":"index_module_Drawer_buttom__bf3246f1","input_wrap":"index_module_input_wrap__bf3246f1","input":"index_module_input__bf3246f1","picture_layout":"index_module_picture_layout__bf3246f1","icon_close":"index_module_icon_close__bf3246f1","icon_zoom":"index_module_icon_zoom__bf3246f1","anticon":"index_module_anticon__bf3246f1","no_AI":"index_module_no_AI__bf3246f1","screenshot":"index_module_screenshot__bf3246f1","disabled":"index_module_disabled__bf3246f1","content_main":"index_module_content_main__bf3246f1","content_con":"index_module_content_con__bf3246f1","delete_quote":"index_module_delete_quote__bf3246f1","sending":"index_module_sending__bf3246f1","Drawer_buttom_Issues_List_newlabo":"index_module_Drawer_buttom_Issues_List_newlabo__bf3246f1","main_list":"index_module_main_list__bf3246f1","chat_content":"index_module_chat_content__bf3246f1","popover_main_content":"index_module_popover_main_content__bf3246f1","popover_main_content_name":"index_module_popover_main_content_name__bf3246f1","teacher_layout":"index_module_teacher_layout__bf3246f1","bottom":"index_module_bottom__bf3246f1","delete":"index_module_delete__bf3246f1","num":"index_module_num__bf3246f1","shrink":"index_module_shrink__bf3246f1","teacher_layout_newlabo":"index_module_teacher_layout_newlabo__bf3246f1","teacher_layout_modal":"index_module_teacher_layout_modal__bf3246f1","ai":"index_module_ai__bf3246f1","user_info":"index_module_user_info__bf3246f1","message":"index_module_message__bf3246f1","con":"index_module_con__bf3246f1","teacher_layout_modal_newlabo":"index_module_teacher_layout_modal_newlabo__bf3246f1","history_list":"index_module_history_list__bf3246f1","search_layout":"index_module_search_layout__bf3246f1","mymove":"index_module_mymove__bf3246f1","title":"index_module_title__bf3246f1","search_top":"index_module_search_top__bf3246f1","list_item":"index_module_list_item__bf3246f1","list_summary":"index_module_list_summary__bf3246f1","head_img":"index_module_head_img__bf3246f1","list_desc":"index_module_list_desc__bf3246f1","name":"index_module_name__bf3246f1","decs":"index_module_decs__bf3246f1","open":"index_module_open__bf3246f1","list_summary_active":"index_module_list_summary_active__bf3246f1","list_detail":"index_module_list_detail__bf3246f1","list":"index_module_list__bf3246f1","list_more":"index_module_list_more__bf3246f1","no_data":"index_module_no_data__bf3246f1","history_list_broadside":"index_module_history_list_broadside__bf3246f1","teacher_list":"index_module_teacher_list__bf3246f1","screenshot_Modal":"index_module_screenshot_Modal__bf3246f1","ReactCrop":"index_module_ReactCrop__bf3246f1","screenshot_Modal_btn":"index_module_screenshot_Modal_btn__bf3246f1"};
|
|
2477
2477
|
|
|
2478
2478
|
//消息已读
|
|
2479
2479
|
var readMessage = function(roomId, urllocation, userData, http) {
|
|
@@ -3304,11 +3304,13 @@ var ScreenshotTool = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
|
3304
3304
|
var _useState = _sliced_to_array(useState(), 2), crop = _useState[0], setCrop = _useState[1];
|
|
3305
3305
|
var _useState1 = _sliced_to_array(useState(), 2), completedCrop = _useState1[0], setCompletedCrop = _useState1[1];
|
|
3306
3306
|
var _useState2 = _sliced_to_array(useState(16 / 9), 2), aspect = _useState2[0]; _useState2[1];
|
|
3307
|
-
var _useState3 = _sliced_to_array(useState(
|
|
3307
|
+
var _useState3 = _sliced_to_array(useState(window.devicePixelRatio), 2), devicePixelRatio = _useState3[0]; _useState3[1];
|
|
3308
|
+
var _useState4 = _sliced_to_array(useState(true), 2), isFirst = _useState4[0], setIsFirst = _useState4[1];
|
|
3309
|
+
var _useState5 = _sliced_to_array(useState({
|
|
3308
3310
|
top: 0,
|
|
3309
3311
|
left: 0
|
|
3310
|
-
}), 2), btnPosition =
|
|
3311
|
-
var
|
|
3312
|
+
}), 2), btnPosition = _useState5[0], setBtnPosition = _useState5[1];
|
|
3313
|
+
var _useState6 = _sliced_to_array(useState(false), 2), showBtn = _useState6[0], setShowBtn = _useState6[1];
|
|
3312
3314
|
function centerAspectCrop(mediaWidth, mediaHeight, aspect) {
|
|
3313
3315
|
return I(H({
|
|
3314
3316
|
unit: "%",
|
|
@@ -3336,10 +3338,10 @@ var ScreenshotTool = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
|
3336
3338
|
image.src = imgBese64; // 将'your_image_url'替换为你自己的图片URL
|
|
3337
3339
|
// 等待图片加载完成后再进行操作
|
|
3338
3340
|
image.onload = function() {
|
|
3339
|
-
var x = completedCrop.x; // 起始点x坐标
|
|
3340
|
-
var y = completedCrop.y; // 起始点y坐标
|
|
3341
|
-
var width = completedCrop.width; // 需要裁剪的区域宽度
|
|
3342
|
-
var height = completedCrop.height; // 需要裁剪的区域高度
|
|
3341
|
+
var x = parseInt((completedCrop.x * devicePixelRatio).toString()); // 起始点x坐标
|
|
3342
|
+
var y = parseInt((completedCrop.y * devicePixelRatio).toString()); // 起始点y坐标
|
|
3343
|
+
var width = parseInt((completedCrop.width * devicePixelRatio).toString()); // 需要裁剪的区域宽度
|
|
3344
|
+
var height = parseInt((completedCrop.height * devicePixelRatio).toString()); // 需要裁剪的区域高度
|
|
3343
3345
|
// 设置canvas大小与裁剪区域相同
|
|
3344
3346
|
canvas.width = width;
|
|
3345
3347
|
canvas.height = height;
|
|
@@ -3360,7 +3362,7 @@ var ScreenshotTool = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
|
3360
3362
|
var y = e.y;
|
|
3361
3363
|
var h = e.height;
|
|
3362
3364
|
var w = e.width;
|
|
3363
|
-
var top = y + h + 8;
|
|
3365
|
+
var top = y + h + (isFirst ? 21 : 8);
|
|
3364
3366
|
var left = x + w - 88;
|
|
3365
3367
|
if (top + 42 > window.innerHeight) {
|
|
3366
3368
|
top = top - 50;
|
|
@@ -3370,6 +3372,7 @@ var ScreenshotTool = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
|
3370
3372
|
left: left
|
|
3371
3373
|
});
|
|
3372
3374
|
setShowBtn(true);
|
|
3375
|
+
setIsFirst(false);
|
|
3373
3376
|
};
|
|
3374
3377
|
return /*#__PURE__*/ jsxs("div", {
|
|
3375
3378
|
className: modules_63b47c51.screenshot_Modal,
|
|
@@ -3395,6 +3398,9 @@ var ScreenshotTool = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
|
3395
3398
|
minWidth: 100,
|
|
3396
3399
|
children: /*#__PURE__*/ jsx("img", {
|
|
3397
3400
|
alt: "Crop me",
|
|
3401
|
+
style: {
|
|
3402
|
+
display: "none"
|
|
3403
|
+
},
|
|
3398
3404
|
src: imgBese64,
|
|
3399
3405
|
onLoad: onImageLoad
|
|
3400
3406
|
})
|
|
@@ -3724,7 +3730,7 @@ var img = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAA
|
|
|
3724
3730
|
var styles = modules_63b47c51;
|
|
3725
3731
|
var TextArea = Input.TextArea;
|
|
3726
3732
|
var CustomerService = function(props) {
|
|
3727
|
-
var userData = props.userData, http = props.http, urllocation = props.urllocation, onCancel = props.onCancel, serverName = props.serverName, fetchEventSource = props.fetchEventSource, initShowType = props.initShowType, onEvent = props.onEvent, stepIds = props.stepIds, stepId = props.stepId
|
|
3733
|
+
var userData = props.userData, http = props.http, urllocation = props.urllocation, onCancel = props.onCancel, serverName = props.serverName, fetchEventSource = props.fetchEventSource, initShowType = props.initShowType, onEvent = props.onEvent, stepIds = props.stepIds, stepId = props.stepId; props.screenshotAreaId; var config = props.config;
|
|
3728
3734
|
// const { bese64String, startRecord, stopRecord } = useMediaRecorder(); //语音转文字
|
|
3729
3735
|
// const [voiceRecordingStatus, setVoiceRecordingStatus] = useState(3); //语音录制状态 3,语音识别完成 2,录制中, 1,录制结束
|
|
3730
3736
|
var _useState = _sliced_to_array(useState([]), 2), copyTextOBJ = _useState[0], setCopyTextObj = _useState[1]; //复制的消息id
|
|
@@ -3801,33 +3807,118 @@ var CustomerService = function(props) {
|
|
|
3801
3807
|
initShowType
|
|
3802
3808
|
]);
|
|
3803
3809
|
useEffect(function() {
|
|
3804
|
-
|
|
3805
|
-
|
|
3810
|
+
function handlerHtml2canvas() {
|
|
3811
|
+
console.log("kkkkkkkkkkk");
|
|
3806
3812
|
try {
|
|
3807
3813
|
newShowType.current = true;
|
|
3808
3814
|
setImgBese64("");
|
|
3809
|
-
|
|
3810
|
-
|
|
3811
|
-
|
|
3812
|
-
|
|
3813
|
-
|
|
3814
|
-
|
|
3815
|
-
|
|
3816
|
-
|
|
3817
|
-
|
|
3815
|
+
var plugin = new screenShotPlugin({
|
|
3816
|
+
clickCutFullScreen: true,
|
|
3817
|
+
enableWebRtc: true,
|
|
3818
|
+
loadCrossImg: true,
|
|
3819
|
+
canvasWidth: window.innerWidth,
|
|
3820
|
+
canvasHeight: window.innerHeight,
|
|
3821
|
+
level: -1,
|
|
3822
|
+
hiddenToolIco: true,
|
|
3823
|
+
screenShotDom: document.body,
|
|
3824
|
+
cropBoxInfo: {
|
|
3825
|
+
x: 0,
|
|
3826
|
+
y: 0,
|
|
3827
|
+
w: window.innerWidth,
|
|
3828
|
+
h: window.innerHeight
|
|
3829
|
+
},
|
|
3830
|
+
wrcReplyTime: 20,
|
|
3831
|
+
wrcWindowMode: true,
|
|
3832
|
+
hiddenScrollBar: {
|
|
3833
|
+
state: true
|
|
3834
|
+
},
|
|
3835
|
+
completeCallback: function(param) {
|
|
3836
|
+
var base64 = param.base64;
|
|
3837
|
+
// console.log(
|
|
3838
|
+
// "截图组件加载完毕调用此方法来完成框选区域的截图",
|
|
3839
|
+
// base64
|
|
3840
|
+
// );
|
|
3841
|
+
setImgBese64(base64);
|
|
3842
|
+
},
|
|
3843
|
+
triggerCallback: function() {
|
|
3844
|
+
// 截图组件加载完毕调用此方法来完成框选区域的截图
|
|
3845
|
+
plugin.completeScreenshot();
|
|
3846
|
+
},
|
|
3847
|
+
cancelCallback: function(err) {
|
|
3848
|
+
if (err.code === -1) {
|
|
3849
|
+
console.log(err);
|
|
3850
|
+
newShowType.current = false;
|
|
3851
|
+
if (saveShowType != -1) {
|
|
3852
|
+
setShowType(saveShowType);
|
|
3853
|
+
} else {
|
|
3854
|
+
setShowType(1);
|
|
3855
|
+
}
|
|
3856
|
+
setShowScreenshot(false);
|
|
3857
|
+
onCancel();
|
|
3858
|
+
}
|
|
3818
3859
|
}
|
|
3819
|
-
}).then(function(canvas) {
|
|
3820
|
-
// document.body.appendChild(canvas);
|
|
3821
|
-
console.log(canvas, 99999);
|
|
3822
|
-
// var base64URL = canvas.toDataURL('image/jpeg')
|
|
3823
|
-
var base64URL = canvas.toDataURL("image/jpg", 1.0);
|
|
3824
|
-
console.log(base64URL);
|
|
3825
|
-
setImgBese64(base64URL);
|
|
3826
3860
|
});
|
|
3861
|
+
// modernScreenshot
|
|
3862
|
+
// .domToPng(document.querySelector("body"))
|
|
3863
|
+
// .then((dataUrl:any) => {
|
|
3864
|
+
// console.log(dataUrl);
|
|
3865
|
+
// setImgBese64(dataUrl);
|
|
3866
|
+
// });
|
|
3867
|
+
// domtoimage
|
|
3868
|
+
// .toPng(document.body)
|
|
3869
|
+
// .then(function (dataUrl:any) {
|
|
3870
|
+
// setImgBese64(dataUrl);
|
|
3871
|
+
// })
|
|
3872
|
+
// .catch(function (error:any) {
|
|
3873
|
+
// console.error("oops, something went wrong!", error);
|
|
3874
|
+
// });
|
|
3875
|
+
// //排除
|
|
3876
|
+
// new screenShotPlugin({
|
|
3877
|
+
// enableWebRtc: true,
|
|
3878
|
+
// canvasWidth:window.innerWidth,
|
|
3879
|
+
// canvasHeight:window.innerHeight,
|
|
3880
|
+
// level:9999999,
|
|
3881
|
+
// completeCallback: function (info:any) {
|
|
3882
|
+
// console.log(info);
|
|
3883
|
+
// setImgBese64(info.base64);
|
|
3884
|
+
// },
|
|
3885
|
+
// closeCallback: function () {
|
|
3886
|
+
// },
|
|
3887
|
+
// });
|
|
3888
|
+
// html2canvas(document.body,{//__docusaurus
|
|
3889
|
+
// useCORS: true, // 支持跨域图片截图
|
|
3890
|
+
// allowTaint: true, // 污染处理
|
|
3891
|
+
// scale: 1 ,// 图片比例
|
|
3892
|
+
// logging:false,
|
|
3893
|
+
// // foreignObjectRendering:true,
|
|
3894
|
+
// ignoreElements:(element: { compareDocumentPosition: (arg0: string) => number; })=>{
|
|
3895
|
+
// if(element.compareDocumentPosition(screenshotAreaId)===2)return true
|
|
3896
|
+
// return false
|
|
3897
|
+
// },
|
|
3898
|
+
// windowWidth:window.innerWidth,
|
|
3899
|
+
// windowHeight:window.innerHeight
|
|
3900
|
+
// })
|
|
3901
|
+
// .then(function (canvas:any) {
|
|
3902
|
+
// // document.body.appendChild(canvas);
|
|
3903
|
+
// // console.log(canvas,99999);
|
|
3904
|
+
// // var base64URL = canvas.toDataURL('image/jpeg')
|
|
3905
|
+
// let base64URL = canvas.toDataURL("image/jpg", 1.0)
|
|
3906
|
+
// // console.log(base64URL);
|
|
3907
|
+
// setImgBese64(base64URL);
|
|
3908
|
+
// // svgNodesToRemove.forEach(item=>{
|
|
3909
|
+
// // item.remove()
|
|
3910
|
+
// // })
|
|
3911
|
+
// });
|
|
3827
3912
|
} catch (error) {
|
|
3828
3913
|
console.log(error);
|
|
3829
3914
|
}
|
|
3830
3915
|
}
|
|
3916
|
+
//|| showScreenshot
|
|
3917
|
+
if (showType == 5 || showScreenshot) {
|
|
3918
|
+
console.log("bbbbbbbbbbbbbb");
|
|
3919
|
+
handlerHtml2canvas();
|
|
3920
|
+
// window.addEventListener('resize',handlerHtml2canvas)
|
|
3921
|
+
}
|
|
3831
3922
|
if (showType != 1 && !firstLoad && pageCount > 0) {
|
|
3832
3923
|
setFirstLoad(true);
|
|
3833
3924
|
scrollToBottom();
|
|
@@ -3887,6 +3978,7 @@ var CustomerService = function(props) {
|
|
|
3887
3978
|
if (content) {
|
|
3888
3979
|
content.removeEventListener("scroll", handleScroll);
|
|
3889
3980
|
}
|
|
3981
|
+
window.removeEventListener("resize", handlerHtml2canvas);
|
|
3890
3982
|
};
|
|
3891
3983
|
}, [
|
|
3892
3984
|
historyMessageList,
|
|
@@ -5413,11 +5505,18 @@ var CustomerService = function(props) {
|
|
|
5413
5505
|
/*#__PURE__*/ jsxs("div", {
|
|
5414
5506
|
className: styles.operate,
|
|
5415
5507
|
children: [
|
|
5416
|
-
/*#__PURE__*/
|
|
5508
|
+
/*#__PURE__*/ jsxs("i", {
|
|
5509
|
+
className: styles.popover_main,
|
|
5417
5510
|
onClick: function() {
|
|
5418
5511
|
setShowHistory(true);
|
|
5419
5512
|
},
|
|
5420
|
-
children:
|
|
5513
|
+
children: [
|
|
5514
|
+
/*#__PURE__*/ jsx(CustomRecord$1, {}),
|
|
5515
|
+
/*#__PURE__*/ jsx("span", {
|
|
5516
|
+
className: styles.popover,
|
|
5517
|
+
children: "历史记录"
|
|
5518
|
+
})
|
|
5519
|
+
]
|
|
5421
5520
|
}),
|
|
5422
5521
|
/*#__PURE__*/ jsx("span", {
|
|
5423
5522
|
className: styles.line
|
|
@@ -5437,20 +5536,14 @@ var CustomerService = function(props) {
|
|
|
5437
5536
|
})
|
|
5438
5537
|
]
|
|
5439
5538
|
}),
|
|
5440
|
-
/*#__PURE__*/
|
|
5539
|
+
/*#__PURE__*/ jsx("i", {
|
|
5441
5540
|
className: styles.popover_main,
|
|
5442
5541
|
onClick: function() {
|
|
5443
5542
|
onEvent(serverName + serverUrl(), "click_智能问答_退出全屏", "提交");
|
|
5444
5543
|
setShowType(3);
|
|
5445
5544
|
setFirstLoad(false); //重启滚动条在最上方
|
|
5446
5545
|
},
|
|
5447
|
-
children:
|
|
5448
|
-
/*#__PURE__*/ jsx(CloseOutlined, {}),
|
|
5449
|
-
/*#__PURE__*/ jsx("span", {
|
|
5450
|
-
className: styles.popover,
|
|
5451
|
-
children: "退出全屏"
|
|
5452
|
-
})
|
|
5453
|
-
]
|
|
5546
|
+
children: /*#__PURE__*/ jsx(CloseOutlined, {})
|
|
5454
5547
|
})
|
|
5455
5548
|
]
|
|
5456
5549
|
})
|
|
@@ -7138,6 +7231,9 @@ var CustomerService = function(props) {
|
|
|
7138
7231
|
}),
|
|
7139
7232
|
(showType == 4 || showType == 5) && /*#__PURE__*/ jsxs("div", {
|
|
7140
7233
|
className: "".concat(styles.ChatWindow_Drawer),
|
|
7234
|
+
style: {
|
|
7235
|
+
display: "".concat(!showScreenshot ? "none" : "flex")
|
|
7236
|
+
},
|
|
7141
7237
|
id: "",
|
|
7142
7238
|
children: [
|
|
7143
7239
|
/*#__PURE__*/ jsx("div", {
|