SecondaryHeading.vue 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136
  1. <template>
  2. <!-- 一级标题页导航 -->
  3. <div class="sannongzhichuang">
  4. <div class="inner">
  5. <h2>
  6. <!-- 三农之窗 -->
  7. {{ titleName }}
  8. <em class="iconfont icon-xingzhuang-zhijiaosanjiaoxing-copy"></em>
  9. </h2>
  10. <p class="introduction">
  11. <strong>频道介绍</strong>
  12. <div v-for="(item,index) in titleData">
  13. <span v-if="index<=7">
  14. <!-- <NuxtLink :to="`/newsList/${item.id}`" target="_blank">{{ item.name }}</NuxtLink> -->
  15. <NuxtLink :to="{ path: `/newsList/${item.category_id}`, query: { catid: item.category_id } }" target="_blank">{{ item.name }}</NuxtLink>
  16. </span>
  17. </div>
  18. </p>
  19. </div>
  20. </div>
  21. </template>
  22. <script setup>
  23. //let ChannelList = ['理论前沿', '典型经验', '魅力乡村', '农民之家', '农业天地', '农村建设', '高端资讯', '实践探索']
  24. const props = defineProps({
  25. titleName: String,
  26. titleData:Array
  27. });
  28. </script>
  29. <style lang="less" scoped>
  30. // 三农之窗
  31. .sannongzhichuang {
  32. margin: 30px 0 40px;
  33. .inner {
  34. width: 1200px;
  35. height: 67px;
  36. position: relative;
  37. }
  38. h2 {
  39. display: inline-block;
  40. background-image: url("../../static/images/bg1.png");
  41. width: 156px;
  42. height: 43px;
  43. padding: 14px 31px 10px 25px;
  44. font-family: STXingkai, STXingkai;
  45. font-weight: 400;
  46. font-size: 39px;
  47. color: #FFFFFF;
  48. line-height: 46px;
  49. text-align: center;
  50. font-style: normal;
  51. text-transform: none;
  52. -webkit-text-stroke: 1px #3C6C47;
  53. position: absolute;
  54. top: 0;
  55. left: 0;
  56. z-index: 99;
  57. em {
  58. position: absolute;
  59. top: -16px;
  60. right: -12px;
  61. color: #185410;
  62. display: inline-block;
  63. width: 13px;
  64. height: 13px;
  65. }
  66. }
  67. p.introduction {
  68. display: inline-block;
  69. width: 1003px;
  70. height: 56px;
  71. line-height: 56px;
  72. background-color: #fafafa;
  73. position: absolute;
  74. bottom: 0;
  75. right: 0;
  76. display: flex;
  77. >strong:first-child {
  78. margin-left: 40px;
  79. display: inline-block;
  80. vertical-align: middle;
  81. width: 28px;
  82. height: 36px;
  83. padding: 3px 7px;
  84. border: 0.5px solid #129502;
  85. font-family: Microsoft YaHei, Microsoft YaHei;
  86. font-weight: bold;
  87. font-size: 14px;
  88. color: #139602;
  89. line-height: 18px;
  90. text-align: center;
  91. font-style: normal;
  92. text-transform: none;
  93. }
  94. div {
  95. >span {
  96. width: 64px;
  97. height: 21px;
  98. font-family: Microsoft YaHei, Microsoft YaHei;
  99. font-weight: 400;
  100. font-size: 16px;
  101. color: #000000;
  102. line-height: 21px;
  103. text-align: left;
  104. font-style: normal;
  105. text-transform: none;
  106. margin-top: 17px;
  107. padding: 0 24px;
  108. border-right: 1px solid #ccc;
  109. a {
  110. color: #000;
  111. }
  112. }
  113. >span:hover a {
  114. color: #139602;
  115. }
  116. >span:last-child {
  117. border: none;
  118. }
  119. }
  120. }
  121. }
  122. </style>