<template>
    <div class="bck">
        <div class="context">
            <div class="title">
                <div
                    :class="active == 'a' ? 'title_check' : 'title_nocheck'"
                    @click="chooseTag('a')"
                >
                    <div>研学成果量</div>
                    <div class="blue_div"></div>
                </div>
                <div
                    :class="active == 'b' ? 'title_check' : 'title_nocheck'"
                    @click="chooseTag('b')"
                >
                    <div>成果浏览量</div>
                    <div class="blue_div"></div>
                </div>
            </div>

            <div class="table_title titleFont">
                <div class="title_1">排名</div>
                <div class="title_2">
                    <div class="title_2_2">学校名称</div>
                    <div class="title_2_3">数量</div>
                </div>
            </div>

            <div class="table_title conFont" v-for="(v,i) in rankList" :key="i">
                <div class="title_1" v-if="i == 0">
                    <img src="@/assets/rank/1.png" />
                </div>
                <div class="title_1" v-if="i == 1">
                    <img src="@/assets/rank/2.png" />
                </div>
                <div class="title_1" v-if="i == 2">
                    <img src="@/assets/rank/3.png" />
                </div>
                <div class="title_1" v-if="i > 2">{{i +1}}</div>
                <div class="title_2">
                    <div class="title_2_2">柯桥中学</div>
                    <div class="title_2_3">120</div>
                </div>
            </div>
        </div>

        <tabbar4 active="rank"></tabbar4>
    </div>
</template>

<script>
import Tabbar4 from "@/component/Tabbar4";
export default {
    components: { Tabbar4 },
    data() {
        return {
            active: "a",
            rankList: []
        };
    },
    methods: {
        chooseTag(val) {
            this.active = val;
        },
    },
};
</script>

<style lang="scss" scoped>
.bck {
    position: absolute;
    width: 100vw;
    height: 100vh;
    background-image: url("../../assets/rank/blue_rank.png");
    -moz-background-size: 100% 100%;
    background-size: 100% 100%;

    .context {
        width: 100vw;
        min-height: 1100px;
        background-color: #fff;
        margin-top: 310px;
        border-radius: 80px;
        padding: 2vw 5vw;
        box-sizing: border-box;

        .title {
            width: 90%;
            height: 100px;
            margin-top: 40px;
            display: flex;
            align-items: center;

            .title_check {
                font-size: 5vw;
                color: #333333;
                margin: 0 3vw;
                font-weight: 800;

                .blue_div {
                    width: 50px;
                    height: 15px;
                    border-radius: 10px;
                    margin-left: 10vw;
                    margin-top: 20px;
                    background-color: #0b91f3;
                }
            }
            .title_nocheck {
                font-size: 4.2vw;
                color: #999999;
                margin: 0 3vw;

                .blue_div {
                    width: 50px;
                    height: 15px;
                    border-radius: 10px;
                    margin-left: 10vw;
                    margin-top: 20px;
                    background-color: #fff;
                }
            }
        }

        .table_title {
            width: 100%;
            height: 110px;
            margin-top: 25px;
            padding: 20px 3vw 3vw 0;
            box-sizing: border-box;
            display: flex;
            justify-content: space-between;
            align-items: center;

            .title_1 {
                width: 15%;
                text-align: center;

                img {
                    width: 55px;
                    height: 70px;
                }
            }
            .title_2 {
                width: 70%;
                display: flex;
                justify-content: space-between;

                .title_2_3{
                    width: 10vw;
                    text-align: left;
                }
            }
        }
        .titleFont {
            font-size: 4.5vw;
            color: #999999;
        }
        .conFont {
            font-size: 4.45vw;
            color: #333333;
        }
    }
}
</style>