Using the following method, you can run callback when a UserGuiding preview end;

window.userGuidingLayer.push({ 
  event: 'onPreviewEnd',
  fn: _YOUR_FUNCTION_HERE_
})


example call

window.userGuidingLayer.push({
  event: 'onPreviewEnd',
  fn: (data) => console.log(data)
})

example output (logs to console)

{   
  completed: false, // false if user bounced  
  guideId: 123456
}

See other available methods;

onPreviewStart
onPreviewStep

Did this answer your question?