@dfsj/components 3.7.1 → 3.7.2-alpha.2
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/components/Boards/src/Boards.vue.d.ts +11 -0
- package/dist/components/Boards/src/Boards.vue2.js +27 -31
- package/dist/components/Boards/src/hooKs/useStyle.js +5 -5
- package/dist/components/Boards/src/props.d.ts +5 -0
- package/dist/components/Boards/src/props.js +2 -1
- package/dist/components/ClickOutSide/src/ClickOutSide.vue2.js +1 -1
- package/dist/components/{src/components/Descriptions → Descriptions}/src/Descriptions.vue.d.ts +12 -12
- package/dist/components/Descriptions/src/Descriptions.vue2.js +4 -4
- package/dist/components/Editor/src/Editor.vue.d.ts +4 -4
- package/dist/components/Editor/src/Editor.vue2.js +5 -5
- package/dist/components/Form/src/Form.vue.d.ts +481 -447
- package/dist/components/Form/src/Form.vue2.js +30 -24
- package/dist/components/Form/src/components/useRenderCheckbox.js +8 -8
- package/dist/components/Form/src/components/useRenderRadio.js +8 -8
- package/dist/components/Form/src/components/useRenderSelect.js +11 -11
- package/dist/components/Form/src/helper/componentMap.js +0 -2
- package/dist/components/Form/src/helper/index.js +7 -7
- package/dist/components/Form/src/types/index.d.ts +2 -2
- package/dist/components/Form/src/useForm.js +63 -63
- package/dist/components/Highlight/src/Highlight.vue.d.ts +4 -4
- package/dist/components/Highlight/src/Highlight.vue2.js +3 -3
- package/dist/components/Icon/src/Icon.vue.d.ts +8 -8
- package/dist/components/Icon/src/Icon.vue2.js +11 -11
- package/dist/components/{src/components/InputPassword → InputPassword}/src/InputPassword.vue.d.ts +4 -4
- package/dist/components/Modal/src/BasicModal.vue.d.ts +68 -15
- package/dist/components/Modal/src/BasicModal.vue2.js +20 -17
- package/dist/components/{src/components/Modal → Modal}/src/components/ModalFooter.vue.d.ts +4 -4
- package/dist/components/Modal/src/components/ModalFooter.vue2.js +17 -7
- package/dist/components/{src/components/Modal → Modal}/src/components/ModalHeader.vue.d.ts +63 -10
- package/dist/components/Modal/src/components/ModalHeader.vue2.js +3 -3
- package/dist/components/Modal/src/config.js +2 -2
- package/dist/components/Modal/src/hooks/useModalDrag.js +9 -2
- package/dist/components/Modal/src/hooks/useTimeout.js +1 -1
- package/dist/components/{src/components/Modal → Modal}/src/props.d.ts +31 -7
- package/dist/components/Modal/src/props.js +9 -1
- package/dist/components/Modal/src/utils/index.js +1 -1
- package/dist/components/NodeAxis/src/CanvasNodeRender.js +35 -35
- package/dist/components/NodeAxis/src/NodeAxis.vue2.js +1 -1
- package/dist/components/NodeAxis/src/NodeModel.js +10 -10
- package/dist/components/NodeAxis/src/NodeRender.js +3 -3
- package/dist/components/NodeAxis/src/TimerNodePlayer.js +4 -4
- package/dist/components/Stateful/src/Stateful.vue.d.ts +2 -2
- package/dist/components/Stateful/src/Stateful.vue2.js +6 -6
- package/dist/components/Stateful/src/props.d.ts +1 -1
- package/dist/components/Table/src/Table.vue.d.ts +732 -645
- package/dist/components/Table/src/Table.vue2.js +10 -10
- package/dist/components/Table/src/components/ColumnSetting.vue2.js +20 -20
- package/dist/components/Table/src/components/TableActions.vue.d.ts +229 -0
- package/dist/components/Table/src/components/TableActions.vue2.js +1 -1
- package/dist/components/Table/src/useTable.js +50 -50
- package/dist/components/UnifyChart/src/ChartToolbox.vue.d.ts +8 -8
- package/dist/components/UnifyChart/src/ChartToolbox.vue2.js +2 -2
- package/dist/components/UnifyChart/src/UnifyChart.vue.d.ts +16 -16
- package/dist/components/UnifyChart/src/UnifyChart.vue2.js +2 -2
- package/dist/components/UnifyChart/src/hooks/useLoader.js +19 -19
- package/dist/components/UnifyChart/src/hooks/useRender.js +3 -3
- package/dist/components/UnifyChart/src/props.d.ts +13 -13
- package/dist/components/UnifyChart/src/useDownLoad.d.ts +9 -0
- package/dist/components/UnifyChart/src/useDownLoad.js +27 -0
- package/dist/components/Video/src/VideoPlayer.vue.d.ts +14 -14
- package/dist/components/Video/src/VideoPlayer.vue2.js +5 -5
- package/dist/components/{src/components/Video → Video}/src/VideoPlayerToolbar.vue.d.ts +12 -12
- package/dist/components/Video/src/VideoPlayerToolbar.vue2.js +4 -4
- package/dist/components/Video/src/abstract/VideoControl.js +13 -13
- package/dist/components/Video/src/control/DaHua.js +8 -8
- package/dist/components/Video/src/control/Hikvision.js +12 -12
- package/dist/components/Visual/src/BufferLayerPlayer.js +65 -68
- package/dist/components/Visual/src/ResolvableLayerProvider.js +5 -5
- package/dist/components/Visual/src/resolvers/IntervalResolver.js +9 -9
- package/dist/components/Visual/src/resolvers/tools.resolver.js +8 -1
- package/dist/components/Visual/src/utils/NodeMath.js +1 -1
- package/dist/components/Windows/src/ModalWrap.vue2.js +52 -8
- package/dist/components/Windows/src/Windows.vue2.js +3 -3
- package/dist/components/Windows/src/props.d.ts +8 -3
- package/dist/directives/clickOutside.js +3 -3
- package/dist/directives/repeatClick.js +1 -1
- package/dist/directives/resizable.js +4 -4
- package/dist/index.d.ts +0 -1
- package/dist/index.js +0 -1
- package/dist/index.min.css +3 -3
- package/dist/node_modules/.pnpm/{@vueuse_core@10.11.1_vue@3.5.13_typescript@5.7.3_ → @vueuse_core@13.7.0_vue@3.5.19_typescript@5.9.2_}/node_modules/@vueuse/core/index.js +151 -93
- package/dist/node_modules/.pnpm/@vueuse_shared@13.7.0_vue@3.5.19_typescript@5.9.2_/node_modules/@vueuse/shared/index.js +53 -0
- package/package.json +66 -66
- package/dist/components/DatePicker/index.d.ts +0 -2
- package/dist/components/DatePicker/src/composables/use-month-range-header.js +0 -52
- package/dist/components/DatePicker/src/composables/use-range-picker.js +0 -99
- package/dist/components/DatePicker/src/date-picker-com/panel-date-range.vue.js +0 -5
- package/dist/components/DatePicker/src/date-picker-com/panel-date-range.vue2.js +0 -564
- package/dist/components/DatePicker/src/date-picker-com/panel-month-range.vue.js +0 -5
- package/dist/components/DatePicker/src/date-picker-com/panel-month-range.vue2.js +0 -210
- package/dist/components/DatePicker/src/index.d.ts +0 -218
- package/dist/components/DatePicker/src/index.js +0 -87
- package/dist/components/DatePicker/src/panel-utils.d.ts +0 -2
- package/dist/components/DatePicker/src/panel-utils.js +0 -25
- package/dist/components/src/components/ClickOutSide/src/ClickOutSide.vue.d.ts +0 -7
- package/dist/components/src/components/DatePicker/src/composables/use-month-range-header.d.ts +0 -16
- package/dist/components/src/components/DatePicker/src/composables/use-range-picker.d.ts +0 -173
- package/dist/components/src/components/DatePicker/src/date-picker-com/panel-date-range.vue.d.ts +0 -19
- package/dist/components/src/components/DatePicker/src/date-picker-com/panel-month-range.vue.d.ts +0 -16
- package/dist/components/src/components/Highlight/src/Highlight.vue.d.ts +0 -41
- package/dist/components/src/components/NodeAxis/src/BCanvasNodeRender.d.ts +0 -19
- package/dist/components/src/components/NodeAxis/src/NodeAxis.d.ts +0 -12
- package/dist/components/src/components/Table/src/components/TableActions.vue.d.ts +0 -96
- package/dist/components/src/themes/index.d.ts +0 -1
- package/dist/node_modules/.pnpm/@vueuse_shared@10.11.1_vue@3.5.13_typescript@5.7.3_/node_modules/@vueuse/shared/index.js +0 -40
- /package/dist/components/{src/components/Boards → Boards}/src/hooKs/useStyle.d.ts +0 -0
- /package/dist/components/{src/components/Form → Form}/src/components/useRenderCheckbox.d.ts +0 -0
- /package/dist/components/{src/components/Form → Form}/src/components/useRenderRadio.d.ts +0 -0
- /package/dist/components/{src/components/Form → Form}/src/components/useRenderSelect.d.ts +0 -0
- /package/dist/components/{src/components/Form → Form}/src/helper/componentMap.d.ts +0 -0
- /package/dist/components/{src/components/Form → Form}/src/helper/index.d.ts +0 -0
- /package/dist/components/{src/components/Modal → Modal}/src/config.d.ts +0 -0
- /package/dist/components/{src/components/Modal → Modal}/src/hooks/useModalDrag.d.ts +0 -0
- /package/dist/components/{src/components/Modal → Modal}/src/hooks/useTimeout.d.ts +0 -0
- /package/dist/components/{src/components/Modal → Modal}/src/utils/index.d.ts +0 -0
- /package/dist/components/{src/components/NodeAxis → NodeAxis}/src/NodeAxis.vue.d.ts +0 -0
- /package/dist/components/{src/components/NodeAxis → NodeAxis}/src/TimerNodePlayer.d.ts +0 -0
- /package/dist/components/{src/components/NodeAxis → NodeAxis}/src/interface/NodePlayer.d.ts +0 -0
- /package/dist/components/{src/components/Table → Table}/src/components/ColumnSetting.vue.d.ts +0 -0
- /package/dist/components/{src/components/Table → Table}/src/helper/index.d.ts +0 -0
- /package/dist/components/{src/components/Video → Video}/src/abstract/AbstractVideoControl.d.ts +0 -0
- /package/dist/components/{src/components/Video → Video}/src/abstract/Observable.d.ts +0 -0
- /package/dist/components/{src/components/Video → Video}/src/abstract/VideoControl.d.ts +0 -0
- /package/dist/components/{src/components/Video → Video}/src/control/DaHua.d.ts +0 -0
- /package/dist/components/{src/components/Video → Video}/src/control/Hikvision.d.ts +0 -0
- /package/dist/components/{src/components/Video → Video}/src/control/VideoFactory.d.ts +0 -0
- /package/dist/components/{src/components/Video → Video}/src/enums/CommonEnum.d.ts +0 -0
- /package/dist/components/{src/components/Windows → Windows}/src/ModalWrap.vue.d.ts +0 -0
- /package/dist/{components/src/helper → helper}/lang.d.ts +0 -0
- /package/dist/{components/src/utils → utils}/index.d.ts +0 -0
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
var defOptions = {
|
|
2
|
+
name: '图表图片',
|
|
3
|
+
suffix: '.png',
|
|
4
|
+
pixelRatio: 2,
|
|
5
|
+
backgroundColor: '#fff'
|
|
6
|
+
};
|
|
7
|
+
function useDownLoad(getFn) {
|
|
8
|
+
var downloadImg = function downloadImg(options) {
|
|
9
|
+
var def = Object.assign({}, defOptions, options);
|
|
10
|
+
var chartIns = typeof getFn == 'function' ? getFn() : getFn;
|
|
11
|
+
var imgUrl = chartIns === null || chartIns === void 0 ? void 0 : chartIns.getDataURL({
|
|
12
|
+
pixelRatio: def.pixelRatio,
|
|
13
|
+
backgroundColor: def.backgroundColor
|
|
14
|
+
});
|
|
15
|
+
var tempA = document.createElement('a');
|
|
16
|
+
tempA.download = def.name + def.suffix;
|
|
17
|
+
tempA.href = imgUrl;
|
|
18
|
+
document.body.appendChild(tempA);
|
|
19
|
+
tempA.click();
|
|
20
|
+
tempA.remove();
|
|
21
|
+
};
|
|
22
|
+
return {
|
|
23
|
+
downloadImg: downloadImg
|
|
24
|
+
};
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
export { useDownLoad };
|
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
2
|
-
host: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/types").
|
|
2
|
+
host: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/shared/vue-types.d8e57a80").b<string>> & {
|
|
3
3
|
default: string;
|
|
4
4
|
};
|
|
5
|
-
port: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/types").
|
|
5
|
+
port: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/shared/vue-types.d8e57a80").b<string>> & {
|
|
6
6
|
default: string;
|
|
7
7
|
};
|
|
8
|
-
channel: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/types").
|
|
8
|
+
channel: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/shared/vue-types.d8e57a80").b<string>> & {
|
|
9
9
|
default: string;
|
|
10
10
|
};
|
|
11
|
-
username: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/types").
|
|
11
|
+
username: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/shared/vue-types.d8e57a80").b<string>> & {
|
|
12
12
|
default: string;
|
|
13
13
|
};
|
|
14
|
-
password: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/types").
|
|
14
|
+
password: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/shared/vue-types.d8e57a80").b<string>> & {
|
|
15
15
|
default: string;
|
|
16
16
|
};
|
|
17
|
-
streamType: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/types").
|
|
17
|
+
streamType: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/shared/vue-types.d8e57a80").b<string>> & {
|
|
18
18
|
default: string;
|
|
19
19
|
};
|
|
20
|
-
videoType: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/types").
|
|
20
|
+
videoType: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/shared/vue-types.d8e57a80").b<string>> & {
|
|
21
21
|
default: string;
|
|
22
22
|
} & {
|
|
23
23
|
default: string;
|
|
@@ -25,25 +25,25 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
25
25
|
}>, (_ctx: any, _cache: any) => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
26
26
|
[key: string]: any;
|
|
27
27
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
28
|
-
host: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/types").
|
|
28
|
+
host: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/shared/vue-types.d8e57a80").b<string>> & {
|
|
29
29
|
default: string;
|
|
30
30
|
};
|
|
31
|
-
port: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/types").
|
|
31
|
+
port: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/shared/vue-types.d8e57a80").b<string>> & {
|
|
32
32
|
default: string;
|
|
33
33
|
};
|
|
34
|
-
channel: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/types").
|
|
34
|
+
channel: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/shared/vue-types.d8e57a80").b<string>> & {
|
|
35
35
|
default: string;
|
|
36
36
|
};
|
|
37
|
-
username: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/types").
|
|
37
|
+
username: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/shared/vue-types.d8e57a80").b<string>> & {
|
|
38
38
|
default: string;
|
|
39
39
|
};
|
|
40
|
-
password: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/types").
|
|
40
|
+
password: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/shared/vue-types.d8e57a80").b<string>> & {
|
|
41
41
|
default: string;
|
|
42
42
|
};
|
|
43
|
-
streamType: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/types").
|
|
43
|
+
streamType: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/shared/vue-types.d8e57a80").b<string>> & {
|
|
44
44
|
default: string;
|
|
45
45
|
};
|
|
46
|
-
videoType: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/types").
|
|
46
|
+
videoType: import("vue-types").VueTypeValidableDef<string, import("vue-types/dist/shared/vue-types.d8e57a80").b<string>> & {
|
|
47
47
|
default: string;
|
|
48
48
|
} & {
|
|
49
49
|
default: string;
|
|
@@ -7,7 +7,7 @@ import propTypes from 'vue-types';
|
|
|
7
7
|
import script$1 from './VideoPlayerToolbar.vue2.js';
|
|
8
8
|
|
|
9
9
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
10
|
-
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t),
|
|
10
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
11
11
|
var _hoisted_1 = {
|
|
12
12
|
style: {
|
|
13
13
|
"color": "white"
|
|
@@ -31,7 +31,7 @@ var script = defineComponent({
|
|
|
31
31
|
var isPlay = ref(false);
|
|
32
32
|
var isFullscreen = ref(false);
|
|
33
33
|
var props = __props;
|
|
34
|
-
var componentId = (_getCurrentInstance = getCurrentInstance()) === null || _getCurrentInstance ===
|
|
34
|
+
var componentId = (_getCurrentInstance = getCurrentInstance()) === null || _getCurrentInstance === void 0 ? void 0 : _getCurrentInstance.uid;
|
|
35
35
|
onMounted(function () {
|
|
36
36
|
nextTick(function () {
|
|
37
37
|
instance = VideoFactory.create(props.videoType, _objectSpread({
|
|
@@ -55,12 +55,12 @@ var script = defineComponent({
|
|
|
55
55
|
function stop() {
|
|
56
56
|
var _instance, _instance$stop;
|
|
57
57
|
console.log('props.control', instance);
|
|
58
|
-
(_instance = instance) === null || _instance ===
|
|
58
|
+
(_instance = instance) === null || _instance === void 0 || (_instance$stop = _instance.stop) === null || _instance$stop === void 0 || _instance$stop.call(_instance);
|
|
59
59
|
}
|
|
60
60
|
function play() {
|
|
61
61
|
var _instance2, _instance2$play;
|
|
62
62
|
console.log('props.control', instance);
|
|
63
|
-
(_instance2 = instance) === null || _instance2 ===
|
|
63
|
+
(_instance2 = instance) === null || _instance2 === void 0 || (_instance2$play = _instance2.play) === null || _instance2$play === void 0 || _instance2$play.call(_instance2);
|
|
64
64
|
}
|
|
65
65
|
function toggleFullScreen() {
|
|
66
66
|
isFullscreen.value = !isFullscreen.value;
|
|
@@ -68,7 +68,7 @@ var script = defineComponent({
|
|
|
68
68
|
}
|
|
69
69
|
onBeforeUnmount(function () {
|
|
70
70
|
var _instance3, _instance3$dispose;
|
|
71
|
-
(_instance3 = instance) === null || _instance3 ===
|
|
71
|
+
(_instance3 = instance) === null || _instance3 === void 0 || (_instance3$dispose = _instance3.dispose) === null || _instance3$dispose === void 0 || _instance3$dispose.call(_instance3);
|
|
72
72
|
instance = null;
|
|
73
73
|
});
|
|
74
74
|
function downloadFile() {
|
|
@@ -1,29 +1,29 @@
|
|
|
1
1
|
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
2
|
-
domRef: import("vue-types").VueTypeValidableDef<any, import("vue-types/dist/types").
|
|
3
|
-
stop: import("vue-types").VueTypeValidableDef<(...args: any[]) => any, import("vue-types/dist/types").
|
|
2
|
+
domRef: import("vue-types").VueTypeValidableDef<any, import("vue-types/dist/shared/vue-types.d8e57a80").b<any>>;
|
|
3
|
+
stop: import("vue-types").VueTypeValidableDef<(...args: any[]) => any, import("vue-types/dist/shared/vue-types.d8e57a80").b<(...args: any[]) => any>> & {
|
|
4
4
|
default: (...args: any[]) => any;
|
|
5
5
|
};
|
|
6
|
-
play: import("vue-types").VueTypeValidableDef<(...args: any[]) => any, import("vue-types/dist/types").
|
|
6
|
+
play: import("vue-types").VueTypeValidableDef<(...args: any[]) => any, import("vue-types/dist/shared/vue-types.d8e57a80").b<(...args: any[]) => any>> & {
|
|
7
7
|
default: (...args: any[]) => any;
|
|
8
8
|
};
|
|
9
|
-
isPlay: import("vue-types").VueTypeValidableDef<boolean, import("vue-types/dist/types").
|
|
10
|
-
isFullscreen: import("vue-types").VueTypeValidableDef<boolean, import("vue-types/dist/types").
|
|
11
|
-
toggleFullscreenFn: import("vue-types").VueTypeValidableDef<(...args: any[]) => any, import("vue-types/dist/types").
|
|
9
|
+
isPlay: import("vue-types").VueTypeValidableDef<boolean, import("vue-types/dist/shared/vue-types.d8e57a80").b<boolean>>;
|
|
10
|
+
isFullscreen: import("vue-types").VueTypeValidableDef<boolean, import("vue-types/dist/shared/vue-types.d8e57a80").b<boolean>>;
|
|
11
|
+
toggleFullscreenFn: import("vue-types").VueTypeValidableDef<(...args: any[]) => any, import("vue-types/dist/shared/vue-types.d8e57a80").b<(...args: any[]) => any>> & {
|
|
12
12
|
default: (...args: any[]) => any;
|
|
13
13
|
};
|
|
14
14
|
}>, (_ctx: any, _cache: any) => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
15
15
|
[key: string]: any;
|
|
16
16
|
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
17
|
-
domRef: import("vue-types").VueTypeValidableDef<any, import("vue-types/dist/types").
|
|
18
|
-
stop: import("vue-types").VueTypeValidableDef<(...args: any[]) => any, import("vue-types/dist/types").
|
|
17
|
+
domRef: import("vue-types").VueTypeValidableDef<any, import("vue-types/dist/shared/vue-types.d8e57a80").b<any>>;
|
|
18
|
+
stop: import("vue-types").VueTypeValidableDef<(...args: any[]) => any, import("vue-types/dist/shared/vue-types.d8e57a80").b<(...args: any[]) => any>> & {
|
|
19
19
|
default: (...args: any[]) => any;
|
|
20
20
|
};
|
|
21
|
-
play: import("vue-types").VueTypeValidableDef<(...args: any[]) => any, import("vue-types/dist/types").
|
|
21
|
+
play: import("vue-types").VueTypeValidableDef<(...args: any[]) => any, import("vue-types/dist/shared/vue-types.d8e57a80").b<(...args: any[]) => any>> & {
|
|
22
22
|
default: (...args: any[]) => any;
|
|
23
23
|
};
|
|
24
|
-
isPlay: import("vue-types").VueTypeValidableDef<boolean, import("vue-types/dist/types").
|
|
25
|
-
isFullscreen: import("vue-types").VueTypeValidableDef<boolean, import("vue-types/dist/types").
|
|
26
|
-
toggleFullscreenFn: import("vue-types").VueTypeValidableDef<(...args: any[]) => any, import("vue-types/dist/types").
|
|
24
|
+
isPlay: import("vue-types").VueTypeValidableDef<boolean, import("vue-types/dist/shared/vue-types.d8e57a80").b<boolean>>;
|
|
25
|
+
isFullscreen: import("vue-types").VueTypeValidableDef<boolean, import("vue-types/dist/shared/vue-types.d8e57a80").b<boolean>>;
|
|
26
|
+
toggleFullscreenFn: import("vue-types").VueTypeValidableDef<(...args: any[]) => any, import("vue-types/dist/shared/vue-types.d8e57a80").b<(...args: any[]) => any>> & {
|
|
27
27
|
default: (...args: any[]) => any;
|
|
28
28
|
};
|
|
29
29
|
}>> & Readonly<{}>, {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineComponent, toRefs, computed, openBlock, createElementBlock, renderSlot, createVNode, unref, mergeProps, withModifiers } from 'vue';
|
|
2
|
-
import { useFullscreen } from '../../../node_modules/.pnpm/@vueuse_core@
|
|
2
|
+
import { useFullscreen } from '../../../node_modules/.pnpm/@vueuse_core@13.7.0_vue@3.5.19_typescript@5.9.2_/node_modules/@vueuse/core/index.js';
|
|
3
3
|
import '../../Icon/src/Icon.vue.js';
|
|
4
4
|
import '../../Icon/src/SvgIcon.vue.js';
|
|
5
5
|
import propTypes from 'vue-types';
|
|
@@ -36,16 +36,16 @@ var script = defineComponent({
|
|
|
36
36
|
function playToggle() {
|
|
37
37
|
if (isPlay.value) {
|
|
38
38
|
var _props$stop;
|
|
39
|
-
(_props$stop = props.stop) === null || _props$stop ===
|
|
39
|
+
(_props$stop = props.stop) === null || _props$stop === void 0 || _props$stop.call(props);
|
|
40
40
|
} else {
|
|
41
41
|
var _props$play;
|
|
42
|
-
(_props$play = props.play) === null || _props$play ===
|
|
42
|
+
(_props$play = props.play) === null || _props$play === void 0 || _props$play.call(props);
|
|
43
43
|
}
|
|
44
44
|
}
|
|
45
45
|
function fullToggle() {
|
|
46
46
|
var _props$toggleFullscre;
|
|
47
47
|
toggleDom();
|
|
48
|
-
(_props$toggleFullscre = props.toggleFullscreenFn) === null || _props$toggleFullscre ===
|
|
48
|
+
(_props$toggleFullscre = props.toggleFullscreenFn) === null || _props$toggleFullscre === void 0 || _props$toggleFullscre.call(props);
|
|
49
49
|
}
|
|
50
50
|
return function (_ctx, _cache) {
|
|
51
51
|
return openBlock(), createElementBlock("div", _hoisted_1, [renderSlot(_ctx.$slots, "default"), createVNode(unref(script$1), mergeProps({
|
|
@@ -13,19 +13,19 @@ var VideoControl = /*#__PURE__*/function (_Observable) {
|
|
|
13
13
|
var _this;
|
|
14
14
|
_classCallCheck(this, VideoControl);
|
|
15
15
|
_this = _callSuper(this, VideoControl);
|
|
16
|
-
_defineProperty(_this, "ip",
|
|
17
|
-
_defineProperty(_this, "port",
|
|
18
|
-
_defineProperty(_this, "channel",
|
|
19
|
-
_defineProperty(_this, "streamType",
|
|
20
|
-
_defineProperty(_this, "username",
|
|
21
|
-
_defineProperty(_this, "password",
|
|
22
|
-
_defineProperty(_this, "wrapEl",
|
|
23
|
-
_defineProperty(_this, "isPlayback",
|
|
24
|
-
_defineProperty(_this, "playbackIndex",
|
|
25
|
-
_defineProperty(_this, "state",
|
|
26
|
-
_defineProperty(_this, "player",
|
|
27
|
-
_defineProperty(_this, "needPlugin",
|
|
28
|
-
_defineProperty(_this, "needLogin",
|
|
16
|
+
_defineProperty(_this, "ip", void 0);
|
|
17
|
+
_defineProperty(_this, "port", void 0);
|
|
18
|
+
_defineProperty(_this, "channel", void 0);
|
|
19
|
+
_defineProperty(_this, "streamType", void 0);
|
|
20
|
+
_defineProperty(_this, "username", void 0);
|
|
21
|
+
_defineProperty(_this, "password", void 0);
|
|
22
|
+
_defineProperty(_this, "wrapEl", void 0);
|
|
23
|
+
_defineProperty(_this, "isPlayback", void 0);
|
|
24
|
+
_defineProperty(_this, "playbackIndex", void 0);
|
|
25
|
+
_defineProperty(_this, "state", void 0);
|
|
26
|
+
_defineProperty(_this, "player", void 0);
|
|
27
|
+
_defineProperty(_this, "needPlugin", void 0);
|
|
28
|
+
_defineProperty(_this, "needLogin", void 0);
|
|
29
29
|
console.log('opt', opt);
|
|
30
30
|
_this.ip = opt.ip;
|
|
31
31
|
_this.port = opt.port;
|
|
@@ -8,8 +8,8 @@ import VideoControl from '../abstract/VideoControl.js';
|
|
|
8
8
|
import { EventEnum } from '../enums/CommonEnum.js';
|
|
9
9
|
|
|
10
10
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
11
|
-
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t),
|
|
12
|
-
function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e, _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
11
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
12
|
+
function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
13
13
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
14
14
|
var DEF = {
|
|
15
15
|
ip: '172.168.1.247',
|
|
@@ -24,8 +24,8 @@ var DaHua = /*#__PURE__*/function (_VideoControl) {
|
|
|
24
24
|
var _this;
|
|
25
25
|
_classCallCheck(this, DaHua);
|
|
26
26
|
_this = _callSuper(this, DaHua, [_objectSpread(_objectSpread({}, DEF), opts)]);
|
|
27
|
-
_defineProperty(_this, "canvasEl",
|
|
28
|
-
_defineProperty(_this, "videoEl",
|
|
27
|
+
_defineProperty(_this, "canvasEl", void 0);
|
|
28
|
+
_defineProperty(_this, "videoEl", void 0);
|
|
29
29
|
_this.isPlayback = false;
|
|
30
30
|
_this.playbackIndex = 0;
|
|
31
31
|
_this.generateEl();
|
|
@@ -49,7 +49,7 @@ var DaHua = /*#__PURE__*/function (_VideoControl) {
|
|
|
49
49
|
key: "removeEl",
|
|
50
50
|
value: function removeEl() {
|
|
51
51
|
var remove = function remove(el) {
|
|
52
|
-
var parent = el === null || el ===
|
|
52
|
+
var parent = el === null || el === void 0 ? void 0 : el.parentNode;
|
|
53
53
|
if (parent) {
|
|
54
54
|
parent.removeChild(el);
|
|
55
55
|
}
|
|
@@ -77,7 +77,7 @@ var DaHua = /*#__PURE__*/function (_VideoControl) {
|
|
|
77
77
|
key: "stop",
|
|
78
78
|
value: function stop() {
|
|
79
79
|
var _this$player, _this$player$pause;
|
|
80
|
-
this === null || this ===
|
|
80
|
+
this === null || this === void 0 || (_this$player = this.player) === null || _this$player === void 0 || (_this$player$pause = _this$player.pause) === null || _this$player$pause === void 0 || _this$player$pause.call(_this$player);
|
|
81
81
|
this.dispatch(EventEnum.PAUSE, {
|
|
82
82
|
type: 'Pause',
|
|
83
83
|
target: this
|
|
@@ -143,8 +143,8 @@ var DaHua = /*#__PURE__*/function (_VideoControl) {
|
|
|
143
143
|
type: 'dispose',
|
|
144
144
|
target: this
|
|
145
145
|
});
|
|
146
|
-
this.player && ((_this$player2 = this.player) === null || _this$player2 ===
|
|
147
|
-
this.player && ((_this$player3 = this.player) === null || _this$player3 ===
|
|
146
|
+
this.player && ((_this$player2 = this.player) === null || _this$player2 === void 0 || (_this$player2$stop = _this$player2.stop) === null || _this$player2$stop === void 0 ? void 0 : _this$player2$stop.call(_this$player2));
|
|
147
|
+
this.player && ((_this$player3 = this.player) === null || _this$player3 === void 0 || (_this$player3$close = _this$player3.close) === null || _this$player3$close === void 0 ? void 0 : _this$player3$close.call(_this$player3));
|
|
148
148
|
this.removeEl();
|
|
149
149
|
this.player = null;
|
|
150
150
|
}
|
|
@@ -8,8 +8,8 @@ import VideoControl from '../abstract/VideoControl.js';
|
|
|
8
8
|
import { EventEnum } from '../enums/CommonEnum.js';
|
|
9
9
|
|
|
10
10
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
11
|
-
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t),
|
|
12
|
-
function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e, _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
11
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
12
|
+
function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
|
|
13
13
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
14
14
|
var DEF = {
|
|
15
15
|
ip: '172.168.1.247',
|
|
@@ -29,11 +29,11 @@ var Hikvision = /*#__PURE__*/function (_VideoControl) {
|
|
|
29
29
|
_classCallCheck(this, Hikvision);
|
|
30
30
|
var def = _objectSpread(_objectSpread({}, DEF), opts);
|
|
31
31
|
_this = _callSuper(this, Hikvision, [def]);
|
|
32
|
-
_defineProperty(_this, "width",
|
|
33
|
-
_defineProperty(_this, "height",
|
|
34
|
-
_defineProperty(_this, "elId",
|
|
35
|
-
_defineProperty(_this, "container",
|
|
36
|
-
_defineProperty(_this, "szBasePath",
|
|
32
|
+
_defineProperty(_this, "width", void 0);
|
|
33
|
+
_defineProperty(_this, "height", void 0);
|
|
34
|
+
_defineProperty(_this, "elId", void 0);
|
|
35
|
+
_defineProperty(_this, "container", void 0);
|
|
36
|
+
_defineProperty(_this, "szBasePath", void 0);
|
|
37
37
|
_this.isPlayback = false;
|
|
38
38
|
_this.playbackIndex = 0;
|
|
39
39
|
_this.needPlugin = true;
|
|
@@ -84,7 +84,7 @@ var Hikvision = /*#__PURE__*/function (_VideoControl) {
|
|
|
84
84
|
value: function generateEl() {
|
|
85
85
|
var _this$width, _this$height;
|
|
86
86
|
this.container = document.createElement('div');
|
|
87
|
-
this.container.style.cssText = "width: ".concat((_this$width = this.width) !== null && _this$width !==
|
|
87
|
+
this.container.style.cssText = "width: ".concat((_this$width = this.width) !== null && _this$width !== void 0 ? _this$width : '100%', ";height: ").concat((_this$height = this.height) !== null && _this$height !== void 0 ? _this$height : '100%', ";");
|
|
88
88
|
this.container.setAttribute('id', this.pluginElId);
|
|
89
89
|
if (this.wrapEl) {
|
|
90
90
|
this.wrapEl.appendChild(this.container);
|
|
@@ -94,7 +94,7 @@ var Hikvision = /*#__PURE__*/function (_VideoControl) {
|
|
|
94
94
|
key: "removeEl",
|
|
95
95
|
value: function removeEl() {
|
|
96
96
|
var remove = function remove(el) {
|
|
97
|
-
var parent = el === null || el ===
|
|
97
|
+
var parent = el === null || el === void 0 ? void 0 : el.parentNode;
|
|
98
98
|
if (parent) {
|
|
99
99
|
parent.removeChild(el);
|
|
100
100
|
}
|
|
@@ -123,7 +123,7 @@ var Hikvision = /*#__PURE__*/function (_VideoControl) {
|
|
|
123
123
|
value: function play() {
|
|
124
124
|
var _WebVideoCtrl,
|
|
125
125
|
_this2 = this;
|
|
126
|
-
var oWndInfo = (_WebVideoCtrl = WebVideoCtrl) === null || _WebVideoCtrl ===
|
|
126
|
+
var oWndInfo = (_WebVideoCtrl = WebVideoCtrl) === null || _WebVideoCtrl === void 0 ? void 0 : _WebVideoCtrl.I_GetWindowStatus(0);
|
|
127
127
|
var startRealPlay = function startRealPlay() {
|
|
128
128
|
WebVideoCtrl.I_StartRealPlay(_this2.identify, {
|
|
129
129
|
iStreamType: _this2.streamType,
|
|
@@ -199,7 +199,7 @@ var Hikvision = /*#__PURE__*/function (_VideoControl) {
|
|
|
199
199
|
port = this.port,
|
|
200
200
|
username = this.username,
|
|
201
201
|
password = this.password;
|
|
202
|
-
(_WebVideoCtrl2 = WebVideoCtrl) === null || _WebVideoCtrl2 ===
|
|
202
|
+
(_WebVideoCtrl2 = WebVideoCtrl) === null || _WebVideoCtrl2 === void 0 || _WebVideoCtrl2.I_Login(ip, 1, port, username, password, {
|
|
203
203
|
timeout: 3000,
|
|
204
204
|
success: function success(xmlDoc) {
|
|
205
205
|
console.log('登录成功', xmlDoc);
|
|
@@ -219,7 +219,7 @@ var Hikvision = /*#__PURE__*/function (_VideoControl) {
|
|
|
219
219
|
value: function logout() {
|
|
220
220
|
var _WebVideoCtrl3,
|
|
221
221
|
_this5 = this;
|
|
222
|
-
(_WebVideoCtrl3 = WebVideoCtrl) === null || _WebVideoCtrl3 ===
|
|
222
|
+
(_WebVideoCtrl3 = WebVideoCtrl) === null || _WebVideoCtrl3 === void 0 || _WebVideoCtrl3.I_Logout(this.identify).then(function () {
|
|
223
223
|
console.log('退出成功');
|
|
224
224
|
}, function () {
|
|
225
225
|
console.log('退出失败');
|
|
@@ -8,9 +8,9 @@ import def from './config/default.manager.js';
|
|
|
8
8
|
var BufferLayerPlayer = /*#__PURE__*/function () {
|
|
9
9
|
function BufferLayerPlayer(manager, provider, options) {
|
|
10
10
|
_classCallCheck(this, BufferLayerPlayer);
|
|
11
|
-
_defineProperty(this, "manager",
|
|
12
|
-
_defineProperty(this, "provider",
|
|
13
|
-
_defineProperty(this, "options",
|
|
11
|
+
_defineProperty(this, "manager", void 0);
|
|
12
|
+
_defineProperty(this, "provider", void 0);
|
|
13
|
+
_defineProperty(this, "options", void 0);
|
|
14
14
|
_defineProperty(this, "queue", []);
|
|
15
15
|
_defineProperty(this, "index", 0);
|
|
16
16
|
_defineProperty(this, "cursor", 0);
|
|
@@ -27,41 +27,40 @@ var BufferLayerPlayer = /*#__PURE__*/function () {
|
|
|
27
27
|
key: "backward",
|
|
28
28
|
value: function () {
|
|
29
29
|
var _backward = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee() {
|
|
30
|
-
var index, cursor;
|
|
31
|
-
return _regeneratorRuntime.wrap(function
|
|
30
|
+
var index, cursor, _t;
|
|
31
|
+
return _regeneratorRuntime.wrap(function (_context) {
|
|
32
32
|
while (1) switch (_context.prev = _context.next) {
|
|
33
33
|
case 0:
|
|
34
34
|
index = this.index;
|
|
35
35
|
cursor = this.cursor;
|
|
36
36
|
if (!(index === 0 && cursor === 0)) {
|
|
37
|
-
_context.next =
|
|
37
|
+
_context.next = 1;
|
|
38
38
|
break;
|
|
39
39
|
}
|
|
40
40
|
return _context.abrupt("return");
|
|
41
|
-
case
|
|
41
|
+
case 1:
|
|
42
42
|
if (!(index === 0 || cursor > this.center)) {
|
|
43
|
-
_context.next =
|
|
43
|
+
_context.next = 2;
|
|
44
44
|
break;
|
|
45
45
|
}
|
|
46
46
|
this.cursor--;
|
|
47
|
-
_context.next =
|
|
47
|
+
_context.next = 5;
|
|
48
48
|
break;
|
|
49
|
-
case
|
|
50
|
-
|
|
51
|
-
_context.next =
|
|
49
|
+
case 2:
|
|
50
|
+
_t = this.queue;
|
|
51
|
+
_context.next = 3;
|
|
52
52
|
return this.get(--this.index);
|
|
53
|
-
case
|
|
54
|
-
|
|
55
|
-
_context.
|
|
56
|
-
_context.next = 15;
|
|
53
|
+
case 3:
|
|
54
|
+
_t.splice.call(_t, 0, 0, _context.sent);
|
|
55
|
+
_context.next = 4;
|
|
57
56
|
return this.manager.addition(this.queue[0]);
|
|
58
|
-
case
|
|
57
|
+
case 4:
|
|
59
58
|
if (this.queue.length > this.options.buffer) {
|
|
60
59
|
this.manager.remove(this.queue.pop());
|
|
61
60
|
}
|
|
62
|
-
case
|
|
61
|
+
case 5:
|
|
63
62
|
this.render();
|
|
64
|
-
case
|
|
63
|
+
case 6:
|
|
65
64
|
case "end":
|
|
66
65
|
return _context.stop();
|
|
67
66
|
}
|
|
@@ -76,40 +75,39 @@ var BufferLayerPlayer = /*#__PURE__*/function () {
|
|
|
76
75
|
key: "forward",
|
|
77
76
|
value: function () {
|
|
78
77
|
var _forward = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee2() {
|
|
79
|
-
var size, index, count;
|
|
80
|
-
return _regeneratorRuntime.wrap(function
|
|
78
|
+
var size, index, count, _t2;
|
|
79
|
+
return _regeneratorRuntime.wrap(function (_context2) {
|
|
81
80
|
while (1) switch (_context2.prev = _context2.next) {
|
|
82
81
|
case 0:
|
|
83
82
|
size = this.queue.length;
|
|
84
83
|
index = this.index;
|
|
85
84
|
count = this.provider.count;
|
|
86
85
|
if (!(index + size >= count && this.cursor >= size)) {
|
|
87
|
-
_context2.next =
|
|
86
|
+
_context2.next = 1;
|
|
88
87
|
break;
|
|
89
88
|
}
|
|
90
89
|
return _context2.abrupt("return");
|
|
91
|
-
case
|
|
90
|
+
case 1:
|
|
92
91
|
if (!(this.cursor < this.center || index + size >= count)) {
|
|
93
|
-
_context2.next =
|
|
92
|
+
_context2.next = 2;
|
|
94
93
|
break;
|
|
95
94
|
}
|
|
96
95
|
this.cursor++;
|
|
97
|
-
_context2.next =
|
|
96
|
+
_context2.next = 5;
|
|
98
97
|
break;
|
|
99
|
-
case
|
|
100
|
-
|
|
101
|
-
_context2.next =
|
|
98
|
+
case 2:
|
|
99
|
+
_t2 = this.queue;
|
|
100
|
+
_context2.next = 3;
|
|
102
101
|
return this.get(size + this.index++);
|
|
103
|
-
case
|
|
104
|
-
|
|
105
|
-
_context2.
|
|
106
|
-
_context2.next = 16;
|
|
102
|
+
case 3:
|
|
103
|
+
_t2.push.call(_t2, _context2.sent);
|
|
104
|
+
_context2.next = 4;
|
|
107
105
|
return this.manager.addition(this.queue[this.queue.length - 1]);
|
|
108
|
-
case
|
|
106
|
+
case 4:
|
|
109
107
|
this.manager.remove(this.queue.shift());
|
|
110
|
-
case
|
|
108
|
+
case 5:
|
|
111
109
|
this.render();
|
|
112
|
-
case
|
|
110
|
+
case 6:
|
|
113
111
|
case "end":
|
|
114
112
|
return _context2.stop();
|
|
115
113
|
}
|
|
@@ -144,19 +142,19 @@ var BufferLayerPlayer = /*#__PURE__*/function () {
|
|
|
144
142
|
key: "visible",
|
|
145
143
|
value: function () {
|
|
146
144
|
var _visible = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee3(value) {
|
|
147
|
-
return _regeneratorRuntime.wrap(function
|
|
145
|
+
return _regeneratorRuntime.wrap(function (_context3) {
|
|
148
146
|
while (1) switch (_context3.prev = _context3.next) {
|
|
149
147
|
case 0:
|
|
150
148
|
if (value === false) {
|
|
151
149
|
this.manager.remove(this.queue);
|
|
152
150
|
}
|
|
153
151
|
if (!(value === true)) {
|
|
154
|
-
_context3.next =
|
|
152
|
+
_context3.next = 1;
|
|
155
153
|
break;
|
|
156
154
|
}
|
|
157
|
-
_context3.next =
|
|
155
|
+
_context3.next = 1;
|
|
158
156
|
return this.manager.addition(this.queue);
|
|
159
|
-
case
|
|
157
|
+
case 1:
|
|
160
158
|
case "end":
|
|
161
159
|
return _context3.stop();
|
|
162
160
|
}
|
|
@@ -200,18 +198,18 @@ var BufferLayerPlayer = /*#__PURE__*/function () {
|
|
|
200
198
|
var _get = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee4(index) {
|
|
201
199
|
var _this$provider, _this$manager, _this$manager2, _this$manager3;
|
|
202
200
|
var layer, opacity;
|
|
203
|
-
return _regeneratorRuntime.wrap(function
|
|
201
|
+
return _regeneratorRuntime.wrap(function (_context4) {
|
|
204
202
|
while (1) switch (_context4.prev = _context4.next) {
|
|
205
203
|
case 0:
|
|
206
|
-
_context4.next =
|
|
207
|
-
return (_this$provider = this.provider) === null || _this$provider ===
|
|
208
|
-
case
|
|
204
|
+
_context4.next = 1;
|
|
205
|
+
return (_this$provider = this.provider) === null || _this$provider === void 0 ? void 0 : _this$provider.get(index);
|
|
206
|
+
case 1:
|
|
209
207
|
layer = _context4.sent;
|
|
210
|
-
opacity = (_this$manager = this.manager) === null || _this$manager ===
|
|
211
|
-
(_this$manager2 = this.manager) === null || _this$manager2 ===
|
|
212
|
-
(_this$manager3 = this.manager) === null || _this$manager3 ===
|
|
208
|
+
opacity = (_this$manager = this.manager) === null || _this$manager === void 0 ? void 0 : _this$manager.query(layer, "opacity");
|
|
209
|
+
(_this$manager2 = this.manager) === null || _this$manager2 === void 0 || _this$manager2.modify(layer, "$opacity", opacity);
|
|
210
|
+
(_this$manager3 = this.manager) === null || _this$manager3 === void 0 || _this$manager3.modify(layer, "opacity", 0);
|
|
213
211
|
return _context4.abrupt("return", layer);
|
|
214
|
-
case
|
|
212
|
+
case 2:
|
|
215
213
|
case "end":
|
|
216
214
|
return _context4.stop();
|
|
217
215
|
}
|
|
@@ -227,41 +225,40 @@ var BufferLayerPlayer = /*#__PURE__*/function () {
|
|
|
227
225
|
value: function () {
|
|
228
226
|
var _ready = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee5(index) {
|
|
229
227
|
var _this$queue2, _this$manager4;
|
|
230
|
-
var max, i, _this$queue;
|
|
231
|
-
return _regeneratorRuntime.wrap(function
|
|
228
|
+
var max, i, _this$queue, _t3, _t4;
|
|
229
|
+
return _regeneratorRuntime.wrap(function (_context5) {
|
|
232
230
|
while (1) switch (_context5.prev = _context5.next) {
|
|
233
231
|
case 0:
|
|
234
232
|
max = Math.min(this.provider.count, index + this.options.buffer);
|
|
235
233
|
i = index;
|
|
236
|
-
case
|
|
234
|
+
case 1:
|
|
237
235
|
if (!(i < max)) {
|
|
238
|
-
_context5.next =
|
|
236
|
+
_context5.next = 4;
|
|
239
237
|
break;
|
|
240
238
|
}
|
|
241
|
-
|
|
242
|
-
if (
|
|
243
|
-
_context5.next =
|
|
239
|
+
_t3 = (_this$queue = this.queue) === null || _this$queue === void 0;
|
|
240
|
+
if (_t3) {
|
|
241
|
+
_context5.next = 3;
|
|
244
242
|
break;
|
|
245
243
|
}
|
|
246
|
-
|
|
247
|
-
_context5.next =
|
|
244
|
+
_t4 = _this$queue;
|
|
245
|
+
_context5.next = 2;
|
|
248
246
|
return this.get(i);
|
|
249
|
-
case
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
case 10:
|
|
247
|
+
case 2:
|
|
248
|
+
_t4.push.call(_t4, _context5.sent);
|
|
249
|
+
case 3:
|
|
253
250
|
i++;
|
|
254
|
-
_context5.next =
|
|
251
|
+
_context5.next = 1;
|
|
255
252
|
break;
|
|
256
|
-
case
|
|
253
|
+
case 4:
|
|
257
254
|
this.index = index;
|
|
258
255
|
this.cursor = 0;
|
|
259
|
-
this.center = ((_this$queue2 = this.queue) === null || _this$queue2 ===
|
|
260
|
-
_context5.next =
|
|
261
|
-
return (_this$manager4 = this.manager) === null || _this$manager4 ===
|
|
262
|
-
case
|
|
256
|
+
this.center = ((_this$queue2 = this.queue) === null || _this$queue2 === void 0 ? void 0 : _this$queue2.length) >> 1;
|
|
257
|
+
_context5.next = 5;
|
|
258
|
+
return (_this$manager4 = this.manager) === null || _this$manager4 === void 0 ? void 0 : _this$manager4.addition(this.queue);
|
|
259
|
+
case 5:
|
|
263
260
|
this.render();
|
|
264
|
-
case
|
|
261
|
+
case 6:
|
|
265
262
|
case "end":
|
|
266
263
|
return _context5.stop();
|
|
267
264
|
}
|
|
@@ -280,7 +277,7 @@ var BufferLayerPlayer = /*#__PURE__*/function () {
|
|
|
280
277
|
if (this.last && this.last !== queue[cursor]) {
|
|
281
278
|
this.manager.modify(this.last, "opacity", 0);
|
|
282
279
|
}
|
|
283
|
-
if (!queue || (queue === null || queue ===
|
|
280
|
+
if (!queue || (queue === null || queue === void 0 ? void 0 : queue.length) <= 0) return;
|
|
284
281
|
if ((this.last = queue[cursor]) != null) {
|
|
285
282
|
var opacity = this.manager.query(queue[cursor], "$opacity");
|
|
286
283
|
this.manager.modify(queue[cursor], "opacity", opacity);
|