Subscription.vue 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132
  1. <template>
  2. <!-- 认购 -->
  3. <div class="subscription">
  4. <div class="subscription-content" v-if="subscriptionData > 0">
  5. <div class="subscription-head pf400 fs12 fc666666">
  6. <div class="head-name">名称</div>
  7. <div class="head-price">单价</div>
  8. <div class="head-operate">操作</div>
  9. </div>
  10. <div class="subscription-body">
  11. <div
  12. class="subscription-item"
  13. v-for="(item, index) in subscriptionData"
  14. :key="index">
  15. <div class="item-name pf400 fs14 fc2C3131">Bitcoin</div>
  16. <div class="item-price pf400 fs14 fc2C3131">15.3156</div>
  17. <div class="item-operate">
  18. <div class="text pf500 fs12 fcFFFFFF">认购</div>
  19. </div>
  20. </div>
  21. </div>
  22. </div>
  23. <div class="subscription-null" v-else>
  24. <img
  25. src="../../../assets/icon/index/subscription-null.svg"
  26. class="img-null"
  27. alt="" />
  28. </div>
  29. </div>
  30. </template>
  31. <script setup>
  32. import { ref } from "vue";
  33. const subscriptionData = ref(6);
  34. </script>
  35. <style lang="less" scoped>
  36. .subscription {
  37. width: 349px;
  38. .subscription-content {
  39. margin-top: 10px;
  40. width: 100%;
  41. .subscription-head {
  42. display: flex;
  43. flex-direction: row;
  44. justify-content: flex-start;
  45. width: 100%;
  46. height: 24px;
  47. .head-name {
  48. width: 116px;
  49. height: 24px;
  50. line-height: 24px;
  51. text-align: left;
  52. letter-spacing: 0.17px;
  53. }
  54. .head-price {
  55. width: 117px;
  56. height: 24px;
  57. line-height: 24px;
  58. text-align: center;
  59. letter-spacing: 0.17px;
  60. }
  61. .head-operate {
  62. width: 116px;
  63. height: 24px;
  64. line-height: 24px;
  65. text-align: right;
  66. letter-spacing: 0.17px;
  67. }
  68. }
  69. .subscription-body {
  70. width: 100%;
  71. .subscription-item {
  72. display: flex;
  73. flex-direction: row;
  74. justify-content: flex-start;
  75. margin-top: 13px;
  76. padding-bottom: 13px;
  77. width: 100%;
  78. border-bottom: 1px solid #f5f5f5;
  79. .item-name {
  80. width: 116px;
  81. height: 24px;
  82. line-height: 24px;
  83. text-align: left;
  84. letter-spacing: 0.17px;
  85. }
  86. .item-price {
  87. width: 117px;
  88. height: 24px;
  89. line-height: 24px;
  90. text-align: center;
  91. letter-spacing: 0.17px;
  92. }
  93. .item-operate {
  94. display: flex;
  95. flex-direction: row;
  96. justify-content: flex-end;
  97. width: 116px;
  98. height: 24px;
  99. .text {
  100. width: 61px;
  101. height: 24px;
  102. line-height: 24px;
  103. text-align: center;
  104. border-radius: 5px;
  105. background: #45b26b;
  106. }
  107. }
  108. }
  109. }
  110. }
  111. .subscription-null {
  112. .img-null {
  113. margin-top: 117px;
  114. width: 343px;
  115. height: 267px;
  116. }
  117. }
  118. }
  119. </style>