您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

textDetails.vue 1.3KB

1年前
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. <template>
  2. <view class="news-item" v-for="(item,index) in state.data" :key='index'>
  3. <view class="left-text">
  4. <view class="tit description">{{item.title}}</view>
  5. <view class="span">{{item.copywriting}}</view>
  6. </view>
  7. <view class="image-box">
  8. <image :src="fileURLList + item.imgUrl"></image>
  9. </view>
  10. </view>
  11. </template>
  12. <script setup lang="ts">
  13. import { reactive } from "vue";
  14. import { onLoad } from "@dcloudio/uni-app";
  15. import { fileURL, fileURLList } from "@/datas/fileURL.js";
  16. const state = reactive({
  17. data: []
  18. })
  19. onLoad((option) => {
  20. const params = JSON.parse(decodeURIComponent(option.item))
  21. state.data.push(params)
  22. console.log("params", params)
  23. })
  24. </script>
  25. <style>
  26. page {
  27. background: #eef7f7;
  28. }
  29. </style>
  30. <style lang="scss" scoped>
  31. .news-item {
  32. display: flex;
  33. border: 1rpx solid #dcdcdc;
  34. padding: 40rpx;
  35. font-size: 30rpx;
  36. box-sizing: border-box;
  37. width: 90%;
  38. margin: 30rpx auto;
  39. background-color: white;
  40. justify-content: space-between;
  41. }
  42. .image-box image {
  43. width: 100rpx;
  44. height: 100rpx;
  45. border-radius: 10rpx;
  46. }
  47. .news-item .span {
  48. font-size: 22rpx;
  49. display: inline-block;
  50. text-align: center;
  51. background: #bae0f1;
  52. border-radius: 6rpx;
  53. color: #0a8f8a;
  54. padding: 4rpx 8rpx;
  55. }
  56. .news-item .more {
  57. font-size: 24rpx;
  58. text-align: center;
  59. color: #0a8f8a;
  60. padding: 22rpx 0;
  61. }
  62. </style>