/* Source and licensing information for the line(s) below can be found at https://en-hum.huji.ac.il/profiles/openscholar/modules/contrib/colorbox/js/colorbox_inline.js. */
(function($){Drupal.behaviors.initColorboxInline={attach:function(context,settings){if(!$.isFunction($.colorbox)||typeof settings.colorbox==='undefined')return;if(settings.colorbox.mobiledetect&&window.matchMedia){var mq=window.matchMedia("(max-device-width: "+settings.colorbox.mobiledevicewidth+")");if(mq.matches)return};$.urlParam=function(name,url){if(name=='fragment'){var results=new RegExp('(#[^&#]*)').exec(url)}else var results=new RegExp('[\\?&]'+name+'=([^&#]*)').exec(url);if(!results)return'';return results[1]||''};$('.colorbox-inline',context).once('init-colorbox-inline').colorbox({transition:settings.colorbox.transition,speed:settings.colorbox.speed,opacity:settings.colorbox.opacity,slideshow:settings.colorbox.slideshow,slideshowAuto:settings.colorbox.slideshowAuto,slideshowSpeed:settings.colorbox.slideshowSpeed,slideshowStart:settings.colorbox.slideshowStart,slideshowStop:settings.colorbox.slideshowStop,current:settings.colorbox.current,previous:settings.colorbox.previous,next:settings.colorbox.next,close:settings.colorbox.close,overlayClose:settings.colorbox.overlayClose,maxWidth:settings.colorbox.maxWidth,maxHeight:settings.colorbox.maxHeight,innerWidth:function(){return $.urlParam('width',$(this).attr('href'))},innerHeight:function(){return $.urlParam('height',$(this).attr('href'))},title:function(){return Drupal.colorbox.sanitizeMarkup(decodeURIComponent($.urlParam('title',$(this).attr('href'))))},iframe:function(){return $.urlParam('iframe',$(this).attr('href'))},inline:function(){return $.urlParam('inline',$(this).attr('href'))},href:function(){return $.urlParam('fragment',$(this).attr('href'))}})}}})(jQuery);;
/* Source and licensing information for the above line(s) can be found at https://en-hum.huji.ac.il/profiles/openscholar/modules/contrib/colorbox/js/colorbox_inline.js. */;/*})'"*/
/*!
 * jQuery Form Plugin
 * version: 2.52 (07-DEC-2010)
 * @requires jQuery v1.3.2 or later
 *
 * Examples and documentation at: http://malsup.com/jquery/form/
 * Dual licensed under the MIT and GPL licenses:
 *   http://www.opensource.org/licenses/mit-license.php
 *   http://www.gnu.org/licenses/gpl.html
 */
