<template>
  <popup v-model:value="value" header-title="余额提现" header-style="green" content-animate="scale" @close="$emit('destroy-popup')">
    <section class="recharge-container exchange-container relative jCenter withdrawal-container">
      <div @click="close" class="recharge-close-wrap cursor-pointer absolute animate-rotate-hover">
        <icon type="close" class="recharge-close"></icon>
      </div>

      <section class="screen">

        <aside class="rowACenter exchange-item withdrawal-item-margin">
          <div class="exchange-label">我的余额:</div>
          <div class="flex-1">
            <div class="line-1 exchange-value">{{$store.getters.money}}</div>
          </div>
        </aside>

        <aside class="rowACenter exchange-item">
          <div class="exchange-label">提现金额</div>
          <div class="exchange-input-warp">
            <a-input-number
                class="recording-input screen exchange-input"
                :min="1"
                :precision="0"
                v-model:value="moneyValue"
                :max="$store.getters.money"
                :disabled="disabled"
            ></a-input-number>
          </div>
          <div @click="allExChange" class="exchange-all-button"
            :class="{
              'button-active': !disabled
            }"
          >全部兑换</div>
        </aside>

        <div class="center">
          <v-button @submit-verify="submitVerify" @submit="submit" class="exchange-button withdrawal-button">立即兑换</v-button>
        </div>


      </section>

    </section>
  </popup>
</template>

<script>
import {
  Popup,
  icon,
  vButton
} from '$components';
import {
  InputNumber
} from 'ant-design-vue';
import mixins from '../mixins';
export default {
  name: "popup-withdrawal",
  components:{
    Popup,
    icon,
    vButton,
    [InputNumber.name]:InputNumber
  },
  mixins
}
</script>

<style scoped lang="scss" src="../style.scss"></style>

<style lang="scss" src="../../popup-exchange-coin/global.scss"></style>