From ba88cf0ce9d0403b84251d237fc620703ab17132 Mon Sep 17 00:00:00 2001 From: George Berezhnoy Date: Tue, 23 May 2017 17:10:48 +0300 Subject: [PATCH] Attaches fix --- plugins/attaches/attaches.css | 1 + plugins/attaches/attaches.js | 8 +++++--- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/plugins/attaches/attaches.css b/plugins/attaches/attaches.css index bca5723c..5712fce9 100644 --- a/plugins/attaches/attaches.css +++ b/plugins/attaches/attaches.css @@ -53,6 +53,7 @@ .cdx-attaches__extension, .cdx-attaches__size { color: #8f9298; + white-space: nowrap; } .cdx-attaches__extension::after { diff --git a/plugins/attaches/attaches.js b/plugins/attaches/attaches.js index e73685ee..52268411 100644 --- a/plugins/attaches/attaches.js +++ b/plugins/attaches/attaches.js @@ -21,7 +21,8 @@ var cdxAttaches = function () { * Private methods and props */ - var KBYTE = 1024; + var KBYTE = 1024, + fileWrapper = null; /** * Default config @@ -217,7 +218,7 @@ var cdxAttaches = function () { upload.current = progress; - codex.editor.content.switchBlock(codex.editor.content.currentNode, progress, 'attaches'); + codex.editor.content.switchBlock(fileWrapper, progress, 'attaches'); }, @@ -350,7 +351,8 @@ var cdxAttaches = function () { if (!data) { - return ui.defaultForm(); + fileWrapper = ui.defaultForm(); + return fileWrapper; }