From 07bed8eb775a20af1d6ba8eaa40a1b30f9858f9e Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 30 Nov 2026 13:18:02 +0000 Subject: [PATCH 01/13] [Fling game] Remove leftover extension store steps The draggable behavior is now added directly from the behavior dialog, but the tutorial still opened the extension store first: the store dialog then stayed open over the objects list and the tutorial could not be continued. --- tutorials/in-app/flingGame.json | 79 +++++---------------------------- 1 file changed, 10 insertions(+), 69 deletions(-) diff --git a/tutorials/in-app/flingGame.json b/tutorials/in-app/flingGame.json index 4118edf..4c1fbde 100644 --- a/tutorials/in-app/flingGame.json +++ b/tutorials/in-app/flingGame.json @@ -1690,75 +1690,6 @@ "absenceOfElement": "#object-editor-dialog" } }, - { - "id": "OpenPropertiesManagerForExtension", - "elementToHighlightId": "#main-toolbar-project-manager-button", - "nextStepTrigger": { - "presenceOfElement": "div[role=\"presentation\"]:is([data-open=true], :not([aria-hidden=true])) #project-manager-tab-extensions" - }, - "tooltip": { - "title": { - "messageByLocale": { - "en": "Now we'll make it possible for the player to drag the $(projectile).", - "fr": "Maintenant, nous allons faire en sorte que le joueur puisse faire glisser $(projectile) avec sa souris.", - "es": "Ahora vamos a hacer que el jugador pueda arrastrar $(projectile) con el ratón.", - "pt": "Agora vamos fazer com que o jogador possa arrastar $(projectile) com o mouse.", - "th": "ทีนี้เราจะทำให้ผู้เล่นสามารถลาก $(projectile)", - "ar": "الآن هيّا نجعل اللاعبين قادرين على سحب الـ $(projectile)." - } - }, - "description": { - "messageByLocale": { - "en": "For this, we will install an **extension**.\n\nOpen the **Project Manager**.", - "fr": "Pour cela, nous allons installer un **extension**.\n\nOuvrez le **Gestionnaire de projet**.", - "es": "Para ello, vamos a instalar una **extensión**.\n\nAbre el **Gestor de proyectos**.", - "pt": "Para isso, vamos instalar uma **extensão**.\n\nAbra o **Gerenciador de projetos**.", - "th": "โดยเราจะติดตั้ง **extension**\n\nเปิด **โปรเจกต์เมเนเจอร์**", - "ar": "للقيام بذلك، سوف نقوم بتثبيت **ملحق**.\n\nفتح **مدير المشروع**." - } - }, - "placement": "right" - } - }, - { - "elementToHighlightId": "div[role=\"presentation\"]:is([data-open=true], :not([aria-hidden=true])) #project-manager-tab-extensions", - "nextStepTrigger": { - "presenceOfElement": "#project-manager-extension-search-or-create" - }, - "tooltip": { - "description": { - "messageByLocale": { - "en": "Open the **Extensions** tab.", - "fr": "Ouvrez l'onglet **Extensions**.", - "es": "Abre la pestaña **Extensiones**.", - "pt": "Abra a guia **Extensões**.", - "th": "เปิดแท็บ **Extensions**", - "ar": "فتح نافذة **الملحقات**." - } - } - }, - "isOnClosableDialog": true, - "skippable": true - }, - { - "elementToHighlightId": "#project-manager-extension-search-or-create", - "nextStepTrigger": { - "presenceOfElement": "#extension-search-dialog" - }, - "tooltip": { - "description": { - "messageByLocale": { - "en": "Open the extension store", - "fr": "Ouvrez le **Magasin d'extension**.", - "es": "Abre la **Tienda de extensiones**.", - "pt": "Abra a **Loja de extensões**.", - "th": "เปิดร้านค้า extension", - "ar": "فتح متجر الملحقات" - } - } - }, - "isOnClosableDialog": true - }, { "elementToHighlightId": "#toolbar-open-objects-panel-button", "nextStepTrigger": { @@ -1796,6 +1727,16 @@ "presenceOfElement": "#object-editor-dialog" }, "tooltip": { + "title": { + "messageByLocale": { + "en": "Now we'll make it possible for the player to drag the $(projectile).", + "fr": "Maintenant, nous allons faire en sorte que le joueur puisse faire glisser $(projectile) avec sa souris.", + "es": "Ahora vamos a hacer que el jugador pueda arrastrar $(projectile) con el ratón.", + "pt": "Agora vamos fazer com que o jogador possa arrastar $(projectile) com o mouse.", + "th": "ทีนี้เราจะทำให้ผู้เล่นสามารถลาก $(projectile)", + "ar": "الآن هيّا نجعل اللاعبين قادرين على سحب الـ $(projectile)." + } + }, "placement": "left", "description": { "messageByLocale": { From 729adde70cb31809d2ea16f975467147a7ebe389 Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 30 Nov 2026 12:14:20 +0000 Subject: [PATCH 02/13] [Fling game] Let the target and block instances be dropped on the scene These steps highlight the object in the list but did not set interactsWithCanvas, so the blocking layer covered the scene canvas and the drop was refused. --- tutorials/in-app/flingGame.json | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tutorials/in-app/flingGame.json b/tutorials/in-app/flingGame.json index 4c1fbde..691ebce 100644 --- a/tutorials/in-app/flingGame.json +++ b/tutorials/in-app/flingGame.json @@ -936,6 +936,7 @@ }, { "elementToHighlightId": "objectInObjectsList:target", + "interactsWithCanvas": true, "nextStepTrigger": { "instanceAddedOnScene": "target" }, @@ -1111,6 +1112,7 @@ }, { "elementToHighlightId": "objectInObjectsList:block", + "interactsWithCanvas": true, "nextStepTrigger": { "instanceAddedOnScene": "block", "instancesCount": 2 From 17427b25e54988d721980747c147abf8f7d47e78 Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 30 Nov 2026 14:05:25 +0000 Subject: [PATCH 03/13] [Fling game] Fix the layer rename and hide steps for the tree view layers list The layers list is now a tree view: a new layer enters inline rename mode and #layer-name no longer exists. Wait for the renamed row instead. The visibility toggle is a button (its value never changes): wait for the row to be marked hidden (data-hidden, to be exposed by the editor). --- tutorials/in-app/flingGame.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tutorials/in-app/flingGame.json b/tutorials/in-app/flingGame.json index 691ebce..04b21b8 100644 --- a/tutorials/in-app/flingGame.json +++ b/tutorials/in-app/flingGame.json @@ -2792,9 +2792,9 @@ } }, { - "elementToHighlightId": "#layer-1 #layer-name", + "elementToHighlightId": "#layer-1", "nextStepTrigger": { - "valueEquals": "WinLayer" + "presenceOfElement": "#layer-1[data-scene=\"WinLayer\"]" }, "tooltip": { "description": { @@ -2813,7 +2813,7 @@ { "elementToHighlightId": "#layer-1 #layer-visibility", "nextStepTrigger": { - "valueHasChanged": true + "presenceOfElement": "#layer-1[data-hidden=\"true\"]" }, "tooltip": { "description": { From bcd19769491a1f894ca448f0b88df544767000f3 Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 30 Nov 2026 14:05:25 +0000 Subject: [PATCH 04/13] Press Enter when retrying to type in a tutorial input Inline rename inputs (tree view items) are only committed with Enter. --- e2e/lib/tutorialPlayer.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/e2e/lib/tutorialPlayer.js b/e2e/lib/tutorialPlayer.js index 40115e5..c5e253c 100644 --- a/e2e/lib/tutorialPlayer.js +++ b/e2e/lib/tutorialPlayer.js @@ -439,6 +439,8 @@ const performStepAction = async ({ const textToType = extractTextToType(step); if (isTextInput && textToType) { await fillField(page, highlightedElementSelector, textToType); + // Inline rename inputs (tree view items) are only committed with Enter. + if (attempt > 1) await page.keyboard.press('Enter'); return; } const sceneCanvas = page From 04ad58ace0bcf00796acbb99db44d7b3cb684999 Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 30 Nov 2026 14:38:39 +0000 Subject: [PATCH 05/13] [Fling game] Let the user select the background instance on the scene These steps ask to select an instance on the scene but highlight a toolbar button without interactsWithCanvas, so the blocking layer covered the scene. --- tutorials/in-app/flingGame.json | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tutorials/in-app/flingGame.json b/tutorials/in-app/flingGame.json index 04b21b8..16d4c7e 100644 --- a/tutorials/in-app/flingGame.json +++ b/tutorials/in-app/flingGame.json @@ -2128,6 +2128,7 @@ { "elementToHighlightId": "#toolbar-open-properties-panel-button", "skippable": true, + "interactsWithCanvas": true, "nextStepTrigger": { "presenceOfElement": "#instance-properties-editor" }, @@ -2146,6 +2147,7 @@ } }, { + "interactsWithCanvas": true, "nextStepTrigger": { "presenceOfElement": "#instance-properties-editor [id=\"Z Order\"]" }, @@ -2167,6 +2169,7 @@ { "elementToHighlightId": "#toolbar-open-properties-panel-button", "skippable": true, + "interactsWithCanvas": true, "nextStepTrigger": { "presenceOfElement": "#instance-properties-editor" }, From 83827e759ce62f6744b05b911f1300f7865f6cef Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 30 Nov 2026 15:20:49 +0000 Subject: [PATCH 06/13] [Fling game] Don't send the user back when publishing the game The publish step highlighted the publish button until the game link appeared, but the button disappears as soon as the export starts: after a second without its highlighted element, the tutorial went back to the "Share" step, behind the share dialog. Move on once the button is clicked; the next step waits for the link. --- tutorials/in-app/flingGame.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tutorials/in-app/flingGame.json b/tutorials/in-app/flingGame.json index 16d4c7e..f7e0ad8 100644 --- a/tutorials/in-app/flingGame.json +++ b/tutorials/in-app/flingGame.json @@ -3905,7 +3905,7 @@ "id": "ClickOnGenerateLink", "elementToHighlightId": "[id$=online-web-button][id^=launch-export]", "nextStepTrigger": { - "presenceOfElement": "#open-online-export-button" + "absenceOfElement": "[id$=online-web-button][id^=launch-export]" }, "tooltip": { "description": { From f80bbcd8a4b5ef25f088ddd28a0cba01b925b860 Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 30 Nov 2026 15:21:38 +0000 Subject: [PATCH 07/13] [Fling game] Let the user close the share dialog after opening the game The step asks to open the game then close the dialog, but the blocking layer only let the "Open" button be clicked: the dialog could not be closed. --- tutorials/in-app/flingGame.json | 1 + 1 file changed, 1 insertion(+) diff --git a/tutorials/in-app/flingGame.json b/tutorials/in-app/flingGame.json index f7e0ad8..7292fd5 100644 --- a/tutorials/in-app/flingGame.json +++ b/tutorials/in-app/flingGame.json @@ -3933,6 +3933,7 @@ "nextStepTrigger": { "absenceOfElement": "#export-game-share-dialog" }, + "disableBlockingLayer": true, "tooltip": { "description": { "messageByLocale": { From 8151b86bfc0f9d6fc32703e7652976291421d6ef Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 30 Nov 2026 15:41:21 +0000 Subject: [PATCH 08/13] [Fling game] Fix the new scene steps for the tree view project manager Scene items ids are now based on their position in the whole project manager tree, so #scene-item-1 never existed. Wait for a scene that is not the start scene instead (data-default, to be exposed by the editor). The renamed scene name was never gathered (it was read before the rename): split the step so the name is read once the scene is renamed, then ask to open it. --- tutorials/in-app/flingGame.json | 38 ++++++++++++++++++++++++++------- 1 file changed, 30 insertions(+), 8 deletions(-) diff --git a/tutorials/in-app/flingGame.json b/tutorials/in-app/flingGame.json index 7292fd5..231b041 100644 --- a/tutorials/in-app/flingGame.json +++ b/tutorials/in-app/flingGame.json @@ -4068,7 +4068,7 @@ { "elementToHighlightId": "#project-manager #add-new-scene-button", "nextStepTrigger": { - "presenceOfElement": "#scene-item-1" + "presenceOfElement": "#project-manager [id^=\"scene-item\"][data-scene]:not([data-default=\"true\"])" }, "tooltip": { "description": { @@ -4089,19 +4089,41 @@ } }, { - "elementToHighlightId": "#project-manager #scene-item-1", + "elementToHighlightId": "#project-manager [id^=\"scene-item\"][data-scene]:not([data-default=\"true\"])", + "nextStepTrigger": { + "absenceOfElement": "sceneInProjectManager:startScene" + }, + "mapProjectData": { + "startScene": "projectLastSceneName" + }, + "tooltip": { + "description": { + "messageByLocale": { + "en": "Right click on the new scene and change its name to “**StartScreen**”.", + "fr": "Faites un clic droit sur la nouvelle scène et changez son nom pour “**EcranOuverture**”.", + "es": "Haga clic derecho en la nueva escena y cambie su nombre a “**PantallaInicio**”.", + "pt": "Clique com o botão direito na nova cena e altere o nome para “**TelaInicial**”.", + "th": "คลิกขวาที่ scene ใหม่และเปลี่ยนชื่อเป็น “**StartScreen**”", + "ar": "نقرة بزر الفأرة الأيمن على المشهد الجديد وإعادة تسميته إلى **StartScreen**." + } + }, + "placement": "right" + } + }, + { + "elementToHighlightId": "sceneInProjectManager:startScene", "nextStepTrigger": { "presenceOfElement": "editorTab:startScene:Scene" }, "tooltip": { "description": { "messageByLocale": { - "en": "Right click on the new scene and change its name to “**StartScreen**”.\n\nOnce you're done, click on the item to open the new scene.", - "fr": "Faites un clic droit sur la nouvelle scène et changez son nom pour “**EcranOuverture**”.\n\nUne fois terminé, cliquez sur l'élément pour ouvrir la scène.", - "es": "Haga clic derecho en la nueva escena y cambie su nombre a “**PantallaInicio**”.\n\nUna vez terminado, haga clic en el elemento para abrir la escena.", - "pt": "Clique com o botão direito na nova cena e altere o nome para “**TelaInicial**”.\n\nUma vez terminado, clique no item para abrir a nova cena.", - "th": "คลิกขวาที่ scene ใหม่และเปลี่ยนชื่อเป็น “**StartScreen**”\n\nเมื่อเสร็จแล้ว คลิกที่ไอเทมเพื่อเปิด scene ใหม่", - "ar": "نقرة بزر الفأرة الأيمن على المشهد الجديد وإعادة تسميته إلى **StartScreen**.\n\nبمجرد الانتهاء، النقر عليه لفتح المشهد الجديد." + "en": "Once you're done, click on the item to open the new scene.", + "fr": "Une fois terminé, cliquez sur l'élément pour ouvrir la scène.", + "es": "Una vez terminado, haga clic en el elemento para abrir la escena.", + "pt": "Uma vez terminado, clique no item para abrir a nova cena.", + "th": "เมื่อเสร็จแล้ว คลิกที่ไอเทมเพื่อเปิด scene ใหม่", + "ar": "بمجرد الانتهاء، النقر عليه لفتح المشهد الجديد." } }, "placement": "right" From 3f19070f0372d6bda5e1e2581bd2bce0acf819f9 Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 30 Nov 2026 16:20:09 +0000 Subject: [PATCH 09/13] [Fling game] Check that the new scene is set as the start scene [data-default] was true for any start scene, including the initial one: check it on the new scene item (needs the editor to support a selector after the scene key). --- tutorials/in-app/flingGame.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tutorials/in-app/flingGame.json b/tutorials/in-app/flingGame.json index 231b041..cbbf97a 100644 --- a/tutorials/in-app/flingGame.json +++ b/tutorials/in-app/flingGame.json @@ -6439,7 +6439,7 @@ { "elementToHighlightId": "sceneInProjectManager:startScene", "nextStepTrigger": { - "presenceOfElement": "[id^=\"scene-item\"][data-default=\"true\"]" + "presenceOfElement": "sceneInProjectManager:startScene:[data-default=\"true\"]" }, "tooltip": { "description": { From 9768043f35444f52eaafce2a5564454adb4e9b4c Mon Sep 17 00:00:00 2001 From: Claude Date: Tue, 1 Dec 2026 13:09:52 +0000 Subject: [PATCH 10/13] [Fling game] Keep renaming and opening the new scene in a single step Renaming a scene also renames it in the tutorial data, so a step waiting for the old scene name to disappear never advances. --- tutorials/in-app/flingGame.json | 34 ++++++--------------------------- 1 file changed, 6 insertions(+), 28 deletions(-) diff --git a/tutorials/in-app/flingGame.json b/tutorials/in-app/flingGame.json index cbbf97a..78243b1 100644 --- a/tutorials/in-app/flingGame.json +++ b/tutorials/in-app/flingGame.json @@ -4090,40 +4090,18 @@ }, { "elementToHighlightId": "#project-manager [id^=\"scene-item\"][data-scene]:not([data-default=\"true\"])", - "nextStepTrigger": { - "absenceOfElement": "sceneInProjectManager:startScene" - }, - "mapProjectData": { - "startScene": "projectLastSceneName" - }, - "tooltip": { - "description": { - "messageByLocale": { - "en": "Right click on the new scene and change its name to “**StartScreen**”.", - "fr": "Faites un clic droit sur la nouvelle scène et changez son nom pour “**EcranOuverture**”.", - "es": "Haga clic derecho en la nueva escena y cambie su nombre a “**PantallaInicio**”.", - "pt": "Clique com o botão direito na nova cena e altere o nome para “**TelaInicial**”.", - "th": "คลิกขวาที่ scene ใหม่และเปลี่ยนชื่อเป็น “**StartScreen**”", - "ar": "نقرة بزر الفأرة الأيمن على المشهد الجديد وإعادة تسميته إلى **StartScreen**." - } - }, - "placement": "right" - } - }, - { - "elementToHighlightId": "sceneInProjectManager:startScene", "nextStepTrigger": { "presenceOfElement": "editorTab:startScene:Scene" }, "tooltip": { "description": { "messageByLocale": { - "en": "Once you're done, click on the item to open the new scene.", - "fr": "Une fois terminé, cliquez sur l'élément pour ouvrir la scène.", - "es": "Una vez terminado, haga clic en el elemento para abrir la escena.", - "pt": "Uma vez terminado, clique no item para abrir a nova cena.", - "th": "เมื่อเสร็จแล้ว คลิกที่ไอเทมเพื่อเปิด scene ใหม่", - "ar": "بمجرد الانتهاء، النقر عليه لفتح المشهد الجديد." + "en": "Right click on the new scene and change its name to “**StartScreen**”.\n\nOnce you're done, click on the item to open the new scene.", + "fr": "Faites un clic droit sur la nouvelle scène et changez son nom pour “**EcranOuverture**”.\n\nUne fois terminé, cliquez sur l'élément pour ouvrir la scène.", + "es": "Haga clic derecho en la nueva escena y cambie su nombre a “**PantallaInicio**”.\n\nUna vez terminado, haga clic en el elemento para abrir la escena.", + "pt": "Clique com o botão direito na nova cena e altere o nome para “**TelaInicial**”.\n\nUma vez terminado, clique no item para abrir a nova cena.", + "th": "คลิกขวาที่ scene ใหม่และเปลี่ยนชื่อเป็น “**StartScreen**”\n\nเมื่อเสร็จแล้ว คลิกที่ไอเทมเพื่อเปิด scene ใหม่", + "ar": "نقرة بزر الفأرة الأيمن على المشهد الجديد وإعادة تسميته إلى **StartScreen**.\n\nبمجرد الانتهاء، النقر عليه لفتح المشهد الجديد." } }, "placement": "right" From aa1860c9c32285928fb669650b1f8865923fa03c Mon Sep 17 00:00:00 2001 From: Claude Date: Tue, 1 Dec 2026 13:19:57 +0000 Subject: [PATCH 11/13] [Fling game] End the rename of the duplicated title before opening it A duplicated object starts in inline rename mode, where double clicking only selects the text of the name. --- tutorials/in-app/flingGame.json | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/tutorials/in-app/flingGame.json b/tutorials/in-app/flingGame.json index 78243b1..8ae4b3a 100644 --- a/tutorials/in-app/flingGame.json +++ b/tutorials/in-app/flingGame.json @@ -4491,6 +4491,25 @@ }, "skippable": true }, + { + "elementToHighlightId": "objectInObjectsList:startText", + "nextStepTrigger": { + "absenceOfElement": "#scene-editor[data-active] #objects-list input" + }, + "tooltip": { + "description": { + "messageByLocale": { + "en": "Press **Enter** to keep the name $(startText) for now.", + "fr": "Appuyez sur **Entrée** pour garder le nom $(startText) pour l'instant.", + "es": "Presione **Enter** para mantener el nombre $(startText) por ahora.", + "pt": "Pressione **Enter** para manter o nome $(startText) por enquanto.", + "th": "กด **Enter** เพื่อใช้ชื่อ $(startText) ไปก่อน", + "ar": "اضغط على **Enter** للاحتفاظ بالاسم $(startText) في الوقت الحالي." + } + }, + "placement": "left" + } + }, { "elementToHighlightId": "objectInObjectsList:startText", "nextStepTrigger": { From f63904123444c72e1dacc742e9c0fd8ae9c00e17 Mon Sep 17 00:00:00 2001 From: Claude Date: Tue, 1 Dec 2026 13:21:26 +0000 Subject: [PATCH 12/13] Check the scene state selector of sceneInProjectManager selectors Also accept the data-default and data-hidden attributes of the scene and layer tree view items. --- .../check-in-app-tutorial-selectors.spec.js | 30 +++++++++++++++++++ scripts/lib/InAppTutorialSelectorChecker.js | 23 +++++++++++++- 2 files changed, 52 insertions(+), 1 deletion(-) diff --git a/scripts/__tests__/check-in-app-tutorial-selectors.spec.js b/scripts/__tests__/check-in-app-tutorial-selectors.spec.js index 6b06cfa..5d43155 100644 --- a/scripts/__tests__/check-in-app-tutorial-selectors.spec.js +++ b/scripts/__tests__/check-in-app-tutorial-selectors.spec.js @@ -196,6 +196,36 @@ describe('checkTutorial', () => { expect(problems[0].reason).toMatch(/UnknownEditor/); }); + it('validates the state selector following a scene in the project manager', () => { + const tutorial = { + id: 'test', + initialProjectData: { gameScene: 'GameScene' }, + flow: [ + { + elementToHighlightId: 'sceneInProjectManager:gameScene', + nextStepTrigger: { + presenceOfElement: + 'sceneInProjectManager:gameScene:[data-state="x"]', + }, + }, + { + nextStepTrigger: { + presenceOfElement: + 'sceneInProjectManager:notDeclared:[data-default="true"]', + }, + }, + ], + }; + const problems = checkTutorial( + tutorial, + sourceBlob + '\ndefault: this._isStartScene()' + ); + expect(problems.map((problem) => problem.reason)).toEqual([ + 'attribute "data-state" was not found in the editor sources', + 'selector "sceneInProjectManager:notDeclared:[data-default="true"]" references project data key "notDeclared" which is not declared in initialProjectData or any mapProjectData', + ]); + }); + it('returns no problem for a fully valid tutorial', () => { const tutorial = { id: 'test', diff --git a/scripts/lib/InAppTutorialSelectorChecker.js b/scripts/lib/InAppTutorialSelectorChecker.js index 21f1a57..029bb72 100644 --- a/scripts/lib/InAppTutorialSelectorChecker.js +++ b/scripts/lib/InAppTutorialSelectorChecker.js @@ -95,9 +95,11 @@ const DYNAMIC_ID_FAMILIES = [ * be found in the sources. */ const KNOWN_CAMEL_CASE_DATASET_KEYS = [ + 'default', 'effective', 'global', 'groupName', + 'hidden', 'isFiltered', ]; @@ -306,6 +308,17 @@ const extractSelectorUsages = (tutorial) => { return usages; }; +/** + * `sceneInProjectManager:` can be followed by a selector checking the + * state of the scene item (e.g. `sceneInProjectManager:startScene:[data-default="true"]`). + * @param {string} selector + * @returns {{ sceneKey: string, stateSelector: string }} + */ +const getSceneInProjectManagerParts = (selector) => { + const [, sceneKey, ...stateSelectorParts] = selector.split(':'); + return { sceneKey, stateSelector: stateSelectorParts.join(':') }; +}; + /** * Checks a project data accessor selector (e.g. `objectInObjectsList:player`) * or an `editorIsActive` value against the keys declared by the tutorial. @@ -357,7 +370,9 @@ const checkProjectDataAccessor = (selector, field, declaredDataKeys) => { return reasons; } - const dataKey = selector.slice(selector.indexOf(':') + 1); + const dataKey = selector.startsWith('sceneInProjectManager:') + ? getSceneInProjectManagerParts(selector).sceneKey + : selector.slice(selector.indexOf(':') + 1); if (!declaredDataKeys.has(dataKey)) { return [ `selector "${selector}" references project data key "${dataKey}" which is not declared in initialProjectData or any mapProjectData`, @@ -429,6 +444,12 @@ const checkTutorial = (tutorial, sourceBlob) => { const reasons = isProjectDataAccessor ? checkProjectDataAccessor(usage.selector, usage.field, declaredDataKeys) : checkCssSelector(usage.selector, sourceBlob); + if (usage.selector.startsWith('sceneInProjectManager:')) { + const { stateSelector } = getSceneInProjectManagerParts(usage.selector); + if (stateSelector) { + reasons.push(...checkCssSelector(stateSelector, sourceBlob)); + } + } for (const reason of reasons) { problems.push({ tutorialId: tutorial.id, From 7b9e77139df391412a862f900f8119063c93ea23 Mon Sep 17 00:00:00 2001 From: Claude Date: Tue, 1 Dec 2026 13:38:11 +0000 Subject: [PATCH 13/13] [Fling game] Use the visible "Mouse button released" condition MouseButtonReleased is hidden: the condition listed in the editor is MouseButtonFromTextReleased, whose button values are quoted. --- tutorials/in-app/flingGame.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tutorials/in-app/flingGame.json b/tutorials/in-app/flingGame.json index 8ae4b3a..18e868f 100644 --- a/tutorials/in-app/flingGame.json +++ b/tutorials/in-app/flingGame.json @@ -4795,7 +4795,7 @@ { "elementToHighlightId": "#instruction-editor-dialog #search-bar", "nextStepTrigger": { - "presenceOfElement": "#instruction-item-MouseButtonReleased" + "presenceOfElement": "#instruction-item-MouseButtonFromTextReleased" }, "tooltip": { "description": { @@ -4812,7 +4812,7 @@ "isOnClosableDialog": true }, { - "elementToHighlightId": "#instruction-item-MouseButtonReleased", + "elementToHighlightId": "#instruction-item-MouseButtonFromTextReleased", "nextStepTrigger": { "presenceOfElement": "#instruction-parameters-container" }, @@ -4833,7 +4833,7 @@ { "elementToHighlightId": "#instruction-parameters-container select", "nextStepTrigger": { - "valueEquals": "Left" + "valueEquals": "\"Left\"" }, "tooltip": { "description": {