学员端小程序
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

71 lines
1.2 KiB

  1. <template>
  2. <view class="step1">
  3. <view class="card">
  4. <view class="list">
  5. <view class="listItem" v-for="(item,index) in list" :key="index" :class="{active: index==1}">
  6. {{ item.text }}</view>
  7. </view>
  8. </view>
  9. <view class="btn" @click="changeStep(2)">下一步</view>
  10. </view>
  11. </template>
  12. <script>
  13. export default {
  14. data() {
  15. return {
  16. list: [{
  17. text: '科目二',
  18. id: 2
  19. },
  20. {
  21. text: '科目三',
  22. id: 3
  23. },
  24. ],
  25. }
  26. },
  27. methods: {
  28. changeStep(val) {
  29. this.$emit('changeStep', val)
  30. }
  31. }
  32. }
  33. </script>
  34. <style lang="scss" scoped>
  35. .list {
  36. display: flex;
  37. flex-wrap: wrap;
  38. display: flex;
  39. padding: 24rpx;
  40. .listItem {
  41. width: 32.4%;
  42. height: 120rpx;
  43. background: #F8F8F8;
  44. border-radius: 12rpx;
  45. font-weight: 500;
  46. text-align: center;
  47. line-height: 120rpx;
  48. margin-right: 20rpx;
  49. &.active {
  50. width: 200rpx;
  51. height: 120rpx;
  52. background: rgba(25, 137, 250, 0.1);
  53. border-radius: 12rpx;
  54. border: 2rpx solid $themC;
  55. color: $themC;
  56. }
  57. }
  58. }
  59. .btn {
  60. width: 47%;
  61. height: 72rpx;
  62. background: #1989FA;
  63. border-radius: 8rpx;
  64. font-size: 28rpx;
  65. color: #fff;
  66. text-align: center;
  67. line-height: 72rpx;
  68. margin: 108rpx auto 50rpx auto;
  69. }
  70. </style>