

(function () {
    var loopaSmartEvents = window._loopaSmartEvents;

    loopaSmartEvents.publisherData = {
    pubId: '690a863d736b773d4db00b16',
    extraPublisherIds: '',
    siteScript: '\\n<script>\\n!function(e,i){if(!e.pixie){var n=e.pixie=function(e,i,a){n.actionQueue.push({action:e,actionValue:i,params:a})};n.actionQueue=[];var a=i.createElement("script");a.async=!0,a.src="//acdn.adnxs.com/dmp/up/pixie.js";var t=i.getElementsByTagName("head")[0];t.insertBefore(a,t.firstChild)}}(window,document);\\npixie(\'init\', \'62bdb0e0-a21c-4956-ad46-6eda489f2fc9\');\\n</script>\\n\\n\\n<script>\\npixie(\'event\', \'PageView\');\\n</script>\\n<noscript><img src="https://ib.adnxs.com/pixie?pi=62bdb0e0-a21c-4956-ad46-6eda489f2fc9&e=PageView&script=0" width="1" height="1" style="display:none"/></noscript>\\n\\n\\n\\n<script>\\n!function(f,b,e,v,n,t,s)\\n{if(f.fbq)return;n=f.fbq=function(){n.callMethod?\\nn.callMethod.apply(n,arguments):n.queue.push(arguments)};\\nif(!f._fbq)f._fbq=n;n.push=n;n.loaded=!0;n.version=\'2.0\';\\nn.queue=[];t=b.createElement(e);t.async=!0;\\nt.src=v;s=b.getElementsByTagName(e)[0];\\ns.parentNode.insertBefore(t,s)}(window, document,\'script\',\\n\'https://connect.facebook.net/en_US/fbevents.js\');\\nfbq(\'init\', \'879022418394089\');\\nfbq(\'track\', \'PageView\');\\n</script>\\n<noscript><img height="1" width="1" style="display:none"\\nsrc="https://www.facebook.com/tr?id=879022418394089&ev=PageView&noscript=1"\\n/></noscript>\\n\\n\\n\\n<script type=\'text/javascript\'>\\n  window._tfa = window._tfa || [];\\n  window._tfa.push({notify: \'event\', name: \'page_view\', id: 1949834});\\n  !function (t, f, a, x) {\\n         if (!document.getElementById(x)) {\\n            t.async = 1;t.src = a;t.id=x;f.parentNode.insertBefore(t, f);\\n         }\\n  }(document.createElement(\'script\'),\\n  document.getElementsByTagName(\'script\')[0],\\n  \'//cdn.taboola.com/libtrc/unip/1949834/tfa.js\',\\n  \'tb_tfa_script\');\\n</script>\\n\\n\\n<script async src="https://js.adsrvr.org/up_loader.3.0.0.js"></script>\\n<script>\\n    window.ttdConversionEventsLayer = window.ttdConversionEventsLayer || [];\\n    function ttdConversionEvents() {\\n        window.ttdConversionEventsLayer.push(arguments);\\n    }\\n    \\n    ttdConversionEvents("init", {\\n        advertiserId: "hvhgxrg",\\n        pixelIds: ["f2rfvhu"]\\n    });\\n\\n    ttdConversionEvents("event", {});\\n</script>\\n\\n<script>\\n  // Click To Call\\n  document.querySelectorAll("a[href*=\'tel:\']").forEach((item) => {\\n    item.addEventListener("click", function () {\\n      loopa.push({\\n        event: \'conversion\',\\n        data: { type: "ClickToCall", products: _loopaSmartEvents.productParsingData.productId()}\\n      });\\n    });\\n  });\\n\\n  // Click To Email\\n  document.querySelectorAll("a[href*=\'mailto:\'], .contact_link_email a, .contact_link_email span span").forEach((item) => {\\n    item.addEventListener("click", function () {\\n      loopa.push({\\n        event: \'conversion\',\\n        data: { type: "EmailClick", products: _loopaSmartEvents.productParsingData.productId()}\\n      });\\n    });\\n  });\\n  \\n  // ListingOpentimes\\n  document.querySelectorAll(".event_actions span.btn").forEach((item) => {\\n    item.addEventListener("click", function () {\\n      loopa.push({\\n        event: \'conversion\',\\n        data: { type: "ListingOpentimes", products: _loopaSmartEvents.productParsingData.productId()}\\n      });\\n    });\\n  });  \\n\\n  // enquireForm\\n document.querySelectorAll(".pdp_next_steps_contract, .pdp_contact_prompt button.btn, .pdp_next_steps_question, .event_actions>span, .contact_link_email a, .contact_link_email span span, .pdp_contact_prompt button[type=button], .footer_button_bar .tbc .btn, .menu_footer>.btn").forEach((button) => {\\n      button.addEventListener("click", () => {\\n          setTimeout(() => {\\n              var phone = document.querySelector("input[type=submit]")\\n              phone.addEventListener("click", () => {\\n                  loopa.push({\\n                      event: \'conversion\',\\n                      data: { type: "enquireForm", products: _loopaSmartEvents.productParsingData.productId() }\\n                  });\\n              });\\n          }, 500);\\n      });\\n  });\\n  \\n   // ViewFloorplan\\n   document.querySelector(".header_feature_button.floorplan_button").addEventListener("click", function () {\\n     loopa.push({\\n         event: \'conversion\',\\n         data: {type:"ViewFloorplan", products: _loopaSmartEvents.productParsingData.productId()}\\n      });\\n   }); \\n      //VideoView\\n  document.querySelector(".header_feature_button.video_play_button").addEventListener("click", function () {\\n     loopa.push({\\n         event: \'conversion\',\\n         data: {type:"VideoView", products: _loopaSmartEvents.productParsingData.productId()}\\n      });\\n   }); \\n  \\n\\n  //ViewGallery\\n  document.querySelectorAll(".header_feature_button.three_d_tour_button, .pdp_feature, .pdp_image picture img, .gallery_modal_slide_nav .next span, .gallery_modal_slide_nav .prev span").forEach((item) => {\\n      item.addEventListener("click", function () {\\n          loopa.push({\\n              event: \'conversion\',\\n              data: { type: "ViewGallery", products: _loopaSmartEvents.productParsingData.productId()}\\n          });\\n      });\\n     \\n  });  \\n  \\n  //MAP AND DIRECTION CLICKS (Listing Map)\\n  document.querySelector("#location .pdp_map_wrap").addEventListener("click", function () {\\n      	loopa.push({\\n           event: \'conversion\',\\n           data: {type:"GetDirections", products: _loopaSmartEvents.productParsingData.productId()}\\n        });\\n    }); \\n  \\n  //ViewGallery\\n  document.querySelectorAll(".pdp_jump_links.full ul li span").forEach((item) => {\\n    if (item.textContent.includes("Photos")) {\\n      item.addEventListener("click", function () {\\n          loopa.push({\\n              event: \'conversion\',\\n              data: { type: "ViewGallery", products: _loopaSmartEvents.productParsingData.productId()}\\n          });\\n      });\\n    }\\n    if (item.textContent.includes("Floorplan")) {\\n      item.addEventListener("click", function () {\\n          loopa.push({\\n              event: \'conversion\',\\n              data: { type: "ViewFloorplan", products: _loopaSmartEvents.productParsingData.productId()}\\n          });\\n      });\\n    }\\n    if (item.textContent.includes("Video")) {\\n      item.addEventListener("click", function () {\\n          loopa.push({\\n              event: \'conversion\',\\n              data: { type: "VideoView", products: _loopaSmartEvents.productParsingData.productId()}\\n          });\\n      });\\n    }\\n     \\n  });  \\n  \\n</script>\\n',
    productScript: '',
    conversionScript: '<script>\\n	fbq(\'trackSingle\', \'879022418394089\', \'Lead\', {\\n		enquiryType: \'[[TYPE]]\'\\n	});\\n\\n	_tfa.push({ notify: \'event\', name: "[[TYPE]]", id: 1949834 });\\n  \\n  	pixie("event", "Lead", {            \\n		item_type: "[[TYPE]]"\\n	});\\n</script>\\n<loopascript>\\n  ttdConversionEvents("event", { "td1": "[[TYPE]]" });\\n</loopascript>\\n<script>\\n    var conversionType = "[[TYPE]]";\\n    switch (conversionType) {        \\n        case "enquireForm":\\n        case "ClickToCall":\\n        case "EmailClick":\\n        case "AddToCalendar":\\n			      fbq(\'trackSingle\', \'879022418394089\', \'Lead\', {\\n                enquiryType: \'HardEnquiry\'\\n            }); \\n            pixie(\'event\', \'Lead\', { item_type: \'HardEnquiry\', });\\n            _tfa.push({ notify: \'event\', name: \'HardEnquiry\', id: 1949834 });                  \\n            break;        \\n      default:\\n            fbq(\'trackSingle\', \'879022418394089\', \'Lead\', {\\n                enquiryType: \'Interest\'\\n            });  \\n            pixie(\'event\', \'Lead\', { item_type: \'Interest\', });\\n            _tfa.push({ notify: \'event\', name: \'Interest\', id: 1949834 });           \\n            break;  \\n  \\n  }  \\n         		\\n</script>',
    addToCartScript: '',
    genericActionScript: '',
    allowCookieMessage: false,
    messageSelector: '',
    includePostscribe: false,
    autoTriggerOnHashChange: false,
    enableEU: false,
    postParsedData: false,
    audienceSplitScript: '',
    enableActionTracking: false,
    parsingMode: 2,
    collectParsingListFromUserActivity: false
    };

    loopaSmartEvents.productParsingData = {
    title: function() { return '' },
    itemUrl: function() { return '' },
    productId: function() { return document.location.href.indexOf('/properties/') > 0 ? 'RWW' + window.location.href.match(/(\d+)$/)[0] : "" },
    description: function() { return '' },
    mainImage: function() { return '' },
    images: function() { return '' },
    language: function() { return '' },
    price: function() { return '' },
    rrp: function() { return '' },
    brandName: function() { return '' },
    colour: function() { return '' },
    stock: function() { return '' },
    category: function() { return '' },
    subCategory: function() { return '' },
    mpn: function() { return '' },
    gtin: function() { return '' },
    productType: function() { return '' },
    customField1: function() { return '' },
    customField2: function() { return '' },
    customField3: function() { return '' },
    customField4: function() { return '' },
    customField5: function() { return '' },
    customField6: function() { return '' },
    customField7: function() { return '' },
    customField8: function() { return '' },
    customField9: function() { return '' },
    customField10: function() { return '' },
    customField11: function() { return '' },
    customField12: function() { return '' },
    customField13: function() { return '' },
    customField14: function() { return '' },
    customField15: function() { return '' },
    customField16: function() { return '' },
    latitude: function() { return '' },
    longitude: function() { return '' }
    };

    loopaSmartEvents.gdprSettings = {
    mode: 'BlockEu',
    applyRulesOutsideEu: false,
    cookieAllowedCheckScript: function() { return false },
    cookieDisabledCheckScript: function() { return false }
    };

    loopaSmartEvents.userData = {
    hasCookie: false,
    userId: ''    
    };

    }());
