<template>
  <div class="param-set-page">
    <flowNodeParamTable
      :node-params="nodeParamData"
      :current-node="currentRunFlowNode"
      :page-info="nodeInfo"
      :run-info="runInfo"
      :online-file-param="onlineFileParam"
      @update="refreshParamFun"
    ></flowNodeParamTable>
  </div>
</template>

<script setup lang="ts">
import { watch } from 'vue';
import flowNodeParamTable from '@/components/flow/flowNodeParamTable.vue';

const props = defineProps({
  currentRunFlowNode: {
    type: Object,
    default: () => {},
  },
  nodeParamData: {
    type: Array,
    default: () => [],
  },
  nodeData: {
    type: Object,
    default: () => {},
  },
  nodeInfo: {
    type: Object,
    default: () => {},
  },
  runInfo: {
    type: Object,
    default: () => {},
  },
  onlineFileParam: {
    type: Object,
    default: () => {},
  },
});

const emits = defineEmits(['update']);

const refreshParamFun = () => {
  emits('update');
};

watch(
  () => props.currentRunFlowNode,
  (newVal) => {
    if (newVal) {
    }
  },
  {
    immediate: true,
    deep: true,
  }
);
</script>

<style lang="scss" scoped>
.param-set-page {
  width: 100%;
  height: 100%;
  overflow: auto;
}
</style>
