|
|
@@ -8,18 +8,18 @@
|
|
|
<!-- 测试抓拍使用 -->
|
|
|
<!-- <button @click="handleZhua">抓拍</button> -->
|
|
|
</view>
|
|
|
- <span v-show="showVideo" @click="noShowVideoBtn" class="shiti-video-hidden-btn"><i></i></span>
|
|
|
- <span v-show="!showVideo" @click="showVideoBtn" class="shiti-video-show-btn"><i></i></span>
|
|
|
+ <view v-show="showVideo" @click="noShowVideoBtn" class="shiti-video-hidden-btn">
|
|
|
+ <icon :style="{ backgroundImage: 'url(' + iconsArr.videoCloseIcon + ')' }"></icon>
|
|
|
+ </view>
|
|
|
+ <view v-show="!showVideo" @click="showVideoBtn" class="shiti-video-show-btn">
|
|
|
+ <icon :style="{ backgroundImage: 'url(' + iconsArr.videoPlayIcon + ')' }"></icon>
|
|
|
+ </view>
|
|
|
</view>
|
|
|
</template>
|
|
|
|
|
|
<script setup>
|
|
|
- import {
|
|
|
- ref,
|
|
|
- onUnmounted,
|
|
|
- nextTick,
|
|
|
- computed,
|
|
|
- } from "vue";
|
|
|
+ import {ref,onUnmounted,nextTick,computed,onMounted,reactive} from "vue";
|
|
|
+ import cacheManager from '@/utils/cacheManager.js';
|
|
|
import * as ksApi from "@/api/kaoshi.js"
|
|
|
import {
|
|
|
getStaticUrl
|
|
|
@@ -30,7 +30,7 @@
|
|
|
|
|
|
const zhuapaiStore = useZhuapaiStore();
|
|
|
|
|
|
- const imgUrl = getStaticUrl('static/images/exam/nokaoshi.png')
|
|
|
+ const imgUrl = '';
|
|
|
|
|
|
const cameraContext = ref(null);
|
|
|
|
|
|
@@ -45,10 +45,15 @@
|
|
|
|
|
|
const stopTimer = ref(null);
|
|
|
const style = ref({
|
|
|
- top: "10vh",
|
|
|
+ top: "17vh",
|
|
|
right: "0",
|
|
|
});
|
|
|
|
|
|
+ const iconsArr = reactive({
|
|
|
+ noKaoshiImg: '',
|
|
|
+ videoCloseIcon: '',
|
|
|
+ videoPlayIcon: '',
|
|
|
+ })
|
|
|
const myClass = computed(() => {
|
|
|
return {
|
|
|
'show-video': showVideo.value,
|
|
|
@@ -274,7 +279,10 @@
|
|
|
console.log('结束')
|
|
|
}, 10 * 1000)
|
|
|
}
|
|
|
-
|
|
|
+ onMounted(() => {
|
|
|
+ iconsArr.videoCloseIcon = cacheManager.get('projectImg').video_close_icon;
|
|
|
+ iconsArr.videoPlayIcon = cacheManager.get('projectImg').video_play_icon;
|
|
|
+ });
|
|
|
defineExpose({
|
|
|
init,
|
|
|
showVideoBtn
|
|
|
@@ -319,7 +327,7 @@
|
|
|
position: absolute;
|
|
|
top: 0;
|
|
|
|
|
|
- i {
|
|
|
+ icon{
|
|
|
width: 32rpx;
|
|
|
height: 32rpx;
|
|
|
display: block;
|
|
|
@@ -334,8 +342,7 @@
|
|
|
height: 60rpx;
|
|
|
left: 0;
|
|
|
|
|
|
- i {
|
|
|
- background-image: url("@/static/images/exam/video-close-icon.svg");
|
|
|
+ icon {
|
|
|
margin: 6rpx auto 6rpx 6rpx;
|
|
|
}
|
|
|
}
|
|
|
@@ -345,10 +352,6 @@
|
|
|
padding: 20rpx;
|
|
|
border-radius: 8rpx;
|
|
|
right: 0;
|
|
|
-
|
|
|
- i {
|
|
|
- background-image: url("@/static/images/exam/video-play-icon.svg");
|
|
|
- }
|
|
|
}
|
|
|
}
|
|
|
</style>
|