Don't redraw a media-tag everytime the content has changed

This commit is contained in:
yflory
2017-06-13 17:21:22 +02:00
parent 2032c08066
commit 19cb920a7c
6 changed files with 18 additions and 34 deletions

View File

@@ -53,6 +53,9 @@ body {
font-family: Calibri, Ubuntu, sans-serif;
word-wrap: break-word;
}
#previewContainer media-tag * {
max-width: 100%;
}
#preview {
max-width: 40vw;
margin: auto;

View File

@@ -56,6 +56,9 @@ body {
box-sizing: border-box;
font-family: Calibri,Ubuntu,sans-serif;
word-wrap: break-word;
media-tag * {
max-width:100%;
}
}
#preview {

View File

@@ -9,6 +9,7 @@ define([
'/common/cryptpad-common.js',
'/common/cryptget.js',
'/common/diffMarked.js',
'/bower_components/tweetnacl/nacl-fast.min.js', // needed for media-tag
], function ($, Crypto, Realtime, TextPatcher, Toolbar, JSONSortify, JsonOT, Cryptpad,
Cryptget, DiffMd) {
var Messages = Cryptpad.Messages;