From a80b00a7655036a1814cd54b0b4cf8c7517f51c2 Mon Sep 17 00:00:00 2001 From: yflory Date: Thu, 20 Jul 2017 18:32:03 +0200 Subject: [PATCH] Move the file picker in common --- customize.dist/src/less/mixins.less | 53 ++++++++++++++++++++ www/common/cryptpad-common.js | 62 +++++++++++++++++++++++ www/common/diffMarked.js | 1 - www/drive/file.less | 49 +----------------- www/slide/main.js | 77 +++++------------------------ 5 files changed, 128 insertions(+), 114 deletions(-) diff --git a/customize.dist/src/less/mixins.less b/customize.dist/src/less/mixins.less index cd900a60c..0ef09dd36 100644 --- a/customize.dist/src/less/mixins.less +++ b/customize.dist/src/less/mixins.less @@ -138,3 +138,56 @@ background: white; } } + +.fileIcon { + li { + display: inline-block; + margin: 10px 10px; + width: 140px; + height: 140px; + text-align: center; + vertical-align: top; + overflow: hidden; + text-overflow: ellipsis; + padding-top: 5px; + padding-bottom: 5px; + + &:not(.selected):not(.selectedTmp) { + border: 1px solid #CCC; + } + .name { + width: 100%; + height: 48px; + margin: 8px 0; + display: inline-block; + //align-items: center; + //justify-content: center; + overflow: hidden; + //text-overflow: ellipsis; + word-wrap: break-word; + } + .truncated { + display: block; + position: absolute; + bottom: 0px; + left: 0; right: 0; + text-align: center; + } + img.icon { + height: 48px; + max-height: none; + max-width: none; + margin: 8px 0; + } + .fa { + display: block; + margin: auto; + font-size: 48px; + margin: 8px 0; + text-align: center; + &.listonly { + display: none; + } + } + } +} diff --git a/www/common/cryptpad-common.js b/www/common/cryptpad-common.js index 5b7e5a15a..9a3e7abf4 100644 --- a/www/common/cryptpad-common.js +++ b/www/common/cryptpad-common.js @@ -1098,6 +1098,7 @@ define([ } break; case 'upload': + console.log('UPLOAD'); button = $('