<template>
    <div class="title-box flex justify-between mb20">
        <p class="title">내 사진첩</p>
    </div>
    <div class="myphoto mb30">
        <div class="title-box flex justify-end mb40">
            <select name="" id="">
                <option value="">A반</option>
            </select>
        </div>
        <div class="btnGroup">
            <button @click="selectedTab = 'tab1'" type="button" title="글쓰기" class="tab-btn">
                <img v-if="selectedTab !== 'tab1'" src="../../../resources/img/btn49_15s_normal.png" alt="">
                <img v-else src="../../../resources/img/btn49_15s_click.png" alt="">
                <p :class="{ 'custom-style': selectedTab === 'tab1' }">1</p>
            </button>
        </div>
        <div v-if="selectedTab === 'tab1'" class="tab-box">
            <div class="class photo">
                <div class="box gd-col2" style="gap: 10px;" @click="goToPage('ClassDetail')">
                    <div><img src="../../../resources/img/img210_15s.png" alt=""></div>
                </div>
                <div class="text flex justify-between mt20">
                    <p class="title1">A반</p>
                    <span class="member">20명</span>
                </div>
               
            </div>

        </div>
    </div>
</template>

<script>
import SvgIcon from '@jamescoyle/vue-icon';
import { mdiMagnify, } from '@mdi/js';
import { mdilArrowRight } from '@mdi/light-js';
import ProgressBar from '../../component/ProgressBar.vue';


export default {
    data() {
        return {
            selectedTab: 'tab1',
            mdiMagnify: mdiMagnify,
            mdilArrowRight: mdilArrowRight,
            timer: "00:00",
            progress: 20
        }
    },
    methods: {
        goToPage(page) {
            this.$router.push({ name: page });
        },
        increaseProgress() {
            if (this.progress < 100) {
                this.progress += 10;
            }
        },
        showConfirm(type) {
            let message = '';
            if (type === 'cancel') {
                message = '삭제하시겠습니까?';
            } else if (type === 'reset') {
                message = '초기화하시겠습니까?';
            } else if (type === 'save') {
                message = '등록하시겠습니까?';
            }

            if (confirm(message)) {
                this.goBack();
            }
        },
    },
    watch: {

    },
    computed: {

    },
    components: {
        SvgIcon,
        ProgressBar
    },
    mounted() {
        console.log('Main2 mounted');
    }
}
</script>