<template>
  <div class="text-xs-center">
    <el-input ref="inp" v-model="inputText" size="small" @input="changeValue" class="table_in_input"></el-input>
  </div>
</template>

<script>
import helper from "@/services/helper";
export default {
  props: {
    item: {
      type: String,
      default: ""
    },
    header: {
      type: String,
      default: ""
    },
    rowId: {
      type: Number,
      default: 0
    }
  },
  data: () => ({
    inputText: ""
  }),
  mounted() {
    this.inputText = this.item;
  },
  methods: {
    changeValue() {
      this.$emit("changeInputValue", {
        rowId: this.rowId,
        header: this.header,
        inputValue: this.inputText
      });
    }
  }
};
</script>
<style scoped>
.text-xs-center {
  height: 32px;
}
.text-xs-center input {
  width: 100%;
}
.table_in_input {
  text-align: center;
  font-size: 14px;
}
</style>