share.blade.php 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="UTF-8">
  5. <title>{{empty($dream->user) ? '' : $dream->user->nickname}}的梦想</title>
  6. <script src="/base/js/jquery-2.1.1.min.js"></script>
  7. <meta name="viewport" content="initial-scale=1, maximum-scale=1, user-scalable=no, width=device-width">
  8. <style>
  9. body{
  10. padding: 0;
  11. margin: 0;
  12. }
  13. p{
  14. -webkit-margin-before: 0.1em;
  15. -webkit-margin-after: 0.1em;
  16. }
  17. </style>
  18. </head>
  19. <body style="overflow-x: hidden">
  20. <div style="height: 50px">
  21. <a href="https://fir.im/jt4h">
  22. <div style="float: left;color: #666;line-height: 50px;padding-left: 5px">支持({{empty($dream->user) ? '' : $dream->user->nickname}})的梦想!现在就下载喵喵</div>
  23. <div style="float: right;padding: 5px">
  24. <img style="width: 40px;height: 40px;" src="http://firicon.fir.im/396004d5e7b572efbefdfee976338331a457282b" alt="">
  25. </div>
  26. </a>
  27. </div>
  28. <img style="width: 100%; height: 100%;" src="{{!empty($dream->img) ? $dream->img->pic : ''}}
  29. ">
  30. <p style="font-size: 17px; padding: 0 10px">{{$dream->name}}</p>
  31. <div style="border-bottom: 1px solid #DEDEDE">
  32. <p id="about" style="font-size: 13px; padding: 0 10px; color: #919191;white-space: nowrap;overflow:hidden;text-overflow:ellipsis">
  33. {{$dream->about}}
  34. </p>
  35. <p style="text-align: center">
  36. <img src="/base/img/down.svg" alt="" id="down">
  37. <img src="/base/img/up.svg" alt="" id="up">
  38. </p>
  39. </div>
  40. <div style="border-bottom: 1px solid #DEDEDE; height: 50px; padding: 5px 10px;">
  41. <div style="float:left;">
  42. <p>{{$days}}</p>
  43. <p style="font-size: 13px; color: #919191">剩余时间</p>
  44. </div>
  45. {{--判断显示--}}
  46. @if( $dream->user_id == $user_id)
  47. <div style="float:right;">
  48. <p style="text-align: right">{{$dream->mark}}</p>
  49. <p style="font-size: 13px;; color: #919191">当前获得梦想分数</p>
  50. </div>
  51. @endif
  52. </div>
  53. <div style="clear:both; height: 50px; padding: 5px 10px;">
  54. <div style="text-align: left">
  55. <p style="text-align: right">{{$dream->coin}}</p>
  56. <p style="font-size: 13px; color: #919191">我要求的梦想币</p>
  57. </div>
  58. {{--判断显示--}}
  59. @if( $dream->user_id == $user_id)
  60. <div style="text-align: right;float: right">
  61. <p style="color: #FF6600">{{$dream->get_coin}}</p>
  62. <p style="font-size: 13px; color: #919191">目前已获梦想币</p>
  63. </div>
  64. @endif
  65. </div>
  66. <div style="padding: 0 10px 20px 10px">
  67. <div style="background-color:#E6E6E6; width: 100%;">
  68. <div style="width: {{($dream->get_coin / $dream->coin)*100}}%; background: #FF6600; height: 5px">
  69. </div>
  70. </div>
  71. </div>
  72. </body>
  73. </html>
  74. <script>
  75. $(function () {
  76. $('#up').hide();
  77. var str = $('#about').html();
  78. new_str = str.replace(/\n/g,"<br/>");
  79. $('#about').html(new_str);
  80. $('#up').click(function () {
  81. $(this).hide();
  82. $('#down').show();
  83. $('#about').css('white-space','nowrap');
  84. });
  85. $('#down').click(function () {
  86. $(this).hide();
  87. $('#up').show();
  88. $('#about').css('white-space','normal');
  89. });
  90. });
  91. </script>