# ValScheManagePopup 赛程管理弹窗
# 引入
import PressValScheManagePopup from '@tencent/press-next/press-val-sche-manage-popup/press-val-sche-manage-popup';
# 代码演示
# 基础用法
<PressValScheManagePopup
:show="dialogData.valScheManagePopup.show"
:operation="dialogData.valScheManagePopup.operation"
@cancel="()=>dialogData.valScheManagePopup.show=false"
@resetMatch="dialogData.valScheManagePopup.resetMatch"
@startGame="dialogData.valScheManagePopup.startGame"
@changeScore="dialogData.valScheManagePopup.changeScore"
/>
const dialogData = ref({
valScheManagePopup: {
show: false,
operation: {
info: {
leftTeamScore: 1,
rightTeamScore: 2,
title: '2进1 BO3',
statusDesc: '已结束',
leftTeamAvatar: '',
leftTeamName: '队伍1',
rightTeamAvatar: '',
rightTeamName: '队伍2',
},
},
changeScore() {
console.log('[changeScore]');
},
startGame() {
console.log('[startGame]');
},
resetMatch() {
console.log('[resetMatch]');
},
},
});
# API
# Props
defineProps({
show: {
type: Boolean,
},
operation: {
type: Object,
default: () => ({}),
},
});
# Events
const emits = defineEmits<{
cancel: [],
resetMatch: [],
changeScore: [],
startGame: [],
}>();