inl-ui 0.1.21 → 0.1.23
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/index.cjs +84 -23
- package/dist/components/index.d.ts +68 -10
- package/dist/components/index.js +83 -24
- package/dist/components/style.css +2 -1
- package/dist/hooks/index.cjs +5 -9
- package/dist/hooks/index.js +5 -9
- package/dist/index.cjs +85 -24
- package/dist/index.d.ts +86 -28
- package/dist/index.js +84 -24
- package/dist/style.css +2 -1
- package/dist/tplib/index.cjs +5 -9
- package/dist/tplib/index.d.ts +0 -1
- package/dist/tplib/index.js +5 -9
- package/dist/video/index.cjs +84 -23
- package/dist/video/index.d.ts +65 -7
- package/dist/video/index.js +83 -24
- package/dist/video/style.css +2 -1
- package/dist/videoMobile/index.cjs +7 -11
- package/dist/videoMobile/index.js +7 -11
- package/package.json +3 -1
package/dist/video/index.js
CHANGED
|
@@ -2,6 +2,7 @@ import { defineComponent, ref, watch, onBeforeUnmount, createVNode, resolveCompo
|
|
|
2
2
|
import { FullscreenOutlined, createFromIconfontCN } from '@ant-design/icons-vue';
|
|
3
3
|
import axios from 'axios';
|
|
4
4
|
import { useRouter } from 'vue-router';
|
|
5
|
+
import EZUIKit from 'ezuikit-js';
|
|
5
6
|
|
|
6
7
|
const config = {
|
|
7
8
|
prefix: "inl",
|
|
@@ -4518,7 +4519,7 @@ class WebRtcMt$1 {
|
|
|
4518
4519
|
}
|
|
4519
4520
|
}
|
|
4520
4521
|
}
|
|
4521
|
-
retryTime;
|
|
4522
|
+
// protected retryTime;
|
|
4522
4523
|
// 拉流创建播放器
|
|
4523
4524
|
createVideo(plays) {
|
|
4524
4525
|
this.mediaServerAddrMap.set(plays.videoElm, plays);
|
|
@@ -4529,7 +4530,6 @@ class WebRtcMt$1 {
|
|
|
4529
4530
|
fetch(addRtspProxyUrl, {
|
|
4530
4531
|
method: "GET"
|
|
4531
4532
|
}).then(response => {
|
|
4532
|
-
this.retryTime = 0;
|
|
4533
4533
|
response.json().then(res => {
|
|
4534
4534
|
if (res.code === 0) {
|
|
4535
4535
|
this.startPlay(plays);
|
|
@@ -4541,12 +4541,9 @@ class WebRtcMt$1 {
|
|
|
4541
4541
|
}
|
|
4542
4542
|
});
|
|
4543
4543
|
}).catch(err => {
|
|
4544
|
-
|
|
4545
|
-
this.
|
|
4546
|
-
|
|
4547
|
-
this.rePlay();
|
|
4548
|
-
}, 60 * 1e3);
|
|
4549
|
-
}
|
|
4544
|
+
setTimeout(() => {
|
|
4545
|
+
this.rePlay();
|
|
4546
|
+
}, 3 * 60 * 1e3);
|
|
4550
4547
|
});
|
|
4551
4548
|
});
|
|
4552
4549
|
}
|
|
@@ -4605,7 +4602,7 @@ class WebRtcMt$1 {
|
|
|
4605
4602
|
this.stopPlay();
|
|
4606
4603
|
setTimeout(() => {
|
|
4607
4604
|
this.init(this.opt);
|
|
4608
|
-
}, 1e3);
|
|
4605
|
+
}, 5 * 1e3);
|
|
4609
4606
|
}
|
|
4610
4607
|
// 播放
|
|
4611
4608
|
play(videoElm) {
|
|
@@ -4782,9 +4779,9 @@ const VideoPlayerV2 = defineComponent({
|
|
|
4782
4779
|
});
|
|
4783
4780
|
onBeforeUnmount(() => {
|
|
4784
4781
|
stopPlay();
|
|
4785
|
-
|
|
4786
|
-
const videoElement = document.getElementById(uuid);
|
|
4782
|
+
const videoElement = document.getElementById(`videoPlayer_${uuid}`);
|
|
4787
4783
|
if (videoElement) {
|
|
4784
|
+
videoElement.pause();
|
|
4788
4785
|
videoElement.src = null;
|
|
4789
4786
|
videoElement.srcObject = null;
|
|
4790
4787
|
videoElement.remove();
|
|
@@ -5227,23 +5224,12 @@ const VideoBoxV2 = defineComponent({
|
|
|
5227
5224
|
camera.value = res.data.data;
|
|
5228
5225
|
streams.value = JSON.parse(camera.value.brandTypePo?.streamTypeDict || "[]");
|
|
5229
5226
|
};
|
|
5230
|
-
let interval;
|
|
5231
5227
|
let timeout;
|
|
5232
5228
|
let show = ref(true);
|
|
5233
|
-
|
|
5234
|
-
show.value = false;
|
|
5235
|
-
setTimeout(() => {
|
|
5236
|
-
show.value = true;
|
|
5237
|
-
}, 500);
|
|
5238
|
-
}, _prop.intervalTime * (0.5 + Math.random()));
|
|
5239
|
-
onBeforeUnmount(() => {
|
|
5240
|
-
clearInterval(interval);
|
|
5241
|
-
clearInterval(timer);
|
|
5242
|
-
});
|
|
5229
|
+
onBeforeUnmount(() => {});
|
|
5243
5230
|
const fill = ref("fill");
|
|
5244
5231
|
watch(() => _prop.camera, val => {
|
|
5245
5232
|
if (val && Object.keys(val).length != 0) {
|
|
5246
|
-
clearInterval(interval);
|
|
5247
5233
|
getVideoParams(val);
|
|
5248
5234
|
getVideoDetail(val);
|
|
5249
5235
|
const fillVal = localStorage.getItem(val);
|
|
@@ -6120,4 +6106,77 @@ const AlarmVideo = defineComponent({
|
|
|
6120
6106
|
});
|
|
6121
6107
|
var alarmVideo = installComponent(AlarmVideo, "alarm-video");
|
|
6122
6108
|
|
|
6123
|
-
|
|
6109
|
+
const CloudVideo = defineComponent({
|
|
6110
|
+
props: {
|
|
6111
|
+
// 视频信息|视频源uuid
|
|
6112
|
+
cameraId: {
|
|
6113
|
+
require: true,
|
|
6114
|
+
type: String
|
|
6115
|
+
},
|
|
6116
|
+
channelNo: {
|
|
6117
|
+
type: Number,
|
|
6118
|
+
default: 1
|
|
6119
|
+
},
|
|
6120
|
+
token: {
|
|
6121
|
+
type: String,
|
|
6122
|
+
default: ""
|
|
6123
|
+
},
|
|
6124
|
+
template: {
|
|
6125
|
+
type: String,
|
|
6126
|
+
default: ""
|
|
6127
|
+
},
|
|
6128
|
+
height: {
|
|
6129
|
+
type: Number,
|
|
6130
|
+
default: ""
|
|
6131
|
+
},
|
|
6132
|
+
width: {
|
|
6133
|
+
type: Number,
|
|
6134
|
+
default: ""
|
|
6135
|
+
}
|
|
6136
|
+
},
|
|
6137
|
+
emits: [],
|
|
6138
|
+
setup(prop, _context) {
|
|
6139
|
+
const uuid = ref(UUID());
|
|
6140
|
+
let player;
|
|
6141
|
+
const initVideo = async () => {
|
|
6142
|
+
const res = await axios.post("https://open.ys7.com/api/lapp/v2/live/address/get", void 0, {
|
|
6143
|
+
params: {
|
|
6144
|
+
accessToken: prop.token,
|
|
6145
|
+
deviceSerial: prop.cameraId,
|
|
6146
|
+
channelNo: prop.channelNo || 1
|
|
6147
|
+
}
|
|
6148
|
+
});
|
|
6149
|
+
const opt = {
|
|
6150
|
+
id: `cloudVideo_${uuid.value}`,
|
|
6151
|
+
url: res.data.data.url,
|
|
6152
|
+
accessToken: prop.token,
|
|
6153
|
+
template: "6298aca808d643fb99f481f2db5bf6a2",
|
|
6154
|
+
height: 300
|
|
6155
|
+
};
|
|
6156
|
+
if (prop.template) {
|
|
6157
|
+
opt.template = prop.template;
|
|
6158
|
+
}
|
|
6159
|
+
if (prop.width) {
|
|
6160
|
+
opt.width = prop.width;
|
|
6161
|
+
}
|
|
6162
|
+
if (prop.template) {
|
|
6163
|
+
opt.height = prop.height;
|
|
6164
|
+
}
|
|
6165
|
+
player = new EZUIKit.EZUIKitPlayer(opt);
|
|
6166
|
+
};
|
|
6167
|
+
onMounted(() => {
|
|
6168
|
+
initVideo();
|
|
6169
|
+
});
|
|
6170
|
+
onBeforeUnmount(() => {
|
|
6171
|
+
player?.stop();
|
|
6172
|
+
});
|
|
6173
|
+
return () => createVNode("div", {
|
|
6174
|
+
"class": "cloudVideo"
|
|
6175
|
+
}, [createVNode("div", {
|
|
6176
|
+
"id": `cloudVideo_${uuid.value}`
|
|
6177
|
+
}, null)]);
|
|
6178
|
+
}
|
|
6179
|
+
});
|
|
6180
|
+
var cloudVideo = installComponent(CloudVideo, "cloud-video");
|
|
6181
|
+
|
|
6182
|
+
export { alarmVideo as AlarmVideo, cloudVideo as CloudVideo, pollingPlay as PollingPlay, videoBox as VideoBox, videoPlayerV1 as VideoPlayerV1, videoPlayerV2 as VideoPlayerV2, VideoBoxV2$1 as videoBoxV2 };
|
package/dist/video/style.css
CHANGED
|
@@ -1,2 +1,3 @@
|
|
|
1
1
|
.playVideos{display:flex;flex-direction:column;height:100%;padding-left:20px}.playVideos .operate{display:flex;justify-content:space-between;margin:5px 0}.playVideos .operate .button{cursor:pointer}.playVideos .grid{display:grid;flex:1;overflow:hidden}.playVideos .grid .video{background:#000;border:1px solid hsla(216,7%,59%,.3);height:100%;object-fit:fill;overflow:hidden;width:100%}.playVideos .grid.full{height:100%;left:0;position:fixed;top:0;width:100%;z-index:10}.playVideos .type1{grid-template-columns:1fr;grid-template-rows:1fr}.playVideos .type4{grid-template-columns:1fr 1fr;grid-template-rows:1fr 1fr}.playVideos .type8{grid-template-columns:1fr 1fr 1fr 1fr;grid-template-rows:1fr 1fr 1fr 1fr}.playVideos .type8 .video:first-child{grid-column:1/4;grid-row:1/4}.playVideos .type9{grid-template-columns:1fr 1fr 1fr;grid-template-rows:1fr 1fr 1fr}.playVideos .type13{grid-template-columns:1fr 1fr 1fr 1fr;grid-template-rows:1fr 1fr 1fr 1fr}.playVideos .type13 .video:first-child{grid-column:1/3;grid-row:1/3}.playVideos .type16{grid-template-columns:1fr 1fr 1fr 1fr;grid-template-rows:1fr 1fr 1fr 1fr}@keyframes moveBottom{0%{bottom:0}to{bottom:-66px}}.videoComponent{background:#000;height:100%;position:relative;width:100%}.videoComponent.fill{object-fit:fill}.videoComponent.contain{object-fit:contain}.videoBox{height:100%;overflow:hidden;position:relative}.videoBox.alarm:before{border:2px solid #ea5858;box-shadow:inset 0 0 10px 8px rgba(234,88,88,.5);content:"";height:100%;pointer-events:none;position:absolute;top:0;width:100%;z-index:7}.videoBox:hover .selectFields{animation-duration:1s;animation-fill-mode:both;animation-name:moveBottom}.videoBox:hover .footer-min{display:flex}.videoBox:hover .footer-min .name-min span,.videoBox:hover .footer-min .tool{display:block}.videoBox .selectFields{background:rgba(0,0,0,.3);bottom:0;display:grid;grid-template-columns:1fr 1fr 1fr;grid-template-rows:1fr 1fr;height:66px;position:absolute;width:100%}.videoBox .selectFields .info{border:0;color:#fff;line-height:33px;overflow:hidden;padding:0 5px;text-align:center;text-overflow:ellipsis;white-space:nowrap}.videoBox .selectFields .info .value{font-size:15px;font-weight:600;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.videoBox .footer-min{align-items:center;backdrop-filter:blur(10px);background:hsla(0,0%,100%,.04);border-radius:4px 4px 0 0;bottom:0;display:none;height:44px;justify-content:space-between;position:absolute;width:100%}.videoBox .footer-min .name-min{align-items:center;display:flex;padding-left:15px}.videoBox .footer-min .name-min span{color:#fff;display:none;font-size:16px;font-weight:600}.videoBox .footer-min .tool{display:none}.videoBox .footer-min .tool img{cursor:pointer;height:20px;margin-right:15px;width:20px}.videoControls{align-items:center;display:flex;flex-direction:column;width:100%}.videoControls .videoControl{height:126px;position:relative;width:126px}.videoControls .videoControl .bg{height:100%;position:relative;width:100%}.videoControls .videoControl img{cursor:pointer;position:absolute}.videoControls .videoControl .up{left:52px;top:14px}.videoControls .videoControl .lup{left:26px;top:26px;transform:rotate(-45deg)}.videoControls .videoControl .rup{left:78px;top:27px;transform:rotate(45deg)}.videoControls .videoControl .left{left:14px;top:52px;transform:rotate(-90deg)}.videoControls .videoControl .right{left:90px;top:52px;transform:rotate(90deg)}.videoControls .videoControl .ldown{left:26px;top:78px;transform:rotate(215deg)}.videoControls .videoControl .down{left:52px;top:90px;transform:rotate(180deg)}.videoControls .videoControl .rdown{left:78px;top:78px;transform:rotate(135deg)}.videoControls .btns{background:#e0e7f2;border-radius:19px;height:28px;margin:8px 8px 0;padding:3px;width:56px}.videoControls .btns img{cursor:pointer;margin-right:1px}
|
|
2
|
-
.videoAlarmDia.dark{background:linear-gradient(90deg,#3e7eff,#1e4e75 30%,#1e4e75 70%,#3e7eff);padding:1px}.videoAlarmDia.dark .ant-modal-close{color:#fff}.videoAlarmDia.dark .ant-modal-header{background-color:#22396f;border-bottom-color:transparent;padding-left:20px}.videoAlarmDia.dark .ant-modal-header .ant-modal-title{align-items:center;background-image:linear-gradient(90deg,#2852a8 0,rgba(40,82,168,0) 50%);color:#fff;display:flex;height:42px;padding-left:10px}.videoAlarmDia.dark .ant-modal-content{background-color:#22396f}.videoAlarmDia.dark .ant-modal-content .body,.videoAlarmDia.dark .ant-modal-content .body .alarmList .alarm .name,.videoAlarmDia.dark .ant-modal-content .body .alarmList .title,.videoAlarmDia.dark .ant-modal-content .body .themeImg{color:#fff}.videoAlarmDia.dark .ant-modal-content .body .tabs .tabContainer .allTab .tab{background:#ffffff1a;color:#fff}.videoAlarmDia.dark .ant-modal-content .body .tabs .tabContainer .allTab .tab.active{background:#3e7eff;color:#fff}.videoAlarmDia .ant-modal-body{padding-top:18px}.videoAlarmDia .body{display:flex;flex-direction:column;height:660px}.videoAlarmDia .body .title{color:#000;font-size:18px}.videoAlarmDia .body .themeImg{height:18px;margin-right:5px;width:18px}.videoAlarmDia .body .current{align-self:center;display:flex;height:400px;justify-content:center;margin:10px 0 25px;width:750px}.videoAlarmDia .body .current .grid{grid-gap:3px;background-color:transparent;display:grid;height:100%;overflow:hidden;width:100%}.videoAlarmDia .body .current .grid .videoBox{background-color:#000}.videoAlarmDia .body .alarmList{display:flex;flex-wrap:wrap;justify-content:flex-start;max-height:80px;overflow:auto}.videoAlarmDia .body .alarmList .title{font-size:14px;font-weight:600;margin-bottom:10px}.videoAlarmDia .body .alarmList .alarm{align-items:center;border-radius:5px;color:#000;cursor:pointer;height:24px;margin-bottom:10px;margin-right:10px;padding:5px}.videoAlarmDia .body .alarmList .alarm img{height:16px;margin-right:5px;width:16px}.videoAlarmDia .body .alarmList .alarm .name{font-size:14px;white-space:nowrap}.videoAlarmDia .body .alarmList .alarm1{background:rgba(234,88,88,.1);color:#354052}.videoAlarmDia .body .alarmList .alarm2{background:rgba(255,146,20,.1);color:#354052}.videoAlarmDia .body .alarmList .alarm3{background:rgba(255,196,20,.1);color:#354052}.videoAlarmDia .body .alarmList .alarm4{background:rgba(62,126,255,.1);color:#354052}.videoAlarmDia .body .tip{align-items:center;display:flex;margin:0}.videoAlarmDia .body .tip .sumNum{margin-right:16px}.videoAlarmDia .body .tip .timeNum{color:#3e7eff;font-weight:600;margin-right:5px}.videoAlarmDia .body .tabs{align-items:center;display:flex;margin:10px 0 5px}.videoAlarmDia .body .tabs .themeImg{cursor:pointer;overflow:visible}.videoAlarmDia .body .tabs .endIcon{margin-left:10px}.videoAlarmDia .body .tabs .tabContainer{display:flex;overflow:hidden}.videoAlarmDia .body .tabs .tabContainer .allTab{display:flex;height:40px;left:0;position:relative}.videoAlarmDia .body .tabs .tabContainer .allTab .tab{background:#f2f3f8;border-radius:4px;cursor:pointer;font-size:14px;height:32px;line-height:32px;margin-right:10px;padding:0 10px;position:relative;text-align:center;white-space:nowrap}.videoAlarmDia .body .tabs .tabContainer .allTab .tab.active{background:#1d33a2;color:#fff}.videoAlarmDia .body .tabs .tabContainer .allTab .tab.active:after{border:10px solid transparent;border-top-color:#1d33a2;content:"";height:0;left:50%;position:absolute;top:30px;width:0}.videoAlarmDia .body .numLine{align-items:center;display:flex}.videoAlarmDia .body .numLine .cameraNum{color:#3e7eff;font-weight:600}.videoAlarmDia .body .numLine .tipImg{height:18px;margin:0 5px 0 25px;width:18px}.videoAlarmDia .body .numLine .alarmNum{color:#fa4141;font-weight:600}.videoAlarmDia .body .otherAlarm{align-items:center;display:flex}.videoAlarmDia .body .otherAlarm .ant-tag{cursor:pointer;font-size:14px}.videoAlarmDia .body .otherAlarm .tipImg{height:18px;margin-right:5px;width:18px}.videoAlarmDia .body .otherAlarm .annotation{height:12px;margin:2px;width:12px}.videoAlarmDia .body .type1{grid-template-columns:1fr;grid-template-rows:1fr}.videoAlarmDia .body .type4{grid-template-columns:1fr 1fr;grid-template-rows:1fr 1fr}.videoAlarmDia .body .type8{grid-template-columns:1fr 1fr 1fr 1fr;grid-template-rows:1fr 1fr 1fr 1fr}.videoAlarmDia .body .type8 .videoBox:first-child{grid-column:1/4;grid-row:1/4}.videoAlarmDia .body .type9{grid-template-columns:1fr 1fr 1fr;grid-template-rows:1fr 1fr 1fr}.videoAlarmDia .body .type13{grid-template-columns:1fr 1fr 1fr 1fr;grid-template-rows:1fr 1fr 1fr 1fr}.videoAlarmDia .body .type13 .videoBox:first-child{grid-column:1/3;grid-row:1/3}.videoAlarmDia .body .type16{grid-template-columns:1fr 1fr 1fr 1fr;grid-template-rows:1fr 1fr 1fr 1fr}
|
|
2
|
+
.videoAlarmDia.dark{background:linear-gradient(90deg,#3e7eff,#1e4e75 30%,#1e4e75 70%,#3e7eff);padding:1px}.videoAlarmDia.dark .ant-modal-close{color:#fff}.videoAlarmDia.dark .ant-modal-header{background-color:#22396f;border-bottom-color:transparent;padding-left:20px}.videoAlarmDia.dark .ant-modal-header .ant-modal-title{align-items:center;background-image:linear-gradient(90deg,#2852a8 0,rgba(40,82,168,0) 50%);color:#fff;display:flex;height:42px;padding-left:10px}.videoAlarmDia.dark .ant-modal-content{background-color:#22396f}.videoAlarmDia.dark .ant-modal-content .body,.videoAlarmDia.dark .ant-modal-content .body .alarmList .alarm .name,.videoAlarmDia.dark .ant-modal-content .body .alarmList .title,.videoAlarmDia.dark .ant-modal-content .body .themeImg{color:#fff}.videoAlarmDia.dark .ant-modal-content .body .tabs .tabContainer .allTab .tab{background:#ffffff1a;color:#fff}.videoAlarmDia.dark .ant-modal-content .body .tabs .tabContainer .allTab .tab.active{background:#3e7eff;color:#fff}.videoAlarmDia .ant-modal-body{padding-top:18px}.videoAlarmDia .body{display:flex;flex-direction:column;height:660px}.videoAlarmDia .body .title{color:#000;font-size:18px}.videoAlarmDia .body .themeImg{height:18px;margin-right:5px;width:18px}.videoAlarmDia .body .current{align-self:center;display:flex;height:400px;justify-content:center;margin:10px 0 25px;width:750px}.videoAlarmDia .body .current .grid{grid-gap:3px;background-color:transparent;display:grid;height:100%;overflow:hidden;width:100%}.videoAlarmDia .body .current .grid .videoBox{background-color:#000}.videoAlarmDia .body .alarmList{display:flex;flex-wrap:wrap;justify-content:flex-start;max-height:80px;overflow:auto}.videoAlarmDia .body .alarmList .title{font-size:14px;font-weight:600;margin-bottom:10px}.videoAlarmDia .body .alarmList .alarm{align-items:center;border-radius:5px;color:#000;cursor:pointer;height:24px;margin-bottom:10px;margin-right:10px;padding:5px}.videoAlarmDia .body .alarmList .alarm img{height:16px;margin-right:5px;width:16px}.videoAlarmDia .body .alarmList .alarm .name{font-size:14px;white-space:nowrap}.videoAlarmDia .body .alarmList .alarm1{background:rgba(234,88,88,.1);color:#354052}.videoAlarmDia .body .alarmList .alarm2{background:rgba(255,146,20,.1);color:#354052}.videoAlarmDia .body .alarmList .alarm3{background:rgba(255,196,20,.1);color:#354052}.videoAlarmDia .body .alarmList .alarm4{background:rgba(62,126,255,.1);color:#354052}.videoAlarmDia .body .tip{align-items:center;display:flex;margin:0}.videoAlarmDia .body .tip .sumNum{margin-right:16px}.videoAlarmDia .body .tip .timeNum{color:#3e7eff;font-weight:600;margin-right:5px}.videoAlarmDia .body .tabs{align-items:center;display:flex;margin:10px 0 5px}.videoAlarmDia .body .tabs .themeImg{cursor:pointer;overflow:visible}.videoAlarmDia .body .tabs .endIcon{margin-left:10px}.videoAlarmDia .body .tabs .tabContainer{display:flex;overflow:hidden}.videoAlarmDia .body .tabs .tabContainer .allTab{display:flex;height:40px;left:0;position:relative}.videoAlarmDia .body .tabs .tabContainer .allTab .tab{background:#f2f3f8;border-radius:4px;cursor:pointer;font-size:14px;height:32px;line-height:32px;margin-right:10px;padding:0 10px;position:relative;text-align:center;white-space:nowrap}.videoAlarmDia .body .tabs .tabContainer .allTab .tab.active{background:#1d33a2;color:#fff}.videoAlarmDia .body .tabs .tabContainer .allTab .tab.active:after{border:10px solid transparent;border-top-color:#1d33a2;content:"";height:0;left:50%;position:absolute;top:30px;width:0}.videoAlarmDia .body .numLine{align-items:center;display:flex}.videoAlarmDia .body .numLine .cameraNum{color:#3e7eff;font-weight:600}.videoAlarmDia .body .numLine .tipImg{height:18px;margin:0 5px 0 25px;width:18px}.videoAlarmDia .body .numLine .alarmNum{color:#fa4141;font-weight:600}.videoAlarmDia .body .otherAlarm{align-items:center;display:flex}.videoAlarmDia .body .otherAlarm .ant-tag{cursor:pointer;font-size:14px}.videoAlarmDia .body .otherAlarm .tipImg{height:18px;margin-right:5px;width:18px}.videoAlarmDia .body .otherAlarm .annotation{height:12px;margin:2px;width:12px}.videoAlarmDia .body .type1{grid-template-columns:1fr;grid-template-rows:1fr}.videoAlarmDia .body .type4{grid-template-columns:1fr 1fr;grid-template-rows:1fr 1fr}.videoAlarmDia .body .type8{grid-template-columns:1fr 1fr 1fr 1fr;grid-template-rows:1fr 1fr 1fr 1fr}.videoAlarmDia .body .type8 .videoBox:first-child{grid-column:1/4;grid-row:1/4}.videoAlarmDia .body .type9{grid-template-columns:1fr 1fr 1fr;grid-template-rows:1fr 1fr 1fr}.videoAlarmDia .body .type13{grid-template-columns:1fr 1fr 1fr 1fr;grid-template-rows:1fr 1fr 1fr 1fr}.videoAlarmDia .body .type13 .videoBox:first-child{grid-column:1/3;grid-row:1/3}.videoAlarmDia .body .type16{grid-template-columns:1fr 1fr 1fr 1fr;grid-template-rows:1fr 1fr 1fr 1fr}
|
|
3
|
+
.cloudVideo{height:100%;width:100%}
|
|
@@ -4507,7 +4507,7 @@ class WebRtcMt {
|
|
|
4507
4507
|
}
|
|
4508
4508
|
}
|
|
4509
4509
|
}
|
|
4510
|
-
retryTime;
|
|
4510
|
+
// protected retryTime;
|
|
4511
4511
|
// 拉流创建播放器
|
|
4512
4512
|
createVideo(plays) {
|
|
4513
4513
|
this.mediaServerAddrMap.set(plays.videoElm, plays);
|
|
@@ -4518,7 +4518,6 @@ class WebRtcMt {
|
|
|
4518
4518
|
fetch(addRtspProxyUrl, {
|
|
4519
4519
|
method: "GET"
|
|
4520
4520
|
}).then(response => {
|
|
4521
|
-
this.retryTime = 0;
|
|
4522
4521
|
response.json().then(res => {
|
|
4523
4522
|
if (res.code === 0) {
|
|
4524
4523
|
this.startPlay(plays);
|
|
@@ -4530,12 +4529,9 @@ class WebRtcMt {
|
|
|
4530
4529
|
}
|
|
4531
4530
|
});
|
|
4532
4531
|
}).catch(err => {
|
|
4533
|
-
|
|
4534
|
-
this.
|
|
4535
|
-
|
|
4536
|
-
this.rePlay();
|
|
4537
|
-
}, 60 * 1e3);
|
|
4538
|
-
}
|
|
4532
|
+
setTimeout(() => {
|
|
4533
|
+
this.rePlay();
|
|
4534
|
+
}, 3 * 60 * 1e3);
|
|
4539
4535
|
});
|
|
4540
4536
|
});
|
|
4541
4537
|
}
|
|
@@ -4594,7 +4590,7 @@ class WebRtcMt {
|
|
|
4594
4590
|
this.stopPlay();
|
|
4595
4591
|
setTimeout(() => {
|
|
4596
4592
|
this.init(this.opt);
|
|
4597
|
-
}, 1e3);
|
|
4593
|
+
}, 5 * 1e3);
|
|
4598
4594
|
}
|
|
4599
4595
|
// 播放
|
|
4600
4596
|
play(videoElm) {
|
|
@@ -4788,9 +4784,9 @@ const VideoPlayerV2 = vue.defineComponent({
|
|
|
4788
4784
|
});
|
|
4789
4785
|
vue.onBeforeUnmount(() => {
|
|
4790
4786
|
stopPlay();
|
|
4791
|
-
|
|
4792
|
-
const videoElement = document.getElementById(uuid);
|
|
4787
|
+
const videoElement = document.getElementById(`videoPlayer_${uuid}`);
|
|
4793
4788
|
if (videoElement) {
|
|
4789
|
+
videoElement.pause();
|
|
4794
4790
|
videoElement.src = null;
|
|
4795
4791
|
videoElement.srcObject = null;
|
|
4796
4792
|
videoElement.remove();
|
|
@@ -4499,7 +4499,7 @@ class WebRtcMt {
|
|
|
4499
4499
|
}
|
|
4500
4500
|
}
|
|
4501
4501
|
}
|
|
4502
|
-
retryTime;
|
|
4502
|
+
// protected retryTime;
|
|
4503
4503
|
// 拉流创建播放器
|
|
4504
4504
|
createVideo(plays) {
|
|
4505
4505
|
this.mediaServerAddrMap.set(plays.videoElm, plays);
|
|
@@ -4510,7 +4510,6 @@ class WebRtcMt {
|
|
|
4510
4510
|
fetch(addRtspProxyUrl, {
|
|
4511
4511
|
method: "GET"
|
|
4512
4512
|
}).then(response => {
|
|
4513
|
-
this.retryTime = 0;
|
|
4514
4513
|
response.json().then(res => {
|
|
4515
4514
|
if (res.code === 0) {
|
|
4516
4515
|
this.startPlay(plays);
|
|
@@ -4522,12 +4521,9 @@ class WebRtcMt {
|
|
|
4522
4521
|
}
|
|
4523
4522
|
});
|
|
4524
4523
|
}).catch(err => {
|
|
4525
|
-
|
|
4526
|
-
this.
|
|
4527
|
-
|
|
4528
|
-
this.rePlay();
|
|
4529
|
-
}, 60 * 1e3);
|
|
4530
|
-
}
|
|
4524
|
+
setTimeout(() => {
|
|
4525
|
+
this.rePlay();
|
|
4526
|
+
}, 3 * 60 * 1e3);
|
|
4531
4527
|
});
|
|
4532
4528
|
});
|
|
4533
4529
|
}
|
|
@@ -4586,7 +4582,7 @@ class WebRtcMt {
|
|
|
4586
4582
|
this.stopPlay();
|
|
4587
4583
|
setTimeout(() => {
|
|
4588
4584
|
this.init(this.opt);
|
|
4589
|
-
}, 1e3);
|
|
4585
|
+
}, 5 * 1e3);
|
|
4590
4586
|
}
|
|
4591
4587
|
// 播放
|
|
4592
4588
|
play(videoElm) {
|
|
@@ -4780,9 +4776,9 @@ const VideoPlayerV2 = defineComponent({
|
|
|
4780
4776
|
});
|
|
4781
4777
|
onBeforeUnmount(() => {
|
|
4782
4778
|
stopPlay();
|
|
4783
|
-
|
|
4784
|
-
const videoElement = document.getElementById(uuid);
|
|
4779
|
+
const videoElement = document.getElementById(`videoPlayer_${uuid}`);
|
|
4785
4780
|
if (videoElement) {
|
|
4781
|
+
videoElement.pause();
|
|
4786
4782
|
videoElement.src = null;
|
|
4787
4783
|
videoElement.srcObject = null;
|
|
4788
4784
|
videoElement.remove();
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "inl-ui",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.23",
|
|
4
4
|
"description": "工业 pc ui库",
|
|
5
5
|
"main": "dist/index.cjs",
|
|
6
6
|
"module": "dist/index.js",
|
|
@@ -29,6 +29,8 @@
|
|
|
29
29
|
"dependencies": {
|
|
30
30
|
"@sszj-temp/mobile": "^0.0.104",
|
|
31
31
|
"@vueuse/core": "^9.6.0",
|
|
32
|
+
"ezuikit-flv": "^1.0.1",
|
|
33
|
+
"ezuikit-js": "^8.0.2",
|
|
32
34
|
"marked": "^9.1.6",
|
|
33
35
|
"vite-plugin-qiankun": "^1.0.15",
|
|
34
36
|
"vue": "^3.2.45"
|