From 28b8555ab720cdd053d703a9856dd2df28a04cb7 Mon Sep 17 00:00:00 2001 From: Oliver Eyton-Williams Date: Fri, 7 Mar 2025 12:15:56 +0100 Subject: [PATCH] fix(client): order editors like their tabs (#59163) --- client/src/templates/Challenges/classic/multifile-editor.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/client/src/templates/Challenges/classic/multifile-editor.tsx b/client/src/templates/Challenges/classic/multifile-editor.tsx index 45cf004426b..1d2a494bd70 100644 --- a/client/src/templates/Challenges/classic/multifile-editor.tsx +++ b/client/src/templates/Challenges/classic/multifile-editor.tsx @@ -99,10 +99,11 @@ const MultifileEditor = (props: MultifileEditorProps) => { const editorKeys = []; + // The order of the keys should match the order set by sortChallengeFiles + if (indexjsx) editorKeys.push('indexjsx'); if (indexhtml) editorKeys.push('indexhtml'); if (stylescss) editorKeys.push('stylescss'); if (scriptjs) editorKeys.push('scriptjs'); - if (indexjsx) editorKeys.push('indexjsx'); if (mainpy) editorKeys.push('mainpy'); if (indexts) editorKeys.push('indexts');