兼兼街公众号代码
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

63 lines
1.2 KiB

  1. <template>
  2. <view class="new-card flex justify-between">
  3. <view style="margin: 10rpx 24rpx; display: flex;">
  4. <image :showLoading="true" :src="item.headImage" style="width: 100rpx;height: 100rpx;border-radius: 50%;"></image>
  5. <view style="padding: 28rpx;">
  6. <view style="font-size: 28rpx;font-weight: 500">{{getName(item.nickName)}}</view>
  7. <view style="font-size: 24rpx;margin-top: 20rpx;">{{item.createTime}}</view>
  8. </view>
  9. </view>
  10. </view>
  11. </template>
  12. <script>
  13. export default{
  14. props:{
  15. item:{
  16. type:Object,
  17. }
  18. },
  19. data(){
  20. return{
  21. }
  22. },
  23. methods:{
  24. getName(str){
  25. if(str.length > 10) {
  26. return str.substr(0,10) + "..."
  27. }
  28. return str
  29. }
  30. }
  31. }
  32. </script>
  33. <style lang="scss" scoped>
  34. .new-card {
  35. margin-bottom: 12rpx;
  36. background-color: #FFFFFF;
  37. .new-card-l {
  38. font-size: 28rpx;
  39. color: #C8C8C8;
  40. padding: 16rpx 16rpx;
  41. .title {
  42. font-size: 32rpx;
  43. color: #000000;
  44. line-height: 40rpx;
  45. font-weight: 600;
  46. overflow: hidden;
  47. display: -webkit-box;
  48. -webkit-box-orient: vertical;
  49. -webkit-line-clamp: 2;
  50. }
  51. }
  52. .new-card-r{
  53. uni-image>img {
  54. border-radius: 50%;
  55. }
  56. }
  57. }
  58. </style>