/*! * BizPanda Lockers - v2.3.7, 2018-07-08 * for jQuery: http://onepress-media.com/plugin/social-locker-for-jquery/get * for Wordpress: http://onepress-media.com/plugin/social-locker-for-wordpress/get * * Copyright 2018, OnePress, http://byonepress.com * Help Desk: http://support.onepress-media.com/ */ /*! * Localization * Copyright 2014, OnePress, http://byonepress.com * * @since 1.0.0 * @pacakge core */ (function ($) { /** * Text resources. */ if ( !$.pandalocker ) $.pandalocker = {}; if (!$.pandalocker.lang) $.pandalocker.lang = {}; if (!$.pandalocker.lang.defaults ) $.pandalocker.lang.defaults = {}; $.pandalocker.lang.defaults = { // - translatable text // the Screen "Please Confirm Your Email" confirm_screen_title: 'Please Confirm Your Email', confirm_screen_instructiont: 'We have sent a confirmation email to {email}. Please click on the confirmation link in the email to reveal the content.', confirm_screen_note1: 'The content will be unlocked automatically within 10 seconds after confirmation.', confirm_screen_note2: 'Note delivering the email may take several minutes.', confirm_screen_cancel: '(cancel)', confirm_screen_open: 'Open my inbox on {service}', // the Screen "One Step To Complete" onestep_screen_title: 'One Step To Complete', onestep_screen_instructiont: 'Please enter your email below to continue.', onestep_screen_button: 'OK, complete', // the sign-in buttons signin_long: 'Sign in via {name}', signin_short: 'via {name}', signin_facebook_name: 'Facebook', signin_twitter_name: 'Twitter', signin_google_name: 'Google', signin_linkedin_name: 'LinkedIn', // miscellaneous misc_data_processing: 'Processing data, please wait...', misc_or_enter_email: 'or enter your email manually to sign in', misc_enter_your_name: 'enter your name', misc_enter_your_email: 'enter your email address', misc_your_agree_with: 'By clicking on the button(s), you agree with {links}', misc_terms_of_use: 'Terms of Use', misc_privacy_policy: 'Privacy Policy', misc_agreement_checkbox: 'I consent to processing of my data according to {links}', misc_agreement_checkbox_alt: 'I agree with {links}', misc_or_wait: 'or wait {timer}s', misc_close: 'Close', misc_or: 'OR', // errors & notices errors_empty_email: "Please enter your email address.", errors_inorrect_email: "It seems you entered an incorrect email address. Please check it.", errors_empty_name: "Please enter your name.", errors_empty_field: "Please fill this field.", errors_empty_checkbox: "Please mark this checkbox to continue.", errors_invalid_url: "Please enter a valid URL.", errors_invalid_integer: "Please enter an integer number.", errors_greater_number: "Please enter a number greater than or equal to {0}.", errors_less_number: "Please enter a number less than or equal to {0}.", errors_invalid_value: "Invalid value. Please check the value you entered.", errors_invalid_date: "Please enter a valid date.", errors_invalid_month: "Please enter a valid month number (between 01 and 12).", errors_invalid_day: "Please enter a valid day number (between 01 and 31).", errors_subscription_canceled: "You have canceled your subscription.", errors_not_signed_in: "Sorry, but you have not signed in. Please try again.", res_errors_not_granted: "Sorry, but you have not granted all the required permissions ({permissions}). Please try again.", errors_no_consent: "Please give us your consent in order to continue.", // - default text & internal errors // common resources error: 'error', noSpam: 'Your email address is 100% safe from spam!', errors: { ajaxError: 'Unexpected ajax error. Please check the console log to get more details.', unableToLoadSDK: 'Unable to load SDK script for "{0}" due to the error "{1}". Please make sure that nothing blocks loading of social scripts in your browser. Some browser extentions (Avast, PrivDog, AdBlock etc.) or usage of private tabs in FireFox may cause this issue. Turn them off and try again.', unableToCreateControl: 'Unable to create ({0}). Please make sure that nothing blocks loading of social scripts in your browser. Some browser extentions (Avast, PrivDog, AdBlock etc.) can cause this issue. Turn them off and try again.', invlidFacebookAppId: 'Invalid App ID or given URL is not allowed by the Application configuration: One or more of the given URLs is not allowed by the App\'s settings. It must match the Website URL or Canvas URL, or the domain must be a subdomain of one of the App\'s domains.', invlidFacebookAppIdOrSSL: 'Current URL is not allowed by the Facebook App configuration or a SSL certificate is required. Please check out the plugin help section to learn more: How to use -> Creating Social Apps -> Creating Facebook App.', sslRequired: 'All new Facebook apps created as of March 2018 have to use only HTTPS URLs when using Facebook Login. It means that you need to install a SSL certificate on your website. Please check out the plugin help section to learn more: How to use -> SSL certificate.', emptyFBAppIdError: 'Please set your Facebook App ID.', emptyTwitterFollowUrlError: 'Please set an URL of your Twitter profile.', tweetNotFound: 'Please make sure that you have posted the tweet. Unfortunately we have not manage to find the tweet in your account.', followingNotFound: 'Please make sure that you have followed us. Unfortunately we have not manage to find you in the list of followers.', unsupportedTwitterTweetLayout: 'The Twitter Tweet Button doesn\'t support the vertical layout. Please remove the Tweet button or select another theme.', unsupportedTwitterFollowLayout: 'The Twitter Follow Button doesn\'t support the vertical layout. Please remove the Follow button or select another theme.', emptyYoutubeChannelId: 'Please set your Youtube Channel ID.', emptyGoogleClientId: 'Please set your Google Client ID.', unsupportedYoutubeSubscribeLayout: 'The Youtube Subscribe Button doesn\'t support the vertical layout. Please remove the Subscribe button or select another theme.' }, // locker type-dependent resources scopes: { // when the Connect Buttons is the primary group signinLocker: { defaultHeader: "Sing In To Unlock This Content", defaultMessage: "Please sign in. Just click one of the buttons below to get instant access.", btnSubscribe: "sign in to unlock", viaSignInLong: "{long}", viaSignInShort: "{short}" }, // when the Subscription is the primary group emailLocker: { defaultHeader: "This Content Is Only For Subscribers", defaultMessage: "Please subscribe to unlock this content. Just enter your email.", btnSubscribe: "subscribe to unlock", viaSignInLong: "{short}", viaSignInShort: "{name}" }, // when the Social Buttons is the primary group socialLocker: { defaultHeader: "This content is locked", defaultMessage: "Please support us, use one of the buttons below to unlock the content." } }, // text resources for the group 'connect-buttons' connectButtons: { defaultMessage: "subscribe via your social profile by one click", facebook: {}, google: { clientIdMissed: "The Google Client ID is not set. You need to generate a client ID before using the button.", unexpectedError: 'Unable to sign in. Unexpected error occurred: {0}' }, twitter: { proxyEmpty: "The proxy URL is empty. The proxy is used to call Twitter API." }, linkedin: { clientIdMissed: "The LinkedIn Client ID or Client Secret is not set. You need to set these settings before using the button." }, defaultSeparator: "or", errorYouTubeChannelMissed: "Please set an ID of your Youtube channel to subscribe.", errorLinkedInCompanyNotFound: "The LinkedIn company '{0}' not found.", errorLinkedInCompanyMissed: "Please specify the LinkedIn company ID or name to follow.", errorTwitterUserMissed: "Please specify the Twitter user name to follow.", errorTwitterMessageMissed: "Please specify the message to tweet.", }, // text resources for the group 'subscription' subscription: { defaultText: 'Cannot sign in via social networks? Enter your email manually.', defaultButtonText: 'done, sign in to unlock', }, // text resources for the group 'social-buttons' socialButtons: { // default labels for the buttons covers facebookLike: 'like us', facebookShare: 'share', twitterTweet: 'tweet', twitterFollow: 'follow us', googlePlus: '+1 us', googleShare: 'share', youtubeSubscribe: 'subscribe', linkedinShare: 'share' } }; $.pandalocker.lang = $.pandalocker.lang.defaults; if ( window.__pandalockers && window.__pandalockers.lang ) { $.pandalocker.lang = $.extend( $.pandalocker.lang, window.__pandalockers.lang ); window.__pandalockers.lang = null; } })(jQuery);; /*! * Themes Presets * Copyright 2014, OnePress, http://byonepress.com * * @since 1.0.0 * @pacakge core */ (function ($) { if (!$.pandalocker.themes) $.pandalocker.themes = {}; // Theme: Great Attractor $.pandalocker.themes['great-attractor'] = {}; // Theme: Friendly Giant $.pandalocker.themes['friendly-giant'] = { theme: { fonts: [{ name: 'Open Sans', styles: ['400', '700'] }] } }; // Theme: Dark Force $.pandalocker.themes['dark-force'] = { theme: { fonts: [{ name: 'Montserrat', styles: ['400', '700'] }] } }; // Theme: Starter $.pandalocker.themes['starter'] = { socialButtons: { layout: 'horizontal', counter: true, flip: false } }; // Theme: Secrets $.pandalocker.themes['secrets'] = { socialButtons: { layout: 'horizontal', counter: true, flip: true } }; // Theme: Dandyish $.pandalocker.themes['dandyish'] = { socialButtons: { unsupported: ['twitter-follow'], layout: 'vertical', counter: true, flip: false } }; // Theme: Glass $.pandalocker.themes['glass'] = { socialButtons: { layout: 'horizontal', counter: true, flip: false } }; // Theme: Flat $.pandalocker.themes['flat'] = { socialButtons: { layout: 'horizontal', counter: true, flip: true } }; })(jQuery);; /*! * Variables * Copyright 2014, OnePress, http://byonepress.com * * @since 1.0.0 * @pacakge includes */ !function(a){"use strict";a.pandalocker||(a.pandalocker={}),a.pandalocker.data||(a.pandalocker.data={}),a.pandalocker.entity||(a.pandalocker.entity={}),a.pandalocker.groups||(a.pandalocker.groups={}),a.pandalocker.controls||(a.pandalocker.controls={}),a.pandalocker.tools||(a.pandalocker.tools={}),a.pandalocker.storages||(a.pandalocker.storages={}),a.pandalocker.services||(a.pandalocker.services={}),a.pandalocker.extras||(a.pandalocker.extras={}),a.pandalocker.controls["social-buttons"]||(a.pandalocker.controls["social-buttons"]={}),a.pandalocker.controls["connect-buttons"]||(a.pandalocker.controls["connect-buttons"]={}),a.pandalocker.controls.subscription||(a.pandalocker.controls.subscription={})}(jQuery);; /*! * Filers & Hooks API * Copyright 2014, OnePress, http://byonepress.com * * @since 1.0.0 * @pacakge core */ !function(a){"use strict";a.pandalocker||(a.pandalocker={}),a.pandalocker.filters=a.pandalocker.filters||{_items:{},_priorities:{},run:function(a,b){var c=b&&b.length>0?b[0]:null;if(!this._items[a])return c;for(var d in this._priorities[a])if(this._priorities[a].hasOwnProperty(d))for(var e=this._priorities[a][d],f=0;f"+b+""):"object"==typeof b?b.clone():b:b},a.pandalocker.tools.diffArrays=function(b,c){return a.grep(b,function(b){return-1==a.inArray(b,c)})},a.pandalocker.tools.unionArrays=function(b,c){return a.grep(b,function(b){return-1!==a.inArray(b,c)})},a.pandalocker.tools.cookie=a.pandalocker.tools.cookie||function(b,c,d){if(arguments.length>1&&(!/Object/.test(Object.prototype.toString.call(c))||null===c||void 0===c)){if(d=a.extend({},d),(null===c||void 0===c)&&(d.expires=-1),"number"==typeof d.expires){var e=d.expires,f=d.expires=new Date;f.setDate(f.getDate()+e)}return c=String(c),document.cookie=[encodeURIComponent(b),"=",d.raw?c:encodeURIComponent(c),d.expires?"; expires="+d.expires.toUTCString():"",d.path?"; path="+d.path:"",d.domain?"; domain="+d.domain:"",d.secure?"; secure":""].join("")}d=c||{};for(var g,h=d.raw?function(a){return a}:decodeURIComponent,i=document.cookie.split("; "),j=0;g=i[j]&&i[j].split("=");j++)if(h(g[0])===b)return h(g[1]||"");return null},a.pandalocker.tools.hash=a.pandalocker.tools.hash||function(a){var b=0;if(!a||0===a.length)return b;for(var c=0;c0&&"none"!==a},a.pandalocker.tools.canBlur=a.pandalocker.tools.canBlur||function(){var a=document.createElement("div");a.style.cssText=_browserPrefixes.join("filter:blur(2px); ");var b=!!a.style.length&&(void 0===document.documentMode||document.documentMode>9);if(b)return!0;try{b=void 0!==typeof SVGFEColorMatrixElement&&2==SVGFEColorMatrixElement.SVG_FECOLORMATRIX_TYPE_SATURATE}catch(c){}return b},a.pandalocker.isTouch=a.pandalocker.isTouch||function(){return!!("ontouchstart"in window)||!!("onmsgesturechange"in window)},a.pandalocker.widget=function(b,c){var d={createWidget:function(d,e){var f=a.extend(!0,{},c);if(f.element=a(d),"BODY"==d.tagName){var g='
';a("body").wrapInner(g),f.element=a(".onp-sl-body-inner-wrap")}f.options=a.extend(!0,f.options,e),f._init&&f._init(),f._create&&f._create(),a.data(d,"plugin_"+b,f)},callMethod:function(a,b){return a[b]&&a[b]()}};a.fn[b]=function(){var c=arguments,e=arguments.length,f=this;return this.each(function(){var g=a.data(this,"plugin_"+b);!g&&1>=e?d.createWidget(this,e?c[0]:!1):1==e&&(f=d.callMethod(g,c[0]))}),f}},a.pandalocker.detectBrowser=a.pandalocker.detectBrowser||function(){function b(){var a=-1;if("Microsoft Internet Explorer"==navigator.appName){var b=navigator.userAgent,c=new RegExp("MSIE ([0-9]{1,}[.0-9]{0,})");null!=c.exec(b)&&(a=parseFloat(RegExp.$1))}else if("Netscape"==navigator.appName){var b=navigator.userAgent,c=new RegExp("Trident/.*rv:([0-9]{1,}[.0-9]{0,})");null!=c.exec(b)&&(a=parseFloat(RegExp.$1))}return a}var c=jQuery.uaMatch||function(a){a=a.toLowerCase();var b=/(chrome)[ \/]([\w.]+)/.exec(a)||/(webkit)[ \/]([\w.]+)/.exec(a)||/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(a)||/(msie) ([\w.]+)/.exec(a)||a.indexOf("compatible")<0&&/(mozilla)(?:.*? rv:([\w.]+)|)/.exec(a)||[];return{browser:b[1]||"",version:b[2]||"0"}},d=c(navigator.userAgent);a.pandalocker.browser={},d.browser&&(a.pandalocker.browser[d.browser]=!0,a.pandalocker.browser.version=d.version);var e=b();e>0&&(a.pandalocker.browser.msie=!0,a.pandalocker.browser.version=e),a.pandalocker.browser.chrome?a.pandalocker.browser.webkit=!0:a.pandalocker.browser.webkit&&(a.pandalocker.browser.safari=!0)},a.pandalocker.detectBrowser(),a.pandalocker.tools.camelCase=function(a){return a.toLowerCase().replace(/-(.)/g,function(a,b){return b.toUpperCase()})},a.pandalocker.tools.capitaliseFirstLetter=function(a){return a.charAt(0).toUpperCase()+a.slice(1)},a.pandalocker.tools.isMobile=function(){return/webOS|iPhone|iPod|BlackBerry/i.test(navigator.userAgent)?!0:/Android/i.test(navigator.userAgent)&&/Mobile/i.test(navigator.userAgent)?!0:!1},a.pandalocker.tools.isTabletOrMobile=function(){return/webOS|iPhone|iPad|Android|iPod|BlackBerry/i.test(navigator.userAgent)?!0:!1},a.pandalocker.tools.isInAppBrowser=function(){return a.pandalocker.tools.getInAppBrowser()?!0:!1},a.pandalocker.tools.getInAppBrowser=function(){return/FBAN|FBAV/i.test(navigator.userAgent)?"Facebook In-App browser":/Instagram/i.test(navigator.userAgent)?"Instagram In-App browser":/Twitter/i.test(navigator.userAgent)?"Twitter In-App browser":/VKAndroid/i.test(navigator.userAgent)?"VK In-App browser":!1},a.pandalocker.tools.updateQueryStringParameter=function(a,b,c){var d=new RegExp("([?&])"+b+"=.*?(&|$)","i"),e=-1!==a.indexOf("?")?"&":"?";return a.match(d)?a.replace(d,"$1"+b+"="+c+"$2"):a+e+b+"="+c},a.pandalocker.tools.parseQuery=function(a){if("string"!=typeof a)return!1;var b=[];if(a){var c=a.split("&");if(c)for(var d in c){var e=c[d].split("=");b[e[0]]=e[1]}}return b},a.pandalocker.tools.isValidEmailAddress=function(a){var b=new RegExp(/^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?$/i);return b.test(a)},a.pandalocker.tools.isValidUrl=function(a){var b=new RegExp(/^(https?|ftp):\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i);return b.test(a)},a.pandalocker.tools.findLeftWindowBoundry=function(){return window.screenLeft?window.screenLeft:window.screenX?window.screenX:0},a.pandalocker.tools.findTopWindowBoundry=function(){return window.screenTop?window.screenTop:window.screenY?window.screenY:0},a.pandalocker.tools.extractJSON=function(b){var c,d,e;c=b.indexOf("{",c+1);do{if(d=b.lastIndexOf("}"),c>=d)return null;do{e=b.substring(c,d+1);try{var f=a.parseJSON(e);if(f)return f}catch(g){}d=b.substr(0,d).lastIndexOf("}")}while(d>c);c=b.indexOf("{",c+1)}while(-1!=c);return!1},a.pandalocker.tools.saveValue=function(b,c,d){if(localStorage&&localStorage.setItem)try{localStorage.setItem(b,c)}catch(e){a.pandalocker.tools.cookie(b,c,{expires:d,path:"/"})}else a.pandalocker.tools.cookie(b,c,{expires:d,path:"/"})},a.pandalocker.tools.getValue=function(b,c){var d=localStorage&&localStorage.getItem&&localStorage.getItem(b);return d||(d=a.pandalocker.tools.cookie(b)),d?d:c},a.pandalocker.tools.guid=function(){var a=function(){return Math.floor(65536*(1+Math.random())).toString(16).substring(1)};return a()+a()+"-"+a()+"-"+a()+"-"+a()+"-"+a()+a()+a()}}(jQuery);; /*! * SDK Connector * Copyright 2014, OnePress, http://byonepress.com * * @since 1.0.0 * @pacakge core */ !function(a){"use strict";a.pandalocker.sdk=a.pandalocker.sdk||{_ready:{},_connected:{},_error:{},getSDK:function(b){return b=a.pandalocker.tools.camelCase(b),a.pandalocker.sdk[b]?a.pandalocker.sdk[b]:null},isConnected:function(b){if(a("#"+b.scriptId).length>0)return!0;var c=!1;return a("script").each(function(){var d=a(this).attr("src");return d?(c=-1!==d.indexOf(b.url),c?(a(this).attr("id",b.scriptId),!1):void 0):!0}),c},getLoadingScript:function(b){var c=a("#"+b.scriptId),d=a("script[src='*"+b.url+"']");return c.length>0?c:d},isLoaded:function(a){return this.isConnected(a)&&a.isLoaded&&a.isLoaded()},connect:function(b,c,d){var e=this,f=this.getSDK(b),g=new a.pandalocker.deferred;if(!f)return console&&console.log("Invalide SDK name: "+b),g.reject("invalide-sdk"),g.promise();if(f.options=c,setTimeout(function(){var a=f.isLoaded();a?e.setup&&e.setup():(e._connected[b]=!1,g.reject("timeout"))},d),this._ready[b])return g.resolve(),g.promise();if(a(document).bind(b+"-init",function(){g.resolve()}),a(document).bind(b+"-error",function(a,c){e._error[b]=!0,g.reject(c)}),this._connected[b]&&!e._error[b])return g.promise();f.createEvents||(f.createEvents=function(){var b=f.isLoaded(),c=function(){a(document).trigger(f.name+"-init")};return b?void c():void a(document).bind(f.name+"-script-loaded",function(){c()})}),f.prepare&&f.prepare();var h=f.isLoaded(),i=this.isConnected(f);if(a(document).bind(b+"-init",function(){e._ready[b]=!0}),this._connected[b]||f.createEvents(),!i||e._error[b]){if(e._error[b]){var j=this.getLoadingScript(f);j&&j.remove()}var k=function(){var a=document.createElement("script");a.type="text/javascript",a.id=f.scriptId,a.src=f.url;var b=f.getScriptBody?f.getScriptBody():null;b&&(a.innerHtml=b);var c=document.getElementsByTagName("body")[0];c.appendChild(a)};k()}if(!h){var j=this.getLoadingScript(f)[0];j.onerror=function(b){console&&console.log("Failed to load SDK script:"),console&&console.log(b),a(document).trigger(f.name+"-error",["blocked"])},j.onreadystatechange=j.onload=function(){var b=j.readyState;(!b||/loaded|complete/.test(b))&&(a(document).trigger(f.name+"-script-loaded"),a(document).unbind(f.name+"-script-loaded"))}}return setTimeout(function(){var b=f.isLoaded();b||a(document).trigger(f.name+"-error",["timeout"])},d),this._connected[b]=!0,g.promise()}}}(jQuery);; /*! * Functions to work with URLs * Copyright 2014, OnePress, http://byonepress.com * * @since 1.0.0 * @pacakge core */ /*! * URL.js * Copyright 2011 Eric Ferraiuolo * https://github.com/ericf/urljs */ !function(a){var b=function(){var a=this;return a&&a.hasOwnProperty&&a instanceof b||(a=new b),a._init.apply(a,arguments)};!function(){var a,c,d,e="absolute",f="relative",g=":",h="//",i="@",j=".",k="/",l="..",m="../",n="?",o="=",p="&",q="#",r="",s="type",t="scheme",u="userInfo",v="host",w="port",x="path",y="query",z="fragment",A=/^(?:(https?:\/\/|\/\/)|(\/|\?|#)|[^;:@=\.\s])/i,B=/^(?:(https?):\/\/|\/\/)(?:([^:@\s]+:?[^:@\s]+?)@)?((?:[^;:@=\/\?\.\s]+\.)+[A-Za-z0-9\-]{2,})(?::(\d+))?(?=\/|\?|#|$)([^\?#]+)?(?:\?([^#]+))?(?:#(.+))?/i,C=/^([^\?#]+)?(?:\?([^#]+))?(?:#(.+))?/i,D="object",E="string",F=/^\s+|\s+$/g;a=String.prototype.trim?function(a){return a&&a.trim?a.trim():a}:function(a){try{return a.replace(F,r)}catch(b){return a}},c=function(a){return a&&typeof a===D},d=function(a){return typeof a===E},b.ABSOLUTE=e,b.RELATIVE=f,b.normalize=function(a){return new b(a).toString()},b.resolve=function(a,c){return new b(a).resolve(c).toString()},b.prototype={_init:function(a){return this.constructor=b,a=d(a)?a:a instanceof b?a.toString():null,this._original=a,this._url={},this._isValid=this._parse(a),this},toString:function(){var a=this._url,b=[],c=a[s],d=a[t],f=a[x],i=a[y],j=a[z];return c===e&&(b.push(d?d+g+h:h,this.authority()),f&&0!==f.indexOf(k)&&(f=k+f)),b.push(f,i?n+this.queryString():r,j?q+j:r),b.join(r)},original:function(){return this._original},isValid:function(){return this._isValid},isAbsolute:function(){return this._url[s]===e},isRelative:function(){return this._url[s]===f},isHostRelative:function(){var a=this._url[x];return this.isRelative()&&a&&0===a.indexOf(k)},type:function(){return this._url[s]},scheme:function(a){return arguments.length?this._set(t,a):this._url[t]},userInfo:function(a){return arguments.length?this._set(u,a):this._url[u]},host:function(a){return arguments.length?this._set(v,a):this._url[v]},domain:function(){var a=this._url[v];return a?a.split(j).slice(-2).join(j):void 0},port:function(a){return arguments.length?this._set(w,a):this._url[w]},authority:function(){var a=this._url,b=a[u],c=a[v],d=a[w];return[b?b+i:r,c,d?g+d:r].join(r)},path:function(a){return arguments.length?this._set(x,a):this._url[x]},query:function(a){return arguments.length?this._set(y,a):this._url[y]},queryString:function(a){if(arguments.length)return this._set(y,this._parseQuery(a));a=r;var b,c,d=this._url[y];if(d)for(b=0,c=d.length;c>b;b++)a+=d[b].join(o),c-1>b&&(a+=p);return a},fragment:function(a){return arguments.length?this._set(z,a):this._url[z]},resolve:function(a){a=a instanceof b?a:new b(a);var c,d;return this.isValid()&&a.isValid()?a.isAbsolute()?this.isAbsolute()?a.scheme()?a:new b(a).scheme(this.scheme()):a:(c=new b(this.isAbsolute()?this:null),a.path()?(d=a.isHostRelative()||!this.path()?a.path():this.path().substring(0,this.path().lastIndexOf(k)+1)+a.path(),c.path(this._normalizePath(d)).query(a.query()).fragment(a.fragment())):a.query()?c.query(a.query()).fragment(a.fragment()):a.fragment()&&c.fragment(a.fragment()),c):this},reduce:function(a){a=a instanceof b?a:new b(a);var c=this.resolve(a);return this.isAbsolute()&&c.isAbsolute()&&c.scheme()===this.scheme()&&c.authority()===this.authority()&&c.scheme(null).userInfo(null).host(null).port(null),c},_parse:function(b,c){if(b=a(b),!(d(b)&&b.length>0))return!1;var g,h;switch(c||(c=b.match(A),c=c?c[1]?e:c[2]?f:null:null),c){case e:g=b.match(B),g&&(h={},h[s]=e,h[t]=g[1]?g[1].toLowerCase():void 0,h[u]=g[2],h[v]=g[3].toLowerCase(),h[w]=g[4]?parseInt(g[4],10):void 0,h[x]=g[5]||k,h[y]=this._parseQuery(g[6]),h[z]=g[7]);break;case f:g=b.match(C),g&&(h={},h[s]=f,h[x]=g[1],h[y]=this._parseQuery(g[2]),h[z]=g[3]);break;default:return this._parse(b,e)||this._parse(b,f)}return h?(this._url=h,!0):!1},_parseQuery:function(b){if(d(b)){b=a(b);var c,e,f,g=[],h=b.split(p);for(e=0,f=h.length;f>e;e++)h[e]&&(c=h[e].split(o),g.push(c[1]?c:[c[0]]));return g}},_set:function(a,b){return this._url[a]=b,!b||a!==t&&a!==u&&a!==v&&a!==w||(this._url[s]=e),b||a!==v||(this._url[s]=f),this._isValid=this._parse(this.toString()),this},_normalizePath:function(a){var b,c,d,e,f,g;if(a.indexOf(m)>-1){for(b=a.split(k),d=[],f=0,g=b.length;g>f;f++)c=b[f],c===l?d.pop():c&&d.push(c);e=d.join(k),a[0]===k&&(e=k+e),a[a.length-1]===k&&e.length>1&&(e+=k)}else e=a;return e}}}(),a.pandalocker||(a.pandalocker={}),a.pandalocker.tools||(a.pandalocker.tools={}),a.pandalocker.tools.URL=b}(jQuery);; /*! * Blurring * Copyright 2014, OnePress, http://byonepress.com * * @since 1.0.0 * @pacakge core */ /*! * * Version: 0.0.5 * Author: Gianluca Guarini * Website: http://www.gianlucaguarini.com/ */ !function(a,b,c){"use strict";var d={filterId:0},e=" -webkit- -moz- -o- -ms- ".split(" "),f=function(){var a=b.createElement("div");return a.style.cssText=e.join("filter:blur(2px); "),!!a.style.length&&(void 0===b.documentMode||b.documentMode>9)},g=function(){var a=!1;try{a=void 0!==typeof SVGFEColorMatrixElement&&2==SVGFEColorMatrixElement.SVG_FECOLORMATRIX_TYPE_SATURATE}catch(b){}return a},h=function(e,h){var i,j,k,l={intensity:5,forceSVGUrl:!1,animationOptions:{duration:1e3,easing:"linear"}},m=c.extend(l,h),n={},o=function(a){if(n[a]||""===n[a])return n[a]+a;for(var c=b.createElement("div"),d=["","Moz","Webkit","O","ms","Khtml"],e=0;ea)throw"I can animate only positive numbers";var d=new c.Deferred;return k&&k.stop(!0,!0),k=new c.Animation(m,{intensity:a},c.extend(m.animationOptions,b)).progress(c.proxy(this.blur,this)).done(d.resolve),d.promise()},this.unblur=function(){return this.$elm.css(r,"none"),this.$elm[0].style[r]="none",q=!1,this},this.toggleblur=function(){return q?this.unblur():this.blur(),this},this.destroy=function(){p.svgfilters&&c("filter#blur-effect-id-"+j).parent().remove(),this.unblur();for(var a in this)delete this[a];return this},this.init()};c.fn.Vague=function(a){return new h(this,a)},c.pandalocker.tools.supportBlurring=function(){return c.pandalocker.browser.msie&&c.pandalocker.browser.version>9&&c.pandalocker.browser.msie<12?!1:f()||g()?!0:!1}}(window,document,jQuery);; /*! * OnePress Default State Storage * Copyright 2014, OnePress, http://byonepress.com */ !function(a){"use strict";a.pandalocker.storages.defaultStateStorage=function(b){var c=b.options;this.demo=c.demo,this.useCookies=c.locker.useCookies,this.expires=c.locker.expires,this.isUnlocked=function(a){return this.demo?!1:this._getValue(a)?!0:!1},this.isLocked=function(a){return!this.isUnlocked(a)},this.requestState=function(a,b){return this.demo?b("locked"):void b(this.isUnlocked(a)?"unlocked":"locked")},this.setState=function(a,b){if(this.demo)return!0;try{return"unlocked"===b?this._setValue(a):this._removeValue(a)}catch(c){console&&console.log(c)}},this._setValue=function(b){if(!b)return!1;var c=!0,d=1e4;if(this.expires){var e=new Date,f=e.getTime(),g=f+1e3*this.expires;d=Math.ceil(this.expires/86400),c=JSON.stringify({expires:g})}var h=!0;if(localStorage&&!this.useCookies){h=!1;try{localStorage.setItem(b,c)}catch(i){console&&console.log(i),h=!0}}return h&&a.pandalocker.tools.cookie(b,c,{expires:d,path:"/"}),!0},this._getValue=function(b){if(!b)return!1;var c=localStorage&&!this.useCookies&&localStorage.getItem(b);if(c||(c=a.pandalocker.tools.cookie(b)),c)try{var d=JSON.parse(c);if(d&&d.expires){var e=new Date;return d.expires>e}return!0}catch(f){return!0}},this._removeValue=function(b){return b?(localStorage&&localStorage.removeItem(b),void a.pandalocker.tools.cookie(b,null)):!1}}}(jQuery);; /*! * OnePress Visibility Checker Service * Copyright 2015, OnePress, http://byonepress.com */ !function(a){"use strict";a.pandalocker.services.visibility=function(){this.canLock=function(a){if(!a)return!0;for(var b in a)if(a.hasOwnProperty(b)&&"object"==typeof a[b]){var c=a[b],d=this.isVisible(c);if(!d)return!1}return!0},this.isVisible=function(a){if(!a.conditions)return!0;var b=this.matchFilter(a),c=a.type||"showif";return"showif"===c?b:"hideif"===c?!b:void 0},this.matchFilter=function(a){var b=!0;for(var c in a.conditions)if(a.conditions.hasOwnProperty(c)&&"object"==typeof a.conditions[c]){var d=a.conditions[c],e=this.matchScope(d);e||(b=!1)}return b},this.matchScope=function(a){var b=!1;if(!a.conditions)return!0;for(var c in a.conditions)if(a.conditions.hasOwnProperty(c)&&"object"==typeof a.conditions[c]){var d=a.conditions[c],e=this.matchCondition(d);e&&(b=!0)}return b},this.matchCondition=function(a){var b=a.param,c=a.operator,d=a.value,e=a.type||"text",f=this.getValueProvider(b);if(!f)return console&&console.log('[visibility]: the value provider "%s" not found.'.replace("%s",b)),!0;var g=f.getValue(a);return null===g?(console&&console.log('[visibility]: the value returned from the provider "%s" equals to null.'.replace("%s",b)),!0):f.compare?f.compare(c,d,g,e):this.compare(c,d,g,e)},this.getValueProvider=function(b){var c=a.pandalocker.services.visibilityProviders[b];return c=a.pandalocker.filters.run("visibility-value-provider",[c,b])},this.compare=function(b,c,d,e){var f="date"===e&&("equals"===b||"notequal"===b);switch(c=this.castValue(c,e,f?"range":null),d=this.castValue(d,e),b){case"equals":return a.isArray(d)?a.inArray(c,d)>-1:c.range?d>c.start&&dc.start&&dd;case"greater":case"younger":return d>c;case"contains":return d.indexOf(c)>-1;case"notcontain":return-1===d.indexOf(c);case"between":return d>=c.start&&d<=c.end}return!0},this.castValue=function(b,c,d){if(null===b)return b;if(a.isArray(b)){for(var e=0;e0||(a.runHook("na"),"show-content"===a.options.locker.naMode&&a.unlock("na")))})}}}(jQuery);; !function(a){"use strict";var b={};b.init=function(b,c){var d=a.extend(!0,{},this._defaults);if(this.options=a.extend(!0,d,c),this.groupOptions=b.options,this.lockerOptions=b.locker.options,this.lang=b.lang,this.group=b,this.locker=b.locker,this.groupOptions.senderName&&(this.senderName=this.groupOptions.senderName),!this.name)throw new Error('The property "name" cannot be empty for the control.');this.options.proxy=this.options.proxy||this.groupOptions.proxy||this.lockerOptions.proxy,this.setup&&this.setup(),this.setupHooks&&this.setupHooks(),this.prepareOptions&&this.prepareOptions()},b._defaults={},b.renderControl=function(b){this.control=a(this.tag||"
").addClass("onp-sl-control").addClass("onp-sl-"+this.name).appendTo(b),this.innerWrap=a("
").addClass("onp-sl-control-inner-wrap").appendTo(this.control),this._isRendered=!0,this._hasError()&&this.showError(),this.render(this.innerWrap)},b.render=function(){throw new Error("The control should implement the method 'render'")},b.unlock=function(a,b,c){this.setState("unlocked"),this.group.unlock(a||"button",b||this.senderName||this.name,c)},b.addClassToLocker=function(a){this.group.addClassToLocker(a)},b._trackWindow=function(a,b){var c=window.open;window.open=function(d,e,f){var g=c(d,e,f);if(!d)return g;if(-1===d.indexOf(a))return g;var h=setInterval(function(){g&&g.closed===!1||(clearInterval(h),b&&b())},300);return g}},b.requestState=function(a){var b=this._getStateStorage();b.requestState(this._getStorageIdentity(),a)},b.setState=function(a,b){var c=this._getStateStorage();c.setState(this._getStorageIdentity(),a,b),this.group.setState(a,"button",this.name)},b._getStorageIdentity=function(){return"control_"+this.name},b._getStateStorage=function(){return this.locker._getStateStorage()},b._setLoadingState=function(a){this._stateSender||(this._stateSender=a,this.control.addClass("onp-sl-state-loading"),this._isLoadingState=!0)},b._removeLoadingState=function(a){this._stateSender&&this._stateSender!==a||(this._stateSender=null,this.control.removeClass("onp-sl-state-loading"),this._isLoadingState=!1)},b._isLoading=function(){return this._isLoadingState},b._setError=function(a){this._error||(this._error=a)},b._hasError=function(){return this._error?!0:!1},b.showError=function(a,b){var c=this;if(this.runHook("control-error",[c.name,c.group.name]),c.group.onControlError&&c.group.onControlError(c.name),!this._isRendered)return void this._setError(a);var b=b||this.innerWrap,a=a||this._error;if(!this.control.hasClass("onp-sl-state-error")){this.control.removeClass("onp-sl-state-loading").addClass("onp-sl-state-error");var d=this.createErrorMarkup(a).appendTo(b);d.find(".onp-sl-error-title").click(function(){return c.group.showError(c.name,a),!1})}},b.createErrorMarkup=function(){return a("")},b.showNotice=function(a,b){this.group.showNotice(a,null,b)},b.validateAgreement=function(){return this.group.validateAgreement()},b.addHook=function(a,b,c){return this.group.addHook(a,b,c)},b.runHook=function(a,b){return this.group.runHook(a,b)},b.addFilter=function(a,b,c){return this.group.addFilter(a,b,c)},b.applyFilters=function(a,b,c){return this.group.applyFilters(a,b,c)},b.requireSdk=function(b,c){var d=this,e=new a.pandalocker.deferred;if(!b)return e.resolve(),e.promise();var f=this.group.options.loadingTimeout||this.lockerOptions.locker.loadingTimeout||2e4,g=d.attemptToLoad(b,c||{},5,f);return g.done(function(){e.resolve()}),g.fail(function(c){var d=a.pandalocker.lang.errors.unableToLoadSDK.replace("{0}",b).replace("{1}",c);e.reject(d)}),e.promise()},b.attemptToLoad=function(b,c,d,e){var f=this;d||(d=5);var g=new a.pandalocker.deferred,h=a.pandalocker.sdk.connect(b,c||{},e);return h.done(function(){g.resolve()}),h.fail(function(a){console.log('Failed to load SDK script "'+b+'" due to the error "'+a+'". '+d+" attempts left."),"timeout"!==a&&"blocked"!==a&&g.reject(a),0>=d-1?g.reject(a):f.attemptToLoad(b,c,d-1,e).done(function(){g.resolve()}).fail(function(){g.reject(a)})}),g.promise()},b.verifyButton=function(){var b=this,c=new a.pandalocker.deferred,d=b.verification.timeout,e=function(){if((b.customVerifyButton&&!b.customVerifyButton()||0===b.control.find(b.verification.container).length)&&d>=0)setTimeout(function(){e()},500),d-=500;else{if(0>=d){var f=a.pandalocker.lang.errors.unableToCreateControl.replace("{0}",b.networkName);return c.reject(f)}c.resolve()}};return e(),c.promise()},b.showScreen=function(a,b){this.group.showScreen(a,b)},a.pandalocker.entity.control=b}(jQuery);; !function(a){"use strict";var b=a.pandalocker.tools.extend(a.pandalocker.entity.control);b.setup=function(){var b=this;this.options.actions=this.options.actions||[];var c=!1;for(var d in this.options.actions)"subscribe"===this.options.actions[d]&&(this.options.actions.splice(d,1),c=!0);c&&this.options.actions.push("subscribe"),this.groupOptions.actions&&(this.options.actions=a.extend(this.options.actions,this.groupOptions.actions));for(var e=0;e=b&&a(c)})},b.canLock=function(){return!0},b.renderGroup=function(b){var c=a("
");c.appendTo(b);var d=a("
");if(d.appendTo(c),c.addClass(this.isFirst?"onp-sl-first-group":this.isLast?"onp-sl-last-group":"onp-sl-middle-group"),c.addClass(this.isSingle?"onp-sl-single-group":"onp-sl-not-single-group"),c.addClass("onp-sl-group-index-"+this.options.index),this.element=c,this.innerWrap=d,this.renderSeparator(),this.options.text.header||this.options.text.message){var e=a("
").appendTo(this.innerWrap);this.options.text.header&&e.append(this.options.text.header.addClass("onp-sl-header onp-sl-strong").clone()),this.options.text.message&&e.append(this.options.text.message.addClass("onp-sl-message").clone())}this._isRendered=!0,this.render(this.innerWrap)},b.render=function(){!this.hasAgreementHandler("top")&&this.lockerOptions.agreement.checkbox&&"top"===this.lockerOptions.agreement.checkbox&&this.renderAgreementCheckbox(),this.renderControls(this.innerWrap),!this.hasAgreementHandler("bottom")&&this.lockerOptions.agreement.checkbox&&"bottom"===this.lockerOptions.agreement.checkbox&&this.renderAgreementCheckbox()},b.unlock=function(a,b,c){this.locker.unlock(a,b,c)},b.setState=function(a,b,c){this.locker.setState(a,b||"group",c||this.name)},b.renderControls=function(a){for(var b=0;b
").appendTo(b),g=a("
").appendTo(f);d="social-buttons"===this.name?e.checkbox&&e.checkbox.text||a.pandalocker.lang.misc_agreement_checkbox_alt:e.checkbox&&e.checkbox.text||a.pandalocker.lang.misc_agreement_checkbox;var h=this.locker._replaceTermLinks(d),i=(a("").html(a.pandalocker.lang.errors_no_consent).appendTo(g),a("