<template>
    <van-dialog
        v-model:show="show"
        theme="round-button"
        confirm-button-text="直接进入"
        @confirm="confirm"
        @cancel="cancel"
    >
        <div class="dialog-title">
            <img src="@assets/icon-lijibaoming.png" alt="" />
            <span>请选择进入游戏的方式</span>
        </div>
    </van-dialog>
</template>

<script>
import room from '../../mixins/room.js';
export default {
    mixins: [room],
    props: {
        roomInfo: {
            type: Object,
            default: () => {
                return {};
            }
        }
    },
    computed: {
        requireTicketInfo() {
            let info = [...this.requireTicketOptions].find(item => {
                return item.value === this.roomInfo.requireTicket;
            });
            return info ? info : {};
        }
    },
    data() {
        return {
            show: false,
            message: ''
        };
    },
    methods: {
        init(url = '') {
            this.show = true;
        },
        confirm() {},
        cancel() {
            this.$router.back();
        }
    }
};
</script>

<style lang="less" scoped>
.dialog-title {
    .flex-col();
    align-items: center;
    padding: 20px 0 24px;
    img {
        width: 48px;
        height: 48px;
    }
    span {
        font-size: 18px;
        font-weight: bold;
        color: #ffffff;
        line-height: 24px;
        margin-top: 12px;
    }
}

.dialog-tips {
    font-size: 14px;
    color: #6a6d83;
    line-height: 20px;
    padding: 0 20px 30px;
}
</style>
