diff --git a/src/components/robot/pages/RobotSettingsPage.tsx b/src/components/robot/pages/RobotSettingsPage.tsx
index 118329358..cb456e3d2 100644
--- a/src/components/robot/pages/RobotSettingsPage.tsx
+++ b/src/components/robot/pages/RobotSettingsPage.tsx
@@ -152,20 +152,36 @@ export const RobotSettingsPage = ({ handleStart }: RobotSettingsProps) => {
}}
style={{ marginBottom: "20px" }}
/>
- {robot.recording.workflow?.[0]?.what?.[0]?.args?.[0]?.limit !==
- undefined && (
-
- )}
+ {(() => {
+ let listCounter = 1;
+
+ return robot.recording.workflow.flatMap((wf, wfIndex) =>
+ wf.what.flatMap((action, actionIndex) => {
+ const argsWithLimit = action.args?.filter(
+ (arg: any) => arg && typeof arg === "object" && arg.limit !== undefined
+ );
+
+ if (!argsWithLimit?.length) return [];
+
+ return argsWithLimit.map((arg, limitIndex) => {
+ const labelName = action.name || `List ${listCounter++}`;
+ return (
+
+ );
+ });
+ })
+ );
+ })()}
+