Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion src/coffee/bootstrap-tour.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -683,7 +683,11 @@
width: $backdropElement.innerWidth()
height: $backdropElement.innerHeight()
offset: $backdropElement.offset()

#If element is in a distinct iframe, calculate offset based on viewport selector
if $backdropElement[0].ownerDocument != window.document && @_options.viewport
$offsetContainer = $(@_options.viewport.selector).offset()
elementData.offset.top+=$offsetContainer.top
elementData.offset.top+=$offsetContainer.left
$backdropElement.addClass 'tour-step-backdrop'
elementData = @_applyBackdropPadding step.backdropPadding, elementData if step.backdropPadding

Expand Down