From c7085ad297cdb0a014c944ea729d807df7c7b41c Mon Sep 17 00:00:00 2001 From: Vincent Vanwaelscappel Date: Tue, 25 Feb 2025 15:21:56 +0100 Subject: [PATCH] wip #7340 @1 --- resources/linkeditor-stable/js/linkeditor.loader.js | 3 ++- resources/linkeditor-stable/style/style.sass | 8 ++++++++ .../views/fluidbook_publication/link_editor.blade.php | 1 + 3 files changed, 11 insertions(+), 1 deletion(-) diff --git a/resources/linkeditor-stable/js/linkeditor.loader.js b/resources/linkeditor-stable/js/linkeditor.loader.js index 91c417148..20c851f17 100644 --- a/resources/linkeditor-stable/js/linkeditor.loader.js +++ b/resources/linkeditor-stable/js/linkeditor.loader.js @@ -71,7 +71,8 @@ LinkeditorLoader.prototype = { _loadPage: function (p, container) { var imageFormat = FLUIDBOOK_DATA.settings.imageFormat ?? 'jpg'; - var c = '
'; + var transparent = !!FLUIDBOOK_DATA.settings.transparentPage; + var c = '
'; if (this.linkeditor.utils.isSpecialPage(p)) { let data = this.linkeditor.utils.getSpecialPageAssetData(p); c += ''; diff --git a/resources/linkeditor-stable/style/style.sass b/resources/linkeditor-stable/style/style.sass index d43720f4e..48a0d47a5 100644 --- a/resources/linkeditor-stable/style/style.sass +++ b/resources/linkeditor-stable/style/style.sass @@ -145,6 +145,14 @@ body, #linkeditor, html width: 100% height: 100% + &.transparent + background-color: transparent + background-repeat: repeat + background-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyMCIgaGVpZ2h0PSIyMCI+PGRlZnM+PHBhdHRlcm4gaWQ9ImEiIHdpZHRoPSIyMCIgaGVpZ2h0PSIyMCIgcGF0dGVyblVuaXRzPSJ1c2VyU3BhY2VPblVzZSI+PHBhdGggZmlsbD0iI2ZmZiIgZD0iTTAgMGgxMHYxMEgweiIvPjxwYXRoIGZpbGw9IiNkZGQiIGQ9Ik0xMCAwaDEwdjEwSDEweiIvPjxwYXRoIGZpbGw9IiNmZmYiIGQ9Ik0xMCAxMGgxMHYxMEgxMHoiLz48cGF0aCBmaWxsPSIjZGRkIiBkPSJNMCAxMGgxMHYxMEgweiIvPjwvcGF0dGVybj48L2RlZnM+PHJlY3QgZmlsbD0idXJsKCNhKSIgd2lkdGg9IjEwMCUiIGhlaWdodD0iMTAwJSIvPjwvc3ZnPg==") + //@include dark-theme + // background-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyMCIgaGVpZ2h0PSIyMCI+PGRlZnM+PHBhdHRlcm4gaWQ9ImEiIHdpZHRoPSIyMCIgaGVpZ2h0PSIyMCIgcGF0dGVyblVuaXRzPSJ1c2VyU3BhY2VPblVzZSI+PHBhdGggZmlsbD0iIzY2NiIgZD0iTTAgMGgxMHYxMEgweiIvPjxwYXRoIGZpbGw9IiM5OTkiIGQ9Ik0xMCAwaDEwdjEwSDEweiIvPjxwYXRoIGZpbGw9IiM2NjYiIGQ9Ik0xMCAxMGgxMHYxMEgxMHoiLz48cGF0aCBmaWxsPSIjOTk5IiBkPSJNMCAxMGgxMHYxMEgweiIvPjwvcGF0dGVybj48L2RlZnM+PHJlY3QgZmlsbD0idXJsKCNhKSIgd2lkdGg9IjEwMCUiIGhlaWdodD0iMTAwJSIvPjwvc3ZnPg==") + + img display: block position: absolute diff --git a/resources/views/fluidbook_publication/link_editor.blade.php b/resources/views/fluidbook_publication/link_editor.blade.php index 2baacbcb5..452f98052 100644 --- a/resources/views/fluidbook_publication/link_editor.blade.php +++ b/resources/views/fluidbook_publication/link_editor.blade.php @@ -14,6 +14,7 @@ $fbdata['settings']['width']=$fbdata['width']=$fluidbook->getPageWidth(); $fbdata['settings']['height']=$fbdata['height']=$fluidbook->getPageHeight(); $fbdata['settings']['pages']=$fbdata['pages']=$fluidbook->getPagesNumber(); + $fbdata['settings']['imageFormat']=$fluidbook->getImageFormat(); $fbdata['page_dimensions']=[]; $mh = 0; for($i=1;$i<=$fbdata['pages'];$i++){ -- 2.39.5