|
|
@@ -0,0 +1,186 @@
|
|
|
+<template>
|
|
|
+ <div class="resources">
|
|
|
+ <div class="resources-header">
|
|
|
+ <header-btn
|
|
|
+ :isChoose="chooseResource === index"
|
|
|
+ v-for="(item, index) in resources"
|
|
|
+ :key="index"
|
|
|
+ :icon="item.icon"
|
|
|
+ :name="item.name"
|
|
|
+ @choose="chooseResource = index"
|
|
|
+ ></header-btn>
|
|
|
+
|
|
|
+ <div class="resources-tag" :style="{ left: `${167 * chooseResource + 96}px` }"></div>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <div class="resource-box">
|
|
|
+ <div class="news-content">
|
|
|
+ <div class="top">
|
|
|
+ <div class="title">政策</div>
|
|
|
+ <el-link :underline="false" class="more">
|
|
|
+ 更多<i class="el-icon-view el-icon-arrow-right"></i>
|
|
|
+ </el-link>
|
|
|
+ </div>
|
|
|
+ <div class="news-list">
|
|
|
+ <router-link v-for="i in 20" :key="i" :to="{ name: 'newsDetail' }" class="news-link">
|
|
|
+ <span class="text1">习近平在江西考察并主持召开推动中部地区崛起工作座谈会</span>
|
|
|
+ <span class="text2">05.23</span>
|
|
|
+ </router-link>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+</template>
|
|
|
+
|
|
|
+<script>
|
|
|
+import HeaderBtn from './HeaderBtn.vue';
|
|
|
+export default {
|
|
|
+ components: { HeaderBtn },
|
|
|
+ data() {
|
|
|
+ return {
|
|
|
+ chooseResource: 0,
|
|
|
+ resources: [
|
|
|
+ {
|
|
|
+ icon: 'iconfont-imt_fuwu_icon_01_pre',
|
|
|
+ name: '政策'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ icon: 'iconfont-imt_fuwu_icon_02',
|
|
|
+ name: '法律'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ icon: 'iconfont-imt_fuwu_icon_04_pre',
|
|
|
+ name: '知产'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ icon: 'iconfont-imt_fuwu_icon_03',
|
|
|
+ name: '技术'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ icon: 'iconfont-imt_fuwu_icon_042',
|
|
|
+ name: '产品'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ icon: 'iconfont-imt_fuwu_icon_04',
|
|
|
+ name: '企业'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ icon: 'iconfont-imt_fuwu_icon_041',
|
|
|
+ name: '专家'
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ };
|
|
|
+ }
|
|
|
+};
|
|
|
+</script>
|
|
|
+
|
|
|
+<style lang="less" scoped>
|
|
|
+.resources-header {
|
|
|
+ .flex();
|
|
|
+ padding: 40px 20px 24px;
|
|
|
+ justify-content: space-between;
|
|
|
+ .header-btn {
|
|
|
+ padding: 0 40px;
|
|
|
+ }
|
|
|
+
|
|
|
+ position: relative;
|
|
|
+ &::after {
|
|
|
+ content: '';
|
|
|
+ position: absolute;
|
|
|
+ left: 0;
|
|
|
+ right: 0;
|
|
|
+ bottom: 0;
|
|
|
+ background-color: #0f264d;
|
|
|
+ height: 1px;
|
|
|
+ z-index: 1;
|
|
|
+ }
|
|
|
+ .resources-tag {
|
|
|
+ position: absolute;
|
|
|
+ bottom: 0px;
|
|
|
+ width: 10px;
|
|
|
+ height: 6px;
|
|
|
+ background-color: #fff;
|
|
|
+ z-index: 2;
|
|
|
+ transition: left ease-in-out 0.3s;
|
|
|
+ &::before {
|
|
|
+ content: '';
|
|
|
+ background-color: #0f264d;
|
|
|
+ width: 8px;
|
|
|
+ left: -2px;
|
|
|
+ height: 1px;
|
|
|
+ position: absolute;
|
|
|
+ bottom: 0;
|
|
|
+ transform-origin: 0px 0px;
|
|
|
+ transform: rotate(-30deg);
|
|
|
+ }
|
|
|
+ &::after {
|
|
|
+ content: '';
|
|
|
+ background-color: #0f264d;
|
|
|
+ width: 8px;
|
|
|
+ right: -2px;
|
|
|
+ height: 1px;
|
|
|
+ position: absolute;
|
|
|
+ bottom: 0;
|
|
|
+ transform-origin: 8px 0px;
|
|
|
+ transform: rotate(30deg);
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+.resource-box {
|
|
|
+ padding: 30px 0 100px;
|
|
|
+}
|
|
|
+.news-content {
|
|
|
+ padding: 10px 30px;
|
|
|
+ height: 367px;
|
|
|
+ width: 1020px;
|
|
|
+ box-shadow: 0px 2px 10px 0px rgba(25, 25, 25, 0.1);
|
|
|
+ box-sizing: border-box;
|
|
|
+ .flex-col();
|
|
|
+ .top {
|
|
|
+ .flex();
|
|
|
+ .title {
|
|
|
+ color: @prim;
|
|
|
+ font-size: 16px;
|
|
|
+ font-weight: bold;
|
|
|
+ }
|
|
|
+ padding: 20px 0;
|
|
|
+ justify-content: space-between;
|
|
|
+ border-bottom: 1px solid @bg;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+.news-list {
|
|
|
+ flex-grow: 1;
|
|
|
+ overflow: auto;
|
|
|
+ padding: 25px 12px 15px;
|
|
|
+ .news-link {
|
|
|
+ text-decoration: none;
|
|
|
+ .flex();
|
|
|
+ font-size: 14px;
|
|
|
+ line-height: 20px;
|
|
|
+
|
|
|
+ .text1 {
|
|
|
+ color: #000;
|
|
|
+ flex-grow: 1;
|
|
|
+ }
|
|
|
+
|
|
|
+ .text2 {
|
|
|
+ color: @info;
|
|
|
+ }
|
|
|
+
|
|
|
+ &:hover {
|
|
|
+ .text1 {
|
|
|
+ color: @prim;
|
|
|
+ }
|
|
|
+
|
|
|
+ .text2 {
|
|
|
+ color: fade(@prim, 60%);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ .news-link + .news-link {
|
|
|
+ margin-top: 25px;
|
|
|
+ }
|
|
|
+}
|
|
|
+</style>
|