<template>
  <div class="main-content">
    <el-scrollbar height="730px">
      <component :is="currentComponent" ref="content"></component>
    </el-scrollbar>
  </div>
</template>
<script setup>
import { defineExpose } from "vue";
const props = defineProps({
  currentComponent: {
    type: Object,
    required: true,
  },
});
const content = ref(null);
// const consumerLeft = () => {
//   content.value.consumer();
// };
// const resLeft = () => {
//   content.value.practicalTraining();
// };
// const submitDataLeft = () => {
//   content.value.submitData();
// };
// const submitMethod = () => {
//   console.log(666);
//   // content.value.submitData();
// };
const submitMethod = () => {
  // console.log(666);
  content.value.submitData();
};
const retrainMethod = () => {
  // console.log(666);
  content.value.retrain();
};
defineExpose({
  submitMethod,
  retrainMethod,
});
</script>
<style lang="scss" scoped>
.main-content {
  width: calc(100% - 60px);
}
</style>
