From: Stephen Cameron Date: Wed, 31 Jan 2018 11:19:59 +0000 (+0100) Subject: Allow local/relative URLs for logo link. WIP #1852 @0.5 X-Git-Url: http://git.cubedesigners.com/?a=commitdiff_plain;h=6a1adcc2481f894ad4cac2ef3c1ec2d81605f7c7;p=fluidbook-html5.git Allow local/relative URLs for logo link. WIP #1852 @0.5 --- diff --git a/js/libs/fluidbook/fluidbook.js b/js/libs/fluidbook/fluidbook.js index b6419e95..686daa37 100644 --- a/js/libs/fluidbook/fluidbook.js +++ b/js/libs/fluidbook/fluidbook.js @@ -331,6 +331,7 @@ Fluidbook.prototype = { if (page != $this.currentPage) { $($this).trigger('changePage', [page]); } + this.landingpage.hide(); this.menu.closeView(function () { if (page != $this.currentPage) { $this.pageTransition(page); @@ -782,7 +783,12 @@ Fluidbook.prototype = { if (this.datas.url_link == '' || this.datas.url_link == 'http://') { return; } - this.wopen(this.datas.url_link, '_blank'); + + if (this.datas.url_link.indexOf('#') === 0) { + window.location.hash = this.datas.url_link; + } else { + this.wopen(this.datas.url_link, '_blank'); + } }, addWaiter: function (reset) {