task.vue 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. <template>
  2. <view class="content">
  3. <view class="task-header">
  4. <cu-custom>
  5. <block slot="content">任务广场</block>
  6. </cu-custom>
  7. <view class="sub-name">任务多,变现快!</view>
  8. <view class="sub-logo" :style="style"><image src="https://blue-data.oss-cn-guangzhou.aliyuncs.com/star/task-star-small.png" mode="widthFix"></image></view>
  9. </view>
  10. <view class="task-content">
  11. </view>
  12. </view>
  13. </template>
  14. <script>
  15. var app;
  16. export default {
  17. data() {
  18. return {
  19. style:""
  20. }
  21. },
  22. onLoad() {
  23. app = this;
  24. var StatusBar= this.StatusBar;
  25. var style = `top:${StatusBar}px;`;
  26. app.style = style;
  27. },
  28. methods: {
  29. }
  30. }
  31. </script>
  32. <style lang="scss">
  33. page{background-color: #f8f8f8;}
  34. .task-header{position: relative;background-image: linear-gradient(180deg, #85DFFE 9%, #D5F4FF 62.55%, #f8f8f8 100%);height: 290rpx;}
  35. .task-header .sub-name{font-size: 32rpx;font-weight: 800;font-family: "bluevBold";padding-left: 20rpx;padding-top: 20rpx;}
  36. .task-header .sub-logo{
  37. position: absolute;
  38. top: 40rpx;
  39. /* #ifdef MP-WEIXIN */
  40. right: 220upx;
  41. /* #endif */
  42. /* #ifdef MP-ALIPAY */
  43. right: 150upx;
  44. /* #endif */
  45. }
  46. .task-header .sub-logo image{width: 220rpx;max-height: 220rpx;}
  47. .task-content{background-image: linear-gradient(180deg, #ffffff, #f8f8f8);height: 100vh;border-radius: 40upx 40upx 0 0;}
  48. </style>