agreement.vue 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. <template>
  2. <view class="buttomText flex" @click="checkedChange">
  3. <image v-if='checked' class="buttomIcon" src="../../static/icon/addressIconXz.png" mode="scaleToFill">
  4. </image>
  5. <view class="buttomNo" v-else>
  6. </view>
  7. <text class="margin-l-10">勾选代表同意</text>
  8. <navigator url="./userAgreement">
  9. <text class="next-text">母婴界严选服务</text>
  10. </navigator>
  11. <text>与</text>
  12. <navigator url="./privacyAgreement">
  13. <text class="next-text">隐私条例</text>
  14. </navigator>
  15. </view>
  16. </template>
  17. <script>
  18. export default {
  19. data() {
  20. return {
  21. // 是否选中
  22. checked: false,
  23. };
  24. },
  25. methods: {
  26. checkedChange() {
  27. this.checked = !this.checked;
  28. this.$emit('checkedChange', this.checked)
  29. }
  30. },
  31. };
  32. </script>
  33. <style lang="scss">
  34. .buttomText {
  35. margin-top: 30rpx;
  36. justify-content: center;
  37. font-size: 24rpx;
  38. color: $font-color-light;
  39. .buttomIcon,
  40. .buttomNo {
  41. width: 40rpx;
  42. height: 40rpx;
  43. }
  44. .next-text{
  45. color: $uni-color-primary;
  46. }
  47. .buttomNo {
  48. border: 1px solid $font-color-light;
  49. border-radius: 100rpx;
  50. }
  51. }
  52. </style>