{"version":3,"file":"emigrated.30125f9b.mjs","sources":["../../../../pages/exam/emigrated.vue"],"sourcesContent":["<template>\n  <NuxtLayout>\n    <div class=\"app_container emigrated_content\">\n      <div v-if=\"map.info.id\" class=\"emigrated_info\">\n      <div class=\"emigrated_header\">\n        <div class=\"emigrated_info_content\">\n        <div class=\"emigrated_nav\">\n          <el-breadcrumb :separator-icon=\"ArrowRight\">\n            <el-breadcrumb-item :to=\"{ path: '/' }\"><span class=\"emigrated_nav_title\">首页</span></el-breadcrumb-item>\n            <el-breadcrumb-item :to=\"{ path: '/exam' }\"><span class=\"emigrated_nav_title\">试卷中心</span>\n            </el-breadcrumb-item>\n            <el-breadcrumb-item :to=\"{ path: '/exam/list',query:{categoryId:map.categoryId,practiceType:map.practiceType -1} }\">\n              <span class=\"emigrated_nav_title\">{{ map.categoryName }}</span>\n            </el-breadcrumb-item>\n            <el-breadcrumb-item>\n              <div class=\"emigrated_nav_title tx-ov\">{{ map.info.practiceName }}</div>\n            </el-breadcrumb-item>\n          </el-breadcrumb>\n        </div>\n          <div class=\"emigrated_header_box\">\n            <div class=\"header_box_left\">\n              <div class=\"practice_name\">{{ map.info.practiceName }}</div>\n              <div class=\"box_msg_list\">\n                <div class=\"box_msg_item\">关卡数：共{{map.info.practiceTitleInfoList.length}}关</div>\n                <div class=\"box_msg_item\">每关卡限时：{{map.info.levelLimit}}分钟</div><br>\n                <div class=\"box_msg_item\">闯关成功标准：{{map.info.passPercentage}}%正确率</div>\n                <div class=\"box_msg_item\">每关卡复活机会：{{map.info.resurgenceNum === 0?'不限':'共'+map.info.resurgenceNum+'次'}}</div>\n                <div class=\"box_msg_item\">排行说明：闯关次数最多，用时最短排在最前面</div>\n              </div>\n            </div>\n            <div class=\"header_box_right\">\n              <el-button type=\"primary\" @click=\"handleLearn('')\">{{map.info.userPracticeStatus === 1?'开始闯关':'继续闯关'}}</el-button>\n              <el-button type=\"text\" class=\"mgt10\"><img class=\"mgr6\" src=\"@/assets/paper/rank.svg\"/>排行榜</el-button>\n            </div>\n          </div>\n          <div class=\"table_list\">\n            <div class=\"table_item\" @click=\"handleLearn(item)\" v-for=\"(item,index) in map.info.practiceTitleInfoList\" :key=\"index\">\n              <div class=\"table_item_top lock\"></div>\n              <div class=\"table_item_title\">{{item.titleName}}</div>\n              <div class=\"table_item_msg\">人已闯关成功</div>\n            </div>\n          </div>\n        </div>\n      </div>\n      </div>\n    </div>\n  </NuxtLayout>\n</template>\n\n<script setup>\nimport {ArrowRight} from '@element-plus/icons-vue'\nimport {onMounted, reactive} from \"vue\";\nimport {useUserStore} from \"../../stores/user\";\nimport {getStore} from \"../../utils/storage\";\nimport cookie from '@/utils/cookies'\n\nconst router = useRouter()\nconst route = useRoute()\nconst store = useUserStore()\nconst map = reactive({\n  info:{},\n  categoryId:'',\n  practiceType:4,\n  practiceId:'',\n  categoryName:''\n})\nconst token = computed(()=>store.token)\nconst handleLearn = (data) => {\n  if(token.value){\n    if(!data){\n      data = map.info.practiceTitleInfoList[0]\n    }\n    router.push({\n      path: '/practice/daily',\n      query: {\n        practiceType: map.practiceType,\n        courseId: map.practiceId,\n        titleId:data.id,\n        titleName:data.titleName\n      }\n    })\n  }else{\n    router.push({\n      path: '/login',\n      query: {\n        redirect: encodeURIComponent(route.fullPath)\n      }\n    })\n  }\n}\n\nlet cookieData = cookie.getShop()\nonMounted(()=>{\n  map.info = JSON.parse(getStore('emigratedData') || '{}')\n  useHead({\n    title: map.info.practiceName + '-' + cookieData.shopName\n  });\n  map.categoryId = route.query.categoryId\n  map.categoryName = decodeURIComponent(route.query.categoryName)\n  map.practiceType = +route.query.practiceType\n  map.practiceId = route.query.practiceId\n})\n</script>\n\n<style scoped lang=\"scss\">\n.emigrated_info{}\n.emigrated_info_content{\n  padding: 20px calc((100vw - 1200px) / 2);\n}\n.emigrated_nav {\n  margin-bottom: 20px;\n}\n\n.emigrated_nav_title {\n  color: #999999;\n  font-weight: 400;\n  max-width: 115px;\n}\n.emigrated_header_box{\n  margin-bottom: 20px;\n  padding: 30px;\n  background-color: #FFFFFF;\n  display: flex;\n  justify-content: space-between;\n  align-items: center;\n  .practice_name{\n    font-family: 'Microsoft YaHei';\n    font-style: normal;\n    font-weight: 400;\n    font-size: 22px;\n    line-height: 29px;\n    color: #333333;\n    margin-bottom: 34px;\n  }\n  .box_msg_list{\n    display: flex;\n    align-items: center;\n    flex-direction: row;\n    flex-wrap: wrap;\n  }\n  .box_msg_item{\n    font-style: normal;\n    font-weight: 400;\n    font-size: 14px;\n    color: #666666;\n    margin-right: 50px;\n    margin-bottom: 24px;\n  }\n  .header_box_right{\n    padding:0 53px;\n    display: flex;\n    place-items: center;\n    flex-direction: column;\n  }\n  .header_box_right .el-button.el-button--primary{\n    width: 154px;\n    height: 42px;\n    border-radius: 5px;\n  }\n}\n.table_list{\n  padding: 42px 30px;\n  background-color: #FFFFFF;\n  display: flex;\n  flex-direction: row;\n  flex-wrap: wrap;\n  .table_item{\n    display: flex;\n    align-items: center;\n    flex-direction: column;\n    margin-bottom: 32px;\n    cursor: pointer;\n  }\n  .table_item:has(.lock){\n    cursor: none;\n  }\n  .table_item+.table_item{\n    margin-left: 60px;\n  }\n  .table_item:nth-child(7n+1){\n    margin-left: 0;\n  }\n  .table_item_top{\n    width: 100px;\n    height: 100px;\n    background-image: url(\"~/assets/paper/emigrated_bg.png\");\n    background-size: contain;\n    position: relative;\n    display: flex;\n    align-items: center;\n    justify-content: center;\n  }\n  .table_item_top.lock:before{\n    content: '';\n    position: absolute;\n    width: 44px;\n    height: 44px;\n    background-image: url(\"~/assets/paper/lock.png\");\n    background-size: 100% 100%;\n  }\n  .table_item_top.go:before{\n    content: '';\n    position: absolute;\n    width: 44px;\n    height: 44px;\n    background-image: url(\"~/assets/paper/go.png\");\n    background-size: 100% 100%;\n  }\n  .table_item_top.success:before{\n    content: '';\n    position: absolute;\n    width: 100px;\n    height: 100px;\n    left: 0;\n    top: 0;\n    background: #FFFFFF;\n    opacity: 0.4;\n    z-index: 1;\n  }\n  .table_item_top.success:after{\n    content: '';\n    position: absolute;\n    width: 44px;\n    height: 44px;\n    background-image: url(\"../../assets/paper/success.png\");\n    background-size: 100% 100%;\n    z-index: 2;\n  }\n  .table_item_title{\n    margin-top: 16px;\n    font-style: normal;\n    font-weight: 400;\n    font-size: 16px;\n    color: #333333;\n  }\n  .table_item_msg{\n    font-style: normal;\n    font-weight: 400;\n    font-size: 14px;\n    color: #999999;\n    margin-top: 4px;\n  }\n}\n</style>\n"],"names":["router","useRouter","route","useRoute","store","useUserStore","map","reactive","info","categoryId","practiceType","practiceId","categoryName","token","computed","handleLearn","data","value","practiceTitleInfoList","push","path","query","courseId","titleId","id","titleName","redirect","encodeURIComponent","fullPath","cookieData","cookie","getShop","onMounted","JSON","parse","getStore","useHead","title","practiceName","shopName","decodeURIComponent"],"mappings":"gzCAwDA,MAAAA,EAAAC,IACAC,EAAAC,IACAC,EAAAC,IACAC,EAAAC,EAAA,CACAC,KAAA,CAAA,EACAC,WAAA,GACAC,aAAA,EACAC,WAAA,GACAC,aAAA,KAEAC,GAAAC,GAAA,IAAAV,EAAAS,QACAE,GAAAC,IACAH,GAAAI,OACAD,IACAA,EAAAV,EAAAE,KAAAU,sBAAA,IAEAlB,EAAAmB,KAAA,CACAC,KAAA,kBACAC,MAAA,CACAX,aAAAJ,EAAAI,aACAY,SAAAhB,EAAAK,WACAY,QAAAP,EAAAQ,GACAC,UAAAT,EAAAS,cAIAzB,EAAAmB,KAAA,CACAC,KAAA,SACAC,MAAA,CACAK,SAAAC,mBAAAzB,EAAA0B,YAGA,EAGA,IAAAC,GAAAC,EAAAC,iBACAC,GAAA,KACA1B,EAAAE,KAAAyB,KAAAC,MAAAC,EAAA,kBAAA,MACAC,EAAA,CACAC,MAAA/B,EAAAE,KAAA8B,aAAA,IAAAT,GAAAU,WAEAjC,EAAAG,WAAAP,EAAAmB,MAAAZ,WACAH,EAAAM,aAAA4B,mBAAAtC,EAAAmB,MAAAT,cACAN,EAAAI,cAAAR,EAAAmB,MAAAX,aACAJ,EAAAK,WAAAT,EAAAmB,MAAAV,UAAA"}