Hierarchy

  • IFrameHelper

Constructors

Methods

  • Forwards event data to parent page.
    CbnPlugin retrieves this event data and pushes it directly into the "data layer", which can then be interpreted by the Google Tag Manager.
    If the configurator is not embedded in an IFrame, the event is pushed directly into the data layer of the current window.

    Parameters

    • event: string

      key for event identification

    • Optional eventData: string | object

      optional event data

    Returns void

  • Checks if the page is opened inside an IFrame

    Returns boolean

  • Updates the parent windows scroll position to show the IFrame at the top left.
    Can be adjusted by offsetX & offsetY.

    !!! Note !!!

    Only adjusts the scroll position of the window itself and therefore won't work if the IFrame is embedded inside another element with a scrollbar...

    Parameters

    • Optional offsetX: number
    • Optional offsetY: number

    Returns void

  • Send a custom message to the parent page via the "CustomMessage".
    The parent page can handle those messages by implementing the function Combeenation.on{msgName}.

    Parameters

    • msgName: string
    • Optional data: object

    Returns void

  • Changes the width and/or height of the IFrame and/or scroll position of the parent page window.
    Won't do anything if we are not inside an IFrame.
    Sends an "silent" error to raygun if we are inside an IFrame but the CbnPlugin is not correctly installed on the parent site.

    Parameters

    • Optional width: number

      If not given or 0, the width is not changed

    • Optional height: number

      If not given or 0, the height is not changed

    • Optional scrollToX: number

      New horizontal scroll position of the parent page window

    • Optional scrollToY: number

      New vertical scroll position of the parent page window

    Returns void

Generated using TypeDoc