s-signup-modal.vue 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122
  1. <template>
  2. <!-- 规格弹窗 -->
  3. <!-- showClose -->
  4. <su-popup :show="show" @close="colseSignUpModal" type="center" round="10">
  5. <view class="model-box ss-flex-col">
  6. <view class="ss-m-t-56 ss-flex-col ss-col-center">
  7. <text class="cicon-check-round"></text>
  8. <view class="score-title">{{ t('pop.auto_checkin_success') }}</view>
  9. <view class="model-title ss-flex ss-col-center ss-m-t-22 ss-m-b-30">
  10. {{ t('pop.daily_checkin_reward',{point:state?.social}) }}
  11. <!-- 获得每日签到{{state?.social}}点身价 -->
  12. </view>
  13. <view class="model-title ss-flex ss-col-center ss-m-b-30" v-if="state?.upgradeOrNot ">
  14. {{ t('pop.level_upgraded') }}{{ state?.socialStatusName }}
  15. </view>
  16. </view>
  17. <view class="model-bg ss-flex-col ss-col-center ss-row-right">
  18. <view class="ss-m-b-40">
  19. <button class="ss-reset-button confirm-btn" @tap="colseSignUpModal();">{{ t('common.confirm') }}</button>
  20. </view>
  21. </view>
  22. </view>
  23. </su-popup>
  24. </template>
  25. <script setup>
  26. import {
  27. computed,
  28. reactive,
  29. ref,
  30. watch
  31. } from 'vue';
  32. import sheep from '@/sheep';
  33. import { t } from '@/locale'
  34. import {
  35. colseSignUpModal,
  36. showSignUpModal
  37. } from '@/sheep/hooks/useModal';
  38. const headerBg = sheep.$url.css('/static/images/sign.png');
  39. const show = computed(() => sheep.$store('modal').signUp);
  40. const state = computed(() => sheep.$store('modal').signUpInfo)
  41. // 监听签到成功 3s之后自动关闭
  42. watch(() => show.value, (newValue) => {
  43. if(newValue){
  44. setTimeout(colseSignUpModal,3000)
  45. }
  46. })
  47. </script>
  48. <style lang="scss" scoped>
  49. .model-box {
  50. width: 520rpx;
  51. // height: 590rpx;
  52. background: linear-gradient(177deg, #ff6000 0%, #fe832a 100%);
  53. // background: linear-gradient(177deg, var(--ui-BG-Main), var(--ui-BG-Main-gradient));
  54. border-radius: 10rpx;
  55. .cicon-check-round {
  56. font-size: 70rpx;
  57. color: #fff;
  58. }
  59. .score-title {
  60. font-size: 34rpx;
  61. font-family: OPPOSANS;
  62. font-weight: 500;
  63. color: #fcff00;
  64. }
  65. .model-title {
  66. font-size: 28rpx;
  67. font-weight: 500;
  68. color: #ffffff;
  69. }
  70. .model-bg {
  71. width: 520rpx;
  72. height: 6.75rem;
  73. background-size: 100% 100%;
  74. background-image: v-bind(headerBg);
  75. background-repeat: no-repeat;
  76. border-radius: 0 0 10rpx 10rpx;
  77. .title {
  78. font-size: 34rpx;
  79. font-weight: bold;
  80. // color: var(--ui-BG-Main);
  81. color: #ff6000;
  82. }
  83. .subtitle {
  84. font-size: 26rpx;
  85. font-weight: 500;
  86. color: #999999;
  87. }
  88. .cancel-btn {
  89. width: 220rpx;
  90. height: 70rpx;
  91. border: 2rpx solid #ff6000;
  92. border-radius: 35rpx;
  93. font-size: 28rpx;
  94. font-weight: 500;
  95. color: #ff6000;
  96. line-height: normal;
  97. margin-right: 10rpx;
  98. }
  99. .confirm-btn {
  100. width: 300rpx;
  101. height: 70rpx;
  102. background: linear-gradient(90deg, #ff6000, #fe832a);
  103. box-shadow: 0 0.2em 0.5em rgba(#ff6000, 0.4);
  104. border-radius: 35rpx;
  105. font-size: 28rpx;
  106. font-weight: 500;
  107. color: #ffffff;
  108. line-height: normal;
  109. }
  110. }
  111. }
  112. </style>