<template>
    <van-field 
      :value="email"
      class="email-input"
      @input="input"
      placeholder="请输入邮箱"
      label-align="right"
      :disabled="!canEditEmail"
      clearable
    />
</template>
<script lang="ts">
import { Component, Vue, Model, Emit, Prop } from 'vue-property-decorator';
import { isPhone } from '@/const/pattern';
/**
 * 手机号输入框
 */
@Component({
  name: 'EmailInput',
})
export default class EmailInput extends Vue {
  @Model ('input', { type: String, required: true })
  private readonly email!: string;
  @Prop({ type: Boolean, default: true})
  private readonly canEditEmail!: boolean;

  @Emit('input')
  private input(e: string) {
    return e;
  }
}
</script>
<style scoped lang="scss">
.email-input{
  font-size: 14px;
  font-family: PingFangSC-Medium, PingFang SC;
  font-weight: 500;
  color: #1F292D;
}
</style>