!function(e){function t(){if(e.fn.ajaxSubmit.debug){var t="[jquery.form] "+Array.prototype.join.call(arguments,"");window.console&&window.console.log?window.console.log(t):window.opera&&window.opera.postError&&window.opera.postError(t)}}$.httpData;e.fn.ajaxSubmit=function(a){function r(){function r(){var t=u.attr("target"),a=u.attr("action");i.setAttribute("target",s),"POST"!=i.getAttribute("method")&&i.setAttribute("method","POST"),i.getAttribute("action")!=o.url&&i.setAttribute("action",o.url),o.skipEncodingOverride||u.attr({encoding:"multipart/form-data",enctype:"multipart/form-data"}),o.timeout&&setTimeout(function(){h=!0,n()},o.timeout);var r=[];try{if(o.extraData)for(var l in o.extraData)r.push(e('<input type="hidden" name="'+l+'" value="'+o.extraData[l]+'" />').appendTo(i)[0]);c.appendTo("body"),c.data("form-plugin-onload",n),i.submit()}finally{i.setAttribute("action",a),t?i.setAttribute("target",t):u.removeAttr("target"),e(r).remove()}}function n(){if(!p){c.removeData("form-plugin-onload");var a=!0;try{if(h)throw"timeout";x=f.contentWindow?f.contentWindow.document:f.contentDocument?f.contentDocument:f.document;var r="xml"==o.dataType||x.XMLDocument||e.isXMLDoc(x);if(t("isXml="+r),!r&&window.opera&&(null==x.body||""==x.body.innerHTML)&&--y)return t("requeing onLoad callback, DOM not available"),void setTimeout(n,250);p=!0,m.responseText=x.documentElement?x.documentElement.innerHTML:null,m.responseXML=x.XMLDocument?x.XMLDocument:x,m.getResponseHeader=function(e){return{"content-type":o.dataType}[e]};var i=/(json|script)/.test(o.dataType);if(i||o.textarea){var s=x.getElementsByTagName("textarea")[0];if(s)m.responseText=s.value;else if(i){var l=x.getElementsByTagName("pre")[0],u=x.getElementsByTagName("body")[0];l?m.responseText=l.textContent:u&&(m.responseText=u.innerHTML)}}else"xml"!=o.dataType||m.responseXML||null==m.responseText||(m.responseXML=function(e,t){window.ActiveXObject?((t=new ActiveXObject("Microsoft.XMLDOM")).async="false",t.loadXML(e)):t=(new DOMParser).parseFromString(e,"text/xml");return t&&t.documentElement&&"parsererror"!=t.documentElement.tagName?t:null}(m.responseText));b=e.httpData(m,o.dataType)}catch(r){t("error caught:",r),a=!1,m.error=r,e.handleError(o,m,"error",r)}m.aborted&&(t("upload aborted"),a=!1),a&&(o.success.call(o.context,b,"success",m),d&&e.event.trigger("ajaxSuccess",[m,o])),d&&e.event.trigger("ajaxComplete",[m,o]),d&&!--e.active&&e.event.trigger("ajaxStop"),o.complete&&o.complete.call(o.context,m,a?"success":"error"),setTimeout(function(){c.removeData("form-plugin-onload"),c.remove(),m.responseXML=null},100)}}var i=u[0];if(e(":input[name=submit],:input[id=submit]",i).length)alert('Error: Form elements must not have name or id of "submit".');else{var o=e.extend(!0,{},e.ajaxSettings,a);o.context=o.context||o;var s="jqFormIO"+(new Date).getTime(),l="_"+s;window[l]=function(){var e=c.data("form-plugin-onload");if(e){e(),window[l]=void 0;try{delete window[l]}catch(e){}}};var c=e('<iframe id="'+s+'" name="'+s+'" src="'+o.iframeSrc+'" onload="window[\'_\'+this.id]()" />'),f=c[0];c.css({position:"absolute",top:"-1000px",left:"-1000px"});var m={aborted:0,responseText:null,responseXML:null,status:0,statusText:"n/a",getAllResponseHeaders:function(){},getResponseHeader:function(){},setRequestHeader:function(){},abort:function(){this.aborted=1,c.attr("src",o.iframeSrc)}},d=o.global;if(d&&!e.active++&&e.event.trigger("ajaxStart"),d&&e.event.trigger("ajaxSend",[m,o]),o.beforeSend&&!1===o.beforeSend.call(o.context,m,o))o.global&&e.active--;else if(!m.aborted){var p=!1,h=0,v=i.clk;if(v){var g=v.name;g&&!v.disabled&&(o.extraData=o.extraData||{},o.extraData[g]=v.value,"image"==v.type&&(o.extraData[g+".x"]=i.clk_x,o.extraData[g+".y"]=i.clk_y))}o.forceSync?r():setTimeout(r,10);var b,x,y=50}}}if(!this.length)return t("ajaxSubmit: skipping submit process - no element selected"),this;"function"==typeof a&&(a={success:a});var n=this.attr("action");if((n="string"==typeof n?e.trim(n):"")&&(n=(n.match(/^([^#]+)/)||[])[1]),n=n||window.location.href||"",a=e.extend(!0,{url:n,type:this.attr("method")||"GET",iframeSrc:/^https/i.test(window.location.href||"")?"javascript:false":"about:blank"},a),n={},this.trigger("form-pre-serialize",[this,a,n]),n.veto)return t("ajaxSubmit: submit vetoed via form-pre-serialize trigger"),this;if(a.beforeSerialize&&!1===a.beforeSerialize(this,a))return t("ajaxSubmit: submit aborted via beforeSerialize callback"),this;var i,o,s=this.formToArray(a.semantic);if(a.data)for(i in a.extraData=a.data,a.data)if(a.data[i]instanceof Array)for(var l in a.data[i])s.push({name:i,value:a.data[i][l]});else o=a.data[i],o=e.isFunction(o)?o():o,s.push({name:i,value:o});if(a.beforeSubmit&&!1===a.beforeSubmit(s,this,a))return t("ajaxSubmit: submit aborted via beforeSubmit callback"),this;if(this.trigger("form-submit-validate",[s,this,a,n]),n.veto)return t("ajaxSubmit: submit vetoed via form-submit-validate trigger"),this;i=e.param(s),"GET"==a.type.toUpperCase()?(a.url+=(a.url.indexOf("?")>=0?"&":"?")+i,a.data=null):a.data=i;var u=this,c=[];if(a.resetForm&&c.push(function(){u.resetForm()}),a.clearForm&&c.push(function(){u.clearForm()}),!a.dataType&&a.target){var f=a.success||function(){};c.push(function(t){var r=a.replaceTarget?"replaceWith":"html";e(a.target)[r](t).each(f,arguments)})}else a.success&&c.push(a.success);return a.success=function(e,t,r){for(var n=a.context||a,i=0,o=c.length;i<o;i++)c[i].apply(n,[e,t,r||u,u])},i=e("input:file",this).length>0,l="multipart/form-data"==u.attr("enctype")||"multipart/form-data"==u.attr("encoding"),!1!==a.iframe&&(i||a.iframe||l)?a.closeKeepAlive?e.get(a.closeKeepAlive,r):r():e.ajax(a),this.trigger("form-submit-notify",[this,a]),this},e.fn.ajaxForm=function(a){if(0===this.length){var r={s:this.selector,c:this.context};return!e.isReady&&r.s?(t("DOM not ready, queuing ajaxForm"),e(function(){e(r.s,r.c).ajaxForm(a)}),this):(t("terminating; zero elements found by selector"+(e.isReady?"":" (DOM not ready)")),this)}return this.ajaxFormUnbind().bind("submit.form-plugin",function(t){t.isDefaultPrevented()||(t.preventDefault(),e(this).ajaxSubmit(a))}).bind("click.form-plugin",function(t){var a=t.target,r=e(a);if(!r.is(":submit,input:image")){if(0==(a=r.closest(":submit")).length)return;a=a[0]}var n=this;n.clk=a,"image"==a.type&&(null!=t.offsetX?(n.clk_x=t.offsetX,n.clk_y=t.offsetY):"function"==typeof e.fn.offset?(r=r.offset(),n.clk_x=t.pageX-r.left,n.clk_y=t.pageY-r.top):(n.clk_x=t.pageX-a.offsetLeft,n.clk_y=t.pageY-a.offsetTop)),setTimeout(function(){n.clk=n.clk_x=n.clk_y=null},100)})},e.fn.ajaxFormUnbind=function(){return this.unbind("submit.form-plugin click.form-plugin")},e.fn.formToArray=function(t){var a=[];if(0===this.length)return a;var r,n,i,o,s,l,u=this[0],c=t?u.getElementsByTagName("*"):u.elements;if(!c)return a;for(r=0,s=c.length;r<s;r++)if(i=(n=c[r]).name)if(t&&u.clk&&"image"==n.type)n.disabled||u.clk!=n||(a.push({name:i,value:e(n).val()}),a.push({name:i+".x",value:u.clk_x},{name:i+".y",value:u.clk_y}));else if((o=e.fieldValue(n,!0))&&o.constructor==Array)for(n=0,l=o.length;n<l;n++)a.push({name:i,value:o[n]});else null!=o&&a.push({name:i,value:o});return!t&&u.clk&&(i=(c=(t=e(u.clk))[0]).name)&&!c.disabled&&"image"==c.type&&(a.push({name:i,value:t.val()}),a.push({name:i+".x",value:u.clk_x},{name:i+".y",value:u.clk_y})),a},e.fn.formSerialize=function(t){return e.param(this.formToArray(t))},e.fn.fieldSerialize=function(t){var a=[];return this.each(function(){var r=this.name;if(r){var n=e.fieldValue(this,t);if(n&&n.constructor==Array)for(var i=0,o=n.length;i<o;i++)a.push({name:r,value:n[i]});else null!=n&&a.push({name:this.name,value:n})}}),e.param(a)},e.fn.fieldValue=function(t){for(var a=[],r=0,n=this.length;r<n;r++){var i=e.fieldValue(this[r],t);null==i||i.constructor==Array&&!i.length||(i.constructor==Array?e.merge(a,i):a.push(i))}return a},e.fieldValue=function(t,a){var r=t.name,n=t.type,i=t.tagName.toLowerCase();if(void 0===a&&(a=!0),a&&(!r||t.disabled||"reset"==n||"button"==n||("checkbox"==n||"radio"==n)&&!t.checked||("submit"==n||"image"==n)&&t.form&&t.form.clk!=t||"select"==i&&-1==t.selectedIndex))return null;if("select"==i){var o=t.selectedIndex;if(o<0)return null;r=[],i=t.options;var s=(n="select-one"==n)?o+1:i.length;for(o=n?o:0;o<s;o++){var l=i[o];if(l.selected){var u=l.value;if(u||(u=l.attributes&&l.attributes.value&&!l.attributes.value.specified?l.text:l.value),n)return u;r.push(u)}}return r}return e(t).val()},e.fn.clearForm=function(){return this.each(function(){e("input,select,textarea",this).clearFields()})},e.fn.clearFields=e.fn.clearInputs=function(){return this.each(function(){var e=this.type,t=this.tagName.toLowerCase();"text"==e||"password"==e||"textarea"==t?this.value="":"checkbox"==e||"radio"==e?this.checked=!1:"select"==t&&(this.selectedIndex=-1)})},e.fn.resetForm=function(){return this.each(function(){("function"==typeof this.reset||"object"==typeof this.reset&&!this.reset.nodeType)&&this.reset()})},e.fn.enable=function(e){return void 0===e&&(e=!0),this.each(function(){this.disabled=!e})},e.fn.selected=function(t){return void 0===t&&(t=!0),this.each(function(){var a=this.type;"checkbox"==a||"radio"==a?this.checked=t:"option"==this.tagName.toLowerCase()&&(a=e(this).parent("select"),t&&a[0]&&"select-one"==a[0].type&&a.find("option").selected(!1),this.selected=t)})}}(jQuery);
;/*})'"*/;/*})'"*/
/* Source and licensing information for the line(s) below can be found at https://en-hum.huji.ac.il/profiles/openscholar/themes/contrib/bootstrap/js/misc/_progress.js. */
(function($){Drupal.progressBar=function(id,updateCallback,method,errorCallback){var pb=this;this.id=id;this.method=method||'GET';this.updateCallback=updateCallback;this.errorCallback=errorCallback;this.element=$('<div class="progress-wrapper" aria-live="polite"></div>');this.element.html('<div id ="'+id+'" class="progress progress-striped active"><div class="progress-bar" role="progressbar" aria-valuemin="0" aria-valuemax="100" aria-valuenow="0"><div class="percentage sr-only"></div></div></div></div><div class="percentage pull-right"></div><div class="message">&nbsp;</div>')};Drupal.progressBar.prototype.setProgress=function(percentage,message){if(percentage>=0&&percentage<=100){$('div.progress-bar',this.element).css('width',percentage+'%');$('div.progress-bar',this.element).attr('aria-valuenow',percentage);$('div.percentage',this.element).html(percentage+'%')};$('div.message',this.element).html(message);if(this.updateCallback)this.updateCallback(percentage,message,this)};Drupal.progressBar.prototype.startMonitoring=function(uri,delay){this.delay=delay;this.uri=uri;this.sendPing()};Drupal.progressBar.prototype.stopMonitoring=function(){clearTimeout(this.timer);this.uri=null};Drupal.progressBar.prototype.sendPing=function(){if(this.timer)clearTimeout(this.timer);if(this.uri){var pb=this;$.ajax({type:this.method,url:this.uri,data:'',dataType:'json',success:function(progress){if(progress.status==0){pb.displayError(progress.data);return};pb.setProgress(progress.percentage,progress.message);pb.timer=setTimeout(function(){pb.sendPing()},pb.delay)},error:function(xmlhttp){pb.displayError(Drupal.ajaxError(xmlhttp,pb.uri))}})}};Drupal.progressBar.prototype.displayError=function(string){var error=$('<div class="alert alert-block alert-error"><a class="close" data-dismiss="alert" href="#">&times;</a><h4>Error message</h4></div>').append(string);$(this.element).before(error).hide();if(this.errorCallback)this.errorCallback(this)}})(jQuery);;
/* Source and licensing information for the above line(s) can be found at https://en-hum.huji.ac.il/profiles/openscholar/themes/contrib/bootstrap/js/misc/_progress.js. */;/*})'"*/
