Inline mode

By default, the widget runs in modal mode. To use the widget in inline mode, employ the setOptions method:

window.transactionlink.setOptions({
  inline: true // boolean,
  autoHeight: true, // boolean, enables automatic height adjustment based on content
  showCloseButton: undefined, // boolean | undefined - if set to true, displays the close button in inline mode; defaults to undefined (hidden)
  ...otherOptions
});
  • When autoHeight is enabled, the widget or iframe will dynamically adjust its size based on the content inside, ensuring proper rendering without requiring a fixed height.

  • The showCloseButton option controls whether a close button appears in inline mode. By default, it is undefined, meaning the button is hidden. If explicitly set to true, the button will be displayed.

Note that the optimal way to use the widget in inline mode is to place the widget element inside a container with fixed width and height:

<div class="widget-wrapper">
    <div id="transactionlink-widget" />
</div>
.widget-wrapper {
  width: 100%;
  height: 100%;
}

This ensures proper rendering and display of the inline widget.

Last updated

Was this helpful?