Use the whole viewport. Ref #19

pull/1/head
Victor Dubiniuk 11 years ago
parent de08e8ced6
commit bce4ff41b9

@ -5,7 +5,7 @@
.documentslist { padding:5px; } .documentslist { padding:5px; }
.documentslist .add-document { .documentslist .add-document{
display: inline-block; display: inline-block;
height: 200px; height: 200px;
width: 200px; width: 200px;
@ -16,10 +16,10 @@
display: inline-block; display: inline-block;
position: relative; position: relative;
height: 200px; height: 200px;
width: 98px; width: 200px;
background-repeat: no-repeat; background-repeat: no-repeat;
background-size: 64px; background-size: 64px;
background-position: 18px; background-position: 50% 68px;
} }
.add-document .add { .add-document .add {
background-image: url('%webroot%/core/img/actions/add.svg'); background-image: url('%webroot%/core/img/actions/add.svg');
@ -66,16 +66,18 @@
text-align: center; text-align: center;
} }
#odf_close{ #odf-toolbar{
float:left; position: absolute;
width: 100%;
z-index: 500;
} }
#odf_invite{ #odf-close{
float:right; float:left;
} }
#editor-content #mainContainer{ #odf-invite{
background-color: transparent; float:right;
} }
#mainContainer #collaboration{ #mainContainer #collaboration{
@ -99,6 +101,7 @@
#mainContainer{ #mainContainer{
position:absolute; position:absolute;
z-index:500;
} }
#documents-overlay, #documents-overlay-below{ #documents-overlay, #documents-overlay-below{
@ -107,20 +110,20 @@
left: 0; left: 0;
width: 100%; width: 100%;
height: 100%; height: 100%;
filter:alpha(opacity=50); filter:alpha(opacity=30);
opacity: 0.5; opacity: 0.3;
z-index: 1000; z-index: 1000;
background: #000 url('%webroot%/core/img/loading-dark.gif') 50% 50% no-repeat; background: #000 url('%webroot%/core/img/loading-dark.gif') 50% 50% no-repeat;
} }
#documents-overlay-below{ #documents-overlay-below{
left:85px; left:0;
top:48px; top:0;
filter:alpha(opacity=100); filter:alpha(opacity=100);
opacity: 1; opacity: 1;
background:#f0f0f0; background:#f0f0f0;
z-index: 999; z-index: 999;
} }
#documents-content #editor, #documents-content #members{ #members{
padding-top: 3em !important; padding-top: 3em !important;
} }

@ -8,7 +8,6 @@ var documentsMain = {
onStartup: function() { onStartup: function() {
"use strict"; "use strict";
$('<div id="documents-overlay"></div> <div id="documents-overlay-below"></div>').hide().appendTo(document.body); $('<div id="documents-overlay"></div> <div id="documents-overlay-below"></div>').hide().appendTo(document.body);
$('#documents-overlay-below').css({left: $('#navigation').width()+4});
OC.addScript('documents', 'dojo-amalgamation', function() { OC.addScript('documents', 'dojo-amalgamation', function() {
OC.addScript('documents', 'webodf-debug').done(function() { OC.addScript('documents', 'webodf-debug').done(function() {
// preload stuff in the background // preload stuff in the background
@ -33,19 +32,19 @@ var documentsMain = {
require({ }, ["webodf/editor/server/owncloud/ServerFactory", "webodf/editor/Editor"], function (ServerFactory, Editor) { require({ }, ["webodf/editor/server/owncloud/ServerFactory", "webodf/editor/Editor"], function (ServerFactory, Editor) {
// fade out file list and show WebODF canvas // fade out file list and show WebODF canvas
$('.documentslist, #emptyfolder').fadeOut('slow').promise().done(function() { $('#content').fadeOut('slow').promise().done(function() {
// odf action toolbar // odf action toolbar
var odfToolbarHtml = var odfToolbarHtml =
'<div id="odf-toolbar">' + '<div id="odf-toolbar" class="dijitToolbar">' +
' <button id="odf_close">' + ' <button id="odf-close">' +
t('files_odfviewer', 'Close') + t('documents', 'Close') +
' </button>' + ' </button>' +
' <button id="odf_invite">' + ' <button id="odf-invite">' +
t('files_odfviewer', 'Invite') + t('documents', 'Invite') +
' </button>' + ' </button>' +
' <span id="toolbar" class="claro"></span>' + ' <span id="toolbar" class="claro"></span>' +
'</div>'; '</div>';
$('#controls').append(odfToolbarHtml); $(document.body).prepend(odfToolbarHtml);
var memberId, odfelement, odfcanvas, canvashtml = var memberId, odfelement, odfcanvas, canvashtml =
'<div id = "mainContainer" class="claro" style="">' + '<div id = "mainContainer" class="claro" style="">' +
@ -67,7 +66,7 @@ var documentsMain = {
var serverFactory = new ServerFactory(); var serverFactory = new ServerFactory();
$(document.body).addClass("claro"); $(document.body).addClass("claro");
$('.documentslist, #emptyfolder').after(canvashtml); $(document.body).prepend(canvashtml);
// in case we are on the public sharing page we shall display the odf into the preview tag // in case we are on the public sharing page we shall display the odf into the preview tag
$('#preview').html(canvashtml); $('#preview').html(canvashtml);
@ -159,7 +158,7 @@ var documentsMain = {
$('#mainContainer').remove(); $('#mainContainer').remove();
$('#odf-toolbar').remove(); $('#odf-toolbar').remove();
$('.actions,#file_access_panel').fadeIn('slow'); $('.actions,#file_access_panel').fadeIn('slow');
$('.documentslist, #emptyfolder').fadeIn('slow'); $('#content').fadeIn('slow');
$(document.body).removeClass('claro'); $(document.body).removeClass('claro');
}); });
documentsMain.isEditorMode = false; documentsMain.isEditorMode = false;
@ -270,10 +269,10 @@ $(document).ready(function() {
} }
}); });
$('#content').on('click', '#odf_close', documentsMain.onClose); $(document.body).on('click', '#odf-close', documentsMain.onClose);
$('#content').on('click', '#odf_invite', documentsMain.onInvite); $(document.body).on('click', '#odf-invite', documentsMain.onInvite);
$('#content').on('click', '#invite-send', documentsMain.sendInvite); $(document.body).on('click', '#invite-send', documentsMain.sendInvite);
$('#content').on('click', '#invitee-list li', function(){ $(document.body).on('click', '#invitee-list li', function(){
$(this).remove(); $(this).remove();
}); });

@ -1,12 +1,14 @@
<div id="controls"> <!-- <div id="controls">
<div id="invite-block" style="display:none"> <div id="invite-block" style="display:none">
<input id="inivite-input" type="text" /> <input id="inivite-input" type="text" />
<ul id="invitee-list"></ul> <ul id="invitee-list"></ul>
<button id="invite-send"><?php p('Send Invitation') ?></button> <button id="invite-send"><?php p('Send Invitation') ?></button>
</div> </div>
</div> </div>
-->
<div id="editor-content">
</div>
<div id="documents-content"> <div id="documents-content">
<div id="editor-content">
<ul class="documentslist"> <ul class="documentslist">
<li class="add-document"> <li class="add-document">
<!-- <a class="add svg" target="_blank" href=""> <!-- <a class="add svg" target="_blank" href="">
@ -20,5 +22,4 @@
<a target="_blank" href=""><label></label></a> <a target="_blank" href=""><label></label></a>
</li> </li>
</ul> </ul>
</div>
</div> </div>

Loading…
Cancel
Save