.6*n&&($(this).width($(this).width()*(n/$(this).width())),$(this).height(n),$(this).css("height",n+"px")),$(this).width()18&&(r=18);"left"==$(this).closest(".small-image-div-container").css("float")?$(this).closest(".small-image-div-container").css("padding-right",r+"px"):$(this).closest(".small-image-div-container").css("padding-left",r+"px")}$(this).height()>.75*n&&$(this).height(.75*n),null!=$(this).next()&&0==$(this).next().closest(".small-image-div").length&&0==$(this).next().closest(".page-break-before").length&&$(this).height()!=a&&$(this).css("padding-bottom","9px"),null!=$(this).prev()&&0==$(this).prev().closest(".small-image-div").length&&$(this).height()!=a&&$(this).css("padding-top","9px");var g=gMagicWidth/numVisiblePages-36-36;$(this).width()>g&&$(this).width(g),$(this).css("max-width",parseInt($(this).width())+"px"),$(this).css("max-height",parseInt($(this).height())+"px"),$(this).css("min-width",parseInt($(this).width())+"px"),$(this).css("min-height",parseInt($(this).height())+"px")}),$(".partial-page-image-div").width(parseInt(gMagicWidth/numVisiblePages)-36-36),$(".partial-page-image-div").css("max-width",parseInt(gMagicWidth/numVisiblePages)-36-36+"px"),$(".partial-page-image-div").height(parseInt(gMagicHeight/1.5)-36-36),$(".partial-page-image-div").css("max-height",parseInt(gMagicHeight/1.5)-36-36+"px"),$(".partial-page-image-div .kiss-image-smart-position").width(parseInt(gMagicWidth/numVisiblePages)-36-36),$(".partial-page-image-div .kiss-image-smart-position").height(parseInt(gMagicHeight)-36-36),$('.partial-page-image-div>div[data-kiss-image-presentation="contain"]').each(function(){if($(this).parent().width()>=parseInt(gMagicWidth/numVisiblePages)-36-36){var e=parseInt($(this).attr("data-kiss-image-dimensions-y"))/parseInt($(this).attr("data-kiss-image-dimensions-x")),t=parseInt((parseInt(gMagicWidth/numVisiblePages)-36-36)*e);$(this).parent().height(t),$(this).parent().css("max-height",t+"px"),$(this).parent().css("min-height",t+"px");var i=parseInt(gMagicWidth/numVisiblePages)-36-36;$(this).parent().width(i),$(this).parent().css("max-width",i+"px"),$(this).parent().css("min-width",i+"px")}if($(this).parent().height()>=parseInt(gMagicHeight/1.5)-36-36){e=parseInt($(this).attr("data-kiss-image-dimensions-x"))/parseInt($(this).attr("data-kiss-image-dimensions-y")),i=parseInt((parseInt(gMagicHeight/1.5)-36-36)*e);$(this).parent().width(i),$(this).parent().css("max-width",i+"px"),$(this).parent().css("min-width",i+"px");t=parseInt(gMagicHeight/1.5)-36-36;$(this).parent().height(t),$(this).parent().css("max-height",t+"px"),$(this).parent().css("min-height",t+"px")}}),$(".full-page-image-div").width(parseInt(gMagicWidth/numVisiblePages)-36-36),$(".full-page-image-div").height(parseInt(gMagicHeight)-36-36),$(".full-page-image-div .kiss-image-smart-position").width(parseInt(gMagicWidth/numVisiblePages)-36-36),$(".full-page-image-div .kiss-image-smart-position").height(parseInt(gMagicHeight)-36-36);var e=!1;for($("h1,h2,h3,h4,h5,h6").addClass("contingent-on-next-element-fitting"),$(".partial-page-image-div").addClass("page-break-before"),$(".full-page-image-div").addClass("page-break-before").addClass("page-break-after"),$("div.full-page-image-div").prev().closest("h1,h2,h3,h4,h5,h6").addClass("page-break-before");;){for(var t=0;$("div#temp")[0].scrollHeight==gMagicHeight-48-48-36-36;){var i,a=0,s=!1,n=!1,r="",g=$("div#temp").html().length,d=!1,h="";do{if(i=$("#contentBuffer>:first"),void 0===$(i)[0]||null==$(i)[0]){console.log("Done"),e=!0;break}if($(i).hasClass("page-break-before")&&d)break;a++;var o=$(i)[0].outerHTML;r+=o,1==a&&(h=o.substr(0,o.indexOf(">")+1)).indexOf(" ")>0&&(h=h.substr(0,h.indexOf(" "))+">"),d=!!$(i).hasClass("contingent-on-next-element-fitting"),$(i).hasClass("page-break-before")&&(s=!0),$(i).hasClass("page-break-after")&&(n=!0,d=!1),$("#contentBuffer>:first").remove()}while(d);if(e){$("div#temp").html().length&&promoteToNewPage({bPrepend:!1});break}if(s&&(t&&promoteToNewPage({bPrepend:!1}),s=!1,g=0),$("div#temp").append(r),t+=r.length,n){promoteToNewPage({bPrepend:!1}),n=!1,g=0;break}var l;do{if(l=!1,$("div#temp")[0].scrollHeight<=gMagicHeight-48-48-36-36)g+=r.length;else{if(g&&""!=h){for(var p="",c=0;c:last")[0].outerHTML+p,$("#temp>:last").remove();$("div#contentBuffer").prepend(p),g&&promoteToNewPage({bPrepend:!1});break}if(!(a>1)){var m=$("#temp").html(),u=[],f=m.length;do{var b=m.indexOf(">");if((f=m.substr(0,f).lastIndexOf(" "))<=b){var v=$("#temp>:first")[0].outerHTML;$("#temp>:first").remove(),u[1]=$("#temp").html(),u[0]=v,$("#temp").html(v);break}u=KISS_JS_CutUpHTML(m,f),$("#temp").html(u[0]),f--}while(f>0&&parseInt($("div#temp")[0].scrollHeight)>gMagicHeight-48-48-36-36);$("div#contentBuffer").prepend(u[1]),u[0].length&&promoteToNewPage({prepend:!1});break}p="";p=$("#temp>:last")[0].outerHTML,$("#temp>:last").remove(),$("div#contentBuffer").prepend(p),a--,l=!0}}while(l)}if(e)break}KISS_JS_TitlePage(),KISS_JS_SummaryPage(),2==numVisiblePages&&1==(1&numTotalPages)&&KISS_JS_BackPage(),$(".full-page-image-div").closest(".page-style").css("padding","0"),$(".full-page-image-div").closest(".title-page-style").css("padding","0"),$(".full-page-image-div").width(parseInt(gMagicWidth/numVisiblePages)),$(".full-page-image-div").css("max-width",parseInt(gMagicWidth/numVisiblePages)+"px"),$(".full-page-image-div").css("min-width",parseInt(gMagicWidth/numVisiblePages)+"px"),$(".full-page-image-div").height(parseInt(gMagicHeight)),$(".full-page-image-div").css("max-height",parseInt(gMagicHeight)+"px"),$(".full-page-image-div").css("min-height",parseInt(gMagicHeight)+"px"),$(".full-page-image-div .kiss-image-smart-position").width(parseInt(gMagicWidth/numVisiblePages)),$(".full-page-image-div .kiss-image-smart-position").css("max-width",parseInt(gMagicWidth/numVisiblePages)+"px"),$(".full-page-image-div .kiss-image-smart-position").css("min-width",parseInt(gMagicWidth/numVisiblePages)+"px"),$(".full-page-image-div .kiss-image-smart-position").height(parseInt(gMagicHeight)),$(".full-page-image-div .kiss-image-smart-position").css("max-height",parseInt(gMagicHeight)+"px"),$(".full-page-image-div .kiss-image-smart-position").css("min-height",parseInt(gMagicHeight)+"px"),$(".partial-page-image-div").width(parseInt(gMagicWidth/numVisiblePages)-36-36),$(".partial-page-image-div").css("max-width",parseInt(gMagicWidth/numVisiblePages)-36-36+"px"),$(".partial-page-image-div").css("min-width",parseInt(gMagicWidth/numVisiblePages)-36-36+"px"),$(".partial-page-image-div .kiss-image-smart-position").width(parseInt(gMagicWidth/numVisiblePages)-36-36),$(".page-header").width(parseInt(gMagicWidth/numVisiblePages-36-36)),$(".page-footer").width(parseInt(gMagicWidth/numVisiblePages-36-36)),$(".page-content").each(function(e){$(this).find("span.page-number").html(e+1),$(this).find("span.total-page-number").html(numTotalPages)});var w=$(".page-content"),x=0;for(c=0;cI||$(w[c]).hasClass("kiss-chapter-title-page")&&!k)&&($(w[c]).css("background","linear-gradient(135deg, rgba(255,255,255,0.67) 0%, rgba(255,255,255,1.0) 50%),url(////d2kvhj8ixnchwb.cloudfront.net/westernsydneycareers-prod-publicsettingcdn/www-backgroundtexture.jpg.17308540762bf67652e1933dd44f59c762ca1d78c4ae9f2b5e4573a85ff4c8836252cc1b13)"),$(w[c]).css("background-size",""),$(w[c]).css("background-position","top left"))}$("div#temp").remove(),$("div#contentBuffer").html(""),2==numVisiblePages?($("div.flipbook div.page-content:odd").append(''),$("div.flipbook div.page-content:even").append(''),$(".flipbook").turn({width:gMagicWidth,height:gMagicHeight,elevation:50,gradients:!0,autoCenter:!0,display:"double"})):$(".flipbook").turn({width:gMagicWidth,height:gMagicHeight,elevation:50,gradients:!0,autoCenter:!0,display:"single"}),$(".flipbook").bind("turned",function(e,t,i){KISS_JS_ImageSmartPosition(),KISS_JS_ImageCorrect("body"),KISS_JS_RescaleDevices()});parseInt(KISS_JS_ReadCookie("wkhtmltoxwidth"))>0&&$(".flipbook").turn("next")}function escapeHtml(e){var t={"&":"&","<":"<",">":">",'"':""","'":"'"};return e.replace(/[&<>"']/g,function(e){return t[e]})}function KISS_JS_GetWidthHeight(){var e=Math.max(document.documentElement.clientWidth,window.innerWidth||0),t=Math.max(document.documentElement.clientHeight,window.innerHeight||0);0==e&&0==t&&(e=parseInt(KISS_JS_ReadCookie("wkhtmltoxwidth")),t=parseInt(KISS_JS_ReadCookie("wkhtmltoxheight")),$("body").css("width",e+"px"),$("body").css("height",t+"px")),gMagicWidth=parseInt(.9*e),gMagicHeight=parseInt(.9*t)}function KISS_JS_RescaleDevices(){$(".kiss-mockup-device-wrapper").each(function(){$(this).css("transform","");var e=$(this).parent().height()/$(this).outerHeight()*.9,t=$(this).parent().width()/$(this).outerWidth()*.9;$(this).css("transform","scale("+(ePhone: 1300 190 290 (toll free within Australia) ',footerHTML+='Email: team@resourcesforcourses.com.au | ',footerHTML+='0/0 | \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t';var headerHTML='';$(window).load(function(){var e=document.documentElement;e.requestFullscreen?e.requestFullscreen():e.mozRequestFullScreen?e.mozRequestFullScreen():e.webkitRequestFullScreen&&e.webkitRequestFullScreen(),$("#kiss-phantomjs-font-prep").hide(),KISS_JS_GetWidthHeight(),KISS_JS_ConvertHTMLIntoPages(),KISS_JS_ImageSmartPosition(),KISS_JS_ImageCorrect("body"),KISS_JS_RescaleDevices(),KISS_JS_MorphModal_Init(),KISS_JS_Transform_Init();var t=null;window.onresize=function(){clearTimeout(t),t=setTimeout(function(){KISS_JS_GetWidthHeight(),KISS_JS_ConvertHTMLIntoPages(),KISS_JS_ImageSmartPosition(),KISS_JS_ImageCorrect("body"),KISS_JS_RescaleDevices()},50)}})