@cloud-app-dev/vidc 3.0.3 → 3.0.6
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/.umirc.ts +12 -7
- package/es/DisableMark/index.css +9 -0
- package/es/DisableMark/index.d.ts +8 -0
- package/es/DisableMark/index.js +10 -0
- package/es/Drawer/index.css +1 -0
- package/es/Map/AMap.d.ts +6841 -1308
- package/es/Map/BasicMap/AMapInstance.d.ts +4 -3
- package/es/Map/BasicMap/AMapInstance.js +18 -3
- package/es/Map/BasicMap/LeafletInstance.d.ts +3 -3
- package/es/Map/ClusterLayer/hook.d.ts +4 -4
- package/es/Map/ClusterLayer/hook.js +20 -24
- package/es/Map/ClusterLayer/index.d.ts +1 -0
- package/es/Map/ClusterLayer/index.js +1 -0
- package/es/Map/Config/utils.js +2 -2
- package/es/Map/InfoWindow/MakerLikeWindow.d.ts +4 -0
- package/es/Map/InfoWindow/MakerLikeWindow.js +103 -0
- package/es/Map/InfoWindow/demo.js +48 -21
- package/es/Map/InfoWindow/index.d.ts +7 -5
- package/es/Map/InfoWindow/index.js +7 -6
- package/es/Map/interface.d.ts +1 -1
- package/es/Map/useMarker/index.d.ts +2 -2
- package/es/Map/useMarker/index.js +3 -19
- package/es/Player/api/index.js +0 -1
- package/es/Player/demo.js +4 -3
- package/es/Player/event/errorEvent.js +3 -8
- package/es/Player/iconfont.d.ts +1 -1
- package/es/Player/iconfont.js +1 -1
- package/es/Player/live_heart.js +7 -32
- package/es/Player/single_player.js +6 -1
- package/es/Player/style/iconfont.ttf +0 -0
- package/es/Player/style/iconfont.woff +0 -0
- package/es/Player/style/iconfont.woff2 +0 -0
- package/es/ScreenPlayer/Live.d.ts +1 -1
- package/es/ScreenPlayer/Live.js +22 -4
- package/es/ScreenPlayer/LiveTools.d.ts +5 -1
- package/es/ScreenPlayer/LiveTools.js +87 -43
- package/es/ScreenPlayer/PlayerWithExt.js +29 -4
- package/es/ScreenPlayer/Record.d.ts +1 -1
- package/es/ScreenPlayer/Record.js +27 -8
- package/es/ScreenPlayer/RecordTools.d.ts +5 -1
- package/es/ScreenPlayer/RecordTools.js +103 -46
- package/es/ScreenPlayer/ScreenSelect.d.ts +7 -0
- package/es/ScreenPlayer/ScreenSelect.js +28 -0
- package/es/ScreenPlayer/SegmentTimeLine.d.ts +1 -2
- package/es/ScreenPlayer/SegmentTimeLine.js +9 -6
- package/es/ScreenPlayer/TimeSelect.d.ts +7 -0
- package/es/ScreenPlayer/TimeSelect.js +129 -0
- package/es/ScreenPlayer/demo.d.ts +1 -1
- package/es/ScreenPlayer/demo.js +9 -4
- package/es/ScreenPlayer/demo2.js +1 -1
- package/es/ScreenPlayer/index.css +62 -4
- package/es/ScreenPlayer/interface.d.ts +27 -0
- package/es/Timeout/index.d.ts +8 -9
- package/es/Timeout/index.js +17 -23
- package/es/index.d.ts +1 -0
- package/es/index.js +1 -0
- package/package.json +1 -1
package/es/Timeout/index.js
CHANGED
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
import "antd/lib/modal/style";
|
|
2
|
-
import _Modal from "antd/lib/modal";
|
|
3
1
|
import _useEventListener from "ahooks/es/useEventListener";
|
|
4
2
|
import _useRafInterval from "ahooks/es/useRafInterval";
|
|
5
3
|
|
|
@@ -16,16 +14,15 @@ function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Sy
|
|
|
16
14
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
17
15
|
|
|
18
16
|
import React, { useEffect, useRef, useState } from 'react';
|
|
19
|
-
|
|
20
|
-
import 'antd/es/modal/style/css';
|
|
17
|
+
|
|
21
18
|
/**
|
|
22
|
-
*
|
|
19
|
+
* @desc 用户创建界面超时回调
|
|
23
20
|
*/
|
|
24
|
-
|
|
25
21
|
function Timeout(_ref) {
|
|
26
22
|
var contianer = _ref.contianer,
|
|
27
23
|
time = _ref.time,
|
|
28
|
-
onTimeout = _ref.onTimeout
|
|
24
|
+
onTimeout = _ref.onTimeout,
|
|
25
|
+
ignore = _ref.ignore;
|
|
29
26
|
var cuurentTimeRef = useRef(Date.now());
|
|
30
27
|
var lockstatusRef = useRef(false);
|
|
31
28
|
|
|
@@ -37,15 +34,24 @@ function Timeout(_ref) {
|
|
|
37
34
|
setState = _useState2[1];
|
|
38
35
|
|
|
39
36
|
_useRafInterval(function () {
|
|
40
|
-
|
|
37
|
+
var now = Date.now();
|
|
38
|
+
setState(function (old) {
|
|
41
39
|
return Object.assign(Object.assign({}, old), {
|
|
42
|
-
timelock:
|
|
40
|
+
timelock: now
|
|
43
41
|
});
|
|
44
42
|
});
|
|
43
|
+
var isIgnore = ignore ? ignore() : false;
|
|
44
|
+
|
|
45
|
+
if (isIgnore) {
|
|
46
|
+
// 如果当前需要忽略,那么重置时间
|
|
47
|
+
cuurentTimeRef.current = now;
|
|
48
|
+
}
|
|
45
49
|
}, 1 * 1000);
|
|
46
50
|
|
|
47
51
|
useEffect(function () {
|
|
48
|
-
|
|
52
|
+
var isIgnore = ignore ? ignore() : false;
|
|
53
|
+
|
|
54
|
+
if (!lockstatusRef.current && state.timelock - cuurentTimeRef.current > time * 1000 && !isIgnore) {
|
|
49
55
|
lockstatusRef.current = true;
|
|
50
56
|
onTimeout && onTimeout();
|
|
51
57
|
setTimeout(function () {
|
|
@@ -64,20 +70,8 @@ function Timeout(_ref) {
|
|
|
64
70
|
return /*#__PURE__*/React.createElement(React.Fragment, null);
|
|
65
71
|
}
|
|
66
72
|
|
|
67
|
-
function defaultTimeoutAction() {
|
|
68
|
-
return _Modal.warning({
|
|
69
|
-
title: '系统提示',
|
|
70
|
-
content: /*#__PURE__*/React.createElement("p", null, "\u60A8\u957F\u65F6\u95F4\u672A\u64CD\u4F5C\u7CFB\u7EDF\uFF0C\u8BF7\u91CD\u65B0\u767B\u5F55\uFF01"),
|
|
71
|
-
onOk: function onOk() {
|
|
72
|
-
sessionStorage.clear();
|
|
73
|
-
window.location.replace('/login');
|
|
74
|
-
}
|
|
75
|
-
});
|
|
76
|
-
}
|
|
77
|
-
|
|
78
73
|
Timeout.defaultProps = {
|
|
79
74
|
time: 15 * 60,
|
|
80
|
-
contianer: document.body
|
|
81
|
-
onTimeout: defaultTimeoutAction
|
|
75
|
+
contianer: document.body
|
|
82
76
|
};
|
|
83
77
|
export default Timeout;
|
package/es/index.d.ts
CHANGED
|
@@ -6,6 +6,7 @@ export { default as Box } from './Box';
|
|
|
6
6
|
export { default as CheckGroupFixed } from './CheckGroupFixed';
|
|
7
7
|
export { default as Config } from './Config';
|
|
8
8
|
export { default as ConfigContext } from './ConfigContext';
|
|
9
|
+
export { default as DisableMark } from './DisableMark';
|
|
9
10
|
export { default as DomMove } from './DomMove';
|
|
10
11
|
export { default as Drag } from './Drag';
|
|
11
12
|
export { default as Drawer } from './Drawer';
|
package/es/index.js
CHANGED
|
@@ -6,6 +6,7 @@ export { default as Box } from './Box';
|
|
|
6
6
|
export { default as CheckGroupFixed } from './CheckGroupFixed';
|
|
7
7
|
export { default as Config } from './Config';
|
|
8
8
|
export { default as ConfigContext } from './ConfigContext';
|
|
9
|
+
export { default as DisableMark } from './DisableMark';
|
|
9
10
|
export { default as DomMove } from './DomMove';
|
|
10
11
|
export { default as Drag } from './Drag';
|
|
11
12
|
export { default as Drawer } from './Drawer';
|