function createCookie(n,t,i,r,u,f){var o,e;i?(o=new Date,o.setTime(o.getTime()+i*864e5),e=o.toGMTString()):e="";cookieString=n+"="+escape(t);e&&(cookieString+="; expires="+e);r&&(cookieString+="; path="+escape(r));u&&(cookieString+="; domain="+escape(u));f&&(cookieString+="; secure");document.cookie=cookieString}function getCookie(n){var t=n+"=";return document.cookie.split(t)[1].split(";")[0]}function deleteCookie(n){createCookie(n,"",-1)}function recordPL(n){$("#linkRecordPL").prop("disabled",!0);$("#spanRecordPLMsgSuccess").hide();$("#spanRecordPLMsgError").hide();jQuery.ajax({type:"POST",url:$("#hdnRecordPLUrl").val(),dataType:"text",data:"itemId="+n,success:function(n){recordPLStatus(n)},error:function(){recordPLStatus(!1)}})}function recordPLStatus(n){var t=$.parseJSON(n),i=t.Status;$("#linkRecordPL").hide();i?($("#spanRecordPLMsgError").hide(),$("#spanRecordPLMsgSuccess .ce-success").text(t.Message),$("#spanRecordPLMsgSuccess").show()):($("#linkRecordPL").show(),$("#linkRecordPL").prop("disabled",!1),$("#spanRecordPLMsgError .ce-error").text(t.Message),$("#spanRecordPLMsgError").show(),$("#spanRecordPLMsgSuccess").hide())}function UpdateProtectedAssetMessages(){digitalData.user&&$(".content-asset__pill.content-asset__pill--locked")&&$(".content-asset__pill.content-asset__pill--locked").hide()}(function(n){typeof define=="function"&&define.amd?define(["jquery"],n):typeof exports=="object"?module.exports=n(require("jquery")):n(jQuery)})(function(n){function i(n){return t.raw?n:encodeURIComponent(n)}function f(n){return t.raw?n:decodeURIComponent(n)}function e(n){return i(t.json?JSON.stringify(n):String(n))}function o(n){n.indexOf('"')===0&&(n=n.slice(1,-1).replace(/\\"/g,'"').replace(/\\\\/g,"\\"));try{return n=decodeURIComponent(n.replace(u," ")),t.json?JSON.parse(n):n}catch(i){}}function r(i,r){var u=t.raw?i:o(i);return n.isFunction(r)?r(u):u}var u=/\+/g,t=n.cookie=function(u,o,s){var v,c;if(arguments.length>1&&!n.isFunction(o))return s=n.extend({},t.defaults,s),typeof s.expires=="number"&&(v=s.expires,c=s.expires=new Date,c.setMilliseconds(c.getMilliseconds()+v*864e5)),document.cookie=[i(u),"=",e(o),s.expires?"; expires="+s.expires.toUTCString():"",s.path?"; path="+s.path:"",s.domain?"; domain="+s.domain:"",s.secure?"; secure":""].join("");for(var l=u?undefined:{},y=document.cookie?document.cookie.split("; "):[],a=0,b=y.length;a<b;a++){var p=y[a].split("="),w=f(p.shift()),h=p.join("=");if(u===w){l=r(h,o);break}u||(h=r(h))===undefined||(l[w]=h)}return l};t.defaults={};n.removeCookie=function(t,i){return n.cookie(t,"",n.extend({},i,{expires:-1})),!n.cookie(t)}});$(document).ready(function(){if(!(window.location.href.indexOf("sc_mode=edit")>0)){var n=document.createElement("script");n.type="text/javascript";n.src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-MML-AM_CHTML";document.getElementsByTagName("body")[0].appendChild(n)}UpdateProtectedAssetMessages()});$(".chat-card .chat-link").on("click",function(){return window.open(this.href,"Chat","width = 470,height = 560"),!1});$("div[id^='globalAlert_'] a.close,div[id^='localAlert_'] a.close").on("click",function(n){n.preventDefault();var t=$(this).attr("id");jQuery.cookie("Alerts")==undefined?createCookie("Alerts",t,"","/","",1):createCookie("Alerts",jQuery.cookie("Alerts")+"|"+t,"","/","",1);$("#alert"+t).hide()});var delimiter="|";$("#hdnPLRecordStatus").length>0&&recordPLStatus(decodeURI($("#hdnPLRecordStatus").val()))