From ded854c73cad010e434de7c3f20722372d3fd50d Mon Sep 17 00:00:00 2001 From: chris Date: Thu, 21 Mar 2024 11:47:52 +0100 Subject: [PATCH] fix(navigation): check unique subflow name for current Co-Authored-By: Alex August Schlote --- app/services/flowNavigation.server.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/services/flowNavigation.server.ts b/app/services/flowNavigation.server.ts index 9808f0508..727c90176 100644 --- a/app/services/flowNavigation.server.ts +++ b/app/services/flowNavigation.server.ts @@ -91,7 +91,9 @@ function getSubflowSpecifics( destination: flowRoot + subflowDestionationStepId, label: translation[subflowRoot] ?? subflowKey, state: navState({ - isCurrent: currentStepId.startsWith(subflowRoot), + isCurrent: + currentStepId.startsWith(subflowRoot) && + currentStepId.at(subflowRoot.length) === "/", // subflows might start with the same name, this ensures the following characters isReachable: subflowState !== "Hidden", isDone: subflowState == "Done", isUneditable: flowController.isUneditable(subflowRoot),