Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@abtasty/modal

Package Overview
Dependencies
Maintainers
18
Versions
201
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@abtasty/modal - npm Package Compare versions

Comparing version 2.5.12-0 to 2.5.12

2

dist/form.js

@@ -1,1 +0,1 @@

!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):e.widgetForm=t()}(this,function(){"use strict";var e={backgroundGroup:{propName:"backgroundGroup",category:"style",type:"group",label:{en:"Background",fr:"Fond"},collapsible:!0,children:[{propName:"backgroundColor",type:"colorpicker",category:"style",label:{en:"Background color",fr:"Couleur d'arrière-plan"},value:"rgba(255, 255, 255, 1)",conditions:[{field:"layout",value:function(e){return"no-title"!==e&&"imageOnly"!==e}}]},{category:"style",type:"short-separator",propName:"backgroundImage-style-separator",conditions:[{field:"layout",value:function(e){return"no-title"!==e&&"imageOnly"!==e}}]},{propName:"backgroundImage",type:"mediaupload",category:"style",label:{en:"Background image",fr:"Image d'arrière-plan"},conditions:[{field:"layout",value:function(e){return"no-title"!==e&&"imageOnly"!==e}}]},{category:"style",type:"short-separator",propName:"overlay-style-separator",conditions:[{field:"layout",value:function(e){return"no-title"!==e&&"imageOnly"!==e}}]},{propName:"overlayOpacity",type:"slider",category:"style",label:{en:"Overlay opacity",fr:"Opacité de l'overlay"},value:"50",unit:"%"}]},borderGroup:{propName:"borderGroup",category:"style",type:"group",label:{en:"Border",fr:"Bordure"},collapsible:!0,children:[{propName:"borderWidth",category:"style",type:"slider",unit:"px",value:0,min:0,max:10,label:{en:"Border Thickness",fr:"Largeur de la bordure"}},{category:"style",type:"short-separator",propName:"borderRadius-style-separator"},{propName:"borderRadius",category:"style",type:"slider",unit:"px",value:10,min:0,max:20,label:{en:"Border radius",fr:"Angle de la bordure"}},{category:"style",type:"short-separator",propName:"borderRadiusImage-separator",conditions:[{field:"layout",value:function(e){return"imageOnly"!==e}}]},{propName:"borderRadiusImage",category:"style",type:"slider",unit:"px",value:10,min:0,max:20,label:{en:"Image Border radius",fr:"Angle de la bordure de l'image"},conditions:[{field:"layout",value:function(e){return"imageOnly"!==e}}]},{category:"style",type:"short-separator",propName:"borderColor-style-separator"},{propName:"borderColor",category:"style",type:"colorpicker",label:{en:"Border color",fr:"Couleur de la bordure"},value:"rgba(0, 0, 0, 1)"}]},closeButtonGroup:{propName:"closeButtonGroup",category:"style",type:"group",label:{en:"Close button",fr:"Bouton de fermeture"},collapsible:!0,children:[{propName:"closeButtonPosition",category:"style",type:"radio",label:{en:"Close button position",fr:"Position du bouton de fermeture"},value:"inside",options:[{label:{en:"Inside",fr:"À l'intérieur"},value:"inside"},{label:{en:"Outside",fr:"À l'extérieur"},value:"outside"}]},{category:"style",type:"short-separator",propName:"closeButtonColor-style-separator"},{propName:"closeButtonColor",type:"colorpicker",category:"style",label:{en:"Close button color",fr:"Couleur du bouton de fermeture"},value:"rgba(92, 92, 92, 1)"},{category:"style",type:"short-separator",propName:"closeBackgroundButtonColor-style-separator",conditions:[{field:"closeButtonPosition",value:"outside"}]},{propName:"backgroundCloseButtonColor",type:"colorpicker",category:"style",label:{en:"Background close button color",fr:"Couleur du fond du bouton de fermeture"},value:"rgba(255, 255, 255, 1)",conditions:[{field:"closeButtonPosition",value:"outside"}]}]},dimensions:[{propName:"widthImageWithText",type:"radio",category:"style",label:{en:"Width",fr:"Largeur"},value:"medium",options:[{label:{en:"Small",fr:"Petite"},value:"small"},{label:{en:"Medium",fr:"Moyenne"},value:"medium"},{label:"Large",value:"large"},{label:{en:"Custom",fr:"Sur mesure"},value:"custom"}],conditions:[{field:"type",value:function(e){return"video"!==e}},{field:"layout",value:function(e){return"imageOnly"!==e}}]},{propName:"widthImageOnly",type:"radio",category:"style",label:{en:"Width",fr:"Largeur"},value:"fit",options:[{label:{en:"Fit to size",fr:"S'adapte à la taille"},value:"fit"},{label:{en:"Small",fr:"Petite"},value:"small"},{label:{en:"Medium",fr:"Moyenne"},value:"medium"},{label:"Large",value:"large"}],conditions:[{field:"type",value:function(e){return"video"!==e}},{field:"layout",value:function(e){return"imageOnly"===e}}]},{propName:"customWidth",type:"number",category:"style",label:{en:"Custom width (%)",fr:"Largeur sur mesure (%)"},value:50,conditions:[{field:"widthImageWithText",value:"custom"}]}],animations:[{category:"style",type:"separator",propName:"animation-separator"},{propName:"animation",type:"radio",category:"style",label:"Animation",value:"none",options:[{label:{en:"None",fr:"Aucune"},value:"none"},{label:"slide In",value:"slideIn"},{label:"Fade In",value:"fadeIn"}]}]},t=[{propName:"recurrence",type:"select",category:"conditions",label:{en:"Recurrence",fr:"Récurrence"},value:"-1",options:[{label:{en:"Every time",fr:"Chaque page"},value:"-1"},{label:{en:"Every session",fr:"Chaque session"},value:"0"},{label:{en:"Everyday",fr:"Chaque jour"},value:"1"},{label:{en:"Every week",fr:"Chaque semaine"},value:"7"},{label:{en:"Every month",fr:"Chaque mois"},value:"30"},{label:{en:"Once per user (no recurrence)",fr:"Une fois par visiteur (pas de récurrence)"},value:"365"}]},{category:"conditions",type:"separator",propName:"triggerEvent-separator"},{propName:"triggerEvent",type:"select",category:"conditions",label:{en:"Triggers on",fr:"Se déclenche au"},value:"pageLoad",options:[{label:{en:"Page load",fr:"Chargement de la page"},value:"pageLoad"},{label:{en:"Click",fr:"Clic"},value:"click"},{label:{en:"Exit intent",fr:"Avant fermeture de l'onglet"},value:"exitIntent"},{label:{en:"Delay",fr:"Délai"},value:"timer"},{label:{en:"Reengage (after inactivity)",fr:"Réengagement (après inactivité)"},value:"reengage"}]},{propName:"clickEventSelector",type:"selectelement",category:"conditions",label:{en:"DOM element to listen to",fr:"Élément du DOM à écouter"},placeholder:{en:"Please select an element in the webpage",fr:"Veuillez sélectionner un élément dans la page"},conditions:[{field:"triggerEvent",value:"click"}]},{propName:"exitEventDelay",type:"number",category:"conditions",label:{en:"Delay after leaving",fr:"Délai avant affichage (après sortie de page)"},min:0,max:120,value:0,conditions:[{field:"triggerEvent",value:"exitIntent"}]},{propName:"reengageEventDelay",type:"number",category:"conditions",label:{en:"Delay before reengagement",fr:"Délai d'inactivité avant affichage"},min:1,max:120,value:10,conditions:[{field:"triggerEvent",value:"reengage"}]},{propName:"triggerEventDelay",type:"number",category:"conditions",label:{en:"Trigger event delay (in seconds)",fr:"Délai avant l'affichage (en secondes)"},value:10,conditions:[{field:"triggerEvent",value:"timer"}]}],o={title:{propName:"title",type:"wysiwyg",category:"content",label:{en:"Title",fr:"Titre"},placeholder:{en:"Some title",fr:"Mon titre"},value:{en:"Title",fr:"Titre"},conditions:[{field:"layout",value:function(e){return"no-title"!==e&&"imageOnly"!==e}}]},buttonSettings:[{category:"content",type:"separator",propName:"button-separator"},{propName:"button",category:"content",type:"switch",value:!1,label:{en:"Add a button",fr:"Ajouter un bouton"}},{propName:"buttonText",type:"text",category:"content",label:{en:"Button text",fr:"Texte du bouton"},value:{en:"Accept",fr:"Valider"},placeholder:{en:"Submit",fr:"Valider"},conditions:[{field:"button"}]},{propName:"buttonLink",type:"text",category:"content",label:{en:"Button link",fr:"Lien du bouton"},value:"https://www.google.com",conditions:[{field:"button"}]},{propName:"buttonTextColor",category:"content",type:"colorpicker",label:{en:"Button text color",fr:"Couleur du texte du bouton"},value:"rgba(255, 255, 255, 1)",conditions:[{field:"button"}]},{propName:"buttonBackgroundColor",category:"content",type:"colorpicker",label:{en:"Button background color",fr:"Couleur de fond du bouton"},value:"rgba(86, 159, 242, 1)",conditions:[{field:"button"}]}]};function a(e){if(Array.isArray(e)){for(var t=0,o=Array(e.length);t<e.length;t++)o[t]=e[t];return o}return Array.from(e)}var r=[{propName:"type",value:"image",type:"hidden",category:"layout"},{propName:"layout",category:"layout",value:"imageOnly",type:"radioImage",options:[{label:{en:"Image only",fr:"Image seule"},value:"imageOnly",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/image/image-only.png"},{label:{en:"Left",fr:"Gauche"},value:"left",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/image/left.png"},{label:{en:"Right",fr:"Droite"},value:"right",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/image/right.png"},{label:{en:"Top",fr:"Haut"},value:"top",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/image/top.png"},{label:{en:"Bottom",fr:"Bas"},value:"bottom",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/image/bottom.png"}]},{propName:"image",type:"mediaupload",category:"content",label:"Image"},{category:"content",type:"separator",propName:"title-separator",conditions:[{field:"layout",value:function(e){return"no-title"!==e&&"imageOnly"!==e}}]},o.title,{category:"content",type:"separator",propName:"wysiwyg-content-separator",conditions:[{field:"layout",value:function(e){return"imageOnly"!==e}}]},{propName:"content",type:"wysiwyg",category:"content",label:{en:"Content",fr:"Contenu"},value:"Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.",conditions:[{field:"layout",value:function(e){return"imageOnly"!==e}}]}].concat(a(o.buttonSettings),a(e.dimensions),[{type:"separator",category:"style"},e.backgroundGroup,{type:"separator",category:"style"},e.borderGroup,{type:"separator",category:"style"},e.closeButtonGroup],a(e.animations),a(t));function n(e){if(Array.isArray(e)){for(var t=0,o=Array(e.length);t<e.length;t++)o[t]=e[t];return o}return Array.from(e)}var l=[{propName:"type",value:"simple",type:"hidden",category:"layout"},{propName:"layout",category:"layout",value:"center",type:"radioImage",options:[{label:{en:"Center",fr:"Centre"},value:"center",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/simple/center.png"},{label:{en:"Left",fr:"Gauche"},value:"left",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/simple/left.png"},{label:{en:"Right",fr:"Droite"},value:"right",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/simple/right.png"}]},o.title,{category:"content",type:"separator",propName:"title-content-separator"},{propName:"content",type:"wysiwyg",category:"content",label:{en:"Content",fr:"Contenu"},value:"Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum."}].concat(n(o.buttonSettings),n(e.dimensions),[{type:"separator",category:"style"},e.backgroundGroup,{type:"separator",category:"style"},e.borderGroup,{type:"separator",category:"style"},e.closeButtonGroup],n(e.animations),n(t));function i(e){if(Array.isArray(e)){for(var t=0,o=Array(e.length);t<e.length;t++)o[t]=e[t];return o}return Array.from(e)}var u=[{propName:"type",value:"video",type:"hidden",category:"layout"},{propName:"layout",category:"layout",value:"no-title",type:"radioImage",options:[{label:{en:"No title",fr:"Sans titre"},value:"no-title",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/video/video-only.png"},{label:{en:"Top",fr:"Haut"},value:"top",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/video/bottom.png"},{label:{en:"Bottom",fr:"Bas"},value:"bottom",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/video/top.png"}]},o.title,{propName:"videoLink",type:"text",category:"content",label:{en:"URL (Youtube or Vimeo)",fr:"URL (Youtube ou Vimeo)"},value:"https://www.youtube.com/watch?v=XyGGixAg3bE"}].concat(i(o.buttonSettings),i(e.dimensions),[{type:"separator",category:"style",conditions:[{field:"type",value:function(e){return"video"!==e}},{field:"layout",value:function(e){return"imageOnly"!==e}}]},e.backgroundGroup,{type:"separator",category:"style"},e.borderGroup,{type:"separator",category:"style"},e.closeButtonGroup],i(e.animations),i(t),[{category:"content",type:"separator",propName:"autoPlay-separator"},{propName:"autoPlay",category:"conditions",type:"switch",value:!1,label:{en:"Auto play (Youtube only)",fr:"Lecture automatique (Youtube uniquement)"}}]),s=void 0,p=document.getElementById("abtasty-widget-react-form__widget");if(p){var c=p.getAttribute("data-plugin-id");s="0b34ffa7-dd00-4ab2-ac28-51f63a64e795"===c?l:"c7009087-6559-45e5-bcdd-eda375a13886"===c?u:r}else s=r;return s});
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):e.widgetForm=t()}(this,function(){"use strict";var e={backgroundGroup:{propName:"backgroundGroup",category:"style",type:"group",label:{en:"Background",fr:"Fond"},collapsible:!0,children:[{propName:"backgroundColor",type:"colorpicker",category:"style",label:{en:"Background color",fr:"Couleur d'arrière-plan"},value:"rgba(255, 255, 255, 1)",conditions:[{field:"layout",value:function(e){return"no-title"!==e&&"imageOnly"!==e}}]},{category:"style",type:"short-separator",propName:"backgroundImage-style-separator",conditions:[{field:"layout",value:function(e){return"no-title"!==e&&"imageOnly"!==e}}]},{propName:"backgroundImage",type:"mediaupload",category:"style",label:{en:"Background image",fr:"Image d'arrière-plan"},conditions:[{field:"layout",value:function(e){return"no-title"!==e&&"imageOnly"!==e}}]},{category:"style",type:"short-separator",propName:"overlay-style-separator",conditions:[{field:"layout",value:function(e){return"no-title"!==e&&"imageOnly"!==e}}]},{propName:"overlayOpacity",type:"slider",category:"style",label:{en:"Overlay opacity",fr:"Opacité de l'overlay"},value:"50",unit:"%"}]},borderGroup:{propName:"borderGroup",category:"style",type:"group",label:{en:"Border",fr:"Bordure"},collapsible:!0,children:[{propName:"borderWidth",category:"style",type:"slider",unit:"px",value:0,min:0,max:10,label:{en:"Border Thickness",fr:"Largeur de la bordure"}},{category:"style",type:"short-separator",propName:"borderRadius-style-separator"},{propName:"borderRadius",category:"style",type:"slider",unit:"px",value:10,min:0,max:20,label:{en:"Border radius",fr:"Angle de la bordure"}},{category:"style",type:"short-separator",propName:"borderRadiusImage-separator",conditions:[{field:"layout",value:function(e){return"imageOnly"!==e}}]},{propName:"borderRadiusImage",category:"style",type:"slider",unit:"px",value:10,min:0,max:20,label:{en:"Image Border radius",fr:"Angle de la bordure de l'image"},conditions:[{field:"layout",value:function(e){return"imageOnly"!==e}}]},{category:"style",type:"short-separator",propName:"borderColor-style-separator"},{propName:"borderColor",category:"style",type:"colorpicker",label:{en:"Border color",fr:"Couleur de la bordure"},value:"rgba(0, 0, 0, 1)"}]},closeButtonGroup:{propName:"closeButtonGroup",category:"style",type:"group",label:{en:"Close button",fr:"Bouton de fermeture"},collapsible:!0,children:[{propName:"closeButtonPosition",category:"style",type:"radio",label:{en:"Close button position",fr:"Position du bouton de fermeture"},value:"inside",options:[{label:{en:"Inside",fr:"À l'intérieur"},value:"inside"},{label:{en:"Outside",fr:"À l'extérieur"},value:"outside"}]},{category:"style",type:"short-separator",propName:"closeButtonColor-style-separator"},{propName:"closeButtonColor",type:"colorpicker",category:"style",label:{en:"Close button color",fr:"Couleur du bouton de fermeture"},value:"rgba(92, 92, 92, 1)"},{category:"style",type:"short-separator",propName:"closeBackgroundButtonColor-style-separator",conditions:[{field:"closeButtonPosition",value:"outside"}]},{propName:"backgroundCloseButtonColor",type:"colorpicker",category:"style",label:{en:"Background close button color",fr:"Couleur du fond du bouton de fermeture"},value:"rgba(255, 255, 255, 1)",conditions:[{field:"closeButtonPosition",value:"outside"}]}]},dimensions:[{propName:"widthImageWithText",type:"radio",category:"style",label:{en:"Width",fr:"Largeur"},value:"medium",options:[{label:{en:"Small",fr:"Petite"},value:"small"},{label:{en:"Medium",fr:"Moyenne"},value:"medium"},{label:"Large",value:"large"},{label:{en:"Custom",fr:"Sur mesure"},value:"custom"}],conditions:[{field:"type",value:function(e){return"video"!==e}},{field:"layout",value:function(e){return"imageOnly"!==e}}]},{propName:"widthImageOnly",type:"radio",category:"style",label:{en:"Width",fr:"Largeur"},value:"fit",options:[{label:{en:"Fit to size",fr:"S'adapte à la taille"},value:"fit"},{label:{en:"Small",fr:"Petite"},value:"small"},{label:{en:"Medium",fr:"Moyenne"},value:"medium"},{label:"Large",value:"large"}],conditions:[{field:"type",value:function(e){return"video"!==e}},{field:"layout",value:function(e){return"imageOnly"===e}}]},{propName:"customWidth",type:"number",category:"style",label:{en:"Custom width (%)",fr:"Largeur sur mesure (%)"},value:50,conditions:[{field:"widthImageWithText",value:"custom"}]}],animations:[{category:"style",type:"separator",propName:"animation-separator"},{propName:"animation",type:"radio",category:"style",label:"Animation",value:"none",options:[{label:{en:"None",fr:"Aucune"},value:"none"},{label:"slide In",value:"slideIn"},{label:"Fade In",value:"fadeIn"}]}]},t=[{propName:"recurrence",type:"select",category:"conditions",label:{en:"Recurrence",fr:"Récurrence"},value:"-1",options:[{label:{en:"Every time",fr:"Chaque page"},value:"-1"},{label:{en:"Every session",fr:"Chaque session"},value:"0"},{label:{en:"Everyday",fr:"Chaque jour"},value:"1"},{label:{en:"Every week",fr:"Chaque semaine"},value:"7"},{label:{en:"Every month",fr:"Chaque mois"},value:"30"},{label:{en:"Once per user (no recurrence)",fr:"Une fois par visiteur (pas de récurrence)"},value:"365"}]},{category:"conditions",type:"separator",propName:"triggerEvent-separator"},{propName:"triggerEvent",type:"select",category:"conditions",label:{en:"Triggers on",fr:"Se déclenche au"},value:"pageLoad",options:[{label:{en:"Page load",fr:"Chargement de la page"},value:"pageLoad"},{label:{en:"Click",fr:"Clic"},value:"click"},{label:{en:"Exit intent",fr:"Avant fermeture de l'onglet"},value:"exitIntent"},{label:{en:"Delay",fr:"Délai"},value:"timer"},{label:{en:"Reengage (after inactivity)",fr:"Réengagement (après inactivité)"},value:"reengage"}]},{propName:"clickEventSelector",type:"selectelement",category:"conditions",label:{en:"DOM element to listen to",fr:"Élément du DOM à écouter"},placeholder:{en:"Please select an element in the webpage",fr:"Veuillez sélectionner un élément dans la page"},conditions:[{field:"triggerEvent",value:"click"}]},{propName:"exitEventDelay",type:"number",category:"conditions",label:{en:"Delay after leaving",fr:"Délai avant affichage (après sortie de page)"},min:0,max:120,value:0,conditions:[{field:"triggerEvent",value:"exitIntent"}]},{propName:"reengageEventDelay",type:"number",category:"conditions",label:{en:"Delay before reengagement",fr:"Délai d'inactivité avant affichage"},min:1,max:120,value:10,conditions:[{field:"triggerEvent",value:"reengage"}]},{propName:"triggerEventDelay",type:"number",category:"conditions",label:{en:"Trigger event delay (in seconds)",fr:"Délai avant l'affichage (en secondes)"},value:10,conditions:[{field:"triggerEvent",value:"timer"}]}],o={title:{propName:"title",type:"wysiwyg",category:"content",label:{en:"Title",fr:"Titre"},placeholder:{en:"Some title",fr:"Mon titre"},value:{en:"Title",fr:"Titre"},conditions:[{field:"layout",value:function(e){return"no-title"!==e&&"imageOnly"!==e}}]},buttonSettings:[{category:"content",type:"separator",propName:"button-separator"},{propName:"button",category:"content",type:"switch",value:!1,label:{en:"Add a button",fr:"Ajouter un bouton"}},{propName:"buttonText",type:"text",category:"content",label:{en:"Button text",fr:"Texte du bouton"},value:{en:"Accept",fr:"Valider"},placeholder:{en:"Submit",fr:"Valider"},conditions:[{field:"button"}]},{propName:"buttonLink",type:"text",category:"content",label:{en:"Button link",fr:"Lien du bouton"},value:"https://www.google.com",conditions:[{field:"button"}]},{propName:"buttonTextColor",category:"content",type:"colorpicker",label:{en:"Button text color",fr:"Couleur du texte du bouton"},value:"rgba(255, 255, 255, 1)",conditions:[{field:"button"}]},{propName:"buttonBackgroundColor",category:"content",type:"colorpicker",label:{en:"Button background color",fr:"Couleur de fond du bouton"},value:"rgba(86, 159, 242, 1)",conditions:[{field:"button"}]}]};function a(e){if(Array.isArray(e)){for(var t=0,o=Array(e.length);t<e.length;t++)o[t]=e[t];return o}return Array.from(e)}var r=[{propName:"type",value:"image",type:"hidden",category:"layout"},{propName:"layout",category:"layout",value:"imageOnly",type:"radioImage",options:[{label:{en:"Image only",fr:"Image seule"},value:"imageOnly",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/image/image-only.png"},{label:{en:"Left",fr:"Gauche"},value:"left",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/image/left.png"},{label:{en:"Right",fr:"Droite"},value:"right",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/image/right.png"},{label:{en:"Top",fr:"Haut"},value:"top",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/image/top.png"},{label:{en:"Bottom",fr:"Bas"},value:"bottom",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/image/bottom.png"}]},{propName:"image",type:"mediaupload",category:"content",label:"Image"},{category:"content",type:"separator",propName:"title-separator",conditions:[{field:"layout",value:function(e){return"no-title"!==e&&"imageOnly"!==e}}]},o.title,{category:"content",type:"separator",propName:"wysiwyg-content-separator",conditions:[{field:"layout",value:function(e){return"imageOnly"!==e}}]},{propName:"content",type:"wysiwyg",category:"content",label:{en:"Content",fr:"Contenu"},value:"Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.",conditions:[{field:"layout",value:function(e){return"imageOnly"!==e}}]}].concat(a(o.buttonSettings),a(e.dimensions),[{type:"separator",category:"style"},e.backgroundGroup,{type:"separator",category:"style"},e.borderGroup,{type:"separator",category:"style"},e.closeButtonGroup],a(e.animations),a(t));function n(e){if(Array.isArray(e)){for(var t=0,o=Array(e.length);t<e.length;t++)o[t]=e[t];return o}return Array.from(e)}var l=[{propName:"type",value:"simple",type:"hidden",category:"layout"},{propName:"layout",category:"layout",value:"center",type:"radioImage",options:[{label:{en:"Center",fr:"Centre"},value:"center",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/simple/center.png"},{label:{en:"Left",fr:"Gauche"},value:"left",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/simple/left.png"},{label:{en:"Right",fr:"Droite"},value:"right",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/simple/right.png"}]},o.title,{category:"content",type:"separator",propName:"title-content-separator"},{propName:"content",type:"wysiwyg",category:"content",label:{en:"Content",fr:"Contenu"},value:"Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum."}].concat(n(o.buttonSettings),n(e.dimensions),[{type:"separator",category:"style"},e.backgroundGroup,{type:"separator",category:"style"},e.borderGroup,{type:"separator",category:"style"},e.closeButtonGroup],n(e.animations),n(t));function i(e){if(Array.isArray(e)){for(var t=0,o=Array(e.length);t<e.length;t++)o[t]=e[t];return o}return Array.from(e)}var u=[{propName:"type",value:"video",type:"hidden",category:"layout"},{propName:"layout",category:"layout",value:"no-title",type:"radioImage",options:[{label:{en:"No title",fr:"Sans titre"},value:"no-title",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/video/video-only.png"},{label:{en:"Top",fr:"Haut"},value:"top",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/video/bottom.png"},{label:{en:"Bottom",fr:"Bas"},value:"bottom",src:"https://s3-eu-west-1.amazonaws.com/widgets-form-images/modal/video/top.png"}]},o.title,{propName:"videoLink",type:"text",category:"content",label:{en:"URL (Youtube or Vimeo)",fr:"URL (Youtube ou Vimeo)"},value:"https://www.youtube.com/watch?v=XyGGixAg3bE"}].concat(i(o.buttonSettings),i(e.dimensions),[{type:"separator",category:"style",conditions:[{field:"type",value:function(e){return"video"!==e}},{field:"layout",value:function(e){return"imageOnly"!==e}}]},e.backgroundGroup,{type:"separator",category:"style"},e.borderGroup,{type:"separator",category:"style"},e.closeButtonGroup],i(e.animations),i(t),[{category:"content",type:"separator",propName:"autoPlay-separator"},{propName:"autoPlay",category:"conditions",type:"switch",value:!1,label:{en:"Auto play (Youtube only)",fr:"Lecture automatique (Youtube uniquement)"}}]),s=void 0,p=document.getElementById("abtasty-widget-react-form__widget");if(p){var c=p.getAttribute("data-plugin-id");s=9===Number(c)?l:64===Number(c)?u:r}else s=r;return s});

@@ -1,1 +0,1 @@

!function(){"use strict";!function(t,a){void 0===a&&(a={});var e=a.insertAt;if(t&&"undefined"!=typeof document){var o=document.head||document.getElementsByTagName("head")[0],i=document.createElement("style");i.type="text/css","top"===e&&o.firstChild?o.insertBefore(i,o.firstChild):o.appendChild(i),i.styleSheet?i.styleSheet.cssText=t:i.appendChild(document.createTextNode(t))}}("abtasty-modal{display:none;position:fixed;top:0;left:0;width:100%;height:100%;z-index:2147483145}abtasty-modal:not(.abtasty-modal--video){overflow-y:auto}abtasty-modal__underlay{width:100%;height:100%;position:fixed;top:0;left:0;background-color:rgba(0,0,0,.5);cursor:pointer}.abtasty-modal__area{top:0;left:0;right:0;width:auto;margin:10px!important;z-index:100;position:relative}.abtasty-modal__area-layout--imageOnly{max-width:80%}.abtasty-modal__area-layout--imageOnly img{border-style:solid;-webkit-box-sizing:border-box;box-sizing:border-box;max-width:100%;opacity:1}.abtasty-modal__area-type--video.abtasty-modal__area-layout--no-title .abtasty-modal__content{padding:5px;border-radius:0!important;border-width:0!important;background-color:transparent!important;background-image:none!important}.abtasty-modal__area-type--video.abtasty-modal__area-layout--bottom .abtasty-modal__content{padding:25px 20px 20px}.abtasty-modal .abtasty-modal__content{border-color:#f6f6f6;border-style:solid;padding:20px}.abtasty-modal__area-type--image,.abtasty-modal__area-type--no-title,.abtasty-modal__area-type--simple,.abtasty-modal__area-type--video{margin:0 auto 20px!important;top:10vh;border:none;background:none}.abtasty-modal__area-type--video.abtasty-modal__area-layout--bottom .abtasty-modal__close--inside{top:2px}.abtasty-modal__area-type--video.abtasty-modal__area-layout--top .abtasty-modal__close--inside{right:15px;top:20px}.abtasty-modal__area-type--image .abtasty-modal__close,.abtasty-modal__area-type--simple .abtasty-modal__close{right:10px;top:15px}.abtasty-modal__close{position:absolute;right:5px;top:0;font-size:20px;font-weight:300;background:transparent;border:0;color:#222;font-family:Helvetica Neue,Helvetica,Arial,sans-serif!important;line-height:24px!important;margin-right:5px;cursor:pointer;width:20px;height:20px;padding:0;-webkit-box-sizing:border-box;box-sizing:border-box}.abtasty-modal__close svg{display:block}.abtasty-modal__close svg .close-x{stroke:#5c5c5c;fill:transparent;stroke-linecap:round;stroke-width:3}.abtasty-modal__area-type--video.abtasty-modal__area-layout--no-title .abtasty-modal__close--inside{top:-6px;right:-15px;background:#fff;border-radius:20px;width:20px;height:20px}.abtasty-modal__area-type--image .abtasty-modal__close--outside,.abtasty-modal__area-type--simple .abtasty-modal__close--outside,.abtasty-modal__close--outside,.abtasty-modal__close .abtasty-modal__close--outside{top:-25px;right:-25px;width:20px;height:20px}.abtasty-modal__close--outside{background:#fff;border-radius:20px}.abtasty-modal__media,.abtasty-modal__media-link{max-width:100%;display:block}.abtasty-modal__text{padding:20px;font-family:Open Sans,sans-serif!important;color:#000;overflow:auto}.abtasty-modal__title{width:auto;font-size:20px!important;font-weight:500;line-height:1.1;margin-bottom:10px}.abtasty-modal__text p{margin:0 0 10px!important;font-size:15px;font-weight:300;word-wrap:break-word}.abtasty-modal__button{width:100%;text-align:center;margin-top:20px}.abtasty-modal__button a{padding:10px 20px;border-radius:10px;display:inline-block;font-weight:700}.abtasty-modal__area-type--simple.abtasty-modal__area-layout--center .abtasty-modal__title{text-align:center}.abtasty-modal__area-type--simple.abtasty-modal__area-layout--center .abtasty-modal__innertext{text-align:center;white-space:pre-wrap}.abtasty-modal__area-type--simple.abtasty-modal__area-layout--left .abtasty-modal__title{width:50%;float:left;text-align:center;vertical-align:middle}.abtasty-modal__area-type--simple.abtasty-modal__area-layout--left .abtasty-modal__innertext{width:50%;float:left}.abtasty-modal__area-type--simple.abtasty-modal__area-layout--right .abtasty-modal__title{width:50%;float:left;text-align:center;vertical-align:middle}.abtasty-modal__area-type--simple.abtasty-modal__area-layout--right .abtasty-modal__innertext{width:50%;float:left}.abtasty-modal__area-type--image .abtasty-modal__image img{max-height:400px;max-width:100%;display:inline;opacity:1}.abtasty-modal__area-type--image.abtasty-modal__area-layout--left .abtasty-modal__image{width:50%;display:inline-block;height:auto;vertical-align:middle;text-align:center}.abtasty-modal__area-type--image.abtasty-modal__area-layout--left .abtasty-modal__text{text-align:left;width:50%;display:inline-block;vertical-align:middle;-webkit-box-sizing:border-box;box-sizing:border-box}.abtasty-modal__area-type--image.abtasty-modal__area-layout--right .abtasty-modal__image{width:50%;display:inline-block;height:auto;vertical-align:middle;text-align:center}.abtasty-modal__area-type--image.abtasty-modal__area-layout--right .abtasty-modal__text{text-align:left;width:50%;display:inline-block;vertical-align:middle;-webkit-box-sizing:border-box;box-sizing:border-box}.abtasty-modal__area-type--image.abtasty-modal__area-layout--top .abtasty-modal__image{width:100%;text-align:center}.abtasty-modal__area-type--image.abtasty-modal__area-layout--top .abtasty-modal__text{width:100%;padding:20px 0}.abtasty-modal__area-type--image.abtasty-modal__area-layout--top .abtasty-modal__image img{max-height:300px;opacity:1}.abtasty-modal__area-type--image.abtasty-modal__area-layout--bottom .abtasty-modal__image{width:100%;text-align:center}.abtasty-modal__area-type--image.abtasty-modal__area-layout--bottom .abtasty-modal__text{width:100%;padding:20px 0}.abtasty-modal__area-type--video{text-align:center;width:100%}.abtasty-modal__area-type--video iframe{width:100%}@media (min-width:630px){abtasty-modal:not(.abtasty-modal--video) .abtasty-modal__area-width--medium{width:600px;margin:0 auto 20px!important}.abtasty-modal--video{width:50%;left:25%}}@media (min-width:330px){abtasty-modal:not(.abtasty-modal--video) .abtasty-modal__area-width--small{width:300px;margin:0 auto 20px!important}}@media (min-width:930px){abtasty-modal:not(.abtasty-modal--video) .abtasty-modal__area-width--large{width:900px;margin:0 auto 20px!important}}.abtasty-animation-fadeIn{-webkit-animation-name:abTastyfadeIn;animation-name:abTastyfadeIn}.abtasty-animation-fadeIn,.abtasty-animation-fadeOut{-webkit-animation-duration:.5s;animation-duration:.5s}.abtasty-animation-fadeOut{-webkit-animation-name:abTastyfadeOut;animation-name:abTastyfadeOut}.abtasty-animation-slideIn{-webkit-animation-name:abTastyslideInDown;animation-name:abTastyslideInDown;-webkit-animation-duration:.5s;animation-duration:.5s}.abtasty-animation-slideOut{-webkit-animation-name:abTastyslideOutUp;animation-name:abTastyslideOutUp;-webkit-animation-duration:.5s;animation-duration:.5s}@-webkit-keyframes abTastyfadeIn{0%{opacity:0}to{opacity:1}}@keyframes abTastyfadeIn{0%{opacity:0}to{opacity:1}}@-webkit-keyframes abTastyfadeOut{0%{opacity:1}to{opacity:0}}@keyframes abTastyfadeOut{0%{opacity:1}to{opacity:0}}@-webkit-keyframes abTastyslideInDown{0%{-webkit-transform:translateY(-100%);transform:translateY(-100%)}to{-webkit-transform:translateY(0);transform:translateY(0)}}@keyframes abTastyslideInDown{0%{-webkit-transform:translateY(-100%);transform:translateY(-100%)}to{-webkit-transform:translateY(0);transform:translateY(0)}}@-webkit-keyframes abTastyslideOutUp{0%{-webkit-transform:translateY(0);transform:translateY(0)}to{-webkit-transform:translateY(-100%);transform:translateY(-100%)}}@keyframes abTastyslideOutUp{0%{-webkit-transform:translateY(0);transform:translateY(0)}to{-webkit-transform:translateY(-100%);transform:translateY(-100%)}}",{});var C=function(t){var n=Object.prototype.hasOwnProperty;function d(t,a){return Array.isArray(t)?function(t,a){for(var e,o="",i="",n=Array.isArray(a),r=0;r<t.length;r++)(e=d(t[r]))&&(n&&a[r]&&(e=m(e)),o=o+i+e,i=" ");return o}(t,a):t&&"object"==typeof t?function(t){var a="",e="";for(var o in t)o&&t[o]&&n.call(t,o)&&(a=a+e+o,e=" ");return a}(t):t||""}function l(t){if(!t)return"";if("object"==typeof t){var a="";for(var e in t)n.call(t,e)&&(a=a+e+":"+t[e]+";");return a}return t+""}function r(t,a,e,o){return!1!==a&&null!=a&&(a||"class"!==t&&"style"!==t)?!0===a?" "+(o?t:t+'="'+t+'"'):("function"==typeof a.toJSON&&(a=a.toJSON()),"string"==typeof a||(a=JSON.stringify(a),e||-1===a.indexOf('"'))?(e&&(a=m(a))," "+t+'="'+a+'"'):" "+t+"='"+a.replace(/'/g,"&#39;")+"'"):""}t.merge=function t(a,e){if(1===arguments.length){for(var o=a[0],i=1;i<a.length;i++)o=t(o,a[i]);return o}for(var n in e)if("class"===n){var r=a[n]||[];a[n]=(Array.isArray(r)?r:[r]).concat(e[n]||[])}else if("style"===n){var r=l(a[n]);r=r&&";"!==r[r.length-1]?r+";":r;var d=l(e[n]);d=d&&";"!==d[d.length-1]?d+";":d,a[n]=r+d}else a[n]=e[n];return a},t.classes=d,t.style=l,t.attr=r,t.attrs=function(t,a){var e="";for(var o in t)if(n.call(t,o)){var i=t[o];if("class"===o){i=d(i),e=r(o,i,!1,a)+e;continue}"style"===o&&(i=l(i)),e+=r(o,i,!1,a)}return e};var s=/["&<>]/;function m(t){var a=""+t,e=s.exec(a);if(!e)return t;var o,i,n,r="";for(o=e.index,i=0;o<a.length;o++){switch(a.charCodeAt(o)){case 34:n="&quot;";break;case 38:n="&amp;";break;case 60:n="&lt;";break;case 62:n="&gt;";break;default:continue}i!==o&&(r+=a.substring(i,o)),i=o+1,r+=n}return i!==o?r+a.substring(i,o):r}return t.escape=m,t.rethrow=function a(e,t,o,i){if(!(e instanceof Error))throw e;if(!("undefined"==typeof window&&t||i))throw e.message+=" on line "+o,e;try{i=i||require("fs").readFileSync(t,"utf8")}catch(t){a(e,null,o)}var n=3,r=i.split("\n"),d=Math.max(o-n,0),l=Math.min(r.length,o+n);var n=r.slice(d,l).map(function(t,a){var e=a+d+1;return(e==o?" > ":" ")+e+"| "+t}).join("\n");e.path=t;e.message=(t||"Pug")+":"+o+"\n"+n+"\n\n"+e.message;throw e},t}({}),e=function(t){var w,k="",T={};try{var a={},e=t||{};(function(a,t,e,o,i,n,r,d,l,s,m,y,b,u,c,p,_,f,g,h,v,x){T.button=w=function(){this&&this.block,this&&this.attributes;k=(k=(k+='<div class="abtasty-modal__button">')+"<a"+(C.attr("href",m,!0,!0)+C.attr("style",C.style({"background-color":s+"!important",color:b+"!important"}),!0,!0))+">")+C.escape(null==(w=y)?"":w)+"</a></div>"},T.title=w=function(){this&&this.block,this&&this.attributes;k=(k+='<h2 class="abtasty-modal__title" style="text-align:center;">')+(null==(w=h)?"":w)+"</h2>"},T.imageOnly=w=function(){this&&this.block,this&&this.attributes;k=k+"<img"+(C.attr("src",p,!0,!0)+C.attr("style",C.style({"border-radius":n+"px!important","border-width":d+"px!important","border-color":i+"!important"}),!0,!0))+">"},T.imageWithText=w=function(){this&&this.block,this&&this.attributes;k+='<div class="abtasty-modal__image">',p&&(k=k+"<img"+(C.attr("src",p,!0,!0)+C.attr("style",C.style({"border-radius":r+"px!important"}),!0,!0))+">"),k+="</div>"},T.content=w=function(){this&&this.block,this&&this.attributes;k+='<div class="abtasty-modal__innertext">',k=(k+="<p>")+(null==(w=f)?"":w)+"</p></div>"},T.closeButton=w=function(){this&&this.block,this&&this.attributes;k=k+"<div"+C.attr("class",C.classes(["abtasty-modal__close",u?"abtasty-modal__close--"+u:""],[!1,!0]),!1,!0)+" data-abtasty-actionnable"+C.attr("style",C.style("outside"===u?{"background-color":t}:""),!0,!0)+">",k+='<svg viewbox="0 0 40 40">',k+='<path class="close-x" d="M 10,10 L 30,30 M 30,10 L 10,30"></path></svg></div>'},T.contentWrapper=w=function(){var t=this&&this.block;this&&this.attributes;k=k+'<div class="abtasty-modal__content"'+C.attr("style",C.style({"border-radius":n+"px!important","border-width":d+"px!important","border-color":i+"!important","background-color":e+"!important","background-image":'url("'+o+'")!important'}),!0,!0)+">",t&&t&&t(),k+="</div>"},T.modalWrapper=w=function(){var t=this&&this.block;this&&this.attributes;k=(k=k+"<abtasty-modal__underlay"+C.attr("style",C.style({"background-color":"rgba(0, 0, 0, "+g/100+")"}),!0,!0)+"></abtasty-modal__underlay>")+"<div"+(C.attr("class",C.classes(["abtasty-animation-"+a+" abtasty-modal__area abtasty-modal__area-width--"+x+" abtasty-modal__area-type--"+v+" abtasty-modal__area-layout--"+_],[!0]),!1,!0)+C.attr("style",C.style({width:"custom"===x&&c+"%","margin-left":"custom"===x&&(100-c)/2+"% !important"}),!0,!0))+">",t&&t&&t(),k+="</div>"},T.modalWrapper.call({block:function(){T.closeButton(),"image"===v&&"imageOnly"===_?(T.imageOnly(),l&&T.button()):T.contentWrapper.call({block:function(){"simple"===v?(k+='<div class="abtasty-modal__text">',"center"===_||"left"===_?(T.title(),T.content()):(T.content(),T.title()),k+='<div style="clear:both;"></div>',k+="</div>",l&&T.button()):"image"===v?("top"!==_&&"left"!==_||T.imageWithText(),k+='<div class="abtasty-modal__text">',T.title(),T.content(),l&&T.button(),k+="</div>","right"!==_&&"bottom"!==_||T.imageWithText(),k+='<div style="clear:both;"></div>'):"video"===v&&("top"===_&&T.title(),k+=null==(w=f)?"":w,"bottom"===_&&T.title(),l&&T.button())}})}})}).call(this,"animation"in e?e.animation:"undefined"!=typeof animation?animation:void 0,"backgroundCloseButtonColor"in e?e.backgroundCloseButtonColor:"undefined"!=typeof backgroundCloseButtonColor?backgroundCloseButtonColor:void 0,"backgroundColor"in e?e.backgroundColor:"undefined"!=typeof backgroundColor?backgroundColor:void 0,"backgroundImage"in e?e.backgroundImage:"undefined"!=typeof backgroundImage?backgroundImage:void 0,"borderColor"in e?e.borderColor:"undefined"!=typeof borderColor?borderColor:void 0,"borderRadius"in e?e.borderRadius:"undefined"!=typeof borderRadius?borderRadius:void 0,"borderRadiusImage"in e?e.borderRadiusImage:"undefined"!=typeof borderRadiusImage?borderRadiusImage:void 0,"borderWidth"in e?e.borderWidth:"undefined"!=typeof borderWidth?borderWidth:void 0,"button"in e?e.button:"undefined"!=typeof button?button:void 0,"buttonBackgroundColor"in e?e.buttonBackgroundColor:"undefined"!=typeof buttonBackgroundColor?buttonBackgroundColor:void 0,"buttonLink"in e?e.buttonLink:"undefined"!=typeof buttonLink?buttonLink:void 0,"buttonText"in e?e.buttonText:"undefined"!=typeof buttonText?buttonText:void 0,"buttonTextColor"in e?e.buttonTextColor:"undefined"!=typeof buttonTextColor?buttonTextColor:void 0,"closeButtonPosition"in e?e.closeButtonPosition:"undefined"!=typeof closeButtonPosition?closeButtonPosition:void 0,"customWidth"in e?e.customWidth:"undefined"!=typeof customWidth?customWidth:void 0,"image"in e?e.image:"undefined"!=typeof image?image:void 0,"layout"in e?e.layout:"undefined"!=typeof layout?layout:void 0,"modalContent"in e?e.modalContent:"undefined"!=typeof modalContent?modalContent:void 0,"overlayOpacity"in e?e.overlayOpacity:"undefined"!=typeof overlayOpacity?overlayOpacity:void 0,"title"in e?e.title:"undefined"!=typeof title?title:void 0,"type"in e?e.type:"undefined"!=typeof type?type:void 0,"width"in e?e.width:"undefined"!=typeof width?width:void 0)}catch(t){C.rethrow(t,void 0,void 0,a[void 0])}return k};var t=DATA,i=t.type,o=t.animation,n=t.backgroundColor,r=t.overlayOpacity,d=t.backgroundImage,l=t.borderRadius,s=t.borderRadiusImage,m=t.borderWidth,y=t.borderColor,b=t.button,u=t.buttonBackgroundColor,c=t.buttonLink,p=t.buttonText,_=t.buttonTextColor,f=t.backgroundCloseButtonColor,g=t.closeButtonColor,h=t.closeButtonPosition,v=t.content,x=t.customWidth,w=t.title,k=t.layout,T=t.videoLink,I=t.recurrence,O=t.triggerEvent,B=t.triggerEventDelay,E=t.clickEventSelector,a=t.widthImageWithText,S=t.widthImageOnly,L=t.autoPlay,A="imageOnly"===k?S:a,W=DATA.image||"https://gitlab.com/abtasty/public/storage/raw/master/image-placeholder.png",Y=void 0,D=document.createElement("abtasty-modal"),z="AB Tasty Modal "+i+" "+TEST_ID,R=void 0!==window.ABTastyEditor,q=!!sessionStorage.getItem("ABTastyPreview"),M="abtasty-modal__underlay",N=".abtasty-modal__close",P=Date.now(),H=void 0,U=PLUGIN_ID;var j,F=void 0;function J(){F&&(document.querySelector("body").style.overflowY=F),D.style.display="none","video"===i&&(D.innerHTML=""),void 0!==U&&ABTastyEvent(U+" "+i+" modal closed",null,TEST_ID)}function G(){return D.querySelector(M)&&D.querySelector(N)?(D.querySelector(M).addEventListener("click",J),D.querySelector(N).addEventListener("click",J),0):setTimeout(G,50)}function $(t,a){return t.matches?t.matches(a):t.msMatchesSelector(a)}function K(){var t=0<arguments.length&&void 0!==arguments[0]&&arguments[0],a={layout:k,type:i,borderRadius:l,borderRadiusImage:s,borderWidth:m,borderColor:y,button:b,buttonBackgroundColor:u,buttonLink:c,buttonText:p,buttonTextColor:_,backgroundColor:"imageOnly"!==k?n:"initial",overlayOpacity:r,backgroundImage:d,image:W,width:A,videoLink:T,customWidth:x,animation:o,title:w,closeButtonPosition:h,backgroundCloseButtonColor:f,modalContent:v||t.outerHTML};(D.className="abtasty-modal abtasty-modal--"+i,D.dataset.testId=TEST_ID,D.innerHTML=e(a),document.body.appendChild(D),H=D.querySelector(".abtasty-modal__area"),g)&&(D.querySelector(N+" .close-x").style.stroke=g)}function Q(){var t=(630<window.innerWidth?.5*window.innerWidth:window.innerWidth-40)/16*9;return Math.round(t)}function V(){var t="abtasty-widget-video-"+Date.now(),a=document.createElement("iframe");a.setAttribute("id",t);var e=function(t){var a=-1<t.indexOf("youtu"),e=-1<t.indexOf("vimeo"),o=void 0;a?(o="//www.youtube.com/embed/"+t.match(/^.*(youtu.be\/|v\/|e\/|u\/\w+\/|embed\/|v=)([^#&?]*).*/)[2]+"?rel=0",L&&(o+="&autoplay=1")):e&&(o="//player.vimeo.com/video/"+t.match(/.*(www\.)?vimeo.com\/(\d+)($|\/)/)[2]);return o}(T),o=Q();a.style.height=o+"px","no-title"===k&&(a.style.border=m+"px solid "+y+"!important",a.style.borderRadius=l+"px!important"),a.src=e,a.frameBorder=0,a.allowfullscreen=!0,K(a),H.style.height=o+"px",window.addEventListener("resize",function(){var t=document.querySelector("abtasty-modal iframe"),a=Q();t.style.height=a+"px",H.style.height=a+"px"})}function X(){if(e=Number(I),!(o=localStorage.getItem(z))||-1===e||R||q||(0===e?!sessionStorage.getItem(z):o<P-24*e*60*60*1e3)){if("video"===i)V(),G();else if("image"===i&&"fit"===A){var t=new Image;t.src=W,t.className="abtasty-modal__media",t.onload=function(){K(this),H.style.width=this.width+"px",H.style.height=this.height+"px",G()}}else K(),G();D.style.display="block",a=document.querySelector("body"),F=window.getComputedStyle(a).overflowY,a.style.overflowY="hidden",void 0!==U&&ABTastyEvent(U+" "+i+" modal displayed",null,TEST_ID),R||(localStorage.setItem(z,P),sessionStorage.setItem(z,P))}var a,e,o}j=function(){var e,o,i,n,r,t,d,l,s,m,y,b,a=window.top.ABTastyWidgetForm||!1;if(R&&a)X();else if("click"===O)m=E,y=X,b=M+", "+N,document.body.addEventListener("click",function(t){var a=t.target;if(!b||!$(a,b))for(;a;){if(a!==document&&$(a,m)){y();break}a=a.parentNode}});else switch(O){case"pageLoad":X();break;case"exitIntent":r=X,t=DATA.exitEventDelay,d=parseFloat(t)||0,l=void 0,s=0,document.addEventListener("mousemove",function(t){s=t.clientY}),document.body.addEventListener("mouseleave",function t(a){a.clientY<=50&&(s=0,clearInterval(l),l=setTimeout(function(){0===s&&(r(),document.body.removeEventListener("mouseleave",t))},1e3*d))},!1);break;case"reengage":e=X,o=DATA.reengageEventDelay,n=void 0,(i=["mousemove","keydown","scroll"]).forEach(function(t){document.addEventListener(t,function a(){clearTimeout(n),n=setTimeout(function(){e(),i.forEach(function(t){return document.removeEventListener(t,a)})},1e3*o)},!1)});break;case"timer":clearTimeout(Y),Y=setTimeout(X,1e3*B)}},"loading"!==document.readyState?j():document.addEventListener("DOMContentLoaded",j)}();
!function(){"use strict";!function(t,a){void 0===a&&(a={});var e=a.insertAt;if(t&&"undefined"!=typeof document){var o=document.head||document.getElementsByTagName("head")[0],i=document.createElement("style");i.type="text/css","top"===e&&o.firstChild?o.insertBefore(i,o.firstChild):o.appendChild(i),i.styleSheet?i.styleSheet.cssText=t:i.appendChild(document.createTextNode(t))}}("abtasty-modal{display:none;position:fixed;top:0;left:0;width:100%;height:100%;z-index:2147483145}abtasty-modal:not(.abtasty-modal--video){overflow-y:auto}abtasty-modal__underlay{width:100%;height:100%;position:fixed;top:0;left:0;background-color:rgba(0,0,0,.5);cursor:pointer}.abtasty-modal__area{top:0;left:0;right:0;width:auto;margin:10px!important;z-index:100;position:relative;float:none}.abtasty-modal__area-layout--imageOnly{max-width:80%}.abtasty-modal__area-layout--imageOnly img{border-style:solid;-webkit-box-sizing:border-box;box-sizing:border-box;max-width:100%;opacity:1}.abtasty-modal__area-type--video.abtasty-modal__area-layout--no-title .abtasty-modal__content{padding:5px;border-radius:0!important;border-width:0!important;background-color:transparent!important;background-image:none!important}.abtasty-modal__area-type--video.abtasty-modal__area-layout--bottom .abtasty-modal__content{padding:25px 20px 20px}.abtasty-modal .abtasty-modal__content{border-color:#f6f6f6;border-style:solid;padding:20px}.abtasty-modal__area-type--image,.abtasty-modal__area-type--no-title,.abtasty-modal__area-type--simple,.abtasty-modal__area-type--video{margin:0 auto 20px!important;top:10vh;border:none;background:none}.abtasty-modal__area-type--video.abtasty-modal__area-layout--bottom .abtasty-modal__close--inside{top:2px}.abtasty-modal__area-type--video.abtasty-modal__area-layout--top .abtasty-modal__close--inside{right:15px;top:20px}.abtasty-modal__area-type--image .abtasty-modal__close,.abtasty-modal__area-type--simple .abtasty-modal__close{right:10px;top:15px}.abtasty-modal__close{position:absolute;right:5px;top:0;font-size:20px;font-weight:300;background:transparent;border:0;color:#222;font-family:Helvetica Neue,Helvetica,Arial,sans-serif!important;line-height:24px!important;margin-right:5px;cursor:pointer;width:20px;height:20px;padding:0;-webkit-box-sizing:border-box;box-sizing:border-box}.abtasty-modal__close svg{display:block}.abtasty-modal__close svg .close-x{stroke:#5c5c5c;fill:transparent;stroke-linecap:round;stroke-width:3}.abtasty-modal__area-type--video.abtasty-modal__area-layout--no-title .abtasty-modal__close--inside{top:-6px;right:-15px;background:#fff;border-radius:20px;width:20px;height:20px}.abtasty-modal__area-type--image .abtasty-modal__close--outside,.abtasty-modal__area-type--simple .abtasty-modal__close--outside,.abtasty-modal__close--outside,.abtasty-modal__close .abtasty-modal__close--outside{top:-25px;right:-25px;width:20px;height:20px}.abtasty-modal__close--outside{background:#fff;border-radius:20px}.abtasty-modal__media,.abtasty-modal__media-link{max-width:100%;display:block}.abtasty-modal__text{padding:20px;font-family:Open Sans,sans-serif!important;color:#000;overflow:auto}.abtasty-modal__title{width:auto;font-size:20px!important;font-weight:500;line-height:1.1;margin-bottom:10px}.abtasty-modal__text p{margin:0 0 10px!important;font-size:15px;font-weight:300;word-wrap:break-word}.abtasty-modal__button{width:100%;text-align:center;margin-top:20px}.abtasty-modal__button a{padding:10px 20px;border-radius:10px;display:inline-block;font-weight:700}.abtasty-modal__area-type--simple.abtasty-modal__area-layout--center .abtasty-modal__title{text-align:center}.abtasty-modal__area-type--simple.abtasty-modal__area-layout--center .abtasty-modal__innertext{text-align:center;white-space:pre-wrap}.abtasty-modal__area-type--simple.abtasty-modal__area-layout--left .abtasty-modal__title{width:50%;float:left;text-align:center;vertical-align:middle}.abtasty-modal__area-type--simple.abtasty-modal__area-layout--left .abtasty-modal__innertext{width:50%;float:left}.abtasty-modal__area-type--simple.abtasty-modal__area-layout--right .abtasty-modal__title{width:50%;float:left;text-align:center;vertical-align:middle}.abtasty-modal__area-type--simple.abtasty-modal__area-layout--right .abtasty-modal__innertext{width:50%;float:left}.abtasty-modal__area-type--image .abtasty-modal__image img{max-height:400px;max-width:100%;display:inline;opacity:1}.abtasty-modal__area-type--image.abtasty-modal__area-layout--left .abtasty-modal__image{width:50%;display:inline-block;height:auto;vertical-align:middle;text-align:center}.abtasty-modal__area-type--image.abtasty-modal__area-layout--left .abtasty-modal__text{text-align:left;width:50%;display:inline-block;vertical-align:middle;-webkit-box-sizing:border-box;box-sizing:border-box}.abtasty-modal__area-type--image.abtasty-modal__area-layout--right .abtasty-modal__image{width:50%;display:inline-block;height:auto;vertical-align:middle;text-align:center}.abtasty-modal__area-type--image.abtasty-modal__area-layout--right .abtasty-modal__text{text-align:left;width:50%;display:inline-block;vertical-align:middle;-webkit-box-sizing:border-box;box-sizing:border-box}.abtasty-modal__area-type--image.abtasty-modal__area-layout--top .abtasty-modal__image{width:100%;text-align:center}.abtasty-modal__area-type--image.abtasty-modal__area-layout--top .abtasty-modal__text{width:100%;padding:20px 0}.abtasty-modal__area-type--image.abtasty-modal__area-layout--top .abtasty-modal__image img{max-height:300px;opacity:1}.abtasty-modal__area-type--image.abtasty-modal__area-layout--bottom .abtasty-modal__image{width:100%;text-align:center}.abtasty-modal__area-type--image.abtasty-modal__area-layout--bottom .abtasty-modal__text{width:100%;padding:20px 0}.abtasty-modal__area-type--video{text-align:center;width:100%}.abtasty-modal__area-type--video iframe{width:100%}@media (min-width:630px){abtasty-modal:not(.abtasty-modal--video) .abtasty-modal__area-width--medium{width:600px;margin:0 auto 20px!important}.abtasty-modal--video{width:50%;left:25%}}@media (min-width:330px){abtasty-modal:not(.abtasty-modal--video) .abtasty-modal__area-width--small{width:300px;margin:0 auto 20px!important}}@media (min-width:930px){abtasty-modal:not(.abtasty-modal--video) .abtasty-modal__area-width--large{width:900px;margin:0 auto 20px!important}}.abtasty-animation-fadeIn{-webkit-animation-name:abTastyfadeIn;animation-name:abTastyfadeIn}.abtasty-animation-fadeIn,.abtasty-animation-fadeOut{-webkit-animation-duration:.5s;animation-duration:.5s}.abtasty-animation-fadeOut{-webkit-animation-name:abTastyfadeOut;animation-name:abTastyfadeOut}.abtasty-animation-slideIn{-webkit-animation-name:abTastyslideInDown;animation-name:abTastyslideInDown;-webkit-animation-duration:.5s;animation-duration:.5s}.abtasty-animation-slideOut{-webkit-animation-name:abTastyslideOutUp;animation-name:abTastyslideOutUp;-webkit-animation-duration:.5s;animation-duration:.5s}@-webkit-keyframes abTastyfadeIn{0%{opacity:0}to{opacity:1}}@keyframes abTastyfadeIn{0%{opacity:0}to{opacity:1}}@-webkit-keyframes abTastyfadeOut{0%{opacity:1}to{opacity:0}}@keyframes abTastyfadeOut{0%{opacity:1}to{opacity:0}}@-webkit-keyframes abTastyslideInDown{0%{-webkit-transform:translateY(-100%);transform:translateY(-100%)}to{-webkit-transform:translateY(0);transform:translateY(0)}}@keyframes abTastyslideInDown{0%{-webkit-transform:translateY(-100%);transform:translateY(-100%)}to{-webkit-transform:translateY(0);transform:translateY(0)}}@-webkit-keyframes abTastyslideOutUp{0%{-webkit-transform:translateY(0);transform:translateY(0)}to{-webkit-transform:translateY(-100%);transform:translateY(-100%)}}@keyframes abTastyslideOutUp{0%{-webkit-transform:translateY(0);transform:translateY(0)}to{-webkit-transform:translateY(-100%);transform:translateY(-100%)}}",{});var C=function(t){var n=Object.prototype.hasOwnProperty;function d(t,a){return Array.isArray(t)?function(t,a){for(var e,o="",i="",n=Array.isArray(a),r=0;r<t.length;r++)(e=d(t[r]))&&(n&&a[r]&&(e=m(e)),o=o+i+e,i=" ");return o}(t,a):t&&"object"==typeof t?function(t){var a="",e="";for(var o in t)o&&t[o]&&n.call(t,o)&&(a=a+e+o,e=" ");return a}(t):t||""}function l(t){if(!t)return"";if("object"==typeof t){var a="";for(var e in t)n.call(t,e)&&(a=a+e+":"+t[e]+";");return a}return t+""}function r(t,a,e,o){return!1!==a&&null!=a&&(a||"class"!==t&&"style"!==t)?!0===a?" "+(o?t:t+'="'+t+'"'):("function"==typeof a.toJSON&&(a=a.toJSON()),"string"==typeof a||(a=JSON.stringify(a),e||-1===a.indexOf('"'))?(e&&(a=m(a))," "+t+'="'+a+'"'):" "+t+"='"+a.replace(/'/g,"&#39;")+"'"):""}t.merge=function t(a,e){if(1===arguments.length){for(var o=a[0],i=1;i<a.length;i++)o=t(o,a[i]);return o}for(var n in e)if("class"===n){var r=a[n]||[];a[n]=(Array.isArray(r)?r:[r]).concat(e[n]||[])}else if("style"===n){var r=l(a[n]);r=r&&";"!==r[r.length-1]?r+";":r;var d=l(e[n]);d=d&&";"!==d[d.length-1]?d+";":d,a[n]=r+d}else a[n]=e[n];return a},t.classes=d,t.style=l,t.attr=r,t.attrs=function(t,a){var e="";for(var o in t)if(n.call(t,o)){var i=t[o];if("class"===o){i=d(i),e=r(o,i,!1,a)+e;continue}"style"===o&&(i=l(i)),e+=r(o,i,!1,a)}return e};var s=/["&<>]/;function m(t){var a=""+t,e=s.exec(a);if(!e)return t;var o,i,n,r="";for(o=e.index,i=0;o<a.length;o++){switch(a.charCodeAt(o)){case 34:n="&quot;";break;case 38:n="&amp;";break;case 60:n="&lt;";break;case 62:n="&gt;";break;default:continue}i!==o&&(r+=a.substring(i,o)),i=o+1,r+=n}return i!==o?r+a.substring(i,o):r}return t.escape=m,t.rethrow=function a(e,t,o,i){if(!(e instanceof Error))throw e;if(!("undefined"==typeof window&&t||i))throw e.message+=" on line "+o,e;try{i=i||require("fs").readFileSync(t,"utf8")}catch(t){a(e,null,o)}var n=3,r=i.split("\n"),d=Math.max(o-n,0),l=Math.min(r.length,o+n);var n=r.slice(d,l).map(function(t,a){var e=a+d+1;return(e==o?" > ":" ")+e+"| "+t}).join("\n");e.path=t;e.message=(t||"Pug")+":"+o+"\n"+n+"\n\n"+e.message;throw e},t}({}),e=function(t){var w,k="",T={};try{var a={},e=t||{};(function(a,t,e,o,i,n,r,d,l,s,m,y,b,u,c,p,_,f,g,h,v,x){T.button=w=function(){this&&this.block,this&&this.attributes;k=(k=(k+='<div class="abtasty-modal__button">')+"<a"+(C.attr("href",m,!0,!0)+C.attr("style",C.style({"background-color":s+"!important",color:b+"!important"}),!0,!0))+">")+C.escape(null==(w=y)?"":w)+"</a></div>"},T.title=w=function(){this&&this.block,this&&this.attributes;k=(k+='<h2 class="abtasty-modal__title" style="text-align:center;">')+(null==(w=h)?"":w)+"</h2>"},T.imageOnly=w=function(){this&&this.block,this&&this.attributes;k=k+"<img"+(C.attr("src",p,!0,!0)+C.attr("style",C.style({"border-radius":n+"px!important","border-width":d+"px!important","border-color":i+"!important"}),!0,!0))+">"},T.imageWithText=w=function(){this&&this.block,this&&this.attributes;k+='<div class="abtasty-modal__image">',p&&(k=k+"<img"+(C.attr("src",p,!0,!0)+C.attr("style",C.style({"border-radius":r+"px!important"}),!0,!0))+">"),k+="</div>"},T.content=w=function(){this&&this.block,this&&this.attributes;k+='<div class="abtasty-modal__innertext">',k=(k+="<p>")+(null==(w=f)?"":w)+"</p></div>"},T.closeButton=w=function(){this&&this.block,this&&this.attributes;k=k+"<div"+C.attr("class",C.classes(["abtasty-modal__close",u?"abtasty-modal__close--"+u:""],[!1,!0]),!1,!0)+" data-abtasty-actionnable"+C.attr("style",C.style("outside"===u?{"background-color":t}:""),!0,!0)+">",k+='<svg viewbox="0 0 40 40">',k+='<path class="close-x" d="M 10,10 L 30,30 M 30,10 L 10,30"></path></svg></div>'},T.contentWrapper=w=function(){var t=this&&this.block;this&&this.attributes;k=k+'<div class="abtasty-modal__content"'+C.attr("style",C.style({"border-radius":n+"px!important","border-width":d+"px!important","border-color":i+"!important","background-color":e+"!important","background-image":'url("'+o+'")!important'}),!0,!0)+">",t&&t&&t(),k+="</div>"},T.modalWrapper=w=function(){var t=this&&this.block;this&&this.attributes;k=(k=k+"<abtasty-modal__underlay"+C.attr("style",C.style({"background-color":"rgba(0, 0, 0, "+g/100+")"}),!0,!0)+"></abtasty-modal__underlay>")+"<div"+(C.attr("class",C.classes(["abtasty-animation-"+a+" abtasty-modal__area abtasty-modal__area-width--"+x+" abtasty-modal__area-type--"+v+" abtasty-modal__area-layout--"+_],[!0]),!1,!0)+C.attr("style",C.style({width:"custom"===x&&c+"%","margin-left":"custom"===x&&(100-c)/2+"% !important"}),!0,!0))+">",t&&t&&t(),k+="</div>"},T.modalWrapper.call({block:function(){T.closeButton(),"image"===v&&"imageOnly"===_?(T.imageOnly(),l&&T.button()):T.contentWrapper.call({block:function(){"simple"===v?(k+='<div class="abtasty-modal__text">',"center"===_||"left"===_?(T.title(),T.content()):(T.content(),T.title()),k+='<div style="clear:both;"></div>',k+="</div>",l&&T.button()):"image"===v?("top"!==_&&"left"!==_||T.imageWithText(),k+='<div class="abtasty-modal__text">',T.title(),T.content(),l&&T.button(),k+="</div>","right"!==_&&"bottom"!==_||T.imageWithText(),k+='<div style="clear:both;"></div>'):"video"===v&&("top"===_&&T.title(),k+=null==(w=f)?"":w,"bottom"===_&&T.title(),l&&T.button())}})}})}).call(this,"animation"in e?e.animation:"undefined"!=typeof animation?animation:void 0,"backgroundCloseButtonColor"in e?e.backgroundCloseButtonColor:"undefined"!=typeof backgroundCloseButtonColor?backgroundCloseButtonColor:void 0,"backgroundColor"in e?e.backgroundColor:"undefined"!=typeof backgroundColor?backgroundColor:void 0,"backgroundImage"in e?e.backgroundImage:"undefined"!=typeof backgroundImage?backgroundImage:void 0,"borderColor"in e?e.borderColor:"undefined"!=typeof borderColor?borderColor:void 0,"borderRadius"in e?e.borderRadius:"undefined"!=typeof borderRadius?borderRadius:void 0,"borderRadiusImage"in e?e.borderRadiusImage:"undefined"!=typeof borderRadiusImage?borderRadiusImage:void 0,"borderWidth"in e?e.borderWidth:"undefined"!=typeof borderWidth?borderWidth:void 0,"button"in e?e.button:"undefined"!=typeof button?button:void 0,"buttonBackgroundColor"in e?e.buttonBackgroundColor:"undefined"!=typeof buttonBackgroundColor?buttonBackgroundColor:void 0,"buttonLink"in e?e.buttonLink:"undefined"!=typeof buttonLink?buttonLink:void 0,"buttonText"in e?e.buttonText:"undefined"!=typeof buttonText?buttonText:void 0,"buttonTextColor"in e?e.buttonTextColor:"undefined"!=typeof buttonTextColor?buttonTextColor:void 0,"closeButtonPosition"in e?e.closeButtonPosition:"undefined"!=typeof closeButtonPosition?closeButtonPosition:void 0,"customWidth"in e?e.customWidth:"undefined"!=typeof customWidth?customWidth:void 0,"image"in e?e.image:"undefined"!=typeof image?image:void 0,"layout"in e?e.layout:"undefined"!=typeof layout?layout:void 0,"modalContent"in e?e.modalContent:"undefined"!=typeof modalContent?modalContent:void 0,"overlayOpacity"in e?e.overlayOpacity:"undefined"!=typeof overlayOpacity?overlayOpacity:void 0,"title"in e?e.title:"undefined"!=typeof title?title:void 0,"type"in e?e.type:"undefined"!=typeof type?type:void 0,"width"in e?e.width:"undefined"!=typeof width?width:void 0)}catch(t){C.rethrow(t,void 0,void 0,a[void 0])}return k};var t=DATA,i=t.type,o=t.animation,n=t.backgroundColor,r=t.overlayOpacity,d=t.backgroundImage,l=t.borderRadius,s=t.borderRadiusImage,m=t.borderWidth,y=t.borderColor,b=t.button,u=t.buttonBackgroundColor,c=t.buttonLink,p=t.buttonText,_=t.buttonTextColor,f=t.backgroundCloseButtonColor,g=t.closeButtonColor,h=t.closeButtonPosition,v=t.content,x=t.customWidth,w=t.title,k=t.layout,T=t.videoLink,I=t.recurrence,O=t.triggerEvent,B=t.triggerEventDelay,E=t.clickEventSelector,a=t.widthImageWithText,S=t.widthImageOnly,L=t.autoPlay,A="imageOnly"===k?S:a,W=DATA.image||"https://gitlab.com/abtasty/public/storage/raw/master/image-placeholder.png",Y=void 0,D=document.createElement("abtasty-modal"),z="AB Tasty Modal "+i+" "+TEST_ID,R=void 0!==window.ABTastyEditor,q=!!sessionStorage.getItem("ABTastyPreview"),M="abtasty-modal__underlay",N=".abtasty-modal__close",P=Date.now(),H=void 0,U=PLUGIN_ID;var j,F=void 0;function J(){F&&(document.querySelector("body").style.overflowY=F),D.style.display="none","video"===i&&(D.innerHTML=""),void 0!==U&&ABTastyEvent(U+" "+i+" modal closed",null,TEST_ID)}function G(){return D.querySelector(M)&&D.querySelector(N)?(D.querySelector(M).addEventListener("click",J),D.querySelector(N).addEventListener("click",J),0):setTimeout(G,50)}function $(t,a){return t.matches?t.matches(a):t.msMatchesSelector(a)}function K(){var t=0<arguments.length&&void 0!==arguments[0]&&arguments[0],a={layout:k,type:i,borderRadius:l,borderRadiusImage:s,borderWidth:m,borderColor:y,button:b,buttonBackgroundColor:u,buttonLink:c,buttonText:p,buttonTextColor:_,backgroundColor:"imageOnly"!==k?n:"initial",overlayOpacity:r,backgroundImage:d,image:W,width:A,videoLink:T,customWidth:x,animation:o,title:w,closeButtonPosition:h,backgroundCloseButtonColor:f,modalContent:v||t.outerHTML};(D.className="abtasty-modal abtasty-modal--"+i,D.dataset.testId=TEST_ID,D.innerHTML=e(a),document.body.appendChild(D),H=D.querySelector(".abtasty-modal__area"),g)&&(D.querySelector(N+" .close-x").style.stroke=g)}function Q(){var t=(630<window.innerWidth?.5*window.innerWidth:window.innerWidth-40)/16*9;return Math.round(t)}function V(){var t="abtasty-widget-video-"+Date.now(),a=document.createElement("iframe");a.setAttribute("id",t);var e=function(t){var a=-1<t.indexOf("youtu"),e=-1<t.indexOf("vimeo"),o=void 0;a?(o="//www.youtube.com/embed/"+t.match(/^.*(youtu.be\/|v\/|e\/|u\/\w+\/|embed\/|v=)([^#&?]*).*/)[2]+"?rel=0",L&&(o+="&autoplay=1")):e&&(o="//player.vimeo.com/video/"+t.match(/.*(www\.)?vimeo.com\/(\d+)($|\/)/)[2]);return o}(T),o=Q();a.style.height=o+"px","no-title"===k&&(a.style.border=m+"px solid "+y+"!important",a.style.borderRadius=l+"px!important"),a.src=e,a.frameBorder=0,a.allowfullscreen=!0,K(a),H.style.height=o+"px",window.addEventListener("resize",function(){var t=document.querySelector("abtasty-modal iframe"),a=Q();t.style.height=a+"px",H.style.height=a+"px"})}function X(){if(e=Number(I),!(o=localStorage.getItem(z))||-1===e||R||q||(0===e?!sessionStorage.getItem(z):o<P-24*e*60*60*1e3)){if("video"===i)V(),G();else if("image"===i&&"fit"===A){var t=new Image;t.src=W,t.className="abtasty-modal__media",t.onload=function(){K(this),H.style.width=this.width+"px",H.style.height=this.height+"px",G()}}else K(),G();D.style.display="block",a=document.querySelector("body"),F=window.getComputedStyle(a).overflowY,a.style.overflowY="hidden",void 0!==U&&ABTastyEvent(U+" "+i+" modal displayed",null,TEST_ID),R||(localStorage.setItem(z,P),sessionStorage.setItem(z,P))}var a,e,o}j=function(){var e,o,i,n,r,t,d,l,s,m,y,b,a=window.top.ABTastyWidgetForm||!1;if(R&&a)X();else if("click"===O)m=E,y=X,b=M+", "+N,document.body.addEventListener("click",function(t){var a=t.target;if(!b||!$(a,b))for(;a;){if(a!==document&&$(a,m)){y();break}a=a.parentNode}});else switch(O){case"pageLoad":X();break;case"exitIntent":r=X,t=DATA.exitEventDelay,d=parseFloat(t)||0,l=void 0,s=0,document.addEventListener("mousemove",function(t){s=t.clientY}),document.body.addEventListener("mouseleave",function t(a){a.clientY<=50&&(s=0,clearInterval(l),l=setTimeout(function(){0===s&&(r(),document.body.removeEventListener("mouseleave",t))},1e3*d))},!1);break;case"reengage":e=X,o=DATA.reengageEventDelay,n=void 0,(i=["mousemove","keydown","scroll"]).forEach(function(t){document.addEventListener(t,function a(){clearTimeout(n),n=setTimeout(function(){e(),i.forEach(function(t){return document.removeEventListener(t,a)})},1e3*o)},!1)});break;case"timer":clearTimeout(Y),Y=setTimeout(X,1e3*B)}},"loading"!==document.readyState?j():document.addEventListener("DOMContentLoaded",j)}();
{
"name": "@abtasty/modal",
"description": "Widget for AB Tasty",
"version": "2.5.12-0",
"version": "2.5.12",
"icon": "icon.png",

@@ -6,0 +6,0 @@ "form": "dist/form.js",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc