index.vue 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. <template>
  2. <view class="red_packet" catchtouchmove="true">
  3. <image src="../../static/icon/red_packet_background.jpg" class="read_packet_background" />
  4. <view class="rule">活动规则</view>
  5. <view class="get_content">
  6. <view class="custom_button"> 立即领取 </view>
  7. <text>点击领取后,红包将自动到账余额</text>
  8. </view>
  9. </view>
  10. </template>
  11. <script></script>
  12. <style lang="less" scoped>
  13. .red_packet {
  14. width: 100vw;
  15. height: 100vh;
  16. position: relative;
  17. .read_packet_background {
  18. width: 100%;
  19. height: 100%;
  20. }
  21. .rule {
  22. position: absolute;
  23. right: 0;
  24. top: 26%;
  25. color: #846100;
  26. padding: 15rpx 35rpx;
  27. background-color: #ffedad;
  28. border-radius: 60rpx;
  29. text-align: center;
  30. font-size: 28rpx;
  31. }
  32. .get_content {
  33. position: absolute;
  34. bottom: 18%;
  35. width: 100%;
  36. display: flex;
  37. flex-direction: column;
  38. align-items: center;
  39. justify-content: center;
  40. > text {
  41. color: #fff;
  42. font-size: 26rpx;
  43. margin-top: 20rpx;
  44. }
  45. }
  46. .custom_button {
  47. display: inline-block;
  48. background-color: #fbe6a0;
  49. color: #9c6c11;
  50. font-size: 18px;
  51. padding: 6px 30px;
  52. border-radius: 8px;
  53. text-align: center;
  54. box-shadow: 0px 2px 4px rgba(0, 0, 0, 0.1);
  55. border: 2px solid transparent;
  56. text-shadow: 0 1px 1px rgba(255, 255, 255, 0.5);
  57. position: relative;
  58. }
  59. .custom_button:before,
  60. .custom_button:after {
  61. content: "";
  62. position: absolute;
  63. width: 24px;
  64. height: 24px;
  65. background-color: #fbe6a0;
  66. border: 2px solid #fbe6a0;
  67. border-radius: 10rpx;
  68. top: 50%;
  69. transform: translateY(-50%);
  70. }
  71. .custom_button:before {
  72. left: -6px;
  73. }
  74. .custom_button:after {
  75. right: -6px;
  76. }
  77. }
  78. </style>