KnowledgeTrack.vue 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133
  1. <template>
  2. <div class="knowledgeTrack">
  3. <h3 class="title">历次考试知识点追踪</h3>
  4. <!-- 内容区域 -->
  5. <div class="map_content" v-if="examRange || knowledgeStats.length > 0">
  6. <!-- 考试范围说明 -->
  7. <div class="knowledge_stats">
  8. <p class="range_text" >
  9. <span class="dot"></span>历次考试:<span v-html="examRange" style="color:#333333;font-weight:600;"></span>
  10. </p>
  11. <p class="stats_text" v-for="(item, index) in knowledgeStats" :key="index">
  12. <span class="dot"></span> <span v-html="item"></span>
  13. </p>
  14. </div>
  15. </div>
  16. <!-- 暂无数据 -->
  17. <div class="noData" v-else>
  18. <div class="module_chart no_content_data no_data" element-loading-background="#ffffff">
  19. <span>暂无数据</span>
  20. </div>
  21. </div>
  22. </div>
  23. </template>
  24. <script>
  25. export default {
  26. name: "KnowledgeTrack",
  27. props: {
  28. // 考试范围
  29. examRange: {
  30. type: String,
  31. default: ''
  32. },
  33. // 包含知识点数据
  34. knowledgeStats: {
  35. type: Array,
  36. default: () => []
  37. },
  38. // 模式:class/grade/student
  39. mode: {
  40. type: String,
  41. default: 'grade'
  42. }
  43. },
  44. data() {
  45. return {
  46. };
  47. },
  48. computed: {
  49. },
  50. mounted() {
  51. },
  52. methods: {
  53. }
  54. };
  55. </script>
  56. <style scoped lang="scss">
  57. .knowledgeTrack {
  58. background-color: #ffffff;
  59. border-radius: 10px;
  60. padding: 20px;
  61. box-sizing: border-box;
  62. .title {
  63. font-size: 16px;
  64. font-weight: 600;
  65. color: #333333;
  66. margin: 0 0 20px 0;
  67. }
  68. .map_content {
  69. background: #F7F7F8;
  70. border-radius: 5px 5px 5px 5px;
  71. border: 1px solid #EBEEF5;
  72. padding: 12px;
  73. p{
  74. margin-bottom: 5px;
  75. }
  76. .range_text,.stats_text {
  77. font-size: 14px;
  78. line-height: 1.8;
  79. color: #666;
  80. padding-left: 17px;
  81. position: relative;
  82. text-align: justify;
  83. .dot {
  84. position: absolute;
  85. left: 0;
  86. top: 8px;
  87. display: inline-block;
  88. width: 6px;
  89. height: 6px;
  90. background: #666666;
  91. border-radius: 50%;
  92. }
  93. }
  94. }
  95. //暂无数据
  96. .noData {
  97. position: relative;
  98. height: 220px;
  99. /* 暂无数据样式 */
  100. .no_data {
  101. position: absolute;
  102. top: 50%;
  103. left: 50%;
  104. transform: translate(-50%, -50%);
  105. font-size: 14px;
  106. color: #909399;
  107. text-align: center;
  108. width: 100%;
  109. height: 100%;
  110. display: flex;
  111. align-items: center;
  112. justify-content: center;
  113. border-radius: 8px;
  114. span{
  115. margin-top: 11%;
  116. }
  117. }
  118. }
  119. }
  120. </style>