Fix loader for compact header mode
This commit is contained in:
parent
e0aecd9704
commit
9e246ec424
|
@ -783,10 +783,13 @@
|
|||
if (config.frameEditorId)
|
||||
params += "&frameEditorId=" + config.frameEditorId;
|
||||
|
||||
if (config.editorConfig && (config.editorConfig.mode == 'view' || config.editorConfig.customization && !!config.editorConfig.customization.compactHeader) ||
|
||||
if (config.editorConfig && config.editorConfig.mode == 'view' ||
|
||||
config.document && config.document.permissions && (config.document.permissions.edit === false && !config.document.permissions.review ))
|
||||
params += "&mode=view";
|
||||
|
||||
if (config.editorConfig && config.editorConfig.customization && !!config.editorConfig.customization.compactHeader)
|
||||
params += "&compact=true";
|
||||
|
||||
return params;
|
||||
}
|
||||
|
||||
|
|
|
@ -223,11 +223,14 @@
|
|||
|
||||
<script>
|
||||
var params = getUrlParams(),
|
||||
compact = params["compact"] == 'true',
|
||||
view = params["mode"] == 'view';
|
||||
|
||||
if (view) {
|
||||
if (compact || view) {
|
||||
document.querySelector('.brendpanel > :nth-child(2)').remove();
|
||||
document.querySelector('.brendpanel > :nth-child(1)').style.height = '32px';
|
||||
}
|
||||
if (view) {
|
||||
document.querySelector('.sktoolbar').remove();
|
||||
}
|
||||
|
||||
|
|
|
@ -209,12 +209,17 @@
|
|||
|
||||
<script>
|
||||
var params = getUrlParams(),
|
||||
compact = params["compact"] == 'true',
|
||||
view = params["mode"] == 'view';
|
||||
if (view) {
|
||||
|
||||
if (compact || view) {
|
||||
document.querySelector('.brendpanel > :nth-child(2)').remove();
|
||||
document.querySelector('.brendpanel > :nth-child(1)').style.height = '32px';
|
||||
}
|
||||
if (view) {
|
||||
document.querySelector('.sktoolbar').remove();
|
||||
}
|
||||
|
||||
if (stopLoading) {
|
||||
document.body.removeChild(document.getElementById('loading-mask'));
|
||||
} else {
|
||||
|
|
|
@ -252,11 +252,14 @@
|
|||
|
||||
<script>
|
||||
var params = getUrlParams(),
|
||||
compact = params["compact"] == 'true',
|
||||
view = params["mode"] == 'view';
|
||||
|
||||
if (view) {
|
||||
if (compact || view) {
|
||||
document.querySelector('.brendpanel > :nth-child(2)').remove();
|
||||
document.querySelector('.brendpanel > :nth-child(1)').style.height = '32px';
|
||||
}
|
||||
if (view) {
|
||||
document.querySelector('.sktoolbar').remove();
|
||||
}
|
||||
|
||||
|
|
|
@ -258,11 +258,14 @@
|
|||
|
||||
<script>
|
||||
var params = getUrlParams(),
|
||||
compact = params["compact"] == 'true',
|
||||
view = params["mode"] == 'view';
|
||||
|
||||
if (view) {
|
||||
if (compact || view) {
|
||||
document.querySelector('.brendpanel > :nth-child(2)').remove();
|
||||
document.querySelector('.brendpanel > :nth-child(1)').style.height = '32px';
|
||||
}
|
||||
if (view) {
|
||||
document.querySelector('.sktoolbar').remove();
|
||||
}
|
||||
|
||||
|
|
|
@ -224,6 +224,7 @@
|
|||
<script>
|
||||
var params = getUrlParams(),
|
||||
internal = params["internal"] == 'true',
|
||||
compact = params["compact"] == 'true',
|
||||
view = params["mode"] == 'view';
|
||||
|
||||
if (internal) {
|
||||
|
@ -231,9 +232,11 @@
|
|||
document.querySelector('.sktoolbar').remove();
|
||||
}
|
||||
|
||||
if (view) {
|
||||
if (compact || view) {
|
||||
document.querySelector('.brendpanel > :nth-child(2)').remove();
|
||||
document.querySelector('.brendpanel > :nth-child(1)').style.height = '32px';
|
||||
}
|
||||
if (view) {
|
||||
document.querySelector('.sktoolbar').remove();
|
||||
}
|
||||
|
||||
|
|
|
@ -229,6 +229,7 @@
|
|||
<script>
|
||||
var params = getUrlParams(),
|
||||
internal = params["internal"] == 'true',
|
||||
compact = params["compact"] == 'true',
|
||||
view = params["mode"] == 'view';
|
||||
|
||||
if (internal) {
|
||||
|
@ -236,9 +237,11 @@
|
|||
document.querySelector('.sktoolbar').remove();
|
||||
}
|
||||
|
||||
if (view) {
|
||||
if (compact || view) {
|
||||
document.querySelector('.brendpanel > :nth-child(2)').remove();
|
||||
document.querySelector('.brendpanel > :nth-child(1)').style.height = '32px';
|
||||
}
|
||||
if (view) {
|
||||
document.querySelector('.sktoolbar').remove();
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue