{"version":3,"sources":["logicjs.js","logicjs.cookiePolicy.js"],"names":["logicjs","isTouchDevice","window","navigator","maxTouchPoints","browserKit","styles","getComputedStyle","document","documentElement","pre","Array","prototype","slice","call","join","match","OLink","dom","RegExp","lowercase","css","js","toUpperCase","substr","setCookie","cname","cvalue","exdays","d","Date","expires","setTime","getTime","toUTCString","cookie","getCookie","name","ca","split","i","length","c","charAt","substring","indexOf","addEventListener","getElementById","onclick","date","style","display"],"mappings":"AAKA,IAAAA,SAAAA,QAAA,KAAA,IAAAA,QAAA,GAMAA,SAAAC,cAAA,WACA,MAAA,iBAAAC,QACAC,UAAAC,cACA,EAMAJ,QAAAK,WAAA,WACA,IAAAC,EAAAJ,OAAAK,iBAAAC,SAAAC,gBAAA,EAAA,EACAC,GAAAC,MAAAC,UAAAC,MACAC,KAAAR,CAAA,EACAS,KAAA,EAAA,EACAC,MAAA,mBAAA,GAAA,KAAAV,EAAAW,OAAA,CAAA,GAAA,MACA,GAEA,MAAA,CACAC,IAFA,kBAAAF,MAAA,IAAAG,OAAA,IAAAT,EAAA,IAAA,GAAA,CAAA,EAAA,GAGAU,UAAAV,EACAW,IAAA,IAAAX,EAAA,IACAY,GAAAZ,EAAA,GAAAa,YAAA,EAAAb,EAAAc,OAAA,CAAA,CACA,CACA,EAOAxB,QAAAyB,UAAA,SAAAC,EAAAC,EAAAC,GACA,IAAAC,EAAA,IAAAC,KAEAC,GADAF,EAAAG,QAAAH,EAAAI,QAAA,EAAA,GAAAL,EAAA,GAAA,GAAA,GAAA,EACA,WAAAC,EAAAK,YAAA,GACA1B,SAAA2B,OAAAT,EAAA,IAAAC,EAAA,IAAAI,EAAA,SACA,EAEA/B,QAAAoC,UAAA,SAAAV,GAGA,IAFA,IAAAW,EAAAX,EAAA,IACAY,EAAA9B,SAAA2B,OAAAI,MAAA,GAAA,EACAC,EAAA,EAAAA,EAAAF,EAAAG,OAAAD,CAAA,GAAA,CAEA,IADA,IAAAE,EAAAJ,EAAAE,GACA,KAAAE,EAAAC,OAAA,CAAA,GACAD,EAAAA,EAAAE,UAAA,CAAA,EAEA,GAAA,GAAAF,EAAAG,QAAAR,CAAA,EACA,OAAAK,EAAAE,UAAAP,EAAAI,OAAAC,EAAAD,MAAA,CAEA,CACA,MAAA,EACA,ECjDAjC,SAAAsC,iBAAA,mBAAA,WAEA,OAAAtC,SAAAuC,eAAA,uBAAA,IACAvC,SAAAuC,eAAA,uBAAA,EAAAC,QAAA,WACA,IAAAC,EAAA,IAAAnB,KACAmB,EAAAjB,QAAAiB,EAAAhB,QAAA,EAAA,MAAA,EACAzB,SAAA2B,OAAA,qDAAAc,EAAAf,YAAA,EAAA,6BAEA1B,SAAAuC,eAAA,cAAA,EAAAG,MAAAC,QAAA,OACA,OAAA3C,SAAAuC,eAAA,mBAAA,IAAAvC,SAAAuC,eAAA,mBAAA,EAAAG,MAAAC,QAAA,OACA,GAGA,OAAA3C,SAAAuC,eAAA,qBAAA,IACAvC,SAAAuC,eAAA,qBAAA,EAAAC,QAAA,WACAxC,SAAAuC,eAAA,cAAA,EAAAG,MAAAC,QAAA,OACA,OAAA3C,SAAAuC,eAAA,mBAAA,IAAAvC,SAAAuC,eAAA,mBAAA,EAAAG,MAAAC,QAAA,OACA,EAEA,CAAA","file":"logic.min.js","sourcesContent":["/*** Welcome to logicjs ***\r\n As this is the only required file, keep it clean by only including neccessary functions.\r\n Create a new file for new features e.g logicjs.exampleFeature = function(){}. From here create your prototype functions.\r\n*/\r\n\r\nif (typeof logicjs === \"undefined\") var logicjs = {};\r\n\r\n/*** Touch screen device check ***\r\n returns true if is touchscreen device\r\n*/\r\n\r\nlogicjs.isTouchDevice = function () {\r\n return 'ontouchstart' in window // works on most browsers \r\n || navigator.maxTouchPoints; // works on IE10/11 and Surface\r\n};\r\n\r\n/*** Browser Check ***\r\n Returns browser associated values (eg -webkit-)\r\n*/\r\n\r\nlogicjs.browserKit = function () {\r\n var styles = window.getComputedStyle(document.documentElement, ''),\r\n pre = (Array.prototype.slice\r\n .call(styles)\r\n .join('')\r\n .match(/-(moz|webkit|ms)-/) || (styles.OLink === '' && ['', 'o'])\r\n )[1],\r\n dom = ('WebKit|Moz|MS|O').match(new RegExp('(' + pre + ')', 'i'))[1];\r\n return {\r\n dom: dom,\r\n lowercase: pre,\r\n css: '-' + pre + '-',\r\n js: pre[0].toUpperCase() + pre.substr(1)\r\n };\r\n};\r\n\r\n/*** Cookie script ***\r\n set cookie - sets cookie values passed in: \"cookie-name\" : string, \"cookie value\" : string, 500 : number\r\n get cookie - returns cookie value\r\n*/\r\n\r\nlogicjs.setCookie = function (cname, cvalue, exdays) {\r\n var d = new Date();\r\n d.setTime(d.getTime() + (exdays * 24 * 60 * 60 * 1000));\r\n var expires = \"expires=\" + d.toUTCString();\r\n document.cookie = cname + \"=\" + cvalue + \";\" + expires + \";path=/\";\r\n}\r\n\r\nlogicjs.getCookie = function (cname) {\r\n var name = cname + \"=\",\r\n ca = document.cookie.split(';');\r\n for (var i = 0; i < ca.length; i++) {\r\n var c = ca[i];\r\n while (c.charAt(0) == ' ') {\r\n c = c.substring(1);\r\n }\r\n if (c.indexOf(name) == 0) {\r\n return c.substring(name.length, c.length);\r\n }\r\n }\r\n return \"\";\r\n}\r\n\r\n\r\n","/*\r\n cookie policy\r\n Version:2\r\n Dependencies: jQuery\r\n \r\n SUMMARY:\r\n\r\n Controls cookie policy display setting and removing cookies. Currently built to work with RocktimeCore.config setting\r\n EnableNewStyleCookiePolicyVersionNo = 3. This is the default so no settings need to be set in the initialise example below.\r\n\r\n*/\r\n\r\ndocument.addEventListener(\"DOMContentLoaded\", function () {\r\n\r\n if (document.getElementById(\"CookiePolicyAcceptAll\") !== null) {\r\n document.getElementById(\"CookiePolicyAcceptAll\").onclick = function () {\r\n var date = new Date();\r\n date.setTime(date.getTime() + (90 * 24 * 60 * 60 * 1000));\r\n document.cookie = \"rtCookiePrivacySetting=AcceptedTypes=ALL; expires=\" + date.toUTCString() + \"; SameSite=Strict; path=/;\";\r\n\r\n document.getElementById(\"CookiePolicy\").style.display = 'none';\r\n if (document.getElementById(\"CookiePolicyModal\") !== null) { document.getElementById(\"CookiePolicyModal\").style.display = 'none'; }\r\n };\r\n }\r\n\r\n if (document.getElementById(\"CookieControlCentre\") !== null) {\r\n document.getElementById(\"CookieControlCentre\").onclick = function () {\r\n document.getElementById(\"CookiePolicy\").style.display = 'none';\r\n if (document.getElementById(\"CookiePolicyModal\") !== null) { document.getElementById(\"CookiePolicyModal\").style.display = 'none'; }\r\n };\r\n }\r\n});\r\n"]}