Skip to content

Commit

Permalink
Update the workflow markdown report when editing the step label
Browse files Browse the repository at this point in the history
  • Loading branch information
assuntad23 committed Jan 17, 2024
1 parent 00cb4f2 commit 7aed45f
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions client/src/components/Workflow/Editor/Index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,7 @@ import { Toast } from "composables/toast";
import { storeToRefs } from "pinia";
import Vue, { computed, onUnmounted, ref, unref } from "vue";
import { replaceLabel } from "@/components/Markdown/parse";
import { getUntypedWorkflowParameters } from "@/components/Workflow/Editor/modules/parameters";
import { ConfirmDialog } from "@/composables/confirmDialog";
import { useDatatypesMapper } from "@/composables/datatypesMapper";
Expand Down Expand Up @@ -653,7 +654,10 @@ export default {
},
onLabel(nodeId, newLabel) {
const step = { ...this.steps[nodeId], label: newLabel };
const oldLabel = this.steps[nodeId].label;
this.onUpdateStep(step);
const newMarkdown = replaceLabel(this.markdownText, "step", oldLabel, newLabel);
this.onReportUpdate(newMarkdown);
},
onScrollTo(stepId) {
this.scrollToId = stepId;
Expand Down

0 comments on commit 7aed45f

Please sign in to comment.