Open rlee1990 opened 1 month ago
@lukepighetti this is quite important for us also. Is there any possibilities?
@rlee1990 I think a way that this could be done is to provide your own actionBuilder
widget, and here you will receive a CalloutActionController
controller. The controller has some properties
/// The current target's index.
final int index;
/// The total number of targets.
final int pages;
/// Convenience getter for if we're currently on the last page.
bool get isLastPage => index + 1 == pages;
/// Convenience getter for if we're currently on the first page.
bool get isFirstPage => index == 0;
You can then check controller.isLastPage in your next button onPressed callback and handle done
Pretty much copy this default design https://github.com/lukepighetti/flutter_hotspot/blob/main/lib/src/hotspot_action_builder.dart and handle the last page check just above controller.next()
Is there a way to know when the done button is pressed or when the tour is done?