From 29840ea4c262313567225135183cf35dcdc76f89 Mon Sep 17 00:00:00 2001 From: Olivier Buisard Date: Wed, 31 Jul 2024 16:55:53 -0400 Subject: [PATCH 1/4] Added auto-start and events information --- docs/general-concepts/guided-tours.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/docs/general-concepts/guided-tours.md b/docs/general-concepts/guided-tours.md index 9f11fea1..f02f4570 100644 --- a/docs/general-concepts/guided-tours.md +++ b/docs/general-concepts/guided-tours.md @@ -75,6 +75,22 @@ Note that the Guided Tour component knows how to differentiate category tours fo There is no available tour when editing a specific module, plugin or template. That is where launching a tour from anywhere can become handy. +### Auto start + +Starting with Joomla 5.2, you can set tours to auto start. Those tours will run automatically once a user enters the context of the tour. Once a tour auto starts, the user can hide the tour forever (although the tour can still be run manually), and a cancellation will delay the tour for a later run. Once a specific time has passed (the delay setting can be found in the Global Configuration of the Guided Tours - it defaults to 1 hour), the tour will run again automatically, once in context. + + +### Event dispatchers + +Once a user cancels, opts-out or completes a tour, events are triggered, allowing developers to act according to user actions. One may want to send a message to a user after completion of a tour in order to propose another one, for instance. +Those events are: +- onBeforeTourRunSaveState: triggered before saving the auto-start tour user state and recording user action logs +- onTourRunSaveState: triggered before saving the auto-start tour user state, used to record user actions into the logs +- onAfterTourRunSaveState: triggered after saving the auto-start tour user state and recording user action logs + +You can find those events in the AjaxController. + + ## Launching a tour from any location Launching a tour from a different location than the Guided Tours module is as easy as adding the attribute `data-gt-uid` with the identifier of the tour. From be971edce5fe93b7d514aa3e7e3b7f0d46058a29 Mon Sep 17 00:00:00 2001 From: Olivier Buisard Date: Thu, 1 Aug 2024 12:14:45 -0400 Subject: [PATCH 2/4] Changed event paragraph --- docs/general-concepts/guided-tours.md | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/docs/general-concepts/guided-tours.md b/docs/general-concepts/guided-tours.md index f02f4570..e94484b5 100644 --- a/docs/general-concepts/guided-tours.md +++ b/docs/general-concepts/guided-tours.md @@ -84,11 +84,10 @@ Starting with Joomla 5.2, you can set tours to auto start. Those tours will run Once a user cancels, opts-out or completes a tour, events are triggered, allowing developers to act according to user actions. One may want to send a message to a user after completion of a tour in order to propose another one, for instance. Those events are: -- onBeforeTourRunSaveState: triggered before saving the auto-start tour user state and recording user action logs -- onTourRunSaveState: triggered before saving the auto-start tour user state, used to record user actions into the logs -- onAfterTourRunSaveState: triggered after saving the auto-start tour user state and recording user action logs +- onBeforeTourSaveUserState: triggered before saving the auto-start tour user state (used to record states in the User Action Logs), +- onAfterTourSaveUserState: triggered after saving the auto-start tour user state. -You can find those events in the AjaxController. +You can find those events in the AjaxController class. ## Launching a tour from any location From 7ae776e02f7db2037b500587845fa583b82ec065 Mon Sep 17 00:00:00 2001 From: Olivier Buisard Date: Wed, 4 Sep 2024 19:49:02 -0400 Subject: [PATCH 3/4] Update guided-tours.md Added information about image inclusion. --- docs/general-concepts/guided-tours.md | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/docs/general-concepts/guided-tours.md b/docs/general-concepts/guided-tours.md index e94484b5..7658e97b 100644 --- a/docs/general-concepts/guided-tours.md +++ b/docs/general-concepts/guided-tours.md @@ -87,7 +87,14 @@ Those events are: - onBeforeTourSaveUserState: triggered before saving the auto-start tour user state (used to record states in the User Action Logs), - onAfterTourSaveUserState: triggered after saving the auto-start tour user state. -You can find those events in the AjaxController class. +You can find those events in the AjaxController class. + + +### Adding images to the content + +Use the editor to include images inside the content descriptions. Images are located in the media folder, ```/images``` by default. +However, expecially when creating a tour for a third party extension, you may want to include images located in the media folder of the extension. +In this case, the image path must start with ```media/...```. ## Launching a tour from any location From 0c4b66da3c71c0a43559d2e5617219b73db98129 Mon Sep 17 00:00:00 2001 From: Olivier Buisard Date: Sun, 29 Sep 2024 14:18:32 -0400 Subject: [PATCH 4/4] Improved wording of triggering events --- docs/general-concepts/guided-tours.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/general-concepts/guided-tours.md b/docs/general-concepts/guided-tours.md index 7658e97b..dbcd2427 100644 --- a/docs/general-concepts/guided-tours.md +++ b/docs/general-concepts/guided-tours.md @@ -83,9 +83,9 @@ Starting with Joomla 5.2, you can set tours to auto start. Those tours will run ### Event dispatchers Once a user cancels, opts-out or completes a tour, events are triggered, allowing developers to act according to user actions. One may want to send a message to a user after completion of a tour in order to propose another one, for instance. -Those events are: -- onBeforeTourSaveUserState: triggered before saving the auto-start tour user state (used to record states in the User Action Logs), -- onAfterTourSaveUserState: triggered after saving the auto-start tour user state. +Those events are triggered at different stages: +- onBeforeTourSaveUserState: before saving the auto-start tour user state (used to record states in the User Action Logs), +- onAfterTourSaveUserState: after saving the auto-start tour user state. You can find those events in the AjaxController class.