Update Quiz button

(function(w, d, s, o){ var j = d.createElement(s); j.async = true; j.src = ‘//script.marquiz.io/v2.js’;j.onload = function() { if (document.readyState !== ‘loading’) Marquiz.init(o); else document.addEventListener(“DOMContentLoaded”, function() { Marquiz.init(o); }); }; d.head.insertBefore(j, d.head.firstElementChild); })(window, document, ‘script’, { host: ‘//quiz.marquiz.io’, region: ‘us’, id:…Continue reading

CSS Mobile burger menu

@media ( max-width: 1023px ) { .gm-navigation-drawer–mobile .gm-menu-btn-close-mobile-drawer { padding: 12px 0px 0px 0px !important; } .gm-navigation-drawer–mobile .gm-mobile-menu-container { margin-top: 0px; } }Continue reading

Injects Rewards into mobile burger menu

jQuery( document ).ready( () => { let mobile_menu_container = jQuery( ‘.gm-mobile-menu-container’ ).first(); if ( typeof mobile_menu_container == typeof undefined ) { return; } let component = ` Terra Rewards Earn points, rewards and discounts! `; mobile_menu_container.before( component ); });Continue reading

Product Quizz

const review_quizz_button = ( ev ) => { let target = jQuery( ev.currentTarget ); let span = target.children( ‘span’ ).first(); if ( typeof span == typeof undefined ) { return false; } let text = span.html(); if ( `${text}` ==…Continue reading

Banner My Rewards Fix

function try_open_my_rewards() { let my_rewards_container = jQuery( ‘.wll-launcher-button-container’ ); if ( my_rewards_container.length < 1 ) { window.location.href = '/my-account/loyalty_reward/'; return; } my_rewards_container.first().trigger('click'); } jQuery( document ).ready(() => { let banner_my_rewards = jQuery( ‘#myRewards’ ); if ( banner_my_rewards.length < 1 )…Continue reading

VERY IMPORTANT – Updates Express Checkout Elements

const update_apple_pay_button = () => { let target_container = jQuery( ‘.eh_payapal_express_checkout_button’ ); let target_button = jQuery( ‘.apple-pay-button’ ); if ( target_container.length == 0 || target_button.length == 0 ) { return; } target_button = target_button.clone( true ); let current_button_style = target_button.attr(…Continue reading

Auto-Launches quizz

jQuery( document ).ready(() => { let hash = window.location.hash; let contains_hash = ( hash == ‘#quiz’ ); if ( contains_hash ) { Marquiz.showModal( ’62a10a9ab692e000277a518a’ ); } });Continue reading