twisto-widget-modal

Standalone modal. Visibility is controlled by the is-opened attribute — set to "true" to show.

Step 1: Add this script to the page ⬇️

<script src="https://cdn.twistopay.com/widget/twisto-widget.js" async></script>

Step 2: Insert the modal and a trigger button ⬇️

<button id="open-twisto-modal">Open Twisto info</button> <twisto-widget-modal product="pay-in-3" language="cs" theme="light" is-opened="false" ></twisto-widget-modal> <script> document.getElementById('open-twisto-modal').addEventListener('click', function() { document.querySelector('twisto-widget-modal').setAttribute('is-opened', 'true'); }); </script>

The modal also supports combination="bnpl+pay-in-3" to display Pay in 3 + Pay in 30 days content together.

 

Attributes

The modal has two variants:

  • Static — displayed when amount and currency are not provided. Always shows all services.
  • Dynamic — displayed when amount and currency are provided. Shows calculated amounts per service.
AttributeDescriptionTypeDefault value
productName of Twisto product. Options: pay-in-30-days, pay-in-3, paid-bnpl.Stringnull
combinationUse bnpl+pay-in-3 to explicitly show BNPL + Pay in 3 together. Optional.Stringnull
amountProduct price. When provided together with currency, enables the dynamic variant with calculated amounts.Numbernull
currencyCurrency of amount. Required with amount. For example, CZK, EUR, PLN, etc.Stringnull
languageLanguage. Options: cs, en or pl.Stringen
themeTheme. Options: light or dark.Stringlight
widthModal width. Options: auto or full.Stringauto
merchant-nameYour e-shop name. Optional.Stringnull
is-openedControls visibility. Set to "true" to show, "false" to hide.Boolean"false"

For a full list of available attributes, see How to edit Twisto widgets.

 

Examples

Pay in 3

<button id="open-twisto-modal">Open Twisto info</button> <twisto-widget-modal product="pay-in-3" language="cs" theme="light" is-opened="false" ></twisto-widget-modal> <script> document.getElementById('open-twisto-modal').addEventListener('click', function () { document.querySelector('twisto-widget-modal').setAttribute('is-opened', 'true') }) </script>