<template>
  <view class="container">
    <view class="image-container" @click="toPage('merchant')">
      <image src="@/static/index/merchant.png" mode="aspectFit"></image>
      <text>客户端</text>
    </view>
    <view class="image-container" @click="toPage('login')">
      <image src="@/static/index/rider.png" mode="aspectFit"></image>
      <text>骑手端</text>
    </view>
  </view>
</template>
<script>
  export default {
    methods: {
      toPage(path) {
        uni.navigateTo({
          url: '/pages/login/' + path
        });
      }
    }
  }
</script>
<style lang="scss" scoped>
  .container {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
  }

  .image-container {
    width: 50%;
    display: flex;
    justify-content: center;
    flex-direction: column;
    align-items: center;

    text {
      margin-top: 20rpx;
    }
  }

  image {
    width: 100px;
    /* 设置图片宽度，根据实际需求调整 */
    height: 100px;
    /* 设置图片高度，保持与宽度一致 */
  }
</style>