mirror of https://github.com/zulip/zulip.git
copy_and_paste: Re-disable copy-paste handler in production.
This reverts commit 6e048c5d3f
.
See #8963 for the main issue we need to fix before re-enabling this;
basically, some combination of toMarkdown and the way text/html gets
written was introducing a lot of bonus/bogus whitespace, both in the
form of newlines and spaces converted to ` `.
This commit is contained in:
parent
a183186672
commit
a4def8d409
|
@ -1,5 +1,9 @@
|
|||
global.stub_out_jquery();
|
||||
|
||||
set_global('page_params', {
|
||||
development: true,
|
||||
});
|
||||
|
||||
var jsdom = require("jsdom");
|
||||
global.document = jsdom.jsdom('<!DOCTYPE html><p>Hello world</p>');
|
||||
var window = jsdom.jsdom().defaultView;
|
||||
|
|
|
@ -224,7 +224,7 @@ exports.paste_handler = function (event) {
|
|||
|
||||
if (clipboardData.getData) {
|
||||
var paste_html = clipboardData.getData('text/html');
|
||||
if (paste_html) {
|
||||
if (paste_html && page_params.development_environment) {
|
||||
event.preventDefault();
|
||||
var text = exports.paste_handler_converter(paste_html);
|
||||
compose_ui.insert_syntax_and_focus(text);
|
||||
|
|
Loading…
Reference in New Issue