Untitled

mail@pastecode.io avatar
unknown
plain_text
2 years ago
4.0 kB
3
Indexable
Never

(function () {
  try {
    /* main variables */
    var debug = 0;
    var variation_name = "";

    /* all Pure helper functions */

    function waitForElement(selector, trigger, delayInterval, delayTimeout) {
      var interval = setInterval(function () {
        if (
          document &&
          document.querySelector(selector) &&
          document.querySelectorAll(selector).length > 0
        ) {
          clearInterval(interval);
          trigger();
        }
      }, delayInterval);
      setTimeout(function () {
        clearInterval(interval);
      }, delayTimeout);
    }

    /* Variation functions */
  
function init(){

      document.querySelector(".s-trial .b-steps-free-trial").insertAdjacentHTML("afterend",'<div class="eg-video-container"><div class="eg-thumbnail"></div><div class="eg-video"><iframe allow="autoplay; fullscreen; picture-in-picture; camera; microphone; display-capture" allowfullscreen="" allowtransparency="true" referrerpolicy="no-referrer-when-downgrade" class="vidyard-iframe-Aydz1phXGXAqUGqg4pWWMw" frameborder="0"scrolling="no" src="https://play.vidyard.com/Aydz1phXGXAqUGqg4pWWMw?disable_popouts=1&amp;v=4.3.10&amp;type=inline&amp;autoplay=0" style="opacity: 1; background-color: transparent;"></iframe></div></div>');


      document.querySelector('.eg-thumbnail').addEventListener('click', function(){

        this.remove();
        document.querySelector('.eg-video-container .eg-video iframe').src = 'https://play.vidyard.com/Aydz1phXGXAqUGqg4pWWMw?disable_popouts=1&v=4.3.10&type=inline&autoplay=1';
      });


document.querySelector("div.s-trial__cols > div:nth-child(1) > div.b-steps-free-trial").insertAdjacentHTML("afterend", "<p id='eg_faq'>Looking for Something ? Check out our FAQs</p>")


document.querySelector("#eg_faq").addEventListener("click",()=>{

                                                                                                                                                                                                                      
               document.querySelector("div.l-page__in > div > article > section").scrollIntoView({behavior: "smooth"})                                                                                                                                                    })
}
    /* Initialize variation */
    waitForElement(".s-trial .b-steps-free-trial", init, 100, 35000);
  } catch (e) {
    if (debug) console.log(e, "error in Test" + variation_name);
  }
})();






.s-trial__col p#eg_faq {
    text-align: center;
    padding-top: 15px;
    margin-bottom: -10px;
  color: #2B87C8;
cursor: pointer;
font-weight: 400;
}

.s-trial__col .b-steps-free-trial {
  background: #2B87C8 ;
}

 .mktoButtonRow .wds-btn._primary {
    background: #fff;
    color: #000;
}

.s-trial__col .b-steps-free-trial__nav__value {
  color: #fff;
  border-color: #fff;
}

.s-trial__cols .b-steps-free-trial__subnav,
.s-trial__cols .b-steps-free-trial__chat  a,
.b-steps-free-trial__back,
.l-page__in .s-trial__cols h2,
label#LblOpt_In__c {
  color: #fff !important;
}

#LblOpt_In__c a {
  color: purple;
}

.b-steps-free-trial__back::before{
  border-left: 2px solid #fff;
  border-bottom: 2px solid #fff;
}

.b-steps-free-trial__chat a::before {
  filter: brightness(10);
}

.eg-video {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%;
  height: 0;
border: 1px solid #605d5d;
}

.eg-video iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.eg-video-container {
  padding: 40px 20px;
}

.eg-thumbnail {
  position: absolute;
  width: calc(100% - 40px);
  height: calc(100% - 80px);
  background: transparent;
  top: 40px;
  left: 20px;
  z-index: 1;
  cursor: pointer;
}
.eg-video-container {
  position: relative;
}
@media screen and (max-width: 767px) {
  html body .eg-thumbnail {
      width: calc(100% - 30px);
  }

  .eg-video-container {
      padding: 40px 15px;
  }

}